|
85 | 85 | default => '',
|
86 | 86 | })
|
87 | 87 | ->add(match ($variant) { // Shadows...
|
88 |
| - 'primary' => 'shadow-[inset_0px_1px_theme(colors.white/.2)]', |
89 |
| - 'danger' => 'shadow-[inset_0px_1px_theme(colors.red.500),inset_0px_2px_theme(colors.white/.15)] dark:shadow-none', |
| 88 | + 'primary' => 'shadow-[inset_0px_1px_--theme(--color-white/.2)]', |
| 89 | + 'danger' => 'shadow-[inset_0px_1px_var(--color-red-500),inset_0px_2px_--theme(--color-white/.15)] dark:shadow-none', |
90 | 90 | 'outline' => match ($size) {
|
91 |
| - 'base' => 'shadow-sm', |
92 |
| - 'sm' => 'shadow-sm', |
| 91 | + 'base' => 'shadow-xs', |
| 92 | + 'sm' => 'shadow-xs', |
93 | 93 | 'xs' => 'shadow-none',
|
94 | 94 | },
|
95 | 95 | default => '',
|
96 | 96 | })
|
97 | 97 | ->add(match ($variant) { // Grouped border treatments...
|
98 | 98 | 'ghost' => '',
|
99 | 99 | 'subtle' => '',
|
100 |
| - 'outline' => '[[data-flux-button-group]_&]:border-l-0 [:is([data-flux-button-group]>&:first-child,_[data-flux-button-group]_:first-child>&)]:border-l-[1px]', |
101 |
| - 'filled' => '[[data-flux-button-group]_&]:border-r [:is([data-flux-button-group]>&:last-child,_[data-flux-button-group]_:last-child>&)]:border-r-0 [[data-flux-button-group]_&]:border-zinc-200/80 [[data-flux-button-group]_&]:dark:border-zinc-900/50', |
102 |
| - 'danger' => '[[data-flux-button-group]_&]:border-r [:is([data-flux-button-group]>&:last-child,_[data-flux-button-group]_:last-child>&)]:border-r-0 [[data-flux-button-group]_&]:border-red-600 [[data-flux-button-group]_&]:dark:border-red-900/25', |
103 |
| - 'primary' => '[[data-flux-button-group]_&]:border-r-0 [:is([data-flux-button-group]>&:last-child,_[data-flux-button-group]_:last-child>&)]:border-r-[1px] dark:[:is([data-flux-button-group]>&:last-child,_[data-flux-button-group]_:last-child>&)]:border-r-0 dark:[:is([data-flux-button-group]>&:last-child,_[data-flux-button-group]_:last-child>&)]:border-l-[1px] [:is([data-flux-button-group]>&:not(:first-child),_[data-flux-button-group]_:not(:first-child)>&)]:border-l-[color-mix(in_srgb,var(--color-accent-foreground),transparent_85%)]', |
| 100 | + 'outline' => 'in-data-flux-button-group:border-l-0 [:is([data-flux-button-group]>&:first-child,_[data-flux-button-group]_:first-child>&)]:border-l-[1px]', |
| 101 | + 'filled' => 'in-data-flux-button-group:border-r [:is([data-flux-button-group]>&:last-child,_[data-flux-button-group]_:last-child>&)]:border-r-0 in-data-flux-button-group:border-zinc-200/80 dark:in-data-flux-button-group:border-zinc-900/50', |
| 102 | + 'danger' => 'in-data-flux-button-group:border-r [:is([data-flux-button-group]>&:last-child,_[data-flux-button-group]_:last-child>&)]:border-r-0 in-data-flux-button-group:border-red-600 dark:in-data-flux-button-group:border-red-900/25', |
| 103 | + 'primary' => 'in-data-flux-button-group:border-r-0 [:is([data-flux-button-group]>&:last-child,_[data-flux-button-group]_:last-child>&)]:border-r-[1px] dark:[:is([data-flux-button-group]>&:last-child,_[data-flux-button-group]_:last-child>&)]:border-r-0 dark:[:is([data-flux-button-group]>&:last-child,_[data-flux-button-group]_:last-child>&)]:border-l-[1px] [:is([data-flux-button-group]>&:not(:first-child),_[data-flux-button-group]_:not(:first-child)>&)]:border-l-[color-mix(in_srgb,var(--color-accent-foreground),transparent_85%)]', |
104 | 104 | })
|
105 | 105 | ->add($loading ? [ // Loading states...
|
106 | 106 | '*:transition-opacity',
|
107 | 107 | $type === 'submit' ? '[&[disabled]>:not([data-flux-loading-indicator])]:opacity-0' : '[&[data-flux-loading]>:not([data-flux-loading-indicator])]:opacity-0',
|
108 | 108 | $type === 'submit' ? '[&[disabled]>[data-flux-loading-indicator]]:opacity-100' : '[&[data-flux-loading]>[data-flux-loading-indicator]]:opacity-100',
|
109 |
| - $type === 'submit' ? '[&[disabled]]:pointer-events-none' : '[&[data-flux-loading]]:pointer-events-none', |
| 109 | + $type === 'submit' ? '[&[disabled]]:pointer-events-none' : 'data-flux-loading:pointer-events-none', |
110 | 110 | ] : [])
|
111 | 111 | ;
|
112 | 112 |
|
|
0 commit comments