Number Scales
Scales automatically generate multiple tokens from a mathematical pattern. They're perfect for creating consistent spacing, typography, and sizing systems.
Linear Scales
Linear scales add a fixed amount each step. They're ideal for spacing and sizing where you want even increments.
Why use scales? Instead of manually defining each value, let the scale generator produce consistent, mathematical progressions automatically.
Basic Linear Scale
Using Peak Instead of Increment
Define the maximum value and let the system calculate even distribution:
Linear Parameters
base- Starting value (required)
increment- Amount to add each step
peak- Maximum value (alternative to increment)
steps- Array of step names or a number
Modular Scales
Modular scales multiply by a ratio each step. They create proportional progressions that are ideal for typography.
Basic Modular Scale
Common Typography Ratios
Compare different ratios side by side:
Using Peak Instead of Ratio
Define the maximum value and let the ratio be calculated automatically:
Step Definitions
Steps define the names and count of generated tokens. You can use explicit lists, numbers, ranges, and prefixed patterns.
Explicit List
Range Shorthand
Generate numeric sequences automatically with [start..end] or [start..end:step]:
Range with Prefix
Add prefixes to generated numbers using braces {...}:
Mixed Ranges
Combine multiple ranges with different stepping for fine-grained control at certain intervals:
Complete Examples
Spacing System
Typography Scale
Border Radius Scale
Next: Inheritance — clone token groups and create derived sets with transforms.