@das-fed/ui 6.4.0-dev.89 → 6.4.0-dev.90
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/package.json +5 -5
- package/packages/business-components/app-container/index.js +66 -66
- package/packages/business-components/app-container/index.js.gz +0 -0
- package/packages/business-components/change-enterprises/index.js +1 -1
- package/packages/business-components/change-enterprises/index.js.gz +0 -0
- package/packages/business-components/device-panel/index.js +4 -4
- package/packages/business-components/device-panel/index.js.gz +0 -0
- package/packages/business-components/process-form/index.js +1 -1
- package/packages/business-components/process-form/index.js.gz +0 -0
- package/packages/business-components/process-log/i18n/index.d.ts +0 -5
- package/packages/business-components/process-log/index.js +22 -23
- package/packages/business-components/process-log/index.js.gz +0 -0
- package/packages/business-components/process-search-form/index.js +1 -1
- package/packages/business-components/process-search-form/index.js.gz +0 -0
- package/packages/business-components/urgent-panel/index.js +2 -2
- package/packages/business-components/urgent-panel/index.js.gz +0 -0
- package/packages/business-components/user-org-dialog/index.js +1 -1
- package/packages/business-components/user-org-dialog/index.js.gz +0 -0
- package/packages/components/calendar/index.js +98 -100
- package/packages/components/calendar/index.js.gz +0 -0
- package/packages/components/cascader/index.js +12 -12
- package/packages/components/cascader/index.js.gz +0 -0
- package/packages/components/color-picker/index.js +6 -6
- package/packages/components/color-picker/index.js.gz +0 -0
- package/packages/components/date-picker/index.js +121 -115
- package/packages/components/date-picker/index.js.gz +0 -0
- package/packages/components/date-picker/style.css +1 -1
- package/packages/components/date-picker/style.css.gz +0 -0
- package/packages/components/image-upload/i18n/index.d.ts +5 -0
- package/packages/components/image-upload/index.js +81 -76
- package/packages/components/image-upload/index.js.gz +0 -0
- package/packages/components/image-viewer/index.js +127 -127
- package/packages/components/image-viewer/index.js.gz +0 -0
- package/packages/components/input/index.js +11 -11
- package/packages/components/input/index.js.gz +0 -0
- package/packages/components/input-dialog-select/index.js +1 -1
- package/packages/components/input-dialog-select/index.js.gz +0 -0
- package/packages/components/input-number/index.js +161 -144
- package/packages/components/input-number/index.js.gz +0 -0
- package/packages/components/input-number/style.css +1 -1
- package/packages/components/input-number/style.css.gz +0 -0
- package/packages/components/search/index.js +70 -79
- package/packages/components/search/index.js.gz +0 -0
- package/packages/components/search/style.css +1 -1
- package/packages/components/search/style.css.gz +0 -0
- package/packages/components/search-form/index.js +718 -705
- package/packages/components/search-form/index.js.gz +0 -0
- package/packages/components/search-form/style.css +1 -1
- package/packages/components/search-form/style.css.gz +0 -0
- package/packages/components/select/index.js +86 -86
- package/packages/components/select/index.js.gz +0 -0
- package/packages/components/select/style.css +1 -1
- package/packages/components/select/style.css.gz +0 -0
- package/packages/components/table/index.js +2817 -2817
- package/packages/components/table/index.js.gz +0 -0
- package/packages/components/table/style.css +1 -1
- package/packages/components/table/style.css.gz +0 -0
- package/packages/components/tree/index.js +1 -1
- package/packages/components/tree/index.js.gz +0 -0
- package/packages/components/tree-select/index.js +344 -344
- package/packages/components/tree-select/index.js.gz +0 -0
- package/packages/components/tree-v2/index.js +1 -1
- package/packages/components/tree-v2/index.js.gz +0 -0
- package/packages/components/upload/index.js +47 -47
- package/packages/components/upload/index.js.gz +0 -0
|
@@ -1,42 +1,41 @@
|
|
|
1
1
|
import '@das-fed/ui/packages/components/calendar/style.css';
|
|
2
|
-
import { withInstall as
|
|
3
|
-
import { defineComponent as
|
|
4
|
-
import { t as A, setI18nRule as
|
|
5
|
-
import
|
|
6
|
-
import le from "dayjs/plugin/localeData";
|
|
2
|
+
import { withInstall as ee } from "@das-fed/utils/with-install/index";
|
|
3
|
+
import { defineComponent as Q, ref as b, computed as g, watch as ae, nextTick as K, openBlock as u, createElementBlock as m, normalizeClass as B, Fragment as j, renderList as P, createElementVNode as W, toDisplayString as L, renderSlot as N, createCommentVNode as v, normalizeStyle as te, onMounted as ne, onBeforeUnmount as re, createVNode as se, createSlots as U, withCtx as V, normalizeProps as F, mergeProps as Z, guardReactiveProps as E, createBlock as oe } from "vue";
|
|
4
|
+
import { t as A, currentLang as q, setI18nRule as le } from "@das-fed/web/packages/i18n/index";
|
|
5
|
+
import M from "dayjs";
|
|
7
6
|
import { SizeWatcher as de } from "@das-fed/utils/size-watcher";
|
|
8
7
|
import { setThemeRule as ce } from "@das-fed/web/packages/theme/index";
|
|
9
|
-
const he = (
|
|
10
|
-
const l =
|
|
8
|
+
const he = (o, i) => {
|
|
9
|
+
const l = o.endOf("month"), c = i.startOf("month"), n = l.isSame(c, "week") ? c.add(1, "week") : c;
|
|
11
10
|
return [
|
|
12
|
-
[
|
|
11
|
+
[o, l],
|
|
13
12
|
[n.startOf("week"), i]
|
|
14
13
|
];
|
|
15
|
-
}, ie = (
|
|
16
|
-
const l =
|
|
14
|
+
}, ie = (o, i) => {
|
|
15
|
+
const l = o.endOf("month"), c = o.add(1, "month").startOf("month"), s = l.isSame(
|
|
17
16
|
c,
|
|
18
17
|
"week"
|
|
19
|
-
) ? c.add(1, "week") : c, n =
|
|
18
|
+
) ? c.add(1, "week") : c, n = s.endOf("month"), f = i.startOf("month"), z = n.isSame(f, "week") ? f.add(1, "week") : f;
|
|
20
19
|
return [
|
|
21
|
-
[
|
|
22
|
-
[
|
|
23
|
-
[
|
|
20
|
+
[o, l],
|
|
21
|
+
[s.startOf("week"), n],
|
|
22
|
+
[z.startOf("week"), i]
|
|
24
23
|
];
|
|
25
|
-
},
|
|
26
|
-
const l =
|
|
27
|
-
return
|
|
28
|
-
}, $ = (
|
|
29
|
-
const l =
|
|
30
|
-
return $(i).map((c,
|
|
31
|
-
}, pe = (
|
|
32
|
-
const i =
|
|
24
|
+
}, x = (o, i) => {
|
|
25
|
+
const l = o.startOf("week"), c = i.endOf("week"), s = l.get("month"), n = c.get("month");
|
|
26
|
+
return s === n ? [[l, c]] : (s + 1) % 12 === n ? he(l, c) : s + 2 === n || (s + 1) % 11 === n ? ie(l, c) : [];
|
|
27
|
+
}, $ = (o) => Array.from(Array.from({ length: o }).keys()), ue = (o, i) => {
|
|
28
|
+
const l = o.subtract(1, "month").endOf("month").date();
|
|
29
|
+
return $(i).map((c, s) => l - (i - s - 1));
|
|
30
|
+
}, pe = (o) => {
|
|
31
|
+
const i = o.daysInMonth();
|
|
33
32
|
return $(i).map((l, c) => c + 1);
|
|
34
|
-
}, me = (
|
|
33
|
+
}, me = (o) => $(o.length / 7).map((i) => {
|
|
35
34
|
const l = i * 7;
|
|
36
|
-
return
|
|
35
|
+
return o.slice(l, l + 7);
|
|
37
36
|
}), fe = { key: 0 }, ye = { class: "das-calendar-header-box" }, ke = { class: "das-calendar-header-week-line" }, ge = ["onClick"], we = {
|
|
38
37
|
name: "calendar-table"
|
|
39
|
-
},
|
|
38
|
+
}, G = /* @__PURE__ */ Q({
|
|
40
39
|
...we,
|
|
41
40
|
props: {
|
|
42
41
|
selectedDay: {},
|
|
@@ -52,13 +51,13 @@ const he = (s, i) => {
|
|
|
52
51
|
cellHeight: {}
|
|
53
52
|
},
|
|
54
53
|
emits: ["pick"],
|
|
55
|
-
setup(
|
|
56
|
-
const c = l,
|
|
54
|
+
setup(o, { expose: i, emit: l }) {
|
|
55
|
+
const c = l, s = M(), n = o, f = b("128px"), z = b(), Y = 60, S = ["sun", "mon", "tue", "wed", "thu", "fri", "sat"], _ = g(() => !!n.range && !!n.range.length), J = g(() => {
|
|
57
56
|
const e = n.firstDayOfWeek, t = n.showZhou ? "das-calendar-weeks-zhou-" : "das-calendar-weeks-";
|
|
58
57
|
return e === 0 ? S.map((r) => A(`${t}${r}`)) : S.slice(e).concat(S.slice(0, e)).map((r) => A(`${t}${r}`));
|
|
59
|
-
}), D =
|
|
58
|
+
}), D = g(() => {
|
|
60
59
|
let e = [];
|
|
61
|
-
if (
|
|
60
|
+
if (_.value) {
|
|
62
61
|
const [t, r] = n.range;
|
|
63
62
|
let h = [];
|
|
64
63
|
t.isSame(r, "month") ? h = $(r.date() - t.date() + 1).map((C) => ({
|
|
@@ -70,11 +69,11 @@ const he = (s, i) => {
|
|
|
70
69
|
}));
|
|
71
70
|
let k = h.length % 7;
|
|
72
71
|
k = k === 0 ? 0 : 7 - k;
|
|
73
|
-
const
|
|
72
|
+
const w = $(k).map((C, T) => ({
|
|
74
73
|
text: T + 1,
|
|
75
74
|
type: "next"
|
|
76
75
|
}));
|
|
77
|
-
e = h.concat(
|
|
76
|
+
e = h.concat(w);
|
|
78
77
|
} else {
|
|
79
78
|
const t = n.date.startOf("month").day(), r = ue(
|
|
80
79
|
n.date,
|
|
@@ -87,13 +86,13 @@ const he = (s, i) => {
|
|
|
87
86
|
type: "current"
|
|
88
87
|
}));
|
|
89
88
|
e = [...r, ...h];
|
|
90
|
-
const k = 7 - (e.length % 7 || 7),
|
|
89
|
+
const k = 7 - (e.length % 7 || 7), w = $(k).map((C, T) => ({
|
|
91
90
|
text: T + 1,
|
|
92
91
|
type: "next"
|
|
93
92
|
}));
|
|
94
|
-
if (e = e.concat(
|
|
95
|
-
const C =
|
|
96
|
-
text: C +
|
|
93
|
+
if (e = e.concat(w), n.calendartType == "simple" && e.length / 7 < 6) {
|
|
94
|
+
const C = w.length ? w[w.length - 1].text : 0, T = $(7).map((Oe, X) => ({
|
|
95
|
+
text: C + X + 1,
|
|
97
96
|
type: "next"
|
|
98
97
|
}));
|
|
99
98
|
e = e.concat(T);
|
|
@@ -106,14 +105,14 @@ const he = (s, i) => {
|
|
|
106
105
|
let t = Number(e) - Y - 1;
|
|
107
106
|
f.value = t / D.value.length - 1 + "px";
|
|
108
107
|
};
|
|
109
|
-
|
|
108
|
+
ae(
|
|
110
109
|
() => D.value,
|
|
111
110
|
(e) => {
|
|
112
111
|
if (n.cellHeight) {
|
|
113
112
|
f.value = `${n.cellHeight}px`;
|
|
114
113
|
return;
|
|
115
114
|
}
|
|
116
|
-
e && e.length ?
|
|
115
|
+
e && e.length ? K(() => {
|
|
117
116
|
H();
|
|
118
117
|
}) : f.value = "128px";
|
|
119
118
|
},
|
|
@@ -124,7 +123,7 @@ const he = (s, i) => {
|
|
|
124
123
|
f.value = `${n.cellHeight}px`;
|
|
125
124
|
return;
|
|
126
125
|
}
|
|
127
|
-
|
|
126
|
+
K(() => {
|
|
128
127
|
H();
|
|
129
128
|
});
|
|
130
129
|
}, y = (e, t) => {
|
|
@@ -138,7 +137,7 @@ const he = (s, i) => {
|
|
|
138
137
|
}
|
|
139
138
|
}, R = ({ text: e, type: t }) => {
|
|
140
139
|
const r = [t], h = y(e, t);
|
|
141
|
-
return h.isSame(n.selectedDay, "day") && r.push("is-selected"), h.isSame(
|
|
140
|
+
return h.isSame(n.selectedDay, "day") && r.push("is-selected"), h.isSame(s, "day") && r.push("is-today"), r;
|
|
142
141
|
}, I = ({ text: e, type: t }) => {
|
|
143
142
|
const r = y(e, t);
|
|
144
143
|
c("pick", r);
|
|
@@ -157,12 +156,12 @@ const he = (s, i) => {
|
|
|
157
156
|
if (t) {
|
|
158
157
|
const r = t[e];
|
|
159
158
|
if (r) {
|
|
160
|
-
const { text: h, type: k } = r,
|
|
159
|
+
const { text: h, type: k } = r, w = y(h, k);
|
|
161
160
|
return {
|
|
162
|
-
isSelected:
|
|
161
|
+
isSelected: w.isSame(n.selectedDay),
|
|
163
162
|
type: `${k}-month`,
|
|
164
|
-
day:
|
|
165
|
-
date:
|
|
163
|
+
day: w.format("YYYY-MM-DD"),
|
|
164
|
+
date: w.toDate()
|
|
166
165
|
};
|
|
167
166
|
}
|
|
168
167
|
}
|
|
@@ -185,14 +184,14 @@ const he = (s, i) => {
|
|
|
185
184
|
getHeight: O
|
|
186
185
|
}), (e, t) => D.value.length ? (u(), m("table", {
|
|
187
186
|
key: 0,
|
|
188
|
-
class: B(["das-calendar-table", { "is-range":
|
|
187
|
+
class: B(["das-calendar-table", { "is-range": _.value, "is-week": e.calendartType == "week", simple: e.calendartType == "simple" }]),
|
|
189
188
|
cellspacing: "0",
|
|
190
189
|
cellpadding: "0",
|
|
191
190
|
ref_key: "tableRef",
|
|
192
|
-
ref:
|
|
191
|
+
ref: z
|
|
193
192
|
}, [
|
|
194
|
-
e.hideHeader ?
|
|
195
|
-
(u(!0), m(j, null, P(
|
|
193
|
+
e.hideHeader ? v("", !0) : (u(), m("thead", fe, [
|
|
194
|
+
(u(!0), m(j, null, P(J.value, (r, h) => (u(), m("th", {
|
|
196
195
|
class: "das-calendar-table-header",
|
|
197
196
|
key: r
|
|
198
197
|
}, [
|
|
@@ -200,16 +199,16 @@ const he = (s, i) => {
|
|
|
200
199
|
W("div", ke, [
|
|
201
200
|
W("div", {
|
|
202
201
|
class: B(["das-calendar-header-week", { highlight: e.highlightWeek }])
|
|
203
|
-
},
|
|
202
|
+
}, L(r), 3),
|
|
204
203
|
e.calendartType == "week" ? N(e.$slots, "week-type", {
|
|
205
204
|
key: 0,
|
|
206
205
|
data: p(h)
|
|
207
|
-
}) :
|
|
206
|
+
}) : v("", !0)
|
|
208
207
|
]),
|
|
209
208
|
e.calendartType == "week" ? (u(), m("div", {
|
|
210
209
|
key: 0,
|
|
211
210
|
class: B(["das-calendar-header-day", { highlight: e.highlightDay }])
|
|
212
|
-
},
|
|
211
|
+
}, L(a(h)), 3)) : v("", !0)
|
|
213
212
|
])
|
|
214
213
|
]))), 128))
|
|
215
214
|
])),
|
|
@@ -221,14 +220,14 @@ const he = (s, i) => {
|
|
|
221
220
|
"hide-border": h === 0 && e.hideHeader
|
|
222
221
|
})
|
|
223
222
|
}, [
|
|
224
|
-
(u(!0), m(j, null, P(r, (k,
|
|
225
|
-
key:
|
|
223
|
+
(u(!0), m(j, null, P(r, (k, w) => (u(), m("td", {
|
|
224
|
+
key: w,
|
|
226
225
|
class: B(R(k)),
|
|
227
226
|
onClick: (C) => I(k)
|
|
228
227
|
}, [
|
|
229
228
|
W("div", {
|
|
230
229
|
class: "das-calendar-day",
|
|
231
|
-
style:
|
|
230
|
+
style: te({ height: f.value })
|
|
232
231
|
}, [
|
|
233
232
|
N(e.$slots, "date-cell", {
|
|
234
233
|
data: d(k)
|
|
@@ -237,7 +236,7 @@ const he = (s, i) => {
|
|
|
237
236
|
], 10, ge))), 128))
|
|
238
237
|
], 2))), 128))
|
|
239
238
|
])
|
|
240
|
-
], 2)) :
|
|
239
|
+
], 2)) : v("", !0);
|
|
241
240
|
}
|
|
242
241
|
}), Ce = {
|
|
243
242
|
key: 0,
|
|
@@ -251,15 +250,15 @@ const he = (s, i) => {
|
|
|
251
250
|
}, ze = {
|
|
252
251
|
key: 1,
|
|
253
252
|
class: "das-calendar-body 2"
|
|
254
|
-
},
|
|
253
|
+
}, Ne = {
|
|
255
254
|
key: 1,
|
|
256
255
|
class: "das-calendar-cell-date"
|
|
257
|
-
},
|
|
256
|
+
}, _e = {
|
|
258
257
|
key: 2,
|
|
259
258
|
class: "das-calendar-cell-cont"
|
|
260
259
|
}, Me = {
|
|
261
260
|
name: "test"
|
|
262
|
-
}, $e = /* @__PURE__ */
|
|
261
|
+
}, $e = /* @__PURE__ */ Q({
|
|
263
262
|
...Me,
|
|
264
263
|
props: {
|
|
265
264
|
modelValue: {},
|
|
@@ -274,48 +273,47 @@ const he = (s, i) => {
|
|
|
274
273
|
cellHeight: { default: 0 }
|
|
275
274
|
},
|
|
276
275
|
emits: ["update:model-value", "itemClick"],
|
|
277
|
-
setup(
|
|
278
|
-
|
|
279
|
-
const c = v.localeData().firstDayOfWeek(), o = s, n = l, f = b(), _ = b(), Y = b(), S = w(() => o.firstDayOfWeek || c), M = b(), L = v(), D = w({
|
|
276
|
+
setup(o, { expose: i, emit: l }) {
|
|
277
|
+
const c = g(() => q.value == "zh-CN" ? 1 : (q.value == "en", 0)), s = o, n = l, f = b(), z = b(), Y = b(), S = g(() => s.firstDayOfWeek || c.value), _ = b(), J = M(), D = g({
|
|
280
278
|
get() {
|
|
281
|
-
return
|
|
279
|
+
return s.modelValue ? (_.value = y.value, y.value) : _.value;
|
|
282
280
|
},
|
|
283
281
|
set(a) {
|
|
284
282
|
if (!a) return;
|
|
285
|
-
|
|
283
|
+
_.value = a;
|
|
286
284
|
const p = a.toDate();
|
|
287
|
-
|
|
285
|
+
s.isSwitchMonth && n("update:model-value", p);
|
|
288
286
|
}
|
|
289
|
-
}), H =
|
|
290
|
-
if (
|
|
291
|
-
if (
|
|
292
|
-
const p = (
|
|
293
|
-
return e.push(
|
|
287
|
+
}), H = g(() => {
|
|
288
|
+
if (s.type == "week") {
|
|
289
|
+
if (s.range) return s.range;
|
|
290
|
+
const p = (M(s.modelValue).day() - S.value + 7) % 7, d = 7 - (p + 1), e = [];
|
|
291
|
+
return e.push(M(s.modelValue).subtract(p, "day").toDate()), e.push(M(s.modelValue).add(d, "day").toDate()), e;
|
|
294
292
|
} else
|
|
295
|
-
return
|
|
296
|
-
}), O =
|
|
293
|
+
return s.range ? s.range : void 0;
|
|
294
|
+
}), O = g(() => {
|
|
297
295
|
if (!H.value) return [];
|
|
298
|
-
const a = H.value.map((e) =>
|
|
299
|
-
return
|
|
300
|
-
}), y =
|
|
301
|
-
|
|
296
|
+
const a = H.value.map((e) => M(e)), [p, d] = a;
|
|
297
|
+
return s.type == "week" ? [[p, d]] : p.isAfter(d) ? [] : p.isSame(d, "month") ? x(p, d) : p.add(1, "month").month() !== d.month() ? [] : x(p, d);
|
|
298
|
+
}), y = g(() => s.modelValue ? M(s.modelValue) : D.value || (O.value.length ? O.value[0][0] : J));
|
|
299
|
+
g(() => y.value.subtract(1, "month").date(1)), g(() => y.value.add(1, "month").date(1)), g(() => y.value.subtract(1, "year").date(1)), g(() => y.value.add(1, "year").date(1)), g(() => {
|
|
302
300
|
const a = `das-calendar-month${y.value.format("M")}`;
|
|
303
301
|
return `${y.value.year()} ${A("das-calendar-year")} ${A(a)}`;
|
|
304
|
-
}),
|
|
302
|
+
}), ne(() => {
|
|
305
303
|
Y.value = de(() => {
|
|
306
304
|
var a, p;
|
|
307
|
-
Array.isArray(
|
|
305
|
+
Array.isArray(z.value) ? (a = z.value[0]) == null || a.getHeight() : (p = z.value) == null || p.getHeight();
|
|
308
306
|
}, f.value);
|
|
309
|
-
}),
|
|
307
|
+
}), re(() => {
|
|
310
308
|
Y.value.disconnect();
|
|
311
309
|
});
|
|
312
310
|
const R = (a) => {
|
|
313
|
-
|
|
311
|
+
s.isSwitchSelection && (D.value = a), n("itemClick", a.toDate());
|
|
314
312
|
};
|
|
315
313
|
return i({
|
|
316
314
|
$calendar: f,
|
|
317
315
|
setActive: (a) => {
|
|
318
|
-
D.value =
|
|
316
|
+
D.value = M(a), n("itemClick", a);
|
|
319
317
|
}
|
|
320
318
|
}), (a, p) => (u(), m("div", {
|
|
321
319
|
ref_key: "$calendar",
|
|
@@ -323,9 +321,9 @@ const he = (s, i) => {
|
|
|
323
321
|
class: "das-ui-calendar"
|
|
324
322
|
}, [
|
|
325
323
|
O.value.length === 0 ? (u(), m("div", Ce, [
|
|
326
|
-
|
|
324
|
+
se(G, {
|
|
327
325
|
ref_key: "$calendarTable",
|
|
328
|
-
ref:
|
|
326
|
+
ref: z,
|
|
329
327
|
date: y.value,
|
|
330
328
|
firstDayOfWeek: S.value,
|
|
331
329
|
parent: f.value,
|
|
@@ -334,16 +332,16 @@ const he = (s, i) => {
|
|
|
334
332
|
highlightDay: a.highlightDay,
|
|
335
333
|
showZhou: a.showZhou,
|
|
336
334
|
cellHeight: a.cellHeight,
|
|
337
|
-
"selected-day":
|
|
335
|
+
"selected-day": _.value,
|
|
338
336
|
onPick: R
|
|
339
|
-
},
|
|
337
|
+
}, U({
|
|
340
338
|
"date-cell": V((d) => [
|
|
341
|
-
a.$slots.custom ? N(a.$slots, "custom", F(Z({ key: 0 }, d))) :
|
|
339
|
+
a.$slots.custom ? N(a.$slots, "custom", F(Z({ key: 0 }, d))) : v("", !0),
|
|
342
340
|
a.type != "week" && !a.$slots.custom ? (u(), m("p", De, [
|
|
343
|
-
W("span", null,
|
|
341
|
+
W("span", null, L(Number(d.data.day.split("-").slice(2)).toString()), 1),
|
|
344
342
|
N(a.$slots, "date-type", F(E(d)))
|
|
345
|
-
])) :
|
|
346
|
-
a.$slots.custom ?
|
|
343
|
+
])) : v("", !0),
|
|
344
|
+
a.$slots.custom ? v("", !0) : (u(), m("div", ve, [
|
|
347
345
|
N(a.$slots, "date-cell", F(E(d)))
|
|
348
346
|
]))
|
|
349
347
|
]),
|
|
@@ -358,10 +356,10 @@ const he = (s, i) => {
|
|
|
358
356
|
} : void 0
|
|
359
357
|
]), 1032, ["date", "firstDayOfWeek", "parent", "calendartType", "highlightWeek", "highlightDay", "showZhou", "cellHeight", "selected-day"])
|
|
360
358
|
])) : (u(), m("div", ze, [
|
|
361
|
-
(u(!0), m(j, null, P(O.value, (d, e) => (u(), oe(
|
|
359
|
+
(u(!0), m(j, null, P(O.value, (d, e) => (u(), oe(G, {
|
|
362
360
|
ref_for: !0,
|
|
363
361
|
ref_key: "$calendarTable",
|
|
364
|
-
ref:
|
|
362
|
+
ref: z,
|
|
365
363
|
key: e,
|
|
366
364
|
firstDayOfWeek: S.value,
|
|
367
365
|
date: d[0],
|
|
@@ -370,21 +368,21 @@ const he = (s, i) => {
|
|
|
370
368
|
highlightDay: a.highlightDay,
|
|
371
369
|
showZhou: a.showZhou,
|
|
372
370
|
cellHeight: a.cellHeight,
|
|
373
|
-
"selected-day":
|
|
371
|
+
"selected-day": _.value,
|
|
374
372
|
range: d,
|
|
375
373
|
parent: f.value,
|
|
376
374
|
"hide-header": e !== 0,
|
|
377
375
|
onPick: R
|
|
378
|
-
},
|
|
376
|
+
}, U({
|
|
379
377
|
"date-cell": V((t) => [
|
|
380
378
|
a.$slots.custom ? N(a.$slots, "custom", Z({
|
|
381
379
|
key: 0,
|
|
382
380
|
ref_for: !0
|
|
383
|
-
}, t)) :
|
|
384
|
-
a.type != "week" && !a.$slots.custom ? (u(), m("p",
|
|
385
|
-
W("span", null,
|
|
386
|
-
])) :
|
|
387
|
-
a.$slots.custom ?
|
|
381
|
+
}, t)) : v("", !0),
|
|
382
|
+
a.type != "week" && !a.$slots.custom ? (u(), m("p", Ne, [
|
|
383
|
+
W("span", null, L(Number(t.data.day.split("-").slice(2)).toString()), 1)
|
|
384
|
+
])) : v("", !0),
|
|
385
|
+
a.$slots.custom ? v("", !0) : (u(), m("div", _e, [
|
|
388
386
|
N(a.$slots, "date-cell", Z({ ref_for: !0 }, t))
|
|
389
387
|
]))
|
|
390
388
|
]),
|
|
@@ -468,10 +466,10 @@ const he = (s, i) => {
|
|
|
468
466
|
"das-calendar-months-nov": { "zh-CN": "十一月", en: "Nov", _appCode: "framework" },
|
|
469
467
|
"das-calendar-months-dec": { "zh-CN": "十二月", en: "Dec", _appCode: "framework" }
|
|
470
468
|
};
|
|
471
|
-
|
|
469
|
+
le(We);
|
|
472
470
|
ce(Se);
|
|
473
|
-
const
|
|
471
|
+
const Re = ee($e), Ve = { name: `calendar ${A("日历")}` };
|
|
474
472
|
export {
|
|
475
|
-
|
|
476
|
-
|
|
473
|
+
Re as DasCalendar,
|
|
474
|
+
Ve as default
|
|
477
475
|
};
|
|
Binary file
|
|
@@ -10,13 +10,13 @@ import { vScrollbar as Ce } from "@das-fed/ui/packages/components/scrollbar/inde
|
|
|
10
10
|
import { DasTooltip as J } from "@das-fed/ui/packages/components/tooltip/index";
|
|
11
11
|
import { calcTextWidth as Be } from "@das-fed/utils/common-tools";
|
|
12
12
|
import { useModelValue as Fe } from "@das-fed/utils/vue";
|
|
13
|
-
const Me = { style: { maxheight: "200px" } },
|
|
13
|
+
const Me = { style: { maxheight: "200px" } }, _e = {
|
|
14
14
|
key: 0,
|
|
15
15
|
class: "das-cascader-error-label-content"
|
|
16
|
-
},
|
|
16
|
+
}, Se = {
|
|
17
17
|
name: "DasCascader"
|
|
18
18
|
}, De = /* @__PURE__ */ de({
|
|
19
|
-
...
|
|
19
|
+
...Se,
|
|
20
20
|
props: {
|
|
21
21
|
modelValue: { default: void 0 },
|
|
22
22
|
props: {},
|
|
@@ -42,7 +42,7 @@ const Me = { style: { maxheight: "200px" } }, Se = {
|
|
|
42
42
|
ne((e) => ({
|
|
43
43
|
"23b9eff0": re.value,
|
|
44
44
|
"39b5143d": te.value,
|
|
45
|
-
aa5709a8:
|
|
45
|
+
aa5709a8: S.value
|
|
46
46
|
}));
|
|
47
47
|
const a = V, o = Fe(a, "modelValue"), I = T, K = ce(), p = r(null), v = r(null), L = r(null), w = r(), M = r(!1), k = u(() => a.isView ? a.noSetDefaultVal ? " " : "-" : a.placeholder ?? " "), f = r(0), m = r(0), d = r(!1), Q = u(() => (Array.isArray(o.value) ? o.value.length : o.value) ? w.value : k.value), z = u(() => {
|
|
48
48
|
var e;
|
|
@@ -107,7 +107,7 @@ const Me = { style: { maxheight: "200px" } }, Se = {
|
|
|
107
107
|
visibility: "visible",
|
|
108
108
|
top: C.value.y + "px",
|
|
109
109
|
left: C.value.x + "px"
|
|
110
|
-
})),
|
|
110
|
+
})), _ = r({
|
|
111
111
|
display: "block",
|
|
112
112
|
color: j("--das-ui-input-error-color").value,
|
|
113
113
|
"white-space": "break-spaces"
|
|
@@ -125,7 +125,7 @@ const Me = { style: { maxheight: "200px" } }, Se = {
|
|
|
125
125
|
e ? ae() : le();
|
|
126
126
|
}, re = u(() => a.width ? a.width : "230px"), te = u(() => a.height ? a.height : "auto"), N = u(() => ({
|
|
127
127
|
width: typeof a.width == "number" ? a.width + "px" : a.width
|
|
128
|
-
})),
|
|
128
|
+
})), S = r("-10px");
|
|
129
129
|
pe(() => {
|
|
130
130
|
o.value ? setTimeout(() => {
|
|
131
131
|
se();
|
|
@@ -141,7 +141,7 @@ const Me = { style: { maxheight: "200px" } }, Se = {
|
|
|
141
141
|
U(() => {
|
|
142
142
|
var t, s;
|
|
143
143
|
const l = (s = (t = p.value) == null ? void 0 : t.popperPaneRef) == null ? void 0 : s.attributes["data-popper-placement"].value;
|
|
144
|
-
l && l.indexOf("top") > -1 ?
|
|
144
|
+
l && l.indexOf("top") > -1 ? S.value = "10px" : S.value = "-10px";
|
|
145
145
|
});
|
|
146
146
|
};
|
|
147
147
|
return F({
|
|
@@ -224,9 +224,9 @@ const Me = { style: { maxheight: "200px" } }, Se = {
|
|
|
224
224
|
_: 3
|
|
225
225
|
}, 8, ["visible", "disabled", "content"]),
|
|
226
226
|
e.error && e.errorLabel ? (i(), n(Z, { key: 0 }, [
|
|
227
|
-
e.errorMode === "default" ? (i(), n("div",
|
|
227
|
+
e.errorMode === "default" ? (i(), n("div", _e, [
|
|
228
228
|
B("span", {
|
|
229
|
-
style: y(
|
|
229
|
+
style: y(_.value)
|
|
230
230
|
}, x(e.errorLabel), 5)
|
|
231
231
|
])) : e.errorMode === "overlay" && M.value ? (i(), n(Z, { key: 1 }, [
|
|
232
232
|
e.teleported ? (i(), be(ge, {
|
|
@@ -237,7 +237,7 @@ const Me = { style: { maxheight: "200px" } }, Se = {
|
|
|
237
237
|
style: y(Y.value)
|
|
238
238
|
}, [
|
|
239
239
|
B("span", {
|
|
240
|
-
style: y(
|
|
240
|
+
style: y(_.value)
|
|
241
241
|
}, x(e.errorLabel), 5)
|
|
242
242
|
], 4)
|
|
243
243
|
])) : (i(), n("div", {
|
|
@@ -246,7 +246,7 @@ const Me = { style: { maxheight: "200px" } }, Se = {
|
|
|
246
246
|
class: "das-cascader-overlay-error-label-content"
|
|
247
247
|
}, [
|
|
248
248
|
B("span", {
|
|
249
|
-
style: y(
|
|
249
|
+
style: y(_.value)
|
|
250
250
|
}, x(e.errorLabel), 5)
|
|
251
251
|
], 4))
|
|
252
252
|
], 64)) : q("", !0)
|
|
@@ -258,7 +258,7 @@ const Me = { style: { maxheight: "200px" } }, Se = {
|
|
|
258
258
|
for (const [a, o] of F)
|
|
259
259
|
T[a] = o;
|
|
260
260
|
return T;
|
|
261
|
-
}, Ee = /* @__PURE__ */ Pe(De, [["__scopeId", "data-v-9722f84d"]]), Ie = { 请选择: { "zh-CN": "请选择", en: "Please
|
|
261
|
+
}, Ee = /* @__PURE__ */ Pe(De, [["__scopeId", "data-v-9722f84d"]]), Ie = { 请选择: { "zh-CN": "请选择", en: "Please select", _appCode: "framework" } }, Le = {
|
|
262
262
|
"--das-ui-cascader-color-primary": "#5582F3",
|
|
263
263
|
// 主题色
|
|
264
264
|
"--das-ui-cascader-color-text": G("--das-ui-color-normal"),
|
|
Binary file
|
|
@@ -46,13 +46,13 @@ const Y = (s, d) => {
|
|
|
46
46
|
fold: import("@das-fed/ui/packages/icons/fold"),
|
|
47
47
|
close2: import("@das-fed/ui/packages/icons/close-2")
|
|
48
48
|
});
|
|
49
|
-
const p = I(() => F.value === "zh-CN" ? Q : W), _ = I(() => l.placeholder || A("请输入")), { innerValue: a, inputChangeHandler: n, inputInputHandler:
|
|
49
|
+
const p = I(() => F.value === "zh-CN" ? Q : W), _ = I(() => l.placeholder || A("请输入")), { innerValue: a, inputChangeHandler: n, inputInputHandler: R, colorOption: o, colorPickerValue: h } = Y(l, u), b = y(), m = y(!1), B = (t) => {
|
|
50
50
|
var i, r;
|
|
51
51
|
u("change", t), a.value = t, (r = (i = b.value) == null ? void 0 : i.getElRef()) == null || r.handleClose(), m.value = !1;
|
|
52
52
|
}, D = () => {
|
|
53
53
|
var t, i;
|
|
54
54
|
o.value.mode != "default" && ((i = (t = b.value) == null ? void 0 : t.getElRef()) == null || i.handleOpen(), m.value = !0);
|
|
55
|
-
},
|
|
55
|
+
}, E = (t) => {
|
|
56
56
|
m.value = t;
|
|
57
57
|
};
|
|
58
58
|
return (t, i) => (c(), V("div", Z, [
|
|
@@ -72,7 +72,7 @@ const Y = (s, d) => {
|
|
|
72
72
|
disabled: e(o).disabled || l.disabled,
|
|
73
73
|
append: "",
|
|
74
74
|
onClick: D,
|
|
75
|
-
onInput: e(
|
|
75
|
+
onInput: e(R),
|
|
76
76
|
borderType: l.borderType,
|
|
77
77
|
placeholder: _.value,
|
|
78
78
|
noSetDefaultVal: e(o).mode == "predefine" && !e(o).isView && !l.isView && !e(o).disabled && !l.disabled || l.noSetDefaultVal && (e(o).isView || l.isView) && !e(a)
|
|
@@ -109,7 +109,7 @@ const Y = (s, d) => {
|
|
|
109
109
|
placement: "bottom-end",
|
|
110
110
|
selfPopperClass: "color-predefine-dropdown",
|
|
111
111
|
"hide-on-click": !1,
|
|
112
|
-
onVisibleChange:
|
|
112
|
+
onVisibleChange: E
|
|
113
113
|
}, {
|
|
114
114
|
content: f(() => [
|
|
115
115
|
P("span", {
|
|
@@ -136,7 +136,7 @@ const Y = (s, d) => {
|
|
|
136
136
|
class: g(["color-predefine-span", { active: e(a) == r }]),
|
|
137
137
|
key: S,
|
|
138
138
|
style: H("background-color:" + r),
|
|
139
|
-
onClick: (de) =>
|
|
139
|
+
onClick: (de) => B(r)
|
|
140
140
|
}, null, 14, oe))), 128))
|
|
141
141
|
])
|
|
142
142
|
]),
|
|
@@ -167,7 +167,7 @@ const Y = (s, d) => {
|
|
|
167
167
|
},
|
|
168
168
|
"--das-ui-color-picker-primary": "#5582F3"
|
|
169
169
|
// 主题色
|
|
170
|
-
}, re = { 请输入: { "zh-CN": "请输入", en: "Please
|
|
170
|
+
}, re = { 请输入: { "zh-CN": "请输入", en: "Please enter", _appCode: "framework" } };
|
|
171
171
|
L(re);
|
|
172
172
|
X(ie);
|
|
173
173
|
const Ce = () => y(null), ge = $(ne);
|
|
Binary file
|