@topvisor/ui 0.9.23 → 0.9.24-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.
Files changed (104) hide show
  1. package/.chunks/datepicker-CQs26CC6.amd.js +247 -0
  2. package/.chunks/datepicker-CQs26CC6.amd.js.map +1 -0
  3. package/.chunks/datepicker-HwhZ99xe.es.js +290 -0
  4. package/.chunks/datepicker-HwhZ99xe.es.js.map +1 -0
  5. package/.chunks/forms-BBbBD32l.amd.js +3 -0
  6. package/.chunks/forms-BBbBD32l.amd.js.map +1 -0
  7. package/.chunks/{forms-U97cW1zp.es.js → forms-CMU4ajdz.es.js} +39 -39
  8. package/.chunks/forms-CMU4ajdz.es.js.map +1 -0
  9. package/.chunks/{listItem.vue_vue_type_script_setup_true_lang-C_o5sC8m.es.js → listItem.vue_vue_type_script_setup_true_lang-BPa6m9N6.es.js} +2 -2
  10. package/.chunks/listItem.vue_vue_type_script_setup_true_lang-BPa6m9N6.es.js.map +1 -0
  11. package/.chunks/{listItem.vue_vue_type_script_setup_true_lang-C67aHWhi.amd.js → listItem.vue_vue_type_script_setup_true_lang-CXLZpO9U.amd.js} +2 -2
  12. package/.chunks/listItem.vue_vue_type_script_setup_true_lang-CXLZpO9U.amd.js.map +1 -0
  13. package/.chunks/popup-CAjyI5nT.es.js +796 -0
  14. package/.chunks/popup-CAjyI5nT.es.js.map +1 -0
  15. package/.chunks/popup-DgxCokgg.amd.js +389 -0
  16. package/.chunks/popup-DgxCokgg.amd.js.map +1 -0
  17. package/.chunks/store-Bl79G7T_.amd.js.map +1 -1
  18. package/.chunks/store-PoMCiuBr.es.js.map +1 -1
  19. package/.chunks/{widgetInput-DmpYL1aA.es.js → widgetInput-Dglsn0CF.es.js} +2 -2
  20. package/.chunks/widgetInput-Dglsn0CF.es.js.map +1 -0
  21. package/.chunks/{widgetInput-DgylW6NK.amd.js → widgetInput-Dm3FgvaC.amd.js} +2 -2
  22. package/.chunks/widgetInput-Dm3FgvaC.amd.js.map +1 -0
  23. package/README.md +86 -86
  24. package/assets/core.css +1 -1
  25. package/assets/dark.css +1 -1
  26. package/assets/forms.css +1 -1
  27. package/assets/formsExt.css +1 -1
  28. package/assets/light.css +1 -1
  29. package/assets/tabs.css +1 -1
  30. package/assets/tabsView.css +1 -1
  31. package/assets/widgetInput.css +1 -1
  32. package/core/core.amd.js +1 -1
  33. package/core/core.js +1 -1
  34. package/forms/forms.amd.js +1 -1
  35. package/forms/forms.js +1 -1
  36. package/forms/helpers.amd.js.map +1 -1
  37. package/forms/helpers.js.map +1 -1
  38. package/formsExt/formsExt.amd.js +1 -1
  39. package/formsExt/formsExt.amd.js.map +1 -1
  40. package/formsExt/formsExt.js +5 -4
  41. package/formsExt/formsExt.js.map +1 -1
  42. package/icomoon/Read Me.txt +7 -7
  43. package/icomoon/demo-files/demo.css +161 -161
  44. package/icomoon/demo-files/demo.js +30 -30
  45. package/icomoon/demo.html +3225 -3225
  46. package/icomoon/fonts/Topvisor-2.svg +252 -252
  47. package/icomoon/style.css +707 -707
  48. package/package.json +20 -20
  49. package/popup/popup.amd.js +1 -1
  50. package/popup/popup.js +2 -2
  51. package/popup/worker.amd.js +1 -1
  52. package/popup/worker.amd.js.map +1 -1
  53. package/popup/worker.js +27 -31
  54. package/popup/worker.js.map +1 -1
  55. package/require/css.amd.js +11 -11
  56. package/src/components/formsExt/selector2/selector2.stories.d.ts +16 -16
  57. package/src/components/formsExt/selector2/selector2.vue.d.ts +8 -8
  58. package/src/components/popup/lib/popup.d.ts +40 -46
  59. package/src/components/popup/lib/popup.globalEvents.d.ts +2 -4
  60. package/src/components/popup/lib/worker.d.ts +24 -33
  61. package/src/components/popup/lib/worker.globalEvents.d.ts +1 -2
  62. package/src/components/popup/popup/popup.stories.d.ts +6 -6
  63. package/src/core/utils/dom.d.ts +3 -3
  64. package/tabs/tabs.amd.js +1 -1
  65. package/tabs/tabs.js +1 -1
  66. package/tabsView/tabsView.amd.js +1 -1
  67. package/tabsView/tabsView.amd.js.map +1 -1
  68. package/tabsView/tabsView.js +2 -2
  69. package/tabsView/tabsView.js.map +1 -1
  70. package/utils/css.amd.js.map +1 -1
  71. package/utils/css.js.map +1 -1
  72. package/utils/date.amd.js +1 -1
  73. package/utils/date.js +1 -1
  74. package/utils/device.amd.js +1 -1
  75. package/utils/device.js +1 -1
  76. package/utils/dom.amd.js.map +1 -1
  77. package/utils/dom.js.map +1 -1
  78. package/utils/keyboard.amd.js.map +1 -1
  79. package/utils/keyboard.js.map +1 -1
  80. package/utils/route.amd.js.map +1 -1
  81. package/utils/route.js.map +1 -1
  82. package/utils/scroll.amd.js +1 -1
  83. package/utils/scroll.amd.js.map +1 -1
  84. package/utils/scroll.js +1 -1
  85. package/utils/scroll.js.map +1 -1
  86. package/utils/system.amd.js.map +1 -1
  87. package/utils/system.js.map +1 -1
  88. package/utils/window.amd.js +1 -1
  89. package/utils/window.js +1 -1
  90. package/.chunks/datepicker-B28_yC8V.es.js +0 -277
  91. package/.chunks/datepicker-B28_yC8V.es.js.map +0 -1
  92. package/.chunks/datepicker-CDoo2d0x.amd.js +0 -234
  93. package/.chunks/datepicker-CDoo2d0x.amd.js.map +0 -1
  94. package/.chunks/forms-DNRGCC9P.amd.js +0 -3
  95. package/.chunks/forms-DNRGCC9P.amd.js.map +0 -1
  96. package/.chunks/forms-U97cW1zp.es.js.map +0 -1
  97. package/.chunks/listItem.vue_vue_type_script_setup_true_lang-C67aHWhi.amd.js.map +0 -1
  98. package/.chunks/listItem.vue_vue_type_script_setup_true_lang-C_o5sC8m.es.js.map +0 -1
  99. package/.chunks/popup-C1hmF9NI.es.js +0 -765
  100. package/.chunks/popup-C1hmF9NI.es.js.map +0 -1
  101. package/.chunks/popup-Cg-GRa9u.amd.js +0 -386
  102. package/.chunks/popup-Cg-GRa9u.amd.js.map +0 -1
  103. package/.chunks/widgetInput-DgylW6NK.amd.js.map +0 -1
  104. package/.chunks/widgetInput-DmpYL1aA.es.js.map +0 -1
@@ -1,765 +0,0 @@
1
- import { C as h } from "./forms-U97cW1zp.es.js";
2
- import n from "../utils/dom.js";
3
- import { PopupWorker as i } from "../popup/worker.js";
4
- class g {
5
- static componentName = "Top";
6
- componentName;
7
- // имя класса компонента
8
- className;
9
- // имя css класса компонента
10
- uid;
11
- // уникальный id компонента
12
- el;
13
- // элемент, связанный с компонентом
14
- options = {};
15
- // параметры компонента
16
- unmountEls = [];
17
- unmountEvents = [];
18
- // переопредлять нельзя
19
- // если компонент инициирован, необходимо сразу его вернуть и выполнить reInit() вместо mount()
20
- // используется init вместо constructor, так как super constructor выполняется до Object.defineProperty() параметров класса
21
- init(t, p, o) {
22
- if (!p)
23
- throw t + ": el is undefined";
24
- const e = g.getComponent(p, t);
25
- if (e)
26
- return e.reInit(o), e;
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();
28
- }
29
- // получить инициированный компонент
30
- static getComponent(t, p) {
31
- return n.storage(t, "#" + p);
32
- }
33
- // устанвоить компонент
34
- _setComponent(t) {
35
- n.storage(t, "#" + this.componentName, this);
36
- }
37
- // функция подключения компонента
38
- mount() {
39
- throw "Please, add method mount() to component: " + this.componentName;
40
- }
41
- // функция отключения компонента
42
- unmount() {
43
- n.storage(this.el, "#" + this.componentName, null), this.unmountEls.forEach((t) => {
44
- t.remove();
45
- }), this.unmountEls = [], this.unmountEvents.forEach((t) => {
46
- t.el.removeEventListener(t.type, t.listener, t.options);
47
- }), this.unmountEvents = [];
48
- }
49
- // указание новые элементы, которые должны будут удалиться после unmount
50
- registerElForUnmount(t) {
51
- this.unmountEls.push(t);
52
- }
53
- // указание новые события, которые должны будут удалиться после unmount
54
- addEventListenerWithUnmount(t, p, o, e) {
55
- t.addEventListener(p, o, e), this.registerEventForUnmount(t, p, o, e);
56
- }
57
- // указание новые события, которые должны будут удалиться после unmount
58
- registerEventForUnmount(t, p, o, e) {
59
- const r = {
60
- el: t,
61
- type: p,
62
- listener: o,
63
- options: e
64
- };
65
- this.unmountEvents.push(r);
66
- }
67
- // функция перенастройки уже подключенного компонента
68
- reInit(t) {
69
- throw "Please, add method reInit() to component: " + this.componentName;
70
- }
71
- // удалить элементы из DOM, но не из памяти
72
- static detach(t) {
73
- var p;
74
- if (t.forEach)
75
- t.forEach((o) => {
76
- var e;
77
- return (e = o.parentElement) == null ? void 0 : e.removeChild(o);
78
- });
79
- else {
80
- const o = t;
81
- (p = o.parentElement) == null || p.removeChild(o);
82
- }
83
- }
84
- }
85
- class b {
86
- static init() {
87
- document.addEventListener("click", this.onclick), document.addEventListener("keydown", this.onkeydown);
88
- }
89
- /**
90
- * Глобальный обработчик кликов
91
- * обрабатывает клики внутри Popup
92
- * @param {Event} e
93
- */
94
- static onclick(t) {
95
- var o;
96
- const p = t.target.closest(".closer, a, .a, .top-button");
97
- if (p) {
98
- const e = t.target.closest(".top-popup-wrapper");
99
- if (!e || p.matches(".top-popup-noCloser"))
100
- return;
101
- if (p.getAttribute("href") === "." && t.preventDefault(), t.target.matches("[data-top-popup]")) {
102
- const r = t.target.closest("ul"), l = t.target.closest("a, .a");
103
- r && ((o = r.querySelector("a.top-active, .a.top-active")) == null || o.classList.remove("top-active")), l && l.classList.add("top-active");
104
- return;
105
- }
106
- i.close(e);
107
- }
108
- if (t.target.matches(".top-popup-wrapper")) {
109
- const e = t.target;
110
- i.close(e);
111
- }
112
- }
113
- /**
114
- * Глобальный обработчик нажатия кнопки на клавиатуре
115
- * @param {Event} e
116
- */
117
- static onkeydown(t) {
118
- var e;
119
- const p = t.target.closest(".top-popup-wrapper");
120
- if (!p)
121
- return;
122
- const o = p.querySelector("ul.top-popup_content");
123
- switch (t.key) {
124
- case "Escape":
125
- i.close(p);
126
- break;
127
- case "Enter":
128
- if (!o) {
129
- if (n.querySelectorVisible(p, ".preloader"))
130
- break;
131
- const c = n.querySelectorVisible(p, ".top-popup_footer .go, .top-popup_footer [data-action]");
132
- if (c) {
133
- c.click();
134
- break;
135
- }
136
- const f = n.querySelectorVisibleLast(p, ".top-popup_footer .top-button");
137
- f && f.click();
138
- break;
139
- }
140
- const r = n.querySelectorVisible(p, "li > a.top-active");
141
- r && (t.preventDefault(), location.href = r.getAttribute("href"));
142
- const l = p.querySelector("li > .top-active");
143
- l && l.click();
144
- break;
145
- case "ArrowUp":
146
- case "ArrowRight":
147
- case "ArrowDown":
148
- case "ArrowLeft":
149
- if (!o)
150
- break;
151
- t.key === "ArrowRight" || t.key === "ArrowLeft" ? n.querySelectorVisible(
152
- p,
153
- "ul.top-popup_content > li:not(.top-popup_liNoSelectable) > .top-active > .top-popup_listMore"
154
- ) && t.preventDefault() : t.preventDefault();
155
- const d = (e = p.querySelector("ul.top-popup_content > li:not(.top-popup_liNoSelectable) > .top-active")) == null ? void 0 : e.parentElement;
156
- if (t.key === "ArrowRight" && d) {
157
- const c = d.querySelector(".top-active > .top-popup_listMore");
158
- if (c)
159
- return c.click();
160
- }
161
- const a = n.querySelectorAllVisible(p, "ul.top-popup_content > li:not(.top-popup_liNoSelectable)"), u = a.length;
162
- if (!u)
163
- return;
164
- let s = a.indexOf(d);
165
- if (t.key === "ArrowUp" || t.key === "ArrowLeft" ? s-- : s++, t.key === "ArrowLeft" && s === -1)
166
- return t.target.matches("input") ? void 0 : i.close(p);
167
- if (t.key === "ArrowRight" && s === u)
168
- return;
169
- s < 0 && (s = u - 1), s > u - 1 && (s = 0), p.querySelectorAll("ul.top-popup_content > li > .top-active").forEach((c) => c.classList.remove("top-active")), a[s].querySelector(":scope > a, :scope > .a").classList.add("top-active"), i.scrollToActive(p);
170
- break;
171
- }
172
- }
173
- }
174
- const x = `:root {
175
- --top-popup-z-index: 200000;
176
- --top-popup-transition-delay: 100ms;
177
-
178
- --top-popup-background-color: var(--color-bg-3);
179
- --top-popup-background-color-hover: var(--color-theme-75);
180
- --top-popup-background-color-active: var(--color-theme-100);
181
-
182
- --top-popup-border-color: var(--color-line-2-opacity);
183
- --top-popup-title-background-color: var(--color-theme-50);
184
-
185
- /* суммарный отсуп от каря popup до элемента */
186
- --top-popup-content-padding: calc(var(--top-popup-list-padding) + var(--top-popup-listItem-padding));
187
-
188
- /* списки */
189
- --top-popup-list-padding: var(--top-padding-2);
190
-
191
- --top-popup-listItem-radius: var(--top-radius-2);
192
- --top-popup-listItem-padding: var(--top-padding-2);
193
- }
194
-
195
- .top-popup-front { position: relative; }
196
-
197
- .top-popup-wrapper {
198
- /* см. recalcPosition() */
199
- --top-popup-height: 0px;
200
- --top-popup-right-bounding: 0px;
201
- --top-popup-bottom-bounding: 0px;
202
- --top-popup-top: 0px;
203
- --top-popup-right: calc(100vw - var(--top-popup-right-bounding));
204
- --top-popup-bottom: calc(var(--100vh) - var(--top-popup-bottom-bounding));
205
- --top-popup-left: 0px;
206
-
207
- text-align: initial; white-space: normal; word-break: normal;
208
- position: absolute; z-index: 200000;
209
- }
210
- .top-popup-wrapper:not(.top-popup-wrapper-shown) { overflow: hidden; }
211
-
212
- /* top-popupPanel */
213
- .top-popupPanel {
214
- cursor: default;
215
- box-shadow: var(--top-shadow-b);
216
- border-radius: 8px;
217
- background: var(--top-popup-background-color);
218
- position: absolute; overflow: hidden;
219
- display: flex; flex-direction: column;
220
- }
221
-
222
- /* position */
223
- .top-popup-wrapper > * {
224
- opacity: 0;
225
- transition: opacity var(--top-popup-transition-delay) linear, transform var(--top-popup-transition-delay) linear;
226
- }
227
- .top-popup-wrapper.p0 > * { transform: translateY(-8px); }
228
- .top-popup-wrapper.p1 > * { transform: translateY(8px); }
229
- .top-popup-wrapper.p2 > * { transform: translateX(8px); }
230
- .top-popup-wrapper.p3 > * { transform: translateY(8px); }
231
- .top-popup-wrapper.p4 > * { transform: translateX(-8px); }
232
- .top-popup-wrapper-shown:not(.top-popup-wrapper-closed) > * {opacity: 1;transform: translate(0, 0) !important;}
233
-
234
- .top-popup-wrapper.p0 > .top-popup { top: calc(-16px); left: calc(0px - 8px); }
235
- .top-popup-wrapper.p1 > .top-popup { bottom: calc(100% + 8px); }
236
- .top-popup-wrapper.p2 > .top-popup { left: calc(100% + 8px); }
237
- .top-popup-wrapper.p3 > .top-popup { top: calc(100% + 8px); }
238
- .top-popup-wrapper.p4 > .top-popup { right: calc(100% + 8px); }
239
- .top-popup-wrapper.p2 > .top-popup,
240
- .top-popup-wrapper.p4 > .top-popup { margin-top: -10px; }
241
-
242
- .top-popup-wrapper.p1.with_notch > .top-popup { margin-bottom: 5px; }
243
- .top-popup-wrapper.p2.with_notch > .top-popup { margin-left: 5px; }
244
- .top-popup-wrapper.p3.with_notch > .top-popup { margin-top: 5px; }
245
- .top-popup-wrapper.p4.with_notch > .top-popup { margin-right: 5px; }
246
-
247
- .top-popup-wrapper.invert-x > .top-popup { right: 0; }
248
- .top-popup-wrapper.invert-y > .top-popup { bottom: 0; }
249
-
250
- /* notch */
251
- .top-popup-wrapper > .notch { border: 7.4px solid transparent; position: absolute; display: block; }
252
-
253
- .top-popup-wrapper.p1 > .notch { border-bottom: 0; border-top: 7.4px solid var(--content-background-color); margin: 0 0 7.4px -7.4px; bottom: 100%; left: 50% }
254
- .top-popup-wrapper.p2 > .notch { border-left: 0; border-right: 7.4px solid var(--content-background-color); margin: 0 0 -7.4px 7.4px; bottom: 50%; left: 100%; }
255
- .top-popup-wrapper.p3 > .notch { border-top: 0; border-bottom: 7.4px solid var(--content-background-color); margin: 7.4px 0 0 -7.4px; top: 100%; left: 50%; }
256
- .top-popup-wrapper.p4 > .notch { border-right: 0; border-left: 7.4px solid var(--content-background-color); margin: 0 7.4px -7.4px 0; bottom: 50%; right: 100%; }
257
-
258
- .top-popup-wrapper.p1 > .notch-border { border-top-color: rgba(0, 0, 0, 0.05); margin-bottom: 6px; }
259
- .top-popup-wrapper.p2 > .notch-border { border-right-color: rgba(0, 0, 0, 0.05); margin-left: 6px; }
260
- .top-popup-wrapper.p3 > .notch-border { border-bottom-color: rgba(0, 0, 0, 0.05); margin-top: 6px; }
261
- .top-popup-wrapper.p4 > .notch-border { border-left-color: rgba(0, 0, 0, 0.05); margin-right: 6px; }
262
-
263
- /* common */
264
- .top-popup_header,
265
- .top-popup_content,
266
- .top-popup_footer { font-size: 14px; }
267
- .top-popup_header,
268
- .top-popup_footer { display: flex; align-items: center; justify-content: space-between; }
269
-
270
- /* header */
271
- .top-popup_header {
272
- border-bottom: 1px solid var(--top-popup-border-color);
273
- padding: var(--top-padding-3);
274
- font-weight: 600;
275
- }
276
- .top-popup_header > * { font-weight: 400; }
277
- .top-popup_header > .a { cursor: pointer; color: var(--color-blue-450); }
278
- .top-popup_header > .a:hover { color: var(--color-blue-350); }
279
-
280
- .top-popup_headerButton { width: 60px; }
281
-
282
- /* widget */
283
- .top-popup_widget {
284
- padding: var(--top-padding-2) var(--top-padding-2) 0 var(--top-padding-2);
285
- }
286
-
287
- /* content */
288
- .top-popup_content {
289
- margin: 0;
290
- flex-grow: 1;
291
- overflow-y: auto;
292
- display: flex;
293
- flex-direction: column;
294
- gap: var(--top-gap-4);
295
-
296
- -webkit-overflow-scrolling: touch;
297
- }
298
-
299
- div.top-popup_content {
300
- padding: var(--top-popup-content-padding);
301
- }
302
- div.top-popup_content > * { flex-shrink: 0; }
303
- div.top-popup_content > .top-button { margin: 0; }
304
-
305
- div.top-popup_content .top-unwrap {
306
- --top-unwrap-x: var(--top-popup-content-padding);
307
- }
308
-
309
- ul.top-popup_content {
310
- padding: var(--top-popup-list-padding);
311
- gap: 2px;
312
- }
313
-
314
- ul.top-popup_content .top-unwrap {
315
- --top-unwrap-x: var(--top-popup-list-padding);
316
- }
317
-
318
- .top-popup_listItem {
319
- border-radius: var(--top-popup-listItem-radius);
320
- padding: var(--top-popup-listItem-padding);
321
- line-height: 1 !important;
322
- }
323
-
324
- ul.top-popup_content li { margin: 0; list-style: none; display: flex; position: relative }
325
- ul.top-popup_content li > * { flex-grow: 1; }
326
- ul.top-popup_content li > a:not(.top-button),
327
- ul.top-popup_content li > .a {
328
- cursor: pointer;
329
- box-sizing: border-box;
330
- border-radius: var(--top-popup-listItem-radius);
331
- background: var(--top-popup-background-color);
332
- padding: var(--top-popup-listItem-padding);
333
- color: var(--color-text) !important; font-size: 14px; font-weight: normal !important; text-decoration: none !important; font-style: normal;
334
- line-height: 1 !important;
335
- display: flex; flex: 1 1 100%; align-items: center;
336
- transition: background-color 0.1s ease-in-out;
337
- }
338
- .top-popup-wrapper-no_animate ul.top-popup_content li > a:not(.top-button),
339
- .top-popup-wrapper-no_animate ul.top-popup_content li > .a { transition: none; }
340
-
341
- ul.top-popup_content li > a:not(.top-button):hover,
342
- ul.top-popup_content li > .a:hover { background: var(--top-popup-background-color-hover); }
343
- ul.top-popup_content li > a:not(.top-button).top-active,
344
- ul.top-popup_content li > .a.top-active { background: var(--top-popup-background-color-active); }
345
-
346
- .top-popup_content + .top-popup_content { padding-top: 0; }
347
-
348
- /* listTitle */
349
- .top-popup_listItem-title {
350
- background: var(--top-popup-title-background-color);
351
- color: var(--color-text-2); font-size: 12px;
352
- }
353
-
354
- /* listDelimiter */
355
- .top-popup_listItem-delimiter {
356
- border-radius: 3px;
357
- background: var(--top-popup-border-color);
358
- height: 1px;
359
- padding: 0;
360
- margin: 4px;
361
- }
362
-
363
- /* listMore */
364
- .top-popup_listMore {
365
- font-size: 20px;
366
- margin: calc(0px - var(--top-popup-listItem-padding)) calc(0px - var(--top-popup-listItem-padding) / 2) calc(0px - var(--top-popup-listItem-padding)) 0;
367
- }
368
-
369
- .top-popup_listMore.top-button{ margin: 0; }
370
-
371
- ul.top-popup_content li > .a.top-popup_listMore {
372
- text-align: center;
373
- flex-basis: 10px;
374
- }
375
- ul.top-popup_content li > .a.top-popup_listMore:before { color: var(--color-gray-500); }
376
- ul.top-popup_content li > * > .top-popup_listMore {
377
- margin-left: auto;
378
- color: var(--color-gray-500);
379
- font-size: 14px;
380
- }
381
- ul.top-popup_content li > * > i.top-popup_listMore:hover,
382
- ul.top-popup_content li > * > i.top-popup_listMore.top-active { color: var(--color-blue-500); }
383
- ul.top-popup_content li > * > i.top-popup_listMore:before {
384
- transform: rotate(90deg);
385
- display: block;
386
- }
387
-
388
- ul.top-popup_content li a.close { background: none !important; }
389
-
390
- /* data-top-icon */
391
- .top-popup_content > [data-top-icon]:before {
392
- --top-icon-size: 20px;
393
- }
394
-
395
- ul.top-popup_content li > [data-top-icon]:not(.top-button):before {
396
- --top-icon-color: var(--color-text-3);
397
- --top-icon-size: 20px;
398
- --top-icon-width: 20px;
399
-
400
- height: 1rem; margin-right: 8px; transition: color 0.1s;
401
- }
402
- ul.top-popup_content li:hover > [data-top-icon]:not(.top-button):before,
403
- ul.top-popup_content li > [data-top-icon]:not(.top-button).top-active:before {
404
- --top-icon-color: var(--color-text-2);
405
- }
406
-
407
- /* footer */
408
- .top-popup_footer {
409
- padding: var(--top-popup-list-padding);
410
- border-top: 1px solid var(--top-popup-border-color);
411
- display: flex;
412
- gap: var(--top-gap-2);
413
- justify-content: flex-end;
414
- }
415
-
416
- /* Виджеты */
417
- .top-popup > [data-widget] { padding: 0 var(--top-popup-list-padding); }
418
- .top-popup > [data-widget] + hr { margin: 0 var(--top-popup-list-padding); }
419
-
420
- .top-popup .placeholder {
421
- border: 1px solid #E0D9D9 !important; border-right: none !important; border-left: none !important; background: #F9F9F9 !important; margin: -1px 0; z-index: 1;
422
- position: relative;
423
- }
424
-
425
- /* компоненты */
426
- .top-popup-wrapper.simple_list > .top-popup { min-width: 0; white-space: nowrap; }
427
-
428
- .top-popup_content .top-column { display: flex; flex-direction: column; gap: 4px; }
429
- html .top-popup .top-popup_content li > .top-button {
430
- margin: calc(var(--top-popup-listItem-padding) / 2) var(--top-popup-listItem-padding);
431
- }
432
-
433
- .top-popup li .check_all,
434
- .top-popup li .clear_all { cursor: pointer; color: var(--color-cyan); padding: 8px; display: inline-block; }
435
- .top-popup li .check_all:hover,
436
- .top-popup li .clear_all:hover { text-decoration: underline; }
437
- .top-popup li .clear_all { display: none; }
438
-
439
- /* table */
440
- .top-popup_content table { margin: -9px 0; }
441
- .top-popup_content table td,
442
- .top-popup_content table th { padding: 9px var(--top-popup-listItem-padding) 9px 0; vertical-align: top; }
443
- .top-popup_content table th { width: 40%; font-weight: 600; white-space: nowrap; }
444
-
445
- /* формы */
446
- ul.top-popup_content .a > [type="checkbox"],
447
- ul.top-popup_content .a > [type="radio"] { margin: -8px 0 -8px auto; }
448
-
449
- /* deprecated */
450
- ul.top-popup_content a > [class*=icon],
451
- ul.top-popup_content i.a > [class*=icon] {
452
- transition: 0.1s;
453
- }
454
-
455
- .top-popup .buttons { border-radius: 0 0 4px 4px; border-top: 1px solid #BDC3C7; background: #ECF0F1; padding: 10px 15px; margin: 10px -15px -10px -15px; white-space: nowrap; }
456
- .top-popup_footer [class*=btn]:not(.btn-transparent) { min-width: 100px; padding: 5px 14px; margin-left: 10px; }
457
- .top-popup_footer [class*=btn]:first-child { margin-left: 0; }
458
- .top-popup_footer .btn.full_width { margin: 0; flex-grow: 1; }`, w = `:root{
459
- --top-popup-list-padding: 0px;
460
-
461
- --top-popup-listItem-radius: 0px;
462
- --top-popup-listItem-padding: var(--top-padding-4);
463
- }
464
-
465
- html.with_popup{ background: #808080; }
466
-
467
- .top-popup-wrapper{
468
- --top-popup-footer-offset: 25px;
469
-
470
- width: auto !important; height: auto !important;
471
- position: fixed; top: 0 !important; right: 0 !important; left: 0 !important; overflow: hidden;
472
- transition: background 0.3s;
473
- }
474
-
475
- .top-popup-wrapper-shown:not(.top-popup-wrapper-closed){ background: rgba(0,0,0,0.5); backdrop-filter: blur(1px); }
476
- .top-popup-wrapper-shown:not(.top-popup-wrapper-closed) > .top-popup{ opacity: 1 !important; }
477
-
478
- .top-popup{
479
- 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;
480
- top: auto !important; right: 0 !important; bottom: var(--toolbar-height, 0px) !important; left: 0 !important;
481
- display: flex; flex-direction: column;
482
-
483
- /* невозможно опустить элемент вниз за экран на 100%, fix: opacity и translateY(80%) */
484
- transform: translateY(80%);
485
-
486
- transition: opacity 0.3s, transform 0.3s;
487
- }
488
-
489
-
490
- /* from top */
491
- .top-popup-wrapper.p-from-top{
492
- --top-popup-footer-offset: 0px;
493
-
494
- top: var(--header-height, 0px) !important;
495
- }
496
- .with_dialog .top-popup-wrapper.p-from-top{ top: 50px !important; }
497
- .top-popup-wrapper.p-from-top > .top-popup{
498
- border-radius: 0 0 8px 8px; max-height: calc(100% - 24px); top: 0 !important; bottom: auto !important;
499
- transform: translateY(calc(-100% - 24px));
500
- }
501
-
502
- /* widget */
503
- .top-popup_widget{ padding: var(--top-padding-2);}
504
- .top-popup_widget:not(.p-from-top){ order: 10; }
505
-
506
- /* content */
507
- ul.top-popup_content{
508
- gap: 0;
509
- }
510
- ul.top-popup_content li:not(:last-child){ border-bottom: 1px solid var(--top-popup-border-color); }
511
-
512
- .top-popup-wrapper.top-style_alt > .top-popup > ul > li{ border-bottom: none; }
513
-
514
- /* footer */
515
- .top-popup_footer{
516
- flex-direction: column-reverse;
517
- }
518
- .top-popup_footer > .top-button{
519
- --top-forms-base-height: var(--top-forms-base-height_l);
520
-
521
- width: 100%;
522
- }
523
-
524
- /* listTitle */
525
- ul.top-popup_content .top-popup_listItem-title{
526
- --top-popup-padding-v: 12px;
527
- }
528
-
529
- /* listDelimiter */
530
- ul.top-popup_content .top-popup_listItem-delimiter{ background: var(--color-line-1-opacity); height: 4px; margin: 0; }
531
- ul.top-popup_content li:first-child > .top-popup_listItem-delimiter{ border-top: 1px solid var(--top-popup-border-color); }`, P = `html:not(.with_dialog){ margin-right: 0 !important; }
532
-
533
- .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)); }
534
- .top-popup-wrapper.invert-x > .top-popup{ max-width: calc(100vw - var(--top-popup-right) - 16px); }
535
- .top-popup-wrapper.invert-y > .top-popup{ max-height: calc(100vh - var(--top-popup-bottom) - 16px); }
536
-
537
- /* position */
538
- .top-popup-wrapper.p1 > .top-popup{ max-height: calc(var(--top-popup-top) - var(--header-height, 0px) - 16px); }
539
- .top-popup-wrapper.p3 > .top-popup{ max-height: calc(var(--top-popup-bottom) - 16px); }
540
- .top-popup-wrapper.p2 > .top-popup{ max-width: calc(var(--top-popup-right) - 16px); }
541
- .top-popup-wrapper.p4 > .top-popup{ max-width: calc(var(--top-popup-left) - 16px); }
542
-
543
- /* notch */
544
- .top-popup-wrapper.p1.with_notch > .top-popup,
545
- .top-popup-wrapper.p3.with_notch > .top-popup{ margin-left: -16px !important; }
546
- .top-popup-wrapper.p1.with_notch > .notch,
547
- .top-popup-wrapper.p3.with_notch > .notch{ margin-left: -8px !important; }
548
-
549
- .top-popup-wrapper.p1.with_notch.invert-x,
550
- .top-popup-wrapper.p3.with_notch.invert-x{ margin-left: 3px !important; }
551
- .top-popup-wrapper.p1.with_notch.invert-x > .notch,
552
- .top-popup-wrapper.p3.with_notch.invert-x > .notch{ margin-left: -9px !important; }
553
-
554
- /* listMore */
555
- ul.top-popup_content li > * > i.top-popup_listMore{ visibility: hidden; transition: none; }
556
- ul.top-popup_content li:hover > * > i.top-popup_listMore,
557
- ul.top-popup_content li > *.top-active > i.top-popup_listMore,
558
- ul.top-popup_content li > * > i.top-popup_listMore.top-active{ visibility: visible; }`;
559
- h.appendStyle(x);
560
- h.appendStyle(w, "m");
561
- h.appendStyle(P, "pc");
562
- class v extends g {
563
- static componentName = "Popup";
564
- el;
565
- // элемент, вызвавший открытие Popup
566
- elActiveByDefault;
567
- // элемент уже имеет класс top-active перед открытием окна
568
- elPopup;
569
- elPopupInner;
570
- elPopupHeader;
571
- elPopupWidget;
572
- elPopupBody;
573
- elPopupFooter;
574
- elFront;
575
- popupParent;
576
- $;
577
- // только, если есть jQuery
578
- elStartPosition;
579
- // используется для useOriginal
580
- shift = {
581
- top: 0,
582
- left: 0
583
- };
584
- isClosed = !1;
585
- // флаг того, что меню закрыто
586
- isFirstClick = !0;
587
- type;
588
- // selector или html
589
- options = {
590
- popup: "",
591
- // selector, text
592
- p: 0,
593
- // положение меню (0 - над элементом, 1 - сверху, 2 - справа, 3 - снизу, 4 слева)
594
- notch: !1,
595
- // отображать ли клювик
596
- class: "",
597
- // класс, добавляемый меню
598
- posBy: "left",
599
- // способ привязки позиционирования меню (left/right - левый/правый край родителя, fixed - по окну)
600
- frontSelector: "",
601
- invertX: !1,
602
- // базовая ордината - правая граница элемента, а не левая
603
- openByHover: !1,
604
- // открывать при наведении
605
- useOriginal: !1,
606
- // использовать оригинальный шаблон, без клонирвоания (для сохранения состояния меню)
607
- transitionDuration: 100,
608
- // значение прописано в css
609
- isFullScreen: !1,
610
- /**
611
- * @type {}
612
- */
613
- i18n: {}
614
- };
615
- events = {};
616
- // el - элемент, открывающий меню
617
- constructor(t, p) {
618
- return super(), this.init(v.componentName, t, p);
619
- }
620
- async mount() {
621
- const t = this.vueGetComponent();
622
- if (this.popupParent = i.getPopup(this.el.closest(".top-popup-wrapper")), await this.mountJQuery(), n.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)
623
- this.type = "vue", this.options.popup = "", this.elPopup = n.genEl("div", {}, this.options.popup);
624
- else if (this.options.popup.match(/^[#.]/))
625
- this.type = "selector", this.elPopup = document.querySelector(`${this.options.popup}.template`);
626
- else {
627
- if (this.type = "html", this.options.useOriginal)
628
- throw "Option useOriginal not allowed for text templates";
629
- this.elPopup = n.genEl("div", {}, this.options.popup);
630
- }
631
- if (!this.elPopup || t != null && t.opened) {
632
- if (this.options.useOriginal || t != null && t.opened) {
633
- if (t != null && t.opened ? this.elPopup = t.popup.elPopup : this.elPopup = document.querySelector(`${this.options.popup}.top-popup-wrapper-shown`), this.elPopup) {
634
- this.el.dataset.topPopupOpened = "", this.elActiveByDefault || this.el.classList.remove("top-active"), i.close(this.elPopup), setTimeout(() => this.mount(), this.options.transitionDuration);
635
- return;
636
- }
637
- throw "Option useOriginal state allowed only elements .template";
638
- }
639
- this.elPopup = document.querySelector(`${this.options.popup}:not(.top-popup-wrapper)`);
640
- }
641
- if (!this.elPopup)
642
- return;
643
- for (this.options.useOriginal ? (this.elStartPosition = this.elPopup.closest(".top-popup-el-start-position"), this.elStartPosition || (this.elStartPosition = n.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 = n.wrap(this.elPopup, "div")), this.type === "html" && (this.elPopup.querySelector(":scope > .top-popup_content") || (this.elPopup.classList.add("top-popup_content"), this.elPopup = n.wrap(this.elPopup, "div"))), (this.type === "selector" && !this.elPopup.matches(".template") || this.type === "html" || this.type === "vue") && (n.querySelectorAllArray(this.elPopup, "[data-top-popup]").forEach((e) => e.dataset.topPopupPosBy = "fixed"), n.querySelectorAllArray(this.elPopup, ".top-popup-wrapper").forEach((e) => e.remove()))), i.decoratorBeforeOpen(this), t && (this.options.class = t.classRef.value, t.transitionDurationRef.value !== void 0 && (this.options.transitionDuration = t.transitionDurationRef.value, this.elPopup.style.setProperty("--top-popup-transition-delay", this.options.transitionDuration + "ms"))), this.elPopupInner = document.createElement("div"), this.elPopupInner.classList.add("top-popupPanel", "top-popup"); this.elPopup.firstChild; )
644
- this.elPopupInner.appendChild(this.elPopup.firstChild);
645
- if (this.elPopup.append(this.elPopupInner), this.elPopup.classList.add("top-popup-wrapper"), this.options.class) {
646
- const e = this.options.class.split(" ");
647
- this.elPopup.classList.add(...e);
648
- }
649
- 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");
650
- const p = !!this.elPopup.querySelector('[data-widget="search"]');
651
- this.options.isFullScreen && !p && (this.elPopupHeader || (this.elPopupHeader = n.genEl("i", { class: "top-popup_header" }), this.elPopupInner.prepend(this.elPopupHeader), this.elPopupHeader.prepend(n.genEl("i", { class: "a closer" }, this.options.i18n.Close)), this.elPopupHeader.append(n.genEl("i", { class: "top-popup_headerButton" })))), n.storage(this.elPopup, "Popup", 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.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", this.el.parentElement.insertBefore(this.elPopup, this.el), this.elPopup.classList.remove("template"), this.options.invertX && this.elPopup.classList.add("invert-x");
652
- let o = !!this.el.closest(".modal-header");
653
- o || (o = !!this.el.closest("#top_panel")), o || (o = !!this.el.closest("#secondmenu")), o && this.elPopup.classList.add("p-from-top"), setTimeout(() => this.elPopup.classList.add("top-popup-wrapper-shown")), this.elFront && !this.elFront.matches("body") && (this.elFront.append(this.elPopup), this.shift.top = n.offset(this.el).top - this.el.offsetTop - n.offset(this.elFront).top, this.shift.left = n.offset(this.el).left - this.el.offsetLeft - n.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.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.$ && this.$.trigger("aftershow.top-menu-popup", [h.$(this.elPopup)]), this.recalcPosition(), this.elPopup.setAttribute("tabindex", 0), this.focus(), i.decoratorAfterOpen(this), this.mountEvents();
654
- }
655
- async mountJQuery() {
656
- h.$ && (this.$ = h.$(this.el));
657
- }
658
- /**
659
- * Выполнить фокусировку на нужный элемент после открытия окна
660
- */
661
- focus() {
662
- let t = n.querySelectorVisible(this.elPopup, ".top-popup-autofocus");
663
- t || (t = n.querySelectorVisible(this.elPopup, ":read-write, select:not(:disabled)")), t || (t = n.querySelectorVisible(this.elPopup, ".top-popup_footer .top-button")), t || (t = this.elPopup), t.focus(), setTimeout(() => {
664
- t.focus();
665
- }, this.options.transitionDuration);
666
- }
667
- mountEvents() {
668
- this.addEventListenerWithUnmount(document, "mousedown", (t) => this.onMousedown(t)), this.addEventListenerWithUnmount(this.elPopup, "focus", (t) => this.onFocus(t)), this.options.openByHover && (this.addEventListenerWithUnmount(this.elPopup, "mouseleave", (t) => this.onMouseleave(t)), this.addEventListenerWithUnmount(this.elPopupInner, "mouseleave", (t) => this.onMouseleave(t))), this.options.isFullScreen && this.elPopupBody && this.addEventListenerWithUnmount(this.elPopupBody, "touchmove", (t) => this.onTouchmove(t));
669
- }
670
- /**
671
- * Обработка клика вне окна
672
- * @param {Event} e
673
- */
674
- onMousedown(t) {
675
- if (!this.elPopup || !this.isFirstClick || (this.isFirstClick = !1, setTimeout(() => this.isFirstClick = !0), t.button !== 0))
676
- return;
677
- let p = n.querySelectorVisibleLast(document.body, ":scope > .top-popup-wrapper");
678
- p && p !== this.elPopup || (p = n.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") || i.decoratorIsIgnoreOuterClick(t) || i.close(this.elPopup)));
679
- }
680
- /**
681
- * Закрыть другие Popup при фокусе на элемент формы в текущем
682
- * @param {Event} e
683
- */
684
- onFocus(t) {
685
- if (t.target.matches("input") || this.isClosed)
686
- return;
687
- i.getAllVisible().forEach((o) => {
688
- var e, r, l;
689
- this.elPopup.contains(o) || ((e = this.popupParent) == null ? void 0 : e.elPopup) === o || ((l = (r = this.popupParent) == null ? void 0 : r.popupParent) == null ? void 0 : l.elPopup) === o || i.close(o);
690
- });
691
- }
692
- /**
693
- * Закрыть Popup при отведении мыши
694
- * @param {Event} _e
695
- */
696
- onMouseleave(t) {
697
- setTimeout(() => {
698
- this.elPopupInner.matches(":hover") || i.close(this.elPopup);
699
- }, 100);
700
- }
701
- /**
702
- * Контроль положения Popup при fixed позиционировании
703
- */
704
- onResize() {
705
- this.elPopup.parentElement !== document.body && document.body.append(this.elPopup), this.elPopup.style.top = n.offset(this.el).top + "px", this.elPopup.style.left = n.offset(this.el).left + "px";
706
- }
707
- unmount() {
708
- super.unmount(), this.el.dataset.topPopupOpened = "", this.elActiveByDefault || this.el.classList.remove("top-active");
709
- let t = this.el.getAttribute("style");
710
- t && (t = t.replace(/position:[^;]*;?/g, ""), this.el.setAttribute("style", t));
711
- }
712
- // контроль за положением Popup, чтобы оно не вылезало за пределы документа
713
- recalcPosition() {
714
- if (!this.elPopup)
715
- return;
716
- let t = this.options.p, p;
717
- switch (this.elPopup.style.height = this.el.offsetHeight + "px", this.elPopup.classList.remove("p0", "p1", "p2", "p3", "p4"), this.elPopup.classList.add("p" + t), this.options.posBy) {
718
- case "left":
719
- p = this.el.offsetLeft + parseInt(this.el.style["margin-left"] || 0), p += this.shift.left, this.elPopup.style.left = p + "px";
720
- break;
721
- case "right":
722
- p = this.el.offsetLeft + parseInt(this.el.style["margin-left"] || 0), this.elPopup.style.right = this.el.offsetParent.offsetWidth - this.el.offsetWidth - p + "px";
723
- break;
724
- case "fixed":
725
- this.addEventListenerWithUnmount(window, "resize", () => this.onResize()), this.onResize();
726
- break;
727
- default:
728
- this.options.posBy.append(this.elPopup);
729
- }
730
- const o = this.elPopup.getBoundingClientRect();
731
- this.elPopup.style.setProperty("--top-popup-height", this.elPopup.offsetHeight + "px"), this.elPopup.style.setProperty("--top-popup-right-bounding", o.right + "px"), this.elPopup.style.setProperty("--top-popup-bottom-bounding", o.bottom + "px"), this.elPopup.style.setProperty("--top-popup-top", o.top + "px"), this.elPopup.style.setProperty("--top-popup-left", o.left + "px"), this.elPopupInner.style.maxWidth = "unset", this.elPopupInner.style.maxHeight = "unset";
732
- let e = !1, r = !1, l = !1, d = !1, a = o.left > window.innerWidth / 2, u = o.top > window.innerHeight / 2;
733
- t === 4 && (a = !a), t === 1 && (u = !u);
734
- const s = this.elPopupInner.getBoundingClientRect(), c = window.innerWidth - s.right, f = window.innerHeight - s.bottom, m = 8;
735
- s.top < m && (e = !0), c < m && (r = !0), f < m && (l = !0), s.left < m && (d = !0), e && (t === 0 || t === 1) && u && (t = 3), l && t === 3 && u && (t = 1), r && t === 2 && a && (t = 4), d && t === 4 && a && (t = 2), r && (t === 0 || t === 1 || t === 3) && this.elPopup.classList.add("invert-x"), l && (t === 2 || t === 4) && u && (t === 2 && !a && this.elPopup.classList.add("invert-y"), t === 4 && !a && this.elPopup.classList.add("invert-x"), this.elPopup.matches(".invert-y") || (t = 1)), this.elPopup.classList.remove("p0", "p1", "p2", "p3", "p4"), this.elPopup.classList.add("p" + t), this.elPopupInner.style.maxWidth = "", this.elPopupInner.style.maxHeight = "", i.scrollToActive(this.elPopup);
736
- }
737
- onTouchmove(t) {
738
- t.currentTarget.scrollWidth > t.currentTarget.offsetWidth || t.target.parentElement.scrollWidth > t.target.parentElement.offsetWidth || t.currentTarget.matches(".has_scroll") || t.preventDefault();
739
- }
740
- close() {
741
- this.isClosed || (this.isClosed = !0, this.$ && this.$.trigger("afterclose.top-menu-popup", [h.$(this.elPopup)]), !i.noClose && (this.unmount(), this.elPopup.classList.add("top-popup-wrapper-closed"), setTimeout(() => {
742
- var o, e, r;
743
- this.vueClose(), this.options.useOriginal ? (this.elPopup.removeAttribute("style"), this.elPopup.classList.remove("top-popup-wrapper-shown", "top-popup-wrapper-closed"), this.elPopup.classList.add("template"), this.elStartPosition.append(this.elPopup), (o = this.elPopup.querySelector("div.top-popup_content.top-column")) == null || o.classList.remove("top-column"), (e = this.elPopup.querySelector(".notch-border")) == null || e.remove(), (r = this.elPopup.querySelector(".notch")) == null || r.remove(), this.elPopupInner.replaceWith(...this.elPopupInner.childNodes), n.storageClear(this.elPopup)) : (n.storageClear(this.elPopup), this.elPopup.remove(), delete this.elPopup);
744
- const t = i.getAllVisible(), p = t.length && t[t.length - 1];
745
- p ? i.getPopup(p).focus() : document.documentElement.classList.remove("with_popup");
746
- }, this.options.transitionDuration)));
747
- }
748
- async vueOpen() {
749
- var t;
750
- await ((t = this.vueGetComponent()) == null ? void 0 : t.onOpen(this));
751
- }
752
- vueClose() {
753
- var t;
754
- (t = this.vueGetComponent()) == null || t.onClose(this);
755
- }
756
- // получить vueConnectors компонента Popup
757
- vueGetComponent() {
758
- return i.vueConnectors.get(this.el.dataset.topPopupId);
759
- }
760
- }
761
- b.init();
762
- export {
763
- v as default
764
- };
765
- //# sourceMappingURL=popup-C1hmF9NI.es.js.map