Module stylo

Source
Expand description

Private module of type aliases so we can refer to stylo types with nicer names

StructsΒ§

AlignFlags πŸ”’
Constants shared by multiple CSS Box Alignment properties
ContentDistribution πŸ”’
Shared value for the align-content and justify-content properties.
Display πŸ”’
GridAutoFlow πŸ”’
Controls how the auto-placement algorithm works specifying exactly how auto-placed items get flowed into the grid: [ row | column ] || dense https://drafts.csswg.org/css-grid-2/#grid-auto-flow-property
LengthPercentage πŸ”’
A <length-percentage> value. This can be either a <length>, a <percentage>, or a combination of both via calc().
NonNegative πŸ”’
A wrapper of Non-negative values.
Percentage πŸ”’
A computed percentage.

EnumsΒ§

BoxSizing πŸ”’
DisplayInside πŸ”’
DisplayOutside πŸ”’
Defines an element’s display type, which consists of the two basic qualities of how an element generates boxes https://drafts.csswg.org/css-display/#propdef-display
GenericGridTemplateComponent πŸ”’
Variants for <grid-template-rows> | <grid-template-columns>
GenericInset πŸ”’
Specified type for inset properties, which allows the use of the anchor() function. Note(dshin): LengthPercentageOrAuto is not used here because having LengthPercentageOrAuto and AnchorFunction in the enum pays the price of the discriminator for LengthPercentage | Auto as well as LengthPercentageOrAuto | AnchorFunction. This increases the size of the style struct, which would not be great. On the other hand, we trade for code duplication, so… :(
GenericLengthPercentageOrNormal πŸ”’
A generic <length-percentage> | normal` value.
GenericMargin πŸ”’
Specified type for margin properties, which allows the use of the anchor-size() function.
GenericMaxSize πŸ”’
A generic value for the max-width or max-height property.
GenericSize πŸ”’
A generic value for the width, height, min-width, or min-height property.
Overflow πŸ”’
The value for the overflow-x / overflow-y properties.
Position πŸ”’
PreferredRatio πŸ”’
Ratio or None.
RepeatCount πŸ”’
The initial argument of the repeat function.
TrackBreadth πŸ”’
A track breadth for explicit grid track sizing. It’s generic solely to avoid re-implementing it for the computed type.
TrackListValue πŸ”’
Track list values. Can be or
TrackSize πŸ”’
A <track-size> type for explicit grid track sizing. Like <track-breadth>, this is generic only to avoid code bloat. It only takes <length-percentage>
UnpackedLengthPercentage πŸ”’
An unpacked <length-percentage> that borrows the calc() variant.

Type AliasesΒ§

AspectRatio πŸ”’
A computed value for the aspect-ratio property.
Gap πŸ”’
GridLine πŸ”’
The computed value of a <grid-line>.
InsetVal πŸ”’
MarginVal πŸ”’
MaxSize πŸ”’
Size πŸ”’