@cfx-dev/ui-components 4.5.15 → 4.5.17
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/{Combination-2dfXEDc9.js → Combination-CcTTSYNP.js} +1 -1
- package/dist/{DropdownContent-CLtPVRZg.js → DropdownContent-MvHlrWi6.js} +4 -4
- package/dist/assets/all_css.css +3 -0
- package/dist/assets/css/AccordionShowcase.css +1 -0
- package/dist/assets/css/Avatar.css +1 -1
- package/dist/assets/css/Badge.css +1 -1
- package/dist/assets/css/DropdownSelect.css +1 -1
- package/dist/assets/css/Range.css +1 -0
- package/dist/assets/css/RangeInput.css +1 -0
- package/dist/assets/css/RichInput.css +1 -1
- package/dist/assets/css/Select.css +1 -1
- package/dist/assets/css/StyledInput.css +1 -1
- package/dist/assets/general/global.css +1 -1
- package/dist/cfxIcons-B4SQ4Ljd.js +100 -0
- package/dist/components/Accordion/Accordion.d.ts +11 -1
- package/dist/components/Accordion/Accordion.js +105 -98
- package/dist/components/Accordion/AccordionShowcase.js +129 -95
- package/dist/components/Avatar/Avatar.d.ts +1 -1
- package/dist/components/Avatar/Avatar.js +21 -19
- package/dist/components/Avatar/AvatarShowcase.js +20 -12
- package/dist/components/Badge/Badge.js +16 -17
- package/dist/components/Badge/BadgeShowcase.js +10 -0
- package/dist/components/Button/Button.d.ts +2 -1
- package/dist/components/Button/Button.js +78 -72
- package/dist/components/Button/ButtonShowcase.js +16 -5
- package/dist/components/Checkbox/Checkbox.js +22 -21
- package/dist/components/DropdownContent/DropdownContent.js +1 -1
- package/dist/components/DropdownContent/index.js +1 -1
- package/dist/components/DropdownMenu/DropdownMenu.js +1 -1
- package/dist/components/DropdownSelect/DropdownSelect.js +1 -1
- package/dist/components/Icon/Icon.js +1 -1
- package/dist/components/IconBig/IconBig.js +3 -2
- package/dist/components/Icons/IconsShowcase.js +1 -1
- package/dist/components/Icons/cfx-icons/Filter.d.ts +5 -0
- package/dist/components/Icons/cfx-icons/Filter.js +23 -0
- package/dist/components/Icons/cfxIcons.d.ts +1 -0
- package/dist/components/Icons/cfxIcons.js +80 -78
- package/dist/components/Icons/index.js +1 -1
- package/dist/components/Range/Range.d.ts +4 -0
- package/dist/components/Range/Range.js +90 -0
- package/dist/components/Range/Range.types.d.ts +9 -0
- package/dist/components/Range/Range.types.js +1 -0
- package/dist/components/Range/RangeInput.d.ts +13 -0
- package/dist/components/Range/RangeInput.js +78 -0
- package/dist/components/Range/RangeShowcase.d.ts +2 -0
- package/dist/components/Range/RangeShowcase.js +41 -0
- package/dist/components/Range/RangeWithInputs.d.ts +8 -0
- package/dist/components/Range/RangeWithInputs.js +81 -0
- package/dist/components/Range/index.d.ts +6 -0
- package/dist/components/Range/index.js +8 -0
- package/dist/components/Select/Select.js +3 -3
- package/dist/components/Slider/Slider.js +64 -472
- package/dist/components/Slider/SliderShowcase.js +6 -4
- package/dist/components/Switch/Switch.js +1 -1
- package/dist/{index-DWzyrn_L.js → index-3ctv5u9o.js} +1 -1
- package/dist/{index-BMU9X4M-.js → index-9LBuZ7x4.js} +7 -7
- package/dist/{index-DCuJlMqr.js → index-CfQtbUfi.js} +6 -6
- package/dist/index-D5SMGei3.js +427 -0
- package/dist/main.d.ts +2 -0
- package/dist/main.js +105 -99
- package/dist/styles-scss/_ui.scss +23 -16
- package/package.json +1 -1
- package/dist/cfxIcons-B9nzO6TW.js +0 -98
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { jsxs as a, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import r from "../Flex/Flex.js";
|
|
3
|
+
import { Text as t } from "../Text/Text.js";
|
|
4
|
+
import "../../utils/ui/ui.js";
|
|
5
|
+
import i from "./RangeWithInputs.js";
|
|
6
|
+
function g() {
|
|
7
|
+
return /* @__PURE__ */ a(r, { gap: "large", vertical: !0, pb: 20, children: [
|
|
8
|
+
/* @__PURE__ */ a(r, { gap: "normal", vertical: !0, children: [
|
|
9
|
+
/* @__PURE__ */ e(t, { children: "Range With Inputs" }),
|
|
10
|
+
/* @__PURE__ */ e(
|
|
11
|
+
i,
|
|
12
|
+
{
|
|
13
|
+
defaultValue: [55, 100],
|
|
14
|
+
max: 200,
|
|
15
|
+
step: 5,
|
|
16
|
+
maxSign: "$",
|
|
17
|
+
minSign: "$",
|
|
18
|
+
name: "range-with-inputs"
|
|
19
|
+
}
|
|
20
|
+
)
|
|
21
|
+
] }),
|
|
22
|
+
/* @__PURE__ */ a(r, { gap: "normal", vertical: !0, children: [
|
|
23
|
+
/* @__PURE__ */ e(t, { children: "Disabled: Range With Inputs" }),
|
|
24
|
+
/* @__PURE__ */ e(
|
|
25
|
+
i,
|
|
26
|
+
{
|
|
27
|
+
defaultValue: [55, 100],
|
|
28
|
+
max: 200,
|
|
29
|
+
step: 5,
|
|
30
|
+
maxSign: "$",
|
|
31
|
+
minSign: "$",
|
|
32
|
+
disabled: !0,
|
|
33
|
+
name: "disabled-range"
|
|
34
|
+
}
|
|
35
|
+
)
|
|
36
|
+
] })
|
|
37
|
+
] });
|
|
38
|
+
}
|
|
39
|
+
export {
|
|
40
|
+
g as default
|
|
41
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { RangeProps } from './Range.types';
|
|
2
|
+
|
|
3
|
+
export type RangeWithInputsProps = RangeProps & {
|
|
4
|
+
minSign?: string;
|
|
5
|
+
maxSign?: string;
|
|
6
|
+
};
|
|
7
|
+
declare function RangeWithInputs(props: RangeWithInputsProps): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export default RangeWithInputs;
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { jsxs as x, jsx as s } from "react/jsx-runtime";
|
|
2
|
+
import i from "react";
|
|
3
|
+
import C from "../Flex/Flex.js";
|
|
4
|
+
import R from "./Range.js";
|
|
5
|
+
import M from "./RangeInput.js";
|
|
6
|
+
function _(V) {
|
|
7
|
+
const {
|
|
8
|
+
value: e,
|
|
9
|
+
defaultValue: l,
|
|
10
|
+
onValueChange: m,
|
|
11
|
+
min: c = 0,
|
|
12
|
+
max: o = 100,
|
|
13
|
+
minSign: h,
|
|
14
|
+
maxSign: S,
|
|
15
|
+
disabled: f = !1,
|
|
16
|
+
name: u,
|
|
17
|
+
...b
|
|
18
|
+
} = V, [t, d] = i.useState(() => e ? e[0] : l ? l[0] : c), [n, p] = i.useState(() => e ? e[1] : l ? l[1] : o), r = i.useCallback((a) => {
|
|
19
|
+
d(a[0]), p(a[1]), m && m(a);
|
|
20
|
+
}, [m]), j = i.useCallback((a) => {
|
|
21
|
+
const g = Math.min(Number(a), n);
|
|
22
|
+
r([g, n]);
|
|
23
|
+
}, [r, n]), v = i.useCallback((a) => {
|
|
24
|
+
const g = Math.min(Number(a), o);
|
|
25
|
+
r([t, g]);
|
|
26
|
+
}, [r, t, o]);
|
|
27
|
+
return i.useEffect(() => {
|
|
28
|
+
e && (d(e[0]), p(e[1]));
|
|
29
|
+
}, [e]), /* @__PURE__ */ x(C, { gap: 2.5, direction: "column", children: [
|
|
30
|
+
u && /* @__PURE__ */ s(
|
|
31
|
+
"input",
|
|
32
|
+
{
|
|
33
|
+
type: "hidden",
|
|
34
|
+
name: u,
|
|
35
|
+
value: [t, n].join(",")
|
|
36
|
+
}
|
|
37
|
+
),
|
|
38
|
+
/* @__PURE__ */ s(
|
|
39
|
+
R,
|
|
40
|
+
{
|
|
41
|
+
min: c,
|
|
42
|
+
max: o,
|
|
43
|
+
value: [t, n],
|
|
44
|
+
defaultValue: l,
|
|
45
|
+
onValueChange: r,
|
|
46
|
+
disabled: f,
|
|
47
|
+
name: u,
|
|
48
|
+
...b
|
|
49
|
+
}
|
|
50
|
+
),
|
|
51
|
+
/* @__PURE__ */ x(C, { gap: 2.5, justifyContent: "space-between", children: [
|
|
52
|
+
/* @__PURE__ */ s(
|
|
53
|
+
M,
|
|
54
|
+
{
|
|
55
|
+
sign: h,
|
|
56
|
+
value: t,
|
|
57
|
+
onChange: j,
|
|
58
|
+
min: c,
|
|
59
|
+
max: n,
|
|
60
|
+
disabled: f,
|
|
61
|
+
id: [u, "min"].filter(Boolean).join("-")
|
|
62
|
+
}
|
|
63
|
+
),
|
|
64
|
+
/* @__PURE__ */ s(
|
|
65
|
+
M,
|
|
66
|
+
{
|
|
67
|
+
sign: h,
|
|
68
|
+
value: n,
|
|
69
|
+
onChange: v,
|
|
70
|
+
min: t,
|
|
71
|
+
max: o,
|
|
72
|
+
disabled: f,
|
|
73
|
+
id: [u, "max"].filter(Boolean).join("-")
|
|
74
|
+
}
|
|
75
|
+
)
|
|
76
|
+
] })
|
|
77
|
+
] });
|
|
78
|
+
}
|
|
79
|
+
export {
|
|
80
|
+
_ as default
|
|
81
|
+
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export { default as Range } from './Range';
|
|
2
|
+
export { default as RangeInput } from './RangeInput';
|
|
3
|
+
export { default as RangeWithInputs } from './RangeWithInputs';
|
|
4
|
+
export type { RangeProps } from './Range.types';
|
|
5
|
+
export type { RangeInputProps } from './RangeInput';
|
|
6
|
+
export type { RangeWithInputsProps } from './RangeWithInputs';
|
|
@@ -3,9 +3,9 @@ import * as l from "react";
|
|
|
3
3
|
import q from "react";
|
|
4
4
|
import { R as ft, r as De } from "../../index-Cl_RnsqN.js";
|
|
5
5
|
import { c as Ee } from "../../index-rKs9bXHr.js";
|
|
6
|
-
import {
|
|
7
|
-
import { u as gt, c as vt } from "../../index-
|
|
8
|
-
import { c as Le, d as _t, u as Ne, A as St, a as wt, h as xt, b as yt, R as Ct, F as It, D as Tt, C as bt, e as Pt } from "../../Combination-
|
|
6
|
+
import { e as K, P as N, u as Oe, c as mt, b as B, a as P, f as ht } from "../../index-CfQtbUfi.js";
|
|
7
|
+
import { u as gt, c as vt } from "../../index-9LBuZ7x4.js";
|
|
8
|
+
import { c as Le, d as _t, u as Ne, A as St, a as wt, h as xt, b as yt, R as Ct, F as It, D as Tt, C as bt, e as Pt } from "../../Combination-CcTTSYNP.js";
|
|
9
9
|
import { u as Nt } from "../../index-BZPx6jYI.js";
|
|
10
10
|
import { Icon as Rt } from "../Icon/Icon.js";
|
|
11
11
|
import { clsx as xe } from "../../utils/clsx.js";
|