@topvisor/ui 1.0.8 → 1.0.9-fix-css
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/datepicker-Cs3C14z5.amd.js +248 -0
- package/.chunks/datepicker-Cs3C14z5.amd.js.map +1 -0
- package/.chunks/datepicker-LNkS97nF.es.js +290 -0
- package/.chunks/datepicker-LNkS97nF.es.js.map +1 -0
- package/.chunks/forms-BydHEF-k.es.js +1928 -0
- package/.chunks/forms-BydHEF-k.es.js.map +1 -0
- package/.chunks/forms-Cq5zFLsO.amd.js +3 -0
- package/.chunks/forms-Cq5zFLsO.amd.js.map +1 -0
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-B0xTxYZR.amd.js +2 -0
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-B0xTxYZR.amd.js.map +1 -0
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-DinMn3Ud.es.js +174 -0
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-DinMn3Ud.es.js.map +1 -0
- package/.chunks/menu.vue_vue_type_style_index_0_lang-BT-PgdJ5.amd.js +2 -0
- package/.chunks/menu.vue_vue_type_style_index_0_lang-BT-PgdJ5.amd.js.map +1 -0
- package/.chunks/menu.vue_vue_type_style_index_0_lang-C585WUlJ.es.js +109 -0
- package/.chunks/menu.vue_vue_type_style_index_0_lang-C585WUlJ.es.js.map +1 -0
- package/.chunks/{popup-D-G2sXks.es.js → popup-B7AaTfNZ.es.js} +494 -493
- package/.chunks/popup-B7AaTfNZ.es.js.map +1 -0
- package/.chunks/popup-D22VHVHf.amd.js +448 -0
- package/.chunks/popup-D22VHVHf.amd.js.map +1 -0
- package/.chunks/store-CX_6ZXhO.es.js.map +1 -1
- package/.chunks/store-esTid5oI.amd.js.map +1 -1
- package/README.md +86 -86
- package/assets/charts.css +1 -0
- package/assets/core.css +1 -1
- package/assets/forms.css +1 -1
- package/assets/project.css +1 -1
- package/assets/tabsView.css +1 -1
- package/assets/themes/dark.css +1 -1
- package/assets/themes/light.css +1 -1
- package/charts/charts.amd.js +2 -0
- package/charts/charts.amd.js.map +1 -0
- package/charts/charts.d.ts +2 -0
- package/charts/charts.js +120 -0
- package/charts/charts.js.map +1 -0
- package/components/charts/charts.d.ts +3 -0
- package/components/charts/miniChart/miniChart.d.ts +80 -0
- package/components/charts/miniChart/miniChart.vue.d.ts +15 -0
- package/components/charts/miniChart/stories/dummy.d.ts +13 -0
- package/components/charts/miniChart/utils/consts.d.ts +8 -0
- package/components/formsExt/selector2/selector2.vue.d.ts +16 -20
- package/components/popup/alert/alert.vue.d.ts +8 -7
- package/components/popup/confirm/confirm.d.ts +1 -1
- package/components/popup/confirm/confirm.vue.d.ts +8 -7
- package/components/popup/lib/popup.d.ts +1 -1
- package/components/popup/popup/popup.d.ts +8 -4
- package/components/popup/popup/popup.vue.d.ts +8 -8
- package/components/popup/prompt/prompt.d.ts +1 -1
- package/components/popup/prompt/prompt.vue.d.ts +8 -7
- package/components/project/project.d.ts +9 -0
- package/components/project/tagSelector/popupListItem/tagPopupListItem.vue.d.ts +18 -0
- package/components/project/tagSelector/popupListItem/types.d.ts +33 -0
- package/components/project/tagSelector/popupOpener/popupOpener.vue.d.ts +26 -0
- package/components/project/tagSelector/popupOpener/types.d.ts +62 -0
- package/components/project/tagSelector/tagIcon/tagIcon.vue.d.ts +4 -0
- package/components/project/tagSelector/tagIcon/types.d.ts +21 -0
- package/components/project/tagSelector/tagSelector.vue.d.ts +37 -0
- package/components/project/tagSelector/tagsDefaults.d.ts +3 -0
- package/components/project/tagSelector/types.d.ts +138 -0
- package/components/project/tagSelector/utils/el.d.ts +19 -0
- package/components/project/tagSelector/utils/utils.d.ts +14 -0
- package/core/app.amd.js +1 -1
- package/core/app.amd.js.map +1 -1
- package/core/app.js +52 -45
- package/core/app.js.map +1 -1
- package/core/core/core.d.ts +4 -0
- package/core/directives/data.d.ts +10 -0
- package/core/utils/route.d.ts +1 -1
- package/forms/forms.amd.js +1 -1
- package/forms/forms.js +5 -5
- package/forms/helpers.amd.js.map +1 -1
- package/forms/helpers.js.map +1 -1
- package/formsExt/formsExt.amd.js +1 -1
- package/formsExt/formsExt.amd.js.map +1 -1
- package/formsExt/formsExt.js +121 -166
- package/formsExt/formsExt.js.map +1 -1
- package/icomoon/Read Me.txt +7 -7
- package/icomoon/Topvisor icons.json +5845 -5845
- package/icomoon/demo-files/demo.css +161 -161
- package/icomoon/demo-files/demo.js +30 -30
- package/icomoon/demo.html +3379 -3379
- package/icomoon/fonts/Topvisor-2.svg +263 -263
- package/icomoon/style.css +740 -740
- package/package.json +37 -37
- package/popup/popup.amd.js +1 -1
- package/popup/popup.amd.js.map +1 -1
- package/popup/popup.js +103 -108
- package/popup/popup.js.map +1 -1
- package/popup/worker.amd.js +1 -1
- package/popup/worker.amd.js.map +1 -1
- package/popup/worker.js +2 -2
- 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 +814 -262
- package/project/project.js.map +1 -1
- package/require/css.amd.js +12 -12
- package/tabs/tabs.amd.js +1 -1
- package/tabs/tabs.amd.js.map +1 -1
- package/tabs/tabs.js +41 -59
- package/tabs/tabs.js.map +1 -1
- package/tabsView/tabsView.amd.js +1 -1
- package/tabsView/tabsView.amd.js.map +1 -1
- package/tabsView/tabsView.js +144 -183
- package/tabsView/tabsView.js.map +1 -1
- package/utils/check.amd.js +1 -1
- package/utils/check.amd.js.map +1 -1
- package/utils/check.js +1 -1
- package/utils/check.js.map +1 -1
- package/utils/clipboard.amd.js.map +1 -1
- package/utils/clipboard.js.map +1 -1
- package/utils/date.amd.js +1 -1
- package/utils/date.js +1 -1
- package/utils/device.amd.js +1 -1
- package/utils/device.js +1 -1
- package/utils/dom.amd.js.map +1 -1
- package/utils/dom.js.map +1 -1
- package/utils/image.amd.js.map +1 -1
- package/utils/image.js.map +1 -1
- package/utils/keyboard.amd.js.map +1 -1
- package/utils/keyboard.js.map +1 -1
- package/utils/lodash.amd.js +1 -1
- package/utils/lodash.js +5 -5
- package/utils/number.amd.js.map +1 -1
- package/utils/number.js.map +1 -1
- package/utils/price.amd.js +1 -1
- package/utils/price.amd.js.map +1 -1
- package/utils/price.js +1 -1
- package/utils/price.js.map +1 -1
- package/utils/route.amd.js +1 -1
- package/utils/route.amd.js.map +1 -1
- package/utils/route.js +15 -15
- package/utils/route.js.map +1 -1
- package/utils/scroll.amd.js.map +1 -1
- package/utils/scroll.js.map +1 -1
- package/utils/searchers.amd.js.map +1 -1
- package/utils/searchers.js.map +1 -1
- package/utils/string.amd.js +1 -1
- package/utils/string.amd.js.map +1 -1
- package/utils/string.js +1 -1
- package/utils/string.js.map +1 -1
- package/utils/system.amd.js.map +1 -1
- package/utils/system.js.map +1 -1
- package/utils/url.amd.js.map +1 -1
- package/utils/url.js.map +1 -1
- package/web-types.json +89 -72
- package/.chunks/datepicker-CRfiJCmp.amd.js +0 -248
- package/.chunks/datepicker-CRfiJCmp.amd.js.map +0 -1
- package/.chunks/datepicker-CugKFVIH.es.js +0 -290
- package/.chunks/datepicker-CugKFVIH.es.js.map +0 -1
- package/.chunks/forms-CHiMZ8vg.es.js +0 -2015
- package/.chunks/forms-CHiMZ8vg.es.js.map +0 -1
- package/.chunks/forms-CjYoXTEQ.amd.js +0 -3
- package/.chunks/forms-CjYoXTEQ.amd.js.map +0 -1
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-Bb7B8CTJ.es.js +0 -174
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-Bb7B8CTJ.es.js.map +0 -1
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-CEF3WDJ_.amd.js +0 -2
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-CEF3WDJ_.amd.js.map +0 -1
- package/.chunks/menu-CHeV29rC.es.js +0 -118
- package/.chunks/menu-CHeV29rC.es.js.map +0 -1
- package/.chunks/menu-D1lnYuWU.amd.js +0 -2
- package/.chunks/menu-D1lnYuWU.amd.js.map +0 -1
- package/.chunks/popup-C4Tne4qA.amd.js +0 -447
- package/.chunks/popup-C4Tne4qA.amd.js.map +0 -1
- package/.chunks/popup-D-G2sXks.es.js.map +0 -1
- package/.chunks/utils-BOlUthaH.es.js +0 -91
- package/.chunks/utils-BOlUthaH.es.js.map +0 -1
- package/.chunks/utils-x88W55mf.amd.js +0 -2
- package/.chunks/utils-x88W55mf.amd.js.map +0 -1
- package/components/project/utils.d.ts +0 -1
- package/core/core.amd.js +0 -2
- package/core/core.amd.js.map +0 -1
- package/core/core.d.ts +0 -4
- package/core/core.js +0 -6
- package/core/core.js.map +0 -1
- package/project/utils.amd.js +0 -2
- package/project/utils.amd.js.map +0 -1
- package/project/utils.d.ts +0 -2
- package/project/utils.js +0 -6
- package/project/utils.js.map +0 -1
- package/test/themes/themes/dark-positions.amd.js +0 -2
- package/test/themes/themes/dark-positions.amd.js.map +0 -1
- package/test/themes/themes/dark-positions.d.ts +0 -1
- package/test/themes/themes/dark-positions.js +0 -2
- package/test/themes/themes/dark-positions.js.map +0 -1
- package/test/themes/themes/dark.amd.js +0 -2
- package/test/themes/themes/dark.amd.js.map +0 -1
- package/test/themes/themes/dark.d.ts +0 -1
- package/test/themes/themes/dark.js +0 -4
- package/test/themes/themes/dark.js.map +0 -1
- package/test/themes/themes/light-positions.amd.js +0 -2
- package/test/themes/themes/light-positions.amd.js.map +0 -1
- package/test/themes/themes/light-positions.d.ts +0 -1
- package/test/themes/themes/light-positions.js +0 -2
- package/test/themes/themes/light-positions.js.map +0 -1
- package/test/themes/themes/light.amd.js +0 -2
- package/test/themes/themes/light.amd.js.map +0 -1
- package/test/themes/themes/light.d.ts +0 -1
- package/test/themes/themes/light.js +0 -4
- package/test/themes/themes/light.js.map +0 -1
package/formsExt/formsExt.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { defineComponent as
|
|
3
|
-
import { w as
|
|
4
|
-
import { invertKeyboardLayout as
|
|
5
|
-
import { TopPopup as
|
|
6
|
-
import {
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
const
|
|
1
|
+
import { Core as j } from "../core/app.js";
|
|
2
|
+
import { defineComponent as P, ref as T, computed as N, resolveDirective as Z, openBlock as c, createElementBlock as v, normalizeClass as S, toDisplayString as B, createCommentVNode as A, createElementVNode as K, withDirectives as X, createVNode as H, withKeys as _, withModifiers as I, createBlock as k, withCtx as C, createTextVNode as $, watch as E, toRef as q, mergeProps as J, mergeModels as z, useModel as Y, Fragment as O, renderList as G, vModelRadio as x, unref as L, renderSlot as ee } from "vue";
|
|
3
|
+
import { w as te, _ as D, c as oe, s as le, C as ae } from "../.chunks/forms-BydHEF-k.es.js";
|
|
4
|
+
import { invertKeyboardLayout as se } from "../utils/keyboard.js";
|
|
5
|
+
import { TopPopup as re, TopPopupWidgetInput as ne, TopPopupListItem as R } from "../popup/popup.js";
|
|
6
|
+
import { _ as ie } from "../.chunks/menu.vue_vue_type_style_index_0_lang-C585WUlJ.es.js";
|
|
7
|
+
const Q = ["../assets/formsExt.css"].map((r) => import.meta.resolve(r));
|
|
8
|
+
j.insertCSSLinkToPage(Q, !0);
|
|
9
|
+
const ue = { class: "top-editArea_footer" }, de = /* @__PURE__ */ P({
|
|
10
10
|
__name: "editArea",
|
|
11
11
|
props: {
|
|
12
12
|
defaultValue: { default: "" },
|
|
@@ -30,7 +30,7 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
30
30
|
},
|
|
31
31
|
emits: ["submit", "close", "clickOnTitle"],
|
|
32
32
|
setup(r, { emit: d }) {
|
|
33
|
-
const e = r, a = d, m =
|
|
33
|
+
const e = r, a = d, m = T(e.defaultValue), f = T(e.isFocused), n = N(() => m.value !== e.defaultValue), p = N(() => e.attachToKeyboard ? "" : e.forceShowCloseBtn && !n.value ? e.closeText : e.cancelText), i = (u) => {
|
|
34
34
|
a("submit", u), m.value = e.defaultValue;
|
|
35
35
|
}, y = () => {
|
|
36
36
|
if (e.forceShowCloseBtn && !n.value) {
|
|
@@ -42,9 +42,9 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
42
42
|
e.attachToKeyboard && a("clickOnTitle");
|
|
43
43
|
};
|
|
44
44
|
return (u, o) => {
|
|
45
|
-
const
|
|
45
|
+
const V = Z("top-focus");
|
|
46
46
|
return c(), v("div", {
|
|
47
|
-
class:
|
|
47
|
+
class: S({
|
|
48
48
|
"top-editArea": !0,
|
|
49
49
|
"top-editArea-attachedToKeyboard": u.attachToKeyboard
|
|
50
50
|
})
|
|
@@ -53,15 +53,15 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
53
53
|
key: 0,
|
|
54
54
|
class: "top-editArea_title",
|
|
55
55
|
onClick: o[0] || (o[0] = (h) => b())
|
|
56
|
-
},
|
|
57
|
-
|
|
58
|
-
class:
|
|
56
|
+
}, B(u.title), 1)) : A("", !0),
|
|
57
|
+
K("div", {
|
|
58
|
+
class: S({
|
|
59
59
|
"top-editArea_form": !0,
|
|
60
60
|
"top-error": u.isError,
|
|
61
61
|
"top-focus": f.value
|
|
62
62
|
})
|
|
63
63
|
}, [
|
|
64
|
-
|
|
64
|
+
X(H(te, {
|
|
65
65
|
modelValue: m.value,
|
|
66
66
|
"onUpdate:modelValue": o[1] || (o[1] = (h) => m.value = h),
|
|
67
67
|
name: u.name,
|
|
@@ -77,14 +77,14 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
77
77
|
onFocus: o[2] || (o[2] = () => f.value = !0),
|
|
78
78
|
onBlur: o[3] || (o[3] = () => f.value = !1),
|
|
79
79
|
onKeyup: [
|
|
80
|
-
|
|
81
|
-
o[4] || (o[4] =
|
|
80
|
+
_(y, ["esc"]),
|
|
81
|
+
o[4] || (o[4] = _(I((h) => i(m.value), ["ctrl"]), ["enter"]))
|
|
82
82
|
]
|
|
83
83
|
}, null, 8, ["modelValue", "name", "placeholder", "rows", "minHeight", "expandable", "disabled", "readonly", "isError", "hint"]), [
|
|
84
|
-
[
|
|
84
|
+
[V, { disabled: !f.value }]
|
|
85
85
|
]),
|
|
86
|
-
|
|
87
|
-
n.value || u.forceShowCloseBtn ? (c(),
|
|
86
|
+
K("div", ue, [
|
|
87
|
+
n.value || u.forceShowCloseBtn ? (c(), k(D, {
|
|
88
88
|
key: 0,
|
|
89
89
|
class: "top-editArea_button",
|
|
90
90
|
color: "theme",
|
|
@@ -92,42 +92,28 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
92
92
|
icon: u.attachToKeyboard ? "" : "",
|
|
93
93
|
onClick: y
|
|
94
94
|
}, {
|
|
95
|
-
default:
|
|
96
|
-
B(
|
|
95
|
+
default: C(() => [
|
|
96
|
+
$(B(p.value), 1)
|
|
97
97
|
]),
|
|
98
98
|
_: 1
|
|
99
|
-
}, 8, ["icon"])) :
|
|
100
|
-
n.value ? (c(),
|
|
99
|
+
}, 8, ["icon"])) : A("", !0),
|
|
100
|
+
n.value ? (c(), k(D, {
|
|
101
101
|
key: 1,
|
|
102
102
|
class: "top-editArea_button",
|
|
103
103
|
icon: u.attachToKeyboard ? "" : "",
|
|
104
104
|
onClick: o[5] || (o[5] = (h) => i(m.value))
|
|
105
105
|
}, {
|
|
106
|
-
default:
|
|
107
|
-
B(
|
|
106
|
+
default: C(() => [
|
|
107
|
+
$(B(u.attachToKeyboard ? "" : u.submitText), 1)
|
|
108
108
|
]),
|
|
109
109
|
_: 1
|
|
110
|
-
}, 8, ["icon"])) :
|
|
110
|
+
}, 8, ["icon"])) : A("", !0)
|
|
111
111
|
])
|
|
112
112
|
], 2)
|
|
113
113
|
], 2);
|
|
114
114
|
};
|
|
115
115
|
}
|
|
116
|
-
}), ce = {
|
|
117
|
-
"top-editArea": "top-editArea",
|
|
118
|
-
"top-editArea_title": "top-editArea_title",
|
|
119
|
-
"top-editArea_form": "top-editArea_form",
|
|
120
|
-
"top-focus": "top-focus",
|
|
121
|
-
"top-textarea": "top-textarea",
|
|
122
|
-
"top-editArea_element": "top-editArea_element",
|
|
123
|
-
"top-textarea_textarea": "top-textarea_textarea",
|
|
124
|
-
"top-editArea_footer": "top-editArea_footer",
|
|
125
|
-
"top-editArea-attachedToKeyboard": "top-editArea-attachedToKeyboard",
|
|
126
|
-
"top-button": "top-button",
|
|
127
|
-
"top-editArea_button": "top-editArea_button"
|
|
128
|
-
}, me = {
|
|
129
|
-
$style: ce
|
|
130
|
-
}, fe = /* @__PURE__ */ K(pe, [["__cssModules", me]]), ve = { class: "top-editInput" }, ye = /* @__PURE__ */ L({
|
|
116
|
+
}), pe = { class: "top-editInput" }, ce = /* @__PURE__ */ P({
|
|
131
117
|
__name: "editInput",
|
|
132
118
|
props: {
|
|
133
119
|
modelValue: {},
|
|
@@ -136,38 +122,33 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
136
122
|
},
|
|
137
123
|
emits: ["update:modelValue"],
|
|
138
124
|
setup(r, { emit: d }) {
|
|
139
|
-
const e = r, a =
|
|
140
|
-
|
|
125
|
+
const e = r, a = T(e.modelValue);
|
|
126
|
+
E(q(e.modelValue), () => {
|
|
141
127
|
a.value = e.modelValue;
|
|
142
128
|
});
|
|
143
129
|
const m = d, f = () => {
|
|
144
130
|
m("update:modelValue", a.value);
|
|
145
131
|
};
|
|
146
|
-
return (n, p) => (c(), v("div",
|
|
147
|
-
|
|
148
|
-
onKeydownCapture: p[0] || (p[0] =
|
|
149
|
-
onKeydown:
|
|
132
|
+
return (n, p) => (c(), v("div", pe, [
|
|
133
|
+
H(oe, J(n.input, {
|
|
134
|
+
onKeydownCapture: p[0] || (p[0] = _(I((i) => a.value = n.modelValue, ["stop"]), ["esc"])),
|
|
135
|
+
onKeydown: _(I(f, ["stop"]), ["enter"]),
|
|
150
136
|
modelValue: a.value,
|
|
151
137
|
"onUpdate:modelValue": p[1] || (p[1] = (i) => a.value = i)
|
|
152
138
|
}), null, 16, ["onKeydown", "modelValue"]),
|
|
153
|
-
a.value !== n.modelValue ? (c(),
|
|
139
|
+
a.value !== n.modelValue ? (c(), k(D, J({
|
|
154
140
|
key: 0,
|
|
155
141
|
icon: "",
|
|
156
142
|
styling: "soft"
|
|
157
|
-
}, n.button, { onClick: f }), null, 16)) :
|
|
143
|
+
}, n.button, { onClick: f }), null, 16)) : A("", !0)
|
|
158
144
|
]));
|
|
159
145
|
}
|
|
160
|
-
}),
|
|
161
|
-
"top-editInput": "top-editInput",
|
|
162
|
-
"top-input": "top-input"
|
|
163
|
-
}, be = {
|
|
164
|
-
$style: he
|
|
165
|
-
}, Ae = /* @__PURE__ */ K(ye, [["__cssModules", be]]), ge = ["data-top-icon", "onClick"], Te = {
|
|
146
|
+
}), me = ["data-top-icon", "onClick"], fe = {
|
|
166
147
|
key: 0,
|
|
167
148
|
class: "top-radioGroup_circle"
|
|
168
|
-
},
|
|
149
|
+
}, ve = ["value", "disabled"], ye = /* @__PURE__ */ P({
|
|
169
150
|
__name: "radioGroup",
|
|
170
|
-
props: /* @__PURE__ */
|
|
151
|
+
props: /* @__PURE__ */ z({
|
|
171
152
|
modelValue: {},
|
|
172
153
|
radiosProps: {},
|
|
173
154
|
showIndicator: { type: Boolean },
|
|
@@ -179,10 +160,10 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
179
160
|
},
|
|
180
161
|
modelModifiers: {}
|
|
181
162
|
}),
|
|
182
|
-
emits: /* @__PURE__ */
|
|
163
|
+
emits: /* @__PURE__ */ z(["update:modelValue"], ["update:modelValue"]),
|
|
183
164
|
setup(r, { emit: d }) {
|
|
184
|
-
const e =
|
|
185
|
-
|
|
165
|
+
const e = Y(r, "modelValue"), a = r, m = T(null);
|
|
166
|
+
E(e, () => {
|
|
186
167
|
var n, p, i, y, b;
|
|
187
168
|
(n = a.radiosProps) != null && n.some((u) => u.value === e.value) || (e.value = ((i = (p = a.radiosProps) == null ? void 0 : p[0]) == null ? void 0 : i.value) ?? ""), (b = (y = m.value) == null ? void 0 : y.querySelector(".radioGroup_item-selected")) == null || b.scrollIntoView();
|
|
188
169
|
}, { immediate: !0 });
|
|
@@ -190,15 +171,15 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
190
171
|
return (n, p) => (c(), v("div", {
|
|
191
172
|
ref_key: "elRef",
|
|
192
173
|
ref: m,
|
|
193
|
-
class:
|
|
174
|
+
class: S({
|
|
194
175
|
"top-radioGroup": !0,
|
|
195
176
|
"top-scrollBarXHidding": !0,
|
|
196
177
|
["top-size_" + n.size]: !!n.size,
|
|
197
178
|
"top-error": n.isError
|
|
198
179
|
})
|
|
199
180
|
}, [
|
|
200
|
-
(c(!0), v(
|
|
201
|
-
class:
|
|
181
|
+
(c(!0), v(O, null, G(n.radiosProps, (i) => (c(), v("label", {
|
|
182
|
+
class: S({
|
|
202
183
|
"top-radioGroup_item-selected": i.value === e.value,
|
|
203
184
|
"top-radioGroup_item": !0,
|
|
204
185
|
"top-forms-focusable": !0,
|
|
@@ -207,53 +188,43 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
207
188
|
"data-top-icon": i.icon,
|
|
208
189
|
onClick: (y) => e.value = i.value
|
|
209
190
|
}, [
|
|
210
|
-
B(
|
|
211
|
-
n.showIndicator ? (c(), v("span",
|
|
212
|
-
|
|
191
|
+
$(B(i.title) + " ", 1),
|
|
192
|
+
n.showIndicator ? (c(), v("span", fe)) : A("", !0),
|
|
193
|
+
X(K("input", {
|
|
213
194
|
"onUpdate:modelValue": p[0] || (p[0] = (y) => e.value = y),
|
|
214
195
|
name: f,
|
|
215
196
|
type: "radio",
|
|
216
|
-
class:
|
|
197
|
+
class: S({
|
|
217
198
|
"top-unvisible": !0
|
|
218
199
|
}),
|
|
219
200
|
value: i.value,
|
|
220
201
|
disabled: i.disabled
|
|
221
|
-
}, null, 8,
|
|
222
|
-
[
|
|
202
|
+
}, null, 8, ve), [
|
|
203
|
+
[x, e.value]
|
|
223
204
|
])
|
|
224
|
-
], 10,
|
|
205
|
+
], 10, me))), 256))
|
|
225
206
|
], 2));
|
|
226
207
|
}
|
|
227
|
-
}),
|
|
228
|
-
|
|
229
|
-
"top-radioGroup": "top-radioGroup",
|
|
230
|
-
"top-radioGroup_item": "top-radioGroup_item",
|
|
231
|
-
"top-radioGroup_item-selected": "top-radioGroup_item-selected",
|
|
232
|
-
"top-radioGroup_circle": "top-radioGroup_circle",
|
|
233
|
-
"top-error": "top-error",
|
|
234
|
-
"top-disabled": "top-disabled"
|
|
235
|
-
}, Ce = {
|
|
236
|
-
$style: we
|
|
237
|
-
}, Ie = /* @__PURE__ */ K(_e, [["__cssModules", Ce]]), $e = (r, d, e) => {
|
|
238
|
-
const a = V([]), m = V(!1);
|
|
208
|
+
}), he = (r, d, e) => {
|
|
209
|
+
const a = T([]), m = T(!1);
|
|
239
210
|
let f = "", n;
|
|
240
211
|
r && !r.params.limit && (r.params.limit = 100);
|
|
241
212
|
const p = async () => {
|
|
242
213
|
if (!r) return;
|
|
243
|
-
let o,
|
|
244
|
-
if (e && (r.cache ??= /* @__PURE__ */ new Map(),
|
|
214
|
+
let o, V;
|
|
215
|
+
if (e && (r.cache ??= /* @__PURE__ */ new Map(), V = JSON.stringify(r.params), o = r.cache.get(V), o))
|
|
245
216
|
return o;
|
|
246
217
|
if (m.value = !0, o = await r.call(), m.value = !1, o.errors) return;
|
|
247
218
|
if (!Array.isArray(o.result)) {
|
|
248
219
|
console.warn("В result ожидался массив");
|
|
249
220
|
return;
|
|
250
221
|
}
|
|
251
|
-
const h = o.result.findIndex((
|
|
222
|
+
const h = o.result.findIndex((M) => M.id === void 0 || M.name === void 0);
|
|
252
223
|
if (h !== -1) {
|
|
253
224
|
console.warn(`В result[${h}] нет id или name`);
|
|
254
225
|
return;
|
|
255
226
|
}
|
|
256
|
-
return e && r.cache.set(
|
|
227
|
+
return e && r.cache.set(V, o), o;
|
|
257
228
|
}, i = async () => {
|
|
258
229
|
if (!r) return;
|
|
259
230
|
r.params.offset = 0, r.params.search = f;
|
|
@@ -264,16 +235,16 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
264
235
|
r.params.offset = n, r.params.search = f;
|
|
265
236
|
const o = await p();
|
|
266
237
|
o && (n = o.nextOffset, a.value = a.value.concat(o.result));
|
|
267
|
-
}, b =
|
|
238
|
+
}, b = le(() => i(), 200);
|
|
268
239
|
return {
|
|
269
240
|
items: a,
|
|
270
241
|
isLoading: m,
|
|
271
242
|
loadAppend: y,
|
|
272
|
-
setSearchTextAndLoad: (o,
|
|
273
|
-
r && (o.length < d || o === f && a.value.length || (f = o,
|
|
243
|
+
setSearchTextAndLoad: (o, V = !0) => {
|
|
244
|
+
r && (o.length < d || o === f && a.value.length || (f = o, V ? b() : i()));
|
|
274
245
|
}
|
|
275
246
|
};
|
|
276
|
-
},
|
|
247
|
+
}, be = { class: "top-selector2_itemMulti top-ellipsis" }, ge = /* @__PURE__ */ P({
|
|
277
248
|
__name: "itemMulti",
|
|
278
249
|
props: {
|
|
279
250
|
id: {},
|
|
@@ -281,33 +252,26 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
281
252
|
},
|
|
282
253
|
emits: ["delete"],
|
|
283
254
|
setup(r) {
|
|
284
|
-
return (d, e) => (c(), v("div",
|
|
285
|
-
B(
|
|
286
|
-
|
|
255
|
+
return (d, e) => (c(), v("div", be, [
|
|
256
|
+
$(B(d.name) + " ", 1),
|
|
257
|
+
K("span", {
|
|
287
258
|
class: "top-selector2_itemMultiDelete",
|
|
288
259
|
"data-top-icon": "",
|
|
289
260
|
onClick: e[0] || (e[0] = (a) => d.$emit("delete", d.id)),
|
|
290
|
-
onMousedown: e[1] || (e[1] =
|
|
261
|
+
onMousedown: e[1] || (e[1] = I(() => {
|
|
291
262
|
}, ["stop"]))
|
|
292
263
|
}, null, 32)
|
|
293
264
|
]));
|
|
294
265
|
}
|
|
295
|
-
}),
|
|
296
|
-
"top-selector2_itemMulti": "top-selector2_itemMulti",
|
|
297
|
-
"top-selector2_itemMultiDelete": "top-selector2_itemMultiDelete",
|
|
298
|
-
"top-selector2": "top-selector2",
|
|
299
|
-
"top-active": "top-active"
|
|
300
|
-
}, ke = {
|
|
301
|
-
$style: Me
|
|
302
|
-
}, Ee = /* @__PURE__ */ K(Be, [["__cssModules", ke]]), Le = {
|
|
266
|
+
}), Ve = {
|
|
303
267
|
key: 0,
|
|
304
268
|
class: "top-selector2_activeItems"
|
|
305
|
-
},
|
|
269
|
+
}, Ae = {
|
|
306
270
|
key: 1,
|
|
307
271
|
class: "top-selector2_activeName top-ellipsis"
|
|
308
|
-
},
|
|
272
|
+
}, Te = /* @__PURE__ */ P({
|
|
309
273
|
__name: "selector2",
|
|
310
|
-
props: /* @__PURE__ */
|
|
274
|
+
props: /* @__PURE__ */ z({
|
|
311
275
|
modelValue: {},
|
|
312
276
|
items: { default: () => [] },
|
|
313
277
|
multiselect: { type: Boolean },
|
|
@@ -328,42 +292,42 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
328
292
|
}),
|
|
329
293
|
emits: ["update:modelValue"],
|
|
330
294
|
setup(r) {
|
|
331
|
-
const d = r, e =
|
|
295
|
+
const d = r, e = Y(r, "modelValue"), a = T(""), m = {
|
|
332
296
|
id: 0,
|
|
333
297
|
name: "Все"
|
|
334
|
-
}, f =
|
|
298
|
+
}, f = T(null), n = () => {
|
|
335
299
|
var t;
|
|
336
300
|
return (t = f.value) == null ? void 0 : t.popup;
|
|
337
301
|
};
|
|
338
|
-
window.__STORYBOOK_PREVIEW__ && !d.modelValue &&
|
|
302
|
+
window.__STORYBOOK_PREVIEW__ && !d.modelValue && E(
|
|
339
303
|
() => d.multiselect,
|
|
340
304
|
() => {
|
|
341
305
|
e.value = d.multiselect ? [] : { id: null, name: "" };
|
|
342
306
|
},
|
|
343
307
|
{ immediate: !0 }
|
|
344
308
|
);
|
|
345
|
-
const p =
|
|
309
|
+
const p = he(d.apiRequest, d.minLength, d.useCache), i = N(() => {
|
|
346
310
|
const t = [];
|
|
347
311
|
return !d.multiselect && d.appendAllValue && t.push(m), d.items.forEach((s) => t.push({ ...s })), t;
|
|
348
312
|
}), y = (t, s = !0) => s && t.id === null ? Array.isArray(e.value) ? e.value.some((l) => l.id === t.id && l.name === t.name) : t.name === e.value.name : Array.isArray(e.value) ? e.value.some((l) => l.id === t.id) : t.id === e.value.id, b = N(() => {
|
|
349
|
-
const t = a.value.toLowerCase(), s =
|
|
313
|
+
const t = a.value.toLowerCase(), s = se(t);
|
|
350
314
|
let l = [];
|
|
351
|
-
return i.value.forEach((
|
|
352
|
-
const
|
|
353
|
-
(
|
|
315
|
+
return i.value.forEach((g) => {
|
|
316
|
+
const w = g.name.toLowerCase();
|
|
317
|
+
(g.id === Number(t) || w.includes(t) || w.includes(s)) && (w === t || w === s ? l.unshift(g) : l.push(g));
|
|
354
318
|
}), l.push(...p.items.value), d.appendSearchToResult && a.value && (!l.length || l[0].name.toLowerCase() !== t) && l.push({
|
|
355
319
|
id: null,
|
|
356
320
|
name: a.value
|
|
357
|
-
}), d.multiselect && (l = l.filter((
|
|
321
|
+
}), d.multiselect && (l = l.filter((g) => !y(g))), l;
|
|
358
322
|
}), u = async (t) => {
|
|
359
323
|
var s, l;
|
|
360
324
|
if (d.multiselect) {
|
|
361
325
|
if (!Array.isArray(e.value) || y(t))
|
|
362
326
|
return;
|
|
363
|
-
const
|
|
364
|
-
|
|
365
|
-
var
|
|
366
|
-
(
|
|
327
|
+
const g = [...e.value];
|
|
328
|
+
g.push({ ...t }), e.value = g, ae.state.isMobile ? (s = n()) == null || s.close() : setTimeout(() => {
|
|
329
|
+
var w, F, U, W;
|
|
330
|
+
(w = n()) == null || w.recalcPosition(), (W = (U = (F = n()) == null ? void 0 : F.elPopupWidget) == null ? void 0 : U.querySelector("input")) == null || W.focus(), a.value && (b.value.length || (a.value = "", p.items.value = []));
|
|
367
331
|
});
|
|
368
332
|
} else
|
|
369
333
|
a.value && (a.value = "", p.items.value = []), JSON.stringify(t) !== JSON.stringify(e.value) && (e.value = { ...t }), (l = n()) == null || l.close();
|
|
@@ -372,31 +336,31 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
372
336
|
const s = (i.value.findIndex((l) => l.id === e.value.id) + 1) % i.value.length;
|
|
373
337
|
e.value = { ...i.value[s] };
|
|
374
338
|
}
|
|
375
|
-
},
|
|
339
|
+
}, V = async (t) => {
|
|
376
340
|
Array.isArray(e.value) && (e.value = e.value.filter((s) => s.id !== t), setTimeout(() => {
|
|
377
341
|
var s;
|
|
378
342
|
(s = n()) == null || s.recalcPosition();
|
|
379
343
|
}));
|
|
380
|
-
}, h =
|
|
381
|
-
d.apiRequest && (
|
|
344
|
+
}, h = T(!1);
|
|
345
|
+
d.apiRequest && (E(h, () => {
|
|
382
346
|
h.value && p.setSearchTextAndLoad(a.value, !1);
|
|
383
|
-
}),
|
|
384
|
-
const
|
|
347
|
+
}), E(a, () => p.setSearchTextAndLoad(a.value)));
|
|
348
|
+
const M = (t) => {
|
|
385
349
|
const s = t.target;
|
|
386
350
|
s.scrollTop / (s.scrollHeight - s.offsetHeight) > 0.8 && p.loadAppend();
|
|
387
351
|
};
|
|
388
|
-
return (t, s) => (c(),
|
|
352
|
+
return (t, s) => (c(), k(L(re), {
|
|
389
353
|
ref_key: "popupRef",
|
|
390
354
|
ref: f,
|
|
391
355
|
onOpen: s[1] || (s[1] = (l) => h.value = !0),
|
|
392
356
|
onClose: s[2] || (s[2] = (l) => h.value = !1),
|
|
393
|
-
onScrollContentList: s[3] || (s[3] = (l) => t.apiRequest ?
|
|
357
|
+
onScrollContentList: s[3] || (s[3] = (l) => t.apiRequest ? M(l) : void 0),
|
|
394
358
|
notch: !1,
|
|
395
359
|
transitionDuration: 0
|
|
396
360
|
}, {
|
|
397
|
-
opener:
|
|
398
|
-
|
|
399
|
-
class:
|
|
361
|
+
opener: C(() => [
|
|
362
|
+
K("div", {
|
|
363
|
+
class: S({
|
|
400
364
|
"top-selector2": !0,
|
|
401
365
|
"top-selector2-multiselect": t.multiselect,
|
|
402
366
|
["top-size_" + t.size]: !0,
|
|
@@ -405,55 +369,55 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
405
369
|
"top-error": t.isError
|
|
406
370
|
})
|
|
407
371
|
}, [
|
|
408
|
-
t.multiselect ? (c(), v("div",
|
|
409
|
-
(c(!0), v(
|
|
372
|
+
t.multiselect ? (c(), v("div", Ve, [
|
|
373
|
+
(c(!0), v(O, null, G(e.value, (l) => (c(), k(ge, {
|
|
410
374
|
id: l.id,
|
|
411
375
|
name: l.name,
|
|
412
|
-
onDelete:
|
|
376
|
+
onDelete: V
|
|
413
377
|
}, null, 8, ["id", "name"]))), 256))
|
|
414
|
-
])) :
|
|
415
|
-
t.multiselect ?
|
|
378
|
+
])) : A("", !0),
|
|
379
|
+
t.multiselect ? A("", !0) : (c(), v("span", Ae, B(Array.isArray(e.value) ? "" : e.value.name), 1)),
|
|
416
380
|
t.addChanger && !t.multiselect && i.value.length > 1 && !t.disabled ? (c(), v("span", {
|
|
417
381
|
key: 2,
|
|
418
382
|
class: "top-changer top-changer-selector",
|
|
419
|
-
onClick:
|
|
420
|
-
})) :
|
|
383
|
+
onClick: I(o, ["stop"])
|
|
384
|
+
})) : A("", !0)
|
|
421
385
|
], 2)
|
|
422
386
|
]),
|
|
423
|
-
widget:
|
|
424
|
-
|
|
387
|
+
widget: C(() => [
|
|
388
|
+
H(L(ne), {
|
|
425
389
|
title: "Поиск",
|
|
426
390
|
icon: "",
|
|
427
391
|
modelValue: a.value,
|
|
428
392
|
"onUpdate:modelValue": s[0] || (s[0] = (l) => a.value = l),
|
|
429
|
-
isLoading:
|
|
393
|
+
isLoading: L(p).isLoading.value,
|
|
430
394
|
placeholder: !Array.isArray(e.value) && !t.multiselect && t.showSelectedInInput ? e.value.name : t.placeholder
|
|
431
395
|
}, null, 8, ["modelValue", "isLoading", "placeholder"])
|
|
432
396
|
]),
|
|
433
|
-
contentList:
|
|
434
|
-
(c(!0), v(
|
|
435
|
-
class:
|
|
397
|
+
contentList: C(() => [
|
|
398
|
+
(c(!0), v(O, null, G(b.value, (l) => (c(), k(L(R), {
|
|
399
|
+
class: S({
|
|
436
400
|
"top-active": !Array.isArray(e.value) && !t.multiselect && e.value.name === l.name
|
|
437
401
|
}),
|
|
438
402
|
key: l.id ?? void 0,
|
|
439
|
-
onClick:
|
|
403
|
+
onClick: I((g) => u(l), ["stop"])
|
|
440
404
|
}, {
|
|
441
|
-
default:
|
|
442
|
-
t.$slots.item ?
|
|
405
|
+
default: C(() => [
|
|
406
|
+
t.$slots.item ? ee(t.$slots, "item", {
|
|
443
407
|
key: 0,
|
|
444
408
|
item: l
|
|
445
|
-
}) : (c(), v(
|
|
446
|
-
B(
|
|
409
|
+
}) : (c(), v(O, { key: 1 }, [
|
|
410
|
+
$(B(l.name), 1)
|
|
447
411
|
], 64))
|
|
448
412
|
]),
|
|
449
413
|
_: 2
|
|
450
414
|
}, 1032, ["class", "onClick"]))), 128)),
|
|
451
|
-
b.value.length ?
|
|
415
|
+
b.value.length ? A("", !0) : (c(), k(L(R), {
|
|
452
416
|
key: 0,
|
|
453
417
|
type: "regular"
|
|
454
418
|
}, {
|
|
455
|
-
default:
|
|
456
|
-
|
|
419
|
+
default: C(() => s[4] || (s[4] = [
|
|
420
|
+
$(" Нет результатов ")
|
|
457
421
|
])),
|
|
458
422
|
_: 1
|
|
459
423
|
}))
|
|
@@ -461,21 +425,12 @@ const de = { class: "top-editArea_footer" }, pe = /* @__PURE__ */ L({
|
|
|
461
425
|
_: 3
|
|
462
426
|
}, 512));
|
|
463
427
|
}
|
|
464
|
-
}), Pe =
|
|
465
|
-
"top-selector2": "top-selector2",
|
|
466
|
-
"top-selector2-multiselect": "top-selector2-multiselect",
|
|
467
|
-
"top-active": "top-active",
|
|
468
|
-
"top-selector2_activeItems": "top-selector2_activeItems",
|
|
469
|
-
"top-selector2_activeName": "top-selector2_activeName",
|
|
470
|
-
"top-changer-selector": "top-changer-selector"
|
|
471
|
-
}, Ne = {
|
|
472
|
-
$style: Pe
|
|
473
|
-
}, Oe = /* @__PURE__ */ K(Ge, [["__cssModules", Ne]]), Je = fe, Xe = Ae, Re = Ie, Ye = Oe, je = ue;
|
|
428
|
+
}), $e = de, Le = ce, Ee = ye, Ke = Te, Pe = ie;
|
|
474
429
|
export {
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
430
|
+
$e as TopEditArea,
|
|
431
|
+
Le as TopEditInput,
|
|
432
|
+
Pe as TopMenu,
|
|
433
|
+
Ee as TopRadioGroup,
|
|
434
|
+
Ke as TopSelector2
|
|
480
435
|
};
|
|
481
436
|
//# sourceMappingURL=formsExt.js.map
|