@alma/widgets 2.4.0 → 2.6.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/raw/widgets.css +13 -2
- package/dist/raw/widgets.js +72 -47
- package/dist/raw/widgets.js.map +1 -1
- package/dist/raw/widgets.m.js +72 -47
- package/dist/raw/widgets.m.js.map +1 -1
- package/dist/raw/widgets.modern.js +67 -45
- package/dist/raw/widgets.modern.js.map +1 -1
- package/dist/raw/widgets.umd.js +72 -47
- package/dist/raw/widgets.umd.js.map +1 -1
- package/dist/types/Widgets/EligibilityModal/DesktopModal/index.d.ts +3 -1
- package/dist/types/Widgets/EligibilityModal/MobileModal/index.d.ts +3 -1
- package/dist/types/Widgets/EligibilityModal/ModalContainer.test.d.ts +1 -0
- package/dist/types/Widgets/EligibilityModal/classNames.const.d.ts +1 -0
- package/dist/types/Widgets/EligibilityModal/components/Title/index.d.ts +3 -1
- package/dist/types/Widgets/EligibilityModal/modal.test.d.ts +1 -0
- package/dist/types/Widgets/PaymentPlans/__tests__/Basics.test.d.ts +1 -0
- package/dist/types/Widgets/PaymentPlans/__tests__/Credit.test.d.ts +1 -0
- package/dist/types/Widgets/PaymentPlans/__tests__/CustomTransitionDelay.test.d.ts +1 -0
- package/dist/types/Widgets/PaymentPlans/__tests__/HideWidget.test.d.ts +1 -0
- package/dist/types/Widgets/PaymentPlans/__tests__/IneligibleOptions.test.d.ts +1 -0
- package/dist/types/Widgets/PaymentPlans/__tests__/LanguageCheck.test.d.ts +1 -0
- package/dist/types/Widgets/PaymentPlans/__tests__/LaunchModal.test.d.ts +1 -0
- package/dist/types/Widgets/PaymentPlans/__tests__/SuggestedPaymentPlan.test.d.ts +1 -0
- package/dist/types/Widgets/PaymentPlans/__tests__/WithoutPlans.test.d.ts +1 -0
- package/dist/types/test/fixtures.d.ts +1 -0
- package/dist/types/utils/index.test.d.ts +1 -0
- package/dist/widgets.css +2 -2
- 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 -1
package/dist/raw/widgets.css
CHANGED
|
@@ -319,7 +319,7 @@
|
|
|
319
319
|
|
|
320
320
|
._MPKjS {
|
|
321
321
|
padding: 32px 24px;
|
|
322
|
-
margin-bottom:
|
|
322
|
+
margin-bottom: 16px;
|
|
323
323
|
border-top: 1px solid var(--gray-300);
|
|
324
324
|
border-bottom: 1px solid var(--gray-300);
|
|
325
325
|
}
|
|
@@ -337,6 +337,13 @@
|
|
|
337
337
|
font-size: 18px;
|
|
338
338
|
}
|
|
339
339
|
|
|
340
|
+
._65ZpD {
|
|
341
|
+
background: var(--gray-200);
|
|
342
|
+
padding: 24px;
|
|
343
|
+
margin: 24px 0px;
|
|
344
|
+
border-radius: 8px;
|
|
345
|
+
}
|
|
346
|
+
|
|
340
347
|
._1ZIgu {
|
|
341
348
|
font-family: 'Eina04', sans-serif;
|
|
342
349
|
font-weight: 600;
|
|
@@ -344,6 +351,10 @@
|
|
|
344
351
|
margin-bottom: 24px;
|
|
345
352
|
}
|
|
346
353
|
|
|
354
|
+
._tUTZp {
|
|
355
|
+
text-align: right;
|
|
356
|
+
}
|
|
357
|
+
|
|
347
358
|
._1BUr8 {
|
|
348
359
|
margin-top: 8px;
|
|
349
360
|
}
|
|
@@ -354,6 +365,7 @@
|
|
|
354
365
|
margin: 0;
|
|
355
366
|
border-bottom: 1px solid transparent;
|
|
356
367
|
height: 100%;
|
|
368
|
+
max-height: 180px;
|
|
357
369
|
}
|
|
358
370
|
}
|
|
359
371
|
|
|
@@ -440,7 +452,6 @@
|
|
|
440
452
|
height: 100%;
|
|
441
453
|
display: flex;
|
|
442
454
|
flex-direction: column;
|
|
443
|
-
justify-content: space-between;
|
|
444
455
|
width: 100%;
|
|
445
456
|
}
|
|
446
457
|
|
package/dist/raw/widgets.js
CHANGED
|
@@ -1838,8 +1838,9 @@ var messagesDE = {
|
|
|
1838
1838
|
"eligibility-modal.credit-commitment": "Ein Kredit verpflichtet Sie und muss zurückgezahlt werden. Prüfen Sie Ihre Rückzahlungsfähigkeit, bevor Sie sich verpflichten.",
|
|
1839
1839
|
"eligibility-modal.credit-cost": "Davon Kreditkosten",
|
|
1840
1840
|
"eligibility-modal.credit-cost-amount": "{creditCost} (APR {TAEG})",
|
|
1841
|
-
"eligibility-modal.no-eligibility": "Ups, die Simulation
|
|
1842
|
-
"eligibility-modal.title": "<highlighted>Bezahlen Sie in Raten</highlighted>
|
|
1841
|
+
"eligibility-modal.no-eligibility": "Ups, die Simulation hat anscheinend nicht funktioniert.",
|
|
1842
|
+
"eligibility-modal.title": "<highlighted>Bezahlen Sie in Raten</highlighted> per Kreditkarte mit Alma.",
|
|
1843
|
+
"eligibility-modal.title-deferred": "<highlighted>Bezahlen Sie in Raten</highlighted> oder später per Kreditkarte mit Alma.",
|
|
1843
1844
|
"eligibility-modal.total": "Insgesamt",
|
|
1844
1845
|
"installments.today": "Heutzutage",
|
|
1845
1846
|
"payment-plan-strings.day-abbreviation": "J{numberOfDeferredDays}",
|
|
@@ -1861,7 +1862,8 @@ var messagesEN = {
|
|
|
1861
1862
|
"eligibility-modal.credit-cost": "Of which cost of credit",
|
|
1862
1863
|
"eligibility-modal.credit-cost-amount": "{creditCost} (APR {TAEG})",
|
|
1863
1864
|
"eligibility-modal.no-eligibility": "Oops, looks like the simulation didn't work.",
|
|
1864
|
-
"eligibility-modal.title": "<highlighted>Pay in installments</highlighted>
|
|
1865
|
+
"eligibility-modal.title": "<highlighted>Pay in installments</highlighted> by credit card with Alma.",
|
|
1866
|
+
"eligibility-modal.title-deferred": "<highlighted>Pay in installments</highlighted> or later by credit card with Alma.",
|
|
1865
1867
|
"eligibility-modal.total": "Total",
|
|
1866
1868
|
"installments.today": "Today",
|
|
1867
1869
|
"payment-plan-strings.day-abbreviation": "T{numberOfDeferredDays}",
|
|
@@ -1883,7 +1885,8 @@ var messagesES = {
|
|
|
1883
1885
|
"eligibility-modal.credit-cost": "Coste de crédito (incl. en el total)",
|
|
1884
1886
|
"eligibility-modal.credit-cost-amount": "{creditCost} (TAE {TAEG})",
|
|
1885
1887
|
"eligibility-modal.no-eligibility": "Uy, parece que la simulación no ha funcionado.",
|
|
1886
|
-
"eligibility-modal.title": "<highlighted>Paga a plazos</highlighted>
|
|
1888
|
+
"eligibility-modal.title": "<highlighted>Paga a plazos</highlighted> con tarjeta de crédito con Alma.",
|
|
1889
|
+
"eligibility-modal.title-deferred": "<highlighted>Paga a plazos</highlighted> o más adelante con tu tarjeta, a través de Alma.",
|
|
1887
1890
|
"eligibility-modal.total": "Total",
|
|
1888
1891
|
"installments.today": "Hoy",
|
|
1889
1892
|
"payment-plan-strings.day-abbreviation": "D{numberOfDeferredDays}",
|
|
@@ -1904,8 +1907,9 @@ var messagesFR = {
|
|
|
1904
1907
|
"eligibility-modal.credit-commitment": "Un crédit vous engage et doit être remboursé. Vérifiez vos capacités de remboursement avant de vous engager.",
|
|
1905
1908
|
"eligibility-modal.credit-cost": "Dont coût du crédit",
|
|
1906
1909
|
"eligibility-modal.credit-cost-amount": "{creditCost} (TAEG {TAEG})",
|
|
1907
|
-
"eligibility-modal.no-eligibility": "Oups, il semblerait que la simulation n'
|
|
1908
|
-
"eligibility-modal.title": "<highlighted>Payez en plusieurs fois</highlighted>
|
|
1910
|
+
"eligibility-modal.no-eligibility": "Oups, il semblerait que la simulation n'ait pas fonctionné.",
|
|
1911
|
+
"eligibility-modal.title": "<highlighted>Payez en plusieurs fois</highlighted> par carte bancaire avec Alma.",
|
|
1912
|
+
"eligibility-modal.title-deferred": "<highlighted>Payez en plusieurs fois</highlighted> ou plus tard par carte bancaire avec Alma.",
|
|
1909
1913
|
"eligibility-modal.total": "Total",
|
|
1910
1914
|
"installments.today": "Aujourd'hui",
|
|
1911
1915
|
"payment-plan-strings.day-abbreviation": "J{numberOfDeferredDays}",
|
|
@@ -1927,7 +1931,8 @@ var messagesIT = {
|
|
|
1927
1931
|
"eligibility-modal.credit-cost": "Di cui commissioni",
|
|
1928
1932
|
"eligibility-modal.credit-cost-amount": "{creditCost} (TAEG {TAEG})",
|
|
1929
1933
|
"eligibility-modal.no-eligibility": "Ops, sembra che la simulazione non abbia funzionato.",
|
|
1930
|
-
"eligibility-modal.title": "<highlighted>Paga a rate</highlighted>
|
|
1934
|
+
"eligibility-modal.title": "<highlighted>Paga a rate</highlighted> con carta di credito con Alma.",
|
|
1935
|
+
"eligibility-modal.title-deferred": "<highlighted>Paga a rate</highlighted> e posticipa il pagamento con Alma, senza interessi.",
|
|
1931
1936
|
"eligibility-modal.total": "Totale",
|
|
1932
1937
|
"installments.today": "Oggi",
|
|
1933
1938
|
"payment-plan-strings.day-abbreviation": "G{numberOfDeferredDays}",
|
|
@@ -1949,7 +1954,8 @@ var messagesNL = {
|
|
|
1949
1954
|
"eligibility-modal.credit-cost": "Waarvan kosten van krediet",
|
|
1950
1955
|
"eligibility-modal.credit-cost-amount": "{creditCost} (APR {TAEG})",
|
|
1951
1956
|
"eligibility-modal.no-eligibility": "Oeps, het lijkt erop dat de simulatie niet werkte.",
|
|
1952
|
-
"eligibility-modal.title": "<highlighted>Betaal in termijnen</highlighted>
|
|
1957
|
+
"eligibility-modal.title": "<highlighted>Betaal in termijnen</highlighted> met kredietkaart bij Alma.",
|
|
1958
|
+
"eligibility-modal.title-deferred": "<highlighted>Betaal in termijnen</highlighted> of later per credit card met Alma.",
|
|
1953
1959
|
"eligibility-modal.total": "Totaal",
|
|
1954
1960
|
"installments.today": "Tegenwoordig",
|
|
1955
1961
|
"payment-plan-strings.day-abbreviation": "J{numberOfDeferredDays}",
|
|
@@ -2190,7 +2196,8 @@ var STATIC_CUSTOMISATION_CLASSES = {
|
|
|
2190
2196
|
closeButton: prefix + '-close-button',
|
|
2191
2197
|
scheduleDetails: prefix + '-schedule-details',
|
|
2192
2198
|
scheduleTotal: prefix + '-schedule-total',
|
|
2193
|
-
scheduleCredit: prefix + '-schedule-credit'
|
|
2199
|
+
scheduleCredit: prefix + '-schedule-credit',
|
|
2200
|
+
summary: prefix + '-summary'
|
|
2194
2201
|
};
|
|
2195
2202
|
|
|
2196
2203
|
var _excluded = ["children", "isOpen", "onClose", "className", "contentClassName", "scrollable"];
|
|
@@ -2388,7 +2395,7 @@ var EligibilityPlansButtons = function EligibilityPlansButtons(_ref) {
|
|
|
2388
2395
|
}));
|
|
2389
2396
|
};
|
|
2390
2397
|
|
|
2391
|
-
var s$3 = {"schedule":"_MPKjS","scheduleLine":"_1A7Qv","total":"_14Ejo","creditCost":"_1ZIgu","creditMessage":"_1BUr8"};
|
|
2398
|
+
var s$3 = {"schedule":"_MPKjS","scheduleLine":"_1A7Qv","total":"_14Ejo","summary":"_65ZpD","creditCost":"_1ZIgu","creditCostAmount":"_tUTZp","creditMessage":"_1BUr8"};
|
|
2392
2399
|
|
|
2393
2400
|
var Schedule = function Schedule(_ref) {
|
|
2394
2401
|
var currentPlan = _ref.currentPlan;
|
|
@@ -2398,9 +2405,29 @@ var Schedule = function Schedule(_ref) {
|
|
|
2398
2405
|
var customerFees = priceFromCents(currentPlan ? currentPlan.customer_total_cost_amount : 0);
|
|
2399
2406
|
var isCredit = currentPlan && currentPlan.installments_count > 4;
|
|
2400
2407
|
var intl = reactIntl.useIntl();
|
|
2401
|
-
return /*#__PURE__*/React__default.createElement("div", {
|
|
2408
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("div", {
|
|
2402
2409
|
className: cx(s$3.schedule, STATIC_CUSTOMISATION_CLASSES.scheduleDetails),
|
|
2403
2410
|
"data-testid": "modal-installments-element"
|
|
2411
|
+
}, ((currentPlan == null ? void 0 : currentPlan.payment_plan) || []).map(function (installment, index) {
|
|
2412
|
+
return /*#__PURE__*/React__default.createElement("div", {
|
|
2413
|
+
className: s$3.scheduleLine,
|
|
2414
|
+
key: index
|
|
2415
|
+
}, /*#__PURE__*/React__default.createElement("span", null, dateFns.isToday(installment.due_date * 1000) ? /*#__PURE__*/React__default.createElement(reactIntl.FormattedMessage, {
|
|
2416
|
+
id: "installments.today",
|
|
2417
|
+
defaultMessage: "Aujourd'hui"
|
|
2418
|
+
}) : /*#__PURE__*/React__default.createElement(reactIntl.FormattedDate, {
|
|
2419
|
+
value: installment.due_date * 1000,
|
|
2420
|
+
day: "numeric",
|
|
2421
|
+
month: "long",
|
|
2422
|
+
year: "numeric"
|
|
2423
|
+
})), /*#__PURE__*/React__default.createElement("span", null, /*#__PURE__*/React__default.createElement(reactIntl.FormattedNumber, {
|
|
2424
|
+
value: priceFromCents(installment.total_amount),
|
|
2425
|
+
style: "currency",
|
|
2426
|
+
currency: "EUR"
|
|
2427
|
+
})));
|
|
2428
|
+
})), /*#__PURE__*/React__default.createElement("div", {
|
|
2429
|
+
className: cx(s$3.summary, STATIC_CUSTOMISATION_CLASSES.summary),
|
|
2430
|
+
"data-testid": "modal-summary"
|
|
2404
2431
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
2405
2432
|
className: cx(s$3.scheduleLine, s$3.total, STATIC_CUSTOMISATION_CLASSES.scheduleTotal)
|
|
2406
2433
|
}, /*#__PURE__*/React__default.createElement("span", null, /*#__PURE__*/React__default.createElement(reactIntl.FormattedMessage, {
|
|
@@ -2418,7 +2445,9 @@ var Schedule = function Schedule(_ref) {
|
|
|
2418
2445
|
})) : /*#__PURE__*/React__default.createElement("span", null, /*#__PURE__*/React__default.createElement(reactIntl.FormattedMessage, {
|
|
2419
2446
|
id: "eligibility-modal.cost",
|
|
2420
2447
|
defaultMessage: "Dont frais"
|
|
2421
|
-
})), /*#__PURE__*/React__default.createElement("span",
|
|
2448
|
+
})), /*#__PURE__*/React__default.createElement("span", {
|
|
2449
|
+
className: s$3.creditCostAmount
|
|
2450
|
+
}, isCredit ? /*#__PURE__*/React__default.createElement(reactIntl.FormattedMessage, {
|
|
2422
2451
|
id: "eligibility-modal.credit-cost-amount",
|
|
2423
2452
|
defaultMessage: "{creditCost} (TAEG {TAEG})",
|
|
2424
2453
|
values: {
|
|
@@ -2435,29 +2464,12 @@ var Schedule = function Schedule(_ref) {
|
|
|
2435
2464
|
value: customerFees,
|
|
2436
2465
|
style: "currency",
|
|
2437
2466
|
currency: "EUR"
|
|
2438
|
-
}))),
|
|
2439
|
-
return /*#__PURE__*/React__default.createElement("div", {
|
|
2440
|
-
className: s$3.scheduleLine,
|
|
2441
|
-
key: index
|
|
2442
|
-
}, /*#__PURE__*/React__default.createElement("span", null, dateFns.isToday(installment.due_date * 1000) ? /*#__PURE__*/React__default.createElement(reactIntl.FormattedMessage, {
|
|
2443
|
-
id: "installments.today",
|
|
2444
|
-
defaultMessage: "Aujourd'hui"
|
|
2445
|
-
}) : /*#__PURE__*/React__default.createElement(reactIntl.FormattedDate, {
|
|
2446
|
-
value: installment.due_date * 1000,
|
|
2447
|
-
day: "numeric",
|
|
2448
|
-
month: "long",
|
|
2449
|
-
year: "numeric"
|
|
2450
|
-
})), /*#__PURE__*/React__default.createElement("span", null, /*#__PURE__*/React__default.createElement(reactIntl.FormattedNumber, {
|
|
2451
|
-
value: priceFromCents(installment.total_amount),
|
|
2452
|
-
style: "currency",
|
|
2453
|
-
currency: "EUR"
|
|
2454
|
-
})));
|
|
2455
|
-
}), isCredit && /*#__PURE__*/React__default.createElement("p", {
|
|
2467
|
+
}))), isCredit && /*#__PURE__*/React__default.createElement("p", {
|
|
2456
2468
|
className: s$3.creditMessage
|
|
2457
2469
|
}, /*#__PURE__*/React__default.createElement(reactIntl.FormattedMessage, {
|
|
2458
2470
|
id: "eligibility-modal.credit-commitment",
|
|
2459
2471
|
defaultMessage: "Un cr\xE9dit vous engage et doit \xEAtre rembours\xE9. V\xE9rifiez vos capacit\xE9s de remboursement\n avant de vous engager."
|
|
2460
|
-
})));
|
|
2472
|
+
}))));
|
|
2461
2473
|
};
|
|
2462
2474
|
|
|
2463
2475
|
var s$4 = {"list":"_180ro","listItem":"_1HqCO","bullet":"_3B8wx"};
|
|
@@ -2556,31 +2568,43 @@ var Logo = function Logo() {
|
|
|
2556
2568
|
|
|
2557
2569
|
var s$6 = {"title":"_3ERx-"};
|
|
2558
2570
|
|
|
2559
|
-
var Title = function Title() {
|
|
2571
|
+
var Title = function Title(_ref) {
|
|
2572
|
+
var isSomePlanDeferred = _ref.isSomePlanDeferred;
|
|
2560
2573
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
2561
2574
|
className: cx(s$6.title, STATIC_CUSTOMISATION_CLASSES.title),
|
|
2562
2575
|
"data-testid": "modal-title-element"
|
|
2563
|
-
}, /*#__PURE__*/React__default.createElement(reactIntl.FormattedMessage, {
|
|
2564
|
-
id:
|
|
2576
|
+
}, isSomePlanDeferred ? /*#__PURE__*/React__default.createElement(reactIntl.FormattedMessage, {
|
|
2577
|
+
id: 'eligibility-modal.title-deferred',
|
|
2565
2578
|
defaultMessage: "<highlighted>Payez en plusieurs fois</highlighted> ou plus tard par carte bancaire avec Alma.",
|
|
2566
2579
|
values: {
|
|
2567
2580
|
highlighted: function highlighted() {
|
|
2568
2581
|
return /*#__PURE__*/React__default.createElement("span", null, [].slice.call(arguments));
|
|
2569
2582
|
}
|
|
2570
2583
|
}
|
|
2584
|
+
}) : /*#__PURE__*/React__default.createElement(reactIntl.FormattedMessage, {
|
|
2585
|
+
id: 'eligibility-modal.title',
|
|
2586
|
+
defaultMessage: "<highlighted>Payez en plusieurs fois</highlighted> par carte bancaire avec Alma.",
|
|
2587
|
+
values: {
|
|
2588
|
+
highlighted: function highlighted() {
|
|
2589
|
+
return /*#__PURE__*/React__default.createElement("span", null, [].slice.call(arguments));
|
|
2590
|
+
}
|
|
2591
|
+
}
|
|
2571
2592
|
}));
|
|
2572
2593
|
};
|
|
2573
2594
|
|
|
2574
2595
|
var s$7 = {"container":"_21g6u","block":"_3zaP5","left":"_2SBRC"};
|
|
2575
2596
|
|
|
2576
2597
|
var DesktopModal = function DesktopModal(_ref) {
|
|
2577
|
-
var children = _ref.children
|
|
2598
|
+
var children = _ref.children,
|
|
2599
|
+
isSomePlanDeferred = _ref.isSomePlanDeferred;
|
|
2578
2600
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
2579
2601
|
className: s$7.container,
|
|
2580
2602
|
"data-testid": "modal-container"
|
|
2581
2603
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
2582
2604
|
className: cx([s$7.block, s$7.left, STATIC_CUSTOMISATION_CLASSES.leftSide])
|
|
2583
|
-
}, /*#__PURE__*/React__default.createElement(Title,
|
|
2605
|
+
}, /*#__PURE__*/React__default.createElement(Title, {
|
|
2606
|
+
isSomePlanDeferred: isSomePlanDeferred
|
|
2607
|
+
}), /*#__PURE__*/React__default.createElement(Info, null), /*#__PURE__*/React__default.createElement(Logo, null)), /*#__PURE__*/React__default.createElement("div", {
|
|
2584
2608
|
className: cx(s$7.block, STATIC_CUSTOMISATION_CLASSES.rightSide)
|
|
2585
2609
|
}, children));
|
|
2586
2610
|
};
|
|
@@ -2590,11 +2614,14 @@ var s$8 = {"noEligibility":"_17qNJ","loader":"_2oTJq"};
|
|
|
2590
2614
|
var s$9 = {"container":"_2G7Ch"};
|
|
2591
2615
|
|
|
2592
2616
|
var MobileModal = function MobileModal(_ref) {
|
|
2593
|
-
var children = _ref.children
|
|
2617
|
+
var children = _ref.children,
|
|
2618
|
+
isSomePlanDeferred = _ref.isSomePlanDeferred;
|
|
2594
2619
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
2595
2620
|
className: s$9.container,
|
|
2596
2621
|
"data-testid": "modal-container"
|
|
2597
|
-
}, /*#__PURE__*/React__default.createElement(Title,
|
|
2622
|
+
}, /*#__PURE__*/React__default.createElement(Title, {
|
|
2623
|
+
isSomePlanDeferred: isSomePlanDeferred
|
|
2624
|
+
}), children, /*#__PURE__*/React__default.createElement(Info, null), /*#__PURE__*/React__default.createElement(Logo, null));
|
|
2598
2625
|
};
|
|
2599
2626
|
|
|
2600
2627
|
var EligibilityModal = function EligibilityModal(_ref) {
|
|
@@ -2615,25 +2642,23 @@ var EligibilityModal = function EligibilityModal(_ref) {
|
|
|
2615
2642
|
return plan.eligible;
|
|
2616
2643
|
});
|
|
2617
2644
|
var currentPlan = eligiblePlans[currentPlanIndex];
|
|
2618
|
-
var
|
|
2619
|
-
|
|
2620
|
-
|
|
2621
|
-
setCurrentPlanIndex: setCurrentPlanIndex,
|
|
2622
|
-
currentPlan: currentPlan,
|
|
2623
|
-
status: status
|
|
2624
|
-
};
|
|
2645
|
+
var isSomePlanDeferred = eligibilityPlans.some(function (plan) {
|
|
2646
|
+
return plan.deferred_days > 0 || plan.deferred_months > 0;
|
|
2647
|
+
});
|
|
2625
2648
|
return /*#__PURE__*/React__default.createElement(ControlledModal, {
|
|
2626
2649
|
onClose: onClose,
|
|
2627
2650
|
ariaHideApp: false,
|
|
2628
2651
|
scrollable: true,
|
|
2629
2652
|
isOpen: true
|
|
2630
|
-
}, /*#__PURE__*/React__default.createElement(ModalComponent,
|
|
2653
|
+
}, /*#__PURE__*/React__default.createElement(ModalComponent, {
|
|
2654
|
+
isSomePlanDeferred: isSomePlanDeferred
|
|
2655
|
+
}, status === apiStatus.PENDING && /*#__PURE__*/React__default.createElement("div", {
|
|
2631
2656
|
className: s$8.loader
|
|
2632
2657
|
}, /*#__PURE__*/React__default.createElement(LoadingIndicator, null)), status === apiStatus.SUCCESS && eligiblePlans.length === 0 && /*#__PURE__*/React__default.createElement("div", {
|
|
2633
2658
|
className: s$8.noEligibility
|
|
2634
2659
|
}, /*#__PURE__*/React__default.createElement(reactIntl.FormattedMessage, {
|
|
2635
2660
|
id: "eligibility-modal.no-eligibility",
|
|
2636
|
-
defaultMessage: "Oups, il semblerait que la simulation n'
|
|
2661
|
+
defaultMessage: "Oups, il semblerait que la simulation n'ait pas fonctionn\xE9."
|
|
2637
2662
|
})), status === apiStatus.SUCCESS && eligiblePlans.length >= 1 && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(EligibilityPlansButtons, {
|
|
2638
2663
|
eligibilityPlans: eligiblePlans,
|
|
2639
2664
|
currentPlanIndex: currentPlanIndex,
|