@topvisor/ui 1.0.41-dialog.1 → 1.0.42-checkvisibility.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.chunks/{core-CwjGTMhd.es.js → core-BAG3GPtC.es.js} +4 -4
- package/.chunks/{core-CwjGTMhd.es.js.map → core-BAG3GPtC.es.js.map} +1 -1
- package/.chunks/{core-D2o3elGA.amd.js → core-BW5pBSkC.amd.js} +2 -2
- package/.chunks/{core-D2o3elGA.amd.js.map → core-BW5pBSkC.amd.js.map} +1 -1
- package/.chunks/{datepicker-Byyye2pn.amd.js → datepicker-BWaVsTd0.amd.js} +2 -2
- package/.chunks/{datepicker-Byyye2pn.amd.js.map → datepicker-BWaVsTd0.amd.js.map} +1 -1
- package/.chunks/{datepicker-N83oX3hx.es.js → datepicker-DCDYQmsc.es.js} +2 -2
- package/.chunks/{datepicker-N83oX3hx.es.js.map → datepicker-DCDYQmsc.es.js.map} +1 -1
- package/.chunks/{dialog_selectorRegions-pDIYvl7b.amd.js → dialog_selectorRegions-C-MZasKk.amd.js} +2 -2
- package/.chunks/{dialog_selectorRegions-pDIYvl7b.amd.js.map → dialog_selectorRegions-C-MZasKk.amd.js.map} +1 -1
- package/.chunks/{dialog_selectorRegions-lYV2SJBx.es.js → dialog_selectorRegions-DhFJmdQM.es.js} +4 -4
- package/.chunks/{dialog_selectorRegions-lYV2SJBx.es.js.map → dialog_selectorRegions-DhFJmdQM.es.js.map} +1 -1
- package/.chunks/dialogs.vue_vue_type_script_setup_true_lang-B92h9NoR.amd.js +2 -0
- package/.chunks/dialogs.vue_vue_type_script_setup_true_lang-B92h9NoR.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-LxNjWbxU.es.js} +113 -97
- package/.chunks/dialogs.vue_vue_type_script_setup_true_lang-LxNjWbxU.es.js.map +1 -0
- package/.chunks/{forms-C-fyoosd.es.js → forms-DOGPN_TR.es.js} +480 -468
- package/.chunks/{forms-C-fyoosd.es.js.map → forms-DOGPN_TR.es.js.map} +1 -1
- package/.chunks/forms-Gb7ujpmz.amd.js +3 -0
- package/.chunks/{forms-DO87ZZk9.amd.js.map → forms-Gb7ujpmz.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-CF_hIWa6.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-CF_hIWa6.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-CJQj81Yq.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-CJQj81Yq.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-CczcI_-j.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-CczcI_-j.amd.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-Dq5eEX9i.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-Dq5eEX9i.es.js.map} +1 -1
- package/.chunks/{notice-B8nfJMJN.amd.js → notice-C5sXcBql.amd.js} +2 -2
- package/.chunks/{notice-B8nfJMJN.amd.js.map → notice-C5sXcBql.amd.js.map} +1 -1
- package/.chunks/{notice-DCONQ8rR.es.js → notice-DE88Oe-t.es.js} +2 -2
- package/.chunks/{notice-DCONQ8rR.es.js.map → notice-DE88Oe-t.es.js.map} +1 -1
- package/.chunks/{page.vue_vue_type_script_setup_true_lang-Dze2ZUr3.es.js → page.vue_vue_type_script_setup_true_lang-DV1TJ_hF.es.js} +4 -4
- package/.chunks/page.vue_vue_type_script_setup_true_lang-DV1TJ_hF.es.js.map +1 -0
- package/.chunks/{page.vue_vue_type_script_setup_true_lang-Cg3dLy7K.amd.js → page.vue_vue_type_script_setup_true_lang-wVql7Y7c.amd.js} +2 -2
- package/.chunks/page.vue_vue_type_script_setup_true_lang-wVql7Y7c.amd.js.map +1 -0
- package/.chunks/popup-B_8bvIsF.amd.js +2 -0
- package/.chunks/{popup-XXfdNLmr.amd.js.map → popup-B_8bvIsF.amd.js.map} +1 -1
- package/.chunks/{popup-PpCQY5Zi.es.js → popup-BjsK_pMZ.es.js} +106 -80
- package/.chunks/{popup-PpCQY5Zi.es.js.map → popup-BjsK_pMZ.es.js.map} +1 -1
- package/.chunks/{utils-DAIrXU57.amd.js → utils-BYruuiOR.amd.js} +2 -2
- package/.chunks/{utils-DAIrXU57.amd.js.map → utils-BYruuiOR.amd.js.map} +1 -1
- package/.chunks/utils-BbbR1pxf.amd.js +2 -0
- package/.chunks/utils-BbbR1pxf.amd.js.map +1 -0
- package/.chunks/{utils-BcKnFj1j.es.js → utils-CB-BjgcP.es.js} +242 -166
- package/.chunks/utils-CB-BjgcP.es.js.map +1 -0
- package/.chunks/{utils-DsICGMuv.es.js → utils-DtQUyz9-.es.js} +2 -2
- package/.chunks/{utils-DsICGMuv.es.js.map → utils-DtQUyz9-.es.js.map} +1 -1
- 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/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/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/useMenu.d.ts +2 -0
- package/components/formsExt/selector2/selector2.vue.d.ts +5 -180
- package/components/formsExt/selector2/types.d.ts +17 -8
- 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 +17 -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 +320 -283
- 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.js +2 -2
- package/project/project.amd.js +1 -1
- package/project/project.js +5 -5
- 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 +44 -27
- 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.js +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-XXfdNLmr.amd.js +0 -2
- 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
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { u as
|
|
1
|
+
import { u as k, C as f } from "./forms-DOGPN_TR.es.js";
|
|
2
2
|
import i from "../utils/dom.js";
|
|
3
|
-
import { TopPopupWorker as
|
|
4
|
-
class
|
|
3
|
+
import { TopPopupWorker as l } from "../popup/worker.js";
|
|
4
|
+
class P {
|
|
5
5
|
static componentName = "Top";
|
|
6
6
|
componentName;
|
|
7
7
|
// имя класса компонента
|
|
@@ -21,7 +21,7 @@ class x {
|
|
|
21
21
|
init(t, p, o) {
|
|
22
22
|
if (!p)
|
|
23
23
|
throw t + ": el is undefined";
|
|
24
|
-
const e =
|
|
24
|
+
const e = P.getComponent(p, t);
|
|
25
25
|
if (e)
|
|
26
26
|
return e.reInit(o), e;
|
|
27
27
|
this.componentName = t, this.className = "top" + t[0].toUpperCase() + t.substring(1), this.uid = this.componentName + (Math.random() + "").replace(".", ""), this._setComponent(p), this.el = p, this.el.classList.add(this.className), this.options = Object.assign(this.options, o), this.mount();
|
|
@@ -56,13 +56,13 @@ class x {
|
|
|
56
56
|
}
|
|
57
57
|
// указание новые события, которые должны будут удалиться после unmount
|
|
58
58
|
registerEventForUnmount(t, p, o, e) {
|
|
59
|
-
const
|
|
59
|
+
const r = {
|
|
60
60
|
el: t,
|
|
61
61
|
type: p,
|
|
62
62
|
listener: o,
|
|
63
63
|
options: e
|
|
64
64
|
};
|
|
65
|
-
this.unmountEvents.push(
|
|
65
|
+
this.unmountEvents.push(r);
|
|
66
66
|
}
|
|
67
67
|
// функция перенастройки уже подключенного компонента
|
|
68
68
|
reInit(t) {
|
|
@@ -82,7 +82,7 @@ class x {
|
|
|
82
82
|
}
|
|
83
83
|
}
|
|
84
84
|
}
|
|
85
|
-
class
|
|
85
|
+
class I {
|
|
86
86
|
static isInited = !1;
|
|
87
87
|
/**
|
|
88
88
|
* Добавить глобальные обработчики
|
|
@@ -101,13 +101,13 @@ class y {
|
|
|
101
101
|
var o;
|
|
102
102
|
if (!(!(t.target instanceof HTMLElement) || !t.target.closest(".top-popup-wrapper"))) {
|
|
103
103
|
if (t.target.matches("[data-top-popup]")) {
|
|
104
|
-
const e = t.target.closest("ul"),
|
|
105
|
-
e && ((o = e.querySelector("a.top-active, .a.top-active")) == null || o.classList.remove("top-active")),
|
|
104
|
+
const e = t.target.closest("ul"), r = t.target.closest("a, .a");
|
|
105
|
+
e && ((o = e.querySelector("a.top-active, .a.top-active")) == null || o.classList.remove("top-active")), r && r.classList.add("top-active"), t.stopPropagation();
|
|
106
106
|
return;
|
|
107
107
|
}
|
|
108
108
|
if (t.target.matches(".top-popup-wrapper")) {
|
|
109
109
|
const e = t.target;
|
|
110
|
-
|
|
110
|
+
l.close(e), t.stopPropagation();
|
|
111
111
|
return;
|
|
112
112
|
}
|
|
113
113
|
}
|
|
@@ -124,14 +124,14 @@ class y {
|
|
|
124
124
|
const o = t.target.closest(".top-popup-wrapper");
|
|
125
125
|
if (!o || p.matches(".top-popup-noCloser"))
|
|
126
126
|
return;
|
|
127
|
-
p.getAttribute("href") === "." && t.preventDefault(),
|
|
127
|
+
p.getAttribute("href") === "." && t.preventDefault(), l.close(o);
|
|
128
128
|
}
|
|
129
129
|
}
|
|
130
130
|
/**
|
|
131
131
|
* Глобальный обработчик нажатия кнопки на клавиатуре
|
|
132
132
|
*/
|
|
133
133
|
static onkeydown(t) {
|
|
134
|
-
var e,
|
|
134
|
+
var e, r;
|
|
135
135
|
if (!(t.target instanceof HTMLElement)) return;
|
|
136
136
|
const p = t.target.closest(".top-popup-wrapper");
|
|
137
137
|
if (!p)
|
|
@@ -139,25 +139,25 @@ class y {
|
|
|
139
139
|
const o = p.querySelector("ul.top-popup_content");
|
|
140
140
|
switch (t.key) {
|
|
141
141
|
case "Escape":
|
|
142
|
-
|
|
142
|
+
l.close(p);
|
|
143
143
|
break;
|
|
144
144
|
case "Enter":
|
|
145
145
|
if (!o) {
|
|
146
146
|
if (i.querySelectorVisible(p, ".preloader"))
|
|
147
147
|
break;
|
|
148
|
-
const
|
|
149
|
-
if (
|
|
150
|
-
|
|
148
|
+
const a = i.querySelectorVisible(p, ".top-popup_footer .go, .top-popup_footer [data-action]");
|
|
149
|
+
if (a instanceof HTMLElement) {
|
|
150
|
+
a.click();
|
|
151
151
|
break;
|
|
152
152
|
}
|
|
153
|
-
let
|
|
154
|
-
|
|
153
|
+
let g = i.querySelectorVisibleLast(p, ".top-popup_footer .top-button:focus");
|
|
154
|
+
g || (g = i.querySelectorVisibleLast(p, ".top-popup_footer .top-button")), g instanceof HTMLElement && g.click();
|
|
155
155
|
break;
|
|
156
156
|
}
|
|
157
|
-
const
|
|
158
|
-
|
|
159
|
-
const
|
|
160
|
-
|
|
157
|
+
const n = i.querySelectorVisible(p, "li > a.top-active");
|
|
158
|
+
n && n.getAttribute("href") && (t.preventDefault(), location.href = n.getAttribute("href"));
|
|
159
|
+
const c = p.querySelector("li > .top-active");
|
|
160
|
+
c instanceof HTMLElement && c.click();
|
|
161
161
|
break;
|
|
162
162
|
// управление стрелками
|
|
163
163
|
case "ArrowUp":
|
|
@@ -170,30 +170,30 @@ class y {
|
|
|
170
170
|
p,
|
|
171
171
|
"ul.top-popup_content > li:not(.top-popup_liNoSelectable) > .top-active > .top-popup_listMore"
|
|
172
172
|
) && t.preventDefault() : t.preventDefault();
|
|
173
|
-
const
|
|
174
|
-
if (t.key === "ArrowRight" &&
|
|
175
|
-
const
|
|
176
|
-
if (
|
|
177
|
-
return
|
|
173
|
+
const h = (e = p.querySelector("ul.top-popup_content > li:not(.top-popup_liNoSelectable) > .top-active")) == null ? void 0 : e.parentElement;
|
|
174
|
+
if (t.key === "ArrowRight" && h) {
|
|
175
|
+
const a = h.querySelector(".top-active > .top-popup_listMore");
|
|
176
|
+
if (a instanceof HTMLElement)
|
|
177
|
+
return a.click();
|
|
178
178
|
}
|
|
179
|
-
const
|
|
180
|
-
if (!
|
|
179
|
+
const u = i.querySelectorAllVisible(p, "ul.top-popup_content > li:not(.top-popup_liNoSelectable)"), m = u.length;
|
|
180
|
+
if (!m)
|
|
181
181
|
return;
|
|
182
|
-
let
|
|
183
|
-
if (
|
|
184
|
-
return t.target.matches("input") ? void 0 :
|
|
185
|
-
if (t.key === "ArrowRight" &&
|
|
182
|
+
let d = -1;
|
|
183
|
+
if (h && (d = u.indexOf(h)), t.key === "ArrowUp" || t.key === "ArrowLeft" ? d-- : d++, t.key === "ArrowLeft" && d === -1)
|
|
184
|
+
return t.target.matches("input") ? void 0 : l.close(p);
|
|
185
|
+
if (t.key === "ArrowRight" && d === m)
|
|
186
186
|
return;
|
|
187
|
-
|
|
187
|
+
d < 0 && (d = m - 1), d > m - 1 && (d = 0), p.querySelectorAll("ul.top-popup_content > li > .top-active").forEach((a) => a.classList.remove("top-active")), (r = u[d].querySelector(":scope > a, :scope > .a")) == null || r.classList.add("top-active"), l.scrollToActive(p);
|
|
188
188
|
break;
|
|
189
189
|
}
|
|
190
190
|
}
|
|
191
191
|
}
|
|
192
|
-
const _ = ":root{--top-popup-z-index: 200000;--top-popup-transition-delay: .1s;--top-popup-background-color: var(--color-layout-front-1);--top-popup-background-color-hover: var(--color-layout-front-3);--top-popup-background-color-active: var(--color-layout-front-4);--top-popup-border-color: var(--color-line-2-opacity);--top-popup-title-background-color: var(--color-layer-1);--top-popup-content-padding: calc(var(--top-popup-list-padding) + var(--top-popup-listItem-padding));--top-popup-list-padding: var(--top-padding-2);--top-popup-listItem-radius: var(--top-radius-2);--top-popup-listItem-padding: var(--top-padding-2)}.top-popup-front{position:relative}.top-popup-wrapper{--top-popup-height: 0px;--top-popup-right-bounding: 0px;--top-popup-bottom-bounding: 0px;--top-popup-top: 0px;--top-popup-right: calc(100vw - var(--top-popup-right-bounding));--top-popup-bottom: calc(var(--100vh) - var(--top-popup-bottom-bounding));--top-popup-left: 0px;text-align:initial;white-space:normal;word-break:normal;position:absolute;z-index:200000}.top-popup-wrapper:not(.top-popup-wrapper-shown){overflow:hidden}.top-popupPanel{cursor:default;box-shadow:var(--top-shadow-b);border-radius:14px;background:var(--top-popup-background-color);position:absolute;overflow:hidden;display:flex;flex-direction:column}.top-popup-wrapper>*{opacity:0;transition:opacity var(--top-popup-transition-delay) linear,transform var(--top-popup-transition-delay) linear}.top-popup-wrapper.p0>*{transform:translateY(-8px)}.top-popup-wrapper.p1>*{transform:translateY(8px)}.top-popup-wrapper.p2>*{transform:translate(8px)}.top-popup-wrapper.p3>*{transform:translateY(8px)}.top-popup-wrapper.p4>*{transform:translate(-8px)}.top-popup-wrapper-shown:not(.top-popup-wrapper-closed)>*{opacity:1;transform:translate(0)!important}.top-popup-wrapper.p0>.top-popup{top:-16px;left:-8px}.top-popup-wrapper.p1>.top-popup{bottom:calc(100% + 8px)}.top-popup-wrapper.p2>.top-popup{left:calc(100% + 8px)}.top-popup-wrapper.p3>.top-popup{top:calc(100% + 8px)}.top-popup-wrapper.p4>.top-popup{right:calc(100% + 8px)}.top-popup-wrapper.p2>.top-popup,.top-popup-wrapper.p4>.top-popup{margin-top:-10px}.top-popup-wrapper.p2.invert-y>.top-popup,.top-popup-wrapper.p4.invert-y>.top-popup{margin-bottom:-10px}.top-popup-wrapper.p1.with_notch>.top-popup{margin-bottom:5px}.top-popup-wrapper.p2.with_notch>.top-popup{margin-left:5px}.top-popup-wrapper.p3.with_notch>.top-popup{margin-top:5px}.top-popup-wrapper.p4.with_notch>.top-popup{margin-right:5px}.top-popup-wrapper.invert-x>.top-popup{right:0}.top-popup-wrapper.invert-y>.top-popup{bottom:0}.top-popup-wrapper>.notch{border:7.4px solid transparent;position:absolute;display:block}.top-popup-wrapper.p1>.notch{border-bottom:0;border-top:7.4px solid var(--color-layout-front-1);margin:0 0 7.4px -7.4px;bottom:100%;left:50%}.top-popup-wrapper.p2>.notch{border-left:0;border-right:7.4px solid var(--color-layout-front-1);margin:0 0 -7.4px 7.4px;bottom:50%;left:100%}.top-popup-wrapper.p3>.notch{border-top:0;border-bottom:7.4px solid var(--color-layout-front-1);margin:7.4px 0 0 -7.4px;top:100%;left:50%}.top-popup-wrapper.p4>.notch{border-right:0;border-left:7.4px solid var(--color-layout-front-1);margin:0 7.4px -7.4px 0;bottom:50%;right:100%}.top-popup-wrapper.p1>.notch-border{border-top-color:#0000000d;margin-bottom:6px}.top-popup-wrapper.p2>.notch-border{border-right-color:#0000000d;margin-left:6px}.top-popup-wrapper.p3>.notch-border{border-bottom-color:#0000000d;margin-top:6px}.top-popup-wrapper.p4>.notch-border{border-left-color:#0000000d;margin-right:6px}.top-popup_header,.top-popup_content,.top-popup_footer{font-size:14px}.top-popup_header,.top-popup_footer{display:flex;align-items:center;justify-content:space-between}.top-popup_header{color:var(--color-text-1);border-bottom:1px solid var(--top-popup-border-color);padding:var(--top-padding-3);font-weight:600}.top-popup_header>*{font-weight:400}.top-popup_header>.a{cursor:pointer}.top-popup_header>.a:hover{color:var(--color-text-primary)}.top-popup_headerButton{width:60px}.top-popup_widget{padding:var(--top-padding-2)}.top-popup_content{margin:0;flex-grow:1;overflow-y:auto;display:flex;flex-direction:column;gap:var(--top-gap-4);-webkit-overflow-scrolling:touch}div.top-popup_content{color:var(--color-text-1);padding:var(--top-popup-content-padding)}div.top-popup_content>*{flex-shrink:0}div.top-popup_content>.top-button{margin:0}div.top-popup_content .top-unwrap{--top-unwrap-x: var(--top-popup-content-padding)}ul.top-popup_content{color:var(--color-text-1);padding:var(--top-popup-list-padding);gap:2px}ul.top-popup_content .top-unwrap{--top-unwrap-x: var(--top-popup-list-padding)}.top-popup_listItem{border-radius:var(--top-popup-listItem-radius);padding:var(--top-popup-listItem-padding);line-height:1!important}ul.top-popup_content li{margin:0;list-style:none;display:flex;position:relative}ul.top-popup_content li>*{flex-grow:1}ul.top-popup_content li>a:not(.top-button),ul.top-popup_content li>.a{cursor:pointer;box-sizing:border-box;border-radius:var(--top-popup-listItem-radius);background:var(--top-popup-background-color);padding:var(--top-popup-listItem-padding);color:var(--color-text-1)!important;font-size:14px;font-weight:400!important;text-decoration:none!important;font-style:normal;line-height:1!important;display:flex;flex:1 1 100%;align-items:center;transition:background-color .1s ease-in-out}.top-popup-wrapper-no_animate ul.top-popup_content li>a:not(.top-button),.top-popup-wrapper-no_animate ul.top-popup_content li>.a{transition:none}ul.top-popup_content li>a:not(.top-button):hover,ul.top-popup_content li>.a:hover{background:var(--top-popup-background-color-hover)}ul.top-popup_content li>a:not(.top-button).top-active,ul.top-popup_content li>.a.top-active{--top-icon-color: var(--color-text-primary) !important;background:var(--top-popup-background-color-active)}.top-popup_content+.top-popup_content{padding-top:0}.top-popup_listItem-title{background:var(--color-layer-1);color:var(--color-text-1);font-size:12px}.top-popup_listItem-delimiter{border-radius:3px;background:var(--top-popup-border-color);height:1px;padding:0;margin:4px}.top-popup_listMore{font-size:20px;margin:calc(0px - var(--top-popup-listItem-padding)) calc(0px - var(--top-popup-listItem-padding) / 2) calc(0px - var(--top-popup-listItem-padding)) 0}.top-popup_listMore.top-button{margin:0}ul.top-popup_content li>.a.top-popup_listMore{text-align:center;flex-basis:10px}ul.top-popup_content li>.a.top-popup_listMore:before{color:var(--color-text-2)}ul.top-popup_content li>*>.top-popup_listMore{margin-left:auto;color:var(--color-layer-4);font-size:14px}ul.top-popup_content li>*>i.top-popup_listMore:hover,ul.top-popup_content li>*>i.top-popup_listMore.top-active{color:var(--color-text-primary)}ul.top-popup_content li>*>i.top-popup_listMore:before{transform:rotate(90deg);display:block}ul.top-popup_content li a.close{background:none!important}.top-popup_content>[data-top-icon]:before{--top-icon-size: 20px}ul.top-popup_content li>[data-top-icon]:not(.top-button){--top-icon-color: var(--color-text-3);--top-icon-size: 20px;--top-icon-width: 20px}ul.top-popup_content li>[data-top-icon]:not(.top-button):before{height:1rem;margin-right:8px;transition:color .1s}ul.top-popup_content li:hover>[data-top-icon]:not(.top-button){--top-icon-color: var(--color-text-2)}.top-popup_footer{padding:var(--top-padding-3);border-top:1px solid var(--top-popup-border-color);display:flex;gap:var(--top-gap-2);justify-content:flex-end}.top-popup_footerSupportLink{margin-right:auto}.top-popup>[data-widget]{padding:0 var(--top-popup-list-padding)}.top-popup>[data-widget]+hr{margin:0 var(--top-popup-list-padding)}.top-popup .placeholder{border:1px solid #E0D9D9!important;border-right:none!important;border-left:none!important;background:#f9f9f9!important;margin:-1px 0;z-index:1;position:relative}.top-popup-wrapper.simple_list>.top-popup{min-width:0;white-space:nowrap}.top-popup_content .top-column{display:flex;flex-direction:column;gap:4px}html .top-popup .top-popup_content li>.top-button{margin:calc(var(--top-popup-listItem-padding) / 2) var(--top-popup-listItem-padding)}.top-popup li .check_all,.top-popup li .clear_all{cursor:pointer;color:var(--color-text-primary);padding:8px;display:inline-block}.top-popup li .check_all:hover,.top-popup li .clear_all:hover{text-decoration:underline}.top-popup li .clear_all{display:none}.top-popup_content table{margin:-9px 0}.top-popup_content table td,.top-popup_content table th{padding:9px var(--top-popup-listItem-padding) 9px 0;vertical-align:top}.top-popup_content table th{width:40%;font-weight:600;white-space:nowrap}ul.top-popup_content .a>[type=checkbox],ul.top-popup_content .a>[type=radio]{margin:-8px 0 -8px auto}ul.top-popup_content a>[class*=icon],ul.top-popup_content i.a>[class*=icon]{transition:.1s}.top-popup .buttons{border-radius:0 0 4px 4px;border-top:1px solid #BDC3C7;background:#ecf0f1;padding:10px 15px;margin:10px -15px -10px;white-space:nowrap}.top-popup_footer [class*=btn]:not(.btn-transparent){min-width:100px;padding:5px 14px;margin-left:10px}.top-popup_footer [class*=btn]:first-child{margin-left:0}.top-popup_footer .btn.full_width{margin:0;flex-grow:1}", L = ":root{--top-popup-list-padding: 0px;--top-popup-listItem-radius: 0px;--top-popup-listItem-padding: var(--top-padding-4)}html.with_popup{background:gray}.top-popup-wrapper{--top-popup-footer-offset: 25px;width:auto!important;height:auto!important;position:fixed;top:0!important;right:0!important;left:0!important;overflow:hidden;transition:background .3s}.top-popup-wrapper-shown:not(.top-popup-wrapper-closed){background:#00000080;-webkit-backdrop-filter:blur(1px);backdrop-filter:blur(1px)}.top-popup-wrapper-shown:not(.top-popup-wrapper-closed)>.top-popup{opacity:1!important}.top-popup{border-radius:8px 8px 0 0;width:auto!important;max-height:calc(100% - var(--header-height, 0px) - var(--toolbar-height, 0px) - 12px);margin:0!important;top:auto!important;right:0!important;bottom:var(--toolbar-height, 0px)!important;left:0!important;display:flex;flex-direction:column;transform:translateY(80%);transition:opacity .3s,transform .3s}.top-popup-wrapper.p-from-top{--top-popup-footer-offset: 0px;top:var(--header-height, 0px)!important}.with_dialog .top-popup-wrapper.p-from-top{top:50px!important}.top-popup-wrapper.p-from-top>.top-popup{border-radius:0 0 8px 8px;max-height:calc(100% - 24px);top:0!important;bottom:auto!important;transform:translateY(calc(-100% - 24px))}.top-popup_widget:not(.p-from-top){order:10}ul.top-popup_content{gap:0}ul.top-popup_content li:not(:last-child){border-bottom:1px solid var(--top-popup-border-color)}.top-popup-wrapper.top-style_alt>.top-popup>ul>li{border-bottom:none}.top-popup_footer{flex-direction:column-reverse}.top-popup_footer>.top-button{--top-forms-base-height: var(--top-forms-base-height_l);width:100%}ul.top-popup_content .top-popup_listItem-title{--top-popup-padding-v: 12px}ul.top-popup_content .top-popup_listItem-delimiter{background:var(--color-line-1-opacity);height:4px;margin:0}ul.top-popup_content li:first-child>.top-popup_listItem-delimiter{border-top:1px solid var(--top-popup-border-color)}", E = ".top-popup{min-width:250px;max-width:calc(100vw - var(--top-popup-left) - 16px);max-height:calc(var(--top-popup-bottom) + var(--top-popup-height))}.top-popup-wrapper.invert-x>.top-popup{max-width:calc(100vw - var(--top-popup-right) - 16px)}.top-popup-wrapper.invert-y>.top-popup{max-height:calc(100vh - var(--top-popup-bottom) - 16px)}.top-popup-wrapper.p1>.top-popup{max-height:calc(var(--top-popup-top) - var(--header-height, 0px) - 16px)}.top-popup-wrapper.p3>.top-popup{max-height:calc(var(--top-popup-bottom) - 16px)}.top-popup-wrapper.p2>.top-popup{max-width:calc(var(--top-popup-right) - 16px)}.top-popup-wrapper.p4>.top-popup{max-width:calc(var(--top-popup-left) - 16px)}.top-popup-wrapper.p1.with_notch>.top-popup,.top-popup-wrapper.p3.with_notch>.top-popup{margin-left:-16px!important}.top-popup-wrapper.p1.with_notch>.notch,.top-popup-wrapper.p3.with_notch>.notch{margin-left:-8px!important}.top-popup-wrapper.p1.with_notch.invert-x,.top-popup-wrapper.p3.with_notch.invert-x{margin-left:3px!important}.top-popup-wrapper.p1.with_notch.invert-x>.notch,.top-popup-wrapper.p3.with_notch.invert-x>.notch{margin-left:-9px!important}ul.top-popup_content li>*>i.top-popup_listMore{visibility:hidden;transition:none}ul.top-popup_content li:hover>*>i.top-popup_listMore,ul.top-popup_content li>*.top-active>i.top-popup_listMore,ul.top-popup_content li>*>i.top-popup_listMore.top-active{visibility:visible}";
|
|
193
|
-
f.insertStyleToPage(
|
|
194
|
-
f.insertStyleToPage(
|
|
195
|
-
f.insertStyleToPage(
|
|
196
|
-
class
|
|
192
|
+
const S = ":root{--top-popup-z-index: 200000;--top-popup-transition-delay: .1s;--top-popup-offset: var(--top-padding-2);--top-popup-background-color: var(--color-layout-front-1);--top-popup-background-color-hover: var(--color-layout-front-3);--top-popup-background-color-active: var(--color-layout-front-4);--top-popup-border-color: var(--color-line-2-opacity);--top-popup-title-background-color: var(--color-layer-1);--top-popup-content-padding: calc(var(--top-popup-list-padding) + var(--top-popup-listItem-padding));--top-popup-list-padding: var(--top-padding-2);--top-popup-listItem-radius: var(--top-radius-2);--top-popup-listItem-padding: var(--top-padding-2)}.top-popup-front{position:relative}.top-popup-wrapper{--top-popup-height: 0px;--top-popup-right-bounding: 0px;--top-popup-bottom-bounding: 0px;--top-popup-top: 0px;--top-popup-right: calc(100vw - var(--top-popup-right-bounding));--top-popup-bottom: calc(var(--100vh) - var(--top-popup-bottom-bounding));--top-popup-left: 0px;--top-popup-margin: -10px;text-align:initial;white-space:normal;word-break:normal;position:absolute;z-index:200000}.top-popup-wrapper:not(.top-popup-wrapper-shown){overflow:hidden}.top-popupPanel{cursor:default;box-shadow:var(--top-shadow-b);border-radius:14px;background:var(--top-popup-background-color);position:absolute;overflow:hidden;display:flex;flex-direction:column}.top-popup-wrapper>*{opacity:0;transition:opacity var(--top-popup-transition-delay) linear,transform var(--top-popup-transition-delay) linear}.top-popup-wrapper.p0>*{transform:translateY(-8px)}.top-popup-wrapper.p1>*{transform:translateY(8px)}.top-popup-wrapper.p2>*{transform:translate(8px)}.top-popup-wrapper.p3>*{transform:translateY(8px)}.top-popup-wrapper.p4>*{transform:translate(-8px)}.top-popup-wrapper-shown:not(.top-popup-wrapper-closed)>*{opacity:1;transform:translate(0)!important}.top-popup-wrapper.p0>.top-popup{top:-16px;left:-8px}.top-popup-wrapper.p1>.top-popup{bottom:calc(100% + 8px)}.top-popup-wrapper.p2>.top-popup{left:calc(100% + 8px)}.top-popup-wrapper.p3>.top-popup{top:calc(100% + 8px)}.top-popup-wrapper.p4>.top-popup{right:calc(100% + 8px)}.top-popup-wrapper.p2>.top-popup,.top-popup-wrapper.p4>.top-popup{margin-top:var(--top-popup-margin)}.top-popup-wrapper.p2.invert-y>.top-popup,.top-popup-wrapper.p4.invert-y>.top-popup{margin-bottom:var(--top-popup-margin)}.top-popup-wrapper.p1.with_notch>.top-popup{margin-bottom:5px}.top-popup-wrapper.p2.with_notch>.top-popup{margin-left:5px}.top-popup-wrapper.p3.with_notch>.top-popup{margin-top:5px}.top-popup-wrapper.p4.with_notch>.top-popup{margin-right:5px}.top-popup-wrapper.invert-x>.top-popup{right:0}.top-popup-wrapper.invert-y>.top-popup{bottom:0}.top-popup-wrapper>.notch{border:7.4px solid transparent;position:absolute;display:block}.top-popup-wrapper.p1>.notch{border-bottom:0;border-top:7.4px solid var(--color-layout-front-1);margin:0 0 7.4px -7.4px;bottom:100%;left:50%}.top-popup-wrapper.p2>.notch{border-left:0;border-right:7.4px solid var(--color-layout-front-1);margin:0 0 -7.4px 7.4px;bottom:50%;left:100%}.top-popup-wrapper.p3>.notch{border-top:0;border-bottom:7.4px solid var(--color-layout-front-1);margin:7.4px 0 0 -7.4px;top:100%;left:50%}.top-popup-wrapper.p4>.notch{border-right:0;border-left:7.4px solid var(--color-layout-front-1);margin:0 7.4px -7.4px 0;bottom:50%;right:100%}.top-popup-wrapper.p1>.notch-border{border-top-color:#0000000d;margin-bottom:6px}.top-popup-wrapper.p2>.notch-border{border-right-color:#0000000d;margin-left:6px}.top-popup-wrapper.p3>.notch-border{border-bottom-color:#0000000d;margin-top:6px}.top-popup-wrapper.p4>.notch-border{border-left-color:#0000000d;margin-right:6px}.top-popup_header,.top-popup_content,.top-popup_footer{font-size:14px}.top-popup_header,.top-popup_footer{display:flex;align-items:center;justify-content:space-between}.top-popup_header{color:var(--color-text-1);border-bottom:1px solid var(--top-popup-border-color);padding:var(--top-padding-3);font-weight:600}.top-popup_header>*{font-weight:400}.top-popup_header>.a{cursor:pointer}.top-popup_header>.a:hover{color:var(--color-text-primary)}.top-popup_headerButton{width:60px}.top-popup_widget{padding:var(--top-padding-2)}.top-popup_content{margin:0;flex-grow:1;overflow-y:auto;display:flex;flex-direction:column;gap:var(--top-gap-4);-webkit-overflow-scrolling:touch}div.top-popup_content{color:var(--color-text-1);padding:var(--top-popup-content-padding)}div.top-popup_content>*{flex-shrink:0}div.top-popup_content>.top-button{margin:0}div.top-popup_content .top-unwrap{--top-unwrap-x: var(--top-popup-content-padding)}ul.top-popup_content{color:var(--color-text-1);padding:var(--top-popup-list-padding);gap:2px}ul.top-popup_content .top-unwrap{--top-unwrap-x: var(--top-popup-list-padding)}.top-popup_listItem{border-radius:var(--top-popup-listItem-radius);padding:var(--top-popup-listItem-padding);line-height:1!important}ul.top-popup_content li{margin:0;list-style:none;display:flex;position:relative}ul.top-popup_content li>*{flex-grow:1}ul.top-popup_content li>a:not(.top-button),ul.top-popup_content li>.a{cursor:pointer;box-sizing:border-box;border-radius:var(--top-popup-listItem-radius);background:var(--top-popup-background-color);padding:var(--top-popup-listItem-padding);color:var(--color-text-1)!important;font-size:14px;font-weight:400!important;text-decoration:none!important;font-style:normal;line-height:1!important;display:flex;flex:1 1 100%;align-items:center;transition:background-color .1s ease-in-out}.top-popup-wrapper-no_animate ul.top-popup_content li>a:not(.top-button),.top-popup-wrapper-no_animate ul.top-popup_content li>.a{transition:none}ul.top-popup_content li>a:not(.top-button):hover,ul.top-popup_content li>.a:hover{background:var(--top-popup-background-color-hover)}ul.top-popup_content li>a:not(.top-button).top-active,ul.top-popup_content li>.a.top-active{--top-icon-color: var(--color-text-primary) !important;background:var(--top-popup-background-color-active)}.top-popup_content+.top-popup_content{padding-top:0}.top-popup_listItem-title{background:var(--color-layer-1);color:var(--color-text-1);font-size:12px}.top-popup_listItem-delimiter{border-radius:3px;background:var(--top-popup-border-color);height:1px;padding:0;margin:4px}.top-popup_listMore{font-size:20px;margin:calc(0px - var(--top-popup-listItem-padding)) calc(0px - var(--top-popup-listItem-padding) / 2) calc(0px - var(--top-popup-listItem-padding)) 0}.top-popup_listMore.top-button{margin:0}ul.top-popup_content li>.a.top-popup_listMore{text-align:center;flex-basis:10px}ul.top-popup_content li>.a.top-popup_listMore:before{color:var(--color-text-2)}ul.top-popup_content li>*>.top-popup_listMore{margin-left:auto;color:var(--color-layer-4);font-size:14px}ul.top-popup_content li>*>i.top-popup_listMore:hover,ul.top-popup_content li>*>i.top-popup_listMore.top-active{color:var(--color-text-primary)}ul.top-popup_content li>*>i.top-popup_listMore:before{transform:rotate(90deg);display:block}ul.top-popup_content li a.close{background:none!important}.top-popup_content>[data-top-icon]:before{--top-icon-size: 20px}ul.top-popup_content li>[data-top-icon]:not(.top-button){--top-icon-color: var(--color-text-3);--top-icon-size: 20px;--top-icon-width: 20px}ul.top-popup_content li>[data-top-icon]:not(.top-button):before{height:1rem;margin-right:8px;transition:color .1s}ul.top-popup_content li:hover>[data-top-icon]:not(.top-button){--top-icon-color: var(--color-text-2)}.top-popup_footer{padding:var(--top-padding-3);border-top:1px solid var(--top-popup-border-color);display:flex;gap:var(--top-gap-2);justify-content:flex-end}.top-popup_footerSupportLink{margin-right:auto}.top-popup>[data-widget]{padding:0 var(--top-popup-list-padding)}.top-popup>[data-widget]+hr{margin:0 var(--top-popup-list-padding)}.top-popup .placeholder{border:1px solid #E0D9D9!important;border-right:none!important;border-left:none!important;background:#f9f9f9!important;margin:-1px 0;z-index:1;position:relative}.top-popup-wrapper.simple_list>.top-popup{min-width:0;white-space:nowrap}.top-popup_content .top-column{display:flex;flex-direction:column;gap:4px}html .top-popup .top-popup_content li>.top-button{margin:calc(var(--top-popup-listItem-padding) / 2) var(--top-popup-listItem-padding)}.top-popup li .check_all,.top-popup li .clear_all{cursor:pointer;color:var(--color-text-primary);padding:8px;display:inline-block}.top-popup li .check_all:hover,.top-popup li .clear_all:hover{text-decoration:underline}.top-popup li .clear_all{display:none}.top-popup_content table{margin:-9px 0}.top-popup_content table td,.top-popup_content table th{padding:9px var(--top-popup-listItem-padding) 9px 0;vertical-align:top}.top-popup_content table th{width:40%;font-weight:600;white-space:nowrap}ul.top-popup_content .a>[type=checkbox],ul.top-popup_content .a>[type=radio]{margin:-8px 0 -8px auto}ul.top-popup_content a>[class*=icon],ul.top-popup_content i.a>[class*=icon]{transition:.1s}.top-popup .buttons{border-radius:0 0 4px 4px;border-top:1px solid #BDC3C7;background:#ecf0f1;padding:10px 15px;margin:10px -15px -10px;white-space:nowrap}.top-popup_footer [class*=btn]:not(.btn-transparent){min-width:100px;padding:5px 14px;margin-left:10px}.top-popup_footer [class*=btn]:first-child{margin-left:0}.top-popup_footer .btn.full_width{margin:0;flex-grow:1}", M = ":root{--top-popup-list-padding: 0px;--top-popup-listItem-radius: 0px;--top-popup-listItem-padding: var(--top-padding-4)}html.with_popup{background:gray}.top-popup-wrapper{--top-popup-footer-offset: 25px;width:auto!important;height:auto!important;position:fixed;top:0!important;right:0!important;left:0!important;overflow:hidden;transition:background .3s}.top-popup-wrapper-shown:not(.top-popup-wrapper-closed){background:#00000080;-webkit-backdrop-filter:blur(1px);backdrop-filter:blur(1px)}.top-popup-wrapper-shown:not(.top-popup-wrapper-closed)>.top-popup{opacity:1!important}.top-popup{border-radius:8px 8px 0 0;width:auto!important;max-height:calc(100% - var(--header-height, 0px) - var(--toolbar-height, 0px) - 12px);margin:0!important;top:auto!important;right:0!important;bottom:var(--toolbar-height, 0px)!important;left:0!important;display:flex;flex-direction:column;transform:translateY(80%);transition:opacity .3s,transform .3s}.top-popup-wrapper.p-from-top{--top-popup-footer-offset: 0px;top:var(--header-height, 0px)!important}.with_dialog .top-popup-wrapper.p-from-top{top:50px!important}.top-popup-wrapper.p-from-top>.top-popup{border-radius:0 0 8px 8px;max-height:calc(100% - 24px);top:0!important;bottom:auto!important;transform:translateY(calc(-100% - 24px))}.top-popup_widget:not(.p-from-top){order:10}ul.top-popup_content{gap:0}ul.top-popup_content li:not(:last-child){border-bottom:1px solid var(--top-popup-border-color)}.top-popup-wrapper.top-style_alt>.top-popup>ul>li{border-bottom:none}.top-popup_footer{flex-direction:column-reverse}.top-popup_footer>.top-button{--top-forms-base-height: var(--top-forms-base-height_l);width:100%}ul.top-popup_content .top-popup_listItem-title{--top-popup-padding-v: 12px}ul.top-popup_content .top-popup_listItem-delimiter{background:var(--color-line-1-opacity);height:4px;margin:0}ul.top-popup_content li:first-child>.top-popup_listItem-delimiter{border-top:1px solid var(--top-popup-border-color)}", T = ".top-popup{min-width:250px;max-width:calc(100vw - var(--top-popup-left) - 16px);max-height:calc(var(--top-popup-bottom) + var(--top-popup-height))}.top-popup-wrapper.invert-x>.top-popup{max-width:calc(100vw - var(--top-popup-right) - 16px)}.top-popup-wrapper.invert-y>.top-popup{max-height:calc(100vh - var(--top-popup-bottom) - 16px)}.top-popup-wrapper.p1>.top-popup{max-height:calc(var(--top-popup-top) - var(--header-height, 0px) - 16px)}.top-popup-wrapper.p3>.top-popup{max-height:calc(var(--top-popup-bottom) - 16px)}.top-popup-wrapper.p2>.top-popup{max-width:calc(var(--top-popup-right) - 16px)}.top-popup-wrapper.p4>.top-popup{max-width:calc(var(--top-popup-left) - 16px)}.top-popup-wrapper.p1.with_notch>.top-popup,.top-popup-wrapper.p3.with_notch>.top-popup{margin-left:-16px!important}.top-popup-wrapper.p1.with_notch>.notch,.top-popup-wrapper.p3.with_notch>.notch{margin-left:-8px!important}.top-popup-wrapper.p1.with_notch.invert-x,.top-popup-wrapper.p3.with_notch.invert-x{margin-left:3px!important}.top-popup-wrapper.p1.with_notch.invert-x>.notch,.top-popup-wrapper.p3.with_notch.invert-x>.notch{margin-left:-9px!important}ul.top-popup_content li>*>i.top-popup_listMore{visibility:hidden;transition:none}ul.top-popup_content li:hover>*>i.top-popup_listMore,ul.top-popup_content li>*.top-active>i.top-popup_listMore,ul.top-popup_content li>*>i.top-popup_listMore.top-active{visibility:visible}";
|
|
193
|
+
f.insertStyleToPage(S);
|
|
194
|
+
f.insertStyleToPage(M, "m");
|
|
195
|
+
f.insertStyleToPage(T, "pc");
|
|
196
|
+
class x extends P {
|
|
197
197
|
static componentName = "TopPopup";
|
|
198
198
|
// элемент, вызвавший открытие Popup
|
|
199
199
|
elActiveByDefault;
|
|
@@ -250,13 +250,13 @@ class v extends x {
|
|
|
250
250
|
* @param options
|
|
251
251
|
*/
|
|
252
252
|
constructor(t, p) {
|
|
253
|
-
super(), this.init(
|
|
253
|
+
super(), this.init(x.componentName, t, p);
|
|
254
254
|
}
|
|
255
255
|
async mount() {
|
|
256
|
-
var e,
|
|
256
|
+
var e, r;
|
|
257
257
|
if (!(this.el instanceof HTMLElement)) return;
|
|
258
258
|
const t = this.vueGetComponent();
|
|
259
|
-
if (this.el.closest(".top-popup-wrapper") && (this.popupParent =
|
|
259
|
+
if (this.el.closest(".top-popup-wrapper") && (this.popupParent = l.getPopup(this.el.closest(".top-popup-wrapper"))), await this.mountJQuery(), i.css(this.el, "position") !== "absolute" && (this.el.style.position = "relative"), this.el.dataset.topPopupOpened = "opened", this.elActiveByDefault = this.el.classList.contains("top-active"), this.el.classList.add("top-active"), t)
|
|
260
260
|
this.type = "vue", this.options.popup = "", this.elPopup = i.genEl("div", {}, this.options.popup);
|
|
261
261
|
else if ((e = this.options.popup) != null && e.match(/^[#.]/))
|
|
262
262
|
this.type = "selector", this.elPopup = document.querySelector(`${this.options.popup}.template`) || void 0;
|
|
@@ -268,7 +268,7 @@ class v extends x {
|
|
|
268
268
|
if (!this.elPopup || t != null && t.opened) {
|
|
269
269
|
if (this.options.useOriginal || t != null && t.opened) {
|
|
270
270
|
if (t != null && t.opened ? this.elPopup = t.popup.elPopup : this.elPopup = document.querySelector(`${this.options.popup}.top-popup-wrapper-shown`) || void 0, this.elPopup) {
|
|
271
|
-
this.el.dataset.topPopupOpened = "", this.elActiveByDefault || this.el.classList.remove("top-active"),
|
|
271
|
+
this.el.dataset.topPopupOpened = "", this.elActiveByDefault || this.el.classList.remove("top-active"), l.close(this.elPopup), setTimeout(() => this.mount(), this.options.transitionDuration);
|
|
272
272
|
return;
|
|
273
273
|
}
|
|
274
274
|
throw "Option useOriginal state allowed only elements .template";
|
|
@@ -277,29 +277,29 @@ class v extends x {
|
|
|
277
277
|
}
|
|
278
278
|
if (!this.elPopup)
|
|
279
279
|
return;
|
|
280
|
-
for (this.options.useOriginal ? (this.elStartPosition = this.elPopup.closest(".top-popup-el-start-position"), this.elStartPosition || (this.elStartPosition = i.wrap(this.elPopup, "i"), this.elStartPosition.classList.add("top-popup-el-start-position", "hidden"))) : (this.elPopup = this.elPopup.cloneNode(!0), this.type === "selector" && !this.elPopup.matches(".template") && (this.elPopup.classList.remove("hidden"), this.elPopup.querySelector(":scope > .top-popup_content") || this.elPopup.classList.add("top-popup_content"), this.elPopup = i.wrap(this.elPopup, "div")), this.type === "html" && (this.elPopup.querySelector(":scope > .top-popup_content") || (this.elPopup.classList.add("top-popup_content"), this.elPopup = i.wrap(this.elPopup, "div"))), (this.type === "selector" && !this.elPopup.matches(".template") || this.type === "html" || this.type === "vue") && (i.querySelectorAllArray(this.elPopup, "[data-top-popup]").forEach((
|
|
281
|
-
|
|
282
|
-
}), i.querySelectorAllArray(this.elPopup, ".top-popup-wrapper").forEach((
|
|
280
|
+
for (this.options.useOriginal ? (this.elStartPosition = this.elPopup.closest(".top-popup-el-start-position"), this.elStartPosition || (this.elStartPosition = i.wrap(this.elPopup, "i"), this.elStartPosition.classList.add("top-popup-el-start-position", "hidden"))) : (this.elPopup = this.elPopup.cloneNode(!0), this.type === "selector" && !this.elPopup.matches(".template") && (this.elPopup.classList.remove("hidden"), this.elPopup.querySelector(":scope > .top-popup_content") || this.elPopup.classList.add("top-popup_content"), this.elPopup = i.wrap(this.elPopup, "div")), this.type === "html" && (this.elPopup.querySelector(":scope > .top-popup_content") || (this.elPopup.classList.add("top-popup_content"), this.elPopup = i.wrap(this.elPopup, "div"))), (this.type === "selector" && !this.elPopup.matches(".template") || this.type === "html" || this.type === "vue") && (i.querySelectorAllArray(this.elPopup, "[data-top-popup]").forEach((n) => {
|
|
281
|
+
n instanceof HTMLElement && (n.dataset.topPopupPosBy = "fixed");
|
|
282
|
+
}), i.querySelectorAllArray(this.elPopup, ".top-popup-wrapper").forEach((n) => n.remove()))), l.decoratorBeforeOpen(this), t && (this.options.class = t.classRef.value, t.transitionDurationRef.value !== void 0 && (this.options.transitionDuration = t.transitionDurationRef.value, this.elPopup instanceof HTMLElement && this.elPopup.style.setProperty(
|
|
283
283
|
"--top-popup-transition-delay",
|
|
284
284
|
this.options.transitionDuration + "ms"
|
|
285
285
|
))), this.elPopupInner = document.createElement("div"), this.elPopupInner.classList.add("top-popupPanel", "top-popup"); this.elPopup.firstChild; )
|
|
286
286
|
this.elPopupInner.appendChild(this.elPopup.firstChild);
|
|
287
287
|
if (this.elPopup.append(this.elPopupInner), this.elPopup.classList.add("top-popup-wrapper"), this.options.class) {
|
|
288
|
-
const
|
|
289
|
-
this.elPopup.classList.add(...
|
|
288
|
+
const n = this.options.class.split(" ");
|
|
289
|
+
this.elPopup.classList.add(...n);
|
|
290
290
|
}
|
|
291
291
|
this.options.notch && (this.elPopup.classList.add("with_notch"), this.elPopup.insertAdjacentHTML("beforeend", '<i class="notch notch-border"></i><i class="notch"></i>')), await this.vueOpen(), this.elPopupHeader = this.elPopupInner.querySelector(".top-popup_header"), this.elPopupWidget = this.elPopupInner.querySelector(".top-popup_widget"), this.elPopupBody = this.elPopupInner.querySelector(".top-popup_content"), this.elPopupFooter = this.elPopupInner.querySelector(".top-popup_footer");
|
|
292
292
|
const p = !!this.elPopup.querySelector('[data-widget="search"]');
|
|
293
293
|
if (this.options.isFullScreen && !p) {
|
|
294
|
-
const
|
|
295
|
-
!this.elPopupHeader &&
|
|
294
|
+
const n = k();
|
|
295
|
+
!this.elPopupHeader && n.Common.Close && (this.elPopupHeader = i.genEl("i", { class: "top-popup_header" }), this.elPopupInner.prepend(this.elPopupHeader), this.elPopupHeader.prepend(i.genEl("i", { class: "a closer" }, n.Common.Close)), this.elPopupHeader.append(i.genEl("i", { class: "top-popup_headerButton" })));
|
|
296
296
|
}
|
|
297
|
-
i.storage(this.elPopup,
|
|
297
|
+
i.storage(this.elPopup, x.componentName, this), this.options.frontSelector && (this.elFront = document.querySelector(this.options.frontSelector)), this.elFront || (this.elFront = this.el.closest(".top-popup-front")), this.elFront || (this.elFront = document.body), this.elPopup instanceof HTMLElement && (this.elPopup.style.width = this.el.offsetWidth + "px", this.elPopup.style.height = this.el.offsetHeight + "px", this.elPopup.style.top = this.el.offsetTop + "px", this.elPopup.style.right = parseInt(this.el.style.right || "0") + "px", this.elPopup.style.bottom = parseInt(this.el.style.bottom || "0") + "px"), (r = this.el.parentElement) == null || r.insertBefore(this.elPopup, this.el), this.elPopup.classList.remove("template"), this.options.invertX && this.elPopup.classList.add("invert-x");
|
|
298
298
|
let o = !!this.el.closest(".modal-header");
|
|
299
299
|
o || (o = !!this.el.closest("#top_panel")), o || (o = !!this.el.closest("#secondmenu")), o && this.elPopup.classList.add("p-from-top"), setTimeout(() => {
|
|
300
|
-
var
|
|
301
|
-
return (
|
|
302
|
-
}), this.elFront && !this.elFront.matches("body") && (this.elFront.append(this.elPopup), this.shift.top = i.offset(this.el).top - this.el.offsetTop - i.offset(this.elFront).top, this.shift.left = i.offset(this.el).left - this.el.offsetLeft - i.offset(this.elFront).left, this.shift.top -= parseInt(this.el.style["margin-top"] || 0), this.shift.left -= parseInt(this.el.style["margin-left"] || 0), this.elPopup instanceof HTMLElement && (this.elPopup.style.top = parseInt(this.elPopup.style.top || "0") + this.shift.top + "px", this.elPopup.style.left = parseInt(this.elPopup.style.left || "0") + this.shift.left + "px")), this.$ && f.$ && this.$.trigger("aftershow.top-menu-popup", [f.$(this.elPopup)]), this.recalcPosition(), this.elPopup.setAttribute("tabindex", "0"), this.focus(),
|
|
300
|
+
var n;
|
|
301
|
+
return (n = this.elPopup) == null ? void 0 : n.classList.add("top-popup-wrapper-shown");
|
|
302
|
+
}), this.elFront && !this.elFront.matches("body") && (this.elFront.append(this.elPopup), this.shift.top = i.offset(this.el).top - this.el.offsetTop - i.offset(this.elFront).top, this.shift.left = i.offset(this.el).left - this.el.offsetLeft - i.offset(this.elFront).left, this.shift.top -= parseInt(this.el.style["margin-top"] || 0), this.shift.left -= parseInt(this.el.style["margin-left"] || 0), this.elPopup instanceof HTMLElement && (this.elPopup.style.top = parseInt(this.elPopup.style.top || "0") + this.shift.top + "px", this.elPopup.style.left = parseInt(this.elPopup.style.left || "0") + this.shift.left + "px")), this.$ && f.$ && this.$.trigger("aftershow.top-menu-popup", [f.$(this.elPopup)]), this.recalcPosition(), this.elPopup.setAttribute("tabindex", "0"), this.focus(), l.decoratorAfterOpen(this), this.mountEvents();
|
|
303
303
|
}
|
|
304
304
|
async mountJQuery() {
|
|
305
305
|
f.$ && (this.$ = f.$(this.el));
|
|
@@ -323,7 +323,7 @@ class v extends x {
|
|
|
323
323
|
if (!this.elPopup || !(t.target instanceof Element) || !this.isFirstClick || (this.isFirstClick = !1, setTimeout(() => this.isFirstClick = !0), t instanceof MouseEvent && t.button !== 0))
|
|
324
324
|
return;
|
|
325
325
|
let p = i.querySelectorVisibleLast(document.body, ":scope > .top-popup-wrapper");
|
|
326
|
-
p && p !== this.elPopup || t.target.closest(".top-popup-front") && (p = i.querySelectorVisibleLast(t.target.closest(".top-popup-front"), ":scope > .top-popup-wrapper"), p && p !== this.elPopup) || this.elPopup.contains(t.target) || this.elPopup.closest(".ui-dialog") && !t.target.closest(".ui-dialog") ||
|
|
326
|
+
p && p !== this.elPopup || t.target.closest(".top-popup-front") && (p = i.querySelectorVisibleLast(t.target.closest(".top-popup-front"), ":scope > .top-popup-wrapper"), p && p !== this.elPopup) || this.elPopup.contains(t.target) || this.elPopup.closest(".ui-dialog") && !t.target.closest(".ui-dialog") || l.decoratorIsIgnoreOuterClick(t) || l.close(this.elPopup);
|
|
327
327
|
}
|
|
328
328
|
/**
|
|
329
329
|
* Закрыть другие Popup при фокусе на элемент формы в текущем
|
|
@@ -331,9 +331,9 @@ class v extends x {
|
|
|
331
331
|
onFocus(t) {
|
|
332
332
|
if (t.target instanceof Element && t.target.matches("input") || this.isClosed)
|
|
333
333
|
return;
|
|
334
|
-
|
|
335
|
-
var e,
|
|
336
|
-
(e = this.elPopup) != null && e.contains(o) || ((
|
|
334
|
+
l.getAllVisible().forEach((o) => {
|
|
335
|
+
var e, r, n, c;
|
|
336
|
+
(e = this.elPopup) != null && e.contains(o) || ((r = this.popupParent) == null ? void 0 : r.elPopup) === o || ((c = (n = this.popupParent) == null ? void 0 : n.popupParent) == null ? void 0 : c.elPopup) === o || l.close(o);
|
|
337
337
|
});
|
|
338
338
|
}
|
|
339
339
|
/**
|
|
@@ -341,7 +341,7 @@ class v extends x {
|
|
|
341
341
|
*/
|
|
342
342
|
onMouseleave(t) {
|
|
343
343
|
setTimeout(() => {
|
|
344
|
-
this.elPopupInner && this.elPopupInner.matches(":hover") || !this.elPopup ||
|
|
344
|
+
this.elPopupInner && this.elPopupInner.matches(":hover") || !this.elPopup || l.close(this.elPopup);
|
|
345
345
|
}, 100);
|
|
346
346
|
}
|
|
347
347
|
/**
|
|
@@ -357,7 +357,7 @@ class v extends x {
|
|
|
357
357
|
}
|
|
358
358
|
// контроль за положением Popup, чтобы оно не вылезало за пределы документа
|
|
359
359
|
recalcPosition(t) {
|
|
360
|
-
var
|
|
360
|
+
var y, _;
|
|
361
361
|
if (!(this.elPopup instanceof HTMLElement)) return;
|
|
362
362
|
let p = t ?? this.options.p, o;
|
|
363
363
|
if (this.el instanceof HTMLElement)
|
|
@@ -373,20 +373,46 @@ class v extends x {
|
|
|
373
373
|
this.addEventListenerWithUnmount(window, "resize", () => this.onResize()), this.onResize();
|
|
374
374
|
break;
|
|
375
375
|
default:
|
|
376
|
-
(
|
|
376
|
+
(y = this.options.posBy) == null || y.append(this.elPopup);
|
|
377
377
|
}
|
|
378
378
|
const e = this.elPopup.getBoundingClientRect();
|
|
379
379
|
this.elPopup.style.setProperty("--top-popup-height", this.elPopup.offsetHeight + "px"), this.elPopup.style.setProperty("--top-popup-right-bounding", e.right + "px"), this.elPopup.style.setProperty("--top-popup-bottom-bounding", e.bottom + "px"), this.elPopup.style.setProperty("--top-popup-top", e.top + "px"), this.elPopup.style.setProperty("--top-popup-left", e.left + "px"), this.elPopupInner instanceof HTMLElement && (this.elPopupInner.style.maxWidth = "unset", this.elPopupInner.style.maxHeight = "unset");
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
380
|
+
const r = {
|
|
381
|
+
top: !1,
|
|
382
|
+
right: !1,
|
|
383
|
+
bottom: !1,
|
|
384
|
+
left: !1
|
|
385
|
+
}, n = {
|
|
386
|
+
top: !1,
|
|
387
|
+
right: !1,
|
|
388
|
+
bottom: !1,
|
|
389
|
+
left: !1
|
|
390
|
+
};
|
|
391
|
+
let c = e.left > window.innerWidth / 2, h = e.top > window.innerHeight / 2;
|
|
392
|
+
p === 4 && (c = !c), p === 1 && (h = !h);
|
|
393
|
+
const u = (_ = this.elPopupInner) == null ? void 0 : _.getBoundingClientRect();
|
|
394
|
+
let m, d;
|
|
395
|
+
const a = i.cssNumber(this.elPopup, "--top-popup-offset"), g = this.el.offsetHeight, L = this.el.offsetWidth;
|
|
396
|
+
u && (m = window.innerWidth - u.right, d = window.innerHeight - u.bottom, u.top < a && (r.top = !0, u.top < a * 2 - u.height + g && (n.top = !0)), m < a && (r.right = !0, m < a * 2 - u.width + L && (n.right = !0)), d < a && (r.bottom = !0, d < a * 2 - u.height + g && (n.bottom = !0)), u.left < a && (r.left = !0, u.left < a * 2 - u.width + g && (n.left = !0)));
|
|
397
|
+
const E = (v, s) => {
|
|
398
|
+
if (v === "x") {
|
|
399
|
+
if (!r.right && !r.left || (s === 1 || s === 3) && !n.right && !n.left && c)
|
|
400
|
+
return s;
|
|
401
|
+
r.right && (s === 0 || s === 2) && c && (s = 4), r.left && (s === 0 || s === 4) && c && (s = 2);
|
|
402
|
+
}
|
|
403
|
+
if (v === "y") {
|
|
404
|
+
if (!r.top && !r.bottom || (s === 2 || s === 4) && !n.top && !n.bottom && h)
|
|
405
|
+
return s;
|
|
406
|
+
r.top && (s === 0 || s === 1) && h && (s = 3), r.bottom && h && (s = 1);
|
|
407
|
+
}
|
|
408
|
+
return s;
|
|
409
|
+
};
|
|
410
|
+
let w = ["x", "y"];
|
|
411
|
+
(p === 0 || p === 1 || p === 3) && (w = ["y", "x"]);
|
|
412
|
+
let b = p ?? 0;
|
|
413
|
+
w.forEach((v) => {
|
|
414
|
+
b = E(v, b);
|
|
415
|
+
}), p = b, r.bottom && (p === 2 || p === 4) && h && this.elPopup.classList.add("invert-y"), r.right && (p === 0 || p === 1 || p === 3) && this.elPopup.classList.add("invert-x"), this.elPopup.classList.remove("p0", "p1", "p2", "p3", "p4"), this.elPopup.classList.add("p" + p), this.elPopupInner instanceof HTMLElement && (this.elPopupInner.style.maxWidth = "", this.elPopupInner.style.maxHeight = ""), l.scrollToActive(this.elPopup);
|
|
390
416
|
}
|
|
391
417
|
onTouchmove(t) {
|
|
392
418
|
var p, o, e;
|
|
@@ -398,12 +424,12 @@ class v extends x {
|
|
|
398
424
|
}
|
|
399
425
|
close() {
|
|
400
426
|
var t;
|
|
401
|
-
this.isClosed || (this.isClosed = !0, this.$ && f.$ && this.elPopup && this.$.trigger("afterclose.top-menu-popup", [f.$(this.elPopup)]), !
|
|
402
|
-
var e,
|
|
427
|
+
this.isClosed || (this.isClosed = !0, this.$ && f.$ && this.elPopup && this.$.trigger("afterclose.top-menu-popup", [f.$(this.elPopup)]), !l.noClose && (this.unmount(), (t = this.elPopup) == null || t.classList.add("top-popup-wrapper-closed"), setTimeout(() => {
|
|
428
|
+
var e, r, n, c, h;
|
|
403
429
|
if (this.vueClose(), !this.elPopup) return;
|
|
404
|
-
this.options.useOriginal ? (this.elPopup.removeAttribute("style"), this.elPopup.classList.remove("top-popup-wrapper-shown", "top-popup-wrapper-closed"), this.elPopup.classList.add("template"), (e = this.elStartPosition) == null || e.append(this.elPopup), (
|
|
405
|
-
const p =
|
|
406
|
-
o ?
|
|
430
|
+
this.options.useOriginal ? (this.elPopup.removeAttribute("style"), this.elPopup.classList.remove("top-popup-wrapper-shown", "top-popup-wrapper-closed"), this.elPopup.classList.add("template"), (e = this.elStartPosition) == null || e.append(this.elPopup), (r = this.elPopup.querySelector("div.top-popup_content.top-column")) == null || r.classList.remove("top-column"), (n = this.elPopup.querySelector(".notch-border")) == null || n.remove(), (c = this.elPopup.querySelector(".notch")) == null || c.remove(), (h = this.elPopupInner) == null || h.replaceWith(...this.elPopupInner.childNodes), i.storageClear(this.elPopup)) : (i.storageClear(this.elPopup), this.elPopup.remove(), delete this.elPopup);
|
|
431
|
+
const p = l.getAllVisible(), o = p.length && p[p.length - 1];
|
|
432
|
+
o ? l.getPopup(o).focus() : document.documentElement.classList.remove("with_popup");
|
|
407
433
|
}, this.options.transitionDuration)));
|
|
408
434
|
}
|
|
409
435
|
async vueOpen() {
|
|
@@ -416,11 +442,11 @@ class v extends x {
|
|
|
416
442
|
}
|
|
417
443
|
// получить vueConnectors компонента Popup
|
|
418
444
|
vueGetComponent() {
|
|
419
|
-
if (this.el instanceof HTMLElement && this.options.id) return
|
|
445
|
+
if (this.el instanceof HTMLElement && this.options.id) return l.vueConnectors.get(this.options.id);
|
|
420
446
|
}
|
|
421
447
|
}
|
|
422
|
-
|
|
448
|
+
I.init();
|
|
423
449
|
export {
|
|
424
|
-
|
|
450
|
+
x as TopLibPopup
|
|
425
451
|
};
|
|
426
|
-
//# sourceMappingURL=popup-
|
|
452
|
+
//# sourceMappingURL=popup-BjsK_pMZ.es.js.map
|