Open History to see the last commit
1@theme inline {
2 @keyframes accordion-down {
3 from {
4 height: 0;
5 }
6 to {
7 height: var(
8 --radix-accordion-content-height,
9 var(--accordion-panel-height, auto)
10 );
11 }
12 }
13β
14 @keyframes accordion-up {
15 from {
16 height: var(
17 --radix-accordion-content-height,
18 var(--accordion-panel-height, auto)
19 );
20 }
21 to {
22 height: 0;
23 }
24 }
25}
26β
27/* Custom variants */
28@custom-variant data-open {
29 &:where([data-state='open']),
30 &:where([data-open]:not([data-open='false'])) {
31 @slot;
32 }
33}
34β
35@custom-variant data-closed {
36 &:where([data-state='closed']),
37 &:where([data-closed]:not([data-closed='false'])) {
38 @slot;
39 }
40}
41β
42@custom-variant data-checked {
43 &:where([data-state='checked']),
44 &:where([data-checked]:not([data-checked='false'])) {
45 @slot;
46 }
47}
48β
49@custom-variant data-unchecked {
50 &:where([data-state='unchecked']),
51 &:where([data-unchecked]:not([data-unchecked='false'])) {
52 @slot;
53 }
54}
55β
56@custom-variant data-selected {
57 &:where([data-selected='true']),
58 &:where([data-selected]:not([data-selected='false'])) {
59 @slot;
60 }
61}
62β
63@custom-variant data-disabled {
64 &:where([data-disabled='true']),
65 &:where([data-disabled]:not([data-disabled='false'])) {
66 @slot;
67 }
68}
69β
70@custom-variant data-active {
71 &:where([data-state='active']),
72 &:where([data-active]:not([data-active='false'])) {
73 @slot;
74 }
75}
76β
77@custom-variant data-horizontal {
78 &:where([data-orientation='horizontal']) {
79 @slot;
80 }
81}
82β
83@custom-variant data-vertical {
84 &:where([data-orientation='vertical']) {
85 @slot;
86 }
87}
88β
89@utility no-scrollbar {
90 -ms-overflow-style: none;
91 scrollbar-width: none;
92β
93 &::-webkit-scrollbar {
94 display: none;
95 }
96}
97β
98/* scroll-fade */
99@property --scroll-fade-t {
100 syntax: '<length-percentage>';
101 inherits: false;
102 initial-value: 0px;
103}
104@property --scroll-fade-b {
105 syntax: '<length-percentage>';
106 inherits: false;
107 initial-value: 0px;
108}
109@property --scroll-fade-s {
110 syntax: '<length-percentage>';
111 inherits: false;
112 initial-value: 0px;
113}
114@property --scroll-fade-e {
115 syntax: '<length-percentage>';
116 inherits: false;
117 initial-value: 0px;
118}
119@property --scroll-fade-mask {
120 syntax: '*';
121 inherits: false;
122}
123β
124@theme inline {
125 @keyframes scroll-fade-reveal-t {
126 from {
127 --scroll-fade-t: 0px;
128 }
129 to {
130 --scroll-fade-t: var(
131 --_scroll-fade-size-t,
132 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
133 );
134 }
135 }
136 @keyframes scroll-fade-reveal-b {
137 from {
138 --scroll-fade-b: var(
139 --_scroll-fade-size-b,
140 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
141 );
142 }
143 to {
144 --scroll-fade-b: 0px;
145 }
146 }
147 @keyframes scroll-fade-reveal-s {
148 from {
149 --scroll-fade-s: 0px;
150 }
151 to {
152 --scroll-fade-s: var(
153 --_scroll-fade-size-s,
154 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
155 );
156 }
157 }
158 @keyframes scroll-fade-reveal-e {
159 from {
160 --scroll-fade-e: var(
161 --_scroll-fade-size-e,
162 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
163 );
164 }
165 to {
166 --scroll-fade-e: 0px;
167 }
168 }
169}
170β
171@utility scroll-fade {
172 --_scroll-fade-size-t: var(
173 --scroll-fade-t-size,
174 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
175 );
176 --_scroll-fade-size-b: var(
177 --scroll-fade-b-size,
178 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
179 );
180 --scroll-fade-block: linear-gradient(
181 to bottom,
182 transparent 0,
183 #000 var(--scroll-fade-t, 0px),
184 #000 calc(100% - var(--scroll-fade-b, 0px)),
185 transparent 100%
186 );
187 -webkit-mask-image: var(--scroll-fade-mask, var(--scroll-fade-block));
188 mask-image: var(--scroll-fade-mask, var(--scroll-fade-block));
189 -webkit-mask-composite: source-in;
190 mask-composite: intersect;
191 -webkit-mask-repeat: no-repeat;
192 mask-repeat: no-repeat;
193β
194 @supports (animation-timeline: scroll()) {
195 animation:
196 scroll-fade-reveal-t 1ms ease-in-out,
197 scroll-fade-reveal-b 1ms ease-in-out;
198 animation-timeline: scroll(self y), scroll(self y);
199 animation-range:
200 0 var(--scroll-fade-reveal, calc(var(--spacing) * 24)),
201 calc(100% - var(--scroll-fade-reveal, calc(var(--spacing) * 24))) 100%;
202 animation-fill-mode: both;
203 }
204β
205 @supports not (animation-timeline: scroll()) {
206 --scroll-fade-t: var(--_scroll-fade-size-t);
207 --scroll-fade-b: var(--_scroll-fade-size-b);
208 }
209}
210β
211@utility scroll-fade-y {
212 --_scroll-fade-size-t: var(
213 --scroll-fade-t-size,
214 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
215 );
216 --_scroll-fade-size-b: var(
217 --scroll-fade-b-size,
218 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
219 );
220 --scroll-fade-block: linear-gradient(
221 to bottom,
222 transparent 0,
223 #000 var(--scroll-fade-t, 0px),
224 #000 calc(100% - var(--scroll-fade-b, 0px)),
225 transparent 100%
226 );
227 -webkit-mask-image: var(--scroll-fade-mask, var(--scroll-fade-block));
228 mask-image: var(--scroll-fade-mask, var(--scroll-fade-block));
229 -webkit-mask-composite: source-in;
230 mask-composite: intersect;
231 -webkit-mask-repeat: no-repeat;
232 mask-repeat: no-repeat;
233β
234 @supports (animation-timeline: scroll()) {
235 animation:
236 scroll-fade-reveal-t 1ms ease-in-out,
237 scroll-fade-reveal-b 1ms ease-in-out;
238 animation-timeline: scroll(self y), scroll(self y);
239 animation-range:
240 0 var(--scroll-fade-reveal, calc(var(--spacing) * 24)),
241 calc(100% - var(--scroll-fade-reveal, calc(var(--spacing) * 24))) 100%;
242 animation-fill-mode: both;
243 }
244β
245 @supports not (animation-timeline: scroll()) {
246 --scroll-fade-t: var(--_scroll-fade-size-t);
247 --scroll-fade-b: var(--_scroll-fade-size-b);
248 }
249}
250β
251@utility scroll-fade-x {
252 --_scroll-fade-size-s: var(
253 --scroll-fade-s-size,
254 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
255 );
256 --_scroll-fade-size-e: var(
257 --scroll-fade-e-size,
258 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
259 );
260 --scroll-fade-inline: linear-gradient(
261 to right,
262 transparent 0,
263 #000 var(--scroll-fade-s, 0px),
264 #000 calc(100% - var(--scroll-fade-e, 0px)),
265 transparent 100%
266 );
267 &:where([dir='rtl'], [dir='rtl'] *) {
268 --scroll-fade-inline: linear-gradient(
269 to left,
270 transparent 0,
271 #000 var(--scroll-fade-s, 0px),
272 #000 calc(100% - var(--scroll-fade-e, 0px)),
273 transparent 100%
274 );
275 }
276 -webkit-mask-image: var(--scroll-fade-mask, var(--scroll-fade-inline));
277 mask-image: var(--scroll-fade-mask, var(--scroll-fade-inline));
278 -webkit-mask-composite: source-in;
279 mask-composite: intersect;
280 -webkit-mask-repeat: no-repeat;
281 mask-repeat: no-repeat;
282β
283 @supports (animation-timeline: scroll()) {
284 animation:
285 scroll-fade-reveal-s 1ms ease-in-out,
286 scroll-fade-reveal-e 1ms ease-in-out;
287 animation-timeline: scroll(self inline), scroll(self inline);
288 animation-range:
289 0 var(--scroll-fade-reveal, calc(var(--spacing) * 24)),
290 calc(100% - var(--scroll-fade-reveal, calc(var(--spacing) * 24))) 100%;
291 animation-fill-mode: both;
292 }
293β
294 @supports not (animation-timeline: scroll()) {
295 --scroll-fade-s: var(--_scroll-fade-size-s);
296 --scroll-fade-e: var(--_scroll-fade-size-e);
297 }
298}
299β
300@utility scroll-fade-t {
301 --_scroll-fade-size-t: var(
302 --scroll-fade-t-size,
303 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
304 );
305 --scroll-fade-mask: linear-gradient(
306 to bottom,
307 transparent 0,
308 #000 var(--scroll-fade-t, 0px),
309 #000 100%
310 );
311 -webkit-mask-image: var(--scroll-fade-mask);
312 mask-image: var(--scroll-fade-mask);
313 -webkit-mask-composite: source-in;
314 mask-composite: intersect;
315 -webkit-mask-repeat: no-repeat;
316 mask-repeat: no-repeat;
317β
318 @supports (animation-timeline: scroll()) {
319 animation: scroll-fade-reveal-t 1ms ease-in-out;
320 animation-timeline: scroll(self y);
321 animation-range: 0 var(--scroll-fade-reveal, calc(var(--spacing) * 24));
322 animation-fill-mode: both;
323 }
324β
325 @supports not (animation-timeline: scroll()) {
326 --scroll-fade-t: var(--_scroll-fade-size-t);
327 }
328}
329β
330@utility scroll-fade-b {
331 --_scroll-fade-size-b: var(
332 --scroll-fade-b-size,
333 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
334 );
335 --scroll-fade-mask: linear-gradient(
336 to bottom,
337 #000 0,
338 #000 calc(100% - var(--scroll-fade-b, 0px)),
339 transparent 100%
340 );
341 -webkit-mask-image: var(--scroll-fade-mask);
342 mask-image: var(--scroll-fade-mask);
343 -webkit-mask-composite: source-in;
344 mask-composite: intersect;
345 -webkit-mask-repeat: no-repeat;
346 mask-repeat: no-repeat;
347β
348 @supports (animation-timeline: scroll()) {
349 animation: scroll-fade-reveal-b 1ms ease-in-out;
350 animation-timeline: scroll(self y);
351 animation-range: calc(
352 100% - var(--scroll-fade-reveal, calc(var(--spacing) * 24))
353 )
354 100%;
355 animation-fill-mode: both;
356 }
357β
358 @supports not (animation-timeline: scroll()) {
359 --scroll-fade-b: var(--_scroll-fade-size-b);
360 }
361}
362β
363@utility scroll-fade-l {
364 --_scroll-fade-size-s: var(
365 --scroll-fade-s-size,
366 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
367 );
368 --scroll-fade-mask: linear-gradient(
369 to right,
370 transparent 0,
371 #000 var(--scroll-fade-s, 0px),
372 #000 100%
373 );
374 -webkit-mask-image: var(--scroll-fade-mask);
375 mask-image: var(--scroll-fade-mask);
376 -webkit-mask-composite: source-in;
377 mask-composite: intersect;
378 -webkit-mask-repeat: no-repeat;
379 mask-repeat: no-repeat;
380β
381 @supports (animation-timeline: scroll()) {
382 animation: scroll-fade-reveal-s 1ms ease-in-out;
383 animation-timeline: scroll(self x);
384 animation-range: 0 var(--scroll-fade-reveal, calc(var(--spacing) * 24));
385 animation-fill-mode: both;
386 }
387β
388 @supports not (animation-timeline: scroll()) {
389 --scroll-fade-s: var(--_scroll-fade-size-s);
390 }
391}
392β
393@utility scroll-fade-r {
394 --_scroll-fade-size-e: var(
395 --scroll-fade-e-size,
396 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
397 );
398 --scroll-fade-mask: linear-gradient(
399 to right,
400 #000 0,
401 #000 calc(100% - var(--scroll-fade-e, 0px)),
402 transparent 100%
403 );
404 -webkit-mask-image: var(--scroll-fade-mask);
405 mask-image: var(--scroll-fade-mask);
406 -webkit-mask-composite: source-in;
407 mask-composite: intersect;
408 -webkit-mask-repeat: no-repeat;
409 mask-repeat: no-repeat;
410β
411 @supports (animation-timeline: scroll()) {
412 animation: scroll-fade-reveal-e 1ms ease-in-out;
413 animation-timeline: scroll(self x);
414 animation-range: calc(
415 100% - var(--scroll-fade-reveal, calc(var(--spacing) * 24))
416 )
417 100%;
418 animation-fill-mode: both;
419 }
420β
421 @supports not (animation-timeline: scroll()) {
422 --scroll-fade-e: var(--_scroll-fade-size-e);
423 }
424}
425β
426@utility scroll-fade-s {
427 --_scroll-fade-size-s: var(
428 --scroll-fade-s-size,
429 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
430 );
431 --scroll-fade-mask: linear-gradient(
432 to right,
433 transparent 0,
434 #000 var(--scroll-fade-s, 0px),
435 #000 100%
436 );
437 &:where([dir='rtl'], [dir='rtl'] *) {
438 --scroll-fade-mask: linear-gradient(
439 to left,
440 transparent 0,
441 #000 var(--scroll-fade-s, 0px),
442 #000 100%
443 );
444 }
445 -webkit-mask-image: var(--scroll-fade-mask);
446 mask-image: var(--scroll-fade-mask);
447 -webkit-mask-composite: source-in;
448 mask-composite: intersect;
449 -webkit-mask-repeat: no-repeat;
450 mask-repeat: no-repeat;
451β
452 @supports (animation-timeline: scroll()) {
453 animation: scroll-fade-reveal-s 1ms ease-in-out;
454 animation-timeline: scroll(self inline);
455 animation-range: 0 var(--scroll-fade-reveal, calc(var(--spacing) * 24));
456 animation-fill-mode: both;
457 }
458β
459 @supports not (animation-timeline: scroll()) {
460 --scroll-fade-s: var(--_scroll-fade-size-s);
461 }
462}
463β
464@utility scroll-fade-e {
465 --_scroll-fade-size-e: var(
466 --scroll-fade-e-size,
467 var(--scroll-fade-size, min(12%, calc(var(--spacing) * 10)))
468 );
469 --scroll-fade-mask: linear-gradient(
470 to right,
471 #000 0,
472 #000 calc(100% - var(--scroll-fade-e, 0px)),
473 transparent 100%
474 );
475 &:where([dir='rtl'], [dir='rtl'] *) {
476 --scroll-fade-mask: linear-gradient(
477 to left,
478 #000 0,
479 #000 calc(100% - var(--scroll-fade-e, 0px)),
480 transparent 100%
481 );
482 }
483 -webkit-mask-image: var(--scroll-fade-mask);
484 mask-image: var(--scroll-fade-mask);
485 -webkit-mask-composite: source-in;
486 mask-composite: intersect;
487 -webkit-mask-repeat: no-repeat;
488 mask-repeat: no-repeat;
489β
490 @supports (animation-timeline: scroll()) {
491 animation: scroll-fade-reveal-e 1ms ease-in-out;
492 animation-timeline: scroll(self inline);
493 animation-range: calc(
494 100% - var(--scroll-fade-reveal, calc(var(--spacing) * 24))
495 )
496 100%;
497 animation-fill-mode: both;
498 }
499β
500 @supports not (animation-timeline: scroll()) {
501 --scroll-fade-e: var(--_scroll-fade-size-e);
502 }
503}
504β
505@utility scroll-fade-* {
506 --scroll-fade-size: calc(var(--spacing) * --value(integer));
507 --scroll-fade-size: --value([length], [percentage]);
508}
509β
510@utility scroll-fade-t-* {
511 --scroll-fade-t-size: calc(var(--spacing) * --value(integer));
512 --scroll-fade-t-size: --value([length], [percentage]);
513}
514β
515@utility scroll-fade-b-* {
516 --scroll-fade-b-size: calc(var(--spacing) * --value(integer));
517 --scroll-fade-b-size: --value([length], [percentage]);
518}
519β
520@utility scroll-fade-s-* {
521 --scroll-fade-s-size: calc(var(--spacing) * --value(integer));
522 --scroll-fade-s-size: --value([length], [percentage]);
523}
524β
525@utility scroll-fade-e-* {
526 --scroll-fade-e-size: calc(var(--spacing) * --value(integer));
527 --scroll-fade-e-size: --value([length], [percentage]);
528}
529β
530@utility scroll-fade-none {
531 --scroll-fade-mask: none;
532}
533β
534/* shimmer */
535@property --shimmer-angle {
536 syntax: '<angle>';
537 inherits: true;
538 initial-value: 20deg;
539}
540@property --shimmer-image {
541 syntax: '*';
542 inherits: false;
543}
544@property --shimmer-text-fill {
545 syntax: '*';
546 inherits: false;
547}
548β
549@theme inline {
550 @keyframes tw-shimmer {
551 from {
552 background-position: 100% 0;
553 }
554 to {
555 background-position: 0 0;
556 }
557 }
558}
559β
560@utility shimmer {
561 --_spread: var(--shimmer-spread, calc(3ch + 40px));
562 --_base: currentColor;
563 --_highlight: var(
564 --shimmer-color,
565 oklch(from currentColor l c h / calc(alpha* 0.2))
566 );
567β
568 background-image: var(
569 --shimmer-image,
570 linear-gradient(
571 calc(90deg + var(--shimmer-angle)),
572 var(--_base) calc(50% - var(--_spread)),
573 color-mix(in oklch, var(--_highlight), var(--_base) 50%)
574 calc(50% - var(--_spread) * 0.5),
575 var(--_highlight) 50%,
576 color-mix(in oklch, var(--_highlight), var(--_base) 50%)
577 calc(50% + var(--_spread) * 0.5),
578 var(--_base) calc(50% + var(--_spread))
579 )
580 );
581 background-repeat: no-repeat;
582 background-size: calc(200% + var(--_spread) * 2) 100%;
583 background-position: 0 0;
584 background-clip: text;
585 -webkit-background-clip: text;
586 -webkit-text-fill-color: var(--shimmer-text-fill, transparent);
587 animation: tw-shimmer var(--shimmer-duration, 2s) linear infinite;
588β
589 @variant dark {
590 --_highlight: var(
591 --shimmer-color,
592 oklch(from currentColor max(0.8, calc(l + 0.4)) c h / calc(alpha + 0.4))
593 );
594 }
595β
596 &:where([dir='rtl'], [dir='rtl'] *) {
597 animation-direction: reverse;
598 }
599}
600β
601@utility shimmer-once {
602 animation-iteration-count: 1;
603}
604β
605@utility shimmer-reverse {
606 animation-direction: reverse;
607}
608β
609@utility shimmer-none {
610 --shimmer-image: none;
611 --shimmer-text-fill: currentColor;
612}
613β
614@utility shimmer-color-* {
615 --shimmer-color: --value(--color, [color]);
616 --shimmer-color: color-mix(
617 in oklch,
618 --value(--color, [color]) calc(--modifier(integer) * 1%),
619 transparent
620 );
621}
622β
623@utility shimmer-duration-* {
624 --shimmer-duration: calc(--value(integer) * 1ms);
625}
626β
627@utility shimmer-spread-* {
628 --shimmer-spread: calc(var(--spacing) * --value(integer));
629 --shimmer-spread: --value([length], [percentage]);
630}
631β
632@utility shimmer-angle-* {
633 --shimmer-angle: calc(--value(integer) * 1deg);
634}
635β
636@media (prefers-reduced-motion: reduce) {
637 .shimmer {
638 animation: none;
639 background-image: none;
640 -webkit-text-fill-color: currentColor;
641 }
642}