A fork of @unocss/preset-mini
- Use
emunits by default - Fallback values for CSS variables
- i.e.
color-$red|#ff0000forcolor: var(--red, #ff0000)property
- i.e.
- Background images
bg-image-[…]forbackground-imagepropertybg-repeat-xforbackground-repeat: repeat-xpropertybg-bottomforbackground-position: bottomproperty
- Containment
contain-layoutcontain-paintcontain-content
- Content visibility
content-visibility-auto
- Object fit
object-coverobject-containobject-fillobject-scale-downobject-none
- Object position
object-top,object-top-left, etc
- Scroll snap
snap-x,snap-y,snap-both, orsnap-nonefor directionsnap-mandatoryorsnap-proximityfor strictnesssnap-start,snap-end,snap-center, orsnap-align-nonefor alignmentsnap-normalorsnap-alwaysfor “snap stops”scroll-m-…andscroll-p-…for margin/padding
- Overscroll behavior
no-overscrollforoverscroll-behavior: containproperty
- Scrollbar appearance
no-scrollbarsforscrollbar-width: noneand-ms-overflow-style: noneproperties
- Tabular numbers
tabnumforfont-feature-settings: tnumproperty
- Line clamping
- i.e.
line-clamp-2to use-webkit-line-clampto limit number of wraps to 2 lines
- i.e.
- Touch actions
touch-pan-*fortouch-action: pan-*propertytouch-pinch-zoomfortouch-action: pinch-zoompropertytouch-autofortouch-action: autopropertytouch-manipulationfortouch-action: manipulationpropertytouch-nonefortouch-action: noneproperty
- Targeting
<span>and<a>descendants- i.e.
span:color-redforcolor: redproperty on all span and anchor tags within the element - When using
emas the default, this is most useful when you want to set a default font size for text within an element.
- i.e.
- Element-level zooming
zoom-5appliesfont-size: 5emto all direct children of the elementzoom-0.5appliesfont-size: 0.5emto all direct children of the element- This is great for scaling elements on-the-fly without having to update every
emvalue of every descendant.
- Targeting attribute values
- i.e.
[data-selected]:color-redforcolor: redproperty if the element has adata-selectedattribute - or
[data-selected="true"]:color-redforcolor: redproperty if the element has adata-selectedattribute with a value oftrue
- i.e.
And probably some other stuff I forgot to list!