@astryx-vue/themes 0.3.0 → 0.4.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.
Files changed (94) hide show
  1. package/butter/badge.css +5 -0
  2. package/butter/banner.css +29 -0
  3. package/butter/base.css +16 -89
  4. package/butter/button.css +6 -0
  5. package/butter/card.css +81 -0
  6. package/butter/input.css +13 -10
  7. package/butter/mobile-type.css +55 -0
  8. package/butter/progress-bar.css +5 -4
  9. package/butter/section.css +7 -0
  10. package/butter/top-nav.css +35 -0
  11. package/butter.css +4 -0
  12. package/chocolate/base.css +17 -90
  13. package/chocolate/button.css +4 -6
  14. package/chocolate/card.css +1 -0
  15. package/chocolate/mobile-type.css +55 -0
  16. package/chocolate/section.css +7 -0
  17. package/chocolate.css +3 -0
  18. package/data.css +84 -0
  19. package/gothic/badge.css +1 -0
  20. package/gothic/banner.css +32 -0
  21. package/gothic/base.css +16 -89
  22. package/gothic/card.css +57 -0
  23. package/gothic/code.css +5 -4
  24. package/gothic/section.css +7 -0
  25. package/gothic.css +2 -0
  26. package/matcha/base.css +3 -76
  27. package/matcha/button.css +1 -0
  28. package/matcha/card.css +2 -0
  29. package/matcha/section.css +8 -0
  30. package/matcha.css +2 -0
  31. package/neutral/alert-dialog.css +2 -2
  32. package/neutral/avatar-group.css +3 -3
  33. package/neutral/avatar.css +7 -7
  34. package/neutral/badge.css +31 -28
  35. package/neutral/banner.css +57 -10
  36. package/neutral/base.css +123 -190
  37. package/neutral/bottom-sheet.css +6 -6
  38. package/neutral/button.css +15 -5
  39. package/neutral/card.css +12 -12
  40. package/neutral/chat.css +1 -1
  41. package/neutral/checkbox.css +5 -5
  42. package/neutral/code.css +10 -12
  43. package/neutral/collapsible.css +4 -4
  44. package/neutral/context-menu.css +8 -8
  45. package/neutral/dialog.css +3 -3
  46. package/neutral/divider.css +3 -3
  47. package/neutral/dropdown-menu.css +4 -4
  48. package/neutral/empty-state.css +2 -2
  49. package/neutral/heading.css +13 -15
  50. package/neutral/hover-card.css +3 -3
  51. package/neutral/icon.css +2 -2
  52. package/neutral/input.css +12 -12
  53. package/neutral/kbd.css +1 -1
  54. package/neutral/link.css +3 -3
  55. package/neutral/list.css +2 -2
  56. package/neutral/local-tokens.css +29 -0
  57. package/neutral/mobile-type.css +42 -0
  58. package/neutral/more-menu.css +9 -9
  59. package/neutral/overlay.css +1 -1
  60. package/neutral/popover.css +2 -2
  61. package/neutral/progress-bar.css +6 -6
  62. package/neutral/{skeleton.css → section.css} +1 -1
  63. package/neutral/segmented-control.css +35 -12
  64. package/neutral/slider.css +3 -3
  65. package/neutral/spinner.css +4 -4
  66. package/neutral/status-dot.css +4 -4
  67. package/neutral/stepper.css +16 -0
  68. package/neutral/switch.css +3 -3
  69. package/neutral/text.css +7 -17
  70. package/neutral/toast.css +1 -1
  71. package/neutral/toggle-button.css +1 -1
  72. package/neutral/tooltip.css +3 -3
  73. package/neutral.css +5 -1
  74. package/package.json +2 -1
  75. package/stone/banner.css +29 -0
  76. package/stone/base.css +16 -89
  77. package/stone/button.css +5 -6
  78. package/stone/card.css +1 -0
  79. package/stone/code.css +5 -4
  80. package/stone/input.css +7 -6
  81. package/stone/mobile-type.css +55 -0
  82. package/stone/progress-bar.css +6 -4
  83. package/stone/section.css +7 -0
  84. package/stone/switch.css +1 -1
  85. package/stone.css +3 -0
  86. package/y2k/badge.css +5 -0
  87. package/y2k/banner.css +29 -0
  88. package/y2k/base.css +6 -79
  89. package/y2k/button.css +15 -6
  90. package/y2k/card.css +1 -0
  91. package/y2k/code.css +5 -4
  92. package/y2k/section.css +7 -0
  93. package/y2k/top-nav.css +22 -0
  94. package/y2k.css +3 -0
@@ -3,11 +3,11 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-checkbox-background: light-dark(#fff, #262626);
7
- --astryx-checkbox-border: light-dark(#d4d4d4, #525252);
8
- --astryx-checkbox-accent: light-dark(#262626, #ebebeb);
9
- --astryx-checkbox-on-accent: light-dark(#fff, #171717);
10
- --astryx-checkbox-focus: light-dark(#262626, #ebebeb);
6
+ --astryx-checkbox-background: var(--astryx-color-background-surface);
7
+ --astryx-checkbox-border: var(--astryx-color-border-emphasized);
8
+ --astryx-checkbox-accent: var(--astryx-color-accent);
9
+ --astryx-checkbox-on-accent: var(--astryx-color-on-accent);
10
+ --astryx-checkbox-focus: var(--astryx-color-accent);
11
11
  --astryx-checkbox-disabled-background: light-dark(#f5f5f5, #171717);
12
12
  }
13
13
  }
package/neutral/code.css CHANGED
@@ -3,22 +3,20 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-text-code-size: 0.875rem;
7
- --astryx-text-code-leading: 1.4286;
6
+ --astryx-code-background: var(--astryx-color-background-muted);
7
+ --astryx-code-primary-foreground: var(--astryx-color-text-primary);
8
+ --astryx-code-secondary-foreground: var(--astryx-color-text-secondary);
8
9
 
9
- --astryx-code-background: light-dark(#f5f5f5, #262626);
10
- --astryx-code-primary-foreground: light-dark(#171717, #fafafa);
11
- --astryx-code-secondary-foreground: light-dark(#525252, #a3a3a3);
12
-
13
- /* CodeBlock card: white surface and a hairline border, matching the
14
- original block. Inline code keeps the muted chip above. */
10
+ /* CodeBlock card: the syntax theme's own background stops plus a hairline
11
+ border. Inline code keeps the muted chip above. */
15
12
  --astryx-code-block-background: light-dark(#ffffff, #111111);
16
- --astryx-code-block-border: light-dark(#00000014, #ffffff1a);
17
- --astryx-code-block-focus: light-dark(#262626, #ebebeb);
13
+ --astryx-code-block-border: var(--astryx-color-border);
14
+ --astryx-code-block-focus: var(--astryx-color-accent);
18
15
  --astryx-code-block-highlight-background: light-dark(#0074e233, #6d9cfe33);
19
16
 
20
- /* Syntax colors from the original CodeBlock theme: keyword and type share
21
- the same purple, strings stay green. */
17
+ /* Syntax palette `astryx-neutral`: keyword and type share the same purple,
18
+ strings stay green. Punctuation, comment and operator sit on the neutral
19
+ mid stop so they clear AA on the code background. */
22
20
  --astryx-code-syntax-keyword: light-dark(#6b187c, #efa8ff);
23
21
  --astryx-code-syntax-string: light-dark(#0b5615, #a4d6a3);
24
22
  --astryx-code-syntax-comment: light-dark(#6a6a6a, #9e9e9e);
@@ -3,9 +3,9 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-collapsible-trigger-foreground: light-dark(#171717, #fafafa);
7
- --astryx-collapsible-content-foreground: light-dark(#171717, #fafafa);
8
- --astryx-collapsible-pressed-overlay: light-dark(#0000001a, #ffffff1a);
9
- --astryx-collapsible-focus: light-dark(#262626, #ebebeb);
6
+ --astryx-collapsible-trigger-foreground: var(--astryx-color-text-primary);
7
+ --astryx-collapsible-content-foreground: var(--astryx-color-text-primary);
8
+ --astryx-collapsible-pressed-overlay: var(--astryx-color-overlay-pressed);
9
+ --astryx-collapsible-focus: var(--astryx-color-accent);
10
10
  }
11
11
  }
@@ -3,17 +3,17 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-context-menu-background: light-dark(#ffffff, #1b1b1b);
7
- --astryx-context-menu-foreground: light-dark(#171717, #fafafa);
6
+ --astryx-context-menu-background: var(--astryx-color-background-popover);
7
+ --astryx-context-menu-foreground: var(--astryx-color-text-primary);
8
8
  --astryx-context-menu-shadow:
9
9
  0 2px 4px light-dark(oklch(0 0 0 / 5%), oklch(0 0 0 / 25%)),
10
10
  0 4px 8px light-dark(oklch(0 0 0 / 10%), oklch(0 0 0 / 40%)),
11
11
  inset 0 0 0 1px light-dark(transparent, oklch(1 0 0 / 8%));
12
- --astryx-context-menu-item-foreground: light-dark(#171717, #fafafa);
13
- --astryx-context-menu-item-focus-background: light-dark(#0536590c, #ffffff0c);
14
- --astryx-context-menu-item-pressed-background: light-dark(#05365919, #ffffff19);
15
- --astryx-context-menu-item-description-foreground: light-dark(#525252, #a3a3a3);
16
- --astryx-context-menu-item-error-foreground: light-dark(#89001a, #ffc6c1);
17
- --astryx-context-menu-section-foreground: light-dark(#525252, #a3a3a3);
12
+ --astryx-context-menu-item-foreground: var(--astryx-color-text-primary);
13
+ --astryx-context-menu-item-focus-background: var(--astryx-color-overlay-hover);
14
+ --astryx-context-menu-item-pressed-background: var(--astryx-color-overlay-pressed);
15
+ --astryx-context-menu-item-description-foreground: var(--astryx-color-text-secondary);
16
+ --astryx-context-menu-item-error-foreground: var(--astryx-color-text-red);
17
+ --astryx-context-menu-section-foreground: var(--astryx-color-text-secondary);
18
18
  }
19
19
  }
@@ -3,9 +3,9 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-dialog-background: light-dark(#ffffff, #262626);
7
- --astryx-dialog-foreground: light-dark(#171717, #fafafa);
8
- --astryx-dialog-overlay: light-dark(#00000080, #000000cc);
6
+ --astryx-dialog-background: var(--astryx-color-background-surface);
7
+ --astryx-dialog-foreground: var(--astryx-color-text-primary);
8
+ --astryx-dialog-overlay: var(--astryx-color-overlay);
9
9
  --astryx-dialog-shadow:
10
10
  0 4px 6px light-dark(oklch(0 0 0 / 10%), oklch(0 0 0 / 50%)),
11
11
  0 12px 24px light-dark(oklch(0 0 0 / 15%), oklch(0 0 0 / 70%)),
@@ -3,8 +3,8 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-divider-color-subtle: light-dark(#00000014, #ffffff1a);
7
- --astryx-divider-color-strong: light-dark(#d4d4d4, #525252);
8
- --astryx-divider-label-color: light-dark(#525252, #a3a3a3);
6
+ --astryx-divider-color-subtle: var(--astryx-color-border);
7
+ --astryx-divider-color-strong: var(--astryx-color-border-emphasized);
8
+ --astryx-divider-label-color: var(--astryx-color-text-secondary);
9
9
  }
10
10
  }
@@ -3,8 +3,8 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-dropdown-menu-background: light-dark(#ffffff, #1b1b1b);
7
- --astryx-dropdown-menu-foreground: light-dark(#171717, #fafafa);
6
+ --astryx-dropdown-menu-background: var(--astryx-color-background-popover);
7
+ --astryx-dropdown-menu-foreground: var(--astryx-color-text-primary);
8
8
  --astryx-dropdown-menu-shadow:
9
9
  0 2px 4px light-dark(oklch(0 0 0 / 5%), oklch(0 0 0 / 25%)),
10
10
  0 4px 8px light-dark(oklch(0 0 0 / 10%), oklch(0 0 0 / 40%)),
@@ -12,7 +12,7 @@
12
12
  --astryx-dropdown-menu-hover-background: var(--astryx-color-overlay-hover);
13
13
  --astryx-dropdown-menu-pressed-background: var(--astryx-color-overlay-pressed);
14
14
  --astryx-dropdown-menu-trigger-open-overlay: var(--astryx-color-overlay-pressed);
15
- --astryx-dropdown-menu-destructive-foreground: light-dark(#a50c25, #ffc6c1);
16
- --astryx-dropdown-menu-section-heading-foreground: light-dark(#525252, #a3a3a3);
15
+ --astryx-dropdown-menu-destructive-foreground: var(--astryx-color-error);
16
+ --astryx-dropdown-menu-section-heading-foreground: var(--astryx-color-text-secondary);
17
17
  }
18
18
  }
@@ -3,8 +3,8 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-empty-state-title-foreground: light-dark(#171717, #fafafa);
7
- --astryx-empty-state-description-foreground: light-dark(#525252, #a3a3a3);
6
+ --astryx-empty-state-title-foreground: var(--astryx-color-text-primary);
7
+ --astryx-empty-state-description-foreground: var(--astryx-color-text-secondary);
8
8
  --astryx-empty-state-text-width: 360px;
9
9
  }
10
10
  }
@@ -4,21 +4,19 @@
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
6
  --astryx-heading-foreground: var(--astryx-color-text-primary);
7
- --astryx-heading-level-1-size: 2rem;
8
- --astryx-heading-level-2-size: 1.75rem;
9
- --astryx-heading-level-3-size: 1.5rem;
10
- --astryx-heading-level-4-size: var(--astryx-font-size-base, 0.875rem);
11
- --astryx-heading-level-5-size: 1.125rem;
12
- --astryx-heading-level-6-size: 1rem;
13
- --astryx-heading-display-1-size: 3rem;
14
- --astryx-heading-display-2-size: 2.25rem;
15
- --astryx-heading-display-3-size: 1.75rem;
16
- --astryx-heading-display-weight: 300;
17
7
  --astryx-heading-leading: 1.25;
18
- --astryx-text-large-size: 1rem;
19
- --astryx-text-large-leading: 1.5;
20
- --astryx-text-label-size: 0.875rem;
21
- --astryx-text-label-leading: 1.25;
22
- --astryx-text-supporting-foreground: var(--astryx-color-text-secondary);
8
+
9
+ /* The theme's type scale drives every heading size. */
10
+ --astryx-heading-level-1-size: var(--astryx-text-heading-1-size);
11
+ --astryx-heading-level-2-size: var(--astryx-text-heading-2-size);
12
+ --astryx-heading-level-3-size: var(--astryx-text-heading-3-size);
13
+ --astryx-heading-level-4-size: var(--astryx-text-heading-4-size);
14
+ --astryx-heading-level-5-size: var(--astryx-text-heading-5-size);
15
+ --astryx-heading-level-6-size: var(--astryx-text-heading-6-size);
16
+
17
+ --astryx-heading-display-1-size: var(--astryx-text-display-1-size);
18
+ --astryx-heading-display-2-size: var(--astryx-text-display-2-size);
19
+ --astryx-heading-display-3-size: var(--astryx-text-display-3-size);
20
+ --astryx-heading-display-weight: var(--astryx-text-display-1-weight);
23
21
  }
24
22
  }
@@ -3,12 +3,12 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-hover-card-background: light-dark(#ffffff, #1b1b1b);
7
- --astryx-hover-card-foreground: light-dark(#171717, #fafafa);
6
+ --astryx-hover-card-background: var(--astryx-color-background-popover);
7
+ --astryx-hover-card-foreground: var(--astryx-color-text-primary);
8
8
  --astryx-hover-card-shadow:
9
9
  0 2px 4px light-dark(oklch(0 0 0 / 5%), oklch(0 0 0 / 25%)),
10
10
  0 4px 8px light-dark(oklch(0 0 0 / 10%), oklch(0 0 0 / 40%)),
11
11
  inset 0 0 0 1px light-dark(transparent, oklch(1 0 0 / 8%));
12
- --astryx-hover-card-indication-color: light-dark(#d4d4d4, #525252);
12
+ --astryx-hover-card-indication-color: var(--astryx-color-border-emphasized);
13
13
  }
14
14
  }
package/neutral/icon.css CHANGED
@@ -5,8 +5,8 @@
5
5
  [data-astryx-theme='neutral'] {
6
6
  --astryx-icon-primary-foreground: var(--astryx-color-icon-primary);
7
7
  --astryx-icon-secondary-foreground: light-dark(#6a6a6a, #9e9e9e);
8
- --astryx-icon-disabled-foreground: light-dark(#919191, #525252);
9
- --astryx-icon-accent-foreground: light-dark(#0074e2, #6d9cfe);
8
+ --astryx-icon-disabled-foreground: var(--astryx-color-text-disabled);
9
+ --astryx-icon-accent-foreground: var(--astryx-color-icon-accent);
10
10
  --astryx-icon-success-foreground: light-dark(#00490b, #a4d6a3);
11
11
  --astryx-icon-error-foreground: light-dark(#76000c, #ffc4be);
12
12
  --astryx-icon-warning-foreground: light-dark(#4b3900, #f8d36a);
package/neutral/input.css CHANGED
@@ -3,20 +3,20 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-input-background: light-dark(#fff, #262626);
7
- --astryx-input-border: light-dark(#d4d4d4, #525252);
8
- --astryx-input-focus: light-dark(#262626, #ebebeb);
6
+ --astryx-input-background: var(--astryx-color-background-surface);
7
+ --astryx-input-border: var(--astryx-color-border-emphasized);
8
+ --astryx-input-focus: var(--astryx-color-accent);
9
9
  --astryx-input-height-sm: 28px;
10
10
  --astryx-input-height-md: 32px;
11
11
  --astryx-input-height-lg: 36px;
12
- --astryx-input-error: light-dark(#e33f4a, #ff705d);
13
- --astryx-input-error-foreground: light-dark(#89001a, #ffc6c1);
14
- --astryx-input-error-background: light-dark(#facecb, #ff9e973d);
15
- --astryx-input-warning: light-dark(#a67a00, #fdcf4f);
16
- --astryx-input-warning-foreground: light-dark(#584400, #fdcf4f);
17
- --astryx-input-warning-background: light-dark(#f8da9d, #deb4333d);
18
- --astryx-input-success: light-dark(#198100, #64af4c);
19
- --astryx-input-success-foreground: light-dark(#0c5700, #9fe59b);
20
- --astryx-input-success-background: light-dark(#c5e5c0, #84c9803d);
12
+ --astryx-input-error: var(--astryx-color-error);
13
+ --astryx-input-error-foreground: var(--astryx-color-text-red);
14
+ --astryx-input-error-background: var(--astryx-color-error-muted);
15
+ --astryx-input-warning: var(--astryx-color-warning);
16
+ --astryx-input-warning-foreground: var(--astryx-color-text-yellow);
17
+ --astryx-input-warning-background: var(--astryx-color-warning-muted);
18
+ --astryx-input-success: var(--astryx-color-success);
19
+ --astryx-input-success-foreground: var(--astryx-color-text-green);
20
+ --astryx-input-success-background: var(--astryx-color-success-muted);
21
21
  }
22
22
  }
package/neutral/kbd.css CHANGED
@@ -3,7 +3,7 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-kbd-background: light-dark(#e5e5e5, #ffffff1a);
6
+ --astryx-kbd-background: var(--astryx-color-neutral);
7
7
  --astryx-kbd-foreground: var(--astryx-color-text-secondary);
8
8
  --astryx-kbd-border-color: var(--astryx-color-border-emphasized);
9
9
  }
package/neutral/link.css CHANGED
@@ -3,8 +3,8 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-link-primary-foreground: light-dark(#171717, #fafafa);
7
- --astryx-link-secondary-foreground: light-dark(#525252, #a3a3a3);
8
- --astryx-link-accent-foreground: light-dark(#0074e2, #6d9cfe);
6
+ --astryx-link-primary-foreground: var(--astryx-color-text-primary);
7
+ --astryx-link-secondary-foreground: var(--astryx-color-text-secondary);
8
+ --astryx-link-accent-foreground: var(--astryx-color-text-accent);
9
9
  }
10
10
  }
package/neutral/list.css CHANGED
@@ -7,7 +7,7 @@
7
7
  --astryx-list-item-pressed-background: var(--astryx-color-overlay-pressed);
8
8
  --astryx-list-item-selected-background: light-dark(#0082fb33, #0082fb3f);
9
9
  --astryx-list-item-focus: light-dark(#0064e0, #2694fe);
10
- --astryx-list-divider-color: light-dark(#05365919, #f2f4f619);
11
- --astryx-list-marker-foreground: light-dark(#171717, #fafafa);
10
+ --astryx-list-divider-color: var(--astryx-color-border);
11
+ --astryx-list-marker-foreground: var(--astryx-color-text-primary);
12
12
  }
13
13
  }
@@ -0,0 +1,29 @@
1
+ /**
2
+ * Neutral theme-local tokens.
3
+ *
4
+ * These names are private to the Neutral theme (not portable semantic tokens),
5
+ * and components reference them instead of hard-coding the same status color
6
+ * in several places. Values come from the reviewed palette.
7
+ */
8
+ @layer astryx.reset, astryx.tokens, astryx.base, astryx.components, astryx.overrides;
9
+
10
+ @layer astryx.tokens {
11
+ :root,
12
+ [data-astryx-theme='neutral'] {
13
+ --astryx-theme-neutral-color-status-fill-accent: light-dark(#0074e2, #6d9cfe);
14
+ --astryx-theme-neutral-color-status-fill-success: light-dark(#198100, #64af4c);
15
+ --astryx-theme-neutral-color-status-fill-warning: #ffce2f;
16
+ --astryx-theme-neutral-color-status-fill-error: light-dark(#c9303a, #ff705d);
17
+
18
+ --astryx-theme-neutral-color-status-muted-accent: light-dark(#b9d7ff, #88bcff3d);
19
+
20
+ /* Tints used on top of an already-tinted surface (Banner). */
21
+ --astryx-theme-neutral-color-on-tint-neutral: light-dark(#fafafa4d, #0a0a0a4d);
22
+ --astryx-theme-neutral-color-on-tint-overlay-hover: light-dark(#fafafa1a, #0a0a0a1a);
23
+ --astryx-theme-neutral-color-on-tint-overlay-pressed: light-dark(#fafafa33, #0a0a0a33);
24
+
25
+ /* Red overlay used by the destructive Button instead of the neutral one. */
26
+ --astryx-theme-neutral-color-destructive-overlay-hover: light-dark(#ff7f770d, #ee736c0d);
27
+ --astryx-theme-neutral-color-destructive-overlay-pressed: light-dark(#ff7f771a, #ee736c1a);
28
+ }
29
+ }
@@ -0,0 +1,42 @@
1
+ /**
2
+ * Neutral type scale on touch devices.
3
+ *
4
+ * On a coarse pointer below the lg breakpoint the whole ladder is re-derived
5
+ * from a 16px base with a smaller ratio, so body text reaches 16px while
6
+ * display-1 keeps its desktop size (42px). Sizes are re-derived here instead of
7
+ * swapping the base size, because every size token is an absolute rem value.
8
+ */
9
+ @layer astryx.reset, astryx.tokens, astryx.base, astryx.components, astryx.overrides;
10
+
11
+ @layer astryx.tokens {
12
+ @media (width < 1024px) and (pointer: coarse) {
13
+ :root,
14
+ [data-astryx-theme='neutral'] {
15
+ --astryx-font-size-4xs: 0.4375rem;
16
+ --astryx-font-size-3xs: 0.5rem;
17
+ --astryx-font-size-2xs: 0.625rem;
18
+ --astryx-font-size-xs: 0.75rem;
19
+ --astryx-font-size-sm: 0.875rem;
20
+ --astryx-font-size-base: 1rem;
21
+ --astryx-font-size-lg: 1.1875rem;
22
+ --astryx-font-size-xl: 1.375rem;
23
+ --astryx-font-size-2xl: 1.625rem;
24
+ --astryx-font-size-3xl: 1.875rem;
25
+ --astryx-font-size-4xl: 2.25rem;
26
+
27
+ --astryx-text-heading-1-leading: 1.3846;
28
+ --astryx-text-heading-2-leading: 1.4545;
29
+ --astryx-text-heading-3-leading: 1.4737;
30
+ --astryx-text-heading-4-leading: 1.5;
31
+ --astryx-text-heading-5-leading: 1.4286;
32
+ --astryx-text-heading-6-leading: 1.6667;
33
+ --astryx-text-body-leading: 1.5;
34
+ --astryx-text-large-leading: 1.4737;
35
+ --astryx-text-label-leading: 1.5;
36
+ --astryx-text-code-leading: 1.5;
37
+ --astryx-text-supporting-leading: 1.4286;
38
+ --astryx-text-display-2-leading: 1.2222;
39
+ --astryx-text-display-3-leading: 1.4667;
40
+ }
41
+ }
42
+ }
@@ -3,15 +3,15 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-more-menu-background: light-dark(#ffffff, #1b1b1b);
7
- --astryx-more-menu-foreground: light-dark(#171717, #fafafa);
8
- --astryx-more-menu-description-foreground: light-dark(#525252, #a3a3a3);
9
- --astryx-more-menu-heading-foreground: light-dark(#525252, #a3a3a3);
10
- --astryx-more-menu-destructive-foreground: light-dark(#a50c25, #ffc6c1);
11
- --astryx-more-menu-item-hover-background: light-dark(#0536590c, #ffffff0c);
12
- --astryx-more-menu-item-pressed-background: light-dark(#05365919, #ffffff19);
13
- --astryx-more-menu-scrim: light-dark(#00000080, #000000cc);
14
- --astryx-more-menu-trigger-open-overlay: light-dark(#0000001a, #ffffff1a);
6
+ --astryx-more-menu-background: var(--astryx-color-background-popover);
7
+ --astryx-more-menu-foreground: var(--astryx-color-text-primary);
8
+ --astryx-more-menu-description-foreground: var(--astryx-color-text-secondary);
9
+ --astryx-more-menu-heading-foreground: var(--astryx-color-text-secondary);
10
+ --astryx-more-menu-destructive-foreground: var(--astryx-color-error);
11
+ --astryx-more-menu-item-hover-background: var(--astryx-color-overlay-hover);
12
+ --astryx-more-menu-item-pressed-background: var(--astryx-color-overlay-pressed);
13
+ --astryx-more-menu-scrim: var(--astryx-color-overlay);
14
+ --astryx-more-menu-trigger-open-overlay: var(--astryx-color-overlay-pressed);
15
15
  --astryx-more-menu-shadow:
16
16
  0 2px 4px light-dark(oklch(0 0 0 / 5%), oklch(0 0 0 / 25%)),
17
17
  0 4px 8px light-dark(oklch(0 0 0 / 10%), oklch(0 0 0 / 40%)),
@@ -3,7 +3,7 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-overlay-scrim-background: light-dark(#00000080, #000000cc);
6
+ --astryx-overlay-scrim-background: var(--astryx-color-overlay);
7
7
  --astryx-overlay-scrim-light-background: color-mix(in srgb, #fff 60%, transparent);
8
8
  }
9
9
  }
@@ -3,8 +3,8 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-popover-background: light-dark(#ffffff, #1b1b1b);
7
- --astryx-popover-foreground: light-dark(#171717, #fafafa);
6
+ --astryx-popover-background: var(--astryx-color-background-popover);
7
+ --astryx-popover-foreground: var(--astryx-color-text-primary);
8
8
  --astryx-popover-shadow:
9
9
  0 2px 4px light-dark(oklch(0 0 0 / 5%), oklch(0 0 0 / 25%)),
10
10
  0 4px 8px light-dark(oklch(0 0 0 / 10%), oklch(0 0 0 / 40%)),
@@ -6,11 +6,11 @@
6
6
  --astryx-progress-bar-track-height: 8px;
7
7
  --astryx-progress-bar-track-height-sm: 4px;
8
8
  --astryx-progress-bar-track-height-lg: 12px;
9
- --astryx-progress-bar-track-background: light-dark(#e5e5e5, rgb(255 255 255 / 10%));
10
- --astryx-progress-bar-fill-background: light-dark(#171717, #fff);
11
- --astryx-progress-bar-success-fill: light-dark(#198100, #64af4c);
12
- --astryx-progress-bar-warning-fill: light-dark(#ffce2f, #ffce2f);
13
- --astryx-progress-bar-error-fill: light-dark(#e33f4a, #ff705d);
14
- --astryx-progress-bar-info-fill: light-dark(#0074e2, #6d9cfe);
9
+ --astryx-progress-bar-track-background: var(--astryx-color-border-emphasized);
10
+ --astryx-progress-bar-fill-background: var(--astryx-color-accent);
11
+ --astryx-progress-bar-success-fill: var(--astryx-theme-neutral-color-status-fill-success);
12
+ --astryx-progress-bar-warning-fill: var(--astryx-theme-neutral-color-status-fill-warning);
13
+ --astryx-progress-bar-error-fill: var(--astryx-theme-neutral-color-status-fill-error);
14
+ --astryx-progress-bar-info-fill: var(--astryx-theme-neutral-color-status-fill-accent);
15
15
  }
16
16
  }
@@ -3,6 +3,6 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-color-skeleton: light-dark(#ebebeb, #525252);
6
+ --astryx-section-padding: var(--astryx-spacing-3);
7
7
  }
8
8
  }
@@ -3,17 +3,40 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-segmented-control-background: light-dark(#f5f5f5, #171717);
7
- --astryx-segmented-control-focus: light-dark(#262626, #ebebeb);
8
- --astryx-segmented-control-item-foreground: light-dark(#525252, #a3a3a3);
9
- --astryx-segmented-control-item-hover-background: light-dark(#0000000d, #ffffff0d);
10
- --astryx-segmented-control-item-pressed-background: light-dark(#0000001a, #ffffff1a);
11
- --astryx-segmented-control-item-selected-foreground: light-dark(#171717, #fafafa);
12
- --astryx-segmented-control-item-selected-background: light-dark(#ffffff, #262626);
13
- --astryx-segmented-control-item-selected-shadow:
14
- 0 2px 4px light-dark(oklch(0 0 0 / 5%), oklch(0 0 0 / 25%)),
15
- 0 4px 8px light-dark(oklch(0 0 0 / 10%), oklch(0 0 0 / 40%)),
16
- inset 0 0 0 1px light-dark(transparent, oklch(1 0 0 / 8%));
17
- --astryx-segmented-control-item-disabled-foreground: light-dark(#919191, #525252);
6
+ --astryx-segmented-control-background: var(--astryx-color-neutral);
7
+ --astryx-segmented-control-focus: var(--astryx-color-accent);
8
+
9
+ /* A roomier inset around the track. The selected item stays flat against
10
+ the tinted track. */
11
+ --astryx-segmented-control-padding: var(--astryx-spacing-1);
12
+
13
+ --astryx-segmented-control-item-foreground: var(--astryx-color-text-secondary);
14
+ --astryx-segmented-control-item-hover-background: var(--astryx-color-overlay-hover);
15
+ --astryx-segmented-control-item-pressed-background: var(--astryx-color-overlay-pressed);
16
+ --astryx-segmented-control-item-selected-foreground: var(--astryx-color-text-primary);
17
+ --astryx-segmented-control-item-selected-background: var(--astryx-color-background-surface);
18
+ --astryx-segmented-control-item-selected-shadow: none;
19
+ --astryx-segmented-control-item-disabled-foreground: var(--astryx-color-text-disabled);
20
+ }
21
+ }
22
+
23
+ /*
24
+ * Keeping the outside height means the items lose the extra inset from both
25
+ * sides, so the padding change above does not make the control taller.
26
+ */
27
+ @layer astryx.overrides {
28
+ :root .astryx-segmented-control-item[data-size='sm'],
29
+ [data-astryx-theme='neutral'] .astryx-segmented-control-item[data-size='sm'] {
30
+ height: calc(var(--astryx-size-element-sm) - 8px);
31
+ }
32
+
33
+ :root .astryx-segmented-control-item[data-size='md'],
34
+ [data-astryx-theme='neutral'] .astryx-segmented-control-item[data-size='md'] {
35
+ height: calc(var(--astryx-size-element-md) - 8px);
36
+ }
37
+
38
+ :root .astryx-segmented-control-item[data-size='lg'],
39
+ [data-astryx-theme='neutral'] .astryx-segmented-control-item[data-size='lg'] {
40
+ height: calc(var(--astryx-size-element-lg) - 8px);
18
41
  }
19
42
  }
@@ -2,9 +2,9 @@
2
2
  @layer astryx.tokens {
3
3
  :root,
4
4
  [data-astryx-theme='neutral'] {
5
- --astryx-slider-track: light-dark(#e5e5e5, #404040);
6
- --astryx-slider-accent: light-dark(#262626, #ebebeb);
7
- --astryx-slider-focus: light-dark(#262626, #ebebeb);
5
+ --astryx-slider-track: var(--astryx-color-background-muted);
6
+ --astryx-slider-accent: var(--astryx-color-accent);
7
+ --astryx-slider-focus: var(--astryx-color-accent);
8
8
  --astryx-slider-height: 160px;
9
9
  }
10
10
  }
@@ -13,10 +13,10 @@
13
13
  --astryx-spinner-stroke-width-xl: 4px;
14
14
  --astryx-spinner-arc-fraction: 0.375;
15
15
  --astryx-spinner-group-gap: 8px;
16
- --astryx-spinner-label-color: light-dark(#171717, #fafafa);
17
- --astryx-spinner-color-accent: light-dark(#262626, #ebebeb);
18
- --astryx-spinner-color-subtle: light-dark(#525252, #a3a3a3);
19
- --astryx-spinner-color-track: light-dark(#ccd3db, #5a5e66);
16
+ --astryx-spinner-label-color: var(--astryx-color-text-primary);
17
+ --astryx-spinner-color-accent: var(--astryx-color-accent);
18
+ --astryx-spinner-color-subtle: var(--astryx-color-text-secondary);
19
+ --astryx-spinner-color-track: var(--astryx-color-track);
20
20
  --astryx-spinner-color-on-dark: #fff;
21
21
  }
22
22
  }
@@ -3,10 +3,10 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-status-dot-neutral-background: light-dark(#a3a3a3, #737373);
7
- --astryx-status-dot-info-background: light-dark(#0074e2, #6d9cfe);
8
- --astryx-status-dot-success-background: light-dark(#198100, #64af4c);
6
+ --astryx-status-dot-neutral-background: var(--astryx-color-icon-secondary);
7
+ --astryx-status-dot-info-background: var(--astryx-theme-neutral-color-status-fill-accent);
8
+ --astryx-status-dot-success-background: var(--astryx-theme-neutral-color-status-fill-success);
9
9
  --astryx-status-dot-warning-background: #ffce2f;
10
- --astryx-status-dot-error-background: light-dark(#e33f4a, #ff705d);
10
+ --astryx-status-dot-error-background: var(--astryx-theme-neutral-color-status-fill-error);
11
11
  }
12
12
  }
@@ -0,0 +1,16 @@
1
+ @layer astryx.reset, astryx.tokens, astryx.base, astryx.components, astryx.overrides;
2
+
3
+ /*
4
+ * Step indicators paint from the shared status colors. A step's status picks
5
+ * which one it reads, so re-pointing all four on the indicator itself gives
6
+ * each status the approved status fill.
7
+ */
8
+ @layer astryx.overrides {
9
+ :root .astryx-step-indicator,
10
+ [data-astryx-theme='neutral'] .astryx-step-indicator {
11
+ --astryx-color-accent: var(--astryx-theme-neutral-color-status-fill-accent);
12
+ --astryx-color-success: var(--astryx-theme-neutral-color-status-fill-success);
13
+ --astryx-color-warning: var(--astryx-theme-neutral-color-status-fill-warning);
14
+ --astryx-color-error: var(--astryx-theme-neutral-color-status-fill-error);
15
+ }
16
+ }
@@ -23,8 +23,8 @@
23
23
  --astryx-switch-thumb-travel-lg: 22px;
24
24
  --astryx-switch-track-radius: 999px;
25
25
  --astryx-switch-thumb-radius: 999px;
26
- --astryx-switch-track-off: light-dark(#e2e2e2, #303030);
27
- --astryx-switch-track-on: light-dark(#1b1b1b, #f1f1f1);
28
- --astryx-switch-thumb: light-dark(#ffffff, #262626);
26
+ --astryx-switch-track-off: var(--astryx-color-border-emphasized);
27
+ --astryx-switch-track-on: var(--astryx-color-accent);
28
+ --astryx-switch-thumb: var(--astryx-color-background-surface);
29
29
  }
30
30
  }
package/neutral/text.css CHANGED
@@ -4,23 +4,13 @@
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
6
  --astryx-text-foreground: var(--astryx-color-text-primary);
7
- --astryx-text-body-size: 0.875rem;
8
- --astryx-text-body-leading: 1.4286;
9
- --astryx-text-large-size: 1rem;
10
- --astryx-text-large-leading: 1.5;
11
- --astryx-text-label-size: 0.875rem;
12
- --astryx-text-label-leading: 1.25;
13
7
  --astryx-text-supporting-foreground: var(--astryx-color-text-secondary);
14
- --astryx-text-supporting-size: 0.75rem;
15
- --astryx-text-supporting-leading: 1.6667;
16
- --astryx-text-display-1-size: 3rem;
17
- --astryx-text-display-2-size: 2.25rem;
18
- --astryx-text-display-3-size: 1.75rem;
19
- --astryx-text-display-weight: 300;
20
- --astryx-text-sm-size: 0.75rem;
21
- --astryx-text-md-size: 0.875rem;
22
- --astryx-text-lg-size: 1rem;
23
- --astryx-text-xl-size: 1.25rem;
24
- --astryx-color-text-accent: light-dark(#0074e2, #6d9cfe);
8
+ --astryx-text-display-weight: var(--astryx-font-weight-normal);
9
+
10
+ /* Sizes offered by the `size` prop on Text and Link. */
11
+ --astryx-text-sm-size: var(--astryx-font-size-sm);
12
+ --astryx-text-md-size: var(--astryx-font-size-base);
13
+ --astryx-text-lg-size: var(--astryx-font-size-lg);
14
+ --astryx-text-xl-size: var(--astryx-font-size-xl);
25
15
  }
26
16
  }
package/neutral/toast.css CHANGED
@@ -3,7 +3,7 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-toast-info-background: light-dark(#171717, #fafafa);
6
+ --astryx-toast-info-background: var(--astryx-color-background-inverted);
7
7
  --astryx-toast-info-foreground: light-dark(#fafafa, #171717);
8
8
  --astryx-toast-success-background: #0a7b3e;
9
9
  --astryx-toast-warning-background: #9a6700;
@@ -3,7 +3,7 @@
3
3
  @layer astryx.tokens {
4
4
  :root,
5
5
  [data-astryx-theme='neutral'] {
6
- --astryx-toggle-button-pressed-background: light-dark(#05365919, #ffffff19);
6
+ --astryx-toggle-button-pressed-background: var(--astryx-color-overlay-pressed);
7
7
  --astryx-toggle-button-pressed-font-weight: 600;
8
8
  --astryx-toggle-button-group-gap: 4px;
9
9
  }