@codecademy/gamut 68.6.1-alpha.f6b2ce.0 → 68.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Modals/elements.d.ts +186 -1
- package/dist/Modals/elements.js +3 -3
- package/dist/{InternalFloatingCard/InternalFloatingCard.d.ts → PatternBackdrop/PatternBackdrop.d.ts} +8 -24
- package/dist/PatternBackdrop/PatternBackdrop.js +42 -0
- package/dist/Toast/Toast.js +4 -4
- package/package.json +8 -11
- package/agent-tools/.claude-plugin/marketplace.json +0 -16
- package/agent-tools/.claude-plugin/plugin.json +0 -7
- package/agent-tools/.cursor-plugin/plugin.json +0 -7
- package/agent-tools/DESIGN.Codecademy.md +0 -696
- package/agent-tools/DESIGN.LXStudio.md +0 -512
- package/agent-tools/DESIGN.Percipio.md +0 -513
- package/agent-tools/DESIGN.md +0 -1
- package/agent-tools/agents/.gitkeep +0 -0
- package/agent-tools/commands/gamut-review.md +0 -259
- package/agent-tools/guidelines/components/animations.md +0 -74
- package/agent-tools/guidelines/components/buttons.md +0 -95
- package/agent-tools/guidelines/components/card.md +0 -19
- package/agent-tools/guidelines/components/coachmark.md +0 -21
- package/agent-tools/guidelines/components/data-table.md +0 -79
- package/agent-tools/guidelines/components/forms.md +0 -106
- package/agent-tools/guidelines/components/loading-states.md +0 -17
- package/agent-tools/guidelines/components/menu.md +0 -58
- package/agent-tools/guidelines/components/overview.md +0 -124
- package/agent-tools/guidelines/components/radial-progress.md +0 -13
- package/agent-tools/guidelines/components/select.md +0 -23
- package/agent-tools/guidelines/components/tooltips.md +0 -22
- package/agent-tools/guidelines/components/video.md +0 -29
- package/agent-tools/guidelines/foundations/color.md +0 -168
- package/agent-tools/guidelines/foundations/modes.md +0 -69
- package/agent-tools/guidelines/foundations/spacing.md +0 -107
- package/agent-tools/guidelines/foundations/typography.md +0 -82
- package/agent-tools/guidelines/overview-icons.md +0 -19
- package/agent-tools/guidelines/overview-illustrations.md +0 -7
- package/agent-tools/guidelines/overview-patterns.md +0 -7
- package/agent-tools/guidelines/overview.md +0 -84
- package/agent-tools/guidelines/setup.md +0 -83
- package/agent-tools/rules/accessibility.mdc +0 -78
- package/agent-tools/skills/gamut-accessibility/SKILL.md +0 -224
- package/agent-tools/skills/gamut-color-mode/SKILL.md +0 -149
- package/agent-tools/skills/gamut-components/SKILL.md +0 -46
- package/agent-tools/skills/gamut-forms/SKILL.md +0 -101
- package/agent-tools/skills/gamut-style-utilities/SKILL.md +0 -111
- package/agent-tools/skills/gamut-system-props/SKILL.md +0 -225
- package/agent-tools/skills/gamut-testing/SKILL.md +0 -225
- package/agent-tools/skills/gamut-theming/SKILL.md +0 -63
- package/agent-tools/skills/gamut-typography/SKILL.md +0 -79
- package/bin/commands/plugin/install.mjs +0 -213
- package/bin/commands/plugin/list.mjs +0 -73
- package/bin/commands/plugin/remove.mjs +0 -108
- package/bin/commands/plugin/update.mjs +0 -59
- package/bin/gamut.mjs +0 -96
- package/bin/lib/claude.mjs +0 -52
- package/bin/lib/cursor.mjs +0 -40
- package/bin/lib/design.mjs +0 -71
- package/bin/lib/io.mjs +0 -14
- package/bin/lib/resolve-plugin-dir.mjs +0 -38
- package/bin/lib/run-command.mjs +0 -22
- package/dist/InternalFloatingCard/InternalFloatingCard.js +0 -98
|
@@ -1,696 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
version: alpha
|
|
3
|
-
name: Codecademy Design System
|
|
4
|
-
description: Design tokens for codecademy.com
|
|
5
|
-
colors:
|
|
6
|
-
# palette — raw swatches; set once on :root and then always reference by token name, never use hex values directly in code
|
|
7
|
-
hyper-500: '#3A10E5'
|
|
8
|
-
hyper-400: '#5533FF'
|
|
9
|
-
navy-900: '#0A0D1C'
|
|
10
|
-
navy-800: '#10162F'
|
|
11
|
-
navy-700: 'rgba(16, 22, 47, 0.86)'
|
|
12
|
-
navy-600: 'rgba(16, 22, 47, 0.75)'
|
|
13
|
-
navy-500: 'rgba(16, 22, 47, 0.63)'
|
|
14
|
-
navy-300: 'rgba(16, 22, 47, 0.28)'
|
|
15
|
-
navy-200: 'rgba(16, 22, 47, 0.12)'
|
|
16
|
-
navy-100: 'rgba(16, 22, 47, 0.04)'
|
|
17
|
-
yellow-500: '#FFD300'
|
|
18
|
-
yellow-400: '#CCA900'
|
|
19
|
-
yellow-0: '#FFFAE5'
|
|
20
|
-
yellow-900: '#211B00'
|
|
21
|
-
green-700: '#008A27'
|
|
22
|
-
green-400: '#AEE938'
|
|
23
|
-
green-0: '#F5FFE3'
|
|
24
|
-
green-900: '#151C07'
|
|
25
|
-
red-600: '#BE1809'
|
|
26
|
-
red-500: '#E91C11'
|
|
27
|
-
red-400: '#DC5879'
|
|
28
|
-
red-300: '#E85D7F'
|
|
29
|
-
red-0: '#FBF1F0'
|
|
30
|
-
red-900: '#280503'
|
|
31
|
-
beige: '#FFF0E5'
|
|
32
|
-
white: '#ffffff'
|
|
33
|
-
black: '#000000'
|
|
34
|
-
# semantic aliases (light mode) — use these in code, not palette swatches or hex values
|
|
35
|
-
text: '{colors.navy-800}'
|
|
36
|
-
text-accent: '{colors.navy-900}'
|
|
37
|
-
text-secondary: '{colors.navy-600}'
|
|
38
|
-
text-disabled: '{colors.navy-500}'
|
|
39
|
-
background: '{colors.white}'
|
|
40
|
-
background-primary: '{colors.beige}'
|
|
41
|
-
background-contrast: '{colors.white}'
|
|
42
|
-
background-selected: '{colors.navy-100}'
|
|
43
|
-
background-hover: '{colors.navy-200}'
|
|
44
|
-
background-disabled: '{colors.navy-200}'
|
|
45
|
-
background-success: '{colors.green-0}'
|
|
46
|
-
background-warning: '{colors.yellow-0}'
|
|
47
|
-
background-error: '{colors.red-0}'
|
|
48
|
-
primary: '{colors.hyper-500}'
|
|
49
|
-
primary-hover: '{colors.hyper-400}'
|
|
50
|
-
primary-inverse: '{colors.yellow-500}'
|
|
51
|
-
secondary: '{colors.navy-800}'
|
|
52
|
-
secondary-hover: '{colors.navy-700}'
|
|
53
|
-
danger: '{colors.red-500}'
|
|
54
|
-
danger-hover: '{colors.red-600}'
|
|
55
|
-
feedback-error: '{colors.red-600}'
|
|
56
|
-
feedback-success: '{colors.green-700}'
|
|
57
|
-
feedback-warning: '{colors.yellow-500}'
|
|
58
|
-
border-primary: '{colors.navy-800}'
|
|
59
|
-
border-secondary: '{colors.navy-600}'
|
|
60
|
-
border-tertiary: '{colors.navy-300}'
|
|
61
|
-
border-disabled: '{colors.navy-500}'
|
|
62
|
-
shadow-primary: '{colors.navy-800}'
|
|
63
|
-
shadow-secondary: '{colors.navy-600}'
|
|
64
|
-
typography:
|
|
65
|
-
base:
|
|
66
|
-
fontFamily: '"Apercu", -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif'
|
|
67
|
-
fontSize: '1rem'
|
|
68
|
-
fontWeight: '400'
|
|
69
|
-
lineHeight: '1.5'
|
|
70
|
-
accent:
|
|
71
|
-
fontFamily: '"Suisse", "Apercu", -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif'
|
|
72
|
-
fontSize: '0.875rem'
|
|
73
|
-
fontWeight: '400'
|
|
74
|
-
lineHeight: '1.5'
|
|
75
|
-
title:
|
|
76
|
-
fontFamily: '"Apercu", -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif'
|
|
77
|
-
fontSize: '2.125rem'
|
|
78
|
-
fontWeight: '700'
|
|
79
|
-
lineHeight: '1.2'
|
|
80
|
-
monospace:
|
|
81
|
-
fontFamily: 'Monaco, Menlo, "Ubuntu Mono", "Droid Sans Mono", Consolas, monospace'
|
|
82
|
-
system:
|
|
83
|
-
fontFamily: '-apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif'
|
|
84
|
-
'14':
|
|
85
|
-
fontSize: '0.875rem'
|
|
86
|
-
'16':
|
|
87
|
-
fontSize: '1rem'
|
|
88
|
-
'18':
|
|
89
|
-
fontSize: '1.125rem'
|
|
90
|
-
'20':
|
|
91
|
-
fontSize: '1.25rem'
|
|
92
|
-
'22':
|
|
93
|
-
fontSize: '1.375rem'
|
|
94
|
-
'26':
|
|
95
|
-
fontSize: '1.625rem'
|
|
96
|
-
'34':
|
|
97
|
-
fontSize: '2.125rem'
|
|
98
|
-
'44':
|
|
99
|
-
fontSize: '2.75rem'
|
|
100
|
-
'64':
|
|
101
|
-
fontSize: '4rem'
|
|
102
|
-
borderRadii:
|
|
103
|
-
none: '0px'
|
|
104
|
-
sm: '2px'
|
|
105
|
-
md: '4px'
|
|
106
|
-
lg: '8px'
|
|
107
|
-
xl: '16px'
|
|
108
|
-
full: '999px'
|
|
109
|
-
spacing:
|
|
110
|
-
'0': '0'
|
|
111
|
-
'4': '0.25rem'
|
|
112
|
-
'8': '0.5rem'
|
|
113
|
-
'12': '0.75rem'
|
|
114
|
-
'16': '1rem'
|
|
115
|
-
'24': '1.5rem'
|
|
116
|
-
'32': '2rem'
|
|
117
|
-
'40': '2.5rem'
|
|
118
|
-
'48': '3rem'
|
|
119
|
-
'64': '4rem'
|
|
120
|
-
'96': '6rem'
|
|
121
|
-
components:
|
|
122
|
-
FillButton:
|
|
123
|
-
backgroundColor: '{colors.primary}'
|
|
124
|
-
textColor: '{colors.white}'
|
|
125
|
-
borderRadii: '{borderRadii.md}'
|
|
126
|
-
FillButton-hover:
|
|
127
|
-
backgroundColor: '{colors.primary-hover}'
|
|
128
|
-
textColor: '{colors.white}'
|
|
129
|
-
FillButton-danger:
|
|
130
|
-
backgroundColor: '{colors.danger}'
|
|
131
|
-
textColor: '{colors.white}'
|
|
132
|
-
borderRadii: '{borderRadii.md}'
|
|
133
|
-
FillButton-danger-hover:
|
|
134
|
-
backgroundColor: '{colors.danger-hover}'
|
|
135
|
-
textColor: '{colors.white}'
|
|
136
|
-
StrokeButton:
|
|
137
|
-
backgroundColor: 'transparent'
|
|
138
|
-
textColor: '{colors.secondary}'
|
|
139
|
-
borderRadii: '{borderRadii.md}'
|
|
140
|
-
StrokeButton-hover:
|
|
141
|
-
textColor: '{colors.secondary-hover}'
|
|
142
|
-
IconButton:
|
|
143
|
-
backgroundColor: 'transparent'
|
|
144
|
-
textColor: '{colors.secondary}'
|
|
145
|
-
IconButton-hover:
|
|
146
|
-
textColor: '{colors.secondary-hover}'
|
|
147
|
-
CTAButton:
|
|
148
|
-
backgroundColor: '{colors.primary}'
|
|
149
|
-
textColor: '{colors.white}'
|
|
150
|
-
borderRadii: '{borderRadii.md}'
|
|
151
|
-
CTAButton-inverse:
|
|
152
|
-
backgroundColor: '{colors.primary-inverse}'
|
|
153
|
-
textColor: '{colors.secondary}'
|
|
154
|
-
borderRadii: '{borderRadii.md}'
|
|
155
|
-
TextButton:
|
|
156
|
-
backgroundColor: 'transparent'
|
|
157
|
-
textColor: '{colors.primary}'
|
|
158
|
-
TextButton-hover:
|
|
159
|
-
textColor: '{colors.primary-hover}'
|
|
160
|
-
Card:
|
|
161
|
-
backgroundColor: '{colors.background}'
|
|
162
|
-
borderRadii: '{borderRadii.none}'
|
|
163
|
-
Card-interactive:
|
|
164
|
-
borderRadii: '{borderRadii.md}'
|
|
165
|
-
Card-elevated:
|
|
166
|
-
backgroundColor: '{colors.background-primary}'
|
|
167
|
-
borderRadii: '{borderRadii.lg}'
|
|
168
|
-
Card-beige:
|
|
169
|
-
backgroundColor: '{colors.beige}'
|
|
170
|
-
borderRadii: '{borderRadii.lg}'
|
|
171
|
-
Input:
|
|
172
|
-
backgroundColor: '{colors.background}'
|
|
173
|
-
textColor: '{colors.text}'
|
|
174
|
-
borderRadii: '{borderRadii.md}'
|
|
175
|
-
Checkbox:
|
|
176
|
-
backgroundColor: '{colors.primary}'
|
|
177
|
-
borderRadii: '{borderRadii.sm}'
|
|
178
|
-
Checkbox-hover:
|
|
179
|
-
backgroundColor: '{colors.primary-hover}'
|
|
180
|
-
Headline:
|
|
181
|
-
textColor: '{colors.text-accent}'
|
|
182
|
-
typography: '{typography.title}'
|
|
183
|
-
Tag-success:
|
|
184
|
-
backgroundColor: '{colors.feedback-success}'
|
|
185
|
-
textColor: '{colors.white}'
|
|
186
|
-
borderRadii: '{borderRadii.sm}'
|
|
187
|
-
Tag-warning:
|
|
188
|
-
backgroundColor: '{colors.feedback-warning}'
|
|
189
|
-
textColor: '{colors.text}'
|
|
190
|
-
borderRadii: '{borderRadii.sm}'
|
|
191
|
-
Alert-error:
|
|
192
|
-
backgroundColor: '{colors.background-error}'
|
|
193
|
-
textColor: '{colors.feedback-error}'
|
|
194
|
-
Alert-success:
|
|
195
|
-
backgroundColor: '{colors.background-success}'
|
|
196
|
-
textColor: '{colors.text}'
|
|
197
|
-
Alert-warning:
|
|
198
|
-
backgroundColor: '{colors.background-warning}'
|
|
199
|
-
textColor: '{colors.text}'
|
|
200
|
-
---
|
|
201
|
-
|
|
202
|
-
# Codecademy
|
|
203
|
-
|
|
204
|
-
This file defines the visual design tokens for codecademy.com, implemented using the Gamut design system (`@codecademy/gamut`, `@codecademy/gamut-styles`). Gamut ships 52 components with Figma ↔ code mappings via Figma Code Connect.
|
|
205
|
-
|
|
206
|
-
Figma file: https://www.figma.com/design/ReGfRNillGABAj5SlITalN/📐-Gamut
|
|
207
|
-
Storybook: https://gamut.codecademy.com
|
|
208
|
-
|
|
209
|
-
---
|
|
210
|
-
|
|
211
|
-
## Overview
|
|
212
|
-
|
|
213
|
-
Codecademy communicates logic with personality — structured and trustworthy enough for a learning platform, with creative moments that feel engaging and human. The design voice is: _"we are ruled by logic, but are creative and a bit unexpected as well."_
|
|
214
|
-
|
|
215
|
-
Density: Medium. Information-dense layouts use careful whitespace and strong typographic hierarchy to stay readable. Avoid cramped or overly airy layouts.
|
|
216
|
-
|
|
217
|
-
Design philosophy:
|
|
218
|
-
|
|
219
|
-
- Components are color mode–aware by default — never hardcode hex values for adaptive UI
|
|
220
|
-
- Every component works across all themes without modification
|
|
221
|
-
- Mobile-first responsive design built on a 12-column grid
|
|
222
|
-
- Use semantic tokens (`background-primary`, not raw `beige`) so colors adapt across themes and modes
|
|
223
|
-
|
|
224
|
-
### Themes
|
|
225
|
-
|
|
226
|
-
Codecademy products use three Gamut themes, all sharing the same core visual identity. Token aliases resolve to the right values per theme automatically — components require no modification.
|
|
227
|
-
|
|
228
|
-
| Theme | Use case | Base font | Dark mode |
|
|
229
|
-
| -------- | ------------------------------- | --------- | -------------- |
|
|
230
|
-
| Core | Codecademy (default) | Apercu | ✓ light + dark |
|
|
231
|
-
| Admin | Codecademy admin tools | Apercu | ✓ light + dark |
|
|
232
|
-
| Platform | Codecademy learning environment | Apercu | ✓ light + dark |
|
|
233
|
-
|
|
234
|
-
Set the active theme at the app root via `<GamutProvider theme={theme}>` (or `adminTheme` / `platformTheme`). Install this file in app repos: `gamut plugin install cursor --theme core` (copies to `./DESIGN.md`).
|
|
235
|
-
|
|
236
|
-
For other Skillsoft products: `gamut plugin install cursor --theme percipio` or `--theme lxstudio` (see `DESIGN.Percipio.md`, `DESIGN.LXStudio.md`).
|
|
237
|
-
|
|
238
|
-
---
|
|
239
|
-
|
|
240
|
-
## Colors
|
|
241
|
-
|
|
242
|
-
Use semantic token names in code and designs. They resolve to the correct raw value for the active theme and color mode automatically. Never hardcode hex values for anything that needs to adapt across modes. Never hardcode core-theme values like `beige` — use `background-primary` and other semantic aliases.
|
|
243
|
-
|
|
244
|
-
For dark/light regions, use `<ColorMode>` or `<Background>` from `@codecademy/gamut-styles` — never swap colors manually with custom CSS.
|
|
245
|
-
|
|
246
|
-
### Text
|
|
247
|
-
|
|
248
|
-
| Token | Light | Dark | Use for |
|
|
249
|
-
| ---------------- | -------------------------- | --------------- | --------------------------- |
|
|
250
|
-
| `text` | navy-800 `#10162F` at 100% | white `#ffffff` | Default body and UI text |
|
|
251
|
-
| `text-accent` | navy-900 `#0A0D1C` | beige `#FFF0E5` | Stronger emphasis text |
|
|
252
|
-
| `text-secondary` | navy-800 at 75% | white at 65% | Supporting / secondary copy |
|
|
253
|
-
| `text-disabled` | navy-800 at 63% | white at 50% | Disabled state labels |
|
|
254
|
-
|
|
255
|
-
### Background
|
|
256
|
-
|
|
257
|
-
| Token | Light | Dark | Use for |
|
|
258
|
-
| --------------------- | ------------------ | -------------------- | --------------------------------- |
|
|
259
|
-
| `background` | white `#ffffff` | navy-800 `#10162F` | Default page/component background |
|
|
260
|
-
| `background-primary` | beige `#FFF0E5` | navy-900 `#0A0D1C` | Slightly elevated surfaces |
|
|
261
|
-
| `background-contrast` | white | black `#000000` | Maximum contrast surface |
|
|
262
|
-
| `background-selected` | navy-800 at 4% | white at 4% | Selected row / item |
|
|
263
|
-
| `background-hover` | navy-800 at 12% | white at 9% | Hover state overlay |
|
|
264
|
-
| `background-disabled` | navy-800 at 12% | white at 9% | Disabled surface |
|
|
265
|
-
| `background-success` | green-0 `#F5FFE3` | green-900 `#151C07` | Success state container |
|
|
266
|
-
| `background-warning` | yellow-0 `#FFFAE5` | yellow-900 `#211B00` | Warning state container |
|
|
267
|
-
| `background-error` | red-0 `#FBF1F0` | red-900 `#280503` | Error state container |
|
|
268
|
-
|
|
269
|
-
### Interactive
|
|
270
|
-
|
|
271
|
-
| Token | Light | Dark | Use for |
|
|
272
|
-
| ----------------- | -------------------- | -------------------- | ------------------------------------ |
|
|
273
|
-
| `primary` | hyper-500 `#3A10E5` | yellow-500 `#FFD300` | Primary CTA, links, focus rings |
|
|
274
|
-
| `primary-hover` | hyper-400 `#5533FF` | yellow-400 `#CCA900` | Hover state of primary interactive |
|
|
275
|
-
| `primary-inverse` | yellow-500 `#FFD300` | hyper-500 `#3A10E5` | Primary on a colored background |
|
|
276
|
-
| `secondary` | navy-800 `#10162F` | white `#ffffff` | Secondary CTA, ghost buttons |
|
|
277
|
-
| `secondary-hover` | navy-800 at 86% | white at 80% | Hover state of secondary interactive |
|
|
278
|
-
| `danger` | red-500 `#E91C11` | red-300 `#E85D7F` | Destructive actions, error states |
|
|
279
|
-
| `danger-hover` | red-600 `#BE1809` | red-400 `#DC5879` | Hover on danger interactive |
|
|
280
|
-
|
|
281
|
-
### Border
|
|
282
|
-
|
|
283
|
-
| Token | Light | Dark | Use for |
|
|
284
|
-
| ------------------ | ------------------ | --------------- | -------------------------- |
|
|
285
|
-
| `border-primary` | navy-800 `#10162F` | white `#ffffff` | Strong borders, dividers |
|
|
286
|
-
| `border-secondary` | navy-800 at 75% | white at 65% | Medium-weight borders |
|
|
287
|
-
| `border-tertiary` | navy-800 at 28% | white at 20% | Subtle borders, separators |
|
|
288
|
-
| `border-disabled` | navy-800 at 63% | white at 50% | Disabled input borders |
|
|
289
|
-
|
|
290
|
-
### Feedback
|
|
291
|
-
|
|
292
|
-
| Token | Light | Dark | Use for |
|
|
293
|
-
| ------------------ | ------------------- | ------------------- | -------------------------------- |
|
|
294
|
-
| `feedback-error` | red-600 `#BE1809` | red-300 `#E85D7F` | Error messages, validation |
|
|
295
|
-
| `feedback-success` | green-700 `#008A27` | green-400 `#AEE938` | Success messages, confirmations |
|
|
296
|
-
| `feedback-warning` | yellow `#FFD300` | yellow-0 `#FFFAE5` | Warning messages, caution states |
|
|
297
|
-
|
|
298
|
-
### Shadow
|
|
299
|
-
|
|
300
|
-
| Token | Light | Dark |
|
|
301
|
-
| ------------------ | --------------- | ------------ |
|
|
302
|
-
| `shadow-primary` | navy-800 | white |
|
|
303
|
-
| `shadow-secondary` | navy-800 at 75% | white at 65% |
|
|
304
|
-
|
|
305
|
-
---
|
|
306
|
-
|
|
307
|
-
### Raw color palette
|
|
308
|
-
|
|
309
|
-
All colors available as static tokens regardless of color mode. Use these only when a color should be fixed and not adapt to dark mode (e.g. `<Background bg="navy">` on Codecademy-branded surfaces).
|
|
310
|
-
|
|
311
|
-
#### Core palette
|
|
312
|
-
|
|
313
|
-
| Name | Weights available | Notes |
|
|
314
|
-
| --------------- | ---------------------------- | --------------------------------------------------------------------------------- |
|
|
315
|
-
| `navy` | 100–900 | 100–700 are rgba transparencies of `#10162F`; 800 = `#10162F`; 900 = `#0A0D1C` |
|
|
316
|
-
| `white` | 100–700 | rgba transparencies of `#ffffff` (no solid white weight — use `white` for `#fff`) |
|
|
317
|
-
| `blue` | 0, 100, 300, 400, 500, 800 | 500 = `#1557FF` |
|
|
318
|
-
| `hyper` | 400, 500 | 500 = `#3A10E5` (purple-blue), 400 = `#5533FF` |
|
|
319
|
-
| `green` | 0, 100, 400, 700, 900 | 700 = `#008A27` |
|
|
320
|
-
| `yellow` | 0, 400, 500, 900 | 500 = `#FFD300` |
|
|
321
|
-
| `red` | 0, 300, 400, 500, 600, 900 | 500 = `#E91C11` |
|
|
322
|
-
| `gray` | 100, 200, 300, 600, 800, 900 | |
|
|
323
|
-
| `pink` | 0, 400 | 400 = `#F966FF` |
|
|
324
|
-
| `orange` | 100, 500 | 500 = `#FF8C00` |
|
|
325
|
-
| `beige` | 100 (alias: `beige`) | `#FFF0E5` |
|
|
326
|
-
| `black` | — | `#000000` |
|
|
327
|
-
| `white` (solid) | — | `#ffffff` |
|
|
328
|
-
|
|
329
|
-
Named aliases (shorthand for common weights):
|
|
330
|
-
`beige`, `blue`, `green`, `hyper`, `lightBlue`, `lightGreen`, `navy`, `orange`, `paleBlue`, `paleGreen`, `palePink`, `paleRed`, `paleYellow`, `pink`, `red`, `yellow`, `black`, `white`
|
|
331
|
-
|
|
332
|
-
#### Platform-only additions
|
|
333
|
-
|
|
334
|
-
`lightBeige` (`#FFFBF8`), `gold` (`#8A7300`), `teal` (`#006D82`), `purple` (`#B3CCFF`)
|
|
335
|
-
|
|
336
|
-
---
|
|
337
|
-
|
|
338
|
-
## Typography
|
|
339
|
-
|
|
340
|
-
### Typefaces
|
|
341
|
-
|
|
342
|
-
| Token | Font | Use for |
|
|
343
|
-
| ----------- | -------------------------------------------------------- | ------------------------------------------------ |
|
|
344
|
-
| `base` | Apercu Pro (CSS: `Apercu`) | All default UI text, headlines, body copy |
|
|
345
|
-
| `accent` | Suisse Intl Mono (CSS: `Suisse`); falls back to `Apercu` | Code, captions, labels, lists, technical context |
|
|
346
|
-
| `monospace` | Monaco, Menlo, Ubuntu Mono, Droid Sans Mono, Consolas | Code editor contexts |
|
|
347
|
-
| `system` | System UI fonts | Performance-critical surfaces |
|
|
348
|
-
|
|
349
|
-
### Rules
|
|
350
|
-
|
|
351
|
-
- Apercu Bold for headlines, sub-headlines, CTAs, and buttons.
|
|
352
|
-
- Apercu Regular for body text, UI labels, and menu items.
|
|
353
|
-
- Apercu Italic to emphasize text within a Regular paragraph — not Bold.
|
|
354
|
-
- Suisse sparingly: code snippets, enumerated items, quotations, captions. Reads 10–15% large for its point size — size down relative to Apercu (14px Suisse ≈ 16px Apercu visually).
|
|
355
|
-
- Text is left-aligned by default. Center-align only for short marketing headlines. Never right-align.
|
|
356
|
-
- Do not adjust letter-spacing.
|
|
357
|
-
|
|
358
|
-
### Font size scale
|
|
359
|
-
|
|
360
|
-
| Token key | Size | Common use |
|
|
361
|
-
| --------- | ---- | ---------------------------- |
|
|
362
|
-
| `64` | 64px | Hero / display |
|
|
363
|
-
| `44` | 44px | Page titles |
|
|
364
|
-
| `34` | 34px | Section titles |
|
|
365
|
-
| `26` | 26px | Sub-section titles |
|
|
366
|
-
| `22` | 22px | Card titles, large UI labels |
|
|
367
|
-
| `20` | 20px | Secondary titles |
|
|
368
|
-
| `18` | 18px | Large body, intro text |
|
|
369
|
-
| `16` | 16px | Default body text |
|
|
370
|
-
| `14` | 14px | Small body, captions, labels |
|
|
371
|
-
|
|
372
|
-
### Font weight scale
|
|
373
|
-
|
|
374
|
-
| Token | Value | Use |
|
|
375
|
-
| ------- | ----- | ------------------------ |
|
|
376
|
-
| `base` | 400 | Body text, UI labels |
|
|
377
|
-
| `title` | 700 | Headlines, CTAs, buttons |
|
|
378
|
-
|
|
379
|
-
### Line height scale
|
|
380
|
-
|
|
381
|
-
| Token | Value | Use |
|
|
382
|
-
| ------------- | ----- | ------------------------------------------------ |
|
|
383
|
-
| `base` | 1.5 | Body text (150% — aim for 150–175% of font size) |
|
|
384
|
-
| `spacedTitle` | 1.3 | Sub-headlines and medium titles |
|
|
385
|
-
| `title` | 1.2 | Large headlines (aim for 100–110% of font size) |
|
|
386
|
-
|
|
387
|
-
### Line length
|
|
388
|
-
|
|
389
|
-
Target 45–85 characters per line; 66 characters is ideal for web body text. Max 50 characters for multi-column layouts.
|
|
390
|
-
|
|
391
|
-
---
|
|
392
|
-
|
|
393
|
-
## Layout
|
|
394
|
-
|
|
395
|
-
### Spacing scale
|
|
396
|
-
|
|
397
|
-
All spacing is multiples of 4px, placed on an 8px grid. Use only these values for padding, margin, gap, width, and height — snap to the nearest token if a design specifies an off-scale value.
|
|
398
|
-
|
|
399
|
-
| Token | Value |
|
|
400
|
-
| ----- | ----- |
|
|
401
|
-
| `0` | 0 |
|
|
402
|
-
| `4` | 4px |
|
|
403
|
-
| `8` | 8px |
|
|
404
|
-
| `12` | 12px |
|
|
405
|
-
| `16` | 16px |
|
|
406
|
-
| `24` | 24px |
|
|
407
|
-
| `32` | 32px |
|
|
408
|
-
| `40` | 40px |
|
|
409
|
-
| `48` | 48px |
|
|
410
|
-
| `64` | 64px |
|
|
411
|
-
| `96` | 96px |
|
|
412
|
-
|
|
413
|
-
Use multiples of 8px for block-element spacing; 4px only for inline or typographic relationships.
|
|
414
|
-
|
|
415
|
-
### System props
|
|
416
|
-
|
|
417
|
-
Never use inline `style` attributes. Use system props from `@codecademy/gamut-styles` with shorthand names:
|
|
418
|
-
|
|
419
|
-
| Long form | Shorthand |
|
|
420
|
-
| --------------- | --------- |
|
|
421
|
-
| `margin` | `m` |
|
|
422
|
-
| `marginTop` | `mt` |
|
|
423
|
-
| `marginBottom` | `mb` |
|
|
424
|
-
| `marginLeft` | `ml` |
|
|
425
|
-
| `marginRight` | `mr` |
|
|
426
|
-
| `marginX` | `mx` |
|
|
427
|
-
| `marginY` | `my` |
|
|
428
|
-
| `padding` | `p` |
|
|
429
|
-
| `paddingTop` | `pt` |
|
|
430
|
-
| `paddingBottom` | `pb` |
|
|
431
|
-
| `paddingLeft` | `pl` |
|
|
432
|
-
| `paddingRight` | `pr` |
|
|
433
|
-
| `paddingX` | `px` |
|
|
434
|
-
| `paddingY` | `py` |
|
|
435
|
-
|
|
436
|
-
Use `mb={16}`, not `marginBottom={16}`. Color and border props: `bg`, `color` / `textColor`, `borderColor`, `borderRadius` — values must be Gamut tokens, never raw hex.
|
|
437
|
-
|
|
438
|
-
### Responsive behavior
|
|
439
|
-
|
|
440
|
-
Mobile-first. Apply styles from the named breakpoint and up.
|
|
441
|
-
|
|
442
|
-
| Token | Min-width | Screen dimensions | Max content | Fold height |
|
|
443
|
-
| -------- | --------- | ----------------- | ----------- | ----------- |
|
|
444
|
-
| _(base)_ | 0 | 320×480 | 288px | 440px |
|
|
445
|
-
| `xs` | 480px | 480×900 | 448px | 440px |
|
|
446
|
-
| `sm` | 768px | 768×1024 | 704px | 680px |
|
|
447
|
-
| `md` | 1024px | 1024×768 | 896px | 680px |
|
|
448
|
-
| `lg` | 1200px | 1200×900 | 1072px | 680px |
|
|
449
|
-
| `xl` | 1440px | 1440×900 | 1248px | 680px |
|
|
450
|
-
|
|
451
|
-
Container query variants (`c_xs` through `c_xl`) mirror these values but trigger on component container size, not viewport.
|
|
452
|
-
|
|
453
|
-
Grid: 12-column grid at all breakpoints.
|
|
454
|
-
|
|
455
|
-
| Usage | Recommended values |
|
|
456
|
-
| --------------------- | ------------------------------------------------ |
|
|
457
|
-
| Horizontal margins | 64px (lg+), 48px (md), 32px (sm/xs), 16px (base) |
|
|
458
|
-
| Column gaps (gutters) | 32px (lg+), 24px (md), 16px (sm/xs), 8px (base) |
|
|
459
|
-
| Row gaps | 32px (lg+), 24px (md), 16px (sm/xs), 8px (base) |
|
|
460
|
-
|
|
461
|
-
Minimum interactive touch target: 44×44px on mobile breakpoints.
|
|
462
|
-
|
|
463
|
-
- Begin design work at 1440px (XL), then adapt down.
|
|
464
|
-
- Wider multi-column layouts collapse to fewer columns — do not stretch or squish.
|
|
465
|
-
- Avoid dense or small components in the base (mobile) breakpoint.
|
|
466
|
-
|
|
467
|
-
### Global layout tokens
|
|
468
|
-
|
|
469
|
-
| Token | Value | Use |
|
|
470
|
-
| -------------- | -------------------------------------- | ------------------------------- |
|
|
471
|
-
| `headerHeight` | 4rem (64px) base, 5rem (80px) at `md`+ | Global page header height |
|
|
472
|
-
| `headerZ` | 15 | Z-index for global page headers |
|
|
473
|
-
|
|
474
|
-
---
|
|
475
|
-
|
|
476
|
-
## Elevation & Depth
|
|
477
|
-
|
|
478
|
-
Gamut uses border-based and shadow-based depth cues rather than a rigid z-elevation tier system.
|
|
479
|
-
|
|
480
|
-
### Shadow tokens
|
|
481
|
-
|
|
482
|
-
Shadow props accept standard CSS `box-shadow` syntax. Always use `shadow-primary` / `shadow-secondary` color tokens so shadows remain visible in both light and dark modes.
|
|
483
|
-
|
|
484
|
-
```
|
|
485
|
-
box-shadow: 0 4px 0 <shadow-primary> → Card "outline" shadow
|
|
486
|
-
box-shadow: 0 0 4px rgba(0,0,0,.15) → Subtle ambient shadow
|
|
487
|
-
```
|
|
488
|
-
|
|
489
|
-
### Card shadow variants
|
|
490
|
-
|
|
491
|
-
| Variant | Effect | Use for |
|
|
492
|
-
| ---------------- | ------------------------------------------------------ | ------------------------------ |
|
|
493
|
-
| `none` (default) | No shadow | Static / non-interactive cards |
|
|
494
|
-
| `outline` | Solid shadow on bottom + left/right using border color | Standard clickable cards |
|
|
495
|
-
| `patternLeft` | Decorative checker pattern on bottom + left | Stylized content cards |
|
|
496
|
-
| `patternRight` | Decorative checker pattern on bottom + right | Stylized content cards |
|
|
497
|
-
|
|
498
|
-
Interactive cards (`isInteractive` prop) gain a shadow on hover and `borderRadius: md`. Cards with a pattern drop the pattern on hover.
|
|
499
|
-
|
|
500
|
-
### Z-index
|
|
501
|
-
|
|
502
|
-
| Token | Value | Use |
|
|
503
|
-
| --------- | ----- | ------------------ |
|
|
504
|
-
| `headerZ` | 15 | Global page header |
|
|
505
|
-
|
|
506
|
-
---
|
|
507
|
-
|
|
508
|
-
## Shapes
|
|
509
|
-
|
|
510
|
-
Border radius tokens from `borderRadii` in `@codecademy/gamut-styles`. No custom radius values.
|
|
511
|
-
|
|
512
|
-
| Token | Value | Use |
|
|
513
|
-
| ------ | ----- | ------------------------------------------ |
|
|
514
|
-
| `none` | 0px | Square / non-interactive elements |
|
|
515
|
-
| `sm` | 2px | Subtle rounding, tags, checkboxes |
|
|
516
|
-
| `md` | 4px | Default buttons, inputs, interactive cards |
|
|
517
|
-
| `lg` | 8px | Cards, panels |
|
|
518
|
-
| `xl` | 16px | Large cards, modals |
|
|
519
|
-
| `full` | 999px | Pills, avatars, circular elements |
|
|
520
|
-
|
|
521
|
-
---
|
|
522
|
-
|
|
523
|
-
## Components
|
|
524
|
-
|
|
525
|
-
### Component catalog
|
|
526
|
-
|
|
527
|
-
Components are organized into three tiers:
|
|
528
|
-
|
|
529
|
-
### Atoms — foundational, single-purpose
|
|
530
|
-
|
|
531
|
-
Badge, Button (FillButton, StrokeButton, CTAButton, TextButton, IconButton), ButtonBase, Card, Checkbox, CodeBlock, ColorMode, Drawer, FlexBox, FormGroup, GridBox, HiddenText, Icon, Input, Label, Loader, Radio, Select, Spinner, Tag, TextArea, Toggle, Tooltip
|
|
532
|
-
|
|
533
|
-
### Molecules — composed of atoms, handle a discrete task
|
|
534
|
-
|
|
535
|
-
Alert, Anchor, Breadcrumbs, Coachmark, Disclosure, GridForm, Markdown, Menu, Modal, Pagination, Popover, ProgressBar, Table, Tabs, Toast, Toaster, Video
|
|
536
|
-
|
|
537
|
-
### Organisms — page-level compositions
|
|
538
|
-
|
|
539
|
-
ContentContainer, GridContainer, Layout, LayoutGrid
|
|
540
|
-
|
|
541
|
-
### Key component patterns
|
|
542
|
-
|
|
543
|
-
#### Buttons
|
|
544
|
-
|
|
545
|
-
There is no generic `Button` component. Use the variant that matches intent:
|
|
546
|
-
|
|
547
|
-
| Variant | Component | Use for |
|
|
548
|
-
| ----------------- | -------------- | ----------------------------------- |
|
|
549
|
-
| Primary action | `FillButton` | Solid fill, high-emphasis CTA |
|
|
550
|
-
| Secondary action | `StrokeButton` | Outlined, secondary CTA |
|
|
551
|
-
| Marketing CTA | `CTAButton` | High-visibility promotional actions |
|
|
552
|
-
| Tertiary / inline | `TextButton` | Low-emphasis, inline text actions |
|
|
553
|
-
| Icon-only | `IconButton` | Compact actions with icon only |
|
|
554
|
-
|
|
555
|
-
- `IconButton` requires `tip` for screen reader accessibility.
|
|
556
|
-
- Never set `mode` on buttons — they inherit color context from parent wrappers.
|
|
557
|
-
- Sizes: `small`, `normal` (default), `large`. Support `icon`, `disabled`, and `href` (renders as `<a>`).
|
|
558
|
-
- States: default → hover (`primary-hover` / `secondary-hover`) → active → disabled (`text-disabled` + `background-disabled`).
|
|
559
|
-
|
|
560
|
-
#### Cards
|
|
561
|
-
|
|
562
|
-
- Valid `variant` values: `default`, `white`, `yellow`, `beige`, `navy`, `hyper` — never invent compound names (invalid values crash `parseToHsl()`).
|
|
563
|
-
- Defaults: `shadow="none"`, `isInteractive={false}`.
|
|
564
|
-
- Set `isInteractive` only when the card is a link or has click/hover interaction (e.g. wrapped in `<Anchor>`); interactive cards get hover shadow and `borderRadius: md`.
|
|
565
|
-
- Shadow variants: `none` (default), `outline`, `patternLeft`, `patternRight`.
|
|
566
|
-
|
|
567
|
-
#### Color-aware components
|
|
568
|
-
|
|
569
|
-
- `<ColorMode mode="light|dark|system">` — explicit mode when you know which mode a region should use.
|
|
570
|
-
- `<Background bg="<color>">` — dynamic background; Gamut picks contrast-safe inner mode. Prefer over raw `bg` on content-bearing surfaces.
|
|
571
|
-
|
|
572
|
-
### Gamut implementation guardrails
|
|
573
|
-
|
|
574
|
-
#### Component discovery
|
|
575
|
-
|
|
576
|
-
1. Inspect `@codecademy/gamut` exports before building custom UI for a pattern.
|
|
577
|
-
2. Prefer Gamut components (`Menu`, `DataTable`, `Tabs`, `Video`, etc.) over raw HTML.
|
|
578
|
-
3. Read component TypeScript definitions before using `variant` / color props.
|
|
579
|
-
4. If no Gamut component exists: `{/* No Gamut component available for [pattern] — using custom markup */}`
|
|
580
|
-
|
|
581
|
-
#### Forms
|
|
582
|
-
|
|
583
|
-
- Submit/save flows (validation, bundled fields, dirty tracking): use `GridForm` or `ConnectedForm`.
|
|
584
|
-
- Live filters / standalone controls (no submit step): use atoms (`Input`, `Select`, `Checkbox`, `Radio`, `TextArea`, `FormGroup`) directly.
|
|
585
|
-
- Always provide `defaultValues`; use `validation="onChange"` when the submit button should stay disabled until valid.
|
|
586
|
-
- Set `hideLabel: true` on checkbox, radio, or toggle fields without a meaningful `label`.
|
|
587
|
-
|
|
588
|
-
#### DataTable / DataList
|
|
589
|
-
|
|
590
|
-
- `sortable: true` on a column requires `query`, `onQueryChange`, and client-sorted `rows` — Gamut does not sort data internally.
|
|
591
|
-
|
|
592
|
-
#### Menu
|
|
593
|
-
|
|
594
|
-
- Always set `variant` explicitly: `fixed` + `as="nav"` for persistent navigation (sidebars, primary nav); `popover` for overflow/action menus.
|
|
595
|
-
- Do not let flex-stretching ancestors expand `Menu` to fill vertical space — wrap in intrinsic-height containers.
|
|
596
|
-
|
|
597
|
-
#### Accessibility
|
|
598
|
-
|
|
599
|
-
- Meet WCAG contrast and 44×44px minimum touch targets on mobile.
|
|
600
|
-
- Use `FocusTrap` inside modals, dialogs, drawers, and other focus-confined regions.
|
|
601
|
-
|
|
602
|
-
#### Assets
|
|
603
|
-
|
|
604
|
-
- Icons: `@codecademy/gamut-icons` — verify icons exist; do not trust stale Figma layer names.
|
|
605
|
-
- Illustrations: `@codecademy/gamut-illustrations`
|
|
606
|
-
- Patterns: `@codecademy/gamut-patterns`
|
|
607
|
-
|
|
608
|
-
---
|
|
609
|
-
|
|
610
|
-
## Do's and Don'ts
|
|
611
|
-
|
|
612
|
-
### Colors
|
|
613
|
-
|
|
614
|
-
- Do use semantic color aliases (`primary`, `text`, `background`, etc.) for any UI that must adapt to color mode or theme.
|
|
615
|
-
- Do use `<Background bg="...">` when setting a section background — it adjusts the inner color mode for contrast automatically.
|
|
616
|
-
- Don't hardcode hex values for anything adaptive.
|
|
617
|
-
- Don't use navy or white semi-transparent swatches where they may overlap unpredictably.
|
|
618
|
-
|
|
619
|
-
### Typography
|
|
620
|
-
|
|
621
|
-
- Do use `title` weight (700) for headlines, CTAs, and buttons.
|
|
622
|
-
- Do keep body text at 150–175% line height for readability.
|
|
623
|
-
- Do use Suisse sparingly — as an accent for code, captions, and lists only.
|
|
624
|
-
- Don't use Apercu Bold to emphasize text _within_ a paragraph — use Italic instead.
|
|
625
|
-
- Don't adjust letter-spacing.
|
|
626
|
-
- Don't right-align text in normal circumstances.
|
|
627
|
-
- Don't center-align body paragraphs with long line lengths.
|
|
628
|
-
|
|
629
|
-
### Layout & Spacing
|
|
630
|
-
|
|
631
|
-
- Do use multiples of 8px for block-element spacing (4px only for inline / typographic relationships).
|
|
632
|
-
- Do begin design work at 1440px (XL), then adapt down to each breakpoint.
|
|
633
|
-
- Do align elements to the 12-column grid.
|
|
634
|
-
- Don't stretch elements to fill wider space — maintain proper line lengths and component widths.
|
|
635
|
-
|
|
636
|
-
### Components
|
|
637
|
-
|
|
638
|
-
- Do use `FillButton` for primary actions and `StrokeButton` for secondary actions.
|
|
639
|
-
- Do add `isInteractive` only to `Card` components that are links or otherwise interactive.
|
|
640
|
-
- Don't import a generic `Button` — it does not exist in Gamut.
|
|
641
|
-
- Don't use `CTAButton` for standard UI actions — reserve it for marketing/high-visibility promotions.
|
|
642
|
-
- Don't use `<Background>` without an actual color value — it's not a neutral wrapper.
|
|
643
|
-
- Don't use bare form atoms for functional forms — use `GridForm` or `ConnectedForm`.
|
|
644
|
-
|
|
645
|
-
### Pre-ship validation
|
|
646
|
-
|
|
647
|
-
Before considering UI output final, run `/gamut-review` from the app repository root (the directory that contains `DESIGN.md`). Install the plugin first if needed: Cursor — `gamut plugin install cursor --theme core`; Claude Code — `gamut plugin install claude --theme core` (use `admin` or `platform` for those Codecademy themes).
|
|
648
|
-
|
|
649
|
-
The command performs automated checks (dependencies, `GamutProvider`, imports, hex colors, tests, component guardrails) and prints a manual pre-ship checklist keyed to this product's theme. Fix all errors before shipping. Full procedure: [`commands/gamut-review.md`](commands/gamut-review.md) in `@codecademy/gamut` agent-tools (installed as a slash command with the Gamut plugin).
|
|
650
|
-
|
|
651
|
-
---
|
|
652
|
-
|
|
653
|
-
## Agent Prompt Guide
|
|
654
|
-
|
|
655
|
-
Quick color/token reference for generating or specifying UI:
|
|
656
|
-
|
|
657
|
-
| Scenario | Tokens |
|
|
658
|
-
| ---------------------- | ----------------------------------------------------------------------------------------------------- |
|
|
659
|
-
| Primary button (light) | `bg: primary (#3A10E5)`, `color: white`, `hover: primary-hover (#5533FF)` |
|
|
660
|
-
| Primary button (dark) | `bg: primary (#FFD300)`, `color: navy-800`, `hover: primary-hover (#CCA900)` |
|
|
661
|
-
| Body text | `color: text`, `font: base (Apercu Pro)`, `size: 16px`, `weight: 400`, `lineHeight: base (1.5)` |
|
|
662
|
-
| Headline | `color: text-accent`, `font: base`, `size: 34–64px`, `weight: title (700)`, `lineHeight: title (1.2)` |
|
|
663
|
-
| Caption / label | `color: text-secondary`, `font: accent (Suisse Int'l Mono)`, `size: 14px` |
|
|
664
|
-
| Card default | `bg: background`, `borderRadius: none` — add `isInteractive` for hover shadow + `borderRadius: md` |
|
|
665
|
-
| Error state | `color: feedback-error`, `bg: background-error`, `border: danger` |
|
|
666
|
-
| Success state | `color: feedback-success`, `bg: background-success` |
|
|
667
|
-
| Disabled state | `color: text-disabled`, `bg: background-disabled`, `border: border-disabled` |
|
|
668
|
-
|
|
669
|
-
### Component token cheatsheet
|
|
670
|
-
|
|
671
|
-
```
|
|
672
|
-
FillButton → bg: primary, color: white, hover: primary-hover
|
|
673
|
-
StrokeButton → bg: transparent, border: secondary, hover: secondary-hover
|
|
674
|
-
CTAButton → high-visibility; use primary-inverse on colored surfaces
|
|
675
|
-
Card (light) → variant: "default" | "white" | "yellow" | "beige"
|
|
676
|
-
Card (dark) → variant: "navy" | "hyper"
|
|
677
|
-
Alert (error) → uses feedback-error + background-error
|
|
678
|
-
Alert (success) → uses feedback-success + background-success
|
|
679
|
-
Alert (warning) → uses feedback-warning + background-warning
|
|
680
|
-
ColorMode → <ColorMode mode="light|dark|system">
|
|
681
|
-
Background → <Background bg="hyper"> — auto-flips color mode for contrast
|
|
682
|
-
```
|
|
683
|
-
|
|
684
|
-
---
|
|
685
|
-
|
|
686
|
-
## Figma ↔ Code Mapping
|
|
687
|
-
|
|
688
|
-
52 components have Code Connect entries in `packages/code-connect/`. These appear as live code snippets in Figma's inspect panel when you select a component.
|
|
689
|
-
|
|
690
|
-
Figma layer names use emojis as visual shorthand (e.g. `✏️ label`, `👁 leading icon`, `↳ trailing icon`). These map to named props in the React components.
|
|
691
|
-
|
|
692
|
-
To publish updated code snippets after changing a component:
|
|
693
|
-
|
|
694
|
-
```
|
|
695
|
-
npx figma connect publish --token <your-figma-token>
|
|
696
|
-
```
|