@aplus-frontend/ui 7.0.1 → 7.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/src/ap-descriptions/ap-descriptions.vue.mjs +39 -39
- package/es/src/ap-descriptions/style/index.mjs +16 -43
- package/es/src/ap-download/ap-download.vue.mjs +43 -43
- package/es/src/ap-download/hooks/useStyle.d.ts +1 -1
- package/es/src/ap-download/hooks/useStyle.mjs +17 -14
- package/es/src/ap-download/style/index.mjs +6 -13
- package/es/src/ap-form/modal-form/index.vue.mjs +59 -60
- package/es/src/ap-form/style/modal-form.mjs +14 -15
- package/es/src/ap-form/style/search-form-sorter.mjs +26 -26
- package/es/src/ap-form/style/token.d.ts +4 -0
- package/es/src/ap-grid/style/index.mjs +3 -3
- package/es/src/ap-pro-card/style/statistic.mjs +3 -3
- package/es/src/ap-pro-card/style/token.mjs +1 -1
- package/es/src/ap-table/style/index.mjs +2 -2
- package/es/src/ap-table/style/setting.mjs +2 -2
- package/es/src/ap-tag/ap-tag-group.vue.mjs +61 -61
- package/es/src/ap-tag/ap-tag.vue.mjs +19 -20
- package/es/src/ap-tag/style/group.mjs +2 -8
- package/es/src/ap-tag/style/index.mjs +14 -23
- package/es/src/ap-upload/apUpload.vue.mjs +39 -39
- package/es/src/ap-upload/components/MultipleFile.vue2.mjs +60 -61
- package/es/src/ap-upload/components/Picture.vue2.mjs +90 -91
- package/es/src/ap-upload/components/SingleFile.vue2.mjs +72 -72
- package/es/src/ap-upload/style/multiple-file.mjs +13 -40
- package/es/src/ap-upload/style/picture.mjs +12 -30
- package/es/src/ap-upload/style/single-file.mjs +5 -16
- package/es/src/business/ap-appendix/style/index.mjs +1 -1
- package/es/src/business/ap-attachment/ApAttachment.mjs +42 -39
- package/es/src/business/ap-copy/style/index.mjs +1 -1
- package/es/src/business/ap-expand-alert/ApExpandAlert.vue2.mjs +45 -46
- package/es/src/business/ap-ladder/ApLadder.mjs +20 -22
- package/es/src/business/ap-ladder/style/index.mjs +9 -34
- package/es/src/business/ap-product-info/ApProductInfo.mjs +21 -22
- package/es/src/business/ap-product-info/style/index.mjs +8 -24
- package/es/src/business/ap-radio-group/style/index.mjs +1 -1
- package/es/src/business/ap-size-input/ApSizeInput.mjs +1 -1
- package/es/src/business/ap-table-modal/hooks/use-table-modal.mjs +18 -19
- package/es/src/business/ap-table-modal/modal-title.vue2.mjs +13 -13
- package/es/src/business/ap-title/style/index.mjs +1 -1
- package/es/src/business/ap-upload-file/ap-upload-single/ap-upload-single.vue.mjs +38 -37
- package/es/src/business/ap-value-select-card/index.vue2.mjs +36 -37
- package/es/src/business/ap-value-select-card/style/index.mjs +7 -29
- package/es/src/business/batch-input-group/style/index.mjs +1 -1
- package/es/src/check-card/style/index.mjs +31 -31
- package/es/src/design-token/constants.mjs +4 -2
- package/es/src/design-token/interface.d.ts +36 -39
- package/es/src/scroll-bar/style/index.mjs +12 -12
- package/es/src/splitter/style/index.mjs +6 -6
- package/es/src/style/index.mjs +1 -1
- package/es/src/text/style/index.mjs +1 -1
- package/es/src/utils/cssinjs/TokenUtil.d.ts +11 -0
- package/es/src/utils/cssinjs/TokenUtil.mjs +26 -0
- package/es/src/utils/cssinjs/index.mjs +23 -22
- package/es/src/version.d.ts +1 -1
- package/es/src/version.mjs +1 -1
- package/lib/src/ap-descriptions/ap-descriptions.vue.js +1 -1
- package/lib/src/ap-descriptions/style/index.js +1 -1
- package/lib/src/ap-download/ap-download.vue.js +1 -1
- package/lib/src/ap-download/hooks/useStyle.d.ts +1 -1
- package/lib/src/ap-download/hooks/useStyle.js +1 -1
- package/lib/src/ap-download/style/index.js +1 -1
- package/lib/src/ap-form/modal-form/index.vue.js +1 -1
- package/lib/src/ap-form/style/modal-form.js +1 -1
- package/lib/src/ap-form/style/search-form-sorter.js +1 -1
- package/lib/src/ap-form/style/token.d.ts +4 -0
- package/lib/src/ap-grid/style/index.js +1 -1
- package/lib/src/ap-pro-card/style/statistic.js +1 -1
- package/lib/src/ap-pro-card/style/token.js +1 -1
- package/lib/src/ap-table/style/index.js +1 -1
- package/lib/src/ap-table/style/setting.js +1 -1
- package/lib/src/ap-tag/ap-tag-group.vue.js +1 -1
- package/lib/src/ap-tag/ap-tag.vue.js +1 -1
- package/lib/src/ap-tag/style/group.js +1 -1
- package/lib/src/ap-tag/style/index.js +1 -1
- package/lib/src/ap-upload/apUpload.vue.js +1 -1
- package/lib/src/ap-upload/components/MultipleFile.vue2.js +1 -1
- package/lib/src/ap-upload/components/Picture.vue2.js +1 -1
- package/lib/src/ap-upload/components/SingleFile.vue2.js +1 -1
- package/lib/src/ap-upload/style/multiple-file.js +1 -1
- package/lib/src/ap-upload/style/picture.js +1 -1
- package/lib/src/ap-upload/style/single-file.js +1 -1
- package/lib/src/business/ap-appendix/style/index.js +1 -1
- package/lib/src/business/ap-attachment/ApAttachment.js +1 -1
- package/lib/src/business/ap-copy/style/index.js +1 -1
- package/lib/src/business/ap-expand-alert/ApExpandAlert.vue2.js +1 -1
- package/lib/src/business/ap-ladder/ApLadder.js +1 -1
- package/lib/src/business/ap-ladder/style/index.js +1 -1
- package/lib/src/business/ap-product-info/ApProductInfo.js +1 -1
- package/lib/src/business/ap-product-info/style/index.js +1 -1
- package/lib/src/business/ap-radio-group/style/index.js +1 -1
- package/lib/src/business/ap-size-input/ApSizeInput.js +1 -1
- package/lib/src/business/ap-table-modal/hooks/use-table-modal.js +1 -1
- package/lib/src/business/ap-table-modal/modal-title.vue2.js +1 -1
- package/lib/src/business/ap-title/style/index.js +1 -1
- package/lib/src/business/ap-upload-file/ap-upload-single/ap-upload-single.vue.js +1 -1
- package/lib/src/business/ap-value-select-card/index.vue2.js +1 -1
- package/lib/src/business/ap-value-select-card/style/index.js +1 -1
- package/lib/src/business/batch-input-group/style/index.js +1 -1
- package/lib/src/check-card/style/index.js +1 -1
- package/lib/src/design-token/constants.js +1 -1
- package/lib/src/design-token/interface.d.ts +36 -39
- package/lib/src/scroll-bar/style/index.js +1 -1
- package/lib/src/splitter/style/index.js +1 -1
- package/lib/src/style/index.js +1 -1
- package/lib/src/text/style/index.js +1 -1
- package/lib/src/utils/cssinjs/TokenUtil.d.ts +11 -0
- package/lib/src/utils/cssinjs/TokenUtil.js +1 -0
- package/lib/src/utils/cssinjs/index.js +1 -1
- package/lib/src/version.d.ts +1 -1
- package/lib/src/version.js +1 -1
- package/package.json +1 -1
|
@@ -1,71 +1,74 @@
|
|
|
1
|
-
import { defineComponent as W, ref as
|
|
1
|
+
import { defineComponent as W, ref as k, useSlots as _, computed as o, cloneVNode as j, toRaw as h, unref as K, createVNode as t, createTextVNode as R } from "vue";
|
|
2
2
|
import { Tooltip as B, Popover as G } from "@aplus-frontend/antdv";
|
|
3
3
|
import "../../config-provider/index.mjs";
|
|
4
4
|
import { ApAttachmentProps as H } from "./constans.mjs";
|
|
5
|
-
import { getHexWithOpacity as
|
|
6
|
-
import { useOssInit as
|
|
7
|
-
import { debounce as
|
|
5
|
+
import { getHexWithOpacity as M, getFileInfo as F } from "../../ap-download/utils/getFileInfo.mjs";
|
|
6
|
+
import { useOssInit as q } from "../../ap-download/hooks/index.mjs";
|
|
7
|
+
import { debounce as D, isArray as E } from "lodash-unified";
|
|
8
8
|
import { LoadingOutlined as g } from "@ant-design/icons-vue";
|
|
9
|
-
import { warning as
|
|
10
|
-
import
|
|
9
|
+
import { warning as J } from "../../utils/warning.mjs";
|
|
10
|
+
import Q from "./style/index.mjs";
|
|
11
|
+
import { useToken as X } from "../../config-provider/hooks/use-token.mjs";
|
|
11
12
|
import { useNamespace as Y } from "../../config-provider/hooks/use-namespace.mjs";
|
|
12
|
-
import { useGlobalConfig as
|
|
13
|
+
import { useGlobalConfig as T } from "../../config-provider/hooks/use-global-config.mjs";
|
|
13
14
|
import { useLocale as Z } from "../../config-provider/hooks/use-locale.mjs";
|
|
14
|
-
const
|
|
15
|
+
const fe = /* @__PURE__ */ W({
|
|
15
16
|
name: "ApAttachment",
|
|
16
17
|
props: H(),
|
|
17
18
|
setup(e, {
|
|
18
|
-
emit:
|
|
19
|
+
emit: p
|
|
19
20
|
}) {
|
|
20
21
|
const {
|
|
21
|
-
b:
|
|
22
|
+
b: x,
|
|
22
23
|
e: a
|
|
23
|
-
} = Y("ap-attachment"), L =
|
|
24
|
-
|
|
24
|
+
} = Y("ap-attachment"), L = Q("ap-attachment"), C = T("apUpload"), N = T("downloadCenterTriggerConfig"), {
|
|
25
|
+
token: w
|
|
26
|
+
} = X(), {
|
|
27
|
+
lang: O,
|
|
25
28
|
t: m
|
|
26
|
-
} = Z(), i =
|
|
27
|
-
"--download-main-color":
|
|
28
|
-
"--download-main-color-opacity":
|
|
29
|
-
})),
|
|
29
|
+
} = Z(), i = k(!1), c = k(""), d = _(), P = o(() => O.value === "zh-cn" ? "zh_CN" : "en_US"), s = o(() => e.needName ?? C?.value?.needName), f = o(() => e.attachmentList.length === 1), y = o(() => s.value ? e.attachmentList.length > 0 && s.value && s.value?.nameKey ? e.attachmentList[0][s.value.nameKey] : "" : e.attachmentList.length > 0 ? e.attachmentList[0].fileName : ""), I = o(() => f.value ? y.value : m("ap.apAttachment.downloadall")), A = o(() => ({
|
|
30
|
+
"--download-main-color": w.value?.colorLink,
|
|
31
|
+
"--download-main-color-opacity": M(w.value?.colorLink, 0.6)
|
|
32
|
+
})), S = o(() => e.getOssAccess || C.value?.getOssAccess), V = o(() => {
|
|
30
33
|
const l = d.default ? d.default()[0] : null;
|
|
31
34
|
return l ? j(l, {
|
|
32
35
|
style: {
|
|
33
36
|
"font-size": "16px"
|
|
34
37
|
}
|
|
35
38
|
}) : null;
|
|
36
|
-
}), v =
|
|
39
|
+
}), v = D(async (l, r) => {
|
|
37
40
|
if (!e.disabled) {
|
|
38
|
-
i.value = !0,
|
|
41
|
+
i.value = !0, r && (c.value = r);
|
|
39
42
|
try {
|
|
40
|
-
const
|
|
41
|
-
if (
|
|
42
|
-
const
|
|
43
|
+
const n = E(h(l)) ? h(l) : [h(l)];
|
|
44
|
+
if (N.value?.trigger) {
|
|
45
|
+
const u = F(s.value, n).map((b) => ({
|
|
43
46
|
objectName: b.path,
|
|
44
47
|
fileName: b.fileName
|
|
45
48
|
}));
|
|
46
|
-
|
|
49
|
+
N.value?.trigger(u), p("downloadCallback", u);
|
|
47
50
|
} else {
|
|
48
|
-
const
|
|
49
|
-
|
|
51
|
+
const u = await (await q(S.value, K(P))).downloadFile(F(e.needName, n));
|
|
52
|
+
p("downloadCallback", u);
|
|
50
53
|
}
|
|
51
|
-
} catch (
|
|
52
|
-
|
|
54
|
+
} catch (n) {
|
|
55
|
+
J(!1, n);
|
|
53
56
|
} finally {
|
|
54
57
|
i.value = !1, c.value = "";
|
|
55
58
|
}
|
|
56
59
|
}
|
|
57
|
-
}, 500),
|
|
60
|
+
}, 500), z = (l) => l && l.length > 0 ? t("ul", {
|
|
58
61
|
class: [a("file-list"), L.value],
|
|
59
|
-
style:
|
|
60
|
-
}, [l.map((
|
|
61
|
-
key:
|
|
62
|
+
style: A.value
|
|
63
|
+
}, [l.map((r, n) => t("li", {
|
|
64
|
+
key: n,
|
|
62
65
|
class: [a("file-item")],
|
|
63
|
-
onClick: () => v(
|
|
64
|
-
}, [i.value && c.value ===
|
|
66
|
+
onClick: () => v(r, n + 1)
|
|
67
|
+
}, [i.value && c.value === n + 1 ? t("span", {
|
|
65
68
|
class: [a("spin")]
|
|
66
69
|
}, [t(g, {
|
|
67
70
|
spin: !0
|
|
68
|
-
}, null)]) : null,
|
|
71
|
+
}, null)]) : null, r.fileName])), t("li", {
|
|
69
72
|
class: [a("download-all")],
|
|
70
73
|
onClick: () => v(e.attachmentList, "all")
|
|
71
74
|
}, [i.value && c.value === "all" ? t("span", {
|
|
@@ -74,10 +77,10 @@ const de = /* @__PURE__ */ W({
|
|
|
74
77
|
spin: !0
|
|
75
78
|
}, null)]) : null, m("ap.apAttachment.downloadall")])]) : null;
|
|
76
79
|
return () => e.attachmentList?.length > 0 && t("div", {
|
|
77
|
-
class: [
|
|
78
|
-
style: [
|
|
80
|
+
class: [x(), L.value],
|
|
81
|
+
style: [A.value]
|
|
79
82
|
}, [t(B, {
|
|
80
|
-
title:
|
|
83
|
+
title: I.value,
|
|
81
84
|
placement: e.textToolTipPlacement,
|
|
82
85
|
color: e.toolTipBgColor
|
|
83
86
|
}, {
|
|
@@ -90,14 +93,14 @@ const de = /* @__PURE__ */ W({
|
|
|
90
93
|
spin: !0
|
|
91
94
|
}, null)]) : null, d.default ? t("div", {
|
|
92
95
|
class: [a("text-render")]
|
|
93
|
-
}, [
|
|
96
|
+
}, [V.value, R(" ")]) : null, t("div", {
|
|
94
97
|
class: [a("text-inner")],
|
|
95
98
|
style: {
|
|
96
99
|
"max-width": e.maxWidth ? e.maxWidth + "px" : "auto"
|
|
97
100
|
}
|
|
98
101
|
}, [y.value])])]
|
|
99
102
|
}), t(G, {
|
|
100
|
-
content:
|
|
103
|
+
content: z(e.attachmentList),
|
|
101
104
|
placement: e.fileMorePopoverPlacement,
|
|
102
105
|
color: "#fff"
|
|
103
106
|
}, {
|
|
@@ -108,5 +111,5 @@ const de = /* @__PURE__ */ W({
|
|
|
108
111
|
}
|
|
109
112
|
});
|
|
110
113
|
export {
|
|
111
|
-
|
|
114
|
+
fe as default
|
|
112
115
|
};
|
|
@@ -1,14 +1,13 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { DownOutlined as
|
|
3
|
-
import { Alert as
|
|
4
|
-
import { ApActionItem as
|
|
1
|
+
import { defineComponent as W, computed as c, ref as g, watch as x, nextTick as f, onMounted as j, createElementBlock as i, openBlock as a, normalizeClass as n, unref as t, createVNode as S, withCtx as m, createElementVNode as C, normalizeStyle as y, renderSlot as H, createBlock as $, toDisplayString as u, resolveDynamicComponent as I, Fragment as E, renderList as G, createCommentVNode as L, createTextVNode as J } from "vue";
|
|
2
|
+
import { DownOutlined as P } from "@ant-design/icons-vue";
|
|
3
|
+
import { Alert as Q, Tooltip as U } from "@aplus-frontend/antdv";
|
|
4
|
+
import { ApActionItem as X } from "../../ap-action/index.mjs";
|
|
5
5
|
import "../../config-provider/index.mjs";
|
|
6
|
-
import { isNil as
|
|
7
|
-
import
|
|
8
|
-
import { useLocale as
|
|
9
|
-
import { useNamespace as
|
|
10
|
-
|
|
11
|
-
const oe = ["onClick"], he = /* @__PURE__ */ j({
|
|
6
|
+
import { isNil as Y, isString as A } from "lodash-unified";
|
|
7
|
+
import Z from "./style/index.mjs";
|
|
8
|
+
import { useLocale as _ } from "../../config-provider/hooks/use-locale.mjs";
|
|
9
|
+
import { useNamespace as ee } from "../../config-provider/hooks/use-namespace.mjs";
|
|
10
|
+
const te = ["onClick"], ce = /* @__PURE__ */ W({
|
|
12
11
|
__name: "ApExpandAlert",
|
|
13
12
|
props: {
|
|
14
13
|
type: { default: "warning" },
|
|
@@ -27,25 +26,25 @@ const oe = ["onClick"], he = /* @__PURE__ */ j({
|
|
|
27
26
|
afterClose: {}
|
|
28
27
|
},
|
|
29
28
|
emits: ["choose", "expand", "close"],
|
|
30
|
-
setup(z, { expose: D, emit:
|
|
31
|
-
const h =
|
|
29
|
+
setup(z, { expose: D, emit: V }) {
|
|
30
|
+
const h = V, p = z, { t: B } = _(), R = c(() => {
|
|
32
31
|
if (p.type != "card")
|
|
33
32
|
return p.type;
|
|
34
|
-
}),
|
|
33
|
+
}), l = g(""), d = g(null), q = c(() => ({
|
|
35
34
|
fontWeight: "400",
|
|
36
35
|
wordBreak: "break-all",
|
|
37
36
|
overflow: "hidden",
|
|
38
37
|
display: "-webkit-box",
|
|
39
|
-
webkitLineClamp:
|
|
38
|
+
webkitLineClamp: l.value,
|
|
40
39
|
webkitBoxOrient: "vertical",
|
|
41
40
|
lineHeight: "18px"
|
|
42
41
|
}));
|
|
43
|
-
function
|
|
44
|
-
|
|
42
|
+
function F() {
|
|
43
|
+
l.value === "1" ? (l.value = "", h("expand", "expand")) : (l.value = "1", h("expand", "collapse"));
|
|
45
44
|
}
|
|
46
|
-
const
|
|
45
|
+
const M = c(() => l.value === "1" ? B("ap.apExpandAlert.expand") : B("ap.apExpandAlert.collapse")), v = g(!0), N = c(() => l.value !== "1");
|
|
47
46
|
function k(e) {
|
|
48
|
-
e ?
|
|
47
|
+
e ? l.value = "" : l.value = "1";
|
|
49
48
|
}
|
|
50
49
|
function O(e) {
|
|
51
50
|
h("close", e);
|
|
@@ -53,7 +52,7 @@ const oe = ["onClick"], he = /* @__PURE__ */ j({
|
|
|
53
52
|
x(
|
|
54
53
|
() => p.data,
|
|
55
54
|
() => {
|
|
56
|
-
|
|
55
|
+
l.value = "", f(() => {
|
|
57
56
|
if (d.value) {
|
|
58
57
|
const e = Number(d.value.clientHeight), r = Number(
|
|
59
58
|
parseInt(d.value.style.lineHeight)
|
|
@@ -75,11 +74,11 @@ const oe = ["onClick"], he = /* @__PURE__ */ j({
|
|
|
75
74
|
});
|
|
76
75
|
},
|
|
77
76
|
{ immediate: !0 }
|
|
78
|
-
),
|
|
77
|
+
), j(() => {
|
|
79
78
|
x(
|
|
80
79
|
() => p.contentStyle,
|
|
81
80
|
(e) => {
|
|
82
|
-
|
|
81
|
+
Y(e.lineHeight) || f(() => {
|
|
83
82
|
const r = document.querySelector(
|
|
84
83
|
`#${w} .ant-alert-action`
|
|
85
84
|
), s = document.querySelector(
|
|
@@ -95,15 +94,15 @@ const oe = ["onClick"], he = /* @__PURE__ */ j({
|
|
|
95
94
|
}
|
|
96
95
|
);
|
|
97
96
|
});
|
|
98
|
-
const { b: T, e: o
|
|
97
|
+
const { b: T, e: o } = ee("ap-expand-alert"), K = Z("ap-expand-alert"), w = `${T()}-key-${Date.now()}-${(Math.random() * 1e6).toFixed(0)}`;
|
|
99
98
|
return D({
|
|
100
99
|
setExpand: k
|
|
101
|
-
}), (e, r) => (
|
|
100
|
+
}), (e, r) => (a(), i("div", {
|
|
102
101
|
id: w,
|
|
103
|
-
class: n([t(T)(),
|
|
102
|
+
class: n([t(T)(), t(K)])
|
|
104
103
|
}, [
|
|
105
|
-
|
|
106
|
-
type:
|
|
104
|
+
S(t(Q), {
|
|
105
|
+
type: R.value,
|
|
107
106
|
"show-icon": e.showIcon,
|
|
108
107
|
closable: e.closable,
|
|
109
108
|
class: n([t(o)("antAlert"), e.type == "card" ? "card-alert" : ""]),
|
|
@@ -111,17 +110,17 @@ const oe = ["onClick"], he = /* @__PURE__ */ j({
|
|
|
111
110
|
onClose: O
|
|
112
111
|
}, {
|
|
113
112
|
action: m(() => [
|
|
114
|
-
v.value ? (
|
|
113
|
+
v.value ? (a(), $(t(X), {
|
|
115
114
|
key: 0,
|
|
116
115
|
size: "small",
|
|
117
116
|
style: { "font-size": "12px", "padding-left": "16px" },
|
|
118
|
-
onClick: r[0] || (r[0] = (s) =>
|
|
117
|
+
onClick: r[0] || (r[0] = (s) => F())
|
|
119
118
|
}, {
|
|
120
119
|
default: m(() => [
|
|
121
|
-
|
|
120
|
+
C("span", {
|
|
122
121
|
class: n(t(o)("expandText"))
|
|
123
|
-
}, u(
|
|
124
|
-
|
|
122
|
+
}, u(M.value), 3),
|
|
123
|
+
S(t(P), {
|
|
125
124
|
class: n(N.value ? t(o)("expandIcon") : t(o)("collapseIcon"))
|
|
126
125
|
}, null, 8, ["class"])
|
|
127
126
|
]),
|
|
@@ -129,26 +128,26 @@ const oe = ["onClick"], he = /* @__PURE__ */ j({
|
|
|
129
128
|
})) : L("", !0)
|
|
130
129
|
]),
|
|
131
130
|
message: m(() => [
|
|
132
|
-
|
|
131
|
+
C("div", {
|
|
133
132
|
ref_key: "ellipsisBoxRef",
|
|
134
133
|
ref: d,
|
|
135
|
-
style: y({ ...
|
|
134
|
+
style: y({ ...q.value, ...e.contentStyle }),
|
|
136
135
|
class: n(t(o)("alertContent"))
|
|
137
136
|
}, [
|
|
138
137
|
H(e.$slots, "default", {}, () => [
|
|
139
|
-
t(A)(e.prefix) ? (
|
|
138
|
+
t(A)(e.prefix) ? (a(), i("span", {
|
|
140
139
|
key: 0,
|
|
141
140
|
class: n(t(o)("prefix")),
|
|
142
141
|
style: y(e.prefixStyle)
|
|
143
|
-
}, u(e.prefix), 7)) : (
|
|
142
|
+
}, u(e.prefix), 7)) : (a(), $(I(e.prefix), {
|
|
144
143
|
key: 1,
|
|
145
144
|
style: y(e.prefixStyle)
|
|
146
145
|
}, null, 8, ["style"])),
|
|
147
|
-
t(A)(e.data) ? (
|
|
146
|
+
t(A)(e.data) ? (a(), i("span", {
|
|
148
147
|
key: 2,
|
|
149
148
|
class: n(t(o)("text"))
|
|
150
|
-
}, u(e.data), 3)) : (
|
|
151
|
-
|
|
149
|
+
}, u(e.data), 3)) : (a(!0), i(E, { key: 3 }, G(e.data, (s, b) => (a(), i(E, { key: b }, [
|
|
150
|
+
S(t(U), {
|
|
152
151
|
title: e.tipTitle ? e.tipTitle : null
|
|
153
152
|
}, {
|
|
154
153
|
default: m(() => [
|
|
@@ -156,22 +155,22 @@ const oe = ["onClick"], he = /* @__PURE__ */ j({
|
|
|
156
155
|
record: s,
|
|
157
156
|
index: b
|
|
158
157
|
}, () => [
|
|
159
|
-
|
|
158
|
+
C("span", {
|
|
160
159
|
class: n(t(o)("showItem")),
|
|
161
|
-
onClick: (
|
|
162
|
-
}, u(e.mapLabel ? s[e.mapLabel] : s), 11,
|
|
160
|
+
onClick: (ae) => e.$emit("choose", s)
|
|
161
|
+
}, u(e.mapLabel ? s[e.mapLabel] : s), 11, te)
|
|
163
162
|
])
|
|
164
163
|
]),
|
|
165
164
|
_: 2
|
|
166
165
|
}, 1032, ["title"]),
|
|
167
|
-
b !== e.data.length - 1 ? (
|
|
166
|
+
b !== e.data.length - 1 ? (a(), i("span", {
|
|
168
167
|
key: 0,
|
|
169
168
|
class: n(t(o)("spliter")),
|
|
170
169
|
style: y(e.separatorStyle)
|
|
171
170
|
}, [
|
|
172
|
-
t(A)(e.separator) ? (
|
|
173
|
-
|
|
174
|
-
], 64)) : (
|
|
171
|
+
t(A)(e.separator) ? (a(), i(E, { key: 0 }, [
|
|
172
|
+
J(u(e.separator), 1)
|
|
173
|
+
], 64)) : (a(), $(I(e.separator), { key: 1 }))
|
|
175
174
|
], 6)) : L("", !0)
|
|
176
175
|
], 64))), 128))
|
|
177
176
|
])
|
|
@@ -183,5 +182,5 @@ const oe = ["onClick"], he = /* @__PURE__ */ j({
|
|
|
183
182
|
}
|
|
184
183
|
});
|
|
185
184
|
export {
|
|
186
|
-
|
|
185
|
+
ce as default
|
|
187
186
|
};
|
|
@@ -1,40 +1,38 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as f, computed as t, createVNode as i } from "vue";
|
|
2
2
|
import "../../config-provider/index.mjs";
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import { ApLadderProps as
|
|
6
|
-
import
|
|
7
|
-
import { useNamespace as
|
|
8
|
-
|
|
9
|
-
const w = /* @__PURE__ */ p({
|
|
3
|
+
import s from "./components/SimpleMode.mjs";
|
|
4
|
+
import p from "./components/ValueGroupMode.mjs";
|
|
5
|
+
import { ApLadderProps as k } from "./constans.mjs";
|
|
6
|
+
import b from "./style/index.mjs";
|
|
7
|
+
import { useNamespace as h } from "../../config-provider/hooks/use-namespace.mjs";
|
|
8
|
+
const M = /* @__PURE__ */ f({
|
|
10
9
|
name: "ApLadder",
|
|
11
|
-
props:
|
|
10
|
+
props: k(),
|
|
12
11
|
setup(e, {
|
|
13
12
|
slots: n
|
|
14
13
|
}) {
|
|
15
14
|
const {
|
|
16
|
-
b:
|
|
17
|
-
|
|
18
|
-
} = v("ap-ladder"), u = h("ap-ladder"), r = A("uiMode", "aplus"), m = o(() => e.labelValues === void 0 || e.labelValues.length === 0), c = o(() => e.labelValues.length > 0), f = o(() => e.labelAlign), s = (l) => {
|
|
15
|
+
b: o
|
|
16
|
+
} = h("ap-ladder"), d = b("ap-ladder"), r = t(() => e.labelValues === void 0 || e.labelValues.length === 0), u = t(() => e.labelValues.length > 0), m = t(() => e.labelAlign), c = (l) => {
|
|
19
17
|
l.link && window.open(l.link, "_blank"), typeof l.handleClickLink == "function" && l.handleClickLink();
|
|
20
|
-
},
|
|
21
|
-
return () =>
|
|
22
|
-
class: [
|
|
23
|
-
}, [
|
|
18
|
+
}, a = () => n.title?.() || null;
|
|
19
|
+
return () => i("div", {
|
|
20
|
+
class: [o(), d.value]
|
|
21
|
+
}, [r.value ? i(s, {
|
|
24
22
|
major: e.major,
|
|
25
23
|
minor: e.minor,
|
|
26
24
|
layout: e.layout
|
|
27
25
|
}, {
|
|
28
|
-
title: n.title ?
|
|
29
|
-
}) :
|
|
26
|
+
title: n.title ? a : void 0
|
|
27
|
+
}) : u.value ? i(p, {
|
|
30
28
|
labelValues: e.labelValues || [],
|
|
31
|
-
labelAlign:
|
|
32
|
-
onHandleClick:
|
|
29
|
+
labelAlign: m.value,
|
|
30
|
+
onHandleClick: c
|
|
33
31
|
}, {
|
|
34
|
-
title: n.title ?
|
|
32
|
+
title: n.title ? a : void 0
|
|
35
33
|
}) : null]);
|
|
36
34
|
}
|
|
37
35
|
});
|
|
38
36
|
export {
|
|
39
|
-
|
|
37
|
+
M as default
|
|
40
38
|
};
|
|
@@ -19,7 +19,7 @@ const i = (l) => {
|
|
|
19
19
|
},
|
|
20
20
|
[`${e}__value-group-label`]: {
|
|
21
21
|
display: "inline-block",
|
|
22
|
-
color:
|
|
22
|
+
color: l.textColor3,
|
|
23
23
|
wordBreak: "break-all",
|
|
24
24
|
position: "relative",
|
|
25
25
|
justifyContent: "center"
|
|
@@ -29,7 +29,7 @@ const i = (l) => {
|
|
|
29
29
|
padding: "0 3px"
|
|
30
30
|
},
|
|
31
31
|
[`${e}__value-group-value`]: {
|
|
32
|
-
color:
|
|
32
|
+
color: l.textColor1,
|
|
33
33
|
wordBreak: "break-all",
|
|
34
34
|
overflow: "hidden",
|
|
35
35
|
textOverflow: "ellipsis",
|
|
@@ -106,59 +106,34 @@ const i = (l) => {
|
|
|
106
106
|
},
|
|
107
107
|
[`${e}__major`]: {
|
|
108
108
|
lineHeight: l.lineHeight,
|
|
109
|
-
color:
|
|
109
|
+
color: l.textColor1
|
|
110
110
|
},
|
|
111
111
|
[`${e}__minor`]: {
|
|
112
112
|
lineHeight: l.lineHeight,
|
|
113
|
-
color:
|
|
113
|
+
color: l.textColor3
|
|
114
114
|
},
|
|
115
115
|
[`${e}__label`]: {
|
|
116
116
|
display: "inline-block",
|
|
117
|
-
color:
|
|
117
|
+
color: l.textColor3,
|
|
118
118
|
wordBreak: "break-all"
|
|
119
119
|
},
|
|
120
120
|
[`${e}__value`]: {
|
|
121
|
-
display:
|
|
121
|
+
display: l.textColor1,
|
|
122
122
|
wordBreak: "break-all"
|
|
123
123
|
},
|
|
124
124
|
[`${e}__unit`]: {
|
|
125
|
-
color:
|
|
125
|
+
color: l.textColor1
|
|
126
126
|
},
|
|
127
127
|
[`${e}__link, ${e}__link a`]: {
|
|
128
128
|
cursor: "pointer",
|
|
129
129
|
color: l.colorLink,
|
|
130
130
|
textDecoration: "none"
|
|
131
|
-
},
|
|
132
|
-
"&--admin": {
|
|
133
|
-
[e]: {
|
|
134
|
-
"&__value-group-label": {
|
|
135
|
-
color: "#999"
|
|
136
|
-
},
|
|
137
|
-
"&__value-group-value": {
|
|
138
|
-
color: "#333"
|
|
139
|
-
},
|
|
140
|
-
"&__major": {
|
|
141
|
-
color: "#333"
|
|
142
|
-
},
|
|
143
|
-
"&__minor": {
|
|
144
|
-
color: "#999"
|
|
145
|
-
},
|
|
146
|
-
"&__label": {
|
|
147
|
-
color: "#999"
|
|
148
|
-
},
|
|
149
|
-
"&__value": {
|
|
150
|
-
color: "#333"
|
|
151
|
-
},
|
|
152
|
-
"&__unit": {
|
|
153
|
-
color: "#333"
|
|
154
|
-
}
|
|
155
|
-
}
|
|
156
131
|
}
|
|
157
132
|
}
|
|
158
133
|
};
|
|
159
|
-
},
|
|
134
|
+
}, t = o("ApLadder", (l) => [
|
|
160
135
|
i(l)
|
|
161
136
|
]);
|
|
162
137
|
export {
|
|
163
|
-
|
|
138
|
+
t as default
|
|
164
139
|
};
|
|
@@ -1,26 +1,25 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { ApProductInfoProps as
|
|
1
|
+
import { defineComponent as f, h as t, createVNode as e, createTextVNode as v } from "vue";
|
|
2
|
+
import { ApProductInfoProps as y } from "./constans.mjs";
|
|
3
3
|
import "../../config-provider/index.mjs";
|
|
4
4
|
import { ApImage as h } from "../ap-image/index.mjs";
|
|
5
|
-
import { ApCopy as
|
|
6
|
-
import { Space as
|
|
5
|
+
import { ApCopy as s } from "../ap-copy/index.mjs";
|
|
6
|
+
import { Space as g, Tooltip as m } from "@aplus-frontend/antdv";
|
|
7
7
|
import { IconApAdFillWarn as k } from "@aplus-frontend/icon";
|
|
8
|
-
import
|
|
8
|
+
import b from "./style/index.mjs";
|
|
9
9
|
import { useNamespace as A } from "../../config-provider/hooks/use-namespace.mjs";
|
|
10
|
-
|
|
11
|
-
const B = /* @__PURE__ */ v({
|
|
10
|
+
const T = /* @__PURE__ */ f({
|
|
12
11
|
name: "ApProductInfo",
|
|
13
|
-
props:
|
|
12
|
+
props: y(),
|
|
14
13
|
setup(r) {
|
|
15
14
|
const {
|
|
16
|
-
b:
|
|
15
|
+
b: i,
|
|
17
16
|
e: o,
|
|
18
17
|
m: a
|
|
19
|
-
} = A("ap-product-info"), c =
|
|
18
|
+
} = A("ap-product-info"), c = b("ap-product-info"), p = (l) => typeof l.value == "function" ? l.value() : l.helpMessage ? t(g.Compact, {}, [t(s, {
|
|
20
19
|
text: l.value,
|
|
21
20
|
link: l.link,
|
|
22
21
|
textStyle: l.link ? "link" : "minor"
|
|
23
|
-
}), t(
|
|
22
|
+
}), t(m, {
|
|
24
23
|
placement: "top",
|
|
25
24
|
color: l.toolTipBgColor,
|
|
26
25
|
title: typeof l.helpMessage == "string" ? l.helpMessage : t(l.helpMessage)
|
|
@@ -29,14 +28,14 @@ const B = /* @__PURE__ */ v({
|
|
|
29
28
|
style: {
|
|
30
29
|
cursor: "pointer"
|
|
31
30
|
}
|
|
32
|
-
}))]) : t(
|
|
31
|
+
}))]) : t(s, {
|
|
33
32
|
text: l.value,
|
|
34
33
|
textStyle: l.link ? "link" : "minor",
|
|
35
34
|
link: l.link,
|
|
36
35
|
disableCopy: r.disableCopy
|
|
37
|
-
}, l.value)
|
|
36
|
+
}, l.value);
|
|
38
37
|
return () => e("div", {
|
|
39
|
-
class: [
|
|
38
|
+
class: [i(), c.value]
|
|
40
39
|
}, [e("div", {
|
|
41
40
|
class: o("img")
|
|
42
41
|
}, [e(h, {
|
|
@@ -46,25 +45,25 @@ const B = /* @__PURE__ */ v({
|
|
|
46
45
|
preview: r.preview
|
|
47
46
|
}, null)]), e("div", {
|
|
48
47
|
class: [o("content")]
|
|
49
|
-
}, [e(
|
|
48
|
+
}, [e(s, {
|
|
50
49
|
disableCopy: r.disableCopy
|
|
51
50
|
}, {
|
|
52
51
|
default: () => [r.title]
|
|
53
52
|
}), e("div", {
|
|
54
53
|
class: o("row-container")
|
|
55
|
-
}, [r.values.map((l,
|
|
56
|
-
const
|
|
54
|
+
}, [r.values.map((l, u) => {
|
|
55
|
+
const n = l.col === 2, d = l.col !== 2 && u % 2 === 0;
|
|
57
56
|
return e("div", {
|
|
58
57
|
key: JSON.stringify(l),
|
|
59
|
-
class: [o("row-item"), a(
|
|
58
|
+
class: [o("row-item"), a(n ? "full" : "half")]
|
|
60
59
|
}, [e("div", {
|
|
61
60
|
class: [o("item")]
|
|
62
61
|
}, [l.label && e("div", {
|
|
63
62
|
class: o("label")
|
|
64
|
-
}, [l.label, e("span", null, [
|
|
65
|
-
class: [o("value"), !
|
|
63
|
+
}, [l.label, e("span", null, [v(":")])]), e("div", {
|
|
64
|
+
class: [o("value"), !n && a("overflow")],
|
|
66
65
|
title: typeof l.value != "function" ? String(l.value || "") : ""
|
|
67
|
-
}, [p(l)])]),
|
|
66
|
+
}, [p(l)])]), d && e("div", {
|
|
68
67
|
class: o("divider"),
|
|
69
68
|
style: {
|
|
70
69
|
right: 0
|
|
@@ -76,5 +75,5 @@ const B = /* @__PURE__ */ v({
|
|
|
76
75
|
}
|
|
77
76
|
});
|
|
78
77
|
export {
|
|
79
|
-
|
|
78
|
+
T as default
|
|
80
79
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { genComponentStyleHook as
|
|
2
|
-
const
|
|
3
|
-
const { componentCls: e } =
|
|
1
|
+
import { genComponentStyleHook as o } from "../../../utils/cssinjs/index.mjs";
|
|
2
|
+
const l = (i) => {
|
|
3
|
+
const { componentCls: e } = i;
|
|
4
4
|
return {
|
|
5
5
|
[e]: {
|
|
6
6
|
display: "flex",
|
|
@@ -47,7 +47,7 @@ const i = (o) => {
|
|
|
47
47
|
width: "100%"
|
|
48
48
|
},
|
|
49
49
|
[`${e}__label`]: {
|
|
50
|
-
color:
|
|
50
|
+
color: i.textColor3,
|
|
51
51
|
flexShrink: 0,
|
|
52
52
|
span: {
|
|
53
53
|
display: "inline-block",
|
|
@@ -56,35 +56,19 @@ const i = (o) => {
|
|
|
56
56
|
},
|
|
57
57
|
[`${e}__value`]: {
|
|
58
58
|
maxWidth: "300px",
|
|
59
|
-
color:
|
|
59
|
+
color: i.textColor3,
|
|
60
60
|
overflow: "hidden",
|
|
61
61
|
textOverflow: "ellipsis",
|
|
62
62
|
whiteSpace: "nowrap"
|
|
63
63
|
},
|
|
64
64
|
[`${e}--link`]: {
|
|
65
|
-
color:
|
|
65
|
+
color: i.colorLink,
|
|
66
66
|
cursor: "pointer"
|
|
67
|
-
},
|
|
68
|
-
"&--admin": {
|
|
69
|
-
[`${e}`]: {
|
|
70
|
-
"&__title": {
|
|
71
|
-
color: "#333"
|
|
72
|
-
},
|
|
73
|
-
"&__label": {
|
|
74
|
-
color: "#999"
|
|
75
|
-
},
|
|
76
|
-
"&__value": {
|
|
77
|
-
color: "#999"
|
|
78
|
-
},
|
|
79
|
-
"&--link": {
|
|
80
|
-
color: "rgb(0, 112, 255)"
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
67
|
}
|
|
84
68
|
}
|
|
85
69
|
};
|
|
86
|
-
}, n =
|
|
87
|
-
i
|
|
70
|
+
}, n = o("ApProductInfo", (i) => [
|
|
71
|
+
l(i)
|
|
88
72
|
]);
|
|
89
73
|
export {
|
|
90
74
|
n as default
|