zhihao-ui 1.2.29 → 1.2.31
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/dist/es/{BaseInfo-XETJaruy.js → BaseInfo-CAuR2Id0.js} +1 -1
- package/dist/es/BaseItem-CQzBP1WX.js +129 -0
- package/dist/es/{Button-CzjgaPIL.js → Button-D-R-2Fix.js} +4 -4
- package/dist/es/DatePicker-BDz_yTX2.js +36 -0
- package/dist/es/{DetailHeader-C7L01g9Z.js → DetailHeader-CBN9CqAp.js} +3 -3
- package/dist/es/{DetailSubTitle-ChWfR3qA.js → DetailSubTitle-DsnSxPKH.js} +2 -2
- package/dist/es/{Dialog-Cky8TKRM.js → Dialog-C_hAbDgU.js} +3 -3
- package/dist/es/{DiyDataTable-D1s7-cdV.js → DiyDataTable-CXSUoapn.js} +10 -10
- package/dist/es/{EditInfoPair-C0EG8kUd.js → EditInfoPair-C0Ielr4q.js} +3 -3
- package/dist/es/{FileWrapper-CmvheBNp.js → FileWrapper-DFqY2SD_.js} +4 -4
- package/dist/es/Grid-CLg9sn2Y.js +198 -0
- package/dist/es/{InfoPair-JA1pAAyP.js → InfoPair-6agPuvqq.js} +3 -3
- package/dist/es/{Input-12ajHBoj.js → Input-CzlIXSCf.js} +3 -3
- package/dist/es/{Loading-CHji9tKE.js → Loading-ClE8eADM.js} +2 -2
- package/dist/es/{Map-Bq9kPMot.js → Map-BJc6GMOA.js} +231 -222
- package/dist/es/{MessageBox-1NCCwju7.js → MessageBox-CBMAgp6C.js} +2 -2
- package/dist/es/{MoneyInput-PI2K9BeH.js → MoneyInput-EODuzFjO.js} +17 -18
- package/dist/es/{PageHeadPanel-CBDItYUC.js → PageHeadPanel-DDnMIqmC.js} +2 -2
- package/dist/es/{Table-BBWU5wYF.js → Table-D7YUOcI0.js} +132 -130
- package/dist/es/{ToolTips-BBCd543g.js → ToolTips-BpZo8gsa.js} +3 -3
- package/dist/es/index.js +67 -60
- package/dist/es/utils-BbWQLYZL.js +52 -0
- package/dist/es/{vendor-BhAIOWbw.js → vendor-Cq716b5Q.js} +2034 -2019
- package/dist/index.css +1 -1
- package/dist/types/components/BaseItem/BaseItem.test.d.ts +1 -0
- package/dist/types/components/BaseItem/BaseItem.vue.d.ts +50 -0
- package/dist/types/components/BaseItem/index.d.ts +209 -0
- package/dist/types/components/BaseItem/types.d.ts +39 -0
- package/dist/types/components/DatePicker/DatePicker.vue.d.ts +2 -2
- package/dist/types/components/DatePicker/index.d.ts +5 -5
- package/dist/types/components/Dialog/Dialog.vue.d.ts +29 -29
- package/dist/types/components/Dialog/index.d.ts +45 -45
- package/dist/types/components/FileWrapper/FileWrapper.vue.d.ts +2 -2
- package/dist/types/components/FileWrapper/index.d.ts +6 -6
- package/dist/types/components/Grid/Grid.vue.d.ts +7 -9
- package/dist/types/components/Grid/components/GridItem.vue.d.ts +71 -0
- package/dist/types/components/Grid/components/MultiGrid.vue.d.ts +11 -0
- package/dist/types/components/Grid/components/collectGridItems.d.ts +9 -0
- package/dist/types/components/Grid/index.d.ts +187 -0
- package/dist/types/components/Grid/types.d.ts +14 -1
- package/dist/types/components/Map/config.d.ts +1 -0
- package/dist/types/components/Map/interface/entity/render.d.ts +2 -0
- package/dist/types/components/Map/render/renderPoint.d.ts +1 -2
- package/dist/types/components/Table/components/ColSetting.vue.d.ts +2 -2
- package/dist/types/components/Table/components/SearchForm.vue.d.ts +2 -2
- package/dist/types/components/ToolTips/ToolTips.vue.d.ts +1 -1
- package/dist/types/components/ToolTips/index.d.ts +3 -3
- package/dist/types/components/index.d.ts +1 -0
- package/dist/types/components/utils/color.d.ts +1 -0
- package/dist/umd/index.css +1 -1
- package/dist/umd/index.umd.cjs +19 -19
- package/package.json +1 -1
- package/dist/es/DatePicker-DNgii92T.js +0 -58
- package/dist/es/Grid-CfJ_U3gi.js +0 -96
- package/dist/es/utils-BIGjF-zg.js +0 -14
package/package.json
CHANGED
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
import { defineComponent as d, openBlock as u, createElementBlock as h, normalizeClass as f, createVNode as D, unref as M, mergeProps as _ } from "vue";
|
|
2
|
-
import { h as g, b as Y } from "./vendor-BhAIOWbw.js";
|
|
3
|
-
import { w as A } from "./utils-BIGjF-zg.js";
|
|
4
|
-
const p = "--", m = "YYYY-MM-DDTHH:mm:ss", T = "YYYY-MM-DDT23:59:59", E = "YYYY-MM-DD", C = "https://static.zhihaoscm.cn/", i = (e, l = E) => e ? g(e).format(l).replace("Invalid date", p) : p, N = (e) => typeof e == "number" ? !0 : typeof e == "string" ? !isNaN(parseFloat(e)) : !1;
|
|
5
|
-
function U(e) {
|
|
6
|
-
const l = ["角", "分"], c = ["零", "壹", "贰", "叁", "肆", "伍", "陆", "柒", "捌", "玖"], s = [
|
|
7
|
-
["元", "万", "亿"],
|
|
8
|
-
["", "拾", "佰", "仟"]
|
|
9
|
-
], n = e < 0 ? "负" : "";
|
|
10
|
-
e = Math.abs(e);
|
|
11
|
-
let o = "";
|
|
12
|
-
for (let a = 0; a < l.length; a++)
|
|
13
|
-
o += (c[Math.floor(e * 10 * Math.pow(10, a)) % 10] + l[a]).replace(/零./, "");
|
|
14
|
-
o = o || "整", e = Math.floor(e);
|
|
15
|
-
for (let a = 0; a < s[0].length && e > 0; a++) {
|
|
16
|
-
let t = "";
|
|
17
|
-
for (let r = 0; r < s[1].length && e > 0; r++)
|
|
18
|
-
t = c[e % 10] + s[1][r] + t, e = Math.floor(e / 10);
|
|
19
|
-
o = t.replace(/(零.)*零$/, "").replace(/^$/, "零") + s[0][a] + o;
|
|
20
|
-
}
|
|
21
|
-
return n + o.replace(/(零.)*零元/, "元").replace(/(零.)+/g, "零").replace(/^整$/, "零元整");
|
|
22
|
-
}
|
|
23
|
-
const k = /* @__PURE__ */ d({
|
|
24
|
-
name: "zh-date-picker",
|
|
25
|
-
__name: "DatePicker",
|
|
26
|
-
props: {
|
|
27
|
-
style: {},
|
|
28
|
-
class: {},
|
|
29
|
-
modelValue: {}
|
|
30
|
-
},
|
|
31
|
-
emits: ["update:modelValue", "change"],
|
|
32
|
-
setup(e, { emit: l }) {
|
|
33
|
-
const c = e, s = l, n = (t) => Array.isArray(t) ? [i(t[0], m), i(t[1], T)] : t && i(t, m), o = (t) => {
|
|
34
|
-
const r = n(t);
|
|
35
|
-
s("update:modelValue", r);
|
|
36
|
-
}, a = (t) => {
|
|
37
|
-
const r = n(t);
|
|
38
|
-
s("change", r);
|
|
39
|
-
};
|
|
40
|
-
return (t, r) => (u(), h("div", {
|
|
41
|
-
class: f([c.class, "zh-date-picker"])
|
|
42
|
-
}, [
|
|
43
|
-
D(M(Y), _(t.$attrs, {
|
|
44
|
-
style: c.style,
|
|
45
|
-
"model-value": c.modelValue,
|
|
46
|
-
"onUpdate:modelValue": o,
|
|
47
|
-
onChange: a
|
|
48
|
-
}), null, 16, ["style", "model-value"])
|
|
49
|
-
], 2));
|
|
50
|
-
}
|
|
51
|
-
}), L = A(k);
|
|
52
|
-
export {
|
|
53
|
-
C,
|
|
54
|
-
p as D,
|
|
55
|
-
L as Z,
|
|
56
|
-
U as d,
|
|
57
|
-
N as v
|
|
58
|
-
};
|
package/dist/es/Grid-CfJ_U3gi.js
DELETED
|
@@ -1,96 +0,0 @@
|
|
|
1
|
-
import { defineComponent as $, onBeforeMount as B, useSlots as C, ref as k, computed as f, onMounted as L, onActivated as S, onUnmounted as j, onDeactivated as M, provide as p, watch as z, openBlock as P, createElementBlock as R, normalizeStyle as Z, renderSlot as D } from "vue";
|
|
2
|
-
import { w as H } from "./utils-BIGjF-zg.js";
|
|
3
|
-
const N = /* @__PURE__ */ $({
|
|
4
|
-
name: "zh-grid",
|
|
5
|
-
__name: "Grid",
|
|
6
|
-
props: {
|
|
7
|
-
cols: { default: () => ({ xs: 1, sm: 2, md: 2, lg: 4, xl: 4 }) },
|
|
8
|
-
collapsed: { type: Boolean, default: !1 },
|
|
9
|
-
collapsedRows: { default: 1 },
|
|
10
|
-
gap: { default: 10 }
|
|
11
|
-
},
|
|
12
|
-
setup(A, { expose: E }) {
|
|
13
|
-
const t = A;
|
|
14
|
-
B(() => t.collapsed && u()), L(() => {
|
|
15
|
-
o({ target: { innerWidth: window.innerWidth } }), window.addEventListener("resize", o);
|
|
16
|
-
}), S(() => {
|
|
17
|
-
o({ target: { innerWidth: window.innerWidth } }), window.addEventListener("resize", o);
|
|
18
|
-
}), j(() => {
|
|
19
|
-
window.removeEventListener("resize", o);
|
|
20
|
-
}), M(() => {
|
|
21
|
-
window.removeEventListener("resize", o);
|
|
22
|
-
});
|
|
23
|
-
const o = (s) => {
|
|
24
|
-
let e = s.target.innerWidth;
|
|
25
|
-
switch (!!e) {
|
|
26
|
-
case e < 768:
|
|
27
|
-
r.value = "xs";
|
|
28
|
-
break;
|
|
29
|
-
case (e >= 768 && e < 992):
|
|
30
|
-
r.value = "sm";
|
|
31
|
-
break;
|
|
32
|
-
case (e >= 992 && e < 1200):
|
|
33
|
-
r.value = "md";
|
|
34
|
-
break;
|
|
35
|
-
case (e >= 1200 && e < 1920):
|
|
36
|
-
r.value = "lg";
|
|
37
|
-
break;
|
|
38
|
-
case e >= 1920:
|
|
39
|
-
r.value = "xl";
|
|
40
|
-
break;
|
|
41
|
-
}
|
|
42
|
-
};
|
|
43
|
-
p("gap", Array.isArray(t.gap) ? t.gap[0] : t.gap);
|
|
44
|
-
let r = k("xl");
|
|
45
|
-
p("breakPoint", r);
|
|
46
|
-
const i = k(-1);
|
|
47
|
-
p("shouldHiddenIndex", i);
|
|
48
|
-
const d = f(() => typeof t.cols == "object" ? t.cols[r.value] ?? t.cols : t.cols);
|
|
49
|
-
p("cols", d);
|
|
50
|
-
const G = C().default(), u = () => {
|
|
51
|
-
var m, v, g, h;
|
|
52
|
-
let s = [], e = null;
|
|
53
|
-
G.forEach((a) => {
|
|
54
|
-
var n;
|
|
55
|
-
typeof a.type == "object" && a.type.name === "GridItem" && ((n = a.props) == null ? void 0 : n.suffix) !== void 0 && (e = a), typeof a.type == "symbol" && Array.isArray(a.children) && s.push(...a.children);
|
|
56
|
-
});
|
|
57
|
-
let c = 0;
|
|
58
|
-
e && (c = (((m = e.props[r.value]) == null ? void 0 : m.span) ?? ((v = e.props) == null ? void 0 : v.span) ?? 1) + (((g = e.props[r.value]) == null ? void 0 : g.offset) ?? ((h = e.props) == null ? void 0 : h.offset) ?? 0));
|
|
59
|
-
try {
|
|
60
|
-
let a = !1;
|
|
61
|
-
s.reduce((n = 0, l, _) => {
|
|
62
|
-
var w, y, x, b;
|
|
63
|
-
if (n += (((w = l.props[r.value]) == null ? void 0 : w.span) ?? ((y = l.props) == null ? void 0 : y.span) ?? 1) + (((x = l.props[r.value]) == null ? void 0 : x.offset) ?? ((b = l.props) == null ? void 0 : b.offset) ?? 0), Number(n) > t.collapsedRows * d.value - c)
|
|
64
|
-
throw i.value = _, a = !0, "find it";
|
|
65
|
-
return n;
|
|
66
|
-
}, 0), a || (i.value = -1);
|
|
67
|
-
} catch {
|
|
68
|
-
}
|
|
69
|
-
};
|
|
70
|
-
z(
|
|
71
|
-
() => r.value,
|
|
72
|
-
() => {
|
|
73
|
-
t.collapsed && u();
|
|
74
|
-
}
|
|
75
|
-
), z(
|
|
76
|
-
() => t.collapsed,
|
|
77
|
-
(s) => {
|
|
78
|
-
if (s) return u();
|
|
79
|
-
i.value = -1;
|
|
80
|
-
}
|
|
81
|
-
);
|
|
82
|
-
const I = f(() => typeof t.gap == "number" ? `${t.gap}px` : Array.isArray(t.gap) ? `${t.gap[1]}px ${t.gap[0]}px` : "unset"), W = f(() => ({
|
|
83
|
-
display: "grid",
|
|
84
|
-
gridGap: I.value,
|
|
85
|
-
gridTemplateColumns: `repeat(${d.value}, minmax(0, 1fr))`
|
|
86
|
-
}));
|
|
87
|
-
return E({ breakPoint: r }), (s, e) => (P(), R("div", {
|
|
88
|
-
style: Z(W.value)
|
|
89
|
-
}, [
|
|
90
|
-
D(s.$slots, "default")
|
|
91
|
-
], 4));
|
|
92
|
-
}
|
|
93
|
-
}), q = H(N);
|
|
94
|
-
export {
|
|
95
|
-
q as Z
|
|
96
|
-
};
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { ao as t } from "./vendor-BhAIOWbw.js";
|
|
2
|
-
function n(a) {
|
|
3
|
-
return (s) => t(a, (r) => {
|
|
4
|
-
s.use(r);
|
|
5
|
-
});
|
|
6
|
-
}
|
|
7
|
-
const e = (a) => (a.install = (l) => {
|
|
8
|
-
const s = (a == null ? void 0 : a.name) || "UnnamedComponent";
|
|
9
|
-
l.component(s, a);
|
|
10
|
-
}, a);
|
|
11
|
-
export {
|
|
12
|
-
n as m,
|
|
13
|
-
e as w
|
|
14
|
-
};
|