@paypay/mini-app-js-sdk 1.47.0 → 1.50.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (28) hide show
  1. package/dist/mini-app-api.d.ts +2 -1
  2. package/dist/mini-app-js-sdk.browser.js +1 -1
  3. package/dist/mini-app-js-sdk.es.js +2177 -725
  4. package/dist/mini-app-js-sdk.min.css +1 -1
  5. package/dist/model/bridge/getCashbackInformation.d.ts +2 -0
  6. package/dist/model/makePayment.d.ts +22 -14
  7. package/dist/model/miniAppError.d.ts +2 -1
  8. package/dist/model/permission.d.ts +1 -0
  9. package/dist/package/banner-header/index.vue.d.ts +1 -1
  10. package/dist/package/payment-method/Bank.vue.d.ts +14 -5
  11. package/dist/package/payment-method/CreditCard.vue.d.ts +14 -13
  12. package/dist/package/payment-method/PayLaterCC.vue.d.ts +14 -4
  13. package/dist/package/payment-method/SbidBank.vue.d.ts +14 -5
  14. package/dist/package/payment-method/Wallet.vue.d.ts +6 -2
  15. package/dist/package/payment-method/index.d.ts +6 -2
  16. package/dist/types.d.ts +5 -0
  17. package/dist/utils/helper.d.ts +3 -2
  18. package/dist/views/make-payment/Main.vue.d.ts +1 -0
  19. package/dist/views/make-payment/Sheets/Charge/ChoosePaymentMethod.vue.d.ts +10 -1
  20. package/dist/views/make-payment/Sheets/Charge/TopContent.vue.d.ts +10 -1
  21. package/dist/views/make-payment/Sheets/Charge/index.vue.d.ts +230 -36
  22. package/dist/views/make-payment/Sheets/ChoosePayment.vue.d.ts +10 -1
  23. package/dist/views/make-payment/Sheets/MaintenanceInfo.vue.d.ts +20 -0
  24. package/dist/views/make-payment/Sheets/PayMethod.vue.d.ts +10 -1
  25. package/dist/views/make-payment/Sheets/Payment.vue.d.ts +10 -1
  26. package/dist/views/make-payment/hooks/app-hooks.d.ts +116 -22
  27. package/dist/views/topup/App.vue.d.ts +2 -3
  28. package/package.json +5 -4
@@ -85,8 +85,8 @@ function normalizeNativeResponseData(data2) {
85
85
  }
86
86
  class JsBridge {
87
87
  constructor(global2) {
88
- this.version = "1.47.0";
89
- this.revision = "24fba29";
88
+ this.version = "1.50.0";
89
+ this.revision = "d2542c6";
90
90
  this.messageHandlers = new Map();
91
91
  this.responseCallbacks = new Map();
92
92
  this.global = global2;
@@ -214,6 +214,7 @@ var MiniAppErrorType;
214
214
  MiniAppErrorType2["deeplinkUnavailable"] = "DEEPLINK_UNAVAILABLE";
215
215
  MiniAppErrorType2["kycIncompleted"] = "KYC_INCOMPLETED";
216
216
  MiniAppErrorType2["noBankAccount"] = "NO_BANK_ACCOUNT";
217
+ MiniAppErrorType2["invalidPaymentIdentifier"] = "INVALID_PAYMENT_IDENTIFIER";
217
218
  })(MiniAppErrorType || (MiniAppErrorType = {}));
218
219
  class PayPayJsBridgeBase {
219
220
  constructor(jsBridge2) {
@@ -1563,6 +1564,131 @@ function getUserLocationRequest(params) {
1563
1564
  function isValidUrl(urlChallenge) {
1564
1565
  return /^https?:\/\//.test(urlChallenge);
1565
1566
  }
1567
+ async function initAppDetail(accessToken) {
1568
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w;
1569
+ const res = await ppFetch2({
1570
+ method: "GET",
1571
+ url: "web-api/app/v1/apps/detail",
1572
+ headers: { Authorization: `Bearer ${accessToken}` }
1573
+ });
1574
+ if ((res == null ? void 0 : res.ppFetchResult) !== "success" || !((_b = (_a = res == null ? void 0 : res.body) == null ? void 0 : _a.unsigned) == null ? void 0 : _b.data)) {
1575
+ removeAppDetail();
1576
+ return false;
1577
+ }
1578
+ saveAppDetail(JSON.stringify({
1579
+ appLogo: (_e = (_d = (_c = res == null ? void 0 : res.body) == null ? void 0 : _c.unsigned) == null ? void 0 : _d.data) == null ? void 0 : _e.appLogo,
1580
+ appName: (_h = (_g = (_f = res == null ? void 0 : res.body) == null ? void 0 : _f.unsigned) == null ? void 0 : _g.data) == null ? void 0 : _h.appName,
1581
+ openUrl: (_k = (_j = (_i = res == null ? void 0 : res.body) == null ? void 0 : _i.unsigned) == null ? void 0 : _j.data) == null ? void 0 : _k.openUrl,
1582
+ whiteListDomains: (_n = (_m = (_l = res == null ? void 0 : res.body) == null ? void 0 : _l.unsigned) == null ? void 0 : _m.data) == null ? void 0 : _n.whiteListDomains,
1583
+ isInternal: (_q = (_p = (_o = res == null ? void 0 : res.body) == null ? void 0 : _o.unsigned) == null ? void 0 : _p.data) == null ? void 0 : _q.isInternal,
1584
+ window: (_t = (_s = (_r = res == null ? void 0 : res.body) == null ? void 0 : _r.unsigned) == null ? void 0 : _s.data) == null ? void 0 : _t.window,
1585
+ subdomainCookieSharing: (_w = (_v = (_u = res == null ? void 0 : res.body) == null ? void 0 : _u.unsigned) == null ? void 0 : _v.data) == null ? void 0 : _w.subdomainCookieSharing
1586
+ }));
1587
+ return true;
1588
+ }
1589
+ function getAppDetail() {
1590
+ const json = getAppDetail$1();
1591
+ if (json) {
1592
+ return JSON.parse(json);
1593
+ }
1594
+ return null;
1595
+ }
1596
+ function reconstructParams(params) {
1597
+ if (!params)
1598
+ return params;
1599
+ const _a = params, { success: success2, complete, fail } = _a, data2 = __objRest(_a, ["success", "complete", "fail"]);
1600
+ return __spreadProps(__spreadValues({}, data2), {
1601
+ success: (result2) => {
1602
+ setTimeout(() => {
1603
+ success2 == null ? void 0 : success2(result2);
1604
+ }, 0);
1605
+ setTimeout(() => {
1606
+ complete == null ? void 0 : complete();
1607
+ }, 0);
1608
+ },
1609
+ fail: (result2) => {
1610
+ setTimeout(() => {
1611
+ fail == null ? void 0 : fail(result2);
1612
+ }, 0);
1613
+ setTimeout(() => {
1614
+ complete == null ? void 0 : complete();
1615
+ }, 0);
1616
+ }
1617
+ });
1618
+ }
1619
+ function openWebview(openWebviewParams) {
1620
+ var _a, _b, _c, _d;
1621
+ const params = reconstructParams(openWebviewParams);
1622
+ let url;
1623
+ let openUrl2 = null;
1624
+ const appDetail = getAppDetail();
1625
+ try {
1626
+ url = new URL(params == null ? void 0 : params.url);
1627
+ } catch (error2) {
1628
+ (_a = params == null ? void 0 : params.fail) == null ? void 0 : _a.call(params, {
1629
+ errorCode: MiniAppErrorType.invalidUrl
1630
+ });
1631
+ return;
1632
+ }
1633
+ try {
1634
+ openUrl2 = appDetail ? new URL(appDetail.openUrl) : null;
1635
+ } catch (_) {
1636
+ }
1637
+ if (params == null ? void 0 : params.authorization) {
1638
+ params.url = getAuthUrl(params.url);
1639
+ openWebviewInternal(params);
1640
+ } else if (["http:", "https:"].includes(url.protocol) && ((params == null ? void 0 : params.style) === "external" || ((_b = appDetail == null ? void 0 : appDetail.whiteListDomains) == null ? void 0 : _b.includes(url.host)) || url.host === (openUrl2 == null ? void 0 : openUrl2.host))) {
1641
+ openWebviewInternal(params);
1642
+ } else {
1643
+ return (_c = params == null ? void 0 : params.fail) == null ? void 0 : _c.call(params, {
1644
+ errorCode: MiniAppErrorType.whiteListError
1645
+ });
1646
+ }
1647
+ (_d = params == null ? void 0 : params.success) == null ? void 0 : _d.call(params);
1648
+ }
1649
+ function openWebviewInternal(params) {
1650
+ var _a, _b;
1651
+ let url;
1652
+ try {
1653
+ url = new URL(params == null ? void 0 : params.url);
1654
+ } catch (_) {
1655
+ }
1656
+ if (isPayPayMiniApp() && url) {
1657
+ if (["http:", "https:"].includes(url.protocol)) {
1658
+ url.searchParams.set("ppOpenWebview", (_a = params == null ? void 0 : params.style) != null ? _a : "modal");
1659
+ }
1660
+ window.location.href = url.toString();
1661
+ } else if (url) {
1662
+ if (["http:", "https:"].includes(url.protocol)) {
1663
+ (_b = window.open(url.toString(), "_blank")) == null ? void 0 : _b.focus();
1664
+ } else {
1665
+ window.location.href = url.toString();
1666
+ }
1667
+ }
1668
+ }
1669
+ function getAuthUrl(redirectUrl) {
1670
+ var _a;
1671
+ let authUrl = "";
1672
+ switch (getEnv()) {
1673
+ case "staging":
1674
+ authUrl = "https://stg-www.paypay-corp.co.jp";
1675
+ break;
1676
+ case "sandbox":
1677
+ authUrl = "https://stg-www.sandbox.paypay.ne.jp";
1678
+ break;
1679
+ case "canary":
1680
+ authUrl = "https://www-prod-canary.paypay.ne.jp";
1681
+ break;
1682
+ case "qa":
1683
+ authUrl = "https://www.qa.stg.paypay.ne.jp";
1684
+ break;
1685
+ case "production":
1686
+ default:
1687
+ authUrl = "https://www.paypay.ne.jp";
1688
+ }
1689
+ const clientId = (_a = getClientId()) != null ? _a : "";
1690
+ return `${authUrl}/portal/auth/mini-app/permission?clientId=${clientId}&redirectUrl=${encodeURIComponent(redirectUrl)}`;
1691
+ }
1566
1692
  function isDef(val2) {
1567
1693
  return val2 !== void 0 && val2 !== null;
1568
1694
  }
@@ -1738,11 +1864,14 @@ function handleHeightResize(el, windowHeight, isScrollable, offsetHeight) {
1738
1864
  return false;
1739
1865
  }
1740
1866
  }
1741
- function getPaymentMethodStatus(isExpired, val2) {
1867
+ function getPaymentMethodStatus(isExpired, paymentMethodInfo) {
1742
1868
  const lg2 = getLanguage();
1743
1869
  if (isExpired)
1744
1870
  return lg2.paymentMethod.expired;
1745
- return val2 && val2 in PaymentMethodStatus ? lg2.paymentMethodStatus[val2] : "";
1871
+ const { paymentMethodStatus: paymentMethodStatus2, paymentMethodStatusLabel } = paymentMethodInfo || {};
1872
+ if (paymentMethodStatusLabel)
1873
+ return paymentMethodStatusLabel;
1874
+ return paymentMethodStatus2 && paymentMethodStatus2 in PaymentMethodStatus ? lg2.paymentMethodStatus[paymentMethodStatus2] : "";
1746
1875
  }
1747
1876
  function filterErrorButtonList(buttonList) {
1748
1877
  return buttonList == null ? void 0 : buttonList.filter((button4) => {
@@ -1791,6 +1920,23 @@ async function generateCodeChallange(codeVerifier) {
1791
1920
  const hash = await crypto.subtle.digest("SHA-256", array);
1792
1921
  return base64UrlEncode(String.fromCharCode(...new Uint8Array(hash)));
1793
1922
  }
1923
+ function openUrl(linkUrl) {
1924
+ if (!linkUrl)
1925
+ return;
1926
+ if (isValidUrl(linkUrl)) {
1927
+ openWebviewInternal({ url: linkUrl });
1928
+ return;
1929
+ }
1930
+ try {
1931
+ const url = new URL(linkUrl);
1932
+ const urlParam = url.searchParams.get("url");
1933
+ if (urlParam && linkUrl.startsWith("paypay://embed")) {
1934
+ openWebviewInternal({ url: urlParam });
1935
+ return;
1936
+ }
1937
+ } catch (_) {
1938
+ }
1939
+ }
1794
1940
  const opaUrl = () => {
1795
1941
  switch (getEnv()) {
1796
1942
  case "staging":
@@ -1811,7 +1957,7 @@ const opaUrl = () => {
1811
1957
  const createHeaderMiniAppApi = (urlEndpoint, customHeaders) => {
1812
1958
  let headers = new Headers(__spreadValues({
1813
1959
  "Content-Type": "application/json",
1814
- "Client-Version": "1.47.0",
1960
+ "Client-Version": "1.50.0",
1815
1961
  "Client-OS-Type": getRuntime()
1816
1962
  }, customHeaders));
1817
1963
  if (urlEndpoint === "web-api/app/v2/payment/methods" || urlEndpoint === "web-api/app/v2/payment/consult" || urlEndpoint === "web-api/app/v1/payment/cashbackDetail" || urlEndpoint === "web-api/app/v1/confirmAgeForCashback" || urlEndpoint === "web-api/app/v1/internal/request" || urlEndpoint === "web-api/app/v1/addressbyzip" || urlEndpoint === "/web-api/app/platform/v1/balance" || urlEndpoint === "web-api/app/v1/users/autoTopupConfiguration" || urlEndpoint === "web-api/app/v1/users/preTransactionAutoTopupConfiguration") {
@@ -1964,35 +2110,6 @@ async function refreshToken() {
1964
2110
  }
1965
2111
  return false;
1966
2112
  }
1967
- async function initAppDetail(accessToken) {
1968
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w;
1969
- const res = await ppFetch2({
1970
- method: "GET",
1971
- url: "web-api/app/v1/apps/detail",
1972
- headers: { Authorization: `Bearer ${accessToken}` }
1973
- });
1974
- if ((res == null ? void 0 : res.ppFetchResult) !== "success" || !((_b = (_a = res == null ? void 0 : res.body) == null ? void 0 : _a.unsigned) == null ? void 0 : _b.data)) {
1975
- removeAppDetail();
1976
- return false;
1977
- }
1978
- saveAppDetail(JSON.stringify({
1979
- appLogo: (_e = (_d = (_c = res == null ? void 0 : res.body) == null ? void 0 : _c.unsigned) == null ? void 0 : _d.data) == null ? void 0 : _e.appLogo,
1980
- appName: (_h = (_g = (_f = res == null ? void 0 : res.body) == null ? void 0 : _f.unsigned) == null ? void 0 : _g.data) == null ? void 0 : _h.appName,
1981
- openUrl: (_k = (_j = (_i = res == null ? void 0 : res.body) == null ? void 0 : _i.unsigned) == null ? void 0 : _j.data) == null ? void 0 : _k.openUrl,
1982
- whiteListDomains: (_n = (_m = (_l = res == null ? void 0 : res.body) == null ? void 0 : _l.unsigned) == null ? void 0 : _m.data) == null ? void 0 : _n.whiteListDomains,
1983
- isInternal: (_q = (_p = (_o = res == null ? void 0 : res.body) == null ? void 0 : _o.unsigned) == null ? void 0 : _p.data) == null ? void 0 : _q.isInternal,
1984
- window: (_t = (_s = (_r = res == null ? void 0 : res.body) == null ? void 0 : _r.unsigned) == null ? void 0 : _s.data) == null ? void 0 : _t.window,
1985
- subdomainCookieSharing: (_w = (_v = (_u = res == null ? void 0 : res.body) == null ? void 0 : _u.unsigned) == null ? void 0 : _v.data) == null ? void 0 : _w.subdomainCookieSharing
1986
- }));
1987
- return true;
1988
- }
1989
- function getAppDetail() {
1990
- const json = getAppDetail$1();
1991
- if (json) {
1992
- return JSON.parse(json);
1993
- }
1994
- return null;
1995
- }
1996
2113
  async function initAppConfiguration() {
1997
2114
  var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m;
1998
2115
  const res = await ppFetch2({
@@ -2021,29 +2138,6 @@ function getAppConfig() {
2021
2138
  }
2022
2139
  return null;
2023
2140
  }
2024
- function reconstructParams(params) {
2025
- if (!params)
2026
- return params;
2027
- const _a = params, { success: success2, complete, fail } = _a, data2 = __objRest(_a, ["success", "complete", "fail"]);
2028
- return __spreadProps(__spreadValues({}, data2), {
2029
- success: (result2) => {
2030
- setTimeout(() => {
2031
- success2 == null ? void 0 : success2(result2);
2032
- }, 0);
2033
- setTimeout(() => {
2034
- complete == null ? void 0 : complete();
2035
- }, 0);
2036
- },
2037
- fail: (result2) => {
2038
- setTimeout(() => {
2039
- fail == null ? void 0 : fail(result2);
2040
- }, 0);
2041
- setTimeout(() => {
2042
- complete == null ? void 0 : complete();
2043
- }, 0);
2044
- }
2045
- });
2046
- }
2047
2141
  var MiniAppStatusType;
2048
2142
  (function(MiniAppStatusType2) {
2049
2143
  MiniAppStatusType2["validToken"] = "TOKEN_VALID";
@@ -2056,10 +2150,10 @@ var MiniAppStatusType;
2056
2150
  })(MiniAppStatusType || (MiniAppStatusType = {}));
2057
2151
  function getUAID(params) {
2058
2152
  const newParams = reconstructParams(params);
2059
- execute$f(newParams).catch(() => {
2153
+ execute$g(newParams).catch(() => {
2060
2154
  });
2061
2155
  }
2062
- async function execute$f(params) {
2156
+ async function execute$g(params) {
2063
2157
  var _a, _b, _c, _d, _e;
2064
2158
  const res = await ppFetch2({
2065
2159
  method: "GET",
@@ -2073,9 +2167,9 @@ async function execute$f(params) {
2073
2167
  }
2074
2168
  function checkAccessToken(params) {
2075
2169
  const newParams = reconstructParams(params);
2076
- execute$e(newParams);
2170
+ execute$f(newParams);
2077
2171
  }
2078
- function execute$e(params) {
2172
+ function execute$f(params) {
2079
2173
  var _a, _b;
2080
2174
  const clientId = getClientId();
2081
2175
  const token = getAccessToken();
@@ -2100,9 +2194,9 @@ function execute$e(params) {
2100
2194
  }
2101
2195
  async function getUserProfile(params) {
2102
2196
  const newParams = reconstructParams(params);
2103
- await execute$d(newParams);
2197
+ await execute$e(newParams);
2104
2198
  }
2105
- async function execute$d(params) {
2199
+ async function execute$e(params) {
2106
2200
  var _a, _b;
2107
2201
  const res = await ppFetch2({
2108
2202
  method: "GET",
@@ -2679,7 +2773,7 @@ function createGetter(isReadonly2 = false, shallow = false) {
2679
2773
  return res;
2680
2774
  };
2681
2775
  }
2682
- const set = /* @__PURE__ */ createSetter();
2776
+ const set$1 = /* @__PURE__ */ createSetter();
2683
2777
  const shallowSet = /* @__PURE__ */ createSetter(true);
2684
2778
  function createSetter(shallow = false) {
2685
2779
  return function set2(target, key2, value2, receiver2) {
@@ -2731,7 +2825,7 @@ function ownKeys(target) {
2731
2825
  }
2732
2826
  const mutableHandlers = {
2733
2827
  get,
2734
- set,
2828
+ set: set$1,
2735
2829
  deleteProperty,
2736
2830
  has,
2737
2831
  ownKeys
@@ -2799,7 +2893,7 @@ function add(value2) {
2799
2893
  }
2800
2894
  return this;
2801
2895
  }
2802
- function set$1(key2, value2) {
2896
+ function set$1$1(key2, value2) {
2803
2897
  value2 = toRaw(value2);
2804
2898
  const target = toRaw(this);
2805
2899
  const { has: has2, get: get2 } = getProto(target);
@@ -2892,7 +2986,7 @@ function createInstrumentations() {
2892
2986
  },
2893
2987
  has: has$1,
2894
2988
  add,
2895
- set: set$1,
2989
+ set: set$1$1,
2896
2990
  delete: deleteEntry,
2897
2991
  clear,
2898
2992
  forEach: createForEach(false, false)
@@ -2906,7 +3000,7 @@ function createInstrumentations() {
2906
3000
  },
2907
3001
  has: has$1,
2908
3002
  add,
2909
- set: set$1,
3003
+ set: set$1$1,
2910
3004
  delete: deleteEntry,
2911
3005
  clear,
2912
3006
  forEach: createForEach(false, true)
@@ -7578,9 +7672,9 @@ const OTTLoginState = reactive({
7578
7672
  });
7579
7673
  async function init(params) {
7580
7674
  const newParams = reconstructParams(params);
7581
- await execute$c(newParams);
7675
+ await execute$d(newParams);
7582
7676
  }
7583
- async function execute$c(params) {
7677
+ async function execute$d(params) {
7584
7678
  var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p;
7585
7679
  try {
7586
7680
  saveEnv((_a = params == null ? void 0 : params.env) != null ? _a : "");
@@ -7595,7 +7689,8 @@ async function execute$c(params) {
7595
7689
  });
7596
7690
  }
7597
7691
  }
7598
- const urlParams = new URLSearchParams(window.location.search);
7692
+ const url = new URL(window.location.href);
7693
+ const urlParams = url.searchParams;
7599
7694
  let token = urlParams == null ? void 0 : urlParams.get("token");
7600
7695
  if (!token || token.length < 1) {
7601
7696
  token = urlParams == null ? void 0 : urlParams.get("one_time_token");
@@ -7608,9 +7703,8 @@ async function execute$c(params) {
7608
7703
  }
7609
7704
  urlParams.delete("token");
7610
7705
  urlParams.delete("one_time_token");
7611
- const newUrlParams = urlParams.toString().length ? "?" + urlParams.toString() : "";
7612
- const newUrl = location.pathname + newUrlParams + location.hash;
7613
- history.replaceState(null, "", newUrl);
7706
+ url.search = urlParams.toString();
7707
+ history.replaceState(null, "", url);
7614
7708
  const codeVerifier = getCodeVerifier();
7615
7709
  const res = await ppFetch2({
7616
7710
  method: "POST",
@@ -7689,87 +7783,14 @@ function copyToClipboard(copyTextParams) {
7689
7783
  document.body.removeChild(textarea);
7690
7784
  result2 ? (_a = params == null ? void 0 : params.success) == null ? void 0 : _a.call(params) : (_b = params == null ? void 0 : params.fail) == null ? void 0 : _b.call(params, { errorCode: MiniAppErrorType.other });
7691
7785
  }
7692
- function openWebview(openWebviewParams) {
7693
- var _a, _b, _c, _d;
7694
- const params = reconstructParams(openWebviewParams);
7695
- let url;
7696
- let openUrl = null;
7697
- const appDetail = getAppDetail();
7698
- try {
7699
- url = new URL(params == null ? void 0 : params.url);
7700
- } catch (error2) {
7701
- (_a = params == null ? void 0 : params.fail) == null ? void 0 : _a.call(params, {
7702
- errorCode: MiniAppErrorType.invalidUrl
7703
- });
7704
- return;
7705
- }
7706
- try {
7707
- openUrl = appDetail ? new URL(appDetail.openUrl) : null;
7708
- } catch (_) {
7709
- }
7710
- if (params == null ? void 0 : params.authorization) {
7711
- params.url = getAuthUrl(params.url);
7712
- openWebviewInternal(params);
7713
- } else if (["http:", "https:"].includes(url.protocol) && ((params == null ? void 0 : params.style) === "external" || ((_b = appDetail == null ? void 0 : appDetail.whiteListDomains) == null ? void 0 : _b.includes(url.host)) || url.host === (openUrl == null ? void 0 : openUrl.host))) {
7714
- openWebviewInternal(params);
7715
- } else {
7716
- return (_c = params == null ? void 0 : params.fail) == null ? void 0 : _c.call(params, {
7717
- errorCode: MiniAppErrorType.whiteListError
7718
- });
7719
- }
7720
- (_d = params == null ? void 0 : params.success) == null ? void 0 : _d.call(params);
7721
- }
7722
- function openWebviewInternal(params) {
7723
- var _a, _b;
7724
- let url;
7725
- try {
7726
- url = new URL(params == null ? void 0 : params.url);
7727
- } catch (_) {
7728
- }
7729
- if (isPayPayMiniApp() && url) {
7730
- if (["http:", "https:"].includes(url.protocol)) {
7731
- url.searchParams.set("ppOpenWebview", (_a = params == null ? void 0 : params.style) != null ? _a : "modal");
7732
- }
7733
- window.location.href = url.toString();
7734
- } else if (url) {
7735
- if (["http:", "https:"].includes(url.protocol)) {
7736
- (_b = window.open(url.toString(), "_blank")) == null ? void 0 : _b.focus();
7737
- } else {
7738
- window.location.href = url.toString();
7739
- }
7740
- }
7741
- }
7742
- function getAuthUrl(redirectUrl) {
7743
- var _a;
7744
- let authUrl = "";
7745
- switch (getEnv()) {
7746
- case "staging":
7747
- authUrl = "https://stg-www.paypay-corp.co.jp";
7748
- break;
7749
- case "sandbox":
7750
- authUrl = "https://stg-www.sandbox.paypay.ne.jp";
7751
- break;
7752
- case "canary":
7753
- authUrl = "https://www-prod-canary.paypay.ne.jp";
7754
- break;
7755
- case "qa":
7756
- authUrl = "https://www.qa.stg.paypay.ne.jp";
7757
- break;
7758
- case "production":
7759
- default:
7760
- authUrl = "https://www.paypay.ne.jp";
7761
- }
7762
- const clientId = (_a = getClientId()) != null ? _a : "";
7763
- return `${authUrl}/portal/auth/mini-app/permission?clientId=${clientId}&redirectUrl=${encodeURIComponent(redirectUrl)}`;
7764
- }
7765
- var _sfc_main$1A = defineComponent({
7786
+ var _sfc_main$1B = defineComponent({
7766
7787
  name: "LoadingIndicator"
7767
7788
  });
7768
7789
  const loading$1 = "_loading_ovc6l_1";
7769
7790
  const bounce = "_bounce_ovc6l_14";
7770
7791
  const bounce1 = "_bounce1_ovc6l_14";
7771
7792
  const bounce2 = "_bounce2_ovc6l_17";
7772
- var style0$1p = {
7793
+ var style0$1q = {
7773
7794
  loading: loading$1,
7774
7795
  bounce,
7775
7796
  bounce1,
@@ -7783,7 +7804,7 @@ var _export_sfc = (sfc, props) => {
7783
7804
  return target;
7784
7805
  };
7785
7806
  const _hoisted_1$W = /* @__PURE__ */ createBaseVNode("div", null, null, -1);
7786
- function _sfc_render$1A(_ctx, _cache, $props, $setup, $data, $options) {
7807
+ function _sfc_render$1B(_ctx, _cache, $props, $setup, $data, $options) {
7787
7808
  return openBlock(), createElementBlock("div", {
7788
7809
  class: normalizeClass(_ctx.$style.loading)
7789
7810
  }, [
@@ -7796,9 +7817,9 @@ function _sfc_render$1A(_ctx, _cache, $props, $setup, $data, $options) {
7796
7817
  _hoisted_1$W
7797
7818
  ], 2);
7798
7819
  }
7799
- const cssModules$1p = {};
7800
- cssModules$1p["$style"] = style0$1p;
7801
- var LoadingIndicator = /* @__PURE__ */ _export_sfc(_sfc_main$1A, [["render", _sfc_render$1A], ["__cssModules", cssModules$1p]]);
7820
+ const cssModules$1q = {};
7821
+ cssModules$1q["$style"] = style0$1q;
7822
+ var LoadingIndicator = /* @__PURE__ */ _export_sfc(_sfc_main$1B, [["render", _sfc_render$1B], ["__cssModules", cssModules$1q]]);
7802
7823
  const buttonWrapper = "_buttonWrapper_1a5ed_2";
7803
7824
  const container$A = "_container_1a5ed_2";
7804
7825
  const primary = "_primary_1a5ed_24";
@@ -8402,7 +8423,7 @@ const errorTitle = "_errorTitle_86qa7_25";
8402
8423
  const subTitle$2 = "_subTitle_86qa7_33";
8403
8424
  const btnContainer$2 = "_btnContainer_86qa7_41";
8404
8425
  const closeBtn$3 = "_closeBtn_86qa7_45";
8405
- var style0$1o = {
8426
+ var style0$1p = {
8406
8427
  "ppmna-default-font": "_ppmna-default-font_86qa7_1",
8407
8428
  errorContainer,
8408
8429
  errorIcon,
@@ -8412,7 +8433,7 @@ var style0$1o = {
8412
8433
  btnContainer: btnContainer$2,
8413
8434
  closeBtn: closeBtn$3
8414
8435
  };
8415
- const _sfc_main$1z = defineComponent({
8436
+ const _sfc_main$1A = defineComponent({
8416
8437
  components: {
8417
8438
  ActionSheet,
8418
8439
  Button
@@ -8528,7 +8549,7 @@ const _sfc_main$1z = defineComponent({
8528
8549
  }
8529
8550
  });
8530
8551
  const _hoisted_1$V = ["src"];
8531
- function _sfc_render$1z(_ctx, _cache, $props, $setup, $data, $options) {
8552
+ function _sfc_render$1A(_ctx, _cache, $props, $setup, $data, $options) {
8532
8553
  const _component_Button = resolveComponent("Button");
8533
8554
  const _component_ActionSheet = resolveComponent("ActionSheet");
8534
8555
  return openBlock(), createBlock(_component_ActionSheet, {
@@ -8597,10 +8618,10 @@ function _sfc_render$1z(_ctx, _cache, $props, $setup, $data, $options) {
8597
8618
  _: 1
8598
8619
  }, 8, ["show"]);
8599
8620
  }
8600
- const cssModules$1o = {};
8601
- cssModules$1o["$style"] = style0$1o;
8602
- var ErrorSheet = /* @__PURE__ */ _export_sfc(_sfc_main$1z, [["render", _sfc_render$1z], ["__cssModules", cssModules$1o]]);
8603
- const wrapperClass$p = "_wrapperClass_hgr81_2";
8621
+ const cssModules$1p = {};
8622
+ cssModules$1p["$style"] = style0$1p;
8623
+ var ErrorSheet = /* @__PURE__ */ _export_sfc(_sfc_main$1A, [["render", _sfc_render$1A], ["__cssModules", cssModules$1p]]);
8624
+ const wrapperClass$q = "_wrapperClass_hgr81_2";
8604
8625
  const openMapActionsheetContainer = "_openMapActionsheetContainer_hgr81_2";
8605
8626
  const openMapTitle = "_openMapTitle_hgr81_13";
8606
8627
  const openMapActionsheetMain = "_openMapActionsheetMain_hgr81_19";
@@ -8608,9 +8629,9 @@ const divider = "_divider_hgr81_26";
8608
8629
  const mapButton = "_mapButton_hgr81_29";
8609
8630
  const closeBtn$2 = "_closeBtn_hgr81_36";
8610
8631
  const mapList = "_mapList_hgr81_48";
8611
- var style0$1n = {
8632
+ var style0$1o = {
8612
8633
  "ppmna-default-font": "_ppmna-default-font_hgr81_1",
8613
- wrapperClass: wrapperClass$p,
8634
+ wrapperClass: wrapperClass$q,
8614
8635
  openMapActionsheetContainer,
8615
8636
  openMapTitle,
8616
8637
  openMapActionsheetMain,
@@ -8619,7 +8640,7 @@ var style0$1n = {
8619
8640
  closeBtn: closeBtn$2,
8620
8641
  mapList
8621
8642
  };
8622
- const _sfc_main$1y = defineComponent({
8643
+ const _sfc_main$1z = defineComponent({
8623
8644
  components: {
8624
8645
  ActionSheet,
8625
8646
  Button,
@@ -8671,7 +8692,7 @@ const _sfc_main$1y = defineComponent({
8671
8692
  }
8672
8693
  });
8673
8694
  const _hoisted_1$U = /* @__PURE__ */ createTextVNode(" \u30AD\u30E3\u30F3\u30BB\u30EB ");
8674
- function _sfc_render$1y(_ctx, _cache, $props, $setup, $data, $options) {
8695
+ function _sfc_render$1z(_ctx, _cache, $props, $setup, $data, $options) {
8675
8696
  const _component_Divider = resolveComponent("Divider");
8676
8697
  const _component_Button = resolveComponent("Button");
8677
8698
  const _component_ActionSheet = resolveComponent("ActionSheet");
@@ -8741,9 +8762,9 @@ function _sfc_render$1y(_ctx, _cache, $props, $setup, $data, $options) {
8741
8762
  }, null, 8, ["show", "error-text"])
8742
8763
  ], 64);
8743
8764
  }
8744
- const cssModules$1n = {};
8745
- cssModules$1n["$style"] = style0$1n;
8746
- var AppVue$8 = /* @__PURE__ */ _export_sfc(_sfc_main$1y, [["render", _sfc_render$1y], ["__cssModules", cssModules$1n]]);
8765
+ const cssModules$1o = {};
8766
+ cssModules$1o["$style"] = style0$1o;
8767
+ var AppVue$8 = /* @__PURE__ */ _export_sfc(_sfc_main$1z, [["render", _sfc_render$1z], ["__cssModules", cssModules$1o]]);
8747
8768
  const popStateHandler = (callback, inputParams) => {
8748
8769
  const handlePopState = () => {
8749
8770
  var _a, _b;
@@ -8906,36 +8927,49 @@ const PermissionName = {
8906
8927
  mini_app_user_address: "mini_app_user_address",
8907
8928
  mini_app_user_phone_camera: "mini_app_user_phone_camera",
8908
8929
  mini_app_user_phone_album: "mini_app_user_phone_album",
8909
- mini_app_bank_information: "mini_app_bank_information"
8930
+ mini_app_bank_information: "mini_app_bank_information",
8931
+ mini_app_cashback_information: "mini_app_cashback_information"
8910
8932
  };
8911
8933
  const checkPermission = async (permissionNames) => {
8912
8934
  var _a;
8913
- if ((_a = getAppDetail()) == null ? void 0 : _a.isInternal) {
8914
- return PermissionStatus.granted;
8915
- }
8916
- const resPermission = await getUserGrantedPermission();
8917
- permissionNames = Array.isArray(permissionNames) ? permissionNames : [permissionNames];
8918
- for (const permissionName of permissionNames) {
8919
- if (!(resPermission == null ? void 0 : resPermission.find((name2) => name2 === permissionName))) {
8920
- return PermissionStatus.denied;
8935
+ try {
8936
+ if ((_a = getAppDetail()) == null ? void 0 : _a.isInternal) {
8937
+ return PermissionStatus.granted;
8921
8938
  }
8939
+ const resPermission = await getUserGrantedPermission();
8940
+ permissionNames = Array.isArray(permissionNames) ? permissionNames : [permissionNames];
8941
+ for (const permissionName of permissionNames) {
8942
+ if (!(resPermission == null ? void 0 : resPermission.find((name2) => name2 === permissionName))) {
8943
+ return PermissionStatus.denied;
8944
+ }
8945
+ }
8946
+ return PermissionStatus.granted;
8947
+ } catch {
8948
+ throw Error(MiniAppErrorType.serverError);
8922
8949
  }
8923
- return PermissionStatus.granted;
8924
8950
  };
8925
8951
  async function getUserGrantedPermission() {
8926
8952
  var _a, _b, _c, _d;
8927
- const response = await ppFetch2({
8928
- method: "GET",
8929
- url: "web-api/app/v1/users/permissions/granted"
8930
- });
8931
- return (response == null ? void 0 : response.ppFetchResult) === "success" ? (_d = (_c = (_b = (_a = response == null ? void 0 : response.body) == null ? void 0 : _a.unsigned) == null ? void 0 : _b.data) == null ? void 0 : _c.scopes) != null ? _d : [] : [];
8953
+ try {
8954
+ const response = await ppFetch2({
8955
+ method: "GET",
8956
+ url: "web-api/app/v1/users/permissions/granted"
8957
+ });
8958
+ if ((response == null ? void 0 : response.ppFetchResult) !== "success") {
8959
+ throw Error(MiniAppErrorType.serverError);
8960
+ } else {
8961
+ return (_d = (_c = (_b = (_a = response == null ? void 0 : response.body) == null ? void 0 : _a.unsigned) == null ? void 0 : _b.data) == null ? void 0 : _c.scopes) != null ? _d : [];
8962
+ }
8963
+ } catch {
8964
+ throw Error(MiniAppErrorType.serverError);
8965
+ }
8932
8966
  }
8933
8967
  async function getBalance(params) {
8934
8968
  const newParams = reconstructParams(params);
8935
- await execute$b(newParams);
8969
+ await execute$c(newParams);
8936
8970
  }
8937
- async function execute$b(params) {
8938
- var _a, _b, _c, _d, _e, _f, _g, _h;
8971
+ async function execute$c(params) {
8972
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i;
8939
8973
  try {
8940
8974
  const grantStatus = await checkPermission(PermissionName.mini_app_payment_balance);
8941
8975
  if (grantStatus !== PermissionStatus.granted) {
@@ -8956,13 +8990,15 @@ async function execute$b(params) {
8956
8990
  const newBalance = (_f = (_e = (_d = (_c = res == null ? void 0 : res.body) == null ? void 0 : _c.unsigned) == null ? void 0 : _d.data) == null ? void 0 : _e.totalBalance) == null ? void 0 : _f.amount;
8957
8991
  return (_g = params == null ? void 0 : params.success) == null ? void 0 : _g.call(params, { balance: newBalance });
8958
8992
  }
8993
+ } catch {
8994
+ return (_h = params == null ? void 0 : params.fail) == null ? void 0 : _h.call(params, { errorCode: MiniAppErrorType.serverError });
8959
8995
  } finally {
8960
8996
  }
8961
- return (_h = params == null ? void 0 : params.fail) == null ? void 0 : _h.call(params, { errorCode: MiniAppErrorType.serverError });
8997
+ return (_i = params == null ? void 0 : params.fail) == null ? void 0 : _i.call(params, { errorCode: MiniAppErrorType.serverError });
8962
8998
  }
8963
8999
  async function getAuthStatus(params) {
8964
9000
  const newParams = reconstructParams(params);
8965
- await execute$a(newParams);
9001
+ await execute$b(newParams);
8966
9002
  }
8967
9003
  async function handlePKCE() {
8968
9004
  const codeVerifier = generateCodeVerifier();
@@ -8984,7 +9020,7 @@ async function handleFailCallback(params, errorCode) {
8984
9020
  code
8985
9021
  });
8986
9022
  }
8987
- async function execute$a(params) {
9023
+ async function execute$b(params) {
8988
9024
  var _a, _b, _c, _d, _e, _f;
8989
9025
  try {
8990
9026
  const clientId = getClientId();
@@ -9237,7 +9273,7 @@ function useBreakpoints() {
9237
9273
  windowHeight: computed(() => windowHeight.value)
9238
9274
  };
9239
9275
  }
9240
- const wrapperClass$o = "_wrapperClass_1k2lr_1";
9276
+ const wrapperClass$p = "_wrapperClass_1k2lr_1";
9241
9277
  const breakDownList = "_breakDownList_1k2lr_1";
9242
9278
  const nonUsable = "_nonUsable_1k2lr_17";
9243
9279
  const breakDownEnter = "_breakDownEnter_1k2lr_35";
@@ -9247,8 +9283,8 @@ const enterActive = "_enterActive_1k2lr_55";
9247
9283
  const leaveActive = "_leaveActive_1k2lr_60";
9248
9284
  const enterTo = "_enterTo_1k2lr_65";
9249
9285
  const leaveTo = "_leaveTo_1k2lr_69";
9250
- var style0$1m = {
9251
- wrapperClass: wrapperClass$o,
9286
+ var style0$1n = {
9287
+ wrapperClass: wrapperClass$p,
9252
9288
  breakDownList,
9253
9289
  nonUsable,
9254
9290
  breakDownEnter,
@@ -9259,7 +9295,7 @@ var style0$1m = {
9259
9295
  enterTo,
9260
9296
  leaveTo
9261
9297
  };
9262
- const _sfc_main$1x = defineComponent({
9298
+ const _sfc_main$1y = defineComponent({
9263
9299
  props: {
9264
9300
  wallet: {
9265
9301
  type: Object,
@@ -9300,7 +9336,7 @@ const _sfc_main$1x = defineComponent({
9300
9336
  };
9301
9337
  }
9302
9338
  });
9303
- function _sfc_render$1x(_ctx, _cache, $props, $setup, $data, $options) {
9339
+ function _sfc_render$1y(_ctx, _cache, $props, $setup, $data, $options) {
9304
9340
  return openBlock(), createElementBlock("div", {
9305
9341
  class: normalizeClass(_ctx.$style.wrapperClass)
9306
9342
  }, [
@@ -9363,10 +9399,10 @@ function _sfc_render$1x(_ctx, _cache, $props, $setup, $data, $options) {
9363
9399
  }, 8, ["enter-active-class", "leave-active-class", "enter-to-class", "leave-to-class"])
9364
9400
  ], 2);
9365
9401
  }
9366
- const cssModules$1m = {};
9367
- cssModules$1m["$style"] = style0$1m;
9368
- var WalletBreakdown = /* @__PURE__ */ _export_sfc(_sfc_main$1x, [["render", _sfc_render$1x], ["__cssModules", cssModules$1m]]);
9369
- const wrapperClass$n = "_wrapperClass_123gn_1";
9402
+ const cssModules$1n = {};
9403
+ cssModules$1n["$style"] = style0$1n;
9404
+ var WalletBreakdown = /* @__PURE__ */ _export_sfc(_sfc_main$1y, [["render", _sfc_render$1y], ["__cssModules", cssModules$1n]]);
9405
+ const wrapperClass$o = "_wrapperClass_123gn_1";
9370
9406
  const ppmnaPaymentTypeContainer$4 = "_ppmnaPaymentTypeContainer_123gn_1";
9371
9407
  const img$e = "_img_123gn_5";
9372
9408
  const imgContainer$5 = "_imgContainer_123gn_18";
@@ -9384,8 +9420,8 @@ const chargeContainer = "_chargeContainer_123gn_96";
9384
9420
  const greenTick = "_greenTick_123gn_106";
9385
9421
  const autoCharge = "_autoCharge_123gn_119";
9386
9422
  const makePaymentRightAlign = "_makePaymentRightAlign_123gn_126";
9387
- var style0$1l = {
9388
- wrapperClass: wrapperClass$n,
9423
+ var style0$1m = {
9424
+ wrapperClass: wrapperClass$o,
9389
9425
  ppmnaPaymentTypeContainer: ppmnaPaymentTypeContainer$4,
9390
9426
  img: img$e,
9391
9427
  imgContainer: imgContainer$5,
@@ -9404,7 +9440,7 @@ var style0$1l = {
9404
9440
  autoCharge,
9405
9441
  makePaymentRightAlign
9406
9442
  };
9407
- const _sfc_main$1w = defineComponent({
9443
+ const _sfc_main$1x = defineComponent({
9408
9444
  components: {
9409
9445
  WalletBreakdown
9410
9446
  },
@@ -9444,8 +9480,8 @@ const _sfc_main$1w = defineComponent({
9444
9480
  }
9445
9481
  });
9446
9482
  const _hoisted_1$T = ["src"];
9447
- const _hoisted_2$p = ["src"];
9448
- function _sfc_render$1w(_ctx, _cache, $props, $setup, $data, $options) {
9483
+ const _hoisted_2$s = ["src"];
9484
+ function _sfc_render$1x(_ctx, _cache, $props, $setup, $data, $options) {
9449
9485
  const _component_WalletBreakdown = resolveComponent("WalletBreakdown");
9450
9486
  return openBlock(), createElementBlock("div", {
9451
9487
  class: normalizeClass([
@@ -9483,7 +9519,7 @@ function _sfc_render$1w(_ctx, _cache, $props, $setup, $data, $options) {
9483
9519
  class: normalizeClass(_ctx.$style.greenTick),
9484
9520
  src: _ctx.images.checkGreen,
9485
9521
  alt: "green-tick"
9486
- }, null, 10, _hoisted_2$p),
9522
+ }, null, 10, _hoisted_2$s),
9487
9523
  createBaseVNode("span", {
9488
9524
  class: normalizeClass(_ctx.$style.autoCharge)
9489
9525
  }, toDisplayString(_ctx.lg.wallet.autoCharge), 3)
@@ -9507,10 +9543,10 @@ function _sfc_render$1w(_ctx, _cache, $props, $setup, $data, $options) {
9507
9543
  ], 2)
9508
9544
  ], 2);
9509
9545
  }
9510
- const cssModules$1l = {};
9511
- cssModules$1l["$style"] = style0$1l;
9512
- var WalletType = /* @__PURE__ */ _export_sfc(_sfc_main$1w, [["render", _sfc_render$1w], ["__cssModules", cssModules$1l]]);
9513
- const wrapperClass$m = "_wrapperClass_1cpol_1";
9546
+ const cssModules$1m = {};
9547
+ cssModules$1m["$style"] = style0$1m;
9548
+ var WalletType = /* @__PURE__ */ _export_sfc(_sfc_main$1x, [["render", _sfc_render$1x], ["__cssModules", cssModules$1m]]);
9549
+ const wrapperClass$n = "_wrapperClass_1cpol_1";
9514
9550
  const ppmnaPaymentTypeContainer$3 = "_ppmnaPaymentTypeContainer_1cpol_1";
9515
9551
  const img$d = "_img_1cpol_5";
9516
9552
  const imgContainer$4 = "_imgContainer_1cpol_18";
@@ -9527,14 +9563,14 @@ const auth = "_auth_1cpol_90";
9527
9563
  const authText = "_authText_1cpol_100";
9528
9564
  const cardImageContainer = "_cardImageContainer_1cpol_104";
9529
9565
  const cardImg = "_cardImg_1cpol_107";
9530
- const content$g = "_content_1cpol_111";
9566
+ const content$h = "_content_1cpol_111";
9531
9567
  const authenticated = "_authenticated_1cpol_121";
9532
9568
  const notAuthenticated = "_notAuthenticated_1cpol_124";
9533
9569
  const authorizedImg$1 = "_authorizedImg_1cpol_127";
9534
9570
  const unAuthorizedImg$1 = "_unAuthorizedImg_1cpol_136";
9535
9571
  const creditCard$1 = "_creditCard_1cpol_144";
9536
- var style0$1k = {
9537
- wrapperClass: wrapperClass$m,
9572
+ var style0$1l = {
9573
+ wrapperClass: wrapperClass$n,
9538
9574
  ppmnaPaymentTypeContainer: ppmnaPaymentTypeContainer$3,
9539
9575
  img: img$d,
9540
9576
  imgContainer: imgContainer$4,
@@ -9551,7 +9587,7 @@ var style0$1k = {
9551
9587
  authText,
9552
9588
  cardImageContainer,
9553
9589
  cardImg,
9554
- content: content$g,
9590
+ content: content$h,
9555
9591
  authenticated,
9556
9592
  notAuthenticated,
9557
9593
  authorizedImg: authorizedImg$1,
@@ -9566,7 +9602,7 @@ const creditCardMap$1 = {
9566
9602
  [CreditTypes.AMEX]: img$c.amex,
9567
9603
  yj: img$c.yahoo
9568
9604
  };
9569
- const _sfc_main$1v = defineComponent({
9605
+ const _sfc_main$1w = defineComponent({
9570
9606
  props: {
9571
9607
  credit: {
9572
9608
  type: Object,
@@ -9642,8 +9678,8 @@ const _sfc_main$1v = defineComponent({
9642
9678
  }
9643
9679
  });
9644
9680
  const _hoisted_1$S = ["src"];
9645
- const _hoisted_2$o = ["src"];
9646
- function _sfc_render$1v(_ctx, _cache, $props, $setup, $data, $options) {
9681
+ const _hoisted_2$r = ["src"];
9682
+ function _sfc_render$1w(_ctx, _cache, $props, $setup, $data, $options) {
9647
9683
  return openBlock(), createElementBlock("div", {
9648
9684
  class: normalizeClass([
9649
9685
  _ctx.style.wrapperClass,
@@ -9681,7 +9717,7 @@ function _sfc_render$1v(_ctx, _cache, $props, $setup, $data, $options) {
9681
9717
  createBaseVNode("img", {
9682
9718
  src: _ctx.authInfo.img,
9683
9719
  class: normalizeClass([_ctx.authInfo.authImg])
9684
- }, null, 10, _hoisted_2$o),
9720
+ }, null, 10, _hoisted_2$r),
9685
9721
  createBaseVNode("span", {
9686
9722
  class: normalizeClass([_ctx.style.authText])
9687
9723
  }, toDisplayString(_ctx.authInfo.text), 3)
@@ -9701,10 +9737,10 @@ function _sfc_render$1v(_ctx, _cache, $props, $setup, $data, $options) {
9701
9737
  ], 2)
9702
9738
  ], 2);
9703
9739
  }
9704
- const cssModules$1k = {};
9705
- cssModules$1k["$style"] = style0$1k;
9706
- var CreditCardType = /* @__PURE__ */ _export_sfc(_sfc_main$1v, [["render", _sfc_render$1v], ["__cssModules", cssModules$1k]]);
9707
- const wrapperClass$l = "_wrapperClass_insy7_1";
9740
+ const cssModules$1l = {};
9741
+ cssModules$1l["$style"] = style0$1l;
9742
+ var CreditCardType = /* @__PURE__ */ _export_sfc(_sfc_main$1w, [["render", _sfc_render$1w], ["__cssModules", cssModules$1l]]);
9743
+ const wrapperClass$m = "_wrapperClass_insy7_1";
9708
9744
  const ppmnaPaymentTypeContainer$2 = "_ppmnaPaymentTypeContainer_insy7_1";
9709
9745
  const img$b = "_img_insy7_5";
9710
9746
  const imgContainer$3 = "_imgContainer_insy7_18";
@@ -9718,12 +9754,12 @@ const arrowRight$2 = "_arrowRight_insy7_71";
9718
9754
  const makePaymentArrowContainer$2 = "_makePaymentArrowContainer_insy7_81";
9719
9755
  const bankImg = "_bankImg_insy7_85";
9720
9756
  const branchCode = "_branchCode_insy7_89";
9721
- const content$f = "_content_insy7_92";
9757
+ const content$g = "_content_insy7_92";
9722
9758
  const roundContainer = "_roundContainer_insy7_96";
9723
9759
  const round$2 = "_round_insy7_26";
9724
9760
  const bankName = "_bankName_insy7_102";
9725
- var style0$1j = {
9726
- wrapperClass: wrapperClass$l,
9761
+ var style0$1k = {
9762
+ wrapperClass: wrapperClass$m,
9727
9763
  ppmnaPaymentTypeContainer: ppmnaPaymentTypeContainer$2,
9728
9764
  img: img$b,
9729
9765
  imgContainer: imgContainer$3,
@@ -9737,7 +9773,7 @@ var style0$1j = {
9737
9773
  makePaymentArrowContainer: makePaymentArrowContainer$2,
9738
9774
  bankImg,
9739
9775
  branchCode,
9740
- content: content$f,
9776
+ content: content$g,
9741
9777
  roundContainer,
9742
9778
  round: round$2,
9743
9779
  bankName
@@ -9751,7 +9787,7 @@ const getTypeText$2 = (val2) => {
9751
9787
  return "";
9752
9788
  }
9753
9789
  };
9754
- const _sfc_main$1u = defineComponent({
9790
+ const _sfc_main$1v = defineComponent({
9755
9791
  props: {
9756
9792
  bank: {
9757
9793
  type: Object,
@@ -9796,7 +9832,7 @@ const _sfc_main$1u = defineComponent({
9796
9832
  }
9797
9833
  });
9798
9834
  const _hoisted_1$R = ["src"];
9799
- function _sfc_render$1u(_ctx, _cache, $props, $setup, $data, $options) {
9835
+ function _sfc_render$1v(_ctx, _cache, $props, $setup, $data, $options) {
9800
9836
  return openBlock(), createElementBlock("div", {
9801
9837
  class: normalizeClass([
9802
9838
  _ctx.style.wrapperClass,
@@ -9850,10 +9886,10 @@ function _sfc_render$1u(_ctx, _cache, $props, $setup, $data, $options) {
9850
9886
  ], 2)
9851
9887
  ], 2);
9852
9888
  }
9853
- const cssModules$1j = {};
9854
- cssModules$1j["$style"] = style0$1j;
9855
- var BankType = /* @__PURE__ */ _export_sfc(_sfc_main$1u, [["render", _sfc_render$1u], ["__cssModules", cssModules$1j]]);
9856
- const wrapperClass$k = "_wrapperClass_101rj_1";
9889
+ const cssModules$1k = {};
9890
+ cssModules$1k["$style"] = style0$1k;
9891
+ var BankType = /* @__PURE__ */ _export_sfc(_sfc_main$1v, [["render", _sfc_render$1v], ["__cssModules", cssModules$1k]]);
9892
+ const wrapperClass$l = "_wrapperClass_101rj_1";
9857
9893
  const ppmnaPaymentTypeContainer$1 = "_ppmnaPaymentTypeContainer_101rj_1";
9858
9894
  const img$a = "_img_101rj_5";
9859
9895
  const imgContainer$2 = "_imgContainer_101rj_18";
@@ -9867,11 +9903,11 @@ const arrowRight$1 = "_arrowRight_101rj_71";
9867
9903
  const makePaymentArrowContainer$1 = "_makePaymentArrowContainer_101rj_81";
9868
9904
  const container$y = "_container_101rj_85";
9869
9905
  const sbidImg = "_sbidImg_101rj_97";
9870
- const content$e = "_content_101rj_105";
9906
+ const content$f = "_content_101rj_105";
9871
9907
  const desc1 = "_desc1_101rj_118";
9872
9908
  const desc2 = "_desc2_101rj_122";
9873
- var style0$1i = {
9874
- wrapperClass: wrapperClass$k,
9909
+ var style0$1j = {
9910
+ wrapperClass: wrapperClass$l,
9875
9911
  ppmnaPaymentTypeContainer: ppmnaPaymentTypeContainer$1,
9876
9912
  img: img$a,
9877
9913
  imgContainer: imgContainer$2,
@@ -9885,11 +9921,11 @@ var style0$1i = {
9885
9921
  makePaymentArrowContainer: makePaymentArrowContainer$1,
9886
9922
  container: container$y,
9887
9923
  sbidImg,
9888
- content: content$e,
9924
+ content: content$f,
9889
9925
  desc1,
9890
9926
  desc2
9891
9927
  };
9892
- const _sfc_main$1t = defineComponent({
9928
+ const _sfc_main$1u = defineComponent({
9893
9929
  props: {
9894
9930
  sbid: {
9895
9931
  type: Object,
@@ -9917,7 +9953,7 @@ const _sfc_main$1t = defineComponent({
9917
9953
  }
9918
9954
  });
9919
9955
  const _hoisted_1$Q = ["src"];
9920
- function _sfc_render$1t(_ctx, _cache, $props, $setup, $data, $options) {
9956
+ function _sfc_render$1u(_ctx, _cache, $props, $setup, $data, $options) {
9921
9957
  return openBlock(), createElementBlock("div", {
9922
9958
  class: normalizeClass([_ctx.$style.wrapperClass, _ctx.$style.container])
9923
9959
  }, [
@@ -9951,10 +9987,10 @@ function _sfc_render$1t(_ctx, _cache, $props, $setup, $data, $options) {
9951
9987
  ], 2)
9952
9988
  ], 2);
9953
9989
  }
9954
- const cssModules$1i = {};
9955
- cssModules$1i["$style"] = style0$1i;
9956
- var SbidType = /* @__PURE__ */ _export_sfc(_sfc_main$1t, [["render", _sfc_render$1t], ["__cssModules", cssModules$1i]]);
9957
- const wrapperClass$j = "_wrapperClass_1nwz1_1";
9990
+ const cssModules$1j = {};
9991
+ cssModules$1j["$style"] = style0$1j;
9992
+ var SbidType = /* @__PURE__ */ _export_sfc(_sfc_main$1u, [["render", _sfc_render$1u], ["__cssModules", cssModules$1j]]);
9993
+ const wrapperClass$k = "_wrapperClass_1nwz1_1";
9958
9994
  const ppmnaPaymentTypeContainer = "_ppmnaPaymentTypeContainer_1nwz1_1";
9959
9995
  const img$9 = "_img_1nwz1_5";
9960
9996
  const imgContainer$1 = "_imgContainer_1nwz1_18";
@@ -9969,8 +10005,8 @@ const makePaymentArrowContainer = "_makePaymentArrowContainer_1nwz1_81";
9969
10005
  const container$x = "_container_1nwz1_86";
9970
10006
  const subTitle = "_subTitle_1nwz1_91";
9971
10007
  const imageContainer$5 = "_imageContainer_1nwz1_96";
9972
- var style0$1h = {
9973
- wrapperClass: wrapperClass$j,
10008
+ var style0$1i = {
10009
+ wrapperClass: wrapperClass$k,
9974
10010
  ppmnaPaymentTypeContainer,
9975
10011
  img: img$9,
9976
10012
  imgContainer: imgContainer$1,
@@ -9986,7 +10022,7 @@ var style0$1h = {
9986
10022
  subTitle,
9987
10023
  imageContainer: imageContainer$5
9988
10024
  };
9989
- const _sfc_main$1s = defineComponent({
10025
+ const _sfc_main$1t = defineComponent({
9990
10026
  props: {
9991
10027
  payLater: {
9992
10028
  type: Object,
@@ -10015,7 +10051,7 @@ const _sfc_main$1s = defineComponent({
10015
10051
  }
10016
10052
  });
10017
10053
  const _hoisted_1$P = ["src"];
10018
- function _sfc_render$1s(_ctx, _cache, $props, $setup, $data, $options) {
10054
+ function _sfc_render$1t(_ctx, _cache, $props, $setup, $data, $options) {
10019
10055
  return openBlock(), createElementBlock("div", {
10020
10056
  class: normalizeClass([
10021
10057
  _ctx.$style.wrapperClass,
@@ -10056,9 +10092,9 @@ function _sfc_render$1s(_ctx, _cache, $props, $setup, $data, $options) {
10056
10092
  ], 2)
10057
10093
  ], 2);
10058
10094
  }
10059
- const cssModules$1h = {};
10060
- cssModules$1h["$style"] = style0$1h;
10061
- var PayLaterType = /* @__PURE__ */ _export_sfc(_sfc_main$1s, [["render", _sfc_render$1s], ["__cssModules", cssModules$1h]]);
10095
+ const cssModules$1i = {};
10096
+ cssModules$1i["$style"] = style0$1i;
10097
+ var PayLaterType = /* @__PURE__ */ _export_sfc(_sfc_main$1t, [["render", _sfc_render$1t], ["__cssModules", cssModules$1i]]);
10062
10098
  const PaymentType = defineComponent({
10063
10099
  props: {
10064
10100
  paymentMethod: {
@@ -14344,7 +14380,7 @@ var lottie_svg = { exports: {} };
14344
14380
  lottie.useWebWorker = setWebWorker;
14345
14381
  lottie.setIDPrefix = setPrefix;
14346
14382
  lottie.__getFactory = getFactory;
14347
- lottie.version = "5.9.4";
14383
+ lottie.version = "5.9.6";
14348
14384
  function checkReady() {
14349
14385
  if (document.readyState === "complete") {
14350
14386
  clearInterval(readyStateCheckInterval);
@@ -22618,11 +22654,12 @@ var lottie_svg = { exports: {} };
22618
22654
  }
22619
22655
  };
22620
22656
  function SVGDropShadowEffect(filter, filterManager, elem2, id, source) {
22621
- var filterSize = filterManager.container.globalData.renderConfig.filterSize;
22622
- filter.setAttribute("x", filterSize.x);
22623
- filter.setAttribute("y", filterSize.y);
22624
- filter.setAttribute("width", filterSize.width);
22625
- filter.setAttribute("height", filterSize.height);
22657
+ var globalFilterSize = filterManager.container.globalData.renderConfig.filterSize;
22658
+ var filterSize = filterManager.data.fs || globalFilterSize;
22659
+ filter.setAttribute("x", filterSize.x || globalFilterSize.x);
22660
+ filter.setAttribute("y", filterSize.y || globalFilterSize.y);
22661
+ filter.setAttribute("width", filterSize.width || globalFilterSize.width);
22662
+ filter.setAttribute("height", filterSize.height || globalFilterSize.height);
22626
22663
  this.filterManager = filterManager;
22627
22664
  var feGaussianBlur = createNS("feGaussianBlur");
22628
22665
  feGaussianBlur.setAttribute("in", "SourceAlpha");
@@ -22867,16 +22904,16 @@ const Lottie = defineComponent({
22867
22904
  }, null);
22868
22905
  }
22869
22906
  });
22870
- const wrapperClass$i = "_wrapperClass_192d5_7";
22907
+ const wrapperClass$j = "_wrapperClass_192d5_7";
22871
22908
  const container$w = "_container_192d5_7";
22872
22909
  const header$a = "_header_192d5_21";
22873
22910
  const arrow$2 = "_arrow_192d5_28";
22874
22911
  const address$1 = "_address_192d5_37";
22875
22912
  const arrowContainer$1 = "_arrowContainer_192d5_46";
22876
22913
  const text$7 = "_text_192d5_57";
22877
- var style0$1g = {
22914
+ var style0$1h = {
22878
22915
  "ppmna-default-font": "_ppmna-default-font_192d5_1",
22879
- wrapperClass: wrapperClass$i,
22916
+ wrapperClass: wrapperClass$j,
22880
22917
  container: container$w,
22881
22918
  header: header$a,
22882
22919
  arrow: arrow$2,
@@ -22884,7 +22921,7 @@ var style0$1g = {
22884
22921
  arrowContainer: arrowContainer$1,
22885
22922
  text: text$7
22886
22923
  };
22887
- const _sfc_main$1r = defineComponent({
22924
+ const _sfc_main$1s = defineComponent({
22888
22925
  name: "AddressInfo",
22889
22926
  components: {},
22890
22927
  props: {
@@ -22926,7 +22963,7 @@ const _sfc_main$1r = defineComponent({
22926
22963
  };
22927
22964
  }
22928
22965
  });
22929
- function _sfc_render$1r(_ctx, _cache, $props, $setup, $data, $options) {
22966
+ function _sfc_render$1s(_ctx, _cache, $props, $setup, $data, $options) {
22930
22967
  return openBlock(), createElementBlock("div", {
22931
22968
  class: normalizeClass([_ctx.style.wrapperClass, _ctx.style.container])
22932
22969
  }, [
@@ -22958,23 +22995,23 @@ function _sfc_render$1r(_ctx, _cache, $props, $setup, $data, $options) {
22958
22995
  ], 2)
22959
22996
  ], 2);
22960
22997
  }
22961
- const cssModules$1g = {};
22962
- cssModules$1g["$style"] = style0$1g;
22963
- var AddressInfo$1 = /* @__PURE__ */ _export_sfc(_sfc_main$1r, [["render", _sfc_render$1r], ["__cssModules", cssModules$1g]]);
22964
- const wrapperClass$h = "_wrapperClass_1vjx2_1";
22965
- const paymentMethodContainer$4 = "_paymentMethodContainer_1vjx2_1";
22966
- const imageWrapper$3 = "_imageWrapper_1vjx2_6";
22967
- const imageContainer$4 = "_imageContainer_1vjx2_10";
22968
- const roundStylePaymentMethod$3 = "_roundStylePaymentMethod_1vjx2_19";
22969
- const label$7 = "_label_1vjx2_23";
22970
- const mainLabel$4 = "_mainLabel_1vjx2_30";
22971
- const subLabel$4 = "_subLabel_1vjx2_37";
22972
- const invalid$5 = "_invalid_1vjx2_46";
22973
- const rightAlign$5 = "_rightAlign_1vjx2_52";
22974
- const paymentMethodDisabled$4 = "_paymentMethodDisabled_1vjx2_57";
22975
- const img$8 = "_img_1vjx2_63";
22976
- var style0$1f = {
22977
- wrapperClass: wrapperClass$h,
22998
+ const cssModules$1h = {};
22999
+ cssModules$1h["$style"] = style0$1h;
23000
+ var AddressInfo$1 = /* @__PURE__ */ _export_sfc(_sfc_main$1s, [["render", _sfc_render$1s], ["__cssModules", cssModules$1h]]);
23001
+ const wrapperClass$i = "_wrapperClass_otzwj_1";
23002
+ const paymentMethodContainer$4 = "_paymentMethodContainer_otzwj_1";
23003
+ const imageWrapper$3 = "_imageWrapper_otzwj_6";
23004
+ const imageContainer$4 = "_imageContainer_otzwj_10";
23005
+ const roundStylePaymentMethod$3 = "_roundStylePaymentMethod_otzwj_19";
23006
+ const label$7 = "_label_otzwj_23";
23007
+ const mainLabel$4 = "_mainLabel_otzwj_30";
23008
+ const subLabel$4 = "_subLabel_otzwj_37";
23009
+ const invalid$5 = "_invalid_otzwj_46";
23010
+ const rightAlign$5 = "_rightAlign_otzwj_58";
23011
+ const paymentMethodDisabled$4 = "_paymentMethodDisabled_otzwj_63";
23012
+ const img$8 = "_img_otzwj_68";
23013
+ var style0$1g = {
23014
+ wrapperClass: wrapperClass$i,
22978
23015
  paymentMethodContainer: paymentMethodContainer$4,
22979
23016
  imageWrapper: imageWrapper$3,
22980
23017
  imageContainer: imageContainer$4,
@@ -22987,7 +23024,7 @@ var style0$1f = {
22987
23024
  paymentMethodDisabled: paymentMethodDisabled$4,
22988
23025
  img: img$8
22989
23026
  };
22990
- const _sfc_main$1q = defineComponent({
23027
+ const _sfc_main$1r = defineComponent({
22991
23028
  components: {
22992
23029
  WalletBreakdown
22993
23030
  },
@@ -22997,6 +23034,9 @@ const _sfc_main$1q = defineComponent({
22997
23034
  required: true
22998
23035
  }
22999
23036
  },
23037
+ emits: {
23038
+ select: () => true
23039
+ },
23000
23040
  setup(props) {
23001
23041
  const openBreakDown = ref(false);
23002
23042
  const toggleBreakDown = () => {
@@ -23038,10 +23078,11 @@ const _sfc_main$1q = defineComponent({
23038
23078
  }
23039
23079
  });
23040
23080
  const _hoisted_1$O = ["src"];
23041
- function _sfc_render$1q(_ctx, _cache, $props, $setup, $data, $options) {
23081
+ function _sfc_render$1r(_ctx, _cache, $props, $setup, $data, $options) {
23042
23082
  const _component_WalletBreakdown = resolveComponent("WalletBreakdown");
23043
23083
  return openBlock(), createElementBlock("div", {
23044
- class: normalizeClass([_ctx.style.wrapperClass, _ctx.style.paymentMethodContainer])
23084
+ class: normalizeClass([_ctx.style.wrapperClass, _ctx.style.paymentMethodContainer]),
23085
+ onClick: _cache[0] || (_cache[0] = ($event) => _ctx.$emit("select"))
23045
23086
  }, [
23046
23087
  createBaseVNode("div", {
23047
23088
  class: normalizeClass(_ctx.style.imageContainer)
@@ -23065,36 +23106,36 @@ function _sfc_render$1q(_ctx, _cache, $props, $setup, $data, $options) {
23065
23106
  ], 2)
23066
23107
  ], 2);
23067
23108
  }
23068
- const cssModules$1f = {};
23069
- cssModules$1f["$style"] = style0$1f;
23070
- var Wallet = /* @__PURE__ */ _export_sfc(_sfc_main$1q, [["render", _sfc_render$1q], ["__cssModules", cssModules$1f]]);
23071
- const wrapperClass$g = "_wrapperClass_84gij_1";
23072
- const paymentMethodContainer$3 = "_paymentMethodContainer_84gij_1";
23073
- const imageWrapper$2 = "_imageWrapper_84gij_6";
23074
- const imageContainer$3 = "_imageContainer_84gij_10";
23075
- const roundStylePaymentMethod$2 = "_roundStylePaymentMethod_84gij_19";
23076
- const label$6 = "_label_84gij_23";
23077
- const mainLabel$3 = "_mainLabel_84gij_30";
23078
- const subLabel$3 = "_subLabel_84gij_37";
23079
- const invalid$4 = "_invalid_84gij_46";
23080
- const rightAlign$4 = "_rightAlign_84gij_52";
23081
- const paymentMethodDisabled$3 = "_paymentMethodDisabled_84gij_57";
23082
- const img$7 = "_img_84gij_63";
23083
- const round$1 = "_round_84gij_19";
23084
- const creditCardLabel = "_creditCardLabel_84gij_70";
23085
- const authenticateStatusContainer = "_authenticateStatusContainer_84gij_75";
23086
- const unAuthorizedImg = "_unAuthorizedImg_84gij_82";
23087
- const unAuthorized = "_unAuthorized_84gij_82";
23088
- const authorized = "_authorized_84gij_88";
23089
- const authorizedImg = "_authorizedImg_84gij_91";
23090
- const creditCard = "_creditCard_84gij_70";
23091
- const maintainanceInfo$2 = "_maintainanceInfo_84gij_98";
23092
- const paymentInfo$2 = "_paymentInfo_84gij_104";
23093
- const fullWidth$1 = "_fullWidth_84gij_107";
23094
- const cardInfo = "_cardInfo_84gij_110";
23095
- const additionDescription = "_additionDescription_84gij_115";
23096
- var style0$1e = {
23097
- wrapperClass: wrapperClass$g,
23109
+ const cssModules$1g = {};
23110
+ cssModules$1g["$style"] = style0$1g;
23111
+ var Wallet = /* @__PURE__ */ _export_sfc(_sfc_main$1r, [["render", _sfc_render$1r], ["__cssModules", cssModules$1g]]);
23112
+ const wrapperClass$h = "_wrapperClass_mf296_1";
23113
+ const paymentMethodContainer$3 = "_paymentMethodContainer_mf296_1";
23114
+ const imageWrapper$2 = "_imageWrapper_mf296_6";
23115
+ const imageContainer$3 = "_imageContainer_mf296_10";
23116
+ const roundStylePaymentMethod$2 = "_roundStylePaymentMethod_mf296_19";
23117
+ const label$6 = "_label_mf296_23";
23118
+ const mainLabel$3 = "_mainLabel_mf296_30";
23119
+ const subLabel$3 = "_subLabel_mf296_37";
23120
+ const invalid$4 = "_invalid_mf296_46";
23121
+ const rightAlign$4 = "_rightAlign_mf296_58";
23122
+ const paymentMethodDisabled$3 = "_paymentMethodDisabled_mf296_63";
23123
+ const img$7 = "_img_mf296_68";
23124
+ const round$1 = "_round_mf296_19";
23125
+ const creditCardLabel = "_creditCardLabel_mf296_75";
23126
+ const authenticateStatusContainer = "_authenticateStatusContainer_mf296_80";
23127
+ const unAuthorizedImg = "_unAuthorizedImg_mf296_87";
23128
+ const unAuthorized = "_unAuthorized_mf296_87";
23129
+ const authorized = "_authorized_mf296_93";
23130
+ const authorizedImg = "_authorizedImg_mf296_96";
23131
+ const creditCard = "_creditCard_mf296_75";
23132
+ const maintainanceInfo$3 = "_maintainanceInfo_mf296_103";
23133
+ const paymentInfo$3 = "_paymentInfo_mf296_110";
23134
+ const fullWidth$1 = "_fullWidth_mf296_113";
23135
+ const cardInfo = "_cardInfo_mf296_117";
23136
+ const additionDescription = "_additionDescription_mf296_123";
23137
+ var style0$1f = {
23138
+ wrapperClass: wrapperClass$h,
23098
23139
  paymentMethodContainer: paymentMethodContainer$3,
23099
23140
  imageWrapper: imageWrapper$2,
23100
23141
  imageContainer: imageContainer$3,
@@ -23114,8 +23155,8 @@ var style0$1e = {
23114
23155
  authorized,
23115
23156
  authorizedImg,
23116
23157
  creditCard,
23117
- maintainanceInfo: maintainanceInfo$2,
23118
- paymentInfo: paymentInfo$2,
23158
+ maintainanceInfo: maintainanceInfo$3,
23159
+ paymentInfo: paymentInfo$3,
23119
23160
  fullWidth: fullWidth$1,
23120
23161
  cardInfo,
23121
23162
  additionDescription
@@ -23127,7 +23168,7 @@ const creditCardMap = {
23127
23168
  [CreditTypes.MASTER]: img$6.master,
23128
23169
  [CreditTypes.AMEX]: img$6.amex
23129
23170
  };
23130
- const _sfc_main$1p = defineComponent({
23171
+ const _sfc_main$1q = defineComponent({
23131
23172
  components: {
23132
23173
  Button
23133
23174
  },
@@ -23142,7 +23183,10 @@ const _sfc_main$1p = defineComponent({
23142
23183
  default: false
23143
23184
  }
23144
23185
  },
23145
- setup(props) {
23186
+ emits: {
23187
+ select: () => true
23188
+ },
23189
+ setup(props, { emit }) {
23146
23190
  const style = useCssModule();
23147
23191
  const isYjCard = computed(() => {
23148
23192
  var _a, _b;
@@ -23156,9 +23200,9 @@ const _sfc_main$1p = defineComponent({
23156
23200
  var _a, _b;
23157
23201
  return (_b = (_a = props.credit) == null ? void 0 : _a.creditCardInfo) == null ? void 0 : _b.isExpired;
23158
23202
  });
23159
- const isActivated = computed(() => {
23203
+ const isDisable = computed(() => {
23160
23204
  var _a, _b;
23161
- return ((_b = (_a = props.credit) == null ? void 0 : _a.creditCardInfo) == null ? void 0 : _b.paymentMethodStatus) === "ACTIVATED";
23205
+ return ((_b = (_a = props.credit) == null ? void 0 : _a.creditCardInfo) == null ? void 0 : _b.paymentMethodStatus) !== "ACTIVATED" || isExpired.value;
23162
23206
  });
23163
23207
  const authInfo = computed(() => {
23164
23208
  var _a, _b;
@@ -23201,18 +23245,25 @@ const _sfc_main$1p = defineComponent({
23201
23245
  style: props.round ? style.round : style.creditCard
23202
23246
  };
23203
23247
  });
23204
- const paymentMethodStatus2 = computed(() => {
23205
- var _a, _b;
23206
- return (_b = (_a = props.credit) == null ? void 0 : _a.creditCardInfo) == null ? void 0 : _b.paymentMethodStatus;
23207
- });
23208
23248
  const paymentMethodStatusText = computed(() => {
23209
- var _a;
23210
- return getPaymentMethodStatus((_a = isExpired.value) != null ? _a : false, paymentMethodStatus2.value);
23249
+ var _a, _b;
23250
+ return getPaymentMethodStatus((_a = isExpired.value) != null ? _a : false, (_b = props.credit) == null ? void 0 : _b.creditCardInfo);
23211
23251
  });
23212
23252
  const additionalDescription = computed(() => {
23213
23253
  var _a;
23214
23254
  return (_a = props.credit.paymentMethodDescriptionInfo) == null ? void 0 : _a.additionalDescription;
23215
23255
  });
23256
+ const handleClick = (e, info2) => {
23257
+ if (info2 == null ? void 0 : info2.linkUrl) {
23258
+ e == null ? void 0 : e.stopPropagation();
23259
+ openUrl(info2.linkUrl);
23260
+ }
23261
+ };
23262
+ const handleSelect = () => {
23263
+ if (isDisable.value)
23264
+ return;
23265
+ emit("select");
23266
+ };
23216
23267
  return {
23217
23268
  last4digits: computed(() => {
23218
23269
  var _a, _b;
@@ -23220,25 +23271,36 @@ const _sfc_main$1p = defineComponent({
23220
23271
  }),
23221
23272
  authInfo,
23222
23273
  paymentMethodStatusText,
23223
- maintainanceInfo: computed(() => {
23224
- var _a, _b, _c, _d;
23225
- return (_d = (_c = (_b = (_a = props.credit) == null ? void 0 : _a.paymentMethodDescriptionInfo) == null ? void 0 : _b.statusDescription) == null ? void 0 : _c.text) != null ? _d : "";
23226
- }),
23227
- getClass: isExpired.value || paymentMethodStatus2.value !== "ACTIVATED" ? style.paymentMethodDisabled : "",
23228
- isActivated,
23274
+ getClass: isDisable.value ? style.paymentMethodDisabled : "",
23275
+ isDisable,
23229
23276
  style,
23230
23277
  cardInfo: cardInfo2,
23231
- isExpired,
23232
- additionalDescription
23278
+ additionalDescription,
23279
+ payMethodDescriptionInfo: computed(() => {
23280
+ var _a, _b, _c, _d;
23281
+ return [
23282
+ (_b = (_a = props.credit) == null ? void 0 : _a.paymentMethodDescriptionInfo) == null ? void 0 : _b.statusDescription,
23283
+ (_d = (_c = props.credit) == null ? void 0 : _c.paymentMethodDescriptionInfo) == null ? void 0 : _d.detailDescription
23284
+ ].filter((info2) => !!info2);
23285
+ }),
23286
+ getMaintenanceStyle: computed(() => (info2) => {
23287
+ return {
23288
+ color: info2.color
23289
+ };
23290
+ }),
23291
+ handleClick,
23292
+ handleSelect
23233
23293
  };
23234
23294
  }
23235
23295
  });
23236
23296
  const _hoisted_1$N = ["src"];
23237
- const _hoisted_2$n = ["src"];
23238
- function _sfc_render$1p(_ctx, _cache, $props, $setup, $data, $options) {
23297
+ const _hoisted_2$q = ["src"];
23298
+ const _hoisted_3$e = ["onClick"];
23299
+ function _sfc_render$1q(_ctx, _cache, $props, $setup, $data, $options) {
23239
23300
  const _component_Button = resolveComponent("Button");
23240
23301
  return openBlock(), createElementBlock("div", {
23241
- class: normalizeClass([_ctx.style.wrapperClass, _ctx.style.paymentMethodContainer, _ctx.getClass])
23302
+ class: normalizeClass([_ctx.style.wrapperClass, _ctx.style.paymentMethodContainer, _ctx.getClass]),
23303
+ onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleSelect && _ctx.handleSelect(...args))
23242
23304
  }, [
23243
23305
  createBaseVNode("div", {
23244
23306
  class: normalizeClass(_ctx.style.imageWrapper)
@@ -23283,7 +23345,7 @@ function _sfc_render$1p(_ctx, _cache, $props, $setup, $data, $options) {
23283
23345
  createBaseVNode("img", {
23284
23346
  src: _ctx.authInfo.img,
23285
23347
  class: normalizeClass(_ctx.authInfo.imgStyle)
23286
- }, null, 10, _hoisted_2$n),
23348
+ }, null, 10, _hoisted_2$q),
23287
23349
  createBaseVNode("span", null, toDisplayString(_ctx.authInfo.text), 1)
23288
23350
  ], 2)
23289
23351
  ], 2),
@@ -23300,7 +23362,7 @@ function _sfc_render$1p(_ctx, _cache, $props, $setup, $data, $options) {
23300
23362
  createBaseVNode("span", {
23301
23363
  class: normalizeClass(_ctx.style.rightAlign)
23302
23364
  }, [
23303
- !_ctx.isActivated || _ctx.isExpired ? (openBlock(), createBlock(_component_Button, {
23365
+ _ctx.isDisable ? (openBlock(), createBlock(_component_Button, {
23304
23366
  key: 0,
23305
23367
  disabled: true,
23306
23368
  class: normalizeClass(_ctx.style.invalid),
@@ -23314,35 +23376,40 @@ function _sfc_render$1p(_ctx, _cache, $props, $setup, $data, $options) {
23314
23376
  }, 8, ["class"])) : createCommentVNode("", true)
23315
23377
  ], 2)
23316
23378
  ], 2),
23317
- _ctx.maintainanceInfo ? (openBlock(), createElementBlock("div", {
23318
- key: 0,
23319
- class: normalizeClass(_ctx.style.maintainanceInfo)
23320
- }, toDisplayString(_ctx.maintainanceInfo), 3)) : createCommentVNode("", true)
23379
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.payMethodDescriptionInfo, (info2, index2) => {
23380
+ return openBlock(), createElementBlock("div", {
23381
+ key: index2,
23382
+ class: normalizeClass(_ctx.style.maintainanceInfo),
23383
+ style: normalizeStyle(_ctx.getMaintenanceStyle(info2)),
23384
+ "data-testid": "description-info",
23385
+ onClick: ($event) => _ctx.handleClick($event, info2)
23386
+ }, toDisplayString(info2.text), 15, _hoisted_3$e);
23387
+ }), 128))
23321
23388
  ], 2)
23322
23389
  ], 2);
23323
23390
  }
23324
- const cssModules$1e = {};
23325
- cssModules$1e["$style"] = style0$1e;
23326
- var CreditCard = /* @__PURE__ */ _export_sfc(_sfc_main$1p, [["render", _sfc_render$1p], ["__cssModules", cssModules$1e]]);
23327
- const wrapperClass$f = "_wrapperClass_x170y_1";
23328
- const paymentMethodContainer$2 = "_paymentMethodContainer_x170y_1";
23329
- const imageWrapper$1 = "_imageWrapper_x170y_6";
23330
- const imageContainer$2 = "_imageContainer_x170y_10";
23331
- const roundStylePaymentMethod$1 = "_roundStylePaymentMethod_x170y_19";
23332
- const label$5 = "_label_x170y_23";
23333
- const mainLabel$2 = "_mainLabel_x170y_30";
23334
- const subLabel$2 = "_subLabel_x170y_37";
23335
- const invalid$3 = "_invalid_x170y_46";
23336
- const rightAlign$3 = "_rightAlign_x170y_52";
23337
- const paymentMethodDisabled$2 = "_paymentMethodDisabled_x170y_57";
23338
- const img$5 = "_img_x170y_63";
23339
- const round = "_round_x170y_19";
23340
- const branchNumber$1 = "_branchNumber_x170y_70";
23341
- const maintainanceInfo$1 = "_maintainanceInfo_x170y_76";
23342
- const paymentInfo$1 = "_paymentInfo_x170y_82";
23343
- const fullWidth = "_fullWidth_x170y_85";
23344
- var style0$1d = {
23345
- wrapperClass: wrapperClass$f,
23391
+ const cssModules$1f = {};
23392
+ cssModules$1f["$style"] = style0$1f;
23393
+ var CreditCard = /* @__PURE__ */ _export_sfc(_sfc_main$1q, [["render", _sfc_render$1q], ["__cssModules", cssModules$1f]]);
23394
+ const wrapperClass$g = "_wrapperClass_6wfpf_1";
23395
+ const paymentMethodContainer$2 = "_paymentMethodContainer_6wfpf_1";
23396
+ const imageWrapper$1 = "_imageWrapper_6wfpf_6";
23397
+ const imageContainer$2 = "_imageContainer_6wfpf_10";
23398
+ const roundStylePaymentMethod$1 = "_roundStylePaymentMethod_6wfpf_19";
23399
+ const label$5 = "_label_6wfpf_23";
23400
+ const mainLabel$2 = "_mainLabel_6wfpf_30";
23401
+ const subLabel$2 = "_subLabel_6wfpf_37";
23402
+ const invalid$3 = "_invalid_6wfpf_46";
23403
+ const rightAlign$3 = "_rightAlign_6wfpf_58";
23404
+ const paymentMethodDisabled$2 = "_paymentMethodDisabled_6wfpf_63";
23405
+ const img$5 = "_img_6wfpf_68";
23406
+ const round = "_round_6wfpf_19";
23407
+ const branchNumber$1 = "_branchNumber_6wfpf_75";
23408
+ const maintainanceInfo$2 = "_maintainanceInfo_6wfpf_81";
23409
+ const paymentInfo$2 = "_paymentInfo_6wfpf_87";
23410
+ const fullWidth = "_fullWidth_6wfpf_90";
23411
+ var style0$1e = {
23412
+ wrapperClass: wrapperClass$g,
23346
23413
  paymentMethodContainer: paymentMethodContainer$2,
23347
23414
  imageWrapper: imageWrapper$1,
23348
23415
  imageContainer: imageContainer$2,
@@ -23356,8 +23423,8 @@ var style0$1d = {
23356
23423
  img: img$5,
23357
23424
  round,
23358
23425
  branchNumber: branchNumber$1,
23359
- maintainanceInfo: maintainanceInfo$1,
23360
- paymentInfo: paymentInfo$1,
23426
+ maintainanceInfo: maintainanceInfo$2,
23427
+ paymentInfo: paymentInfo$2,
23361
23428
  fullWidth
23362
23429
  };
23363
23430
  const getTypeText$1 = (val2) => {
@@ -23369,7 +23436,7 @@ const getTypeText$1 = (val2) => {
23369
23436
  return "";
23370
23437
  }
23371
23438
  };
23372
- const _sfc_main$1o = defineComponent({
23439
+ const _sfc_main$1p = defineComponent({
23373
23440
  components: {
23374
23441
  Button
23375
23442
  },
@@ -23384,18 +23451,20 @@ const _sfc_main$1o = defineComponent({
23384
23451
  default: false
23385
23452
  }
23386
23453
  },
23387
- setup(props) {
23388
- var _a, _b;
23454
+ emits: {
23455
+ select: () => true
23456
+ },
23457
+ setup(props, { emit }) {
23389
23458
  const bankInfo2 = computed(() => {
23390
- var _a2, _b2;
23391
- const bankInfo22 = ((_a2 = props.bank) == null ? void 0 : _a2.bankInfo) || null;
23459
+ var _a, _b;
23460
+ const bankInfo22 = ((_a = props.bank) == null ? void 0 : _a.bankInfo) || null;
23392
23461
  const logo = bankInfo22 == null ? void 0 : bankInfo22.bankLogoUrl;
23393
23462
  const name2 = bankInfo22 == null ? void 0 : bankInfo22.bankName;
23394
23463
  let branchCode2 = bankInfo22 == null ? void 0 : bankInfo22.bankBranchCode;
23395
23464
  const branchName = bankInfo22 == null ? void 0 : bankInfo22.bankBranchName;
23396
23465
  const digits = bankInfo22 == null ? void 0 : bankInfo22.bankAccountNumberLast2digits;
23397
23466
  if ((bankInfo22 == null ? void 0 : bankInfo22.bankCode) !== bankCode.YUCHO_BANK_CODE) {
23398
- branchCode2 = getTypeText$1((_b2 = bankInfo22 == null ? void 0 : bankInfo22.bankAccountType) != null ? _b2 : "");
23467
+ branchCode2 = getTypeText$1((_b = bankInfo22 == null ? void 0 : bankInfo22.bankAccountType) != null ? _b : "");
23399
23468
  }
23400
23469
  return {
23401
23470
  logo,
@@ -23406,30 +23475,54 @@ const _sfc_main$1o = defineComponent({
23406
23475
  };
23407
23476
  });
23408
23477
  const style = useCssModule();
23478
+ const handleClick = (e, info2) => {
23479
+ if (info2 == null ? void 0 : info2.linkUrl) {
23480
+ e == null ? void 0 : e.stopPropagation();
23481
+ openUrl(info2.linkUrl);
23482
+ }
23483
+ };
23484
+ const isDisable = computed(() => {
23485
+ var _a, _b;
23486
+ return ((_b = (_a = props.bank) == null ? void 0 : _a.bankInfo) == null ? void 0 : _b.paymentMethodStatus) !== PaymentMethodStatus.ACTIVATED;
23487
+ });
23488
+ const handleSelect = () => {
23489
+ if (isDisable == null ? void 0 : isDisable.value)
23490
+ return;
23491
+ emit("select");
23492
+ };
23409
23493
  return {
23410
23494
  bankInfo: bankInfo2,
23411
- isDisable: computed(() => {
23412
- var _a2, _b2;
23413
- return ((_b2 = (_a2 = props.bank) == null ? void 0 : _a2.bankInfo) == null ? void 0 : _b2.paymentMethodStatus) !== "ACTIVATED";
23495
+ isDisable,
23496
+ paymentMethodStatusText: computed(() => {
23497
+ var _a;
23498
+ return getPaymentMethodStatus(false, (_a = props.bank) == null ? void 0 : _a.bankInfo);
23414
23499
  }),
23415
- paymentMethodStatus: computed(() => {
23416
- var _a2, _b2;
23417
- return getPaymentMethodStatus(false, (_b2 = (_a2 = props.bank) == null ? void 0 : _a2.bankInfo) == null ? void 0 : _b2.paymentMethodStatus);
23500
+ getClass: (isDisable == null ? void 0 : isDisable.value) ? style.paymentMethodDisabled : "",
23501
+ style,
23502
+ payMethodDescriptionInfo: computed(() => {
23503
+ var _a, _b, _c, _d;
23504
+ return [
23505
+ (_b = (_a = props.bank) == null ? void 0 : _a.paymentMethodDescriptionInfo) == null ? void 0 : _b.statusDescription,
23506
+ (_d = (_c = props.bank) == null ? void 0 : _c.paymentMethodDescriptionInfo) == null ? void 0 : _d.detailDescription
23507
+ ].filter((info2) => !!info2);
23418
23508
  }),
23419
- maintainanceInfo: computed(() => {
23420
- var _a2, _b2, _c, _d;
23421
- return (_d = (_c = (_b2 = (_a2 = props.bank) == null ? void 0 : _a2.paymentMethodDescriptionInfo) == null ? void 0 : _b2.statusDescription) == null ? void 0 : _c.text) != null ? _d : "";
23509
+ getMaintenanceStyle: computed(() => (info2) => {
23510
+ return {
23511
+ color: info2.color
23512
+ };
23422
23513
  }),
23423
- getClass: ((_b = (_a = props.bank) == null ? void 0 : _a.bankInfo) == null ? void 0 : _b.paymentMethodStatus) !== "ACTIVATED" ? style.paymentMethodDisabled : "",
23424
- style
23514
+ handleClick,
23515
+ handleSelect
23425
23516
  };
23426
23517
  }
23427
23518
  });
23428
23519
  const _hoisted_1$M = ["src"];
23429
- function _sfc_render$1o(_ctx, _cache, $props, $setup, $data, $options) {
23520
+ const _hoisted_2$p = ["onClick"];
23521
+ function _sfc_render$1p(_ctx, _cache, $props, $setup, $data, $options) {
23430
23522
  const _component_Button = resolveComponent("Button");
23431
23523
  return openBlock(), createElementBlock("div", {
23432
- class: normalizeClass([_ctx.style.wrapperClass, _ctx.style.paymentMethodContainer, _ctx.getClass])
23524
+ class: normalizeClass([_ctx.style.wrapperClass, _ctx.style.paymentMethodContainer, _ctx.getClass]),
23525
+ onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleSelect && _ctx.handleSelect(...args))
23433
23526
  }, [
23434
23527
  createBaseVNode("div", {
23435
23528
  class: normalizeClass(_ctx.style.imageWrapper)
@@ -23482,53 +23575,57 @@ function _sfc_render$1o(_ctx, _cache, $props, $setup, $data, $options) {
23482
23575
  type: "default"
23483
23576
  }, {
23484
23577
  default: withCtx(() => [
23485
- createTextVNode(toDisplayString(_ctx.paymentMethodStatus), 1)
23578
+ createTextVNode(toDisplayString(_ctx.paymentMethodStatusText), 1)
23486
23579
  ]),
23487
23580
  _: 1
23488
23581
  }, 8, ["class"])) : createCommentVNode("", true)
23489
23582
  ], 2)
23490
23583
  ], 2),
23491
- _ctx.maintainanceInfo ? (openBlock(), createElementBlock("div", {
23492
- key: 0,
23493
- class: normalizeClass(_ctx.style.maintainanceInfo)
23494
- }, toDisplayString(_ctx.maintainanceInfo), 3)) : createCommentVNode("", true)
23584
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.payMethodDescriptionInfo, (info2, index2) => {
23585
+ return openBlock(), createElementBlock("div", {
23586
+ key: index2,
23587
+ class: normalizeClass(_ctx.style.maintainanceInfo),
23588
+ style: normalizeStyle(_ctx.getMaintenanceStyle(info2)),
23589
+ onClick: ($event) => _ctx.handleClick($event, info2)
23590
+ }, toDisplayString(info2.text), 15, _hoisted_2$p);
23591
+ }), 128))
23495
23592
  ], 2)
23496
23593
  ], 2);
23497
23594
  }
23498
- const cssModules$1d = {};
23499
- cssModules$1d["$style"] = style0$1d;
23500
- var Bank = /* @__PURE__ */ _export_sfc(_sfc_main$1o, [["render", _sfc_render$1o], ["__cssModules", cssModules$1d]]);
23501
- const wrapperClass$e = "_wrapperClass_w4u0m_1";
23502
- const container$v = "_container_w4u0m_1";
23503
- const imageContainer$1 = "_imageContainer_w4u0m_7";
23504
- const img$4 = "_img_w4u0m_10";
23505
- const content$d = "_content_w4u0m_15";
23506
- const paymentInfo = "_paymentInfo_w4u0m_19";
23507
- const paymentDesc = "_paymentDesc_w4u0m_23";
23508
- const mainDesc = "_mainDesc_w4u0m_27";
23509
- const subDesc = "_subDesc_w4u0m_34";
23510
- const disable = "_disable_w4u0m_40";
23511
- const centerAlign = "_centerAlign_w4u0m_46";
23512
- const maintainanceInfo = "_maintainanceInfo_w4u0m_49";
23513
- const invalid$2 = "_invalid_w4u0m_55";
23514
- const paymentMethodDisabled$1 = "_paymentMethodDisabled_w4u0m_60";
23515
- var style0$1c = {
23516
- wrapperClass: wrapperClass$e,
23595
+ const cssModules$1e = {};
23596
+ cssModules$1e["$style"] = style0$1e;
23597
+ var Bank = /* @__PURE__ */ _export_sfc(_sfc_main$1p, [["render", _sfc_render$1p], ["__cssModules", cssModules$1e]]);
23598
+ const wrapperClass$f = "_wrapperClass_4g7cx_1";
23599
+ const container$v = "_container_4g7cx_1";
23600
+ const imageContainer$1 = "_imageContainer_4g7cx_7";
23601
+ const img$4 = "_img_4g7cx_10";
23602
+ const content$e = "_content_4g7cx_15";
23603
+ const paymentInfo$1 = "_paymentInfo_4g7cx_19";
23604
+ const paymentDesc = "_paymentDesc_4g7cx_23";
23605
+ const mainDesc = "_mainDesc_4g7cx_27";
23606
+ const subDesc = "_subDesc_4g7cx_34";
23607
+ const disable = "_disable_4g7cx_40";
23608
+ const centerAlign = "_centerAlign_4g7cx_46";
23609
+ const maintainanceInfo$1 = "_maintainanceInfo_4g7cx_49";
23610
+ const invalid$2 = "_invalid_4g7cx_55";
23611
+ const paymentMethodDisabled$1 = "_paymentMethodDisabled_4g7cx_66";
23612
+ var style0$1d = {
23613
+ wrapperClass: wrapperClass$f,
23517
23614
  container: container$v,
23518
23615
  imageContainer: imageContainer$1,
23519
23616
  img: img$4,
23520
- content: content$d,
23521
- paymentInfo,
23617
+ content: content$e,
23618
+ paymentInfo: paymentInfo$1,
23522
23619
  paymentDesc,
23523
23620
  mainDesc,
23524
23621
  subDesc,
23525
23622
  disable,
23526
23623
  centerAlign,
23527
- maintainanceInfo,
23624
+ maintainanceInfo: maintainanceInfo$1,
23528
23625
  invalid: invalid$2,
23529
23626
  paymentMethodDisabled: paymentMethodDisabled$1
23530
23627
  };
23531
- const _sfc_main$1n = defineComponent({
23628
+ const _sfc_main$1o = defineComponent({
23532
23629
  components: {
23533
23630
  Button
23534
23631
  },
@@ -23538,31 +23635,56 @@ const _sfc_main$1n = defineComponent({
23538
23635
  required: true
23539
23636
  }
23540
23637
  },
23541
- setup(props) {
23542
- var _a, _b;
23638
+ emits: {
23639
+ select: () => true
23640
+ },
23641
+ setup(props, { emit }) {
23543
23642
  const style = useCssModule();
23643
+ const handleClick = (e, info2) => {
23644
+ if (info2 == null ? void 0 : info2.linkUrl) {
23645
+ e == null ? void 0 : e.stopPropagation();
23646
+ openUrl(info2.linkUrl);
23647
+ }
23648
+ };
23649
+ const isDisable = computed(() => {
23650
+ var _a, _b;
23651
+ return ((_b = (_a = props.sbid) == null ? void 0 : _a.sbidCarrierBillingInfo) == null ? void 0 : _b.paymentMethodStatus) !== PaymentMethodStatus.ACTIVATED;
23652
+ });
23653
+ const handleSelect = () => {
23654
+ if (isDisable.value)
23655
+ return;
23656
+ emit("select");
23657
+ };
23544
23658
  return {
23545
- isDisable: computed(() => {
23546
- var _a2, _b2;
23547
- return ((_b2 = (_a2 = props.sbid) == null ? void 0 : _a2.sbidCarrierBillingInfo) == null ? void 0 : _b2.paymentMethodStatus) !== "ACTIVATED";
23548
- }),
23659
+ isDisable,
23549
23660
  images: getImages(),
23550
- paymentMethodStatus: computed(() => {
23551
- var _a2, _b2;
23552
- return getPaymentMethodStatus(false, (_b2 = (_a2 = props.sbid) == null ? void 0 : _a2.sbidCarrierBillingInfo) == null ? void 0 : _b2.paymentMethodStatus);
23553
- }),
23554
- maintainanceInfo: computed(() => {
23555
- var _a2, _b2, _c, _d;
23556
- return (_d = (_c = (_b2 = (_a2 = props.sbid) == null ? void 0 : _a2.paymentMethodDescriptionInfo) == null ? void 0 : _b2.statusDescription) == null ? void 0 : _c.text) != null ? _d : "";
23661
+ paymentMethodStatusText: computed(() => {
23662
+ var _a;
23663
+ return getPaymentMethodStatus(false, (_a = props.sbid) == null ? void 0 : _a.sbidCarrierBillingInfo);
23557
23664
  }),
23558
- getClass: ((_b = (_a = props.sbid) == null ? void 0 : _a.sbidCarrierBillingInfo) == null ? void 0 : _b.paymentMethodStatus) !== "ACTIVATED" ? style.paymentMethodDisabled : "",
23665
+ getClass: (isDisable == null ? void 0 : isDisable.value) ? style.paymentMethodDisabled : "",
23559
23666
  lg: getLanguage(),
23560
- style
23667
+ style,
23668
+ payMethodDescriptionInfo: computed(() => {
23669
+ var _a, _b, _c, _d;
23670
+ return [
23671
+ (_b = (_a = props.sbid) == null ? void 0 : _a.paymentMethodDescriptionInfo) == null ? void 0 : _b.statusDescription,
23672
+ (_d = (_c = props.sbid) == null ? void 0 : _c.paymentMethodDescriptionInfo) == null ? void 0 : _d.detailDescription
23673
+ ].filter((info2) => !!info2);
23674
+ }),
23675
+ getMaintenanceStyle: computed(() => (info2) => {
23676
+ return {
23677
+ color: info2.color
23678
+ };
23679
+ }),
23680
+ handleClick,
23681
+ handleSelect
23561
23682
  };
23562
23683
  }
23563
23684
  });
23564
23685
  const _hoisted_1$L = ["src"];
23565
- function _sfc_render$1n(_ctx, _cache, $props, $setup, $data, $options) {
23686
+ const _hoisted_2$o = ["onClick"];
23687
+ function _sfc_render$1o(_ctx, _cache, $props, $setup, $data, $options) {
23566
23688
  const _component_Button = resolveComponent("Button");
23567
23689
  return openBlock(), createElementBlock("div", {
23568
23690
  class: normalizeClass([
@@ -23570,7 +23692,8 @@ function _sfc_render$1n(_ctx, _cache, $props, $setup, $data, $options) {
23570
23692
  _ctx.style.container,
23571
23693
  _ctx.getClass,
23572
23694
  _ctx.isDisable ? _ctx.style.centerAlign : ""
23573
- ])
23695
+ ]),
23696
+ onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleSelect && _ctx.handleSelect(...args))
23574
23697
  }, [
23575
23698
  createBaseVNode("div", {
23576
23699
  class: normalizeClass(_ctx.style.imageContainer)
@@ -23610,34 +23733,41 @@ function _sfc_render$1n(_ctx, _cache, $props, $setup, $data, $options) {
23610
23733
  type: "default"
23611
23734
  }, {
23612
23735
  default: withCtx(() => [
23613
- createTextVNode(toDisplayString(_ctx.paymentMethodStatus), 1)
23736
+ createTextVNode(toDisplayString(_ctx.paymentMethodStatusText), 1)
23614
23737
  ]),
23615
23738
  _: 1
23616
23739
  }, 8, ["class"])) : createCommentVNode("", true)
23617
23740
  ])
23618
23741
  ], 2),
23619
- _ctx.maintainanceInfo ? (openBlock(), createElementBlock("div", {
23620
- key: 0,
23621
- class: normalizeClass(_ctx.style.maintainanceInfo)
23622
- }, toDisplayString(_ctx.maintainanceInfo), 3)) : createCommentVNode("", true)
23742
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.payMethodDescriptionInfo, (info2, index2) => {
23743
+ return openBlock(), createElementBlock("div", {
23744
+ key: index2,
23745
+ class: normalizeClass(_ctx.style.maintainanceInfo),
23746
+ style: normalizeStyle(_ctx.getMaintenanceStyle(info2)),
23747
+ onClick: ($event) => _ctx.handleClick($event, info2)
23748
+ }, toDisplayString(info2.text), 15, _hoisted_2$o);
23749
+ }), 128))
23623
23750
  ], 2)
23624
23751
  ], 2);
23625
23752
  }
23626
- const cssModules$1c = {};
23627
- cssModules$1c["$style"] = style0$1c;
23628
- var SbidBank = /* @__PURE__ */ _export_sfc(_sfc_main$1n, [["render", _sfc_render$1n], ["__cssModules", cssModules$1c]]);
23629
- const wrapperClass$d = "_wrapperClass_1572o_1";
23630
- const img$3 = "_img_1572o_1";
23631
- const container$u = "_container_1572o_5";
23632
- const imgContainer = "_imgContainer_1572o_10";
23633
- const labelContainer = "_labelContainer_1572o_19";
23634
- const mainLabel$1 = "_mainLabel_1572o_26";
23635
- const subLabel$1 = "_subLabel_1572o_33";
23636
- const disabled$2 = "_disabled_1572o_39";
23637
- const rightAlign$2 = "_rightAlign_1572o_45";
23638
- const invalid$1 = "_invalid_1572o_49";
23639
- var style0$1b = {
23640
- wrapperClass: wrapperClass$d,
23753
+ const cssModules$1d = {};
23754
+ cssModules$1d["$style"] = style0$1d;
23755
+ var SbidBank = /* @__PURE__ */ _export_sfc(_sfc_main$1o, [["render", _sfc_render$1o], ["__cssModules", cssModules$1d]]);
23756
+ const wrapperClass$e = "_wrapperClass_jhs19_1";
23757
+ const img$3 = "_img_jhs19_1";
23758
+ const container$u = "_container_jhs19_5";
23759
+ const imgContainer = "_imgContainer_jhs19_10";
23760
+ const labelContainer = "_labelContainer_jhs19_19";
23761
+ const mainLabel$1 = "_mainLabel_jhs19_26";
23762
+ const subLabel$1 = "_subLabel_jhs19_33";
23763
+ const disabled$2 = "_disabled_jhs19_39";
23764
+ const rightAlign$2 = "_rightAlign_jhs19_44";
23765
+ const invalid$1 = "_invalid_jhs19_48";
23766
+ const content$d = "_content_jhs19_59";
23767
+ const paymentInfo = "_paymentInfo_jhs19_62";
23768
+ const maintainanceInfo = "_maintainanceInfo_jhs19_65";
23769
+ var style0$1c = {
23770
+ wrapperClass: wrapperClass$e,
23641
23771
  img: img$3,
23642
23772
  container: container$u,
23643
23773
  imgContainer,
@@ -23646,9 +23776,12 @@ var style0$1b = {
23646
23776
  subLabel: subLabel$1,
23647
23777
  disabled: disabled$2,
23648
23778
  rightAlign: rightAlign$2,
23649
- invalid: invalid$1
23779
+ invalid: invalid$1,
23780
+ content: content$d,
23781
+ paymentInfo,
23782
+ maintainanceInfo
23650
23783
  };
23651
- const _sfc_main$1m = defineComponent({
23784
+ const _sfc_main$1n = defineComponent({
23652
23785
  components: {
23653
23786
  Button
23654
23787
  },
@@ -23658,25 +23791,57 @@ const _sfc_main$1m = defineComponent({
23658
23791
  required: true
23659
23792
  }
23660
23793
  },
23661
- setup(props) {
23662
- var _a, _b;
23794
+ emits: {
23795
+ select: () => true
23796
+ },
23797
+ setup(props, { emit }) {
23798
+ const handleClick = (e, info2) => {
23799
+ if (info2 == null ? void 0 : info2.linkUrl) {
23800
+ e == null ? void 0 : e.stopPropagation();
23801
+ openUrl(info2.linkUrl);
23802
+ }
23803
+ };
23804
+ const isDisable = computed(() => {
23805
+ var _a, _b;
23806
+ return ((_b = (_a = props == null ? void 0 : props.payLater) == null ? void 0 : _a.payLaterCcInfo) == null ? void 0 : _b.paymentMethodStatus) !== PaymentMethodStatus.ACTIVATED;
23807
+ });
23808
+ const handleSelect = () => {
23809
+ if (isDisable.value)
23810
+ return;
23811
+ emit("select");
23812
+ };
23663
23813
  return {
23664
23814
  formattedBalance: computed(() => {
23665
- var _a2, _b2;
23666
- return formatAmount((_b2 = (_a2 = props.payLater) == null ? void 0 : _a2.payLaterCcInfo) == null ? void 0 : _b2.availableAmount);
23815
+ var _a, _b;
23816
+ return formatAmount((_b = (_a = props.payLater) == null ? void 0 : _a.payLaterCcInfo) == null ? void 0 : _b.availableAmount);
23667
23817
  }),
23668
- isDisable: ((_b = (_a = props == null ? void 0 : props.payLater) == null ? void 0 : _a.payLaterCcInfo) == null ? void 0 : _b.paymentMethodStatus) !== PaymentMethodStatus.ACTIVATED,
23818
+ isDisable,
23669
23819
  images: getImages(),
23670
23820
  lg: getLanguage(),
23671
23821
  paymentMethodStatusText: computed(() => {
23672
- var _a2, _b2;
23673
- return getPaymentMethodStatus(false, (_b2 = (_a2 = props == null ? void 0 : props.payLater) == null ? void 0 : _a2.payLaterCcInfo) == null ? void 0 : _b2.paymentMethodStatus);
23674
- })
23822
+ var _a;
23823
+ return getPaymentMethodStatus(false, (_a = props == null ? void 0 : props.payLater) == null ? void 0 : _a.payLaterCcInfo);
23824
+ }),
23825
+ payMethodDescriptionInfo: computed(() => {
23826
+ var _a, _b, _c, _d;
23827
+ return [
23828
+ (_b = (_a = props.payLater) == null ? void 0 : _a.paymentMethodDescriptionInfo) == null ? void 0 : _b.statusDescription,
23829
+ (_d = (_c = props.payLater) == null ? void 0 : _c.paymentMethodDescriptionInfo) == null ? void 0 : _d.detailDescription
23830
+ ].filter((info2) => !!info2);
23831
+ }),
23832
+ getMaintenanceStyle: computed(() => (info2) => {
23833
+ return {
23834
+ color: info2.color
23835
+ };
23836
+ }),
23837
+ handleClick,
23838
+ handleSelect
23675
23839
  };
23676
23840
  }
23677
23841
  });
23678
23842
  const _hoisted_1$K = ["src"];
23679
- function _sfc_render$1m(_ctx, _cache, $props, $setup, $data, $options) {
23843
+ const _hoisted_2$n = ["onClick"];
23844
+ function _sfc_render$1n(_ctx, _cache, $props, $setup, $data, $options) {
23680
23845
  const _component_Button = resolveComponent("Button");
23681
23846
  return openBlock(), createElementBlock("div", {
23682
23847
  class: normalizeClass([
@@ -23685,7 +23850,8 @@ function _sfc_render$1m(_ctx, _cache, $props, $setup, $data, $options) {
23685
23850
  [_ctx.$style.disabled]: _ctx.isDisable,
23686
23851
  [_ctx.$style.container]: true
23687
23852
  }
23688
- ])
23853
+ ]),
23854
+ onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleSelect && _ctx.handleSelect(...args))
23689
23855
  }, [
23690
23856
  createBaseVNode("div", {
23691
23857
  class: normalizeClass(_ctx.$style.imgContainer)
@@ -23696,37 +23862,53 @@ function _sfc_render$1m(_ctx, _cache, $props, $setup, $data, $options) {
23696
23862
  }, null, 10, _hoisted_1$K)
23697
23863
  ], 2),
23698
23864
  createBaseVNode("div", {
23699
- class: normalizeClass(_ctx.$style.labelContainer)
23700
- }, [
23701
- createBaseVNode("span", {
23702
- class: normalizeClass(_ctx.$style.mainLabel),
23703
- "data-testid": "pay-method-title"
23704
- }, toDisplayString(_ctx.lg.payLater.title), 3),
23705
- createBaseVNode("span", {
23706
- class: normalizeClass(_ctx.$style.subLabel)
23707
- }, toDisplayString(_ctx.lg.payLater.balance) + toDisplayString(_ctx.formattedBalance) + "\u5186 ", 3)
23708
- ], 2),
23709
- createBaseVNode("span", {
23710
- class: normalizeClass(_ctx.$style.rightAlign)
23865
+ class: normalizeClass(_ctx.$style.content)
23711
23866
  }, [
23712
- _ctx.isDisable ? (openBlock(), createBlock(_component_Button, {
23713
- key: 0,
23714
- disabled: true,
23715
- class: normalizeClass(_ctx.$style.invalid),
23716
- size: "small",
23717
- type: "default"
23718
- }, {
23719
- default: withCtx(() => [
23720
- createTextVNode(toDisplayString(_ctx.paymentMethodStatusText), 1)
23721
- ]),
23722
- _: 1
23723
- }, 8, ["class"])) : createCommentVNode("", true)
23867
+ createBaseVNode("div", {
23868
+ class: normalizeClass(_ctx.$style.paymentInfo)
23869
+ }, [
23870
+ createBaseVNode("div", {
23871
+ class: normalizeClass(_ctx.$style.labelContainer)
23872
+ }, [
23873
+ createBaseVNode("span", {
23874
+ class: normalizeClass(_ctx.$style.mainLabel),
23875
+ "data-testid": "pay-method-title"
23876
+ }, toDisplayString(_ctx.lg.payLater.title), 3),
23877
+ createBaseVNode("span", {
23878
+ class: normalizeClass(_ctx.$style.subLabel)
23879
+ }, toDisplayString(_ctx.lg.payLater.balance) + toDisplayString(_ctx.formattedBalance) + "\u5186 ", 3)
23880
+ ], 2),
23881
+ createBaseVNode("span", {
23882
+ class: normalizeClass(_ctx.$style.rightAlign)
23883
+ }, [
23884
+ _ctx.isDisable ? (openBlock(), createBlock(_component_Button, {
23885
+ key: 0,
23886
+ disabled: true,
23887
+ class: normalizeClass(_ctx.$style.invalid),
23888
+ size: "small",
23889
+ type: "default"
23890
+ }, {
23891
+ default: withCtx(() => [
23892
+ createTextVNode(toDisplayString(_ctx.paymentMethodStatusText), 1)
23893
+ ]),
23894
+ _: 1
23895
+ }, 8, ["class"])) : createCommentVNode("", true)
23896
+ ], 2)
23897
+ ], 2),
23898
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.payMethodDescriptionInfo, (info2, index2) => {
23899
+ return openBlock(), createElementBlock("div", {
23900
+ key: index2,
23901
+ class: normalizeClass(_ctx.$style.maintainanceInfo),
23902
+ style: normalizeStyle(_ctx.getMaintenanceStyle(info2)),
23903
+ onClick: ($event) => _ctx.handleClick($event, info2)
23904
+ }, toDisplayString(info2.text), 15, _hoisted_2$n);
23905
+ }), 128))
23724
23906
  ], 2)
23725
23907
  ], 2);
23726
23908
  }
23727
- const cssModules$1b = {};
23728
- cssModules$1b["$style"] = style0$1b;
23729
- var PayLaterCC = /* @__PURE__ */ _export_sfc(_sfc_main$1m, [["render", _sfc_render$1m], ["__cssModules", cssModules$1b]]);
23909
+ const cssModules$1c = {};
23910
+ cssModules$1c["$style"] = style0$1c;
23911
+ var PayLaterCC = /* @__PURE__ */ _export_sfc(_sfc_main$1n, [["render", _sfc_render$1n], ["__cssModules", cssModules$1c]]);
23730
23912
  const PaymentMethod = defineComponent({
23731
23913
  props: {
23732
23914
  paymentMethod: {
@@ -23736,29 +23918,37 @@ const PaymentMethod = defineComponent({
23736
23918
  }
23737
23919
  }
23738
23920
  },
23921
+ emits: {
23922
+ select: () => true
23923
+ },
23739
23924
  render() {
23740
23925
  switch (this.paymentMethod.paymentMethodType) {
23741
23926
  case PaymentMethodType.WALLET:
23742
23927
  return createVNode(Wallet, {
23743
- "wallet": this.paymentMethod
23928
+ "wallet": this.paymentMethod,
23929
+ "onSelect": () => this.$emit("select")
23744
23930
  }, null);
23745
23931
  case PaymentMethodType.CREDIT_CARD:
23746
23932
  return createVNode(CreditCard, {
23747
- "credit": this.paymentMethod
23933
+ "credit": this.paymentMethod,
23934
+ "onSelect": () => this.$emit("select")
23748
23935
  }, null);
23749
23936
  case PaymentMethodType.BANK:
23750
23937
  case PaymentMethodType.YMONEY_BANK:
23751
23938
  return createVNode(Bank, {
23752
23939
  "bank": this.paymentMethod,
23753
- "round": true
23940
+ "round": true,
23941
+ "onSelect": () => this.$emit("select")
23754
23942
  }, null);
23755
23943
  case PaymentMethodType.SBID_CARRIER_BILLING:
23756
23944
  return createVNode(SbidBank, {
23757
- "sbid": this.paymentMethod
23945
+ "sbid": this.paymentMethod,
23946
+ "onSelect": () => this.$emit("select")
23758
23947
  }, null);
23759
23948
  case PaymentMethodType.PAY_LATER_CC:
23760
23949
  return createVNode(PayLaterCC, {
23761
- "payLater": this.paymentMethod
23950
+ "payLater": this.paymentMethod,
23951
+ "onSelect": () => this.$emit("select")
23762
23952
  }, null);
23763
23953
  case PaymentMethodType.PAY_LATER:
23764
23954
  return null;
@@ -23766,21 +23956,21 @@ const PaymentMethod = defineComponent({
23766
23956
  return null;
23767
23957
  }
23768
23958
  });
23769
- const wrapperClass$c = "_wrapperClass_6gcou_1";
23959
+ const wrapperClass$d = "_wrapperClass_6gcou_1";
23770
23960
  const methodItem$1 = "_methodItem_6gcou_1";
23771
23961
  const topupMethodItem = "_topupMethodItem_6gcou_14";
23772
23962
  const iconContainer$2 = "_iconContainer_6gcou_18";
23773
23963
  const iconGreenTick$1 = "_iconGreenTick_6gcou_27";
23774
23964
  const iconHidden$1 = "_iconHidden_6gcou_37";
23775
- var style0$1a = {
23776
- wrapperClass: wrapperClass$c,
23965
+ var style0$1b = {
23966
+ wrapperClass: wrapperClass$d,
23777
23967
  methodItem: methodItem$1,
23778
23968
  topupMethodItem,
23779
23969
  iconContainer: iconContainer$2,
23780
23970
  iconGreenTick: iconGreenTick$1,
23781
23971
  iconHidden: iconHidden$1
23782
23972
  };
23783
- const _sfc_main$1l = defineComponent({
23973
+ const _sfc_main$1m = defineComponent({
23784
23974
  name: "PaymentMethodList",
23785
23975
  components: {
23786
23976
  PaymentMethod
@@ -23816,7 +24006,7 @@ const _sfc_main$1l = defineComponent({
23816
24006
  };
23817
24007
  }
23818
24008
  });
23819
- function _sfc_render$1l(_ctx, _cache, $props, $setup, $data, $options) {
24009
+ function _sfc_render$1m(_ctx, _cache, $props, $setup, $data, $options) {
23820
24010
  const _component_PaymentMethod = resolveComponent("PaymentMethod");
23821
24011
  return openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.paymentMethods, (paymentMethod2, index2) => {
23822
24012
  return openBlock(), createElementBlock("div", {
@@ -23842,14 +24032,83 @@ function _sfc_render$1l(_ctx, _cache, $props, $setup, $data, $options) {
23842
24032
  createVNode(_component_PaymentMethod, {
23843
24033
  "data-testid": "payment-method",
23844
24034
  "payment-method": paymentMethod2,
23845
- onClick: ($event) => _ctx.select(index2)
23846
- }, null, 8, ["payment-method", "onClick"])
24035
+ onSelect: ($event) => _ctx.select(index2)
24036
+ }, null, 8, ["payment-method", "onSelect"])
23847
24037
  ], 2);
23848
24038
  }), 128);
23849
24039
  }
24040
+ const cssModules$1b = {};
24041
+ cssModules$1b["$style"] = style0$1b;
24042
+ var PaymentMethodList = /* @__PURE__ */ _export_sfc(_sfc_main$1m, [["render", _sfc_render$1m], ["__cssModules", cssModules$1b]]);
24043
+ const wrapperClass$c = "_wrapperClass_1lewn_1";
24044
+ const maintenanceContainer = "_maintenanceContainer_1lewn_1";
24045
+ const maintenanceText = "_maintenanceText_1lewn_18";
24046
+ const rightArror = "_rightArror_1lewn_23";
24047
+ var style0$1a = {
24048
+ wrapperClass: wrapperClass$c,
24049
+ maintenanceContainer,
24050
+ maintenanceText,
24051
+ rightArror
24052
+ };
24053
+ const _sfc_main$1l = defineComponent({
24054
+ name: "MaintenanceInfo",
24055
+ props: {
24056
+ maintenanceInfo: {
24057
+ type: Object,
24058
+ default: null
24059
+ }
24060
+ },
24061
+ setup(props) {
24062
+ const handleClick = () => {
24063
+ const { linkUrl } = (props == null ? void 0 : props.maintenanceInfo) || {};
24064
+ if (linkUrl) {
24065
+ openUrl(linkUrl);
24066
+ }
24067
+ };
24068
+ const textStyle = computed(() => {
24069
+ var _a, _b, _c;
24070
+ return {
24071
+ color: (_b = (_a = props == null ? void 0 : props.maintenanceInfo) == null ? void 0 : _a.color) != null ? _b : "#3895FF",
24072
+ "font-weight": ((_c = props == null ? void 0 : props.maintenanceInfo) == null ? void 0 : _c.isBold) ? "bold" : "normal"
24073
+ };
24074
+ });
24075
+ const containerStyle = computed(() => {
24076
+ var _a, _b;
24077
+ return {
24078
+ backgroundColor: (_b = (_a = props == null ? void 0 : props.maintenanceInfo) == null ? void 0 : _a.backgroundColor) != null ? _b : "#E5F1FF"
24079
+ };
24080
+ });
24081
+ return {
24082
+ handleClick,
24083
+ textStyle,
24084
+ containerStyle
24085
+ };
24086
+ }
24087
+ });
24088
+ function _sfc_render$1l(_ctx, _cache, $props, $setup, $data, $options) {
24089
+ var _a, _b;
24090
+ return _ctx.maintenanceInfo ? (openBlock(), createElementBlock("div", {
24091
+ key: 0,
24092
+ class: normalizeClass([_ctx.$style.wrapperClass, _ctx.$style.maintenanceContainer]),
24093
+ style: normalizeStyle(_ctx.containerStyle),
24094
+ "data-testid": "maintenance-info",
24095
+ onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleClick && _ctx.handleClick(...args))
24096
+ }, [
24097
+ createBaseVNode("span", {
24098
+ class: normalizeClass(_ctx.$style.maintenanceText),
24099
+ style: normalizeStyle(_ctx.textStyle),
24100
+ "data-testid": "maintenance-info-text"
24101
+ }, toDisplayString((_a = _ctx.maintenanceInfo) == null ? void 0 : _a.text), 7),
24102
+ ((_b = _ctx.maintenanceInfo) == null ? void 0 : _b.linkUrl) ? (openBlock(), createElementBlock("i", {
24103
+ key: 0,
24104
+ class: normalizeClass(_ctx.$style.rightArror),
24105
+ "data-testid": "maintenance-info-link"
24106
+ }, null, 2)) : createCommentVNode("", true)
24107
+ ], 6)) : createCommentVNode("", true);
24108
+ }
23850
24109
  const cssModules$1a = {};
23851
24110
  cssModules$1a["$style"] = style0$1a;
23852
- var PaymentMethodList = /* @__PURE__ */ _export_sfc(_sfc_main$1l, [["render", _sfc_render$1l], ["__cssModules", cssModules$1a]]);
24111
+ var MaintenanceInfo = /* @__PURE__ */ _export_sfc(_sfc_main$1l, [["render", _sfc_render$1l], ["__cssModules", cssModules$1a]]);
23853
24112
  const wrapperClass$b = "_wrapperClass_1xmid_2";
23854
24113
  const paymentContainer$1 = "_paymentContainer_1xmid_2";
23855
24114
  const label$4 = "_label_1xmid_11";
@@ -23877,7 +24136,8 @@ var style0$19 = {
23877
24136
  const _sfc_main$1k = defineComponent({
23878
24137
  components: {
23879
24138
  PaymentType,
23880
- PaymentMethodList
24139
+ PaymentMethodList,
24140
+ MaintenanceInfo
23881
24141
  },
23882
24142
  props: {
23883
24143
  title: {
@@ -23915,6 +24175,10 @@ const _sfc_main$1k = defineComponent({
23915
24175
  type: Boolean,
23916
24176
  required: false,
23917
24177
  default: false
24178
+ },
24179
+ appealDescription: {
24180
+ type: Object,
24181
+ default: null
23918
24182
  }
23919
24183
  },
23920
24184
  emits: {
@@ -23947,6 +24211,7 @@ const _sfc_main$1k = defineComponent({
23947
24211
  const _hoisted_1$J = ["src"];
23948
24212
  function _sfc_render$1k(_ctx, _cache, $props, $setup, $data, $options) {
23949
24213
  const _component_PaymentType = resolveComponent("PaymentType");
24214
+ const _component_MaintenanceInfo = resolveComponent("MaintenanceInfo");
23950
24215
  const _component_PaymentMethodList = resolveComponent("PaymentMethodList");
23951
24216
  const _directive_vertical_scroll = resolveDirective("vertical-scroll");
23952
24217
  return openBlock(), createElementBlock("div", {
@@ -23989,8 +24254,12 @@ function _sfc_render$1k(_ctx, _cache, $props, $setup, $data, $options) {
23989
24254
  "payment-method": _ctx.paymentMethod,
23990
24255
  "is-make-payment": true
23991
24256
  }, null, 8, ["class", "payment-method"])) : createCommentVNode("", true),
23992
- _ctx.showPaymentMethodList ? withDirectives((openBlock(), createElementBlock("div", {
24257
+ _ctx.showPaymentMethodList ? (openBlock(), createBlock(_component_MaintenanceInfo, {
23993
24258
  key: 2,
24259
+ "maintenance-info": _ctx.appealDescription
24260
+ }, null, 8, ["maintenance-info"])) : createCommentVNode("", true),
24261
+ _ctx.showPaymentMethodList ? withDirectives((openBlock(), createElementBlock("div", {
24262
+ key: 3,
23994
24263
  class: normalizeClass(_ctx.style.contentContainer)
23995
24264
  }, [
23996
24265
  createVNode(_component_PaymentMethodList, {
@@ -26054,8 +26323,8 @@ const _sfc_main$1a = defineComponent({
26054
26323
  buttonDisabled.value = !editOK;
26055
26324
  }
26056
26325
  });
26057
- const open = computed(() => props.open);
26058
- watch(open, (newOpen, prevOpen) => {
26326
+ const open2 = computed(() => props.open);
26327
+ watch(open2, (newOpen, prevOpen) => {
26059
26328
  if (newOpen === false && prevOpen === true) {
26060
26329
  Object.assign(state, createInitialState$1());
26061
26330
  } else {
@@ -26259,12 +26528,12 @@ const _sfc_main$19 = defineComponent({
26259
26528
  const lg2 = getLanguage();
26260
26529
  const style = useCssModule();
26261
26530
  const close2 = () => emit("close");
26262
- const del = () => emit("del");
26531
+ const del2 = () => emit("del");
26263
26532
  const img2 = getImages();
26264
26533
  return {
26265
26534
  style,
26266
26535
  close: close2,
26267
- del,
26536
+ del: del2,
26268
26537
  lg: lg2,
26269
26538
  img: img2
26270
26539
  };
@@ -26639,7 +26908,7 @@ const _sfc_main$17 = defineComponent({
26639
26908
  return handleError2();
26640
26909
  }
26641
26910
  };
26642
- const del = async () => {
26911
+ const del2 = async () => {
26643
26912
  var _a, _b, _c;
26644
26913
  const addressListResponse = await getAddressList();
26645
26914
  if ((addressListResponse == null ? void 0 : addressListResponse.ppFetchResult) === "success") {
@@ -26674,7 +26943,7 @@ const _sfc_main$17 = defineComponent({
26674
26943
  addAddress: addAddress2,
26675
26944
  addSheetLoading: computed(() => state.addSheetLoading),
26676
26945
  addressList: computed(() => state.addressList),
26677
- del,
26946
+ del: del2,
26678
26947
  isDesktopPay,
26679
26948
  addOrEdit,
26680
26949
  triggerLayoutUpdate,
@@ -26998,6 +27267,10 @@ const _sfc_main$15 = defineComponent({
26998
27267
  type: Array,
26999
27268
  required: true,
27000
27269
  default: () => []
27270
+ },
27271
+ appealDescription: {
27272
+ type: Object,
27273
+ default: null
27001
27274
  }
27002
27275
  },
27003
27276
  emits: {
@@ -27191,9 +27464,10 @@ function _sfc_render$15(_ctx, _cache, $props, $setup, $data, $options) {
27191
27464
  "payment-methods": _ctx.paymentMethods,
27192
27465
  "select-payment-index": _ctx.selectPaymentIndex,
27193
27466
  "show-payment-method-list": _ctx.showPaymentMethodList,
27467
+ "appeal-description": _ctx.appealDescription,
27194
27468
  onSelectPaymentMethod: _ctx.select,
27195
27469
  onShow: _ctx.showPaymentMethod
27196
- }, null, 8, ["loading", "payment-method", "payment-methods", "select-payment-index", "show-payment-method-list", "onSelectPaymentMethod", "onShow"])) : createCommentVNode("", true),
27470
+ }, null, 8, ["loading", "payment-method", "payment-methods", "select-payment-index", "show-payment-method-list", "appeal-description", "onSelectPaymentMethod", "onShow"])) : createCommentVNode("", true),
27197
27471
  _ctx.isSufficient && _ctx.isMobile ? (openBlock(), createElementBlock("div", {
27198
27472
  key: 3,
27199
27473
  class: normalizeClass(_ctx.style.insufficientAmount)
@@ -27354,7 +27628,8 @@ var style0$W = {
27354
27628
  const _sfc_main$14 = defineComponent({
27355
27629
  components: {
27356
27630
  Header,
27357
- PaymentMethodList
27631
+ PaymentMethodList,
27632
+ MaintenanceInfo
27358
27633
  },
27359
27634
  props: {
27360
27635
  paymentMethods: {
@@ -27371,6 +27646,10 @@ const _sfc_main$14 = defineComponent({
27371
27646
  type: [String, Object],
27372
27647
  required: false,
27373
27648
  default: ""
27649
+ },
27650
+ appealDescription: {
27651
+ type: Object,
27652
+ default: null
27374
27653
  }
27375
27654
  },
27376
27655
  emits: {
@@ -27399,6 +27678,7 @@ const _sfc_main$14 = defineComponent({
27399
27678
  });
27400
27679
  function _sfc_render$14(_ctx, _cache, $props, $setup, $data, $options) {
27401
27680
  const _component_Header = resolveComponent("Header");
27681
+ const _component_MaintenanceInfo = resolveComponent("MaintenanceInfo");
27402
27682
  const _component_PaymentMethodList = resolveComponent("PaymentMethodList");
27403
27683
  const _directive_vertical_scroll = resolveDirective("vertical-scroll");
27404
27684
  return openBlock(), createElementBlock("div", {
@@ -27415,6 +27695,7 @@ function _sfc_render$14(_ctx, _cache, $props, $setup, $data, $options) {
27415
27695
  withDirectives((openBlock(), createElementBlock("div", {
27416
27696
  class: normalizeClass(_ctx.style.contentContainer)
27417
27697
  }, [
27698
+ createVNode(_component_MaintenanceInfo, { "maintenance-info": _ctx.appealDescription }, null, 8, ["maintenance-info"]),
27418
27699
  createVNode(_component_PaymentMethodList, {
27419
27700
  "payment-methods": _ctx.paymentMethods,
27420
27701
  "select-payment-index": _ctx.selectPaymentIndex,
@@ -27769,7 +28050,7 @@ const _sfc_main$11 = defineComponent({
27769
28050
  },
27770
28051
  setup(props, { emit }) {
27771
28052
  const images2 = getImages();
27772
- const click = () => emit("click");
28053
+ const click2 = () => emit("click");
27773
28054
  const style = useCssModule();
27774
28055
  const cashBackInfo2 = computed(() => {
27775
28056
  var _a, _b, _c, _d, _e, _f;
@@ -27792,7 +28073,7 @@ const _sfc_main$11 = defineComponent({
27792
28073
  return cashBackInfo2.value.cashBackAmount;
27793
28074
  });
27794
28075
  return {
27795
- click,
28076
+ click: click2,
27796
28077
  style,
27797
28078
  cashBackInfo: cashBackInfo2,
27798
28079
  images: images2,
@@ -28161,7 +28442,7 @@ const _sfc_main$10 = defineComponent({
28161
28442
  millisecond: true,
28162
28443
  onFinish: () => {
28163
28444
  isCountDown.value = false;
28164
- click();
28445
+ click2();
28165
28446
  countDown.reset();
28166
28447
  }
28167
28448
  });
@@ -28184,7 +28465,7 @@ const _sfc_main$10 = defineComponent({
28184
28465
  state.showShrinkAnimation = false;
28185
28466
  }, timeout);
28186
28467
  };
28187
- const click = () => {
28468
+ const click2 = () => {
28188
28469
  if (state.showCashBackDetailList || props.hasCashBackAnimation && isMobile.value || props.hasCashBackAnimation && !props.hasConfirmAge && isDesktop.value)
28189
28470
  return;
28190
28471
  context.emit("success");
@@ -28217,7 +28498,7 @@ const _sfc_main$10 = defineComponent({
28217
28498
  }),
28218
28499
  statusLabelColor: computed(() => props.paymentResult.statusLabelColor.toLowerCase()),
28219
28500
  labelText: computed(() => props.paymentResult.statusLabelString),
28220
- click,
28501
+ click: click2,
28221
28502
  copy,
28222
28503
  showCashBackDetailList: computed(() => state.showCashBackDetailList),
28223
28504
  openCashBackDetailList,
@@ -28762,6 +29043,7 @@ function _sfc_render$Y(_ctx, _cache, $props, $setup, $data, $options) {
28762
29043
  return openBlock(), createBlock(_component_ActionSheet, { show: _ctx.show }, {
28763
29044
  default: withCtx(() => [
28764
29045
  createBaseVNode("div", {
29046
+ "data-testid": "birthday-picker",
28765
29047
  class: normalizeClass(_ctx.$style.birthdayPicker)
28766
29048
  }, [
28767
29049
  createBaseVNode("div", {
@@ -28775,14 +29057,16 @@ function _sfc_render$Y(_ctx, _cache, $props, $setup, $data, $options) {
28775
29057
  class: normalizeClass(_ctx.$style.content)
28776
29058
  }, [
28777
29059
  createBaseVNode("p", {
28778
- class: normalizeClass(_ctx.$style.title)
29060
+ class: normalizeClass(_ctx.$style.title),
29061
+ "data-testid": "birthday-confirm-title"
28779
29062
  }, [
28780
29063
  createTextVNode(toDisplayString(_ctx.lg.birthdayConfirm.title), 1),
28781
29064
  _hoisted_2$g,
28782
29065
  createTextVNode(toDisplayString(_ctx.lg.birthdayConfirm.title2), 1)
28783
29066
  ], 2),
28784
29067
  createBaseVNode("p", {
28785
- class: normalizeClass(_ctx.$style.description)
29068
+ class: normalizeClass(_ctx.$style.description),
29069
+ "data-testid": "birthday-confirm-description"
28786
29070
  }, [
28787
29071
  createTextVNode(toDisplayString(_ctx.lg.birthdayConfirm.desc), 1),
28788
29072
  _hoisted_3$c,
@@ -28795,7 +29079,10 @@ function _sfc_render$Y(_ctx, _cache, $props, $setup, $data, $options) {
28795
29079
  createBaseVNode("div", {
28796
29080
  class: normalizeClass(_ctx.$style.dateContainer)
28797
29081
  }, [
28798
- createVNode(_component_DateButton, { onSelected: _ctx.select }, {
29082
+ createVNode(_component_DateButton, {
29083
+ "data-testid": "birthday-date",
29084
+ onSelected: _ctx.select
29085
+ }, {
28799
29086
  default: withCtx(() => [
28800
29087
  createTextVNode(toDisplayString(_ctx.lg.birthdayConfirm.date), 1)
28801
29088
  ]),
@@ -28810,7 +29097,7 @@ function _sfc_render$Y(_ctx, _cache, $props, $setup, $data, $options) {
28810
29097
  type: "primary",
28811
29098
  block: "",
28812
29099
  disabled: !_ctx.hasInputted,
28813
- "data-test": "birthday-confirm-complete",
29100
+ "data-testid": "birthday-confirm-complete",
28814
29101
  onClick: _ctx.complete
28815
29102
  }, {
28816
29103
  default: withCtx(() => [
@@ -28820,7 +29107,7 @@ function _sfc_render$Y(_ctx, _cache, $props, $setup, $data, $options) {
28820
29107
  }, 8, ["disabled", "onClick"]),
28821
29108
  createVNode(_component_Button, {
28822
29109
  type: "link",
28823
- "data-test": "birthday-confirm-help",
29110
+ "data-testid": "birthday-confirm-help",
28824
29111
  block: "",
28825
29112
  onClick: _ctx.helpPageClick
28826
29113
  }, {
@@ -28899,7 +29186,8 @@ function _sfc_render$X(_ctx, _cache, $props, $setup, $data, $options) {
28899
29186
  return openBlock(), createBlock(_component_ActionSheet, { show: _ctx.show }, {
28900
29187
  default: withCtx(() => [
28901
29188
  createBaseVNode("div", {
28902
- class: normalizeClass(_ctx.$style.birthdayPicker)
29189
+ class: normalizeClass(_ctx.$style.birthdayPicker),
29190
+ "data-testid": "birthday-confirm-error"
28903
29191
  }, [
28904
29192
  createBaseVNode("div", {
28905
29193
  class: normalizeClass(_ctx.$style.header)
@@ -28913,14 +29201,16 @@ function _sfc_render$X(_ctx, _cache, $props, $setup, $data, $options) {
28913
29201
  class: normalizeClass(_ctx.$style.content)
28914
29202
  }, [
28915
29203
  createBaseVNode("p", {
28916
- class: normalizeClass(_ctx.$style.title)
29204
+ class: normalizeClass(_ctx.$style.title),
29205
+ "data-testid": "birthday-error-title"
28917
29206
  }, [
28918
29207
  createTextVNode(toDisplayString(_ctx.lg.birthdayConfirmError.title), 1),
28919
29208
  _hoisted_2$f,
28920
29209
  createTextVNode(" " + toDisplayString(_ctx.lg.birthdayConfirmError.title2), 1)
28921
29210
  ], 2),
28922
29211
  createBaseVNode("p", {
28923
- class: normalizeClass(_ctx.$style.description)
29212
+ class: normalizeClass(_ctx.$style.description),
29213
+ "data-testid": "birthday-error-description"
28924
29214
  }, [
28925
29215
  createTextVNode(toDisplayString(_ctx.lg.birthdayConfirmError.desc), 1),
28926
29216
  _hoisted_3$b,
@@ -28933,7 +29223,7 @@ function _sfc_render$X(_ctx, _cache, $props, $setup, $data, $options) {
28933
29223
  createVNode(_component_Button, {
28934
29224
  type: "primary",
28935
29225
  block: "",
28936
- "data-test": "birthday-confirm-error-check-help",
29226
+ "data-testid": "birthday-confirm-error-check-help",
28937
29227
  onClick: _ctx.helpPageClick
28938
29228
  }, {
28939
29229
  default: withCtx(() => [
@@ -28944,7 +29234,7 @@ function _sfc_render$X(_ctx, _cache, $props, $setup, $data, $options) {
28944
29234
  createVNode(_component_Button, {
28945
29235
  type: "link",
28946
29236
  block: "",
28947
- "data-test": "birthday-confirm-error-close-button",
29237
+ "data-testid": "birthday-confirm-error-close-button",
28948
29238
  onClick: _ctx.close
28949
29239
  }, {
28950
29240
  default: withCtx(() => [
@@ -29092,6 +29382,8 @@ function makeSound(url) {
29092
29382
  setTimeout(() => {
29093
29383
  if (audio) {
29094
29384
  try {
29385
+ if (void 0)
29386
+ ;
29095
29387
  audio.play().catch((e) => {
29096
29388
  console.warn(e);
29097
29389
  });
@@ -29327,7 +29619,7 @@ function _sfc_render$V(_ctx, _cache, $props, $setup, $data, $options) {
29327
29619
  class: normalizeClass(_ctx.style.closeImage),
29328
29620
  src: _ctx.images.whiteIconClose,
29329
29621
  style: normalizeStyle([_ctx.isMobile ? _ctx.headerFix : {}]),
29330
- "data-test": "cash-back-detail-close-button",
29622
+ "data-testid": "cash-back-detail-close-button",
29331
29623
  onClick: _cache[1] || (_cache[1] = (...args) => _ctx.close && _ctx.close(...args))
29332
29624
  }, null, 14, _hoisted_1$u)) : createCommentVNode("", true),
29333
29625
  _ctx.showFullScreenContent ? (openBlock(), createElementBlock("div", {
@@ -29335,14 +29627,15 @@ function _sfc_render$V(_ctx, _cache, $props, $setup, $data, $options) {
29335
29627
  class: normalizeClass(_ctx.style.campaignContainer)
29336
29628
  }, [
29337
29629
  createBaseVNode("p", {
29338
- class: normalizeClass(_ctx.style.optionalText)
29630
+ class: normalizeClass(_ctx.style.optionalText),
29631
+ "data-testid": "cashback-optional-text"
29339
29632
  }, toDisplayString(_ctx.animation.optionalText), 3),
29340
29633
  createBaseVNode("div", {
29341
29634
  class: normalizeClass(_ctx.style.actionsButtonContainer)
29342
29635
  }, [
29343
29636
  _ctx.showCampaignDetail ? (openBlock(), createBlock(_component_FloatingButton, {
29344
29637
  key: 0,
29345
- "data-test": "cash-back-detail-detail-button",
29638
+ "data-testid": "cash-back-detail-detail-button",
29346
29639
  "image-url": _ctx.images.myOffer,
29347
29640
  onClick: _ctx.openCampaignDetail
29348
29641
  }, {
@@ -29353,7 +29646,7 @@ function _sfc_render$V(_ctx, _cache, $props, $setup, $data, $options) {
29353
29646
  }, 8, ["image-url", "onClick"])) : createCommentVNode("", true),
29354
29647
  _ctx.showCampaignHome ? (openBlock(), createBlock(_component_FloatingButton, {
29355
29648
  key: 1,
29356
- "data-test": "cash-back-detail-home-button",
29649
+ "data-testid": "cash-back-detail-home-button",
29357
29650
  "image-url": _ctx.images.myOffer,
29358
29651
  onClick: _ctx.openCampaignHome
29359
29652
  }, {
@@ -29364,7 +29657,7 @@ function _sfc_render$V(_ctx, _cache, $props, $setup, $data, $options) {
29364
29657
  }, 8, ["image-url", "onClick"])) : createCommentVNode("", true),
29365
29658
  _ctx.showShare ? (openBlock(), createBlock(_component_FloatingButton, {
29366
29659
  key: 2,
29367
- "data-test": "cash-back-detail-share-button",
29660
+ "data-testid": "cash-back-detail-share-button",
29368
29661
  "image-url": _ctx.images.share,
29369
29662
  "button-class": _ctx.style.shareButton,
29370
29663
  onClick: _ctx.openShare
@@ -29414,13 +29707,13 @@ const _sfc_main$U = defineComponent({
29414
29707
  },
29415
29708
  setup(props, { emit }) {
29416
29709
  const style = useCssModule();
29417
- const click = (price2) => {
29710
+ const click2 = (price2) => {
29418
29711
  emit("click", price2);
29419
29712
  };
29420
29713
  return {
29421
29714
  style,
29422
29715
  numberWithCommas,
29423
- click
29716
+ click: click2
29424
29717
  };
29425
29718
  }
29426
29719
  });
@@ -30008,6 +30301,10 @@ const _sfc_main$Q = defineComponent({
30008
30301
  type: Array,
30009
30302
  default: () => [2e3, 3e3, 5e3, 1e4, 3e4, 5e4, 1e5],
30010
30303
  required: false
30304
+ },
30305
+ appealDescription: {
30306
+ type: Object,
30307
+ default: null
30011
30308
  }
30012
30309
  },
30013
30310
  emits: {
@@ -30204,10 +30501,11 @@ function _sfc_render$Q(_ctx, _cache, $props, $setup, $data, $options) {
30204
30501
  "payment-methods": _ctx.paymentMethods,
30205
30502
  "select-payment-index": _ctx.selectIndex,
30206
30503
  "show-payment-method-list": _ctx.showPaymentMethodList,
30504
+ "appeal-description": _ctx.appealDescription,
30207
30505
  "is-topup-pay": true,
30208
30506
  onSelectPaymentMethod: _ctx.select,
30209
30507
  onShow: _ctx.openPaymentMethod
30210
- }, null, 8, ["title", "payment-method", "payment-methods", "select-payment-index", "show-payment-method-list", "onSelectPaymentMethod", "onShow"])), [
30508
+ }, null, 8, ["title", "payment-method", "payment-methods", "select-payment-index", "show-payment-method-list", "appeal-description", "onSelectPaymentMethod", "onShow"])), [
30211
30509
  [vShow, !_ctx.done]
30212
30510
  ]) : createCommentVNode("", true),
30213
30511
  _ctx.showUserAddress && _ctx.isDesktop ? (openBlock(), createBlock(_component_GetUserAddressApp, {
@@ -30313,7 +30611,8 @@ const _sfc_main$P = defineComponent({
30313
30611
  components: {
30314
30612
  Header,
30315
30613
  PaymentMethodList,
30316
- Divider
30614
+ Divider,
30615
+ MaintenanceInfo
30317
30616
  },
30318
30617
  props: {
30319
30618
  paymentMethods: {
@@ -30340,6 +30639,10 @@ const _sfc_main$P = defineComponent({
30340
30639
  type: Boolean,
30341
30640
  required: false,
30342
30641
  default: true
30642
+ },
30643
+ appealDescription: {
30644
+ type: Object,
30645
+ default: null
30343
30646
  }
30344
30647
  },
30345
30648
  emits: {
@@ -30369,6 +30672,7 @@ const _sfc_main$P = defineComponent({
30369
30672
  const _hoisted_1$o = /* @__PURE__ */ createBaseVNode("br", null, null, -1);
30370
30673
  function _sfc_render$P(_ctx, _cache, $props, $setup, $data, $options) {
30371
30674
  const _component_Header = resolveComponent("Header");
30675
+ const _component_MaintenanceInfo = resolveComponent("MaintenanceInfo");
30372
30676
  const _component_PaymentMethodList = resolveComponent("PaymentMethodList");
30373
30677
  const _component_Divider = resolveComponent("Divider");
30374
30678
  const _directive_vertical_scroll = resolveDirective("vertical-scroll");
@@ -30388,6 +30692,7 @@ function _sfc_render$P(_ctx, _cache, $props, $setup, $data, $options) {
30388
30692
  class: normalizeClass({ [_ctx.style.paymentList]: true, [_ctx.style.payment]: !_ctx.isTopup }),
30389
30693
  "data-testid": "payment-list"
30390
30694
  }, [
30695
+ createVNode(_component_MaintenanceInfo, { "maintenance-info": _ctx.appealDescription }, null, 8, ["maintenance-info"]),
30391
30696
  createVNode(_component_PaymentMethodList, {
30392
30697
  "select-payment-index": _ctx.selectIndex,
30393
30698
  "payment-methods": _ctx.paymentMethods,
@@ -30508,12 +30813,13 @@ const createButtonsAmount = (price2, arr) => {
30508
30813
  return _arr.filter((_price) => _price >= price2);
30509
30814
  };
30510
30815
  function useData(props) {
30511
- var _a, _b, _c, _d, _e;
30816
+ var _a, _b, _c, _d, _e, _f;
30512
30817
  const lastUsedMethod = getLastTopupPayMethod();
30513
30818
  const state = reactive({
30514
30819
  paymentMethods: (_a = props.insufficientBalanceInfo) == null ? void 0 : _a.paymentMethodList,
30515
- index: isValidPaymentMethod(lastUsedMethod, (_b = props.insufficientBalanceInfo) == null ? void 0 : _b.paymentMethodList) ? (_c = props.insufficientBalanceInfo) == null ? void 0 : _c.paymentMethodList.findIndex((method2) => method2.paymentMethodId === lastUsedMethod) : findFirstValidMethod((_d = props.insufficientBalanceInfo) == null ? void 0 : _d.paymentMethodList),
30516
- topupAmount: (_e = props.insufficientBalanceInfo) == null ? void 0 : _e.recommendedTopupAmount,
30820
+ appealDescription: (_b = props.insufficientBalanceInfo) == null ? void 0 : _b.appealDescription,
30821
+ index: isValidPaymentMethod(lastUsedMethod, (_c = props.insufficientBalanceInfo) == null ? void 0 : _c.paymentMethodList) ? (_d = props.insufficientBalanceInfo) == null ? void 0 : _d.paymentMethodList.findIndex((method2) => method2.paymentMethodId === lastUsedMethod) : findFirstValidMethod((_e = props.insufficientBalanceInfo) == null ? void 0 : _e.paymentMethodList),
30822
+ topupAmount: (_f = props.insufficientBalanceInfo) == null ? void 0 : _f.recommendedTopupAmount,
30517
30823
  mount: false,
30518
30824
  unmount: false,
30519
30825
  showChargeList: false,
@@ -30549,6 +30855,7 @@ function useData(props) {
30549
30855
  const setScrollState = (data2) => {
30550
30856
  state.isScrollable = data2;
30551
30857
  };
30858
+ const appealDescription = computed(() => state.appealDescription);
30552
30859
  return {
30553
30860
  available,
30554
30861
  selectIndex: computed(() => state.index),
@@ -30570,7 +30877,8 @@ function useData(props) {
30570
30877
  closeChargeList,
30571
30878
  closePaymentList,
30572
30879
  isScrollable: computed(() => state.isScrollable),
30573
- setScrollState
30880
+ setScrollState,
30881
+ appealDescription
30574
30882
  };
30575
30883
  }
30576
30884
  const _sfc_main$O = defineComponent({
@@ -30656,7 +30964,8 @@ const _sfc_main$O = defineComponent({
30656
30964
  topupAmount: topupAmount2,
30657
30965
  available,
30658
30966
  isScrollable,
30659
- setScrollState
30967
+ setScrollState,
30968
+ appealDescription
30660
30969
  } = useData(props);
30661
30970
  onMounted(() => {
30662
30971
  setMount();
@@ -30777,7 +31086,8 @@ const _sfc_main$O = defineComponent({
30777
31086
  selectTopupList,
30778
31087
  addressSelect,
30779
31088
  updateAddress,
30780
- handleUpdate
31089
+ handleUpdate,
31090
+ appealDescription
30781
31091
  };
30782
31092
  }
30783
31093
  });
@@ -30846,6 +31156,7 @@ function _sfc_render$O(_ctx, _cache, $props, $setup, $data, $options) {
30846
31156
  "show-user-address": _ctx.showUserAddress,
30847
31157
  addresses: _ctx.addresses,
30848
31158
  "selected-address": _ctx.selectedAddress,
31159
+ "appeal-description": _ctx.appealDescription,
30849
31160
  onSelect: _ctx.selectPaymentList,
30850
31161
  onAnimationEnd: _ctx.animationEnd,
30851
31162
  onSetMoney: _ctx.setMoney,
@@ -30858,7 +31169,7 @@ function _sfc_render$O(_ctx, _cache, $props, $setup, $data, $options) {
30858
31169
  onChooseAddress: _ctx.addressSelect,
30859
31170
  onLayoutUpdate: _ctx.handleUpdate,
30860
31171
  onUpdateAddress: _ctx.updateAddress
30861
- }, null, 8, ["container-class", "payment-method", "topup-amount-text", "banner-info", "done", "paying", "amount-buttons", "halfsheet-amount", "available", "payment-methods", "select-index", "is-scrollable", "show-user-address", "addresses", "selected-address", "onSelect", "onAnimationEnd", "onSetMoney", "onSelectmoremoney", "onShowConsult", "onOpenPaymentMethod", "onCharge", "onClose", "onShowPaymentList", "onChooseAddress", "onLayoutUpdate", "onUpdateAddress"])
31172
+ }, null, 8, ["container-class", "payment-method", "topup-amount-text", "banner-info", "done", "paying", "amount-buttons", "halfsheet-amount", "available", "payment-methods", "select-index", "is-scrollable", "show-user-address", "addresses", "selected-address", "appeal-description", "onSelect", "onAnimationEnd", "onSetMoney", "onSelectmoremoney", "onShowConsult", "onOpenPaymentMethod", "onCharge", "onClose", "onShowPaymentList", "onChooseAddress", "onLayoutUpdate", "onUpdateAddress"])
30862
31173
  ], 2),
30863
31174
  createVNode(Transition, {
30864
31175
  "enter-active-class": _ctx.style.slideSecondaryEnterActive,
@@ -30900,10 +31211,11 @@ function _sfc_render$O(_ctx, _cache, $props, $setup, $data, $options) {
30900
31211
  key: 0,
30901
31212
  class: normalizeClass([_ctx.style.listContainer]),
30902
31213
  "payment-methods": _ctx.paymentMethods,
31214
+ "appeal-description": _ctx.appealDescription,
30903
31215
  "select-index": _ctx.selectIndex,
30904
31216
  onSelectPaymentMethod: _ctx.selectPaymentList,
30905
31217
  onBack: _ctx.closePaymentList
30906
- }, null, 8, ["class", "payment-methods", "select-index", "onSelectPaymentMethod", "onBack"])) : createCommentVNode("", true)
31218
+ }, null, 8, ["class", "payment-methods", "appeal-description", "select-index", "onSelectPaymentMethod", "onBack"])) : createCommentVNode("", true)
30907
31219
  ]),
30908
31220
  _: 1
30909
31221
  }, 8, ["enter-active-class", "leave-active-class", "enter-from-class"])
@@ -31149,13 +31461,14 @@ function usePaymentMethod(props) {
31149
31461
  paymentMethods: [],
31150
31462
  selectPaymentIndex: 0,
31151
31463
  bannerInfo: null,
31152
- showPaymentMethodList: false
31464
+ showPaymentMethodList: false,
31465
+ appealDescription: null
31153
31466
  });
31154
31467
  const showPaymentMethod = () => {
31155
31468
  paymentState.showPaymentMethodList = true;
31156
31469
  };
31157
31470
  const getPaymentMethods = async (dryRun) => {
31158
- var _a, _b, _c, _d, _e, _f, _g, _h;
31471
+ var _a, _b, _c, _d, _e, _f, _g;
31159
31472
  const res = await getPaymentMethods2({
31160
31473
  merchant: (_a = props == null ? void 0 : props.paymentParams) == null ? void 0 : _a.merchantAlias,
31161
31474
  type: ((_b = props.paymentParams) == null ? void 0 : _b.isAuthorization) ? "PRE_AUTH" : "ACQUIRING",
@@ -31169,7 +31482,7 @@ function usePaymentMethod(props) {
31169
31482
  result: false
31170
31483
  };
31171
31484
  }
31172
- const paymentMethodList = (_h = (_g = (_f = (_e = res == null ? void 0 : res.body) == null ? void 0 : _e.unsigned) == null ? void 0 : _f.data) == null ? void 0 : _g.payload) == null ? void 0 : _h.paymentMethodList;
31485
+ const { paymentMethodList, appealDescription } = ((_g = (_f = (_e = res == null ? void 0 : res.body) == null ? void 0 : _e.unsigned) == null ? void 0 : _f.data) == null ? void 0 : _g.payload) || {};
31173
31486
  paymentState.paymentMethods = paymentMethodList;
31174
31487
  const walletPaymentMethod = paymentMethodList ? paymentMethodList.find((elem2) => elem2.paymentMethodType === PaymentMethodType.WALLET) || null : null;
31175
31488
  if (walletPaymentMethod && walletPaymentMethod.descriptionBannerInfo) {
@@ -31179,6 +31492,7 @@ function usePaymentMethod(props) {
31179
31492
  paymentState.paymentMethods = paymentMethodList ? paymentMethodList.filter(function(method2) {
31180
31493
  return method2.paymentMethodType !== PaymentMethodType.PAY_LATER;
31181
31494
  }) : paymentMethodList;
31495
+ paymentState.appealDescription = appealDescription;
31182
31496
  paymentState.selectPaymentIndex = isValidPaymentMethod(lastSavedMethod, paymentState == null ? void 0 : paymentState.paymentMethods) ? paymentState.paymentMethods.findIndex((method2) => method2.paymentMethodId === lastSavedMethod) : findFirstValidMethod(paymentState.paymentMethods);
31183
31497
  return {
31184
31498
  res,
@@ -31197,7 +31511,8 @@ function usePaymentMethod(props) {
31197
31511
  paymentMethods: computed(() => paymentState.paymentMethods),
31198
31512
  selectPaymentIndex: computed(() => paymentState.selectPaymentIndex),
31199
31513
  bannerInfo: computed(() => paymentState.bannerInfo),
31200
- showPaymentMethodList: computed(() => paymentState.showPaymentMethodList)
31514
+ showPaymentMethodList: computed(() => paymentState.showPaymentMethodList),
31515
+ appealDescription: computed(() => paymentState.appealDescription)
31201
31516
  };
31202
31517
  }
31203
31518
  function useConsult(props) {
@@ -31846,7 +32161,8 @@ const _sfc_main$M = defineComponent({
31846
32161
  selectPaymentIndex,
31847
32162
  showPaymentMethod,
31848
32163
  bannerInfo: bannerInfo2,
31849
- showPaymentMethodList
32164
+ showPaymentMethodList,
32165
+ appealDescription
31850
32166
  } = usePaymentMethod(props);
31851
32167
  const { pay: pay2, paymentId: paymentId2 } = usePayment(props, {
31852
32168
  paymentMethod: paymentMethod2,
@@ -31909,13 +32225,17 @@ const _sfc_main$M = defineComponent({
31909
32225
  const address2 = (selectedAddress == null ? void 0 : selectedAddress.value) ? __spreadValues({}, selectedAddress.value) : null;
31910
32226
  paymentSuccess(res, address2);
31911
32227
  watch(() => paymentHandler.value, async () => {
31912
- var _a2, _b;
32228
+ var _a2, _b, _c;
31913
32229
  if (!(paymentHandler == null ? void 0 : paymentHandler.value))
31914
32230
  return;
32231
+ if ((_a2 = props == null ? void 0 : props.paymentParams) == null ? void 0 : _a2.alwaysHideCompletionScreen) {
32232
+ endApplication();
32233
+ return;
32234
+ }
31915
32235
  const cashBack2 = getCashBackDetail({
31916
32236
  paymentId: res.unsigned.data.paymentId
31917
32237
  });
31918
- const alwaysDisplay = ((_a2 = props == null ? void 0 : props.paymentParams) == null ? void 0 : _a2.alwaysDisplayCompletionScreen) || ((_b = props == null ? void 0 : props.paymentParams) == null ? void 0 : _b.isAuthorization);
32238
+ const alwaysDisplay = ((_b = props == null ? void 0 : props.paymentParams) == null ? void 0 : _b.alwaysDisplayCompletionScreen) || ((_c = props == null ? void 0 : props.paymentParams) == null ? void 0 : _c.isAuthorization);
31919
32239
  endPayment();
31920
32240
  if (alwaysDisplay) {
31921
32241
  showPaymentResult(res.unsigned.data);
@@ -32077,7 +32397,8 @@ const _sfc_main$M = defineComponent({
32077
32397
  show3DSecureSheet,
32078
32398
  selectedTopupMethod,
32079
32399
  close3DSecureSheet,
32080
- selectedCCType
32400
+ selectedCCType,
32401
+ appealDescription
32081
32402
  };
32082
32403
  }
32083
32404
  });
@@ -32121,6 +32442,7 @@ function _sfc_render$M(_ctx, _cache, $props, $setup, $data, $options) {
32121
32442
  "select-payment-index": _ctx.selectPaymentIndex,
32122
32443
  "show-payment-method-list": _ctx.showPaymentMethodList,
32123
32444
  addresses: _ctx.addressList,
32445
+ "appeal-description": _ctx.appealDescription,
32124
32446
  onClose: _ctx.cancelPayment,
32125
32447
  onPay: _ctx.pay,
32126
32448
  onCharge: _ctx.openCharge,
@@ -32131,7 +32453,7 @@ function _sfc_render$M(_ctx, _cache, $props, $setup, $data, $options) {
32131
32453
  onSelect: _ctx.selectPayment,
32132
32454
  onShowPaymentMethod: _ctx.showPaymentMethod,
32133
32455
  onUpdateAddress: _ctx.updateAddress
32134
- }, null, 8, ["payment-method", "price", "done", "paying", "loading", "banner-info", "insufficient-balance-info", "tax-exempt", "payment-methods", "selected-address", "payment-params", "show-user-address", "select-payment-index", "show-payment-method-list", "addresses", "onClose", "onPay", "onCharge", "onChoosePaymentMethods", "onChooseAddress", "onAnimationEnd", "onOpenConsult", "onSelect", "onShowPaymentMethod", "onUpdateAddress"])) : createCommentVNode("", true),
32456
+ }, null, 8, ["payment-method", "price", "done", "paying", "loading", "banner-info", "insufficient-balance-info", "tax-exempt", "payment-methods", "selected-address", "payment-params", "show-user-address", "select-payment-index", "show-payment-method-list", "addresses", "appeal-description", "onClose", "onPay", "onCharge", "onChoosePaymentMethods", "onChooseAddress", "onAnimationEnd", "onOpenConsult", "onSelect", "onShowPaymentMethod", "onUpdateAddress"])) : createCommentVNode("", true),
32135
32457
  createVNode(Transition, {
32136
32458
  "enter-active-class": _ctx.$style.slideSecondaryEnterActive,
32137
32459
  "leave-active-class": _ctx.$style.slideSecondaryLeaveActive,
@@ -32166,13 +32488,14 @@ function _sfc_render$M(_ctx, _cache, $props, $setup, $data, $options) {
32166
32488
  _ctx.isVisiblePaymentMethod && _ctx.isMobile ? (openBlock(), createBlock(_component_ChoosePayment, {
32167
32489
  key: 0,
32168
32490
  "payment-methods": _ctx.paymentMethods,
32491
+ "appeal-description": _ctx.appealDescription,
32169
32492
  "root-style": {
32170
32493
  [_ctx.$style.longHeightContainer]: _ctx.selectedAddress && _ctx.insufficientBalanceInfo
32171
32494
  },
32172
32495
  "select-payment-index": _ctx.selectPaymentIndex,
32173
32496
  onBack: _ctx.backClick,
32174
32497
  onSelect: _ctx.selectPayment
32175
- }, null, 8, ["payment-methods", "root-style", "select-payment-index", "onBack", "onSelect"])) : createCommentVNode("", true)
32498
+ }, null, 8, ["payment-methods", "appeal-description", "root-style", "select-payment-index", "onBack", "onSelect"])) : createCommentVNode("", true)
32176
32499
  ]),
32177
32500
  _: 1
32178
32501
  }, 8, ["enter-active-class", "leave-active-class", "enter-from-class"])
@@ -32543,14 +32866,27 @@ function createWrapComplete(fn) {
32543
32866
  };
32544
32867
  }
32545
32868
  const makePayment = async (params) => {
32546
- var _a, _b, _c, _d;
32547
- if ((_b = (_a = params == null ? void 0 : params.additionalUserInfo) == null ? void 0 : _a.userAddress) == null ? void 0 : _b.visible) {
32548
- const grantStatus = await checkPermission(PermissionName.mini_app_user_address);
32549
- if (grantStatus !== PermissionStatus.granted) {
32550
- (_c = params == null ? void 0 : params.fail) == null ? void 0 : _c.call(params, {
32551
- errorCode: MiniAppErrorType.insufficientScope
32869
+ var _a, _b, _c, _d, _e, _f, _g, _h;
32870
+ if ((params == null ? void 0 : params.alwaysDisplayCompletionScreen) && (params == null ? void 0 : params.alwaysHideCompletionScreen)) {
32871
+ (_a = params == null ? void 0 : params.fail) == null ? void 0 : _a.call(params, {
32872
+ errorCode: MiniAppErrorType.badRequest
32873
+ });
32874
+ return (_b = params == null ? void 0 : params.complete) == null ? void 0 : _b.call(params);
32875
+ }
32876
+ if ((_d = (_c = params == null ? void 0 : params.additionalUserInfo) == null ? void 0 : _c.userAddress) == null ? void 0 : _d.visible) {
32877
+ try {
32878
+ const grantStatus = await checkPermission(PermissionName.mini_app_user_address);
32879
+ if (grantStatus !== PermissionStatus.granted) {
32880
+ (_e = params == null ? void 0 : params.fail) == null ? void 0 : _e.call(params, {
32881
+ errorCode: MiniAppErrorType.insufficientScope
32882
+ });
32883
+ return (_f = params == null ? void 0 : params.complete) == null ? void 0 : _f.call(params);
32884
+ }
32885
+ } catch {
32886
+ (_g = params == null ? void 0 : params.fail) == null ? void 0 : _g.call(params, {
32887
+ errorCode: MiniAppErrorType.serverError
32552
32888
  });
32553
- return (_d = params == null ? void 0 : params.complete) == null ? void 0 : _d.call(params);
32889
+ return (_h = params == null ? void 0 : params.complete) == null ? void 0 : _h.call(params);
32554
32890
  }
32555
32891
  }
32556
32892
  const success2 = params.success;
@@ -32677,6 +33013,8 @@ const Currency = defineComponent({
32677
33013
  };
32678
33014
  watch(() => props.modelValue, (value2) => {
32679
33015
  updateValue(value2);
33016
+ }, {
33017
+ immediate: true
32680
33018
  });
32681
33019
  return () => createVNode("div", {
32682
33020
  "class": [styles$1.ppmnaInput, {
@@ -32718,7 +33056,7 @@ const _sfc_main$K = defineComponent({
32718
33056
  },
32719
33057
  setup(props, { emit }) {
32720
33058
  const style = useCssModule();
32721
- const click = (item2, index2) => {
33059
+ const click2 = (item2, index2) => {
32722
33060
  emit("click", item2, index2);
32723
33061
  };
32724
33062
  return {
@@ -32738,7 +33076,7 @@ const _sfc_main$K = defineComponent({
32738
33076
  var _a, _b, _c;
32739
33077
  return (_c = (_b = (_a = props == null ? void 0 : props.selectedPaymentMethod) == null ? void 0 : _a.descriptionBannerInfo) == null ? void 0 : _b.displayResponse) == null ? void 0 : _c.buttonList;
32740
33078
  }),
32741
- click,
33079
+ click: click2,
32742
33080
  style
32743
33081
  };
32744
33082
  }
@@ -33013,52 +33351,55 @@ function _sfc_render$I(_ctx, _cache, $props, $setup, $data, $options) {
33013
33351
  const cssModules$z = {};
33014
33352
  cssModules$z["$style"] = style0$z;
33015
33353
  var TopupCompletion = /* @__PURE__ */ _export_sfc(_sfc_main$I, [["render", _sfc_render$I], ["__cssModules", cssModules$z]]);
33016
- const slideSecondaryEnterActive = "_slideSecondaryEnterActive_8j48o_7";
33017
- const slideSecondaryLeaveActive = "_slideSecondaryLeaveActive_8j48o_10";
33018
- const slideSecondaryEnterFrom = "_slideSecondaryEnterFrom_8j48o_13";
33019
- const wrapperClass$4 = "_wrapperClass_8j48o_17";
33020
- const topupWrapper = "_topupWrapper_8j48o_17";
33021
- const noBorder = "_noBorder_8j48o_23";
33022
- const fullHeight = "_fullHeight_8j48o_26";
33023
- const choosePayment$2 = "_choosePayment_8j48o_30";
33024
- const topupMoneyLabel = "_topupMoneyLabel_8j48o_37";
33025
- const topupCharge = "_topupCharge_8j48o_45";
33026
- const fullHeightCharge = "_fullHeightCharge_8j48o_51";
33027
- const topup$2 = "_topup_8j48o_17";
33028
- const banner = "_banner_8j48o_63";
33029
- const bannerText = "_bannerText_8j48o_66";
33030
- const bannerMargin = "_bannerMargin_8j48o_69";
33031
- const amountList$1 = "_amountList_8j48o_72";
33032
- const paymentType = "_paymentType_8j48o_93";
33033
- const invalidAmount = "_invalidAmount_8j48o_97";
33034
- const loadingText = "_loadingText_8j48o_102";
33035
- const chargeSelect = "_chargeSelect_8j48o_111";
33036
- const blueDivider = "_blueDivider_8j48o_116";
33037
- const chargeMoney = "_chargeMoney_8j48o_123";
33038
- const unit$2 = "_unit_8j48o_129";
33039
- const chargeInput = "_chargeInput_8j48o_132";
33040
- const fullHeightInput = "_fullHeightInput_8j48o_147";
33041
- const inputLeft = "_inputLeft_8j48o_150";
33042
- const inputRight = "_inputRight_8j48o_157";
33043
- const noMethod = "_noMethod_8j48o_164";
33044
- const topupMoney = "_topupMoney_8j48o_37";
33045
- const moneyLabel = "_moneyLabel_8j48o_177";
33046
- const btnContainer = "_btnContainer_8j48o_181";
33047
- const fullBtnContainer = "_fullBtnContainer_8j48o_188";
33048
- const moneyList = "_moneyList_8j48o_203";
33049
- const doneContainer = "_doneContainer_8j48o_210";
33050
- const fullHeightLottie = "_fullHeightLottie_8j48o_217";
33051
- const ppmnaLottie = "_ppmnaLottie_8j48o_220";
33052
- const moreMoney = "_moreMoney_8j48o_225";
33053
- const fullHeightPayMethod = "_fullHeightPayMethod_8j48o_230";
33354
+ const slideSecondaryEnterActive = "_slideSecondaryEnterActive_1h3dw_7";
33355
+ const slideSecondaryLeaveActive = "_slideSecondaryLeaveActive_1h3dw_10";
33356
+ const slideSecondaryEnterFrom = "_slideSecondaryEnterFrom_1h3dw_13";
33357
+ const wrapperClass$4 = "_wrapperClass_1h3dw_17";
33358
+ const topupWrapper = "_topupWrapper_1h3dw_17";
33359
+ const noBorder = "_noBorder_1h3dw_23";
33360
+ const dummyInput = "_dummyInput_1h3dw_26";
33361
+ const fullHeight = "_fullHeight_1h3dw_30";
33362
+ const choosePayment$2 = "_choosePayment_1h3dw_34";
33363
+ const topupMoneyLabel = "_topupMoneyLabel_1h3dw_41";
33364
+ const topupCharge = "_topupCharge_1h3dw_49";
33365
+ const fullHeightCharge = "_fullHeightCharge_1h3dw_55";
33366
+ const topup$2 = "_topup_1h3dw_17";
33367
+ const banner = "_banner_1h3dw_67";
33368
+ const bannerText = "_bannerText_1h3dw_70";
33369
+ const bannerMargin = "_bannerMargin_1h3dw_73";
33370
+ const amountList$1 = "_amountList_1h3dw_76";
33371
+ const paymentType = "_paymentType_1h3dw_97";
33372
+ const invalidAmount = "_invalidAmount_1h3dw_101";
33373
+ const loadingText = "_loadingText_1h3dw_106";
33374
+ const fakeInput = "_fakeInput_1h3dw_115";
33375
+ const chargeSelect = "_chargeSelect_1h3dw_122";
33376
+ const blueDivider = "_blueDivider_1h3dw_127";
33377
+ const chargeMoney = "_chargeMoney_1h3dw_134";
33378
+ const unit$2 = "_unit_1h3dw_140";
33379
+ const chargeInput = "_chargeInput_1h3dw_143";
33380
+ const fullHeightInput = "_fullHeightInput_1h3dw_158";
33381
+ const inputLeft = "_inputLeft_1h3dw_161";
33382
+ const inputRight = "_inputRight_1h3dw_168";
33383
+ const noMethod = "_noMethod_1h3dw_175";
33384
+ const topupMoney = "_topupMoney_1h3dw_41";
33385
+ const moneyLabel = "_moneyLabel_1h3dw_188";
33386
+ const btnContainer = "_btnContainer_1h3dw_192";
33387
+ const fullBtnContainer = "_fullBtnContainer_1h3dw_199";
33388
+ const moneyList = "_moneyList_1h3dw_214";
33389
+ const doneContainer = "_doneContainer_1h3dw_221";
33390
+ const fullHeightLottie = "_fullHeightLottie_1h3dw_228";
33391
+ const ppmnaLottie = "_ppmnaLottie_1h3dw_231";
33392
+ const moreMoney = "_moreMoney_1h3dw_236";
33393
+ const fullHeightPayMethod = "_fullHeightPayMethod_1h3dw_241";
33054
33394
  var style0$y = {
33055
- "ppmna-default-font": "_ppmna-default-font_8j48o_1",
33395
+ "ppmna-default-font": "_ppmna-default-font_1h3dw_1",
33056
33396
  slideSecondaryEnterActive,
33057
33397
  slideSecondaryLeaveActive,
33058
33398
  slideSecondaryEnterFrom,
33059
33399
  wrapperClass: wrapperClass$4,
33060
33400
  topupWrapper,
33061
33401
  noBorder,
33402
+ dummyInput,
33062
33403
  fullHeight,
33063
33404
  choosePayment: choosePayment$2,
33064
33405
  topupMoneyLabel,
@@ -33072,6 +33413,7 @@ var style0$y = {
33072
33413
  paymentType,
33073
33414
  invalidAmount,
33074
33415
  loadingText,
33416
+ fakeInput,
33075
33417
  chargeSelect,
33076
33418
  blueDivider,
33077
33419
  chargeMoney,
@@ -33166,13 +33508,13 @@ const _sfc_main$H = defineComponent({
33166
33508
  ORDINARY: "\u666E\u901A"
33167
33509
  },
33168
33510
  lottieAnim: null,
33169
- footerposition: false,
33170
33511
  cashbackData: {},
33171
33512
  lg: getLanguage(),
33172
33513
  images: getImages(),
33173
33514
  isFirstLoad: false,
33174
33515
  show3DSecureSheet: false,
33175
- topupMinAmount: 100
33516
+ topupMinAmount: 100,
33517
+ appealDescription: null
33176
33518
  };
33177
33519
  },
33178
33520
  computed: {
@@ -33219,7 +33561,7 @@ const _sfc_main$H = defineComponent({
33219
33561
  methods: {
33220
33562
  numberWithCommas,
33221
33563
  async init() {
33222
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n;
33564
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
33223
33565
  this.loading = true;
33224
33566
  this.isFirstLoad = true;
33225
33567
  const paymentIDParams = __spreadProps(__spreadValues({}, ((_a = this.topupParams) == null ? void 0 : _a.merchant) && {
@@ -33248,14 +33590,15 @@ const _sfc_main$H = defineComponent({
33248
33590
  this.errorShow = true;
33249
33591
  return;
33250
33592
  }
33251
- this.paymentMethodList = (_h = (_g = (_f = paymentIdResponse.body.unsigned) == null ? void 0 : _f.data) == null ? void 0 : _g.payload) == null ? void 0 : _h.paymentMethodList;
33593
+ const { paymentMethodList, appealDescription } = (_g = (_f = paymentIdResponse.body.unsigned) == null ? void 0 : _f.data) == null ? void 0 : _g.payload;
33594
+ this.paymentMethodList = paymentMethodList;
33595
+ this.appealDescription = appealDescription;
33252
33596
  this.findFirstValidMethodTopup();
33253
33597
  const config2 = getAppConfig();
33254
33598
  if (config2) {
33255
- this.inputMoney = (_i = config2 == null ? void 0 : config2.topupHalfSheetRecommendedAmount[0]) == null ? void 0 : _i.value;
33256
- this.topupHalfSheetAmount = (_j = config2 == null ? void 0 : config2.topupHalfSheetAmount[0]) == null ? void 0 : _j.value;
33257
- this.topupButtonsAmount = (_k = config2 == null ? void 0 : config2.topupButtonsAmount[0]) == null ? void 0 : _k.value;
33258
- this.topupMinAmount = (_n = (_m = (_l = config2 == null ? void 0 : config2.topupMinAmount) == null ? void 0 : _l[0]) == null ? void 0 : _m.value) != null ? _n : this.topupMinAmount;
33599
+ this.topupHalfSheetAmount = (_h = config2 == null ? void 0 : config2.topupHalfSheetAmount[0]) == null ? void 0 : _h.value;
33600
+ this.topupButtonsAmount = (_i = config2 == null ? void 0 : config2.topupButtonsAmount[0]) == null ? void 0 : _i.value;
33601
+ this.topupMinAmount = (_l = (_k = (_j = config2 == null ? void 0 : config2.topupMinAmount) == null ? void 0 : _j[0]) == null ? void 0 : _k.value) != null ? _l : this.topupMinAmount;
33259
33602
  }
33260
33603
  this.loading = false;
33261
33604
  this.isFirstLoad = false;
@@ -33271,22 +33614,23 @@ const _sfc_main$H = defineComponent({
33271
33614
  }
33272
33615
  },
33273
33616
  async switchInput() {
33274
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o;
33617
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p;
33275
33618
  this.isInput = true;
33619
+ (_a = document.getElementById("fake_input")) == null ? void 0 : _a.focus();
33276
33620
  const cashbackInfo2 = await getCashBackInfo();
33277
33621
  if (!cashbackInfo2 || (cashbackInfo2 == null ? void 0 : cashbackInfo2.ppFetchResult) !== "success") {
33278
33622
  this.errorCode = (cashbackInfo2 == null ? void 0 : cashbackInfo2.ppFetchResult) === "notAuthorized" ? MiniAppErrorType.notAuthorized : (cashbackInfo2 == null ? void 0 : cashbackInfo2.ppFetchResult) === "timeout" ? MiniAppErrorType.timeOut : MiniAppErrorType.serverError;
33279
33623
  this.showError();
33280
33624
  return;
33281
33625
  }
33282
- this.cashbackData = (_b = (_a = cashbackInfo2 == null ? void 0 : cashbackInfo2.body) == null ? void 0 : _a.data) == null ? void 0 : _b.payload;
33626
+ this.cashbackData = (_c = (_b = cashbackInfo2 == null ? void 0 : cashbackInfo2.body) == null ? void 0 : _b.data) == null ? void 0 : _c.payload;
33283
33627
  this.inputMoney = 0;
33284
33628
  this.minAmountUnmet = false;
33285
33629
  this.maxAmountExceeded = false;
33286
- this.fixBalMoney = (_h = (_g = (_f = (_e = (_d = (_c = cashbackInfo2 == null ? void 0 : cashbackInfo2.body) == null ? void 0 : _c.data) == null ? void 0 : _d.payload) == null ? void 0 : _e.walletSummary) == null ? void 0 : _f.totalBalanceInfo) == null ? void 0 : _g.balance) != null ? _h : 0;
33630
+ this.fixBalMoney = (_i = (_h = (_g = (_f = (_e = (_d = cashbackInfo2 == null ? void 0 : cashbackInfo2.body) == null ? void 0 : _d.data) == null ? void 0 : _e.payload) == null ? void 0 : _f.walletSummary) == null ? void 0 : _g.totalBalanceInfo) == null ? void 0 : _h.balance) != null ? _i : 0;
33287
33631
  this.balMoney = formatCurrency(this.inputMoney + this.fixBalMoney, 0);
33288
- this.fixCashbackBalance = (_n = (_m = (_l = (_k = (_j = (_i = cashbackInfo2 == null ? void 0 : cashbackInfo2.body) == null ? void 0 : _i.data) == null ? void 0 : _j.payload) == null ? void 0 : _k.walletSummary) == null ? void 0 : _l.allTotalBalanceInfo) == null ? void 0 : _m.balance) != null ? _n : 0;
33289
- this.totalCashbackBalance = (_o = formatCurrency(this.inputMoney + this.fixCashbackBalance, 0)) != null ? _o : "0";
33632
+ this.fixCashbackBalance = (_o = (_n = (_m = (_l = (_k = (_j = cashbackInfo2 == null ? void 0 : cashbackInfo2.body) == null ? void 0 : _j.data) == null ? void 0 : _k.payload) == null ? void 0 : _l.walletSummary) == null ? void 0 : _m.allTotalBalanceInfo) == null ? void 0 : _n.balance) != null ? _o : 0;
33633
+ this.totalCashbackBalance = (_p = formatCurrency(this.inputMoney + this.fixCashbackBalance, 0)) != null ? _p : "0";
33290
33634
  setTimeout(() => {
33291
33635
  var _a2;
33292
33636
  (_a2 = document.getElementById("inputmoney")) == null ? void 0 : _a2.focus();
@@ -33311,9 +33655,6 @@ const _sfc_main$H = defineComponent({
33311
33655
  this.$emit("click");
33312
33656
  }
33313
33657
  },
33314
- togglePosition(toggle) {
33315
- this.footerposition = toggle;
33316
- },
33317
33658
  checkValidAmount() {
33318
33659
  var _a;
33319
33660
  const inputVal = Number(String(this.inputMoney).replace(/,/g, ""));
@@ -33539,25 +33880,29 @@ function _sfc_render$H(_ctx, _cache, $props, $setup, $data, $options) {
33539
33880
  }, toDisplayString(_ctx.lg.topup.charge), 3)) : createCommentVNode("", true),
33540
33881
  !_ctx.isInput ? (openBlock(), createElementBlock("div", {
33541
33882
  key: 1,
33542
- class: normalizeClass(_ctx.$style.chargeMoney),
33543
- "data-testid": "money-text"
33883
+ class: normalizeClass(_ctx.$style.dummyInput),
33884
+ onClick: _cache[0] || (_cache[0] = withModifiers(($event) => _ctx.switchInput(), ["prevent"]))
33544
33885
  }, [
33545
- createTextVNode(toDisplayString(_ctx.numberWithCommas(_ctx.inputMoney)), 1),
33546
- createBaseVNode("span", {
33547
- class: normalizeClass(_ctx.$style.unit)
33548
- }, "\u5186", 2)
33549
- ], 2)) : createCommentVNode("", true),
33550
- !_ctx.isInput ? (openBlock(), createElementBlock("div", {
33886
+ createBaseVNode("div", {
33887
+ class: normalizeClass(_ctx.$style.chargeMoney),
33888
+ "data-testid": "money-text"
33889
+ }, [
33890
+ createTextVNode(toDisplayString(_ctx.numberWithCommas(_ctx.inputMoney)), 1),
33891
+ createBaseVNode("span", {
33892
+ class: normalizeClass(_ctx.$style.unit)
33893
+ }, "\u5186", 2)
33894
+ ], 2),
33895
+ createBaseVNode("div", {
33896
+ class: normalizeClass(_ctx.$style.blueDivider)
33897
+ }, null, 2)
33898
+ ], 2)) : (openBlock(), createElementBlock("div", {
33551
33899
  key: 2,
33552
- class: normalizeClass(_ctx.$style.blueDivider)
33553
- }, null, 2)) : (openBlock(), createElementBlock("div", {
33554
- key: 3,
33555
33900
  class: normalizeClass([_ctx.$style.chargeInput, _ctx.$style.chargeMoney])
33556
33901
  }, [
33557
33902
  createVNode(_component_Currency, {
33558
33903
  id: "inputmoney",
33559
33904
  modelValue: _ctx.inputMoney,
33560
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.inputMoney = $event),
33905
+ "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.inputMoney = $event),
33561
33906
  "input-mode": "numeric",
33562
33907
  "tab-index": 0,
33563
33908
  maxlength: "12",
@@ -33565,9 +33910,7 @@ function _sfc_render$H(_ctx, _cache, $props, $setup, $data, $options) {
33565
33910
  autofocus: false,
33566
33911
  class: normalizeClass({ [_ctx.$style.fullHeightInput]: _ctx.isInput }),
33567
33912
  "data-testid": "input-money",
33568
- onInput: _ctx.checkValidAmount,
33569
- onFocus: _cache[1] || (_cache[1] = ($event) => _ctx.togglePosition(true)),
33570
- onBlur: _cache[2] || (_cache[2] = ($event) => _ctx.togglePosition(false))
33913
+ onInput: _ctx.checkValidAmount
33571
33914
  }, null, 8, ["modelValue", "class", "onInput"]),
33572
33915
  createBaseVNode("span", {
33573
33916
  class: normalizeClass(_ctx.$style.inputLeft)
@@ -33613,7 +33956,7 @@ function _sfc_render$H(_ctx, _cache, $props, $setup, $data, $options) {
33613
33956
  }),
33614
33957
  "data-test": "toggle-payment-method",
33615
33958
  "data-testid": "toggle-payment-method",
33616
- onClick: _cache[3] || (_cache[3] = ($event) => _ctx.togglePaymentMethod(true))
33959
+ onClick: _cache[2] || (_cache[2] = ($event) => _ctx.togglePaymentMethod(true))
33617
33960
  }, [
33618
33961
  createBaseVNode("span", {
33619
33962
  class: normalizeClass(_ctx.$style.moneyLabel)
@@ -33662,7 +34005,7 @@ function _sfc_render$H(_ctx, _cache, $props, $setup, $data, $options) {
33662
34005
  loading: _ctx.loading,
33663
34006
  "data-test": "click-topup",
33664
34007
  "data-testid": "click-topup",
33665
- onClick: _cache[4] || (_cache[4] = ($event) => _ctx.clickTopup(false))
34008
+ onClick: _cache[3] || (_cache[3] = ($event) => _ctx.clickTopup(false))
33666
34009
  }, {
33667
34010
  default: withCtx(() => [
33668
34011
  createTextVNode(toDisplayString(_ctx.numberWithCommas(_ctx.inputMoney)) + " " + toDisplayString(_ctx.lg.topup.payBtn), 1)
@@ -33682,7 +34025,7 @@ function _sfc_render$H(_ctx, _cache, $props, $setup, $data, $options) {
33682
34025
  [_ctx.$style.fullHeightLottie]: _ctx.isInput,
33683
34026
  [_ctx.$style.ppmnaLottie]: true
33684
34027
  }),
33685
- onCreateLottie: _cache[5] || (_cache[5] = ($event) => _ctx.createAnime($event))
34028
+ onCreateLottie: _cache[4] || (_cache[4] = ($event) => _ctx.createAnime($event))
33686
34029
  }, null, 8, ["path", "class"])
33687
34030
  ], 2)) : createCommentVNode("", true)
33688
34031
  ], 6)) : createCommentVNode("", true),
@@ -33730,6 +34073,7 @@ function _sfc_render$H(_ctx, _cache, $props, $setup, $data, $options) {
33730
34073
  _ctx.isSelectPaymentMethod ? (openBlock(), createBlock(_component_ChoosePaymentMethod, {
33731
34074
  key: 0,
33732
34075
  "payment-methods": _ctx.paymentMethodList,
34076
+ "appeal-description": _ctx.appealDescription,
33733
34077
  "select-index": _ctx.selectPaymentIndex,
33734
34078
  class: normalizeClass({
33735
34079
  [_ctx.$style.fullHeight]: _ctx.isInput,
@@ -33739,7 +34083,7 @@ function _sfc_render$H(_ctx, _cache, $props, $setup, $data, $options) {
33739
34083
  style: normalizeStyle(_ctx.getTopHeight),
33740
34084
  onBack: _ctx.togglePaymentMethod,
33741
34085
  onSelectPaymentMethod: _ctx.selectPaymentMethod
33742
- }, null, 8, ["payment-methods", "select-index", "class", "style", "onBack", "onSelectPaymentMethod"])) : createCommentVNode("", true)
34086
+ }, null, 8, ["payment-methods", "appeal-description", "select-index", "class", "style", "onBack", "onSelectPaymentMethod"])) : createCommentVNode("", true)
33743
34087
  ]),
33744
34088
  _: 1
33745
34089
  }, 8, ["enter-active-class", "leave-active-class", "enter-from-class"])
@@ -33755,7 +34099,7 @@ function _sfc_render$H(_ctx, _cache, $props, $setup, $data, $options) {
33755
34099
  createVNode(_component_DuplicatePayment, {
33756
34100
  mode: "topup",
33757
34101
  onCancel: _ctx.duplicateCancel,
33758
- onProceed: _cache[6] || (_cache[6] = ($event) => _ctx.clickTopup(true))
34102
+ onProceed: _cache[5] || (_cache[5] = ($event) => _ctx.clickTopup(true))
33759
34103
  }, null, 8, ["onCancel"])
33760
34104
  ]),
33761
34105
  _: 1
@@ -33763,7 +34107,7 @@ function _sfc_render$H(_ctx, _cache, $props, $setup, $data, $options) {
33763
34107
  createVNode(_component_ActionSheet, {
33764
34108
  show: _ctx.bannerInfoVisible,
33765
34109
  type: "alert",
33766
- onClose: _cache[7] || (_cache[7] = ($event) => _ctx.bannerBtnClick())
34110
+ onClose: _cache[6] || (_cache[6] = ($event) => _ctx.bannerBtnClick())
33767
34111
  }, {
33768
34112
  default: withCtx(() => [
33769
34113
  createVNode(_component_BannerInfo, {
@@ -33791,13 +34135,19 @@ function _sfc_render$H(_ctx, _cache, $props, $setup, $data, $options) {
33791
34135
  "error-text": _ctx.errorInfo.desc,
33792
34136
  "button-list": _ctx.errorInfo.buttonList,
33793
34137
  show: _ctx.errorShow || _ctx.errorOverlay,
33794
- onCloseClick: _cache[8] || (_cache[8] = ($event) => _ctx.closeErrorSheet())
34138
+ onCloseClick: _cache[7] || (_cache[7] = ($event) => _ctx.closeErrorSheet())
33795
34139
  }, null, 8, ["error-title", "icon-url", "error-text", "button-list", "show"]),
33796
34140
  createVNode(_component_ThreeDSecureSheet, {
33797
34141
  show: _ctx.show3DSecureSheet,
33798
34142
  "cc-type": _ctx.selectedCCType,
33799
34143
  onClose: _ctx.close3DSecureSheet
33800
- }, null, 8, ["show", "cc-type", "onClose"])
34144
+ }, null, 8, ["show", "cc-type", "onClose"]),
34145
+ createBaseVNode("input", {
34146
+ id: "fake_input",
34147
+ type: "text",
34148
+ readonly: "",
34149
+ class: normalizeClass(_ctx.$style.fakeInput)
34150
+ }, null, 2)
33801
34151
  ], 64);
33802
34152
  }
33803
34153
  const cssModules$y = {};
@@ -33867,17 +34217,14 @@ function removeStorageData(params) {
33867
34217
  }
33868
34218
  async function getPermissionStatus(params) {
33869
34219
  const newParams = reconstructParams(params);
33870
- await execute$9(newParams);
34220
+ await execute$a(newParams);
33871
34221
  }
33872
- async function execute$9(params) {
33873
- var _a, _b, _c, _d;
34222
+ async function execute$a(params) {
34223
+ var _a, _b, _c;
33874
34224
  try {
33875
34225
  const permissionList = await getUserGrantedPermission();
33876
- if (!permissionList) {
33877
- return (_a = params == null ? void 0 : params.fail) == null ? void 0 : _a.call(params, { errorCode: MiniAppErrorType.serverError });
33878
- }
33879
34226
  if (!(params == null ? void 0 : params.name)) {
33880
- return (_b = params == null ? void 0 : params.success) == null ? void 0 : _b.call(params, {
34227
+ return (_a = params == null ? void 0 : params.success) == null ? void 0 : _a.call(params, {
33881
34228
  granted_permissions: permissionList
33882
34229
  });
33883
34230
  } else {
@@ -33885,10 +34232,10 @@ async function execute$9(params) {
33885
34232
  return name2 === (params == null ? void 0 : params.name);
33886
34233
  });
33887
34234
  const status2 = thePermission ? PermissionStatus.granted : PermissionStatus.denied;
33888
- return (_c = params == null ? void 0 : params.success) == null ? void 0 : _c.call(params, { status: status2 });
34235
+ return (_b = params == null ? void 0 : params.success) == null ? void 0 : _b.call(params, { status: status2 });
33889
34236
  }
33890
34237
  } catch (_) {
33891
- return (_d = params == null ? void 0 : params.fail) == null ? void 0 : _d.call(params, { errorCode: MiniAppErrorType.serverError });
34238
+ return (_c = params == null ? void 0 : params.fail) == null ? void 0 : _c.call(params, { errorCode: MiniAppErrorType.serverError });
33892
34239
  }
33893
34240
  }
33894
34241
  function scanCode(_params) {
@@ -34298,9 +34645,9 @@ function showUpdateWarning$1(params) {
34298
34645
  }
34299
34646
  async function getPlatformInformation(params) {
34300
34647
  const newParams = reconstructParams(params);
34301
- await execute$8(newParams);
34648
+ await execute$9(newParams);
34302
34649
  }
34303
- async function execute$8(params) {
34650
+ async function execute$9(params) {
34304
34651
  var _a, _b;
34305
34652
  let sdkVersion = null;
34306
34653
  let preferredLanguage = getPayPayLanguage();
@@ -34329,9 +34676,9 @@ async function execute$8(params) {
34329
34676
  }
34330
34677
  function getDeviceInformation(params) {
34331
34678
  const newParams = reconstructParams(params);
34332
- execute$7(newParams);
34679
+ execute$8(newParams);
34333
34680
  }
34334
- function execute$7(params) {
34681
+ function execute$8(params) {
34335
34682
  var _a;
34336
34683
  const runtime = getRuntime();
34337
34684
  (_a = params == null ? void 0 : params.success) == null ? void 0 : _a.call(params, {
@@ -34533,9 +34880,9 @@ async function share(shareParams) {
34533
34880
  }
34534
34881
  async function getKycInformation(params) {
34535
34882
  const newParams = reconstructParams(params);
34536
- await execute$6(newParams);
34883
+ await execute$7(newParams);
34537
34884
  }
34538
- async function execute$6(params) {
34885
+ async function execute$7(params) {
34539
34886
  var _a, _b, _c, _d, _e, _f, _g, _h;
34540
34887
  try {
34541
34888
  const grantStatus = await checkPermission(PermissionName.mini_app_kyc);
@@ -34565,18 +34912,24 @@ async function execute$6(params) {
34565
34912
  }
34566
34913
  }
34567
34914
  const initGetUserAddress = async (params) => {
34568
- var _a, _b;
34569
- const grantStatus = await checkPermission(PermissionName.mini_app_user_address);
34570
- if (grantStatus !== PermissionStatus.granted) {
34571
- return (_a = params == null ? void 0 : params.fail) == null ? void 0 : _a.call(params, {
34572
- errorCode: MiniAppErrorType.insufficientScope
34915
+ var _a, _b, _c;
34916
+ try {
34917
+ const grantStatus = await checkPermission(PermissionName.mini_app_user_address);
34918
+ if (grantStatus !== PermissionStatus.granted) {
34919
+ return (_a = params == null ? void 0 : params.fail) == null ? void 0 : _a.call(params, {
34920
+ errorCode: MiniAppErrorType.insufficientScope
34921
+ });
34922
+ }
34923
+ } catch {
34924
+ return (_b = params == null ? void 0 : params.fail) == null ? void 0 : _b.call(params, {
34925
+ errorCode: MiniAppErrorType.serverError
34573
34926
  });
34574
34927
  }
34575
34928
  const container2 = document.createElement("div");
34576
34929
  container2.className = "ppmna-reset-css";
34577
34930
  const res = await getAddressList();
34578
34931
  if ((res == null ? void 0 : res.ppFetchResult) !== "success") {
34579
- (_b = params == null ? void 0 : params.fail) == null ? void 0 : _b.call(params, {
34932
+ (_c = params == null ? void 0 : params.fail) == null ? void 0 : _c.call(params, {
34580
34933
  errorCode: getFailErrorCode(res == null ? void 0 : res.ppFetchResult)
34581
34934
  });
34582
34935
  return;
@@ -34601,12 +34954,12 @@ const initGetUserAddress = async (params) => {
34601
34954
  }
34602
34955
  }, popStateHandler(closeSheet, params)), {
34603
34956
  render() {
34604
- var _a2, _b2, _c;
34957
+ var _a2, _b2, _c2;
34605
34958
  return h(AppVue$7, {
34606
34959
  show: this.show,
34607
34960
  onClick: this.close,
34608
34961
  getUserAddressParams: params,
34609
- addresses: (_c = (_b2 = (_a2 = res == null ? void 0 : res.body) == null ? void 0 : _a2.unsigned) == null ? void 0 : _b2.data) == null ? void 0 : _c.addresses
34962
+ addresses: (_c2 = (_b2 = (_a2 = res == null ? void 0 : res.body) == null ? void 0 : _a2.unsigned) == null ? void 0 : _b2.data) == null ? void 0 : _c2.addresses
34610
34963
  });
34611
34964
  }
34612
34965
  }));
@@ -34925,12 +35278,12 @@ async function checkPaymentMethod(checkPayMethodParams) {
34925
35278
  }
34926
35279
  function debug(params) {
34927
35280
  const newParams = reconstructParams(params);
34928
- execute$5(newParams);
35281
+ execute$6(newParams);
34929
35282
  }
34930
- function execute$5(params) {
35283
+ function execute$6(params) {
34931
35284
  var _a;
34932
35285
  (_a = params == null ? void 0 : params.success) == null ? void 0 : _a.call(params, {
34933
- v: "1.47.0"
35286
+ v: "1.50.0"
34934
35287
  });
34935
35288
  }
34936
35289
  function useCallBack(props, ctx) {
@@ -36032,25 +36385,31 @@ function _sfc_render$y(_ctx, _cache, $props, $setup, $data, $options) {
36032
36385
  }
36033
36386
  var AppVue$1 = /* @__PURE__ */ _export_sfc(_sfc_main$y, [["render", _sfc_render$y]]);
36034
36387
  async function initRegisterEmail(initRegisterEmail2, allowsUpdate) {
36035
- var _a, _b, _c, _d, _e, _f, _g;
36036
- const grantStatus = await checkPermission(PermissionName.mini_app_user_email_address);
36037
- if (grantStatus !== PermissionStatus.granted) {
36038
- return (_a = initRegisterEmail2 == null ? void 0 : initRegisterEmail2.fail) == null ? void 0 : _a.call(initRegisterEmail2, {
36039
- errorCode: MiniAppErrorType.insufficientScope
36388
+ var _a, _b, _c, _d, _e, _f, _g, _h;
36389
+ try {
36390
+ const grantStatus = await checkPermission(PermissionName.mini_app_user_email_address);
36391
+ if (grantStatus !== PermissionStatus.granted) {
36392
+ return (_a = initRegisterEmail2 == null ? void 0 : initRegisterEmail2.fail) == null ? void 0 : _a.call(initRegisterEmail2, {
36393
+ errorCode: MiniAppErrorType.insufficientScope
36394
+ });
36395
+ }
36396
+ } catch {
36397
+ return (_b = initRegisterEmail2 == null ? void 0 : initRegisterEmail2.fail) == null ? void 0 : _b.call(initRegisterEmail2, {
36398
+ errorCode: MiniAppErrorType.serverError
36040
36399
  });
36041
36400
  }
36042
36401
  const res = await getUserProfileDataV2();
36043
36402
  if (res.ppFetchResult !== "success") {
36044
- (_b = initRegisterEmail2 == null ? void 0 : initRegisterEmail2.fail) == null ? void 0 : _b.call(initRegisterEmail2, {
36403
+ (_c = initRegisterEmail2 == null ? void 0 : initRegisterEmail2.fail) == null ? void 0 : _c.call(initRegisterEmail2, {
36045
36404
  errorCode: MiniAppErrorType.serverError
36046
36405
  });
36047
36406
  return;
36048
36407
  }
36049
- const email2 = (_d = (_c = res.body.unsigned) == null ? void 0 : _c.data) == null ? void 0 : _d.email;
36408
+ const email2 = (_e = (_d = res.body.unsigned) == null ? void 0 : _d.data) == null ? void 0 : _e.email;
36050
36409
  const emailRegistered = !!email2;
36051
- const emailVerified = ((_f = (_e = res.body.unsigned) == null ? void 0 : _e.data) == null ? void 0 : _f.emailStatus) === "VERIFIED";
36410
+ const emailVerified = ((_g = (_f = res.body.unsigned) == null ? void 0 : _f.data) == null ? void 0 : _g.emailStatus) === "VERIFIED";
36052
36411
  if (emailRegistered && emailVerified && !allowsUpdate) {
36053
- (_g = initRegisterEmail2 == null ? void 0 : initRegisterEmail2.success) == null ? void 0 : _g.call(initRegisterEmail2, {
36412
+ (_h = initRegisterEmail2 == null ? void 0 : initRegisterEmail2.success) == null ? void 0 : _h.call(initRegisterEmail2, {
36054
36413
  statusCode: MiniAppStatusType.emailRegistered,
36055
36414
  email: email2
36056
36415
  });
@@ -36097,9 +36456,9 @@ function registerEmail(params, allowsUpdate = false) {
36097
36456
  }
36098
36457
  function registerKyc(params) {
36099
36458
  const newParams = reconstructParams(params);
36100
- execute$4(newParams);
36459
+ execute$5(newParams);
36101
36460
  }
36102
- function execute$4(params) {
36461
+ function execute$5(params) {
36103
36462
  var _a;
36104
36463
  params = __spreadProps(__spreadValues({}, params), {
36105
36464
  type: (params == null ? void 0 : params.type) || "EKYC"
@@ -36137,13 +36496,13 @@ function execute$4(params) {
36137
36496
  }
36138
36497
  async function startMultiFactorAuth(params) {
36139
36498
  const newParams = reconstructParams(params);
36140
- await execute$3(newParams);
36499
+ await execute$4(newParams);
36141
36500
  }
36142
36501
  function validType(params) {
36143
36502
  const authTypes = ["BIOMETRIC"];
36144
36503
  return authTypes.includes(params == null ? void 0 : params.type);
36145
36504
  }
36146
- async function execute$3(params) {
36505
+ async function execute$4(params) {
36147
36506
  var _a, _b, _c, _d, _e, _f, _g, _h, _i;
36148
36507
  if (!validType(params)) {
36149
36508
  return (_a = params == null ? void 0 : params.fail) == null ? void 0 : _a.call(params, { errorCode: MiniAppErrorType.invalidType });
@@ -36173,9 +36532,9 @@ async function execute$3(params) {
36173
36532
  }
36174
36533
  function logout(params) {
36175
36534
  const newParams = reconstructParams(params);
36176
- execute$2(newParams);
36535
+ execute$3(newParams);
36177
36536
  }
36178
- function execute$2(params) {
36537
+ function execute$3(params) {
36179
36538
  var _a, _b;
36180
36539
  try {
36181
36540
  Object.entries(PpLocalStorageKey).forEach(([_, value2]) => {
@@ -36190,9 +36549,9 @@ function execute$2(params) {
36190
36549
  }
36191
36550
  async function verifyMultiFactorAuthResult(params) {
36192
36551
  const newParams = reconstructParams(params);
36193
- await execute$1(newParams);
36552
+ await execute$2(newParams);
36194
36553
  }
36195
- async function execute$1(params) {
36554
+ async function execute$2(params) {
36196
36555
  var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
36197
36556
  const urlParams = new URLSearchParams(window.location.search);
36198
36557
  const sessionId = urlParams == null ? void 0 : urlParams.get("ppSessionId");
@@ -36956,14 +37315,177 @@ function callbackHandler(params, callback) {
36956
37315
  }
36957
37316
  }
36958
37317
  var isVue2 = false;
37318
+ function set(target, key2, val2) {
37319
+ if (Array.isArray(target)) {
37320
+ target.length = Math.max(target.length, key2);
37321
+ target.splice(key2, 1, val2);
37322
+ return val2;
37323
+ }
37324
+ target[key2] = val2;
37325
+ return val2;
37326
+ }
37327
+ function del(target, key2) {
37328
+ if (Array.isArray(target)) {
37329
+ target.splice(key2, 1);
37330
+ return;
37331
+ }
37332
+ delete target[key2];
37333
+ }
37334
+ function getDevtoolsGlobalHook() {
37335
+ return getTarget().__VUE_DEVTOOLS_GLOBAL_HOOK__;
37336
+ }
37337
+ function getTarget() {
37338
+ return typeof navigator !== "undefined" && typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : {};
37339
+ }
37340
+ const isProxyAvailable = typeof Proxy === "function";
37341
+ const HOOK_SETUP = "devtools-plugin:setup";
37342
+ const HOOK_PLUGIN_SETTINGS_SET = "plugin:settings:set";
37343
+ let supported;
37344
+ let perf;
37345
+ function isPerformanceSupported() {
37346
+ var _a;
37347
+ if (supported !== void 0) {
37348
+ return supported;
37349
+ }
37350
+ if (typeof window !== "undefined" && window.performance) {
37351
+ supported = true;
37352
+ perf = window.performance;
37353
+ } else if (typeof global !== "undefined" && ((_a = global.perf_hooks) === null || _a === void 0 ? void 0 : _a.performance)) {
37354
+ supported = true;
37355
+ perf = global.perf_hooks.performance;
37356
+ } else {
37357
+ supported = false;
37358
+ }
37359
+ return supported;
37360
+ }
37361
+ function now() {
37362
+ return isPerformanceSupported() ? perf.now() : Date.now();
37363
+ }
37364
+ class ApiProxy {
37365
+ constructor(plugin, hook) {
37366
+ this.target = null;
37367
+ this.targetQueue = [];
37368
+ this.onQueue = [];
37369
+ this.plugin = plugin;
37370
+ this.hook = hook;
37371
+ const defaultSettings = {};
37372
+ if (plugin.settings) {
37373
+ for (const id in plugin.settings) {
37374
+ const item2 = plugin.settings[id];
37375
+ defaultSettings[id] = item2.defaultValue;
37376
+ }
37377
+ }
37378
+ const localSettingsSaveId = `__vue-devtools-plugin-settings__${plugin.id}`;
37379
+ let currentSettings = Object.assign({}, defaultSettings);
37380
+ try {
37381
+ const raw = localStorage.getItem(localSettingsSaveId);
37382
+ const data2 = JSON.parse(raw);
37383
+ Object.assign(currentSettings, data2);
37384
+ } catch (e) {
37385
+ }
37386
+ this.fallbacks = {
37387
+ getSettings() {
37388
+ return currentSettings;
37389
+ },
37390
+ setSettings(value2) {
37391
+ try {
37392
+ localStorage.setItem(localSettingsSaveId, JSON.stringify(value2));
37393
+ } catch (e) {
37394
+ }
37395
+ currentSettings = value2;
37396
+ },
37397
+ now() {
37398
+ return now();
37399
+ }
37400
+ };
37401
+ if (hook) {
37402
+ hook.on(HOOK_PLUGIN_SETTINGS_SET, (pluginId, value2) => {
37403
+ if (pluginId === this.plugin.id) {
37404
+ this.fallbacks.setSettings(value2);
37405
+ }
37406
+ });
37407
+ }
37408
+ this.proxiedOn = new Proxy({}, {
37409
+ get: (_target, prop) => {
37410
+ if (this.target) {
37411
+ return this.target.on[prop];
37412
+ } else {
37413
+ return (...args) => {
37414
+ this.onQueue.push({
37415
+ method: prop,
37416
+ args
37417
+ });
37418
+ };
37419
+ }
37420
+ }
37421
+ });
37422
+ this.proxiedTarget = new Proxy({}, {
37423
+ get: (_target, prop) => {
37424
+ if (this.target) {
37425
+ return this.target[prop];
37426
+ } else if (prop === "on") {
37427
+ return this.proxiedOn;
37428
+ } else if (Object.keys(this.fallbacks).includes(prop)) {
37429
+ return (...args) => {
37430
+ this.targetQueue.push({
37431
+ method: prop,
37432
+ args,
37433
+ resolve: () => {
37434
+ }
37435
+ });
37436
+ return this.fallbacks[prop](...args);
37437
+ };
37438
+ } else {
37439
+ return (...args) => {
37440
+ return new Promise((resolve2) => {
37441
+ this.targetQueue.push({
37442
+ method: prop,
37443
+ args,
37444
+ resolve: resolve2
37445
+ });
37446
+ });
37447
+ };
37448
+ }
37449
+ }
37450
+ });
37451
+ }
37452
+ async setRealTarget(target) {
37453
+ this.target = target;
37454
+ for (const item2 of this.onQueue) {
37455
+ this.target.on[item2.method](...item2.args);
37456
+ }
37457
+ for (const item2 of this.targetQueue) {
37458
+ item2.resolve(await this.target[item2.method](...item2.args));
37459
+ }
37460
+ }
37461
+ }
37462
+ function setupDevtoolsPlugin(pluginDescriptor, setupFn) {
37463
+ const descriptor = pluginDescriptor;
37464
+ const target = getTarget();
37465
+ const hook = getDevtoolsGlobalHook();
37466
+ const enableProxy = isProxyAvailable && descriptor.enableEarlyProxy;
37467
+ if (hook && (target.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__ || !enableProxy)) {
37468
+ hook.emit(HOOK_SETUP, pluginDescriptor, setupFn);
37469
+ } else {
37470
+ const proxy = enableProxy ? new ApiProxy(descriptor, hook) : null;
37471
+ const list2 = target.__VUE_DEVTOOLS_PLUGINS__ = target.__VUE_DEVTOOLS_PLUGINS__ || [];
37472
+ list2.push({
37473
+ pluginDescriptor: descriptor,
37474
+ setupFn,
37475
+ proxy
37476
+ });
37477
+ if (proxy)
37478
+ setupFn(proxy.proxiedTarget);
37479
+ }
37480
+ }
36959
37481
  /*!
36960
- * pinia v2.0.14
37482
+ * pinia v2.0.18
36961
37483
  * (c) 2022 Eduardo San Martin Morote
36962
37484
  * @license MIT
36963
37485
  */
36964
37486
  let activePinia;
36965
37487
  const setActivePinia = (pinia) => activePinia = pinia;
36966
- const piniaSymbol = Symbol();
37488
+ const piniaSymbol = Symbol("pinia");
36967
37489
  function isPlainObject(o) {
36968
37490
  return o && typeof o === "object" && Object.prototype.toString.call(o) === "[object Object]" && typeof o.toJSON !== "function";
36969
37491
  }
@@ -36973,6 +37495,721 @@ var MutationType;
36973
37495
  MutationType2["patchObject"] = "patch object";
36974
37496
  MutationType2["patchFunction"] = "patch function";
36975
37497
  })(MutationType || (MutationType = {}));
37498
+ const IS_CLIENT = typeof window !== "undefined";
37499
+ const _global = /* @__PURE__ */ (() => typeof window === "object" && window.window === window ? window : typeof self === "object" && self.self === self ? self : typeof global === "object" && global.global === global ? global : typeof globalThis === "object" ? globalThis : { HTMLElement: null })();
37500
+ function bom(blob, { autoBom = false } = {}) {
37501
+ if (autoBom && /^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(blob.type)) {
37502
+ return new Blob([String.fromCharCode(65279), blob], { type: blob.type });
37503
+ }
37504
+ return blob;
37505
+ }
37506
+ function download(url, name2, opts) {
37507
+ const xhr = new XMLHttpRequest();
37508
+ xhr.open("GET", url);
37509
+ xhr.responseType = "blob";
37510
+ xhr.onload = function() {
37511
+ saveAs(xhr.response, name2, opts);
37512
+ };
37513
+ xhr.onerror = function() {
37514
+ console.error("could not download file");
37515
+ };
37516
+ xhr.send();
37517
+ }
37518
+ function corsEnabled(url) {
37519
+ const xhr = new XMLHttpRequest();
37520
+ xhr.open("HEAD", url, false);
37521
+ try {
37522
+ xhr.send();
37523
+ } catch (e) {
37524
+ }
37525
+ return xhr.status >= 200 && xhr.status <= 299;
37526
+ }
37527
+ function click(node) {
37528
+ try {
37529
+ node.dispatchEvent(new MouseEvent("click"));
37530
+ } catch (e) {
37531
+ const evt = document.createEvent("MouseEvents");
37532
+ evt.initMouseEvent("click", true, true, window, 0, 0, 0, 80, 20, false, false, false, false, 0, null);
37533
+ node.dispatchEvent(evt);
37534
+ }
37535
+ }
37536
+ const _navigator = typeof navigator === "object" ? navigator : { userAgent: "" };
37537
+ const isMacOSWebView = /* @__PURE__ */ (() => /Macintosh/.test(_navigator.userAgent) && /AppleWebKit/.test(_navigator.userAgent) && !/Safari/.test(_navigator.userAgent))();
37538
+ const saveAs = !IS_CLIENT ? () => {
37539
+ } : typeof HTMLAnchorElement !== "undefined" && "download" in HTMLAnchorElement.prototype && !isMacOSWebView ? downloadSaveAs : "msSaveOrOpenBlob" in _navigator ? msSaveAs : fileSaverSaveAs;
37540
+ function downloadSaveAs(blob, name2 = "download", opts) {
37541
+ const a = document.createElement("a");
37542
+ a.download = name2;
37543
+ a.rel = "noopener";
37544
+ if (typeof blob === "string") {
37545
+ a.href = blob;
37546
+ if (a.origin !== location.origin) {
37547
+ if (corsEnabled(a.href)) {
37548
+ download(blob, name2, opts);
37549
+ } else {
37550
+ a.target = "_blank";
37551
+ click(a);
37552
+ }
37553
+ } else {
37554
+ click(a);
37555
+ }
37556
+ } else {
37557
+ a.href = URL.createObjectURL(blob);
37558
+ setTimeout(function() {
37559
+ URL.revokeObjectURL(a.href);
37560
+ }, 4e4);
37561
+ setTimeout(function() {
37562
+ click(a);
37563
+ }, 0);
37564
+ }
37565
+ }
37566
+ function msSaveAs(blob, name2 = "download", opts) {
37567
+ if (typeof blob === "string") {
37568
+ if (corsEnabled(blob)) {
37569
+ download(blob, name2, opts);
37570
+ } else {
37571
+ const a = document.createElement("a");
37572
+ a.href = blob;
37573
+ a.target = "_blank";
37574
+ setTimeout(function() {
37575
+ click(a);
37576
+ });
37577
+ }
37578
+ } else {
37579
+ navigator.msSaveOrOpenBlob(bom(blob, opts), name2);
37580
+ }
37581
+ }
37582
+ function fileSaverSaveAs(blob, name2, opts, popup) {
37583
+ popup = popup || open("", "_blank");
37584
+ if (popup) {
37585
+ popup.document.title = popup.document.body.innerText = "downloading...";
37586
+ }
37587
+ if (typeof blob === "string")
37588
+ return download(blob, name2, opts);
37589
+ const force = blob.type === "application/octet-stream";
37590
+ const isSafari2 = /constructor/i.test(String(_global.HTMLElement)) || "safari" in _global;
37591
+ const isChromeIOS = /CriOS\/[\d]+/.test(navigator.userAgent);
37592
+ if ((isChromeIOS || force && isSafari2 || isMacOSWebView) && typeof FileReader !== "undefined") {
37593
+ const reader = new FileReader();
37594
+ reader.onloadend = function() {
37595
+ let url = reader.result;
37596
+ if (typeof url !== "string") {
37597
+ popup = null;
37598
+ throw new Error("Wrong reader.result type");
37599
+ }
37600
+ url = isChromeIOS ? url : url.replace(/^data:[^;]*;/, "data:attachment/file;");
37601
+ if (popup) {
37602
+ popup.location.href = url;
37603
+ } else {
37604
+ location.assign(url);
37605
+ }
37606
+ popup = null;
37607
+ };
37608
+ reader.readAsDataURL(blob);
37609
+ } else {
37610
+ const url = URL.createObjectURL(blob);
37611
+ if (popup)
37612
+ popup.location.assign(url);
37613
+ else
37614
+ location.href = url;
37615
+ popup = null;
37616
+ setTimeout(function() {
37617
+ URL.revokeObjectURL(url);
37618
+ }, 4e4);
37619
+ }
37620
+ }
37621
+ function toastMessage(message, type) {
37622
+ const piniaMessage = "\u{1F34D} " + message;
37623
+ if (typeof __VUE_DEVTOOLS_TOAST__ === "function") {
37624
+ __VUE_DEVTOOLS_TOAST__(piniaMessage, type);
37625
+ } else if (type === "error") {
37626
+ console.error(piniaMessage);
37627
+ } else if (type === "warn") {
37628
+ console.warn(piniaMessage);
37629
+ } else {
37630
+ console.log(piniaMessage);
37631
+ }
37632
+ }
37633
+ function isPinia(o) {
37634
+ return "_a" in o && "install" in o;
37635
+ }
37636
+ function checkClipboardAccess() {
37637
+ if (!("clipboard" in navigator)) {
37638
+ toastMessage(`Your browser doesn't support the Clipboard API`, "error");
37639
+ return true;
37640
+ }
37641
+ }
37642
+ function checkNotFocusedError(error2) {
37643
+ if (error2 instanceof Error && error2.message.toLowerCase().includes("document is not focused")) {
37644
+ toastMessage('You need to activate the "Emulate a focused page" setting in the "Rendering" panel of devtools.', "warn");
37645
+ return true;
37646
+ }
37647
+ return false;
37648
+ }
37649
+ async function actionGlobalCopyState(pinia) {
37650
+ if (checkClipboardAccess())
37651
+ return;
37652
+ try {
37653
+ await navigator.clipboard.writeText(JSON.stringify(pinia.state.value));
37654
+ toastMessage("Global state copied to clipboard.");
37655
+ } catch (error2) {
37656
+ if (checkNotFocusedError(error2))
37657
+ return;
37658
+ toastMessage(`Failed to serialize the state. Check the console for more details.`, "error");
37659
+ console.error(error2);
37660
+ }
37661
+ }
37662
+ async function actionGlobalPasteState(pinia) {
37663
+ if (checkClipboardAccess())
37664
+ return;
37665
+ try {
37666
+ pinia.state.value = JSON.parse(await navigator.clipboard.readText());
37667
+ toastMessage("Global state pasted from clipboard.");
37668
+ } catch (error2) {
37669
+ if (checkNotFocusedError(error2))
37670
+ return;
37671
+ toastMessage(`Failed to deserialize the state from clipboard. Check the console for more details.`, "error");
37672
+ console.error(error2);
37673
+ }
37674
+ }
37675
+ async function actionGlobalSaveState(pinia) {
37676
+ try {
37677
+ saveAs(new Blob([JSON.stringify(pinia.state.value)], {
37678
+ type: "text/plain;charset=utf-8"
37679
+ }), "pinia-state.json");
37680
+ } catch (error2) {
37681
+ toastMessage(`Failed to export the state as JSON. Check the console for more details.`, "error");
37682
+ console.error(error2);
37683
+ }
37684
+ }
37685
+ let fileInput;
37686
+ function getFileOpener() {
37687
+ if (!fileInput) {
37688
+ fileInput = document.createElement("input");
37689
+ fileInput.type = "file";
37690
+ fileInput.accept = ".json";
37691
+ }
37692
+ function openFile() {
37693
+ return new Promise((resolve2, reject) => {
37694
+ fileInput.onchange = async () => {
37695
+ const files = fileInput.files;
37696
+ if (!files)
37697
+ return resolve2(null);
37698
+ const file = files.item(0);
37699
+ if (!file)
37700
+ return resolve2(null);
37701
+ return resolve2({ text: await file.text(), file });
37702
+ };
37703
+ fileInput.oncancel = () => resolve2(null);
37704
+ fileInput.onerror = reject;
37705
+ fileInput.click();
37706
+ });
37707
+ }
37708
+ return openFile;
37709
+ }
37710
+ async function actionGlobalOpenStateFile(pinia) {
37711
+ try {
37712
+ const open2 = await getFileOpener();
37713
+ const result2 = await open2();
37714
+ if (!result2)
37715
+ return;
37716
+ const { text: text2, file } = result2;
37717
+ pinia.state.value = JSON.parse(text2);
37718
+ toastMessage(`Global state imported from "${file.name}".`);
37719
+ } catch (error2) {
37720
+ toastMessage(`Failed to export the state as JSON. Check the console for more details.`, "error");
37721
+ console.error(error2);
37722
+ }
37723
+ }
37724
+ function formatDisplay(display) {
37725
+ return {
37726
+ _custom: {
37727
+ display
37728
+ }
37729
+ };
37730
+ }
37731
+ const PINIA_ROOT_LABEL = "\u{1F34D} Pinia (root)";
37732
+ const PINIA_ROOT_ID = "_root";
37733
+ function formatStoreForInspectorTree(store) {
37734
+ return isPinia(store) ? {
37735
+ id: PINIA_ROOT_ID,
37736
+ label: PINIA_ROOT_LABEL
37737
+ } : {
37738
+ id: store.$id,
37739
+ label: store.$id
37740
+ };
37741
+ }
37742
+ function formatStoreForInspectorState(store) {
37743
+ if (isPinia(store)) {
37744
+ const storeNames = Array.from(store._s.keys());
37745
+ const storeMap = store._s;
37746
+ const state2 = {
37747
+ state: storeNames.map((storeId) => ({
37748
+ editable: true,
37749
+ key: storeId,
37750
+ value: store.state.value[storeId]
37751
+ })),
37752
+ getters: storeNames.filter((id) => storeMap.get(id)._getters).map((id) => {
37753
+ const store2 = storeMap.get(id);
37754
+ return {
37755
+ editable: false,
37756
+ key: id,
37757
+ value: store2._getters.reduce((getters, key2) => {
37758
+ getters[key2] = store2[key2];
37759
+ return getters;
37760
+ }, {})
37761
+ };
37762
+ })
37763
+ };
37764
+ return state2;
37765
+ }
37766
+ const state = {
37767
+ state: Object.keys(store.$state).map((key2) => ({
37768
+ editable: true,
37769
+ key: key2,
37770
+ value: store.$state[key2]
37771
+ }))
37772
+ };
37773
+ if (store._getters && store._getters.length) {
37774
+ state.getters = store._getters.map((getterName) => ({
37775
+ editable: false,
37776
+ key: getterName,
37777
+ value: store[getterName]
37778
+ }));
37779
+ }
37780
+ if (store._customProperties.size) {
37781
+ state.customProperties = Array.from(store._customProperties).map((key2) => ({
37782
+ editable: true,
37783
+ key: key2,
37784
+ value: store[key2]
37785
+ }));
37786
+ }
37787
+ return state;
37788
+ }
37789
+ function formatEventData(events) {
37790
+ if (!events)
37791
+ return {};
37792
+ if (Array.isArray(events)) {
37793
+ return events.reduce((data2, event) => {
37794
+ data2.keys.push(event.key);
37795
+ data2.operations.push(event.type);
37796
+ data2.oldValue[event.key] = event.oldValue;
37797
+ data2.newValue[event.key] = event.newValue;
37798
+ return data2;
37799
+ }, {
37800
+ oldValue: {},
37801
+ keys: [],
37802
+ operations: [],
37803
+ newValue: {}
37804
+ });
37805
+ } else {
37806
+ return {
37807
+ operation: formatDisplay(events.type),
37808
+ key: formatDisplay(events.key),
37809
+ oldValue: events.oldValue,
37810
+ newValue: events.newValue
37811
+ };
37812
+ }
37813
+ }
37814
+ function formatMutationType(type) {
37815
+ switch (type) {
37816
+ case MutationType.direct:
37817
+ return "mutation";
37818
+ case MutationType.patchFunction:
37819
+ return "$patch";
37820
+ case MutationType.patchObject:
37821
+ return "$patch";
37822
+ default:
37823
+ return "unknown";
37824
+ }
37825
+ }
37826
+ let isTimelineActive = true;
37827
+ const componentStateTypes = [];
37828
+ const MUTATIONS_LAYER_ID = "pinia:mutations";
37829
+ const INSPECTOR_ID = "pinia";
37830
+ const getStoreType = (id) => "\u{1F34D} " + id;
37831
+ function registerPiniaDevtools(app, pinia) {
37832
+ setupDevtoolsPlugin({
37833
+ id: "dev.esm.pinia",
37834
+ label: "Pinia \u{1F34D}",
37835
+ logo: "https://pinia.vuejs.org/logo.svg",
37836
+ packageName: "pinia",
37837
+ homepage: "https://pinia.vuejs.org",
37838
+ componentStateTypes,
37839
+ app
37840
+ }, (api2) => {
37841
+ if (typeof api2.now !== "function") {
37842
+ toastMessage("You seem to be using an outdated version of Vue Devtools. Are you still using the Beta release instead of the stable one? You can find the links at https://devtools.vuejs.org/guide/installation.html.");
37843
+ }
37844
+ api2.addTimelineLayer({
37845
+ id: MUTATIONS_LAYER_ID,
37846
+ label: `Pinia \u{1F34D}`,
37847
+ color: 15064968
37848
+ });
37849
+ api2.addInspector({
37850
+ id: INSPECTOR_ID,
37851
+ label: "Pinia \u{1F34D}",
37852
+ icon: "storage",
37853
+ treeFilterPlaceholder: "Search stores",
37854
+ actions: [
37855
+ {
37856
+ icon: "content_copy",
37857
+ action: () => {
37858
+ actionGlobalCopyState(pinia);
37859
+ },
37860
+ tooltip: "Serialize and copy the state"
37861
+ },
37862
+ {
37863
+ icon: "content_paste",
37864
+ action: async () => {
37865
+ await actionGlobalPasteState(pinia);
37866
+ api2.sendInspectorTree(INSPECTOR_ID);
37867
+ api2.sendInspectorState(INSPECTOR_ID);
37868
+ },
37869
+ tooltip: "Replace the state with the content of your clipboard"
37870
+ },
37871
+ {
37872
+ icon: "save",
37873
+ action: () => {
37874
+ actionGlobalSaveState(pinia);
37875
+ },
37876
+ tooltip: "Save the state as a JSON file"
37877
+ },
37878
+ {
37879
+ icon: "folder_open",
37880
+ action: async () => {
37881
+ await actionGlobalOpenStateFile(pinia);
37882
+ api2.sendInspectorTree(INSPECTOR_ID);
37883
+ api2.sendInspectorState(INSPECTOR_ID);
37884
+ },
37885
+ tooltip: "Import the state from a JSON file"
37886
+ }
37887
+ ],
37888
+ nodeActions: [
37889
+ {
37890
+ icon: "restore",
37891
+ tooltip: "Reset the state (option store only)",
37892
+ action: (nodeId) => {
37893
+ const store = pinia._s.get(nodeId);
37894
+ if (!store) {
37895
+ toastMessage(`Cannot reset "${nodeId}" store because it wasn't found.`, "warn");
37896
+ } else if (!store._isOptionsAPI) {
37897
+ toastMessage(`Cannot reset "${nodeId}" store because it's a setup store.`, "warn");
37898
+ } else {
37899
+ store.$reset();
37900
+ toastMessage(`Store "${nodeId}" reset.`);
37901
+ }
37902
+ }
37903
+ }
37904
+ ]
37905
+ });
37906
+ api2.on.inspectComponent((payload, ctx) => {
37907
+ const proxy = payload.componentInstance && payload.componentInstance.proxy;
37908
+ if (proxy && proxy._pStores) {
37909
+ const piniaStores = payload.componentInstance.proxy._pStores;
37910
+ Object.values(piniaStores).forEach((store) => {
37911
+ payload.instanceData.state.push({
37912
+ type: getStoreType(store.$id),
37913
+ key: "state",
37914
+ editable: true,
37915
+ value: store._isOptionsAPI ? {
37916
+ _custom: {
37917
+ value: toRaw(store.$state),
37918
+ actions: [
37919
+ {
37920
+ icon: "restore",
37921
+ tooltip: "Reset the state of this store",
37922
+ action: () => store.$reset()
37923
+ }
37924
+ ]
37925
+ }
37926
+ } : Object.keys(store.$state).reduce((state, key2) => {
37927
+ state[key2] = store.$state[key2];
37928
+ return state;
37929
+ }, {})
37930
+ });
37931
+ if (store._getters && store._getters.length) {
37932
+ payload.instanceData.state.push({
37933
+ type: getStoreType(store.$id),
37934
+ key: "getters",
37935
+ editable: false,
37936
+ value: store._getters.reduce((getters, key2) => {
37937
+ try {
37938
+ getters[key2] = store[key2];
37939
+ } catch (error2) {
37940
+ getters[key2] = error2;
37941
+ }
37942
+ return getters;
37943
+ }, {})
37944
+ });
37945
+ }
37946
+ });
37947
+ }
37948
+ });
37949
+ api2.on.getInspectorTree((payload) => {
37950
+ if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {
37951
+ let stores = [pinia];
37952
+ stores = stores.concat(Array.from(pinia._s.values()));
37953
+ payload.rootNodes = (payload.filter ? stores.filter((store) => "$id" in store ? store.$id.toLowerCase().includes(payload.filter.toLowerCase()) : PINIA_ROOT_LABEL.toLowerCase().includes(payload.filter.toLowerCase())) : stores).map(formatStoreForInspectorTree);
37954
+ }
37955
+ });
37956
+ api2.on.getInspectorState((payload) => {
37957
+ if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {
37958
+ const inspectedStore = payload.nodeId === PINIA_ROOT_ID ? pinia : pinia._s.get(payload.nodeId);
37959
+ if (!inspectedStore) {
37960
+ return;
37961
+ }
37962
+ if (inspectedStore) {
37963
+ payload.state = formatStoreForInspectorState(inspectedStore);
37964
+ }
37965
+ }
37966
+ });
37967
+ api2.on.editInspectorState((payload, ctx) => {
37968
+ if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {
37969
+ const inspectedStore = payload.nodeId === PINIA_ROOT_ID ? pinia : pinia._s.get(payload.nodeId);
37970
+ if (!inspectedStore) {
37971
+ return toastMessage(`store "${payload.nodeId}" not found`, "error");
37972
+ }
37973
+ const { path } = payload;
37974
+ if (!isPinia(inspectedStore)) {
37975
+ if (path.length !== 1 || !inspectedStore._customProperties.has(path[0]) || path[0] in inspectedStore.$state) {
37976
+ path.unshift("$state");
37977
+ }
37978
+ } else {
37979
+ path.unshift("state");
37980
+ }
37981
+ isTimelineActive = false;
37982
+ payload.set(inspectedStore, path, payload.state.value);
37983
+ isTimelineActive = true;
37984
+ }
37985
+ });
37986
+ api2.on.editComponentState((payload) => {
37987
+ if (payload.type.startsWith("\u{1F34D}")) {
37988
+ const storeId = payload.type.replace(/^🍍\s*/, "");
37989
+ const store = pinia._s.get(storeId);
37990
+ if (!store) {
37991
+ return toastMessage(`store "${storeId}" not found`, "error");
37992
+ }
37993
+ const { path } = payload;
37994
+ if (path[0] !== "state") {
37995
+ return toastMessage(`Invalid path for store "${storeId}":
37996
+ ${path}
37997
+ Only state can be modified.`);
37998
+ }
37999
+ path[0] = "$state";
38000
+ isTimelineActive = false;
38001
+ payload.set(store, path, payload.state.value);
38002
+ isTimelineActive = true;
38003
+ }
38004
+ });
38005
+ });
38006
+ }
38007
+ function addStoreToDevtools(app, store) {
38008
+ if (!componentStateTypes.includes(getStoreType(store.$id))) {
38009
+ componentStateTypes.push(getStoreType(store.$id));
38010
+ }
38011
+ setupDevtoolsPlugin({
38012
+ id: "dev.esm.pinia",
38013
+ label: "Pinia \u{1F34D}",
38014
+ logo: "https://pinia.vuejs.org/logo.svg",
38015
+ packageName: "pinia",
38016
+ homepage: "https://pinia.vuejs.org",
38017
+ componentStateTypes,
38018
+ app,
38019
+ settings: {
38020
+ logStoreChanges: {
38021
+ label: "Notify about new/deleted stores",
38022
+ type: "boolean",
38023
+ defaultValue: true
38024
+ }
38025
+ }
38026
+ }, (api2) => {
38027
+ const now2 = typeof api2.now === "function" ? api2.now.bind(api2) : Date.now;
38028
+ store.$onAction(({ after, onError, name: name2, args }) => {
38029
+ const groupId = runningActionId++;
38030
+ api2.addTimelineEvent({
38031
+ layerId: MUTATIONS_LAYER_ID,
38032
+ event: {
38033
+ time: now2(),
38034
+ title: "\u{1F6EB} " + name2,
38035
+ subtitle: "start",
38036
+ data: {
38037
+ store: formatDisplay(store.$id),
38038
+ action: formatDisplay(name2),
38039
+ args
38040
+ },
38041
+ groupId
38042
+ }
38043
+ });
38044
+ after((result2) => {
38045
+ activeAction = void 0;
38046
+ api2.addTimelineEvent({
38047
+ layerId: MUTATIONS_LAYER_ID,
38048
+ event: {
38049
+ time: now2(),
38050
+ title: "\u{1F6EC} " + name2,
38051
+ subtitle: "end",
38052
+ data: {
38053
+ store: formatDisplay(store.$id),
38054
+ action: formatDisplay(name2),
38055
+ args,
38056
+ result: result2
38057
+ },
38058
+ groupId
38059
+ }
38060
+ });
38061
+ });
38062
+ onError((error2) => {
38063
+ activeAction = void 0;
38064
+ api2.addTimelineEvent({
38065
+ layerId: MUTATIONS_LAYER_ID,
38066
+ event: {
38067
+ time: now2(),
38068
+ logType: "error",
38069
+ title: "\u{1F4A5} " + name2,
38070
+ subtitle: "end",
38071
+ data: {
38072
+ store: formatDisplay(store.$id),
38073
+ action: formatDisplay(name2),
38074
+ args,
38075
+ error: error2
38076
+ },
38077
+ groupId
38078
+ }
38079
+ });
38080
+ });
38081
+ }, true);
38082
+ store._customProperties.forEach((name2) => {
38083
+ watch(() => unref(store[name2]), (newValue, oldValue) => {
38084
+ api2.notifyComponentUpdate();
38085
+ api2.sendInspectorState(INSPECTOR_ID);
38086
+ if (isTimelineActive) {
38087
+ api2.addTimelineEvent({
38088
+ layerId: MUTATIONS_LAYER_ID,
38089
+ event: {
38090
+ time: now2(),
38091
+ title: "Change",
38092
+ subtitle: name2,
38093
+ data: {
38094
+ newValue,
38095
+ oldValue
38096
+ },
38097
+ groupId: activeAction
38098
+ }
38099
+ });
38100
+ }
38101
+ }, { deep: true });
38102
+ });
38103
+ store.$subscribe(({ events, type }, state) => {
38104
+ api2.notifyComponentUpdate();
38105
+ api2.sendInspectorState(INSPECTOR_ID);
38106
+ if (!isTimelineActive)
38107
+ return;
38108
+ const eventData = {
38109
+ time: now2(),
38110
+ title: formatMutationType(type),
38111
+ data: __spreadValues({
38112
+ store: formatDisplay(store.$id)
38113
+ }, formatEventData(events)),
38114
+ groupId: activeAction
38115
+ };
38116
+ activeAction = void 0;
38117
+ if (type === MutationType.patchFunction) {
38118
+ eventData.subtitle = "\u2935\uFE0F";
38119
+ } else if (type === MutationType.patchObject) {
38120
+ eventData.subtitle = "\u{1F9E9}";
38121
+ } else if (events && !Array.isArray(events)) {
38122
+ eventData.subtitle = events.type;
38123
+ }
38124
+ if (events) {
38125
+ eventData.data["rawEvent(s)"] = {
38126
+ _custom: {
38127
+ display: "DebuggerEvent",
38128
+ type: "object",
38129
+ tooltip: "raw DebuggerEvent[]",
38130
+ value: events
38131
+ }
38132
+ };
38133
+ }
38134
+ api2.addTimelineEvent({
38135
+ layerId: MUTATIONS_LAYER_ID,
38136
+ event: eventData
38137
+ });
38138
+ }, { detached: true, flush: "sync" });
38139
+ const hotUpdate = store._hotUpdate;
38140
+ store._hotUpdate = markRaw((newStore) => {
38141
+ hotUpdate(newStore);
38142
+ api2.addTimelineEvent({
38143
+ layerId: MUTATIONS_LAYER_ID,
38144
+ event: {
38145
+ time: now2(),
38146
+ title: "\u{1F525} " + store.$id,
38147
+ subtitle: "HMR update",
38148
+ data: {
38149
+ store: formatDisplay(store.$id),
38150
+ info: formatDisplay(`HMR update`)
38151
+ }
38152
+ }
38153
+ });
38154
+ api2.notifyComponentUpdate();
38155
+ api2.sendInspectorTree(INSPECTOR_ID);
38156
+ api2.sendInspectorState(INSPECTOR_ID);
38157
+ });
38158
+ const { $dispose } = store;
38159
+ store.$dispose = () => {
38160
+ $dispose();
38161
+ api2.notifyComponentUpdate();
38162
+ api2.sendInspectorTree(INSPECTOR_ID);
38163
+ api2.sendInspectorState(INSPECTOR_ID);
38164
+ api2.getSettings().logStoreChanges && toastMessage(`Disposed "${store.$id}" store \u{1F5D1}`);
38165
+ };
38166
+ api2.notifyComponentUpdate();
38167
+ api2.sendInspectorTree(INSPECTOR_ID);
38168
+ api2.sendInspectorState(INSPECTOR_ID);
38169
+ api2.getSettings().logStoreChanges && toastMessage(`"${store.$id}" store installed \u{1F195}`);
38170
+ });
38171
+ }
38172
+ let runningActionId = 0;
38173
+ let activeAction;
38174
+ function patchActionForGrouping(store, actionNames) {
38175
+ const actions = actionNames.reduce((storeActions, actionName) => {
38176
+ storeActions[actionName] = toRaw(store)[actionName];
38177
+ return storeActions;
38178
+ }, {});
38179
+ for (const actionName in actions) {
38180
+ store[actionName] = function() {
38181
+ const _actionId = runningActionId;
38182
+ const trackedStore = new Proxy(store, {
38183
+ get(...args) {
38184
+ activeAction = _actionId;
38185
+ return Reflect.get(...args);
38186
+ },
38187
+ set(...args) {
38188
+ activeAction = _actionId;
38189
+ return Reflect.set(...args);
38190
+ }
38191
+ });
38192
+ return actions[actionName].apply(trackedStore, arguments);
38193
+ };
38194
+ }
38195
+ }
38196
+ function devtoolsPlugin({ app, store, options }) {
38197
+ if (store.$id.startsWith("__hot:")) {
38198
+ return;
38199
+ }
38200
+ if (options.state) {
38201
+ store._isOptionsAPI = true;
38202
+ }
38203
+ if (typeof options.state === "function") {
38204
+ patchActionForGrouping(store, Object.keys(options.actions));
38205
+ const originalHotUpdate = store._hotUpdate;
38206
+ toRaw(store)._hotUpdate = function(newStore) {
38207
+ originalHotUpdate.apply(this, arguments);
38208
+ patchActionForGrouping(store, Object.keys(newStore._hmrPayload.actions));
38209
+ };
38210
+ }
38211
+ addStoreToDevtools(app, store);
38212
+ }
36976
38213
  function createPinia() {
36977
38214
  const scope = effectScope(true);
36978
38215
  const state = scope.run(() => ref({}));
@@ -36985,6 +38222,9 @@ function createPinia() {
36985
38222
  pinia._a = app;
36986
38223
  app.provide(piniaSymbol, pinia);
36987
38224
  app.config.globalProperties.$pinia = pinia;
38225
+ if (IS_CLIENT) {
38226
+ registerPiniaDevtools(app, pinia);
38227
+ }
36988
38228
  toBeInstalled.forEach((plugin) => _p.push(plugin));
36989
38229
  toBeInstalled = [];
36990
38230
  }
@@ -37003,8 +38243,28 @@ function createPinia() {
37003
38243
  _s: new Map(),
37004
38244
  state
37005
38245
  });
38246
+ if (IS_CLIENT && true && typeof Proxy !== "undefined") {
38247
+ pinia.use(devtoolsPlugin);
38248
+ }
37006
38249
  return pinia;
37007
38250
  }
38251
+ function patchObject(newState, oldState) {
38252
+ for (const key2 in oldState) {
38253
+ const subPatch = oldState[key2];
38254
+ if (!(key2 in newState)) {
38255
+ continue;
38256
+ }
38257
+ const targetValue = newState[key2];
38258
+ if (isPlainObject(targetValue) && isPlainObject(subPatch) && !isRef(subPatch) && !isReactive(subPatch)) {
38259
+ newState[key2] = patchObject(targetValue, subPatch);
38260
+ } else {
38261
+ {
38262
+ newState[key2] = subPatch;
38263
+ }
38264
+ }
38265
+ }
38266
+ return newState;
38267
+ }
37008
38268
  const noop = () => {
37009
38269
  };
37010
38270
  function addSubscription(subscriptions, callback, detached, onCleanup = noop) {
@@ -37040,7 +38300,7 @@ function mergeReactiveObjects(target, patchToApply) {
37040
38300
  }
37041
38301
  return target;
37042
38302
  }
37043
- const skipHydrateSymbol = Symbol();
38303
+ const skipHydrateSymbol = Symbol("pinia:skipHydration");
37044
38304
  function shouldHydrate(obj) {
37045
38305
  return !isPlainObject(obj) || !obj.hasOwnProperty(skipHydrateSymbol);
37046
38306
  }
@@ -37053,13 +38313,16 @@ function createOptionsStore(id, options, pinia, hot) {
37053
38313
  const initialState2 = pinia.state.value[id];
37054
38314
  let store;
37055
38315
  function setup() {
37056
- if (!initialState2 && true) {
38316
+ if (!initialState2 && !hot) {
37057
38317
  {
37058
38318
  pinia.state.value[id] = state ? state() : {};
37059
38319
  }
37060
38320
  }
37061
- const localState = toRefs(pinia.state.value[id]);
38321
+ const localState = hot ? toRefs(ref(state ? state() : {}).value) : toRefs(pinia.state.value[id]);
37062
38322
  return assign(localState, actions, Object.keys(getters || {}).reduce((computedGetters, name2) => {
38323
+ if (name2 in localState) {
38324
+ console.warn(`[\u{1F34D}]: A getter cannot have the same name as another state property. Rename one of them. Found with "${name2}" in store "${id}".`);
38325
+ }
37063
38326
  computedGetters[name2] = markRaw(computed(() => {
37064
38327
  setActivePinia(pinia);
37065
38328
  const store2 = pinia._s.get(id);
@@ -37080,25 +38343,44 @@ function createOptionsStore(id, options, pinia, hot) {
37080
38343
  function createSetupStore($id, setup, options = {}, pinia, hot, isOptionsStore) {
37081
38344
  let scope;
37082
38345
  const optionsForPlugin = assign({ actions: {} }, options);
38346
+ if (!pinia._e.active) {
38347
+ throw new Error("Pinia destroyed");
38348
+ }
37083
38349
  const $subscribeOptions = {
37084
38350
  deep: true
37085
38351
  };
38352
+ {
38353
+ $subscribeOptions.onTrigger = (event) => {
38354
+ if (isListening) {
38355
+ debuggerEvents = event;
38356
+ } else if (isListening == false && !store._hotUpdating) {
38357
+ if (Array.isArray(debuggerEvents)) {
38358
+ debuggerEvents.push(event);
38359
+ } else {
38360
+ console.error("\u{1F34D} debuggerEvents should be an array. This is most likely an internal Pinia bug.");
38361
+ }
38362
+ }
38363
+ };
38364
+ }
37086
38365
  let isListening;
37087
38366
  let isSyncListening;
37088
38367
  let subscriptions = markRaw([]);
37089
38368
  let actionSubscriptions = markRaw([]);
37090
38369
  let debuggerEvents;
37091
38370
  const initialState2 = pinia.state.value[$id];
37092
- if (!isOptionsStore && !initialState2 && true) {
38371
+ if (!isOptionsStore && !initialState2 && !hot) {
37093
38372
  {
37094
38373
  pinia.state.value[$id] = {};
37095
38374
  }
37096
38375
  }
37097
- ref({});
38376
+ const hotState = ref({});
37098
38377
  let activeListener;
37099
38378
  function $patch(partialStateOrMutator) {
37100
38379
  let subscriptionMutation;
37101
38380
  isListening = isSyncListening = false;
38381
+ {
38382
+ debuggerEvents = [];
38383
+ }
37102
38384
  if (typeof partialStateOrMutator === "function") {
37103
38385
  partialStateOrMutator(pinia.state.value[$id]);
37104
38386
  subscriptionMutation = {
@@ -37124,7 +38406,9 @@ function createSetupStore($id, setup, options = {}, pinia, hot, isOptionsStore)
37124
38406
  isSyncListening = true;
37125
38407
  triggerSubscriptions(subscriptions, subscriptionMutation, pinia.state.value[$id]);
37126
38408
  }
37127
- const $reset = noop;
38409
+ const $reset = () => {
38410
+ throw new Error(`\u{1F34D}: Store "${$id}" is built using the setup syntax and does not implement $reset().`);
38411
+ };
37128
38412
  function $dispose() {
37129
38413
  scope.stop();
37130
38414
  subscriptions = [];
@@ -37170,6 +38454,12 @@ function createSetupStore($id, setup, options = {}, pinia, hot, isOptionsStore)
37170
38454
  return ret;
37171
38455
  };
37172
38456
  }
38457
+ const _hmrPayload = /* @__PURE__ */ markRaw({
38458
+ actions: {},
38459
+ getters: {},
38460
+ state: [],
38461
+ hotState
38462
+ });
37173
38463
  const partialStore = {
37174
38464
  _p: pinia,
37175
38465
  $id,
@@ -37191,7 +38481,10 @@ function createSetupStore($id, setup, options = {}, pinia, hot, isOptionsStore)
37191
38481
  },
37192
38482
  $dispose
37193
38483
  };
37194
- const store = reactive(assign({}, partialStore));
38484
+ const store = reactive(assign(IS_CLIENT ? {
38485
+ _customProperties: markRaw(new Set()),
38486
+ _hmrPayload
38487
+ } : {}, partialStore));
37195
38488
  pinia._s.set($id, store);
37196
38489
  const setupStore = pinia._e.run(() => {
37197
38490
  scope = effectScope();
@@ -37200,7 +38493,9 @@ function createSetupStore($id, setup, options = {}, pinia, hot, isOptionsStore)
37200
38493
  for (const key2 in setupStore) {
37201
38494
  const prop = setupStore[key2];
37202
38495
  if (isRef(prop) && !isComputed(prop) || isReactive(prop)) {
37203
- if (!isOptionsStore) {
38496
+ if (hot) {
38497
+ set(hotState.value, key2, toRef(setupStore, key2));
38498
+ } else if (!isOptionsStore) {
37204
38499
  if (initialState2 && shouldHydrate(prop)) {
37205
38500
  if (isRef(prop)) {
37206
38501
  prop.value = initialState2[key2];
@@ -37212,29 +38507,120 @@ function createSetupStore($id, setup, options = {}, pinia, hot, isOptionsStore)
37212
38507
  pinia.state.value[$id][key2] = prop;
37213
38508
  }
37214
38509
  }
38510
+ {
38511
+ _hmrPayload.state.push(key2);
38512
+ }
37215
38513
  } else if (typeof prop === "function") {
37216
- const actionValue = wrapAction(key2, prop);
38514
+ const actionValue = hot ? prop : wrapAction(key2, prop);
37217
38515
  {
37218
38516
  setupStore[key2] = actionValue;
37219
38517
  }
38518
+ {
38519
+ _hmrPayload.actions[key2] = prop;
38520
+ }
37220
38521
  optionsForPlugin.actions[key2] = prop;
37221
- } else
37222
- ;
38522
+ } else {
38523
+ if (isComputed(prop)) {
38524
+ _hmrPayload.getters[key2] = isOptionsStore ? options.getters[key2] : prop;
38525
+ if (IS_CLIENT) {
38526
+ const getters = setupStore._getters || (setupStore._getters = markRaw([]));
38527
+ getters.push(key2);
38528
+ }
38529
+ }
38530
+ }
37223
38531
  }
37224
38532
  {
37225
38533
  assign(store, setupStore);
37226
38534
  assign(toRaw(store), setupStore);
37227
38535
  }
37228
38536
  Object.defineProperty(store, "$state", {
37229
- get: () => pinia.state.value[$id],
38537
+ get: () => hot ? hotState.value : pinia.state.value[$id],
37230
38538
  set: (state) => {
38539
+ if (hot) {
38540
+ throw new Error("cannot set hotState");
38541
+ }
37231
38542
  $patch(($state) => {
37232
38543
  assign($state, state);
37233
38544
  });
37234
38545
  }
37235
38546
  });
38547
+ {
38548
+ store._hotUpdate = markRaw((newStore) => {
38549
+ store._hotUpdating = true;
38550
+ newStore._hmrPayload.state.forEach((stateKey) => {
38551
+ if (stateKey in store.$state) {
38552
+ const newStateTarget = newStore.$state[stateKey];
38553
+ const oldStateSource = store.$state[stateKey];
38554
+ if (typeof newStateTarget === "object" && isPlainObject(newStateTarget) && isPlainObject(oldStateSource)) {
38555
+ patchObject(newStateTarget, oldStateSource);
38556
+ } else {
38557
+ newStore.$state[stateKey] = oldStateSource;
38558
+ }
38559
+ }
38560
+ set(store, stateKey, toRef(newStore.$state, stateKey));
38561
+ });
38562
+ Object.keys(store.$state).forEach((stateKey) => {
38563
+ if (!(stateKey in newStore.$state)) {
38564
+ del(store, stateKey);
38565
+ }
38566
+ });
38567
+ isListening = false;
38568
+ isSyncListening = false;
38569
+ pinia.state.value[$id] = toRef(newStore._hmrPayload, "hotState");
38570
+ isSyncListening = true;
38571
+ nextTick().then(() => {
38572
+ isListening = true;
38573
+ });
38574
+ for (const actionName in newStore._hmrPayload.actions) {
38575
+ const action = newStore[actionName];
38576
+ set(store, actionName, wrapAction(actionName, action));
38577
+ }
38578
+ for (const getterName in newStore._hmrPayload.getters) {
38579
+ const getter = newStore._hmrPayload.getters[getterName];
38580
+ const getterValue = isOptionsStore ? computed(() => {
38581
+ setActivePinia(pinia);
38582
+ return getter.call(store, store);
38583
+ }) : getter;
38584
+ set(store, getterName, getterValue);
38585
+ }
38586
+ Object.keys(store._hmrPayload.getters).forEach((key2) => {
38587
+ if (!(key2 in newStore._hmrPayload.getters)) {
38588
+ del(store, key2);
38589
+ }
38590
+ });
38591
+ Object.keys(store._hmrPayload.actions).forEach((key2) => {
38592
+ if (!(key2 in newStore._hmrPayload.actions)) {
38593
+ del(store, key2);
38594
+ }
38595
+ });
38596
+ store._hmrPayload = newStore._hmrPayload;
38597
+ store._getters = newStore._getters;
38598
+ store._hotUpdating = false;
38599
+ });
38600
+ const nonEnumerable = {
38601
+ writable: true,
38602
+ configurable: true,
38603
+ enumerable: false
38604
+ };
38605
+ if (IS_CLIENT) {
38606
+ ["_p", "_hmrPayload", "_getters", "_customProperties"].forEach((p2) => {
38607
+ Object.defineProperty(store, p2, __spreadValues({
38608
+ value: store[p2]
38609
+ }, nonEnumerable));
38610
+ });
38611
+ }
38612
+ }
37236
38613
  pinia._p.forEach((extender) => {
37237
- {
38614
+ if (IS_CLIENT) {
38615
+ const extensions = scope.run(() => extender({
38616
+ store,
38617
+ app: pinia._a,
38618
+ pinia,
38619
+ options: optionsForPlugin
38620
+ }));
38621
+ Object.keys(extensions || {}).forEach((key2) => store._customProperties.add(key2));
38622
+ assign(store, extensions);
38623
+ } else {
37238
38624
  assign(store, scope.run(() => extender({
37239
38625
  store,
37240
38626
  app: pinia._a,
@@ -37243,6 +38629,11 @@ function createSetupStore($id, setup, options = {}, pinia, hot, isOptionsStore)
37243
38629
  })));
37244
38630
  }
37245
38631
  });
38632
+ if (store.$state && typeof store.$state === "object" && typeof store.$state.constructor === "function" && !store.$state.constructor.toString().includes("[native code]")) {
38633
+ console.warn(`[\u{1F34D}]: The "state" must be a plain object. It cannot be
38634
+ state: () => new MyClass()
38635
+ Found in store "${store.$id}".`);
38636
+ }
37246
38637
  if (initialState2 && isOptionsStore && options.hydrate) {
37247
38638
  options.hydrate(store.$state, initialState2);
37248
38639
  }
@@ -37266,6 +38657,12 @@ function defineStore(idOrOptions, setup, setupOptions) {
37266
38657
  pinia = pinia || currentInstance2 && inject(piniaSymbol);
37267
38658
  if (pinia)
37268
38659
  setActivePinia(pinia);
38660
+ if (!activePinia) {
38661
+ throw new Error(`[\u{1F34D}]: getActivePinia was called with no active Pinia. Did you forget to install pinia?
38662
+ const pinia = createPinia()
38663
+ app.use(pinia)
38664
+ This will fail in production.`);
38665
+ }
37269
38666
  pinia = activePinia;
37270
38667
  if (!pinia._s.has(id)) {
37271
38668
  if (isSetupStore) {
@@ -37273,8 +38670,23 @@ function defineStore(idOrOptions, setup, setupOptions) {
37273
38670
  } else {
37274
38671
  createOptionsStore(id, options, pinia);
37275
38672
  }
38673
+ {
38674
+ useStore._pinia = pinia;
38675
+ }
37276
38676
  }
37277
38677
  const store = pinia._s.get(id);
38678
+ if (hot) {
38679
+ const hotId = "__hot:" + id;
38680
+ const newStore = isSetupStore ? createSetupStore(hotId, setup, options, pinia, true) : createOptionsStore(hotId, assign({}, options), pinia, true);
38681
+ hot._hotUpdate(newStore);
38682
+ delete pinia.state.value[hotId];
38683
+ pinia._s.delete(hotId);
38684
+ }
38685
+ if (IS_CLIENT && currentInstance2 && currentInstance2.proxy && !hot) {
38686
+ const vm = currentInstance2.proxy;
38687
+ const cache = "_pStores" in vm ? vm._pStores : vm._pStores = {};
38688
+ cache[id] = store;
38689
+ }
37278
38690
  return store;
37279
38691
  }
37280
38692
  useStore.$id = id;
@@ -38822,19 +40234,19 @@ function _sfc_render$i(_ctx, _cache, $props, $setup, $data, $options) {
38822
40234
  const cssModules$f = {};
38823
40235
  cssModules$f["$style"] = style0$f;
38824
40236
  var SkeletonLoader = /* @__PURE__ */ _export_sfc(_sfc_main$i, [["render", _sfc_render$i], ["__cssModules", cssModules$f]]);
38825
- const wrapperClass$1 = "_wrapperClass_1fmyn_1";
38826
- const paymentMethodContainer = "_paymentMethodContainer_1fmyn_1";
38827
- const imageWrapper = "_imageWrapper_1fmyn_6";
38828
- const imageContainer = "_imageContainer_1fmyn_10";
38829
- const roundStylePaymentMethod = "_roundStylePaymentMethod_1fmyn_19";
38830
- const label$1 = "_label_1fmyn_23";
38831
- const mainLabel = "_mainLabel_1fmyn_30";
38832
- const subLabel = "_subLabel_1fmyn_37";
38833
- const invalid = "_invalid_1fmyn_46";
38834
- const rightAlign = "_rightAlign_1fmyn_52";
38835
- const paymentMethodDisabled = "_paymentMethodDisabled_1fmyn_57";
38836
- const img = "_img_1fmyn_63";
38837
- const branchNumber = "_branchNumber_1fmyn_67";
40237
+ const wrapperClass$1 = "_wrapperClass_wy5sc_1";
40238
+ const paymentMethodContainer = "_paymentMethodContainer_wy5sc_1";
40239
+ const imageWrapper = "_imageWrapper_wy5sc_6";
40240
+ const imageContainer = "_imageContainer_wy5sc_10";
40241
+ const roundStylePaymentMethod = "_roundStylePaymentMethod_wy5sc_19";
40242
+ const label$1 = "_label_wy5sc_23";
40243
+ const mainLabel = "_mainLabel_wy5sc_30";
40244
+ const subLabel = "_subLabel_wy5sc_37";
40245
+ const invalid = "_invalid_wy5sc_46";
40246
+ const rightAlign = "_rightAlign_wy5sc_58";
40247
+ const paymentMethodDisabled = "_paymentMethodDisabled_wy5sc_63";
40248
+ const img = "_img_wy5sc_68";
40249
+ const branchNumber = "_branchNumber_wy5sc_72";
38838
40250
  var style0$e = {
38839
40251
  wrapperClass: wrapperClass$1,
38840
40252
  paymentMethodContainer,
@@ -39249,9 +40661,9 @@ function _sfc_render$e(_ctx, _cache, $props, $setup, $data, $options) {
39249
40661
  var GetBankInfoWrapper = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["render", _sfc_render$e]]);
39250
40662
  function getBankInfo(params) {
39251
40663
  const newParams = reconstructParams(params);
39252
- execute(newParams);
40664
+ execute$1(newParams);
39253
40665
  }
39254
- function execute(params) {
40666
+ function execute$1(params) {
39255
40667
  var _a;
39256
40668
  try {
39257
40669
  const container2 = document.createElement("div");
@@ -40009,23 +41421,23 @@ function _sfc_render$a(_ctx, _cache, $props, $setup, $data, $options) {
40009
41421
  const cssModules$8 = {};
40010
41422
  cssModules$8["$style"] = style0$8;
40011
41423
  var AutoTopupMethod = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["render", _sfc_render$a], ["__cssModules", cssModules$8]]);
40012
- const container = "_container_1agnw_1";
40013
- const mainContents = "_mainContents_1agnw_10";
40014
- const section = "_section_1agnw_16";
40015
- const main = "_main_1agnw_10";
40016
- const icon$5 = "_icon_1agnw_24";
40017
- const title$5 = "_title_1agnw_28";
40018
- const description$5 = "_description_1agnw_35";
40019
- const config = "_config_1agnw_42";
40020
- const item = "_item_1agnw_47";
40021
- const label = "_label_1agnw_57";
40022
- const contents$5 = "_contents_1agnw_61";
40023
- const inner$5 = "_inner_1agnw_61";
40024
- const price = "_price_1agnw_64";
40025
- const amount = "_amount_1agnw_69";
40026
- const unit$1 = "_unit_1agnw_74";
40027
- const notice = "_notice_1agnw_79";
40028
- const updateMessage = "_updateMessage_1agnw_94";
41424
+ const container = "_container_1ehx9_1";
41425
+ const mainContents = "_mainContents_1ehx9_7";
41426
+ const section = "_section_1ehx9_13";
41427
+ const main = "_main_1ehx9_7";
41428
+ const icon$5 = "_icon_1ehx9_21";
41429
+ const title$5 = "_title_1ehx9_25";
41430
+ const description$5 = "_description_1ehx9_32";
41431
+ const config = "_config_1ehx9_39";
41432
+ const item = "_item_1ehx9_44";
41433
+ const label = "_label_1ehx9_54";
41434
+ const contents$5 = "_contents_1ehx9_58";
41435
+ const inner$5 = "_inner_1ehx9_58";
41436
+ const price = "_price_1ehx9_61";
41437
+ const amount = "_amount_1ehx9_66";
41438
+ const unit$1 = "_unit_1ehx9_71";
41439
+ const notice = "_notice_1ehx9_76";
41440
+ const updateMessage = "_updateMessage_1ehx9_91";
40029
41441
  var style0$7 = {
40030
41442
  container,
40031
41443
  mainContents,
@@ -40973,6 +42385,42 @@ function registerPaymentFeatures(params) {
40973
42385
  app.mount(container2);
40974
42386
  document.body.appendChild(container2);
40975
42387
  }
42388
+ async function getCashbackInformation(params) {
42389
+ const newParams = reconstructParams(params);
42390
+ await execute(newParams);
42391
+ }
42392
+ async function execute(params) {
42393
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;
42394
+ try {
42395
+ if (!(params == null ? void 0 : params.merchantPaymentId)) {
42396
+ return (_a = params == null ? void 0 : params.fail) == null ? void 0 : _a.call(params, { errorCode: MiniAppErrorType.badRequest });
42397
+ }
42398
+ const grantStatus = await checkPermission(PermissionName.mini_app_cashback_information);
42399
+ if (grantStatus !== PermissionStatus.granted) {
42400
+ return (_b = params == null ? void 0 : params.fail) == null ? void 0 : _b.call(params, {
42401
+ errorCode: MiniAppErrorType.insufficientScope
42402
+ });
42403
+ }
42404
+ const res = await ppFetch2({
42405
+ method: "GET",
42406
+ url: `web-api/app/v1/payments/cashback/granted/${params.merchantPaymentId}`,
42407
+ params: { merchant: params == null ? void 0 : params.merchant }
42408
+ });
42409
+ if ((res == null ? void 0 : res.ppFetchResult) === "apiError" && ((_e = (_d = (_c = res == null ? void 0 : res.body) == null ? void 0 : _c.unsigned) == null ? void 0 : _d.resultInfo) == null ? void 0 : _e.code) === "RESOURCE_NOT_FOUND") {
42410
+ return (_f = params == null ? void 0 : params.fail) == null ? void 0 : _f.call(params, {
42411
+ errorCode: MiniAppErrorType.invalidPaymentIdentifier
42412
+ });
42413
+ } else if (res.ppFetchResult !== "success") {
42414
+ return (_g = params == null ? void 0 : params.fail) == null ? void 0 : _g.call(params, { errorCode: getFailErrorCode(res.ppFetchResult) });
42415
+ } else {
42416
+ return (_j = params == null ? void 0 : params.success) == null ? void 0 : _j.call(params, {
42417
+ jws: (_i = (_h = res == null ? void 0 : res.body) == null ? void 0 : _h.signed) == null ? void 0 : _i.jws
42418
+ });
42419
+ }
42420
+ } catch (e) {
42421
+ return (_k = params == null ? void 0 : params.fail) == null ? void 0 : _k.call(params, { errorCode: MiniAppErrorType.serverError });
42422
+ }
42423
+ }
40976
42424
  var RuntimeEnv;
40977
42425
  (function(RuntimeEnv2) {
40978
42426
  RuntimeEnv2["JS"] = "JS";
@@ -40993,6 +42441,10 @@ class MiniAppModule extends JsBridgeModule {
40993
42441
  copyToClipboard(params) {
40994
42442
  copyToClipboard(params);
40995
42443
  }
42444
+ getCashbackInformation(params) {
42445
+ getCashbackInformation(params).catch(() => {
42446
+ });
42447
+ }
40996
42448
  openWebview(params) {
40997
42449
  openWebview(params);
40998
42450
  }