import type { Rule } from '@unocss/core' ; import { handler as h } from '../utils' ; export const varEmpty = 'var(--un-empty,/*!*/ /*!*/)' ; export const displays = [ [ 'inline' , { display : 'inline' } ] , [ 'block' , { display : 'block' } ] , [ 'inline-block' , { display : 'inline-block' } ] , [ 'contents' , { display : 'contents' } ] , [ 'flow-root' , { display : 'flow-root' } ] , [ 'list-item' , { display : 'list-item' } ] , [ 'hidden' , { display : 'none' } ] , ] ; export const appearances = [ [ 'visible' , { visibility : 'visible' } ] , [ 'invisible' , { visibility : 'hidden' } ] , [ 'backface-visible' , { 'backface-visibility' : 'visible' } ] , [ 'backface-hidden' , { 'backface-visibility' : 'hidden' } ] , ] ; export const cursors = [ [ /^cursor-(.+)$/ , ( [ , c ] ) => ( { cursor : h . bracket . cssvar ( c ) || c } ) ] , ] ; export const pointerEvents = [ [ 'pointer-events-auto' , { 'pointer-events' : 'auto' } ] , [ 'pointer-events-none' , { 'pointer-events' : 'none' } ] , ] ; export const resizes = [ [ 'resize-x' , { resize : 'horizontal' } ] , [ 'resize-y' , { resize : 'vertical' } ] , [ 'resize' , { resize : 'both' } ] , [ 'resize-none' , { resize : 'none' } ] , ] ; export const userSelects = [ [ 'select-auto' , { 'user-select' : 'auto' } ] , [ 'select-all' , { 'user-select' : 'all' } ] , [ 'select-text' , { 'user-select' : 'text' } ] , [ 'select-none' , { 'user-select' : 'none' } ] , ] ; export const whitespaces = [ [ /^(?:whitespace|ws)-(normal|nowrap|pre|pre-line|pre-wrap)$/ , ( [ , v ] ) => ( { 'white-space' : v } ) ] , ] ; export const contents = [ [ 'content-empty' , { content : '""' } ] , [ 'content-none' , { content : '""' } ] , ] ; export const breaks = [ [ 'break-normal' , { 'overflow-wrap' : 'normal' , 'word-break' : 'normal' } ] , [ 'break-words' , { 'overflow-wrap' : 'break-word' } ] , [ 'break-all' , { 'word-break' : 'break-all' } ] , ] ; export const textOverflows = [ [ 'truncate' , { 'overflow' : 'hidden' , 'text-overflow' : 'ellipsis' , 'white-space' : 'nowrap' } ] , [ 'text-ellipsis' , { 'text-overflow' : 'ellipsis' } ] , [ 'text-clip' , { 'text-overflow' : 'clip' } ] , ] ; export const textTransforms = [ [ 'case-upper' , { 'text-transform' : 'uppercase' } ] , [ 'case-lower' , { 'text-transform' : 'lowercase' } ] , [ 'case-capital' , { 'text-transform' : 'capitalize' } ] , [ 'case-normal' , { 'text-transform' : 'none' } ] , ] ; export const fontStyles = [ [ 'italic' , { 'font-style' : 'italic' } ] , [ 'not-italic' , { 'font-style' : 'normal' } ] , ] ; export const fontSmoothings = [ [ 'antialiased' , { '-webkit-font-smoothing' : 'antialiased' , '-moz-osx-font-smoothing' : 'grayscale' , 'font-smoothing' : 'grayscale' , } ] , [ 'subpixel-antialiased' , { '-webkit-font-smoothing' : 'auto' , '-moz-osx-font-smoothing' : 'auto' , 'font-smoothing' : 'auto' , } ] , ] ;