@regardio/react 0.7.23 → 0.8.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/dist/button/index.d.mts +2 -2
- package/dist/button/index.mjs +2 -2
- package/dist/button-BllZdqCA.mjs +109 -0
- package/dist/carousel/index.mjs +1 -1
- package/dist/checkbox/index.mjs +12 -17
- package/dist/combobox/index.d.mts +142 -0
- package/dist/combobox/index.mjs +238 -0
- package/dist/field/index.d.mts +2 -2
- package/dist/field/index.mjs +26 -26
- package/dist/fieldset/index.d.mts +2 -2
- package/dist/fieldset/index.mjs +18 -21
- package/dist/icon-button/index.d.mts +1 -1
- package/dist/icon-button/index.mjs +1 -1
- package/dist/index-BTB1biC_.d.mts +19 -0
- package/dist/index-DEHa010W.d.mts +35 -0
- package/dist/input/index.d.mts +1 -1
- package/dist/input/index.mjs +1 -1
- package/dist/input-BHRHF8xW.mjs +62 -0
- package/dist/password-input/index.d.mts +2 -2
- package/dist/password-input/index.mjs +5 -6
- package/dist/radio/index.mjs +12 -17
- package/dist/slider/index.mjs +6 -13
- package/dist/switch/index.mjs +7 -12
- package/dist/text/index.d.mts +6 -3
- package/dist/text/index.mjs +6 -3
- package/dist/toggle/index.mjs +44 -29
- package/package.json +39 -27
- package/src/button/button.test.tsx +12 -8
- package/src/button/button.tsx +50 -59
- package/src/button/index.ts +2 -2
- package/src/checkbox/checkbox.tsx +11 -14
- package/src/combobox/combobox.stories.tsx +137 -0
- package/src/combobox/combobox.tsx +435 -0
- package/src/combobox/index.ts +2 -0
- package/src/field/field.test.tsx +1 -1
- package/src/field/field.tsx +21 -13
- package/src/fieldset/fieldset.test.tsx +1 -1
- package/src/fieldset/fieldset.tsx +6 -6
- package/src/icon-button/icon-button.test.tsx +1 -1
- package/src/input/input.stories.tsx +0 -11
- package/src/input/input.test.tsx +5 -2
- package/src/input/input.tsx +34 -75
- package/src/password-input/password-input.tsx +4 -5
- package/src/radio/radio.tsx +11 -14
- package/src/slider/slider.tsx +6 -8
- package/src/storybook.css +27 -0
- package/src/switch/switch.tsx +6 -11
- package/src/text/text.tsx +6 -3
- package/src/toggle/toggle.test.tsx +1 -2
- package/src/toggle/toggle.tsx +44 -29
- package/dist/button-wigUM1BB.mjs +0 -127
- package/dist/index-B_G_f749.d.mts +0 -29
- package/dist/index-DH3W0i5O.d.mts +0 -35
- package/dist/input-C2SM4-AB.mjs +0 -71
package/dist/input-C2SM4-AB.mjs
DELETED
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
import { tv } from "@regardio/tailwind/utils";
|
|
2
|
-
import { jsx } from "react/jsx-runtime";
|
|
3
|
-
import { Input } from "@base-ui/react/input";
|
|
4
|
-
//#region src/input/input.tsx
|
|
5
|
-
const input = tv({
|
|
6
|
-
base: [
|
|
7
|
-
"w-full",
|
|
8
|
-
"px-3",
|
|
9
|
-
"py-2",
|
|
10
|
-
"border",
|
|
11
|
-
"border-gray-300",
|
|
12
|
-
"rounded-md",
|
|
13
|
-
"bg-white",
|
|
14
|
-
"text-gray-900",
|
|
15
|
-
"placeholder-gray-500",
|
|
16
|
-
"focus:outline-none",
|
|
17
|
-
"focus:ring-2",
|
|
18
|
-
"focus:ring-blue-500",
|
|
19
|
-
"focus:border-blue-500",
|
|
20
|
-
"transition-colors",
|
|
21
|
-
"duration-200"
|
|
22
|
-
],
|
|
23
|
-
defaultVariants: {
|
|
24
|
-
size: "md",
|
|
25
|
-
variant: "default"
|
|
26
|
-
},
|
|
27
|
-
variants: {
|
|
28
|
-
size: {
|
|
29
|
-
lg: [
|
|
30
|
-
"px-4",
|
|
31
|
-
"py-3",
|
|
32
|
-
"text-lg"
|
|
33
|
-
],
|
|
34
|
-
md: [],
|
|
35
|
-
sm: [
|
|
36
|
-
"px-2",
|
|
37
|
-
"py-1",
|
|
38
|
-
"text-sm"
|
|
39
|
-
]
|
|
40
|
-
},
|
|
41
|
-
variant: {
|
|
42
|
-
default: [],
|
|
43
|
-
error: [
|
|
44
|
-
"border-red-300",
|
|
45
|
-
"text-red-900",
|
|
46
|
-
"placeholder-red-500",
|
|
47
|
-
"focus:ring-red-500",
|
|
48
|
-
"focus:border-red-500"
|
|
49
|
-
],
|
|
50
|
-
success: [
|
|
51
|
-
"border-green-300",
|
|
52
|
-
"text-green-900",
|
|
53
|
-
"placeholder-green-500",
|
|
54
|
-
"focus:ring-green-500",
|
|
55
|
-
"focus:border-green-500"
|
|
56
|
-
]
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
});
|
|
60
|
-
const Input$1 = ({ className, variant, size, ...props }) => {
|
|
61
|
-
return /* @__PURE__ */ jsx(Input, {
|
|
62
|
-
className: input({
|
|
63
|
-
className,
|
|
64
|
-
size,
|
|
65
|
-
variant
|
|
66
|
-
}),
|
|
67
|
-
...props
|
|
68
|
-
});
|
|
69
|
-
};
|
|
70
|
-
//#endregion
|
|
71
|
-
export { Input$1 as t };
|