bootstrap-table-rails 1.12.2 → 1.16.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/README.md +83 -77
- data/lib/bootstrap-table-rails/version.rb +1 -1
- data/vendor/assets/javascripts/bootstrap-table/bootstrap-table-locale-all.js +5420 -2066
- data/vendor/assets/javascripts/bootstrap-table/bootstrap-table-vue.esm.js +2279 -0
- data/vendor/assets/javascripts/bootstrap-table/bootstrap-table-vue.js +2287 -0
- data/vendor/assets/javascripts/bootstrap-table/bootstrap-table.css +238 -204
- data/vendor/assets/javascripts/bootstrap-table/bootstrap-table.js +7212 -3295
- data/vendor/assets/javascripts/bootstrap-table/extensions/accent-neutralise/bootstrap-table-accent-neutralise.js +2647 -182
- data/vendor/assets/javascripts/bootstrap-table/extensions/addrbar/bootstrap-table-addrbar.js +1631 -0
- data/vendor/assets/javascripts/bootstrap-table/extensions/auto-refresh/bootstrap-table-auto-refresh.js +1092 -84
- data/vendor/assets/javascripts/bootstrap-table/extensions/cell-input/bootstrap-table-cell-input.css +12 -0
- data/vendor/assets/javascripts/bootstrap-table/extensions/cell-input/bootstrap-table-cell-input.js +2248 -0
- data/vendor/assets/javascripts/bootstrap-table/extensions/cookie/bootstrap-table-cookie.js +2226 -413
- data/vendor/assets/javascripts/bootstrap-table/extensions/copy-rows/bootstrap-table-copy-rows.js +1114 -102
- data/vendor/assets/javascripts/bootstrap-table/extensions/defer-url/bootstrap-table-defer-url.js +820 -32
- data/vendor/assets/javascripts/bootstrap-table/extensions/editable/bootstrap-table-editable.js +1619 -146
- data/vendor/assets/javascripts/bootstrap-table/extensions/export/bootstrap-table-export.js +2668 -179
- data/vendor/assets/javascripts/bootstrap-table/extensions/filter-control/bootstrap-table-filter-control.css +4 -4
- data/vendor/assets/javascripts/bootstrap-table/extensions/filter-control/bootstrap-table-filter-control.js +2831 -744
- data/vendor/assets/javascripts/bootstrap-table/extensions/fixed-columns/bootstrap-table-fixed-columns.css +25 -0
- data/vendor/assets/javascripts/bootstrap-table/extensions/fixed-columns/bootstrap-table-fixed-columns.js +1501 -0
- data/vendor/assets/javascripts/bootstrap-table/extensions/group-by-v2/bootstrap-table-group-by.css +2 -6
- data/vendor/assets/javascripts/bootstrap-table/extensions/group-by-v2/bootstrap-table-group-by.js +1874 -226
- data/vendor/assets/javascripts/bootstrap-table/extensions/i18n-enhance/bootstrap-table-i18n-enhance.js +120 -30
- data/vendor/assets/javascripts/bootstrap-table/extensions/key-events/bootstrap-table-key-events.js +1387 -80
- data/vendor/assets/javascripts/bootstrap-table/extensions/mobile/bootstrap-table-mobile.js +1239 -136
- data/vendor/assets/javascripts/bootstrap-table/extensions/multiple-sort/bootstrap-table-multiple-sort.js +2113 -412
- data/vendor/assets/javascripts/bootstrap-table/extensions/page-jump-to/bootstrap-table-page-jump-to.css +11 -0
- data/vendor/assets/javascripts/bootstrap-table/extensions/page-jump-to/bootstrap-table-page-jump-to.js +1043 -0
- data/vendor/assets/javascripts/bootstrap-table/extensions/pipeline/bootstrap-table-pipeline.js +1173 -0
- data/vendor/assets/javascripts/bootstrap-table/extensions/print/bootstrap-table-print.js +2055 -149
- data/vendor/assets/javascripts/bootstrap-table/extensions/reorder-columns/bootstrap-table-reorder-columns.js +1401 -181
- data/vendor/assets/javascripts/bootstrap-table/extensions/reorder-rows/bootstrap-table-reorder-rows.css +10 -10
- data/vendor/assets/javascripts/bootstrap-table/extensions/reorder-rows/bootstrap-table-reorder-rows.js +986 -118
- data/vendor/assets/javascripts/bootstrap-table/extensions/resizable/bootstrap-table-resizable.js +716 -75
- data/vendor/assets/javascripts/bootstrap-table/extensions/sticky-header/bootstrap-table-sticky-header.css +13 -14
- data/vendor/assets/javascripts/bootstrap-table/extensions/sticky-header/bootstrap-table-sticky-header.js +1151 -118
- data/vendor/assets/javascripts/bootstrap-table/extensions/toolbar/bootstrap-table-toolbar.js +2547 -211
- data/vendor/assets/javascripts/bootstrap-table/extensions/treegrid/bootstrap-table-treegrid.js +1910 -109
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-af-ZA.js +762 -40
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-ar-SA.js +763 -40
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-ca-ES.js +763 -44
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-cs-CZ.js +763 -44
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-da-DK.js +762 -37
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-de-DE.js +762 -52
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-el-GR.js +762 -28
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-en-US.js +762 -49
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-es-AR.js +763 -31
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-es-CL.js +763 -44
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-es-CR.js +762 -40
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-es-ES.js +762 -43
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-es-MX.js +764 -51
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-es-NI.js +762 -40
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-es-SP.js +762 -40
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-et-EE.js +762 -43
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-eu-EU.js +762 -43
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-fa-IR.js +762 -43
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-fi-FI.js +762 -0
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-fr-BE.js +763 -28
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-fr-CH.js +762 -0
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-fr-FR.js +764 -95
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-fr-LU.js +762 -0
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-he-IL.js +762 -43
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-hr-HR.js +763 -44
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-hu-HU.js +762 -43
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-id-ID.js +762 -49
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-it-IT.js +764 -52
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-ja-JP.js +762 -43
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-ka-GE.js +762 -40
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-ko-KR.js +762 -37
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-ms-MY.js +762 -43
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-nb-NO.js +762 -37
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-nl-BE.js +762 -0
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-nl-NL.js +763 -52
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-pl-PL.js +762 -37
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-pt-BR.js +764 -41
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-pt-PT.js +762 -43
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-ro-RO.js +762 -43
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-ru-RU.js +762 -72
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-sk-SK.js +762 -49
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-sr-Cyrl-RS.js +762 -0
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-sr-Latn-RS.js +762 -0
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-sv-SE.js +762 -37
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-th-TH.js +762 -37
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-tr-TR.js +763 -41
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-uk-UA.js +762 -73
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-ur-PK.js +762 -37
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-uz-Latn-UZ.js +762 -49
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-vi-VN.js +762 -28
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-zh-CN.js +762 -46
- data/vendor/assets/javascripts/bootstrap-table/locale/bootstrap-table-zh-TW.js +762 -40
- data/vendor/assets/javascripts/bootstrap-table/themes/bulma/bootstrap-table-bulma.css +421 -0
- data/vendor/assets/javascripts/bootstrap-table/themes/bulma/bootstrap-table-bulma.js +989 -0
- data/vendor/assets/javascripts/bootstrap-table/themes/foundation/bootstrap-table-foundation.css +395 -0
- data/vendor/assets/javascripts/bootstrap-table/themes/foundation/bootstrap-table-foundation.js +999 -0
- data/vendor/assets/javascripts/bootstrap-table/themes/materialize/bootstrap-table-materialize.css +391 -0
- data/vendor/assets/javascripts/bootstrap-table/themes/materialize/bootstrap-table-materialize.js +992 -0
- data/vendor/assets/javascripts/bootstrap-table/themes/semantic/bootstrap-table-semantic.css +403 -0
- data/vendor/assets/javascripts/bootstrap-table/themes/semantic/bootstrap-table-semantic.js +966 -0
- metadata +30 -25
- data/vendor/assets/javascripts/bootstrap-table/extensions/angular/bootstrap-table-angular.js +0 -107
- data/vendor/assets/javascripts/bootstrap-table/extensions/auto-refresh/bootstrap-table-auto-refresh.css +0 -3
- data/vendor/assets/javascripts/bootstrap-table/extensions/click-edit-row/bootstrap-table-click-edit-row.css +0 -21
- data/vendor/assets/javascripts/bootstrap-table/extensions/click-edit-row/bootstrap-table-click-edit-row.js +0 -142
- data/vendor/assets/javascripts/bootstrap-table/extensions/filter/bootstrap-table-filter.js +0 -67
- data/vendor/assets/javascripts/bootstrap-table/extensions/flat-json/bootstrap-table-flat-json.js +0 -62
- data/vendor/assets/javascripts/bootstrap-table/extensions/group-by/bootstrap-table-group-by.css +0 -53
- data/vendor/assets/javascripts/bootstrap-table/extensions/group-by/bootstrap-table-group-by.js +0 -243
- data/vendor/assets/javascripts/bootstrap-table/extensions/multi-column-toggle/bootstrap-table-multi-toggle.js +0 -88
- data/vendor/assets/javascripts/bootstrap-table/extensions/multiple-search/bootstrap-table-multiple-search.js +0 -71
- data/vendor/assets/javascripts/bootstrap-table/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.css +0 -17
- data/vendor/assets/javascripts/bootstrap-table/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.js +0 -127
- data/vendor/assets/javascripts/bootstrap-table/extensions/natural-sorting/bootstrap-table-natural-sorting.js +0 -67
- data/vendor/assets/javascripts/bootstrap-table/extensions/page-jumpto/bootstrap-table-jumpto.css +0 -8
- data/vendor/assets/javascripts/bootstrap-table/extensions/page-jumpto/bootstrap-table-jumpto.js +0 -50
- data/vendor/assets/javascripts/bootstrap-table/extensions/select2-filter/bootstrap-table-select2-filter.js +0 -332
- data/vendor/assets/javascripts/bootstrap-table/extensions/tree-column/bootstrap-table-tree-column.css +0 -1
- data/vendor/assets/javascripts/bootstrap-table/extensions/tree-column/bootstrap-table-tree-column.js +0 -130
@@ -0,0 +1,2287 @@
|
|
1
|
+
(function (global, factory) {
|
2
|
+
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
3
|
+
typeof define === 'function' && define.amd ? define(factory) :
|
4
|
+
(global = global || self, global.BootstrapTable = factory());
|
5
|
+
}(this, (function () { 'use strict';
|
6
|
+
|
7
|
+
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
8
|
+
|
9
|
+
function createCommonjsModule(fn, module) {
|
10
|
+
return module = { exports: {} }, fn(module, module.exports), module.exports;
|
11
|
+
}
|
12
|
+
|
13
|
+
var check = function (it) {
|
14
|
+
return it && it.Math == Math && it;
|
15
|
+
};
|
16
|
+
|
17
|
+
// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
|
18
|
+
var global_1 =
|
19
|
+
// eslint-disable-next-line no-undef
|
20
|
+
check(typeof globalThis == 'object' && globalThis) ||
|
21
|
+
check(typeof window == 'object' && window) ||
|
22
|
+
check(typeof self == 'object' && self) ||
|
23
|
+
check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
|
24
|
+
// eslint-disable-next-line no-new-func
|
25
|
+
Function('return this')();
|
26
|
+
|
27
|
+
var fails = function (exec) {
|
28
|
+
try {
|
29
|
+
return !!exec();
|
30
|
+
} catch (error) {
|
31
|
+
return true;
|
32
|
+
}
|
33
|
+
};
|
34
|
+
|
35
|
+
// Thank's IE8 for his funny defineProperty
|
36
|
+
var descriptors = !fails(function () {
|
37
|
+
return Object.defineProperty({}, 'a', { get: function () { return 7; } }).a != 7;
|
38
|
+
});
|
39
|
+
|
40
|
+
var nativePropertyIsEnumerable = {}.propertyIsEnumerable;
|
41
|
+
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
42
|
+
|
43
|
+
// Nashorn ~ JDK8 bug
|
44
|
+
var NASHORN_BUG = getOwnPropertyDescriptor && !nativePropertyIsEnumerable.call({ 1: 2 }, 1);
|
45
|
+
|
46
|
+
// `Object.prototype.propertyIsEnumerable` method implementation
|
47
|
+
// https://tc39.github.io/ecma262/#sec-object.prototype.propertyisenumerable
|
48
|
+
var f = NASHORN_BUG ? function propertyIsEnumerable(V) {
|
49
|
+
var descriptor = getOwnPropertyDescriptor(this, V);
|
50
|
+
return !!descriptor && descriptor.enumerable;
|
51
|
+
} : nativePropertyIsEnumerable;
|
52
|
+
|
53
|
+
var objectPropertyIsEnumerable = {
|
54
|
+
f: f
|
55
|
+
};
|
56
|
+
|
57
|
+
var createPropertyDescriptor = function (bitmap, value) {
|
58
|
+
return {
|
59
|
+
enumerable: !(bitmap & 1),
|
60
|
+
configurable: !(bitmap & 2),
|
61
|
+
writable: !(bitmap & 4),
|
62
|
+
value: value
|
63
|
+
};
|
64
|
+
};
|
65
|
+
|
66
|
+
var toString = {}.toString;
|
67
|
+
|
68
|
+
var classofRaw = function (it) {
|
69
|
+
return toString.call(it).slice(8, -1);
|
70
|
+
};
|
71
|
+
|
72
|
+
var split = ''.split;
|
73
|
+
|
74
|
+
// fallback for non-array-like ES3 and non-enumerable old V8 strings
|
75
|
+
var indexedObject = fails(function () {
|
76
|
+
// throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
|
77
|
+
// eslint-disable-next-line no-prototype-builtins
|
78
|
+
return !Object('z').propertyIsEnumerable(0);
|
79
|
+
}) ? function (it) {
|
80
|
+
return classofRaw(it) == 'String' ? split.call(it, '') : Object(it);
|
81
|
+
} : Object;
|
82
|
+
|
83
|
+
// `RequireObjectCoercible` abstract operation
|
84
|
+
// https://tc39.github.io/ecma262/#sec-requireobjectcoercible
|
85
|
+
var requireObjectCoercible = function (it) {
|
86
|
+
if (it == undefined) throw TypeError("Can't call method on " + it);
|
87
|
+
return it;
|
88
|
+
};
|
89
|
+
|
90
|
+
// toObject with fallback for non-array-like ES3 strings
|
91
|
+
|
92
|
+
|
93
|
+
|
94
|
+
var toIndexedObject = function (it) {
|
95
|
+
return indexedObject(requireObjectCoercible(it));
|
96
|
+
};
|
97
|
+
|
98
|
+
var isObject = function (it) {
|
99
|
+
return typeof it === 'object' ? it !== null : typeof it === 'function';
|
100
|
+
};
|
101
|
+
|
102
|
+
// `ToPrimitive` abstract operation
|
103
|
+
// https://tc39.github.io/ecma262/#sec-toprimitive
|
104
|
+
// instead of the ES6 spec version, we didn't implement @@toPrimitive case
|
105
|
+
// and the second argument - flag - preferred type is a string
|
106
|
+
var toPrimitive = function (input, PREFERRED_STRING) {
|
107
|
+
if (!isObject(input)) return input;
|
108
|
+
var fn, val;
|
109
|
+
if (PREFERRED_STRING && typeof (fn = input.toString) == 'function' && !isObject(val = fn.call(input))) return val;
|
110
|
+
if (typeof (fn = input.valueOf) == 'function' && !isObject(val = fn.call(input))) return val;
|
111
|
+
if (!PREFERRED_STRING && typeof (fn = input.toString) == 'function' && !isObject(val = fn.call(input))) return val;
|
112
|
+
throw TypeError("Can't convert object to primitive value");
|
113
|
+
};
|
114
|
+
|
115
|
+
var hasOwnProperty = {}.hasOwnProperty;
|
116
|
+
|
117
|
+
var has = function (it, key) {
|
118
|
+
return hasOwnProperty.call(it, key);
|
119
|
+
};
|
120
|
+
|
121
|
+
var document$1 = global_1.document;
|
122
|
+
// typeof document.createElement is 'object' in old IE
|
123
|
+
var EXISTS = isObject(document$1) && isObject(document$1.createElement);
|
124
|
+
|
125
|
+
var documentCreateElement = function (it) {
|
126
|
+
return EXISTS ? document$1.createElement(it) : {};
|
127
|
+
};
|
128
|
+
|
129
|
+
// Thank's IE8 for his funny defineProperty
|
130
|
+
var ie8DomDefine = !descriptors && !fails(function () {
|
131
|
+
return Object.defineProperty(documentCreateElement('div'), 'a', {
|
132
|
+
get: function () { return 7; }
|
133
|
+
}).a != 7;
|
134
|
+
});
|
135
|
+
|
136
|
+
var nativeGetOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
137
|
+
|
138
|
+
// `Object.getOwnPropertyDescriptor` method
|
139
|
+
// https://tc39.github.io/ecma262/#sec-object.getownpropertydescriptor
|
140
|
+
var f$1 = descriptors ? nativeGetOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {
|
141
|
+
O = toIndexedObject(O);
|
142
|
+
P = toPrimitive(P, true);
|
143
|
+
if (ie8DomDefine) try {
|
144
|
+
return nativeGetOwnPropertyDescriptor(O, P);
|
145
|
+
} catch (error) { /* empty */ }
|
146
|
+
if (has(O, P)) return createPropertyDescriptor(!objectPropertyIsEnumerable.f.call(O, P), O[P]);
|
147
|
+
};
|
148
|
+
|
149
|
+
var objectGetOwnPropertyDescriptor = {
|
150
|
+
f: f$1
|
151
|
+
};
|
152
|
+
|
153
|
+
var anObject = function (it) {
|
154
|
+
if (!isObject(it)) {
|
155
|
+
throw TypeError(String(it) + ' is not an object');
|
156
|
+
} return it;
|
157
|
+
};
|
158
|
+
|
159
|
+
var nativeDefineProperty = Object.defineProperty;
|
160
|
+
|
161
|
+
// `Object.defineProperty` method
|
162
|
+
// https://tc39.github.io/ecma262/#sec-object.defineproperty
|
163
|
+
var f$2 = descriptors ? nativeDefineProperty : function defineProperty(O, P, Attributes) {
|
164
|
+
anObject(O);
|
165
|
+
P = toPrimitive(P, true);
|
166
|
+
anObject(Attributes);
|
167
|
+
if (ie8DomDefine) try {
|
168
|
+
return nativeDefineProperty(O, P, Attributes);
|
169
|
+
} catch (error) { /* empty */ }
|
170
|
+
if ('get' in Attributes || 'set' in Attributes) throw TypeError('Accessors not supported');
|
171
|
+
if ('value' in Attributes) O[P] = Attributes.value;
|
172
|
+
return O;
|
173
|
+
};
|
174
|
+
|
175
|
+
var objectDefineProperty = {
|
176
|
+
f: f$2
|
177
|
+
};
|
178
|
+
|
179
|
+
var createNonEnumerableProperty = descriptors ? function (object, key, value) {
|
180
|
+
return objectDefineProperty.f(object, key, createPropertyDescriptor(1, value));
|
181
|
+
} : function (object, key, value) {
|
182
|
+
object[key] = value;
|
183
|
+
return object;
|
184
|
+
};
|
185
|
+
|
186
|
+
var setGlobal = function (key, value) {
|
187
|
+
try {
|
188
|
+
createNonEnumerableProperty(global_1, key, value);
|
189
|
+
} catch (error) {
|
190
|
+
global_1[key] = value;
|
191
|
+
} return value;
|
192
|
+
};
|
193
|
+
|
194
|
+
var SHARED = '__core-js_shared__';
|
195
|
+
var store = global_1[SHARED] || setGlobal(SHARED, {});
|
196
|
+
|
197
|
+
var sharedStore = store;
|
198
|
+
|
199
|
+
var functionToString = Function.toString;
|
200
|
+
|
201
|
+
// this helper broken in `3.4.1-3.4.4`, so we can't use `shared` helper
|
202
|
+
if (typeof sharedStore.inspectSource != 'function') {
|
203
|
+
sharedStore.inspectSource = function (it) {
|
204
|
+
return functionToString.call(it);
|
205
|
+
};
|
206
|
+
}
|
207
|
+
|
208
|
+
var inspectSource = sharedStore.inspectSource;
|
209
|
+
|
210
|
+
var WeakMap = global_1.WeakMap;
|
211
|
+
|
212
|
+
var nativeWeakMap = typeof WeakMap === 'function' && /native code/.test(inspectSource(WeakMap));
|
213
|
+
|
214
|
+
var shared = createCommonjsModule(function (module) {
|
215
|
+
(module.exports = function (key, value) {
|
216
|
+
return sharedStore[key] || (sharedStore[key] = value !== undefined ? value : {});
|
217
|
+
})('versions', []).push({
|
218
|
+
version: '3.6.0',
|
219
|
+
mode: 'global',
|
220
|
+
copyright: '© 2019 Denis Pushkarev (zloirock.ru)'
|
221
|
+
});
|
222
|
+
});
|
223
|
+
|
224
|
+
var id = 0;
|
225
|
+
var postfix = Math.random();
|
226
|
+
|
227
|
+
var uid = function (key) {
|
228
|
+
return 'Symbol(' + String(key === undefined ? '' : key) + ')_' + (++id + postfix).toString(36);
|
229
|
+
};
|
230
|
+
|
231
|
+
var keys = shared('keys');
|
232
|
+
|
233
|
+
var sharedKey = function (key) {
|
234
|
+
return keys[key] || (keys[key] = uid(key));
|
235
|
+
};
|
236
|
+
|
237
|
+
var hiddenKeys = {};
|
238
|
+
|
239
|
+
var WeakMap$1 = global_1.WeakMap;
|
240
|
+
var set, get, has$1;
|
241
|
+
|
242
|
+
var enforce = function (it) {
|
243
|
+
return has$1(it) ? get(it) : set(it, {});
|
244
|
+
};
|
245
|
+
|
246
|
+
var getterFor = function (TYPE) {
|
247
|
+
return function (it) {
|
248
|
+
var state;
|
249
|
+
if (!isObject(it) || (state = get(it)).type !== TYPE) {
|
250
|
+
throw TypeError('Incompatible receiver, ' + TYPE + ' required');
|
251
|
+
} return state;
|
252
|
+
};
|
253
|
+
};
|
254
|
+
|
255
|
+
if (nativeWeakMap) {
|
256
|
+
var store$1 = new WeakMap$1();
|
257
|
+
var wmget = store$1.get;
|
258
|
+
var wmhas = store$1.has;
|
259
|
+
var wmset = store$1.set;
|
260
|
+
set = function (it, metadata) {
|
261
|
+
wmset.call(store$1, it, metadata);
|
262
|
+
return metadata;
|
263
|
+
};
|
264
|
+
get = function (it) {
|
265
|
+
return wmget.call(store$1, it) || {};
|
266
|
+
};
|
267
|
+
has$1 = function (it) {
|
268
|
+
return wmhas.call(store$1, it);
|
269
|
+
};
|
270
|
+
} else {
|
271
|
+
var STATE = sharedKey('state');
|
272
|
+
hiddenKeys[STATE] = true;
|
273
|
+
set = function (it, metadata) {
|
274
|
+
createNonEnumerableProperty(it, STATE, metadata);
|
275
|
+
return metadata;
|
276
|
+
};
|
277
|
+
get = function (it) {
|
278
|
+
return has(it, STATE) ? it[STATE] : {};
|
279
|
+
};
|
280
|
+
has$1 = function (it) {
|
281
|
+
return has(it, STATE);
|
282
|
+
};
|
283
|
+
}
|
284
|
+
|
285
|
+
var internalState = {
|
286
|
+
set: set,
|
287
|
+
get: get,
|
288
|
+
has: has$1,
|
289
|
+
enforce: enforce,
|
290
|
+
getterFor: getterFor
|
291
|
+
};
|
292
|
+
|
293
|
+
var redefine = createCommonjsModule(function (module) {
|
294
|
+
var getInternalState = internalState.get;
|
295
|
+
var enforceInternalState = internalState.enforce;
|
296
|
+
var TEMPLATE = String(String).split('String');
|
297
|
+
|
298
|
+
(module.exports = function (O, key, value, options) {
|
299
|
+
var unsafe = options ? !!options.unsafe : false;
|
300
|
+
var simple = options ? !!options.enumerable : false;
|
301
|
+
var noTargetGet = options ? !!options.noTargetGet : false;
|
302
|
+
if (typeof value == 'function') {
|
303
|
+
if (typeof key == 'string' && !has(value, 'name')) createNonEnumerableProperty(value, 'name', key);
|
304
|
+
enforceInternalState(value).source = TEMPLATE.join(typeof key == 'string' ? key : '');
|
305
|
+
}
|
306
|
+
if (O === global_1) {
|
307
|
+
if (simple) O[key] = value;
|
308
|
+
else setGlobal(key, value);
|
309
|
+
return;
|
310
|
+
} else if (!unsafe) {
|
311
|
+
delete O[key];
|
312
|
+
} else if (!noTargetGet && O[key]) {
|
313
|
+
simple = true;
|
314
|
+
}
|
315
|
+
if (simple) O[key] = value;
|
316
|
+
else createNonEnumerableProperty(O, key, value);
|
317
|
+
// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
|
318
|
+
})(Function.prototype, 'toString', function toString() {
|
319
|
+
return typeof this == 'function' && getInternalState(this).source || inspectSource(this);
|
320
|
+
});
|
321
|
+
});
|
322
|
+
|
323
|
+
var path = global_1;
|
324
|
+
|
325
|
+
var aFunction = function (variable) {
|
326
|
+
return typeof variable == 'function' ? variable : undefined;
|
327
|
+
};
|
328
|
+
|
329
|
+
var getBuiltIn = function (namespace, method) {
|
330
|
+
return arguments.length < 2 ? aFunction(path[namespace]) || aFunction(global_1[namespace])
|
331
|
+
: path[namespace] && path[namespace][method] || global_1[namespace] && global_1[namespace][method];
|
332
|
+
};
|
333
|
+
|
334
|
+
var ceil = Math.ceil;
|
335
|
+
var floor = Math.floor;
|
336
|
+
|
337
|
+
// `ToInteger` abstract operation
|
338
|
+
// https://tc39.github.io/ecma262/#sec-tointeger
|
339
|
+
var toInteger = function (argument) {
|
340
|
+
return isNaN(argument = +argument) ? 0 : (argument > 0 ? floor : ceil)(argument);
|
341
|
+
};
|
342
|
+
|
343
|
+
var min = Math.min;
|
344
|
+
|
345
|
+
// `ToLength` abstract operation
|
346
|
+
// https://tc39.github.io/ecma262/#sec-tolength
|
347
|
+
var toLength = function (argument) {
|
348
|
+
return argument > 0 ? min(toInteger(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991
|
349
|
+
};
|
350
|
+
|
351
|
+
var max = Math.max;
|
352
|
+
var min$1 = Math.min;
|
353
|
+
|
354
|
+
// Helper for a popular repeating case of the spec:
|
355
|
+
// Let integer be ? ToInteger(index).
|
356
|
+
// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).
|
357
|
+
var toAbsoluteIndex = function (index, length) {
|
358
|
+
var integer = toInteger(index);
|
359
|
+
return integer < 0 ? max(integer + length, 0) : min$1(integer, length);
|
360
|
+
};
|
361
|
+
|
362
|
+
// `Array.prototype.{ indexOf, includes }` methods implementation
|
363
|
+
var createMethod = function (IS_INCLUDES) {
|
364
|
+
return function ($this, el, fromIndex) {
|
365
|
+
var O = toIndexedObject($this);
|
366
|
+
var length = toLength(O.length);
|
367
|
+
var index = toAbsoluteIndex(fromIndex, length);
|
368
|
+
var value;
|
369
|
+
// Array#includes uses SameValueZero equality algorithm
|
370
|
+
// eslint-disable-next-line no-self-compare
|
371
|
+
if (IS_INCLUDES && el != el) while (length > index) {
|
372
|
+
value = O[index++];
|
373
|
+
// eslint-disable-next-line no-self-compare
|
374
|
+
if (value != value) return true;
|
375
|
+
// Array#indexOf ignores holes, Array#includes - not
|
376
|
+
} else for (;length > index; index++) {
|
377
|
+
if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;
|
378
|
+
} return !IS_INCLUDES && -1;
|
379
|
+
};
|
380
|
+
};
|
381
|
+
|
382
|
+
var arrayIncludes = {
|
383
|
+
// `Array.prototype.includes` method
|
384
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.includes
|
385
|
+
includes: createMethod(true),
|
386
|
+
// `Array.prototype.indexOf` method
|
387
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.indexof
|
388
|
+
indexOf: createMethod(false)
|
389
|
+
};
|
390
|
+
|
391
|
+
var indexOf = arrayIncludes.indexOf;
|
392
|
+
|
393
|
+
|
394
|
+
var objectKeysInternal = function (object, names) {
|
395
|
+
var O = toIndexedObject(object);
|
396
|
+
var i = 0;
|
397
|
+
var result = [];
|
398
|
+
var key;
|
399
|
+
for (key in O) !has(hiddenKeys, key) && has(O, key) && result.push(key);
|
400
|
+
// Don't enum bug & hidden keys
|
401
|
+
while (names.length > i) if (has(O, key = names[i++])) {
|
402
|
+
~indexOf(result, key) || result.push(key);
|
403
|
+
}
|
404
|
+
return result;
|
405
|
+
};
|
406
|
+
|
407
|
+
// IE8- don't enum bug keys
|
408
|
+
var enumBugKeys = [
|
409
|
+
'constructor',
|
410
|
+
'hasOwnProperty',
|
411
|
+
'isPrototypeOf',
|
412
|
+
'propertyIsEnumerable',
|
413
|
+
'toLocaleString',
|
414
|
+
'toString',
|
415
|
+
'valueOf'
|
416
|
+
];
|
417
|
+
|
418
|
+
var hiddenKeys$1 = enumBugKeys.concat('length', 'prototype');
|
419
|
+
|
420
|
+
// `Object.getOwnPropertyNames` method
|
421
|
+
// https://tc39.github.io/ecma262/#sec-object.getownpropertynames
|
422
|
+
var f$3 = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
|
423
|
+
return objectKeysInternal(O, hiddenKeys$1);
|
424
|
+
};
|
425
|
+
|
426
|
+
var objectGetOwnPropertyNames = {
|
427
|
+
f: f$3
|
428
|
+
};
|
429
|
+
|
430
|
+
var f$4 = Object.getOwnPropertySymbols;
|
431
|
+
|
432
|
+
var objectGetOwnPropertySymbols = {
|
433
|
+
f: f$4
|
434
|
+
};
|
435
|
+
|
436
|
+
// all object keys, includes non-enumerable and symbols
|
437
|
+
var ownKeys = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) {
|
438
|
+
var keys = objectGetOwnPropertyNames.f(anObject(it));
|
439
|
+
var getOwnPropertySymbols = objectGetOwnPropertySymbols.f;
|
440
|
+
return getOwnPropertySymbols ? keys.concat(getOwnPropertySymbols(it)) : keys;
|
441
|
+
};
|
442
|
+
|
443
|
+
var copyConstructorProperties = function (target, source) {
|
444
|
+
var keys = ownKeys(source);
|
445
|
+
var defineProperty = objectDefineProperty.f;
|
446
|
+
var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
|
447
|
+
for (var i = 0; i < keys.length; i++) {
|
448
|
+
var key = keys[i];
|
449
|
+
if (!has(target, key)) defineProperty(target, key, getOwnPropertyDescriptor(source, key));
|
450
|
+
}
|
451
|
+
};
|
452
|
+
|
453
|
+
var replacement = /#|\.prototype\./;
|
454
|
+
|
455
|
+
var isForced = function (feature, detection) {
|
456
|
+
var value = data[normalize(feature)];
|
457
|
+
return value == POLYFILL ? true
|
458
|
+
: value == NATIVE ? false
|
459
|
+
: typeof detection == 'function' ? fails(detection)
|
460
|
+
: !!detection;
|
461
|
+
};
|
462
|
+
|
463
|
+
var normalize = isForced.normalize = function (string) {
|
464
|
+
return String(string).replace(replacement, '.').toLowerCase();
|
465
|
+
};
|
466
|
+
|
467
|
+
var data = isForced.data = {};
|
468
|
+
var NATIVE = isForced.NATIVE = 'N';
|
469
|
+
var POLYFILL = isForced.POLYFILL = 'P';
|
470
|
+
|
471
|
+
var isForced_1 = isForced;
|
472
|
+
|
473
|
+
var getOwnPropertyDescriptor$1 = objectGetOwnPropertyDescriptor.f;
|
474
|
+
|
475
|
+
|
476
|
+
|
477
|
+
|
478
|
+
|
479
|
+
|
480
|
+
/*
|
481
|
+
options.target - name of the target object
|
482
|
+
options.global - target is the global object
|
483
|
+
options.stat - export as static methods of target
|
484
|
+
options.proto - export as prototype methods of target
|
485
|
+
options.real - real prototype method for the `pure` version
|
486
|
+
options.forced - export even if the native feature is available
|
487
|
+
options.bind - bind methods to the target, required for the `pure` version
|
488
|
+
options.wrap - wrap constructors to preventing global pollution, required for the `pure` version
|
489
|
+
options.unsafe - use the simple assignment of property instead of delete + defineProperty
|
490
|
+
options.sham - add a flag to not completely full polyfills
|
491
|
+
options.enumerable - export as enumerable property
|
492
|
+
options.noTargetGet - prevent calling a getter on target
|
493
|
+
*/
|
494
|
+
var _export = function (options, source) {
|
495
|
+
var TARGET = options.target;
|
496
|
+
var GLOBAL = options.global;
|
497
|
+
var STATIC = options.stat;
|
498
|
+
var FORCED, target, key, targetProperty, sourceProperty, descriptor;
|
499
|
+
if (GLOBAL) {
|
500
|
+
target = global_1;
|
501
|
+
} else if (STATIC) {
|
502
|
+
target = global_1[TARGET] || setGlobal(TARGET, {});
|
503
|
+
} else {
|
504
|
+
target = (global_1[TARGET] || {}).prototype;
|
505
|
+
}
|
506
|
+
if (target) for (key in source) {
|
507
|
+
sourceProperty = source[key];
|
508
|
+
if (options.noTargetGet) {
|
509
|
+
descriptor = getOwnPropertyDescriptor$1(target, key);
|
510
|
+
targetProperty = descriptor && descriptor.value;
|
511
|
+
} else targetProperty = target[key];
|
512
|
+
FORCED = isForced_1(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
|
513
|
+
// contained in target
|
514
|
+
if (!FORCED && targetProperty !== undefined) {
|
515
|
+
if (typeof sourceProperty === typeof targetProperty) continue;
|
516
|
+
copyConstructorProperties(sourceProperty, targetProperty);
|
517
|
+
}
|
518
|
+
// add a flag to not completely full polyfills
|
519
|
+
if (options.sham || (targetProperty && targetProperty.sham)) {
|
520
|
+
createNonEnumerableProperty(sourceProperty, 'sham', true);
|
521
|
+
}
|
522
|
+
// extend global
|
523
|
+
redefine(target, key, sourceProperty, options);
|
524
|
+
}
|
525
|
+
};
|
526
|
+
|
527
|
+
var nativeSymbol = !!Object.getOwnPropertySymbols && !fails(function () {
|
528
|
+
// Chrome 38 Symbol has incorrect toString conversion
|
529
|
+
// eslint-disable-next-line no-undef
|
530
|
+
return !String(Symbol());
|
531
|
+
});
|
532
|
+
|
533
|
+
var useSymbolAsUid = nativeSymbol
|
534
|
+
// eslint-disable-next-line no-undef
|
535
|
+
&& !Symbol.sham
|
536
|
+
// eslint-disable-next-line no-undef
|
537
|
+
&& typeof Symbol() == 'symbol';
|
538
|
+
|
539
|
+
// `IsArray` abstract operation
|
540
|
+
// https://tc39.github.io/ecma262/#sec-isarray
|
541
|
+
var isArray = Array.isArray || function isArray(arg) {
|
542
|
+
return classofRaw(arg) == 'Array';
|
543
|
+
};
|
544
|
+
|
545
|
+
// `ToObject` abstract operation
|
546
|
+
// https://tc39.github.io/ecma262/#sec-toobject
|
547
|
+
var toObject = function (argument) {
|
548
|
+
return Object(requireObjectCoercible(argument));
|
549
|
+
};
|
550
|
+
|
551
|
+
// `Object.keys` method
|
552
|
+
// https://tc39.github.io/ecma262/#sec-object.keys
|
553
|
+
var objectKeys = Object.keys || function keys(O) {
|
554
|
+
return objectKeysInternal(O, enumBugKeys);
|
555
|
+
};
|
556
|
+
|
557
|
+
// `Object.defineProperties` method
|
558
|
+
// https://tc39.github.io/ecma262/#sec-object.defineproperties
|
559
|
+
var objectDefineProperties = descriptors ? Object.defineProperties : function defineProperties(O, Properties) {
|
560
|
+
anObject(O);
|
561
|
+
var keys = objectKeys(Properties);
|
562
|
+
var length = keys.length;
|
563
|
+
var index = 0;
|
564
|
+
var key;
|
565
|
+
while (length > index) objectDefineProperty.f(O, key = keys[index++], Properties[key]);
|
566
|
+
return O;
|
567
|
+
};
|
568
|
+
|
569
|
+
var html = getBuiltIn('document', 'documentElement');
|
570
|
+
|
571
|
+
var GT = '>';
|
572
|
+
var LT = '<';
|
573
|
+
var PROTOTYPE = 'prototype';
|
574
|
+
var SCRIPT = 'script';
|
575
|
+
var IE_PROTO = sharedKey('IE_PROTO');
|
576
|
+
|
577
|
+
var EmptyConstructor = function () { /* empty */ };
|
578
|
+
|
579
|
+
var scriptTag = function (content) {
|
580
|
+
return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;
|
581
|
+
};
|
582
|
+
|
583
|
+
// Create object with fake `null` prototype: use ActiveX Object with cleared prototype
|
584
|
+
var NullProtoObjectViaActiveX = function (activeXDocument) {
|
585
|
+
activeXDocument.write(scriptTag(''));
|
586
|
+
activeXDocument.close();
|
587
|
+
var temp = activeXDocument.parentWindow.Object;
|
588
|
+
activeXDocument = null; // avoid memory leak
|
589
|
+
return temp;
|
590
|
+
};
|
591
|
+
|
592
|
+
// Create object with fake `null` prototype: use iframe Object with cleared prototype
|
593
|
+
var NullProtoObjectViaIFrame = function () {
|
594
|
+
// Thrash, waste and sodomy: IE GC bug
|
595
|
+
var iframe = documentCreateElement('iframe');
|
596
|
+
var JS = 'java' + SCRIPT + ':';
|
597
|
+
var iframeDocument;
|
598
|
+
iframe.style.display = 'none';
|
599
|
+
html.appendChild(iframe);
|
600
|
+
// https://github.com/zloirock/core-js/issues/475
|
601
|
+
iframe.src = String(JS);
|
602
|
+
iframeDocument = iframe.contentWindow.document;
|
603
|
+
iframeDocument.open();
|
604
|
+
iframeDocument.write(scriptTag('document.F=Object'));
|
605
|
+
iframeDocument.close();
|
606
|
+
return iframeDocument.F;
|
607
|
+
};
|
608
|
+
|
609
|
+
// Check for document.domain and active x support
|
610
|
+
// No need to use active x approach when document.domain is not set
|
611
|
+
// see https://github.com/es-shims/es5-shim/issues/150
|
612
|
+
// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346
|
613
|
+
// avoid IE GC bug
|
614
|
+
var activeXDocument;
|
615
|
+
var NullProtoObject = function () {
|
616
|
+
try {
|
617
|
+
/* global ActiveXObject */
|
618
|
+
activeXDocument = document.domain && new ActiveXObject('htmlfile');
|
619
|
+
} catch (error) { /* ignore */ }
|
620
|
+
NullProtoObject = activeXDocument ? NullProtoObjectViaActiveX(activeXDocument) : NullProtoObjectViaIFrame();
|
621
|
+
var length = enumBugKeys.length;
|
622
|
+
while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];
|
623
|
+
return NullProtoObject();
|
624
|
+
};
|
625
|
+
|
626
|
+
hiddenKeys[IE_PROTO] = true;
|
627
|
+
|
628
|
+
// `Object.create` method
|
629
|
+
// https://tc39.github.io/ecma262/#sec-object.create
|
630
|
+
var objectCreate = Object.create || function create(O, Properties) {
|
631
|
+
var result;
|
632
|
+
if (O !== null) {
|
633
|
+
EmptyConstructor[PROTOTYPE] = anObject(O);
|
634
|
+
result = new EmptyConstructor();
|
635
|
+
EmptyConstructor[PROTOTYPE] = null;
|
636
|
+
// add "__proto__" for Object.getPrototypeOf polyfill
|
637
|
+
result[IE_PROTO] = O;
|
638
|
+
} else result = NullProtoObject();
|
639
|
+
return Properties === undefined ? result : objectDefineProperties(result, Properties);
|
640
|
+
};
|
641
|
+
|
642
|
+
var nativeGetOwnPropertyNames = objectGetOwnPropertyNames.f;
|
643
|
+
|
644
|
+
var toString$1 = {}.toString;
|
645
|
+
|
646
|
+
var windowNames = typeof window == 'object' && window && Object.getOwnPropertyNames
|
647
|
+
? Object.getOwnPropertyNames(window) : [];
|
648
|
+
|
649
|
+
var getWindowNames = function (it) {
|
650
|
+
try {
|
651
|
+
return nativeGetOwnPropertyNames(it);
|
652
|
+
} catch (error) {
|
653
|
+
return windowNames.slice();
|
654
|
+
}
|
655
|
+
};
|
656
|
+
|
657
|
+
// fallback for IE11 buggy Object.getOwnPropertyNames with iframe and window
|
658
|
+
var f$5 = function getOwnPropertyNames(it) {
|
659
|
+
return windowNames && toString$1.call(it) == '[object Window]'
|
660
|
+
? getWindowNames(it)
|
661
|
+
: nativeGetOwnPropertyNames(toIndexedObject(it));
|
662
|
+
};
|
663
|
+
|
664
|
+
var objectGetOwnPropertyNamesExternal = {
|
665
|
+
f: f$5
|
666
|
+
};
|
667
|
+
|
668
|
+
var WellKnownSymbolsStore = shared('wks');
|
669
|
+
var Symbol$1 = global_1.Symbol;
|
670
|
+
var createWellKnownSymbol = useSymbolAsUid ? Symbol$1 : uid;
|
671
|
+
|
672
|
+
var wellKnownSymbol = function (name) {
|
673
|
+
if (!has(WellKnownSymbolsStore, name)) {
|
674
|
+
if (nativeSymbol && has(Symbol$1, name)) WellKnownSymbolsStore[name] = Symbol$1[name];
|
675
|
+
else WellKnownSymbolsStore[name] = createWellKnownSymbol('Symbol.' + name);
|
676
|
+
} return WellKnownSymbolsStore[name];
|
677
|
+
};
|
678
|
+
|
679
|
+
var f$6 = wellKnownSymbol;
|
680
|
+
|
681
|
+
var wrappedWellKnownSymbol = {
|
682
|
+
f: f$6
|
683
|
+
};
|
684
|
+
|
685
|
+
var defineProperty = objectDefineProperty.f;
|
686
|
+
|
687
|
+
var defineWellKnownSymbol = function (NAME) {
|
688
|
+
var Symbol = path.Symbol || (path.Symbol = {});
|
689
|
+
if (!has(Symbol, NAME)) defineProperty(Symbol, NAME, {
|
690
|
+
value: wrappedWellKnownSymbol.f(NAME)
|
691
|
+
});
|
692
|
+
};
|
693
|
+
|
694
|
+
var defineProperty$1 = objectDefineProperty.f;
|
695
|
+
|
696
|
+
|
697
|
+
|
698
|
+
var TO_STRING_TAG = wellKnownSymbol('toStringTag');
|
699
|
+
|
700
|
+
var setToStringTag = function (it, TAG, STATIC) {
|
701
|
+
if (it && !has(it = STATIC ? it : it.prototype, TO_STRING_TAG)) {
|
702
|
+
defineProperty$1(it, TO_STRING_TAG, { configurable: true, value: TAG });
|
703
|
+
}
|
704
|
+
};
|
705
|
+
|
706
|
+
var aFunction$1 = function (it) {
|
707
|
+
if (typeof it != 'function') {
|
708
|
+
throw TypeError(String(it) + ' is not a function');
|
709
|
+
} return it;
|
710
|
+
};
|
711
|
+
|
712
|
+
// optional / simple context binding
|
713
|
+
var bindContext = function (fn, that, length) {
|
714
|
+
aFunction$1(fn);
|
715
|
+
if (that === undefined) return fn;
|
716
|
+
switch (length) {
|
717
|
+
case 0: return function () {
|
718
|
+
return fn.call(that);
|
719
|
+
};
|
720
|
+
case 1: return function (a) {
|
721
|
+
return fn.call(that, a);
|
722
|
+
};
|
723
|
+
case 2: return function (a, b) {
|
724
|
+
return fn.call(that, a, b);
|
725
|
+
};
|
726
|
+
case 3: return function (a, b, c) {
|
727
|
+
return fn.call(that, a, b, c);
|
728
|
+
};
|
729
|
+
}
|
730
|
+
return function (/* ...args */) {
|
731
|
+
return fn.apply(that, arguments);
|
732
|
+
};
|
733
|
+
};
|
734
|
+
|
735
|
+
var SPECIES = wellKnownSymbol('species');
|
736
|
+
|
737
|
+
// `ArraySpeciesCreate` abstract operation
|
738
|
+
// https://tc39.github.io/ecma262/#sec-arrayspeciescreate
|
739
|
+
var arraySpeciesCreate = function (originalArray, length) {
|
740
|
+
var C;
|
741
|
+
if (isArray(originalArray)) {
|
742
|
+
C = originalArray.constructor;
|
743
|
+
// cross-realm fallback
|
744
|
+
if (typeof C == 'function' && (C === Array || isArray(C.prototype))) C = undefined;
|
745
|
+
else if (isObject(C)) {
|
746
|
+
C = C[SPECIES];
|
747
|
+
if (C === null) C = undefined;
|
748
|
+
}
|
749
|
+
} return new (C === undefined ? Array : C)(length === 0 ? 0 : length);
|
750
|
+
};
|
751
|
+
|
752
|
+
var push = [].push;
|
753
|
+
|
754
|
+
// `Array.prototype.{ forEach, map, filter, some, every, find, findIndex }` methods implementation
|
755
|
+
var createMethod$1 = function (TYPE) {
|
756
|
+
var IS_MAP = TYPE == 1;
|
757
|
+
var IS_FILTER = TYPE == 2;
|
758
|
+
var IS_SOME = TYPE == 3;
|
759
|
+
var IS_EVERY = TYPE == 4;
|
760
|
+
var IS_FIND_INDEX = TYPE == 6;
|
761
|
+
var NO_HOLES = TYPE == 5 || IS_FIND_INDEX;
|
762
|
+
return function ($this, callbackfn, that, specificCreate) {
|
763
|
+
var O = toObject($this);
|
764
|
+
var self = indexedObject(O);
|
765
|
+
var boundFunction = bindContext(callbackfn, that, 3);
|
766
|
+
var length = toLength(self.length);
|
767
|
+
var index = 0;
|
768
|
+
var create = specificCreate || arraySpeciesCreate;
|
769
|
+
var target = IS_MAP ? create($this, length) : IS_FILTER ? create($this, 0) : undefined;
|
770
|
+
var value, result;
|
771
|
+
for (;length > index; index++) if (NO_HOLES || index in self) {
|
772
|
+
value = self[index];
|
773
|
+
result = boundFunction(value, index, O);
|
774
|
+
if (TYPE) {
|
775
|
+
if (IS_MAP) target[index] = result; // map
|
776
|
+
else if (result) switch (TYPE) {
|
777
|
+
case 3: return true; // some
|
778
|
+
case 5: return value; // find
|
779
|
+
case 6: return index; // findIndex
|
780
|
+
case 2: push.call(target, value); // filter
|
781
|
+
} else if (IS_EVERY) return false; // every
|
782
|
+
}
|
783
|
+
}
|
784
|
+
return IS_FIND_INDEX ? -1 : IS_SOME || IS_EVERY ? IS_EVERY : target;
|
785
|
+
};
|
786
|
+
};
|
787
|
+
|
788
|
+
var arrayIteration = {
|
789
|
+
// `Array.prototype.forEach` method
|
790
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.foreach
|
791
|
+
forEach: createMethod$1(0),
|
792
|
+
// `Array.prototype.map` method
|
793
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.map
|
794
|
+
map: createMethod$1(1),
|
795
|
+
// `Array.prototype.filter` method
|
796
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.filter
|
797
|
+
filter: createMethod$1(2),
|
798
|
+
// `Array.prototype.some` method
|
799
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.some
|
800
|
+
some: createMethod$1(3),
|
801
|
+
// `Array.prototype.every` method
|
802
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.every
|
803
|
+
every: createMethod$1(4),
|
804
|
+
// `Array.prototype.find` method
|
805
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.find
|
806
|
+
find: createMethod$1(5),
|
807
|
+
// `Array.prototype.findIndex` method
|
808
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.findIndex
|
809
|
+
findIndex: createMethod$1(6)
|
810
|
+
};
|
811
|
+
|
812
|
+
var $forEach = arrayIteration.forEach;
|
813
|
+
|
814
|
+
var HIDDEN = sharedKey('hidden');
|
815
|
+
var SYMBOL = 'Symbol';
|
816
|
+
var PROTOTYPE$1 = 'prototype';
|
817
|
+
var TO_PRIMITIVE = wellKnownSymbol('toPrimitive');
|
818
|
+
var setInternalState = internalState.set;
|
819
|
+
var getInternalState = internalState.getterFor(SYMBOL);
|
820
|
+
var ObjectPrototype = Object[PROTOTYPE$1];
|
821
|
+
var $Symbol = global_1.Symbol;
|
822
|
+
var $stringify = getBuiltIn('JSON', 'stringify');
|
823
|
+
var nativeGetOwnPropertyDescriptor$1 = objectGetOwnPropertyDescriptor.f;
|
824
|
+
var nativeDefineProperty$1 = objectDefineProperty.f;
|
825
|
+
var nativeGetOwnPropertyNames$1 = objectGetOwnPropertyNamesExternal.f;
|
826
|
+
var nativePropertyIsEnumerable$1 = objectPropertyIsEnumerable.f;
|
827
|
+
var AllSymbols = shared('symbols');
|
828
|
+
var ObjectPrototypeSymbols = shared('op-symbols');
|
829
|
+
var StringToSymbolRegistry = shared('string-to-symbol-registry');
|
830
|
+
var SymbolToStringRegistry = shared('symbol-to-string-registry');
|
831
|
+
var WellKnownSymbolsStore$1 = shared('wks');
|
832
|
+
var QObject = global_1.QObject;
|
833
|
+
// Don't use setters in Qt Script, https://github.com/zloirock/core-js/issues/173
|
834
|
+
var USE_SETTER = !QObject || !QObject[PROTOTYPE$1] || !QObject[PROTOTYPE$1].findChild;
|
835
|
+
|
836
|
+
// fallback for old Android, https://code.google.com/p/v8/issues/detail?id=687
|
837
|
+
var setSymbolDescriptor = descriptors && fails(function () {
|
838
|
+
return objectCreate(nativeDefineProperty$1({}, 'a', {
|
839
|
+
get: function () { return nativeDefineProperty$1(this, 'a', { value: 7 }).a; }
|
840
|
+
})).a != 7;
|
841
|
+
}) ? function (O, P, Attributes) {
|
842
|
+
var ObjectPrototypeDescriptor = nativeGetOwnPropertyDescriptor$1(ObjectPrototype, P);
|
843
|
+
if (ObjectPrototypeDescriptor) delete ObjectPrototype[P];
|
844
|
+
nativeDefineProperty$1(O, P, Attributes);
|
845
|
+
if (ObjectPrototypeDescriptor && O !== ObjectPrototype) {
|
846
|
+
nativeDefineProperty$1(ObjectPrototype, P, ObjectPrototypeDescriptor);
|
847
|
+
}
|
848
|
+
} : nativeDefineProperty$1;
|
849
|
+
|
850
|
+
var wrap = function (tag, description) {
|
851
|
+
var symbol = AllSymbols[tag] = objectCreate($Symbol[PROTOTYPE$1]);
|
852
|
+
setInternalState(symbol, {
|
853
|
+
type: SYMBOL,
|
854
|
+
tag: tag,
|
855
|
+
description: description
|
856
|
+
});
|
857
|
+
if (!descriptors) symbol.description = description;
|
858
|
+
return symbol;
|
859
|
+
};
|
860
|
+
|
861
|
+
var isSymbol = nativeSymbol && typeof $Symbol.iterator == 'symbol' ? function (it) {
|
862
|
+
return typeof it == 'symbol';
|
863
|
+
} : function (it) {
|
864
|
+
return Object(it) instanceof $Symbol;
|
865
|
+
};
|
866
|
+
|
867
|
+
var $defineProperty = function defineProperty(O, P, Attributes) {
|
868
|
+
if (O === ObjectPrototype) $defineProperty(ObjectPrototypeSymbols, P, Attributes);
|
869
|
+
anObject(O);
|
870
|
+
var key = toPrimitive(P, true);
|
871
|
+
anObject(Attributes);
|
872
|
+
if (has(AllSymbols, key)) {
|
873
|
+
if (!Attributes.enumerable) {
|
874
|
+
if (!has(O, HIDDEN)) nativeDefineProperty$1(O, HIDDEN, createPropertyDescriptor(1, {}));
|
875
|
+
O[HIDDEN][key] = true;
|
876
|
+
} else {
|
877
|
+
if (has(O, HIDDEN) && O[HIDDEN][key]) O[HIDDEN][key] = false;
|
878
|
+
Attributes = objectCreate(Attributes, { enumerable: createPropertyDescriptor(0, false) });
|
879
|
+
} return setSymbolDescriptor(O, key, Attributes);
|
880
|
+
} return nativeDefineProperty$1(O, key, Attributes);
|
881
|
+
};
|
882
|
+
|
883
|
+
var $defineProperties = function defineProperties(O, Properties) {
|
884
|
+
anObject(O);
|
885
|
+
var properties = toIndexedObject(Properties);
|
886
|
+
var keys = objectKeys(properties).concat($getOwnPropertySymbols(properties));
|
887
|
+
$forEach(keys, function (key) {
|
888
|
+
if (!descriptors || $propertyIsEnumerable.call(properties, key)) $defineProperty(O, key, properties[key]);
|
889
|
+
});
|
890
|
+
return O;
|
891
|
+
};
|
892
|
+
|
893
|
+
var $create = function create(O, Properties) {
|
894
|
+
return Properties === undefined ? objectCreate(O) : $defineProperties(objectCreate(O), Properties);
|
895
|
+
};
|
896
|
+
|
897
|
+
var $propertyIsEnumerable = function propertyIsEnumerable(V) {
|
898
|
+
var P = toPrimitive(V, true);
|
899
|
+
var enumerable = nativePropertyIsEnumerable$1.call(this, P);
|
900
|
+
if (this === ObjectPrototype && has(AllSymbols, P) && !has(ObjectPrototypeSymbols, P)) return false;
|
901
|
+
return enumerable || !has(this, P) || !has(AllSymbols, P) || has(this, HIDDEN) && this[HIDDEN][P] ? enumerable : true;
|
902
|
+
};
|
903
|
+
|
904
|
+
var $getOwnPropertyDescriptor = function getOwnPropertyDescriptor(O, P) {
|
905
|
+
var it = toIndexedObject(O);
|
906
|
+
var key = toPrimitive(P, true);
|
907
|
+
if (it === ObjectPrototype && has(AllSymbols, key) && !has(ObjectPrototypeSymbols, key)) return;
|
908
|
+
var descriptor = nativeGetOwnPropertyDescriptor$1(it, key);
|
909
|
+
if (descriptor && has(AllSymbols, key) && !(has(it, HIDDEN) && it[HIDDEN][key])) {
|
910
|
+
descriptor.enumerable = true;
|
911
|
+
}
|
912
|
+
return descriptor;
|
913
|
+
};
|
914
|
+
|
915
|
+
var $getOwnPropertyNames = function getOwnPropertyNames(O) {
|
916
|
+
var names = nativeGetOwnPropertyNames$1(toIndexedObject(O));
|
917
|
+
var result = [];
|
918
|
+
$forEach(names, function (key) {
|
919
|
+
if (!has(AllSymbols, key) && !has(hiddenKeys, key)) result.push(key);
|
920
|
+
});
|
921
|
+
return result;
|
922
|
+
};
|
923
|
+
|
924
|
+
var $getOwnPropertySymbols = function getOwnPropertySymbols(O) {
|
925
|
+
var IS_OBJECT_PROTOTYPE = O === ObjectPrototype;
|
926
|
+
var names = nativeGetOwnPropertyNames$1(IS_OBJECT_PROTOTYPE ? ObjectPrototypeSymbols : toIndexedObject(O));
|
927
|
+
var result = [];
|
928
|
+
$forEach(names, function (key) {
|
929
|
+
if (has(AllSymbols, key) && (!IS_OBJECT_PROTOTYPE || has(ObjectPrototype, key))) {
|
930
|
+
result.push(AllSymbols[key]);
|
931
|
+
}
|
932
|
+
});
|
933
|
+
return result;
|
934
|
+
};
|
935
|
+
|
936
|
+
// `Symbol` constructor
|
937
|
+
// https://tc39.github.io/ecma262/#sec-symbol-constructor
|
938
|
+
if (!nativeSymbol) {
|
939
|
+
$Symbol = function Symbol() {
|
940
|
+
if (this instanceof $Symbol) throw TypeError('Symbol is not a constructor');
|
941
|
+
var description = !arguments.length || arguments[0] === undefined ? undefined : String(arguments[0]);
|
942
|
+
var tag = uid(description);
|
943
|
+
var setter = function (value) {
|
944
|
+
if (this === ObjectPrototype) setter.call(ObjectPrototypeSymbols, value);
|
945
|
+
if (has(this, HIDDEN) && has(this[HIDDEN], tag)) this[HIDDEN][tag] = false;
|
946
|
+
setSymbolDescriptor(this, tag, createPropertyDescriptor(1, value));
|
947
|
+
};
|
948
|
+
if (descriptors && USE_SETTER) setSymbolDescriptor(ObjectPrototype, tag, { configurable: true, set: setter });
|
949
|
+
return wrap(tag, description);
|
950
|
+
};
|
951
|
+
|
952
|
+
redefine($Symbol[PROTOTYPE$1], 'toString', function toString() {
|
953
|
+
return getInternalState(this).tag;
|
954
|
+
});
|
955
|
+
|
956
|
+
objectPropertyIsEnumerable.f = $propertyIsEnumerable;
|
957
|
+
objectDefineProperty.f = $defineProperty;
|
958
|
+
objectGetOwnPropertyDescriptor.f = $getOwnPropertyDescriptor;
|
959
|
+
objectGetOwnPropertyNames.f = objectGetOwnPropertyNamesExternal.f = $getOwnPropertyNames;
|
960
|
+
objectGetOwnPropertySymbols.f = $getOwnPropertySymbols;
|
961
|
+
|
962
|
+
if (descriptors) {
|
963
|
+
// https://github.com/tc39/proposal-Symbol-description
|
964
|
+
nativeDefineProperty$1($Symbol[PROTOTYPE$1], 'description', {
|
965
|
+
configurable: true,
|
966
|
+
get: function description() {
|
967
|
+
return getInternalState(this).description;
|
968
|
+
}
|
969
|
+
});
|
970
|
+
{
|
971
|
+
redefine(ObjectPrototype, 'propertyIsEnumerable', $propertyIsEnumerable, { unsafe: true });
|
972
|
+
}
|
973
|
+
}
|
974
|
+
}
|
975
|
+
|
976
|
+
if (!useSymbolAsUid) {
|
977
|
+
wrappedWellKnownSymbol.f = function (name) {
|
978
|
+
return wrap(wellKnownSymbol(name), name);
|
979
|
+
};
|
980
|
+
}
|
981
|
+
|
982
|
+
_export({ global: true, wrap: true, forced: !nativeSymbol, sham: !nativeSymbol }, {
|
983
|
+
Symbol: $Symbol
|
984
|
+
});
|
985
|
+
|
986
|
+
$forEach(objectKeys(WellKnownSymbolsStore$1), function (name) {
|
987
|
+
defineWellKnownSymbol(name);
|
988
|
+
});
|
989
|
+
|
990
|
+
_export({ target: SYMBOL, stat: true, forced: !nativeSymbol }, {
|
991
|
+
// `Symbol.for` method
|
992
|
+
// https://tc39.github.io/ecma262/#sec-symbol.for
|
993
|
+
'for': function (key) {
|
994
|
+
var string = String(key);
|
995
|
+
if (has(StringToSymbolRegistry, string)) return StringToSymbolRegistry[string];
|
996
|
+
var symbol = $Symbol(string);
|
997
|
+
StringToSymbolRegistry[string] = symbol;
|
998
|
+
SymbolToStringRegistry[symbol] = string;
|
999
|
+
return symbol;
|
1000
|
+
},
|
1001
|
+
// `Symbol.keyFor` method
|
1002
|
+
// https://tc39.github.io/ecma262/#sec-symbol.keyfor
|
1003
|
+
keyFor: function keyFor(sym) {
|
1004
|
+
if (!isSymbol(sym)) throw TypeError(sym + ' is not a symbol');
|
1005
|
+
if (has(SymbolToStringRegistry, sym)) return SymbolToStringRegistry[sym];
|
1006
|
+
},
|
1007
|
+
useSetter: function () { USE_SETTER = true; },
|
1008
|
+
useSimple: function () { USE_SETTER = false; }
|
1009
|
+
});
|
1010
|
+
|
1011
|
+
_export({ target: 'Object', stat: true, forced: !nativeSymbol, sham: !descriptors }, {
|
1012
|
+
// `Object.create` method
|
1013
|
+
// https://tc39.github.io/ecma262/#sec-object.create
|
1014
|
+
create: $create,
|
1015
|
+
// `Object.defineProperty` method
|
1016
|
+
// https://tc39.github.io/ecma262/#sec-object.defineproperty
|
1017
|
+
defineProperty: $defineProperty,
|
1018
|
+
// `Object.defineProperties` method
|
1019
|
+
// https://tc39.github.io/ecma262/#sec-object.defineproperties
|
1020
|
+
defineProperties: $defineProperties,
|
1021
|
+
// `Object.getOwnPropertyDescriptor` method
|
1022
|
+
// https://tc39.github.io/ecma262/#sec-object.getownpropertydescriptors
|
1023
|
+
getOwnPropertyDescriptor: $getOwnPropertyDescriptor
|
1024
|
+
});
|
1025
|
+
|
1026
|
+
_export({ target: 'Object', stat: true, forced: !nativeSymbol }, {
|
1027
|
+
// `Object.getOwnPropertyNames` method
|
1028
|
+
// https://tc39.github.io/ecma262/#sec-object.getownpropertynames
|
1029
|
+
getOwnPropertyNames: $getOwnPropertyNames,
|
1030
|
+
// `Object.getOwnPropertySymbols` method
|
1031
|
+
// https://tc39.github.io/ecma262/#sec-object.getownpropertysymbols
|
1032
|
+
getOwnPropertySymbols: $getOwnPropertySymbols
|
1033
|
+
});
|
1034
|
+
|
1035
|
+
// Chrome 38 and 39 `Object.getOwnPropertySymbols` fails on primitives
|
1036
|
+
// https://bugs.chromium.org/p/v8/issues/detail?id=3443
|
1037
|
+
_export({ target: 'Object', stat: true, forced: fails(function () { objectGetOwnPropertySymbols.f(1); }) }, {
|
1038
|
+
getOwnPropertySymbols: function getOwnPropertySymbols(it) {
|
1039
|
+
return objectGetOwnPropertySymbols.f(toObject(it));
|
1040
|
+
}
|
1041
|
+
});
|
1042
|
+
|
1043
|
+
// `JSON.stringify` method behavior with symbols
|
1044
|
+
// https://tc39.github.io/ecma262/#sec-json.stringify
|
1045
|
+
if ($stringify) {
|
1046
|
+
var FORCED_JSON_STRINGIFY = !nativeSymbol || fails(function () {
|
1047
|
+
var symbol = $Symbol();
|
1048
|
+
// MS Edge converts symbol values to JSON as {}
|
1049
|
+
return $stringify([symbol]) != '[null]'
|
1050
|
+
// WebKit converts symbol values to JSON as null
|
1051
|
+
|| $stringify({ a: symbol }) != '{}'
|
1052
|
+
// V8 throws on boxed symbols
|
1053
|
+
|| $stringify(Object(symbol)) != '{}';
|
1054
|
+
});
|
1055
|
+
|
1056
|
+
_export({ target: 'JSON', stat: true, forced: FORCED_JSON_STRINGIFY }, {
|
1057
|
+
// eslint-disable-next-line no-unused-vars
|
1058
|
+
stringify: function stringify(it, replacer, space) {
|
1059
|
+
var args = [it];
|
1060
|
+
var index = 1;
|
1061
|
+
var $replacer;
|
1062
|
+
while (arguments.length > index) args.push(arguments[index++]);
|
1063
|
+
$replacer = replacer;
|
1064
|
+
if (!isObject(replacer) && it === undefined || isSymbol(it)) return; // IE8 returns string on undefined
|
1065
|
+
if (!isArray(replacer)) replacer = function (key, value) {
|
1066
|
+
if (typeof $replacer == 'function') value = $replacer.call(this, key, value);
|
1067
|
+
if (!isSymbol(value)) return value;
|
1068
|
+
};
|
1069
|
+
args[1] = replacer;
|
1070
|
+
return $stringify.apply(null, args);
|
1071
|
+
}
|
1072
|
+
});
|
1073
|
+
}
|
1074
|
+
|
1075
|
+
// `Symbol.prototype[@@toPrimitive]` method
|
1076
|
+
// https://tc39.github.io/ecma262/#sec-symbol.prototype-@@toprimitive
|
1077
|
+
if (!$Symbol[PROTOTYPE$1][TO_PRIMITIVE]) {
|
1078
|
+
createNonEnumerableProperty($Symbol[PROTOTYPE$1], TO_PRIMITIVE, $Symbol[PROTOTYPE$1].valueOf);
|
1079
|
+
}
|
1080
|
+
// `Symbol.prototype[@@toStringTag]` property
|
1081
|
+
// https://tc39.github.io/ecma262/#sec-symbol.prototype-@@tostringtag
|
1082
|
+
setToStringTag($Symbol, SYMBOL);
|
1083
|
+
|
1084
|
+
hiddenKeys[HIDDEN] = true;
|
1085
|
+
|
1086
|
+
var defineProperty$2 = objectDefineProperty.f;
|
1087
|
+
|
1088
|
+
|
1089
|
+
var NativeSymbol = global_1.Symbol;
|
1090
|
+
|
1091
|
+
if (descriptors && typeof NativeSymbol == 'function' && (!('description' in NativeSymbol.prototype) ||
|
1092
|
+
// Safari 12 bug
|
1093
|
+
NativeSymbol().description !== undefined
|
1094
|
+
)) {
|
1095
|
+
var EmptyStringDescriptionStore = {};
|
1096
|
+
// wrap Symbol constructor for correct work with undefined description
|
1097
|
+
var SymbolWrapper = function Symbol() {
|
1098
|
+
var description = arguments.length < 1 || arguments[0] === undefined ? undefined : String(arguments[0]);
|
1099
|
+
var result = this instanceof SymbolWrapper
|
1100
|
+
? new NativeSymbol(description)
|
1101
|
+
// in Edge 13, String(Symbol(undefined)) === 'Symbol(undefined)'
|
1102
|
+
: description === undefined ? NativeSymbol() : NativeSymbol(description);
|
1103
|
+
if (description === '') EmptyStringDescriptionStore[result] = true;
|
1104
|
+
return result;
|
1105
|
+
};
|
1106
|
+
copyConstructorProperties(SymbolWrapper, NativeSymbol);
|
1107
|
+
var symbolPrototype = SymbolWrapper.prototype = NativeSymbol.prototype;
|
1108
|
+
symbolPrototype.constructor = SymbolWrapper;
|
1109
|
+
|
1110
|
+
var symbolToString = symbolPrototype.toString;
|
1111
|
+
var native = String(NativeSymbol('test')) == 'Symbol(test)';
|
1112
|
+
var regexp = /^Symbol\((.*)\)[^)]+$/;
|
1113
|
+
defineProperty$2(symbolPrototype, 'description', {
|
1114
|
+
configurable: true,
|
1115
|
+
get: function description() {
|
1116
|
+
var symbol = isObject(this) ? this.valueOf() : this;
|
1117
|
+
var string = symbolToString.call(symbol);
|
1118
|
+
if (has(EmptyStringDescriptionStore, symbol)) return '';
|
1119
|
+
var desc = native ? string.slice(7, -1) : string.replace(regexp, '$1');
|
1120
|
+
return desc === '' ? undefined : desc;
|
1121
|
+
}
|
1122
|
+
});
|
1123
|
+
|
1124
|
+
_export({ global: true, forced: true }, {
|
1125
|
+
Symbol: SymbolWrapper
|
1126
|
+
});
|
1127
|
+
}
|
1128
|
+
|
1129
|
+
// `Symbol.iterator` well-known symbol
|
1130
|
+
// https://tc39.github.io/ecma262/#sec-symbol.iterator
|
1131
|
+
defineWellKnownSymbol('iterator');
|
1132
|
+
|
1133
|
+
var createProperty = function (object, key, value) {
|
1134
|
+
var propertyKey = toPrimitive(key);
|
1135
|
+
if (propertyKey in object) objectDefineProperty.f(object, propertyKey, createPropertyDescriptor(0, value));
|
1136
|
+
else object[propertyKey] = value;
|
1137
|
+
};
|
1138
|
+
|
1139
|
+
var userAgent = getBuiltIn('navigator', 'userAgent') || '';
|
1140
|
+
|
1141
|
+
var process = global_1.process;
|
1142
|
+
var versions = process && process.versions;
|
1143
|
+
var v8 = versions && versions.v8;
|
1144
|
+
var match, version;
|
1145
|
+
|
1146
|
+
if (v8) {
|
1147
|
+
match = v8.split('.');
|
1148
|
+
version = match[0] + match[1];
|
1149
|
+
} else if (userAgent) {
|
1150
|
+
match = userAgent.match(/Edge\/(\d+)/);
|
1151
|
+
if (!match || match[1] >= 74) {
|
1152
|
+
match = userAgent.match(/Chrome\/(\d+)/);
|
1153
|
+
if (match) version = match[1];
|
1154
|
+
}
|
1155
|
+
}
|
1156
|
+
|
1157
|
+
var v8Version = version && +version;
|
1158
|
+
|
1159
|
+
var SPECIES$1 = wellKnownSymbol('species');
|
1160
|
+
|
1161
|
+
var arrayMethodHasSpeciesSupport = function (METHOD_NAME) {
|
1162
|
+
// We can't use this feature detection in V8 since it causes
|
1163
|
+
// deoptimization and serious performance degradation
|
1164
|
+
// https://github.com/zloirock/core-js/issues/677
|
1165
|
+
return v8Version >= 51 || !fails(function () {
|
1166
|
+
var array = [];
|
1167
|
+
var constructor = array.constructor = {};
|
1168
|
+
constructor[SPECIES$1] = function () {
|
1169
|
+
return { foo: 1 };
|
1170
|
+
};
|
1171
|
+
return array[METHOD_NAME](Boolean).foo !== 1;
|
1172
|
+
});
|
1173
|
+
};
|
1174
|
+
|
1175
|
+
var IS_CONCAT_SPREADABLE = wellKnownSymbol('isConcatSpreadable');
|
1176
|
+
var MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF;
|
1177
|
+
var MAXIMUM_ALLOWED_INDEX_EXCEEDED = 'Maximum allowed index exceeded';
|
1178
|
+
|
1179
|
+
// We can't use this feature detection in V8 since it causes
|
1180
|
+
// deoptimization and serious performance degradation
|
1181
|
+
// https://github.com/zloirock/core-js/issues/679
|
1182
|
+
var IS_CONCAT_SPREADABLE_SUPPORT = v8Version >= 51 || !fails(function () {
|
1183
|
+
var array = [];
|
1184
|
+
array[IS_CONCAT_SPREADABLE] = false;
|
1185
|
+
return array.concat()[0] !== array;
|
1186
|
+
});
|
1187
|
+
|
1188
|
+
var SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('concat');
|
1189
|
+
|
1190
|
+
var isConcatSpreadable = function (O) {
|
1191
|
+
if (!isObject(O)) return false;
|
1192
|
+
var spreadable = O[IS_CONCAT_SPREADABLE];
|
1193
|
+
return spreadable !== undefined ? !!spreadable : isArray(O);
|
1194
|
+
};
|
1195
|
+
|
1196
|
+
var FORCED = !IS_CONCAT_SPREADABLE_SUPPORT || !SPECIES_SUPPORT;
|
1197
|
+
|
1198
|
+
// `Array.prototype.concat` method
|
1199
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.concat
|
1200
|
+
// with adding support of @@isConcatSpreadable and @@species
|
1201
|
+
_export({ target: 'Array', proto: true, forced: FORCED }, {
|
1202
|
+
concat: function concat(arg) { // eslint-disable-line no-unused-vars
|
1203
|
+
var O = toObject(this);
|
1204
|
+
var A = arraySpeciesCreate(O, 0);
|
1205
|
+
var n = 0;
|
1206
|
+
var i, k, length, len, E;
|
1207
|
+
for (i = -1, length = arguments.length; i < length; i++) {
|
1208
|
+
E = i === -1 ? O : arguments[i];
|
1209
|
+
if (isConcatSpreadable(E)) {
|
1210
|
+
len = toLength(E.length);
|
1211
|
+
if (n + len > MAX_SAFE_INTEGER) throw TypeError(MAXIMUM_ALLOWED_INDEX_EXCEEDED);
|
1212
|
+
for (k = 0; k < len; k++, n++) if (k in E) createProperty(A, n, E[k]);
|
1213
|
+
} else {
|
1214
|
+
if (n >= MAX_SAFE_INTEGER) throw TypeError(MAXIMUM_ALLOWED_INDEX_EXCEEDED);
|
1215
|
+
createProperty(A, n++, E);
|
1216
|
+
}
|
1217
|
+
}
|
1218
|
+
A.length = n;
|
1219
|
+
return A;
|
1220
|
+
}
|
1221
|
+
});
|
1222
|
+
|
1223
|
+
var UNSCOPABLES = wellKnownSymbol('unscopables');
|
1224
|
+
var ArrayPrototype = Array.prototype;
|
1225
|
+
|
1226
|
+
// Array.prototype[@@unscopables]
|
1227
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype-@@unscopables
|
1228
|
+
if (ArrayPrototype[UNSCOPABLES] == undefined) {
|
1229
|
+
objectDefineProperty.f(ArrayPrototype, UNSCOPABLES, {
|
1230
|
+
configurable: true,
|
1231
|
+
value: objectCreate(null)
|
1232
|
+
});
|
1233
|
+
}
|
1234
|
+
|
1235
|
+
// add a key to Array.prototype[@@unscopables]
|
1236
|
+
var addToUnscopables = function (key) {
|
1237
|
+
ArrayPrototype[UNSCOPABLES][key] = true;
|
1238
|
+
};
|
1239
|
+
|
1240
|
+
var correctPrototypeGetter = !fails(function () {
|
1241
|
+
function F() { /* empty */ }
|
1242
|
+
F.prototype.constructor = null;
|
1243
|
+
return Object.getPrototypeOf(new F()) !== F.prototype;
|
1244
|
+
});
|
1245
|
+
|
1246
|
+
var IE_PROTO$1 = sharedKey('IE_PROTO');
|
1247
|
+
var ObjectPrototype$1 = Object.prototype;
|
1248
|
+
|
1249
|
+
// `Object.getPrototypeOf` method
|
1250
|
+
// https://tc39.github.io/ecma262/#sec-object.getprototypeof
|
1251
|
+
var objectGetPrototypeOf = correctPrototypeGetter ? Object.getPrototypeOf : function (O) {
|
1252
|
+
O = toObject(O);
|
1253
|
+
if (has(O, IE_PROTO$1)) return O[IE_PROTO$1];
|
1254
|
+
if (typeof O.constructor == 'function' && O instanceof O.constructor) {
|
1255
|
+
return O.constructor.prototype;
|
1256
|
+
} return O instanceof Object ? ObjectPrototype$1 : null;
|
1257
|
+
};
|
1258
|
+
|
1259
|
+
var ITERATOR = wellKnownSymbol('iterator');
|
1260
|
+
var BUGGY_SAFARI_ITERATORS = false;
|
1261
|
+
|
1262
|
+
var returnThis = function () { return this; };
|
1263
|
+
|
1264
|
+
// `%IteratorPrototype%` object
|
1265
|
+
// https://tc39.github.io/ecma262/#sec-%iteratorprototype%-object
|
1266
|
+
var IteratorPrototype, PrototypeOfArrayIteratorPrototype, arrayIterator;
|
1267
|
+
|
1268
|
+
if ([].keys) {
|
1269
|
+
arrayIterator = [].keys();
|
1270
|
+
// Safari 8 has buggy iterators w/o `next`
|
1271
|
+
if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS = true;
|
1272
|
+
else {
|
1273
|
+
PrototypeOfArrayIteratorPrototype = objectGetPrototypeOf(objectGetPrototypeOf(arrayIterator));
|
1274
|
+
if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype = PrototypeOfArrayIteratorPrototype;
|
1275
|
+
}
|
1276
|
+
}
|
1277
|
+
|
1278
|
+
if (IteratorPrototype == undefined) IteratorPrototype = {};
|
1279
|
+
|
1280
|
+
// 25.1.2.1.1 %IteratorPrototype%[@@iterator]()
|
1281
|
+
if ( !has(IteratorPrototype, ITERATOR)) {
|
1282
|
+
createNonEnumerableProperty(IteratorPrototype, ITERATOR, returnThis);
|
1283
|
+
}
|
1284
|
+
|
1285
|
+
var iteratorsCore = {
|
1286
|
+
IteratorPrototype: IteratorPrototype,
|
1287
|
+
BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS
|
1288
|
+
};
|
1289
|
+
|
1290
|
+
var IteratorPrototype$1 = iteratorsCore.IteratorPrototype;
|
1291
|
+
|
1292
|
+
var createIteratorConstructor = function (IteratorConstructor, NAME, next) {
|
1293
|
+
var TO_STRING_TAG = NAME + ' Iterator';
|
1294
|
+
IteratorConstructor.prototype = objectCreate(IteratorPrototype$1, { next: createPropertyDescriptor(1, next) });
|
1295
|
+
setToStringTag(IteratorConstructor, TO_STRING_TAG, false);
|
1296
|
+
return IteratorConstructor;
|
1297
|
+
};
|
1298
|
+
|
1299
|
+
var aPossiblePrototype = function (it) {
|
1300
|
+
if (!isObject(it) && it !== null) {
|
1301
|
+
throw TypeError("Can't set " + String(it) + ' as a prototype');
|
1302
|
+
} return it;
|
1303
|
+
};
|
1304
|
+
|
1305
|
+
// `Object.setPrototypeOf` method
|
1306
|
+
// https://tc39.github.io/ecma262/#sec-object.setprototypeof
|
1307
|
+
// Works with __proto__ only. Old v8 can't work with null proto objects.
|
1308
|
+
/* eslint-disable no-proto */
|
1309
|
+
var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? function () {
|
1310
|
+
var CORRECT_SETTER = false;
|
1311
|
+
var test = {};
|
1312
|
+
var setter;
|
1313
|
+
try {
|
1314
|
+
setter = Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set;
|
1315
|
+
setter.call(test, []);
|
1316
|
+
CORRECT_SETTER = test instanceof Array;
|
1317
|
+
} catch (error) { /* empty */ }
|
1318
|
+
return function setPrototypeOf(O, proto) {
|
1319
|
+
anObject(O);
|
1320
|
+
aPossiblePrototype(proto);
|
1321
|
+
if (CORRECT_SETTER) setter.call(O, proto);
|
1322
|
+
else O.__proto__ = proto;
|
1323
|
+
return O;
|
1324
|
+
};
|
1325
|
+
}() : undefined);
|
1326
|
+
|
1327
|
+
var IteratorPrototype$2 = iteratorsCore.IteratorPrototype;
|
1328
|
+
var BUGGY_SAFARI_ITERATORS$1 = iteratorsCore.BUGGY_SAFARI_ITERATORS;
|
1329
|
+
var ITERATOR$1 = wellKnownSymbol('iterator');
|
1330
|
+
var KEYS = 'keys';
|
1331
|
+
var VALUES = 'values';
|
1332
|
+
var ENTRIES = 'entries';
|
1333
|
+
|
1334
|
+
var returnThis$1 = function () { return this; };
|
1335
|
+
|
1336
|
+
var defineIterator = function (Iterable, NAME, IteratorConstructor, next, DEFAULT, IS_SET, FORCED) {
|
1337
|
+
createIteratorConstructor(IteratorConstructor, NAME, next);
|
1338
|
+
|
1339
|
+
var getIterationMethod = function (KIND) {
|
1340
|
+
if (KIND === DEFAULT && defaultIterator) return defaultIterator;
|
1341
|
+
if (!BUGGY_SAFARI_ITERATORS$1 && KIND in IterablePrototype) return IterablePrototype[KIND];
|
1342
|
+
switch (KIND) {
|
1343
|
+
case KEYS: return function keys() { return new IteratorConstructor(this, KIND); };
|
1344
|
+
case VALUES: return function values() { return new IteratorConstructor(this, KIND); };
|
1345
|
+
case ENTRIES: return function entries() { return new IteratorConstructor(this, KIND); };
|
1346
|
+
} return function () { return new IteratorConstructor(this); };
|
1347
|
+
};
|
1348
|
+
|
1349
|
+
var TO_STRING_TAG = NAME + ' Iterator';
|
1350
|
+
var INCORRECT_VALUES_NAME = false;
|
1351
|
+
var IterablePrototype = Iterable.prototype;
|
1352
|
+
var nativeIterator = IterablePrototype[ITERATOR$1]
|
1353
|
+
|| IterablePrototype['@@iterator']
|
1354
|
+
|| DEFAULT && IterablePrototype[DEFAULT];
|
1355
|
+
var defaultIterator = !BUGGY_SAFARI_ITERATORS$1 && nativeIterator || getIterationMethod(DEFAULT);
|
1356
|
+
var anyNativeIterator = NAME == 'Array' ? IterablePrototype.entries || nativeIterator : nativeIterator;
|
1357
|
+
var CurrentIteratorPrototype, methods, KEY;
|
1358
|
+
|
1359
|
+
// fix native
|
1360
|
+
if (anyNativeIterator) {
|
1361
|
+
CurrentIteratorPrototype = objectGetPrototypeOf(anyNativeIterator.call(new Iterable()));
|
1362
|
+
if (IteratorPrototype$2 !== Object.prototype && CurrentIteratorPrototype.next) {
|
1363
|
+
if ( objectGetPrototypeOf(CurrentIteratorPrototype) !== IteratorPrototype$2) {
|
1364
|
+
if (objectSetPrototypeOf) {
|
1365
|
+
objectSetPrototypeOf(CurrentIteratorPrototype, IteratorPrototype$2);
|
1366
|
+
} else if (typeof CurrentIteratorPrototype[ITERATOR$1] != 'function') {
|
1367
|
+
createNonEnumerableProperty(CurrentIteratorPrototype, ITERATOR$1, returnThis$1);
|
1368
|
+
}
|
1369
|
+
}
|
1370
|
+
// Set @@toStringTag to native iterators
|
1371
|
+
setToStringTag(CurrentIteratorPrototype, TO_STRING_TAG, true);
|
1372
|
+
}
|
1373
|
+
}
|
1374
|
+
|
1375
|
+
// fix Array#{values, @@iterator}.name in V8 / FF
|
1376
|
+
if (DEFAULT == VALUES && nativeIterator && nativeIterator.name !== VALUES) {
|
1377
|
+
INCORRECT_VALUES_NAME = true;
|
1378
|
+
defaultIterator = function values() { return nativeIterator.call(this); };
|
1379
|
+
}
|
1380
|
+
|
1381
|
+
// define iterator
|
1382
|
+
if ( IterablePrototype[ITERATOR$1] !== defaultIterator) {
|
1383
|
+
createNonEnumerableProperty(IterablePrototype, ITERATOR$1, defaultIterator);
|
1384
|
+
}
|
1385
|
+
|
1386
|
+
// export additional methods
|
1387
|
+
if (DEFAULT) {
|
1388
|
+
methods = {
|
1389
|
+
values: getIterationMethod(VALUES),
|
1390
|
+
keys: IS_SET ? defaultIterator : getIterationMethod(KEYS),
|
1391
|
+
entries: getIterationMethod(ENTRIES)
|
1392
|
+
};
|
1393
|
+
if (FORCED) for (KEY in methods) {
|
1394
|
+
if (BUGGY_SAFARI_ITERATORS$1 || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {
|
1395
|
+
redefine(IterablePrototype, KEY, methods[KEY]);
|
1396
|
+
}
|
1397
|
+
} else _export({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS$1 || INCORRECT_VALUES_NAME }, methods);
|
1398
|
+
}
|
1399
|
+
|
1400
|
+
return methods;
|
1401
|
+
};
|
1402
|
+
|
1403
|
+
var ARRAY_ITERATOR = 'Array Iterator';
|
1404
|
+
var setInternalState$1 = internalState.set;
|
1405
|
+
var getInternalState$1 = internalState.getterFor(ARRAY_ITERATOR);
|
1406
|
+
|
1407
|
+
// `Array.prototype.entries` method
|
1408
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.entries
|
1409
|
+
// `Array.prototype.keys` method
|
1410
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.keys
|
1411
|
+
// `Array.prototype.values` method
|
1412
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype.values
|
1413
|
+
// `Array.prototype[@@iterator]` method
|
1414
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype-@@iterator
|
1415
|
+
// `CreateArrayIterator` internal method
|
1416
|
+
// https://tc39.github.io/ecma262/#sec-createarrayiterator
|
1417
|
+
var es_array_iterator = defineIterator(Array, 'Array', function (iterated, kind) {
|
1418
|
+
setInternalState$1(this, {
|
1419
|
+
type: ARRAY_ITERATOR,
|
1420
|
+
target: toIndexedObject(iterated), // target
|
1421
|
+
index: 0, // next index
|
1422
|
+
kind: kind // kind
|
1423
|
+
});
|
1424
|
+
// `%ArrayIteratorPrototype%.next` method
|
1425
|
+
// https://tc39.github.io/ecma262/#sec-%arrayiteratorprototype%.next
|
1426
|
+
}, function () {
|
1427
|
+
var state = getInternalState$1(this);
|
1428
|
+
var target = state.target;
|
1429
|
+
var kind = state.kind;
|
1430
|
+
var index = state.index++;
|
1431
|
+
if (!target || index >= target.length) {
|
1432
|
+
state.target = undefined;
|
1433
|
+
return { value: undefined, done: true };
|
1434
|
+
}
|
1435
|
+
if (kind == 'keys') return { value: index, done: false };
|
1436
|
+
if (kind == 'values') return { value: target[index], done: false };
|
1437
|
+
return { value: [index, target[index]], done: false };
|
1438
|
+
}, 'values');
|
1439
|
+
|
1440
|
+
// https://tc39.github.io/ecma262/#sec-array.prototype-@@unscopables
|
1441
|
+
addToUnscopables('keys');
|
1442
|
+
addToUnscopables('values');
|
1443
|
+
addToUnscopables('entries');
|
1444
|
+
|
1445
|
+
var TO_STRING_TAG$1 = wellKnownSymbol('toStringTag');
|
1446
|
+
var test = {};
|
1447
|
+
|
1448
|
+
test[TO_STRING_TAG$1] = 'z';
|
1449
|
+
|
1450
|
+
var toStringTagSupport = String(test) === '[object z]';
|
1451
|
+
|
1452
|
+
var TO_STRING_TAG$2 = wellKnownSymbol('toStringTag');
|
1453
|
+
// ES3 wrong here
|
1454
|
+
var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) == 'Arguments';
|
1455
|
+
|
1456
|
+
// fallback for IE11 Script Access Denied error
|
1457
|
+
var tryGet = function (it, key) {
|
1458
|
+
try {
|
1459
|
+
return it[key];
|
1460
|
+
} catch (error) { /* empty */ }
|
1461
|
+
};
|
1462
|
+
|
1463
|
+
// getting tag from ES6+ `Object.prototype.toString`
|
1464
|
+
var classof = toStringTagSupport ? classofRaw : function (it) {
|
1465
|
+
var O, tag, result;
|
1466
|
+
return it === undefined ? 'Undefined' : it === null ? 'Null'
|
1467
|
+
// @@toStringTag case
|
1468
|
+
: typeof (tag = tryGet(O = Object(it), TO_STRING_TAG$2)) == 'string' ? tag
|
1469
|
+
// builtinTag case
|
1470
|
+
: CORRECT_ARGUMENTS ? classofRaw(O)
|
1471
|
+
// ES3 arguments fallback
|
1472
|
+
: (result = classofRaw(O)) == 'Object' && typeof O.callee == 'function' ? 'Arguments' : result;
|
1473
|
+
};
|
1474
|
+
|
1475
|
+
// `Object.prototype.toString` method implementation
|
1476
|
+
// https://tc39.github.io/ecma262/#sec-object.prototype.tostring
|
1477
|
+
var objectToString = toStringTagSupport ? {}.toString : function toString() {
|
1478
|
+
return '[object ' + classof(this) + ']';
|
1479
|
+
};
|
1480
|
+
|
1481
|
+
// `Object.prototype.toString` method
|
1482
|
+
// https://tc39.github.io/ecma262/#sec-object.prototype.tostring
|
1483
|
+
if (!toStringTagSupport) {
|
1484
|
+
redefine(Object.prototype, 'toString', objectToString, { unsafe: true });
|
1485
|
+
}
|
1486
|
+
|
1487
|
+
// `RegExp.prototype.flags` getter implementation
|
1488
|
+
// https://tc39.github.io/ecma262/#sec-get-regexp.prototype.flags
|
1489
|
+
var regexpFlags = function () {
|
1490
|
+
var that = anObject(this);
|
1491
|
+
var result = '';
|
1492
|
+
if (that.global) result += 'g';
|
1493
|
+
if (that.ignoreCase) result += 'i';
|
1494
|
+
if (that.multiline) result += 'm';
|
1495
|
+
if (that.dotAll) result += 's';
|
1496
|
+
if (that.unicode) result += 'u';
|
1497
|
+
if (that.sticky) result += 'y';
|
1498
|
+
return result;
|
1499
|
+
};
|
1500
|
+
|
1501
|
+
// babel-minify transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError,
|
1502
|
+
// so we use an intermediate function.
|
1503
|
+
function RE(s, f) {
|
1504
|
+
return RegExp(s, f);
|
1505
|
+
}
|
1506
|
+
|
1507
|
+
var UNSUPPORTED_Y = fails(function () {
|
1508
|
+
// babel-minify transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError
|
1509
|
+
var re = RE('a', 'y');
|
1510
|
+
re.lastIndex = 2;
|
1511
|
+
return re.exec('abcd') != null;
|
1512
|
+
});
|
1513
|
+
|
1514
|
+
var BROKEN_CARET = fails(function () {
|
1515
|
+
// https://bugzilla.mozilla.org/show_bug.cgi?id=773687
|
1516
|
+
var re = RE('^r', 'gy');
|
1517
|
+
re.lastIndex = 2;
|
1518
|
+
return re.exec('str') != null;
|
1519
|
+
});
|
1520
|
+
|
1521
|
+
var regexpStickyHelpers = {
|
1522
|
+
UNSUPPORTED_Y: UNSUPPORTED_Y,
|
1523
|
+
BROKEN_CARET: BROKEN_CARET
|
1524
|
+
};
|
1525
|
+
|
1526
|
+
var nativeExec = RegExp.prototype.exec;
|
1527
|
+
// This always refers to the native implementation, because the
|
1528
|
+
// String#replace polyfill uses ./fix-regexp-well-known-symbol-logic.js,
|
1529
|
+
// which loads this file before patching the method.
|
1530
|
+
var nativeReplace = String.prototype.replace;
|
1531
|
+
|
1532
|
+
var patchedExec = nativeExec;
|
1533
|
+
|
1534
|
+
var UPDATES_LAST_INDEX_WRONG = (function () {
|
1535
|
+
var re1 = /a/;
|
1536
|
+
var re2 = /b*/g;
|
1537
|
+
nativeExec.call(re1, 'a');
|
1538
|
+
nativeExec.call(re2, 'a');
|
1539
|
+
return re1.lastIndex !== 0 || re2.lastIndex !== 0;
|
1540
|
+
})();
|
1541
|
+
|
1542
|
+
var UNSUPPORTED_Y$1 = regexpStickyHelpers.UNSUPPORTED_Y || regexpStickyHelpers.BROKEN_CARET;
|
1543
|
+
|
1544
|
+
// nonparticipating capturing group, copied from es5-shim's String#split patch.
|
1545
|
+
var NPCG_INCLUDED = /()??/.exec('')[1] !== undefined;
|
1546
|
+
|
1547
|
+
var PATCH = UPDATES_LAST_INDEX_WRONG || NPCG_INCLUDED || UNSUPPORTED_Y$1;
|
1548
|
+
|
1549
|
+
if (PATCH) {
|
1550
|
+
patchedExec = function exec(str) {
|
1551
|
+
var re = this;
|
1552
|
+
var lastIndex, reCopy, match, i;
|
1553
|
+
var sticky = UNSUPPORTED_Y$1 && re.sticky;
|
1554
|
+
var flags = regexpFlags.call(re);
|
1555
|
+
var source = re.source;
|
1556
|
+
var charsAdded = 0;
|
1557
|
+
var strCopy = str;
|
1558
|
+
|
1559
|
+
if (sticky) {
|
1560
|
+
flags = flags.replace('y', '');
|
1561
|
+
if (flags.indexOf('g') === -1) {
|
1562
|
+
flags += 'g';
|
1563
|
+
}
|
1564
|
+
|
1565
|
+
strCopy = String(str).slice(re.lastIndex);
|
1566
|
+
// Support anchored sticky behavior.
|
1567
|
+
if (re.lastIndex > 0 && (!re.multiline || re.multiline && str[re.lastIndex - 1] !== '\n')) {
|
1568
|
+
source = '(?: ' + source + ')';
|
1569
|
+
strCopy = ' ' + strCopy;
|
1570
|
+
charsAdded++;
|
1571
|
+
}
|
1572
|
+
// ^(? + rx + ) is needed, in combination with some str slicing, to
|
1573
|
+
// simulate the 'y' flag.
|
1574
|
+
reCopy = new RegExp('^(?:' + source + ')', flags);
|
1575
|
+
}
|
1576
|
+
|
1577
|
+
if (NPCG_INCLUDED) {
|
1578
|
+
reCopy = new RegExp('^' + source + '$(?!\\s)', flags);
|
1579
|
+
}
|
1580
|
+
if (UPDATES_LAST_INDEX_WRONG) lastIndex = re.lastIndex;
|
1581
|
+
|
1582
|
+
match = nativeExec.call(sticky ? reCopy : re, strCopy);
|
1583
|
+
|
1584
|
+
if (sticky) {
|
1585
|
+
if (match) {
|
1586
|
+
match.input = match.input.slice(charsAdded);
|
1587
|
+
match[0] = match[0].slice(charsAdded);
|
1588
|
+
match.index = re.lastIndex;
|
1589
|
+
re.lastIndex += match[0].length;
|
1590
|
+
} else re.lastIndex = 0;
|
1591
|
+
} else if (UPDATES_LAST_INDEX_WRONG && match) {
|
1592
|
+
re.lastIndex = re.global ? match.index + match[0].length : lastIndex;
|
1593
|
+
}
|
1594
|
+
if (NPCG_INCLUDED && match && match.length > 1) {
|
1595
|
+
// Fix browsers whose `exec` methods don't consistently return `undefined`
|
1596
|
+
// for NPCG, like IE8. NOTE: This doesn' work for /(.?)?/
|
1597
|
+
nativeReplace.call(match[0], reCopy, function () {
|
1598
|
+
for (i = 1; i < arguments.length - 2; i++) {
|
1599
|
+
if (arguments[i] === undefined) match[i] = undefined;
|
1600
|
+
}
|
1601
|
+
});
|
1602
|
+
}
|
1603
|
+
|
1604
|
+
return match;
|
1605
|
+
};
|
1606
|
+
}
|
1607
|
+
|
1608
|
+
var regexpExec = patchedExec;
|
1609
|
+
|
1610
|
+
_export({ target: 'RegExp', proto: true, forced: /./.exec !== regexpExec }, {
|
1611
|
+
exec: regexpExec
|
1612
|
+
});
|
1613
|
+
|
1614
|
+
// `String.prototype.{ codePointAt, at }` methods implementation
|
1615
|
+
var createMethod$2 = function (CONVERT_TO_STRING) {
|
1616
|
+
return function ($this, pos) {
|
1617
|
+
var S = String(requireObjectCoercible($this));
|
1618
|
+
var position = toInteger(pos);
|
1619
|
+
var size = S.length;
|
1620
|
+
var first, second;
|
1621
|
+
if (position < 0 || position >= size) return CONVERT_TO_STRING ? '' : undefined;
|
1622
|
+
first = S.charCodeAt(position);
|
1623
|
+
return first < 0xD800 || first > 0xDBFF || position + 1 === size
|
1624
|
+
|| (second = S.charCodeAt(position + 1)) < 0xDC00 || second > 0xDFFF
|
1625
|
+
? CONVERT_TO_STRING ? S.charAt(position) : first
|
1626
|
+
: CONVERT_TO_STRING ? S.slice(position, position + 2) : (first - 0xD800 << 10) + (second - 0xDC00) + 0x10000;
|
1627
|
+
};
|
1628
|
+
};
|
1629
|
+
|
1630
|
+
var stringMultibyte = {
|
1631
|
+
// `String.prototype.codePointAt` method
|
1632
|
+
// https://tc39.github.io/ecma262/#sec-string.prototype.codepointat
|
1633
|
+
codeAt: createMethod$2(false),
|
1634
|
+
// `String.prototype.at` method
|
1635
|
+
// https://github.com/mathiasbynens/String.prototype.at
|
1636
|
+
charAt: createMethod$2(true)
|
1637
|
+
};
|
1638
|
+
|
1639
|
+
var charAt = stringMultibyte.charAt;
|
1640
|
+
|
1641
|
+
|
1642
|
+
|
1643
|
+
var STRING_ITERATOR = 'String Iterator';
|
1644
|
+
var setInternalState$2 = internalState.set;
|
1645
|
+
var getInternalState$2 = internalState.getterFor(STRING_ITERATOR);
|
1646
|
+
|
1647
|
+
// `String.prototype[@@iterator]` method
|
1648
|
+
// https://tc39.github.io/ecma262/#sec-string.prototype-@@iterator
|
1649
|
+
defineIterator(String, 'String', function (iterated) {
|
1650
|
+
setInternalState$2(this, {
|
1651
|
+
type: STRING_ITERATOR,
|
1652
|
+
string: String(iterated),
|
1653
|
+
index: 0
|
1654
|
+
});
|
1655
|
+
// `%StringIteratorPrototype%.next` method
|
1656
|
+
// https://tc39.github.io/ecma262/#sec-%stringiteratorprototype%.next
|
1657
|
+
}, function next() {
|
1658
|
+
var state = getInternalState$2(this);
|
1659
|
+
var string = state.string;
|
1660
|
+
var index = state.index;
|
1661
|
+
var point;
|
1662
|
+
if (index >= string.length) return { value: undefined, done: true };
|
1663
|
+
point = charAt(string, index);
|
1664
|
+
state.index += point.length;
|
1665
|
+
return { value: point, done: false };
|
1666
|
+
});
|
1667
|
+
|
1668
|
+
var SPECIES$2 = wellKnownSymbol('species');
|
1669
|
+
|
1670
|
+
var REPLACE_SUPPORTS_NAMED_GROUPS = !fails(function () {
|
1671
|
+
// #replace needs built-in support for named groups.
|
1672
|
+
// #match works fine because it just return the exec results, even if it has
|
1673
|
+
// a "grops" property.
|
1674
|
+
var re = /./;
|
1675
|
+
re.exec = function () {
|
1676
|
+
var result = [];
|
1677
|
+
result.groups = { a: '7' };
|
1678
|
+
return result;
|
1679
|
+
};
|
1680
|
+
return ''.replace(re, '$<a>') !== '7';
|
1681
|
+
});
|
1682
|
+
|
1683
|
+
// IE <= 11 replaces $0 with the whole match, as if it was $&
|
1684
|
+
// https://stackoverflow.com/questions/6024666/getting-ie-to-replace-a-regex-with-the-literal-string-0
|
1685
|
+
var REPLACE_KEEPS_$0 = (function () {
|
1686
|
+
return 'a'.replace(/./, '$0') === '$0';
|
1687
|
+
})();
|
1688
|
+
|
1689
|
+
// Chrome 51 has a buggy "split" implementation when RegExp#exec !== nativeExec
|
1690
|
+
// Weex JS has frozen built-in prototypes, so use try / catch wrapper
|
1691
|
+
var SPLIT_WORKS_WITH_OVERWRITTEN_EXEC = !fails(function () {
|
1692
|
+
var re = /(?:)/;
|
1693
|
+
var originalExec = re.exec;
|
1694
|
+
re.exec = function () { return originalExec.apply(this, arguments); };
|
1695
|
+
var result = 'ab'.split(re);
|
1696
|
+
return result.length !== 2 || result[0] !== 'a' || result[1] !== 'b';
|
1697
|
+
});
|
1698
|
+
|
1699
|
+
var fixRegexpWellKnownSymbolLogic = function (KEY, length, exec, sham) {
|
1700
|
+
var SYMBOL = wellKnownSymbol(KEY);
|
1701
|
+
|
1702
|
+
var DELEGATES_TO_SYMBOL = !fails(function () {
|
1703
|
+
// String methods call symbol-named RegEp methods
|
1704
|
+
var O = {};
|
1705
|
+
O[SYMBOL] = function () { return 7; };
|
1706
|
+
return ''[KEY](O) != 7;
|
1707
|
+
});
|
1708
|
+
|
1709
|
+
var DELEGATES_TO_EXEC = DELEGATES_TO_SYMBOL && !fails(function () {
|
1710
|
+
// Symbol-named RegExp methods call .exec
|
1711
|
+
var execCalled = false;
|
1712
|
+
var re = /a/;
|
1713
|
+
|
1714
|
+
if (KEY === 'split') {
|
1715
|
+
// We can't use real regex here since it causes deoptimization
|
1716
|
+
// and serious performance degradation in V8
|
1717
|
+
// https://github.com/zloirock/core-js/issues/306
|
1718
|
+
re = {};
|
1719
|
+
// RegExp[@@split] doesn't call the regex's exec method, but first creates
|
1720
|
+
// a new one. We need to return the patched regex when creating the new one.
|
1721
|
+
re.constructor = {};
|
1722
|
+
re.constructor[SPECIES$2] = function () { return re; };
|
1723
|
+
re.flags = '';
|
1724
|
+
re[SYMBOL] = /./[SYMBOL];
|
1725
|
+
}
|
1726
|
+
|
1727
|
+
re.exec = function () { execCalled = true; return null; };
|
1728
|
+
|
1729
|
+
re[SYMBOL]('');
|
1730
|
+
return !execCalled;
|
1731
|
+
});
|
1732
|
+
|
1733
|
+
if (
|
1734
|
+
!DELEGATES_TO_SYMBOL ||
|
1735
|
+
!DELEGATES_TO_EXEC ||
|
1736
|
+
(KEY === 'replace' && !(REPLACE_SUPPORTS_NAMED_GROUPS && REPLACE_KEEPS_$0)) ||
|
1737
|
+
(KEY === 'split' && !SPLIT_WORKS_WITH_OVERWRITTEN_EXEC)
|
1738
|
+
) {
|
1739
|
+
var nativeRegExpMethod = /./[SYMBOL];
|
1740
|
+
var methods = exec(SYMBOL, ''[KEY], function (nativeMethod, regexp, str, arg2, forceStringMethod) {
|
1741
|
+
if (regexp.exec === regexpExec) {
|
1742
|
+
if (DELEGATES_TO_SYMBOL && !forceStringMethod) {
|
1743
|
+
// The native String method already delegates to @@method (this
|
1744
|
+
// polyfilled function), leasing to infinite recursion.
|
1745
|
+
// We avoid it by directly calling the native @@method method.
|
1746
|
+
return { done: true, value: nativeRegExpMethod.call(regexp, str, arg2) };
|
1747
|
+
}
|
1748
|
+
return { done: true, value: nativeMethod.call(str, regexp, arg2) };
|
1749
|
+
}
|
1750
|
+
return { done: false };
|
1751
|
+
}, { REPLACE_KEEPS_$0: REPLACE_KEEPS_$0 });
|
1752
|
+
var stringMethod = methods[0];
|
1753
|
+
var regexMethod = methods[1];
|
1754
|
+
|
1755
|
+
redefine(String.prototype, KEY, stringMethod);
|
1756
|
+
redefine(RegExp.prototype, SYMBOL, length == 2
|
1757
|
+
// 21.2.5.8 RegExp.prototype[@@replace](string, replaceValue)
|
1758
|
+
// 21.2.5.11 RegExp.prototype[@@split](string, limit)
|
1759
|
+
? function (string, arg) { return regexMethod.call(string, this, arg); }
|
1760
|
+
// 21.2.5.6 RegExp.prototype[@@match](string)
|
1761
|
+
// 21.2.5.9 RegExp.prototype[@@search](string)
|
1762
|
+
: function (string) { return regexMethod.call(string, this); }
|
1763
|
+
);
|
1764
|
+
}
|
1765
|
+
|
1766
|
+
if (sham) createNonEnumerableProperty(RegExp.prototype[SYMBOL], 'sham', true);
|
1767
|
+
};
|
1768
|
+
|
1769
|
+
var charAt$1 = stringMultibyte.charAt;
|
1770
|
+
|
1771
|
+
// `AdvanceStringIndex` abstract operation
|
1772
|
+
// https://tc39.github.io/ecma262/#sec-advancestringindex
|
1773
|
+
var advanceStringIndex = function (S, index, unicode) {
|
1774
|
+
return index + (unicode ? charAt$1(S, index).length : 1);
|
1775
|
+
};
|
1776
|
+
|
1777
|
+
// `RegExpExec` abstract operation
|
1778
|
+
// https://tc39.github.io/ecma262/#sec-regexpexec
|
1779
|
+
var regexpExecAbstract = function (R, S) {
|
1780
|
+
var exec = R.exec;
|
1781
|
+
if (typeof exec === 'function') {
|
1782
|
+
var result = exec.call(R, S);
|
1783
|
+
if (typeof result !== 'object') {
|
1784
|
+
throw TypeError('RegExp exec method returned something other than an Object or null');
|
1785
|
+
}
|
1786
|
+
return result;
|
1787
|
+
}
|
1788
|
+
|
1789
|
+
if (classofRaw(R) !== 'RegExp') {
|
1790
|
+
throw TypeError('RegExp#exec called on incompatible receiver');
|
1791
|
+
}
|
1792
|
+
|
1793
|
+
return regexpExec.call(R, S);
|
1794
|
+
};
|
1795
|
+
|
1796
|
+
var max$1 = Math.max;
|
1797
|
+
var min$2 = Math.min;
|
1798
|
+
var floor$1 = Math.floor;
|
1799
|
+
var SUBSTITUTION_SYMBOLS = /\$([$&'`]|\d\d?|<[^>]*>)/g;
|
1800
|
+
var SUBSTITUTION_SYMBOLS_NO_NAMED = /\$([$&'`]|\d\d?)/g;
|
1801
|
+
|
1802
|
+
var maybeToString = function (it) {
|
1803
|
+
return it === undefined ? it : String(it);
|
1804
|
+
};
|
1805
|
+
|
1806
|
+
// @@replace logic
|
1807
|
+
fixRegexpWellKnownSymbolLogic('replace', 2, function (REPLACE, nativeReplace, maybeCallNative, reason) {
|
1808
|
+
return [
|
1809
|
+
// `String.prototype.replace` method
|
1810
|
+
// https://tc39.github.io/ecma262/#sec-string.prototype.replace
|
1811
|
+
function replace(searchValue, replaceValue) {
|
1812
|
+
var O = requireObjectCoercible(this);
|
1813
|
+
var replacer = searchValue == undefined ? undefined : searchValue[REPLACE];
|
1814
|
+
return replacer !== undefined
|
1815
|
+
? replacer.call(searchValue, O, replaceValue)
|
1816
|
+
: nativeReplace.call(String(O), searchValue, replaceValue);
|
1817
|
+
},
|
1818
|
+
// `RegExp.prototype[@@replace]` method
|
1819
|
+
// https://tc39.github.io/ecma262/#sec-regexp.prototype-@@replace
|
1820
|
+
function (regexp, replaceValue) {
|
1821
|
+
if (reason.REPLACE_KEEPS_$0 || (typeof replaceValue === 'string' && replaceValue.indexOf('$0') === -1)) {
|
1822
|
+
var res = maybeCallNative(nativeReplace, regexp, this, replaceValue);
|
1823
|
+
if (res.done) return res.value;
|
1824
|
+
}
|
1825
|
+
|
1826
|
+
var rx = anObject(regexp);
|
1827
|
+
var S = String(this);
|
1828
|
+
|
1829
|
+
var functionalReplace = typeof replaceValue === 'function';
|
1830
|
+
if (!functionalReplace) replaceValue = String(replaceValue);
|
1831
|
+
|
1832
|
+
var global = rx.global;
|
1833
|
+
if (global) {
|
1834
|
+
var fullUnicode = rx.unicode;
|
1835
|
+
rx.lastIndex = 0;
|
1836
|
+
}
|
1837
|
+
var results = [];
|
1838
|
+
while (true) {
|
1839
|
+
var result = regexpExecAbstract(rx, S);
|
1840
|
+
if (result === null) break;
|
1841
|
+
|
1842
|
+
results.push(result);
|
1843
|
+
if (!global) break;
|
1844
|
+
|
1845
|
+
var matchStr = String(result[0]);
|
1846
|
+
if (matchStr === '') rx.lastIndex = advanceStringIndex(S, toLength(rx.lastIndex), fullUnicode);
|
1847
|
+
}
|
1848
|
+
|
1849
|
+
var accumulatedResult = '';
|
1850
|
+
var nextSourcePosition = 0;
|
1851
|
+
for (var i = 0; i < results.length; i++) {
|
1852
|
+
result = results[i];
|
1853
|
+
|
1854
|
+
var matched = String(result[0]);
|
1855
|
+
var position = max$1(min$2(toInteger(result.index), S.length), 0);
|
1856
|
+
var captures = [];
|
1857
|
+
// NOTE: This is equivalent to
|
1858
|
+
// captures = result.slice(1).map(maybeToString)
|
1859
|
+
// but for some reason `nativeSlice.call(result, 1, result.length)` (called in
|
1860
|
+
// the slice polyfill when slicing native arrays) "doesn't work" in safari 9 and
|
1861
|
+
// causes a crash (https://pastebin.com/N21QzeQA) when trying to debug it.
|
1862
|
+
for (var j = 1; j < result.length; j++) captures.push(maybeToString(result[j]));
|
1863
|
+
var namedCaptures = result.groups;
|
1864
|
+
if (functionalReplace) {
|
1865
|
+
var replacerArgs = [matched].concat(captures, position, S);
|
1866
|
+
if (namedCaptures !== undefined) replacerArgs.push(namedCaptures);
|
1867
|
+
var replacement = String(replaceValue.apply(undefined, replacerArgs));
|
1868
|
+
} else {
|
1869
|
+
replacement = getSubstitution(matched, S, position, captures, namedCaptures, replaceValue);
|
1870
|
+
}
|
1871
|
+
if (position >= nextSourcePosition) {
|
1872
|
+
accumulatedResult += S.slice(nextSourcePosition, position) + replacement;
|
1873
|
+
nextSourcePosition = position + matched.length;
|
1874
|
+
}
|
1875
|
+
}
|
1876
|
+
return accumulatedResult + S.slice(nextSourcePosition);
|
1877
|
+
}
|
1878
|
+
];
|
1879
|
+
|
1880
|
+
// https://tc39.github.io/ecma262/#sec-getsubstitution
|
1881
|
+
function getSubstitution(matched, str, position, captures, namedCaptures, replacement) {
|
1882
|
+
var tailPos = position + matched.length;
|
1883
|
+
var m = captures.length;
|
1884
|
+
var symbols = SUBSTITUTION_SYMBOLS_NO_NAMED;
|
1885
|
+
if (namedCaptures !== undefined) {
|
1886
|
+
namedCaptures = toObject(namedCaptures);
|
1887
|
+
symbols = SUBSTITUTION_SYMBOLS;
|
1888
|
+
}
|
1889
|
+
return nativeReplace.call(replacement, symbols, function (match, ch) {
|
1890
|
+
var capture;
|
1891
|
+
switch (ch.charAt(0)) {
|
1892
|
+
case '$': return '$';
|
1893
|
+
case '&': return matched;
|
1894
|
+
case '`': return str.slice(0, position);
|
1895
|
+
case "'": return str.slice(tailPos);
|
1896
|
+
case '<':
|
1897
|
+
capture = namedCaptures[ch.slice(1, -1)];
|
1898
|
+
break;
|
1899
|
+
default: // \d\d?
|
1900
|
+
var n = +ch;
|
1901
|
+
if (n === 0) return match;
|
1902
|
+
if (n > m) {
|
1903
|
+
var f = floor$1(n / 10);
|
1904
|
+
if (f === 0) return match;
|
1905
|
+
if (f <= m) return captures[f - 1] === undefined ? ch.charAt(1) : captures[f - 1] + ch.charAt(1);
|
1906
|
+
return match;
|
1907
|
+
}
|
1908
|
+
capture = captures[n - 1];
|
1909
|
+
}
|
1910
|
+
return capture === undefined ? '' : capture;
|
1911
|
+
});
|
1912
|
+
}
|
1913
|
+
});
|
1914
|
+
|
1915
|
+
// iterable DOM collections
|
1916
|
+
// flag - `iterable` interface - 'entries', 'keys', 'values', 'forEach' methods
|
1917
|
+
var domIterables = {
|
1918
|
+
CSSRuleList: 0,
|
1919
|
+
CSSStyleDeclaration: 0,
|
1920
|
+
CSSValueList: 0,
|
1921
|
+
ClientRectList: 0,
|
1922
|
+
DOMRectList: 0,
|
1923
|
+
DOMStringList: 0,
|
1924
|
+
DOMTokenList: 1,
|
1925
|
+
DataTransferItemList: 0,
|
1926
|
+
FileList: 0,
|
1927
|
+
HTMLAllCollection: 0,
|
1928
|
+
HTMLCollection: 0,
|
1929
|
+
HTMLFormElement: 0,
|
1930
|
+
HTMLSelectElement: 0,
|
1931
|
+
MediaList: 0,
|
1932
|
+
MimeTypeArray: 0,
|
1933
|
+
NamedNodeMap: 0,
|
1934
|
+
NodeList: 1,
|
1935
|
+
PaintRequestList: 0,
|
1936
|
+
Plugin: 0,
|
1937
|
+
PluginArray: 0,
|
1938
|
+
SVGLengthList: 0,
|
1939
|
+
SVGNumberList: 0,
|
1940
|
+
SVGPathSegList: 0,
|
1941
|
+
SVGPointList: 0,
|
1942
|
+
SVGStringList: 0,
|
1943
|
+
SVGTransformList: 0,
|
1944
|
+
SourceBufferList: 0,
|
1945
|
+
StyleSheetList: 0,
|
1946
|
+
TextTrackCueList: 0,
|
1947
|
+
TextTrackList: 0,
|
1948
|
+
TouchList: 0
|
1949
|
+
};
|
1950
|
+
|
1951
|
+
var ITERATOR$2 = wellKnownSymbol('iterator');
|
1952
|
+
var TO_STRING_TAG$3 = wellKnownSymbol('toStringTag');
|
1953
|
+
var ArrayValues = es_array_iterator.values;
|
1954
|
+
|
1955
|
+
for (var COLLECTION_NAME in domIterables) {
|
1956
|
+
var Collection = global_1[COLLECTION_NAME];
|
1957
|
+
var CollectionPrototype = Collection && Collection.prototype;
|
1958
|
+
if (CollectionPrototype) {
|
1959
|
+
// some Chrome versions have non-configurable methods on DOMTokenList
|
1960
|
+
if (CollectionPrototype[ITERATOR$2] !== ArrayValues) try {
|
1961
|
+
createNonEnumerableProperty(CollectionPrototype, ITERATOR$2, ArrayValues);
|
1962
|
+
} catch (error) {
|
1963
|
+
CollectionPrototype[ITERATOR$2] = ArrayValues;
|
1964
|
+
}
|
1965
|
+
if (!CollectionPrototype[TO_STRING_TAG$3]) {
|
1966
|
+
createNonEnumerableProperty(CollectionPrototype, TO_STRING_TAG$3, COLLECTION_NAME);
|
1967
|
+
}
|
1968
|
+
if (domIterables[COLLECTION_NAME]) for (var METHOD_NAME in es_array_iterator) {
|
1969
|
+
// some Chrome versions have non-configurable methods on DOMTokenList
|
1970
|
+
if (CollectionPrototype[METHOD_NAME] !== es_array_iterator[METHOD_NAME]) try {
|
1971
|
+
createNonEnumerableProperty(CollectionPrototype, METHOD_NAME, es_array_iterator[METHOD_NAME]);
|
1972
|
+
} catch (error) {
|
1973
|
+
CollectionPrototype[METHOD_NAME] = es_array_iterator[METHOD_NAME];
|
1974
|
+
}
|
1975
|
+
}
|
1976
|
+
}
|
1977
|
+
}
|
1978
|
+
|
1979
|
+
function _defineProperty(obj, key, value) {
|
1980
|
+
if (key in obj) {
|
1981
|
+
Object.defineProperty(obj, key, {
|
1982
|
+
value: value,
|
1983
|
+
enumerable: true,
|
1984
|
+
configurable: true,
|
1985
|
+
writable: true
|
1986
|
+
});
|
1987
|
+
} else {
|
1988
|
+
obj[key] = value;
|
1989
|
+
}
|
1990
|
+
|
1991
|
+
return obj;
|
1992
|
+
}
|
1993
|
+
|
1994
|
+
function ownKeys$1(object, enumerableOnly) {
|
1995
|
+
var keys = Object.keys(object);
|
1996
|
+
|
1997
|
+
if (Object.getOwnPropertySymbols) {
|
1998
|
+
var symbols = Object.getOwnPropertySymbols(object);
|
1999
|
+
if (enumerableOnly) symbols = symbols.filter(function (sym) {
|
2000
|
+
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
2001
|
+
});
|
2002
|
+
keys.push.apply(keys, symbols);
|
2003
|
+
}
|
2004
|
+
|
2005
|
+
return keys;
|
2006
|
+
}
|
2007
|
+
|
2008
|
+
function _objectSpread2(target) {
|
2009
|
+
for (var i = 1; i < arguments.length; i++) {
|
2010
|
+
var source = arguments[i] != null ? arguments[i] : {};
|
2011
|
+
|
2012
|
+
if (i % 2) {
|
2013
|
+
ownKeys$1(Object(source), true).forEach(function (key) {
|
2014
|
+
_defineProperty(target, key, source[key]);
|
2015
|
+
});
|
2016
|
+
} else if (Object.getOwnPropertyDescriptors) {
|
2017
|
+
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
2018
|
+
} else {
|
2019
|
+
ownKeys$1(Object(source)).forEach(function (key) {
|
2020
|
+
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
2021
|
+
});
|
2022
|
+
}
|
2023
|
+
}
|
2024
|
+
|
2025
|
+
return target;
|
2026
|
+
}
|
2027
|
+
|
2028
|
+
function _toConsumableArray(arr) {
|
2029
|
+
return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread();
|
2030
|
+
}
|
2031
|
+
|
2032
|
+
function _arrayWithoutHoles(arr) {
|
2033
|
+
if (Array.isArray(arr)) {
|
2034
|
+
for (var i = 0, arr2 = new Array(arr.length); i < arr.length; i++) arr2[i] = arr[i];
|
2035
|
+
|
2036
|
+
return arr2;
|
2037
|
+
}
|
2038
|
+
}
|
2039
|
+
|
2040
|
+
function _iterableToArray(iter) {
|
2041
|
+
if (Symbol.iterator in Object(iter) || Object.prototype.toString.call(iter) === "[object Arguments]") return Array.from(iter);
|
2042
|
+
}
|
2043
|
+
|
2044
|
+
function _nonIterableSpread() {
|
2045
|
+
throw new TypeError("Invalid attempt to spread non-iterable instance");
|
2046
|
+
}
|
2047
|
+
|
2048
|
+
//
|
2049
|
+
//
|
2050
|
+
//
|
2051
|
+
//
|
2052
|
+
var $ = window.jQuery;
|
2053
|
+
|
2054
|
+
var deepCopy = function deepCopy(arg) {
|
2055
|
+
return $.extend(true, Array.isArray(arg) ? [] : {}, arg);
|
2056
|
+
};
|
2057
|
+
|
2058
|
+
var script = {
|
2059
|
+
name: 'BootstrapTable',
|
2060
|
+
props: {
|
2061
|
+
columns: {
|
2062
|
+
type: Array,
|
2063
|
+
require: true
|
2064
|
+
},
|
2065
|
+
data: {
|
2066
|
+
type: [Array, Object],
|
2067
|
+
default: function _default() {
|
2068
|
+
return undefined;
|
2069
|
+
}
|
2070
|
+
},
|
2071
|
+
options: {
|
2072
|
+
type: Object,
|
2073
|
+
default: function _default() {
|
2074
|
+
return {};
|
2075
|
+
}
|
2076
|
+
}
|
2077
|
+
},
|
2078
|
+
mounted: function mounted() {
|
2079
|
+
var _this = this;
|
2080
|
+
|
2081
|
+
this.$table = $(this.$el);
|
2082
|
+
this.$table.on('all.bs.table', function (e, name, args) {
|
2083
|
+
var eventName = $.fn.bootstrapTable.events[name];
|
2084
|
+
eventName = eventName.replace(/([A-Z])/g, '-$1').toLowerCase();
|
2085
|
+
|
2086
|
+
_this.$emit.apply(_this, [eventName].concat(_toConsumableArray(args)));
|
2087
|
+
});
|
2088
|
+
|
2089
|
+
this._initTable();
|
2090
|
+
},
|
2091
|
+
methods: _objectSpread2({
|
2092
|
+
_initTable: function _initTable() {
|
2093
|
+
var options = _objectSpread2({}, deepCopy(this.options), {
|
2094
|
+
columns: deepCopy(this.columns),
|
2095
|
+
data: deepCopy(this.data)
|
2096
|
+
});
|
2097
|
+
|
2098
|
+
if (!this._hasInit) {
|
2099
|
+
this.$table.bootstrapTable(options);
|
2100
|
+
this._hasInit = true;
|
2101
|
+
} else {
|
2102
|
+
this.refreshOptions(options);
|
2103
|
+
}
|
2104
|
+
}
|
2105
|
+
}, function () {
|
2106
|
+
var res = {};
|
2107
|
+
var _iteratorNormalCompletion = true;
|
2108
|
+
var _didIteratorError = false;
|
2109
|
+
var _iteratorError = undefined;
|
2110
|
+
|
2111
|
+
try {
|
2112
|
+
var _loop = function _loop() {
|
2113
|
+
var method = _step.value;
|
2114
|
+
|
2115
|
+
res[method] = function () {
|
2116
|
+
var _this$$table;
|
2117
|
+
|
2118
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
2119
|
+
args[_key] = arguments[_key];
|
2120
|
+
}
|
2121
|
+
|
2122
|
+
return (_this$$table = this.$table).bootstrapTable.apply(_this$$table, [method].concat(args));
|
2123
|
+
};
|
2124
|
+
};
|
2125
|
+
|
2126
|
+
for (var _iterator = $.fn.bootstrapTable.methods[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
|
2127
|
+
_loop();
|
2128
|
+
}
|
2129
|
+
} catch (err) {
|
2130
|
+
_didIteratorError = true;
|
2131
|
+
_iteratorError = err;
|
2132
|
+
} finally {
|
2133
|
+
try {
|
2134
|
+
if (!_iteratorNormalCompletion && _iterator.return != null) {
|
2135
|
+
_iterator.return();
|
2136
|
+
}
|
2137
|
+
} finally {
|
2138
|
+
if (_didIteratorError) {
|
2139
|
+
throw _iteratorError;
|
2140
|
+
}
|
2141
|
+
}
|
2142
|
+
}
|
2143
|
+
|
2144
|
+
return res;
|
2145
|
+
}()),
|
2146
|
+
watch: {
|
2147
|
+
options: {
|
2148
|
+
handler: function handler() {
|
2149
|
+
this._initTable();
|
2150
|
+
},
|
2151
|
+
deep: true
|
2152
|
+
},
|
2153
|
+
columns: {
|
2154
|
+
handler: function handler() {
|
2155
|
+
this._initTable();
|
2156
|
+
},
|
2157
|
+
deep: true
|
2158
|
+
},
|
2159
|
+
data: {
|
2160
|
+
handler: function handler() {
|
2161
|
+
this.load(deepCopy(this.data));
|
2162
|
+
},
|
2163
|
+
deep: true
|
2164
|
+
}
|
2165
|
+
}
|
2166
|
+
};
|
2167
|
+
|
2168
|
+
function normalizeComponent(template, style, script, scopeId, isFunctionalTemplate, moduleIdentifier /* server only */, shadowMode, createInjector, createInjectorSSR, createInjectorShadow) {
|
2169
|
+
if (typeof shadowMode !== 'boolean') {
|
2170
|
+
createInjectorSSR = createInjector;
|
2171
|
+
createInjector = shadowMode;
|
2172
|
+
shadowMode = false;
|
2173
|
+
}
|
2174
|
+
// Vue.extend constructor export interop.
|
2175
|
+
const options = typeof script === 'function' ? script.options : script;
|
2176
|
+
// render functions
|
2177
|
+
if (template && template.render) {
|
2178
|
+
options.render = template.render;
|
2179
|
+
options.staticRenderFns = template.staticRenderFns;
|
2180
|
+
options._compiled = true;
|
2181
|
+
// functional template
|
2182
|
+
if (isFunctionalTemplate) {
|
2183
|
+
options.functional = true;
|
2184
|
+
}
|
2185
|
+
}
|
2186
|
+
// scopedId
|
2187
|
+
if (scopeId) {
|
2188
|
+
options._scopeId = scopeId;
|
2189
|
+
}
|
2190
|
+
let hook;
|
2191
|
+
if (moduleIdentifier) {
|
2192
|
+
// server build
|
2193
|
+
hook = function (context) {
|
2194
|
+
// 2.3 injection
|
2195
|
+
context =
|
2196
|
+
context || // cached call
|
2197
|
+
(this.$vnode && this.$vnode.ssrContext) || // stateful
|
2198
|
+
(this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext); // functional
|
2199
|
+
// 2.2 with runInNewContext: true
|
2200
|
+
if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {
|
2201
|
+
context = __VUE_SSR_CONTEXT__;
|
2202
|
+
}
|
2203
|
+
// inject component styles
|
2204
|
+
if (style) {
|
2205
|
+
style.call(this, createInjectorSSR(context));
|
2206
|
+
}
|
2207
|
+
// register component module identifier for async chunk inference
|
2208
|
+
if (context && context._registeredComponents) {
|
2209
|
+
context._registeredComponents.add(moduleIdentifier);
|
2210
|
+
}
|
2211
|
+
};
|
2212
|
+
// used by ssr in case component is cached and beforeCreate
|
2213
|
+
// never gets called
|
2214
|
+
options._ssrRegister = hook;
|
2215
|
+
}
|
2216
|
+
else if (style) {
|
2217
|
+
hook = shadowMode
|
2218
|
+
? function (context) {
|
2219
|
+
style.call(this, createInjectorShadow(context, this.$root.$options.shadowRoot));
|
2220
|
+
}
|
2221
|
+
: function (context) {
|
2222
|
+
style.call(this, createInjector(context));
|
2223
|
+
};
|
2224
|
+
}
|
2225
|
+
if (hook) {
|
2226
|
+
if (options.functional) {
|
2227
|
+
// register for functional component in vue file
|
2228
|
+
const originalRender = options.render;
|
2229
|
+
options.render = function renderWithStyleInjection(h, context) {
|
2230
|
+
hook.call(context);
|
2231
|
+
return originalRender(h, context);
|
2232
|
+
};
|
2233
|
+
}
|
2234
|
+
else {
|
2235
|
+
// inject component registration as beforeCreate hook
|
2236
|
+
const existing = options.beforeCreate;
|
2237
|
+
options.beforeCreate = existing ? [].concat(existing, hook) : [hook];
|
2238
|
+
}
|
2239
|
+
}
|
2240
|
+
return script;
|
2241
|
+
}
|
2242
|
+
|
2243
|
+
/* script */
|
2244
|
+
const __vue_script__ = script;
|
2245
|
+
|
2246
|
+
/* template */
|
2247
|
+
var __vue_render__ = function() {
|
2248
|
+
var _vm = this;
|
2249
|
+
var _h = _vm.$createElement;
|
2250
|
+
var _c = _vm._self._c || _h;
|
2251
|
+
return _c("table")
|
2252
|
+
};
|
2253
|
+
var __vue_staticRenderFns__ = [];
|
2254
|
+
__vue_render__._withStripped = true;
|
2255
|
+
|
2256
|
+
/* style */
|
2257
|
+
const __vue_inject_styles__ = undefined;
|
2258
|
+
/* scoped */
|
2259
|
+
const __vue_scope_id__ = undefined;
|
2260
|
+
/* module identifier */
|
2261
|
+
const __vue_module_identifier__ = undefined;
|
2262
|
+
/* functional template */
|
2263
|
+
const __vue_is_functional_template__ = false;
|
2264
|
+
/* style inject */
|
2265
|
+
|
2266
|
+
/* style inject SSR */
|
2267
|
+
|
2268
|
+
/* style inject shadow dom */
|
2269
|
+
|
2270
|
+
|
2271
|
+
|
2272
|
+
const __vue_component__ = normalizeComponent(
|
2273
|
+
{ render: __vue_render__, staticRenderFns: __vue_staticRenderFns__ },
|
2274
|
+
__vue_inject_styles__,
|
2275
|
+
__vue_script__,
|
2276
|
+
__vue_scope_id__,
|
2277
|
+
__vue_is_functional_template__,
|
2278
|
+
__vue_module_identifier__,
|
2279
|
+
false,
|
2280
|
+
undefined,
|
2281
|
+
undefined,
|
2282
|
+
undefined
|
2283
|
+
);
|
2284
|
+
|
2285
|
+
return __vue_component__;
|
2286
|
+
|
2287
|
+
})));
|