@choice-ui/react 1.7.7 → 1.7.8
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.
|
@@ -12,6 +12,6 @@ export interface IconButtonProps extends Omit<HTMLProps<HTMLElement>, "size" | "
|
|
|
12
12
|
readOnly?: boolean;
|
|
13
13
|
size?: "default" | "large" | "reset";
|
|
14
14
|
tooltip?: TooltipProps;
|
|
15
|
-
variant?: "default" | "secondary" | "solid" | "highlight" | "ghost" | "dark" | "reset";
|
|
15
|
+
variant?: "default" | "secondary" | "solid" | "highlight" | "ghost" | "dark" | "submit" | "reset";
|
|
16
16
|
}
|
|
17
17
|
export declare const IconButton: import('react').ForwardRefExoticComponent<Omit<IconButtonProps, "ref"> & import('react').RefAttributes<HTMLElement>>;
|
|
@@ -21,6 +21,9 @@ export declare const iconButtonTv: import('tailwind-variants').TVReturnType<{
|
|
|
21
21
|
dark: {
|
|
22
22
|
button: string;
|
|
23
23
|
};
|
|
24
|
+
submit: {
|
|
25
|
+
button: string[];
|
|
26
|
+
};
|
|
24
27
|
reset: {};
|
|
25
28
|
};
|
|
26
29
|
active: {
|
|
@@ -68,6 +71,9 @@ export declare const iconButtonTv: import('tailwind-variants').TVReturnType<{
|
|
|
68
71
|
dark: {
|
|
69
72
|
button: string;
|
|
70
73
|
};
|
|
74
|
+
submit: {
|
|
75
|
+
button: string[];
|
|
76
|
+
};
|
|
71
77
|
reset: {};
|
|
72
78
|
};
|
|
73
79
|
active: {
|
|
@@ -115,6 +121,9 @@ export declare const iconButtonTv: import('tailwind-variants').TVReturnType<{
|
|
|
115
121
|
dark: {
|
|
116
122
|
button: string;
|
|
117
123
|
};
|
|
124
|
+
submit: {
|
|
125
|
+
button: string[];
|
|
126
|
+
};
|
|
118
127
|
reset: {};
|
|
119
128
|
};
|
|
120
129
|
active: {
|
|
@@ -23,6 +23,12 @@ const iconButtonTv = tcv({
|
|
|
23
23
|
highlight: {},
|
|
24
24
|
ghost: {},
|
|
25
25
|
dark: { button: "text-white" },
|
|
26
|
+
submit: {
|
|
27
|
+
button: [
|
|
28
|
+
"bg-[var(--theme-submit-btn-bg)] text-[var(--theme-submit-btn-text)]",
|
|
29
|
+
"focus-visible:border-transparent"
|
|
30
|
+
]
|
|
31
|
+
},
|
|
26
32
|
reset: {}
|
|
27
33
|
},
|
|
28
34
|
active: {
|
|
@@ -136,6 +142,29 @@ const iconButtonTv = tcv({
|
|
|
136
142
|
variant: "dark",
|
|
137
143
|
disabled: true,
|
|
138
144
|
class: { button: "text-gray-500" }
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
variant: "submit",
|
|
148
|
+
class: {
|
|
149
|
+
button: "focus-visible:shadow-focus"
|
|
150
|
+
}
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
variant: "submit",
|
|
154
|
+
focused: true,
|
|
155
|
+
class: {
|
|
156
|
+
button: ["shadow-focus", "border-transparent"]
|
|
157
|
+
}
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
variant: "submit",
|
|
161
|
+
loading: true,
|
|
162
|
+
class: { button: "opacity-70" }
|
|
163
|
+
},
|
|
164
|
+
{
|
|
165
|
+
variant: "submit",
|
|
166
|
+
disabled: true,
|
|
167
|
+
class: { button: "opacity-50" }
|
|
139
168
|
}
|
|
140
169
|
],
|
|
141
170
|
defaultVariants: {
|
|
@@ -26,6 +26,9 @@
|
|
|
26
26
|
--animate-spinner-bounce-right: spinner-bounce-right 0.5s infinite alternate ease;
|
|
27
27
|
--animate-indeterminate-bar: indeterminate-bar 1.5s cubic-bezier(0.65, 0.815, 0.735, 0.395)
|
|
28
28
|
infinite normal none running;
|
|
29
|
+
|
|
30
|
+
--theme-submit-btn-bg: var(--default-theme-submit-btn-bg);
|
|
31
|
+
--theme-submit-btn-text: var(--default-theme-submit-btn-text);
|
|
29
32
|
}
|
|
30
33
|
|
|
31
34
|
/* Base styles */
|
|
@@ -654,3 +657,15 @@
|
|
|
654
657
|
}
|
|
655
658
|
}
|
|
656
659
|
}
|
|
660
|
+
|
|
661
|
+
/* Submit button theme variables */
|
|
662
|
+
:root {
|
|
663
|
+
--default-theme-submit-btn-bg: #000;
|
|
664
|
+
--default-theme-submit-btn-text: #fff;
|
|
665
|
+
}
|
|
666
|
+
|
|
667
|
+
.dark,
|
|
668
|
+
.light .dark {
|
|
669
|
+
--default-theme-submit-btn-bg: #fff;
|
|
670
|
+
--default-theme-submit-btn-text: #000;
|
|
671
|
+
}
|
package/package.json
CHANGED