@jrgermain/stylesheet 0.0.3
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/dist/index.css +5380 -0
- package/dist/index.css.map +1 -0
- package/dist/index.min.css +2 -0
- package/dist/index.min.css.map +1 -0
- package/package.json +49 -0
- package/src/styles/_utils.scss +87 -0
- package/src/styles/_variables.scss +344 -0
- package/src/styles/components/_alert.scss +115 -0
- package/src/styles/components/_app.scss +268 -0
- package/src/styles/components/_button.scss +220 -0
- package/src/styles/components/_card.scss +37 -0
- package/src/styles/components/_chip.scss +165 -0
- package/src/styles/components/_details.scss +137 -0
- package/src/styles/components/_dialog.scss +240 -0
- package/src/styles/components/_field.scss +301 -0
- package/src/styles/components/_hr.scss +23 -0
- package/src/styles/components/_layout.scss +85 -0
- package/src/styles/components/_progress-meter.scss +149 -0
- package/src/styles/components/_range.scss +96 -0
- package/src/styles/components/_skeleton.scss +71 -0
- package/src/styles/components/_switch.scss +82 -0
- package/src/styles/components/_table.scss +82 -0
- package/src/styles/components/_text.scss +289 -0
- package/src/styles/experimental/dialog-animations.css +39 -0
- package/src/styles/experimental/mobile-sidebar-fade-out.css +5 -0
- package/src/styles/index.scss +47 -0
|
@@ -0,0 +1,344 @@
|
|
|
1
|
+
@use "sass:map";
|
|
2
|
+
@use "sass:color";
|
|
3
|
+
@use "sass:math";
|
|
4
|
+
|
|
5
|
+
:root,
|
|
6
|
+
::backdrop {
|
|
7
|
+
--header-height: clamp(50px, 3.5rem, 70px);
|
|
8
|
+
--sidebar-width: clamp(300px, 18rem, 400px);
|
|
9
|
+
--opacity-low: 20%;
|
|
10
|
+
--opacity-medium: 40%;
|
|
11
|
+
--opacity-high: 70%;
|
|
12
|
+
|
|
13
|
+
// Brand
|
|
14
|
+
--color-brand-1: oklch(15% 55% 270deg);
|
|
15
|
+
--color-brand-2: oklch(25% 53% 270deg);
|
|
16
|
+
--color-brand-3: oklch(35% 52% 270deg);
|
|
17
|
+
--color-brand-4: oklch(45% 51% 270deg);
|
|
18
|
+
--color-brand-5: oklch(55% 50% 270deg);
|
|
19
|
+
--color-brand-6: oklch(65% 50% 270deg);
|
|
20
|
+
--color-brand-7: oklch(75% 45% 270deg);
|
|
21
|
+
--color-brand-8: oklch(85% 42% 270deg);
|
|
22
|
+
--color-brand-9: oklch(95% 36% 270deg);
|
|
23
|
+
--color-brand-transparent: oklch(55% 50% 270deg / var(--opacity-medium));
|
|
24
|
+
--color-brand-extra-transparent: oklch(55% 50% 270deg / var(--opacity-low));
|
|
25
|
+
|
|
26
|
+
// Red
|
|
27
|
+
--color-red-1: oklch(15% 55% 30deg);
|
|
28
|
+
--color-red-2: oklch(25% 52% 30deg);
|
|
29
|
+
--color-red-3: oklch(35% 54% 30deg);
|
|
30
|
+
--color-red-4: oklch(45% 52% 30deg);
|
|
31
|
+
--color-red-5: oklch(55% 50% 30deg);
|
|
32
|
+
--color-red-6: oklch(65% 50% 30deg);
|
|
33
|
+
--color-red-7: oklch(75% 45% 30deg);
|
|
34
|
+
--color-red-8: oklch(85% 45% 30deg);
|
|
35
|
+
--color-red-9: oklch(95% 38% 30deg);
|
|
36
|
+
--color-red-transparent: oklch(55% 50% 30deg / var(--opacity-medium));
|
|
37
|
+
--color-red-extra-transparent: oklch(55% 50% 30deg / var(--opacity-low));
|
|
38
|
+
|
|
39
|
+
// Orange
|
|
40
|
+
--color-orange-1: oklch(15% 55% 61deg);
|
|
41
|
+
--color-orange-2: oklch(25% 50% 61deg);
|
|
42
|
+
--color-orange-3: oklch(35% 49% 61deg);
|
|
43
|
+
--color-orange-4: oklch(45% 48% 61deg);
|
|
44
|
+
--color-orange-5: oklch(55% 50% 61deg);
|
|
45
|
+
--color-orange-6: oklch(65% 50% 61deg);
|
|
46
|
+
--color-orange-7: oklch(75% 45% 61deg);
|
|
47
|
+
--color-orange-8: oklch(85% 40% 61deg);
|
|
48
|
+
--color-orange-9: oklch(95% 35% 61deg);
|
|
49
|
+
--color-orange-transparent: oklch(55% 50% 61deg / var(--opacity-medium));
|
|
50
|
+
--color-orange-extra-transparent: oklch(55% 50% 61deg / var(--opacity-low));
|
|
51
|
+
|
|
52
|
+
// Yellow
|
|
53
|
+
--color-yellow-1: oklch(15% 50% 90deg);
|
|
54
|
+
--color-yellow-2: oklch(25% 50% 90deg);
|
|
55
|
+
--color-yellow-3: oklch(35% 50% 90deg);
|
|
56
|
+
--color-yellow-4: oklch(45% 44% 90deg);
|
|
57
|
+
--color-yellow-5: oklch(55% 44% 90deg);
|
|
58
|
+
--color-yellow-6: oklch(65% 44% 90deg);
|
|
59
|
+
--color-yellow-7: oklch(75% 40% 90deg);
|
|
60
|
+
--color-yellow-8: oklch(85% 37% 90deg);
|
|
61
|
+
--color-yellow-9: oklch(95% 29% 90deg);
|
|
62
|
+
--color-yellow-transparent: oklch(55% 44% 90deg / var(--opacity-medium));
|
|
63
|
+
--color-yellow-extra-transparent: oklch(55% 44% 90deg / var(--opacity-low));
|
|
64
|
+
|
|
65
|
+
// Green
|
|
66
|
+
--color-green-1: oklch(15% 55% 133deg);
|
|
67
|
+
--color-green-2: oklch(25% 55% 133deg);
|
|
68
|
+
--color-green-3: oklch(35% 50% 133deg);
|
|
69
|
+
--color-green-4: oklch(45% 50% 133deg);
|
|
70
|
+
--color-green-5: oklch(55% 49% 133deg);
|
|
71
|
+
--color-green-6: oklch(65% 49% 133deg);
|
|
72
|
+
--color-green-7: oklch(75% 45% 133deg);
|
|
73
|
+
--color-green-8: oklch(85% 43% 133deg);
|
|
74
|
+
--color-green-9: oklch(95% 30% 133deg);
|
|
75
|
+
--color-green-transparent: oklch(55% 49% 133deg / var(--opacity-medium));
|
|
76
|
+
--color-green-extra-transparent: oklch(55% 49% 133deg / var(--opacity-low));
|
|
77
|
+
|
|
78
|
+
// Sky
|
|
79
|
+
--color-sky-1: oklch(15% 55% 200deg);
|
|
80
|
+
--color-sky-2: oklch(25% 55% 200deg);
|
|
81
|
+
--color-sky-3: oklch(35% 50% 200deg);
|
|
82
|
+
--color-sky-4: oklch(45% 50% 200deg);
|
|
83
|
+
--color-sky-5: oklch(55% 52% 200deg);
|
|
84
|
+
--color-sky-6: oklch(65% 46% 200deg);
|
|
85
|
+
--color-sky-7: oklch(75% 36% 200deg);
|
|
86
|
+
--color-sky-8: oklch(85% 25% 200deg);
|
|
87
|
+
--color-sky-9: oklch(95% 17% 200deg);
|
|
88
|
+
--color-sky-transparent: oklch(55% 52% 200deg / var(--opacity-medium));
|
|
89
|
+
--color-sky-extra-transparent: oklch(55% 52% 200deg / var(--opacity-low));
|
|
90
|
+
|
|
91
|
+
// Blue
|
|
92
|
+
--color-blue-1: oklch(15% 55% 260deg);
|
|
93
|
+
--color-blue-2: oklch(25% 55% 260deg);
|
|
94
|
+
--color-blue-3: oklch(35% 53% 260deg);
|
|
95
|
+
--color-blue-4: oklch(45% 50% 260deg);
|
|
96
|
+
--color-blue-5: oklch(55% 52% 260deg);
|
|
97
|
+
--color-blue-6: oklch(65% 52% 260deg);
|
|
98
|
+
--color-blue-7: oklch(75% 52% 260deg);
|
|
99
|
+
--color-blue-8: oklch(85% 50% 260deg);
|
|
100
|
+
--color-blue-9: oklch(95% 39% 260deg);
|
|
101
|
+
--color-blue-transparent: oklch(55% 52% 260deg / var(--opacity-medium));
|
|
102
|
+
--color-blue-extra-transparent: oklch(55% 52% 260deg / var(--opacity-low));
|
|
103
|
+
|
|
104
|
+
// Purple
|
|
105
|
+
--color-purple-1: oklch(15% 55% 310deg);
|
|
106
|
+
--color-purple-2: oklch(25% 55% 310deg);
|
|
107
|
+
--color-purple-3: oklch(35% 53% 310deg);
|
|
108
|
+
--color-purple-4: oklch(45% 52% 310deg);
|
|
109
|
+
--color-purple-5: oklch(55% 52% 310deg);
|
|
110
|
+
--color-purple-6: oklch(65% 51% 310deg);
|
|
111
|
+
--color-purple-7: oklch(75% 48% 310deg);
|
|
112
|
+
--color-purple-8: oklch(85% 42% 310deg);
|
|
113
|
+
--color-purple-9: oklch(95% 40% 310deg);
|
|
114
|
+
--color-purple-transparent: oklch(55% 52% 310deg / var(--opacity-medium));
|
|
115
|
+
--color-purple-extra-transparent: oklch(55% 52% 310deg / var(--opacity-low));
|
|
116
|
+
|
|
117
|
+
// Magenta
|
|
118
|
+
--color-magenta-1: oklch(15% 55% 356deg);
|
|
119
|
+
--color-magenta-2: oklch(25% 55% 356deg);
|
|
120
|
+
--color-magenta-3: oklch(35% 54% 356deg);
|
|
121
|
+
--color-magenta-4: oklch(45% 51% 356deg);
|
|
122
|
+
--color-magenta-5: oklch(55% 50% 356deg);
|
|
123
|
+
--color-magenta-6: oklch(65% 47% 356deg);
|
|
124
|
+
--color-magenta-7: oklch(75% 43% 356deg);
|
|
125
|
+
--color-magenta-8: oklch(85% 38% 356deg);
|
|
126
|
+
--color-magenta-9: oklch(95% 30% 356deg);
|
|
127
|
+
--color-magenta-transparent: oklch(55% 50% 356deg / var(--opacity-medium));
|
|
128
|
+
--color-magenta-extra-transparent: oklch(55% 50% 356deg / var(--opacity-low));
|
|
129
|
+
|
|
130
|
+
// Gray
|
|
131
|
+
--color-gray-1: oklch(15% 2% 263deg);
|
|
132
|
+
--color-gray-2: oklch(25% 2% 263deg);
|
|
133
|
+
--color-gray-3: oklch(35% 2% 263deg);
|
|
134
|
+
--color-gray-4: oklch(45% 2% 263deg);
|
|
135
|
+
--color-gray-5: oklch(55% 2% 263deg);
|
|
136
|
+
--color-gray-6: oklch(65% 2% 263deg);
|
|
137
|
+
--color-gray-7: oklch(75% 2% 263deg);
|
|
138
|
+
--color-gray-8: oklch(85% 2% 263deg);
|
|
139
|
+
--color-gray-9: oklch(95% 2% 263deg);
|
|
140
|
+
--color-gray-transparent: oklch(55% 2% 263deg / var(--opacity-medium));
|
|
141
|
+
--color-gray-extra-transparent: oklch(55% 2% 263deg / var(--opacity-low));
|
|
142
|
+
|
|
143
|
+
// Individual colors
|
|
144
|
+
--color-body: oklch(98.5% 1% 263deg);
|
|
145
|
+
--color-body-alt: white;
|
|
146
|
+
--color-body-text: oklch(10% 2% 263deg);
|
|
147
|
+
--color-body-text-alt: oklch(38% 2% 263deg);
|
|
148
|
+
--color-shadow: oklch(40% 2% 263deg / 15%);
|
|
149
|
+
--color-outline: oklch(89% 2% 263deg);
|
|
150
|
+
|
|
151
|
+
@media (prefers-color-scheme: dark) {
|
|
152
|
+
// Brand
|
|
153
|
+
--color-brand-9: oklch(17% 55% 270deg);
|
|
154
|
+
--color-brand-8: oklch(27% 53% 270deg);
|
|
155
|
+
--color-brand-7: oklch(37% 52% 270deg);
|
|
156
|
+
--color-brand-6: oklch(47% 51% 270deg);
|
|
157
|
+
--color-brand-5: oklch(57% 50% 270deg);
|
|
158
|
+
--color-brand-4: oklch(67% 50% 270deg);
|
|
159
|
+
--color-brand-3: oklch(77% 45% 270deg);
|
|
160
|
+
--color-brand-2: oklch(87% 42% 270deg);
|
|
161
|
+
--color-brand-1: oklch(97% 36% 270deg);
|
|
162
|
+
|
|
163
|
+
// Red
|
|
164
|
+
--color-red-9: oklch(17% 55% 30deg);
|
|
165
|
+
--color-red-8: oklch(27% 52% 30deg);
|
|
166
|
+
--color-red-7: oklch(37% 54% 30deg);
|
|
167
|
+
--color-red-6: oklch(47% 52% 30deg);
|
|
168
|
+
--color-red-5: oklch(57% 50% 30deg);
|
|
169
|
+
--color-red-4: oklch(67% 50% 30deg);
|
|
170
|
+
--color-red-3: oklch(77% 45% 30deg);
|
|
171
|
+
--color-red-2: oklch(87% 45% 30deg);
|
|
172
|
+
--color-red-1: oklch(97% 38% 30deg);
|
|
173
|
+
|
|
174
|
+
// Orange
|
|
175
|
+
--color-orange-9: oklch(17% 55% 61deg);
|
|
176
|
+
--color-orange-8: oklch(27% 50% 61deg);
|
|
177
|
+
--color-orange-7: oklch(37% 49% 61deg);
|
|
178
|
+
--color-orange-6: oklch(47% 48% 61deg);
|
|
179
|
+
--color-orange-5: oklch(57% 50% 61deg);
|
|
180
|
+
--color-orange-4: oklch(67% 50% 61deg);
|
|
181
|
+
--color-orange-3: oklch(77% 45% 61deg);
|
|
182
|
+
--color-orange-2: oklch(87% 40% 61deg);
|
|
183
|
+
--color-orange-1: oklch(97% 35% 61deg);
|
|
184
|
+
|
|
185
|
+
// Yellow
|
|
186
|
+
--color-yellow-9: oklch(17% 50% 90deg);
|
|
187
|
+
--color-yellow-8: oklch(27% 50% 90deg);
|
|
188
|
+
--color-yellow-7: oklch(37% 50% 90deg);
|
|
189
|
+
--color-yellow-6: oklch(47% 44% 90deg);
|
|
190
|
+
--color-yellow-5: oklch(57% 44% 90deg);
|
|
191
|
+
--color-yellow-4: oklch(67% 44% 90deg);
|
|
192
|
+
--color-yellow-3: oklch(77% 40% 90deg);
|
|
193
|
+
--color-yellow-2: oklch(87% 37% 90deg);
|
|
194
|
+
--color-yellow-1: oklch(97% 29% 90deg);
|
|
195
|
+
|
|
196
|
+
// Green
|
|
197
|
+
--color-green-9: oklch(17% 55% 133deg);
|
|
198
|
+
--color-green-8: oklch(27% 55% 133deg);
|
|
199
|
+
--color-green-7: oklch(37% 50% 133deg);
|
|
200
|
+
--color-green-6: oklch(47% 50% 133deg);
|
|
201
|
+
--color-green-5: oklch(57% 49% 133deg);
|
|
202
|
+
--color-green-4: oklch(67% 49% 133deg);
|
|
203
|
+
--color-green-3: oklch(77% 45% 133deg);
|
|
204
|
+
--color-green-2: oklch(87% 43% 133deg);
|
|
205
|
+
--color-green-1: oklch(97% 30% 133deg);
|
|
206
|
+
|
|
207
|
+
// Sky
|
|
208
|
+
--color-sky-9: oklch(17% 55% 200deg);
|
|
209
|
+
--color-sky-8: oklch(27% 55% 200deg);
|
|
210
|
+
--color-sky-7: oklch(37% 50% 200deg);
|
|
211
|
+
--color-sky-6: oklch(47% 50% 200deg);
|
|
212
|
+
--color-sky-5: oklch(57% 52% 200deg);
|
|
213
|
+
--color-sky-4: oklch(67% 46% 200deg);
|
|
214
|
+
--color-sky-3: oklch(77% 36% 200deg);
|
|
215
|
+
--color-sky-2: oklch(87% 25% 200deg);
|
|
216
|
+
--color-sky-1: oklch(97% 17% 200deg);
|
|
217
|
+
|
|
218
|
+
// Blue
|
|
219
|
+
--color-blue-9: oklch(17% 55% 260deg);
|
|
220
|
+
--color-blue-8: oklch(27% 55% 260deg);
|
|
221
|
+
--color-blue-7: oklch(37% 53% 260deg);
|
|
222
|
+
--color-blue-6: oklch(47% 50% 260deg);
|
|
223
|
+
--color-blue-5: oklch(57% 52% 260deg);
|
|
224
|
+
--color-blue-4: oklch(67% 52% 260deg);
|
|
225
|
+
--color-blue-3: oklch(77% 52% 260deg);
|
|
226
|
+
--color-blue-2: oklch(87% 50% 260deg);
|
|
227
|
+
--color-blue-1: oklch(97% 39% 260deg);
|
|
228
|
+
|
|
229
|
+
// Purple
|
|
230
|
+
--color-purple-9: oklch(17% 55% 310deg);
|
|
231
|
+
--color-purple-8: oklch(27% 55% 310deg);
|
|
232
|
+
--color-purple-7: oklch(37% 53% 310deg);
|
|
233
|
+
--color-purple-6: oklch(47% 52% 310deg);
|
|
234
|
+
--color-purple-5: oklch(57% 52% 310deg);
|
|
235
|
+
--color-purple-4: oklch(67% 51% 310deg);
|
|
236
|
+
--color-purple-3: oklch(77% 48% 310deg);
|
|
237
|
+
--color-purple-2: oklch(87% 42% 310deg);
|
|
238
|
+
--color-purple-1: oklch(97% 40% 310deg);
|
|
239
|
+
|
|
240
|
+
// Magenta
|
|
241
|
+
--color-magenta-9: oklch(17% 55% 356deg);
|
|
242
|
+
--color-magenta-8: oklch(27% 55% 356deg);
|
|
243
|
+
--color-magenta-7: oklch(37% 54% 356deg);
|
|
244
|
+
--color-magenta-6: oklch(47% 51% 356deg);
|
|
245
|
+
--color-magenta-5: oklch(57% 50% 356deg);
|
|
246
|
+
--color-magenta-4: oklch(67% 47% 356deg);
|
|
247
|
+
--color-magenta-3: oklch(77% 43% 356deg);
|
|
248
|
+
--color-magenta-2: oklch(87% 38% 356deg);
|
|
249
|
+
--color-magenta-1: oklch(97% 30% 356deg);
|
|
250
|
+
|
|
251
|
+
// Gray
|
|
252
|
+
--color-gray-9: oklch(17% 2% 263deg);
|
|
253
|
+
--color-gray-8: oklch(27% 2% 263deg);
|
|
254
|
+
--color-gray-7: oklch(37% 2% 263deg);
|
|
255
|
+
--color-gray-6: oklch(47% 2% 263deg);
|
|
256
|
+
--color-gray-5: oklch(57% 2% 263deg);
|
|
257
|
+
--color-gray-4: oklch(67% 2% 263deg);
|
|
258
|
+
--color-gray-3: oklch(77% 2% 263deg);
|
|
259
|
+
--color-gray-2: oklch(87% 2% 263deg);
|
|
260
|
+
--color-gray-1: oklch(97% 2% 263deg);
|
|
261
|
+
|
|
262
|
+
// Darker replacements for semantic colors
|
|
263
|
+
--color-body: oklch(20% 2% 263deg);
|
|
264
|
+
--color-body-alt: oklch(8% 2% 263deg);
|
|
265
|
+
--color-body-text: white;
|
|
266
|
+
--color-body-text-alt: oklch(88% 1% 263deg);
|
|
267
|
+
--color-shadow: oklch(5% 2% 263deg / 25%);
|
|
268
|
+
--color-outline: oklch(39% 2% 263deg);
|
|
269
|
+
|
|
270
|
+
// Slightly decrease font weights
|
|
271
|
+
--font-weight-black: 900;
|
|
272
|
+
--font-weight-bold: 700;
|
|
273
|
+
--font-weight-semibold: 550;
|
|
274
|
+
--font-weight-normal: 375;
|
|
275
|
+
|
|
276
|
+
// Slightly increase opacity
|
|
277
|
+
--opacity-low: 35%;
|
|
278
|
+
--opacity-medium: 50%;
|
|
279
|
+
--opacity-high: 80%;
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
// Font sizes
|
|
283
|
+
--font-size-xs: clamp(0.6944rem, 0.6855rem + 0.0446vw, 0.72rem);
|
|
284
|
+
--font-size-s: clamp(0.8331rem, 0.8099rem + 0.1163vw, 0.9rem);
|
|
285
|
+
--font-size-m: clamp(1rem, 0.9565rem + 0.2174vw, 1.125rem);
|
|
286
|
+
--font-size-l: clamp(1.2rem, 1.1283rem + 0.3587vw, 1.4063rem);
|
|
287
|
+
--font-size-xl: clamp(1.44rem, 1.3293rem + 0.5533vw, 1.7581rem);
|
|
288
|
+
--font-size-2xl: clamp(1.7281rem, 1.5649rem + 0.8163vw, 2.1975rem);
|
|
289
|
+
--font-size-3xl: clamp(2.0738rem, 1.8396rem + 1.1707vw, 2.7469rem);
|
|
290
|
+
--font-size-4xl: clamp(2.4881rem, 2.1594rem + 1.6435vw, 3.4331rem);
|
|
291
|
+
|
|
292
|
+
// Font weights
|
|
293
|
+
--font-weight-black: 950;
|
|
294
|
+
--font-weight-bold: 750;
|
|
295
|
+
--font-weight-semibold: 600;
|
|
296
|
+
--font-weight-normal: 400;
|
|
297
|
+
--font-weight-light: 200;
|
|
298
|
+
|
|
299
|
+
// Font families
|
|
300
|
+
--font-family-body: "Manrope Variable", "Inter", "Roboto", "Helvetica Neue",
|
|
301
|
+
"Arial Nova", "Nimbus Sans", "Arial", sans-serif;
|
|
302
|
+
--font-family-heading: "Lexend Variable", "Inter", "Roboto", "Helvetica Neue",
|
|
303
|
+
"Arial Nova", "Nimbus Sans", "Arial", sans-serif;
|
|
304
|
+
--font-family-ui: var(--font-family-body);
|
|
305
|
+
--font-family-mono: "Source Code Pro Variable", ui-monospace,
|
|
306
|
+
"Source Code Pro", "Menlo", "Consolas", "DejaVu Sans Mono", monospace;
|
|
307
|
+
|
|
308
|
+
// Spacing
|
|
309
|
+
--space-3xs: clamp(4px, 3.6528px + 0.1087vw, 5px);
|
|
310
|
+
--space-2xs: clamp(8px, 7.6528px + 0.1087vw, 9px);
|
|
311
|
+
--space-xs: clamp(12px, 11.304px + 0.2174vw, 14px);
|
|
312
|
+
--space-s: clamp(16px, 15.304px + 0.2174vw, 18px);
|
|
313
|
+
--space-m: clamp(24px, 22.9568px + 0.3261vw, 27px);
|
|
314
|
+
--space-l: clamp(32px, 30.608px + 0.4348vw, 36px);
|
|
315
|
+
--space-xl: clamp(48px, 45.9136px + 0.6522vw, 54px);
|
|
316
|
+
--space-2xl: clamp(64px, 61.2176px + 0.8696vw, 72px);
|
|
317
|
+
--space-3xl: clamp(96px, 91.8256px + 1.3043vw, 108px);
|
|
318
|
+
|
|
319
|
+
// Between xs and m based on screen width
|
|
320
|
+
--space-body: clamp(12px, 6.7824px + 1.6304vw, 27px);
|
|
321
|
+
|
|
322
|
+
// Radii
|
|
323
|
+
--radius-none: 0;
|
|
324
|
+
--radius-s: 3px;
|
|
325
|
+
--radius-m: 6px;
|
|
326
|
+
--radius-l: 12px;
|
|
327
|
+
--radius-xl: 24px;
|
|
328
|
+
--radius-2xl: 64px;
|
|
329
|
+
--radius-full: 9999px;
|
|
330
|
+
|
|
331
|
+
// Shadows
|
|
332
|
+
--shadow-none: none;
|
|
333
|
+
--shadow-s: 0 1px 3px -1px var(--color-shadow);
|
|
334
|
+
--shadow-m: 0 1px 7px -1px var(--color-shadow);
|
|
335
|
+
--shadow-l: var(--shadow-s), 0 1px 11px -1px var(--color-shadow);
|
|
336
|
+
--shadow-xl: var(--shadow-m), 0 1px 15px -1px var(--color-shadow);
|
|
337
|
+
|
|
338
|
+
// Border widths
|
|
339
|
+
--border-none: 0;
|
|
340
|
+
--border-s: 1px;
|
|
341
|
+
--border-m: 2px;
|
|
342
|
+
--border-l: 5px;
|
|
343
|
+
--border-xl: 8px;
|
|
344
|
+
}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
@use "../utils";
|
|
2
|
+
|
|
3
|
+
.alert {
|
|
4
|
+
display: block;
|
|
5
|
+
border-radius: var(--radius-s);
|
|
6
|
+
border-start-start-radius: calc(var(--space-2xs) + 2em);
|
|
7
|
+
border-end-start-radius: calc(var(--space-2xs) + 2em);
|
|
8
|
+
padding: var(--space-2xs);
|
|
9
|
+
padding-inline-start: calc(var(--space-2xs) + 2em);
|
|
10
|
+
font-size: var(--font-size-m);
|
|
11
|
+
color: var(--color-body-text);
|
|
12
|
+
position: relative;
|
|
13
|
+
background:
|
|
14
|
+
linear-gradient(var(--alert-bg-color), var(--alert-bg-color)) padding-box,
|
|
15
|
+
linear-gradient(
|
|
16
|
+
to right,
|
|
17
|
+
var(--alert-border-start-color),
|
|
18
|
+
var(--alert-border-end-color)
|
|
19
|
+
)
|
|
20
|
+
border-box;
|
|
21
|
+
border: var(--border-m) solid transparent;
|
|
22
|
+
line-height: 1.4;
|
|
23
|
+
|
|
24
|
+
> * {
|
|
25
|
+
line-height: 1.4;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
@media print {
|
|
29
|
+
& {
|
|
30
|
+
border-color: var(--alert-border-start-color);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
&::before {
|
|
35
|
+
content: "";
|
|
36
|
+
print-color-adjust: exact;
|
|
37
|
+
z-index: 2;
|
|
38
|
+
position: absolute;
|
|
39
|
+
inset-block: 0;
|
|
40
|
+
inset-inline-start: calc(var(--space-2xs) * 0.5);
|
|
41
|
+
margin: auto;
|
|
42
|
+
width: 2em;
|
|
43
|
+
height: 2em;
|
|
44
|
+
mask-repeat: no-repeat;
|
|
45
|
+
mask-size: contain;
|
|
46
|
+
background-color: var(--alert-border-start-color);
|
|
47
|
+
mask-image: var(--alert-icon);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
&::after {
|
|
51
|
+
content: "";
|
|
52
|
+
print-color-adjust: exact;
|
|
53
|
+
z-index: 1;
|
|
54
|
+
position: absolute;
|
|
55
|
+
inset-block: 0;
|
|
56
|
+
inset-inline-start: calc(var(--space-2xs) * 0.5);
|
|
57
|
+
margin: auto;
|
|
58
|
+
width: 2em;
|
|
59
|
+
height: 2em;
|
|
60
|
+
background-color: #fffe;
|
|
61
|
+
border-radius: var(--radius-full);
|
|
62
|
+
scale: 0.75;
|
|
63
|
+
box-shadow: var(--shadow-s);
|
|
64
|
+
|
|
65
|
+
@media (prefers-color-scheme: dark) {
|
|
66
|
+
background-color: #000e;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
&.error {
|
|
71
|
+
--alert-bg-color: var(--color-red-9);
|
|
72
|
+
--alert-border-start-color: var(--color-red-5);
|
|
73
|
+
--alert-border-end-color: var(--color-red-6);
|
|
74
|
+
--alert-icon: #{utils.svg-to-data-url(
|
|
75
|
+
'<svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 512 512"><path d="M331.3 308.7L278.6 256l52.7-52.7c6.2-6.2 6.2-16.4 0-22.6-6.2-6.2-16.4-6.2-22.6 0L256 233.4l-52.7-52.7c-6.2-6.2-15.6-7.1-22.6 0-7.1 7.1-6 16.6 0 22.6l52.7 52.7-52.7 52.7c-6.7 6.7-6.4 16.3 0 22.6 6.4 6.4 16.4 6.2 22.6 0l52.7-52.7 52.7 52.7c6.2 6.2 16.4 6.2 22.6 0 6.3-6.2 6.3-16.4 0-22.6z" fill="#888888"/><path d="M256 76c48.1 0 93.3 18.7 127.3 52.7S436 207.9 436 256s-18.7 93.3-52.7 127.3S304.1 436 256 436c-48.1 0-93.3-18.7-127.3-52.7S76 304.1 76 256s18.7-93.3 52.7-127.3S207.9 76 256 76m0-28C141.1 48 48 141.1 48 256s93.1 208 208 208 208-93.1 208-208S370.9 48 256 48z" fill="#888888"/></svg>'
|
|
76
|
+
)};
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
&.warning {
|
|
80
|
+
--alert-bg-color: var(--color-yellow-9);
|
|
81
|
+
--alert-border-start-color: var(--color-yellow-5);
|
|
82
|
+
--alert-border-end-color: var(--color-yellow-6);
|
|
83
|
+
--alert-icon: #{utils.svg-to-data-url(
|
|
84
|
+
'<svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 512 512"><path fill="none" stroke="#888888" stroke-miterlimit="10" stroke-width="32" d="M448 256c0-106-86-192-192-192S64 150 64 256s86 192 192 192s192-86 192-192Z"/><path fill="none" stroke="#888888" stroke-linecap="round" stroke-linejoin="round" stroke-width="32" d="M250.26 166.05L256 288l5.73-121.95a5.74 5.74 0 0 0-5.79-6h0a5.74 5.74 0 0 0-5.68 6Z"/><path fill="#888888" d="M256 367.91a20 20 0 1 1 20-20a20 20 0 0 1-20 20Z"/></svg>'
|
|
85
|
+
)};
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
&.success {
|
|
89
|
+
--alert-bg-color: var(--color-green-9);
|
|
90
|
+
--alert-border-start-color: var(--color-green-5);
|
|
91
|
+
--alert-border-end-color: var(--color-green-6);
|
|
92
|
+
--alert-icon: #{utils.svg-to-data-url(
|
|
93
|
+
'<svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 512 512"><path d="M362.6 192.9L345 174.8c-.7-.8-1.8-1.2-2.8-1.2-1.1 0-2.1.4-2.8 1.2l-122 122.9-44.4-44.4c-.8-.8-1.8-1.2-2.8-1.2-1 0-2 .4-2.8 1.2l-17.8 17.8c-1.6 1.6-1.6 4.1 0 5.7l56 56c3.6 3.6 8 5.7 11.7 5.7 5.3 0 9.9-3.9 11.6-5.5h.1l133.7-134.4c1.4-1.7 1.4-4.2-.1-5.7z" fill="#888888"/><path d="M256 76c48.1 0 93.3 18.7 127.3 52.7S436 207.9 436 256s-18.7 93.3-52.7 127.3S304.1 436 256 436c-48.1 0-93.3-18.7-127.3-52.7S76 304.1 76 256s18.7-93.3 52.7-127.3S207.9 76 256 76m0-28C141.1 48 48 141.1 48 256s93.1 208 208 208 208-93.1 208-208S370.9 48 256 48z" fill="#888888"/></svg>'
|
|
94
|
+
)};
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
&.info {
|
|
98
|
+
--alert-bg-color: var(--color-sky-9);
|
|
99
|
+
--alert-border-start-color: var(--color-sky-5);
|
|
100
|
+
--alert-border-end-color: var(--color-sky-6);
|
|
101
|
+
--alert-icon: #{utils.svg-to-data-url(
|
|
102
|
+
'<svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 512 512"><path d="M235.4 172.2c0-11.4 9.3-19.9 20.5-19.9 11.4 0 20.7 8.5 20.7 19.9s-9.3 20-20.7 20c-11.2 0-20.5-8.6-20.5-20zm1.4 35.7H275V352h-38.2V207.9z" fill="#888888"/><path d="M256 76c48.1 0 93.3 18.7 127.3 52.7S436 207.9 436 256s-18.7 93.3-52.7 127.3S304.1 436 256 436c-48.1 0-93.3-18.7-127.3-52.7S76 304.1 76 256s18.7-93.3 52.7-127.3S207.9 76 256 76m0-28C141.1 48 48 141.1 48 256s93.1 208 208 208 208-93.1 208-208S370.9 48 256 48z" fill="#888888"/></svg>'
|
|
103
|
+
)};
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
.alert-title {
|
|
108
|
+
font-family: var(--font-family-heading);
|
|
109
|
+
font-weight: var(--font-weight-bold);
|
|
110
|
+
line-height: 1;
|
|
111
|
+
color: var(--alert-border-start-color);
|
|
112
|
+
font-size: 0.85em;
|
|
113
|
+
margin: 0;
|
|
114
|
+
margin-block-end: 0.15em;
|
|
115
|
+
}
|