@ithinkdt/ui 4.0.19 → 4.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.
- package/esm/{DataTable-2vtI02wP.js → DataTable-BVifHuTW.js} +3 -3
- package/esm/{components-DLa9-kdK.js → components-Gbs1QIjp.js} +7 -11
- package/esm/components.js +1 -1
- package/esm/composables.d.ts +2 -2
- package/esm/composables.js +2 -2
- package/esm/{directives-Chz4DK1u.js → directives-G7hy3akL.js} +1 -1
- package/esm/directives.js +1 -1
- package/esm/index.d.ts +2 -2
- package/esm/index.js +2 -2
- package/esm/page.d.ts +4 -4
- package/esm/page.js +10 -9
- package/esm/use-style.js +22 -22
- package/esm/{use-table-range-select-Da6t9Vlf.js → use-table-range-select-BTC3NnsD.js} +4 -4
- package/package.json +8 -8
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import e, { c as t, cB as n, cE as r, cM as i, useClsPrefix as a } from "./use-style.js";
|
|
2
|
-
import { i as o } from "./directives-
|
|
3
|
-
import { C as s } from "./components-
|
|
4
|
-
import { t as c } from "./use-table-range-select-
|
|
2
|
+
import { i as o } from "./directives-G7hy3akL.js";
|
|
3
|
+
import { C as s } from "./components-Gbs1QIjp.js";
|
|
4
|
+
import { t as c } from "./use-table-range-select-BTC3NnsD.js";
|
|
5
5
|
import { computed as l, createVNode as u, defineComponent as d, inject as f, isVNode as p, ref as m, shallowRef as h, toValue as g, useTemplateRef as _, watch as v, withDirectives as y } from "vue";
|
|
6
6
|
import { toReactive as b, until as x } from "@vueuse/core";
|
|
7
7
|
import { NButton as S, NDataTable as C, NFlex as w, NIcon as T, NTooltip as E, dataTableProps as D } from "ithinkdt-ui";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as e } from "./use-i18n-BUP_StIp.js";
|
|
2
2
|
import t, { cB as n, cE as r, useClsPrefix as i } from "./use-style.js";
|
|
3
|
-
import { i as a } from "./directives-
|
|
3
|
+
import { i as a } from "./directives-G7hy3akL.js";
|
|
4
4
|
import { Fragment as o, computed as s, createTextVNode as c, createVNode as l, defineAsyncComponent as u, defineComponent as d, h as f, inject as p, isVNode as m, markRaw as h, mergeProps as g, nextTick as _, onBeforeUnmount as v, reactive as y, ref as b, renderSlot as x, shallowRef as S, toRaw as C, toRef as w, toValue as T, unref as E, useTemplateRef as D, watch as O, withDirectives as k } from "vue";
|
|
5
5
|
import { onClickOutside as A, until as j, useElementHover as M, useFullscreen as N } from "@vueuse/core";
|
|
6
6
|
import { NAnchor as P, NAnchorLink as F, NAvatar as I, NAvatarGroup as ee, NBadge as te, NButton as L, NCard as ne, NCheckbox as R, NCheckboxGroup as re, NDropdown as ie, NEllipsis as ae, NEmpty as oe, NFlex as z, NForm as se, NFormItem as ce, NGi as le, NGrid as ue, NIcon as B, NInput as V, NList as de, NListItem as fe, NPagination as pe, NPopover as H, NRadio as me, NRadioButton as he, NRadioGroup as ge, NScrollbar as _e, NSelect as ve, NSpin as ye, NTag as be, NText as xe, NTooltip as Se, NTransfer as Ce, NTree as we, NTreeSelect as Te, formProps as U, useDialog as Ee } from "ithinkdt-ui";
|
|
@@ -1175,7 +1175,7 @@ var bt = /* @__PURE__ */ d({
|
|
|
1175
1175
|
size: "20",
|
|
1176
1176
|
depth: "3"
|
|
1177
1177
|
}, { default: () => [o.value ? l(Qe, null, null) : l(Ze, null, null)] })] }), u = (t) => {
|
|
1178
|
-
let n = t.split("-")[0];
|
|
1178
|
+
let n = t.split("-", 1)[0];
|
|
1179
1179
|
return e.supports.some((e) => e.value !== t && e.value.startsWith(n)) ? t : n;
|
|
1180
1180
|
}, d = `__slots${De(6)}`;
|
|
1181
1181
|
O(() => e.supports, (e) => {
|
|
@@ -1947,12 +1947,8 @@ var jt = /* @__PURE__ */ d({
|
|
|
1947
1947
|
disabled: t.disabled || void 0,
|
|
1948
1948
|
value: r,
|
|
1949
1949
|
filter: (e, t) => t.label.includes(e) || t.value.includes(e),
|
|
1950
|
-
"onUpdate:value":
|
|
1951
|
-
|
|
1952
|
-
},
|
|
1953
|
-
onUpdateValue: (e) => {
|
|
1954
|
-
a?.(e);
|
|
1955
|
-
}
|
|
1950
|
+
"onUpdate:value": i,
|
|
1951
|
+
onUpdateValue: a
|
|
1956
1952
|
}), null), k = ({ option: e, handleClose: n }) => l(be, {
|
|
1957
1953
|
type: t.type === "user" ? "primary" : "info",
|
|
1958
1954
|
closable: !0,
|
|
@@ -1970,7 +1966,7 @@ var jt = /* @__PURE__ */ d({
|
|
|
1970
1966
|
showIcon: !1,
|
|
1971
1967
|
title: t.placeholder,
|
|
1972
1968
|
style: { width: "700px" },
|
|
1973
|
-
content: () => l("div", { style: { height: "550px" } }, [D({ style: { height: "100%" } }, t.type === "user" ? f.value : p.value, e.value, (t) => e.value = t)]),
|
|
1969
|
+
content: () => l("div", { style: { height: "550px" } }, [D({ style: { height: "100%" } }, t.type === "user" ? f.value : p.value, e.value, (t) => e.value = t, void 0)]),
|
|
1974
1970
|
positiveText: a.value.positiveText,
|
|
1975
1971
|
negativeText: a.value.negativeText,
|
|
1976
1972
|
onPositiveClick() {
|
|
@@ -2027,7 +2023,7 @@ var jt = /* @__PURE__ */ d({
|
|
|
2027
2023
|
});
|
|
2028
2024
|
function Q(e, t, { placement: n = "left", size: r = 24, tooltip: i = !0, username: a = !1, renderInfo: o }) {
|
|
2029
2025
|
let s = e.nickname.split(" ").at(-1), c = s;
|
|
2030
|
-
if (/^[\
|
|
2026
|
+
if (/^[\u{4E00}-\u{9FA5}]+$/u.test(s)) {
|
|
2031
2027
|
let e = s.length;
|
|
2032
2028
|
c = e === 3 || e === 4 ? s.slice(-2) : e > 4 ? s.slice(0, 1) : s;
|
|
2033
2029
|
} else s.length > 4 && (c = l(B, null, { default: () => [l(nt, null, null)] }));
|
|
@@ -2162,6 +2158,6 @@ var Mt = /* @__PURE__ */ d({
|
|
|
2162
2158
|
});
|
|
2163
2159
|
};
|
|
2164
2160
|
}
|
|
2165
|
-
}), It = u(() => import("./DataTable-
|
|
2161
|
+
}), It = u(() => import("./DataTable-BVifHuTW.js").then((e) => e.DataTable));
|
|
2166
2162
|
//#endregion
|
|
2167
2163
|
export { Re as C, ot as S, gt as _, jt as a, pt as b, At as c, Tt as d, Ct as f, _t as g, yt as h, Mt as i, Ot as l, bt as m, Ft as n, Nt as o, X as p, Pt as r, $ as s, It as t, Et as u, Y as v, Le as w, ct as x, J as y };
|
package/esm/components.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { S as e, _ as t, a as n, b as r, c as i, d as a, f as o, g as s, h as c, i as l, l as u, m as d, n as f, o as p, p as m, r as h, s as g, t as _, u as v, v as y, w as b, x, y as S } from "./components-
|
|
1
|
+
import { S as e, _ as t, a as n, b as r, c as i, d as a, f as o, g as s, h as c, i as l, l as u, m as d, n as f, o as p, p as m, r as h, s as g, t as _, u as v, v as y, w as b, x, y as S } from "./components-Gbs1QIjp.js";
|
|
2
2
|
export { e as DataActions, x as DataCustom, r as DataDescriptions, s as DataFilter, t as DataForm, y as DataFormActions, d as DataLocaleInput, m as DataPagination, a as DataSelection, _ as DataTable, l as DtDeptRender, n as DtUserDept, p as DtUserRender, v as FullscreenButton, u as FullscreenWrapper, b as NCheckboxes, i as NRadios, f as NStateButton, h as StateButtonProps, o as ViewProfile, S as dataFormActionsProps, g as renderUsers, c as useLocaleEdit };
|
package/esm/composables.d.ts
CHANGED
|
@@ -4,10 +4,10 @@ import { InjectionKey, MaybeRef, ShallowRef, TemplateRef } from 'vue'
|
|
|
4
4
|
|
|
5
5
|
export declare function useDataTableDrag<T>(
|
|
6
6
|
tableRef: TemplateRef<HTMLElement>,
|
|
7
|
-
options: {
|
|
7
|
+
options: Omit<Sortable.Options, 'onSort'> & {
|
|
8
8
|
data: MaybeRef<T[]>
|
|
9
9
|
onSort: (info: { from: number, to: number }) => void
|
|
10
|
-
}
|
|
10
|
+
},
|
|
11
11
|
): void
|
|
12
12
|
|
|
13
13
|
/**
|
package/esm/composables.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as e } from "./use-table-range-select-
|
|
1
|
+
import { t as e } from "./use-table-range-select-BTC3NnsD.js";
|
|
2
2
|
import { nextTick as t, ref as n, watch as r } from "vue";
|
|
3
3
|
import { unrefElement as i } from "@vueuse/core";
|
|
4
4
|
import { Sortable as a } from "sortablejs";
|
|
@@ -7,7 +7,7 @@ function o(e, { data: o, onSort: s, ...c }) {
|
|
|
7
7
|
r([n(o), e], async ([e, n]) => {
|
|
8
8
|
if (e.length === 0) return;
|
|
9
9
|
await t();
|
|
10
|
-
let r = i(n)?.querySelector(".n-data-table-base-table-body .n-data-table-tbody");
|
|
10
|
+
let r = i(n)?.querySelector(":scope .n-data-table-base-table-body .n-data-table-tbody");
|
|
11
11
|
if (!r) return;
|
|
12
12
|
let o = a.create(r, {
|
|
13
13
|
animation: 150,
|
|
@@ -83,7 +83,7 @@ var O, k, A, j = /* @__PURE__ */ s({
|
|
|
83
83
|
"right",
|
|
84
84
|
"left",
|
|
85
85
|
"bottom"
|
|
86
|
-
].find((t) => e.startsWith(t))) ?? "top", r.placement.split("-")[0]) {
|
|
86
|
+
].find((t) => e.startsWith(t))) ?? "top", r.placement.split("-", 1)[0]) {
|
|
87
87
|
case "top":
|
|
88
88
|
r.x = t.left + t.width / 2, r.y = t.top;
|
|
89
89
|
break;
|
package/esm/directives.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { i as e, n as t, r as n, t as r } from "./directives-
|
|
1
|
+
import { i as e, n as t, r as n, t as r } from "./directives-G7hy3akL.js";
|
|
2
2
|
export { r as SpinDirectiveProvider, n as TooltipDirectiveProvider, t as vSpin, e as vTooltip };
|
package/esm/index.d.ts
CHANGED
|
@@ -4,11 +4,11 @@ import { I18nComposable, ParseMessage } from '@ithinkdt/common/i18n'
|
|
|
4
4
|
|
|
5
5
|
import { UILocale } from '../locale.js'
|
|
6
6
|
|
|
7
|
+
export { UILocale } from '../locale.js'
|
|
8
|
+
|
|
7
9
|
export * from './directives.js'
|
|
8
10
|
export * from './design.js'
|
|
9
11
|
|
|
10
|
-
export { UILocale }
|
|
11
|
-
|
|
12
12
|
/** Props for {@link UIProvider} */
|
|
13
13
|
export interface UIProviderProps {
|
|
14
14
|
i18n?: I18nComposable<ParseMessage<UILocale, 'common'>>
|
package/esm/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as e, t } from "./use-i18n-BUP_StIp.js";
|
|
2
2
|
import n, { c as r, cB as i, cE as a, cM as o } from "./use-style.js";
|
|
3
|
-
import { i as s, n as c, r as l, t as u } from "./directives-
|
|
3
|
+
import { i as s, n as c, r as l, t as u } from "./directives-G7hy3akL.js";
|
|
4
4
|
import { Fragment as d, computed as f, createVNode as p, defineComponent as m, inject as h, isVNode as g, mergeProps as _, provide as v, reactive as y, ref as b, renderSlot as x, shallowRef as S, toRef as C, toValue as w, unref as T, useTemplateRef as E, watch as D, withDirectives as O } from "vue";
|
|
5
5
|
import { computedAsync as ee, promiseTimeout as k, useElementHover as A, useElementSize as te, useEventListener as ne, watchDebounced as re } from "@vueuse/core";
|
|
6
6
|
import { NAvatar as j, NBadge as ie, NBreadcrumb as ae, NBreadcrumbItem as oe, NButton as M, NDrawer as se, NDrawerContent as ce, NDropdown as N, NEmpty as le, NIcon as P, NInput as F, NList as I, NListItem as L, NMenu as R, NPagination as z, NPopover as B, NScrollbar as V, NText as H, NThing as U, useThemeVars as W } from "ithinkdt-ui";
|
|
@@ -32,7 +32,7 @@ var _e = /* @__PURE__ */ m({
|
|
|
32
32
|
},
|
|
33
33
|
emit: ["logout", "change-pwd"],
|
|
34
34
|
setup(t, { emit: n, slots: r }) {
|
|
35
|
-
let i = f(() => /^[\
|
|
35
|
+
let i = f(() => /^[\u{4E00}-\u{9FA5}]+$/u.test(t.nickname) ? t.nickname?.slice(t.nickname?.length > 3 ? 2 : 1) : t.nickname?.split(" ", 1)[0]), { t: a } = e(), o = p(P, { size: "28" }, { default: () => [p("svg", {
|
|
36
36
|
xmlns: "http://www.w3.org/2000/svg",
|
|
37
37
|
width: "1em",
|
|
38
38
|
height: "1em",
|
package/esm/page.d.ts
CHANGED
|
@@ -71,7 +71,7 @@ declare module '@ithinkdt/page' {
|
|
|
71
71
|
}
|
|
72
72
|
|
|
73
73
|
file: {
|
|
74
|
-
fileProps?: ShallowMaybeRef<{
|
|
74
|
+
fileProps?: ShallowMaybeRef<PublicProps & {
|
|
75
75
|
type?: 'file' | 'image' | undefined
|
|
76
76
|
multiple?: boolean | undefined
|
|
77
77
|
max?: number | undefined
|
|
@@ -79,13 +79,13 @@ declare module '@ithinkdt/page' {
|
|
|
79
79
|
/** 最大文件大小(单位:KB) */
|
|
80
80
|
maxSize?: number | undefined
|
|
81
81
|
onBeforeUpload?: UploadProps['onBeforeUpload']
|
|
82
|
-
}
|
|
82
|
+
}>
|
|
83
83
|
fileSlots?: {
|
|
84
84
|
default?: (() => VNode[]) | undefined
|
|
85
85
|
}
|
|
86
86
|
}
|
|
87
87
|
upload: {
|
|
88
|
-
uploadProps?: ShallowMaybeRef<{
|
|
88
|
+
uploadProps?: ShallowMaybeRef<PublicProps & {
|
|
89
89
|
type?: 'file' | 'image' | undefined
|
|
90
90
|
multiple?: boolean | undefined
|
|
91
91
|
max?: number | undefined
|
|
@@ -94,7 +94,7 @@ declare module '@ithinkdt/page' {
|
|
|
94
94
|
maxSize?: number | undefined
|
|
95
95
|
onBeforeUpload?: UploadProps['onBeforeUpload']
|
|
96
96
|
defaultUpload?: boolean | undefined
|
|
97
|
-
}
|
|
97
|
+
}>
|
|
98
98
|
uploadSlots?: {
|
|
99
99
|
default?: (() => VNode[]) | undefined
|
|
100
100
|
}
|
package/esm/page.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as e } from "./use-i18n-BUP_StIp.js";
|
|
2
|
-
import { _ as t, a as n, c as r, i, o as a, w as o } from "./components-
|
|
2
|
+
import { _ as t, a as n, c as r, i, o as a, w as o } from "./components-Gbs1QIjp.js";
|
|
3
3
|
import { computed as s, createVNode as c, defineAsyncComponent as l, defineComponent as u, h as d, isVNode as f, mergeProps as p, nextTick as m, ref as h, renderSlot as g, shallowRef as _, toValue as v, unref as y } from "vue";
|
|
4
4
|
import { until as b, useClipboard as x } from "@vueuse/core";
|
|
5
5
|
import { NButton as S, NCheckbox as C, NColorPicker as w, NDrawer as T, NDrawerContent as E, NFlex as D, NIcon as O, NInput as k, NInputNumber as A, NModal as j, NScrollbar as M, NSelect as N, NText as P, NUpload as F, useMessage as I } from "ithinkdt-ui";
|
|
@@ -112,7 +112,7 @@ function K({ getDeptsByCode: e, getUsersByUsername: t, getFileInfos: n, previewF
|
|
|
112
112
|
if (r == null) return;
|
|
113
113
|
let { dictType: o, options: l, multiple: u, statusMap: d } = W(a);
|
|
114
114
|
if (l ? t !== l && (t = l, n = new Map(l.map((e) => [e[a.valueField || "value"], e]))) : e !== o && (e = o, !n && e && (n = U(e))), !u) {
|
|
115
|
-
if (r = r.toString(), d && r
|
|
115
|
+
if (r = r.toString(), d && Object.hasOwn(d, r)) {
|
|
116
116
|
let e = d[r] ?? "default";
|
|
117
117
|
return [
|
|
118
118
|
"primary",
|
|
@@ -339,8 +339,15 @@ function X({ getUserGroups: e, getUsersByGroup: t, getDeptsByCode: i, getUsersBy
|
|
|
339
339
|
O("");
|
|
340
340
|
}, k()) : (n = void 0, t = C) : (n = void 0, e !== b && (e = b, !t && e && (t = H(e))));
|
|
341
341
|
let A = T.multiple ? l?.map(E) : E(l);
|
|
342
|
-
if (g)
|
|
342
|
+
if (g) {
|
|
343
343
|
let e;
|
|
344
|
+
if (!T.multiple) {
|
|
345
|
+
let e = y(t)?.find((e) => e[T.valueField || "value"] === A);
|
|
346
|
+
return c(P, {
|
|
347
|
+
depth: 2,
|
|
348
|
+
style: "line-height: 1.25"
|
|
349
|
+
}, { default: () => [e ? T.renderLabel ? T.renderLabel(e) ?? "" : e[T.labelField || "label"] ?? "" : A ?? ""] });
|
|
350
|
+
}
|
|
344
351
|
return c(P, {
|
|
345
352
|
depth: 2,
|
|
346
353
|
style: "line-height: 1.25"
|
|
@@ -348,12 +355,6 @@ function X({ getUserGroups: e, getUsersByGroup: t, getDeptsByCode: i, getUsersBy
|
|
|
348
355
|
let r = e ? T.renderLabel ? T.renderLabel(e) ?? "" : e[T.labelField || "label"] ?? "" : A[t] ?? "";
|
|
349
356
|
return c("span", { key: e ? e[T.valueField || "value"] : A[t] ?? "" }, [r, t < n.length - 1 ? ", " : ""]);
|
|
350
357
|
})) ? e : { default: () => [e] });
|
|
351
|
-
} else {
|
|
352
|
-
let e = y(t)?.find((e) => e[T.valueField || "value"] === A);
|
|
353
|
-
return c(P, {
|
|
354
|
-
depth: 2,
|
|
355
|
-
style: "line-height: 1.25"
|
|
356
|
-
}, { default: () => [e ? T.renderLabel ? T.renderLabel(e) ?? "" : e[T.labelField || "label"] ?? "" : A ?? ""] });
|
|
357
358
|
}
|
|
358
359
|
return r = T.multiple, i = u, w === "number" && !a && (a = (e, ...t) => {
|
|
359
360
|
i(r ? e?.map(S) : S(e), ...t);
|
package/esm/use-style.js
CHANGED
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
import { useMergedClsPrefix as e } from "ithinkdt-ui/es/_mixins/use-config";
|
|
2
|
-
import
|
|
3
|
-
import { c as
|
|
1
|
+
import { useMergedClsPrefix as e, useMergedClsPrefix as t } from "ithinkdt-ui/es/_mixins/use-config";
|
|
2
|
+
import n from "ithinkdt-ui/es/_mixins/use-style";
|
|
3
|
+
import { c as r, cB as i, cE as a, cM as o } from "ithinkdt-ui/es/_utils/cssr/index";
|
|
4
4
|
//#region src/use-style.js
|
|
5
|
-
function
|
|
6
|
-
return i ??= e(), t
|
|
5
|
+
function s(t, r, i, a) {
|
|
6
|
+
return i ??= e(), n(t, r, i, a), i;
|
|
7
7
|
}
|
|
8
|
-
var
|
|
9
|
-
...
|
|
10
|
-
...
|
|
11
|
-
},
|
|
12
|
-
...
|
|
8
|
+
var c = { width: "100%" }, l = { height: "100%" }, u = {
|
|
9
|
+
...c,
|
|
10
|
+
...l
|
|
11
|
+
}, d = { display: "flex" }, f = {
|
|
12
|
+
...d,
|
|
13
13
|
flexDirection: "column"
|
|
14
|
-
}, f = {
|
|
15
|
-
...u,
|
|
16
|
-
alignItems: "center"
|
|
17
14
|
}, p = {
|
|
18
|
-
...
|
|
19
|
-
|
|
15
|
+
...d,
|
|
16
|
+
alignItems: "center"
|
|
20
17
|
}, m = {
|
|
21
|
-
...
|
|
22
|
-
justifyContent: "
|
|
18
|
+
...d,
|
|
19
|
+
justifyContent: "center"
|
|
23
20
|
}, h = {
|
|
24
|
-
...
|
|
25
|
-
|
|
26
|
-
}, g =
|
|
27
|
-
...
|
|
21
|
+
...d,
|
|
22
|
+
justifyContent: "space-between"
|
|
23
|
+
}, g = {
|
|
24
|
+
...p,
|
|
25
|
+
...m
|
|
26
|
+
}, _ = (e) => ({
|
|
27
|
+
...d,
|
|
28
28
|
gap: e
|
|
29
29
|
});
|
|
30
30
|
//#endregion
|
|
31
|
-
export {
|
|
31
|
+
export { r as c, i as cB, a as cE, o as cM, s as default, d as flex, p as flexAlignCenter, g as flexCenter, f as flexDirCol, _ as flexGap, m as flexJustifyCenter, h as flexJustifySB, l as fullHeight, u as fullWH, c as fullWidth, t as useClsPrefix };
|
|
@@ -29,7 +29,7 @@ function p(p, m = {}) {
|
|
|
29
29
|
ing: !0,
|
|
30
30
|
x1: t.cellIndex,
|
|
31
31
|
y1: n.rowIndex
|
|
32
|
-
},
|
|
32
|
+
}, "getSelection" in globalThis ? getSelection().removeAllRanges() : document.selection && document.selection.empty());
|
|
33
33
|
}, {
|
|
34
34
|
passive: !0,
|
|
35
35
|
capture: !0
|
|
@@ -42,7 +42,7 @@ function p(p, m = {}) {
|
|
|
42
42
|
ing: !1,
|
|
43
43
|
mousedown: !1
|
|
44
44
|
};
|
|
45
|
-
let e = g.value?.querySelector("tbody"), { x0: t, x1: n, y0: r, y1: i } = h.value ?? {};
|
|
45
|
+
let e = g.value?.querySelector(":scope tbody"), { x0: t, x1: n, y0: r, y1: i } = h.value ?? {};
|
|
46
46
|
if (!m?.onSelect && y.value !== "auto" || !e || d(n)) return;
|
|
47
47
|
let [a, o] = [t, n].toSorted((e, t) => e - t), [s, c] = [r, i].toSorted((e, t) => e - t);
|
|
48
48
|
m?.onSelect?.({
|
|
@@ -62,7 +62,7 @@ function p(p, m = {}) {
|
|
|
62
62
|
h.value &&= void 0;
|
|
63
63
|
});
|
|
64
64
|
let C = () => {
|
|
65
|
-
let e = g.value?.querySelector("tbody"), { x0: t, x1: n, y0: r, y1: i } = h.value ?? {};
|
|
65
|
+
let e = g.value?.querySelector(":scope tbody"), { x0: t, x1: n, y0: r, y1: i } = h.value ?? {};
|
|
66
66
|
if (!x.value || !e || d(n)) return [];
|
|
67
67
|
let [a, o] = [t, n].toSorted((e, t) => e - t), [s, c] = [r, i].toSorted((e, t) => e - t), l = [];
|
|
68
68
|
for (let t = s; t <= c; t++) {
|
|
@@ -81,7 +81,7 @@ function p(p, m = {}) {
|
|
|
81
81
|
return l;
|
|
82
82
|
};
|
|
83
83
|
return o([g, h], ([e, { x0: t, x1: n, y0: r, y1: i } = {}]) => {
|
|
84
|
-
let a = e?.querySelector("tbody");
|
|
84
|
+
let a = e?.querySelector(":scope tbody");
|
|
85
85
|
if (!a) return;
|
|
86
86
|
let [o, s] = [t, n].toSorted((e, t) => e - t), [c, l] = [r, i].toSorted((e, t) => e - t);
|
|
87
87
|
for (let e = 0; e < a.rows.length; e++) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ithinkdt/ui",
|
|
3
|
-
"version": "4.0
|
|
3
|
+
"version": "4.1.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"description": "iThinkDT UI",
|
|
@@ -67,13 +67,13 @@
|
|
|
67
67
|
"sortablejs": "^1.15.7",
|
|
68
68
|
"@types/sortablejs": "^1.15.9",
|
|
69
69
|
"nanoid": "^5.1.11",
|
|
70
|
-
"@ithinkdt/common": "^4.0
|
|
70
|
+
"@ithinkdt/common": "^4.1.0"
|
|
71
71
|
},
|
|
72
72
|
"peerDependencies": {
|
|
73
|
-
"@ithinkdt/page": ">=4.
|
|
73
|
+
"@ithinkdt/page": ">=4.1",
|
|
74
74
|
"vue": ">=3.5",
|
|
75
|
-
"vue-router": ">=
|
|
76
|
-
"ithinkdt-ui": ">=1.
|
|
75
|
+
"vue-router": ">=5.1",
|
|
76
|
+
"ithinkdt-ui": ">=1.9",
|
|
77
77
|
"unocss": ">=66"
|
|
78
78
|
},
|
|
79
79
|
"peerDependenciesMeta": {
|
|
@@ -88,12 +88,12 @@
|
|
|
88
88
|
"@vitejs/plugin-vue-jsx": "^5.1.5",
|
|
89
89
|
"ithinkdt-ui": "^1.9.4",
|
|
90
90
|
"typescript": "~6.0.3",
|
|
91
|
-
"unocss": "^66.7.
|
|
91
|
+
"unocss": "^66.7.2",
|
|
92
92
|
"vite": "^8.0.16",
|
|
93
|
-
"vue": "^3.5.
|
|
93
|
+
"vue": "^3.5.38",
|
|
94
94
|
"vue-router": "^5.1.0",
|
|
95
95
|
"@vue/test-utils": "^2.4.11",
|
|
96
|
-
"@ithinkdt/page": "^4.0
|
|
96
|
+
"@ithinkdt/page": "^4.1.0"
|
|
97
97
|
},
|
|
98
98
|
"scripts": {
|
|
99
99
|
"dev": "vite build --watch",
|