lh-ui-next 0.0.46 → 0.0.48
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/README.md +2 -2
- package/lib/lh-ui-next.mjs +77 -68
- package/lib/lh-ui-next.umd.js +1 -6686
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
alpha version is use to self-test; beta version is use to public survey.for example:
|
|
5
5
|
1.0.0-alpha.1
|
|
6
6
|
1.0.0-test.2
|
|
7
|
-
## Official version : "0.0.
|
|
8
|
-
## test version : "0.0.
|
|
7
|
+
## Official version : "0.0.48",
|
|
8
|
+
## test version : "0.0.48",
|
|
9
9
|
## npmmirror
|
|
10
10
|
When cnpm sync execution is unsuccessful,you can go the website(http://www.npmmirror.com/package/lh-ui-next) and press sync button to
|
|
11
11
|
manual trigger the sync event
|
package/lib/lh-ui-next.mjs
CHANGED
|
@@ -669,7 +669,12 @@ function Lt(e, t, i, s, l, n) {
|
|
|
669
669
|
const J = /* @__PURE__ */ _(St, [["render", Lt]]), Pt = {
|
|
670
670
|
name: "lhScrollbar",
|
|
671
671
|
componentName: "lhScrollbar",
|
|
672
|
-
props: {
|
|
672
|
+
props: {
|
|
673
|
+
disableResizeWrap: {
|
|
674
|
+
type: Boolean,
|
|
675
|
+
default: !1
|
|
676
|
+
}
|
|
677
|
+
},
|
|
673
678
|
emits: ["onScrollLeft", "onScrollTop", "init", "horizontalVisibleChange", "verticalVisibleChange"],
|
|
674
679
|
data() {
|
|
675
680
|
return {
|
|
@@ -759,13 +764,15 @@ const J = /* @__PURE__ */ _(St, [["render", Lt]]), Pt = {
|
|
|
759
764
|
}
|
|
760
765
|
},
|
|
761
766
|
resizeWrapHandler({ width: e, height: t }) {
|
|
762
|
-
if (
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
767
|
+
if (!this.disableResizeWrap) {
|
|
768
|
+
if (e !== "auto") {
|
|
769
|
+
let i = Number(e.replace(/px/, "")), s = this.$refs.myScrollbarView.offsetWidth;
|
|
770
|
+
this.resizeWidth(s, i);
|
|
771
|
+
}
|
|
772
|
+
if (t !== "auto") {
|
|
773
|
+
let i = Number(t.replace(/px/, "")), s = this.$refs.myScrollbarView.offsetHeight;
|
|
774
|
+
this.resizeHeight(s, i);
|
|
775
|
+
}
|
|
769
776
|
}
|
|
770
777
|
},
|
|
771
778
|
resizeWidth(e, t) {
|
|
@@ -829,8 +836,10 @@ const J = /* @__PURE__ */ _(St, [["render", Lt]]), Pt = {
|
|
|
829
836
|
}
|
|
830
837
|
}
|
|
831
838
|
setTimeout(() => {
|
|
832
|
-
|
|
833
|
-
|
|
839
|
+
if (this.$refs.myScrollbarWrap) {
|
|
840
|
+
let t = {};
|
|
841
|
+
t.vertical = JSON.parse(JSON.stringify(this.vertical)), t.vertical.scrollTop = this.$refs.myScrollbarWrap.scrollTop, t.horizontal = JSON.parse(JSON.stringify(this.horizontal)), t.horizontal.scrollLeft = this.$refs.myScrollbarWrap.scrollLeft, this.$emit("init", t);
|
|
842
|
+
}
|
|
834
843
|
}, 0);
|
|
835
844
|
}
|
|
836
845
|
}, Nt = {
|
|
@@ -1163,7 +1172,7 @@ const G = /* @__PURE__ */ _(Pt, [["render", Vt]]), zt = {
|
|
|
1163
1172
|
}, Dt = {
|
|
1164
1173
|
key: 0,
|
|
1165
1174
|
class: "lh-select-search"
|
|
1166
|
-
}, Mt = ["onClick"], Et = ["title", "innerHTML"],
|
|
1175
|
+
}, Mt = ["onClick"], Et = ["title", "innerHTML"], Rt = ["onClick"], Bt = ["innerHTML"], Wt = ["onClick"], Ft = ["innerHTML"], Ot = {
|
|
1167
1176
|
key: 3,
|
|
1168
1177
|
class: "nullMsg"
|
|
1169
1178
|
}, Ht = ["title"], At = ["innerHTML"], Ut = {
|
|
@@ -1240,6 +1249,7 @@ function Kt(e, t, i, s, l, n) {
|
|
|
1240
1249
|
}, null, 8, ["modelValue"])
|
|
1241
1250
|
])) : m("", !0),
|
|
1242
1251
|
w(r, {
|
|
1252
|
+
disableResizeWrap: "",
|
|
1243
1253
|
ref: "myScrollbar",
|
|
1244
1254
|
style: k({ maxHeight: i.maxHeight + "px" })
|
|
1245
1255
|
}, {
|
|
@@ -1266,8 +1276,8 @@ function Kt(e, t, i, s, l, n) {
|
|
|
1266
1276
|
u("span", {
|
|
1267
1277
|
class: "events-none",
|
|
1268
1278
|
innerHTML: d.name
|
|
1269
|
-
}, null, 8,
|
|
1270
|
-
], 10,
|
|
1279
|
+
}, null, 8, Bt)
|
|
1280
|
+
], 10, Rt)), [
|
|
1271
1281
|
[V, n.filterTextIn(d.name)]
|
|
1272
1282
|
])), 256)) : (o(!0), c(p, { key: 2 }, y(l.myoptionList, (d) => v((o(), c("li", {
|
|
1273
1283
|
onClick: (b) => n.itemClick(d),
|
|
@@ -1838,7 +1848,7 @@ const Vi = /([\:\-\_]+(.))/g, zi = /^moz([A-Z])/, Di = Number(document.documentM
|
|
|
1838
1848
|
return l ? s.toUpperCase() : s;
|
|
1839
1849
|
}).replace(zi, "Moz$1");
|
|
1840
1850
|
};
|
|
1841
|
-
function
|
|
1851
|
+
function Be(e, t) {
|
|
1842
1852
|
if (!e || !t)
|
|
1843
1853
|
return !1;
|
|
1844
1854
|
if (t.indexOf(" ") !== -1)
|
|
@@ -1852,7 +1862,7 @@ function K(e, t) {
|
|
|
1852
1862
|
const s = (t || "").split(" ");
|
|
1853
1863
|
for (let l = 0, n = s.length; l < n; l++) {
|
|
1854
1864
|
const a = s[l];
|
|
1855
|
-
!a || (e.classList ? e.classList.add(a) :
|
|
1865
|
+
!a || (e.classList ? e.classList.add(a) : Be(e, a) || (i += " " + a));
|
|
1856
1866
|
}
|
|
1857
1867
|
e.classList || e.setAttribute("class", i);
|
|
1858
1868
|
}
|
|
@@ -1863,7 +1873,7 @@ function q(e, t) {
|
|
|
1863
1873
|
let s = " " + e.className + " ";
|
|
1864
1874
|
for (let l = 0, n = i.length; l < n; l++) {
|
|
1865
1875
|
const a = i[l];
|
|
1866
|
-
!a || (e.classList ? e.classList.remove(a) :
|
|
1876
|
+
!a || (e.classList ? e.classList.remove(a) : Be(e, a) && (s = s.replace(" " + a + " ", " ")));
|
|
1867
1877
|
}
|
|
1868
1878
|
e.classList || e.setAttribute("class", Mi(s));
|
|
1869
1879
|
}
|
|
@@ -1896,10 +1906,10 @@ const W = Di < 9 ? function(e, t) {
|
|
|
1896
1906
|
return e.style[t];
|
|
1897
1907
|
}
|
|
1898
1908
|
};
|
|
1899
|
-
let
|
|
1909
|
+
let Re = !1, Ke = !1, ke;
|
|
1900
1910
|
const Je = function() {
|
|
1901
1911
|
let e = N.modalDom;
|
|
1902
|
-
return e ?
|
|
1912
|
+
return e ? Re = !0 : (Re = !1, e = document.createElement("div"), N.modalDom = e, e.addEventListener("touchmove", function(t) {
|
|
1903
1913
|
t.preventDefault(), t.stopPropagation();
|
|
1904
1914
|
}), e.addEventListener("click", function() {
|
|
1905
1915
|
N.doOnModalClick && N.doOnModalClick();
|
|
@@ -1935,7 +1945,7 @@ const Je = function() {
|
|
|
1935
1945
|
if (n[r].id === e)
|
|
1936
1946
|
return;
|
|
1937
1947
|
const a = Je();
|
|
1938
|
-
K(a, "v-modal"), this.modalFade && !
|
|
1948
|
+
K(a, "v-modal"), this.modalFade && !Re && K(a, "v-modal-enter"), s && s.trim().split(/\s+/).forEach((h) => K(a, h)), setTimeout(() => {
|
|
1939
1949
|
q(a, "v-modal-enter");
|
|
1940
1950
|
}, 200), i && i.parentNode && i.parentNode.nodeType !== 11 ? i.parentNode.appendChild(a) : document.body.appendChild(a), t && (a.style.zIndex = t), a.tabIndex = 0, a.style.display = "", this.modalStack.push({ id: e, zIndex: t, modalClass: s });
|
|
1941
1951
|
},
|
|
@@ -1979,7 +1989,7 @@ window.addEventListener("keydown", function(e) {
|
|
|
1979
1989
|
}
|
|
1980
1990
|
});
|
|
1981
1991
|
let we;
|
|
1982
|
-
function
|
|
1992
|
+
function Ri() {
|
|
1983
1993
|
if (we !== void 0)
|
|
1984
1994
|
return we;
|
|
1985
1995
|
const e = document.createElement("div");
|
|
@@ -1991,7 +2001,7 @@ function Bi() {
|
|
|
1991
2001
|
const s = i.offsetWidth;
|
|
1992
2002
|
return e.parentNode.removeChild(e), we = t - s, we;
|
|
1993
2003
|
}
|
|
1994
|
-
let
|
|
2004
|
+
let Bi = 1, Ve;
|
|
1995
2005
|
const Wi = {
|
|
1996
2006
|
props: {
|
|
1997
2007
|
visible: {
|
|
@@ -2028,7 +2038,7 @@ const Wi = {
|
|
|
2028
2038
|
}
|
|
2029
2039
|
},
|
|
2030
2040
|
beforeMount() {
|
|
2031
|
-
this._popupId = "popup-" +
|
|
2041
|
+
this._popupId = "popup-" + Bi++, N.register(this._popupId, this);
|
|
2032
2042
|
},
|
|
2033
2043
|
beforeUnmount() {
|
|
2034
2044
|
N.deregister(this._popupId), N.closeModal(this._popupId), this.restoreBodyStyle();
|
|
@@ -2070,7 +2080,7 @@ const Wi = {
|
|
|
2070
2080
|
this._opening = !0;
|
|
2071
2081
|
const t = this.$el, i = e.modal, s = e.zIndex;
|
|
2072
2082
|
if (s && (N.zIndex = s), i && (this._closing && (N.closeModal(this._popupId), this._closing = !1), N.openModal(this._popupId, N.nextZIndex(), this.modalAppendToBody ? void 0 : t, e.modalClass, e.modalFade), e.lockScroll)) {
|
|
2073
|
-
this.withoutHiddenClass = !
|
|
2083
|
+
this.withoutHiddenClass = !Be(document.body, "lh-popup-parent--hidden"), this.withoutHiddenClass && (this.bodyPaddingRight = document.body.style.paddingRight, this.computedBodyPaddingRight = parseInt(W(document.body, "paddingRight"), 10)), Ve = Ri();
|
|
2074
2084
|
const l = document.documentElement.clientHeight < document.body.scrollHeight, n = W(document.body, "overflowY");
|
|
2075
2085
|
Ve > 0 && (l || n === "scroll") && this.withoutHiddenClass && (document.body.style.paddingRight = this.computedBodyPaddingRight + Ve + "px"), K(document.body, "lh-popup-parent--hidden");
|
|
2076
2086
|
}
|
|
@@ -2976,7 +2986,6 @@ const Dl = /* @__PURE__ */ _(Tl, [["render", zl]]), Ml = {
|
|
|
2976
2986
|
},
|
|
2977
2987
|
watch: {
|
|
2978
2988
|
searchText: {
|
|
2979
|
-
immediate: !0,
|
|
2980
2989
|
deep: !0,
|
|
2981
2990
|
handler: function(e) {
|
|
2982
2991
|
this.debounce(this.search, 500);
|
|
@@ -2987,10 +2996,10 @@ const Dl = /* @__PURE__ */ _(Tl, [["render", zl]]), Ml = {
|
|
|
2987
2996
|
deep: !0,
|
|
2988
2997
|
handler: function(e, t) {
|
|
2989
2998
|
if (e === "" || e === null)
|
|
2990
|
-
this.$refs.myTree.setCheckedKeys([]);
|
|
2999
|
+
this.$refs.myTree && this.$refs.myTree.setCheckedKeys([]);
|
|
2991
3000
|
else {
|
|
2992
3001
|
let i = e.split(",");
|
|
2993
|
-
this.$refs.myTree.setCheckedKeys(i);
|
|
3002
|
+
this.$refs.myTree && this.$refs.myTree.setCheckedKeys(i);
|
|
2994
3003
|
}
|
|
2995
3004
|
}
|
|
2996
3005
|
}
|
|
@@ -3017,16 +3026,16 @@ const Dl = /* @__PURE__ */ _(Tl, [["render", zl]]), Ml = {
|
|
|
3017
3026
|
}
|
|
3018
3027
|
},
|
|
3019
3028
|
buttonFuc1() {
|
|
3020
|
-
this.$refs.myTree.allSelect();
|
|
3029
|
+
this.$refs.myTree && this.$refs.myTree.allSelect();
|
|
3021
3030
|
},
|
|
3022
3031
|
buttonFuc2() {
|
|
3023
|
-
this.$refs.myTree.reverseSelect();
|
|
3032
|
+
this.$refs.myTree && this.$refs.myTree.reverseSelect();
|
|
3024
3033
|
},
|
|
3025
3034
|
buttonFuc3() {
|
|
3026
|
-
this.$refs.myTree.cancelAllSelect();
|
|
3035
|
+
this.$refs.myTree && this.$refs.myTree.cancelAllSelect();
|
|
3027
3036
|
},
|
|
3028
3037
|
search() {
|
|
3029
|
-
this.$refs.myTree.search(this.searchText);
|
|
3038
|
+
this.$refs.myTree && this.$refs.myTree.search(this.searchText);
|
|
3030
3039
|
},
|
|
3031
3040
|
checkClickCallback(e) {
|
|
3032
3041
|
this.$emit("tree-check-click", e), this.$refs.mySelectSpan.click();
|
|
@@ -3064,7 +3073,7 @@ const Dl = /* @__PURE__ */ _(Tl, [["render", zl]]), Ml = {
|
|
|
3064
3073
|
beforeUnmount() {
|
|
3065
3074
|
window.removeEventListener("resize", this.listenResize);
|
|
3066
3075
|
}
|
|
3067
|
-
}, El = { class: "lh-select" },
|
|
3076
|
+
}, El = { class: "lh-select" }, Rl = ["innerHTML"], Bl = ["title"], Wl = ["innerHTML"], Fl = {
|
|
3068
3077
|
key: 0,
|
|
3069
3078
|
class: "lh-select-node lh-select-node-close pull-left"
|
|
3070
3079
|
}, Ol = /* @__PURE__ */ u("i", { class: "dropdown-icon lh-ui-font-component icon_component_arrow_down" }, null, -1);
|
|
@@ -3092,7 +3101,7 @@ function Hl(e, t, i, s, l, n) {
|
|
|
3092
3101
|
n.isSingleSelect ? (o(!0), c(p, { key: 0 }, y(l.showList, (C) => (o(), c("div", {
|
|
3093
3102
|
class: "lh-select-single text-overflow",
|
|
3094
3103
|
innerHTML: C.name
|
|
3095
|
-
}, null, 8,
|
|
3104
|
+
}, null, 8, Rl))), 256)) : (o(), c(p, { key: 1 }, [
|
|
3096
3105
|
(o(!0), c(p, null, y(l.showList, (C, I) => (o(), c(p, null, [
|
|
3097
3106
|
I === 0 ? (o(), c("span", {
|
|
3098
3107
|
key: 0,
|
|
@@ -3107,7 +3116,7 @@ function Hl(e, t, i, s, l, n) {
|
|
|
3107
3116
|
class: "lh-ui-font-component icon_component_close",
|
|
3108
3117
|
onClick: t[1] || (t[1] = U((...z) => n.delTopItem && n.delTopItem(...z), ["stop"]))
|
|
3109
3118
|
})
|
|
3110
|
-
], 8,
|
|
3119
|
+
], 8, Bl)) : m("", !0)
|
|
3111
3120
|
], 64))), 256)),
|
|
3112
3121
|
l.showList.length > 1 ? (o(), c("span", Fl, " +" + g(l.showList.length - 1), 1)) : m("", !0)
|
|
3113
3122
|
], 64)),
|
|
@@ -4164,7 +4173,7 @@ const Sn = {
|
|
|
4164
4173
|
key: 0,
|
|
4165
4174
|
class: "title-img-wapper"
|
|
4166
4175
|
}, Dn = ["src"], Mn = { class: "lh-condition-content lh-scroll-common" }, En = { class: "lh-condition-footer" };
|
|
4167
|
-
function
|
|
4176
|
+
function Rn(e, t, i, s, l, n) {
|
|
4168
4177
|
const a = T("lh-button");
|
|
4169
4178
|
return o(), c("div", Tn, [
|
|
4170
4179
|
u("div", In, [
|
|
@@ -4223,7 +4232,7 @@ function Bn(e, t, i, s, l, n) {
|
|
|
4223
4232
|
})
|
|
4224
4233
|
], 512);
|
|
4225
4234
|
}
|
|
4226
|
-
const fe = /* @__PURE__ */ _(Sn, [["render",
|
|
4235
|
+
const fe = /* @__PURE__ */ _(Sn, [["render", Rn]]);
|
|
4227
4236
|
fe.install = function(e) {
|
|
4228
4237
|
e.component(fe.name, fe);
|
|
4229
4238
|
};
|
|
@@ -4770,7 +4779,7 @@ let ze = {
|
|
|
4770
4779
|
var s = new Date(a, parseInt(r) - 1, h);
|
|
4771
4780
|
else
|
|
4772
4781
|
var s = new Date();
|
|
4773
|
-
var l,
|
|
4782
|
+
var l, R = 0, n = 0, a = s.getFullYear(), r = s.getMonth() + 1, h = s.getDate(), d = (Date.UTC(s.getFullYear(), s.getMonth(), s.getDate()) - Date.UTC(1900, 0, 31)) / 864e5;
|
|
4774
4783
|
for (l = 1900; l < 2101 && d > 0; l++)
|
|
4775
4784
|
n = this.lYearDays(l), d -= n;
|
|
4776
4785
|
d < 0 && (d += n, l--);
|
|
@@ -4778,10 +4787,10 @@ let ze = {
|
|
|
4778
4787
|
b.getFullYear() == a && b.getMonth() + 1 == r && b.getDate() == h && (C = !0);
|
|
4779
4788
|
var I = s.getDay(), z = this.nStr1[I];
|
|
4780
4789
|
I == 0 && (I = 7);
|
|
4781
|
-
var D = l,
|
|
4790
|
+
var D = l, R = this.leapMonth(l), P = !1;
|
|
4782
4791
|
for (l = 1; l < 13 && d > 0; l++)
|
|
4783
|
-
|
|
4784
|
-
d == 0 &&
|
|
4792
|
+
R > 0 && l == R + 1 && P == !1 ? (--l, P = !0, n = this.leapDays(D)) : n = this.monthDays(D, l), P == !0 && l == R + 1 && (P = !1), d -= n;
|
|
4793
|
+
d == 0 && R > 0 && l == R + 1 && (P ? P = !1 : (P = !0, --l)), d < 0 && (d += n, --l);
|
|
4785
4794
|
var M = l, F = d + 1, it = r - 1, lt = this.toGanZhiYear(D), Fe = this.getTerm(a, r * 2 - 1), nt = this.getTerm(a, r * 2), Oe = this.toGanZhi((a - 1900) * 12 + r + 11);
|
|
4786
4795
|
h >= Fe && (Oe = this.toGanZhi((a - 1900) * 12 + r + 12));
|
|
4787
4796
|
var Pe = !1, Ne = null;
|
|
@@ -4826,8 +4835,8 @@ let ze = {
|
|
|
4826
4835
|
for (var b = 0, C = !1, d = 1; d < t; d++)
|
|
4827
4836
|
b = this.leapMonth(e), C || b <= d && b > 0 && (h += this.leapDays(e), C = !0), h += this.monthDays(e, d);
|
|
4828
4837
|
l && (h += a);
|
|
4829
|
-
var I = Date.UTC(1900, 1, 30, 0, 0, 0), z = new Date((h + i - 31) * 864e5 + I), D = z.getUTCFullYear(),
|
|
4830
|
-
return this.solar2lunar(D,
|
|
4838
|
+
var I = Date.UTC(1900, 1, 30, 0, 0, 0), z = new Date((h + i - 31) * 864e5 + I), D = z.getUTCFullYear(), R = z.getUTCMonth() + 1, P = z.getUTCDate();
|
|
4839
|
+
return this.solar2lunar(D, R, P);
|
|
4831
4840
|
}
|
|
4832
4841
|
};
|
|
4833
4842
|
const Qe = {
|
|
@@ -4879,8 +4888,8 @@ const Qe = {
|
|
|
4879
4888
|
(h + 1) % 7 === 0 && (I = !0);
|
|
4880
4889
|
let z = !1;
|
|
4881
4890
|
h >= n * 7 && (z = !0);
|
|
4882
|
-
let D = Math.ceil((h + 1) / 7),
|
|
4883
|
-
b.GMTTime = new Date(
|
|
4891
|
+
let D = Math.ceil((h + 1) / 7), R = b.date.replace(/-/g, "/") + " 00:00:00";
|
|
4892
|
+
b.GMTTime = new Date(R), typeof this.pickerOptions.disabledDate == "function" && (C = this.pickerOptions.disabledDate(b.GMTTime)), r[D - 1].push({
|
|
4884
4893
|
day: d,
|
|
4885
4894
|
noBorderRight: I,
|
|
4886
4895
|
noBorderBottom: z,
|
|
@@ -4936,7 +4945,7 @@ const Qe = {
|
|
|
4936
4945
|
month: e.getMonth() + 1
|
|
4937
4946
|
};
|
|
4938
4947
|
}
|
|
4939
|
-
},
|
|
4948
|
+
}, Bn = {
|
|
4940
4949
|
name: "lhCalendar",
|
|
4941
4950
|
componentName: "lhCalendar",
|
|
4942
4951
|
mixins: [Qe],
|
|
@@ -5018,7 +5027,7 @@ function Gn(e, t, i, s, l, n) {
|
|
|
5018
5027
|
])) : m("", !0)
|
|
5019
5028
|
]);
|
|
5020
5029
|
}
|
|
5021
|
-
const me = /* @__PURE__ */ _(
|
|
5030
|
+
const me = /* @__PURE__ */ _(Bn, [["render", Gn]]);
|
|
5022
5031
|
me.install = function(e) {
|
|
5023
5032
|
e.component(me.name, me);
|
|
5024
5033
|
};
|
|
@@ -5064,7 +5073,7 @@ const Zn = {
|
|
|
5064
5073
|
z = 0, D = 0;
|
|
5065
5074
|
else {
|
|
5066
5075
|
a / l >= 2 && (z = z + -1 * a, D = D + -1 * d * (a / l)), r.translate(b, s);
|
|
5067
|
-
let
|
|
5076
|
+
let R = l / 2 + 10, P = R * Math.cos(h), M = R * Math.sin(h);
|
|
5068
5077
|
C / s % 2 == 0 ? (z = z + -1 * P, D = D + -1 * M) : (z = z + P, D = D + M);
|
|
5069
5078
|
}
|
|
5070
5079
|
else
|
|
@@ -5886,7 +5895,7 @@ const ge = /* @__PURE__ */ _(Ns, [["render", Es]]);
|
|
|
5886
5895
|
ge.install = function(e) {
|
|
5887
5896
|
e.component(ge.name, ge);
|
|
5888
5897
|
};
|
|
5889
|
-
const
|
|
5898
|
+
const Rs = {
|
|
5890
5899
|
data() {
|
|
5891
5900
|
return {
|
|
5892
5901
|
visible: !1,
|
|
@@ -5959,7 +5968,7 @@ const Bs = {
|
|
|
5959
5968
|
beforeUnmount() {
|
|
5960
5969
|
document.removeEventListener("keydown", this.keydown);
|
|
5961
5970
|
}
|
|
5962
|
-
},
|
|
5971
|
+
}, Bs = {
|
|
5963
5972
|
key: 0,
|
|
5964
5973
|
class: "lh-message__content"
|
|
5965
5974
|
}, Ws = ["innerHTML"];
|
|
@@ -5994,7 +6003,7 @@ function Fs(e, t, i, s, l, n) {
|
|
|
5994
6003
|
key: 1,
|
|
5995
6004
|
innerHTML: l.message,
|
|
5996
6005
|
class: "lh-message__content"
|
|
5997
|
-
}, null, 8, Ws)) : (o(), c("p",
|
|
6006
|
+
}, null, 8, Ws)) : (o(), c("p", Bs, g(l.message), 1))
|
|
5998
6007
|
]),
|
|
5999
6008
|
l.showClose ? (o(), c("i", {
|
|
6000
6009
|
key: 2,
|
|
@@ -6008,13 +6017,13 @@ function Fs(e, t, i, s, l, n) {
|
|
|
6008
6017
|
_: 3
|
|
6009
6018
|
}, 8, ["onAfterLeave"]);
|
|
6010
6019
|
}
|
|
6011
|
-
const Os = /* @__PURE__ */ _(
|
|
6020
|
+
const Os = /* @__PURE__ */ _(Rs, [["render", Fs]]);
|
|
6012
6021
|
let H = [], Hs = 1;
|
|
6013
|
-
const
|
|
6022
|
+
const B = function(e) {
|
|
6014
6023
|
e = e || {};
|
|
6015
6024
|
let t = e.onClose, i = "message_" + Hs++;
|
|
6016
6025
|
e.onClose = function() {
|
|
6017
|
-
|
|
6026
|
+
B.close(i, t);
|
|
6018
6027
|
};
|
|
6019
6028
|
let l = Le(Os).mount(document.createElement("div"));
|
|
6020
6029
|
for (let a in e)
|
|
@@ -6026,11 +6035,11 @@ const R = function(e) {
|
|
|
6026
6035
|
}), l.verticalOffset = n, l.visible = !0, H.push(l), l;
|
|
6027
6036
|
};
|
|
6028
6037
|
["success", "warning", "info", "error"].forEach((e) => {
|
|
6029
|
-
|
|
6038
|
+
B[e] = (t) => (typeof t == "string" && (t = {
|
|
6030
6039
|
message: t
|
|
6031
|
-
}), t.type = e,
|
|
6040
|
+
}), t.type = e, B(t));
|
|
6032
6041
|
});
|
|
6033
|
-
|
|
6042
|
+
B.close = function(e, t) {
|
|
6034
6043
|
let i = H.length, s = -1, l;
|
|
6035
6044
|
for (let n = 0; n < i; n++)
|
|
6036
6045
|
if (e === H[n].id) {
|
|
@@ -6043,7 +6052,7 @@ R.close = function(e, t) {
|
|
|
6043
6052
|
a.style.top = parseInt(a.style.top, 10) - l - 16 + "px";
|
|
6044
6053
|
}
|
|
6045
6054
|
};
|
|
6046
|
-
|
|
6055
|
+
B.closeAll = function() {
|
|
6047
6056
|
for (let e = H.length - 1; e >= 0; e--)
|
|
6048
6057
|
H[e].close();
|
|
6049
6058
|
};
|
|
@@ -6151,7 +6160,7 @@ const As = {
|
|
|
6151
6160
|
Array.isArray(this.currentFiles) || (this.currentFiles = []);
|
|
6152
6161
|
for (let e = 0; e < this.currentFiles.length; e++)
|
|
6153
6162
|
if (this.currentFiles[e].response.data.status === "uploading") {
|
|
6154
|
-
|
|
6163
|
+
B.warning("\u8BF7\u7B49\u5F85\u5F53\u524D\u6587\u4EF6\u5B8C\u6210\u4E0A\u4F20");
|
|
6155
6164
|
return;
|
|
6156
6165
|
}
|
|
6157
6166
|
this.$refs.fileInput.click();
|
|
@@ -6161,11 +6170,11 @@ const As = {
|
|
|
6161
6170
|
},
|
|
6162
6171
|
beforeUpload() {
|
|
6163
6172
|
if (this.currentFiles.length + this.selectFiles.length > Number(this.maxNum))
|
|
6164
|
-
return
|
|
6173
|
+
return B.warning(`\u4E0A\u4F20\u6587\u4EF6\u6570\u91CF\u4E0D\u8D85\u8FC7 ${this.maxNum} \u4E2A`), !1;
|
|
6165
6174
|
for (let e = 0; e < this.selectFiles.length; e++) {
|
|
6166
6175
|
let t = this.selectFiles[e];
|
|
6167
6176
|
if (t.name.length > 100)
|
|
6168
|
-
return
|
|
6177
|
+
return B.warning("\u9644\u4EF6\u540D\u79F0\u4E0D\u80FD\u5927\u4E8E100\u4E2A\u5B57\u7B26"), !1;
|
|
6169
6178
|
const i = t.name.substring(t.name.lastIndexOf(".") + 1).toLowerCase(), s = [];
|
|
6170
6179
|
for (let a = 0; a < this.typeList.length; a++) {
|
|
6171
6180
|
const r = this.typeList[a];
|
|
@@ -6173,9 +6182,9 @@ const As = {
|
|
|
6173
6182
|
}
|
|
6174
6183
|
const l = s.join("/");
|
|
6175
6184
|
if (l.indexOf(i) === -1)
|
|
6176
|
-
return
|
|
6185
|
+
return B.warning("\u9644\u4EF6\u4EC5\u652F\u6301\u540E\u7F00" + l), !1;
|
|
6177
6186
|
if (t.size / 1024 / 1024 > this.maxLimit)
|
|
6178
|
-
return
|
|
6187
|
+
return B.error("\u60A8\u7684\u6587\u4EF6\u5927\u4E8E" + this.maxLimit + "MB\uFF0C\u65E0\u6CD5\u4E0A\u4F20"), !1;
|
|
6179
6188
|
}
|
|
6180
6189
|
return !0;
|
|
6181
6190
|
},
|
|
@@ -6220,7 +6229,7 @@ const As = {
|
|
|
6220
6229
|
}).then((r) => {
|
|
6221
6230
|
r.code == "5000" ? (this.currentFiles[a].response.data.fileId = r.data ? r.data.fileId : null, this.currentFiles[a].response.data.fileIdStr = r.data ? r.data.fileIdStr : null, this.currentFiles[a].response.data.fileName = r.data ? r.data.fileName : this.currentFiles[a].response.data.fileName, setTimeout(() => {
|
|
6222
6231
|
this.filesChange();
|
|
6223
|
-
}, 60)) : (
|
|
6232
|
+
}, 60)) : (B.error(r.message), setTimeout(() => {
|
|
6224
6233
|
this.currentFiles[a].response.data.status = "fail", this.$emit("uploadFail", this.currentFiles[a]), this.filesChange();
|
|
6225
6234
|
}, 60));
|
|
6226
6235
|
});
|
|
@@ -6238,7 +6247,7 @@ const As = {
|
|
|
6238
6247
|
for (let i in this.params)
|
|
6239
6248
|
t[i] = this.params[i];
|
|
6240
6249
|
We(this.urlDelete, t).then((i) => {
|
|
6241
|
-
i.code == "5000" ||
|
|
6250
|
+
i.code == "5000" || B.error(i.message);
|
|
6242
6251
|
});
|
|
6243
6252
|
}
|
|
6244
6253
|
},
|
|
@@ -6938,9 +6947,9 @@ const za = {
|
|
|
6938
6947
|
cy: "50",
|
|
6939
6948
|
r: "20",
|
|
6940
6949
|
fill: "none"
|
|
6941
|
-
}, null, -1),
|
|
6950
|
+
}, null, -1), Ra = [
|
|
6942
6951
|
Ea
|
|
6943
|
-
],
|
|
6952
|
+
], Ba = {
|
|
6944
6953
|
key: 1,
|
|
6945
6954
|
class: "lh-loading-icon-wapper"
|
|
6946
6955
|
}, Wa = {
|
|
@@ -6955,11 +6964,11 @@ function Fa(e, t, i, s, l, n) {
|
|
|
6955
6964
|
style: k({ backgroundColor: l.background || "" })
|
|
6956
6965
|
}, [
|
|
6957
6966
|
u("div", Da, [
|
|
6958
|
-
l.spinner ? (o(), c("div",
|
|
6967
|
+
l.spinner ? (o(), c("div", Ba, [
|
|
6959
6968
|
u("i", {
|
|
6960
6969
|
class: f(l.spinner)
|
|
6961
6970
|
}, null, 2)
|
|
6962
|
-
])) : (o(), c("svg", Ma,
|
|
6971
|
+
])) : (o(), c("svg", Ma, Ra)),
|
|
6963
6972
|
l.text ? (o(), c("p", Wa, g(l.text), 1)) : m("", !0)
|
|
6964
6973
|
])
|
|
6965
6974
|
], 6), [
|
|
@@ -7238,7 +7247,7 @@ const io = {
|
|
|
7238
7247
|
], tt = function(e, t = {}) {
|
|
7239
7248
|
lo.map((i) => {
|
|
7240
7249
|
e.component(i.name, i);
|
|
7241
|
-
}), window.$lhMessage =
|
|
7250
|
+
}), window.$lhMessage = B, window.$loadingDirective = qe.directive, window.$loading = qe.service, window.$confirm = te.confirm, e.config.globalProperties.$lht = (i) => {
|
|
7242
7251
|
let s = [];
|
|
7243
7252
|
return t.language && t.language.locale ? s = t.lang[t.language.locale].message : s = io, i.split(".").reduce((l, n) => {
|
|
7244
7253
|
if (l)
|