ling-yun-custom-components 0.0.10 → 0.0.22
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/BatchImport.mjs +50 -50
- package/es/CustomDialog.mjs +1 -1
- package/es/CustomDropdown.mjs +24 -24
- package/es/CustomPagination.mjs +1 -1
- package/es/CustomSelect.mjs +1 -1
- package/es/FileList.mjs +1 -1
- package/es/GradientButton.mjs +23 -23
- package/es/IconEmpty.mjs +1 -1
- package/es/IconRenderer.mjs +21 -18
- package/es/IconSelect.mjs +33 -33
- package/es/PaginationTable.mjs +37 -37
- package/es/SearchBar.mjs +1 -1
- package/es/TreeSelect.mjs +25 -25
- package/es/UpdatePasswordDialog.mjs +21 -21
- package/es/UploadFile.mjs +1 -1
- package/es/chunks/{index.D4Kbv-m1.js → index.CRROL-C7.js} +100 -100
- package/es/chunks/{index.DlooXR0t.js → index._uj6b1Kd.js} +2953 -3583
- package/es/chunks/{layout.C0UEMbnF.js → layout.3r4JjCjq.js} +1 -1
- package/es/chunks/layout.B8mwOOqx.js +149 -0
- package/es/chunks/{layout.LCKaV7EX.js → layout.BHroZ9U9.js} +1 -1
- package/es/chunks/{layout.DeAFov0o.js → layout.BSdpu71J.js} +1 -1
- package/es/chunks/{layout.6MxjcpGc.js → layout.BZ373u9D.js} +43 -43
- package/es/chunks/{layout.CnANFnM1.js → layout.Bg387XYI.js} +31 -31
- package/es/chunks/{layout._A_rHZM7.js → layout.BsiNPYtX.js} +1 -1
- package/es/chunks/{layout.ypvwQzq5.js → layout.BzQrppiO.js} +19 -19
- package/es/chunks/{layout.Dvw3u-s5.js → layout.CSYJ22Ac.js} +22 -22
- package/es/chunks/{layout.CtWHo87D.js → layout.CmH2-6H-.js} +1 -1
- package/es/chunks/{layout.BJE8rMzK.js → layout.D7cg-xRZ.js} +2 -2
- package/es/chunks/layout.DBgjqaxe.js +66 -0
- package/es/chunks/{layout.t3qD0LTW.js → layout.DLUJzpco.js} +4 -4
- package/es/chunks/{layout.Day1LJyl.js → layout.Epzao23T.js} +9 -9
- package/es/chunks/{layout.f58eO4Hr.js → layout.dhOtQkoC.js} +13 -13
- package/es/chunks/{layout.1y3OJ-ea.js → layout.iUFnoCjZ.js} +2 -2
- package/es/chunks/{layout.CTQtuC78.js → layout.o_B8gly4.js} +2 -2
- package/es/chunks/{layout.CiNI5oQK.js → layout.vvR_4ki7.js} +48 -48
- package/lib/BatchImport.js +1 -1
- package/lib/CustomDialog.js +1 -1
- package/lib/CustomDropdown.js +1 -1
- package/lib/CustomPagination.js +1 -1
- package/lib/CustomSelect.js +1 -1
- package/lib/FileList.js +1 -1
- package/lib/GradientButton.js +1 -1
- package/lib/IconEmpty.js +1 -1
- package/lib/IconRenderer.js +1 -1
- package/lib/IconSelect.js +1 -1
- package/lib/PaginationTable.js +1 -1
- package/lib/SearchBar.js +1 -1
- package/lib/TreeSelect.js +1 -1
- package/lib/UpdatePasswordDialog.js +1 -1
- package/lib/UploadFile.js +1 -1
- package/lib/chunks/index.BKVX0AJJ.js +23 -0
- package/lib/chunks/{index.CrvqvcN9.js → index.Cm0zRaZN.js} +2 -2
- package/lib/chunks/{layout.BXdjRFbn.js → layout.-2KgXQBu.js} +1 -1
- package/lib/chunks/layout.7-8MCU-f.js +1 -0
- package/lib/chunks/{layout.CoSBrO12.js → layout.9Q_gwznp.js} +1 -1
- package/lib/chunks/layout.B8EsRYB6.js +1 -0
- package/lib/chunks/layout.B8d4J538.js +1 -0
- package/lib/chunks/{layout.CwA4IJ1g.js → layout.BeQpU6RU.js} +1 -1
- package/lib/chunks/{layout.5iOiFlVu.js → layout.BqWe_qix.js} +1 -1
- package/lib/chunks/{layout.-yZzrp74.js → layout.C2BGVUSH.js} +1 -1
- package/lib/chunks/{layout.DDTIwGYp.js → layout.D3OyheOl.js} +1 -1
- package/lib/chunks/layout.DE2WIKAN.js +1 -0
- package/lib/chunks/{layout.BhL14Rqh.js → layout.DWbm8gXV.js} +1 -1
- package/lib/chunks/layout.DYKJPi9L.js +1 -0
- package/lib/chunks/layout.DYnlhiPO.js +1 -0
- package/lib/chunks/layout.Dt0IRZ49.js +1 -0
- package/lib/chunks/layout.Js61I3wA.js +1 -0
- package/lib/chunks/layout.XtG7xOYE.js +1 -0
- package/lib/chunks/{layout.CDg3sCTi.js → layout.s-xNK0r5.js} +1 -1
- package/lib/chunks/{layout.DfiLurg1.js → layout.vff7gZ3-.js} +1 -1
- package/package.json +15 -15
- package/es/chunks/layout.ZxPdKhRp.js +0 -149
- package/lib/chunks/index.Bixsw9fA.js +0 -23
- package/lib/chunks/layout.2PAIPzYY.js +0 -1
- package/lib/chunks/layout.BBNd1hLQ.js +0 -1
- package/lib/chunks/layout.BNJsxQ2g.js +0 -1
- package/lib/chunks/layout.BmQYiD_b.js +0 -1
- package/lib/chunks/layout.CeVldGUL.js +0 -1
- package/lib/chunks/layout.CjJiAY0w.js +0 -1
- package/lib/chunks/layout.DOS2ezSW.js +0 -1
- package/lib/chunks/layout.D_TxPvRy.js +0 -1
package/es/BatchImport.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { w as
|
|
2
|
-
import { createElementBlock as x, openBlock as s, Fragment as q, createElementVNode as r, toDisplayString as w, ref as
|
|
3
|
-
import { ElDialog as
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
import {
|
|
7
|
-
const
|
|
1
|
+
import { w as z } from "./chunks/index.bCzIhWFw.js";
|
|
2
|
+
import { createElementBlock as x, openBlock as s, Fragment as q, createElementVNode as r, toDisplayString as w, ref as C, computed as g, createBlock as V, unref as u, withCtx as i, createCommentVNode as c, mergeProps as L, createVNode as f, createTextVNode as D } from "vue";
|
|
3
|
+
import { ElDialog as P, ElIcon as Q, ElButton as R } from "element-plus";
|
|
4
|
+
import { emitsMap as B, uploadFileType as h, codeMap as _, messageSuccess as A } from "ling-yun-methods";
|
|
5
|
+
import G from "./chunks/layout.BHroZ9U9.js";
|
|
6
|
+
import { IconQuery as H } from "color-message-lingyun-vue";
|
|
7
|
+
const J = {
|
|
8
8
|
__name: "ImportResultContent",
|
|
9
9
|
props: {
|
|
10
10
|
uploadResData: {
|
|
@@ -17,7 +17,7 @@ const K = {
|
|
|
17
17
|
}
|
|
18
18
|
},
|
|
19
19
|
setup(o) {
|
|
20
|
-
const d = o,
|
|
20
|
+
const d = o, F = () => {
|
|
21
21
|
const { ossUrl: v, fileName: t } = d.uploadResData;
|
|
22
22
|
d.templateConfig.downloadErrorFile(t, v, d.templateConfig.isNeedTransform);
|
|
23
23
|
};
|
|
@@ -28,12 +28,12 @@ const K = {
|
|
|
28
28
|
r("span", {
|
|
29
29
|
class: "pointer",
|
|
30
30
|
style: { color: "var(--error-color-1)" },
|
|
31
|
-
onClick:
|
|
31
|
+
onClick: F
|
|
32
32
|
}, " 错误报告 ")
|
|
33
33
|
])
|
|
34
34
|
], 64));
|
|
35
35
|
}
|
|
36
|
-
},
|
|
36
|
+
}, K = {
|
|
37
37
|
key: 0,
|
|
38
38
|
class: "flex items-center"
|
|
39
39
|
}, W = {
|
|
@@ -76,14 +76,14 @@ const K = {
|
|
|
76
76
|
}
|
|
77
77
|
},
|
|
78
78
|
emits: [
|
|
79
|
-
|
|
79
|
+
B.updateModelValue,
|
|
80
80
|
"success",
|
|
81
81
|
"error",
|
|
82
82
|
"cancel",
|
|
83
83
|
"uploadSuccess"
|
|
84
84
|
],
|
|
85
85
|
setup(o, { emit: d }) {
|
|
86
|
-
const
|
|
86
|
+
const F = {
|
|
87
87
|
templateFileName: "导入模板.xlsx"
|
|
88
88
|
}, v = {
|
|
89
89
|
uploadFileType: [h.xlsx, h.xls],
|
|
@@ -91,117 +91,117 @@ const K = {
|
|
|
91
91
|
multiple: !1,
|
|
92
92
|
rowCount: 1,
|
|
93
93
|
maxCount: 1
|
|
94
|
-
}, t = o,
|
|
94
|
+
}, t = o, T = d, p = C([]), m = g({
|
|
95
95
|
get() {
|
|
96
96
|
return t.modelValue;
|
|
97
97
|
},
|
|
98
98
|
set(l) {
|
|
99
|
-
|
|
99
|
+
T(B.updateModelValue, l);
|
|
100
100
|
}
|
|
101
|
-
}),
|
|
101
|
+
}), I = g(() => n.value === "result" ? "导入结果" : t.title), k = g(() => ({
|
|
102
102
|
...v,
|
|
103
103
|
...t.uploadFileConfig
|
|
104
|
-
})),
|
|
105
|
-
...
|
|
104
|
+
})), y = g(() => ({
|
|
105
|
+
...F,
|
|
106
106
|
...t.templateConfig
|
|
107
|
-
})),
|
|
108
|
-
|
|
109
|
-
}, n =
|
|
107
|
+
})), M = () => {
|
|
108
|
+
y.value.downloadTemplate({}, y.value.templateFileName);
|
|
109
|
+
}, n = C("upload"), b = C({}), U = () => {
|
|
110
110
|
m.value = !1;
|
|
111
111
|
};
|
|
112
|
-
function
|
|
113
|
-
const a = l.name.split(".").pop(),
|
|
114
|
-
return new File([l],
|
|
112
|
+
function j(l, e) {
|
|
113
|
+
const a = l.name.split(".").pop(), N = `${e}.${a}`;
|
|
114
|
+
return new File([l], N, {
|
|
115
115
|
type: l.type,
|
|
116
116
|
lastModified: l.lastModified
|
|
117
117
|
});
|
|
118
118
|
}
|
|
119
|
-
const
|
|
119
|
+
const O = C(null), $ = async () => {
|
|
120
120
|
const l = t.uploadFileConfig?.fileName || p.value?.[0]?.raw?.name;
|
|
121
|
-
|
|
122
|
-
...
|
|
123
|
-
file:
|
|
121
|
+
k.value?.apiConfig({
|
|
122
|
+
...k.value?.params,
|
|
123
|
+
file: j(p.value?.[0]?.raw, l)
|
|
124
124
|
}).then((e) => {
|
|
125
125
|
const { data: a } = e;
|
|
126
|
-
|
|
127
|
-
const { failureTotal:
|
|
128
|
-
e.code ===
|
|
126
|
+
O.value = a;
|
|
127
|
+
const { failureTotal: N, successTotal: S } = a;
|
|
128
|
+
e.code === _.success && (N ? (n.value = "result", b.value = a, S && T("uploadSuccess")) : (A(`文件导入成功,共导入数据:${S}条`), T("uploadSuccess"), m.value = !1));
|
|
129
129
|
});
|
|
130
130
|
}, E = () => {
|
|
131
131
|
m.value = !1;
|
|
132
132
|
};
|
|
133
|
-
return (l, e) => (s(), V(u(
|
|
133
|
+
return (l, e) => (s(), V(u(P), {
|
|
134
134
|
modelValue: m.value,
|
|
135
135
|
"onUpdate:modelValue": e[1] || (e[1] = (a) => m.value = a),
|
|
136
|
-
title:
|
|
136
|
+
title: I.value,
|
|
137
137
|
width: o.width,
|
|
138
138
|
"close-on-click-modal": !1,
|
|
139
139
|
"close-on-press-escape": !1,
|
|
140
140
|
onClose: E
|
|
141
141
|
}, {
|
|
142
142
|
footer: i(() => [
|
|
143
|
-
n.value === "upload" ? (s(), x("div",
|
|
144
|
-
|
|
145
|
-
f(u(
|
|
143
|
+
n.value === "upload" ? (s(), x("div", K, [
|
|
144
|
+
y.value?.downloadTemplate ? (s(), x("div", W, [
|
|
145
|
+
f(u(Q), {
|
|
146
146
|
size: 14,
|
|
147
147
|
color: "var(--text-color-4)"
|
|
148
148
|
}, {
|
|
149
149
|
default: i(() => [
|
|
150
|
-
f(u(
|
|
150
|
+
f(u(H))
|
|
151
151
|
]),
|
|
152
152
|
_: 1
|
|
153
153
|
}),
|
|
154
154
|
e[2] || (e[2] = r("div", { class: "text-74798c pd-l-4" }, "还没有模板?点击下载", -1)),
|
|
155
155
|
r("div", {
|
|
156
156
|
class: "text-3b64ff pointer",
|
|
157
|
-
onClick:
|
|
157
|
+
onClick: M
|
|
158
158
|
}, " 《" + w(o.templateName) + "模板》 ", 1)
|
|
159
159
|
])) : c("", !0),
|
|
160
|
-
f(u(
|
|
160
|
+
f(u(R), { onClick: E }, {
|
|
161
161
|
default: i(() => [...e[3] || (e[3] = [
|
|
162
|
-
|
|
162
|
+
D("取消", -1)
|
|
163
163
|
])]),
|
|
164
164
|
_: 1
|
|
165
165
|
}),
|
|
166
|
-
f(u(
|
|
166
|
+
f(u(R), {
|
|
167
167
|
type: "primary",
|
|
168
168
|
onClick: $,
|
|
169
169
|
disabled: !p.value?.length
|
|
170
170
|
}, {
|
|
171
171
|
default: i(() => [...e[4] || (e[4] = [
|
|
172
|
-
|
|
172
|
+
D(" 确认 ", -1)
|
|
173
173
|
])]),
|
|
174
174
|
_: 1
|
|
175
175
|
}, 8, ["disabled"])
|
|
176
176
|
])) : c("", !0),
|
|
177
177
|
n.value === "result" ? (s(), x("div", X, [
|
|
178
|
-
f(u(
|
|
178
|
+
f(u(R), {
|
|
179
179
|
type: "primary",
|
|
180
|
-
onClick:
|
|
180
|
+
onClick: U
|
|
181
181
|
}, {
|
|
182
182
|
default: i(() => [...e[5] || (e[5] = [
|
|
183
|
-
|
|
183
|
+
D("我知道了", -1)
|
|
184
184
|
])]),
|
|
185
185
|
_: 1
|
|
186
186
|
})
|
|
187
187
|
])) : c("", !0)
|
|
188
188
|
]),
|
|
189
189
|
default: i(() => [
|
|
190
|
-
n.value === "upload" ? (s(), V(
|
|
190
|
+
n.value === "upload" ? (s(), V(G, L({
|
|
191
191
|
key: 0,
|
|
192
192
|
modelValue: p.value,
|
|
193
193
|
"onUpdate:modelValue": e[0] || (e[0] = (a) => p.value = a)
|
|
194
|
-
},
|
|
195
|
-
n.value === "result" ? (s(), V(
|
|
194
|
+
}, k.value), null, 16, ["modelValue"])) : c("", !0),
|
|
195
|
+
n.value === "result" ? (s(), V(J, {
|
|
196
196
|
key: 1,
|
|
197
|
-
templateConfig:
|
|
198
|
-
uploadResData:
|
|
197
|
+
templateConfig: y.value,
|
|
198
|
+
uploadResData: b.value
|
|
199
199
|
}, null, 8, ["templateConfig", "uploadResData"])) : c("", !0)
|
|
200
200
|
]),
|
|
201
201
|
_: 1
|
|
202
202
|
}, 8, ["modelValue", "title", "width"]));
|
|
203
203
|
}
|
|
204
|
-
}), se =
|
|
204
|
+
}), se = z(Y);
|
|
205
205
|
export {
|
|
206
206
|
se as BatchImport,
|
|
207
207
|
se as default
|
package/es/CustomDialog.mjs
CHANGED
package/es/CustomDropdown.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { w as v } from "./chunks/index.bCzIhWFw.js";
|
|
2
|
-
import { createBlock as m, openBlock as r, unref as d, mergeProps as C, withCtx as
|
|
3
|
-
import { ElDropdown as
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { _ as
|
|
7
|
-
import './assets/CustomDropdown.css';const
|
|
2
|
+
import { createBlock as m, openBlock as r, unref as d, mergeProps as C, withCtx as n, renderSlot as h, createElementVNode as c, createVNode as s, toDisplayString as p, createElementBlock as V, createCommentVNode as D, Fragment as E, renderList as I } from "vue";
|
|
3
|
+
import { ElDropdown as N, ElIcon as S, ElDropdownMenu as B, ElDropdownItem as x } from "element-plus";
|
|
4
|
+
import { emitsMap as i } from "ling-yun-methods";
|
|
5
|
+
import { IconDown as M } from "color-message-lingyun-vue";
|
|
6
|
+
import { _ as O } from "./chunks/_plugin-vue_export-helper.CHgC5LLL.js";
|
|
7
|
+
import './assets/CustomDropdown.css';const T = { class: "custom-dropdown-trigger" }, $ = /* @__PURE__ */ Object.assign({
|
|
8
8
|
name: "CustomDropdown"
|
|
9
9
|
}, {
|
|
10
10
|
__name: "layout",
|
|
@@ -77,20 +77,20 @@ import './assets/CustomDropdown.css';const M = { class: "custom-dropdown-trigger
|
|
|
77
77
|
"visible-change",
|
|
78
78
|
"click"
|
|
79
79
|
],
|
|
80
|
-
setup(e, { expose:
|
|
80
|
+
setup(e, { expose: f, emit: g }) {
|
|
81
81
|
const b = e, l = g, u = (o) => {
|
|
82
|
-
const
|
|
82
|
+
const a = b.items.find(
|
|
83
83
|
(t) => t.command === o || t.value === o || t === o
|
|
84
84
|
);
|
|
85
|
-
l(i.change, o,
|
|
85
|
+
l(i.change, o, a), l(i.updateModelValue, o, a), l("command", o, a);
|
|
86
86
|
}, w = (o) => {
|
|
87
87
|
l("visible-change", o);
|
|
88
88
|
}, k = () => {
|
|
89
89
|
l("click");
|
|
90
90
|
};
|
|
91
|
-
return
|
|
91
|
+
return f({
|
|
92
92
|
handleCommand: u
|
|
93
|
-
}), (o,
|
|
93
|
+
}), (o, a) => (r(), m(d(N), C({
|
|
94
94
|
trigger: e.trigger,
|
|
95
95
|
placement: e.placement,
|
|
96
96
|
disabled: e.disabled,
|
|
@@ -101,19 +101,19 @@ import './assets/CustomDropdown.css';const M = { class: "custom-dropdown-trigger
|
|
|
101
101
|
onVisibleChange: w,
|
|
102
102
|
onClick: k
|
|
103
103
|
}, o.$attrs), {
|
|
104
|
-
dropdown:
|
|
105
|
-
s(d(
|
|
106
|
-
default:
|
|
104
|
+
dropdown: n(() => [
|
|
105
|
+
s(d(B), null, {
|
|
106
|
+
default: n(() => [
|
|
107
107
|
h(o.$slots, "dropdown", {}, () => [
|
|
108
|
-
e.items && e.items.length > 0 ? (r(!0), V(E, { key: 0 },
|
|
108
|
+
e.items && e.items.length > 0 ? (r(!0), V(E, { key: 0 }, I(e.items, (t, y) => (r(), m(d(x), {
|
|
109
109
|
key: t.key || y,
|
|
110
110
|
command: t.command || t.value || t,
|
|
111
111
|
disabled: t.disabled,
|
|
112
112
|
divided: t.divided,
|
|
113
113
|
icon: t.icon
|
|
114
114
|
}, {
|
|
115
|
-
default:
|
|
116
|
-
c("span", null,
|
|
115
|
+
default: n(() => [
|
|
116
|
+
c("span", null, p(t.label || t.text || t), 1)
|
|
117
117
|
]),
|
|
118
118
|
_: 2
|
|
119
119
|
}, 1032, ["command", "disabled", "divided", "icon"]))), 128)) : D("", !0)
|
|
@@ -122,13 +122,13 @@ import './assets/CustomDropdown.css';const M = { class: "custom-dropdown-trigger
|
|
|
122
122
|
_: 3
|
|
123
123
|
})
|
|
124
124
|
]),
|
|
125
|
-
default:
|
|
125
|
+
default: n(() => [
|
|
126
126
|
h(o.$slots, "default", {}, () => [
|
|
127
|
-
c("div",
|
|
128
|
-
c("span", null,
|
|
129
|
-
s(d(
|
|
130
|
-
default:
|
|
131
|
-
s(d(
|
|
127
|
+
c("div", T, [
|
|
128
|
+
c("span", null, p(e.placeholder), 1),
|
|
129
|
+
s(d(S), { class: "dropdown-icon" }, {
|
|
130
|
+
default: n(() => [
|
|
131
|
+
s(d(M))
|
|
132
132
|
]),
|
|
133
133
|
_: 1
|
|
134
134
|
})
|
|
@@ -138,7 +138,7 @@ import './assets/CustomDropdown.css';const M = { class: "custom-dropdown-trigger
|
|
|
138
138
|
_: 3
|
|
139
139
|
}, 16, ["trigger", "placement", "disabled", "hide-on-click", "show-timeout", "hide-timeout"]));
|
|
140
140
|
}
|
|
141
|
-
}), j = /* @__PURE__ */
|
|
141
|
+
}), j = /* @__PURE__ */ O($, [["__scopeId", "data-v-07e365ee"]]), G = v(j);
|
|
142
142
|
export {
|
|
143
143
|
G as CustomDropdown,
|
|
144
144
|
G as default
|
package/es/CustomPagination.mjs
CHANGED
package/es/CustomSelect.mjs
CHANGED
package/es/FileList.mjs
CHANGED
package/es/GradientButton.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { w as z } from "./chunks/index.bCzIhWFw.js";
|
|
2
|
-
import { computed as
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
2
|
+
import { computed as l, createElementBlock as c, openBlock as i, normalizeStyle as s, createElementVNode as m, normalizeClass as u, createBlock as g, createCommentVNode as b, unref as d, withCtx as S, resolveDynamicComponent as w, Fragment as $, renderList as B, toDisplayString as j } from "vue";
|
|
3
|
+
import { textDirection as a } from "ling-yun-methods";
|
|
4
|
+
import { IconAdd as I } from "color-message-lingyun-vue";
|
|
5
5
|
import { ElIcon as O } from "element-plus";
|
|
6
6
|
import { _ as R } from "./chunks/_plugin-vue_export-helper.CHgC5LLL.js";
|
|
7
|
-
import './assets/GradientButton.css';const
|
|
7
|
+
import './assets/GradientButton.css';const D = /* @__PURE__ */ Object.assign({
|
|
8
8
|
name: "GradientButton"
|
|
9
9
|
}, {
|
|
10
10
|
__name: "layout",
|
|
@@ -32,7 +32,7 @@ import './assets/GradientButton.css';const E = /* @__PURE__ */ Object.assign({
|
|
|
32
32
|
// 文字排列方向:horizontal | vertical
|
|
33
33
|
direction: {
|
|
34
34
|
type: String,
|
|
35
|
-
default:
|
|
35
|
+
default: a.horizontal
|
|
36
36
|
},
|
|
37
37
|
// 图标
|
|
38
38
|
icon: {
|
|
@@ -41,26 +41,26 @@ import './assets/GradientButton.css';const E = /* @__PURE__ */ Object.assign({
|
|
|
41
41
|
}
|
|
42
42
|
},
|
|
43
43
|
setup(o) {
|
|
44
|
-
const n = o, f =
|
|
44
|
+
const n = o, f = l(() => (n.text.content || "").split("") || []), x = l(() => {
|
|
45
45
|
const { gradientColors: t, borderRadius: e } = n.button;
|
|
46
46
|
return {
|
|
47
47
|
background: `linear-gradient(180deg, ${t?.[0]}, ${t?.[1]})`,
|
|
48
48
|
borderRadius: `${e}px`
|
|
49
49
|
};
|
|
50
|
-
}), v =
|
|
50
|
+
}), v = l(() => {
|
|
51
51
|
const { borderRadius: t, padding: e, background: r } = n.button;
|
|
52
52
|
return {
|
|
53
53
|
borderRadius: `${t}px`,
|
|
54
54
|
padding: e,
|
|
55
55
|
background: r
|
|
56
56
|
};
|
|
57
|
-
}),
|
|
57
|
+
}), y = l(() => ({
|
|
58
58
|
"flex items-center justify-center overflow-hidden": !0,
|
|
59
|
-
"flex-col": n.direction ===
|
|
60
|
-
})),
|
|
59
|
+
"flex-col": n.direction === a.vertical
|
|
60
|
+
})), p = l(() => {
|
|
61
61
|
const { gradientColors: t, color: e } = n.text;
|
|
62
62
|
return t?.[0] || e;
|
|
63
|
-
}), k =
|
|
63
|
+
}), k = l(() => {
|
|
64
64
|
const { gradientColors: t, fontSize: e, color: r } = n.text, C = t?.length ? `linear-gradient(180deg, ${t?.[0]}, ${t?.[1]})` : "transparent", h = {
|
|
65
65
|
backgroundClip: "text",
|
|
66
66
|
WebkitBackgroundClip: "text",
|
|
@@ -73,38 +73,38 @@ import './assets/GradientButton.css';const E = /* @__PURE__ */ Object.assign({
|
|
|
73
73
|
...t?.length ? h : {}
|
|
74
74
|
};
|
|
75
75
|
});
|
|
76
|
-
return (t, e) => (
|
|
76
|
+
return (t, e) => (i(), c("div", {
|
|
77
77
|
class: "gradient-btn pointer overflow-hidden",
|
|
78
|
-
style: s(
|
|
78
|
+
style: s(x.value)
|
|
79
79
|
}, [
|
|
80
80
|
m("div", {
|
|
81
81
|
class: "gradient-btn-content overflow-hidden",
|
|
82
82
|
style: s(v.value)
|
|
83
83
|
}, [
|
|
84
84
|
m("div", {
|
|
85
|
-
class: u(
|
|
85
|
+
class: u(y.value)
|
|
86
86
|
}, [
|
|
87
|
-
o.icon ? (
|
|
87
|
+
o.icon ? (i(), g(d(O), {
|
|
88
88
|
key: 0,
|
|
89
89
|
size: o.text.fontSize,
|
|
90
|
-
color:
|
|
90
|
+
color: p.value,
|
|
91
91
|
class: u({
|
|
92
|
-
"mg-r-4": o.direction === d(
|
|
93
|
-
"mg-b-4": o.direction === d(
|
|
92
|
+
"mg-r-4": o.direction === d(a).horizontal,
|
|
93
|
+
"mg-b-4": o.direction === d(a).vertical
|
|
94
94
|
})
|
|
95
95
|
}, {
|
|
96
96
|
default: S(() => [
|
|
97
|
-
(
|
|
97
|
+
(i(), g(w(o.icon)))
|
|
98
98
|
]),
|
|
99
99
|
_: 1
|
|
100
100
|
}, 8, ["size", "color", "class"])) : b("", !0),
|
|
101
|
-
f.value?.length ? (
|
|
101
|
+
f.value?.length ? (i(), c("div", {
|
|
102
102
|
key: 1,
|
|
103
103
|
class: u(["overflow-hidden flex", {
|
|
104
|
-
"flex-col": o.direction === d(
|
|
104
|
+
"flex-col": o.direction === d(a).vertical
|
|
105
105
|
}])
|
|
106
106
|
}, [
|
|
107
|
-
(
|
|
107
|
+
(i(!0), c($, null, B(f.value, (r) => (i(), c("div", {
|
|
108
108
|
style: s(k.value),
|
|
109
109
|
key: r
|
|
110
110
|
}, j(r), 5))), 128))
|
|
@@ -113,7 +113,7 @@ import './assets/GradientButton.css';const E = /* @__PURE__ */ Object.assign({
|
|
|
113
113
|
], 4)
|
|
114
114
|
], 4));
|
|
115
115
|
}
|
|
116
|
-
}),
|
|
116
|
+
}), E = /* @__PURE__ */ R(D, [["__scopeId", "data-v-5fab0460"]]), W = z(E);
|
|
117
117
|
export {
|
|
118
118
|
W as GradientButton,
|
|
119
119
|
W as default
|
package/es/IconEmpty.mjs
CHANGED
package/es/IconRenderer.mjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { w as
|
|
2
|
-
import {
|
|
3
|
-
import { ElIcon as
|
|
4
|
-
import { c as
|
|
5
|
-
const
|
|
1
|
+
import { w as m } from "./chunks/index.bCzIhWFw.js";
|
|
2
|
+
import { createElementBlock as c, openBlock as t, Fragment as l, createTextVNode as i, createBlock as r, createCommentVNode as s, unref as n, mergeProps as u, withCtx as f, resolveDynamicComponent as p } from "vue";
|
|
3
|
+
import { ElIcon as d } from "element-plus";
|
|
4
|
+
import { c as y } from "./chunks/global.DVwnOczb.js";
|
|
5
|
+
const N = /* @__PURE__ */ Object.assign({
|
|
6
6
|
name: "IconRenderer"
|
|
7
7
|
}, {
|
|
8
8
|
__name: "layout",
|
|
@@ -24,19 +24,22 @@ const f = /* @__PURE__ */ Object.assign({
|
|
|
24
24
|
}
|
|
25
25
|
},
|
|
26
26
|
setup(e) {
|
|
27
|
-
return (
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
27
|
+
return (a, o) => (t(), c(l, null, [
|
|
28
|
+
o[0] || (o[0] = i("000 ", -1)),
|
|
29
|
+
e.iconName ? (t(), r(n(d), u({
|
|
30
|
+
key: 0,
|
|
31
|
+
size: e.size,
|
|
32
|
+
color: e.color
|
|
33
|
+
}, a.$attrs), {
|
|
34
|
+
default: f(() => [
|
|
35
|
+
(t(), r(p(n(y)[e.iconName])))
|
|
36
|
+
]),
|
|
37
|
+
_: 1
|
|
38
|
+
}, 16, ["size", "color"])) : s("", !0)
|
|
39
|
+
], 64));
|
|
37
40
|
}
|
|
38
|
-
}),
|
|
41
|
+
}), I = m(N);
|
|
39
42
|
export {
|
|
40
|
-
|
|
41
|
-
|
|
43
|
+
I as IconRenderer,
|
|
44
|
+
I as default
|
|
42
45
|
};
|
package/es/IconSelect.mjs
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { w as
|
|
2
|
-
import { ref as p, computed as v, watch as
|
|
3
|
-
import { ElPopover as B, ElInput as O, ElIcon as
|
|
4
|
-
import {
|
|
1
|
+
import { w as S } from "./chunks/index.bCzIhWFw.js";
|
|
2
|
+
import { ref as p, computed as v, watch as N, createBlock as c, openBlock as o, unref as a, withCtx as i, createElementVNode as x, createVNode as r, createElementBlock as u, createCommentVNode as E, Fragment as I, renderList as L, normalizeClass as h, resolveDynamicComponent as V, createTextVNode as j } from "vue";
|
|
3
|
+
import { ElPopover as B, ElInput as O, ElIcon as y } from "element-plus";
|
|
4
|
+
import { IconSearch as T, IconAdd as U } from "color-message-lingyun-vue";
|
|
5
5
|
import { c as g } from "./chunks/global.DVwnOczb.js";
|
|
6
|
-
import { I as
|
|
7
|
-
import { _ as
|
|
8
|
-
import './assets/IconSelect.css';const
|
|
6
|
+
import { I as A } from "./chunks/layout.DBgjqaxe.js";
|
|
7
|
+
import { _ as D } from "./chunks/_plugin-vue_export-helper.CHgC5LLL.js";
|
|
8
|
+
import './assets/IconSelect.css';const F = { class: "icon-select-content flex flex-col overflow-hidden" }, P = { class: "icon-select-grid overflow-y-auto display-grid" }, $ = ["title", "onClick"], q = {
|
|
9
9
|
key: 0,
|
|
10
10
|
class: "no-data"
|
|
11
11
|
}, G = /* @__PURE__ */ Object.assign({
|
|
@@ -34,16 +34,16 @@ import './assets/IconSelect.css';const P = { class: "icon-select-content flex fl
|
|
|
34
34
|
},
|
|
35
35
|
emits: ["update:modelValue"],
|
|
36
36
|
setup(d, { emit: k }) {
|
|
37
|
-
const
|
|
37
|
+
const w = d, C = k, m = p(!1), s = p(""), n = p(w.modelValue), _ = v(() => Object.entries(g).filter(([e]) => e.toLowerCase().includes("menu")).map(([e, l]) => ({
|
|
38
38
|
name: e,
|
|
39
39
|
component: l
|
|
40
|
-
}))),
|
|
41
|
-
(e) => e.name.toLowerCase().includes(
|
|
42
|
-
) :
|
|
40
|
+
}))), b = v(() => s.value ? _.value.filter(
|
|
41
|
+
(e) => e.name.toLowerCase().includes(s.value.toLowerCase())
|
|
42
|
+
) : _.value), f = v(() => n.value && g[n.value] || null), z = (e) => {
|
|
43
43
|
n.value = e.name, C("update:modelValue", e.name), m.value = !1;
|
|
44
44
|
};
|
|
45
|
-
return
|
|
46
|
-
() =>
|
|
45
|
+
return N(
|
|
46
|
+
() => w.modelValue,
|
|
47
47
|
(e) => {
|
|
48
48
|
n.value = e;
|
|
49
49
|
}
|
|
@@ -55,24 +55,24 @@ import './assets/IconSelect.css';const P = { class: "icon-select-content flex fl
|
|
|
55
55
|
trigger: "click"
|
|
56
56
|
}, {
|
|
57
57
|
reference: i(() => [
|
|
58
|
-
|
|
59
|
-
class:
|
|
58
|
+
x("div", {
|
|
59
|
+
class: h(["flex items-center pointer radius-16 justify-center w-icon-item", {
|
|
60
60
|
"select-icon-box bg-fcfdff text-202434 fz-14 flex-col": !f.value,
|
|
61
61
|
"icon-item": n.value
|
|
62
62
|
}])
|
|
63
63
|
}, [
|
|
64
|
-
f.value ? (o(), c(a(
|
|
64
|
+
f.value ? (o(), c(a(y), {
|
|
65
65
|
key: 0,
|
|
66
66
|
size: d.iconSize
|
|
67
67
|
}, {
|
|
68
68
|
default: i(() => [
|
|
69
|
-
(o(), c(
|
|
69
|
+
(o(), c(V(f.value)))
|
|
70
70
|
]),
|
|
71
71
|
_: 1
|
|
72
|
-
}, 8, ["size"])) : (o(), u(
|
|
73
|
-
|
|
72
|
+
}, 8, ["size"])) : (o(), u(I, { key: 1 }, [
|
|
73
|
+
r(a(y), { size: 16 }, {
|
|
74
74
|
default: i(() => [
|
|
75
|
-
|
|
75
|
+
r(a(U))
|
|
76
76
|
]),
|
|
77
77
|
_: 1
|
|
78
78
|
}),
|
|
@@ -81,39 +81,39 @@ import './assets/IconSelect.css';const P = { class: "icon-select-content flex fl
|
|
|
81
81
|
], 2)
|
|
82
82
|
]),
|
|
83
83
|
default: i(() => [
|
|
84
|
-
|
|
85
|
-
|
|
84
|
+
x("div", F, [
|
|
85
|
+
r(a(O), {
|
|
86
86
|
class: "mg-b-12",
|
|
87
|
-
modelValue:
|
|
88
|
-
"onUpdate:modelValue": l[0] || (l[0] = (t) =>
|
|
87
|
+
modelValue: s.value,
|
|
88
|
+
"onUpdate:modelValue": l[0] || (l[0] = (t) => s.value = t),
|
|
89
89
|
placeholder: "搜索图标",
|
|
90
90
|
"prefix-icon": a(T),
|
|
91
91
|
clearable: ""
|
|
92
92
|
}, null, 8, ["modelValue", "prefix-icon"]),
|
|
93
|
-
|
|
94
|
-
(o(!0), u(
|
|
93
|
+
x("div", P, [
|
|
94
|
+
(o(!0), u(I, null, L(b.value, (t) => (o(), u("div", {
|
|
95
95
|
key: t.name,
|
|
96
|
-
class:
|
|
96
|
+
class: h(["icon-item radius-8 justify-center items-center pointer flex w-icon-item", { active: n.value === t.name }]),
|
|
97
97
|
title: t.name,
|
|
98
98
|
onClick: (J) => z(t)
|
|
99
99
|
}, [
|
|
100
|
-
|
|
100
|
+
r(a(y), { size: 50 }, {
|
|
101
101
|
default: i(() => [
|
|
102
|
-
(o(), c(
|
|
102
|
+
(o(), c(V(t.component)))
|
|
103
103
|
]),
|
|
104
104
|
_: 2
|
|
105
105
|
}, 1024)
|
|
106
|
-
], 10,
|
|
106
|
+
], 10, $))), 128))
|
|
107
107
|
]),
|
|
108
|
-
|
|
109
|
-
|
|
108
|
+
b.value.length === 0 ? (o(), u("div", q, [
|
|
109
|
+
r(A, { text: "未找到相关图标" })
|
|
110
110
|
])) : E("", !0)
|
|
111
111
|
])
|
|
112
112
|
]),
|
|
113
113
|
_: 1
|
|
114
114
|
}, 8, ["visible", "width"]));
|
|
115
115
|
}
|
|
116
|
-
}), H = /* @__PURE__ */
|
|
116
|
+
}), H = /* @__PURE__ */ D(G, [["__scopeId", "data-v-b6a428ec"]]), Z = S(H);
|
|
117
117
|
export {
|
|
118
118
|
Z as IconSelect,
|
|
119
119
|
Z as default
|