1 | (function webpackUniversalModuleDefinition(root, factory) {
|
2 | if(typeof exports === 'object' && typeof module === 'object')
|
3 | module.exports = factory(require("vue"), require("./icon"), require("./transition"), require("./_mixin/emitter"), require("./button"));
|
4 | else if(typeof define === 'function' && define.amd)
|
5 | define(["vue", "./icon", "./transition", "./_mixin/emitter", "./button"], factory);
|
6 | else {
|
7 | var a = typeof exports === 'object' ? factory(require("vue"), require("./icon"), require("./transition"), require("./_mixin/emitter"), require("./button")) : factory(root["Vue"], root["./icon"], root["./transition"], root["./_mixin/emitter"], root["./button"]);
|
8 | for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
|
9 | }
|
10 | })(window, function(__WEBPACK_EXTERNAL_MODULE__2__, __WEBPACK_EXTERNAL_MODULE__8__, __WEBPACK_EXTERNAL_MODULE__11__, __WEBPACK_EXTERNAL_MODULE__12__, __WEBPACK_EXTERNAL_MODULE__13__) {
|
11 | return (function(modules) {
|
12 |
|
13 | var installedModules = {};
|
14 |
|
15 |
|
16 | function __webpack_require__(moduleId) {
|
17 |
|
18 |
|
19 | if(installedModules[moduleId]) {
|
20 | return installedModules[moduleId].exports;
|
21 | }
|
22 |
|
23 | var module = installedModules[moduleId] = {
|
24 | i: moduleId,
|
25 | l: false,
|
26 | exports: {}
|
27 | };
|
28 |
|
29 |
|
30 | modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
|
31 |
|
32 |
|
33 | module.l = true;
|
34 |
|
35 |
|
36 | return module.exports;
|
37 | }
|
38 |
|
39 |
|
40 |
|
41 | __webpack_require__.m = modules;
|
42 |
|
43 |
|
44 | __webpack_require__.c = installedModules;
|
45 |
|
46 |
|
47 | __webpack_require__.d = function(exports, name, getter) {
|
48 | if(!__webpack_require__.o(exports, name)) {
|
49 | Object.defineProperty(exports, name, { enumerable: true, get: getter });
|
50 | }
|
51 | };
|
52 |
|
53 |
|
54 | __webpack_require__.r = function(exports) {
|
55 | if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
|
56 | Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
57 | }
|
58 | Object.defineProperty(exports, '__esModule', { value: true });
|
59 | };
|
60 |
|
61 |
|
62 |
|
63 |
|
64 |
|
65 |
|
66 | __webpack_require__.t = function(value, mode) {
|
67 | if(mode & 1) value = __webpack_require__(value);
|
68 | if(mode & 8) return value;
|
69 | if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
|
70 | var ns = Object.create(null);
|
71 | __webpack_require__.r(ns);
|
72 | Object.defineProperty(ns, 'default', { enumerable: true, value: value });
|
73 | if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
|
74 | return ns;
|
75 | };
|
76 |
|
77 |
|
78 | __webpack_require__.n = function(module) {
|
79 | var getter = module && module.__esModule ?
|
80 | function getDefault() { return module['default']; } :
|
81 | function getModuleExports() { return module; };
|
82 | __webpack_require__.d(getter, 'a', getter);
|
83 | return getter;
|
84 | };
|
85 |
|
86 |
|
87 | __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
88 |
|
89 |
|
90 | __webpack_require__.p = "/dist/";
|
91 |
|
92 |
|
93 |
|
94 | return __webpack_require__(__webpack_require__.s = 129);
|
95 | })
|
96 |
|
97 | ({
|
98 |
|
99 | 0:
|
100 | (function(module, __webpack_exports__, __webpack_require__) {
|
101 |
|
102 | "use strict";
|
103 | __webpack_require__.d(__webpack_exports__, "a", function() { return normalizeComponent; });
|
104 |
|
105 |
|
106 |
|
107 |
|
108 |
|
109 |
|
110 | function normalizeComponent (
|
111 | scriptExports,
|
112 | render,
|
113 | staticRenderFns,
|
114 | functionalTemplate,
|
115 | injectStyles,
|
116 | scopeId,
|
117 | moduleIdentifier, /* server only */
|
118 | shadowMode /* vue-cli only */
|
119 | ) {
|
120 |
|
121 | var options = typeof scriptExports === 'function'
|
122 | ? scriptExports.options
|
123 | : scriptExports
|
124 |
|
125 |
|
126 | if (render) {
|
127 | options.render = render
|
128 | options.staticRenderFns = staticRenderFns
|
129 | options._compiled = true
|
130 | }
|
131 |
|
132 |
|
133 | if (functionalTemplate) {
|
134 | options.functional = true
|
135 | }
|
136 |
|
137 |
|
138 | if (scopeId) {
|
139 | options._scopeId = 'data-v-' + scopeId
|
140 | }
|
141 |
|
142 | var hook
|
143 | if (moduleIdentifier) {
|
144 | hook = function (context) {
|
145 |
|
146 | context =
|
147 | context ||
|
148 | (this.$vnode && this.$vnode.ssrContext) ||
|
149 | (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext)
|
150 |
|
151 | if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {
|
152 | context = __VUE_SSR_CONTEXT__
|
153 | }
|
154 |
|
155 | if (injectStyles) {
|
156 | injectStyles.call(this, context)
|
157 | }
|
158 |
|
159 | if (context && context._registeredComponents) {
|
160 | context._registeredComponents.add(moduleIdentifier)
|
161 | }
|
162 | }
|
163 |
|
164 |
|
165 | options._ssrRegister = hook
|
166 | } else if (injectStyles) {
|
167 | hook = shadowMode
|
168 | ? function () {
|
169 | injectStyles.call(
|
170 | this,
|
171 | (options.functional ? this.parent : this).$root.$options.shadowRoot
|
172 | )
|
173 | }
|
174 | : injectStyles
|
175 | }
|
176 |
|
177 | if (hook) {
|
178 | if (options.functional) {
|
179 |
|
180 |
|
181 | options._injectStyles = hook
|
182 |
|
183 | var originalRender = options.render
|
184 | options.render = function renderWithStyleInjection (h, context) {
|
185 | hook.call(context)
|
186 | return originalRender(h, context)
|
187 | }
|
188 | } else {
|
189 |
|
190 | var existing = options.beforeCreate
|
191 | options.beforeCreate = existing
|
192 | ? [].concat(existing, hook)
|
193 | : [hook]
|
194 | }
|
195 | }
|
196 |
|
197 | return {
|
198 | exports: scriptExports,
|
199 | options: options
|
200 | }
|
201 | }
|
202 |
|
203 |
|
204 | }),
|
205 |
|
206 | 1:
|
207 | (function(module, __webpack_exports__, __webpack_require__) {
|
208 |
|
209 | "use strict";
|
210 | __webpack_require__.d(__webpack_exports__, "g", function() { return on; });
|
211 | __webpack_require__.d(__webpack_exports__, "f", function() { return off; });
|
212 |
|
213 | __webpack_require__.d(__webpack_exports__, "d", function() { return hasClass; });
|
214 | __webpack_require__.d(__webpack_exports__, "a", function() { return addClass; });
|
215 | __webpack_require__.d(__webpack_exports__, "h", function() { return removeClass; });
|
216 | __webpack_require__.d(__webpack_exports__, "c", function() { return getStyle; });
|
217 |
|
218 |
|
219 |
|
220 |
|
221 | __webpack_require__.d(__webpack_exports__, "e", function() { return merge; });
|
222 | __webpack_require__.d(__webpack_exports__, "b", function() { return getScrollBarWidth; });
|
223 | var babel_runtime_helpers_typeof__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9);
|
224 | var babel_runtime_helpers_typeof__WEBPACK_IMPORTED_MODULE_0___default = __webpack_require__.n(babel_runtime_helpers_typeof__WEBPACK_IMPORTED_MODULE_0__);
|
225 | var vue__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2);
|
226 | var vue__WEBPACK_IMPORTED_MODULE_1___default = __webpack_require__.n(vue__WEBPACK_IMPORTED_MODULE_1__);
|
227 |
|
228 |
|
229 |
|
230 |
|
231 | var isServer = vue__WEBPACK_IMPORTED_MODULE_1___default.a.prototype.$isServer;
|
232 | var SPECIAL_CHARS_REGEXP = /([\:\-\_]+(.))/g;
|
233 | var MOZ_HACK_REGEXP = /^moz([A-Z])/;
|
234 | var ieVersion = isServer ? 0 : Number(document.documentMode);
|
235 |
|
236 |
|
237 | var trim = function trim(string) {
|
238 | return (string || '').replace(/^[\s\uFEFF]+|[\s\uFEFF]+$/g, '');
|
239 | };
|
240 |
|
241 | var camelCase = function camelCase(name) {
|
242 | return name.replace(SPECIAL_CHARS_REGEXP, function (_, separator, letter, offset) {
|
243 | return offset ? letter.toUpperCase() : letter;
|
244 | }).replace(MOZ_HACK_REGEXP, 'Moz$1');
|
245 | };
|
246 |
|
247 |
|
248 | var on = function () {
|
249 | if (!isServer && document.addEventListener) {
|
250 | return function (element, event, handler) {
|
251 | if (element && event && handler) {
|
252 | element.addEventListener(event, handler, false);
|
253 | }
|
254 | };
|
255 | } else {
|
256 | return function (element, event, handler) {
|
257 | if (element && event && handler) {
|
258 | element.attachEvent('on' + event, handler);
|
259 | }
|
260 | };
|
261 | }
|
262 | }();
|
263 |
|
264 |
|
265 | var off = function () {
|
266 | if (!isServer && document.removeEventListener) {
|
267 | return function (element, event, handler) {
|
268 | if (element && event) {
|
269 | element.removeEventListener(event, handler, false);
|
270 | }
|
271 | };
|
272 | } else {
|
273 | return function (element, event, handler) {
|
274 | if (element && event) {
|
275 | element.detachEvent('on' + event, handler);
|
276 | }
|
277 | };
|
278 | }
|
279 | }();
|
280 |
|
281 |
|
282 | var once = function once(el, event, fn) {
|
283 | var listener = function listener() {
|
284 | if (fn) {
|
285 | fn.apply(this, arguments);
|
286 | }
|
287 | off(el, event, listener);
|
288 | };
|
289 | on(el, event, listener);
|
290 | };
|
291 |
|
292 |
|
293 | function hasClass(el, cls) {
|
294 | if (!el || !cls) return false;
|
295 | if (cls.indexOf(' ') !== -1) {
|
296 | throw new Error('className should not contain space.');
|
297 | }
|
298 | if (el.classList) {
|
299 | return el.classList.contains(cls);
|
300 | } else {
|
301 | return (' ' + el.className + ' ').indexOf(' ' + cls + ' ') > -1;
|
302 | }
|
303 | }
|
304 |
|
305 |
|
306 | function addClass(el, cls) {
|
307 | if (!el) return;
|
308 | var curClass = el.className;
|
309 | var classes = (cls || '').split(' ');
|
310 |
|
311 | for (var i = 0, j = classes.length; i < j; i++) {
|
312 | var clsName = classes[i];
|
313 | if (!clsName) continue;
|
314 |
|
315 | if (el.classList) {
|
316 | el.classList.add(clsName);
|
317 | } else if (!hasClass(el, clsName)) {
|
318 | curClass += ' ' + clsName;
|
319 | }
|
320 | }
|
321 | if (!el.classList) {
|
322 | el.setAttribute('class', curClass);
|
323 | }
|
324 | }
|
325 |
|
326 |
|
327 | function removeClass(el, cls) {
|
328 | if (!el || !cls) return;
|
329 | var classes = cls.split(' ');
|
330 | var curClass = ' ' + el.className + ' ';
|
331 |
|
332 | for (var i = 0, j = classes.length; i < j; i++) {
|
333 | var clsName = classes[i];
|
334 | if (!clsName) continue;
|
335 |
|
336 | if (el.classList) {
|
337 | el.classList.remove(clsName);
|
338 | } else if (hasClass(el, clsName)) {
|
339 | curClass = curClass.replace(' ' + clsName + ' ', ' ');
|
340 | }
|
341 | }
|
342 | if (!el.classList) {
|
343 | el.setAttribute('class', trim(curClass));
|
344 | }
|
345 | }
|
346 |
|
347 |
|
348 | var getStyle = ieVersion < 9 ? function (element, styleName) {
|
349 | if (isServer) return;
|
350 | if (!element || !styleName) return null;
|
351 | styleName = camelCase(styleName);
|
352 | if (styleName === 'float') {
|
353 | styleName = 'styleFloat';
|
354 | }
|
355 | try {
|
356 | switch (styleName) {
|
357 | case 'opacity':
|
358 | try {
|
359 | return element.filters.item('alpha').opacity / 100;
|
360 | } catch (e) {
|
361 | return 1.0;
|
362 | }
|
363 | default:
|
364 | return element.style[styleName] || element.currentStyle ? element.currentStyle[styleName] : null;
|
365 | }
|
366 | } catch (e) {
|
367 | return element.style[styleName];
|
368 | }
|
369 | } : function (element, styleName) {
|
370 | if (isServer) return;
|
371 | if (!element || !styleName) return null;
|
372 | styleName = camelCase(styleName);
|
373 | if (styleName === 'float') {
|
374 | styleName = 'cssFloat';
|
375 | }
|
376 | try {
|
377 | var computed = document.defaultView.getComputedStyle(element, '');
|
378 | return element.style[styleName] || computed ? computed[styleName] : null;
|
379 | } catch (e) {
|
380 | return element.style[styleName];
|
381 | }
|
382 | };
|
383 |
|
384 |
|
385 | function setStyle(element, styleName, value) {
|
386 | if (!element || !styleName) return;
|
387 |
|
388 | if ((typeof styleName === 'undefined' ? 'undefined' : babel_runtime_helpers_typeof__WEBPACK_IMPORTED_MODULE_0___default()(styleName)) === 'object') {
|
389 | for (var prop in styleName) {
|
390 | if (styleName.hasOwnProperty(prop)) {
|
391 | setStyle(element, prop, styleName[prop]);
|
392 | }
|
393 | }
|
394 | } else {
|
395 | styleName = camelCase(styleName);
|
396 | if (styleName === 'opacity' && ieVersion < 9) {
|
397 | element.style.filter = isNaN(value) ? '' : 'alpha(opacity=' + value * 100 + ')';
|
398 | } else {
|
399 | element.style[styleName] = value;
|
400 | }
|
401 | }
|
402 | }
|
403 |
|
404 | var isScroll = function isScroll(el, vertical) {
|
405 | if (isServer) return;
|
406 |
|
407 | var determinedDirection = vertical !== null && vertical !== undefined;
|
408 | var overflow = determinedDirection ? vertical ? getStyle(el, 'overflow-y') : getStyle(el, 'overflow-x') : getStyle(el, 'overflow');
|
409 |
|
410 | return overflow.match(/(scroll|auto|overlay)/);
|
411 | };
|
412 |
|
413 | var getScrollContainer = function getScrollContainer(el, vertical) {
|
414 | if (isServer) return;
|
415 |
|
416 | var parent = el;
|
417 | while (parent) {
|
418 | if ([window, document, document.documentElement].includes(parent)) {
|
419 | return window;
|
420 | }
|
421 | if (isScroll(parent, vertical)) {
|
422 | return parent;
|
423 | }
|
424 | parent = parent.parentNode;
|
425 | }
|
426 |
|
427 | return parent;
|
428 | };
|
429 |
|
430 | var isInContainer = function isInContainer(el, container) {
|
431 | if (isServer || !el || !container) return false;
|
432 |
|
433 | var elRect = el.getBoundingClientRect();
|
434 | var containerRect = void 0;
|
435 |
|
436 | if ([window, document, document.documentElement, null, undefined].includes(container)) {
|
437 | containerRect = {
|
438 | top: 0,
|
439 | right: window.innerWidth,
|
440 | bottom: window.innerHeight,
|
441 | left: 0
|
442 | };
|
443 | } else {
|
444 | containerRect = container.getBoundingClientRect();
|
445 | }
|
446 |
|
447 | return elRect.top < containerRect.bottom && elRect.bottom > containerRect.top && elRect.right > containerRect.left && elRect.left < containerRect.right;
|
448 | };
|
449 |
|
450 | function merge(target) {
|
451 | for (var i = 1, j = arguments.length; i < j; i++) {
|
452 | var source = arguments[i] || {};
|
453 | for (var prop in source) {
|
454 | if (source.hasOwnProperty(prop)) {
|
455 | var value = source[prop];
|
456 | if (value !== undefined) {
|
457 | target[prop] = value;
|
458 | }
|
459 | }
|
460 | }
|
461 | }
|
462 |
|
463 | return target;
|
464 | }
|
465 |
|
466 | var scrollBarWidth = void 0;
|
467 | function getScrollBarWidth() {
|
468 | if (vue__WEBPACK_IMPORTED_MODULE_1___default.a.prototype.$isServer) return 0;
|
469 | if (scrollBarWidth !== undefined) return scrollBarWidth;
|
470 |
|
471 | var outer = document.createElement('div');
|
472 | outer.className = 'el-scrollbar__wrap';
|
473 | outer.style.visibility = 'hidden';
|
474 | outer.style.width = '100px';
|
475 | outer.style.position = 'absolute';
|
476 | outer.style.top = '-9999px';
|
477 | document.body.appendChild(outer);
|
478 |
|
479 | var widthNoScroll = outer.offsetWidth;
|
480 | outer.style.overflow = 'scroll';
|
481 |
|
482 | var inner = document.createElement('div');
|
483 | inner.style.width = '100%';
|
484 | outer.appendChild(inner);
|
485 |
|
486 | var widthWithScroll = inner.offsetWidth;
|
487 | outer.parentNode.removeChild(outer);
|
488 | scrollBarWidth = widthNoScroll - widthWithScroll;
|
489 |
|
490 | return scrollBarWidth;
|
491 | }
|
492 |
|
493 | }),
|
494 |
|
495 | 11:
|
496 | (function(module, exports) {
|
497 |
|
498 | module.exports = __WEBPACK_EXTERNAL_MODULE__11__;
|
499 |
|
500 | }),
|
501 |
|
502 | 12:
|
503 | (function(module, exports) {
|
504 |
|
505 | module.exports = __WEBPACK_EXTERNAL_MODULE__12__;
|
506 |
|
507 | }),
|
508 |
|
509 | 129:
|
510 | (function(module, __webpack_exports__, __webpack_require__) {
|
511 |
|
512 | "use strict";
|
513 |
|
514 | __webpack_require__.r(__webpack_exports__);
|
515 |
|
516 |
|
517 | var style = __webpack_require__(139);
|
518 |
|
519 |
|
520 | var drawer_style = __webpack_require__(250);
|
521 |
|
522 |
|
523 | var loaders = __webpack_require__(252);
|
524 |
|
525 |
|
526 |
|
527 |
|
528 |
|
529 |
|
530 | var render = function () {
|
531 | var _vm = this
|
532 | var _h = _vm.$createElement
|
533 | var _c = _vm._self._c || _h
|
534 | return _c(
|
535 | "div",
|
536 | {
|
537 | directives: [
|
538 | {
|
539 | name: "show",
|
540 | rawName: "v-show",
|
541 | value: _vm.visibility,
|
542 | expression: "visibility",
|
543 | },
|
544 | ],
|
545 | ref: "root",
|
546 | class: _vm.contentClasses,
|
547 | },
|
548 | [
|
549 | _c("div", {
|
550 | directives: [
|
551 | {
|
552 | name: "show",
|
553 | rawName: "v-show",
|
554 | value: _vm.mask,
|
555 | expression: "mask",
|
556 | },
|
557 | ],
|
558 | class: _vm.prefixClsMask,
|
559 | on: {
|
560 | click: function (e) {
|
561 | return _vm.onMaskClick(e)
|
562 | },
|
563 | },
|
564 | }),
|
565 | _c(
|
566 | "div",
|
567 | {
|
568 | class: _vm.prefixClsWrap,
|
569 | attrs: { role: "document" },
|
570 | on: {
|
571 | click: function (e) {
|
572 | return _vm.onMaskClick(e)
|
573 | },
|
574 | },
|
575 | },
|
576 | [
|
577 | _c(
|
578 | "div",
|
579 | {
|
580 | class: [_vm.prefixCls, _vm.prefixCls + "-" + _vm.position],
|
581 | style: _vm.isHorizontal
|
582 | ? "width: " + _vm.size
|
583 | : "height: " + _vm.size,
|
584 | },
|
585 | [
|
586 | _vm.loading
|
587 | ? _c(
|
588 | "div",
|
589 | {
|
590 | class: _vm.prefixCls + "-loading",
|
591 | on: {
|
592 | click: function ($event) {
|
593 | $event.stopPropagation()
|
594 | },
|
595 | },
|
596 | },
|
597 | [_c("div", { staticClass: "ball-spin-fade-loader" })]
|
598 | )
|
599 | : _vm._e(),
|
600 | _c(
|
601 | "div",
|
602 | { class: _vm.prefixClsHeader },
|
603 | [
|
604 | _c(
|
605 | "div",
|
606 | { class: _vm.prefixClsTitle },
|
607 | [_vm._t("title", [_vm._v(_vm._s(_vm.title))])],
|
608 | 2
|
609 | ),
|
610 | _c("mds-icon", {
|
611 | directives: [
|
612 | {
|
613 | name: "show",
|
614 | rawName: "v-show",
|
615 | value: _vm.showClose,
|
616 | expression: "showClose",
|
617 | },
|
618 | ],
|
619 | class: _vm.prefixClsClose,
|
620 | attrs: { type: "line-close" },
|
621 | nativeOn: {
|
622 | click: function ($event) {
|
623 | return _vm.handleClose($event)
|
624 | },
|
625 | },
|
626 | }),
|
627 | ],
|
628 | 1
|
629 | ),
|
630 | _c("div", { class: _vm.prefixClsBody }, [_vm._t("default")], 2),
|
631 | _vm.$slots.footer
|
632 | ? _c(
|
633 | "div",
|
634 | { staticClass: "mds-drawer-footer" },
|
635 | [_vm._t("footer")],
|
636 | 2
|
637 | )
|
638 | : _vm._e(),
|
639 | ]
|
640 | ),
|
641 | ]
|
642 | ),
|
643 | ]
|
644 | )
|
645 | }
|
646 | var staticRenderFns = []
|
647 | render._withStripped = true
|
648 |
|
649 |
|
650 |
|
651 |
|
652 |
|
653 | var external_icon_ = __webpack_require__(8);
|
654 | var external_icon_default = __webpack_require__.n(external_icon_);
|
655 |
|
656 |
|
657 | var external_button_ = __webpack_require__(13);
|
658 | var external_button_default = __webpack_require__.n(external_button_);
|
659 |
|
660 |
|
661 | var external_transition_ = __webpack_require__(11);
|
662 | var external_transition_default = __webpack_require__.n(external_transition_);
|
663 |
|
664 |
|
665 | var popup_main = __webpack_require__(14);
|
666 |
|
667 |
|
668 | var emitter_ = __webpack_require__(12);
|
669 | var emitter_default = __webpack_require__.n(emitter_);
|
670 |
|
671 |
|
672 |
|
673 |
|
674 |
|
675 |
|
676 |
|
677 |
|
678 |
|
679 |
|
680 |
|
681 |
|
682 |
|
683 |
|
684 |
|
685 |
|
686 |
|
687 |
|
688 |
|
689 |
|
690 |
|
691 |
|
692 |
|
693 |
|
694 |
|
695 |
|
696 |
|
697 |
|
698 |
|
699 |
|
700 |
|
701 |
|
702 |
|
703 |
|
704 |
|
705 |
|
706 |
|
707 |
|
708 |
|
709 |
|
710 |
|
711 |
|
712 | var PREFIXCLS = 'mds-drawer';
|
713 | var drawervue_type_script_lang_js_ = ({
|
714 | name: 'MdsDrawer',
|
715 | mixins: [popup_main["b" ], emitter_default.a],
|
716 | components: {
|
717 | MdsIcon: external_icon_default.a,
|
718 | MdsButton: external_button_default.a,
|
719 | MdsTransition: external_transition_default.a
|
720 | },
|
721 | props: {
|
722 | visibility: {
|
723 | type: Boolean,
|
724 | default: false
|
725 | },
|
726 | mask: {
|
727 | type: Boolean,
|
728 | default: true
|
729 | },
|
730 | maskClosable: {
|
731 | type: Boolean,
|
732 | default: false
|
733 | },
|
734 | size: {
|
735 | type: String,
|
736 | default: '30%'
|
737 | },
|
738 | position: {
|
739 | type: String,
|
740 | default: 'right',
|
741 | validator: function validator(val) {
|
742 | return ['top', 'right', 'bottom', 'left'].indexOf(val) !== -1;
|
743 | }
|
744 | },
|
745 | showClose: {
|
746 | type: Boolean,
|
747 | default: true
|
748 | },
|
749 | title: {
|
750 | type: String
|
751 | },
|
752 | appendToBody: {
|
753 | type: Boolean,
|
754 | default: false
|
755 | },
|
756 | beforeClose: {
|
757 | type: Function
|
758 | },
|
759 | loading: {
|
760 | type: Boolean,
|
761 | default: function _default() {
|
762 | return false;
|
763 | }
|
764 | },
|
765 | customClass: String,
|
766 | preFocus: {
|
767 | type: Boolean,
|
768 | default: true
|
769 | }
|
770 | },
|
771 | data: function data() {
|
772 | return {
|
773 | prefixCls: PREFIXCLS,
|
774 | prefixClsContainer: PREFIXCLS + '-container',
|
775 | prefixClsMask: PREFIXCLS + '-mask',
|
776 | prefixClsWrap: PREFIXCLS + '-wrap',
|
777 | prefixClsContent: PREFIXCLS + '-content',
|
778 | prefixClsClose: PREFIXCLS + '-close',
|
779 | prefixClsHeader: PREFIXCLS + '-header',
|
780 | prefixClsIcon: PREFIXCLS + '-icon',
|
781 | prefixClsTitle: PREFIXCLS + '-title',
|
782 | prefixClsBody: PREFIXCLS + '-body'
|
783 | };
|
784 | },
|
785 |
|
786 | watch: {
|
787 | loading: {
|
788 | handler: function handler() {
|
789 | this.$nextTick(function () {
|
790 | window.loadersFn && window.loadersFn('ball-spin-fade-loader');
|
791 | });
|
792 | },
|
793 |
|
794 | immediate: true
|
795 | },
|
796 | visibility: function visibility(val) {
|
797 | var _this = this;
|
798 |
|
799 | if (val) {
|
800 | this.closed = false;
|
801 | this.$emit('open');
|
802 | if (this.appendToBody) {
|
803 | document.body.appendChild(this.$el);
|
804 | }
|
805 | this.open();
|
806 | this.stop();
|
807 | if (this.preFocus) {
|
808 | this.prevActiveElement = document.activeElement;
|
809 | }
|
810 | } else {
|
811 | if (!this.closed) this.$emit('close');
|
812 | this.move();
|
813 | if (this.prevActiveElement) {
|
814 | this.$nextTick(function () {
|
815 | _this.prevActiveElement.focus();
|
816 | });
|
817 | }
|
818 | }
|
819 | }
|
820 | },
|
821 | computed: {
|
822 | contentClasses: function contentClasses() {
|
823 | return [this.prefixClsContainer].concat(this.customClass);
|
824 | },
|
825 | isHorizontal: function isHorizontal() {
|
826 | return this.position === 'right' || this.position === 'left';
|
827 | }
|
828 | },
|
829 | methods: {
|
830 | hide: function hide(cancel) {
|
831 | if (cancel !== false) {
|
832 | this.$emit('update:visibility', false);
|
833 | this.$emit('close');
|
834 | this.closed = true;
|
835 | }
|
836 | },
|
837 | handleClose: function handleClose() {
|
838 | if (typeof this.beforeClose === 'function') {
|
839 | this.beforeClose(this.hide);
|
840 | } else {
|
841 | this.hide();
|
842 | }
|
843 | },
|
844 | onMaskClick: function onMaskClick(e) {
|
845 | if (e.target === e.currentTarget && this.maskClosable) {
|
846 | this.handleClose();
|
847 | }
|
848 | },
|
849 |
|
850 |
|
851 | stop: function stop() {
|
852 | var mo = function mo(e) {
|
853 | e.preventDefault();
|
854 | };
|
855 | document.body.style.overflow = 'hidden';
|
856 | document.addEventListener('scroll', mo, false);
|
857 | },
|
858 |
|
859 |
|
860 | move: function move() {
|
861 | var mo = function mo(e) {
|
862 | e.preventDefault();
|
863 | };
|
864 | document.body.style.overflow = '';
|
865 | document.removeEventListener('scroll', mo, false);
|
866 | }
|
867 | },
|
868 | beforeDestroy: function beforeDestroy() {
|
869 | if (this.appendToBody && this.$el && this.$el.parentNode) {
|
870 | this.$el.parentNode.removeChild(this.$el);
|
871 | }
|
872 | },
|
873 | mounted: function mounted() {
|
874 | if (this.visibility) {
|
875 | if (this.appendToBody) {
|
876 | document.body.appendChild(this.$el);
|
877 | }
|
878 | this.open();
|
879 | }
|
880 | }
|
881 | });
|
882 |
|
883 | var drawer_drawervue_type_script_lang_js_ = (drawervue_type_script_lang_js_);
|
884 |
|
885 | var componentNormalizer = __webpack_require__(0);
|
886 |
|
887 |
|
888 |
|
889 |
|
890 |
|
891 |
|
892 |
|
893 |
|
894 |
|
895 | var component = Object(componentNormalizer["a" ])(
|
896 | drawer_drawervue_type_script_lang_js_,
|
897 | render,
|
898 | staticRenderFns,
|
899 | false,
|
900 | null,
|
901 | null,
|
902 | null
|
903 |
|
904 | )
|
905 |
|
906 |
|
907 | if (false) { var api; }
|
908 | component.options.__file = "components/drawer/drawer.vue"
|
909 | var drawer = (component.exports);
|
910 |
|
911 |
|
912 |
|
913 |
|
914 | drawer.install = function (Vue) {
|
915 | Vue.component(drawer.name, drawer);
|
916 | };
|
917 | var components_drawer = __webpack_exports__["default"] = (drawer);
|
918 |
|
919 | }),
|
920 |
|
921 | 13:
|
922 | (function(module, exports) {
|
923 |
|
924 | module.exports = __WEBPACK_EXTERNAL_MODULE__13__;
|
925 |
|
926 | }),
|
927 |
|
928 | 139:
|
929 | (function(module, exports) {
|
930 |
|
931 |
|
932 |
|
933 | }),
|
934 |
|
935 | 14:
|
936 | (function(module, __webpack_exports__, __webpack_require__) {
|
937 |
|
938 | "use strict";
|
939 | var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2);
|
940 | var vue__WEBPACK_IMPORTED_MODULE_0___default = __webpack_require__.n(vue__WEBPACK_IMPORTED_MODULE_0__);
|
941 | var _dom_helper__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);
|
942 | var _popup_manager__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5);
|
943 | __webpack_require__.d(__webpack_exports__, "a", function() { return _popup_manager__WEBPACK_IMPORTED_MODULE_2__["a"]; });
|
944 |
|
945 |
|
946 |
|
947 |
|
948 |
|
949 | var idSeed = 1;
|
950 |
|
951 | var scrollBarWidth = void 0;
|
952 |
|
953 | __webpack_exports__["b"] = ({
|
954 | props: {
|
955 | visibility: {
|
956 | type: Boolean,
|
957 | default: false
|
958 | },
|
959 | openDelay: {},
|
960 | closeDelay: {},
|
961 | zIndex: {},
|
962 | modal: {
|
963 | type: Boolean,
|
964 | default: false
|
965 | },
|
966 | modalFade: {
|
967 | type: Boolean,
|
968 | default: true
|
969 | },
|
970 | modalClass: {},
|
971 | modalAppendToBody: {
|
972 | type: Boolean,
|
973 | default: false
|
974 | },
|
975 | lockScroll: {
|
976 | type: Boolean,
|
977 | default: true
|
978 | },
|
979 | closeOnPressEscape: {
|
980 | type: Boolean,
|
981 | default: false
|
982 | },
|
983 | closeOnClickModal: {
|
984 | type: Boolean,
|
985 | default: false
|
986 | }
|
987 | },
|
988 |
|
989 | beforeMount: function beforeMount() {
|
990 | this._popupId = 'popup-' + idSeed++;
|
991 | _popup_manager__WEBPACK_IMPORTED_MODULE_2__[ "a"].register(this._popupId, this);
|
992 | },
|
993 | beforeDestroy: function beforeDestroy() {
|
994 | _popup_manager__WEBPACK_IMPORTED_MODULE_2__[ "a"].deregister(this._popupId);
|
995 | _popup_manager__WEBPACK_IMPORTED_MODULE_2__[ "a"].closeModal(this._popupId);
|
996 |
|
997 | this.restoreBodyStyle();
|
998 | },
|
999 | data: function data() {
|
1000 | return {
|
1001 | opened: false,
|
1002 | bodyPaddingRight: null,
|
1003 | computedBodyPaddingRight: 0,
|
1004 | withoutHiddenClass: true,
|
1005 | rendered: false
|
1006 | };
|
1007 | },
|
1008 |
|
1009 |
|
1010 | watch: {
|
1011 | visibility: function visibility(val) {
|
1012 | var _this = this;
|
1013 |
|
1014 | if (val) {
|
1015 | if (this._opening) return;
|
1016 | if (!this.rendered) {
|
1017 | this.rendered = true;
|
1018 | vue__WEBPACK_IMPORTED_MODULE_0___default.a.nextTick(function () {
|
1019 | _this.open();
|
1020 | });
|
1021 | } else {
|
1022 | this.open();
|
1023 | }
|
1024 | } else {
|
1025 | this.close();
|
1026 | }
|
1027 | }
|
1028 | },
|
1029 |
|
1030 | methods: {
|
1031 | open: function open(options) {
|
1032 | var _this2 = this;
|
1033 |
|
1034 | if (!this.rendered) {
|
1035 | this.rendered = true;
|
1036 | }
|
1037 | var props = Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "e"])({}, this.$props || this, options);
|
1038 |
|
1039 | if (this._closeTimer) {
|
1040 | clearTimeout(this._closeTimer);
|
1041 | this._closeTimer = null;
|
1042 | }
|
1043 | clearTimeout(this._openTimer);
|
1044 |
|
1045 | var openDelay = Number(props.openDelay);
|
1046 | if (openDelay > 0) {
|
1047 | this._openTimer = setTimeout(function () {
|
1048 | _this2._openTimer = null;
|
1049 | _this2.doOpen(props);
|
1050 | }, openDelay);
|
1051 | } else {
|
1052 | this.doOpen(props);
|
1053 | }
|
1054 | },
|
1055 | doOpen: function doOpen(props) {
|
1056 | if (this.$isServer) return;
|
1057 | if (this.willOpen && !this.willOpen()) return;
|
1058 | if (this.opened) return;
|
1059 |
|
1060 | this._opening = true;
|
1061 |
|
1062 | var dom = this.$el;
|
1063 |
|
1064 | var modal = props.modal;
|
1065 |
|
1066 | var zIndex = props.zIndex;
|
1067 | if (zIndex) {
|
1068 | _popup_manager__WEBPACK_IMPORTED_MODULE_2__[ "a"].zIndex = zIndex;
|
1069 | }
|
1070 |
|
1071 | if (modal) {
|
1072 | if (this._closing) {
|
1073 | _popup_manager__WEBPACK_IMPORTED_MODULE_2__[ "a"].closeModal(this._popupId);
|
1074 | this._closing = false;
|
1075 | }
|
1076 | _popup_manager__WEBPACK_IMPORTED_MODULE_2__[ "a"].openModal(this._popupId, _popup_manager__WEBPACK_IMPORTED_MODULE_2__[ "a"].nextZIndex(), this.modalAppendToBody ? undefined : dom, props.modalClass, props.modalFade);
|
1077 | if (props.lockScroll) {
|
1078 | this.withoutHiddenClass = !Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "d"])(document.body, 'mds-popup-parent--hidden');
|
1079 | if (this.withoutHiddenClass) {
|
1080 | this.bodyPaddingRight = document.body.style.paddingRight;
|
1081 | this.computedBodyPaddingRight = parseInt(Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "c"])(document.body, 'paddingRight'), 10);
|
1082 | }
|
1083 | scrollBarWidth = Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "b"])();
|
1084 | var bodyHasOverflow = document.documentElement.clientHeight < document.body.scrollHeight;
|
1085 | var bodyOverflowY = Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "c"])(document.body, 'overflowY');
|
1086 | if (scrollBarWidth > 0 && (bodyHasOverflow || bodyOverflowY === 'scroll') && this.withoutHiddenClass) {
|
1087 | document.body.style.paddingRight = this.computedBodyPaddingRight + scrollBarWidth + 'px';
|
1088 | }
|
1089 | Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "a"])(document.body, 'mds-popup-parent--hidden');
|
1090 | }
|
1091 | }
|
1092 |
|
1093 | if (getComputedStyle(dom).position === 'static') {
|
1094 | dom.style.position = 'absolute';
|
1095 | }
|
1096 |
|
1097 | dom.style.zIndex = _popup_manager__WEBPACK_IMPORTED_MODULE_2__[ "a"].nextZIndex();
|
1098 | this.opened = true;
|
1099 |
|
1100 | this.onOpen && this.onOpen();
|
1101 |
|
1102 | this.doAfterOpen();
|
1103 | },
|
1104 | doAfterOpen: function doAfterOpen() {
|
1105 | this._opening = false;
|
1106 | },
|
1107 | close: function close() {
|
1108 | var _this3 = this;
|
1109 |
|
1110 | if (this.willClose && !this.willClose()) return;
|
1111 |
|
1112 | if (this._openTimer !== null) {
|
1113 | clearTimeout(this._openTimer);
|
1114 | this._openTimer = null;
|
1115 | }
|
1116 | clearTimeout(this._closeTimer);
|
1117 |
|
1118 | var closeDelay = Number(this.closeDelay);
|
1119 |
|
1120 | if (closeDelay > 0) {
|
1121 | this._closeTimer = setTimeout(function () {
|
1122 | _this3._closeTimer = null;
|
1123 | _this3.doClose();
|
1124 | }, closeDelay);
|
1125 | } else {
|
1126 | this.doClose();
|
1127 | }
|
1128 | },
|
1129 | doClose: function doClose() {
|
1130 | this._closing = true;
|
1131 |
|
1132 | this.onClose && this.onClose();
|
1133 |
|
1134 | if (this.lockScroll) {
|
1135 | setTimeout(this.restoreBodyStyle, 200);
|
1136 | }
|
1137 |
|
1138 | this.opened = false;
|
1139 |
|
1140 | this.doAfterClose();
|
1141 | },
|
1142 | doAfterClose: function doAfterClose() {
|
1143 | _popup_manager__WEBPACK_IMPORTED_MODULE_2__[ "a"].closeModal(this._popupId);
|
1144 | this._closing = false;
|
1145 | },
|
1146 | restoreBodyStyle: function restoreBodyStyle() {
|
1147 | if (this.modal && this.withoutHiddenClass) {
|
1148 | document.body.style.paddingRight = this.bodyPaddingRight;
|
1149 | Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "h"])(document.body, 'mds-popup-parent--hidden');
|
1150 | }
|
1151 | this.withoutHiddenClass = true;
|
1152 | }
|
1153 | }
|
1154 | });
|
1155 |
|
1156 |
|
1157 |
|
1158 | }),
|
1159 |
|
1160 | 2:
|
1161 | (function(module, exports) {
|
1162 |
|
1163 | module.exports = __WEBPACK_EXTERNAL_MODULE__2__;
|
1164 |
|
1165 | }),
|
1166 |
|
1167 | 250:
|
1168 | (function(module, exports) {
|
1169 |
|
1170 |
|
1171 |
|
1172 | }),
|
1173 |
|
1174 | 252:
|
1175 | (function(module, exports) {
|
1176 |
|
1177 |
|
1178 |
|
1179 | }),
|
1180 |
|
1181 | 5:
|
1182 | (function(module, __webpack_exports__, __webpack_require__) {
|
1183 |
|
1184 | "use strict";
|
1185 | var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2);
|
1186 | var vue__WEBPACK_IMPORTED_MODULE_0___default = __webpack_require__.n(vue__WEBPACK_IMPORTED_MODULE_0__);
|
1187 | var _dom_helper__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);
|
1188 |
|
1189 |
|
1190 |
|
1191 | var hasModal = false;
|
1192 | var hasInitZIndex = false;
|
1193 | var zIndex = void 0;
|
1194 |
|
1195 | var getModal = function getModal() {
|
1196 | if (vue__WEBPACK_IMPORTED_MODULE_0___default.a.prototype.$isServer) return;
|
1197 | var modalDom = PopupManager.modalDom;
|
1198 | if (modalDom) {
|
1199 | hasModal = true;
|
1200 | } else {
|
1201 | hasModal = false;
|
1202 | modalDom = document.createElement('div');
|
1203 | PopupManager.modalDom = modalDom;
|
1204 |
|
1205 | modalDom.addEventListener('touchmove', function (event) {
|
1206 | event.preventDefault();
|
1207 | event.stopPropagation();
|
1208 | });
|
1209 |
|
1210 | modalDom.addEventListener('click', function () {
|
1211 | PopupManager.doOnModalClick && PopupManager.doOnModalClick();
|
1212 | });
|
1213 | }
|
1214 |
|
1215 | return modalDom;
|
1216 | };
|
1217 |
|
1218 | var instances = {};
|
1219 |
|
1220 | var PopupManager = {
|
1221 | modalFade: true,
|
1222 |
|
1223 | getInstance: function getInstance(id) {
|
1224 | return instances[id];
|
1225 | },
|
1226 |
|
1227 | register: function register(id, instance) {
|
1228 | if (id && instance) {
|
1229 | instances[id] = instance;
|
1230 | }
|
1231 | },
|
1232 |
|
1233 | deregister: function deregister(id) {
|
1234 | if (id) {
|
1235 | instances[id] = null;
|
1236 | delete instances[id];
|
1237 | }
|
1238 | },
|
1239 |
|
1240 | nextZIndex: function nextZIndex() {
|
1241 | return PopupManager.zIndex++;
|
1242 | },
|
1243 |
|
1244 | modalStack: [],
|
1245 |
|
1246 | doOnModalClick: function doOnModalClick() {
|
1247 | var topItem = PopupManager.modalStack[PopupManager.modalStack.length - 1];
|
1248 | if (!topItem) return;
|
1249 |
|
1250 | var instance = PopupManager.getInstance(topItem.id);
|
1251 | if (instance && instance.closeOnClickModal) {
|
1252 | instance.close();
|
1253 | }
|
1254 | },
|
1255 |
|
1256 | openModal: function openModal(id, zIndex, dom, modalClass, modalFade) {
|
1257 | if (vue__WEBPACK_IMPORTED_MODULE_0___default.a.prototype.$isServer) return;
|
1258 | if (!id || zIndex === undefined) return;
|
1259 | this.modalFade = modalFade;
|
1260 |
|
1261 | var modalStack = this.modalStack;
|
1262 |
|
1263 | for (var i = 0, j = modalStack.length; i < j; i++) {
|
1264 | var item = modalStack[i];
|
1265 | if (item.id === id) {
|
1266 | return;
|
1267 | }
|
1268 | }
|
1269 |
|
1270 | var modalDom = getModal();
|
1271 |
|
1272 | Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "a"])(modalDom, 'v-modal');
|
1273 | if (this.modalFade && !hasModal) {
|
1274 | Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "a"])(modalDom, 'v-modal-enter');
|
1275 | }
|
1276 | if (modalClass) {
|
1277 | var classArr = modalClass.trim().split(/\s+/);
|
1278 | classArr.forEach(function (item) {
|
1279 | return Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "a"])(modalDom, item);
|
1280 | });
|
1281 | }
|
1282 | setTimeout(function () {
|
1283 | Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "h"])(modalDom, 'v-modal-enter');
|
1284 | }, 200);
|
1285 |
|
1286 | if (dom && dom.parentNode && dom.parentNode.nodeType !== 11) {
|
1287 | dom.parentNode.appendChild(modalDom);
|
1288 | } else {
|
1289 | document.body.appendChild(modalDom);
|
1290 | }
|
1291 |
|
1292 | if (zIndex) {
|
1293 | modalDom.style.zIndex = zIndex;
|
1294 | }
|
1295 | modalDom.tabIndex = 0;
|
1296 | modalDom.style.display = '';
|
1297 |
|
1298 | this.modalStack.push({ id: id, zIndex: zIndex, modalClass: modalClass });
|
1299 | },
|
1300 |
|
1301 | closeModal: function closeModal(id) {
|
1302 | var modalStack = this.modalStack;
|
1303 | var modalDom = getModal();
|
1304 |
|
1305 | if (modalStack.length > 0) {
|
1306 | var topItem = modalStack[modalStack.length - 1];
|
1307 | if (topItem.id === id) {
|
1308 | if (topItem.modalClass) {
|
1309 | var classArr = topItem.modalClass.trim().split(/\s+/);
|
1310 | classArr.forEach(function (item) {
|
1311 | return Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "h"])(modalDom, item);
|
1312 | });
|
1313 | }
|
1314 |
|
1315 | modalStack.pop();
|
1316 | if (modalStack.length > 0) {
|
1317 | modalDom.style.zIndex = modalStack[modalStack.length - 1].zIndex;
|
1318 | }
|
1319 | } else {
|
1320 | for (var i = modalStack.length - 1; i >= 0; i--) {
|
1321 | if (modalStack[i].id === id) {
|
1322 | modalStack.splice(i, 1);
|
1323 | break;
|
1324 | }
|
1325 | }
|
1326 | }
|
1327 | }
|
1328 |
|
1329 | if (modalStack.length === 0) {
|
1330 | if (this.modalFade) {
|
1331 | Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "a"])(modalDom, 'v-modal-leave');
|
1332 | }
|
1333 | setTimeout(function () {
|
1334 | if (modalStack.length === 0) {
|
1335 | if (modalDom.parentNode) modalDom.parentNode.removeChild(modalDom);
|
1336 | modalDom.style.display = 'none';
|
1337 | PopupManager.modalDom = undefined;
|
1338 | }
|
1339 | Object(_dom_helper__WEBPACK_IMPORTED_MODULE_1__[ "h"])(modalDom, 'v-modal-leave');
|
1340 | }, 200);
|
1341 | }
|
1342 | }
|
1343 | };
|
1344 |
|
1345 | Object.defineProperty(PopupManager, 'zIndex', {
|
1346 | configurable: true,
|
1347 | get: function get() {
|
1348 | if (!hasInitZIndex) {
|
1349 | zIndex = zIndex || (vue__WEBPACK_IMPORTED_MODULE_0___default.a.prototype.$ELEMENT || {}).zIndex || 2000;
|
1350 | hasInitZIndex = true;
|
1351 | }
|
1352 | return zIndex;
|
1353 | },
|
1354 | set: function set(value) {
|
1355 | zIndex = value;
|
1356 | }
|
1357 | });
|
1358 |
|
1359 | var getTopPopup = function getTopPopup() {
|
1360 | if (vue__WEBPACK_IMPORTED_MODULE_0___default.a.prototype.$isServer) return;
|
1361 | if (PopupManager.modalStack.length > 0) {
|
1362 | var topPopup = PopupManager.modalStack[PopupManager.modalStack.length - 1];
|
1363 | if (!topPopup) return;
|
1364 | var instance = PopupManager.getInstance(topPopup.id);
|
1365 |
|
1366 | return instance;
|
1367 | }
|
1368 | };
|
1369 |
|
1370 | if (!vue__WEBPACK_IMPORTED_MODULE_0___default.a.prototype.$isServer) {
|
1371 |
|
1372 | window.addEventListener('keydown', function (event) {
|
1373 | if (event.keyCode === 27) {
|
1374 | var topPopup = getTopPopup();
|
1375 |
|
1376 | if (topPopup && topPopup.closeOnPressEscape) {
|
1377 | topPopup.handleClose ? topPopup.handleClose() : topPopup.handleAction ? topPopup.handleAction('cancel') : topPopup.close();
|
1378 | }
|
1379 | }
|
1380 | });
|
1381 | }
|
1382 |
|
1383 | __webpack_exports__["a"] = (PopupManager);
|
1384 |
|
1385 | }),
|
1386 |
|
1387 | 8:
|
1388 | (function(module, exports) {
|
1389 |
|
1390 | module.exports = __WEBPACK_EXTERNAL_MODULE__8__;
|
1391 |
|
1392 | }),
|
1393 |
|
1394 | 9:
|
1395 | (function(module, exports) {
|
1396 |
|
1397 | module.exports = require("babel-runtime/helpers/typeof");
|
1398 |
|
1399 | })
|
1400 |
|
1401 | });
|
1402 | }); |
\ | No newline at end of file |