vue-efko-data-view 1.0.3 → 1.0.4
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/data-view.cjs.js +7 -7
- package/dist/data-view.cjs.js.map +1 -1
- package/dist/data-view.es.js +1402 -1344
- package/dist/data-view.es.js.map +1 -1
- package/dist/dataview/DataView.vue.d.ts +2 -0
- package/dist/dataview/table/TheTable.vue.d.ts +1 -0
- package/dist/dataview/table/interface/table.d.ts +1 -0
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/data-view.es.js
CHANGED
|
@@ -1,234 +1,234 @@
|
|
|
1
|
-
import { inject as
|
|
2
|
-
import { isEqual as
|
|
3
|
-
import
|
|
4
|
-
import { CheckCircleTwoTone as
|
|
5
|
-
import
|
|
6
|
-
import { Empty as
|
|
7
|
-
function
|
|
8
|
-
return
|
|
9
|
-
for (var
|
|
10
|
-
var t = arguments[
|
|
11
|
-
for (var
|
|
1
|
+
import { inject as mt, shallowRef as ve, getCurrentInstance as Lt, defineComponent as P, watch as $, unref as _, provide as vt, watchEffect as Ot, onBeforeUnmount as Ke, ref as L, computed as T, triggerRef as zt, resolveComponent as H, createElementBlock as C, openBlock as v, createElementVNode as R, createBlock as B, createCommentVNode as U, Fragment as O, renderList as W, normalizeStyle as ze, withCtx as w, createTextVNode as N, toDisplayString as X, createVNode as M, h as ie, createSlots as Ie, renderSlot as z, onMounted as le, normalizeClass as Pt, mergeProps as Ye, resolveDynamicComponent as yt, reactive as Ze, normalizeProps as pe, guardReactiveProps as ge } from "vue";
|
|
2
|
+
import { isEqual as ye } from "lodash";
|
|
3
|
+
import Qe from "@formkit/auto-animate";
|
|
4
|
+
import { CheckCircleTwoTone as nt, EyeOutlined as bt, EditOutlined as xt, RedoOutlined as St, DeleteOutlined as At, AppstoreOutlined as Nt, PicCenterOutlined as jt } from "@ant-design/icons-vue";
|
|
5
|
+
import Ut from "@vueform/multiselect";
|
|
6
|
+
import { Empty as Xt } from "efko-ui-library";
|
|
7
|
+
function I() {
|
|
8
|
+
return I = Object.assign ? Object.assign.bind() : function(e) {
|
|
9
|
+
for (var n = 1; n < arguments.length; n++) {
|
|
10
|
+
var t = arguments[n];
|
|
11
|
+
for (var o in t) ({}).hasOwnProperty.call(t, o) && (e[o] = t[o]);
|
|
12
12
|
}
|
|
13
13
|
return e;
|
|
14
|
-
},
|
|
14
|
+
}, I.apply(null, arguments);
|
|
15
15
|
}
|
|
16
|
-
function
|
|
17
|
-
for (var
|
|
18
|
-
t = e.charCodeAt(
|
|
16
|
+
function Ct(e) {
|
|
17
|
+
for (var n = 0, t, o = 0, r = e.length; r >= 4; ++o, r -= 4)
|
|
18
|
+
t = e.charCodeAt(o) & 255 | (e.charCodeAt(++o) & 255) << 8 | (e.charCodeAt(++o) & 255) << 16 | (e.charCodeAt(++o) & 255) << 24, t = /* Math.imul(k, m): */
|
|
19
19
|
(t & 65535) * 1540483477 + ((t >>> 16) * 59797 << 16), t ^= /* k >>> r: */
|
|
20
|
-
t >>> 24,
|
|
20
|
+
t >>> 24, n = /* Math.imul(k, m): */
|
|
21
21
|
(t & 65535) * 1540483477 + ((t >>> 16) * 59797 << 16) ^ /* Math.imul(h, m): */
|
|
22
|
-
(
|
|
22
|
+
(n & 65535) * 1540483477 + ((n >>> 16) * 59797 << 16);
|
|
23
23
|
switch (r) {
|
|
24
24
|
case 3:
|
|
25
|
-
|
|
25
|
+
n ^= (e.charCodeAt(o + 2) & 255) << 16;
|
|
26
26
|
case 2:
|
|
27
|
-
|
|
27
|
+
n ^= (e.charCodeAt(o + 1) & 255) << 8;
|
|
28
28
|
case 1:
|
|
29
|
-
|
|
30
|
-
(
|
|
29
|
+
n ^= e.charCodeAt(o) & 255, n = /* Math.imul(h, m): */
|
|
30
|
+
(n & 65535) * 1540483477 + ((n >>> 16) * 59797 << 16);
|
|
31
31
|
}
|
|
32
|
-
return
|
|
33
|
-
(
|
|
32
|
+
return n ^= n >>> 13, n = /* Math.imul(h, m): */
|
|
33
|
+
(n & 65535) * 1540483477 + ((n >>> 16) * 59797 << 16), ((n ^ n >>> 15) >>> 0).toString(36);
|
|
34
34
|
}
|
|
35
|
-
const
|
|
36
|
-
class
|
|
37
|
-
constructor(
|
|
38
|
-
this.cache = /* @__PURE__ */ new Map(), this.instanceId =
|
|
35
|
+
const ot = "%";
|
|
36
|
+
class Gt {
|
|
37
|
+
constructor(n) {
|
|
38
|
+
this.cache = /* @__PURE__ */ new Map(), this.instanceId = n;
|
|
39
39
|
}
|
|
40
|
-
get(
|
|
41
|
-
return this.cache.get(Array.isArray(
|
|
40
|
+
get(n) {
|
|
41
|
+
return this.cache.get(Array.isArray(n) ? n.join(ot) : n) || null;
|
|
42
42
|
}
|
|
43
|
-
update(
|
|
44
|
-
const
|
|
45
|
-
a === null ? this.cache.delete(
|
|
43
|
+
update(n, t) {
|
|
44
|
+
const o = Array.isArray(n) ? n.join(ot) : n, r = this.cache.get(o), a = t(r);
|
|
45
|
+
a === null ? this.cache.delete(o) : this.cache.set(o, a);
|
|
46
46
|
}
|
|
47
47
|
}
|
|
48
|
-
const
|
|
49
|
-
const
|
|
50
|
-
return
|
|
51
|
-
t.component(
|
|
48
|
+
const Wt = (e) => {
|
|
49
|
+
const n = e;
|
|
50
|
+
return n.install = function(t) {
|
|
51
|
+
t.component(n.displayName || n.name, e);
|
|
52
52
|
}, e;
|
|
53
53
|
};
|
|
54
|
-
function
|
|
54
|
+
function wt(e) {
|
|
55
55
|
return {
|
|
56
56
|
type: Object,
|
|
57
57
|
default: e
|
|
58
58
|
};
|
|
59
59
|
}
|
|
60
|
-
function
|
|
60
|
+
function He(e) {
|
|
61
61
|
return {
|
|
62
62
|
type: Boolean,
|
|
63
63
|
default: e
|
|
64
64
|
};
|
|
65
65
|
}
|
|
66
|
-
function
|
|
66
|
+
function qt(e, n) {
|
|
67
67
|
const t = {
|
|
68
68
|
validator: () => !0,
|
|
69
69
|
default: e
|
|
70
70
|
};
|
|
71
71
|
return t;
|
|
72
72
|
}
|
|
73
|
-
function
|
|
73
|
+
function rt(e) {
|
|
74
74
|
return {
|
|
75
75
|
type: Array,
|
|
76
76
|
default: e
|
|
77
77
|
};
|
|
78
78
|
}
|
|
79
|
-
function
|
|
79
|
+
function at(e) {
|
|
80
80
|
return {
|
|
81
81
|
type: String,
|
|
82
82
|
default: e
|
|
83
83
|
};
|
|
84
84
|
}
|
|
85
|
-
function
|
|
85
|
+
function Kt(e, n) {
|
|
86
86
|
return e ? {
|
|
87
87
|
type: e,
|
|
88
|
-
default:
|
|
89
|
-
} :
|
|
88
|
+
default: n
|
|
89
|
+
} : qt(n);
|
|
90
90
|
}
|
|
91
|
-
const
|
|
92
|
-
function
|
|
91
|
+
const Yt = "data-token-hash", Be = "data-css-hash", me = "__cssinjs_instance__";
|
|
92
|
+
function be() {
|
|
93
93
|
const e = Math.random().toString(12).slice(2);
|
|
94
94
|
if (typeof document < "u" && document.head && document.body) {
|
|
95
|
-
const
|
|
95
|
+
const n = document.body.querySelectorAll(`style[${Be}]`) || [], {
|
|
96
96
|
firstChild: t
|
|
97
97
|
} = document.head;
|
|
98
|
-
Array.from(
|
|
99
|
-
r[
|
|
98
|
+
Array.from(n).forEach((r) => {
|
|
99
|
+
r[me] = r[me] || e, r[me] === e && document.head.insertBefore(r, t);
|
|
100
100
|
});
|
|
101
|
-
const
|
|
102
|
-
Array.from(document.querySelectorAll(`style[${
|
|
101
|
+
const o = {};
|
|
102
|
+
Array.from(document.querySelectorAll(`style[${Be}]`)).forEach((r) => {
|
|
103
103
|
var a;
|
|
104
|
-
const l = r.getAttribute(
|
|
105
|
-
|
|
104
|
+
const l = r.getAttribute(Be);
|
|
105
|
+
o[l] ? r[me] === e && ((a = r.parentNode) === null || a === void 0 || a.removeChild(r)) : o[l] = !0;
|
|
106
106
|
});
|
|
107
107
|
}
|
|
108
|
-
return new
|
|
108
|
+
return new Gt(e);
|
|
109
109
|
}
|
|
110
|
-
const
|
|
111
|
-
var e,
|
|
112
|
-
const
|
|
110
|
+
const kt = Symbol("StyleContextKey"), Zt = () => {
|
|
111
|
+
var e, n, t;
|
|
112
|
+
const o = Lt();
|
|
113
113
|
let r;
|
|
114
|
-
if (
|
|
115
|
-
const a = (t = (
|
|
116
|
-
a ? r = a : (r =
|
|
114
|
+
if (o && o.appContext) {
|
|
115
|
+
const a = (t = (n = (e = o.appContext) === null || e === void 0 ? void 0 : e.config) === null || n === void 0 ? void 0 : n.globalProperties) === null || t === void 0 ? void 0 : t.__ANTDV_CSSINJS_CACHE__;
|
|
116
|
+
a ? r = a : (r = be(), o.appContext.config.globalProperties && (o.appContext.config.globalProperties.__ANTDV_CSSINJS_CACHE__ = r));
|
|
117
117
|
} else
|
|
118
|
-
r =
|
|
118
|
+
r = be();
|
|
119
119
|
return r;
|
|
120
|
-
},
|
|
121
|
-
cache:
|
|
120
|
+
}, Mt = {
|
|
121
|
+
cache: be(),
|
|
122
122
|
defaultCache: !0,
|
|
123
123
|
hashPriority: "low"
|
|
124
|
-
},
|
|
125
|
-
const e =
|
|
126
|
-
return
|
|
124
|
+
}, Je = () => {
|
|
125
|
+
const e = Zt();
|
|
126
|
+
return mt(kt, ve(I(I({}, Mt), {
|
|
127
127
|
cache: e
|
|
128
128
|
})));
|
|
129
|
-
},
|
|
130
|
-
const
|
|
131
|
-
cache:
|
|
129
|
+
}, Qt = (e) => {
|
|
130
|
+
const n = Je(), t = ve(I(I({}, Mt), {
|
|
131
|
+
cache: be()
|
|
132
132
|
}));
|
|
133
|
-
return
|
|
134
|
-
const
|
|
133
|
+
return $([() => _(e), n], () => {
|
|
134
|
+
const o = I({}, n.value), r = _(e);
|
|
135
135
|
Object.keys(r).forEach((l) => {
|
|
136
|
-
const
|
|
137
|
-
r[l] !== void 0 && (
|
|
136
|
+
const s = r[l];
|
|
137
|
+
r[l] !== void 0 && (o[l] = s);
|
|
138
138
|
});
|
|
139
139
|
const {
|
|
140
140
|
cache: a
|
|
141
141
|
} = r;
|
|
142
|
-
|
|
142
|
+
o.cache = o.cache || be(), o.defaultCache = !a && n.value.defaultCache, t.value = o;
|
|
143
143
|
}, {
|
|
144
144
|
immediate: !0
|
|
145
|
-
}),
|
|
146
|
-
},
|
|
147
|
-
autoClear:
|
|
145
|
+
}), vt(kt, t), t;
|
|
146
|
+
}, Jt = () => ({
|
|
147
|
+
autoClear: He(),
|
|
148
148
|
/** @private Test only. Not work in production. */
|
|
149
|
-
mock:
|
|
149
|
+
mock: at(),
|
|
150
150
|
/**
|
|
151
151
|
* Only set when you need ssr to extract style on you own.
|
|
152
152
|
* If not provided, it will auto create <style /> on the end of Provider in server side.
|
|
153
153
|
*/
|
|
154
|
-
cache:
|
|
154
|
+
cache: wt(),
|
|
155
155
|
/** Tell children that this context is default generated context */
|
|
156
|
-
defaultCache:
|
|
156
|
+
defaultCache: He(),
|
|
157
157
|
/** Use `:where` selector to reduce hashId css selector priority */
|
|
158
|
-
hashPriority:
|
|
158
|
+
hashPriority: at(),
|
|
159
159
|
/** Tell cssinjs where to inject style in */
|
|
160
|
-
container:
|
|
160
|
+
container: Kt(),
|
|
161
161
|
/** Component wil render inline `<style />` for fallback in SSR. Not recommend. */
|
|
162
|
-
ssrInline:
|
|
162
|
+
ssrInline: He(),
|
|
163
163
|
/** Transform css before inject in document. Please note that `transformers` do not support dynamic update */
|
|
164
|
-
transformers:
|
|
164
|
+
transformers: rt(),
|
|
165
165
|
/**
|
|
166
166
|
* Linters to lint css before inject in document.
|
|
167
167
|
* Styles will be linted after transforming.
|
|
168
168
|
* Please note that `linters` do not support dynamic update.
|
|
169
169
|
*/
|
|
170
|
-
linters:
|
|
170
|
+
linters: rt()
|
|
171
171
|
});
|
|
172
|
-
|
|
172
|
+
Wt(P({
|
|
173
173
|
name: "AStyleProvider",
|
|
174
174
|
inheritAttrs: !1,
|
|
175
|
-
props:
|
|
175
|
+
props: Jt(),
|
|
176
176
|
setup(e, {
|
|
177
|
-
slots:
|
|
177
|
+
slots: n
|
|
178
178
|
}) {
|
|
179
|
-
return
|
|
179
|
+
return Qt(e), () => {
|
|
180
180
|
var t;
|
|
181
|
-
return (t =
|
|
181
|
+
return (t = n.default) === null || t === void 0 ? void 0 : t.call(n);
|
|
182
182
|
};
|
|
183
183
|
}
|
|
184
184
|
}));
|
|
185
|
-
function
|
|
185
|
+
function en() {
|
|
186
186
|
return !1;
|
|
187
187
|
}
|
|
188
|
-
let
|
|
189
|
-
function
|
|
190
|
-
return
|
|
188
|
+
let Pe = !1;
|
|
189
|
+
function tn() {
|
|
190
|
+
return Pe;
|
|
191
191
|
}
|
|
192
|
-
const
|
|
192
|
+
const nn = process.env.NODE_ENV === "production" ? en : tn;
|
|
193
193
|
if (process.env.NODE_ENV !== "production" && typeof module < "u" && module && module.hot && typeof window < "u") {
|
|
194
194
|
const e = window;
|
|
195
195
|
if (typeof e.webpackHotUpdate == "function") {
|
|
196
|
-
const
|
|
197
|
-
e.webpackHotUpdate = (...t) => (
|
|
198
|
-
|
|
199
|
-
}, 0),
|
|
196
|
+
const n = e.webpackHotUpdate;
|
|
197
|
+
e.webpackHotUpdate = (...t) => (Pe = !0, setTimeout(() => {
|
|
198
|
+
Pe = !1;
|
|
199
|
+
}, 0), n(...t));
|
|
200
200
|
}
|
|
201
201
|
}
|
|
202
|
-
function
|
|
203
|
-
const r =
|
|
204
|
-
|
|
205
|
-
a.value = [e, ...
|
|
202
|
+
function on(e, n, t, o) {
|
|
203
|
+
const r = Je(), a = ve(""), l = ve();
|
|
204
|
+
Ot(() => {
|
|
205
|
+
a.value = [e, ...n.value].join("%");
|
|
206
206
|
});
|
|
207
|
-
const
|
|
207
|
+
const s = nn(), h = (d) => {
|
|
208
208
|
r.value.cache.update(d, (u) => {
|
|
209
|
-
const [
|
|
210
|
-
return
|
|
209
|
+
const [m = 0, S] = u || [];
|
|
210
|
+
return m - 1 === 0 ? (o == null || o(S, !1), null) : [m - 1, S];
|
|
211
211
|
});
|
|
212
212
|
};
|
|
213
|
-
return
|
|
214
|
-
u &&
|
|
215
|
-
const [S = 0, x] =
|
|
216
|
-
let
|
|
217
|
-
process.env.NODE_ENV !== "production" && x &&
|
|
218
|
-
const
|
|
219
|
-
return [S + 1,
|
|
213
|
+
return $(a, (d, u) => {
|
|
214
|
+
u && h(u), r.value.cache.update(d, (m) => {
|
|
215
|
+
const [S = 0, x] = m || [];
|
|
216
|
+
let f = x;
|
|
217
|
+
process.env.NODE_ENV !== "production" && x && s && (o == null || o(f, s), f = null);
|
|
218
|
+
const k = f || t();
|
|
219
|
+
return [S + 1, k];
|
|
220
220
|
}), l.value = r.value.cache.get(a.value)[1];
|
|
221
221
|
}, {
|
|
222
222
|
immediate: !0
|
|
223
|
-
}),
|
|
224
|
-
|
|
223
|
+
}), Ke(() => {
|
|
224
|
+
h(a.value);
|
|
225
225
|
}), l;
|
|
226
226
|
}
|
|
227
|
-
function
|
|
228
|
-
if (e.length !==
|
|
227
|
+
function rn(e, n) {
|
|
228
|
+
if (e.length !== n.length)
|
|
229
229
|
return !1;
|
|
230
230
|
for (let t = 0; t < e.length; t++)
|
|
231
|
-
if (e[t] !==
|
|
231
|
+
if (e[t] !== n[t])
|
|
232
232
|
return !1;
|
|
233
233
|
return !0;
|
|
234
234
|
}
|
|
@@ -239,274 +239,274 @@ class se {
|
|
|
239
239
|
size() {
|
|
240
240
|
return this.keys.length;
|
|
241
241
|
}
|
|
242
|
-
internalGet(
|
|
243
|
-
let
|
|
242
|
+
internalGet(n, t = !1) {
|
|
243
|
+
let o = {
|
|
244
244
|
map: this.cache
|
|
245
245
|
};
|
|
246
|
-
return
|
|
246
|
+
return n.forEach((r) => {
|
|
247
247
|
var a;
|
|
248
|
-
|
|
249
|
-
}),
|
|
248
|
+
o ? o = (a = o == null ? void 0 : o.map) === null || a === void 0 ? void 0 : a.get(r) : o = void 0;
|
|
249
|
+
}), o != null && o.value && t && (o.value[1] = this.cacheCallTimes++), o == null ? void 0 : o.value;
|
|
250
250
|
}
|
|
251
|
-
get(
|
|
251
|
+
get(n) {
|
|
252
252
|
var t;
|
|
253
|
-
return (t = this.internalGet(
|
|
253
|
+
return (t = this.internalGet(n, !0)) === null || t === void 0 ? void 0 : t[0];
|
|
254
254
|
}
|
|
255
|
-
has(
|
|
256
|
-
return !!this.internalGet(
|
|
255
|
+
has(n) {
|
|
256
|
+
return !!this.internalGet(n);
|
|
257
257
|
}
|
|
258
|
-
set(
|
|
259
|
-
if (!this.has(
|
|
258
|
+
set(n, t) {
|
|
259
|
+
if (!this.has(n)) {
|
|
260
260
|
if (this.size() + 1 > se.MAX_CACHE_SIZE + se.MAX_CACHE_OFFSET) {
|
|
261
261
|
const [r] = this.keys.reduce((a, l) => {
|
|
262
|
-
const [,
|
|
263
|
-
return this.internalGet(l)[1] <
|
|
262
|
+
const [, s] = a;
|
|
263
|
+
return this.internalGet(l)[1] < s ? [l, this.internalGet(l)[1]] : a;
|
|
264
264
|
}, [this.keys[0], this.cacheCallTimes]);
|
|
265
265
|
this.delete(r);
|
|
266
266
|
}
|
|
267
|
-
this.keys.push(
|
|
267
|
+
this.keys.push(n);
|
|
268
268
|
}
|
|
269
|
-
let
|
|
270
|
-
|
|
271
|
-
if (a ===
|
|
272
|
-
|
|
269
|
+
let o = this.cache;
|
|
270
|
+
n.forEach((r, a) => {
|
|
271
|
+
if (a === n.length - 1)
|
|
272
|
+
o.set(r, {
|
|
273
273
|
value: [t, this.cacheCallTimes++]
|
|
274
274
|
});
|
|
275
275
|
else {
|
|
276
|
-
const l =
|
|
277
|
-
l ? l.map || (l.map = /* @__PURE__ */ new Map()) :
|
|
276
|
+
const l = o.get(r);
|
|
277
|
+
l ? l.map || (l.map = /* @__PURE__ */ new Map()) : o.set(r, {
|
|
278
278
|
map: /* @__PURE__ */ new Map()
|
|
279
|
-
}),
|
|
279
|
+
}), o = o.get(r).map;
|
|
280
280
|
}
|
|
281
281
|
});
|
|
282
282
|
}
|
|
283
|
-
deleteByPath(
|
|
284
|
-
var
|
|
285
|
-
const r =
|
|
283
|
+
deleteByPath(n, t) {
|
|
284
|
+
var o;
|
|
285
|
+
const r = n.get(t[0]);
|
|
286
286
|
if (t.length === 1)
|
|
287
|
-
return r.map ?
|
|
287
|
+
return r.map ? n.set(t[0], {
|
|
288
288
|
map: r.map
|
|
289
|
-
}) :
|
|
289
|
+
}) : n.delete(t[0]), (o = r.value) === null || o === void 0 ? void 0 : o[0];
|
|
290
290
|
const a = this.deleteByPath(r.map, t.slice(1));
|
|
291
|
-
return (!r.map || r.map.size === 0) && !r.value &&
|
|
291
|
+
return (!r.map || r.map.size === 0) && !r.value && n.delete(t[0]), a;
|
|
292
292
|
}
|
|
293
|
-
delete(
|
|
294
|
-
if (this.has(
|
|
295
|
-
return this.keys = this.keys.filter((t) => !
|
|
293
|
+
delete(n) {
|
|
294
|
+
if (this.has(n))
|
|
295
|
+
return this.keys = this.keys.filter((t) => !rn(t, n)), this.deleteByPath(this.cache, n);
|
|
296
296
|
}
|
|
297
297
|
}
|
|
298
298
|
se.MAX_CACHE_SIZE = 20;
|
|
299
299
|
se.MAX_CACHE_OFFSET = 5;
|
|
300
|
-
let
|
|
301
|
-
function
|
|
302
|
-
process.env.NODE_ENV !== "production" && !e && console !== void 0 && console.error(`Warning: ${
|
|
300
|
+
let Ne = {};
|
|
301
|
+
function an(e, n) {
|
|
302
|
+
process.env.NODE_ENV !== "production" && !e && console !== void 0 && console.error(`Warning: ${n}`);
|
|
303
303
|
}
|
|
304
|
-
function
|
|
305
|
-
|
|
304
|
+
function ln() {
|
|
305
|
+
Ne = {};
|
|
306
306
|
}
|
|
307
|
-
function
|
|
308
|
-
!
|
|
307
|
+
function sn(e, n, t) {
|
|
308
|
+
!n && !Ne[t] && (e(!1, t), Ne[t] = !0);
|
|
309
309
|
}
|
|
310
|
-
function
|
|
311
|
-
|
|
310
|
+
function cn(e, n) {
|
|
311
|
+
sn(an, e, n);
|
|
312
312
|
}
|
|
313
|
-
function
|
|
313
|
+
function un() {
|
|
314
314
|
}
|
|
315
|
-
let
|
|
316
|
-
process.env.NODE_ENV !== "production" && (
|
|
317
|
-
|
|
315
|
+
let Et = un;
|
|
316
|
+
process.env.NODE_ENV !== "production" && (Et = (e, n, t) => {
|
|
317
|
+
cn(e, `[ant-design-vue: ${n}] ${t}`), process.env.NODE_ENV === "test" && ln();
|
|
318
318
|
});
|
|
319
|
-
let
|
|
320
|
-
class
|
|
321
|
-
constructor(
|
|
322
|
-
this.derivatives = Array.isArray(
|
|
319
|
+
let it = 0;
|
|
320
|
+
class Tt {
|
|
321
|
+
constructor(n) {
|
|
322
|
+
this.derivatives = Array.isArray(n) ? n : [n], this.id = it, n.length === 0 && Et(n.length > 0, "[Efko дизайн Vue CSS-in-JS] Theme should have at least one derivative function."), it += 1;
|
|
323
323
|
}
|
|
324
|
-
getDerivativeToken(
|
|
325
|
-
return this.derivatives.reduce((t,
|
|
324
|
+
getDerivativeToken(n) {
|
|
325
|
+
return this.derivatives.reduce((t, o) => o(n, t), void 0);
|
|
326
326
|
}
|
|
327
327
|
}
|
|
328
|
-
const
|
|
329
|
-
function
|
|
330
|
-
const
|
|
331
|
-
return
|
|
328
|
+
const De = new se();
|
|
329
|
+
function dn(e) {
|
|
330
|
+
const n = Array.isArray(e) ? e : [e];
|
|
331
|
+
return De.has(n) || De.set(n, new Tt(n)), De.get(n);
|
|
332
332
|
}
|
|
333
|
-
const
|
|
334
|
-
function
|
|
335
|
-
let
|
|
336
|
-
return
|
|
337
|
-
const
|
|
338
|
-
|
|
339
|
-
}),
|
|
333
|
+
const lt = /* @__PURE__ */ new WeakMap();
|
|
334
|
+
function Me(e) {
|
|
335
|
+
let n = lt.get(e) || "";
|
|
336
|
+
return n || (Object.keys(e).forEach((t) => {
|
|
337
|
+
const o = e[t];
|
|
338
|
+
n += t, o instanceof Tt ? n += o.id : o && typeof o == "object" ? n += Me(o) : n += o;
|
|
339
|
+
}), lt.set(e, n)), n;
|
|
340
340
|
}
|
|
341
|
-
function
|
|
342
|
-
return
|
|
341
|
+
function fn(e, n) {
|
|
342
|
+
return Ct(`${n}_${Me(e)}`);
|
|
343
343
|
}
|
|
344
|
-
const
|
|
345
|
-
function
|
|
344
|
+
const st = {}, pn = process.env.NODE_ENV === "production", gn = process.env.NODE_ENV === "prerender", hn = !pn && !gn ? "css-dev-only-do-not-override" : "css", oe = /* @__PURE__ */ new Map();
|
|
345
|
+
function mn(e) {
|
|
346
346
|
oe.set(e, (oe.get(e) || 0) + 1);
|
|
347
347
|
}
|
|
348
|
-
function
|
|
349
|
-
typeof document < "u" && document.querySelectorAll(`style[${
|
|
348
|
+
function vn(e, n) {
|
|
349
|
+
typeof document < "u" && document.querySelectorAll(`style[${Yt}="${e}"]`).forEach((o) => {
|
|
350
350
|
var r;
|
|
351
|
-
|
|
351
|
+
o[me] === n && ((r = o.parentNode) === null || r === void 0 || r.removeChild(o));
|
|
352
352
|
});
|
|
353
353
|
}
|
|
354
|
-
const
|
|
355
|
-
function
|
|
354
|
+
const yn = 0;
|
|
355
|
+
function bn(e, n) {
|
|
356
356
|
oe.set(e, (oe.get(e) || 0) - 1);
|
|
357
|
-
const t = Array.from(oe.keys()),
|
|
358
|
-
t.length -
|
|
359
|
-
|
|
357
|
+
const t = Array.from(oe.keys()), o = t.filter((r) => (oe.get(r) || 0) <= 0);
|
|
358
|
+
t.length - o.length > yn && o.forEach((r) => {
|
|
359
|
+
vn(r, n), oe.delete(r);
|
|
360
360
|
});
|
|
361
361
|
}
|
|
362
|
-
const
|
|
362
|
+
const xn = (e, n, t, o) => {
|
|
363
363
|
const r = t.getDerivativeToken(e);
|
|
364
|
-
let a =
|
|
365
|
-
return
|
|
364
|
+
let a = I(I({}, r), n);
|
|
365
|
+
return o && (a = o(a)), a;
|
|
366
366
|
};
|
|
367
|
-
function
|
|
368
|
-
const
|
|
369
|
-
return
|
|
367
|
+
function Sn(e, n, t = L({})) {
|
|
368
|
+
const o = Je(), r = T(() => I({}, ...n.value)), a = T(() => Me(r.value)), l = T(() => Me(t.value.override || st));
|
|
369
|
+
return on("token", T(() => [t.value.salt || "", e.value.id, a.value, l.value]), () => {
|
|
370
370
|
const {
|
|
371
|
-
salt:
|
|
372
|
-
override: d =
|
|
371
|
+
salt: h = "",
|
|
372
|
+
override: d = st,
|
|
373
373
|
formatToken: u,
|
|
374
|
-
getComputedToken:
|
|
375
|
-
} = t.value, S =
|
|
376
|
-
S._tokenKey = x,
|
|
377
|
-
const
|
|
378
|
-
return S._hashId =
|
|
379
|
-
}, (
|
|
374
|
+
getComputedToken: m
|
|
375
|
+
} = t.value, S = m ? m(r.value, d, e.value) : xn(r.value, d, e.value, u), x = fn(S, h);
|
|
376
|
+
S._tokenKey = x, mn(x);
|
|
377
|
+
const f = `${hn}-${Ct(x)}`;
|
|
378
|
+
return S._hashId = f, [S, f];
|
|
379
|
+
}, (h) => {
|
|
380
380
|
var d;
|
|
381
|
-
|
|
381
|
+
bn(h[0]._tokenKey, (d = o.value) === null || d === void 0 ? void 0 : d.cache.instanceId);
|
|
382
382
|
});
|
|
383
383
|
}
|
|
384
|
-
const
|
|
385
|
-
function
|
|
386
|
-
|
|
387
|
-
var t =
|
|
388
|
-
return e =
|
|
384
|
+
const An = "1.7.0";
|
|
385
|
+
function j(e, n) {
|
|
386
|
+
Cn(e) && (e = "100%");
|
|
387
|
+
var t = wn(e);
|
|
388
|
+
return e = n === 360 ? e : Math.min(n, Math.max(0, parseFloat(e))), t && (e = parseInt(String(e * n), 10) / 100), Math.abs(e - n) < 1e-6 ? 1 : (n === 360 ? e = (e < 0 ? e % n + n : e % n) / parseFloat(String(n)) : e = e % n / parseFloat(String(n)), e);
|
|
389
389
|
}
|
|
390
|
-
function
|
|
390
|
+
function Se(e) {
|
|
391
391
|
return Math.min(1, Math.max(0, e));
|
|
392
392
|
}
|
|
393
|
-
function
|
|
393
|
+
function Cn(e) {
|
|
394
394
|
return typeof e == "string" && e.indexOf(".") !== -1 && parseFloat(e) === 1;
|
|
395
395
|
}
|
|
396
|
-
function
|
|
396
|
+
function wn(e) {
|
|
397
397
|
return typeof e == "string" && e.indexOf("%") !== -1;
|
|
398
398
|
}
|
|
399
|
-
function
|
|
399
|
+
function It(e) {
|
|
400
400
|
return e = parseFloat(e), (isNaN(e) || e < 0 || e > 1) && (e = 1), e;
|
|
401
401
|
}
|
|
402
|
-
function
|
|
402
|
+
function Ae(e) {
|
|
403
403
|
return e <= 1 ? "".concat(Number(e) * 100, "%") : e;
|
|
404
404
|
}
|
|
405
|
-
function
|
|
405
|
+
function re(e) {
|
|
406
406
|
return e.length === 1 ? "0" + e : String(e);
|
|
407
407
|
}
|
|
408
|
-
function
|
|
408
|
+
function kn(e, n, t) {
|
|
409
409
|
return {
|
|
410
|
-
r:
|
|
411
|
-
g:
|
|
412
|
-
b:
|
|
410
|
+
r: j(e, 255) * 255,
|
|
411
|
+
g: j(n, 255) * 255,
|
|
412
|
+
b: j(t, 255) * 255
|
|
413
413
|
};
|
|
414
414
|
}
|
|
415
|
-
function
|
|
416
|
-
e =
|
|
417
|
-
var
|
|
418
|
-
if (
|
|
415
|
+
function ct(e, n, t) {
|
|
416
|
+
e = j(e, 255), n = j(n, 255), t = j(t, 255);
|
|
417
|
+
var o = Math.max(e, n, t), r = Math.min(e, n, t), a = 0, l = 0, s = (o + r) / 2;
|
|
418
|
+
if (o === r)
|
|
419
419
|
l = 0, a = 0;
|
|
420
420
|
else {
|
|
421
|
-
var
|
|
422
|
-
switch (l =
|
|
421
|
+
var h = o - r;
|
|
422
|
+
switch (l = s > 0.5 ? h / (2 - o - r) : h / (o + r), o) {
|
|
423
423
|
case e:
|
|
424
|
-
a = (
|
|
424
|
+
a = (n - t) / h + (n < t ? 6 : 0);
|
|
425
425
|
break;
|
|
426
|
-
case
|
|
427
|
-
a = (t - e) /
|
|
426
|
+
case n:
|
|
427
|
+
a = (t - e) / h + 2;
|
|
428
428
|
break;
|
|
429
429
|
case t:
|
|
430
|
-
a = (e -
|
|
430
|
+
a = (e - n) / h + 4;
|
|
431
431
|
break;
|
|
432
432
|
}
|
|
433
433
|
a /= 6;
|
|
434
434
|
}
|
|
435
|
-
return { h: a, s: l, l:
|
|
435
|
+
return { h: a, s: l, l: s };
|
|
436
436
|
}
|
|
437
|
-
function
|
|
438
|
-
return t < 0 && (t += 1), t > 1 && (t -= 1), t < 1 / 6 ? e + (
|
|
437
|
+
function $e(e, n, t) {
|
|
438
|
+
return t < 0 && (t += 1), t > 1 && (t -= 1), t < 1 / 6 ? e + (n - e) * (6 * t) : t < 1 / 2 ? n : t < 2 / 3 ? e + (n - e) * (2 / 3 - t) * 6 : e;
|
|
439
439
|
}
|
|
440
|
-
function
|
|
441
|
-
var
|
|
442
|
-
if (e =
|
|
443
|
-
r = t, a = t,
|
|
440
|
+
function Mn(e, n, t) {
|
|
441
|
+
var o, r, a;
|
|
442
|
+
if (e = j(e, 360), n = j(n, 100), t = j(t, 100), n === 0)
|
|
443
|
+
r = t, a = t, o = t;
|
|
444
444
|
else {
|
|
445
|
-
var l = t < 0.5 ? t * (1 +
|
|
446
|
-
|
|
445
|
+
var l = t < 0.5 ? t * (1 + n) : t + n - t * n, s = 2 * t - l;
|
|
446
|
+
o = $e(s, l, e + 1 / 3), r = $e(s, l, e), a = $e(s, l, e - 1 / 3);
|
|
447
447
|
}
|
|
448
|
-
return { r:
|
|
448
|
+
return { r: o * 255, g: r * 255, b: a * 255 };
|
|
449
449
|
}
|
|
450
|
-
function
|
|
451
|
-
e =
|
|
452
|
-
var
|
|
453
|
-
if (
|
|
450
|
+
function je(e, n, t) {
|
|
451
|
+
e = j(e, 255), n = j(n, 255), t = j(t, 255);
|
|
452
|
+
var o = Math.max(e, n, t), r = Math.min(e, n, t), a = 0, l = o, s = o - r, h = o === 0 ? 0 : s / o;
|
|
453
|
+
if (o === r)
|
|
454
454
|
a = 0;
|
|
455
455
|
else {
|
|
456
|
-
switch (
|
|
456
|
+
switch (o) {
|
|
457
457
|
case e:
|
|
458
|
-
a = (
|
|
458
|
+
a = (n - t) / s + (n < t ? 6 : 0);
|
|
459
459
|
break;
|
|
460
|
-
case
|
|
461
|
-
a = (t - e) /
|
|
460
|
+
case n:
|
|
461
|
+
a = (t - e) / s + 2;
|
|
462
462
|
break;
|
|
463
463
|
case t:
|
|
464
|
-
a = (e -
|
|
464
|
+
a = (e - n) / s + 4;
|
|
465
465
|
break;
|
|
466
466
|
}
|
|
467
467
|
a /= 6;
|
|
468
468
|
}
|
|
469
|
-
return { h: a, s:
|
|
469
|
+
return { h: a, s: h, v: l };
|
|
470
470
|
}
|
|
471
|
-
function
|
|
472
|
-
e =
|
|
473
|
-
var
|
|
474
|
-
return { r: d * 255, g: u * 255, b:
|
|
471
|
+
function En(e, n, t) {
|
|
472
|
+
e = j(e, 360) * 6, n = j(n, 100), t = j(t, 100);
|
|
473
|
+
var o = Math.floor(e), r = e - o, a = t * (1 - n), l = t * (1 - r * n), s = t * (1 - (1 - r) * n), h = o % 6, d = [t, l, a, a, s, t][h], u = [s, t, t, l, a, a][h], m = [a, a, s, t, t, l][h];
|
|
474
|
+
return { r: d * 255, g: u * 255, b: m * 255 };
|
|
475
475
|
}
|
|
476
|
-
function
|
|
476
|
+
function Ue(e, n, t, o) {
|
|
477
477
|
var r = [
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
478
|
+
re(Math.round(e).toString(16)),
|
|
479
|
+
re(Math.round(n).toString(16)),
|
|
480
|
+
re(Math.round(t).toString(16))
|
|
481
481
|
];
|
|
482
|
-
return
|
|
482
|
+
return o && r[0].startsWith(r[0].charAt(1)) && r[1].startsWith(r[1].charAt(1)) && r[2].startsWith(r[2].charAt(1)) ? r[0].charAt(0) + r[1].charAt(0) + r[2].charAt(0) : r.join("");
|
|
483
483
|
}
|
|
484
|
-
function
|
|
484
|
+
function Tn(e, n, t, o, r) {
|
|
485
485
|
var a = [
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
486
|
+
re(Math.round(e).toString(16)),
|
|
487
|
+
re(Math.round(n).toString(16)),
|
|
488
|
+
re(Math.round(t).toString(16)),
|
|
489
|
+
re(In(o))
|
|
490
490
|
];
|
|
491
491
|
return r && a[0].startsWith(a[0].charAt(1)) && a[1].startsWith(a[1].charAt(1)) && a[2].startsWith(a[2].charAt(1)) && a[3].startsWith(a[3].charAt(1)) ? a[0].charAt(0) + a[1].charAt(0) + a[2].charAt(0) + a[3].charAt(0) : a.join("");
|
|
492
492
|
}
|
|
493
|
-
function
|
|
493
|
+
function In(e) {
|
|
494
494
|
return Math.round(parseFloat(e) * 255).toString(16);
|
|
495
495
|
}
|
|
496
|
-
function
|
|
497
|
-
return
|
|
496
|
+
function ut(e) {
|
|
497
|
+
return G(e) / 255;
|
|
498
498
|
}
|
|
499
|
-
function
|
|
499
|
+
function G(e) {
|
|
500
500
|
return parseInt(e, 16);
|
|
501
501
|
}
|
|
502
|
-
function
|
|
502
|
+
function Hn(e) {
|
|
503
503
|
return {
|
|
504
504
|
r: e >> 16,
|
|
505
505
|
g: (e & 65280) >> 8,
|
|
506
506
|
b: e & 255
|
|
507
507
|
};
|
|
508
508
|
}
|
|
509
|
-
var
|
|
509
|
+
var Xe = {
|
|
510
510
|
aliceblue: "#f0f8ff",
|
|
511
511
|
antiquewhite: "#faebd7",
|
|
512
512
|
aqua: "#00ffff",
|
|
@@ -657,116 +657,116 @@ var ze = {
|
|
|
657
657
|
yellowgreen: "#9acd32"
|
|
658
658
|
};
|
|
659
659
|
function ae(e) {
|
|
660
|
-
var
|
|
661
|
-
return typeof e == "string" && (e =
|
|
660
|
+
var n = { r: 0, g: 0, b: 0 }, t = 1, o = null, r = null, a = null, l = !1, s = !1;
|
|
661
|
+
return typeof e == "string" && (e = $n(e)), typeof e == "object" && (J(e.r) && J(e.g) && J(e.b) ? (n = kn(e.r, e.g, e.b), l = !0, s = String(e.r).substr(-1) === "%" ? "prgb" : "rgb") : J(e.h) && J(e.s) && J(e.v) ? (o = Ae(e.s), r = Ae(e.v), n = En(e.h, o, r), l = !0, s = "hsv") : J(e.h) && J(e.s) && J(e.l) && (o = Ae(e.s), a = Ae(e.l), n = Mn(e.h, o, a), l = !0, s = "hsl"), Object.prototype.hasOwnProperty.call(e, "a") && (t = e.a)), t = It(t), {
|
|
662
662
|
ok: l,
|
|
663
|
-
format: e.format ||
|
|
664
|
-
r: Math.min(255, Math.max(
|
|
665
|
-
g: Math.min(255, Math.max(
|
|
666
|
-
b: Math.min(255, Math.max(
|
|
663
|
+
format: e.format || s,
|
|
664
|
+
r: Math.min(255, Math.max(n.r, 0)),
|
|
665
|
+
g: Math.min(255, Math.max(n.g, 0)),
|
|
666
|
+
b: Math.min(255, Math.max(n.b, 0)),
|
|
667
667
|
a: t
|
|
668
668
|
};
|
|
669
669
|
}
|
|
670
|
-
var
|
|
671
|
-
CSS_UNIT: new RegExp(
|
|
672
|
-
rgb: new RegExp("rgb" +
|
|
673
|
-
rgba: new RegExp("rgba" +
|
|
674
|
-
hsl: new RegExp("hsl" +
|
|
675
|
-
hsla: new RegExp("hsla" +
|
|
676
|
-
hsv: new RegExp("hsv" +
|
|
677
|
-
hsva: new RegExp("hsva" +
|
|
670
|
+
var Bn = "[-\\+]?\\d+%?", Dn = "[-\\+]?\\d*\\.\\d+%?", ne = "(?:".concat(Dn, ")|(?:").concat(Bn, ")"), Fe = "[\\s|\\(]+(".concat(ne, ")[,|\\s]+(").concat(ne, ")[,|\\s]+(").concat(ne, ")\\s*\\)?"), Ve = "[\\s|\\(]+(".concat(ne, ")[,|\\s]+(").concat(ne, ")[,|\\s]+(").concat(ne, ")[,|\\s]+(").concat(ne, ")\\s*\\)?"), Y = {
|
|
671
|
+
CSS_UNIT: new RegExp(ne),
|
|
672
|
+
rgb: new RegExp("rgb" + Fe),
|
|
673
|
+
rgba: new RegExp("rgba" + Ve),
|
|
674
|
+
hsl: new RegExp("hsl" + Fe),
|
|
675
|
+
hsla: new RegExp("hsla" + Ve),
|
|
676
|
+
hsv: new RegExp("hsv" + Fe),
|
|
677
|
+
hsva: new RegExp("hsva" + Ve),
|
|
678
678
|
hex3: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,
|
|
679
679
|
hex6: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,
|
|
680
680
|
hex4: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,
|
|
681
681
|
hex8: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/
|
|
682
682
|
};
|
|
683
|
-
function
|
|
683
|
+
function $n(e) {
|
|
684
684
|
if (e = e.trim().toLowerCase(), e.length === 0)
|
|
685
685
|
return !1;
|
|
686
|
-
var
|
|
687
|
-
if (
|
|
688
|
-
e =
|
|
686
|
+
var n = !1;
|
|
687
|
+
if (Xe[e])
|
|
688
|
+
e = Xe[e], n = !0;
|
|
689
689
|
else if (e === "transparent")
|
|
690
690
|
return { r: 0, g: 0, b: 0, a: 0, format: "name" };
|
|
691
|
-
var t =
|
|
692
|
-
return t ? { r: t[1], g: t[2], b: t[3] } : (t =
|
|
693
|
-
r:
|
|
694
|
-
g:
|
|
695
|
-
b:
|
|
696
|
-
a:
|
|
697
|
-
format:
|
|
698
|
-
} : (t =
|
|
699
|
-
r:
|
|
700
|
-
g:
|
|
701
|
-
b:
|
|
702
|
-
format:
|
|
703
|
-
} : (t =
|
|
704
|
-
r:
|
|
705
|
-
g:
|
|
706
|
-
b:
|
|
707
|
-
a:
|
|
708
|
-
format:
|
|
709
|
-
} : (t =
|
|
710
|
-
r:
|
|
711
|
-
g:
|
|
712
|
-
b:
|
|
713
|
-
format:
|
|
691
|
+
var t = Y.rgb.exec(e);
|
|
692
|
+
return t ? { r: t[1], g: t[2], b: t[3] } : (t = Y.rgba.exec(e), t ? { r: t[1], g: t[2], b: t[3], a: t[4] } : (t = Y.hsl.exec(e), t ? { h: t[1], s: t[2], l: t[3] } : (t = Y.hsla.exec(e), t ? { h: t[1], s: t[2], l: t[3], a: t[4] } : (t = Y.hsv.exec(e), t ? { h: t[1], s: t[2], v: t[3] } : (t = Y.hsva.exec(e), t ? { h: t[1], s: t[2], v: t[3], a: t[4] } : (t = Y.hex8.exec(e), t ? {
|
|
693
|
+
r: G(t[1]),
|
|
694
|
+
g: G(t[2]),
|
|
695
|
+
b: G(t[3]),
|
|
696
|
+
a: ut(t[4]),
|
|
697
|
+
format: n ? "name" : "hex8"
|
|
698
|
+
} : (t = Y.hex6.exec(e), t ? {
|
|
699
|
+
r: G(t[1]),
|
|
700
|
+
g: G(t[2]),
|
|
701
|
+
b: G(t[3]),
|
|
702
|
+
format: n ? "name" : "hex"
|
|
703
|
+
} : (t = Y.hex4.exec(e), t ? {
|
|
704
|
+
r: G(t[1] + t[1]),
|
|
705
|
+
g: G(t[2] + t[2]),
|
|
706
|
+
b: G(t[3] + t[3]),
|
|
707
|
+
a: ut(t[4] + t[4]),
|
|
708
|
+
format: n ? "name" : "hex8"
|
|
709
|
+
} : (t = Y.hex3.exec(e), t ? {
|
|
710
|
+
r: G(t[1] + t[1]),
|
|
711
|
+
g: G(t[2] + t[2]),
|
|
712
|
+
b: G(t[3] + t[3]),
|
|
713
|
+
format: n ? "name" : "hex"
|
|
714
714
|
} : !1)))))))));
|
|
715
715
|
}
|
|
716
|
-
function
|
|
717
|
-
return !!
|
|
716
|
+
function J(e) {
|
|
717
|
+
return !!Y.CSS_UNIT.exec(String(e));
|
|
718
718
|
}
|
|
719
|
-
var
|
|
719
|
+
var Z = (
|
|
720
720
|
/** @class */
|
|
721
721
|
function() {
|
|
722
|
-
function e(
|
|
723
|
-
|
|
724
|
-
var
|
|
725
|
-
if (
|
|
726
|
-
return
|
|
727
|
-
typeof
|
|
728
|
-
var r = ae(
|
|
729
|
-
this.originalInput =
|
|
722
|
+
function e(n, t) {
|
|
723
|
+
n === void 0 && (n = ""), t === void 0 && (t = {});
|
|
724
|
+
var o;
|
|
725
|
+
if (n instanceof e)
|
|
726
|
+
return n;
|
|
727
|
+
typeof n == "number" && (n = Hn(n)), this.originalInput = n;
|
|
728
|
+
var r = ae(n);
|
|
729
|
+
this.originalInput = n, this.r = r.r, this.g = r.g, this.b = r.b, this.a = r.a, this.roundA = Math.round(100 * this.a) / 100, this.format = (o = t.format) !== null && o !== void 0 ? o : r.format, this.gradientType = t.gradientType, this.r < 1 && (this.r = Math.round(this.r)), this.g < 1 && (this.g = Math.round(this.g)), this.b < 1 && (this.b = Math.round(this.b)), this.isValid = r.ok;
|
|
730
730
|
}
|
|
731
731
|
return e.prototype.isDark = function() {
|
|
732
732
|
return this.getBrightness() < 128;
|
|
733
733
|
}, e.prototype.isLight = function() {
|
|
734
734
|
return !this.isDark();
|
|
735
735
|
}, e.prototype.getBrightness = function() {
|
|
736
|
-
var
|
|
737
|
-
return (
|
|
736
|
+
var n = this.toRgb();
|
|
737
|
+
return (n.r * 299 + n.g * 587 + n.b * 114) / 1e3;
|
|
738
738
|
}, e.prototype.getLuminance = function() {
|
|
739
|
-
var
|
|
740
|
-
return a <= 0.03928 ? t = a / 12.92 : t = Math.pow((a + 0.055) / 1.055, 2.4), l <= 0.03928 ?
|
|
739
|
+
var n = this.toRgb(), t, o, r, a = n.r / 255, l = n.g / 255, s = n.b / 255;
|
|
740
|
+
return a <= 0.03928 ? t = a / 12.92 : t = Math.pow((a + 0.055) / 1.055, 2.4), l <= 0.03928 ? o = l / 12.92 : o = Math.pow((l + 0.055) / 1.055, 2.4), s <= 0.03928 ? r = s / 12.92 : r = Math.pow((s + 0.055) / 1.055, 2.4), 0.2126 * t + 0.7152 * o + 0.0722 * r;
|
|
741
741
|
}, e.prototype.getAlpha = function() {
|
|
742
742
|
return this.a;
|
|
743
|
-
}, e.prototype.setAlpha = function(
|
|
744
|
-
return this.a =
|
|
743
|
+
}, e.prototype.setAlpha = function(n) {
|
|
744
|
+
return this.a = It(n), this.roundA = Math.round(100 * this.a) / 100, this;
|
|
745
745
|
}, e.prototype.isMonochrome = function() {
|
|
746
|
-
var
|
|
747
|
-
return
|
|
746
|
+
var n = this.toHsl().s;
|
|
747
|
+
return n === 0;
|
|
748
748
|
}, e.prototype.toHsv = function() {
|
|
749
|
-
var
|
|
750
|
-
return { h:
|
|
749
|
+
var n = je(this.r, this.g, this.b);
|
|
750
|
+
return { h: n.h * 360, s: n.s, v: n.v, a: this.a };
|
|
751
751
|
}, e.prototype.toHsvString = function() {
|
|
752
|
-
var
|
|
753
|
-
return this.a === 1 ? "hsv(".concat(t, ", ").concat(
|
|
752
|
+
var n = je(this.r, this.g, this.b), t = Math.round(n.h * 360), o = Math.round(n.s * 100), r = Math.round(n.v * 100);
|
|
753
|
+
return this.a === 1 ? "hsv(".concat(t, ", ").concat(o, "%, ").concat(r, "%)") : "hsva(".concat(t, ", ").concat(o, "%, ").concat(r, "%, ").concat(this.roundA, ")");
|
|
754
754
|
}, e.prototype.toHsl = function() {
|
|
755
|
-
var
|
|
756
|
-
return { h:
|
|
755
|
+
var n = ct(this.r, this.g, this.b);
|
|
756
|
+
return { h: n.h * 360, s: n.s, l: n.l, a: this.a };
|
|
757
757
|
}, e.prototype.toHslString = function() {
|
|
758
|
-
var
|
|
759
|
-
return this.a === 1 ? "hsl(".concat(t, ", ").concat(
|
|
760
|
-
}, e.prototype.toHex = function(
|
|
761
|
-
return
|
|
762
|
-
}, e.prototype.toHexString = function(
|
|
763
|
-
return
|
|
764
|
-
}, e.prototype.toHex8 = function(
|
|
765
|
-
return
|
|
766
|
-
}, e.prototype.toHex8String = function(
|
|
767
|
-
return
|
|
768
|
-
}, e.prototype.toHexShortString = function(
|
|
769
|
-
return
|
|
758
|
+
var n = ct(this.r, this.g, this.b), t = Math.round(n.h * 360), o = Math.round(n.s * 100), r = Math.round(n.l * 100);
|
|
759
|
+
return this.a === 1 ? "hsl(".concat(t, ", ").concat(o, "%, ").concat(r, "%)") : "hsla(".concat(t, ", ").concat(o, "%, ").concat(r, "%, ").concat(this.roundA, ")");
|
|
760
|
+
}, e.prototype.toHex = function(n) {
|
|
761
|
+
return n === void 0 && (n = !1), Ue(this.r, this.g, this.b, n);
|
|
762
|
+
}, e.prototype.toHexString = function(n) {
|
|
763
|
+
return n === void 0 && (n = !1), "#" + this.toHex(n);
|
|
764
|
+
}, e.prototype.toHex8 = function(n) {
|
|
765
|
+
return n === void 0 && (n = !1), Tn(this.r, this.g, this.b, this.a, n);
|
|
766
|
+
}, e.prototype.toHex8String = function(n) {
|
|
767
|
+
return n === void 0 && (n = !1), "#" + this.toHex8(n);
|
|
768
|
+
}, e.prototype.toHexShortString = function(n) {
|
|
769
|
+
return n === void 0 && (n = !1), this.a === 1 ? this.toHexString(n) : this.toHex8String(n);
|
|
770
770
|
}, e.prototype.toRgb = function() {
|
|
771
771
|
return {
|
|
772
772
|
r: Math.round(this.r),
|
|
@@ -775,123 +775,123 @@ var q = (
|
|
|
775
775
|
a: this.a
|
|
776
776
|
};
|
|
777
777
|
}, e.prototype.toRgbString = function() {
|
|
778
|
-
var
|
|
779
|
-
return this.a === 1 ? "rgb(".concat(
|
|
778
|
+
var n = Math.round(this.r), t = Math.round(this.g), o = Math.round(this.b);
|
|
779
|
+
return this.a === 1 ? "rgb(".concat(n, ", ").concat(t, ", ").concat(o, ")") : "rgba(".concat(n, ", ").concat(t, ", ").concat(o, ", ").concat(this.roundA, ")");
|
|
780
780
|
}, e.prototype.toPercentageRgb = function() {
|
|
781
|
-
var
|
|
782
|
-
return "".concat(Math.round(
|
|
781
|
+
var n = function(t) {
|
|
782
|
+
return "".concat(Math.round(j(t, 255) * 100), "%");
|
|
783
783
|
};
|
|
784
784
|
return {
|
|
785
|
-
r:
|
|
786
|
-
g:
|
|
787
|
-
b:
|
|
785
|
+
r: n(this.r),
|
|
786
|
+
g: n(this.g),
|
|
787
|
+
b: n(this.b),
|
|
788
788
|
a: this.a
|
|
789
789
|
};
|
|
790
790
|
}, e.prototype.toPercentageRgbString = function() {
|
|
791
|
-
var
|
|
792
|
-
return Math.round(
|
|
791
|
+
var n = function(t) {
|
|
792
|
+
return Math.round(j(t, 255) * 100);
|
|
793
793
|
};
|
|
794
|
-
return this.a === 1 ? "rgb(".concat(
|
|
794
|
+
return this.a === 1 ? "rgb(".concat(n(this.r), "%, ").concat(n(this.g), "%, ").concat(n(this.b), "%)") : "rgba(".concat(n(this.r), "%, ").concat(n(this.g), "%, ").concat(n(this.b), "%, ").concat(this.roundA, ")");
|
|
795
795
|
}, e.prototype.toName = function() {
|
|
796
796
|
if (this.a === 0)
|
|
797
797
|
return "transparent";
|
|
798
798
|
if (this.a < 1)
|
|
799
799
|
return !1;
|
|
800
|
-
for (var
|
|
801
|
-
var r =
|
|
802
|
-
if (
|
|
800
|
+
for (var n = "#" + Ue(this.r, this.g, this.b, !1), t = 0, o = Object.entries(Xe); t < o.length; t++) {
|
|
801
|
+
var r = o[t], a = r[0], l = r[1];
|
|
802
|
+
if (n === l)
|
|
803
803
|
return a;
|
|
804
804
|
}
|
|
805
805
|
return !1;
|
|
806
|
-
}, e.prototype.toString = function(
|
|
807
|
-
var t = !!
|
|
808
|
-
|
|
809
|
-
var
|
|
810
|
-
return a ?
|
|
806
|
+
}, e.prototype.toString = function(n) {
|
|
807
|
+
var t = !!n;
|
|
808
|
+
n = n ?? this.format;
|
|
809
|
+
var o = !1, r = this.a < 1 && this.a >= 0, a = !t && r && (n.startsWith("hex") || n === "name");
|
|
810
|
+
return a ? n === "name" && this.a === 0 ? this.toName() : this.toRgbString() : (n === "rgb" && (o = this.toRgbString()), n === "prgb" && (o = this.toPercentageRgbString()), (n === "hex" || n === "hex6") && (o = this.toHexString()), n === "hex3" && (o = this.toHexString(!0)), n === "hex4" && (o = this.toHex8String(!0)), n === "hex8" && (o = this.toHex8String()), n === "name" && (o = this.toName()), n === "hsl" && (o = this.toHslString()), n === "hsv" && (o = this.toHsvString()), o || this.toHexString());
|
|
811
811
|
}, e.prototype.toNumber = function() {
|
|
812
812
|
return (Math.round(this.r) << 16) + (Math.round(this.g) << 8) + Math.round(this.b);
|
|
813
813
|
}, e.prototype.clone = function() {
|
|
814
814
|
return new e(this.toString());
|
|
815
|
-
}, e.prototype.lighten = function(
|
|
816
|
-
|
|
815
|
+
}, e.prototype.lighten = function(n) {
|
|
816
|
+
n === void 0 && (n = 10);
|
|
817
817
|
var t = this.toHsl();
|
|
818
|
-
return t.l +=
|
|
819
|
-
}, e.prototype.brighten = function(
|
|
820
|
-
|
|
818
|
+
return t.l += n / 100, t.l = Se(t.l), new e(t);
|
|
819
|
+
}, e.prototype.brighten = function(n) {
|
|
820
|
+
n === void 0 && (n = 10);
|
|
821
821
|
var t = this.toRgb();
|
|
822
|
-
return t.r = Math.max(0, Math.min(255, t.r - Math.round(255 * -(
|
|
823
|
-
}, e.prototype.darken = function(
|
|
824
|
-
|
|
822
|
+
return t.r = Math.max(0, Math.min(255, t.r - Math.round(255 * -(n / 100)))), t.g = Math.max(0, Math.min(255, t.g - Math.round(255 * -(n / 100)))), t.b = Math.max(0, Math.min(255, t.b - Math.round(255 * -(n / 100)))), new e(t);
|
|
823
|
+
}, e.prototype.darken = function(n) {
|
|
824
|
+
n === void 0 && (n = 10);
|
|
825
825
|
var t = this.toHsl();
|
|
826
|
-
return t.l -=
|
|
827
|
-
}, e.prototype.tint = function(
|
|
828
|
-
return
|
|
829
|
-
}, e.prototype.shade = function(
|
|
830
|
-
return
|
|
831
|
-
}, e.prototype.desaturate = function(
|
|
832
|
-
|
|
826
|
+
return t.l -= n / 100, t.l = Se(t.l), new e(t);
|
|
827
|
+
}, e.prototype.tint = function(n) {
|
|
828
|
+
return n === void 0 && (n = 10), this.mix("white", n);
|
|
829
|
+
}, e.prototype.shade = function(n) {
|
|
830
|
+
return n === void 0 && (n = 10), this.mix("black", n);
|
|
831
|
+
}, e.prototype.desaturate = function(n) {
|
|
832
|
+
n === void 0 && (n = 10);
|
|
833
833
|
var t = this.toHsl();
|
|
834
|
-
return t.s -=
|
|
835
|
-
}, e.prototype.saturate = function(
|
|
836
|
-
|
|
834
|
+
return t.s -= n / 100, t.s = Se(t.s), new e(t);
|
|
835
|
+
}, e.prototype.saturate = function(n) {
|
|
836
|
+
n === void 0 && (n = 10);
|
|
837
837
|
var t = this.toHsl();
|
|
838
|
-
return t.s +=
|
|
838
|
+
return t.s += n / 100, t.s = Se(t.s), new e(t);
|
|
839
839
|
}, e.prototype.greyscale = function() {
|
|
840
840
|
return this.desaturate(100);
|
|
841
|
-
}, e.prototype.spin = function(
|
|
842
|
-
var t = this.toHsl(),
|
|
843
|
-
return t.h =
|
|
844
|
-
}, e.prototype.mix = function(
|
|
841
|
+
}, e.prototype.spin = function(n) {
|
|
842
|
+
var t = this.toHsl(), o = (t.h + n) % 360;
|
|
843
|
+
return t.h = o < 0 ? 360 + o : o, new e(t);
|
|
844
|
+
}, e.prototype.mix = function(n, t) {
|
|
845
845
|
t === void 0 && (t = 50);
|
|
846
|
-
var
|
|
847
|
-
r: (r.r -
|
|
848
|
-
g: (r.g -
|
|
849
|
-
b: (r.b -
|
|
850
|
-
a: (r.a -
|
|
846
|
+
var o = this.toRgb(), r = new e(n).toRgb(), a = t / 100, l = {
|
|
847
|
+
r: (r.r - o.r) * a + o.r,
|
|
848
|
+
g: (r.g - o.g) * a + o.g,
|
|
849
|
+
b: (r.b - o.b) * a + o.b,
|
|
850
|
+
a: (r.a - o.a) * a + o.a
|
|
851
851
|
};
|
|
852
852
|
return new e(l);
|
|
853
|
-
}, e.prototype.analogous = function(
|
|
854
|
-
|
|
855
|
-
var
|
|
856
|
-
for (
|
|
857
|
-
|
|
853
|
+
}, e.prototype.analogous = function(n, t) {
|
|
854
|
+
n === void 0 && (n = 6), t === void 0 && (t = 30);
|
|
855
|
+
var o = this.toHsl(), r = 360 / t, a = [this];
|
|
856
|
+
for (o.h = (o.h - (r * n >> 1) + 720) % 360; --n; )
|
|
857
|
+
o.h = (o.h + r) % 360, a.push(new e(o));
|
|
858
858
|
return a;
|
|
859
859
|
}, e.prototype.complement = function() {
|
|
860
|
-
var
|
|
861
|
-
return
|
|
862
|
-
}, e.prototype.monochromatic = function(
|
|
863
|
-
|
|
864
|
-
for (var t = this.toHsv(),
|
|
865
|
-
l.push(new e({ h:
|
|
860
|
+
var n = this.toHsl();
|
|
861
|
+
return n.h = (n.h + 180) % 360, new e(n);
|
|
862
|
+
}, e.prototype.monochromatic = function(n) {
|
|
863
|
+
n === void 0 && (n = 6);
|
|
864
|
+
for (var t = this.toHsv(), o = t.h, r = t.s, a = t.v, l = [], s = 1 / n; n--; )
|
|
865
|
+
l.push(new e({ h: o, s: r, v: a })), a = (a + s) % 1;
|
|
866
866
|
return l;
|
|
867
867
|
}, e.prototype.splitcomplement = function() {
|
|
868
|
-
var
|
|
868
|
+
var n = this.toHsl(), t = n.h;
|
|
869
869
|
return [
|
|
870
870
|
this,
|
|
871
|
-
new e({ h: (t + 72) % 360, s:
|
|
872
|
-
new e({ h: (t + 216) % 360, s:
|
|
871
|
+
new e({ h: (t + 72) % 360, s: n.s, l: n.l }),
|
|
872
|
+
new e({ h: (t + 216) % 360, s: n.s, l: n.l })
|
|
873
873
|
];
|
|
874
|
-
}, e.prototype.onBackground = function(
|
|
875
|
-
var t = this.toRgb(),
|
|
874
|
+
}, e.prototype.onBackground = function(n) {
|
|
875
|
+
var t = this.toRgb(), o = new e(n).toRgb(), r = t.a + o.a * (1 - t.a);
|
|
876
876
|
return new e({
|
|
877
|
-
r: (t.r * t.a +
|
|
878
|
-
g: (t.g * t.a +
|
|
879
|
-
b: (t.b * t.a +
|
|
877
|
+
r: (t.r * t.a + o.r * o.a * (1 - t.a)) / r,
|
|
878
|
+
g: (t.g * t.a + o.g * o.a * (1 - t.a)) / r,
|
|
879
|
+
b: (t.b * t.a + o.b * o.a * (1 - t.a)) / r,
|
|
880
880
|
a: r
|
|
881
881
|
});
|
|
882
882
|
}, e.prototype.triad = function() {
|
|
883
883
|
return this.polyad(3);
|
|
884
884
|
}, e.prototype.tetrad = function() {
|
|
885
885
|
return this.polyad(4);
|
|
886
|
-
}, e.prototype.polyad = function(
|
|
887
|
-
for (var t = this.toHsl(),
|
|
888
|
-
r.push(new e({ h: (
|
|
886
|
+
}, e.prototype.polyad = function(n) {
|
|
887
|
+
for (var t = this.toHsl(), o = t.h, r = [this], a = 360 / n, l = 1; l < n; l++)
|
|
888
|
+
r.push(new e({ h: (o + l * a) % 360, s: t.s, l: t.l }));
|
|
889
889
|
return r;
|
|
890
|
-
}, e.prototype.equals = function(
|
|
891
|
-
return this.toRgbString() === new e(
|
|
890
|
+
}, e.prototype.equals = function(n) {
|
|
891
|
+
return this.toRgbString() === new e(n).toRgbString();
|
|
892
892
|
}, e;
|
|
893
893
|
}()
|
|
894
|
-
),
|
|
894
|
+
), Ce = 2, dt = 0.16, Fn = 0.05, Vn = 0.05, _n = 0.15, Ht = 5, Bt = 4, Rn = [{
|
|
895
895
|
index: 7,
|
|
896
896
|
opacity: 0.15
|
|
897
897
|
}, {
|
|
@@ -922,64 +922,64 @@ var q = (
|
|
|
922
922
|
index: 1,
|
|
923
923
|
opacity: 0.98
|
|
924
924
|
}];
|
|
925
|
-
function
|
|
926
|
-
var
|
|
925
|
+
function ft(e) {
|
|
926
|
+
var n = e.r, t = e.g, o = e.b, r = je(n, t, o);
|
|
927
927
|
return {
|
|
928
928
|
h: r.h * 360,
|
|
929
929
|
s: r.s,
|
|
930
930
|
v: r.v
|
|
931
931
|
};
|
|
932
932
|
}
|
|
933
|
-
function
|
|
934
|
-
var
|
|
935
|
-
return "#".concat(
|
|
933
|
+
function we(e) {
|
|
934
|
+
var n = e.r, t = e.g, o = e.b;
|
|
935
|
+
return "#".concat(Ue(n, t, o, !1));
|
|
936
936
|
}
|
|
937
|
-
function
|
|
938
|
-
var
|
|
939
|
-
r: (
|
|
940
|
-
g: (
|
|
941
|
-
b: (
|
|
937
|
+
function Ln(e, n, t) {
|
|
938
|
+
var o = t / 100, r = {
|
|
939
|
+
r: (n.r - e.r) * o + e.r,
|
|
940
|
+
g: (n.g - e.g) * o + e.g,
|
|
941
|
+
b: (n.b - e.b) * o + e.b
|
|
942
942
|
};
|
|
943
943
|
return r;
|
|
944
944
|
}
|
|
945
|
-
function
|
|
946
|
-
var
|
|
947
|
-
return Math.round(e.h) >= 60 && Math.round(e.h) <= 240 ?
|
|
945
|
+
function pt(e, n, t) {
|
|
946
|
+
var o;
|
|
947
|
+
return Math.round(e.h) >= 60 && Math.round(e.h) <= 240 ? o = t ? Math.round(e.h) - Ce * n : Math.round(e.h) + Ce * n : o = t ? Math.round(e.h) + Ce * n : Math.round(e.h) - Ce * n, o < 0 ? o += 360 : o >= 360 && (o -= 360), o;
|
|
948
948
|
}
|
|
949
|
-
function
|
|
949
|
+
function gt(e, n, t) {
|
|
950
950
|
if (e.h === 0 && e.s === 0)
|
|
951
951
|
return e.s;
|
|
952
|
-
var
|
|
953
|
-
return t ?
|
|
954
|
-
}
|
|
955
|
-
function
|
|
956
|
-
var
|
|
957
|
-
return t ?
|
|
958
|
-
}
|
|
959
|
-
function
|
|
960
|
-
for (var
|
|
961
|
-
var a =
|
|
962
|
-
h:
|
|
963
|
-
s:
|
|
964
|
-
v:
|
|
952
|
+
var o;
|
|
953
|
+
return t ? o = e.s - dt * n : n === Bt ? o = e.s + dt : o = e.s + Fn * n, o > 1 && (o = 1), t && n === Ht && o > 0.1 && (o = 0.1), o < 0.06 && (o = 0.06), Number(o.toFixed(2));
|
|
954
|
+
}
|
|
955
|
+
function ht(e, n, t) {
|
|
956
|
+
var o;
|
|
957
|
+
return t ? o = e.v + Vn * n : o = e.v - _n * n, o > 1 && (o = 1), Number(o.toFixed(2));
|
|
958
|
+
}
|
|
959
|
+
function Ee(e) {
|
|
960
|
+
for (var n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, t = [], o = ae(e), r = Ht; r > 0; r -= 1) {
|
|
961
|
+
var a = ft(o), l = we(ae({
|
|
962
|
+
h: pt(a, r, !0),
|
|
963
|
+
s: gt(a, r, !0),
|
|
964
|
+
v: ht(a, r, !0)
|
|
965
965
|
}));
|
|
966
966
|
t.push(l);
|
|
967
967
|
}
|
|
968
|
-
t.push(
|
|
969
|
-
for (var
|
|
970
|
-
var
|
|
971
|
-
h:
|
|
972
|
-
s:
|
|
973
|
-
v:
|
|
968
|
+
t.push(we(o));
|
|
969
|
+
for (var s = 1; s <= Bt; s += 1) {
|
|
970
|
+
var h = ft(o), d = we(ae({
|
|
971
|
+
h: pt(h, s),
|
|
972
|
+
s: gt(h, s),
|
|
973
|
+
v: ht(h, s)
|
|
974
974
|
}));
|
|
975
975
|
t.push(d);
|
|
976
976
|
}
|
|
977
|
-
return
|
|
978
|
-
var
|
|
977
|
+
return n.theme === "dark" ? Rn.map(function(u) {
|
|
978
|
+
var m = u.index, S = u.opacity, x = we(Ln(ae(n.backgroundColor || "#141414"), ae(t[m]), S * 100));
|
|
979
979
|
return x;
|
|
980
980
|
}) : t;
|
|
981
981
|
}
|
|
982
|
-
var
|
|
982
|
+
var _e = {
|
|
983
983
|
red: "#F5222D",
|
|
984
984
|
volcano: "#FA541C",
|
|
985
985
|
orange: "#FA8C16",
|
|
@@ -993,50 +993,50 @@ var Be = {
|
|
|
993
993
|
purple: "#722ED1",
|
|
994
994
|
magenta: "#EB2F96",
|
|
995
995
|
grey: "#666666"
|
|
996
|
-
},
|
|
997
|
-
Object.keys(
|
|
998
|
-
|
|
996
|
+
}, Re = {}, Le = {};
|
|
997
|
+
Object.keys(_e).forEach(function(e) {
|
|
998
|
+
Re[e] = Ee(_e[e]), Re[e].primary = Re[e][5], Le[e] = Ee(_e[e], {
|
|
999
999
|
theme: "dark",
|
|
1000
1000
|
backgroundColor: "#141414"
|
|
1001
|
-
}),
|
|
1001
|
+
}), Le[e].primary = Le[e][5];
|
|
1002
1002
|
});
|
|
1003
|
-
const
|
|
1003
|
+
const On = (e) => {
|
|
1004
1004
|
const {
|
|
1005
|
-
controlHeight:
|
|
1005
|
+
controlHeight: n
|
|
1006
1006
|
} = e;
|
|
1007
1007
|
return {
|
|
1008
|
-
controlHeightSM:
|
|
1009
|
-
controlHeightXS:
|
|
1010
|
-
controlHeightLG:
|
|
1008
|
+
controlHeightSM: n * 0.75,
|
|
1009
|
+
controlHeightXS: n * 0.5,
|
|
1010
|
+
controlHeightLG: n * 1.25
|
|
1011
1011
|
};
|
|
1012
1012
|
};
|
|
1013
|
-
function
|
|
1013
|
+
function zn(e) {
|
|
1014
1014
|
const {
|
|
1015
|
-
sizeUnit:
|
|
1015
|
+
sizeUnit: n,
|
|
1016
1016
|
sizeStep: t
|
|
1017
1017
|
} = e;
|
|
1018
1018
|
return {
|
|
1019
|
-
sizeXXL:
|
|
1019
|
+
sizeXXL: n * (t + 8),
|
|
1020
1020
|
// 48
|
|
1021
|
-
sizeXL:
|
|
1021
|
+
sizeXL: n * (t + 4),
|
|
1022
1022
|
// 32
|
|
1023
|
-
sizeLG:
|
|
1023
|
+
sizeLG: n * (t + 2),
|
|
1024
1024
|
// 24
|
|
1025
|
-
sizeMD:
|
|
1025
|
+
sizeMD: n * (t + 1),
|
|
1026
1026
|
// 20
|
|
1027
|
-
sizeMS:
|
|
1027
|
+
sizeMS: n * t,
|
|
1028
1028
|
// 16
|
|
1029
|
-
size:
|
|
1029
|
+
size: n * t,
|
|
1030
1030
|
// 16
|
|
1031
|
-
sizeSM:
|
|
1031
|
+
sizeSM: n * (t - 1),
|
|
1032
1032
|
// 12
|
|
1033
|
-
sizeXS:
|
|
1033
|
+
sizeXS: n * (t - 2),
|
|
1034
1034
|
// 8
|
|
1035
|
-
sizeXXS:
|
|
1035
|
+
sizeXXS: n * (t - 3)
|
|
1036
1036
|
// 4
|
|
1037
1037
|
};
|
|
1038
1038
|
}
|
|
1039
|
-
const
|
|
1039
|
+
const Dt = {
|
|
1040
1040
|
blue: "#1677ff",
|
|
1041
1041
|
purple: "#722ED1",
|
|
1042
1042
|
cyan: "#13C2C2",
|
|
@@ -1050,7 +1050,7 @@ const Ht = {
|
|
|
1050
1050
|
geekblue: "#2F54EB",
|
|
1051
1051
|
gold: "#FAAD14",
|
|
1052
1052
|
lime: "#A0D911"
|
|
1053
|
-
},
|
|
1053
|
+
}, et = I(I({}, Dt), {
|
|
1054
1054
|
// Color
|
|
1055
1055
|
colorPrimary: "#1677ff",
|
|
1056
1056
|
colorSuccess: "#52c41a",
|
|
@@ -1094,20 +1094,20 @@ const Ht = {
|
|
|
1094
1094
|
// Wireframe
|
|
1095
1095
|
wireframe: !1
|
|
1096
1096
|
});
|
|
1097
|
-
function
|
|
1098
|
-
generateColorPalettes:
|
|
1097
|
+
function Pn(e, {
|
|
1098
|
+
generateColorPalettes: n,
|
|
1099
1099
|
generateNeutralColorPalettes: t
|
|
1100
1100
|
}) {
|
|
1101
1101
|
const {
|
|
1102
|
-
colorSuccess:
|
|
1102
|
+
colorSuccess: o,
|
|
1103
1103
|
colorWarning: r,
|
|
1104
1104
|
colorError: a,
|
|
1105
1105
|
colorInfo: l,
|
|
1106
|
-
colorPrimary:
|
|
1107
|
-
colorBgBase:
|
|
1106
|
+
colorPrimary: s,
|
|
1107
|
+
colorBgBase: h,
|
|
1108
1108
|
colorTextBase: d
|
|
1109
|
-
} = e, u =
|
|
1110
|
-
return
|
|
1109
|
+
} = e, u = n(s), m = n(o), S = n(r), x = n(a), f = n(l), k = t(h, d);
|
|
1110
|
+
return I(I({}, k), {
|
|
1111
1111
|
colorPrimaryBg: u[1],
|
|
1112
1112
|
colorPrimaryBgHover: u[2],
|
|
1113
1113
|
colorPrimaryBorder: u[3],
|
|
@@ -1118,16 +1118,16 @@ function Lo(e, {
|
|
|
1118
1118
|
colorPrimaryTextHover: u[8],
|
|
1119
1119
|
colorPrimaryText: u[9],
|
|
1120
1120
|
colorPrimaryTextActive: u[10],
|
|
1121
|
-
colorSuccessBg:
|
|
1122
|
-
colorSuccessBgHover:
|
|
1123
|
-
colorSuccessBorder:
|
|
1124
|
-
colorSuccessBorderHover:
|
|
1125
|
-
colorSuccessHover:
|
|
1126
|
-
colorSuccess:
|
|
1127
|
-
colorSuccessActive:
|
|
1128
|
-
colorSuccessTextHover:
|
|
1129
|
-
colorSuccessText:
|
|
1130
|
-
colorSuccessTextActive:
|
|
1121
|
+
colorSuccessBg: m[1],
|
|
1122
|
+
colorSuccessBgHover: m[2],
|
|
1123
|
+
colorSuccessBorder: m[3],
|
|
1124
|
+
colorSuccessBorderHover: m[4],
|
|
1125
|
+
colorSuccessHover: m[4],
|
|
1126
|
+
colorSuccess: m[6],
|
|
1127
|
+
colorSuccessActive: m[7],
|
|
1128
|
+
colorSuccessTextHover: m[8],
|
|
1129
|
+
colorSuccessText: m[9],
|
|
1130
|
+
colorSuccessTextActive: m[10],
|
|
1131
1131
|
colorErrorBg: x[1],
|
|
1132
1132
|
colorErrorBgHover: x[2],
|
|
1133
1133
|
colorErrorBorder: x[3],
|
|
@@ -1148,99 +1148,99 @@ function Lo(e, {
|
|
|
1148
1148
|
colorWarningTextHover: S[8],
|
|
1149
1149
|
colorWarningText: S[9],
|
|
1150
1150
|
colorWarningTextActive: S[10],
|
|
1151
|
-
colorInfoBg:
|
|
1152
|
-
colorInfoBgHover:
|
|
1153
|
-
colorInfoBorder:
|
|
1154
|
-
colorInfoBorderHover:
|
|
1155
|
-
colorInfoHover:
|
|
1156
|
-
colorInfo:
|
|
1157
|
-
colorInfoActive:
|
|
1158
|
-
colorInfoTextHover:
|
|
1159
|
-
colorInfoText:
|
|
1160
|
-
colorInfoTextActive:
|
|
1161
|
-
colorBgMask: new
|
|
1151
|
+
colorInfoBg: f[1],
|
|
1152
|
+
colorInfoBgHover: f[2],
|
|
1153
|
+
colorInfoBorder: f[3],
|
|
1154
|
+
colorInfoBorderHover: f[4],
|
|
1155
|
+
colorInfoHover: f[4],
|
|
1156
|
+
colorInfo: f[6],
|
|
1157
|
+
colorInfoActive: f[7],
|
|
1158
|
+
colorInfoTextHover: f[8],
|
|
1159
|
+
colorInfoText: f[9],
|
|
1160
|
+
colorInfoTextActive: f[10],
|
|
1161
|
+
colorBgMask: new Z("#000").setAlpha(0.45).toRgbString(),
|
|
1162
1162
|
colorWhite: "#fff"
|
|
1163
1163
|
});
|
|
1164
1164
|
}
|
|
1165
|
-
const
|
|
1166
|
-
let
|
|
1167
|
-
return e < 6 && e >= 5 ?
|
|
1165
|
+
const Nn = (e) => {
|
|
1166
|
+
let n = e, t = e, o = e, r = e;
|
|
1167
|
+
return e < 6 && e >= 5 ? n = e + 1 : e < 16 && e >= 6 ? n = e + 2 : e >= 16 && (n = 16), e < 7 && e >= 5 ? t = 4 : e < 8 && e >= 7 ? t = 5 : e < 14 && e >= 8 ? t = 6 : e < 16 && e >= 14 ? t = 7 : e >= 16 && (t = 8), e < 6 && e >= 2 ? o = 1 : e >= 6 && (o = 2), e > 4 && e < 8 ? r = 4 : e >= 8 && (r = 6), {
|
|
1168
1168
|
borderRadius: e > 16 ? 16 : e,
|
|
1169
|
-
borderRadiusXS:
|
|
1169
|
+
borderRadiusXS: o,
|
|
1170
1170
|
borderRadiusSM: t,
|
|
1171
|
-
borderRadiusLG:
|
|
1171
|
+
borderRadiusLG: n,
|
|
1172
1172
|
borderRadiusOuter: r
|
|
1173
1173
|
};
|
|
1174
1174
|
};
|
|
1175
|
-
function
|
|
1175
|
+
function jn(e) {
|
|
1176
1176
|
const {
|
|
1177
|
-
motionUnit:
|
|
1177
|
+
motionUnit: n,
|
|
1178
1178
|
motionBase: t,
|
|
1179
|
-
borderRadius:
|
|
1179
|
+
borderRadius: o,
|
|
1180
1180
|
lineWidth: r
|
|
1181
1181
|
} = e;
|
|
1182
|
-
return
|
|
1182
|
+
return I({
|
|
1183
1183
|
// motion
|
|
1184
|
-
motionDurationFast: `${(t +
|
|
1185
|
-
motionDurationMid: `${(t +
|
|
1186
|
-
motionDurationSlow: `${(t +
|
|
1184
|
+
motionDurationFast: `${(t + n).toFixed(1)}s`,
|
|
1185
|
+
motionDurationMid: `${(t + n * 2).toFixed(1)}s`,
|
|
1186
|
+
motionDurationSlow: `${(t + n * 3).toFixed(1)}s`,
|
|
1187
1187
|
// line
|
|
1188
1188
|
lineWidthBold: r + 1
|
|
1189
|
-
},
|
|
1189
|
+
}, Nn(o));
|
|
1190
1190
|
}
|
|
1191
|
-
const
|
|
1192
|
-
const
|
|
1191
|
+
const ee = (e, n) => new Z(e).setAlpha(n).toRgbString(), he = (e, n) => new Z(e).darken(n).toHexString(), Un = (e) => {
|
|
1192
|
+
const n = Ee(e);
|
|
1193
1193
|
return {
|
|
1194
|
-
1:
|
|
1195
|
-
2:
|
|
1196
|
-
3:
|
|
1197
|
-
4:
|
|
1198
|
-
5:
|
|
1199
|
-
6:
|
|
1200
|
-
7:
|
|
1201
|
-
8:
|
|
1202
|
-
9:
|
|
1203
|
-
10:
|
|
1194
|
+
1: n[0],
|
|
1195
|
+
2: n[1],
|
|
1196
|
+
3: n[2],
|
|
1197
|
+
4: n[3],
|
|
1198
|
+
5: n[4],
|
|
1199
|
+
6: n[5],
|
|
1200
|
+
7: n[6],
|
|
1201
|
+
8: n[4],
|
|
1202
|
+
9: n[5],
|
|
1203
|
+
10: n[6]
|
|
1204
1204
|
// 8: colors[7],
|
|
1205
1205
|
// 9: colors[8],
|
|
1206
1206
|
// 10: colors[9],
|
|
1207
1207
|
};
|
|
1208
|
-
},
|
|
1209
|
-
const t = e || "#fff",
|
|
1208
|
+
}, Xn = (e, n) => {
|
|
1209
|
+
const t = e || "#fff", o = n || "#000";
|
|
1210
1210
|
return {
|
|
1211
1211
|
colorBgBase: t,
|
|
1212
|
-
colorTextBase:
|
|
1213
|
-
colorText:
|
|
1214
|
-
colorTextSecondary:
|
|
1215
|
-
colorTextTertiary:
|
|
1216
|
-
colorTextQuaternary:
|
|
1217
|
-
colorFill:
|
|
1218
|
-
colorFillSecondary:
|
|
1219
|
-
colorFillTertiary:
|
|
1220
|
-
colorFillQuaternary:
|
|
1221
|
-
colorBgLayout:
|
|
1222
|
-
colorBgContainer:
|
|
1223
|
-
colorBgElevated:
|
|
1224
|
-
colorBgSpotlight:
|
|
1225
|
-
colorBorder:
|
|
1226
|
-
colorBorderSecondary:
|
|
1212
|
+
colorTextBase: o,
|
|
1213
|
+
colorText: ee(o, 0.88),
|
|
1214
|
+
colorTextSecondary: ee(o, 0.65),
|
|
1215
|
+
colorTextTertiary: ee(o, 0.45),
|
|
1216
|
+
colorTextQuaternary: ee(o, 0.25),
|
|
1217
|
+
colorFill: ee(o, 0.15),
|
|
1218
|
+
colorFillSecondary: ee(o, 0.06),
|
|
1219
|
+
colorFillTertiary: ee(o, 0.04),
|
|
1220
|
+
colorFillQuaternary: ee(o, 0.02),
|
|
1221
|
+
colorBgLayout: he(t, 4),
|
|
1222
|
+
colorBgContainer: he(t, 0),
|
|
1223
|
+
colorBgElevated: he(t, 0),
|
|
1224
|
+
colorBgSpotlight: ee(o, 0.85),
|
|
1225
|
+
colorBorder: he(t, 15),
|
|
1226
|
+
colorBorderSecondary: he(t, 6)
|
|
1227
1227
|
};
|
|
1228
1228
|
};
|
|
1229
|
-
function
|
|
1230
|
-
const
|
|
1231
|
-
const r =
|
|
1229
|
+
function Gn(e) {
|
|
1230
|
+
const n = new Array(10).fill(null).map((t, o) => {
|
|
1231
|
+
const r = o - 1, a = e * Math.pow(2.71828, r / 5), l = o > 1 ? Math.floor(a) : Math.ceil(a);
|
|
1232
1232
|
return Math.floor(l / 2) * 2;
|
|
1233
1233
|
});
|
|
1234
|
-
return
|
|
1235
|
-
const
|
|
1234
|
+
return n[1] = e, n.map((t) => {
|
|
1235
|
+
const o = t + 8;
|
|
1236
1236
|
return {
|
|
1237
1237
|
size: t,
|
|
1238
|
-
lineHeight:
|
|
1238
|
+
lineHeight: o / t
|
|
1239
1239
|
};
|
|
1240
1240
|
});
|
|
1241
1241
|
}
|
|
1242
|
-
const
|
|
1243
|
-
const
|
|
1242
|
+
const Wn = (e) => {
|
|
1243
|
+
const n = Gn(e), t = n.map((r) => r.size), o = n.map((r) => r.lineHeight);
|
|
1244
1244
|
return {
|
|
1245
1245
|
fontSizeSM: t[0],
|
|
1246
1246
|
fontSize: t[1],
|
|
@@ -1251,76 +1251,76 @@ const Uo = (e) => {
|
|
|
1251
1251
|
fontSizeHeading3: t[4],
|
|
1252
1252
|
fontSizeHeading4: t[3],
|
|
1253
1253
|
fontSizeHeading5: t[2],
|
|
1254
|
-
lineHeight:
|
|
1255
|
-
lineHeightLG:
|
|
1256
|
-
lineHeightSM:
|
|
1257
|
-
lineHeightHeading1:
|
|
1258
|
-
lineHeightHeading2:
|
|
1259
|
-
lineHeightHeading3:
|
|
1260
|
-
lineHeightHeading4:
|
|
1261
|
-
lineHeightHeading5:
|
|
1254
|
+
lineHeight: o[1],
|
|
1255
|
+
lineHeightLG: o[2],
|
|
1256
|
+
lineHeightSM: o[0],
|
|
1257
|
+
lineHeightHeading1: o[6],
|
|
1258
|
+
lineHeightHeading2: o[5],
|
|
1259
|
+
lineHeightHeading3: o[4],
|
|
1260
|
+
lineHeightHeading4: o[3],
|
|
1261
|
+
lineHeightHeading5: o[2]
|
|
1262
1262
|
};
|
|
1263
1263
|
};
|
|
1264
|
-
function
|
|
1265
|
-
const
|
|
1266
|
-
const
|
|
1267
|
-
return new Array(10).fill(1).reduce((r, a, l) => (r[`${t}-${l + 1}`] =
|
|
1268
|
-
}).reduce((t,
|
|
1269
|
-
return
|
|
1270
|
-
generateColorPalettes:
|
|
1271
|
-
generateNeutralColorPalettes:
|
|
1272
|
-
})),
|
|
1273
|
-
}
|
|
1274
|
-
function
|
|
1264
|
+
function qn(e) {
|
|
1265
|
+
const n = Object.keys(Dt).map((t) => {
|
|
1266
|
+
const o = Ee(e[t]);
|
|
1267
|
+
return new Array(10).fill(1).reduce((r, a, l) => (r[`${t}-${l + 1}`] = o[l], r), {});
|
|
1268
|
+
}).reduce((t, o) => (t = I(I({}, t), o), t), {});
|
|
1269
|
+
return I(I(I(I(I(I(I({}, e), n), Pn(e, {
|
|
1270
|
+
generateColorPalettes: Un,
|
|
1271
|
+
generateNeutralColorPalettes: Xn
|
|
1272
|
+
})), Wn(e.fontSize)), zn(e)), On(e)), jn(e));
|
|
1273
|
+
}
|
|
1274
|
+
function Oe(e) {
|
|
1275
1275
|
return e >= 0 && e <= 255;
|
|
1276
1276
|
}
|
|
1277
|
-
function
|
|
1277
|
+
function ke(e, n) {
|
|
1278
1278
|
const {
|
|
1279
1279
|
r: t,
|
|
1280
|
-
g:
|
|
1280
|
+
g: o,
|
|
1281
1281
|
b: r,
|
|
1282
1282
|
a
|
|
1283
|
-
} = new
|
|
1283
|
+
} = new Z(e).toRgb();
|
|
1284
1284
|
if (a < 1)
|
|
1285
1285
|
return e;
|
|
1286
1286
|
const {
|
|
1287
1287
|
r: l,
|
|
1288
|
-
g:
|
|
1289
|
-
b:
|
|
1290
|
-
} = new
|
|
1288
|
+
g: s,
|
|
1289
|
+
b: h
|
|
1290
|
+
} = new Z(n).toRgb();
|
|
1291
1291
|
for (let d = 0.01; d <= 1; d += 0.01) {
|
|
1292
|
-
const u = Math.round((t - l * (1 - d)) / d),
|
|
1293
|
-
if (
|
|
1294
|
-
return new
|
|
1292
|
+
const u = Math.round((t - l * (1 - d)) / d), m = Math.round((o - s * (1 - d)) / d), S = Math.round((r - h * (1 - d)) / d);
|
|
1293
|
+
if (Oe(u) && Oe(m) && Oe(S))
|
|
1294
|
+
return new Z({
|
|
1295
1295
|
r: u,
|
|
1296
|
-
g:
|
|
1296
|
+
g: m,
|
|
1297
1297
|
b: S,
|
|
1298
1298
|
a: Math.round(d * 100) / 100
|
|
1299
1299
|
}).toRgbString();
|
|
1300
1300
|
}
|
|
1301
|
-
return new
|
|
1301
|
+
return new Z({
|
|
1302
1302
|
r: t,
|
|
1303
|
-
g:
|
|
1303
|
+
g: o,
|
|
1304
1304
|
b: r,
|
|
1305
1305
|
a: 1
|
|
1306
1306
|
}).toRgbString();
|
|
1307
1307
|
}
|
|
1308
|
-
var
|
|
1308
|
+
var Kn = function(e, n) {
|
|
1309
1309
|
var t = {};
|
|
1310
|
-
for (var
|
|
1311
|
-
if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var r = 0,
|
|
1312
|
-
|
|
1310
|
+
for (var o in e) Object.prototype.hasOwnProperty.call(e, o) && n.indexOf(o) < 0 && (t[o] = e[o]);
|
|
1311
|
+
if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var r = 0, o = Object.getOwnPropertySymbols(e); r < o.length; r++)
|
|
1312
|
+
n.indexOf(o[r]) < 0 && Object.prototype.propertyIsEnumerable.call(e, o[r]) && (t[o[r]] = e[o[r]]);
|
|
1313
1313
|
return t;
|
|
1314
1314
|
};
|
|
1315
|
-
function
|
|
1315
|
+
function Yn(e) {
|
|
1316
1316
|
const {
|
|
1317
|
-
override:
|
|
1318
|
-
} = e, t =
|
|
1319
|
-
Object.keys(
|
|
1320
|
-
delete
|
|
1317
|
+
override: n
|
|
1318
|
+
} = e, t = Kn(e, ["override"]), o = I({}, n);
|
|
1319
|
+
Object.keys(et).forEach((x) => {
|
|
1320
|
+
delete o[x];
|
|
1321
1321
|
});
|
|
1322
|
-
const r =
|
|
1323
|
-
return
|
|
1322
|
+
const r = I(I({}, t), o), a = 480, l = 576, s = 768, h = 992, d = 1200, u = 1600, m = 2e3;
|
|
1323
|
+
return I(I(I({}, r), {
|
|
1324
1324
|
colorLink: r.colorInfoText,
|
|
1325
1325
|
colorLinkHover: r.colorInfoHover,
|
|
1326
1326
|
colorLinkActive: r.colorInfoActive,
|
|
@@ -1331,7 +1331,7 @@ function Wo(e) {
|
|
|
1331
1331
|
colorBgContainerDisabled: r.colorFillTertiary,
|
|
1332
1332
|
// ============== Split ============== //
|
|
1333
1333
|
colorBorderBg: r.colorBgContainer,
|
|
1334
|
-
colorSplit:
|
|
1334
|
+
colorSplit: ke(r.colorBorderSecondary, r.colorBgContainer),
|
|
1335
1335
|
// ============== Text ============== //
|
|
1336
1336
|
colorTextPlaceholder: r.colorTextQuaternary,
|
|
1337
1337
|
colorTextDisabled: r.colorTextQuaternary,
|
|
@@ -1344,8 +1344,8 @@ function Wo(e) {
|
|
|
1344
1344
|
colorBgTextActive: r.colorFill,
|
|
1345
1345
|
colorIcon: r.colorTextTertiary,
|
|
1346
1346
|
colorIconHover: r.colorText,
|
|
1347
|
-
colorErrorOutline:
|
|
1348
|
-
colorWarningOutline:
|
|
1347
|
+
colorErrorOutline: ke(r.colorErrorBg, r.colorBgContainer),
|
|
1348
|
+
colorWarningOutline: ke(r.colorWarningBg, r.colorBgContainer),
|
|
1349
1349
|
/** Custom colors (efko) */
|
|
1350
1350
|
colorLogo: r.colorLogo,
|
|
1351
1351
|
colorSelectedMenu: r.colorSelectedMenu,
|
|
@@ -1362,7 +1362,7 @@ function Wo(e) {
|
|
|
1362
1362
|
controlItemBgActiveHover: r.colorPrimaryBgHover,
|
|
1363
1363
|
controlItemBgActiveDisabled: r.colorFill,
|
|
1364
1364
|
controlTmpOutline: r.colorFillQuaternary,
|
|
1365
|
-
controlOutline:
|
|
1365
|
+
controlOutline: ke(r.colorPrimaryBg, r.colorBgContainer),
|
|
1366
1366
|
lineType: r.lineType,
|
|
1367
1367
|
borderRadius: r.borderRadius,
|
|
1368
1368
|
borderRadiusXS: r.borderRadiusXS,
|
|
@@ -1416,27 +1416,27 @@ function Wo(e) {
|
|
|
1416
1416
|
screenXSMax: l - 1,
|
|
1417
1417
|
screenSM: l,
|
|
1418
1418
|
screenSMMin: l,
|
|
1419
|
-
screenSMMax:
|
|
1420
|
-
screenMD:
|
|
1421
|
-
screenMDMin:
|
|
1422
|
-
screenMDMax:
|
|
1423
|
-
screenLG:
|
|
1424
|
-
screenLGMin:
|
|
1419
|
+
screenSMMax: s - 1,
|
|
1420
|
+
screenMD: s,
|
|
1421
|
+
screenMDMin: s,
|
|
1422
|
+
screenMDMax: h - 1,
|
|
1423
|
+
screenLG: h,
|
|
1424
|
+
screenLGMin: h,
|
|
1425
1425
|
screenLGMax: d - 1,
|
|
1426
1426
|
screenXL: d,
|
|
1427
1427
|
screenXLMin: d,
|
|
1428
1428
|
screenXLMax: u - 1,
|
|
1429
1429
|
screenXXL: u,
|
|
1430
1430
|
screenXXLMin: u,
|
|
1431
|
-
screenXXLMax:
|
|
1432
|
-
screenXXXL:
|
|
1433
|
-
screenXXXLMin:
|
|
1431
|
+
screenXXLMax: m - 1,
|
|
1432
|
+
screenXXXL: m,
|
|
1433
|
+
screenXXXLMin: m,
|
|
1434
1434
|
// FIXME: component box-shadow, should be removed
|
|
1435
1435
|
boxShadowPopoverArrow: "3px 3px 7px rgba(0, 0, 0, 0.1)",
|
|
1436
1436
|
boxShadowCard: `
|
|
1437
|
-
0 1px 2px -2px ${new
|
|
1438
|
-
0 3px 6px 0 ${new
|
|
1439
|
-
0 5px 12px 4px ${new
|
|
1437
|
+
0 1px 2px -2px ${new Z("rgba(0, 0, 0, 0.16)").toRgbString()},
|
|
1438
|
+
0 3px 6px 0 ${new Z("rgba(0, 0, 0, 0.12)").toRgbString()},
|
|
1439
|
+
0 5px 12px 4px ${new Z("rgba(0, 0, 0, 0.09)").toRgbString()}
|
|
1440
1440
|
`,
|
|
1441
1441
|
boxShadowDrawerRight: `
|
|
1442
1442
|
-6px 0 16px 0 rgba(0, 0, 0, 0.08),
|
|
@@ -1462,168 +1462,168 @@ function Wo(e) {
|
|
|
1462
1462
|
boxShadowTabsOverflowRight: "inset -10px 0 8px -8px rgba(0, 0, 0, 0.08)",
|
|
1463
1463
|
boxShadowTabsOverflowTop: "inset 0 10px 8px -8px rgba(0, 0, 0, 0.08)",
|
|
1464
1464
|
boxShadowTabsOverflowBottom: "inset 0 -10px 8px -8px rgba(0, 0, 0, 0.08)"
|
|
1465
|
-
}),
|
|
1465
|
+
}), o);
|
|
1466
1466
|
}
|
|
1467
|
-
const
|
|
1468
|
-
token:
|
|
1467
|
+
const Zn = dn(qn), Qn = {
|
|
1468
|
+
token: et,
|
|
1469
1469
|
hashed: !0
|
|
1470
|
-
},
|
|
1471
|
-
|
|
1472
|
-
|
|
1470
|
+
}, $t = Symbol("DesignTokenContext"), Ge = ve(), Jn = (e) => {
|
|
1471
|
+
vt($t, e), $(e, () => {
|
|
1472
|
+
Ge.value = _(e), zt(Ge);
|
|
1473
1473
|
}, {
|
|
1474
1474
|
immediate: !0,
|
|
1475
1475
|
deep: !0
|
|
1476
1476
|
});
|
|
1477
1477
|
};
|
|
1478
|
-
|
|
1478
|
+
P({
|
|
1479
1479
|
props: {
|
|
1480
|
-
value:
|
|
1480
|
+
value: wt()
|
|
1481
1481
|
},
|
|
1482
1482
|
setup(e, {
|
|
1483
|
-
slots:
|
|
1483
|
+
slots: n
|
|
1484
1484
|
}) {
|
|
1485
|
-
return
|
|
1485
|
+
return Jn(T(() => e.value)), () => {
|
|
1486
1486
|
var t;
|
|
1487
|
-
return (t =
|
|
1487
|
+
return (t = n.default) === null || t === void 0 ? void 0 : t.call(n);
|
|
1488
1488
|
};
|
|
1489
1489
|
}
|
|
1490
1490
|
});
|
|
1491
|
-
function
|
|
1492
|
-
const e =
|
|
1493
|
-
salt:
|
|
1494
|
-
override:
|
|
1491
|
+
function Ft() {
|
|
1492
|
+
const e = mt($t, T(() => Ge.value || Qn)), n = T(() => `${An}-${e.value.hashed || ""}`), t = T(() => e.value.theme || Zn), o = Sn(t, T(() => [et, e.value.token]), T(() => ({
|
|
1493
|
+
salt: n.value,
|
|
1494
|
+
override: I({
|
|
1495
1495
|
override: e.value.token
|
|
1496
1496
|
}, e.value.components),
|
|
1497
|
-
formatToken:
|
|
1497
|
+
formatToken: Yn
|
|
1498
1498
|
})));
|
|
1499
|
-
return [t,
|
|
1499
|
+
return [t, T(() => o.value[0]), T(() => e.value.hashed ? o.value[1] : "")];
|
|
1500
1500
|
}
|
|
1501
|
-
const
|
|
1501
|
+
const eo = { class: "flex flex-wrap tag-cloud" }, to = { class: "flex flex-wrap" }, no = /* @__PURE__ */ P({
|
|
1502
1502
|
__name: "FilterTagCloud",
|
|
1503
1503
|
props: {
|
|
1504
1504
|
filters: {}
|
|
1505
1505
|
},
|
|
1506
1506
|
emits: ["update:filters", "remove", "clear"],
|
|
1507
|
-
setup(e, { emit:
|
|
1508
|
-
const t = e,
|
|
1507
|
+
setup(e, { emit: n }) {
|
|
1508
|
+
const t = e, o = n, [, r] = Ft(), a = T(() => (console.log(r), {
|
|
1509
1509
|
color: r.value.colorSelectedMenu,
|
|
1510
1510
|
borderColor: r.value.colorBorderSecondary,
|
|
1511
1511
|
backgroundColor: r.value.mainBgColor || r.value.colorPrimaryBg
|
|
1512
|
-
})), l = (
|
|
1513
|
-
function f
|
|
1514
|
-
return typeof
|
|
1512
|
+
})), l = (f) => f == null ? !1 : Array.isArray(f) ? f.length > 0 : !!f, s = T(() => Object.values(t.filters).some(l));
|
|
1513
|
+
function h(f) {
|
|
1514
|
+
return typeof f == "object" && f !== null && "name" in f && typeof f.name == "string";
|
|
1515
1515
|
}
|
|
1516
|
-
const d = (
|
|
1517
|
-
if (typeof
|
|
1516
|
+
const d = (f) => {
|
|
1517
|
+
if (typeof f == "string")
|
|
1518
1518
|
return {
|
|
1519
|
-
key:
|
|
1520
|
-
label:
|
|
1521
|
-
original:
|
|
1519
|
+
key: f,
|
|
1520
|
+
label: f,
|
|
1521
|
+
original: f
|
|
1522
1522
|
};
|
|
1523
|
-
if (Array.isArray(
|
|
1524
|
-
if (
|
|
1525
|
-
const
|
|
1523
|
+
if (Array.isArray(f)) {
|
|
1524
|
+
if (f.length === 2 && typeof f[0] == "string" && typeof f[1] == "string") {
|
|
1525
|
+
const p = `${f[0]} - ${f[1]}`;
|
|
1526
1526
|
return {
|
|
1527
|
-
key:
|
|
1528
|
-
label:
|
|
1529
|
-
original:
|
|
1527
|
+
key: p,
|
|
1528
|
+
label: p,
|
|
1529
|
+
original: f
|
|
1530
1530
|
};
|
|
1531
1531
|
}
|
|
1532
|
-
const
|
|
1532
|
+
const i = f.join(", ");
|
|
1533
1533
|
return {
|
|
1534
|
-
key:
|
|
1535
|
-
label:
|
|
1536
|
-
original:
|
|
1534
|
+
key: i,
|
|
1535
|
+
label: i,
|
|
1536
|
+
original: f
|
|
1537
1537
|
};
|
|
1538
1538
|
}
|
|
1539
|
-
if (f
|
|
1540
|
-
const
|
|
1539
|
+
if (h(f)) {
|
|
1540
|
+
const i = f.name;
|
|
1541
1541
|
return {
|
|
1542
|
-
key:
|
|
1543
|
-
label:
|
|
1544
|
-
original:
|
|
1542
|
+
key: i,
|
|
1543
|
+
label: i,
|
|
1544
|
+
original: f
|
|
1545
1545
|
};
|
|
1546
1546
|
}
|
|
1547
|
-
const
|
|
1547
|
+
const k = JSON.stringify(f);
|
|
1548
1548
|
return {
|
|
1549
|
-
key:
|
|
1550
|
-
label:
|
|
1551
|
-
original:
|
|
1549
|
+
key: k,
|
|
1550
|
+
label: k,
|
|
1551
|
+
original: f
|
|
1552
1552
|
};
|
|
1553
|
-
}, u = (
|
|
1554
|
-
d(
|
|
1555
|
-
],
|
|
1556
|
-
if (Array.isArray(
|
|
1557
|
-
const
|
|
1558
|
-
(b) => !
|
|
1553
|
+
}, u = (f) => f == null ? [] : Array.isArray(f) ? f.map((k) => d(k)) : [
|
|
1554
|
+
d(f)
|
|
1555
|
+
], m = (f, k) => typeof f == "string" || typeof k == "string" ? f === k : JSON.stringify(f) === JSON.stringify(k), S = (f, k, i) => {
|
|
1556
|
+
if (Array.isArray(k)) {
|
|
1557
|
+
const p = k.filter(
|
|
1558
|
+
(b) => !m(b, i)
|
|
1559
1559
|
);
|
|
1560
|
-
|
|
1560
|
+
o("update:filters", {
|
|
1561
1561
|
...t.filters,
|
|
1562
|
-
[
|
|
1562
|
+
[f]: p
|
|
1563
1563
|
});
|
|
1564
1564
|
} else
|
|
1565
|
-
|
|
1565
|
+
o("update:filters", {
|
|
1566
1566
|
...t.filters,
|
|
1567
|
-
[
|
|
1567
|
+
[f]: null
|
|
1568
1568
|
});
|
|
1569
|
-
|
|
1569
|
+
o("remove", f, k, i);
|
|
1570
1570
|
}, x = () => {
|
|
1571
|
-
|
|
1571
|
+
o("update:filters", {}), o("clear");
|
|
1572
1572
|
};
|
|
1573
|
-
return (
|
|
1574
|
-
const
|
|
1575
|
-
return
|
|
1576
|
-
|
|
1577
|
-
(
|
|
1578
|
-
(
|
|
1579
|
-
key:
|
|
1573
|
+
return (f, k) => {
|
|
1574
|
+
const i = H("a-tag"), p = H("a-button");
|
|
1575
|
+
return v(), C("div", eo, [
|
|
1576
|
+
R("div", to, [
|
|
1577
|
+
(v(!0), C(O, null, W(Object.entries(e.filters), ([b, g]) => (v(), C(O, { key: b }, [
|
|
1578
|
+
(v(!0), C(O, null, W(u(g), (A) => (v(), B(i, {
|
|
1579
|
+
key: A.key,
|
|
1580
1580
|
class: "filter-tag",
|
|
1581
1581
|
closable: !0,
|
|
1582
|
-
style:
|
|
1583
|
-
onClose: () => S(b,
|
|
1582
|
+
style: ze(a.value),
|
|
1583
|
+
onClose: () => S(b, g, A.original)
|
|
1584
1584
|
}, {
|
|
1585
|
-
default:
|
|
1586
|
-
|
|
1585
|
+
default: w(() => [
|
|
1586
|
+
N(X(A.label), 1)
|
|
1587
1587
|
]),
|
|
1588
1588
|
_: 2
|
|
1589
1589
|
}, 1032, ["style", "onClose"]))), 128))
|
|
1590
1590
|
], 64))), 128))
|
|
1591
1591
|
]),
|
|
1592
|
-
|
|
1592
|
+
s.value ? (v(), B(p, {
|
|
1593
1593
|
key: 0,
|
|
1594
1594
|
type: "link",
|
|
1595
1595
|
onClick: x
|
|
1596
1596
|
}, {
|
|
1597
|
-
default:
|
|
1598
|
-
|
|
1597
|
+
default: w(() => [...k[0] || (k[0] = [
|
|
1598
|
+
N(" Очистить все ", -1)
|
|
1599
1599
|
])]),
|
|
1600
1600
|
_: 1
|
|
1601
|
-
})) :
|
|
1601
|
+
})) : U("", !0)
|
|
1602
1602
|
]);
|
|
1603
1603
|
};
|
|
1604
1604
|
}
|
|
1605
|
-
}), ce = (e,
|
|
1605
|
+
}), ce = (e, n) => {
|
|
1606
1606
|
const t = e.__vccOpts || e;
|
|
1607
|
-
for (const [
|
|
1608
|
-
t[
|
|
1607
|
+
for (const [o, r] of n)
|
|
1608
|
+
t[o] = r;
|
|
1609
1609
|
return t;
|
|
1610
|
-
},
|
|
1610
|
+
}, oo = /* @__PURE__ */ ce(no, [["__scopeId", "data-v-a32f7554"]]), ro = { class: "flex items-center justify-center text-lg" }, Te = /* @__PURE__ */ P({
|
|
1611
1611
|
__name: "TableCellStatus",
|
|
1612
1612
|
props: {
|
|
1613
1613
|
value: {}
|
|
1614
1614
|
},
|
|
1615
1615
|
setup(e) {
|
|
1616
|
-
return (
|
|
1617
|
-
e.value ? (
|
|
1616
|
+
return (n, t) => (v(), C("div", ro, [
|
|
1617
|
+
e.value ? (v(), B(_(nt), {
|
|
1618
1618
|
key: 1,
|
|
1619
1619
|
"two-tone-color": "#bfbfbf"
|
|
1620
|
-
})) : (
|
|
1620
|
+
})) : (v(), B(_(nt), {
|
|
1621
1621
|
key: 0,
|
|
1622
1622
|
"two-tone-color": "#4ade80"
|
|
1623
1623
|
}))
|
|
1624
1624
|
]));
|
|
1625
1625
|
}
|
|
1626
|
-
}),
|
|
1626
|
+
}), ao = { class: "flex items-center justify-center gap-2" }, io = /* @__PURE__ */ P({
|
|
1627
1627
|
__name: "CardCellActions",
|
|
1628
1628
|
props: {
|
|
1629
1629
|
record: {},
|
|
@@ -1631,55 +1631,55 @@ const Qo = { class: "flex flex-wrap tag-cloud" }, Jo = { class: "flex flex-wrap"
|
|
|
1631
1631
|
editAction: { type: Boolean }
|
|
1632
1632
|
},
|
|
1633
1633
|
emits: ["edit", "delete", "restore"],
|
|
1634
|
-
setup(e, { emit:
|
|
1635
|
-
const t = e,
|
|
1634
|
+
setup(e, { emit: n }) {
|
|
1635
|
+
const t = e, o = n, r = t.canEdit ?? !0, a = t.editAction ?? !0, l = (d) => o("delete", d), s = (d) => o("restore", d), h = (d) => o("edit", d);
|
|
1636
1636
|
return (d, u) => {
|
|
1637
|
-
const
|
|
1638
|
-
return
|
|
1639
|
-
|
|
1637
|
+
const m = H("a-button"), S = H("a-tooltip");
|
|
1638
|
+
return v(), C("div", ao, [
|
|
1639
|
+
_(r) === !1 ? (v(), B(S, {
|
|
1640
1640
|
key: 0,
|
|
1641
1641
|
title: "Смотреть"
|
|
1642
1642
|
}, {
|
|
1643
|
-
default:
|
|
1644
|
-
M(
|
|
1645
|
-
icon: ie(
|
|
1646
|
-
onClick: u[0] || (u[0] = (x) =>
|
|
1643
|
+
default: w(() => [
|
|
1644
|
+
M(m, {
|
|
1645
|
+
icon: ie(_(bt)),
|
|
1646
|
+
onClick: u[0] || (u[0] = (x) => h(e.record))
|
|
1647
1647
|
}, null, 8, ["icon"])
|
|
1648
1648
|
]),
|
|
1649
1649
|
_: 1
|
|
1650
|
-
})) :
|
|
1651
|
-
|
|
1652
|
-
|
|
1650
|
+
})) : U("", !0),
|
|
1651
|
+
_(r) !== !1 ? (v(), C(O, { key: 1 }, [
|
|
1652
|
+
_(a) !== !1 ? (v(), B(S, {
|
|
1653
1653
|
key: 0,
|
|
1654
1654
|
title: "Редактировать"
|
|
1655
1655
|
}, {
|
|
1656
|
-
default:
|
|
1657
|
-
M(
|
|
1658
|
-
icon: ie(
|
|
1659
|
-
onClick: u[1] || (u[1] = (x) =>
|
|
1656
|
+
default: w(() => [
|
|
1657
|
+
M(m, {
|
|
1658
|
+
icon: ie(_(xt)),
|
|
1659
|
+
onClick: u[1] || (u[1] = (x) => h(e.record))
|
|
1660
1660
|
}, null, 8, ["icon"])
|
|
1661
1661
|
]),
|
|
1662
1662
|
_: 1
|
|
1663
|
-
})) :
|
|
1663
|
+
})) : U("", !0),
|
|
1664
1664
|
M(S, {
|
|
1665
1665
|
title: e.record.deletedAt ? "Восстановить" : "Удалить"
|
|
1666
1666
|
}, {
|
|
1667
|
-
default:
|
|
1668
|
-
M(
|
|
1669
|
-
icon: ie(e.record.deletedAt ?
|
|
1670
|
-
onClick: u[2] || (u[2] = (x) => e.record.deletedAt ?
|
|
1667
|
+
default: w(() => [
|
|
1668
|
+
M(m, {
|
|
1669
|
+
icon: ie(e.record.deletedAt ? _(St) : _(At)),
|
|
1670
|
+
onClick: u[2] || (u[2] = (x) => e.record.deletedAt ? s(e.record) : l(e.record))
|
|
1671
1671
|
}, null, 8, ["icon"])
|
|
1672
1672
|
]),
|
|
1673
1673
|
_: 1
|
|
1674
1674
|
}, 8, ["title"])
|
|
1675
|
-
], 64)) :
|
|
1675
|
+
], 64)) : U("", !0)
|
|
1676
1676
|
]);
|
|
1677
1677
|
};
|
|
1678
1678
|
}
|
|
1679
|
-
}),
|
|
1679
|
+
}), lo = { class: "data-card__header" }, so = { class: "data-card__body" }, co = { class: "data-card__label" }, uo = { class: "data-card__value" }, fo = { key: 0 }, po = { key: 2 }, go = { key: 3 }, ho = { key: 4 }, mo = { key: 5 }, vo = {
|
|
1680
1680
|
key: 0,
|
|
1681
1681
|
class: "data-card__footer"
|
|
1682
|
-
},
|
|
1682
|
+
}, yo = /* @__PURE__ */ P({
|
|
1683
1683
|
__name: "TheCard",
|
|
1684
1684
|
props: {
|
|
1685
1685
|
loading: { type: Boolean },
|
|
@@ -1690,100 +1690,100 @@ const Qo = { class: "flex flex-wrap tag-cloud" }, Jo = { class: "flex flex-wrap"
|
|
|
1690
1690
|
showActionsColumn: { type: Boolean }
|
|
1691
1691
|
},
|
|
1692
1692
|
emits: ["delete", "restore", "edit"],
|
|
1693
|
-
setup(e, { emit:
|
|
1694
|
-
const t = e,
|
|
1695
|
-
if (
|
|
1693
|
+
setup(e, { emit: n }) {
|
|
1694
|
+
const t = e, o = (i) => t.record[String(i.dataIndex)], r = (i) => {
|
|
1695
|
+
if (i === null || typeof i != "object")
|
|
1696
1696
|
return "";
|
|
1697
|
-
if ("name" in
|
|
1698
|
-
const
|
|
1699
|
-
return typeof
|
|
1697
|
+
if ("name" in i) {
|
|
1698
|
+
const p = i.name;
|
|
1699
|
+
return typeof p == "string" ? p : "";
|
|
1700
1700
|
}
|
|
1701
1701
|
return "";
|
|
1702
|
-
}, a = (
|
|
1703
|
-
const
|
|
1704
|
-
return Array.isArray(
|
|
1705
|
-
},
|
|
1706
|
-
key: `${
|
|
1707
|
-
label:
|
|
1708
|
-
})), d =
|
|
1709
|
-
return (
|
|
1710
|
-
const b = H("a-tag"),
|
|
1711
|
-
return
|
|
1702
|
+
}, a = (i) => i == null ? !0 : typeof i == "string" ? i.trim().length === 0 : !1, l = (i) => i == null ? "" : typeof i == "string" ? i.trim() : typeof i == "object" ? r(i) : String(i), s = (i) => {
|
|
1703
|
+
const p = o(i);
|
|
1704
|
+
return Array.isArray(p) ? p.map((b) => l(b)).filter((b) => b.trim().length > 0) : [];
|
|
1705
|
+
}, h = (i) => s(i).map((p, b) => ({
|
|
1706
|
+
key: `${p}-${b}`,
|
|
1707
|
+
label: p
|
|
1708
|
+
})), d = n, u = t.canEdit ?? !0, m = t.editAction ?? !0, S = t.showActionsColumn ?? !0, x = (i) => d("delete", i), f = (i) => d("restore", i), k = (i) => d("edit", i);
|
|
1709
|
+
return (i, p) => {
|
|
1710
|
+
const b = H("a-tag"), g = H("a-card");
|
|
1711
|
+
return v(), B(g, {
|
|
1712
1712
|
loading: e.loading,
|
|
1713
1713
|
bordered: !1,
|
|
1714
1714
|
class: "data-card bg-white rounded-3 shadow-sm"
|
|
1715
|
-
},
|
|
1716
|
-
title:
|
|
1717
|
-
|
|
1718
|
-
|
|
1715
|
+
}, Ie({
|
|
1716
|
+
title: w(() => [
|
|
1717
|
+
R("div", lo, [
|
|
1718
|
+
z(i.$slots, "title", {}, void 0, !0)
|
|
1719
1719
|
])
|
|
1720
1720
|
]),
|
|
1721
|
-
default:
|
|
1722
|
-
|
|
1723
|
-
|
|
1721
|
+
default: w(() => [
|
|
1722
|
+
R("div", so, [
|
|
1723
|
+
z(i.$slots, "body", {
|
|
1724
1724
|
record: e.record,
|
|
1725
1725
|
columns: e.columns
|
|
1726
1726
|
}, () => [
|
|
1727
|
-
(
|
|
1728
|
-
key:
|
|
1727
|
+
(v(!0), C(O, null, W(e.columns, (A) => (v(), C("div", {
|
|
1728
|
+
key: A.dataIndex,
|
|
1729
1729
|
class: "data-card__row"
|
|
1730
1730
|
}, [
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
M(
|
|
1731
|
+
R("span", co, X(A.title) + ": ", 1),
|
|
1732
|
+
R("span", uo, [
|
|
1733
|
+
A.dataIndex === "deletedAt" ? (v(), C("span", fo, [
|
|
1734
|
+
M(Te, {
|
|
1735
1735
|
value: e.record.deletedAt
|
|
1736
1736
|
}, null, 8, ["value"])
|
|
1737
|
-
])) : Array.isArray(
|
|
1738
|
-
|
|
1739
|
-
key:
|
|
1737
|
+
])) : Array.isArray(o(A)) ? (v(), C(O, { key: 1 }, [
|
|
1738
|
+
A.tag === !0 ? (v(!0), C(O, { key: 0 }, W(h(A), (V) => (v(), B(b, {
|
|
1739
|
+
key: V.key,
|
|
1740
1740
|
class: "mr-1 mb-1"
|
|
1741
1741
|
}, {
|
|
1742
|
-
default:
|
|
1743
|
-
|
|
1742
|
+
default: w(() => [
|
|
1743
|
+
N(X(V.label), 1)
|
|
1744
1744
|
]),
|
|
1745
1745
|
_: 2
|
|
1746
|
-
}, 1024))), 128)) : (
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
], 64)) :
|
|
1746
|
+
}, 1024))), 128)) : (v(!0), C(O, { key: 1 }, W(s(A), (V, y) => (v(), C("span", { key: y }, [
|
|
1747
|
+
N(X(V) + " ", 1),
|
|
1748
|
+
y < s(A).length - 1 ? (v(), C(O, { key: 0 }, [
|
|
1749
|
+
N(" , ")
|
|
1750
|
+
], 64)) : U("", !0)
|
|
1751
1751
|
]))), 128))
|
|
1752
|
-
], 64)) : typeof
|
|
1753
|
-
M(
|
|
1754
|
-
value: !
|
|
1752
|
+
], 64)) : typeof o(A) == "boolean" ? (v(), C("span", po, [
|
|
1753
|
+
M(Te, {
|
|
1754
|
+
value: !o(A)
|
|
1755
1755
|
}, null, 8, ["value"])
|
|
1756
|
-
])) :
|
|
1757
|
-
a(
|
|
1758
|
-
default:
|
|
1759
|
-
|
|
1756
|
+
])) : o(A) !== null && typeof o(A) == "object" ? (v(), C("span", go, X(r(o(A))), 1)) : A.tag === !0 ? (v(), C("span", ho, [
|
|
1757
|
+
a(o(A)) ? U("", !0) : (v(), B(b, { key: 0 }, {
|
|
1758
|
+
default: w(() => [
|
|
1759
|
+
N(X(o(A)), 1)
|
|
1760
1760
|
]),
|
|
1761
1761
|
_: 2
|
|
1762
1762
|
}, 1024))
|
|
1763
|
-
])) : (
|
|
1763
|
+
])) : (v(), C("span", mo, X(o(A)), 1))
|
|
1764
1764
|
])
|
|
1765
1765
|
]))), 128))
|
|
1766
1766
|
], !0)
|
|
1767
1767
|
]),
|
|
1768
|
-
|
|
1769
|
-
|
|
1768
|
+
i.$slots.footer ? (v(), C("div", vo, [
|
|
1769
|
+
z(i.$slots, "footer", {
|
|
1770
1770
|
record: e.record,
|
|
1771
1771
|
columns: e.columns
|
|
1772
1772
|
}, void 0, !0)
|
|
1773
|
-
])) :
|
|
1773
|
+
])) : U("", !0)
|
|
1774
1774
|
]),
|
|
1775
1775
|
_: 2
|
|
1776
1776
|
}, [
|
|
1777
|
-
|
|
1777
|
+
_(S) ? {
|
|
1778
1778
|
name: "actions",
|
|
1779
|
-
fn:
|
|
1780
|
-
M(
|
|
1779
|
+
fn: w(() => [
|
|
1780
|
+
M(io, {
|
|
1781
1781
|
record: e.record,
|
|
1782
|
-
"can-edit":
|
|
1783
|
-
"edit-action":
|
|
1784
|
-
onEdit:
|
|
1782
|
+
"can-edit": _(u),
|
|
1783
|
+
"edit-action": _(m),
|
|
1784
|
+
onEdit: k,
|
|
1785
1785
|
onDelete: x,
|
|
1786
|
-
onRestore:
|
|
1786
|
+
onRestore: f
|
|
1787
1787
|
}, null, 8, ["record", "can-edit", "edit-action"])
|
|
1788
1788
|
]),
|
|
1789
1789
|
key: "0"
|
|
@@ -1791,7 +1791,7 @@ const Qo = { class: "flex flex-wrap tag-cloud" }, Jo = { class: "flex flex-wrap"
|
|
|
1791
1791
|
]), 1032, ["loading"]);
|
|
1792
1792
|
};
|
|
1793
1793
|
}
|
|
1794
|
-
}),
|
|
1794
|
+
}), bo = /* @__PURE__ */ ce(yo, [["__scopeId", "data-v-c6be2770"]]), xo = { class: "efko-dataview" }, So = /* @__PURE__ */ P({
|
|
1795
1795
|
__name: "LazyLoadTrigger",
|
|
1796
1796
|
props: {
|
|
1797
1797
|
onIntersect: {},
|
|
@@ -1800,33 +1800,33 @@ const Qo = { class: "flex flex-wrap tag-cloud" }, Jo = { class: "flex flex-wrap"
|
|
|
1800
1800
|
loading: { type: Boolean }
|
|
1801
1801
|
},
|
|
1802
1802
|
setup(e) {
|
|
1803
|
-
const
|
|
1804
|
-
let
|
|
1803
|
+
const n = e, t = L(null);
|
|
1804
|
+
let o = null;
|
|
1805
1805
|
const r = (a) => {
|
|
1806
|
-
var
|
|
1807
|
-
a[0].isIntersecting && ((
|
|
1806
|
+
var s;
|
|
1807
|
+
a[0].isIntersecting && ((s = n.onIntersect) == null || s.call(n), n.once && o && o.disconnect());
|
|
1808
1808
|
};
|
|
1809
1809
|
return le(() => {
|
|
1810
|
-
|
|
1811
|
-
threshold:
|
|
1812
|
-
}), t.value &&
|
|
1813
|
-
}),
|
|
1814
|
-
|
|
1810
|
+
o = new IntersectionObserver(r, {
|
|
1811
|
+
threshold: n.threshold
|
|
1812
|
+
}), t.value && o.observe(t.value);
|
|
1813
|
+
}), Ke(() => {
|
|
1814
|
+
o && o.disconnect();
|
|
1815
1815
|
}), (a, l) => {
|
|
1816
|
-
const
|
|
1817
|
-
return
|
|
1818
|
-
|
|
1816
|
+
const s = H("a-spin");
|
|
1817
|
+
return v(), C("div", xo, [
|
|
1818
|
+
R("div", {
|
|
1819
1819
|
ref_key: "container",
|
|
1820
1820
|
ref: t,
|
|
1821
1821
|
style: { height: "1px" },
|
|
1822
1822
|
class: "flex items-center justify-center py-5"
|
|
1823
1823
|
}, [
|
|
1824
|
-
M(
|
|
1824
|
+
M(s, { spinning: e.loading }, null, 8, ["spinning"])
|
|
1825
1825
|
], 512)
|
|
1826
1826
|
]);
|
|
1827
1827
|
};
|
|
1828
1828
|
}
|
|
1829
|
-
}),
|
|
1829
|
+
}), Ao = { class: "efko-dataview" }, Co = { class: "flex flex-col gap-4" }, wo = /* @__PURE__ */ P({
|
|
1830
1830
|
__name: "CardGrid",
|
|
1831
1831
|
props: {
|
|
1832
1832
|
loading: { type: Boolean },
|
|
@@ -1840,15 +1840,15 @@ const Qo = { class: "flex flex-wrap tag-cloud" }, Jo = { class: "flex flex-wrap"
|
|
|
1840
1840
|
meta: {}
|
|
1841
1841
|
},
|
|
1842
1842
|
emits: ["delete", "restore", "edit", "pageChange", "sizeChange"],
|
|
1843
|
-
setup(e, { emit:
|
|
1844
|
-
const t = e,
|
|
1843
|
+
setup(e, { emit: n }) {
|
|
1844
|
+
const t = e, o = n;
|
|
1845
1845
|
le(() => {
|
|
1846
1846
|
const u = document.querySelector(".card-grid");
|
|
1847
|
-
u !== null &&
|
|
1847
|
+
u !== null && Qe(u);
|
|
1848
1848
|
});
|
|
1849
|
-
const r =
|
|
1849
|
+
const r = T(
|
|
1850
1850
|
() => t.cardLayout === "row" ? "card-grid card-grid--row" : "card-grid card-grid--grid"
|
|
1851
|
-
), a =
|
|
1851
|
+
), a = T(() => t.columns), l = L([]), s = () => {
|
|
1852
1852
|
var S;
|
|
1853
1853
|
if (((S = t.meta) == null ? void 0 : S.currentPage) === 1) {
|
|
1854
1854
|
l.value = [
|
|
@@ -1856,27 +1856,27 @@ const Qo = { class: "flex flex-wrap tag-cloud" }, Jo = { class: "flex flex-wrap"
|
|
|
1856
1856
|
];
|
|
1857
1857
|
return;
|
|
1858
1858
|
}
|
|
1859
|
-
const u = new Set(l.value.map((x) => x.id)),
|
|
1860
|
-
l.value.push(...
|
|
1859
|
+
const u = new Set(l.value.map((x) => x.id)), m = t.dataSource.filter((x) => !u.has(x.id));
|
|
1860
|
+
l.value.push(...m);
|
|
1861
1861
|
};
|
|
1862
|
-
|
|
1862
|
+
s(), $(() => {
|
|
1863
1863
|
var u;
|
|
1864
1864
|
return [
|
|
1865
1865
|
t.dataSource,
|
|
1866
1866
|
(u = t.meta) == null ? void 0 : u.currentPage
|
|
1867
1867
|
];
|
|
1868
|
-
},
|
|
1868
|
+
}, s, {
|
|
1869
1869
|
deep: !0
|
|
1870
1870
|
});
|
|
1871
|
-
const
|
|
1872
|
-
t.loading ||
|
|
1871
|
+
const h = T(() => t.meta === void 0 ? !0 : t.meta.currentPage * t.meta.pageSize >= t.meta.total), d = () => {
|
|
1872
|
+
t.loading || h.value || !t.meta || o("pageChange", t.meta.currentPage + 1);
|
|
1873
1873
|
};
|
|
1874
|
-
return (u,
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
class:
|
|
1874
|
+
return (u, m) => (v(), C("div", Ao, [
|
|
1875
|
+
R("div", Co, [
|
|
1876
|
+
R("div", {
|
|
1877
|
+
class: Pt(r.value)
|
|
1878
1878
|
}, [
|
|
1879
|
-
(
|
|
1879
|
+
(v(!0), C(O, null, W(l.value, (S, x) => (v(), B(bo, {
|
|
1880
1880
|
key: String(S.id ?? `card-${x}`),
|
|
1881
1881
|
loading: e.loading,
|
|
1882
1882
|
record: S,
|
|
@@ -1884,14 +1884,14 @@ const Qo = { class: "flex flex-wrap tag-cloud" }, Jo = { class: "flex flex-wrap"
|
|
|
1884
1884
|
"can-edit": e.canEdit,
|
|
1885
1885
|
"edit-action": e.editAction,
|
|
1886
1886
|
"show-actions-column": e.showActionsColumn,
|
|
1887
|
-
onEdit:
|
|
1888
|
-
onDelete:
|
|
1889
|
-
onRestore:
|
|
1890
|
-
},
|
|
1887
|
+
onEdit: m[0] || (m[0] = (f) => o("edit", f)),
|
|
1888
|
+
onDelete: m[1] || (m[1] = (f) => o("delete", f)),
|
|
1889
|
+
onRestore: m[2] || (m[2] = (f) => o("restore", f))
|
|
1890
|
+
}, Ie({ _: 2 }, [
|
|
1891
1891
|
u.$slots.titleCard ? {
|
|
1892
1892
|
name: "title",
|
|
1893
|
-
fn:
|
|
1894
|
-
|
|
1893
|
+
fn: w(() => [
|
|
1894
|
+
z(u.$slots, "titleCard", {
|
|
1895
1895
|
record: S,
|
|
1896
1896
|
columns: a.value
|
|
1897
1897
|
}, void 0, !0)
|
|
@@ -1900,48 +1900,48 @@ const Qo = { class: "flex flex-wrap tag-cloud" }, Jo = { class: "flex flex-wrap"
|
|
|
1900
1900
|
} : void 0,
|
|
1901
1901
|
u.$slots.bodyCard ? {
|
|
1902
1902
|
name: "body",
|
|
1903
|
-
fn:
|
|
1904
|
-
|
|
1905
|
-
record:
|
|
1906
|
-
columns:
|
|
1903
|
+
fn: w(({ record: f, columns: k }) => [
|
|
1904
|
+
z(u.$slots, "bodyCard", {
|
|
1905
|
+
record: f,
|
|
1906
|
+
columns: k
|
|
1907
1907
|
}, void 0, !0)
|
|
1908
1908
|
]),
|
|
1909
1909
|
key: "1"
|
|
1910
1910
|
} : void 0,
|
|
1911
1911
|
u.$slots.footerCard ? {
|
|
1912
1912
|
name: "footer",
|
|
1913
|
-
fn:
|
|
1914
|
-
|
|
1915
|
-
record:
|
|
1916
|
-
columns:
|
|
1913
|
+
fn: w(({ record: f, columns: k }) => [
|
|
1914
|
+
z(u.$slots, "footerCard", {
|
|
1915
|
+
record: f,
|
|
1916
|
+
columns: k
|
|
1917
1917
|
}, void 0, !0)
|
|
1918
1918
|
]),
|
|
1919
1919
|
key: "2"
|
|
1920
1920
|
} : void 0
|
|
1921
1921
|
]), 1032, ["loading", "record", "columns", "can-edit", "edit-action", "show-actions-column"]))), 128))
|
|
1922
1922
|
], 2),
|
|
1923
|
-
e.pagination && !
|
|
1923
|
+
e.pagination && !h.value ? (v(), B(So, {
|
|
1924
1924
|
key: 0,
|
|
1925
1925
|
loading: e.loading,
|
|
1926
1926
|
once: !1,
|
|
1927
1927
|
"on-intersect": d
|
|
1928
|
-
}, null, 8, ["loading"])) :
|
|
1928
|
+
}, null, 8, ["loading"])) : U("", !0)
|
|
1929
1929
|
])
|
|
1930
1930
|
]));
|
|
1931
1931
|
}
|
|
1932
|
-
}),
|
|
1933
|
-
var
|
|
1934
|
-
const
|
|
1932
|
+
}), ko = /* @__PURE__ */ ce(wo, [["__scopeId", "data-v-e3e3f0a2"]]), Mo = "10", gr = "20", hr = "50", mr = "100", vr = "1000", yr = 1, br = Mo;
|
|
1933
|
+
var q = /* @__PURE__ */ ((e) => (e.SEARCH = "search", e.SELECT = "select", e.DATE = "date", e))(q || {}), Eo = /* @__PURE__ */ ((e) => (e.SMALL = "10", e.MEDIUM = "20", e.LARGE = "50", e.EXTRA_LARGE = "100", e.ULTRA = "1000", e))(Eo || {});
|
|
1934
|
+
const xr = [
|
|
1935
1935
|
"10",
|
|
1936
1936
|
"20",
|
|
1937
1937
|
"50",
|
|
1938
1938
|
"100"
|
|
1939
1939
|
/* EXTRA_LARGE */
|
|
1940
1940
|
];
|
|
1941
|
-
var
|
|
1942
|
-
const
|
|
1941
|
+
var To = /* @__PURE__ */ ((e) => (e[e.NONE = 0] = "NONE", e[e.SMALL = 10] = "SMALL", e[e.MEDIUM = 20] = "MEDIUM", e[e.LARGE = 50] = "LARGE", e))(To || {}), Io = /* @__PURE__ */ ((e) => (e[e.DEFAULT_CURRENT_PAGE = 1] = "DEFAULT_CURRENT_PAGE", e))(Io || {}), We = /* @__PURE__ */ ((e) => (e.ASCEND = "ascend", e.DESCEND = "descend", e))(We || {}), Ho = /* @__PURE__ */ ((e) => (e.ASC = "asc", e.DESC = "desc", e))(Ho || {});
|
|
1942
|
+
const Bo = P({
|
|
1943
1943
|
name: "MultiselectWrapper",
|
|
1944
|
-
components: { VueMultiselect:
|
|
1944
|
+
components: { VueMultiselect: Ut },
|
|
1945
1945
|
props: {
|
|
1946
1946
|
modelValue: {
|
|
1947
1947
|
type: [Array, String, Number, Object, Boolean, null],
|
|
@@ -1950,25 +1950,25 @@ const Tn = z({
|
|
|
1950
1950
|
},
|
|
1951
1951
|
emits: ["update:modelValue"],
|
|
1952
1952
|
data() {
|
|
1953
|
-
return { simpleImage:
|
|
1953
|
+
return { simpleImage: Xt.PRESENTED_IMAGE_SIMPLE };
|
|
1954
1954
|
}
|
|
1955
1955
|
});
|
|
1956
|
-
function
|
|
1957
|
-
const l = H("a-empty"),
|
|
1958
|
-
return
|
|
1956
|
+
function Do(e, n, t, o, r, a) {
|
|
1957
|
+
const l = H("a-empty"), s = H("VueMultiselect");
|
|
1958
|
+
return v(), B(s, Ye(e.$attrs, {
|
|
1959
1959
|
class: "filter-select",
|
|
1960
1960
|
modelValue: e.modelValue,
|
|
1961
|
-
"onUpdate:modelValue":
|
|
1961
|
+
"onUpdate:modelValue": n[0] || (n[0] = (h) => e.$emit("update:modelValue", h)),
|
|
1962
1962
|
label: "name",
|
|
1963
1963
|
"value-prop": "id"
|
|
1964
1964
|
}), {
|
|
1965
|
-
nooptions:
|
|
1965
|
+
nooptions: w(() => [
|
|
1966
1966
|
M(l, { image: e.simpleImage }, null, 8, ["image"])
|
|
1967
1967
|
]),
|
|
1968
1968
|
_: 1
|
|
1969
1969
|
}, 16, ["modelValue"]);
|
|
1970
1970
|
}
|
|
1971
|
-
const
|
|
1971
|
+
const Vt = /* @__PURE__ */ ce(Bo, [["render", Do], ["__scopeId", "data-v-cfb3f123"]]), $o = { class: "efko-dataview" }, Fo = { class: "flex items-center gap-2 p-2" }, Vo = /* @__PURE__ */ P({
|
|
1972
1972
|
__name: "FilterDropdown",
|
|
1973
1973
|
props: {
|
|
1974
1974
|
placeholder: {},
|
|
@@ -1976,19 +1976,19 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
1976
1976
|
componentProps: {}
|
|
1977
1977
|
},
|
|
1978
1978
|
emits: ["update:modelValue", "apply"],
|
|
1979
|
-
setup(e, { emit:
|
|
1980
|
-
const t = e,
|
|
1981
|
-
|
|
1979
|
+
setup(e, { emit: n }) {
|
|
1980
|
+
const t = e, o = n, r = T(() => t.filterMode === q.SEARCH ? "a-input" : t.filterMode === q.SELECT ? Vt : t.filterMode === q.DATE ? "a-range-picker" : null), a = L(null), l = () => {
|
|
1981
|
+
o("update:modelValue", a.value), o("apply"), a.value = null;
|
|
1982
1982
|
};
|
|
1983
|
-
return (
|
|
1983
|
+
return (s, h) => {
|
|
1984
1984
|
const d = H("a-button");
|
|
1985
|
-
return
|
|
1986
|
-
|
|
1987
|
-
(
|
|
1985
|
+
return v(), C("div", $o, [
|
|
1986
|
+
R("div", Fo, [
|
|
1987
|
+
(v(), B(yt(r.value), Ye(e.componentProps, {
|
|
1988
1988
|
value: a.value,
|
|
1989
|
-
"onUpdate:value":
|
|
1989
|
+
"onUpdate:value": h[0] || (h[0] = (u) => a.value = u),
|
|
1990
1990
|
modelValue: a.value,
|
|
1991
|
-
"onUpdate:modelValue":
|
|
1991
|
+
"onUpdate:modelValue": h[1] || (h[1] = (u) => a.value = u),
|
|
1992
1992
|
placeholder: e.placeholder,
|
|
1993
1993
|
style: { "min-width": "240px", "max-width": "300px", "font-size": "14px" },
|
|
1994
1994
|
object: ""
|
|
@@ -1998,8 +1998,8 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
1998
1998
|
size: "small",
|
|
1999
1999
|
onClick: l
|
|
2000
2000
|
}, {
|
|
2001
|
-
default:
|
|
2002
|
-
|
|
2001
|
+
default: w(() => [...h[2] || (h[2] = [
|
|
2002
|
+
N(" Добавить ", -1)
|
|
2003
2003
|
])]),
|
|
2004
2004
|
_: 1
|
|
2005
2005
|
})
|
|
@@ -2007,7 +2007,7 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2007
2007
|
]);
|
|
2008
2008
|
};
|
|
2009
2009
|
}
|
|
2010
|
-
}),
|
|
2010
|
+
}), _o = { class: "flex items-center justify-center gap-2" }, Ro = /* @__PURE__ */ P({
|
|
2011
2011
|
__name: "TableCellActions",
|
|
2012
2012
|
props: {
|
|
2013
2013
|
record: {},
|
|
@@ -2016,59 +2016,59 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2016
2016
|
deleteAction: { type: Boolean }
|
|
2017
2017
|
},
|
|
2018
2018
|
emits: ["edit", "delete", "restore"],
|
|
2019
|
-
setup(e, { emit:
|
|
2020
|
-
const t = e,
|
|
2021
|
-
|
|
2022
|
-
}, a = (
|
|
2023
|
-
|
|
2024
|
-
}, l = (
|
|
2025
|
-
|
|
2019
|
+
setup(e, { emit: n }) {
|
|
2020
|
+
const t = e, o = n, r = (s) => {
|
|
2021
|
+
o("delete", s);
|
|
2022
|
+
}, a = (s) => {
|
|
2023
|
+
o("restore", s);
|
|
2024
|
+
}, l = (s) => {
|
|
2025
|
+
o("edit", s);
|
|
2026
2026
|
};
|
|
2027
|
-
return (
|
|
2027
|
+
return (s, h) => {
|
|
2028
2028
|
const d = H("a-button"), u = H("a-tooltip");
|
|
2029
|
-
return
|
|
2030
|
-
t.canEdit === !1 ? (
|
|
2029
|
+
return v(), C("div", _o, [
|
|
2030
|
+
t.canEdit === !1 ? (v(), B(u, {
|
|
2031
2031
|
key: 0,
|
|
2032
2032
|
title: "Смотреть"
|
|
2033
2033
|
}, {
|
|
2034
|
-
default:
|
|
2034
|
+
default: w(() => [
|
|
2035
2035
|
M(d, {
|
|
2036
|
-
icon: ie(
|
|
2037
|
-
onClick:
|
|
2036
|
+
icon: ie(_(bt)),
|
|
2037
|
+
onClick: h[0] || (h[0] = (m) => l(e.record))
|
|
2038
2038
|
}, null, 8, ["icon"])
|
|
2039
2039
|
]),
|
|
2040
2040
|
_: 1
|
|
2041
|
-
})) :
|
|
2042
|
-
e.canEdit !== !1 ? (
|
|
2043
|
-
t.editAction !== !1 ? (
|
|
2041
|
+
})) : U("", !0),
|
|
2042
|
+
e.canEdit !== !1 ? (v(), C(O, { key: 1 }, [
|
|
2043
|
+
t.editAction !== !1 ? (v(), B(u, {
|
|
2044
2044
|
key: 0,
|
|
2045
2045
|
title: "Редактировать"
|
|
2046
2046
|
}, {
|
|
2047
|
-
default:
|
|
2047
|
+
default: w(() => [
|
|
2048
2048
|
M(d, {
|
|
2049
|
-
icon: ie(
|
|
2050
|
-
onClick:
|
|
2049
|
+
icon: ie(_(xt)),
|
|
2050
|
+
onClick: h[1] || (h[1] = (m) => l(e.record))
|
|
2051
2051
|
}, null, 8, ["icon"])
|
|
2052
2052
|
]),
|
|
2053
2053
|
_: 1
|
|
2054
|
-
})) :
|
|
2055
|
-
e.deleteAction !== !1 ? (
|
|
2054
|
+
})) : U("", !0),
|
|
2055
|
+
e.deleteAction !== !1 ? (v(), B(u, {
|
|
2056
2056
|
key: 1,
|
|
2057
2057
|
title: e.record.isDeleted ? "Восстановить" : "Удалить"
|
|
2058
2058
|
}, {
|
|
2059
|
-
default:
|
|
2059
|
+
default: w(() => [
|
|
2060
2060
|
M(d, {
|
|
2061
|
-
icon: ie(e.record.isDeleted ?
|
|
2062
|
-
onClick:
|
|
2061
|
+
icon: ie(e.record.isDeleted ? _(St) : _(At)),
|
|
2062
|
+
onClick: h[2] || (h[2] = (m) => e.record.isDeleted ? a(e.record) : r(e.record))
|
|
2063
2063
|
}, null, 8, ["icon"])
|
|
2064
2064
|
]),
|
|
2065
2065
|
_: 1
|
|
2066
|
-
}, 8, ["title"])) :
|
|
2067
|
-
], 64)) :
|
|
2066
|
+
}, 8, ["title"])) : U("", !0)
|
|
2067
|
+
], 64)) : U("", !0)
|
|
2068
2068
|
]);
|
|
2069
2069
|
};
|
|
2070
2070
|
}
|
|
2071
|
-
}),
|
|
2071
|
+
}), Lo = { key: 0 }, Oo = { key: 1 }, zo = { key: 2 }, Po = { key: 3 }, No = { key: 4 }, jo = { key: 5 }, Uo = /* @__PURE__ */ P({
|
|
2072
2072
|
__name: "TableBodyCell",
|
|
2073
2073
|
props: {
|
|
2074
2074
|
loading: { type: Boolean },
|
|
@@ -2077,7 +2077,7 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2077
2077
|
tagStyle: {}
|
|
2078
2078
|
},
|
|
2079
2079
|
setup(e) {
|
|
2080
|
-
const
|
|
2080
|
+
const n = e, t = T(() => n.record[String(n.column.dataIndex)]), o = (d) => d == null ? !0 : typeof d == "string" ? d.trim().length === 0 : !1, r = (d) => {
|
|
2081
2081
|
if (d === null || typeof d != "object")
|
|
2082
2082
|
return "";
|
|
2083
2083
|
if ("name" in d) {
|
|
@@ -2085,61 +2085,61 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2085
2085
|
return typeof u == "string" ? u : "";
|
|
2086
2086
|
}
|
|
2087
2087
|
return "";
|
|
2088
|
-
}, a = (d) => d == null ? "" : typeof d == "string" ? d.trim() : typeof d == "object" ? r(d) : String(d), l =
|
|
2088
|
+
}, a = (d) => d == null ? "" : typeof d == "string" ? d.trim() : typeof d == "object" ? r(d) : String(d), l = T(() => {
|
|
2089
2089
|
const d = t.value;
|
|
2090
2090
|
return Array.isArray(d) ? d.map((u) => a(u)).filter((u) => u.trim().length > 0) : [];
|
|
2091
|
-
}),
|
|
2091
|
+
}), s = T(() => l.value.map((d, u) => ({
|
|
2092
2092
|
key: `${d}-${u}`,
|
|
2093
2093
|
label: d
|
|
2094
|
-
}))),
|
|
2094
|
+
}))), h = T(() => !o(t.value));
|
|
2095
2095
|
return (d, u) => {
|
|
2096
|
-
const
|
|
2097
|
-
return e.loading ? (
|
|
2096
|
+
const m = H("a-skeleton"), S = H("a-tag");
|
|
2097
|
+
return e.loading ? (v(), B(m, {
|
|
2098
2098
|
key: 0,
|
|
2099
2099
|
active: !0,
|
|
2100
2100
|
loading: !0,
|
|
2101
2101
|
title: !1,
|
|
2102
2102
|
paragraph: { rows: 1 }
|
|
2103
|
-
})) : (
|
|
2104
|
-
e.column.dataIndex === "isDeleted" ? (
|
|
2105
|
-
M(
|
|
2103
|
+
})) : (v(), C(O, { key: 1 }, [
|
|
2104
|
+
e.column.dataIndex === "isDeleted" ? (v(), C("span", Lo, [
|
|
2105
|
+
M(Te, {
|
|
2106
2106
|
value: e.record.isDeleted
|
|
2107
2107
|
}, null, 8, ["value"])
|
|
2108
|
-
])) : Array.isArray(t.value) ? (
|
|
2109
|
-
e.column.tag === !0 ? (
|
|
2108
|
+
])) : Array.isArray(t.value) ? (v(), C("span", Oo, [
|
|
2109
|
+
e.column.tag === !0 ? (v(!0), C(O, { key: 0 }, W(s.value, (x) => (v(), B(S, {
|
|
2110
2110
|
key: x.key,
|
|
2111
|
-
style:
|
|
2111
|
+
style: ze(e.tagStyle),
|
|
2112
2112
|
class: "mr-1 mb-1"
|
|
2113
2113
|
}, {
|
|
2114
|
-
default:
|
|
2115
|
-
|
|
2114
|
+
default: w(() => [
|
|
2115
|
+
N(X(x.label), 1)
|
|
2116
2116
|
]),
|
|
2117
2117
|
_: 2
|
|
2118
|
-
}, 1032, ["style"]))), 128)) : (
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
], 64)) :
|
|
2118
|
+
}, 1032, ["style"]))), 128)) : (v(!0), C(O, { key: 1 }, W(l.value, (x, f) => (v(), C("span", { key: f }, [
|
|
2119
|
+
N(X(x) + " ", 1),
|
|
2120
|
+
f < l.value.length - 1 ? (v(), C(O, { key: 0 }, [
|
|
2121
|
+
N(", ")
|
|
2122
|
+
], 64)) : U("", !0)
|
|
2123
2123
|
]))), 128))
|
|
2124
|
-
])) : typeof t.value == "boolean" ? (
|
|
2125
|
-
M(
|
|
2124
|
+
])) : typeof t.value == "boolean" ? (v(), C("span", zo, [
|
|
2125
|
+
M(Te, {
|
|
2126
2126
|
value: !t.value
|
|
2127
2127
|
}, null, 8, ["value"])
|
|
2128
|
-
])) : t.value !== null && typeof t.value == "object" ? (
|
|
2129
|
-
|
|
2128
|
+
])) : t.value !== null && typeof t.value == "object" ? (v(), C("span", Po, X(r(t.value)), 1)) : e.column.tag === !0 ? (v(), C("span", No, [
|
|
2129
|
+
h.value ? (v(), B(S, {
|
|
2130
2130
|
key: 0,
|
|
2131
|
-
style:
|
|
2131
|
+
style: ze(e.tagStyle)
|
|
2132
2132
|
}, {
|
|
2133
|
-
default:
|
|
2134
|
-
|
|
2133
|
+
default: w(() => [
|
|
2134
|
+
N(X(String(t.value)), 1)
|
|
2135
2135
|
]),
|
|
2136
2136
|
_: 1
|
|
2137
|
-
}, 8, ["style"])) : (
|
|
2138
|
-
])) : (
|
|
2137
|
+
}, 8, ["style"])) : (v(), C(O, { key: 1 }, [], 64))
|
|
2138
|
+
])) : (v(), C("span", jo, X(t.value), 1))
|
|
2139
2139
|
], 64));
|
|
2140
2140
|
};
|
|
2141
2141
|
}
|
|
2142
|
-
}),
|
|
2142
|
+
}), Xo = { class: "efko-dataview" }, Go = { class: "flex items-center justify-between" }, Wo = { class: "flex items-center gap-2" }, qo = /* @__PURE__ */ P({
|
|
2143
2143
|
__name: "TheTable",
|
|
2144
2144
|
props: {
|
|
2145
2145
|
loading: { type: Boolean },
|
|
@@ -2154,48 +2154,49 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2154
2154
|
showActionsColumn: { type: Boolean },
|
|
2155
2155
|
columnsVisibility: {},
|
|
2156
2156
|
disableColumnFilterDropdowns: { type: Boolean },
|
|
2157
|
-
showFilterButton: { type: Boolean }
|
|
2157
|
+
showFilterButton: { type: Boolean },
|
|
2158
|
+
multiColumnFilters: { type: Boolean }
|
|
2158
2159
|
},
|
|
2159
2160
|
emits: ["update:filterValues", "filterApply", "restore", "edit", "delete", "sortChange", "pageChange", "sizeChange", "openColumnDrawer", "openFilterDrawer"],
|
|
2160
|
-
setup(e, { emit:
|
|
2161
|
-
const [, t] =
|
|
2162
|
-
|
|
2163
|
-
),
|
|
2164
|
-
...
|
|
2165
|
-
]),
|
|
2166
|
-
(
|
|
2167
|
-
)), u =
|
|
2168
|
-
const
|
|
2169
|
-
if (
|
|
2161
|
+
setup(e, { emit: n }) {
|
|
2162
|
+
const [, t] = Ft(), o = e, r = n, a = T(() => o.showFilterButton === !0), l = L(
|
|
2163
|
+
o.filterValues || {}
|
|
2164
|
+
), s = L([
|
|
2165
|
+
...o.columns
|
|
2166
|
+
]), h = L({}), d = T(() => o.disableColumnFilterDropdowns === !0 ? [] : s.value.filter(
|
|
2167
|
+
(y) => y.filterable
|
|
2168
|
+
)), u = T(() => {
|
|
2169
|
+
const c = s.value.filter((E) => {
|
|
2170
|
+
if (E.filterOnly)
|
|
2170
2171
|
return !1;
|
|
2171
|
-
const
|
|
2172
|
-
return
|
|
2173
|
-
}).map((
|
|
2174
|
-
const { headerAlign:
|
|
2172
|
+
const F = E.key || String(E.dataIndex);
|
|
2173
|
+
return o.columnsVisibility[F] !== !1;
|
|
2174
|
+
}).map((E) => {
|
|
2175
|
+
const { headerAlign: F, cellAlign: K, ...Q } = E;
|
|
2175
2176
|
return {
|
|
2176
|
-
...
|
|
2177
|
-
sorter: !!
|
|
2178
|
-
sortDirections:
|
|
2179
|
-
|
|
2180
|
-
|
|
2177
|
+
...Q,
|
|
2178
|
+
sorter: !!Q.sortable,
|
|
2179
|
+
sortDirections: Q.sortable ? [
|
|
2180
|
+
We.ASCEND,
|
|
2181
|
+
We.DESCEND
|
|
2181
2182
|
] : void 0,
|
|
2182
|
-
customHeaderCell: () =>
|
|
2183
|
+
customHeaderCell: () => F ? {
|
|
2183
2184
|
style: {
|
|
2184
|
-
textAlign:
|
|
2185
|
+
textAlign: F
|
|
2185
2186
|
}
|
|
2186
2187
|
} : void 0,
|
|
2187
|
-
customCell: () =>
|
|
2188
|
+
customCell: () => K ? {
|
|
2188
2189
|
style: {
|
|
2189
|
-
textAlign:
|
|
2190
|
+
textAlign: K
|
|
2190
2191
|
}
|
|
2191
2192
|
} : void 0,
|
|
2192
|
-
customFilterDropdown: !!
|
|
2193
|
-
slots:
|
|
2194
|
-
filterDropdown: `filter${String(
|
|
2193
|
+
customFilterDropdown: !!Q.filterable,
|
|
2194
|
+
slots: Q.filterable ? {
|
|
2195
|
+
filterDropdown: `filter${String(Q.dataIndex)}Dropdown`
|
|
2195
2196
|
} : void 0
|
|
2196
2197
|
};
|
|
2197
2198
|
});
|
|
2198
|
-
return
|
|
2199
|
+
return o.showActionsColumn !== !1 && o.columnsVisibility.actions !== !1 && c.push({
|
|
2199
2200
|
title: "Действия",
|
|
2200
2201
|
key: "actions",
|
|
2201
2202
|
dataIndex: "actions",
|
|
@@ -2203,123 +2204,146 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2203
2204
|
slots: {
|
|
2204
2205
|
customRender: "actionColumn"
|
|
2205
2206
|
}
|
|
2206
|
-
}),
|
|
2207
|
-
}),
|
|
2208
|
-
() => Object.keys(
|
|
2209
|
-
(
|
|
2207
|
+
}), c;
|
|
2208
|
+
}), m = T(
|
|
2209
|
+
() => Object.keys(o.columnsVisibility).filter(
|
|
2210
|
+
(y) => o.columnsVisibility[y] === !1
|
|
2210
2211
|
).length
|
|
2211
|
-
), S =
|
|
2212
|
+
), S = T(() => ({
|
|
2212
2213
|
color: t.value.colorSelectedMenu,
|
|
2213
2214
|
borderColor: t.value.colorBorderSecondary,
|
|
2214
2215
|
backgroundColor: t.value.mainBgColor || t.value.colorPrimaryBg
|
|
2215
|
-
})), x = (
|
|
2216
|
-
const
|
|
2217
|
-
return Array.isArray(
|
|
2218
|
-
},
|
|
2219
|
-
|
|
2220
|
-
|
|
2221
|
-
|
|
2222
|
-
|
|
2223
|
-
|
|
2224
|
-
|
|
2216
|
+
})), x = (y) => {
|
|
2217
|
+
const c = l.value[y];
|
|
2218
|
+
return Array.isArray(c) ? c : c != null ? [c] : [];
|
|
2219
|
+
}, f = (y) => Array.isArray(y) && y.length === 2 && typeof y[0] == "string" && typeof y[1] == "string", k = (y) => {
|
|
2220
|
+
if (typeof y == "string")
|
|
2221
|
+
return y;
|
|
2222
|
+
if (y !== null && typeof y == "object") {
|
|
2223
|
+
const c = y.format;
|
|
2224
|
+
if (typeof c == "function")
|
|
2225
|
+
return c("YYYY-MM-DD");
|
|
2226
|
+
const E = y.toISOString;
|
|
2227
|
+
if (typeof E == "function")
|
|
2228
|
+
return E();
|
|
2229
|
+
}
|
|
2230
|
+
return String(y);
|
|
2231
|
+
}, i = (y, c) => {
|
|
2232
|
+
if (c == null)
|
|
2233
|
+
return [];
|
|
2234
|
+
if (y.filterMode === q.SEARCH) {
|
|
2235
|
+
if (typeof c != "string")
|
|
2236
|
+
return [];
|
|
2237
|
+
const E = c.trim();
|
|
2238
|
+
return E.length === 0 ? [] : [E];
|
|
2239
|
+
}
|
|
2240
|
+
return y.filterMode === q.DATE ? !Array.isArray(c) || c.length !== 2 ? [] : [[
|
|
2241
|
+
k(c[0]),
|
|
2242
|
+
k(c[1])
|
|
2243
|
+
]] : Array.isArray(c) ? c : [c];
|
|
2244
|
+
}, p = (y, c) => {
|
|
2245
|
+
const E = { ...l.value };
|
|
2246
|
+
if (c === null)
|
|
2247
|
+
E[y] = null, r("filterApply", { key: y, value: [] });
|
|
2248
|
+
else if (Array.isArray(c)) {
|
|
2249
|
+
const F = c.filter((K) => K != null);
|
|
2250
|
+
F.length === 0 ? (E[y] = null, r("filterApply", { key: y, value: [] })) : F.length === 1 && !f(F[0]) ? (E[y] = F[0], r("filterApply", { key: y, value: F })) : (E[y] = F, r("filterApply", { key: y, value: F }));
|
|
2225
2251
|
} else
|
|
2226
|
-
|
|
2227
|
-
r("update:filterValues",
|
|
2228
|
-
},
|
|
2229
|
-
const
|
|
2230
|
-
if (
|
|
2231
|
-
|
|
2252
|
+
E[y] = c, r("filterApply", { key: y, value: [c] });
|
|
2253
|
+
r("update:filterValues", E), l.value = E, h.value[y] = null;
|
|
2254
|
+
}, b = (y, c) => {
|
|
2255
|
+
const E = String(y.dataIndex), F = i(y, c);
|
|
2256
|
+
if (F.length === 0) {
|
|
2257
|
+
h.value[E] = null;
|
|
2232
2258
|
return;
|
|
2233
2259
|
}
|
|
2234
|
-
if (
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
const R = [];
|
|
2238
|
-
v.forEach((te) => {
|
|
2239
|
-
R.some((re) => J(re, te)) || R.push(te);
|
|
2240
|
-
}), R.length === h.length && R.every((te) => h.some((re) => J(re, te))) ? f.value[k] = null : i(k, R);
|
|
2260
|
+
if (!((y.filterMultiple ?? o.multiColumnFilters ?? !0) !== !1)) {
|
|
2261
|
+
if (y.filterMode === q.DATE) {
|
|
2262
|
+
p(E, F);
|
|
2241
2263
|
return;
|
|
2242
2264
|
}
|
|
2243
|
-
if (
|
|
2244
|
-
|
|
2265
|
+
if (Array.isArray(c)) {
|
|
2266
|
+
p(E, F[F.length - 1]);
|
|
2245
2267
|
return;
|
|
2246
2268
|
}
|
|
2247
|
-
|
|
2248
|
-
...h,
|
|
2249
|
-
v
|
|
2250
|
-
]);
|
|
2269
|
+
p(E, F[0]);
|
|
2251
2270
|
return;
|
|
2252
2271
|
}
|
|
2253
|
-
const
|
|
2254
|
-
|
|
2255
|
-
|
|
2272
|
+
const ue = [
|
|
2273
|
+
...x(E)
|
|
2274
|
+
];
|
|
2275
|
+
let de = !1;
|
|
2276
|
+
if (F.forEach((fe) => {
|
|
2277
|
+
ue.some((xe) => ye(xe, fe)) || (ue.push(fe), de = !0);
|
|
2278
|
+
}), !de) {
|
|
2279
|
+
h.value[E] = null;
|
|
2256
2280
|
return;
|
|
2257
2281
|
}
|
|
2258
|
-
|
|
2259
|
-
},
|
|
2282
|
+
p(E, ue);
|
|
2283
|
+
}, g = (y) => y.isGroup ? "parent-row" : "", A = (y, c, E) => {
|
|
2260
2284
|
r("sortChange", {
|
|
2261
|
-
columnKey:
|
|
2262
|
-
order:
|
|
2285
|
+
columnKey: E.columnKey || "",
|
|
2286
|
+
order: E.order || null
|
|
2263
2287
|
});
|
|
2264
|
-
},
|
|
2265
|
-
const
|
|
2266
|
-
(
|
|
2288
|
+
}, V = (y, c) => {
|
|
2289
|
+
const E = c.key || String(c.dataIndex), F = s.value.findIndex(
|
|
2290
|
+
(K) => (K.key || String(K.dataIndex)) === E
|
|
2267
2291
|
);
|
|
2268
|
-
|
|
2269
|
-
...
|
|
2270
|
-
width:
|
|
2292
|
+
F !== -1 && s.value.splice(F, 1, {
|
|
2293
|
+
...c,
|
|
2294
|
+
width: y
|
|
2271
2295
|
});
|
|
2272
2296
|
};
|
|
2273
|
-
return
|
|
2274
|
-
() =>
|
|
2275
|
-
(
|
|
2276
|
-
l.value =
|
|
2297
|
+
return $(
|
|
2298
|
+
() => o.filterValues,
|
|
2299
|
+
(y) => {
|
|
2300
|
+
l.value = y || {};
|
|
2277
2301
|
}
|
|
2278
|
-
),
|
|
2279
|
-
() =>
|
|
2280
|
-
(
|
|
2281
|
-
|
|
2282
|
-
...
|
|
2302
|
+
), $(
|
|
2303
|
+
() => o.columns,
|
|
2304
|
+
(y) => {
|
|
2305
|
+
s.value = [
|
|
2306
|
+
...y
|
|
2283
2307
|
];
|
|
2284
2308
|
},
|
|
2285
2309
|
{
|
|
2286
2310
|
immediate: !0
|
|
2287
2311
|
}
|
|
2288
2312
|
), le(() => {
|
|
2289
|
-
const
|
|
2290
|
-
|
|
2291
|
-
}), (
|
|
2292
|
-
var
|
|
2293
|
-
const
|
|
2294
|
-
return
|
|
2295
|
-
M(
|
|
2313
|
+
const y = document.querySelector(".the-table tbody");
|
|
2314
|
+
y !== null && Qe(y);
|
|
2315
|
+
}), (y, c) => {
|
|
2316
|
+
var de, fe, xe, tt;
|
|
2317
|
+
const E = H("Icon"), F = H("a-button"), K = H("a-badge"), Q = H("a-table"), ue = H("a-pagination");
|
|
2318
|
+
return v(), C("div", Xo, [
|
|
2319
|
+
M(Q, {
|
|
2296
2320
|
bordered: "",
|
|
2297
2321
|
"table-layout": "fixed",
|
|
2298
2322
|
class: "the-table",
|
|
2299
2323
|
loading: e.loading,
|
|
2300
2324
|
columns: u.value,
|
|
2301
2325
|
"data-source": e.dataSource,
|
|
2302
|
-
"row-key": (
|
|
2326
|
+
"row-key": (D) => D.id,
|
|
2303
2327
|
pagination: !1,
|
|
2304
2328
|
scroll: { x: "max-content" },
|
|
2305
|
-
"row-class-name":
|
|
2306
|
-
onChange:
|
|
2307
|
-
onResizeColumn:
|
|
2308
|
-
},
|
|
2309
|
-
title:
|
|
2310
|
-
|
|
2311
|
-
|
|
2312
|
-
M(
|
|
2329
|
+
"row-class-name": g,
|
|
2330
|
+
onChange: A,
|
|
2331
|
+
onResizeColumn: V
|
|
2332
|
+
}, Ie({
|
|
2333
|
+
title: w(() => [
|
|
2334
|
+
R("div", Go, [
|
|
2335
|
+
R("div", Wo, [
|
|
2336
|
+
M(K, {
|
|
2313
2337
|
dot: "",
|
|
2314
|
-
count:
|
|
2338
|
+
count: m.value
|
|
2315
2339
|
}, {
|
|
2316
|
-
default:
|
|
2317
|
-
M(
|
|
2340
|
+
default: w(() => [
|
|
2341
|
+
M(F, {
|
|
2318
2342
|
class: "flex items-center justify-center p-2",
|
|
2319
|
-
onClick:
|
|
2343
|
+
onClick: c[0] || (c[0] = (D) => y.$emit("openColumnDrawer"))
|
|
2320
2344
|
}, {
|
|
2321
|
-
default:
|
|
2322
|
-
M(
|
|
2345
|
+
default: w(() => [
|
|
2346
|
+
M(E, {
|
|
2323
2347
|
name: "solar:settings-outline",
|
|
2324
2348
|
class: "text-lg"
|
|
2325
2349
|
})
|
|
@@ -2329,80 +2353,80 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2329
2353
|
]),
|
|
2330
2354
|
_: 1
|
|
2331
2355
|
}, 8, ["count"]),
|
|
2332
|
-
a.value ? (
|
|
2356
|
+
a.value ? (v(), B(F, {
|
|
2333
2357
|
key: 0,
|
|
2334
2358
|
class: "flex items-center justify-center p-2",
|
|
2335
|
-
onClick:
|
|
2359
|
+
onClick: c[1] || (c[1] = (D) => y.$emit("openFilterDrawer"))
|
|
2336
2360
|
}, {
|
|
2337
|
-
default:
|
|
2338
|
-
M(
|
|
2361
|
+
default: w(() => [
|
|
2362
|
+
M(E, {
|
|
2339
2363
|
name: "ant-design:filter-outlined",
|
|
2340
2364
|
class: "text-lg"
|
|
2341
2365
|
})
|
|
2342
2366
|
]),
|
|
2343
2367
|
_: 1
|
|
2344
|
-
})) :
|
|
2368
|
+
})) : U("", !0)
|
|
2345
2369
|
]),
|
|
2346
|
-
|
|
2370
|
+
z(y.$slots, "title")
|
|
2347
2371
|
])
|
|
2348
2372
|
]),
|
|
2349
|
-
bodyCell:
|
|
2350
|
-
|
|
2351
|
-
column:
|
|
2352
|
-
record:
|
|
2373
|
+
bodyCell: w(({ column: D, record: te }) => [
|
|
2374
|
+
z(y.$slots, "bodyCell", {
|
|
2375
|
+
column: D,
|
|
2376
|
+
record: te
|
|
2353
2377
|
}, () => [
|
|
2354
|
-
M(
|
|
2378
|
+
M(Uo, {
|
|
2355
2379
|
loading: e.loading,
|
|
2356
|
-
column:
|
|
2357
|
-
record:
|
|
2380
|
+
column: D,
|
|
2381
|
+
record: te,
|
|
2358
2382
|
"tag-style": S.value
|
|
2359
2383
|
}, null, 8, ["loading", "column", "record", "tag-style"])
|
|
2360
2384
|
])
|
|
2361
2385
|
]),
|
|
2362
|
-
actionColumn:
|
|
2363
|
-
|
|
2364
|
-
M(
|
|
2386
|
+
actionColumn: w(({ record: D }) => [
|
|
2387
|
+
z(y.$slots, "actionColumn", { record: D }, () => [
|
|
2388
|
+
M(Ro, {
|
|
2365
2389
|
"edit-action": e.editAction,
|
|
2366
2390
|
"delete-action": e.deleteAction,
|
|
2367
2391
|
"can-edit": e.canEdit,
|
|
2368
|
-
record:
|
|
2369
|
-
onEdit: () =>
|
|
2370
|
-
onDelete: () =>
|
|
2371
|
-
onRestore: () =>
|
|
2392
|
+
record: D,
|
|
2393
|
+
onEdit: () => y.$emit("edit", D),
|
|
2394
|
+
onDelete: () => y.$emit("delete", D),
|
|
2395
|
+
onRestore: () => y.$emit("restore", D)
|
|
2372
2396
|
}, null, 8, ["edit-action", "delete-action", "can-edit", "record", "onEdit", "onDelete", "onRestore"])
|
|
2373
2397
|
])
|
|
2374
2398
|
]),
|
|
2375
2399
|
_: 2
|
|
2376
2400
|
}, [
|
|
2377
|
-
|
|
2378
|
-
name: `filter${String(
|
|
2379
|
-
fn:
|
|
2380
|
-
M(
|
|
2381
|
-
modelValue:
|
|
2382
|
-
"onUpdate:modelValue": [(
|
|
2383
|
-
"filter-mode":
|
|
2384
|
-
"component-props":
|
|
2385
|
-
placeholder:
|
|
2401
|
+
W(d.value, (D) => ({
|
|
2402
|
+
name: `filter${String(D.dataIndex)}Dropdown`,
|
|
2403
|
+
fn: w(() => [
|
|
2404
|
+
M(Vo, {
|
|
2405
|
+
modelValue: h.value[D.dataIndex],
|
|
2406
|
+
"onUpdate:modelValue": [(te) => h.value[D.dataIndex] = te, (te) => b(D, te)],
|
|
2407
|
+
"filter-mode": D.filterMode,
|
|
2408
|
+
"component-props": D.componentProps,
|
|
2409
|
+
placeholder: D.title
|
|
2386
2410
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "filter-mode", "component-props", "placeholder"])
|
|
2387
2411
|
])
|
|
2388
2412
|
}))
|
|
2389
2413
|
]), 1032, ["loading", "columns", "data-source", "row-key"]),
|
|
2390
|
-
e.pagination ? (
|
|
2414
|
+
e.pagination ? (v(), B(ue, {
|
|
2391
2415
|
key: 0,
|
|
2392
2416
|
class: "mt-4 text-right",
|
|
2393
|
-
current: (
|
|
2394
|
-
"page-size": (
|
|
2395
|
-
total: (
|
|
2396
|
-
"show-total": (
|
|
2397
|
-
"page-size-options": (
|
|
2417
|
+
current: (de = e.meta) == null ? void 0 : de.currentPage,
|
|
2418
|
+
"page-size": (fe = e.meta) == null ? void 0 : fe.pageSize,
|
|
2419
|
+
total: (xe = e.meta) == null ? void 0 : xe.total,
|
|
2420
|
+
"show-total": (D) => `Всего ${D} элементов`,
|
|
2421
|
+
"page-size-options": (tt = e.meta) == null ? void 0 : tt.pageSizeOptions,
|
|
2398
2422
|
"show-size-changer": !0,
|
|
2399
|
-
onChange:
|
|
2400
|
-
onShowSizeChange:
|
|
2401
|
-
}, null, 8, ["current", "page-size", "total", "show-total", "page-size-options"])) :
|
|
2423
|
+
onChange: c[2] || (c[2] = (D) => y.$emit("pageChange", D)),
|
|
2424
|
+
onShowSizeChange: c[3] || (c[3] = (D, te) => y.$emit("sizeChange", D, te))
|
|
2425
|
+
}, null, 8, ["current", "page-size", "total", "show-total", "page-size-options"])) : U("", !0)
|
|
2402
2426
|
]);
|
|
2403
2427
|
};
|
|
2404
2428
|
}
|
|
2405
|
-
}),
|
|
2429
|
+
}), Ko = { class: "mb-4" }, Yo = { class: "flex flex-col gap-1" }, Zo = /* @__PURE__ */ P({
|
|
2406
2430
|
__name: "ColumnSettingsDrawer",
|
|
2407
2431
|
props: {
|
|
2408
2432
|
visible: { type: Boolean },
|
|
@@ -2414,114 +2438,114 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2414
2438
|
cardLayout: {}
|
|
2415
2439
|
},
|
|
2416
2440
|
emits: ["update:visible", "update:modelValue", "update:viewMode", "update:cardLayout"],
|
|
2417
|
-
setup(e, { emit:
|
|
2418
|
-
const t = e,
|
|
2441
|
+
setup(e, { emit: n }) {
|
|
2442
|
+
const t = e, o = n, r = L(t.visible), a = L(t.viewMode), l = L(t.cardLayout), s = Ze({
|
|
2419
2443
|
...t.modelValue
|
|
2420
|
-
}),
|
|
2421
|
-
return
|
|
2444
|
+
}), h = T(() => a.value === "grid"), d = t.disableViewMode || !1;
|
|
2445
|
+
return $(
|
|
2422
2446
|
() => t.visible,
|
|
2423
2447
|
(u) => {
|
|
2424
2448
|
r.value = u;
|
|
2425
2449
|
}
|
|
2426
|
-
),
|
|
2427
|
-
|
|
2428
|
-
}),
|
|
2450
|
+
), $(r, (u) => {
|
|
2451
|
+
o("update:visible", u);
|
|
2452
|
+
}), $(
|
|
2429
2453
|
() => t.viewMode,
|
|
2430
2454
|
(u) => {
|
|
2431
2455
|
a.value = u;
|
|
2432
2456
|
}
|
|
2433
|
-
),
|
|
2434
|
-
|
|
2435
|
-
}),
|
|
2457
|
+
), $(a, (u) => {
|
|
2458
|
+
o("update:viewMode", u);
|
|
2459
|
+
}), $(
|
|
2436
2460
|
() => t.cardLayout,
|
|
2437
2461
|
(u) => {
|
|
2438
2462
|
l.value = u;
|
|
2439
2463
|
}
|
|
2440
|
-
),
|
|
2441
|
-
|
|
2442
|
-
}),
|
|
2464
|
+
), $(l, (u) => {
|
|
2465
|
+
o("update:cardLayout", u);
|
|
2466
|
+
}), $(
|
|
2443
2467
|
() => t.modelValue,
|
|
2444
|
-
(u) => Object.assign(
|
|
2468
|
+
(u) => Object.assign(s, u),
|
|
2445
2469
|
{
|
|
2446
2470
|
deep: !0
|
|
2447
2471
|
}
|
|
2448
|
-
),
|
|
2472
|
+
), $(s, (u) => o("update:modelValue", {
|
|
2449
2473
|
...u
|
|
2450
2474
|
}), {
|
|
2451
2475
|
deep: !0
|
|
2452
|
-
}), t.showActionsColumn &&
|
|
2453
|
-
const S = H("a-checkbox"), x = H("a-radio"),
|
|
2454
|
-
return
|
|
2476
|
+
}), t.showActionsColumn && s.actions === void 0 && (s.actions = !0), (u, m) => {
|
|
2477
|
+
const S = H("a-checkbox"), x = H("a-radio"), f = H("a-radio-group"), k = H("a-radio-button"), i = H("a-drawer");
|
|
2478
|
+
return v(), B(i, {
|
|
2455
2479
|
open: r.value,
|
|
2456
|
-
"onUpdate:open":
|
|
2480
|
+
"onUpdate:open": m[2] || (m[2] = (p) => r.value = p),
|
|
2457
2481
|
class: "efko-dataview",
|
|
2458
2482
|
title: "Настройки представления",
|
|
2459
2483
|
placement: "right"
|
|
2460
2484
|
}, {
|
|
2461
|
-
default:
|
|
2462
|
-
|
|
2463
|
-
|
|
2464
|
-
|
|
2465
|
-
(
|
|
2466
|
-
key:
|
|
2485
|
+
default: w(() => [
|
|
2486
|
+
R("section", Ko, [
|
|
2487
|
+
m[3] || (m[3] = R("h3", { class: "font-bold text-base mb-2" }, "Отображение колонок", -1)),
|
|
2488
|
+
R("div", Yo, [
|
|
2489
|
+
(v(!0), C(O, null, W(e.columns, (p) => (v(), C("div", {
|
|
2490
|
+
key: p.key ?? p.dataIndex
|
|
2467
2491
|
}, [
|
|
2468
2492
|
M(S, {
|
|
2469
|
-
checked:
|
|
2470
|
-
"onUpdate:checked": (b) =>
|
|
2471
|
-
disabled:
|
|
2493
|
+
checked: s[p.key ?? p.dataIndex],
|
|
2494
|
+
"onUpdate:checked": (b) => s[p.key ?? p.dataIndex] = b,
|
|
2495
|
+
disabled: h.value,
|
|
2472
2496
|
class: "flex"
|
|
2473
2497
|
}, {
|
|
2474
|
-
default:
|
|
2475
|
-
|
|
2498
|
+
default: w(() => [
|
|
2499
|
+
N(X(p.title), 1)
|
|
2476
2500
|
]),
|
|
2477
2501
|
_: 2
|
|
2478
2502
|
}, 1032, ["checked", "onUpdate:checked", "disabled"])
|
|
2479
2503
|
]))), 128))
|
|
2480
2504
|
])
|
|
2481
2505
|
]),
|
|
2482
|
-
|
|
2483
|
-
|
|
2484
|
-
M(
|
|
2506
|
+
R("section", null, [
|
|
2507
|
+
m[8] || (m[8] = R("h3", { class: "font-bold text-base mb-2" }, "Вид", -1)),
|
|
2508
|
+
M(f, {
|
|
2485
2509
|
value: a.value,
|
|
2486
|
-
"onUpdate:value":
|
|
2510
|
+
"onUpdate:value": m[0] || (m[0] = (p) => a.value = p),
|
|
2487
2511
|
"button-style": "solid",
|
|
2488
2512
|
class: "mb-3",
|
|
2489
|
-
disabled:
|
|
2513
|
+
disabled: _(d)
|
|
2490
2514
|
}, {
|
|
2491
|
-
default:
|
|
2515
|
+
default: w(() => [
|
|
2492
2516
|
M(x, { value: "table" }, {
|
|
2493
|
-
default:
|
|
2494
|
-
|
|
2517
|
+
default: w(() => [...m[4] || (m[4] = [
|
|
2518
|
+
N("Таблица", -1)
|
|
2495
2519
|
])]),
|
|
2496
2520
|
_: 1
|
|
2497
2521
|
}),
|
|
2498
2522
|
M(x, { value: "grid" }, {
|
|
2499
|
-
default:
|
|
2500
|
-
|
|
2523
|
+
default: w(() => [...m[5] || (m[5] = [
|
|
2524
|
+
N("Карточки", -1)
|
|
2501
2525
|
])]),
|
|
2502
2526
|
_: 1
|
|
2503
2527
|
})
|
|
2504
2528
|
]),
|
|
2505
2529
|
_: 1
|
|
2506
2530
|
}, 8, ["value", "disabled"]),
|
|
2507
|
-
M(
|
|
2531
|
+
M(f, {
|
|
2508
2532
|
value: l.value,
|
|
2509
|
-
"onUpdate:value":
|
|
2533
|
+
"onUpdate:value": m[1] || (m[1] = (p) => l.value = p),
|
|
2510
2534
|
"button-style": "solid",
|
|
2511
|
-
disabled: !
|
|
2535
|
+
disabled: !h.value
|
|
2512
2536
|
}, {
|
|
2513
|
-
default:
|
|
2514
|
-
M(
|
|
2515
|
-
default:
|
|
2516
|
-
M(
|
|
2517
|
-
|
|
2537
|
+
default: w(() => [
|
|
2538
|
+
M(k, { value: "grid" }, {
|
|
2539
|
+
default: w(() => [
|
|
2540
|
+
M(_(Nt), { class: "mr-2" }),
|
|
2541
|
+
m[6] || (m[6] = N("Сетка ", -1))
|
|
2518
2542
|
]),
|
|
2519
2543
|
_: 1
|
|
2520
2544
|
}),
|
|
2521
|
-
M(
|
|
2522
|
-
default:
|
|
2523
|
-
M(
|
|
2524
|
-
|
|
2545
|
+
M(k, { value: "row" }, {
|
|
2546
|
+
default: w(() => [
|
|
2547
|
+
M(_(jt), { class: "mr-2" }),
|
|
2548
|
+
m[7] || (m[7] = N("Строка ", -1))
|
|
2525
2549
|
]),
|
|
2526
2550
|
_: 1
|
|
2527
2551
|
})
|
|
@@ -2534,7 +2558,7 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2534
2558
|
}, 8, ["open"]);
|
|
2535
2559
|
};
|
|
2536
2560
|
}
|
|
2537
|
-
}),
|
|
2561
|
+
}), _t = /* @__PURE__ */ P({
|
|
2538
2562
|
__name: "FilterInput",
|
|
2539
2563
|
props: {
|
|
2540
2564
|
modelValue: { type: [String, Number, Boolean, Object, Array, null] },
|
|
@@ -2543,20 +2567,20 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2543
2567
|
placeholder: {}
|
|
2544
2568
|
},
|
|
2545
2569
|
emits: ["update:modelValue"],
|
|
2546
|
-
setup(e, { emit:
|
|
2547
|
-
const t = e,
|
|
2548
|
-
return
|
|
2570
|
+
setup(e, { emit: n }) {
|
|
2571
|
+
const t = e, o = n, r = T(() => t.filterMode === q.SEARCH ? "a-input" : t.filterMode === q.SELECT ? Vt : t.filterMode === q.DATE ? "a-range-picker" : "a-input"), a = L(t.modelValue);
|
|
2572
|
+
return $(() => t.modelValue, (l) => {
|
|
2549
2573
|
a.value = l;
|
|
2550
|
-
}),
|
|
2574
|
+
}), $(a, (l) => o("update:modelValue", l)), (l, s) => (v(), B(yt(r.value), Ye(e.componentProps, {
|
|
2551
2575
|
value: a.value,
|
|
2552
|
-
"onUpdate:value":
|
|
2576
|
+
"onUpdate:value": s[0] || (s[0] = (h) => a.value = h),
|
|
2553
2577
|
modelValue: a.value,
|
|
2554
|
-
"onUpdate:modelValue":
|
|
2578
|
+
"onUpdate:modelValue": s[1] || (s[1] = (h) => a.value = h),
|
|
2555
2579
|
placeholder: e.placeholder,
|
|
2556
2580
|
class: "w-full text-sm"
|
|
2557
2581
|
}), null, 16, ["value", "modelValue", "placeholder"]));
|
|
2558
2582
|
}
|
|
2559
|
-
}),
|
|
2583
|
+
}), Qo = { class: "text-sm font-medium" }, Jo = { class: "mt-2 flex flex-col gap-2" }, er = /* @__PURE__ */ P({
|
|
2560
2584
|
__name: "CardFiltersDrawer",
|
|
2561
2585
|
props: {
|
|
2562
2586
|
visible: { type: Boolean },
|
|
@@ -2564,97 +2588,113 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2564
2588
|
filterValues: {}
|
|
2565
2589
|
},
|
|
2566
2590
|
emits: ["update:visible", "update:filterValues", "filterApply"],
|
|
2567
|
-
setup(e, { emit:
|
|
2568
|
-
const t = e,
|
|
2591
|
+
setup(e, { emit: n }) {
|
|
2592
|
+
const t = e, o = n, r = L(t.visible), a = Ze({
|
|
2569
2593
|
...t.filterValues
|
|
2570
|
-
}), l = (i) => i.key ?? String(i.dataIndex),
|
|
2571
|
-
(i
|
|
2572
|
-
|
|
2573
|
-
|
|
2574
|
-
|
|
2594
|
+
}), l = (i) => i.key ?? String(i.dataIndex), s = (i) => {
|
|
2595
|
+
if (typeof i == "string")
|
|
2596
|
+
return i;
|
|
2597
|
+
if (i !== null && typeof i == "object") {
|
|
2598
|
+
const p = i.format;
|
|
2599
|
+
if (typeof p == "function")
|
|
2600
|
+
return p("YYYY-MM-DD");
|
|
2601
|
+
const b = i.toISOString;
|
|
2602
|
+
if (typeof b == "function")
|
|
2603
|
+
return b();
|
|
2604
|
+
}
|
|
2605
|
+
return String(i);
|
|
2606
|
+
}, h = (i, p) => {
|
|
2607
|
+
if (p !== void 0)
|
|
2608
|
+
return i.filterMode === q.DATE && Array.isArray(p) && p.length === 2 ? [[s(p[0]), s(p[1])]] : p;
|
|
2609
|
+
}, d = (i) => Array.isArray(i) ? i : i != null ? [i] : [], u = (i) => i == null ? !0 : Array.isArray(i) ? i.length === 0 : typeof i == "string" ? i.trim() === "" : !1, m = T(() => t.columns.filter((i) => i.filterable)), S = T(() => Object.keys(a).some(
|
|
2610
|
+
(i) => !ye(a[i], t.filterValues[i])
|
|
2611
|
+
)), x = (i) => {
|
|
2612
|
+
Object.keys(a).forEach((p) => {
|
|
2613
|
+
delete a[p];
|
|
2575
2614
|
}), Object.assign(a, i);
|
|
2576
2615
|
};
|
|
2577
|
-
|
|
2616
|
+
$(
|
|
2578
2617
|
() => t.visible,
|
|
2579
2618
|
(i) => {
|
|
2580
|
-
r.value = i, i &&
|
|
2619
|
+
r.value = i, i && x(t.filterValues);
|
|
2581
2620
|
}
|
|
2582
|
-
),
|
|
2583
|
-
|
|
2584
|
-
}),
|
|
2621
|
+
), $(r, (i) => {
|
|
2622
|
+
o("update:visible", i);
|
|
2623
|
+
}), $(
|
|
2585
2624
|
() => t.filterValues,
|
|
2586
2625
|
(i) => {
|
|
2587
|
-
|
|
2626
|
+
x(i);
|
|
2588
2627
|
},
|
|
2589
2628
|
{
|
|
2590
2629
|
deep: !0
|
|
2591
2630
|
}
|
|
2592
2631
|
);
|
|
2593
|
-
const
|
|
2632
|
+
const f = () => {
|
|
2594
2633
|
const i = {
|
|
2595
2634
|
...t.filterValues
|
|
2596
2635
|
};
|
|
2597
|
-
Object.entries(a).forEach(([
|
|
2598
|
-
|
|
2599
|
-
|
|
2600
|
-
|
|
2636
|
+
Object.entries(a).forEach(([p, b]) => {
|
|
2637
|
+
const g = t.columns.find((V) => String(l(V)) === p), A = g ? h(g, b) : b;
|
|
2638
|
+
if (u(b)) {
|
|
2639
|
+
i[p] = null, o("filterApply", {
|
|
2640
|
+
key: p,
|
|
2601
2641
|
value: []
|
|
2602
2642
|
});
|
|
2603
2643
|
return;
|
|
2604
2644
|
}
|
|
2605
|
-
i[
|
|
2606
|
-
key:
|
|
2607
|
-
value:
|
|
2645
|
+
i[p] = A, o("filterApply", {
|
|
2646
|
+
key: p,
|
|
2647
|
+
value: d(A)
|
|
2608
2648
|
});
|
|
2609
|
-
}),
|
|
2610
|
-
},
|
|
2611
|
-
Object.keys(a).forEach((
|
|
2612
|
-
delete a[
|
|
2613
|
-
}),
|
|
2649
|
+
}), o("update:filterValues", i), r.value = !1;
|
|
2650
|
+
}, k = () => {
|
|
2651
|
+
Object.keys(a).forEach((p) => {
|
|
2652
|
+
delete a[p];
|
|
2653
|
+
}), o("update:filterValues", {});
|
|
2614
2654
|
};
|
|
2615
|
-
return (i,
|
|
2616
|
-
const
|
|
2617
|
-
return
|
|
2655
|
+
return (i, p) => {
|
|
2656
|
+
const b = H("a-button"), g = H("a-drawer");
|
|
2657
|
+
return v(), B(g, {
|
|
2618
2658
|
open: r.value,
|
|
2619
|
-
"onUpdate:open":
|
|
2659
|
+
"onUpdate:open": p[0] || (p[0] = (A) => r.value = A),
|
|
2620
2660
|
class: "efko-dataview",
|
|
2621
2661
|
placement: "right",
|
|
2622
2662
|
width: "360",
|
|
2623
2663
|
title: "Фильтры",
|
|
2624
2664
|
"body-style": "padding: 24px"
|
|
2625
2665
|
}, {
|
|
2626
|
-
default:
|
|
2627
|
-
(
|
|
2628
|
-
key: l(
|
|
2666
|
+
default: w(() => [
|
|
2667
|
+
(v(!0), C(O, null, W(m.value, (A) => (v(), C("section", {
|
|
2668
|
+
key: l(A),
|
|
2629
2669
|
class: "mb-4 flex flex-col gap-2"
|
|
2630
2670
|
}, [
|
|
2631
|
-
|
|
2632
|
-
M(
|
|
2633
|
-
modelValue: a[l(
|
|
2634
|
-
"onUpdate:modelValue": (
|
|
2635
|
-
"filter-mode":
|
|
2636
|
-
"component-props":
|
|
2637
|
-
placeholder:
|
|
2671
|
+
R("span", Qo, X(A.title), 1),
|
|
2672
|
+
M(_t, {
|
|
2673
|
+
modelValue: a[l(A)],
|
|
2674
|
+
"onUpdate:modelValue": (V) => a[l(A)] = V,
|
|
2675
|
+
"filter-mode": A.filterMode,
|
|
2676
|
+
"component-props": A.componentProps,
|
|
2677
|
+
placeholder: A.title
|
|
2638
2678
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "filter-mode", "component-props", "placeholder"])
|
|
2639
2679
|
]))), 128)),
|
|
2640
|
-
|
|
2641
|
-
M(
|
|
2680
|
+
R("div", Jo, [
|
|
2681
|
+
M(b, {
|
|
2642
2682
|
block: "",
|
|
2643
|
-
onClick:
|
|
2683
|
+
onClick: k
|
|
2644
2684
|
}, {
|
|
2645
|
-
default:
|
|
2646
|
-
|
|
2685
|
+
default: w(() => [...p[1] || (p[1] = [
|
|
2686
|
+
N(" Сбросить ", -1)
|
|
2647
2687
|
])]),
|
|
2648
2688
|
_: 1
|
|
2649
2689
|
}),
|
|
2650
|
-
M(
|
|
2690
|
+
M(b, {
|
|
2651
2691
|
type: "primary",
|
|
2652
2692
|
block: "",
|
|
2653
|
-
disabled: !
|
|
2654
|
-
onClick:
|
|
2693
|
+
disabled: !S.value,
|
|
2694
|
+
onClick: f
|
|
2655
2695
|
}, {
|
|
2656
|
-
default:
|
|
2657
|
-
|
|
2696
|
+
default: w(() => [...p[2] || (p[2] = [
|
|
2697
|
+
N(" Применить ", -1)
|
|
2658
2698
|
])]),
|
|
2659
2699
|
_: 1
|
|
2660
2700
|
}, 8, ["disabled"])
|
|
@@ -2664,7 +2704,7 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2664
2704
|
}, 8, ["open"]);
|
|
2665
2705
|
};
|
|
2666
2706
|
}
|
|
2667
|
-
}),
|
|
2707
|
+
}), tr = /* @__PURE__ */ ce(er, [["__scopeId", "data-v-c29393f2"]]), nr = { class: "text-sm font-medium" }, or = /* @__PURE__ */ P({
|
|
2668
2708
|
__name: "CardFiltersModal",
|
|
2669
2709
|
props: {
|
|
2670
2710
|
visible: { type: Boolean },
|
|
@@ -2672,80 +2712,96 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2672
2712
|
filterValues: {}
|
|
2673
2713
|
},
|
|
2674
2714
|
emits: ["update:visible", "update:filterValues", "filterApply"],
|
|
2675
|
-
setup(e, { emit:
|
|
2676
|
-
const t = e,
|
|
2715
|
+
setup(e, { emit: n }) {
|
|
2716
|
+
const t = e, o = n, r = L(t.visible), a = Ze({
|
|
2677
2717
|
...t.filterValues
|
|
2678
|
-
}), l = (i) => i.key ?? String(i.dataIndex),
|
|
2718
|
+
}), l = (i) => i.key ?? String(i.dataIndex), s = (i) => {
|
|
2719
|
+
if (typeof i == "string")
|
|
2720
|
+
return i;
|
|
2721
|
+
if (i !== null && typeof i == "object") {
|
|
2722
|
+
const p = i.format;
|
|
2723
|
+
if (typeof p == "function")
|
|
2724
|
+
return p("YYYY-MM-DD");
|
|
2725
|
+
const b = i.toISOString;
|
|
2726
|
+
if (typeof b == "function")
|
|
2727
|
+
return b();
|
|
2728
|
+
}
|
|
2729
|
+
return String(i);
|
|
2730
|
+
}, h = (i, p) => {
|
|
2731
|
+
if (p !== void 0)
|
|
2732
|
+
return i.filterMode === q.DATE && Array.isArray(p) && p.length === 2 ? [[s(p[0]), s(p[1])]] : p;
|
|
2733
|
+
}, d = (i) => Array.isArray(i) ? i : i != null ? [i] : [], u = (i) => i == null ? !0 : Array.isArray(i) ? i.length === 0 : typeof i == "string" ? i.trim() === "" : !1, m = T(
|
|
2679
2734
|
() => t.columns.filter((i) => i.filterable)
|
|
2680
|
-
),
|
|
2681
|
-
(i) => !
|
|
2682
|
-
)),
|
|
2683
|
-
Object.keys(a).forEach((
|
|
2684
|
-
delete a[
|
|
2735
|
+
), S = T(() => Object.keys(a).some(
|
|
2736
|
+
(i) => !ye(a[i], t.filterValues[i])
|
|
2737
|
+
)), x = (i) => {
|
|
2738
|
+
Object.keys(a).forEach((p) => {
|
|
2739
|
+
delete a[p];
|
|
2685
2740
|
}), Object.assign(a, i);
|
|
2686
2741
|
};
|
|
2687
|
-
|
|
2742
|
+
$(
|
|
2688
2743
|
() => t.visible,
|
|
2689
2744
|
(i) => {
|
|
2690
|
-
r.value = i, i &&
|
|
2745
|
+
r.value = i, i && x(t.filterValues);
|
|
2691
2746
|
}
|
|
2692
|
-
),
|
|
2693
|
-
|
|
2694
|
-
}),
|
|
2747
|
+
), $(r, (i) => {
|
|
2748
|
+
o("update:visible", i);
|
|
2749
|
+
}), $(
|
|
2695
2750
|
() => t.filterValues,
|
|
2696
2751
|
(i) => {
|
|
2697
|
-
|
|
2752
|
+
x(i);
|
|
2698
2753
|
},
|
|
2699
2754
|
{
|
|
2700
2755
|
deep: !0
|
|
2701
2756
|
}
|
|
2702
2757
|
);
|
|
2703
|
-
const
|
|
2758
|
+
const f = () => {
|
|
2704
2759
|
const i = {
|
|
2705
2760
|
...t.filterValues
|
|
2706
2761
|
};
|
|
2707
|
-
Object.entries(a).forEach(([
|
|
2708
|
-
|
|
2709
|
-
|
|
2710
|
-
|
|
2762
|
+
Object.entries(a).forEach(([p, b]) => {
|
|
2763
|
+
const g = t.columns.find((V) => String(l(V)) === p), A = g ? h(g, b) : b;
|
|
2764
|
+
if (u(b)) {
|
|
2765
|
+
i[p] = null, o("filterApply", {
|
|
2766
|
+
key: p,
|
|
2711
2767
|
value: []
|
|
2712
2768
|
});
|
|
2713
2769
|
return;
|
|
2714
2770
|
}
|
|
2715
|
-
i[
|
|
2716
|
-
key:
|
|
2717
|
-
value:
|
|
2771
|
+
i[p] = A, o("filterApply", {
|
|
2772
|
+
key: p,
|
|
2773
|
+
value: d(A)
|
|
2718
2774
|
});
|
|
2719
|
-
}),
|
|
2720
|
-
},
|
|
2775
|
+
}), o("update:filterValues", i), r.value = !1;
|
|
2776
|
+
}, k = () => {
|
|
2721
2777
|
r.value = !1;
|
|
2722
2778
|
};
|
|
2723
|
-
return (i,
|
|
2724
|
-
const
|
|
2725
|
-
return
|
|
2779
|
+
return (i, p) => {
|
|
2780
|
+
const b = H("a-modal");
|
|
2781
|
+
return v(), B(b, {
|
|
2726
2782
|
visible: r.value,
|
|
2727
|
-
"onUpdate:visible":
|
|
2783
|
+
"onUpdate:visible": p[0] || (p[0] = (g) => r.value = g),
|
|
2728
2784
|
class: "efko-dataview",
|
|
2729
2785
|
title: "Фильтры",
|
|
2730
2786
|
"destroy-on-close": "",
|
|
2731
2787
|
"ok-text": "Применить",
|
|
2732
2788
|
"cancel-text": "Сбросить",
|
|
2733
|
-
"ok-button-props": { disabled: !
|
|
2734
|
-
onOk:
|
|
2735
|
-
onCancel:
|
|
2789
|
+
"ok-button-props": { disabled: !S.value },
|
|
2790
|
+
onOk: f,
|
|
2791
|
+
onCancel: k
|
|
2736
2792
|
}, {
|
|
2737
|
-
default:
|
|
2738
|
-
(
|
|
2739
|
-
key: l(
|
|
2793
|
+
default: w(() => [
|
|
2794
|
+
(v(!0), C(O, null, W(m.value, (g) => (v(), C("section", {
|
|
2795
|
+
key: l(g),
|
|
2740
2796
|
class: "mb-4 flex flex-col gap-2"
|
|
2741
2797
|
}, [
|
|
2742
|
-
|
|
2743
|
-
M(
|
|
2744
|
-
modelValue: a[l(
|
|
2745
|
-
"onUpdate:modelValue": (
|
|
2746
|
-
"filter-mode":
|
|
2747
|
-
"component-props":
|
|
2748
|
-
placeholder:
|
|
2798
|
+
R("span", nr, X(g.title), 1),
|
|
2799
|
+
M(_t, {
|
|
2800
|
+
modelValue: a[l(g)],
|
|
2801
|
+
"onUpdate:modelValue": (A) => a[l(g)] = A,
|
|
2802
|
+
"filter-mode": g.filterMode,
|
|
2803
|
+
"component-props": g.componentProps,
|
|
2804
|
+
placeholder: g.title
|
|
2749
2805
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "filter-mode", "component-props", "placeholder"])
|
|
2750
2806
|
]))), 128))
|
|
2751
2807
|
]),
|
|
@@ -2753,9 +2809,9 @@ const $t = /* @__PURE__ */ ce(Tn, [["render", Hn], ["__scopeId", "data-v-cfb3f12
|
|
|
2753
2809
|
}, 8, ["visible", "ok-button-props"]);
|
|
2754
2810
|
};
|
|
2755
2811
|
}
|
|
2756
|
-
}),
|
|
2757
|
-
var
|
|
2758
|
-
const
|
|
2812
|
+
}), rr = /* @__PURE__ */ ce(or, [["__scopeId", "data-v-4171d5f0"]]);
|
|
2813
|
+
var qe = /* @__PURE__ */ ((e) => (e.Table = "table", e.Grid = "grid", e))(qe || {}), Rt = /* @__PURE__ */ ((e) => (e.Grid = "grid", e.Row = "row", e))(Rt || {});
|
|
2814
|
+
const ar = { class: "efko-dataview" }, ir = { class: "flex items-center justify-between gap-2 mb-2" }, lr = { class: "flex items-center gap-1" }, Sr = /* @__PURE__ */ P({
|
|
2759
2815
|
__name: "DataView",
|
|
2760
2816
|
props: {
|
|
2761
2817
|
viewMode: {},
|
|
@@ -2772,74 +2828,75 @@ const or = { class: "efko-dataview" }, nr = { class: "flex items-center justify-
|
|
|
2772
2828
|
disableViewMode: { type: Boolean, default: !1 },
|
|
2773
2829
|
enableTableFilterDrawer: { type: Boolean, default: !1 },
|
|
2774
2830
|
disableColumnFilterDropdowns: { type: Boolean, default: !1 },
|
|
2775
|
-
useFilterModal: { type: Boolean, default: !1 }
|
|
2831
|
+
useFilterModal: { type: Boolean, default: !1 },
|
|
2832
|
+
multiColumnFilters: { type: Boolean, default: !0 }
|
|
2776
2833
|
},
|
|
2777
2834
|
emits: ["update:viewMode", "update:filterValues", "filterApply", "edit", "delete", "restore", "sortChange", "pageChange", "sizeChange"],
|
|
2778
|
-
setup(e, { emit:
|
|
2779
|
-
const t = e,
|
|
2835
|
+
setup(e, { emit: n }) {
|
|
2836
|
+
const t = e, o = n, r = L(t.viewMode || qe.Table), a = T(() => (r == null ? void 0 : r.value) === qe.Grid), l = L(Rt.Grid), s = L(
|
|
2780
2837
|
t.filterValues || {}
|
|
2781
|
-
),
|
|
2782
|
-
|
|
2783
|
-
}, u = (b,
|
|
2784
|
-
const
|
|
2785
|
-
if (
|
|
2786
|
-
if (Array.isArray(
|
|
2787
|
-
const
|
|
2788
|
-
|
|
2838
|
+
), h = L(null), d = (b) => {
|
|
2839
|
+
s.value = b, o("update:filterValues", b);
|
|
2840
|
+
}, u = (b, g, A) => {
|
|
2841
|
+
const V = { ...s.value };
|
|
2842
|
+
if (g !== void 0) {
|
|
2843
|
+
if (Array.isArray(g)) {
|
|
2844
|
+
const y = g.filter((c) => !ye(c, A));
|
|
2845
|
+
y.length === 0 ? V[b] = null : y.length === 1 && !Array.isArray(y[0]) ? V[b] = y[0] : V[b] = y, d(V);
|
|
2789
2846
|
return;
|
|
2790
2847
|
}
|
|
2791
|
-
|
|
2848
|
+
ye(g, A) && (V[b] = null, d(V));
|
|
2792
2849
|
}
|
|
2793
|
-
},
|
|
2794
|
-
|
|
2795
|
-
}, x =
|
|
2796
|
-
(b) =>
|
|
2797
|
-
).length : 0),
|
|
2798
|
-
b.forEach((
|
|
2799
|
-
const
|
|
2800
|
-
|
|
2801
|
-
}), t.showActionsColumn &&
|
|
2850
|
+
}, m = () => d({}), S = (b) => {
|
|
2851
|
+
o("filterApply", b);
|
|
2852
|
+
}, x = L(!1), f = L(!1), k = L({}), i = T(() => r.value === "table" ? Object.keys(k.value).filter(
|
|
2853
|
+
(b) => k.value[b] === !1
|
|
2854
|
+
).length : 0), p = (b) => {
|
|
2855
|
+
b.forEach((g) => {
|
|
2856
|
+
const A = g.key ?? String(g.dataIndex);
|
|
2857
|
+
k.value[A] === void 0 && (k.value[A] = !0);
|
|
2858
|
+
}), t.showActionsColumn && k.value.actions === void 0 && (k.value.actions = !0);
|
|
2802
2859
|
};
|
|
2803
|
-
return
|
|
2860
|
+
return $(
|
|
2804
2861
|
() => t.filterValues,
|
|
2805
2862
|
(b) => {
|
|
2806
|
-
|
|
2863
|
+
s.value = b || {};
|
|
2807
2864
|
}
|
|
2808
|
-
),
|
|
2865
|
+
), $(
|
|
2809
2866
|
() => t.viewMode,
|
|
2810
2867
|
(b) => {
|
|
2811
2868
|
b !== void 0 && (r.value = b);
|
|
2812
2869
|
}
|
|
2813
|
-
),
|
|
2814
|
-
|
|
2815
|
-
}), (b,
|
|
2816
|
-
const
|
|
2817
|
-
return
|
|
2818
|
-
|
|
2870
|
+
), $(() => t.columns, p), $(r, (b) => o("update:viewMode", b)), le(() => p(t.columns)), le(() => {
|
|
2871
|
+
h.value && Qe(h.value);
|
|
2872
|
+
}), (b, g) => {
|
|
2873
|
+
const A = H("Icon"), V = H("a-button"), y = H("a-badge");
|
|
2874
|
+
return v(), C("div", ar, [
|
|
2875
|
+
R("div", {
|
|
2819
2876
|
ref_key: "tagCloudContainer",
|
|
2820
|
-
ref:
|
|
2877
|
+
ref: h
|
|
2821
2878
|
}, [
|
|
2822
|
-
M(
|
|
2823
|
-
filters:
|
|
2879
|
+
M(oo, {
|
|
2880
|
+
filters: s.value,
|
|
2824
2881
|
"onUpdate:filters": d,
|
|
2825
2882
|
onRemove: u,
|
|
2826
|
-
onClear:
|
|
2883
|
+
onClear: m
|
|
2827
2884
|
}, null, 8, ["filters"])
|
|
2828
2885
|
], 512),
|
|
2829
|
-
a.value ? (
|
|
2830
|
-
|
|
2831
|
-
|
|
2832
|
-
M(
|
|
2886
|
+
a.value ? (v(), C(O, { key: 0 }, [
|
|
2887
|
+
R("div", ir, [
|
|
2888
|
+
R("div", lr, [
|
|
2889
|
+
M(y, {
|
|
2833
2890
|
dot: "",
|
|
2834
|
-
count:
|
|
2891
|
+
count: i.value
|
|
2835
2892
|
}, {
|
|
2836
|
-
default:
|
|
2837
|
-
M(
|
|
2893
|
+
default: w(() => [
|
|
2894
|
+
M(V, {
|
|
2838
2895
|
class: "flex items-center justify-center p-2",
|
|
2839
|
-
onClick:
|
|
2896
|
+
onClick: g[0] || (g[0] = (c) => f.value = !0)
|
|
2840
2897
|
}, {
|
|
2841
|
-
default:
|
|
2842
|
-
M(
|
|
2898
|
+
default: w(() => [
|
|
2899
|
+
M(A, {
|
|
2843
2900
|
name: "solar:settings-outline",
|
|
2844
2901
|
class: "text-lg"
|
|
2845
2902
|
})
|
|
@@ -2849,12 +2906,12 @@ const or = { class: "efko-dataview" }, nr = { class: "flex items-center justify-
|
|
|
2849
2906
|
]),
|
|
2850
2907
|
_: 1
|
|
2851
2908
|
}, 8, ["count"]),
|
|
2852
|
-
M(
|
|
2909
|
+
M(V, {
|
|
2853
2910
|
class: "flex items-center justify-center p-2",
|
|
2854
|
-
onClick:
|
|
2911
|
+
onClick: g[1] || (g[1] = (c) => x.value = !0)
|
|
2855
2912
|
}, {
|
|
2856
|
-
default:
|
|
2857
|
-
M(
|
|
2913
|
+
default: w(() => [
|
|
2914
|
+
M(A, {
|
|
2858
2915
|
name: "ant-design:filter-outlined",
|
|
2859
2916
|
class: "text-lg"
|
|
2860
2917
|
})
|
|
@@ -2862,10 +2919,10 @@ const or = { class: "efko-dataview" }, nr = { class: "flex items-center justify-
|
|
|
2862
2919
|
_: 1
|
|
2863
2920
|
})
|
|
2864
2921
|
]),
|
|
2865
|
-
|
|
2866
|
-
|
|
2922
|
+
z(b.$slots, "headerCardContainer"),
|
|
2923
|
+
z(b.$slots, "title")
|
|
2867
2924
|
]),
|
|
2868
|
-
a.value ? (
|
|
2925
|
+
a.value ? (v(), B(ko, {
|
|
2869
2926
|
key: 0,
|
|
2870
2927
|
loading: e.loading,
|
|
2871
2928
|
columns: e.columns,
|
|
@@ -2876,107 +2933,108 @@ const or = { class: "efko-dataview" }, nr = { class: "flex items-center justify-
|
|
|
2876
2933
|
"show-actions-column": e.showActionsColumn,
|
|
2877
2934
|
pagination: e.pagination,
|
|
2878
2935
|
meta: e.meta,
|
|
2879
|
-
onRestore:
|
|
2880
|
-
onEdit:
|
|
2881
|
-
onDelete:
|
|
2882
|
-
onPageChange:
|
|
2883
|
-
onSizeChange:
|
|
2884
|
-
},
|
|
2936
|
+
onRestore: g[2] || (g[2] = (c) => o("restore", c)),
|
|
2937
|
+
onEdit: g[3] || (g[3] = (c) => o("edit", c)),
|
|
2938
|
+
onDelete: g[4] || (g[4] = (c) => o("delete", c)),
|
|
2939
|
+
onPageChange: g[5] || (g[5] = (c) => o("pageChange", c)),
|
|
2940
|
+
onSizeChange: g[6] || (g[6] = (c, E) => o("sizeChange", c, E))
|
|
2941
|
+
}, Ie({ _: 2 }, [
|
|
2885
2942
|
b.$slots.titleCard ? {
|
|
2886
2943
|
name: "titleCard",
|
|
2887
|
-
fn:
|
|
2888
|
-
|
|
2944
|
+
fn: w((c) => [
|
|
2945
|
+
z(b.$slots, "titleCard", pe(ge(c)))
|
|
2889
2946
|
]),
|
|
2890
2947
|
key: "0"
|
|
2891
2948
|
} : void 0,
|
|
2892
2949
|
b.$slots.body ? {
|
|
2893
2950
|
name: "bodyCard",
|
|
2894
|
-
fn:
|
|
2895
|
-
|
|
2951
|
+
fn: w((c) => [
|
|
2952
|
+
z(b.$slots, "body", pe(ge(c)))
|
|
2896
2953
|
]),
|
|
2897
2954
|
key: "1"
|
|
2898
2955
|
} : void 0,
|
|
2899
2956
|
b.$slots.footer ? {
|
|
2900
2957
|
name: "footerCard",
|
|
2901
|
-
fn:
|
|
2902
|
-
|
|
2958
|
+
fn: w((c) => [
|
|
2959
|
+
z(b.$slots, "footer", pe(ge(c)))
|
|
2903
2960
|
]),
|
|
2904
2961
|
key: "2"
|
|
2905
2962
|
} : void 0
|
|
2906
|
-
]), 1032, ["loading", "columns", "data-source", "card-layout", "can-edit", "edit-action", "show-actions-column", "pagination", "meta"])) :
|
|
2907
|
-
], 64)) : (
|
|
2963
|
+
]), 1032, ["loading", "columns", "data-source", "card-layout", "can-edit", "edit-action", "show-actions-column", "pagination", "meta"])) : U("", !0)
|
|
2964
|
+
], 64)) : (v(), B(qo, {
|
|
2908
2965
|
key: 1,
|
|
2909
2966
|
loading: e.loading,
|
|
2910
2967
|
pagination: e.pagination,
|
|
2911
2968
|
columns: e.columns,
|
|
2912
2969
|
"data-source": e.dataSource,
|
|
2913
|
-
"filter-values":
|
|
2970
|
+
"filter-values": s.value,
|
|
2914
2971
|
meta: e.meta,
|
|
2915
2972
|
"can-edit": e.canEdit,
|
|
2916
2973
|
"edit-action": e.editAction,
|
|
2917
2974
|
"delete-action": e.deleteAction,
|
|
2918
2975
|
"show-actions-column": e.showActionsColumn,
|
|
2919
|
-
"columns-visibility":
|
|
2976
|
+
"columns-visibility": k.value,
|
|
2920
2977
|
"disable-column-filter-dropdowns": t.disableColumnFilterDropdowns === !0,
|
|
2921
2978
|
"show-filter-button": t.enableTableFilterDrawer === !0,
|
|
2922
|
-
|
|
2923
|
-
|
|
2979
|
+
"multi-column-filters": t.multiColumnFilters,
|
|
2980
|
+
onOpenColumnDrawer: g[7] || (g[7] = (c) => f.value = !0),
|
|
2981
|
+
onOpenFilterDrawer: g[8] || (g[8] = (c) => x.value = !0),
|
|
2924
2982
|
"onUpdate:filterValues": d,
|
|
2925
|
-
onFilterApply:
|
|
2926
|
-
onRestore:
|
|
2927
|
-
onEdit:
|
|
2928
|
-
onDelete:
|
|
2929
|
-
onSortChange:
|
|
2930
|
-
onPageChange:
|
|
2931
|
-
onSizeChange:
|
|
2983
|
+
onFilterApply: g[9] || (g[9] = (c) => o("filterApply", c)),
|
|
2984
|
+
onRestore: g[10] || (g[10] = (c) => o("restore", c)),
|
|
2985
|
+
onEdit: g[11] || (g[11] = (c) => o("edit", c)),
|
|
2986
|
+
onDelete: g[12] || (g[12] = (c) => o("delete", c)),
|
|
2987
|
+
onSortChange: g[13] || (g[13] = (c) => o("sortChange", c)),
|
|
2988
|
+
onPageChange: g[14] || (g[14] = (c) => o("pageChange", c)),
|
|
2989
|
+
onSizeChange: g[15] || (g[15] = (c, E) => o("sizeChange", c, E))
|
|
2932
2990
|
}, {
|
|
2933
|
-
title:
|
|
2934
|
-
|
|
2991
|
+
title: w(() => [
|
|
2992
|
+
z(b.$slots, "title")
|
|
2935
2993
|
]),
|
|
2936
|
-
bodyCell:
|
|
2937
|
-
|
|
2994
|
+
bodyCell: w((c) => [
|
|
2995
|
+
z(b.$slots, "bodyCell", pe(ge(c)))
|
|
2938
2996
|
]),
|
|
2939
|
-
actionColumn:
|
|
2940
|
-
|
|
2997
|
+
actionColumn: w((c) => [
|
|
2998
|
+
z(b.$slots, "actionColumn", pe(ge(c)))
|
|
2941
2999
|
]),
|
|
2942
3000
|
_: 3
|
|
2943
|
-
}, 8, ["loading", "pagination", "columns", "data-source", "filter-values", "meta", "can-edit", "edit-action", "delete-action", "show-actions-column", "columns-visibility", "disable-column-filter-dropdowns", "show-filter-button"])),
|
|
2944
|
-
|
|
3001
|
+
}, 8, ["loading", "pagination", "columns", "data-source", "filter-values", "meta", "can-edit", "edit-action", "delete-action", "show-actions-column", "columns-visibility", "disable-column-filter-dropdowns", "show-filter-button", "multi-column-filters"])),
|
|
3002
|
+
z(b.$slots, "filtersDrawer", {
|
|
2945
3003
|
visible: x.value,
|
|
2946
|
-
setVisible: (
|
|
2947
|
-
x.value =
|
|
3004
|
+
setVisible: (c) => {
|
|
3005
|
+
x.value = c;
|
|
2948
3006
|
},
|
|
2949
|
-
filters:
|
|
3007
|
+
filters: s.value,
|
|
2950
3008
|
updateFilters: d,
|
|
2951
3009
|
emitFilterApply: S
|
|
2952
3010
|
}, () => [
|
|
2953
|
-
t.useFilterModal === !0 ? (
|
|
3011
|
+
t.useFilterModal === !0 ? (v(), B(rr, {
|
|
2954
3012
|
key: 0,
|
|
2955
3013
|
visible: x.value,
|
|
2956
|
-
"onUpdate:visible":
|
|
3014
|
+
"onUpdate:visible": g[16] || (g[16] = (c) => x.value = c),
|
|
2957
3015
|
columns: e.columns,
|
|
2958
|
-
"filter-values":
|
|
3016
|
+
"filter-values": s.value,
|
|
2959
3017
|
"onUpdate:filterValues": d,
|
|
2960
|
-
onFilterApply:
|
|
2961
|
-
}, null, 8, ["visible", "columns", "filter-values"])) : (
|
|
3018
|
+
onFilterApply: g[17] || (g[17] = (c) => o("filterApply", c))
|
|
3019
|
+
}, null, 8, ["visible", "columns", "filter-values"])) : (v(), B(tr, {
|
|
2962
3020
|
key: 1,
|
|
2963
3021
|
visible: x.value,
|
|
2964
|
-
"onUpdate:visible":
|
|
3022
|
+
"onUpdate:visible": g[18] || (g[18] = (c) => x.value = c),
|
|
2965
3023
|
columns: e.columns,
|
|
2966
|
-
"filter-values":
|
|
3024
|
+
"filter-values": s.value,
|
|
2967
3025
|
"onUpdate:filterValues": d,
|
|
2968
|
-
onFilterApply:
|
|
3026
|
+
onFilterApply: g[19] || (g[19] = (c) => o("filterApply", c))
|
|
2969
3027
|
}, null, 8, ["visible", "columns", "filter-values"]))
|
|
2970
3028
|
]),
|
|
2971
|
-
M(
|
|
2972
|
-
visible:
|
|
2973
|
-
"onUpdate:visible":
|
|
2974
|
-
"model-value":
|
|
2975
|
-
"onUpdate:modelValue":
|
|
3029
|
+
M(Zo, {
|
|
3030
|
+
visible: f.value,
|
|
3031
|
+
"onUpdate:visible": g[20] || (g[20] = (c) => f.value = c),
|
|
3032
|
+
"model-value": k.value,
|
|
3033
|
+
"onUpdate:modelValue": g[21] || (g[21] = (c) => k.value = c),
|
|
2976
3034
|
"view-mode": r.value,
|
|
2977
|
-
"onUpdate:viewMode":
|
|
3035
|
+
"onUpdate:viewMode": g[22] || (g[22] = (c) => r.value = c),
|
|
2978
3036
|
"card-layout": l.value,
|
|
2979
|
-
"onUpdate:cardLayout":
|
|
3037
|
+
"onUpdate:cardLayout": g[23] || (g[23] = (c) => l.value = c),
|
|
2980
3038
|
columns: e.columns,
|
|
2981
3039
|
"show-actions-column": e.showActionsColumn,
|
|
2982
3040
|
"disable-view-mode": e.disableViewMode
|
|
@@ -2984,7 +3042,7 @@ const or = { class: "efko-dataview" }, nr = { class: "flex items-center justify-
|
|
|
2984
3042
|
]);
|
|
2985
3043
|
};
|
|
2986
3044
|
}
|
|
2987
|
-
}),
|
|
3045
|
+
}), Ar = /* @__PURE__ */ P({
|
|
2988
3046
|
__name: "LazyLoadContainer",
|
|
2989
3047
|
props: {
|
|
2990
3048
|
onIntersect: {},
|
|
@@ -2993,52 +3051,52 @@ const or = { class: "efko-dataview" }, nr = { class: "flex items-center justify-
|
|
|
2993
3051
|
rootMargin: { default: "0px" }
|
|
2994
3052
|
},
|
|
2995
3053
|
setup(e) {
|
|
2996
|
-
const
|
|
2997
|
-
let
|
|
3054
|
+
const n = e, t = L(null);
|
|
3055
|
+
let o = null;
|
|
2998
3056
|
const r = (a) => {
|
|
2999
|
-
a[0].isIntersecting &&
|
|
3057
|
+
a[0].isIntersecting && n.onIntersect && (n.onIntersect(), n.once && o && o.disconnect());
|
|
3000
3058
|
};
|
|
3001
3059
|
return le(() => {
|
|
3002
|
-
|
|
3003
|
-
threshold:
|
|
3004
|
-
rootMargin:
|
|
3005
|
-
}), t.value &&
|
|
3006
|
-
}),
|
|
3007
|
-
|
|
3008
|
-
}), (a, l) => (
|
|
3060
|
+
o = new IntersectionObserver(r, {
|
|
3061
|
+
threshold: n.threshold,
|
|
3062
|
+
rootMargin: n.rootMargin
|
|
3063
|
+
}), t.value && o.observe(t.value);
|
|
3064
|
+
}), Ke(() => {
|
|
3065
|
+
o == null || o.disconnect();
|
|
3066
|
+
}), (a, l) => (v(), C("div", {
|
|
3009
3067
|
ref_key: "container",
|
|
3010
3068
|
ref: t
|
|
3011
3069
|
}, [
|
|
3012
|
-
|
|
3070
|
+
z(a.$slots, "default")
|
|
3013
3071
|
], 512));
|
|
3014
3072
|
}
|
|
3015
3073
|
});
|
|
3016
3074
|
export {
|
|
3017
|
-
|
|
3018
|
-
|
|
3019
|
-
|
|
3020
|
-
|
|
3021
|
-
|
|
3022
|
-
|
|
3023
|
-
|
|
3024
|
-
|
|
3025
|
-
|
|
3026
|
-
|
|
3027
|
-
|
|
3028
|
-
|
|
3029
|
-
|
|
3030
|
-
|
|
3031
|
-
|
|
3032
|
-
|
|
3033
|
-
|
|
3034
|
-
|
|
3035
|
-
|
|
3036
|
-
|
|
3037
|
-
|
|
3038
|
-
|
|
3039
|
-
|
|
3040
|
-
|
|
3041
|
-
|
|
3042
|
-
|
|
3075
|
+
tr as CardFiltersDrawer,
|
|
3076
|
+
rr as CardFiltersModal,
|
|
3077
|
+
ko as CardGrid,
|
|
3078
|
+
Rt as CardLayout,
|
|
3079
|
+
Zo as ColumnSettingsDrawer,
|
|
3080
|
+
yr as DEFAULT_PAGE_NUMBER,
|
|
3081
|
+
br as DEFAULT_PAGE_SIZE,
|
|
3082
|
+
qo as DataTable,
|
|
3083
|
+
Sr as DataView,
|
|
3084
|
+
q as FilterMode,
|
|
3085
|
+
Ar as LazyLoadContainer,
|
|
3086
|
+
So as LazyLoadTrigger,
|
|
3087
|
+
mr as PAGE_SIZE_EXTRA_LARGE,
|
|
3088
|
+
hr as PAGE_SIZE_LARGE,
|
|
3089
|
+
gr as PAGE_SIZE_MEDIUM,
|
|
3090
|
+
xr as PAGE_SIZE_OPTIONS,
|
|
3091
|
+
Mo as PAGE_SIZE_SMALL,
|
|
3092
|
+
vr as PAGE_SIZE_ULTRA,
|
|
3093
|
+
Eo as PageSizes,
|
|
3094
|
+
To as SkipSizes,
|
|
3095
|
+
Ho as SortOrder,
|
|
3096
|
+
Uo as TableBodyCell,
|
|
3097
|
+
Io as TableDefaults,
|
|
3098
|
+
We as TableSortOrder,
|
|
3099
|
+
qe as ViewMode,
|
|
3100
|
+
Sr as default
|
|
3043
3101
|
};
|
|
3044
3102
|
//# sourceMappingURL=data-view.es.js.map
|