@baishuyun/ui-base 6.38.1 → 6.38.2
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/AiRuntimeContainer/index.js +1 -1
- package/dist/Amap/index.js +1 -1
- package/dist/Calendar/{Calendar-1ZIZcHEx.js → Calendar--OiKstox.js} +1 -1
- package/dist/Calendar/index.js +3 -3
- package/dist/Card/index.js +1 -1
- package/dist/CheckBox/{CheckBox-BXKoPSBh.js → CheckBox-Ck2mN3aJ.js} +51 -43
- package/dist/CheckBox/{CheckBox-DihUnPT-.js → CheckBox-D5gtYO8N.js} +1 -1
- package/dist/CheckBox/index.js +3 -3
- package/dist/ColorPicker/index.js +1 -1
- package/dist/ConfigProvider/index.js +1 -1
- package/dist/DatePicker/{DatePicker-ChROXLhv.js → DatePicker-MDfmIJrN.js} +1 -1
- package/dist/DatePicker/{DatePickerPanel-D86rFDgT.js → DatePickerPanel-BxJJFoBv.js} +1 -1
- package/dist/DatePicker/index.js +2 -2
- package/dist/DropDown/index.js +1 -1
- package/dist/Editor/index.js +12 -12
- package/dist/FieldCard/index.js +1 -1
- package/dist/Gantt/index.js +2 -2
- package/dist/Icon/index.js +1 -1
- package/dist/InputTag/index.js +1 -1
- package/dist/Kanban/index.js +3 -3
- package/dist/Loading/index.js +1 -1
- package/dist/Modal/index.js +1 -1
- package/dist/NotFoundContent/index.js +1 -1
- package/dist/Overlay/index.js +1 -1
- package/dist/Radio/{Radio-GeMs-7qt.js → Radio-NvTetWb5.js} +44 -35
- package/dist/Radio/index.js +2 -2
- package/dist/ScrollBar/index.js +1 -1
- package/dist/Segmented/index.js +1 -1
- package/dist/Select/{Select-cIKwnIMD.js → Select-DwBd8HaW.js} +66 -56
- package/dist/Select/index.js +6 -6
- package/dist/Table/index.js +1 -1
- package/dist/Tabs/index.js +1 -1
- package/dist/Tooltip/index.js +1 -1
- package/dist/Tree/index.js +4 -4
- package/dist/animations/index.d.ts +0 -62
- package/dist/components/Calendar/utils/dateUtils.d.ts +0 -1
- package/dist/components/Calendar/utils/eventUtils.d.ts +0 -3
- package/dist/components/Calendar/utils/layout/monthLayoutAlgorithm.d.ts +0 -9
- package/dist/components/Calendar/utils/theme/index.d.ts +0 -2
- package/dist/components/Gantt/GanttChart/utils/timeScale.d.ts +0 -8
- package/dist/components/Gantt/interface.d.ts +0 -1
- package/dist/components/Select/utils/tree.d.ts +1 -0
- package/dist/index.js +8 -8
- package/dist/vendors/{Tree-C8l3t4L6.js → Tree-D5ZZzoPS.js} +2 -2
- package/dist/vendors/{version-BrsbUgJb.js → version-Gt_7aQUl.js} +1 -1
- package/package.json +1 -1
- package/dist/components/Calendar/subcomponents/AllDaySection/index.d.ts +0 -1
- package/dist/components/Calendar/subcomponents/CurrentTimeIndicator/index.d.ts +0 -1
- package/dist/components/Calendar/subcomponents/EventCard/index.d.ts +0 -1
- package/dist/components/Calendar/subcomponents/TimeAxis/index.d.ts +0 -1
- package/dist/components/Calendar/subcomponents/TimeGrid/index.d.ts +0 -1
- package/dist/components/Gantt/utils/index.d.ts +0 -8
- package/dist/utils/color.d.ts +0 -9
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "../vendors/version-
|
|
1
|
+
import "../vendors/version-Gt_7aQUl.js";
|
|
2
2
|
import { jsx as e } from "react/jsx-runtime";
|
|
3
3
|
import * as t from "react";
|
|
4
4
|
import { Component as n, useCallback as r, useEffect as i, useLayoutEffect as a, useMemo as o, useRef as s } from "react";
|
package/dist/Amap/index.js
CHANGED
|
@@ -3,7 +3,7 @@ import { t } from "../vendors/cssVars-BbL_cmFM.js";
|
|
|
3
3
|
import { t as n } from "../vendors/useLocale-DvhRopWF.js";
|
|
4
4
|
import { t as r } from "../Segmented/Segmented-AHLqTK7U.js";
|
|
5
5
|
import { t as i } from "../Tooltip/Tooltip-N-w19uRu.js";
|
|
6
|
-
import { t as a } from "../DatePicker/DatePicker-
|
|
6
|
+
import { t as a } from "../DatePicker/DatePicker-MDfmIJrN.js";
|
|
7
7
|
import { jsx as o, jsxs as s } from "react/jsx-runtime";
|
|
8
8
|
import { memo as c, useCallback as l, useEffect as u, useLayoutEffect as d, useMemo as f, useRef as p, useState as m } from "react";
|
|
9
9
|
import h from "clsx";
|
package/dist/Calendar/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "../vendors/version-
|
|
1
|
+
import "../vendors/version-Gt_7aQUl.js";
|
|
2
2
|
import "../Icon/Icon-CcKDWNGy.js";
|
|
3
3
|
import "../vendors/LocaleContext-CsTLO_Y2.js";
|
|
4
4
|
import "../Overlay/OverlayContext-CVSFoyqN.js";
|
|
@@ -7,7 +7,7 @@ import "../vendors/useLocale-DvhRopWF.js";
|
|
|
7
7
|
import "../vendors/useLatchedPopupPortalRoot-Cu3oUL9h.js";
|
|
8
8
|
import "../Segmented/Segmented-AHLqTK7U.js";
|
|
9
9
|
import "../Tooltip/Tooltip-N-w19uRu.js";
|
|
10
|
-
import { n as e, r as t, t as n } from "./Calendar
|
|
11
|
-
import "../DatePicker/DatePicker-
|
|
10
|
+
import { n as e, r as t, t as n } from "./Calendar--OiKstox.js";
|
|
11
|
+
import "../DatePicker/DatePicker-MDfmIJrN.js";
|
|
12
12
|
import "../DatePicker/pickerLocale-Brf7_Tnd.js";
|
|
13
13
|
export { n as Calendar, n as default, t as resolveCalendarThemeVars, e as resolvePlatformCalendarTheme };
|
package/dist/Card/index.js
CHANGED
|
@@ -1,35 +1,35 @@
|
|
|
1
1
|
import { t as e } from "../Icon/Icon-CcKDWNGy.js";
|
|
2
2
|
import { t } from "../vendors/cssVars-BbL_cmFM.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { createContext as a, forwardRef as o, useContext as s } from "react";
|
|
3
|
+
import { jsx as n, jsxs as r } from "react/jsx-runtime";
|
|
4
|
+
import { createContext as i, forwardRef as a, useContext as o, useId as s } from "react";
|
|
6
5
|
import c from "clsx";
|
|
6
|
+
import { useControllableValue as l } from "ahooks";
|
|
7
7
|
//#region src/components/CheckBox/context/context.ts
|
|
8
|
-
var
|
|
9
|
-
checkbox:
|
|
8
|
+
var u = i(null), d = "_checkbox_5dsmf_1", f = "_checkbox__inner_5dsmf_35", p = {
|
|
9
|
+
checkbox: d,
|
|
10
10
|
"checkbox--checked": "_checkbox--checked_5dsmf_12",
|
|
11
11
|
"checkbox--unchecked": "_checkbox--unchecked_5dsmf_17",
|
|
12
12
|
"checkbox--indeterminate": "_checkbox--indeterminate_5dsmf_24",
|
|
13
13
|
"checkbox--disabled": "_checkbox--disabled_5dsmf_28",
|
|
14
|
-
checkbox__inner:
|
|
14
|
+
checkbox__inner: f,
|
|
15
15
|
"checkbox__inner--disabled": "_checkbox__inner--disabled_5dsmf_41"
|
|
16
|
-
},
|
|
17
|
-
let o =
|
|
18
|
-
[
|
|
19
|
-
[
|
|
20
|
-
[
|
|
21
|
-
[
|
|
22
|
-
}), l = c(
|
|
23
|
-
return /* @__PURE__ */
|
|
16
|
+
}, m = ({ isChecked: t = !1, indeterminate: i = !1, disabled: a = !1 }) => {
|
|
17
|
+
let o = i ? "indeterminate" : t ? "checked" : "unchecked", s = c(p.checkbox, {
|
|
18
|
+
[p["checkbox--checked"]]: !a && o === "checked",
|
|
19
|
+
[p["checkbox--unchecked"]]: !a && o === "unchecked",
|
|
20
|
+
[p["checkbox--indeterminate"]]: !a && o === "indeterminate",
|
|
21
|
+
[p["checkbox--disabled"]]: a
|
|
22
|
+
}), l = c(p.checkbox__inner, { [p["checkbox__inner--disabled"]]: a });
|
|
23
|
+
return /* @__PURE__ */ r("div", {
|
|
24
24
|
className: s,
|
|
25
|
-
children: [o === "checked" && /* @__PURE__ */
|
|
25
|
+
children: [o === "checked" && /* @__PURE__ */ n(e, {
|
|
26
26
|
name: "checkthebox",
|
|
27
27
|
color: "currentColor"
|
|
28
|
-
}), o === "indeterminate" && /* @__PURE__ */
|
|
28
|
+
}), o === "indeterminate" && /* @__PURE__ */ n("div", { className: l })]
|
|
29
29
|
});
|
|
30
|
-
},
|
|
30
|
+
}, h = /* @__PURE__ */ function(e) {
|
|
31
31
|
return e.NONE = "none", e.HORIZONTAL = "horizontal", e.VERTICAL = "vertical", e;
|
|
32
|
-
}({}),
|
|
32
|
+
}({}), g = {
|
|
33
33
|
"bsy-checkbox": "_bsy-checkbox_dflop_1",
|
|
34
34
|
"bsy-checkbox--disabled": "_bsy-checkbox--disabled_dflop_8",
|
|
35
35
|
"bsy-checkbox--full-width": "_bsy-checkbox--full-width_dflop_12",
|
|
@@ -40,40 +40,48 @@ var l = a(null), u = "_checkbox_5dsmf_1", d = "_checkbox__inner_5dsmf_35", f = {
|
|
|
40
40
|
"bsy-checkbox__button--checked": "_bsy-checkbox__button--checked_dflop_38",
|
|
41
41
|
"bsy-checkbox__button--unchecked": "_bsy-checkbox__button--unchecked_dflop_42",
|
|
42
42
|
"bsy-checkbox__button--left-label": "_bsy-checkbox__button--left-label_dflop_49"
|
|
43
|
-
},
|
|
43
|
+
}, _ = (e) => {
|
|
44
44
|
if (!e) return {};
|
|
45
45
|
let n = {}, r = e.colorPrimary;
|
|
46
46
|
return t(n, "--bsy-checkbox-checked-bg", e.checkedBg ?? r), t(n, "--bsy-checkbox-checked-border", e.checkedBorder ?? r), t(n, "--bsy-checkbox-check-icon-color", e.checkIconColor), t(n, "--bsy-checkbox-unchecked-bg", e.uncheckedBg), t(n, "--bsy-checkbox-color-border", e.colorBorder), t(n, "--bsy-checkbox-color-border-hover", e.colorBorderHover ?? r), t(n, "--bsy-checkbox-indeterminate-bg", e.indeterminateBg), t(n, "--bsy-checkbox-indeterminate-border", e.indeterminateBorder ?? r), t(n, "--bsy-checkbox-indeterminate-indicator", e.indeterminateIndicator ?? r), t(n, "--bsy-checkbox-color-bg-disabled", e.colorBgDisabled), t(n, "--bsy-checkbox-color-border-disabled", e.colorBorderDisabled), t(n, "--bsy-checkbox-check-icon-color-disabled", e.checkIconColorDisabled), t(n, "--bsy-checkbox-indeterminate-indicator-disabled", e.indeterminateIndicatorDisabled), t(n, "--bsy-checkbox-color-text-disabled", e.colorTextDisabled), n;
|
|
47
|
-
},
|
|
48
|
-
let
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
47
|
+
}, v = a((e, t) => {
|
|
48
|
+
let i = s(), { indeterminate: a = !1, disabled: d = !1, children: f, style: p, labelPosition: v = "right", theme: y } = e, b = e.value ?? i, [x, S] = l(e, {
|
|
49
|
+
valuePropName: "checked",
|
|
50
|
+
defaultValuePropName: "defaultChecked",
|
|
51
|
+
defaultValue: !1
|
|
52
|
+
}), C = o(u), w = C ? C.value?.includes(b) : x, T = (e) => {
|
|
53
|
+
if (!(d || C?.disabled)) {
|
|
54
|
+
if (C) {
|
|
55
|
+
let t = e ? [...C.value || [], b] : (C.value || []).filter((e) => e !== b);
|
|
56
|
+
C.onChange?.(t);
|
|
57
|
+
return;
|
|
58
|
+
}
|
|
59
|
+
S(e);
|
|
60
|
+
}
|
|
61
|
+
}, E = d || C?.disabled, D = _(y);
|
|
62
|
+
return /* @__PURE__ */ r("div", {
|
|
63
|
+
className: c(g["bsy-checkbox"], {
|
|
64
|
+
[g["bsy-checkbox--disabled"]]: E,
|
|
65
|
+
[g["bsy-checkbox--full-width"]]: C?.layout === h.NONE || !C?.layout
|
|
58
66
|
}),
|
|
59
|
-
onClick: () =>
|
|
67
|
+
onClick: () => T(!w),
|
|
60
68
|
style: {
|
|
61
|
-
...
|
|
62
|
-
...
|
|
69
|
+
...D,
|
|
70
|
+
...p
|
|
63
71
|
},
|
|
64
|
-
children: [/* @__PURE__ */
|
|
72
|
+
children: [/* @__PURE__ */ n("div", {
|
|
65
73
|
ref: t,
|
|
66
74
|
role: "checkbox",
|
|
67
|
-
"aria-checked":
|
|
68
|
-
tabIndex:
|
|
69
|
-
className: c({ [
|
|
70
|
-
children: /* @__PURE__ */
|
|
71
|
-
indeterminate:
|
|
72
|
-
isChecked:
|
|
73
|
-
disabled:
|
|
75
|
+
"aria-checked": a ? "mixed" : w,
|
|
76
|
+
tabIndex: E ? -1 : 0,
|
|
77
|
+
className: c({ [g["bsy-checkbox__button--left-label"]]: v === "left" }),
|
|
78
|
+
children: /* @__PURE__ */ n(m, {
|
|
79
|
+
indeterminate: a,
|
|
80
|
+
isChecked: w,
|
|
81
|
+
disabled: E
|
|
74
82
|
})
|
|
75
|
-
}),
|
|
83
|
+
}), f]
|
|
76
84
|
});
|
|
77
85
|
});
|
|
78
86
|
//#endregion
|
|
79
|
-
export {
|
|
87
|
+
export { u as i, _ as n, h as r, v as t };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { i as e, n as t, r as n, t as r } from "./CheckBox-
|
|
1
|
+
import { i as e, n as t, r as n, t as r } from "./CheckBox-Ck2mN3aJ.js";
|
|
2
2
|
import { jsx as i } from "react/jsx-runtime";
|
|
3
3
|
import a from "clsx";
|
|
4
4
|
import { useControllableValue as o } from "ahooks";
|
package/dist/CheckBox/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "../vendors/version-
|
|
1
|
+
import "../vendors/version-Gt_7aQUl.js";
|
|
2
2
|
import "../Icon/Icon-CcKDWNGy.js";
|
|
3
|
-
import "./CheckBox-
|
|
4
|
-
import { t as e } from "./CheckBox-
|
|
3
|
+
import "./CheckBox-Ck2mN3aJ.js";
|
|
4
|
+
import { t as e } from "./CheckBox-D5gtYO8N.js";
|
|
5
5
|
export { e as default };
|
|
@@ -48,7 +48,7 @@ var w = {
|
|
|
48
48
|
"bsy-date-picker__content": "_bsy-date-picker__content_1i2le_33",
|
|
49
49
|
"bsy-date-picker__divider": "_bsy-date-picker__divider_1i2le_43",
|
|
50
50
|
"bsy-date-picker__panel-loading": "_bsy-date-picker__panel-loading_1i2le_49"
|
|
51
|
-
}, j = m(() => import("./DatePickerPanel-
|
|
51
|
+
}, j = m(() => import("./DatePickerPanel-BxJJFoBv.js")), M = (n) => {
|
|
52
52
|
let { children: m, picker: S = "date", theme: w, getPopupContainer: D, triggerActiveClassName: O, zIndex: M } = n, { locale: N } = i(), P = e(M), [F, I] = v(n, {
|
|
53
53
|
defaultValuePropName: "defaultValue",
|
|
54
54
|
valuePropName: "value",
|
package/dist/DatePicker/index.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import "../vendors/version-
|
|
1
|
+
import "../vendors/version-Gt_7aQUl.js";
|
|
2
2
|
import "../vendors/LocaleContext-CsTLO_Y2.js";
|
|
3
3
|
import "../Overlay/OverlayContext-CVSFoyqN.js";
|
|
4
4
|
import "../vendors/useFloatingOverlay-DlLAeqUv.js";
|
|
5
5
|
import "../vendors/useLocale-DvhRopWF.js";
|
|
6
6
|
import "../vendors/useLatchedPopupPortalRoot-Cu3oUL9h.js";
|
|
7
|
-
import { t as e } from "./DatePicker-
|
|
7
|
+
import { t as e } from "./DatePicker-MDfmIJrN.js";
|
|
8
8
|
import "./pickerLocale-Brf7_Tnd.js";
|
|
9
9
|
export { e as default };
|
package/dist/DropDown/index.js
CHANGED
package/dist/Editor/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "../vendors/version-
|
|
1
|
+
import "../vendors/version-Gt_7aQUl.js";
|
|
2
2
|
import "../ScrollBar/style-D26azwz6.js";
|
|
3
3
|
import { t as e } from "../Icon/Icon-CcKDWNGy.js";
|
|
4
4
|
import "../vendors/LocaleContext-CsTLO_Y2.js";
|
|
@@ -13,8 +13,8 @@ import { r as s } from "../vendors/animations-DNlwdSQ2.js";
|
|
|
13
13
|
import "../vendors/useLatchedPopupPortalRoot-Cu3oUL9h.js";
|
|
14
14
|
import { t as c } from "../Tooltip/Tooltip-N-w19uRu.js";
|
|
15
15
|
import "../Select/SelectInputSearch-Bt2i3y3d.js";
|
|
16
|
-
import "../CheckBox/CheckBox-
|
|
17
|
-
import { t as l } from "../CheckBox/CheckBox-
|
|
16
|
+
import "../CheckBox/CheckBox-Ck2mN3aJ.js";
|
|
17
|
+
import { t as l } from "../CheckBox/CheckBox-D5gtYO8N.js";
|
|
18
18
|
import "../NotFoundContent/NotFoundContent-DJUQ0_2D.js";
|
|
19
19
|
import { t as u } from "../ScrollBar/ScrollBar-DJ6DaHDb.js";
|
|
20
20
|
import { t as d } from "../vendors/useFloatingPortal-DJ1iKmW-.js";
|
|
@@ -92,26 +92,26 @@ var U = {
|
|
|
92
92
|
});
|
|
93
93
|
}, [p]), _ = T((e) => {
|
|
94
94
|
if (!u?.isResizing) return;
|
|
95
|
-
let t = e.clientX - u.startX, n;
|
|
95
|
+
let t = e.clientX - u.startX, n = e.clientY - u.startY, r;
|
|
96
96
|
switch (u.direction) {
|
|
97
97
|
case "bottom-right":
|
|
98
|
-
|
|
98
|
+
r = Math.max(50, u.startWidth + t);
|
|
99
99
|
break;
|
|
100
100
|
case "bottom-left":
|
|
101
|
-
|
|
101
|
+
r = Math.max(50, u.startWidth - t);
|
|
102
102
|
break;
|
|
103
103
|
case "top-right":
|
|
104
|
-
|
|
104
|
+
r = Math.max(50, u.startWidth + t - n);
|
|
105
105
|
break;
|
|
106
106
|
case "top-left":
|
|
107
|
-
|
|
107
|
+
r = Math.max(50, u.startWidth - t - n);
|
|
108
108
|
break;
|
|
109
|
-
default:
|
|
109
|
+
default: r = Math.max(50, u.startWidth + t);
|
|
110
110
|
}
|
|
111
|
-
let
|
|
111
|
+
let i = r / u.aspectRatio;
|
|
112
112
|
m({
|
|
113
|
-
width:
|
|
114
|
-
height:
|
|
113
|
+
width: r,
|
|
114
|
+
height: i
|
|
115
115
|
});
|
|
116
116
|
}, [u]), S = T(() => {
|
|
117
117
|
u?.isResizing && (s.update(() => {
|
package/dist/FieldCard/index.js
CHANGED
package/dist/Gantt/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "../vendors/version-
|
|
1
|
+
import "../vendors/version-Gt_7aQUl.js";
|
|
2
2
|
import "../ScrollBar/style-D26azwz6.js";
|
|
3
3
|
import { t as e } from "../Icon/Icon-CcKDWNGy.js";
|
|
4
4
|
import "../vendors/LocaleContext-CsTLO_Y2.js";
|
|
@@ -469,7 +469,7 @@ function Xe({ pixelsPerDay: e, viewMode: t, timelineCoords: n, onTaskTimeChange:
|
|
|
469
469
|
let T = g(() => {
|
|
470
470
|
d((e) => {
|
|
471
471
|
let t = Object.keys(w.current);
|
|
472
|
-
if (t.length === 0) return {};
|
|
472
|
+
if (t.length === 0) return Object.keys(e).length === 0 ? e : {};
|
|
473
473
|
let n = {};
|
|
474
474
|
for (let r of t) e[r] && (n[r] = e[r]);
|
|
475
475
|
return Object.keys(n).length === Object.keys(e).length ? e : n;
|
package/dist/Icon/index.js
CHANGED
package/dist/InputTag/index.js
CHANGED
package/dist/Kanban/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "../vendors/version-
|
|
1
|
+
import "../vendors/version-Gt_7aQUl.js";
|
|
2
2
|
import "../ScrollBar/style-D26azwz6.js";
|
|
3
3
|
import { t as e } from "../Icon/Icon-CcKDWNGy.js";
|
|
4
4
|
import "../vendors/LocaleContext-CsTLO_Y2.js";
|
|
@@ -7,8 +7,8 @@ import { t } from "../vendors/cssVars-BbL_cmFM.js";
|
|
|
7
7
|
import { t as n } from "../vendors/useLocale-DvhRopWF.js";
|
|
8
8
|
import "../vendors/useLatchedPopupPortalRoot-Cu3oUL9h.js";
|
|
9
9
|
import "../Select/SelectInputSearch-Bt2i3y3d.js";
|
|
10
|
-
import "../CheckBox/CheckBox-
|
|
11
|
-
import { t as r } from "../CheckBox/CheckBox-
|
|
10
|
+
import "../CheckBox/CheckBox-Ck2mN3aJ.js";
|
|
11
|
+
import { t as r } from "../CheckBox/CheckBox-D5gtYO8N.js";
|
|
12
12
|
import "../NotFoundContent/NotFoundContent-DJUQ0_2D.js";
|
|
13
13
|
import { t as i } from "../ScrollBar/ScrollBar-DJ6DaHDb.js";
|
|
14
14
|
import "../vendors/useFloatingPortal-DJ1iKmW-.js";
|
package/dist/Loading/index.js
CHANGED
package/dist/Modal/index.js
CHANGED
package/dist/Overlay/index.js
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { t as e } from "../vendors/cssVars-BbL_cmFM.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { createContext as i, forwardRef as a, useContext as o } from "react";
|
|
2
|
+
import { jsx as t, jsxs as n } from "react/jsx-runtime";
|
|
3
|
+
import { createContext as r, forwardRef as i, useContext as a, useId as o } from "react";
|
|
5
4
|
import s from "clsx";
|
|
6
5
|
import { useControllableValue as c } from "ahooks";
|
|
7
6
|
//#region src/components/Radio/context/context.ts
|
|
8
|
-
var l =
|
|
7
|
+
var l = r(null), u = /* @__PURE__ */ function(e) {
|
|
9
8
|
return e.NONE = "none", e.HORIZONTAL = "horizontal", e.VERTICAL = "vertical", e;
|
|
10
9
|
}({}), d = {
|
|
11
10
|
"bsy-radio": "_bsy-radio_mkmuc_1",
|
|
@@ -24,60 +23,70 @@ var l = i(null), u = /* @__PURE__ */ function(e) {
|
|
|
24
23
|
if (!t) return {};
|
|
25
24
|
let n = {};
|
|
26
25
|
return e(n, "--bsy-radio-checked-bg", t.checkedBg), e(n, "--bsy-radio-checked-border", t.checkedBorder), e(n, "--bsy-radio-dot-color", t.dotColor), e(n, "--bsy-radio-unchecked-bg", t.uncheckedBg), e(n, "--bsy-radio-color-border", t.colorBorder), e(n, "--bsy-radio-color-border-hover", t.colorBorderHover), e(n, "--bsy-radio-color-bg-disabled", t.colorBgDisabled), e(n, "--bsy-radio-color-border-disabled", t.colorBorderDisabled), e(n, "--bsy-radio-checked-disabled-bg", t.checkedDisabledBg), e(n, "--bsy-radio-checked-disabled-border", t.checkedDisabledBorder), e(n, "--bsy-radio-checked-disabled-dot", t.checkedDisabledDot), n;
|
|
27
|
-
}, p =
|
|
28
|
-
let
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
26
|
+
}, p = i((e, r) => {
|
|
27
|
+
let i = o(), { disabled: p = !1, children: m, style: h, labelPosition: g = "right", className: _, theme: v } = e, y = e.value ?? i, [b, x] = c(e, {
|
|
28
|
+
valuePropName: "checked",
|
|
29
|
+
defaultValuePropName: "defaultChecked",
|
|
30
|
+
defaultValue: !1
|
|
31
|
+
}), S = a(l), C = S ? S.value === y : b, w = () => {
|
|
32
|
+
if (!(p || S?.disabled)) {
|
|
33
|
+
if (S) {
|
|
34
|
+
C ? S.onDeselect?.(y) : S.onChange?.(y);
|
|
35
|
+
return;
|
|
36
|
+
}
|
|
37
|
+
x(!C);
|
|
38
|
+
}
|
|
39
|
+
}, T = p || S?.disabled, E = S?.layout === u.NONE || !S?.layout, D = s(d["bsy-radio"], {
|
|
40
|
+
[d["bsy-radio--disabled"]]: T,
|
|
41
|
+
[d["bsy-radio--full-width"]]: E
|
|
42
|
+
}, _), O = s(d["bsy-radio__input"], {
|
|
43
|
+
[d["bsy-radio__input--checked"]]: C,
|
|
44
|
+
[d["bsy-radio__input--disabled"]]: T
|
|
45
|
+
}), k = s(d["bsy-radio__label"], { [d["bsy-radio__label--left"]]: g === "left" });
|
|
46
|
+
return /* @__PURE__ */ n("div", {
|
|
38
47
|
role: "radio",
|
|
39
|
-
className:
|
|
40
|
-
onClick:
|
|
48
|
+
className: D,
|
|
49
|
+
onClick: w,
|
|
41
50
|
style: {
|
|
42
|
-
...f(
|
|
43
|
-
...
|
|
51
|
+
...f(v),
|
|
52
|
+
...h
|
|
44
53
|
},
|
|
45
|
-
children: [/* @__PURE__ */
|
|
46
|
-
ref:
|
|
54
|
+
children: [/* @__PURE__ */ t("div", {
|
|
55
|
+
ref: r,
|
|
47
56
|
role: "radio",
|
|
48
|
-
"aria-checked":
|
|
49
|
-
tabIndex:
|
|
50
|
-
className:
|
|
51
|
-
"data-layout":
|
|
52
|
-
}),
|
|
53
|
-
className:
|
|
54
|
-
children:
|
|
57
|
+
"aria-checked": C,
|
|
58
|
+
tabIndex: T ? -1 : 0,
|
|
59
|
+
className: O,
|
|
60
|
+
"data-layout": S?.layout
|
|
61
|
+
}), m && /* @__PURE__ */ t("span", {
|
|
62
|
+
className: k,
|
|
63
|
+
children: m
|
|
55
64
|
})]
|
|
56
65
|
});
|
|
57
66
|
});
|
|
58
67
|
p.displayName = "BsyRadio";
|
|
59
68
|
//#endregion
|
|
60
69
|
//#region src/components/Radio/Group.tsx
|
|
61
|
-
var m = ({ disabled: e, layout:
|
|
70
|
+
var m = ({ disabled: e, layout: n = u.NONE, children: r, className: i, style: a, theme: o, onDeselect: p, ...m }) => {
|
|
62
71
|
let [h, g] = c(m, {
|
|
63
72
|
defaultValue: "",
|
|
64
73
|
valuePropName: "value",
|
|
65
74
|
defaultValuePropName: "defaultValue",
|
|
66
75
|
trigger: "onChange"
|
|
67
76
|
}), _ = s(d["bsy-radio-group"], {
|
|
68
|
-
[d["bsy-radio-group--none"]]:
|
|
69
|
-
[d["bsy-radio-group--vertical"]]:
|
|
70
|
-
[d["bsy-radio-group--horizontal"]]:
|
|
77
|
+
[d["bsy-radio-group--none"]]: n === u.NONE,
|
|
78
|
+
[d["bsy-radio-group--vertical"]]: n === u.VERTICAL,
|
|
79
|
+
[d["bsy-radio-group--horizontal"]]: n === u.HORIZONTAL
|
|
71
80
|
}, i);
|
|
72
|
-
return /* @__PURE__ */
|
|
81
|
+
return /* @__PURE__ */ t(l.Provider, {
|
|
73
82
|
value: {
|
|
74
83
|
value: h,
|
|
75
84
|
onChange: g,
|
|
76
85
|
disabled: e,
|
|
77
|
-
layout:
|
|
86
|
+
layout: n,
|
|
78
87
|
onDeselect: p
|
|
79
88
|
},
|
|
80
|
-
children: /* @__PURE__ */
|
|
89
|
+
children: /* @__PURE__ */ t("div", {
|
|
81
90
|
className: _,
|
|
82
91
|
style: {
|
|
83
92
|
...f(o),
|
package/dist/Radio/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import "../vendors/version-
|
|
2
|
-
import { t as e } from "./Radio-
|
|
1
|
+
import "../vendors/version-Gt_7aQUl.js";
|
|
2
|
+
import { t as e } from "./Radio-NvTetWb5.js";
|
|
3
3
|
export { e as default };
|
package/dist/ScrollBar/index.js
CHANGED
package/dist/Segmented/index.js
CHANGED
|
@@ -5,9 +5,9 @@ import { t as i } from "../vendors/useLocale-DvhRopWF.js";
|
|
|
5
5
|
import { n as a, r as o } from "../vendors/animations-DNlwdSQ2.js";
|
|
6
6
|
import { t as s } from "../vendors/useLatchedPopupPortalRoot-Cu3oUL9h.js";
|
|
7
7
|
import { t as c } from "./SelectInputSearch-Bt2i3y3d.js";
|
|
8
|
-
import { n as l, t as u } from "../vendors/Tree-
|
|
9
|
-
import { n as d } from "../CheckBox/CheckBox-
|
|
10
|
-
import { t as f } from "../CheckBox/CheckBox-
|
|
8
|
+
import { n as l, t as u } from "../vendors/Tree-D5ZZzoPS.js";
|
|
9
|
+
import { n as d } from "../CheckBox/CheckBox-Ck2mN3aJ.js";
|
|
10
|
+
import { t as f } from "../CheckBox/CheckBox-D5gtYO8N.js";
|
|
11
11
|
import { t as p } from "../NotFoundContent/NotFoundContent-DJUQ0_2D.js";
|
|
12
12
|
import { t as m } from "../ScrollBar/ScrollBar-DJ6DaHDb.js";
|
|
13
13
|
import { t as h } from "../vendors/useFloatingPortal-DJ1iKmW-.js";
|
|
@@ -221,7 +221,17 @@ var ge = "_select_multiple_input__container_15izh_1", _e = "_select_multiple_inp
|
|
|
221
221
|
X.displayName = "BsySelectMultipleInput";
|
|
222
222
|
//#endregion
|
|
223
223
|
//#region src/components/Select/utils/tree.ts
|
|
224
|
-
|
|
224
|
+
function Z(e, t, n) {
|
|
225
|
+
if (e) for (let r of e) {
|
|
226
|
+
if (r[n.value] === t) return r;
|
|
227
|
+
let e = r[n.children];
|
|
228
|
+
if (e?.length) {
|
|
229
|
+
let r = Z(e, t, n);
|
|
230
|
+
if (r) return r;
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
var Q = (e, t) => {
|
|
225
235
|
let n = [], r = (e) => {
|
|
226
236
|
e.forEach((e) => {
|
|
227
237
|
let { [t.children]: i, ...a } = e;
|
|
@@ -234,7 +244,7 @@ var Z = (e, t) => {
|
|
|
234
244
|
if (b(y)) return [];
|
|
235
245
|
let e = _(y) ? y : [y];
|
|
236
246
|
if (l === L.TREE) {
|
|
237
|
-
let t = V(T), n =
|
|
247
|
+
let t = V(T), n = Q(c, T);
|
|
238
248
|
return e.map((e) => n.find((n) => t.getValue(n) === e) || x?.(e)).filter((e) => !!e);
|
|
239
249
|
}
|
|
240
250
|
return e.map((e) => c.find((t) => t[T.value] === e) || x?.(e)).filter((e) => !!e);
|
|
@@ -305,7 +315,7 @@ var Z = (e, t) => {
|
|
|
305
315
|
ve.displayName = "BsySelectInput";
|
|
306
316
|
//#endregion
|
|
307
317
|
//#region src/components/Select/OptionList/SingleOptionList/SingleOptionList.tsx
|
|
308
|
-
var
|
|
318
|
+
var $ = D((e) => {
|
|
309
319
|
let { options: t, value: n, onSelect: r, searchValue: a = "", fieldNames: o, optionRender: s, optionStyle: c } = e, { t: u } = i(), { otherInputPosition: d } = z(), { otherOptionValue: f, setOtherOptionValue: p, onOtherInputChange: m, isSelectedOtherOption: h = !1 } = B(), g = M(null), _ = V(o);
|
|
310
320
|
return /* @__PURE__ */ C("ul", {
|
|
311
321
|
role: "listbox",
|
|
@@ -361,7 +371,7 @@ var Q = D((e) => {
|
|
|
361
371
|
})
|
|
362
372
|
});
|
|
363
373
|
});
|
|
364
|
-
|
|
374
|
+
$.displayName = "BsySingleSelect";
|
|
365
375
|
//#endregion
|
|
366
376
|
//#region src/components/Select/OptionList/MultOptionList/MultOptionList.tsx
|
|
367
377
|
var ye = (e) => {
|
|
@@ -435,7 +445,7 @@ var be = (e) => {
|
|
|
435
445
|
value: a.value,
|
|
436
446
|
children: a.children
|
|
437
447
|
} : void 0,
|
|
438
|
-
selectedKeys: r ? [
|
|
448
|
+
selectedKeys: r == null ? [] : [r],
|
|
439
449
|
onSelect: i
|
|
440
450
|
})
|
|
441
451
|
})
|
|
@@ -445,17 +455,17 @@ var be = (e) => {
|
|
|
445
455
|
if (e) for (let i of e) n.push(i), r(i[t.children]);
|
|
446
456
|
};
|
|
447
457
|
return r(e), n;
|
|
448
|
-
},
|
|
449
|
-
let i = r[n.children] ?
|
|
458
|
+
}, Se = (e, t, n) => e.reduce((e, r) => {
|
|
459
|
+
let i = r[n.children] ? Se(r[n.children], t, n) : void 0;
|
|
450
460
|
if (t.has(r[n.value]) || i && i.length > 0) {
|
|
451
461
|
let a = t.has(r[n.value]) ? r[n.children] : i;
|
|
452
462
|
e.push({
|
|
453
463
|
...r,
|
|
454
|
-
children: a
|
|
464
|
+
[n.children]: a
|
|
455
465
|
});
|
|
456
466
|
}
|
|
457
467
|
return e;
|
|
458
|
-
}, []),
|
|
468
|
+
}, []), Ce = (e) => {
|
|
459
469
|
let { options: t = [], searchValue: n = "", type: r, filterOption: a, optionRender: o, optionStyle: s, notFoundContent: c } = e, { t: l } = i(), { value: u, setIsOpen: d, setValue: f } = R(), { fieldNames: m } = z(), h = j(() => r === L.TREE ? xe(t, m) : t, [
|
|
460
470
|
t,
|
|
461
471
|
m,
|
|
@@ -473,7 +483,7 @@ var be = (e) => {
|
|
|
473
483
|
}, [d, f]), x = () => {
|
|
474
484
|
if (!a || v(n)) return t;
|
|
475
485
|
let e = g.search(n), i = new Set(e.map((e) => e.item[m.value]));
|
|
476
|
-
return r === L.TREE ?
|
|
486
|
+
return r === L.TREE ? Se(t, i, m) : t.filter((e) => i.has(e[m.value]));
|
|
477
487
|
};
|
|
478
488
|
return /* @__PURE__ */ C(S, { children: (() => {
|
|
479
489
|
let e = {
|
|
@@ -486,7 +496,7 @@ var be = (e) => {
|
|
|
486
496
|
text: l("noDataFound")
|
|
487
497
|
}) : c;
|
|
488
498
|
switch (r) {
|
|
489
|
-
case L.SINGLE: return /* @__PURE__ */ C(
|
|
499
|
+
case L.SINGLE: return /* @__PURE__ */ C($, {
|
|
490
500
|
...e,
|
|
491
501
|
value: u,
|
|
492
502
|
fieldNames: m,
|
|
@@ -509,14 +519,14 @@ var be = (e) => {
|
|
|
509
519
|
default: return null;
|
|
510
520
|
}
|
|
511
521
|
})() });
|
|
512
|
-
},
|
|
522
|
+
}, we = (e) => {
|
|
513
523
|
let { options: t = [], type: n = L.SINGLE, filterOption: r = !0, onSearch: a, showSearch: o, searchPlaceholder: s, onPopupScroll: l, notFoundContent: u, themeStyle: d } = e, { t: f } = i(), { searchValue: h = "", setSearchValue: g } = R(), _ = A(h), v = () => e.fetching ? /* @__PURE__ */ C(p, {
|
|
514
524
|
className: "bsy-select-empty",
|
|
515
525
|
text: f("dataSearching")
|
|
516
526
|
}) : t.length === 0 && !h ? u === void 0 ? /* @__PURE__ */ C(p, {
|
|
517
527
|
className: "bsy-select-empty",
|
|
518
528
|
text: f("noData")
|
|
519
|
-
}) : u : /* @__PURE__ */ C(
|
|
529
|
+
}) : u : /* @__PURE__ */ C(Ce, {
|
|
520
530
|
searchValue: _,
|
|
521
531
|
options: t,
|
|
522
532
|
type: n,
|
|
@@ -545,10 +555,10 @@ var be = (e) => {
|
|
|
545
555
|
})] })
|
|
546
556
|
});
|
|
547
557
|
};
|
|
548
|
-
|
|
558
|
+
we.displayName = "BsySelectPanel";
|
|
549
559
|
//#endregion
|
|
550
560
|
//#region src/components/Select/style/resolveSelectThemeVars.ts
|
|
551
|
-
var
|
|
561
|
+
var Te = (e) => {
|
|
552
562
|
if (!e) return {};
|
|
553
563
|
let t = {}, n = e.colorPrimary;
|
|
554
564
|
r(t, "--bsy-select-color-primary", n), r(t, "--bsy-select-color-bg", e.colorBgContainer), r(t, "--bsy-select-color-bg-elevated", e.colorBgElevated ?? e.colorBgContainer), r(t, "--bsy-select-color-text", e.colorText), r(t, "--bsy-select-color-input-value", e.colorInputValue), r(t, "--bsy-select-color-text-placeholder", e.colorTextPlaceholder), r(t, "--bsy-select-color-icon", e.colorIcon), r(t, "--bsy-select-color-icon-hover", e.colorIconHover ?? n), r(t, "--bsy-select-color-border", e.colorBorder), r(t, "--bsy-select-color-border-hover", e.colorBorderHover ?? n), r(t, "--bsy-select-color-bg-disabled", e.colorBgDisabled), r(t, "--bsy-select-color-text-disabled", e.colorTextDisabled), r(t, "--bsy-select-color-border-disabled", e.colorBorderDisabled), r(t, "--bsy-select-item-hover-bg", e.itemHoverBg), r(t, "--bsy-select-item-active-bg", e.itemActiveBg), r(t, "--bsy-select-item-active-color", e.itemActiveColor ?? n), r(t, "--bsy-select-item-color-disabled", e.itemColorDisabled), r(t, "--bsy-select-item-system-color", e.itemSystemColor), r(t, "--bsy-select-color-highlight", e.colorHighlight ?? n), r(t, "--bsy-select-tag-bg", e.tagBg), r(t, "--bsy-select-tag-color", e.tagColor), r(t, "--bsy-select-tag-bg-disabled", e.tagBgDisabled), r(t, "--bsy-select-tag-color-disabled", e.tagColorDisabled);
|
|
@@ -557,7 +567,7 @@ var we = (e) => {
|
|
|
557
567
|
...e.checkbox
|
|
558
568
|
};
|
|
559
569
|
return Object.assign(t, d(i)), t;
|
|
560
|
-
},
|
|
570
|
+
}, Ee = ee((e, r) => {
|
|
561
571
|
let { options: a = [], type: c = L.SINGLE, fieldNames: l, clearable: u = !0, disabled: d = !1, placeholder: f, labelRender: p, onOtherInputChange: m, onOpenChange: g, onPopupScroll: _, prefix: v, suffixIcon: b, ghost: x, inputValueStyle: S, tagStyle: T, zIndex: E, zIndexMask: ee, otherInputPosition: D = "bottom", getPopupContainer: k, theme: A } = e, re = Number.parseFloat(e.popupMinWidth ?? ""), ae = e.popupMatchSelectWidth ?? (Number.isFinite(re) ? re : !0), P = de[c], F = t(E), R = ee ?? F - 1, { t: z } = i(), B = te(), { onChange: V } = e, H = l || fe, [U, W] = oe(e, {
|
|
562
572
|
defaultValue: P === I.SINGLE ? void 0 : [],
|
|
563
573
|
defaultValuePropName: "defaultValue",
|
|
@@ -565,8 +575,8 @@ var we = (e) => {
|
|
|
565
575
|
trigger: "__NO_CUSTOM_CHANGE__"
|
|
566
576
|
}), [ge, _e] = ie(""), G = M(/* @__PURE__ */ new Map()), [K, q] = ie(() => {
|
|
567
577
|
if (P === I.SINGLE) {
|
|
568
|
-
let e = a
|
|
569
|
-
return e && t ? U : void 0;
|
|
578
|
+
let e = Z(a, U, H), t = a.find((e) => e.isOther === !0);
|
|
579
|
+
return !e && t ? U : void 0;
|
|
570
580
|
}
|
|
571
581
|
}), J = O((e, t) => {
|
|
572
582
|
if (!y(e, U)) {
|
|
@@ -588,18 +598,18 @@ var we = (e) => {
|
|
|
588
598
|
W,
|
|
589
599
|
H,
|
|
590
600
|
U
|
|
591
|
-
]), [Y, { set: X }] = se(!1),
|
|
601
|
+
]), [Y, { set: X }] = se(!1), Q = O((e) => {
|
|
592
602
|
e !== Y && (X(e), g?.(e));
|
|
593
603
|
}, [
|
|
594
604
|
X,
|
|
595
605
|
g,
|
|
596
606
|
Y
|
|
597
|
-
]), { isSelectedOtherOption:
|
|
607
|
+
]), { isSelectedOtherOption: $, shouldShowOtherInput: ye } = j(() => {
|
|
598
608
|
if (P === I.MULTIPLE) return {
|
|
599
609
|
isSelectedOtherOption: !1,
|
|
600
610
|
shouldShowOtherInput: !1
|
|
601
611
|
};
|
|
602
|
-
let e = a
|
|
612
|
+
let e = Z(a, U, H);
|
|
603
613
|
return e ? {
|
|
604
614
|
isSelectedOtherOption: e.isOther === !0,
|
|
605
615
|
shouldShowOtherInput: e.isOther === !0
|
|
@@ -618,8 +628,8 @@ var we = (e) => {
|
|
|
618
628
|
]), be = O(() => {
|
|
619
629
|
if (U) {
|
|
620
630
|
if (P === I.SINGLE) {
|
|
621
|
-
let e = a
|
|
622
|
-
if (e && t) return t[H.value];
|
|
631
|
+
let e = Z(a, U, H), t = a.find((e) => e.isOther === !0);
|
|
632
|
+
if (!e && t) return t[H.value];
|
|
623
633
|
}
|
|
624
634
|
return U;
|
|
625
635
|
} else return U;
|
|
@@ -632,7 +642,7 @@ var we = (e) => {
|
|
|
632
642
|
value: be(),
|
|
633
643
|
setValue: J,
|
|
634
644
|
isOpen: Y,
|
|
635
|
-
setIsOpen:
|
|
645
|
+
setIsOpen: Q,
|
|
636
646
|
getCachedOptionByValue: (e) => G.current.get(e),
|
|
637
647
|
searchValue: ge,
|
|
638
648
|
setSearchValue: _e
|
|
@@ -640,9 +650,9 @@ var we = (e) => {
|
|
|
640
650
|
be,
|
|
641
651
|
J,
|
|
642
652
|
Y,
|
|
643
|
-
|
|
653
|
+
Q,
|
|
644
654
|
ge
|
|
645
|
-
]),
|
|
655
|
+
]), Se = j(() => Te(A), [A]), Ce = j(() => ({
|
|
646
656
|
fieldNames: l || fe,
|
|
647
657
|
disabled: d,
|
|
648
658
|
otherInputPosition: D
|
|
@@ -650,20 +660,20 @@ var we = (e) => {
|
|
|
650
660
|
l,
|
|
651
661
|
d,
|
|
652
662
|
D
|
|
653
|
-
]),
|
|
654
|
-
isSelectedOtherOption:
|
|
663
|
+
]), Ee = j(() => ({
|
|
664
|
+
isSelectedOtherOption: $,
|
|
655
665
|
otherOptionValue: K,
|
|
656
666
|
setOtherOptionValue: q,
|
|
657
667
|
onOtherInputChange: m
|
|
658
668
|
}), [
|
|
659
|
-
|
|
669
|
+
$,
|
|
660
670
|
K,
|
|
661
671
|
q,
|
|
662
672
|
m
|
|
663
|
-
]), { refs:
|
|
673
|
+
]), { refs: De, floatingStyles: Oe, getReferenceProps: ke, getFloatingProps: Ae, referenceStyle: je } = h({
|
|
664
674
|
isOpen: Y,
|
|
665
675
|
close: () => {
|
|
666
|
-
|
|
676
|
+
Q(!1);
|
|
667
677
|
},
|
|
668
678
|
showMask: e.showMask,
|
|
669
679
|
zIndex: F,
|
|
@@ -673,14 +683,14 @@ var we = (e) => {
|
|
|
673
683
|
x: 0,
|
|
674
684
|
y: 4
|
|
675
685
|
}
|
|
676
|
-
}), { portalRoot:
|
|
677
|
-
|
|
686
|
+
}), { portalRoot: Me, portalMountKey: Ne, handleExitComplete: Pe } = s(Y, k), Fe = O(() => {
|
|
687
|
+
$ && (q(""), m?.("")), Q(!1), G.current.clear(), J(P === I.SINGLE ? void 0 : []);
|
|
678
688
|
}, [
|
|
679
|
-
|
|
689
|
+
$,
|
|
680
690
|
m,
|
|
681
691
|
J,
|
|
682
692
|
P,
|
|
683
|
-
|
|
693
|
+
Q
|
|
684
694
|
]);
|
|
685
695
|
return ne(r, () => ({
|
|
686
696
|
getOtherOptionValue: () => K,
|
|
@@ -690,23 +700,23 @@ var we = (e) => {
|
|
|
690
700
|
}), [K, m]), /* @__PURE__ */ C(pe.Provider, {
|
|
691
701
|
value: xe,
|
|
692
702
|
children: /* @__PURE__ */ C(me.Provider, {
|
|
693
|
-
value:
|
|
703
|
+
value: Ce,
|
|
694
704
|
children: /* @__PURE__ */ C(he.Provider, {
|
|
695
|
-
value:
|
|
705
|
+
value: Ee,
|
|
696
706
|
children: /* @__PURE__ */ w("div", {
|
|
697
707
|
className: N("bsy-select-container text-sm", e.className),
|
|
698
708
|
style: {
|
|
699
|
-
|
|
709
|
+
...Se,
|
|
700
710
|
...e.style
|
|
701
711
|
},
|
|
702
712
|
children: [
|
|
703
713
|
/* @__PURE__ */ C("div", {
|
|
704
|
-
ref:
|
|
714
|
+
ref: De.setReference,
|
|
705
715
|
className: N("bsy-select-input-event", e.inputClassName),
|
|
706
|
-
...
|
|
707
|
-
style:
|
|
716
|
+
...ke(),
|
|
717
|
+
style: je,
|
|
708
718
|
onClick: () => {
|
|
709
|
-
e.disabled ||
|
|
719
|
+
e.disabled || Q(!Y);
|
|
710
720
|
},
|
|
711
721
|
role: "combobox",
|
|
712
722
|
"aria-expanded": Y,
|
|
@@ -726,37 +736,37 @@ var we = (e) => {
|
|
|
726
736
|
ghost: x,
|
|
727
737
|
inputValueStyle: S,
|
|
728
738
|
tagStyle: T,
|
|
729
|
-
onClear:
|
|
739
|
+
onClear: Fe
|
|
730
740
|
})
|
|
731
741
|
}),
|
|
732
742
|
/* @__PURE__ */ w(ue, {
|
|
733
|
-
root:
|
|
743
|
+
root: Me,
|
|
734
744
|
children: [Y && e.showMask ? /* @__PURE__ */ C("div", {
|
|
735
745
|
className: "bsy-select-mask",
|
|
736
746
|
style: { zIndex: R }
|
|
737
747
|
}) : null, /* @__PURE__ */ C(n, {
|
|
738
748
|
zIndex: F,
|
|
739
749
|
children: /* @__PURE__ */ C(ce, {
|
|
740
|
-
onExitComplete:
|
|
750
|
+
onExitComplete: Pe,
|
|
741
751
|
children: Y ? /* @__PURE__ */ C(le.div, {
|
|
742
|
-
ref:
|
|
752
|
+
ref: De.setFloating,
|
|
743
753
|
style: {
|
|
744
|
-
...
|
|
754
|
+
...Oe,
|
|
745
755
|
zIndex: F
|
|
746
756
|
},
|
|
747
|
-
...
|
|
757
|
+
...Ae(),
|
|
748
758
|
id: B,
|
|
749
759
|
...o,
|
|
750
|
-
children: /* @__PURE__ */ C(
|
|
760
|
+
children: /* @__PURE__ */ C(we, {
|
|
751
761
|
...e,
|
|
752
762
|
options: a,
|
|
753
763
|
onPopupScroll: _,
|
|
754
|
-
themeStyle:
|
|
764
|
+
themeStyle: Se
|
|
755
765
|
})
|
|
756
766
|
}, "bsy-select-panel") : null
|
|
757
767
|
})
|
|
758
768
|
})]
|
|
759
|
-
},
|
|
769
|
+
}, Ne),
|
|
760
770
|
ye && D === "bottom" ? e.otherOptionRender ? e.otherOptionRender(K, a) : /* @__PURE__ */ C("div", {
|
|
761
771
|
className: "bsy-select-other-input",
|
|
762
772
|
children: /* @__PURE__ */ C("input", {
|
|
@@ -776,6 +786,6 @@ var we = (e) => {
|
|
|
776
786
|
})
|
|
777
787
|
});
|
|
778
788
|
});
|
|
779
|
-
|
|
789
|
+
Ee.displayName = "BsySelect";
|
|
780
790
|
//#endregion
|
|
781
|
-
export { I as n, L as r,
|
|
791
|
+
export { I as n, L as r, Ee as t };
|
package/dist/Select/index.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import "../vendors/version-
|
|
1
|
+
import "../vendors/version-Gt_7aQUl.js";
|
|
2
2
|
import "../ScrollBar/style-D26azwz6.js";
|
|
3
3
|
import "../Icon/Icon-CcKDWNGy.js";
|
|
4
4
|
import "../vendors/LocaleContext-CsTLO_Y2.js";
|
|
5
5
|
import "../Overlay/OverlayContext-CVSFoyqN.js";
|
|
6
6
|
import "../vendors/useLocale-DvhRopWF.js";
|
|
7
7
|
import "../vendors/useLatchedPopupPortalRoot-Cu3oUL9h.js";
|
|
8
|
-
import { n as e, r as t, t as n } from "./Select-
|
|
8
|
+
import { n as e, r as t, t as n } from "./Select-DwBd8HaW.js";
|
|
9
9
|
import "./SelectInputSearch-Bt2i3y3d.js";
|
|
10
|
-
import "../vendors/Tree-
|
|
11
|
-
import "../CheckBox/CheckBox-
|
|
12
|
-
import "../CheckBox/CheckBox-
|
|
13
|
-
import "../Radio/Radio-
|
|
10
|
+
import "../vendors/Tree-D5ZZzoPS.js";
|
|
11
|
+
import "../CheckBox/CheckBox-Ck2mN3aJ.js";
|
|
12
|
+
import "../CheckBox/CheckBox-D5gtYO8N.js";
|
|
13
|
+
import "../Radio/Radio-NvTetWb5.js";
|
|
14
14
|
import "../NotFoundContent/NotFoundContent-DJUQ0_2D.js";
|
|
15
15
|
import "../ScrollBar/ScrollBar-DJ6DaHDb.js";
|
|
16
16
|
import "../vendors/useFloatingPortal-DJ1iKmW-.js";
|
package/dist/Table/index.js
CHANGED
package/dist/Tabs/index.js
CHANGED
package/dist/Tooltip/index.js
CHANGED
package/dist/Tree/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import "../vendors/version-
|
|
1
|
+
import "../vendors/version-Gt_7aQUl.js";
|
|
2
2
|
import "../Icon/Icon-CcKDWNGy.js";
|
|
3
|
-
import { t as e } from "../vendors/Tree-
|
|
4
|
-
import "../CheckBox/CheckBox-
|
|
5
|
-
import "../Radio/Radio-
|
|
3
|
+
import { t as e } from "../vendors/Tree-D5ZZzoPS.js";
|
|
4
|
+
import "../CheckBox/CheckBox-Ck2mN3aJ.js";
|
|
5
|
+
import "../Radio/Radio-NvTetWb5.js";
|
|
6
6
|
export { e as Tree };
|
|
@@ -55,65 +55,3 @@ export declare const FADE_ANIMATION: {
|
|
|
55
55
|
readonly ease: "easeInOut";
|
|
56
56
|
};
|
|
57
57
|
};
|
|
58
|
-
export declare const SLIDE_DOWN_ANIMATION: {
|
|
59
|
-
readonly initial: {
|
|
60
|
-
readonly opacity: 0;
|
|
61
|
-
readonly y: -10;
|
|
62
|
-
};
|
|
63
|
-
readonly animate: {
|
|
64
|
-
readonly opacity: 1;
|
|
65
|
-
readonly y: 0;
|
|
66
|
-
};
|
|
67
|
-
readonly exit: {
|
|
68
|
-
readonly opacity: 0;
|
|
69
|
-
readonly y: -10;
|
|
70
|
-
};
|
|
71
|
-
readonly transition: {
|
|
72
|
-
readonly duration: 0.2;
|
|
73
|
-
readonly ease: "easeOut";
|
|
74
|
-
};
|
|
75
|
-
};
|
|
76
|
-
export declare const SLIDE_UP_ANIMATION: {
|
|
77
|
-
readonly initial: {
|
|
78
|
-
readonly opacity: 0;
|
|
79
|
-
readonly y: 10;
|
|
80
|
-
};
|
|
81
|
-
readonly animate: {
|
|
82
|
-
readonly opacity: 1;
|
|
83
|
-
readonly y: 0;
|
|
84
|
-
};
|
|
85
|
-
readonly exit: {
|
|
86
|
-
readonly opacity: 0;
|
|
87
|
-
readonly y: 10;
|
|
88
|
-
};
|
|
89
|
-
readonly transition: {
|
|
90
|
-
readonly duration: 0.2;
|
|
91
|
-
readonly ease: "easeOut";
|
|
92
|
-
};
|
|
93
|
-
};
|
|
94
|
-
export declare const TOAST_ANIMATION: {
|
|
95
|
-
readonly initial: {
|
|
96
|
-
readonly opacity: 0;
|
|
97
|
-
readonly y: -50;
|
|
98
|
-
readonly scale: 0.8;
|
|
99
|
-
};
|
|
100
|
-
readonly animate: {
|
|
101
|
-
readonly opacity: 1;
|
|
102
|
-
readonly y: 0;
|
|
103
|
-
readonly scale: 1;
|
|
104
|
-
};
|
|
105
|
-
readonly exit: {
|
|
106
|
-
readonly opacity: 0;
|
|
107
|
-
readonly y: -50;
|
|
108
|
-
readonly scale: 0.8;
|
|
109
|
-
readonly transition: {
|
|
110
|
-
readonly duration: 0.3;
|
|
111
|
-
readonly ease: "easeOut";
|
|
112
|
-
};
|
|
113
|
-
};
|
|
114
|
-
readonly transition: {
|
|
115
|
-
readonly type: "spring";
|
|
116
|
-
readonly damping: 20;
|
|
117
|
-
readonly stiffness: 220;
|
|
118
|
-
};
|
|
119
|
-
};
|
|
@@ -14,7 +14,6 @@ export declare const addDays: (date: Date, days: number, timeZone?: string) => D
|
|
|
14
14
|
export declare const addWeeks: (date: Date, weeks: number, timeZone?: string) => Date;
|
|
15
15
|
export declare const addMonths: (date: Date, months: number, timeZone?: string) => Date;
|
|
16
16
|
export declare const shiftDateByMode: (date: Date, mode: CalendarMode, delta: -1 | 1, timeZone?: string) => Date;
|
|
17
|
-
export declare const getMonthWeekCount: (date: Date, timeZone?: string) => number;
|
|
18
17
|
export declare const getDynamicMonthViewDates: (date: Date, timeZone?: string) => Dayjs[];
|
|
19
18
|
export declare const getMonthViewRange: (date: Date, timeZone?: string) => {
|
|
20
19
|
start: Dayjs;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { Dayjs } from 'dayjs';
|
|
2
2
|
import { CalendarFormatMessage, NormalizedCalendarDataItem } from '../types.internal';
|
|
3
|
-
import { CalendarTimeInput } from '../interface';
|
|
4
3
|
export declare const getCalendarEventId: (event: {
|
|
5
4
|
id: string | number;
|
|
6
5
|
}) => string | number;
|
|
@@ -40,5 +39,3 @@ export declare const toAbsolutePosition: (layoutEvent: {
|
|
|
40
39
|
};
|
|
41
40
|
/** 半开区间重叠(已解析的 dayjs 实例,供 filter + clamp 热路径复用)。 */
|
|
42
41
|
export declare const overlapsHalfOpenInstant: (start: Dayjs, end: Dayjs, rangeStart: Dayjs, rangeEnd: Dayjs) => boolean;
|
|
43
|
-
/** 半开区间重叠判断:[eventStart, eventEnd) 与 [rangeStart, rangeEnd) */
|
|
44
|
-
export declare const overlapsRangeHalfOpen: (eventStart: CalendarTimeInput, eventEnd: CalendarTimeInput, rangeStart: CalendarTimeInput, rangeEnd: CalendarTimeInput, timeZone?: string) => boolean;
|
|
@@ -16,15 +16,6 @@ export declare function calculateSegmentPosition(segment: any): {
|
|
|
16
16
|
left: string;
|
|
17
17
|
width: string;
|
|
18
18
|
};
|
|
19
|
-
/**
|
|
20
|
-
* Phase 1: 全局行分配算法
|
|
21
|
-
* 为整月的事件分配全局一致的行号,确保跨天、跨周事件保持相同行号
|
|
22
|
-
* @param {Array} events - 日历事件数组
|
|
23
|
-
* @param {dayjs.Dayjs} gridStart - 月视图起始日期
|
|
24
|
-
* @param {number} dayCount - 总天数(35或42)
|
|
25
|
-
* @returns {Map<string, number>} eventId -> rowIndex 的映射
|
|
26
|
-
*/
|
|
27
|
-
export declare function assignGlobalRows(events: any, gridStart: any, dayCount: any, timeZone: any): Map<any, any>;
|
|
28
19
|
/**
|
|
29
20
|
* Phase 2: 可见性裁剪算法
|
|
30
21
|
* 按天从左到右遍历,确定哪些事件需要隐藏
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
/** 当前时间线固定色,不进 theme 配置 */
|
|
2
|
-
export declare const CALENDAR_CURRENT_TIME_COLOR = "#ff5631";
|
|
3
1
|
export { resolveCalendarThemeVars } from './resolveCalendarThemeVars';
|
|
4
2
|
export { resolveDatePickerThemeFromCalendar, resolveSegmentedThemeFromCalendar, } from './resolveSubcomponentThemes';
|
|
5
3
|
export { resolveScheduleColorVars } from './resolveScheduleColorVars';
|
|
@@ -11,10 +11,6 @@ export declare const buildBufferedTimelineRange: (timeRangeConfig?: TimeRangeCon
|
|
|
11
11
|
startMs: number;
|
|
12
12
|
endMs: number;
|
|
13
13
|
};
|
|
14
|
-
export declare const buildTodayTimelineRange: (timeRangeConfig?: TimeRangeConfig, nowMs?: number) => {
|
|
15
|
-
startMs: number;
|
|
16
|
-
endMs: number;
|
|
17
|
-
};
|
|
18
14
|
export declare const alignRangeToViewMode: (startMs: number, endMs: number, viewMode: GanttMode) => {
|
|
19
15
|
startMs: number;
|
|
20
16
|
endMs: number;
|
|
@@ -29,7 +25,3 @@ export declare const buildTimelineCoords: ({ viewMode, timelineStartMs, timeline
|
|
|
29
25
|
pixelsPerDay: number;
|
|
30
26
|
lowerSegments: LowerSegment[];
|
|
31
27
|
}) => TimelineCoords;
|
|
32
|
-
export declare const buildCenteredTimelineRange: (centerMs: number, spanMs: number) => {
|
|
33
|
-
startMs: number;
|
|
34
|
-
endMs: number;
|
|
35
|
-
};
|
|
@@ -47,7 +47,6 @@ export type GanttSubDayMode = (typeof SUB_DAY_MODES)[number];
|
|
|
47
47
|
export declare const GANTT_MODE_DISPLAY_ORDER: readonly [...("oneMinute" | "tenMinute" | "halfHour" | "hour" | "sixHour" | "halfDay")[], "day", "week", "month", "quarter", "quarterMonth", "year"];
|
|
48
48
|
export declare const DEFAULT_GANTT_MODE: GanttMode;
|
|
49
49
|
export declare function isGanttMode(mode: string): mode is GanttMode;
|
|
50
|
-
export declare function isCalendarViewMode(mode: GanttMode): mode is GanttCalendarMode;
|
|
51
50
|
export declare function isSubDayMode(mode: GanttMode): mode is GanttSubDayMode;
|
|
52
51
|
export type GanttTimeInput = string | number | Date | null;
|
|
53
52
|
export interface GanttDragPermission {
|
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
import { FieldNames, DefaultOptionType } from '../interface';
|
|
2
|
+
export declare function findOptionByValue(nodes: DefaultOptionType[] | undefined, value: DefaultOptionType['value'], fieldNames: FieldNames): DefaultOptionType | undefined;
|
|
2
3
|
export declare const flatTree: (tree: DefaultOptionType[], fieldNames: FieldNames) => DefaultOptionType[];
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "./vendors/version-
|
|
1
|
+
import "./vendors/version-Gt_7aQUl.js";
|
|
2
2
|
import "./ScrollBar/style-D26azwz6.js";
|
|
3
3
|
import { t as e } from "./Icon/Icon-CcKDWNGy.js";
|
|
4
4
|
import "./vendors/LocaleContext-CsTLO_Y2.js";
|
|
@@ -14,12 +14,12 @@ import "./vendors/useLocale-DvhRopWF.js";
|
|
|
14
14
|
import "./vendors/useLatchedPopupPortalRoot-Cu3oUL9h.js";
|
|
15
15
|
import { t as _ } from "./Segmented/Segmented-AHLqTK7U.js";
|
|
16
16
|
import { n as v, t as y } from "./Tooltip/Tooltip-N-w19uRu.js";
|
|
17
|
-
import { t as b } from "./Select/Select-
|
|
17
|
+
import { t as b } from "./Select/Select-DwBd8HaW.js";
|
|
18
18
|
import "./Select/SelectInputSearch-Bt2i3y3d.js";
|
|
19
|
-
import { t as x } from "./vendors/Tree-
|
|
20
|
-
import "./CheckBox/CheckBox-
|
|
21
|
-
import { t as S } from "./CheckBox/CheckBox-
|
|
22
|
-
import { t as C } from "./Radio/Radio-
|
|
19
|
+
import { t as x } from "./vendors/Tree-D5ZZzoPS.js";
|
|
20
|
+
import "./CheckBox/CheckBox-Ck2mN3aJ.js";
|
|
21
|
+
import { t as S } from "./CheckBox/CheckBox-D5gtYO8N.js";
|
|
22
|
+
import { t as C } from "./Radio/Radio-NvTetWb5.js";
|
|
23
23
|
import { t as w } from "./NotFoundContent/NotFoundContent-DJUQ0_2D.js";
|
|
24
24
|
import { t as T } from "./ScrollBar/ScrollBar-DJ6DaHDb.js";
|
|
25
25
|
import "./vendors/useFloatingPortal-DJ1iKmW-.js";
|
|
@@ -29,8 +29,8 @@ import { t as O } from "./DropDown/DropDown-D97QGQpV.js";
|
|
|
29
29
|
import { t as k } from "./Loading/Loading-CLUJfdln.js";
|
|
30
30
|
import "./NotFoundContent/index.js";
|
|
31
31
|
import { t as A } from "./InputTag/InputTag-5NTrA5bA.js";
|
|
32
|
-
import { t as j } from "./Calendar/Calendar
|
|
33
|
-
import { t as M } from "./DatePicker/DatePicker-
|
|
32
|
+
import { t as j } from "./Calendar/Calendar--OiKstox.js";
|
|
33
|
+
import { t as M } from "./DatePicker/DatePicker-MDfmIJrN.js";
|
|
34
34
|
import "./DatePicker/pickerLocale-Brf7_Tnd.js";
|
|
35
35
|
import { a as N, c as P, d as F, f as I, g as L, h as R, i as z, l as B, m as V, n as H, o as U, p as W, r as G, t as K, u as q } from "./Table/Table-B7fDob3i.js";
|
|
36
36
|
import { t as J } from "./FieldCard/FieldCard-CTrNTXFc.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { t as e } from "../Icon/Icon-CcKDWNGy.js";
|
|
2
|
-
import { t } from "../CheckBox/CheckBox-
|
|
3
|
-
import { t as n } from "../Radio/Radio-
|
|
2
|
+
import { t } from "../CheckBox/CheckBox-Ck2mN3aJ.js";
|
|
3
|
+
import { t as n } from "../Radio/Radio-NvTetWb5.js";
|
|
4
4
|
import { isString as r, noop as i } from "lodash-es";
|
|
5
5
|
import { Fragment as a, jsx as o, jsxs as s } from "react/jsx-runtime";
|
|
6
6
|
import c, { createContext as l, useCallback as u, useContext as d, useEffect as f, useMemo as p } from "react";
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default } from './AllDaySection';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default } from './CurrentTimeIndicator';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default } from './EventCard';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default } from './TimeAxis';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default } from './TimeGrid';
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/** 内部 barrel;公开 API 请从 `@baishuyun/ui-base/Gantt` 导入 */
|
|
2
|
-
export { GANTT_DEFAULT_ROW_HEIGHT, GANTT_TABLE_HEADER_ROW_SPAN, MIN_TABLE_WIDTH, HEADER_TOP_HEIGHT, HEADER_BOTTOM_HEIGHT, DRAG_MODE_MOVE, DRAG_MODE_RESIZE_START, DRAG_MODE_RESIZE_END, EMPTY_GROUP_VALUE, } from '../GanttChart/utils/constants';
|
|
3
|
-
export { DEFAULT_TABLE_WIDTH_FALLBACK, TABLE_WIDTH_PLACEHOLDER, MIN_CHART_WIDTH, } from './constants';
|
|
4
|
-
export { isGroupCollapsed, toggleCollapsedKey } from './collapseKeys';
|
|
5
|
-
export { isSameHighlightTarget, isHighlightMatch, resolveChartHighlightTarget, } from './highlightTarget';
|
|
6
|
-
export { GANTT_TABLE_DISABLED_RESIZE_COLUMNS, mergeColumnWidths, useGanttTableColumnResize, } from './columnResize';
|
|
7
|
-
export { normalizeTaskDateRange } from '../GanttChart/utils/dateRangeNormalizer';
|
|
8
|
-
export { isSubDayViewMode, ALL_GANTT_MODES, CALENDAR_TIER_MODES, DEFAULT_GANTT_MODE, } from '../GanttChart/utils/timelineViewConfig';
|
package/dist/utils/color.d.ts
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* 将一个十六进制颜色字符串转换为带有指定透明度的 RGBA 颜色字符串。
|
|
3
|
-
* @param {string} hex - 十六进制颜色字符串 (例如, "#RRGGBB" 或 "#RGB").
|
|
4
|
-
* @param {number} alpha - 透明度值,介于 0 (完全透明) 和 1 (完全不透明) 之间。
|
|
5
|
-
* 返回 RGBA 格式的颜色字符串,如果输入无效则返回 null。
|
|
6
|
-
*/
|
|
7
|
-
export declare function hexToRgba(hex: string, alpha: number): string | null;
|
|
8
|
-
declare const areColorsSame: (colorA: string, colorB: string) => boolean;
|
|
9
|
-
export { areColorsSame };
|