@topvisor/ui 0.9.34-utils-components-3 → 0.9.34-utils-components-5
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-CtnkRS5e.es.js → datepicker-Bh_DAFqD.es.js} +2 -2
- package/.chunks/{datepicker-CtnkRS5e.es.js.map → datepicker-Bh_DAFqD.es.js.map} +1 -1
- package/.chunks/{datepicker-DquD9mIq.amd.js → datepicker-CIbLjf_3.amd.js} +2 -2
- package/.chunks/{datepicker-DquD9mIq.amd.js.map → datepicker-CIbLjf_3.amd.js.map} +1 -1
- package/.chunks/forms-BfIXIMY_.es.js +1089 -0
- package/.chunks/forms-BfIXIMY_.es.js.map +1 -0
- package/.chunks/forms-C__H1yL_.amd.js +3 -0
- package/.chunks/forms-C__H1yL_.amd.js.map +1 -0
- package/.chunks/i18n-BNGjUFTp.amd.js +2 -0
- package/.chunks/i18n-BNGjUFTp.amd.js.map +1 -0
- package/.chunks/i18n-DCbk4MSK.es.js +20 -0
- package/.chunks/i18n-DCbk4MSK.es.js.map +1 -0
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-CaBP5R7L.amd.js +2 -0
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-CaBP5R7L.amd.js.map +1 -0
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-DJZS6vRL.es.js +161 -0
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-DJZS6vRL.es.js.map +1 -0
- package/.chunks/{menu-DFQAjecc.es.js → menu-24EpQtdy.es.js} +37 -37
- package/.chunks/menu-24EpQtdy.es.js.map +1 -0
- package/.chunks/menu-DV1iSTyB.amd.js +2 -0
- package/.chunks/menu-DV1iSTyB.amd.js.map +1 -0
- package/.chunks/popup-BKd_kjT8.amd.js +440 -0
- package/.chunks/popup-BKd_kjT8.amd.js.map +1 -0
- package/.chunks/{popup-BoqfTf-1.es.js → popup-DwpeWN20.es.js} +57 -53
- package/.chunks/popup-DwpeWN20.es.js.map +1 -0
- package/assets/forms.css +1 -1
- package/assets/formsExt.css +1 -1
- package/common/common.d.ts +1 -1
- package/{src/components → components}/formsExt/editInput/editInput.vue.d.ts +1 -10
- package/{src/components → components}/formsExt/formsExt.d.ts +2 -0
- package/components/formsExt/selector2/itemMulti.vue.d.ts +18 -0
- package/components/formsExt/selector2/selector2.vue.d.ts +132 -0
- package/{src/components → components}/popup/lib/popup.d.ts +0 -3
- package/{src/components → components}/popup/lib/worker.d.ts +0 -4
- package/core/app.amd.js +2 -0
- package/core/app.amd.js.map +1 -0
- package/core/app.d.ts +7 -0
- package/core/app.js +307 -0
- package/core/app.js.map +1 -0
- package/{src/core → core}/core/core.d.ts +17 -24
- package/core/core/options.d.ts +24 -0
- package/{src/core → core}/core/state.d.ts +3 -2
- package/core/core.amd.js +1 -1
- package/core/core.d.ts +2 -2
- package/core/core.js +1 -1
- package/core/directives/focus.d.ts +9 -3
- package/core/directives/sticky.d.ts +11 -3
- package/core/directives/swimUp.d.ts +10 -3
- package/core/directives/tooltip.d.ts +11 -3
- package/{src/core/plugin/plugin.d.ts → core/plugins/core.d.ts} +14 -17
- package/core/plugins/i18n.d.ts +98 -0
- package/core/plugins/piniaTPA.d.ts +18 -0
- package/core/utils/clipboard.d.ts +1 -0
- package/{src/core → core}/utils/price.d.ts +3 -1
- package/{src/core → core}/utils/system.d.ts +0 -1
- package/forms/forms.amd.js +1 -1
- package/forms/forms.d.ts +1 -1
- package/forms/forms.js +7 -7
- package/forms/helpers.d.ts +1 -1
- package/formsExt/formsExt.amd.js +1 -1
- package/formsExt/formsExt.amd.js.map +1 -1
- package/formsExt/formsExt.d.ts +1 -1
- package/formsExt/formsExt.js +357 -122
- package/formsExt/formsExt.js.map +1 -1
- package/package.json +5 -1
- package/popup/popup.amd.js +1 -1
- package/popup/popup.amd.js.map +1 -1
- package/popup/popup.d.ts +1 -1
- package/popup/popup.js +6 -6
- package/popup/worker.amd.js +1 -1
- package/popup/worker.amd.js.map +1 -1
- package/popup/worker.d.ts +2 -2
- package/popup/worker.js +5 -7
- 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.d.ts +1 -1
- package/project/project.js +7 -7
- package/project/project.js.map +1 -1
- package/tabs/tabs.amd.js +1 -1
- package/tabs/tabs.d.ts +1 -1
- package/tabs/tabs.js +5 -5
- package/tabsView/tabsView.amd.js +1 -1
- package/tabsView/tabsView.amd.js.map +1 -1
- package/tabsView/tabsView.d.ts +1 -1
- package/tabsView/tabsView.js +8 -8
- package/tabsView/tabsView.js.map +1 -1
- package/utils/check.d.ts +1 -1
- package/utils/clipboard.amd.js +2 -0
- package/utils/clipboard.amd.js.map +1 -0
- package/utils/clipboard.d.ts +1 -0
- package/utils/clipboard.js +10 -0
- package/utils/clipboard.js.map +1 -0
- package/utils/css.d.ts +1 -1
- package/utils/date.amd.js +1 -1
- package/utils/date.d.ts +1 -1
- package/utils/date.js +4 -4
- package/utils/device.amd.js +1 -1
- package/utils/device.d.ts +1 -1
- package/utils/device.js +5 -5
- package/utils/dom.d.ts +2 -2
- package/utils/image.d.ts +1 -1
- package/utils/keyboard.d.ts +1 -1
- package/utils/number.d.ts +1 -1
- package/utils/price.amd.js +1 -1
- package/utils/price.amd.js.map +1 -1
- package/utils/price.d.ts +1 -1
- package/utils/price.js +8 -5
- package/utils/price.js.map +1 -1
- package/utils/route.d.ts +1 -1
- package/utils/scroll.amd.js +1 -1
- package/utils/scroll.d.ts +1 -1
- package/utils/scroll.js +1 -1
- package/utils/store.d.ts +1 -1
- package/utils/string.amd.js +1 -1
- package/utils/string.amd.js.map +1 -1
- package/utils/string.d.ts +1 -1
- package/utils/string.js +38 -35
- package/utils/string.js.map +1 -1
- package/utils/system.amd.js +1 -1
- package/utils/system.amd.js.map +1 -1
- package/utils/system.d.ts +1 -1
- package/utils/system.js +16 -17
- package/utils/system.js.map +1 -1
- package/utils/url.d.ts +1 -1
- package/utils/window.amd.js +1 -1
- package/utils/window.d.ts +1 -1
- package/utils/window.js +1 -1
- package/web-types.json +62 -62
- package/.chunks/forms-CvUw0pdr.amd.js +0 -3
- package/.chunks/forms-CvUw0pdr.amd.js.map +0 -1
- package/.chunks/forms-zlyhVXZ9.es.js +0 -1186
- package/.chunks/forms-zlyhVXZ9.es.js.map +0 -1
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-C0vCVRTn.amd.js +0 -2
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-C0vCVRTn.amd.js.map +0 -1
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-C1JdWeQq.es.js +0 -164
- package/.chunks/listItem.vue_vue_type_script_setup_true_lang-C1JdWeQq.es.js.map +0 -1
- package/.chunks/menu-D8OY3zle.amd.js +0 -2
- package/.chunks/menu-D8OY3zle.amd.js.map +0 -1
- package/.chunks/menu-DFQAjecc.es.js.map +0 -1
- package/.chunks/popup-31lyEYe3.amd.js +0 -440
- package/.chunks/popup-31lyEYe3.amd.js.map +0 -1
- package/.chunks/popup-BoqfTf-1.es.js.map +0 -1
- package/core/directives/focus.amd.js +0 -2
- package/core/directives/focus.amd.js.map +0 -1
- package/core/directives/focus.js +0 -5
- package/core/directives/focus.js.map +0 -1
- package/core/directives/sticky.amd.js +0 -2
- package/core/directives/sticky.amd.js.map +0 -1
- package/core/directives/sticky.js +0 -5
- package/core/directives/sticky.js.map +0 -1
- package/core/directives/swimUp.amd.js +0 -2
- package/core/directives/swimUp.amd.js.map +0 -1
- package/core/directives/swimUp.js +0 -5
- package/core/directives/swimUp.js.map +0 -1
- package/core/directives/tooltip.amd.js +0 -2
- package/core/directives/tooltip.amd.js.map +0 -1
- package/core/directives/tooltip.js +0 -5
- package/core/directives/tooltip.js.map +0 -1
- package/core/plugin/plugin.amd.js +0 -2
- package/core/plugin/plugin.amd.js.map +0 -1
- package/core/plugin/plugin.d.ts +0 -3
- package/core/plugin/plugin.js +0 -23
- package/core/plugin/plugin.js.map +0 -1
- package/src/components/forms/avatar/avatar.stories.d.ts +0 -85
- package/src/components/forms/button/button.stories.d.ts +0 -278
- package/src/components/forms/checkbox/checkbox.stories.d.ts +0 -116
- package/src/components/forms/controlLabel/controlLabel.stories.d.ts +0 -65
- package/src/components/forms/hint/hint.stories.d.ts +0 -75
- package/src/components/forms/input/input.stories.d.ts +0 -226
- package/src/components/forms/inputDate/inputDate.stories.d.ts +0 -117
- package/src/components/forms/inputRange/inputRange.stories.d.ts +0 -285
- package/src/components/forms/loadbar/loadbar.stories.d.ts +0 -10
- package/src/components/forms/radio/radio.stories.d.ts +0 -132
- package/src/components/forms/select/select.stories.d.ts +0 -108
- package/src/components/forms/switcher/switcher.stories.d.ts +0 -127
- package/src/components/forms/textarea/textarea.stories.d.ts +0 -90
- package/src/components/formsExt/editArea/editArea.stories.d.ts +0 -158
- package/src/components/formsExt/editInput/editInput.stories.d.ts +0 -98
- package/src/components/formsExt/menu/menu.stories.d.ts +0 -82
- package/src/components/formsExt/radioGroup/radioGroup.stories.d.ts +0 -67
- package/src/components/formsExt/selector2/selector2.stories.d.ts +0 -277
- package/src/components/popup/popup/popup.stories.d.ts +0 -701
- package/src/components/project/selectorCompetitors/selectorCompetitors.stories.d.ts +0 -43
- package/src/components/tabs/tabs/tabs.stories.d.ts +0 -539
- package/src/components/tabsView/tabsView/tabsView.stories.d.ts +0 -352
- package/src/components/tabsView/tabsView//320/255/320/273/320/265/320/274/320/265/320/275/321/202/321/213/MenuItem.stories.d.ts +0 -333
- package/src/components/tabsView/tabsView//320/255/320/273/320/265/320/274/320/265/320/275/321/202/321/213/MenuTitle.stories.d.ts +0 -175
- package/src/core/core/options.d.ts +0 -13
- package/src/core/core/page.d.ts +0 -7
- package/src/core/directives/focus.d.ts +0 -9
- package/src/core/directives/sticky.d.ts +0 -11
- package/src/core/directives/swimUp.d.ts +0 -10
- package/src/core/directives/tooltip.d.ts +0 -11
- /package/{src/components → components}/common/common.d.ts +0 -0
- /package/{src/components → components}/common/icon/icon.d.ts +0 -0
- /package/{src/components → components}/forms/avatar/avatar.d.ts +0 -0
- /package/{src/components → components}/forms/avatar/avatar.vue.d.ts +0 -0
- /package/{src/components → components}/forms/button/button.d.ts +0 -0
- /package/{src/components → components}/forms/button/button.vue.d.ts +0 -0
- /package/{src/components → components}/forms/checkbox/checkbox.d.ts +0 -0
- /package/{src/components → components}/forms/checkbox/checkbox.vue.d.ts +0 -0
- /package/{src/components → components}/forms/controlLabel/controlLabel.d.ts +0 -0
- /package/{src/components → components}/forms/controlLabel/controlLabel.vue.d.ts +0 -0
- /package/{src/components → components}/forms/forms.d.ts +0 -0
- /package/{src/components → components}/forms/helpers.d.ts +0 -0
- /package/{src/components → components}/forms/hint/hint.d.ts +0 -0
- /package/{src/components → components}/forms/hint/hint.vue.d.ts +0 -0
- /package/{src/components → components}/forms/input/input.d.ts +0 -0
- /package/{src/components → components}/forms/input/input.vue.d.ts +0 -0
- /package/{src/components → components}/forms/inputDate/datepicker.d.ts +0 -0
- /package/{src/components → components}/forms/inputDate/inputDate.d.ts +0 -0
- /package/{src/components → components}/forms/inputDate/inputDate.vue.d.ts +0 -0
- /package/{src/components → components}/forms/inputRange/inputRange.d.ts +0 -0
- /package/{src/components → components}/forms/inputRange/inputRange.vue.d.ts +0 -0
- /package/{src/components → components}/forms/loadbar/loadbar.vue.d.ts +0 -0
- /package/{src/components → components}/forms/radio/radio.d.ts +0 -0
- /package/{src/components → components}/forms/radio/radio.vue.d.ts +0 -0
- /package/{src/components → components}/forms/select/select.d.ts +0 -0
- /package/{src/components → components}/forms/select/select.vue.d.ts +0 -0
- /package/{src/components → components}/forms/select/stories/exampleOptions.d.ts +0 -0
- /package/{src/components → components}/forms/switcher/switcher.d.ts +0 -0
- /package/{src/components → components}/forms/switcher/switcher.vue.d.ts +0 -0
- /package/{src/components → components}/forms/textarea/textarea.d.ts +0 -0
- /package/{src/components → components}/forms/textarea/textarea.vue.d.ts +0 -0
- /package/{src/components → components}/formsExt/editArea/editArea.d.ts +0 -0
- /package/{src/components → components}/formsExt/editArea/editArea.vue.d.ts +0 -0
- /package/{src/components → components}/formsExt/editInput/editInput.d.ts +0 -0
- /package/{src/components → components}/formsExt/menu/menu.d.ts +0 -0
- /package/{src/components → components}/formsExt/menu/menu.vue.d.ts +0 -0
- /package/{src/components → components}/formsExt/menu/stories/items.d.ts +0 -0
- /package/{src/components → components}/formsExt/radioGroup/radioGroup.d.ts +0 -0
- /package/{src/components → components}/formsExt/radioGroup/radioGroup.vue.d.ts +0 -0
- /package/{src/components → components}/formsExt/selector2/api.d.ts +0 -0
- /package/{src/components → components}/formsExt/selector2/selector2.d.ts +0 -0
- /package/{src/components → components}/formsExt/selector2/stories/dummyAPIRequest.d.ts +0 -0
- /package/{src/components → components}/popup/lib/popup.globalEvents.d.ts +0 -0
- /package/{src/components → components}/popup/lib/worker.globalEvents.d.ts +0 -0
- /package/{src/components → components}/popup/popup/listItem.vue.d.ts +0 -0
- /package/{src/components → components}/popup/popup/opener.vue.d.ts +0 -0
- /package/{src/components → components}/popup/popup/popup.d.ts +0 -0
- /package/{src/components → components}/popup/popup/popup.vue.d.ts +0 -0
- /package/{src/components → components}/popup/popup/widgetInput.vue.d.ts +0 -0
- /package/{src/components → components}/popup/popup.d.ts +0 -0
- /package/{src/components → components}/popup/worker.d.ts +0 -0
- /package/{src/components → components}/project/project.d.ts +0 -0
- /package/{src/components → components}/project/selectorCompetitors/composables.d.ts +0 -0
- /package/{src/components → components}/project/selectorCompetitors/selectorCompetitors.d.ts +0 -0
- /package/{src/components → components}/project/selectorCompetitors/selectorCompetitors.vue.d.ts +0 -0
- /package/{src/components → components}/project/selectorCompetitors/stories/items.d.ts +0 -0
- /package/{src/components → components}/project/selectorCompetitors/types/competitor.d.ts +0 -0
- /package/{src/components → components}/tabs/tabs/content.vue.d.ts +0 -0
- /package/{src/components → components}/tabs/tabs/tab.vue.d.ts +0 -0
- /package/{src/components → components}/tabs/tabs/tabs.d.ts +0 -0
- /package/{src/components → components}/tabs/tabs/tabs.vue.d.ts +0 -0
- /package/{src/components → components}/tabs/tabs.d.ts +0 -0
- /package/{src/components → components}/tabsView/tabsView/menu.vue.d.ts +0 -0
- /package/{src/components → components}/tabsView/tabsView/menuDelimeter.vue.d.ts +0 -0
- /package/{src/components → components}/tabsView/tabsView/menuItem.vue.d.ts +0 -0
- /package/{src/components → components}/tabsView/tabsView/menuTitle.vue.d.ts +0 -0
- /package/{src/components → components}/tabsView/tabsView/store.d.ts +0 -0
- /package/{src/components → components}/tabsView/tabsView/tabsView.d.ts +0 -0
- /package/{src/components → components}/tabsView/tabsView/tabsView.vue.d.ts +0 -0
- /package/{src/components → components}/tabsView/tabsView/utils.d.ts +0 -0
- /package/{src/components → components}/tabsView/tabsView.d.ts +0 -0
- /package/{src/core → core}/core/events.d.ts +0 -0
- /package/{src/core → core}/utils/check.d.ts +0 -0
- /package/{src/core → core}/utils/css.d.ts +0 -0
- /package/{src/core → core}/utils/date.d.ts +0 -0
- /package/{src/core → core}/utils/device.d.ts +0 -0
- /package/{src/core → core}/utils/dom.d.ts +0 -0
- /package/{src/core → core}/utils/image.d.ts +0 -0
- /package/{src/core → core}/utils/keyboard.d.ts +0 -0
- /package/{src/core → core}/utils/number.d.ts +0 -0
- /package/{src/core → core}/utils/route.d.ts +0 -0
- /package/{src/core → core}/utils/scroll.d.ts +0 -0
- /package/{src/core → core}/utils/store/localStorage.d.ts +0 -0
- /package/{src/core → core}/utils/store/plugin.d.ts +0 -0
- /package/{src/core → core}/utils/store/store.d.ts +0 -0
- /package/{src/core → core}/utils/store.d.ts +0 -0
- /package/{src/core → core}/utils/string.d.ts +0 -0
- /package/{src/core → core}/utils/url.d.ts +0 -0
- /package/{src/core → core}/utils/window.d.ts +0 -0
|
@@ -0,0 +1,1089 @@
|
|
|
1
|
+
import { insertToPage as x } from "../utils/css.js";
|
|
2
|
+
import { reactive as I, defineComponent as v, useCssVars as q, computed as h, openBlock as p, createElementBlock as m, createElementVNode as S, createCommentVNode as g, createBlock as M, resolveDynamicComponent as te, normalizeClass as w, withCtx as L, renderSlot as k, createTextVNode as oe, toDisplayString as V, mergeModels as C, useModel as G, withDirectives as W, vModelCheckbox as Q, mergeProps as E, withKeys as se, vModelText as J, withModifiers as ae, onUnmounted as ne, ref as ie, unref as N, vModelRadio as re, resolveDirective as le, watch as de, Fragment as P, renderList as F, vModelSelect as pe } from "vue";
|
|
3
|
+
const ee = ["../assets/forms.css"].map((t) => import.meta.resolve(t));
|
|
4
|
+
x(ee, !0);
|
|
5
|
+
function ue() {
|
|
6
|
+
return "devicePixelRatio" in window && window.devicePixelRatio > 1;
|
|
7
|
+
}
|
|
8
|
+
function ce() {
|
|
9
|
+
return !!navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|IEMobile|Opera Mini/i);
|
|
10
|
+
}
|
|
11
|
+
function me() {
|
|
12
|
+
return navigator.userAgent.indexOf("Topvisor_App") != -1;
|
|
13
|
+
}
|
|
14
|
+
function fe() {
|
|
15
|
+
return navigator.userAgent.indexOf("Mac OS X") !== -1;
|
|
16
|
+
}
|
|
17
|
+
function Gt() {
|
|
18
|
+
const t = /Chrome|Android/.test(navigator.userAgent);
|
|
19
|
+
let o = /Safari/.test(navigator.userAgent);
|
|
20
|
+
return t && o && (o = !1), o;
|
|
21
|
+
}
|
|
22
|
+
function Qt() {
|
|
23
|
+
return fe() ? "⌘" : "Ctrl";
|
|
24
|
+
}
|
|
25
|
+
const Jt = () => $(document).scrollTop(), Zt = () => $(document), jt = () => [document], be = () => {
|
|
26
|
+
const t = [
|
|
27
|
+
["iOS", /(iPhone|iPad)/i],
|
|
28
|
+
["Android", /(Android)/i],
|
|
29
|
+
["Windows Phone", /(IEMobile)/i],
|
|
30
|
+
["Windows 3.11", /Win16/i],
|
|
31
|
+
["Windows 95", /(Windows 95)|(Win95)|(Windows_95)/i],
|
|
32
|
+
["Windows 98", /(Windows 98)|(Win98)/i],
|
|
33
|
+
["Windows 2000", /(Windows NT 5.0)|(Windows 2000)/i],
|
|
34
|
+
["Windows XP", /(Windows NT 5.1)|(Windows XP)/i],
|
|
35
|
+
["Windows Server 2003", /(Windows NT 5.2)/i],
|
|
36
|
+
["Windows Vista", /(Windows NT 6.0)/i],
|
|
37
|
+
["Windows 7", /(Windows NT 6.1)/i],
|
|
38
|
+
["Windows 8", /(Windows NT 6.[23])|(Windows 8)/i],
|
|
39
|
+
["Windows 10", /(Windows NT 10)/i],
|
|
40
|
+
["Windows NT 4.0", /(Windows NT 4.0)|(WinNT4.0)|(WinNT)|(Windows NT)/i],
|
|
41
|
+
["Windows ME", /Windows ME/i],
|
|
42
|
+
["Windows", /Windows/i],
|
|
43
|
+
["Open BSD", /OpenBSD/i],
|
|
44
|
+
["Sun OS", /SunOS/i],
|
|
45
|
+
["Linux", /(Linux)|(X11)/i],
|
|
46
|
+
["Macintosh", /(Mac_PowerPC)|(Macintosh)|(Mac OS X 10.4)|(Mac OS X 10.5)|(Mac OS X 10.6)/i],
|
|
47
|
+
["QNX", /QNX/i],
|
|
48
|
+
["BeOS", /BeOS/i],
|
|
49
|
+
["OS/2", /OS\/2/i]
|
|
50
|
+
];
|
|
51
|
+
let o = "";
|
|
52
|
+
for (let s = 0; s < t.length; s++)
|
|
53
|
+
if (t[s][1].test(navigator.userAgent)) {
|
|
54
|
+
o = t[s][0];
|
|
55
|
+
break;
|
|
56
|
+
}
|
|
57
|
+
return o;
|
|
58
|
+
}, xt = async () => {
|
|
59
|
+
var o;
|
|
60
|
+
let t = be();
|
|
61
|
+
if (t === "Windows 10") {
|
|
62
|
+
const s = await ((o = navigator == null ? void 0 : navigator.userAgentData) == null ? void 0 : o.getHighEntropyValues(["platformVersion"]));
|
|
63
|
+
s && s.platformVersion >= "13" && (t = "Windows 11");
|
|
64
|
+
}
|
|
65
|
+
return t;
|
|
66
|
+
}, he = 100;
|
|
67
|
+
let U;
|
|
68
|
+
const H = /* @__PURE__ */ new Map(), D = {
|
|
69
|
+
width: window.innerWidth,
|
|
70
|
+
height: window.innerHeight
|
|
71
|
+
};
|
|
72
|
+
function ge(t) {
|
|
73
|
+
H.set(t, t);
|
|
74
|
+
}
|
|
75
|
+
function we(t) {
|
|
76
|
+
H.delete(t);
|
|
77
|
+
}
|
|
78
|
+
function ye(t) {
|
|
79
|
+
clearTimeout(U), U = setTimeout(function() {
|
|
80
|
+
t.topEvent = {
|
|
81
|
+
widthDiff: D.width - window.innerWidth,
|
|
82
|
+
hightDiff: D.height - window.innerHeight
|
|
83
|
+
}, D.width = window.innerWidth, D.height = window.innerHeight, H.forEach((o) => o(t));
|
|
84
|
+
}, he);
|
|
85
|
+
}
|
|
86
|
+
window.addEventListener("resize", ye);
|
|
87
|
+
const ve = {
|
|
88
|
+
addOnReize: ge,
|
|
89
|
+
removeOnResize: we
|
|
90
|
+
};
|
|
91
|
+
var K;
|
|
92
|
+
const R = {
|
|
93
|
+
/**
|
|
94
|
+
* Базовая ширина страницы для отображения ПК / Мобильной версии сайта
|
|
95
|
+
*/
|
|
96
|
+
widthForMobile: 900,
|
|
97
|
+
/**
|
|
98
|
+
* Формат даты, который будет испоьзоваться по умолчанию для вывода даты, как правило, завсит от текущего пользователя
|
|
99
|
+
*/
|
|
100
|
+
dateFormat: "Y-m-d",
|
|
101
|
+
/**
|
|
102
|
+
* Валюта, которая будет испоьзоваться по умолчанию, как правило, завсит от текущего пользователя
|
|
103
|
+
*/
|
|
104
|
+
currency: "USD",
|
|
105
|
+
/**
|
|
106
|
+
* Для Москвы: +0300
|
|
107
|
+
*/
|
|
108
|
+
gmt: (K = (/* @__PURE__ */ new Date()).toString().match(/GMT(\S+)/)) == null ? void 0 : K[1]
|
|
109
|
+
}, Se = {
|
|
110
|
+
dateFormat: R.dateFormat,
|
|
111
|
+
currency: R.currency,
|
|
112
|
+
gmt: R.gmt,
|
|
113
|
+
/**
|
|
114
|
+
* Device by size
|
|
115
|
+
* @see widthForMobile
|
|
116
|
+
*/
|
|
117
|
+
isMobile: !1,
|
|
118
|
+
/**
|
|
119
|
+
* Device by user agent
|
|
120
|
+
*/
|
|
121
|
+
isMobileUA: !1,
|
|
122
|
+
/**
|
|
123
|
+
* true, если плотность пикселей экрана больше 1
|
|
124
|
+
*/
|
|
125
|
+
isRetina: !1,
|
|
126
|
+
/**
|
|
127
|
+
* true, елси это приложение
|
|
128
|
+
*/
|
|
129
|
+
isApp: !1,
|
|
130
|
+
/**
|
|
131
|
+
* true при горизонтальном расположении устройства
|
|
132
|
+
*/
|
|
133
|
+
isLandscape: !0,
|
|
134
|
+
/**
|
|
135
|
+
* true при вертикальном расположении устройства
|
|
136
|
+
*/
|
|
137
|
+
isPortrait: !1,
|
|
138
|
+
size: 0,
|
|
139
|
+
/**
|
|
140
|
+
* true, если страница скрыта
|
|
141
|
+
*/
|
|
142
|
+
isHidden: !1
|
|
143
|
+
}, $e = () => typeof window > "u" ? {} : window, _e = $e();
|
|
144
|
+
class u {
|
|
145
|
+
/**
|
|
146
|
+
* Настройки словаря
|
|
147
|
+
*
|
|
148
|
+
* @deprecated - используйте useI18n() и $i18n;
|
|
149
|
+
*/
|
|
150
|
+
static L = I({
|
|
151
|
+
Not_date: "Not date"
|
|
152
|
+
});
|
|
153
|
+
static state = I({ ...Se });
|
|
154
|
+
static widthForMobile = 900;
|
|
155
|
+
static matchMediaIsMobile;
|
|
156
|
+
static $ = _e.$;
|
|
157
|
+
/**
|
|
158
|
+
* Добавить на страницу стили, используется для загрузки стилей из js
|
|
159
|
+
*
|
|
160
|
+
* Условная загрузка стилей m и pc отключена в пользу производительсности, стили грузятся всегда, но применяются по условию
|
|
161
|
+
* @param style - css стили в строке
|
|
162
|
+
* @param type - если указать 'm' или 'pc', то стили будут применяться по условию в зависимости от настройки this.widthForMobile
|
|
163
|
+
*/
|
|
164
|
+
static appendStyle(o, s = "") {
|
|
165
|
+
let n = "all";
|
|
166
|
+
s === "m" && (n = "(max-width: " + this.widthForMobile + "px)"), s === "pc" && (n = "(min-width: " + this.widthForMobile + "px)");
|
|
167
|
+
const a = document.createElement("style");
|
|
168
|
+
a.innerHTML = o, a.media = n, document.head.append(a);
|
|
169
|
+
}
|
|
170
|
+
/**
|
|
171
|
+
* Установить конфигурацию UI
|
|
172
|
+
*/
|
|
173
|
+
static setOptions(o) {
|
|
174
|
+
u.widthForMobile = o.widthForMobile, u.state.dateFormat = o.dateFormat, u.state.currency = o.currency, o != null && o.gmt && (u.state.gmt = o.gmt), u.setState();
|
|
175
|
+
}
|
|
176
|
+
static setState() {
|
|
177
|
+
u.matchMediaIsMobile = window.matchMedia(`(max-width: ${u.widthForMobile}px)`), u.state.isMobileUA = ce(), u.state.isRetina = ue(), u.state.isApp = me(), u.state.isHidden = this.isHidden(), u.setStateByWindowSize(), ve.addOnReize(u.onResize), u.onResize(), u.saveToCookie();
|
|
178
|
+
}
|
|
179
|
+
static onResize() {
|
|
180
|
+
u.setStateByWindowSize(), document.documentElement.style.setProperty("--100vh", window.innerHeight + "px");
|
|
181
|
+
}
|
|
182
|
+
static setStateByWindowSize() {
|
|
183
|
+
var o;
|
|
184
|
+
u.state.isMobile = !!((o = u.matchMediaIsMobile) != null && o.matches), u.state.isLandscape = window.innerWidth > window.innerHeight, u.state.isPortrait = !u.state.isLandscape, u.state.size = window.innerWidth > window.innerHeight ? window.innerWidth : window.innerHeight, u.saveToCookie();
|
|
185
|
+
}
|
|
186
|
+
/**
|
|
187
|
+
* Сохранить информацию об устройстве в cookie
|
|
188
|
+
*/
|
|
189
|
+
static saveToCookie() {
|
|
190
|
+
const o = [
|
|
191
|
+
1,
|
|
192
|
+
window.innerWidth,
|
|
193
|
+
window.innerHeight,
|
|
194
|
+
window.devicePixelRatio,
|
|
195
|
+
Number(u.state.isMobile),
|
|
196
|
+
Number(u.state.isRetina)
|
|
197
|
+
];
|
|
198
|
+
document.cookie = "device=" + o.join(",") + "; path=/;";
|
|
199
|
+
}
|
|
200
|
+
/**
|
|
201
|
+
* Проверить скрыта страница или нет
|
|
202
|
+
*/
|
|
203
|
+
static isHidden = () => document.hidden;
|
|
204
|
+
}
|
|
205
|
+
const T = window.L ?? {}, eo = (t, o, s) => {
|
|
206
|
+
switch (new Date(t, o, s).getDay()) {
|
|
207
|
+
case 0:
|
|
208
|
+
return T.Vs + ".";
|
|
209
|
+
case 1:
|
|
210
|
+
return T.Pn + ".";
|
|
211
|
+
case 2:
|
|
212
|
+
return T.Vt + ".";
|
|
213
|
+
case 3:
|
|
214
|
+
return T.Sr + ".";
|
|
215
|
+
case 4:
|
|
216
|
+
return T.Ct + ".";
|
|
217
|
+
case 5:
|
|
218
|
+
return T.Pt + ".";
|
|
219
|
+
case 6:
|
|
220
|
+
return T.Sb + ".";
|
|
221
|
+
default:
|
|
222
|
+
return "";
|
|
223
|
+
}
|
|
224
|
+
}, to = (t, o = !0, s = 2) => {
|
|
225
|
+
let n = String(t.getFullYear()), a = String(t.getDate()).padStart(2, "0"), e = String(t.getMonth() + 1).padStart(2, "0"), d = String(t.getHours()).padStart(2, "0"), r = String(t.getMinutes()).padStart(2, "0"), f = String(t.getSeconds()).padStart(2, "0"), i = n + "-" + e + "-" + a;
|
|
226
|
+
return s >= 1 && (i += " " + d), s >= 2 && (i += ":" + r), s === 3 && (i += ":" + f), o && (i = B(i, s)), i;
|
|
227
|
+
};
|
|
228
|
+
function oo(t) {
|
|
229
|
+
return t.indexOf("T") === -1 && (t.length == 10 && (t += " 00:00:00"), t = t.replace(" ", "T") + u.state.gmt), new Date(t);
|
|
230
|
+
}
|
|
231
|
+
function ke(t, o = !0, s = 0) {
|
|
232
|
+
let n;
|
|
233
|
+
t != null ? n = new Date(t) : n = /* @__PURE__ */ new Date();
|
|
234
|
+
const a = n.getFullYear(), e = String(n.getMonth() + 1).padStart(2, "0"), d = n.getDate().toString().padStart(2, "0"), r = n.getHours().toString().padStart(2, "0"), f = n.getMinutes().toString().padStart(2, "0"), i = n.getSeconds().toString().padStart(2, "0");
|
|
235
|
+
return n = a + "-" + e + "-" + d, s && (n += " "), s >= 1 && (n += r), s >= 2 && (n += ":" + f), s >= 3 && (n += ":" + i), o && (n = B(n, s)), n;
|
|
236
|
+
}
|
|
237
|
+
function so(t, o = !0) {
|
|
238
|
+
const n = (/* @__PURE__ */ new Date()).getTimezoneOffset() / 60 * -1 * 60 * 60 * 1e3, a = 3 * 60 * 60 * 1e3;
|
|
239
|
+
let e;
|
|
240
|
+
t !== void 0 ? e = new Date(t) : e = /* @__PURE__ */ new Date(), e.setTime(e.getTime() - n + a);
|
|
241
|
+
let d = String(e.getFullYear()), r = String(e.getDate()).padStart(2, "0"), f = String(e.getMonth() + 1).padStart(2, "0"), i = String(e.getHours()).padStart(2, "0"), l = String(e.getMinutes()).padStart(2, "0"), c = String(e.getSeconds()).padStart(2, "0"), b = d + "-" + f + "-" + r + " " + i + ":" + l + ":" + c;
|
|
242
|
+
return o && (b = B(b)), b;
|
|
243
|
+
}
|
|
244
|
+
function B(t, o = 2, s, n = u.L.Not_date) {
|
|
245
|
+
if (typeof t == "string" && (!t || t.substring(0, 10) === "0000-00-00") && n && n !== "0000-00-00" || !t) return n;
|
|
246
|
+
s || (s = u.state.dateFormat), s = s.toLowerCase().replace("m", "mm").replace("y", "yy").replace("d", "dd");
|
|
247
|
+
let a;
|
|
248
|
+
if (t instanceof Date)
|
|
249
|
+
a = t;
|
|
250
|
+
else {
|
|
251
|
+
let d = t.substring(0, 10);
|
|
252
|
+
if (d.length === 7 && (d += "-01"), d += " 00:00", d = d.replace(/-/g, "/"), a = new Date(d), isNaN(Number(a))) return n;
|
|
253
|
+
}
|
|
254
|
+
let e = "";
|
|
255
|
+
if (s && window.$ && (e = $.datepicker.formatDate(s, a)), o && typeof t == "string" && t.length > 10 || o && t instanceof Date) {
|
|
256
|
+
let d = "";
|
|
257
|
+
if (t instanceof Date)
|
|
258
|
+
d = (/* @__PURE__ */ new Date()).toLocaleTimeString("en-US", {
|
|
259
|
+
hour12: !1,
|
|
260
|
+
hour: "numeric",
|
|
261
|
+
minute: o >= 2 ? "numeric" : void 0,
|
|
262
|
+
second: o >= 3 ? "numeric" : void 0
|
|
263
|
+
});
|
|
264
|
+
else
|
|
265
|
+
switch (o) {
|
|
266
|
+
case 1:
|
|
267
|
+
d = t.substring(11, 13);
|
|
268
|
+
break;
|
|
269
|
+
case 2:
|
|
270
|
+
d = t.substring(11, 16);
|
|
271
|
+
break;
|
|
272
|
+
case 3:
|
|
273
|
+
d = t.substring(11, 19);
|
|
274
|
+
break;
|
|
275
|
+
}
|
|
276
|
+
e += " " + d;
|
|
277
|
+
}
|
|
278
|
+
return e = e.trim(), e;
|
|
279
|
+
}
|
|
280
|
+
function X(t, o = u.L.Not_date) {
|
|
281
|
+
if (!t)
|
|
282
|
+
return o;
|
|
283
|
+
if (t.match(/\d\d\d\d-\d\d-\d\d/))
|
|
284
|
+
return t;
|
|
285
|
+
const s = u.state.dateFormat.toLowerCase(), n = t.split(/\W/), a = s.split(/\W/);
|
|
286
|
+
let e = "", d = "", r = "";
|
|
287
|
+
a.forEach((i, l) => {
|
|
288
|
+
switch (i) {
|
|
289
|
+
case "d":
|
|
290
|
+
e = n[l];
|
|
291
|
+
break;
|
|
292
|
+
case "m":
|
|
293
|
+
d = n[l];
|
|
294
|
+
break;
|
|
295
|
+
case "y":
|
|
296
|
+
r = n[l];
|
|
297
|
+
break;
|
|
298
|
+
}
|
|
299
|
+
});
|
|
300
|
+
let f = r + "-" + d + "-" + e;
|
|
301
|
+
return f.match(/\d\d\d\d-\d\d-\d\d/) || (console.info("Неверный формат даты, будет возращена текущая дата, " + f), f = ke((/* @__PURE__ */ new Date()).getTime(), !1).substring(0, 10)), f;
|
|
302
|
+
}
|
|
303
|
+
const Me = { class: "top-avatar" }, Te = ["src", "title"], Ve = ["title"], We = /* @__PURE__ */ v({
|
|
304
|
+
__name: "avatar",
|
|
305
|
+
props: {
|
|
306
|
+
size: { default: 64 },
|
|
307
|
+
image: {},
|
|
308
|
+
nickname: {},
|
|
309
|
+
isOnline: { type: Boolean },
|
|
310
|
+
lastActiveTime: {},
|
|
311
|
+
i18n: { default: () => ({
|
|
312
|
+
Online: "Online",
|
|
313
|
+
LastSeen: "Last seen"
|
|
314
|
+
}) }
|
|
315
|
+
},
|
|
316
|
+
setup(t) {
|
|
317
|
+
q((a) => ({
|
|
318
|
+
"15bd2dfc": a.size + "px"
|
|
319
|
+
}));
|
|
320
|
+
const o = t, s = h(() => {
|
|
321
|
+
var a, e;
|
|
322
|
+
if (o.isOnline)
|
|
323
|
+
return (a = o.i18n) == null ? void 0 : a.Online;
|
|
324
|
+
if (o.lastActiveTime)
|
|
325
|
+
return ((e = o.i18n) == null ? void 0 : e.LastSeen) + ": " + B(o.lastActiveTime, 2);
|
|
326
|
+
}), n = h(() => o.nickname ? o.nickname + (s.value ? `
|
|
327
|
+
${s.value}` : "") : s.value);
|
|
328
|
+
return (a, e) => (p(), m("div", Me, [
|
|
329
|
+
S("img", {
|
|
330
|
+
class: "top-avatar_image",
|
|
331
|
+
src: a.image,
|
|
332
|
+
title: n.value,
|
|
333
|
+
alt: ""
|
|
334
|
+
}, null, 8, Te),
|
|
335
|
+
a.isOnline ? (p(), m("div", {
|
|
336
|
+
key: 0,
|
|
337
|
+
class: "top-avatar_status",
|
|
338
|
+
title: s.value
|
|
339
|
+
}, null, 8, Ve)) : g("", !0)
|
|
340
|
+
]));
|
|
341
|
+
}
|
|
342
|
+
}), Be = {
|
|
343
|
+
"top-avatar": "top-avatar",
|
|
344
|
+
"top-avatar_image": "top-avatar_image",
|
|
345
|
+
"top-avatar_status": "top-avatar_status"
|
|
346
|
+
}, y = (t, o) => {
|
|
347
|
+
const s = t.__vccOpts || t;
|
|
348
|
+
for (const [n, a] of o)
|
|
349
|
+
s[n] = a;
|
|
350
|
+
return s;
|
|
351
|
+
}, Le = {
|
|
352
|
+
$style: Be
|
|
353
|
+
}, ze = /* @__PURE__ */ y(We, [["__cssModules", Le]]), De = {
|
|
354
|
+
key: 0,
|
|
355
|
+
class: "top-ellipsis"
|
|
356
|
+
}, Ee = /* @__PURE__ */ v({
|
|
357
|
+
__name: "button",
|
|
358
|
+
props: {
|
|
359
|
+
color: { default: "blue" },
|
|
360
|
+
styling: { default: "" },
|
|
361
|
+
size: { default: "s" },
|
|
362
|
+
name: {},
|
|
363
|
+
title: {},
|
|
364
|
+
icon: {},
|
|
365
|
+
icon2: {},
|
|
366
|
+
href: {},
|
|
367
|
+
disabled: { type: Boolean },
|
|
368
|
+
isSubmit: { type: Boolean },
|
|
369
|
+
isActive: { type: Boolean },
|
|
370
|
+
isProgress: { type: Boolean }
|
|
371
|
+
},
|
|
372
|
+
setup(t) {
|
|
373
|
+
const o = t, s = h(() => o.href ? "a" : "button"), n = h(() => o.isSubmit ? "submit" : void 0);
|
|
374
|
+
return (a, e) => (p(), M(te(s.value), {
|
|
375
|
+
class: w({
|
|
376
|
+
"top-active": a.isActive,
|
|
377
|
+
"top-disabled": a.disabled,
|
|
378
|
+
"top-forms-focusable": !a.disabled,
|
|
379
|
+
"top-button": !0,
|
|
380
|
+
"top-button-progress": a.isProgress,
|
|
381
|
+
[`top-size_${a.size}`]: !!a.size,
|
|
382
|
+
[`top-color_${a.color}`]: !0,
|
|
383
|
+
[`top-style_${a.styling}`]: !!a.styling,
|
|
384
|
+
"top-button-withoutText": !a.$slots.default
|
|
385
|
+
}),
|
|
386
|
+
name: a.name,
|
|
387
|
+
title: a.title,
|
|
388
|
+
href: a.href,
|
|
389
|
+
type: n.value,
|
|
390
|
+
"data-top-icon": a.icon || void 0,
|
|
391
|
+
"data-top-icon2": a.icon2 || void 0,
|
|
392
|
+
disabled: a.disabled || void 0,
|
|
393
|
+
inProgress: a.isProgress
|
|
394
|
+
}, {
|
|
395
|
+
default: L(() => [
|
|
396
|
+
a.$slots.default ? (p(), m("span", De, [
|
|
397
|
+
k(a.$slots, "default", {}, () => [
|
|
398
|
+
oe(V(a.icon ? "" : "Button"), 1)
|
|
399
|
+
])
|
|
400
|
+
])) : g("", !0),
|
|
401
|
+
k(a.$slots, "html")
|
|
402
|
+
]),
|
|
403
|
+
_: 3
|
|
404
|
+
}, 8, ["class", "name", "title", "href", "type", "data-top-icon", "data-top-icon2", "disabled", "inProgress"]));
|
|
405
|
+
}
|
|
406
|
+
}), Ae = "_progress_1f1nw_1", Ne = {
|
|
407
|
+
"top-button": "top-button",
|
|
408
|
+
"top-active": "top-active",
|
|
409
|
+
"top-button-progress": "top-button-progress",
|
|
410
|
+
progress: Ae,
|
|
411
|
+
"top-button-withoutText": "top-button-withoutText",
|
|
412
|
+
"top-color_blue": "top-color_blue",
|
|
413
|
+
"top-color_green": "top-color_green",
|
|
414
|
+
"top-color_orange": "top-color_orange",
|
|
415
|
+
"top-color_red": "top-color_red",
|
|
416
|
+
"top-color_pink": "top-color_pink",
|
|
417
|
+
"top-color_theme": "top-color_theme",
|
|
418
|
+
"top-style_outline": "top-style_outline",
|
|
419
|
+
"top-style_soft": "top-style_soft",
|
|
420
|
+
"top-style_transparent": "top-style_transparent",
|
|
421
|
+
"top-size_l": "top-size_l",
|
|
422
|
+
"top-size_xl": "top-size_xl"
|
|
423
|
+
}, Pe = {
|
|
424
|
+
$style: Ne
|
|
425
|
+
}, Re = /* @__PURE__ */ y(Ee, [["__cssModules", Pe]]), Ce = { class: "top-forms-optionLabel" }, Oe = /* @__PURE__ */ v({
|
|
426
|
+
__name: "controlLabel",
|
|
427
|
+
props: {
|
|
428
|
+
description: {},
|
|
429
|
+
disabled: { type: Boolean }
|
|
430
|
+
},
|
|
431
|
+
setup(t) {
|
|
432
|
+
return (o, s) => (p(), m("div", Ce, [
|
|
433
|
+
S("div", {
|
|
434
|
+
class: w({
|
|
435
|
+
"top-forms-optionLabel_title": !0,
|
|
436
|
+
"top-forms-optionLabel_title-disabled": o.disabled
|
|
437
|
+
})
|
|
438
|
+
}, [
|
|
439
|
+
k(o.$slots, "default")
|
|
440
|
+
], 2),
|
|
441
|
+
o.description ? (p(), m("div", {
|
|
442
|
+
key: 0,
|
|
443
|
+
class: w(["top-forms-optionLabel_description", { "top-forms-optionLabel_description-disabled": o.disabled }])
|
|
444
|
+
}, V(o.description), 3)) : g("", !0)
|
|
445
|
+
]));
|
|
446
|
+
}
|
|
447
|
+
}), He = {
|
|
448
|
+
"top-forms-optionLabel": "top-forms-optionLabel",
|
|
449
|
+
"top-forms-optionLabel_title": "top-forms-optionLabel_title",
|
|
450
|
+
"top-forms-optionLabel_title-disabled": "top-forms-optionLabel_title-disabled",
|
|
451
|
+
"top-forms-optionLabel_description": "top-forms-optionLabel_description",
|
|
452
|
+
"top-forms-optionLabel_description-disabled": "top-forms-optionLabel_description-disabled"
|
|
453
|
+
}, Ie = {
|
|
454
|
+
$style: He
|
|
455
|
+
}, A = /* @__PURE__ */ y(Oe, [["__cssModules", Ie]]), Fe = ["name", "value", "indeterminate", "disabled"], Ue = /* @__PURE__ */ v({
|
|
456
|
+
__name: "checkbox",
|
|
457
|
+
props: /* @__PURE__ */ C({
|
|
458
|
+
modelValue: { type: [Boolean, Array, Set] },
|
|
459
|
+
name: {},
|
|
460
|
+
value: {},
|
|
461
|
+
description: {},
|
|
462
|
+
disabled: { type: Boolean },
|
|
463
|
+
indeterminate: { type: Boolean },
|
|
464
|
+
isError: { type: Boolean }
|
|
465
|
+
}, {
|
|
466
|
+
modelValue: { type: [Boolean, Array, Set] },
|
|
467
|
+
modelModifiers: {}
|
|
468
|
+
}),
|
|
469
|
+
emits: ["update:modelValue"],
|
|
470
|
+
setup(t) {
|
|
471
|
+
const o = G(t, "modelValue");
|
|
472
|
+
return (s, n) => (p(), m("label", {
|
|
473
|
+
class: w({
|
|
474
|
+
"top-forms-optionWrapper": !0,
|
|
475
|
+
"top-checkbox": !0,
|
|
476
|
+
["top-checkbox_" + s.name]: !!s.name,
|
|
477
|
+
"top-disabled": s.disabled,
|
|
478
|
+
"top-error": s.isError && !s.disabled
|
|
479
|
+
})
|
|
480
|
+
}, [
|
|
481
|
+
W(S("input", {
|
|
482
|
+
type: "checkbox",
|
|
483
|
+
class: w({
|
|
484
|
+
"top-forms-focusable": !s.disabled,
|
|
485
|
+
"top-forms-option": !0,
|
|
486
|
+
"top-checkbox_input": !0,
|
|
487
|
+
"top-error": s.isError && !s.disabled
|
|
488
|
+
}),
|
|
489
|
+
name: s.name,
|
|
490
|
+
"onUpdate:modelValue": n[0] || (n[0] = (a) => o.value = a),
|
|
491
|
+
value: s.value,
|
|
492
|
+
indeterminate: s.indeterminate,
|
|
493
|
+
disabled: s.disabled
|
|
494
|
+
}, null, 10, Fe), [
|
|
495
|
+
[Q, o.value]
|
|
496
|
+
]),
|
|
497
|
+
s.$slots.default ? (p(), M(A, {
|
|
498
|
+
key: 0,
|
|
499
|
+
description: s.description,
|
|
500
|
+
disabled: s.disabled
|
|
501
|
+
}, {
|
|
502
|
+
default: L(() => [
|
|
503
|
+
k(s.$slots, "default")
|
|
504
|
+
]),
|
|
505
|
+
_: 3
|
|
506
|
+
}, 8, ["description", "disabled"])) : g("", !0)
|
|
507
|
+
], 2));
|
|
508
|
+
}
|
|
509
|
+
}), Xe = {
|
|
510
|
+
"top-checkbox": "top-checkbox",
|
|
511
|
+
"top-checkbox_input": "top-checkbox_input",
|
|
512
|
+
"top-error": "top-error"
|
|
513
|
+
}, Ye = {
|
|
514
|
+
$style: Xe
|
|
515
|
+
}, Ke = /* @__PURE__ */ y(Ue, [["__cssModules", Ye]]), qe = ["title"], Ge = /* @__PURE__ */ v({
|
|
516
|
+
__name: "hint",
|
|
517
|
+
props: {
|
|
518
|
+
hint: {}
|
|
519
|
+
},
|
|
520
|
+
setup(t) {
|
|
521
|
+
return (o, s) => (p(), m("span", {
|
|
522
|
+
class: "top-hint",
|
|
523
|
+
"data-top-icon": "",
|
|
524
|
+
title: o.hint
|
|
525
|
+
}, null, 8, qe));
|
|
526
|
+
}
|
|
527
|
+
}), Qe = {
|
|
528
|
+
"top-hint": "top-hint"
|
|
529
|
+
}, Je = {
|
|
530
|
+
$style: Qe
|
|
531
|
+
}, Z = /* @__PURE__ */ y(Ge, [["__cssModules", Je]]), Ze = {
|
|
532
|
+
"top-loadbar": "top-loadbar"
|
|
533
|
+
}, je = {}, xe = { class: "top-loadbar" };
|
|
534
|
+
function et(t, o) {
|
|
535
|
+
return p(), m("div", xe);
|
|
536
|
+
}
|
|
537
|
+
const tt = {
|
|
538
|
+
$style: Ze
|
|
539
|
+
}, j = /* @__PURE__ */ y(je, [["render", et], ["__cssModules", tt]]), ot = ["data-top-icon", "data-top-icon2"], st = ["name", "title", "placeholder", "disabled", "readonly"], at = {
|
|
540
|
+
key: 2,
|
|
541
|
+
class: "top-formsCaption"
|
|
542
|
+
}, nt = /* @__PURE__ */ v({
|
|
543
|
+
inheritAttrs: !1,
|
|
544
|
+
__name: "input",
|
|
545
|
+
props: {
|
|
546
|
+
modelValue: {},
|
|
547
|
+
name: {},
|
|
548
|
+
disabled: { type: Boolean },
|
|
549
|
+
readonly: { type: Boolean },
|
|
550
|
+
modificator: {},
|
|
551
|
+
size: { default: "s" },
|
|
552
|
+
isError: { type: Boolean },
|
|
553
|
+
isLoading: { type: Boolean },
|
|
554
|
+
icon: {},
|
|
555
|
+
icon2: {},
|
|
556
|
+
addCleaner: { type: Boolean },
|
|
557
|
+
title: {},
|
|
558
|
+
captionType: { default: "" }
|
|
559
|
+
},
|
|
560
|
+
emits: ["update:modelValue"],
|
|
561
|
+
setup(t, { emit: o }) {
|
|
562
|
+
const s = t, n = o, a = h({
|
|
563
|
+
get() {
|
|
564
|
+
return s.modelValue;
|
|
565
|
+
},
|
|
566
|
+
set(r) {
|
|
567
|
+
n("update:modelValue", r);
|
|
568
|
+
}
|
|
569
|
+
}), e = h(() => s.addCleaner && !s.title || s.captionType !== "" ? "" : s.title), d = (r) => {
|
|
570
|
+
s.modelValue && r.stopPropagation(), n("update:modelValue", "");
|
|
571
|
+
};
|
|
572
|
+
return (r, f) => (p(), m("label", {
|
|
573
|
+
class: w({
|
|
574
|
+
"top-input": !0,
|
|
575
|
+
["top-size_" + r.size]: !0,
|
|
576
|
+
"top-disabled": r.disabled,
|
|
577
|
+
["top-input-" + r.modificator]: !!r.modificator,
|
|
578
|
+
"top-input-withCleaner": r.addCleaner && a.value && a.value !== "0000-00-00",
|
|
579
|
+
"top-formsCaptionWrapper": r.captionType !== "",
|
|
580
|
+
"top-formsCaptionWrapper-always": r.captionType === "top"
|
|
581
|
+
}),
|
|
582
|
+
"data-top-icon": r.icon,
|
|
583
|
+
"data-top-icon2": r.icon2
|
|
584
|
+
}, [
|
|
585
|
+
r.isLoading ? (p(), M(j, { key: 0 })) : g("", !0),
|
|
586
|
+
W(S("input", E({
|
|
587
|
+
type: "text",
|
|
588
|
+
class: {
|
|
589
|
+
"top-input_input": !0,
|
|
590
|
+
["top-input_input-" + r.modificator]: !!r.modificator,
|
|
591
|
+
"top-forms-focusable": !r.disabled,
|
|
592
|
+
"top-error": r.isError
|
|
593
|
+
},
|
|
594
|
+
autocomplete: "off_always",
|
|
595
|
+
name: r.name,
|
|
596
|
+
"onUpdate:modelValue": f[0] || (f[0] = (i) => a.value = i),
|
|
597
|
+
title: r.title,
|
|
598
|
+
placeholder: e.value,
|
|
599
|
+
disabled: r.disabled,
|
|
600
|
+
readonly: r.readonly,
|
|
601
|
+
onKeydown: f[1] || (f[1] = se((i) => (r.addCleaner || !!r.$slots.btn) && d(i), ["esc"]))
|
|
602
|
+
}, r.$attrs), null, 16, st), [
|
|
603
|
+
[J, a.value]
|
|
604
|
+
]),
|
|
605
|
+
r.addCleaner && a.value && a.value !== "0000-00-00" ? (p(), m("span", {
|
|
606
|
+
key: 1,
|
|
607
|
+
class: "top-input_cleaner",
|
|
608
|
+
"data-top-icon": "",
|
|
609
|
+
onClick: ae(d, ["prevent"])
|
|
610
|
+
})) : g("", !0),
|
|
611
|
+
r.captionType !== "" ? (p(), m("span", at, V(r.title), 1)) : g("", !0),
|
|
612
|
+
k(r.$slots, "default")
|
|
613
|
+
], 10, ot));
|
|
614
|
+
}
|
|
615
|
+
}), it = {
|
|
616
|
+
"top-input": "top-input",
|
|
617
|
+
"top-input_input": "top-input_input",
|
|
618
|
+
"top-input-withCleaner": "top-input-withCleaner",
|
|
619
|
+
"top-input_cleaner": "top-input_cleaner",
|
|
620
|
+
"top-loadbar": "top-loadbar"
|
|
621
|
+
}, rt = {
|
|
622
|
+
$style: it
|
|
623
|
+
}, O = /* @__PURE__ */ y(nt, [["__cssModules", rt]]), lt = ["modelValue"], dt = !!document.documentElement.ontouchstart && !!document.createElement("input").showPicker;
|
|
624
|
+
let Y = (t) => {
|
|
625
|
+
};
|
|
626
|
+
const pt = /* @__PURE__ */ v({
|
|
627
|
+
__name: "inputDate",
|
|
628
|
+
props: {
|
|
629
|
+
modelValue: {},
|
|
630
|
+
name: {},
|
|
631
|
+
disabled: { type: Boolean },
|
|
632
|
+
readonly: { type: Boolean },
|
|
633
|
+
modificator: {},
|
|
634
|
+
size: {},
|
|
635
|
+
isError: { type: Boolean },
|
|
636
|
+
isLoading: { type: Boolean },
|
|
637
|
+
icon: {},
|
|
638
|
+
icon2: { default: "" },
|
|
639
|
+
addCleaner: { type: Boolean },
|
|
640
|
+
title: {},
|
|
641
|
+
captionType: {}
|
|
642
|
+
},
|
|
643
|
+
emits: ["update:modelValue"],
|
|
644
|
+
setup(t, { emit: o }) {
|
|
645
|
+
const s = t, n = o;
|
|
646
|
+
ne(() => {
|
|
647
|
+
e && e.datepicker("destroy");
|
|
648
|
+
});
|
|
649
|
+
const a = ie();
|
|
650
|
+
let e;
|
|
651
|
+
const d = h({
|
|
652
|
+
get() {
|
|
653
|
+
return B(s.modelValue, 2, void 0, "0000-00-00");
|
|
654
|
+
},
|
|
655
|
+
set(l) {
|
|
656
|
+
l = X(l, "0000-00-00"), n("update:modelValue", l);
|
|
657
|
+
}
|
|
658
|
+
});
|
|
659
|
+
let r = (l) => {
|
|
660
|
+
Y(l);
|
|
661
|
+
}, f = (l) => {
|
|
662
|
+
const c = X(l.target.value), b = B(c);
|
|
663
|
+
if (!b || b === u.L.Not_date || l.target.value !== b) {
|
|
664
|
+
l.target.value = d.value;
|
|
665
|
+
return;
|
|
666
|
+
}
|
|
667
|
+
d.value = l.target.value;
|
|
668
|
+
};
|
|
669
|
+
async function i(l) {
|
|
670
|
+
const c = await import("./datepicker-Bh_DAFqD.es.js");
|
|
671
|
+
Y = c.oninput, e = c.connectDatepicker(l.target, {
|
|
672
|
+
onSelect: () => f(l)
|
|
673
|
+
}), e && e.datepicker("show");
|
|
674
|
+
}
|
|
675
|
+
return (l, c) => N(dt) ? (p(), M(O, E({ key: 0 }, l.$props, {
|
|
676
|
+
modelValue: d.value,
|
|
677
|
+
readonly: "",
|
|
678
|
+
onClick: c[1] || (c[1] = (b) => a.value.showPicker())
|
|
679
|
+
}), {
|
|
680
|
+
default: L(() => [
|
|
681
|
+
S("input", {
|
|
682
|
+
ref_key: "el",
|
|
683
|
+
ref: a,
|
|
684
|
+
type: "date",
|
|
685
|
+
class: "top-input_input-date",
|
|
686
|
+
modelValue: l.modelValue,
|
|
687
|
+
onChange: c[0] || (c[0] = (b) => d.value = b.target.value),
|
|
688
|
+
tabindex: "-1"
|
|
689
|
+
}, null, 40, lt)
|
|
690
|
+
]),
|
|
691
|
+
_: 1
|
|
692
|
+
}, 16, ["modelValue"])) : (p(), M(O, E({ key: 1 }, l.$props, {
|
|
693
|
+
modelValue: d.value,
|
|
694
|
+
"onUpdate:modelValue": c[2] || (c[2] = (b) => b === "" ? d.value = "" : ""),
|
|
695
|
+
onInput: N(r),
|
|
696
|
+
onFocusOnce: i,
|
|
697
|
+
onChange: N(f),
|
|
698
|
+
modificator: "datepicker"
|
|
699
|
+
}), null, 16, ["modelValue", "onInput", "onChange"]));
|
|
700
|
+
}
|
|
701
|
+
}), ut = {
|
|
702
|
+
"top-input-datepicker": "top-input-datepicker",
|
|
703
|
+
"top-input_input-date": "top-input_input-date"
|
|
704
|
+
}, ct = {
|
|
705
|
+
$style: ut
|
|
706
|
+
}, mt = /* @__PURE__ */ y(pt, [["__cssModules", ct]]), ft = { class: "top-inputRange" }, bt = /* @__PURE__ */ S("span", { class: "top-inputRange_dash" }, " — ", -1), ht = /* @__PURE__ */ v({
|
|
707
|
+
__name: "inputRange",
|
|
708
|
+
setup(t) {
|
|
709
|
+
return (o, s) => (p(), m("div", ft, [
|
|
710
|
+
k(o.$slots, "from"),
|
|
711
|
+
bt,
|
|
712
|
+
k(o.$slots, "to")
|
|
713
|
+
]));
|
|
714
|
+
}
|
|
715
|
+
}), gt = {
|
|
716
|
+
"top-inputRange": "top-inputRange",
|
|
717
|
+
"top-inputRange_dash": "top-inputRange_dash",
|
|
718
|
+
"top-input": "top-input"
|
|
719
|
+
}, wt = {
|
|
720
|
+
$style: gt
|
|
721
|
+
}, yt = /* @__PURE__ */ y(ht, [["__cssModules", wt]]), vt = ["name", "value", "disabled"], St = /* @__PURE__ */ v({
|
|
722
|
+
__name: "radio",
|
|
723
|
+
props: {
|
|
724
|
+
modelValue: {},
|
|
725
|
+
value: {},
|
|
726
|
+
name: {},
|
|
727
|
+
description: {},
|
|
728
|
+
disabled: { type: Boolean },
|
|
729
|
+
isError: { type: Boolean }
|
|
730
|
+
},
|
|
731
|
+
emits: ["update:modelValue"],
|
|
732
|
+
setup(t, { emit: o }) {
|
|
733
|
+
const s = t, n = o, a = h({
|
|
734
|
+
get() {
|
|
735
|
+
return s.modelValue;
|
|
736
|
+
},
|
|
737
|
+
set(e) {
|
|
738
|
+
n("update:modelValue", e);
|
|
739
|
+
}
|
|
740
|
+
});
|
|
741
|
+
return (e, d) => (p(), m("label", {
|
|
742
|
+
class: w({
|
|
743
|
+
"top-forms-optionWrapper": !0,
|
|
744
|
+
"top-radio": !0,
|
|
745
|
+
["top-radio_" + e.name]: e.name !== "",
|
|
746
|
+
"top-disabled": e.disabled,
|
|
747
|
+
"top-error": e.isError && !e.disabled
|
|
748
|
+
})
|
|
749
|
+
}, [
|
|
750
|
+
W(S("input", {
|
|
751
|
+
type: "radio",
|
|
752
|
+
class: w({
|
|
753
|
+
"top-forms-focusable": !e.disabled,
|
|
754
|
+
"top-forms-option": !0,
|
|
755
|
+
"top-radio_input": !0,
|
|
756
|
+
"top-error": e.isError && !e.disabled
|
|
757
|
+
}),
|
|
758
|
+
"onUpdate:modelValue": d[0] || (d[0] = (r) => a.value = r),
|
|
759
|
+
name: e.name,
|
|
760
|
+
value: e.value,
|
|
761
|
+
disabled: e.disabled
|
|
762
|
+
}, null, 10, vt), [
|
|
763
|
+
[re, a.value]
|
|
764
|
+
]),
|
|
765
|
+
e.$slots.default ? (p(), M(A, {
|
|
766
|
+
key: 0,
|
|
767
|
+
description: e.description,
|
|
768
|
+
disabled: e.disabled
|
|
769
|
+
}, {
|
|
770
|
+
default: L(() => [
|
|
771
|
+
k(e.$slots, "default")
|
|
772
|
+
]),
|
|
773
|
+
_: 3
|
|
774
|
+
}, 8, ["description", "disabled"])) : g("", !0)
|
|
775
|
+
], 2));
|
|
776
|
+
}
|
|
777
|
+
}), $t = {
|
|
778
|
+
"top-radio": "top-radio",
|
|
779
|
+
"top-radio_input": "top-radio_input",
|
|
780
|
+
"top-error": "top-error"
|
|
781
|
+
}, _t = {
|
|
782
|
+
$style: $t
|
|
783
|
+
}, kt = /* @__PURE__ */ y(St, [["__cssModules", _t]]), Mt = ["name", "value", "disabled"], Tt = /* @__PURE__ */ v({
|
|
784
|
+
__name: "switcher",
|
|
785
|
+
props: {
|
|
786
|
+
modelValue: { type: [Boolean, Array, Set] },
|
|
787
|
+
name: {},
|
|
788
|
+
value: {},
|
|
789
|
+
description: {},
|
|
790
|
+
disabled: { type: Boolean },
|
|
791
|
+
isError: { type: Boolean }
|
|
792
|
+
},
|
|
793
|
+
emits: ["update:modelValue"],
|
|
794
|
+
setup(t, { emit: o }) {
|
|
795
|
+
const s = t, n = o, a = h({
|
|
796
|
+
get() {
|
|
797
|
+
return s.modelValue;
|
|
798
|
+
},
|
|
799
|
+
set(e) {
|
|
800
|
+
n("update:modelValue", e);
|
|
801
|
+
}
|
|
802
|
+
});
|
|
803
|
+
return (e, d) => (p(), m("label", {
|
|
804
|
+
class: w({
|
|
805
|
+
"top-forms-optionWrapper": !0,
|
|
806
|
+
"top-checkboxSwitcher": !0,
|
|
807
|
+
"top-disabled": e.disabled,
|
|
808
|
+
"top-error": e.isError && !e.disabled
|
|
809
|
+
})
|
|
810
|
+
}, [
|
|
811
|
+
W(S("input", {
|
|
812
|
+
type: "checkbox",
|
|
813
|
+
class: w({
|
|
814
|
+
"top-forms-focusable": !e.disabled,
|
|
815
|
+
"top-forms-option": !0,
|
|
816
|
+
"top-checkboxSwitcher_input": !0,
|
|
817
|
+
"top-error": e.isError && !e.disabled
|
|
818
|
+
}),
|
|
819
|
+
"onUpdate:modelValue": d[0] || (d[0] = (r) => a.value = r),
|
|
820
|
+
name: e.name,
|
|
821
|
+
value: e.value,
|
|
822
|
+
disabled: e.disabled
|
|
823
|
+
}, null, 10, Mt), [
|
|
824
|
+
[Q, a.value]
|
|
825
|
+
]),
|
|
826
|
+
e.$slots.default ? (p(), M(A, {
|
|
827
|
+
key: 0,
|
|
828
|
+
description: e.description,
|
|
829
|
+
disabled: e.disabled
|
|
830
|
+
}, {
|
|
831
|
+
default: L(() => [
|
|
832
|
+
k(e.$slots, "default")
|
|
833
|
+
]),
|
|
834
|
+
_: 3
|
|
835
|
+
}, 8, ["description", "disabled"])) : g("", !0)
|
|
836
|
+
], 2));
|
|
837
|
+
}
|
|
838
|
+
}), Vt = {
|
|
839
|
+
"top-checkboxSwitcher": "top-checkboxSwitcher",
|
|
840
|
+
"top-checkboxSwitcher_input": "top-checkboxSwitcher_input",
|
|
841
|
+
"top-error": "top-error"
|
|
842
|
+
}, Wt = {
|
|
843
|
+
$style: Vt
|
|
844
|
+
}, Bt = /* @__PURE__ */ y(Tt, [["__cssModules", Wt]]), Lt = ["name", "placeholder", "disabled", "readonly", "rows"], zt = {
|
|
845
|
+
key: 0,
|
|
846
|
+
class: "top-textarea_pseudoContent"
|
|
847
|
+
}, Dt = /* @__PURE__ */ v({
|
|
848
|
+
inheritAttrs: !1,
|
|
849
|
+
__name: "textarea",
|
|
850
|
+
props: {
|
|
851
|
+
modelValue: {},
|
|
852
|
+
name: {},
|
|
853
|
+
placeholder: {},
|
|
854
|
+
rows: { default: 5 },
|
|
855
|
+
minHeight: { default: 120 },
|
|
856
|
+
expandable: { type: Boolean },
|
|
857
|
+
disabled: { type: Boolean },
|
|
858
|
+
readonly: { type: Boolean },
|
|
859
|
+
isError: { type: Boolean },
|
|
860
|
+
hint: {}
|
|
861
|
+
},
|
|
862
|
+
emits: ["update:modelValue"],
|
|
863
|
+
setup(t, { emit: o }) {
|
|
864
|
+
q((e) => ({
|
|
865
|
+
"6e3fbb58": e.minHeight + "px"
|
|
866
|
+
}));
|
|
867
|
+
const s = t, n = o, a = h({
|
|
868
|
+
get() {
|
|
869
|
+
return s.modelValue;
|
|
870
|
+
},
|
|
871
|
+
set(e) {
|
|
872
|
+
n("update:modelValue", e);
|
|
873
|
+
}
|
|
874
|
+
});
|
|
875
|
+
return (e, d) => {
|
|
876
|
+
const r = le("top-tooltip");
|
|
877
|
+
return p(), m("label", {
|
|
878
|
+
class: w({
|
|
879
|
+
"top-textarea": !0,
|
|
880
|
+
["top-textarea-" + e.name]: e.name,
|
|
881
|
+
"top-disabled": e.disabled
|
|
882
|
+
})
|
|
883
|
+
}, [
|
|
884
|
+
W(S("textarea", E({
|
|
885
|
+
type: "text",
|
|
886
|
+
class: {
|
|
887
|
+
"top-forms-focusable": !e.disabled,
|
|
888
|
+
"top-textarea_textarea": !0,
|
|
889
|
+
"top-textarea_textarea-expandable": e.expandable,
|
|
890
|
+
"top-error": e.isError
|
|
891
|
+
},
|
|
892
|
+
autocomplete: "off_always",
|
|
893
|
+
name: e.name,
|
|
894
|
+
placeholder: e.placeholder,
|
|
895
|
+
disabled: e.disabled,
|
|
896
|
+
readonly: e.readonly,
|
|
897
|
+
rows: e.expandable ? void 0 : e.rows
|
|
898
|
+
}, e.$attrs, {
|
|
899
|
+
"onUpdate:modelValue": d[0] || (d[0] = (f) => a.value = f)
|
|
900
|
+
}), null, 16, Lt), [
|
|
901
|
+
[J, a.value]
|
|
902
|
+
]),
|
|
903
|
+
e.expandable ? (p(), m("div", zt, V(a.value + " "), 1)) : g("", !0),
|
|
904
|
+
e.hint ? W((p(), M(Z, {
|
|
905
|
+
key: 1,
|
|
906
|
+
class: "top-textarea_hint",
|
|
907
|
+
hint: e.hint
|
|
908
|
+
}, null, 8, ["hint"])), [
|
|
909
|
+
[r]
|
|
910
|
+
]) : g("", !0)
|
|
911
|
+
], 2);
|
|
912
|
+
};
|
|
913
|
+
}
|
|
914
|
+
}), Et = {
|
|
915
|
+
"top-textarea": "top-textarea",
|
|
916
|
+
"top-textarea_textarea": "top-textarea_textarea",
|
|
917
|
+
"top-textarea_textarea-expandable": "top-textarea_textarea-expandable",
|
|
918
|
+
"top-textarea_pseudoContent": "top-textarea_pseudoContent",
|
|
919
|
+
"top-textarea_hint": "top-textarea_hint"
|
|
920
|
+
}, At = {
|
|
921
|
+
$style: Et
|
|
922
|
+
}, Nt = /* @__PURE__ */ y(Dt, [["__cssModules", At]]), Pt = ["data-value", "data-top-icon", "data-top-icon2"], Rt = ["name", "disabled"], Ct = ["label", "disabled"], Ot = ["value", "selected", "disabled"], Ht = ["value", "selected", "disabled"], It = {
|
|
923
|
+
key: 1,
|
|
924
|
+
class: "top-formsCaption"
|
|
925
|
+
}, Ft = /* @__PURE__ */ v({
|
|
926
|
+
__name: "select",
|
|
927
|
+
props: /* @__PURE__ */ C({
|
|
928
|
+
modelValue: {},
|
|
929
|
+
options: {},
|
|
930
|
+
name: {},
|
|
931
|
+
disabled: { type: Boolean },
|
|
932
|
+
icon: {},
|
|
933
|
+
size: { default: "s" },
|
|
934
|
+
addChanger: { type: Boolean },
|
|
935
|
+
title: {},
|
|
936
|
+
isError: { type: Boolean }
|
|
937
|
+
}, {
|
|
938
|
+
modelValue: {
|
|
939
|
+
required: !0
|
|
940
|
+
},
|
|
941
|
+
modelModifiers: {}
|
|
942
|
+
}),
|
|
943
|
+
emits: /* @__PURE__ */ C(["update:modelValue"], ["update:modelValue"]),
|
|
944
|
+
setup(t, { emit: o }) {
|
|
945
|
+
const s = t, n = G(t, "modelValue"), a = h(() => {
|
|
946
|
+
const i = /* @__PURE__ */ new Map();
|
|
947
|
+
return s.options.forEach((l, c) => {
|
|
948
|
+
if (typeof l == "string" && (l = d(c, l)), l.children) {
|
|
949
|
+
const b = /* @__PURE__ */ new Map();
|
|
950
|
+
l.children.forEach((_, z) => {
|
|
951
|
+
typeof _ == "string" && (_ = d(z, _)), b.set(_.value, _);
|
|
952
|
+
}), l = { ...l }, l.children = b, i.set(l.value, l);
|
|
953
|
+
} else
|
|
954
|
+
i.set(l.value, l);
|
|
955
|
+
}), i;
|
|
956
|
+
}), e = h(() => {
|
|
957
|
+
const i = /* @__PURE__ */ new Map();
|
|
958
|
+
return a.value.forEach((l) => {
|
|
959
|
+
if (!l.disabled) {
|
|
960
|
+
if (l.children) {
|
|
961
|
+
l.children.forEach((c) => {
|
|
962
|
+
c.disabled || i.set(c.value, c);
|
|
963
|
+
});
|
|
964
|
+
return;
|
|
965
|
+
}
|
|
966
|
+
i.set(l.value, l);
|
|
967
|
+
}
|
|
968
|
+
}), i;
|
|
969
|
+
}), d = (i, l) => ({
|
|
970
|
+
value: i,
|
|
971
|
+
title: l
|
|
972
|
+
});
|
|
973
|
+
de([
|
|
974
|
+
() => s.modelValue,
|
|
975
|
+
e
|
|
976
|
+
], () => {
|
|
977
|
+
(n.value === null || n.value === void 0) && e.value.size && (console.warn("Пожалуйста, не передавайте в компонент Select значения null и undefined"), n.value = e.value.keys().next().value);
|
|
978
|
+
}, { immediate: !0 });
|
|
979
|
+
const r = h(() => {
|
|
980
|
+
var i;
|
|
981
|
+
return (i = e.value.get(n.value)) == null ? void 0 : i.icon;
|
|
982
|
+
}), f = () => {
|
|
983
|
+
const i = [...e.value.keys()], c = (i.indexOf(n.value) + 1) % i.length;
|
|
984
|
+
n.value = i[c];
|
|
985
|
+
};
|
|
986
|
+
return (i, l) => (p(), m("label", {
|
|
987
|
+
class: w({
|
|
988
|
+
"top-select": !0,
|
|
989
|
+
["top-select-" + i.name]: i.name,
|
|
990
|
+
["top-size_" + i.size]: !0,
|
|
991
|
+
"top-formsCaptionWrapper": !!i.title,
|
|
992
|
+
"top-select-error": i.isError,
|
|
993
|
+
"top-disabled": i.disabled
|
|
994
|
+
}),
|
|
995
|
+
"data-value": n.value,
|
|
996
|
+
"data-top-icon": i.icon,
|
|
997
|
+
"data-top-icon2": r.value
|
|
998
|
+
}, [
|
|
999
|
+
W(S("select", {
|
|
1000
|
+
class: w({
|
|
1001
|
+
"top-forms-focusable": !i.disabled,
|
|
1002
|
+
"top-select_select": !0,
|
|
1003
|
+
"top-select_arrow": !0,
|
|
1004
|
+
"top-error": i.isError
|
|
1005
|
+
}),
|
|
1006
|
+
name: i.name,
|
|
1007
|
+
disabled: i.disabled,
|
|
1008
|
+
"onUpdate:modelValue": l[0] || (l[0] = (c) => n.value = c)
|
|
1009
|
+
}, [
|
|
1010
|
+
(p(!0), m(P, null, F(a.value, ([c, b]) => (p(), m(P, null, [
|
|
1011
|
+
b.children ? (p(), m("optgroup", {
|
|
1012
|
+
key: "group_" + c,
|
|
1013
|
+
label: b.title,
|
|
1014
|
+
disabled: b.disabled
|
|
1015
|
+
}, [
|
|
1016
|
+
(p(!0), m(P, null, F(b.children, ([_, z]) => (p(), m("option", {
|
|
1017
|
+
key: _,
|
|
1018
|
+
value: _,
|
|
1019
|
+
selected: _ === n.value,
|
|
1020
|
+
disabled: z.disabled
|
|
1021
|
+
}, V(z.title), 9, Ot))), 128))
|
|
1022
|
+
], 8, Ct)) : (p(), m("option", {
|
|
1023
|
+
key: c ?? void 0,
|
|
1024
|
+
value: c,
|
|
1025
|
+
selected: c === n.value,
|
|
1026
|
+
disabled: b.disabled
|
|
1027
|
+
}, V(b.title), 9, Ht))
|
|
1028
|
+
], 64))), 256))
|
|
1029
|
+
], 10, Rt), [
|
|
1030
|
+
[pe, n.value]
|
|
1031
|
+
]),
|
|
1032
|
+
i.addChanger && e.value.size && !i.disabled ? (p(), m("span", {
|
|
1033
|
+
key: 0,
|
|
1034
|
+
class: "top-changer",
|
|
1035
|
+
onClick: f
|
|
1036
|
+
})) : g("", !0),
|
|
1037
|
+
i.title ? (p(), m("span", It, V(i.title), 1)) : g("", !0)
|
|
1038
|
+
], 10, Pt));
|
|
1039
|
+
}
|
|
1040
|
+
}), Ut = {
|
|
1041
|
+
"top-select": "top-select",
|
|
1042
|
+
"top-select-error": "top-select-error",
|
|
1043
|
+
"top-select_select": "top-select_select",
|
|
1044
|
+
"top-changer": "top-changer"
|
|
1045
|
+
}, Xt = {
|
|
1046
|
+
$style: Ut
|
|
1047
|
+
}, Yt = /* @__PURE__ */ y(Ft, [["__cssModules", Xt]]), ao = ze, no = Re, io = Ke, ro = A, lo = Z, po = O, uo = mt, co = yt, mo = kt, fo = Bt, bo = Nt, ho = Yt, go = j;
|
|
1048
|
+
export {
|
|
1049
|
+
jt as A,
|
|
1050
|
+
be as B,
|
|
1051
|
+
u as C,
|
|
1052
|
+
xt as D,
|
|
1053
|
+
ve as E,
|
|
1054
|
+
eo as F,
|
|
1055
|
+
to as G,
|
|
1056
|
+
oo as H,
|
|
1057
|
+
ke as I,
|
|
1058
|
+
so as J,
|
|
1059
|
+
X as K,
|
|
1060
|
+
Re as T,
|
|
1061
|
+
_e as _,
|
|
1062
|
+
y as a,
|
|
1063
|
+
O as b,
|
|
1064
|
+
ao as c,
|
|
1065
|
+
B as d,
|
|
1066
|
+
no as e,
|
|
1067
|
+
io as f,
|
|
1068
|
+
ro as g,
|
|
1069
|
+
lo as h,
|
|
1070
|
+
Gt as i,
|
|
1071
|
+
po as j,
|
|
1072
|
+
uo as k,
|
|
1073
|
+
co as l,
|
|
1074
|
+
go as m,
|
|
1075
|
+
mo as n,
|
|
1076
|
+
ho as o,
|
|
1077
|
+
fo as p,
|
|
1078
|
+
bo as q,
|
|
1079
|
+
Nt as r,
|
|
1080
|
+
j as s,
|
|
1081
|
+
ue as t,
|
|
1082
|
+
ce as u,
|
|
1083
|
+
me as v,
|
|
1084
|
+
fe as w,
|
|
1085
|
+
Qt as x,
|
|
1086
|
+
Jt as y,
|
|
1087
|
+
Zt as z
|
|
1088
|
+
};
|
|
1089
|
+
//# sourceMappingURL=forms-BfIXIMY_.es.js.map
|