@rookcom/monarch-tokens 0.0.0-stage → 0.2.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 (60) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/README.md +7 -2
  3. package/dist/appearance.d.ts +36 -0
  4. package/dist/appearance.d.ts.map +1 -0
  5. package/dist/appearance.js +42 -0
  6. package/dist/appearance.js.map +1 -0
  7. package/dist/color.d.ts +42 -0
  8. package/dist/color.d.ts.map +1 -0
  9. package/dist/color.js +121 -0
  10. package/dist/color.js.map +1 -0
  11. package/dist/contrast-report.json +1333 -0
  12. package/dist/css/base.css +31 -0
  13. package/dist/css/compat.css +149 -0
  14. package/dist/css/monarch.css +429 -0
  15. package/dist/css/products/app.css +85 -0
  16. package/dist/css/products/atlas.css +85 -0
  17. package/dist/css/products/base.css +85 -0
  18. package/dist/css/products/calendar.css +85 -0
  19. package/dist/css/products/chat.css +85 -0
  20. package/dist/css/products/developers.css +85 -0
  21. package/dist/css/products/dossier.css +85 -0
  22. package/dist/css/products/dots.css +85 -0
  23. package/dist/css/products/friends.css +85 -0
  24. package/dist/css/products/gtm.css +85 -0
  25. package/dist/css/products/id.css +85 -0
  26. package/dist/css/products/intellect.css +85 -0
  27. package/dist/css/products/links.css +85 -0
  28. package/dist/css/products/people.css +85 -0
  29. package/dist/css/products/pulse.css +85 -0
  30. package/dist/css/products/ranker.css +85 -0
  31. package/dist/css/products/recruit.css +85 -0
  32. package/dist/css/products/signal.css +85 -0
  33. package/dist/css/products/stride.css +85 -0
  34. package/dist/css/products/tickets.css +85 -0
  35. package/dist/css.d.ts +36 -0
  36. package/dist/css.d.ts.map +1 -0
  37. package/dist/css.js +242 -0
  38. package/dist/css.js.map +1 -0
  39. package/dist/generated/products.d.ts +111 -0
  40. package/dist/generated/products.d.ts.map +1 -0
  41. package/dist/generated/products.js +26 -0
  42. package/dist/generated/products.js.map +1 -0
  43. package/dist/index.d.ts +8 -0
  44. package/dist/index.d.ts.map +1 -0
  45. package/dist/index.js +8 -0
  46. package/dist/index.js.map +1 -0
  47. package/dist/primitives.d.ts +190 -0
  48. package/dist/primitives.d.ts.map +1 -0
  49. package/dist/primitives.js +210 -0
  50. package/dist/primitives.js.map +1 -0
  51. package/dist/tailwind.d.ts +275 -0
  52. package/dist/tailwind.d.ts.map +1 -0
  53. package/dist/tailwind.js +179 -0
  54. package/dist/tailwind.js.map +1 -0
  55. package/dist/themes.d.ts +74 -0
  56. package/dist/themes.d.ts.map +1 -0
  57. package/dist/themes.js +292 -0
  58. package/dist/themes.js.map +1 -0
  59. package/dist/tokens.json +2455 -0
  60. package/package.json +60 -4
@@ -0,0 +1,85 @@
1
+ /*! Monarch product accent: signal. Generated by @rookcom/monarch-tokens. Do not edit. */
2
+ @layer monarch.tokens, monarch.base, monarch.components;
3
+
4
+ @layer monarch.tokens {
5
+
6
+ [data-mn-product="signal"] {
7
+ --mn-color-accent-solid: hsl(198 100% 35%);
8
+ --mn-color-accent-solid-hover: hsl(198 100% 30%);
9
+ --mn-color-accent-solid-active: hsl(198 100% 26%);
10
+ --mn-color-accent-on-solid: hsl(0 0% 100%);
11
+ --mn-color-accent-subtle: hsl(198 81% 96.5%);
12
+ --mn-color-accent-subtle-hover: hsl(198 81% 93.5%);
13
+ --mn-color-accent-strong: hsl(198 100% 32.5%);
14
+ --mn-color-accent-on-strong: hsl(0 0% 100%);
15
+ --mn-color-accent-border: hsl(198 60% 84%);
16
+ --primary: 198 100% 35%;
17
+ --primary-foreground: 0 0% 100%;
18
+ --ring: 198 100% 32.5%;
19
+ --sidebar-primary: 198 100% 35%;
20
+ --sidebar-primary-foreground: 0 0% 100%;
21
+ --sidebar-ring: 198 100% 32.5%;
22
+ }
23
+
24
+ .dark[data-mn-product="signal"],
25
+ .dark [data-mn-product="signal"],
26
+ [data-mn-theme="dark"][data-mn-product="signal"],
27
+ [data-mn-theme="dark"] [data-mn-product="signal"] {
28
+ --mn-color-accent-solid: hsl(198 100% 35%);
29
+ --mn-color-accent-solid-hover: hsl(198 100% 30%);
30
+ --mn-color-accent-solid-active: hsl(198 100% 26%);
31
+ --mn-color-accent-on-solid: hsl(0 0% 100%);
32
+ --mn-color-accent-subtle: hsl(198 40% 14%);
33
+ --mn-color-accent-subtle-hover: hsl(198 40% 18%);
34
+ --mn-color-accent-strong: hsl(198 100% 46%);
35
+ --mn-color-accent-on-strong: hsl(224 22% 6.5%);
36
+ --mn-color-accent-border: hsl(198 45% 32%);
37
+ --primary: 198 100% 35%;
38
+ --primary-foreground: 0 0% 100%;
39
+ --ring: 198 100% 46%;
40
+ --sidebar-primary: 198 100% 35%;
41
+ --sidebar-primary-foreground: 0 0% 100%;
42
+ --sidebar-ring: 198 100% 46%;
43
+ }
44
+
45
+ [data-mn-contrast="more"][data-mn-product="signal"],
46
+ [data-mn-contrast="more"] [data-mn-product="signal"] {
47
+ --mn-color-accent-solid: hsl(198 100% 26.5%);
48
+ --mn-color-accent-solid-hover: hsl(198 100% 21.5%);
49
+ --mn-color-accent-solid-active: hsl(198 100% 17.5%);
50
+ --mn-color-accent-on-solid: hsl(0 0% 100%);
51
+ --mn-color-accent-subtle: hsl(198 81% 97%);
52
+ --mn-color-accent-subtle-hover: hsl(198 81% 94%);
53
+ --mn-color-accent-strong: hsl(198 100% 24.5%);
54
+ --mn-color-accent-on-strong: hsl(0 0% 100%);
55
+ --mn-color-accent-border: hsl(198 100% 24.5%);
56
+ --primary: 198 100% 26.5%;
57
+ --primary-foreground: 0 0% 100%;
58
+ --ring: 198 100% 24.5%;
59
+ --sidebar-primary: 198 100% 26.5%;
60
+ --sidebar-primary-foreground: 0 0% 100%;
61
+ --sidebar-ring: 198 100% 24.5%;
62
+ }
63
+
64
+ .dark[data-mn-contrast="more"][data-mn-product="signal"],
65
+ .dark[data-mn-contrast="more"] [data-mn-product="signal"],
66
+ [data-mn-theme="dark"][data-mn-contrast="more"][data-mn-product="signal"],
67
+ [data-mn-theme="dark"][data-mn-contrast="more"] [data-mn-product="signal"] {
68
+ --mn-color-accent-solid: hsl(198 100% 46.5%);
69
+ --mn-color-accent-solid-hover: hsl(198 100% 51.5%);
70
+ --mn-color-accent-solid-active: hsl(198 100% 55.5%);
71
+ --mn-color-accent-on-solid: hsl(224 22% 6.5%);
72
+ --mn-color-accent-subtle: hsl(198 40% 10%);
73
+ --mn-color-accent-subtle-hover: hsl(198 40% 14%);
74
+ --mn-color-accent-strong: hsl(198 100% 57%);
75
+ --mn-color-accent-on-strong: hsl(224 22% 6.5%);
76
+ --mn-color-accent-border: hsl(198 100% 57%);
77
+ --primary: 198 100% 46.5%;
78
+ --primary-foreground: 224 22% 6.5%;
79
+ --ring: 198 100% 57%;
80
+ --sidebar-primary: 198 100% 46.5%;
81
+ --sidebar-primary-foreground: 224 22% 6.5%;
82
+ --sidebar-ring: 198 100% 57%;
83
+ }
84
+
85
+ }
@@ -0,0 +1,85 @@
1
+ /*! Monarch product accent: stride. Generated by @rookcom/monarch-tokens. Do not edit. */
2
+ @layer monarch.tokens, monarch.base, monarch.components;
3
+
4
+ @layer monarch.tokens {
5
+
6
+ [data-mn-product="stride"] {
7
+ --mn-color-accent-solid: hsl(136 63% 32.5%);
8
+ --mn-color-accent-solid-hover: hsl(136 63% 27.5%);
9
+ --mn-color-accent-solid-active: hsl(136 63% 23.5%);
10
+ --mn-color-accent-on-solid: hsl(0 0% 100%);
11
+ --mn-color-accent-subtle: hsl(136 56.7% 96.5%);
12
+ --mn-color-accent-subtle-hover: hsl(136 56.7% 93.5%);
13
+ --mn-color-accent-strong: hsl(136 63% 30.5%);
14
+ --mn-color-accent-on-strong: hsl(0 0% 100%);
15
+ --mn-color-accent-border: hsl(136 37.8% 84%);
16
+ --primary: 136 63% 32.5%;
17
+ --primary-foreground: 0 0% 100%;
18
+ --ring: 136 63% 30.5%;
19
+ --sidebar-primary: 136 63% 32.5%;
20
+ --sidebar-primary-foreground: 0 0% 100%;
21
+ --sidebar-ring: 136 63% 30.5%;
22
+ }
23
+
24
+ .dark[data-mn-product="stride"],
25
+ .dark [data-mn-product="stride"],
26
+ [data-mn-theme="dark"][data-mn-product="stride"],
27
+ [data-mn-theme="dark"] [data-mn-product="stride"] {
28
+ --mn-color-accent-solid: hsl(136 63% 32.5%);
29
+ --mn-color-accent-solid-hover: hsl(136 63% 27.5%);
30
+ --mn-color-accent-solid-active: hsl(136 63% 23.5%);
31
+ --mn-color-accent-on-solid: hsl(0 0% 100%);
32
+ --mn-color-accent-subtle: hsl(136 25.2% 14%);
33
+ --mn-color-accent-subtle-hover: hsl(136 25.2% 18%);
34
+ --mn-color-accent-strong: hsl(136 63% 43%);
35
+ --mn-color-accent-on-strong: hsl(224 22% 6.5%);
36
+ --mn-color-accent-border: hsl(136 28.4% 32%);
37
+ --primary: 136 63% 32.5%;
38
+ --primary-foreground: 0 0% 100%;
39
+ --ring: 136 63% 43%;
40
+ --sidebar-primary: 136 63% 32.5%;
41
+ --sidebar-primary-foreground: 0 0% 100%;
42
+ --sidebar-ring: 136 63% 43%;
43
+ }
44
+
45
+ [data-mn-contrast="more"][data-mn-product="stride"],
46
+ [data-mn-contrast="more"] [data-mn-product="stride"] {
47
+ --mn-color-accent-solid: hsl(136 63% 24.5%);
48
+ --mn-color-accent-solid-hover: hsl(136 63% 19.5%);
49
+ --mn-color-accent-solid-active: hsl(136 63% 15.5%);
50
+ --mn-color-accent-on-solid: hsl(0 0% 100%);
51
+ --mn-color-accent-subtle: hsl(136 56.7% 97%);
52
+ --mn-color-accent-subtle-hover: hsl(136 56.7% 94%);
53
+ --mn-color-accent-strong: hsl(136 63% 22.5%);
54
+ --mn-color-accent-on-strong: hsl(0 0% 100%);
55
+ --mn-color-accent-border: hsl(136 63% 22.5%);
56
+ --primary: 136 63% 24.5%;
57
+ --primary-foreground: 0 0% 100%;
58
+ --ring: 136 63% 22.5%;
59
+ --sidebar-primary: 136 63% 24.5%;
60
+ --sidebar-primary-foreground: 0 0% 100%;
61
+ --sidebar-ring: 136 63% 22.5%;
62
+ }
63
+
64
+ .dark[data-mn-contrast="more"][data-mn-product="stride"],
65
+ .dark[data-mn-contrast="more"] [data-mn-product="stride"],
66
+ [data-mn-theme="dark"][data-mn-contrast="more"][data-mn-product="stride"],
67
+ [data-mn-theme="dark"][data-mn-contrast="more"] [data-mn-product="stride"] {
68
+ --mn-color-accent-solid: hsl(136 63% 43.5%);
69
+ --mn-color-accent-solid-hover: hsl(136 63% 48.5%);
70
+ --mn-color-accent-solid-active: hsl(136 63% 52.5%);
71
+ --mn-color-accent-on-solid: hsl(224 22% 6.5%);
72
+ --mn-color-accent-subtle: hsl(136 25.2% 10%);
73
+ --mn-color-accent-subtle-hover: hsl(136 25.2% 14%);
74
+ --mn-color-accent-strong: hsl(136 63% 50%);
75
+ --mn-color-accent-on-strong: hsl(224 22% 6.5%);
76
+ --mn-color-accent-border: hsl(136 63% 50%);
77
+ --primary: 136 63% 43.5%;
78
+ --primary-foreground: 224 22% 6.5%;
79
+ --ring: 136 63% 50%;
80
+ --sidebar-primary: 136 63% 43.5%;
81
+ --sidebar-primary-foreground: 224 22% 6.5%;
82
+ --sidebar-ring: 136 63% 50%;
83
+ }
84
+
85
+ }
@@ -0,0 +1,85 @@
1
+ /*! Monarch product accent: tickets. Generated by @rookcom/monarch-tokens. Do not edit. */
2
+ @layer monarch.tokens, monarch.base, monarch.components;
3
+
4
+ @layer monarch.tokens {
5
+
6
+ [data-mn-product="tickets"] {
7
+ --mn-color-accent-solid: hsl(354 71% 52%);
8
+ --mn-color-accent-solid-hover: hsl(354 71% 47%);
9
+ --mn-color-accent-solid-active: hsl(354 71% 43%);
10
+ --mn-color-accent-on-solid: hsl(0 0% 100%);
11
+ --mn-color-accent-subtle: hsl(354 63.9% 96.5%);
12
+ --mn-color-accent-subtle-hover: hsl(354 63.9% 93.5%);
13
+ --mn-color-accent-strong: hsl(354 71% 46.5%);
14
+ --mn-color-accent-on-strong: hsl(0 0% 100%);
15
+ --mn-color-accent-border: hsl(354 42.6% 84%);
16
+ --primary: 354 71% 52%;
17
+ --primary-foreground: 0 0% 100%;
18
+ --ring: 354 71% 46.5%;
19
+ --sidebar-primary: 354 71% 52%;
20
+ --sidebar-primary-foreground: 0 0% 100%;
21
+ --sidebar-ring: 354 71% 46.5%;
22
+ }
23
+
24
+ .dark[data-mn-product="tickets"],
25
+ .dark [data-mn-product="tickets"],
26
+ [data-mn-theme="dark"][data-mn-product="tickets"],
27
+ [data-mn-theme="dark"] [data-mn-product="tickets"] {
28
+ --mn-color-accent-solid: hsl(354 71% 52%);
29
+ --mn-color-accent-solid-hover: hsl(354 71% 47%);
30
+ --mn-color-accent-solid-active: hsl(354 71% 43%);
31
+ --mn-color-accent-on-solid: hsl(0 0% 100%);
32
+ --mn-color-accent-subtle: hsl(354 28.4% 14%);
33
+ --mn-color-accent-subtle-hover: hsl(354 28.4% 18%);
34
+ --mn-color-accent-strong: hsl(354 71% 65%);
35
+ --mn-color-accent-on-strong: hsl(224 22% 6.5%);
36
+ --mn-color-accent-border: hsl(354 32% 32%);
37
+ --primary: 354 71% 52%;
38
+ --primary-foreground: 0 0% 100%;
39
+ --ring: 354 71% 65%;
40
+ --sidebar-primary: 354 71% 52%;
41
+ --sidebar-primary-foreground: 0 0% 100%;
42
+ --sidebar-ring: 354 71% 65%;
43
+ }
44
+
45
+ [data-mn-contrast="more"][data-mn-product="tickets"],
46
+ [data-mn-contrast="more"] [data-mn-product="tickets"] {
47
+ --mn-color-accent-solid: hsl(354 71% 39.5%);
48
+ --mn-color-accent-solid-hover: hsl(354 71% 34.5%);
49
+ --mn-color-accent-solid-active: hsl(354 71% 30.5%);
50
+ --mn-color-accent-on-solid: hsl(0 0% 100%);
51
+ --mn-color-accent-subtle: hsl(354 63.9% 97%);
52
+ --mn-color-accent-subtle-hover: hsl(354 63.9% 94%);
53
+ --mn-color-accent-strong: hsl(354 71% 34.5%);
54
+ --mn-color-accent-on-strong: hsl(0 0% 100%);
55
+ --mn-color-accent-border: hsl(354 71% 34.5%);
56
+ --primary: 354 71% 39.5%;
57
+ --primary-foreground: 0 0% 100%;
58
+ --ring: 354 71% 34.5%;
59
+ --sidebar-primary: 354 71% 39.5%;
60
+ --sidebar-primary-foreground: 0 0% 100%;
61
+ --sidebar-ring: 354 71% 34.5%;
62
+ }
63
+
64
+ .dark[data-mn-contrast="more"][data-mn-product="tickets"],
65
+ .dark[data-mn-contrast="more"] [data-mn-product="tickets"],
66
+ [data-mn-theme="dark"][data-mn-contrast="more"][data-mn-product="tickets"],
67
+ [data-mn-theme="dark"][data-mn-contrast="more"] [data-mn-product="tickets"] {
68
+ --mn-color-accent-solid: hsl(354 71% 70%);
69
+ --mn-color-accent-solid-hover: hsl(354 71% 75%);
70
+ --mn-color-accent-solid-active: hsl(354 71% 79%);
71
+ --mn-color-accent-on-solid: hsl(224 22% 6.5%);
72
+ --mn-color-accent-subtle: hsl(354 28.4% 10%);
73
+ --mn-color-accent-subtle-hover: hsl(354 28.4% 14%);
74
+ --mn-color-accent-strong: hsl(354 71% 74.5%);
75
+ --mn-color-accent-on-strong: hsl(224 22% 6.5%);
76
+ --mn-color-accent-border: hsl(354 71% 74.5%);
77
+ --primary: 354 71% 70%;
78
+ --primary-foreground: 224 22% 6.5%;
79
+ --ring: 354 71% 74.5%;
80
+ --sidebar-primary: 354 71% 70%;
81
+ --sidebar-primary-foreground: 224 22% 6.5%;
82
+ --sidebar-ring: 354 71% 74.5%;
83
+ }
84
+
85
+ }
package/dist/css.d.ts ADDED
@@ -0,0 +1,36 @@
1
+ /**
2
+ * CSS generation. Pure functions, so output is reproducible and testable.
3
+ *
4
+ * Selector contract (documented in docs/guides/theming.md):
5
+ * theme <html class="dark"> or <html data-mn-theme="dark|light">
6
+ * contrast <html data-mn-contrast="more">
7
+ * product <html data-mn-product="tickets"> (from products/<id>.css)
8
+ *
9
+ * Theme blocks are emitted in the order light, dark, hc-light, hc-dark. The
10
+ * first three share specificity (0,1,0) and rely on source order; hc-dark
11
+ * combines both attributes (0,2,0). Product blocks add [data-mn-product] to
12
+ * each theme selector, so a product + theme combination always beats the
13
+ * theme alone whichever file loads first.
14
+ */
15
+ import { type Hsl } from './color.js';
16
+ import { type IntentRole, type ResolvedTheme, type ThemeId } from './themes.js';
17
+ export declare const LAYER = "monarch.tokens";
18
+ /** Declared in every Monarch stylesheet so the order holds whichever loads first. */
19
+ export declare const LAYER_ORDER = "@layer monarch.tokens, monarch.base, monarch.components;";
20
+ /** Root-level selectors for each theme. */
21
+ export declare function themeSelectors(id: ThemeId): string[];
22
+ /** Selectors for a product accent in each theme (same element or descendant). */
23
+ export declare function productSelectors(productId: string, id: ThemeId): string[];
24
+ /** CSS custom property name for a key, e.g. space `0.5` → `--mn-space-0-5`. */
25
+ export declare function varName(group: string, key: string | number): string;
26
+ type Decls = ReadonlyArray<readonly [string, string]>;
27
+ /** Theme-independent tokens. */
28
+ export declare function staticDecls(): Decls;
29
+ export declare const NEUTRAL_ROLES: readonly ["bg-canvas", "bg-surface", "bg-raised", "bg-subtle", "bg-muted", "bg-emphasis", "bg-inverse", "text-default", "text-muted", "text-subtle", "text-disabled", "text-inverse", "border-subtle", "border-default", "border-strong", "border-input"];
30
+ export declare const INTENT_ROLES: readonly IntentRole[];
31
+ export declare function themeDecls(resolved: ResolvedTheme): Decls;
32
+ export declare function buildMonarchCss(defaultAccent: Hsl): string;
33
+ export declare function buildProductCss(productId: string, accent: Hsl): string;
34
+ export declare function buildCompatCss(defaultAccent: Hsl): string;
35
+ export {};
36
+ //# sourceMappingURL=css.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"css.d.ts","sourceRoot":"","sources":["../src/css.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,OAAO,EAAqB,KAAK,GAAG,EAAE,MAAM,YAAY,CAAC;AAiBzD,OAAO,EAKL,KAAK,UAAU,EAGf,KAAK,aAAa,EAClB,KAAK,OAAO,EACb,MAAM,aAAa,CAAC;AAErB,eAAO,MAAM,KAAK,mBAAmB,CAAC;AACtC,qFAAqF;AACrF,eAAO,MAAM,WAAW,6DAA6D,CAAC;AAKtF,2CAA2C;AAC3C,wBAAgB,cAAc,CAAC,EAAE,EAAE,OAAO,GAAG,MAAM,EAAE,CAWpD;AAED,iFAAiF;AACjF,wBAAgB,gBAAgB,CAAC,SAAS,EAAE,MAAM,EAAE,EAAE,EAAE,OAAO,GAAG,MAAM,EAAE,CAIzE;AAED,+EAA+E;AAC/E,wBAAgB,OAAO,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,CAEnE;AAED,KAAK,KAAK,GAAG,aAAa,CAAC,SAAS,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;AAWtD,gCAAgC;AAChC,wBAAgB,WAAW,IAAI,KAAK,CA+BnC;AAED,eAAO,MAAM,aAAa,2PAiB0B,CAAC;AAErD,eAAO,MAAM,YAAY,EAAE,SAAS,UAAU,EAU7C,CAAC;AAoBF,wBAAgB,UAAU,CAAC,QAAQ,EAAE,aAAa,GAAG,KAAK,CAmBzD;AAWD,wBAAgB,eAAe,CAAC,aAAa,EAAE,GAAG,GAAG,MAAM,CAO1D;AAED,wBAAgB,eAAe,CAAC,SAAS,EAAE,MAAM,EAAE,MAAM,EAAE,GAAG,GAAG,MAAM,CAatE;AAsDD,wBAAgB,cAAc,CAAC,aAAa,EAAE,GAAG,GAAG,MAAM,CAczD"}
package/dist/css.js ADDED
@@ -0,0 +1,242 @@
1
+ /**
2
+ * CSS generation. Pure functions, so output is reproducible and testable.
3
+ *
4
+ * Selector contract (documented in docs/guides/theming.md):
5
+ * theme <html class="dark"> or <html data-mn-theme="dark|light">
6
+ * contrast <html data-mn-contrast="more">
7
+ * product <html data-mn-product="tickets"> (from products/<id>.css)
8
+ *
9
+ * Theme blocks are emitted in the order light, dark, hc-light, hc-dark. The
10
+ * first three share specificity (0,1,0) and rely on source order; hc-dark
11
+ * combines both attributes (0,2,0). Product blocks add [data-mn-product] to
12
+ * each theme selector, so a product + theme combination always beats the
13
+ * theme alone whichever file loads first.
14
+ */
15
+ import { toChannels, toCss } from './color.js';
16
+ import { breakpoint, controlHeight, duration, easing, fontFamily, fontSize, fontWeight, layout, letterSpacing, lineHeight, radius, space, spectrum, zIndex, } from './primitives.js';
17
+ import { INTENT_IDS, THEME_IDS, resolveTheme, themes, } from './themes.js';
18
+ export const LAYER = 'monarch.tokens';
19
+ /** Declared in every Monarch stylesheet so the order holds whichever loads first. */
20
+ export const LAYER_ORDER = '@layer monarch.tokens, monarch.base, monarch.components;';
21
+ const DARK = ['.dark', '[data-mn-theme="dark"]'];
22
+ const HC = ['[data-mn-contrast="more"]'];
23
+ /** Root-level selectors for each theme. */
24
+ export function themeSelectors(id) {
25
+ switch (id) {
26
+ case 'light':
27
+ return [':root', '[data-mn-theme="light"]'];
28
+ case 'dark':
29
+ return [...DARK];
30
+ case 'hc-light':
31
+ return [...HC];
32
+ case 'hc-dark':
33
+ return DARK.flatMap((d) => HC.map((h) => `${d}${h}`));
34
+ }
35
+ }
36
+ /** Selectors for a product accent in each theme (same element or descendant). */
37
+ export function productSelectors(productId, id) {
38
+ const p = `[data-mn-product="${productId}"]`;
39
+ if (id === 'light')
40
+ return [p];
41
+ return themeSelectors(id).flatMap((q) => [`${q}${p}`, `${q} ${p}`]);
42
+ }
43
+ /** CSS custom property name for a key, e.g. space `0.5` → `--mn-space-0-5`. */
44
+ export function varName(group, key) {
45
+ return `--mn-${group}-${String(key).replace('.', '-')}`;
46
+ }
47
+ function block(selectors, decls, indent = ' ') {
48
+ const body = decls.map(([k, v]) => `${indent} ${k}: ${v};`).join('\n');
49
+ return `${indent}${selectors.join(',\n' + indent)} {\n${body}\n${indent}}`;
50
+ }
51
+ function entries(group, obj) {
52
+ return Object.entries(obj).map(([k, v]) => [varName(group, k), v]);
53
+ }
54
+ /** Theme-independent tokens. */
55
+ export function staticDecls() {
56
+ const spectrumDecls = [];
57
+ for (const [name, ramp] of Object.entries(spectrum)) {
58
+ spectrumDecls.push([`--mn-color-spectrum-${name}`, toCss(ramp[500])]);
59
+ }
60
+ return [
61
+ ['--mn-font-sans', fontFamily.sans],
62
+ ['--mn-font-mono', fontFamily.mono],
63
+ ...entries('text', fontSize),
64
+ ...entries('leading', lineHeight),
65
+ ...entries('weight', fontWeight),
66
+ ...entries('tracking', letterSpacing),
67
+ ...Object.entries(space).map(([k, v]) => [varName('space', k), v]),
68
+ ...entries('radius', radius),
69
+ ...entries('control', controlHeight),
70
+ ...entries('duration', duration),
71
+ ...entries('ease', easing),
72
+ ...entries('breakpoint', breakpoint),
73
+ ...entries('z', zIndex),
74
+ ['--mn-layout-rail-collapsed', layout.railCollapsed],
75
+ ['--mn-layout-rail-expanded', layout.railExpanded],
76
+ ['--mn-layout-content-max', layout.contentMax],
77
+ ['--mn-layout-reading-max', layout.readingMax],
78
+ ['--mn-layout-gutter', layout.gutter],
79
+ ['--mn-layout-gutter-lg', layout.gutterLg],
80
+ ...spectrumDecls,
81
+ [
82
+ '--mn-gradient-spectrum',
83
+ `linear-gradient(120deg, ${toCss(spectrum.blue[500])}, ${toCss(spectrum.violet[500])} 30%, ${toCss(spectrum.purple[500])} 55%, ${toCss(spectrum.pink[500])} 78%, ${toCss(spectrum.orange[500])})`,
84
+ ],
85
+ ];
86
+ }
87
+ export const NEUTRAL_ROLES = [
88
+ 'bg-canvas',
89
+ 'bg-surface',
90
+ 'bg-raised',
91
+ 'bg-subtle',
92
+ 'bg-muted',
93
+ 'bg-emphasis',
94
+ 'bg-inverse',
95
+ 'text-default',
96
+ 'text-muted',
97
+ 'text-subtle',
98
+ 'text-disabled',
99
+ 'text-inverse',
100
+ 'border-subtle',
101
+ 'border-default',
102
+ 'border-strong',
103
+ 'border-input',
104
+ ];
105
+ export const INTENT_ROLES = [
106
+ 'solid',
107
+ 'solid-hover',
108
+ 'solid-active',
109
+ 'on-solid',
110
+ 'subtle',
111
+ 'subtle-hover',
112
+ 'strong',
113
+ 'on-strong',
114
+ 'border',
115
+ ];
116
+ function intentDecls(intent, scale) {
117
+ return INTENT_ROLES.map((role) => [`--mn-color-${intent}-${role}`, toCss(scale[role])]);
118
+ }
119
+ /** Categorical data-visualisation palette, distinguishable in both schemes. */
120
+ function dataDecls(scheme) {
121
+ const step = scheme === 'dark' ? 400 : 600;
122
+ const order = [
123
+ spectrum.blue,
124
+ spectrum.orange,
125
+ spectrum.violet,
126
+ spectrum.pink,
127
+ spectrum.purple,
128
+ ];
129
+ const out = order.map((r, i) => [`--mn-color-data-${i + 1}`, toCss(r[step])]);
130
+ return out;
131
+ }
132
+ export function themeDecls(resolved) {
133
+ const { theme } = resolved;
134
+ const n = theme.neutrals;
135
+ return [
136
+ ['color-scheme', theme.scheme],
137
+ ...NEUTRAL_ROLES.map((r) => [`--mn-color-${r}`, toCss(n[r])]),
138
+ ...INTENT_IDS.flatMap((id) => intentDecls(id, resolved.intents[id])),
139
+ ['--mn-color-text-link', 'var(--mn-color-accent-strong)'],
140
+ [
141
+ '--mn-color-focus-ring',
142
+ theme.contrast === 'more' ? 'var(--mn-color-text-default)' : 'var(--mn-color-accent-strong)',
143
+ ],
144
+ ['--mn-focus-ring-width', theme.contrast === 'more' ? '3px' : '2px'],
145
+ ['--mn-color-overlay-scrim', theme.scrim],
146
+ ...['xs', 'sm', 'md', 'lg', 'xl'].map((k) => [`--mn-shadow-${k}`, theme.shadow[k]]),
147
+ ...dataDecls(theme.scheme),
148
+ ];
149
+ }
150
+ /** Reduced motion: every duration collapses, so components need no special casing. */
151
+ const REDUCED_MOTION = ` @media (prefers-reduced-motion: reduce) {
152
+ :root {
153
+ ${Object.keys(duration)
154
+ .map((k) => ` ${varName('duration', k)}: 0ms;`)
155
+ .join('\n')}
156
+ }
157
+ }`;
158
+ export function buildMonarchCss(defaultAccent) {
159
+ const parts = [`@layer ${LAYER} {`, block([':root'], staticDecls())];
160
+ for (const id of THEME_IDS) {
161
+ parts.push(block(themeSelectors(id), themeDecls(resolveTheme(themes[id], defaultAccent))));
162
+ }
163
+ parts.push(REDUCED_MOTION, '}');
164
+ return header('Monarch tokens') + parts.join('\n\n') + '\n';
165
+ }
166
+ export function buildProductCss(productId, accent) {
167
+ const parts = [`@layer ${LAYER} {`];
168
+ for (const id of THEME_IDS) {
169
+ const resolved = resolveTheme(themes[id], accent);
170
+ parts.push(block(productSelectors(productId, id), [
171
+ ...intentDecls('accent', resolved.intents.accent),
172
+ ...compatAccentDecls(resolved),
173
+ ]));
174
+ }
175
+ parts.push('}');
176
+ return header(`Monarch product accent: ${productId}`) + parts.join('\n\n') + '\n';
177
+ }
178
+ /**
179
+ * Legacy bridge for apps still on shadcn-style variables (`hsl(var(--primary))`).
180
+ * Values are generated from Monarch tokens, never authored separately. Meaning
181
+ * of existing names is preserved: Rook's `secondary` and `accent` have always
182
+ * been the blue informational colour, so they map to `info`, not to a neutral.
183
+ */
184
+ function compatNeutralDecls(r) {
185
+ const n = r.theme.neutrals;
186
+ const i = r.intents;
187
+ const c = (h) => toChannels(h);
188
+ return [
189
+ ['--background', c(n['bg-canvas'])],
190
+ ['--foreground', c(n['text-default'])],
191
+ ['--card', c(n['bg-surface'])],
192
+ ['--card-foreground', c(n['text-default'])],
193
+ ['--popover', c(n['bg-raised'])],
194
+ ['--popover-foreground', c(n['text-default'])],
195
+ ['--secondary', c(i.info.solid)],
196
+ ['--secondary-foreground', c(i.info['on-solid'])],
197
+ ['--accent', c(i.info.solid)],
198
+ ['--accent-foreground', c(i.info['on-solid'])],
199
+ ['--success', c(i.success.solid)],
200
+ ['--success-foreground', c(i.success['on-solid'])],
201
+ ['--warning', c(i.warning.solid)],
202
+ ['--warning-foreground', c(i.warning['on-solid'])],
203
+ ['--destructive', c(i.danger.solid)],
204
+ ['--destructive-foreground', c(i.danger['on-solid'])],
205
+ ['--muted', c(n['bg-muted'])],
206
+ ['--muted-foreground', c(n['text-muted'])],
207
+ ['--border', c(n['border-default'])],
208
+ ['--input', c(n['border-input'])],
209
+ ['--radius', radius.lg],
210
+ ['--sidebar-background', c(n['bg-surface'])],
211
+ ['--sidebar-foreground', c(n['text-default'])],
212
+ ['--sidebar-accent', c(n['bg-muted'])],
213
+ ['--sidebar-accent-foreground', c(n['text-default'])],
214
+ ['--sidebar-border', c(n['border-default'])],
215
+ ];
216
+ }
217
+ function compatAccentDecls(r) {
218
+ const a = r.intents.accent;
219
+ return [
220
+ ['--primary', toChannels(a.solid)],
221
+ ['--primary-foreground', toChannels(a['on-solid'])],
222
+ ['--ring', toChannels(a.strong)],
223
+ ['--sidebar-primary', toChannels(a.solid)],
224
+ ['--sidebar-primary-foreground', toChannels(a['on-solid'])],
225
+ ['--sidebar-ring', toChannels(a.strong)],
226
+ ];
227
+ }
228
+ export function buildCompatCss(defaultAccent) {
229
+ const parts = [`@layer ${LAYER} {`];
230
+ for (const id of THEME_IDS) {
231
+ const resolved = resolveTheme(themes[id], defaultAccent);
232
+ parts.push(block(themeSelectors(id), [...compatNeutralDecls(resolved), ...compatAccentDecls(resolved)]));
233
+ }
234
+ parts.push('}');
235
+ return (header('Monarch legacy bridge (shadcn variable names). Deprecated: remove after migration.') +
236
+ parts.join('\n\n') +
237
+ '\n');
238
+ }
239
+ function header(title) {
240
+ return `/*! ${title}. Generated by @rookcom/monarch-tokens. Do not edit. */\n${LAYER_ORDER}\n\n`;
241
+ }
242
+ //# sourceMappingURL=css.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"css.js","sourceRoot":"","sources":["../src/css.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,OAAO,EAAE,UAAU,EAAE,KAAK,EAAY,MAAM,YAAY,CAAC;AACzD,OAAO,EACL,UAAU,EACV,aAAa,EACb,QAAQ,EACR,MAAM,EACN,UAAU,EACV,QAAQ,EACR,UAAU,EACV,MAAM,EACN,aAAa,EACb,UAAU,EACV,MAAM,EACN,KAAK,EACL,QAAQ,EACR,MAAM,GACP,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,UAAU,EACV,SAAS,EACT,YAAY,EACZ,MAAM,GAMP,M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CAAC,CAAC,CAAC;QACnD,CAAC,QAAQ,EAAE,UAAU,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC;QAChC,CAAC,mBAAmB,EAAE,UAAU,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;QAC1C,CAAC,8BAA8B,EAAE,UAAU,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC;QAC3D,CAAC,gBAAgB,EAAE,UAAU,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC;KACzC,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,cAAc,CAAC,aAAkB;IAC/C,MAAM,KAAK,GAAG,CAAC,UAAU,KAAK,IAAI,CAAC,CAAC;IACpC,KAAK,MAAM,EAAE,IAAI,SAAS,EAAE,CAAC;QAC3B,MAAM,QAAQ,GAAG,YAAY,CAAC,MAAM,CAAC,EAAE,CAAC,EAAE,aAAa,CAAC,CAAC;QACzD,KAAK,CAAC,IAAI,CACR,KAAK,CAAC,cAAc,CAAC,EAAE,CAAC,EAAE,CAAC,GAAG,kBAAkB,CAAC,QAAQ,CAAC,EAAE,GAAG,iBAAiB,CAAC,QAAQ,CAAC,CAAC,CAAC,CAC7F,CAAC;IACJ,CAAC;IACD,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IAChB,OAAO,CACL,MAAM,CAAC,oFAAoF,CAAC;QAC5F,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC;QAClB,IAAI,CACL,CAAC;AACJ,CAAC;AAED,SAAS,MAAM,CAAC,KAAa;IAC3B,OAAO,OAAO,KAAK,4DAA4D,WAAW,MAAM,CAAC;AACnG,CAAC"}
@@ -0,0 +1,111 @@
1
+ import { type Hsl } from '../color.js';
2
+ export interface ProductAccent {
3
+ readonly id: string;
4
+ readonly name: string;
5
+ readonly accent: Hsl;
6
+ }
7
+ export declare const products: {
8
+ readonly app: {
9
+ readonly id: "app";
10
+ readonly name: "Rook App";
11
+ readonly accent: Hsl;
12
+ };
13
+ readonly atlas: {
14
+ readonly id: "atlas";
15
+ readonly name: "Rook Atlas";
16
+ readonly accent: Hsl;
17
+ };
18
+ readonly base: {
19
+ readonly id: "base";
20
+ readonly name: "Rook Base";
21
+ readonly accent: Hsl;
22
+ };
23
+ readonly calendar: {
24
+ readonly id: "calendar";
25
+ readonly name: "Rook Calendar";
26
+ readonly accent: Hsl;
27
+ };
28
+ readonly chat: {
29
+ readonly id: "chat";
30
+ readonly name: "Rook Chat";
31
+ readonly accent: Hsl;
32
+ };
33
+ readonly developers: {
34
+ readonly id: "developers";
35
+ readonly name: "Rook Developers";
36
+ readonly accent: Hsl;
37
+ };
38
+ readonly dossier: {
39
+ readonly id: "dossier";
40
+ readonly name: "Rook Dossier";
41
+ readonly accent: Hsl;
42
+ };
43
+ readonly dots: {
44
+ readonly id: "dots";
45
+ readonly name: "Rook Dots";
46
+ readonly accent: Hsl;
47
+ };
48
+ readonly friends: {
49
+ readonly id: "friends";
50
+ readonly name: "Rook Friends";
51
+ readonly accent: Hsl;
52
+ };
53
+ readonly gtm: {
54
+ readonly id: "gtm";
55
+ readonly name: "Rook GTM";
56
+ readonly accent: Hsl;
57
+ };
58
+ readonly id: {
59
+ readonly id: "id";
60
+ readonly name: "Rook ID & Workspace";
61
+ readonly accent: Hsl;
62
+ };
63
+ readonly intellect: {
64
+ readonly id: "intellect";
65
+ readonly name: "Rook Intellect";
66
+ readonly accent: Hsl;
67
+ };
68
+ readonly links: {
69
+ readonly id: "links";
70
+ readonly name: "Rook Links";
71
+ readonly accent: Hsl;
72
+ };
73
+ readonly people: {
74
+ readonly id: "people";
75
+ readonly name: "Rook People";
76
+ readonly accent: Hsl;
77
+ };
78
+ readonly pulse: {
79
+ readonly id: "pulse";
80
+ readonly name: "Rook Pulse";
81
+ readonly accent: Hsl;
82
+ };
83
+ readonly ranker: {
84
+ readonly id: "ranker";
85
+ readonly name: "Rook Ranker";
86
+ readonly accent: Hsl;
87
+ };
88
+ readonly recruit: {
89
+ readonly id: "recruit";
90
+ readonly name: "Rook Recruit";
91
+ readonly accent: Hsl;
92
+ };
93
+ readonly signal: {
94
+ readonly id: "signal";
95
+ readonly name: "Rook Signal";
96
+ readonly accent: Hsl;
97
+ };
98
+ readonly stride: {
99
+ readonly id: "stride";
100
+ readonly name: "Rook Stride";
101
+ readonly accent: Hsl;
102
+ };
103
+ readonly tickets: {
104
+ readonly id: "tickets";
105
+ readonly name: "Rook Tickets";
106
+ readonly accent: Hsl;
107
+ };
108
+ };
109
+ export type ProductId = keyof typeof products;
110
+ export declare const productIds: ProductId[];
111
+ //# sourceMappingURL=products.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"products.d.ts","sourceRoot":"","sources":["../../src/generated/products.ts"],"names":[],"mappings":"AACA,OAAO,EAAO,KAAK,GAAG,EAAE,MAAM,aAAa,CAAC;AAE5C,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,MAAM,EAAE,GAAG,CAAC;CACtB;AAED,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAqB6B,CAAC;AAEnD,MAAM,MAAM,SAAS,GAAG,MAAM,OAAO,QAAQ,CAAC;AAC9C,eAAO,MAAM,UAAU,EAA4B,SAAS,EAAE,CAAC"}