cy-element-ui 1.0.55 → 1.0.57

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 (220) hide show
  1. package/lib/alert.js +108 -108
  2. package/lib/aside.js +77 -77
  3. package/lib/autocomplete.js +368 -5207
  4. package/lib/avatar.js +4 -4
  5. package/lib/backtop.js +101 -192
  6. package/lib/badge.js +108 -108
  7. package/lib/breadcrumb-item.js +108 -108
  8. package/lib/breadcrumb.js +94 -94
  9. package/lib/button-group.js +4 -4
  10. package/lib/button.js +4 -4
  11. package/lib/calendar.js +139 -1736
  12. package/lib/card.js +96 -96
  13. package/lib/carousel-item.js +110 -454
  14. package/lib/carousel.js +107 -1258
  15. package/lib/cascader-panel.js +196 -3529
  16. package/lib/cascader.js +711 -8071
  17. package/lib/checkbox-button.js +121 -153
  18. package/lib/checkbox-group.js +17 -49
  19. package/lib/checkbox.js +17 -49
  20. package/lib/col.js +2 -2
  21. package/lib/collapse-item.js +112 -817
  22. package/lib/collapse.js +108 -108
  23. package/lib/color-picker.js +846 -4723
  24. package/lib/container.js +88 -88
  25. package/lib/date-picker.js +4783 -10779
  26. package/lib/descriptions-item.js +2 -2
  27. package/lib/descriptions.js +8 -63
  28. package/lib/dialog.js +24 -1202
  29. package/lib/directives/repeat-click.js +2 -2
  30. package/lib/divider.js +104 -104
  31. package/lib/drawer.js +107 -877
  32. package/lib/dropdown-item.js +96 -128
  33. package/lib/dropdown-menu.js +101 -2303
  34. package/lib/dropdown.js +54 -990
  35. package/lib/element-ui.common.js +14292 -31369
  36. package/lib/empty.js +101 -795
  37. package/lib/fileUpload.js +27 -2543
  38. package/lib/footer.js +77 -77
  39. package/lib/form-item.js +206 -3309
  40. package/lib/form.js +117 -131
  41. package/lib/header.js +77 -77
  42. package/lib/icon.js +67 -67
  43. package/lib/image.js +155 -1671
  44. package/lib/index.js +1 -1
  45. package/lib/infinite-scroll.js +26 -435
  46. package/lib/input-number.js +35 -1424
  47. package/lib/input.js +39 -511
  48. package/lib/link.js +4 -4
  49. package/lib/loading.js +149 -886
  50. package/lib/locale/format.js +1 -1
  51. package/lib/locale/index.js +1 -1
  52. package/lib/main.js +64 -64
  53. package/lib/menu-item-group.js +103 -103
  54. package/lib/menu-item.js +139 -3142
  55. package/lib/menu.js +280 -971
  56. package/lib/message-box.js +181 -2736
  57. package/lib/message.js +118 -1196
  58. package/lib/mixins/locale.js +1 -1
  59. package/lib/mixins/migrating.js +2 -2
  60. package/lib/notification.js +118 -1195
  61. package/lib/option-group.js +121 -153
  62. package/lib/option.js +18 -394
  63. package/lib/page-header.js +87 -781
  64. package/lib/pagination.js +642 -7743
  65. package/lib/popconfirm.js +219 -3606
  66. package/lib/popover.js +101 -2626
  67. package/lib/progress.js +4 -4
  68. package/lib/radio-button.js +121 -153
  69. package/lib/radio-group.js +121 -153
  70. package/lib/radio.js +17 -49
  71. package/lib/rate.js +115 -758
  72. package/lib/result.js +108 -108
  73. package/lib/row.js +2 -2
  74. package/lib/scrollbar.js +41 -1813
  75. package/lib/select.js +220 -5558
  76. package/lib/selectDisplayInput.js +4 -4
  77. package/lib/skeleton-item.js +108 -108
  78. package/lib/skeleton.js +108 -108
  79. package/lib/slider.js +814 -5052
  80. package/lib/spinner.js +100 -100
  81. package/lib/statistic.js +114 -9602
  82. package/lib/step.js +108 -108
  83. package/lib/steps.js +99 -514
  84. package/lib/subTitle.js +91 -91
  85. package/lib/submenu.js +76 -2397
  86. package/lib/switch.js +129 -584
  87. package/lib/tab-pane.js +108 -108
  88. package/lib/tabDialog.js +106 -1632
  89. package/lib/table-column.js +267 -1115
  90. package/lib/table.js +1297 -7111
  91. package/lib/tabs.js +115 -1617
  92. package/lib/tag.js +4 -4
  93. package/lib/time-picker.js +599 -6491
  94. package/lib/time-select.js +409 -6336
  95. package/lib/timeline-item.js +108 -108
  96. package/lib/timeline.js +4 -4
  97. package/lib/tooltip.js +44 -2688
  98. package/lib/transfer.js +155 -2247
  99. package/lib/transitions/collapse-transition.js +1 -1
  100. package/lib/tree.js +157 -1572
  101. package/lib/treeSelect.js +108 -3423
  102. package/lib/upload.js +36 -1203
  103. package/lib/utils/clickoutside.js +1 -1
  104. package/lib/utils/date-util.js +2 -2
  105. package/lib/utils/popup/index.js +2 -2
  106. package/lib/utils/popup/popup-manager.js +1 -1
  107. package/lib/utils/util.js +1 -1
  108. package/lib/utils/vdom.js +1 -1
  109. package/lib/utils/vue-popper.js +1 -1
  110. package/package.json +1 -1
  111. package/packages/autocomplete/src/autocomplete-suggestions.vue +3 -3
  112. package/packages/autocomplete/src/autocomplete.vue +6 -6
  113. package/packages/calendar/src/date-table.vue +2 -2
  114. package/packages/calendar/src/main.vue +5 -5
  115. package/packages/carousel/src/item.vue +1 -1
  116. package/packages/carousel/src/main.vue +1 -1
  117. package/packages/cascader/src/cascader.vue +15 -15
  118. package/packages/cascader-panel/src/cascader-menu.vue +3 -3
  119. package/packages/cascader-panel/src/cascader-node.vue +3 -3
  120. package/packages/cascader-panel/src/cascader-panel.vue +4 -4
  121. package/packages/cascader-panel/src/node.js +3 -3
  122. package/packages/cascader-panel/src/store.js +2 -2
  123. package/packages/checkbox/src/checkbox-button.vue +1 -1
  124. package/packages/checkbox/src/checkbox-group.vue +1 -1
  125. package/packages/checkbox/src/checkbox.vue +1 -1
  126. package/packages/collapse/src/collapse-item.vue +3 -3
  127. package/packages/color-picker/src/components/picker-dropdown.vue +4 -4
  128. package/packages/color-picker/src/main.vue +2 -2
  129. package/packages/date-picker/src/basic/date-table.vue +3 -3
  130. package/packages/date-picker/src/basic/month-table.vue +5 -5
  131. package/packages/date-picker/src/basic/time-spinner.vue +3 -3
  132. package/packages/date-picker/src/basic/year-table.vue +3 -3
  133. package/packages/date-picker/src/panel/date-range.vue +5 -5
  134. package/packages/date-picker/src/panel/date.vue +5 -5
  135. package/packages/date-picker/src/panel/month-range.vue +5 -5
  136. package/packages/date-picker/src/panel/time-range.vue +2 -2
  137. package/packages/date-picker/src/panel/time-select.vue +2 -2
  138. package/packages/date-picker/src/panel/time.vue +2 -2
  139. package/packages/date-picker/src/picker.vue +6 -6
  140. package/packages/descriptions/src/index.js +1 -1
  141. package/packages/dialog/src/component.vue +3 -3
  142. package/packages/drawer/src/main.vue +2 -2
  143. package/packages/dropdown/src/dropdown-item.vue +1 -1
  144. package/packages/dropdown/src/dropdown-menu.vue +1 -1
  145. package/packages/dropdown/src/dropdown.vue +6 -6
  146. package/packages/empty/src/index.vue +1 -1
  147. package/packages/fileUpload/src/main.vue +3 -3
  148. package/packages/form/src/form-item.vue +3 -3
  149. package/packages/form/src/form.vue +1 -1
  150. package/packages/image/src/image-viewer.vue +3 -3
  151. package/packages/image/src/main.vue +3 -3
  152. package/packages/infinite-scroll/src/main.js +3 -3
  153. package/packages/input/src/input.vue +4 -4
  154. package/packages/input-number/src/input-number.vue +3 -3
  155. package/packages/loading/src/directive.js +3 -3
  156. package/packages/loading/src/index.js +4 -4
  157. package/packages/menu/src/menu-item.vue +2 -2
  158. package/packages/menu/src/menu.vue +4 -4
  159. package/packages/menu/src/submenu.vue +4 -4
  160. package/packages/message/src/main.js +3 -3
  161. package/packages/message-box/src/main.js +2 -2
  162. package/packages/message-box/src/main.vue +7 -7
  163. package/packages/notification/src/main.js +3 -3
  164. package/packages/page-header/src/main.vue +1 -1
  165. package/packages/pagination/src/pagination.js +5 -5
  166. package/packages/popconfirm/src/main.vue +3 -3
  167. package/packages/popover/src/main.vue +4 -4
  168. package/packages/radio/src/radio-button.vue +1 -1
  169. package/packages/radio/src/radio-group.vue +1 -1
  170. package/packages/radio/src/radio.vue +1 -1
  171. package/packages/rate/src/main.vue +3 -3
  172. package/packages/scrollbar/src/bar.js +1 -1
  173. package/packages/scrollbar/src/main.js +3 -3
  174. package/packages/select/src/option-group.vue +1 -1
  175. package/packages/select/src/option.vue +2 -2
  176. package/packages/select/src/select-dropdown.vue +1 -1
  177. package/packages/select/src/select.vue +11 -11
  178. package/packages/slider/src/button.vue +1 -1
  179. package/packages/slider/src/main.vue +2 -2
  180. package/packages/statistic/src/main.vue +2 -2
  181. package/packages/steps/src/steps.vue +1 -1
  182. package/packages/switch/src/component.vue +3 -3
  183. package/packages/tabDialog/src/main.vue +1 -1
  184. package/packages/table/src/config.js +1 -1
  185. package/packages/table/src/filter-panel.vue +7 -7
  186. package/packages/table/src/store/current.js +1 -1
  187. package/packages/table/src/store/index.js +1 -1
  188. package/packages/table/src/store/watcher.js +1 -1
  189. package/packages/table/src/table-body.js +4 -4
  190. package/packages/table/src/table-column.js +1 -1
  191. package/packages/table/src/table-header.js +2 -2
  192. package/packages/table/src/table-layout.js +1 -1
  193. package/packages/table/src/table-row.js +1 -1
  194. package/packages/table/src/table.vue +5 -5
  195. package/packages/table/src/util.js +1 -1
  196. package/packages/tabs/src/tab-bar.vue +1 -1
  197. package/packages/tabs/src/tab-nav.vue +1 -1
  198. package/packages/tooltip/src/main.js +3 -3
  199. package/packages/transfer/src/main.vue +4 -4
  200. package/packages/transfer/src/transfer-panel.vue +4 -4
  201. package/packages/tree/src/model/node.js +2 -2
  202. package/packages/tree/src/tree-node.vue +3 -3
  203. package/packages/tree/src/tree.vue +3 -3
  204. package/packages/treeSelect/src/main.vue +2 -2
  205. package/packages/upload/src/index.vue +2 -2
  206. package/packages/upload/src/upload-list.vue +2 -2
  207. package/src/directives/repeat-click.js +2 -2
  208. package/src/index.js +1 -1
  209. package/src/locale/format.js +2 -2
  210. package/src/locale/index.js +1 -1
  211. package/src/mixins/locale.js +1 -1
  212. package/src/mixins/migrating.js +2 -2
  213. package/src/transitions/collapse-transition.js +1 -1
  214. package/src/utils/clickoutside.js +1 -1
  215. package/src/utils/date-util.js +2 -2
  216. package/src/utils/popup/index.js +2 -2
  217. package/src/utils/popup/popup-manager.js +1 -1
  218. package/src/utils/util.js +1 -1
  219. package/src/utils/vdom.js +1 -1
  220. package/src/utils/vue-popper.js +1 -1
package/lib/menu.js CHANGED
@@ -82,393 +82,321 @@ module.exports =
82
82
  /******/
83
83
  /******/
84
84
  /******/ // Load entry module and return exports
85
- /******/ return __webpack_require__(__webpack_require__.s = 154);
85
+ /******/ return __webpack_require__(__webpack_require__.s = 76);
86
86
  /******/ })
87
87
  /************************************************************************/
88
88
  /******/ ({
89
89
 
90
90
  /***/ 0:
91
- /***/ (function(module, exports) {
92
-
93
- module.exports = require("vue");
94
-
95
- /***/ }),
96
-
97
- /***/ 1:
98
91
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
99
92
 
100
93
  "use strict";
101
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "g", function() { return on; });
102
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return off; });
103
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "h", function() { return once; });
104
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return hasClass; });
105
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return addClass; });
106
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "i", function() { return removeClass; });
107
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return getStyle; });
108
- /* unused harmony export setStyle */
109
- /* unused harmony export isScroll */
110
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return getScrollContainer; });
111
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return isInContainer; });
112
- /* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
113
- /* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(vue__WEBPACK_IMPORTED_MODULE_0__);
114
- var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
115
-
116
- /* istanbul ignore next */
117
-
118
-
119
-
120
- var isServer = vue__WEBPACK_IMPORTED_MODULE_0___default.a.prototype.$isServer;
121
- var SPECIAL_CHARS_REGEXP = /([\:\-\_]+(.))/g;
122
- var MOZ_HACK_REGEXP = /^moz([A-Z])/;
123
- var ieVersion = isServer ? 0 : Number(document.documentMode);
124
-
125
- /* istanbul ignore next */
126
- var trim = function trim(string) {
127
- return (string || '').replace(/^[\s\uFEFF]+|[\s\uFEFF]+$/g, '');
128
- };
129
- /* istanbul ignore next */
130
- var camelCase = function camelCase(name) {
131
- return name.replace(SPECIAL_CHARS_REGEXP, function (_, separator, letter, offset) {
132
- return offset ? letter.toUpperCase() : letter;
133
- }).replace(MOZ_HACK_REGEXP, 'Moz$1');
134
- };
135
-
136
- /* istanbul ignore next */
137
- var on = function () {
138
- if (!isServer && document.addEventListener) {
139
- return function (element, event, handler) {
140
- if (element && event && handler) {
141
- element.addEventListener(event, handler, false);
142
- }
143
- };
144
- } else {
145
- return function (element, event, handler) {
146
- if (element && event && handler) {
147
- element.attachEvent('on' + event, handler);
148
- }
149
- };
150
- }
151
- }();
152
-
153
- /* istanbul ignore next */
154
- var off = function () {
155
- if (!isServer && document.removeEventListener) {
156
- return function (element, event, handler) {
157
- if (element && event) {
158
- element.removeEventListener(event, handler, false);
159
- }
160
- };
161
- } else {
162
- return function (element, event, handler) {
163
- if (element && event) {
164
- element.detachEvent('on' + event, handler);
165
- }
166
- };
167
- }
168
- }();
169
-
170
- /* istanbul ignore next */
171
- var once = function once(el, event, fn) {
172
- var listener = function listener() {
173
- if (fn) {
174
- fn.apply(this, arguments);
175
- }
176
- off(el, event, listener);
177
- };
178
- on(el, event, listener);
179
- };
180
-
181
- /* istanbul ignore next */
182
- function hasClass(el, cls) {
183
- if (!el || !cls) return false;
184
- if (cls.indexOf(' ') !== -1) throw new Error('className should not contain space.');
185
- if (el.classList) {
186
- return el.classList.contains(cls);
187
- } else {
188
- return (' ' + el.className + ' ').indexOf(' ' + cls + ' ') > -1;
189
- }
190
- };
191
-
192
- /* istanbul ignore next */
193
- function addClass(el, cls) {
194
- if (!el) return;
195
- var curClass = el.className;
196
- var classes = (cls || '').split(' ');
197
-
198
- for (var i = 0, j = classes.length; i < j; i++) {
199
- var clsName = classes[i];
200
- if (!clsName) continue;
201
-
202
- if (el.classList) {
203
- el.classList.add(clsName);
204
- } else if (!hasClass(el, clsName)) {
205
- curClass += ' ' + clsName;
206
- }
207
- }
208
- if (!el.classList) {
209
- el.setAttribute('class', curClass);
210
- }
211
- };
212
-
213
- /* istanbul ignore next */
214
- function removeClass(el, cls) {
215
- if (!el || !cls) return;
216
- var classes = cls.split(' ');
217
- var curClass = ' ' + el.className + ' ';
218
-
219
- for (var i = 0, j = classes.length; i < j; i++) {
220
- var clsName = classes[i];
221
- if (!clsName) continue;
222
-
223
- if (el.classList) {
224
- el.classList.remove(clsName);
225
- } else if (hasClass(el, clsName)) {
226
- curClass = curClass.replace(' ' + clsName + ' ', ' ');
227
- }
228
- }
229
- if (!el.classList) {
230
- el.setAttribute('class', trim(curClass));
231
- }
232
- };
233
-
234
- /* istanbul ignore next */
235
- var getStyle = ieVersion < 9 ? function (element, styleName) {
236
- if (isServer) return;
237
- if (!element || !styleName) return null;
238
- styleName = camelCase(styleName);
239
- if (styleName === 'float') {
240
- styleName = 'styleFloat';
241
- }
242
- try {
243
- switch (styleName) {
244
- case 'opacity':
245
- try {
246
- return element.filters.item('alpha').opacity / 100;
247
- } catch (e) {
248
- return 1.0;
249
- }
250
- default:
251
- return element.style[styleName] || element.currentStyle ? element.currentStyle[styleName] : null;
252
- }
253
- } catch (e) {
254
- return element.style[styleName];
255
- }
256
- } : function (element, styleName) {
257
- if (isServer) return;
258
- if (!element || !styleName) return null;
259
- styleName = camelCase(styleName);
260
- if (styleName === 'float') {
261
- styleName = 'cssFloat';
262
- }
263
- try {
264
- var computed = document.defaultView.getComputedStyle(element, '');
265
- return element.style[styleName] || computed ? computed[styleName] : null;
266
- } catch (e) {
267
- return element.style[styleName];
268
- }
269
- };
94
+ /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return normalizeComponent; });
95
+ /* globals __VUE_SSR_CONTEXT__ */
270
96
 
271
- /* istanbul ignore next */
272
- function setStyle(element, styleName, value) {
273
- if (!element || !styleName) return;
97
+ // IMPORTANT: Do NOT use ES2015 features in this file (except for modules).
98
+ // This module is a runtime utility for cleaner component module output and will
99
+ // be included in the final webpack user bundle.
274
100
 
275
- if ((typeof styleName === 'undefined' ? 'undefined' : _typeof(styleName)) === 'object') {
276
- for (var prop in styleName) {
277
- if (styleName.hasOwnProperty(prop)) {
278
- setStyle(element, prop, styleName[prop]);
279
- }
280
- }
281
- } else {
282
- styleName = camelCase(styleName);
283
- if (styleName === 'opacity' && ieVersion < 9) {
284
- element.style.filter = isNaN(value) ? '' : 'alpha(opacity=' + value * 100 + ')';
285
- } else {
286
- element.style[styleName] = value;
287
- }
288
- }
289
- };
101
+ function normalizeComponent(
102
+ scriptExports,
103
+ render,
104
+ staticRenderFns,
105
+ functionalTemplate,
106
+ injectStyles,
107
+ scopeId,
108
+ moduleIdentifier /* server only */,
109
+ shadowMode /* vue-cli only */
110
+ ) {
111
+ // Vue.extend constructor export interop
112
+ var options =
113
+ typeof scriptExports === 'function' ? scriptExports.options : scriptExports
290
114
 
291
- var isScroll = function isScroll(el, vertical) {
292
- if (isServer) return;
115
+ // render functions
116
+ if (render) {
117
+ options.render = render
118
+ options.staticRenderFns = staticRenderFns
119
+ options._compiled = true
120
+ }
293
121
 
294
- var determinedDirection = vertical !== null && vertical !== undefined;
295
- var overflow = determinedDirection ? vertical ? getStyle(el, 'overflow-y') : getStyle(el, 'overflow-x') : getStyle(el, 'overflow');
122
+ // functional template
123
+ if (functionalTemplate) {
124
+ options.functional = true
125
+ }
296
126
 
297
- return overflow.match(/(scroll|auto|overlay)/);
298
- };
127
+ // scopedId
128
+ if (scopeId) {
129
+ options._scopeId = 'data-v-' + scopeId
130
+ }
299
131
 
300
- var getScrollContainer = function getScrollContainer(el, vertical) {
301
- if (isServer) return;
132
+ var hook
133
+ if (moduleIdentifier) {
134
+ // server build
135
+ hook = function (context) {
136
+ // 2.3 injection
137
+ context =
138
+ context || // cached call
139
+ (this.$vnode && this.$vnode.ssrContext) || // stateful
140
+ (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional
141
+ // 2.2 with runInNewContext: true
142
+ if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {
143
+ context = __VUE_SSR_CONTEXT__
144
+ }
145
+ // inject component styles
146
+ if (injectStyles) {
147
+ injectStyles.call(this, context)
148
+ }
149
+ // register component module identifier for async chunk inferrence
150
+ if (context && context._registeredComponents) {
151
+ context._registeredComponents.add(moduleIdentifier)
152
+ }
153
+ }
154
+ // used by ssr in case component is cached and beforeCreate
155
+ // never gets called
156
+ options._ssrRegister = hook
157
+ } else if (injectStyles) {
158
+ hook = shadowMode
159
+ ? function () {
160
+ injectStyles.call(
161
+ this,
162
+ (options.functional ? this.parent : this).$root.$options.shadowRoot
163
+ )
164
+ }
165
+ : injectStyles
166
+ }
302
167
 
303
- var parent = el;
304
- while (parent) {
305
- if ([window, document, document.documentElement].includes(parent)) {
306
- return window;
307
- }
308
- if (isScroll(parent, vertical)) {
309
- return parent;
310
- }
311
- parent = parent.parentNode;
312
- }
168
+ if (hook) {
169
+ if (options.functional) {
170
+ // for template-only hot-reload because in that case the render fn doesn't
171
+ // go through the normalizer
172
+ options._injectStyles = hook
173
+ // register for functional component in vue file
174
+ var originalRender = options.render
175
+ options.render = function renderWithStyleInjection(h, context) {
176
+ hook.call(context)
177
+ return originalRender(h, context)
178
+ }
179
+ } else {
180
+ // inject component registration as beforeCreate hook
181
+ var existing = options.beforeCreate
182
+ options.beforeCreate = existing ? [].concat(existing, hook) : [hook]
183
+ }
184
+ }
313
185
 
314
- return parent;
315
- };
186
+ return {
187
+ exports: scriptExports,
188
+ options: options
189
+ }
190
+ }
316
191
 
317
- var isInContainer = function isInContainer(el, container) {
318
- if (isServer || !el || !container) return false;
319
192
 
320
- var elRect = el.getBoundingClientRect();
321
- var containerRect = void 0;
193
+ /***/ }),
322
194
 
323
- if ([window, document, document.documentElement, null, undefined].includes(container)) {
324
- containerRect = {
325
- top: 0,
326
- right: window.innerWidth,
327
- bottom: window.innerHeight,
328
- left: 0
329
- };
330
- } else {
331
- containerRect = container.getBoundingClientRect();
332
- }
195
+ /***/ 11:
196
+ /***/ (function(module, exports) {
333
197
 
334
- return elRect.top < containerRect.bottom && elRect.bottom > containerRect.top && elRect.right > containerRect.left && elRect.left < containerRect.right;
335
- };
198
+ module.exports = require("cy-element-ui/lib/mixins/migrating");
336
199
 
337
200
  /***/ }),
338
201
 
339
- /***/ 12:
340
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
202
+ /***/ 2:
203
+ /***/ (function(module, exports) {
341
204
 
342
- "use strict";
343
- /* harmony import */ var _utils_util__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3);
205
+ module.exports = require("cy-element-ui/lib/utils/dom");
344
206
 
345
- /**
346
- * Show migrating guide in browser console.
347
- *
348
- * Usage:
349
- * import Migrating from 'element-ui/src/mixins/migrating';
350
- *
351
- * mixins: [Migrating]
352
- *
353
- * add getMigratingConfig method for your component.
354
- * getMigratingConfig() {
355
- * return {
356
- * props: {
357
- * 'allow-no-selection': 'allow-no-selection is removed.',
358
- * 'selection-mode': 'selection-mode is removed.'
359
- * },
360
- * events: {
361
- * selectionchange: 'selectionchange is renamed to selection-change.'
362
- * }
363
- * };
364
- * },
365
- */
366
- /* harmony default export */ __webpack_exports__["a"] = ({
367
- mounted: function mounted() {
368
- if (true) return;
369
- if (!this.$vnode) return;
370
-
371
- var _getMigratingConfig = this.getMigratingConfig(),
372
- _getMigratingConfig$p = _getMigratingConfig.props,
373
- props = _getMigratingConfig$p === undefined ? {} : _getMigratingConfig$p,
374
- _getMigratingConfig$e = _getMigratingConfig.events,
375
- events = _getMigratingConfig$e === undefined ? {} : _getMigratingConfig$e;
376
-
377
- var _$vnode = this.$vnode,
378
- data = _$vnode.data,
379
- componentOptions = _$vnode.componentOptions;
380
-
381
- var definedProps = data.attrs || {};
382
- var definedEvents = componentOptions.listeners || {};
383
-
384
- for (var propName in definedProps) {
385
- propName = Object(_utils_util__WEBPACK_IMPORTED_MODULE_0__[/* kebabCase */ "q"])(propName); // compatible with camel case
386
- if (props[propName]) {
387
- console.warn('[Element Migrating][' + this.$options.name + '][Attribute]: ' + props[propName]);
388
- }
389
- }
207
+ /***/ }),
390
208
 
391
- for (var eventName in definedEvents) {
392
- eventName = Object(_utils_util__WEBPACK_IMPORTED_MODULE_0__[/* kebabCase */ "q"])(eventName); // compatible with camel case
393
- if (events[eventName]) {
394
- console.warn('[Element Migrating][' + this.$options.name + '][Event]: ' + events[eventName]);
395
- }
396
- }
397
- },
209
+ /***/ 4:
210
+ /***/ (function(module, exports) {
398
211
 
399
- methods: {
400
- getMigratingConfig: function getMigratingConfig() {
401
- return {
402
- props: {},
403
- events: {}
404
- };
405
- }
406
- }
407
- });
212
+ module.exports = require("cy-element-ui/lib/mixins/emitter");
408
213
 
409
214
  /***/ }),
410
215
 
411
- /***/ 154:
216
+ /***/ 76:
412
217
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
413
218
 
414
219
  "use strict";
415
220
  // ESM COMPAT FLAG
416
221
  __webpack_require__.r(__webpack_exports__);
417
222
 
418
- // EXTERNAL MODULE: ./src/mixins/emitter.js
419
- var emitter = __webpack_require__(6);
420
-
421
- // EXTERNAL MODULE: ./src/mixins/migrating.js
422
- var migrating = __webpack_require__(12);
223
+ // EXTERNAL MODULE: external "cy-element-ui/lib/mixins/emitter"
224
+ var emitter_ = __webpack_require__(4);
225
+ var emitter_default = /*#__PURE__*/__webpack_require__.n(emitter_);
423
226
 
424
- // EXTERNAL MODULE: ./src/utils/aria-utils.js
425
- var aria_utils = __webpack_require__(30);
227
+ // EXTERNAL MODULE: external "cy-element-ui/lib/mixins/migrating"
228
+ var migrating_ = __webpack_require__(11);
229
+ var migrating_default = /*#__PURE__*/__webpack_require__.n(migrating_);
426
230
 
427
- // CONCATENATED MODULE: ./src/utils/menu/aria-submenu.js
231
+ // CONCATENATED MODULE: ./src/utils/aria-utils.js
232
+ var aria = aria || {};
428
233
 
234
+ aria.Utils = aria.Utils || {};
429
235
 
430
- var SubMenu = function SubMenu(parent, domNode) {
431
- this.domNode = domNode;
432
- this.parent = parent;
433
- this.subMenuItems = [];
434
- this.subIndex = 0;
435
- this.init();
236
+ /**
237
+ * @desc Set focus on descendant nodes until the first focusable element is
238
+ * found.
239
+ * @param element
240
+ * DOM node for which to find the first focusable descendant.
241
+ * @returns
242
+ * true if a focusable element is found and focus is set.
243
+ */
244
+ aria.Utils.focusFirstDescendant = function (element) {
245
+ for (var i = 0; i < element.childNodes.length; i++) {
246
+ var child = element.childNodes[i];
247
+ if (aria.Utils.attemptFocus(child) || aria.Utils.focusFirstDescendant(child)) {
248
+ return true;
249
+ }
250
+ }
251
+ return false;
436
252
  };
437
253
 
438
- SubMenu.prototype.init = function () {
439
- this.subMenuItems = this.domNode.querySelectorAll('li');
440
- this.addListeners();
441
- };
254
+ /**
255
+ * @desc Find the last descendant node that is focusable.
256
+ * @param element
257
+ * DOM node for which to find the last focusable descendant.
258
+ * @returns
259
+ * true if a focusable element is found and focus is set.
260
+ */
442
261
 
443
- SubMenu.prototype.gotoSubIndex = function (idx) {
444
- if (idx === this.subMenuItems.length) {
445
- idx = 0;
446
- } else if (idx < 0) {
447
- idx = this.subMenuItems.length - 1;
262
+ aria.Utils.focusLastDescendant = function (element) {
263
+ for (var i = element.childNodes.length - 1; i >= 0; i--) {
264
+ var child = element.childNodes[i];
265
+ if (aria.Utils.attemptFocus(child) || aria.Utils.focusLastDescendant(child)) {
266
+ return true;
267
+ }
448
268
  }
449
- this.subMenuItems[idx].focus();
450
- this.subIndex = idx;
269
+ return false;
451
270
  };
452
271
 
453
- SubMenu.prototype.addListeners = function () {
454
- var _this = this;
455
-
456
- var keys = aria_utils["a" /* default */].keys;
457
- var parentNode = this.parent.domNode;
458
- Array.prototype.forEach.call(this.subMenuItems, function (el) {
459
- el.addEventListener('keydown', function (event) {
460
- var prevDef = false;
461
- switch (event.keyCode) {
462
- case keys.down:
463
- _this.gotoSubIndex(_this.subIndex + 1);
464
- prevDef = true;
465
- break;
272
+ /**
273
+ * @desc Set Attempt to set focus on the current node.
274
+ * @param element
275
+ * The node to attempt to focus on.
276
+ * @returns
277
+ * true if element is focused.
278
+ */
279
+ aria.Utils.attemptFocus = function (element) {
280
+ if (!aria.Utils.isFocusable(element)) {
281
+ return false;
282
+ }
283
+ aria.Utils.IgnoreUtilFocusChanges = true;
284
+ try {
285
+ element.focus();
286
+ } catch (e) {}
287
+ aria.Utils.IgnoreUtilFocusChanges = false;
288
+ return document.activeElement === element;
289
+ };
290
+
291
+ aria.Utils.isFocusable = function (element) {
292
+ if (element.tabIndex > 0 || element.tabIndex === 0 && element.getAttribute('tabIndex') !== null) {
293
+ return true;
294
+ }
295
+
296
+ if (element.disabled) {
297
+ return false;
298
+ }
299
+
300
+ switch (element.nodeName) {
301
+ case 'A':
302
+ return !!element.href && element.rel !== 'ignore';
303
+ case 'INPUT':
304
+ return element.type !== 'hidden' && element.type !== 'file';
305
+ case 'BUTTON':
306
+ case 'SELECT':
307
+ case 'TEXTAREA':
308
+ return true;
309
+ default:
310
+ return false;
311
+ }
312
+ };
313
+
314
+ /**
315
+ * 触发一个事件
316
+ * mouseenter, mouseleave, mouseover, keyup, change, click 等
317
+ * @param {Element} elm
318
+ * @param {String} name
319
+ * @param {*} opts
320
+ */
321
+ aria.Utils.triggerEvent = function (elm, name) {
322
+ var eventName = void 0;
323
+
324
+ if (/^mouse|click/.test(name)) {
325
+ eventName = 'MouseEvents';
326
+ } else if (/^key/.test(name)) {
327
+ eventName = 'KeyboardEvent';
328
+ } else {
329
+ eventName = 'HTMLEvents';
330
+ }
331
+ var evt = document.createEvent(eventName);
332
+
333
+ for (var _len = arguments.length, opts = Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) {
334
+ opts[_key - 2] = arguments[_key];
335
+ }
336
+
337
+ evt.initEvent.apply(evt, [name].concat(opts));
338
+ elm.dispatchEvent ? elm.dispatchEvent(evt) : elm.fireEvent('on' + name, evt);
339
+
340
+ return elm;
341
+ };
342
+
343
+ aria.Utils.keys = {
344
+ tab: 9,
345
+ enter: 13,
346
+ space: 32,
347
+ left: 37,
348
+ up: 38,
349
+ right: 39,
350
+ down: 40,
351
+ esc: 27
352
+ };
353
+
354
+ /* harmony default export */ var aria_utils = (aria.Utils);
355
+ // CONCATENATED MODULE: ./src/utils/menu/aria-submenu.js
356
+
357
+
358
+ var SubMenu = function SubMenu(parent, domNode) {
359
+ this.domNode = domNode;
360
+ this.parent = parent;
361
+ this.subMenuItems = [];
362
+ this.subIndex = 0;
363
+ this.init();
364
+ };
365
+
366
+ SubMenu.prototype.init = function () {
367
+ this.subMenuItems = this.domNode.querySelectorAll('li');
368
+ this.addListeners();
369
+ };
370
+
371
+ SubMenu.prototype.gotoSubIndex = function (idx) {
372
+ if (idx === this.subMenuItems.length) {
373
+ idx = 0;
374
+ } else if (idx < 0) {
375
+ idx = this.subMenuItems.length - 1;
376
+ }
377
+ this.subMenuItems[idx].focus();
378
+ this.subIndex = idx;
379
+ };
380
+
381
+ SubMenu.prototype.addListeners = function () {
382
+ var _this = this;
383
+
384
+ var keys = aria_utils.keys;
385
+ var parentNode = this.parent.domNode;
386
+ Array.prototype.forEach.call(this.subMenuItems, function (el) {
387
+ el.addEventListener('keydown', function (event) {
388
+ var prevDef = false;
389
+ switch (event.keyCode) {
390
+ case keys.down:
391
+ _this.gotoSubIndex(_this.subIndex + 1);
392
+ prevDef = true;
393
+ break;
466
394
  case keys.up:
467
395
  _this.gotoSubIndex(_this.subIndex - 1);
468
396
  prevDef = true;
469
397
  break;
470
398
  case keys.tab:
471
- aria_utils["a" /* default */].triggerEvent(parentNode, 'mouseleave');
399
+ aria_utils.triggerEvent(parentNode, 'mouseleave');
472
400
  break;
473
401
  case keys.enter:
474
402
  case keys.space:
@@ -508,22 +436,22 @@ MenuItem.prototype.init = function () {
508
436
  MenuItem.prototype.addListeners = function () {
509
437
  var _this = this;
510
438
 
511
- var keys = aria_utils["a" /* default */].keys;
439
+ var keys = aria_utils.keys;
512
440
  this.domNode.addEventListener('keydown', function (event) {
513
441
  var prevDef = false;
514
442
  switch (event.keyCode) {
515
443
  case keys.down:
516
- aria_utils["a" /* default */].triggerEvent(event.currentTarget, 'mouseenter');
444
+ aria_utils.triggerEvent(event.currentTarget, 'mouseenter');
517
445
  _this.submenu && _this.submenu.gotoSubIndex(0);
518
446
  prevDef = true;
519
447
  break;
520
448
  case keys.up:
521
- aria_utils["a" /* default */].triggerEvent(event.currentTarget, 'mouseenter');
449
+ aria_utils.triggerEvent(event.currentTarget, 'mouseenter');
522
450
  _this.submenu && _this.submenu.gotoSubIndex(_this.submenu.subMenuItems.length - 1);
523
451
  prevDef = true;
524
452
  break;
525
453
  case keys.tab:
526
- aria_utils["a" /* default */].triggerEvent(event.currentTarget, 'mouseleave');
454
+ aria_utils.triggerEvent(event.currentTarget, 'mouseleave');
527
455
  break;
528
456
  case keys.enter:
529
457
  case keys.space:
@@ -555,8 +483,8 @@ Menu.prototype.init = function () {
555
483
  });
556
484
  };
557
485
  /* harmony default export */ var aria_menubar = (Menu);
558
- // EXTERNAL MODULE: ./src/utils/dom.js
559
- var dom = __webpack_require__(1);
486
+ // EXTERNAL MODULE: external "cy-element-ui/lib/utils/dom"
487
+ var dom_ = __webpack_require__(2);
560
488
 
561
489
  // CONCATENATED MODULE: ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib??vue-loader-options!./packages/menu/src/menu.vue?vue&type=script&lang=js
562
490
 
@@ -596,7 +524,7 @@ var dom = __webpack_require__(1);
596
524
 
597
525
  componentName: 'ElMenu',
598
526
 
599
- mixins: [emitter["a" /* default */], migrating["a" /* default */]],
527
+ mixins: [emitter_default.a, migrating_default.a],
600
528
 
601
529
  provide: function provide() {
602
530
  return {
@@ -618,33 +546,33 @@ var dom = __webpack_require__(1);
618
546
  el.style.opacity = 0.2;
619
547
  },
620
548
  enter: function enter(el) {
621
- Object(dom["a" /* addClass */])(el, 'el-opacity-transition');
549
+ Object(dom_["addClass"])(el, 'el-opacity-transition');
622
550
  el.style.opacity = 1;
623
551
  },
624
552
  afterEnter: function afterEnter(el) {
625
- Object(dom["i" /* removeClass */])(el, 'el-opacity-transition');
553
+ Object(dom_["removeClass"])(el, 'el-opacity-transition');
626
554
  el.style.opacity = '';
627
555
  },
628
556
  beforeLeave: function beforeLeave(el) {
629
557
  if (!el.dataset) el.dataset = {};
630
558
 
631
- if (Object(dom["d" /* hasClass */])(el, 'el-menu--collapse')) {
632
- Object(dom["i" /* removeClass */])(el, 'el-menu--collapse');
559
+ if (Object(dom_["hasClass"])(el, 'el-menu--collapse')) {
560
+ Object(dom_["removeClass"])(el, 'el-menu--collapse');
633
561
  el.dataset.oldOverflow = el.style.overflow;
634
562
  el.dataset.scrollWidth = el.clientWidth;
635
- Object(dom["a" /* addClass */])(el, 'el-menu--collapse');
563
+ Object(dom_["addClass"])(el, 'el-menu--collapse');
636
564
  } else {
637
- Object(dom["a" /* addClass */])(el, 'el-menu--collapse');
565
+ Object(dom_["addClass"])(el, 'el-menu--collapse');
638
566
  el.dataset.oldOverflow = el.style.overflow;
639
567
  el.dataset.scrollWidth = el.clientWidth;
640
- Object(dom["i" /* removeClass */])(el, 'el-menu--collapse');
568
+ Object(dom_["removeClass"])(el, 'el-menu--collapse');
641
569
  }
642
570
 
643
571
  el.style.width = el.scrollWidth + 'px';
644
572
  el.style.overflow = 'hidden';
645
573
  },
646
574
  leave: function leave(el) {
647
- Object(dom["a" /* addClass */])(el, 'horizontal-collapse-transition');
575
+ Object(dom_["addClass"])(el, 'horizontal-collapse-transition');
648
576
  el.style.width = el.dataset.scrollWidth + 'px';
649
577
  }
650
578
  }
@@ -900,7 +828,7 @@ var dom = __webpack_require__(1);
900
828
  // CONCATENATED MODULE: ./packages/menu/src/menu.vue?vue&type=script&lang=js
901
829
  /* harmony default export */ var src_menuvue_type_script_lang_js = (menuvue_type_script_lang_js);
902
830
  // EXTERNAL MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js
903
- var componentNormalizer = __webpack_require__(2);
831
+ var componentNormalizer = __webpack_require__(0);
904
832
 
905
833
  // CONCATENATED MODULE: ./packages/menu/src/menu.vue
906
834
  var menu_render, staticRenderFns
@@ -932,625 +860,6 @@ menu.install = function (Vue) {
932
860
 
933
861
  /* harmony default export */ var packages_menu = __webpack_exports__["default"] = (menu);
934
862
 
935
- /***/ }),
936
-
937
- /***/ 2:
938
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
939
-
940
- "use strict";
941
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return normalizeComponent; });
942
- /* globals __VUE_SSR_CONTEXT__ */
943
-
944
- // IMPORTANT: Do NOT use ES2015 features in this file (except for modules).
945
- // This module is a runtime utility for cleaner component module output and will
946
- // be included in the final webpack user bundle.
947
-
948
- function normalizeComponent(
949
- scriptExports,
950
- render,
951
- staticRenderFns,
952
- functionalTemplate,
953
- injectStyles,
954
- scopeId,
955
- moduleIdentifier /* server only */,
956
- shadowMode /* vue-cli only */
957
- ) {
958
- // Vue.extend constructor export interop
959
- var options =
960
- typeof scriptExports === 'function' ? scriptExports.options : scriptExports
961
-
962
- // render functions
963
- if (render) {
964
- options.render = render
965
- options.staticRenderFns = staticRenderFns
966
- options._compiled = true
967
- }
968
-
969
- // functional template
970
- if (functionalTemplate) {
971
- options.functional = true
972
- }
973
-
974
- // scopedId
975
- if (scopeId) {
976
- options._scopeId = 'data-v-' + scopeId
977
- }
978
-
979
- var hook
980
- if (moduleIdentifier) {
981
- // server build
982
- hook = function (context) {
983
- // 2.3 injection
984
- context =
985
- context || // cached call
986
- (this.$vnode && this.$vnode.ssrContext) || // stateful
987
- (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional
988
- // 2.2 with runInNewContext: true
989
- if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {
990
- context = __VUE_SSR_CONTEXT__
991
- }
992
- // inject component styles
993
- if (injectStyles) {
994
- injectStyles.call(this, context)
995
- }
996
- // register component module identifier for async chunk inferrence
997
- if (context && context._registeredComponents) {
998
- context._registeredComponents.add(moduleIdentifier)
999
- }
1000
- }
1001
- // used by ssr in case component is cached and beforeCreate
1002
- // never gets called
1003
- options._ssrRegister = hook
1004
- } else if (injectStyles) {
1005
- hook = shadowMode
1006
- ? function () {
1007
- injectStyles.call(
1008
- this,
1009
- (options.functional ? this.parent : this).$root.$options.shadowRoot
1010
- )
1011
- }
1012
- : injectStyles
1013
- }
1014
-
1015
- if (hook) {
1016
- if (options.functional) {
1017
- // for template-only hot-reload because in that case the render fn doesn't
1018
- // go through the normalizer
1019
- options._injectStyles = hook
1020
- // register for functional component in vue file
1021
- var originalRender = options.render
1022
- options.render = function renderWithStyleInjection(h, context) {
1023
- hook.call(context)
1024
- return originalRender(h, context)
1025
- }
1026
- } else {
1027
- // inject component registration as beforeCreate hook
1028
- var existing = options.beforeCreate
1029
- options.beforeCreate = existing ? [].concat(existing, hook) : [hook]
1030
- }
1031
- }
1032
-
1033
- return {
1034
- exports: scriptExports,
1035
- options: options
1036
- }
1037
- }
1038
-
1039
-
1040
- /***/ }),
1041
-
1042
- /***/ 3:
1043
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
1044
-
1045
- "use strict";
1046
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "r", function() { return noop; });
1047
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "j", function() { return hasOwn; });
1048
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "t", function() { return toObject; });
1049
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "i", function() { return getValueByPath; });
1050
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "h", function() { return getPropByPath; });
1051
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "g", function() { return generateId; });
1052
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "u", function() { return valueEquals; });
1053
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return escapeRegexpString; });
1054
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return arrayFindIndex; });
1055
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return arrayFind; });
1056
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return coerceTruthyValueToArray; });
1057
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "o", function() { return isIE; });
1058
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "k", function() { return isEdge; });
1059
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "n", function() { return isFirefox; });
1060
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return autoprefixer; });
1061
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "q", function() { return kebabCase; });
1062
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return capitalize; });
1063
- /* unused harmony export looseEqual */
1064
- /* unused harmony export arrayEquals */
1065
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "m", function() { return isEqual; });
1066
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "l", function() { return isEmpty; });
1067
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "s", function() { return rafThrottle; });
1068
- /* unused harmony export objToArray */
1069
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "p", function() { return isMac; });
1070
- /* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
1071
- /* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(vue__WEBPACK_IMPORTED_MODULE_0__);
1072
- /* harmony import */ var _types__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4);
1073
- var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
1074
-
1075
-
1076
-
1077
-
1078
- var hasOwnProperty = Object.prototype.hasOwnProperty;
1079
-
1080
- function noop() {};
1081
-
1082
- function hasOwn(obj, key) {
1083
- return hasOwnProperty.call(obj, key);
1084
- };
1085
-
1086
- function extend(to, _from) {
1087
- for (var key in _from) {
1088
- to[key] = _from[key];
1089
- }
1090
- return to;
1091
- };
1092
-
1093
- function toObject(arr) {
1094
- var res = {};
1095
- for (var i = 0; i < arr.length; i++) {
1096
- if (arr[i]) {
1097
- extend(res, arr[i]);
1098
- }
1099
- }
1100
- return res;
1101
- };
1102
-
1103
- var getValueByPath = function getValueByPath(object, prop) {
1104
- prop = prop || '';
1105
- var paths = prop.split('.');
1106
- var current = object;
1107
- var result = null;
1108
- for (var i = 0, j = paths.length; i < j; i++) {
1109
- var path = paths[i];
1110
- if (!current) break;
1111
-
1112
- if (i === j - 1) {
1113
- result = current[path];
1114
- break;
1115
- }
1116
- current = current[path];
1117
- }
1118
- return result;
1119
- };
1120
-
1121
- function getPropByPath(obj, path, strict) {
1122
- var tempObj = obj;
1123
- path = path.replace(/\[(\w+)\]/g, '.$1');
1124
- path = path.replace(/^\./, '');
1125
-
1126
- var keyArr = path.split('.');
1127
- var i = 0;
1128
- for (var len = keyArr.length; i < len - 1; ++i) {
1129
- if (!tempObj && !strict) break;
1130
- var key = keyArr[i];
1131
- if (key in tempObj) {
1132
- tempObj = tempObj[key];
1133
- } else {
1134
- if (strict) {
1135
- throw new Error('please transfer a valid prop path to form item!');
1136
- }
1137
- break;
1138
- }
1139
- }
1140
- return {
1141
- o: tempObj,
1142
- k: keyArr[i],
1143
- v: tempObj ? tempObj[keyArr[i]] : null
1144
- };
1145
- };
1146
-
1147
- var generateId = function generateId() {
1148
- return Math.floor(Math.random() * 10000);
1149
- };
1150
-
1151
- var valueEquals = function valueEquals(a, b) {
1152
- // see: https://stackoverflow.com/questions/3115982/how-to-check-if-two-arrays-are-equal-with-javascript
1153
- if (a === b) return true;
1154
- if (!(a instanceof Array)) return false;
1155
- if (!(b instanceof Array)) return false;
1156
- if (a.length !== b.length) return false;
1157
- for (var i = 0; i !== a.length; ++i) {
1158
- if (a[i] !== b[i]) return false;
1159
- }
1160
- return true;
1161
- };
1162
-
1163
- var escapeRegexpString = function escapeRegexpString() {
1164
- var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
1165
- return String(value).replace(/[|\\{}()[\]^$+*?.]/g, '\\$&');
1166
- };
1167
-
1168
- // TODO: use native Array.find, Array.findIndex when IE support is dropped
1169
- var arrayFindIndex = function arrayFindIndex(arr, pred) {
1170
- for (var i = 0; i !== arr.length; ++i) {
1171
- if (pred(arr[i])) {
1172
- return i;
1173
- }
1174
- }
1175
- return -1;
1176
- };
1177
-
1178
- var arrayFind = function arrayFind(arr, pred) {
1179
- var idx = arrayFindIndex(arr, pred);
1180
- return idx !== -1 ? arr[idx] : undefined;
1181
- };
1182
-
1183
- // coerce truthy value to array
1184
- var coerceTruthyValueToArray = function coerceTruthyValueToArray(val) {
1185
- if (Array.isArray(val)) {
1186
- return val;
1187
- } else if (val) {
1188
- return [val];
1189
- } else {
1190
- return [];
1191
- }
1192
- };
1193
-
1194
- var isIE = function isIE() {
1195
- return !vue__WEBPACK_IMPORTED_MODULE_0___default.a.prototype.$isServer && !isNaN(Number(document.documentMode));
1196
- };
1197
-
1198
- var isEdge = function isEdge() {
1199
- return !vue__WEBPACK_IMPORTED_MODULE_0___default.a.prototype.$isServer && navigator.userAgent.indexOf('Edge') > -1;
1200
- };
1201
-
1202
- var isFirefox = function isFirefox() {
1203
- return !vue__WEBPACK_IMPORTED_MODULE_0___default.a.prototype.$isServer && !!window.navigator.userAgent.match(/firefox/i);
1204
- };
1205
-
1206
- var autoprefixer = function autoprefixer(style) {
1207
- if ((typeof style === 'undefined' ? 'undefined' : _typeof(style)) !== 'object') return style;
1208
- var rules = ['transform', 'transition', 'animation'];
1209
- var prefixes = ['ms-', 'webkit-'];
1210
- rules.forEach(function (rule) {
1211
- var value = style[rule];
1212
- if (rule && value) {
1213
- prefixes.forEach(function (prefix) {
1214
- style[prefix + rule] = value;
1215
- });
1216
- }
1217
- });
1218
- return style;
1219
- };
1220
-
1221
- var kebabCase = function kebabCase(str) {
1222
- var hyphenateRE = /([^-])([A-Z])/g;
1223
- return str.replace(hyphenateRE, '$1-$2').replace(hyphenateRE, '$1-$2').toLowerCase();
1224
- };
1225
-
1226
- var capitalize = function capitalize(str) {
1227
- if (!Object(_types__WEBPACK_IMPORTED_MODULE_1__[/* isString */ "e"])(str)) return str;
1228
- return str.charAt(0).toUpperCase() + str.slice(1);
1229
- };
1230
-
1231
- var looseEqual = function looseEqual(a, b) {
1232
- var isObjectA = Object(_types__WEBPACK_IMPORTED_MODULE_1__[/* isObject */ "d"])(a);
1233
- var isObjectB = Object(_types__WEBPACK_IMPORTED_MODULE_1__[/* isObject */ "d"])(b);
1234
- if (isObjectA && isObjectB) {
1235
- return JSON.stringify(a) === JSON.stringify(b);
1236
- } else if (!isObjectA && !isObjectB) {
1237
- return String(a) === String(b);
1238
- } else {
1239
- return false;
1240
- }
1241
- };
1242
-
1243
- var arrayEquals = function arrayEquals(arrayA, arrayB) {
1244
- arrayA = arrayA || [];
1245
- arrayB = arrayB || [];
1246
-
1247
- if (arrayA.length !== arrayB.length) {
1248
- return false;
1249
- }
1250
-
1251
- for (var i = 0; i < arrayA.length; i++) {
1252
- if (!looseEqual(arrayA[i], arrayB[i])) {
1253
- return false;
1254
- }
1255
- }
1256
-
1257
- return true;
1258
- };
1259
-
1260
- var isEqual = function isEqual(value1, value2) {
1261
- if (Array.isArray(value1) && Array.isArray(value2)) {
1262
- return arrayEquals(value1, value2);
1263
- }
1264
- return looseEqual(value1, value2);
1265
- };
1266
-
1267
- var isEmpty = function isEmpty(val) {
1268
- // null or undefined
1269
- if (val == null) return true;
1270
-
1271
- if (typeof val === 'boolean') return false;
1272
-
1273
- if (typeof val === 'number') return !val;
1274
-
1275
- if (val instanceof Error) return val.message === '';
1276
-
1277
- switch (Object.prototype.toString.call(val)) {
1278
- // String or Array
1279
- case '[object String]':
1280
- case '[object Array]':
1281
- return !val.length;
1282
-
1283
- // Map or Set or File
1284
- case '[object File]':
1285
- case '[object Map]':
1286
- case '[object Set]':
1287
- {
1288
- return !val.size;
1289
- }
1290
- // Plain Object
1291
- case '[object Object]':
1292
- {
1293
- return !Object.keys(val).length;
1294
- }
1295
- }
1296
-
1297
- return false;
1298
- };
1299
-
1300
- function rafThrottle(fn) {
1301
- var locked = false;
1302
- return function () {
1303
- var _this = this;
1304
-
1305
- for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
1306
- args[_key] = arguments[_key];
1307
- }
1308
-
1309
- if (locked) return;
1310
- locked = true;
1311
- window.requestAnimationFrame(function (_) {
1312
- fn.apply(_this, args);
1313
- locked = false;
1314
- });
1315
- };
1316
- }
1317
-
1318
- function objToArray(obj) {
1319
- if (Array.isArray(obj)) {
1320
- return obj;
1321
- }
1322
- return isEmpty(obj) ? [] : [obj];
1323
- }
1324
-
1325
- var isMac = function isMac() {
1326
- return !vue__WEBPACK_IMPORTED_MODULE_0___default.a.prototype.$isServer && /macintosh|mac os x/i.test(navigator.userAgent);
1327
- };
1328
-
1329
- /***/ }),
1330
-
1331
- /***/ 30:
1332
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
1333
-
1334
- "use strict";
1335
- var aria = aria || {};
1336
-
1337
- aria.Utils = aria.Utils || {};
1338
-
1339
- /**
1340
- * @desc Set focus on descendant nodes until the first focusable element is
1341
- * found.
1342
- * @param element
1343
- * DOM node for which to find the first focusable descendant.
1344
- * @returns
1345
- * true if a focusable element is found and focus is set.
1346
- */
1347
- aria.Utils.focusFirstDescendant = function (element) {
1348
- for (var i = 0; i < element.childNodes.length; i++) {
1349
- var child = element.childNodes[i];
1350
- if (aria.Utils.attemptFocus(child) || aria.Utils.focusFirstDescendant(child)) {
1351
- return true;
1352
- }
1353
- }
1354
- return false;
1355
- };
1356
-
1357
- /**
1358
- * @desc Find the last descendant node that is focusable.
1359
- * @param element
1360
- * DOM node for which to find the last focusable descendant.
1361
- * @returns
1362
- * true if a focusable element is found and focus is set.
1363
- */
1364
-
1365
- aria.Utils.focusLastDescendant = function (element) {
1366
- for (var i = element.childNodes.length - 1; i >= 0; i--) {
1367
- var child = element.childNodes[i];
1368
- if (aria.Utils.attemptFocus(child) || aria.Utils.focusLastDescendant(child)) {
1369
- return true;
1370
- }
1371
- }
1372
- return false;
1373
- };
1374
-
1375
- /**
1376
- * @desc Set Attempt to set focus on the current node.
1377
- * @param element
1378
- * The node to attempt to focus on.
1379
- * @returns
1380
- * true if element is focused.
1381
- */
1382
- aria.Utils.attemptFocus = function (element) {
1383
- if (!aria.Utils.isFocusable(element)) {
1384
- return false;
1385
- }
1386
- aria.Utils.IgnoreUtilFocusChanges = true;
1387
- try {
1388
- element.focus();
1389
- } catch (e) {}
1390
- aria.Utils.IgnoreUtilFocusChanges = false;
1391
- return document.activeElement === element;
1392
- };
1393
-
1394
- aria.Utils.isFocusable = function (element) {
1395
- if (element.tabIndex > 0 || element.tabIndex === 0 && element.getAttribute('tabIndex') !== null) {
1396
- return true;
1397
- }
1398
-
1399
- if (element.disabled) {
1400
- return false;
1401
- }
1402
-
1403
- switch (element.nodeName) {
1404
- case 'A':
1405
- return !!element.href && element.rel !== 'ignore';
1406
- case 'INPUT':
1407
- return element.type !== 'hidden' && element.type !== 'file';
1408
- case 'BUTTON':
1409
- case 'SELECT':
1410
- case 'TEXTAREA':
1411
- return true;
1412
- default:
1413
- return false;
1414
- }
1415
- };
1416
-
1417
- /**
1418
- * 触发一个事件
1419
- * mouseenter, mouseleave, mouseover, keyup, change, click 等
1420
- * @param {Element} elm
1421
- * @param {String} name
1422
- * @param {*} opts
1423
- */
1424
- aria.Utils.triggerEvent = function (elm, name) {
1425
- var eventName = void 0;
1426
-
1427
- if (/^mouse|click/.test(name)) {
1428
- eventName = 'MouseEvents';
1429
- } else if (/^key/.test(name)) {
1430
- eventName = 'KeyboardEvent';
1431
- } else {
1432
- eventName = 'HTMLEvents';
1433
- }
1434
- var evt = document.createEvent(eventName);
1435
-
1436
- for (var _len = arguments.length, opts = Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) {
1437
- opts[_key - 2] = arguments[_key];
1438
- }
1439
-
1440
- evt.initEvent.apply(evt, [name].concat(opts));
1441
- elm.dispatchEvent ? elm.dispatchEvent(evt) : elm.fireEvent('on' + name, evt);
1442
-
1443
- return elm;
1444
- };
1445
-
1446
- aria.Utils.keys = {
1447
- tab: 9,
1448
- enter: 13,
1449
- space: 32,
1450
- left: 37,
1451
- up: 38,
1452
- right: 39,
1453
- down: 40,
1454
- esc: 27
1455
- };
1456
-
1457
- /* harmony default export */ __webpack_exports__["a"] = (aria.Utils);
1458
-
1459
- /***/ }),
1460
-
1461
- /***/ 4:
1462
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
1463
-
1464
- "use strict";
1465
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return isString; });
1466
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return isObject; });
1467
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return isHtmlElement; });
1468
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return isFunction; });
1469
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return isUndefined; });
1470
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return isDefined; });
1471
- /* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
1472
- /* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(vue__WEBPACK_IMPORTED_MODULE_0__);
1473
- var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
1474
-
1475
-
1476
-
1477
- function isString(obj) {
1478
- return Object.prototype.toString.call(obj) === '[object String]';
1479
- }
1480
-
1481
- function isObject(obj) {
1482
- return Object.prototype.toString.call(obj) === '[object Object]';
1483
- }
1484
-
1485
- function isHtmlElement(node) {
1486
- return node && node.nodeType === Node.ELEMENT_NODE;
1487
- }
1488
-
1489
- /**
1490
- * - Inspired:
1491
- * https://github.com/jashkenas/underscore/blob/master/modules/isFunction.js
1492
- */
1493
- var isFunction = function isFunction(functionToCheck) {
1494
- var getType = {};
1495
- return functionToCheck && getType.toString.call(functionToCheck) === '[object Function]';
1496
- };
1497
-
1498
- if ( true && (typeof Int8Array === 'undefined' ? 'undefined' : _typeof(Int8Array)) !== 'object' && (vue__WEBPACK_IMPORTED_MODULE_0___default.a.prototype.$isServer || typeof document.childNodes !== 'function')) {
1499
- isFunction = function isFunction(obj) {
1500
- return typeof obj === 'function' || false;
1501
- };
1502
- }
1503
-
1504
-
1505
-
1506
- var isUndefined = function isUndefined(val) {
1507
- return val === void 0;
1508
- };
1509
-
1510
- var isDefined = function isDefined(val) {
1511
- return val !== undefined && val !== null;
1512
- };
1513
-
1514
- /***/ }),
1515
-
1516
- /***/ 6:
1517
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
1518
-
1519
- "use strict";
1520
- function _broadcast(componentName, eventName, params) {
1521
- this.$children.forEach(function (child) {
1522
- var name = child.$options.componentName;
1523
-
1524
- if (name === componentName) {
1525
- child.$emit.apply(child, [eventName].concat(params));
1526
- } else {
1527
- _broadcast.apply(child, [componentName, eventName].concat([params]));
1528
- }
1529
- });
1530
- }
1531
- /* harmony default export */ __webpack_exports__["a"] = ({
1532
- methods: {
1533
- dispatch: function dispatch(componentName, eventName, params) {
1534
- var parent = this.$parent || this.$root;
1535
- var name = parent.$options.componentName;
1536
-
1537
- while (parent && (!name || name !== componentName)) {
1538
- parent = parent.$parent;
1539
-
1540
- if (parent) {
1541
- name = parent.$options.componentName;
1542
- }
1543
- }
1544
- if (parent) {
1545
- parent.$emit.apply(parent, [eventName].concat(params));
1546
- }
1547
- },
1548
- broadcast: function broadcast(componentName, eventName, params) {
1549
- _broadcast.call(this, componentName, eventName, params);
1550
- }
1551
- }
1552
- });
1553
-
1554
863
  /***/ })
1555
864
 
1556
865
  /******/ });