@topvisor/ui 1.0.42-dev.4 → 1.0.42-policy.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/formsExt/policy/policy.vue.d.ts +18 -1
- package/components/formsExt/policy/types.d.ts +17 -3
- package/formsExt/formsExt.amd.js +1 -1
- package/formsExt/formsExt.amd.js.map +1 -1
- package/formsExt/formsExt.js +114 -112
- package/formsExt/formsExt.js.map +1 -1
- package/package.json +4 -1
- package/popup/popup.amd.js +1 -1
- package/popup/popup.amd.js.map +1 -1
- package/popup/popup.js +114 -114
- package/popup/popup.js.map +1 -1
package/formsExt/formsExt.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Core as x } from "../core/app.js";
|
|
2
|
-
import { defineComponent as L, ref as
|
|
2
|
+
import { defineComponent as L, ref as B, computed as P, createElementBlock as y, openBlock as p, normalizeClass as I, createCommentVNode as A, createElementVNode as _, toDisplayString as $, createVNode as O, withKeys as G, withModifiers as N, createBlock as w, createSlots as U, withCtx as V, createTextVNode as S, watch as E, toRef as D, mergeProps as R, mergeModels as J, useModel as Y, Fragment as z, renderList as F, withDirectives as q, vModelRadio as te, resolveDirective as oe, unref as v, renderSlot as W, resolveDynamicComponent as le } from "vue";
|
|
3
3
|
import { w as se, _ as X, f as ae, d as re, u as ne, C as Q, x as ie, g as ue } from "../.chunks/forms-DC7ffuv2.es.js";
|
|
4
4
|
import { TopPopup as de, TopPopupListItem as H, TopPopupWidgetInput as pe } from "../popup/popup.js";
|
|
5
5
|
import { invertKeyboardLayout as ce } from "../utils/keyboard.js";
|
|
@@ -32,29 +32,29 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
32
32
|
},
|
|
33
33
|
emits: ["submit", "close", "clickOnTitle"],
|
|
34
34
|
setup(l, { emit: t }) {
|
|
35
|
-
const s = l, o = t,
|
|
36
|
-
o("submit", u),
|
|
35
|
+
const s = l, o = t, d = B(s.defaultValue), a = B(s.isFocused), r = P(() => d.value !== s.defaultValue), c = (u) => {
|
|
36
|
+
o("submit", u), d.value = s.defaultValue;
|
|
37
37
|
}, f = () => {
|
|
38
38
|
if (s.forceShowCloseBtn && !r.value) {
|
|
39
39
|
o("close");
|
|
40
40
|
return;
|
|
41
41
|
}
|
|
42
|
-
|
|
43
|
-
},
|
|
42
|
+
d.value = s.defaultValue;
|
|
43
|
+
}, k = () => {
|
|
44
44
|
s.attachToKeyboard && o("clickOnTitle");
|
|
45
45
|
};
|
|
46
|
-
return (u, b) => (
|
|
46
|
+
return (u, b) => (p(), y("div", {
|
|
47
47
|
class: I({
|
|
48
48
|
"top-editArea": !0,
|
|
49
49
|
"top-editArea-attachedToKeyboard": u.attachToKeyboard
|
|
50
50
|
})
|
|
51
51
|
}, [
|
|
52
|
-
u.title ? (
|
|
52
|
+
u.title ? (p(), y("div", {
|
|
53
53
|
key: 0,
|
|
54
54
|
class: "top-editArea_title",
|
|
55
|
-
onClick: b[0] || (b[0] = (i) =>
|
|
55
|
+
onClick: b[0] || (b[0] = (i) => k())
|
|
56
56
|
}, $(u.title), 1)) : A("", !0),
|
|
57
|
-
|
|
57
|
+
_("div", {
|
|
58
58
|
class: I({
|
|
59
59
|
"top-editArea_form": !0,
|
|
60
60
|
"top-forms-focusable": !0,
|
|
@@ -63,9 +63,9 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
63
63
|
"top-focus": a.value
|
|
64
64
|
})
|
|
65
65
|
}, [
|
|
66
|
-
|
|
67
|
-
modelValue:
|
|
68
|
-
"onUpdate:modelValue": b[1] || (b[1] = (i) =>
|
|
66
|
+
O(se, {
|
|
67
|
+
modelValue: d.value,
|
|
68
|
+
"onUpdate:modelValue": b[1] || (b[1] = (i) => d.value = i),
|
|
69
69
|
name: u.name,
|
|
70
70
|
placeholder: u.placeholder,
|
|
71
71
|
rows: u.rows,
|
|
@@ -80,11 +80,11 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
80
80
|
onBlur: b[3] || (b[3] = () => a.value = !1),
|
|
81
81
|
onKeyup: [
|
|
82
82
|
G(f, ["esc"]),
|
|
83
|
-
b[4] || (b[4] = G(N((i) => c(
|
|
83
|
+
b[4] || (b[4] = G(N((i) => c(d.value), ["ctrl"]), ["enter"]))
|
|
84
84
|
]
|
|
85
85
|
}, null, 8, ["modelValue", "name", "placeholder", "rows", "minHeight", "expandable", "disabled", "readonly", "isError", "hint"]),
|
|
86
|
-
|
|
87
|
-
r.value || u.forceShowCloseBtn ? (
|
|
86
|
+
_("div", me, [
|
|
87
|
+
r.value || u.forceShowCloseBtn ? (p(), w(X, {
|
|
88
88
|
key: 0,
|
|
89
89
|
icon: u.$core.state.isMobile ? "" : "",
|
|
90
90
|
class: "top-editArea_button",
|
|
@@ -100,11 +100,11 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
100
100
|
key: "0"
|
|
101
101
|
}
|
|
102
102
|
]), 1032, ["icon"])) : A("", !0),
|
|
103
|
-
r.value ? (
|
|
103
|
+
r.value ? (p(), w(X, {
|
|
104
104
|
key: 1,
|
|
105
105
|
class: "top-editArea_button",
|
|
106
106
|
icon: u.$core.state.isMobile ? "" : "",
|
|
107
|
-
onClick: b[5] || (b[5] = (i) => c(
|
|
107
|
+
onClick: b[5] || (b[5] = (i) => c(d.value))
|
|
108
108
|
}, U({ _: 2 }, [
|
|
109
109
|
u.$core.state.isMobile ? void 0 : {
|
|
110
110
|
name: "default",
|
|
@@ -127,21 +127,21 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
127
127
|
},
|
|
128
128
|
emits: ["update:modelValue"],
|
|
129
129
|
setup(l, { emit: t }) {
|
|
130
|
-
const s = l, o =
|
|
131
|
-
E(
|
|
130
|
+
const s = l, o = B(s.modelValue);
|
|
131
|
+
E(D(s.modelValue), () => {
|
|
132
132
|
o.value = s.modelValue;
|
|
133
133
|
});
|
|
134
|
-
const
|
|
135
|
-
|
|
134
|
+
const d = t, a = () => {
|
|
135
|
+
d("update:modelValue", o.value);
|
|
136
136
|
};
|
|
137
|
-
return (r, c) => (
|
|
138
|
-
|
|
137
|
+
return (r, c) => (p(), y("div", ye, [
|
|
138
|
+
O(ae, R(r.input, {
|
|
139
139
|
onKeydownCapture: c[0] || (c[0] = G(N((f) => o.value = r.modelValue, ["stop"]), ["esc"])),
|
|
140
140
|
onKeydown: G(N(a, ["stop"]), ["enter"]),
|
|
141
141
|
modelValue: o.value,
|
|
142
142
|
"onUpdate:modelValue": c[1] || (c[1] = (f) => o.value = f)
|
|
143
143
|
}), null, 16, ["onKeydown", "modelValue"]),
|
|
144
|
-
o.value !== r.modelValue ? (
|
|
144
|
+
o.value !== r.modelValue ? (p(), w(X, R({
|
|
145
145
|
key: 0,
|
|
146
146
|
icon: "",
|
|
147
147
|
styling: "soft"
|
|
@@ -151,9 +151,9 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
151
151
|
}), be = ["data-top-icon", "onClick"], ge = {
|
|
152
152
|
key: 0,
|
|
153
153
|
class: "top-radioGroup_circle"
|
|
154
|
-
},
|
|
154
|
+
}, Te = ["value", "disabled"], ke = /* @__PURE__ */ L({
|
|
155
155
|
__name: "radioGroup",
|
|
156
|
-
props: /* @__PURE__ */
|
|
156
|
+
props: /* @__PURE__ */ J({
|
|
157
157
|
modelValue: {},
|
|
158
158
|
radiosProps: {},
|
|
159
159
|
showIndicator: { type: Boolean },
|
|
@@ -167,13 +167,13 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
167
167
|
}),
|
|
168
168
|
emits: ["update:modelValue"],
|
|
169
169
|
setup(l) {
|
|
170
|
-
const t =
|
|
170
|
+
const t = Y(l, "modelValue"), s = l, o = B(null);
|
|
171
171
|
E(t, () => {
|
|
172
|
-
var a, r, c, f,
|
|
173
|
-
(a = s.radiosProps) != null && a.some((u) => u.value === t.value) || (t.value = ((c = (r = s.radiosProps) == null ? void 0 : r[0]) == null ? void 0 : c.value) ?? ""), (
|
|
172
|
+
var a, r, c, f, k;
|
|
173
|
+
(a = s.radiosProps) != null && a.some((u) => u.value === t.value) || (t.value = ((c = (r = s.radiosProps) == null ? void 0 : r[0]) == null ? void 0 : c.value) ?? ""), (k = (f = o.value) == null ? void 0 : f.querySelector(".radioGroup_item-selected")) == null || k.scrollIntoView();
|
|
174
174
|
}, { immediate: !0 });
|
|
175
|
-
const
|
|
176
|
-
return (a, r) => (
|
|
175
|
+
const d = "radioGroup-" + Math.random();
|
|
176
|
+
return (a, r) => (p(), y("div", {
|
|
177
177
|
ref_key: "elRef",
|
|
178
178
|
ref: o,
|
|
179
179
|
class: I({
|
|
@@ -183,7 +183,7 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
183
183
|
"top-error": a.isError
|
|
184
184
|
})
|
|
185
185
|
}, [
|
|
186
|
-
(
|
|
186
|
+
(p(!0), y(z, null, F(a.radiosProps, (c) => (p(), y("label", {
|
|
187
187
|
class: I({
|
|
188
188
|
"top-radioGroup_item-selected": c.value === t.value,
|
|
189
189
|
"top-radioGroup_item": !0,
|
|
@@ -194,17 +194,17 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
194
194
|
onClick: (f) => t.value = c.value
|
|
195
195
|
}, [
|
|
196
196
|
S($(c.title) + " ", 1),
|
|
197
|
-
a.showIndicator ? (
|
|
198
|
-
q(
|
|
197
|
+
a.showIndicator ? (p(), y("span", ge)) : A("", !0),
|
|
198
|
+
q(_("input", {
|
|
199
199
|
"onUpdate:modelValue": r[0] || (r[0] = (f) => t.value = f),
|
|
200
|
-
name:
|
|
200
|
+
name: d,
|
|
201
201
|
type: "radio",
|
|
202
202
|
class: I({
|
|
203
203
|
"top-unvisible": !0
|
|
204
204
|
}),
|
|
205
205
|
value: c.value,
|
|
206
206
|
disabled: c.disabled
|
|
207
|
-
}, null, 8,
|
|
207
|
+
}, null, 8, Te), [
|
|
208
208
|
[te, t.value]
|
|
209
209
|
])
|
|
210
210
|
], 10, be))), 256))
|
|
@@ -212,7 +212,7 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
212
212
|
}
|
|
213
213
|
}), Ae = ["data-top-icon"], Ce = ["value", "checked", "disabled", "onChange"], $e = /* @__PURE__ */ L({
|
|
214
214
|
__name: "checkboxGroup",
|
|
215
|
-
props: /* @__PURE__ */
|
|
215
|
+
props: /* @__PURE__ */ J({
|
|
216
216
|
modelValue: {},
|
|
217
217
|
items: {},
|
|
218
218
|
size: { default: "s" },
|
|
@@ -226,11 +226,11 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
226
226
|
}),
|
|
227
227
|
emits: ["update:modelValue"],
|
|
228
228
|
setup(l) {
|
|
229
|
-
const t =
|
|
230
|
-
const
|
|
231
|
-
a === -1 ?
|
|
229
|
+
const t = Y(l, "modelValue"), s = (o) => {
|
|
230
|
+
const d = [...t.value], a = d.indexOf(o);
|
|
231
|
+
a === -1 ? d.push(o) : d.splice(a, 1), t.value = d;
|
|
232
232
|
};
|
|
233
|
-
return (o,
|
|
233
|
+
return (o, d) => (p(), y("div", {
|
|
234
234
|
class: I({
|
|
235
235
|
"top-checkboxGroup": !0,
|
|
236
236
|
["top-checkboxGroup-" + o.styling]: !0,
|
|
@@ -239,7 +239,7 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
239
239
|
"top-error": o.isError
|
|
240
240
|
})
|
|
241
241
|
}, [
|
|
242
|
-
(
|
|
242
|
+
(p(!0), y(z, null, F(o.items, (a) => (p(), y("label", {
|
|
243
243
|
key: a.id,
|
|
244
244
|
class: I({
|
|
245
245
|
"top-checkboxGroup_item": !0,
|
|
@@ -249,7 +249,7 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
249
249
|
}),
|
|
250
250
|
"data-top-icon": a.icon
|
|
251
251
|
}, [
|
|
252
|
-
|
|
252
|
+
_("input", {
|
|
253
253
|
type: "checkbox",
|
|
254
254
|
class: "top-unvisible",
|
|
255
255
|
value: a.id,
|
|
@@ -269,9 +269,9 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
269
269
|
},
|
|
270
270
|
emits: ["delete"],
|
|
271
271
|
setup(l) {
|
|
272
|
-
return (t, s) => (
|
|
272
|
+
return (t, s) => (p(), y("div", Ve, [
|
|
273
273
|
S($(t.name) + " ", 1),
|
|
274
|
-
|
|
274
|
+
_("span", {
|
|
275
275
|
class: "top-selector2_itemMultiDelete",
|
|
276
276
|
"data-top-icon": "",
|
|
277
277
|
onClick: s[0] || (s[0] = (o) => t.$emit("delete", t.id)),
|
|
@@ -281,7 +281,7 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
281
281
|
]));
|
|
282
282
|
}
|
|
283
283
|
}), Ie = (l, t, s) => {
|
|
284
|
-
const o =
|
|
284
|
+
const o = B([]), d = B(!1);
|
|
285
285
|
let a = "", r;
|
|
286
286
|
l && !l.params.limit && (l.params.limit = 100);
|
|
287
287
|
const c = async () => {
|
|
@@ -289,7 +289,7 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
289
289
|
let i, C;
|
|
290
290
|
if (s && (l.cache ??= /* @__PURE__ */ new Map(), C = JSON.stringify(l.params), i = l.cache.get(C), i))
|
|
291
291
|
return i;
|
|
292
|
-
if (
|
|
292
|
+
if (d.value = !0, i = await l.call(), d.value = !1, i.errors) return;
|
|
293
293
|
if (!Array.isArray(i.result)) {
|
|
294
294
|
console.warn("В result ожидался массив");
|
|
295
295
|
return;
|
|
@@ -305,8 +305,8 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
305
305
|
l.params.offset = 0, l.params.search = a;
|
|
306
306
|
const i = await c();
|
|
307
307
|
i && (r = i.nextOffset, o.value = i.result);
|
|
308
|
-
},
|
|
309
|
-
if (!l || !r ||
|
|
308
|
+
}, k = async () => {
|
|
309
|
+
if (!l || !r || d.value) return;
|
|
310
310
|
l.params.offset = r, l.params.search = a;
|
|
311
311
|
const i = await c();
|
|
312
312
|
i && (r = i.nextOffset, o.value = o.value.concat(i.result));
|
|
@@ -314,29 +314,29 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
314
314
|
return {
|
|
315
315
|
apiRequest: l,
|
|
316
316
|
items: o,
|
|
317
|
-
isLoading:
|
|
318
|
-
loadAppend:
|
|
317
|
+
isLoading: d,
|
|
318
|
+
loadAppend: k,
|
|
319
319
|
setSearchTextAndLoad: (i, C = !0) => {
|
|
320
320
|
l && (i.length < t || i === a && o.value.length || (a = i, C ? u() : f()));
|
|
321
321
|
}
|
|
322
322
|
};
|
|
323
|
-
},
|
|
324
|
-
const f =
|
|
325
|
-
id:
|
|
323
|
+
}, Be = 0, Z = (l, t, s = !0) => s && t.id === null ? Array.isArray(l) ? l.some((o) => o.id === t.id && o.name === t.name) : t.name === l.name : Array.isArray(l) ? l.some((o) => o.id === t.id) : t.id === l.id, _e = (l, t, s, o, d, a, r, c) => {
|
|
324
|
+
const f = B(""), k = {
|
|
325
|
+
id: Be,
|
|
326
326
|
name: ne().Common.All
|
|
327
327
|
}, u = () => {
|
|
328
328
|
f.value = "", c.items.value = [];
|
|
329
329
|
}, b = () => !(!c.apiRequest || a.value !== "inline" || f.value.length >= r), i = P(() => {
|
|
330
330
|
var e;
|
|
331
331
|
const h = [];
|
|
332
|
-
return !s && o.value && h.push(
|
|
332
|
+
return !s && o.value && h.push(k), (e = t.value) == null || e.forEach((n) => h.push({ ...n })), h;
|
|
333
333
|
}), C = P(() => {
|
|
334
334
|
const h = f.value.toLowerCase(), e = ce(h);
|
|
335
335
|
let n = [];
|
|
336
336
|
return i.value.forEach((g) => {
|
|
337
337
|
const m = g.name.toLowerCase();
|
|
338
338
|
(g.id === Number(h) || m.includes(h) || m.includes(e)) && (m === h || m === e ? n.unshift(g) : n.push(g));
|
|
339
|
-
}), n.push(...c.items.value),
|
|
339
|
+
}), n.push(...c.items.value), d.value && f.value && (!n.length || n[0].name.toLowerCase() !== h) && n.push({
|
|
340
340
|
id: null,
|
|
341
341
|
name: f.value
|
|
342
342
|
}), s && (n = n.filter((g) => !Z(l.value, g))), n;
|
|
@@ -371,7 +371,7 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
371
371
|
class: "top-selector2_placeholder top-ellipsis"
|
|
372
372
|
}, Pe = /* @__PURE__ */ L({
|
|
373
373
|
__name: "selector2",
|
|
374
|
-
props: /* @__PURE__ */
|
|
374
|
+
props: /* @__PURE__ */ J({
|
|
375
375
|
modelValue: {},
|
|
376
376
|
items: { default: () => [] },
|
|
377
377
|
title: {},
|
|
@@ -396,25 +396,25 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
396
396
|
}),
|
|
397
397
|
emits: ["update:modelValue"],
|
|
398
398
|
setup(l) {
|
|
399
|
-
const t = l, s =
|
|
400
|
-
let
|
|
401
|
-
o.value === "inline" && t.minLength && (
|
|
402
|
-
const a = Ie(t.apiRequest,
|
|
399
|
+
const t = l, s = Y(l, "modelValue"), o = P(() => t.searchType === "inline" && t.multiselect || t.searchType === "inline" && Q.state.isMobile ? "popup" : t.searchType);
|
|
400
|
+
let d = 0;
|
|
401
|
+
o.value === "inline" && t.minLength && (d = t.minLength);
|
|
402
|
+
const a = Ie(t.apiRequest, d, t.useCache), r = _e(
|
|
403
403
|
s,
|
|
404
|
-
|
|
404
|
+
D(t, "items"),
|
|
405
405
|
t.multiselect,
|
|
406
|
-
|
|
407
|
-
|
|
406
|
+
D(t, "appendAllValue"),
|
|
407
|
+
D(t, "appendSearchToResult"),
|
|
408
408
|
o,
|
|
409
|
-
|
|
409
|
+
d,
|
|
410
410
|
a
|
|
411
|
-
), c = P(() => t.buttonProps ? "TopButton" : o.value === "inline" ? "TopInput" : "div"), f =
|
|
411
|
+
), c = P(() => t.buttonProps ? "TopButton" : o.value === "inline" ? "TopInput" : "div"), f = B(null), k = () => {
|
|
412
412
|
var e;
|
|
413
413
|
return (e = f.value) == null ? void 0 : e.popup;
|
|
414
414
|
};
|
|
415
415
|
a.apiRequest && E(r.searchText, () => {
|
|
416
416
|
var e;
|
|
417
|
-
a.setSearchTextAndLoad(r.searchText.value), o.value === "inline" && r.genIsShort() && ((e =
|
|
417
|
+
a.setSearchTextAndLoad(r.searchText.value), o.value === "inline" && r.genIsShort() && ((e = k()) == null || e.close());
|
|
418
418
|
}), E(s, () => {
|
|
419
419
|
o.value === "inline" && r.resetSearch();
|
|
420
420
|
});
|
|
@@ -422,7 +422,7 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
422
422
|
var e;
|
|
423
423
|
return Array.isArray(s.value) || t.multiselect || !t.selectedAsPlaceholder && o.value !== "inline" ? t.placeholder : ((e = s.value) == null ? void 0 : e.name) || t.placeholder;
|
|
424
424
|
}), b = (e) => {
|
|
425
|
-
var m,
|
|
425
|
+
var m, T;
|
|
426
426
|
let n = !1;
|
|
427
427
|
switch (e.key) {
|
|
428
428
|
case "Delete":
|
|
@@ -442,7 +442,7 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
442
442
|
break;
|
|
443
443
|
}
|
|
444
444
|
const g = e.key.length === 1 && !e.ctrlKey && !e.metaKey;
|
|
445
|
-
(o.value === "popup" || o.value === "inline") && g && (n = !0), (m =
|
|
445
|
+
(o.value === "popup" || o.value === "inline") && g && (n = !0), (m = k()) != null && m.elPopup && (n = !1), n && (o.value === "popup" && (e.preventDefault(), e.stopPropagation(), g && (r.searchText.value || (r.searchText.value = e.key))), (T = e.currentTarget) == null || T.click());
|
|
446
446
|
};
|
|
447
447
|
let i = !1;
|
|
448
448
|
const C = (e) => {
|
|
@@ -455,12 +455,12 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
455
455
|
var e;
|
|
456
456
|
if (i = !0, a.apiRequest) {
|
|
457
457
|
if (r.genIsShort()) {
|
|
458
|
-
(e =
|
|
458
|
+
(e = k()) == null || e.close();
|
|
459
459
|
return;
|
|
460
460
|
}
|
|
461
461
|
a.setSearchTextAndLoad(r.searchText.value, !1);
|
|
462
462
|
}
|
|
463
|
-
},
|
|
463
|
+
}, j = () => {
|
|
464
464
|
setTimeout(() => {
|
|
465
465
|
i = !1;
|
|
466
466
|
}, 100), o.value === "popup" && r.searchText.value && r.resetSearch();
|
|
@@ -491,17 +491,17 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
491
491
|
}
|
|
492
492
|
)), (e, n) => {
|
|
493
493
|
const g = oe("top-focus");
|
|
494
|
-
return
|
|
494
|
+
return p(), w(v(de), {
|
|
495
495
|
ref_key: "popupRef",
|
|
496
496
|
ref: f,
|
|
497
497
|
onOpen: n[3] || (n[3] = (m) => K()),
|
|
498
|
-
onClose: n[4] || (n[4] = (m) =>
|
|
498
|
+
onClose: n[4] || (n[4] = (m) => j()),
|
|
499
499
|
onScrollContentList: n[5] || (n[5] = (m) => e.apiRequest ? h(m) : void 0),
|
|
500
500
|
notch: o.value !== "inline",
|
|
501
501
|
transitionDuration: 0
|
|
502
502
|
}, U({
|
|
503
503
|
opener: V(() => [
|
|
504
|
-
q((
|
|
504
|
+
q((p(), w(le(c.value), R(e.buttonProps, {
|
|
505
505
|
ref: "subcomponentSelector",
|
|
506
506
|
class: {
|
|
507
507
|
"top-selector2": !0,
|
|
@@ -521,21 +521,21 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
521
521
|
"onUpdate:modelValue": n[0] || (n[0] = (m) => v(r).searchText.value = m),
|
|
522
522
|
onFocus: C,
|
|
523
523
|
onBlur: n[1] || (n[1] = (m) => {
|
|
524
|
-
var
|
|
525
|
-
return (
|
|
524
|
+
var T;
|
|
525
|
+
return (T = k()) != null && T.isClosed ? v(r).resetSearch() : "";
|
|
526
526
|
})
|
|
527
527
|
}), {
|
|
528
528
|
default: V(() => [
|
|
529
|
-
e.multiselect ? (
|
|
530
|
-
(
|
|
529
|
+
e.multiselect ? (p(), y("div", Se, [
|
|
530
|
+
(p(!0), y(z, null, F(s.value, (m) => (p(), w(we, {
|
|
531
531
|
id: m.id,
|
|
532
532
|
name: m.name,
|
|
533
533
|
onDelete: v(r).deleteItemById
|
|
534
534
|
}, null, 8, ["id", "name", "onDelete"]))), 256))
|
|
535
535
|
])) : A("", !0),
|
|
536
|
-
o.value !== "inline" && !e.multiselect ? (
|
|
537
|
-
e.multiselect && !s.value.length ? (
|
|
538
|
-
e.addChanger && !e.buttonProps && !e.multiselect && v(r).items.value.length > 1 && !e.disabled ? (
|
|
536
|
+
o.value !== "inline" && !e.multiselect ? (p(), y("span", Le, $(Array.isArray(s.value) ? "" : s.value.name), 1)) : A("", !0),
|
|
537
|
+
e.multiselect && !s.value.length ? (p(), y("span", Ee, $(u.value), 1)) : A("", !0),
|
|
538
|
+
e.addChanger && !e.buttonProps && !e.multiselect && v(r).items.value.length > 1 && !e.disabled ? (p(), y("span", {
|
|
539
539
|
key: 3,
|
|
540
540
|
class: "top-changer top-changer-selector top-popup_widget",
|
|
541
541
|
"data-top-popup-disabled": "true",
|
|
@@ -555,25 +555,25 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
555
555
|
contentList: V(() => {
|
|
556
556
|
var m;
|
|
557
557
|
return [
|
|
558
|
-
(
|
|
558
|
+
(p(!0), y(z, null, F(v(r).itemsForShow.value, (T) => (p(), w(v(H), {
|
|
559
559
|
class: I({
|
|
560
|
-
"top-active": !Array.isArray(s.value) && !e.multiselect && s.value.id ===
|
|
560
|
+
"top-active": !Array.isArray(s.value) && !e.multiselect && s.value.id === T.id && s.value.name === T.name
|
|
561
561
|
}),
|
|
562
|
-
key:
|
|
562
|
+
key: T.id ?? void 0,
|
|
563
563
|
closeByClick: !e.multiselect || v(Q).state.isMobile,
|
|
564
|
-
onClick: (He) => v(r).selectItem(
|
|
564
|
+
onClick: (He) => v(r).selectItem(T)
|
|
565
565
|
}, {
|
|
566
566
|
default: V(() => [
|
|
567
567
|
e.$slots.item ? W(e.$slots, "item", {
|
|
568
568
|
key: 0,
|
|
569
|
-
item:
|
|
570
|
-
}) : (
|
|
571
|
-
S($(
|
|
569
|
+
item: T
|
|
570
|
+
}) : (p(), y(z, { key: 1 }, [
|
|
571
|
+
S($(T.name), 1)
|
|
572
572
|
], 64))
|
|
573
573
|
]),
|
|
574
574
|
_: 2
|
|
575
575
|
}, 1032, ["class", "closeByClick", "onClick"]))), 128)),
|
|
576
|
-
!v(a).isLoading.value && !v(r).itemsForShow.value.length ? (
|
|
576
|
+
!v(a).isLoading.value && !v(r).itemsForShow.value.length ? (p(), w(v(H), {
|
|
577
577
|
key: 0,
|
|
578
578
|
type: "regular"
|
|
579
579
|
}, {
|
|
@@ -582,12 +582,12 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
582
582
|
]),
|
|
583
583
|
_: 1
|
|
584
584
|
})) : A("", !0),
|
|
585
|
-
v(a).isLoading.value && (e.searchType !== "popup" || (m = e.apiRequest) != null && m.params.offset) ? (
|
|
585
|
+
v(a).isLoading.value && (e.searchType !== "popup" || (m = e.apiRequest) != null && m.params.offset) ? (p(), w(v(H), {
|
|
586
586
|
key: 1,
|
|
587
587
|
type: "regular"
|
|
588
588
|
}, {
|
|
589
589
|
default: V(() => [
|
|
590
|
-
|
|
590
|
+
O(v(ie), { type: "circles" })
|
|
591
591
|
]),
|
|
592
592
|
_: 1
|
|
593
593
|
})) : A("", !0)
|
|
@@ -600,11 +600,11 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
600
600
|
fn: V(() => {
|
|
601
601
|
var m;
|
|
602
602
|
return [
|
|
603
|
-
|
|
603
|
+
O(v(pe), {
|
|
604
604
|
title: "Поиск",
|
|
605
605
|
icon: "",
|
|
606
606
|
modelValue: v(r).searchText.value,
|
|
607
|
-
"onUpdate:modelValue": n[2] || (n[2] = (
|
|
607
|
+
"onUpdate:modelValue": n[2] || (n[2] = (T) => v(r).searchText.value = T),
|
|
608
608
|
isLoading: v(a).isLoading.value && !((m = e.apiRequest) != null && m.params.offset),
|
|
609
609
|
placeholder: u.value
|
|
610
610
|
}, null, 8, ["modelValue", "isLoading", "placeholder"])
|
|
@@ -618,7 +618,7 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
618
618
|
}), Me = ["data-top-icon"], Ke = { class: "top-info_text" }, ze = {
|
|
619
619
|
key: 0,
|
|
620
620
|
class: "top-info_value"
|
|
621
|
-
},
|
|
621
|
+
}, Oe = /* @__PURE__ */ L({
|
|
622
622
|
__name: "info",
|
|
623
623
|
props: {
|
|
624
624
|
icon: {},
|
|
@@ -626,7 +626,7 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
626
626
|
size: { default: "default" }
|
|
627
627
|
},
|
|
628
628
|
setup(l) {
|
|
629
|
-
return (t, s) => (
|
|
629
|
+
return (t, s) => (p(), y("div", {
|
|
630
630
|
class: I({
|
|
631
631
|
"top-info": !0,
|
|
632
632
|
["top-size_" + t.size]: !0,
|
|
@@ -634,49 +634,51 @@ const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
|
634
634
|
}),
|
|
635
635
|
"data-top-icon": t.icon
|
|
636
636
|
}, [
|
|
637
|
-
|
|
637
|
+
_("div", Ke, [
|
|
638
638
|
W(t.$slots, "default")
|
|
639
639
|
]),
|
|
640
|
-
t.$slots.additional ? (
|
|
640
|
+
t.$slots.additional ? (p(), y("span", ze, [
|
|
641
641
|
W(t.$slots, "additional")
|
|
642
642
|
])) : A("", !0)
|
|
643
643
|
], 10, Me));
|
|
644
644
|
}
|
|
645
|
-
}),
|
|
645
|
+
}), De = {
|
|
646
646
|
key: 0,
|
|
647
647
|
class: "top-policy"
|
|
648
648
|
}, Ge = { class: "top-policy_title" }, Ne = ["innerHTML"], Fe = /* @__PURE__ */ L({
|
|
649
649
|
__name: "policy",
|
|
650
650
|
props: {
|
|
651
651
|
title: {},
|
|
652
|
-
|
|
652
|
+
description: {},
|
|
653
|
+
acceptText: {},
|
|
654
|
+
cookieName: {}
|
|
653
655
|
},
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
656
|
+
emits: ["accept"],
|
|
657
|
+
setup(l, { emit: t }) {
|
|
658
|
+
const s = t, o = B(!0), d = () => {
|
|
659
|
+
o.value = !1, s("accept");
|
|
658
660
|
};
|
|
659
|
-
return (
|
|
660
|
-
|
|
661
|
-
|
|
661
|
+
return (a, r) => o.value ? (p(), y("div", De, [
|
|
662
|
+
_("div", Ge, $(a.title), 1),
|
|
663
|
+
_("div", {
|
|
662
664
|
class: "top-policy_description",
|
|
663
|
-
innerHTML:
|
|
665
|
+
innerHTML: a.description
|
|
664
666
|
}, null, 8, Ne),
|
|
665
|
-
|
|
667
|
+
O(v(ue), {
|
|
666
668
|
size: "m",
|
|
667
|
-
onClick:
|
|
669
|
+
onClick: d
|
|
668
670
|
}, {
|
|
669
671
|
default: V(() => [
|
|
670
|
-
S($(
|
|
672
|
+
S($(a.acceptText), 1)
|
|
671
673
|
]),
|
|
672
674
|
_: 1
|
|
673
675
|
})
|
|
674
676
|
])) : A("", !0);
|
|
675
677
|
}
|
|
676
|
-
}),
|
|
678
|
+
}), je = ve, Qe = he, Ze = ke, qe = $e, xe = Pe, et = fe, tt = Oe, ot = Fe;
|
|
677
679
|
export {
|
|
678
680
|
qe as TopCheckboxGroup,
|
|
679
|
-
|
|
681
|
+
je as TopEditArea,
|
|
680
682
|
Qe as TopEditInput,
|
|
681
683
|
tt as TopInfo,
|
|
682
684
|
et as TopMenu,
|