tyrell-components 1.0.0-RC13 → 1.0.0-RC15
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.
- package/README.md +10 -2
- package/css/tyrell-theme.css +192 -180
- package/css/tyrell.css +23 -0
- package/dist/tyrell-colors-static.css +1 -316
- package/dist/tyrell-theme.css +1 -1454
- package/dist/tyrell.css +1 -1371
- package/dist/tyrell.js +1 -1
- package/lib/base/ty-component.d.ts +20 -10
- package/lib/base/ty-component.js +196 -319
- package/lib/components/button.d.ts +3 -17
- package/lib/components/button.js +261 -295
- package/lib/components/calendar-month.d.ts +4 -50
- package/lib/components/calendar-month.js +443 -582
- package/lib/components/calendar-navigation.d.ts +3 -48
- package/lib/components/calendar-navigation.js +239 -362
- package/lib/components/calendar.d.ts +8 -83
- package/lib/components/calendar.js +616 -829
- package/lib/components/checkbox.d.ts +5 -72
- package/lib/components/checkbox.js +273 -416
- package/lib/components/copy.d.ts +4 -57
- package/lib/components/copy.js +280 -397
- package/lib/components/date-picker.d.ts +21 -163
- package/lib/components/date-picker.js +1143 -1674
- package/lib/components/file-upload.d.ts +9 -15
- package/lib/components/file-upload.js +404 -426
- package/lib/components/icon.d.ts +3 -24
- package/lib/components/icon.js +141 -230
- package/lib/components/input.d.ts +8 -108
- package/lib/components/input.js +593 -784
- package/lib/components/modal.d.ts +17 -26
- package/lib/components/modal.js +340 -484
- package/lib/components/option.d.ts +2 -9
- package/lib/components/option.js +168 -216
- package/lib/components/popup.d.ts +2 -17
- package/lib/components/popup.js +249 -380
- package/lib/components/radio.d.ts +5 -25
- package/lib/components/radio.js +407 -461
- package/lib/components/resize-observer.d.ts +3 -30
- package/lib/components/resize-observer.js +69 -103
- package/lib/components/scroll-container.d.ts +2 -12
- package/lib/components/scroll-container.js +293 -338
- package/lib/components/select.d.ts +87 -159
- package/lib/components/select.js +1609 -2090
- package/lib/components/selected-tags.d.ts +5 -48
- package/lib/components/selected-tags.js +188 -276
- package/lib/components/step.d.ts +1 -6
- package/lib/components/step.js +62 -68
- package/lib/components/switch.d.ts +1 -12
- package/lib/components/switch.js +214 -247
- package/lib/components/tab.d.ts +1 -6
- package/lib/components/tab.js +62 -69
- package/lib/components/tabs.d.ts +6 -63
- package/lib/components/tabs.js +545 -777
- package/lib/components/tag.d.ts +3 -37
- package/lib/components/tag.js +236 -335
- package/lib/components/textarea.d.ts +7 -87
- package/lib/components/textarea.js +457 -627
- package/lib/components/tooltip.d.ts +3 -11
- package/lib/components/tooltip.js +307 -443
- package/lib/components/wizard.d.ts +6 -54
- package/lib/components/wizard.js +405 -618
- package/lib/icons/fontawesome/brands.d.ts +0 -1
- package/lib/icons/fontawesome/brands.js +0 -8
- package/lib/icons/fontawesome/regular.d.ts +0 -1
- package/lib/icons/fontawesome/regular.js +0 -8
- package/lib/icons/fontawesome/solid.d.ts +0 -1
- package/lib/icons/fontawesome/solid.js +0 -8
- package/lib/icons/heroicons/micro.d.ts +0 -1
- package/lib/icons/heroicons/micro.js +392 -400
- package/lib/icons/heroicons/mini.d.ts +0 -1
- package/lib/icons/heroicons/mini.js +382 -390
- package/lib/icons/heroicons/outline.d.ts +0 -1
- package/lib/icons/heroicons/outline.js +337 -345
- package/lib/icons/heroicons/solid.d.ts +0 -1
- package/lib/icons/heroicons/solid.js +407 -415
- package/lib/icons/lucide.d.ts +0 -1
- package/lib/icons/lucide.js +24479 -26351
- package/lib/icons/material/filled.d.ts +0 -1
- package/lib/icons/material/filled.js +9653 -9663
- package/lib/icons/material/outlined.d.ts +0 -1
- package/lib/icons/material/outlined.js +10271 -10281
- package/lib/icons/material/round.d.ts +0 -1
- package/lib/icons/material/round.js +10495 -10505
- package/lib/icons/material/sharp.d.ts +0 -1
- package/lib/icons/material/sharp.js +9905 -9915
- package/lib/icons/material/two-tone.d.ts +0 -1
- package/lib/icons/material/two-tone.js +12792 -12802
- package/lib/index.d.ts +0 -1
- package/lib/index.js +21 -41
- package/lib/styles/button.d.ts +2 -20
- package/lib/styles/button.js +202 -404
- package/lib/styles/calendar-month.d.ts +1 -5
- package/lib/styles/calendar-month.js +127 -244
- package/lib/styles/calendar-navigation.d.ts +2 -6
- package/lib/styles/calendar-navigation.js +64 -104
- package/lib/styles/calendar.d.ts +1 -2
- package/lib/styles/calendar.js +9 -22
- package/lib/styles/checkbox.d.ts +0 -1
- package/lib/styles/checkbox.js +45 -94
- package/lib/styles/copy.d.ts +0 -1
- package/lib/styles/copy.js +67 -106
- package/lib/styles/custom-scrollbar.d.ts +1 -2
- package/lib/styles/custom-scrollbar.js +80 -115
- package/lib/styles/date-picker.d.ts +1 -5
- package/lib/styles/date-picker.js +261 -335
- package/lib/styles/field-size.d.ts +6 -0
- package/lib/styles/field-size.js +91 -0
- package/lib/styles/file-upload.d.ts +1 -2
- package/lib/styles/file-upload.js +143 -188
- package/lib/styles/icon.d.ts +2 -6
- package/lib/styles/icon.js +92 -170
- package/lib/styles/input.d.ts +1 -6
- package/lib/styles/input.js +125 -290
- package/lib/styles/modal.d.ts +1 -2
- package/lib/styles/modal.js +71 -108
- package/lib/styles/option.d.ts +2 -6
- package/lib/styles/option.js +49 -64
- package/lib/styles/popup.d.ts +1 -2
- package/lib/styles/popup.js +42 -77
- package/lib/styles/radio.d.ts +0 -1
- package/lib/styles/radio.js +69 -110
- package/lib/styles/resize-observer.d.ts +1 -2
- package/lib/styles/resize-observer.js +2 -12
- package/lib/styles/scroll-container.d.ts +1 -2
- package/lib/styles/scroll-container.js +100 -149
- package/lib/styles/select-base.d.ts +0 -1
- package/lib/styles/select-base.js +597 -785
- package/lib/styles/select.d.ts +1 -2
- package/lib/styles/select.js +140 -236
- package/lib/styles/step.d.ts +1 -2
- package/lib/styles/step.js +22 -33
- package/lib/styles/switch.d.ts +0 -1
- package/lib/styles/switch.js +34 -73
- package/lib/styles/tab.d.ts +1 -2
- package/lib/styles/tab.js +22 -34
- package/lib/styles/tabs.d.ts +3 -11
- package/lib/styles/tabs.js +190 -222
- package/lib/styles/tag.d.ts +1 -5
- package/lib/styles/tag.js +136 -218
- package/lib/styles/textarea.d.ts +1 -2
- package/lib/styles/textarea.js +210 -319
- package/lib/styles/tooltip.d.ts +0 -1
- package/lib/styles/tooltip.js +3 -13
- package/lib/styles/wizard.d.ts +5 -21
- package/lib/styles/wizard.js +170 -306
- package/lib/types/common.d.ts +2 -2
- package/lib/types/common.js +6 -17
- package/lib/utils/calendar-utils.d.ts +4 -21
- package/lib/utils/calendar-utils.js +100 -273
- package/lib/utils/custom-scrollbar.d.ts +6 -20
- package/lib/utils/custom-scrollbar.js +273 -317
- package/lib/utils/flavor-sheet.d.ts +0 -1
- package/lib/utils/flavor-sheet.js +14 -37
- package/lib/utils/icon-registry.d.ts +0 -2
- package/lib/utils/icon-registry.js +137 -243
- package/lib/utils/icons.d.ts +0 -1
- package/lib/utils/icons.js +0 -9
- package/lib/utils/loader-registry.d.ts +0 -1
- package/lib/utils/loader-registry.js +3 -35
- package/lib/utils/locale.d.ts +2 -23
- package/lib/utils/locale.js +34 -120
- package/lib/utils/mobile.d.ts +0 -1
- package/lib/utils/mobile.js +1 -18
- package/lib/utils/number-format.d.ts +6 -3
- package/lib/utils/number-format.js +54 -110
- package/lib/utils/positioning.d.ts +50 -7
- package/lib/utils/positioning.js +224 -234
- package/lib/utils/property-capture.d.ts +5 -27
- package/lib/utils/property-capture.js +36 -144
- package/lib/utils/property-manager.d.ts +0 -1
- package/lib/utils/property-manager.js +126 -196
- package/lib/utils/resize-observer.d.ts +0 -1
- package/lib/utils/resize-observer.js +23 -59
- package/lib/utils/scroll-lock.d.ts +4 -11
- package/lib/utils/scroll-lock.js +65 -172
- package/lib/utils/styles.d.ts +0 -1
- package/lib/utils/styles.js +17 -41
- package/lib/version.d.ts +1 -2
- package/lib/version.js +1 -11
- package/package.json +4 -4
- package/lib/base/ty-component.d.ts.map +0 -1
- package/lib/base/ty-component.js.map +0 -1
- package/lib/components/button.d.ts.map +0 -1
- package/lib/components/button.js.map +0 -1
- package/lib/components/calendar-month.d.ts.map +0 -1
- package/lib/components/calendar-month.js.map +0 -1
- package/lib/components/calendar-navigation.d.ts.map +0 -1
- package/lib/components/calendar-navigation.js.map +0 -1
- package/lib/components/calendar.d.ts.map +0 -1
- package/lib/components/calendar.js.map +0 -1
- package/lib/components/checkbox.d.ts.map +0 -1
- package/lib/components/checkbox.js.map +0 -1
- package/lib/components/copy.d.ts.map +0 -1
- package/lib/components/copy.js.map +0 -1
- package/lib/components/date-picker.d.ts.map +0 -1
- package/lib/components/date-picker.js.map +0 -1
- package/lib/components/file-upload.d.ts.map +0 -1
- package/lib/components/file-upload.js.map +0 -1
- package/lib/components/icon.d.ts.map +0 -1
- package/lib/components/icon.js.map +0 -1
- package/lib/components/input.d.ts.map +0 -1
- package/lib/components/input.js.map +0 -1
- package/lib/components/modal.d.ts.map +0 -1
- package/lib/components/modal.js.map +0 -1
- package/lib/components/option.d.ts.map +0 -1
- package/lib/components/option.js.map +0 -1
- package/lib/components/popup.d.ts.map +0 -1
- package/lib/components/popup.js.map +0 -1
- package/lib/components/radio.d.ts.map +0 -1
- package/lib/components/radio.js.map +0 -1
- package/lib/components/resize-observer.d.ts.map +0 -1
- package/lib/components/resize-observer.js.map +0 -1
- package/lib/components/scroll-container.d.ts.map +0 -1
- package/lib/components/scroll-container.js.map +0 -1
- package/lib/components/select.d.ts.map +0 -1
- package/lib/components/select.js.map +0 -1
- package/lib/components/selected-tags.d.ts.map +0 -1
- package/lib/components/selected-tags.js.map +0 -1
- package/lib/components/step.d.ts.map +0 -1
- package/lib/components/step.js.map +0 -1
- package/lib/components/switch.d.ts.map +0 -1
- package/lib/components/switch.js.map +0 -1
- package/lib/components/tab.d.ts.map +0 -1
- package/lib/components/tab.js.map +0 -1
- package/lib/components/tabs.d.ts.map +0 -1
- package/lib/components/tabs.js.map +0 -1
- package/lib/components/tag.d.ts.map +0 -1
- package/lib/components/tag.js.map +0 -1
- package/lib/components/textarea.d.ts.map +0 -1
- package/lib/components/textarea.js.map +0 -1
- package/lib/components/tooltip.d.ts.map +0 -1
- package/lib/components/tooltip.js.map +0 -1
- package/lib/components/wizard.d.ts.map +0 -1
- package/lib/components/wizard.js.map +0 -1
- package/lib/icons/fontawesome/brands.d.ts.map +0 -1
- package/lib/icons/fontawesome/brands.js.map +0 -1
- package/lib/icons/fontawesome/regular.d.ts.map +0 -1
- package/lib/icons/fontawesome/regular.js.map +0 -1
- package/lib/icons/fontawesome/solid.d.ts.map +0 -1
- package/lib/icons/fontawesome/solid.js.map +0 -1
- package/lib/icons/heroicons/micro.d.ts.map +0 -1
- package/lib/icons/heroicons/micro.js.map +0 -1
- package/lib/icons/heroicons/mini.d.ts.map +0 -1
- package/lib/icons/heroicons/mini.js.map +0 -1
- package/lib/icons/heroicons/outline.d.ts.map +0 -1
- package/lib/icons/heroicons/outline.js.map +0 -1
- package/lib/icons/heroicons/solid.d.ts.map +0 -1
- package/lib/icons/heroicons/solid.js.map +0 -1
- package/lib/icons/lucide.d.ts.map +0 -1
- package/lib/icons/lucide.js.map +0 -1
- package/lib/icons/material/filled.d.ts.map +0 -1
- package/lib/icons/material/filled.js.map +0 -1
- package/lib/icons/material/outlined.d.ts.map +0 -1
- package/lib/icons/material/outlined.js.map +0 -1
- package/lib/icons/material/round.d.ts.map +0 -1
- package/lib/icons/material/round.js.map +0 -1
- package/lib/icons/material/sharp.d.ts.map +0 -1
- package/lib/icons/material/sharp.js.map +0 -1
- package/lib/icons/material/two-tone.d.ts.map +0 -1
- package/lib/icons/material/two-tone.js.map +0 -1
- package/lib/index.d.ts.map +0 -1
- package/lib/index.js.map +0 -1
- package/lib/styles/button.d.ts.map +0 -1
- package/lib/styles/button.js.map +0 -1
- package/lib/styles/calendar-month.d.ts.map +0 -1
- package/lib/styles/calendar-month.js.map +0 -1
- package/lib/styles/calendar-navigation.d.ts.map +0 -1
- package/lib/styles/calendar-navigation.js.map +0 -1
- package/lib/styles/calendar.d.ts.map +0 -1
- package/lib/styles/calendar.js.map +0 -1
- package/lib/styles/checkbox.d.ts.map +0 -1
- package/lib/styles/checkbox.js.map +0 -1
- package/lib/styles/copy.d.ts.map +0 -1
- package/lib/styles/copy.js.map +0 -1
- package/lib/styles/custom-scrollbar.d.ts.map +0 -1
- package/lib/styles/custom-scrollbar.js.map +0 -1
- package/lib/styles/date-picker.d.ts.map +0 -1
- package/lib/styles/date-picker.js.map +0 -1
- package/lib/styles/file-upload.d.ts.map +0 -1
- package/lib/styles/file-upload.js.map +0 -1
- package/lib/styles/icon.d.ts.map +0 -1
- package/lib/styles/icon.js.map +0 -1
- package/lib/styles/input.d.ts.map +0 -1
- package/lib/styles/input.js.map +0 -1
- package/lib/styles/modal.d.ts.map +0 -1
- package/lib/styles/modal.js.map +0 -1
- package/lib/styles/multiselect.d.ts +0 -8
- package/lib/styles/multiselect.d.ts.map +0 -1
- package/lib/styles/multiselect.js +0 -849
- package/lib/styles/multiselect.js.map +0 -1
- package/lib/styles/option.d.ts.map +0 -1
- package/lib/styles/option.js.map +0 -1
- package/lib/styles/popup.d.ts.map +0 -1
- package/lib/styles/popup.js.map +0 -1
- package/lib/styles/radio.d.ts.map +0 -1
- package/lib/styles/radio.js.map +0 -1
- package/lib/styles/resize-observer.d.ts.map +0 -1
- package/lib/styles/resize-observer.js.map +0 -1
- package/lib/styles/scroll-container.d.ts.map +0 -1
- package/lib/styles/scroll-container.js.map +0 -1
- package/lib/styles/select-base.d.ts.map +0 -1
- package/lib/styles/select-base.js.map +0 -1
- package/lib/styles/select.d.ts.map +0 -1
- package/lib/styles/select.js.map +0 -1
- package/lib/styles/step.d.ts.map +0 -1
- package/lib/styles/step.js.map +0 -1
- package/lib/styles/switch.d.ts.map +0 -1
- package/lib/styles/switch.js.map +0 -1
- package/lib/styles/tab.d.ts.map +0 -1
- package/lib/styles/tab.js.map +0 -1
- package/lib/styles/tabs.d.ts.map +0 -1
- package/lib/styles/tabs.js.map +0 -1
- package/lib/styles/tag.d.ts.map +0 -1
- package/lib/styles/tag.js.map +0 -1
- package/lib/styles/textarea.d.ts.map +0 -1
- package/lib/styles/textarea.js.map +0 -1
- package/lib/styles/tooltip.d.ts.map +0 -1
- package/lib/styles/tooltip.js.map +0 -1
- package/lib/styles/wizard.d.ts.map +0 -1
- package/lib/styles/wizard.js.map +0 -1
- package/lib/types/common.d.ts.map +0 -1
- package/lib/types/common.js.map +0 -1
- package/lib/utils/calendar-utils.d.ts.map +0 -1
- package/lib/utils/calendar-utils.js.map +0 -1
- package/lib/utils/custom-scrollbar.d.ts.map +0 -1
- package/lib/utils/custom-scrollbar.js.map +0 -1
- package/lib/utils/flavor-sheet.d.ts.map +0 -1
- package/lib/utils/flavor-sheet.js.map +0 -1
- package/lib/utils/icon-registry.d.ts.map +0 -1
- package/lib/utils/icon-registry.js.map +0 -1
- package/lib/utils/icons.d.ts.map +0 -1
- package/lib/utils/icons.js.map +0 -1
- package/lib/utils/loader-registry.d.ts.map +0 -1
- package/lib/utils/loader-registry.js.map +0 -1
- package/lib/utils/locale.d.ts.map +0 -1
- package/lib/utils/locale.js.map +0 -1
- package/lib/utils/mobile.d.ts.map +0 -1
- package/lib/utils/mobile.js.map +0 -1
- package/lib/utils/number-format.d.ts.map +0 -1
- package/lib/utils/number-format.js.map +0 -1
- package/lib/utils/parse-boolean.d.ts +0 -39
- package/lib/utils/parse-boolean.d.ts.map +0 -1
- package/lib/utils/parse-boolean.js +0 -58
- package/lib/utils/parse-boolean.js.map +0 -1
- package/lib/utils/positioning.d.ts.map +0 -1
- package/lib/utils/positioning.js.map +0 -1
- package/lib/utils/property-capture.d.ts.map +0 -1
- package/lib/utils/property-capture.js.map +0 -1
- package/lib/utils/property-manager.d.ts.map +0 -1
- package/lib/utils/property-manager.js.map +0 -1
- package/lib/utils/resize-observer.d.ts.map +0 -1
- package/lib/utils/resize-observer.js.map +0 -1
- package/lib/utils/scroll-lock.d.ts.map +0 -1
- package/lib/utils/scroll-lock.js.map +0 -1
- package/lib/utils/styles.d.ts.map +0 -1
- package/lib/utils/styles.js.map +0 -1
- package/lib/version.d.ts.map +0 -1
- package/lib/version.js.map +0 -1
package/css/tyrell-theme.css
CHANGED
|
@@ -13,8 +13,8 @@
|
|
|
13
13
|
* <link rel="stylesheet" href=".../tyrell-theme.css">
|
|
14
14
|
*
|
|
15
15
|
* :root {
|
|
16
|
-
* --ty-
|
|
17
|
-
* --ty-
|
|
16
|
+
* --ty-primary-hue: 200; // teal. Try 260 indigo, 30 orange, 145 emerald.
|
|
17
|
+
* --ty-primary-chroma: 0.13;
|
|
18
18
|
* }
|
|
19
19
|
*
|
|
20
20
|
* =====================================================================
|
|
@@ -24,9 +24,9 @@
|
|
|
24
24
|
* Every color in the library is one formula on five axes:
|
|
25
25
|
*
|
|
26
26
|
* oklch(
|
|
27
|
-
* L = L-curve[shade] × flavor-l-factor ← Tier
|
|
28
|
-
* C = flavor-chroma × saturation-curve[shade] ← Tier
|
|
29
|
-
* H = flavor-hue ← Tier
|
|
27
|
+
* L = L-curve[shade] × flavor-l-factor ← Tier 2 × Tier 4
|
|
28
|
+
* C = flavor-chroma × saturation-curve[shade] ← Tier 1 × Tier 3
|
|
29
|
+
* H = flavor-hue ← Tier 1
|
|
30
30
|
* )
|
|
31
31
|
*
|
|
32
32
|
* Pick a flavor (primary / success / warning / danger /
|
|
@@ -61,15 +61,15 @@
|
|
|
61
61
|
*
|
|
62
62
|
* SECTION 1 — KNOBS
|
|
63
63
|
* The variables you might want to override. Six tiers from drop-in
|
|
64
|
-
* rebrand (Tier 1) to surgical per-flavor tweak (Tier
|
|
65
|
-
* buttons (Tier
|
|
64
|
+
* rebrand (Tier 1) to surgical per-flavor tweak (Tier 4) plus solid
|
|
65
|
+
* buttons (Tier 5).
|
|
66
66
|
*
|
|
67
67
|
* SECTION 2 — IMPLEMENTATION
|
|
68
68
|
* The oklch() expressions that wire the knobs through to the actual
|
|
69
69
|
* color tokens. Rarely needs editing — Section 1 is the contract.
|
|
70
70
|
*
|
|
71
71
|
* Browser support: oklch() is in every evergreen browser since mid-2023.
|
|
72
|
-
* Tier
|
|
72
|
+
* Tier 5 (solid) additionally uses OKLCH relative color — oklch(from …) —
|
|
73
73
|
* which lands later: Chrome 119, Safari 16.4, Firefox 128 (mid-2024).
|
|
74
74
|
* Solid fills have no fallback below those versions.
|
|
75
75
|
*
|
|
@@ -83,59 +83,53 @@
|
|
|
83
83
|
* these in your own `:root` (or `html.dark` for per-mode tuning) —
|
|
84
84
|
* your declaration wins by source order.
|
|
85
85
|
*
|
|
86
|
-
* Tier 1 — SEEDS
|
|
87
|
-
* Tier 2 —
|
|
88
|
-
* Tier 3 —
|
|
89
|
-
* Tier 4 —
|
|
90
|
-
* Tier 5 — PER-FLAVOR L-FACTOR per-flavor lightness multiplier — push
|
|
86
|
+
* Tier 1 — FLAVOR SEEDS each flavor's hue + chroma, incl. primary.
|
|
87
|
+
* Tier 2 — L-CURVE 5 lightness stops for the emphasis ramp.
|
|
88
|
+
* Tier 3 — SATURATION CURVE per-shade chroma multipliers.
|
|
89
|
+
* Tier 4 — PER-FLAVOR L-FACTOR per-flavor lightness multiplier — push
|
|
91
90
|
* one flavor up or down without touching
|
|
92
91
|
* the others. Default 1.
|
|
93
|
-
* Tier
|
|
92
|
+
* Tier 5 — SOLID FILLS solid-button system: hover/active/tone
|
|
94
93
|
* L offsets + per-theme dim/desaturate.
|
|
95
94
|
* ===================================================================== */
|
|
96
95
|
|
|
97
96
|
:root {
|
|
98
97
|
/* ----------------------------------------------------------------
|
|
99
|
-
* Tier 1 — SEEDS
|
|
100
|
-
*
|
|
101
|
-
*
|
|
98
|
+
* Tier 1 — FLAVOR SEEDS
|
|
99
|
+
* Every flavor — including primary — is one hue + one chroma. No
|
|
100
|
+
* flavor derives from another; each is a standalone dial:
|
|
101
|
+
* --ty-success-hue: 160; (more teal)
|
|
102
|
+
* --ty-warning-chroma: 0.2; (more vivid)
|
|
103
|
+
* Rebrand by overriding --ty-primary-hue/-chroma alone; touch the
|
|
104
|
+
* others only when a specific flavor needs its own tuning.
|
|
102
105
|
* --------------------------------------------------------------*/
|
|
103
106
|
|
|
104
|
-
--ty-
|
|
105
|
-
--ty-
|
|
107
|
+
--ty-primary-hue: 252;
|
|
108
|
+
--ty-primary-chroma: 0.08; /* restrained default; the loud 0.2 read as "bollywood" */
|
|
106
109
|
|
|
107
|
-
/* Surface tint. 0 = monochrome surfaces (default, no
|
|
108
|
-
* Bump to ~0.005 (light) / ~0.012 (dark) to warm surfaces toward
|
|
110
|
+
/* Surface tint. 0 = monochrome surfaces (default, no primary leak).
|
|
111
|
+
* Bump to ~0.005 (light) / ~0.012 (dark) to warm surfaces toward primary. */
|
|
109
112
|
--ty-surface-chroma: 0;
|
|
110
113
|
|
|
111
|
-
/* ----------------------------------------------------------------
|
|
112
|
-
* Tier 2 — PER-FLAVOR ANCHORS
|
|
113
|
-
* Semantic colors (success/warning/danger/neutral) have their own
|
|
114
|
-
* hue + chroma seeds so they keep meaning across brand changes.
|
|
115
|
-
* Override any individually:
|
|
116
|
-
* --ty-success-hue: 160; (more teal)
|
|
117
|
-
* --ty-warning-chroma: 0.2; (more vivid)
|
|
118
|
-
* --------------------------------------------------------------*/
|
|
119
|
-
|
|
120
114
|
--ty-success-hue: 145;
|
|
121
|
-
--ty-success-chroma:
|
|
115
|
+
--ty-success-chroma: 0.086;
|
|
122
116
|
|
|
123
|
-
--ty-warning-hue:
|
|
124
|
-
--ty-warning-chroma:
|
|
117
|
+
--ty-warning-hue: 76;
|
|
118
|
+
--ty-warning-chroma: 0.178;
|
|
125
119
|
|
|
126
|
-
--ty-danger-hue:
|
|
127
|
-
--ty-danger-chroma:
|
|
120
|
+
--ty-danger-hue: 31;
|
|
121
|
+
--ty-danger-chroma: 0.134;
|
|
128
122
|
|
|
129
|
-
/* Neutral is ACHROMATIC by default — greys do not follow
|
|
123
|
+
/* Neutral is ACHROMATIC by default — greys do not follow primary.
|
|
130
124
|
* Most of an interface is monochrome; a rebrand should not drift it.
|
|
131
|
-
* To warm greys toward
|
|
132
|
-
* --ty-neutral-hue: var(--ty-
|
|
133
|
-
* --ty-neutral-chroma:
|
|
125
|
+
* To warm greys toward primary (the pre-2026-08 behavior), opt in:
|
|
126
|
+
* --ty-neutral-hue: var(--ty-primary-hue);
|
|
127
|
+
* --ty-neutral-chroma: 0.003; */
|
|
134
128
|
--ty-neutral-hue: 0;
|
|
135
129
|
--ty-neutral-chroma: 0;
|
|
136
130
|
|
|
137
131
|
/* ----------------------------------------------------------------
|
|
138
|
-
* Tier
|
|
132
|
+
* Tier 2 — L-CURVE (light mode)
|
|
139
133
|
* 5 lightness stops per flavor for the emphasis ramp.
|
|
140
134
|
* Lower L = darker = more emphasis in light mode.
|
|
141
135
|
* Plus 3 bg L stops for the soft-tint backgrounds.
|
|
@@ -147,9 +141,16 @@
|
|
|
147
141
|
--ty-l-soft: 0.72; /* - low emphasis */
|
|
148
142
|
--ty-l-faint: 0.88; /* -- min emphasis */
|
|
149
143
|
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
144
|
+
/* BG TRACK — the flavor's BASE color at low opacity, composited over
|
|
145
|
+
* whatever surface it sits on. No bg-specific L or chroma stops: the
|
|
146
|
+
* ink is always mid-scale (gamut-happy, l-factor-safe), and the alpha
|
|
147
|
+
* does the washing. Direction is automatic — the same token lightens
|
|
148
|
+
* a dark surface and darkens a light one — and l-factor reaches the
|
|
149
|
+
* tint only through the ink, scaled by alpha: it points, it doesn't
|
|
150
|
+
* shove. */
|
|
151
|
+
--ty-a-bg-base: 9%;
|
|
152
|
+
--ty-a-bg-bold: 17%;
|
|
153
|
+
--ty-a-bg-soft: 4%;
|
|
153
154
|
|
|
154
155
|
/* Text ladder (--ty-text-*) and surface borders — historically
|
|
155
156
|
* hardcoded hexes in tyrell.css that a rebrand never touched; now
|
|
@@ -202,7 +203,7 @@
|
|
|
202
203
|
--ty-focus-ring-alpha: 5%; /* focus ring mix strength (dark needs more) */
|
|
203
204
|
|
|
204
205
|
/* ----------------------------------------------------------------
|
|
205
|
-
* Tier
|
|
206
|
+
* Tier 3 — SATURATION CURVE
|
|
206
207
|
* Per-shade chroma multipliers. Each shade's chroma =
|
|
207
208
|
* flavor-chroma × multiplier. Drops near the extremes so
|
|
208
209
|
* near-white and near-black can hold their tint.
|
|
@@ -214,18 +215,14 @@
|
|
|
214
215
|
--ty-c-soft-mult: 0.77;
|
|
215
216
|
--ty-c-faint-mult: 0.46;
|
|
216
217
|
|
|
217
|
-
--ty-c-bg-base-mult: 0.15;
|
|
218
|
-
--ty-c-bg-bold-mult: 0.38;
|
|
219
|
-
--ty-c-bg-soft-mult: 0.08;
|
|
220
|
-
|
|
221
218
|
/* ----------------------------------------------------------------
|
|
222
|
-
* Tier
|
|
219
|
+
* Tier 4 — PER-FLAVOR L-FACTOR
|
|
223
220
|
* Multiplies the L-curve values for that flavor only. Default 1 =
|
|
224
|
-
* no change. Useful when one flavor's
|
|
225
|
-
*
|
|
221
|
+
* no change. Useful when one flavor's hue sits too close to
|
|
222
|
+
* primary's on the wheel and the buttons blend.
|
|
226
223
|
*
|
|
227
|
-
* Example:
|
|
228
|
-
* Both render as similar warm browns at
|
|
224
|
+
* Example: primary-hue: 47° (gold). Warning sits at 75° (amber).
|
|
225
|
+
* Both render as similar warm browns at that chroma. Drop warning
|
|
229
226
|
* a notch and it darkens enough to stand apart:
|
|
230
227
|
* --ty-warning-l-factor: 0.85;
|
|
231
228
|
*
|
|
@@ -235,24 +232,24 @@
|
|
|
235
232
|
* light AND set its inverse (1 / factor, roughly) in `html.dark`.
|
|
236
233
|
* --------------------------------------------------------------*/
|
|
237
234
|
|
|
238
|
-
--ty-primary-l-factor:
|
|
235
|
+
--ty-primary-l-factor: 0.96;
|
|
239
236
|
--ty-success-l-factor: 1;
|
|
240
|
-
--ty-warning-l-factor: 1.
|
|
241
|
-
--ty-danger-l-factor:
|
|
237
|
+
--ty-warning-l-factor: 1.3;
|
|
238
|
+
--ty-danger-l-factor: 0.93;
|
|
242
239
|
--ty-neutral-l-factor: 1;
|
|
243
240
|
|
|
244
241
|
/* ----------------------------------------------------------------
|
|
245
|
-
* Tier
|
|
242
|
+
* Tier 5 — SOLID FILLS
|
|
246
243
|
* Solid buttons are their OWN system, not the emphasis ramp. Each
|
|
247
244
|
* flavor's fill defaults to --ty-color-{flavor}; the knobs below
|
|
248
245
|
* derive its hover / active / tone+ / tone- and per-theme adjust.
|
|
249
|
-
* Math lives in SECTION 2 (search "Tier
|
|
246
|
+
* Math lives in SECTION 2 (search "Tier 5 — SOLID"); these are the
|
|
250
247
|
* dials.
|
|
251
248
|
*
|
|
252
249
|
* Axis A — interaction & tone, OKLCH L offsets on the fill.
|
|
253
250
|
* Axis B — per-theme adjust applied to the base fill (dim/desaturate).
|
|
254
251
|
*
|
|
255
|
-
* NOTE: like Tier
|
|
252
|
+
* NOTE: like Tier 4, the emphasis curve flips for dark, so these L
|
|
256
253
|
* offsets are sign-flipped in `html.dark` below (darken in light =
|
|
257
254
|
* lighten in dark). Keep the two blocks in sync.
|
|
258
255
|
* --------------------------------------------------------------*/
|
|
@@ -276,17 +273,32 @@
|
|
|
276
273
|
* black-text (Material treats amber the same way). Other flavors: 0. */
|
|
277
274
|
--ty-primary-solid-l: 0;
|
|
278
275
|
--ty-success-solid-l: 0;
|
|
279
|
-
--ty-warning-solid-l: 0
|
|
276
|
+
--ty-warning-solid-l: 0;
|
|
280
277
|
--ty-danger-solid-l: 0;
|
|
281
278
|
}
|
|
282
279
|
|
|
283
|
-
/* Dark mode overrides for the L-curve and saturation curve
|
|
284
|
-
*
|
|
280
|
+
/* Dark mode overrides for the L-curve and saturation curve, plus Tier 1
|
|
281
|
+
* (per-flavor hue/chroma, incl. primary) and Tier 4 (l-factor)
|
|
282
|
+
* — dark ships its own distinct flavor tuning here, not a
|
|
283
|
+
* carry-through of :root's light values. */
|
|
285
284
|
html.dark,
|
|
286
285
|
html[data-theme="dark"],
|
|
287
286
|
[data-ty-theme].dark,
|
|
288
287
|
[data-ty-theme][data-theme="dark"] {
|
|
289
|
-
|
|
288
|
+
--ty-primary-l-factor: 1;
|
|
289
|
+
--ty-solid-fg-threshold: 0.5 !important;
|
|
290
|
+
--ty-primary-hue: 226;
|
|
291
|
+
--ty-primary-chroma: 0.065;
|
|
292
|
+
--ty-success-hue: 129;
|
|
293
|
+
--ty-success-chroma: 0.092;
|
|
294
|
+
--ty-success-l-factor: 1.09;
|
|
295
|
+
--ty-danger-hue: 13;
|
|
296
|
+
--ty-danger-chroma: 0.101;
|
|
297
|
+
--ty-danger-l-factor: 1.06;
|
|
298
|
+
--ty-warning-hue: 82;
|
|
299
|
+
--ty-warning-chroma: 0.195;
|
|
300
|
+
--ty-warning-l-factor: 1.5;
|
|
301
|
+
/* Tier 2 dark — inverted curve. Higher L = lighter text = more
|
|
290
302
|
* emphasis on a dark background. */
|
|
291
303
|
--ty-l-strong: 0.72;
|
|
292
304
|
--ty-l-bold: 0.66;
|
|
@@ -294,9 +306,11 @@ html[data-theme="dark"],
|
|
|
294
306
|
--ty-l-soft: 0.46;
|
|
295
307
|
--ty-l-faint: 0.3;
|
|
296
308
|
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
--ty-
|
|
309
|
+
/* BG TRACK dark — dark ink sits closer to its surface in L than
|
|
310
|
+
* light's does, so the tint needs a touch more alpha to be felt. */
|
|
311
|
+
--ty-a-bg-base: 13%;
|
|
312
|
+
--ty-a-bg-bold: 22%;
|
|
313
|
+
--ty-a-bg-soft: 7%;
|
|
300
314
|
|
|
301
315
|
/* Text ladder + surface borders dark — L matched to the hexes
|
|
302
316
|
* tyrell.css used to hardcode (#fff/#f9fafb/#d6d6d6/#7f8590/#555a63,
|
|
@@ -330,12 +344,12 @@ html[data-theme="dark"],
|
|
|
330
344
|
--ty-l-bg-neutral-faint: 0.15;
|
|
331
345
|
--ty-c-bg-neutral-faint-mult: 2;
|
|
332
346
|
|
|
333
|
-
/* Tier
|
|
347
|
+
/* Tier 4 dark — neutral inks pulled down a notch against dark surfaces. */
|
|
334
348
|
--ty-neutral-l-factor: 0.8;
|
|
335
349
|
|
|
336
350
|
--ty-focus-ring-alpha: 20%;
|
|
337
351
|
|
|
338
|
-
/* Tier
|
|
352
|
+
/* Tier 3 dark — dim shades hold more chroma so they don't grey out;
|
|
339
353
|
* strong shades trim chroma so bright tones don't over-pop. */
|
|
340
354
|
--ty-c-strong-mult: 0.77;
|
|
341
355
|
--ty-c-bold-mult: 1;
|
|
@@ -343,11 +357,7 @@ html[data-theme="dark"],
|
|
|
343
357
|
--ty-c-soft-mult: 0.77;
|
|
344
358
|
--ty-c-faint-mult: 0.5;
|
|
345
359
|
|
|
346
|
-
|
|
347
|
-
--ty-c-bg-bold-mult: 0.54;
|
|
348
|
-
--ty-c-bg-soft-mult: 0.23;
|
|
349
|
-
|
|
350
|
-
/* Tier 6 dark — interaction offsets flip sign (press LIGHTENS on dark),
|
|
360
|
+
/* Tier 5 dark — interaction offsets flip sign (press LIGHTENS on dark),
|
|
351
361
|
* and the per-theme adjust dims + desaturates the fills against the
|
|
352
362
|
* dark canvas. (Computed solid tokens are declared once at html:root.) */
|
|
353
363
|
/* Bigger than light mode's 0.04/0.08: small L deltas at the dark end of
|
|
@@ -386,8 +396,8 @@ html[data-theme="dark"],
|
|
|
386
396
|
* Formulas are declared ONCE, at `html:root` (specificity 0,1,1 — NOT
|
|
387
397
|
* plain `:root` (0,1,0)): they out-rank tyrell.css's hardcoded light
|
|
388
398
|
* tokens by specificity and its hardcoded `html.dark` hexes (0,1,1) by
|
|
389
|
-
* source order, since the
|
|
390
|
-
* formula duplicates — the dials they read (Tier 3
|
|
399
|
+
* source order, since the theme layer loads after. Dark mode needs no
|
|
400
|
+
* formula duplicates — the dials they read (Tier 2/3, SECTION 1) are
|
|
391
401
|
* what flip per mode. The `html.dark` block at the END of this file
|
|
392
402
|
* holds only genuine per-mode DATA (surface ladder, hand-pinned
|
|
393
403
|
* absolutes) — never formulas. If you add a token here, do NOT mirror
|
|
@@ -403,8 +413,8 @@ html:root,
|
|
|
403
413
|
* ramp formula reads that seed's c + h channels via relative color
|
|
404
414
|
* syntax; L always comes from the mode-flipped curve. Two ways in:
|
|
405
415
|
*
|
|
406
|
-
* numbers (default) — the Tier 1
|
|
407
|
-
* seed: --ty-
|
|
416
|
+
* numbers (default) — the Tier 1 hue+chroma dials construct the
|
|
417
|
+
* seed: --ty-primary-hue: 200; --ty-primary-chroma: 0.13;
|
|
408
418
|
*
|
|
409
419
|
* a color — set the seed directly and the dials are bypassed:
|
|
410
420
|
* --ty-primary-seed: #76467c;
|
|
@@ -416,9 +426,23 @@ html:root,
|
|
|
416
426
|
* correct for ANY seed — light or dark. (Your exact pixel may
|
|
417
427
|
* appear nowhere; pin --ty-solid-X etc. if you need it literally.)
|
|
418
428
|
* --------------------------------------------------------------*/
|
|
429
|
+
/* BG TRACK — `--ty-bg-X` is the flavor's BASE ink at low alpha, real
|
|
430
|
+
* transparency, composited by the browser over whatever is actually
|
|
431
|
+
* underneath. Why this beats computing a tint lightness:
|
|
432
|
+
*
|
|
433
|
+
* - The ink is MID-SCALE (L 0.38–0.88), where the gamut is widest
|
|
434
|
+
* and `l-stop × l-factor` behaves — no near-white/near-black
|
|
435
|
+
* endpoint math, no chroma clipping, no hue drift.
|
|
436
|
+
* - Direction per mode is free: the same token darkens a light
|
|
437
|
+
* surface and lightens a dark one, on ANY surface level (content,
|
|
438
|
+
* elevated, floating), not just a nominal one.
|
|
439
|
+
* - l-factor points rather than shoves: it moves the ink a little,
|
|
440
|
+
* and only alpha × that movement reaches the tint.
|
|
441
|
+
*
|
|
442
|
+
* The wash amount is the --ty-a-bg-* dials (Tier 2 area). */
|
|
419
443
|
--ty-primary-seed-resolved: var(
|
|
420
444
|
--ty-primary-seed,
|
|
421
|
-
oklch(0.5 var(--ty-
|
|
445
|
+
oklch(0.5 var(--ty-primary-chroma) var(--ty-primary-hue))
|
|
422
446
|
);
|
|
423
447
|
--ty-success-seed-resolved: var(
|
|
424
448
|
--ty-success-seed,
|
|
@@ -464,19 +488,13 @@ html:root,
|
|
|
464
488
|
calc(c * var(--ty-c-faint-mult)) h
|
|
465
489
|
);
|
|
466
490
|
--ty-bg-primary: oklch(
|
|
467
|
-
from var(--ty-primary-
|
|
468
|
-
calc(var(--ty-l-bg-base) * var(--ty-primary-l-factor))
|
|
469
|
-
calc(c * var(--ty-c-bg-base-mult)) h
|
|
491
|
+
from var(--ty-color-primary) l c h / var(--ty-a-bg-base)
|
|
470
492
|
);
|
|
471
493
|
--ty-bg-primary-bold: oklch(
|
|
472
|
-
from var(--ty-primary-
|
|
473
|
-
calc(var(--ty-l-bg-bold) * var(--ty-primary-l-factor))
|
|
474
|
-
calc(c * var(--ty-c-bg-bold-mult)) h
|
|
494
|
+
from var(--ty-color-primary) l c h / var(--ty-a-bg-bold)
|
|
475
495
|
);
|
|
476
496
|
--ty-bg-primary-soft: oklch(
|
|
477
|
-
from var(--ty-primary-
|
|
478
|
-
calc(var(--ty-l-bg-soft) * var(--ty-primary-l-factor))
|
|
479
|
-
calc(c * var(--ty-c-bg-soft-mult)) h
|
|
497
|
+
from var(--ty-color-primary) l c h / var(--ty-a-bg-soft)
|
|
480
498
|
);
|
|
481
499
|
--ty-border-primary: var(--ty-color-primary-soft);
|
|
482
500
|
|
|
@@ -507,19 +525,13 @@ html:root,
|
|
|
507
525
|
calc(c * var(--ty-c-faint-mult)) h
|
|
508
526
|
);
|
|
509
527
|
--ty-bg-success: oklch(
|
|
510
|
-
from var(--ty-success-
|
|
511
|
-
calc(var(--ty-l-bg-base) * var(--ty-success-l-factor))
|
|
512
|
-
calc(c * var(--ty-c-bg-base-mult)) h
|
|
528
|
+
from var(--ty-color-success) l c h / var(--ty-a-bg-base)
|
|
513
529
|
);
|
|
514
530
|
--ty-bg-success-bold: oklch(
|
|
515
|
-
from var(--ty-success-
|
|
516
|
-
calc(var(--ty-l-bg-bold) * var(--ty-success-l-factor))
|
|
517
|
-
calc(c * var(--ty-c-bg-bold-mult)) h
|
|
531
|
+
from var(--ty-color-success) l c h / var(--ty-a-bg-bold)
|
|
518
532
|
);
|
|
519
533
|
--ty-bg-success-soft: oklch(
|
|
520
|
-
from var(--ty-success-
|
|
521
|
-
calc(var(--ty-l-bg-soft) * var(--ty-success-l-factor))
|
|
522
|
-
calc(c * var(--ty-c-bg-soft-mult)) h
|
|
534
|
+
from var(--ty-color-success) l c h / var(--ty-a-bg-soft)
|
|
523
535
|
);
|
|
524
536
|
--ty-border-success: var(--ty-color-success-soft);
|
|
525
537
|
|
|
@@ -550,19 +562,13 @@ html:root,
|
|
|
550
562
|
calc(c * var(--ty-c-faint-mult)) h
|
|
551
563
|
);
|
|
552
564
|
--ty-bg-danger: oklch(
|
|
553
|
-
from var(--ty-danger-
|
|
554
|
-
calc(var(--ty-l-bg-base) * var(--ty-danger-l-factor))
|
|
555
|
-
calc(c * var(--ty-c-bg-base-mult)) h
|
|
565
|
+
from var(--ty-color-danger) l c h / var(--ty-a-bg-base)
|
|
556
566
|
);
|
|
557
567
|
--ty-bg-danger-bold: oklch(
|
|
558
|
-
from var(--ty-danger-
|
|
559
|
-
calc(var(--ty-l-bg-bold) * var(--ty-danger-l-factor))
|
|
560
|
-
calc(c * var(--ty-c-bg-bold-mult)) h
|
|
568
|
+
from var(--ty-color-danger) l c h / var(--ty-a-bg-bold)
|
|
561
569
|
);
|
|
562
570
|
--ty-bg-danger-soft: oklch(
|
|
563
|
-
from var(--ty-danger-
|
|
564
|
-
calc(var(--ty-l-bg-soft) * var(--ty-danger-l-factor))
|
|
565
|
-
calc(c * var(--ty-c-bg-soft-mult)) h
|
|
571
|
+
from var(--ty-color-danger) l c h / var(--ty-a-bg-soft)
|
|
566
572
|
);
|
|
567
573
|
--ty-border-danger: var(--ty-color-danger-soft);
|
|
568
574
|
|
|
@@ -593,19 +599,13 @@ html:root,
|
|
|
593
599
|
calc(c * var(--ty-c-faint-mult)) h
|
|
594
600
|
);
|
|
595
601
|
--ty-bg-warning: oklch(
|
|
596
|
-
from var(--ty-warning-
|
|
597
|
-
calc(var(--ty-l-bg-base) * var(--ty-warning-l-factor))
|
|
598
|
-
calc(c * var(--ty-c-bg-base-mult)) h
|
|
602
|
+
from var(--ty-color-warning) l c h / var(--ty-a-bg-base)
|
|
599
603
|
);
|
|
600
604
|
--ty-bg-warning-bold: oklch(
|
|
601
|
-
from var(--ty-warning-
|
|
602
|
-
calc(var(--ty-l-bg-bold) * var(--ty-warning-l-factor))
|
|
603
|
-
calc(c * var(--ty-c-bg-bold-mult)) h
|
|
605
|
+
from var(--ty-color-warning) l c h / var(--ty-a-bg-bold)
|
|
604
606
|
);
|
|
605
607
|
--ty-bg-warning-soft: oklch(
|
|
606
|
-
from var(--ty-warning-
|
|
607
|
-
calc(var(--ty-l-bg-soft) * var(--ty-warning-l-factor))
|
|
608
|
-
calc(c * var(--ty-c-bg-soft-mult)) h
|
|
608
|
+
from var(--ty-color-warning) l c h / var(--ty-a-bg-soft)
|
|
609
609
|
);
|
|
610
610
|
--ty-border-warning: var(--ty-color-warning-soft);
|
|
611
611
|
|
|
@@ -636,19 +636,13 @@ html:root,
|
|
|
636
636
|
calc(c * var(--ty-c-faint-mult)) h
|
|
637
637
|
);
|
|
638
638
|
--ty-bg-neutral: oklch(
|
|
639
|
-
from var(--ty-neutral-
|
|
640
|
-
calc(var(--ty-l-bg-base) * var(--ty-neutral-l-factor))
|
|
641
|
-
calc(c * var(--ty-c-bg-base-mult)) h
|
|
639
|
+
from var(--ty-color-neutral) l c h / var(--ty-a-bg-base)
|
|
642
640
|
);
|
|
643
641
|
--ty-bg-neutral-bold: oklch(
|
|
644
|
-
from var(--ty-neutral-
|
|
645
|
-
calc(var(--ty-l-bg-bold) * var(--ty-neutral-l-factor))
|
|
646
|
-
calc(c * var(--ty-c-bg-bold-mult)) h
|
|
642
|
+
from var(--ty-color-neutral) l c h / var(--ty-a-bg-bold)
|
|
647
643
|
);
|
|
648
644
|
--ty-bg-neutral-soft: oklch(
|
|
649
|
-
from var(--ty-neutral-
|
|
650
|
-
calc(var(--ty-l-bg-soft) * var(--ty-neutral-l-factor))
|
|
651
|
-
calc(c * var(--ty-c-bg-soft-mult)) h
|
|
645
|
+
from var(--ty-color-neutral) l c h / var(--ty-a-bg-soft)
|
|
652
646
|
);
|
|
653
647
|
--ty-bg-neutral-strong: oklch(
|
|
654
648
|
from var(--ty-neutral-seed-resolved) var(--ty-l-bg-neutral-strong)
|
|
@@ -660,7 +654,7 @@ html:root,
|
|
|
660
654
|
);
|
|
661
655
|
|
|
662
656
|
/* ----------------------------------------------------------------
|
|
663
|
-
* Global neutral borders — own family, own L ladder (Tier
|
|
657
|
+
* Global neutral borders — own family, own L ladder (Tier 2).
|
|
664
658
|
* Tinted by the neutral seeds like everything grey, but NOT tied to
|
|
665
659
|
* the text emphasis curve or --ty-neutral-l-factor. Per-flavor
|
|
666
660
|
* accent borders (--ty-border-{flavor}) stay ink aliases — a colored
|
|
@@ -684,7 +678,7 @@ html:root,
|
|
|
684
678
|
|
|
685
679
|
/* ----------------------------------------------------------------
|
|
686
680
|
* Text ladder + surface borders — engine-wired versions of tokens
|
|
687
|
-
* tyrell.css hardcodes as hexes. Own L dials (Tier
|
|
681
|
+
* tyrell.css hardcodes as hexes. Own L dials (Tier 2), neutral
|
|
688
682
|
* hue/chroma tint. These out-rank the base hexes the same way every
|
|
689
683
|
* other token here does; a rebrand now reaches body text too.
|
|
690
684
|
* --------------------------------------------------------------*/
|
|
@@ -739,12 +733,18 @@ html:root,
|
|
|
739
733
|
);
|
|
740
734
|
|
|
741
735
|
/* ----------------------------------------------------------------
|
|
742
|
-
* Inputs — tied to neutral ramp so form controls retint with
|
|
736
|
+
* Inputs — tied to neutral ramp so form controls retint with primary.
|
|
743
737
|
* --------------------------------------------------------------*/
|
|
744
738
|
--ty-input-bg: var(--ty-surface-input);
|
|
745
739
|
--ty-input-color: var(--ty-color-neutral-strong);
|
|
746
|
-
|
|
747
|
-
|
|
740
|
+
/* Borders come from the BORDER family, not the neutral ink ramp: ink is
|
|
741
|
+
multiplied by --ty-neutral-l-factor (0.8 in dark), which crushed the
|
|
742
|
+
resting input border to L 0.24 against an L 0.18 input surface — half
|
|
743
|
+
the separation light gets (0.88 on 1.0). The border ladder is exempt
|
|
744
|
+
from that factor by design, and its own comments name these two as the
|
|
745
|
+
successors of neutral-faint / neutral-soft. */
|
|
746
|
+
--ty-input-border: var(--ty-border-soft);
|
|
747
|
+
--ty-input-border-hover: var(--ty-border);
|
|
748
748
|
--ty-input-border-focus: var(--ty-color-primary);
|
|
749
749
|
--ty-input-placeholder: var(--ty-color-neutral-soft);
|
|
750
750
|
--ty-input-disabled-bg: var(--ty-color-neutral-faint);
|
|
@@ -757,11 +757,28 @@ html:root,
|
|
|
757
757
|
);
|
|
758
758
|
}
|
|
759
759
|
|
|
760
|
+
/* Dark takes the border family one rung harder than light. Genuine per-mode
|
|
761
|
+
DATA, not a formula duplicate: a small L delta at the dark end of an
|
|
762
|
+
emissive screen reads much weaker than the same delta mid-scale (the same
|
|
763
|
+
reason dark hover/active offsets are bigger — see Tier 5 dark), so light's
|
|
764
|
+
soft/base pair lands too quiet here. Dark uses base/bold instead.
|
|
765
|
+
|
|
766
|
+
Placed AFTER the block above on purpose: html.dark and html:root are both
|
|
767
|
+
(0,1,1), so source order is what decides this one — moving it up to the
|
|
768
|
+
dial block at the top of the file would lose the tie. */
|
|
769
|
+
html.dark,
|
|
770
|
+
html[data-theme="dark"],
|
|
771
|
+
[data-ty-theme].dark,
|
|
772
|
+
[data-ty-theme][data-theme="dark"] {
|
|
773
|
+
--ty-input-border: var(--ty-border);
|
|
774
|
+
--ty-input-border-hover: var(--ty-border-bold);
|
|
775
|
+
}
|
|
776
|
+
|
|
760
777
|
/* ----------------------------------------------------------------
|
|
761
|
-
* Tier
|
|
778
|
+
* Tier 5 — SOLID (implementation)
|
|
762
779
|
* Solid is its OWN system, NOT the text/emphasis ramp. The dials
|
|
763
780
|
* (--ty-solid-hover-l / -active-l / -strong-l / -soft-l and
|
|
764
|
-
* --ty-solid-l / -c / -h) live in SECTION 1, Tier
|
|
781
|
+
* --ty-solid-l / -c / -h) live in SECTION 1, Tier 5. Below is the
|
|
765
782
|
* derivation only: base fill bakes in the per-theme adjust (Axis B);
|
|
766
783
|
* hover/active/strong/soft offset the base by Axis A. Override any
|
|
767
784
|
* single --ty-solid-{flavor}-{state} to recolor just that segment.
|
|
@@ -769,8 +786,8 @@ html:root,
|
|
|
769
786
|
* Declared at `html:root` (specificity 0,1,1) — NOT plain `:root` (0,1,0) —
|
|
770
787
|
* on purpose: it must out-rank tyrell.css's hardcoded dark solids at
|
|
771
788
|
* `html.dark` (0,1,1). It wins light by specificity over base's `html{}`,
|
|
772
|
-
* and wins dark by source order over base's `html.dark` (
|
|
773
|
-
* That's what lets dark solids re-tint with --ty-
|
|
789
|
+
* and wins dark by source order over base's `html.dark` (theme layer loads after).
|
|
790
|
+
* That's what lets dark solids re-tint with --ty-primary-hue. Declared ONCE —
|
|
774
791
|
* the oklch(from var(--ty-color-*)) formulas resolve per-mode automatically,
|
|
775
792
|
* so no dark duplicate is needed.
|
|
776
793
|
* --------------------------------------------------------------*/
|
|
@@ -807,7 +824,7 @@ html:root,
|
|
|
807
824
|
* SOLID FOREGROUNDS — auto-contrast.
|
|
808
825
|
*
|
|
809
826
|
* Each fill gets a foreground picked from its OWN lightness, so a
|
|
810
|
-
* rebrand (--ty-
|
|
827
|
+
* rebrand (--ty-primary-hue / --ty-primary-chroma / any L-curve override)
|
|
811
828
|
* can't strand white text on a pale fill. Branchless, no JS:
|
|
812
829
|
*
|
|
813
830
|
* clamp(0, (threshold - l) * 1000, 1) -> 1 (white) when the fill
|
|
@@ -823,9 +840,19 @@ html:root,
|
|
|
823
840
|
* or set --ty-solid-fg-threshold: 1 to force white everywhere.
|
|
824
841
|
* --------------------------------------------------------------*/
|
|
825
842
|
|
|
826
|
-
/* Crossover point. Fills lighter than this get black text
|
|
827
|
-
|
|
828
|
-
|
|
843
|
+
/* Crossover point. Fills lighter than this get black text; higher =
|
|
844
|
+
prefers white, lower = prefers black.
|
|
845
|
+
|
|
846
|
+
Measured in-browser at stock dials, not guessed: the L at which black
|
|
847
|
+
and white give EQUAL WCAG contrast is 0.553 (success) / 0.564 (neutral)
|
|
848
|
+
/ 0.569 (warning) / 0.570 (primary) / 0.578 (danger) — a 0.025 spread,
|
|
849
|
+
so one global dial can serve every hue. Sweeping all 30 fills (15 ×
|
|
850
|
+
light/dark), the window where every fill gets the better of black/white
|
|
851
|
+
is (0.544, 0.588]; 0.57 sits ~mid-window. It previously read 0.62 —
|
|
852
|
+
above every flavor's break-even — which put white on `warning+` in both
|
|
853
|
+
modes: 4.23:1 light, 3.95:1 dark, each below AA and each the worse of
|
|
854
|
+
the two choices. Locked by test/solid-contrast.test.ts. */
|
|
855
|
+
--ty-solid-fg-threshold: 0.75;
|
|
829
856
|
|
|
830
857
|
--ty-solid-primary-fg: oklch(
|
|
831
858
|
from var(--ty-solid-primary)
|
|
@@ -984,15 +1011,15 @@ html:root,
|
|
|
984
1011
|
* work, switches just snap (the pre-TC37 behavior).
|
|
985
1012
|
* ===================================================================== */
|
|
986
1013
|
|
|
987
|
-
@property --ty-
|
|
1014
|
+
@property --ty-primary-hue {
|
|
988
1015
|
syntax: "<number>";
|
|
989
1016
|
inherits: true;
|
|
990
|
-
initial-value:
|
|
1017
|
+
initial-value: 252;
|
|
991
1018
|
}
|
|
992
|
-
@property --ty-
|
|
1019
|
+
@property --ty-primary-chroma {
|
|
993
1020
|
syntax: "<number>";
|
|
994
1021
|
inherits: true;
|
|
995
|
-
initial-value: 0.
|
|
1022
|
+
initial-value: 0.08;
|
|
996
1023
|
}
|
|
997
1024
|
@property --ty-surface-chroma {
|
|
998
1025
|
syntax: "<number>";
|
|
@@ -1064,20 +1091,20 @@ html:root,
|
|
|
1064
1091
|
inherits: true;
|
|
1065
1092
|
initial-value: 0.88;
|
|
1066
1093
|
}
|
|
1067
|
-
@property --ty-
|
|
1068
|
-
syntax: "<
|
|
1094
|
+
@property --ty-a-bg-base {
|
|
1095
|
+
syntax: "<percentage>";
|
|
1069
1096
|
inherits: true;
|
|
1070
|
-
initial-value:
|
|
1097
|
+
initial-value: 9%;
|
|
1071
1098
|
}
|
|
1072
|
-
@property --ty-
|
|
1073
|
-
syntax: "<
|
|
1099
|
+
@property --ty-a-bg-bold {
|
|
1100
|
+
syntax: "<percentage>";
|
|
1074
1101
|
inherits: true;
|
|
1075
|
-
initial-value:
|
|
1102
|
+
initial-value: 17%;
|
|
1076
1103
|
}
|
|
1077
|
-
@property --ty-
|
|
1078
|
-
syntax: "<
|
|
1104
|
+
@property --ty-a-bg-soft {
|
|
1105
|
+
syntax: "<percentage>";
|
|
1079
1106
|
inherits: true;
|
|
1080
|
-
initial-value:
|
|
1107
|
+
initial-value: 4%;
|
|
1081
1108
|
}
|
|
1082
1109
|
@property --ty-l-text-strong {
|
|
1083
1110
|
syntax: "<number>";
|
|
@@ -1219,21 +1246,6 @@ html:root,
|
|
|
1219
1246
|
inherits: true;
|
|
1220
1247
|
initial-value: 0.46;
|
|
1221
1248
|
}
|
|
1222
|
-
@property --ty-c-bg-base-mult {
|
|
1223
|
-
syntax: "<number>";
|
|
1224
|
-
inherits: true;
|
|
1225
|
-
initial-value: 0.15;
|
|
1226
|
-
}
|
|
1227
|
-
@property --ty-c-bg-bold-mult {
|
|
1228
|
-
syntax: "<number>";
|
|
1229
|
-
inherits: true;
|
|
1230
|
-
initial-value: 0.38;
|
|
1231
|
-
}
|
|
1232
|
-
@property --ty-c-bg-soft-mult {
|
|
1233
|
-
syntax: "<number>";
|
|
1234
|
-
inherits: true;
|
|
1235
|
-
initial-value: 0.08;
|
|
1236
|
-
}
|
|
1237
1249
|
@property --ty-primary-l-factor {
|
|
1238
1250
|
syntax: "<number>";
|
|
1239
1251
|
inherits: true;
|
|
@@ -1346,7 +1358,7 @@ html:root,
|
|
|
1346
1358
|
@property --ty-solid-fg-threshold {
|
|
1347
1359
|
syntax: "<number>";
|
|
1348
1360
|
inherits: true;
|
|
1349
|
-
initial-value: 0.
|
|
1361
|
+
initial-value: 0.75;
|
|
1350
1362
|
}
|
|
1351
1363
|
@property --ty-focus-ring-alpha {
|
|
1352
1364
|
syntax: "<percentage>";
|
|
@@ -1384,21 +1396,21 @@ html:root,
|
|
|
1384
1396
|
html,
|
|
1385
1397
|
[data-ty-theme] {
|
|
1386
1398
|
transition-property:
|
|
1387
|
-
--ty-
|
|
1388
|
-
--ty-success-
|
|
1389
|
-
--ty-
|
|
1390
|
-
--ty-neutral-
|
|
1391
|
-
--ty-l-
|
|
1392
|
-
--ty-
|
|
1393
|
-
--ty-l-text-
|
|
1394
|
-
--ty-l-border-
|
|
1395
|
-
--ty-l-border, --ty-l-border
|
|
1396
|
-
--ty-l-
|
|
1397
|
-
--ty-l-surface-
|
|
1398
|
-
--ty-l-solid-neutral
|
|
1399
|
-
--ty-l-bg-neutral-
|
|
1400
|
-
--ty-c-
|
|
1401
|
-
--ty-c-
|
|
1399
|
+
--ty-primary-hue, --ty-primary-chroma, --ty-surface-chroma,
|
|
1400
|
+
--ty-success-hue, --ty-success-chroma, --ty-warning-hue,
|
|
1401
|
+
--ty-warning-chroma, --ty-danger-hue, --ty-danger-chroma,
|
|
1402
|
+
--ty-neutral-hue, --ty-neutral-chroma, --ty-l-strong, --ty-l-bold,
|
|
1403
|
+
--ty-l-base, --ty-l-soft, --ty-l-faint, --ty-a-bg-base, --ty-a-bg-bold,
|
|
1404
|
+
--ty-a-bg-soft, --ty-l-text-strong, --ty-l-text-bold, --ty-l-text-base,
|
|
1405
|
+
--ty-l-text-soft, --ty-l-text-faint, --ty-l-border-content,
|
|
1406
|
+
--ty-l-border-elevated, --ty-l-border-floating, --ty-l-border-strong,
|
|
1407
|
+
--ty-l-border-bold, --ty-l-border, --ty-l-border-soft,
|
|
1408
|
+
--ty-l-border-faint, --ty-l-surface-canvas, --ty-l-surface-content,
|
|
1409
|
+
--ty-l-surface-elevated, --ty-l-surface-floating, --ty-l-surface-input,
|
|
1410
|
+
--ty-l-solid-neutral, --ty-l-solid-neutral-strong,
|
|
1411
|
+
--ty-l-bg-neutral-strong, --ty-l-bg-neutral-faint,
|
|
1412
|
+
--ty-c-bg-neutral-faint-mult, --ty-c-strong-mult, --ty-c-bold-mult,
|
|
1413
|
+
--ty-c-base-mult, --ty-c-soft-mult, --ty-c-faint-mult,
|
|
1402
1414
|
--ty-primary-l-factor, --ty-success-l-factor, --ty-warning-l-factor,
|
|
1403
1415
|
--ty-danger-l-factor, --ty-neutral-l-factor, --ty-primary-solid-l,
|
|
1404
1416
|
--ty-success-solid-l, --ty-warning-solid-l, --ty-danger-solid-l,
|