dlzn-ui 1.67.0 → 1.68.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/components/checkbox/src/checkbox.vue.d.ts +1 -1
- package/components/form/src/form.d.ts +5 -4
- package/components/form/src/form.vue.d.ts +1 -1
- package/components/form/src/form.vue_vue_type_script_setup_true_lang.mjs +89 -89
- package/components/form/src/form.vue_vue_type_style_index_0_scoped_178687e3_lang.css +2 -0
- package/components/form/src/form2.mjs +2 -2
- package/components/image-viewer/src/image-viewer.vue.d.ts +1 -1
- package/components/index.d.ts +6 -6
- package/components/input-number/src/input-number.vue.d.ts +1 -1
- package/components/popconfirm/src/popconfirm.vue.d.ts +1 -1
- package/components/popup/src/popup.vue.d.ts +1 -1
- package/components/select/src/select.vue.d.ts +4 -4
- package/components/tag/src/tag.vue.d.ts +1 -1
- package/components/tree/src/tree.vue.d.ts +2 -2
- package/components/upload/src/upload.vue.d.ts +2 -2
- package/hooks/useList.d.ts +1 -2
- package/hooks/useList.mjs +10 -10
- package/index.d.ts +14 -15
- package/index.mjs +42 -43
- package/package.json +1 -1
- package/store/modules/router.d.ts +2 -3
- package/store/modules/router.mjs +24 -24
- package/types/globle.d.ts +4 -0
- package/virtual-app-params.d.mjs +0 -0
- package/virtual-app-params.d.ts +6 -0
- package/components/form/src/form.vue_vue_type_style_index_0_scoped_4f6efe42_lang.css +0 -2
- package/entry/appParams.d.ts +0 -11
- package/entry/appParams.mjs +0 -11
|
@@ -5,9 +5,9 @@ declare const __VLS_export: import("vue").DefineComponent<CheckboxProps, {}, {},
|
|
|
5
5
|
}, string, import("vue").PublicProps, Readonly<CheckboxProps> & Readonly<{
|
|
6
6
|
"onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
|
|
7
7
|
}>, {
|
|
8
|
-
value: string | number | boolean;
|
|
9
8
|
disabled: boolean;
|
|
10
9
|
readonly: boolean;
|
|
10
|
+
value: string | number | boolean;
|
|
11
11
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
12
12
|
declare const _default: typeof __VLS_export;
|
|
13
13
|
//#endregion
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { CheckboxGroupProps as CheckboxGroupProps$1 } from "../../checkbox-group/src/checkbox-group.js";
|
|
2
|
+
import "../../checkbox-group/index.js";
|
|
1
3
|
import { CheckboxProps as CheckboxProps$1 } from "../../checkbox/src/checkbox.js";
|
|
2
4
|
import "../../checkbox/index.js";
|
|
3
5
|
import { InputProps as InputProps$1 } from "../../input/src/input.js";
|
|
@@ -24,12 +26,11 @@ import { TreeSelectProps as TreeSelectProps$1 } from "../../tree-select/src/tree
|
|
|
24
26
|
import "../../tree-select/index.js";
|
|
25
27
|
import { UploadProps as UploadProps$1 } from "../../upload/src/upload.js";
|
|
26
28
|
import "../../upload/index.js";
|
|
27
|
-
import { BusComponentPropsMap } from "../../../index.js";
|
|
28
|
-
import { CheckboxGroupProps as CheckboxGroupProps$1 } from "../../checkbox-group/src/checkbox-group.js";
|
|
29
|
-
import "../../checkbox-group/index.js";
|
|
30
29
|
import { FormInstanceFunctions, FormItemProps as FormItemProps$1, FormProps as FormProps$1 } from "tdesign-vue-next";
|
|
31
30
|
import { ClassValue, ComponentPublicInstance, Ref, StyleValue } from "vue";
|
|
31
|
+
import appParams from "virtual:dlzn-ui/app-params";
|
|
32
32
|
//#region ../../packages/dlzn-ui/components/form/src/form.d.ts
|
|
33
|
+
type BusComponentPropsMapType = typeof appParams.busComponentPropsMap;
|
|
33
34
|
export declare const formPropsInit: {
|
|
34
35
|
readonly autoLabelWidth: true;
|
|
35
36
|
readonly colon: true;
|
|
@@ -128,7 +129,7 @@ type ComponentItemWithOthers = { [K in keyof ComponentPropsMap]: AllowedComponen
|
|
|
128
129
|
slot?: never;
|
|
129
130
|
}; }[keyof ComponentPropsMap];
|
|
130
131
|
type ComponentItemXOR = { [K in keyof ComponentPropsMap]: ComponentConfig<K>; }[keyof ComponentPropsMap];
|
|
131
|
-
interface ComponentPropsMap extends
|
|
132
|
+
interface ComponentPropsMap extends BusComponentPropsMapType {
|
|
132
133
|
TCheckbox: Omit<CheckboxProps$1, 'modelValue'>;
|
|
133
134
|
TCheckboxGroup: Omit<CheckboxGroupProps$1, 'modelValue'>;
|
|
134
135
|
TInput: Omit<InputProps$1, 'modelValue'>;
|
|
@@ -3,9 +3,9 @@ import { FormInstance, FormProps, FormPropsData } from "./form.js";
|
|
|
3
3
|
declare var __VLS_15: string, __VLS_16: {};
|
|
4
4
|
type __VLS_Slots = {} & { [K in NonNullable<typeof __VLS_15>]?: (props: typeof __VLS_16) => any; };
|
|
5
5
|
declare const __VLS_base: import("vue").DefineComponent<FormProps, FormInstance, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<FormProps> & Readonly<{}>, {
|
|
6
|
-
data: FormPropsData;
|
|
7
6
|
disabled: boolean;
|
|
8
7
|
readonly: boolean;
|
|
8
|
+
data: FormPropsData;
|
|
9
9
|
labelAlign: "right" | "top";
|
|
10
10
|
colon: boolean;
|
|
11
11
|
layout: "vertical" | "inline";
|
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
import
|
|
2
|
-
import t from "../../../plugins/autoImport/
|
|
3
|
-
import n from "../../../
|
|
4
|
-
import
|
|
5
|
-
import i from "../../checkbox/src/
|
|
6
|
-
import a from "
|
|
7
|
-
import
|
|
8
|
-
import s from "../../input
|
|
9
|
-
import c from "../../
|
|
10
|
-
import l from "../../
|
|
11
|
-
import u from "../../
|
|
12
|
-
import d from "../../
|
|
13
|
-
import f from "../../
|
|
14
|
-
import p from "../../
|
|
15
|
-
import m from "../../
|
|
16
|
-
import h from "../../textarea/src/textarea2.mjs";
|
|
1
|
+
import e from "../../../plugins/autoImport/_msg.mjs";
|
|
2
|
+
import t from "../../../plugins/autoImport/_notify.mjs";
|
|
3
|
+
import { isFalsy as n } from "../../../utils/boolean.mjs";
|
|
4
|
+
import r from "../../checkbox/src/checkbox2.mjs";
|
|
5
|
+
import i from "../../checkbox-group/src/checkbox-group2.mjs";
|
|
6
|
+
import { formPropsInit as a } from "./form.mjs";
|
|
7
|
+
import o from "../../input-number/src/input-number2.mjs";
|
|
8
|
+
import s from "../../input/src/input2.mjs";
|
|
9
|
+
import c from "../../radio-group/src/radio-group2.mjs";
|
|
10
|
+
import l from "../../range-input/src/range-input2.mjs";
|
|
11
|
+
import u from "../../select/src/select2.mjs";
|
|
12
|
+
import d from "../../slider/src/slider2.mjs";
|
|
13
|
+
import f from "../../switch/src/switch2.mjs";
|
|
14
|
+
import p from "../../tag-input/src/tag-input2.mjs";
|
|
15
|
+
import m from "../../textarea/src/textarea2.mjs";
|
|
17
16
|
import ee from "../../tree-select/src/tree-select2.mjs";
|
|
18
17
|
import te from "../../tree/src/tree2.mjs";
|
|
19
18
|
import ne from "../../upload/src/upload2.mjs";
|
|
20
|
-
import { Fragment as
|
|
21
|
-
import { useMutationObserver as
|
|
22
|
-
import { Form as
|
|
19
|
+
import { Fragment as h, computed as g, createBlock as _, createCommentVNode as v, createElementBlock as y, defineAsyncComponent as b, defineComponent as x, getCurrentInstance as S, mergeDefaults as C, mergeProps as w, nextTick as T, onMounted as re, openBlock as E, provide as D, ref as O, renderList as k, renderSlot as A, resolveDynamicComponent as j, shallowRef as M, unref as N, watch as P, withCtx as F } from "vue";
|
|
20
|
+
import { useMutationObserver as I, useResizeObserver as L } from "@vueuse/core";
|
|
21
|
+
import { Form as R, FormItem as z } from "tdesign-vue-next";
|
|
22
|
+
import B from "virtual:dlzn-ui/app-params";
|
|
23
23
|
//#region ../../packages/dlzn-ui/components/form/src/form.vue?vue&type=script&setup=true&lang.ts
|
|
24
|
-
var V = /*@__PURE__*/
|
|
24
|
+
var V = /*@__PURE__*/ x({
|
|
25
25
|
inheritAttrs: !1,
|
|
26
26
|
name: "TForm",
|
|
27
27
|
__name: "form",
|
|
28
|
-
props: /*@__PURE__*/
|
|
28
|
+
props: /*@__PURE__*/ C({
|
|
29
29
|
autoLabelWidth: { type: Boolean },
|
|
30
30
|
data: {},
|
|
31
31
|
items: {},
|
|
@@ -49,15 +49,15 @@ var V = /*@__PURE__*/ S({
|
|
|
49
49
|
onReset: { type: Function },
|
|
50
50
|
onSubmit: { type: Function },
|
|
51
51
|
onValidate: { type: Function }
|
|
52
|
-
},
|
|
53
|
-
setup(
|
|
54
|
-
let
|
|
52
|
+
}, a),
|
|
53
|
+
setup(a, { expose: x }) {
|
|
54
|
+
let C = a, { busComponentInitialValueMap: V, busFormItems: H } = B, U = S(), W = O(null), G = g(() => C.items.map((e) => {
|
|
55
55
|
if (typeof e.__others == "function") {
|
|
56
56
|
let t = {
|
|
57
57
|
...e,
|
|
58
58
|
...e.__others({
|
|
59
59
|
exposed: W,
|
|
60
|
-
formData:
|
|
60
|
+
formData: C.data
|
|
61
61
|
})
|
|
62
62
|
};
|
|
63
63
|
return delete t.__others, t;
|
|
@@ -66,10 +66,10 @@ var V = /*@__PURE__*/ S({
|
|
|
66
66
|
}));
|
|
67
67
|
function K() {
|
|
68
68
|
G.value.forEach((e) => {
|
|
69
|
-
if (e.model !== void 0 && !Object.hasOwn(
|
|
69
|
+
if (e.model !== void 0 && !Object.hasOwn(C.data, e.model)) {
|
|
70
70
|
if (V.has(e.component)) {
|
|
71
71
|
let t = V.get(e.component);
|
|
72
|
-
|
|
72
|
+
C.data[e.model] = t(e);
|
|
73
73
|
return;
|
|
74
74
|
}
|
|
75
75
|
let t = [
|
|
@@ -87,34 +87,34 @@ var V = /*@__PURE__*/ S({
|
|
|
87
87
|
"yearrange",
|
|
88
88
|
"years"
|
|
89
89
|
].includes(e.type) || e.component === "TSlider" && e.range === !0;
|
|
90
|
-
|
|
90
|
+
C.data[e.model] = t ? [] : e.component === "TCheckbox" ? !1 : e.component === "TSwitch" ? Array.isArray(e.customValue) ? e.customValue[1] : !1 : "";
|
|
91
91
|
}
|
|
92
92
|
});
|
|
93
93
|
}
|
|
94
|
-
|
|
94
|
+
P(G, K, {
|
|
95
95
|
deep: 2,
|
|
96
96
|
immediate: !0
|
|
97
|
-
}),
|
|
98
|
-
|
|
97
|
+
}), P(() => C.data, () => {
|
|
98
|
+
t.error("TForm: data is changed");
|
|
99
99
|
});
|
|
100
100
|
let q = /* @__PURE__ */ new Map(), J = {
|
|
101
|
-
TCheckbox:
|
|
102
|
-
TCheckboxGroup:
|
|
103
|
-
TInput:
|
|
104
|
-
TInputNumber:
|
|
105
|
-
TRadioGroup:
|
|
106
|
-
TRangeInput:
|
|
107
|
-
TSelect:
|
|
108
|
-
TSlider:
|
|
109
|
-
TSwitch:
|
|
110
|
-
TTagInput:
|
|
111
|
-
TTextarea:
|
|
101
|
+
TCheckbox: r,
|
|
102
|
+
TCheckboxGroup: i,
|
|
103
|
+
TInput: s,
|
|
104
|
+
TInputNumber: o,
|
|
105
|
+
TRadioGroup: c,
|
|
106
|
+
TRangeInput: l,
|
|
107
|
+
TSelect: u,
|
|
108
|
+
TSlider: d,
|
|
109
|
+
TSwitch: f,
|
|
110
|
+
TTagInput: p,
|
|
111
|
+
TTextarea: m,
|
|
112
112
|
TTree: te,
|
|
113
113
|
TTreeSelect: ee,
|
|
114
114
|
TUpload: ne
|
|
115
115
|
};
|
|
116
116
|
function Y(e) {
|
|
117
|
-
return typeof e == "string" ? H.has(e) ? (q.has(e) || q.set(e,
|
|
117
|
+
return typeof e == "string" ? H.has(e) ? (q.has(e) || q.set(e, b(H.get(e))), q.get(e)) : J[e] : s;
|
|
118
118
|
}
|
|
119
119
|
function ie(e) {
|
|
120
120
|
let t = {};
|
|
@@ -133,7 +133,7 @@ var V = /*@__PURE__*/ S({
|
|
|
133
133
|
"TCheckboxGroup",
|
|
134
134
|
"TRadioGroup"
|
|
135
135
|
].includes(e.component), r = e.component === "TUpload" ? "请上传文件" : typeof t.label == "string" ? n ? `请选择${t.label}` : `请填写${t.label}` : "必填";
|
|
136
|
-
return t.required === !0 && (t.rules === void 0 && (t.rules = []), !t.rules.some((e) => e.required === !0) &&
|
|
136
|
+
return t.required === !0 && (t.rules === void 0 && (t.rules = []), !t.rules.some((e) => e.required === !0) && C.rules?.[e.model ?? ""] === void 0 && t.rules.unshift({
|
|
137
137
|
message: r,
|
|
138
138
|
required: !0
|
|
139
139
|
}, {
|
|
@@ -144,8 +144,8 @@ var V = /*@__PURE__*/ S({
|
|
|
144
144
|
whitespace: !0
|
|
145
145
|
}), t;
|
|
146
146
|
}
|
|
147
|
-
let ae =
|
|
148
|
-
let e = { ...
|
|
147
|
+
let ae = g(() => {
|
|
148
|
+
let e = { ...C };
|
|
149
149
|
if (e.rules !== void 0) {
|
|
150
150
|
let t = {};
|
|
151
151
|
Object.keys(e.rules).forEach((n) => {
|
|
@@ -162,71 +162,71 @@ var V = /*@__PURE__*/ S({
|
|
|
162
162
|
return delete e.items, delete e.msgErrorWhenValidate, delete e.autoLabelWidth, Object.keys(e).forEach((t) => {
|
|
163
163
|
e[t] === void 0 && delete e[t];
|
|
164
164
|
}), e;
|
|
165
|
-
}), oe =
|
|
166
|
-
let e = { ...
|
|
165
|
+
}), oe = R, Z = () => {
|
|
166
|
+
let e = { ...C.data };
|
|
167
167
|
return G.value.forEach((t) => {
|
|
168
168
|
t.show === !1 && delete e[t.model];
|
|
169
169
|
}), e;
|
|
170
170
|
};
|
|
171
|
-
function se(
|
|
172
|
-
if (
|
|
173
|
-
let
|
|
174
|
-
if (!
|
|
175
|
-
let
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
171
|
+
function se(t) {
|
|
172
|
+
if (t !== null) {
|
|
173
|
+
let r = t;
|
|
174
|
+
if (!r.validate._alreadyReplace) {
|
|
175
|
+
let t = r.validate;
|
|
176
|
+
r.validate = (...n) => new Promise((r, i) => {
|
|
177
|
+
t(...n).then((t) => {
|
|
178
|
+
t === !0 ? r(Z()) : (C.msgErrorWhenValidate && Object.keys(t).forEach((n) => {
|
|
179
|
+
t[n].forEach((t) => {
|
|
180
|
+
t.result === !1 && e.error(t.message);
|
|
181
181
|
});
|
|
182
|
-
}), i(
|
|
182
|
+
}), i(t));
|
|
183
183
|
});
|
|
184
|
-
}),
|
|
184
|
+
}), r.validate._alreadyReplace = !0;
|
|
185
185
|
}
|
|
186
|
-
if (!
|
|
187
|
-
let e =
|
|
188
|
-
|
|
186
|
+
if (!r.validate._alreadyReplace) {
|
|
187
|
+
let e = r.validateOnly;
|
|
188
|
+
r.validateOnly = (...t) => new Promise((n, r) => {
|
|
189
189
|
e(...t).then((e) => {
|
|
190
190
|
e === !0 ? n(Z()) : r(e);
|
|
191
191
|
});
|
|
192
|
-
}),
|
|
192
|
+
}), r.validateOnly._alreadyReplace = !0;
|
|
193
193
|
}
|
|
194
|
-
if (!
|
|
195
|
-
let e =
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
194
|
+
if (!r.clearValidate._alreadyReplace) {
|
|
195
|
+
let e = r.clearValidate;
|
|
196
|
+
r.clearValidate = (...t) => {
|
|
197
|
+
T(() => {
|
|
198
|
+
T(() => {
|
|
199
|
+
T(() => {
|
|
200
|
+
T(() => {
|
|
201
|
+
T(() => {
|
|
202
202
|
e(...t);
|
|
203
203
|
});
|
|
204
204
|
});
|
|
205
205
|
});
|
|
206
206
|
});
|
|
207
207
|
});
|
|
208
|
-
},
|
|
208
|
+
}, r.clearValidate._alreadyReplace = !0;
|
|
209
209
|
}
|
|
210
|
-
|
|
211
|
-
let { ignoreKeys:
|
|
212
|
-
Object.keys(
|
|
213
|
-
|
|
214
|
-
}), Object.assign(
|
|
210
|
+
r.getFormData = Z, r.setFormData = (e, t) => {
|
|
211
|
+
let { ignoreKeys: r = [], isNotFalsy: i = !0, numberToStringKeys: a = [], override: o = {}, splitToArrKeys: s = [] } = t ?? {};
|
|
212
|
+
Object.keys(C.data).forEach((t) => {
|
|
213
|
+
r.includes(t) || (s.includes(t) ? C.data[t] = typeof e[t] == "string" ? e[t].split(",").filter(Boolean) : [] : i && n(e[t]) || (C.data[t] = e[t]), a.includes(t) && typeof C.data[t] == "number" && (C.data[t] = String(C.data[t])));
|
|
214
|
+
}), Object.assign(C.data, o);
|
|
215
215
|
};
|
|
216
216
|
}
|
|
217
|
-
let
|
|
218
|
-
W.value =
|
|
217
|
+
let r = t ?? {};
|
|
218
|
+
W.value = r, U.exposed = r;
|
|
219
219
|
}
|
|
220
|
-
let Q =
|
|
220
|
+
let Q = M();
|
|
221
221
|
re(() => {
|
|
222
|
-
Q.value = U.exposed.$el.getElementsByClassName("t-form__label"), $(),
|
|
222
|
+
Q.value = U.exposed.$el.getElementsByClassName("t-form__label"), $(), I(U.exposed.$el, () => {
|
|
223
223
|
$();
|
|
224
224
|
}, {
|
|
225
225
|
attributeFilter: ["class"],
|
|
226
226
|
characterData: !0,
|
|
227
227
|
childList: !0,
|
|
228
228
|
subtree: !0
|
|
229
|
-
}),
|
|
229
|
+
}), L(U.exposed.$el, () => {
|
|
230
230
|
$();
|
|
231
231
|
});
|
|
232
232
|
});
|
|
@@ -234,7 +234,7 @@ var V = /*@__PURE__*/ S({
|
|
|
234
234
|
let e = [...Q.value];
|
|
235
235
|
if (e.forEach((e) => {
|
|
236
236
|
e.style.minWidth = "auto";
|
|
237
|
-
}),
|
|
237
|
+
}), C.labelAlign === "top" || !C.autoLabelWidth) return;
|
|
238
238
|
let t = 0;
|
|
239
239
|
e.forEach((e) => {
|
|
240
240
|
t = Math.max(t, e.offsetWidth);
|
|
@@ -242,15 +242,15 @@ var V = /*@__PURE__*/ S({
|
|
|
242
242
|
e.style.minWidth = `${t}px`;
|
|
243
243
|
});
|
|
244
244
|
}
|
|
245
|
-
return
|
|
245
|
+
return D("formData", C.data), D("formExposed", W), D("isFormDisabled", g(() => C.disabled)), D("isFormReadonly", g(() => C.readonly)), x({}), (e, t) => (E(), y(h, null, [v(" eslint-disable vue/no-mutating-props "), (E(), _(j(N(oe)), w(w(e.$attrs, {
|
|
246
246
|
...ae.value,
|
|
247
247
|
ref: se
|
|
248
248
|
}), { "label-width": "fit-content" }), {
|
|
249
|
-
default:
|
|
250
|
-
default:
|
|
249
|
+
default: F(() => [(E(!0), y(h, null, k(G.value.filter((e) => e.show !== !1), (t) => (E(), _(N(z), w({ key: t.model ?? t.slot }, { ref_for: !0 }, w({ ...X(t) }, { class: { no_label_item: N(n)(t._label) } }), { name: t.model }), {
|
|
250
|
+
default: F(() => [t.slot ? A(e.$slots, t.slot, {}, void 0, !0, 0) : (E(), _(j(Y(t.component)), w({
|
|
251
251
|
key: 1,
|
|
252
|
-
modelValue:
|
|
253
|
-
"onUpdate:modelValue": (e) =>
|
|
252
|
+
modelValue: a.data[t.model],
|
|
253
|
+
"onUpdate:modelValue": (e) => a.data[t.model] = e
|
|
254
254
|
}, { ref_for: !0 }, ie(t)), null, 16, ["modelValue", "onUpdate:modelValue"]))]),
|
|
255
255
|
_: 2
|
|
256
256
|
}, 1040, ["name"]))), 128))]),
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */
|
|
2
|
+
[data-v-178687e3] .t-form__label{padding-right:var(--td-size-1)}[data-v-178687e3] .t-form__label--top{min-height:auto;line-height:inherit}[data-v-178687e3] .t-form__item{margin-bottom:var(--td-comp-margin-xxl)!important}[data-v-178687e3] .t-form__item.no_label_item .t-form__label{display:none}[data-v-178687e3] .t-form__item .t-input-adornment{flex:auto}.t-form[data-v-178687e3]{--td-comp-margin-xxl:var(--td-comp-margin-xl)}.t-form[data-v-178687e3]:has(.t-form__item:not(.no_label_item)) .no_label_item .t-form__label{opacity:0;height:1px;padding-right:0;display:block}.t-form.no_item_mb .t-form__item[data-v-178687e3]{margin-bottom:0!important}.t-form-inline[data-v-178687e3]{--repeat-min-width:220px;--repeat-gap:24px;grid-template-columns:repeat(auto-fill, minmax(var(--repeat-min-width), 1fr));gap:0 var(--repeat-gap);display:grid}.t-form-inline[data-v-178687e3] .no_label_item{align-self:flex-end}.t-form-inline[data-v-178687e3] .t-form__item{min-width:auto;margin-right:0;display:block}.t-form-inline[data-v-178687e3] .t-form__item.grid_item .t-form__controls-content{grid-template-columns:repeat(auto-fill, minmax(var(--repeat-min-width), 1fr));gap:0 var(--repeat-gap);display:grid}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import e from "../../../_virtual/_plugin-vue_export-helper.mjs";
|
|
2
2
|
import t from "./form.vue_vue_type_script_setup_true_lang.mjs";
|
|
3
|
-
import './form.
|
|
3
|
+
import './form.vue_vue_type_style_index_0_scoped_178687e3_lang.css';/* empty css */
|
|
4
4
|
//#region ../../packages/dlzn-ui/components/form/src/form.vue
|
|
5
|
-
var n = /*#__PURE__*/ e(t, [["__scopeId", "data-v-
|
|
5
|
+
var n = /*#__PURE__*/ e(t, [["__scopeId", "data-v-178687e3"]]);
|
|
6
6
|
//#endregion
|
|
7
7
|
export { n as default };
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { ImageViewerProps } from "./image-viewer.js";
|
|
2
2
|
//#region ../../packages/dlzn-ui/components/image-viewer/src/image-viewer.vue.d.ts
|
|
3
3
|
declare const __VLS_export: import("vue").DefineComponent<ImageViewerProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<ImageViewerProps> & Readonly<{}>, {
|
|
4
|
-
visible: boolean;
|
|
5
4
|
closeBtn: boolean | import("tdesign-vue-next").TNode;
|
|
6
5
|
closeOnEscKeydown: boolean;
|
|
7
6
|
draggable: boolean;
|
|
8
7
|
showOverlay: boolean;
|
|
8
|
+
visible: boolean;
|
|
9
9
|
closeOnOverlay: boolean;
|
|
10
10
|
navigationArrow: boolean | import("tdesign-vue-next").TNode;
|
|
11
11
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
package/components/index.d.ts
CHANGED
|
@@ -7,6 +7,9 @@ import "./button/index.js";
|
|
|
7
7
|
import { CardProps, cardPropsInit } from "./card/src/card.js";
|
|
8
8
|
import _default$1 from "./card/src/card.vue.js";
|
|
9
9
|
import "./card/index.js";
|
|
10
|
+
import { CheckboxGroupProps } from "./checkbox-group/src/checkbox-group.js";
|
|
11
|
+
import _default$3 from "./checkbox-group/src/checkbox-group.vue.js";
|
|
12
|
+
import "./checkbox-group/index.js";
|
|
10
13
|
import { CheckboxProps } from "./checkbox/src/checkbox.js";
|
|
11
14
|
import _default$2 from "./checkbox/src/checkbox.vue.js";
|
|
12
15
|
import "./checkbox/index.js";
|
|
@@ -51,12 +54,12 @@ import _default$4 from "./form/src/form.vue.js";
|
|
|
51
54
|
import "./form/index.js";
|
|
52
55
|
import { IconProps } from "./icon/src/icon.js";
|
|
53
56
|
import _default$5 from "./icon/src/icon.vue.js";
|
|
54
|
-
import { ImageProps, imagePropsInit } from "./image/src/image.js";
|
|
55
|
-
import _default$6 from "./image/src/image.vue.js";
|
|
56
|
-
import "./image/index.js";
|
|
57
57
|
import { ImageViewerProps, imageViewerPropsInit } from "./image-viewer/src/image-viewer.js";
|
|
58
58
|
import _default$7 from "./image-viewer/src/image-viewer.vue.js";
|
|
59
59
|
import "./image-viewer/index.js";
|
|
60
|
+
import { ImageProps, imagePropsInit } from "./image/src/image.js";
|
|
61
|
+
import _default$6 from "./image/src/image.vue.js";
|
|
62
|
+
import "./image/index.js";
|
|
60
63
|
import { LinkProps, linkPropsInit } from "./link/src/link.js";
|
|
61
64
|
import _default$10 from "./link/src/link.vue.js";
|
|
62
65
|
import "./link/index.js";
|
|
@@ -72,7 +75,4 @@ import "./tab-panel/index.js";
|
|
|
72
75
|
import { TagProps, tagPropsInit } from "./tag/src/tag.js";
|
|
73
76
|
import _default$20 from "./tag/src/tag.vue.js";
|
|
74
77
|
import "./tag/index.js";
|
|
75
|
-
import { CheckboxGroupProps } from "./checkbox-group/src/checkbox-group.js";
|
|
76
|
-
import _default$3 from "./checkbox-group/src/checkbox-group.vue.js";
|
|
77
|
-
import "./checkbox-group/index.js";
|
|
78
78
|
export { AllowedComponentProps, ButtonProps, CardProps, CheckboxGroupProps, CheckboxProps, DEFAULT_ACCEPT, FormExposed, FormInstance, FormItem, FormItemComponentPropsUnderlyingWithMeta, FormItemProps, FormProps, FormPropsData, GetFormData, IconProps, ImageProps, ImageViewerProps, InputNumberProps, InputProps, LinkProps, PaginationProps, PopconfirmProps, PopupProps, RadioGroupProps, RangeInputProps, ResolvedFormItem, SelectProps, SetFormData, SliderProps, SlotItem, SwitchProps, _default as TButton, _default$1 as TCard, _default$2 as TCheckbox, _default$3 as TCheckboxGroup, _default$4 as TForm, _default$5 as TIcon, _default$6 as TImage, _default$7 as TImageViewer, _default$8 as TInput, _default$9 as TInputNumber, _default$10 as TLink, _default$11 as TPagination, _default$12 as TPopconfirm, _default$13 as TPopup, _default$14 as TRadioGroup, _default$15 as TRangeInput, _default$16 as TSelect, _default$17 as TSlider, _default$18 as TSwitch, _default$19 as TTabPanel, _default$20 as TTag, _default$21 as TTagInput, _default$22 as TTextarea, _default$23 as TTree, _default$24 as TTreeSelect, _default$25 as TUpload, type TabPanelProps, TagInputProps, TagProps, TextareaProps, TreeProps, TreeSelectProps, UploadFile, UploadInstanceFunctions, UploadProps, buttonPropsInit, cardPropsInit, formPropsInit, imagePropsInit, imageViewerPropsInit, inputNumberPropsInit, inputPropsInit, linkPropsInit, selectPropsInit, sliderPropsInit, switchPropsInit, tagInputPropsInit, tagPropsInit, treePropsInit };
|
|
@@ -6,9 +6,9 @@ declare const __VLS_export: import("vue").DefineComponent<InputNumberProps$1, {}
|
|
|
6
6
|
}, string, import("vue").PublicProps, Readonly<InputNumberProps$1> & Readonly<{
|
|
7
7
|
"onUpdate:modelValue"?: ((value: InputNumberValue) => any) | undefined;
|
|
8
8
|
}>, {
|
|
9
|
-
theme: "normal" | "row";
|
|
10
9
|
disabled: boolean;
|
|
11
10
|
readonly: boolean;
|
|
11
|
+
theme: "normal" | "row";
|
|
12
12
|
min: InputNumberValue;
|
|
13
13
|
autoWidth: boolean;
|
|
14
14
|
decimalPlaces: import("tdesign-vue-next").InputNumberDecimalPlaces;
|
|
@@ -2,9 +2,9 @@ import { PopconfirmProps } from "./popconfirm.js";
|
|
|
2
2
|
//#region ../../packages/dlzn-ui/components/popconfirm/src/popconfirm.vue.d.ts
|
|
3
3
|
declare const __VLS_export: import("vue").DefineComponent<PopconfirmProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<PopconfirmProps> & Readonly<{}>, {
|
|
4
4
|
destroyOnClose: boolean;
|
|
5
|
-
showArrow: boolean;
|
|
6
5
|
theme: "default" | "warning" | "danger";
|
|
7
6
|
visible: boolean;
|
|
7
|
+
showArrow: boolean;
|
|
8
8
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
9
9
|
declare const _default: typeof __VLS_export;
|
|
10
10
|
//#endregion
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { PopupProps } from "./popup.js";
|
|
2
2
|
//#region ../../packages/dlzn-ui/components/popup/src/popup.vue.d.ts
|
|
3
3
|
declare const __VLS_export: import("vue").DefineComponent<PopupProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<PopupProps> & Readonly<{}>, {
|
|
4
|
-
showArrow: boolean;
|
|
5
4
|
visible: boolean;
|
|
5
|
+
showArrow: boolean;
|
|
6
6
|
delay: number | Array<number>;
|
|
7
7
|
hideEmptyPopup: boolean;
|
|
8
8
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { SelectProps } from "./select.js";
|
|
2
2
|
//#region ../../packages/dlzn-ui/components/select/src/select.vue.d.ts
|
|
3
3
|
declare const __VLS_export: import("vue").DefineComponent<SelectProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<SelectProps> & Readonly<{}>, {
|
|
4
|
-
showArrow: boolean;
|
|
5
|
-
keys: import("tdesign-vue-next").KeysType;
|
|
6
4
|
disabled: boolean;
|
|
7
|
-
scroll: import("tdesign-vue-next").InfinityScroll;
|
|
8
5
|
readonly: boolean;
|
|
6
|
+
keys: import("tdesign-vue-next").KeysType;
|
|
9
7
|
showCheckAll: boolean;
|
|
8
|
+
showArrow: boolean;
|
|
10
9
|
placeholder: string;
|
|
11
10
|
clearable: boolean;
|
|
11
|
+
multiple: boolean;
|
|
12
|
+
scroll: import("tdesign-vue-next").InfinityScroll;
|
|
12
13
|
filterable: boolean;
|
|
13
14
|
inputValue: string;
|
|
14
15
|
minCollapsedNum: number;
|
|
15
|
-
multiple: boolean;
|
|
16
16
|
popupVisible: boolean;
|
|
17
17
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
18
18
|
declare const _default: typeof __VLS_export;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { TagProps } from "./tag.js";
|
|
2
2
|
//#region ../../packages/dlzn-ui/components/tag/src/tag.vue.d.ts
|
|
3
3
|
declare const __VLS_export: import("vue").DefineComponent<TagProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<TagProps> & Readonly<{}>, {
|
|
4
|
-
size: import("tdesign-vue-next").SizeEnum;
|
|
5
4
|
title: string | boolean;
|
|
5
|
+
size: import("tdesign-vue-next").SizeEnum;
|
|
6
6
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
7
7
|
declare const _default: typeof __VLS_export;
|
|
8
8
|
//#endregion
|
|
@@ -2,10 +2,10 @@ import { TreeProps as TreeProps$1 } from "./tree.js";
|
|
|
2
2
|
import { TreeInstanceFunctions } from "tdesign-vue-next";
|
|
3
3
|
//#region ../../packages/dlzn-ui/components/tree/src/tree.vue.d.ts
|
|
4
4
|
declare const __VLS_export: import("vue").DefineComponent<TreeProps$1, TreeInstanceFunctions<import("tdesign-vue-next").TreeOptionData>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<TreeProps$1> & Readonly<{}>, {
|
|
5
|
-
icon: boolean | ((h: typeof import("vue").h, props: import("tdesign-vue-next").TreeNodeModel<import("tdesign-vue-next/es/tree/utils/adapt").TypeTreeOptionData>) => import("tdesign-vue-next").TNodeReturnValue);
|
|
6
|
-
lazy: boolean;
|
|
7
5
|
disabled: boolean;
|
|
8
6
|
label: string | boolean | ((h: typeof import("vue").h, props: import("tdesign-vue-next").TreeNodeModel<import("tdesign-vue-next/es/tree/utils/adapt").TypeTreeOptionData>) => import("tdesign-vue-next").TNodeReturnValue);
|
|
7
|
+
lazy: boolean;
|
|
8
|
+
icon: boolean | ((h: typeof import("vue").h, props: import("tdesign-vue-next").TreeNodeModel<import("tdesign-vue-next/es/tree/utils/adapt").TypeTreeOptionData>) => import("tdesign-vue-next").TNodeReturnValue);
|
|
9
9
|
hover: boolean;
|
|
10
10
|
checkable: boolean;
|
|
11
11
|
expandOnClickNode: boolean;
|
|
@@ -3,10 +3,10 @@ import { UploadInstanceFunctions, UploadProps } from "./upload.js";
|
|
|
3
3
|
declare var __VLS_10: string, __VLS_11: any;
|
|
4
4
|
type __VLS_Slots = {} & { [K in NonNullable<typeof __VLS_10>]?: (props: typeof __VLS_11) => any; };
|
|
5
5
|
declare const __VLS_base: import("vue").DefineComponent<UploadProps, UploadInstanceFunctions, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<UploadProps> & Readonly<{}>, {
|
|
6
|
-
theme: "custom" | "file" | "file-input" | "file-flow" | "image" | "image-flow";
|
|
7
6
|
disabled: boolean;
|
|
8
|
-
|
|
7
|
+
theme: "custom" | "file" | "file-input" | "file-flow" | "image" | "image-flow";
|
|
9
8
|
accept: string;
|
|
9
|
+
multiple: boolean;
|
|
10
10
|
useMockProgress: boolean;
|
|
11
11
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
12
12
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
package/hooks/useList.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { UseListPromiseMap } from "../index.js";
|
|
2
1
|
import { ComputedRef, Ref } from "vue";
|
|
3
2
|
//#region ../../packages/dlzn-ui/hooks/useList.d.ts
|
|
4
3
|
export interface ListItem {
|
|
@@ -10,7 +9,7 @@ export type UseListAllKey = keyof typeof promiseMap;
|
|
|
10
9
|
export type UseListKey = Exclude<UseListAllKey, UseListTreeKey>;
|
|
11
10
|
export type UseListTreeKey = TreeKeys<typeof promiseMap>;
|
|
12
11
|
type TreeKeys<T> = { [K in keyof T]: K extends `${string}Tree` ? K : never; }[keyof T];
|
|
13
|
-
declare const promiseMap:
|
|
12
|
+
declare const promiseMap: Record<string, () => Promise<ListItem[]>>;
|
|
14
13
|
export declare function useClearList(): void;
|
|
15
14
|
export declare function useList(key: UseListAllKey): Ref<ListItem[], ListItem[]>;
|
|
16
15
|
export declare function useListLabel(key: UseListKey): ComputedRef<string[]>;
|
package/hooks/useList.mjs
CHANGED
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
1
|
+
import { stringDisplay as e } from "../utils/string.mjs";
|
|
2
|
+
import { computed as t, ref as n } from "vue";
|
|
3
|
+
import r from "virtual:dlzn-ui/app-params";
|
|
4
4
|
//#region ../../packages/dlzn-ui/hooks/useList.ts
|
|
5
|
-
var i = /* @__PURE__ */ new Map(), a = /* @__PURE__ */ new Map(), o =
|
|
5
|
+
var i = /* @__PURE__ */ new Map(), a = /* @__PURE__ */ new Map(), o = r.useListPromiseMap;
|
|
6
6
|
function s() {
|
|
7
7
|
i.clear(), a.clear();
|
|
8
8
|
}
|
|
9
9
|
function c(e) {
|
|
10
|
-
let t = i.has(e) ? i.get(e) :
|
|
10
|
+
let t = i.has(e) ? i.get(e) : n([]);
|
|
11
11
|
return i.has(e) || i.set(e, t), t.value.length === 0 && (!a.has(e) || a.get(e) === !1) && (a.set(e, !0), o[e]().then((e) => {
|
|
12
12
|
t.value = e;
|
|
13
13
|
}).finally(() => {
|
|
14
14
|
a.set(e, !1);
|
|
15
15
|
})), t;
|
|
16
16
|
}
|
|
17
|
-
function l(
|
|
18
|
-
let i = c(
|
|
19
|
-
return
|
|
17
|
+
function l(n, r) {
|
|
18
|
+
let i = c(n);
|
|
19
|
+
return t(() => {
|
|
20
20
|
if (r === void 0) return i.value.map((e) => e.label);
|
|
21
|
-
if (Array.isArray(r)) return i.value.length === 0 ? [] : r.map((
|
|
21
|
+
if (Array.isArray(r)) return i.value.length === 0 ? [] : r.map((t) => i.value.find((e) => String(e.value) === String(t))?.label ?? e(t));
|
|
22
22
|
if (i.value.length === 0) return "";
|
|
23
23
|
if (typeof r == "string") {
|
|
24
24
|
let e = r.split(",").filter(Boolean);
|
|
25
25
|
if (e.length > 0) return e.map((e) => i.value.find((t) => String(t.value) === e)?.label ?? e).join(",");
|
|
26
26
|
}
|
|
27
|
-
return i.value.find((e) => String(e.value) === String(r))?.label ??
|
|
27
|
+
return i.value.find((e) => String(e.value) === String(r))?.label ?? e(r);
|
|
28
28
|
});
|
|
29
29
|
}
|
|
30
30
|
function u(e) {
|
package/index.d.ts
CHANGED
|
@@ -4,7 +4,9 @@ import { ButtonProps, buttonPropsInit } from "./components/button/src/button.js"
|
|
|
4
4
|
import _default from "./components/button/src/button.vue.js";
|
|
5
5
|
import { CardProps, cardPropsInit } from "./components/card/src/card.js";
|
|
6
6
|
import _default$1 from "./components/card/src/card.vue.js";
|
|
7
|
-
import
|
|
7
|
+
import { ListItem } from "./hooks/useList.js";
|
|
8
|
+
import { CheckboxGroupProps } from "./components/checkbox-group/src/checkbox-group.js";
|
|
9
|
+
import _default$3 from "./components/checkbox-group/src/checkbox-group.vue.js";
|
|
8
10
|
import { CheckboxProps } from "./components/checkbox/src/checkbox.js";
|
|
9
11
|
import _default$2 from "./components/checkbox/src/checkbox.vue.js";
|
|
10
12
|
import { InputProps, inputPropsInit } from "./components/input/src/input.js";
|
|
@@ -35,10 +37,10 @@ import { AllowedComponentProps, FormExposed, FormInstance, FormItem, FormItemCom
|
|
|
35
37
|
import _default$4 from "./components/form/src/form.vue.js";
|
|
36
38
|
import { IconProps } from "./components/icon/src/icon.js";
|
|
37
39
|
import _default$5 from "./components/icon/src/icon.vue.js";
|
|
38
|
-
import { ImageProps, imagePropsInit } from "./components/image/src/image.js";
|
|
39
|
-
import _default$6 from "./components/image/src/image.vue.js";
|
|
40
40
|
import { ImageViewerProps, imageViewerPropsInit } from "./components/image-viewer/src/image-viewer.js";
|
|
41
41
|
import _default$7 from "./components/image-viewer/src/image-viewer.vue.js";
|
|
42
|
+
import { ImageProps, imagePropsInit } from "./components/image/src/image.js";
|
|
43
|
+
import _default$6 from "./components/image/src/image.vue.js";
|
|
42
44
|
import { LinkProps, linkPropsInit } from "./components/link/src/link.js";
|
|
43
45
|
import _default$10 from "./components/link/src/link.vue.js";
|
|
44
46
|
import { PaginationProps } from "./components/pagination/src/pagination.js";
|
|
@@ -50,17 +52,14 @@ import _default$19 from "./components/tab-panel/src/tab-panel.vue.js";
|
|
|
50
52
|
import { TagProps, tagPropsInit } from "./components/tag/src/tag.js";
|
|
51
53
|
import _default$20 from "./components/tag/src/tag.vue.js";
|
|
52
54
|
import "./components/index.js";
|
|
53
|
-
import {
|
|
54
|
-
import { CheckboxGroupProps } from "./components/checkbox-group/src/checkbox-group.js";
|
|
55
|
-
import _default$3 from "./components/checkbox-group/src/checkbox-group.vue.js";
|
|
56
|
-
import { AsyncComponentLoader, Component } from "vue";
|
|
55
|
+
import { AsyncComponentLoader } from "vue";
|
|
57
56
|
//#region ../../packages/dlzn-ui/index.d.ts
|
|
58
|
-
export
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
57
|
+
export interface AppParams {
|
|
58
|
+
busComponentInitialValueMap: Map<string, (itemConfig: Record<string, any>) => any>;
|
|
59
|
+
busComponentPropsMap: Record<string, any>;
|
|
60
|
+
busFormItems: Map<string, AsyncComponentLoader>;
|
|
61
|
+
useListPromiseMap: Record<string, () => Promise<ListItem[]>>;
|
|
62
|
+
viewsEntryLazyImport: Record<string, LazyVueComponentImport>;
|
|
63
|
+
}
|
|
65
64
|
//#endregion
|
|
66
|
-
export { AllowedComponentProps, ButtonProps, CardProps, CheckboxGroupProps, CheckboxProps, DEFAULT_ACCEPT, FormExposed, FormInstance, FormItem, FormItemComponentPropsUnderlyingWithMeta, FormItemProps, FormProps, FormPropsData, GetFormData, IconProps, ImageProps, ImageViewerProps, InputNumberProps, InputProps, LinkProps, PaginationProps, PopconfirmProps, PopupProps, RadioGroupProps, RangeInputProps, ResolvedFormItem, SelectProps, SetFormData, SliderProps, SlotItem, SwitchProps, _default as TButton, _default$1 as TCard, _default$2 as TCheckbox, _default$3 as TCheckboxGroup, _default$4 as TForm, _default$5 as TIcon, _default$6 as TImage, _default$7 as TImageViewer, _default$8 as TInput, _default$9 as TInputNumber, _default$10 as TLink, _default$11 as TPagination, _default$12 as TPopconfirm, _default$13 as TPopup, _default$14 as TRadioGroup, _default$15 as TRangeInput, _default$16 as TSelect, _default$17 as TSlider, _default$18 as TSwitch, _default$19 as TTabPanel, _default$20 as TTag, _default$21 as TTagInput, _default$22 as TTextarea, _default$23 as TTree, _default$24 as TTreeSelect, _default$25 as TUpload, type TabPanelProps, TagInputProps, TagProps, TextareaProps, TreeProps, TreeSelectProps, UploadFile, UploadInstanceFunctions, UploadProps, buttonPropsInit, cardPropsInit, formPropsInit, imagePropsInit, imageViewerPropsInit, inputNumberPropsInit, inputPropsInit, linkPropsInit, selectPropsInit,
|
|
65
|
+
export { AllowedComponentProps, ButtonProps, CardProps, CheckboxGroupProps, CheckboxProps, DEFAULT_ACCEPT, FormExposed, FormInstance, FormItem, FormItemComponentPropsUnderlyingWithMeta, FormItemProps, FormProps, FormPropsData, GetFormData, IconProps, ImageProps, ImageViewerProps, InputNumberProps, InputProps, LinkProps, PaginationProps, PopconfirmProps, PopupProps, RadioGroupProps, RangeInputProps, ResolvedFormItem, SelectProps, SetFormData, SliderProps, SlotItem, SwitchProps, _default as TButton, _default$1 as TCard, _default$2 as TCheckbox, _default$3 as TCheckboxGroup, _default$4 as TForm, _default$5 as TIcon, _default$6 as TImage, _default$7 as TImageViewer, _default$8 as TInput, _default$9 as TInputNumber, _default$10 as TLink, _default$11 as TPagination, _default$12 as TPopconfirm, _default$13 as TPopup, _default$14 as TRadioGroup, _default$15 as TRangeInput, _default$16 as TSelect, _default$17 as TSlider, _default$18 as TSwitch, _default$19 as TTabPanel, _default$20 as TTag, _default$21 as TTagInput, _default$22 as TTextarea, _default$23 as TTree, _default$24 as TTreeSelect, _default$25 as TUpload, type TabPanelProps, TagInputProps, TagProps, TextareaProps, TreeProps, TreeSelectProps, UploadFile, UploadInstanceFunctions, UploadProps, buttonPropsInit, cardPropsInit, formPropsInit, imagePropsInit, imageViewerPropsInit, inputNumberPropsInit, inputPropsInit, linkPropsInit, selectPropsInit, sliderPropsInit, switchPropsInit, tagInputPropsInit, tagPropsInit, treePropsInit };
|
package/index.mjs
CHANGED
|
@@ -1,43 +1,42 @@
|
|
|
1
|
-
import e from "./
|
|
2
|
-
import
|
|
3
|
-
import n from "./components/
|
|
4
|
-
import r from "./components/
|
|
5
|
-
import i from "./components/
|
|
6
|
-
import
|
|
7
|
-
import o from "./components/
|
|
8
|
-
import s from "./components/checkbox/src/
|
|
9
|
-
import c from "./components/
|
|
10
|
-
import {
|
|
11
|
-
import
|
|
12
|
-
import d from "./components/input
|
|
13
|
-
import
|
|
14
|
-
import p from "./components/
|
|
15
|
-
import m from "./components/
|
|
16
|
-
import h from "./components/
|
|
17
|
-
import
|
|
18
|
-
import _ from "./components/
|
|
19
|
-
import
|
|
20
|
-
import y from "./components/
|
|
21
|
-
import
|
|
22
|
-
import x from "./components/
|
|
23
|
-
import
|
|
24
|
-
import C from "./components/
|
|
25
|
-
import w from "./components/
|
|
26
|
-
import
|
|
27
|
-
import E from "./components/tree
|
|
28
|
-
import D from "./components/
|
|
29
|
-
import
|
|
30
|
-
import k from "./components/
|
|
31
|
-
import A from "./components/
|
|
32
|
-
import
|
|
33
|
-
import M from "./components/image/src/
|
|
34
|
-
import
|
|
35
|
-
import P from "./components/
|
|
36
|
-
import
|
|
37
|
-
import I from "./components/
|
|
38
|
-
import L from "./components/
|
|
39
|
-
import R from "./components/
|
|
40
|
-
import z from "./components/
|
|
41
|
-
import
|
|
42
|
-
|
|
43
|
-
export { O as DEFAULT_ACCEPT, i as TButton, o as TCard, s as TCheckbox, c as TCheckboxGroup, A as TForm, n as TIcon, M as TImage, P as TImageViewer, p as TInput, d as TInputNumber, I as TLink, L as TPagination, r as TPopconfirm, R as TPopup, m as TRadioGroup, h as TRangeInput, _ as TSelect, y as TSlider, x as TSwitch, z as TTabPanel, V as TTag, C as TTagInput, w as TTextarea, D as TTree, E as TTreeSelect, k as TUpload, t as buttonPropsInit, a as cardPropsInit, l as formPropsInit, j as imagePropsInit, N as imageViewerPropsInit, u as inputNumberPropsInit, f as inputPropsInit, F as linkPropsInit, g as selectPropsInit, e as setAppParams, v as sliderPropsInit, b as switchPropsInit, S as tagInputPropsInit, B as tagPropsInit, T as treePropsInit };
|
|
1
|
+
import { buttonPropsInit as e } from "./components/button/src/button.mjs";
|
|
2
|
+
import t from "./components/icon/src/icon2.mjs";
|
|
3
|
+
import n from "./components/popconfirm/src/popconfirm2.mjs";
|
|
4
|
+
import r from "./components/button/src/button2.mjs";
|
|
5
|
+
import { cardPropsInit as i } from "./components/card/src/card.mjs";
|
|
6
|
+
import a from "./components/card/src/card2.mjs";
|
|
7
|
+
import o from "./components/checkbox/src/checkbox2.mjs";
|
|
8
|
+
import s from "./components/checkbox-group/src/checkbox-group2.mjs";
|
|
9
|
+
import { formPropsInit as c } from "./components/form/src/form.mjs";
|
|
10
|
+
import { inputNumberPropsInit as l } from "./components/input-number/src/input-number.mjs";
|
|
11
|
+
import u from "./components/input-number/src/input-number2.mjs";
|
|
12
|
+
import { inputPropsInit as d } from "./components/input/src/input.mjs";
|
|
13
|
+
import f from "./components/input/src/input2.mjs";
|
|
14
|
+
import p from "./components/radio-group/src/radio-group2.mjs";
|
|
15
|
+
import m from "./components/range-input/src/range-input2.mjs";
|
|
16
|
+
import { selectPropsInit as h } from "./components/select/src/select.mjs";
|
|
17
|
+
import g from "./components/select/src/select2.mjs";
|
|
18
|
+
import { sliderPropsInit as _ } from "./components/slider/src/slider.mjs";
|
|
19
|
+
import v from "./components/slider/src/slider2.mjs";
|
|
20
|
+
import { switchPropsInit as y } from "./components/switch/src/switch.mjs";
|
|
21
|
+
import b from "./components/switch/src/switch2.mjs";
|
|
22
|
+
import { tagInputPropsInit as x } from "./components/tag-input/src/tag-input.mjs";
|
|
23
|
+
import S from "./components/tag-input/src/tag-input2.mjs";
|
|
24
|
+
import C from "./components/textarea/src/textarea2.mjs";
|
|
25
|
+
import { treePropsInit as w } from "./components/tree/src/tree.mjs";
|
|
26
|
+
import T from "./components/tree-select/src/tree-select2.mjs";
|
|
27
|
+
import E from "./components/tree/src/tree2.mjs";
|
|
28
|
+
import { DEFAULT_ACCEPT as D } from "./components/upload/src/upload.mjs";
|
|
29
|
+
import O from "./components/upload/src/upload2.mjs";
|
|
30
|
+
import k from "./components/form/src/form2.mjs";
|
|
31
|
+
import { imagePropsInit as A } from "./components/image/src/image.mjs";
|
|
32
|
+
import j from "./components/image/src/image2.mjs";
|
|
33
|
+
import { imageViewerPropsInit as M } from "./components/image-viewer/src/image-viewer.mjs";
|
|
34
|
+
import N from "./components/image-viewer/src/image-viewer2.mjs";
|
|
35
|
+
import { linkPropsInit as P } from "./components/link/src/link.mjs";
|
|
36
|
+
import F from "./components/link/src/link2.mjs";
|
|
37
|
+
import I from "./components/pagination/src/pagination2.mjs";
|
|
38
|
+
import L from "./components/popup/src/popup2.mjs";
|
|
39
|
+
import R from "./components/tab-panel/src/tab-panel2.mjs";
|
|
40
|
+
import { tagPropsInit as z } from "./components/tag/src/tag.mjs";
|
|
41
|
+
import B from "./components/tag/src/tag2.mjs";
|
|
42
|
+
export { D as DEFAULT_ACCEPT, r as TButton, a as TCard, o as TCheckbox, s as TCheckboxGroup, k as TForm, t as TIcon, j as TImage, N as TImageViewer, f as TInput, u as TInputNumber, F as TLink, I as TPagination, n as TPopconfirm, L as TPopup, p as TRadioGroup, m as TRangeInput, g as TSelect, v as TSlider, b as TSwitch, R as TTabPanel, B as TTag, S as TTagInput, C as TTextarea, E as TTree, T as TTreeSelect, O as TUpload, e as buttonPropsInit, i as cardPropsInit, c as formPropsInit, A as imagePropsInit, M as imageViewerPropsInit, l as inputNumberPropsInit, d as inputPropsInit, P as linkPropsInit, h as selectPropsInit, _ as sliderPropsInit, y as switchPropsInit, x as tagInputPropsInit, z as tagPropsInit, w as treePropsInit };
|
package/package.json
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import { LazyRouterImport } from "../../index.js";
|
|
2
1
|
import { Component, Ref } from "vue";
|
|
3
2
|
//#region ../../packages/dlzn-ui/store/modules/router.d.ts
|
|
4
3
|
export interface RouteRecordRaw {
|
|
5
4
|
children?: RouteRecordRaw[];
|
|
6
|
-
component?: Component |
|
|
5
|
+
component?: Component | LazyVueComponentImport;
|
|
7
6
|
meta: {
|
|
8
7
|
fullScreen: boolean;
|
|
9
8
|
hidden: boolean;
|
|
@@ -20,7 +19,7 @@ export interface RouteRecordRaw {
|
|
|
20
19
|
}
|
|
21
20
|
interface ResRouterItem extends Omit<RouteRecordRaw, 'children' | 'component' | 'meta' | 'redirect'> {
|
|
22
21
|
children?: ResRouterItem[];
|
|
23
|
-
component?: Component |
|
|
22
|
+
component?: Component | LazyVueComponentImport | string;
|
|
24
23
|
hidden?: boolean;
|
|
25
24
|
meta?: {
|
|
26
25
|
fullScreen?: boolean;
|
package/store/modules/router.mjs
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import n from "
|
|
4
|
-
import r from "
|
|
5
|
-
import i from "
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import
|
|
1
|
+
import { getTopRoute as e } from "../../router/index.mjs";
|
|
2
|
+
import t from "./recentRouters.mjs";
|
|
3
|
+
import n from "../../plugins/alova/index.mjs";
|
|
4
|
+
import r from "./user.mjs";
|
|
5
|
+
import { markRaw as i, ref as a } from "vue";
|
|
6
|
+
import { defineStore as o } from "pinia";
|
|
7
|
+
import { useRouter as s } from "vue-router";
|
|
8
|
+
import c from "virtual:dlzn-ui/app-params";
|
|
9
9
|
//#region ../../packages/dlzn-ui/store/modules/router.ts
|
|
10
10
|
function l() {
|
|
11
|
-
return
|
|
11
|
+
return n.Get("getRouters", { meta: {
|
|
12
12
|
useFailMsg: "获取用户路由失败",
|
|
13
13
|
useLoading: "正在获取用户路由..."
|
|
14
14
|
} });
|
|
@@ -25,7 +25,7 @@ function d(e) {
|
|
|
25
25
|
}) : t.push(e);
|
|
26
26
|
}), t;
|
|
27
27
|
}
|
|
28
|
-
function f(
|
|
28
|
+
function f(t) {
|
|
29
29
|
let n = (e, t) => {
|
|
30
30
|
let r = [];
|
|
31
31
|
return e.forEach((e) => {
|
|
@@ -51,8 +51,8 @@ function f(e) {
|
|
|
51
51
|
}
|
|
52
52
|
e.component !== void 0 && !["Layout", "ParentView"].includes(e.component) && (i.component = _(e)), u(i) && r.push(i);
|
|
53
53
|
}), r;
|
|
54
|
-
}, r =
|
|
55
|
-
return r.children.push(...
|
|
54
|
+
}, r = e();
|
|
55
|
+
return r.children.push(...t), n([r], null);
|
|
56
56
|
}
|
|
57
57
|
function p(e) {
|
|
58
58
|
let t = (e) => {
|
|
@@ -67,7 +67,7 @@ function p(e) {
|
|
|
67
67
|
};
|
|
68
68
|
return t(e);
|
|
69
69
|
}
|
|
70
|
-
var m =
|
|
70
|
+
var m = c.viewsEntryLazyImport, h = [];
|
|
71
71
|
function g(e) {
|
|
72
72
|
return `/src/views/${e.split("___")[0]}.vue`;
|
|
73
73
|
}
|
|
@@ -80,33 +80,33 @@ function _(e) {
|
|
|
80
80
|
return;
|
|
81
81
|
}
|
|
82
82
|
return typeof t == "string" && h.push(g(t)), () => n().then((t) => ({
|
|
83
|
-
...t
|
|
83
|
+
...t,
|
|
84
84
|
name: e.name
|
|
85
85
|
}));
|
|
86
86
|
}
|
|
87
87
|
return e.component;
|
|
88
88
|
}
|
|
89
|
-
var v =
|
|
90
|
-
let e =
|
|
91
|
-
async function
|
|
92
|
-
let
|
|
93
|
-
h.length = 0, e.value =
|
|
89
|
+
var v = o("router", () => {
|
|
90
|
+
let e = a([]), n = s(), o = r();
|
|
91
|
+
async function c() {
|
|
92
|
+
let r = await l();
|
|
93
|
+
h.length = 0, e.value = i(p(f(d(r)))), o.isAdmin && Object.keys(m).forEach((e) => {
|
|
94
94
|
if (!h.includes(e)) {
|
|
95
95
|
let t = `${e} 页面对应的路由不存在`;
|
|
96
96
|
console.error(t);
|
|
97
97
|
}
|
|
98
|
-
}),
|
|
99
|
-
|
|
100
|
-
}),
|
|
98
|
+
}), n.hasRoute("Index") && n.removeRoute("Index"), e.value.forEach((e) => {
|
|
99
|
+
n.addRoute(e);
|
|
100
|
+
}), t().init();
|
|
101
101
|
}
|
|
102
102
|
function u() {
|
|
103
103
|
e.value.forEach((e) => {
|
|
104
|
-
|
|
104
|
+
n.removeRoute(e.name);
|
|
105
105
|
}), e.value = [];
|
|
106
106
|
}
|
|
107
107
|
return {
|
|
108
108
|
clear: u,
|
|
109
|
-
getRouters:
|
|
109
|
+
getRouters: c,
|
|
110
110
|
routersRaw: e
|
|
111
111
|
};
|
|
112
112
|
});
|
package/types/globle.d.ts
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
|
+
import type { Component } from 'vue'
|
|
2
|
+
|
|
1
3
|
export {} // 为了让这个声明文件变成模块声明文件,而不是一个全局声明文件
|
|
2
4
|
|
|
3
5
|
declare global {
|
|
6
|
+
export type LazyVueComponentImport = () => Promise<Component>
|
|
7
|
+
|
|
4
8
|
type PettyPrimitive = null | number | string | undefined
|
|
5
9
|
interface Window {
|
|
6
10
|
pluginWebUpdateNotice_?: {
|
|
File without changes
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */
|
|
2
|
-
[data-v-4f6efe42] .t-form__label{padding-right:var(--td-size-1)}[data-v-4f6efe42] .t-form__label--top{min-height:auto;line-height:inherit}[data-v-4f6efe42] .t-form__item{margin-bottom:var(--td-comp-margin-xxl)!important}[data-v-4f6efe42] .t-form__item.no_label_item .t-form__label{display:none}[data-v-4f6efe42] .t-form__item .t-input-adornment{flex:auto}.t-form[data-v-4f6efe42]{--td-comp-margin-xxl:var(--td-comp-margin-xl)}.t-form[data-v-4f6efe42]:has(.t-form__item:not(.no_label_item)) .no_label_item .t-form__label{opacity:0;height:1px;padding-right:0;display:block}.t-form.no_item_mb .t-form__item[data-v-4f6efe42]{margin-bottom:0!important}.t-form-inline[data-v-4f6efe42]{--repeat-min-width:220px;--repeat-gap:24px;grid-template-columns:repeat(auto-fill, minmax(var(--repeat-min-width), 1fr));gap:0 var(--repeat-gap);display:grid}.t-form-inline[data-v-4f6efe42] .no_label_item{align-self:flex-end}.t-form-inline[data-v-4f6efe42] .t-form__item{min-width:auto;margin-right:0;display:block}.t-form-inline[data-v-4f6efe42] .t-form__item.grid_item .t-form__controls-content{grid-template-columns:repeat(auto-fill, minmax(var(--repeat-min-width), 1fr));gap:0 var(--repeat-gap);display:grid}
|
package/entry/appParams.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { BusComponentInitialValueMap, BusFormItems, LazyRouterImport, UseListPromiseMap } from "../index.js";
|
|
2
|
-
//#region ../../packages/dlzn-ui/entry/appParams.d.ts
|
|
3
|
-
interface AppParams {
|
|
4
|
-
busComponentInitialValueMap: BusComponentInitialValueMap;
|
|
5
|
-
busFormItems: BusFormItems;
|
|
6
|
-
useListPromiseMap: UseListPromiseMap;
|
|
7
|
-
viewsEntryLazyImport: Record<string, LazyRouterImport>;
|
|
8
|
-
}
|
|
9
|
-
export declare function getAppParams(): AppParams;
|
|
10
|
-
export default function setAppParams(params: AppParams): void;
|
|
11
|
-
//#endregion
|
package/entry/appParams.mjs
DELETED