bonkers-ui 2.0.8 → 2.0.9
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/README.md +3 -3
- package/assets/UiInputRange.css +1 -1
- package/components/UiAccordion/UiAccordion.context.js +27 -27
- package/components/UiAccordion/UiAccordion.context.js.map +1 -1
- package/components/UiBerRank/UiBerRank.js +87 -90
- package/components/UiBerRank/UiBerRank.js.map +1 -1
- package/components/UiCheckbox/UiCheckbox.js +36 -36
- package/components/UiCheckbox/UiCheckbox.js.map +1 -1
- package/components/UiIconBadge/_types.d.ts +1 -1
- package/components/UiIconBadge/_types.js.map +1 -1
- package/components/UiInput/UiInput.base.js +2 -2
- package/components/UiInput/UiInput.base.js.map +1 -1
- package/components/UiInput/UiInputText.js +1 -1
- package/components/UiInput/UiInputText.js.map +1 -1
- package/components/UiInputRange/UiInputRange.js +66 -51
- package/components/UiInputRange/UiInputRange.js.map +1 -1
- package/components/UiPills/UiPills.js +1 -1
- package/components/UiPills/UiPills.js.map +1 -1
- package/components/UiPlainRadio/UiPlainRadio.js +16 -5
- package/components/UiPlainRadio/UiPlainRadio.js.map +1 -1
- package/components/UiProductCard/UiProductCard.js +1 -1
- package/components/UiProductCard/UiProductCard.js.map +1 -1
- package/components/UiProgress/UiProgress.js +1 -1
- package/components/UiProgress/UiProgress.js.map +1 -1
- package/components/UiRadioFancy/UiRadioFancy.js +2 -2
- package/components/UiRadioFancy/UiRadioFancy.js.map +1 -1
- package/components/UiSelect/UiSelect.js +54 -54
- package/components/UiSelect/UiSelect.js.map +1 -1
- package/components/UiSkeleton/UiSkeleton.js +42 -42
- package/components/UiSkeleton/UiSkeleton.js.map +1 -1
- package/components/UiTable/UiTable.js +9 -9
- package/components/UiTable/UiTable.js.map +1 -1
- package/components/UiTable/UiTableCell.d.ts +1 -0
- package/components/UiTable/UiTableCell.js +17 -9
- package/components/UiTable/UiTableCell.js.map +1 -1
- package/components/UiTable/UiTableRow.d.ts +1 -4
- package/components/UiTable/UiTableRow.js +8 -12
- package/components/UiTable/UiTableRow.js.map +1 -1
- package/components/UiTable/_types.d.ts +0 -3
- package/components/UiTable/_types.js +2 -3
- package/components/UiTable/_types.js.map +1 -1
- package/components/UiTable/index.d.ts +1 -1
- package/components/UiTable/index.js +6 -7
- package/components/UiTabs/UiTabs.js +1 -1
- package/components/UiTabs/UiTabs.js.map +1 -1
- package/components/UiToggle/UiToggle.js +27 -27
- package/components/UiToggle/UiToggle.js.map +1 -1
- package/eslint.config.mjs +33 -1
- package/package.json +21 -20
|
@@ -1,81 +1,96 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import '../../assets/UiInputRange.css';const
|
|
5
|
-
thumb:
|
|
6
|
-
},
|
|
1
|
+
import { jsxs as V, jsx as l } from "react/jsx-runtime";
|
|
2
|
+
import f, { useState as z, useCallback as $, useEffect as T } from "react";
|
|
3
|
+
import x from "classnames";
|
|
4
|
+
import '../../assets/UiInputRange.css';const E = "_thumb_hkko1_18", O = {
|
|
5
|
+
thumb: E
|
|
6
|
+
}, L = ({
|
|
7
7
|
value: s,
|
|
8
|
-
min:
|
|
9
|
-
max:
|
|
10
|
-
step:
|
|
11
|
-
onChangeHandler:
|
|
12
|
-
className:
|
|
13
|
-
...
|
|
8
|
+
min: a,
|
|
9
|
+
max: c,
|
|
10
|
+
step: p,
|
|
11
|
+
onChangeHandler: v,
|
|
12
|
+
className: y,
|
|
13
|
+
...h
|
|
14
14
|
}) => {
|
|
15
|
-
const
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
const t = parseFloat(String(s)),
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
S(() => {
|
|
24
|
-
i();
|
|
15
|
+
const n = f.useRef(null), S = f.useRef(null), d = f.useRef(null), m = M(s, a, c), [g, F] = z(
|
|
16
|
+
`calc(${m}% - ${m * 32 / 100}px)`
|
|
17
|
+
), b = $(() => {
|
|
18
|
+
const t = parseFloat(String(s)), e = parseFloat(String(a)), o = parseFloat(String(c)), r = (t - e) / (o - e) * 100;
|
|
19
|
+
F(`calc(${r}% - ${r * 32 / 100}px)`);
|
|
20
|
+
}, [a, c, s]);
|
|
21
|
+
T(() => {
|
|
22
|
+
b();
|
|
25
23
|
const t = new ResizeObserver(() => {
|
|
26
|
-
|
|
24
|
+
b();
|
|
27
25
|
});
|
|
28
|
-
return
|
|
26
|
+
return n.current && t.observe(n.current), () => {
|
|
29
27
|
t.disconnect();
|
|
30
28
|
};
|
|
31
|
-
}, [
|
|
32
|
-
const
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
29
|
+
}, [b]);
|
|
30
|
+
const k = (t) => {
|
|
31
|
+
const e = +t.target.value;
|
|
32
|
+
if (e === s) return;
|
|
33
|
+
const o = parseFloat(e.toFixed(10));
|
|
34
|
+
v(o);
|
|
35
|
+
}, w = (t) => {
|
|
36
|
+
if (!d.current || !n.current) return;
|
|
37
|
+
const e = d.current.getBoundingClientRect(), o = t.clientX - e.left, r = e.width, i = o / r * 100, u = parseFloat(String(a)), N = parseFloat(String(c)), R = u + i / 100 * (N - u), C = Math.round(R / Number(p)) * Number(p);
|
|
38
|
+
if (n.current) {
|
|
39
|
+
n.current.value = String(C);
|
|
40
|
+
const P = new Event("input", {
|
|
41
|
+
bubbles: !0
|
|
42
|
+
});
|
|
43
|
+
n.current.dispatchEvent(P);
|
|
44
|
+
}
|
|
36
45
|
};
|
|
37
|
-
|
|
46
|
+
function M(t, e, o) {
|
|
47
|
+
const r = parseFloat(String(t)), i = parseFloat(String(e)), u = parseFloat(String(o));
|
|
48
|
+
return (r - i) / (u - i) * 100;
|
|
49
|
+
}
|
|
50
|
+
return /* @__PURE__ */ V(
|
|
38
51
|
"div",
|
|
39
52
|
{
|
|
40
|
-
|
|
53
|
+
ref: d,
|
|
54
|
+
className: x(
|
|
41
55
|
"relative box-content h-xl py-xxs",
|
|
42
|
-
|
|
43
|
-
|
|
56
|
+
h.disabled && "pointer-events-none cursor-default opacity-60",
|
|
57
|
+
y
|
|
44
58
|
),
|
|
59
|
+
onClick: w,
|
|
45
60
|
children: [
|
|
46
|
-
/* @__PURE__ */
|
|
61
|
+
/* @__PURE__ */ l(
|
|
47
62
|
"input",
|
|
48
63
|
{
|
|
49
|
-
...
|
|
50
|
-
ref:
|
|
51
|
-
className: "absolute
|
|
64
|
+
...h,
|
|
65
|
+
ref: n,
|
|
66
|
+
className: "absolute top-0 left-0 size-full cursor-pointer appearance-none bg-transparent",
|
|
52
67
|
style: {
|
|
53
68
|
touchAction: "none"
|
|
54
69
|
},
|
|
55
70
|
type: "range",
|
|
56
|
-
min:
|
|
57
|
-
max:
|
|
58
|
-
step:
|
|
71
|
+
min: a,
|
|
72
|
+
max: c,
|
|
73
|
+
step: p,
|
|
59
74
|
value: s,
|
|
60
|
-
onChange:
|
|
75
|
+
onChange: k,
|
|
61
76
|
onTouchStart: (t) => t.stopPropagation(),
|
|
62
77
|
onTouchMove: (t) => t.stopPropagation()
|
|
63
78
|
}
|
|
64
79
|
),
|
|
65
|
-
/* @__PURE__ */
|
|
80
|
+
/* @__PURE__ */ l("div", { className: "pointer-events-none absolute top-1/2 left-0 h-xxs w-full -translate-y-1/2 overflow-clip rounded-sm bg-secondary-alt", children: /* @__PURE__ */ l(
|
|
66
81
|
"div",
|
|
67
82
|
{
|
|
68
|
-
className: "pointer-events-none absolute
|
|
83
|
+
className: "pointer-events-none absolute top-1/2 left-0 h-xxs -translate-y-1/2 rounded-sm bg-primary-600",
|
|
69
84
|
style: {
|
|
70
|
-
width:
|
|
85
|
+
width: `calc(${g} + 16px)`
|
|
71
86
|
}
|
|
72
87
|
}
|
|
73
88
|
) }),
|
|
74
|
-
/* @__PURE__ */
|
|
89
|
+
/* @__PURE__ */ l(
|
|
75
90
|
"div",
|
|
76
91
|
{
|
|
77
|
-
className:
|
|
78
|
-
|
|
92
|
+
className: x(
|
|
93
|
+
O.thumb,
|
|
79
94
|
"pointer-events-none",
|
|
80
95
|
"absolute",
|
|
81
96
|
"box-content",
|
|
@@ -85,11 +100,11 @@ import '../../assets/UiInputRange.css';const j = "_thumb_hkko1_18", T = {
|
|
|
85
100
|
"bg-white",
|
|
86
101
|
"border-primary-600"
|
|
87
102
|
),
|
|
88
|
-
ref:
|
|
103
|
+
ref: S,
|
|
89
104
|
style: {
|
|
90
|
-
left:
|
|
105
|
+
left: g
|
|
91
106
|
},
|
|
92
|
-
children: /* @__PURE__ */
|
|
107
|
+
children: /* @__PURE__ */ l("div", { className: "absolute top-1/2 left-1/2 size-xxs -translate-x-1/2 -translate-y-1/2 rounded-full bg-primary-600" })
|
|
93
108
|
}
|
|
94
109
|
)
|
|
95
110
|
]
|
|
@@ -97,6 +112,6 @@ import '../../assets/UiInputRange.css';const j = "_thumb_hkko1_18", T = {
|
|
|
97
112
|
);
|
|
98
113
|
};
|
|
99
114
|
export {
|
|
100
|
-
|
|
115
|
+
L as UiInputRange
|
|
101
116
|
};
|
|
102
117
|
//# sourceMappingURL=UiInputRange.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UiInputRange.js","sources":["../../../src/components/UiInputRange/UiInputRange.tsx"],"sourcesContent":["import React, { useState, useEffect, useCallback } from \"react\";\nimport cx from \"classnames\";\nimport styles from \"./UiInputRange.module.css\";\n\nexport type TUiInputRangeProps = {\n\tvalue: number;\n\tmin: string | number;\n\tmax: string | number;\n\tstep: string | number;\n\tonChangeHandler: (value: number) => void;\n\tclassName?: string;\n} & React.HTMLProps<HTMLInputElement>;\n\nexport const UiInputRange: React.FC<TUiInputRangeProps> = ({\n\tvalue,\n\tmin,\n\tmax,\n\tstep,\n\tonChangeHandler,\n\tclassName,\n\t...rest\n}) => {\n\tconst track = React.useRef<HTMLInputElement>(null);\n\tconst thumb = React.useRef<HTMLDivElement>(null);\n\tconst
|
|
1
|
+
{"version":3,"file":"UiInputRange.js","sources":["../../../src/components/UiInputRange/UiInputRange.tsx"],"sourcesContent":["import React, { useState, useEffect, useCallback } from \"react\";\nimport cx from \"classnames\";\nimport styles from \"./UiInputRange.module.css\";\n\nexport type TUiInputRangeProps = {\n\tvalue: number;\n\tmin: string | number;\n\tmax: string | number;\n\tstep: string | number;\n\tonChangeHandler: (value: number) => void;\n\tclassName?: string;\n} & React.HTMLProps<HTMLInputElement>;\n\nexport const UiInputRange: React.FC<TUiInputRangeProps> = ({\n\tvalue,\n\tmin,\n\tmax,\n\tstep,\n\tonChangeHandler,\n\tclassName,\n\t...rest\n}) => {\n\tconst track = React.useRef<HTMLInputElement>(null);\n\tconst thumb = React.useRef<HTMLDivElement>(null);\n\tconst container = React.useRef<HTMLDivElement>(null);\n\n\tconst initialPosition = calculateInitialPosition(value, min, max);\n\tconst [thumbLeft, setThumbLeft] = useState(\n\t\t`calc(${initialPosition}% - ${(initialPosition * 32) / 100}px)`\n\t);\n\n\tconst updatePositions = useCallback(() => {\n\t\tconst numValue = parseFloat(String(value));\n\t\tconst numMin = parseFloat(String(min));\n\t\tconst numMax = parseFloat(String(max));\n\n\t\tconst percentage = ((numValue - numMin) / (numMax - numMin)) * 100;\n\t\tsetThumbLeft(`calc(${percentage}% - ${(percentage * 32) / 100}px)`);\n\t}, [min, max, value]);\n\n\tuseEffect(() => {\n\t\tupdatePositions();\n\n\t\tconst resizeObserver = new ResizeObserver(() => {\n\t\t\tupdatePositions();\n\t\t});\n\n\t\tif (track.current) {\n\t\t\tresizeObserver.observe(track.current);\n\t\t}\n\n\t\treturn () => {\n\t\t\tresizeObserver.disconnect();\n\t\t};\n\t}, [updatePositions]);\n\n\tconst handleOnChange = (e: React.ChangeEvent<HTMLInputElement>) => {\n\t\tconst newValue = +e.target.value;\n\t\tif (newValue === value) return;\n\t\tconst preciseValue = parseFloat(newValue.toFixed(10));\n\t\tonChangeHandler(preciseValue);\n\t};\n\n\tconst handleTrackClick = (e: React.MouseEvent<HTMLDivElement>) => {\n\t\tif (!container.current || !track.current) return;\n\n\t\tconst rect = container.current.getBoundingClientRect();\n\t\tconst clickPosition = e.clientX - rect.left;\n\t\tconst trackWidth = rect.width;\n\t\tconst percentage = (clickPosition / trackWidth) * 100;\n\n\t\tconst numMin = parseFloat(String(min));\n\t\tconst numMax = parseFloat(String(max));\n\t\tconst newValue = numMin + (percentage / 100) * (numMax - numMin);\n\n\t\tconst steppedValue = Math.round(newValue / Number(step)) * Number(step);\n\n\t\tif (track.current) {\n\t\t\ttrack.current.value = String(steppedValue);\n\t\t\tconst event = new Event(\"input\", {\n\t\t\t\tbubbles: true\n\t\t\t});\n\t\t\ttrack.current.dispatchEvent(event);\n\t\t}\n\t};\n\n\tfunction calculateInitialPosition(value: number, min: string | number, max: string | number) {\n\t\tconst numValue = parseFloat(String(value));\n\t\tconst numMin = parseFloat(String(min));\n\t\tconst numMax = parseFloat(String(max));\n\n\t\treturn ((numValue - numMin) / (numMax - numMin)) * 100;\n\t}\n\n\treturn (\n\t\t<div\n\t\t\tref={ container }\n\t\t\tclassName={ cx(\n\t\t\t\t\"relative box-content h-xl py-xxs\",\n\t\t\t\trest.disabled && \"pointer-events-none cursor-default opacity-60\",\n\t\t\t\tclassName\n\t\t\t) }\n\t\t\tonClick={ handleTrackClick }\n\t\t>\n\t\t\t<input\n\t\t\t\t{ ...rest }\n\t\t\t\tref={ track }\n\t\t\t\tclassName=\"absolute top-0 left-0 size-full cursor-pointer appearance-none bg-transparent\"\n\t\t\t\tstyle={ {\n\t\t\t\t\ttouchAction: \"none\",\n\t\t\t\t} }\n\t\t\t\ttype=\"range\"\n\t\t\t\tmin={ min }\n\t\t\t\tmax={ max }\n\t\t\t\tstep={ step }\n\t\t\t\tvalue={ value }\n\t\t\t\tonChange={ handleOnChange }\n\t\t\t\tonTouchStart={ (e) => e.stopPropagation() }\n\t\t\t\tonTouchMove={ (e) => e.stopPropagation() }\n\t\t\t/>\n\n\t\t\t<div className=\"pointer-events-none absolute top-1/2 left-0 h-xxs w-full -translate-y-1/2 overflow-clip rounded-sm bg-secondary-alt\">\n\t\t\t\t<div\n\t\t\t\t\tclassName=\"pointer-events-none absolute top-1/2 left-0 h-xxs -translate-y-1/2 rounded-sm bg-primary-600\"\n\t\t\t\t\tstyle={ {\n\t\t\t\t\t\twidth: `calc(${thumbLeft} + 16px)`,\n\t\t\t\t\t} }\n\t\t\t\t/>\n\t\t\t</div>\n\t\t\t<div\n\t\t\t\tclassName={ cx(\n\t\t\t\t\tstyles.thumb,\n\t\t\t\t\t\"pointer-events-none\",\n\t\t\t\t\t\"absolute\",\n\t\t\t\t\t\"box-content\",\n\t\t\t\t\t\"size-md\",\n\t\t\t\t\t\"-translate-y-1/2\",\n\t\t\t\t\t\"rounded-full\",\n\t\t\t\t\t\"bg-white\",\n\t\t\t\t\t\"border-primary-600\",\n\t\t\t\t) }\n\t\t\t\tref={ thumb }\n\t\t\t\tstyle={ {\n\t\t\t\t\tleft: thumbLeft,\n\t\t\t\t} }\n\t\t\t>\n\t\t\t\t<div className=\"absolute top-1/2 left-1/2 size-xxs -translate-x-1/2 -translate-y-1/2 rounded-full bg-primary-600\" />\n\t\t\t</div>\n\t\t</div>\n\t);\n};\n"],"names":["UiInputRange","value","min","max","step","onChangeHandler","className","rest","track","React","thumb","container","initialPosition","calculateInitialPosition","thumbLeft","setThumbLeft","useState","updatePositions","useCallback","numValue","numMin","numMax","percentage","useEffect","resizeObserver","handleOnChange","e","newValue","preciseValue","handleTrackClick","rect","clickPosition","trackWidth","steppedValue","event","jsxs","cx","jsx","styles"],"mappings":"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"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UiPills.js","sources":["../../../src/components/UiPills/UiPills.tsx"],"sourcesContent":["import React from \"react\";\nimport { EBadgeKind, EBadgeSize } from \"./_types.ts\";\nimport { ETextWeight, ETypographySizes, UiTypography } from \"../UiTypography\";\nimport cx from \"classnames\";\n\ninterface IUiPills {\n\tchildren: React.ReactNode\n\tkind?: EBadgeKind,\n\tsize?: EBadgeSize,\n\ticon?: React.ReactNode,\n\trounded?: boolean,\n\tclassName?: string\n}\n\nconst kindClasses = {\n\t[EBadgeKind.PRIMARY]: \"bg-primary-100 text-primary-700\",\n\t[EBadgeKind.ERROR]: \"bg-error-300 text-error-700\",\n\t[EBadgeKind.WARNING]: \"bg-warning-300 text-warning-700\",\n\t[EBadgeKind.ACCENT]: \"bg-accent-300 text-accent-700\",\n\t[EBadgeKind.PRIMARY_ALT]: \"bg-primary-300 text-primary-800\",\n\t[EBadgeKind.SECONDARY]: \"bg-white text-secondary-300 ring-1 ring-secondary-alt-300\",\n\t[EBadgeKind.ACCENT_ALT]: \"bg-accent-alt-500 text-secondary-700\",\n};\n\nconst sizeEnums = {\n\t[EBadgeSize.SMALL]: ETypographySizes.XXS,\n\t[EBadgeSize.MEDIUM]: ETypographySizes.XS,\n\t[EBadgeSize.LARGE]: ETypographySizes.SM,\n};\n\nexport const UiPills: React.FC<IUiPills> = ({\n\tchildren,\n\tkind = EBadgeKind.PRIMARY,\n\tsize = EBadgeSize.SMALL,\n\tclassName,\n\ticon,\n\trounded = false\n}) => {\n\treturn (\n\t\t<div className={ cx(\n\t\t\t\"ui-pills\",\n\t\t\t\"grid grid-flow-col justify-start
|
|
1
|
+
{"version":3,"file":"UiPills.js","sources":["../../../src/components/UiPills/UiPills.tsx"],"sourcesContent":["import React from \"react\";\nimport { EBadgeKind, EBadgeSize } from \"./_types.ts\";\nimport { ETextWeight, ETypographySizes, UiTypography } from \"../UiTypography\";\nimport cx from \"classnames\";\n\ninterface IUiPills {\n\tchildren: React.ReactNode\n\tkind?: EBadgeKind,\n\tsize?: EBadgeSize,\n\ticon?: React.ReactNode,\n\trounded?: boolean,\n\tclassName?: string\n}\n\nconst kindClasses = {\n\t[EBadgeKind.PRIMARY]: \"bg-primary-100 text-primary-700\",\n\t[EBadgeKind.ERROR]: \"bg-error-300 text-error-700\",\n\t[EBadgeKind.WARNING]: \"bg-warning-300 text-warning-700\",\n\t[EBadgeKind.ACCENT]: \"bg-accent-300 text-accent-700\",\n\t[EBadgeKind.PRIMARY_ALT]: \"bg-primary-300 text-primary-800\",\n\t[EBadgeKind.SECONDARY]: \"bg-white text-secondary-300 ring-1 ring-secondary-alt-300\",\n\t[EBadgeKind.ACCENT_ALT]: \"bg-accent-alt-500 text-secondary-700\",\n};\n\nconst sizeEnums = {\n\t[EBadgeSize.SMALL]: ETypographySizes.XXS,\n\t[EBadgeSize.MEDIUM]: ETypographySizes.XS,\n\t[EBadgeSize.LARGE]: ETypographySizes.SM,\n};\n\nexport const UiPills: React.FC<IUiPills> = ({\n\tchildren,\n\tkind = EBadgeKind.PRIMARY,\n\tsize = EBadgeSize.SMALL,\n\tclassName,\n\ticon,\n\trounded = false\n}) => {\n\treturn (\n\t\t<div className={ cx(\n\t\t\t\"ui-pills\",\n\t\t\t\"grid w-max grid-flow-col justify-start\",\n\t\t\t\"items-center\",\n\t\t\t\"gap-xxxs\",\n\t\t\t\"px-xxs py-xxxs\",\n\t\t\t\"overflow-hidden\",\n\t\t\trounded\n\t\t\t\t? \"rounded-full\"\n\t\t\t\t: \"rounded-sm\",\n\t\t\tkindClasses[kind],\n\t\t\tclassName\n\t\t) }>\n\t\t\t{ icon }\n\t\t\t{ children\n\t\t\t\t? (\n\t\t\t\t\t<UiTypography size={ sizeEnums[size] } weight={ ETextWeight.SEMI_BOLD } className=\"whitespace-nowrap\">\n\t\t\t\t\t\t{ children }\n\t\t\t\t\t</UiTypography>\n\t\t\t\t)\n\t\t\t\t: null }\n\t\t</div>\n\t);\n};\n"],"names":["kindClasses","EBadgeKind","sizeEnums","EBadgeSize","ETypographySizes","UiPills","children","kind","size","className","icon","rounded","jsxs","cx","jsx","UiTypography","ETextWeight"],"mappings":";;;;;;AAcA,MAAMA,IAAc;AAAA,EACnB,CAACC,EAAW,OAAO,GAAG;AAAA,EACtB,CAACA,EAAW,KAAK,GAAG;AAAA,EACpB,CAACA,EAAW,OAAO,GAAG;AAAA,EACtB,CAACA,EAAW,MAAM,GAAG;AAAA,EACrB,CAACA,EAAW,WAAW,GAAG;AAAA,EAC1B,CAACA,EAAW,SAAS,GAAG;AAAA,EACxB,CAACA,EAAW,UAAU,GAAG;AAC1B,GAEMC,IAAY;AAAA,EACjB,CAACC,EAAW,KAAK,GAAGC,EAAiB;AAAA,EACrC,CAACD,EAAW,MAAM,GAAGC,EAAiB;AAAA,EACtC,CAACD,EAAW,KAAK,GAAGC,EAAiB;AACtC,GAEaC,IAA8B,CAAC;AAAA,EAC3C,UAAAC;AAAA,EACA,MAAAC,IAAON,EAAW;AAAA,EAClB,MAAAO,IAAOL,EAAW;AAAA,EAClB,WAAAM;AAAA,EACA,MAAAC;AAAA,EACA,SAAAC,IAAU;AACX,MAEE,gBAAAC,EAAC,SAAI,WAAYC;AAAA,EAChB;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACAF,IACG,iBACA;AAAA,EACHX,EAAYO,CAAI;AAAA,EAChBE;AAEE,GAAA,UAAA;AAAA,EAAAC;AAAA,EACAJ,IAEA,gBAAAQ,EAACC,GAAa,EAAA,MAAOb,EAAUM,CAAI,GAAI,QAASQ,EAAY,WAAY,WAAU,qBAC/E,UAAAV,EACH,CAAA,IAEC;AAAA,GACJ;"}
|
|
@@ -29,7 +29,7 @@ const v = ({
|
|
|
29
29
|
"input",
|
|
30
30
|
{
|
|
31
31
|
className: i(
|
|
32
|
-
"
|
|
32
|
+
"absolute",
|
|
33
33
|
"appearance-none",
|
|
34
34
|
"peer"
|
|
35
35
|
),
|
|
@@ -61,7 +61,11 @@ const v = ({
|
|
|
61
61
|
"rounded-xl",
|
|
62
62
|
"size-full",
|
|
63
63
|
"text-sm",
|
|
64
|
-
r ? "ring-secondary-alt-300" :
|
|
64
|
+
r ? "ring-secondary-alt-300" : `
|
|
65
|
+
peer-checked:ring-primary-600
|
|
66
|
+
peer-checked:outline
|
|
67
|
+
peer-checked:outline-primary-600
|
|
68
|
+
`,
|
|
65
69
|
e ? "ring-2" : "ring",
|
|
66
70
|
{
|
|
67
71
|
"ring-secondary-alt-600 hover:ring-secondary-500": !r && !e
|
|
@@ -79,7 +83,7 @@ const v = ({
|
|
|
79
83
|
e ? "ring-2" : "ring",
|
|
80
84
|
r ? "ring-secondary-alt-300" : "ring-primary-600",
|
|
81
85
|
{
|
|
82
|
-
"ring-secondary-alt-600 group-hover:ring-secondary-500
|
|
86
|
+
"ring-secondary-alt-600 group-hover:ring-secondary-500 group-active:ring-secondary-500": !r && !e
|
|
83
87
|
}
|
|
84
88
|
), children: /* @__PURE__ */ n(
|
|
85
89
|
"span",
|
|
@@ -102,9 +106,16 @@ const v = ({
|
|
|
102
106
|
)
|
|
103
107
|
}
|
|
104
108
|
) }),
|
|
105
|
-
/* @__PURE__ */ a("div", { className:
|
|
109
|
+
/* @__PURE__ */ a("div", { className: `
|
|
110
|
+
flex
|
|
111
|
+
flex-col
|
|
112
|
+
`, children: [
|
|
106
113
|
s,
|
|
107
|
-
t ? /* @__PURE__ */ n("div", { className:
|
|
114
|
+
t ? /* @__PURE__ */ n("div", { className: `
|
|
115
|
+
text-xs
|
|
116
|
+
font-normal
|
|
117
|
+
text-secondary-alt-400
|
|
118
|
+
`, children: t }) : null
|
|
108
119
|
] })
|
|
109
120
|
]
|
|
110
121
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UiPlainRadio.js","sources":["../../../src/components/UiPlainRadio/UiPlainRadio.tsx"],"sourcesContent":["import React from \"react\";\nimport cx from \"classnames\";\n\nexport type TUiPlainRadio = {\n\tchildren?: React.ReactNode\n\tdisabled?: boolean;\n\tsubHeader?: string;\n\tvalue: string;\n\tname: string;\n\tclassName?: string\n\tchecked?: boolean\n\tonChange: (value: string) => void;\n\n} & Omit<React.InputHTMLAttributes<HTMLInputElement>, \"onChange\" | \"checked\" | \"value\" | \"name\">;\n\nexport const UiPlainRadio: React.FC<TUiPlainRadio> = ({\n\tid,\n\tchildren,\n\tdisabled,\n\tsubHeader,\n\tvalue,\n\tname,\n\tchecked = false,\n\tclassName,\n\tonChange,\n\t...rest\n\n}) => {\n\n\treturn (\n\t\t<label className={ cx(\n\t\t\t\"ui-plain-radio\",\n\t\t\t\"relative\",\n\t\t\t\"group\",\n\t\t\t{\n\t\t\t\t\"pointer-events-none opacity-50\": disabled\n\t\t\t},\n\t\t\tclassName\n\t\t) }\n\t\t>\n\t\t\t<input className={ cx(\n\t\t\t\t\"
|
|
1
|
+
{"version":3,"file":"UiPlainRadio.js","sources":["../../../src/components/UiPlainRadio/UiPlainRadio.tsx"],"sourcesContent":["import React from \"react\";\nimport cx from \"classnames\";\n\nexport type TUiPlainRadio = {\n\tchildren?: React.ReactNode\n\tdisabled?: boolean;\n\tsubHeader?: string;\n\tvalue: string;\n\tname: string;\n\tclassName?: string\n\tchecked?: boolean\n\tonChange: (value: string) => void;\n\n} & Omit<React.InputHTMLAttributes<HTMLInputElement>, \"onChange\" | \"checked\" | \"value\" | \"name\">;\n\nexport const UiPlainRadio: React.FC<TUiPlainRadio> = ({\n\tid,\n\tchildren,\n\tdisabled,\n\tsubHeader,\n\tvalue,\n\tname,\n\tchecked = false,\n\tclassName,\n\tonChange,\n\t...rest\n\n}) => {\n\n\treturn (\n\t\t<label className={ cx(\n\t\t\t\"ui-plain-radio\",\n\t\t\t\"relative\",\n\t\t\t\"group\",\n\t\t\t{\n\t\t\t\t\"pointer-events-none opacity-50\": disabled\n\t\t\t},\n\t\t\tclassName\n\t\t) }\n\t\t>\n\t\t\t<input className={ cx(\n\t\t\t\t\"absolute\",\n\t\t\t\t\"appearance-none\",\n\t\t\t\t\"peer\",\n\t\t\t) }\n\t\t\tid={ id || `${name}-${value}` }\n\t\t\ttype=\"radio\"\n\t\t\tvalue={ value }\n\t\t\tchecked={ checked }\n\t\t\tonChange={ () => onChange(value) }\n\t\t\t{ ...rest }\n\t\t\t/>\n\n\t\t\t<div className={ cx(\n\t\t\t\t\"bg-white\",\n\t\t\t\t\"box-border\",\n\t\t\t\t\"cursor-pointer\",\n\t\t\t\t\"flex\",\n\t\t\t\t\"gap-sm\",\n\t\t\t\t\"items-center\",\n\t\t\t\t\"p-sm\",\n\t\t\t\t\"peer-active:bg-secondary-alt-200\",\n\t\t\t\t\"peer-active:ring-primary-800\",\n\t\t\t\t\"peer-focus-within:outline-offset-4\",\n\t\t\t\t\"peer-focus:outline-2\",\n\t\t\t\t\"peer-focus:peer-checked:outline-primary-600\",\n\t\t\t\t\"peer-hover:ring-primary-700\",\n\t\t\t\t\"rounded-xl\",\n\t\t\t\t\"size-full\",\n\t\t\t\t\"text-sm\",\n\t\t\t\tdisabled\n\t\t\t\t\t? \"ring-secondary-alt-300\"\n\t\t\t\t\t: `\n\t\t\t\t\t\tpeer-checked:ring-primary-600\n\t\t\t\t\t\tpeer-checked:outline\n\t\t\t\t\t\tpeer-checked:outline-primary-600\n\t\t\t\t\t`,\n\t\t\t\tchecked\n\t\t\t\t\t? \"ring-2\"\n\t\t\t\t\t: \"ring\",\n\t\t\t\t{\n\t\t\t\t\t\"ring-secondary-alt-600 hover:ring-secondary-500\": !disabled && !checked,\n\t\t\t\t}\n\n\t\t\t) }\n\t\t\t>\n\n\t\t\t\t<span className={ cx(\n\t\t\t\t\t\"bg-white\",\n\t\t\t\t\t\"group-active:ring-primary-800\",\n\t\t\t\t\t\"group-hover:ring-primary-700\",\n\t\t\t\t\t\"pointer-events-none\",\n\t\t\t\t\t\"relative\",\n\t\t\t\t\t\"rounded-full\",\n\t\t\t\t\t\"size-md\",\n\t\t\t\t\tchecked\n\t\t\t\t\t\t? \"ring-2\"\n\t\t\t\t\t\t: \"ring\",\n\t\t\t\t\tdisabled\n\t\t\t\t\t\t? \"ring-secondary-alt-300\"\n\t\t\t\t\t\t: \"ring-primary-600\",\n\n\t\t\t\t\t{\n\t\t\t\t\t\t\"ring-secondary-alt-600 group-hover:ring-secondary-500 group-active:ring-secondary-500\": !disabled && !checked,\n\t\t\t\t\t}\n\n\t\t\t\t) }>\n\t\t\t\t\t<span\n\t\t\t\t\t\tclassName={ cx(\n\t\t\t\t\t\t\t\"absolute\",\n\t\t\t\t\t\t\t\"block\",\n\t\t\t\t\t\t\t\"group-active:bg-primary-800\",\n\t\t\t\t\t\t\t\"group-hover:bg-primary-700\",\n\t\t\t\t\t\t\t\"left-xxs\",\n\t\t\t\t\t\t\t\"pointer-events-none\",\n\t\t\t\t\t\t\t\"rounded-full\",\n\t\t\t\t\t\t\t\"size-xxs\",\n\t\t\t\t\t\t\t\"top-xxs\",\n\t\t\t\t\t\t\tchecked\n\t\t\t\t\t\t\t\t? \"bg-primary-600\"\n\t\t\t\t\t\t\t\t: \"bg-white\",\n\t\t\t\t\t\t\tdisabled\n\t\t\t\t\t\t\t\t? \"bg-secondary-alt-300\"\n\t\t\t\t\t\t\t\t: \"bg-primary-600\",\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\"bg-white group-hover:bg-white group-active:bg-white\": !disabled && !checked,\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t) }/>\n\n\t\t\t\t</span>\n\n\t\t\t\t<div className={ `\n\t\t\t\t\tflex\n\t\t\t\t\tflex-col\n\t\t\t\t` }>\n\t\t\t\t\t{ children }\n\n\t\t\t\t\t{\n\t\t\t\t\t\tsubHeader\n\t\t\t\t\t\t\t? <div className={ `\n\t\t\t\t\t\t\t\ttext-xs\n\t\t\t\t\t\t\t\tfont-normal\n\t\t\t\t\t\t\t\ttext-secondary-alt-400\n\t\t\t\t\t\t\t` }>{ subHeader }</div>\n\t\t\t\t\t\t\t: null\n\t\t\t\t\t}\n\n\t\t\t\t</div>\n\n\t\t\t</div>\n\n\t\t</label>\n\n\t);\n};\n"],"names":["UiPlainRadio","id","children","disabled","subHeader","value","name","checked","className","onChange","rest","jsxs","cx","jsx"],"mappings":";;;AAeO,MAAMA,IAAwC,CAAC;AAAA,EACrD,IAAAC;AAAA,EACA,UAAAC;AAAA,EACA,UAAAC;AAAA,EACA,WAAAC;AAAA,EACA,OAAAC;AAAA,EACA,MAAAC;AAAA,EACA,SAAAC,IAAU;AAAA,EACV,WAAAC;AAAA,EACA,UAAAC;AAAA,EACA,GAAGC;AAEJ,MAGE,gBAAAC;AAAA,EAAC;AAAA,EAAA;AAAA,IAAM,WAAYC;AAAA,MAClB;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,QACC,kCAAkCT;AAAA,MACnC;AAAA,MACAK;AAAA,IACD;AAAA,IAEC,UAAA;AAAA,MAAA,gBAAAK;AAAA,QAAC;AAAA,QAAA;AAAA,UAAM,WAAYD;AAAA,YAClB;AAAA,YACA;AAAA,YACA;AAAA,UACD;AAAA,UACA,IAAKX,KAAO,GAAGK,CAAI,IAAID,CAAK;AAAA,UAC5B,MAAK;AAAA,UACL,OAAAA;AAAA,UACA,SAAAE;AAAA,UACA,UAAW,MAAME,EAASJ,CAAK;AAAA,UAC7B,GAAGK;AAAA,QAAA;AAAA,MACL;AAAA,MAEA,gBAAAC;AAAA,QAAC;AAAA,QAAA;AAAA,UAAI,WAAYC;AAAA,YAChB;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACAT,IACG,2BACA;AAAA;AAAA;AAAA;AAAA;AAAA,YAKHI,IACG,WACA;AAAA,YACH;AAAA,cACC,mDAAmD,CAACJ,KAAY,CAACI;AAAA,YAAA;AAAA,UAGnE;AAAA,UAGC,UAAA;AAAA,YAAA,gBAAAM,EAAC,UAAK,WAAYD;AAAA,cACjB;AAAA,cACA;AAAA,cACA;AAAA,cACA;AAAA,cACA;AAAA,cACA;AAAA,cACA;AAAA,cACAL,IACG,WACA;AAAA,cACHJ,IACG,2BACA;AAAA,cAEH;AAAA,gBACC,yFAAyF,CAACA,KAAY,CAACI;AAAA,cAAA;AAAA,YAIxG,GAAA,UAAA,gBAAAM;AAAA,cAAC;AAAA,cAAA;AAAA,gBACA,WAAYD;AAAA,kBACX;AAAA,kBACA;AAAA,kBACA;AAAA,kBACA;AAAA,kBACA;AAAA,kBACA;AAAA,kBACA;AAAA,kBACA;AAAA,kBACA;AAAA,kBACAL,IACG,mBACA;AAAA,kBACHJ,IACG,yBACA;AAAA,kBACH;AAAA,oBACC,uDAAuD,CAACA,KAAY,CAACI;AAAA,kBAAA;AAAA,gBACtE;AAAA,cAED;AAAA,YAAA,GAEF;AAAA,YAEA,gBAAAI,EAAC,SAAI,WAAY;AAAA;AAAA;AAAA,OAId,UAAA;AAAA,cAAAT;AAAA,cAGDE,IACI,gBAAAS,EAAA,OAAA,EAAI,WAAY;AAAA;AAAA;AAAA;AAAA,UAIb,aAAW,IACf;AAAA,YAAA,EAGL,CAAA;AAAA,UAAA;AAAA,QAAA;AAAA,MAAA;AAAA,IAED;AAAA,EAAA;AAED;"}
|
|
@@ -17,7 +17,7 @@ const A = ({
|
|
|
17
17
|
"px-xs py-sm",
|
|
18
18
|
p
|
|
19
19
|
), children: [
|
|
20
|
-
i && /* @__PURE__ */ r("div", { className: "absolute
|
|
20
|
+
i && /* @__PURE__ */ r("div", { className: "absolute -top-xxs right-xs", children: /* @__PURE__ */ r(a, { rounded: !0, kind: c.ACCENT_ALT, children: i }) }),
|
|
21
21
|
n,
|
|
22
22
|
/* @__PURE__ */ e("div", { className: "grid gap-xxs", children: [
|
|
23
23
|
/* @__PURE__ */ r(
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UiProductCard.js","sources":["../../../src/components/UiProductCard/UiProductCard.tsx"],"sourcesContent":["import React from \"react\";\nimport { EBadgeKind, UiPills } from \"../UiPills\";\nimport {\n\tUiTypography, ETypographySizes, ETextWeight, ETextAlign, EColors\n} from \"../UiTypography\";\nimport cx from \"classnames\";\n\ntype TUiProductCardProps = {\n\tbadgeText?: string;\n\ttitle?: React.ReactNode;\n\tsubtitle?: React.ReactNode;\n\theader?: React.ReactNode;\n\tclassName?: string;\n}\n\nexport const UiProductCard: React.FC<TUiProductCardProps> = ({\n\tbadgeText,\n\ttitle,\n\tsubtitle,\n\theader,\n\tclassName\n}) => {\n\treturn (\n\t\t<div className={ cx(\n\t\t\t\"relative flex flex-col gap-sm rounded-2xl border border-secondary-alt-500 bg-white\",\n\t\t\t\"px-xs py-sm\",\n\t\t\tclassName\n\t\t) }>\n\n\t\t\t{ badgeText && (\n\t\t\t\t<div className=\"absolute
|
|
1
|
+
{"version":3,"file":"UiProductCard.js","sources":["../../../src/components/UiProductCard/UiProductCard.tsx"],"sourcesContent":["import React from \"react\";\nimport { EBadgeKind, UiPills } from \"../UiPills\";\nimport {\n\tUiTypography, ETypographySizes, ETextWeight, ETextAlign, EColors\n} from \"../UiTypography\";\nimport cx from \"classnames\";\n\ntype TUiProductCardProps = {\n\tbadgeText?: string;\n\ttitle?: React.ReactNode;\n\tsubtitle?: React.ReactNode;\n\theader?: React.ReactNode;\n\tclassName?: string;\n}\n\nexport const UiProductCard: React.FC<TUiProductCardProps> = ({\n\tbadgeText,\n\ttitle,\n\tsubtitle,\n\theader,\n\tclassName\n}) => {\n\treturn (\n\t\t<div className={ cx(\n\t\t\t\"relative flex flex-col gap-sm rounded-2xl border border-secondary-alt-500 bg-white\",\n\t\t\t\"px-xs py-sm\",\n\t\t\tclassName\n\t\t) }>\n\n\t\t\t{ badgeText && (\n\t\t\t\t<div className=\"absolute -top-xxs right-xs\">\n\t\t\t\t\t<UiPills rounded kind={ EBadgeKind.ACCENT_ALT }>{ badgeText }</UiPills>\n\t\t\t\t</div>\n\t\t\t) }\n\n\t\t\t{ header }\n\n\t\t\t<div className=\"grid gap-xxs\">\n\t\t\t\t<UiTypography\n\t\t\t\t\tsize={ ETypographySizes.MD }\n\t\t\t\t\tweight={ ETextWeight.BOLD }\n\t\t\t\t\talign={ ETextAlign.LEFT }\n\t\t\t\t\tcolor={ EColors.SECONDARY }\n\t\t\t\t\tlineHeight\n\t\t\t\t>\n\t\t\t\t\t{ title }\n\t\t\t\t</UiTypography>\n\n\t\t\t\t<UiTypography\n\t\t\t\t\tsize={ ETypographySizes.XS }\n\t\t\t\t\talign={ ETextAlign.LEFT }\n\t\t\t\t\tcolor={ EColors.SECONDARY_400 }\n\t\t\t\t\tlineHeight\n\t\t\t\t>\n\t\t\t\t\t{ subtitle }\n\t\t\t\t</UiTypography>\n\t\t\t</div>\n\t\t</div >\n\t);\n};\n"],"names":["UiProductCard","badgeText","title","subtitle","header","className","jsxs","cx","jsx","UiPills","EBadgeKind","UiTypography","ETypographySizes","ETextWeight","ETextAlign","EColors"],"mappings":";;;;;;;;AAeO,MAAMA,IAA+C,CAAC;AAAA,EAC5D,WAAAC;AAAA,EACA,OAAAC;AAAA,EACA,UAAAC;AAAA,EACA,QAAAC;AAAA,EACA,WAAAC;AACD,MAEE,gBAAAC,EAAC,SAAI,WAAYC;AAAA,EAChB;AAAA,EACA;AAAA,EACAF;AAGE,GAAA,UAAA;AAAA,EAAAJ,KACA,gBAAAO,EAAA,OAAA,EAAI,WAAU,8BACd,UAAC,gBAAAA,EAAAC,GAAA,EAAQ,SAAO,IAAC,MAAOC,EAAW,YAAe,UAAAT,EAAW,CAAA,GAC9D;AAAA,EAGCG;AAAA,EAEF,gBAAAE,EAAC,OAAI,EAAA,WAAU,gBACd,UAAA;AAAA,IAAA,gBAAAE;AAAA,MAACG;AAAA,MAAA;AAAA,QACA,MAAOC,EAAiB;AAAA,QACxB,QAASC,EAAY;AAAA,QACrB,OAAQC,EAAW;AAAA,QACnB,OAAQC,EAAQ;AAAA,QAChB,YAAU;AAAA,QAER,UAAAb;AAAA,MAAA;AAAA,IACH;AAAA,IAEA,gBAAAM;AAAA,MAACG;AAAA,MAAA;AAAA,QACA,MAAOC,EAAiB;AAAA,QACxB,OAAQE,EAAW;AAAA,QACnB,OAAQC,EAAQ;AAAA,QAChB,YAAU;AAAA,QAER,UAAAZ;AAAA,MAAA;AAAA,IAAA;AAAA,EACH,EACD,CAAA;AAAA,GACD;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UiProgress.js","sources":["../../../src/components/UiProgress/UiProgress.tsx"],"sourcesContent":["import React from \"react\";\nimport cx from \"classnames\";\nimport { EColors, ETextWeight, ETypographySizes, UiTypography } from \"../UiTypography\";\n\ninterface IUiProgress {\n\tmin: number\n\tmax: number\n\tcurrent: number\n\tprogressText?: string\n\tclassName?: string\n}\n\nexport const UiProgress: React.FC<IUiProgress> = ({\n\tprogressText,\n\tmax,\n\tmin,\n\tcurrent,\n\tclassName\n\n}) => {\n\tconst filler = ((current - min) / (max - min)) * 100;\n\n\treturn (\n\t\t<div className={ cx(\n\t\t\t\"ui-progress\",\n\t\t\tclassName\n\t\t) }>\n\t\t\t<div className={ cx(\n\t\t\t\t\"relative\",\n\t\t\t\t\"h-xxs
|
|
1
|
+
{"version":3,"file":"UiProgress.js","sources":["../../../src/components/UiProgress/UiProgress.tsx"],"sourcesContent":["import React from \"react\";\nimport cx from \"classnames\";\nimport { EColors, ETextWeight, ETypographySizes, UiTypography } from \"../UiTypography\";\n\ninterface IUiProgress {\n\tmin: number\n\tmax: number\n\tcurrent: number\n\tprogressText?: string\n\tclassName?: string\n}\n\nexport const UiProgress: React.FC<IUiProgress> = ({\n\tprogressText,\n\tmax,\n\tmin,\n\tcurrent,\n\tclassName\n\n}) => {\n\tconst filler = ((current - min) / (max - min)) * 100;\n\n\treturn (\n\t\t<div className={ cx(\n\t\t\t\"ui-progress\",\n\t\t\tclassName\n\t\t) }>\n\t\t\t<div className={ cx(\n\t\t\t\t\"relative\",\n\t\t\t\t\"h-xxs\",\n\t\t\t\t\"w-full\",\n\t\t\t\t\"overflow-hidden\",\n\t\t\t\t\"rounded-3xl\",\n\t\t\t\t\"bg-primary-50\",\n\t\t\t\t\"mb-xxs\"\n\t\t\t) } >\n\t\t\t\t<div className={ cx(\n\t\t\t\t\t\"ui-progress__bar-fill\",\n\t\t\t\t\t\"absolute\",\n\t\t\t\t\t\"left-0\",\n\t\t\t\t\t\"top-0\",\n\t\t\t\t\t\"z-10\",\n\t\t\t\t\t\"h-full\",\n\t\t\t\t\t\"rounded-2xl\",\n\t\t\t\t\t\"bg-primary-700\",\n\t\t\t\t\t\"transition-all\",\n\t\t\t\t\t\"duration-300\"\n\n\t\t\t\t) }\n\t\t\t\tstyle={ {\n\t\t\t\t\twidth: `${filler}%`\n\t\t\t\t} }>\n\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t{ progressText && (\n\t\t\t\t<UiTypography\n\t\t\t\t\tcolor={ EColors.PRIMARY_700 }\n\t\t\t\t\tsize={ ETypographySizes.SM }\n\t\t\t\t\tweight={ ETextWeight.SEMI_BOLD }\n\t\t\t\t>\n\t\t\t\t\t{ progressText }\n\t\t\t\t</UiTypography>\n\t\t\t) }\n\n\t\t</div>\n\n\t);\n};\n"],"names":["UiProgress","progressText","max","min","current","className","filler","jsxs","cx","jsx","UiTypography","EColors","ETypographySizes","ETextWeight"],"mappings":";;;;;;AAYO,MAAMA,IAAoC,CAAC;AAAA,EACjD,cAAAC;AAAA,EACA,KAAAC;AAAA,EACA,KAAAC;AAAA,EACA,SAAAC;AAAA,EACA,WAAAC;AAED,MAAM;AACL,QAAMC,KAAWF,IAAUD,MAAQD,IAAMC,KAAQ;AAGhD,SAAA,gBAAAI,EAAC,SAAI,WAAYC;AAAA,IAChB;AAAA,IACAH;AAAA,EAEA,GAAA,UAAA;AAAA,IAAA,gBAAAI,EAAC,SAAI,WAAYD;AAAA,MAChB;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IAEA,GAAA,UAAA,gBAAAC;AAAA,MAAC;AAAA,MAAA;AAAA,QAAI,WAAYD;AAAA,UAChB;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,QAED;AAAA,QACA,OAAQ;AAAA,UACP,OAAO,GAAGF,CAAM;AAAA,QAAA;AAAA,MACjB;AAAA,IAAA,GAGD;AAAA,IACEL,KACD,gBAAAQ;AAAA,MAACC;AAAA,MAAA;AAAA,QACA,OAAQC,EAAQ;AAAA,QAChB,MAAOC,EAAiB;AAAA,QACxB,QAASC,EAAY;AAAA,QAEnB,UAAAZ;AAAA,MAAA;AAAA,IAAA;AAAA,EACH,GAGF;AAGF;"}
|
|
@@ -35,7 +35,7 @@ const h = {
|
|
|
35
35
|
"bg-white",
|
|
36
36
|
"p-sm",
|
|
37
37
|
"hover:border-secondary-alt-700",
|
|
38
|
-
"peer-focus:outline
|
|
38
|
+
"peer-focus:outline",
|
|
39
39
|
"peer-focus:outline-4",
|
|
40
40
|
"peer-focus:outline-primary-300",
|
|
41
41
|
"peer-checked:shadow-border-primary-600",
|
|
@@ -46,7 +46,7 @@ const h = {
|
|
|
46
46
|
"gap-sm",
|
|
47
47
|
"text-sm",
|
|
48
48
|
c ? "peer-focus:outline-offset-2" : "peer-focus:outline-offset-0",
|
|
49
|
-
e ? "border-secondary-alt-400 text-secondary-alt-500
|
|
49
|
+
e ? "peer-checked:shadow-border-primary-disabled border-secondary-alt-400 text-secondary-alt-500" : "border-secondary-alt-600",
|
|
50
50
|
h[l]
|
|
51
51
|
), children: [
|
|
52
52
|
/* @__PURE__ */ r(
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UiRadioFancy.js","sources":["../../../src/components/UiRadioFancy/UiRadioFancy.tsx"],"sourcesContent":["import React from \"react\";\nimport cx from \"classnames\";\nimport { UiIcon } from \"../UiIcon\";\nimport { ESize } from \"../../_types/sizing\";\nimport { type IconProp } from \"@fortawesome/fontawesome-svg-core\";\nimport { ERadioTypes } from \"./_types\";\n\nexport type TUiRadioFancy = {\n\tchildren: React.ReactNode\n\ticon?: IconProp\n\tdisabled?: boolean;\n\tactive?: boolean;\n\tsubHeader?: string;\n\tclassName?: string;\n\tradioType?: ERadioTypes;\n\tvalue: string;\n\tonChange: (value: string) => void;\n\n} & Omit<React.InputHTMLAttributes<HTMLInputElement>, \"onChange\" | \"checked\" | \"value\" | \"name\">;\n\nconst typeClasses = {\n\t[ERadioTypes.DEFAULT]: \"items-center\",\n\t[ERadioTypes.COMPACT]: \"items-start flex-col\"\n};\n\nexport const UiRadioFancy: React.FC<TUiRadioFancy> = ({\n\tchildren,\n\ticon,\n\tdisabled,\n\tsubHeader,\n\tactive,\n\tradioType = ERadioTypes.DEFAULT,\n\tvalue,\n\tonChange,\n\tclassName\n\n}) => {\n\treturn (\n\t\t<label className={ cx(\n\t\t\t\"ui-radio-fancy\",\n\t\t\t\"relative\",\n\t\t\t{\n\t\t\t\t\"pointer-events-none\": disabled\n\t\t\t},\n\t\t\tclassName\n\t\t) }>\n\t\t\t<input className=\"group peer absolute appearance-none\" type=\"radio\" checked={ active } onChange={ ()=> onChange(value) }/>\n\n\t\t\t<div className={ cx(\n\t\t\t\t\"box-border\",\n\t\t\t\t\"cursor-pointer\",\n\t\t\t\t\"rounded-lg\",\n\t\t\t\t\"border\",\n\t\t\t\t\"bg-white\",\n\t\t\t\t\"p-sm\",\n\t\t\t\t\"hover:border-secondary-alt-700\",\n\t\t\t\t\"peer-focus:outline
|
|
1
|
+
{"version":3,"file":"UiRadioFancy.js","sources":["../../../src/components/UiRadioFancy/UiRadioFancy.tsx"],"sourcesContent":["import React from \"react\";\nimport cx from \"classnames\";\nimport { UiIcon } from \"../UiIcon\";\nimport { ESize } from \"../../_types/sizing\";\nimport { type IconProp } from \"@fortawesome/fontawesome-svg-core\";\nimport { ERadioTypes } from \"./_types\";\n\nexport type TUiRadioFancy = {\n\tchildren: React.ReactNode\n\ticon?: IconProp\n\tdisabled?: boolean;\n\tactive?: boolean;\n\tsubHeader?: string;\n\tclassName?: string;\n\tradioType?: ERadioTypes;\n\tvalue: string;\n\tonChange: (value: string) => void;\n\n} & Omit<React.InputHTMLAttributes<HTMLInputElement>, \"onChange\" | \"checked\" | \"value\" | \"name\">;\n\nconst typeClasses = {\n\t[ERadioTypes.DEFAULT]: \"items-center\",\n\t[ERadioTypes.COMPACT]: \"items-start flex-col\"\n};\n\nexport const UiRadioFancy: React.FC<TUiRadioFancy> = ({\n\tchildren,\n\ticon,\n\tdisabled,\n\tsubHeader,\n\tactive,\n\tradioType = ERadioTypes.DEFAULT,\n\tvalue,\n\tonChange,\n\tclassName\n\n}) => {\n\treturn (\n\t\t<label className={ cx(\n\t\t\t\"ui-radio-fancy\",\n\t\t\t\"relative\",\n\t\t\t{\n\t\t\t\t\"pointer-events-none\": disabled\n\t\t\t},\n\t\t\tclassName\n\t\t) }>\n\t\t\t<input className=\"group peer absolute appearance-none\" type=\"radio\" checked={ active } onChange={ ()=> onChange(value) }/>\n\n\t\t\t<div className={ cx(\n\t\t\t\t\"box-border\",\n\t\t\t\t\"cursor-pointer\",\n\t\t\t\t\"rounded-lg\",\n\t\t\t\t\"border\",\n\t\t\t\t\"bg-white\",\n\t\t\t\t\"p-sm\",\n\t\t\t\t\"hover:border-secondary-alt-700\",\n\t\t\t\t\"peer-focus:outline\",\n\t\t\t\t\"peer-focus:outline-4\",\n\t\t\t\t\"peer-focus:outline-primary-300\",\n\t\t\t\t\"peer-checked:shadow-border-primary-600\",\n\t\t\t\t\"peer-checked:border-0\",\n\t\t\t\t\"active:peer-checked:bg-secondary-alt-200\",\n\t\t\t\t\"hover:peer-checked:shadow-border-primary-700\",\n\t\t\t\t\"flex\",\n\t\t\t\t\"gap-sm\",\n\t\t\t\t\"text-sm\",\n\t\t\t\tactive\n\t\t\t\t\t? \"peer-focus:outline-offset-2\"\n\t\t\t\t\t: \"peer-focus:outline-offset-0\",\n\t\t\t\tdisabled\n\t\t\t\t\t? \"peer-checked:shadow-border-primary-disabled border-secondary-alt-400 text-secondary-alt-500\"\n\t\t\t\t\t: \"border-secondary-alt-600\",\n\n\t\t\t\ttypeClasses[radioType],\n\n\t\t\t) }>\n\t\t\t\t<div className={ cx(\n\t\t\t\t\t\"relative\",\n\t\t\t\t\t\"grid\",\n\t\t\t\t\t\"size-fit\",\n\t\t\t\t\t\"rounded-full\",\n\t\t\t\t\t\"place-items-center\",\n\t\t\t\t\t\"text-white\",\n\t\t\t\t\t\"p-xxs\",\n\t\t\t\t\t{\n\t\t\t\t\t\t\"bg-primary-300\": disabled,\n\t\t\t\t\t\t\"bg-primary\": !disabled\n\t\t\t\t\t}\n\n\t\t\t\t) }\n\t\t\t\t>\n\n\t\t\t\t\t{\n\t\t\t\t\t\ticon\n\t\t\t\t\t\t\t? <UiIcon\n\t\t\t\t\t\t\t\tname={ icon }\n\t\t\t\t\t\t\t\tsize={ ESize.SM }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t: null\n\t\t\t\t\t}\n\n\t\t\t\t</div>\n\n\t\t\t\t<div className=\"flex flex-col\">\n\t\t\t\t\t{ children }\n\t\t\t\t\t<div className=\"text-xs font-normal text-secondary-alt-400\">{ subHeader }</div>\n\t\t\t\t</div>\n\n\t\t\t</div>\n\n\t\t</label>\n\n\t);\n};\n"],"names":["typeClasses","ERadioTypes","UiRadioFancy","children","icon","disabled","subHeader","active","radioType","value","onChange","className","jsxs","cx","jsx","UiIcon","ESize"],"mappings":";;;;;;;AAoBA,MAAMA,IAAc;AAAA,EACnB,CAACC,EAAY,OAAO,GAAG;AAAA,EACvB,CAACA,EAAY,OAAO,GAAG;AACxB,GAEaC,IAAwC,CAAC;AAAA,EACrD,UAAAC;AAAA,EACA,MAAAC;AAAA,EACA,UAAAC;AAAA,EACA,WAAAC;AAAA,EACA,QAAAC;AAAA,EACA,WAAAC,IAAYP,EAAY;AAAA,EACxB,OAAAQ;AAAA,EACA,UAAAC;AAAA,EACA,WAAAC;AAED,MAEE,gBAAAC,EAAC,WAAM,WAAYC;AAAA,EAClB;AAAA,EACA;AAAA,EACA;AAAA,IACC,uBAAuBR;AAAA,EACxB;AAAA,EACAM;AAEA,GAAA,UAAA;AAAA,EAAC,gBAAAG,EAAA,SAAA,EAAM,WAAU,uCAAsC,MAAK,SAAQ,SAAUP,GAAS,UAAW,MAAKG,EAASD,CAAK,EAAG,CAAA;AAAA,EAExH,gBAAAG,EAAC,SAAI,WAAYC;AAAA,IAChB;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACAN,IACG,gCACA;AAAA,IACHF,IACG,gGACA;AAAA,IAEHL,EAAYQ,CAAS;AAAA,EAGrB,GAAA,UAAA;AAAA,IAAA,gBAAAM;AAAA,MAAC;AAAA,MAAA;AAAA,QAAI,WAAYD;AAAA,UAChB;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,UACA;AAAA,YACC,kBAAkBR;AAAA,YAClB,cAAc,CAACA;AAAA,UAAA;AAAA,QAGjB;AAAA,QAIE,UACGD,IAAA,gBAAAU;AAAA,UAACC;AAAA,UAAA;AAAA,YACF,MAAOX;AAAA,YACP,MAAOY,EAAM;AAAA,UAAA;AAAA,QAAA,IAEZ;AAAA,MAAA;AAAA,IAGL;AAAA,IAEA,gBAAAJ,EAAC,OAAI,EAAA,WAAU,iBACZ,UAAA;AAAA,MAAAT;AAAA,MACD,gBAAAW,EAAA,OAAA,EAAI,WAAU,8CAA+C,UAAWR,EAAA,CAAA;AAAA,IAAA,EAC1E,CAAA;AAAA,EAAA,EAED,CAAA;AAAA,GAED;"}
|
|
@@ -1,79 +1,79 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as o, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import y from "react";
|
|
3
|
-
import
|
|
4
|
-
import { UiTypography as
|
|
5
|
-
import { ETypographySizes as
|
|
6
|
-
import { EColors as
|
|
7
|
-
import { EInputKind as
|
|
8
|
-
import '../../assets/UiSelect.css';const
|
|
9
|
-
UiSelect:
|
|
10
|
-
},
|
|
11
|
-
[
|
|
12
|
-
[
|
|
13
|
-
[
|
|
3
|
+
import a from "classnames";
|
|
4
|
+
import { UiTypography as s } from "../UiTypography/UiTypography.js";
|
|
5
|
+
import { ETypographySizes as i } from "../UiTypography/_types.js";
|
|
6
|
+
import { EColors as c } from "../../_types/colors.js";
|
|
7
|
+
import { EInputKind as r } from "../UiInput/_types.js";
|
|
8
|
+
import '../../assets/UiSelect.css';const g = "_UiSelect_1fbno_1", w = {
|
|
9
|
+
UiSelect: g
|
|
10
|
+
}, E = {
|
|
11
|
+
[r.DEFAULT]: "border-secondary-alt-600",
|
|
12
|
+
[r.ERROR]: "border-error",
|
|
13
|
+
[r.SUCCESS]: "border-primary-600"
|
|
14
14
|
}, _ = ({
|
|
15
|
-
children:
|
|
16
|
-
heading:
|
|
17
|
-
subLabel:
|
|
18
|
-
disabled:
|
|
19
|
-
onChange:
|
|
20
|
-
className:
|
|
15
|
+
children: C,
|
|
16
|
+
heading: d,
|
|
17
|
+
subLabel: m,
|
|
18
|
+
disabled: u,
|
|
19
|
+
onChange: p,
|
|
20
|
+
className: f,
|
|
21
21
|
placeholder: h,
|
|
22
22
|
postfixIcon: x,
|
|
23
|
-
statusMessage:
|
|
24
|
-
kind:
|
|
25
|
-
...
|
|
23
|
+
statusMessage: t,
|
|
24
|
+
kind: l,
|
|
25
|
+
...n
|
|
26
26
|
}) => {
|
|
27
|
-
const [
|
|
27
|
+
const [R, S] = y.useState(n.value || n.defaultValue || ""), b = y.useCallback(
|
|
28
28
|
(v) => {
|
|
29
|
-
|
|
29
|
+
S(v.target.value), p?.(v);
|
|
30
30
|
},
|
|
31
|
-
[
|
|
31
|
+
[p]
|
|
32
32
|
);
|
|
33
|
-
return /* @__PURE__ */
|
|
34
|
-
|
|
35
|
-
|
|
33
|
+
return /* @__PURE__ */ o("div", { className: a("ui-select", f), children: [
|
|
34
|
+
d ? /* @__PURE__ */ e(
|
|
35
|
+
s,
|
|
36
36
|
{
|
|
37
|
-
size:
|
|
37
|
+
size: i.MD,
|
|
38
38
|
className: "mb-xxs",
|
|
39
|
-
children:
|
|
39
|
+
children: d
|
|
40
40
|
}
|
|
41
41
|
) : null,
|
|
42
|
-
/* @__PURE__ */
|
|
43
|
-
|
|
42
|
+
/* @__PURE__ */ o("div", { className: a(
|
|
43
|
+
w.UiSelect,
|
|
44
44
|
"relative",
|
|
45
45
|
"rounded-xl",
|
|
46
46
|
"border",
|
|
47
47
|
"hover:border-secondary-alt-600",
|
|
48
|
-
|
|
48
|
+
u ? ["pointer-events-none", "border-secondary-alt-300", "bg-secondary-alt-200"] : [l && E[l], "bg-white"]
|
|
49
49
|
), children: [
|
|
50
|
-
/* @__PURE__ */
|
|
50
|
+
/* @__PURE__ */ o(
|
|
51
51
|
"select",
|
|
52
52
|
{
|
|
53
|
-
...
|
|
53
|
+
...n,
|
|
54
54
|
className: `
|
|
55
55
|
m-0
|
|
56
|
-
pr-xl
|
|
57
56
|
w-full
|
|
58
57
|
cursor-pointer
|
|
59
58
|
appearance-none
|
|
60
59
|
border-0
|
|
61
60
|
bg-transparent
|
|
62
|
-
leading-[20px]
|
|
63
61
|
p-sm
|
|
62
|
+
pr-xl
|
|
63
|
+
leading-[20px]
|
|
64
64
|
text-secondary-alt
|
|
65
65
|
outline-0
|
|
66
66
|
`,
|
|
67
|
-
disabled:
|
|
68
|
-
value:
|
|
69
|
-
onChange:
|
|
67
|
+
disabled: u,
|
|
68
|
+
value: R,
|
|
69
|
+
onChange: b,
|
|
70
70
|
children: [
|
|
71
71
|
h ? /* @__PURE__ */ e("option", { value: "", disabled: !0, hidden: !0, children: h }) : null,
|
|
72
|
-
|
|
72
|
+
C
|
|
73
73
|
]
|
|
74
74
|
}
|
|
75
75
|
),
|
|
76
|
-
/* @__PURE__ */ e("div", { className: "absolute
|
|
76
|
+
/* @__PURE__ */ e("div", { className: "pointer-events-none absolute top-1/2 right-sm -translate-y-1/2", children: x || /* @__PURE__ */ e(
|
|
77
77
|
"svg",
|
|
78
78
|
{
|
|
79
79
|
width: "16",
|
|
@@ -91,28 +91,28 @@ import '../../assets/UiSelect.css';const w = "_UiSelect_1fbno_1", E = {
|
|
|
91
91
|
}
|
|
92
92
|
) })
|
|
93
93
|
] }),
|
|
94
|
-
|
|
95
|
-
|
|
94
|
+
m ? /* @__PURE__ */ e(
|
|
95
|
+
s,
|
|
96
96
|
{
|
|
97
|
-
size:
|
|
98
|
-
color:
|
|
97
|
+
size: i.SM,
|
|
98
|
+
color: c.SECONDARY_ALT,
|
|
99
99
|
className: "mt-xxs",
|
|
100
|
-
children:
|
|
100
|
+
children: m
|
|
101
101
|
}
|
|
102
102
|
) : null,
|
|
103
|
-
|
|
104
|
-
|
|
103
|
+
t ? /* @__PURE__ */ e(
|
|
104
|
+
s,
|
|
105
105
|
{
|
|
106
|
-
className:
|
|
106
|
+
className: a(
|
|
107
107
|
"transition-all duration-300 ease-in-out",
|
|
108
|
-
"max-h-0
|
|
108
|
+
"mt-xxs max-h-0 gap-xxs overflow-hidden opacity-0",
|
|
109
109
|
"data-[status=true]:max-h-full data-[status=true]:opacity-100"
|
|
110
110
|
),
|
|
111
111
|
lineHeight: !0,
|
|
112
|
-
color:
|
|
113
|
-
size:
|
|
114
|
-
"data-status": !!
|
|
115
|
-
children:
|
|
112
|
+
color: l === r.ERROR ? c.ERROR : c.PRIMARY,
|
|
113
|
+
size: i.SM,
|
|
114
|
+
"data-status": !!t,
|
|
115
|
+
children: t
|
|
116
116
|
}
|
|
117
117
|
) : null
|
|
118
118
|
] });
|