@ecopages/radiant-themes 0.2.0 → 0.2.2

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 (42) hide show
  1. package/README.md +37 -17
  2. package/dist/compiled/themes/cloudflare/compact.css +56 -14
  3. package/dist/compiled/themes/cloudflare.css +56 -14
  4. package/dist/compiled/themes/github/compact.css +310 -65
  5. package/dist/compiled/themes/github.css +310 -65
  6. package/dist/compiled/themes/high-contrast/compact.css +108 -11
  7. package/dist/compiled/themes/high-contrast.css +108 -11
  8. package/dist/compiled/themes/macos/compact.css +698 -272
  9. package/dist/compiled/themes/macos-classic/compact.css +455 -16
  10. package/dist/compiled/themes/macos-classic.css +455 -16
  11. package/dist/compiled/themes/macos.css +698 -272
  12. package/dist/compiled/themes/material/compact.css +461 -136
  13. package/dist/compiled/themes/material.css +461 -136
  14. package/dist/compiled/themes/vercel/compact.css +118 -66
  15. package/dist/compiled/themes/vercel.css +118 -66
  16. package/dist/compiled/themes/vscode/compact.css +310 -40
  17. package/dist/compiled/themes/vscode.css +310 -40
  18. package/dist/compiled/themes/windows95/compact.css +408 -22
  19. package/dist/compiled/themes/windows95.css +408 -22
  20. package/dist/foundation.css +13 -0
  21. package/dist/tokens/colors/cloudflare.css +1 -1
  22. package/dist/tokens/colors/github.css +32 -0
  23. package/dist/tokens/colors/macos.css +65 -25
  24. package/dist/tokens/colors/material.css +61 -20
  25. package/dist/tokens/colors/vercel.css +43 -39
  26. package/dist/tokens/colors/vscode.css +48 -4
  27. package/dist/tokens/colors/windows95.css +10 -5
  28. package/dist/tokens/components/cloudflare.css +63 -7
  29. package/dist/tokens/components/github.css +287 -39
  30. package/dist/tokens/components/high-contrast.css +106 -11
  31. package/dist/tokens/components/macos-classic.css +549 -15
  32. package/dist/tokens/components/macos.css +555 -96
  33. package/dist/tokens/components/material.css +360 -29
  34. package/dist/tokens/components/vercel.css +83 -19
  35. package/dist/tokens/components/vscode.css +280 -27
  36. package/dist/tokens/components/windows95.css +470 -18
  37. package/dist/tokens/roles/cloudflare.css +1 -1
  38. package/dist/tokens/roles/github.css +12 -12
  39. package/dist/tokens/roles/macos.css +97 -93
  40. package/dist/tokens/roles/material.css +65 -65
  41. package/dist/tokens/roles/vercel.css +3 -3
  42. package/package.json +3 -3
@@ -1,184 +1,552 @@
1
1
  @reference 'tailwindcss';
2
2
 
3
- :root, :root[data-rui-theme='macos'] {
4
- --font-sans: -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, sans-serif;
5
- --font-heading: -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, sans-serif;
6
- --font-mono: 'SFMono-Regular', Menlo, Monaco, monospace;
7
- --border-radius-xs: 0.375rem;
8
- --border-radius-sm: 0.5rem;
9
- --border-radius-md: 0.5rem;
3
+ /**
4
+ * macOS Sonoma and Sequoia AppKit controls: SF Pro at the 13px system size, 6px push buttons drawn with a hairline
5
+ * shadow instead of a border, accent-filled default buttons, check boxes, and radio buttons, pop-up buttons with an
6
+ * accent arrow well, segmented tab controls, white slider knobs, and translucent menus and popovers.
7
+ *
8
+ * @remarks Control heights map regular, large, and extra large AppKit sizes (22, 28, 36px) to `sm`, `md`, and `lg`.
9
+ * Text fields keep a 3:1 border instead of AppKit's lighter bezel so their boundary stays visible.
10
+ */
11
+ :root,
12
+ :root[data-rui-theme='macos'] {
13
+ --font-sans: system-ui, -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Helvetica Neue', Arial, sans-serif;
14
+ --font-heading: system-ui, -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Helvetica Neue', Arial, sans-serif;
15
+ --font-mono: ui-monospace, 'SF Mono', SFMono-Regular, Menlo, Monaco, monospace;
16
+ --text-control: 0.8125rem;
17
+ --border-radius-xs: 0.25rem;
18
+ --border-radius-sm: 0.3125rem;
19
+ --border-radius-md: 0.375rem;
10
20
  --border-radius-lg: 0.625rem;
11
21
  --border-radius-xl: 0.75rem;
12
22
  --border-radius-2xl: 1rem;
13
23
  --border-radius-3xl: 1.25rem;
14
24
  --radius-control: var(--border-radius-md);
15
25
  --radius-container: var(--border-radius-lg);
26
+ --size-control-sm: 1.375rem;
27
+ --size-control-md: 1.75rem;
28
+ --size-control-lg: 2.25rem;
16
29
  --rui-border-alpha: 100%;
17
30
  --focus-ring-width: 3px;
18
- --focus-ring-offset: 3px;
31
+ --focus-ring-offset: 1px;
32
+ --macos-hover-fill: color-mix(in srgb, var(--macos-text) 7%, transparent);
33
+ --macos-press-fill: color-mix(in srgb, var(--macos-text) 14%, transparent);
34
+ --macos-default-button-sheen: linear-gradient(to bottom, rgb(255 255 255 / 0.14), rgb(255 255 255 / 0));
19
35
  }
20
36
 
21
37
  @layer components {
38
+ :root .rui-button {
39
+ @apply rounded-control border border-transparent font-normal;
40
+ background-image: none;
41
+ box-shadow: none;
42
+ transition-duration: var(--duration-fast);
43
+ }
44
+
22
45
  /**
23
- * @remarks macOS fills dark destructive buttons with a saturated red and white text; `--error` stays the lighter
24
- * red used for error text on dark surfaces.
46
+ * @remarks Secondary push buttons have no border: a hairline shadow outlines the white (light) or grey (dark) face,
47
+ * and they only darken while pressed.
25
48
  */
26
- :root.dark .rui-button--destructive {
27
- background-color: #d93036;
28
- color: #ffffff;
49
+ :root .rui-button--outline,
50
+ :root .rui-button--destructive {
51
+ border-color: transparent;
52
+ background-color: var(--macos-control);
53
+ color: var(--macos-text);
54
+ box-shadow: var(--macos-control-shadow);
29
55
  }
30
56
 
31
- :root.dark .rui-button--destructive:hover:not(:disabled) {
32
- background-color: #c9302c;
57
+ :root .rui-button--outline:hover:not(:disabled),
58
+ :root .rui-button--destructive:hover:not(:disabled) {
59
+ background-color: var(--macos-control);
33
60
  }
34
61
 
35
- :root.dark .rui-button--destructive:active:not(:disabled) {
36
- background-color: #b62324;
62
+ :root .rui-button--outline:active:not(:disabled),
63
+ :root .rui-button--outline[aria-pressed='true'],
64
+ :root .rui-button--destructive:active:not(:disabled) {
65
+ background-color: var(--macos-control-pressed);
66
+ box-shadow: var(--macos-control-shadow);
37
67
  }
38
68
 
39
69
  /**
40
- * @remarks macOS dark push buttons use the accent blue with white text. `#0a6cd6` keeps the system blue's hue at
41
- * 5:1 contrast, and `--primary` stays the lighter accent for primary text.
70
+ * @remarks AppKit marks a destructive alert action with red text on an ordinary push button, not a red fill.
42
71
  */
43
- :root.dark .rui-button--filled {
44
- background-color: #0a6cd6;
45
- color: #ffffff;
72
+ :root .rui-button--destructive {
73
+ color: var(--macos-red);
46
74
  }
47
75
 
48
- :root.dark .rui-button--filled:hover:not(:disabled) {
49
- background-color: #0a64c8;
76
+ :root.dark .rui-button--destructive {
77
+ color: #ffcdc9;
50
78
  }
51
79
 
52
- :root.dark .rui-button--filled:active:not(:disabled),
53
- :root.dark .rui-button--filled[aria-pressed='true'] {
54
- background-color: #0a5bb5;
80
+ /**
81
+ * @remarks The default button fills with `selectedContentBackgroundColor` rather than the brighter accent so its
82
+ * white label keeps 4.5:1.
83
+ */
84
+ :root .rui-button--filled {
85
+ border-color: transparent;
86
+ background-color: var(--macos-selection);
87
+ background-image: var(--macos-default-button-sheen);
88
+ color: var(--macos-selection-text);
89
+ box-shadow:
90
+ 0 0 0 0.5px rgb(0 0 0 / 0.12),
91
+ 0 0.5px 1px rgb(0 0 0 / 0.25);
55
92
  }
56
93
 
57
- :root .rui-button {
58
- @apply rounded-control border border-transparent font-medium shadow-none;
59
- transition-duration: var(--duration-fast);
94
+ :root .rui-button--filled:hover:not(:disabled) {
95
+ background-color: var(--macos-selection);
60
96
  }
61
97
 
62
- :root .rui-button--filled,
63
- :root .rui-button--destructive {
64
- @apply shadow-sm;
98
+ :root .rui-button--filled:active:not(:disabled),
99
+ :root .rui-button--filled[aria-pressed='true'] {
100
+ background-color: color-mix(in srgb, var(--macos-selection), black 18%);
101
+ box-shadow:
102
+ 0 0 0 0.5px rgb(0 0 0 / 0.12),
103
+ 0 0.5px 1px rgb(0 0 0 / 0.25);
65
104
  }
66
105
 
67
- :root .rui-button--outline {
68
- @apply border-border bg-surface text-on-surface;
69
- border-color: var(--rui-control-border-color);
106
+ :root .rui-button--ghost {
107
+ color: var(--macos-text);
70
108
  }
71
109
 
72
- :root .rui-button--outline:hover:not(:disabled),
73
110
  :root .rui-button--ghost:hover:not(:disabled) {
74
- @apply bg-surface-container-low;
111
+ background-color: var(--macos-hover-fill);
112
+ }
113
+
114
+ :root .rui-button--ghost:active:not(:disabled),
115
+ :root .rui-button--ghost[aria-pressed='true'] {
116
+ background-color: var(--macos-press-fill);
117
+ box-shadow: none;
75
118
  }
76
119
 
120
+ :root .rui-button--link {
121
+ color: var(--link);
122
+ }
123
+
124
+ :root .rui-button:focus-visible {
125
+ @apply ring-[3px] ring-focus-ring/60;
126
+ }
127
+
128
+ /**
129
+ * @remarks AppKit text fields are near-square white wells; the accent focus ring hugs the bezel.
130
+ */
77
131
  :root .rui-input,
78
132
  :root .rui-textarea,
79
133
  :root .rui-autocomplete__input,
80
- :root .rui-combobox__input,
81
- :root .rui-date-field__input,
82
- :root .rui-date-input__segment,
83
- :root .rui-number-field__input,
84
- :root .rui-select__control {
85
- @apply rounded-control border-border bg-surface text-on-surface shadow-none;
134
+ :root .rui-combobox__control,
135
+ :root .rui-date-field__group,
136
+ :root .rui-date-range-picker__group,
137
+ :root .rui-input-group,
138
+ :root .rui-number-field__group,
139
+ :root rui-date-input:where(:not([data-date-field-input], [data-range-start], [data-range-end])) {
140
+ @apply rounded-sm bg-surface text-on-surface shadow-none;
86
141
  border-color: var(--rui-control-border-color);
87
142
  }
88
143
 
144
+ :root .rui-input:focus-visible,
145
+ :root .rui-textarea:focus-visible,
146
+ :root .rui-autocomplete__input:focus-visible,
147
+ :root .rui-combobox__control:focus-within,
148
+ :root .rui-date-field__group:focus-within,
149
+ :root .rui-date-range-picker__group:focus-within,
150
+ :root .rui-input-group:focus-within,
151
+ :root .rui-number-field__group:focus-within {
152
+ @apply outline-none ring-[3px] ring-focus-ring/60;
153
+ }
154
+
155
+ /**
156
+ * Pop-up buttons are push buttons whose arrow sits in an accent-filled rounded well.
157
+ */
158
+ :root .rui-select__control {
159
+ @apply rounded-control;
160
+ border-color: transparent;
161
+ background-color: var(--macos-control);
162
+ color: var(--macos-text);
163
+ box-shadow: var(--macos-control-shadow);
164
+ }
165
+
166
+ :root .rui-select__control:focus-within {
167
+ @apply ring-[3px] ring-focus-ring/60;
168
+ }
169
+
170
+ :root .rui-select__trigger {
171
+ color: var(--macos-text);
172
+ }
173
+
174
+ :root .rui-select__control .rui-control-toggle,
175
+ :root .rui-combobox__control .rui-control-toggle {
176
+ width: 1.0625rem;
177
+ height: 1.0625rem;
178
+ margin-inline-end: 0.125rem;
179
+ border-radius: var(--border-radius-xs);
180
+ background-color: var(--macos-accent);
181
+ background-image: var(--macos-default-button-sheen);
182
+ color: #ffffff;
183
+ }
184
+
185
+ :root .rui-select__control .rui-control-toggle:hover:not(:disabled),
186
+ :root .rui-combobox__control .rui-control-toggle:hover:not(:disabled) {
187
+ background-color: var(--macos-accent);
188
+ }
189
+
190
+ :root .rui-select__control .rui-control-toggle > svg,
191
+ :root .rui-combobox__control .rui-control-toggle > svg {
192
+ width: 0.75rem;
193
+ height: 0.75rem;
194
+ stroke-width: 2.5;
195
+ }
196
+
197
+ /**
198
+ * Check boxes and radio buttons fill with the accent and draw a white mark; unchecked ones are white with a hairline.
199
+ */
89
200
  :root .rui-checkbox__control,
90
201
  :root .rui-radio__control {
91
- @apply border-border bg-surface;
202
+ width: 0.875rem;
203
+ height: 0.875rem;
92
204
  border-color: var(--rui-control-border-color);
205
+ background-color: var(--macos-surface);
206
+ box-shadow: 0 0.5px 1px rgb(0 0 0 / 0.12);
207
+ }
208
+
209
+ :root.dark .rui-checkbox__control,
210
+ :root.dark .rui-radio__control {
211
+ background-color: var(--macos-control);
212
+ }
213
+
214
+ :root .rui-checkbox__control {
215
+ @apply rounded-xs;
216
+ }
217
+
218
+ :root .rui-checkbox__input:checked:not(:indeterminate):not([aria-checked='mixed']) + .rui-checkbox__control,
219
+ :root .rui-checkbox__input:indeterminate + .rui-checkbox__control,
220
+ :root .rui-checkbox__input[aria-checked='mixed'] + .rui-checkbox__control,
221
+ :root .rui-radio__input:checked + .rui-radio__control {
222
+ border-color: var(--primary);
223
+ background-color: var(--macos-accent);
224
+ background-image: var(--macos-default-button-sheen);
225
+ }
226
+
227
+ :root .rui-checkbox__input:checked:not(:indeterminate):not([aria-checked='mixed']) + .rui-checkbox__control::after {
228
+ width: 0.5625rem;
229
+ height: 0.5625rem;
230
+ color: #ffffff;
231
+ }
232
+
233
+ :root .rui-checkbox__input:indeterminate + .rui-checkbox__control::after,
234
+ :root .rui-checkbox__input[aria-checked='mixed'] + .rui-checkbox__control::after {
235
+ width: 0.5rem;
236
+ background-color: #ffffff;
237
+ }
238
+
239
+ :root .rui-radio__input:checked + .rui-radio__control::after {
240
+ width: 0.375rem;
241
+ height: 0.375rem;
242
+ background-color: #ffffff;
243
+ }
244
+
245
+ :root .rui-checkbox__input:focus-visible + .rui-checkbox__control,
246
+ :root .rui-radio__input:focus-visible + .rui-radio__control,
247
+ :root .rui-switch__input:focus-visible + .rui-switch__track {
248
+ @apply ring-[3px] ring-focus-ring/60 ring-offset-0;
93
249
  }
94
250
 
95
251
  :root .rui-switch {
96
- --rui-switch-track: color-mix(in oklab, var(--on-background) 14%, transparent);
97
- --rui-switch-track-hover: color-mix(in oklab, var(--on-background) 20%, transparent);
252
+ --rui-switch-width: 2.375rem;
253
+ --rui-switch-height: 1.375rem;
254
+ --rui-switch-thumb-size: 1.25rem;
255
+ --rui-switch-track: color-mix(in srgb, var(--macos-text) 12%, transparent);
256
+ --rui-switch-track-hover: color-mix(in srgb, var(--macos-text) 12%, transparent);
257
+ --rui-switch-track-on: var(--macos-accent);
258
+ --rui-switch-track-on-hover: var(--macos-accent);
98
259
  --rui-switch-thumb: #ffffff;
99
260
  --rui-switch-thumb-on: #ffffff;
100
261
  }
101
262
 
102
263
  :root .rui-switch__track {
103
264
  @apply rounded-pill;
265
+ box-shadow: inset 0 0 0 0.5px rgb(0 0 0 / 0.12);
104
266
  }
105
267
 
106
268
  :root .rui-switch__thumb {
269
+ left: 1px;
107
270
  box-shadow:
108
- 0 0 0 0.5px rgb(0 0 0 / 0.12),
109
- 0 1px 2px rgb(0 0 0 / 0.24);
271
+ 0 0 0 0.5px rgb(0 0 0 / 0.1),
272
+ 0 1px 2px rgb(0 0 0 / 0.25);
110
273
  }
111
274
 
112
- :root .rui-checkbox__control {
113
- @apply rounded-xs;
275
+ :root .rui-switch__input:checked + .rui-switch__track .rui-switch__thumb {
276
+ right: 1px;
114
277
  }
115
278
 
116
- :root .rui-listbox__option[aria-selected='true'],
279
+ /**
280
+ * Selection uses `selectedContentBackgroundColor` with white text: list and menu rows, calendar days, and the
281
+ * source-list sidebar.
282
+ */
283
+ :root .rui-listbox__option[aria-selected='true']:not([aria-disabled='true']),
284
+ :root .rui-listbox__option[aria-selected='true']:focus-visible,
117
285
  :root .rui-menu-button__item[aria-checked='true'],
118
286
  :root .rui-menubar__menu-item[aria-checked='true'],
119
287
  :root .rui-tree__node[aria-selected='true'],
120
- :root .rui-calendar__day[aria-selected='true'],
121
- :root .rui-sidebar__menu-button--active,
288
+ :root .rui-calendar__day[aria-selected='true']:not([data-range-middle='true']),
289
+ :root .rui-calendar__day[aria-selected='true']:not([data-range-middle='true']):hover:not(:disabled),
122
290
  :root .rui-navigation-menu__link-list a[aria-current='page'] {
123
- @apply rounded-control bg-primary-container text-on-primary-container;
291
+ @apply rounded-sm;
292
+ background-color: var(--macos-selection);
293
+ background-image: none;
294
+ color: var(--macos-selection-text);
295
+ }
296
+
297
+ :root .rui-listbox__option[aria-selected='true'] .rui-listbox__option-indicator {
298
+ color: var(--macos-selection-text);
299
+ }
300
+
301
+ :root .rui-listbox__option {
302
+ @apply rounded-sm;
303
+ padding-block: 0.1875rem;
304
+ }
305
+
306
+ :root .rui-calendar__day {
307
+ @apply h-7 rounded-full;
308
+ }
309
+
310
+ :root .rui-calendar__day[aria-selected='true']:not([data-range-middle='true']) {
311
+ @apply rounded-full;
312
+ }
313
+
314
+ :root .rui-calendar__day[aria-current='date']:not([aria-selected='true']) {
315
+ @apply no-underline;
316
+ color: var(--macos-red);
317
+ }
318
+
319
+ /**
320
+ * @remarks Menu rows highlight with the accent and white text while the pointer or keyboard is on them, inset 5px
321
+ * from the menu edge with 4px corners.
322
+ */
323
+ :root .rui-menu-button__menu,
324
+ :root .rui-menubar__menu {
325
+ @apply p-[5px];
326
+ --rui-menu-item-hover: var(--macos-selection);
327
+ }
328
+
329
+ :root .rui-menu-button__item,
330
+ :root .rui-menubar__menu-item {
331
+ @apply rounded-xs;
332
+ padding-block: 0.1875rem;
333
+ padding-inline: 0.625rem;
334
+ font-size: var(--text-control);
335
+ }
336
+
337
+ :root .rui-menu-button__item:focus-visible:not([aria-disabled='true']),
338
+ :root .rui-menu-button__item[aria-expanded='true'],
339
+ :root .rui-menubar__menu-item:focus-visible:not([aria-disabled='true']),
340
+ :root .rui-menubar__menu-item[aria-expanded='true'] {
341
+ color: var(--macos-selection-text);
342
+ --tw-ring-shadow: 0 0 #0000;
343
+ }
344
+
345
+ @media (hover: hover) and (pointer: fine) {
346
+ :root .rui-menu-button__item:hover:not([aria-disabled='true']),
347
+ :root .rui-menubar__menu-item:hover:not([aria-disabled='true']) {
348
+ background-color: var(--macos-selection);
349
+ color: var(--macos-selection-text);
350
+ }
351
+
352
+ :root .rui-menu-button__item:hover:not([aria-disabled='true'])::after,
353
+ :root .rui-menubar__menu-item:hover:not([aria-disabled='true'])::after {
354
+ color: inherit;
355
+ }
356
+ }
357
+
358
+ :root .rui-sidebar__menu-button:hover {
359
+ background-color: var(--macos-hover-fill);
360
+ }
361
+
362
+ /**
363
+ * @remarks Source lists mark the current row with the unemphasized grey selection, as Finder and System Settings do
364
+ * while the sidebar is not the key view.
365
+ */
366
+ :root .rui-sidebar__menu-button[aria-current='page'],
367
+ :root .rui-sidebar__menu-button--active {
368
+ background-color: var(--macos-unemphasized-selection);
369
+ color: var(--macos-text);
124
370
  }
125
371
 
126
- :root .rui-dialog__surface,
127
- :root .rui-popover-host,
128
- :root .rui-hover-card__content,
372
+ /**
373
+ * Menus, pop-up lists, popovers, and hover cards are translucent, blurred materials with a hairline edge.
374
+ */
375
+ :root .rui-popover,
129
376
  :root .rui-menu-button__menu,
130
377
  :root .rui-menubar__menu,
131
378
  :root .rui-select__listbox,
132
379
  :root .rui-combobox__listbox,
133
- :root .rui-calendar,
134
- :root rui-tabs[variant='boxed'] {
135
- @apply rounded-container border border-border bg-surface shadow-lg;
380
+ :root .rui-hover-card__content {
381
+ --rui-popover-surface: var(--macos-elevated);
382
+ --rui-popover-border-color: transparent;
383
+ --rui-popover-shadow: var(--macos-menu-shadow);
384
+ --rui-popover-radius: var(--border-radius-lg);
385
+ @apply border-transparent text-on-surface;
386
+ background-color: var(--macos-elevated);
387
+ box-shadow: var(--macos-menu-shadow);
388
+ backdrop-filter: blur(24px) saturate(1.6);
389
+ }
390
+
391
+ :root .rui-menu-button__menu,
392
+ :root .rui-menubar__menu,
393
+ :root .rui-select__listbox,
394
+ :root .rui-combobox__listbox {
395
+ --rui-popover-radius: var(--border-radius-md);
396
+ border-radius: var(--border-radius-md);
397
+ }
398
+
399
+ :root .rui-hover-card__content {
400
+ border-radius: var(--border-radius-lg);
401
+ }
402
+
403
+ :root .rui-select__listbox .rui-listbox,
404
+ :root .rui-combobox__listbox .rui-listbox,
405
+ :root .rui-popover--listbox .rui-listbox {
406
+ @apply bg-transparent p-[5px];
407
+ }
408
+
409
+ :root .rui-tooltip {
410
+ --rui-tooltip-surface: var(--macos-elevated-solid);
411
+ --rui-tooltip-color: var(--macos-text);
412
+ --rui-tooltip-radius: var(--border-radius-xs);
413
+ --rui-tooltip-shadow: 0 0 0 0.5px var(--macos-elevated-edge), 0 2px 8px rgb(0 0 0 / 0.18);
414
+ --rui-tooltip-padding-x: 0.375rem;
415
+ --rui-tooltip-padding-y: 0.125rem;
416
+ }
417
+
418
+ /**
419
+ * @remarks Alerts are window-background panels with 10px corners and a deep shadow; the title is bold text, not a
420
+ * title-bar band.
421
+ */
422
+ :root .rui-dialog {
423
+ --rui-dialog-surface: var(--macos-canvas);
424
+ --rui-dialog-radius: var(--border-radius-lg);
425
+ --rui-dialog-shadow: 0 0 0 0.5px var(--macos-elevated-edge), 0 20px 50px rgb(0 0 0 / 0.35);
426
+ }
427
+
428
+ :root .rui-dialog__surface {
429
+ @apply text-on-surface;
430
+ background-color: var(--macos-canvas);
431
+ box-shadow:
432
+ 0 0 0 0.5px var(--macos-elevated-edge),
433
+ inset 0 0 0 0.5px var(--macos-elevated-highlight),
434
+ 0 20px 50px rgb(0 0 0 / 0.35);
435
+ }
436
+
437
+ :root .rui-dialog__title {
438
+ @apply font-bold text-on-surface;
439
+ }
440
+
441
+ :root .rui-calendar {
442
+ @apply rounded-container border-0 text-on-surface;
443
+ background-color: var(--macos-surface);
444
+ box-shadow: var(--macos-control-shadow);
445
+ }
446
+
447
+ :root .rui-calendar__header {
448
+ @apply font-semibold text-on-surface;
449
+ }
450
+
451
+ :root .rui-sidebar__header {
452
+ @apply font-semibold text-on-surface;
136
453
  }
137
454
 
138
- :root .rui-dialog__title,
139
- :root .rui-calendar__header,
140
- :root .rui-sidebar__header,
141
- :root .rui-table__header {
142
- @apply bg-surface-container-low text-on-surface font-semibold;
455
+ /**
456
+ * Tabs are a segmented control: a recessed track with the selected segment raised as a push-button face. Boxed tabs
457
+ * center that control above the group box, as `NSTabView` does, but clear of its edge so it never clips content.
458
+ */
459
+ :root .rui-tabs__list {
460
+ @apply w-fit max-w-full gap-0 border-0 p-0.5;
461
+ border-radius: calc(var(--radius-control) + 1px);
462
+ background-color: color-mix(in srgb, var(--macos-text) 7%, transparent);
463
+ }
464
+
465
+ :root .rui-tabs__tab {
466
+ @apply rounded-control border-0 font-normal;
467
+ color: var(--macos-text);
468
+ padding-block: 0.125rem;
469
+ padding-inline: 0.75rem;
470
+ font-size: var(--text-control);
471
+ }
472
+
473
+ :root .rui-tabs__tab[aria-selected='true'] {
474
+ @apply font-normal;
475
+ background-color: var(--macos-control);
476
+ color: var(--macos-text);
477
+ box-shadow: var(--macos-control-shadow);
478
+ }
479
+
480
+ :root .rui-tabs__tab:focus-visible {
481
+ @apply ring-[3px] ring-focus-ring/60 ring-offset-0;
143
482
  }
144
483
 
145
484
  :root rui-tabs[variant='boxed'] {
146
- @apply rounded-container border border-border bg-surface shadow-sm;
485
+ @apply overflow-visible rounded-none border-0 bg-transparent shadow-none;
147
486
  }
148
487
 
149
488
  :root rui-tabs[variant='boxed'] .rui-tabs__list {
150
- @apply gap-1 border-0 bg-surface-container-low px-1 py-1;
151
- border-radius: var(--radius-control);
489
+ @apply relative z-10 mx-auto;
490
+ margin-bottom: 0.5rem;
491
+ padding-block: 0.125rem;
152
492
  }
153
493
 
154
- :root rui-tabs[variant='boxed'] .rui-tabs__tab {
155
- @apply rounded-control border-0 bg-transparent text-on-surface-container-low;
156
- padding-inline: var(--rui-tabs-tab-padding-x);
157
- padding-block: var(--rui-tabs-tab-padding-y);
494
+ :root.dark rui-tabs[variant='boxed'] .rui-tabs__list {
495
+ background-color: #2a2a2a;
158
496
  }
159
497
 
160
- :root rui-tabs[variant='boxed'] .rui-tabs__tab[aria-selected='true'] {
161
- @apply rounded-control bg-surface text-on-surface font-semibold shadow-sm;
498
+ :root:not(.dark) rui-tabs[variant='boxed'] .rui-tabs__list {
499
+ background-color: #e3e3e3;
500
+ }
501
+
502
+ :root rui-tabs[variant='boxed'] .rui-tabs__tab,
503
+ :root rui-tabs[variant='boxed'] .rui-tabs__tab:not([aria-selected='true']) {
504
+ @apply opacity-100;
505
+ color: var(--macos-text);
162
506
  border-bottom-color: transparent;
163
507
  }
164
508
 
165
509
  :root rui-tabs[variant='boxed'] .rui-tabs__panel {
166
- @apply rounded-none bg-surface;
510
+ @apply rounded-md text-on-surface;
511
+ border: 1px solid color-mix(in srgb, var(--macos-text) 12%, transparent);
512
+ background-color: color-mix(in srgb, var(--macos-text) 4%, transparent);
167
513
  padding: var(--rui-tabs-panel-padding);
168
514
  }
169
515
 
170
- :root .rui-tabs__tab[aria-selected='true'] {
171
- @apply rounded-pill bg-surface-container text-on-surface font-semibold;
172
- border-bottom-color: transparent;
516
+ :root .rui-alert,
517
+ :root .rui-toast {
518
+ @apply rounded-container border-transparent text-on-surface;
519
+ background-color: var(--macos-elevated);
520
+ background-image: none;
521
+ box-shadow: var(--macos-menu-shadow);
522
+ backdrop-filter: blur(24px) saturate(1.6);
173
523
  }
174
524
 
175
- :root .rui-alert,
176
- :root .rui-toast__content {
177
- @apply rounded-container border border-border bg-surface text-on-surface shadow-md;
525
+ /**
526
+ * @remarks Notification banners use the 16px corner of macOS notifications; status shows in the icon, not the text.
527
+ */
528
+ :root .rui-toast {
529
+ @apply rounded-2xl;
530
+ }
531
+
532
+ :root .rui-toast--info .rui-toast__icon {
533
+ color: var(--macos-accent);
534
+ }
535
+
536
+ :root .rui-toast--success .rui-toast__icon {
537
+ color: var(--success);
538
+ }
539
+
540
+ :root .rui-toast--warning .rui-toast__icon {
541
+ color: var(--warning);
542
+ }
543
+
544
+ :root .rui-toast--error .rui-toast__icon {
545
+ color: var(--error);
178
546
  }
179
547
 
180
548
  :root .rui-alert--info .rui-alert__icon {
181
- color: var(--info);
549
+ color: var(--macos-accent);
182
550
  }
183
551
 
184
552
  :root .rui-alert--success .rui-alert__icon {
@@ -193,15 +561,80 @@
193
561
  color: var(--error);
194
562
  }
195
563
 
196
- :root .rui-badge,
564
+ :root .rui-feed__article {
565
+ @apply rounded-container border-0 text-on-surface;
566
+ background-color: var(--macos-surface);
567
+ box-shadow: var(--macos-control-shadow);
568
+ }
569
+
570
+ :root .rui-badge {
571
+ @apply rounded-pill;
572
+ }
573
+
197
574
  :root .rui-chip,
198
575
  :root .rui-pagination__link {
199
- @apply rounded-pill;
576
+ @apply rounded-control;
200
577
  }
201
578
 
202
- :root .rui-table__row:nth-child(even),
203
- :root .rui-grid__row:nth-child(even) {
204
- @apply bg-surface-container-low;
579
+ /**
580
+ * @remarks Table views are white content areas with `alternatingContentBackgroundColors` stripes, a plain header
581
+ * divided by hairlines, and no grid lines between rows.
582
+ */
583
+ :root .rui-table,
584
+ :root .rui-grid {
585
+ background-color: var(--macos-surface);
586
+ }
587
+
588
+ :root .rui-grid {
589
+ @apply border-0;
590
+ box-shadow: var(--macos-control-shadow);
591
+ }
592
+
593
+ :root .rui-table__column,
594
+ :root .rui-table__cell,
595
+ :root .rui-grid__cell {
596
+ @apply border-b-transparent text-on-surface;
597
+ border-right-color: transparent;
598
+ background-color: var(--macos-surface);
599
+ }
600
+
601
+ :root .rui-table__column,
602
+ :root .rui-grid__row:first-child .rui-grid__cell {
603
+ @apply font-semibold;
604
+ border-bottom-color: var(--macos-grid);
605
+ border-right-color: var(--macos-grid);
606
+ }
607
+
608
+ :root .rui-table__row:nth-child(even) > .rui-table__cell,
609
+ :root .rui-grid__row:nth-child(odd):not(:first-child) > .rui-grid__cell {
610
+ background-color: var(--macos-alternate-row);
611
+ }
612
+
613
+ :root .rui-treegrid {
614
+ @apply rounded-container border-0 text-on-surface;
615
+ background-color: var(--macos-surface);
616
+ box-shadow: var(--macos-control-shadow);
617
+ --rui-treegrid-indent: 0.875rem;
618
+ }
619
+
620
+ :root .rui-treegrid__cell {
621
+ @apply border-0 bg-transparent px-2 py-1 text-on-surface;
622
+ font-size: var(--text-control);
623
+ }
624
+
625
+ :root .rui-treegrid__row--header .rui-treegrid__cell {
626
+ @apply font-semibold;
627
+ border-bottom: 1px solid var(--macos-grid);
628
+ background-color: var(--macos-surface);
629
+ }
630
+
631
+ :root .rui-treegrid__row:not(.rui-treegrid__row--header):hover .rui-treegrid__cell:not([aria-selected='true']) {
632
+ background-color: var(--macos-hover-fill);
633
+ }
634
+
635
+ :root .rui-treegrid__cell[aria-selected='true'] {
636
+ background-color: var(--macos-selection);
637
+ color: var(--macos-selection-text);
205
638
  }
206
639
 
207
640
  :root .rui-separator,
@@ -209,17 +642,43 @@
209
642
  @apply bg-border;
210
643
  }
211
644
 
212
- :root .rui-slider__thumb {
213
- @apply rounded-pill border border-surface bg-primary shadow-sm;
645
+ /**
646
+ * @remarks Sliders draw a thin grey track with an accent fill and a white knob with a soft shadow.
647
+ */
648
+ :root .rui-slider {
649
+ --rui-slider-track-size: 0.25rem;
650
+ --rui-slider-track-radius: 9999px;
651
+ --rui-slider-track-color: color-mix(in srgb, var(--macos-text) 15%, transparent);
652
+ --rui-slider-fill-color: var(--macos-accent);
653
+ --rui-slider-thumb-size: 1.25rem;
654
+ --rui-slider-thumb-radius: 9999px;
655
+ --rui-slider-thumb-border-width: 0px;
656
+ --rui-slider-thumb-border-color: transparent;
657
+ --rui-slider-thumb-background: #ffffff;
658
+ --rui-slider-thumb-shadow: 0 0 0 0.5px rgb(0 0 0 / 0.18), 0 1px 3px rgb(0 0 0 / 0.3);
659
+ --rui-slider-focus-ring-width: 3px;
660
+ --rui-slider-focus-ring: color-mix(in srgb, var(--focus-ring) 60%, transparent);
661
+ }
662
+
663
+ :root .rui-meter__track {
664
+ @apply rounded-pill;
665
+ background-color: color-mix(in srgb, var(--macos-text) 12%, transparent);
666
+ box-shadow: inset 0 0 0 0.5px rgb(0 0 0 / 0.08);
214
667
  }
215
668
 
216
- :root .rui-meter__track,
217
- :root .rui-slider__range-track {
218
- @apply rounded-pill bg-surface-container;
669
+ :root .rui-meter__fill {
670
+ @apply rounded-pill;
671
+ background-color: var(--macos-accent);
219
672
  }
673
+ }
220
674
 
221
- :root .rui-meter__fill,
222
- :root .rui-slider__range-fill {
223
- @apply rounded-pill bg-primary;
675
+ @media (prefers-contrast: more) {
676
+ @layer components {
677
+ :root .rui-button--outline,
678
+ :root .rui-button--destructive,
679
+ :root .rui-select__control,
680
+ :root .rui-tabs__tab[aria-selected='true'] {
681
+ border-color: var(--rui-control-border-color);
682
+ }
224
683
  }
225
684
  }