@topvisor/ui 1.0.41 → 1.0.42-TopSelector.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.chunks/{core-D2o3elGA.amd.js → core-CNHOrWnw.amd.js} +2 -2
- package/.chunks/{core-D2o3elGA.amd.js.map → core-CNHOrWnw.amd.js.map} +1 -1
- package/.chunks/{core-CwjGTMhd.es.js → core-CZLRhkk2.es.js} +4 -4
- package/.chunks/{core-CwjGTMhd.es.js.map → core-CZLRhkk2.es.js.map} +1 -1
- package/.chunks/{datepicker-N83oX3hx.es.js → datepicker-BZ-GKoJc.es.js} +2 -2
- package/.chunks/{datepicker-N83oX3hx.es.js.map → datepicker-BZ-GKoJc.es.js.map} +1 -1
- package/.chunks/{datepicker-Byyye2pn.amd.js → datepicker-DnMEQ2c7.amd.js} +2 -2
- package/.chunks/{datepicker-Byyye2pn.amd.js.map → datepicker-DnMEQ2c7.amd.js.map} +1 -1
- package/.chunks/{dialog_selectorRegions-pDIYvl7b.amd.js → dialog_selectorRegions-B7ylHRje.amd.js} +2 -2
- package/.chunks/{dialog_selectorRegions-pDIYvl7b.amd.js.map → dialog_selectorRegions-B7ylHRje.amd.js.map} +1 -1
- package/.chunks/{dialog_selectorRegions-lYV2SJBx.es.js → dialog_selectorRegions-CR77RefG.es.js} +4 -4
- package/.chunks/{dialog_selectorRegions-lYV2SJBx.es.js.map → dialog_selectorRegions-CR77RefG.es.js.map} +1 -1
- package/.chunks/dialogs.vue_vue_type_script_setup_true_lang-C0n3o7PD.amd.js +2 -0
- package/.chunks/dialogs.vue_vue_type_script_setup_true_lang-C0n3o7PD.amd.js.map +1 -0
- package/.chunks/{dialogs.vue_vue_type_script_setup_true_lang-X3S_WcSV.es.js → dialogs.vue_vue_type_script_setup_true_lang-sExyADFk.es.js} +113 -97
- package/.chunks/dialogs.vue_vue_type_script_setup_true_lang-sExyADFk.es.js.map +1 -0
- package/.chunks/{forms-C-fyoosd.es.js → forms-1PEYT7sp.es.js} +482 -470
- package/.chunks/{forms-C-fyoosd.es.js.map → forms-1PEYT7sp.es.js.map} +1 -1
- package/.chunks/forms-BduN5hFf.amd.js +3 -0
- package/.chunks/{forms-DO87ZZk9.amd.js.map → forms-BduN5hFf.amd.js.map} +1 -1
- package/.chunks/{listItem.vue_vue_type_script_setup_true_lang-DDQSxC8E.amd.js → listItem.vue_vue_type_script_setup_true_lang-C660hIcG.amd.js} +2 -2
- package/.chunks/{listItem.vue_vue_type_script_setup_true_lang-DDQSxC8E.amd.js.map → listItem.vue_vue_type_script_setup_true_lang-C660hIcG.amd.js.map} +1 -1
- package/.chunks/{listItem.vue_vue_type_script_setup_true_lang-BJTTvdc7.es.js → listItem.vue_vue_type_script_setup_true_lang-DPwnYUm-.es.js} +2 -2
- package/.chunks/{listItem.vue_vue_type_script_setup_true_lang-BJTTvdc7.es.js.map → listItem.vue_vue_type_script_setup_true_lang-DPwnYUm-.es.js.map} +1 -1
- package/.chunks/{menu.vue_vue_type_style_index_0_lang-Bi9Z81pC.es.js → menu.vue_vue_type_style_index_0_lang-BYP0xpzD.es.js} +2 -2
- package/.chunks/{menu.vue_vue_type_style_index_0_lang-Bi9Z81pC.es.js.map → menu.vue_vue_type_style_index_0_lang-BYP0xpzD.es.js.map} +1 -1
- package/.chunks/{menu.vue_vue_type_style_index_0_lang-7eYwnVLw.amd.js → menu.vue_vue_type_style_index_0_lang-C9cIXmj2.amd.js} +2 -2
- package/.chunks/{menu.vue_vue_type_style_index_0_lang-7eYwnVLw.amd.js.map → menu.vue_vue_type_style_index_0_lang-C9cIXmj2.amd.js.map} +1 -1
- package/.chunks/{notice-DCONQ8rR.es.js → notice-C505E22P.es.js} +2 -2
- package/.chunks/{notice-DCONQ8rR.es.js.map → notice-C505E22P.es.js.map} +1 -1
- package/.chunks/{notice-B8nfJMJN.amd.js → notice-CEYLelBs.amd.js} +2 -2
- package/.chunks/{notice-B8nfJMJN.amd.js.map → notice-CEYLelBs.amd.js.map} +1 -1
- package/.chunks/{page.vue_vue_type_script_setup_true_lang-Cg3dLy7K.amd.js → page.vue_vue_type_script_setup_true_lang-DpmKeCWn.amd.js} +2 -2
- package/.chunks/page.vue_vue_type_script_setup_true_lang-DpmKeCWn.amd.js.map +1 -0
- package/.chunks/{page.vue_vue_type_script_setup_true_lang-Dze2ZUr3.es.js → page.vue_vue_type_script_setup_true_lang-_-EoskSt.es.js} +4 -4
- package/.chunks/page.vue_vue_type_script_setup_true_lang-_-EoskSt.es.js.map +1 -0
- package/.chunks/{popup-PpCQY5Zi.es.js → popup-Bh3WbTKH.es.js} +106 -73
- package/.chunks/popup-Bh3WbTKH.es.js.map +1 -0
- package/.chunks/popup-C5-ffkMJ.amd.js +2 -0
- package/.chunks/popup-C5-ffkMJ.amd.js.map +1 -0
- package/.chunks/{utils-DAIrXU57.amd.js → utils-BgjhCn4H.amd.js} +2 -2
- package/.chunks/{utils-DAIrXU57.amd.js.map → utils-BgjhCn4H.amd.js.map} +1 -1
- package/.chunks/{utils-BcKnFj1j.es.js → utils-CMJHpNDX.es.js} +246 -169
- package/.chunks/utils-CMJHpNDX.es.js.map +1 -0
- package/.chunks/{utils-DsICGMuv.es.js → utils-DEyMm4Iq.es.js} +2 -2
- package/.chunks/{utils-DsICGMuv.es.js.map → utils-DEyMm4Iq.es.js.map} +1 -1
- package/.chunks/utils-DWmOkm95.amd.js +2 -0
- package/.chunks/utils-DWmOkm95.amd.js.map +1 -0
- package/assets/core.css +1 -1
- package/assets/forms.css +1 -1
- package/assets/formsExt.css +1 -1
- package/assets/notice.css +1 -1
- package/assets/project.css +1 -1
- package/charts/charts.amd.js +1 -1
- package/charts/charts.js +1 -1
- package/components/dialog/dialog/dialogs/dialogs.vue.d.ts +3 -0
- package/components/dialog/lib/types.d.ts +23 -0
- package/components/dialog/lib/utils.d.ts +8 -8
- package/components/dialog/lib/utils.globalEvents.d.ts +2 -2
- package/components/dialog/lib/worker.d.ts +12 -11
- package/components/forms/button/button.vue.d.ts +2 -5
- package/components/forms/button/types.d.ts +10 -0
- package/components/formsExt/formsExt.d.ts +2 -0
- package/components/formsExt/policy/policy.vue.d.ts +4 -0
- package/components/formsExt/policy/types.d.ts +10 -0
- package/components/formsExt/selector2/composables/useAPI.d.ts +1 -1
- package/components/formsExt/selector2/composables/useMenu.d.ts +5 -1
- package/components/formsExt/selector2/selector2.vue.d.ts +3 -4
- package/components/formsExt/selector2/stories/dummyAPIRequest.d.ts +1 -2
- package/components/formsExt/selector2/types.d.ts +48 -22
- package/components/popup/lib/popup.d.ts +1 -0
- package/components/popup/lib/worker.d.ts +4 -2
- package/core/app.amd.js +1 -1
- package/core/app.js +5 -5
- package/core/core/core.d.ts +1 -1
- package/core/core/options.d.ts +7 -6
- package/core/core/state.d.ts +1 -1
- package/core/plugins/core.d.ts +1 -1
- package/core/utils/date.d.ts +30 -12
- package/core/utils/dom.d.ts +11 -1
- package/core/utils/string.d.ts +1 -1
- package/dialog/dialog.amd.js +1 -1
- package/dialog/dialog.js +2 -2
- package/forms/forms.amd.js +1 -1
- package/forms/forms.js +1 -1
- package/formsExt/formsExt.amd.js +1 -1
- package/formsExt/formsExt.amd.js.map +1 -1
- package/formsExt/formsExt.js +432 -309
- package/formsExt/formsExt.js.map +1 -1
- package/icomoon/demo.html +15 -1
- package/icomoon/fonts/Topvisor-2.eot +0 -0
- package/icomoon/fonts/Topvisor-2.svg +1 -0
- package/icomoon/fonts/Topvisor-2.ttf +0 -0
- package/icomoon/fonts/Topvisor-2.woff +0 -0
- package/icomoon/selection.json +1 -1
- package/icomoon/style.css +8 -5
- package/layout/layout.amd.js +1 -1
- package/layout/layout.js +1 -1
- package/package.json +1 -1
- package/popup/popup.amd.js +1 -1
- package/popup/popup.js +2 -2
- package/popup/worker.amd.js +1 -1
- package/popup/worker.amd.js.map +1 -1
- package/popup/worker.js +30 -21
- package/popup/worker.js.map +1 -1
- package/project/project.amd.js +1 -1
- package/project/project.amd.js.map +1 -1
- package/project/project.js +6 -6
- package/project/project.js.map +1 -1
- package/tabsView/tabsView.amd.js +1 -1
- package/tabsView/tabsView.js +1 -1
- package/utils/clipboard.amd.js +1 -1
- package/utils/clipboard.js +1 -1
- package/utils/date.amd.js +1 -1
- package/utils/date.js +4 -3
- package/utils/device.amd.js +1 -1
- package/utils/device.js +1 -1
- package/utils/dom.amd.js +1 -1
- package/utils/dom.amd.js.map +1 -1
- package/utils/dom.js +27 -22
- package/utils/dom.js.map +1 -1
- package/utils/lodash.amd.js +1 -1
- package/utils/lodash.js +1 -1
- package/utils/price.amd.js +1 -1
- package/utils/price.js +1 -1
- package/utils/searchers.amd.js +1 -1
- package/utils/searchers.js +3 -3
- package/utils/string.amd.js +1 -1
- package/utils/string.amd.js.map +1 -1
- package/utils/string.js +34 -30
- package/utils/string.js.map +1 -1
- package/.chunks/dialogs.vue_vue_type_script_setup_true_lang-B14m3p7q.amd.js +0 -2
- package/.chunks/dialogs.vue_vue_type_script_setup_true_lang-B14m3p7q.amd.js.map +0 -1
- package/.chunks/dialogs.vue_vue_type_script_setup_true_lang-X3S_WcSV.es.js.map +0 -1
- package/.chunks/forms-DO87ZZk9.amd.js +0 -3
- package/.chunks/page.vue_vue_type_script_setup_true_lang-Cg3dLy7K.amd.js.map +0 -1
- package/.chunks/page.vue_vue_type_script_setup_true_lang-Dze2ZUr3.es.js.map +0 -1
- package/.chunks/popup-PpCQY5Zi.es.js.map +0 -1
- package/.chunks/popup-XXfdNLmr.amd.js +0 -2
- package/.chunks/popup-XXfdNLmr.amd.js.map +0 -1
- package/.chunks/utils-BcKnFj1j.es.js.map +0 -1
- package/.chunks/utils-pvFg1FqE.amd.js +0 -2
- package/.chunks/utils-pvFg1FqE.amd.js.map +0 -1
- package/icomoon/Topvisor icons.json +0 -6612
package/formsExt/formsExt.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { Core as
|
|
2
|
-
import { defineComponent as
|
|
3
|
-
import { w as
|
|
4
|
-
import { TopPopup as
|
|
5
|
-
import { invertKeyboardLayout as
|
|
6
|
-
import { _ as
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
const
|
|
1
|
+
import { Core as x } from "../core/app.js";
|
|
2
|
+
import { defineComponent as L, ref as _, computed as P, createElementBlock as y, openBlock as d, normalizeClass as I, createCommentVNode as A, createElementVNode as B, toDisplayString as $, createVNode as D, withKeys as G, withModifiers as N, createBlock as w, createSlots as U, withCtx as V, createTextVNode as S, watch as E, toRef as O, mergeProps as R, mergeModels as j, useModel as J, 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
|
+
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-1PEYT7sp.es.js";
|
|
4
|
+
import { TopPopup as de, TopPopupListItem as H, TopPopupWidgetInput as pe } from "../popup/popup.js";
|
|
5
|
+
import { invertKeyboardLayout as ce } from "../utils/keyboard.js";
|
|
6
|
+
import { _ as fe } from "../.chunks/menu.vue_vue_type_style_index_0_lang-BYP0xpzD.es.js";
|
|
7
|
+
const ee = ["../assets/formsExt.css"].map((l) => import.meta.resolve(l));
|
|
8
|
+
x.insertCSSLinkToPage(ee, !0);
|
|
9
|
+
const me = { class: "top-editArea_footer" }, ve = /* @__PURE__ */ L({
|
|
10
10
|
__name: "editArea",
|
|
11
11
|
props: {
|
|
12
12
|
defaultValue: { default: "" },
|
|
@@ -31,92 +31,94 @@ const ie = { class: "top-editArea_footer" }, ue = /* @__PURE__ */ B({
|
|
|
31
31
|
maxLength: {}
|
|
32
32
|
},
|
|
33
33
|
emits: ["submit", "close", "clickOnTitle"],
|
|
34
|
-
setup(
|
|
35
|
-
const
|
|
36
|
-
|
|
37
|
-
},
|
|
38
|
-
if (
|
|
39
|
-
|
|
34
|
+
setup(l, { emit: t }) {
|
|
35
|
+
const s = l, o = t, p = _(s.defaultValue), a = _(s.isFocused), r = P(() => p.value !== s.defaultValue), c = (u) => {
|
|
36
|
+
o("submit", u), p.value = s.defaultValue;
|
|
37
|
+
}, f = () => {
|
|
38
|
+
if (s.forceShowCloseBtn && !r.value) {
|
|
39
|
+
o("close");
|
|
40
40
|
return;
|
|
41
41
|
}
|
|
42
|
-
|
|
43
|
-
},
|
|
44
|
-
|
|
42
|
+
p.value = s.defaultValue;
|
|
43
|
+
}, T = () => {
|
|
44
|
+
s.attachToKeyboard && o("clickOnTitle");
|
|
45
45
|
};
|
|
46
|
-
return (
|
|
47
|
-
class:
|
|
46
|
+
return (u, b) => (d(), y("div", {
|
|
47
|
+
class: I({
|
|
48
48
|
"top-editArea": !0,
|
|
49
|
-
"top-editArea-attachedToKeyboard":
|
|
49
|
+
"top-editArea-attachedToKeyboard": u.attachToKeyboard
|
|
50
50
|
})
|
|
51
51
|
}, [
|
|
52
|
-
|
|
52
|
+
u.title ? (d(), y("div", {
|
|
53
53
|
key: 0,
|
|
54
54
|
class: "top-editArea_title",
|
|
55
|
-
onClick:
|
|
56
|
-
}, $(
|
|
57
|
-
|
|
58
|
-
class:
|
|
55
|
+
onClick: b[0] || (b[0] = (i) => T())
|
|
56
|
+
}, $(u.title), 1)) : A("", !0),
|
|
57
|
+
B("div", {
|
|
58
|
+
class: I({
|
|
59
59
|
"top-editArea_form": !0,
|
|
60
|
-
"top-
|
|
61
|
-
"top-
|
|
60
|
+
"top-forms-focusable": !0,
|
|
61
|
+
"top-as-input": !0,
|
|
62
|
+
"top-error": u.isError,
|
|
63
|
+
"top-focus": a.value
|
|
62
64
|
})
|
|
63
65
|
}, [
|
|
64
|
-
|
|
65
|
-
modelValue:
|
|
66
|
-
"onUpdate:modelValue":
|
|
67
|
-
name:
|
|
68
|
-
placeholder:
|
|
69
|
-
rows:
|
|
70
|
-
minHeight:
|
|
71
|
-
expandable:
|
|
72
|
-
disabled:
|
|
73
|
-
readonly:
|
|
74
|
-
isError:
|
|
75
|
-
hint:
|
|
66
|
+
D(se, {
|
|
67
|
+
modelValue: p.value,
|
|
68
|
+
"onUpdate:modelValue": b[1] || (b[1] = (i) => p.value = i),
|
|
69
|
+
name: u.name,
|
|
70
|
+
placeholder: u.placeholder,
|
|
71
|
+
rows: u.rows,
|
|
72
|
+
minHeight: u.minHeight,
|
|
73
|
+
expandable: u.expandable,
|
|
74
|
+
disabled: u.disabled,
|
|
75
|
+
readonly: u.readonly,
|
|
76
|
+
isError: u.isError,
|
|
77
|
+
hint: u.hint,
|
|
76
78
|
class: "top-editArea_element",
|
|
77
|
-
onFocus:
|
|
78
|
-
onBlur:
|
|
79
|
+
onFocus: b[2] || (b[2] = () => a.value = !0),
|
|
80
|
+
onBlur: b[3] || (b[3] = () => a.value = !1),
|
|
79
81
|
onKeyup: [
|
|
80
|
-
|
|
81
|
-
|
|
82
|
+
G(f, ["esc"]),
|
|
83
|
+
b[4] || (b[4] = G(N((i) => c(p.value), ["ctrl"]), ["enter"]))
|
|
82
84
|
]
|
|
83
85
|
}, null, 8, ["modelValue", "name", "placeholder", "rows", "minHeight", "expandable", "disabled", "readonly", "isError", "hint"]),
|
|
84
|
-
|
|
85
|
-
|
|
86
|
+
B("div", me, [
|
|
87
|
+
r.value || u.forceShowCloseBtn ? (d(), w(X, {
|
|
86
88
|
key: 0,
|
|
87
|
-
icon:
|
|
89
|
+
icon: u.$core.state.isMobile ? "" : "",
|
|
88
90
|
class: "top-editArea_button",
|
|
89
91
|
color: "theme",
|
|
90
92
|
styling: "soft",
|
|
91
|
-
onClick:
|
|
92
|
-
},
|
|
93
|
-
|
|
93
|
+
onClick: f
|
|
94
|
+
}, U({ _: 2 }, [
|
|
95
|
+
u.$core.state.isMobile ? void 0 : {
|
|
94
96
|
name: "default",
|
|
95
97
|
fn: V(() => [
|
|
96
|
-
S($(
|
|
98
|
+
S($(u.cancelText), 1)
|
|
97
99
|
]),
|
|
98
100
|
key: "0"
|
|
99
101
|
}
|
|
100
|
-
]), 1032, ["icon"])) :
|
|
101
|
-
|
|
102
|
+
]), 1032, ["icon"])) : A("", !0),
|
|
103
|
+
r.value ? (d(), w(X, {
|
|
102
104
|
key: 1,
|
|
103
105
|
class: "top-editArea_button",
|
|
104
|
-
icon:
|
|
105
|
-
onClick:
|
|
106
|
-
},
|
|
107
|
-
|
|
106
|
+
icon: u.$core.state.isMobile ? "" : "",
|
|
107
|
+
onClick: b[5] || (b[5] = (i) => c(p.value))
|
|
108
|
+
}, U({ _: 2 }, [
|
|
109
|
+
u.$core.state.isMobile ? void 0 : {
|
|
108
110
|
name: "default",
|
|
109
111
|
fn: V(() => [
|
|
110
|
-
S($(
|
|
112
|
+
S($(u.submitText), 1)
|
|
111
113
|
]),
|
|
112
114
|
key: "0"
|
|
113
115
|
}
|
|
114
|
-
]), 1032, ["icon"])) :
|
|
116
|
+
]), 1032, ["icon"])) : A("", !0)
|
|
115
117
|
])
|
|
116
118
|
], 2)
|
|
117
119
|
], 2));
|
|
118
120
|
}
|
|
119
|
-
}),
|
|
121
|
+
}), ye = { class: "top-editInput" }, he = /* @__PURE__ */ L({
|
|
120
122
|
__name: "editInput",
|
|
121
123
|
props: {
|
|
122
124
|
modelValue: {},
|
|
@@ -124,34 +126,34 @@ const ie = { class: "top-editArea_footer" }, ue = /* @__PURE__ */ B({
|
|
|
124
126
|
button: {}
|
|
125
127
|
},
|
|
126
128
|
emits: ["update:modelValue"],
|
|
127
|
-
setup(
|
|
128
|
-
const
|
|
129
|
-
E(
|
|
130
|
-
|
|
129
|
+
setup(l, { emit: t }) {
|
|
130
|
+
const s = l, o = _(s.modelValue);
|
|
131
|
+
E(O(s.modelValue), () => {
|
|
132
|
+
o.value = s.modelValue;
|
|
131
133
|
});
|
|
132
|
-
const
|
|
133
|
-
|
|
134
|
+
const p = t, a = () => {
|
|
135
|
+
p("update:modelValue", o.value);
|
|
134
136
|
};
|
|
135
|
-
return (
|
|
136
|
-
|
|
137
|
-
onKeydownCapture: c[0] || (c[0] =
|
|
138
|
-
onKeydown:
|
|
139
|
-
modelValue:
|
|
140
|
-
"onUpdate:modelValue": c[1] || (c[1] = (
|
|
137
|
+
return (r, c) => (d(), y("div", ye, [
|
|
138
|
+
D(ae, R(r.input, {
|
|
139
|
+
onKeydownCapture: c[0] || (c[0] = G(N((f) => o.value = r.modelValue, ["stop"]), ["esc"])),
|
|
140
|
+
onKeydown: G(N(a, ["stop"]), ["enter"]),
|
|
141
|
+
modelValue: o.value,
|
|
142
|
+
"onUpdate:modelValue": c[1] || (c[1] = (f) => o.value = f)
|
|
141
143
|
}), null, 16, ["onKeydown", "modelValue"]),
|
|
142
|
-
|
|
144
|
+
o.value !== r.modelValue ? (d(), w(X, R({
|
|
143
145
|
key: 0,
|
|
144
146
|
icon: "",
|
|
145
147
|
styling: "soft"
|
|
146
|
-
},
|
|
148
|
+
}, r.button, { onClick: a }), null, 16)) : A("", !0)
|
|
147
149
|
]));
|
|
148
150
|
}
|
|
149
|
-
}),
|
|
151
|
+
}), be = ["data-top-icon", "onClick"], ge = {
|
|
150
152
|
key: 0,
|
|
151
153
|
class: "top-radioGroup_circle"
|
|
152
|
-
},
|
|
154
|
+
}, ke = ["value", "disabled"], Te = /* @__PURE__ */ L({
|
|
153
155
|
__name: "radioGroup",
|
|
154
|
-
props: /* @__PURE__ */
|
|
156
|
+
props: /* @__PURE__ */ j({
|
|
155
157
|
modelValue: {},
|
|
156
158
|
radiosProps: {},
|
|
157
159
|
showIndicator: { type: Boolean },
|
|
@@ -164,53 +166,53 @@ const ie = { class: "top-editArea_footer" }, ue = /* @__PURE__ */ B({
|
|
|
164
166
|
modelModifiers: {}
|
|
165
167
|
}),
|
|
166
168
|
emits: ["update:modelValue"],
|
|
167
|
-
setup(
|
|
168
|
-
const
|
|
169
|
-
E(
|
|
170
|
-
var
|
|
171
|
-
(
|
|
169
|
+
setup(l) {
|
|
170
|
+
const t = J(l, "modelValue"), s = l, o = _(null);
|
|
171
|
+
E(t, () => {
|
|
172
|
+
var a, r, c, f, T;
|
|
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) ?? ""), (T = (f = o.value) == null ? void 0 : f.querySelector(".radioGroup_item-selected")) == null || T.scrollIntoView();
|
|
172
174
|
}, { immediate: !0 });
|
|
173
|
-
const
|
|
174
|
-
return (
|
|
175
|
+
const p = "radioGroup-" + Math.random();
|
|
176
|
+
return (a, r) => (d(), y("div", {
|
|
175
177
|
ref_key: "elRef",
|
|
176
|
-
ref:
|
|
177
|
-
class:
|
|
178
|
+
ref: o,
|
|
179
|
+
class: I({
|
|
178
180
|
"top-radioGroup": !0,
|
|
179
181
|
"top-scrollBarXHidding": !0,
|
|
180
|
-
["top-size_" +
|
|
181
|
-
"top-error":
|
|
182
|
+
["top-size_" + a.size]: !!a.size,
|
|
183
|
+
"top-error": a.isError
|
|
182
184
|
})
|
|
183
185
|
}, [
|
|
184
|
-
(
|
|
185
|
-
class:
|
|
186
|
-
"top-radioGroup_item-selected": c.value ===
|
|
186
|
+
(d(!0), y(z, null, F(a.radiosProps, (c) => (d(), y("label", {
|
|
187
|
+
class: I({
|
|
188
|
+
"top-radioGroup_item-selected": c.value === t.value,
|
|
187
189
|
"top-radioGroup_item": !0,
|
|
188
190
|
"top-forms-focusable": !0,
|
|
189
191
|
"top-disabled": c.disabled
|
|
190
192
|
}),
|
|
191
193
|
"data-top-icon": c.icon,
|
|
192
|
-
onClick: (
|
|
194
|
+
onClick: (f) => t.value = c.value
|
|
193
195
|
}, [
|
|
194
196
|
S($(c.title) + " ", 1),
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
"onUpdate:modelValue":
|
|
198
|
-
name:
|
|
197
|
+
a.showIndicator ? (d(), y("span", ge)) : A("", !0),
|
|
198
|
+
q(B("input", {
|
|
199
|
+
"onUpdate:modelValue": r[0] || (r[0] = (f) => t.value = f),
|
|
200
|
+
name: p,
|
|
199
201
|
type: "radio",
|
|
200
|
-
class:
|
|
202
|
+
class: I({
|
|
201
203
|
"top-unvisible": !0
|
|
202
204
|
}),
|
|
203
205
|
value: c.value,
|
|
204
206
|
disabled: c.disabled
|
|
205
|
-
}, null, 8,
|
|
206
|
-
[
|
|
207
|
+
}, null, 8, ke), [
|
|
208
|
+
[te, t.value]
|
|
207
209
|
])
|
|
208
|
-
], 10,
|
|
210
|
+
], 10, be))), 256))
|
|
209
211
|
], 2));
|
|
210
212
|
}
|
|
211
|
-
}),
|
|
213
|
+
}), Ae = ["data-top-icon"], Ce = ["value", "checked", "disabled", "onChange"], $e = /* @__PURE__ */ L({
|
|
212
214
|
__name: "checkboxGroup",
|
|
213
|
-
props: /* @__PURE__ */
|
|
215
|
+
props: /* @__PURE__ */ j({
|
|
214
216
|
modelValue: {},
|
|
215
217
|
items: {},
|
|
216
218
|
size: { default: "s" },
|
|
@@ -223,297 +225,386 @@ const ie = { class: "top-editArea_footer" }, ue = /* @__PURE__ */ B({
|
|
|
223
225
|
modelModifiers: {}
|
|
224
226
|
}),
|
|
225
227
|
emits: ["update:modelValue"],
|
|
226
|
-
setup(
|
|
227
|
-
const
|
|
228
|
-
const
|
|
229
|
-
|
|
228
|
+
setup(l) {
|
|
229
|
+
const t = J(l, "modelValue"), s = (o) => {
|
|
230
|
+
const p = [...t.value], a = p.indexOf(o);
|
|
231
|
+
a === -1 ? p.push(o) : p.splice(a, 1), t.value = p;
|
|
230
232
|
};
|
|
231
|
-
return (
|
|
232
|
-
class:
|
|
233
|
+
return (o, p) => (d(), y("div", {
|
|
234
|
+
class: I({
|
|
233
235
|
"top-checkboxGroup": !0,
|
|
234
|
-
["top-checkboxGroup-" +
|
|
236
|
+
["top-checkboxGroup-" + o.styling]: !0,
|
|
235
237
|
"top-scrollBarXHidding": !0,
|
|
236
|
-
["top-size_" +
|
|
237
|
-
"top-error":
|
|
238
|
+
["top-size_" + o.size]: !!o.size,
|
|
239
|
+
"top-error": o.isError
|
|
238
240
|
})
|
|
239
241
|
}, [
|
|
240
|
-
(
|
|
241
|
-
key:
|
|
242
|
-
class:
|
|
242
|
+
(d(!0), y(z, null, F(o.items, (a) => (d(), y("label", {
|
|
243
|
+
key: a.id,
|
|
244
|
+
class: I({
|
|
243
245
|
"top-checkboxGroup_item": !0,
|
|
244
|
-
"top-checkboxGroup_item-selected":
|
|
246
|
+
"top-checkboxGroup_item-selected": t.value.includes(a.id),
|
|
245
247
|
"top-forms-focusable": !0,
|
|
246
|
-
"top-disabled":
|
|
248
|
+
"top-disabled": a.disabled
|
|
247
249
|
}),
|
|
248
|
-
"data-top-icon":
|
|
250
|
+
"data-top-icon": a.icon
|
|
249
251
|
}, [
|
|
250
|
-
|
|
252
|
+
B("input", {
|
|
251
253
|
type: "checkbox",
|
|
252
254
|
class: "top-unvisible",
|
|
253
|
-
value:
|
|
254
|
-
checked:
|
|
255
|
-
disabled:
|
|
256
|
-
onChange: (
|
|
257
|
-
}, null, 40,
|
|
258
|
-
S(" " + $(
|
|
259
|
-
], 10,
|
|
255
|
+
value: a.id,
|
|
256
|
+
checked: t.value.includes(a.id),
|
|
257
|
+
disabled: a.disabled,
|
|
258
|
+
onChange: (r) => s(a.id)
|
|
259
|
+
}, null, 40, Ce),
|
|
260
|
+
S(" " + $(a.title), 1)
|
|
261
|
+
], 10, Ae))), 128))
|
|
260
262
|
], 2));
|
|
261
263
|
}
|
|
262
|
-
}),
|
|
264
|
+
}), Ve = { class: "top-selector2_itemMulti top-ellipsis" }, we = /* @__PURE__ */ L({
|
|
263
265
|
__name: "itemMulti",
|
|
264
266
|
props: {
|
|
265
267
|
id: {},
|
|
266
268
|
name: {}
|
|
267
269
|
},
|
|
268
270
|
emits: ["delete"],
|
|
269
|
-
setup(
|
|
270
|
-
return (
|
|
271
|
-
S($(
|
|
272
|
-
|
|
271
|
+
setup(l) {
|
|
272
|
+
return (t, s) => (d(), y("div", Ve, [
|
|
273
|
+
S($(t.name) + " ", 1),
|
|
274
|
+
B("span", {
|
|
273
275
|
class: "top-selector2_itemMultiDelete",
|
|
274
276
|
"data-top-icon": "",
|
|
275
|
-
onClick:
|
|
276
|
-
onMousedown:
|
|
277
|
+
onClick: s[0] || (s[0] = (o) => t.$emit("delete", t.id)),
|
|
278
|
+
onMousedown: s[1] || (s[1] = N(() => {
|
|
277
279
|
}, ["stop"]))
|
|
278
280
|
}, null, 32)
|
|
279
281
|
]));
|
|
280
282
|
}
|
|
281
|
-
}),
|
|
282
|
-
const
|
|
283
|
-
let
|
|
284
|
-
|
|
283
|
+
}), Ie = (l, t, s) => {
|
|
284
|
+
const o = _([]), p = _(!1);
|
|
285
|
+
let a = "", r;
|
|
286
|
+
l && !l.params.limit && (l.params.limit = 100);
|
|
285
287
|
const c = async () => {
|
|
286
|
-
if (!
|
|
287
|
-
let
|
|
288
|
-
if (
|
|
289
|
-
return
|
|
290
|
-
if (
|
|
291
|
-
if (!Array.isArray(
|
|
288
|
+
if (!l) return;
|
|
289
|
+
let i, C;
|
|
290
|
+
if (s && (l.cache ??= /* @__PURE__ */ new Map(), C = JSON.stringify(l.params), i = l.cache.get(C), i))
|
|
291
|
+
return i;
|
|
292
|
+
if (p.value = !0, i = await l.call(), p.value = !1, i.errors) return;
|
|
293
|
+
if (!Array.isArray(i.result)) {
|
|
292
294
|
console.warn("В result ожидался массив");
|
|
293
295
|
return;
|
|
294
296
|
}
|
|
295
|
-
const
|
|
296
|
-
if (
|
|
297
|
-
console.warn(`В result[${
|
|
297
|
+
const M = i.result.findIndex((K) => K.id === void 0 || K.name === void 0);
|
|
298
|
+
if (M !== -1) {
|
|
299
|
+
console.warn(`В result[${M}] нет id или name`);
|
|
298
300
|
return;
|
|
299
301
|
}
|
|
300
|
-
return
|
|
301
|
-
},
|
|
302
|
-
if (!
|
|
303
|
-
|
|
304
|
-
const
|
|
305
|
-
|
|
306
|
-
},
|
|
307
|
-
if (!
|
|
308
|
-
|
|
309
|
-
const
|
|
310
|
-
|
|
311
|
-
},
|
|
302
|
+
return s && l.cache.set(C, i), i;
|
|
303
|
+
}, f = async () => {
|
|
304
|
+
if (!l) return;
|
|
305
|
+
l.params.offset = 0, l.params.search = a;
|
|
306
|
+
const i = await c();
|
|
307
|
+
i && (r = i.nextOffset, o.value = i.result);
|
|
308
|
+
}, T = async () => {
|
|
309
|
+
if (!l || !r || p.value) return;
|
|
310
|
+
l.params.offset = r, l.params.search = a;
|
|
311
|
+
const i = await c();
|
|
312
|
+
i && (r = i.nextOffset, o.value = o.value.concat(i.result));
|
|
313
|
+
}, u = re(() => f(), 200);
|
|
312
314
|
return {
|
|
313
|
-
apiRequest:
|
|
314
|
-
items:
|
|
315
|
-
isLoading:
|
|
316
|
-
loadAppend:
|
|
317
|
-
setSearchTextAndLoad: (
|
|
318
|
-
|
|
315
|
+
apiRequest: l,
|
|
316
|
+
items: o,
|
|
317
|
+
isLoading: p,
|
|
318
|
+
loadAppend: T,
|
|
319
|
+
setSearchTextAndLoad: (i, C = !0) => {
|
|
320
|
+
l && (i.length < t || i === a && o.value.length || (a = i, C ? u() : f()));
|
|
319
321
|
}
|
|
320
322
|
};
|
|
321
|
-
},
|
|
322
|
-
const
|
|
323
|
-
id:
|
|
324
|
-
name:
|
|
325
|
-
},
|
|
326
|
-
|
|
327
|
-
},
|
|
328
|
-
var
|
|
329
|
-
const
|
|
330
|
-
return !
|
|
331
|
-
}),
|
|
332
|
-
const
|
|
333
|
-
let
|
|
334
|
-
return
|
|
335
|
-
const
|
|
336
|
-
(
|
|
337
|
-
}),
|
|
323
|
+
}, _e = 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, Be = (l, t, s, o, p, a, r, c) => {
|
|
324
|
+
const f = _(""), T = {
|
|
325
|
+
id: _e,
|
|
326
|
+
name: ne().Common.All
|
|
327
|
+
}, u = () => {
|
|
328
|
+
f.value = "", c.items.value = [];
|
|
329
|
+
}, b = () => !(!c.apiRequest || a.value !== "inline" || f.value.length >= r), i = P(() => {
|
|
330
|
+
var e;
|
|
331
|
+
const h = [];
|
|
332
|
+
return !s && o.value && h.push(T), (e = t.value) == null || e.forEach((n) => h.push({ ...n })), h;
|
|
333
|
+
}), C = P(() => {
|
|
334
|
+
const h = f.value.toLowerCase(), e = ce(h);
|
|
335
|
+
let n = [];
|
|
336
|
+
return i.value.forEach((g) => {
|
|
337
|
+
const m = g.name.toLowerCase();
|
|
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), p.value && f.value && (!n.length || n[0].name.toLowerCase() !== h) && n.push({
|
|
338
340
|
id: null,
|
|
339
|
-
name:
|
|
340
|
-
}),
|
|
341
|
+
name: f.value
|
|
342
|
+
}), s && (n = n.filter((g) => !Z(l.value, g))), n;
|
|
341
343
|
});
|
|
342
344
|
return {
|
|
343
|
-
searchText:
|
|
344
|
-
resetSearch:
|
|
345
|
-
|
|
346
|
-
|
|
345
|
+
searchText: f,
|
|
346
|
+
resetSearch: u,
|
|
347
|
+
genIsShort: b,
|
|
348
|
+
items: i,
|
|
349
|
+
itemsForShow: C,
|
|
350
|
+
selectItem: (h) => {
|
|
351
|
+
s && Array.isArray(l.value) ? Z(l.value, h) || (l.value = [...l.value, h]) : l.value = h;
|
|
352
|
+
},
|
|
353
|
+
selectNextItem: () => {
|
|
354
|
+
if (!Array.isArray(l.value)) {
|
|
355
|
+
const e = (C.value.findIndex((n) => n.id === l.value.id) + 1) % C.value.length;
|
|
356
|
+
l.value = { ...C.value[e] };
|
|
357
|
+
}
|
|
358
|
+
},
|
|
359
|
+
deleteItemById: async (h) => {
|
|
360
|
+
Array.isArray(l.value) && (l.value = l.value.filter((e) => e.id !== h));
|
|
361
|
+
}
|
|
347
362
|
};
|
|
348
|
-
},
|
|
363
|
+
}, Se = {
|
|
349
364
|
key: 0,
|
|
350
365
|
class: "top-selector2_activeItems"
|
|
351
|
-
},
|
|
366
|
+
}, Le = {
|
|
352
367
|
key: 1,
|
|
353
368
|
class: "top-selector2_activeName top-ellipsis"
|
|
354
|
-
},
|
|
369
|
+
}, Ee = {
|
|
370
|
+
key: 2,
|
|
371
|
+
class: "top-selector2_placeholder top-ellipsis"
|
|
372
|
+
}, Pe = /* @__PURE__ */ L({
|
|
355
373
|
__name: "selector2",
|
|
356
|
-
props: /* @__PURE__ */
|
|
374
|
+
props: /* @__PURE__ */ j({
|
|
357
375
|
modelValue: {},
|
|
358
376
|
items: { default: () => [] },
|
|
359
|
-
|
|
377
|
+
title: {},
|
|
360
378
|
disabled: { type: Boolean },
|
|
361
379
|
size: { default: "s" },
|
|
362
380
|
isError: { type: Boolean },
|
|
381
|
+
searchType: { default: "popup" },
|
|
382
|
+
placeholder: {},
|
|
363
383
|
apiRequest: {},
|
|
364
384
|
minLength: { default: 0 },
|
|
365
385
|
useCache: { type: Boolean },
|
|
366
386
|
appendSearchToResult: { type: Boolean },
|
|
387
|
+
multiselect: { type: Boolean },
|
|
367
388
|
appendAllValue: { type: Boolean },
|
|
368
389
|
addChanger: { type: Boolean },
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
showSearch: { type: Boolean, default: !0 }
|
|
390
|
+
buttonProps: {},
|
|
391
|
+
selectedAsPlaceholder: { type: Boolean }
|
|
372
392
|
}, {
|
|
373
393
|
modelValue: { required: !0 },
|
|
374
394
|
modelModifiers: {}
|
|
375
395
|
}),
|
|
376
396
|
emits: ["update:modelValue"],
|
|
377
|
-
setup(
|
|
378
|
-
const
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
397
|
+
setup(l) {
|
|
398
|
+
const t = l, s = J(l, "modelValue"), o = P(() => t.searchType === "inline" && t.multiselect || t.searchType === "inline" && Q.state.isMobile ? "popup" : t.searchType);
|
|
399
|
+
let p = 0;
|
|
400
|
+
o.value === "inline" && t.minLength && (p = t.minLength);
|
|
401
|
+
const a = Ie(t.apiRequest, p, t.useCache), r = Be(
|
|
402
|
+
s,
|
|
403
|
+
O(t, "items"),
|
|
404
|
+
t.multiselect,
|
|
405
|
+
O(t, "appendAllValue"),
|
|
406
|
+
O(t, "appendSearchToResult"),
|
|
407
|
+
o,
|
|
408
|
+
p,
|
|
409
|
+
a
|
|
410
|
+
), c = P(() => t.buttonProps ? "TopButton" : o.value === "inline" ? "TopInput" : "div"), f = _(null), T = () => {
|
|
411
|
+
var e;
|
|
412
|
+
return (e = f.value) == null ? void 0 : e.popup;
|
|
413
|
+
};
|
|
414
|
+
a.apiRequest && E(r.searchText, () => {
|
|
415
|
+
var e;
|
|
416
|
+
a.setSearchTextAndLoad(r.searchText.value), o.value === "inline" && r.genIsShort() && ((e = T()) == null || e.close());
|
|
417
|
+
}), E(s, () => {
|
|
418
|
+
o.value === "inline" && r.resetSearch();
|
|
419
|
+
});
|
|
420
|
+
const u = P(() => {
|
|
421
|
+
var e;
|
|
422
|
+
return Array.isArray(s.value) || t.multiselect || !t.selectedAsPlaceholder && o.value !== "inline" ? t.placeholder : ((e = s.value) == null ? void 0 : e.name) || t.placeholder;
|
|
423
|
+
}), b = (e) => {
|
|
424
|
+
var m, k;
|
|
425
|
+
let n = !1;
|
|
426
|
+
switch (e.key) {
|
|
427
|
+
case "Delete":
|
|
428
|
+
case "Backspace":
|
|
429
|
+
Array.isArray(s.value) && (e.preventDefault(), e.stopPropagation(), s.value.pop());
|
|
430
|
+
break;
|
|
431
|
+
case "ArrowUp":
|
|
432
|
+
case "ArrowRight":
|
|
433
|
+
case "ArrowDown":
|
|
434
|
+
case "ArrowLeft":
|
|
435
|
+
case "Enter":
|
|
436
|
+
case " ":
|
|
437
|
+
n = !0;
|
|
438
|
+
break;
|
|
439
|
+
case "Escape":
|
|
440
|
+
o.value === "inline" && r.resetSearch();
|
|
441
|
+
break;
|
|
442
|
+
}
|
|
443
|
+
const g = e.key.length === 1 && !e.ctrlKey && !e.metaKey;
|
|
444
|
+
(o.value === "popup" || o.value === "inline") && g && (n = !0), (m = T()) != null && m.elPopup && (n = !1), n && (o.value === "popup" && (e.preventDefault(), e.stopPropagation(), g && (r.searchText.value || (r.searchText.value = e.key))), (k = e.currentTarget) == null || k.click());
|
|
445
|
+
};
|
|
446
|
+
let i = !1;
|
|
447
|
+
const C = (e) => {
|
|
448
|
+
var n;
|
|
449
|
+
i || o.value === "inline" && ((n = e.currentTarget) == null || n.click());
|
|
450
|
+
}, M = (e) => {
|
|
451
|
+
var n, g;
|
|
452
|
+
e.preventDefault(), i = !0, (g = (n = e.currentTarget) == null ? void 0 : n.parentElement) == null || g.focus(), i = !1, r.selectNextItem();
|
|
453
|
+
}, K = () => {
|
|
454
|
+
var e;
|
|
455
|
+
if (i = !0, a.apiRequest) {
|
|
456
|
+
if (r.genIsShort()) {
|
|
457
|
+
(e = T()) == null || e.close();
|
|
458
|
+
return;
|
|
459
|
+
}
|
|
460
|
+
a.setSearchTextAndLoad(r.searchText.value, !1);
|
|
385
461
|
}
|
|
386
|
-
},
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
i.value && n.setSearchTextAndLoad(t.searchText.value, !1);
|
|
394
|
-
}), E(t.searchText, () => n.setSearchTextAndLoad(t.searchText.value)));
|
|
395
|
-
const m = (l) => {
|
|
396
|
-
o.multiselect && Array.isArray(e.value) ? J(e.value, l) || (e.value = [...e.value, l]) : e.value = l;
|
|
397
|
-
}, r = () => {
|
|
398
|
-
var l;
|
|
399
|
-
i.value = !1, (l = a.value) == null || l.focus(), t.searchText.value && t.resetSearch();
|
|
400
|
-
}, v = (l) => {
|
|
401
|
-
const u = l.target;
|
|
402
|
-
u.scrollTop / (u.scrollHeight - u.offsetHeight) > 0.8 && n.loadAppend();
|
|
462
|
+
}, Y = () => {
|
|
463
|
+
setTimeout(() => {
|
|
464
|
+
i = !1;
|
|
465
|
+
}, 100), o.value === "popup" && r.searchText.value && r.resetSearch();
|
|
466
|
+
}, h = (e) => {
|
|
467
|
+
const n = e.target;
|
|
468
|
+
n.scrollTop / (n.scrollHeight - n.offsetHeight) > 0.8 && a.loadAppend();
|
|
403
469
|
};
|
|
404
|
-
return window.__STORYBOOK_PREVIEW__ &&
|
|
405
|
-
() =>
|
|
470
|
+
return window.__STORYBOOK_PREVIEW__ && (E(
|
|
471
|
+
() => t.multiselect,
|
|
406
472
|
() => {
|
|
407
|
-
|
|
473
|
+
t.multiselect ? Array.isArray(s.value) || (s.value = [
|
|
474
|
+
{
|
|
475
|
+
id: 1,
|
|
476
|
+
name: "Выбери меня"
|
|
477
|
+
}
|
|
478
|
+
]) : Array.isArray(s.value) && (s.value = {
|
|
479
|
+
id: null,
|
|
480
|
+
name: ""
|
|
481
|
+
});
|
|
408
482
|
},
|
|
409
483
|
{ immediate: !0 }
|
|
410
|
-
), (
|
|
411
|
-
|
|
412
|
-
|
|
484
|
+
), E(
|
|
485
|
+
() => t.searchType,
|
|
486
|
+
() => {
|
|
487
|
+
setTimeout(() => {
|
|
488
|
+
location.reload();
|
|
489
|
+
}, 500);
|
|
490
|
+
}
|
|
491
|
+
)), (e, n) => {
|
|
492
|
+
const g = oe("top-focus");
|
|
493
|
+
return d(), w(v(de), {
|
|
413
494
|
ref_key: "popupRef",
|
|
414
|
-
ref:
|
|
415
|
-
onOpen:
|
|
416
|
-
onClose:
|
|
417
|
-
onScrollContentList:
|
|
495
|
+
ref: f,
|
|
496
|
+
onOpen: n[3] || (n[3] = (m) => K()),
|
|
497
|
+
onClose: n[4] || (n[4] = (m) => Y()),
|
|
498
|
+
onScrollContentList: n[5] || (n[5] = (m) => e.apiRequest ? h(m) : void 0),
|
|
418
499
|
notch: !1,
|
|
419
500
|
transitionDuration: 0
|
|
420
|
-
},
|
|
501
|
+
}, U({
|
|
421
502
|
opener: V(() => [
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
class: C({
|
|
503
|
+
q((d(), w(le(c.value), R(e.buttonProps, {
|
|
504
|
+
ref: "subcomponentSelector",
|
|
505
|
+
class: {
|
|
426
506
|
"top-selector2": !0,
|
|
427
|
-
"top-selector2-multiselect":
|
|
428
|
-
|
|
429
|
-
"top-
|
|
430
|
-
"top-
|
|
431
|
-
"top-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
507
|
+
"top-selector2-multiselect": e.multiselect,
|
|
508
|
+
"top-as-input": !e.buttonProps,
|
|
509
|
+
"top-as-selector": !0,
|
|
510
|
+
["top-size_" + e.size]: !0,
|
|
511
|
+
"top-disabled": e.disabled,
|
|
512
|
+
"top-forms-focusable": !e.disabled,
|
|
513
|
+
"top-error": e.isError
|
|
514
|
+
},
|
|
515
|
+
tabindex: "0",
|
|
516
|
+
onKeydown: b,
|
|
517
|
+
placeholder: u.value,
|
|
518
|
+
modelValue: v(r).searchText.value,
|
|
519
|
+
"onUpdate:modelValue": n[0] || (n[0] = (m) => v(r).searchText.value = m),
|
|
520
|
+
onFocus: C,
|
|
521
|
+
onBlur: n[1] || (n[1] = (m) => {
|
|
522
|
+
var k;
|
|
523
|
+
return (k = T()) != null && k.isClosed ? v(r).resetSearch() : "";
|
|
524
|
+
})
|
|
525
|
+
}), {
|
|
526
|
+
default: V(() => [
|
|
527
|
+
e.multiselect ? (d(), y("div", Se, [
|
|
528
|
+
(d(!0), y(z, null, F(s.value, (m) => (d(), w(we, {
|
|
529
|
+
id: m.id,
|
|
530
|
+
name: m.name,
|
|
531
|
+
onDelete: v(r).deleteItemById
|
|
532
|
+
}, null, 8, ["id", "name", "onDelete"]))), 256))
|
|
533
|
+
])) : A("", !0),
|
|
534
|
+
o.value !== "inline" && !e.multiselect ? (d(), y("span", Le, $(Array.isArray(s.value) ? "" : s.value.name), 1)) : A("", !0),
|
|
535
|
+
e.multiselect && !s.value.length ? (d(), y("span", Ee, $(u.value), 1)) : A("", !0),
|
|
536
|
+
e.addChanger && !e.buttonProps && !e.multiselect && v(r).items.value.length > 1 && !e.disabled ? (d(), y("span", {
|
|
537
|
+
key: 3,
|
|
538
|
+
class: "top-changer top-changer-selector top-popup_widget",
|
|
539
|
+
"data-top-popup-disabled": "true",
|
|
540
|
+
onClick: M
|
|
541
|
+
})) : A("", !0)
|
|
542
|
+
]),
|
|
543
|
+
_: 1
|
|
544
|
+
}, 16, ["class", "placeholder", "modelValue"])), [
|
|
454
545
|
[
|
|
455
|
-
|
|
456
|
-
|
|
546
|
+
g,
|
|
547
|
+
e.isError,
|
|
457
548
|
void 0,
|
|
458
549
|
{ onupdate: !0 }
|
|
459
550
|
]
|
|
460
551
|
])
|
|
461
552
|
]),
|
|
462
553
|
contentList: V(() => {
|
|
463
|
-
var
|
|
554
|
+
var m;
|
|
464
555
|
return [
|
|
465
|
-
(
|
|
466
|
-
class:
|
|
467
|
-
"top-active": !Array.isArray(
|
|
556
|
+
(d(!0), y(z, null, F(v(r).itemsForShow.value, (k) => (d(), w(v(H), {
|
|
557
|
+
class: I({
|
|
558
|
+
"top-active": !Array.isArray(s.value) && !e.multiselect && s.value.id === k.id && s.value.name === k.name
|
|
468
559
|
}),
|
|
469
|
-
key:
|
|
470
|
-
closeByClick: !
|
|
471
|
-
onClick: (
|
|
560
|
+
key: k.id ?? void 0,
|
|
561
|
+
closeByClick: !e.multiselect || v(Q).state.isMobile,
|
|
562
|
+
onClick: (He) => v(r).selectItem(k)
|
|
472
563
|
}, {
|
|
473
564
|
default: V(() => [
|
|
474
|
-
|
|
565
|
+
e.$slots.item ? W(e.$slots, "item", {
|
|
475
566
|
key: 0,
|
|
476
|
-
item:
|
|
477
|
-
}) : (
|
|
478
|
-
S($(
|
|
567
|
+
item: k
|
|
568
|
+
}) : (d(), y(z, { key: 1 }, [
|
|
569
|
+
S($(k.name), 1)
|
|
479
570
|
], 64))
|
|
480
571
|
]),
|
|
481
572
|
_: 2
|
|
482
573
|
}, 1032, ["class", "closeByClick", "onClick"]))), 128)),
|
|
483
|
-
!
|
|
574
|
+
!v(a).isLoading.value && !v(r).itemsForShow.value.length ? (d(), w(v(H), {
|
|
484
575
|
key: 0,
|
|
485
576
|
type: "regular"
|
|
486
577
|
}, {
|
|
487
578
|
default: V(() => [
|
|
488
|
-
S($(
|
|
579
|
+
S($(e.$i18n.Common.No_results), 1)
|
|
489
580
|
]),
|
|
490
581
|
_: 1
|
|
491
|
-
})) :
|
|
492
|
-
|
|
582
|
+
})) : A("", !0),
|
|
583
|
+
v(a).isLoading.value && (e.searchType !== "popup" || (m = e.apiRequest) != null && m.params.offset) ? (d(), w(v(H), {
|
|
493
584
|
key: 1,
|
|
494
585
|
type: "regular"
|
|
495
586
|
}, {
|
|
496
587
|
default: V(() => [
|
|
497
|
-
|
|
588
|
+
D(v(ie), { type: "circles" })
|
|
498
589
|
]),
|
|
499
590
|
_: 1
|
|
500
|
-
})) :
|
|
591
|
+
})) : A("", !0)
|
|
501
592
|
];
|
|
502
593
|
}),
|
|
503
594
|
_: 2
|
|
504
595
|
}, [
|
|
505
|
-
|
|
596
|
+
o.value === "popup" ? {
|
|
506
597
|
name: "widget",
|
|
507
598
|
fn: V(() => {
|
|
508
|
-
var
|
|
599
|
+
var m;
|
|
509
600
|
return [
|
|
510
|
-
|
|
601
|
+
D(v(pe), {
|
|
511
602
|
title: "Поиск",
|
|
512
603
|
icon: "",
|
|
513
|
-
modelValue:
|
|
514
|
-
"onUpdate:modelValue":
|
|
515
|
-
isLoading:
|
|
516
|
-
placeholder:
|
|
604
|
+
modelValue: v(r).searchText.value,
|
|
605
|
+
"onUpdate:modelValue": n[2] || (n[2] = (k) => v(r).searchText.value = k),
|
|
606
|
+
isLoading: v(a).isLoading.value && !((m = e.apiRequest) != null && m.params.offset),
|
|
607
|
+
placeholder: u.value
|
|
517
608
|
}, null, 8, ["modelValue", "isLoading", "placeholder"])
|
|
518
609
|
];
|
|
519
610
|
}),
|
|
@@ -522,41 +613,73 @@ const ie = { class: "top-editArea_footer" }, ue = /* @__PURE__ */ B({
|
|
|
522
613
|
]), 1536);
|
|
523
614
|
};
|
|
524
615
|
}
|
|
525
|
-
}),
|
|
616
|
+
}), Me = ["data-top-icon"], Ke = { class: "top-info_text" }, ze = {
|
|
526
617
|
key: 0,
|
|
527
618
|
class: "top-info_value"
|
|
528
|
-
},
|
|
619
|
+
}, De = /* @__PURE__ */ L({
|
|
529
620
|
__name: "info",
|
|
530
621
|
props: {
|
|
531
622
|
icon: {},
|
|
532
623
|
styling: { default: "default" },
|
|
533
624
|
size: { default: "default" }
|
|
534
625
|
},
|
|
535
|
-
setup(
|
|
536
|
-
return (
|
|
537
|
-
class:
|
|
626
|
+
setup(l) {
|
|
627
|
+
return (t, s) => (d(), y("div", {
|
|
628
|
+
class: I({
|
|
538
629
|
"top-info": !0,
|
|
539
|
-
["top-size_" +
|
|
540
|
-
["top-info-styling_" +
|
|
630
|
+
["top-size_" + t.size]: !0,
|
|
631
|
+
["top-info-styling_" + t.styling]: !0
|
|
541
632
|
}),
|
|
542
|
-
"data-top-icon":
|
|
633
|
+
"data-top-icon": t.icon
|
|
543
634
|
}, [
|
|
544
|
-
|
|
545
|
-
|
|
635
|
+
B("div", Ke, [
|
|
636
|
+
W(t.$slots, "default")
|
|
546
637
|
]),
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
])) :
|
|
550
|
-
], 10,
|
|
638
|
+
t.$slots.additional ? (d(), y("span", ze, [
|
|
639
|
+
W(t.$slots, "additional")
|
|
640
|
+
])) : A("", !0)
|
|
641
|
+
], 10, Me));
|
|
642
|
+
}
|
|
643
|
+
}), Oe = {
|
|
644
|
+
key: 0,
|
|
645
|
+
class: "top-policy"
|
|
646
|
+
}, Ge = { class: "top-policy_title" }, Ne = ["innerHTML"], Fe = /* @__PURE__ */ L({
|
|
647
|
+
__name: "policy",
|
|
648
|
+
props: {
|
|
649
|
+
title: {},
|
|
650
|
+
text: {}
|
|
651
|
+
},
|
|
652
|
+
setup(l) {
|
|
653
|
+
const t = _(!0), s = () => {
|
|
654
|
+
const o = location.hostname.split(".").slice(-2).join(".");
|
|
655
|
+
document.cookie = `cookie_consent=accepted; path=/; domain=.${o}; max-age=31536000`, t.value = !1;
|
|
656
|
+
};
|
|
657
|
+
return (o, p) => t.value ? (d(), y("div", Oe, [
|
|
658
|
+
B("div", Ge, $(o.title), 1),
|
|
659
|
+
B("div", {
|
|
660
|
+
class: "top-policy_description",
|
|
661
|
+
innerHTML: o.text
|
|
662
|
+
}, null, 8, Ne),
|
|
663
|
+
D(v(ue), {
|
|
664
|
+
size: "m",
|
|
665
|
+
onClick: s
|
|
666
|
+
}, {
|
|
667
|
+
default: V(() => [
|
|
668
|
+
S($(o.$i18n.Common.Allow), 1)
|
|
669
|
+
]),
|
|
670
|
+
_: 1
|
|
671
|
+
})
|
|
672
|
+
])) : A("", !0);
|
|
551
673
|
}
|
|
552
|
-
}),
|
|
674
|
+
}), Ye = ve, Qe = he, Ze = Te, qe = $e, xe = Pe, et = fe, tt = De, ot = Fe;
|
|
553
675
|
export {
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
676
|
+
qe as TopCheckboxGroup,
|
|
677
|
+
Ye as TopEditArea,
|
|
678
|
+
Qe as TopEditInput,
|
|
679
|
+
tt as TopInfo,
|
|
680
|
+
et as TopMenu,
|
|
681
|
+
ot as TopPolicy,
|
|
682
|
+
Ze as TopRadioGroup,
|
|
683
|
+
xe as TopSelector2
|
|
561
684
|
};
|
|
562
685
|
//# sourceMappingURL=formsExt.js.map
|