Expand description
Design token tables.
The tables are authored here, in Rust, because Rust is the single source for everything
that has two representations, and because values written in Kotlin by hand would go
unverified. They are executed in the Renderer: codegen writes them into
Protocol.gen.kt as Kotlin objects, so they enter the Renderer binary at build time and
never cross the boundary at run time. The Host still sends roles and never a token
table.
What the Renderer implementer still owns is the rules these values feed: how an
elevation is drawn, how each ButtonVariant is styled, and motion.
Structs§
- Color
Token - One
ColorRoleslot in both schemes, inColorRoletag order. - Design
Token Table - Items 1 to 4 of the 14.6 table for one design system.
- Shape
Token - Space
Token - Type
Token - One rung of the nine-rung type ladder (13.2).
Constants§
- DESIGN_
TOKENS - Every design system’s table, in
DesignSystemtag order.