@danielgindi/dom-utils 1.0.2 → 1.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/lib.cjs.js CHANGED
@@ -1,27 +1,11 @@
1
1
  /*!
2
- * @danielgindi/dom-utils 1.0.2
2
+ * @danielgindi/dom-utils 1.0.6
3
3
  * git://github.com/danielgindi/dom-utils.git
4
4
  */
5
5
  'use strict';
6
6
 
7
7
  Object.defineProperty(exports, '__esModule', { value: true });
8
8
 
9
- function _typeof(obj) {
10
- "@babel/helpers - typeof";
11
-
12
- if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
13
- _typeof = function (obj) {
14
- return typeof obj;
15
- };
16
- } else {
17
- _typeof = function (obj) {
18
- return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
19
- };
20
- }
21
-
22
- return _typeof(obj);
23
- }
24
-
25
9
  var REACT_ELEMENT_TYPE;
26
10
 
27
11
  function _jsx(type, props, key, children) {
@@ -63,29 +47,142 @@ function _jsx(type, props, key, children) {
63
47
  return {
64
48
  $$typeof: REACT_ELEMENT_TYPE,
65
49
  type: type,
66
- key: key === undefined ? null : '' + key,
50
+ key: key === undefined ? null : "" + key,
67
51
  ref: null,
68
52
  props: props,
69
53
  _owner: null
70
54
  };
71
55
  }
72
56
 
73
- function _asyncIterator(iterable) {
74
- var method;
57
+ function ownKeys$2(object, enumerableOnly) {
58
+ var keys = Object.keys(object);
75
59
 
76
- if (typeof Symbol !== "undefined") {
77
- if (Symbol.asyncIterator) {
78
- method = iterable[Symbol.asyncIterator];
79
- if (method != null) return method.call(iterable);
60
+ if (Object.getOwnPropertySymbols) {
61
+ var symbols = Object.getOwnPropertySymbols(object);
62
+
63
+ if (enumerableOnly) {
64
+ symbols = symbols.filter(function (sym) {
65
+ return Object.getOwnPropertyDescriptor(object, sym).enumerable;
66
+ });
67
+ }
68
+
69
+ keys.push.apply(keys, symbols);
70
+ }
71
+
72
+ return keys;
73
+ }
74
+
75
+ function _objectSpread2(target) {
76
+ for (var i = 1; i < arguments.length; i++) {
77
+ var source = arguments[i] != null ? arguments[i] : {};
78
+
79
+ if (i % 2) {
80
+ ownKeys$2(Object(source), true).forEach(function (key) {
81
+ _defineProperty(target, key, source[key]);
82
+ });
83
+ } else if (Object.getOwnPropertyDescriptors) {
84
+ Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
85
+ } else {
86
+ ownKeys$2(Object(source)).forEach(function (key) {
87
+ Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
88
+ });
80
89
  }
90
+ }
91
+
92
+ return target;
93
+ }
94
+
95
+ function _typeof(obj) {
96
+ "@babel/helpers - typeof";
97
+
98
+ if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
99
+ _typeof = function (obj) {
100
+ return typeof obj;
101
+ };
102
+ } else {
103
+ _typeof = function (obj) {
104
+ return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
105
+ };
106
+ }
107
+
108
+ return _typeof(obj);
109
+ }
81
110
 
82
- if (Symbol.iterator) {
83
- method = iterable[Symbol.iterator];
84
- if (method != null) return method.call(iterable);
111
+ function _wrapRegExp() {
112
+ _wrapRegExp = function (re, groups) {
113
+ return new BabelRegExp(re, undefined, groups);
114
+ };
115
+
116
+ var _super = RegExp.prototype;
117
+
118
+ var _groups = new WeakMap();
119
+
120
+ function BabelRegExp(re, flags, groups) {
121
+ var _this = new RegExp(re, flags);
122
+
123
+ _groups.set(_this, groups || _groups.get(re));
124
+
125
+ return _setPrototypeOf(_this, BabelRegExp.prototype);
126
+ }
127
+
128
+ _inherits(BabelRegExp, RegExp);
129
+
130
+ BabelRegExp.prototype.exec = function (str) {
131
+ var result = _super.exec.call(this, str);
132
+
133
+ if (result) result.groups = buildGroups(result, this);
134
+ return result;
135
+ };
136
+
137
+ BabelRegExp.prototype[Symbol.replace] = function (str, substitution) {
138
+ if (typeof substitution === "string") {
139
+ var groups = _groups.get(this);
140
+
141
+ return _super[Symbol.replace].call(this, str, substitution.replace(/\$<([^>]+)>/g, function (_, name) {
142
+ return "$" + groups[name];
143
+ }));
144
+ } else if (typeof substitution === "function") {
145
+ var _this = this;
146
+
147
+ return _super[Symbol.replace].call(this, str, function () {
148
+ var args = arguments;
149
+
150
+ if (typeof args[args.length - 1] !== "object") {
151
+ args = [].slice.call(args);
152
+ args.push(buildGroups(args, _this));
153
+ }
154
+
155
+ return substitution.apply(this, args);
156
+ });
157
+ } else {
158
+ return _super[Symbol.replace].call(this, str, substitution);
85
159
  }
160
+ };
161
+
162
+ function buildGroups(result, re) {
163
+ var g = _groups.get(re);
164
+
165
+ return Object.keys(g).reduce(function (groups, name) {
166
+ groups[name] = result[g[name]];
167
+ return groups;
168
+ }, Object.create(null));
169
+ }
170
+
171
+ return _wrapRegExp.apply(this, arguments);
172
+ }
173
+
174
+ function _asyncIterator(iterable) {
175
+ var method;
176
+
177
+ if (typeof Symbol !== "undefined") {
178
+ if (Symbol.asyncIterator) method = iterable[Symbol.asyncIterator];
179
+ if (method == null && Symbol.iterator) method = iterable[Symbol.iterator];
86
180
  }
87
181
 
88
- throw new TypeError("Object is not async iterable");
182
+ if (method == null) method = iterable["@@asyncIterator"];
183
+ if (method == null) method = iterable["@@iterator"];
184
+ if (method == null) throw new TypeError("Object is not async iterable");
185
+ return method.call(iterable);
89
186
  }
90
187
 
91
188
  function _AwaitValue(value) {
@@ -171,11 +268,9 @@ function _AsyncGenerator(gen) {
171
268
  }
172
269
  }
173
270
 
174
- if (typeof Symbol === "function" && Symbol.asyncIterator) {
175
- _AsyncGenerator.prototype[Symbol.asyncIterator] = function () {
176
- return this;
177
- };
178
- }
271
+ _AsyncGenerator.prototype[typeof Symbol === "function" && Symbol.asyncIterator || "@@asyncIterator"] = function () {
272
+ return this;
273
+ };
179
274
 
180
275
  _AsyncGenerator.prototype.next = function (arg) {
181
276
  return this._invoke("next", arg);
@@ -216,11 +311,9 @@ function _asyncGeneratorDelegate(inner, awaitWrap) {
216
311
 
217
312
  ;
218
313
 
219
- if (typeof Symbol === "function" && Symbol.iterator) {
220
- iter[Symbol.iterator] = function () {
221
- return this;
222
- };
223
- }
314
+ iter[typeof Symbol !== "undefined" && Symbol.iterator || "@@iterator"] = function () {
315
+ return this;
316
+ };
224
317
 
225
318
  iter.next = function (value) {
226
319
  if (waiting) {
@@ -391,7 +484,7 @@ function _objectSpread(target) {
391
484
  var ownKeys = Object.keys(source);
392
485
 
393
486
  if (typeof Object.getOwnPropertySymbols === 'function') {
394
- ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) {
487
+ ownKeys.push.apply(ownKeys, Object.getOwnPropertySymbols(source).filter(function (sym) {
395
488
  return Object.getOwnPropertyDescriptor(source, sym).enumerable;
396
489
  }));
397
490
  }
@@ -404,40 +497,6 @@ function _objectSpread(target) {
404
497
  return target;
405
498
  }
406
499
 
407
- function ownKeys$1(object, enumerableOnly) {
408
- var keys = Object.keys(object);
409
-
410
- if (Object.getOwnPropertySymbols) {
411
- var symbols = Object.getOwnPropertySymbols(object);
412
- if (enumerableOnly) symbols = symbols.filter(function (sym) {
413
- return Object.getOwnPropertyDescriptor(object, sym).enumerable;
414
- });
415
- keys.push.apply(keys, symbols);
416
- }
417
-
418
- return keys;
419
- }
420
-
421
- function _objectSpread2(target) {
422
- for (var i = 1; i < arguments.length; i++) {
423
- var source = arguments[i] != null ? arguments[i] : {};
424
-
425
- if (i % 2) {
426
- ownKeys$1(Object(source), true).forEach(function (key) {
427
- _defineProperty(target, key, source[key]);
428
- });
429
- } else if (Object.getOwnPropertyDescriptors) {
430
- Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
431
- } else {
432
- ownKeys$1(Object(source)).forEach(function (key) {
433
- Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
434
- });
435
- }
436
- }
437
-
438
- return target;
439
- }
440
-
441
500
  function _inherits(subClass, superClass) {
442
501
  if (typeof superClass !== "function" && superClass !== null) {
443
502
  throw new TypeError("Super expression must either be null or a function");
@@ -558,19 +617,17 @@ function _interopRequireDefault(obj) {
558
617
  };
559
618
  }
560
619
 
561
- function _getRequireWildcardCache() {
620
+ function _getRequireWildcardCache(nodeInterop) {
562
621
  if (typeof WeakMap !== "function") return null;
563
- var cache = new WeakMap();
564
-
565
- _getRequireWildcardCache = function () {
566
- return cache;
567
- };
568
-
569
- return cache;
622
+ var cacheBabelInterop = new WeakMap();
623
+ var cacheNodeInterop = new WeakMap();
624
+ return (_getRequireWildcardCache = function (nodeInterop) {
625
+ return nodeInterop ? cacheNodeInterop : cacheBabelInterop;
626
+ })(nodeInterop);
570
627
  }
571
628
 
572
- function _interopRequireWildcard(obj) {
573
- if (obj && obj.__esModule) {
629
+ function _interopRequireWildcard(obj, nodeInterop) {
630
+ if (!nodeInterop && obj && obj.__esModule) {
574
631
  return obj;
575
632
  }
576
633
 
@@ -580,7 +637,7 @@ function _interopRequireWildcard(obj) {
580
637
  };
581
638
  }
582
639
 
583
- var cache = _getRequireWildcardCache();
640
+ var cache = _getRequireWildcardCache(nodeInterop);
584
641
 
585
642
  if (cache && cache.has(obj)) {
586
643
  return cache.get(obj);
@@ -590,7 +647,7 @@ function _interopRequireWildcard(obj) {
590
647
  var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
591
648
 
592
649
  for (var key in obj) {
593
- if (Object.prototype.hasOwnProperty.call(obj, key)) {
650
+ if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
594
651
  var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;
595
652
 
596
653
  if (desc && (desc.get || desc.set)) {
@@ -667,6 +724,8 @@ function _assertThisInitialized(self) {
667
724
  function _possibleConstructorReturn(self, call) {
668
725
  if (call && (typeof call === "object" || typeof call === "function")) {
669
726
  return call;
727
+ } else if (call !== void 0) {
728
+ throw new TypeError("Derived constructors may only return object or undefined");
670
729
  }
671
730
 
672
731
  return _assertThisInitialized(self);
@@ -848,18 +907,21 @@ function _maybeArrayLike(next, arr, i) {
848
907
  }
849
908
 
850
909
  function _iterableToArray(iter) {
851
- if (typeof Symbol !== "undefined" && Symbol.iterator in Object(iter)) return Array.from(iter);
910
+ if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
852
911
  }
853
912
 
854
913
  function _iterableToArrayLimit(arr, i) {
855
- if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return;
914
+ var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
915
+
916
+ if (_i == null) return;
856
917
  var _arr = [];
857
918
  var _n = true;
858
919
  var _d = false;
859
- var _e = undefined;
920
+
921
+ var _s, _e;
860
922
 
861
923
  try {
862
- for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {
924
+ for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) {
863
925
  _arr.push(_s.value);
864
926
 
865
927
  if (i && _arr.length === i) break;
@@ -879,10 +941,12 @@ function _iterableToArrayLimit(arr, i) {
879
941
  }
880
942
 
881
943
  function _iterableToArrayLimitLoose(arr, i) {
882
- if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return;
944
+ var _i = arr && (typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]);
945
+
946
+ if (_i == null) return;
883
947
  var _arr = [];
884
948
 
885
- for (var _iterator = arr[Symbol.iterator](), _step; !(_step = _iterator.next()).done;) {
949
+ for (_i = _i.call(arr), _step; !(_step = _i.next()).done;) {
886
950
  _arr.push(_step.value);
887
951
 
888
952
  if (i && _arr.length === i) break;
@@ -917,9 +981,9 @@ function _nonIterableRest() {
917
981
  }
918
982
 
919
983
  function _createForOfIteratorHelper(o, allowArrayLike) {
920
- var it;
984
+ var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"];
921
985
 
922
- if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) {
986
+ if (!it) {
923
987
  if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
924
988
  if (it) o = it;
925
989
  var i = 0;
@@ -952,7 +1016,7 @@ function _createForOfIteratorHelper(o, allowArrayLike) {
952
1016
  err;
953
1017
  return {
954
1018
  s: function () {
955
- it = o[Symbol.iterator]();
1019
+ it = it.call(o);
956
1020
  },
957
1021
  n: function () {
958
1022
  var step = it.next();
@@ -974,28 +1038,24 @@ function _createForOfIteratorHelper(o, allowArrayLike) {
974
1038
  }
975
1039
 
976
1040
  function _createForOfIteratorHelperLoose(o, allowArrayLike) {
977
- var it;
1041
+ var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"];
1042
+ if (it) return (it = it.call(o)).next.bind(it);
978
1043
 
979
- if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) {
980
- if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
981
- if (it) o = it;
982
- var i = 0;
983
- return function () {
984
- if (i >= o.length) return {
985
- done: true
986
- };
987
- return {
988
- done: false,
989
- value: o[i++]
990
- };
1044
+ if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
1045
+ if (it) o = it;
1046
+ var i = 0;
1047
+ return function () {
1048
+ if (i >= o.length) return {
1049
+ done: true
991
1050
  };
992
- }
993
-
994
- throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
1051
+ return {
1052
+ done: false,
1053
+ value: o[i++]
1054
+ };
1055
+ };
995
1056
  }
996
1057
 
997
- it = o[Symbol.iterator]();
998
- return it.next.bind(it);
1058
+ throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
999
1059
  }
1000
1060
 
1001
1061
  function _skipFirstGeneratorNext(fn) {
@@ -1083,12 +1143,62 @@ function _classPrivateFieldLooseBase(receiver, privateKey) {
1083
1143
  }
1084
1144
 
1085
1145
  function _classPrivateFieldGet(receiver, privateMap) {
1086
- var descriptor = privateMap.get(receiver);
1146
+ var descriptor = _classExtractFieldDescriptor(receiver, privateMap, "get");
1087
1147
 
1088
- if (!descriptor) {
1089
- throw new TypeError("attempted to get private field on non-instance");
1148
+ return _classApplyDescriptorGet(receiver, descriptor);
1149
+ }
1150
+
1151
+ function _classPrivateFieldSet(receiver, privateMap, value) {
1152
+ var descriptor = _classExtractFieldDescriptor(receiver, privateMap, "set");
1153
+
1154
+ _classApplyDescriptorSet(receiver, descriptor, value);
1155
+
1156
+ return value;
1157
+ }
1158
+
1159
+ function _classPrivateFieldDestructureSet(receiver, privateMap) {
1160
+ var descriptor = _classExtractFieldDescriptor(receiver, privateMap, "set");
1161
+
1162
+ return _classApplyDescriptorDestructureSet(receiver, descriptor);
1163
+ }
1164
+
1165
+ function _classExtractFieldDescriptor(receiver, privateMap, action) {
1166
+ if (!privateMap.has(receiver)) {
1167
+ throw new TypeError("attempted to " + action + " private field on non-instance");
1090
1168
  }
1091
1169
 
1170
+ return privateMap.get(receiver);
1171
+ }
1172
+
1173
+ function _classStaticPrivateFieldSpecGet(receiver, classConstructor, descriptor) {
1174
+ _classCheckPrivateStaticAccess(receiver, classConstructor);
1175
+
1176
+ _classCheckPrivateStaticFieldDescriptor(descriptor, "get");
1177
+
1178
+ return _classApplyDescriptorGet(receiver, descriptor);
1179
+ }
1180
+
1181
+ function _classStaticPrivateFieldSpecSet(receiver, classConstructor, descriptor, value) {
1182
+ _classCheckPrivateStaticAccess(receiver, classConstructor);
1183
+
1184
+ _classCheckPrivateStaticFieldDescriptor(descriptor, "set");
1185
+
1186
+ _classApplyDescriptorSet(receiver, descriptor, value);
1187
+
1188
+ return value;
1189
+ }
1190
+
1191
+ function _classStaticPrivateMethodGet(receiver, classConstructor, method) {
1192
+ _classCheckPrivateStaticAccess(receiver, classConstructor);
1193
+
1194
+ return method;
1195
+ }
1196
+
1197
+ function _classStaticPrivateMethodSet() {
1198
+ throw new TypeError("attempted to set read only static private field");
1199
+ }
1200
+
1201
+ function _classApplyDescriptorGet(receiver, descriptor) {
1092
1202
  if (descriptor.get) {
1093
1203
  return descriptor.get.call(receiver);
1094
1204
  }
@@ -1096,13 +1206,7 @@ function _classPrivateFieldGet(receiver, privateMap) {
1096
1206
  return descriptor.value;
1097
1207
  }
1098
1208
 
1099
- function _classPrivateFieldSet(receiver, privateMap, value) {
1100
- var descriptor = privateMap.get(receiver);
1101
-
1102
- if (!descriptor) {
1103
- throw new TypeError("attempted to set private field on non-instance");
1104
- }
1105
-
1209
+ function _classApplyDescriptorSet(receiver, descriptor, value) {
1106
1210
  if (descriptor.set) {
1107
1211
  descriptor.set.call(receiver, value);
1108
1212
  } else {
@@ -1112,17 +1216,9 @@ function _classPrivateFieldSet(receiver, privateMap, value) {
1112
1216
 
1113
1217
  descriptor.value = value;
1114
1218
  }
1115
-
1116
- return value;
1117
1219
  }
1118
1220
 
1119
- function _classPrivateFieldDestructureSet(receiver, privateMap) {
1120
- if (!privateMap.has(receiver)) {
1121
- throw new TypeError("attempted to set private field on non-instance");
1122
- }
1123
-
1124
- var descriptor = privateMap.get(receiver);
1125
-
1221
+ function _classApplyDescriptorDestructureSet(receiver, descriptor) {
1126
1222
  if (descriptor.set) {
1127
1223
  if (!("__destrObj" in descriptor)) {
1128
1224
  descriptor.__destrObj = {
@@ -1143,46 +1239,24 @@ function _classPrivateFieldDestructureSet(receiver, privateMap) {
1143
1239
  }
1144
1240
  }
1145
1241
 
1146
- function _classStaticPrivateFieldSpecGet(receiver, classConstructor, descriptor) {
1147
- if (receiver !== classConstructor) {
1148
- throw new TypeError("Private static access of wrong provenance");
1149
- }
1242
+ function _classStaticPrivateFieldDestructureSet(receiver, classConstructor, descriptor) {
1243
+ _classCheckPrivateStaticAccess(receiver, classConstructor);
1150
1244
 
1151
- if (descriptor.get) {
1152
- return descriptor.get.call(receiver);
1153
- }
1245
+ _classCheckPrivateStaticFieldDescriptor(descriptor, "set");
1154
1246
 
1155
- return descriptor.value;
1247
+ return _classApplyDescriptorDestructureSet(receiver, descriptor);
1156
1248
  }
1157
1249
 
1158
- function _classStaticPrivateFieldSpecSet(receiver, classConstructor, descriptor, value) {
1250
+ function _classCheckPrivateStaticAccess(receiver, classConstructor) {
1159
1251
  if (receiver !== classConstructor) {
1160
1252
  throw new TypeError("Private static access of wrong provenance");
1161
1253
  }
1162
-
1163
- if (descriptor.set) {
1164
- descriptor.set.call(receiver, value);
1165
- } else {
1166
- if (!descriptor.writable) {
1167
- throw new TypeError("attempted to set read only private field");
1168
- }
1169
-
1170
- descriptor.value = value;
1171
- }
1172
-
1173
- return value;
1174
1254
  }
1175
1255
 
1176
- function _classStaticPrivateMethodGet(receiver, classConstructor, method) {
1177
- if (receiver !== classConstructor) {
1178
- throw new TypeError("Private static access of wrong provenance");
1256
+ function _classCheckPrivateStaticFieldDescriptor(descriptor, action) {
1257
+ if (descriptor === undefined) {
1258
+ throw new TypeError("attempted to " + action + " private static field before its declaration");
1179
1259
  }
1180
-
1181
- return method;
1182
- }
1183
-
1184
- function _classStaticPrivateMethodSet() {
1185
- throw new TypeError("attempted to set read only static private field");
1186
1260
  }
1187
1261
 
1188
1262
  function _decorate(decorators, factory, superClass, mixins) {
@@ -1590,108 +1664,81 @@ function _classPrivateMethodGet(receiver, privateSet, fn) {
1590
1664
  return fn;
1591
1665
  }
1592
1666
 
1593
- function _classPrivateMethodSet() {
1594
- throw new TypeError("attempted to reassign private method");
1595
- }
1596
-
1597
- function _wrapRegExp(re, groups) {
1598
- _wrapRegExp = function (re, groups) {
1599
- return new BabelRegExp(re, undefined, groups);
1600
- };
1601
-
1602
- var _RegExp = _wrapNativeSuper(RegExp);
1603
-
1604
- var _super = RegExp.prototype;
1605
-
1606
- var _groups = new WeakMap();
1607
-
1608
- function BabelRegExp(re, flags, groups) {
1609
- var _this = _RegExp.call(this, re, flags);
1610
-
1611
- _groups.set(_this, groups || _groups.get(re));
1612
-
1613
- return _this;
1667
+ function _checkPrivateRedeclaration(obj, privateCollection) {
1668
+ if (privateCollection.has(obj)) {
1669
+ throw new TypeError("Cannot initialize the same private elements twice on an object");
1614
1670
  }
1671
+ }
1615
1672
 
1616
- _inherits(BabelRegExp, _RegExp);
1617
-
1618
- BabelRegExp.prototype.exec = function (str) {
1619
- var result = _super.exec.call(this, str);
1620
-
1621
- if (result) result.groups = buildGroups(result, this);
1622
- return result;
1623
- };
1624
-
1625
- BabelRegExp.prototype[Symbol.replace] = function (str, substitution) {
1626
- if (typeof substitution === "string") {
1627
- var groups = _groups.get(this);
1628
-
1629
- return _super[Symbol.replace].call(this, str, substitution.replace(/\$<([^>]+)>/g, function (_, name) {
1630
- return "$" + groups[name];
1631
- }));
1632
- } else if (typeof substitution === "function") {
1633
- var _this = this;
1634
-
1635
- return _super[Symbol.replace].call(this, str, function () {
1636
- var args = [];
1637
- args.push.apply(args, arguments);
1638
-
1639
- if (typeof args[args.length - 1] !== "object") {
1640
- args.push(buildGroups(args, _this));
1641
- }
1673
+ function _classPrivateFieldInitSpec(obj, privateMap, value) {
1674
+ _checkPrivateRedeclaration(obj, privateMap);
1642
1675
 
1643
- return substitution.apply(this, args);
1644
- });
1645
- } else {
1646
- return _super[Symbol.replace].call(this, str, substitution);
1647
- }
1648
- };
1676
+ privateMap.set(obj, value);
1677
+ }
1649
1678
 
1650
- function buildGroups(result, re) {
1651
- var g = _groups.get(re);
1679
+ function _classPrivateMethodInitSpec(obj, privateSet) {
1680
+ _checkPrivateRedeclaration(obj, privateSet);
1652
1681
 
1653
- return Object.keys(g).reduce(function (groups, name) {
1654
- groups[name] = result[g[name]];
1655
- return groups;
1656
- }, Object.create(null));
1657
- }
1682
+ privateSet.add(obj);
1683
+ }
1658
1684
 
1659
- return _wrapRegExp.apply(this, arguments);
1685
+ function _classPrivateMethodSet() {
1686
+ throw new TypeError("attempted to reassign private method");
1660
1687
  }
1661
1688
 
1662
1689
  var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
1663
1690
 
1664
- function commonjsRequire () {
1665
- throw new Error('Dynamic requires are not currently supported by rollup-plugin-commonjs');
1691
+ function getDefaultExportFromCjs (x) {
1692
+ return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
1693
+ }
1694
+
1695
+ function getDefaultExportFromNamespaceIfPresent (n) {
1696
+ return n && Object.prototype.hasOwnProperty.call(n, 'default') ? n['default'] : n;
1666
1697
  }
1667
1698
 
1668
- function unwrapExports (x) {
1669
- return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
1699
+ function getDefaultExportFromNamespaceIfNotNamed (n) {
1700
+ return n && Object.prototype.hasOwnProperty.call(n, 'default') && Object.keys(n).length === 1 ? n['default'] : n;
1670
1701
  }
1671
1702
 
1672
- function createCommonjsModule(fn, module) {
1673
- return module = { exports: {} }, fn(module, module.exports), module.exports;
1703
+ function getAugmentedNamespace(n) {
1704
+ if (n.__esModule) return n;
1705
+ var a = Object.defineProperty({}, '__esModule', {value: true});
1706
+ Object.keys(n).forEach(function (k) {
1707
+ var d = Object.getOwnPropertyDescriptor(n, k);
1708
+ Object.defineProperty(a, k, d.get ? d : {
1709
+ enumerable: true,
1710
+ get: function () {
1711
+ return n[k];
1712
+ }
1713
+ });
1714
+ });
1715
+ return a;
1674
1716
  }
1675
1717
 
1676
- function getCjsExportFromNamespace (n) {
1677
- return n && n['default'] || n;
1718
+ function commonjsRequire (path) {
1719
+ throw new Error('Could not dynamically require "' + path + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
1678
1720
  }
1679
1721
 
1722
+ var es_object_entries = {};
1723
+
1680
1724
  var check = function (it) {
1681
1725
  return it && it.Math == Math && it;
1682
1726
  };
1683
1727
 
1684
1728
  // https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
1685
- var global_1 =
1686
- /* global globalThis -- safe */
1729
+ var global$e =
1730
+ // eslint-disable-next-line es/no-global-this -- safe
1687
1731
  check(typeof globalThis == 'object' && globalThis) ||
1688
1732
  check(typeof window == 'object' && window) ||
1733
+ // eslint-disable-next-line no-restricted-globals -- safe
1689
1734
  check(typeof self == 'object' && self) ||
1690
1735
  check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
1691
1736
  // eslint-disable-next-line no-new-func -- fallback
1692
1737
  (function () { return this; })() || Function('return this')();
1693
1738
 
1694
- var fails = function (exec) {
1739
+ var objectGetOwnPropertyDescriptor = {};
1740
+
1741
+ var fails$f = function (exec) {
1695
1742
  try {
1696
1743
  return !!exec();
1697
1744
  } catch (error) {
@@ -1699,30 +1746,32 @@ var fails = function (exec) {
1699
1746
  }
1700
1747
  };
1701
1748
 
1749
+ var fails$e = fails$f;
1750
+
1702
1751
  // Detect IE8's incomplete defineProperty implementation
1703
- var descriptors = !fails(function () {
1752
+ var descriptors = !fails$e(function () {
1753
+ // eslint-disable-next-line es/no-object-defineproperty -- required for testing
1704
1754
  return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] != 7;
1705
1755
  });
1706
1756
 
1757
+ var objectPropertyIsEnumerable = {};
1758
+
1707
1759
  'use strict';
1708
- var nativePropertyIsEnumerable = {}.propertyIsEnumerable;
1709
- var getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
1760
+ var $propertyIsEnumerable = {}.propertyIsEnumerable;
1761
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
1762
+ var getOwnPropertyDescriptor$2 = Object.getOwnPropertyDescriptor;
1710
1763
 
1711
1764
  // Nashorn ~ JDK8 bug
1712
- var NASHORN_BUG = getOwnPropertyDescriptor$1 && !nativePropertyIsEnumerable.call({ 1: 2 }, 1);
1765
+ var NASHORN_BUG = getOwnPropertyDescriptor$2 && !$propertyIsEnumerable.call({ 1: 2 }, 1);
1713
1766
 
1714
1767
  // `Object.prototype.propertyIsEnumerable` method implementation
1715
1768
  // https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable
1716
- var f$4 = NASHORN_BUG ? function propertyIsEnumerable(V) {
1717
- var descriptor = getOwnPropertyDescriptor$1(this, V);
1769
+ var f$4 = objectPropertyIsEnumerable.f = NASHORN_BUG ? function propertyIsEnumerable(V) {
1770
+ var descriptor = getOwnPropertyDescriptor$2(this, V);
1718
1771
  return !!descriptor && descriptor.enumerable;
1719
- } : nativePropertyIsEnumerable;
1720
-
1721
- var objectPropertyIsEnumerable = {
1722
- f: f$4
1723
- };
1772
+ } : $propertyIsEnumerable;
1724
1773
 
1725
- var createPropertyDescriptor = function (bitmap, value) {
1774
+ var createPropertyDescriptor$2 = function (bitmap, value) {
1726
1775
  return {
1727
1776
  enumerable: !(bitmap & 1),
1728
1777
  configurable: !(bitmap & 2),
@@ -1731,182 +1780,413 @@ var createPropertyDescriptor = function (bitmap, value) {
1731
1780
  };
1732
1781
  };
1733
1782
 
1734
- var toString = {}.toString;
1783
+ var toString$8 = {}.toString;
1735
1784
 
1736
- var classofRaw = function (it) {
1737
- return toString.call(it).slice(8, -1);
1785
+ var classofRaw$1 = function (it) {
1786
+ return toString$8.call(it).slice(8, -1);
1738
1787
  };
1739
1788
 
1789
+ var fails$d = fails$f;
1790
+ var classof$6 = classofRaw$1;
1791
+
1740
1792
  var split = ''.split;
1741
1793
 
1742
1794
  // fallback for non-array-like ES3 and non-enumerable old V8 strings
1743
- var indexedObject = fails(function () {
1795
+ var indexedObject = fails$d(function () {
1744
1796
  // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
1745
1797
  // eslint-disable-next-line no-prototype-builtins -- safe
1746
1798
  return !Object('z').propertyIsEnumerable(0);
1747
1799
  }) ? function (it) {
1748
- return classofRaw(it) == 'String' ? split.call(it, '') : Object(it);
1800
+ return classof$6(it) == 'String' ? split.call(it, '') : Object(it);
1749
1801
  } : Object;
1750
1802
 
1751
1803
  // `RequireObjectCoercible` abstract operation
1752
1804
  // https://tc39.es/ecma262/#sec-requireobjectcoercible
1753
- var requireObjectCoercible = function (it) {
1805
+ var requireObjectCoercible$8 = function (it) {
1754
1806
  if (it == undefined) throw TypeError("Can't call method on " + it);
1755
1807
  return it;
1756
1808
  };
1757
1809
 
1758
1810
  // toObject with fallback for non-array-like ES3 strings
1811
+ var IndexedObject$2 = indexedObject;
1812
+ var requireObjectCoercible$7 = requireObjectCoercible$8;
1813
+
1814
+ var toIndexedObject$4 = function (it) {
1815
+ return IndexedObject$2(requireObjectCoercible$7(it));
1816
+ };
1759
1817
 
1818
+ // `IsCallable` abstract operation
1819
+ // https://tc39.es/ecma262/#sec-iscallable
1820
+ var isCallable$d = function (argument) {
1821
+ return typeof argument === 'function';
1822
+ };
1760
1823
 
1824
+ var isCallable$c = isCallable$d;
1761
1825
 
1762
- var toIndexedObject = function (it) {
1763
- return indexedObject(requireObjectCoercible(it));
1826
+ var isObject$7 = function (it) {
1827
+ return typeof it === 'object' ? it !== null : isCallable$c(it);
1764
1828
  };
1765
1829
 
1766
- var isObject = function (it) {
1767
- return typeof it === 'object' ? it !== null : typeof it === 'function';
1830
+ var global$d = global$e;
1831
+ var isCallable$b = isCallable$d;
1832
+
1833
+ var aFunction = function (argument) {
1834
+ return isCallable$b(argument) ? argument : undefined;
1768
1835
  };
1769
1836
 
1770
- // `ToPrimitive` abstract operation
1771
- // https://tc39.es/ecma262/#sec-toprimitive
1772
- // instead of the ES6 spec version, we didn't implement @@toPrimitive case
1773
- // and the second argument - flag - preferred type is a string
1774
- var toPrimitive = function (input, PREFERRED_STRING) {
1775
- if (!isObject(input)) return input;
1837
+ var getBuiltIn$5 = function (namespace, method) {
1838
+ return arguments.length < 2 ? aFunction(global$d[namespace]) : global$d[namespace] && global$d[namespace][method];
1839
+ };
1840
+
1841
+ var getBuiltIn$4 = getBuiltIn$5;
1842
+
1843
+ var engineUserAgent = getBuiltIn$4('navigator', 'userAgent') || '';
1844
+
1845
+ var global$c = global$e;
1846
+ var userAgent = engineUserAgent;
1847
+
1848
+ var process = global$c.process;
1849
+ var Deno = global$c.Deno;
1850
+ var versions = process && process.versions || Deno && Deno.version;
1851
+ var v8 = versions && versions.v8;
1852
+ var match, version;
1853
+
1854
+ if (v8) {
1855
+ match = v8.split('.');
1856
+ version = match[0] < 4 ? 1 : match[0] + match[1];
1857
+ } else if (userAgent) {
1858
+ match = userAgent.match(/Edge\/(\d+)/);
1859
+ if (!match || match[1] >= 74) {
1860
+ match = userAgent.match(/Chrome\/(\d+)/);
1861
+ if (match) version = match[1];
1862
+ }
1863
+ }
1864
+
1865
+ var engineV8Version = version && +version;
1866
+
1867
+ /* eslint-disable es/no-symbol -- required for testing */
1868
+
1869
+ var V8_VERSION$1 = engineV8Version;
1870
+ var fails$c = fails$f;
1871
+
1872
+ // eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
1873
+ var nativeSymbol = !!Object.getOwnPropertySymbols && !fails$c(function () {
1874
+ var symbol = Symbol();
1875
+ // Chrome 38 Symbol has incorrect toString conversion
1876
+ // `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
1877
+ return !String(symbol) || !(Object(symbol) instanceof Symbol) ||
1878
+ // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances
1879
+ !Symbol.sham && V8_VERSION$1 && V8_VERSION$1 < 41;
1880
+ });
1881
+
1882
+ /* eslint-disable es/no-symbol -- required for testing */
1883
+
1884
+ var NATIVE_SYMBOL$1 = nativeSymbol;
1885
+
1886
+ var useSymbolAsUid = NATIVE_SYMBOL$1
1887
+ && !Symbol.sham
1888
+ && typeof Symbol.iterator == 'symbol';
1889
+
1890
+ var isCallable$a = isCallable$d;
1891
+ var getBuiltIn$3 = getBuiltIn$5;
1892
+ var USE_SYMBOL_AS_UID$1 = useSymbolAsUid;
1893
+
1894
+ var isSymbol$2 = USE_SYMBOL_AS_UID$1 ? function (it) {
1895
+ return typeof it == 'symbol';
1896
+ } : function (it) {
1897
+ var $Symbol = getBuiltIn$3('Symbol');
1898
+ return isCallable$a($Symbol) && Object(it) instanceof $Symbol;
1899
+ };
1900
+
1901
+ var tryToString$2 = function (argument) {
1902
+ try {
1903
+ return String(argument);
1904
+ } catch (error) {
1905
+ return 'Object';
1906
+ }
1907
+ };
1908
+
1909
+ var isCallable$9 = isCallable$d;
1910
+ var tryToString$1 = tryToString$2;
1911
+
1912
+ // `Assert: IsCallable(argument) is true`
1913
+ var aCallable$2 = function (argument) {
1914
+ if (isCallable$9(argument)) return argument;
1915
+ throw TypeError(tryToString$1(argument) + ' is not a function');
1916
+ };
1917
+
1918
+ var aCallable$1 = aCallable$2;
1919
+
1920
+ // `GetMethod` abstract operation
1921
+ // https://tc39.es/ecma262/#sec-getmethod
1922
+ var getMethod$4 = function (V, P) {
1923
+ var func = V[P];
1924
+ return func == null ? undefined : aCallable$1(func);
1925
+ };
1926
+
1927
+ var isCallable$8 = isCallable$d;
1928
+ var isObject$6 = isObject$7;
1929
+
1930
+ // `OrdinaryToPrimitive` abstract operation
1931
+ // https://tc39.es/ecma262/#sec-ordinarytoprimitive
1932
+ var ordinaryToPrimitive$1 = function (input, pref) {
1776
1933
  var fn, val;
1777
- if (PREFERRED_STRING && typeof (fn = input.toString) == 'function' && !isObject(val = fn.call(input))) return val;
1778
- if (typeof (fn = input.valueOf) == 'function' && !isObject(val = fn.call(input))) return val;
1779
- if (!PREFERRED_STRING && typeof (fn = input.toString) == 'function' && !isObject(val = fn.call(input))) return val;
1934
+ if (pref === 'string' && isCallable$8(fn = input.toString) && !isObject$6(val = fn.call(input))) return val;
1935
+ if (isCallable$8(fn = input.valueOf) && !isObject$6(val = fn.call(input))) return val;
1936
+ if (pref !== 'string' && isCallable$8(fn = input.toString) && !isObject$6(val = fn.call(input))) return val;
1780
1937
  throw TypeError("Can't convert object to primitive value");
1781
1938
  };
1782
1939
 
1940
+ var shared$5 = {exports: {}};
1941
+
1942
+ var isPure = false;
1943
+
1944
+ var global$b = global$e;
1945
+
1946
+ var setGlobal$3 = function (key, value) {
1947
+ try {
1948
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
1949
+ Object.defineProperty(global$b, key, { value: value, configurable: true, writable: true });
1950
+ } catch (error) {
1951
+ global$b[key] = value;
1952
+ } return value;
1953
+ };
1954
+
1955
+ var global$a = global$e;
1956
+ var setGlobal$2 = setGlobal$3;
1957
+
1958
+ var SHARED = '__core-js_shared__';
1959
+ var store$3 = global$a[SHARED] || setGlobal$2(SHARED, {});
1960
+
1961
+ var sharedStore = store$3;
1962
+
1963
+ var IS_PURE$1 = isPure;
1964
+ var store$2 = sharedStore;
1965
+
1966
+ (shared$5.exports = function (key, value) {
1967
+ return store$2[key] || (store$2[key] = value !== undefined ? value : {});
1968
+ })('versions', []).push({
1969
+ version: '3.18.2',
1970
+ mode: IS_PURE$1 ? 'pure' : 'global',
1971
+ copyright: '© 2021 Denis Pushkarev (zloirock.ru)'
1972
+ });
1973
+
1974
+ var shared$4 = shared$5.exports;
1975
+
1976
+ var requireObjectCoercible$6 = requireObjectCoercible$8;
1977
+
1978
+ // `ToObject` abstract operation
1979
+ // https://tc39.es/ecma262/#sec-toobject
1980
+ var toObject$4 = function (argument) {
1981
+ return Object(requireObjectCoercible$6(argument));
1982
+ };
1983
+
1984
+ var toObject$3 = toObject$4;
1985
+
1783
1986
  var hasOwnProperty = {}.hasOwnProperty;
1784
1987
 
1785
- var has$1 = function (it, key) {
1786
- return hasOwnProperty.call(it, key);
1988
+ // `HasOwnProperty` abstract operation
1989
+ // https://tc39.es/ecma262/#sec-hasownproperty
1990
+ var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
1991
+ return hasOwnProperty.call(toObject$3(it), key);
1992
+ };
1993
+
1994
+ var id = 0;
1995
+ var postfix = Math.random();
1996
+
1997
+ var uid$2 = function (key) {
1998
+ return 'Symbol(' + String(key === undefined ? '' : key) + ')_' + (++id + postfix).toString(36);
1999
+ };
2000
+
2001
+ var global$9 = global$e;
2002
+ var shared$3 = shared$5.exports;
2003
+ var hasOwn$6 = hasOwnProperty_1;
2004
+ var uid$1 = uid$2;
2005
+ var NATIVE_SYMBOL = nativeSymbol;
2006
+ var USE_SYMBOL_AS_UID = useSymbolAsUid;
2007
+
2008
+ var WellKnownSymbolsStore = shared$3('wks');
2009
+ var Symbol$1 = global$9.Symbol;
2010
+ var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid$1;
2011
+
2012
+ var wellKnownSymbol$a = function (name) {
2013
+ if (!hasOwn$6(WellKnownSymbolsStore, name) || !(NATIVE_SYMBOL || typeof WellKnownSymbolsStore[name] == 'string')) {
2014
+ if (NATIVE_SYMBOL && hasOwn$6(Symbol$1, name)) {
2015
+ WellKnownSymbolsStore[name] = Symbol$1[name];
2016
+ } else {
2017
+ WellKnownSymbolsStore[name] = createWellKnownSymbol('Symbol.' + name);
2018
+ }
2019
+ } return WellKnownSymbolsStore[name];
2020
+ };
2021
+
2022
+ var isObject$5 = isObject$7;
2023
+ var isSymbol$1 = isSymbol$2;
2024
+ var getMethod$3 = getMethod$4;
2025
+ var ordinaryToPrimitive = ordinaryToPrimitive$1;
2026
+ var wellKnownSymbol$9 = wellKnownSymbol$a;
2027
+
2028
+ var TO_PRIMITIVE = wellKnownSymbol$9('toPrimitive');
2029
+
2030
+ // `ToPrimitive` abstract operation
2031
+ // https://tc39.es/ecma262/#sec-toprimitive
2032
+ var toPrimitive$1 = function (input, pref) {
2033
+ if (!isObject$5(input) || isSymbol$1(input)) return input;
2034
+ var exoticToPrim = getMethod$3(input, TO_PRIMITIVE);
2035
+ var result;
2036
+ if (exoticToPrim) {
2037
+ if (pref === undefined) pref = 'default';
2038
+ result = exoticToPrim.call(input, pref);
2039
+ if (!isObject$5(result) || isSymbol$1(result)) return result;
2040
+ throw TypeError("Can't convert object to primitive value");
2041
+ }
2042
+ if (pref === undefined) pref = 'number';
2043
+ return ordinaryToPrimitive(input, pref);
2044
+ };
2045
+
2046
+ var toPrimitive = toPrimitive$1;
2047
+ var isSymbol = isSymbol$2;
2048
+
2049
+ // `ToPropertyKey` abstract operation
2050
+ // https://tc39.es/ecma262/#sec-topropertykey
2051
+ var toPropertyKey$2 = function (argument) {
2052
+ var key = toPrimitive(argument, 'string');
2053
+ return isSymbol(key) ? key : String(key);
1787
2054
  };
1788
2055
 
1789
- var document$1 = global_1.document;
2056
+ var global$8 = global$e;
2057
+ var isObject$4 = isObject$7;
2058
+
2059
+ var document$1 = global$8.document;
1790
2060
  // typeof document.createElement is 'object' in old IE
1791
- var EXISTS = isObject(document$1) && isObject(document$1.createElement);
2061
+ var EXISTS$1 = isObject$4(document$1) && isObject$4(document$1.createElement);
1792
2062
 
1793
- var documentCreateElement = function (it) {
1794
- return EXISTS ? document$1.createElement(it) : {};
2063
+ var documentCreateElement$1 = function (it) {
2064
+ return EXISTS$1 ? document$1.createElement(it) : {};
1795
2065
  };
1796
2066
 
2067
+ var DESCRIPTORS$8 = descriptors;
2068
+ var fails$b = fails$f;
2069
+ var createElement$1 = documentCreateElement$1;
2070
+
1797
2071
  // Thank's IE8 for his funny defineProperty
1798
- var ie8DomDefine = !descriptors && !fails(function () {
1799
- return Object.defineProperty(documentCreateElement('div'), 'a', {
2072
+ var ie8DomDefine = !DESCRIPTORS$8 && !fails$b(function () {
2073
+ // eslint-disable-next-line es/no-object-defineproperty -- requied for testing
2074
+ return Object.defineProperty(createElement$1('div'), 'a', {
1800
2075
  get: function () { return 7; }
1801
2076
  }).a != 7;
1802
2077
  });
1803
2078
 
1804
- var nativeGetOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
2079
+ var DESCRIPTORS$7 = descriptors;
2080
+ var propertyIsEnumerableModule$1 = objectPropertyIsEnumerable;
2081
+ var createPropertyDescriptor$1 = createPropertyDescriptor$2;
2082
+ var toIndexedObject$3 = toIndexedObject$4;
2083
+ var toPropertyKey$1 = toPropertyKey$2;
2084
+ var hasOwn$5 = hasOwnProperty_1;
2085
+ var IE8_DOM_DEFINE$1 = ie8DomDefine;
2086
+
2087
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
2088
+ var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
1805
2089
 
1806
2090
  // `Object.getOwnPropertyDescriptor` method
1807
2091
  // https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
1808
- var f$3 = descriptors ? nativeGetOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {
1809
- O = toIndexedObject(O);
1810
- P = toPrimitive(P, true);
1811
- if (ie8DomDefine) try {
1812
- return nativeGetOwnPropertyDescriptor(O, P);
2092
+ var f$3 = objectGetOwnPropertyDescriptor.f = DESCRIPTORS$7 ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {
2093
+ O = toIndexedObject$3(O);
2094
+ P = toPropertyKey$1(P);
2095
+ if (IE8_DOM_DEFINE$1) try {
2096
+ return $getOwnPropertyDescriptor(O, P);
1813
2097
  } catch (error) { /* empty */ }
1814
- if (has$1(O, P)) return createPropertyDescriptor(!objectPropertyIsEnumerable.f.call(O, P), O[P]);
2098
+ if (hasOwn$5(O, P)) return createPropertyDescriptor$1(!propertyIsEnumerableModule$1.f.call(O, P), O[P]);
1815
2099
  };
1816
2100
 
1817
- var objectGetOwnPropertyDescriptor = {
1818
- f: f$3
1819
- };
2101
+ var objectDefineProperty = {};
1820
2102
 
1821
- var anObject = function (it) {
1822
- if (!isObject(it)) {
1823
- throw TypeError(String(it) + ' is not an object');
1824
- } return it;
2103
+ var isObject$3 = isObject$7;
2104
+
2105
+ // `Assert: Type(argument) is Object`
2106
+ var anObject$a = function (argument) {
2107
+ if (isObject$3(argument)) return argument;
2108
+ throw TypeError(String(argument) + ' is not an object');
1825
2109
  };
1826
2110
 
1827
- var nativeDefineProperty = Object.defineProperty;
2111
+ var DESCRIPTORS$6 = descriptors;
2112
+ var IE8_DOM_DEFINE = ie8DomDefine;
2113
+ var anObject$9 = anObject$a;
2114
+ var toPropertyKey = toPropertyKey$2;
2115
+
2116
+ // eslint-disable-next-line es/no-object-defineproperty -- safe
2117
+ var $defineProperty = Object.defineProperty;
1828
2118
 
1829
2119
  // `Object.defineProperty` method
1830
2120
  // https://tc39.es/ecma262/#sec-object.defineproperty
1831
- var f$2 = descriptors ? nativeDefineProperty : function defineProperty(O, P, Attributes) {
1832
- anObject(O);
1833
- P = toPrimitive(P, true);
1834
- anObject(Attributes);
1835
- if (ie8DomDefine) try {
1836
- return nativeDefineProperty(O, P, Attributes);
2121
+ var f$2 = objectDefineProperty.f = DESCRIPTORS$6 ? $defineProperty : function defineProperty(O, P, Attributes) {
2122
+ anObject$9(O);
2123
+ P = toPropertyKey(P);
2124
+ anObject$9(Attributes);
2125
+ if (IE8_DOM_DEFINE) try {
2126
+ return $defineProperty(O, P, Attributes);
1837
2127
  } catch (error) { /* empty */ }
1838
2128
  if ('get' in Attributes || 'set' in Attributes) throw TypeError('Accessors not supported');
1839
2129
  if ('value' in Attributes) O[P] = Attributes.value;
1840
2130
  return O;
1841
2131
  };
1842
2132
 
1843
- var objectDefineProperty = {
1844
- f: f$2
1845
- };
2133
+ var DESCRIPTORS$5 = descriptors;
2134
+ var definePropertyModule$2 = objectDefineProperty;
2135
+ var createPropertyDescriptor = createPropertyDescriptor$2;
1846
2136
 
1847
- var createNonEnumerableProperty = descriptors ? function (object, key, value) {
1848
- return objectDefineProperty.f(object, key, createPropertyDescriptor(1, value));
2137
+ var createNonEnumerableProperty$4 = DESCRIPTORS$5 ? function (object, key, value) {
2138
+ return definePropertyModule$2.f(object, key, createPropertyDescriptor(1, value));
1849
2139
  } : function (object, key, value) {
1850
2140
  object[key] = value;
1851
2141
  return object;
1852
2142
  };
1853
2143
 
1854
- var setGlobal = function (key, value) {
1855
- try {
1856
- createNonEnumerableProperty(global_1, key, value);
1857
- } catch (error) {
1858
- global_1[key] = value;
1859
- } return value;
1860
- };
1861
-
1862
- var SHARED = '__core-js_shared__';
1863
- var store$1 = global_1[SHARED] || setGlobal(SHARED, {});
2144
+ var redefine$3 = {exports: {}};
1864
2145
 
1865
- var sharedStore = store$1;
2146
+ var isCallable$7 = isCallable$d;
2147
+ var store$1 = sharedStore;
1866
2148
 
1867
2149
  var functionToString = Function.toString;
1868
2150
 
1869
- // this helper broken in `3.4.1-3.4.4`, so we can't use `shared` helper
1870
- if (typeof sharedStore.inspectSource != 'function') {
1871
- sharedStore.inspectSource = function (it) {
2151
+ // this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper
2152
+ if (!isCallable$7(store$1.inspectSource)) {
2153
+ store$1.inspectSource = function (it) {
1872
2154
  return functionToString.call(it);
1873
2155
  };
1874
2156
  }
1875
2157
 
1876
- var inspectSource = sharedStore.inspectSource;
1877
-
1878
- var WeakMap$2 = global_1.WeakMap;
2158
+ var inspectSource$3 = store$1.inspectSource;
1879
2159
 
1880
- var nativeWeakMap = typeof WeakMap$2 === 'function' && /native code/.test(inspectSource(WeakMap$2));
2160
+ var global$7 = global$e;
2161
+ var isCallable$6 = isCallable$d;
2162
+ var inspectSource$2 = inspectSource$3;
1881
2163
 
1882
- var isPure = false;
1883
-
1884
- var shared = createCommonjsModule(function (module) {
1885
- (module.exports = function (key, value) {
1886
- return sharedStore[key] || (sharedStore[key] = value !== undefined ? value : {});
1887
- })('versions', []).push({
1888
- version: '3.9.1',
1889
- mode: isPure ? 'pure' : 'global',
1890
- copyright: '© 2021 Denis Pushkarev (zloirock.ru)'
1891
- });
1892
- });
2164
+ var WeakMap$2 = global$7.WeakMap;
1893
2165
 
1894
- var id = 0;
1895
- var postfix = Math.random();
2166
+ var nativeWeakMap = isCallable$6(WeakMap$2) && /native code/.test(inspectSource$2(WeakMap$2));
1896
2167
 
1897
- var uid = function (key) {
1898
- return 'Symbol(' + String(key === undefined ? '' : key) + ')_' + (++id + postfix).toString(36);
1899
- };
2168
+ var shared$2 = shared$5.exports;
2169
+ var uid = uid$2;
1900
2170
 
1901
- var keys = shared('keys');
2171
+ var keys = shared$2('keys');
1902
2172
 
1903
- var sharedKey = function (key) {
2173
+ var sharedKey$2 = function (key) {
1904
2174
  return keys[key] || (keys[key] = uid(key));
1905
2175
  };
1906
2176
 
1907
- var hiddenKeys$1 = {};
2177
+ var hiddenKeys$4 = {};
1908
2178
 
1909
- var WeakMap$1 = global_1.WeakMap;
2179
+ var NATIVE_WEAK_MAP = nativeWeakMap;
2180
+ var global$6 = global$e;
2181
+ var isObject$2 = isObject$7;
2182
+ var createNonEnumerableProperty$3 = createNonEnumerableProperty$4;
2183
+ var hasOwn$4 = hasOwnProperty_1;
2184
+ var shared$1 = sharedStore;
2185
+ var sharedKey$1 = sharedKey$2;
2186
+ var hiddenKeys$3 = hiddenKeys$4;
2187
+
2188
+ var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
2189
+ var WeakMap$1 = global$6.WeakMap;
1910
2190
  var set, get, has;
1911
2191
 
1912
2192
  var enforce = function (it) {
@@ -1916,18 +2196,19 @@ var enforce = function (it) {
1916
2196
  var getterFor = function (TYPE) {
1917
2197
  return function (it) {
1918
2198
  var state;
1919
- if (!isObject(it) || (state = get(it)).type !== TYPE) {
2199
+ if (!isObject$2(it) || (state = get(it)).type !== TYPE) {
1920
2200
  throw TypeError('Incompatible receiver, ' + TYPE + ' required');
1921
2201
  } return state;
1922
2202
  };
1923
2203
  };
1924
2204
 
1925
- if (nativeWeakMap) {
1926
- var store = sharedStore.state || (sharedStore.state = new WeakMap$1());
2205
+ if (NATIVE_WEAK_MAP || shared$1.state) {
2206
+ var store = shared$1.state || (shared$1.state = new WeakMap$1());
1927
2207
  var wmget = store.get;
1928
2208
  var wmhas = store.has;
1929
2209
  var wmset = store.set;
1930
2210
  set = function (it, metadata) {
2211
+ if (wmhas.call(store, it)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);
1931
2212
  metadata.facade = it;
1932
2213
  wmset.call(store, it, metadata);
1933
2214
  return metadata;
@@ -1939,18 +2220,19 @@ if (nativeWeakMap) {
1939
2220
  return wmhas.call(store, it);
1940
2221
  };
1941
2222
  } else {
1942
- var STATE = sharedKey('state');
1943
- hiddenKeys$1[STATE] = true;
2223
+ var STATE = sharedKey$1('state');
2224
+ hiddenKeys$3[STATE] = true;
1944
2225
  set = function (it, metadata) {
2226
+ if (hasOwn$4(it, STATE)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);
1945
2227
  metadata.facade = it;
1946
- createNonEnumerableProperty(it, STATE, metadata);
2228
+ createNonEnumerableProperty$3(it, STATE, metadata);
1947
2229
  return metadata;
1948
2230
  };
1949
2231
  get = function (it) {
1950
- return has$1(it, STATE) ? it[STATE] : {};
2232
+ return hasOwn$4(it, STATE) ? it[STATE] : {};
1951
2233
  };
1952
2234
  has = function (it) {
1953
- return has$1(it, STATE);
2235
+ return hasOwn$4(it, STATE);
1954
2236
  };
1955
2237
  }
1956
2238
 
@@ -1961,34 +2243,59 @@ var internalState = {
1961
2243
  enforce: enforce,
1962
2244
  getterFor: getterFor
1963
2245
  };
1964
- var internalState_1 = internalState.set;
1965
- var internalState_2 = internalState.get;
1966
- var internalState_3 = internalState.has;
1967
- var internalState_4 = internalState.enforce;
1968
- var internalState_5 = internalState.getterFor;
1969
2246
 
1970
- var redefine = createCommonjsModule(function (module) {
1971
- var getInternalState = internalState.get;
1972
- var enforceInternalState = internalState.enforce;
2247
+ var DESCRIPTORS$4 = descriptors;
2248
+ var hasOwn$3 = hasOwnProperty_1;
2249
+
2250
+ var FunctionPrototype$1 = Function.prototype;
2251
+ // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
2252
+ var getDescriptor = DESCRIPTORS$4 && Object.getOwnPropertyDescriptor;
2253
+
2254
+ var EXISTS = hasOwn$3(FunctionPrototype$1, 'name');
2255
+ // additional protection from minified / mangled / dropped function names
2256
+ var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';
2257
+ var CONFIGURABLE = EXISTS && (!DESCRIPTORS$4 || (DESCRIPTORS$4 && getDescriptor(FunctionPrototype$1, 'name').configurable));
2258
+
2259
+ var functionName = {
2260
+ EXISTS: EXISTS,
2261
+ PROPER: PROPER,
2262
+ CONFIGURABLE: CONFIGURABLE
2263
+ };
2264
+
2265
+ var global$5 = global$e;
2266
+ var isCallable$5 = isCallable$d;
2267
+ var hasOwn$2 = hasOwnProperty_1;
2268
+ var createNonEnumerableProperty$2 = createNonEnumerableProperty$4;
2269
+ var setGlobal$1 = setGlobal$3;
2270
+ var inspectSource$1 = inspectSource$3;
2271
+ var InternalStateModule = internalState;
2272
+ var CONFIGURABLE_FUNCTION_NAME = functionName.CONFIGURABLE;
2273
+
2274
+ var getInternalState$1 = InternalStateModule.get;
2275
+ var enforceInternalState = InternalStateModule.enforce;
1973
2276
  var TEMPLATE = String(String).split('String');
1974
2277
 
1975
- (module.exports = function (O, key, value, options) {
2278
+ (redefine$3.exports = function (O, key, value, options) {
1976
2279
  var unsafe = options ? !!options.unsafe : false;
1977
2280
  var simple = options ? !!options.enumerable : false;
1978
2281
  var noTargetGet = options ? !!options.noTargetGet : false;
2282
+ var name = options && options.name !== undefined ? options.name : key;
1979
2283
  var state;
1980
- if (typeof value == 'function') {
1981
- if (typeof key == 'string' && !has$1(value, 'name')) {
1982
- createNonEnumerableProperty(value, 'name', key);
2284
+ if (isCallable$5(value)) {
2285
+ if (String(name).slice(0, 7) === 'Symbol(') {
2286
+ name = '[' + String(name).replace(/^Symbol\(([^)]*)\)/, '$1') + ']';
2287
+ }
2288
+ if (!hasOwn$2(value, 'name') || (CONFIGURABLE_FUNCTION_NAME && value.name !== name)) {
2289
+ createNonEnumerableProperty$2(value, 'name', name);
1983
2290
  }
1984
2291
  state = enforceInternalState(value);
1985
2292
  if (!state.source) {
1986
- state.source = TEMPLATE.join(typeof key == 'string' ? key : '');
2293
+ state.source = TEMPLATE.join(typeof name == 'string' ? name : '');
1987
2294
  }
1988
2295
  }
1989
- if (O === global_1) {
2296
+ if (O === global$5) {
1990
2297
  if (simple) O[key] = value;
1991
- else setGlobal(key, value);
2298
+ else setGlobal$1(key, value);
1992
2299
  return;
1993
2300
  } else if (!unsafe) {
1994
2301
  delete O[key];
@@ -1996,57 +2303,67 @@ var TEMPLATE = String(String).split('String');
1996
2303
  simple = true;
1997
2304
  }
1998
2305
  if (simple) O[key] = value;
1999
- else createNonEnumerableProperty(O, key, value);
2306
+ else createNonEnumerableProperty$2(O, key, value);
2000
2307
  // add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
2001
2308
  })(Function.prototype, 'toString', function toString() {
2002
- return typeof this == 'function' && getInternalState(this).source || inspectSource(this);
2309
+ return isCallable$5(this) && getInternalState$1(this).source || inspectSource$1(this);
2003
2310
  });
2004
- });
2005
-
2006
- var path = global_1;
2007
2311
 
2008
- var aFunction$1 = function (variable) {
2009
- return typeof variable == 'function' ? variable : undefined;
2010
- };
2312
+ var redefine$2 = redefine$3.exports;
2011
2313
 
2012
- var getBuiltIn = function (namespace, method) {
2013
- return arguments.length < 2 ? aFunction$1(path[namespace]) || aFunction$1(global_1[namespace])
2014
- : path[namespace] && path[namespace][method] || global_1[namespace] && global_1[namespace][method];
2015
- };
2314
+ var objectGetOwnPropertyNames = {};
2016
2315
 
2017
2316
  var ceil = Math.ceil;
2018
2317
  var floor$1 = Math.floor;
2019
2318
 
2020
- // `ToInteger` abstract operation
2021
- // https://tc39.es/ecma262/#sec-tointeger
2022
- var toInteger = function (argument) {
2023
- return isNaN(argument = +argument) ? 0 : (argument > 0 ? floor$1 : ceil)(argument);
2319
+ // `ToIntegerOrInfinity` abstract operation
2320
+ // https://tc39.es/ecma262/#sec-tointegerorinfinity
2321
+ var toIntegerOrInfinity$4 = function (argument) {
2322
+ var number = +argument;
2323
+ // eslint-disable-next-line no-self-compare -- safe
2324
+ return number !== number || number === 0 ? 0 : (number > 0 ? floor$1 : ceil)(number);
2325
+ };
2326
+
2327
+ var toIntegerOrInfinity$3 = toIntegerOrInfinity$4;
2328
+
2329
+ var max$1 = Math.max;
2330
+ var min$4 = Math.min;
2331
+
2332
+ // Helper for a popular repeating case of the spec:
2333
+ // Let integer be ? ToInteger(index).
2334
+ // If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).
2335
+ var toAbsoluteIndex$1 = function (index, length) {
2336
+ var integer = toIntegerOrInfinity$3(index);
2337
+ return integer < 0 ? max$1(integer + length, 0) : min$4(integer, length);
2024
2338
  };
2025
2339
 
2340
+ var toIntegerOrInfinity$2 = toIntegerOrInfinity$4;
2341
+
2026
2342
  var min$3 = Math.min;
2027
2343
 
2028
2344
  // `ToLength` abstract operation
2029
2345
  // https://tc39.es/ecma262/#sec-tolength
2030
- var toLength = function (argument) {
2031
- return argument > 0 ? min$3(toInteger(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991
2346
+ var toLength$5 = function (argument) {
2347
+ return argument > 0 ? min$3(toIntegerOrInfinity$2(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991
2032
2348
  };
2033
2349
 
2034
- var max$1 = Math.max;
2035
- var min$2 = Math.min;
2350
+ var toLength$4 = toLength$5;
2036
2351
 
2037
- // Helper for a popular repeating case of the spec:
2038
- // Let integer be ? ToInteger(index).
2039
- // If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).
2040
- var toAbsoluteIndex = function (index, length) {
2041
- var integer = toInteger(index);
2042
- return integer < 0 ? max$1(integer + length, 0) : min$2(integer, length);
2352
+ // `LengthOfArrayLike` abstract operation
2353
+ // https://tc39.es/ecma262/#sec-lengthofarraylike
2354
+ var lengthOfArrayLike$2 = function (obj) {
2355
+ return toLength$4(obj.length);
2043
2356
  };
2044
2357
 
2358
+ var toIndexedObject$2 = toIndexedObject$4;
2359
+ var toAbsoluteIndex = toAbsoluteIndex$1;
2360
+ var lengthOfArrayLike$1 = lengthOfArrayLike$2;
2361
+
2045
2362
  // `Array.prototype.{ indexOf, includes }` methods implementation
2046
- var createMethod$2 = function (IS_INCLUDES) {
2363
+ var createMethod$4 = function (IS_INCLUDES) {
2047
2364
  return function ($this, el, fromIndex) {
2048
- var O = toIndexedObject($this);
2049
- var length = toLength(O.length);
2365
+ var O = toIndexedObject$2($this);
2366
+ var length = lengthOfArrayLike$1(O);
2050
2367
  var index = toAbsoluteIndex(fromIndex, length);
2051
2368
  var value;
2052
2369
  // Array#includes uses SameValueZero equality algorithm
@@ -2065,32 +2382,32 @@ var createMethod$2 = function (IS_INCLUDES) {
2065
2382
  var arrayIncludes = {
2066
2383
  // `Array.prototype.includes` method
2067
2384
  // https://tc39.es/ecma262/#sec-array.prototype.includes
2068
- includes: createMethod$2(true),
2385
+ includes: createMethod$4(true),
2069
2386
  // `Array.prototype.indexOf` method
2070
2387
  // https://tc39.es/ecma262/#sec-array.prototype.indexof
2071
- indexOf: createMethod$2(false)
2388
+ indexOf: createMethod$4(false)
2072
2389
  };
2073
- var arrayIncludes_1 = arrayIncludes.includes;
2074
- var arrayIncludes_2 = arrayIncludes.indexOf;
2075
2390
 
2391
+ var hasOwn$1 = hasOwnProperty_1;
2392
+ var toIndexedObject$1 = toIndexedObject$4;
2076
2393
  var indexOf = arrayIncludes.indexOf;
2077
-
2394
+ var hiddenKeys$2 = hiddenKeys$4;
2078
2395
 
2079
2396
  var objectKeysInternal = function (object, names) {
2080
- var O = toIndexedObject(object);
2397
+ var O = toIndexedObject$1(object);
2081
2398
  var i = 0;
2082
2399
  var result = [];
2083
2400
  var key;
2084
- for (key in O) !has$1(hiddenKeys$1, key) && has$1(O, key) && result.push(key);
2401
+ for (key in O) !hasOwn$1(hiddenKeys$2, key) && hasOwn$1(O, key) && result.push(key);
2085
2402
  // Don't enum bug & hidden keys
2086
- while (names.length > i) if (has$1(O, key = names[i++])) {
2403
+ while (names.length > i) if (hasOwn$1(O, key = names[i++])) {
2087
2404
  ~indexOf(result, key) || result.push(key);
2088
2405
  }
2089
2406
  return result;
2090
2407
  };
2091
2408
 
2092
2409
  // IE8- don't enum bug keys
2093
- var enumBugKeys = [
2410
+ var enumBugKeys$3 = [
2094
2411
  'constructor',
2095
2412
  'hasOwnProperty',
2096
2413
  'isPrototypeOf',
@@ -2100,67 +2417,80 @@ var enumBugKeys = [
2100
2417
  'valueOf'
2101
2418
  ];
2102
2419
 
2103
- var hiddenKeys = enumBugKeys.concat('length', 'prototype');
2420
+ var internalObjectKeys$1 = objectKeysInternal;
2421
+ var enumBugKeys$2 = enumBugKeys$3;
2422
+
2423
+ var hiddenKeys$1 = enumBugKeys$2.concat('length', 'prototype');
2104
2424
 
2105
2425
  // `Object.getOwnPropertyNames` method
2106
2426
  // https://tc39.es/ecma262/#sec-object.getownpropertynames
2107
- var f$1 = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
2108
- return objectKeysInternal(O, hiddenKeys);
2427
+ // eslint-disable-next-line es/no-object-getownpropertynames -- safe
2428
+ var f$1 = objectGetOwnPropertyNames.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
2429
+ return internalObjectKeys$1(O, hiddenKeys$1);
2109
2430
  };
2110
2431
 
2111
- var objectGetOwnPropertyNames = {
2112
- f: f$1
2113
- };
2432
+ var objectGetOwnPropertySymbols = {};
2114
2433
 
2115
- var f = Object.getOwnPropertySymbols;
2434
+ // eslint-disable-next-line es/no-object-getownpropertysymbols -- safe
2435
+ var f = objectGetOwnPropertySymbols.f = Object.getOwnPropertySymbols;
2116
2436
 
2117
- var objectGetOwnPropertySymbols = {
2118
- f: f
2119
- };
2437
+ var getBuiltIn$2 = getBuiltIn$5;
2438
+ var getOwnPropertyNamesModule = objectGetOwnPropertyNames;
2439
+ var getOwnPropertySymbolsModule$1 = objectGetOwnPropertySymbols;
2440
+ var anObject$8 = anObject$a;
2120
2441
 
2121
2442
  // all object keys, includes non-enumerable and symbols
2122
- var ownKeys = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) {
2123
- var keys = objectGetOwnPropertyNames.f(anObject(it));
2124
- var getOwnPropertySymbols = objectGetOwnPropertySymbols.f;
2443
+ var ownKeys$1 = getBuiltIn$2('Reflect', 'ownKeys') || function ownKeys(it) {
2444
+ var keys = getOwnPropertyNamesModule.f(anObject$8(it));
2445
+ var getOwnPropertySymbols = getOwnPropertySymbolsModule$1.f;
2125
2446
  return getOwnPropertySymbols ? keys.concat(getOwnPropertySymbols(it)) : keys;
2126
2447
  };
2127
2448
 
2128
- var copyConstructorProperties = function (target, source) {
2449
+ var hasOwn = hasOwnProperty_1;
2450
+ var ownKeys = ownKeys$1;
2451
+ var getOwnPropertyDescriptorModule = objectGetOwnPropertyDescriptor;
2452
+ var definePropertyModule$1 = objectDefineProperty;
2453
+
2454
+ var copyConstructorProperties$1 = function (target, source) {
2129
2455
  var keys = ownKeys(source);
2130
- var defineProperty = objectDefineProperty.f;
2131
- var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
2456
+ var defineProperty = definePropertyModule$1.f;
2457
+ var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
2132
2458
  for (var i = 0; i < keys.length; i++) {
2133
2459
  var key = keys[i];
2134
- if (!has$1(target, key)) defineProperty(target, key, getOwnPropertyDescriptor(source, key));
2460
+ if (!hasOwn(target, key)) defineProperty(target, key, getOwnPropertyDescriptor(source, key));
2135
2461
  }
2136
2462
  };
2137
2463
 
2464
+ var fails$a = fails$f;
2465
+ var isCallable$4 = isCallable$d;
2466
+
2138
2467
  var replacement = /#|\.prototype\./;
2139
2468
 
2140
- var isForced = function (feature, detection) {
2469
+ var isForced$1 = function (feature, detection) {
2141
2470
  var value = data[normalize(feature)];
2142
2471
  return value == POLYFILL ? true
2143
2472
  : value == NATIVE ? false
2144
- : typeof detection == 'function' ? fails(detection)
2473
+ : isCallable$4(detection) ? fails$a(detection)
2145
2474
  : !!detection;
2146
2475
  };
2147
2476
 
2148
- var normalize = isForced.normalize = function (string) {
2477
+ var normalize = isForced$1.normalize = function (string) {
2149
2478
  return String(string).replace(replacement, '.').toLowerCase();
2150
2479
  };
2151
2480
 
2152
- var data = isForced.data = {};
2153
- var NATIVE = isForced.NATIVE = 'N';
2154
- var POLYFILL = isForced.POLYFILL = 'P';
2155
-
2156
- var isForced_1 = isForced;
2157
-
2158
- var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
2159
-
2160
-
2161
-
2481
+ var data = isForced$1.data = {};
2482
+ var NATIVE = isForced$1.NATIVE = 'N';
2483
+ var POLYFILL = isForced$1.POLYFILL = 'P';
2162
2484
 
2485
+ var isForced_1 = isForced$1;
2163
2486
 
2487
+ var global$4 = global$e;
2488
+ var getOwnPropertyDescriptor$1 = objectGetOwnPropertyDescriptor.f;
2489
+ var createNonEnumerableProperty$1 = createNonEnumerableProperty$4;
2490
+ var redefine$1 = redefine$3.exports;
2491
+ var setGlobal = setGlobal$3;
2492
+ var copyConstructorProperties = copyConstructorProperties$1;
2493
+ var isForced = isForced_1;
2164
2494
 
2165
2495
  /*
2166
2496
  options.target - name of the target object
@@ -2175,6 +2505,7 @@ var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
2175
2505
  options.sham - add a flag to not completely full polyfills
2176
2506
  options.enumerable - export as enumerable property
2177
2507
  options.noTargetGet - prevent calling a getter on target
2508
+ options.name - the .name of the function if it does not match the key
2178
2509
  */
2179
2510
  var _export = function (options, source) {
2180
2511
  var TARGET = options.target;
@@ -2182,19 +2513,19 @@ var _export = function (options, source) {
2182
2513
  var STATIC = options.stat;
2183
2514
  var FORCED, target, key, targetProperty, sourceProperty, descriptor;
2184
2515
  if (GLOBAL) {
2185
- target = global_1;
2516
+ target = global$4;
2186
2517
  } else if (STATIC) {
2187
- target = global_1[TARGET] || setGlobal(TARGET, {});
2518
+ target = global$4[TARGET] || setGlobal(TARGET, {});
2188
2519
  } else {
2189
- target = (global_1[TARGET] || {}).prototype;
2520
+ target = (global$4[TARGET] || {}).prototype;
2190
2521
  }
2191
2522
  if (target) for (key in source) {
2192
2523
  sourceProperty = source[key];
2193
2524
  if (options.noTargetGet) {
2194
- descriptor = getOwnPropertyDescriptor(target, key);
2525
+ descriptor = getOwnPropertyDescriptor$1(target, key);
2195
2526
  targetProperty = descriptor && descriptor.value;
2196
2527
  } else targetProperty = target[key];
2197
- FORCED = isForced_1(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
2528
+ FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
2198
2529
  // contained in target
2199
2530
  if (!FORCED && targetProperty !== undefined) {
2200
2531
  if (typeof sourceProperty === typeof targetProperty) continue;
@@ -2202,33 +2533,40 @@ var _export = function (options, source) {
2202
2533
  }
2203
2534
  // add a flag to not completely full polyfills
2204
2535
  if (options.sham || (targetProperty && targetProperty.sham)) {
2205
- createNonEnumerableProperty(sourceProperty, 'sham', true);
2536
+ createNonEnumerableProperty$1(sourceProperty, 'sham', true);
2206
2537
  }
2207
2538
  // extend global
2208
- redefine(target, key, sourceProperty, options);
2539
+ redefine$1(target, key, sourceProperty, options);
2209
2540
  }
2210
2541
  };
2211
2542
 
2543
+ var internalObjectKeys = objectKeysInternal;
2544
+ var enumBugKeys$1 = enumBugKeys$3;
2545
+
2212
2546
  // `Object.keys` method
2213
2547
  // https://tc39.es/ecma262/#sec-object.keys
2214
- var objectKeys = Object.keys || function keys(O) {
2215
- return objectKeysInternal(O, enumBugKeys);
2548
+ // eslint-disable-next-line es/no-object-keys -- safe
2549
+ var objectKeys$3 = Object.keys || function keys(O) {
2550
+ return internalObjectKeys(O, enumBugKeys$1);
2216
2551
  };
2217
2552
 
2553
+ var DESCRIPTORS$3 = descriptors;
2554
+ var objectKeys$2 = objectKeys$3;
2555
+ var toIndexedObject = toIndexedObject$4;
2218
2556
  var propertyIsEnumerable = objectPropertyIsEnumerable.f;
2219
2557
 
2220
2558
  // `Object.{ entries, values }` methods implementation
2221
- var createMethod$1 = function (TO_ENTRIES) {
2559
+ var createMethod$3 = function (TO_ENTRIES) {
2222
2560
  return function (it) {
2223
2561
  var O = toIndexedObject(it);
2224
- var keys = objectKeys(O);
2562
+ var keys = objectKeys$2(O);
2225
2563
  var length = keys.length;
2226
2564
  var i = 0;
2227
2565
  var result = [];
2228
2566
  var key;
2229
2567
  while (length > i) {
2230
2568
  key = keys[i++];
2231
- if (!descriptors || propertyIsEnumerable.call(O, key)) {
2569
+ if (!DESCRIPTORS$3 || propertyIsEnumerable.call(O, key)) {
2232
2570
  result.push(TO_ENTRIES ? [key, O[key]] : O[key]);
2233
2571
  }
2234
2572
  }
@@ -2239,905 +2577,1657 @@ var createMethod$1 = function (TO_ENTRIES) {
2239
2577
  var objectToArray = {
2240
2578
  // `Object.entries` method
2241
2579
  // https://tc39.es/ecma262/#sec-object.entries
2242
- entries: createMethod$1(true),
2580
+ entries: createMethod$3(true),
2243
2581
  // `Object.values` method
2244
2582
  // https://tc39.es/ecma262/#sec-object.values
2245
- values: createMethod$1(false)
2583
+ values: createMethod$3(false)
2246
2584
  };
2247
- var objectToArray_1 = objectToArray.entries;
2248
- var objectToArray_2 = objectToArray.values;
2249
2585
 
2586
+ var $$7 = _export;
2250
2587
  var $entries = objectToArray.entries;
2251
2588
 
2252
2589
  // `Object.entries` method
2253
2590
  // https://tc39.es/ecma262/#sec-object.entries
2254
- _export({ target: 'Object', stat: true }, {
2591
+ $$7({ target: 'Object', stat: true }, {
2255
2592
  entries: function entries(O) {
2256
2593
  return $entries(O);
2257
2594
  }
2258
2595
  });
2259
2596
 
2260
- var es_object_entries = {
2597
+ var es_string_endsWith = {};
2598
+
2599
+ var wellKnownSymbol$8 = wellKnownSymbol$a;
2600
+
2601
+ var TO_STRING_TAG$1 = wellKnownSymbol$8('toStringTag');
2602
+ var test = {};
2261
2603
 
2604
+ test[TO_STRING_TAG$1] = 'z';
2605
+
2606
+ var toStringTagSupport = String(test) === '[object z]';
2607
+
2608
+ var TO_STRING_TAG_SUPPORT = toStringTagSupport;
2609
+ var isCallable$3 = isCallable$d;
2610
+ var classofRaw = classofRaw$1;
2611
+ var wellKnownSymbol$7 = wellKnownSymbol$a;
2612
+
2613
+ var TO_STRING_TAG = wellKnownSymbol$7('toStringTag');
2614
+ // ES3 wrong here
2615
+ var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) == 'Arguments';
2616
+
2617
+ // fallback for IE11 Script Access Denied error
2618
+ var tryGet = function (it, key) {
2619
+ try {
2620
+ return it[key];
2621
+ } catch (error) { /* empty */ }
2262
2622
  };
2263
2623
 
2264
- var getCssProps = function getCssProps(el, props) {
2265
- var style = getComputedStyle(el);
2266
- var res = {};var _iterator = _createForOfIteratorHelper(
2267
- props),_step;try {for (_iterator.s(); !(_step = _iterator.n()).done;) {var prop = _step.value;
2268
- var val = style[prop];
2624
+ // getting tag from ES6+ `Object.prototype.toString`
2625
+ var classof$5 = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {
2626
+ var O, tag, result;
2627
+ return it === undefined ? 'Undefined' : it === null ? 'Null'
2628
+ // @@toStringTag case
2629
+ : typeof (tag = tryGet(O = Object(it), TO_STRING_TAG)) == 'string' ? tag
2630
+ // builtinTag case
2631
+ : CORRECT_ARGUMENTS ? classofRaw(O)
2632
+ // ES3 arguments fallback
2633
+ : (result = classofRaw(O)) == 'Object' && isCallable$3(O.callee) ? 'Arguments' : result;
2634
+ };
2269
2635
 
2270
- if ((prop === 'width' || prop === 'height') && val === 'auto' && el instanceof HTMLElement) {
2271
- val = el['offset' + prop.substr(0, 1).toUpperCase() + prop.substr(1)];
2636
+ var classof$4 = classof$5;
2272
2637
 
2273
- if (style.boxSizing !== 'border-box') {
2274
- if (prop === 'width') {
2275
- val -= parseFloat(style.paddingLeft || 0);
2276
- val -= parseFloat(style.paddingRight || 0);
2277
- val -= parseFloat(style.borderLeftWidth || 0);
2278
- val -= parseFloat(style.borderRightWidth || 0);
2279
- } else {
2280
- val -= parseFloat(style.paddingTop || 0);
2281
- val -= parseFloat(style.paddingBottom || 0);
2282
- val -= parseFloat(style.borderTopWidth || 0);
2283
- val -= parseFloat(style.borderBottomWidth || 0);
2284
- }
2285
- if (val < 0)
2286
- val = 0;
2287
- }
2288
- }
2638
+ var toString$7 = function (argument) {
2639
+ if (classof$4(argument) === 'Symbol') throw TypeError('Cannot convert a Symbol value to a string');
2640
+ return String(argument);
2641
+ };
2289
2642
 
2290
- res[prop] = val;
2291
- }} catch (err) {_iterator.e(err);} finally {_iterator.f();}
2292
- return res;
2643
+ var isObject$1 = isObject$7;
2644
+ var classof$3 = classofRaw$1;
2645
+ var wellKnownSymbol$6 = wellKnownSymbol$a;
2646
+
2647
+ var MATCH$1 = wellKnownSymbol$6('match');
2648
+
2649
+ // `IsRegExp` abstract operation
2650
+ // https://tc39.es/ecma262/#sec-isregexp
2651
+ var isRegexp = function (it) {
2652
+ var isRegExp;
2653
+ return isObject$1(it) && ((isRegExp = it[MATCH$1]) !== undefined ? !!isRegExp : classof$3(it) == 'RegExp');
2293
2654
  };
2294
2655
 
2295
- /**
2296
- * @param {ElementCSSInlineStyle} el
2297
- * @param {Object<string, string>} props
2298
- */
2299
- var setCssProps = function setCssProps(el, props) {
2300
- for (var _i = 0, _Object$entries = Object.entries(props); _i < _Object$entries.length; _i++) {var _Object$entries$_i = _slicedToArray(_Object$entries[_i], 2),key = _Object$entries$_i[0],value = _Object$entries$_i[1];
2301
- el.style[key] = value === undefined || value === null ? '' : String(value);}
2656
+ var isRegExp$1 = isRegexp;
2657
+
2658
+ var notARegexp = function (it) {
2659
+ if (isRegExp$1(it)) {
2660
+ throw TypeError("The method doesn't accept regular expressions");
2661
+ } return it;
2302
2662
  };
2303
2663
 
2304
- var generateGetElementSizeFn = function generateGetElementSizeFn(pseudo, dim, dimCased, startDim, endDim) {
2305
- return function () {
2306
- var /**Element|ElementCSSInlineStyle*/el = arguments.length <= 0 ? undefined : arguments[0],
2307
- /**string*/pseudoSelector,
2308
- /**boolean*/paddings,
2309
- /**boolean*/borders,
2310
- /**boolean*/margins;
2664
+ var wellKnownSymbol$5 = wellKnownSymbol$a;
2311
2665
 
2312
- if (pseudo) {
2313
- pseudoSelector = arguments.length <= 1 ? undefined : arguments[1];
2314
- paddings = !!(arguments.length <= 2 ? undefined : arguments[2]);
2315
- borders = !!(arguments.length <= 3 ? undefined : arguments[3]);
2316
- margins = !!(arguments.length <= 4 ? undefined : arguments[4]);
2317
- } else {
2318
- paddings = !!(arguments.length <= 1 ? undefined : arguments[1]);
2319
- borders = !!(arguments.length <= 2 ? undefined : arguments[2]);
2320
- margins = !!(arguments.length <= 3 ? undefined : arguments[3]);
2321
- }
2666
+ var MATCH = wellKnownSymbol$5('match');
2322
2667
 
2323
- if ( /**@type Window*/el === window) {
2324
- return (/**@type Window*/el.document.documentElement["client".concat(dimCased)]);
2325
- } else
2326
- if (el.nodeType === 9) {// document
2327
- var doc = /**@type Document*/el.documentElement;
2328
- var body = /**@type Document*/el.body;
2668
+ var correctIsRegexpLogic = function (METHOD_NAME) {
2669
+ var regexp = /./;
2670
+ try {
2671
+ '/./'[METHOD_NAME](regexp);
2672
+ } catch (error1) {
2673
+ try {
2674
+ regexp[MATCH] = false;
2675
+ return '/./'[METHOD_NAME](regexp);
2676
+ } catch (error2) { /* empty */ }
2677
+ } return false;
2678
+ };
2329
2679
 
2330
- return Math.max(
2331
- body["scroll".concat(dimCased)],
2332
- doc["scroll".concat(dimCased)],
2333
- body["offset".concat(dimCased)],
2334
- doc["offset".concat(dimCased)],
2335
- doc["client".concat(dimCased)]);
2680
+ 'use strict';
2681
+ var $$6 = _export;
2682
+ var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
2683
+ var toLength$3 = toLength$5;
2684
+ var toString$6 = toString$7;
2685
+ var notARegExp = notARegexp;
2686
+ var requireObjectCoercible$5 = requireObjectCoercible$8;
2687
+ var correctIsRegExpLogic = correctIsRegexpLogic;
2688
+ var IS_PURE = isPure;
2689
+
2690
+ // eslint-disable-next-line es/no-string-prototype-endswith -- safe
2691
+ var $endsWith = ''.endsWith;
2692
+ var min$2 = Math.min;
2336
2693
 
2337
- } else
2338
- {
2339
- var value;
2340
- var style;
2341
- var includesPadding = false,includesBorders = false;
2694
+ var CORRECT_IS_REGEXP_LOGIC = correctIsRegExpLogic('endsWith');
2695
+ // https://github.com/zloirock/core-js/pull/702
2696
+ var MDN_POLYFILL_BUG = !IS_PURE && !CORRECT_IS_REGEXP_LOGIC && !!function () {
2697
+ var descriptor = getOwnPropertyDescriptor(String.prototype, 'endsWith');
2698
+ return descriptor && !descriptor.writable;
2699
+ }();
2700
+
2701
+ // `String.prototype.endsWith` method
2702
+ // https://tc39.es/ecma262/#sec-string.prototype.endswith
2703
+ $$6({ target: 'String', proto: true, forced: !MDN_POLYFILL_BUG && !CORRECT_IS_REGEXP_LOGIC }, {
2704
+ endsWith: function endsWith(searchString /* , endPosition = @length */) {
2705
+ var that = toString$6(requireObjectCoercible$5(this));
2706
+ notARegExp(searchString);
2707
+ var endPosition = arguments.length > 1 ? arguments[1] : undefined;
2708
+ var len = that.length;
2709
+ var end = endPosition === undefined ? len : min$2(toLength$3(endPosition), len);
2710
+ var search = toString$6(searchString);
2711
+ return $endsWith
2712
+ ? $endsWith.call(that, search, end)
2713
+ : that.slice(end - search.length, end) === search;
2714
+ }
2715
+ });
2342
2716
 
2343
- if (!pseudo && 'getBoundingClientRect' in el) {
2344
- value = el.getBoundingClientRect()[dim];
2345
- includesPadding = true;
2346
- includesBorders = true;
2347
- }
2717
+ var es_regexp_exec = {};
2348
2718
 
2349
- if (value === undefined || margins || includesPadding !== paddings || includesBorders !== borders) {
2350
- style = pseudo ? getComputedStyle(el, pseudoSelector) : getComputedStyle(el);
2351
- }
2719
+ 'use strict';
2720
+ var anObject$7 = anObject$a;
2352
2721
 
2353
- if (value === undefined) {
2354
- var raw = style[dim];
2355
- if (raw === 'auto') {// computedStyle is no good here, probably an 'inline' element
2356
- value = el["client".concat(dimCased)]; // take clientWidth/clientHeight (damn it, it's rounded)
2357
- includesPadding = true;
2358
- } else {
2359
- value = parseFloat(raw);
2360
- }
2722
+ // `RegExp.prototype.flags` getter implementation
2723
+ // https://tc39.es/ecma262/#sec-get-regexp.prototype.flags
2724
+ var regexpFlags$1 = function () {
2725
+ var that = anObject$7(this);
2726
+ var result = '';
2727
+ if (that.global) result += 'g';
2728
+ if (that.ignoreCase) result += 'i';
2729
+ if (that.multiline) result += 'm';
2730
+ if (that.dotAll) result += 's';
2731
+ if (that.unicode) result += 'u';
2732
+ if (that.sticky) result += 'y';
2733
+ return result;
2734
+ };
2361
2735
 
2362
- if (style.boxSizing === 'border-box') {
2363
- includesPadding = true;
2364
- includesBorders = true;
2365
- }
2366
- }
2736
+ var regexpStickyHelpers = {};
2367
2737
 
2368
- if (paddings !== includesPadding) {
2369
- var totalPadding = parseFloat(style["padding-".concat(startDim)] || 0) +
2370
- parseFloat(style["padding-".concat(endDim)] || 0);
2371
- if (paddings) value += totalPadding;else
2372
- value -= totalPadding;
2373
- }
2738
+ var fails$9 = fails$f;
2739
+ var global$3 = global$e;
2374
2740
 
2375
- if (borders !== includesBorders) {
2376
- var totalBorders = parseFloat(style["border-".concat(startDim, "-width")] || 0) +
2377
- parseFloat(style["border-".concat(endDim, "-width")] || 0);
2378
- if (borders) value += totalBorders;else
2379
- value -= totalBorders;
2380
- }
2741
+ // babel-minify and Closure Compiler transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError
2742
+ var $RegExp$2 = global$3.RegExp;
2381
2743
 
2382
- if (value < 0)
2383
- value = 0;
2744
+ var UNSUPPORTED_Y$2 = regexpStickyHelpers.UNSUPPORTED_Y = fails$9(function () {
2745
+ var re = $RegExp$2('a', 'y');
2746
+ re.lastIndex = 2;
2747
+ return re.exec('abcd') != null;
2748
+ });
2384
2749
 
2385
- if (margins) {
2386
- var totalMargins = parseFloat(style["margin-".concat(startDim)] || 0) +
2387
- parseFloat(style["margin-".concat(endDim)] || 0);
2388
- value += totalMargins;
2389
- }
2750
+ var BROKEN_CARET = regexpStickyHelpers.BROKEN_CARET = fails$9(function () {
2751
+ // https://bugzilla.mozilla.org/show_bug.cgi?id=773687
2752
+ var re = $RegExp$2('^r', 'gy');
2753
+ re.lastIndex = 2;
2754
+ return re.exec('str') != null;
2755
+ });
2390
2756
 
2391
- return value;
2392
- }
2393
- };
2757
+ var DESCRIPTORS$2 = descriptors;
2758
+ var definePropertyModule = objectDefineProperty;
2759
+ var anObject$6 = anObject$a;
2760
+ var objectKeys$1 = objectKeys$3;
2761
+
2762
+ // `Object.defineProperties` method
2763
+ // https://tc39.es/ecma262/#sec-object.defineproperties
2764
+ // eslint-disable-next-line es/no-object-defineproperties -- safe
2765
+ var objectDefineProperties = DESCRIPTORS$2 ? Object.defineProperties : function defineProperties(O, Properties) {
2766
+ anObject$6(O);
2767
+ var keys = objectKeys$1(Properties);
2768
+ var length = keys.length;
2769
+ var index = 0;
2770
+ var key;
2771
+ while (length > index) definePropertyModule.f(O, key = keys[index++], Properties[key]);
2772
+ return O;
2394
2773
  };
2395
2774
 
2396
- var generateSetElementSizeFn = function generateSetElementSizeFn(dim, dimCased, startDim, endDim) {
2397
- return function ( /**Element|ElementCSSInlineStyle*/el,
2398
- /**number*/value)
2399
- {var paddings = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;var borders = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;var margins = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : false;
2400
-
2401
- if ( /**@type Window*/el === window) {
2402
- return;
2403
- }
2775
+ var getBuiltIn$1 = getBuiltIn$5;
2404
2776
 
2405
- if (el.nodeType === 9) {// document
2406
- return;
2407
- }
2777
+ var html$1 = getBuiltIn$1('document', 'documentElement');
2408
2778
 
2409
- var style = getComputedStyle(el);
2779
+ /* global ActiveXObject -- old IE, WSH */
2410
2780
 
2411
- var includesPaddingAndBorders = false;
2781
+ var anObject$5 = anObject$a;
2782
+ var defineProperties = objectDefineProperties;
2783
+ var enumBugKeys = enumBugKeys$3;
2784
+ var hiddenKeys = hiddenKeys$4;
2785
+ var html = html$1;
2786
+ var documentCreateElement = documentCreateElement$1;
2787
+ var sharedKey = sharedKey$2;
2412
2788
 
2413
- if (style.boxSizing === 'border-box') {
2414
- includesPaddingAndBorders = true;
2415
- }
2789
+ var GT = '>';
2790
+ var LT = '<';
2791
+ var PROTOTYPE = 'prototype';
2792
+ var SCRIPT = 'script';
2793
+ var IE_PROTO = sharedKey('IE_PROTO');
2416
2794
 
2417
- paddings = !!paddings;
2418
- borders = !!borders;
2419
- margins = !!margins;
2795
+ var EmptyConstructor = function () { /* empty */ };
2420
2796
 
2421
- if (margins)
2422
- value -= (parseFloat(style["margin-".concat(startDim)]) || 0) + (parseFloat(style["margin-".concat(endDim)]) || 0);
2797
+ var scriptTag = function (content) {
2798
+ return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;
2799
+ };
2423
2800
 
2424
- if (paddings !== includesPaddingAndBorders) {
2425
- var totalPadding = parseFloat(style["padding-".concat(startDim)] || 0) +
2426
- parseFloat(style["padding-".concat(endDim)] || 0);
2427
- if (paddings) value -= totalPadding;else
2428
- value += totalPadding;
2429
- }
2801
+ // Create object with fake `null` prototype: use ActiveX Object with cleared prototype
2802
+ var NullProtoObjectViaActiveX = function (activeXDocument) {
2803
+ activeXDocument.write(scriptTag(''));
2804
+ activeXDocument.close();
2805
+ var temp = activeXDocument.parentWindow.Object;
2806
+ activeXDocument = null; // avoid memory leak
2807
+ return temp;
2808
+ };
2430
2809
 
2431
- if (borders !== includesPaddingAndBorders) {
2432
- var totalBorders = (parseFloat(style["border-".concat(startDim, "-width")]) || 0) + (
2433
- parseFloat(style["border-".concat(endDim, "-width")]) || 0);
2434
- if (borders) value -= totalBorders;else
2435
- value += totalBorders;
2436
- }
2810
+ // Create object with fake `null` prototype: use iframe Object with cleared prototype
2811
+ var NullProtoObjectViaIFrame = function () {
2812
+ // Thrash, waste and sodomy: IE GC bug
2813
+ var iframe = documentCreateElement('iframe');
2814
+ var JS = 'java' + SCRIPT + ':';
2815
+ var iframeDocument;
2816
+ iframe.style.display = 'none';
2817
+ html.appendChild(iframe);
2818
+ // https://github.com/zloirock/core-js/issues/475
2819
+ iframe.src = String(JS);
2820
+ iframeDocument = iframe.contentWindow.document;
2821
+ iframeDocument.open();
2822
+ iframeDocument.write(scriptTag('document.F=Object'));
2823
+ iframeDocument.close();
2824
+ return iframeDocument.F;
2825
+ };
2437
2826
 
2438
- if (value < 0)
2439
- value = 0;
2827
+ // Check for document.domain and active x support
2828
+ // No need to use active x approach when document.domain is not set
2829
+ // see https://github.com/es-shims/es5-shim/issues/150
2830
+ // variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346
2831
+ // avoid IE GC bug
2832
+ var activeXDocument;
2833
+ var NullProtoObject = function () {
2834
+ try {
2835
+ activeXDocument = new ActiveXObject('htmlfile');
2836
+ } catch (error) { /* ignore */ }
2837
+ NullProtoObject = typeof document != 'undefined'
2838
+ ? document.domain && activeXDocument
2839
+ ? NullProtoObjectViaActiveX(activeXDocument) // old IE
2840
+ : NullProtoObjectViaIFrame()
2841
+ : NullProtoObjectViaActiveX(activeXDocument); // WSH
2842
+ var length = enumBugKeys.length;
2843
+ while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];
2844
+ return NullProtoObject();
2845
+ };
2440
2846
 
2441
- el.style[dim] = value + 'px';
2442
- };
2847
+ hiddenKeys[IE_PROTO] = true;
2848
+
2849
+ // `Object.create` method
2850
+ // https://tc39.es/ecma262/#sec-object.create
2851
+ var objectCreate = Object.create || function create(O, Properties) {
2852
+ var result;
2853
+ if (O !== null) {
2854
+ EmptyConstructor[PROTOTYPE] = anObject$5(O);
2855
+ result = new EmptyConstructor();
2856
+ EmptyConstructor[PROTOTYPE] = null;
2857
+ // add "__proto__" for Object.getPrototypeOf polyfill
2858
+ result[IE_PROTO] = O;
2859
+ } else result = NullProtoObject();
2860
+ return Properties === undefined ? result : defineProperties(result, Properties);
2443
2861
  };
2444
2862
 
2445
- /**
2446
- * Gets the width of an element, with fractions
2447
- * @function getElementWidth
2448
- * @param {Element} el
2449
- * @param {boolean} [paddings=false] - include paddings
2450
- * @param {boolean} [borders=false] - include borders
2451
- * @param {boolean} [margins=false] - include margins
2452
- * @returns {number}
2453
- */
2454
- var getElementWidth = generateGetElementSizeFn(false, 'width', 'Width', 'left', 'right');
2863
+ var fails$8 = fails$f;
2864
+ var global$2 = global$e;
2455
2865
 
2456
- /**
2457
- * Gets the width of an element, with fractions
2458
- * @function getElementHeight
2459
- * @param {Element} el
2460
- * @param {boolean} [paddings=false] - include paddings
2461
- * @param {boolean} [borders=false] - include borders
2462
- * @param {boolean} [margins=false] - include margins
2463
- * @returns {number}
2464
- */
2465
- var getElementHeight = generateGetElementSizeFn(false, 'height', 'Height', 'top', 'bottom');
2866
+ // babel-minify and Closure Compiler transpiles RegExp('.', 's') -> /./s and it causes SyntaxError
2867
+ var $RegExp$1 = global$2.RegExp;
2466
2868
 
2467
- /**
2468
- * Gets the width of an element, with fractions
2469
- * @function getPseudoElementWidth
2470
- * @param {Element} el
2471
- * @param {string} pseudo
2472
- * @param {boolean} [paddings=false] - include paddings
2473
- * @param {boolean} [borders=false] - include borders
2474
- * @param {boolean} [margins=false] - include margins
2475
- * @returns {number}
2476
- */
2477
- var getPseudoElementWidth = generateGetElementSizeFn(true, 'width', 'Width', 'left', 'right');
2869
+ var regexpUnsupportedDotAll = fails$8(function () {
2870
+ var re = $RegExp$1('.', 's');
2871
+ return !(re.dotAll && re.exec('\n') && re.flags === 's');
2872
+ });
2478
2873
 
2479
- /**
2480
- * Gets the width of an element, with fractions
2481
- * @function getPseudoElementHeight
2482
- * @param {Element} el
2483
- * @param {string} pseudo
2484
- * @param {boolean} [paddings=false] - include paddings
2485
- * @param {boolean} [borders=false] - include borders
2486
- * @param {boolean} [margins=false] - include margins
2487
- * @returns {number}
2488
- */
2489
- var getPseudoElementHeight = generateGetElementSizeFn(true, 'height', 'Height', 'top', 'bottom');
2874
+ var fails$7 = fails$f;
2875
+ var global$1 = global$e;
2490
2876
 
2491
- /**
2492
- * Sets the width of an element
2493
- * @function setElementWidth
2494
- * @param {Element} el
2495
- * @param {number} value
2496
- * @param {boolean} [paddings=false] - include paddings
2497
- * @param {boolean} [borders=false] - include borders
2498
- * @param {boolean} [margins=false] - include margins
2499
- */
2500
- var setElementWidth = generateSetElementSizeFn('width', 'Width', 'left', 'right');
2877
+ // babel-minify and Closure Compiler transpiles RegExp('(?<a>b)', 'g') -> /(?<a>b)/g and it causes SyntaxError
2878
+ var $RegExp = global$1.RegExp;
2501
2879
 
2502
- /**
2503
- * Sets the width of an element, with fractions
2504
- * @function setElementHeight
2505
- * @param {Element} el
2506
- * @param {number} value
2507
- * @param {boolean} [paddings=false] - include paddings
2508
- * @param {boolean} [borders=false] - include borders
2509
- * @param {boolean} [margins=false] - include margins
2510
- */
2511
- var setElementHeight = generateSetElementSizeFn('height', 'Height', 'top', 'bottom');
2880
+ var regexpUnsupportedNcg = fails$7(function () {
2881
+ var re = $RegExp('(?<a>b)', 'g');
2882
+ return re.exec('b').groups.a !== 'b' ||
2883
+ 'b'.replace(re, '$<a>c') !== 'bc';
2884
+ });
2512
2885
 
2513
- /**
2514
- * Find offset of an element relative to the document, considering scroll offsets
2515
- * @param {Element} el
2516
- * @returns {{top: number, left: number}}
2517
- */
2518
- var getElementOffset = function getElementOffset(el) {
2519
- if (!el.getClientRects().length) {
2520
- return { top: 0, left: 0 };
2521
- }
2886
+ 'use strict';
2887
+ /* eslint-disable regexp/no-empty-capturing-group, regexp/no-empty-group, regexp/no-lazy-ends -- testing */
2888
+ /* eslint-disable regexp/no-useless-quantifier -- testing */
2889
+ var toString$5 = toString$7;
2890
+ var regexpFlags = regexpFlags$1;
2891
+ var stickyHelpers$1 = regexpStickyHelpers;
2892
+ var shared = shared$5.exports;
2893
+ var create = objectCreate;
2894
+ var getInternalState = internalState.get;
2895
+ var UNSUPPORTED_DOT_ALL = regexpUnsupportedDotAll;
2896
+ var UNSUPPORTED_NCG = regexpUnsupportedNcg;
2522
2897
 
2523
- var rect = el.getBoundingClientRect();
2524
- var view = el.ownerDocument.defaultView;
2898
+ var nativeExec = RegExp.prototype.exec;
2899
+ var nativeReplace = shared('native-string-replace', String.prototype.replace);
2525
2900
 
2526
- return {
2527
- top: rect.top + view.pageYOffset,
2528
- left: rect.left + view.pageXOffset };
2901
+ var patchedExec = nativeExec;
2902
+
2903
+ var UPDATES_LAST_INDEX_WRONG = (function () {
2904
+ var re1 = /a/;
2905
+ var re2 = /b*/g;
2906
+ nativeExec.call(re1, 'a');
2907
+ nativeExec.call(re2, 'a');
2908
+ return re1.lastIndex !== 0 || re2.lastIndex !== 0;
2909
+ })();
2910
+
2911
+ var UNSUPPORTED_Y$1 = stickyHelpers$1.UNSUPPORTED_Y || stickyHelpers$1.BROKEN_CARET;
2912
+
2913
+ // nonparticipating capturing group, copied from es5-shim's String#split patch.
2914
+ var NPCG_INCLUDED = /()??/.exec('')[1] !== undefined;
2915
+
2916
+ var PATCH = UPDATES_LAST_INDEX_WRONG || NPCG_INCLUDED || UNSUPPORTED_Y$1 || UNSUPPORTED_DOT_ALL || UNSUPPORTED_NCG;
2917
+
2918
+ if (PATCH) {
2919
+ // eslint-disable-next-line max-statements -- TODO
2920
+ patchedExec = function exec(string) {
2921
+ var re = this;
2922
+ var state = getInternalState(re);
2923
+ var str = toString$5(string);
2924
+ var raw = state.raw;
2925
+ var result, reCopy, lastIndex, match, i, object, group;
2926
+
2927
+ if (raw) {
2928
+ raw.lastIndex = re.lastIndex;
2929
+ result = patchedExec.call(raw, str);
2930
+ re.lastIndex = raw.lastIndex;
2931
+ return result;
2932
+ }
2933
+
2934
+ var groups = state.groups;
2935
+ var sticky = UNSUPPORTED_Y$1 && re.sticky;
2936
+ var flags = regexpFlags.call(re);
2937
+ var source = re.source;
2938
+ var charsAdded = 0;
2939
+ var strCopy = str;
2940
+
2941
+ if (sticky) {
2942
+ flags = flags.replace('y', '');
2943
+ if (flags.indexOf('g') === -1) {
2944
+ flags += 'g';
2945
+ }
2946
+
2947
+ strCopy = str.slice(re.lastIndex);
2948
+ // Support anchored sticky behavior.
2949
+ if (re.lastIndex > 0 && (!re.multiline || re.multiline && str.charAt(re.lastIndex - 1) !== '\n')) {
2950
+ source = '(?: ' + source + ')';
2951
+ strCopy = ' ' + strCopy;
2952
+ charsAdded++;
2953
+ }
2954
+ // ^(? + rx + ) is needed, in combination with some str slicing, to
2955
+ // simulate the 'y' flag.
2956
+ reCopy = new RegExp('^(?:' + source + ')', flags);
2957
+ }
2958
+
2959
+ if (NPCG_INCLUDED) {
2960
+ reCopy = new RegExp('^' + source + '$(?!\\s)', flags);
2961
+ }
2962
+ if (UPDATES_LAST_INDEX_WRONG) lastIndex = re.lastIndex;
2963
+
2964
+ match = nativeExec.call(sticky ? reCopy : re, strCopy);
2965
+
2966
+ if (sticky) {
2967
+ if (match) {
2968
+ match.input = match.input.slice(charsAdded);
2969
+ match[0] = match[0].slice(charsAdded);
2970
+ match.index = re.lastIndex;
2971
+ re.lastIndex += match[0].length;
2972
+ } else re.lastIndex = 0;
2973
+ } else if (UPDATES_LAST_INDEX_WRONG && match) {
2974
+ re.lastIndex = re.global ? match.index + match[0].length : lastIndex;
2975
+ }
2976
+ if (NPCG_INCLUDED && match && match.length > 1) {
2977
+ // Fix browsers whose `exec` methods don't consistently return `undefined`
2978
+ // for NPCG, like IE8. NOTE: This doesn' work for /(.?)?/
2979
+ nativeReplace.call(match[0], reCopy, function () {
2980
+ for (i = 1; i < arguments.length - 2; i++) {
2981
+ if (arguments[i] === undefined) match[i] = undefined;
2982
+ }
2983
+ });
2984
+ }
2985
+
2986
+ if (match && groups) {
2987
+ match.groups = object = create(null);
2988
+ for (i = 0; i < groups.length; i++) {
2989
+ group = groups[i];
2990
+ object[group[0]] = match[group[1]];
2991
+ }
2992
+ }
2993
+
2994
+ return match;
2995
+ };
2996
+ }
2997
+
2998
+ var regexpExec$3 = patchedExec;
2999
+
3000
+ 'use strict';
3001
+ var $$5 = _export;
3002
+ var exec$1 = regexpExec$3;
3003
+
3004
+ // `RegExp.prototype.exec` method
3005
+ // https://tc39.es/ecma262/#sec-regexp.prototype.exec
3006
+ $$5({ target: 'RegExp', proto: true, forced: /./.exec !== exec$1 }, {
3007
+ exec: exec$1
3008
+ });
3009
+
3010
+ var es_string_split = {};
3011
+
3012
+ 'use strict';
3013
+ // TODO: Remove from `core-js@4` since it's moved to entry points
3014
+
3015
+ var redefine = redefine$3.exports;
3016
+ var regexpExec$2 = regexpExec$3;
3017
+ var fails$6 = fails$f;
3018
+ var wellKnownSymbol$4 = wellKnownSymbol$a;
3019
+ var createNonEnumerableProperty = createNonEnumerableProperty$4;
3020
+
3021
+ var SPECIES$3 = wellKnownSymbol$4('species');
3022
+ var RegExpPrototype = RegExp.prototype;
3023
+
3024
+ var fixRegexpWellKnownSymbolLogic = function (KEY, exec, FORCED, SHAM) {
3025
+ var SYMBOL = wellKnownSymbol$4(KEY);
3026
+
3027
+ var DELEGATES_TO_SYMBOL = !fails$6(function () {
3028
+ // String methods call symbol-named RegEp methods
3029
+ var O = {};
3030
+ O[SYMBOL] = function () { return 7; };
3031
+ return ''[KEY](O) != 7;
3032
+ });
2529
3033
 
3034
+ var DELEGATES_TO_EXEC = DELEGATES_TO_SYMBOL && !fails$6(function () {
3035
+ // Symbol-named RegExp methods call .exec
3036
+ var execCalled = false;
3037
+ var re = /a/;
3038
+
3039
+ if (KEY === 'split') {
3040
+ // We can't use real regex here since it causes deoptimization
3041
+ // and serious performance degradation in V8
3042
+ // https://github.com/zloirock/core-js/issues/306
3043
+ re = {};
3044
+ // RegExp[@@split] doesn't call the regex's exec method, but first creates
3045
+ // a new one. We need to return the patched regex when creating the new one.
3046
+ re.constructor = {};
3047
+ re.constructor[SPECIES$3] = function () { return re; };
3048
+ re.flags = '';
3049
+ re[SYMBOL] = /./[SYMBOL];
3050
+ }
3051
+
3052
+ re.exec = function () { execCalled = true; return null; };
3053
+
3054
+ re[SYMBOL]('');
3055
+ return !execCalled;
3056
+ });
3057
+
3058
+ if (
3059
+ !DELEGATES_TO_SYMBOL ||
3060
+ !DELEGATES_TO_EXEC ||
3061
+ FORCED
3062
+ ) {
3063
+ var nativeRegExpMethod = /./[SYMBOL];
3064
+ var methods = exec(SYMBOL, ''[KEY], function (nativeMethod, regexp, str, arg2, forceStringMethod) {
3065
+ var $exec = regexp.exec;
3066
+ if ($exec === regexpExec$2 || $exec === RegExpPrototype.exec) {
3067
+ if (DELEGATES_TO_SYMBOL && !forceStringMethod) {
3068
+ // The native String method already delegates to @@method (this
3069
+ // polyfilled function), leasing to infinite recursion.
3070
+ // We avoid it by directly calling the native @@method method.
3071
+ return { done: true, value: nativeRegExpMethod.call(regexp, str, arg2) };
3072
+ }
3073
+ return { done: true, value: nativeMethod.call(str, regexp, arg2) };
3074
+ }
3075
+ return { done: false };
3076
+ });
3077
+
3078
+ redefine(String.prototype, KEY, methods[0]);
3079
+ redefine(RegExpPrototype, SYMBOL, methods[1]);
3080
+ }
3081
+
3082
+ if (SHAM) createNonEnumerableProperty(RegExpPrototype[SYMBOL], 'sham', true);
2530
3083
  };
2531
3084
 
2532
- /**
2533
- * Calculates the anchored position relative to this element. <br />
2534
- * The return value will include an `left`/`top` position on left/top axis, <br />
2535
- * an `right`/`bottom` position which is the exact opposite, <br />
2536
- * and the `xSpec`/`ySpec` after normalizing rtl based values (`'start'`/`'end'`).
2537
- * @param {Element} el? - the target element to base the calculations on. If `size` and `rtl` are specified - then this argument is optional.
2538
- * @param {'left'|'center'|'right'|'start'|'end'|string|number} xSpec - horizontal anchor specification (could be either `'left'|'center'|'right'|'start'|'end'` or a percentage `'50%'` or a fixed decimal `Number`)
2539
- * @param {'top'|'center'|'bottom'|string|number} ySpec - vertical anchor specification (could be either `'top'|'center'|'bottom'` or a percentage `'50%'` or a fixed decimal `Number`)
2540
- * @param {{width: number, height: number}?} size - can be specified if already known, to avoid extra dom calculations. This is the outer size of the element, including padding and borders.
2541
- * @param {boolean?} [rtl] - if not specified and values like `'start'`/`'end'` are use, then `rtl` is auto detected
2542
- * @returns {{left: number, top: number, right: number, bottom: number, xSpec: string|number, ySpec: string|number}}
2543
- */
2544
- var anchoredPosition = function anchoredPosition(el, xSpec, ySpec, size, rtl) {
2545
- if (!size) {
2546
- size = {
2547
- width: getElementWidth(el, true, true),
2548
- height: getElementWidth(el, true, true) };
3085
+ var fails$5 = fails$f;
3086
+ var isCallable$2 = isCallable$d;
3087
+ var classof$2 = classof$5;
3088
+ var getBuiltIn = getBuiltIn$5;
3089
+ var inspectSource = inspectSource$3;
3090
+
3091
+ var empty = [];
3092
+ var construct = getBuiltIn('Reflect', 'construct');
3093
+ var constructorRegExp = /^\s*(?:class|function)\b/;
3094
+ var exec = constructorRegExp.exec;
3095
+ var INCORRECT_TO_STRING = !constructorRegExp.exec(function () { /* empty */ });
2549
3096
 
3097
+ var isConstructorModern = function (argument) {
3098
+ if (!isCallable$2(argument)) return false;
3099
+ try {
3100
+ construct(Object, empty, argument);
3101
+ return true;
3102
+ } catch (error) {
3103
+ return false;
2550
3104
  }
3105
+ };
2551
3106
 
2552
- if (xSpec === 'start' || xSpec === 'end') {
2553
- if ( /**@type boolean|null*/rtl === null || rtl === undefined) {
2554
- rtl = getComputedStyle(el).direction === 'rtl';
2555
- }
2556
- xSpec = xSpec === 'start' ? rtl ? 'right' : 'left' : rtl ? 'left' : 'right';
3107
+ var isConstructorLegacy = function (argument) {
3108
+ if (!isCallable$2(argument)) return false;
3109
+ switch (classof$2(argument)) {
3110
+ case 'AsyncFunction':
3111
+ case 'GeneratorFunction':
3112
+ case 'AsyncGeneratorFunction': return false;
3113
+ // we can't check .prototype since constructors produced by .bind haven't it
3114
+ } return INCORRECT_TO_STRING || !!exec.call(constructorRegExp, inspectSource(argument));
3115
+ };
3116
+
3117
+ // `IsConstructor` abstract operation
3118
+ // https://tc39.es/ecma262/#sec-isconstructor
3119
+ var isConstructor$2 = !construct || fails$5(function () {
3120
+ var called;
3121
+ return isConstructorModern(isConstructorModern.call)
3122
+ || !isConstructorModern(Object)
3123
+ || !isConstructorModern(function () { called = true; })
3124
+ || called;
3125
+ }) ? isConstructorLegacy : isConstructorModern;
3126
+
3127
+ var isConstructor$1 = isConstructor$2;
3128
+ var tryToString = tryToString$2;
3129
+
3130
+ // `Assert: IsConstructor(argument) is true`
3131
+ var aConstructor$1 = function (argument) {
3132
+ if (isConstructor$1(argument)) return argument;
3133
+ throw TypeError(tryToString(argument) + ' is not a constructor');
3134
+ };
3135
+
3136
+ var anObject$4 = anObject$a;
3137
+ var aConstructor = aConstructor$1;
3138
+ var wellKnownSymbol$3 = wellKnownSymbol$a;
3139
+
3140
+ var SPECIES$2 = wellKnownSymbol$3('species');
3141
+
3142
+ // `SpeciesConstructor` abstract operation
3143
+ // https://tc39.es/ecma262/#sec-speciesconstructor
3144
+ var speciesConstructor$1 = function (O, defaultConstructor) {
3145
+ var C = anObject$4(O).constructor;
3146
+ var S;
3147
+ return C === undefined || (S = anObject$4(C)[SPECIES$2]) == undefined ? defaultConstructor : aConstructor(S);
3148
+ };
3149
+
3150
+ var toIntegerOrInfinity$1 = toIntegerOrInfinity$4;
3151
+ var toString$4 = toString$7;
3152
+ var requireObjectCoercible$4 = requireObjectCoercible$8;
3153
+
3154
+ var createMethod$2 = function (CONVERT_TO_STRING) {
3155
+ return function ($this, pos) {
3156
+ var S = toString$4(requireObjectCoercible$4($this));
3157
+ var position = toIntegerOrInfinity$1(pos);
3158
+ var size = S.length;
3159
+ var first, second;
3160
+ if (position < 0 || position >= size) return CONVERT_TO_STRING ? '' : undefined;
3161
+ first = S.charCodeAt(position);
3162
+ return first < 0xD800 || first > 0xDBFF || position + 1 === size
3163
+ || (second = S.charCodeAt(position + 1)) < 0xDC00 || second > 0xDFFF
3164
+ ? CONVERT_TO_STRING ? S.charAt(position) : first
3165
+ : CONVERT_TO_STRING ? S.slice(position, position + 2) : (first - 0xD800 << 10) + (second - 0xDC00) + 0x10000;
3166
+ };
3167
+ };
3168
+
3169
+ var stringMultibyte = {
3170
+ // `String.prototype.codePointAt` method
3171
+ // https://tc39.es/ecma262/#sec-string.prototype.codepointat
3172
+ codeAt: createMethod$2(false),
3173
+ // `String.prototype.at` method
3174
+ // https://github.com/mathiasbynens/String.prototype.at
3175
+ charAt: createMethod$2(true)
3176
+ };
3177
+
3178
+ 'use strict';
3179
+ var charAt = stringMultibyte.charAt;
3180
+
3181
+ // `AdvanceStringIndex` abstract operation
3182
+ // https://tc39.es/ecma262/#sec-advancestringindex
3183
+ var advanceStringIndex$3 = function (S, index, unicode) {
3184
+ return index + (unicode ? charAt(S, index).length : 1);
3185
+ };
3186
+
3187
+ var anObject$3 = anObject$a;
3188
+ var isCallable$1 = isCallable$d;
3189
+ var classof$1 = classofRaw$1;
3190
+ var regexpExec$1 = regexpExec$3;
3191
+
3192
+ // `RegExpExec` abstract operation
3193
+ // https://tc39.es/ecma262/#sec-regexpexec
3194
+ var regexpExecAbstract = function (R, S) {
3195
+ var exec = R.exec;
3196
+ if (isCallable$1(exec)) {
3197
+ var result = exec.call(R, S);
3198
+ if (result !== null) anObject$3(result);
3199
+ return result;
2557
3200
  }
3201
+ if (classof$1(R) === 'RegExp') return regexpExec$1.call(R, S);
3202
+ throw TypeError('RegExp#exec called on incompatible receiver');
3203
+ };
2558
3204
 
2559
- var x, y;
2560
- var xInverted, yInverted;
3205
+ 'use strict';
3206
+ var fixRegExpWellKnownSymbolLogic$2 = fixRegexpWellKnownSymbolLogic;
3207
+ var isRegExp = isRegexp;
3208
+ var anObject$2 = anObject$a;
3209
+ var requireObjectCoercible$3 = requireObjectCoercible$8;
3210
+ var speciesConstructor = speciesConstructor$1;
3211
+ var advanceStringIndex$2 = advanceStringIndex$3;
3212
+ var toLength$2 = toLength$5;
3213
+ var toString$3 = toString$7;
3214
+ var getMethod$2 = getMethod$4;
3215
+ var callRegExpExec = regexpExecAbstract;
3216
+ var regexpExec = regexpExec$3;
3217
+ var stickyHelpers = regexpStickyHelpers;
3218
+ var fails$4 = fails$f;
3219
+
3220
+ var UNSUPPORTED_Y = stickyHelpers.UNSUPPORTED_Y;
3221
+ var arrayPush = [].push;
3222
+ var min$1 = Math.min;
3223
+ var MAX_UINT32 = 0xFFFFFFFF;
2561
3224
 
2562
- if (xSpec === 'right') {
2563
- x = size.width;
2564
- xInverted = 0;
2565
- } else
2566
- if (xSpec === 'center') {
2567
- x = size.width / 2;
2568
- xInverted = x;
2569
- } else
2570
- if (xSpec === 'left') {
2571
- x = 0;
2572
- xInverted = size.width;
2573
- } else
2574
- if (xSpec && typeof xSpec === 'string' && xSpec.charAt(xSpec.length - 1) === '%') {
2575
- var percent = (parseFloat(xSpec) || 0) / 100;
2576
- x = size.width * percent;
2577
- xInverted = size.width * -percent;
3225
+ // Chrome 51 has a buggy "split" implementation when RegExp#exec !== nativeExec
3226
+ // Weex JS has frozen built-in prototypes, so use try / catch wrapper
3227
+ var SPLIT_WORKS_WITH_OVERWRITTEN_EXEC = !fails$4(function () {
3228
+ // eslint-disable-next-line regexp/no-empty-group -- required for testing
3229
+ var re = /(?:)/;
3230
+ var originalExec = re.exec;
3231
+ re.exec = function () { return originalExec.apply(this, arguments); };
3232
+ var result = 'ab'.split(re);
3233
+ return result.length !== 2 || result[0] !== 'a' || result[1] !== 'b';
3234
+ });
3235
+
3236
+ // @@split logic
3237
+ fixRegExpWellKnownSymbolLogic$2('split', function (SPLIT, nativeSplit, maybeCallNative) {
3238
+ var internalSplit;
3239
+ if (
3240
+ 'abbc'.split(/(b)*/)[1] == 'c' ||
3241
+ // eslint-disable-next-line regexp/no-empty-group -- required for testing
3242
+ 'test'.split(/(?:)/, -1).length != 4 ||
3243
+ 'ab'.split(/(?:ab)*/).length != 2 ||
3244
+ '.'.split(/(.?)(.?)/).length != 4 ||
3245
+ // eslint-disable-next-line regexp/no-empty-capturing-group, regexp/no-empty-group -- required for testing
3246
+ '.'.split(/()()/).length > 1 ||
3247
+ ''.split(/.?/).length
3248
+ ) {
3249
+ // based on es5-shim implementation, need to rework it
3250
+ internalSplit = function (separator, limit) {
3251
+ var string = toString$3(requireObjectCoercible$3(this));
3252
+ var lim = limit === undefined ? MAX_UINT32 : limit >>> 0;
3253
+ if (lim === 0) return [];
3254
+ if (separator === undefined) return [string];
3255
+ // If `separator` is not a regex, use native split
3256
+ if (!isRegExp(separator)) {
3257
+ return nativeSplit.call(string, separator, lim);
3258
+ }
3259
+ var output = [];
3260
+ var flags = (separator.ignoreCase ? 'i' : '') +
3261
+ (separator.multiline ? 'm' : '') +
3262
+ (separator.unicode ? 'u' : '') +
3263
+ (separator.sticky ? 'y' : '');
3264
+ var lastLastIndex = 0;
3265
+ // Make `global` and avoid `lastIndex` issues by working with a copy
3266
+ var separatorCopy = new RegExp(separator.source, flags + 'g');
3267
+ var match, lastIndex, lastLength;
3268
+ while (match = regexpExec.call(separatorCopy, string)) {
3269
+ lastIndex = separatorCopy.lastIndex;
3270
+ if (lastIndex > lastLastIndex) {
3271
+ output.push(string.slice(lastLastIndex, match.index));
3272
+ if (match.length > 1 && match.index < string.length) arrayPush.apply(output, match.slice(1));
3273
+ lastLength = match[0].length;
3274
+ lastLastIndex = lastIndex;
3275
+ if (output.length >= lim) break;
3276
+ }
3277
+ if (separatorCopy.lastIndex === match.index) separatorCopy.lastIndex++; // Avoid an infinite loop
3278
+ }
3279
+ if (lastLastIndex === string.length) {
3280
+ if (lastLength || !separatorCopy.test('')) output.push('');
3281
+ } else output.push(string.slice(lastLastIndex));
3282
+ return output.length > lim ? output.slice(0, lim) : output;
3283
+ };
3284
+ // Chakra, V8
3285
+ } else if ('0'.split(undefined, 0).length) {
3286
+ internalSplit = function (separator, limit) {
3287
+ return separator === undefined && limit === 0 ? [] : nativeSplit.call(this, separator, limit);
3288
+ };
3289
+ } else internalSplit = nativeSplit;
3290
+
3291
+ return [
3292
+ // `String.prototype.split` method
3293
+ // https://tc39.es/ecma262/#sec-string.prototype.split
3294
+ function split(separator, limit) {
3295
+ var O = requireObjectCoercible$3(this);
3296
+ var splitter = separator == undefined ? undefined : getMethod$2(separator, SPLIT);
3297
+ return splitter
3298
+ ? splitter.call(separator, O, limit)
3299
+ : internalSplit.call(toString$3(O), separator, limit);
3300
+ },
3301
+ // `RegExp.prototype[@@split]` method
3302
+ // https://tc39.es/ecma262/#sec-regexp.prototype-@@split
3303
+ //
3304
+ // NOTE: This cannot be properly polyfilled in engines that don't support
3305
+ // the 'y' flag.
3306
+ function (string, limit) {
3307
+ var rx = anObject$2(this);
3308
+ var S = toString$3(string);
3309
+ var res = maybeCallNative(internalSplit, rx, S, limit, internalSplit !== nativeSplit);
3310
+
3311
+ if (res.done) return res.value;
3312
+
3313
+ var C = speciesConstructor(rx, RegExp);
3314
+
3315
+ var unicodeMatching = rx.unicode;
3316
+ var flags = (rx.ignoreCase ? 'i' : '') +
3317
+ (rx.multiline ? 'm' : '') +
3318
+ (rx.unicode ? 'u' : '') +
3319
+ (UNSUPPORTED_Y ? 'g' : 'y');
3320
+
3321
+ // ^(? + rx + ) is needed, in combination with some S slicing, to
3322
+ // simulate the 'y' flag.
3323
+ var splitter = new C(UNSUPPORTED_Y ? '^(?:' + rx.source + ')' : rx, flags);
3324
+ var lim = limit === undefined ? MAX_UINT32 : limit >>> 0;
3325
+ if (lim === 0) return [];
3326
+ if (S.length === 0) return callRegExpExec(splitter, S) === null ? [S] : [];
3327
+ var p = 0;
3328
+ var q = 0;
3329
+ var A = [];
3330
+ while (q < S.length) {
3331
+ splitter.lastIndex = UNSUPPORTED_Y ? 0 : q;
3332
+ var z = callRegExpExec(splitter, UNSUPPORTED_Y ? S.slice(q) : S);
3333
+ var e;
3334
+ if (
3335
+ z === null ||
3336
+ (e = min$1(toLength$2(splitter.lastIndex + (UNSUPPORTED_Y ? q : 0)), S.length)) === p
3337
+ ) {
3338
+ q = advanceStringIndex$2(S, q, unicodeMatching);
3339
+ } else {
3340
+ A.push(S.slice(p, q));
3341
+ if (A.length === lim) return A;
3342
+ for (var i = 1; i <= z.length - 1; i++) {
3343
+ A.push(z[i]);
3344
+ if (A.length === lim) return A;
3345
+ }
3346
+ q = p = e;
3347
+ }
3348
+ }
3349
+ A.push(S.slice(p));
3350
+ return A;
3351
+ }
3352
+ ];
3353
+ }, !SPLIT_WORKS_WITH_OVERWRITTEN_EXEC, UNSUPPORTED_Y);
3354
+
3355
+ var es_array_map = {};
3356
+
3357
+ var aCallable = aCallable$2;
3358
+
3359
+ // optional / simple context binding
3360
+ var functionBindContext = function (fn, that, length) {
3361
+ aCallable(fn);
3362
+ if (that === undefined) return fn;
3363
+ switch (length) {
3364
+ case 0: return function () {
3365
+ return fn.call(that);
3366
+ };
3367
+ case 1: return function (a) {
3368
+ return fn.call(that, a);
3369
+ };
3370
+ case 2: return function (a, b) {
3371
+ return fn.call(that, a, b);
3372
+ };
3373
+ case 3: return function (a, b, c) {
3374
+ return fn.call(that, a, b, c);
3375
+ };
3376
+ }
3377
+ return function (/* ...args */) {
3378
+ return fn.apply(that, arguments);
3379
+ };
3380
+ };
2578
3381
 
2579
- if ( /**@type boolean|null*/rtl === null || rtl === undefined)
2580
- rtl = getComputedStyle(el).direction === 'rtl';
3382
+ var classof = classofRaw$1;
2581
3383
 
2582
- if (rtl) {
2583
- x = size.width - x;
2584
- xInverted = size.width - x;
3384
+ // `IsArray` abstract operation
3385
+ // https://tc39.es/ecma262/#sec-isarray
3386
+ // eslint-disable-next-line es/no-array-isarray -- safe
3387
+ var isArray$1 = Array.isArray || function isArray(argument) {
3388
+ return classof(argument) == 'Array';
3389
+ };
3390
+
3391
+ var isArray = isArray$1;
3392
+ var isConstructor = isConstructor$2;
3393
+ var isObject = isObject$7;
3394
+ var wellKnownSymbol$2 = wellKnownSymbol$a;
3395
+
3396
+ var SPECIES$1 = wellKnownSymbol$2('species');
3397
+
3398
+ // a part of `ArraySpeciesCreate` abstract operation
3399
+ // https://tc39.es/ecma262/#sec-arrayspeciescreate
3400
+ var arraySpeciesConstructor$1 = function (originalArray) {
3401
+ var C;
3402
+ if (isArray(originalArray)) {
3403
+ C = originalArray.constructor;
3404
+ // cross-realm fallback
3405
+ if (isConstructor(C) && (C === Array || isArray(C.prototype))) C = undefined;
3406
+ else if (isObject(C)) {
3407
+ C = C[SPECIES$1];
3408
+ if (C === null) C = undefined;
2585
3409
  }
2586
- } else
2587
- {
2588
- x = parseFloat(xSpec) || 0;
2589
- xInverted = -x;
2590
- }
3410
+ } return C === undefined ? Array : C;
3411
+ };
2591
3412
 
2592
- if (ySpec === 'bottom') {
2593
- y = size.height;
2594
- yInverted = 0;
2595
- } else
2596
- if (ySpec === 'center') {
2597
- y = size.height / 2;
2598
- yInverted = y;
2599
- } else
2600
- if (ySpec === 'top') {
2601
- y = 0;
2602
- yInverted = size.height;
2603
- } else
2604
- if (ySpec && typeof ySpec === 'string' && ySpec.charAt(ySpec.length - 1) === '%') {
2605
- var _percent = (parseFloat(ySpec) || 0) / 100;
2606
- y = size.height * _percent;
2607
- yInverted = size.height * -_percent;
2608
- } else
2609
- {
2610
- y = parseFloat(ySpec) || 0;
2611
- yInverted = -y;
2612
- }
3413
+ var arraySpeciesConstructor = arraySpeciesConstructor$1;
2613
3414
 
2614
- return {
2615
- left: x,
2616
- top: y,
2617
- right: xInverted,
2618
- bottom: yInverted,
2619
- xSpec: xSpec,
2620
- ySpec: ySpec };
3415
+ // `ArraySpeciesCreate` abstract operation
3416
+ // https://tc39.es/ecma262/#sec-arrayspeciescreate
3417
+ var arraySpeciesCreate$1 = function (originalArray, length) {
3418
+ return new (arraySpeciesConstructor(originalArray))(length === 0 ? 0 : length);
3419
+ };
2621
3420
 
3421
+ var bind = functionBindContext;
3422
+ var IndexedObject$1 = indexedObject;
3423
+ var toObject$2 = toObject$4;
3424
+ var lengthOfArrayLike = lengthOfArrayLike$2;
3425
+ var arraySpeciesCreate = arraySpeciesCreate$1;
3426
+
3427
+ var push = [].push;
3428
+
3429
+ // `Array.prototype.{ forEach, map, filter, some, every, find, findIndex, filterReject }` methods implementation
3430
+ var createMethod$1 = function (TYPE) {
3431
+ var IS_MAP = TYPE == 1;
3432
+ var IS_FILTER = TYPE == 2;
3433
+ var IS_SOME = TYPE == 3;
3434
+ var IS_EVERY = TYPE == 4;
3435
+ var IS_FIND_INDEX = TYPE == 6;
3436
+ var IS_FILTER_REJECT = TYPE == 7;
3437
+ var NO_HOLES = TYPE == 5 || IS_FIND_INDEX;
3438
+ return function ($this, callbackfn, that, specificCreate) {
3439
+ var O = toObject$2($this);
3440
+ var self = IndexedObject$1(O);
3441
+ var boundFunction = bind(callbackfn, that, 3);
3442
+ var length = lengthOfArrayLike(self);
3443
+ var index = 0;
3444
+ var create = specificCreate || arraySpeciesCreate;
3445
+ var target = IS_MAP ? create($this, length) : IS_FILTER || IS_FILTER_REJECT ? create($this, 0) : undefined;
3446
+ var value, result;
3447
+ for (;length > index; index++) if (NO_HOLES || index in self) {
3448
+ value = self[index];
3449
+ result = boundFunction(value, index, O);
3450
+ if (TYPE) {
3451
+ if (IS_MAP) target[index] = result; // map
3452
+ else if (result) switch (TYPE) {
3453
+ case 3: return true; // some
3454
+ case 5: return value; // find
3455
+ case 6: return index; // findIndex
3456
+ case 2: push.call(target, value); // filter
3457
+ } else switch (TYPE) {
3458
+ case 4: return false; // every
3459
+ case 7: push.call(target, value); // filterReject
3460
+ }
3461
+ }
3462
+ }
3463
+ return IS_FIND_INDEX ? -1 : IS_SOME || IS_EVERY ? IS_EVERY : target;
3464
+ };
2622
3465
  };
2623
3466
 
2624
- var Css = /*#__PURE__*/Object.freeze({
2625
- __proto__: null,
2626
- getCssProps: getCssProps,
2627
- setCssProps: setCssProps,
2628
- getElementWidth: getElementWidth,
2629
- getElementHeight: getElementHeight,
2630
- setElementWidth: setElementWidth,
2631
- setElementHeight: setElementHeight,
2632
- getPseudoElementWidth: getPseudoElementWidth,
2633
- getPseudoElementHeight: getPseudoElementHeight,
2634
- getElementOffset: getElementOffset,
2635
- anchoredPosition: anchoredPosition
3467
+ var arrayIteration = {
3468
+ // `Array.prototype.forEach` method
3469
+ // https://tc39.es/ecma262/#sec-array.prototype.foreach
3470
+ forEach: createMethod$1(0),
3471
+ // `Array.prototype.map` method
3472
+ // https://tc39.es/ecma262/#sec-array.prototype.map
3473
+ map: createMethod$1(1),
3474
+ // `Array.prototype.filter` method
3475
+ // https://tc39.es/ecma262/#sec-array.prototype.filter
3476
+ filter: createMethod$1(2),
3477
+ // `Array.prototype.some` method
3478
+ // https://tc39.es/ecma262/#sec-array.prototype.some
3479
+ some: createMethod$1(3),
3480
+ // `Array.prototype.every` method
3481
+ // https://tc39.es/ecma262/#sec-array.prototype.every
3482
+ every: createMethod$1(4),
3483
+ // `Array.prototype.find` method
3484
+ // https://tc39.es/ecma262/#sec-array.prototype.find
3485
+ find: createMethod$1(5),
3486
+ // `Array.prototype.findIndex` method
3487
+ // https://tc39.es/ecma262/#sec-array.prototype.findIndex
3488
+ findIndex: createMethod$1(6),
3489
+ // `Array.prototype.filterReject` method
3490
+ // https://github.com/tc39/proposal-array-filtering
3491
+ filterReject: createMethod$1(7)
3492
+ };
3493
+
3494
+ var fails$3 = fails$f;
3495
+ var wellKnownSymbol$1 = wellKnownSymbol$a;
3496
+ var V8_VERSION = engineV8Version;
3497
+
3498
+ var SPECIES = wellKnownSymbol$1('species');
3499
+
3500
+ var arrayMethodHasSpeciesSupport$2 = function (METHOD_NAME) {
3501
+ // We can't use this feature detection in V8 since it causes
3502
+ // deoptimization and serious performance degradation
3503
+ // https://github.com/zloirock/core-js/issues/677
3504
+ return V8_VERSION >= 51 || !fails$3(function () {
3505
+ var array = [];
3506
+ var constructor = array.constructor = {};
3507
+ constructor[SPECIES] = function () {
3508
+ return { foo: 1 };
3509
+ };
3510
+ return array[METHOD_NAME](Boolean).foo !== 1;
3511
+ });
3512
+ };
3513
+
3514
+ 'use strict';
3515
+ var $$4 = _export;
3516
+ var $map = arrayIteration.map;
3517
+ var arrayMethodHasSpeciesSupport$1 = arrayMethodHasSpeciesSupport$2;
3518
+
3519
+ var HAS_SPECIES_SUPPORT$1 = arrayMethodHasSpeciesSupport$1('map');
3520
+
3521
+ // `Array.prototype.map` method
3522
+ // https://tc39.es/ecma262/#sec-array.prototype.map
3523
+ // with adding support of @@species
3524
+ $$4({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT$1 }, {
3525
+ map: function map(callbackfn /* , thisArg */) {
3526
+ return $map(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);
3527
+ }
2636
3528
  });
2637
3529
 
2638
- /**
2639
- * @param {string} tag
2640
- * @param {Object<string, string>} [attrs]
2641
- * @param {Node|Node[]} [children]
2642
- * @returns {Element}
2643
- */
2644
- var createElement = function createElement(tag, attrs, children) {
2645
- var el = document.createElement(tag);
3530
+ var es_array_filter = {};
2646
3531
 
2647
- if (attrs && _typeof(attrs) === 'object')
2648
- setElementAttrs(el, attrs);
3532
+ 'use strict';
3533
+ var $$3 = _export;
3534
+ var $filter = arrayIteration.filter;
3535
+ var arrayMethodHasSpeciesSupport = arrayMethodHasSpeciesSupport$2;
3536
+
3537
+ var HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('filter');
3538
+
3539
+ // `Array.prototype.filter` method
3540
+ // https://tc39.es/ecma262/#sec-array.prototype.filter
3541
+ // with adding support of @@species
3542
+ $$3({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT }, {
3543
+ filter: function filter(callbackfn /* , thisArg */) {
3544
+ return $filter(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);
3545
+ }
3546
+ });
2649
3547
 
2650
- if (children) {
2651
- if (children instanceof Node) {
2652
- el.appendChild(children);
2653
- } else
2654
- if (Array.isArray(children)) {var _iterator = _createForOfIteratorHelper(
2655
- children),_step;try {for (_iterator.s(); !(_step = _iterator.n()).done;) {var child = _step.value;
2656
- el.appendChild(child);}} catch (err) {_iterator.e(err);} finally {_iterator.f();}
3548
+ var es_string_match = {};
3549
+
3550
+ 'use strict';
3551
+ var fixRegExpWellKnownSymbolLogic$1 = fixRegexpWellKnownSymbolLogic;
3552
+ var anObject$1 = anObject$a;
3553
+ var toLength$1 = toLength$5;
3554
+ var toString$2 = toString$7;
3555
+ var requireObjectCoercible$2 = requireObjectCoercible$8;
3556
+ var getMethod$1 = getMethod$4;
3557
+ var advanceStringIndex$1 = advanceStringIndex$3;
3558
+ var regExpExec$1 = regexpExecAbstract;
3559
+
3560
+ // @@match logic
3561
+ fixRegExpWellKnownSymbolLogic$1('match', function (MATCH, nativeMatch, maybeCallNative) {
3562
+ return [
3563
+ // `String.prototype.match` method
3564
+ // https://tc39.es/ecma262/#sec-string.prototype.match
3565
+ function match(regexp) {
3566
+ var O = requireObjectCoercible$2(this);
3567
+ var matcher = regexp == undefined ? undefined : getMethod$1(regexp, MATCH);
3568
+ return matcher ? matcher.call(regexp, O) : new RegExp(regexp)[MATCH](toString$2(O));
3569
+ },
3570
+ // `RegExp.prototype[@@match]` method
3571
+ // https://tc39.es/ecma262/#sec-regexp.prototype-@@match
3572
+ function (string) {
3573
+ var rx = anObject$1(this);
3574
+ var S = toString$2(string);
3575
+ var res = maybeCallNative(nativeMatch, rx, S);
3576
+
3577
+ if (res.done) return res.value;
3578
+
3579
+ if (!rx.global) return regExpExec$1(rx, S);
3580
+
3581
+ var fullUnicode = rx.unicode;
3582
+ rx.lastIndex = 0;
3583
+ var A = [];
3584
+ var n = 0;
3585
+ var result;
3586
+ while ((result = regExpExec$1(rx, S)) !== null) {
3587
+ var matchStr = toString$2(result[0]);
3588
+ A[n] = matchStr;
3589
+ if (matchStr === '') rx.lastIndex = advanceStringIndex$1(S, toLength$1(rx.lastIndex), fullUnicode);
3590
+ n++;
3591
+ }
3592
+ return n === 0 ? null : A;
2657
3593
  }
2658
- }
3594
+ ];
3595
+ });
2659
3596
 
2660
- return el;
3597
+ var es_string_trim = {};
3598
+
3599
+ // a string of all valid unicode whitespaces
3600
+ var whitespaces$2 = '\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u2000\u2001\u2002' +
3601
+ '\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF';
3602
+
3603
+ var requireObjectCoercible$1 = requireObjectCoercible$8;
3604
+ var toString$1 = toString$7;
3605
+ var whitespaces$1 = whitespaces$2;
3606
+
3607
+ var whitespace = '[' + whitespaces$1 + ']';
3608
+ var ltrim = RegExp('^' + whitespace + whitespace + '*');
3609
+ var rtrim = RegExp(whitespace + whitespace + '*$');
3610
+
3611
+ // `String.prototype.{ trim, trimStart, trimEnd, trimLeft, trimRight }` methods implementation
3612
+ var createMethod = function (TYPE) {
3613
+ return function ($this) {
3614
+ var string = toString$1(requireObjectCoercible$1($this));
3615
+ if (TYPE & 1) string = string.replace(ltrim, '');
3616
+ if (TYPE & 2) string = string.replace(rtrim, '');
3617
+ return string;
3618
+ };
2661
3619
  };
2662
3620
 
2663
- /**
2664
- * @param {Element} el
2665
- * @param {Object<string, string>} attrs
2666
- */
2667
- var setElementAttrs = function setElementAttrs(el, attrs) {
2668
- for (var _i = 0, _Object$entries = Object.entries(attrs); _i < _Object$entries.length; _i++) {var _Object$entries$_i = _slicedToArray(_Object$entries[_i], 2),key = _Object$entries$_i[0],value = _Object$entries$_i[1];
2669
- if (value === null || value === undefined)
2670
- continue;
3621
+ var stringTrim = {
3622
+ // `String.prototype.{ trimLeft, trimStart }` methods
3623
+ // https://tc39.es/ecma262/#sec-string.prototype.trimstart
3624
+ start: createMethod(1),
3625
+ // `String.prototype.{ trimRight, trimEnd }` methods
3626
+ // https://tc39.es/ecma262/#sec-string.prototype.trimend
3627
+ end: createMethod(2),
3628
+ // `String.prototype.trim` method
3629
+ // https://tc39.es/ecma262/#sec-string.prototype.trim
3630
+ trim: createMethod(3)
3631
+ };
2671
3632
 
2672
- if (key === 'innerHTML')
2673
- el.innerHTML = String(value);else
2674
- if (key === 'css' && 'style' in el)
2675
- setCssProps(el, value);else
2676
- if (key === 'readOnly' || key === 'tabIndex' || key === 'textContent')
2677
- el[key] = value;else
2678
- el.setAttribute(key, String(value));
2679
- }
3633
+ var PROPER_FUNCTION_NAME = functionName.PROPER;
3634
+ var fails$2 = fails$f;
3635
+ var whitespaces = whitespaces$2;
3636
+
3637
+ var non = '\u200B\u0085\u180E';
3638
+
3639
+ // check that a method works with the correct list
3640
+ // of whitespaces and has a correct name
3641
+ var stringTrimForced = function (METHOD_NAME) {
3642
+ return fails$2(function () {
3643
+ return !!whitespaces[METHOD_NAME]()
3644
+ || non[METHOD_NAME]() !== non
3645
+ || (PROPER_FUNCTION_NAME && whitespaces[METHOD_NAME].name !== METHOD_NAME);
3646
+ });
2680
3647
  };
2681
3648
 
2682
- /**
2683
- * @param {Element} el
2684
- * @param {string} selector
2685
- * @param {Node} [until]
2686
- * @returns {Node|null}
2687
- */
2688
- var closestUntil = function closestUntil(el, selector, until) {
2689
- if ('closest' in el && !until)
2690
- return el.closest(selector);
3649
+ 'use strict';
3650
+ var $$2 = _export;
3651
+ var $trim = stringTrim.trim;
3652
+ var forcedStringTrimMethod = stringTrimForced;
3653
+
3654
+ // `String.prototype.trim` method
3655
+ // https://tc39.es/ecma262/#sec-string.prototype.trim
3656
+ $$2({ target: 'String', proto: true, forced: forcedStringTrimMethod('trim') }, {
3657
+ trim: function trim() {
3658
+ return $trim(this);
3659
+ }
3660
+ });
2691
3661
 
2692
- var matches = Element.prototype.matches ||
2693
- Element.prototype.msMatchesSelector ||
2694
- Element.prototype.webkitMatchesSelector;
3662
+ var getCssProps = function getCssProps(el, props) {
3663
+ var style = getComputedStyle(el);
3664
+ var res = {};var _iterator = _createForOfIteratorHelper(
3665
+ props),_step;try {for (_iterator.s(); !(_step = _iterator.n()).done;) {var prop = _step.value;
3666
+ var val = style[prop];
2695
3667
 
2696
- do {
2697
- if (matches.call(el, selector))
2698
- return el;
3668
+ if ((prop === 'width' || prop === 'height') && val === 'auto' && el instanceof HTMLElement) {
3669
+ val = el['offset' + prop.substr(0, 1).toUpperCase() + prop.substr(1)];
2699
3670
 
2700
- if (until && el === until)
2701
- return null;
3671
+ if (style.boxSizing !== 'border-box') {
3672
+ if (prop === 'width') {
3673
+ val -= parseFloat(style.paddingLeft || 0);
3674
+ val -= parseFloat(style.paddingRight || 0);
3675
+ val -= parseFloat(style.borderLeftWidth || 0);
3676
+ val -= parseFloat(style.borderRightWidth || 0);
3677
+ } else {
3678
+ val -= parseFloat(style.paddingTop || 0);
3679
+ val -= parseFloat(style.paddingBottom || 0);
3680
+ val -= parseFloat(style.borderTopWidth || 0);
3681
+ val -= parseFloat(style.borderBottomWidth || 0);
3682
+ }
3683
+ if (val < 0)
3684
+ val = 0;
3685
+ }
2702
3686
 
2703
- el = el.parentElement || el.parentNode;
2704
- } while (el !== null && el.nodeType === 1);
3687
+ val += 'px';
3688
+ }
2705
3689
 
2706
- return null;
3690
+ res[prop] = val;
3691
+ }} catch (err) {_iterator.e(err);} finally {_iterator.f();}
3692
+ return res;
2707
3693
  };
2708
3694
 
2709
3695
  /**
2710
- * @param {Element} el
2711
- * @param {string} selector
2712
- * @returns {Element|null}
3696
+ * @param {ElementCSSInlineStyle} el
3697
+ * @param {Object<string, string>} props
2713
3698
  */
2714
- var prev = function prev(el, selector) {
2715
- if (!el) return null;
3699
+ var setCssProps = function setCssProps(el, props) {
3700
+ for (var _i = 0, _Object$entries = Object.entries(props); _i < _Object$entries.length; _i++) {var _Object$entries$_i = _slicedToArray(_Object$entries[_i], 2),key = _Object$entries$_i[0],value = _Object$entries$_i[1];
3701
+ el.style[key] = value === undefined || value === null ? '' : String(value);}
3702
+ };
2716
3703
 
2717
- var matches = Element.prototype.matches ||
2718
- Element.prototype.msMatchesSelector ||
2719
- Element.prototype.webkitMatchesSelector;
3704
+ var generateGetElementSizeFn = function generateGetElementSizeFn(pseudo, dim, dimCased, startDim, endDim) {
3705
+ return function () {
3706
+ var /**Element|ElementCSSInlineStyle*/el = arguments.length <= 0 ? undefined : arguments[0],
3707
+ /**string*/pseudoSelector,
3708
+ /**boolean*/paddings,
3709
+ /**boolean*/borders,
3710
+ /**boolean*/margins;
2720
3711
 
2721
- do {
2722
- if (matches.call(el, selector))
2723
- return el;
3712
+ if (pseudo) {
3713
+ pseudoSelector = arguments.length <= 1 ? undefined : arguments[1];
3714
+ paddings = !!(arguments.length <= 2 ? undefined : arguments[2]);
3715
+ borders = !!(arguments.length <= 3 ? undefined : arguments[3]);
3716
+ margins = !!(arguments.length <= 4 ? undefined : arguments[4]);
3717
+ } else {
3718
+ paddings = !!(arguments.length <= 1 ? undefined : arguments[1]);
3719
+ borders = !!(arguments.length <= 2 ? undefined : arguments[2]);
3720
+ margins = !!(arguments.length <= 3 ? undefined : arguments[3]);
3721
+ }
2724
3722
 
2725
- el = el.previousElementSibling || el.previousSibling;
2726
- } while (el !== null && el.nodeType === 1);
3723
+ if ( /**@type Window*/el === window) {
3724
+ return (/**@type Window*/el.document.documentElement["client".concat(dimCased)]);
3725
+ } else
3726
+ if (el.nodeType === 9) {// document
3727
+ var doc = /**@type Document*/el.documentElement;
3728
+ var body = /**@type Document*/el.body;
2727
3729
 
2728
- return null;
2729
- };
3730
+ return Math.max(
3731
+ body["scroll".concat(dimCased)],
3732
+ doc["scroll".concat(dimCased)],
3733
+ body["offset".concat(dimCased)],
3734
+ doc["offset".concat(dimCased)],
3735
+ doc["client".concat(dimCased)]);
2730
3736
 
2731
- /**
2732
- * @param {Element} el
2733
- * @param {string} selector
2734
- * @returns {null|Element}
2735
- */
2736
- var next = function next(el, selector) {
2737
- if (!el) return null;
3737
+ } else
3738
+ {
3739
+ var value;
3740
+ var style;
3741
+ var includesPadding = false,includesBorders = false;
3742
+
3743
+ if (!pseudo && 'getBoundingClientRect' in el) {
3744
+ value = el.getBoundingClientRect()[dim];
3745
+ includesPadding = true;
3746
+ includesBorders = true;
3747
+ }
3748
+
3749
+ if (value === undefined || margins || includesPadding !== paddings || includesBorders !== borders) {
3750
+ style = pseudo ? getComputedStyle(el, pseudoSelector) : getComputedStyle(el);
3751
+ }
3752
+
3753
+ if (value === undefined) {
3754
+ var raw = style[dim];
3755
+ if (raw === 'auto') {// computedStyle is no good here, probably an 'inline' element
3756
+ value = el["client".concat(dimCased)]; // take clientWidth/clientHeight (damn it, it's rounded)
3757
+ includesPadding = true;
3758
+ } else {
3759
+ value = parseFloat(raw);
3760
+ }
3761
+
3762
+ if (style.boxSizing === 'border-box') {
3763
+ includesPadding = true;
3764
+ includesBorders = true;
3765
+ }
3766
+ }
2738
3767
 
2739
- var matches = Element.prototype.matches ||
2740
- Element.prototype.msMatchesSelector ||
2741
- Element.prototype.webkitMatchesSelector;
3768
+ if (paddings !== includesPadding) {
3769
+ var totalPadding = parseFloat(style["padding-".concat(startDim)] || 0) +
3770
+ parseFloat(style["padding-".concat(endDim)] || 0);
3771
+ if (paddings) value += totalPadding;else
3772
+ value -= totalPadding;
3773
+ }
2742
3774
 
2743
- do {
2744
- if (matches.call(el, selector))
2745
- return el;
3775
+ if (borders !== includesBorders) {
3776
+ var totalBorders = parseFloat(style["border-".concat(startDim, "-width")] || 0) +
3777
+ parseFloat(style["border-".concat(endDim, "-width")] || 0);
3778
+ if (borders) value += totalBorders;else
3779
+ value -= totalBorders;
3780
+ }
2746
3781
 
2747
- el = el.nextElementSibling || el.nextSibling;
2748
- } while (el !== null && el.nodeType === 1);
3782
+ if (value < 0)
3783
+ value = 0;
2749
3784
 
2750
- return null;
2751
- };
3785
+ if (margins) {
3786
+ var totalMargins = parseFloat(style["margin-".concat(startDim)] || 0) +
3787
+ parseFloat(style["margin-".concat(endDim)] || 0);
3788
+ value += totalMargins;
3789
+ }
2752
3790
 
2753
- var Dom = /*#__PURE__*/Object.freeze({
2754
- __proto__: null,
2755
- createElement: createElement,
2756
- setElementAttrs: setElementAttrs,
2757
- closestUntil: closestUntil,
2758
- prev: prev,
2759
- next: next
2760
- });
3791
+ return value;
3792
+ }
3793
+ };
3794
+ };
2761
3795
 
2762
- 'use strict';
3796
+ var generateSetElementSizeFn = function generateSetElementSizeFn(dim, dimCased, startDim, endDim) {
3797
+ return function ( /**Element|ElementCSSInlineStyle*/el,
3798
+ /**number*/value)
3799
+ {var paddings = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;var borders = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;var margins = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : false;
2763
3800
 
3801
+ if ( /**@type Window*/el === window) {
3802
+ return;
3803
+ }
2764
3804
 
2765
- // `RegExp.prototype.flags` getter implementation
2766
- // https://tc39.es/ecma262/#sec-get-regexp.prototype.flags
2767
- var regexpFlags = function () {
2768
- var that = anObject(this);
2769
- var result = '';
2770
- if (that.global) result += 'g';
2771
- if (that.ignoreCase) result += 'i';
2772
- if (that.multiline) result += 'm';
2773
- if (that.dotAll) result += 's';
2774
- if (that.unicode) result += 'u';
2775
- if (that.sticky) result += 'y';
2776
- return result;
2777
- };
3805
+ if (el.nodeType === 9) {// document
3806
+ return;
3807
+ }
2778
3808
 
2779
- 'use strict';
3809
+ var style = getComputedStyle(el);
2780
3810
 
3811
+ var includesPaddingAndBorders = false;
2781
3812
 
3813
+ if (style.boxSizing === 'border-box') {
3814
+ includesPaddingAndBorders = true;
3815
+ }
2782
3816
 
2783
- // babel-minify transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError,
2784
- // so we use an intermediate function.
2785
- function RE(s, f) {
2786
- return RegExp(s, f);
2787
- }
3817
+ paddings = !!paddings;
3818
+ borders = !!borders;
3819
+ margins = !!margins;
2788
3820
 
2789
- var UNSUPPORTED_Y$1 = fails(function () {
2790
- // babel-minify transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError
2791
- var re = RE('a', 'y');
2792
- re.lastIndex = 2;
2793
- return re.exec('abcd') != null;
2794
- });
3821
+ if (margins)
3822
+ value -= (parseFloat(style["margin-".concat(startDim)]) || 0) + (parseFloat(style["margin-".concat(endDim)]) || 0);
2795
3823
 
2796
- var BROKEN_CARET = fails(function () {
2797
- // https://bugzilla.mozilla.org/show_bug.cgi?id=773687
2798
- var re = RE('^r', 'gy');
2799
- re.lastIndex = 2;
2800
- return re.exec('str') != null;
2801
- });
3824
+ if (paddings !== includesPaddingAndBorders) {
3825
+ var totalPadding = parseFloat(style["padding-".concat(startDim)] || 0) +
3826
+ parseFloat(style["padding-".concat(endDim)] || 0);
3827
+ if (paddings) value -= totalPadding;else
3828
+ value += totalPadding;
3829
+ }
2802
3830
 
2803
- var regexpStickyHelpers = {
2804
- UNSUPPORTED_Y: UNSUPPORTED_Y$1,
2805
- BROKEN_CARET: BROKEN_CARET
2806
- };
3831
+ if (borders !== includesPaddingAndBorders) {
3832
+ var totalBorders = (parseFloat(style["border-".concat(startDim, "-width")]) || 0) + (
3833
+ parseFloat(style["border-".concat(endDim, "-width")]) || 0);
3834
+ if (borders) value -= totalBorders;else
3835
+ value += totalBorders;
3836
+ }
2807
3837
 
2808
- 'use strict';
3838
+ if (value < 0)
3839
+ value = 0;
2809
3840
 
3841
+ el.style[dim] = value + 'px';
3842
+ };
3843
+ };
2810
3844
 
3845
+ /**
3846
+ * Gets the width of an element, with fractions
3847
+ * @function getElementWidth
3848
+ * @param {Element} el
3849
+ * @param {boolean} [paddings=false] - include paddings
3850
+ * @param {boolean} [borders=false] - include borders
3851
+ * @param {boolean} [margins=false] - include margins
3852
+ * @returns {number}
3853
+ */
3854
+ var getElementWidth = generateGetElementSizeFn(false, 'width', 'Width', 'left', 'right');
2811
3855
 
2812
- var nativeExec = RegExp.prototype.exec;
2813
- // This always refers to the native implementation, because the
2814
- // String#replace polyfill uses ./fix-regexp-well-known-symbol-logic.js,
2815
- // which loads this file before patching the method.
2816
- var nativeReplace = String.prototype.replace;
3856
+ /**
3857
+ * Gets the width of an element, with fractions
3858
+ * @function getElementHeight
3859
+ * @param {Element} el
3860
+ * @param {boolean} [paddings=false] - include paddings
3861
+ * @param {boolean} [borders=false] - include borders
3862
+ * @param {boolean} [margins=false] - include margins
3863
+ * @returns {number}
3864
+ */
3865
+ var getElementHeight = generateGetElementSizeFn(false, 'height', 'Height', 'top', 'bottom');
2817
3866
 
2818
- var patchedExec = nativeExec;
3867
+ /**
3868
+ * Gets the width of an element, with fractions
3869
+ * @function getPseudoElementWidth
3870
+ * @param {Element} el
3871
+ * @param {string} pseudo
3872
+ * @param {boolean} [paddings=false] - include paddings
3873
+ * @param {boolean} [borders=false] - include borders
3874
+ * @param {boolean} [margins=false] - include margins
3875
+ * @returns {number}
3876
+ */
3877
+ var getPseudoElementWidth = generateGetElementSizeFn(true, 'width', 'Width', 'left', 'right');
2819
3878
 
2820
- var UPDATES_LAST_INDEX_WRONG = (function () {
2821
- var re1 = /a/;
2822
- var re2 = /b*/g;
2823
- nativeExec.call(re1, 'a');
2824
- nativeExec.call(re2, 'a');
2825
- return re1.lastIndex !== 0 || re2.lastIndex !== 0;
2826
- })();
3879
+ /**
3880
+ * Gets the width of an element, with fractions
3881
+ * @function getPseudoElementHeight
3882
+ * @param {Element} el
3883
+ * @param {string} pseudo
3884
+ * @param {boolean} [paddings=false] - include paddings
3885
+ * @param {boolean} [borders=false] - include borders
3886
+ * @param {boolean} [margins=false] - include margins
3887
+ * @returns {number}
3888
+ */
3889
+ var getPseudoElementHeight = generateGetElementSizeFn(true, 'height', 'Height', 'top', 'bottom');
2827
3890
 
2828
- var UNSUPPORTED_Y = regexpStickyHelpers.UNSUPPORTED_Y || regexpStickyHelpers.BROKEN_CARET;
3891
+ /**
3892
+ * Sets the width of an element
3893
+ * @function setElementWidth
3894
+ * @param {Element} el
3895
+ * @param {number} value
3896
+ * @param {boolean} [paddings=false] - include paddings
3897
+ * @param {boolean} [borders=false] - include borders
3898
+ * @param {boolean} [margins=false] - include margins
3899
+ */
3900
+ var setElementWidth = generateSetElementSizeFn('width', 'Width', 'left', 'right');
2829
3901
 
2830
- // nonparticipating capturing group, copied from es5-shim's String#split patch.
2831
- // eslint-disable-next-line regexp/no-assertion-capturing-group, regexp/no-empty-group -- required for testing
2832
- var NPCG_INCLUDED = /()??/.exec('')[1] !== undefined;
3902
+ /**
3903
+ * Sets the width of an element, with fractions
3904
+ * @function setElementHeight
3905
+ * @param {Element} el
3906
+ * @param {number} value
3907
+ * @param {boolean} [paddings=false] - include paddings
3908
+ * @param {boolean} [borders=false] - include borders
3909
+ * @param {boolean} [margins=false] - include margins
3910
+ */
3911
+ var setElementHeight = generateSetElementSizeFn('height', 'Height', 'top', 'bottom');
2833
3912
 
2834
- var PATCH = UPDATES_LAST_INDEX_WRONG || NPCG_INCLUDED || UNSUPPORTED_Y;
3913
+ /**
3914
+ * Find offset of an element relative to the document, considering scroll offsets
3915
+ * @param {Element} el
3916
+ * @returns {{top: number, left: number}}
3917
+ */
3918
+ var getElementOffset = function getElementOffset(el) {
3919
+ if (!el.getClientRects().length) {
3920
+ return { top: 0, left: 0 };
3921
+ }
2835
3922
 
2836
- if (PATCH) {
2837
- patchedExec = function exec(str) {
2838
- var re = this;
2839
- var lastIndex, reCopy, match, i;
2840
- var sticky = UNSUPPORTED_Y && re.sticky;
2841
- var flags = regexpFlags.call(re);
2842
- var source = re.source;
2843
- var charsAdded = 0;
2844
- var strCopy = str;
3923
+ var rect = el.getBoundingClientRect();
3924
+ var view = el.ownerDocument.defaultView;
2845
3925
 
2846
- if (sticky) {
2847
- flags = flags.replace('y', '');
2848
- if (flags.indexOf('g') === -1) {
2849
- flags += 'g';
2850
- }
3926
+ return {
3927
+ top: rect.top + view.pageYOffset,
3928
+ left: rect.left + view.pageXOffset };
2851
3929
 
2852
- strCopy = String(str).slice(re.lastIndex);
2853
- // Support anchored sticky behavior.
2854
- if (re.lastIndex > 0 && (!re.multiline || re.multiline && str[re.lastIndex - 1] !== '\n')) {
2855
- source = '(?: ' + source + ')';
2856
- strCopy = ' ' + strCopy;
2857
- charsAdded++;
2858
- }
2859
- // ^(? + rx + ) is needed, in combination with some str slicing, to
2860
- // simulate the 'y' flag.
2861
- reCopy = new RegExp('^(?:' + source + ')', flags);
2862
- }
3930
+ };
2863
3931
 
2864
- if (NPCG_INCLUDED) {
2865
- reCopy = new RegExp('^' + source + '$(?!\\s)', flags);
2866
- }
2867
- if (UPDATES_LAST_INDEX_WRONG) lastIndex = re.lastIndex;
3932
+ /**
3933
+ * Calculates the anchored position relative to this element. <br />
3934
+ * The return value will include an `left`/`top` position on left/top axis, <br />
3935
+ * an `right`/`bottom` position which is the exact opposite, <br />
3936
+ * and the `xSpec`/`ySpec` after normalizing rtl based values (`'start'`/`'end'`).
3937
+ * @param {Element} el? - the target element to base the calculations on. If `size` and `rtl` are specified - then this argument is optional.
3938
+ * @param {'left'|'center'|'right'|'start'|'end'|string|number} xSpec - horizontal anchor specification (could be either `'left'|'center'|'right'|'start'|'end'` or a percentage `'50%'` or a fixed decimal `Number`)
3939
+ * @param {'top'|'center'|'bottom'|string|number} ySpec - vertical anchor specification (could be either `'top'|'center'|'bottom'` or a percentage `'50%'` or a fixed decimal `Number`)
3940
+ * @param {{width: number, height: number}?} size - can be specified if already known, to avoid extra dom calculations. This is the outer size of the element, including padding and borders.
3941
+ * @param {boolean?} [rtl] - if not specified and values like `'start'`/`'end'` are use, then `rtl` is auto detected
3942
+ * @returns {{left: number, top: number, right: number, bottom: number, xSpec: string|number, ySpec: string|number}}
3943
+ */
3944
+ var anchoredPosition = function anchoredPosition(el, xSpec, ySpec, size, rtl) {
3945
+ if (!size) {
3946
+ size = {
3947
+ width: getElementWidth(el, true, true),
3948
+ height: getElementWidth(el, true, true) };
2868
3949
 
2869
- match = nativeExec.call(sticky ? reCopy : re, strCopy);
3950
+ }
2870
3951
 
2871
- if (sticky) {
2872
- if (match) {
2873
- match.input = match.input.slice(charsAdded);
2874
- match[0] = match[0].slice(charsAdded);
2875
- match.index = re.lastIndex;
2876
- re.lastIndex += match[0].length;
2877
- } else re.lastIndex = 0;
2878
- } else if (UPDATES_LAST_INDEX_WRONG && match) {
2879
- re.lastIndex = re.global ? match.index + match[0].length : lastIndex;
2880
- }
2881
- if (NPCG_INCLUDED && match && match.length > 1) {
2882
- // Fix browsers whose `exec` methods don't consistently return `undefined`
2883
- // for NPCG, like IE8. NOTE: This doesn' work for /(.?)?/
2884
- nativeReplace.call(match[0], reCopy, function () {
2885
- for (i = 1; i < arguments.length - 2; i++) {
2886
- if (arguments[i] === undefined) match[i] = undefined;
2887
- }
2888
- });
3952
+ if (xSpec === 'start' || xSpec === 'end') {
3953
+ if ( /**@type boolean|null*/rtl === null || rtl === undefined) {
3954
+ rtl = getComputedStyle(el).direction === 'rtl';
2889
3955
  }
3956
+ xSpec = xSpec === 'start' ? rtl ? 'right' : 'left' : rtl ? 'left' : 'right';
3957
+ }
2890
3958
 
2891
- return match;
2892
- };
2893
- }
2894
-
2895
- var regexpExec = patchedExec;
3959
+ var x, y;
3960
+ var xInverted, yInverted;
2896
3961
 
2897
- 'use strict';
3962
+ if (xSpec === 'right') {
3963
+ x = size.width;
3964
+ xInverted = 0;
3965
+ } else
3966
+ if (xSpec === 'center') {
3967
+ x = size.width / 2;
3968
+ xInverted = x;
3969
+ } else
3970
+ if (xSpec === 'left') {
3971
+ x = 0;
3972
+ xInverted = size.width;
3973
+ } else
3974
+ if (xSpec && typeof xSpec === 'string' && xSpec.charAt(xSpec.length - 1) === '%') {
3975
+ var percent = (parseFloat(xSpec) || 0) / 100;
3976
+ x = size.width * percent;
3977
+ xInverted = size.width * -percent;
2898
3978
 
3979
+ if ( /**@type boolean|null*/rtl === null || rtl === undefined)
3980
+ rtl = getComputedStyle(el).direction === 'rtl';
2899
3981
 
3982
+ if (rtl) {
3983
+ x = size.width - x;
3984
+ xInverted = size.width - x;
3985
+ }
3986
+ } else
3987
+ {
3988
+ x = parseFloat(xSpec) || 0;
3989
+ xInverted = -x;
3990
+ }
2900
3991
 
2901
- // `RegExp.prototype.exec` method
2902
- // https://tc39.es/ecma262/#sec-regexp.prototype.exec
2903
- _export({ target: 'RegExp', proto: true, forced: /./.exec !== regexpExec }, {
2904
- exec: regexpExec
2905
- });
3992
+ if (ySpec === 'bottom') {
3993
+ y = size.height;
3994
+ yInverted = 0;
3995
+ } else
3996
+ if (ySpec === 'center') {
3997
+ y = size.height / 2;
3998
+ yInverted = y;
3999
+ } else
4000
+ if (ySpec === 'top') {
4001
+ y = 0;
4002
+ yInverted = size.height;
4003
+ } else
4004
+ if (ySpec && typeof ySpec === 'string' && ySpec.charAt(ySpec.length - 1) === '%') {
4005
+ var _percent = (parseFloat(ySpec) || 0) / 100;
4006
+ y = size.height * _percent;
4007
+ yInverted = size.height * -_percent;
4008
+ } else
4009
+ {
4010
+ y = parseFloat(ySpec) || 0;
4011
+ yInverted = -y;
4012
+ }
2906
4013
 
2907
- var es_regexp_exec = {
4014
+ return {
4015
+ left: x,
4016
+ top: y,
4017
+ right: xInverted,
4018
+ bottom: yInverted,
4019
+ xSpec: xSpec,
4020
+ ySpec: ySpec };
2908
4021
 
2909
4022
  };
2910
4023
 
2911
- var engineIsNode = classofRaw(global_1.process) == 'process';
4024
+ var timeToMs = function timeToMs(value) {
4025
+ if (!value) {
4026
+ return;
4027
+ }
2912
4028
 
2913
- var engineUserAgent = getBuiltIn('navigator', 'userAgent') || '';
4029
+ var isMs = value.endsWith('ms');
4030
+ return parseFloat(value) * (isMs ? 1 : 1000);
4031
+ };
2914
4032
 
2915
- var process = global_1.process;
2916
- var versions = process && process.versions;
2917
- var v8 = versions && versions.v8;
2918
- var match, version;
4033
+ var isTimeString = function isTimeString(value) {
4034
+ return /^-?(0?\.)?\d+m?s$/.test(value);
4035
+ };
2919
4036
 
2920
- if (v8) {
2921
- match = v8.split('.');
2922
- version = match[0] + match[1];
2923
- } else if (engineUserAgent) {
2924
- match = engineUserAgent.match(/Edge\/(\d+)/);
2925
- if (!match || match[1] >= 74) {
2926
- match = engineUserAgent.match(/Chrome\/(\d+)/);
2927
- if (match) version = match[1];
2928
- }
2929
- }
4037
+ var parseSingleTransition = function parseSingleTransition(transition) {
4038
+ var parts = transition.split(/\s+/),
4039
+ name = parts[0],
4040
+ duration = parts[1],
4041
+ timingFunctionOrDelay = parts[2],
4042
+ delay = parts[3];
2930
4043
 
2931
- var engineV8Version = version && +version;
4044
+ if (isTimeString(timingFunctionOrDelay)) {
4045
+ return {
4046
+ delay: timeToMs(timingFunctionOrDelay),
4047
+ duration: timeToMs(duration),
4048
+ name: name };
2932
4049
 
2933
- var nativeSymbol = !!Object.getOwnPropertySymbols && !fails(function () {
2934
- /* global Symbol -- required for testing */
2935
- return !Symbol.sham &&
2936
- // Chrome 38 Symbol has incorrect toString conversion
2937
- // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances
2938
- (engineIsNode ? engineV8Version === 38 : engineV8Version > 37 && engineV8Version < 41);
2939
- });
4050
+ }
2940
4051
 
2941
- var useSymbolAsUid = nativeSymbol
2942
- /* global Symbol -- safe */
2943
- && !Symbol.sham
2944
- && typeof Symbol.iterator == 'symbol';
4052
+ return {
4053
+ delay: timeToMs(delay),
4054
+ duration: timeToMs(duration),
4055
+ name: name,
4056
+ timingFunction: timingFunctionOrDelay };
2945
4057
 
2946
- var WellKnownSymbolsStore = shared('wks');
2947
- var Symbol$1 = global_1.Symbol;
2948
- var createWellKnownSymbol = useSymbolAsUid ? Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid;
4058
+ };
2949
4059
 
2950
- var wellKnownSymbol = function (name) {
2951
- if (!has$1(WellKnownSymbolsStore, name) || !(nativeSymbol || typeof WellKnownSymbolsStore[name] == 'string')) {
2952
- if (nativeSymbol && has$1(Symbol$1, name)) {
2953
- WellKnownSymbolsStore[name] = Symbol$1[name];
2954
- } else {
2955
- WellKnownSymbolsStore[name] = createWellKnownSymbol('Symbol.' + name);
2956
- }
2957
- } return WellKnownSymbolsStore[name];
4060
+ var parseTransition = function parseTransition(transition) {
4061
+ return transition.match(/([^,()]|\([^)]*\))+/g).map(function (value) {return value.trim();}).filter(function (value) {return value.length > 0;}).map(parseSingleTransition);
2958
4062
  };
2959
4063
 
2960
- 'use strict';
2961
- // TODO: Remove from `core-js@4` since it's moved to entry points
4064
+ var Css = /*#__PURE__*/Object.freeze({
4065
+ __proto__: null,
4066
+ getCssProps: getCssProps,
4067
+ setCssProps: setCssProps,
4068
+ getElementWidth: getElementWidth,
4069
+ getElementHeight: getElementHeight,
4070
+ setElementWidth: setElementWidth,
4071
+ setElementHeight: setElementHeight,
4072
+ getPseudoElementWidth: getPseudoElementWidth,
4073
+ getPseudoElementHeight: getPseudoElementHeight,
4074
+ getElementOffset: getElementOffset,
4075
+ anchoredPosition: anchoredPosition,
4076
+ parseTransition: parseTransition,
4077
+ parseSingleTransition: parseSingleTransition,
4078
+ isTimeString: isTimeString,
4079
+ timeToMs: timeToMs
4080
+ });
2962
4081
 
4082
+ /**
4083
+ * @param {string} tag
4084
+ * @param {Object<string, string>} [attrs]
4085
+ * @param {Node|Node[]} [children]
4086
+ * @returns {Element}
4087
+ */
4088
+ var createElement = function createElement(tag, attrs, children) {
4089
+ var el = document.createElement(tag);
2963
4090
 
4091
+ if (attrs && _typeof(attrs) === 'object')
4092
+ setElementAttrs(el, attrs);
2964
4093
 
4094
+ if (children) {
4095
+ if (children instanceof Node) {
4096
+ el.appendChild(children);
4097
+ } else
4098
+ if (Array.isArray(children)) {var _iterator = _createForOfIteratorHelper(
4099
+ children),_step;try {for (_iterator.s(); !(_step = _iterator.n()).done;) {var child = _step.value;
4100
+ el.appendChild(child);}} catch (err) {_iterator.e(err);} finally {_iterator.f();}
4101
+ }
4102
+ }
2965
4103
 
4104
+ return el;
4105
+ };
2966
4106
 
4107
+ /**
4108
+ * @param {Element} el
4109
+ * @param {Object<string, string>} attrs
4110
+ */
4111
+ var setElementAttrs = function setElementAttrs(el, attrs) {
4112
+ for (var _i = 0, _Object$entries = Object.entries(attrs); _i < _Object$entries.length; _i++) {var _Object$entries$_i = _slicedToArray(_Object$entries[_i], 2),key = _Object$entries$_i[0],value = _Object$entries$_i[1];
4113
+ if (value === null || value === undefined)
4114
+ continue;
2967
4115
 
4116
+ if (key === 'innerHTML')
4117
+ el.innerHTML = String(value);else
4118
+ if (key === 'css' && 'style' in el)
4119
+ setCssProps(el, value);else
4120
+ if (key in el && key !== 'style')
4121
+ el[key] = value;else
4122
+ el.setAttribute(key, String(value));
4123
+ }
4124
+ };
2968
4125
 
2969
- var SPECIES$1 = wellKnownSymbol('species');
4126
+ /**
4127
+ * @param {Element} el
4128
+ * @param {string} selector
4129
+ * @param {Node} [until]
4130
+ * @returns {Node|null}
4131
+ */
4132
+ var closestUntil = function closestUntil(el, selector, until) {
4133
+ if ('closest' in el && !until)
4134
+ return el.closest(selector);
2970
4135
 
2971
- var REPLACE_SUPPORTS_NAMED_GROUPS = !fails(function () {
2972
- // #replace needs built-in support for named groups.
2973
- // #match works fine because it just return the exec results, even if it has
2974
- // a "grops" property.
2975
- var re = /./;
2976
- re.exec = function () {
2977
- var result = [];
2978
- result.groups = { a: '7' };
2979
- return result;
2980
- };
2981
- return ''.replace(re, '$<a>') !== '7';
2982
- });
4136
+ var matches = Element.prototype.matches ||
4137
+ Element.prototype.msMatchesSelector ||
4138
+ Element.prototype.webkitMatchesSelector;
2983
4139
 
2984
- // IE <= 11 replaces $0 with the whole match, as if it was $&
2985
- // https://stackoverflow.com/questions/6024666/getting-ie-to-replace-a-regex-with-the-literal-string-0
2986
- var REPLACE_KEEPS_$0 = (function () {
2987
- return 'a'.replace(/./, '$0') === '$0';
2988
- })();
4140
+ do {
4141
+ if (matches.call(el, selector))
4142
+ return el;
2989
4143
 
2990
- var REPLACE = wellKnownSymbol('replace');
2991
- // Safari <= 13.0.3(?) substitutes nth capture where n>m with an empty string
2992
- var REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE = (function () {
2993
- if (/./[REPLACE]) {
2994
- return /./[REPLACE]('a', '$0') === '';
2995
- }
2996
- return false;
2997
- })();
4144
+ if (until && el === until)
4145
+ return null;
2998
4146
 
2999
- // Chrome 51 has a buggy "split" implementation when RegExp#exec !== nativeExec
3000
- // Weex JS has frozen built-in prototypes, so use try / catch wrapper
3001
- var SPLIT_WORKS_WITH_OVERWRITTEN_EXEC = !fails(function () {
3002
- // eslint-disable-next-line regexp/no-empty-group -- required for testing
3003
- var re = /(?:)/;
3004
- var originalExec = re.exec;
3005
- re.exec = function () { return originalExec.apply(this, arguments); };
3006
- var result = 'ab'.split(re);
3007
- return result.length !== 2 || result[0] !== 'a' || result[1] !== 'b';
3008
- });
4147
+ el = el.parentElement || el.parentNode;
4148
+ } while (el !== null && el.nodeType === 1);
3009
4149
 
3010
- var fixRegexpWellKnownSymbolLogic = function (KEY, length, exec, sham) {
3011
- var SYMBOL = wellKnownSymbol(KEY);
4150
+ return null;
4151
+ };
3012
4152
 
3013
- var DELEGATES_TO_SYMBOL = !fails(function () {
3014
- // String methods call symbol-named RegEp methods
3015
- var O = {};
3016
- O[SYMBOL] = function () { return 7; };
3017
- return ''[KEY](O) != 7;
3018
- });
4153
+ /**
4154
+ * @param {Element} el
4155
+ * @param {string} selector
4156
+ * @returns {Element|null}
4157
+ */
4158
+ var prev = function prev(el, selector) {
4159
+ if (!el) return null;
3019
4160
 
3020
- var DELEGATES_TO_EXEC = DELEGATES_TO_SYMBOL && !fails(function () {
3021
- // Symbol-named RegExp methods call .exec
3022
- var execCalled = false;
3023
- var re = /a/;
4161
+ var matches = Element.prototype.matches ||
4162
+ Element.prototype.msMatchesSelector ||
4163
+ Element.prototype.webkitMatchesSelector;
3024
4164
 
3025
- if (KEY === 'split') {
3026
- // We can't use real regex here since it causes deoptimization
3027
- // and serious performance degradation in V8
3028
- // https://github.com/zloirock/core-js/issues/306
3029
- re = {};
3030
- // RegExp[@@split] doesn't call the regex's exec method, but first creates
3031
- // a new one. We need to return the patched regex when creating the new one.
3032
- re.constructor = {};
3033
- re.constructor[SPECIES$1] = function () { return re; };
3034
- re.flags = '';
3035
- re[SYMBOL] = /./[SYMBOL];
3036
- }
4165
+ do {
4166
+ if (matches.call(el, selector))
4167
+ return el;
3037
4168
 
3038
- re.exec = function () { execCalled = true; return null; };
4169
+ el = el.previousElementSibling || el.previousSibling;
4170
+ } while (el !== null && el.nodeType === 1);
3039
4171
 
3040
- re[SYMBOL]('');
3041
- return !execCalled;
3042
- });
4172
+ return null;
4173
+ };
3043
4174
 
3044
- if (
3045
- !DELEGATES_TO_SYMBOL ||
3046
- !DELEGATES_TO_EXEC ||
3047
- (KEY === 'replace' && !(
3048
- REPLACE_SUPPORTS_NAMED_GROUPS &&
3049
- REPLACE_KEEPS_$0 &&
3050
- !REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE
3051
- )) ||
3052
- (KEY === 'split' && !SPLIT_WORKS_WITH_OVERWRITTEN_EXEC)
3053
- ) {
3054
- var nativeRegExpMethod = /./[SYMBOL];
3055
- var methods = exec(SYMBOL, ''[KEY], function (nativeMethod, regexp, str, arg2, forceStringMethod) {
3056
- if (regexp.exec === regexpExec) {
3057
- if (DELEGATES_TO_SYMBOL && !forceStringMethod) {
3058
- // The native String method already delegates to @@method (this
3059
- // polyfilled function), leasing to infinite recursion.
3060
- // We avoid it by directly calling the native @@method method.
3061
- return { done: true, value: nativeRegExpMethod.call(regexp, str, arg2) };
3062
- }
3063
- return { done: true, value: nativeMethod.call(str, regexp, arg2) };
3064
- }
3065
- return { done: false };
3066
- }, {
3067
- REPLACE_KEEPS_$0: REPLACE_KEEPS_$0,
3068
- REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE: REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE
3069
- });
3070
- var stringMethod = methods[0];
3071
- var regexMethod = methods[1];
3072
-
3073
- redefine(String.prototype, KEY, stringMethod);
3074
- redefine(RegExp.prototype, SYMBOL, length == 2
3075
- // 21.2.5.8 RegExp.prototype[@@replace](string, replaceValue)
3076
- // 21.2.5.11 RegExp.prototype[@@split](string, limit)
3077
- ? function (string, arg) { return regexMethod.call(string, this, arg); }
3078
- // 21.2.5.6 RegExp.prototype[@@match](string)
3079
- // 21.2.5.9 RegExp.prototype[@@search](string)
3080
- : function (string) { return regexMethod.call(string, this); }
3081
- );
3082
- }
4175
+ /**
4176
+ * @param {Element} el
4177
+ * @param {string} selector
4178
+ * @returns {null|Element}
4179
+ */
4180
+ var next = function next(el, selector) {
4181
+ if (!el) return null;
3083
4182
 
3084
- if (sham) createNonEnumerableProperty(RegExp.prototype[SYMBOL], 'sham', true);
3085
- };
4183
+ var matches = Element.prototype.matches ||
4184
+ Element.prototype.msMatchesSelector ||
4185
+ Element.prototype.webkitMatchesSelector;
3086
4186
 
3087
- // `String.prototype.{ codePointAt, at }` methods implementation
3088
- var createMethod = function (CONVERT_TO_STRING) {
3089
- return function ($this, pos) {
3090
- var S = String(requireObjectCoercible($this));
3091
- var position = toInteger(pos);
3092
- var size = S.length;
3093
- var first, second;
3094
- if (position < 0 || position >= size) return CONVERT_TO_STRING ? '' : undefined;
3095
- first = S.charCodeAt(position);
3096
- return first < 0xD800 || first > 0xDBFF || position + 1 === size
3097
- || (second = S.charCodeAt(position + 1)) < 0xDC00 || second > 0xDFFF
3098
- ? CONVERT_TO_STRING ? S.charAt(position) : first
3099
- : CONVERT_TO_STRING ? S.slice(position, position + 2) : (first - 0xD800 << 10) + (second - 0xDC00) + 0x10000;
3100
- };
4187
+ do {
4188
+ if (matches.call(el, selector))
4189
+ return el;
4190
+
4191
+ el = el.nextElementSibling || el.nextSibling;
4192
+ } while (el !== null && el.nodeType === 1);
4193
+
4194
+ return null;
3101
4195
  };
3102
4196
 
3103
- var stringMultibyte = {
3104
- // `String.prototype.codePointAt` method
3105
- // https://tc39.es/ecma262/#sec-string.prototype.codepointat
3106
- codeAt: createMethod(false),
3107
- // `String.prototype.at` method
3108
- // https://github.com/mathiasbynens/String.prototype.at
3109
- charAt: createMethod(true)
4197
+ var unwrapChildren = function unwrapChildren(el) {
4198
+ var parent = el.parentNode;
4199
+ while (el.firstChild) {
4200
+ parent.insertBefore(el.firstChild, el);}
4201
+ parent.removeChild(el);
3110
4202
  };
3111
- var stringMultibyte_1 = stringMultibyte.codeAt;
3112
- var stringMultibyte_2 = stringMultibyte.charAt;
3113
4203
 
3114
- 'use strict';
3115
- var charAt = stringMultibyte.charAt;
4204
+ var Dom = /*#__PURE__*/Object.freeze({
4205
+ __proto__: null,
4206
+ createElement: createElement,
4207
+ setElementAttrs: setElementAttrs,
4208
+ closestUntil: closestUntil,
4209
+ prev: prev,
4210
+ next: next,
4211
+ unwrapChildren: unwrapChildren
4212
+ });
3116
4213
 
3117
- // `AdvanceStringIndex` abstract operation
3118
- // https://tc39.es/ecma262/#sec-advancestringindex
3119
- var advanceStringIndex = function (S, index, unicode) {
3120
- return index + (unicode ? charAt(S, index).length : 1);
3121
- };
4214
+ var es_string_replace = {};
3122
4215
 
3123
- // `ToObject` abstract operation
3124
- // https://tc39.es/ecma262/#sec-toobject
3125
- var toObject = function (argument) {
3126
- return Object(requireObjectCoercible(argument));
3127
- };
4216
+ var toObject$1 = toObject$4;
3128
4217
 
3129
4218
  var floor = Math.floor;
3130
4219
  var replace = ''.replace;
3131
4220
  var SUBSTITUTION_SYMBOLS = /\$([$&'`]|\d{1,2}|<[^>]*>)/g;
3132
4221
  var SUBSTITUTION_SYMBOLS_NO_NAMED = /\$([$&'`]|\d{1,2})/g;
3133
4222
 
4223
+ // `GetSubstitution` abstract operation
3134
4224
  // https://tc39.es/ecma262/#sec-getsubstitution
3135
- var getSubstitution = function (matched, str, position, captures, namedCaptures, replacement) {
4225
+ var getSubstitution$1 = function (matched, str, position, captures, namedCaptures, replacement) {
3136
4226
  var tailPos = position + matched.length;
3137
4227
  var m = captures.length;
3138
4228
  var symbols = SUBSTITUTION_SYMBOLS_NO_NAMED;
3139
4229
  if (namedCaptures !== undefined) {
3140
- namedCaptures = toObject(namedCaptures);
4230
+ namedCaptures = toObject$1(namedCaptures);
3141
4231
  symbols = SUBSTITUTION_SYMBOLS;
3142
4232
  }
3143
4233
  return replace.call(replacement, symbols, function (match, ch) {
@@ -3165,46 +4255,57 @@ var getSubstitution = function (matched, str, position, captures, namedCaptures,
3165
4255
  });
3166
4256
  };
3167
4257
 
3168
- // `RegExpExec` abstract operation
3169
- // https://tc39.es/ecma262/#sec-regexpexec
3170
- var regexpExecAbstract = function (R, S) {
3171
- var exec = R.exec;
3172
- if (typeof exec === 'function') {
3173
- var result = exec.call(R, S);
3174
- if (typeof result !== 'object') {
3175
- throw TypeError('RegExp exec method returned something other than an Object or null');
3176
- }
3177
- return result;
3178
- }
3179
-
3180
- if (classofRaw(R) !== 'RegExp') {
3181
- throw TypeError('RegExp#exec called on incompatible receiver');
3182
- }
3183
-
3184
- return regexpExec.call(R, S);
3185
- };
3186
-
3187
4258
  'use strict';
4259
+ var fixRegExpWellKnownSymbolLogic = fixRegexpWellKnownSymbolLogic;
4260
+ var fails$1 = fails$f;
4261
+ var anObject = anObject$a;
4262
+ var isCallable = isCallable$d;
4263
+ var toIntegerOrInfinity = toIntegerOrInfinity$4;
4264
+ var toLength = toLength$5;
4265
+ var toString = toString$7;
4266
+ var requireObjectCoercible = requireObjectCoercible$8;
4267
+ var advanceStringIndex = advanceStringIndex$3;
4268
+ var getMethod = getMethod$4;
4269
+ var getSubstitution = getSubstitution$1;
4270
+ var regExpExec = regexpExecAbstract;
4271
+ var wellKnownSymbol = wellKnownSymbol$a;
3188
4272
 
3189
-
3190
-
3191
-
3192
-
3193
-
3194
-
3195
-
3196
-
4273
+ var REPLACE = wellKnownSymbol('replace');
3197
4274
  var max = Math.max;
3198
- var min$1 = Math.min;
4275
+ var min = Math.min;
3199
4276
 
3200
4277
  var maybeToString = function (it) {
3201
4278
  return it === undefined ? it : String(it);
3202
4279
  };
3203
4280
 
4281
+ // IE <= 11 replaces $0 with the whole match, as if it was $&
4282
+ // https://stackoverflow.com/questions/6024666/getting-ie-to-replace-a-regex-with-the-literal-string-0
4283
+ var REPLACE_KEEPS_$0 = (function () {
4284
+ // eslint-disable-next-line regexp/prefer-escape-replacement-dollar-char -- required for testing
4285
+ return 'a'.replace(/./, '$0') === '$0';
4286
+ })();
4287
+
4288
+ // Safari <= 13.0.3(?) substitutes nth capture where n>m with an empty string
4289
+ var REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE = (function () {
4290
+ if (/./[REPLACE]) {
4291
+ return /./[REPLACE]('a', '$0') === '';
4292
+ }
4293
+ return false;
4294
+ })();
4295
+
4296
+ var REPLACE_SUPPORTS_NAMED_GROUPS = !fails$1(function () {
4297
+ var re = /./;
4298
+ re.exec = function () {
4299
+ var result = [];
4300
+ result.groups = { a: '7' };
4301
+ return result;
4302
+ };
4303
+ // eslint-disable-next-line regexp/no-useless-dollar-replacements -- false positive
4304
+ return ''.replace(re, '$<a>') !== '7';
4305
+ });
4306
+
3204
4307
  // @@replace logic
3205
- fixRegexpWellKnownSymbolLogic('replace', 2, function (REPLACE, nativeReplace, maybeCallNative, reason) {
3206
- var REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE = reason.REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE;
3207
- var REPLACE_KEEPS_$0 = reason.REPLACE_KEEPS_$0;
4308
+ fixRegExpWellKnownSymbolLogic('replace', function (_, nativeReplace, maybeCallNative) {
3208
4309
  var UNSAFE_SUBSTITUTE = REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE ? '$' : '$0';
3209
4310
 
3210
4311
  return [
@@ -3212,27 +4313,28 @@ fixRegexpWellKnownSymbolLogic('replace', 2, function (REPLACE, nativeReplace, ma
3212
4313
  // https://tc39.es/ecma262/#sec-string.prototype.replace
3213
4314
  function replace(searchValue, replaceValue) {
3214
4315
  var O = requireObjectCoercible(this);
3215
- var replacer = searchValue == undefined ? undefined : searchValue[REPLACE];
3216
- return replacer !== undefined
4316
+ var replacer = searchValue == undefined ? undefined : getMethod(searchValue, REPLACE);
4317
+ return replacer
3217
4318
  ? replacer.call(searchValue, O, replaceValue)
3218
- : nativeReplace.call(String(O), searchValue, replaceValue);
4319
+ : nativeReplace.call(toString(O), searchValue, replaceValue);
3219
4320
  },
3220
4321
  // `RegExp.prototype[@@replace]` method
3221
4322
  // https://tc39.es/ecma262/#sec-regexp.prototype-@@replace
3222
- function (regexp, replaceValue) {
4323
+ function (string, replaceValue) {
4324
+ var rx = anObject(this);
4325
+ var S = toString(string);
4326
+
3223
4327
  if (
3224
- (!REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE && REPLACE_KEEPS_$0) ||
3225
- (typeof replaceValue === 'string' && replaceValue.indexOf(UNSAFE_SUBSTITUTE) === -1)
4328
+ typeof replaceValue === 'string' &&
4329
+ replaceValue.indexOf(UNSAFE_SUBSTITUTE) === -1 &&
4330
+ replaceValue.indexOf('$<') === -1
3226
4331
  ) {
3227
- var res = maybeCallNative(nativeReplace, regexp, this, replaceValue);
4332
+ var res = maybeCallNative(nativeReplace, rx, S, replaceValue);
3228
4333
  if (res.done) return res.value;
3229
4334
  }
3230
4335
 
3231
- var rx = anObject(regexp);
3232
- var S = String(this);
3233
-
3234
- var functionalReplace = typeof replaceValue === 'function';
3235
- if (!functionalReplace) replaceValue = String(replaceValue);
4336
+ var functionalReplace = isCallable(replaceValue);
4337
+ if (!functionalReplace) replaceValue = toString(replaceValue);
3236
4338
 
3237
4339
  var global = rx.global;
3238
4340
  if (global) {
@@ -3241,13 +4343,13 @@ fixRegexpWellKnownSymbolLogic('replace', 2, function (REPLACE, nativeReplace, ma
3241
4343
  }
3242
4344
  var results = [];
3243
4345
  while (true) {
3244
- var result = regexpExecAbstract(rx, S);
4346
+ var result = regExpExec(rx, S);
3245
4347
  if (result === null) break;
3246
4348
 
3247
4349
  results.push(result);
3248
4350
  if (!global) break;
3249
4351
 
3250
- var matchStr = String(result[0]);
4352
+ var matchStr = toString(result[0]);
3251
4353
  if (matchStr === '') rx.lastIndex = advanceStringIndex(S, toLength(rx.lastIndex), fullUnicode);
3252
4354
  }
3253
4355
 
@@ -3256,8 +4358,8 @@ fixRegexpWellKnownSymbolLogic('replace', 2, function (REPLACE, nativeReplace, ma
3256
4358
  for (var i = 0; i < results.length; i++) {
3257
4359
  result = results[i];
3258
4360
 
3259
- var matched = String(result[0]);
3260
- var position = max(min$1(toInteger(result.index), S.length), 0);
4361
+ var matched = toString(result[0]);
4362
+ var position = max(min(toIntegerOrInfinity(result.index), S.length), 0);
3261
4363
  var captures = [];
3262
4364
  // NOTE: This is equivalent to
3263
4365
  // captures = result.slice(1).map(maybeToString)
@@ -3269,7 +4371,7 @@ fixRegexpWellKnownSymbolLogic('replace', 2, function (REPLACE, nativeReplace, ma
3269
4371
  if (functionalReplace) {
3270
4372
  var replacerArgs = [matched].concat(captures, position, S);
3271
4373
  if (namedCaptures !== undefined) replacerArgs.push(namedCaptures);
3272
- var replacement = String(replaceValue.apply(undefined, replacerArgs));
4374
+ var replacement = toString(replaceValue.apply(undefined, replacerArgs));
3273
4375
  } else {
3274
4376
  replacement = getSubstitution(matched, S, position, captures, namedCaptures, replaceValue);
3275
4377
  }
@@ -3281,11 +4383,7 @@ fixRegexpWellKnownSymbolLogic('replace', 2, function (REPLACE, nativeReplace, ma
3281
4383
  return accumulatedResult + S.slice(nextSourcePosition);
3282
4384
  }
3283
4385
  ];
3284
- });
3285
-
3286
- var es_string_replace = {
3287
-
3288
- };
4386
+ }, !REPLACE_SUPPORTS_NAMED_GROUPS || !REPLACE_KEEPS_$0 || REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE);
3289
4387
 
3290
4388
  var getRootNode = function getRootNode(el) {
3291
4389
  if (!el) return null;
@@ -3342,13 +4440,13 @@ var before = function before(_before) {for (var _len = arguments.length, nodes =
3342
4440
  if (nodes.length === 0) return;
3343
4441
 
3344
4442
  if ('before' in _before) {
3345
- after.before.apply(after, nodes);
4443
+ _before.before.apply(_before, nodes);
3346
4444
  } else {
3347
4445
  if (nodes.length === 1) {
3348
4446
  var node = nodes[0];
3349
4447
  var isNode = node instanceof Node;
3350
4448
  node = isNode ? node : document.createTextNode(String(node));
3351
- after.parentNode.insertBefore(node, _before);
4449
+ _before.parentNode.insertBefore(node, _before);
3352
4450
  } else {
3353
4451
  var docFrag = document.createDocumentFragment();var _iterator = _createForOfIteratorHelper(
3354
4452
 
@@ -3376,7 +4474,10 @@ var after = function after(_after) {for (var _len2 = arguments.length, nodes = n
3376
4474
  var node = nodes[0];
3377
4475
  var isNode = node instanceof Node;
3378
4476
  node = isNode ? node : document.createTextNode(String(node));
3379
- _after.parentNode.insertBefore(node, _after.nextSibling);
4477
+
4478
+ if (_after.nextSibling)
4479
+ _after.parentNode.insertBefore(node, _after.nextSibling);else
4480
+ _after.parentNode.appendChild(node);
3380
4481
  } else {
3381
4482
  var docFrag = document.createDocumentFragment();var _iterator2 = _createForOfIteratorHelper(
3382
4483
 
@@ -3393,7 +4494,7 @@ var after = function after(_after) {for (var _len2 = arguments.length, nodes = n
3393
4494
  };
3394
4495
 
3395
4496
  /**
3396
- * @param {ParentNode} parent
4497
+ * @param {ParentNode|Element} parent
3397
4498
  * @param {(Node|string)[]} nodes
3398
4499
  */
3399
4500
  var prepend = function prepend(parent) {for (var _len3 = arguments.length, nodes = new Array(_len3 > 1 ? _len3 - 1 : 0), _key3 = 1; _key3 < _len3; _key3++) {nodes[_key3 - 1] = arguments[_key3];}
@@ -3426,7 +4527,7 @@ var prepend = function prepend(parent) {for (var _len3 = arguments.length, nodes
3426
4527
  };
3427
4528
 
3428
4529
  /**
3429
- * @param {ParentNode} parent
4530
+ * @param {ParentNode|Element} parent
3430
4531
  * @param {(Node|string)[]} nodes
3431
4532
  */
3432
4533
  var append = function append(parent) {for (var _len4 = arguments.length, nodes = new Array(_len4 > 1 ? _len4 - 1 : 0), _key4 = 1; _key4 < _len4; _key4++) {nodes[_key4 - 1] = arguments[_key4];}
@@ -3559,172 +4660,10 @@ var DomCompat = /*#__PURE__*/Object.freeze({
3559
4660
  toggleClass: toggleClass
3560
4661
  });
3561
4662
 
3562
- var MATCH = wellKnownSymbol('match');
3563
-
3564
- // `IsRegExp` abstract operation
3565
- // https://tc39.es/ecma262/#sec-isregexp
3566
- var isRegexp = function (it) {
3567
- var isRegExp;
3568
- return isObject(it) && ((isRegExp = it[MATCH]) !== undefined ? !!isRegExp : classofRaw(it) == 'RegExp');
3569
- };
3570
-
3571
- var aFunction = function (it) {
3572
- if (typeof it != 'function') {
3573
- throw TypeError(String(it) + ' is not a function');
3574
- } return it;
3575
- };
3576
-
3577
- var SPECIES = wellKnownSymbol('species');
3578
-
3579
- // `SpeciesConstructor` abstract operation
3580
- // https://tc39.es/ecma262/#sec-speciesconstructor
3581
- var speciesConstructor = function (O, defaultConstructor) {
3582
- var C = anObject(O).constructor;
3583
- var S;
3584
- return C === undefined || (S = anObject(C)[SPECIES]) == undefined ? defaultConstructor : aFunction(S);
3585
- };
3586
-
3587
- 'use strict';
3588
-
3589
-
3590
-
3591
-
3592
-
3593
-
3594
-
3595
-
3596
-
3597
-
3598
-
3599
- var arrayPush = [].push;
3600
- var min = Math.min;
3601
- var MAX_UINT32 = 0xFFFFFFFF;
3602
-
3603
- // babel-minify transpiles RegExp('x', 'y') -> /x/y and it causes SyntaxError
3604
- var SUPPORTS_Y = !fails(function () { return !RegExp(MAX_UINT32, 'y'); });
3605
-
3606
- // @@split logic
3607
- fixRegexpWellKnownSymbolLogic('split', 2, function (SPLIT, nativeSplit, maybeCallNative) {
3608
- var internalSplit;
3609
- if (
3610
- 'abbc'.split(/(b)*/)[1] == 'c' ||
3611
- // eslint-disable-next-line regexp/no-empty-group -- required for testing
3612
- 'test'.split(/(?:)/, -1).length != 4 ||
3613
- 'ab'.split(/(?:ab)*/).length != 2 ||
3614
- '.'.split(/(.?)(.?)/).length != 4 ||
3615
- // eslint-disable-next-line regexp/no-assertion-capturing-group, regexp/no-empty-group -- required for testing
3616
- '.'.split(/()()/).length > 1 ||
3617
- ''.split(/.?/).length
3618
- ) {
3619
- // based on es5-shim implementation, need to rework it
3620
- internalSplit = function (separator, limit) {
3621
- var string = String(requireObjectCoercible(this));
3622
- var lim = limit === undefined ? MAX_UINT32 : limit >>> 0;
3623
- if (lim === 0) return [];
3624
- if (separator === undefined) return [string];
3625
- // If `separator` is not a regex, use native split
3626
- if (!isRegexp(separator)) {
3627
- return nativeSplit.call(string, separator, lim);
3628
- }
3629
- var output = [];
3630
- var flags = (separator.ignoreCase ? 'i' : '') +
3631
- (separator.multiline ? 'm' : '') +
3632
- (separator.unicode ? 'u' : '') +
3633
- (separator.sticky ? 'y' : '');
3634
- var lastLastIndex = 0;
3635
- // Make `global` and avoid `lastIndex` issues by working with a copy
3636
- var separatorCopy = new RegExp(separator.source, flags + 'g');
3637
- var match, lastIndex, lastLength;
3638
- while (match = regexpExec.call(separatorCopy, string)) {
3639
- lastIndex = separatorCopy.lastIndex;
3640
- if (lastIndex > lastLastIndex) {
3641
- output.push(string.slice(lastLastIndex, match.index));
3642
- if (match.length > 1 && match.index < string.length) arrayPush.apply(output, match.slice(1));
3643
- lastLength = match[0].length;
3644
- lastLastIndex = lastIndex;
3645
- if (output.length >= lim) break;
3646
- }
3647
- if (separatorCopy.lastIndex === match.index) separatorCopy.lastIndex++; // Avoid an infinite loop
3648
- }
3649
- if (lastLastIndex === string.length) {
3650
- if (lastLength || !separatorCopy.test('')) output.push('');
3651
- } else output.push(string.slice(lastLastIndex));
3652
- return output.length > lim ? output.slice(0, lim) : output;
3653
- };
3654
- // Chakra, V8
3655
- } else if ('0'.split(undefined, 0).length) {
3656
- internalSplit = function (separator, limit) {
3657
- return separator === undefined && limit === 0 ? [] : nativeSplit.call(this, separator, limit);
3658
- };
3659
- } else internalSplit = nativeSplit;
3660
-
3661
- return [
3662
- // `String.prototype.split` method
3663
- // https://tc39.es/ecma262/#sec-string.prototype.split
3664
- function split(separator, limit) {
3665
- var O = requireObjectCoercible(this);
3666
- var splitter = separator == undefined ? undefined : separator[SPLIT];
3667
- return splitter !== undefined
3668
- ? splitter.call(separator, O, limit)
3669
- : internalSplit.call(String(O), separator, limit);
3670
- },
3671
- // `RegExp.prototype[@@split]` method
3672
- // https://tc39.es/ecma262/#sec-regexp.prototype-@@split
3673
- //
3674
- // NOTE: This cannot be properly polyfilled in engines that don't support
3675
- // the 'y' flag.
3676
- function (regexp, limit) {
3677
- var res = maybeCallNative(internalSplit, regexp, this, limit, internalSplit !== nativeSplit);
3678
- if (res.done) return res.value;
3679
-
3680
- var rx = anObject(regexp);
3681
- var S = String(this);
3682
- var C = speciesConstructor(rx, RegExp);
3683
-
3684
- var unicodeMatching = rx.unicode;
3685
- var flags = (rx.ignoreCase ? 'i' : '') +
3686
- (rx.multiline ? 'm' : '') +
3687
- (rx.unicode ? 'u' : '') +
3688
- (SUPPORTS_Y ? 'y' : 'g');
3689
-
3690
- // ^(? + rx + ) is needed, in combination with some S slicing, to
3691
- // simulate the 'y' flag.
3692
- var splitter = new C(SUPPORTS_Y ? rx : '^(?:' + rx.source + ')', flags);
3693
- var lim = limit === undefined ? MAX_UINT32 : limit >>> 0;
3694
- if (lim === 0) return [];
3695
- if (S.length === 0) return regexpExecAbstract(splitter, S) === null ? [S] : [];
3696
- var p = 0;
3697
- var q = 0;
3698
- var A = [];
3699
- while (q < S.length) {
3700
- splitter.lastIndex = SUPPORTS_Y ? q : 0;
3701
- var z = regexpExecAbstract(splitter, SUPPORTS_Y ? S : S.slice(q));
3702
- var e;
3703
- if (
3704
- z === null ||
3705
- (e = min(toLength(splitter.lastIndex + (SUPPORTS_Y ? 0 : q)), S.length)) === p
3706
- ) {
3707
- q = advanceStringIndex(S, q, unicodeMatching);
3708
- } else {
3709
- A.push(S.slice(p, q));
3710
- if (A.length === lim) return A;
3711
- for (var i = 1; i <= z.length - 1; i++) {
3712
- A.push(z[i]);
3713
- if (A.length === lim) return A;
3714
- }
3715
- q = p = e;
3716
- }
3717
- }
3718
- A.push(S.slice(p));
3719
- return A;
3720
- }
3721
- ];
3722
- }, !SUPPORTS_Y);
3723
-
3724
- var es_string_split = {
3725
-
3726
- };
4663
+ var es_function_name = {};
3727
4664
 
4665
+ var DESCRIPTORS$1 = descriptors;
4666
+ var FUNCTION_NAME_EXISTS = functionName.EXISTS;
3728
4667
  var defineProperty$1 = objectDefineProperty.f;
3729
4668
 
3730
4669
  var FunctionPrototype = Function.prototype;
@@ -3734,7 +4673,7 @@ var NAME = 'name';
3734
4673
 
3735
4674
  // Function instances `.name` property
3736
4675
  // https://tc39.es/ecma262/#sec-function-instances-name
3737
- if (descriptors && !(NAME in FunctionPrototype)) {
4676
+ if (DESCRIPTORS$1 && !FUNCTION_NAME_EXISTS) {
3738
4677
  defineProperty$1(FunctionPrototype, NAME, {
3739
4678
  configurable: true,
3740
4679
  get: function () {
@@ -3747,10 +4686,6 @@ if (descriptors && !(NAME in FunctionPrototype)) {
3747
4686
  });
3748
4687
  }
3749
4688
 
3750
- var es_function_name = {
3751
-
3752
- };
3753
-
3754
4689
  var DomEventsSink = /*#__PURE__*/function () {
3755
4690
  function DomEventsSink() {_classCallCheck(this, DomEventsSink);
3756
4691
  /**
@@ -3824,6 +4759,11 @@ var DomEventsSink$1 = /*#__PURE__*/Object.freeze({
3824
4759
  'default': DomEventsSink
3825
4760
  });
3826
4761
 
4762
+ var es_math_hypot = {};
4763
+
4764
+ var $$1 = _export;
4765
+
4766
+ // eslint-disable-next-line es/no-math-hypot -- required for testing
3827
4767
  var $hypot = Math.hypot;
3828
4768
  var abs = Math.abs;
3829
4769
  var sqrt = Math.sqrt;
@@ -3834,7 +4774,7 @@ var BUGGY = !!$hypot && $hypot(Infinity, NaN) !== Infinity;
3834
4774
 
3835
4775
  // `Math.hypot` method
3836
4776
  // https://tc39.es/ecma262/#sec-math.hypot
3837
- _export({ target: 'Math', stat: true, forced: BUGGY }, {
4777
+ $$1({ target: 'Math', stat: true, forced: BUGGY }, {
3838
4778
  // eslint-disable-next-line no-unused-vars -- required for `.length`
3839
4779
  hypot: function hypot(value1, value2) {
3840
4780
  var sum = 0;
@@ -3857,10 +4797,6 @@ _export({ target: 'Math', stat: true, forced: BUGGY }, {
3857
4797
  }
3858
4798
  });
3859
4799
 
3860
- var es_math_hypot = {
3861
-
3862
- };
3863
-
3864
4800
  var bindTouchTap = function bindTouchTap(el, options) {
3865
4801
  var currentTouchId = null;
3866
4802
  var downPos = null;
@@ -3940,23 +4876,27 @@ var Touches = /*#__PURE__*/Object.freeze({
3940
4876
  bindTouchTap: bindTouchTap
3941
4877
  });
3942
4878
 
3943
- 'use strict';
3944
-
3945
-
3946
-
3947
-
4879
+ var es_object_assign = {};
3948
4880
 
3949
-
3950
-
3951
-
3952
- var nativeAssign = Object.assign;
4881
+ 'use strict';
4882
+ var DESCRIPTORS = descriptors;
4883
+ var fails = fails$f;
4884
+ var objectKeys = objectKeys$3;
4885
+ var getOwnPropertySymbolsModule = objectGetOwnPropertySymbols;
4886
+ var propertyIsEnumerableModule = objectPropertyIsEnumerable;
4887
+ var toObject = toObject$4;
4888
+ var IndexedObject = indexedObject;
4889
+
4890
+ // eslint-disable-next-line es/no-object-assign -- safe
4891
+ var $assign = Object.assign;
4892
+ // eslint-disable-next-line es/no-object-defineproperty -- required for testing
3953
4893
  var defineProperty = Object.defineProperty;
3954
4894
 
3955
4895
  // `Object.assign` method
3956
4896
  // https://tc39.es/ecma262/#sec-object.assign
3957
- var objectAssign = !nativeAssign || fails(function () {
4897
+ var objectAssign = !$assign || fails(function () {
3958
4898
  // should have correct order of operations (Edge bug)
3959
- if (descriptors && nativeAssign({ b: 1 }, nativeAssign(defineProperty({}, 'a', {
4899
+ if (DESCRIPTORS && $assign({ b: 1 }, $assign(defineProperty({}, 'a', {
3960
4900
  enumerable: true,
3961
4901
  get: function () {
3962
4902
  defineProperty(this, 'b', {
@@ -3968,41 +4908,41 @@ var objectAssign = !nativeAssign || fails(function () {
3968
4908
  // should work with symbols and should have deterministic property order (V8 bug)
3969
4909
  var A = {};
3970
4910
  var B = {};
3971
- /* global Symbol -- required for testing */
4911
+ // eslint-disable-next-line es/no-symbol -- safe
3972
4912
  var symbol = Symbol();
3973
4913
  var alphabet = 'abcdefghijklmnopqrst';
3974
4914
  A[symbol] = 7;
3975
4915
  alphabet.split('').forEach(function (chr) { B[chr] = chr; });
3976
- return nativeAssign({}, A)[symbol] != 7 || objectKeys(nativeAssign({}, B)).join('') != alphabet;
4916
+ return $assign({}, A)[symbol] != 7 || objectKeys($assign({}, B)).join('') != alphabet;
3977
4917
  }) ? function assign(target, source) { // eslint-disable-line no-unused-vars -- required for `.length`
3978
4918
  var T = toObject(target);
3979
4919
  var argumentsLength = arguments.length;
3980
4920
  var index = 1;
3981
- var getOwnPropertySymbols = objectGetOwnPropertySymbols.f;
3982
- var propertyIsEnumerable = objectPropertyIsEnumerable.f;
4921
+ var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;
4922
+ var propertyIsEnumerable = propertyIsEnumerableModule.f;
3983
4923
  while (argumentsLength > index) {
3984
- var S = indexedObject(arguments[index++]);
4924
+ var S = IndexedObject(arguments[index++]);
3985
4925
  var keys = getOwnPropertySymbols ? objectKeys(S).concat(getOwnPropertySymbols(S)) : objectKeys(S);
3986
4926
  var length = keys.length;
3987
4927
  var j = 0;
3988
4928
  var key;
3989
4929
  while (length > j) {
3990
4930
  key = keys[j++];
3991
- if (!descriptors || propertyIsEnumerable.call(S, key)) T[key] = S[key];
4931
+ if (!DESCRIPTORS || propertyIsEnumerable.call(S, key)) T[key] = S[key];
3992
4932
  }
3993
4933
  } return T;
3994
- } : nativeAssign;
4934
+ } : $assign;
4935
+
4936
+ var $ = _export;
4937
+ var assign = objectAssign;
3995
4938
 
3996
4939
  // `Object.assign` method
3997
4940
  // https://tc39.es/ecma262/#sec-object.assign
3998
- _export({ target: 'Object', stat: true, forced: Object.assign !== objectAssign }, {
3999
- assign: objectAssign
4941
+ // eslint-disable-next-line es/no-object-assign -- required for testing
4942
+ $({ target: 'Object', stat: true, forced: Object.assign !== assign }, {
4943
+ assign: assign
4000
4944
  });
4001
4945
 
4002
- var es_object_assign = {
4003
-
4004
- };
4005
-
4006
4946
  var rtlScrollType;
4007
4947
 
4008
4948
  var detectRtlScrollType = function detectRtlScrollType() {