Components use semantic tokens such as bg/surface or text/muted, never the raw ramps. Each semantic token resolves to a different primitive in Light and Dark, and to the active brand where it says brand.
How to use the tokens
In CSS, read the variable directly. With Tailwind, import @aloxe/tokens/tailwind.css and use the ax utilities.
.panel {
background: var(--aloxe-bg-surface);
color: var(--aloxe-text-primary);
border: 1px solid var(--aloxe-border-default);
}
<div class="bg-ax-surface text-ax-text border border-ax-border">...</div>
Semantic tokens
Where a value says brand, the hex shown is the Cobalt value. Other brands replace the brand ramp, see below.
Background
| Token | CSS variable | Light | Dark |
|---|
bg/canvas | --aloxe-bg-canvas | gray/25 (#fcfaf7) | gray/950 (#141211) |
bg/surface | --aloxe-bg-surface | gray/0 (#ffffff) | gray/900 (#1c1a19) |
bg/raised | --aloxe-bg-raised | gray/50 (#f7f5f2) | gray/850 (#282624) |
bg/sunken | --aloxe-bg-sunken | gray/100 (#eeecea) | gray/1000 (#0e0d0b) |
bg/inverse | --aloxe-bg-inverse | gray/900 (#1c1a19) | gray/50 (#f7f5f2) |
bg/scrim | --aloxe-bg-scrim | alpha/black-40 (rgba(0, 0, 0, 0.4)) | alpha/black-64 (rgba(0, 0, 0, 0.64)) |
Text
| Token | CSS variable | Light | Dark |
|---|
text/primary | --aloxe-text-primary | gray/900 (#1c1a19) | gray/50 (#f7f5f2) |
text/secondary | --aloxe-text-secondary | gray/700 (#4e4d4b) | gray/300 (#cfcdcb) |
text/muted | --aloxe-text-muted | gray/600 (#656361) | gray/400 (#a6a4a2) |
text/disabled | --aloxe-text-disabled | gray/400 (#a6a4a2) | gray/600 (#656361) |
text/inverse | --aloxe-text-inverse | gray/0 (#ffffff) | gray/950 (#141211) |
text/on-accent | --aloxe-text-on-accent | gray/0 (#ffffff) | gray/1000 (#0e0d0b) |
text/link | --aloxe-text-link | brand/600 (cobalt #3267ce) | brand/300 (cobalt #a7c5fa) |
Border
| Token | CSS variable | Light | Dark |
|---|
border/subtle | --aloxe-border-subtle | alpha/ink-8 (#1c1a19 at 8%) | alpha/paper-8 (#f7f5f2 at 8%) |
border/default | --aloxe-border-default | alpha/ink-14 (#1c1a19 at 14%) | alpha/paper-14 (#f7f5f2 at 14%) |
border/control | --aloxe-border-control | gray/450 (#8d8c89) | gray/550 (#6d6b69) |
border/focus | --aloxe-border-focus | brand/600 (cobalt #3267ce) | brand/400 (cobalt #78a4f4) |
border/control-hover | --aloxe-border-control-hover | gray/600 (#656361) | gray/450 (#8d8c89) |
Accent
| Token | CSS variable | Light | Dark |
|---|
accent/default | --aloxe-accent-default | brand/600 (cobalt #3267ce) | brand/400 (cobalt #78a4f4) |
accent/hover | --aloxe-accent-hover | brand/700 (cobalt #2c55a5) | brand/300 (cobalt #a7c5fa) |
accent/pressed | --aloxe-accent-pressed | brand/800 (cobalt #244179) | brand/200 (cobalt #cbddfd) |
accent/subtle | --aloxe-accent-subtle | brand/50 (cobalt #ebf8ff) | brand/950 (cobalt #161f31) |
accent/subtle-hover | --aloxe-accent-subtle-hover | brand/100 (cobalt #e2efff) | brand/900 (cobalt #1d2f52) |
accent/text | --aloxe-accent-text | brand/700 (cobalt #2c55a5) | brand/200 (cobalt #cbddfd) |
State
| Token | CSS variable | Light | Dark |
|---|
state/hover | --aloxe-state-hover | alpha/ink-4 (#1c1a19 at 4%) | alpha/paper-6 (#f7f5f2 at 6%) |
state/pressed | --aloxe-state-pressed | alpha/ink-8 (#1c1a19 at 8%) | alpha/paper-10 (#f7f5f2 at 10%) |
Shadow
| Token | CSS variable | Light | Dark |
|---|
shadow/ambient | --aloxe-shadow-ambient | alpha/black-4 (rgba(0, 0, 0, 0.04)) | alpha/black-24 (rgba(0, 0, 0, 0.24)) |
shadow/key | --aloxe-shadow-key | alpha/black-8 (rgba(0, 0, 0, 0.08)) | alpha/black-40 (rgba(0, 0, 0, 0.4)) |
Status
| Token | CSS variable | Light | Dark |
|---|
status/success/solid | --aloxe-status-success-solid | green/600 (#1e8240) | green/400 (#75b683) |
status/success/text | --aloxe-status-success-text | green/700 (#206a37) | green/300 (#a7d0ae) |
status/success/subtle | --aloxe-status-success-subtle | green/50 (#ebfdee) | green/950 (#152318) |
status/success/border | --aloxe-status-success-border | green/200 (#cbe3cf) | green/800 (#1e4f2c) |
status/warning/solid | --aloxe-status-warning-solid | amber/600 (#9c5d00) | amber/400 (#cc9b53) |
status/warning/text | --aloxe-status-warning-text | amber/700 (#7e4d00) | amber/300 (#dfbe93) |
status/warning/subtle | --aloxe-status-warning-subtle | amber/50 (#fff5e3) | amber/950 (#281d0e) |
status/warning/border | --aloxe-status-warning-border | amber/200 (#ecd9bf) | amber/800 (#5e3c00) |
status/danger/solid | --aloxe-status-danger-solid | red/600 (#bf3133) | red/400 (#ec817a) |
status/danger/text | --aloxe-status-danger-text | red/700 (#9a2d2d) | red/300 (#f7afa8) |
status/danger/subtle | --aloxe-status-danger-subtle | red/50 (#ffefeb) | red/950 (#2f1816) |
status/danger/border | --aloxe-status-danger-border | red/200 (#fccfcb) | red/800 (#722725) |
status/info/solid | --aloxe-status-info-solid | brand/600 (cobalt #3267ce) | brand/400 (cobalt #78a4f4) |
status/info/text | --aloxe-status-info-text | brand/700 (cobalt #2c55a5) | brand/300 (cobalt #a7c5fa) |
status/info/subtle | --aloxe-status-info-subtle | brand/50 (cobalt #ebf8ff) | brand/950 (cobalt #161f31) |
status/info/border | --aloxe-status-info-border | brand/200 (cobalt #cbddfd) | brand/800 (cobalt #244179) |
Brand ramps
brand/50 to brand/950 point at the active brand. @aloxe/tokens ships Cobalt. Ember and Moss come with Pro.
| Step | Cobalt | Ember | Moss |
|---|
50 | #ebf8ff | #fff1e7 | #edfcef |
100 | #e2efff | #ffe7dd | #e4f2e5 |
200 | #cbddfd | #f7d3c4 | #cee2d0 |
300 | #a7c5fa | #f0b49d | #adcfb0 |
400 | #78a4f4 | #e38a67 | #7fb486 |
500 | #4981ec | #d45d29 | #4f995c |
600 | #3267ce | #b64302 | #367f45 |
700 | #2c55a5 | #933a0f | #2f683a |
800 | #244179 | #6d2f14 | #274e2e |
900 | #1d2f52 | #4b2414 | #1f3723 |
950 | #161f31 | #2d1a12 | #172319 |
Status colours
Success, warning, danger and info each have four tokens: solid for fills and icons, text for text on a light or dark surface, subtle for backgrounds and border for outlines. Do not rely on colour alone to convey status: pair it with text or an icon.