@diskette/palette 0.8.0 → 0.9.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.
Files changed (66) hide show
  1. package/README.md +232 -0
  2. package/dist/colors/amber.d.ts +10 -0
  3. package/dist/colors/amber.js +10 -0
  4. package/dist/colors/blue.d.ts +10 -0
  5. package/dist/colors/blue.js +10 -0
  6. package/dist/colors/bronze.d.ts +10 -0
  7. package/dist/colors/bronze.js +10 -0
  8. package/dist/colors/brown.d.ts +10 -0
  9. package/dist/colors/brown.js +10 -0
  10. package/dist/colors/crimson.d.ts +10 -0
  11. package/dist/colors/crimson.js +10 -0
  12. package/dist/colors/cyan.d.ts +10 -0
  13. package/dist/colors/cyan.js +10 -0
  14. package/dist/colors/gold.d.ts +10 -0
  15. package/dist/colors/gold.js +10 -0
  16. package/dist/colors/grass.d.ts +10 -0
  17. package/dist/colors/grass.js +10 -0
  18. package/dist/colors/gray.d.ts +10 -0
  19. package/dist/colors/gray.js +10 -0
  20. package/dist/colors/green.d.ts +10 -0
  21. package/dist/colors/green.js +10 -0
  22. package/dist/colors/indigo.d.ts +10 -0
  23. package/dist/colors/indigo.js +10 -0
  24. package/dist/colors/iris.d.ts +10 -0
  25. package/dist/colors/iris.js +10 -0
  26. package/dist/colors/jade.d.ts +10 -0
  27. package/dist/colors/jade.js +10 -0
  28. package/dist/colors/lime.d.ts +10 -0
  29. package/dist/colors/lime.js +10 -0
  30. package/dist/colors/mauve.d.ts +10 -0
  31. package/dist/colors/mauve.js +10 -0
  32. package/dist/colors/mint.d.ts +10 -0
  33. package/dist/colors/mint.js +10 -0
  34. package/dist/colors/olive.d.ts +10 -0
  35. package/dist/colors/olive.js +10 -0
  36. package/dist/colors/orange.d.ts +10 -0
  37. package/dist/colors/orange.js +10 -0
  38. package/dist/colors/pink.d.ts +10 -0
  39. package/dist/colors/pink.js +10 -0
  40. package/dist/colors/plum.d.ts +10 -0
  41. package/dist/colors/plum.js +10 -0
  42. package/dist/colors/purple.d.ts +10 -0
  43. package/dist/colors/purple.js +10 -0
  44. package/dist/colors/red.d.ts +10 -0
  45. package/dist/colors/red.js +10 -0
  46. package/dist/colors/ruby.d.ts +10 -0
  47. package/dist/colors/ruby.js +10 -0
  48. package/dist/colors/sage.d.ts +10 -0
  49. package/dist/colors/sage.js +10 -0
  50. package/dist/colors/sand.d.ts +10 -0
  51. package/dist/colors/sand.js +10 -0
  52. package/dist/colors/sky.d.ts +10 -0
  53. package/dist/colors/sky.js +10 -0
  54. package/dist/colors/slate.d.ts +10 -0
  55. package/dist/colors/slate.js +10 -0
  56. package/dist/colors/teal.d.ts +10 -0
  57. package/dist/colors/teal.js +10 -0
  58. package/dist/colors/tomato.d.ts +10 -0
  59. package/dist/colors/tomato.js +10 -0
  60. package/dist/colors/violet.d.ts +10 -0
  61. package/dist/colors/violet.js +10 -0
  62. package/dist/colors/yellow.d.ts +10 -0
  63. package/dist/colors/yellow.js +10 -0
  64. package/dist/index.d.ts +311 -1
  65. package/dist/types.d.ts +18 -1
  66. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -114,6 +114,16 @@ export declare const colors: ({
114
114
  contrast: string;
115
115
  indicator: string;
116
116
  track: string;
117
+ surface: {
118
+ srgb: {
119
+ light: string;
120
+ dark: string;
121
+ };
122
+ p3: {
123
+ light: string;
124
+ dark: string;
125
+ };
126
+ };
117
127
  } | {
118
128
  srgb: {
119
129
  light: {
@@ -230,6 +240,16 @@ export declare const colors: ({
230
240
  contrast: string;
231
241
  indicator: string;
232
242
  track: string;
243
+ surface: {
244
+ srgb: {
245
+ light: string;
246
+ dark: string;
247
+ };
248
+ p3: {
249
+ light: string;
250
+ dark: string;
251
+ };
252
+ };
233
253
  } | {
234
254
  srgb: {
235
255
  light: {
@@ -346,6 +366,16 @@ export declare const colors: ({
346
366
  contrast: string;
347
367
  indicator: string;
348
368
  track: string;
369
+ surface: {
370
+ srgb: {
371
+ light: string;
372
+ dark: string;
373
+ };
374
+ p3: {
375
+ light: string;
376
+ dark: string;
377
+ };
378
+ };
349
379
  } | {
350
380
  srgb: {
351
381
  light: {
@@ -462,6 +492,16 @@ export declare const colors: ({
462
492
  contrast: string;
463
493
  indicator: string;
464
494
  track: string;
495
+ surface: {
496
+ srgb: {
497
+ light: string;
498
+ dark: string;
499
+ };
500
+ p3: {
501
+ light: string;
502
+ dark: string;
503
+ };
504
+ };
465
505
  } | {
466
506
  srgb: {
467
507
  light: {
@@ -578,6 +618,16 @@ export declare const colors: ({
578
618
  contrast: string;
579
619
  indicator: string;
580
620
  track: string;
621
+ surface: {
622
+ srgb: {
623
+ light: string;
624
+ dark: string;
625
+ };
626
+ p3: {
627
+ light: string;
628
+ dark: string;
629
+ };
630
+ };
581
631
  } | {
582
632
  srgb: {
583
633
  light: {
@@ -694,6 +744,16 @@ export declare const colors: ({
694
744
  contrast: string;
695
745
  indicator: string;
696
746
  track: string;
747
+ surface: {
748
+ srgb: {
749
+ light: string;
750
+ dark: string;
751
+ };
752
+ p3: {
753
+ light: string;
754
+ dark: string;
755
+ };
756
+ };
697
757
  } | {
698
758
  srgb: {
699
759
  light: {
@@ -810,6 +870,16 @@ export declare const colors: ({
810
870
  contrast: string;
811
871
  indicator: string;
812
872
  track: string;
873
+ surface: {
874
+ srgb: {
875
+ light: string;
876
+ dark: string;
877
+ };
878
+ p3: {
879
+ light: string;
880
+ dark: string;
881
+ };
882
+ };
813
883
  } | {
814
884
  srgb: {
815
885
  light: {
@@ -926,6 +996,16 @@ export declare const colors: ({
926
996
  contrast: string;
927
997
  indicator: string;
928
998
  track: string;
999
+ surface: {
1000
+ srgb: {
1001
+ light: string;
1002
+ dark: string;
1003
+ };
1004
+ p3: {
1005
+ light: string;
1006
+ dark: string;
1007
+ };
1008
+ };
929
1009
  } | {
930
1010
  srgb: {
931
1011
  light: {
@@ -1042,6 +1122,16 @@ export declare const colors: ({
1042
1122
  contrast: string;
1043
1123
  indicator: string;
1044
1124
  track: string;
1125
+ surface: {
1126
+ srgb: {
1127
+ light: string;
1128
+ dark: string;
1129
+ };
1130
+ p3: {
1131
+ light: string;
1132
+ dark: string;
1133
+ };
1134
+ };
1045
1135
  } | {
1046
1136
  srgb: {
1047
1137
  light: {
@@ -1158,6 +1248,16 @@ export declare const colors: ({
1158
1248
  contrast: string;
1159
1249
  indicator: string;
1160
1250
  track: string;
1251
+ surface: {
1252
+ srgb: {
1253
+ light: string;
1254
+ dark: string;
1255
+ };
1256
+ p3: {
1257
+ light: string;
1258
+ dark: string;
1259
+ };
1260
+ };
1161
1261
  } | {
1162
1262
  srgb: {
1163
1263
  light: {
@@ -1274,6 +1374,16 @@ export declare const colors: ({
1274
1374
  contrast: string;
1275
1375
  indicator: string;
1276
1376
  track: string;
1377
+ surface: {
1378
+ srgb: {
1379
+ light: string;
1380
+ dark: string;
1381
+ };
1382
+ p3: {
1383
+ light: string;
1384
+ dark: string;
1385
+ };
1386
+ };
1277
1387
  } | {
1278
1388
  srgb: {
1279
1389
  light: {
@@ -1390,6 +1500,16 @@ export declare const colors: ({
1390
1500
  contrast: string;
1391
1501
  indicator: string;
1392
1502
  track: string;
1503
+ surface: {
1504
+ srgb: {
1505
+ light: string;
1506
+ dark: string;
1507
+ };
1508
+ p3: {
1509
+ light: string;
1510
+ dark: string;
1511
+ };
1512
+ };
1393
1513
  } | {
1394
1514
  srgb: {
1395
1515
  light: {
@@ -1506,6 +1626,16 @@ export declare const colors: ({
1506
1626
  contrast: string;
1507
1627
  indicator: string;
1508
1628
  track: string;
1629
+ surface: {
1630
+ srgb: {
1631
+ light: string;
1632
+ dark: string;
1633
+ };
1634
+ p3: {
1635
+ light: string;
1636
+ dark: string;
1637
+ };
1638
+ };
1509
1639
  } | {
1510
1640
  srgb: {
1511
1641
  light: {
@@ -1622,6 +1752,16 @@ export declare const colors: ({
1622
1752
  contrast: string;
1623
1753
  indicator: string;
1624
1754
  track: string;
1755
+ surface: {
1756
+ srgb: {
1757
+ light: string;
1758
+ dark: string;
1759
+ };
1760
+ p3: {
1761
+ light: string;
1762
+ dark: string;
1763
+ };
1764
+ };
1625
1765
  } | {
1626
1766
  srgb: {
1627
1767
  light: {
@@ -1738,6 +1878,16 @@ export declare const colors: ({
1738
1878
  contrast: string;
1739
1879
  indicator: string;
1740
1880
  track: string;
1881
+ surface: {
1882
+ srgb: {
1883
+ light: string;
1884
+ dark: string;
1885
+ };
1886
+ p3: {
1887
+ light: string;
1888
+ dark: string;
1889
+ };
1890
+ };
1741
1891
  } | {
1742
1892
  srgb: {
1743
1893
  light: {
@@ -1854,6 +2004,16 @@ export declare const colors: ({
1854
2004
  contrast: string;
1855
2005
  indicator: string;
1856
2006
  track: string;
2007
+ surface: {
2008
+ srgb: {
2009
+ light: string;
2010
+ dark: string;
2011
+ };
2012
+ p3: {
2013
+ light: string;
2014
+ dark: string;
2015
+ };
2016
+ };
1857
2017
  } | {
1858
2018
  srgb: {
1859
2019
  light: {
@@ -1970,6 +2130,16 @@ export declare const colors: ({
1970
2130
  contrast: string;
1971
2131
  indicator: string;
1972
2132
  track: string;
2133
+ surface: {
2134
+ srgb: {
2135
+ light: string;
2136
+ dark: string;
2137
+ };
2138
+ p3: {
2139
+ light: string;
2140
+ dark: string;
2141
+ };
2142
+ };
1973
2143
  } | {
1974
2144
  srgb: {
1975
2145
  light: {
@@ -2086,6 +2256,16 @@ export declare const colors: ({
2086
2256
  contrast: string;
2087
2257
  indicator: string;
2088
2258
  track: string;
2259
+ surface: {
2260
+ srgb: {
2261
+ light: string;
2262
+ dark: string;
2263
+ };
2264
+ p3: {
2265
+ light: string;
2266
+ dark: string;
2267
+ };
2268
+ };
2089
2269
  } | {
2090
2270
  srgb: {
2091
2271
  light: {
@@ -2202,6 +2382,16 @@ export declare const colors: ({
2202
2382
  contrast: string;
2203
2383
  indicator: string;
2204
2384
  track: string;
2385
+ surface: {
2386
+ srgb: {
2387
+ light: string;
2388
+ dark: string;
2389
+ };
2390
+ p3: {
2391
+ light: string;
2392
+ dark: string;
2393
+ };
2394
+ };
2205
2395
  } | {
2206
2396
  srgb: {
2207
2397
  light: {
@@ -2318,6 +2508,16 @@ export declare const colors: ({
2318
2508
  contrast: string;
2319
2509
  indicator: string;
2320
2510
  track: string;
2511
+ surface: {
2512
+ srgb: {
2513
+ light: string;
2514
+ dark: string;
2515
+ };
2516
+ p3: {
2517
+ light: string;
2518
+ dark: string;
2519
+ };
2520
+ };
2321
2521
  } | {
2322
2522
  srgb: {
2323
2523
  light: {
@@ -2434,6 +2634,16 @@ export declare const colors: ({
2434
2634
  contrast: string;
2435
2635
  indicator: string;
2436
2636
  track: string;
2637
+ surface: {
2638
+ srgb: {
2639
+ light: string;
2640
+ dark: string;
2641
+ };
2642
+ p3: {
2643
+ light: string;
2644
+ dark: string;
2645
+ };
2646
+ };
2437
2647
  } | {
2438
2648
  srgb: {
2439
2649
  light: {
@@ -2550,6 +2760,16 @@ export declare const colors: ({
2550
2760
  contrast: string;
2551
2761
  indicator: string;
2552
2762
  track: string;
2763
+ surface: {
2764
+ srgb: {
2765
+ light: string;
2766
+ dark: string;
2767
+ };
2768
+ p3: {
2769
+ light: string;
2770
+ dark: string;
2771
+ };
2772
+ };
2553
2773
  } | {
2554
2774
  srgb: {
2555
2775
  light: {
@@ -2666,6 +2886,16 @@ export declare const colors: ({
2666
2886
  contrast: string;
2667
2887
  indicator: string;
2668
2888
  track: string;
2889
+ surface: {
2890
+ srgb: {
2891
+ light: string;
2892
+ dark: string;
2893
+ };
2894
+ p3: {
2895
+ light: string;
2896
+ dark: string;
2897
+ };
2898
+ };
2669
2899
  } | {
2670
2900
  srgb: {
2671
2901
  light: {
@@ -2782,6 +3012,16 @@ export declare const colors: ({
2782
3012
  contrast: string;
2783
3013
  indicator: string;
2784
3014
  track: string;
3015
+ surface: {
3016
+ srgb: {
3017
+ light: string;
3018
+ dark: string;
3019
+ };
3020
+ p3: {
3021
+ light: string;
3022
+ dark: string;
3023
+ };
3024
+ };
2785
3025
  } | {
2786
3026
  srgb: {
2787
3027
  light: {
@@ -2898,6 +3138,16 @@ export declare const colors: ({
2898
3138
  contrast: string;
2899
3139
  indicator: string;
2900
3140
  track: string;
3141
+ surface: {
3142
+ srgb: {
3143
+ light: string;
3144
+ dark: string;
3145
+ };
3146
+ p3: {
3147
+ light: string;
3148
+ dark: string;
3149
+ };
3150
+ };
2901
3151
  } | {
2902
3152
  srgb: {
2903
3153
  light: {
@@ -3014,6 +3264,16 @@ export declare const colors: ({
3014
3264
  contrast: string;
3015
3265
  indicator: string;
3016
3266
  track: string;
3267
+ surface: {
3268
+ srgb: {
3269
+ light: string;
3270
+ dark: string;
3271
+ };
3272
+ p3: {
3273
+ light: string;
3274
+ dark: string;
3275
+ };
3276
+ };
3017
3277
  } | {
3018
3278
  srgb: {
3019
3279
  light: {
@@ -3130,6 +3390,16 @@ export declare const colors: ({
3130
3390
  contrast: string;
3131
3391
  indicator: string;
3132
3392
  track: string;
3393
+ surface: {
3394
+ srgb: {
3395
+ light: string;
3396
+ dark: string;
3397
+ };
3398
+ p3: {
3399
+ light: string;
3400
+ dark: string;
3401
+ };
3402
+ };
3133
3403
  } | {
3134
3404
  srgb: {
3135
3405
  light: {
@@ -3246,6 +3516,16 @@ export declare const colors: ({
3246
3516
  contrast: string;
3247
3517
  indicator: string;
3248
3518
  track: string;
3519
+ surface: {
3520
+ srgb: {
3521
+ light: string;
3522
+ dark: string;
3523
+ };
3524
+ p3: {
3525
+ light: string;
3526
+ dark: string;
3527
+ };
3528
+ };
3249
3529
  } | {
3250
3530
  srgb: {
3251
3531
  light: {
@@ -3362,6 +3642,16 @@ export declare const colors: ({
3362
3642
  contrast: string;
3363
3643
  indicator: string;
3364
3644
  track: string;
3645
+ surface: {
3646
+ srgb: {
3647
+ light: string;
3648
+ dark: string;
3649
+ };
3650
+ p3: {
3651
+ light: string;
3652
+ dark: string;
3653
+ };
3654
+ };
3365
3655
  } | {
3366
3656
  srgb: {
3367
3657
  light: {
@@ -3478,6 +3768,16 @@ export declare const colors: ({
3478
3768
  contrast: string;
3479
3769
  indicator: string;
3480
3770
  track: string;
3771
+ surface: {
3772
+ srgb: {
3773
+ light: string;
3774
+ dark: string;
3775
+ };
3776
+ p3: {
3777
+ light: string;
3778
+ dark: string;
3779
+ };
3780
+ };
3481
3781
  } | {
3482
3782
  srgb: {
3483
3783
  light: {
@@ -3594,8 +3894,18 @@ export declare const colors: ({
3594
3894
  contrast: string;
3595
3895
  indicator: string;
3596
3896
  track: string;
3897
+ surface: {
3898
+ srgb: {
3899
+ light: string;
3900
+ dark: string;
3901
+ };
3902
+ p3: {
3903
+ light: string;
3904
+ dark: string;
3905
+ };
3906
+ };
3597
3907
  })[];
3598
3908
  export default colors;
3599
3909
  export { accentColors, grayColors } from './types.ts';
3600
- export type { AccentColor, Color, ColorPalette, ColorScale, GrayColor, } from './types.ts';
3910
+ export type { AccentColor, AlphaConfig, AlphaScale, Color, ColorPalette, ColorScale, GrayColor, } from './types.ts';
3601
3911
  export { css, type ColorConfig } from './lib.ts';
package/dist/types.d.ts CHANGED
@@ -5,7 +5,7 @@ export type AccentColor = (typeof accentColors)[number];
5
5
  export type Color = AccentColor | GrayColor;
6
6
  type ScaleStep = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
7
7
  export type ColorScale<C extends Color> = {
8
- [K in `${C}${ScaleStep}` | `${C}A${ScaleStep}` | 'surface']: string;
8
+ [K in `${C}${ScaleStep}` | `${C}A${ScaleStep}`]: string;
9
9
  };
10
10
  export type ColorPalette<C extends Color> = {
11
11
  srgb: {
@@ -19,5 +19,22 @@ export type ColorPalette<C extends Color> = {
19
19
  contrast: string;
20
20
  indicator: string;
21
21
  track: string;
22
+ surface: {
23
+ srgb: {
24
+ light: string;
25
+ dark: string;
26
+ };
27
+ p3: {
28
+ light: string;
29
+ dark: string;
30
+ };
31
+ };
32
+ };
33
+ export type AlphaScale<C extends 'white' | 'back'> = {
34
+ [K in `${C}A${ScaleStep}`]: string;
35
+ };
36
+ export type AlphaConfig<C extends 'white' | 'back'> = {
37
+ srgb: AlphaScale<C>;
38
+ p3: AlphaScale<C>;
22
39
  };
23
40
  export {};
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@diskette/palette",
3
3
  "type": "module",
4
- "version": "0.8.0",
4
+ "version": "0.9.0",
5
5
  "exports": {
6
6
  ".": "./dist/colors.js",
7
7
  "./colors": "./dist/colors/index.js",