rebill 1.17.7-beta.7 → 1.17.7-beta.9
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/cjs/card-fields-wrapper_16.cjs.entry.js +6 -19
- package/dist/cjs/index-CoibgVZr.js.map +1 -1
- package/dist/cjs/rebill-checkout.cjs.entry.js +13 -32
- package/dist/cjs/rebill-checkout.entry.cjs.js.map +1 -1
- package/dist/cjs/rebill-input-select.cjs.entry.js +5 -3
- package/dist/cjs/rebill-input-select.entry.cjs.js.map +1 -1
- package/dist/cjs/text-normalization-BBMfZ-xP.js +17 -0
- package/dist/cjs/text-normalization-BBMfZ-xP.js.map +1 -0
- package/dist/collection/components/checkout/address/address.js +4 -12
- package/dist/collection/components/checkout/address/address.js.map +1 -1
- package/dist/collection/components/checkout/payment-method-selector/card-fields/identification/identification.js +2 -7
- package/dist/collection/components/checkout/payment-method-selector/card-fields/identification/identification.js.map +1 -1
- package/dist/collection/components/checkout/rebill-checkout.js +13 -32
- package/dist/collection/components/checkout/rebill-checkout.js.map +1 -1
- package/dist/collection/components/shared/inputs/input-select/input-select.js +5 -3
- package/dist/collection/components/shared/inputs/input-select/input-select.js.map +1 -1
- package/dist/collection/utils/text-normalization.js +11 -0
- package/dist/collection/utils/text-normalization.js.map +1 -0
- package/dist/components/card-fields-wrapper.js +1 -1
- package/dist/components/card-identification.js +1 -1
- package/dist/components/change-card-success.js +1 -1
- package/dist/components/{p-K2xpUsfg.js → p-B12xzhzS.js} +5 -5
- package/dist/components/{p-K2xpUsfg.js.map → p-B12xzhzS.js.map} +1 -1
- package/dist/components/{p-BCTH9i47.js → p-B7CdUyxp.js} +3 -3
- package/dist/components/{p-BCTH9i47.js.map → p-B7CdUyxp.js.map} +1 -1
- package/dist/components/{p-CvYgpm98.js → p-BQ4aEOl4.js} +5 -5
- package/dist/components/{p-CvYgpm98.js.map → p-BQ4aEOl4.js.map} +1 -1
- package/dist/components/{p-CkCUDFcA.js → p-BRXQnqpQ.js} +5 -5
- package/dist/components/{p-CkCUDFcA.js.map → p-BRXQnqpQ.js.map} +1 -1
- package/dist/components/p-BjXn3y1C.js.map +1 -1
- package/dist/components/{p-CD9ntKAa.js → p-CGcGcqpB.js} +5 -5
- package/dist/components/{p-CD9ntKAa.js.map → p-CGcGcqpB.js.map} +1 -1
- package/dist/components/{p-DxRnpRk3.js → p-CGhHZWmk.js} +5 -5
- package/dist/components/{p-DxRnpRk3.js.map → p-CGhHZWmk.js.map} +1 -1
- package/dist/components/{p-BDNIA4Br.js → p-COPcpJcv.js} +7 -16
- package/dist/components/p-COPcpJcv.js.map +1 -0
- package/dist/components/{p-CE2SmDW9.js → p-ChqkWQCw.js} +3 -3
- package/dist/components/{p-CE2SmDW9.js.map → p-ChqkWQCw.js.map} +1 -1
- package/dist/components/{p-DaBfDulg.js → p-Cq-DTeKY.js} +4 -9
- package/dist/components/p-Cq-DTeKY.js.map +1 -0
- package/dist/components/{p-CzYvvpoX.js → p-D37GXC_v.js} +3 -3
- package/dist/components/{p-CzYvvpoX.js.map → p-D37GXC_v.js.map} +1 -1
- package/dist/components/{p-BteMjpYN.js → p-DKY_fuG0.js} +3 -3
- package/dist/components/{p-BteMjpYN.js.map → p-DKY_fuG0.js.map} +1 -1
- package/dist/components/{p-BzNYLKjo.js → p-DlJ3nT6S.js} +4 -4
- package/dist/components/{p-BzNYLKjo.js.map → p-DlJ3nT6S.js.map} +1 -1
- package/dist/components/{p-CBnRiclI.js → p-Dovhki0u.js} +6 -6
- package/dist/components/{p-CBnRiclI.js.map → p-Dovhki0u.js.map} +1 -1
- package/dist/components/{p-D_gLok7p.js → p-Jg8Wd5RR.js} +5 -5
- package/dist/components/{p-D_gLok7p.js.map → p-Jg8Wd5RR.js.map} +1 -1
- package/dist/components/{p-BBooWZrh.js → p-v1clBtRI.js} +18 -6
- package/dist/components/p-v1clBtRI.js.map +1 -0
- package/dist/components/payment-method-selector.js +1 -1
- package/dist/components/rebill-address-form.js +1 -1
- package/dist/components/rebill-address.js +1 -1
- package/dist/components/rebill-bank-selector.js +1 -1
- package/dist/components/rebill-change-card.js +11 -11
- package/dist/components/rebill-checkout-single-column.js +1 -1
- package/dist/components/rebill-checkout.js +25 -44
- package/dist/components/rebill-checkout.js.map +1 -1
- package/dist/components/rebill-footer.js +1 -1
- package/dist/components/rebill-input-select.js +1 -1
- package/dist/components/rebill-installments.js +1 -1
- package/dist/components/rebill-processing-payment.js +1 -1
- package/dist/components/rebill-renewal.js +12 -12
- package/dist/components/rebill-save-card.js +10 -10
- package/dist/components/renewal-success-page.js +1 -1
- package/dist/components/root-component.js +1 -1
- package/dist/components/save-card-success.js +1 -1
- package/dist/components/success-page.js +1 -1
- package/dist/esm/card-fields-wrapper_16.entry.js +6 -19
- package/dist/esm/index-UumHbCAL.js.map +1 -1
- package/dist/esm/rebill-checkout.entry.js +13 -32
- package/dist/esm/rebill-checkout.entry.js.map +1 -1
- package/dist/esm/rebill-input-select.entry.js +5 -3
- package/dist/esm/rebill-input-select.entry.js.map +1 -1
- package/dist/esm/text-normalization-DuqEnXBq.js +15 -0
- package/dist/esm/text-normalization-DuqEnXBq.js.map +1 -0
- package/dist/rebill/p-44b136e3.entry.js +2 -0
- package/dist/rebill/p-44b136e3.entry.js.map +1 -0
- package/dist/rebill/p-6f316861.entry.js +2 -0
- package/dist/rebill/p-6f316861.entry.js.map +1 -0
- package/dist/rebill/p-DuqEnXBq.js +2 -0
- package/dist/rebill/p-DuqEnXBq.js.map +1 -0
- package/dist/rebill/p-UumHbCAL.js.map +1 -1
- package/dist/rebill/p-d5daff31.entry.js +2 -0
- package/dist/rebill/p-d5daff31.entry.js.map +1 -0
- package/dist/rebill/rebill-checkout.entry.esm.js.map +1 -1
- package/dist/rebill/rebill-input-select.entry.esm.js.map +1 -1
- package/dist/rebill/rebill.esm.js +1 -1
- package/dist/types/components/checkout/address/address.d.ts +0 -1
- package/dist/types/components/checkout/payment-method-selector/card-fields/identification/identification.d.ts +0 -1
- package/dist/types/components/checkout/rebill-checkout.d.ts +0 -1
- package/dist/types/utils/text-normalization.d.ts +1 -0
- package/package.json +1 -1
- package/dist/components/p-BBooWZrh.js.map +0 -1
- package/dist/components/p-BDNIA4Br.js.map +0 -1
- package/dist/components/p-DaBfDulg.js.map +0 -1
- package/dist/rebill/p-32d1bc20.entry.js +0 -2
- package/dist/rebill/p-32d1bc20.entry.js.map +0 -1
- package/dist/rebill/p-5ae19116.entry.js +0 -2
- package/dist/rebill/p-5ae19116.entry.js.map +0 -1
- package/dist/rebill/p-9ee87282.entry.js +0 -2
- package/dist/rebill/p-9ee87282.entry.js.map +0 -1
|
@@ -10,6 +10,7 @@ var assets = require('./assets-D26S_L0v.js');
|
|
|
10
10
|
var getPaymentMethodDisplayName = require('./get-payment-method-display-name-Bs46JA8z.js');
|
|
11
11
|
var timer = require('./timer-YTImGFi7.js');
|
|
12
12
|
var colorClassMapper = require('./color-class-mapper-Cviu2q1o.js');
|
|
13
|
+
var textNormalization = require('./text-normalization-BBMfZ-xP.js');
|
|
13
14
|
var index_esm = require('./index.esm-4vgDEvoy.js');
|
|
14
15
|
var installmentUtils = require('./installment-utils-BTvLSbRc.js');
|
|
15
16
|
require('./_commonjsHelpers-B83fTs8d.js');
|
|
@@ -418,15 +419,6 @@ const Address = class {
|
|
|
418
419
|
this.unsubscribeSaveCardStore();
|
|
419
420
|
}
|
|
420
421
|
}
|
|
421
|
-
normalizeText(text) {
|
|
422
|
-
return text
|
|
423
|
-
.toLowerCase()
|
|
424
|
-
.normalize('NFD')
|
|
425
|
-
.replace(/[\u0300-\u036f]/g, '') // Remove accents
|
|
426
|
-
.replace(/\./g, '') // Remove dots
|
|
427
|
-
.replace(/\s+/g, ' ') // Normalize spaces
|
|
428
|
-
.trim();
|
|
429
|
-
}
|
|
430
422
|
resolveStateOption(stateValue) {
|
|
431
423
|
if (!stateValue || this.currentBillingStateOptions.length === 0)
|
|
432
424
|
return stateValue;
|
|
@@ -435,12 +427,12 @@ const Address = class {
|
|
|
435
427
|
return exactMatch.value;
|
|
436
428
|
const partialMatch = this.currentBillingStateOptions.find(option => option.value.toLowerCase().includes(stateValue.toLowerCase()) ||
|
|
437
429
|
stateValue.toLowerCase().includes(option.value.toLowerCase()));
|
|
438
|
-
const normalizedInput =
|
|
430
|
+
const normalizedInput = textNormalization.normalizeText(stateValue)
|
|
439
431
|
.replace('ciudad de ', '')
|
|
440
432
|
.replace('estado de ', '')
|
|
441
433
|
.replace('provincia de ', '');
|
|
442
434
|
const normalizedMatch = this.currentBillingStateOptions.find(option => {
|
|
443
|
-
const normalizedOption =
|
|
435
|
+
const normalizedOption = textNormalization.normalizeText(option.value)
|
|
444
436
|
.replace('ciudad de ', '')
|
|
445
437
|
.replace('estado de ', '')
|
|
446
438
|
.replace('provincia de ', '');
|
|
@@ -604,7 +596,7 @@ const Address = class {
|
|
|
604
596
|
})() }))));
|
|
605
597
|
}
|
|
606
598
|
render() {
|
|
607
|
-
return (index.h("div", { key: '
|
|
599
|
+
return (index.h("div", { key: '3bcabaabd1ae98ce8eef79769698743b591688a0' }, this.renderAddressForm()));
|
|
608
600
|
}
|
|
609
601
|
};
|
|
610
602
|
Address.style = addressCss;
|
|
@@ -841,16 +833,14 @@ const Identification = class {
|
|
|
841
833
|
documentTypeError = '';
|
|
842
834
|
documentNumberError = '';
|
|
843
835
|
disabled = false;
|
|
844
|
-
isLoadingDocumentTypes = false;
|
|
845
836
|
loadDocumentTypes = async () => {
|
|
846
837
|
const currentCountry = renewal_store.renewalState.isInitialized
|
|
847
838
|
? renewal_store.renewalState.data?.price?.country
|
|
848
839
|
: saveCard_store.saveCardState.country
|
|
849
840
|
? saveCard_store.saveCardState.country
|
|
850
841
|
: i18n_service.state?.data?.pricing?.country;
|
|
851
|
-
if (currentCountry && currentCountry !== this.country
|
|
842
|
+
if (currentCountry && currentCountry !== this.country) {
|
|
852
843
|
try {
|
|
853
|
-
this.isLoadingDocumentTypes = true;
|
|
854
844
|
const response = await index$1.api.data.getDocumentTypes(currentCountry);
|
|
855
845
|
this.documentTypes = response.data;
|
|
856
846
|
this.country = currentCountry;
|
|
@@ -858,9 +848,6 @@ const Identification = class {
|
|
|
858
848
|
catch (error) {
|
|
859
849
|
console.error('Error loading document types:', error);
|
|
860
850
|
}
|
|
861
|
-
finally {
|
|
862
|
-
this.isLoadingDocumentTypes = false;
|
|
863
|
-
}
|
|
864
851
|
}
|
|
865
852
|
};
|
|
866
853
|
async componentWillLoad() {
|
|
@@ -899,7 +886,7 @@ const Identification = class {
|
|
|
899
886
|
label: documentType.value,
|
|
900
887
|
value: documentType.value,
|
|
901
888
|
}));
|
|
902
|
-
return (index.h(index.h.Fragment, null, index.h("rebill-input-combo", { key: '
|
|
889
|
+
return (index.h(index.h.Fragment, null, index.h("rebill-input-combo", { key: 'c7083435dfb3407d655ddf03fe85bb19898f5e32', "select-id": "documentType", "input-id": "documentNumber", "on-input": this.handleInputChange, "select-placeholder": i18n_service.I18nService.translate('document.typePlaceholder'), "input-placeholder": i18n_service.I18nService.translate('document.numberPlaceholder'), error: i18n_service.I18nService.translate(error), options: options, disabled: this.disabled })));
|
|
903
890
|
}
|
|
904
891
|
};
|
|
905
892
|
|