@baishuyun/ui-base 2.0.0 → 2.1.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.
Files changed (75) hide show
  1. package/dist/Card/{Card-DMXtN2pu.js → Card-CXULQNHa.js} +1 -1
  2. package/dist/Card/index.js +1 -1
  3. package/dist/CheckBox/CheckBox-Bu40TO29.js +84 -0
  4. package/dist/CheckBox/index.js +37 -0
  5. package/dist/ColorPicker/ColorPicker-CwFsihkL.js +207 -0
  6. package/dist/ColorPicker/index.js +1 -1
  7. package/dist/Icon/{Icon-C0bjP9U6.js → Icon-BlkVlKDd.js} +1 -1
  8. package/dist/Icon/index.js +1 -1
  9. package/dist/InputTag/index.js +2 -2
  10. package/dist/Modal/{Modal-C1LEJ6Y0.js → Modal-BZTEGGa0.js} +1 -1
  11. package/dist/Modal/index.js +1 -1
  12. package/dist/NotFoundContent/NotFoundContent-h0-oIXlk.js +6 -0
  13. package/dist/NotFoundContent/index.js +4 -0
  14. package/dist/Radio/index.js +105 -0
  15. package/dist/Segmented/Segmented-UgzW78Ey.js +75 -0
  16. package/dist/Segmented/index.js +4 -0
  17. package/dist/Select/Select-C3abXG27.js +855 -0
  18. package/dist/Select/index.js +6 -0
  19. package/dist/Tree/index.js +4 -0
  20. package/dist/Tree/utils/index.js +40 -0
  21. package/dist/components/CheckBox/CheckBox.d.ts +46 -0
  22. package/dist/components/CheckBox/CheckboxIcon.d.ts +6 -0
  23. package/dist/components/CheckBox/Group.d.ts +30 -0
  24. package/dist/components/CheckBox/constants.d.ts +11 -0
  25. package/dist/components/CheckBox/context/context.d.ts +8 -0
  26. package/dist/components/CheckBox/index.d.ts +9 -0
  27. package/dist/components/NotFoundContent/NotFoundContent.d.ts +9 -0
  28. package/dist/components/NotFoundContent/index.d.ts +1 -0
  29. package/dist/components/Radio/Group.d.ts +3 -0
  30. package/dist/components/Radio/Radio.d.ts +3 -0
  31. package/dist/components/Radio/constants.d.ts +6 -0
  32. package/dist/components/Radio/context/context.d.ts +9 -0
  33. package/dist/components/Radio/index.d.ts +7 -0
  34. package/dist/components/Radio/interface.d.ts +98 -0
  35. package/dist/components/Segmented/Segmented.d.ts +6 -0
  36. package/dist/components/Segmented/Segmented.type.d.ts +31 -0
  37. package/dist/components/Segmented/index.d.ts +2 -0
  38. package/dist/components/Select/HighlightText/HighlightText.d.ts +7 -0
  39. package/dist/components/Select/OptionList/MultOptionList/MultOptionList.d.ts +11 -0
  40. package/dist/components/Select/OptionList/OptionList.d.ts +6 -0
  41. package/dist/components/Select/OptionList/SingleOptionList/SingleOptionList.d.ts +11 -0
  42. package/dist/components/Select/OptionList/TreeOptionList/TreeOptionList.d.ts +21 -0
  43. package/dist/components/Select/OptionList/filter.d.ts +4 -0
  44. package/dist/components/Select/Select.d.ts +3 -0
  45. package/dist/components/Select/SelectInput/SelectInput.d.ts +10 -0
  46. package/dist/components/Select/SelectInput/SelectMultipleInput/OptionTag/OptionTag.d.ts +12 -0
  47. package/dist/components/Select/SelectInput/SelectMultipleInput/SelectMultipleInput.d.ts +8 -0
  48. package/dist/components/Select/SelectInput/SelectSingleInput/SelectSingleInput.d.ts +8 -0
  49. package/dist/components/Select/SelectInputSearch/SelectInputSearch.d.ts +6 -0
  50. package/dist/components/Select/SelectPanel/SelectPanel.d.ts +3 -0
  51. package/dist/components/Select/constants.d.ts +59 -0
  52. package/dist/components/Select/context/SelectContext.d.ts +52 -0
  53. package/dist/components/Select/index.d.ts +3 -0
  54. package/dist/components/Select/interface.d.ts +192 -0
  55. package/dist/components/Select/utils/fieldAccessor.d.ts +30 -0
  56. package/dist/components/Select/utils/tree.d.ts +2 -0
  57. package/dist/components/Tree/Tree.d.ts +6 -0
  58. package/dist/components/Tree/TreeNode/TreeNode.d.ts +21 -0
  59. package/dist/components/Tree/context/TreeContext.d.ts +15 -0
  60. package/dist/components/Tree/index.d.ts +3 -0
  61. package/dist/components/Tree/types/node.d.ts +12 -0
  62. package/dist/components/Tree/types/tree.d.ts +84 -0
  63. package/dist/components/Tree/utils/index.d.ts +11 -0
  64. package/dist/components/index.d.ts +5 -0
  65. package/dist/index.js +45 -35
  66. package/dist/style.css +1 -1
  67. package/dist/vendors/Tree-CCY2gtpG.js +225 -0
  68. package/dist/vendors/fuse.js-D1DCbUBb.js +1022 -0
  69. package/dist/vendors/index-ByQkttKA.js +59 -0
  70. package/dist/vendors/lodash-es-CZfJRWhO.js +305 -0
  71. package/dist/vendors/{simplebar-react-svBEsTVC.js → simplebar-react-Bf9Zq-21.js} +1 -1
  72. package/package.json +1 -1
  73. package/dist/ColorPicker/ColorPicker-CpPLwHR2.js +0 -253
  74. package/dist/vendors/fuse.js-l0sNRNKZ.js +0 -1
  75. package/dist/vendors/lodash-es-DP1ViCXF.js +0 -262
@@ -1,7 +1,7 @@
1
1
  import { jsxs as e, jsx as c } from "react/jsx-runtime";
2
2
  import { useState as l } from "react";
3
3
  import { c as n } from "../vendors/clsx-OuTLNxxd.js";
4
- import { I as p } from "../Icon/Icon-C0bjP9U6.js";
4
+ import { I as p } from "../Icon/Icon-BlkVlKDd.js";
5
5
  const _ = {
6
6
  "bsy-card": "_bsy-card_myftj_1",
7
7
  "bsy-card__header": "_bsy-card__header_myftj_6",
@@ -1,4 +1,4 @@
1
- import { C as f } from "./Card-DMXtN2pu.js";
1
+ import { C as f } from "./Card-CXULQNHa.js";
2
2
  export {
3
3
  f as default
4
4
  };
@@ -0,0 +1,84 @@
1
+ import { jsxs as m, jsx as l } from "react/jsx-runtime";
2
+ import { createContext as B, forwardRef as E, useContext as R } from "react";
3
+ import { I as j } from "../Icon/Icon-BlkVlKDd.js";
4
+ import { c as i } from "../vendors/clsx-OuTLNxxd.js";
5
+ import { u as O } from "../vendors/lodash-es-CZfJRWhO.js";
6
+ const P = B(null), V = "_checkbox_vheru_1", q = "_checkbox__inner_vheru_32", o = {
7
+ checkbox: V,
8
+ "checkbox--checked": "_checkbox--checked_vheru_12",
9
+ "checkbox--unchecked": "_checkbox--unchecked_vheru_16",
10
+ "checkbox--indeterminate": "_checkbox--indeterminate_vheru_23",
11
+ "checkbox--disabled": "_checkbox--disabled_vheru_27",
12
+ checkbox__inner: q,
13
+ "checkbox__inner--disabled": "_checkbox__inner--disabled_vheru_38"
14
+ }, z = ({ isChecked: c = !1, indeterminate: a = !1, disabled: h = !1 }) => {
15
+ const n = a ? "indeterminate" : c ? "checked" : "unchecked", s = i(o.checkbox, {
16
+ [o["checkbox--checked"]]: !h && n === "checked",
17
+ [o["checkbox--unchecked"]]: !h && n === "unchecked",
18
+ [o["checkbox--indeterminate"]]: !h && n === "indeterminate",
19
+ [o["checkbox--disabled"]]: h
20
+ }), b = i(o.checkbox__inner, {
21
+ [o["checkbox__inner--disabled"]]: h
22
+ });
23
+ return /* @__PURE__ */ m("div", { className: s, children: [
24
+ n === "checked" && /* @__PURE__ */ l(j, { name: "checkthebox", color: h ? "#b8b8b8" : "#fff" }),
25
+ n === "indeterminate" && /* @__PURE__ */ l("div", { className: b })
26
+ ] });
27
+ };
28
+ var v = /* @__PURE__ */ ((c) => (c.NONE = "none", c.HORIZONTAL = "horizontal", c.VERTICAL = "vertical", c))(v || {});
29
+ const t = {
30
+ "bsy-checkbox": "_bsy-checkbox_1372g_1",
31
+ "bsy-checkbox--full-width": "_bsy-checkbox--full-width_1372g_8",
32
+ "bsy-checkbox__button--left-label": "_bsy-checkbox__button--left-label_1372g_45"
33
+ }, $ = E((c, a) => {
34
+ var r;
35
+ const {
36
+ checked: h,
37
+ indeterminate: n = !1,
38
+ onChange: s,
39
+ value: b = O("checkbox"),
40
+ disabled: d = !1,
41
+ children: y,
42
+ style: N,
43
+ labelPosition: I = "right"
44
+ } = c, e = R(P), k = e ? (r = e.value) == null ? void 0 : r.includes(b) : h, w = (x) => {
45
+ var u;
46
+ if (!(d || e != null && e.disabled))
47
+ if (e) {
48
+ const f = x ? [...e.value || [], b] : (e.value || []).filter((C) => C !== b);
49
+ f && ((u = e.onChange) == null || u.call(e, f));
50
+ } else
51
+ s == null || s(x);
52
+ }, _ = d || (e == null ? void 0 : e.disabled);
53
+ return /* @__PURE__ */ m(
54
+ "div",
55
+ {
56
+ className: i(t["bsy-checkbox"], {
57
+ [t["bsy-checkbox--full-width"]]: (e == null ? void 0 : e.layout) === v.NONE || !(e != null && e.layout)
58
+ }),
59
+ onClick: () => w(!k),
60
+ style: N,
61
+ children: [
62
+ /* @__PURE__ */ l(
63
+ "div",
64
+ {
65
+ ref: a,
66
+ role: "checkbox",
67
+ "aria-checked": n ? "mixed" : k,
68
+ tabIndex: _ ? -1 : 0,
69
+ className: i({
70
+ [t["bsy-checkbox__button--left-label"]]: I === "left"
71
+ }),
72
+ children: /* @__PURE__ */ l(z, { indeterminate: n, isChecked: k, disabled: _ })
73
+ }
74
+ ),
75
+ y
76
+ ]
77
+ }
78
+ );
79
+ });
80
+ export {
81
+ $ as B,
82
+ P as C,
83
+ v as L
84
+ };
@@ -0,0 +1,37 @@
1
+ import { L as o, C as c, B as u } from "./CheckBox-Bu40TO29.js";
2
+ import { jsx as a } from "react/jsx-runtime";
3
+ import { useControllableValue as n } from "ahooks";
4
+ import { c as f } from "../vendors/clsx-OuTLNxxd.js";
5
+ const m = ({
6
+ disabled: r,
7
+ layout: e = o.NONE,
8
+ children: l,
9
+ ...s
10
+ }) => {
11
+ const [p, t] = n(s, {
12
+ defaultValue: [],
13
+ valuePropName: "value",
14
+ defaultValuePropName: "defaultValue",
15
+ trigger: "onChange"
16
+ }), x = f("flex", {
17
+ "flex-col": e === o.NONE,
18
+ "flex-col gap-[10px]": e === o.VERTICAL,
19
+ "flex-row gap-y-[10px] gap-x-[20px] flex-wrap": e === o.HORIZONTAL
20
+ });
21
+ return /* @__PURE__ */ a(
22
+ c.Provider,
23
+ {
24
+ value: {
25
+ value: p,
26
+ onChange: t,
27
+ disabled: r,
28
+ layout: e
29
+ },
30
+ children: /* @__PURE__ */ a("div", { className: x, children: l })
31
+ }
32
+ );
33
+ }, C = u;
34
+ C.Group = m;
35
+ export {
36
+ C as default
37
+ };
@@ -0,0 +1,207 @@
1
+ import { jsx as r, jsxs as b, Fragment as S } from "react/jsx-runtime";
2
+ import { ColorPicker as O } from "antd";
3
+ import { AnimatePresence as R, motion as w } from "motion/react";
4
+ import { useFloating as A, offset as F, flip as I, shift as x, useClick as E, useDismiss as L, useInteractions as T, FloatingPortal as V } from "@floating-ui/react";
5
+ import { useState as p, isValidElement as j, cloneElement as B, useRef as D } from "react";
6
+ import { useControllableValue as G } from "ahooks";
7
+ import { I as u } from "../Icon/Icon-BlkVlKDd.js";
8
+ import { u as y, P as M } from "../vendors/index-ByQkttKA.js";
9
+ import { c as $ } from "../vendors/clsx-OuTLNxxd.js";
10
+ import { t as k } from "../vendors/tinycolor2-Begv3Jc8.js";
11
+ import { b as d, c as q } from "../vendors/lodash-es-CZfJRWhO.js";
12
+ const z = [
13
+ "rgba(240, 102, 72, 1)",
14
+ // #F06648
15
+ "rgba(255, 197, 2, 1)",
16
+ // #FFC502
17
+ "rgba(74, 204, 140, 1)",
18
+ // #4ACC8C
19
+ "rgba(74, 192, 236, 1)",
20
+ // #4AC0EC
21
+ "rgba(255, 153, 33, 1)",
22
+ // #ff9921
23
+ "rgba(101, 101, 101, 1)",
24
+ // #656565
25
+ "rgba(255, 156, 136, 1)",
26
+ // #ff9c88
27
+ "rgba(98, 98, 206, 1)",
28
+ // #6262ce
29
+ "rgba(241, 104, 182, 1)",
30
+ // #f168b6
31
+ "rgba(55, 103, 241, 1)",
32
+ // #3767f1
33
+ "rgba(162, 206, 30, 1)",
34
+ // #a2ce1e
35
+ "rgba(179, 179, 179, 1)",
36
+ // #b3b3b3
37
+ "rgba(0, 0, 0, 1)",
38
+ // #000000
39
+ "rgba(102, 102, 102, 1)",
40
+ // #666
41
+ "rgba(153, 153, 153, 1)",
42
+ // #999
43
+ "rgba(194, 194, 194, 1)",
44
+ // #c2c2c2
45
+ "rgba(224, 224, 224, 1)",
46
+ // #e0e0e0
47
+ "rgba(77, 96, 159, 1)"
48
+ // #4d609f
49
+ ], H = (e = "bottom-start") => {
50
+ const [o, t] = p(!1), { refs: i, floatingStyles: c, context: a } = A({
51
+ open: o,
52
+ onOpenChange: t,
53
+ placement: e,
54
+ middleware: [
55
+ F(4),
56
+ // 浮层与触发器间距
57
+ I(),
58
+ // 超出边界时自动翻转
59
+ x({ padding: 8 })
60
+ // 自动避开边界
61
+ ]
62
+ }), n = E(a), _ = L(a), { getReferenceProps: l, getFloatingProps: m } = T([n, _]);
63
+ return {
64
+ isOpen: o,
65
+ refs: i,
66
+ floatingStyles: c,
67
+ getReferenceProps: l,
68
+ getFloatingProps: m,
69
+ setIsOpen: t
70
+ };
71
+ }, s = {
72
+ "bsy-color-picker__floating": "_bsy-color-picker__floating_1kfi6_1",
73
+ "bsy-color-picker__content": "_bsy-color-picker__content_1kfi6_4",
74
+ "bsy-color-picker__grid": "_bsy-color-picker__grid_1kfi6_11",
75
+ "bsy-color-picker__preset-colors-title": "_bsy-color-picker__preset-colors-title_1kfi6_15",
76
+ "bsy-color-picker__preset-colors-grid": "_bsy-color-picker__preset-colors-grid_1kfi6_19",
77
+ "bsy-color-picker__preset-colors-item": "_bsy-color-picker__preset-colors-item_1kfi6_24",
78
+ "bsy-color-picker__custom-color-title": "_bsy-color-picker__custom-color-title_1kfi6_47",
79
+ "bsy-color-picker__custom-color-btn": "_bsy-color-picker__custom-color-btn_1kfi6_51",
80
+ "bsy-color-picker__custom-color-btn--active": "_bsy-color-picker__custom-color-btn--active_1kfi6_61",
81
+ "bsy-color-picker__custom-color-btn--preview": "_bsy-color-picker__custom-color-btn--preview_1kfi6_65",
82
+ "bsy-color-picker__custom-color-content": "_bsy-color-picker__custom-color-content_1kfi6_68",
83
+ "bsy-color-picker__check-icon": "_bsy-color-picker__check-icon_1kfi6_72"
84
+ }, f = (e, o) => {
85
+ if (d(e) || d(o))
86
+ return !1;
87
+ const t = k(e).toRgbString(), i = k(o).toRgbString();
88
+ return t === i;
89
+ }, C = ({
90
+ currentColor: e,
91
+ onColorSelect: o,
92
+ options: t,
93
+ style: i
94
+ }) => /* @__PURE__ */ r("div", { className: s["bsy-color-picker__preset-colors-grid"], style: i, children: t.map((c) => /* @__PURE__ */ r(
95
+ "div",
96
+ {
97
+ className: s["bsy-color-picker__preset-colors-item"],
98
+ style: {
99
+ backgroundColor: c,
100
+ "--hover-color": k(c).setAlpha(0.5).toRgbString()
101
+ },
102
+ onClick: () => o(c),
103
+ children: f(e, c) && /* @__PURE__ */ r(u, { name: "checkthebox", className: s["bsy-color-picker__check-icon"] })
104
+ },
105
+ c
106
+ )) }), J = (e) => {
107
+ const { children: o, placement: t = "bottom-start", disabled: i = !1, presetColors: c } = e, { t: a } = y(), [n, _] = G(e, {
108
+ defaultValue: e.value
109
+ }), { isOpen: l, refs: m, floatingStyles: h, getReferenceProps: v, getFloatingProps: P } = H(t), N = j(o) ? B(o, {
110
+ ...v(),
111
+ // @ts-ignore
112
+ ref: m.setReference,
113
+ disabled: i
114
+ }) : o, g = q(c) && c.length ? c : z;
115
+ return /* @__PURE__ */ b(S, { children: [
116
+ N,
117
+ /* @__PURE__ */ r(V, { children: /* @__PURE__ */ r(R, { children: l && /* @__PURE__ */ r(
118
+ "div",
119
+ {
120
+ ref: m.setFloating,
121
+ style: h,
122
+ ...P(),
123
+ className: s["bsy-color-picker__floating"],
124
+ children: /* @__PURE__ */ r(w.div, { ...M, children: /* @__PURE__ */ r("div", { className: s["bsy-color-picker__content"], children: /* @__PURE__ */ b("div", { className: s["bsy-color-picker__grid"], children: [
125
+ /* @__PURE__ */ b("div", { className: s["bsy-color-picker__preset-colors"], children: [
126
+ /* @__PURE__ */ r("div", { className: s["bsy-color-picker__preset-colors-title"], children: a("presetColors") }),
127
+ /* @__PURE__ */ r(
128
+ C,
129
+ {
130
+ currentColor: n,
131
+ onColorSelect: _,
132
+ options: g
133
+ }
134
+ )
135
+ ] }),
136
+ /* @__PURE__ */ r(
137
+ K,
138
+ {
139
+ value: n,
140
+ onChange: _,
141
+ options: g
142
+ }
143
+ )
144
+ ] }) }) })
145
+ }
146
+ ) }) })
147
+ ] });
148
+ }, K = (e) => {
149
+ const [o, t] = p(), [i, c] = p(!1), a = e.options.some((l) => f(l, e.value)), n = D(a ? [] : [e.value]), { t: _ } = y();
150
+ return /* @__PURE__ */ b("div", { className: s["bsy-color-picker__custom-color"], children: [
151
+ /* @__PURE__ */ r("div", { className: s["bsy-color-picker__custom-color-title"], children: _("customColor") }),
152
+ /* @__PURE__ */ b("div", { className: s["bsy-color-picker__custom-color-content"], children: [
153
+ /* @__PURE__ */ r(
154
+ O,
155
+ {
156
+ value: o,
157
+ onChange: (l) => t(l.toRgbString()),
158
+ open: i,
159
+ onOpenChange: (l) => {
160
+ c(l), !l && o && (n.current.includes(o) || n.current.unshift(o), e.onChange(o), t(void 0));
161
+ },
162
+ children: /* @__PURE__ */ r(
163
+ "div",
164
+ {
165
+ className: $(s["bsy-color-picker__custom-color-btn"], {
166
+ [s["bsy-color-picker__custom-color-btn--active"]]: i && !o,
167
+ [s["bsy-color-picker__custom-color-btn--preview"]]: !!o
168
+ }),
169
+ role: "button",
170
+ style: {
171
+ backgroundColor: o || void 0
172
+ },
173
+ onClick: () => {
174
+ c(!0);
175
+ },
176
+ children: /* @__PURE__ */ r(
177
+ u,
178
+ {
179
+ name: "add",
180
+ style: {
181
+ visibility: o ? "hidden" : "visible"
182
+ }
183
+ }
184
+ )
185
+ }
186
+ )
187
+ }
188
+ ),
189
+ /* @__PURE__ */ r(
190
+ C,
191
+ {
192
+ currentColor: e.value,
193
+ onColorSelect: e.onChange,
194
+ options: n.current.slice(0, 5),
195
+ style: {
196
+ gridTemplateColumns: "repeat(5, 1fr)"
197
+ }
198
+ }
199
+ )
200
+ ] })
201
+ ] });
202
+ };
203
+ J.displayName = "BsyColorPicker";
204
+ export {
205
+ J as C,
206
+ z as a
207
+ };
@@ -1,4 +1,4 @@
1
- import { a as e, C as f } from "./ColorPicker-CpPLwHR2.js";
1
+ import { a as e, C as f } from "./ColorPicker-CwFsihkL.js";
2
2
  export {
3
3
  e as COLOR_OPTIONS_RGBA,
4
4
  f as default
@@ -1,6 +1,6 @@
1
1
  import { jsx as p } from "react/jsx-runtime";
2
2
  import { createFromIconfontCN as e } from "@ant-design/icons";
3
- import { i as a } from "../vendors/lodash-es-DP1ViCXF.js";
3
+ import { a } from "../vendors/lodash-es-CZfJRWhO.js";
4
4
  const f = e({
5
5
  scriptUrl: "https://at.alicdn.com/t/c/font_4786625_jgu2jvbpehp.js"
6
6
  }), I = ({ name: o, style: n, className: r, onClick: c, color: s, size: t = 16 }) => {
@@ -1,4 +1,4 @@
1
- import { I as f } from "./Icon-C0bjP9U6.js";
1
+ import { I as f } from "./Icon-BlkVlKDd.js";
2
2
  export {
3
3
  f as default
4
4
  };
@@ -2,9 +2,9 @@ import { jsxs as C, jsx as l } from "react/jsx-runtime";
2
2
  import { useControllableValue as A } from "ahooks";
3
3
  import { useState as S, useLayoutEffect as k, useRef as p, useEffect as D } from "react";
4
4
  import { c as h } from "../vendors/clsx-OuTLNxxd.js";
5
- import { I as M } from "../Icon/Icon-C0bjP9U6.js";
5
+ import { I as M } from "../Icon/Icon-BlkVlKDd.js";
6
6
  import { motion as O } from "motion/react";
7
- import { S as V } from "../vendors/simplebar-react-svBEsTVC.js";
7
+ import { S as V } from "../vendors/simplebar-react-Bf9Zq-21.js";
8
8
  const g = {
9
9
  "bsy-inputTag": "_bsy-inputTag_46spj_11",
10
10
  "bsy-inputTag__container": "_bsy-inputTag__container_46spj_22",
@@ -2,7 +2,7 @@ import { jsxs as s, jsx as o } from "react/jsx-runtime";
2
2
  import { useControllableValue as c } from "ahooks";
3
3
  import { Modal as r } from "antd";
4
4
  import { useState as u } from "react";
5
- import { I as n } from "../Icon/Icon-C0bjP9U6.js";
5
+ import { I as n } from "../Icon/Icon-BlkVlKDd.js";
6
6
  const f = "_modal__title_klsxr_1", b = "_modal__button_groups_klsxr_18", h = "_modal__button_klsxr_18", g = "_modal__icon_klsxr_38", l = {
7
7
  modal__title: f,
8
8
  modal__button_groups: b,
@@ -1,4 +1,4 @@
1
- import { M as f } from "./Modal-C1LEJ6Y0.js";
1
+ import { M as f } from "./Modal-BZTEGGa0.js";
2
2
  export {
3
3
  f as default
4
4
  };
@@ -0,0 +1,6 @@
1
+ import { jsx as t } from "react/jsx-runtime";
2
+ const o = ({ text: e, className: n = "" }) => /* @__PURE__ */ t("div", { className: `text-center text-sm line-height-normal text-[#999] py-[7px] ${n}`, children: /* @__PURE__ */ t("span", { children: e }) });
3
+ o.displayName = "BsyNotFoundContent";
4
+ export {
5
+ o as N
6
+ };
@@ -0,0 +1,4 @@
1
+ import { N as n } from "./NotFoundContent-h0-oIXlk.js";
2
+ export {
3
+ n as NotFoundContent
4
+ };
@@ -0,0 +1,105 @@
1
+ import { jsxs as E, jsx as t } from "react/jsx-runtime";
2
+ import { createContext as I, forwardRef as O, useContext as P } from "react";
3
+ import { c as n } from "../vendors/clsx-OuTLNxxd.js";
4
+ import { u as w } from "../vendors/lodash-es-CZfJRWhO.js";
5
+ import { useControllableValue as z } from "ahooks";
6
+ const N = I(null);
7
+ var o = /* @__PURE__ */ ((i) => (i.NONE = "none", i.HORIZONTAL = "horizontal", i.VERTICAL = "vertical", i))(o || {});
8
+ const s = {
9
+ "bsy-radio": "_bsy-radio_q02xg_1",
10
+ "bsy-radio--disabled": "_bsy-radio--disabled_q02xg_8",
11
+ "bsy-radio--full-width": "_bsy-radio--full-width_q02xg_11",
12
+ "bsy-radio__input": "_bsy-radio__input_q02xg_14",
13
+ "bsy-radio__input--checked": "_bsy-radio__input--checked_q02xg_38",
14
+ "bsy-radio__input--disabled": "_bsy-radio__input--disabled_q02xg_45",
15
+ "bsy-radio__label": "_bsy-radio__label_q02xg_60",
16
+ "bsy-radio__label--left": "_bsy-radio__label--left_q02xg_65",
17
+ "bsy-radio-group": "_bsy-radio-group_q02xg_75",
18
+ "bsy-radio-group--none": "_bsy-radio-group--none_q02xg_78",
19
+ "bsy-radio-group--vertical": "_bsy-radio-group--vertical_q02xg_81",
20
+ "bsy-radio-group--horizontal": "_bsy-radio-group--horizontal_q02xg_85"
21
+ }, g = O((i, e) => {
22
+ const {
23
+ checked: c,
24
+ onChange: d,
25
+ value: l = w("radio"),
26
+ disabled: r = !1,
27
+ children: _,
28
+ style: u,
29
+ labelPosition: y = "right",
30
+ className: p
31
+ } = i, a = P(N), b = a ? a.value === l : c, q = () => {
32
+ var f, m;
33
+ r || a != null && a.disabled || (a ? b ? (m = a.onDeselect) == null || m.call(a, l) : (f = a.onChange) == null || f.call(a, l) : d == null || d(!b));
34
+ }, h = r || (a == null ? void 0 : a.disabled), R = (a == null ? void 0 : a.layout) === o.NONE || !(a != null && a.layout), k = n(
35
+ s["bsy-radio"],
36
+ {
37
+ [s["bsy-radio--disabled"]]: h,
38
+ [s["bsy-radio--full-width"]]: R
39
+ },
40
+ p
41
+ ), x = n(s["bsy-radio__input"], {
42
+ [s["bsy-radio__input--checked"]]: b,
43
+ [s["bsy-radio__input--disabled"]]: h
44
+ }), V = n(s["bsy-radio__label"], {
45
+ [s["bsy-radio__label--left"]]: y === "left"
46
+ });
47
+ return /* @__PURE__ */ E("div", { role: "radio", className: k, onClick: q, style: u, children: [
48
+ /* @__PURE__ */ t(
49
+ "div",
50
+ {
51
+ ref: e,
52
+ role: "radio",
53
+ "aria-checked": b,
54
+ tabIndex: h ? -1 : 0,
55
+ className: x,
56
+ "data-layout": a == null ? void 0 : a.layout
57
+ }
58
+ ),
59
+ _ && /* @__PURE__ */ t("span", { className: V, children: _ })
60
+ ] });
61
+ });
62
+ g.displayName = "BsyRadio";
63
+ const v = ({
64
+ disabled: i,
65
+ layout: e = o.NONE,
66
+ children: c,
67
+ className: d,
68
+ style: l,
69
+ onDeselect: r,
70
+ ..._
71
+ }) => {
72
+ const [u, y] = z(_, {
73
+ defaultValue: "",
74
+ valuePropName: "value",
75
+ defaultValuePropName: "defaultValue",
76
+ trigger: "onChange"
77
+ }), p = n(
78
+ s["bsy-radio-group"],
79
+ {
80
+ [s["bsy-radio-group--none"]]: e === o.NONE,
81
+ [s["bsy-radio-group--vertical"]]: e === o.VERTICAL,
82
+ [s["bsy-radio-group--horizontal"]]: e === o.HORIZONTAL
83
+ },
84
+ d
85
+ );
86
+ return /* @__PURE__ */ t(
87
+ N.Provider,
88
+ {
89
+ value: {
90
+ value: u,
91
+ onChange: y,
92
+ disabled: i,
93
+ layout: e,
94
+ onDeselect: r
95
+ },
96
+ children: /* @__PURE__ */ t("div", { className: p, style: l, children: c })
97
+ }
98
+ );
99
+ };
100
+ v.displayName = "BsyRadioGroup";
101
+ const G = g;
102
+ G.Group = v;
103
+ export {
104
+ G as default
105
+ };
@@ -0,0 +1,75 @@
1
+ import { jsxs as h, jsx as o } from "react/jsx-runtime";
2
+ import { useState as b, useRef as g, useCallback as C, useLayoutEffect as N } from "react";
3
+ import { motion as w } from "motion/react";
4
+ import { c as y } from "../vendors/clsx-OuTLNxxd.js";
5
+ import { useControllableValue as x } from "ahooks";
6
+ const t = {
7
+ "bsy-segmented": "_bsy-segmented_ia83v_1",
8
+ "bsy-segmented--block": "_bsy-segmented--block_ia83v_12",
9
+ "bsy-segmented__item": "_bsy-segmented__item_ia83v_17",
10
+ "bsy-segmented__item--disabled": "_bsy-segmented__item--disabled_ia83v_31",
11
+ "bsy-segmented__item--block": "_bsy-segmented__item--block_ia83v_36",
12
+ "bsy-segmented__item--active": "_bsy-segmented__item--active_ia83v_44",
13
+ "bsy-segmented__item--inactive": "_bsy-segmented__item--inactive_ia83v_48",
14
+ "bsy-segmented__slider": "_bsy-segmented__slider_ia83v_53"
15
+ }, A = (c) => {
16
+ const { options: d, block: i = !1, disabled: l = !1 } = c, [m, u] = x(c), [v, f] = b({ width: 0, left: 0 }), [k, p] = b(!1), n = g(null), a = g(/* @__PURE__ */ new Map()), _ = C(() => {
17
+ const e = a.current.get(m), s = n.current;
18
+ if (e && s) {
19
+ const R = s.getBoundingClientRect(), r = e.getBoundingClientRect();
20
+ f({
21
+ width: r.width,
22
+ left: r.left - R.left
23
+ });
24
+ }
25
+ }, [m]);
26
+ return N(() => {
27
+ _();
28
+ const e = new ResizeObserver(_);
29
+ return n.current && e.observe(n.current), () => {
30
+ e.disconnect();
31
+ };
32
+ }, [_]), /* @__PURE__ */ h(
33
+ "div",
34
+ {
35
+ ref: n,
36
+ className: y(t["bsy-segmented"], i && t["bsy-segmented--block"]),
37
+ style: i ? { gridTemplateColumns: `repeat(${d.length}, 1fr)` } : void 0,
38
+ children: [
39
+ /* @__PURE__ */ o(
40
+ w.div,
41
+ {
42
+ className: t["bsy-segmented__slider"],
43
+ animate: v,
44
+ transition: k ? { type: "spring", stiffness: 350, damping: 35 } : { duration: 0 }
45
+ }
46
+ ),
47
+ d.map((e) => /* @__PURE__ */ o(
48
+ "button",
49
+ {
50
+ ref: (s) => {
51
+ s ? a.current.set(e.value, s) : a.current.delete(e.value);
52
+ },
53
+ onClick: () => {
54
+ l || (u(e.value), p(!0));
55
+ },
56
+ className: y(
57
+ t["bsy-segmented__item"],
58
+ i && t["bsy-segmented__item--block"],
59
+ m === e.value ? t["bsy-segmented__item--active"] : t["bsy-segmented__item--inactive"],
60
+ {
61
+ [t["bsy-segmented__item--disabled"]]: l
62
+ }
63
+ ),
64
+ children: e.label
65
+ },
66
+ e.value
67
+ ))
68
+ ]
69
+ }
70
+ );
71
+ };
72
+ A.displayName = "BsySegmented";
73
+ export {
74
+ A as S
75
+ };
@@ -0,0 +1,4 @@
1
+ import { S as f } from "./Segmented-UgzW78Ey.js";
2
+ export {
3
+ f as default
4
+ };