Expand description
Token block and token AST types.
Structs§
- Filter
Literal - A filter token literal: an ordered list of filter operations, applied in source order. At least one op is required (enforced at resolution).
- Filter
Op - A single filter operation: a kind plus an optional amount. The amount is a
unitless number whose meaning depends on the kind (e.g. fraction for
grayscale, degrees forhue-rotate);Nonemeans “use the op’s default”. - Gradient
Literal - A gradient token literal: either linear (angle + stops) or radial (center + radius + stops).
- Gradient
Stop Ref - A single gradient stop: an offset in
0..1and a reference to a color token. - Mask
Literal - A mask token literal: a single spatial coverage shape plus a feather and an invert flag.
- Shadow
Layer Ref - A single shadow layer: x/y offsets and blur radius (pixels) plus a reference to a color token. A layer with nonzero dx/dy is a drop shadow; a layer with dx=dy=0 and a blur is an outer glow.
- Shadow
Literal - A shadow token literal: an ordered list of shadow layers (e.g. a drop shadow plus an outer glow). At least one layer is required (enforced at resolution).
- Token
- A single design token within a
tokensblock. - Token
Block - The top-level
tokensblock with its requiredformatattribute.
Enums§
- Filter
Kind - The color/image filter operations, applied in source order.
- Gradient
Kind - Whether a gradient token is linear or radial.
- Mask
Shape - The spatial coverage shape of a mask token.
- Token
Literal - A literal value held by a token definition.
- Token
Type - The five v0 token types, plus an extensibility variant for unknown types.
- Token
Value - The value of a token — either an inline literal or an alias to another token.