Skip to content

pantoken-root / packages/core/src / Token

Interface: Token ​

Beta

A single design token in the canonical @property-aligned IR.

Properties ​

name ​

name: string

The custom-property name, e.g. --instui-color-background-base.


syntax ​

syntax: string

The @property syntax descriptor ("<color>", "<length>", "<image>", …) or "*" for contextual values.


inherits ​

inherits: boolean

The @property inherits flag.


value ​

value: string

A concrete value, a var(...) reference, or a light-dark(a, b) pair.


flatValue? ​

optional flatValue?: string

Beta

The fully-flattened literal, present only when value is a reference-preserving CSS expression (a Tokens Studio modify rendered as color-mix() / hsl(from …)). Emitters that need a real colour rather than a CSS expression — the native lineage, Figma, swatches — read this instead; the shared resolver in @pantoken/utils prefers it automatically.


themed? ​

optional themed?: boolean

Beta

True when the light and dark resolutions differ (value is a light-dark()).


refersTo? ​

optional refersTo?: string

Beta

The token this one references, when value is a single var(...).


meta? ​

optional meta?: TokenMeta

Beta

Non-value metadata.