Expand description
A typed representation of CSS style properties in Rust. Used as input to layout computation.
Modules§
- alignment 🔒
- Style types for controlling alignment
- available_
space 🔒 - Style type for representing available space as a sizing constraint
- compact_
length 🔒 - A tagged-pointer abstraction that allows size styles in Taffy to be represented
in just 64 bits. Wrapped by types in the
super::dimension
andsuper::grid
modules. - dimension 🔒
- Style types for representing lengths / sizes
- grid 🔒
- Style types for CSS Grid layout
Structs§
- Compact
Length - A representation of a length as a compact 64-bit tagged pointer
- Dimension
- A unit of linear measurement
- Grid
Template Area - Defines a grid area
- Grid
Template Repetition - A typed representation of a
repeat(..)
ingrid-template-*
value - Length
Percentage - A unit of linear measurement
- Length
Percentage Auto - A unit of linear measurement
- MaxTrack
Sizing Function - Maximum track sizing function
- MinTrack
Sizing Function - Minimum track sizing function
- Named
Grid Line - Defines a named grid line
- Style
- A typed representation of the CSS style information for a single node.
Enums§
- Align
Content - Sets the distribution of space between and around content items For Flexbox it controls alignment in the cross axis For Grid it controls alignment in the block axis
- Align
Items - Used to control how child nodes are aligned. For Flexbox it controls alignment in the cross axis For Grid it controls alignment in the block axis
- Available
Space - The amount of space available to a node in a given axis https://www.w3.org/TR/css-sizing-3/#available
- BoxGeneration
Mode - An abstracted version of the CSS
display
property where any value other than “none” is represented by “normal” See: https://www.w3.org/TR/css-display-3/#box-generation - BoxSizing
- Specifies whether size styles for this node are assigned to the node’s “content box” or “border box”
- Display
- Sets the layout used for the children of this node
- Generic
Grid Placement - A grid line placement specification which is generic over the coordinate system that it uses to define grid line positions.
- Generic
Grid Template Component - A type representing a component in a
grid-template-*
defintion where the type representingrepeat()
s is generic - Grid
Auto Flow - Controls whether grid items are placed row-wise or column-wise. And whether the sparse or dense packing algorithm is used.
- Grid
Placement - A grid line placement specification. Used for grid-[row/column]-[start/end]. Named tracks are not implemented.
- Grid
Template Component - An element in a
grid-template-columns
orgrid-template-rows
definition. Either a track sizing function or a repeat(). - Overflow
- How children overflowing their container should affect layout
- Position
- The positioning strategy for this item.
- Repetition
Count - The first argument to a repeated track definition. This type represents the type of automatic repetition to perform.
Traits§
- Cheap
Clone Str - Trait that represents a cheaply clonable string. If you’re unsure what to use here
consider
Arc<str>
orstring_cache::Atom
. - Core
Style - The core set of styles that are shared between all CSS layout nodes
- Generic
Repetition - A trait to represent a
repeat()
clause in agrid-template-*
definition - Grid
Container Style - The set of styles required for a CSS Grid container
- Grid
Item Style - The set of styles required for a CSS Grid item (child of a CSS Grid container)
- Template
Line Names - A nested list of line names. This is effectively a generic representation of
Vec<Vec<String>>
that allows both the collection and string type to be customised.
Type Aliases§
- Align
Self - Controls alignment of an individual node
- Justify
Content - Sets the distribution of space between and around content items For Flexbox it controls alignment in the main axis For Grid it controls alignment in the inline axis
- Justify
Items - Used to control how child nodes are aligned. Does not apply to Flexbox, and will be ignored if specified on a flex container For Grid it controls alignment in the inline axis
- Justify
Self - Controls alignment of an individual node
- Track
Sizing Function - The sizing function for a grid track (row/column)