@auronui/styles 1.0.0
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/DATA_ATTRIBUTES.md +163 -0
- package/LICENSE +21 -0
- package/README.md +54 -0
- package/base/base.css +40 -0
- package/components/accordion.css +201 -0
- package/components/alert-dialog.css +307 -0
- package/components/alert.css +143 -0
- package/components/aspect-ratio.css +8 -0
- package/components/autocomplete.css +685 -0
- package/components/avatar.css +78 -0
- package/components/badge.css +186 -0
- package/components/breadcrumbs.css +76 -0
- package/components/button-group.css +126 -0
- package/components/button.css +282 -0
- package/components/calendar-year-picker.css +193 -0
- package/components/calendar.css +332 -0
- package/components/card.css +225 -0
- package/components/checkbox-group.css +7 -0
- package/components/checkbox.css +268 -0
- package/components/chip.css +227 -0
- package/components/close-button.css +65 -0
- package/components/collapsible-group.css +7 -0
- package/components/collapsible.css +74 -0
- package/components/color-area.css +81 -0
- package/components/color-field.css +99 -0
- package/components/color-input-group.css +153 -0
- package/components/color-picker.css +121 -0
- package/components/color-slider.css +266 -0
- package/components/color-swatch-picker.css +247 -0
- package/components/color-swatch.css +42 -0
- package/components/combo-box.css +203 -0
- package/components/date-input-group.css +125 -0
- package/components/date-input.css +529 -0
- package/components/date-picker.css +86 -0
- package/components/date-range-field.css +538 -0
- package/components/date-range-picker.css +93 -0
- package/components/description.css +4 -0
- package/components/drawer.css +222 -0
- package/components/dropdown.css +67 -0
- package/components/empty-state.css +4 -0
- package/components/error-message.css +13 -0
- package/components/field-error.css +19 -0
- package/components/fieldset.css +39 -0
- package/components/header.css +7 -0
- package/components/index.css +164 -0
- package/components/input-otp.css +124 -0
- package/components/input.css +603 -0
- package/components/kbd.css +27 -0
- package/components/label.css +28 -0
- package/components/link.css +144 -0
- package/components/list-box-item.css +29 -0
- package/components/list-box-section.css +13 -0
- package/components/list-box.css +11 -0
- package/components/menu-item.css +68 -0
- package/components/menu-section.css +18 -0
- package/components/menu.css +7 -0
- package/components/meter.css +104 -0
- package/components/modal.css +335 -0
- package/components/number-field.css +395 -0
- package/components/pagination.css +157 -0
- package/components/popover.css +96 -0
- package/components/progress-bar.css +126 -0
- package/components/progress-circle.css +82 -0
- package/components/radio-group.css +47 -0
- package/components/radio.css +157 -0
- package/components/range-calendar.css +402 -0
- package/components/scroll-area.css +70 -0
- package/components/scroll-shadow.css +77 -0
- package/components/select.css +649 -0
- package/components/separator.css +59 -0
- package/components/skeleton.css +48 -0
- package/components/slider.css +155 -0
- package/components/spinner.css +42 -0
- package/components/splitter.css +74 -0
- package/components/stepper.css +160 -0
- package/components/surface.css +23 -0
- package/components/switch-group.css +17 -0
- package/components/switch.css +194 -0
- package/components/table.css +341 -0
- package/components/tabs.css +262 -0
- package/components/tag-group.css +66 -0
- package/components/tag.css +99 -0
- package/components/textarea.css +536 -0
- package/components/time-field.css +530 -0
- package/components/toast.css +267 -0
- package/components/toggle-button-group.css +174 -0
- package/components/toggle-button.css +149 -0
- package/components/toolbar.css +32 -0
- package/components/tooltip.css +47 -0
- package/components/tree.css +81 -0
- package/index.css +29 -0
- package/package.json +415 -0
- package/src/components/accordion/accordion.styles.ts +46 -0
- package/src/components/accordion/index.ts +1 -0
- package/src/components/alert/alert.styles.ts +37 -0
- package/src/components/alert/index.ts +1 -0
- package/src/components/alert-dialog/alert-dialog.styles.ts +72 -0
- package/src/components/alert-dialog/index.ts +1 -0
- package/src/components/aspect-ratio/aspect-ratio.styles.ts +10 -0
- package/src/components/aspect-ratio/index.ts +1 -0
- package/src/components/autocomplete/autocomplete.styles.ts +86 -0
- package/src/components/autocomplete/index.ts +1 -0
- package/src/components/avatar/avatar.styles.ts +53 -0
- package/src/components/avatar/index.ts +1 -0
- package/src/components/badge/badge.styles.ts +77 -0
- package/src/components/badge/index.ts +1 -0
- package/src/components/breadcrumbs/breadcrumbs.styles.ts +14 -0
- package/src/components/breadcrumbs/index.ts +1 -0
- package/src/components/button/__tests__/button.styles.test.ts +79 -0
- package/src/components/button/button.styles.ts +65 -0
- package/src/components/button/index.ts +1 -0
- package/src/components/button-group/button-group.styles.ts +32 -0
- package/src/components/button-group/index.ts +1 -0
- package/src/components/calendar/calendar.styles.ts +60 -0
- package/src/components/calendar/index.ts +1 -0
- package/src/components/calendar-year-picker/calendar-year-picker.styles.ts +15 -0
- package/src/components/calendar-year-picker/index.ts +1 -0
- package/src/components/card/card.styles.ts +65 -0
- package/src/components/card/index.ts +1 -0
- package/src/components/checkbox/checkbox.styles.ts +27 -0
- package/src/components/checkbox/index.ts +1 -0
- package/src/components/checkbox-group/checkbox-group.styles.ts +18 -0
- package/src/components/checkbox-group/index.ts +1 -0
- package/src/components/chip/chip.styles.ts +65 -0
- package/src/components/chip/index.ts +1 -0
- package/src/components/close-button/close-button.styles.ts +17 -0
- package/src/components/close-button/index.ts +1 -0
- package/src/components/collapsible/collapsible.styles.ts +25 -0
- package/src/components/collapsible/index.ts +1 -0
- package/src/components/collapsible-group/collapsible-group.styles.ts +13 -0
- package/src/components/collapsible-group/index.ts +1 -0
- package/src/components/color-area/color-area.styles.ts +23 -0
- package/src/components/color-area/index.ts +1 -0
- package/src/components/color-field/color-field.styles.ts +18 -0
- package/src/components/color-field/index.ts +1 -0
- package/src/components/color-input-group/color-input-group.styles.ts +34 -0
- package/src/components/color-input-group/index.ts +1 -0
- package/src/components/color-picker/color-picker.styles.ts +13 -0
- package/src/components/color-picker/index.ts +1 -0
- package/src/components/color-slider/color-slider.styles.ts +14 -0
- package/src/components/color-slider/index.ts +1 -0
- package/src/components/color-swatch/color-swatch.styles.ts +26 -0
- package/src/components/color-swatch/index.ts +1 -0
- package/src/components/color-swatch-picker/color-swatch-picker.styles.ts +54 -0
- package/src/components/color-swatch-picker/index.ts +1 -0
- package/src/components/combo-box/combo-box.styles.ts +26 -0
- package/src/components/combo-box/index.ts +1 -0
- package/src/components/date-input/date-input.styles.ts +86 -0
- package/src/components/date-input/index.ts +1 -0
- package/src/components/date-picker/date-picker.styles.ts +14 -0
- package/src/components/date-picker/index.ts +1 -0
- package/src/components/date-range-field/date-range-field.styles.ts +87 -0
- package/src/components/date-range-field/index.ts +1 -0
- package/src/components/date-range-picker/date-range-picker.styles.ts +14 -0
- package/src/components/date-range-picker/index.ts +1 -0
- package/src/components/description/description.styles.ts +9 -0
- package/src/components/description/index.ts +1 -0
- package/src/components/drawer/drawer.styles.ts +55 -0
- package/src/components/drawer/index.ts +1 -0
- package/src/components/dropdown/dropdown.styles.ts +14 -0
- package/src/components/dropdown/index.ts +1 -0
- package/src/components/empty-state/empty-state.styles.ts +9 -0
- package/src/components/empty-state/index.ts +1 -0
- package/src/components/error-message/error-message.styles.ts +9 -0
- package/src/components/error-message/index.ts +1 -0
- package/src/components/fieldset/fieldset.styles.ts +29 -0
- package/src/components/fieldset/index.ts +1 -0
- package/src/components/header/header.styles.ts +5 -0
- package/src/components/header/index.ts +1 -0
- package/src/components/index.ts +84 -0
- package/src/components/input/index.ts +1 -0
- package/src/components/input/input.styles.ts +87 -0
- package/src/components/input-otp/index.ts +1 -0
- package/src/components/input-otp/input-otp.styles.ts +30 -0
- package/src/components/kbd/index.ts +1 -0
- package/src/components/kbd/kbd.styles.ts +20 -0
- package/src/components/label/index.ts +1 -0
- package/src/components/label/label.styles.ts +25 -0
- package/src/components/link/index.ts +1 -0
- package/src/components/link/link.styles.ts +38 -0
- package/src/components/list-box/index.ts +1 -0
- package/src/components/list-box/list-box.styles.ts +18 -0
- package/src/components/list-box-item/index.ts +1 -0
- package/src/components/list-box-item/list-box-item.styles.ts +25 -0
- package/src/components/list-box-section/index.ts +1 -0
- package/src/components/list-box-section/list-box-section.styles.ts +13 -0
- package/src/components/menu/index.ts +1 -0
- package/src/components/menu/menu.styles.ts +9 -0
- package/src/components/menu-item/index.ts +1 -0
- package/src/components/menu-item/menu-item.styles.ts +26 -0
- package/src/components/menu-section/index.ts +1 -0
- package/src/components/menu-section/menu-section.styles.ts +14 -0
- package/src/components/meter/index.ts +1 -0
- package/src/components/meter/meter.styles.ts +48 -0
- package/src/components/modal/index.ts +1 -0
- package/src/components/modal/modal.styles.ts +70 -0
- package/src/components/number-field/index.ts +1 -0
- package/src/components/number-field/number-field.styles.ts +80 -0
- package/src/components/pagination/index.ts +1 -0
- package/src/components/pagination/pagination.styles.ts +32 -0
- package/src/components/popover/index.ts +1 -0
- package/src/components/popover/popover.styles.ts +14 -0
- package/src/components/progress-bar/index.ts +1 -0
- package/src/components/progress-bar/progress-bar.styles.ts +97 -0
- package/src/components/progress-circle/index.ts +1 -0
- package/src/components/progress-circle/progress-circle.styles.ts +74 -0
- package/src/components/radio/index.ts +1 -0
- package/src/components/radio/radio.styles.ts +14 -0
- package/src/components/radio-group/index.ts +1 -0
- package/src/components/radio-group/radio-group.styles.ts +18 -0
- package/src/components/range-calendar/index.ts +1 -0
- package/src/components/range-calendar/range-calendar.styles.ts +60 -0
- package/src/components/scroll-shadow/index.ts +1 -0
- package/src/components/scroll-shadow/scroll-shadow.styles.ts +37 -0
- package/src/components/select/index.ts +1 -0
- package/src/components/select/select.styles.ts +86 -0
- package/src/components/separator/index.ts +1 -0
- package/src/components/separator/separator.styles.ts +25 -0
- package/src/components/skeleton/index.ts +1 -0
- package/src/components/skeleton/skeleton.styles.ts +21 -0
- package/src/components/slider/index.ts +1 -0
- package/src/components/slider/slider.styles.ts +40 -0
- package/src/components/spinner/index.ts +1 -0
- package/src/components/spinner/spinner.styles.ts +28 -0
- package/src/components/splitter/index.ts +1 -0
- package/src/components/splitter/splitter.styles.ts +28 -0
- package/src/components/stepper/index.ts +1 -0
- package/src/components/stepper/stepper.styles.ts +57 -0
- package/src/components/surface/index.ts +1 -0
- package/src/components/surface/surface.styles.ts +20 -0
- package/src/components/switch/index.ts +1 -0
- package/src/components/switch/switch.styles.ts +31 -0
- package/src/components/switch-group/index.ts +1 -0
- package/src/components/switch-group/switch-group.styles.ts +25 -0
- package/src/components/table/index.ts +1 -0
- package/src/components/table/table.styles.ts +47 -0
- package/src/components/tabs/index.ts +1 -0
- package/src/components/tabs/tabs.styles.ts +31 -0
- package/src/components/tag/index.ts +1 -0
- package/src/components/tag/tag.styles.ts +37 -0
- package/src/components/tag-group/index.ts +1 -0
- package/src/components/tag-group/tag-group.styles.ts +12 -0
- package/src/components/text/index.ts +1 -0
- package/src/components/text/text.styles.ts +29 -0
- package/src/components/textarea/index.ts +1 -0
- package/src/components/textarea/textarea.styles.ts +86 -0
- package/src/components/time-field/index.ts +1 -0
- package/src/components/time-field/time-field.styles.ts +86 -0
- package/src/components/toast/index.ts +1 -0
- package/src/components/toast/toast.styles.ts +67 -0
- package/src/components/toggle-button/index.ts +1 -0
- package/src/components/toggle-button/toggle-button.styles.ts +28 -0
- package/src/components/toggle-button-group/index.ts +1 -0
- package/src/components/toggle-button-group/toggle-button-group.styles.ts +39 -0
- package/src/components/toolbar/index.ts +1 -0
- package/src/components/toolbar/toolbar.styles.ts +23 -0
- package/src/components/tooltip/index.ts +1 -0
- package/src/components/tooltip/tooltip.styles.ts +12 -0
- package/src/components/tree/index.ts +1 -0
- package/src/components/tree/tree.styles.ts +33 -0
- package/src/index.ts +5 -0
- package/src/utils/index.ts +15 -0
- package/themes/default/components/index.css +6 -0
- package/themes/default/index.css +8 -0
- package/themes/default/variables.css +168 -0
- package/themes/shared/theme.css +196 -0
- package/utilities/index.css +244 -0
- package/variants/index.css +106 -0
|
@@ -0,0 +1,402 @@
|
|
|
1
|
+
/* =============================================================================
|
|
2
|
+
* RangeCalendar Component Styles
|
|
3
|
+
*
|
|
4
|
+
* A compound component for contiguous date range selection.
|
|
5
|
+
* Uses BEM naming convention: range-calendar, range-calendar__element, range-calendar--modifier
|
|
6
|
+
*
|
|
7
|
+
* Density, typography and spacing mirror `.calendar` so RangeCalendar and
|
|
8
|
+
* Calendar look identical outside of range-specific track / cap styling.
|
|
9
|
+
* ============================================================================= */
|
|
10
|
+
|
|
11
|
+
/* -----------------------------------------------------------------------------
|
|
12
|
+
* Base RangeCalendar Styles
|
|
13
|
+
* -------------------------------------------------------------------------- */
|
|
14
|
+
.range-calendar {
|
|
15
|
+
@apply w-64 max-w-full text-xs;
|
|
16
|
+
|
|
17
|
+
container-type: inline-size;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
/* -----------------------------------------------------------------------------
|
|
21
|
+
* RangeCalendar Header
|
|
22
|
+
* -------------------------------------------------------------------------- */
|
|
23
|
+
.range-calendar__header {
|
|
24
|
+
@apply flex items-center justify-between px-0.5 pb-1;
|
|
25
|
+
|
|
26
|
+
&:has(.calendar-year-picker__trigger[data-state="open"]) {
|
|
27
|
+
.range-calendar__nav-button {
|
|
28
|
+
@apply pointer-events-none opacity-0;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.range-calendar__heading {
|
|
34
|
+
@apply flex flex-1 items-center justify-center text-center text-xs font-medium;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.range-calendar__nav-button {
|
|
38
|
+
@apply flex size-6 items-center justify-center rounded-full text-accent;
|
|
39
|
+
|
|
40
|
+
will-change: scale;
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
* Transitions
|
|
44
|
+
* CRITICAL: motion-reduce must be AFTER transition for correct override specificity
|
|
45
|
+
*/
|
|
46
|
+
transition:
|
|
47
|
+
transform 300ms var(--ease-out),
|
|
48
|
+
background-color 300ms var(--ease-out),
|
|
49
|
+
box-shadow 300ms var(--ease-out),
|
|
50
|
+
opacity 300ms var(--ease-out);
|
|
51
|
+
@apply transform-gpu motion-reduce:transition-none;
|
|
52
|
+
|
|
53
|
+
cursor: var(--cursor-interactive);
|
|
54
|
+
|
|
55
|
+
/* Hover state – only on devices that support hover (avoids false triggers on touch) */
|
|
56
|
+
@media (hover: hover) {
|
|
57
|
+
&:hover,
|
|
58
|
+
&[data-hovered="true"] {
|
|
59
|
+
@apply bg-default text-accent;
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
/* Pressed state */
|
|
64
|
+
&:active,
|
|
65
|
+
&[data-pressed="true"] {
|
|
66
|
+
transform: scale(0.95);
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
/* Focus state */
|
|
70
|
+
&:focus-visible,
|
|
71
|
+
&[data-focus-visible="true"] {
|
|
72
|
+
@apply status-focused;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
/* Disabled state */
|
|
76
|
+
&:disabled,
|
|
77
|
+
&[data-disabled] {
|
|
78
|
+
@apply status-disabled;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.range-calendar__nav-button-icon {
|
|
83
|
+
@apply size-3.5;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
/* -----------------------------------------------------------------------------
|
|
87
|
+
* RangeCalendar Grid
|
|
88
|
+
* -------------------------------------------------------------------------- */
|
|
89
|
+
.range-calendar__grid {
|
|
90
|
+
/* Override table display with CSS Grid for easier customization */
|
|
91
|
+
display: grid;
|
|
92
|
+
grid-template-columns: repeat(7, 1fr);
|
|
93
|
+
border-collapse: collapse;
|
|
94
|
+
@apply w-full pt-2;
|
|
95
|
+
|
|
96
|
+
&[aria-readonly="true"] {
|
|
97
|
+
.range-calendar__cell {
|
|
98
|
+
@apply pointer-events-none;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.range-calendar__grid-header {
|
|
104
|
+
/* Grid header (thead) styles */
|
|
105
|
+
display: contents;
|
|
106
|
+
|
|
107
|
+
& > tr {
|
|
108
|
+
display: contents;
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
.range-calendar__grid-body {
|
|
113
|
+
/* Grid body (tbody) styles */
|
|
114
|
+
display: contents;
|
|
115
|
+
|
|
116
|
+
& > tr {
|
|
117
|
+
display: contents;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
/* Add top spacing between header and first body row */
|
|
121
|
+
& > tr:first-child > td {
|
|
122
|
+
@apply mt-1;
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
.range-calendar__grid-row {
|
|
127
|
+
/* Use 'contents' so cells participate directly in grid */
|
|
128
|
+
/* Note: This class can be used for custom row styling if needed */
|
|
129
|
+
display: contents;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
.range-calendar__header-cell {
|
|
133
|
+
/* Header cell (th - weekday names) styles */
|
|
134
|
+
@apply flex items-center justify-center pb-1 text-[10px] font-medium text-muted;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
/* -----------------------------------------------------------------------------
|
|
138
|
+
* RangeCalendar Cells
|
|
139
|
+
* -------------------------------------------------------------------------- */
|
|
140
|
+
.range-calendar__cell {
|
|
141
|
+
@apply relative z-1 mx-0 my-[1px] rounded-full p-0 outline-none;
|
|
142
|
+
cursor: var(--cursor-interactive);
|
|
143
|
+
|
|
144
|
+
will-change: background-color, border-color;
|
|
145
|
+
/**
|
|
146
|
+
* Transitions
|
|
147
|
+
* CRITICAL: motion-reduce must be AFTER transition for correct override specificity
|
|
148
|
+
*/
|
|
149
|
+
transition:
|
|
150
|
+
box-shadow 300ms var(--ease-out),
|
|
151
|
+
border-color 300ms var(--ease-out);
|
|
152
|
+
@apply transform-gpu motion-reduce:transition-none;
|
|
153
|
+
|
|
154
|
+
/* Inner interactive circle/capsule (equivalent to React Aria "button-base") */
|
|
155
|
+
.range-calendar__cell-button {
|
|
156
|
+
@apply flex aspect-square w-full items-center justify-center rounded-full text-xs leading-none font-normal text-foreground no-highlight;
|
|
157
|
+
|
|
158
|
+
will-change: scale;
|
|
159
|
+
transition: scale 300ms var(--ease-out);
|
|
160
|
+
@apply transform-gpu motion-reduce:transition-none;
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
/* Focus state */
|
|
164
|
+
&:focus-visible:not(:focus),
|
|
165
|
+
&[data-focus-visible="true"] {
|
|
166
|
+
@apply z-2;
|
|
167
|
+
|
|
168
|
+
.range-calendar__cell-button {
|
|
169
|
+
@apply status-focused;
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
/* Today indicator (data-today lives on the trigger) */
|
|
174
|
+
&:has([data-today]) {
|
|
175
|
+
.range-calendar__cell-button {
|
|
176
|
+
@apply text-accent;
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
/* Range selected track (middle segment) — data-selected is on the trigger */
|
|
181
|
+
&:has([data-selected]:not([data-outside-view])) {
|
|
182
|
+
@apply rounded-none bg-accent-soft;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
/* Round row boundaries so the range track looks continuous across weeks */
|
|
186
|
+
&:has([data-selected]):is(td:first-child > *, [aria-disabled] + td > *) {
|
|
187
|
+
@apply rounded-ss-lg rounded-es-lg;
|
|
188
|
+
&:has([data-selection-start]) {
|
|
189
|
+
@apply rounded-ss-full rounded-es-full;
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
&:has([data-selected]):is(td:last-child > *, td:has(+ [aria-disabled]) > *) {
|
|
194
|
+
@apply rounded-se-lg rounded-ee-lg;
|
|
195
|
+
&:has([data-selection-end]) {
|
|
196
|
+
@apply rounded-se-full rounded-ee-full;
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
/* Range caps (start/end) — data-selection-start/end are on the trigger */
|
|
201
|
+
&:has([data-selection-start]:not([data-outside-view])),
|
|
202
|
+
&:has([data-selection-end]:not([data-outside-view])) {
|
|
203
|
+
@apply z-2;
|
|
204
|
+
|
|
205
|
+
.range-calendar__cell-button {
|
|
206
|
+
@apply bg-accent text-accent-foreground;
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
&:has([data-selection-start]:not([data-outside-view])) {
|
|
211
|
+
@apply rounded-tl-full rounded-bl-full;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
&:has([data-selection-end]:not([data-outside-view])) {
|
|
215
|
+
@apply rounded-tr-full rounded-br-full;
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
/* Pressed state */
|
|
219
|
+
&:active,
|
|
220
|
+
&[data-pressed="true"] {
|
|
221
|
+
.range-calendar__cell-button {
|
|
222
|
+
scale: 0.9;
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
&:has([data-selection-start]),
|
|
226
|
+
&:has([data-selection-end]) {
|
|
227
|
+
.range-calendar__cell-button {
|
|
228
|
+
@apply bg-accent-hover;
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
/* Hover state for non-selected days */
|
|
234
|
+
@media (hover: hover) {
|
|
235
|
+
&:hover:not(:has([data-selected])),
|
|
236
|
+
&[data-hovered="true"]:not(:has([data-selected])) {
|
|
237
|
+
.range-calendar__cell-button {
|
|
238
|
+
@apply bg-default;
|
|
239
|
+
}
|
|
240
|
+
}
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
/* Outside month / outside view (previous/next month days) */
|
|
244
|
+
&:has([data-outside-view]) {
|
|
245
|
+
@apply text-muted opacity-50;
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
&:has([data-selected][data-outside-view]:not([data-selection-start], [data-selection-end])) {
|
|
249
|
+
@apply bg-default/20;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
/* Unavailable dates (data-unavailable on the trigger) */
|
|
253
|
+
&:has([data-unavailable]) {
|
|
254
|
+
@apply status-disabled;
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
/* Disabled state */
|
|
258
|
+
&:has([data-disabled]:not([data-outside-view])),
|
|
259
|
+
&[data-disabled]:not(:has([data-outside-view])) {
|
|
260
|
+
@apply status-disabled;
|
|
261
|
+
|
|
262
|
+
text-decoration: line-through;
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
/* Outside-view cell followed by selected cell across adjacent table cells */
|
|
267
|
+
.range-calendar__grid-body
|
|
268
|
+
td:has(> .range-calendar__cell:has([data-outside-view]))
|
|
269
|
+
+ td
|
|
270
|
+
> .range-calendar__cell:has([data-selected]) {
|
|
271
|
+
@apply rounded-ss-lg rounded-es-lg;
|
|
272
|
+
|
|
273
|
+
&:has([data-outside-view]),
|
|
274
|
+
&:has([data-selection-start]) {
|
|
275
|
+
@apply rounded-ss-full rounded-es-full;
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
|
|
279
|
+
/* Selected cell followed by outside-view cell across adjacent table cells */
|
|
280
|
+
.range-calendar__grid-body
|
|
281
|
+
td:has(> .range-calendar__cell:has([data-selected])):has(
|
|
282
|
+
+ td > .range-calendar__cell:has([data-outside-view])
|
|
283
|
+
)
|
|
284
|
+
> .range-calendar__cell:has([data-selected]) {
|
|
285
|
+
@apply rounded-se-lg rounded-ee-lg;
|
|
286
|
+
|
|
287
|
+
&:has([data-outside-view]),
|
|
288
|
+
&:has([data-selection-end]) {
|
|
289
|
+
@apply rounded-se-full rounded-ee-full;
|
|
290
|
+
}
|
|
291
|
+
}
|
|
292
|
+
|
|
293
|
+
/* Cell indicator - small dot at bottom center of cell */
|
|
294
|
+
.range-calendar__cell-indicator {
|
|
295
|
+
@apply absolute bottom-1 left-1/2 size-[3px] -translate-x-1/2 rounded-full bg-muted;
|
|
296
|
+
|
|
297
|
+
/* Indicator color changes when cell is selected */
|
|
298
|
+
:has([data-selected]) > & {
|
|
299
|
+
@apply bg-accent-foreground;
|
|
300
|
+
}
|
|
301
|
+
}
|
|
302
|
+
|
|
303
|
+
/* -----------------------------------------------------------------------------
|
|
304
|
+
* RangeCalendar Heading Button (clickable heading for view switching)
|
|
305
|
+
* -------------------------------------------------------------------------- */
|
|
306
|
+
.range-calendar__heading-button {
|
|
307
|
+
@apply inline-flex items-center justify-center rounded-md bg-transparent px-2 py-0.5 text-center text-xs font-medium outline-none;
|
|
308
|
+
cursor: var(--cursor-interactive);
|
|
309
|
+
transition:
|
|
310
|
+
background-color 300ms var(--ease-out),
|
|
311
|
+
box-shadow 300ms var(--ease-out);
|
|
312
|
+
@apply transform-gpu motion-reduce:transition-none;
|
|
313
|
+
|
|
314
|
+
@media (hover: hover) {
|
|
315
|
+
&:hover,
|
|
316
|
+
&[data-hovered="true"] {
|
|
317
|
+
@apply bg-default;
|
|
318
|
+
}
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
&:focus-visible,
|
|
322
|
+
&[data-focus-visible="true"] {
|
|
323
|
+
@apply status-focused;
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
/* -----------------------------------------------------------------------------
|
|
328
|
+
* RangeCalendar Month / Year Grids (view switcher bodies)
|
|
329
|
+
* -------------------------------------------------------------------------- */
|
|
330
|
+
.range-calendar__month-grid,
|
|
331
|
+
.range-calendar__year-grid {
|
|
332
|
+
display: grid;
|
|
333
|
+
grid-template-columns: repeat(3, 1fr);
|
|
334
|
+
grid-template-rows: repeat(4, 1fr);
|
|
335
|
+
border-collapse: collapse;
|
|
336
|
+
@apply aspect-[7/6] w-full;
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
.range-calendar__month-grid-body,
|
|
340
|
+
.range-calendar__year-grid-body {
|
|
341
|
+
display: contents;
|
|
342
|
+
|
|
343
|
+
& > tr {
|
|
344
|
+
display: contents;
|
|
345
|
+
place-items: center;
|
|
346
|
+
|
|
347
|
+
& > td {
|
|
348
|
+
display: flex;
|
|
349
|
+
align-items: center;
|
|
350
|
+
justify-content: center;
|
|
351
|
+
padding: 0.5rem;
|
|
352
|
+
}
|
|
353
|
+
}
|
|
354
|
+
}
|
|
355
|
+
|
|
356
|
+
.range-calendar__month-grid-row,
|
|
357
|
+
.range-calendar__year-grid-row {
|
|
358
|
+
display: contents;
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
.range-calendar__month-cell,
|
|
362
|
+
.range-calendar__year-cell {
|
|
363
|
+
@apply relative m-0.5 flex size-auto items-center justify-center rounded-lg text-center text-xs font-medium outline-none no-highlight;
|
|
364
|
+
will-change: scale;
|
|
365
|
+
transition:
|
|
366
|
+
transform 300ms var(--ease-out),
|
|
367
|
+
box-shadow 300ms var(--ease-out),
|
|
368
|
+
background-color 300ms var(--ease-out);
|
|
369
|
+
@apply transform-gpu motion-reduce:transition-none;
|
|
370
|
+
cursor: var(--cursor-interactive);
|
|
371
|
+
|
|
372
|
+
@media (hover: hover) {
|
|
373
|
+
&:hover:not([data-selected]),
|
|
374
|
+
&[data-hovered="true"]:not([data-selected]) {
|
|
375
|
+
@apply bg-default;
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
&:active,
|
|
380
|
+
&[data-pressed="true"] {
|
|
381
|
+
transform: scale(0.95);
|
|
382
|
+
}
|
|
383
|
+
|
|
384
|
+
&:focus-visible,
|
|
385
|
+
&[data-focus-visible="true"] {
|
|
386
|
+
@apply status-focused;
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
&[data-selected] {
|
|
390
|
+
@apply bg-accent text-accent-foreground;
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
&:disabled,
|
|
394
|
+
&[data-disabled] {
|
|
395
|
+
@apply status-disabled;
|
|
396
|
+
}
|
|
397
|
+
}
|
|
398
|
+
|
|
399
|
+
.range-calendar__month-cell-label,
|
|
400
|
+
.range-calendar__year-cell-label {
|
|
401
|
+
@apply pointer-events-none;
|
|
402
|
+
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
/* -------------------------------------------------------------------------------------------------
|
|
2
|
+
* ScrollArea Component Styles
|
|
3
|
+
* Block: scroll-area
|
|
4
|
+
* Pretty, cross-browser scrollbar driven by Reka UI (same look on Chrome,
|
|
5
|
+
* Safari, Firefox, Edge). Renders a JS-positioned thumb over a track.
|
|
6
|
+
* -----------------------------------------------------------------------------------------------*/
|
|
7
|
+
|
|
8
|
+
.scroll-area__root {
|
|
9
|
+
@apply relative overflow-hidden;
|
|
10
|
+
@apply h-full w-full;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.scroll-area__viewport {
|
|
14
|
+
@apply h-full w-full rounded-[inherit];
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
/* Hide the native scrollbar inside the viewport — Reka already does this
|
|
18
|
+
* inline, but we reinforce for clarity. */
|
|
19
|
+
.scroll-area__viewport > [data-reka-scroll-area-viewport] {
|
|
20
|
+
scrollbar-width: none;
|
|
21
|
+
}
|
|
22
|
+
.scroll-area__viewport > [data-reka-scroll-area-viewport]::-webkit-scrollbar {
|
|
23
|
+
display: none;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.scroll-area__scrollbar {
|
|
27
|
+
@apply flex touch-none select-none;
|
|
28
|
+
@apply bg-transparent;
|
|
29
|
+
@apply p-[2px];
|
|
30
|
+
@apply transition-[background-color,opacity] duration-200 ease-out;
|
|
31
|
+
|
|
32
|
+
&[data-orientation="vertical"] {
|
|
33
|
+
@apply h-full w-2.5;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
&[data-orientation="horizontal"] {
|
|
37
|
+
@apply h-2.5 w-full flex-col;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
&:hover {
|
|
41
|
+
@apply bg-(--scroll-area-track,color-mix(in_oklab,currentColor_6%,transparent));
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.scroll-area__thumb {
|
|
46
|
+
@apply relative flex-1;
|
|
47
|
+
@apply rounded-full;
|
|
48
|
+
@apply bg-(--scroll-area-thumb,color-mix(in_oklab,currentColor_28%,transparent));
|
|
49
|
+
@apply transition-colors duration-150 ease-out;
|
|
50
|
+
|
|
51
|
+
/* Expand hit-target — invisible, absolute-centered — for easier grabbing. */
|
|
52
|
+
&::before {
|
|
53
|
+
content: "";
|
|
54
|
+
@apply absolute left-1/2 top-1/2;
|
|
55
|
+
@apply h-full w-full min-h-11 min-w-11;
|
|
56
|
+
@apply -translate-x-1/2 -translate-y-1/2;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
&:hover {
|
|
60
|
+
@apply bg-(--scroll-area-thumb-hover,color-mix(in_oklab,currentColor_46%,transparent));
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
&[data-state="visible"] {
|
|
64
|
+
@apply opacity-100;
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.scroll-area__corner {
|
|
69
|
+
@apply bg-transparent;
|
|
70
|
+
}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
/* Base scroll-shadow component */
|
|
2
|
+
.scroll-shadow {
|
|
3
|
+
@apply relative;
|
|
4
|
+
--scroll-shadow-size: 40px;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
/* Orientation: Vertical */
|
|
8
|
+
.scroll-shadow--vertical {
|
|
9
|
+
@apply overflow-y-auto;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
/* Orientation: Horizontal */
|
|
13
|
+
.scroll-shadow--horizontal {
|
|
14
|
+
@apply overflow-x-auto;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
/* Variant: Fade - Vertical */
|
|
18
|
+
.scroll-shadow--fade.scroll-shadow--vertical {
|
|
19
|
+
&[data-top-scroll="true"] {
|
|
20
|
+
--scroll-linear-gradient: 0deg, #000 calc(100% - var(--scroll-shadow-size)), transparent;
|
|
21
|
+
|
|
22
|
+
mask-image: linear-gradient(var(--scroll-linear-gradient));
|
|
23
|
+
-webkit-mask-image: linear-gradient(var(--scroll-linear-gradient));
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
&[data-bottom-scroll="true"] {
|
|
27
|
+
--scroll-linear-gradient: 180deg, #000 calc(100% - var(--scroll-shadow-size)), transparent;
|
|
28
|
+
|
|
29
|
+
mask-image: linear-gradient(var(--scroll-linear-gradient));
|
|
30
|
+
-webkit-mask-image: linear-gradient(var(--scroll-linear-gradient));
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
&[data-top-bottom-scroll="true"] {
|
|
34
|
+
--scroll-linear-gradient:
|
|
35
|
+
#000, #000, transparent 0, #000 var(--scroll-shadow-size),
|
|
36
|
+
#000 calc(100% - var(--scroll-shadow-size)), transparent;
|
|
37
|
+
|
|
38
|
+
mask-image: linear-gradient(var(--scroll-linear-gradient));
|
|
39
|
+
-webkit-mask-image: linear-gradient(var(--scroll-linear-gradient));
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
/* Variant: Fade - Horizontal */
|
|
44
|
+
.scroll-shadow--fade.scroll-shadow--horizontal {
|
|
45
|
+
&[data-left-scroll="true"] {
|
|
46
|
+
--scroll-linear-gradient: 270deg, #000 calc(100% - var(--scroll-shadow-size)), transparent;
|
|
47
|
+
|
|
48
|
+
mask-image: linear-gradient(var(--scroll-linear-gradient));
|
|
49
|
+
-webkit-mask-image: linear-gradient(var(--scroll-linear-gradient));
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
&[data-right-scroll="true"] {
|
|
53
|
+
--scroll-linear-gradient: 90deg, #000 calc(100% - var(--scroll-shadow-size)), transparent;
|
|
54
|
+
|
|
55
|
+
mask-image: linear-gradient(var(--scroll-linear-gradient));
|
|
56
|
+
-webkit-mask-image: linear-gradient(var(--scroll-linear-gradient));
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
&[data-left-right-scroll="true"] {
|
|
60
|
+
--scroll-linear-gradient:
|
|
61
|
+
to right, #000, #000, transparent 0, #000 var(--scroll-shadow-size),
|
|
62
|
+
#000 calc(100% - var(--scroll-shadow-size)), transparent;
|
|
63
|
+
|
|
64
|
+
mask-image: linear-gradient(var(--scroll-linear-gradient));
|
|
65
|
+
-webkit-mask-image: linear-gradient(var(--scroll-linear-gradient));
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
/* Hide scrollbar modifier */
|
|
70
|
+
.scroll-shadow--hide-scrollbar {
|
|
71
|
+
scrollbar-width: none;
|
|
72
|
+
-ms-overflow-style: none;
|
|
73
|
+
|
|
74
|
+
&::-webkit-scrollbar {
|
|
75
|
+
@apply hidden;
|
|
76
|
+
}
|
|
77
|
+
}
|