@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,307 @@
|
|
|
1
|
+
/* -------------------------------------------------------------------------------------------------
|
|
2
|
+
* AlertDialog Component Styles
|
|
3
|
+
* Block: alert-dialog
|
|
4
|
+
* -----------------------------------------------------------------------------------------------*/
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Element: trigger - the element that opens the modal
|
|
8
|
+
*/
|
|
9
|
+
.alert-dialog__trigger {
|
|
10
|
+
@apply inline-block;
|
|
11
|
+
@apply cursor-(--cursor-interactive);
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* Transitions
|
|
15
|
+
* CRITICAL: motion-reduce must be AFTER transition for correct override specificity
|
|
16
|
+
*/
|
|
17
|
+
transition:
|
|
18
|
+
transform 300ms var(--ease-out-quart),
|
|
19
|
+
background-color 300ms var(--ease-smooth),
|
|
20
|
+
box-shadow 300ms var(--ease-out);
|
|
21
|
+
@apply motion-reduce:transition-none;
|
|
22
|
+
|
|
23
|
+
/* Focus state */
|
|
24
|
+
&:focus-visible:not(:focus),
|
|
25
|
+
&[data-focus-visible="true"] {
|
|
26
|
+
@apply status-focused;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/* Disabled state */
|
|
30
|
+
&:disabled,
|
|
31
|
+
&[aria-disabled="true"] {
|
|
32
|
+
@apply status-disabled;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/* Active/pressed state */
|
|
36
|
+
&:active,
|
|
37
|
+
&[data-pressed="true"] {
|
|
38
|
+
transform: scale(0.97);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
* Element: backdrop - the overlay behind the dialog
|
|
44
|
+
*/
|
|
45
|
+
.alert-dialog__backdrop {
|
|
46
|
+
@apply fixed inset-0 z-50;
|
|
47
|
+
|
|
48
|
+
/* Entering animation — Reka UI sets data-state="open" when mounted */
|
|
49
|
+
&[data-state="open"] {
|
|
50
|
+
@apply animate-in duration-300 ease-out fade-in-0;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
/* Exiting animation — Reka UI sets data-state="closed" before unmount */
|
|
54
|
+
&[data-state="closed"] {
|
|
55
|
+
@apply animate-out duration-200 ease-out fade-out-0;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
* Reduce Animation
|
|
60
|
+
* CRITICAL: motion-reduce must be AFTER animate for correct override specificity
|
|
61
|
+
*/
|
|
62
|
+
&[data-state="open"],
|
|
63
|
+
&[data-state="closed"] {
|
|
64
|
+
@apply will-change-[opacity];
|
|
65
|
+
@apply motion-reduce:animate-none;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
/**
|
|
70
|
+
* Modifier: backdrop--transparent
|
|
71
|
+
*/
|
|
72
|
+
.alert-dialog__backdrop--transparent {
|
|
73
|
+
@apply bg-transparent;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
/**
|
|
77
|
+
* Modifier: backdrop--opaque
|
|
78
|
+
*/
|
|
79
|
+
.alert-dialog__backdrop--opaque {
|
|
80
|
+
@apply bg-backdrop;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* Modifier: backdrop--blur
|
|
85
|
+
*/
|
|
86
|
+
.alert-dialog__backdrop--blur {
|
|
87
|
+
@apply bg-backdrop backdrop-blur-md;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
/**
|
|
91
|
+
* Element: container - the positioning wrapper for the modal
|
|
92
|
+
*/
|
|
93
|
+
.alert-dialog__container {
|
|
94
|
+
@apply fixed inset-0 z-50;
|
|
95
|
+
@apply flex flex-col items-center;
|
|
96
|
+
@apply w-full min-w-0;
|
|
97
|
+
@apply p-4 sm:p-10;
|
|
98
|
+
@apply pointer-events-none;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
/**
|
|
102
|
+
* Element: dialog - the content container for the modal
|
|
103
|
+
*/
|
|
104
|
+
.alert-dialog__dialog {
|
|
105
|
+
@apply relative;
|
|
106
|
+
@apply flex w-full flex-col;
|
|
107
|
+
@apply rounded-3xl bg-overlay shadow-overlay outline-none;
|
|
108
|
+
@apply p-6;
|
|
109
|
+
@apply overflow-hidden;
|
|
110
|
+
@apply pointer-events-auto;
|
|
111
|
+
|
|
112
|
+
&[data-placement="auto"] {
|
|
113
|
+
@apply mt-auto sm:my-auto;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
&[data-placement="center"] {
|
|
117
|
+
@apply my-auto;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
&[data-placement="bottom"] {
|
|
121
|
+
@apply mt-auto;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
&[data-placement="top"] {
|
|
125
|
+
@apply mt-0;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
/* Entering animation — Reka UI sets data-state="open" on AlertDialogContent when mounted */
|
|
129
|
+
&[data-state="open"] {
|
|
130
|
+
@apply animate-in duration-300 ease-out-quad fade-in-0 zoom-in-95;
|
|
131
|
+
|
|
132
|
+
&[data-placement="auto"] {
|
|
133
|
+
@apply slide-in-from-bottom-1 sm:slide-in-from-bottom-0;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
&[data-placement="top"] {
|
|
137
|
+
@apply slide-in-from-top-1;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
&[data-placement="center"] {
|
|
141
|
+
@apply slide-in-from-top-0;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
&[data-placement="bottom"] {
|
|
145
|
+
@apply slide-in-from-bottom-1;
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
/* Exiting animation — Reka UI sets data-state="closed" before unmount */
|
|
150
|
+
&[data-state="closed"] {
|
|
151
|
+
@apply animate-out duration-200 ease-out-quad fade-out-0 zoom-out-95;
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
/**
|
|
155
|
+
* Reduce Animation
|
|
156
|
+
* CRITICAL: motion-reduce must be AFTER animate for correct override specificity
|
|
157
|
+
*/
|
|
158
|
+
&[data-state="open"],
|
|
159
|
+
&[data-state="closed"] {
|
|
160
|
+
@apply will-change-[opacity,transform];
|
|
161
|
+
@apply motion-reduce:animate-none;
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
/**
|
|
166
|
+
* Modifier: dialog--xs
|
|
167
|
+
*/
|
|
168
|
+
.alert-dialog__dialog--xs {
|
|
169
|
+
@apply max-w-xs;
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
/**
|
|
173
|
+
* Modifier: dialog--sm
|
|
174
|
+
*/
|
|
175
|
+
.alert-dialog__dialog--sm {
|
|
176
|
+
@apply max-w-sm;
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
/**
|
|
180
|
+
* Modifier: dialog--md
|
|
181
|
+
*/
|
|
182
|
+
.alert-dialog__dialog--md {
|
|
183
|
+
@apply max-w-md;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
/**
|
|
187
|
+
* Modifier: dialog--lg
|
|
188
|
+
*/
|
|
189
|
+
.alert-dialog__dialog--lg {
|
|
190
|
+
@apply max-w-lg;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
/**
|
|
194
|
+
* Modifier: dialog--cover
|
|
195
|
+
*/
|
|
196
|
+
.alert-dialog__dialog--cover {
|
|
197
|
+
@apply h-full min-h-full w-full;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
/**
|
|
201
|
+
* Element: header - the top section with the title
|
|
202
|
+
*/
|
|
203
|
+
.alert-dialog__header {
|
|
204
|
+
@apply flex flex-col gap-3;
|
|
205
|
+
@apply mb-0;
|
|
206
|
+
|
|
207
|
+
/* When header contains icon, use flex-col layout with gap */
|
|
208
|
+
& > .alert-dialog__icon {
|
|
209
|
+
@apply mb-0;
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
/**
|
|
214
|
+
* Element: heading - the main title text
|
|
215
|
+
*/
|
|
216
|
+
.alert-dialog__heading {
|
|
217
|
+
@apply align-middle;
|
|
218
|
+
@apply text-sm font-medium text-foreground;
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
/**
|
|
222
|
+
* Element: icon - the optional icon indicator
|
|
223
|
+
*/
|
|
224
|
+
.alert-dialog__icon {
|
|
225
|
+
@apply flex items-center justify-center;
|
|
226
|
+
@apply size-10 shrink-0;
|
|
227
|
+
@apply rounded-full select-none;
|
|
228
|
+
|
|
229
|
+
[data-slot="alert-dialog-default-icon"] {
|
|
230
|
+
@apply box-content size-5;
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
/**
|
|
235
|
+
* Modifier: icon--default
|
|
236
|
+
*/
|
|
237
|
+
.alert-dialog__icon--default {
|
|
238
|
+
@apply bg-default text-foreground;
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
/**
|
|
242
|
+
* Modifier: icon--accent
|
|
243
|
+
*/
|
|
244
|
+
.alert-dialog__icon--accent {
|
|
245
|
+
@apply bg-accent-soft text-accent-soft-foreground;
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
/**
|
|
249
|
+
* Modifier: icon--success
|
|
250
|
+
*/
|
|
251
|
+
.alert-dialog__icon--success {
|
|
252
|
+
@apply bg-success-soft text-success-soft-foreground;
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
/**
|
|
256
|
+
* Modifier: icon--warning
|
|
257
|
+
*/
|
|
258
|
+
.alert-dialog__icon--warning {
|
|
259
|
+
@apply bg-warning-soft text-warning-soft-foreground;
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
/**
|
|
263
|
+
* Modifier: icon--danger
|
|
264
|
+
*/
|
|
265
|
+
.alert-dialog__icon--danger {
|
|
266
|
+
@apply bg-danger-soft text-danger-soft-foreground;
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
/**
|
|
270
|
+
* Element: body - the main content area
|
|
271
|
+
*/
|
|
272
|
+
.alert-dialog__body {
|
|
273
|
+
@apply min-h-0 flex-1;
|
|
274
|
+
@apply text-sm leading-[1.43] text-muted;
|
|
275
|
+
@apply my-0;
|
|
276
|
+
@apply max-h-[60vh];
|
|
277
|
+
}
|
|
278
|
+
|
|
279
|
+
/**
|
|
280
|
+
* Element: footer - the bottom action section
|
|
281
|
+
*/
|
|
282
|
+
.alert-dialog__footer {
|
|
283
|
+
@apply flex flex-row items-center justify-end gap-2;
|
|
284
|
+
@apply mt-0;
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
/**
|
|
288
|
+
* Element: close-trigger - the optional x icon button to close the modal
|
|
289
|
+
*/
|
|
290
|
+
.alert-dialog__close-trigger {
|
|
291
|
+
@apply absolute top-4 right-4;
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
/**
|
|
295
|
+
* Elements Spacing
|
|
296
|
+
*/
|
|
297
|
+
.alert-dialog__header + .alert-dialog__body {
|
|
298
|
+
@apply mt-2;
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
.alert-dialog__header + .alert-dialog__footer {
|
|
302
|
+
@apply mt-5;
|
|
303
|
+
}
|
|
304
|
+
|
|
305
|
+
.alert-dialog__body + .alert-dialog__footer {
|
|
306
|
+
@apply mt-5;
|
|
307
|
+
}
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
/* -------------------------------------------------------------------------------------------------
|
|
2
|
+
* Alert Component Styles
|
|
3
|
+
* Block: alert
|
|
4
|
+
* -----------------------------------------------------------------------------------------------*/
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Block: the alert container
|
|
8
|
+
*/
|
|
9
|
+
.alert {
|
|
10
|
+
@apply relative flex w-full flex-row items-start gap-2.5;
|
|
11
|
+
@apply rounded-xl border px-3 py-2.5;
|
|
12
|
+
|
|
13
|
+
transition:
|
|
14
|
+
background-color 200ms var(--ease-smooth),
|
|
15
|
+
border-color 200ms var(--ease-smooth);
|
|
16
|
+
@apply motion-reduce:transition-none;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Element: indicator - the icon chip at the start of the alert
|
|
21
|
+
*/
|
|
22
|
+
.alert__indicator {
|
|
23
|
+
@apply flex shrink-0 items-center justify-center select-none;
|
|
24
|
+
@apply size-7 rounded-full;
|
|
25
|
+
|
|
26
|
+
[data-slot="alert-default-icon"] {
|
|
27
|
+
@apply size-4;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* Element: content - the title + description column
|
|
33
|
+
*/
|
|
34
|
+
.alert__content {
|
|
35
|
+
@apply flex min-w-0 flex-1 flex-col items-start text-sm;
|
|
36
|
+
@apply pt-1;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* Element: title - the alert heading
|
|
41
|
+
*/
|
|
42
|
+
.alert__title {
|
|
43
|
+
@apply text-sm font-semibold leading-5;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* Element: description - supporting body copy
|
|
48
|
+
*/
|
|
49
|
+
.alert__description {
|
|
50
|
+
@apply text-xs leading-[1.125rem] text-muted;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* Element: close - positioning for the optional dismiss control
|
|
55
|
+
*/
|
|
56
|
+
.alert > [data-slot="close-button"] {
|
|
57
|
+
@apply -mr-1;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/* -------------------------------------------------------------------------------------------------
|
|
61
|
+
* Variants
|
|
62
|
+
* -----------------------------------------------------------------------------------------------*/
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* Modifier: default - neutral surface tone
|
|
66
|
+
*/
|
|
67
|
+
.alert--default {
|
|
68
|
+
background-color: var(--color-surface);
|
|
69
|
+
border-color: var(--color-border);
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.alert--default .alert__indicator {
|
|
73
|
+
background-color: color-mix(in oklab, var(--foreground) 8%, transparent);
|
|
74
|
+
@apply text-foreground;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.alert--default .alert__title {
|
|
78
|
+
@apply text-foreground;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
/**
|
|
82
|
+
* Modifier: accent - primary / brand tone
|
|
83
|
+
*/
|
|
84
|
+
.alert--accent {
|
|
85
|
+
background-color: color-mix(in oklab, var(--accent) 8%, var(--surface));
|
|
86
|
+
border-color: color-mix(in oklab, var(--accent) 28%, transparent);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.alert--accent .alert__indicator {
|
|
90
|
+
@apply bg-accent-soft text-accent-soft-foreground;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.alert--accent .alert__title {
|
|
94
|
+
color: var(--color-accent-soft-foreground);
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* Modifier: success
|
|
99
|
+
*/
|
|
100
|
+
.alert--success {
|
|
101
|
+
background-color: color-mix(in oklab, var(--success) 8%, var(--surface));
|
|
102
|
+
border-color: color-mix(in oklab, var(--success) 28%, transparent);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.alert--success .alert__indicator {
|
|
106
|
+
@apply bg-success-soft text-success-soft-foreground;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
.alert--success .alert__title {
|
|
110
|
+
color: var(--color-success-soft-foreground);
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
/**
|
|
114
|
+
* Modifier: warning
|
|
115
|
+
*/
|
|
116
|
+
.alert--warning {
|
|
117
|
+
background-color: color-mix(in oklab, var(--warning) 9%, var(--surface));
|
|
118
|
+
border-color: color-mix(in oklab, var(--warning) 30%, transparent);
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
.alert--warning .alert__indicator {
|
|
122
|
+
@apply bg-warning-soft text-warning-soft-foreground;
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
.alert--warning .alert__title {
|
|
126
|
+
color: var(--color-warning-soft-foreground);
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
/**
|
|
130
|
+
* Modifier: danger
|
|
131
|
+
*/
|
|
132
|
+
.alert--danger {
|
|
133
|
+
background-color: color-mix(in oklab, var(--danger) 8%, var(--surface));
|
|
134
|
+
border-color: color-mix(in oklab, var(--danger) 30%, transparent);
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
.alert--danger .alert__indicator {
|
|
138
|
+
@apply bg-danger-soft text-danger-soft-foreground;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
.alert--danger .alert__title {
|
|
142
|
+
color: var(--color-danger-soft-foreground);
|
|
143
|
+
}
|