@alma/widgets 2.7.1 → 2.8.4
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/raw/widgets.css +6 -2
- package/dist/raw/widgets.js +184 -121
- package/dist/raw/widgets.js.map +1 -1
- package/dist/raw/widgets.m.js +184 -121
- package/dist/raw/widgets.m.js.map +1 -1
- package/dist/raw/widgets.modern.js +179 -118
- package/dist/raw/widgets.modern.js.map +1 -1
- package/dist/raw/widgets.umd.js +2626 -1081
- package/dist/raw/widgets.umd.js.map +1 -1
- package/dist/types/Widgets/PaymentPlans/__tests__/Monochrome.test.d.ts +1 -0
- package/dist/types/Widgets/PaymentPlans/index.d.ts +1 -0
- package/dist/types/assets/Logo.d.ts +3 -2
- package/dist/types/hooks/useButtonAnimation.d.ts +2 -1
- package/dist/types/types.d.ts +5 -4
- package/dist/widgets.css +1 -1
- package/dist/widgets.js +1 -1
- package/dist/widgets.js.map +1 -1
- package/dist/widgets.m.js +1 -1
- package/dist/widgets.m.js.map +1 -1
- package/dist/widgets.modern.js +1 -1
- package/dist/widgets.modern.js.map +1 -1
- package/dist/widgets.umd.js +1 -1
- package/dist/widgets.umd.js.map +1 -1
- package/package.json +1 -2
package/dist/raw/widgets.js
CHANGED
|
@@ -41,13 +41,21 @@ var functionUncurryThis = functionBindNative ? function (fn) {
|
|
|
41
41
|
};
|
|
42
42
|
|
|
43
43
|
var ceil = Math.ceil;
|
|
44
|
-
var floor = Math.floor; // `
|
|
44
|
+
var floor = Math.floor; // `Math.trunc` method
|
|
45
|
+
// https://tc39.es/ecma262/#sec-math.trunc
|
|
46
|
+
// eslint-disable-next-line es-x/no-math-trunc -- safe
|
|
47
|
+
|
|
48
|
+
var mathTrunc = Math.trunc || function trunc(x) {
|
|
49
|
+
var n = +x;
|
|
50
|
+
return (n > 0 ? floor : ceil)(n);
|
|
51
|
+
};
|
|
52
|
+
|
|
45
53
|
// https://tc39.es/ecma262/#sec-tointegerorinfinity
|
|
46
54
|
|
|
47
55
|
var toIntegerOrInfinity = function (argument) {
|
|
48
|
-
var number = +argument; // eslint-disable-next-line no-self-compare --
|
|
56
|
+
var number = +argument; // eslint-disable-next-line no-self-compare -- NaN check
|
|
49
57
|
|
|
50
|
-
return number !== number || number === 0 ? 0 : (number
|
|
58
|
+
return number !== number || number === 0 ? 0 : mathTrunc(number);
|
|
51
59
|
};
|
|
52
60
|
|
|
53
61
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
@@ -80,7 +88,7 @@ function () {
|
|
|
80
88
|
|
|
81
89
|
var defineProperty = Object.defineProperty;
|
|
82
90
|
|
|
83
|
-
var
|
|
91
|
+
var defineGlobalProperty = function (key, value) {
|
|
84
92
|
try {
|
|
85
93
|
defineProperty(global_1, key, {
|
|
86
94
|
value: value,
|
|
@@ -95,34 +103,34 @@ var setGlobal = function (key, value) {
|
|
|
95
103
|
};
|
|
96
104
|
|
|
97
105
|
var SHARED = '__core-js_shared__';
|
|
98
|
-
var store = global_1[SHARED] ||
|
|
106
|
+
var store = global_1[SHARED] || defineGlobalProperty(SHARED, {});
|
|
99
107
|
var sharedStore = store;
|
|
100
108
|
|
|
101
109
|
var shared = createCommonjsModule(function (module) {
|
|
102
110
|
(module.exports = function (key, value) {
|
|
103
111
|
return sharedStore[key] || (sharedStore[key] = value !== undefined ? value : {});
|
|
104
112
|
})('versions', []).push({
|
|
105
|
-
version: '3.22.
|
|
113
|
+
version: '3.22.8',
|
|
106
114
|
mode: 'global',
|
|
107
115
|
copyright: '© 2014-2022 Denis Pushkarev (zloirock.ru)',
|
|
108
|
-
license: 'https://github.com/zloirock/core-js/blob/v3.22.
|
|
116
|
+
license: 'https://github.com/zloirock/core-js/blob/v3.22.8/LICENSE',
|
|
109
117
|
source: 'https://github.com/zloirock/core-js'
|
|
110
118
|
});
|
|
111
119
|
});
|
|
112
120
|
|
|
113
|
-
var TypeError
|
|
121
|
+
var $TypeError = TypeError; // `RequireObjectCoercible` abstract operation
|
|
114
122
|
// https://tc39.es/ecma262/#sec-requireobjectcoercible
|
|
115
123
|
|
|
116
124
|
var requireObjectCoercible = function (it) {
|
|
117
|
-
if (it == undefined) throw TypeError
|
|
125
|
+
if (it == undefined) throw $TypeError("Can't call method on " + it);
|
|
118
126
|
return it;
|
|
119
127
|
};
|
|
120
128
|
|
|
121
|
-
var Object
|
|
129
|
+
var $Object = Object; // `ToObject` abstract operation
|
|
122
130
|
// https://tc39.es/ecma262/#sec-toobject
|
|
123
131
|
|
|
124
132
|
var toObject = function (argument) {
|
|
125
|
-
return Object
|
|
133
|
+
return $Object(requireObjectCoercible(argument));
|
|
126
134
|
};
|
|
127
135
|
|
|
128
136
|
var hasOwnProperty = functionUncurryThis({}.hasOwnProperty); // `HasOwnProperty` abstract operation
|
|
@@ -232,7 +240,7 @@ var classofRaw = function (it) {
|
|
|
232
240
|
};
|
|
233
241
|
|
|
234
242
|
var TO_STRING_TAG$1 = wellKnownSymbol('toStringTag');
|
|
235
|
-
var Object$
|
|
243
|
+
var $Object$1 = Object; // ES3 wrong here
|
|
236
244
|
|
|
237
245
|
var CORRECT_ARGUMENTS = classofRaw(function () {
|
|
238
246
|
return arguments;
|
|
@@ -250,16 +258,16 @@ var tryGet = function (it, key) {
|
|
|
250
258
|
var classof = toStringTagSupport ? classofRaw : function (it) {
|
|
251
259
|
var O, tag, result;
|
|
252
260
|
return it === undefined ? 'Undefined' : it === null ? 'Null' // @@toStringTag case
|
|
253
|
-
: typeof (tag = tryGet(O = Object$
|
|
261
|
+
: typeof (tag = tryGet(O = $Object$1(it), TO_STRING_TAG$1)) == 'string' ? tag // builtinTag case
|
|
254
262
|
: CORRECT_ARGUMENTS ? classofRaw(O) // ES3 arguments fallback
|
|
255
263
|
: (result = classofRaw(O)) == 'Object' && isCallable(O.callee) ? 'Arguments' : result;
|
|
256
264
|
};
|
|
257
265
|
|
|
258
|
-
var String
|
|
266
|
+
var $String = String;
|
|
259
267
|
|
|
260
268
|
var toString_1 = function (argument) {
|
|
261
269
|
if (classof(argument) === 'Symbol') throw TypeError('Cannot convert a Symbol value to a string');
|
|
262
|
-
return String
|
|
270
|
+
return $String(argument);
|
|
263
271
|
};
|
|
264
272
|
|
|
265
273
|
var charAt = functionUncurryThis(''.charAt);
|
|
@@ -342,12 +350,12 @@ var v8PrototypeDefineBug = descriptors && fails(function () {
|
|
|
342
350
|
}).prototype != 42;
|
|
343
351
|
});
|
|
344
352
|
|
|
345
|
-
var String$
|
|
346
|
-
var TypeError$
|
|
353
|
+
var $String$1 = String;
|
|
354
|
+
var $TypeError$1 = TypeError; // `Assert: Type(argument) is Object`
|
|
347
355
|
|
|
348
356
|
var anObject = function (argument) {
|
|
349
357
|
if (isObject(argument)) return argument;
|
|
350
|
-
throw TypeError$
|
|
358
|
+
throw $TypeError$1($String$1(argument) + ' is not an object');
|
|
351
359
|
};
|
|
352
360
|
|
|
353
361
|
var call$1 = Function.prototype.call;
|
|
@@ -357,29 +365,29 @@ var functionCall = functionBindNative ? call$1.bind(call$1) : function () {
|
|
|
357
365
|
|
|
358
366
|
var objectIsPrototypeOf = functionUncurryThis({}.isPrototypeOf);
|
|
359
367
|
|
|
360
|
-
var Object$
|
|
368
|
+
var $Object$2 = Object;
|
|
361
369
|
var isSymbol = useSymbolAsUid ? function (it) {
|
|
362
370
|
return typeof it == 'symbol';
|
|
363
371
|
} : function (it) {
|
|
364
372
|
var $Symbol = getBuiltIn('Symbol');
|
|
365
|
-
return isCallable($Symbol) && objectIsPrototypeOf($Symbol.prototype, Object$
|
|
373
|
+
return isCallable($Symbol) && objectIsPrototypeOf($Symbol.prototype, $Object$2(it));
|
|
366
374
|
};
|
|
367
375
|
|
|
368
|
-
var String$
|
|
376
|
+
var $String$2 = String;
|
|
369
377
|
|
|
370
378
|
var tryToString = function (argument) {
|
|
371
379
|
try {
|
|
372
|
-
return String$
|
|
380
|
+
return $String$2(argument);
|
|
373
381
|
} catch (error) {
|
|
374
382
|
return 'Object';
|
|
375
383
|
}
|
|
376
384
|
};
|
|
377
385
|
|
|
378
|
-
var TypeError$
|
|
386
|
+
var $TypeError$2 = TypeError; // `Assert: IsCallable(argument) is true`
|
|
379
387
|
|
|
380
388
|
var aCallable = function (argument) {
|
|
381
389
|
if (isCallable(argument)) return argument;
|
|
382
|
-
throw TypeError$
|
|
390
|
+
throw $TypeError$2(tryToString(argument) + ' is not a function');
|
|
383
391
|
};
|
|
384
392
|
|
|
385
393
|
// https://tc39.es/ecma262/#sec-getmethod
|
|
@@ -389,7 +397,7 @@ var getMethod = function (V, P) {
|
|
|
389
397
|
return func == null ? undefined : aCallable(func);
|
|
390
398
|
};
|
|
391
399
|
|
|
392
|
-
var TypeError$
|
|
400
|
+
var $TypeError$3 = TypeError; // `OrdinaryToPrimitive` abstract operation
|
|
393
401
|
// https://tc39.es/ecma262/#sec-ordinarytoprimitive
|
|
394
402
|
|
|
395
403
|
var ordinaryToPrimitive = function (input, pref) {
|
|
@@ -397,10 +405,10 @@ var ordinaryToPrimitive = function (input, pref) {
|
|
|
397
405
|
if (pref === 'string' && isCallable(fn = input.toString) && !isObject(val = functionCall(fn, input))) return val;
|
|
398
406
|
if (isCallable(fn = input.valueOf) && !isObject(val = functionCall(fn, input))) return val;
|
|
399
407
|
if (pref !== 'string' && isCallable(fn = input.toString) && !isObject(val = functionCall(fn, input))) return val;
|
|
400
|
-
throw TypeError$
|
|
408
|
+
throw $TypeError$3("Can't convert object to primitive value");
|
|
401
409
|
};
|
|
402
410
|
|
|
403
|
-
var TypeError$
|
|
411
|
+
var $TypeError$4 = TypeError;
|
|
404
412
|
var TO_PRIMITIVE = wellKnownSymbol('toPrimitive'); // `ToPrimitive` abstract operation
|
|
405
413
|
// https://tc39.es/ecma262/#sec-toprimitive
|
|
406
414
|
|
|
@@ -413,7 +421,7 @@ var toPrimitive = function (input, pref) {
|
|
|
413
421
|
if (pref === undefined) pref = 'default';
|
|
414
422
|
result = functionCall(exoticToPrim, input, pref);
|
|
415
423
|
if (!isObject(result) || isSymbol(result)) return result;
|
|
416
|
-
throw TypeError$
|
|
424
|
+
throw $TypeError$4("Can't convert object to primitive value");
|
|
417
425
|
}
|
|
418
426
|
|
|
419
427
|
if (pref === undefined) pref = 'number';
|
|
@@ -427,7 +435,7 @@ var toPropertyKey = function (argument) {
|
|
|
427
435
|
return isSymbol(key) ? key : key + '';
|
|
428
436
|
};
|
|
429
437
|
|
|
430
|
-
var TypeError$
|
|
438
|
+
var $TypeError$5 = TypeError; // eslint-disable-next-line es-x/no-object-defineproperty -- safe
|
|
431
439
|
|
|
432
440
|
var $defineProperty = Object.defineProperty; // eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
|
|
433
441
|
|
|
@@ -465,7 +473,7 @@ var f = descriptors ? v8PrototypeDefineBug ? function defineProperty(O, P, Attri
|
|
|
465
473
|
} catch (error) {
|
|
466
474
|
/* empty */
|
|
467
475
|
}
|
|
468
|
-
if ('get' in Attributes || 'set' in Attributes) throw TypeError$
|
|
476
|
+
if ('get' in Attributes || 'set' in Attributes) throw $TypeError$5('Accessors not supported');
|
|
469
477
|
if ('value' in Attributes) O[P] = Attributes.value;
|
|
470
478
|
return O;
|
|
471
479
|
};
|
|
@@ -498,7 +506,7 @@ var sharedKey = function (key) {
|
|
|
498
506
|
var hiddenKeys = {};
|
|
499
507
|
|
|
500
508
|
var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
|
|
501
|
-
var TypeError$
|
|
509
|
+
var TypeError$1 = global_1.TypeError;
|
|
502
510
|
var WeakMap$1 = global_1.WeakMap;
|
|
503
511
|
var set, get, has;
|
|
504
512
|
|
|
@@ -511,7 +519,7 @@ var getterFor = function (TYPE) {
|
|
|
511
519
|
var state;
|
|
512
520
|
|
|
513
521
|
if (!isObject(it) || (state = get(it)).type !== TYPE) {
|
|
514
|
-
throw TypeError$
|
|
522
|
+
throw TypeError$1('Incompatible receiver, ' + TYPE + ' required');
|
|
515
523
|
}
|
|
516
524
|
|
|
517
525
|
return state;
|
|
@@ -525,7 +533,7 @@ if (nativeWeakMap || sharedStore.state) {
|
|
|
525
533
|
var wmset = functionUncurryThis(store$1.set);
|
|
526
534
|
|
|
527
535
|
set = function (it, metadata) {
|
|
528
|
-
if (wmhas(store$1, it)) throw new TypeError$
|
|
536
|
+
if (wmhas(store$1, it)) throw new TypeError$1(OBJECT_ALREADY_INITIALIZED);
|
|
529
537
|
metadata.facade = it;
|
|
530
538
|
wmset(store$1, it, metadata);
|
|
531
539
|
return metadata;
|
|
@@ -543,7 +551,7 @@ if (nativeWeakMap || sharedStore.state) {
|
|
|
543
551
|
hiddenKeys[STATE] = true;
|
|
544
552
|
|
|
545
553
|
set = function (it, metadata) {
|
|
546
|
-
if (hasOwnProperty_1(it, STATE)) throw new TypeError$
|
|
554
|
+
if (hasOwnProperty_1(it, STATE)) throw new TypeError$1(OBJECT_ALREADY_INITIALIZED);
|
|
547
555
|
metadata.facade = it;
|
|
548
556
|
createNonEnumerableProperty(it, STATE, metadata);
|
|
549
557
|
return metadata;
|
|
@@ -583,16 +591,16 @@ var objectPropertyIsEnumerable = {
|
|
|
583
591
|
f: f$1
|
|
584
592
|
};
|
|
585
593
|
|
|
586
|
-
var Object$
|
|
594
|
+
var $Object$3 = Object;
|
|
587
595
|
var split = functionUncurryThis(''.split); // fallback for non-array-like ES3 and non-enumerable old V8 strings
|
|
588
596
|
|
|
589
597
|
var indexedObject = fails(function () {
|
|
590
598
|
// throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
|
|
591
599
|
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
592
|
-
return
|
|
600
|
+
return !$Object$3('z').propertyIsEnumerable(0);
|
|
593
601
|
}) ? function (it) {
|
|
594
|
-
return classofRaw(it) == 'String' ? split(it, '') : Object$
|
|
595
|
-
} : Object$
|
|
602
|
+
return classofRaw(it) == 'String' ? split(it, '') : $Object$3(it);
|
|
603
|
+
} : $Object$3;
|
|
596
604
|
|
|
597
605
|
var toIndexedObject = function (it) {
|
|
598
606
|
return indexedObject(requireObjectCoercible(it));
|
|
@@ -631,49 +639,84 @@ var functionName = {
|
|
|
631
639
|
CONFIGURABLE: CONFIGURABLE$1
|
|
632
640
|
};
|
|
633
641
|
|
|
634
|
-
var
|
|
642
|
+
var makeBuiltIn_1 = createCommonjsModule(function (module) {
|
|
635
643
|
var CONFIGURABLE_FUNCTION_NAME = functionName.CONFIGURABLE;
|
|
636
|
-
var getInternalState = internalState.get;
|
|
637
644
|
var enforceInternalState = internalState.enforce;
|
|
645
|
+
var getInternalState = internalState.get; // eslint-disable-next-line es-x/no-object-defineproperty -- safe
|
|
646
|
+
|
|
647
|
+
var defineProperty = Object.defineProperty;
|
|
648
|
+
var CONFIGURABLE_LENGTH = descriptors && !fails(function () {
|
|
649
|
+
return defineProperty(function () {
|
|
650
|
+
/* empty */
|
|
651
|
+
}, 'length', {
|
|
652
|
+
value: 8
|
|
653
|
+
}).length !== 8;
|
|
654
|
+
});
|
|
638
655
|
var TEMPLATE = String(String).split('String');
|
|
639
|
-
(module.exports = function (O, key, value, options) {
|
|
640
|
-
var unsafe = options ? !!options.unsafe : false;
|
|
641
|
-
var simple = options ? !!options.enumerable : false;
|
|
642
|
-
var noTargetGet = options ? !!options.noTargetGet : false;
|
|
643
|
-
var name = options && options.name !== undefined ? options.name : key;
|
|
644
|
-
var state;
|
|
645
656
|
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
657
|
+
var makeBuiltIn = module.exports = function (value, name, options) {
|
|
658
|
+
if (String(name).slice(0, 7) === 'Symbol(') {
|
|
659
|
+
name = '[' + String(name).replace(/^Symbol\(([^)]*)\)/, '$1') + ']';
|
|
660
|
+
}
|
|
650
661
|
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
}
|
|
662
|
+
if (options && options.getter) name = 'get ' + name;
|
|
663
|
+
if (options && options.setter) name = 'set ' + name;
|
|
654
664
|
|
|
655
|
-
|
|
665
|
+
if (!hasOwnProperty_1(value, 'name') || CONFIGURABLE_FUNCTION_NAME && value.name !== name) {
|
|
666
|
+
defineProperty(value, 'name', {
|
|
667
|
+
value: name,
|
|
668
|
+
configurable: true
|
|
669
|
+
});
|
|
670
|
+
}
|
|
656
671
|
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
672
|
+
if (CONFIGURABLE_LENGTH && options && hasOwnProperty_1(options, 'arity') && value.length !== options.arity) {
|
|
673
|
+
defineProperty(value, 'length', {
|
|
674
|
+
value: options.arity
|
|
675
|
+
});
|
|
660
676
|
}
|
|
661
677
|
|
|
662
|
-
|
|
663
|
-
if (
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
678
|
+
try {
|
|
679
|
+
if (options && hasOwnProperty_1(options, 'constructor') && options.constructor) {
|
|
680
|
+
if (descriptors) defineProperty(value, 'prototype', {
|
|
681
|
+
writable: false
|
|
682
|
+
}); // in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable
|
|
683
|
+
} else if (value.prototype) value.prototype = undefined;
|
|
684
|
+
} catch (error) {
|
|
685
|
+
/* empty */
|
|
686
|
+
}
|
|
687
|
+
|
|
688
|
+
var state = enforceInternalState(value);
|
|
689
|
+
|
|
690
|
+
if (!hasOwnProperty_1(state, 'source')) {
|
|
691
|
+
state.source = TEMPLATE.join(typeof name == 'string' ? name : '');
|
|
669
692
|
}
|
|
670
693
|
|
|
671
|
-
|
|
672
|
-
}
|
|
694
|
+
return value;
|
|
695
|
+
}; // add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
|
|
696
|
+
// eslint-disable-next-line no-extend-native -- required
|
|
697
|
+
|
|
698
|
+
|
|
699
|
+
Function.prototype.toString = makeBuiltIn(function toString() {
|
|
673
700
|
return isCallable(this) && getInternalState(this).source || inspectSource(this);
|
|
674
|
-
});
|
|
701
|
+
}, 'toString');
|
|
675
702
|
});
|
|
676
703
|
|
|
704
|
+
var defineBuiltIn = function (O, key, value, options) {
|
|
705
|
+
if (!options) options = {};
|
|
706
|
+
var simple = options.enumerable;
|
|
707
|
+
var name = options.name !== undefined ? options.name : key;
|
|
708
|
+
if (isCallable(value)) makeBuiltIn_1(value, name, options);
|
|
709
|
+
|
|
710
|
+
if (options.global) {
|
|
711
|
+
if (simple) O[key] = value;else defineGlobalProperty(key, value);
|
|
712
|
+
} else {
|
|
713
|
+
if (!options.unsafe) delete O[key];else if (O[key]) simple = true;
|
|
714
|
+
if (simple) O[key] = value;else createNonEnumerableProperty(O, key, value);
|
|
715
|
+
}
|
|
716
|
+
|
|
717
|
+
return O;
|
|
718
|
+
};
|
|
719
|
+
|
|
677
720
|
var max = Math.max;
|
|
678
721
|
var min = Math.min; // Helper for a popular repeating case of the spec:
|
|
679
722
|
// Let integer be ? ToInteger(index).
|
|
@@ -805,19 +848,19 @@ var isForced_1 = isForced;
|
|
|
805
848
|
|
|
806
849
|
var getOwnPropertyDescriptor$1 = objectGetOwnPropertyDescriptor.f;
|
|
807
850
|
/*
|
|
808
|
-
options.target
|
|
809
|
-
options.global
|
|
810
|
-
options.stat
|
|
811
|
-
options.proto
|
|
812
|
-
options.real
|
|
813
|
-
options.forced
|
|
814
|
-
options.bind
|
|
815
|
-
options.wrap
|
|
816
|
-
options.unsafe
|
|
817
|
-
options.sham
|
|
818
|
-
options.enumerable
|
|
819
|
-
options.
|
|
820
|
-
options.name
|
|
851
|
+
options.target - name of the target object
|
|
852
|
+
options.global - target is the global object
|
|
853
|
+
options.stat - export as static methods of target
|
|
854
|
+
options.proto - export as prototype methods of target
|
|
855
|
+
options.real - real prototype method for the `pure` version
|
|
856
|
+
options.forced - export even if the native feature is available
|
|
857
|
+
options.bind - bind methods to the target, required for the `pure` version
|
|
858
|
+
options.wrap - wrap constructors to preventing global pollution, required for the `pure` version
|
|
859
|
+
options.unsafe - use the simple assignment of property instead of delete + defineProperty
|
|
860
|
+
options.sham - add a flag to not completely full polyfills
|
|
861
|
+
options.enumerable - export as enumerable property
|
|
862
|
+
options.dontCallGetSet - prevent calling a getter on target
|
|
863
|
+
options.name - the .name of the function if it does not match the key
|
|
821
864
|
*/
|
|
822
865
|
|
|
823
866
|
var _export = function (options, source) {
|
|
@@ -829,7 +872,7 @@ var _export = function (options, source) {
|
|
|
829
872
|
if (GLOBAL) {
|
|
830
873
|
target = global_1;
|
|
831
874
|
} else if (STATIC) {
|
|
832
|
-
target = global_1[TARGET] ||
|
|
875
|
+
target = global_1[TARGET] || defineGlobalProperty(TARGET, {});
|
|
833
876
|
} else {
|
|
834
877
|
target = (global_1[TARGET] || {}).prototype;
|
|
835
878
|
}
|
|
@@ -837,7 +880,7 @@ var _export = function (options, source) {
|
|
|
837
880
|
if (target) for (key in source) {
|
|
838
881
|
sourceProperty = source[key];
|
|
839
882
|
|
|
840
|
-
if (options.
|
|
883
|
+
if (options.dontCallGetSet) {
|
|
841
884
|
descriptor = getOwnPropertyDescriptor$1(target, key);
|
|
842
885
|
targetProperty = descriptor && descriptor.value;
|
|
843
886
|
} else targetProperty = target[key];
|
|
@@ -852,10 +895,9 @@ var _export = function (options, source) {
|
|
|
852
895
|
|
|
853
896
|
if (options.sham || targetProperty && targetProperty.sham) {
|
|
854
897
|
createNonEnumerableProperty(sourceProperty, 'sham', true);
|
|
855
|
-
}
|
|
856
|
-
|
|
898
|
+
}
|
|
857
899
|
|
|
858
|
-
|
|
900
|
+
defineBuiltIn(target, key, sourceProperty, options);
|
|
859
901
|
}
|
|
860
902
|
};
|
|
861
903
|
|
|
@@ -983,11 +1025,12 @@ var correctPrototypeGetter = !fails(function () {
|
|
|
983
1025
|
});
|
|
984
1026
|
|
|
985
1027
|
var IE_PROTO$1 = sharedKey('IE_PROTO');
|
|
986
|
-
var Object$
|
|
987
|
-
var ObjectPrototype = Object$
|
|
1028
|
+
var $Object$4 = Object;
|
|
1029
|
+
var ObjectPrototype = $Object$4.prototype; // `Object.getPrototypeOf` method
|
|
988
1030
|
// https://tc39.es/ecma262/#sec-object.getprototypeof
|
|
1031
|
+
// eslint-disable-next-line es-x/no-object-getprototypeof -- safe
|
|
989
1032
|
|
|
990
|
-
var objectGetPrototypeOf = correctPrototypeGetter ? Object$
|
|
1033
|
+
var objectGetPrototypeOf = correctPrototypeGetter ? $Object$4.getPrototypeOf : function (O) {
|
|
991
1034
|
var object = toObject(O);
|
|
992
1035
|
if (hasOwnProperty_1(object, IE_PROTO$1)) return object[IE_PROTO$1];
|
|
993
1036
|
var constructor = object.constructor;
|
|
@@ -996,7 +1039,7 @@ var objectGetPrototypeOf = correctPrototypeGetter ? Object$5.getPrototypeOf : fu
|
|
|
996
1039
|
return constructor.prototype;
|
|
997
1040
|
}
|
|
998
1041
|
|
|
999
|
-
return object instanceof Object$
|
|
1042
|
+
return object instanceof $Object$4 ? ObjectPrototype : null;
|
|
1000
1043
|
};
|
|
1001
1044
|
|
|
1002
1045
|
var ITERATOR = wellKnownSymbol('iterator');
|
|
@@ -1024,7 +1067,7 @@ if (NEW_ITERATOR_PROTOTYPE) IteratorPrototype = {}; // `%IteratorPrototype%[@@it
|
|
|
1024
1067
|
// https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator
|
|
1025
1068
|
|
|
1026
1069
|
if (!isCallable(IteratorPrototype[ITERATOR])) {
|
|
1027
|
-
|
|
1070
|
+
defineBuiltIn(IteratorPrototype, ITERATOR, function () {
|
|
1028
1071
|
return this;
|
|
1029
1072
|
});
|
|
1030
1073
|
}
|
|
@@ -1066,12 +1109,12 @@ var createIteratorConstructor = function (IteratorConstructor, NAME, next, ENUME
|
|
|
1066
1109
|
return IteratorConstructor;
|
|
1067
1110
|
};
|
|
1068
1111
|
|
|
1069
|
-
var String$
|
|
1070
|
-
var TypeError$
|
|
1112
|
+
var $String$3 = String;
|
|
1113
|
+
var $TypeError$6 = TypeError;
|
|
1071
1114
|
|
|
1072
1115
|
var aPossiblePrototype = function (argument) {
|
|
1073
1116
|
if (typeof argument == 'object' || isCallable(argument)) return argument;
|
|
1074
|
-
throw TypeError$
|
|
1117
|
+
throw $TypeError$6("Can't set " + $String$3(argument) + ' as a prototype');
|
|
1075
1118
|
};
|
|
1076
1119
|
|
|
1077
1120
|
/* eslint-disable no-proto -- safe */
|
|
@@ -1160,7 +1203,7 @@ var defineIterator = function (Iterable, NAME, IteratorConstructor, next, DEFAUL
|
|
|
1160
1203
|
if (objectSetPrototypeOf) {
|
|
1161
1204
|
objectSetPrototypeOf(CurrentIteratorPrototype, IteratorPrototype$2);
|
|
1162
1205
|
} else if (!isCallable(CurrentIteratorPrototype[ITERATOR$1])) {
|
|
1163
|
-
|
|
1206
|
+
defineBuiltIn(CurrentIteratorPrototype, ITERATOR$1, returnThis$1);
|
|
1164
1207
|
}
|
|
1165
1208
|
} // Set @@toStringTag to native iterators
|
|
1166
1209
|
|
|
@@ -1191,7 +1234,7 @@ var defineIterator = function (Iterable, NAME, IteratorConstructor, next, DEFAUL
|
|
|
1191
1234
|
};
|
|
1192
1235
|
if (FORCED) for (KEY in methods) {
|
|
1193
1236
|
if (BUGGY_SAFARI_ITERATORS$1 || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {
|
|
1194
|
-
|
|
1237
|
+
defineBuiltIn(IterablePrototype, KEY, methods[KEY]);
|
|
1195
1238
|
}
|
|
1196
1239
|
} else _export({
|
|
1197
1240
|
target: NAME,
|
|
@@ -1202,7 +1245,7 @@ var defineIterator = function (Iterable, NAME, IteratorConstructor, next, DEFAUL
|
|
|
1202
1245
|
|
|
1203
1246
|
|
|
1204
1247
|
if ( IterablePrototype[ITERATOR$1] !== defaultIterator) {
|
|
1205
|
-
|
|
1248
|
+
defineBuiltIn(IterablePrototype, ITERATOR$1, defaultIterator, {
|
|
1206
1249
|
name: DEFAULT
|
|
1207
1250
|
});
|
|
1208
1251
|
}
|
|
@@ -1353,15 +1396,15 @@ var getIteratorMethod = function (it) {
|
|
|
1353
1396
|
if (it != undefined) return getMethod(it, ITERATOR$3) || getMethod(it, '@@iterator') || iterators[classof(it)];
|
|
1354
1397
|
};
|
|
1355
1398
|
|
|
1356
|
-
var TypeError$
|
|
1399
|
+
var $TypeError$7 = TypeError;
|
|
1357
1400
|
|
|
1358
1401
|
var getIterator = function (argument, usingIterator) {
|
|
1359
1402
|
var iteratorMethod = arguments.length < 2 ? getIteratorMethod(argument) : usingIterator;
|
|
1360
1403
|
if (aCallable(iteratorMethod)) return anObject(functionCall(iteratorMethod, argument));
|
|
1361
|
-
throw TypeError$
|
|
1404
|
+
throw $TypeError$7(tryToString(argument) + ' is not iterable');
|
|
1362
1405
|
};
|
|
1363
1406
|
|
|
1364
|
-
var Array
|
|
1407
|
+
var $Array = Array; // `Array.from` method implementation
|
|
1365
1408
|
// https://tc39.es/ecma262/#sec-array.from
|
|
1366
1409
|
|
|
1367
1410
|
var arrayFrom = function from(arrayLike
|
|
@@ -1377,7 +1420,7 @@ var arrayFrom = function from(arrayLike
|
|
|
1377
1420
|
var index = 0;
|
|
1378
1421
|
var length, result, step, iterator, next, value; // if the target is not iterable or it's an array with the default iterator - use a simple case
|
|
1379
1422
|
|
|
1380
|
-
if (iteratorMethod && !(this
|
|
1423
|
+
if (iteratorMethod && !(this === $Array && isArrayIteratorMethod(iteratorMethod))) {
|
|
1381
1424
|
iterator = getIterator(O, iteratorMethod);
|
|
1382
1425
|
next = iterator.next;
|
|
1383
1426
|
result = IS_CONSTRUCTOR ? new this() : [];
|
|
@@ -1388,7 +1431,7 @@ var arrayFrom = function from(arrayLike
|
|
|
1388
1431
|
}
|
|
1389
1432
|
} else {
|
|
1390
1433
|
length = lengthOfArrayLike(O);
|
|
1391
|
-
result = IS_CONSTRUCTOR ? new this(length) : Array
|
|
1434
|
+
result = IS_CONSTRUCTOR ? new this(length) : $Array(length);
|
|
1392
1435
|
|
|
1393
1436
|
for (; length > index; index++) {
|
|
1394
1437
|
value = mapping ? mapfn(O[index], index) : O[index];
|
|
@@ -1843,7 +1886,7 @@ var messagesDE = {
|
|
|
1843
1886
|
"eligibility-modal.title-deferred": "<highlighted>Bezahlen Sie in Raten</highlighted> oder später per Kreditkarte mit Alma.",
|
|
1844
1887
|
"eligibility-modal.total": "Insgesamt",
|
|
1845
1888
|
"installments.today": "Heute",
|
|
1846
|
-
"payment-plan-strings.day-abbreviation": "
|
|
1889
|
+
"payment-plan-strings.day-abbreviation": "T{numberOfDeferredDays}",
|
|
1847
1890
|
"payment-plan-strings.default-message": "Bezahlen Sie in Raten mit Alma",
|
|
1848
1891
|
"payment-plan-strings.deferred": "{totalAmount} zu zahlen am {dueDate}",
|
|
1849
1892
|
"payment-plan-strings.ineligible-greater-than-max": "Bis zu {maxAmount}",
|
|
@@ -2004,7 +2047,7 @@ var Provider = function Provider(_ref) {
|
|
|
2004
2047
|
};
|
|
2005
2048
|
|
|
2006
2049
|
function _extends() {
|
|
2007
|
-
_extends = Object.assign
|
|
2050
|
+
_extends = Object.assign ? Object.assign.bind() : function (target) {
|
|
2008
2051
|
for (var i = 1; i < arguments.length; i++) {
|
|
2009
2052
|
var source = arguments[i];
|
|
2010
2053
|
|
|
@@ -2017,7 +2060,6 @@ function _extends() {
|
|
|
2017
2060
|
|
|
2018
2061
|
return target;
|
|
2019
2062
|
};
|
|
2020
|
-
|
|
2021
2063
|
return _extends.apply(this, arguments);
|
|
2022
2064
|
}
|
|
2023
2065
|
|
|
@@ -2694,12 +2736,21 @@ var Info = function Info() {
|
|
|
2694
2736
|
}))));
|
|
2695
2737
|
};
|
|
2696
2738
|
|
|
2739
|
+
var COLORS;
|
|
2740
|
+
|
|
2741
|
+
(function (COLORS) {
|
|
2742
|
+
COLORS["ALMA"] = "#FF414D";
|
|
2743
|
+
COLORS["MONOCHROME"] = "#00425D";
|
|
2744
|
+
})(COLORS || (COLORS = {}));
|
|
2745
|
+
|
|
2697
2746
|
function LogoIcon(_ref) {
|
|
2698
|
-
var
|
|
2699
|
-
|
|
2700
|
-
_ref$
|
|
2701
|
-
|
|
2702
|
-
|
|
2747
|
+
var className = _ref.className,
|
|
2748
|
+
_ref$color = _ref.color,
|
|
2749
|
+
color = _ref$color === void 0 ? COLORS.MONOCHROME : _ref$color,
|
|
2750
|
+
_ref$monochrome = _ref.monochrome,
|
|
2751
|
+
monochrome = _ref$monochrome === void 0 ? true : _ref$monochrome,
|
|
2752
|
+
underlineColor = _ref.underlineColor;
|
|
2753
|
+
var defaultUnderlineColor = monochrome ? COLORS.MONOCHROME : COLORS.ALMA;
|
|
2703
2754
|
return /*#__PURE__*/React__default.createElement("svg", {
|
|
2704
2755
|
className: className,
|
|
2705
2756
|
width: "35",
|
|
@@ -2723,7 +2774,7 @@ function LogoIcon(_ref) {
|
|
|
2723
2774
|
y: "20",
|
|
2724
2775
|
width: "40",
|
|
2725
2776
|
height: "3",
|
|
2726
|
-
fill: underlineColor
|
|
2777
|
+
fill: underlineColor || defaultUnderlineColor
|
|
2727
2778
|
}));
|
|
2728
2779
|
}
|
|
2729
2780
|
|
|
@@ -2895,11 +2946,12 @@ var useButtonAnimation = function useButtonAnimation(iterateValues, transitionDe
|
|
|
2895
2946
|
setUpdate = _useState2[1];
|
|
2896
2947
|
|
|
2897
2948
|
React.useEffect(function () {
|
|
2949
|
+
var timeout;
|
|
2898
2950
|
var isMounted = true;
|
|
2899
2951
|
|
|
2900
2952
|
if (iterateValues.length !== 0) {
|
|
2901
2953
|
if (!iterateValues.includes(current) && update) setCurrent(iterateValues[0]);
|
|
2902
|
-
setTimeout(function () {
|
|
2954
|
+
timeout = setTimeout(function () {
|
|
2903
2955
|
if (update && isMounted) {
|
|
2904
2956
|
setCurrent(iterateValues[iterateValues.includes(current) ? (iterateValues.indexOf(current) + 1) % iterateValues.length : 0]);
|
|
2905
2957
|
}
|
|
@@ -2908,6 +2960,7 @@ var useButtonAnimation = function useButtonAnimation(iterateValues, transitionDe
|
|
|
2908
2960
|
|
|
2909
2961
|
return function () {
|
|
2910
2962
|
isMounted = false;
|
|
2963
|
+
clearTimeout(timeout);
|
|
2911
2964
|
};
|
|
2912
2965
|
}, [iterateValues, current]);
|
|
2913
2966
|
return {
|
|
@@ -2974,7 +3027,7 @@ var STATIC_CUSTOMISATION_CLASSES$1 = {
|
|
|
2974
3027
|
activeOption: prefix$1 + '-active-option'
|
|
2975
3028
|
};
|
|
2976
3029
|
|
|
2977
|
-
var s$c = {"widgetButton":"_TSkFv","logo":"_LJ4nZ","primaryContainer":"_bMClc","paymentPlans":"_17c_S","plan":"_2Kqjn","active":"_3dG_J","notEligible":"_3O1bg","info":"_25GrF","loader":"_30j1O","error":"_R0YlN","errorText":"_2kGhu","errorButton":"_73d_Y","pending":"_1ZDMS","clickable":"_UksZa","unClickable":"_1lr-q"};
|
|
3030
|
+
var s$c = {"widgetButton":"_TSkFv","logo":"_LJ4nZ","primaryContainer":"_bMClc","paymentPlans":"_17c_S","plan":"_2Kqjn","active":"_3dG_J","polychrome":"_2icEF","notEligible":"_3O1bg","info":"_25GrF","loader":"_30j1O","error":"_R0YlN","errorText":"_2kGhu","errorButton":"_73d_Y","pending":"_1ZDMS","clickable":"_UksZa","unClickable":"_1lr-q"};
|
|
2978
3031
|
|
|
2979
3032
|
var VERY_LONG_TIME_IN_MS = 1000 * 3600 * 24 * 365;
|
|
2980
3033
|
var DEFAULT_TRANSITION_TIME = 5500;
|
|
@@ -2982,13 +3035,14 @@ var DEFAULT_TRANSITION_TIME = 5500;
|
|
|
2982
3035
|
var PaymentPlanWidget = function PaymentPlanWidget(_ref) {
|
|
2983
3036
|
var _cx, _cx3;
|
|
2984
3037
|
|
|
2985
|
-
var
|
|
2986
|
-
apiData = _ref.apiData,
|
|
3038
|
+
var apiData = _ref.apiData,
|
|
2987
3039
|
configPlans = _ref.configPlans,
|
|
2988
|
-
transitionDelay = _ref.transitionDelay,
|
|
2989
3040
|
hideIfNotEligible = _ref.hideIfNotEligible,
|
|
3041
|
+
monochrome = _ref.monochrome,
|
|
3042
|
+
purchaseAmount = _ref.purchaseAmount,
|
|
2990
3043
|
suggestedPaymentPlan = _ref.suggestedPaymentPlan,
|
|
2991
|
-
cards = _ref.cards
|
|
3044
|
+
cards = _ref.cards,
|
|
3045
|
+
transitionDelay = _ref.transitionDelay;
|
|
2992
3046
|
|
|
2993
3047
|
var _useFetchEligibility = useFetchEligibility(purchaseAmount, apiData, configPlans),
|
|
2994
3048
|
eligibilityPlans = _useFetchEligibility[0],
|
|
@@ -3091,19 +3145,25 @@ var PaymentPlanWidget = function PaymentPlanWidget(_ref) {
|
|
|
3091
3145
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
3092
3146
|
className: cx(s$c.primaryContainer, STATIC_CUSTOMISATION_CLASSES$1.eligibilityLine)
|
|
3093
3147
|
}, /*#__PURE__*/React__default.createElement(LogoIcon, {
|
|
3094
|
-
className: s$c.logo
|
|
3148
|
+
className: s$c.logo,
|
|
3149
|
+
monochrome: monochrome
|
|
3095
3150
|
}), /*#__PURE__*/React__default.createElement("div", {
|
|
3096
3151
|
className: cx(s$c.paymentPlans, STATIC_CUSTOMISATION_CLASSES$1.eligibilityOptions)
|
|
3097
3152
|
}, eligibilityPlans.map(function (eligibilityPlan, key) {
|
|
3098
3153
|
var _cx2;
|
|
3099
3154
|
|
|
3155
|
+
var isCurrent = key === current;
|
|
3100
3156
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
3101
3157
|
key: key,
|
|
3102
3158
|
onMouseEnter: function onMouseEnter() {
|
|
3103
3159
|
return onHover(key);
|
|
3104
3160
|
},
|
|
3161
|
+
onTouchStart: function onTouchStart() {
|
|
3162
|
+
return onHover(key);
|
|
3163
|
+
},
|
|
3105
3164
|
onMouseOut: onLeave,
|
|
3106
|
-
|
|
3165
|
+
onTouchEnd: onLeave,
|
|
3166
|
+
className: cx(s$c.plan, (_cx2 = {}, _cx2[cx(s$c.active, STATIC_CUSTOMISATION_CLASSES$1.activeOption)] = isCurrent, _cx2[s$c.polychrome] = !monochrome && isCurrent, _cx2[cx(s$c.notEligible, STATIC_CUSTOMISATION_CLASSES$1.notEligibleOption)] = !eligibilityPlan.eligible, _cx2))
|
|
3107
3167
|
}, paymentPlanShorthandName(eligibilityPlan));
|
|
3108
3168
|
}))), /*#__PURE__*/React__default.createElement("div", {
|
|
3109
3169
|
className: cx(s$c.info, (_cx3 = {}, _cx3[cx(s$c.notEligible, STATIC_CUSTOMISATION_CLASSES$1.notEligibleOption)] = eligibilityPlans[current] && !eligibilityPlans[current].eligible, _cx3), STATIC_CUSTOMISATION_CLASSES$1.paymentInfo)
|
|
@@ -3138,6 +3198,8 @@ var WidgetsController = /*#__PURE__*/function () {
|
|
|
3138
3198
|
plans = options.plans,
|
|
3139
3199
|
transitionDelay = options.transitionDelay,
|
|
3140
3200
|
hideIfNotEligible = options.hideIfNotEligible,
|
|
3201
|
+
_options$monochrome = options.monochrome,
|
|
3202
|
+
monochrome = _options$monochrome === void 0 ? true : _options$monochrome,
|
|
3141
3203
|
suggestedPaymentPlan = options.suggestedPaymentPlan,
|
|
3142
3204
|
_options$locale = options.locale,
|
|
3143
3205
|
locale = _options$locale === void 0 ? Locale.en : _options$locale,
|
|
@@ -3147,13 +3209,14 @@ var WidgetsController = /*#__PURE__*/function () {
|
|
|
3147
3209
|
reactDom.render( /*#__PURE__*/React__default.createElement(Provider, {
|
|
3148
3210
|
locale: locale
|
|
3149
3211
|
}, /*#__PURE__*/React__default.createElement(PaymentPlanWidget, {
|
|
3150
|
-
purchaseAmount: purchaseAmount,
|
|
3151
3212
|
apiData: this.apiData,
|
|
3152
3213
|
configPlans: plans,
|
|
3153
|
-
transitionDelay: transitionDelay,
|
|
3154
3214
|
hideIfNotEligible: hideIfNotEligible,
|
|
3215
|
+
monochrome: monochrome,
|
|
3216
|
+
purchaseAmount: purchaseAmount,
|
|
3155
3217
|
suggestedPaymentPlan: suggestedPaymentPlan,
|
|
3156
|
-
cards: cards
|
|
3218
|
+
cards: cards,
|
|
3219
|
+
transitionDelay: transitionDelay
|
|
3157
3220
|
})), document.querySelector(container));
|
|
3158
3221
|
}
|
|
3159
3222
|
}
|