Dimension
Dimension tokens in the Jux Editor
Jux supports dimension tokens as consisting of an positive number and a unit of measure. Jux currently supports the following units: PX, %, EM, REM, VH, VW.
Note that dimension fields can accept entries like ‘auto’ which cannot be tokenized.
Coming soon: Dimension tokens could be aliased (pointed to) by other composite tokens like the font size, line height and letter spacing in Typography token, the border width in Border token, the x, y, spread and blur values in Shadow token etc..
Dimension tokens have these fields:
A name (like "space_xs" or "padding_top_input")
A folder path (like "color/core/space_xs")
Optional - an alias to another token
Number value + unit
Optional - description
Dimension tokens can later be used in the DDP in the following modules:
Size (width, height)
Padding + margin
Vertical and horizontal gaps when display is ‘flex’
Border width
Corner radius
Shadow measurements
Each color field can be tokenized by clicking on the ‘token icon button’ that appears on the right side of the field upon hover:
Under the hood
Jux adheres to the W3C Community group’s draft guidelines regarding dimension tokens (section 8.2.) and stores the token as a JSON file with the following structure:
Last updated