@janiscommerce/ui-web 0.38.0 → 0.39.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.umd.js CHANGED
@@ -515,7 +515,7 @@
515
515
 
516
516
  var isCallable$j = isCallable$k;
517
517
 
518
- var isObject$c = function (it) {
518
+ var isObject$d = function (it) {
519
519
  return typeof it == 'object' ? it !== null : isCallable$j(it);
520
520
  };
521
521
 
@@ -640,7 +640,7 @@
640
640
  var global$L = global$T;
641
641
  var call$f = functionCall;
642
642
  var isCallable$f = isCallable$k;
643
- var isObject$b = isObject$c;
643
+ var isObject$c = isObject$d;
644
644
 
645
645
  var TypeError$k = global$L.TypeError;
646
646
 
@@ -648,9 +648,9 @@
648
648
  // https://tc39.es/ecma262/#sec-ordinarytoprimitive
649
649
  var ordinaryToPrimitive$1 = function (input, pref) {
650
650
  var fn, val;
651
- if (pref === 'string' && isCallable$f(fn = input.toString) && !isObject$b(val = call$f(fn, input))) return val;
652
- if (isCallable$f(fn = input.valueOf) && !isObject$b(val = call$f(fn, input))) return val;
653
- if (pref !== 'string' && isCallable$f(fn = input.toString) && !isObject$b(val = call$f(fn, input))) return val;
651
+ if (pref === 'string' && isCallable$f(fn = input.toString) && !isObject$c(val = call$f(fn, input))) return val;
652
+ if (isCallable$f(fn = input.valueOf) && !isObject$c(val = call$f(fn, input))) return val;
653
+ if (pref !== 'string' && isCallable$f(fn = input.toString) && !isObject$c(val = call$f(fn, input))) return val;
654
654
  throw TypeError$k("Can't convert object to primitive value");
655
655
  };
656
656
 
@@ -750,7 +750,7 @@
750
750
 
751
751
  var global$G = global$T;
752
752
  var call$e = functionCall;
753
- var isObject$a = isObject$c;
753
+ var isObject$b = isObject$d;
754
754
  var isSymbol$2 = isSymbol$3;
755
755
  var getMethod$4 = getMethod$5;
756
756
  var ordinaryToPrimitive = ordinaryToPrimitive$1;
@@ -762,13 +762,13 @@
762
762
  // `ToPrimitive` abstract operation
763
763
  // https://tc39.es/ecma262/#sec-toprimitive
764
764
  var toPrimitive$2 = function (input, pref) {
765
- if (!isObject$a(input) || isSymbol$2(input)) return input;
765
+ if (!isObject$b(input) || isSymbol$2(input)) return input;
766
766
  var exoticToPrim = getMethod$4(input, TO_PRIMITIVE);
767
767
  var result;
768
768
  if (exoticToPrim) {
769
769
  if (pref === undefined) pref = 'default';
770
770
  result = call$e(exoticToPrim, input, pref);
771
- if (!isObject$a(result) || isSymbol$2(result)) return result;
771
+ if (!isObject$b(result) || isSymbol$2(result)) return result;
772
772
  throw TypeError$j("Can't convert object to primitive value");
773
773
  }
774
774
  if (pref === undefined) pref = 'number';
@@ -786,11 +786,11 @@
786
786
  };
787
787
 
788
788
  var global$F = global$T;
789
- var isObject$9 = isObject$c;
789
+ var isObject$a = isObject$d;
790
790
 
791
791
  var document$3 = global$F.document;
792
792
  // typeof document.createElement is 'object' in old IE
793
- var EXISTS$1 = isObject$9(document$3) && isObject$9(document$3.createElement);
793
+ var EXISTS$1 = isObject$a(document$3) && isObject$a(document$3.createElement);
794
794
 
795
795
  var documentCreateElement$2 = function (it) {
796
796
  return EXISTS$1 ? document$3.createElement(it) : {};
@@ -847,14 +847,14 @@
847
847
  });
848
848
 
849
849
  var global$E = global$T;
850
- var isObject$8 = isObject$c;
850
+ var isObject$9 = isObject$d;
851
851
 
852
852
  var String$4 = global$E.String;
853
853
  var TypeError$i = global$E.TypeError;
854
854
 
855
855
  // `Assert: Type(argument) is Object`
856
856
  var anObject$h = function (argument) {
857
- if (isObject$8(argument)) return argument;
857
+ if (isObject$9(argument)) return argument;
858
858
  throw TypeError$i(String$4(argument) + ' is not an object');
859
859
  };
860
860
 
@@ -953,7 +953,7 @@
953
953
  var NATIVE_WEAK_MAP = nativeWeakMap;
954
954
  var global$B = global$T;
955
955
  var uncurryThis$o = functionUncurryThis;
956
- var isObject$7 = isObject$c;
956
+ var isObject$8 = isObject$d;
957
957
  var createNonEnumerableProperty$6 = createNonEnumerableProperty$7;
958
958
  var hasOwn$a = hasOwnProperty_1;
959
959
  var shared$1 = sharedStore;
@@ -972,7 +972,7 @@
972
972
  var getterFor = function (TYPE) {
973
973
  return function (it) {
974
974
  var state;
975
- if (!isObject$7(it) || (state = get(it)).type !== TYPE) {
975
+ if (!isObject$8(it) || (state = get(it)).type !== TYPE) {
976
976
  throw TypeError$g('Incompatible receiver, ' + TYPE + ' required');
977
977
  } return state;
978
978
  };
@@ -1437,7 +1437,7 @@
1437
1437
  var global$x = global$T;
1438
1438
  var isArray$2 = isArray$3;
1439
1439
  var isConstructor$2 = isConstructor$3;
1440
- var isObject$6 = isObject$c;
1440
+ var isObject$7 = isObject$d;
1441
1441
  var wellKnownSymbol$i = wellKnownSymbol$m;
1442
1442
 
1443
1443
  var SPECIES$5 = wellKnownSymbol$i('species');
@@ -1451,7 +1451,7 @@
1451
1451
  C = originalArray.constructor;
1452
1452
  // cross-realm fallback
1453
1453
  if (isConstructor$2(C) && (C === Array$3 || isArray$2(C.prototype))) C = undefined;
1454
- else if (isObject$6(C)) {
1454
+ else if (isObject$7(C)) {
1455
1455
  C = C[SPECIES$5];
1456
1456
  if (C === null) C = undefined;
1457
1457
  }
@@ -1490,7 +1490,7 @@
1490
1490
  var global$w = global$T;
1491
1491
  var fails$g = fails$q;
1492
1492
  var isArray$1 = isArray$3;
1493
- var isObject$5 = isObject$c;
1493
+ var isObject$6 = isObject$d;
1494
1494
  var toObject$7 = toObject$9;
1495
1495
  var lengthOfArrayLike$7 = lengthOfArrayLike$9;
1496
1496
  var createProperty$2 = createProperty$3;
@@ -1516,7 +1516,7 @@
1516
1516
  var SPECIES_SUPPORT = arrayMethodHasSpeciesSupport$1('concat');
1517
1517
 
1518
1518
  var isConcatSpreadable = function (O) {
1519
- if (!isObject$5(O)) return false;
1519
+ if (!isObject$6(O)) return false;
1520
1520
  var spreadable = O[IS_CONCAT_SPREADABLE];
1521
1521
  return spreadable !== undefined ? !!spreadable : isArray$1(O);
1522
1522
  };
@@ -3129,7 +3129,7 @@
3129
3129
  var bind$7 = functionBindContext;
3130
3130
  var classof$2 = classof$8;
3131
3131
  var anObject$5 = anObject$h;
3132
- var isObject$4 = isObject$c;
3132
+ var isObject$5 = isObject$d;
3133
3133
  var $toString$2 = toString$9;
3134
3134
  var create = objectCreate;
3135
3135
  var createPropertyDescriptor = createPropertyDescriptor$5;
@@ -3232,7 +3232,7 @@
3232
3232
  this.url = null;
3233
3233
 
3234
3234
  if (init !== undefined) {
3235
- if (isObject$4(init)) this.parseObject(init);
3235
+ if (isObject$5(init)) this.parseObject(init);
3236
3236
  else this.parseQuery(typeof init == 'string' ? charAt$1(init, 0) === '?' ? stringSlice$2(init, 1) : init : $toString$2(init));
3237
3237
  }
3238
3238
  };
@@ -3449,7 +3449,7 @@
3449
3449
  var headersSet = uncurryThis$d(HeadersPrototype.set);
3450
3450
 
3451
3451
  var wrapRequestOptions = function (init) {
3452
- if (isObject$4(init)) {
3452
+ if (isObject$5(init)) {
3453
3453
  var body = init.body;
3454
3454
  var headers;
3455
3455
  if (classof$2(body) === URL_SEARCH_PARAMS) {
@@ -4548,7 +4548,7 @@
4548
4548
  return call$3.apply(apply$2, arguments);
4549
4549
  });
4550
4550
 
4551
- var isObject$3 = isObject$c;
4551
+ var isObject$4 = isObject$d;
4552
4552
  var classof$1 = classofRaw$1;
4553
4553
  var wellKnownSymbol$5 = wellKnownSymbol$m;
4554
4554
 
@@ -4558,7 +4558,7 @@
4558
4558
  // https://tc39.es/ecma262/#sec-isregexp
4559
4559
  var isRegexp = function (it) {
4560
4560
  var isRegExp;
4561
- return isObject$3(it) && ((isRegExp = it[MATCH$1]) !== undefined ? !!isRegExp : classof$1(it) == 'RegExp');
4561
+ return isObject$4(it) && ((isRegExp = it[MATCH$1]) !== undefined ? !!isRegExp : classof$1(it) == 'RegExp');
4562
4562
  };
4563
4563
 
4564
4564
  var global$f = global$T;
@@ -4743,6 +4743,166 @@
4743
4743
  ];
4744
4744
  }, !SPLIT_WORKS_WITH_OVERWRITTEN_EXEC, UNSUPPORTED_Y);
4745
4745
 
4746
+ var $$d = _export;
4747
+
4748
+ // `Number.isNaN` method
4749
+ // https://tc39.es/ecma262/#sec-number.isnan
4750
+ $$d({ target: 'Number', stat: true }, {
4751
+ isNaN: function isNaN(number) {
4752
+ // eslint-disable-next-line no-self-compare -- NaN check
4753
+ return number != number;
4754
+ }
4755
+ });
4756
+
4757
+ var isCallable$2 = isCallable$k;
4758
+ var isObject$3 = isObject$d;
4759
+ var setPrototypeOf$1 = objectSetPrototypeOf;
4760
+
4761
+ // makes subclassing work correct for wrapped built-ins
4762
+ var inheritIfRequired$1 = function ($this, dummy, Wrapper) {
4763
+ var NewTarget, NewTargetPrototype;
4764
+ if (
4765
+ // it can work only with native `setPrototypeOf`
4766
+ setPrototypeOf$1 &&
4767
+ // we haven't completely correct pre-ES6 way for getting `new.target`, so use this
4768
+ isCallable$2(NewTarget = dummy.constructor) &&
4769
+ NewTarget !== Wrapper &&
4770
+ isObject$3(NewTargetPrototype = NewTarget.prototype) &&
4771
+ NewTargetPrototype !== Wrapper.prototype
4772
+ ) setPrototypeOf$1($this, NewTargetPrototype);
4773
+ return $this;
4774
+ };
4775
+
4776
+ var uncurryThis$a = functionUncurryThis;
4777
+
4778
+ // `thisNumberValue` abstract operation
4779
+ // https://tc39.es/ecma262/#sec-thisnumbervalue
4780
+ var thisNumberValue$1 = uncurryThis$a(1.0.valueOf);
4781
+
4782
+ // a string of all valid unicode whitespaces
4783
+ var whitespaces$2 = '\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u2000\u2001\u2002' +
4784
+ '\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF';
4785
+
4786
+ var uncurryThis$9 = functionUncurryThis;
4787
+ var requireObjectCoercible$2 = requireObjectCoercible$8;
4788
+ var toString$3 = toString$9;
4789
+ var whitespaces$1 = whitespaces$2;
4790
+
4791
+ var replace$1 = uncurryThis$9(''.replace);
4792
+ var whitespace = '[' + whitespaces$1 + ']';
4793
+ var ltrim = RegExp('^' + whitespace + whitespace + '*');
4794
+ var rtrim = RegExp(whitespace + whitespace + '*$');
4795
+
4796
+ // `String.prototype.{ trim, trimStart, trimEnd, trimLeft, trimRight }` methods implementation
4797
+ var createMethod$2 = function (TYPE) {
4798
+ return function ($this) {
4799
+ var string = toString$3(requireObjectCoercible$2($this));
4800
+ if (TYPE & 1) string = replace$1(string, ltrim, '');
4801
+ if (TYPE & 2) string = replace$1(string, rtrim, '');
4802
+ return string;
4803
+ };
4804
+ };
4805
+
4806
+ var stringTrim = {
4807
+ // `String.prototype.{ trimLeft, trimStart }` methods
4808
+ // https://tc39.es/ecma262/#sec-string.prototype.trimstart
4809
+ start: createMethod$2(1),
4810
+ // `String.prototype.{ trimRight, trimEnd }` methods
4811
+ // https://tc39.es/ecma262/#sec-string.prototype.trimend
4812
+ end: createMethod$2(2),
4813
+ // `String.prototype.trim` method
4814
+ // https://tc39.es/ecma262/#sec-string.prototype.trim
4815
+ trim: createMethod$2(3)
4816
+ };
4817
+
4818
+ var DESCRIPTORS$2 = descriptors;
4819
+ var global$e = global$T;
4820
+ var uncurryThis$8 = functionUncurryThis;
4821
+ var isForced$1 = isForced_1;
4822
+ var redefine$2 = redefine$b.exports;
4823
+ var hasOwn$1 = hasOwnProperty_1;
4824
+ var inheritIfRequired = inheritIfRequired$1;
4825
+ var isPrototypeOf$2 = objectIsPrototypeOf;
4826
+ var isSymbol = isSymbol$3;
4827
+ var toPrimitive = toPrimitive$2;
4828
+ var fails$6 = fails$q;
4829
+ var getOwnPropertyNames = objectGetOwnPropertyNames.f;
4830
+ var getOwnPropertyDescriptor$1 = objectGetOwnPropertyDescriptor.f;
4831
+ var defineProperty$1 = objectDefineProperty.f;
4832
+ var thisNumberValue = thisNumberValue$1;
4833
+ var trim$1 = stringTrim.trim;
4834
+
4835
+ var NUMBER = 'Number';
4836
+ var NativeNumber = global$e[NUMBER];
4837
+ var NumberPrototype = NativeNumber.prototype;
4838
+ var TypeError$6 = global$e.TypeError;
4839
+ var arraySlice$2 = uncurryThis$8(''.slice);
4840
+ var charCodeAt = uncurryThis$8(''.charCodeAt);
4841
+
4842
+ // `ToNumeric` abstract operation
4843
+ // https://tc39.es/ecma262/#sec-tonumeric
4844
+ var toNumeric = function (value) {
4845
+ var primValue = toPrimitive(value, 'number');
4846
+ return typeof primValue == 'bigint' ? primValue : toNumber(primValue);
4847
+ };
4848
+
4849
+ // `ToNumber` abstract operation
4850
+ // https://tc39.es/ecma262/#sec-tonumber
4851
+ var toNumber = function (argument) {
4852
+ var it = toPrimitive(argument, 'number');
4853
+ var first, third, radix, maxCode, digits, length, index, code;
4854
+ if (isSymbol(it)) throw TypeError$6('Cannot convert a Symbol value to a number');
4855
+ if (typeof it == 'string' && it.length > 2) {
4856
+ it = trim$1(it);
4857
+ first = charCodeAt(it, 0);
4858
+ if (first === 43 || first === 45) {
4859
+ third = charCodeAt(it, 2);
4860
+ if (third === 88 || third === 120) return NaN; // Number('+0x1') should be NaN, old V8 fix
4861
+ } else if (first === 48) {
4862
+ switch (charCodeAt(it, 1)) {
4863
+ case 66: case 98: radix = 2; maxCode = 49; break; // fast equal of /^0b[01]+$/i
4864
+ case 79: case 111: radix = 8; maxCode = 55; break; // fast equal of /^0o[0-7]+$/i
4865
+ default: return +it;
4866
+ }
4867
+ digits = arraySlice$2(it, 2);
4868
+ length = digits.length;
4869
+ for (index = 0; index < length; index++) {
4870
+ code = charCodeAt(digits, index);
4871
+ // parseInt parses a string to a first unavailable symbol
4872
+ // but ToNumber should return NaN if a string contains unavailable symbols
4873
+ if (code < 48 || code > maxCode) return NaN;
4874
+ } return parseInt(digits, radix);
4875
+ }
4876
+ } return +it;
4877
+ };
4878
+
4879
+ // `Number` constructor
4880
+ // https://tc39.es/ecma262/#sec-number-constructor
4881
+ if (isForced$1(NUMBER, !NativeNumber(' 0o1') || !NativeNumber('0b1') || NativeNumber('+0x1'))) {
4882
+ var NumberWrapper = function Number(value) {
4883
+ var n = arguments.length < 1 ? 0 : NativeNumber(toNumeric(value));
4884
+ var dummy = this;
4885
+ // check on 1..constructor(foo) case
4886
+ return isPrototypeOf$2(NumberPrototype, dummy) && fails$6(function () { thisNumberValue(dummy); })
4887
+ ? inheritIfRequired(Object(n), dummy, NumberWrapper) : n;
4888
+ };
4889
+ for (var keys = DESCRIPTORS$2 ? getOwnPropertyNames(NativeNumber) : (
4890
+ // ES3:
4891
+ 'MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,' +
4892
+ // ES2015 (in case, if modules with ES2015 Number statics required before):
4893
+ 'EPSILON,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,isFinite,isInteger,isNaN,isSafeInteger,parseFloat,parseInt,' +
4894
+ // ESNext
4895
+ 'fromString,range'
4896
+ ).split(','), j = 0, key$1; keys.length > j; j++) {
4897
+ if (hasOwn$1(NativeNumber, key$1 = keys[j]) && !hasOwn$1(NumberWrapper, key$1)) {
4898
+ defineProperty$1(NumberWrapper, key$1, getOwnPropertyDescriptor$1(NativeNumber, key$1));
4899
+ }
4900
+ }
4901
+ NumberWrapper.prototype = NumberPrototype;
4902
+ NumberPrototype.constructor = NumberWrapper;
4903
+ redefine$2(global$e, NUMBER, NumberWrapper);
4904
+ }
4905
+
4746
4906
  /**
4747
4907
  * Creates a debounced function that delays invoking func until after wait milliseconds have
4748
4908
  * elapsed since the last time the debounced function was invoked.
@@ -4771,6 +4931,12 @@
4771
4931
 
4772
4932
  return debounced;
4773
4933
  }
4934
+ var isObject$2 = function isObject(value) {
4935
+ return _typeof(value) === 'object' && !Array.isArray(value) && value instanceof Object;
4936
+ };
4937
+ var isNumber = function isNumber(num) {
4938
+ return typeof num === 'number' && !Number.isNaN(Number(num));
4939
+ };
4774
4940
 
4775
4941
  var breakpoints = {
4776
4942
  values: {
@@ -4971,166 +5137,6 @@
4971
5137
  yellowPressed: '#FFBA0C'
4972
5138
  };
4973
5139
 
4974
- var $$d = _export;
4975
-
4976
- // `Number.isNaN` method
4977
- // https://tc39.es/ecma262/#sec-number.isnan
4978
- $$d({ target: 'Number', stat: true }, {
4979
- isNaN: function isNaN(number) {
4980
- // eslint-disable-next-line no-self-compare -- NaN check
4981
- return number != number;
4982
- }
4983
- });
4984
-
4985
- var isCallable$2 = isCallable$k;
4986
- var isObject$2 = isObject$c;
4987
- var setPrototypeOf$1 = objectSetPrototypeOf;
4988
-
4989
- // makes subclassing work correct for wrapped built-ins
4990
- var inheritIfRequired$1 = function ($this, dummy, Wrapper) {
4991
- var NewTarget, NewTargetPrototype;
4992
- if (
4993
- // it can work only with native `setPrototypeOf`
4994
- setPrototypeOf$1 &&
4995
- // we haven't completely correct pre-ES6 way for getting `new.target`, so use this
4996
- isCallable$2(NewTarget = dummy.constructor) &&
4997
- NewTarget !== Wrapper &&
4998
- isObject$2(NewTargetPrototype = NewTarget.prototype) &&
4999
- NewTargetPrototype !== Wrapper.prototype
5000
- ) setPrototypeOf$1($this, NewTargetPrototype);
5001
- return $this;
5002
- };
5003
-
5004
- var uncurryThis$a = functionUncurryThis;
5005
-
5006
- // `thisNumberValue` abstract operation
5007
- // https://tc39.es/ecma262/#sec-thisnumbervalue
5008
- var thisNumberValue$1 = uncurryThis$a(1.0.valueOf);
5009
-
5010
- // a string of all valid unicode whitespaces
5011
- var whitespaces$2 = '\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u2000\u2001\u2002' +
5012
- '\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF';
5013
-
5014
- var uncurryThis$9 = functionUncurryThis;
5015
- var requireObjectCoercible$2 = requireObjectCoercible$8;
5016
- var toString$3 = toString$9;
5017
- var whitespaces$1 = whitespaces$2;
5018
-
5019
- var replace$1 = uncurryThis$9(''.replace);
5020
- var whitespace = '[' + whitespaces$1 + ']';
5021
- var ltrim = RegExp('^' + whitespace + whitespace + '*');
5022
- var rtrim = RegExp(whitespace + whitespace + '*$');
5023
-
5024
- // `String.prototype.{ trim, trimStart, trimEnd, trimLeft, trimRight }` methods implementation
5025
- var createMethod$2 = function (TYPE) {
5026
- return function ($this) {
5027
- var string = toString$3(requireObjectCoercible$2($this));
5028
- if (TYPE & 1) string = replace$1(string, ltrim, '');
5029
- if (TYPE & 2) string = replace$1(string, rtrim, '');
5030
- return string;
5031
- };
5032
- };
5033
-
5034
- var stringTrim = {
5035
- // `String.prototype.{ trimLeft, trimStart }` methods
5036
- // https://tc39.es/ecma262/#sec-string.prototype.trimstart
5037
- start: createMethod$2(1),
5038
- // `String.prototype.{ trimRight, trimEnd }` methods
5039
- // https://tc39.es/ecma262/#sec-string.prototype.trimend
5040
- end: createMethod$2(2),
5041
- // `String.prototype.trim` method
5042
- // https://tc39.es/ecma262/#sec-string.prototype.trim
5043
- trim: createMethod$2(3)
5044
- };
5045
-
5046
- var DESCRIPTORS$2 = descriptors;
5047
- var global$e = global$T;
5048
- var uncurryThis$8 = functionUncurryThis;
5049
- var isForced$1 = isForced_1;
5050
- var redefine$2 = redefine$b.exports;
5051
- var hasOwn$1 = hasOwnProperty_1;
5052
- var inheritIfRequired = inheritIfRequired$1;
5053
- var isPrototypeOf$2 = objectIsPrototypeOf;
5054
- var isSymbol = isSymbol$3;
5055
- var toPrimitive = toPrimitive$2;
5056
- var fails$6 = fails$q;
5057
- var getOwnPropertyNames = objectGetOwnPropertyNames.f;
5058
- var getOwnPropertyDescriptor$1 = objectGetOwnPropertyDescriptor.f;
5059
- var defineProperty$1 = objectDefineProperty.f;
5060
- var thisNumberValue = thisNumberValue$1;
5061
- var trim$1 = stringTrim.trim;
5062
-
5063
- var NUMBER = 'Number';
5064
- var NativeNumber = global$e[NUMBER];
5065
- var NumberPrototype = NativeNumber.prototype;
5066
- var TypeError$6 = global$e.TypeError;
5067
- var arraySlice$2 = uncurryThis$8(''.slice);
5068
- var charCodeAt = uncurryThis$8(''.charCodeAt);
5069
-
5070
- // `ToNumeric` abstract operation
5071
- // https://tc39.es/ecma262/#sec-tonumeric
5072
- var toNumeric = function (value) {
5073
- var primValue = toPrimitive(value, 'number');
5074
- return typeof primValue == 'bigint' ? primValue : toNumber(primValue);
5075
- };
5076
-
5077
- // `ToNumber` abstract operation
5078
- // https://tc39.es/ecma262/#sec-tonumber
5079
- var toNumber = function (argument) {
5080
- var it = toPrimitive(argument, 'number');
5081
- var first, third, radix, maxCode, digits, length, index, code;
5082
- if (isSymbol(it)) throw TypeError$6('Cannot convert a Symbol value to a number');
5083
- if (typeof it == 'string' && it.length > 2) {
5084
- it = trim$1(it);
5085
- first = charCodeAt(it, 0);
5086
- if (first === 43 || first === 45) {
5087
- third = charCodeAt(it, 2);
5088
- if (third === 88 || third === 120) return NaN; // Number('+0x1') should be NaN, old V8 fix
5089
- } else if (first === 48) {
5090
- switch (charCodeAt(it, 1)) {
5091
- case 66: case 98: radix = 2; maxCode = 49; break; // fast equal of /^0b[01]+$/i
5092
- case 79: case 111: radix = 8; maxCode = 55; break; // fast equal of /^0o[0-7]+$/i
5093
- default: return +it;
5094
- }
5095
- digits = arraySlice$2(it, 2);
5096
- length = digits.length;
5097
- for (index = 0; index < length; index++) {
5098
- code = charCodeAt(digits, index);
5099
- // parseInt parses a string to a first unavailable symbol
5100
- // but ToNumber should return NaN if a string contains unavailable symbols
5101
- if (code < 48 || code > maxCode) return NaN;
5102
- } return parseInt(digits, radix);
5103
- }
5104
- } return +it;
5105
- };
5106
-
5107
- // `Number` constructor
5108
- // https://tc39.es/ecma262/#sec-number-constructor
5109
- if (isForced$1(NUMBER, !NativeNumber(' 0o1') || !NativeNumber('0b1') || NativeNumber('+0x1'))) {
5110
- var NumberWrapper = function Number(value) {
5111
- var n = arguments.length < 1 ? 0 : NativeNumber(toNumeric(value));
5112
- var dummy = this;
5113
- // check on 1..constructor(foo) case
5114
- return isPrototypeOf$2(NumberPrototype, dummy) && fails$6(function () { thisNumberValue(dummy); })
5115
- ? inheritIfRequired(Object(n), dummy, NumberWrapper) : n;
5116
- };
5117
- for (var keys = DESCRIPTORS$2 ? getOwnPropertyNames(NativeNumber) : (
5118
- // ES3:
5119
- 'MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,' +
5120
- // ES2015 (in case, if modules with ES2015 Number statics required before):
5121
- 'EPSILON,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,isFinite,isInteger,isNaN,isSafeInteger,parseFloat,parseInt,' +
5122
- // ESNext
5123
- 'fromString,range'
5124
- ).split(','), j = 0, key$1; keys.length > j; j++) {
5125
- if (hasOwn$1(NativeNumber, key$1 = keys[j]) && !hasOwn$1(NumberWrapper, key$1)) {
5126
- defineProperty$1(NumberWrapper, key$1, getOwnPropertyDescriptor$1(NativeNumber, key$1));
5127
- }
5128
- }
5129
- NumberWrapper.prototype = NumberPrototype;
5130
- NumberPrototype.constructor = NumberWrapper;
5131
- redefine$2(global$e, NUMBER, NumberWrapper);
5132
- }
5133
-
5134
5140
  var uncurryThis$7 = functionUncurryThis;
5135
5141
  var requireObjectCoercible$1 = requireObjectCoercible$8;
5136
5142
  var toString$2 = toString$9;
@@ -15981,6 +15987,13 @@
15981
15987
  var hasEqualLng = (prevPosition === null || prevPosition === void 0 ? void 0 : prevPosition.lng) === (newPosition === null || newPosition === void 0 ? void 0 : newPosition.lng);
15982
15988
  return hasEqualLat && hasEqualLng;
15983
15989
  };
15990
+ var isValidAnimation = function isValidAnimation() {
15991
+ var _window$google, _window$google$maps;
15992
+
15993
+ var animation = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
15994
+ var validAnimations = (_window$google = window.google) === null || _window$google === void 0 ? void 0 : (_window$google$maps = _window$google.maps) === null || _window$google$maps === void 0 ? void 0 : _window$google$maps.Animation;
15995
+ return (animation === null || animation === void 0 ? void 0 : animation.name) && validAnimations && validAnimations[animation === null || animation === void 0 ? void 0 : animation.name] !== undefined;
15996
+ };
15984
15997
 
15985
15998
  var Marker = function Marker(_ref) {
15986
15999
  var _ref$markerData = _ref.markerData,
@@ -15998,6 +16011,7 @@
15998
16011
  var _ref2 = marker || {},
15999
16012
  icon = _ref2.icon,
16000
16013
  position = _ref2.position,
16014
+ animation = _ref2.animation,
16001
16015
  overlay = _ref2.overlay,
16002
16016
  infoWindowChildren = _ref2.infoWindowChildren,
16003
16017
  isDraggable = _ref2.isDraggable;
@@ -16014,6 +16028,7 @@
16014
16028
  _onDragEnd = _markerOptions$onDrag3 === void 0 ? function () {} : _markerOptions$onDrag3;
16015
16029
 
16016
16030
  var markerRef = React.useRef(null);
16031
+ var timeoutRef = React.useRef(null);
16017
16032
 
16018
16033
  var _useState3 = React.useState(false),
16019
16034
  _useState4 = _slicedToArray(_useState3, 2),
@@ -16062,6 +16077,29 @@
16062
16077
  };
16063
16078
  };
16064
16079
 
16080
+ var animate = function animate() {
16081
+ var _markerRef$current2, _markerRef$current2$m;
16082
+
16083
+ if (!markerRef.current) return;
16084
+ if (!isValidAnimation(animation)) return;
16085
+ (_markerRef$current2 = markerRef.current) === null || _markerRef$current2 === void 0 ? void 0 : (_markerRef$current2$m = _markerRef$current2.marker) === null || _markerRef$current2$m === void 0 ? void 0 : _markerRef$current2$m.setAnimation(window.google.maps.Animation[animation === null || animation === void 0 ? void 0 : animation.name]);
16086
+ if (timeoutRef.current) clearTimeout(timeoutRef.current);
16087
+
16088
+ if (animation !== null && animation !== void 0 && animation.duration && isNumber(animation === null || animation === void 0 ? void 0 : animation.duration)) {
16089
+ timeoutRef.current = setTimeout(function () {
16090
+ var _markerRef$current3, _markerRef$current3$m;
16091
+
16092
+ (_markerRef$current3 = markerRef.current) === null || _markerRef$current3 === void 0 ? void 0 : (_markerRef$current3$m = _markerRef$current3.marker) === null || _markerRef$current3$m === void 0 ? void 0 : _markerRef$current3$m.setAnimation(null);
16093
+ }, animation === null || animation === void 0 ? void 0 : animation.duration);
16094
+ }
16095
+ };
16096
+
16097
+ React.useEffect(function () {
16098
+ if (animation && isObject$2(animation)) animate();
16099
+ return function () {
16100
+ if (timeoutRef.current) clearTimeout(timeoutRef.current);
16101
+ };
16102
+ }, [animation]);
16065
16103
  var markerProps = {
16066
16104
  ref: markerRef,
16067
16105
  position: position,
@@ -17593,7 +17631,7 @@
17593
17631
  };
17594
17632
 
17595
17633
  var anObject = anObject$h;
17596
- var isObject$1 = isObject$c;
17634
+ var isObject$1 = isObject$d;
17597
17635
  var newPromiseCapability$1 = newPromiseCapability$2;
17598
17636
 
17599
17637
  var promiseResolve$1 = function (C, x) {
@@ -17660,7 +17698,7 @@
17660
17698
  var setSpecies = setSpecies$1;
17661
17699
  var aCallable = aCallable$7;
17662
17700
  var isCallable = isCallable$k;
17663
- var isObject = isObject$c;
17701
+ var isObject = isObject$d;
17664
17702
  var anInstance = anInstance$3;
17665
17703
  var inspectSource = inspectSource$4;
17666
17704
  var iterate = iterate$1;