@das-fed/upf-ui 6.4.0-dev.197 → 6.4.0-dev.199
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/components/date-picker/index.d.ts +0 -3
- package/packages/components/date-picker/index.js +489 -480
- package/packages/components/date-picker/index.js.gz +0 -0
- package/packages/components/date-picker/src/DatePicker.vue.d.ts +0 -2
- package/packages/components/date-picker/src/RangePicker.vue.d.ts +0 -1
- package/packages/components/date-picker/src/TimePicker.vue.d.ts +0 -2
- package/packages/components/date-picker/src/TimeRangePicker.vue.d.ts +0 -2
- package/packages/components/date-picker/style.css +1 -1
- package/packages/components/date-picker/style.css.gz +0 -0
- package/packages/components/form-item/index.js +207 -205
- package/packages/components/form-item/index.js.gz +0 -0
|
@@ -1,35 +1,31 @@
|
|
|
1
1
|
import '@das-fed/upf-ui/packages/components/date-picker/style.css';
|
|
2
|
-
import { withInstall as
|
|
3
|
-
import { defineComponent as
|
|
4
|
-
import { ConfigProvider as
|
|
5
|
-
import { DasAutoRegisterIcon as
|
|
6
|
-
import { DasTooltip as
|
|
7
|
-
import { DasErrorOverlayModel as
|
|
8
|
-
import { useModelValue as
|
|
9
|
-
import { vHoverInside as
|
|
10
|
-
import { useZIndex as
|
|
11
|
-
import { getVarValue as
|
|
12
|
-
import { currentLang as
|
|
2
|
+
import { withInstall as pe } from "@das-fed/upf-utils/with-install/index";
|
|
3
|
+
import { defineComponent as ce, useCssVars as ve, ref as u, watch as _, computed as s, openBlock as v, createElementBlock as T, normalizeClass as be, unref as o, normalizeStyle as Y, createVNode as I, withCtx as c, withDirectives as fe, createBlock as j, mergeProps as ne, isRef as Ce, createSlots as Ee, renderSlot as S, normalizeProps as ge, guardReactiveProps as we, createElementVNode as V, toDisplayString as W, Fragment as ue, createCommentVNode as P, nextTick as ee, useAttrs as Be, createTextVNode as De, renderList as Le, withModifiers as Re } from "vue";
|
|
4
|
+
import { ConfigProvider as Te, DatePicker as Ne, RangePicker as We, Dropdown as Fe, Menu as Ze, MenuItem as Ae, TimePicker as Oe, TimeRangePicker as qe } from "ant-design-vue";
|
|
5
|
+
import { DasAutoRegisterIcon as Me, DasIcon as re } from "@das-fed/upf-ui/packages/components/icon/index";
|
|
6
|
+
import { DasTooltip as Ie } from "@das-fed/upf-ui/packages/components/tooltip/index";
|
|
7
|
+
import { DasErrorOverlayModel as me } from "@das-fed/upf-ui/packages/components/error-overlay-model/index";
|
|
8
|
+
import { useModelValue as X } from "@das-fed/upf-utils/vue";
|
|
9
|
+
import { vHoverInside as he } from "@das-fed/upf-utils/directive/hoverInside/index";
|
|
10
|
+
import { useZIndex as Se } from "@das-fed/upf-utils/hooks/popup-manager/use-zindex";
|
|
11
|
+
import { getVarValue as ye, getVar as _e, setThemeRule as Ke } from "@das-fed/upf-web/packages/theme/index";
|
|
12
|
+
import { currentLang as D, loadLocale as $e, t as se, setI18nRule as He } from "@das-fed/upf-web/packages/i18n/index";
|
|
13
13
|
import { calcTextWidth as ze } from "@das-fed/upf-utils/common-tools";
|
|
14
14
|
import "ant-design-vue/es/date-picker/style/css";
|
|
15
15
|
import "ant-design-vue/es/config-provider/style/css";
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import "dayjs/locale/zh-cn";
|
|
19
|
-
import "dayjs/locale/en";
|
|
20
|
-
import { DasDatePicker as Ve } from "@das-fed/upf-ui/packages/components/date-picker/index";
|
|
21
|
-
import Ee from "dayjs";
|
|
16
|
+
import { DasDatePicker as Pe } from "@das-fed/upf-ui/packages/components/date-picker/index";
|
|
17
|
+
import Ve from "dayjs";
|
|
22
18
|
import "ant-design-vue/es/dropdown/style/css";
|
|
23
19
|
import "ant-design-vue/es/menu/style/css";
|
|
24
|
-
import { DasIconDengdai as
|
|
20
|
+
import { DasIconDengdai as Ue } from "@das-fed/upf-ui/packages/icons/dengdai/index";
|
|
25
21
|
import "ant-design-vue/es/time-picker/style/css";
|
|
26
|
-
const
|
|
22
|
+
const je = { class: "ant-picker-cell-inner" }, Ye = {
|
|
27
23
|
key: 0,
|
|
28
24
|
class: "das-date-picker-error-label-content"
|
|
29
|
-
},
|
|
25
|
+
}, Xe = {
|
|
30
26
|
name: "DasDatePicker"
|
|
31
|
-
},
|
|
32
|
-
...
|
|
27
|
+
}, Ge = /* @__PURE__ */ ce({
|
|
28
|
+
...Xe,
|
|
33
29
|
props: {
|
|
34
30
|
modelValue: {},
|
|
35
31
|
borderType: { default: "bordered" },
|
|
@@ -51,162 +47,167 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
51
47
|
formSize: {}
|
|
52
48
|
},
|
|
53
49
|
emits: ["change", "openChange", "update:model-value", "update:error"],
|
|
54
|
-
setup(
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
50
|
+
setup(F, { expose: K, emit: n }) {
|
|
51
|
+
ve((r) => ({
|
|
52
|
+
"1a23ca34": H.value,
|
|
53
|
+
51064807: A.value
|
|
58
54
|
}));
|
|
59
|
-
const t =
|
|
60
|
-
|
|
55
|
+
const t = F, m = n;
|
|
56
|
+
Me({
|
|
61
57
|
right: import("@das-fed/upf-ui/packages/icons/right"),
|
|
62
58
|
left: import("@das-fed/upf-ui/packages/icons/left"),
|
|
63
59
|
"double-arrow-left": import("@das-fed/upf-ui/packages/icons/double-arrow-left"),
|
|
64
60
|
"double-arrow-right": import("@das-fed/upf-ui/packages/icons/double-arrow-right"),
|
|
65
61
|
riqixuanze: import("@das-fed/upf-ui/packages/icons/riqixuanze")
|
|
66
62
|
});
|
|
67
|
-
const
|
|
63
|
+
const x = u(void 0);
|
|
64
|
+
_(D, async () => {
|
|
65
|
+
x.value = await $e(D.value);
|
|
66
|
+
}, { immediate: !0 });
|
|
67
|
+
const y = s(() => `date-picker-${D.value}`), i = u(null), R = u(null), p = X(t, "modelValue"), M = X(t, "error"), Z = s(() => t.isView ? t.noSetDefaultVal ? "" : "-" : t.placeholder || se("请选择日期")), E = s(() => ({
|
|
68
68
|
width: t.width
|
|
69
|
-
})),
|
|
69
|
+
})), H = s(() => t.width ? t.width : "230px"), N = s(() => t.formSize), A = s(() => t.height ? t.height : N.value ? {
|
|
70
70
|
small: "24px",
|
|
71
71
|
default: "32px",
|
|
72
72
|
large: "40px"
|
|
73
|
-
}[
|
|
74
|
-
"z-index":
|
|
75
|
-
})),
|
|
73
|
+
}[N.value] : "auto"), B = u(3e3), O = s(() => ({
|
|
74
|
+
"z-index": B.value
|
|
75
|
+
})), $ = u(!1), U = u({
|
|
76
76
|
display: "block",
|
|
77
|
-
color:
|
|
77
|
+
color: ye("--das-ui-date-picker-overlay-error-color").value,
|
|
78
78
|
"white-space": "break-spaces"
|
|
79
|
-
}), b = u(!1),
|
|
79
|
+
}), b = u(!1), C = u(""), q = s(() => p.value ? C.value : Z.value), G = () => {
|
|
80
80
|
const r = t.size === "table" ? 12 : 14;
|
|
81
|
-
return ze(
|
|
81
|
+
return ze(Z.value, r);
|
|
82
82
|
}, k = () => {
|
|
83
83
|
var l;
|
|
84
|
-
const r = (l =
|
|
85
|
-
return p.value ? r == null ? void 0 : r.scrollWidth :
|
|
86
|
-
},
|
|
84
|
+
const r = (l = i.value) == null ? void 0 : l.$el.querySelector(".ant-picker-input>input");
|
|
85
|
+
return p.value ? r == null ? void 0 : r.scrollWidth : G();
|
|
86
|
+
}, a = () => {
|
|
87
87
|
var e;
|
|
88
|
-
const r = (e =
|
|
89
|
-
return r ? (
|
|
90
|
-
},
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
88
|
+
const r = (e = i.value) == null ? void 0 : e.$el.querySelector(".ant-picker-input>input");
|
|
89
|
+
return r ? (C.value = r.getAttribute("value"), r.removeAttribute("title"), (r == null ? void 0 : r.offsetWidth) ?? 0) : 0;
|
|
90
|
+
}, f = u(0), g = u(0);
|
|
91
|
+
_(() => [Z.value, p.value], () => {
|
|
92
|
+
ee(() => {
|
|
93
|
+
f.value = a(), g.value = k(), (f.value === g.value || g.value - f.value < 1) && (b.value = !1);
|
|
94
94
|
});
|
|
95
95
|
});
|
|
96
|
-
const
|
|
97
|
-
|
|
96
|
+
const J = u();
|
|
97
|
+
_(
|
|
98
98
|
() => {
|
|
99
99
|
var r;
|
|
100
|
-
return (r =
|
|
100
|
+
return (r = R.value) == null ? void 0 : r.$tooltipRef.popperRef.contentRef;
|
|
101
101
|
},
|
|
102
102
|
(r) => {
|
|
103
103
|
r && (r.addEventListener("mouseenter", function() {
|
|
104
|
-
b.value = !0,
|
|
104
|
+
b.value = !0, J.value && clearTimeout(J.value);
|
|
105
105
|
}), r.addEventListener("mouseleave", function() {
|
|
106
|
-
|
|
106
|
+
J.value = setTimeout(() => {
|
|
107
107
|
b.value = !1;
|
|
108
108
|
}, 200);
|
|
109
109
|
}));
|
|
110
110
|
}
|
|
111
111
|
);
|
|
112
112
|
const w = (r) => {
|
|
113
|
-
r && (
|
|
113
|
+
r && (B.value = Se().nextZIndex()), m("openChange", r), D.value === "en" && ee(() => {
|
|
114
114
|
const l = document == null ? void 0 : document.querySelectorAll(".ant-picker-ok > .ant-btn > span");
|
|
115
115
|
for (let e of l)
|
|
116
116
|
e && (e.innerText = "OK");
|
|
117
117
|
});
|
|
118
|
-
}, re = () => {
|
|
119
|
-
s.value = h(), c.value = k(), s.value === c.value || c.value - s.value < 1 ? b.value = !1 : (b.value = !0, A.value && clearTimeout(A.value)), C.value = !0;
|
|
120
118
|
}, te = () => {
|
|
121
|
-
|
|
119
|
+
f.value = a(), g.value = k(), f.value === g.value || g.value - f.value < 1 ? b.value = !1 : (b.value = !0, J.value && clearTimeout(J.value)), $.value = !0;
|
|
120
|
+
}, le = () => {
|
|
121
|
+
J.value = setTimeout(() => {
|
|
122
122
|
b.value = !1;
|
|
123
|
-
}, 200),
|
|
124
|
-
},
|
|
125
|
-
r ?
|
|
123
|
+
}, 200), $.value = !1;
|
|
124
|
+
}, ae = (r, l) => {
|
|
125
|
+
r ? te() : le();
|
|
126
126
|
}, oe = (r, l) => {
|
|
127
127
|
M.value = !1, m("update:error", M.value), m("update:model-value", r), m("change", r, l);
|
|
128
128
|
};
|
|
129
|
-
return
|
|
130
|
-
$datePicker:
|
|
129
|
+
return K({
|
|
130
|
+
$datePicker: i,
|
|
131
131
|
blur: () => {
|
|
132
|
-
|
|
132
|
+
i.value.blur();
|
|
133
133
|
},
|
|
134
134
|
focus: () => {
|
|
135
|
-
|
|
135
|
+
i.value.focus();
|
|
136
136
|
}
|
|
137
|
-
}), (r, l) => (
|
|
138
|
-
class: be(["das-ui-date-picker", [r.borderType, t.isView ? "readonly" : "",
|
|
139
|
-
style:
|
|
137
|
+
}), (r, l) => (v(), T("div", {
|
|
138
|
+
class: be(["das-ui-date-picker", [r.borderType, t.isView ? "readonly" : "", o(M) ? "is-error" : ""]]),
|
|
139
|
+
style: Y(E.value)
|
|
140
140
|
}, [
|
|
141
|
-
I(
|
|
142
|
-
default:
|
|
143
|
-
I(
|
|
141
|
+
I(o(Te), { locale: x.value }, {
|
|
142
|
+
default: c(() => [
|
|
143
|
+
I(o(Ie), {
|
|
144
144
|
ref_key: "inputTooltipRef",
|
|
145
|
-
ref:
|
|
145
|
+
ref: R,
|
|
146
146
|
placement: "top",
|
|
147
147
|
trigger: "hover",
|
|
148
148
|
visible: b.value,
|
|
149
149
|
disabled: !r.isTooltip,
|
|
150
|
-
content:
|
|
150
|
+
content: q.value
|
|
151
151
|
}, {
|
|
152
|
-
default:
|
|
153
|
-
|
|
152
|
+
default: c(() => [
|
|
153
|
+
fe((v(), j(o(Ne), ne({
|
|
154
|
+
key: y.value,
|
|
154
155
|
ref_key: "$datePicker",
|
|
155
|
-
ref:
|
|
156
|
+
ref: i
|
|
156
157
|
}, r.$attrs, {
|
|
157
|
-
value:
|
|
158
|
-
"onUpdate:value": l[0] || (l[0] = (e) =>
|
|
158
|
+
value: o(p),
|
|
159
|
+
"onUpdate:value": l[0] || (l[0] = (e) => Ce(p) ? p.value = e : null),
|
|
159
160
|
size: t.size,
|
|
160
161
|
dropdownClassName: "das-ui-date-picker-dropdown " + r.dropdownClassName,
|
|
161
|
-
placeholder:
|
|
162
|
+
placeholder: Z.value,
|
|
162
163
|
showToday: r.showToday,
|
|
163
164
|
bordered: r.borderType === "bordered",
|
|
164
165
|
disabled: t.disabled || t.isView,
|
|
165
|
-
style:
|
|
166
|
-
popupStyle:
|
|
166
|
+
style: E.value,
|
|
167
|
+
popupStyle: O.value,
|
|
167
168
|
onChange: oe,
|
|
168
169
|
onOpenChange: w
|
|
169
|
-
}),
|
|
170
|
-
dateRender:
|
|
171
|
-
|
|
172
|
-
|
|
170
|
+
}), Ee({
|
|
171
|
+
dateRender: c((e) => [
|
|
172
|
+
S(r.$slots, "dateRender", ge(we(e)), () => [
|
|
173
|
+
V("div", je, W(e.current.date()), 1)
|
|
173
174
|
], !0)
|
|
174
175
|
]),
|
|
175
|
-
nextIcon:
|
|
176
|
-
|
|
177
|
-
I(
|
|
176
|
+
nextIcon: c(() => [
|
|
177
|
+
S(r.$slots, "nextIcon", {}, () => [
|
|
178
|
+
I(o(re), {
|
|
178
179
|
icon: "right",
|
|
179
180
|
size: "medium"
|
|
180
181
|
})
|
|
181
182
|
], !0)
|
|
182
183
|
]),
|
|
183
|
-
prevIcon:
|
|
184
|
-
|
|
185
|
-
I(
|
|
184
|
+
prevIcon: c(() => [
|
|
185
|
+
S(r.$slots, "prevIcon", {}, () => [
|
|
186
|
+
I(o(re), {
|
|
186
187
|
icon: "left",
|
|
187
188
|
size: "medium"
|
|
188
189
|
})
|
|
189
190
|
], !0)
|
|
190
191
|
]),
|
|
191
|
-
superNextIcon:
|
|
192
|
-
|
|
193
|
-
I(
|
|
192
|
+
superNextIcon: c(() => [
|
|
193
|
+
S(r.$slots, "superNextIcon", {}, () => [
|
|
194
|
+
I(o(re), {
|
|
194
195
|
icon: "double-arrow-right",
|
|
195
196
|
size: "medium"
|
|
196
197
|
})
|
|
197
198
|
], !0)
|
|
198
199
|
]),
|
|
199
|
-
superPrevIcon:
|
|
200
|
-
|
|
201
|
-
I(
|
|
200
|
+
superPrevIcon: c(() => [
|
|
201
|
+
S(r.$slots, "superPrevIcon", {}, () => [
|
|
202
|
+
I(o(re), {
|
|
202
203
|
icon: "double-arrow-left",
|
|
203
204
|
size: "medium"
|
|
204
205
|
})
|
|
205
206
|
], !0)
|
|
206
207
|
]),
|
|
207
|
-
suffixIcon:
|
|
208
|
-
|
|
209
|
-
I(
|
|
208
|
+
suffixIcon: c(() => [
|
|
209
|
+
S(r.$slots, "suffixIcon", {}, () => [
|
|
210
|
+
I(o(re), {
|
|
210
211
|
class: "das-suffix-icon",
|
|
211
212
|
icon: "riqixuanze",
|
|
212
213
|
size: "medium"
|
|
@@ -217,13 +218,13 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
217
218
|
}, [
|
|
218
219
|
r.$slots.renderExtraFooter ? {
|
|
219
220
|
name: "renderExtraFooter",
|
|
220
|
-
fn:
|
|
221
|
-
|
|
221
|
+
fn: c(() => [
|
|
222
|
+
S(r.$slots, "renderExtraFooter", {}, void 0, !0)
|
|
222
223
|
]),
|
|
223
224
|
key: "0"
|
|
224
225
|
} : void 0
|
|
225
226
|
]), 1040, ["value", "size", "dropdownClassName", "placeholder", "showToday", "bordered", "disabled", "style", "popupStyle"])), [
|
|
226
|
-
[
|
|
227
|
+
[o(he), ae]
|
|
227
228
|
])
|
|
228
229
|
]),
|
|
229
230
|
_: 3
|
|
@@ -231,36 +232,36 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
231
232
|
]),
|
|
232
233
|
_: 3
|
|
233
234
|
}, 8, ["locale"]),
|
|
234
|
-
r.error && r.errorLabel ? (
|
|
235
|
-
r.errorMode === "default" ? (
|
|
236
|
-
|
|
237
|
-
style:
|
|
238
|
-
},
|
|
239
|
-
])) :
|
|
240
|
-
r.errorMode === "overlay" &&
|
|
235
|
+
r.error && r.errorLabel ? (v(), T(ue, { key: 0 }, [
|
|
236
|
+
r.errorMode === "default" ? (v(), T("div", Ye, [
|
|
237
|
+
V("span", {
|
|
238
|
+
style: Y(U.value)
|
|
239
|
+
}, W(r.errorLabel), 5)
|
|
240
|
+
])) : P("", !0),
|
|
241
|
+
r.errorMode === "overlay" && $.value ? (v(), j(o(me), {
|
|
241
242
|
key: 1,
|
|
242
243
|
errorLabel: r.errorLabel,
|
|
243
244
|
getEl: () => {
|
|
244
245
|
var e;
|
|
245
|
-
return (e =
|
|
246
|
+
return (e = i.value) == null ? void 0 : e.$el;
|
|
246
247
|
},
|
|
247
248
|
errorModelZIndex: r.errorModelZIndex
|
|
248
|
-
}, null, 8, ["errorLabel", "getEl", "errorModelZIndex"])) :
|
|
249
|
-
], 64)) :
|
|
249
|
+
}, null, 8, ["errorLabel", "getEl", "errorModelZIndex"])) : P("", !0)
|
|
250
|
+
], 64)) : P("", !0)
|
|
250
251
|
], 6));
|
|
251
252
|
}
|
|
252
|
-
}),
|
|
253
|
-
const n =
|
|
254
|
-
for (const [t, m] of
|
|
253
|
+
}), ke = (F, K) => {
|
|
254
|
+
const n = F.__vccOpts || F;
|
|
255
|
+
for (const [t, m] of K)
|
|
255
256
|
n[t] = m;
|
|
256
257
|
return n;
|
|
257
|
-
},
|
|
258
|
+
}, Je = /* @__PURE__ */ ke(Ge, [["__scopeId", "data-v-e031e2c7"]]), Qe = { class: "date-range-separator" }, er = {
|
|
258
259
|
key: 0,
|
|
259
260
|
class: "das-date-picker-error-label-content"
|
|
260
|
-
},
|
|
261
|
+
}, rr = {
|
|
261
262
|
name: "DasDateRangePicker"
|
|
262
|
-
},
|
|
263
|
-
...
|
|
263
|
+
}, tr = /* @__PURE__ */ ce({
|
|
264
|
+
...rr,
|
|
264
265
|
props: {
|
|
265
266
|
modelValue: {},
|
|
266
267
|
borderType: { default: "bordered" },
|
|
@@ -286,111 +287,109 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
286
287
|
formSize: {}
|
|
287
288
|
},
|
|
288
289
|
emits: ["change", "openChange", "update:model-value", "update:error"],
|
|
289
|
-
setup(
|
|
290
|
-
|
|
291
|
-
"
|
|
292
|
-
|
|
290
|
+
setup(F, { emit: K }) {
|
|
291
|
+
ve((a) => ({
|
|
292
|
+
"2de89ca4": p.value,
|
|
293
|
+
"02503ea9": R.value
|
|
293
294
|
}));
|
|
294
|
-
const n =
|
|
295
|
+
const n = F, t = K, m = Be(), x = s(() => n.placeholder ?? [se("开始日期"), se("结束日期")]), y = X(n, "modelValue"), i = X(n, "error"), R = s(() => n.width ? n.width : "230px"), p = s(() => n.height ? n.height : "auto"), M = s(() => ({ ...m, ...n.prevAttrs })), Z = s(() => ({ ...m, ...n.nextAttrs })), E = u(), H = u(!1), N = u({
|
|
295
296
|
display: "block",
|
|
296
|
-
color:
|
|
297
|
+
color: ye("--das-ui-date-picker-overlay-error-color").value,
|
|
297
298
|
"white-space": "break-spaces"
|
|
298
|
-
}),
|
|
299
|
-
|
|
300
|
-
},
|
|
301
|
-
|
|
302
|
-
},
|
|
303
|
-
|
|
304
|
-
},
|
|
305
|
-
t("openChange",
|
|
299
|
+
}), A = () => {
|
|
300
|
+
H.value = !0;
|
|
301
|
+
}, B = () => {
|
|
302
|
+
H.value = !1;
|
|
303
|
+
}, O = (a, f) => {
|
|
304
|
+
a ? A() : B();
|
|
305
|
+
}, $ = (a, f) => {
|
|
306
|
+
t("openChange", a, f), D.value === "en" && ee(() => {
|
|
306
307
|
const g = document == null ? void 0 : document.querySelectorAll(".ant-picker-ok > .ant-btn > span");
|
|
307
|
-
for (let
|
|
308
|
-
|
|
308
|
+
for (let L of g)
|
|
309
|
+
L && (L.innerText = "OK");
|
|
309
310
|
});
|
|
310
|
-
},
|
|
311
|
-
let
|
|
311
|
+
}, U = s(() => {
|
|
312
|
+
let a = n.valueFormat ? n.valueFormat : n.format;
|
|
312
313
|
return [
|
|
313
|
-
|
|
314
|
-
|
|
314
|
+
y.value[0] ? Ve.isDayjs(y.value[0]) ? y.value[0].format(a) : y.value[0] : "",
|
|
315
|
+
y.value[1] ? Ve.isDayjs(y.value[1]) ? y.value[1].format(a) : y.value[1] : ""
|
|
315
316
|
];
|
|
316
|
-
}),
|
|
317
|
+
}), b = (a) => n.disabledDate && n.disabledDate(a) === !0 ? !0 : !!(y.value[1] && a.isAfter(y.value[1], n.disabledUnit || void 0)), C = (a) => n.disabledDate && n.disabledDate(a) === !0 ? !0 : !!(y.value[0] && a.isBefore(y.value[0], n.disabledUnit || void 0)), q = s(() => ({
|
|
317
318
|
width: n.width
|
|
318
|
-
})),
|
|
319
|
-
|
|
320
|
-
},
|
|
321
|
-
|
|
319
|
+
})), G = (a, f) => {
|
|
320
|
+
i.value = !1, t("update:model-value", y.value), t("change", y.value, U.value);
|
|
321
|
+
}, k = (a, f) => {
|
|
322
|
+
i.value = !1, t("update:model-value", y.value), t("change", y.value, U.value);
|
|
322
323
|
};
|
|
323
|
-
return (
|
|
324
|
+
return (a, f) => fe((v(), T("div", {
|
|
324
325
|
class: "das-ui-date-range-picker",
|
|
325
|
-
style:
|
|
326
|
+
style: Y(q.value),
|
|
326
327
|
ref_key: "$dateRange",
|
|
327
|
-
ref:
|
|
328
|
+
ref: E
|
|
328
329
|
}, [
|
|
329
|
-
I(
|
|
330
|
-
modelValue:
|
|
331
|
-
"onUpdate:modelValue":
|
|
332
|
-
format: n.format,
|
|
330
|
+
I(o(Pe), ne(M.value, {
|
|
331
|
+
modelValue: o(y)[0],
|
|
332
|
+
"onUpdate:modelValue": f[0] || (f[0] = (g) => o(y)[0] = g),
|
|
333
333
|
size: n.size,
|
|
334
334
|
valueFormat: n.valueFormat,
|
|
335
335
|
borderType: n.borderType,
|
|
336
|
-
error:
|
|
336
|
+
error: o(i),
|
|
337
337
|
width: n.itemWidth,
|
|
338
|
-
"disabled-date":
|
|
339
|
-
placeholder:
|
|
340
|
-
onChange:
|
|
341
|
-
onOpenChange:
|
|
342
|
-
}), null, 16, ["modelValue", "
|
|
343
|
-
|
|
344
|
-
|
|
338
|
+
"disabled-date": b,
|
|
339
|
+
placeholder: x.value[0],
|
|
340
|
+
onChange: G,
|
|
341
|
+
onOpenChange: f[1] || (f[1] = (g) => $(g, "before"))
|
|
342
|
+
}), null, 16, ["modelValue", "size", "valueFormat", "borderType", "error", "width", "placeholder"]),
|
|
343
|
+
S(a.$slots, "separator", {}, () => [
|
|
344
|
+
V("span", Qe, W(n.separator), 1)
|
|
345
345
|
], !0),
|
|
346
|
-
I(
|
|
347
|
-
modelValue:
|
|
348
|
-
"onUpdate:modelValue":
|
|
349
|
-
format: n.format,
|
|
346
|
+
I(o(Pe), ne(Z.value, {
|
|
347
|
+
modelValue: o(y)[1],
|
|
348
|
+
"onUpdate:modelValue": f[2] || (f[2] = (g) => o(y)[1] = g),
|
|
350
349
|
size: n.size,
|
|
351
350
|
valueFormat: n.valueFormat,
|
|
352
351
|
borderType: n.borderType,
|
|
353
|
-
error:
|
|
352
|
+
error: o(i),
|
|
354
353
|
width: n.itemWidth,
|
|
355
|
-
"disabled-date":
|
|
356
|
-
placeholder:
|
|
357
|
-
onChange:
|
|
358
|
-
onOpenChange:
|
|
359
|
-
}), null, 16, ["modelValue", "
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
style:
|
|
364
|
-
},
|
|
365
|
-
])) :
|
|
366
|
-
|
|
354
|
+
"disabled-date": C,
|
|
355
|
+
placeholder: x.value[1],
|
|
356
|
+
onChange: k,
|
|
357
|
+
onOpenChange: f[3] || (f[3] = (g) => $(g, "after"))
|
|
358
|
+
}), null, 16, ["modelValue", "size", "valueFormat", "borderType", "error", "width", "placeholder"]),
|
|
359
|
+
a.error && a.errorLabel ? (v(), T(ue, { key: 0 }, [
|
|
360
|
+
a.errorMode === "default" ? (v(), T("div", er, [
|
|
361
|
+
V("span", {
|
|
362
|
+
style: Y(N.value)
|
|
363
|
+
}, W(a.errorLabel), 5)
|
|
364
|
+
])) : P("", !0),
|
|
365
|
+
a.errorMode === "overlay" && H.value ? (v(), j(o(me), {
|
|
367
366
|
key: 1,
|
|
368
|
-
errorLabel:
|
|
369
|
-
getEl: () =>
|
|
370
|
-
errorModelZIndex:
|
|
371
|
-
}, null, 8, ["errorLabel", "getEl", "errorModelZIndex"])) :
|
|
372
|
-
], 64)) :
|
|
367
|
+
errorLabel: a.errorLabel,
|
|
368
|
+
getEl: () => E.value,
|
|
369
|
+
errorModelZIndex: a.errorModelZIndex
|
|
370
|
+
}, null, 8, ["errorLabel", "getEl", "errorModelZIndex"])) : P("", !0)
|
|
371
|
+
], 64)) : P("", !0)
|
|
373
372
|
], 4)), [
|
|
374
|
-
[
|
|
373
|
+
[o(he), O]
|
|
375
374
|
]);
|
|
376
375
|
}
|
|
377
|
-
}),
|
|
376
|
+
}), lr = /* @__PURE__ */ ke(tr, [["__scopeId", "data-v-1dbd058e"]]), ar = { class: "ant-picker-cell-inner" }, or = { class: "das-picker-footer-extra" }, ur = {
|
|
378
377
|
key: 0,
|
|
379
378
|
class: "das-picker-ranges"
|
|
380
|
-
},
|
|
379
|
+
}, nr = { class: "das-picker-preset-span" }, sr = ["onClick"], ir = {
|
|
381
380
|
key: 0,
|
|
382
381
|
class: "das-date-picker-error-label-content"
|
|
383
|
-
},
|
|
382
|
+
}, dr = {
|
|
384
383
|
name: "DasRangePicker"
|
|
385
|
-
},
|
|
386
|
-
...
|
|
384
|
+
}, pr = /* @__PURE__ */ ce({
|
|
385
|
+
...dr,
|
|
387
386
|
props: {
|
|
388
387
|
modelValue: {},
|
|
389
388
|
borderType: { default: "bordered" },
|
|
390
389
|
size: { default: "middle" },
|
|
391
390
|
width: { default: "230px" },
|
|
392
391
|
height: {},
|
|
393
|
-
format: {
|
|
392
|
+
format: {},
|
|
394
393
|
showToday: { type: Boolean, default: !1 },
|
|
395
394
|
ranges: { default: [] },
|
|
396
395
|
disabled: { type: Boolean, default: !1 },
|
|
@@ -408,71 +407,71 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
408
407
|
formSize: {}
|
|
409
408
|
},
|
|
410
409
|
emits: ["change", "openChange", "update:model-value", "update:error"],
|
|
411
|
-
setup(
|
|
412
|
-
|
|
413
|
-
"
|
|
414
|
-
|
|
410
|
+
setup(F, { expose: K, emit: n }) {
|
|
411
|
+
ve((e) => ({
|
|
412
|
+
"7adff262": Z.value,
|
|
413
|
+
"75a1d93e": H.value
|
|
415
414
|
}));
|
|
416
|
-
const t =
|
|
417
|
-
|
|
415
|
+
const t = F, m = n;
|
|
416
|
+
Me({
|
|
418
417
|
fold: import("@das-fed/upf-ui/packages/icons/fold"),
|
|
419
418
|
riqixuanze: import("@das-fed/upf-ui/packages/icons/riqixuanze")
|
|
420
419
|
});
|
|
421
|
-
const
|
|
422
|
-
|
|
423
|
-
|
|
420
|
+
const x = u(void 0);
|
|
421
|
+
_(D, async () => {
|
|
422
|
+
x.value = await $e(D.value);
|
|
424
423
|
}, { immediate: !0 });
|
|
425
|
-
const
|
|
424
|
+
const y = s(() => `range-picker-${D.value}`), i = u(null), R = u(null), p = X(t, "modelValue"), M = X(t, "error"), Z = s(() => t.width ? t.width : "230px"), E = s(() => t.formSize), H = s(() => t.height ? t.height : E.value ? {
|
|
426
425
|
small: "24px",
|
|
427
426
|
default: "32px",
|
|
428
427
|
large: "40px"
|
|
429
|
-
}[
|
|
430
|
-
"z-index":
|
|
431
|
-
})),
|
|
428
|
+
}[E.value] : "auto"), N = u(3e3), A = s(() => ({
|
|
429
|
+
"z-index": N.value
|
|
430
|
+
})), B = u(!1), O = u({
|
|
432
431
|
display: "block",
|
|
433
|
-
color:
|
|
432
|
+
color: ye("--das-ui-date-picker-overlay-error-color").value,
|
|
434
433
|
"white-space": "break-spaces"
|
|
435
|
-
}),
|
|
434
|
+
}), $ = s(() => {
|
|
436
435
|
var e;
|
|
437
|
-
return t.isView ? t.noSetDefaultVal ? ["", ""] : ["-", "-"] : (e = t.placeholder) == null ? void 0 : e.map((d) =>
|
|
438
|
-
}),
|
|
436
|
+
return t.isView ? t.noSetDefaultVal ? ["", ""] : ["-", "-"] : (e = t.placeholder) == null ? void 0 : e.map((d) => se(d));
|
|
437
|
+
}), U = s(() => ({
|
|
439
438
|
width: t.width
|
|
440
|
-
})), b = u(!1),
|
|
439
|
+
})), b = u(!1), C = u(["", ""]), q = u("~"), G = s(() => {
|
|
441
440
|
var e;
|
|
442
|
-
return (e = p.value) != null && e.length && p.value[0] && p.value[1] ?
|
|
443
|
-
}), k = u([0, 0]),
|
|
444
|
-
var
|
|
441
|
+
return (e = p.value) != null && e.length && p.value[0] && p.value[1] ? C.value.join(" " + q.value + " ") : $.value.join(" " + q.value + " ");
|
|
442
|
+
}), k = u([0, 0]), a = u([0, 0]), f = () => {
|
|
443
|
+
var z;
|
|
445
444
|
let e = [];
|
|
446
|
-
const d = (
|
|
445
|
+
const d = (z = i.value) == null ? void 0 : z.$el.querySelectorAll(".ant-picker-input>input");
|
|
447
446
|
if (!d)
|
|
448
447
|
return e = [0, 0], e;
|
|
449
|
-
let
|
|
450
|
-
for (let
|
|
451
|
-
|
|
452
|
-
let
|
|
453
|
-
e.push(
|
|
448
|
+
let h = [];
|
|
449
|
+
for (let Q of d) {
|
|
450
|
+
h.push(Q.getAttribute("value") || "");
|
|
451
|
+
let xe = (Q == null ? void 0 : Q.offsetWidth) ?? 0;
|
|
452
|
+
e.push(xe);
|
|
454
453
|
}
|
|
455
|
-
return
|
|
456
|
-
},
|
|
454
|
+
return C.value = h, e;
|
|
455
|
+
}, g = (e) => {
|
|
457
456
|
const d = t.size === "table" ? 12 : 14;
|
|
458
457
|
return ze(e, d);
|
|
459
|
-
},
|
|
460
|
-
var
|
|
458
|
+
}, L = () => {
|
|
459
|
+
var h;
|
|
461
460
|
let e = [];
|
|
462
|
-
return ((
|
|
463
|
-
p.value.length && p.value[0] && p.value[0] ? e.push(
|
|
461
|
+
return ((h = i.value) == null ? void 0 : h.$el.querySelectorAll(".ant-picker-input>input")).forEach((z, Q) => {
|
|
462
|
+
p.value.length && p.value[0] && p.value[0] ? e.push(z == null ? void 0 : z.scrollWidth) : e.push(g($.value[Q]));
|
|
464
463
|
}), e;
|
|
465
464
|
};
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
k.value =
|
|
465
|
+
_(() => [$.value, p.value], () => {
|
|
466
|
+
ee(() => {
|
|
467
|
+
k.value = f(), a.value = L(), (k.value[0] === a.value[0] || a.value[0] - k.value[0] < 1) && (k.value[1] === a.value[1] || a.value[1] - k.value[1] < 1) && (b.value = !1);
|
|
469
468
|
});
|
|
470
469
|
});
|
|
471
470
|
const w = u();
|
|
472
|
-
|
|
471
|
+
_(
|
|
473
472
|
() => {
|
|
474
473
|
var e;
|
|
475
|
-
return (e =
|
|
474
|
+
return (e = R.value) == null ? void 0 : e.$tooltipRef.popperRef.contentRef;
|
|
476
475
|
},
|
|
477
476
|
(e) => {
|
|
478
477
|
e && (e.addEventListener("mouseenter", function() {
|
|
@@ -484,124 +483,124 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
484
483
|
}));
|
|
485
484
|
}
|
|
486
485
|
);
|
|
487
|
-
const
|
|
488
|
-
e && (
|
|
486
|
+
const te = (e) => {
|
|
487
|
+
e && (N.value = Se().nextZIndex()), m("openChange", e), D.value === "en" && ee(() => {
|
|
489
488
|
const d = document == null ? void 0 : document.querySelectorAll(".ant-picker-ok > .ant-btn > span");
|
|
490
|
-
for (let
|
|
491
|
-
|
|
489
|
+
for (let h of d)
|
|
490
|
+
h && (h.innerText = "OK");
|
|
492
491
|
});
|
|
493
|
-
}, te = () => {
|
|
494
|
-
k.value = s(), h.value = g(), (k.value[0] === h.value[0] || h.value[0] - k.value[0] < 1) && (k.value[1] === h.value[1] || h.value[1] - k.value[1] < 1) ? b.value = !1 : (b.value = !0, w.value && clearTimeout(w.value)), P.value = !0;
|
|
495
492
|
}, le = () => {
|
|
493
|
+
k.value = f(), a.value = L(), (k.value[0] === a.value[0] || a.value[0] - k.value[0] < 1) && (k.value[1] === a.value[1] || a.value[1] - k.value[1] < 1) ? b.value = !1 : (b.value = !0, w.value && clearTimeout(w.value)), B.value = !0;
|
|
494
|
+
}, ae = () => {
|
|
496
495
|
w.value = setTimeout(() => {
|
|
497
496
|
b.value = !1;
|
|
498
|
-
}, 200),
|
|
497
|
+
}, 200), B.value = !1;
|
|
499
498
|
}, oe = (e, d) => {
|
|
500
|
-
e ?
|
|
501
|
-
},
|
|
499
|
+
e ? le() : ae();
|
|
500
|
+
}, ie = (e, d) => {
|
|
502
501
|
if (M.value = !1, e === null) {
|
|
503
502
|
m("update:model-value", [null, null]), m("change", [null, null], d);
|
|
504
503
|
return;
|
|
505
504
|
}
|
|
506
505
|
m("update:error", M.value), m("update:model-value", e), m("change", e, d);
|
|
507
|
-
},
|
|
508
|
-
m("update:model-value", e.value), m("change", e.value, [e.value[0].format(t.format), e.value[1].format(t.format)]),
|
|
506
|
+
}, de = (e) => {
|
|
507
|
+
m("update:model-value", e.value), m("change", e.value, [e.value[0].format(t.format), e.value[1].format(t.format)]), i.value.blur();
|
|
509
508
|
};
|
|
510
|
-
return
|
|
511
|
-
$rangePicker:
|
|
509
|
+
return K({
|
|
510
|
+
$rangePicker: i,
|
|
512
511
|
blur: () => {
|
|
513
|
-
|
|
512
|
+
i.value.blur();
|
|
514
513
|
},
|
|
515
514
|
focus: () => {
|
|
516
|
-
|
|
515
|
+
i.value.focus();
|
|
517
516
|
}
|
|
518
|
-
}), (e, d) => (
|
|
519
|
-
class: be(["das-ui-range-picker", [e.borderType, t.isView ? "readonly" : "",
|
|
520
|
-
style:
|
|
517
|
+
}), (e, d) => (v(), T("div", {
|
|
518
|
+
class: be(["das-ui-range-picker", [e.borderType, t.isView ? "readonly" : "", o(M) ? "is-error" : ""]]),
|
|
519
|
+
style: Y(U.value)
|
|
521
520
|
}, [
|
|
522
|
-
I(
|
|
523
|
-
default:
|
|
524
|
-
I(
|
|
521
|
+
I(o(Te), { locale: x.value }, {
|
|
522
|
+
default: c(() => [
|
|
523
|
+
I(o(Ie), {
|
|
525
524
|
ref_key: "inputTooltipRef",
|
|
526
|
-
ref:
|
|
525
|
+
ref: R,
|
|
527
526
|
placement: "top",
|
|
528
527
|
trigger: "hover",
|
|
529
528
|
visible: b.value,
|
|
530
529
|
disabled: !e.isTooltip,
|
|
531
|
-
content:
|
|
530
|
+
content: G.value
|
|
532
531
|
}, {
|
|
533
|
-
default:
|
|
534
|
-
|
|
532
|
+
default: c(() => [
|
|
533
|
+
fe((v(), j(o(We), ne({
|
|
534
|
+
key: y.value,
|
|
535
535
|
ref_key: "$rangePicker",
|
|
536
|
-
ref:
|
|
536
|
+
ref: i
|
|
537
537
|
}, e.$attrs, {
|
|
538
|
-
value:
|
|
539
|
-
format: e.format,
|
|
538
|
+
value: o(p),
|
|
540
539
|
size: t.size,
|
|
541
540
|
dropdownClassName: "das-ui-range-picker-dropdown " + e.dropdownClassName,
|
|
542
|
-
placeholder:
|
|
541
|
+
placeholder: $.value,
|
|
543
542
|
showToday: e.showToday,
|
|
544
543
|
showTime: e.showTime,
|
|
545
544
|
bordered: e.borderType === "bordered",
|
|
546
545
|
disabled: t.disabled || t.isView,
|
|
547
|
-
style:
|
|
548
|
-
popupStyle:
|
|
549
|
-
onChange:
|
|
550
|
-
onOpenChange:
|
|
546
|
+
style: U.value,
|
|
547
|
+
popupStyle: A.value,
|
|
548
|
+
onChange: ie,
|
|
549
|
+
onOpenChange: te
|
|
551
550
|
}), {
|
|
552
|
-
dateRender:
|
|
553
|
-
|
|
554
|
-
|
|
551
|
+
dateRender: c((h) => [
|
|
552
|
+
S(e.$slots, "dateRender", ge(we(h)), () => [
|
|
553
|
+
V("div", ar, W(h.current.date()), 1)
|
|
555
554
|
], !0)
|
|
556
555
|
]),
|
|
557
|
-
nextIcon:
|
|
556
|
+
nextIcon: c(() => d[1] || (d[1] = [
|
|
558
557
|
De(" XX ")
|
|
559
558
|
])),
|
|
560
|
-
prevIcon:
|
|
561
|
-
|
|
559
|
+
prevIcon: c(() => [
|
|
560
|
+
S(e.$slots, "prevIcon", {}, void 0, !0)
|
|
562
561
|
]),
|
|
563
|
-
superNextIcon:
|
|
564
|
-
|
|
562
|
+
superNextIcon: c(() => [
|
|
563
|
+
S(e.$slots, "superNextIcon", {}, void 0, !0)
|
|
565
564
|
]),
|
|
566
|
-
superPrevIcon:
|
|
567
|
-
|
|
565
|
+
superPrevIcon: c(() => [
|
|
566
|
+
S(e.$slots, "superPrevIcon", {}, void 0, !0)
|
|
568
567
|
]),
|
|
569
|
-
suffixIcon:
|
|
570
|
-
|
|
571
|
-
I(
|
|
568
|
+
suffixIcon: c(() => [
|
|
569
|
+
S(e.$slots, "suffixIcon", {}, () => [
|
|
570
|
+
I(o(re), {
|
|
572
571
|
class: "das-suffix-icon",
|
|
573
572
|
icon: "riqixuanze",
|
|
574
573
|
size: "medium"
|
|
575
574
|
})
|
|
576
575
|
], !0)
|
|
577
576
|
]),
|
|
578
|
-
separator:
|
|
579
|
-
|
|
580
|
-
d[2] || (d[2] =
|
|
577
|
+
separator: c(() => [
|
|
578
|
+
S(e.$slots, "separator", {}, () => [
|
|
579
|
+
d[2] || (d[2] = V("div", { style: { padding: "0 8px" } }, "~", -1))
|
|
581
580
|
], !0)
|
|
582
581
|
]),
|
|
583
|
-
renderExtraFooter:
|
|
584
|
-
|
|
585
|
-
|
|
582
|
+
renderExtraFooter: c(() => [
|
|
583
|
+
V("div", or, [
|
|
584
|
+
S(e.$slots, "renderExtraFooter", {}, void 0, !0)
|
|
586
585
|
]),
|
|
587
|
-
e.showTime || e.ranges && e.ranges.length ? (
|
|
588
|
-
(
|
|
586
|
+
e.showTime || e.ranges && e.ranges.length ? (v(), T("div", ur, [
|
|
587
|
+
(v(!0), T(ue, null, Le(e.ranges, (h) => (v(), T("div", {
|
|
589
588
|
class: "das-picker-preset",
|
|
590
|
-
key:
|
|
589
|
+
key: h.key
|
|
591
590
|
}, [
|
|
592
|
-
|
|
591
|
+
h.type === "dropdown" && h.children.length ? (v(), j(o(Fe), {
|
|
593
592
|
key: 0,
|
|
594
593
|
trigger: ["click"]
|
|
595
594
|
}, {
|
|
596
|
-
overlay:
|
|
597
|
-
I(
|
|
598
|
-
default:
|
|
599
|
-
(
|
|
600
|
-
key:
|
|
601
|
-
onClick: (
|
|
595
|
+
overlay: c(() => [
|
|
596
|
+
I(o(Ze), null, {
|
|
597
|
+
default: c(() => [
|
|
598
|
+
(v(!0), T(ue, null, Le(h.children, (z) => (v(), j(o(Ae), {
|
|
599
|
+
key: z.key,
|
|
600
|
+
onClick: (Q) => de(z)
|
|
602
601
|
}, {
|
|
603
|
-
default:
|
|
604
|
-
(
|
|
602
|
+
default: c(() => [
|
|
603
|
+
(v(), T("span", { key: z }, W(z.key), 1))
|
|
605
604
|
]),
|
|
606
605
|
_: 2
|
|
607
606
|
}, 1032, ["onClick"]))), 128))
|
|
@@ -609,15 +608,15 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
609
608
|
_: 2
|
|
610
609
|
}, 1024)
|
|
611
610
|
]),
|
|
612
|
-
default:
|
|
613
|
-
|
|
611
|
+
default: c(() => [
|
|
612
|
+
V("a", {
|
|
614
613
|
class: "ant-dropdown-link",
|
|
615
614
|
onClick: d[0] || (d[0] = Re(() => {
|
|
616
615
|
}, ["prevent"]))
|
|
617
616
|
}, [
|
|
618
|
-
|
|
619
|
-
De(
|
|
620
|
-
I(
|
|
617
|
+
V("span", nr, [
|
|
618
|
+
De(W(h.key) + " ", 1),
|
|
619
|
+
I(o(re), {
|
|
621
620
|
icon: "fold",
|
|
622
621
|
size: "mini",
|
|
623
622
|
style: { display: "inline-block" }
|
|
@@ -626,17 +625,17 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
626
625
|
])
|
|
627
626
|
]),
|
|
628
627
|
_: 2
|
|
629
|
-
}, 1024)) : (
|
|
628
|
+
}, 1024)) : (v(), T("span", {
|
|
630
629
|
key: 1,
|
|
631
630
|
class: "das-picker-preset-span",
|
|
632
|
-
onClick: (
|
|
633
|
-
},
|
|
631
|
+
onClick: (z) => de(h)
|
|
632
|
+
}, W(h.key), 9, sr))
|
|
634
633
|
]))), 128))
|
|
635
|
-
])) :
|
|
634
|
+
])) : P("", !0)
|
|
636
635
|
]),
|
|
637
636
|
_: 3
|
|
638
|
-
}, 16, ["value", "
|
|
639
|
-
[
|
|
637
|
+
}, 16, ["value", "size", "dropdownClassName", "placeholder", "showToday", "showTime", "bordered", "disabled", "style", "popupStyle"])), [
|
|
638
|
+
[o(he), oe]
|
|
640
639
|
])
|
|
641
640
|
]),
|
|
642
641
|
_: 3
|
|
@@ -644,31 +643,31 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
644
643
|
]),
|
|
645
644
|
_: 3
|
|
646
645
|
}, 8, ["locale"]),
|
|
647
|
-
e.error && e.errorLabel ? (
|
|
648
|
-
e.errorMode === "default" ? (
|
|
649
|
-
|
|
650
|
-
style:
|
|
651
|
-
},
|
|
652
|
-
])) :
|
|
653
|
-
e.errorMode === "overlay" &&
|
|
646
|
+
e.error && e.errorLabel ? (v(), T(ue, { key: 0 }, [
|
|
647
|
+
e.errorMode === "default" ? (v(), T("div", ir, [
|
|
648
|
+
V("span", {
|
|
649
|
+
style: Y(O.value)
|
|
650
|
+
}, W(e.errorLabel), 5)
|
|
651
|
+
])) : P("", !0),
|
|
652
|
+
e.errorMode === "overlay" && B.value ? (v(), j(o(me), {
|
|
654
653
|
key: 1,
|
|
655
654
|
errorLabel: e.errorLabel,
|
|
656
655
|
getEl: () => {
|
|
657
|
-
var
|
|
658
|
-
return (
|
|
656
|
+
var h;
|
|
657
|
+
return (h = i.value) == null ? void 0 : h.$el;
|
|
659
658
|
},
|
|
660
659
|
errorModelZIndex: e.errorModelZIndex
|
|
661
|
-
}, null, 8, ["errorLabel", "getEl", "errorModelZIndex"])) :
|
|
662
|
-
], 64)) :
|
|
660
|
+
}, null, 8, ["errorLabel", "getEl", "errorModelZIndex"])) : P("", !0)
|
|
661
|
+
], 64)) : P("", !0)
|
|
663
662
|
], 6));
|
|
664
663
|
}
|
|
665
|
-
}),
|
|
664
|
+
}), cr = /* @__PURE__ */ ke(pr, [["__scopeId", "data-v-34df9634"]]), vr = { class: "ant-picker-cell-inner" }, fr = {
|
|
666
665
|
key: 0,
|
|
667
666
|
class: "das-date-picker-error-label-content"
|
|
668
|
-
},
|
|
667
|
+
}, mr = {
|
|
669
668
|
name: "DasDatePicker"
|
|
670
|
-
},
|
|
671
|
-
...
|
|
669
|
+
}, hr = /* @__PURE__ */ ce({
|
|
670
|
+
...mr,
|
|
672
671
|
props: {
|
|
673
672
|
modelValue: {},
|
|
674
673
|
borderType: { default: "bordered" },
|
|
@@ -690,122 +689,127 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
690
689
|
formSize: {}
|
|
691
690
|
},
|
|
692
691
|
emits: ["change", "openChange", "update:model-value", "update:error"],
|
|
693
|
-
setup(
|
|
694
|
-
|
|
695
|
-
"
|
|
696
|
-
"
|
|
692
|
+
setup(F, { expose: K, emit: n }) {
|
|
693
|
+
ve((r) => ({
|
|
694
|
+
"69b24650": Z.value,
|
|
695
|
+
"9a70ec46": H.value
|
|
697
696
|
}));
|
|
698
|
-
const t =
|
|
697
|
+
const t = F, m = n, x = u(void 0);
|
|
698
|
+
_(D, async () => {
|
|
699
|
+
x.value = await $e(D.value);
|
|
700
|
+
}, { immediate: !0 });
|
|
701
|
+
const y = s(() => `time-picker-${D.value}`), i = u(null), R = u(null), p = X(t, "modelValue"), M = X(t, "error"), Z = s(() => t.width ? t.width : "230px"), E = s(() => t.formSize), H = s(() => t.height ? t.height : E.value ? {
|
|
699
702
|
small: "24px",
|
|
700
703
|
default: "32px",
|
|
701
704
|
large: "40px"
|
|
702
|
-
}[
|
|
705
|
+
}[E.value] : "auto"), N = s(() => ({
|
|
703
706
|
width: t.width
|
|
704
|
-
})),
|
|
705
|
-
"z-index":
|
|
706
|
-
})),
|
|
707
|
+
})), A = s(() => t.isView ? t.noSetDefaultVal ? "" : "-" : se(t.placeholder)), B = u(3e3), O = s(() => ({
|
|
708
|
+
"z-index": B.value
|
|
709
|
+
})), $ = u(!1), U = u({
|
|
707
710
|
display: "block",
|
|
708
|
-
color:
|
|
711
|
+
color: ye("--das-ui-date-picker-overlay-error-color").value,
|
|
709
712
|
"white-space": "break-spaces"
|
|
710
713
|
}), b = (r) => {
|
|
711
|
-
r && (
|
|
714
|
+
r && (B.value = Se().nextZIndex()), m("openChange", r), D.value === "en" && ee(() => {
|
|
712
715
|
const l = document == null ? void 0 : document.querySelectorAll(".ant-picker-ok > .ant-btn > span");
|
|
713
716
|
for (let e of l)
|
|
714
717
|
e && (e.innerText = "OK");
|
|
715
718
|
});
|
|
716
|
-
},
|
|
719
|
+
}, C = u(!1), q = u(""), G = s(() => p.value ? q.value : A.value), k = () => {
|
|
717
720
|
const r = t.size === "table" ? 12 : 14;
|
|
718
|
-
return ze(
|
|
719
|
-
},
|
|
721
|
+
return ze(A.value, r);
|
|
722
|
+
}, a = () => {
|
|
720
723
|
var l;
|
|
721
|
-
const r = (l =
|
|
724
|
+
const r = (l = i.value) == null ? void 0 : l.$el.querySelector(".ant-picker-input>input");
|
|
722
725
|
return p.value ? r == null ? void 0 : r.scrollWidth : k();
|
|
723
|
-
},
|
|
726
|
+
}, f = () => {
|
|
724
727
|
var e;
|
|
725
|
-
const r = (e =
|
|
726
|
-
return r ? (
|
|
727
|
-
},
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
728
|
+
const r = (e = i.value) == null ? void 0 : e.$el.querySelector(".ant-picker-input>input");
|
|
729
|
+
return r ? (q.value = r.getAttribute("value"), r.removeAttribute("title"), (r == null ? void 0 : r.offsetWidth) ?? 0) : 0;
|
|
730
|
+
}, g = u(0), L = u(0);
|
|
731
|
+
_(() => [A.value, p.value], () => {
|
|
732
|
+
ee(() => {
|
|
733
|
+
g.value = f(), L.value = a(), (g.value === L.value || L.value - g.value < 1) && (C.value = !1);
|
|
731
734
|
});
|
|
732
735
|
});
|
|
733
736
|
const w = u();
|
|
734
|
-
|
|
737
|
+
_(
|
|
735
738
|
() => {
|
|
736
739
|
var r;
|
|
737
|
-
return (r =
|
|
740
|
+
return (r = R.value) == null ? void 0 : r.$tooltipRef.popperRef.contentRef;
|
|
738
741
|
},
|
|
739
742
|
(r) => {
|
|
740
743
|
r && (r.addEventListener("mouseenter", function() {
|
|
741
|
-
|
|
744
|
+
C.value = !0, w.value && clearTimeout(w.value);
|
|
742
745
|
}), r.addEventListener("mouseleave", function() {
|
|
743
746
|
w.value = setTimeout(() => {
|
|
744
|
-
|
|
747
|
+
C.value = !1;
|
|
745
748
|
}, 200);
|
|
746
749
|
}));
|
|
747
750
|
}
|
|
748
751
|
);
|
|
749
|
-
const
|
|
750
|
-
|
|
751
|
-
},
|
|
752
|
+
const te = () => {
|
|
753
|
+
g.value = f(), L.value = a(), g.value === L.value || L.value - g.value < 1 ? C.value = !1 : (C.value = !0, w.value && clearTimeout(w.value)), $.value = !0;
|
|
754
|
+
}, le = () => {
|
|
752
755
|
w.value = setTimeout(() => {
|
|
753
|
-
|
|
754
|
-
}, 200),
|
|
755
|
-
},
|
|
756
|
-
r ?
|
|
756
|
+
C.value = !1;
|
|
757
|
+
}, 200), $.value = !1;
|
|
758
|
+
}, ae = (r, l) => {
|
|
759
|
+
r ? te() : le();
|
|
757
760
|
}, oe = (r, l) => {
|
|
758
761
|
M.value = !1, m("update:error", M.value), m("update:model-value", r), m("change", r, l);
|
|
759
762
|
};
|
|
760
|
-
return
|
|
761
|
-
$timePicker:
|
|
763
|
+
return K({
|
|
764
|
+
$timePicker: i,
|
|
762
765
|
blur: () => {
|
|
763
|
-
|
|
766
|
+
i.value.blur();
|
|
764
767
|
},
|
|
765
768
|
focus: () => {
|
|
766
|
-
|
|
769
|
+
i.value.focus();
|
|
767
770
|
}
|
|
768
|
-
}), (r, l) => (
|
|
769
|
-
class: be(["das-ui-time-picker", [r.borderType, t.isView ? "readonly" : "",
|
|
770
|
-
style:
|
|
771
|
+
}), (r, l) => (v(), T("div", {
|
|
772
|
+
class: be(["das-ui-time-picker", [r.borderType, t.isView ? "readonly" : "", o(M) ? "is-error" : ""]]),
|
|
773
|
+
style: Y(N.value)
|
|
771
774
|
}, [
|
|
772
|
-
I(
|
|
773
|
-
default:
|
|
774
|
-
I(
|
|
775
|
+
I(o(Te), { locale: x.value }, {
|
|
776
|
+
default: c(() => [
|
|
777
|
+
I(o(Ie), {
|
|
775
778
|
ref_key: "inputTooltipRef",
|
|
776
|
-
ref:
|
|
779
|
+
ref: R,
|
|
777
780
|
placement: "top",
|
|
778
781
|
trigger: "hover",
|
|
779
|
-
visible:
|
|
782
|
+
visible: C.value,
|
|
780
783
|
disabled: !r.isTooltip,
|
|
781
|
-
content:
|
|
784
|
+
content: G.value
|
|
782
785
|
}, {
|
|
783
|
-
default:
|
|
784
|
-
|
|
786
|
+
default: c(() => [
|
|
787
|
+
fe((v(), j(o(Oe), ne({
|
|
788
|
+
key: y.value,
|
|
785
789
|
ref_key: "$timePicker",
|
|
786
|
-
ref:
|
|
790
|
+
ref: i
|
|
787
791
|
}, r.$attrs, {
|
|
788
|
-
value:
|
|
789
|
-
"onUpdate:value": l[0] || (l[0] = (e) =>
|
|
792
|
+
value: o(p),
|
|
793
|
+
"onUpdate:value": l[0] || (l[0] = (e) => Ce(p) ? p.value = e : null),
|
|
790
794
|
size: t.size,
|
|
791
795
|
popupClassName: "das-ui-time-picker-dropdown " + r.dropdownClassName,
|
|
792
796
|
showNow: r.showNow,
|
|
793
797
|
bordered: r.borderType === "bordered",
|
|
794
|
-
placeholder:
|
|
798
|
+
placeholder: A.value,
|
|
795
799
|
disabled: t.disabled || t.isView,
|
|
796
|
-
style:
|
|
797
|
-
popupStyle:
|
|
800
|
+
style: N.value,
|
|
801
|
+
popupStyle: O.value,
|
|
798
802
|
onChange: oe,
|
|
799
803
|
onOpenChange: b
|
|
800
804
|
}), {
|
|
801
|
-
dateRender:
|
|
802
|
-
|
|
803
|
-
|
|
805
|
+
dateRender: c((e) => [
|
|
806
|
+
S(r.$slots, "dateRender", ge(we(e)), () => [
|
|
807
|
+
V("div", vr, W(e.current.date()), 1)
|
|
804
808
|
], !0)
|
|
805
809
|
]),
|
|
806
|
-
suffixIcon:
|
|
807
|
-
|
|
808
|
-
I(
|
|
810
|
+
suffixIcon: c(() => [
|
|
811
|
+
S(r.$slots, "suffixIcon", {}, () => [
|
|
812
|
+
I(o(Ue), {
|
|
809
813
|
class: "das-suffix-icon",
|
|
810
814
|
size: "medium"
|
|
811
815
|
})
|
|
@@ -813,7 +817,7 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
813
817
|
]),
|
|
814
818
|
_: 3
|
|
815
819
|
}, 16, ["value", "size", "popupClassName", "showNow", "bordered", "placeholder", "disabled", "style", "popupStyle"])), [
|
|
816
|
-
[
|
|
820
|
+
[o(he), ae]
|
|
817
821
|
])
|
|
818
822
|
]),
|
|
819
823
|
_: 3
|
|
@@ -821,31 +825,31 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
821
825
|
]),
|
|
822
826
|
_: 3
|
|
823
827
|
}, 8, ["locale"]),
|
|
824
|
-
r.error && r.errorLabel ? (
|
|
825
|
-
r.errorMode === "default" ? (
|
|
826
|
-
|
|
827
|
-
style:
|
|
828
|
-
},
|
|
829
|
-
])) :
|
|
830
|
-
r.errorMode === "overlay" &&
|
|
828
|
+
r.error && r.errorLabel ? (v(), T(ue, { key: 0 }, [
|
|
829
|
+
r.errorMode === "default" ? (v(), T("div", fr, [
|
|
830
|
+
V("span", {
|
|
831
|
+
style: Y(U.value)
|
|
832
|
+
}, W(r.errorLabel), 5)
|
|
833
|
+
])) : P("", !0),
|
|
834
|
+
r.errorMode === "overlay" && $.value ? (v(), j(o(me), {
|
|
831
835
|
key: 1,
|
|
832
836
|
errorLabel: r.errorLabel,
|
|
833
837
|
getEl: () => {
|
|
834
838
|
var e;
|
|
835
|
-
return (e =
|
|
839
|
+
return (e = i.value) == null ? void 0 : e.$el;
|
|
836
840
|
},
|
|
837
841
|
errorModelZIndex: r.errorModelZIndex
|
|
838
|
-
}, null, 8, ["errorLabel", "getEl", "errorModelZIndex"])) :
|
|
839
|
-
], 64)) :
|
|
842
|
+
}, null, 8, ["errorLabel", "getEl", "errorModelZIndex"])) : P("", !0)
|
|
843
|
+
], 64)) : P("", !0)
|
|
840
844
|
], 6));
|
|
841
845
|
}
|
|
842
|
-
}),
|
|
846
|
+
}), yr = /* @__PURE__ */ ke(hr, [["__scopeId", "data-v-d798677d"]]), kr = { class: "ant-picker-cell-inner" }, br = {
|
|
843
847
|
key: 0,
|
|
844
848
|
class: "das-date-picker-error-label-content"
|
|
845
|
-
},
|
|
849
|
+
}, gr = {
|
|
846
850
|
name: "DasDatePicker"
|
|
847
|
-
},
|
|
848
|
-
...
|
|
851
|
+
}, wr = /* @__PURE__ */ ce({
|
|
852
|
+
...gr,
|
|
849
853
|
props: {
|
|
850
854
|
modelValue: {},
|
|
851
855
|
borderType: { default: "bordered" },
|
|
@@ -867,64 +871,68 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
867
871
|
formSize: {}
|
|
868
872
|
},
|
|
869
873
|
emits: ["change", "openChange", "update:model-value", "update:error"],
|
|
870
|
-
setup(
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
"
|
|
874
|
-
})),
|
|
874
|
+
setup(F, { expose: K, emit: n }) {
|
|
875
|
+
ve((l) => ({
|
|
876
|
+
b908d1c4: Z.value,
|
|
877
|
+
"9baf5a62": H.value
|
|
878
|
+
})), Me({
|
|
875
879
|
dengdai: import("@das-fed/upf-ui/packages/icons/dengdai")
|
|
876
880
|
});
|
|
877
|
-
const t =
|
|
881
|
+
const t = F, m = n, x = u(void 0);
|
|
882
|
+
_(D, async () => {
|
|
883
|
+
x.value = await $e(D.value);
|
|
884
|
+
}, { immediate: !0 });
|
|
885
|
+
const y = s(() => `time-range-picker-${D.value}`), i = u(null), R = u(null), p = X(t, "modelValue"), M = X(t, "error"), Z = s(() => t.width ? t.width : "230px"), E = s(() => t.formSize), H = s(() => t.height ? t.height : E.value ? {
|
|
878
886
|
small: "24px",
|
|
879
887
|
default: "32px",
|
|
880
888
|
large: "40px"
|
|
881
|
-
}[
|
|
882
|
-
"z-index":
|
|
883
|
-
})),
|
|
889
|
+
}[E.value] : "auto"), N = u(3e3), A = s(() => ({
|
|
890
|
+
"z-index": N.value
|
|
891
|
+
})), B = s(() => ({
|
|
884
892
|
width: t.width
|
|
885
|
-
})),
|
|
893
|
+
})), O = s(() => {
|
|
886
894
|
var l;
|
|
887
|
-
return t.isView ? t.noSetDefaultVal ? ["", ""] : ["-", "-"] : (l = t.placeholder) == null ? void 0 : l.map((e) =>
|
|
888
|
-
}),
|
|
895
|
+
return t.isView ? t.noSetDefaultVal ? ["", ""] : ["-", "-"] : (l = t.placeholder) == null ? void 0 : l.map((e) => se(e));
|
|
896
|
+
}), $ = u(!1), U = u({
|
|
889
897
|
display: "block",
|
|
890
|
-
color:
|
|
898
|
+
color: ye("--das-ui-date-picker-overlay-error-color").value,
|
|
891
899
|
"white-space": "break-spaces"
|
|
892
|
-
}), b = u(!1),
|
|
900
|
+
}), b = u(!1), C = u(["", ""]), q = u("~"), G = s(() => {
|
|
893
901
|
var l;
|
|
894
|
-
return (l = p.value) != null && l.length && p.value[0] && p.value[1] ?
|
|
895
|
-
}), k = u([0, 0]),
|
|
896
|
-
var
|
|
902
|
+
return (l = p.value) != null && l.length && p.value[0] && p.value[1] ? C.value.join(" " + q.value + " ") : O.value.join(" " + q.value + " ");
|
|
903
|
+
}), k = u([0, 0]), a = u([0, 0]), f = () => {
|
|
904
|
+
var h;
|
|
897
905
|
let l = [];
|
|
898
|
-
const e = (
|
|
906
|
+
const e = (h = i.value) == null ? void 0 : h.$el.querySelectorAll(".ant-picker-input>input");
|
|
899
907
|
if (!e)
|
|
900
908
|
return l = [0, 0], l;
|
|
901
909
|
let d = [];
|
|
902
|
-
for (let
|
|
903
|
-
d.push(
|
|
904
|
-
let
|
|
905
|
-
l.push(
|
|
910
|
+
for (let z of e) {
|
|
911
|
+
d.push(z.getAttribute("value") || "");
|
|
912
|
+
let Q = (z == null ? void 0 : z.offsetWidth) ?? 0;
|
|
913
|
+
l.push(Q);
|
|
906
914
|
}
|
|
907
|
-
return
|
|
908
|
-
},
|
|
915
|
+
return C.value = d, l;
|
|
916
|
+
}, g = (l) => {
|
|
909
917
|
const e = t.size === "table" ? 12 : 14;
|
|
910
918
|
return ze(l, e);
|
|
911
|
-
},
|
|
919
|
+
}, L = () => {
|
|
912
920
|
var d;
|
|
913
921
|
let l = [];
|
|
914
|
-
return ((d =
|
|
915
|
-
p.value.length && p.value[0] && p.value[0] ? l.push(
|
|
922
|
+
return ((d = i.value) == null ? void 0 : d.$el.querySelectorAll(".ant-picker-input>input")).forEach((h, z) => {
|
|
923
|
+
p.value.length && p.value[0] && p.value[0] ? l.push(h == null ? void 0 : h.scrollWidth) : l.push(g(O.value[z]));
|
|
916
924
|
}), l;
|
|
917
925
|
};
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
k.value =
|
|
926
|
+
_(() => [O.value, p.value], () => {
|
|
927
|
+
ee(() => {
|
|
928
|
+
k.value = f(), a.value = L(), (k.value[0] === a.value[0] || a.value[0] - k.value[0] < 1) && (k.value[1] === a.value[1] || a.value[1] - k.value[1] < 1) && (b.value = !1);
|
|
921
929
|
});
|
|
922
930
|
});
|
|
923
931
|
const w = u();
|
|
924
|
-
|
|
932
|
+
_(
|
|
925
933
|
() => {
|
|
926
934
|
var l;
|
|
927
|
-
return (l =
|
|
935
|
+
return (l = R.value) == null ? void 0 : l.$tooltipRef.popperRef.contentRef;
|
|
928
936
|
},
|
|
929
937
|
(l) => {
|
|
930
938
|
l && (l.addEventListener("mouseenter", function() {
|
|
@@ -936,90 +944,91 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
936
944
|
}));
|
|
937
945
|
}
|
|
938
946
|
);
|
|
939
|
-
const
|
|
940
|
-
l && (
|
|
947
|
+
const te = (l) => {
|
|
948
|
+
l && (N.value = Se().nextZIndex()), m("openChange", l), D.value === "en" && ee(() => {
|
|
941
949
|
const e = document == null ? void 0 : document.querySelectorAll(".ant-picker-ok > .ant-btn > span");
|
|
942
950
|
for (let d of e)
|
|
943
951
|
d && (d.innerText = "OK");
|
|
944
952
|
});
|
|
945
|
-
}, te = () => {
|
|
946
|
-
k.value = s(), h.value = g(), (k.value[0] === h.value[0] || h.value[0] - k.value[0] < 1) && (k.value[1] === h.value[1] || h.value[1] - k.value[1] < 1) ? b.value = !1 : (b.value = !0, w.value && clearTimeout(w.value)), C.value = !0;
|
|
947
953
|
}, le = () => {
|
|
954
|
+
k.value = f(), a.value = L(), (k.value[0] === a.value[0] || a.value[0] - k.value[0] < 1) && (k.value[1] === a.value[1] || a.value[1] - k.value[1] < 1) ? b.value = !1 : (b.value = !0, w.value && clearTimeout(w.value)), $.value = !0;
|
|
955
|
+
}, ae = () => {
|
|
948
956
|
w.value = setTimeout(() => {
|
|
949
957
|
b.value = !1;
|
|
950
|
-
}, 200),
|
|
958
|
+
}, 200), $.value = !1;
|
|
951
959
|
}, oe = (l, e) => {
|
|
952
|
-
l ?
|
|
953
|
-
},
|
|
960
|
+
l ? le() : ae();
|
|
961
|
+
}, ie = (l, e) => {
|
|
954
962
|
if (M.value = !1, l === null) {
|
|
955
963
|
m("update:model-value", [null, null]), m("change", [null, null], e);
|
|
956
964
|
return;
|
|
957
965
|
}
|
|
958
966
|
m("update:error", M.value), m("update:model-value", l), m("change", l, e);
|
|
959
967
|
};
|
|
960
|
-
return
|
|
961
|
-
$timeRangePicker:
|
|
968
|
+
return K({
|
|
969
|
+
$timeRangePicker: i,
|
|
962
970
|
blur: () => {
|
|
963
|
-
|
|
971
|
+
i.value.blur();
|
|
964
972
|
},
|
|
965
973
|
focus: () => {
|
|
966
|
-
|
|
974
|
+
i.value.focus();
|
|
967
975
|
}
|
|
968
|
-
}), (l, e) => (
|
|
969
|
-
class: be(["das-ui-time-range-picker", [l.borderType, t.isView ? "readonly" : "",
|
|
970
|
-
style:
|
|
976
|
+
}), (l, e) => (v(), T("div", {
|
|
977
|
+
class: be(["das-ui-time-range-picker", [l.borderType, t.isView ? "readonly" : "", o(M) ? "is-error" : ""]]),
|
|
978
|
+
style: Y(B.value)
|
|
971
979
|
}, [
|
|
972
|
-
I(
|
|
973
|
-
default:
|
|
974
|
-
I(
|
|
980
|
+
I(o(Te), { locale: x.value }, {
|
|
981
|
+
default: c(() => [
|
|
982
|
+
I(o(Ie), {
|
|
975
983
|
ref_key: "inputTooltipRef",
|
|
976
|
-
ref:
|
|
984
|
+
ref: R,
|
|
977
985
|
placement: "top",
|
|
978
986
|
trigger: "hover",
|
|
979
987
|
visible: b.value,
|
|
980
988
|
disabled: !l.isTooltip,
|
|
981
|
-
content:
|
|
989
|
+
content: G.value
|
|
982
990
|
}, {
|
|
983
|
-
default:
|
|
984
|
-
|
|
991
|
+
default: c(() => [
|
|
992
|
+
fe((v(), j(o(qe), ne({
|
|
993
|
+
key: y.value,
|
|
985
994
|
ref_key: "$timeRangePicker",
|
|
986
|
-
ref:
|
|
995
|
+
ref: i
|
|
987
996
|
}, l.$attrs, {
|
|
988
|
-
value:
|
|
989
|
-
"onUpdate:value": e[0] || (e[0] = (d) =>
|
|
997
|
+
value: o(p),
|
|
998
|
+
"onUpdate:value": e[0] || (e[0] = (d) => Ce(p) ? p.value = d : null),
|
|
990
999
|
size: t.size,
|
|
991
1000
|
popupClassName: "das-ui-time-range-picker-dropdown " + l.dropdownClassName,
|
|
992
1001
|
showNow: l.showNow,
|
|
993
1002
|
bordered: l.borderType === "bordered",
|
|
994
|
-
placeholder:
|
|
1003
|
+
placeholder: O.value,
|
|
995
1004
|
disabled: t.disabled || t.isView,
|
|
996
|
-
style:
|
|
997
|
-
popupStyle:
|
|
998
|
-
onChange:
|
|
999
|
-
onOpenChange:
|
|
1005
|
+
style: B.value,
|
|
1006
|
+
popupStyle: A.value,
|
|
1007
|
+
onChange: ie,
|
|
1008
|
+
onOpenChange: te
|
|
1000
1009
|
}), {
|
|
1001
|
-
dateRender:
|
|
1002
|
-
|
|
1003
|
-
|
|
1010
|
+
dateRender: c((d) => [
|
|
1011
|
+
S(l.$slots, "dateRender", ge(we(d)), () => [
|
|
1012
|
+
V("div", kr, W(d.current.date()), 1)
|
|
1004
1013
|
], !0)
|
|
1005
1014
|
]),
|
|
1006
|
-
suffixIcon:
|
|
1007
|
-
|
|
1008
|
-
I(
|
|
1015
|
+
suffixIcon: c(() => [
|
|
1016
|
+
S(l.$slots, "suffixIcon", {}, () => [
|
|
1017
|
+
I(o(re), {
|
|
1009
1018
|
class: "das-suffix-icon",
|
|
1010
1019
|
icon: "dengdai",
|
|
1011
1020
|
size: "medium"
|
|
1012
1021
|
})
|
|
1013
1022
|
], !0)
|
|
1014
1023
|
]),
|
|
1015
|
-
separator:
|
|
1016
|
-
|
|
1017
|
-
e[1] || (e[1] =
|
|
1024
|
+
separator: c(() => [
|
|
1025
|
+
S(l.$slots, "separator", {}, () => [
|
|
1026
|
+
e[1] || (e[1] = V("div", { style: { padding: "0 8px" } }, "~", -1))
|
|
1018
1027
|
], !0)
|
|
1019
1028
|
]),
|
|
1020
1029
|
_: 3
|
|
1021
1030
|
}, 16, ["value", "size", "popupClassName", "showNow", "bordered", "placeholder", "disabled", "style", "popupStyle"])), [
|
|
1022
|
-
[
|
|
1031
|
+
[o(he), oe]
|
|
1023
1032
|
])
|
|
1024
1033
|
]),
|
|
1025
1034
|
_: 3
|
|
@@ -1027,30 +1036,30 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
1027
1036
|
]),
|
|
1028
1037
|
_: 3
|
|
1029
1038
|
}, 8, ["locale"]),
|
|
1030
|
-
l.error && l.errorLabel ? (
|
|
1031
|
-
l.errorMode === "default" ? (
|
|
1032
|
-
|
|
1033
|
-
style:
|
|
1034
|
-
},
|
|
1035
|
-
])) :
|
|
1036
|
-
l.errorMode === "overlay" &&
|
|
1039
|
+
l.error && l.errorLabel ? (v(), T(ue, { key: 0 }, [
|
|
1040
|
+
l.errorMode === "default" ? (v(), T("div", br, [
|
|
1041
|
+
V("span", {
|
|
1042
|
+
style: Y(U.value)
|
|
1043
|
+
}, W(l.errorLabel), 5)
|
|
1044
|
+
])) : P("", !0),
|
|
1045
|
+
l.errorMode === "overlay" && $.value ? (v(), j(o(me), {
|
|
1037
1046
|
key: 1,
|
|
1038
1047
|
errorLabel: l.errorLabel,
|
|
1039
1048
|
getEl: () => {
|
|
1040
1049
|
var d;
|
|
1041
|
-
return (d =
|
|
1050
|
+
return (d = i.value) == null ? void 0 : d.$el;
|
|
1042
1051
|
},
|
|
1043
1052
|
errorModelZIndex: l.errorModelZIndex
|
|
1044
|
-
}, null, 8, ["errorLabel", "getEl", "errorModelZIndex"])) :
|
|
1045
|
-
], 64)) :
|
|
1053
|
+
}, null, 8, ["errorLabel", "getEl", "errorModelZIndex"])) : P("", !0)
|
|
1054
|
+
], 64)) : P("", !0)
|
|
1046
1055
|
], 6));
|
|
1047
1056
|
}
|
|
1048
|
-
}),
|
|
1057
|
+
}), Tr = /* @__PURE__ */ ke(wr, [["__scopeId", "data-v-e60da691"]]), Ir = {
|
|
1049
1058
|
"--das-ui-date-picker-color-defalut-text": "#212121",
|
|
1050
1059
|
// 默认字体色
|
|
1051
1060
|
"--das-ui-date-picker-color-primary": "#5582F3",
|
|
1052
1061
|
// 主题色
|
|
1053
|
-
"--das-ui-date-picker-color-underline":
|
|
1062
|
+
"--das-ui-date-picker-color-underline": _e("--das-ui-color-help"),
|
|
1054
1063
|
// 下划线基础色
|
|
1055
1064
|
"--das-ui-date-picker-color-error": "#FB2323",
|
|
1056
1065
|
// 错误边框色
|
|
@@ -1078,14 +1087,14 @@ const Ke = { class: "ant-picker-cell-inner" }, Xe = {
|
|
|
1078
1087
|
请选择日期: { "zh-CN": "请选择日期", en: "Please select a date", "zh-MO": "請選擇日期", _appCode: "framework" },
|
|
1079
1088
|
请选择时间: { "zh-CN": "请选择时间", en: "Please select the time", "zh-MO": "請選擇時間", _appCode: "framework" }
|
|
1080
1089
|
};
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
const
|
|
1090
|
+
He(Sr);
|
|
1091
|
+
Ke(Ir);
|
|
1092
|
+
const Kr = pe(Je), Hr = pe(lr), Ur = pe(cr), jr = pe(yr), Yr = pe(Tr), Xr = { name: "datePicker 日期时间选择器" };
|
|
1084
1093
|
export {
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1094
|
+
Kr as DasDatePicker,
|
|
1095
|
+
Hr as DasDateRangePicker,
|
|
1096
|
+
Ur as DasRangePicker,
|
|
1097
|
+
jr as DasTimePicker,
|
|
1098
|
+
Yr as DasTimeRangePicker,
|
|
1099
|
+
Xr as default
|
|
1091
1100
|
};
|