@paykka/card-checkout-ui 0.13.1 → 0.13.5

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 (158) hide show
  1. package/dist/card-checkout-ui.js +21 -21
  2. package/dist/card-checkout-ui.umd.cjs +21 -21
  3. package/dist/es/_commonjsHelpers.js +82 -1
  4. package/dist/es/api/modules/get-browser-params.js +4 -1
  5. package/dist/es/api/modules/opay-wallet/index.js +16 -0
  6. package/dist/es/api/modules/paga-wallet/index.js +16 -0
  7. package/dist/es/api/modules/pic-pay/index.js +16 -0
  8. package/dist/es/api/modules/pix/index.js +16 -0
  9. package/dist/es/api/modules/vietqr/index.js +4 -0
  10. package/dist/es/components/AliPay/index.js +29 -35
  11. package/dist/es/components/Boost/index.js +34 -40
  12. package/dist/es/components/Card/index.js +35 -39
  13. package/dist/es/components/DropIn/index.js +42 -2
  14. package/dist/es/components/EncryptedCard/index.js +5 -1
  15. package/dist/es/components/GooglePay/index.js +1 -0
  16. package/dist/es/components/GrabPay/index.js +34 -40
  17. package/dist/es/components/GuideCard/index.js +6 -1
  18. package/dist/es/components/LinePay/index.js +34 -40
  19. package/dist/es/components/MayBankQRPay/index.js +35 -41
  20. package/dist/es/components/NinePay/index.js +34 -40
  21. package/dist/es/components/SecuredFieldsProvider/index.js +23 -7
  22. package/dist/es/components/SecuredIframe/index.js +36 -59
  23. package/dist/es/components/Sepa/index.js +17 -21
  24. package/dist/es/components/ShopeePay/index.js +34 -40
  25. package/dist/es/components/TNGWallet/index.js +34 -40
  26. package/dist/es/components/ThreeDS/index.js +32 -7
  27. package/dist/es/components/WechatPay/index.js +19 -24
  28. package/dist/es/components/business/QRCodeModal/QRCodeModal.js +6 -6
  29. package/dist/es/components/index.js +5 -0
  30. package/dist/es/components/internal/Form/FormItem.js +1 -1
  31. package/dist/es/components/internal/Form/util.js +1 -1
  32. package/dist/es/components/internal/Select/SelectMenu.js +2 -2
  33. package/dist/es/components/internal/icons/IconError.js +7 -4
  34. package/dist/es/components/internal/icons/IconOpayWallet.js +71 -0
  35. package/dist/es/components/internal/icons/IconPagaWallet.js +141 -0
  36. package/dist/es/components/internal/icons/IconPaymaya.js +42 -86
  37. package/dist/es/components/internal/icons/IconPicPay.js +49 -0
  38. package/dist/es/components/internal/icons/IconPix.js +75 -0
  39. package/dist/es/components/internal/icons/IconVietqr.js +45 -0
  40. package/dist/es/components/internal/icons/IconVietqrComplete.js +49 -0
  41. package/dist/es/components/wallets/GCash/GCash.js +20 -25
  42. package/dist/es/components/wallets/OpayWallet/OpayWallet.js +346 -0
  43. package/dist/es/components/wallets/OpayWallet/index.js +1 -0
  44. package/dist/es/components/wallets/OpayWallet/opay-wallet.js +1 -0
  45. package/dist/es/components/wallets/OpayWallet/type.js +1 -0
  46. package/dist/es/components/wallets/PagaWallet/PagaWallet.js +346 -0
  47. package/dist/es/components/wallets/PagaWallet/index.js +1 -0
  48. package/dist/es/components/wallets/PagaWallet/paga-wallet.js +1 -0
  49. package/dist/es/components/wallets/PagaWallet/type.js +1 -0
  50. package/dist/es/components/wallets/Paymaya/Paymaya.js +34 -40
  51. package/dist/es/components/wallets/PicPay/PicPay.js +346 -0
  52. package/dist/es/components/wallets/PicPay/index.js +1 -0
  53. package/dist/es/components/wallets/PicPay/pic-pay.js +1 -0
  54. package/dist/es/components/wallets/PicPay/type.js +1 -0
  55. package/dist/es/components/wallets/Pix/Pix.js +346 -0
  56. package/dist/es/components/wallets/Pix/index.js +1 -0
  57. package/dist/es/components/wallets/Pix/pix2.js +1 -0
  58. package/dist/es/components/wallets/Pix/type.js +1 -0
  59. package/dist/es/components/wallets/Vietqr/Vietqr.js +380 -0
  60. package/dist/es/components/wallets/Vietqr/index.js +1 -0
  61. package/dist/es/components/wallets/Vietqr/type.js +1 -0
  62. package/dist/es/components/wallets/Vietqr/vietqr2.js +1 -0
  63. package/dist/es/components/wallets/Zalopay/Zalopay.js +17 -21
  64. package/dist/es/components/wallets/index.js +8 -0
  65. package/dist/es/constant.js +32 -2
  66. package/dist/es/core/checkout.js +24 -1
  67. package/dist/es/core/create.js +1 -1
  68. package/dist/es/core/session.js +2 -23
  69. package/dist/es/core/theme.js +65 -0
  70. package/dist/es/core.js +34 -34
  71. package/dist/es/i18n/locales/de-DE.js +8 -2
  72. package/dist/es/i18n/locales/en-GB.js +8 -2
  73. package/dist/es/i18n/locales/es-ES.js +8 -2
  74. package/dist/es/i18n/locales/fr-FR.js +8 -2
  75. package/dist/es/i18n/locales/ja-JP.js +8 -2
  76. package/dist/es/i18n/locales/ko-KR.js +8 -2
  77. package/dist/es/i18n/locales/nl-NL.js +8 -2
  78. package/dist/es/i18n/locales/pt-PT.js +8 -2
  79. package/dist/es/i18n/locales/ru-RU.js +8 -2
  80. package/dist/es/i18n/locales/zh-CN.js +10 -4
  81. package/dist/es/i18n/locales/zh-HK.js +10 -4
  82. package/dist/es/i18n/locales/zh-TW.js +10 -4
  83. package/dist/es/index.js +17 -5
  84. package/dist/es/style.css +1 -1
  85. package/dist/es/utils/format.js +0 -5
  86. package/dist/es/utils/object.js +31 -1
  87. package/dist/es/utils/string.js +10 -0
  88. package/dist/es/utils/system-info/is-ua-webview.js +14 -12
  89. package/dist/es/utils/theme.js +7 -0
  90. package/dist/style.css +1 -1
  91. package/dist/types/api/modules/get-browser-params.d.ts +1 -0
  92. package/dist/types/api/modules/index.d.ts +5 -0
  93. package/dist/types/api/modules/opay-wallet/index.d.ts +4 -0
  94. package/dist/types/api/modules/paga-wallet/index.d.ts +4 -0
  95. package/dist/types/api/modules/pic-pay/index.d.ts +4 -0
  96. package/dist/types/api/modules/pix/index.d.ts +4 -0
  97. package/dist/types/api/modules/vietqr/index.d.ts +4 -0
  98. package/dist/types/components/DropIn/type.d.ts +3 -2
  99. package/dist/types/components/SecuredFieldsProvider/type.d.ts +5 -0
  100. package/dist/types/components/SecuredIframe/HiddenIframe.d.ts +3 -1
  101. package/dist/types/components/ThreeDS/components/ThreeDSAuth/type.d.ts +2 -0
  102. package/dist/types/components/business/QRCodeModal/type.d.ts +2 -0
  103. package/dist/types/components/index.d.ts +1 -3
  104. package/dist/types/components/internal/Loading/Loading.d.ts +1 -0
  105. package/dist/types/components/internal/Select/SelectMenu.d.ts +1 -1
  106. package/dist/types/components/internal/icons/IconOpayWallet.d.ts +2 -0
  107. package/dist/types/components/internal/icons/IconPagaWallet.d.ts +2 -0
  108. package/dist/types/components/internal/icons/IconPicPay.d.ts +2 -0
  109. package/dist/types/components/internal/icons/IconPix.d.ts +2 -0
  110. package/dist/types/components/internal/icons/IconVietqr.d.ts +2 -0
  111. package/dist/types/components/internal/icons/IconVietqrComplete.d.ts +2 -0
  112. package/dist/types/components/internal/icons/index.d.ts +6 -0
  113. package/dist/types/components/wallets/OpayWallet/OpayWallet.d.ts +10 -0
  114. package/dist/types/components/wallets/OpayWallet/index.d.ts +2 -0
  115. package/dist/types/components/wallets/OpayWallet/type.d.ts +40 -0
  116. package/dist/types/components/wallets/PagaWallet/PagaWallet.d.ts +10 -0
  117. package/dist/types/components/wallets/PagaWallet/index.d.ts +2 -0
  118. package/dist/types/components/wallets/PagaWallet/type.d.ts +40 -0
  119. package/dist/types/components/wallets/PicPay/PicPay.d.ts +10 -0
  120. package/dist/types/components/wallets/PicPay/index.d.ts +2 -0
  121. package/dist/types/components/wallets/PicPay/type.d.ts +40 -0
  122. package/dist/types/components/wallets/Pix/Pix.d.ts +10 -0
  123. package/dist/types/components/wallets/Pix/index.d.ts +2 -0
  124. package/dist/types/components/wallets/Pix/type.d.ts +40 -0
  125. package/dist/types/components/wallets/Vietqr/Vietqr.d.ts +10 -0
  126. package/dist/types/components/wallets/Vietqr/index.d.ts +2 -0
  127. package/dist/types/components/wallets/Vietqr/type.d.ts +39 -0
  128. package/dist/types/components/wallets/index.d.ts +8 -0
  129. package/dist/types/components/wallets/type.d.ts +9 -0
  130. package/dist/types/constant.d.ts +11 -1
  131. package/dist/types/core/checkout.d.ts +4 -0
  132. package/dist/types/core/index.d.ts +1 -0
  133. package/dist/types/core/session.d.ts +1 -11
  134. package/dist/types/core/theme.d.ts +7 -0
  135. package/dist/types/i18n/locales/de-DE.d.ts +6 -0
  136. package/dist/types/i18n/locales/en-GB.d.ts +6 -0
  137. package/dist/types/i18n/locales/es-ES.d.ts +6 -0
  138. package/dist/types/i18n/locales/fr-FR.d.ts +6 -0
  139. package/dist/types/i18n/locales/ja-JP.d.ts +6 -0
  140. package/dist/types/i18n/locales/ko-KR.d.ts +6 -0
  141. package/dist/types/i18n/locales/nl-NL.d.ts +6 -0
  142. package/dist/types/i18n/locales/pt-PT.d.ts +6 -0
  143. package/dist/types/i18n/locales/ru-RU.d.ts +6 -0
  144. package/dist/types/i18n/locales/zh-CN.d.ts +6 -0
  145. package/dist/types/i18n/locales/zh-HK.d.ts +6 -0
  146. package/dist/types/i18n/locales/zh-TW.d.ts +6 -0
  147. package/dist/types/types/message.d.ts +29 -25
  148. package/dist/types/utils/index.d.ts +3 -2
  149. package/dist/types/utils/object.d.ts +7 -0
  150. package/dist/types/utils/string.d.ts +1 -0
  151. package/dist/types/utils/style.d.ts +1 -1
  152. package/dist/types/utils/system-info/is-ua-webview.d.ts +1 -1
  153. package/dist/types/utils/theme.d.ts +4 -0
  154. package/package.json +67 -67
  155. package/dist/es/utils/deep-freeze.js +0 -13
  156. package/dist/es/utils/obj.js +0 -22
  157. package/dist/types/utils/deep-freeze.d.ts +0 -1
  158. package/dist/types/utils/obj.d.ts +0 -6
@@ -0,0 +1,49 @@
1
+ import { u } from "../../../core.js";
2
+ import { COMMON_CLASS_NAME } from "../../../constant.js";
3
+ import { isUndefined } from "../../../utils/is.js";
4
+ import "../../../utils/card-brand/brands.js";
5
+ import "../../../utils/system-info/get-browser-info.js";
6
+ import { normalizedClass } from "../../../utils/format.js";
7
+ const IconVietqrComplete = ({ size, style, className }) => {
8
+ const computedSize = !isUndefined(size) ? `${size}px` : "1em";
9
+ return /* @__PURE__ */ u(
10
+ "svg",
11
+ {
12
+ height: computedSize,
13
+ viewBox: "0 0 77 22",
14
+ fill: "none",
15
+ xmlns: "http://www.w3.org/2000/svg",
16
+ style,
17
+ className: normalizedClass(COMMON_CLASS_NAME, className),
18
+ children: /* @__PURE__ */ u("g", { xmlns: "http://www.w3.org/2000/svg", id: "logo-VietQR", children: [
19
+ /* @__PURE__ */ u(
20
+ "path",
21
+ {
22
+ id: "path1",
23
+ d: "M10.798 21.8011C10.2713 21.6258 9.92445 21.4398 9.51047 21.0935C9.13497 20.8125 8.82283 20.3898 8.58211 19.9999C6.58712 16.4803 4.52893 12.9969 2.52683 9.4811C2.28976 9.07466 1.26256 7.29508 0.801223 6.51513C0.351537 5.75394 0.270564 5.55668 0.138788 5.10282C0.0865695 4.92296 0.00275196 4.66219 8.93571e-05 4.09555C-0.00238938 3.56806 0.046983 3.28128 0.113112 3.01017C0.4046 1.81511 1.28694 0.788727 2.45017 0.291579C2.96712 0.0706408 3.52514 -0.0205173 4.21107 0.00391868C4.56416 0.0164973 4.72437 0.0356746 4.95213 0.092622C5.89029 0.327189 6.65462 0.779213 7.11183 1.36988C8.52669 3.62088 9.81845 5.9492 11.1486 8.25161C11.765 9.32109 12.0955 9.87917 12.1037 9.86442C12.2418 9.61696 12.3997 9.36151 12.5446 9.11171C12.8238 8.63128 13.493 7.47445 14.512 5.71056C16.8347 1.6902 16.7861 1.77241 16.9975 1.49804C17.3525 1.03702 17.9119 0.598431 18.4643 0.347953C19.2855 -0.0243857 19.9489 -0.00467975 20.2879 0.00586032C20.8063 0.0219726 21.0952 0.0713712 21.5093 0.214722C22.3388 0.501889 23.0363 1.13226 23.3835 1.59717C23.55 1.82022 23.7175 2.11689 23.8495 2.42272C24.0675 2.92795 24.1515 3.36487 24.1522 3.99813C24.1532 4.90633 23.979 5.45778 23.3622 6.49931C20.8029 10.9425 18.2032 15.3628 15.687 19.8308C15.2117 20.7003 14.6698 21.1934 13.9016 21.5716C13.3177 21.859 12.8678 22.0009 12.0772 22.0001C11.3629 21.9993 11.16 21.9216 10.798 21.8011ZM25.527 21.8387C25.204 21.7478 24.9584 21.5724 24.7903 21.3125C24.5815 20.9898 24.5975 21.51 24.5987 15.0703C24.5997 9.45742 24.6014 9.27379 24.6525 9.13928C24.7348 8.92285 24.8333 8.77278 24.9878 8.6284C25.1402 8.48603 25.3775 8.35971 25.4935 8.35927C25.5326 8.35913 25.579 8.34469 25.5965 8.32721C25.6457 8.27805 26.2019 8.28727 26.3786 8.34018C26.7373 8.44757 27.0554 8.69809 27.2019 8.98856C27.3702 9.32243 27.3617 8.99639 27.3612 15.0971C27.3607 21.1969 27.3697 20.8636 27.1949 21.2096C27.0465 21.5034 26.8029 21.6996 26.4436 21.8148C26.254 21.8756 25.7085 21.8898 25.527 21.8387ZM43.7925 21.8085C43.328 21.659 43.0049 21.2714 42.9342 20.7788C42.9167 20.6565 42.9027 18.7965 42.8967 15.7963C42.8915 13.1632 42.8817 11.004 42.8749 10.998C42.8681 10.992 42.3143 10.9794 41.6444 10.97C40.2763 10.9508 40.2604 10.9485 39.9986 10.736C39.7255 10.5144 39.5839 10.212 39.5627 9.80499C39.5286 9.15071 39.8164 8.69 40.4001 8.46418C40.5448 8.4082 40.5882 8.40762 44.2717 8.41249C46.777 8.4158 48.0333 8.42704 48.1081 8.44679C48.3815 8.51903 48.7011 8.75713 48.838 8.99048C49.0625 9.37323 49.0776 9.97117 48.8729 10.372C48.7843 10.5455 48.5612 10.7655 48.3877 10.8504C48.1275 10.9777 48.0031 10.9871 46.8209 10.9688C45.8419 10.9537 45.7268 10.9565 45.7117 10.9959C45.7024 11.0201 45.6948 13.2254 45.6948 15.8965C45.6948 21.1876 45.7035 20.8912 45.5392 21.2151C45.4332 21.4241 45.2388 21.6176 45.0415 21.7105C44.6581 21.891 44.1684 21.9294 43.7925 21.8085ZM30.2153 21.727C29.9918 21.6646 29.7952 21.5541 29.6306 21.3986C29.4405 21.219 29.3279 21.0218 29.2582 20.7461C29.2039 20.5317 29.2031 20.4285 29.2101 14.8546L29.2173 9.18141L29.2916 9.02319C29.437 8.71317 29.734 8.4799 30.0563 8.4225C30.1328 8.40887 31.9419 8.40189 34.1285 8.40679C37.6102 8.41459 38.0805 8.42066 38.2156 8.45956C38.7771 8.62124 39.0825 9.05159 39.0808 9.67873C39.08 9.97948 39.0509 10.1232 38.9482 10.3326C38.7881 10.6593 38.4909 10.8851 38.1327 10.9523C37.9821 10.9805 34.3735 10.9695 33.037 10.9368C32.6756 10.9279 32.4194 10.9331 32.3745 10.9502C32.3336 10.9657 32.2744 10.968 32.2404 10.9554C32.2016 10.9411 32.1506 10.9473 32.1003 10.9724L32.0212 11.0118L32.0284 12.3687L32.0357 13.7256L34.9796 13.7397C38.2297 13.7553 38.0303 13.7437 38.3258 13.9332C38.7611 14.2123 38.9674 14.6802 38.8888 15.2102C38.8105 15.7376 38.4425 16.1561 37.9528 16.2745C37.8494 16.2995 37.0973 16.3064 34.9505 16.3018C33.3751 16.2984 32.0717 16.3046 32.054 16.3156C32.0302 16.3302 32.0217 16.7147 32.0217 17.7691V19.2027L35.1973 19.2102L38.3729 19.2176L38.5828 19.3213C38.8427 19.4496 39.0495 19.6596 39.1735 19.9213C39.2592 20.102 39.2629 20.1239 39.2629 20.4582C39.2629 20.8024 39.2616 20.8093 39.1599 21.0222C39.0448 21.2629 38.8586 21.4794 38.6734 21.5878C38.6057 21.6275 38.4469 21.6861 38.3206 21.7182C38.0957 21.7753 38.0614 21.776 36.6957 21.7522C35.2349 21.7267 33.7253 21.7268 31.6171 21.7525C30.5655 21.7653 30.3377 21.7612 30.2153 21.727ZM31.3799 8.70622C31.3799 8.70115 31.3557 8.69883 31.326 8.70106C31.2964 8.70329 31.278 8.7145 31.2851 8.72598C31.2969 8.74504 31.3799 8.72774 31.3799 8.70622ZM31.7985 8.71046C31.7985 8.70443 31.779 8.69203 31.7552 8.6829C31.7303 8.67338 31.7191 8.67805 31.7289 8.69385C31.7453 8.72034 31.7985 8.73304 31.7985 8.71046Z",
24
+ fill: "#E7222D"
25
+ }
26
+ ),
27
+ /* @__PURE__ */ u(
28
+ "path",
29
+ {
30
+ id: "path2",
31
+ d: "M55.1925 21.92C53.8843 21.7615 52.6378 21.2664 51.6259 20.5033C51.0596 20.0763 50.3657 19.3185 50.0018 18.7297C49.3431 17.664 49.0164 16.459 49.0156 15.0914C49.0148 13.8128 49.3317 12.6021 49.9277 11.6057C50.7628 10.2098 52.011 9.20998 53.6295 8.64053C55.0053 8.15652 56.9498 8.08879 58.4191 8.47369C60.3524 8.98013 61.9394 10.215 62.8254 11.9022C63.1681 12.5548 63.3805 13.205 63.5031 13.9765C63.5564 14.3126 63.565 14.4751 63.5646 15.1473C63.5642 15.8695 63.5587 15.9582 63.4905 16.3322C63.2817 17.4773 62.8774 18.4001 62.1908 19.2988C62.0732 19.4528 61.8921 19.6654 61.7885 19.7713C61.6072 19.9566 61.5712 20.0188 61.6256 20.0524C61.6396 20.0611 61.7037 20.1638 61.7679 20.2808C61.8322 20.3977 62.0404 20.7617 62.2308 21.0896C62.4211 21.4175 62.5768 21.7013 62.5768 21.7202C62.5768 21.747 62.2641 21.7534 61.1478 21.7496L59.7188 21.7446L59.5759 21.4987C59.4973 21.3634 59.1973 20.845 58.9092 20.3466C58.6211 19.8483 58.2752 19.2524 58.1405 19.0224C57.9022 18.6154 57.3307 17.6229 56.4889 16.1538C56.2613 15.7567 56.0751 15.4306 56.0751 15.429C56.0751 15.4274 56.7248 15.4281 57.5189 15.4304C58.6954 15.434 58.9667 15.4417 58.9845 15.4723C58.9966 15.4929 59.1804 15.8108 59.393 16.1788C59.9347 17.1167 59.9375 17.1213 59.9749 17.1337C60.0445 17.1569 60.2761 16.5173 60.3711 16.0395C60.7339 14.2145 60.0272 12.4194 58.5808 11.4918C57.7968 10.989 56.7589 10.7563 55.8101 10.8705C54.5528 11.0219 53.5085 11.6432 52.8623 12.6244C52.4492 13.2516 52.2436 13.8512 52.1557 14.6854C52.0513 15.6769 52.3057 16.7396 52.8448 17.5648C53.3753 18.3765 54.2187 18.9722 55.1857 19.2182C55.5582 19.3129 55.7949 19.3425 56.2014 19.345C56.5457 19.3471 56.5516 19.3482 56.599 19.4196C56.6255 19.4594 56.9493 20.0136 57.3185 20.6511L57.9898 21.8103L57.8487 21.8442C57.3598 21.9618 55.8849 22.0039 55.1925 21.92ZM64.9975 21.7528C64.986 21.741 64.9766 18.7476 64.9766 15.1009V8.47049L68.2344 8.47074C71.6501 8.47102 71.7734 8.47473 72.4299 8.59758C73.7077 8.83668 74.8707 9.48307 75.5587 10.3365C76.2858 11.2385 76.58 12.286 76.5004 13.6892C76.4711 14.2054 76.3972 14.5742 76.2363 15.0082C76.0165 15.6012 75.7694 15.978 75.2746 16.4747C74.871 16.8798 74.5141 17.1414 74.0525 17.3702C73.9259 17.4329 73.8223 17.4958 73.8223 17.5099C73.8223 17.524 73.8643 17.5878 73.9157 17.6517C73.9671 17.7156 74.1391 17.9561 74.2979 18.1861C74.7976 18.9097 75.2065 19.4954 76.3609 21.1412C76.5653 21.4325 76.7376 21.6897 76.7438 21.7127C76.7538 21.7496 76.5594 21.7539 75.1003 21.749L73.4456 21.7436L71.5429 19.003C70.4964 17.4957 69.5192 16.0868 69.3714 15.8722C69.2235 15.6575 68.9458 15.2561 68.7543 14.9801C68.5627 14.7041 68.3953 14.4594 68.3823 14.4364C68.3613 14.3995 68.5499 14.3946 70.0086 14.3946H71.6586L71.9522 14.8189C72.1136 15.0522 72.2613 15.2435 72.2805 15.244C72.3977 15.2471 72.8814 14.8124 73.055 14.548C73.3028 14.1707 73.3833 13.8593 73.3869 13.2656C73.3892 12.8922 73.3808 12.8032 73.3251 12.6108C73.0637 11.7068 72.4545 11.2211 71.3253 11.016C71.0255 10.9615 68.1464 10.931 68.0854 10.9817C68.0518 11.0095 68.0461 11.7988 68.0461 16.3774V21.7406H66.6968C65.9547 21.7406 65.2735 21.7482 65.183 21.7574C65.0925 21.7667 65.009 21.7646 64.9975 21.7528Z",
32
+ fill: "#22447B"
33
+ }
34
+ ),
35
+ /* @__PURE__ */ u(
36
+ "path",
37
+ {
38
+ id: "path3",
39
+ d: "M8.56249 11.6472C7.79974 11.5294 7.31519 11.3389 6.80457 10.9561C6.55858 10.7717 6.03688 10.2 5.77374 9.82653C4.66699 8.12241 3.69272 6.33375 2.68332 4.57079C2.22379 3.74081 2.15786 3.537 2.16022 2.95389C2.16206 2.49824 2.21217 2.23574 2.3862 1.83486C2.53686 1.48783 2.68318 1.27272 2.98345 0.978366C3.36395 0.605367 3.57096 0.51728 4.04888 0.368012C4.31669 0.284365 4.54819 0.26924 4.86424 0.271585C5.20822 0.274133 5.67159 0.230133 6.40409 0.7126C7.00298 1.10707 7.18193 1.34246 7.89432 2.57754C9.14851 4.74421 10.3988 6.91316 11.6546 9.07889L12.1025 9.85141L12.0235 10.0128C11.98 10.1015 11.8604 10.2668 11.7576 10.3801C11.358 10.8206 11.0179 11.0683 10.3661 11.3932C10.163 11.4944 9.77574 11.59 9.43258 11.6476C9.2492 11.6783 8.74109 11.6748 8.56249 11.6472Z",
40
+ fill: "#9E2D1F"
41
+ }
42
+ )
43
+ ] })
44
+ }
45
+ );
46
+ };
47
+ export {
48
+ IconVietqrComplete
49
+ };
@@ -4,7 +4,7 @@ import { CoreContext } from "../../../core/context.js";
4
4
  import "../../../utils/card-brand/brands.js";
5
5
  import "../../../utils/system-info/get-browser-info.js";
6
6
  import { isMobile } from "../../../utils/system-info/get-system-info.js";
7
- import { cssVarPrefix, normalizedClass, formatAmount } from "../../../utils/format.js";
7
+ import { normalizedClass, formatAmount } from "../../../utils/format.js";
8
8
  import { redirectToPayment } from "../../../utils/redirect.js";
9
9
  import { formatPaymentResult } from "../../../utils/payment.js";
10
10
  import { isTimeoutError } from "../../../api/http.js";
@@ -29,7 +29,7 @@ import "./g-cash.js";
29
29
  const { bem } = useBEM("gcash");
30
30
  const fieldClassNames = bem("field");
31
31
  const GCash = w((props, ref) => {
32
- var _a, _b, _c, _d, _e, _f, _g;
32
+ var _a;
33
33
  const {
34
34
  session,
35
35
  showEmail = false,
@@ -110,9 +110,9 @@ const GCash = w((props, ref) => {
110
110
  setFieldStatus({ ...field });
111
111
  };
112
112
  const processOnSuccess = (res) => {
113
- var _a2, _b2;
113
+ var _a2, _b;
114
114
  setSubmitButtonStatus("success");
115
- (_b2 = props.onSuccess) == null ? void 0 : _b2.call(props, formatPaymentResult({
115
+ (_b = props.onSuccess) == null ? void 0 : _b.call(props, formatPaymentResult({
116
116
  ...res,
117
117
  returnUrl: (_a2 = session == null ? void 0 : session.checkout) == null ? void 0 : _a2.returnUrl
118
118
  }));
@@ -180,12 +180,12 @@ const GCash = w((props, ref) => {
180
180
  };
181
181
  };
182
182
  const pay = async (search = false, timeout) => {
183
- var _a2, _b2, _c2, _d2, _e2, _f2, _g2;
183
+ var _a2, _b, _c, _d, _e, _f, _g;
184
184
  try {
185
185
  const requestOptions = { locale: i18n.locale, timeout };
186
186
  let res = null;
187
187
  if (search) {
188
- const extraParams = (_b2 = (_a2 = core.config)._getExtraParams) == null ? void 0 : _b2.call(_a2, "query", PaymentMethod.GCASH);
188
+ const extraParams = (_b = (_a2 = core.config)._getExtraParams) == null ? void 0 : _b.call(_a2, "query", PaymentMethod.GCASH);
189
189
  res = await getGcashPayInfo(
190
190
  {
191
191
  sessionId: session.sessionId,
@@ -196,10 +196,10 @@ const GCash = w((props, ref) => {
196
196
  requestOptions
197
197
  );
198
198
  } else {
199
- const extraParams = (_d2 = (_c2 = core.config)._getExtraParams) == null ? void 0 : _d2.call(_c2, "payment", PaymentMethod.GCASH);
199
+ const extraParams = (_d = (_c = core.config)._getExtraParams) == null ? void 0 : _d.call(_c, "payment", PaymentMethod.GCASH);
200
200
  res = await gcashPay(await getPaymentParams(), extraParams, requestOptions);
201
201
  }
202
- !search && ((_e2 = props.onSubmitResponse) == null ? void 0 : _e2.call(props, res));
202
+ !search && ((_e = props.onSubmitResponse) == null ? void 0 : _e.call(props, res));
203
203
  const { status, orderStatus, errorMessage, errorCode, payInfo = {}, sessionId } = res;
204
204
  const { paymentExpiredAt } = payInfo;
205
205
  sessionId && (session.sessionId = sessionId);
@@ -237,7 +237,7 @@ const GCash = w((props, ref) => {
237
237
  return { end: false };
238
238
  } else if (orderStatus === "CANCELED") {
239
239
  setSubmitButtonStatus("unSubmit");
240
- (_f2 = props.onTimeout) == null ? void 0 : _f2.call(props);
240
+ (_f = props.onTimeout) == null ? void 0 : _f.call(props);
241
241
  core.resetEnablePaymentMethod();
242
242
  return { end: true };
243
243
  }
@@ -248,7 +248,7 @@ const GCash = w((props, ref) => {
248
248
  } else if (status === "EXPIRED") {
249
249
  setShowQRCodeModal(false);
250
250
  setSubmitButtonStatus("unSubmit");
251
- (_g2 = props.onExpired) == null ? void 0 : _g2.call(props);
251
+ (_g = props.onExpired) == null ? void 0 : _g.call(props);
252
252
  return { end: true };
253
253
  }
254
254
  setSubmitButtonStatus("unSubmit");
@@ -337,24 +337,17 @@ const GCash = w((props, ref) => {
337
337
  }
338
338
  ) }) });
339
339
  };
340
- const formStyle = {
341
- [cssVarPrefix("button-bg-color")]: (_a = session == null ? void 0 : session.colors) == null ? void 0 : _a.primary,
342
- [cssVarPrefix("button-bg-color-hover")]: (_b = session == null ? void 0 : session.colors) == null ? void 0 : _b.primaryHover,
343
- [cssVarPrefix("button-bg-color-active")]: (_c = session == null ? void 0 : session.colors) == null ? void 0 : _c.primaryActive,
344
- [cssVarPrefix("button-text-color")]: (_e = (_d = session == null ? void 0 : session.checkout) == null ? void 0 : _d.theme) == null ? void 0 : _e.payButtonTextColor,
345
- [cssVarPrefix("input-color")]: (_f = session == null ? void 0 : session.colors) == null ? void 0 : _f.primary
346
- };
347
340
  const ErrorMessage = () => {
348
- return /* @__PURE__ */ u(b, { children: !!errorMsg && /* @__PURE__ */ u(Info, { content: errorMsg, style: { marginTop: "12px" } }) });
341
+ return /* @__PURE__ */ u(b, { children: !!errorMsg && /* @__PURE__ */ u(Info, { content: errorMsg }) });
349
342
  };
350
343
  const Address = () => {
351
- var _a2, _b2;
344
+ var _a2, _b;
352
345
  return /* @__PURE__ */ u(b, { children: (fieldStatus == null ? void 0 : fieldStatus.address.show) && /* @__PURE__ */ u("div", { className: fieldClassNames, children: /* @__PURE__ */ u(
353
346
  AddressField,
354
347
  {
355
348
  ref: addressFieldRef,
356
349
  value: form.address,
357
- country: ((_a2 = session == null ? void 0 : session.checkout) == null ? void 0 : _a2.country) || ((_b2 = session == null ? void 0 : session.checkout) == null ? void 0 : _b2.bill.country),
350
+ country: ((_a2 = session == null ? void 0 : session.checkout) == null ? void 0 : _a2.country) || ((_b = session == null ? void 0 : session.checkout) == null ? void 0 : _b.bill.country),
358
351
  onAddressChange: (value) => setForm(Object.assign(form, { address: value }))
359
352
  }
360
353
  ) }) });
@@ -367,13 +360,15 @@ const GCash = w((props, ref) => {
367
360
  session,
368
361
  core
369
362
  },
370
- children: isCheckoutEnabled && i18n.ready.value && /* @__PURE__ */ u(b, { children: [
363
+ children: isCheckoutEnabled && i18n.ready.value && /* @__PURE__ */ u("div", { className: core.theme.className, children: [
371
364
  showGuideCard && /* @__PURE__ */ u(GuideCard, { type: PaymentCategory.GCASH }),
372
- /* @__PURE__ */ u(Form, { form, ref: setFormRef, onFormChange: (form2) => setForm(form2), children: /* @__PURE__ */ u("div", { className: normalizedClass(COMMON_CLASS_NAME, bem()), style: formStyle, children: [
365
+ /* @__PURE__ */ u(Form, { form, ref: setFormRef, onFormChange: (form2) => setForm(form2), children: /* @__PURE__ */ u("div", { className: normalizedClass(COMMON_CLASS_NAME, bem()), children: [
373
366
  Email(),
374
367
  Address(),
375
- ErrorMessage(),
376
- !hidePaymentButton && Button()
368
+ /* @__PURE__ */ u("div", { className: bem("footer-wrapper"), children: [
369
+ ErrorMessage(),
370
+ !hidePaymentButton && Button()
371
+ ] })
377
372
  ] }) }),
378
373
  showQRCodeModal && /* @__PURE__ */ u(
379
374
  QRCodeModal,
@@ -383,7 +378,7 @@ const GCash = w((props, ref) => {
383
378
  textColor: "#FFFFFF",
384
379
  qrCode: qrCodeInfo.qrCode,
385
380
  icon: /* @__PURE__ */ u(IconGcashComplete, { size: 22 }),
386
- amount: (_g = session == null ? void 0 : session.checkout) == null ? void 0 : _g.transAmount,
381
+ amount: (_a = session == null ? void 0 : session.checkout) == null ? void 0 : _a.transAmount,
387
382
  expiredTime: qrCodeInfo.expiredTime,
388
383
  onClose: handleCloseQRCodeModal
389
384
  }
@@ -0,0 +1,346 @@
1
+ import { w, F, A, h, y, q, u, b } from "../../../core.js";
2
+ import { useBEM } from "../../../hooks/useBEM.js";
3
+ import { CoreContext } from "../../../core/context.js";
4
+ import "../../../utils/card-brand/brands.js";
5
+ import "../../../utils/system-info/get-browser-info.js";
6
+ import { normalizedClass, formatAmount } from "../../../utils/format.js";
7
+ import { redirectToPayment } from "../../../utils/redirect.js";
8
+ import { formatPaymentResult } from "../../../utils/payment.js";
9
+ import { isTimeoutError } from "../../../api/http.js";
10
+ import { getBrowserParams } from "../../../api/modules/get-browser-params.js";
11
+ import { PaymentCategory, COMMON_CLASS_NAME, PaymentMethod, SessionMode } from "../../../constant.js";
12
+ import { getOpayWalletPayInfo, opayWalletPay } from "../../../api/modules/opay-wallet/index.js";
13
+ import { PayKKaError } from "../../../core/error.js";
14
+ import { usePayState } from "../../../hooks/usePayState.js";
15
+ import { useRetry } from "../../../hooks/useRetry.js";
16
+ import { createEmailCore, EmailField } from "../../EmailField/EmailField.js";
17
+ import { SubmitButton } from "../../SubmitButton/index.js";
18
+ import { GuideCard } from "../../GuideCard/index.js";
19
+ import { AddressField } from "../../AddressField/index.js";
20
+ import { Info } from "../../internal/Info/Info.js";
21
+ import "../../internal/Form/type.js";
22
+ import "../../internal/Form/context.js";
23
+ import "../../internal/Form/FormItem.js";
24
+ import { Form } from "../../internal/Form/Form.js";
25
+ import "./opay-wallet.js";
26
+ const { bem } = useBEM("opay-wallet");
27
+ const fieldClassNames = bem("field");
28
+ const OpayWallet = w((props, ref) => {
29
+ const {
30
+ session,
31
+ showEmail = false,
32
+ showAddress = false,
33
+ core,
34
+ redirectMode = "auto",
35
+ autoQuery = true,
36
+ showGuideCard = true,
37
+ hidePaymentButton = false
38
+ } = props;
39
+ F(ref, () => ({
40
+ stopRetry: () => {
41
+ setSubmitButtonStatus("unSubmit");
42
+ stopReFetchPayInfo();
43
+ },
44
+ startRetry: (timeout) => {
45
+ setSubmitButtonStatus("loading");
46
+ startReFetchPayInfo({ timeout });
47
+ },
48
+ updateAddress: () => {
49
+ var _a;
50
+ if (!(fieldStatus == null ? void 0 : fieldStatus.address.show))
51
+ return;
52
+ const newForm = Object.assign(form, { address: addressCore.getAddressState() });
53
+ setForm(newForm);
54
+ (_a = addressFieldRef.current) == null ? void 0 : _a.update(addressCore.getAddressState());
55
+ validateForm();
56
+ },
57
+ updateEmail: () => {
58
+ var _a;
59
+ if (!(fieldStatus == null ? void 0 : fieldStatus.email.show))
60
+ return;
61
+ const newForm = Object.assign(form, { email: emailState.email });
62
+ setForm(newForm);
63
+ (_a = emailFieldRef.current) == null ? void 0 : _a.update(emailState.email);
64
+ validateForm();
65
+ },
66
+ payment: () => {
67
+ hidePaymentButton && onSubmit();
68
+ }
69
+ }));
70
+ const addressCore = core.getAddressCore();
71
+ const emailState = createEmailCore();
72
+ const addressFieldRef = A(null);
73
+ const emailFieldRef = A(null);
74
+ const [isCheckoutEnabled, setIsCheckoutEnabled] = h(false);
75
+ const { setErrorMsg, i18n, errorMsg, sessionReady } = usePayState(session, props.core);
76
+ const [submitButtonStatus, setSubmitButtonStatus] = h("unSubmit");
77
+ const formRef = A(null);
78
+ const [form, setForm] = h({
79
+ email: "",
80
+ address: {
81
+ country: void 0,
82
+ province: void 0,
83
+ city: void 0,
84
+ area: void 0,
85
+ postCode: void 0,
86
+ address1: void 0,
87
+ address2: void 0
88
+ }
89
+ });
90
+ const [validated, setValidated] = h(false);
91
+ const [fieldStatus, setFieldStatus] = h();
92
+ const initFieldStatus = () => {
93
+ const { field, sessionMode } = session.checkout;
94
+ const { email, address } = field;
95
+ if (sessionMode === SessionMode.COMPONENT) {
96
+ if (email.disabled) {
97
+ email.show = showEmail;
98
+ }
99
+ if (showAddress && !(address == null ? void 0 : address.show)) {
100
+ address.show = true;
101
+ }
102
+ }
103
+ setFieldStatus({ ...field });
104
+ };
105
+ const processOnSuccess = (res) => {
106
+ var _a, _b;
107
+ setSubmitButtonStatus("success");
108
+ (_b = props.onSuccess) == null ? void 0 : _b.call(props, formatPaymentResult({
109
+ ...res,
110
+ returnUrl: (_a = session == null ? void 0 : session.checkout) == null ? void 0 : _a.returnUrl
111
+ }));
112
+ };
113
+ y(() => {
114
+ if (!sessionReady) {
115
+ return;
116
+ }
117
+ const { bill = {}, supportMethods = [], country } = (session == null ? void 0 : session.checkout) || {};
118
+ if (!supportMethods.includes(PaymentMethod.OPAY_WALLET)) {
119
+ return;
120
+ }
121
+ initFieldStatus();
122
+ setIsCheckoutEnabled(true);
123
+ country && addressCore.setCountry(country);
124
+ form.email = bill.email ?? "";
125
+ form.address.country = country;
126
+ if (autoQuery && core.processingPaymentMethod === PaymentMethod.OPAY_WALLET) {
127
+ setSubmitButtonStatus("loading");
128
+ startReFetchPayInfo();
129
+ }
130
+ }, [sessionReady]);
131
+ const processOnError = (error) => {
132
+ var _a;
133
+ (_a = props.onError) == null ? void 0 : _a.call(props, error);
134
+ core.resetEnablePaymentMethod();
135
+ };
136
+ const onTimeout = q(
137
+ (message) => {
138
+ var _a;
139
+ setErrorMsg(message || i18n.get("common.payTimeout"));
140
+ setSubmitButtonStatus("unSubmit");
141
+ (_a = props.onTimeout) == null ? void 0 : _a.call(props);
142
+ core.resetEnablePaymentMethod();
143
+ },
144
+ [i18n, props.onTimeout]
145
+ );
146
+ const { start: startReFetchPayInfo, stop: stopReFetchPayInfo } = useRetry(
147
+ (timeout) => pay(true, timeout),
148
+ { onTimeout: () => onTimeout(i18n.get("common.queryTimeout")) }
149
+ );
150
+ const getPaymentParams = async () => {
151
+ return {
152
+ sessionId: session.sessionId,
153
+ clientKey: session.clientKey,
154
+ payment: {
155
+ paymentMethod: PaymentMethod.OPAY_WALLET
156
+ },
157
+ bill: {
158
+ email: form.email,
159
+ addressLine1: form.address.address1,
160
+ addressLine2: form.address.address2,
161
+ postalCode: form.address.postCode,
162
+ country: form.address.country,
163
+ district: form.address.area,
164
+ state: form.address.province ? addressCore.getLabel(form.address.province, addressCore.getProvinceOption()) ?? form.address.province : void 0,
165
+ city: form.address.city ? addressCore.getLabel(form.address.city, addressCore.getCityOptions()) ?? form.address.city : void 0
166
+ },
167
+ browser: await getBrowserParams()
168
+ };
169
+ };
170
+ const pay = async (search = false, timeout) => {
171
+ var _a, _b, _c, _d, _e, _f, _g;
172
+ try {
173
+ const requestOptions = { locale: i18n.locale, timeout };
174
+ let res = null;
175
+ if (search) {
176
+ const extraParams = (_b = (_a = core.config)._getExtraParams) == null ? void 0 : _b.call(_a, "query", PaymentMethod.OPAY_WALLET);
177
+ res = await getOpayWalletPayInfo(
178
+ {
179
+ sessionId: session.sessionId,
180
+ clientKey: session.clientKey,
181
+ paymentMethod: PaymentMethod.OPAY_WALLET
182
+ },
183
+ extraParams,
184
+ requestOptions
185
+ );
186
+ } else {
187
+ const extraParams = (_d = (_c = core.config)._getExtraParams) == null ? void 0 : _d.call(_c, "payment", PaymentMethod.OPAY_WALLET);
188
+ res = await opayWalletPay(await getPaymentParams(), extraParams, requestOptions);
189
+ }
190
+ !search && ((_e = props.onSubmitResponse) == null ? void 0 : _e.call(props, res));
191
+ const { status, orderStatus, errorMessage, errorCode, payInfo, sessionId } = res;
192
+ sessionId && (session.sessionId = sessionId);
193
+ if (status === "PROCESSING") {
194
+ if (!orderStatus) {
195
+ setSubmitButtonStatus("unSubmit");
196
+ return { end: true };
197
+ } else if (orderStatus === "SUCCESS") {
198
+ processOnSuccess(res);
199
+ return { end: true };
200
+ } else if (orderStatus === "FAILURE") {
201
+ errorMessage && setErrorMsg(errorMessage);
202
+ setSubmitButtonStatus("unSubmit");
203
+ processOnError(new PayKKaError("API_ERROR", errorMessage, { code: errorCode }));
204
+ return { end: true };
205
+ } else if (orderStatus === "PROCESSING") {
206
+ if (!search) {
207
+ if (redirectMode === "auto" && payInfo) {
208
+ redirectToPayment(payInfo);
209
+ return { end: true };
210
+ } else {
211
+ startReFetchPayInfo();
212
+ }
213
+ }
214
+ return { end: false };
215
+ } else if (orderStatus === "CANCELED") {
216
+ setSubmitButtonStatus("unSubmit");
217
+ (_f = props.onTimeout) == null ? void 0 : _f.call(props);
218
+ core.resetEnablePaymentMethod();
219
+ return { end: true };
220
+ }
221
+ } else if (status === "SUCCESS") {
222
+ processOnSuccess(res);
223
+ return { end: true };
224
+ } else if (status === "EXPIRED") {
225
+ setSubmitButtonStatus("unSubmit");
226
+ (_g = props.onExpired) == null ? void 0 : _g.call(props);
227
+ return { end: true };
228
+ }
229
+ setSubmitButtonStatus("unSubmit");
230
+ return { end: true };
231
+ } catch (error) {
232
+ if (isTimeoutError(error)) {
233
+ if (search) {
234
+ return { end: false };
235
+ } else {
236
+ onTimeout();
237
+ return { end: true };
238
+ }
239
+ } else {
240
+ const message = error.i18nKey ? i18n.get(error.i18nKey) : error.message;
241
+ message && setErrorMsg(message);
242
+ processOnError(new PayKKaError("API_ERROR", message, { code: error.code, cause: error }));
243
+ setSubmitButtonStatus("unSubmit");
244
+ return { end: true };
245
+ }
246
+ }
247
+ };
248
+ const validateForm = () => {
249
+ var _a;
250
+ (_a = formRef.current) == null ? void 0 : _a.validate(void 0, false).then(() => {
251
+ setValidated(true);
252
+ }).catch(() => {
253
+ setValidated(false);
254
+ });
255
+ };
256
+ y(() => {
257
+ validateForm();
258
+ }, [form]);
259
+ const onSubmit = async () => {
260
+ var _a;
261
+ setErrorMsg("");
262
+ (_a = formRef.current) == null ? void 0 : _a.validate(async (errors) => {
263
+ var _a2;
264
+ (fieldStatus == null ? void 0 : fieldStatus.address.show) && addressCore.setValidateAllFields(true);
265
+ (_a2 = props.onSubmit) == null ? void 0 : _a2.call(props, errors);
266
+ if (errors) {
267
+ setSubmitButtonStatus("unSubmit");
268
+ return;
269
+ }
270
+ setErrorMsg("");
271
+ setSubmitButtonStatus("loading");
272
+ await pay();
273
+ });
274
+ };
275
+ const setFormRef = (dom) => {
276
+ formRef.current = dom;
277
+ dom && validateForm();
278
+ };
279
+ const Button = () => {
280
+ var _a;
281
+ const transAmount = (_a = session == null ? void 0 : session.checkout) == null ? void 0 : _a.transAmount;
282
+ const amountText = (transAmount == null ? void 0 : transAmount.amount) ? formatAmount(transAmount).jointSymbol() : "";
283
+ const text = i18n.get("common.pay") + (amountText ? ` ${amountText}` : "");
284
+ return /* @__PURE__ */ u(
285
+ SubmitButton,
286
+ {
287
+ className: bem("button"),
288
+ status: submitButtonStatus,
289
+ text,
290
+ loadingText: i18n.get("common.payProcessing"),
291
+ successText: i18n.get("common.paySuccess"),
292
+ onClick: onSubmit,
293
+ verified: validated
294
+ }
295
+ );
296
+ };
297
+ const Email = () => {
298
+ return /* @__PURE__ */ u(b, { children: (fieldStatus == null ? void 0 : fieldStatus.email.show) && /* @__PURE__ */ u("div", { className: fieldClassNames, children: /* @__PURE__ */ u(
299
+ EmailField,
300
+ {
301
+ ref: emailFieldRef,
302
+ value: form.email,
303
+ disabled: fieldStatus == null ? void 0 : fieldStatus.email.disabled
304
+ }
305
+ ) }) });
306
+ };
307
+ const ErrorMessage = () => {
308
+ return /* @__PURE__ */ u(b, { children: !!errorMsg && /* @__PURE__ */ u(Info, { content: errorMsg }) });
309
+ };
310
+ const Address = () => {
311
+ var _a, _b;
312
+ return /* @__PURE__ */ u(b, { children: (fieldStatus == null ? void 0 : fieldStatus.address.show) && /* @__PURE__ */ u("div", { className: fieldClassNames, children: /* @__PURE__ */ u(
313
+ AddressField,
314
+ {
315
+ ref: addressFieldRef,
316
+ value: form.address,
317
+ country: ((_a = session == null ? void 0 : session.checkout) == null ? void 0 : _a.country) || ((_b = session == null ? void 0 : session.checkout) == null ? void 0 : _b.bill.country),
318
+ onAddressChange: (value) => setForm(Object.assign(form, { address: value }))
319
+ }
320
+ ) }) });
321
+ };
322
+ return /* @__PURE__ */ u(
323
+ CoreContext.Provider,
324
+ {
325
+ value: {
326
+ i18n,
327
+ session,
328
+ core
329
+ },
330
+ children: isCheckoutEnabled && i18n.ready.value && /* @__PURE__ */ u("div", { className: core.theme.className, children: [
331
+ showGuideCard && /* @__PURE__ */ u(GuideCard, { type: PaymentCategory.OPAY_WALLET }),
332
+ /* @__PURE__ */ u(Form, { form, ref: setFormRef, onFormChange: (form2) => setForm(form2), children: /* @__PURE__ */ u("div", { className: normalizedClass(COMMON_CLASS_NAME, bem()), children: [
333
+ Email(),
334
+ Address(),
335
+ /* @__PURE__ */ u("div", { className: bem("footer-wrapper"), children: [
336
+ ErrorMessage(),
337
+ !hidePaymentButton && Button()
338
+ ] })
339
+ ] }) })
340
+ ] })
341
+ }
342
+ );
343
+ });
344
+ export {
345
+ OpayWallet
346
+ };
@@ -0,0 +1 @@
1
+ import "./OpayWallet.js";