tyrell-components 1.0.0-RC10
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/LICENSE +21 -0
- package/README.md +221 -0
- package/css/tyrell-brand.css +767 -0
- package/css/tyrell.css +1679 -0
- package/dist/tyrell-brand.css +767 -0
- package/dist/tyrell.css +1679 -0
- package/dist/tyrell.js +2 -0
- package/lib/base/ty-component.d.ts +133 -0
- package/lib/base/ty-component.d.ts.map +1 -0
- package/lib/base/ty-component.js +297 -0
- package/lib/base/ty-component.js.map +1 -0
- package/lib/components/button.d.ts +135 -0
- package/lib/components/button.d.ts.map +1 -0
- package/lib/components/button.js +277 -0
- package/lib/components/button.js.map +1 -0
- package/lib/components/calendar-month.d.ts +132 -0
- package/lib/components/calendar-month.d.ts.map +1 -0
- package/lib/components/calendar-month.js +440 -0
- package/lib/components/calendar-month.js.map +1 -0
- package/lib/components/calendar-navigation.d.ts +137 -0
- package/lib/components/calendar-navigation.d.ts.map +1 -0
- package/lib/components/calendar-navigation.js +366 -0
- package/lib/components/calendar-navigation.js.map +1 -0
- package/lib/components/calendar.d.ts +166 -0
- package/lib/components/calendar.d.ts.map +1 -0
- package/lib/components/calendar.js +774 -0
- package/lib/components/calendar.js.map +1 -0
- package/lib/components/checkbox.d.ts +189 -0
- package/lib/components/checkbox.d.ts.map +1 -0
- package/lib/components/checkbox.js +400 -0
- package/lib/components/checkbox.js.map +1 -0
- package/lib/components/copy.d.ts +180 -0
- package/lib/components/copy.d.ts.map +1 -0
- package/lib/components/copy.js +393 -0
- package/lib/components/copy.js.map +1 -0
- package/lib/components/date-picker.d.ts +379 -0
- package/lib/components/date-picker.d.ts.map +1 -0
- package/lib/components/date-picker.js +1586 -0
- package/lib/components/date-picker.js.map +1 -0
- package/lib/components/dropdown.d.ts +424 -0
- package/lib/components/dropdown.d.ts.map +1 -0
- package/lib/components/dropdown.js +1640 -0
- package/lib/components/dropdown.js.map +1 -0
- package/lib/components/file-upload.d.ts +121 -0
- package/lib/components/file-upload.d.ts.map +1 -0
- package/lib/components/file-upload.js +441 -0
- package/lib/components/file-upload.js.map +1 -0
- package/lib/components/icon.d.ts +118 -0
- package/lib/components/icon.d.ts.map +1 -0
- package/lib/components/icon.js +245 -0
- package/lib/components/icon.js.map +1 -0
- package/lib/components/input.d.ts +270 -0
- package/lib/components/input.d.ts.map +1 -0
- package/lib/components/input.js +721 -0
- package/lib/components/input.js.map +1 -0
- package/lib/components/modal.d.ts +78 -0
- package/lib/components/modal.d.ts.map +1 -0
- package/lib/components/modal.js +497 -0
- package/lib/components/modal.js.map +1 -0
- package/lib/components/multiselect.d.ts +397 -0
- package/lib/components/multiselect.d.ts.map +1 -0
- package/lib/components/multiselect.js +1595 -0
- package/lib/components/multiselect.js.map +1 -0
- package/lib/components/option.d.ts +66 -0
- package/lib/components/option.d.ts.map +1 -0
- package/lib/components/option.js +314 -0
- package/lib/components/option.js.map +1 -0
- package/lib/components/popup.d.ts +43 -0
- package/lib/components/popup.d.ts.map +1 -0
- package/lib/components/popup.js +380 -0
- package/lib/components/popup.js.map +1 -0
- package/lib/components/radio.d.ts +198 -0
- package/lib/components/radio.d.ts.map +1 -0
- package/lib/components/radio.js +437 -0
- package/lib/components/radio.js.map +1 -0
- package/lib/components/resize-observer.d.ts +48 -0
- package/lib/components/resize-observer.d.ts.map +1 -0
- package/lib/components/resize-observer.js +108 -0
- package/lib/components/resize-observer.js.map +1 -0
- package/lib/components/scroll-container.d.ts +51 -0
- package/lib/components/scroll-container.d.ts.map +1 -0
- package/lib/components/scroll-container.js +239 -0
- package/lib/components/scroll-container.js.map +1 -0
- package/lib/components/step.d.ts +26 -0
- package/lib/components/step.d.ts.map +1 -0
- package/lib/components/step.js +75 -0
- package/lib/components/step.js.map +1 -0
- package/lib/components/switch.d.ts +111 -0
- package/lib/components/switch.d.ts.map +1 -0
- package/lib/components/switch.js +240 -0
- package/lib/components/switch.js.map +1 -0
- package/lib/components/tab.d.ts +23 -0
- package/lib/components/tab.d.ts.map +1 -0
- package/lib/components/tab.js +76 -0
- package/lib/components/tab.js.map +1 -0
- package/lib/components/tabs.d.ts +93 -0
- package/lib/components/tabs.d.ts.map +1 -0
- package/lib/components/tabs.js +653 -0
- package/lib/components/tabs.js.map +1 -0
- package/lib/components/tag.d.ts +144 -0
- package/lib/components/tag.d.ts.map +1 -0
- package/lib/components/tag.js +316 -0
- package/lib/components/tag.js.map +1 -0
- package/lib/components/textarea.d.ts +241 -0
- package/lib/components/textarea.d.ts.map +1 -0
- package/lib/components/textarea.js +585 -0
- package/lib/components/textarea.js.map +1 -0
- package/lib/components/tooltip.d.ts +40 -0
- package/lib/components/tooltip.d.ts.map +1 -0
- package/lib/components/tooltip.js +439 -0
- package/lib/components/tooltip.js.map +1 -0
- package/lib/components/wizard.d.ts +86 -0
- package/lib/components/wizard.d.ts.map +1 -0
- package/lib/components/wizard.js +636 -0
- package/lib/components/wizard.js.map +1 -0
- package/lib/icons/fontawesome/brands.d.ts +557 -0
- package/lib/icons/fontawesome/brands.d.ts.map +1 -0
- package/lib/icons/fontawesome/brands.js +557 -0
- package/lib/icons/fontawesome/brands.js.map +1 -0
- package/lib/icons/fontawesome/regular.d.ts +281 -0
- package/lib/icons/fontawesome/regular.d.ts.map +1 -0
- package/lib/icons/fontawesome/regular.js +281 -0
- package/lib/icons/fontawesome/regular.js.map +1 -0
- package/lib/icons/fontawesome/solid.d.ts +1992 -0
- package/lib/icons/fontawesome/solid.d.ts.map +1 -0
- package/lib/icons/fontawesome/solid.js +1992 -0
- package/lib/icons/fontawesome/solid.js.map +1 -0
- package/lib/icons/heroicons/micro.d.ts +324 -0
- package/lib/icons/heroicons/micro.d.ts.map +1 -0
- package/lib/icons/heroicons/micro.js +1032 -0
- package/lib/icons/heroicons/micro.js.map +1 -0
- package/lib/icons/heroicons/mini.d.ts +332 -0
- package/lib/icons/heroicons/mini.d.ts.map +1 -0
- package/lib/icons/heroicons/mini.js +1038 -0
- package/lib/icons/heroicons/mini.js.map +1 -0
- package/lib/icons/heroicons/outline.d.ts +332 -0
- package/lib/icons/heroicons/outline.d.ts.map +1 -0
- package/lib/icons/heroicons/outline.js +993 -0
- package/lib/icons/heroicons/outline.js.map +1 -0
- package/lib/icons/heroicons/solid.d.ts +332 -0
- package/lib/icons/heroicons/solid.d.ts.map +1 -0
- package/lib/icons/heroicons/solid.js +1063 -0
- package/lib/icons/heroicons/solid.js.map +1 -0
- package/lib/icons/lucide.d.ts +1872 -0
- package/lib/icons/lucide.d.ts.map +1 -0
- package/lib/icons/lucide.js +28212 -0
- package/lib/icons/lucide.js.map +1 -0
- package/lib/icons/material/filled.d.ts +2180 -0
- package/lib/icons/material/filled.d.ts.map +1 -0
- package/lib/icons/material/filled.js +14003 -0
- package/lib/icons/material/filled.js.map +1 -0
- package/lib/icons/material/outlined.d.ts +2142 -0
- package/lib/icons/material/outlined.d.ts.map +1 -0
- package/lib/icons/material/outlined.js +14545 -0
- package/lib/icons/material/outlined.js.map +1 -0
- package/lib/icons/material/round.d.ts +2147 -0
- package/lib/icons/material/round.d.ts.map +1 -0
- package/lib/icons/material/round.js +14779 -0
- package/lib/icons/material/round.js.map +1 -0
- package/lib/icons/material/sharp.d.ts +2147 -0
- package/lib/icons/material/sharp.d.ts.map +1 -0
- package/lib/icons/material/sharp.js +14189 -0
- package/lib/icons/material/sharp.js.map +1 -0
- package/lib/icons/material/two-tone.d.ts +2185 -0
- package/lib/icons/material/two-tone.d.ts.map +1 -0
- package/lib/icons/material/two-tone.js +17152 -0
- package/lib/icons/material/two-tone.js.map +1 -0
- package/lib/index.d.ts +86 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +78 -0
- package/lib/index.js.map +1 -0
- package/lib/styles/button.d.ts +14 -0
- package/lib/styles/button.d.ts.map +1 -0
- package/lib/styles/button.js +498 -0
- package/lib/styles/button.js.map +1 -0
- package/lib/styles/calendar-month.d.ts +6 -0
- package/lib/styles/calendar-month.d.ts.map +1 -0
- package/lib/styles/calendar-month.js +275 -0
- package/lib/styles/calendar-month.js.map +1 -0
- package/lib/styles/calendar-navigation.d.ts +6 -0
- package/lib/styles/calendar-navigation.d.ts.map +1 -0
- package/lib/styles/calendar-navigation.js +143 -0
- package/lib/styles/calendar-navigation.js.map +1 -0
- package/lib/styles/calendar.d.ts +6 -0
- package/lib/styles/calendar.d.ts.map +1 -0
- package/lib/styles/calendar.js +28 -0
- package/lib/styles/calendar.js.map +1 -0
- package/lib/styles/checkbox.d.ts +9 -0
- package/lib/styles/checkbox.d.ts.map +1 -0
- package/lib/styles/checkbox.js +19 -0
- package/lib/styles/checkbox.js.map +1 -0
- package/lib/styles/copy.d.ts +7 -0
- package/lib/styles/copy.d.ts.map +1 -0
- package/lib/styles/copy.js +94 -0
- package/lib/styles/copy.js.map +1 -0
- package/lib/styles/custom-scrollbar.d.ts +6 -0
- package/lib/styles/custom-scrollbar.d.ts.map +1 -0
- package/lib/styles/custom-scrollbar.js +157 -0
- package/lib/styles/custom-scrollbar.js.map +1 -0
- package/lib/styles/date-picker.d.ts +6 -0
- package/lib/styles/date-picker.d.ts.map +1 -0
- package/lib/styles/date-picker.js +438 -0
- package/lib/styles/date-picker.js.map +1 -0
- package/lib/styles/dropdown.d.ts +12 -0
- package/lib/styles/dropdown.d.ts.map +1 -0
- package/lib/styles/dropdown.js +1081 -0
- package/lib/styles/dropdown.js.map +1 -0
- package/lib/styles/file-upload.d.ts +2 -0
- package/lib/styles/file-upload.d.ts.map +1 -0
- package/lib/styles/file-upload.js +241 -0
- package/lib/styles/file-upload.js.map +1 -0
- package/lib/styles/icon.d.ts +6 -0
- package/lib/styles/icon.d.ts.map +1 -0
- package/lib/styles/icon.js +241 -0
- package/lib/styles/icon.js.map +1 -0
- package/lib/styles/input.d.ts +7 -0
- package/lib/styles/input.d.ts.map +1 -0
- package/lib/styles/input.js +685 -0
- package/lib/styles/input.js.map +1 -0
- package/lib/styles/modal.d.ts +8 -0
- package/lib/styles/modal.d.ts.map +1 -0
- package/lib/styles/modal.js +134 -0
- package/lib/styles/modal.js.map +1 -0
- package/lib/styles/multiselect.d.ts +6 -0
- package/lib/styles/multiselect.d.ts.map +1 -0
- package/lib/styles/multiselect.js +825 -0
- package/lib/styles/multiselect.js.map +1 -0
- package/lib/styles/option.d.ts +6 -0
- package/lib/styles/option.d.ts.map +1 -0
- package/lib/styles/option.js +116 -0
- package/lib/styles/option.js.map +1 -0
- package/lib/styles/popup.d.ts +8 -0
- package/lib/styles/popup.d.ts.map +1 -0
- package/lib/styles/popup.js +95 -0
- package/lib/styles/popup.js.map +1 -0
- package/lib/styles/radio.d.ts +8 -0
- package/lib/styles/radio.d.ts.map +1 -0
- package/lib/styles/radio.js +160 -0
- package/lib/styles/radio.js.map +1 -0
- package/lib/styles/resize-observer.d.ts +6 -0
- package/lib/styles/resize-observer.d.ts.map +1 -0
- package/lib/styles/resize-observer.js +18 -0
- package/lib/styles/resize-observer.js.map +1 -0
- package/lib/styles/scroll-container.d.ts +6 -0
- package/lib/styles/scroll-container.d.ts.map +1 -0
- package/lib/styles/scroll-container.js +198 -0
- package/lib/styles/scroll-container.js.map +1 -0
- package/lib/styles/step.d.ts +5 -0
- package/lib/styles/step.d.ts.map +1 -0
- package/lib/styles/step.js +50 -0
- package/lib/styles/step.js.map +1 -0
- package/lib/styles/switch.d.ts +9 -0
- package/lib/styles/switch.d.ts.map +1 -0
- package/lib/styles/switch.js +100 -0
- package/lib/styles/switch.js.map +1 -0
- package/lib/styles/tab.d.ts +5 -0
- package/lib/styles/tab.d.ts.map +1 -0
- package/lib/styles/tab.js +51 -0
- package/lib/styles/tab.js.map +1 -0
- package/lib/styles/tabs.d.ts +13 -0
- package/lib/styles/tabs.d.ts.map +1 -0
- package/lib/styles/tabs.js +184 -0
- package/lib/styles/tabs.js.map +1 -0
- package/lib/styles/tag.d.ts +6 -0
- package/lib/styles/tag.d.ts.map +1 -0
- package/lib/styles/tag.js +409 -0
- package/lib/styles/tag.js.map +1 -0
- package/lib/styles/textarea.d.ts +6 -0
- package/lib/styles/textarea.d.ts.map +1 -0
- package/lib/styles/textarea.js +350 -0
- package/lib/styles/textarea.js.map +1 -0
- package/lib/styles/tooltip.d.ts +9 -0
- package/lib/styles/tooltip.d.ts.map +1 -0
- package/lib/styles/tooltip.js +133 -0
- package/lib/styles/tooltip.js.map +1 -0
- package/lib/styles/wizard.d.ts +25 -0
- package/lib/styles/wizard.d.ts.map +1 -0
- package/lib/styles/wizard.js +348 -0
- package/lib/styles/wizard.js.map +1 -0
- package/lib/types/common.d.ts +143 -0
- package/lib/types/common.d.ts.map +1 -0
- package/lib/types/common.js +5 -0
- package/lib/types/common.js.map +1 -0
- package/lib/utils/calendar-utils.d.ts +176 -0
- package/lib/utils/calendar-utils.d.ts.map +1 -0
- package/lib/utils/calendar-utils.js +370 -0
- package/lib/utils/calendar-utils.js.map +1 -0
- package/lib/utils/custom-scrollbar.d.ts +82 -0
- package/lib/utils/custom-scrollbar.d.ts.map +1 -0
- package/lib/utils/custom-scrollbar.js +320 -0
- package/lib/utils/custom-scrollbar.js.map +1 -0
- package/lib/utils/icon-registry.d.ts +78 -0
- package/lib/utils/icon-registry.d.ts.map +1 -0
- package/lib/utils/icon-registry.js +304 -0
- package/lib/utils/icon-registry.js.map +1 -0
- package/lib/utils/loader-registry.d.ts +35 -0
- package/lib/utils/loader-registry.d.ts.map +1 -0
- package/lib/utils/loader-registry.js +43 -0
- package/lib/utils/loader-registry.js.map +1 -0
- package/lib/utils/locale.d.ts +136 -0
- package/lib/utils/locale.d.ts.map +1 -0
- package/lib/utils/locale.js +213 -0
- package/lib/utils/locale.js.map +1 -0
- package/lib/utils/mobile.d.ts +14 -0
- package/lib/utils/mobile.d.ts.map +1 -0
- package/lib/utils/mobile.js +21 -0
- package/lib/utils/mobile.js.map +1 -0
- package/lib/utils/number-format.d.ts +83 -0
- package/lib/utils/number-format.d.ts.map +1 -0
- package/lib/utils/number-format.js +143 -0
- package/lib/utils/number-format.js.map +1 -0
- package/lib/utils/parse-boolean.d.ts +39 -0
- package/lib/utils/parse-boolean.d.ts.map +1 -0
- package/lib/utils/parse-boolean.js +58 -0
- package/lib/utils/parse-boolean.js.map +1 -0
- package/lib/utils/positioning.d.ts +143 -0
- package/lib/utils/positioning.d.ts.map +1 -0
- package/lib/utils/positioning.js +308 -0
- package/lib/utils/positioning.js.map +1 -0
- package/lib/utils/property-capture.d.ts +132 -0
- package/lib/utils/property-capture.d.ts.map +1 -0
- package/lib/utils/property-capture.js +152 -0
- package/lib/utils/property-capture.js.map +1 -0
- package/lib/utils/property-manager.d.ts +90 -0
- package/lib/utils/property-manager.d.ts.map +1 -0
- package/lib/utils/property-manager.js +197 -0
- package/lib/utils/property-manager.js.map +1 -0
- package/lib/utils/resize-observer.d.ts +42 -0
- package/lib/utils/resize-observer.d.ts.map +1 -0
- package/lib/utils/resize-observer.js +71 -0
- package/lib/utils/resize-observer.js.map +1 -0
- package/lib/utils/scroll-lock.d.ts +79 -0
- package/lib/utils/scroll-lock.d.ts.map +1 -0
- package/lib/utils/scroll-lock.js +197 -0
- package/lib/utils/scroll-lock.js.map +1 -0
- package/lib/utils/styles.d.ts +27 -0
- package/lib/utils/styles.d.ts.map +1 -0
- package/lib/utils/styles.js +53 -0
- package/lib/utils/styles.js.map +1 -0
- package/lib/version.d.ts +8 -0
- package/lib/version.d.ts.map +1 -0
- package/lib/version.js +11 -0
- package/lib/version.js.map +1 -0
- package/package.json +163 -0
|
@@ -0,0 +1,498 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Button Component Styles
|
|
3
|
+
*
|
|
4
|
+
* Three appearance variants × six semantic flavors × three tones (+/base/-).
|
|
5
|
+
* Each variant uses ONE token system:
|
|
6
|
+
* - solid → --ty-solid-{flavor}-{strong|base|soft} (bg) + --ty-solid-{flavor}-fg (text)
|
|
7
|
+
* - outlined → --ty-color-{flavor}-{strong|base|soft} (text === border)
|
|
8
|
+
* - ghost → --ty-color-{flavor}-{strong|base|soft} (text), --ty-bg-{flavor}-soft (hover)
|
|
9
|
+
*
|
|
10
|
+
* Per-instance overrides via host CSS variables:
|
|
11
|
+
* --ty-button-bg, --ty-button-bg-hover, --ty-button-color, --ty-button-border
|
|
12
|
+
*/
|
|
13
|
+
export const buttonStyles = `
|
|
14
|
+
:host {
|
|
15
|
+
display: inline-block;
|
|
16
|
+
font-family: var(--ty-font-sans);
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
:host([wide]) {
|
|
20
|
+
display: flex;
|
|
21
|
+
flex-grow: 1;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
button {
|
|
25
|
+
position: relative;
|
|
26
|
+
display: flex;
|
|
27
|
+
align-items: center;
|
|
28
|
+
justify-content: center;
|
|
29
|
+
gap: var(--ty-spacing-1);
|
|
30
|
+
font-size: var(--ty-font-xs);
|
|
31
|
+
line-height: var(--ty-leading-xs);
|
|
32
|
+
letter-spacing: var(--ty-tracking-xs);
|
|
33
|
+
font-weight: var(--ty-font-medium);
|
|
34
|
+
white-space: nowrap;
|
|
35
|
+
cursor: pointer;
|
|
36
|
+
user-select: none;
|
|
37
|
+
transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
|
|
38
|
+
background: transparent;
|
|
39
|
+
color: var(--ty-color-neutral);
|
|
40
|
+
border: 1px solid transparent;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
button:not(.action) {
|
|
44
|
+
min-width: 4rem;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
button:not(.pill) {
|
|
48
|
+
border-radius: var(--ty-radius-md);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
button.xs:not(.pill) { border-radius: var(--ty-button-radius-xs, var(--ty-radius-md)); }
|
|
52
|
+
button.sm:not(.pill) { border-radius: var(--ty-button-radius-sm, var(--ty-radius-md)); }
|
|
53
|
+
button.md:not(.pill) { border-radius: var(--ty-button-radius-md, var(--ty-radius-md)); }
|
|
54
|
+
button.lg:not(.pill) { border-radius: var(--ty-button-radius-lg, var(--ty-radius-md)); }
|
|
55
|
+
button.xl:not(.pill) { border-radius: var(--ty-button-radius-xl, var(--ty-radius-md)); }
|
|
56
|
+
|
|
57
|
+
button:focus-visible {
|
|
58
|
+
outline: none;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
button:disabled {
|
|
62
|
+
cursor: not-allowed;
|
|
63
|
+
opacity: 0.6;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/* ===== LOADING STATE =====
|
|
67
|
+
Spinner overlays the button center; original content kept in flow but
|
|
68
|
+
hidden via visibility so width/height are preserved (no layout shift).
|
|
69
|
+
*/
|
|
70
|
+
.loader-icon {
|
|
71
|
+
display: none;
|
|
72
|
+
align-items: center;
|
|
73
|
+
justify-content: center;
|
|
74
|
+
flex-shrink: 0;
|
|
75
|
+
width: 1em;
|
|
76
|
+
height: 1em;
|
|
77
|
+
color: currentColor;
|
|
78
|
+
}
|
|
79
|
+
.loader-icon svg {
|
|
80
|
+
width: 100%;
|
|
81
|
+
height: 100%;
|
|
82
|
+
}
|
|
83
|
+
button.loading {
|
|
84
|
+
cursor: wait;
|
|
85
|
+
}
|
|
86
|
+
button.loading > *:not(.loader-icon) {
|
|
87
|
+
visibility: hidden;
|
|
88
|
+
}
|
|
89
|
+
button.loading > .loader-icon {
|
|
90
|
+
display: inline-flex;
|
|
91
|
+
position: absolute;
|
|
92
|
+
top: 50%;
|
|
93
|
+
left: 50%;
|
|
94
|
+
transform: translate(-50%, -50%);
|
|
95
|
+
animation: ty-button-spin 0.7s linear infinite;
|
|
96
|
+
}
|
|
97
|
+
@keyframes ty-button-spin {
|
|
98
|
+
to { transform: translate(-50%, -50%) rotate(360deg); }
|
|
99
|
+
}
|
|
100
|
+
@media (prefers-reduced-motion: reduce) {
|
|
101
|
+
button.loading > .loader-icon {
|
|
102
|
+
animation-duration: 1.6s;
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
::slotted(*) {
|
|
107
|
+
display: inline-flex;
|
|
108
|
+
align-items: center;
|
|
109
|
+
justify-content: center;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
::slotted(ty-icon) {
|
|
113
|
+
flex-shrink: 0;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
:host([wide]) button {
|
|
117
|
+
flex-grow: 1;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
/* ===== SIZES ===== */
|
|
121
|
+
|
|
122
|
+
button.xs {
|
|
123
|
+
padding: 0 var(--ty-spacing-2);
|
|
124
|
+
font-size: var(--ty-font-xs);
|
|
125
|
+
line-height: var(--ty-leading-xs);
|
|
126
|
+
letter-spacing: var(--ty-tracking-xs);
|
|
127
|
+
gap: var(--ty-spacing-1);
|
|
128
|
+
height: 1.375rem;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
button.sm {
|
|
132
|
+
padding: 0 var(--ty-spacing-2);
|
|
133
|
+
font-size: var(--ty-font-xs);
|
|
134
|
+
line-height: var(--ty-leading-xs);
|
|
135
|
+
letter-spacing: var(--ty-tracking-xs);
|
|
136
|
+
gap: var(--ty-spacing-1);
|
|
137
|
+
height: 1.5rem;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
button.md {
|
|
141
|
+
padding: 0.375rem var(--ty-spacing-3);
|
|
142
|
+
font-size: var(--ty-font-sm);
|
|
143
|
+
line-height: var(--ty-leading-sm);
|
|
144
|
+
letter-spacing: var(--ty-tracking-sm);
|
|
145
|
+
gap: var(--ty-spacing-2);
|
|
146
|
+
height: 1.8rem;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
button.lg {
|
|
150
|
+
padding: 0.375rem var(--ty-spacing-4);
|
|
151
|
+
font-size: var(--ty-font-sm);
|
|
152
|
+
line-height: var(--ty-leading-sm);
|
|
153
|
+
letter-spacing: var(--ty-tracking-sm);
|
|
154
|
+
gap: var(--ty-spacing-2);
|
|
155
|
+
height: 2.1rem;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
button.xl {
|
|
159
|
+
padding: var(--ty-spacing-2) var(--ty-spacing-6);
|
|
160
|
+
font-size: var(--ty-font-base);
|
|
161
|
+
line-height: var(--ty-leading-base);
|
|
162
|
+
letter-spacing: var(--ty-tracking-base);
|
|
163
|
+
gap: var(--ty-spacing-2);
|
|
164
|
+
height: 2.3rem;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
/* ===== ACTION (icon-only square) ===== */
|
|
168
|
+
|
|
169
|
+
button.action {
|
|
170
|
+
gap: 0px !important;
|
|
171
|
+
height: 2rem;
|
|
172
|
+
width: 2rem;
|
|
173
|
+
padding: 0px !important;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
button.action ::slotted(ty-icon) {
|
|
177
|
+
height: 1rem;
|
|
178
|
+
width: 1rem;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
button.action.xs { height: 1.375rem; width: 1.375rem; }
|
|
182
|
+
button.action.xs ::slotted(ty-icon) { height: 0.75rem; width: 0.75rem; }
|
|
183
|
+
|
|
184
|
+
button.action.sm { height: 1.5rem; width: 1.5rem; }
|
|
185
|
+
button.action.sm ::slotted(ty-icon) { height: 0.875rem; width: 0.875rem; }
|
|
186
|
+
|
|
187
|
+
button.action.lg { height: 2.25rem; width: 2.25rem; }
|
|
188
|
+
button.action.lg ::slotted(ty-icon) { height: 1.125rem; width: 1.125rem; }
|
|
189
|
+
|
|
190
|
+
button.action.xl { height: 2.5rem; width: 2.5rem; }
|
|
191
|
+
button.action.xl ::slotted(ty-icon) { height: 1.25rem; width: 1.25rem; }
|
|
192
|
+
|
|
193
|
+
/* ===== PILL ===== */
|
|
194
|
+
|
|
195
|
+
button.pill {
|
|
196
|
+
border-radius: 9999px;
|
|
197
|
+
padding-left: 1.25em;
|
|
198
|
+
padding-right: 1.25em;
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
button.pill.xs { padding-left: 1em; padding-right: 1em; }
|
|
202
|
+
button.pill.sm { padding-left: 1.125em; padding-right: 1.125em; }
|
|
203
|
+
button.pill.lg { padding-left: 1.5em; padding-right: 1.5em; }
|
|
204
|
+
button.pill.xl { padding-left: 1.75em; padding-right: 1.75em; }
|
|
205
|
+
|
|
206
|
+
button.pill:has(ty-icon:only-child),
|
|
207
|
+
button.pill:has(slot[name="start"]:only-child),
|
|
208
|
+
button.pill:has(slot[name="end"]:only-child) {
|
|
209
|
+
padding: 0;
|
|
210
|
+
aspect-ratio: 1;
|
|
211
|
+
min-width: var(--ty-size-md);
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
button.pill.xs:has(ty-icon:only-child) { min-width: 1.375rem; min-height: 1.375rem; }
|
|
215
|
+
button.pill.sm:has(ty-icon:only-child) { min-width: 1.5rem; min-height: 1.5rem; }
|
|
216
|
+
button.pill.md:has(ty-icon:only-child) { min-width: 2rem; min-height: 2rem; }
|
|
217
|
+
button.pill.lg:has(ty-icon:only-child) { min-width: 2.25rem; min-height: 2.25rem; }
|
|
218
|
+
button.pill.xl:has(ty-icon:only-child) { min-width: 2.5rem; min-height: 2.5rem; }
|
|
219
|
+
|
|
220
|
+
/* ============================================================
|
|
221
|
+
SOLID — saturated brand fill (uses --ty-solid-{flavor}-* tokens)
|
|
222
|
+
Bare .solid rule = fallback for custom flavors (theme via --ty-button-*).
|
|
223
|
+
============================================================ */
|
|
224
|
+
|
|
225
|
+
button.solid {
|
|
226
|
+
border: none;
|
|
227
|
+
background: var(--ty-button-bg, var(--ty-solid-neutral));
|
|
228
|
+
color: var(--ty-button-color, var(--ty-solid-neutral-fg));
|
|
229
|
+
}
|
|
230
|
+
button.solid:hover:not(:disabled) {
|
|
231
|
+
background: var(--ty-button-bg-hover, var(--ty-button-bg, var(--ty-solid-neutral-strong)));
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
/* Primary */
|
|
235
|
+
button.solid.primary {
|
|
236
|
+
background: var(--ty-button-bg, var(--ty-solid-primary));
|
|
237
|
+
color: var(--ty-button-color, var(--ty-solid-primary-fg));
|
|
238
|
+
}
|
|
239
|
+
button.solid.primary.tone-plus { background: var(--ty-button-bg, var(--ty-solid-primary-strong)); }
|
|
240
|
+
button.solid.primary.tone-minus { background: var(--ty-button-bg, var(--ty-solid-primary-soft)); }
|
|
241
|
+
button.solid.primary:hover:not(:disabled) {
|
|
242
|
+
background: var(--ty-button-bg-hover, var(--ty-solid-primary-strong));
|
|
243
|
+
}
|
|
244
|
+
button.solid.primary:focus-visible {
|
|
245
|
+
box-shadow: 0 0 0 2px var(--ty-focus-ring-gap), 0 0 0 4px var(--ty-color-primary);
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
/* Secondary */
|
|
249
|
+
button.solid.secondary {
|
|
250
|
+
background: var(--ty-button-bg, var(--ty-solid-secondary));
|
|
251
|
+
color: var(--ty-button-color, var(--ty-solid-secondary-fg));
|
|
252
|
+
}
|
|
253
|
+
button.solid.secondary.tone-plus { background: var(--ty-button-bg, var(--ty-solid-secondary-strong)); }
|
|
254
|
+
button.solid.secondary.tone-minus { background: var(--ty-button-bg, var(--ty-solid-secondary-soft)); }
|
|
255
|
+
button.solid.secondary:hover:not(:disabled) {
|
|
256
|
+
background: var(--ty-button-bg-hover, var(--ty-solid-secondary-strong));
|
|
257
|
+
}
|
|
258
|
+
button.solid.secondary:focus-visible {
|
|
259
|
+
box-shadow: 0 0 0 2px var(--ty-focus-ring-gap), 0 0 0 4px var(--ty-color-secondary);
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
/* Success */
|
|
263
|
+
button.solid.success {
|
|
264
|
+
background: var(--ty-button-bg, var(--ty-solid-success));
|
|
265
|
+
color: var(--ty-button-color, var(--ty-solid-success-fg));
|
|
266
|
+
}
|
|
267
|
+
button.solid.success.tone-plus { background: var(--ty-button-bg, var(--ty-solid-success-strong)); }
|
|
268
|
+
button.solid.success.tone-minus { background: var(--ty-button-bg, var(--ty-solid-success-soft)); }
|
|
269
|
+
button.solid.success:hover:not(:disabled) {
|
|
270
|
+
background: var(--ty-button-bg-hover, var(--ty-solid-success-strong));
|
|
271
|
+
}
|
|
272
|
+
button.solid.success:focus-visible {
|
|
273
|
+
box-shadow: 0 0 0 2px var(--ty-focus-ring-gap), 0 0 0 4px var(--ty-color-success);
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
/* Danger */
|
|
277
|
+
button.solid.danger {
|
|
278
|
+
background: var(--ty-button-bg, var(--ty-solid-danger));
|
|
279
|
+
color: var(--ty-button-color, var(--ty-solid-danger-fg));
|
|
280
|
+
}
|
|
281
|
+
button.solid.danger.tone-plus { background: var(--ty-button-bg, var(--ty-solid-danger-strong)); }
|
|
282
|
+
button.solid.danger.tone-minus { background: var(--ty-button-bg, var(--ty-solid-danger-soft)); }
|
|
283
|
+
button.solid.danger:hover:not(:disabled) {
|
|
284
|
+
background: var(--ty-button-bg-hover, var(--ty-solid-danger-strong));
|
|
285
|
+
}
|
|
286
|
+
button.solid.danger:focus-visible {
|
|
287
|
+
box-shadow: 0 0 0 2px var(--ty-focus-ring-gap), 0 0 0 4px var(--ty-color-danger);
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
/* Warning */
|
|
291
|
+
button.solid.warning {
|
|
292
|
+
background: var(--ty-button-bg, var(--ty-solid-warning));
|
|
293
|
+
color: var(--ty-button-color, var(--ty-solid-warning-fg));
|
|
294
|
+
}
|
|
295
|
+
button.solid.warning.tone-plus { background: var(--ty-button-bg, var(--ty-solid-warning-strong)); }
|
|
296
|
+
button.solid.warning.tone-minus { background: var(--ty-button-bg, var(--ty-solid-warning-soft)); }
|
|
297
|
+
button.solid.warning:hover:not(:disabled) {
|
|
298
|
+
background: var(--ty-button-bg-hover, var(--ty-solid-warning-strong));
|
|
299
|
+
}
|
|
300
|
+
button.solid.warning:focus-visible {
|
|
301
|
+
box-shadow: 0 0 0 2px var(--ty-focus-ring-gap), 0 0 0 4px var(--ty-color-warning);
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
/* Neutral */
|
|
305
|
+
button.solid.neutral {
|
|
306
|
+
background: var(--ty-button-bg, var(--ty-solid-neutral));
|
|
307
|
+
color: var(--ty-button-color, var(--ty-solid-neutral-fg));
|
|
308
|
+
}
|
|
309
|
+
button.solid.neutral.tone-plus { background: var(--ty-button-bg, var(--ty-solid-neutral-strong)); }
|
|
310
|
+
button.solid.neutral.tone-minus { background: var(--ty-button-bg, var(--ty-solid-neutral-soft)); }
|
|
311
|
+
button.solid.neutral:hover:not(:disabled) {
|
|
312
|
+
background: var(--ty-button-bg-hover, var(--ty-solid-neutral-strong));
|
|
313
|
+
}
|
|
314
|
+
button.solid.neutral:focus-visible {
|
|
315
|
+
box-shadow: 0 0 0 2px var(--ty-focus-ring-gap), 0 0 0 4px var(--ty-color-neutral);
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
/* ============================================================
|
|
319
|
+
OUTLINED — transparent bg, text === border (uses --ty-color-*)
|
|
320
|
+
Bare .outlined rule = fallback for custom flavors. For outlined,
|
|
321
|
+
text is bound to border color (the rule "text === border"), so the
|
|
322
|
+
fallback chain prefers --ty-button-border, then --ty-button-color.
|
|
323
|
+
============================================================ */
|
|
324
|
+
|
|
325
|
+
button.outlined {
|
|
326
|
+
background: transparent;
|
|
327
|
+
color: var(--ty-button-border, var(--ty-button-color, var(--ty-color-neutral)));
|
|
328
|
+
border-color: var(--ty-button-border, var(--ty-button-color, var(--ty-color-neutral)));
|
|
329
|
+
}
|
|
330
|
+
button.outlined:hover:not(:disabled) {
|
|
331
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-neutral-soft));
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
/* Primary */
|
|
335
|
+
button.outlined.primary {
|
|
336
|
+
color: var(--ty-button-color, var(--ty-color-primary));
|
|
337
|
+
border-color: var(--ty-button-border, var(--ty-color-primary));
|
|
338
|
+
}
|
|
339
|
+
button.outlined.primary.tone-plus {
|
|
340
|
+
color: var(--ty-button-color, var(--ty-color-primary-strong));
|
|
341
|
+
border-color: var(--ty-button-border, var(--ty-color-primary-strong));
|
|
342
|
+
}
|
|
343
|
+
button.outlined.primary.tone-minus {
|
|
344
|
+
color: var(--ty-button-color, var(--ty-color-primary-soft));
|
|
345
|
+
border-color: var(--ty-button-border, var(--ty-color-primary-soft));
|
|
346
|
+
}
|
|
347
|
+
button.outlined.primary:hover:not(:disabled) {
|
|
348
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-primary-soft));
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
/* Secondary */
|
|
352
|
+
button.outlined.secondary {
|
|
353
|
+
color: var(--ty-button-color, var(--ty-color-secondary));
|
|
354
|
+
border-color: var(--ty-button-border, var(--ty-color-secondary));
|
|
355
|
+
}
|
|
356
|
+
button.outlined.secondary.tone-plus {
|
|
357
|
+
color: var(--ty-button-color, var(--ty-color-secondary-strong));
|
|
358
|
+
border-color: var(--ty-button-border, var(--ty-color-secondary-strong));
|
|
359
|
+
}
|
|
360
|
+
button.outlined.secondary.tone-minus {
|
|
361
|
+
color: var(--ty-button-color, var(--ty-color-secondary-soft));
|
|
362
|
+
border-color: var(--ty-button-border, var(--ty-color-secondary-soft));
|
|
363
|
+
}
|
|
364
|
+
button.outlined.secondary:hover:not(:disabled) {
|
|
365
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-secondary-soft));
|
|
366
|
+
}
|
|
367
|
+
|
|
368
|
+
/* Success */
|
|
369
|
+
button.outlined.success {
|
|
370
|
+
color: var(--ty-button-color, var(--ty-color-success));
|
|
371
|
+
border-color: var(--ty-button-border, var(--ty-color-success));
|
|
372
|
+
}
|
|
373
|
+
button.outlined.success.tone-plus {
|
|
374
|
+
color: var(--ty-button-color, var(--ty-color-success-strong));
|
|
375
|
+
border-color: var(--ty-button-border, var(--ty-color-success-strong));
|
|
376
|
+
}
|
|
377
|
+
button.outlined.success.tone-minus {
|
|
378
|
+
color: var(--ty-button-color, var(--ty-color-success-soft));
|
|
379
|
+
border-color: var(--ty-button-border, var(--ty-color-success-soft));
|
|
380
|
+
}
|
|
381
|
+
button.outlined.success:hover:not(:disabled) {
|
|
382
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-success-soft));
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
/* Danger */
|
|
386
|
+
button.outlined.danger {
|
|
387
|
+
color: var(--ty-button-color, var(--ty-color-danger));
|
|
388
|
+
border-color: var(--ty-button-border, var(--ty-color-danger));
|
|
389
|
+
}
|
|
390
|
+
button.outlined.danger.tone-plus {
|
|
391
|
+
color: var(--ty-button-color, var(--ty-color-danger-strong));
|
|
392
|
+
border-color: var(--ty-button-border, var(--ty-color-danger-strong));
|
|
393
|
+
}
|
|
394
|
+
button.outlined.danger.tone-minus {
|
|
395
|
+
color: var(--ty-button-color, var(--ty-color-danger-soft));
|
|
396
|
+
border-color: var(--ty-button-border, var(--ty-color-danger-soft));
|
|
397
|
+
}
|
|
398
|
+
button.outlined.danger:hover:not(:disabled) {
|
|
399
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-danger-soft));
|
|
400
|
+
}
|
|
401
|
+
|
|
402
|
+
/* Warning */
|
|
403
|
+
button.outlined.warning {
|
|
404
|
+
color: var(--ty-button-color, var(--ty-color-warning));
|
|
405
|
+
border-color: var(--ty-button-border, var(--ty-color-warning));
|
|
406
|
+
}
|
|
407
|
+
button.outlined.warning.tone-plus {
|
|
408
|
+
color: var(--ty-button-color, var(--ty-color-warning-strong));
|
|
409
|
+
border-color: var(--ty-button-border, var(--ty-color-warning-strong));
|
|
410
|
+
}
|
|
411
|
+
button.outlined.warning.tone-minus {
|
|
412
|
+
color: var(--ty-button-color, var(--ty-color-warning-soft));
|
|
413
|
+
border-color: var(--ty-button-border, var(--ty-color-warning-soft));
|
|
414
|
+
}
|
|
415
|
+
button.outlined.warning:hover:not(:disabled) {
|
|
416
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-warning-soft));
|
|
417
|
+
}
|
|
418
|
+
|
|
419
|
+
/* Neutral */
|
|
420
|
+
button.outlined.neutral {
|
|
421
|
+
color: var(--ty-button-color, var(--ty-color-neutral));
|
|
422
|
+
border-color: var(--ty-button-border, var(--ty-color-neutral));
|
|
423
|
+
}
|
|
424
|
+
button.outlined.neutral.tone-plus {
|
|
425
|
+
color: var(--ty-button-color, var(--ty-color-neutral-strong));
|
|
426
|
+
border-color: var(--ty-button-border, var(--ty-color-neutral-strong));
|
|
427
|
+
}
|
|
428
|
+
button.outlined.neutral.tone-minus {
|
|
429
|
+
color: var(--ty-button-color, var(--ty-color-neutral-soft));
|
|
430
|
+
border-color: var(--ty-button-border, var(--ty-color-neutral-soft));
|
|
431
|
+
}
|
|
432
|
+
button.outlined.neutral:hover:not(:disabled) {
|
|
433
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-neutral-soft));
|
|
434
|
+
}
|
|
435
|
+
|
|
436
|
+
/* ============================================================
|
|
437
|
+
GHOST — text only, hover bg (uses --ty-color-* + --ty-bg-*-soft)
|
|
438
|
+
Bare .ghost rule = fallback for custom flavors.
|
|
439
|
+
============================================================ */
|
|
440
|
+
|
|
441
|
+
button.ghost {
|
|
442
|
+
background: transparent;
|
|
443
|
+
border: none;
|
|
444
|
+
color: var(--ty-button-color, var(--ty-color-neutral));
|
|
445
|
+
}
|
|
446
|
+
button.ghost:hover:not(:disabled) {
|
|
447
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-neutral-soft));
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
/* Primary */
|
|
451
|
+
button.ghost.primary { color: var(--ty-button-color, var(--ty-color-primary)); }
|
|
452
|
+
button.ghost.primary.tone-plus { color: var(--ty-button-color, var(--ty-color-primary-strong)); }
|
|
453
|
+
button.ghost.primary.tone-minus { color: var(--ty-button-color, var(--ty-color-primary-soft)); }
|
|
454
|
+
button.ghost.primary:hover:not(:disabled) {
|
|
455
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-primary-soft));
|
|
456
|
+
}
|
|
457
|
+
|
|
458
|
+
/* Secondary */
|
|
459
|
+
button.ghost.secondary { color: var(--ty-button-color, var(--ty-color-secondary)); }
|
|
460
|
+
button.ghost.secondary.tone-plus { color: var(--ty-button-color, var(--ty-color-secondary-strong)); }
|
|
461
|
+
button.ghost.secondary.tone-minus { color: var(--ty-button-color, var(--ty-color-secondary-soft)); }
|
|
462
|
+
button.ghost.secondary:hover:not(:disabled) {
|
|
463
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-secondary-soft));
|
|
464
|
+
}
|
|
465
|
+
|
|
466
|
+
/* Success */
|
|
467
|
+
button.ghost.success { color: var(--ty-button-color, var(--ty-color-success)); }
|
|
468
|
+
button.ghost.success.tone-plus { color: var(--ty-button-color, var(--ty-color-success-strong)); }
|
|
469
|
+
button.ghost.success.tone-minus { color: var(--ty-button-color, var(--ty-color-success-soft)); }
|
|
470
|
+
button.ghost.success:hover:not(:disabled) {
|
|
471
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-success-soft));
|
|
472
|
+
}
|
|
473
|
+
|
|
474
|
+
/* Danger */
|
|
475
|
+
button.ghost.danger { color: var(--ty-button-color, var(--ty-color-danger)); }
|
|
476
|
+
button.ghost.danger.tone-plus { color: var(--ty-button-color, var(--ty-color-danger-strong)); }
|
|
477
|
+
button.ghost.danger.tone-minus { color: var(--ty-button-color, var(--ty-color-danger-soft)); }
|
|
478
|
+
button.ghost.danger:hover:not(:disabled) {
|
|
479
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-danger-soft));
|
|
480
|
+
}
|
|
481
|
+
|
|
482
|
+
/* Warning */
|
|
483
|
+
button.ghost.warning { color: var(--ty-button-color, var(--ty-color-warning)); }
|
|
484
|
+
button.ghost.warning.tone-plus { color: var(--ty-button-color, var(--ty-color-warning-strong)); }
|
|
485
|
+
button.ghost.warning.tone-minus { color: var(--ty-button-color, var(--ty-color-warning-soft)); }
|
|
486
|
+
button.ghost.warning:hover:not(:disabled) {
|
|
487
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-warning-soft));
|
|
488
|
+
}
|
|
489
|
+
|
|
490
|
+
/* Neutral */
|
|
491
|
+
button.ghost.neutral { color: var(--ty-button-color, var(--ty-color-neutral)); }
|
|
492
|
+
button.ghost.neutral.tone-plus { color: var(--ty-button-color, var(--ty-color-neutral-strong)); }
|
|
493
|
+
button.ghost.neutral.tone-minus { color: var(--ty-button-color, var(--ty-color-neutral-soft)); }
|
|
494
|
+
button.ghost.neutral:hover:not(:disabled) {
|
|
495
|
+
background: var(--ty-button-bg-hover, var(--ty-bg-neutral-soft));
|
|
496
|
+
}
|
|
497
|
+
`;
|
|
498
|
+
//# sourceMappingURL=button.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"button.js","sourceRoot":"","sources":["../../src/styles/button.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,MAAM,CAAC,MAAM,YAAY,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAoe3B,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Calendar Month Styles
|
|
3
|
+
* Improved design with better visual hierarchy and size variants
|
|
4
|
+
*/
|
|
5
|
+
export declare const calendarMonthStyles = "\n/* ============================================================================\n Theming Tokens\n Override these to retheme the calendar without touching the global palette.\n Defaults chain back to the global --ty-color-* / --ty-bg-* / --ty-border tokens.\n ============================================================================ */\n\n:host {\n /* Accent aliases \u2014 override these three for thin retheming */\n --ty-calendar-accent: var(--ty-color-primary);\n --ty-calendar-today-accent: var(--ty-color-secondary);\n --ty-calendar-muted: var(--ty-color-neutral);\n\n /* Header (weekday names) */\n --ty-calendar-header-color: var(--ty-color-neutral-strong);\n\n /* Day cell \u2014 base */\n --ty-calendar-day-color: var(--ty-calendar-muted);\n --ty-calendar-day-bg: transparent;\n --ty-calendar-day-border: var(--ty-border);\n --ty-calendar-day-radius: 0.375rem;\n\n /* Day cell \u2014 hover */\n --ty-calendar-day-hover-color: var(--ty-color-neutral-strong);\n --ty-calendar-day-hover-bg: var(--ty-bg-neutral-soft);\n --ty-calendar-day-hover-border: var(--ty-border-bold);\n\n /* Today */\n --ty-calendar-today-color: var(--ty-color-secondary-strong);\n --ty-calendar-today-bg: var(--ty-bg-secondary-soft);\n --ty-calendar-today-border: var(--ty-calendar-today-accent);\n\n /* Selected */\n --ty-calendar-selected-color: var(--ty-color-primary-strong);\n --ty-calendar-selected-bg: var(--ty-bg-primary);\n --ty-calendar-selected-border: var(--ty-calendar-accent);\n --ty-calendar-selected-hover-bg: var(--ty-bg-primary-bold);\n --ty-calendar-selected-hover-border: var(--ty-color-primary-bold);\n\n /* Modifier states */\n --ty-calendar-weekend-color: var(--ty-color-danger-soft);\n --ty-calendar-other-month-color: var(--ty-color-neutral-faint);\n --ty-calendar-other-month-opacity: 0.5;\n}\n\n/* ============================================================================\n Base Calendar Container\n ============================================================================ */\n\n.calendar-flex-container {\n display: flex;\n flex-direction: column;\n box-sizing: border-box;\n gap: 0;\n padding: 0.75rem;\n border-radius: 0.5rem;\n font-family: system-ui, sans-serif;\n user-select: none;\n width: var(--calendar-width, fit-content);\n min-width: 280px;\n max-width: var(--calendar-max-width, none);\n}\n\n/* ============================================================================\n Rows (Header + 6 Day Rows)\n ============================================================================ */\n\n.calendar-row {\n display: flex;\n flex: 1;\n min-height: 0;\n}\n\n.calendar-header-row {\n flex: 0 0 auto;\n color: var(--ty-calendar-header-color);\n}\n\n.calendar-day-row {\n flex: 1;\n min-height: 2rem;\n margin-bottom: 0.125rem;\n}\n\n/* ============================================================================\n Base Cell Styles\n ============================================================================ */\n\n.calendar-cell {\n flex: 1;\n display: flex;\n align-items: center;\n justify-content: center;\n min-width: 0;\n position: relative;\n box-sizing: border-box;\n}\n\n/* ============================================================================\n Header Cells\n ============================================================================ */\n\n.calendar-header-cell {\n text-align: center;\n font-weight: 600;\n text-transform: uppercase;\n padding: 0.25rem;\n letter-spacing: 0.05em;\n}\n\n/* ============================================================================\n Day Cells - Square with Better Visual Hierarchy\n ============================================================================ */\n\n.calendar-day-cell {\n /* Square cells */\n aspect-ratio: 1;\n\n /* Layout */\n display: flex;\n align-items: center;\n justify-content: center;\n flex-direction: column;\n\n /* Spacing */\n margin: 0.125rem;\n\n /* Visual */\n border-radius: var(--ty-calendar-day-radius);\n border: 1px solid var(--ty-calendar-day-border);\n background-color: var(--ty-calendar-day-bg);\n color: var(--ty-calendar-day-color);\n cursor: pointer;\n transition: all 0.15s ease;\n\n /* Typography */\n font-weight: 400;\n}\n\n/* Hover State - Stronger Feedback */\n.calendar-day-cell:hover {\n color: var(--ty-calendar-day-hover-color);\n background-color: var(--ty-calendar-day-hover-bg);\n border-color: var(--ty-calendar-day-hover-border);\n}\n\n/* ============================================================================\n Day States\n ============================================================================ */\n\n/* Today - Strong Visual Indicator */\n.calendar-day-cell.today {\n background-color: var(--ty-calendar-today-bg);\n color: var(--ty-calendar-today-color);\n border-color: var(--ty-calendar-today-border);\n font-weight: 600;\n}\n\n/* Weekend - Subtle Color Shift */\n.calendar-day-cell.weekend {\n color: var(--ty-calendar-weekend-color);\n}\n\n/* Other Month - Muted */\n.calendar-day-cell.other-month {\n color: var(--ty-calendar-other-month-color);\n opacity: var(--ty-calendar-other-month-opacity);\n}\n\n.calendar-day-cell.other-month:hover { \n color: var(--ty-calendar-day-hover-color);\n background-color: var(--ty-calendar-day-hover-bg);\n opacity: 0.7;\n}\n\n/* Selected State (for custom usage) */\n.calendar-day-cell.selected {\n background-color: var(--ty-calendar-selected-bg);\n color: var(--ty-calendar-selected-color);\n border-color: var(--ty-calendar-selected-border);\n font-weight: 600;\n}\n\n.calendar-day-cell.selected:hover {\n background-color: var(--ty-calendar-selected-hover-bg);\n border-color: var(--ty-calendar-selected-hover-border);\n}\n\n.calendar-day-cell.selected.other-month {\n opacity: 0.7;\n}\n\n/* ============================================================================\n Size Variants\n ============================================================================ */\n\n/* Small - Compact (240px min-width) */\n.calendar-size-sm {\n padding: 0.5rem;\n min-width: 240px;\n}\n\n.calendar-size-sm .calendar-header-cell {\n font-size: 0.625rem;\n padding: 0.125rem;\n}\n\n.calendar-size-sm .calendar-day-cell {\n font-size: 0.75rem;\n margin: 0.0625rem;\n}\n\n.calendar-size-sm .calendar-day-row {\n min-height: 1.5rem;\n}\n\n/* Medium - Default (280px min-width) */\n.calendar-size-md {\n padding: 0.75rem;\n min-width: 280px;\n}\n\n.calendar-size-md .calendar-header-cell {\n font-size: 0.6875rem;\n padding: 0.25rem;\n}\n\n.calendar-size-md .calendar-day-cell {\n font-size: 0.8125rem;\n margin: 0.125rem;\n}\n\n.calendar-size-md .calendar-day-row {\n min-height: 2rem;\n}\n\n/* Large - Spacious (360px min-width) */\n.calendar-size-lg {\n padding: 1rem;\n min-width: 360px;\n}\n\n.calendar-size-lg .calendar-header-cell {\n font-size: 0.75rem;\n padding: 0.375rem;\n}\n\n.calendar-size-lg .calendar-day-cell {\n font-size: 0.875rem;\n margin: 0.1875rem;\n}\n\n.calendar-size-lg .calendar-day-row {\n min-height: 2.5rem;\n}\n\n/* ============================================================================\n Backwards Compatibility\n ============================================================================ */\n\n.calendar-day {\n width: 100%;\n height: 100%;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n}\n";
|
|
6
|
+
//# sourceMappingURL=calendar-month.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"calendar-month.d.ts","sourceRoot":"","sources":["../../src/styles/calendar-month.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,eAAO,MAAM,mBAAmB,0yOA6Q/B,CAAC"}
|