@rft-rc/recycle-ui 0.0.1-rc.7 → 0.0.2
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/components/search-area/index.d.ts +10 -0
- package/dist/components/search-area/index.d.ts.map +1 -0
- package/dist/components/search-area/index.vue.d.ts +51 -0
- package/dist/components/search-area/index.vue.d.ts.map +1 -0
- package/dist/favicon.svg +10 -0
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.mjs +506 -278
- package/dist/index.mjs.map +1 -1
- package/dist/logo.svg +22 -0
- package/dist/style.css +1 -1
- package/package.json +2 -2
package/dist/index.mjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
const
|
|
1
|
+
import { defineComponent as B, computed as g, createElementBlock as m, openBlock as u, normalizeStyle as A, normalizeClass as V, createCommentVNode as $, renderSlot as w, createTextVNode as q, toDisplayString as C, inject as T, createElementVNode as k, ref as I, watchEffect as Le, provide as U, Fragment as O, renderList as K, createBlock as te, onMounted as be, onUnmounted as ke, Teleport as Ne, createVNode as E, Transition as le, withCtx as G, createApp as Be, reactive as We, TransitionGroup as Te, render as $e, watch as ie, nextTick as ue, unref as H } from "vue";
|
|
2
|
+
const ze = ["disabled"], Me = {
|
|
3
3
|
key: 0,
|
|
4
4
|
class: "rc-button__spinner"
|
|
5
|
-
},
|
|
5
|
+
}, Ue = /* @__PURE__ */ B({
|
|
6
6
|
__name: "index",
|
|
7
7
|
props: {
|
|
8
8
|
type: { default: "default" },
|
|
@@ -16,35 +16,35 @@ const de = ["disabled"], fe = {
|
|
|
16
16
|
},
|
|
17
17
|
emits: ["click"],
|
|
18
18
|
setup(e, { emit: t }) {
|
|
19
|
-
const
|
|
20
|
-
!
|
|
21
|
-
},
|
|
22
|
-
const
|
|
23
|
-
return typeof
|
|
19
|
+
const s = e, c = t, f = (v) => {
|
|
20
|
+
!s.disabled && !s.loading && c("click", v);
|
|
21
|
+
}, d = g(() => {
|
|
22
|
+
const v = s.round;
|
|
23
|
+
return typeof v == "boolean" ? v ? "999px" : "6px" : typeof v == "number" ? `${v}px` : String(v);
|
|
24
24
|
});
|
|
25
|
-
return (
|
|
26
|
-
class:
|
|
27
|
-
style:
|
|
25
|
+
return (v, r) => (u(), m("button", {
|
|
26
|
+
class: V(["rc-button", [`rc-button--${e.type}`, `rc-button--${e.size}`, { "is-plain": e.plain, "is-block": e.block, "is-disabled": e.disabled, "is-loading": e.loading }]]),
|
|
27
|
+
style: A({ borderRadius: d.value }),
|
|
28
28
|
disabled: e.disabled || e.loading,
|
|
29
|
-
onClick:
|
|
29
|
+
onClick: f
|
|
30
30
|
}, [
|
|
31
|
-
e.loading ? (
|
|
32
|
-
|
|
33
|
-
|
|
31
|
+
e.loading ? (u(), m("span", Me)) : $("", !0),
|
|
32
|
+
w(v.$slots, "default", {}, () => [
|
|
33
|
+
q(C(e.label), 1)
|
|
34
34
|
], !0)
|
|
35
|
-
], 14,
|
|
35
|
+
], 14, ze));
|
|
36
36
|
}
|
|
37
|
-
}),
|
|
38
|
-
const
|
|
39
|
-
for (const [c,
|
|
40
|
-
|
|
41
|
-
return
|
|
42
|
-
},
|
|
43
|
-
|
|
44
|
-
function
|
|
45
|
-
return e.component(
|
|
37
|
+
}), W = (e, t) => {
|
|
38
|
+
const s = e.__vccOpts || e;
|
|
39
|
+
for (const [c, f] of t)
|
|
40
|
+
s[c] = f;
|
|
41
|
+
return s;
|
|
42
|
+
}, J = /* @__PURE__ */ W(Ue, [["__scopeId", "data-v-a70e95bb"]]);
|
|
43
|
+
J.name = "rc-button";
|
|
44
|
+
function de(e) {
|
|
45
|
+
return e.component(J.name, J), e;
|
|
46
46
|
}
|
|
47
|
-
const
|
|
47
|
+
const Fe = { class: "rc-desc-item__value" }, Ge = /* @__PURE__ */ B({
|
|
48
48
|
name: "rc-descriptions-item",
|
|
49
49
|
__name: "item",
|
|
50
50
|
props: {
|
|
@@ -55,42 +55,42 @@ const pe = { class: "rc-desc-item__value" }, ye = /* @__PURE__ */ S({
|
|
|
55
55
|
},
|
|
56
56
|
setup(e) {
|
|
57
57
|
const t = e;
|
|
58
|
-
|
|
59
|
-
const
|
|
60
|
-
const
|
|
61
|
-
return Math.min(
|
|
62
|
-
}),
|
|
63
|
-
const
|
|
64
|
-
if (!
|
|
65
|
-
const
|
|
66
|
-
return `calc((100% - ${
|
|
67
|
-
}),
|
|
68
|
-
const
|
|
69
|
-
return
|
|
58
|
+
T("rcDescItemWidth", void 0), T("rcDescSingleWidth", ""), T("rcDescGap", "0px");
|
|
59
|
+
const s = T("rcDescGapPx", 0), c = T("rcDescColCount", 1), f = T("rcDescLabelWidth", ""), d = g(() => {
|
|
60
|
+
const l = typeof t.span == "string" ? parseInt(t.span, 10) : t.span, o = typeof (c == null ? void 0 : c.value) == "number" ? c.value : c, b = !Number.isNaN(l) && l > 0 ? l : 1;
|
|
61
|
+
return Math.min(b, o || 1);
|
|
62
|
+
}), v = g(() => {
|
|
63
|
+
const l = typeof (c == null ? void 0 : c.value) == "number" ? c.value : c, o = typeof (s == null ? void 0 : s.value) == "number" ? s.value : s, b = d.value;
|
|
64
|
+
if (!l || l <= 1 || b >= l) return "100%";
|
|
65
|
+
const y = (l - 1) * o, _ = (b - 1) * o;
|
|
66
|
+
return `calc((100% - ${y}px) * ${b} / ${l} + ${_}px)`;
|
|
67
|
+
}), r = g(() => {
|
|
68
|
+
const l = typeof (f == null ? void 0 : f.value) == "string" ? f.value : f, o = t.labelWidth !== "" ? t.labelWidth : l || "";
|
|
69
|
+
return o ? { width: typeof o == "number" ? `${o}px` : String(o), flex: "0 0 auto" } : {};
|
|
70
70
|
});
|
|
71
|
-
return (
|
|
71
|
+
return (l, o) => (u(), m("div", {
|
|
72
72
|
class: "rc-desc-item",
|
|
73
|
-
style:
|
|
73
|
+
style: A({ width: v.value, flex: `0 0 ${v.value}` })
|
|
74
74
|
}, [
|
|
75
|
-
|
|
75
|
+
k("div", {
|
|
76
76
|
class: "rc-desc-item__label",
|
|
77
|
-
style:
|
|
77
|
+
style: A(r.value)
|
|
78
78
|
}, [
|
|
79
|
-
|
|
80
|
-
|
|
79
|
+
w(l.$slots, "label", {}, () => [
|
|
80
|
+
q(C(e.label), 1)
|
|
81
81
|
], !0)
|
|
82
82
|
], 4),
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
83
|
+
k("div", Fe, [
|
|
84
|
+
w(l.$slots, "default", {}, () => [
|
|
85
|
+
q(C(e.value), 1)
|
|
86
86
|
], !0)
|
|
87
87
|
])
|
|
88
88
|
], 4));
|
|
89
89
|
}
|
|
90
|
-
}),
|
|
90
|
+
}), P = /* @__PURE__ */ W(Ge, [["__scopeId", "data-v-970d0b99"]]), Oe = { class: "rc-descriptions" }, Pe = {
|
|
91
91
|
key: 0,
|
|
92
92
|
class: "rc-descriptions__title"
|
|
93
|
-
},
|
|
93
|
+
}, je = /* @__PURE__ */ B({
|
|
94
94
|
name: "rc-descriptions",
|
|
95
95
|
__name: "index",
|
|
96
96
|
props: {
|
|
@@ -102,66 +102,66 @@ const pe = { class: "rc-desc-item__value" }, ye = /* @__PURE__ */ S({
|
|
|
102
102
|
keyMap: {}
|
|
103
103
|
},
|
|
104
104
|
setup(e) {
|
|
105
|
-
const t = e,
|
|
106
|
-
const
|
|
107
|
-
return !Number.isNaN(
|
|
108
|
-
}),
|
|
109
|
-
|
|
110
|
-
const
|
|
111
|
-
if (
|
|
112
|
-
|
|
105
|
+
const t = e, s = I(null), c = g(() => typeof t.gap == "number" ? `${t.gap}px` : String(t.gap)), f = g(() => {
|
|
106
|
+
const o = typeof t.column == "string" ? Number.parseInt(t.column, 10) : t.column ?? 1;
|
|
107
|
+
return !Number.isNaN(o) && o > 0 ? o : 1;
|
|
108
|
+
}), d = I("100%"), v = I("100%");
|
|
109
|
+
Le(() => {
|
|
110
|
+
const o = f.value;
|
|
111
|
+
if (o <= 1)
|
|
112
|
+
d.value = "100%", v.value = "100%";
|
|
113
113
|
else {
|
|
114
|
-
const
|
|
115
|
-
|
|
114
|
+
const b = typeof t.gap == "number" ? t.gap : parseFloat(String(t.gap)) || 0, _ = `calc((100% - ${(o - 1) * b}px) / ${o})`;
|
|
115
|
+
v.value = _, d.value = _;
|
|
116
116
|
}
|
|
117
|
-
}),
|
|
118
|
-
const
|
|
119
|
-
|
|
120
|
-
const
|
|
121
|
-
var
|
|
122
|
-
const
|
|
123
|
-
return (
|
|
124
|
-
label:
|
|
125
|
-
value:
|
|
117
|
+
}), U("rcDescItemWidth", d), U("rcDescSingleWidth", v), U("rcDescColCount", f), U("rcDescGapPx", g(() => typeof t.gap == "number" ? t.gap : parseFloat(String(t.gap)) || 0));
|
|
118
|
+
const r = g(() => t.labelWidth === "" || t.labelWidth === void 0 ? "" : typeof t.labelWidth == "number" ? `${t.labelWidth}px` : String(t.labelWidth));
|
|
119
|
+
U("rcDescLabelWidth", r), U("rcDescGap", g(() => typeof t.gap == "number" ? `${t.gap}px` : String(t.gap)));
|
|
120
|
+
const l = g(() => {
|
|
121
|
+
var y, _, h;
|
|
122
|
+
const o = ((y = t.keyMap) == null ? void 0 : y.key) ?? "label", b = ((_ = t.keyMap) == null ? void 0 : _.value) ?? "value";
|
|
123
|
+
return (h = t.data) != null && h.length ? t.data.map((D) => ({
|
|
124
|
+
label: D == null ? void 0 : D[o],
|
|
125
|
+
value: D == null ? void 0 : D[b]
|
|
126
126
|
})) : [];
|
|
127
127
|
});
|
|
128
|
-
return (
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
128
|
+
return (o, b) => (u(), m("div", Oe, [
|
|
129
|
+
o.$slots.title || e.title ? (u(), m("div", Pe, [
|
|
130
|
+
w(o.$slots, "title", {}, () => [
|
|
131
|
+
q(C(e.title), 1)
|
|
132
132
|
], !0)
|
|
133
|
-
])) :
|
|
134
|
-
|
|
133
|
+
])) : $("", !0),
|
|
134
|
+
k("div", {
|
|
135
135
|
class: "rc-descriptions__body",
|
|
136
|
-
style:
|
|
136
|
+
style: A({ gap: c.value }),
|
|
137
137
|
ref_key: "wrapEl",
|
|
138
|
-
ref:
|
|
138
|
+
ref: s
|
|
139
139
|
}, [
|
|
140
|
-
|
|
141
|
-
key:
|
|
142
|
-
label:
|
|
143
|
-
value:
|
|
140
|
+
l.value.length ? (u(!0), m(O, { key: 0 }, K(l.value, (y, _) => (u(), te(P, {
|
|
141
|
+
key: _,
|
|
142
|
+
label: y.label,
|
|
143
|
+
value: y.value,
|
|
144
144
|
"label-width": e.labelWidth
|
|
145
|
-
}, null, 8, ["label", "value", "label-width"]))), 128)) :
|
|
145
|
+
}, null, 8, ["label", "value", "label-width"]))), 128)) : w(o.$slots, "default", { key: 1 }, void 0, !0)
|
|
146
146
|
], 4)
|
|
147
147
|
]));
|
|
148
148
|
}
|
|
149
|
-
}),
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
function
|
|
153
|
-
return e.component(
|
|
149
|
+
}), Y = /* @__PURE__ */ W(je, [["__scopeId", "data-v-5fcaa235"]]);
|
|
150
|
+
Y.name = "rc-descriptions";
|
|
151
|
+
P.name = "rc-descriptions-item";
|
|
152
|
+
function fe(e) {
|
|
153
|
+
return e.component(Y.name, Y), e.component("RcDescriptions", Y), e.component(P.name, P), e.component("RcDescriptionsItem", P), e;
|
|
154
154
|
}
|
|
155
|
-
const
|
|
155
|
+
const Dt = Y, Et = P, qe = { class: "rc-card__title" }, He = { class: "rc-card__title-text" }, Ke = {
|
|
156
156
|
key: 0,
|
|
157
157
|
class: "rc-card__status"
|
|
158
|
-
},
|
|
158
|
+
}, Ye = {
|
|
159
159
|
key: 1,
|
|
160
160
|
class: "rc-card__divider"
|
|
161
|
-
},
|
|
161
|
+
}, Je = {
|
|
162
162
|
key: 2,
|
|
163
163
|
class: "rc-card__action"
|
|
164
|
-
},
|
|
164
|
+
}, Qe = /* @__PURE__ */ B({
|
|
165
165
|
name: "rc-card",
|
|
166
166
|
__name: "index",
|
|
167
167
|
props: {
|
|
@@ -179,84 +179,84 @@ const He = B, Ke = R, he = { class: "rc-card__title" }, _e = { class: "rc-card__
|
|
|
179
179
|
height: { default: "" }
|
|
180
180
|
},
|
|
181
181
|
setup(e) {
|
|
182
|
-
const t = e,
|
|
183
|
-
const
|
|
182
|
+
const t = e, s = g(() => {
|
|
183
|
+
const r = typeof t.round == "boolean" ? t.round ? "12px" : "0" : typeof t.round == "number" ? `${t.round}px` : String(t.round);
|
|
184
184
|
return {
|
|
185
185
|
backgroundColor: t.color || "var(--rc-white)",
|
|
186
|
-
borderRadius:
|
|
187
|
-
boxShadow:
|
|
188
|
-
width:
|
|
189
|
-
height:
|
|
186
|
+
borderRadius: r,
|
|
187
|
+
boxShadow: v(t.elevation),
|
|
188
|
+
width: d(t.width),
|
|
189
|
+
height: d(t.height)
|
|
190
190
|
};
|
|
191
|
-
}), c =
|
|
191
|
+
}), c = g(() => t.padding || "16px"), f = g(
|
|
192
192
|
() => typeof t.gap == "number" ? `${t.gap}px` : String(t.gap)
|
|
193
193
|
);
|
|
194
|
-
function
|
|
195
|
-
return
|
|
194
|
+
function d(r) {
|
|
195
|
+
return r == null || r === "" ? "" : typeof r == "number" ? `${r}px` : String(r);
|
|
196
196
|
}
|
|
197
|
-
function
|
|
198
|
-
if (!
|
|
199
|
-
const
|
|
200
|
-
return `0 ${Math.round(
|
|
201
|
-
|
|
202
|
-
)}px ${Math.round(
|
|
197
|
+
function v(r) {
|
|
198
|
+
if (!r || r <= 0) return "none";
|
|
199
|
+
const l = 4 * r;
|
|
200
|
+
return `0 ${Math.round(l / 2)}px ${l}px rgba(0,0,0,0.06), 0 ${Math.round(
|
|
201
|
+
l / 4
|
|
202
|
+
)}px ${Math.round(l / 2)}px rgba(0,0,0,0.04)`;
|
|
203
203
|
}
|
|
204
|
-
return (
|
|
205
|
-
class:
|
|
206
|
-
style:
|
|
204
|
+
return (r, l) => (u(), m("div", {
|
|
205
|
+
class: V(["rc-card", [{ "rc-card--bordered": e.bordered }]]),
|
|
206
|
+
style: A(s.value)
|
|
207
207
|
}, [
|
|
208
|
-
|
|
208
|
+
r.$slots.title || e.title || r.$slots.status || e.status ? (u(), m("div", {
|
|
209
209
|
key: 0,
|
|
210
210
|
class: "rc-card__top",
|
|
211
|
-
style:
|
|
211
|
+
style: A({ backgroundColor: e.topBgColor || "rgba(29, 133, 252, 0.05)" })
|
|
212
212
|
}, [
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
213
|
+
k("div", qe, [
|
|
214
|
+
w(r.$slots, "title", {}, () => [
|
|
215
|
+
k("span", He, C(e.title), 1)
|
|
216
216
|
], !0)
|
|
217
217
|
]),
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
218
|
+
r.$slots.status || e.status ? (u(), m("div", Ke, [
|
|
219
|
+
w(r.$slots, "status", {}, () => [
|
|
220
|
+
k("span", {
|
|
221
221
|
class: "rc-card__status-text",
|
|
222
|
-
style:
|
|
223
|
-
},
|
|
222
|
+
style: A({ color: e.statusColor || "var(--rc-primary)" })
|
|
223
|
+
}, C(e.status), 5)
|
|
224
224
|
], !0)
|
|
225
|
-
])) :
|
|
226
|
-
], 4)) :
|
|
227
|
-
|
|
225
|
+
])) : $("", !0)
|
|
226
|
+
], 4)) : $("", !0),
|
|
227
|
+
k("div", {
|
|
228
228
|
class: "rc-card__body",
|
|
229
|
-
style:
|
|
229
|
+
style: A({ padding: c.value, gap: f.value })
|
|
230
230
|
}, [
|
|
231
|
-
|
|
232
|
-
|
|
231
|
+
w(r.$slots, "content", {}, () => [
|
|
232
|
+
w(r.$slots, "default", {}, void 0, !0)
|
|
233
233
|
], !0)
|
|
234
234
|
], 4),
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
])) :
|
|
235
|
+
r.$slots.action ? (u(), m("div", Ye)) : $("", !0),
|
|
236
|
+
r.$slots.action ? (u(), m("div", Je, [
|
|
237
|
+
w(r.$slots, "action", {}, void 0, !0)
|
|
238
|
+
])) : $("", !0)
|
|
239
239
|
], 6));
|
|
240
240
|
}
|
|
241
|
-
}),
|
|
242
|
-
|
|
243
|
-
const
|
|
244
|
-
function
|
|
245
|
-
return e.component(
|
|
241
|
+
}), ee = /* @__PURE__ */ W(Qe, [["__scopeId", "data-v-a7b95214"]]);
|
|
242
|
+
ee.name = "rc-card";
|
|
243
|
+
const Xe = "RcCard";
|
|
244
|
+
function ve(e) {
|
|
245
|
+
return e.component(ee.name, ee), e.component(Xe, ee), e;
|
|
246
246
|
}
|
|
247
|
-
const
|
|
247
|
+
const Ze = {
|
|
248
248
|
key: 0,
|
|
249
249
|
class: "rc-toast__mask"
|
|
250
|
-
},
|
|
250
|
+
}, et = { class: "rc-toast__content" }, tt = {
|
|
251
251
|
key: 0,
|
|
252
252
|
class: "rc-toast__spinner"
|
|
253
|
-
},
|
|
253
|
+
}, nt = {
|
|
254
254
|
key: 1,
|
|
255
255
|
class: "rc-toast__icon rc-toast__icon--success"
|
|
256
|
-
},
|
|
256
|
+
}, at = {
|
|
257
257
|
key: 2,
|
|
258
258
|
class: "rc-toast__icon rc-toast__icon--fail"
|
|
259
|
-
},
|
|
259
|
+
}, st = { class: "rc-toast__text" }, lt = /* @__PURE__ */ B({
|
|
260
260
|
__name: "index",
|
|
261
261
|
props: {
|
|
262
262
|
message: { default: "" },
|
|
@@ -266,153 +266,153 @@ const we = {
|
|
|
266
266
|
onAfterLeave: {}
|
|
267
267
|
},
|
|
268
268
|
setup(e, { expose: t }) {
|
|
269
|
-
const
|
|
270
|
-
let
|
|
271
|
-
function
|
|
272
|
-
|
|
269
|
+
const s = e, c = I(!0);
|
|
270
|
+
let f;
|
|
271
|
+
function d() {
|
|
272
|
+
f && (clearTimeout(f), f = null);
|
|
273
273
|
}
|
|
274
|
-
function
|
|
275
|
-
|
|
274
|
+
function v() {
|
|
275
|
+
d(), c.value = !1;
|
|
276
276
|
}
|
|
277
|
-
return t({ close:
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
},
|
|
281
|
-
}),
|
|
282
|
-
|
|
283
|
-
}), (
|
|
284
|
-
(
|
|
285
|
-
|
|
277
|
+
return t({ close: v }), be(() => {
|
|
278
|
+
s.duration && s.duration > 0 && (f = setTimeout(() => {
|
|
279
|
+
v();
|
|
280
|
+
}, s.duration));
|
|
281
|
+
}), ke(() => {
|
|
282
|
+
d();
|
|
283
|
+
}), (r, l) => (u(), m(O, null, [
|
|
284
|
+
(u(), te(Ne, { to: "body" }, [
|
|
285
|
+
E(le, {
|
|
286
286
|
name: "rc-toast-fade",
|
|
287
287
|
onAfterLeave: e.onAfterLeave
|
|
288
288
|
}, {
|
|
289
|
-
default:
|
|
290
|
-
c.value ? (
|
|
289
|
+
default: G(() => [
|
|
290
|
+
c.value ? (u(), m("div", {
|
|
291
291
|
key: 0,
|
|
292
|
-
class:
|
|
292
|
+
class: V(["rc-toast", [`rc-toast--${e.type}`]])
|
|
293
293
|
}, [
|
|
294
|
-
e.mask ? (
|
|
295
|
-
|
|
296
|
-
e.type === "loading" ? (
|
|
297
|
-
|
|
294
|
+
e.mask ? (u(), m("div", Ze)) : $("", !0),
|
|
295
|
+
k("div", et, [
|
|
296
|
+
e.type === "loading" ? (u(), m("div", tt)) : e.type === "success" ? (u(), m("div", nt)) : e.type === "fail" ? (u(), m("div", at)) : $("", !0),
|
|
297
|
+
k("div", st, C(e.message), 1)
|
|
298
298
|
])
|
|
299
|
-
], 2)) :
|
|
299
|
+
], 2)) : $("", !0)
|
|
300
300
|
]),
|
|
301
301
|
_: 1
|
|
302
302
|
}, 8, ["onAfterLeave"])
|
|
303
303
|
])),
|
|
304
|
-
|
|
304
|
+
w(r.$slots, "default", {}, void 0, !0)
|
|
305
305
|
], 64));
|
|
306
306
|
}
|
|
307
|
-
}),
|
|
308
|
-
let
|
|
309
|
-
function
|
|
310
|
-
|
|
307
|
+
}), ne = /* @__PURE__ */ W(lt, [["__scopeId", "data-v-d234c9c5"]]);
|
|
308
|
+
let z = null, j = null;
|
|
309
|
+
function me() {
|
|
310
|
+
z && (z.unmount(), z = null), j && (document.body.removeChild(j), j = null);
|
|
311
311
|
}
|
|
312
|
-
function
|
|
312
|
+
function Lt(e) {
|
|
313
313
|
const t = typeof e == "string" ? { message: e } : e || {};
|
|
314
|
-
|
|
315
|
-
const
|
|
314
|
+
me(), j = document.createElement("div"), document.body.appendChild(j);
|
|
315
|
+
const s = {
|
|
316
316
|
message: t.message,
|
|
317
317
|
type: t.type ?? "text",
|
|
318
318
|
duration: t.duration ?? 2e3,
|
|
319
319
|
mask: t.mask ?? !1,
|
|
320
320
|
onAfterLeave: () => {
|
|
321
321
|
var c;
|
|
322
|
-
|
|
322
|
+
me(), (c = t.onClose) == null || c.call(t);
|
|
323
323
|
}
|
|
324
324
|
};
|
|
325
|
-
return
|
|
326
|
-
close:
|
|
325
|
+
return z = Be(ne, s), z.mount(j), {
|
|
326
|
+
close: rt
|
|
327
327
|
};
|
|
328
328
|
}
|
|
329
|
-
function
|
|
330
|
-
var e, t,
|
|
331
|
-
|
|
329
|
+
function rt() {
|
|
330
|
+
var e, t, s;
|
|
331
|
+
z && ((s = (t = (e = z._instance) == null ? void 0 : e.exposed) == null ? void 0 : t.close) == null || s.call(t));
|
|
332
332
|
}
|
|
333
|
-
|
|
334
|
-
function
|
|
335
|
-
return e.component(
|
|
333
|
+
ne.name = "rc-toast";
|
|
334
|
+
function pe(e) {
|
|
335
|
+
return e.component(ne.name, ne), e;
|
|
336
336
|
}
|
|
337
|
-
const
|
|
337
|
+
const ot = {
|
|
338
338
|
class: "rc-message",
|
|
339
339
|
role: "alert",
|
|
340
340
|
"aria-live": "polite"
|
|
341
|
-
},
|
|
341
|
+
}, ct = { class: "rc-message__content" }, it = /* @__PURE__ */ B({
|
|
342
342
|
__name: "index",
|
|
343
343
|
setup(e, { expose: t }) {
|
|
344
|
-
const
|
|
344
|
+
const s = We([]);
|
|
345
345
|
let c = 1;
|
|
346
|
-
function
|
|
347
|
-
const
|
|
348
|
-
|
|
346
|
+
function f(v) {
|
|
347
|
+
const r = s.findIndex((l) => l.id === v);
|
|
348
|
+
r >= 0 && s.splice(r, 1);
|
|
349
349
|
}
|
|
350
|
-
function
|
|
351
|
-
const
|
|
352
|
-
return
|
|
350
|
+
function d(v, r, l) {
|
|
351
|
+
const o = c++;
|
|
352
|
+
return s.push({ id: o, type: v, content: r, duration: l }), l > 0 && window.setTimeout(() => f(o), l), o;
|
|
353
353
|
}
|
|
354
|
-
return t({ add:
|
|
355
|
-
|
|
354
|
+
return t({ add: d, remove: f }), (v, r) => (u(), m("div", ot, [
|
|
355
|
+
E(Te, {
|
|
356
356
|
name: "rc-message-fade",
|
|
357
357
|
tag: "div"
|
|
358
358
|
}, {
|
|
359
|
-
default:
|
|
360
|
-
(
|
|
361
|
-
key:
|
|
362
|
-
class:
|
|
359
|
+
default: G(() => [
|
|
360
|
+
(u(!0), m(O, null, K(s, (l) => (u(), m("div", {
|
|
361
|
+
key: l.id,
|
|
362
|
+
class: V(["rc-message__item", `rc-message--${l.type}`])
|
|
363
363
|
}, [
|
|
364
|
-
|
|
364
|
+
k("span", ct, C(l.content), 1)
|
|
365
365
|
], 2))), 128))
|
|
366
366
|
]),
|
|
367
367
|
_: 1
|
|
368
368
|
})
|
|
369
369
|
]));
|
|
370
370
|
}
|
|
371
|
-
}),
|
|
372
|
-
let
|
|
373
|
-
function
|
|
371
|
+
}), ut = /* @__PURE__ */ W(it, [["__scopeId", "data-v-87811df0"]]);
|
|
372
|
+
let N = null, L = null;
|
|
373
|
+
function dt() {
|
|
374
374
|
var t;
|
|
375
|
-
if (
|
|
376
|
-
|
|
377
|
-
const e =
|
|
378
|
-
|
|
375
|
+
if (N && L) return;
|
|
376
|
+
N = document.createElement("div"), document.body.appendChild(N);
|
|
377
|
+
const e = E(ut, {});
|
|
378
|
+
$e(e, N), L = (t = e.component) == null ? void 0 : t.exposed;
|
|
379
379
|
}
|
|
380
|
-
function
|
|
381
|
-
var
|
|
382
|
-
|
|
383
|
-
const c = typeof
|
|
384
|
-
return (
|
|
380
|
+
function F(e, t, s) {
|
|
381
|
+
var f;
|
|
382
|
+
dt();
|
|
383
|
+
const c = typeof s == "number" ? s : e === "loading" ? 0 : 2e3;
|
|
384
|
+
return (f = L == null ? void 0 : L.add) == null ? void 0 : f.call(L, e, t, c);
|
|
385
385
|
}
|
|
386
|
-
const
|
|
386
|
+
const ft = {
|
|
387
387
|
open(e) {
|
|
388
|
-
return
|
|
388
|
+
return F(e.type || "info", e.content, e.duration);
|
|
389
389
|
},
|
|
390
390
|
info(e, t) {
|
|
391
|
-
return
|
|
391
|
+
return F("info", e, t);
|
|
392
392
|
},
|
|
393
393
|
success(e, t) {
|
|
394
|
-
return
|
|
394
|
+
return F("success", e, t);
|
|
395
395
|
},
|
|
396
396
|
warning(e, t) {
|
|
397
|
-
return
|
|
397
|
+
return F("warning", e, t);
|
|
398
398
|
},
|
|
399
399
|
error(e, t) {
|
|
400
|
-
return
|
|
400
|
+
return F("error", e, t);
|
|
401
401
|
},
|
|
402
402
|
loading(e, t) {
|
|
403
|
-
return
|
|
403
|
+
return F("loading", e, t);
|
|
404
404
|
},
|
|
405
405
|
destroy() {
|
|
406
|
-
|
|
406
|
+
N && ($e(null, N), N.remove(), N = null, L = null);
|
|
407
407
|
}
|
|
408
408
|
};
|
|
409
|
-
function
|
|
410
|
-
return e.config.globalProperties.$message =
|
|
409
|
+
function ye(e) {
|
|
410
|
+
return e.config.globalProperties.$message = ft, e;
|
|
411
411
|
}
|
|
412
|
-
const
|
|
412
|
+
const vt = {
|
|
413
413
|
key: 0,
|
|
414
414
|
class: "rc-icon__unicode"
|
|
415
|
-
},
|
|
415
|
+
}, mt = /* @__PURE__ */ B({
|
|
416
416
|
name: "rc-icon",
|
|
417
417
|
__name: "index",
|
|
418
418
|
props: {
|
|
@@ -423,93 +423,321 @@ const Ae = {
|
|
|
423
423
|
code: { default: "" }
|
|
424
424
|
},
|
|
425
425
|
setup(e) {
|
|
426
|
-
const t = e,
|
|
427
|
-
fontSize:
|
|
426
|
+
const t = e, s = T(re, {}), c = g(() => (s == null ? void 0 : s.iconClass) || "iconfont"), f = g(() => t.name || ""), d = g(() => typeof t.size == "number" ? `${t.size}px` : t.size || "16px"), v = g(() => ({
|
|
427
|
+
fontSize: d.value,
|
|
428
428
|
color: t.color || void 0,
|
|
429
429
|
lineHeight: 1,
|
|
430
|
-
fontFamily: (
|
|
431
|
-
})),
|
|
432
|
-
const
|
|
433
|
-
if (
|
|
434
|
-
if (typeof
|
|
435
|
-
return String.fromCharCode(
|
|
436
|
-
const
|
|
437
|
-
return Number.isNaN(
|
|
430
|
+
fontFamily: (s == null ? void 0 : s.iconClass) || "iconfont"
|
|
431
|
+
})), r = g(() => {
|
|
432
|
+
const l = t.code;
|
|
433
|
+
if (l == null || l === "" || l === 0) return "";
|
|
434
|
+
if (typeof l == "number")
|
|
435
|
+
return String.fromCharCode(l);
|
|
436
|
+
const o = String(l).replace(/^0x/i, ""), b = parseInt(o, 16);
|
|
437
|
+
return Number.isNaN(b) ? "" : String.fromCharCode(b);
|
|
438
438
|
});
|
|
439
|
-
return
|
|
439
|
+
return be(() => {
|
|
440
440
|
if (typeof window > "u") return;
|
|
441
|
-
const
|
|
442
|
-
if (!
|
|
443
|
-
const
|
|
444
|
-
if (!document.head.querySelector(
|
|
445
|
-
const
|
|
446
|
-
|
|
441
|
+
const l = s && s.iconCssUrl || Ce.iconCssUrl;
|
|
442
|
+
if (!l) return;
|
|
443
|
+
const o = `link[rel="stylesheet"][data-rcui-icon="true"][href="${l}"]`;
|
|
444
|
+
if (!document.head.querySelector(o)) {
|
|
445
|
+
const y = document.createElement("link");
|
|
446
|
+
y.rel = "stylesheet", y.href = l, y.setAttribute("data-rcui-icon", "true"), document.head.appendChild(y);
|
|
447
447
|
}
|
|
448
|
-
}), (
|
|
449
|
-
class:
|
|
450
|
-
style:
|
|
448
|
+
}), (l, o) => (u(), m("i", {
|
|
449
|
+
class: V(["rc-icon", [c.value, f.value, { "rc-icon--spin": e.spin }]]),
|
|
450
|
+
style: A(v.value),
|
|
451
451
|
"aria-hidden": "true"
|
|
452
452
|
}, [
|
|
453
|
-
|
|
453
|
+
r.value ? (u(), m("span", vt, C(r.value), 1)) : $("", !0)
|
|
454
454
|
], 6));
|
|
455
455
|
}
|
|
456
|
-
}),
|
|
457
|
-
|
|
458
|
-
function
|
|
459
|
-
return e.component(
|
|
456
|
+
}), M = /* @__PURE__ */ W(mt, [["__scopeId", "data-v-3857a892"]]);
|
|
457
|
+
M.name = "rc-icon";
|
|
458
|
+
function he(e) {
|
|
459
|
+
return e.component(M.name, M), e.component("RcIcon", M), e;
|
|
460
460
|
}
|
|
461
|
-
const
|
|
461
|
+
const pt = { class: "rc-search-area" }, yt = { class: "rc-search-area__bar" }, ht = ["onClick"], _t = { class: "rc-search-area__item-label" }, gt = { class: "rc-search-area__panel-content" }, bt = {
|
|
462
|
+
key: 0,
|
|
463
|
+
class: "rc-search-area__options-grid"
|
|
464
|
+
}, kt = ["onClick"], $t = { class: "rc-search-area__option-label" }, Ct = {
|
|
465
|
+
key: 1,
|
|
466
|
+
class: "rc-search-area__options-grid"
|
|
467
|
+
}, xt = ["onClick"], St = { class: "rc-search-area__option-label" }, wt = {
|
|
468
|
+
key: 2,
|
|
469
|
+
class: "rc-search-area__empty"
|
|
470
|
+
}, It = { class: "rc-search-area__panel-footer" }, At = /* @__PURE__ */ B({
|
|
471
|
+
name: "rc-search-area",
|
|
472
|
+
__name: "index",
|
|
473
|
+
props: {
|
|
474
|
+
items: { default: () => [] },
|
|
475
|
+
modelValue: { default: () => ({}) },
|
|
476
|
+
showMask: { type: Boolean, default: !0 }
|
|
477
|
+
},
|
|
478
|
+
emits: ["update:modelValue", "change", "confirm", "reset", "item-change"],
|
|
479
|
+
setup(e, { expose: t, emit: s }) {
|
|
480
|
+
const c = e, f = s, d = I(null), v = I(null), r = I(null), l = I({ top: "0px" }), o = async () => {
|
|
481
|
+
if (d.value === null || !v.value)
|
|
482
|
+
return;
|
|
483
|
+
await ue();
|
|
484
|
+
const a = v.value.getBoundingClientRect().top;
|
|
485
|
+
l.value = { top: `${a}px` };
|
|
486
|
+
}, b = (n) => {
|
|
487
|
+
if (d.value === null || !v.value)
|
|
488
|
+
return;
|
|
489
|
+
const a = n.target;
|
|
490
|
+
if (v.value.contains(a))
|
|
491
|
+
return;
|
|
492
|
+
const i = v.value.closest(".rc-search-area");
|
|
493
|
+
if (i) {
|
|
494
|
+
const p = i.querySelector(".rc-search-area__bar");
|
|
495
|
+
if (p && p.contains(a))
|
|
496
|
+
return;
|
|
497
|
+
}
|
|
498
|
+
ae();
|
|
499
|
+
};
|
|
500
|
+
ie(d, async (n) => {
|
|
501
|
+
n !== null ? (await ue(), o(), window.addEventListener("resize", o), window.addEventListener("scroll", o, !0), document.addEventListener("click", b, !0)) : (window.removeEventListener("resize", o), window.removeEventListener("scroll", o, !0), document.removeEventListener("click", b, !0));
|
|
502
|
+
}), ke(() => {
|
|
503
|
+
window.removeEventListener("resize", o), window.removeEventListener("scroll", o, !0), document.removeEventListener("click", b, !0);
|
|
504
|
+
});
|
|
505
|
+
const y = I({}), _ = I({ ...c.modelValue });
|
|
506
|
+
ie(() => c.modelValue, (n) => {
|
|
507
|
+
_.value = { ...n || {} };
|
|
508
|
+
}, { deep: !0, immediate: !0 });
|
|
509
|
+
const h = g(() => d.value === null ? null : c.items[d.value]), D = g(() => {
|
|
510
|
+
if (!h.value) return "";
|
|
511
|
+
const n = De(h.value);
|
|
512
|
+
return n > 0 ? `(${n}项)` : "";
|
|
513
|
+
}), Se = (n) => {
|
|
514
|
+
const a = _.value[n.key];
|
|
515
|
+
if (a == null || a === "")
|
|
516
|
+
return n.label;
|
|
517
|
+
if (n.type === "single") {
|
|
518
|
+
const i = oe(n, a);
|
|
519
|
+
if (i)
|
|
520
|
+
return `${n.label}: ${Q(i)}`;
|
|
521
|
+
} else {
|
|
522
|
+
const i = Array.isArray(a) ? a : [a];
|
|
523
|
+
if (i.length > 0) {
|
|
524
|
+
const p = i.map((x) => {
|
|
525
|
+
const S = oe(n, x);
|
|
526
|
+
return S ? Q(S) : null;
|
|
527
|
+
}).filter((x) => x !== null);
|
|
528
|
+
if (p.length > 0)
|
|
529
|
+
return `${n.label}: ${p.join("、")}`;
|
|
530
|
+
}
|
|
531
|
+
}
|
|
532
|
+
return n.label;
|
|
533
|
+
}, we = (n) => {
|
|
534
|
+
const a = c.items[n];
|
|
535
|
+
if (!a) return;
|
|
536
|
+
if (d.value === n) {
|
|
537
|
+
d.value = null;
|
|
538
|
+
return;
|
|
539
|
+
}
|
|
540
|
+
const i = _.value[a.key];
|
|
541
|
+
a.type === "single" ? y.value[a.key] = i !== void 0 ? i : null : y.value[a.key] = i !== void 0 ? Array.isArray(i) ? [...i] : [i] : [], d.value = n;
|
|
542
|
+
}, ae = () => {
|
|
543
|
+
d.value = null;
|
|
544
|
+
}, Q = (n) => typeof n == "string" ? n : n.label || String(n.value), X = (n) => typeof n == "string" ? n : n.value !== void 0 ? n.value : n, oe = (n, a) => n.options.find((i) => {
|
|
545
|
+
const p = X(i);
|
|
546
|
+
return p === a || String(p) === String(a);
|
|
547
|
+
}) || null, Z = (n) => {
|
|
548
|
+
if (!h.value) return !1;
|
|
549
|
+
const a = h.value.key, i = y.value[a], p = X(n);
|
|
550
|
+
return h.value.type === "single" ? i != null && i === p : (Array.isArray(i) ? i : []).some((S) => S === p || String(S) === String(p));
|
|
551
|
+
}, Ie = (n) => {
|
|
552
|
+
if (!h.value) return;
|
|
553
|
+
const a = h.value.key, i = X(n);
|
|
554
|
+
y.value[a] === i ? y.value[a] = null : y.value[a] = i;
|
|
555
|
+
}, Ae = (n) => {
|
|
556
|
+
if (!h.value) return;
|
|
557
|
+
const a = h.value.key, i = X(n), p = Array.isArray(y.value[a]) ? [...y.value[a]] : [], x = p.findIndex(
|
|
558
|
+
(S) => S === i || String(S) === String(i)
|
|
559
|
+
);
|
|
560
|
+
x >= 0 ? p.splice(x, 1) : p.push(i), y.value[a] = p;
|
|
561
|
+
}, Re = () => {
|
|
562
|
+
if (!h.value) return;
|
|
563
|
+
const n = h.value.key;
|
|
564
|
+
h.value.type === "single" ? y.value[n] = null : y.value[n] = [];
|
|
565
|
+
}, Ve = () => {
|
|
566
|
+
if (!h.value) return;
|
|
567
|
+
const n = h.value.key, a = y.value[n], i = _.value[n];
|
|
568
|
+
let p;
|
|
569
|
+
h.value.type === "single" ? (p = a ?? void 0, _.value[n] = p) : (p = Array.isArray(a) && a.length > 0 ? a : void 0, _.value[n] = p), f("update:modelValue", { ..._.value }), f("change", { ..._.value }, h.value), f("confirm", { ..._.value }, h.value), JSON.stringify(i) !== JSON.stringify(p) && f("item-change", n, p), ae();
|
|
570
|
+
}, ce = (n) => {
|
|
571
|
+
const a = _.value[n.key];
|
|
572
|
+
return a == null || a === "" ? 0 : n.type === "single" ? 1 : Array.isArray(a) ? a.length : a ? 1 : 0;
|
|
573
|
+
}, De = (n) => {
|
|
574
|
+
const a = y.value[n.key];
|
|
575
|
+
return a == null || a === "" ? 0 : n.type === "single" ? 1 : Array.isArray(a) ? a.length : 0;
|
|
576
|
+
};
|
|
577
|
+
return t({
|
|
578
|
+
/** 获取当前筛选值 */
|
|
579
|
+
getValues: () => ({ ..._.value }),
|
|
580
|
+
/** 重置所有筛选 */
|
|
581
|
+
reset: () => {
|
|
582
|
+
_.value = {}, y.value = {}, f("update:modelValue", {}), f("change", {}, null), f("reset");
|
|
583
|
+
}
|
|
584
|
+
}), (n, a) => (u(), m("div", pt, [
|
|
585
|
+
k("div", yt, [
|
|
586
|
+
(u(!0), m(O, null, K(c.items, (i, p) => (u(), m("div", {
|
|
587
|
+
key: p,
|
|
588
|
+
class: V(["rc-search-area__item", {
|
|
589
|
+
"is-active": d.value === p,
|
|
590
|
+
"has-value": ce(i) > 0
|
|
591
|
+
}]),
|
|
592
|
+
onClick: (x) => we(p)
|
|
593
|
+
}, [
|
|
594
|
+
k("span", _t, C(Se(i)), 1),
|
|
595
|
+
E(H(M), {
|
|
596
|
+
name: "icon_a-xiala2",
|
|
597
|
+
color: d.value !== p && ce(i) > 0 ? "#1677ff" : "#969799",
|
|
598
|
+
class: V(["rc-search-area__item-arrow", { "is-up": d.value === p }])
|
|
599
|
+
}, null, 8, ["color", "class"])
|
|
600
|
+
], 10, ht))), 128))
|
|
601
|
+
]),
|
|
602
|
+
E(le, { name: "rc-search-area-fade" }, {
|
|
603
|
+
default: G(() => [
|
|
604
|
+
d.value !== null && c.showMask ? (u(), m("div", {
|
|
605
|
+
key: 0,
|
|
606
|
+
ref_key: "maskRef",
|
|
607
|
+
ref: r,
|
|
608
|
+
class: "rc-search-area__mask",
|
|
609
|
+
style: A(l.value),
|
|
610
|
+
onClick: ae
|
|
611
|
+
}, null, 4)) : $("", !0)
|
|
612
|
+
]),
|
|
613
|
+
_: 1
|
|
614
|
+
}),
|
|
615
|
+
E(le, { name: "rc-search-area-slide" }, {
|
|
616
|
+
default: G(() => {
|
|
617
|
+
var i, p, x, S;
|
|
618
|
+
return [
|
|
619
|
+
d.value !== null ? (u(), m("div", {
|
|
620
|
+
key: 0,
|
|
621
|
+
ref_key: "panelRef",
|
|
622
|
+
ref: v,
|
|
623
|
+
class: "rc-search-area__panel"
|
|
624
|
+
}, [
|
|
625
|
+
k("div", gt, [
|
|
626
|
+
((i = h.value) == null ? void 0 : i.type) === "single" ? (u(), m("div", bt, [
|
|
627
|
+
(u(!0), m(O, null, K(h.value.options, (R, se) => (u(), m("div", {
|
|
628
|
+
key: se,
|
|
629
|
+
class: V(["rc-search-area__option", { "is-selected": Z(R) }]),
|
|
630
|
+
onClick: (Ee) => Ie(R)
|
|
631
|
+
}, [
|
|
632
|
+
k("span", $t, C(Q(R)), 1),
|
|
633
|
+
Z(R) ? (u(), te(H(M), {
|
|
634
|
+
key: 0,
|
|
635
|
+
name: "icon_select",
|
|
636
|
+
class: "rc-search-area__option-check"
|
|
637
|
+
})) : $("", !0)
|
|
638
|
+
], 10, kt))), 128))
|
|
639
|
+
])) : (u(), m("div", Ct, [
|
|
640
|
+
(u(!0), m(O, null, K(((p = h.value) == null ? void 0 : p.options) || [], (R, se) => (u(), m("div", {
|
|
641
|
+
key: se,
|
|
642
|
+
class: V(["rc-search-area__option", { "is-selected": Z(R) }]),
|
|
643
|
+
onClick: (Ee) => Ae(R)
|
|
644
|
+
}, [
|
|
645
|
+
k("span", St, C(Q(R)), 1),
|
|
646
|
+
Z(R) ? (u(), te(H(M), {
|
|
647
|
+
key: 0,
|
|
648
|
+
name: "icon_select",
|
|
649
|
+
class: "rc-search-area__option-check"
|
|
650
|
+
})) : $("", !0)
|
|
651
|
+
], 10, xt))), 128))
|
|
652
|
+
])),
|
|
653
|
+
((S = (x = h.value) == null ? void 0 : x.options) == null ? void 0 : S.length) === 0 ? (u(), m("div", wt, [...a[0] || (a[0] = [
|
|
654
|
+
k("p", null, "暂无选项", -1)
|
|
655
|
+
])])) : $("", !0)
|
|
656
|
+
]),
|
|
657
|
+
k("div", It, [
|
|
658
|
+
E(H(J), {
|
|
659
|
+
block: "",
|
|
660
|
+
onClick: Re
|
|
661
|
+
}, {
|
|
662
|
+
default: G(() => [...a[1] || (a[1] = [
|
|
663
|
+
q(" 重置 ", -1)
|
|
664
|
+
])]),
|
|
665
|
+
_: 1
|
|
666
|
+
}),
|
|
667
|
+
E(H(J), {
|
|
668
|
+
type: "primary",
|
|
669
|
+
block: "",
|
|
670
|
+
onClick: Ve
|
|
671
|
+
}, {
|
|
672
|
+
default: G(() => [
|
|
673
|
+
q(" 确定" + C(D.value), 1)
|
|
674
|
+
]),
|
|
675
|
+
_: 1
|
|
676
|
+
})
|
|
677
|
+
])
|
|
678
|
+
], 512)) : $("", !0)
|
|
679
|
+
];
|
|
680
|
+
}),
|
|
681
|
+
_: 1
|
|
682
|
+
})
|
|
683
|
+
]));
|
|
684
|
+
}
|
|
685
|
+
}), _e = /* @__PURE__ */ W(At, [["__scopeId", "data-v-6a70650d"]]), ge = (e) => {
|
|
686
|
+
e.component("RcSearchArea", _e), e.component("rc-search-area", _e);
|
|
687
|
+
}, re = Symbol("RECYCLE_UI_CONFIG"), Ce = {
|
|
462
688
|
prefix: "rc",
|
|
463
689
|
autoRegister: !0,
|
|
464
|
-
provideKey:
|
|
690
|
+
provideKey: re,
|
|
465
691
|
// 预留主题/其他全局配置
|
|
466
692
|
theme: {},
|
|
467
693
|
// IconFont 默认配置(可在 app.use 时覆盖)
|
|
468
694
|
iconCssUrl: "//at.alicdn.com/t/c/font_4252799_9vcnw0pnmkh.css",
|
|
469
695
|
iconClass: "iconfont"
|
|
470
696
|
};
|
|
471
|
-
function
|
|
472
|
-
t.autoRegister !== !1 && (typeof
|
|
697
|
+
function Rt(e, t) {
|
|
698
|
+
t.autoRegister !== !1 && (typeof de == "function" && de(e), typeof fe == "function" && fe(e), typeof ve == "function" && ve(e), typeof pe == "function" && pe(e), typeof he == "function" && he(e), typeof ye == "function" && ye(e), typeof ge == "function" && ge(e));
|
|
473
699
|
}
|
|
474
|
-
const
|
|
475
|
-
const
|
|
476
|
-
if (e.provide(
|
|
477
|
-
const c = `link[rel="stylesheet"][data-rcui-icon="true"][href="${
|
|
700
|
+
const xe = (e, t) => {
|
|
701
|
+
const s = { ...Ce, ...t || {} };
|
|
702
|
+
if (e.provide(s.provideKey ?? re, s), e.config.globalProperties.$recycleUI = s, typeof window < "u" && s.iconCssUrl) {
|
|
703
|
+
const c = `link[rel="stylesheet"][data-rcui-icon="true"][href="${s.iconCssUrl}"]`;
|
|
478
704
|
if (!document.head.querySelector(c)) {
|
|
479
|
-
const
|
|
480
|
-
|
|
705
|
+
const d = document.createElement("link");
|
|
706
|
+
d.rel = "stylesheet", d.href = s.iconCssUrl, d.setAttribute("data-rcui-icon", "true"), document.head.appendChild(d);
|
|
481
707
|
}
|
|
482
708
|
}
|
|
483
|
-
return
|
|
484
|
-
},
|
|
485
|
-
function
|
|
709
|
+
return Rt(e, s), e;
|
|
710
|
+
}, Nt = { install: xe };
|
|
711
|
+
function Bt(e) {
|
|
486
712
|
return {
|
|
487
713
|
install(t) {
|
|
488
|
-
|
|
714
|
+
xe(t, e);
|
|
489
715
|
}
|
|
490
716
|
};
|
|
491
717
|
}
|
|
492
718
|
export {
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
719
|
+
re as RECYCLE_UI_SYMBOL,
|
|
720
|
+
J as RcButton,
|
|
721
|
+
ee as RcCard,
|
|
722
|
+
Dt as RcDescriptions,
|
|
723
|
+
Et as RcDescriptionsItem,
|
|
724
|
+
M as RcIcon,
|
|
725
|
+
_e as RcSearchArea,
|
|
726
|
+
ne as RcToast,
|
|
727
|
+
Bt as createRecycleUI,
|
|
728
|
+
Nt as default,
|
|
729
|
+
Ce as defaultRecycleUIConfig,
|
|
730
|
+
rt as hideToast,
|
|
731
|
+
xe as install,
|
|
732
|
+
de as installButton,
|
|
733
|
+
ve as installCard,
|
|
734
|
+
fe as installDescriptions,
|
|
735
|
+
he as installIcon,
|
|
736
|
+
ye as installMessage,
|
|
737
|
+
ge as installSearchArea,
|
|
738
|
+
ft as message,
|
|
739
|
+
Dt as rcDescriptions,
|
|
740
|
+
Et as rcDescriptionsItem,
|
|
741
|
+
Lt as showToast
|
|
514
742
|
};
|
|
515
743
|
//# sourceMappingURL=index.mjs.map
|