@graftwork/tokens 0.0.0-stage → 1.0.0

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.
@@ -0,0 +1,502 @@
1
+ {
2
+ "color": {
3
+ "surface": {
4
+ "$type": "color",
5
+ "$description": "Dark theme. surface tokens.",
6
+ "default": {
7
+ "$value": "{color.neutral.950}",
8
+ "$description": "Page background.",
9
+ "$extensions": {
10
+ "studio.graftwork": {
11
+ "role": "background"
12
+ }
13
+ }
14
+ },
15
+ "raised": {
16
+ "$value": "{color.neutral.900}",
17
+ "$description": "Cards and panels.",
18
+ "$extensions": {
19
+ "studio.graftwork": {
20
+ "role": "background"
21
+ }
22
+ }
23
+ },
24
+ "subtle": {
25
+ "$value": "{color.neutral.850}",
26
+ "$description": "Table headers, wells, zebra rows.",
27
+ "$extensions": {
28
+ "studio.graftwork": {
29
+ "role": "background"
30
+ }
31
+ }
32
+ },
33
+ "overlay": {
34
+ "$value": "{color.neutral.900}",
35
+ "$description": "Popovers, menus and dialogs.",
36
+ "$extensions": {
37
+ "studio.graftwork": {
38
+ "role": "background"
39
+ }
40
+ }
41
+ }
42
+ },
43
+ "action": {
44
+ "$type": "color",
45
+ "$description": "Dark theme. action tokens.",
46
+ "primary": {
47
+ "bg": {
48
+ "$value": "{color.brand.400}",
49
+ "$description": "Filled primary button.",
50
+ "$extensions": {
51
+ "studio.graftwork": {
52
+ "role": "background"
53
+ }
54
+ }
55
+ },
56
+ "bg-hover": {
57
+ "$value": "{color.brand.300}",
58
+ "$extensions": {
59
+ "studio.graftwork": {
60
+ "role": "background"
61
+ }
62
+ }
63
+ }
64
+ },
65
+ "secondary": {
66
+ "bg": {
67
+ "$value": "{color.neutral.900}",
68
+ "$description": "Secondary button.",
69
+ "$extensions": {
70
+ "studio.graftwork": {
71
+ "role": "background"
72
+ }
73
+ }
74
+ },
75
+ "bg-hover": {
76
+ "$value": "{color.neutral.850}",
77
+ "$extensions": {
78
+ "studio.graftwork": {
79
+ "role": "background"
80
+ }
81
+ }
82
+ }
83
+ },
84
+ "ghost": {
85
+ "bg-hover": {
86
+ "$value": "{color.neutral.850}",
87
+ "$description": "Ghost button hover.",
88
+ "$extensions": {
89
+ "studio.graftwork": {
90
+ "role": "background"
91
+ }
92
+ }
93
+ }
94
+ },
95
+ "destructive": {
96
+ "bg": {
97
+ "$value": "{color.red.400}",
98
+ "$description": "Filled destructive button.",
99
+ "$extensions": {
100
+ "studio.graftwork": {
101
+ "role": "background"
102
+ }
103
+ }
104
+ },
105
+ "bg-hover": {
106
+ "$value": "{color.red.300}",
107
+ "$extensions": {
108
+ "studio.graftwork": {
109
+ "role": "background"
110
+ }
111
+ }
112
+ }
113
+ }
114
+ },
115
+ "status": {
116
+ "$type": "color",
117
+ "$description": "Dark theme. status tokens.",
118
+ "success": {
119
+ "bg": {
120
+ "$value": "{color.green.950}",
121
+ "$extensions": {
122
+ "studio.graftwork": {
123
+ "role": "background"
124
+ }
125
+ }
126
+ }
127
+ },
128
+ "warning": {
129
+ "bg": {
130
+ "$value": "{color.amber.950}",
131
+ "$extensions": {
132
+ "studio.graftwork": {
133
+ "role": "background"
134
+ }
135
+ }
136
+ }
137
+ },
138
+ "error": {
139
+ "bg": {
140
+ "$value": "{color.red.950}",
141
+ "$extensions": {
142
+ "studio.graftwork": {
143
+ "role": "background"
144
+ }
145
+ }
146
+ }
147
+ },
148
+ "info": {
149
+ "bg": {
150
+ "$value": "{color.brand.950}",
151
+ "$extensions": {
152
+ "studio.graftwork": {
153
+ "role": "background"
154
+ }
155
+ }
156
+ }
157
+ }
158
+ },
159
+ "text": {
160
+ "$type": "color",
161
+ "$description": "Dark theme. text tokens.",
162
+ "default": {
163
+ "$value": "{color.neutral.50}",
164
+ "$description": "Body and heading text.",
165
+ "$extensions": {
166
+ "studio.graftwork": {
167
+ "role": "text",
168
+ "on": [
169
+ "{color.surface.default}",
170
+ "{color.surface.raised}",
171
+ "{color.surface.subtle}",
172
+ "{color.surface.overlay}",
173
+ "{color.action.secondary.bg}",
174
+ "{color.action.secondary.bg-hover}",
175
+ "{color.action.ghost.bg-hover}",
176
+ "{color.status.success.bg}",
177
+ "{color.status.warning.bg}",
178
+ "{color.status.error.bg}",
179
+ "{color.status.info.bg}"
180
+ ]
181
+ }
182
+ }
183
+ },
184
+ "secondary": {
185
+ "$value": "{color.neutral.300}",
186
+ "$description": "Supporting text. Still 7:1.",
187
+ "$extensions": {
188
+ "studio.graftwork": {
189
+ "role": "text",
190
+ "on": [
191
+ "{color.surface.default}",
192
+ "{color.surface.raised}",
193
+ "{color.surface.subtle}",
194
+ "{color.surface.overlay}"
195
+ ]
196
+ }
197
+ }
198
+ },
199
+ "placeholder": {
200
+ "$value": "{color.neutral.300}",
201
+ "$description": "Input placeholders. Still 7:1; never the only label.",
202
+ "$extensions": {
203
+ "studio.graftwork": {
204
+ "role": "text",
205
+ "on": [
206
+ "{color.surface.default}",
207
+ "{color.surface.raised}",
208
+ "{color.surface.overlay}"
209
+ ]
210
+ }
211
+ }
212
+ },
213
+ "link": {
214
+ "$value": "{color.brand.300}",
215
+ "$description": "Links. Always underlined as well.",
216
+ "$extensions": {
217
+ "studio.graftwork": {
218
+ "role": "text",
219
+ "on": [
220
+ "{color.surface.default}",
221
+ "{color.surface.raised}",
222
+ "{color.surface.subtle}",
223
+ "{color.surface.overlay}"
224
+ ]
225
+ }
226
+ }
227
+ },
228
+ "on-primary": {
229
+ "$value": "{color.neutral.950}",
230
+ "$description": "Labels on filled primary buttons.",
231
+ "$extensions": {
232
+ "studio.graftwork": {
233
+ "role": "text",
234
+ "on": [
235
+ "{color.action.primary.bg}",
236
+ "{color.action.primary.bg-hover}"
237
+ ]
238
+ }
239
+ }
240
+ },
241
+ "on-destructive": {
242
+ "$value": "{color.neutral.950}",
243
+ "$description": "Labels on filled destructive buttons.",
244
+ "$extensions": {
245
+ "studio.graftwork": {
246
+ "role": "text",
247
+ "on": [
248
+ "{color.action.destructive.bg}",
249
+ "{color.action.destructive.bg-hover}"
250
+ ]
251
+ }
252
+ }
253
+ },
254
+ "success": {
255
+ "$value": "{color.green.300}",
256
+ "$extensions": {
257
+ "studio.graftwork": {
258
+ "role": "text",
259
+ "on": [
260
+ "{color.surface.default}",
261
+ "{color.surface.raised}",
262
+ "{color.surface.subtle}",
263
+ "{color.status.success.bg}"
264
+ ]
265
+ }
266
+ }
267
+ },
268
+ "warning": {
269
+ "$value": "{color.amber.300}",
270
+ "$extensions": {
271
+ "studio.graftwork": {
272
+ "role": "text",
273
+ "on": [
274
+ "{color.surface.default}",
275
+ "{color.surface.raised}",
276
+ "{color.surface.subtle}",
277
+ "{color.status.warning.bg}"
278
+ ]
279
+ }
280
+ }
281
+ },
282
+ "error": {
283
+ "$value": "{color.red.300}",
284
+ "$description": "Error messages, linked to their field.",
285
+ "$extensions": {
286
+ "studio.graftwork": {
287
+ "role": "text",
288
+ "on": [
289
+ "{color.surface.default}",
290
+ "{color.surface.raised}",
291
+ "{color.surface.subtle}",
292
+ "{color.status.error.bg}"
293
+ ]
294
+ }
295
+ }
296
+ },
297
+ "info": {
298
+ "$value": "{color.brand.300}",
299
+ "$extensions": {
300
+ "studio.graftwork": {
301
+ "role": "text",
302
+ "on": [
303
+ "{color.surface.default}",
304
+ "{color.surface.raised}",
305
+ "{color.surface.subtle}",
306
+ "{color.status.info.bg}"
307
+ ]
308
+ }
309
+ }
310
+ }
311
+ },
312
+ "border": {
313
+ "$type": "color",
314
+ "$description": "Dark theme. border tokens.",
315
+ "input": {
316
+ "$value": "{color.neutral.500}",
317
+ "$description": "Input, select and checkbox borders.",
318
+ "$extensions": {
319
+ "studio.graftwork": {
320
+ "role": "non-text",
321
+ "on": [
322
+ "{color.surface.default}",
323
+ "{color.surface.raised}",
324
+ "{color.surface.subtle}",
325
+ "{color.surface.overlay}"
326
+ ]
327
+ }
328
+ }
329
+ },
330
+ "input-invalid": {
331
+ "$value": "{color.red.400}",
332
+ "$description": "Border of an invalid field. Always paired with error text and an icon.",
333
+ "$extensions": {
334
+ "studio.graftwork": {
335
+ "role": "non-text",
336
+ "on": [
337
+ "{color.surface.default}",
338
+ "{color.surface.raised}",
339
+ "{color.surface.subtle}",
340
+ "{color.surface.overlay}"
341
+ ]
342
+ }
343
+ }
344
+ },
345
+ "default": {
346
+ "$value": "{color.neutral.800}",
347
+ "$description": "Dividers and card outlines. Not relied on to identify anything.",
348
+ "$extensions": {
349
+ "studio.graftwork": {
350
+ "role": "decorative"
351
+ }
352
+ }
353
+ },
354
+ "status": {
355
+ "success": {
356
+ "$value": "{color.green.700}",
357
+ "$extensions": {
358
+ "studio.graftwork": {
359
+ "role": "decorative"
360
+ }
361
+ }
362
+ },
363
+ "warning": {
364
+ "$value": "{color.amber.700}",
365
+ "$extensions": {
366
+ "studio.graftwork": {
367
+ "role": "decorative"
368
+ }
369
+ }
370
+ },
371
+ "error": {
372
+ "$value": "{color.red.700}",
373
+ "$extensions": {
374
+ "studio.graftwork": {
375
+ "role": "decorative"
376
+ }
377
+ }
378
+ },
379
+ "info": {
380
+ "$value": "{color.brand.700}",
381
+ "$extensions": {
382
+ "studio.graftwork": {
383
+ "role": "decorative"
384
+ }
385
+ }
386
+ }
387
+ }
388
+ },
389
+ "icon": {
390
+ "$type": "color",
391
+ "$description": "Dark theme. icon tokens.",
392
+ "default": {
393
+ "$value": "{color.neutral.400}",
394
+ "$extensions": {
395
+ "studio.graftwork": {
396
+ "role": "non-text",
397
+ "on": [
398
+ "{color.surface.default}",
399
+ "{color.surface.raised}",
400
+ "{color.surface.subtle}",
401
+ "{color.surface.overlay}"
402
+ ]
403
+ }
404
+ }
405
+ },
406
+ "brand": {
407
+ "$value": "{color.brand.500}",
408
+ "$description": "The brand colour. Icons, borders and decoration; never text.",
409
+ "$extensions": {
410
+ "studio.graftwork": {
411
+ "role": "non-text",
412
+ "on": [
413
+ "{color.surface.default}",
414
+ "{color.surface.raised}",
415
+ "{color.surface.subtle}",
416
+ "{color.surface.overlay}"
417
+ ]
418
+ }
419
+ }
420
+ }
421
+ },
422
+ "focus": {
423
+ "$type": "color",
424
+ "$description": "Dark theme. focus tokens.",
425
+ "ring": {
426
+ "$value": "{color.brand.400}",
427
+ "$description": "Focus ring: 2px wide with a 2px offset, so a gap of surface always separates it from the component. Checked at 3:1 against every surface, which is what WCAG 2.4.13 measures.",
428
+ "$extensions": {
429
+ "studio.graftwork": {
430
+ "role": "non-text",
431
+ "on": [
432
+ "{color.surface.default}",
433
+ "{color.surface.raised}",
434
+ "{color.surface.subtle}",
435
+ "{color.surface.overlay}"
436
+ ]
437
+ }
438
+ }
439
+ }
440
+ },
441
+ "chart": {
442
+ "$type": "color",
443
+ "$description": "Dark theme. chart tokens.",
444
+ "series-1": {
445
+ "$value": "{color.brand.400}",
446
+ "$extensions": {
447
+ "studio.graftwork": {
448
+ "role": "non-text",
449
+ "on": [
450
+ "{color.surface.default}",
451
+ "{color.surface.raised}"
452
+ ]
453
+ }
454
+ }
455
+ },
456
+ "series-2": {
457
+ "$value": "{color.amber.400}",
458
+ "$extensions": {
459
+ "studio.graftwork": {
460
+ "role": "non-text",
461
+ "on": [
462
+ "{color.surface.default}",
463
+ "{color.surface.raised}"
464
+ ]
465
+ }
466
+ }
467
+ },
468
+ "series-3": {
469
+ "$value": "{color.neutral.400}",
470
+ "$extensions": {
471
+ "studio.graftwork": {
472
+ "role": "non-text",
473
+ "on": [
474
+ "{color.surface.default}",
475
+ "{color.surface.raised}"
476
+ ]
477
+ }
478
+ }
479
+ },
480
+ "series-4": {
481
+ "$value": "{color.green.400}",
482
+ "$extensions": {
483
+ "studio.graftwork": {
484
+ "role": "non-text",
485
+ "on": [
486
+ "{color.surface.default}",
487
+ "{color.surface.raised}"
488
+ ]
489
+ }
490
+ }
491
+ },
492
+ "grid": {
493
+ "$value": "{color.neutral.800}",
494
+ "$extensions": {
495
+ "studio.graftwork": {
496
+ "role": "decorative"
497
+ }
498
+ }
499
+ }
500
+ }
501
+ }
502
+ }