@youcan/celeste-tokens 0.6.95 → 0.6.97

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,526 @@
1
+ {
2
+ "fontFamilies": {
3
+ "inter-display": {
4
+ "$value": "InterDisplay",
5
+ "$type": "fontFamilies",
6
+ "font-weight-range": "100-900",
7
+ "font-style": ["normal", "italic"]
8
+ },
9
+ "inter": {
10
+ "$value": "InterVariable",
11
+ "$type": "fontFamilies",
12
+ "font-weight-range": "100-900",
13
+ "font-style": ["normal", "italic"]
14
+ },
15
+ "cairo": {
16
+ "$value": "Cairo",
17
+ "$type": "fontFamilies",
18
+ "font-weight-range": "400-700",
19
+ "font-style": ["normal"]
20
+ },
21
+ "geist-mono": {
22
+ "$value": "Geist Mono",
23
+ "$type": "fontFamilies",
24
+ "font-weight-range": "400-700",
25
+ "font-style": ["normal"]
26
+ },
27
+ "sans": {
28
+ "$value": "InterVariable, Cairo, sans-serif",
29
+ "$type": "fontFamilies"
30
+ },
31
+ "mono": {
32
+ "$value": "Geist Mono, monospace",
33
+ "$type": "fontFamilies"
34
+ },
35
+ "display": {
36
+ "$value": "InterDisplay, Cairo, sans-serif",
37
+ "$type": "fontFamilies"
38
+ }
39
+ },
40
+ "lineHeights": {
41
+ "0": {
42
+ "$value": "64px",
43
+ "$type": "lineHeights"
44
+ },
45
+ "1": {
46
+ "$value": "56px",
47
+ "$type": "lineHeights"
48
+ },
49
+ "2": {
50
+ "$value": "48px",
51
+ "$type": "lineHeights"
52
+ },
53
+ "3": {
54
+ "$value": "40px",
55
+ "$type": "lineHeights"
56
+ },
57
+ "4": {
58
+ "$value": "32px",
59
+ "$type": "lineHeights"
60
+ },
61
+ "5": {
62
+ "$value": "28px",
63
+ "$type": "lineHeights"
64
+ },
65
+ "6": {
66
+ "$value": "24px",
67
+ "$type": "lineHeights"
68
+ },
69
+ "7": {
70
+ "$value": "20px",
71
+ "$type": "lineHeights"
72
+ },
73
+ "8": {
74
+ "$value": "16px",
75
+ "$type": "lineHeights"
76
+ },
77
+ "9": {
78
+ "$value": "12px",
79
+ "$type": "lineHeights"
80
+ }
81
+ },
82
+ "fontWeights": {
83
+ "display-0": {
84
+ "$value": "Medium",
85
+ "$type": "fontWeights"
86
+ },
87
+ "sans-0": {
88
+ "$value": "Regular",
89
+ "$type": "fontWeights"
90
+ },
91
+ "sans-1": {
92
+ "$value": "Medium",
93
+ "$type": "fontWeights"
94
+ }
95
+ },
96
+ "fontSize": {
97
+ "0": {
98
+ "$value": "11",
99
+ "$type": "fontSizes"
100
+ },
101
+ "1": {
102
+ "$value": "12",
103
+ "$type": "fontSizes"
104
+ },
105
+ "2": {
106
+ "$value": "14",
107
+ "$type": "fontSizes"
108
+ },
109
+ "3": {
110
+ "$value": "16",
111
+ "$type": "fontSizes"
112
+ },
113
+ "4": {
114
+ "$value": "18",
115
+ "$type": "fontSizes"
116
+ },
117
+ "5": {
118
+ "$value": "20",
119
+ "$type": "fontSizes"
120
+ },
121
+ "6": {
122
+ "$value": "24",
123
+ "$type": "fontSizes"
124
+ },
125
+ "7": {
126
+ "$value": "32",
127
+ "$type": "fontSizes"
128
+ },
129
+ "8": {
130
+ "$value": "40",
131
+ "$type": "fontSizes"
132
+ },
133
+ "9": {
134
+ "$value": "48",
135
+ "$type": "fontSizes"
136
+ },
137
+ "10": {
138
+ "$value": "56",
139
+ "$type": "fontSizes"
140
+ }
141
+ },
142
+ "letterSpacing": {
143
+ "0": {
144
+ "$value": "-1%",
145
+ "$type": "letterSpacing"
146
+ },
147
+ "1": {
148
+ "$value": "-0.5%",
149
+ "$type": "letterSpacing"
150
+ },
151
+ "2": {
152
+ "$value": "0%",
153
+ "$type": "letterSpacing"
154
+ },
155
+ "3": {
156
+ "$value": "-1.5%",
157
+ "$type": "letterSpacing"
158
+ },
159
+ "4": {
160
+ "$value": "-1.1%",
161
+ "$type": "letterSpacing"
162
+ },
163
+ "5": {
164
+ "$value": "-0.6%",
165
+ "$type": "letterSpacing"
166
+ },
167
+ "6": {
168
+ "$value": "6%",
169
+ "$type": "letterSpacing"
170
+ },
171
+ "7": {
172
+ "$value": "4%",
173
+ "$type": "letterSpacing"
174
+ },
175
+ "8": {
176
+ "$value": "2%",
177
+ "$type": "letterSpacing"
178
+ }
179
+ },
180
+ "paragraphSpacing": {
181
+ "0": {
182
+ "$value": "0",
183
+ "$type": "paragraphSpacing"
184
+ }
185
+ },
186
+ "textCase": {
187
+ "none": {
188
+ "$value": "none",
189
+ "$type": "textCase"
190
+ },
191
+ "uppercase": {
192
+ "$value": "uppercase",
193
+ "$type": "textCase"
194
+ }
195
+ },
196
+ "textDecoration": {
197
+ "none": {
198
+ "$value": "none",
199
+ "$type": "textDecoration"
200
+ }
201
+ },
202
+ "paragraphIndent": {
203
+ "0": {
204
+ "$value": "0px",
205
+ "$type": "dimension"
206
+ }
207
+ },
208
+ "Title": {
209
+ "H1 Title": {
210
+ "$value": {
211
+ "fontFamily": "{fontFamilies.display}",
212
+ "fontWeight": "{fontWeights.display-0}",
213
+ "lineHeight": "{lineHeights.0}",
214
+ "fontSize": "{fontSize.10}",
215
+ "letterSpacing": "{letterSpacing.0}",
216
+ "paragraphSpacing": "{paragraphSpacing.0}",
217
+ "paragraphIndent": "{paragraphIndent.0}",
218
+ "textCase": "{textCase.none}",
219
+ "textDecoration": "{textDecoration.none}"
220
+ },
221
+ "$type": "typography"
222
+ },
223
+ "H2 Title": {
224
+ "$value": {
225
+ "fontFamily": "{fontFamilies.display}",
226
+ "fontWeight": "{fontWeights.display-0}",
227
+ "lineHeight": "{lineHeights.1}",
228
+ "fontSize": "{fontSize.9}",
229
+ "letterSpacing": "{letterSpacing.0}",
230
+ "paragraphSpacing": "{paragraphSpacing.0}",
231
+ "paragraphIndent": "{paragraphIndent.0}",
232
+ "textCase": "{textCase.none}",
233
+ "textDecoration": "{textDecoration.none}"
234
+ },
235
+ "$type": "typography"
236
+ },
237
+ "H3 Title": {
238
+ "$value": {
239
+ "fontFamily": "{fontFamilies.display}",
240
+ "fontWeight": "{fontWeights.display-0}",
241
+ "lineHeight": "{lineHeights.2}",
242
+ "fontSize": "{fontSize.8}",
243
+ "letterSpacing": "{letterSpacing.0}",
244
+ "paragraphSpacing": "{paragraphSpacing.0}",
245
+ "paragraphIndent": "{paragraphIndent.0}",
246
+ "textCase": "{textCase.none}",
247
+ "textDecoration": "{textDecoration.none}"
248
+ },
249
+ "$type": "typography"
250
+ },
251
+ "H4 Title": {
252
+ "$value": {
253
+ "fontFamily": "{fontFamilies.display}",
254
+ "fontWeight": "{fontWeights.display-0}",
255
+ "lineHeight": "{lineHeights.3}",
256
+ "fontSize": "{fontSize.7}",
257
+ "letterSpacing": "{letterSpacing.1}",
258
+ "paragraphSpacing": "{paragraphSpacing.0}",
259
+ "paragraphIndent": "{paragraphIndent.0}",
260
+ "textCase": "{textCase.none}",
261
+ "textDecoration": "{textDecoration.none}"
262
+ },
263
+ "$type": "typography"
264
+ },
265
+ "H5 Title": {
266
+ "$value": {
267
+ "fontFamily": "{fontFamilies.display}",
268
+ "fontWeight": "{fontWeights.display-0}",
269
+ "lineHeight": "{lineHeights.4}",
270
+ "fontSize": "{fontSize.6}",
271
+ "letterSpacing": "{letterSpacing.2}",
272
+ "paragraphSpacing": "{paragraphSpacing.0}",
273
+ "paragraphIndent": "{paragraphIndent.0}",
274
+ "textCase": "{textCase.none}",
275
+ "textDecoration": "{textDecoration.none}"
276
+ },
277
+ "$type": "typography"
278
+ },
279
+ "H6 Title": {
280
+ "$value": {
281
+ "fontFamily": "{fontFamilies.display}",
282
+ "fontWeight": "{fontWeights.display-0}",
283
+ "lineHeight": "{lineHeights.5}",
284
+ "fontSize": "{fontSize.5}",
285
+ "letterSpacing": "{letterSpacing.2}",
286
+ "paragraphSpacing": "{paragraphSpacing.0}",
287
+ "paragraphIndent": "{paragraphIndent.0}",
288
+ "textCase": "{textCase.none}",
289
+ "textDecoration": "{textDecoration.none}"
290
+ },
291
+ "$type": "typography"
292
+ }
293
+ },
294
+ "Label": {
295
+ "xl": {
296
+ "$value": {
297
+ "fontFamily": "{fontFamilies.sans}",
298
+ "fontWeight": "{fontWeights.display-0}",
299
+ "lineHeight": "{lineHeights.4}",
300
+ "fontSize": "{fontSize.6}",
301
+ "letterSpacing": "{letterSpacing.3}",
302
+ "paragraphSpacing": "{paragraphSpacing.0}",
303
+ "paragraphIndent": "{paragraphIndent.0}",
304
+ "textCase": "{textCase.none}",
305
+ "textDecoration": "{textDecoration.none}"
306
+ },
307
+ "$type": "typography"
308
+ },
309
+ "lg": {
310
+ "$value": {
311
+ "fontFamily": "{fontFamilies.sans}",
312
+ "fontWeight": "{fontWeights.display-0}",
313
+ "lineHeight": "{lineHeights.6}",
314
+ "fontSize": "{fontSize.4}",
315
+ "letterSpacing": "{letterSpacing.3}",
316
+ "paragraphSpacing": "{paragraphSpacing.0}",
317
+ "paragraphIndent": "{paragraphIndent.0}",
318
+ "textCase": "{textCase.none}",
319
+ "textDecoration": "{textDecoration.none}"
320
+ },
321
+ "$type": "typography"
322
+ },
323
+ "md": {
324
+ "$value": {
325
+ "fontFamily": "{fontFamilies.sans}",
326
+ "fontWeight": "{fontWeights.display-0}",
327
+ "lineHeight": "{lineHeights.6}",
328
+ "fontSize": "{fontSize.3}",
329
+ "letterSpacing": "{letterSpacing.4}",
330
+ "paragraphSpacing": "{paragraphSpacing.0}",
331
+ "paragraphIndent": "{paragraphIndent.0}",
332
+ "textCase": "{textCase.none}",
333
+ "textDecoration": "{textDecoration.none}"
334
+ },
335
+ "$type": "typography"
336
+ },
337
+ "sm": {
338
+ "$value": {
339
+ "fontFamily": "{fontFamilies.sans}",
340
+ "fontWeight": "{fontWeights.display-0}",
341
+ "lineHeight": "{lineHeights.7}",
342
+ "fontSize": "{fontSize.2}",
343
+ "letterSpacing": "{letterSpacing.5}",
344
+ "paragraphSpacing": "{paragraphSpacing.0}",
345
+ "paragraphIndent": "{paragraphIndent.0}",
346
+ "textCase": "{textCase.none}",
347
+ "textDecoration": "{textDecoration.none}"
348
+ },
349
+ "$type": "typography"
350
+ },
351
+ "xs": {
352
+ "$value": {
353
+ "fontFamily": "{fontFamilies.sans}",
354
+ "fontWeight": "{fontWeights.display-0}",
355
+ "lineHeight": "{lineHeights.8}",
356
+ "fontSize": "{fontSize.1}",
357
+ "letterSpacing": "{letterSpacing.2}",
358
+ "paragraphSpacing": "{paragraphSpacing.0}",
359
+ "paragraphIndent": "{paragraphIndent.0}",
360
+ "textCase": "{textCase.none}",
361
+ "textDecoration": "{textDecoration.none}"
362
+ },
363
+ "$type": "typography"
364
+ }
365
+ },
366
+ "Paragraph": {
367
+ "xl": {
368
+ "$value": {
369
+ "fontFamily": "{fontFamilies.sans}",
370
+ "fontWeight": "{fontWeights.sans-0}",
371
+ "lineHeight": "{lineHeights.4}",
372
+ "fontSize": "{fontSize.6}",
373
+ "letterSpacing": "{letterSpacing.3}",
374
+ "paragraphSpacing": "{paragraphSpacing.0}",
375
+ "paragraphIndent": "{paragraphIndent.0}",
376
+ "textCase": "{textCase.none}",
377
+ "textDecoration": "{textDecoration.none}"
378
+ },
379
+ "$type": "typography"
380
+ },
381
+ "lg": {
382
+ "$value": {
383
+ "fontFamily": "{fontFamilies.sans}",
384
+ "fontWeight": "{fontWeights.sans-0}",
385
+ "lineHeight": "{lineHeights.6}",
386
+ "fontSize": "{fontSize.4}",
387
+ "letterSpacing": "{letterSpacing.3}",
388
+ "paragraphSpacing": "{paragraphSpacing.0}",
389
+ "paragraphIndent": "{paragraphIndent.0}",
390
+ "textCase": "{textCase.none}",
391
+ "textDecoration": "{textDecoration.none}"
392
+ },
393
+ "$type": "typography"
394
+ },
395
+ "md": {
396
+ "$value": {
397
+ "fontFamily": "{fontFamilies.sans}",
398
+ "fontWeight": "{fontWeights.sans-0}",
399
+ "lineHeight": "{lineHeights.6}",
400
+ "fontSize": "{fontSize.3}",
401
+ "letterSpacing": "{letterSpacing.4}",
402
+ "paragraphSpacing": "{paragraphSpacing.0}",
403
+ "paragraphIndent": "{paragraphIndent.0}",
404
+ "textCase": "{textCase.none}",
405
+ "textDecoration": "{textDecoration.none}"
406
+ },
407
+ "$type": "typography"
408
+ },
409
+ "sm": {
410
+ "$value": {
411
+ "fontFamily": "{fontFamilies.sans}",
412
+ "fontWeight": "{fontWeights.sans-0}",
413
+ "lineHeight": "{lineHeights.7}",
414
+ "fontSize": "{fontSize.2}",
415
+ "letterSpacing": "{letterSpacing.5}",
416
+ "paragraphSpacing": "{paragraphSpacing.0}",
417
+ "paragraphIndent": "{paragraphIndent.0}",
418
+ "textCase": "{textCase.none}",
419
+ "textDecoration": "{textDecoration.none}"
420
+ },
421
+ "$type": "typography"
422
+ },
423
+ "xs": {
424
+ "$value": {
425
+ "fontFamily": "{fontFamilies.sans}",
426
+ "fontWeight": "{fontWeights.sans-0}",
427
+ "lineHeight": "{lineHeights.8}",
428
+ "fontSize": "{fontSize.1}",
429
+ "letterSpacing": "{letterSpacing.2}",
430
+ "paragraphSpacing": "{paragraphSpacing.0}",
431
+ "paragraphIndent": "{paragraphIndent.0}",
432
+ "textCase": "{textCase.none}",
433
+ "textDecoration": "{textDecoration.none}"
434
+ },
435
+ "$type": "typography"
436
+ }
437
+ },
438
+ "Subheading": {
439
+ "md": {
440
+ "$value": {
441
+ "fontFamily": "{fontFamilies.sans}",
442
+ "fontWeight": "{fontWeights.display-0}",
443
+ "lineHeight": "{lineHeights.6}",
444
+ "fontSize": "{fontSize.3}",
445
+ "letterSpacing": "{letterSpacing.6}",
446
+ "paragraphSpacing": "{paragraphSpacing.0}",
447
+ "paragraphIndent": "{paragraphIndent.0}",
448
+ "textCase": "{textCase.uppercase}",
449
+ "textDecoration": "{textDecoration.none}"
450
+ },
451
+ "$type": "typography"
452
+ },
453
+ "sm": {
454
+ "$value": {
455
+ "fontFamily": "{fontFamilies.sans}",
456
+ "fontWeight": "{fontWeights.display-0}",
457
+ "lineHeight": "{lineHeights.7}",
458
+ "fontSize": "{fontSize.2}",
459
+ "letterSpacing": "{letterSpacing.6}",
460
+ "paragraphSpacing": "{paragraphSpacing.0}",
461
+ "paragraphIndent": "{paragraphIndent.0}",
462
+ "textCase": "{textCase.uppercase}",
463
+ "textDecoration": "{textDecoration.none}"
464
+ },
465
+ "$type": "typography"
466
+ },
467
+ "xs": {
468
+ "$value": {
469
+ "fontFamily": "{fontFamilies.sans}",
470
+ "fontWeight": "{fontWeights.display-0}",
471
+ "lineHeight": "{lineHeights.8}",
472
+ "fontSize": "{fontSize.1}",
473
+ "letterSpacing": "{letterSpacing.7}",
474
+ "paragraphSpacing": "{paragraphSpacing.0}",
475
+ "paragraphIndent": "{paragraphIndent.0}",
476
+ "textCase": "{textCase.uppercase}",
477
+ "textDecoration": "{textDecoration.none}"
478
+ },
479
+ "$type": "typography"
480
+ },
481
+ "xxs": {
482
+ "$value": {
483
+ "fontFamily": "{fontFamilies.sans}",
484
+ "fontWeight": "{fontWeights.display-0}",
485
+ "lineHeight": "{lineHeights.9}",
486
+ "fontSize": "{fontSize.0}",
487
+ "letterSpacing": "{letterSpacing.8}",
488
+ "paragraphSpacing": "{paragraphSpacing.0}",
489
+ "paragraphIndent": "{paragraphIndent.0}",
490
+ "textCase": "{textCase.uppercase}",
491
+ "textDecoration": "{textDecoration.none}"
492
+ },
493
+ "$type": "typography"
494
+ }
495
+ },
496
+ "Docs": {
497
+ "Label": {
498
+ "$value": {
499
+ "fontFamily": "{fontFamilies.sans}",
500
+ "fontWeight": "{fontWeights.display-0}",
501
+ "lineHeight": "{lineHeights.4}",
502
+ "fontSize": "{fontSize.4}",
503
+ "letterSpacing": "{letterSpacing.3}",
504
+ "paragraphSpacing": "{paragraphSpacing.0}",
505
+ "paragraphIndent": "{paragraphIndent.0}",
506
+ "textCase": "{textCase.none}",
507
+ "textDecoration": "{textDecoration.none}"
508
+ },
509
+ "$type": "typography"
510
+ },
511
+ "Paragraph": {
512
+ "$value": {
513
+ "fontFamily": "{fontFamilies.sans}",
514
+ "fontWeight": "{fontWeights.sans-0}",
515
+ "lineHeight": "{lineHeights.4}",
516
+ "fontSize": "{fontSize.4}",
517
+ "letterSpacing": "{letterSpacing.3}",
518
+ "paragraphSpacing": "{paragraphSpacing.0}",
519
+ "paragraphIndent": "{paragraphIndent.0}",
520
+ "textCase": "{textCase.none}",
521
+ "textDecoration": "{textDecoration.none}"
522
+ },
523
+ "$type": "typography"
524
+ }
525
+ }
526
+ }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@youcan/celeste-tokens",
3
3
  "type": "module",
4
- "version": "0.6.95",
4
+ "version": "0.6.97",
5
5
  "author": "YouCan <tech@youcan.shop>",
6
6
  "repository": {
7
7
  "type": "git",
@@ -20,6 +20,24 @@
20
20
  },
21
21
  "./preset": {
22
22
  "import": "./dist/preset.ts"
23
+ },
24
+ "./json/animation": {
25
+ "import": "./dist/json/animation.json"
26
+ },
27
+ "./json/color": {
28
+ "import": "./dist/json/color.json"
29
+ },
30
+ "./json/radius": {
31
+ "import": "./dist/json/radius.json"
32
+ },
33
+ "./json/shadow": {
34
+ "import": "./dist/json/shadow.json"
35
+ },
36
+ "./json/spacing": {
37
+ "import": "./dist/json/spacing.json"
38
+ },
39
+ "./json/typo": {
40
+ "import": "./dist/json/typo.json"
23
41
  }
24
42
  },
25
43
  "engines": {
package/src/generate.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  /* eslint-disable antfu/no-top-level-await */
2
- import { readFileSync, writeFileSync } from 'node:fs';
2
+ import { copyFileSync, mkdirSync, readdirSync, readFileSync, writeFileSync } from 'node:fs';
3
3
  import { join, resolve } from 'node:path';
4
4
  import { register } from '@tokens-studio/sd-transforms';
5
5
  import { minify as csso } from 'csso';
@@ -95,3 +95,12 @@ prependStubs(resolve(dist, 'tokens.css'));
95
95
  prependStubs(resolve(dist, 'tokens.scss'));
96
96
 
97
97
  minify(resolve(dist, 'tokens.css'));
98
+
99
+ const tokensSrc = resolve(import.meta.dirname, 'tokens');
100
+ const tokensDist = resolve(dist, 'json');
101
+
102
+ mkdirSync(tokensDist, { recursive: true });
103
+
104
+ for (const file of readdirSync(tokensSrc).filter((f: string) => f.endsWith('.json'))) {
105
+ copyFileSync(`${tokensSrc}/${file}`, `${tokensDist}/${file}`);
106
+ }