stripe-pwa-elements 4.0.1 → 4.0.2

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 (100) hide show
  1. package/dist/cjs/factory-tenFFIul.js +1200 -0
  2. package/dist/cjs/{factory-Cd2VI_N2.js → i18n-FhEOc8vz.js} +6 -1149
  3. package/dist/cjs/ion-icon_2.cjs.entry.js +723 -0
  4. package/dist/cjs/loader.cjs.js +1 -1
  5. package/dist/cjs/stripe-address-element.cjs.entry.js +5 -4
  6. package/dist/cjs/stripe-card-element-modal.cjs.entry.js +3 -2
  7. package/dist/cjs/{stripe-card-element_2.cjs.entry.js → stripe-card-element.cjs.entry.js} +8 -93
  8. package/dist/cjs/stripe-currency-selector.cjs.entry.js +4 -3
  9. package/dist/cjs/stripe-elements.cjs.js +1 -1
  10. package/dist/cjs/stripe-express-checkout-element.cjs.entry.js +24 -5
  11. package/dist/cjs/stripe-link-authentication-element.cjs.entry.js +4 -3
  12. package/dist/cjs/stripe-payment-element.cjs.entry.js +12 -124
  13. package/dist/cjs/stripe-payment-element.helpers-DukP33RI.js +122 -0
  14. package/dist/cjs/stripe-payment-request-button.cjs.entry.js +2 -2
  15. package/dist/cjs/stripe-payment-sheet.cjs.entry.js +506 -0
  16. package/dist/collection/collection-manifest.json +2 -1
  17. package/dist/collection/components/stripe-card-element/stripe-card-element.js +3 -2
  18. package/dist/collection/components/stripe-card-element-modal/stripe-card-element-modal.js +4 -3
  19. package/dist/collection/components/stripe-express-checkout-element/stripe-express-checkout-element.js +18 -0
  20. package/dist/collection/components/stripe-modal/stripe-modal.css +23 -1
  21. package/dist/collection/components/stripe-modal/stripe-modal.js +130 -1
  22. package/dist/collection/components/stripe-payment-request-button/stripe-payment-request-button.js +3 -3
  23. package/dist/collection/components/stripe-payment-sheet/payment-sheet-state.js +179 -0
  24. package/dist/collection/components/stripe-payment-sheet/stripe-payment-sheet.css +68 -0
  25. package/dist/collection/components/stripe-payment-sheet/stripe-payment-sheet.helpers.js +90 -0
  26. package/dist/collection/components/stripe-payment-sheet/stripe-payment-sheet.js +544 -0
  27. package/dist/collection/services/express-checkout-element-manager.js +36 -2
  28. package/dist/collection/services/stripe-service.js +20 -6
  29. package/dist/collection/utils/focus.js +76 -0
  30. package/dist/collection/utils/i18n.js +6 -0
  31. package/dist/components/factory.js +1 -1
  32. package/dist/components/i18n.js +1 -0
  33. package/dist/components/stripe-address-element.js +1 -1
  34. package/dist/components/stripe-card-element-modal.js +1 -1
  35. package/dist/components/stripe-card-element2.js +1 -1
  36. package/dist/components/stripe-currency-selector.js +1 -1
  37. package/dist/components/stripe-express-checkout-element.js +1 -1
  38. package/dist/components/stripe-link-authentication-element.js +1 -1
  39. package/dist/components/stripe-modal2.js +1 -1
  40. package/dist/components/stripe-payment-element.helpers.js +1 -0
  41. package/dist/components/stripe-payment-element.js +1 -1
  42. package/dist/components/stripe-payment-request-button2.js +1 -1
  43. package/dist/components/stripe-payment-sheet.d.ts +11 -0
  44. package/dist/components/stripe-payment-sheet.js +1 -0
  45. package/dist/esm/factory-Cd6OGTWN.js +1198 -0
  46. package/dist/esm/{factory-VTa1Gc94.js → i18n-B6JoQetF.js} +7 -1149
  47. package/dist/esm/ion-icon_2.entry.js +720 -0
  48. package/dist/esm/loader.js +1 -1
  49. package/dist/esm/stripe-address-element.entry.js +2 -1
  50. package/dist/esm/stripe-card-element-modal.entry.js +3 -2
  51. package/dist/esm/{stripe-card-element_2.entry.js → stripe-card-element.entry.js} +6 -90
  52. package/dist/esm/stripe-currency-selector.entry.js +2 -1
  53. package/dist/esm/stripe-elements.js +1 -1
  54. package/dist/esm/stripe-express-checkout-element.entry.js +20 -1
  55. package/dist/esm/stripe-link-authentication-element.entry.js +2 -1
  56. package/dist/esm/stripe-payment-element.entry.js +4 -116
  57. package/dist/esm/stripe-payment-element.helpers-CipV87b8.js +117 -0
  58. package/dist/esm/stripe-payment-request-button.entry.js +2 -2
  59. package/dist/esm/stripe-payment-sheet.entry.js +504 -0
  60. package/dist/stripe-elements/{p-ae0c336e.entry.js → p-4891edf0.entry.js} +1 -1
  61. package/dist/stripe-elements/p-5338bc5e.entry.js +1 -0
  62. package/dist/stripe-elements/p-6a9c8b7a.entry.js +1 -0
  63. package/dist/stripe-elements/p-7fe4a287.entry.js +1 -0
  64. package/dist/stripe-elements/p-915b86ed.entry.js +1 -0
  65. package/dist/stripe-elements/p-B6JoQetF.js +1 -0
  66. package/dist/stripe-elements/p-C7MQk9FK.js +1 -0
  67. package/dist/stripe-elements/p-DFAhQS0n.js +1 -0
  68. package/dist/stripe-elements/p-b06a254f.entry.js +1 -0
  69. package/dist/stripe-elements/p-b91c4fa7.entry.js +1 -0
  70. package/dist/stripe-elements/p-ba791c8f.entry.js +1 -0
  71. package/dist/stripe-elements/p-e7372ca7.entry.js +1 -0
  72. package/dist/stripe-elements/p-f892e375.entry.js +1 -0
  73. package/dist/stripe-elements/stripe-elements.esm.js +1 -1
  74. package/dist/types/components/stripe-card-element/stripe-card-element.d.ts +2 -1
  75. package/dist/types/components/stripe-card-element-modal/stripe-card-element-modal.d.ts +2 -1
  76. package/dist/types/components/stripe-express-checkout-element/stripe-express-checkout-element.d.ts +5 -0
  77. package/dist/types/components/stripe-modal/stripe-modal.d.ts +43 -0
  78. package/dist/types/components/stripe-payment-request-button/stripe-payment-request-button.d.ts +1 -1
  79. package/dist/types/components/stripe-payment-sheet/payment-sheet-state.d.ts +104 -0
  80. package/dist/types/components/stripe-payment-sheet/stripe-payment-sheet.d.ts +112 -0
  81. package/dist/types/components/stripe-payment-sheet/stripe-payment-sheet.helpers.d.ts +95 -0
  82. package/dist/types/components.d.ts +169 -10
  83. package/dist/types/index.d.ts +2 -0
  84. package/dist/types/services/interfaces.d.ts +1 -0
  85. package/dist/types/services/stripe-service.d.ts +7 -2
  86. package/dist/types/utils/focus.d.ts +15 -0
  87. package/package.json +5 -3
  88. package/readme.md +42 -6
  89. package/dist/cjs/ion-icon.cjs.entry.js +0 -431
  90. package/dist/components/utils.js +0 -1
  91. package/dist/esm/ion-icon.entry.js +0 -429
  92. package/dist/stripe-elements/p-1bd46766.entry.js +0 -1
  93. package/dist/stripe-elements/p-1c6e0a45.entry.js +0 -1
  94. package/dist/stripe-elements/p-3f42ca0c.entry.js +0 -1
  95. package/dist/stripe-elements/p-5cf62945.entry.js +0 -1
  96. package/dist/stripe-elements/p-74de1556.entry.js +0 -1
  97. package/dist/stripe-elements/p-76e57d78.entry.js +0 -1
  98. package/dist/stripe-elements/p-840d499f.entry.js +0 -1
  99. package/dist/stripe-elements/p-CrjrbGJ3.js +0 -1
  100. package/dist/stripe-elements/p-cfd8e081.entry.js +0 -1
@@ -6,7 +6,7 @@ var appGlobals = require('./app-globals-V2Kpy_OQ.js');
6
6
  const defineCustomElements = async (win, options) => {
7
7
  if (typeof window === 'undefined') return undefined;
8
8
  await appGlobals.globalScripts();
9
- return index.bootstrapLazy([["stripe-card-element-modal.cjs",[[0,"stripe-card-element-modal",{"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"showLabel":[4,"show-label"],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"intentClientSecret":[1,"intent-client-secret"],"shouldUseDefaultFormSubmitAction":[4,"should-use-default-form-submit-action"],"intentType":[1,"intent-type"],"handleSubmit":[1040],"stripeDidLoaded":[1040],"showCloseButton":[4,"show-close-button"],"zip":[4],"open":[4],"getStripeCardElementElement":[64],"present":[64],"updateProgress":[64],"destroy":[64],"setPaymentRequestButton":[64]}]]],["stripe-address-element.cjs",[[0,"stripe-address-element",{"mode":[1],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"showLabel":[4,"show-label"],"defaultCountry":[1,"default-country"],"allowedCountries":[16],"handleSubmit":[1040],"stripeDidLoaded":[1040],"progress":[32],"initStripe":[64],"updateProgress":[64],"setErrorMessage":[64],"getValue":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-currency-selector.cjs",[[0,"stripe-currency-selector",{"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"clientSecret":[1,"client-secret"],"handleCurrencyChange":[1040],"stripeDidLoaded":[1040],"initStripe":[64],"setErrorMessage":[64],"getSelectedCurrency":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-express-checkout-element.cjs",[[0,"stripe-express-checkout-element",{"intentType":[1,"intent-type"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"clientSecret":[1,"client-secret"],"amount":[2],"currency":[1],"buttonHeight":[1,"button-height"],"shouldUseDefaultConfirmAction":[4,"should-use-default-confirm-action"],"stripeDidLoaded":[1040],"progress":[32],"updateProgress":[64],"setErrorMessage":[64],"initStripe":[64],"updateElementOptions":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-link-authentication-element.cjs",[[0,"stripe-link-authentication-element",{"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"defaultEmail":[1,"default-email"],"handleChange":[1040],"stripeDidLoaded":[1040],"progress":[32],"initStripe":[64],"updateProgress":[64],"setErrorMessage":[64],"getEmail":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-payment-element.cjs",[[0,"stripe-payment-element",{"intentType":[1,"intent-type"],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"intentClientSecret":[1,"intent-client-secret"],"checkoutSessionClientSecret":[1,"checkout-session-client-secret"],"shouldUseDefaultFormSubmitAction":[4,"should-use-default-form-submit-action"],"handleSubmit":[1040],"stripeDidLoaded":[1040],"progress":[32],"initStripe":[64],"initStripeWithCheckoutSession":[64],"updateProgress":[64],"setErrorMessage":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}],"intentClientSecret":[{"updateIntentClientSecret":0}],"checkoutSessionClientSecret":[{"updateCheckoutSessionClientSecret":0}]}]]],["ion-icon.cjs",[[1,"ion-icon",{"mode":[1025],"color":[1],"ios":[1],"md":[1],"flipRtl":[4,"flip-rtl"],"name":[513],"src":[1],"icon":[8],"size":[1],"lazy":[4],"sanitize":[4],"svgContent":[32],"isVisible":[32]},null,{"name":[{"loadIcon":0}],"src":[{"loadIcon":0}],"icon":[{"loadIcon":0}],"ios":[{"loadIcon":0}],"md":[{"loadIcon":0}]}]]],["stripe-payment-request-button.cjs",[[260,"stripe-payment-request-button",{"paymentMethodEventHandler":[16],"shippingOptionEventHandler":[16],"shippingAddressEventHandler":[16],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"stripeDidLoaded":[1040],"loadStripeStatus":[32],"stripe":[32],"paymentRequestOption":[32],"isAvailable":[64],"setPaymentMethodEventHandler":[64],"setPaymentRequestShippingOptionEventHandler":[64],"setPaymentRequestShippingAddressEventHandler":[64],"setPaymentRequestOption":[64],"initStripe":[64]}]]],["stripe-card-element_2.cjs",[[0,"stripe-card-element",{"intentType":[1,"intent-type"],"zip":[4],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"showLabel":[4,"show-label"],"intentClientSecret":[1,"intent-client-secret"],"shouldUseDefaultFormSubmitAction":[4,"should-use-default-form-submit-action"],"showPaymentRequestButton":[4,"show-payment-request-button"],"handleSubmit":[1040],"stripeDidLoaded":[1040],"progress":[32],"zipCode":[32],"paymentRequestOption":[32],"initStripe":[64],"updateProgress":[64],"setErrorMessage":[64],"setPaymentRequestOption":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}],[257,"stripe-modal",{"showCloseButton":[4,"show-close-button"],"open":[1028],"renderedOpen":[32],"toggleModal":[64],"openModal":[64],"closeModal":[64]},null,{"open":[{"onOpenChange":0}]}]]]], options);
9
+ return index.bootstrapLazy([["stripe-card-element-modal.cjs",[[0,"stripe-card-element-modal",{"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"showLabel":[4,"show-label"],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"intentClientSecret":[1,"intent-client-secret"],"shouldUseDefaultFormSubmitAction":[4,"should-use-default-form-submit-action"],"intentType":[1,"intent-type"],"handleSubmit":[1040],"stripeDidLoaded":[1040],"showCloseButton":[4,"show-close-button"],"zip":[4],"open":[4],"getStripeCardElementElement":[64],"present":[64],"updateProgress":[64],"destroy":[64],"setPaymentRequestButton":[64]}]]],["stripe-payment-sheet.cjs",[[0,"stripe-payment-sheet",{"publishableKey":[1,"publishable-key"],"intentClientSecret":[1,"intent-client-secret"],"stripeAccount":[1,"stripe-account"],"open":[1540],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"applicationName":[1,"application-name"],"options":[16],"sheet":[32],"visible":[32],"errorMessage":[32],"present":[64]},null,{"publishableKey":[{"handleSecretChange":0}],"intentClientSecret":[{"handleSecretChange":0}],"stripeAccount":[{"handleSecretChange":0}],"open":[{"handleOpenChange":0}]}]]],["stripe-address-element.cjs",[[0,"stripe-address-element",{"mode":[1],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"showLabel":[4,"show-label"],"defaultCountry":[1,"default-country"],"allowedCountries":[16],"handleSubmit":[1040],"stripeDidLoaded":[1040],"progress":[32],"initStripe":[64],"updateProgress":[64],"setErrorMessage":[64],"getValue":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-currency-selector.cjs",[[0,"stripe-currency-selector",{"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"clientSecret":[1,"client-secret"],"handleCurrencyChange":[1040],"stripeDidLoaded":[1040],"initStripe":[64],"setErrorMessage":[64],"getSelectedCurrency":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-express-checkout-element.cjs",[[0,"stripe-express-checkout-element",{"intentType":[1,"intent-type"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"clientSecret":[1,"client-secret"],"amount":[2],"currency":[1],"buttonHeight":[1,"button-height"],"shouldUseDefaultConfirmAction":[4,"should-use-default-confirm-action"],"stripeDidLoaded":[1040],"progress":[32],"updateProgress":[64],"setErrorMessage":[64],"initStripe":[64],"updateElementOptions":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-link-authentication-element.cjs",[[0,"stripe-link-authentication-element",{"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"defaultEmail":[1,"default-email"],"handleChange":[1040],"stripeDidLoaded":[1040],"progress":[32],"initStripe":[64],"updateProgress":[64],"setErrorMessage":[64],"getEmail":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-payment-element.cjs",[[0,"stripe-payment-element",{"intentType":[1,"intent-type"],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"intentClientSecret":[1,"intent-client-secret"],"checkoutSessionClientSecret":[1,"checkout-session-client-secret"],"shouldUseDefaultFormSubmitAction":[4,"should-use-default-form-submit-action"],"handleSubmit":[1040],"stripeDidLoaded":[1040],"progress":[32],"initStripe":[64],"initStripeWithCheckoutSession":[64],"updateProgress":[64],"setErrorMessage":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}],"intentClientSecret":[{"updateIntentClientSecret":0}],"checkoutSessionClientSecret":[{"updateCheckoutSessionClientSecret":0}]}]]],["stripe-payment-request-button.cjs",[[260,"stripe-payment-request-button",{"paymentMethodEventHandler":[16],"shippingOptionEventHandler":[16],"shippingAddressEventHandler":[16],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"stripeDidLoaded":[1040],"loadStripeStatus":[32],"stripe":[32],"paymentRequestOption":[32],"isAvailable":[64],"setPaymentMethodEventHandler":[64],"setPaymentRequestShippingOptionEventHandler":[64],"setPaymentRequestShippingAddressEventHandler":[64],"setPaymentRequestOption":[64],"initStripe":[64]}]]],["stripe-card-element.cjs",[[0,"stripe-card-element",{"intentType":[1,"intent-type"],"zip":[4],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"showLabel":[4,"show-label"],"intentClientSecret":[1,"intent-client-secret"],"shouldUseDefaultFormSubmitAction":[4,"should-use-default-form-submit-action"],"showPaymentRequestButton":[4,"show-payment-request-button"],"handleSubmit":[1040],"stripeDidLoaded":[1040],"progress":[32],"zipCode":[32],"paymentRequestOption":[32],"initStripe":[64],"updateProgress":[64],"setErrorMessage":[64],"setPaymentRequestOption":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["ion-icon_2.cjs",[[257,"stripe-modal",{"showCloseButton":[4,"show-close-button"],"open":[1028],"renderedOpen":[32],"toggleModal":[64],"openModal":[64],"closeModal":[64]},null,{"open":[{"onOpenChange":0}]}],[1,"ion-icon",{"mode":[1025],"color":[1],"ios":[1],"md":[1],"flipRtl":[4,"flip-rtl"],"name":[513],"src":[1],"icon":[8],"size":[1],"lazy":[4],"sanitize":[4],"svgContent":[32],"isVisible":[32]},null,{"name":[{"loadIcon":0}],"src":[{"loadIcon":0}],"icon":[{"loadIcon":0}],"ios":[{"loadIcon":0}],"md":[{"loadIcon":0}]}]]]], options);
10
10
  };
11
11
 
12
12
  exports.setNonce = index.setNonce;
@@ -1,7 +1,8 @@
1
1
  'use strict';
2
2
 
3
3
  var index = require('./index-Dkb0SxZc.js');
4
- var factory = require('./factory-Cd2VI_N2.js');
4
+ var i18n = require('./i18n-FhEOc8vz.js');
5
+ var factory = require('./factory-tenFFIul.js');
5
6
  require('./index-CYbA1N_k.js');
6
7
 
7
8
  const stripeAddressElementCss = () => `:root{--color-label:#565656;--color-placeholder:#acacac;--color-heading-text:#333;--color-text-error:#ef4444;--color-input-border:#e4e4e6;--color-input-border-shadow:rgba(228, 228, 230, 0.6);--color-button-text:rgba(255, 255, 255, 0.95);--color-button-text-disabled:rgba(255, 255, 255, 0.4);--color-primary:#0074d4}.stripe-payment-sheet-wrap{box-sizing:border-box}.stripe-payment-sheet-wrap *:where(:not(iframe,canvas,img,svg,video):not(svg *)){all:unset;display:revert;background:none;border:none;font-family:"Roboto", sans-serif;box-sizing:border-box}.stripe-payment-sheet-wrap button{cursor:pointer}.stripe-payment-sheet-wrap{display:block;width:100%;background:#fff;padding:32px 16px}.stripe-payment-sheet-wrap #address-element{margin-top:16px}.stripe-payment-sheet-wrap .stripe-heading{font-size:24px;font-weight:bold;color:var(--color-heading-text);margin-bottom:24px}.stripe-payment-sheet-wrap .stripe-section-title{font-size:14px;font-weight:bold;color:var(--color-label);margin-bottom:8px}.stripe-payment-sheet-wrap .payment-info.address{margin-bottom:16px}.stripe-payment-sheet-wrap .stripe-element-errors{margin-top:8px;font-size:14px;color:var(--color-text-error)}.stripe-payment-sheet-wrap .submit-button-wrapper{margin-top:32px}.stripe-payment-sheet-wrap button{display:block;color:var(--color-button-text);background-color:var(--color-primary);width:100%;text-align:center;padding:16px 16px;font-size:18px;border-radius:6px;min-height:42px}.stripe-payment-sheet-wrap button:disabled{color:var(--color-button-text-disabled)}`;
@@ -262,7 +263,7 @@ const StripeAddressElement = class {
262
263
  formElement.addEventListener('submit', this.formSubmitListener);
263
264
  }
264
265
  componentDidLoad() {
265
- this.el.classList.add(factory.checkPlatform());
266
+ this.el.classList.add(i18n.checkPlatform());
266
267
  }
267
268
  disconnectedCallback() {
268
269
  // Remove form submit listener
@@ -279,14 +280,14 @@ const StripeAddressElement = class {
279
280
  const { loadStripeStatus } = this.stripeService.state;
280
281
  const { errorMessage } = this.addressElementManager.getState();
281
282
  if (loadStripeStatus === 'failure') {
282
- return index.h("p", null, factory.i18n.t('Failed to load Stripe'));
283
+ return index.h("p", null, i18n.i18n.t('Failed to load Stripe'));
283
284
  }
284
285
  const disabled = this.progress === 'loading';
285
286
  // NOTE: `stripe-payment-sheet-wrap` below is a legacy CSS class kept for backward
286
287
  // compatibility (leftover from a former component name). It is part of the public
287
288
  // DOM contract — consumers may target it in their own stylesheets — so it must
288
289
  // remain in the rendered output. Do not remove it.
289
- return (index.h("div", { class: "stripe-payment-sheet-wrap" }, index.h("form", { id: "stripe-address-element-form" }, index.h("div", { class: "stripe-heading" }, factory.i18n.t(this.sheetTitle)), index.h("div", { class: "payment-info address visible" }, index.h("div", { id: "address-element" })), index.h("div", { id: "address-errors", class: "stripe-element-errors" }, errorMessage), index.h("div", { class: "submit-button-wrapper" }, index.h("button", { type: "submit", disabled: disabled }, this.progress === 'loading' ? factory.i18n.t('Loading') : factory.i18n.t(this.buttonLabel))))));
290
+ return (index.h("div", { class: "stripe-payment-sheet-wrap" }, index.h("form", { id: "stripe-address-element-form" }, index.h("div", { class: "stripe-heading" }, i18n.i18n.t(this.sheetTitle)), index.h("div", { class: "payment-info address visible" }, index.h("div", { id: "address-element" })), index.h("div", { id: "address-errors", class: "stripe-element-errors" }, errorMessage), index.h("div", { class: "submit-button-wrapper" }, index.h("button", { type: "submit", disabled: disabled }, this.progress === 'loading' ? i18n.i18n.t('Loading') : i18n.i18n.t(this.buttonLabel))))));
290
291
  }
291
292
  get el() { return index.getElement(this); }
292
293
  static get watchers() { return {
@@ -13,7 +13,8 @@ const StripeCardElementModal = class {
13
13
  */
14
14
  this.showLabel = false;
15
15
  /**
16
- * The component will provide a function to call the `stripe.confirmCardPayment`API.
16
+ * The component will confirm the intent for you: `stripe.confirmCardPayment` when `intentType` is `'payment'`,
17
+ * `stripe.confirmCardSetup` when it is `'setup'`.
17
18
  * If you want to customize the behavior, should set false.
18
19
  * And listen the 'formSubmit' event on the element
19
20
  */
@@ -101,7 +102,7 @@ const StripeCardElementModal = class {
101
102
  cardElement.setPaymentRequestOption(options);
102
103
  }
103
104
  render() {
104
- return (index.h("stripe-modal", { key: 'a0229c55472e3c6f417086fa08d79e1ec8a8c485', open: this.open, showCloseButton: this.showCloseButton }, index.h("stripe-card-element", { key: '799f08c781bad089cec8b1338e9a714d080abd51', showLabel: this.showLabel, publishableKey: this.publishableKey, intentClientSecret: this.intentClientSecret, shouldUseDefaultFormSubmitAction: this.shouldUseDefaultFormSubmitAction, handleSubmit: this.handleSubmit, stripeDidLoaded: this.stripeDidLoaded, intentType: this.intentType, zip: this.zip, buttonLabel: this.buttonLabel, sheetTitle: this.sheetTitle, applicationName: this.applicationName })));
105
+ return (index.h("stripe-modal", { key: '4904f57b562da9ce4fc348fb376f931cac707540', open: this.open, showCloseButton: this.showCloseButton }, index.h("stripe-card-element", { key: '8707fa6e32ca82b700f53fc2a257b8af1cc7b45c', showLabel: this.showLabel, publishableKey: this.publishableKey, intentClientSecret: this.intentClientSecret, shouldUseDefaultFormSubmitAction: this.shouldUseDefaultFormSubmitAction, handleSubmit: this.handleSubmit, stripeDidLoaded: this.stripeDidLoaded, intentType: this.intentType, zip: this.zip, buttonLabel: this.buttonLabel, sheetTitle: this.sheetTitle, applicationName: this.applicationName })));
105
106
  }
106
107
  get el() { return index.getElement(this); }
107
108
  };
@@ -1,7 +1,8 @@
1
1
  'use strict';
2
2
 
3
3
  var index = require('./index-Dkb0SxZc.js');
4
- var factory = require('./factory-Cd2VI_N2.js');
4
+ var i18n = require('./i18n-FhEOc8vz.js');
5
+ var factory = require('./factory-tenFFIul.js');
5
6
  var error = require('./error-FFC4kSs5.js');
6
7
  require('./index-CYbA1N_k.js');
7
8
 
@@ -293,7 +294,8 @@ const StripeCardElement = class {
293
294
  */
294
295
  this.showLabel = false;
295
296
  /**
296
- * The component will provide a function to call the `stripe.confirmCardPayment`API.
297
+ * The component will confirm the intent for you: `stripe.confirmCardPayment` when `intentType` is `'payment'`,
298
+ * `stripe.confirmCardSetup` when it is `'setup'`.
297
299
  * If you want to customize the behavior, should set false.
298
300
  * And listen the 'formSubmit' event on the element
299
301
  */
@@ -363,7 +365,7 @@ const StripeCardElement = class {
363
365
  });
364
366
  }
365
367
  componentDidLoad() {
366
- this.el.classList.add(factory.checkPlatform());
368
+ this.el.classList.add(i18n.checkPlatform());
367
369
  }
368
370
  componentDidRender() {
369
371
  // Safely create payment request button after DOM is ready
@@ -414,16 +416,16 @@ const StripeCardElement = class {
414
416
  const { loadStripeStatus } = this.stripeService.state;
415
417
  const { errorMessage } = this.cardElementManager.getState();
416
418
  if (loadStripeStatus === 'failure') {
417
- return index.h("p", null, factory.i18n.t('Failed to load Stripe'));
419
+ return index.h("p", null, i18n.i18n.t('Failed to load Stripe'));
418
420
  }
419
421
  const disabled = this.progress === 'loading';
420
422
  return (
421
423
  // NOTE: `stripe-payment-sheet-wrap` is a legacy class name (leftover from a former
422
424
  // component name). External consumers may target it in their own CSS, so it is a
423
425
  // public DOM contract that MUST be kept for backward compatibility. Do not remove it.
424
- index.h("div", { class: "stripe-payment-sheet-wrap" }, index.h("form", { id: "stripe-card-element" }, index.h("div", { class: "stripe-heading" }, factory.i18n.t(this.sheetTitle)), index.h("div", { id: "stripe-payment-request-button" }), index.h("div", null, index.h("div", { class: "stripe-section-title" }, factory.i18n.t('Card information'))), index.h("div", { class: "payment-info card visible" }, index.h("fieldset", { class: "stripe-input-box" }, index.h("div", null, index.h("label", null, this.showLabel ? index.h("lenged", null, factory.i18n.t('Card Number')) : null, index.h("div", { id: "card-number" }))), index.h("div", { class: "stripe-input-column", style: { display: 'flex' } }, index.h("label", { style: { width: '50%' } }, this.showLabel ? index.h("lenged", null, factory.i18n.t('MM / YY')) : null, index.h("div", { id: "card-expiry" })), index.h("label", { style: { width: '50%' } }, this.showLabel ? index.h("lenged", null, factory.i18n.t('CVC')) : null, index.h("div", { id: "card-cvc" }))))), index.h("div", { id: "card-errors", class: "stripe-element-errors" }, errorMessage), this.zip ? (index.h("div", { style: { marginTop: '1.5rem' } }, index.h("div", { class: "stripe-section-title" }, factory.i18n.t('Country or region')))) : null, this.zip ? (index.h("div", { class: "payment-info card visible" }, index.h("fieldset", { class: "stripe-input-box" }, index.h("div", null, index.h("label", null, this.showLabel ? index.h("lenged", null, factory.i18n.t('Postal Code')) : null, index.h("input", { id: "zip", name: "zip", type: "text", inputmode: "numeric", class: "StripeElement", style: { width: '100%' }, placeholder: factory.i18n.t('Postal Code'), value: this.zipCode, onInput: e => {
426
+ index.h("div", { class: "stripe-payment-sheet-wrap" }, index.h("form", { id: "stripe-card-element" }, index.h("div", { class: "stripe-heading" }, i18n.i18n.t(this.sheetTitle)), index.h("div", { id: "stripe-payment-request-button" }), index.h("div", null, index.h("div", { class: "stripe-section-title" }, i18n.i18n.t('Card information'))), index.h("div", { class: "payment-info card visible" }, index.h("fieldset", { class: "stripe-input-box" }, index.h("div", null, index.h("label", null, this.showLabel ? index.h("lenged", null, i18n.i18n.t('Card Number')) : null, index.h("div", { id: "card-number" }))), index.h("div", { class: "stripe-input-column", style: { display: 'flex' } }, index.h("label", { style: { width: '50%' } }, this.showLabel ? index.h("lenged", null, i18n.i18n.t('MM / YY')) : null, index.h("div", { id: "card-expiry" })), index.h("label", { style: { width: '50%' } }, this.showLabel ? index.h("lenged", null, i18n.i18n.t('CVC')) : null, index.h("div", { id: "card-cvc" }))))), index.h("div", { id: "card-errors", class: "stripe-element-errors" }, errorMessage), this.zip ? (index.h("div", { style: { marginTop: '1.5rem' } }, index.h("div", { class: "stripe-section-title" }, i18n.i18n.t('Country or region')))) : null, this.zip ? (index.h("div", { class: "payment-info card visible" }, index.h("fieldset", { class: "stripe-input-box" }, index.h("div", null, index.h("label", null, this.showLabel ? index.h("lenged", null, i18n.i18n.t('Postal Code')) : null, index.h("input", { id: "zip", name: "zip", type: "text", inputmode: "numeric", class: "StripeElement", style: { width: '100%' }, placeholder: i18n.i18n.t('Postal Code'), value: this.zipCode, onInput: e => {
425
427
  this.zipCode = e.target.value;
426
- } })))))) : null, index.h("div", { style: { marginTop: '32px' } }, index.h("button", { type: "submit", disabled: disabled }, this.progress === 'loading' ? factory.i18n.t('Loading') : factory.i18n.t(this.buttonLabel))))));
428
+ } })))))) : null, index.h("div", { style: { marginTop: '32px' } }, index.h("button", { type: "submit", disabled: disabled }, this.progress === 'loading' ? i18n.i18n.t('Loading') : i18n.i18n.t(this.buttonLabel))))));
427
429
  }
428
430
  get el() { return index.getElement(this); }
429
431
  static get watchers() { return {
@@ -437,91 +439,4 @@ const StripeCardElement = class {
437
439
  };
438
440
  StripeCardElement.style = stripeCardElementCss();
439
441
 
440
- const stripeModalCss = () => `:root{--color-label:#565656;--color-placeholder:#acacac;--color-heading-text:#333;--color-text-error:#ef4444;--color-input-border:#e4e4e6;--color-input-border-shadow:rgba(228, 228, 230, 0.6);--color-button-text:rgba(255, 255, 255, 0.95);--color-button-text-disabled:rgba(255, 255, 255, 0.4);--color-primary:#0074d4}:host{box-sizing:border-box}:host *:where(:not(iframe,canvas,img,svg,video):not(svg *)){all:unset;display:revert;background:none;border:none;font-family:"Roboto", sans-serif;box-sizing:border-box}:host button{cursor:pointer}:host{display:block}.modal-row{opacity:0;pointer-events:none;will-change:transform}.modal-row.open{opacity:1;pointer-events:auto;position:fixed;top:0;left:0;width:100%;height:100%;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;gap:1ch;background:rgba(0, 0, 0, 0.3)}.modal-row .modal-child{transform:translateY(100%);transition:transform 420ms ease;position:relative}.modal-row .modal-child .modal-loading{display:none;position:absolute;top:160px;left:50%;transform:translateX(-50%);width:24px;height:24px}.modal-row .modal-child.loading .modal-loading{display:flex;justify-content:center;align-items:center}.modal-row .modal-child.loading .modal-loading svg{width:24px;height:24px}.modal-row .modal-child.loading .modal-content{visibility:hidden}.modal-row.open .modal-child{transform:translateY(0%)}.modal-child{padding:16px 8px 24px;background-color:#fff;width:100%}.modal-close-button-wrap{padding-left:8px}.modal-close-button-wrap .modal-close-button{width:32px;display:block;fill:var(--color-label);cursor:pointer}`;
441
-
442
- const StripeModal = class {
443
- constructor(hostRef) {
444
- index.registerInstance(this, hostRef);
445
- this.close = index.createEvent(this, "close", 7);
446
- /**
447
- * If true, the modal display close button
448
- */
449
- this.showCloseButton = true;
450
- /**
451
- * Modal state.
452
- * If true, the modal will open
453
- */
454
- this.open = false;
455
- /**
456
- * Effect `this.open`. This is for animation.
457
- * Ionic Ref: https://github.com/ionic-team/ionic-framework/blob/main/core/src/components/accordion/accordion.tsx#L83
458
- */
459
- this.renderedOpen = false;
460
- }
461
- onOpenChange(open) {
462
- if (open) {
463
- this.openModalAnimation();
464
- }
465
- else {
466
- this.renderedOpen = false;
467
- this.close.emit();
468
- }
469
- }
470
- /**
471
- * Toggle modal state
472
- */
473
- async toggleModal() {
474
- this.open ? await this.closeModal() : await this.openModal();
475
- }
476
- /**
477
- * Open the modal
478
- */
479
- async openModal() {
480
- this.open = true;
481
- }
482
- /**
483
- * Close the modal
484
- */
485
- async closeModal() {
486
- this.open = false;
487
- }
488
- componentDidLoad() {
489
- const platformName = factory.checkPlatform();
490
- if (platformName) {
491
- this.el.classList.add(platformName);
492
- }
493
- if (this.open) {
494
- this.openModalAnimation();
495
- }
496
- }
497
- openModalAnimation() {
498
- if (!this.el.shadowRoot) {
499
- this.renderedOpen = true;
500
- return;
501
- }
502
- const modalChild = this.el.shadowRoot.querySelector('.modal-child');
503
- modalChild.classList.add('loading');
504
- modalChild.style.willChange = 'transform';
505
- modalChild.addEventListener('transitionend', () => {
506
- modalChild.style.willChange = 'auto';
507
- modalChild.classList.remove('loading');
508
- }, { once: true });
509
- requestAnimationFrame(() => {
510
- this.renderedOpen = this.open;
511
- });
512
- }
513
- render() {
514
- const { renderedOpen, showCloseButton } = this;
515
- return (index.h(index.Host, { key: '38fb86acf7cf5887a426c67b1a1271f7fae7048c' }, index.h("div", { key: 'f751d92c327ee2e564edfcd4d18f4dca43c20c37', class: `modal-row${renderedOpen ? ' open' : ''}`, onClick: () => this.closeModal() }, index.h("div", { key: '11519ccd44a5069df3247c530a2c1e114eab7aef', class: "modal-child", onClick: e => e.stopPropagation() }, showCloseButton ? (index.h("div", { class: "modal-close-button-wrap" }, index.h("ion-icon", { name: "close", size: "large", class: "modal-close-button", onClick: () => this.closeModal() }))) : null, index.h("div", { key: 'a41f7f263b488b5bbc2a999cbabf6b9e407bca85', class: "modal-loading" }, index.h("svg", { key: '0b3b25cb2812bc4d837fb4b7e6af4a5f42f0247e', version: "1.1", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 2400 2400" }, index.h("g", { key: '10a9f9ec59699e6d2988b9c65cd02da1754fd760', "stroke-width": "200", "stroke-linecap": "round", stroke: "currentColor", fill: "none", id: "spinner" }, index.h("line", { key: 'ed271fa584b930ceed5397c271b31e0d48c72f72', x1: "1200", y1: "600", x2: "1200", y2: "100" }), index.h("line", { key: '3cf855a84f3ab58b914b7aeb784fbc5b95d8ae94', opacity: "0.5", x1: "1200", y1: "2300", x2: "1200", y2: "1800" }), index.h("line", { key: '2cce4b62a276399235509e94f47a63acf9c69a0f', opacity: "0.917", x1: "900", y1: "680.4", x2: "650", y2: "247.4" }), index.h("line", { key: '64c175ef068591417b043f7630a44d34eae7cb59', opacity: "0.417", x1: "1750", y1: "2152.6", x2: "1500", y2: "1719.6" }), index.h("line", { key: '0856a654e3aa756dfb1e9fc316b8b379fa9d5a4e', opacity: "0.833", x1: "680.4", y1: "900", x2: "247.4", y2: "650" }), index.h("line", { key: 'c60f1f8495df9b8cdcc8941255d08c01a0e1c02f', opacity: "0.333", x1: "2152.6", y1: "1750", x2: "1719.6", y2: "1500" }), index.h("line", { key: '204bc2a7765e43b86f91c3fb9b1e72a3a39bb323', opacity: "0.75", x1: "600", y1: "1200", x2: "100", y2: "1200" }), index.h("line", { key: '7584b272f9efd7f746c1bcc5c8a5576098b02381', opacity: "0.25", x1: "2300", y1: "1200", x2: "1800", y2: "1200" }), index.h("line", { key: '7a053e9eb5f0da3fbf6fb7c9680bf73073bb126d', opacity: "0.667", x1: "680.4", y1: "1500", x2: "247.4", y2: "1750" }), index.h("line", { key: 'f8b817095143d739589e45c99b03c7afbdfc8293', opacity: "0.167", x1: "2152.6", y1: "650", x2: "1719.6", y2: "900" }), index.h("line", { key: 'aae0e36dbdfff44196f9758c8a5ed2337139ebe0', opacity: "0.583", x1: "900", y1: "1719.6", x2: "650", y2: "2152.6" }), index.h("line", { key: '3a257b30cb289f29ba386ccca7519bcdc22c3786', opacity: "0.083", x1: "1750", y1: "247.4", x2: "1500", y2: "680.4" }), index.h("animateTransform", { key: 'c6b8e73025589403dd3d08f84b02eb824763d056', attributeName: "transform", attributeType: "XML", type: "rotate", keyTimes: "0;0.08333;0.16667;0.25;0.33333;0.41667;0.5;0.58333;0.66667;0.75;0.83333;0.91667", values: "0 1199 1199;30 1199 1199;60 1199 1199;90 1199 1199;120 1199 1199;150 1199 1199;180 1199 1199;210 1199 1199;240 1199 1199;270 1199 1199;300 1199 1199;330 1199 1199", dur: "0.83333s", begin: "0s", repeatCount: "indefinite", calcMode: "discrete" })))), index.h("div", { key: 'da5ef8031e5b826d854a065d8172389cdd84fbf0', class: "modal-content" }, index.h("slot", { key: 'fbe97a3a4d5489de5ae6f49342c58d537b317842' }))))));
516
- }
517
- get el() { return index.getElement(this); }
518
- static get watchers() { return {
519
- "open": [{
520
- "onOpenChange": 0
521
- }]
522
- }; }
523
- };
524
- StripeModal.style = stripeModalCss();
525
-
526
442
  exports.stripe_card_element = StripeCardElement;
527
- exports.stripe_modal = StripeModal;
@@ -1,7 +1,8 @@
1
1
  'use strict';
2
2
 
3
3
  var index = require('./index-Dkb0SxZc.js');
4
- var factory = require('./factory-Cd2VI_N2.js');
4
+ var i18n = require('./i18n-FhEOc8vz.js');
5
+ var factory = require('./factory-tenFFIul.js');
5
6
  require('./index-CYbA1N_k.js');
6
7
 
7
8
  const stripeCurrencySelectorCss = () => `:root{--color-label:#565656;--color-placeholder:#acacac;--color-heading-text:#333;--color-text-error:#ef4444;--color-input-border:#e4e4e6;--color-input-border-shadow:rgba(228, 228, 230, 0.6);--color-button-text:rgba(255, 255, 255, 0.95);--color-button-text-disabled:rgba(255, 255, 255, 0.4);--color-primary:#0074d4}:host{box-sizing:border-box}:host *:where(:not(iframe,canvas,img,svg,video):not(svg *)){all:unset;display:revert;background:none;border:none;font-family:"Roboto", sans-serif;box-sizing:border-box}:host button{cursor:pointer}:host{display:block;width:100%}.stripe-currency-selector-wrap{width:100%;padding:0;margin:0}.stripe-currency-selector-wrap #currency-selector{width:100%;min-height:40px}.stripe-currency-selector-wrap #currency-selector-errors{margin-top:8px}`;
@@ -165,7 +166,7 @@ const StripeCurrencySelector = class {
165
166
  });
166
167
  }
167
168
  componentDidLoad() {
168
- const platform = factory.checkPlatform();
169
+ const platform = i18n.checkPlatform();
169
170
  if (platform) {
170
171
  this.el.classList.add(platform);
171
172
  }
@@ -177,7 +178,7 @@ const StripeCurrencySelector = class {
177
178
  const { loadStripeStatus } = this.stripeService.state;
178
179
  const { errorMessage } = this.currencySelectorElementManager.getState();
179
180
  if (loadStripeStatus === 'failure') {
180
- return index.h("p", null, factory.i18n.t('Failed to load Stripe'));
181
+ return index.h("p", null, i18n.i18n.t('Failed to load Stripe'));
181
182
  }
182
183
  return (index.h("div", { class: "stripe-currency-selector-wrap" }, index.h("div", { id: "currency-selector" }), errorMessage ? (index.h("div", { id: "currency-selector-errors", class: "stripe-element-errors" }, errorMessage)) : null));
183
184
  }
@@ -46,7 +46,7 @@ var patchCloneNodeFix = (HTMLElementPrototype) => {
46
46
 
47
47
  patchBrowser().then(async (options) => {
48
48
  await appGlobals.globalScripts();
49
- return index.bootstrapLazy([["stripe-card-element-modal.cjs",[[0,"stripe-card-element-modal",{"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"showLabel":[4,"show-label"],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"intentClientSecret":[1,"intent-client-secret"],"shouldUseDefaultFormSubmitAction":[4,"should-use-default-form-submit-action"],"intentType":[1,"intent-type"],"handleSubmit":[1040],"stripeDidLoaded":[1040],"showCloseButton":[4,"show-close-button"],"zip":[4],"open":[4],"getStripeCardElementElement":[64],"present":[64],"updateProgress":[64],"destroy":[64],"setPaymentRequestButton":[64]}]]],["stripe-address-element.cjs",[[0,"stripe-address-element",{"mode":[1],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"showLabel":[4,"show-label"],"defaultCountry":[1,"default-country"],"allowedCountries":[16],"handleSubmit":[1040],"stripeDidLoaded":[1040],"progress":[32],"initStripe":[64],"updateProgress":[64],"setErrorMessage":[64],"getValue":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-currency-selector.cjs",[[0,"stripe-currency-selector",{"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"clientSecret":[1,"client-secret"],"handleCurrencyChange":[1040],"stripeDidLoaded":[1040],"initStripe":[64],"setErrorMessage":[64],"getSelectedCurrency":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-express-checkout-element.cjs",[[0,"stripe-express-checkout-element",{"intentType":[1,"intent-type"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"clientSecret":[1,"client-secret"],"amount":[2],"currency":[1],"buttonHeight":[1,"button-height"],"shouldUseDefaultConfirmAction":[4,"should-use-default-confirm-action"],"stripeDidLoaded":[1040],"progress":[32],"updateProgress":[64],"setErrorMessage":[64],"initStripe":[64],"updateElementOptions":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-link-authentication-element.cjs",[[0,"stripe-link-authentication-element",{"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"defaultEmail":[1,"default-email"],"handleChange":[1040],"stripeDidLoaded":[1040],"progress":[32],"initStripe":[64],"updateProgress":[64],"setErrorMessage":[64],"getEmail":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-payment-element.cjs",[[0,"stripe-payment-element",{"intentType":[1,"intent-type"],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"intentClientSecret":[1,"intent-client-secret"],"checkoutSessionClientSecret":[1,"checkout-session-client-secret"],"shouldUseDefaultFormSubmitAction":[4,"should-use-default-form-submit-action"],"handleSubmit":[1040],"stripeDidLoaded":[1040],"progress":[32],"initStripe":[64],"initStripeWithCheckoutSession":[64],"updateProgress":[64],"setErrorMessage":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}],"intentClientSecret":[{"updateIntentClientSecret":0}],"checkoutSessionClientSecret":[{"updateCheckoutSessionClientSecret":0}]}]]],["ion-icon.cjs",[[1,"ion-icon",{"mode":[1025],"color":[1],"ios":[1],"md":[1],"flipRtl":[4,"flip-rtl"],"name":[513],"src":[1],"icon":[8],"size":[1],"lazy":[4],"sanitize":[4],"svgContent":[32],"isVisible":[32]},null,{"name":[{"loadIcon":0}],"src":[{"loadIcon":0}],"icon":[{"loadIcon":0}],"ios":[{"loadIcon":0}],"md":[{"loadIcon":0}]}]]],["stripe-payment-request-button.cjs",[[260,"stripe-payment-request-button",{"paymentMethodEventHandler":[16],"shippingOptionEventHandler":[16],"shippingAddressEventHandler":[16],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"stripeDidLoaded":[1040],"loadStripeStatus":[32],"stripe":[32],"paymentRequestOption":[32],"isAvailable":[64],"setPaymentMethodEventHandler":[64],"setPaymentRequestShippingOptionEventHandler":[64],"setPaymentRequestShippingAddressEventHandler":[64],"setPaymentRequestOption":[64],"initStripe":[64]}]]],["stripe-card-element_2.cjs",[[0,"stripe-card-element",{"intentType":[1,"intent-type"],"zip":[4],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"showLabel":[4,"show-label"],"intentClientSecret":[1,"intent-client-secret"],"shouldUseDefaultFormSubmitAction":[4,"should-use-default-form-submit-action"],"showPaymentRequestButton":[4,"show-payment-request-button"],"handleSubmit":[1040],"stripeDidLoaded":[1040],"progress":[32],"zipCode":[32],"paymentRequestOption":[32],"initStripe":[64],"updateProgress":[64],"setErrorMessage":[64],"setPaymentRequestOption":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}],[257,"stripe-modal",{"showCloseButton":[4,"show-close-button"],"open":[1028],"renderedOpen":[32],"toggleModal":[64],"openModal":[64],"closeModal":[64]},null,{"open":[{"onOpenChange":0}]}]]]], options);
49
+ return index.bootstrapLazy([["stripe-card-element-modal.cjs",[[0,"stripe-card-element-modal",{"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"showLabel":[4,"show-label"],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"intentClientSecret":[1,"intent-client-secret"],"shouldUseDefaultFormSubmitAction":[4,"should-use-default-form-submit-action"],"intentType":[1,"intent-type"],"handleSubmit":[1040],"stripeDidLoaded":[1040],"showCloseButton":[4,"show-close-button"],"zip":[4],"open":[4],"getStripeCardElementElement":[64],"present":[64],"updateProgress":[64],"destroy":[64],"setPaymentRequestButton":[64]}]]],["stripe-payment-sheet.cjs",[[0,"stripe-payment-sheet",{"publishableKey":[1,"publishable-key"],"intentClientSecret":[1,"intent-client-secret"],"stripeAccount":[1,"stripe-account"],"open":[1540],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"applicationName":[1,"application-name"],"options":[16],"sheet":[32],"visible":[32],"errorMessage":[32],"present":[64]},null,{"publishableKey":[{"handleSecretChange":0}],"intentClientSecret":[{"handleSecretChange":0}],"stripeAccount":[{"handleSecretChange":0}],"open":[{"handleOpenChange":0}]}]]],["stripe-address-element.cjs",[[0,"stripe-address-element",{"mode":[1],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"showLabel":[4,"show-label"],"defaultCountry":[1,"default-country"],"allowedCountries":[16],"handleSubmit":[1040],"stripeDidLoaded":[1040],"progress":[32],"initStripe":[64],"updateProgress":[64],"setErrorMessage":[64],"getValue":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-currency-selector.cjs",[[0,"stripe-currency-selector",{"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"clientSecret":[1,"client-secret"],"handleCurrencyChange":[1040],"stripeDidLoaded":[1040],"initStripe":[64],"setErrorMessage":[64],"getSelectedCurrency":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-express-checkout-element.cjs",[[0,"stripe-express-checkout-element",{"intentType":[1,"intent-type"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"clientSecret":[1,"client-secret"],"amount":[2],"currency":[1],"buttonHeight":[1,"button-height"],"shouldUseDefaultConfirmAction":[4,"should-use-default-confirm-action"],"stripeDidLoaded":[1040],"progress":[32],"updateProgress":[64],"setErrorMessage":[64],"initStripe":[64],"updateElementOptions":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-link-authentication-element.cjs",[[0,"stripe-link-authentication-element",{"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"defaultEmail":[1,"default-email"],"handleChange":[1040],"stripeDidLoaded":[1040],"progress":[32],"initStripe":[64],"updateProgress":[64],"setErrorMessage":[64],"getEmail":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["stripe-payment-element.cjs",[[0,"stripe-payment-element",{"intentType":[1,"intent-type"],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"intentClientSecret":[1,"intent-client-secret"],"checkoutSessionClientSecret":[1,"checkout-session-client-secret"],"shouldUseDefaultFormSubmitAction":[4,"should-use-default-form-submit-action"],"handleSubmit":[1040],"stripeDidLoaded":[1040],"progress":[32],"initStripe":[64],"initStripeWithCheckoutSession":[64],"updateProgress":[64],"setErrorMessage":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}],"intentClientSecret":[{"updateIntentClientSecret":0}],"checkoutSessionClientSecret":[{"updateCheckoutSessionClientSecret":0}]}]]],["stripe-payment-request-button.cjs",[[260,"stripe-payment-request-button",{"paymentMethodEventHandler":[16],"shippingOptionEventHandler":[16],"shippingAddressEventHandler":[16],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"stripeDidLoaded":[1040],"loadStripeStatus":[32],"stripe":[32],"paymentRequestOption":[32],"isAvailable":[64],"setPaymentMethodEventHandler":[64],"setPaymentRequestShippingOptionEventHandler":[64],"setPaymentRequestShippingAddressEventHandler":[64],"setPaymentRequestOption":[64],"initStripe":[64]}]]],["stripe-card-element.cjs",[[0,"stripe-card-element",{"intentType":[1,"intent-type"],"zip":[4],"sheetTitle":[1,"sheet-title"],"buttonLabel":[1,"button-label"],"publishableKey":[1,"publishable-key"],"stripeAccount":[1,"stripe-account"],"applicationName":[1,"application-name"],"showLabel":[4,"show-label"],"intentClientSecret":[1,"intent-client-secret"],"shouldUseDefaultFormSubmitAction":[4,"should-use-default-form-submit-action"],"showPaymentRequestButton":[4,"show-payment-request-button"],"handleSubmit":[1040],"stripeDidLoaded":[1040],"progress":[32],"zipCode":[32],"paymentRequestOption":[32],"initStripe":[64],"updateProgress":[64],"setErrorMessage":[64],"setPaymentRequestOption":[64]},null,{"publishableKey":[{"updatePublishableKey":0}],"stripeAccount":[{"updateStripeAccountId":0}]}]]],["ion-icon_2.cjs",[[257,"stripe-modal",{"showCloseButton":[4,"show-close-button"],"open":[1028],"renderedOpen":[32],"toggleModal":[64],"openModal":[64],"closeModal":[64]},null,{"open":[{"onOpenChange":0}]}],[1,"ion-icon",{"mode":[1025],"color":[1],"ios":[1],"md":[1],"flipRtl":[4,"flip-rtl"],"name":[513],"src":[1],"icon":[8],"size":[1],"lazy":[4],"sanitize":[4],"svgContent":[32],"isVisible":[32]},null,{"name":[{"loadIcon":0}],"src":[{"loadIcon":0}],"icon":[{"loadIcon":0}],"ios":[{"loadIcon":0}],"md":[{"loadIcon":0}]}]]]], options);
50
50
  });
51
51
 
52
52
  exports.setNonce = index.setNonce;
@@ -1,7 +1,8 @@
1
1
  'use strict';
2
2
 
3
3
  var index = require('./index-Dkb0SxZc.js');
4
- var factory = require('./factory-Cd2VI_N2.js');
4
+ var i18n = require('./i18n-FhEOc8vz.js');
5
+ var factory = require('./factory-tenFFIul.js');
5
6
  var error = require('./error-FFC4kSs5.js');
6
7
  require('./index-CYbA1N_k.js');
7
8
 
@@ -73,6 +74,8 @@ const StripeExpressCheckoutElement = class {
73
74
  await this.stripeService.initialize(publishableKey, {
74
75
  stripeAccount: options === null || options === void 0 ? void 0 : options.stripeAccount,
75
76
  applicationName: this.applicationName,
77
+ clientSecret: this.clientSecret,
78
+ elementsOptions: this.buildElementsOptions(),
76
79
  });
77
80
  // If already successfully loaded, initialize elements immediately
78
81
  if (this.stripeService.state.loadStripeStatus === 'success') {
@@ -91,6 +94,22 @@ const StripeExpressCheckoutElement = class {
91
94
  });
92
95
  }
93
96
  }
97
+ /**
98
+ * Options for `stripe.elements()` when there is no client secret.
99
+ * Stripe.js reads mode / amount / currency from the Elements group, not from the element itself.
100
+ */
101
+ buildElementsOptions() {
102
+ if (this.currency == null || this.currency === '') {
103
+ return undefined;
104
+ }
105
+ if (this.intentType === 'setup') {
106
+ return { mode: 'setup', currency: this.currency };
107
+ }
108
+ if (this.amount === undefined) {
109
+ return undefined;
110
+ }
111
+ return { mode: 'payment', amount: this.amount, currency: this.currency };
112
+ }
94
113
  /**
95
114
  * Update element options dynamically
96
115
  * @param options - Partial options to update
@@ -273,7 +292,7 @@ const StripeExpressCheckoutElement = class {
273
292
  });
274
293
  }
275
294
  componentDidLoad() {
276
- this.el.classList.add(factory.checkPlatform());
295
+ this.el.classList.add(i18n.checkPlatform());
277
296
  }
278
297
  disconnectedCallback() {
279
298
  this.expressCheckoutManager.unmount();
@@ -282,12 +301,12 @@ const StripeExpressCheckoutElement = class {
282
301
  const { loadStripeStatus } = this.stripeService.state;
283
302
  const { errorMessage, isReady } = this.expressCheckoutManager.getState();
284
303
  if (loadStripeStatus === 'failure') {
285
- return index.h("p", null, factory.i18n.t('Failed to load Stripe'));
304
+ return index.h("p", null, i18n.i18n.t('Failed to load Stripe'));
286
305
  }
287
306
  if (loadStripeStatus === 'loading') {
288
- return index.h("p", null, factory.i18n.t('Loading'));
307
+ return index.h("p", null, i18n.i18n.t('Loading'));
289
308
  }
290
- return (index.h("div", { class: "stripe-express-checkout-wrap" }, index.h("div", { id: "express-checkout-element" }), errorMessage && (index.h("div", { id: "express-checkout-errors", class: "stripe-element-errors" }, errorMessage)), !isReady && loadStripeStatus === 'success' && index.h("div", { class: "stripe-express-checkout-loading" }, factory.i18n.t('Loading'))));
309
+ return (index.h("div", { class: "stripe-express-checkout-wrap" }, index.h("div", { id: "express-checkout-element" }), errorMessage && (index.h("div", { id: "express-checkout-errors", class: "stripe-element-errors" }, errorMessage)), !isReady && loadStripeStatus === 'success' && index.h("div", { class: "stripe-express-checkout-loading" }, i18n.i18n.t('Loading'))));
291
310
  }
292
311
  get el() { return index.getElement(this); }
293
312
  static get watchers() { return {
@@ -1,7 +1,8 @@
1
1
  'use strict';
2
2
 
3
3
  var index = require('./index-Dkb0SxZc.js');
4
- var factory = require('./factory-Cd2VI_N2.js');
4
+ var i18n = require('./i18n-FhEOc8vz.js');
5
+ var factory = require('./factory-tenFFIul.js');
5
6
  require('./index-CYbA1N_k.js');
6
7
 
7
8
  const stripeLinkAuthenticationElementCss = () => `:root{--color-label:#565656;--color-placeholder:#acacac;--color-heading-text:#333;--color-text-error:#ef4444;--color-input-border:#e4e4e6;--color-input-border-shadow:rgba(228, 228, 230, 0.6);--color-button-text:rgba(255, 255, 255, 0.95);--color-button-text-disabled:rgba(255, 255, 255, 0.4);--color-primary:#0074d4}.stripe-link-authentication-wrap{box-sizing:border-box}.stripe-link-authentication-wrap *:where(:not(iframe,canvas,img,svg,video):not(svg *)){all:unset;display:revert;background:none;border:none;font-family:"Roboto", sans-serif;box-sizing:border-box}.stripe-link-authentication-wrap button{cursor:pointer}.stripe-link-authentication-wrap{display:block;width:100%;background:#fff;padding:16px}.stripe-link-authentication-wrap .stripe-link-authentication-container #link-authentication-element .StripeElement{padding:8px 16px;min-height:64px;border-radius:6px;display:flex;justify-content:center;align-items:center}.stripe-link-authentication-wrap .stripe-link-authentication-container #link-authentication-element .StripeElement>.__PrivateStripeElement{width:100%}.stripe-link-authentication-wrap .stripe-link-authentication-container .stripe-element-errors{margin-top:8px;font-size:14px;color:var(--color-text-error)}`;
@@ -201,7 +202,7 @@ const StripeLinkAuthenticationElement = class {
201
202
  });
202
203
  }
203
204
  componentDidLoad() {
204
- const platform = factory.checkPlatform();
205
+ const platform = i18n.checkPlatform();
205
206
  if (platform) {
206
207
  this.el.classList.add(platform);
207
208
  }
@@ -213,7 +214,7 @@ const StripeLinkAuthenticationElement = class {
213
214
  const { loadStripeStatus } = this.stripeService.state;
214
215
  const { errorMessage } = this.linkAuthenticationElementManager.getState();
215
216
  if (loadStripeStatus === 'failure') {
216
- return index.h("p", null, factory.i18n.t('Failed to load Stripe'));
217
+ return index.h("p", null, i18n.i18n.t('Failed to load Stripe'));
217
218
  }
218
219
  return (index.h("div", { class: "stripe-link-authentication-wrap" }, index.h("div", { class: "stripe-link-authentication-container" }, index.h("div", { id: "link-authentication-element" }), index.h("div", { id: "link-authentication-errors", class: "stripe-element-errors" }, errorMessage))));
219
220
  }
@@ -1,123 +1,11 @@
1
1
  'use strict';
2
2
 
3
3
  var index = require('./index-Dkb0SxZc.js');
4
- var factory = require('./factory-Cd2VI_N2.js');
5
- var error = require('./error-FFC4kSs5.js');
4
+ var i18n = require('./i18n-FhEOc8vz.js');
5
+ var factory = require('./factory-tenFFIul.js');
6
+ var stripePaymentElement_helpers = require('./stripe-payment-element.helpers-DukP33RI.js');
6
7
  require('./index-CYbA1N_k.js');
7
-
8
- /**
9
- * Determine whether the submit button should be disabled.
10
- * For Checkout Session mode: the checkout is ready once Stripe finished loading.
11
- * For Payment Intent / Setup Intent mode: an intent client secret must be present.
12
- * @param params progress / loading state and the current mode information
13
- * @returns true when the submit button should be disabled
14
- */
15
- const isSubmitButtonDisabled = (params) => {
16
- const { progress, isCheckoutSession, loadStripeStatus, intentClientSecret } = params;
17
- const hasValidSecret = isCheckoutSession ? loadStripeStatus === 'success' : intentClientSecret != null && intentClientSecret !== '';
18
- return progress === 'loading' || !hasValidSecret;
19
- };
20
- /**
21
- * Run the default Stripe confirmation flow for Payment Intent / Setup Intent mode.
22
- * Calls `confirmPayment` or `confirmSetup` depending on the intent type.
23
- * @param stripe the loaded Stripe.js instance
24
- * @param elements the Stripe Elements instance bound to the payment element
25
- * @param intentType the configured intent type
26
- * @param returnUrl the URL Stripe should redirect back to when required
27
- * @returns the confirmation result
28
- * @throws StripeAPIError when Stripe returns an error
29
- */
30
- const confirmPaymentOrSetup = async (stripe, elements, intentType, returnUrl) => {
31
- const result = await (() => {
32
- if (intentType === 'payment') {
33
- return stripe.confirmPayment({
34
- elements,
35
- confirmParams: {
36
- return_url: returnUrl,
37
- },
38
- redirect: 'if_required',
39
- });
40
- }
41
- return stripe.confirmSetup({
42
- elements,
43
- confirmParams: {
44
- return_url: returnUrl,
45
- },
46
- redirect: 'if_required',
47
- });
48
- })();
49
- if (result.error) {
50
- throw new error.StripeAPIError(result.error);
51
- }
52
- return result;
53
- };
54
- /**
55
- * Confirm a Checkout Session payment using the checkout actions.
56
- * @param checkout the Stripe Checkout instance
57
- * @param returnUrl the URL Stripe should redirect back to when required
58
- * @returns the confirmation result
59
- * @throws StripeAPIError when loading actions or confirming fails
60
- */
61
- const confirmCheckoutSession = async (checkout, returnUrl) => {
62
- var _a;
63
- // Load actions from the checkout session
64
- const loadActionsResult = await checkout.loadActions();
65
- if (loadActionsResult.type === 'error') {
66
- // Create a StripeError-compatible object from the Checkout Session error
67
- const stripeError = {
68
- type: 'api_error',
69
- code: loadActionsResult.error.code || 'checkout_session_error',
70
- message: loadActionsResult.error.message,
71
- };
72
- throw new error.StripeAPIError(stripeError);
73
- }
74
- const { actions } = loadActionsResult;
75
- // Confirm the payment using checkout session actions
76
- const result = await actions.confirm({
77
- returnUrl,
78
- redirect: 'if_required',
79
- });
80
- if (result.type === 'error') {
81
- // Create a StripeError-compatible object from the confirm error
82
- const stripeError = {
83
- type: 'card_error',
84
- code: result.error.code || 'payment_failed',
85
- message: result.error.message,
86
- decline_code: result.error.code === 'paymentFailed' ? (_a = result.error.paymentFailed) === null || _a === void 0 ? void 0 : _a.declineCode : undefined,
87
- };
88
- throw new error.StripeAPIError(stripeError);
89
- }
90
- return result;
91
- };
92
- /**
93
- * Resolve the mode-specific properties for a submit event.
94
- * Picks the Checkout or Elements payload depending on the active mode and
95
- * reports a descriptive error string when the required instance is missing.
96
- * @param params the resolved Stripe instances and client secrets for the current mode
97
- * @returns the submit event props, or an error message when an instance is missing
98
- */
99
- const buildSubmitEventProps = (params) => {
100
- const { stripe, isCheckoutSession, checkout, checkoutSessionClientSecret, elements, intentClientSecret } = params;
101
- const props = {
102
- stripe,
103
- };
104
- if (isCheckoutSession) {
105
- // Checkout Session mode
106
- if (checkout == null) {
107
- return { error: 'Checkout not properly initialized' };
108
- }
109
- props.checkout = checkout;
110
- props.checkoutSessionClientSecret = checkoutSessionClientSecret;
111
- return { props };
112
- }
113
- // Payment Intent / Setup Intent mode
114
- if (elements == null) {
115
- return { error: 'Elements not properly initialized' };
116
- }
117
- props.elements = elements;
118
- props.intentClientSecret = intentClientSecret;
119
- return { props };
120
- };
8
+ require('./error-FFC4kSs5.js');
121
9
 
122
10
  const stripePaymentElementCss = () => `:root{--color-label:#565656;--color-placeholder:#acacac;--color-heading-text:#333;--color-text-error:#ef4444;--color-input-border:#e4e4e6;--color-input-border-shadow:rgba(228, 228, 230, 0.6);--color-button-text:rgba(255, 255, 255, 0.95);--color-button-text-disabled:rgba(255, 255, 255, 0.4);--color-primary:#0074d4}.stripe-payment-sheet-wrap{box-sizing:border-box}.stripe-payment-sheet-wrap *:where(:not(iframe,canvas,img,svg,video):not(svg *)){all:unset;display:revert;background:none;border:none;font-family:"Roboto", sans-serif;box-sizing:border-box}.stripe-payment-sheet-wrap button{cursor:pointer}.stripe-payment-sheet-wrap{display:block;width:100%;background:#fff;padding:32px 16px}.stripe-payment-sheet-wrap .StripeElement{padding:8px 16px;min-height:64px;border-radius:6px;display:flex;justify-content:center;align-items:center}.stripe-payment-sheet-wrap .StripeElement>.__PrivateStripeElement{width:100%}.stripe-payment-sheet-wrap .stripe-heading{font-size:24px;font-weight:bold;color:var(--color-heading-text);margin-bottom:24px}.stripe-payment-sheet-wrap .stripe-section-title{font-size:14px;font-weight:bold;color:var(--color-label);margin-bottom:8px}.stripe-payment-sheet-wrap .payment-info{margin-top:8px}.stripe-payment-sheet-wrap .stripe-element-errors{margin-top:8px;font-size:14px;color:var(--color-text-error)}.stripe-payment-sheet-wrap button{display:block;color:var(--color-button-text);background-color:var(--color-primary);width:100%;text-align:center;padding:16px 16px;font-size:18px;border-radius:6px;min-height:42px}.stripe-payment-sheet-wrap button:disabled{color:var(--color-button-text-disabled)}`;
123
11
 
@@ -265,7 +153,7 @@ const StripePaymentElement = class {
265
153
  console.error('Stripe not properly initialized');
266
154
  return;
267
155
  }
268
- const result = buildSubmitEventProps({
156
+ const result = stripePaymentElement_helpers.buildSubmitEventProps({
269
157
  stripe,
270
158
  isCheckoutSession,
271
159
  checkout: this.stripeService.getCheckout(),
@@ -316,7 +204,7 @@ const StripePaymentElement = class {
316
204
  try {
317
205
  // Get current page URL for return_url
318
206
  const returnUrl = window.location.href;
319
- const result = await confirmPaymentOrSetup(stripe, elements, this.intentType, returnUrl);
207
+ const result = await stripePaymentElement_helpers.confirmPaymentOrSetup(stripe, elements, this.intentType, returnUrl);
320
208
  this.defaultFormSubmitResultHandler(result);
321
209
  }
322
210
  catch (e) {
@@ -336,7 +224,7 @@ const StripePaymentElement = class {
336
224
  try {
337
225
  // Get current page URL for return_url
338
226
  const returnUrl = window.location.href;
339
- const result = await confirmCheckoutSession(checkout, returnUrl);
227
+ const result = await stripePaymentElement_helpers.confirmCheckoutSession(checkout, returnUrl);
340
228
  this.checkoutSessionConfirmResultHandler(result);
341
229
  }
342
230
  catch (e) {
@@ -485,7 +373,7 @@ const StripePaymentElement = class {
485
373
  return;
486
374
  }
487
375
  // Build submit event props based on mode (shared with formSubmitEventHandler)
488
- const result = buildSubmitEventProps({
376
+ const result = stripePaymentElement_helpers.buildSubmitEventProps({
489
377
  stripe,
490
378
  isCheckoutSession,
491
379
  checkout: this.stripeService.getCheckout(),
@@ -533,7 +421,7 @@ const StripePaymentElement = class {
533
421
  formElement.addEventListener('submit', this._submitHandler);
534
422
  }
535
423
  componentDidLoad() {
536
- this.el.classList.add(factory.checkPlatform());
424
+ this.el.classList.add(i18n.checkPlatform());
537
425
  }
538
426
  disconnectedCallback() {
539
427
  this.paymentElementManager.unmount();
@@ -549,10 +437,10 @@ const StripePaymentElement = class {
549
437
  const { loadStripeStatus, isCheckoutSession } = this.stripeService.state;
550
438
  const { errorMessage } = this.paymentElementManager.getState();
551
439
  if (loadStripeStatus === 'failure') {
552
- return index.h("p", null, factory.i18n.t('Failed to load Stripe'));
440
+ return index.h("p", null, i18n.i18n.t('Failed to load Stripe'));
553
441
  }
554
442
  // Determine if button should be disabled (see isSubmitButtonDisabled helper for mode-specific rules)
555
- const disabled = isSubmitButtonDisabled({
443
+ const disabled = stripePaymentElement_helpers.isSubmitButtonDisabled({
556
444
  progress: this.progress,
557
445
  isCheckoutSession: isCheckoutSession === true,
558
446
  loadStripeStatus,
@@ -562,7 +450,7 @@ const StripePaymentElement = class {
562
450
  // NOTE: `stripe-payment-sheet-wrap` is a legacy CSS class kept for backward compatibility.
563
451
  // It is a leftover from a former component name but is part of the public DOM contract,
564
452
  // so external stylesheets may target it. Keep it in the rendered output and the .scss.
565
- index.h("div", { class: "stripe-payment-sheet-wrap" }, index.h("form", { id: "stripe-payment-element" }, index.h("div", { class: "stripe-heading" }, factory.i18n.t(this.sheetTitle)), index.h("div", null, index.h("div", { class: "stripe-section-title" }, factory.i18n.t('Payment information'))), index.h("div", { class: "payment-info visible" }, index.h("div", { id: "payment-element" })), index.h("div", { id: "payment-errors", class: "stripe-element-errors" }, errorMessage), index.h("div", { style: { marginTop: '32px' } }, index.h("button", { type: "submit", disabled: disabled }, this.progress === 'loading' ? factory.i18n.t('Loading') : factory.i18n.t(this.buttonLabel))))));
453
+ index.h("div", { class: "stripe-payment-sheet-wrap" }, index.h("form", { id: "stripe-payment-element" }, index.h("div", { class: "stripe-heading" }, i18n.i18n.t(this.sheetTitle)), index.h("div", null, index.h("div", { class: "stripe-section-title" }, i18n.i18n.t('Payment information'))), index.h("div", { class: "payment-info visible" }, index.h("div", { id: "payment-element" })), index.h("div", { id: "payment-errors", class: "stripe-element-errors" }, errorMessage), index.h("div", { style: { marginTop: '32px' } }, index.h("button", { type: "submit", disabled: disabled }, this.progress === 'loading' ? i18n.i18n.t('Loading') : i18n.i18n.t(this.buttonLabel))))));
566
454
  }
567
455
  get el() { return index.getElement(this); }
568
456
  static get watchers() { return {