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.
Files changed (104) hide show
  1. package/dist/cjs/card-fields-wrapper_16.cjs.entry.js +6 -19
  2. package/dist/cjs/index-CoibgVZr.js.map +1 -1
  3. package/dist/cjs/rebill-checkout.cjs.entry.js +13 -32
  4. package/dist/cjs/rebill-checkout.entry.cjs.js.map +1 -1
  5. package/dist/cjs/rebill-input-select.cjs.entry.js +5 -3
  6. package/dist/cjs/rebill-input-select.entry.cjs.js.map +1 -1
  7. package/dist/cjs/text-normalization-BBMfZ-xP.js +17 -0
  8. package/dist/cjs/text-normalization-BBMfZ-xP.js.map +1 -0
  9. package/dist/collection/components/checkout/address/address.js +4 -12
  10. package/dist/collection/components/checkout/address/address.js.map +1 -1
  11. package/dist/collection/components/checkout/payment-method-selector/card-fields/identification/identification.js +2 -7
  12. package/dist/collection/components/checkout/payment-method-selector/card-fields/identification/identification.js.map +1 -1
  13. package/dist/collection/components/checkout/rebill-checkout.js +13 -32
  14. package/dist/collection/components/checkout/rebill-checkout.js.map +1 -1
  15. package/dist/collection/components/shared/inputs/input-select/input-select.js +5 -3
  16. package/dist/collection/components/shared/inputs/input-select/input-select.js.map +1 -1
  17. package/dist/collection/utils/text-normalization.js +11 -0
  18. package/dist/collection/utils/text-normalization.js.map +1 -0
  19. package/dist/components/card-fields-wrapper.js +1 -1
  20. package/dist/components/card-identification.js +1 -1
  21. package/dist/components/change-card-success.js +1 -1
  22. package/dist/components/{p-K2xpUsfg.js → p-B12xzhzS.js} +5 -5
  23. package/dist/components/{p-K2xpUsfg.js.map → p-B12xzhzS.js.map} +1 -1
  24. package/dist/components/{p-BCTH9i47.js → p-B7CdUyxp.js} +3 -3
  25. package/dist/components/{p-BCTH9i47.js.map → p-B7CdUyxp.js.map} +1 -1
  26. package/dist/components/{p-CvYgpm98.js → p-BQ4aEOl4.js} +5 -5
  27. package/dist/components/{p-CvYgpm98.js.map → p-BQ4aEOl4.js.map} +1 -1
  28. package/dist/components/{p-CkCUDFcA.js → p-BRXQnqpQ.js} +5 -5
  29. package/dist/components/{p-CkCUDFcA.js.map → p-BRXQnqpQ.js.map} +1 -1
  30. package/dist/components/p-BjXn3y1C.js.map +1 -1
  31. package/dist/components/{p-CD9ntKAa.js → p-CGcGcqpB.js} +5 -5
  32. package/dist/components/{p-CD9ntKAa.js.map → p-CGcGcqpB.js.map} +1 -1
  33. package/dist/components/{p-DxRnpRk3.js → p-CGhHZWmk.js} +5 -5
  34. package/dist/components/{p-DxRnpRk3.js.map → p-CGhHZWmk.js.map} +1 -1
  35. package/dist/components/{p-BDNIA4Br.js → p-COPcpJcv.js} +7 -16
  36. package/dist/components/p-COPcpJcv.js.map +1 -0
  37. package/dist/components/{p-CE2SmDW9.js → p-ChqkWQCw.js} +3 -3
  38. package/dist/components/{p-CE2SmDW9.js.map → p-ChqkWQCw.js.map} +1 -1
  39. package/dist/components/{p-DaBfDulg.js → p-Cq-DTeKY.js} +4 -9
  40. package/dist/components/p-Cq-DTeKY.js.map +1 -0
  41. package/dist/components/{p-CzYvvpoX.js → p-D37GXC_v.js} +3 -3
  42. package/dist/components/{p-CzYvvpoX.js.map → p-D37GXC_v.js.map} +1 -1
  43. package/dist/components/{p-BteMjpYN.js → p-DKY_fuG0.js} +3 -3
  44. package/dist/components/{p-BteMjpYN.js.map → p-DKY_fuG0.js.map} +1 -1
  45. package/dist/components/{p-BzNYLKjo.js → p-DlJ3nT6S.js} +4 -4
  46. package/dist/components/{p-BzNYLKjo.js.map → p-DlJ3nT6S.js.map} +1 -1
  47. package/dist/components/{p-CBnRiclI.js → p-Dovhki0u.js} +6 -6
  48. package/dist/components/{p-CBnRiclI.js.map → p-Dovhki0u.js.map} +1 -1
  49. package/dist/components/{p-D_gLok7p.js → p-Jg8Wd5RR.js} +5 -5
  50. package/dist/components/{p-D_gLok7p.js.map → p-Jg8Wd5RR.js.map} +1 -1
  51. package/dist/components/{p-BBooWZrh.js → p-v1clBtRI.js} +18 -6
  52. package/dist/components/p-v1clBtRI.js.map +1 -0
  53. package/dist/components/payment-method-selector.js +1 -1
  54. package/dist/components/rebill-address-form.js +1 -1
  55. package/dist/components/rebill-address.js +1 -1
  56. package/dist/components/rebill-bank-selector.js +1 -1
  57. package/dist/components/rebill-change-card.js +11 -11
  58. package/dist/components/rebill-checkout-single-column.js +1 -1
  59. package/dist/components/rebill-checkout.js +25 -44
  60. package/dist/components/rebill-checkout.js.map +1 -1
  61. package/dist/components/rebill-footer.js +1 -1
  62. package/dist/components/rebill-input-select.js +1 -1
  63. package/dist/components/rebill-installments.js +1 -1
  64. package/dist/components/rebill-processing-payment.js +1 -1
  65. package/dist/components/rebill-renewal.js +12 -12
  66. package/dist/components/rebill-save-card.js +10 -10
  67. package/dist/components/renewal-success-page.js +1 -1
  68. package/dist/components/root-component.js +1 -1
  69. package/dist/components/save-card-success.js +1 -1
  70. package/dist/components/success-page.js +1 -1
  71. package/dist/esm/card-fields-wrapper_16.entry.js +6 -19
  72. package/dist/esm/index-UumHbCAL.js.map +1 -1
  73. package/dist/esm/rebill-checkout.entry.js +13 -32
  74. package/dist/esm/rebill-checkout.entry.js.map +1 -1
  75. package/dist/esm/rebill-input-select.entry.js +5 -3
  76. package/dist/esm/rebill-input-select.entry.js.map +1 -1
  77. package/dist/esm/text-normalization-DuqEnXBq.js +15 -0
  78. package/dist/esm/text-normalization-DuqEnXBq.js.map +1 -0
  79. package/dist/rebill/p-44b136e3.entry.js +2 -0
  80. package/dist/rebill/p-44b136e3.entry.js.map +1 -0
  81. package/dist/rebill/p-6f316861.entry.js +2 -0
  82. package/dist/rebill/p-6f316861.entry.js.map +1 -0
  83. package/dist/rebill/p-DuqEnXBq.js +2 -0
  84. package/dist/rebill/p-DuqEnXBq.js.map +1 -0
  85. package/dist/rebill/p-UumHbCAL.js.map +1 -1
  86. package/dist/rebill/p-d5daff31.entry.js +2 -0
  87. package/dist/rebill/p-d5daff31.entry.js.map +1 -0
  88. package/dist/rebill/rebill-checkout.entry.esm.js.map +1 -1
  89. package/dist/rebill/rebill-input-select.entry.esm.js.map +1 -1
  90. package/dist/rebill/rebill.esm.js +1 -1
  91. package/dist/types/components/checkout/address/address.d.ts +0 -1
  92. package/dist/types/components/checkout/payment-method-selector/card-fields/identification/identification.d.ts +0 -1
  93. package/dist/types/components/checkout/rebill-checkout.d.ts +0 -1
  94. package/dist/types/utils/text-normalization.d.ts +1 -0
  95. package/package.json +1 -1
  96. package/dist/components/p-BBooWZrh.js.map +0 -1
  97. package/dist/components/p-BDNIA4Br.js.map +0 -1
  98. package/dist/components/p-DaBfDulg.js.map +0 -1
  99. package/dist/rebill/p-32d1bc20.entry.js +0 -2
  100. package/dist/rebill/p-32d1bc20.entry.js.map +0 -1
  101. package/dist/rebill/p-5ae19116.entry.js +0 -2
  102. package/dist/rebill/p-5ae19116.entry.js.map +0 -1
  103. package/dist/rebill/p-9ee87282.entry.js +0 -2
  104. 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 = this.normalizeText(stateValue)
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 = this.normalizeText(option.value)
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: 'c82599415b03a6135dc9121a0c6f058ccc9111c8' }, this.renderAddressForm()));
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 && !this.isLoadingDocumentTypes) {
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: 'f0e42a91b3f7b3867efae3f352706736f20ac0b5', "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 })));
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