@alma/widgets 2.6.0 → 2.7.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.
@@ -2194,6 +2194,7 @@ var STATIC_CUSTOMISATION_CLASSES = {
2194
2194
  scheduleDetails: prefix + '-schedule-details',
2195
2195
  scheduleTotal: prefix + '-schedule-total',
2196
2196
  scheduleCredit: prefix + '-schedule-credit',
2197
+ cardContainer: prefix + '-card-logos',
2197
2198
  summary: prefix + '-summary'
2198
2199
  };
2199
2200
 
@@ -2469,16 +2470,184 @@ var Schedule = function Schedule(_ref) {
2469
2470
  }))));
2470
2471
  };
2471
2472
 
2472
- var s$4 = {"list":"_180ro","listItem":"_1HqCO","bullet":"_3B8wx"};
2473
+ var AmexCard = function AmexCard() {
2474
+ return /*#__PURE__*/React.createElement("svg", {
2475
+ xmlns: "http://www.w3.org/2000/svg",
2476
+ width: "24",
2477
+ height: "16",
2478
+ viewBox: "0 0 24 16"
2479
+ }, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
2480
+ id: "cardamex",
2481
+ x1: "10.914%",
2482
+ x2: "87.432%",
2483
+ y1: "86.279%",
2484
+ y2: "15.035%"
2485
+ }, /*#__PURE__*/React.createElement("stop", {
2486
+ offset: "0%",
2487
+ stopColor: "#3FA9F5"
2488
+ }), /*#__PURE__*/React.createElement("stop", {
2489
+ offset: "100%",
2490
+ stopColor: "#0071BC"
2491
+ }))), /*#__PURE__*/React.createElement("g", {
2492
+ fill: "none",
2493
+ fillRule: "evenodd"
2494
+ }, /*#__PURE__*/React.createElement("path", {
2495
+ fill: "url(#cardamex)",
2496
+ fillRule: "nonzero",
2497
+ d: "M22.559 16H1.379C.627 16 0 15.392 0 14.662V1.338C0 .608.627 0 1.379 0H22.62C23.373 0 24 .608 24 1.338v13.324c-.063.73-.627 1.338-1.441 1.338z"
2498
+ }), /*#__PURE__*/React.createElement("g", {
2499
+ fill: "#FFF"
2500
+ }, /*#__PURE__*/React.createElement("path", {
2501
+ d: "M10.115 8.711L8.889 6.044H7.295v3.852L5.517 6.044H4.17l-1.778 4.03h1.103l.368-.889h2.023l.368.89h2.084V7.11l1.349 2.963h.92l1.348-2.904v2.904h.98v-4.03H11.28l-1.165 2.667zm-5.272-.474H4.23l.613-1.422v.06l.613 1.362h-.613z"
2502
+ }), /*#__PURE__*/React.createElement("path", {
2503
+ fillRule: "nonzero",
2504
+ d: "M19.372 7.94l.735-.77 1.042-1.185h-1.287L18.697 7.23l-1.164-1.245h-3.985v3.97h3.923l1.226-1.303 1.165 1.304h1.287L20.107 8.71l-.735-.77zM16.92 9.186h-2.33v-.77h2.268v-.77H14.59v-.712h2.33L18.084 8 16.92 9.185z"
2505
+ }))));
2506
+ };
2507
+
2508
+ var VisaCard = function VisaCard() {
2509
+ return /*#__PURE__*/React.createElement("svg", {
2510
+ xmlns: "http://www.w3.org/2000/svg",
2511
+ width: "24",
2512
+ height: "16",
2513
+ viewBox: "0 0 24 16"
2514
+ }, /*#__PURE__*/React.createElement("g", {
2515
+ fill: "none",
2516
+ fillRule: "nonzero"
2517
+ }, /*#__PURE__*/React.createElement("path", {
2518
+ fill: "#FCFCFC",
2519
+ d: "M22.684 16H1.38C.627 16 0 15.39 0 14.656V1.344C0 .61.627 0 1.379 0H22.62C23.373 0 24 .61 24 1.344v13.374c0 .671-.564 1.282-1.316 1.282z"
2520
+ }), ' ', /*#__PURE__*/React.createElement("path", {
2521
+ fill: "#005098",
2522
+ d: "M8.889 10.726l.948-5.393h1.482l-.949 5.393zM15.704 5.452a3.658 3.658 0 0 0-1.304-.237c-1.481 0-2.489.71-2.489 1.778 0 .77.711 1.185 1.304 1.481.592.237.77.415.77.652 0 .355-.474.533-.889.533-.592 0-.889-.059-1.363-.296l-.177-.06-.178 1.186c.355.178 1.007.296 1.659.296 1.54 0 2.548-.71 2.548-1.837 0-.592-.415-1.067-1.244-1.481-.534-.237-.83-.415-.83-.652 0-.237.237-.474.83-.474.474 0 .83.118 1.126.178l.118.059.119-1.126M19.496 5.333H18.37c-.355 0-.592.119-.77.474l-2.193 4.919h1.541s.237-.652.296-.83h1.897c.059.178.178.83.178.83h1.362l-1.185-5.393zM17.66 8.77l.593-1.481s.118-.296.178-.533l.118.474s.296 1.303.356 1.54h-1.245zM7.644 5.333L6.222 9.007l-.178-.77C5.748 7.348 4.92 6.459 4.03 5.985l1.303 4.682h1.541l2.311-5.393h-1.54"
2523
+ }), /*#__PURE__*/React.createElement("path", {
2524
+ fill: "#F6A500",
2525
+ d: "M4.919 5.333h-2.37v.119c1.836.474 3.08 1.54 3.555 2.844L5.57 5.807c-.118-.414-.355-.474-.651-.474"
2526
+ }), /*#__PURE__*/React.createElement("path", {
2527
+ fill: "#0A5296",
2528
+ d: "M23.937 3.23H0V1.316C0 .598.627 0 1.379 0H22.62C23.373 0 24 .598 24 1.316V3.23h-.063z"
2529
+ }), /*#__PURE__*/React.createElement("path", {
2530
+ fill: "#F4A428",
2531
+ d: "M.063 13H24v1.8c0 .655-.625 1.2-1.375 1.2H1.375C.625 16 0 15.455 0 14.8V13h.063z"
2532
+ })));
2533
+ };
2534
+
2535
+ var MasterCard = function MasterCard() {
2536
+ return /*#__PURE__*/React.createElement("svg", {
2537
+ width: "24px",
2538
+ height: "16px",
2539
+ viewBox: "0 0 24 16",
2540
+ version: "1.1",
2541
+ xmlns: "http://www.w3.org/2000/svg"
2542
+ }, /*#__PURE__*/React.createElement("g", {
2543
+ id: "Parcours-1C-B",
2544
+ stroke: "none",
2545
+ strokeWidth: "1",
2546
+ fill: "none",
2547
+ fillRule: "evenodd"
2548
+ }, /*#__PURE__*/React.createElement("g", {
2549
+ id: "mobile-1C-Paiement-V1",
2550
+ transform: "translate(-269.000000, -313.000000)"
2551
+ }, /*#__PURE__*/React.createElement("g", {
2552
+ id: "mastercard",
2553
+ transform: "translate(269.000000, 313.000000)"
2554
+ }, /*#__PURE__*/React.createElement("rect", {
2555
+ id: "Rectangle",
2556
+ fill: "#FFFFFF",
2557
+ x: "0",
2558
+ y: "0",
2559
+ width: "24",
2560
+ height: "16",
2561
+ rx: "1"
2562
+ }), /*#__PURE__*/React.createElement("g", {
2563
+ id: "Group-6",
2564
+ transform: "translate(4.000000, 3.000000)"
2565
+ }, /*#__PURE__*/React.createElement("circle", {
2566
+ id: "Oval-4-Copy",
2567
+ fill: "#EA001B",
2568
+ cx: "5.05263158",
2569
+ cy: "5.05263158",
2570
+ r: "5.05263158"
2571
+ }), /*#__PURE__*/React.createElement("circle", {
2572
+ id: "Oval-4",
2573
+ fillOpacity: "0.25",
2574
+ fill: "#F79F1A",
2575
+ cx: "10.9473684",
2576
+ cy: "5.05263158",
2577
+ r: "5.05263158"
2578
+ }), /*#__PURE__*/React.createElement("circle", {
2579
+ id: "Oval-4-Copy-2",
2580
+ fillOpacity: "0.9",
2581
+ fill: "#F79F1A",
2582
+ cx: "10.9473684",
2583
+ cy: "5.05263158",
2584
+ r: "5.05263158"
2585
+ }), /*#__PURE__*/React.createElement("circle", {
2586
+ id: "Oval-4-Copy-3",
2587
+ fillOpacity: "0.3",
2588
+ fill: "#EA001B",
2589
+ cx: "5.05263158",
2590
+ cy: "5.05263158",
2591
+ r: "5.05263158"
2592
+ }))))));
2593
+ };
2594
+
2595
+ var CbCard = function CbCard() {
2596
+ return /*#__PURE__*/React.createElement("svg", {
2597
+ xmlns: "http://www.w3.org/2000/svg",
2598
+ width: "24",
2599
+ height: "16",
2600
+ viewBox: "0 0 24 16"
2601
+ }, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
2602
+ id: "cardcb",
2603
+ x1: "5.842%",
2604
+ x2: "95.393%",
2605
+ y1: "81.753%",
2606
+ y2: "17.344%"
2607
+ }, /*#__PURE__*/React.createElement("stop", {
2608
+ offset: "0%",
2609
+ stopColor: "#39B54A"
2610
+ }), ' ', /*#__PURE__*/React.createElement("stop", {
2611
+ offset: "100%",
2612
+ stopColor: "#0A5296"
2613
+ }))), /*#__PURE__*/React.createElement("g", {
2614
+ fill: "none",
2615
+ fillRule: "nonzero"
2616
+ }, /*#__PURE__*/React.createElement("path", {
2617
+ fill: "url(#cardcb)",
2618
+ d: "M22.621 16H1.38C.627 16 0 15.392 0 14.662V1.338C0 .608.627 0 1.379 0H22.62C23.373 0 24 .608 24 1.338v13.324c-.063.73-.627 1.338-1.379 1.338z"
2619
+ }), /*#__PURE__*/React.createElement("g", {
2620
+ fill: "#FFF"
2621
+ }, /*#__PURE__*/React.createElement("path", {
2622
+ d: "M19.094 4.03h-6.437V8h6.498c1.165 0 2.084-.889 2.084-2.015-.06-1.066-.98-1.955-2.145-1.955zM19.094 8.593h-6.437v3.97h6.498c1.165 0 2.084-.889 2.084-2.015-.06-1.067-.98-1.955-2.145-1.955zM7.017 8.06h4.966c-.245-2.371-2.391-4.267-4.966-4.267-2.758 0-5.027 2.074-5.027 4.681s2.269 4.682 5.027 4.682c2.698 0 4.904-2.015 5.027-4.563H7.017v-.534z"
2623
+ }))));
2624
+ };
2625
+
2626
+ var s$4 = {"cardContainer":"_1N3yO","card":"_83cGn"};
2627
+
2628
+ var Cards = function Cards(_ref) {
2629
+ var cards = _ref.cards;
2630
+ return /*#__PURE__*/React.createElement("div", {
2631
+ className: cx(s$4.cardContainer, STATIC_CUSTOMISATION_CLASSES.cardContainer)
2632
+ }, cards.map(function (card) {
2633
+ return /*#__PURE__*/React.createElement("div", {
2634
+ key: card,
2635
+ className: s$4.card,
2636
+ "data-testid": "card-logo-" + card
2637
+ }, card === 'cb' && /*#__PURE__*/React.createElement(CbCard, null), card === 'amex' && /*#__PURE__*/React.createElement(AmexCard, null), card === 'mastercard' && /*#__PURE__*/React.createElement(MasterCard, null), card === 'visa' && /*#__PURE__*/React.createElement(VisaCard, null));
2638
+ }));
2639
+ };
2640
+
2641
+ var s$5 = {"list":"_180ro","listItem":"_1HqCO","bullet":"_3B8wx"};
2473
2642
 
2474
2643
  var Info = function Info() {
2475
2644
  return /*#__PURE__*/React.createElement("div", {
2476
- className: cx(s$4.list, STATIC_CUSTOMISATION_CLASSES.info),
2645
+ className: cx(s$5.list, STATIC_CUSTOMISATION_CLASSES.info),
2477
2646
  "data-testid": "modal-info-element"
2478
2647
  }, /*#__PURE__*/React.createElement("div", {
2479
- className: s$4.listItem
2648
+ className: s$5.listItem
2480
2649
  }, /*#__PURE__*/React.createElement("div", {
2481
- className: s$4.bullet
2650
+ className: s$5.bullet
2482
2651
  }, "1"), /*#__PURE__*/React.createElement("div", {
2483
2652
  className: STATIC_CUSTOMISATION_CLASSES.infoMessage
2484
2653
  }, /*#__PURE__*/React.createElement(FormattedMessage, {
@@ -2490,9 +2659,9 @@ var Info = function Info() {
2490
2659
  }
2491
2660
  }
2492
2661
  }))), /*#__PURE__*/React.createElement("div", {
2493
- className: s$4.listItem
2662
+ className: s$5.listItem
2494
2663
  }, /*#__PURE__*/React.createElement("div", {
2495
- className: s$4.bullet
2664
+ className: s$5.bullet
2496
2665
  }, "2"), /*#__PURE__*/React.createElement("div", {
2497
2666
  className: STATIC_CUSTOMISATION_CLASSES.infoMessage
2498
2667
  }, /*#__PURE__*/React.createElement(FormattedMessage, {
@@ -2504,9 +2673,9 @@ var Info = function Info() {
2504
2673
  }
2505
2674
  }
2506
2675
  }))), /*#__PURE__*/React.createElement("div", {
2507
- className: s$4.listItem
2676
+ className: s$5.listItem
2508
2677
  }, /*#__PURE__*/React.createElement("div", {
2509
- className: s$4.bullet
2678
+ className: s$5.bullet
2510
2679
  }, "3"), /*#__PURE__*/React.createElement("div", {
2511
2680
  className: STATIC_CUSTOMISATION_CLASSES.infoMessage
2512
2681
  }, /*#__PURE__*/React.createElement(FormattedMessage, {
@@ -2553,22 +2722,22 @@ function LogoIcon(_ref) {
2553
2722
  }));
2554
2723
  }
2555
2724
 
2556
- var s$5 = {"logo":"_3Oyv_"};
2725
+ var s$6 = {"logo":"_3Oyv_"};
2557
2726
 
2558
2727
  var Logo = function Logo() {
2559
2728
  return /*#__PURE__*/React.createElement("div", {
2560
- className: s$5.logo
2729
+ className: s$6.logo
2561
2730
  }, /*#__PURE__*/React.createElement(LogoIcon, {
2562
2731
  underlineColor: "#FF414D"
2563
2732
  }));
2564
2733
  };
2565
2734
 
2566
- var s$6 = {"title":"_3ERx-"};
2735
+ var s$7 = {"title":"_3ERx-"};
2567
2736
 
2568
2737
  var Title = function Title(_ref) {
2569
2738
  var isSomePlanDeferred = _ref.isSomePlanDeferred;
2570
2739
  return /*#__PURE__*/React.createElement("div", {
2571
- className: cx(s$6.title, STATIC_CUSTOMISATION_CLASSES.title),
2740
+ className: cx(s$7.title, STATIC_CUSTOMISATION_CLASSES.title),
2572
2741
  "data-testid": "modal-title-element"
2573
2742
  }, isSomePlanDeferred ? /*#__PURE__*/React.createElement(FormattedMessage, {
2574
2743
  id: 'eligibility-modal.title-deferred',
@@ -2589,43 +2758,50 @@ var Title = function Title(_ref) {
2589
2758
  }));
2590
2759
  };
2591
2760
 
2592
- var s$7 = {"container":"_21g6u","block":"_3zaP5","left":"_2SBRC"};
2761
+ var s$8 = {"container":"_21g6u","block":"_3zaP5","left":"_2SBRC"};
2593
2762
 
2594
2763
  var DesktopModal = function DesktopModal(_ref) {
2595
2764
  var children = _ref.children,
2596
- isSomePlanDeferred = _ref.isSomePlanDeferred;
2765
+ isSomePlanDeferred = _ref.isSomePlanDeferred,
2766
+ cards = _ref.cards;
2597
2767
  return /*#__PURE__*/React.createElement("div", {
2598
- className: s$7.container,
2768
+ className: s$8.container,
2599
2769
  "data-testid": "modal-container"
2600
2770
  }, /*#__PURE__*/React.createElement("div", {
2601
- className: cx([s$7.block, s$7.left, STATIC_CUSTOMISATION_CLASSES.leftSide])
2771
+ className: cx([s$8.block, s$8.left, STATIC_CUSTOMISATION_CLASSES.leftSide])
2602
2772
  }, /*#__PURE__*/React.createElement(Title, {
2603
2773
  isSomePlanDeferred: isSomePlanDeferred
2604
- }), /*#__PURE__*/React.createElement(Info, null), /*#__PURE__*/React.createElement(Logo, null)), /*#__PURE__*/React.createElement("div", {
2605
- className: cx(s$7.block, STATIC_CUSTOMISATION_CLASSES.rightSide)
2774
+ }), /*#__PURE__*/React.createElement(Info, null), cards && /*#__PURE__*/React.createElement(Cards, {
2775
+ cards: cards
2776
+ }), /*#__PURE__*/React.createElement(Logo, null)), /*#__PURE__*/React.createElement("div", {
2777
+ className: cx(s$8.block, STATIC_CUSTOMISATION_CLASSES.rightSide)
2606
2778
  }, children));
2607
2779
  };
2608
2780
 
2609
- var s$8 = {"noEligibility":"_17qNJ","loader":"_2oTJq"};
2781
+ var s$9 = {"noEligibility":"_17qNJ","loader":"_2oTJq"};
2610
2782
 
2611
- var s$9 = {"container":"_2G7Ch"};
2783
+ var s$a = {"container":"_2G7Ch"};
2612
2784
 
2613
2785
  var MobileModal = function MobileModal(_ref) {
2614
2786
  var children = _ref.children,
2615
- isSomePlanDeferred = _ref.isSomePlanDeferred;
2787
+ isSomePlanDeferred = _ref.isSomePlanDeferred,
2788
+ cards = _ref.cards;
2616
2789
  return /*#__PURE__*/React.createElement("div", {
2617
- className: s$9.container,
2790
+ className: s$a.container,
2618
2791
  "data-testid": "modal-container"
2619
2792
  }, /*#__PURE__*/React.createElement(Title, {
2620
2793
  isSomePlanDeferred: isSomePlanDeferred
2621
- }), children, /*#__PURE__*/React.createElement(Info, null), /*#__PURE__*/React.createElement(Logo, null));
2794
+ }), children, /*#__PURE__*/React.createElement(Info, null), cards && /*#__PURE__*/React.createElement(Cards, {
2795
+ cards: cards
2796
+ }), /*#__PURE__*/React.createElement(Logo, null));
2622
2797
  };
2623
2798
 
2624
2799
  var EligibilityModal = function EligibilityModal(_ref) {
2625
2800
  var initialPlanIndex = _ref.initialPlanIndex,
2626
2801
  onClose = _ref.onClose,
2627
2802
  eligibilityPlans = _ref.eligibilityPlans,
2628
- status = _ref.status;
2803
+ status = _ref.status,
2804
+ cards = _ref.cards;
2629
2805
 
2630
2806
  var _useState = useState(initialPlanIndex || 0),
2631
2807
  currentPlanIndex = _useState[0],
@@ -2648,11 +2824,12 @@ var EligibilityModal = function EligibilityModal(_ref) {
2648
2824
  scrollable: true,
2649
2825
  isOpen: true
2650
2826
  }, /*#__PURE__*/React.createElement(ModalComponent, {
2651
- isSomePlanDeferred: isSomePlanDeferred
2827
+ isSomePlanDeferred: isSomePlanDeferred,
2828
+ cards: cards
2652
2829
  }, status === apiStatus.PENDING && /*#__PURE__*/React.createElement("div", {
2653
- className: s$8.loader
2830
+ className: s$9.loader
2654
2831
  }, /*#__PURE__*/React.createElement(LoadingIndicator, null)), status === apiStatus.SUCCESS && eligiblePlans.length === 0 && /*#__PURE__*/React.createElement("div", {
2655
- className: s$8.noEligibility
2832
+ className: s$9.noEligibility
2656
2833
  }, /*#__PURE__*/React.createElement(FormattedMessage, {
2657
2834
  id: "eligibility-modal.no-eligibility",
2658
2835
  defaultMessage: "Oups, il semblerait que la simulation n'ait pas fonctionn\xE9."
@@ -2673,7 +2850,8 @@ var ModalContainer = function ModalContainer(_ref) {
2673
2850
  var purchaseAmount = _ref.purchaseAmount,
2674
2851
  apiData = _ref.apiData,
2675
2852
  configPlans = _ref.configPlans,
2676
- onClose = _ref.onClose;
2853
+ onClose = _ref.onClose,
2854
+ cards = _ref.cards;
2677
2855
 
2678
2856
  var _useFetchEligibility = useFetchEligibility(purchaseAmount, apiData, configPlans),
2679
2857
  eligibilityPlans = _useFetchEligibility[0],
@@ -2683,21 +2861,22 @@ var ModalContainer = function ModalContainer(_ref) {
2683
2861
  initialPlanIndex: 0,
2684
2862
  onClose: onClose,
2685
2863
  eligibilityPlans: eligibilityPlans,
2686
- status: status
2864
+ status: status,
2865
+ cards: cards
2687
2866
  });
2688
2867
  };
2689
2868
 
2690
- var s$a = {"loadingIndicator":"_2SwwZ","line1":"_2qODo","line2":"_2YO01"};
2869
+ var s$b = {"loadingIndicator":"_2SwwZ","line1":"_2qODo","line2":"_2YO01"};
2691
2870
 
2692
2871
  var Loader = function Loader(_ref) {
2693
2872
  var className = _ref.className;
2694
2873
  return /*#__PURE__*/React.createElement("div", {
2695
- className: cx(s$a.loadingIndicator, className),
2874
+ className: cx(s$b.loadingIndicator, className),
2696
2875
  "data-testid": "loader"
2697
2876
  }, /*#__PURE__*/React.createElement("div", {
2698
- className: s$a.line1
2877
+ className: s$b.line1
2699
2878
  }), /*#__PURE__*/React.createElement("div", {
2700
- className: s$a.line2
2879
+ className: s$b.line2
2701
2880
  }));
2702
2881
  };
2703
2882
 
@@ -2790,7 +2969,7 @@ var STATIC_CUSTOMISATION_CLASSES$1 = {
2790
2969
  activeOption: prefix$1 + '-active-option'
2791
2970
  };
2792
2971
 
2793
- var s$b = {"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"};
2972
+ 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"};
2794
2973
 
2795
2974
  var VERY_LONG_TIME_IN_MS = 1000 * 3600 * 24 * 365;
2796
2975
  var DEFAULT_TRANSITION_TIME = 5500;
@@ -2803,7 +2982,8 @@ var PaymentPlanWidget = function PaymentPlanWidget(_ref) {
2803
2982
  configPlans = _ref.configPlans,
2804
2983
  transitionDelay = _ref.transitionDelay,
2805
2984
  hideIfNotEligible = _ref.hideIfNotEligible,
2806
- suggestedPaymentPlan = _ref.suggestedPaymentPlan;
2985
+ suggestedPaymentPlan = _ref.suggestedPaymentPlan,
2986
+ cards = _ref.cards;
2807
2987
 
2808
2988
  var _useFetchEligibility = useFetchEligibility(purchaseAmount, apiData, configPlans),
2809
2989
  eligibilityPlans = _useFetchEligibility[0],
@@ -2883,7 +3063,7 @@ var PaymentPlanWidget = function PaymentPlanWidget(_ref) {
2883
3063
 
2884
3064
  if (status === apiStatus.PENDING) {
2885
3065
  return /*#__PURE__*/React.createElement("div", {
2886
- className: cx(s$b.widgetButton, s$b.pending)
3066
+ className: cx(s$c.widgetButton, s$c.pending)
2887
3067
  }, /*#__PURE__*/React.createElement(Loader, null));
2888
3068
  }
2889
3069
 
@@ -2901,14 +3081,14 @@ var PaymentPlanWidget = function PaymentPlanWidget(_ref) {
2901
3081
 
2902
3082
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
2903
3083
  onClick: handleOpenModal,
2904
- className: cx(s$b.widgetButton, (_cx = {}, _cx[s$b.clickable] = eligiblePlans.length > 0, _cx[s$b.unClickable] = eligiblePlans.length === 0, _cx), STATIC_CUSTOMISATION_CLASSES$1.container),
3084
+ className: cx(s$c.widgetButton, (_cx = {}, _cx[s$c.clickable] = eligiblePlans.length > 0, _cx[s$c.unClickable] = eligiblePlans.length === 0, _cx), STATIC_CUSTOMISATION_CLASSES$1.container),
2905
3085
  "data-testid": "widget-button"
2906
3086
  }, /*#__PURE__*/React.createElement("div", {
2907
- className: cx(s$b.primaryContainer, STATIC_CUSTOMISATION_CLASSES$1.eligibilityLine)
3087
+ className: cx(s$c.primaryContainer, STATIC_CUSTOMISATION_CLASSES$1.eligibilityLine)
2908
3088
  }, /*#__PURE__*/React.createElement(LogoIcon, {
2909
- className: s$b.logo
3089
+ className: s$c.logo
2910
3090
  }), /*#__PURE__*/React.createElement("div", {
2911
- className: cx(s$b.paymentPlans, STATIC_CUSTOMISATION_CLASSES$1.eligibilityOptions)
3091
+ className: cx(s$c.paymentPlans, STATIC_CUSTOMISATION_CLASSES$1.eligibilityOptions)
2912
3092
  }, eligibilityPlans.map(function (eligibilityPlan, key) {
2913
3093
  var _cx2;
2914
3094
 
@@ -2918,15 +3098,16 @@ var PaymentPlanWidget = function PaymentPlanWidget(_ref) {
2918
3098
  return onHover(key);
2919
3099
  },
2920
3100
  onMouseOut: onLeave,
2921
- className: cx(s$b.plan, (_cx2 = {}, _cx2[cx(s$b.active, STATIC_CUSTOMISATION_CLASSES$1.activeOption)] = current === key, _cx2[cx(s$b.notEligible, STATIC_CUSTOMISATION_CLASSES$1.notEligibleOption)] = !eligibilityPlan.eligible, _cx2))
3101
+ className: cx(s$c.plan, (_cx2 = {}, _cx2[cx(s$c.active, STATIC_CUSTOMISATION_CLASSES$1.activeOption)] = current === key, _cx2[cx(s$c.notEligible, STATIC_CUSTOMISATION_CLASSES$1.notEligibleOption)] = !eligibilityPlan.eligible, _cx2))
2922
3102
  }, paymentPlanShorthandName(eligibilityPlan));
2923
3103
  }))), /*#__PURE__*/React.createElement("div", {
2924
- className: cx(s$b.info, (_cx3 = {}, _cx3[cx(s$b.notEligible, STATIC_CUSTOMISATION_CLASSES$1.notEligibleOption)] = eligibilityPlans[current] && !eligibilityPlans[current].eligible, _cx3), STATIC_CUSTOMISATION_CLASSES$1.paymentInfo)
3104
+ 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)
2925
3105
  }, eligibilityPlans.length !== 0 && paymentPlanInfoText(eligibilityPlans[current]))), isOpen && /*#__PURE__*/React.createElement(EligibilityModal, {
2926
3106
  initialPlanIndex: getIndexWithinEligiblePlans(current),
2927
3107
  onClose: closeModal,
2928
3108
  eligibilityPlans: eligiblePlans,
2929
- status: status
3109
+ status: status,
3110
+ cards: cards
2930
3111
  }));
2931
3112
  };
2932
3113
 
@@ -2954,7 +3135,8 @@ var WidgetsController = /*#__PURE__*/function () {
2954
3135
  hideIfNotEligible = options.hideIfNotEligible,
2955
3136
  suggestedPaymentPlan = options.suggestedPaymentPlan,
2956
3137
  _options$locale = options.locale,
2957
- locale = _options$locale === void 0 ? Locale.en : _options$locale;
3138
+ locale = _options$locale === void 0 ? Locale.en : _options$locale,
3139
+ cards = options.cards;
2958
3140
 
2959
3141
  if (containerDiv) {
2960
3142
  render( /*#__PURE__*/React.createElement(Provider, {
@@ -2965,7 +3147,8 @@ var WidgetsController = /*#__PURE__*/function () {
2965
3147
  configPlans: plans,
2966
3148
  transitionDelay: transitionDelay,
2967
3149
  hideIfNotEligible: hideIfNotEligible,
2968
- suggestedPaymentPlan: suggestedPaymentPlan
3150
+ suggestedPaymentPlan: suggestedPaymentPlan,
3151
+ cards: cards
2969
3152
  })), document.querySelector(container));
2970
3153
  }
2971
3154
  }
@@ -2976,7 +3159,8 @@ var WidgetsController = /*#__PURE__*/function () {
2976
3159
  _purchaseAmount = options.purchaseAmount,
2977
3160
  _plans = options.plans,
2978
3161
  _options$locale2 = options.locale,
2979
- _locale = _options$locale2 === void 0 ? Locale.en : _options$locale2;
3162
+ _locale = _options$locale2 === void 0 ? Locale.en : _options$locale2,
3163
+ _cards = options.cards;
2980
3164
 
2981
3165
  var close = function close() {
2982
3166
  return containerDiv && unmountComponentAtNode(containerDiv);
@@ -2989,7 +3173,8 @@ var WidgetsController = /*#__PURE__*/function () {
2989
3173
  purchaseAmount: _purchaseAmount,
2990
3174
  apiData: _this.apiData,
2991
3175
  configPlans: _plans,
2992
- onClose: close
3176
+ onClose: close,
3177
+ cards: _cards
2993
3178
  })), document.querySelector(_container));
2994
3179
  }; // if clickableSelector is provided, add an onClick event handler to open the Modal.
2995
3180