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
|
@@ -1,8 +1,4 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Calendar Month Styles
|
|
3
|
-
* Improved design with better visual hierarchy and size variants
|
|
4
|
-
*/
|
|
1
|
+
/** Calendar Month Styles */
|
|
5
2
|
/** Rules for one custom (non-built-in) flavor — see utils/flavor-sheet.ts. */
|
|
6
3
|
export declare const calendarMonthCustomFlavorCss: (base: string) => string;
|
|
7
4
|
export declare const calendarMonthStyles: string;
|
|
8
|
-
//# sourceMappingURL=calendar-month.d.ts.map
|
|
@@ -1,308 +1,191 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Calendar Month Styles
|
|
3
|
-
* Improved design with better visual hierarchy and size variants
|
|
4
|
-
*/
|
|
5
1
|
import { FLAVORS } from "../types/common.js";
|
|
6
|
-
/* Flavor rules set --calendar-month-* local vars, wired in as the fallback
|
|
7
|
-
BEHIND every existing --ty-calendar-* public override (so those keep
|
|
8
|
-
working exactly as before) and AHEAD of the hardcoded primary default.
|
|
9
|
-
Doubles as the per-instance override API for a specific flavor: e.g.
|
|
10
|
-
`ty-calendar-month { --calendar-month-accent: ... }`. Fallback flavor
|
|
11
|
-
`fb` is used for custom flavors so missing tokens degrade to neutral. */
|
|
12
2
|
const calendarMonthFlavor = (f, fb) => {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
3
|
+
const color = (s) => fb
|
|
4
|
+
? `var(--ty-color-${f}${s}, var(--ty-color-${fb}${s}))`
|
|
5
|
+
: `var(--ty-color-${f}${s})`;
|
|
6
|
+
const bg = (s) => fb
|
|
7
|
+
? `var(--ty-bg-${f}${s}, var(--ty-bg-${fb}${s}))`
|
|
8
|
+
: `var(--ty-bg-${f}${s})`;
|
|
9
|
+
return `
|
|
20
10
|
:host([flavor="${f}"]) {
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
11
|
+
--calendar-month-accent: ${color("")};
|
|
12
|
+
--calendar-month-selected-bg: ${bg("")};
|
|
13
|
+
--calendar-month-selected-color: ${color("-strong")};
|
|
14
|
+
--calendar-month-selected-hover-bg: ${bg("-bold")};
|
|
25
15
|
}
|
|
26
16
|
:host([flavor="${f}+"]) {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
17
|
+
--calendar-month-accent: ${color("-strong")};
|
|
18
|
+
--calendar-month-selected-bg: ${bg("-bold")};
|
|
19
|
+
--calendar-month-selected-color: ${color("-strong")};
|
|
20
|
+
--calendar-month-selected-hover-bg: ${bg("-bold")};
|
|
31
21
|
}
|
|
32
22
|
:host([flavor="${f}-"]) {
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
23
|
+
--calendar-month-accent: ${color("-soft")};
|
|
24
|
+
--calendar-month-selected-bg: ${bg("-soft")};
|
|
25
|
+
--calendar-month-selected-color: ${color("")};
|
|
26
|
+
--calendar-month-selected-hover-bg: ${bg("")};
|
|
37
27
|
}
|
|
38
28
|
`;
|
|
39
29
|
};
|
|
40
|
-
/** Rules for one custom (non-built-in) flavor — see utils/flavor-sheet.ts. */
|
|
41
30
|
export const calendarMonthCustomFlavorCss = (base) => calendarMonthFlavor(base, "neutral");
|
|
42
31
|
export const calendarMonthStyles = `
|
|
43
|
-
/* ============================================================================
|
|
44
|
-
Theming Tokens
|
|
45
|
-
Override these to retheme the calendar without touching the global palette.
|
|
46
|
-
Defaults chain back to the global --ty-color-* / --ty-bg-* / --ty-border tokens.
|
|
47
|
-
============================================================================ */
|
|
48
|
-
|
|
49
|
-
/* Theming tokens are applied as var(--ty-calendar-*, <default>) at point
|
|
50
|
-
of use (not declared on :host) so consumers can override any of them
|
|
51
|
-
from outside the shadow root. The 3 accent aliases — --ty-calendar-accent,
|
|
52
|
-
--ty-calendar-today-accent, --ty-calendar-muted — still cascade into the
|
|
53
|
-
derived defaults, so overriding one retints the related cells. */
|
|
54
|
-
|
|
55
|
-
/* ============================================================================
|
|
56
|
-
Base Calendar Container
|
|
57
|
-
============================================================================ */
|
|
58
|
-
|
|
59
32
|
.calendar-flex-container {
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
/* ============================================================================
|
|
74
|
-
Rows (Header + 6 Day Rows)
|
|
75
|
-
============================================================================ */
|
|
76
|
-
|
|
33
|
+
display: flex;
|
|
34
|
+
flex-direction: column;
|
|
35
|
+
box-sizing: border-box;
|
|
36
|
+
gap: 0;
|
|
37
|
+
padding: 0.75rem;
|
|
38
|
+
border-radius: var(--ty-radius-md);
|
|
39
|
+
font-family: inherit;
|
|
40
|
+
user-select: none;
|
|
41
|
+
width: var(--calendar-width, fit-content);
|
|
42
|
+
min-width: var(--ty-calendar-width, 280px);
|
|
43
|
+
max-width: var(--calendar-max-width, none);
|
|
44
|
+
}
|
|
77
45
|
.calendar-row {
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
46
|
+
display: flex;
|
|
47
|
+
flex: 1;
|
|
48
|
+
min-height: 0;
|
|
81
49
|
}
|
|
82
|
-
|
|
83
50
|
.calendar-header-row {
|
|
84
|
-
|
|
85
|
-
|
|
51
|
+
flex: 0 0 auto;
|
|
52
|
+
color: var(--ty-calendar-header-color, var(--ty-color-neutral-soft));
|
|
86
53
|
}
|
|
87
|
-
|
|
88
54
|
.calendar-day-row {
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
/* ============================================================================
|
|
95
|
-
Base Cell Styles
|
|
96
|
-
============================================================================ */
|
|
97
|
-
|
|
55
|
+
flex: 1;
|
|
56
|
+
min-height: 2rem;
|
|
57
|
+
margin-bottom: 0.125rem;
|
|
58
|
+
}
|
|
98
59
|
.calendar-cell {
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
/* ============================================================================
|
|
109
|
-
Header Cells
|
|
110
|
-
============================================================================ */
|
|
111
|
-
|
|
60
|
+
flex: 1;
|
|
61
|
+
display: flex;
|
|
62
|
+
align-items: center;
|
|
63
|
+
justify-content: center;
|
|
64
|
+
min-width: 0;
|
|
65
|
+
position: relative;
|
|
66
|
+
box-sizing: border-box;
|
|
67
|
+
}
|
|
112
68
|
.calendar-header-cell {
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
/* ============================================================================
|
|
121
|
-
Day Cells - Square with Better Visual Hierarchy
|
|
122
|
-
============================================================================ */
|
|
123
|
-
|
|
69
|
+
text-align: center;
|
|
70
|
+
font-weight: 500;
|
|
71
|
+
text-transform: uppercase;
|
|
72
|
+
padding: 0.25rem;
|
|
73
|
+
letter-spacing: 0.05em;
|
|
74
|
+
}
|
|
124
75
|
.calendar-day-cell {
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
background-color: var(--ty-calendar-day-bg, transparent);
|
|
141
|
-
color: var(--ty-calendar-day-color, var(--ty-calendar-muted, var(--ty-text)));
|
|
142
|
-
cursor: pointer;
|
|
143
|
-
transition: var(--ty-local-transition, background-color 0.15s ease, color 0.15s ease);
|
|
144
|
-
|
|
145
|
-
/* Typography */
|
|
146
|
-
font-weight: 400;
|
|
147
|
-
font-variant-numeric: tabular-nums;
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
/* Hover: soft rounded pill, no border flash */
|
|
76
|
+
aspect-ratio: 1;
|
|
77
|
+
display: flex;
|
|
78
|
+
align-items: center;
|
|
79
|
+
justify-content: center;
|
|
80
|
+
flex-direction: column;
|
|
81
|
+
margin: 0.125rem;
|
|
82
|
+
border-radius: var(--ty-calendar-day-radius, 0.5rem);
|
|
83
|
+
border: 1px solid var(--ty-calendar-day-border, transparent);
|
|
84
|
+
background-color: var(--ty-calendar-day-bg, transparent);
|
|
85
|
+
color: var(--ty-calendar-day-color, var(--ty-calendar-muted, var(--ty-text)));
|
|
86
|
+
cursor: pointer;
|
|
87
|
+
transition: var(--ty-local-transition, background-color 0.15s ease, color 0.15s ease);
|
|
88
|
+
font-weight: 400;
|
|
89
|
+
font-variant-numeric: tabular-nums;
|
|
90
|
+
}
|
|
151
91
|
.calendar-day-cell:hover {
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
}
|
|
156
|
-
|
|
157
|
-
/* Keyboard focus ring (roving tabindex — see calendar-month.ts's render()).
|
|
158
|
-
:focus-visible, not :focus, so mouse/pointerdown activation doesn't flash
|
|
159
|
-
a ring; only Tab-in / arrow-key navigation does. */
|
|
92
|
+
color: var(--ty-calendar-day-hover-color, var(--ty-text-strong));
|
|
93
|
+
background-color: var(--ty-calendar-day-hover-bg, var(--ty-bg-neutral-soft));
|
|
94
|
+
border-color: var(--ty-calendar-day-hover-border, transparent);
|
|
95
|
+
}
|
|
160
96
|
.calendar-day-cell:focus-visible {
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
}
|
|
164
|
-
|
|
165
|
-
/* ============================================================================
|
|
166
|
-
Day States
|
|
167
|
-
============================================================================ */
|
|
168
|
-
|
|
169
|
-
/* Today: accent number, no slab — never collides with hover, and the
|
|
170
|
-
selected pill wins when today is picked */
|
|
97
|
+
outline: none;
|
|
98
|
+
box-shadow: 0 0 0 2px var(--calendar-month-accent, var(--ty-color-primary));
|
|
99
|
+
}
|
|
171
100
|
.calendar-day-cell.today {
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
101
|
+
background-color: var(--ty-calendar-today-bg, transparent);
|
|
102
|
+
color: var(--ty-calendar-today-color, var(--ty-calendar-today-accent, var(--calendar-month-accent, var(--ty-color-primary))));
|
|
103
|
+
border-color: var(--ty-calendar-today-border, transparent);
|
|
104
|
+
font-weight: 600;
|
|
176
105
|
}
|
|
177
|
-
|
|
178
|
-
/* Weekend: no distinction by default (hook kept for theming) */
|
|
179
106
|
.calendar-day-cell.weekend {
|
|
180
|
-
|
|
181
|
-
}
|
|
182
|
-
|
|
183
|
-
/* Other Month - Muted.
|
|
184
|
-
Was color: var(--ty-color-neutral-faint) at opacity 0.5 — -faint alone is
|
|
185
|
-
only ~2.5:1 against the content surface (already under the 4.5:1 AA text
|
|
186
|
-
minimum), and blending it toward the background via opacity made it
|
|
187
|
-
worse (~1.5:1 in light mode). --ty-calendar-other-month-color is its own
|
|
188
|
-
token (tyrell.css :root / html.dark) calibrated to actually pass, with
|
|
189
|
-
opacity dropped rather than layered on top. */
|
|
107
|
+
color: var(--ty-calendar-weekend-color, var(--ty-calendar-day-color, var(--ty-text)));
|
|
108
|
+
}
|
|
190
109
|
.calendar-day-cell.other-month {
|
|
191
|
-
|
|
110
|
+
color: var(--ty-calendar-other-month-color, #6b7280);
|
|
192
111
|
}
|
|
193
|
-
|
|
194
112
|
.calendar-day-cell.other-month:hover {
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
113
|
+
color: var(--ty-calendar-day-hover-color, var(--ty-color-neutral-strong));
|
|
114
|
+
background-color: var(--ty-calendar-day-hover-bg, var(--ty-bg-neutral-soft));
|
|
115
|
+
opacity: 0.7;
|
|
198
116
|
}
|
|
199
|
-
|
|
200
|
-
/* Disabled - outside min/max bounds */
|
|
201
117
|
.calendar-day-cell.disabled {
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
118
|
+
color: var(--ty-calendar-disabled-color, var(--ty-color-neutral-faint));
|
|
119
|
+
opacity: var(--ty-calendar-disabled-opacity, 0.35);
|
|
120
|
+
cursor: default;
|
|
121
|
+
pointer-events: none;
|
|
206
122
|
}
|
|
207
|
-
|
|
208
|
-
/* Selected: the one strong element in the grid */
|
|
209
123
|
.calendar-day-cell.selected {
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
124
|
+
background-color: var(--ty-calendar-selected-bg, var(--calendar-month-selected-bg, var(--ty-bg-primary)));
|
|
125
|
+
color: var(--ty-calendar-selected-color, var(--calendar-month-selected-color, var(--ty-color-primary-strong)));
|
|
126
|
+
border-color: var(--ty-calendar-selected-border, var(--ty-calendar-accent, var(--calendar-month-accent, transparent)));
|
|
127
|
+
font-weight: 600;
|
|
214
128
|
}
|
|
215
|
-
|
|
216
129
|
.calendar-day-cell.selected:hover {
|
|
217
|
-
|
|
218
|
-
|
|
130
|
+
background-color: var(--ty-calendar-selected-hover-bg, var(--calendar-month-selected-hover-bg, var(--ty-bg-primary-bold)));
|
|
131
|
+
border-color: var(--ty-calendar-selected-hover-border, transparent);
|
|
219
132
|
}
|
|
220
|
-
|
|
221
133
|
.calendar-day-cell.selected.other-month {
|
|
222
|
-
|
|
223
|
-
}
|
|
224
|
-
|
|
225
|
-
/* ============================================================================
|
|
226
|
-
Size Variants
|
|
227
|
-
============================================================================ */
|
|
228
|
-
|
|
229
|
-
/* Small - Compact (240px min-width) */
|
|
134
|
+
opacity: 0.7;
|
|
135
|
+
}
|
|
230
136
|
.calendar-size-sm {
|
|
231
|
-
|
|
232
|
-
|
|
137
|
+
padding: 0.5rem;
|
|
138
|
+
min-width: var(--ty-calendar-width, 240px);
|
|
233
139
|
}
|
|
234
|
-
|
|
235
140
|
.calendar-size-sm .calendar-header-cell {
|
|
236
|
-
|
|
237
|
-
|
|
141
|
+
font-size: 0.625rem;
|
|
142
|
+
padding: 0.125rem;
|
|
238
143
|
}
|
|
239
|
-
|
|
240
144
|
.calendar-size-sm .calendar-day-cell {
|
|
241
|
-
|
|
242
|
-
|
|
145
|
+
font-size: 0.75rem;
|
|
146
|
+
margin: 0.0625rem;
|
|
243
147
|
}
|
|
244
|
-
|
|
245
148
|
.calendar-size-sm .calendar-day-row {
|
|
246
|
-
|
|
149
|
+
min-height: 1.5rem;
|
|
247
150
|
}
|
|
248
|
-
|
|
249
|
-
/* Medium - Default (280px min-width) */
|
|
250
151
|
.calendar-size-md {
|
|
251
|
-
|
|
252
|
-
|
|
152
|
+
padding: 0.75rem;
|
|
153
|
+
min-width: var(--ty-calendar-width, 280px);
|
|
253
154
|
}
|
|
254
|
-
|
|
255
155
|
.calendar-size-md .calendar-header-cell {
|
|
256
|
-
|
|
257
|
-
|
|
156
|
+
font-size: 0.6875rem;
|
|
157
|
+
padding: 0.25rem;
|
|
258
158
|
}
|
|
259
|
-
|
|
260
159
|
.calendar-size-md .calendar-day-cell {
|
|
261
|
-
|
|
262
|
-
|
|
160
|
+
font-size: 0.8125rem;
|
|
161
|
+
margin: 0.125rem;
|
|
263
162
|
}
|
|
264
|
-
|
|
265
163
|
.calendar-size-md .calendar-day-row {
|
|
266
|
-
|
|
164
|
+
min-height: 2rem;
|
|
267
165
|
}
|
|
268
|
-
|
|
269
|
-
/* Large - Spacious (360px min-width) */
|
|
270
166
|
.calendar-size-lg {
|
|
271
|
-
|
|
272
|
-
|
|
167
|
+
padding: 1rem;
|
|
168
|
+
min-width: var(--ty-calendar-width, 360px);
|
|
273
169
|
}
|
|
274
|
-
|
|
275
170
|
.calendar-size-lg .calendar-header-cell {
|
|
276
|
-
|
|
277
|
-
|
|
171
|
+
font-size: 0.75rem;
|
|
172
|
+
padding: 0.375rem;
|
|
278
173
|
}
|
|
279
|
-
|
|
280
174
|
.calendar-size-lg .calendar-day-cell {
|
|
281
|
-
|
|
282
|
-
|
|
175
|
+
font-size: 0.875rem;
|
|
176
|
+
margin: 0.1875rem;
|
|
283
177
|
}
|
|
284
|
-
|
|
285
178
|
.calendar-size-lg .calendar-day-row {
|
|
286
|
-
|
|
179
|
+
min-height: 2.5rem;
|
|
287
180
|
}
|
|
288
|
-
|
|
289
|
-
/* ============================================================================
|
|
290
|
-
Backwards Compatibility
|
|
291
|
-
============================================================================ */
|
|
292
|
-
|
|
293
181
|
.calendar-day {
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
}
|
|
302
|
-
|
|
303
|
-
/* ============================================================================
|
|
304
|
-
Flavor Variants (set --calendar-month-*, consumed above)
|
|
305
|
-
============================================================================ */
|
|
182
|
+
width: 100%;
|
|
183
|
+
height: 100%;
|
|
184
|
+
display: flex;
|
|
185
|
+
flex-direction: column;
|
|
186
|
+
align-items: center;
|
|
187
|
+
justify-content: center;
|
|
188
|
+
box-sizing: border-box;
|
|
189
|
+
}
|
|
306
190
|
${FLAVORS.map((f) => calendarMonthFlavor(f)).join("")}
|
|
307
191
|
`;
|
|
308
|
-
//# sourceMappingURL=calendar-month.js.map
|
|
@@ -1,6 +1,2 @@
|
|
|
1
|
-
/**
|
|
2
|
-
|
|
3
|
-
* Clean, modern design with proper visual hierarchy and size variants
|
|
4
|
-
*/
|
|
5
|
-
export declare const calendarNavigationStyles = "\n/* ============================================================================\n Size Variants (CSS Custom Properties)\n ============================================================================ */\n\n/* Theming tokens applied as var(--ty-calendar-nav-*, <default>) at point of\n use (NOT on :host) so consumers can override them from outside \u2014 this\n component is nested inside ty-calendar's shadow, so a :host default would\n block inherited overrides. --ty-calendar-accent still cascades in. */\n\n:host([data-size=\"md\"]) {\n --nav-btn-size: 2rem;\n --nav-btn-icon-size: 1.25rem;\n --nav-font-size: 1rem;\n --nav-padding: 0.5rem 0.75rem;\n --nav-default-width: 280px;\n}\n\n:host([data-size=\"sm\"]) {\n --nav-btn-size: 1.5rem;\n --nav-btn-icon-size: 1rem;\n --nav-font-size: 0.875rem;\n --nav-padding: 0.375rem 0.5rem;\n --nav-default-width: 240px;\n}\n\n:host([data-size=\"lg\"]) {\n --nav-btn-size: 2.5rem;\n --nav-btn-icon-size: 1.5rem;\n --nav-font-size: 1.125rem;\n --nav-padding: 0.625rem 1rem;\n --nav-default-width: 360px;\n}\n\n/* ============================================================================\n Main Navigation Header\n ============================================================================ */\n\n.calendar-navigation-header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: var(--nav-padding);\n font-family: system-ui, sans-serif;\n user-select: none;\n width: var(--nav-width, var(--nav-default-width));\n box-sizing: border-box;\n}\n\n/* ============================================================================\n Navigation Groups (Left, Center, Right)\n ============================================================================ */\n\n.nav-group {\n display: flex;\n align-items: center;\n gap: 0.25rem;\n}\n\n.nav-group-left,\n.nav-group-right {\n flex: 0 0 auto;\n}\n\n.nav-group-center {\n flex: 1;\n justify-content: center;\n}\n\n/* ============================================================================\n Navigation Buttons\n ============================================================================ */\n\n.nav-btn {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: var(--nav-btn-size);\n height: var(--nav-btn-size);\n padding: 0;\n border: none;\n border-radius: var(--ty-radius-base);\n background-color: transparent;\n color: var(--ty-calendar-nav-color, var(--ty-color-neutral));\n cursor: pointer;\n transition: var(--ty-local-transition, all 0.15s ease);\n outline: none;\n}\n\n.nav-btn:hover {\n background-color: var(--ty-calendar-nav-hover-bg, var(--ty-bg-neutral-soft));\n color: var(--ty-calendar-nav-hover-color, var(--ty-color-neutral-strong));\n}\n\n.nav-btn:active {\n background-color: var(--ty-calendar-nav-active-bg, var(--ty-bg-neutral));\n transform: scale(0.95);\n}\n\n.nav-btn:disabled {\n opacity: 0.35;\n cursor: default;\n pointer-events: none;\n}\n\n.nav-btn:focus-visible {\n outline: 2px solid var(--ty-calendar-nav-focus-outline, var(--ty-calendar-accent, var(--ty-color-primary)));\n outline-offset: 2px;\n}\n\n/* SVG sizing */\n.nav-btn svg {\n width: var(--nav-btn-icon-size);\n height: var(--nav-btn-icon-size);\n display: block;\n}\n\n/* ============================================================================\n Month/Year Display (Center)\n ============================================================================ */\n\n.month-year-display {\n font-size: var(--nav-font-size);\n font-weight: 600;\n color: var(--ty-calendar-nav-title-color, var(--ty-color-neutral-strong));\n text-align: center;\n white-space: nowrap;\n letter-spacing: -0.01em;\n}\n";
|
|
6
|
-
//# sourceMappingURL=calendar-navigation.d.ts.map
|
|
1
|
+
/** Calendar Navigation Styles */
|
|
2
|
+
export declare const calendarNavigationStyles = "\n/* Theming tokens applied as var(--ty-calendar-nav-*, <default>) at point of\n use (NOT on :host) so consumers can override them from outside \u2014 this\n component is nested inside ty-calendar's shadow, so a :host default would\n block inherited overrides. --ty-calendar-accent still cascades in. */\n\n:host([data-size=\"md\"]) {\n --nav-btn-size: 2rem;\n --nav-btn-icon-size: 1.25rem;\n --nav-font-size: 0.875rem;\n --nav-padding: 0.5rem 0.75rem;\n --nav-default-width: 280px;\n}\n\n:host([data-size=\"sm\"]) {\n --nav-btn-size: 1.5rem;\n --nav-btn-icon-size: 1rem;\n --nav-font-size: 0.875rem;\n --nav-padding: 0.375rem 0.5rem;\n --nav-default-width: 240px;\n}\n\n:host([data-size=\"lg\"]) {\n --nav-btn-size: 2.5rem;\n --nav-btn-icon-size: 1.5rem;\n --nav-font-size: 0.875rem;\n --nav-padding: 0.625rem 1rem;\n --nav-default-width: 360px;\n}\n\n.calendar-navigation-header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: var(--nav-padding);\n font-family: inherit;\n user-select: none;\n /* --ty-calendar-width is the public knob: set it on ty-calendar (or any\n ancestor) and BOTH the nav and the day grid follow it, because custom\n properties inherit through shadow boundaries. --nav-default-width can't\n serve that role \u2014 it's declared on :host([data-size]) inside this shadow\n root, and a declaration on the element always beats a value inherited\n into it, so an outside override of it is silently dead. --nav-width\n (set inline by the width attribute) still wins over both. */\n width: var(--nav-width, var(--ty-calendar-width, var(--nav-default-width)));\n box-sizing: border-box;\n}\n\n/* Navigation groups: left, center, right */\n.nav-group {\n display: flex;\n align-items: center;\n gap: 0.25rem;\n}\n\n.nav-group-left,\n.nav-group-right {\n flex: 0 0 auto;\n}\n\n.nav-group-center {\n flex: 1;\n justify-content: center;\n /* Flex items default to min-width:auto, i.e. they refuse to shrink below\n their content. A long month name (\"September 2026\") therefore widened\n this group and shoved the arrow groups outward \u2014 the nav visibly\n re-laid-out as you paged month to month. min-width:0 lets the centre\n take exactly the leftover space, so the arrows stay pinned whatever the\n label says, and an over-long label ellipsizes instead of pushing. */\n min-width: 0;\n}\n\n.nav-btn {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: var(--nav-btn-size);\n height: var(--nav-btn-size);\n padding: 0;\n border: none;\n border-radius: var(--ty-radius-base);\n background-color: transparent;\n color: var(--ty-calendar-nav-color, var(--ty-color-neutral));\n cursor: pointer;\n transition: var(--ty-local-transition, all 0.15s ease);\n outline: none;\n}\n\n.nav-btn:hover {\n background-color: var(--ty-calendar-nav-hover-bg, var(--ty-bg-neutral-soft));\n color: var(--ty-calendar-nav-hover-color, var(--ty-color-neutral-strong));\n}\n\n.nav-btn:active {\n background-color: var(--ty-calendar-nav-active-bg, var(--ty-bg-neutral));\n transform: scale(0.95);\n}\n\n.nav-btn:disabled {\n opacity: 0.35;\n cursor: default;\n pointer-events: none;\n}\n\n.nav-btn:focus-visible {\n outline: 2px solid var(--ty-calendar-nav-focus-outline, var(--ty-calendar-accent, var(--ty-color-primary)));\n outline-offset: 2px;\n}\n\n.nav-btn svg {\n width: var(--nav-btn-icon-size);\n height: var(--nav-btn-icon-size);\n display: block;\n}\n\n/* 14px uppercase at every size, not a per-size type scale: the label is the\n widest thing in the bar and the only one whose width depends on the data\n (\"May\" vs \"September\"), so scaling it up on lg was what made the arrows\n shuffle around. Small caps read as chrome, stay legible, and leave the\n centre column comfortably wider than the longest localized month name.\n Ellipsis is a backstop for a narrow --nav-width, not the sizing strategy. */\n.month-year-display {\n font-size: var(--nav-font-size);\n font-weight: 600;\n color: var(--ty-calendar-nav-title-color, var(--ty-color-neutral-strong));\n text-align: center;\n white-space: nowrap;\n text-transform: uppercase;\n letter-spacing: 0.04em;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n";
|
|
@@ -1,135 +1,95 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Calendar Navigation Styles
|
|
3
|
-
* Clean, modern design with proper visual hierarchy and size variants
|
|
4
|
-
*/
|
|
5
1
|
export const calendarNavigationStyles = `
|
|
6
|
-
/* ============================================================================
|
|
7
|
-
Size Variants (CSS Custom Properties)
|
|
8
|
-
============================================================================ */
|
|
9
|
-
|
|
10
|
-
/* Theming tokens applied as var(--ty-calendar-nav-*, <default>) at point of
|
|
11
|
-
use (NOT on :host) so consumers can override them from outside — this
|
|
12
|
-
component is nested inside ty-calendar's shadow, so a :host default would
|
|
13
|
-
block inherited overrides. --ty-calendar-accent still cascades in. */
|
|
14
|
-
|
|
15
2
|
:host([data-size="md"]) {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
3
|
+
--nav-btn-size: 2rem;
|
|
4
|
+
--nav-btn-icon-size: 1.25rem;
|
|
5
|
+
--nav-font-size: 0.875rem;
|
|
6
|
+
--nav-padding: 0.5rem 0.75rem;
|
|
7
|
+
--nav-default-width: 280px;
|
|
21
8
|
}
|
|
22
|
-
|
|
23
9
|
:host([data-size="sm"]) {
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
10
|
+
--nav-btn-size: 1.5rem;
|
|
11
|
+
--nav-btn-icon-size: 1rem;
|
|
12
|
+
--nav-font-size: 0.875rem;
|
|
13
|
+
--nav-padding: 0.375rem 0.5rem;
|
|
14
|
+
--nav-default-width: 240px;
|
|
29
15
|
}
|
|
30
|
-
|
|
31
16
|
:host([data-size="lg"]) {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
17
|
+
--nav-btn-size: 2.5rem;
|
|
18
|
+
--nav-btn-icon-size: 1.5rem;
|
|
19
|
+
--nav-font-size: 0.875rem;
|
|
20
|
+
--nav-padding: 0.625rem 1rem;
|
|
21
|
+
--nav-default-width: 360px;
|
|
37
22
|
}
|
|
38
|
-
|
|
39
|
-
/* ============================================================================
|
|
40
|
-
Main Navigation Header
|
|
41
|
-
============================================================================ */
|
|
42
|
-
|
|
43
23
|
.calendar-navigation-header {
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
24
|
+
display: flex;
|
|
25
|
+
align-items: center;
|
|
26
|
+
justify-content: space-between;
|
|
27
|
+
padding: var(--nav-padding);
|
|
28
|
+
font-family: inherit;
|
|
29
|
+
user-select: none;
|
|
30
|
+
width: var(--nav-width, var(--ty-calendar-width, var(--nav-default-width)));
|
|
31
|
+
box-sizing: border-box;
|
|
52
32
|
}
|
|
53
|
-
|
|
54
|
-
/* ============================================================================
|
|
55
|
-
Navigation Groups (Left, Center, Right)
|
|
56
|
-
============================================================================ */
|
|
57
|
-
|
|
58
33
|
.nav-group {
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
34
|
+
display: flex;
|
|
35
|
+
align-items: center;
|
|
36
|
+
gap: 0.25rem;
|
|
62
37
|
}
|
|
63
|
-
|
|
64
38
|
.nav-group-left,
|
|
65
39
|
.nav-group-right {
|
|
66
|
-
|
|
40
|
+
flex: 0 0 auto;
|
|
67
41
|
}
|
|
68
|
-
|
|
69
42
|
.nav-group-center {
|
|
70
|
-
|
|
71
|
-
|
|
43
|
+
flex: 1;
|
|
44
|
+
justify-content: center;
|
|
45
|
+
min-width: 0;
|
|
72
46
|
}
|
|
73
|
-
|
|
74
|
-
/* ============================================================================
|
|
75
|
-
Navigation Buttons
|
|
76
|
-
============================================================================ */
|
|
77
|
-
|
|
78
47
|
.nav-btn {
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
48
|
+
display: inline-flex;
|
|
49
|
+
align-items: center;
|
|
50
|
+
justify-content: center;
|
|
51
|
+
width: var(--nav-btn-size);
|
|
52
|
+
height: var(--nav-btn-size);
|
|
53
|
+
padding: 0;
|
|
54
|
+
border: none;
|
|
55
|
+
border-radius: var(--ty-radius-base);
|
|
56
|
+
background-color: transparent;
|
|
57
|
+
color: var(--ty-calendar-nav-color, var(--ty-color-neutral));
|
|
58
|
+
cursor: pointer;
|
|
59
|
+
transition: var(--ty-local-transition, all 0.15s ease);
|
|
60
|
+
outline: none;
|
|
92
61
|
}
|
|
93
|
-
|
|
94
62
|
.nav-btn:hover {
|
|
95
|
-
|
|
96
|
-
|
|
63
|
+
background-color: var(--ty-calendar-nav-hover-bg, var(--ty-bg-neutral-soft));
|
|
64
|
+
color: var(--ty-calendar-nav-hover-color, var(--ty-color-neutral-strong));
|
|
97
65
|
}
|
|
98
|
-
|
|
99
66
|
.nav-btn:active {
|
|
100
|
-
|
|
101
|
-
|
|
67
|
+
background-color: var(--ty-calendar-nav-active-bg, var(--ty-bg-neutral));
|
|
68
|
+
transform: scale(0.95);
|
|
102
69
|
}
|
|
103
|
-
|
|
104
70
|
.nav-btn:disabled {
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
71
|
+
opacity: 0.35;
|
|
72
|
+
cursor: default;
|
|
73
|
+
pointer-events: none;
|
|
108
74
|
}
|
|
109
|
-
|
|
110
75
|
.nav-btn:focus-visible {
|
|
111
|
-
|
|
112
|
-
|
|
76
|
+
outline: 2px solid var(--ty-calendar-nav-focus-outline, var(--ty-calendar-accent, var(--ty-color-primary)));
|
|
77
|
+
outline-offset: 2px;
|
|
113
78
|
}
|
|
114
|
-
|
|
115
|
-
/* SVG sizing */
|
|
116
79
|
.nav-btn svg {
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
80
|
+
width: var(--nav-btn-icon-size);
|
|
81
|
+
height: var(--nav-btn-icon-size);
|
|
82
|
+
display: block;
|
|
120
83
|
}
|
|
121
|
-
|
|
122
|
-
/* ============================================================================
|
|
123
|
-
Month/Year Display (Center)
|
|
124
|
-
============================================================================ */
|
|
125
|
-
|
|
126
84
|
.month-year-display {
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
85
|
+
font-size: var(--nav-font-size);
|
|
86
|
+
font-weight: 600;
|
|
87
|
+
color: var(--ty-calendar-nav-title-color, var(--ty-color-neutral-strong));
|
|
88
|
+
text-align: center;
|
|
89
|
+
white-space: nowrap;
|
|
90
|
+
text-transform: uppercase;
|
|
91
|
+
letter-spacing: 0.04em;
|
|
92
|
+
overflow: hidden;
|
|
93
|
+
text-overflow: ellipsis;
|
|
133
94
|
}
|
|
134
95
|
`;
|
|
135
|
-
//# sourceMappingURL=calendar-navigation.js.map
|