@feedmepos/mf-connect 0.1.115-dev → 0.1.115-prod

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 (154) hide show
  1. package/README.md +1 -66
  2. package/dist/{App-43mZfFAr.js → App-CvtSY8ZO.js} +618 -652
  3. package/dist/{Bin-CA7v180Y.js → Bin-B3gS9QVZ.js} +8 -8
  4. package/dist/{Broadcast-qmdifF2Y.js → Broadcast-DAeb-HaN.js} +21 -22
  5. package/dist/{CampaignAnalytic-xnrDxqaH.js → CampaignAnalytic-BfTaHVem.js} +7 -7
  6. package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-zjk-QdtX.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-zsei4OfG.js} +9 -9
  7. package/dist/{Card-D8icsk7L.js → Card-JFeVIwFs.js} +24 -25
  8. package/dist/{Collections--THcD-E_.js → Collections-xcDpEhIm.js} +185 -197
  9. package/dist/{Credit-JrbtVMBp.js → Credit-C9HJZjDS.js} +20 -21
  10. package/dist/{DateRangeChip.vue_vue_type_script_setup_true_lang-DrwKtnE5.js → DateRangeChip.vue_vue_type_script_setup_true_lang-DSqVY91w.js} +1 -1
  11. package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-D_jXVE2I.js +3494 -0
  12. package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-hVgqWdD0.js → EffectSheet.vue_vue_type_style_index_0_lang-C3J0rCTt.js} +32 -32
  13. package/dist/{Experience-CFeRqBoj.js → Experience-DszS8gto.js} +31 -32
  14. package/dist/{FileSaver.min-CCXIBm58.js → FileSaver.min-CFVQKaC-.js} +1 -1
  15. package/dist/{Game-CPxq6Ex3.js → Game-DhgeN7E2.js} +18 -19
  16. package/dist/{GiftCardSetup-D0esVZDp.js → GiftCardSetup-CWm6IhrS.js} +75 -75
  17. package/dist/{GoalPickerPanel.vue_vue_type_script_setup_true_lang-CJ1-vL-K.js → GoalPickerPanel.vue_vue_type_script_setup_true_lang-BuKADvmK.js} +7 -7
  18. package/dist/{Goals-DaKI6uXt.js → Goals-DtRVierH.js} +4 -4
  19. package/dist/{ImageInput.vue_vue_type_script_setup_true_lang-BOnL0GxM.js → ImageInput.vue_vue_type_script_setup_true_lang-DlEFyu6h.js} +1 -1
  20. package/dist/{Index-2kENoaZm.js → Index-DFRcu_qE.js} +10 -10
  21. package/dist/{LocationPicker.vue_vue_type_script_setup_true_lang-BtWnJKU_.js → LocationPicker.vue_vue_type_script_setup_true_lang-B3Br4Xvi.js} +1 -1
  22. package/dist/{LottieAnimation.vue_vue_type_script_setup_true_lang-CX_Sspu5.js → LottieAnimation.vue_vue_type_script_setup_true_lang-CjNJj3qj.js} +1 -1
  23. package/dist/{LoyaltyDashboard-CB93Fz8u.js → LoyaltyDashboard-BWHKDPzk.js} +15 -15
  24. package/dist/{MainLayout.vue_vue_type_script_setup_true_lang-Du8fw5v_.js → MainLayout-BmpNNAiE.js} +4 -5
  25. package/dist/Marketing-BKK45Eve.js +236 -0
  26. package/dist/{remy-icon-BhUGu2NI.js → MarketingMaterialEdit-x3c_N7Gs.js} +1031 -2
  27. package/dist/{Member-B--nYyr0.js → Member-xEzrBW_p.js} +7 -7
  28. package/dist/{MemberDetailSheet.vue_vue_type_script_setup_true_lang-BBlzO7Db.js → MemberDetailSheet.vue_vue_type_script_setup_true_lang-DRoC-I0t.js} +50 -43
  29. package/dist/{MemberImportHistory-D52Y4RTC.js → MemberImportHistory-CEQpBBF8.js} +7 -7
  30. package/dist/{MemberList-13Owa1fj.js → MemberList-CCvzkHv8.js} +105 -103
  31. package/dist/{MemberTransactions-CpXEWNbq.js → MemberTransactions-Bmh39J2W.js} +1 -1
  32. package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-DlELjFM0.js → MessageInput.vue_vue_type_script_setup_true_lang-D3Pmk80l.js} +14 -14
  33. package/dist/{MetricInfoTooltip.vue_vue_type_script_setup_true_lang-C_y0rM8c.js → MetricInfoTooltip.vue_vue_type_script_setup_true_lang-DIBKAwHP.js} +1 -1
  34. package/dist/{Mission-Ci-UzXSu.js → Mission-CpUo2Bgw.js} +21 -22
  35. package/dist/{Overview-CKxSfAGF.js → Overview-CwQqQ1Tn.js} +144 -145
  36. package/dist/{Overview-CXen9Ram.js → Overview-DcDZmDXA.js} +22 -23
  37. package/dist/{Point-CR3YOaag.js → Point-CUNQsQIx.js} +21 -22
  38. package/dist/{Promotion-tw3J4ul-.js → Promotion-Cqdim7aW.js} +131 -137
  39. package/dist/{Queue-BZGA5ZXt.js → Queue-CNBVh1UG.js} +45 -46
  40. package/dist/{Record-BTevVXnT.js → Record-BYwz4l4o.js} +9 -9
  41. package/dist/{Review-BU7c8ZF0.js → Review-CqLcZFj8.js} +2 -2
  42. package/dist/ReviewFacebookCallback-DbSCILNN.js +238 -0
  43. package/dist/{ReviewGoogleCallback-xpdPHSdg.js → ReviewGoogleCallback-Dg8R7QlO.js} +5 -5
  44. package/dist/{Reward-jlA_7cxz.js → Reward-M8GZ8eHq.js} +29 -29
  45. package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-D3z_n42G.js → RewardGroup.vue_vue_type_script_setup_true_lang-BkM9-Sx-.js} +15 -16
  46. package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-CnaL93TF.js +1883 -0
  47. package/dist/{Segment-C1Bwm--Q.js → Segment-CrMi6xrp.js} +305 -304
  48. package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-B6apgWTM.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-DKH5_9db.js} +30 -31
  49. package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-B7m2F9UV.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-CyeAQ-hg.js} +4 -4
  50. package/dist/Setting-BnFRI0Se.js +2037 -0
  51. package/dist/{SettingAdvertisements-4XEAJzlL.js → SettingAdvertisements-Dh7v4c1D.js} +12 -12
  52. package/dist/Settings-BvT8_tkQ.js +179 -0
  53. package/dist/{Store-C56dXtc4.js → Store-CV-BmK5b.js} +30 -31
  54. package/dist/{StoreRewards-DQ1Q6WS6.js → StoreRewards-DPhSLvSZ.js} +15 -15
  55. package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-CDu1QySl.js +1264 -0
  56. package/dist/TargetLocationInput.vue_vue_type_script_setup_true_lang-Dqz6jTlH.js +142 -0
  57. package/dist/{Tier-D4CPZqw7.js → Tier-ChvYps23.js} +687 -2576
  58. package/dist/{Title-DCbwhUic.js → Title-v-Ivswr1.js} +92 -94
  59. package/dist/{Transaction-C5LrasXr.js → Transaction-CRqE1Ix0.js} +2 -2
  60. package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-Cl9b4mrK.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-B0Uh9iuj.js} +26 -26
  61. package/dist/{Voucher-rrVbNZKR.js → Voucher-Bg8FOuzD.js} +19 -19
  62. package/dist/{VoucherEditor.vue_vue_type_script_setup_true_lang-BIq227nz.js → VoucherEditor.vue_vue_type_script_setup_true_lang-HKxivQMF.js} +16 -16
  63. package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-C39_95SZ.js → ZodTextField.vue_vue_type_script_setup_true_lang-8d290Dcp.js} +2 -2
  64. package/dist/{app-CgimGODl.js → app-DdNKsn2Q.js} +7107 -8874
  65. package/dist/app.js +3 -4
  66. package/dist/{base.export-D2P6HFvo.js → base.export-R97FrSQL.js} +2 -2
  67. package/dist/{business-Bu5TqSA0.js → business-Ce8vq3wQ.js} +1 -1
  68. package/dist/{campaign-zJxttSIk.js → campaign-BTllt2LH.js} +25 -31
  69. package/dist/{campaign-BFIXSgdJ.js → campaign-C19If7bW.js} +94 -121
  70. package/dist/{campaign.enum-Dx-Zo68Q.js → campaign.enum-9CCbalR4.js} +2 -3
  71. package/dist/{campaign.fn-gvjlcEfe.js → campaign.fn-B4g03h0A.js} +78 -78
  72. package/dist/{collectible.enum-Liy2wH3s.js → collectible.enum-MvqF7mSg.js} +1 -1
  73. package/dist/{collection.fn-DOm0HsSh.js → collection.fn-CR0bD33S.js} +2 -2
  74. package/dist/{currency-BpbQvbm8.js → currency-DmlguGIM.js} +1 -1
  75. package/dist/{effect-D-GtNB3n.js → effect-Dx3zfl28.js} +1 -1
  76. package/dist/{email-addresses-BKMoAtMi.js → email-addresses-De5PGOY4.js} +2 -2
  77. package/dist/{feature-flag-BJ_eyKsq.js → feature-flag-CD9V1V0h.js} +74 -74
  78. package/dist/google-C3S8u0mT.js +4 -0
  79. package/dist/{helper-CkfjBgMM.js → helper-CEiv7SaO.js} +1 -1
  80. package/dist/{index-zTvr2GR4.js → index-649OZ_e1.js} +2 -2
  81. package/dist/{index-feCrYhi6.js → index-B8meeQoD.js} +1 -1
  82. package/dist/{index-CIej31pF.js → index-B8yWVB8P.js} +3 -4
  83. package/dist/{index-BKsxIwbi.js → index-BAXKd9Gg.js} +198 -198
  84. package/dist/{index-BAtUrtqM.js → index-BDPnyro2.js} +6 -19
  85. package/dist/{index-DUAZOMVJ.js → index-BR9h5DTI.js} +1 -1
  86. package/dist/{index-DwU3fsLW.js → index-BVdYxi3l.js} +15 -29
  87. package/dist/{index-D0JK99Ko.js → index-BW6eb3n6.js} +252 -611
  88. package/dist/{index-LygS9WsG.js → index-BYI9ttxy.js} +10767 -8028
  89. package/dist/{index-BdEXUNoG.js → index-BquSqx6K.js} +4 -4
  90. package/dist/{index-BpTIulTX.js → index-CBJy9bxB.js} +1 -1
  91. package/dist/{index-B6kU3PkV.js → index-CPODug8b.js} +2613 -2700
  92. package/dist/{index-CfQuYqXn.js → index-CWUrODxL.js} +1 -1
  93. package/dist/{index-DKxN1mMS.js → index-CqOCJTeR.js} +232 -390
  94. package/dist/{index-CuREApMc.js → index-D4d3l0gw.js} +7 -8
  95. package/dist/{index-Bhl5IRXy.js → index-DT3S00_Y.js} +10 -11
  96. package/dist/{index-DqGs6RJG.js → index-IZRfmmde.js} +581 -683
  97. package/dist/{index-CQ8XFbBk.js → index-__UT3_Ey.js} +2 -2
  98. package/dist/{index-CCEXSPxk.js → index-xct3mnu8.js} +7 -7
  99. package/dist/{index.esm2017-DZi9IQPS.js → index.esm2017-AVbZ9btd.js} +177 -177
  100. package/dist/{loading-Brid2wnu.js → loading-BvHm1m3K.js} +1 -1
  101. package/dist/{lodash-C1epw3Kv.js → lodash-Dvrceo7x.js} +1 -1
  102. package/dist/{member-import-DAIxTIiu.js → member-import-c9avpiSS.js} +5 -6
  103. package/dist/{membership-BZmljFhF.js → membership-D-pZS634.js} +3 -3
  104. package/dist/{money-cLcyGcSZ.js → money-D4skwMkD.js} +1 -1
  105. package/dist/{number-C2jPLJr2.js → number-DJ6ncfT6.js} +1 -1
  106. package/dist/objectid-DEMM_jdR.js +145 -0
  107. package/dist/{onboarding-oRfy_g05.js → onboarding-t7R1d3h-.js} +25 -25
  108. package/dist/{onboardingSetup-BLD6m8HY.js → onboardingSetup-lTaJc0oT.js} +2 -2
  109. package/dist/{plugins-CUsr9vB0.js → plugins-DQNOWwRC.js} +3 -3
  110. package/dist/{reward-UOT03odb.js → reward-BK150pjm.js} +1 -1
  111. package/dist/{rule-BgJnPjkI.js → rule-COcdAnUu.js} +492 -572
  112. package/dist/rule-builder-Deufb6h_.js +102 -0
  113. package/dist/style.css +1 -1
  114. package/dist/template-DeebIqJ_.js +236 -0
  115. package/dist/{timezone-BXA4wq7Y.js → timezone-BP6UC4KL.js} +1 -1
  116. package/dist/{transaction.fn-CQ4fpRt3.js → transaction.fn-BY0hzon0.js} +2 -2
  117. package/dist/{trigger-DXJCGT0q.js → trigger-DVBjVPbN.js} +8 -8
  118. package/dist/useMarketingMaterialActions-DpQCQHFI.js +96 -0
  119. package/dist/{usePagination-Pp4okWr8.js → usePagination-QT552XyF.js} +1 -1
  120. package/dist/{user-B3gXcAIy.js → user-CmAxNc7T.js} +1 -1
  121. package/dist/vue-i18n-Cze706-f.js +2365 -0
  122. package/dist/{xlsx-CCaDUTgW.js → xlsx-DAczoc8y.js} +224 -224
  123. package/dist/{zod-CPwjOxvW.js → zod-Aj-GuVQL.js} +1 -1
  124. package/package.json +2 -6
  125. package/dist/AuditLogs-BPpdm96t.js +0 -2016
  126. package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-DgdAlHU7.js +0 -4442
  127. package/dist/Grab-BWzdN_cd.js +0 -301
  128. package/dist/MainLayout-DwnjGXh6.js +0 -4
  129. package/dist/Marketing-DCco__2F.js +0 -273
  130. package/dist/MarketingMaterialEdit-BbgFtrYP.js +0 -1037
  131. package/dist/ReviewFacebookCallback-BnMF6Arh.js +0 -225
  132. package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-CsHxqH9h.js +0 -1923
  133. package/dist/Setting-CDM4RhLW.js +0 -574
  134. package/dist/Settings-D-0tvZRr.js +0 -286
  135. package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-LLD91Rz6.js +0 -1319
  136. package/dist/TargetLocationInput.vue_vue_type_script_setup_true_lang-Bvy4NJMd.js +0 -7007
  137. package/dist/WhatsappAccount-oJDo5zTr.js +0 -159
  138. package/dist/WhatsappAccountStatusLabel.vue_vue_type_script_setup_true_lang-aCQCYFYq.js +0 -39
  139. package/dist/WhatsappBot-Cl64wG_F.js +0 -876
  140. package/dist/WhatsappBotLogs-D3uT4EiB.js +0 -372
  141. package/dist/WhatsappBotSettings-Cs1lLxh-.js +0 -705
  142. package/dist/WhatsappLayout-C639d2HP.js +0 -21
  143. package/dist/WhatsappNotificationGroupDialog.vue_vue_type_script_setup_true_lang-DpPxWp2x.js +0 -253
  144. package/dist/browser-BSAOEeIM.js +0 -1478
  145. package/dist/duplicateCampaign-CvsvjRE9.js +0 -51
  146. package/dist/feature-flag-Bo-k5sIG.js +0 -50
  147. package/dist/google-BQK68wbe.js +0 -5
  148. package/dist/index-C-iwb2Ln.js +0 -109
  149. package/dist/index-C_H8jFYf.js +0 -2743
  150. package/dist/index-DQ8JJhxs.js +0 -74
  151. package/dist/objectid-C-wocWKI.js +0 -145
  152. package/dist/template-BZyFhr73.js +0 -188
  153. package/dist/useMarketingMaterialActions-B-Wib5ga.js +0 -125
  154. package/dist/vue-i18n-DWGiC_vs.js +0 -2365
@@ -1,25 +1,24 @@
1
- import { defineComponent as xe, ref as ne, h as U, Comment as ln, computed as X, watch as q, resolveComponent as te, openBlock as j, createElementBlock as me, createVNode as R, unref as _, createElementVNode as I, toDisplayString as A, createBlock as Oe, withCtx as ee, Fragment as It, renderList as un, onBeforeUnmount as dn, onMounted as hn, createCommentVNode as Pe, nextTick as fn } from "vue";
2
- import { useRouter as yt, useRoute as wt, RouterView as pn } from "vue-router";
3
- import { useCoreStore as ge, FeedMeAuth as mn } from "@feedmepos/mf-common";
4
- import { u as gn } from "./app-wDQR6dpb.js";
5
- import { u as _n } from "./business-Bu5TqSA0.js";
6
- import { u as Tt } from "./feature-flag-Bo-k5sIG.js";
7
- import { l as vn } from "./feature-flag-BJ_eyKsq.js";
8
- import "./index-feCrYhi6.js";
9
- import { components as W, useSnackbar as In, useDialog as yn } from "@feedmepos/ui-library";
10
- import { u as kt } from "./vue-i18n-DWGiC_vs.js";
11
- import { m as wn } from "./index-DUAZOMVJ.js";
12
- import { C as Xe } from "./timezone-BXA4wq7Y.js";
13
- import { u as Tn } from "./onboarding-oRfy_g05.js";
14
- import { R as p, A as kn, a as Qe } from "./app-CgimGODl.js";
15
- import { J as bn } from "./JsonViewer-v8_C7l5N.js";
16
- import { r as Le, L as En, g as bt, i as Sn, a as Rn, _ as Ze, C as et, b as An, S as se, c as P, d as Q, E as Fe, e as Pn, f as Et, h as Cn, j as Nn, k as St, l as k, m as On, F as Ve, n as Ln, q as oe, o as Mn, p as Un, s as Dn, t as xn, u as Fn } from "./index.esm2017-DZi9IQPS.js";
1
+ import { defineComponent as xe, ref as ee, h as H, Comment as cn, computed as ne, watch as ie, resolveComponent as Z, openBlock as j, createElementBlock as me, createVNode as S, unref as g, createElementVNode as v, toDisplayString as R, createBlock as Oe, withCtx as Q, Fragment as It, renderList as ln, onMounted as un, createCommentVNode as Pe, nextTick as dn } from "vue";
2
+ import { useRouter as yt, useRoute as wt, RouterView as hn } from "vue-router";
3
+ import { useCoreStore as ge, FeedMeAuth as fn } from "@feedmepos/mf-common";
4
+ import { u as pn } from "./app-wDQR6dpb.js";
5
+ import { u as mn } from "./business-Ce8vq3wQ.js";
6
+ import { l as gn } from "./feature-flag-CD9V1V0h.js";
7
+ import "./index-B8meeQoD.js";
8
+ import { components as G, useSnackbar as _n, useDialog as vn } from "@feedmepos/ui-library";
9
+ import { u as Tt } from "./vue-i18n-Cze706-f.js";
10
+ import { m as In } from "./index-BR9h5DTI.js";
11
+ import { C as Xe } from "./timezone-BP6UC4KL.js";
12
+ import { u as yn } from "./onboarding-t7R1d3h-.js";
13
+ import { R as p, A as wn, a as Qe } from "./app-DdNKsn2Q.js";
14
+ import { J as Tn } from "./JsonViewer-v8_C7l5N.js";
15
+ import { r as Le, L as kn, g as kt, i as bn, a as En, _ as Ze, C as et, b as Sn, S as se, c as A, d as Y, E as Fe, e as Rn, f as bt, h as An, j as Pn, k as Et, l as w, m as Cn, F as Ve, n as Nn, q as oe, o as On, p as Ln, s as Mn, t as Un, u as Dn } from "./index.esm2017-AVbZ9btd.js";
17
16
  import { _ as $e } from "./tslib.es6-BCqqvLQ_.js";
18
- import { S as tt, c as Vn } from "./index-CCEXSPxk.js";
19
- const $n = { class: "flex flex-col h-full justify-between py-16" }, Hn = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary text-center" }, Wn = /* @__PURE__ */ xe({
17
+ import { S as tt, c as xn } from "./index-xct3mnu8.js";
18
+ const Fn = { class: "flex flex-col h-full justify-between py-16" }, Vn = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary text-center" }, $n = /* @__PURE__ */ xe({
20
19
  __name: "NavigationTab",
21
20
  setup(n) {
22
- const { t: e, locale: t } = kt(), i = Tn(), r = Tt(), s = ne(), o = [
21
+ const { t: e, locale: t } = Tt(), i = yn(), r = ee(), s = [
23
22
  {
24
23
  label: e("connect.navigation.analytic"),
25
24
  value: p["$connect-ANALYTIC"]
@@ -39,10 +38,6 @@ const $n = { class: "flex flex-col h-full justify-between py-16" }, Hn = { class
39
38
  {
40
39
  label: e("connect.navigation.broadcast"),
41
40
  value: p["$connect-CAMPAIGN_BROADCAST"]
42
- },
43
- {
44
- label: e("connect.navigation.grab"),
45
- value: p["$connect-CAMPAIGN_GRAB"]
46
41
  }
47
42
  ]
48
43
  },
@@ -65,7 +60,7 @@ const $n = { class: "flex flex-col h-full justify-between py-16" }, Hn = { class
65
60
  {
66
61
  label: e("connect.navigation.point"),
67
62
  value: p["$connect-PROGRAM_POINT"],
68
- badge: () => U(W.FmPill, { variant: "premium" })
63
+ badge: () => H(G.FmPill, { variant: "premium" })
69
64
  },
70
65
  {
71
66
  label: e("connect.navigation.credit"),
@@ -74,7 +69,7 @@ const $n = { class: "flex flex-col h-full justify-between py-16" }, Hn = { class
74
69
  {
75
70
  label: e("connect.navigation.game"),
76
71
  value: p["$connect-PROGRAM_GAME"],
77
- badge: () => U(W.FmPill, { variant: "premium" })
72
+ badge: () => H(G.FmPill, { variant: "premium" })
78
73
  },
79
74
  {
80
75
  label: "Mission",
@@ -93,24 +88,19 @@ const $n = { class: "flex flex-col h-full justify-between py-16" }, Hn = { class
93
88
  {
94
89
  label: e("connect.navigation.segments"),
95
90
  value: p["$connect-LOYALTY_SEGMENT"],
96
- badge: () => U(W.FmPill, { variant: "premium" })
91
+ badge: () => H(G.FmPill, { variant: "premium" })
97
92
  },
98
93
  {
99
94
  label: e("connect.navigation.card"),
100
95
  value: p["$connect-LOYALTY_CARD"],
101
- badge: () => U(W.FmPill, { variant: "premium" })
96
+ badge: () => H(G.FmPill, { variant: "premium" })
102
97
  }
103
98
  ]
104
99
  },
105
- {
106
- label: e("connect.navigation.whatsappBot"),
107
- value: p["$connect-WHATSAPP"],
108
- badge: () => U(W.FmPill, { variant: "beta" })
109
- },
110
100
  {
111
101
  label: e("connect.navigation.referral"),
112
102
  value: p["$connect-REFERRAL"],
113
- badge: () => U(W.FmPill, { variant: "premium" })
103
+ badge: () => H(G.FmPill, { variant: "premium" })
114
104
  },
115
105
  {
116
106
  label: e("connect.navigation.store"),
@@ -124,10 +114,6 @@ const $n = { class: "flex flex-col h-full justify-between py-16" }, Hn = { class
124
114
  label: e("connect.navigation.marketingMaterials"),
125
115
  value: p["$connect-MARKETING"]
126
116
  },
127
- {
128
- label: e("connect.navigation.auditLogs"),
129
- value: p["$connect-AUDIT_LOGS"]
130
- },
131
117
  {
132
118
  label: e("connect.navigation.review"),
133
119
  value: p["$connect-REVIEW"]
@@ -135,11 +121,11 @@ const $n = { class: "flex flex-col h-full justify-between py-16" }, Hn = { class
135
121
  {
136
122
  label: e("connect.navigation.goals"),
137
123
  value: p["$connect-GOALS"],
138
- badge: () => i.goalsRemaining > 0 ? U(W.FmBadge, {
124
+ badge: () => i.goalsRemaining > 0 ? H(G.FmBadge, {
139
125
  variant: "numeric",
140
126
  inline: !0,
141
127
  value: i.goalsRemaining
142
- }) : U(ln)
128
+ }) : H(cn)
143
129
  },
144
130
  {
145
131
  label: e("connect.navigation.setting"),
@@ -149,80 +135,76 @@ const $n = { class: "flex flex-col h-full justify-between py-16" }, Hn = { class
149
135
  label: e("connect.navigation.bin"),
150
136
  value: p["$connect-BIN"]
151
137
  }
152
- ], c = X(
153
- () => o.filter(
154
- (f) => f.value !== p["$connect-WHATSAPP"] || r.whatsappBotEnabled
155
- )
156
- ), a = yt(), l = wt(), h = o.reduce((f, w) => [...(w.children ?? []).map((d) => d.value), ...f, w.value], []), m = ge(), v = X(() => {
157
- const f = m.currentCountry.value || "MY";
138
+ ], o = yt(), c = wt(), a = s.reduce((f, y) => [...(y.children ?? []).map((_) => _.value), ...f, y.value], []), l = ge(), d = ne(() => {
139
+ const f = l.currentCountry.value || "MY";
158
140
  return console.log(`[MF] Timezone set to: ${Xe[f]}`), Xe[f];
159
141
  });
160
- q(
142
+ ie(
161
143
  // Watch `route.matched`, not `route`: `useRoute()` returns a reactive object
162
144
  // whose identity never changes, so watching it directly fired once via
163
145
  // `immediate` and the highlight then stayed on whatever page loaded first.
164
- () => l.matched,
146
+ () => c.matched,
165
147
  (f) => {
166
- const d = f.map((g) => g.name).reverse().find((g) => h.includes(g));
167
- d && (s.value = d);
148
+ const _ = f.map((h) => h.name).reverse().find((h) => a.includes(h));
149
+ _ && (r.value = _);
168
150
  },
169
151
  { immediate: !0 }
170
- ), q(
152
+ ), ie(
171
153
  [() => {
172
154
  var f;
173
- return (f = m.currentBusiness.value) == null ? void 0 : f._id;
174
- }, () => l.name, t],
155
+ return (f = l.currentBusiness.value) == null ? void 0 : f._id;
156
+ }, () => c.name, t],
175
157
  ([f]) => {
176
158
  f && i.read(t.value, f);
177
159
  },
178
160
  { immediate: !0 }
179
161
  );
180
- async function y(f) {
181
- await a.push({ name: f });
162
+ async function m(f) {
163
+ await o.push({ name: f });
182
164
  }
183
- return (f, w) => {
184
- var g;
185
- const d = te("FmCollapsibleTabs");
186
- return j(), me("div", $n, [
187
- R(d, {
165
+ return (f, y) => {
166
+ var h;
167
+ const _ = Z("FmCollapsibleTabs");
168
+ return j(), me("div", Fn, [
169
+ S(_, {
188
170
  class: "border-fm-color-neutral-gray-100 border-r px-4",
189
- "model-value": (g = _(s)) == null ? void 0 : g.toString(),
190
- items: _(c),
191
- "onUpdate:modelValue": y
192
- }, null, 8, ["model-value", "items"]),
193
- I("div", Hn, [
194
- I("div", null, "Timezone: " + A(_(v).split("/")[1].replace("_", " ")), 1),
195
- I("div", null, "(UTC" + A(_(wn).tz(_(v)).format("Z")) + ")", 1)
171
+ "model-value": (h = g(r)) == null ? void 0 : h.toString(),
172
+ items: s,
173
+ "onUpdate:modelValue": m
174
+ }, null, 8, ["model-value"]),
175
+ v("div", Vn, [
176
+ v("div", null, "Timezone: " + R(g(d).split("/")[1].replace("_", " ")), 1),
177
+ v("div", null, "(UTC" + R(g(In).tz(g(d)).format("Z")) + ")", 1)
196
178
  ])
197
179
  ]);
198
180
  };
199
181
  }
200
- }), Rt = "feedme_connect_marketing_promo_hidden";
201
- function jn() {
182
+ }), St = "feedme_connect_marketing_promo_hidden";
183
+ function Hn() {
202
184
  try {
203
- return localStorage.getItem(Rt) !== null;
185
+ return localStorage.getItem(St) !== null;
204
186
  } catch {
205
187
  return !1;
206
188
  }
207
189
  }
208
- function Bn() {
190
+ function jn() {
209
191
  try {
210
- localStorage.setItem(Rt, (/* @__PURE__ */ new Date()).toISOString());
192
+ localStorage.setItem(St, (/* @__PURE__ */ new Date()).toISOString());
211
193
  } catch {
212
194
  }
213
195
  }
214
- const Gn = { class: "flex flex-col gap-12" }, zn = { class: "fm-corner-radius-xxl bg-fm-color-primary-oats flex items-start gap-4 self-start px-12 py-4" }, qn = { class: "fm-typo-en-body-sm-600 text-fm-color-primary" }, Kn = { class: "fm-typo-en-title-sm-800 max-w-[560px] leading-[42px]" }, Jn = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary max-w-[600px]" }, Yn = { class: "flex flex-col gap-24 pb-8" }, Xn = { class: "grid grid-cols-1 gap-16 sm:grid-cols-3 md:grid-cols-3 lg:grid-cols-3" }, Qn = { class: "fm-corner-radius-sm bg-fm-color-primary-oats flex h-40 w-40 shrink-0 items-center justify-center" }, Zn = { class: "fm-typo-en-body-lg-600" }, ei = { class: "fm-typo-en-body-md-400 text-fm-color-typo-tertiary" }, ti = { class: "shrink-0" }, ni = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, ii = { class: "flex w-full flex-col gap-12 px-[16px]" }, ri = { class: "flex flex-wrap items-center gap-12" }, si = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-tertiary" }, oi = /* @__PURE__ */ xe({
196
+ const Wn = { class: "flex flex-col gap-12" }, Bn = { class: "fm-corner-radius-xxl bg-fm-color-primary-oats flex items-start gap-4 self-start px-12 py-4" }, Gn = { class: "fm-typo-en-body-sm-600 text-fm-color-primary" }, zn = { class: "fm-typo-en-title-sm-800 max-w-[560px] leading-[42px]" }, qn = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary max-w-[600px]" }, Kn = { class: "flex flex-col gap-24 pb-8" }, Jn = { class: "grid grid-cols-1 gap-16 sm:grid-cols-3 md:grid-cols-3 lg:grid-cols-3" }, Yn = { class: "fm-corner-radius-sm bg-fm-color-primary-oats flex h-40 w-40 shrink-0 items-center justify-center" }, Xn = { class: "fm-typo-en-body-lg-600" }, Qn = { class: "fm-typo-en-body-md-400 text-fm-color-typo-tertiary" }, Zn = { class: "shrink-0" }, ei = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, ti = { class: "flex w-full flex-col gap-12 px-[16px]" }, ni = { class: "flex flex-wrap items-center gap-12" }, ii = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-tertiary" }, ri = /* @__PURE__ */ xe({
215
197
  __name: "AiMarketingPromoDialog",
216
198
  setup(n) {
217
199
  let e = !1;
218
- const { t } = kt(), i = yt(), { sessionUser: r, currentCountry: s } = ge(), o = ne(!1), c = [
200
+ const { t } = Tt(), i = yt(), { sessionUser: r, currentCountry: s } = ge(), o = ee(!1), c = [
219
201
  { key: "completeContent", icon: "layers" },
220
202
  { key: "realContext", icon: "storefront" },
221
203
  { key: "socialFormat", icon: "aspect_ratio" }
222
- ], a = X(() => {
223
- var f;
224
- const y = ((f = r.value) == null ? void 0 : f.permissions) ?? [];
225
- return kn(
204
+ ], a = ne(() => {
205
+ var _;
206
+ const y = ((_ = r.value) == null ? void 0 : _.permissions) ?? [];
207
+ return wn(
226
208
  [
227
209
  {
228
210
  action: Qe.Action.manage,
@@ -231,104 +213,104 @@ const Gn = { class: "flex flex-col gap-12" }, zn = { class: "fm-corner-radius-xx
231
213
  ],
232
214
  y
233
215
  ).granted;
234
- }), l = X(
216
+ }), l = ne(
235
217
  () => s.value === "MY" && a.value
236
218
  );
237
- let h = !1;
238
- q(
219
+ let d = !1;
220
+ ie(
239
221
  l,
240
222
  (y) => {
241
- h || !y || (h = !0, !(jn() || e) && (e = !0, o.value = !0));
223
+ d || !y || (d = !0, !(Hn() || e) && (e = !0, o.value = !0));
242
224
  },
243
225
  { immediate: !0 }
244
226
  );
245
227
  async function m() {
246
228
  o.value = !1, await i.push({ name: p["$connect-MARKETING"] });
247
229
  }
248
- function v() {
249
- Bn(), o.value = !1;
230
+ function f() {
231
+ jn(), o.value = !1;
250
232
  }
251
- return (y, f) => {
252
- const w = te("FmIcon"), d = te("FmCard"), g = te("FmButton"), b = te("FmDialog");
253
- return j(), Oe(b, {
233
+ return (y, _) => {
234
+ const h = Z("FmIcon"), I = Z("FmCard"), T = Z("FmButton"), M = Z("FmDialog");
235
+ return j(), Oe(M, {
254
236
  modelValue: o.value,
255
- "onUpdate:modelValue": f[0] || (f[0] = (T) => o.value = T),
237
+ "onUpdate:modelValue": _[0] || (_[0] = (k) => o.value = k),
256
238
  "min-width": "min(500px, calc(100% - 48px))",
257
239
  "max-width": "min(860px, calc(100% - 48px))",
258
240
  "max-height": "90vh",
259
241
  "dismiss-away": ""
260
242
  }, {
261
- "dialog-header": ee(() => [
262
- I("div", Gn, [
263
- I("div", zn, [
264
- R(w, {
243
+ "dialog-header": Q(() => [
244
+ v("div", Wn, [
245
+ v("div", Bn, [
246
+ S(h, {
265
247
  name: "auto_awesome",
266
248
  size: "sm",
267
249
  color: "primary"
268
250
  }),
269
- I("span", qn, A(_(t)("connect.marketing.whatsNew.badge")), 1)
251
+ v("span", Gn, R(g(t)("connect.marketing.whatsNew.badge")), 1)
270
252
  ]),
271
- I("h1", Kn, A(_(t)("connect.marketing.whatsNew.title")), 1),
272
- I("p", Jn, A(_(t)("connect.marketing.whatsNew.subtitle")), 1)
253
+ v("h1", zn, R(g(t)("connect.marketing.whatsNew.title")), 1),
254
+ v("p", qn, R(g(t)("connect.marketing.whatsNew.subtitle")), 1)
273
255
  ])
274
256
  ]),
275
- "dialog-footer": ee(() => [
276
- I("div", ii, [
277
- I("div", ri, [
278
- R(g, {
257
+ "dialog-footer": Q(() => [
258
+ v("div", ti, [
259
+ v("div", ni, [
260
+ S(T, {
279
261
  variant: "primary",
280
262
  size: "lg",
281
- label: _(t)("connect.marketing.whatsNew.cta"),
263
+ label: g(t)("connect.marketing.whatsNew.cta"),
282
264
  "append-icon": "arrow_forward",
283
265
  onClick: m
284
266
  }, null, 8, ["label"]),
285
- R(g, {
267
+ S(T, {
286
268
  variant: "tertiary",
287
269
  size: "lg",
288
- label: _(t)("connect.marketing.whatsNew.dismiss"),
289
- onClick: v
270
+ label: g(t)("connect.marketing.whatsNew.dismiss"),
271
+ onClick: f
290
272
  }, null, 8, ["label"])
291
273
  ]),
292
- I("div", si, A(_(t)("connect.marketing.whatsNew.footnote")), 1)
274
+ v("div", ii, R(g(t)("connect.marketing.whatsNew.footnote")), 1)
293
275
  ])
294
276
  ]),
295
- default: ee(() => [
296
- I("div", Yn, [
297
- I("div", Xn, [
298
- (j(), me(It, null, un(c, (T) => R(d, {
299
- key: T.key,
277
+ default: Q(() => [
278
+ v("div", Kn, [
279
+ v("div", Jn, [
280
+ (j(), me(It, null, ln(c, (k) => S(I, {
281
+ key: k.key,
300
282
  variant: "outlined",
301
283
  class: "!h-full flex flex-col gap-8 p-16"
302
284
  }, {
303
- default: ee(() => [
304
- I("div", Qn, [
305
- R(w, {
306
- name: T.icon,
285
+ default: Q(() => [
286
+ v("div", Yn, [
287
+ S(h, {
288
+ name: k.icon,
307
289
  size: "md",
308
290
  color: "primary"
309
291
  }, null, 8, ["name"])
310
292
  ]),
311
- I("div", Zn, A(_(t)(`connect.marketing.whatsNew.benefits.${T.key}.title`)), 1),
312
- I("div", ei, A(_(t)(
313
- `connect.marketing.whatsNew.benefits.${T.key}.description`
293
+ v("div", Xn, R(g(t)(`connect.marketing.whatsNew.benefits.${k.key}.title`)), 1),
294
+ v("div", Qn, R(g(t)(
295
+ `connect.marketing.whatsNew.benefits.${k.key}.description`
314
296
  )), 1)
315
297
  ]),
316
298
  _: 2
317
299
  }, 1024)), 64))
318
300
  ]),
319
- R(d, {
301
+ S(I, {
320
302
  variant: "outlined",
321
303
  class: "flex items-start gap-12 p-16"
322
304
  }, {
323
- default: ee(() => [
324
- I("div", ti, [
325
- R(w, {
305
+ default: Q(() => [
306
+ v("div", Zn, [
307
+ S(h, {
326
308
  name: "lightbulb",
327
309
  size: "md",
328
310
  color: "primary"
329
311
  })
330
312
  ]),
331
- I("p", ni, A(_(t)("connect.marketing.whatsNew.callout")), 1)
313
+ v("p", ei, R(g(t)("connect.marketing.whatsNew.callout")), 1)
332
314
  ]),
333
315
  _: 1
334
316
  })
@@ -339,7 +321,7 @@ const Gn = { class: "flex flex-col gap-12" }, zn = { class: "fm-corner-radius-xx
339
321
  };
340
322
  }
341
323
  });
342
- var ai = "firebase", ci = "10.12.4";
324
+ var si = "firebase", oi = "10.12.4";
343
325
  /**
344
326
  * @license
345
327
  * Copyright 2020 Google LLC
@@ -356,13 +338,13 @@ var ai = "firebase", ci = "10.12.4";
356
338
  * See the License for the specific language governing permissions and
357
339
  * limitations under the License.
358
340
  */
359
- Le(ai, ci, "app");
360
- function At() {
341
+ Le(si, oi, "app");
342
+ function Rt() {
361
343
  return {
362
344
  "dependent-sdk-initialized-before-auth": "Another Firebase SDK was initialized and is trying to use Auth before Auth is initialized. Please be sure to call `initializeAuth` or `getAuth` before starting any other Firebase SDK."
363
345
  };
364
346
  }
365
- const li = At, Pt = new Fe("auth", "Firebase", At());
347
+ const ai = Rt, At = new Fe("auth", "Firebase", Rt());
366
348
  /**
367
349
  * @license
368
350
  * Copyright 2020 Google LLC
@@ -379,12 +361,12 @@ const li = At, Pt = new Fe("auth", "Firebase", At());
379
361
  * See the License for the specific language governing permissions and
380
362
  * limitations under the License.
381
363
  */
382
- const _e = new En("@firebase/auth");
383
- function ui(n, ...e) {
384
- _e.logLevel <= St.WARN && _e.warn(`Auth (${se}): ${n}`, ...e);
364
+ const _e = new kn("@firebase/auth");
365
+ function ci(n, ...e) {
366
+ _e.logLevel <= Et.WARN && _e.warn(`Auth (${se}): ${n}`, ...e);
385
367
  }
386
368
  function de(n, ...e) {
387
- _e.logLevel <= St.ERROR && _e.error(`Auth (${se}): ${n}`, ...e);
369
+ _e.logLevel <= Et.ERROR && _e.error(`Auth (${se}): ${n}`, ...e);
388
370
  }
389
371
  /**
390
372
  * @license
@@ -402,38 +384,38 @@ function de(n, ...e) {
402
384
  * See the License for the specific language governing permissions and
403
385
  * limitations under the License.
404
386
  */
405
- function L(n, ...e) {
387
+ function O(n, ...e) {
406
388
  throw He(n, ...e);
407
389
  }
408
- function E(n, ...e) {
390
+ function b(n, ...e) {
409
391
  return He(n, ...e);
410
392
  }
411
- function Ct(n, e, t) {
412
- const i = Object.assign(Object.assign({}, li()), { [e]: t });
393
+ function Pt(n, e, t) {
394
+ const i = Object.assign(Object.assign({}, ai()), { [e]: t });
413
395
  return new Fe("auth", "Firebase", i).create(e, {
414
396
  appName: n.name
415
397
  });
416
398
  }
417
- function H(n) {
418
- return Ct(n, "operation-not-supported-in-this-environment", "Operations that alter the current user are not supported in conjunction with FirebaseServerApp");
399
+ function $(n) {
400
+ return Pt(n, "operation-not-supported-in-this-environment", "Operations that alter the current user are not supported in conjunction with FirebaseServerApp");
419
401
  }
420
402
  function He(n, ...e) {
421
403
  if (typeof n != "string") {
422
404
  const t = e[0], i = [...e.slice(1)];
423
405
  return i[0] && (i[0].appName = n.name), n._errorFactory.create(t, ...i);
424
406
  }
425
- return Pt.create(n, ...e);
407
+ return At.create(n, ...e);
426
408
  }
427
409
  function u(n, e, ...t) {
428
410
  if (!n)
429
411
  throw He(e, ...t);
430
412
  }
431
- function C(n) {
413
+ function P(n) {
432
414
  const e = "INTERNAL ASSERTION FAILED: " + n;
433
415
  throw de(e), new Error(e);
434
416
  }
435
- function M(n, e) {
436
- n || C(e);
417
+ function L(n, e) {
418
+ n || P(e);
437
419
  }
438
420
  /**
439
421
  * @license
@@ -455,7 +437,7 @@ function Me() {
455
437
  var n;
456
438
  return typeof self < "u" && ((n = self.location) === null || n === void 0 ? void 0 : n.href) || "";
457
439
  }
458
- function di() {
440
+ function li() {
459
441
  return nt() === "http:" || nt() === "https:";
460
442
  }
461
443
  function nt() {
@@ -478,15 +460,15 @@ function nt() {
478
460
  * See the License for the specific language governing permissions and
479
461
  * limitations under the License.
480
462
  */
481
- function hi() {
463
+ function ui() {
482
464
  return typeof navigator < "u" && navigator && "onLine" in navigator && typeof navigator.onLine == "boolean" && // Apply only for traditional web apps and Chrome extensions.
483
465
  // This is especially true for Cordova apps which have unreliable
484
466
  // navigator.onLine behavior unless cordova-plugin-network-information is
485
467
  // installed which overwrites the native navigator.onLine value and
486
468
  // defines navigator.connection.
487
- (di() || An() || "connection" in navigator) ? navigator.onLine : !0;
469
+ (li() || Sn() || "connection" in navigator) ? navigator.onLine : !0;
488
470
  }
489
- function fi() {
471
+ function di() {
490
472
  if (typeof navigator > "u")
491
473
  return null;
492
474
  const n = navigator;
@@ -516,10 +498,10 @@ function fi() {
516
498
  */
517
499
  class ae {
518
500
  constructor(e, t) {
519
- this.shortDelay = e, this.longDelay = t, M(t > e, "Short delay should be less than long delay!"), this.isMobile = Sn() || Rn();
501
+ this.shortDelay = e, this.longDelay = t, L(t > e, "Short delay should be less than long delay!"), this.isMobile = bn() || En();
520
502
  }
521
503
  get() {
522
- return hi() ? this.isMobile ? this.longDelay : this.shortDelay : Math.min(5e3, this.shortDelay);
504
+ return ui() ? this.isMobile ? this.longDelay : this.shortDelay : Math.min(5e3, this.shortDelay);
523
505
  }
524
506
  }
525
507
  /**
@@ -538,8 +520,8 @@ class ae {
538
520
  * See the License for the specific language governing permissions and
539
521
  * limitations under the License.
540
522
  */
541
- function We(n, e) {
542
- M(n.emulator, "Emulator should always be set here");
523
+ function je(n, e) {
524
+ L(n.emulator, "Emulator should always be set here");
543
525
  const { url: t } = n.emulator;
544
526
  return e ? `${t}${e.startsWith("/") ? e.slice(1) : e}` : t;
545
527
  }
@@ -559,7 +541,7 @@ function We(n, e) {
559
541
  * See the License for the specific language governing permissions and
560
542
  * limitations under the License.
561
543
  */
562
- class Nt {
544
+ class Ct {
563
545
  static initialize(e, t, i) {
564
546
  this.fetchImpl = e, t && (this.headersImpl = t), i && (this.responseImpl = i);
565
547
  }
@@ -572,7 +554,7 @@ class Nt {
572
554
  return globalThis.fetch;
573
555
  if (typeof fetch < "u")
574
556
  return fetch;
575
- C("Could not find fetch implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill");
557
+ P("Could not find fetch implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill");
576
558
  }
577
559
  static headers() {
578
560
  if (this.headersImpl)
@@ -583,7 +565,7 @@ class Nt {
583
565
  return globalThis.Headers;
584
566
  if (typeof Headers < "u")
585
567
  return Headers;
586
- C("Could not find Headers implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill");
568
+ P("Could not find Headers implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill");
587
569
  }
588
570
  static response() {
589
571
  if (this.responseImpl)
@@ -594,7 +576,7 @@ class Nt {
594
576
  return globalThis.Response;
595
577
  if (typeof Response < "u")
596
578
  return Response;
597
- C("Could not find Response implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill");
579
+ P("Could not find Response implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill");
598
580
  }
599
581
  }
600
582
  /**
@@ -613,7 +595,7 @@ class Nt {
613
595
  * See the License for the specific language governing permissions and
614
596
  * limitations under the License.
615
597
  */
616
- const pi = {
598
+ const hi = {
617
599
  // Custom token errors.
618
600
  CREDENTIAL_MISMATCH: "custom-token-mismatch",
619
601
  // This can only happen if the SDK sends a bad request.
@@ -704,12 +686,12 @@ const pi = {
704
686
  * See the License for the specific language governing permissions and
705
687
  * limitations under the License.
706
688
  */
707
- const mi = new ae(3e4, 6e4);
689
+ const fi = new ae(3e4, 6e4);
708
690
  function Te(n, e) {
709
691
  return n.tenantId && !e.tenantId ? Object.assign(Object.assign({}, e), { tenantId: n.tenantId }) : e;
710
692
  }
711
- async function Z(n, e, t, i, r = {}) {
712
- return Ot(n, r, async () => {
693
+ async function X(n, e, t, i, r = {}) {
694
+ return Nt(n, r, async () => {
713
695
  let s = {}, o = {};
714
696
  i && (e === "GET" ? o = i : s = {
715
697
  body: JSON.stringify(i)
@@ -721,18 +703,18 @@ async function Z(n, e, t, i, r = {}) {
721
703
  ] = "application/json", n.languageCode && (a[
722
704
  "X-Firebase-Locale"
723
705
  /* HttpHeader.X_FIREBASE_LOCALE */
724
- ] = n.languageCode), Nt.fetch()(Mt(n, n.config.apiHost, t, c), Object.assign({
706
+ ] = n.languageCode), Ct.fetch()(Lt(n, n.config.apiHost, t, c), Object.assign({
725
707
  method: e,
726
708
  headers: a,
727
709
  referrerPolicy: "no-referrer"
728
710
  }, s));
729
711
  });
730
712
  }
731
- async function Ot(n, e, t) {
713
+ async function Nt(n, e, t) {
732
714
  n._canInitEmulator = !1;
733
- const i = Object.assign(Object.assign({}, pi), e);
715
+ const i = Object.assign(Object.assign({}, hi), e);
734
716
  try {
735
- const r = new gi(n), s = await Promise.race([
717
+ const r = new pi(n), s = await Promise.race([
736
718
  t(),
737
719
  r.promise
738
720
  ]);
@@ -750,35 +732,35 @@ async function Ot(n, e, t) {
750
732
  throw ue(n, "email-already-in-use", o);
751
733
  if (a === "USER_DISABLED")
752
734
  throw ue(n, "user-disabled", o);
753
- const h = i[a] || a.toLowerCase().replace(/[_\s]+/g, "-");
735
+ const d = i[a] || a.toLowerCase().replace(/[_\s]+/g, "-");
754
736
  if (l)
755
- throw Ct(n, h, l);
756
- L(n, h);
737
+ throw Pt(n, d, l);
738
+ O(n, d);
757
739
  }
758
740
  } catch (r) {
759
741
  if (r instanceof Ve)
760
742
  throw r;
761
- L(n, "network-request-failed", { message: String(r) });
743
+ O(n, "network-request-failed", { message: String(r) });
762
744
  }
763
745
  }
764
- async function Lt(n, e, t, i, r = {}) {
765
- const s = await Z(n, e, t, i, r);
766
- return "mfaPendingCredential" in s && L(n, "multi-factor-auth-required", {
746
+ async function Ot(n, e, t, i, r = {}) {
747
+ const s = await X(n, e, t, i, r);
748
+ return "mfaPendingCredential" in s && O(n, "multi-factor-auth-required", {
767
749
  _serverResponse: s
768
750
  }), s;
769
751
  }
770
- function Mt(n, e, t, i) {
752
+ function Lt(n, e, t, i) {
771
753
  const r = `${e}${t}?${i}`;
772
- return n.config.emulator ? We(n.config, r) : `${n.config.apiScheme}://${r}`;
754
+ return n.config.emulator ? je(n.config, r) : `${n.config.apiScheme}://${r}`;
773
755
  }
774
- class gi {
756
+ class pi {
775
757
  constructor(e) {
776
758
  this.auth = e, this.timer = null, this.promise = new Promise((t, i) => {
777
- this.timer = setTimeout(() => i(E(
759
+ this.timer = setTimeout(() => i(b(
778
760
  this.auth,
779
761
  "network-request-failed"
780
762
  /* AuthErrorCode.NETWORK_REQUEST_FAILED */
781
- )), mi.get());
763
+ )), fi.get());
782
764
  });
783
765
  }
784
766
  clearNetworkTimeout() {
@@ -790,7 +772,7 @@ function ue(n, e, t) {
790
772
  appName: n.name
791
773
  };
792
774
  t.email && (i.email = t.email), t.phoneNumber && (i.phoneNumber = t.phoneNumber);
793
- const r = E(n, e, i);
775
+ const r = b(n, e, i);
794
776
  return r.customData._tokenResponse = t, r;
795
777
  }
796
778
  /**
@@ -809,11 +791,11 @@ function ue(n, e, t) {
809
791
  * See the License for the specific language governing permissions and
810
792
  * limitations under the License.
811
793
  */
812
- async function _i(n, e) {
813
- return Z(n, "POST", "/v1/accounts:delete", e);
794
+ async function mi(n, e) {
795
+ return X(n, "POST", "/v1/accounts:delete", e);
814
796
  }
815
- async function Ut(n, e) {
816
- return Z(n, "POST", "/v1/accounts:lookup", e);
797
+ async function Mt(n, e) {
798
+ return X(n, "POST", "/v1/accounts:lookup", e);
817
799
  }
818
800
  /**
819
801
  * @license
@@ -831,7 +813,7 @@ async function Ut(n, e) {
831
813
  * See the License for the specific language governing permissions and
832
814
  * limitations under the License.
833
815
  */
834
- function ie(n) {
816
+ function te(n) {
835
817
  if (n)
836
818
  try {
837
819
  const e = new Date(Number(n));
@@ -840,8 +822,8 @@ function ie(n) {
840
822
  } catch {
841
823
  }
842
824
  }
843
- async function vi(n, e = !1) {
844
- const t = Q(n), i = await t.getIdToken(e), r = je(i);
825
+ async function gi(n, e = !1) {
826
+ const t = Y(n), i = await t.getIdToken(e), r = We(i);
845
827
  u(
846
828
  r && r.exp && r.auth_time && r.iat,
847
829
  t.auth,
@@ -852,9 +834,9 @@ async function vi(n, e = !1) {
852
834
  return {
853
835
  claims: r,
854
836
  token: i,
855
- authTime: ie(Ce(r.auth_time)),
856
- issuedAtTime: ie(Ce(r.iat)),
857
- expirationTime: ie(Ce(r.exp)),
837
+ authTime: te(Ce(r.auth_time)),
838
+ issuedAtTime: te(Ce(r.iat)),
839
+ expirationTime: te(Ce(r.exp)),
858
840
  signInProvider: o || null,
859
841
  signInSecondFactor: (s == null ? void 0 : s.sign_in_second_factor) || null
860
842
  };
@@ -862,19 +844,19 @@ async function vi(n, e = !1) {
862
844
  function Ce(n) {
863
845
  return Number(n) * 1e3;
864
846
  }
865
- function je(n) {
847
+ function We(n) {
866
848
  const [e, t, i] = n.split(".");
867
849
  if (e === void 0 || t === void 0 || i === void 0)
868
850
  return de("JWT malformed, contained fewer than 3 sections"), null;
869
851
  try {
870
- const r = Ln(t);
852
+ const r = Nn(t);
871
853
  return r ? JSON.parse(r) : (de("Failed to decode base64 JWT payload"), null);
872
854
  } catch (r) {
873
855
  return de("Caught error parsing JWT payload as JSON", r == null ? void 0 : r.toString()), null;
874
856
  }
875
857
  }
876
858
  function it(n) {
877
- const e = je(n);
859
+ const e = We(n);
878
860
  return u(
879
861
  e,
880
862
  "internal-error"
@@ -911,10 +893,10 @@ async function re(n, e, t = !1) {
911
893
  try {
912
894
  return await e;
913
895
  } catch (i) {
914
- throw i instanceof Ve && Ii(i) && n.auth.currentUser === n && await n.auth.signOut(), i;
896
+ throw i instanceof Ve && _i(i) && n.auth.currentUser === n && await n.auth.signOut(), i;
915
897
  }
916
898
  }
917
- function Ii({ code: n }) {
899
+ function _i({ code: n }) {
918
900
  return n === "auth/user-disabled" || n === "auth/user-token-expired";
919
901
  }
920
902
  /**
@@ -933,7 +915,7 @@ function Ii({ code: n }) {
933
915
  * See the License for the specific language governing permissions and
934
916
  * limitations under the License.
935
917
  */
936
- class yi {
918
+ class vi {
937
919
  constructor(e) {
938
920
  this.user = e, this.isRunning = !1, this.timerId = null, this.errorBackoff = 3e4;
939
921
  }
@@ -1000,7 +982,7 @@ class Ue {
1000
982
  this.createdAt = e, this.lastLoginAt = t, this._initializeTime();
1001
983
  }
1002
984
  _initializeTime() {
1003
- this.lastSignInTime = ie(this.lastLoginAt), this.creationTime = ie(this.createdAt);
985
+ this.lastSignInTime = te(this.lastLoginAt), this.creationTime = te(this.createdAt);
1004
986
  }
1005
987
  _copy(e) {
1006
988
  this.createdAt = e.createdAt, this.lastLoginAt = e.lastLoginAt, this._initializeTime();
@@ -1030,7 +1012,7 @@ class Ue {
1030
1012
  */
1031
1013
  async function ve(n) {
1032
1014
  var e;
1033
- const t = n.auth, i = await n.getIdToken(), r = await re(n, Ut(t, { idToken: i }));
1015
+ const t = n.auth, i = await n.getIdToken(), r = await re(n, Mt(t, { idToken: i }));
1034
1016
  u(
1035
1017
  r == null ? void 0 : r.users.length,
1036
1018
  t,
@@ -1039,7 +1021,7 @@ async function ve(n) {
1039
1021
  );
1040
1022
  const s = r.users[0];
1041
1023
  n._notifyReloadListener(s);
1042
- const o = !((e = s.providerUserInfo) === null || e === void 0) && e.length ? Dt(s.providerUserInfo) : [], c = Ti(n.providerData, o), a = n.isAnonymous, l = !(n.email && s.passwordHash) && !(c != null && c.length), h = a ? l : !1, m = {
1024
+ const o = !((e = s.providerUserInfo) === null || e === void 0) && e.length ? Ut(s.providerUserInfo) : [], c = yi(n.providerData, o), a = n.isAnonymous, l = !(n.email && s.passwordHash) && !(c != null && c.length), d = a ? l : !1, m = {
1043
1025
  uid: s.localId,
1044
1026
  displayName: s.displayName || null,
1045
1027
  photoURL: s.photoUrl || null,
@@ -1049,18 +1031,18 @@ async function ve(n) {
1049
1031
  tenantId: s.tenantId || null,
1050
1032
  providerData: c,
1051
1033
  metadata: new Ue(s.createdAt, s.lastLoginAt),
1052
- isAnonymous: h
1034
+ isAnonymous: d
1053
1035
  };
1054
1036
  Object.assign(n, m);
1055
1037
  }
1056
- async function wi(n) {
1057
- const e = Q(n);
1038
+ async function Ii(n) {
1039
+ const e = Y(n);
1058
1040
  await ve(e), await e.auth._persistUserIfCurrent(e), e.auth._notifyListenersIfCurrent(e);
1059
1041
  }
1060
- function Ti(n, e) {
1042
+ function yi(n, e) {
1061
1043
  return [...n.filter((i) => !e.some((r) => r.providerId === i.providerId)), ...e];
1062
1044
  }
1063
- function Dt(n) {
1045
+ function Ut(n) {
1064
1046
  return n.map((e) => {
1065
1047
  var { providerId: t } = e, i = $e(e, ["providerId"]);
1066
1048
  return {
@@ -1089,16 +1071,16 @@ function Dt(n) {
1089
1071
  * See the License for the specific language governing permissions and
1090
1072
  * limitations under the License.
1091
1073
  */
1092
- async function ki(n, e) {
1093
- const t = await Ot(n, {}, async () => {
1074
+ async function wi(n, e) {
1075
+ const t = await Nt(n, {}, async () => {
1094
1076
  const i = oe({
1095
1077
  grant_type: "refresh_token",
1096
1078
  refresh_token: e
1097
- }).slice(1), { tokenApiHost: r, apiKey: s } = n.config, o = Mt(n, r, "/v1/token", `key=${s}`), c = await n._getAdditionalHeaders();
1079
+ }).slice(1), { tokenApiHost: r, apiKey: s } = n.config, o = Lt(n, r, "/v1/token", `key=${s}`), c = await n._getAdditionalHeaders();
1098
1080
  return c[
1099
1081
  "Content-Type"
1100
1082
  /* HttpHeader.CONTENT_TYPE */
1101
- ] = "application/x-www-form-urlencoded", Nt.fetch()(o, {
1083
+ ] = "application/x-www-form-urlencoded", Ct.fetch()(o, {
1102
1084
  method: "POST",
1103
1085
  headers: c,
1104
1086
  body: i
@@ -1110,8 +1092,8 @@ async function ki(n, e) {
1110
1092
  refreshToken: t.refresh_token
1111
1093
  };
1112
1094
  }
1113
- async function bi(n, e) {
1114
- return Z(n, "POST", "/v2/accounts:revokeToken", Te(n, e));
1095
+ async function Ti(n, e) {
1096
+ return X(n, "POST", "/v2/accounts:revokeToken", Te(n, e));
1115
1097
  }
1116
1098
  /**
1117
1099
  * @license
@@ -1129,7 +1111,7 @@ async function bi(n, e) {
1129
1111
  * See the License for the specific language governing permissions and
1130
1112
  * limitations under the License.
1131
1113
  */
1132
- class K {
1114
+ class q {
1133
1115
  constructor() {
1134
1116
  this.refreshToken = null, this.accessToken = null, this.expirationTime = null;
1135
1117
  }
@@ -1174,14 +1156,14 @@ class K {
1174
1156
  this.refreshToken = null;
1175
1157
  }
1176
1158
  async refresh(e, t) {
1177
- const { accessToken: i, refreshToken: r, expiresIn: s } = await ki(e, t);
1159
+ const { accessToken: i, refreshToken: r, expiresIn: s } = await wi(e, t);
1178
1160
  this.updateTokensAndExpiration(i, r, Number(s));
1179
1161
  }
1180
1162
  updateTokensAndExpiration(e, t, i) {
1181
1163
  this.refreshToken = t || null, this.accessToken = e || null, this.expirationTime = Date.now() + i * 1e3;
1182
1164
  }
1183
1165
  static fromJSON(e, t) {
1184
- const { refreshToken: i, accessToken: r, expirationTime: s } = t, o = new K();
1166
+ const { refreshToken: i, accessToken: r, expirationTime: s } = t, o = new q();
1185
1167
  return i && (u(typeof i == "string", "internal-error", {
1186
1168
  appName: e
1187
1169
  }), o.refreshToken = i), r && (u(typeof r == "string", "internal-error", {
@@ -1201,10 +1183,10 @@ class K {
1201
1183
  this.accessToken = e.accessToken, this.refreshToken = e.refreshToken, this.expirationTime = e.expirationTime;
1202
1184
  }
1203
1185
  _clone() {
1204
- return Object.assign(new K(), this.toJSON());
1186
+ return Object.assign(new q(), this.toJSON());
1205
1187
  }
1206
1188
  _performRefresh() {
1207
- return C("not implemented");
1189
+ return P("not implemented");
1208
1190
  }
1209
1191
  }
1210
1192
  /**
@@ -1223,13 +1205,13 @@ class K {
1223
1205
  * See the License for the specific language governing permissions and
1224
1206
  * limitations under the License.
1225
1207
  */
1226
- function D(n, e) {
1208
+ function U(n, e) {
1227
1209
  u(typeof n == "string" || typeof n > "u", "internal-error", { appName: e });
1228
1210
  }
1229
- class N {
1211
+ class C {
1230
1212
  constructor(e) {
1231
1213
  var { uid: t, auth: i, stsTokenManager: r } = e, s = $e(e, ["uid", "auth", "stsTokenManager"]);
1232
- this.providerId = "firebase", this.proactiveRefresh = new yi(this), this.reloadUserInfo = null, this.reloadListener = null, this.uid = t, this.auth = i, this.stsTokenManager = r, this.accessToken = r.accessToken, this.displayName = s.displayName || null, this.email = s.email || null, this.emailVerified = s.emailVerified || !1, this.phoneNumber = s.phoneNumber || null, this.photoURL = s.photoURL || null, this.isAnonymous = s.isAnonymous || !1, this.tenantId = s.tenantId || null, this.providerData = s.providerData ? [...s.providerData] : [], this.metadata = new Ue(s.createdAt || void 0, s.lastLoginAt || void 0);
1214
+ this.providerId = "firebase", this.proactiveRefresh = new vi(this), this.reloadUserInfo = null, this.reloadListener = null, this.uid = t, this.auth = i, this.stsTokenManager = r, this.accessToken = r.accessToken, this.displayName = s.displayName || null, this.email = s.email || null, this.emailVerified = s.emailVerified || !1, this.phoneNumber = s.phoneNumber || null, this.photoURL = s.photoURL || null, this.isAnonymous = s.isAnonymous || !1, this.tenantId = s.tenantId || null, this.providerData = s.providerData ? [...s.providerData] : [], this.metadata = new Ue(s.createdAt || void 0, s.lastLoginAt || void 0);
1233
1215
  }
1234
1216
  async getIdToken(e) {
1235
1217
  const t = await re(this, this.stsTokenManager.getToken(this.auth, e));
@@ -1241,10 +1223,10 @@ class N {
1241
1223
  ), this.accessToken !== t && (this.accessToken = t, await this.auth._persistUserIfCurrent(this), this.auth._notifyListenersIfCurrent(this)), t;
1242
1224
  }
1243
1225
  getIdTokenResult(e) {
1244
- return vi(this, e);
1226
+ return gi(this, e);
1245
1227
  }
1246
1228
  reload() {
1247
- return wi(this);
1229
+ return Ii(this);
1248
1230
  }
1249
1231
  _assign(e) {
1250
1232
  this !== e && (u(
@@ -1255,7 +1237,7 @@ class N {
1255
1237
  ), this.displayName = e.displayName, this.photoURL = e.photoURL, this.email = e.email, this.emailVerified = e.emailVerified, this.phoneNumber = e.phoneNumber, this.isAnonymous = e.isAnonymous, this.tenantId = e.tenantId, this.providerData = e.providerData.map((t) => Object.assign({}, t)), this.metadata._copy(e.metadata), this.stsTokenManager._assign(e.stsTokenManager));
1256
1238
  }
1257
1239
  _clone(e) {
1258
- const t = new N(Object.assign(Object.assign({}, this), { auth: e, stsTokenManager: this.stsTokenManager._clone() }));
1240
+ const t = new C(Object.assign(Object.assign({}, this), { auth: e, stsTokenManager: this.stsTokenManager._clone() }));
1259
1241
  return t.metadata._copy(this.metadata), t;
1260
1242
  }
1261
1243
  _onReload(e) {
@@ -1280,10 +1262,10 @@ class N {
1280
1262
  e.idToken && e.idToken !== this.stsTokenManager.accessToken && (this.stsTokenManager.updateFromServerResponse(e), i = !0), t && await ve(this), await this.auth._persistUserIfCurrent(this), i && this.auth._notifyListenersIfCurrent(this);
1281
1263
  }
1282
1264
  async delete() {
1283
- if (P(this.auth.app))
1284
- return Promise.reject(H(this.auth));
1265
+ if (A(this.auth.app))
1266
+ return Promise.reject($(this.auth));
1285
1267
  const e = await this.getIdToken();
1286
- return await re(this, _i(this.auth, { idToken: e })), this.stsTokenManager.clearRefreshToken(), this.auth.signOut();
1268
+ return await re(this, mi(this.auth, { idToken: e })), this.stsTokenManager.clearRefreshToken(), this.auth.signOut();
1287
1269
  }
1288
1270
  toJSON() {
1289
1271
  return Object.assign(Object.assign({
@@ -1310,21 +1292,21 @@ class N {
1310
1292
  return this.stsTokenManager.refreshToken || "";
1311
1293
  }
1312
1294
  static _fromJSON(e, t) {
1313
- var i, r, s, o, c, a, l, h;
1314
- const m = (i = t.displayName) !== null && i !== void 0 ? i : void 0, v = (r = t.email) !== null && r !== void 0 ? r : void 0, y = (s = t.phoneNumber) !== null && s !== void 0 ? s : void 0, f = (o = t.photoURL) !== null && o !== void 0 ? o : void 0, w = (c = t.tenantId) !== null && c !== void 0 ? c : void 0, d = (a = t._redirectEventId) !== null && a !== void 0 ? a : void 0, g = (l = t.createdAt) !== null && l !== void 0 ? l : void 0, b = (h = t.lastLoginAt) !== null && h !== void 0 ? h : void 0, { uid: T, emailVerified: Ke, isAnonymous: Je, providerData: Re, stsTokenManager: Ye } = t;
1295
+ var i, r, s, o, c, a, l, d;
1296
+ const m = (i = t.displayName) !== null && i !== void 0 ? i : void 0, f = (r = t.email) !== null && r !== void 0 ? r : void 0, y = (s = t.phoneNumber) !== null && s !== void 0 ? s : void 0, _ = (o = t.photoURL) !== null && o !== void 0 ? o : void 0, h = (c = t.tenantId) !== null && c !== void 0 ? c : void 0, I = (a = t._redirectEventId) !== null && a !== void 0 ? a : void 0, T = (l = t.createdAt) !== null && l !== void 0 ? l : void 0, M = (d = t.lastLoginAt) !== null && d !== void 0 ? d : void 0, { uid: k, emailVerified: Ke, isAnonymous: Je, providerData: Re, stsTokenManager: Ye } = t;
1315
1297
  u(
1316
- T && Ye,
1298
+ k && Ye,
1317
1299
  e,
1318
1300
  "internal-error"
1319
1301
  /* AuthErrorCode.INTERNAL_ERROR */
1320
1302
  );
1321
- const an = K.fromJSON(this.name, Ye);
1303
+ const on = q.fromJSON(this.name, Ye);
1322
1304
  u(
1323
- typeof T == "string",
1305
+ typeof k == "string",
1324
1306
  e,
1325
1307
  "internal-error"
1326
1308
  /* AuthErrorCode.INTERNAL_ERROR */
1327
- ), D(m, e.name), D(v, e.name), u(
1309
+ ), U(m, e.name), U(f, e.name), u(
1328
1310
  typeof Ke == "boolean",
1329
1311
  e,
1330
1312
  "internal-error"
@@ -1334,22 +1316,22 @@ class N {
1334
1316
  e,
1335
1317
  "internal-error"
1336
1318
  /* AuthErrorCode.INTERNAL_ERROR */
1337
- ), D(y, e.name), D(f, e.name), D(w, e.name), D(d, e.name), D(g, e.name), D(b, e.name);
1338
- const Ae = new N({
1339
- uid: T,
1319
+ ), U(y, e.name), U(_, e.name), U(h, e.name), U(I, e.name), U(T, e.name), U(M, e.name);
1320
+ const Ae = new C({
1321
+ uid: k,
1340
1322
  auth: e,
1341
- email: v,
1323
+ email: f,
1342
1324
  emailVerified: Ke,
1343
1325
  displayName: m,
1344
1326
  isAnonymous: Je,
1345
- photoURL: f,
1327
+ photoURL: _,
1346
1328
  phoneNumber: y,
1347
- tenantId: w,
1348
- stsTokenManager: an,
1349
- createdAt: g,
1350
- lastLoginAt: b
1329
+ tenantId: h,
1330
+ stsTokenManager: on,
1331
+ createdAt: T,
1332
+ lastLoginAt: M
1351
1333
  });
1352
- return Re && Array.isArray(Re) && (Ae.providerData = Re.map((cn) => Object.assign({}, cn))), d && (Ae._redirectEventId = d), Ae;
1334
+ return Re && Array.isArray(Re) && (Ae.providerData = Re.map((an) => Object.assign({}, an))), I && (Ae._redirectEventId = I), Ae;
1353
1335
  }
1354
1336
  /**
1355
1337
  * Initialize a User from an idToken server response
@@ -1357,9 +1339,9 @@ class N {
1357
1339
  * @param idTokenResponse
1358
1340
  */
1359
1341
  static async _fromIdTokenResponse(e, t, i = !1) {
1360
- const r = new K();
1342
+ const r = new q();
1361
1343
  r.updateFromServerResponse(t);
1362
- const s = new N({
1344
+ const s = new C({
1363
1345
  uid: t.localId,
1364
1346
  auth: e,
1365
1347
  stsTokenManager: r,
@@ -1379,9 +1361,9 @@ class N {
1379
1361
  "internal-error"
1380
1362
  /* AuthErrorCode.INTERNAL_ERROR */
1381
1363
  );
1382
- const s = r.providerUserInfo !== void 0 ? Dt(r.providerUserInfo) : [], o = !(r.email && r.passwordHash) && !(s != null && s.length), c = new K();
1364
+ const s = r.providerUserInfo !== void 0 ? Ut(r.providerUserInfo) : [], o = !(r.email && r.passwordHash) && !(s != null && s.length), c = new q();
1383
1365
  c.updateFromIdToken(i);
1384
- const a = new N({
1366
+ const a = new C({
1385
1367
  uid: r.localId,
1386
1368
  auth: e,
1387
1369
  stsTokenManager: c,
@@ -1418,10 +1400,10 @@ class N {
1418
1400
  * limitations under the License.
1419
1401
  */
1420
1402
  const rt = /* @__PURE__ */ new Map();
1421
- function O(n) {
1422
- M(n instanceof Function, "Expected a class definition");
1403
+ function N(n) {
1404
+ L(n instanceof Function, "Expected a class definition");
1423
1405
  let e = rt.get(n);
1424
- return e ? (M(e instanceof n, "Instance stored in cache mismatched with class"), e) : (e = new n(), rt.set(n, e), e);
1406
+ return e ? (L(e instanceof n, "Instance stored in cache mismatched with class"), e) : (e = new n(), rt.set(n, e), e);
1425
1407
  }
1426
1408
  /**
1427
1409
  * @license
@@ -1439,7 +1421,7 @@ function O(n) {
1439
1421
  * See the License for the specific language governing permissions and
1440
1422
  * limitations under the License.
1441
1423
  */
1442
- class xt {
1424
+ class Dt {
1443
1425
  constructor() {
1444
1426
  this.type = "NONE", this.storage = {};
1445
1427
  }
@@ -1461,8 +1443,8 @@ class xt {
1461
1443
  _removeListener(e, t) {
1462
1444
  }
1463
1445
  }
1464
- xt.type = "NONE";
1465
- const st = xt;
1446
+ Dt.type = "NONE";
1447
+ const st = Dt;
1466
1448
  /**
1467
1449
  * @license
1468
1450
  * Copyright 2019 Google LLC
@@ -1482,7 +1464,7 @@ const st = xt;
1482
1464
  function he(n, e, t) {
1483
1465
  return `firebase:${n}:${e}:${t}`;
1484
1466
  }
1485
- class J {
1467
+ class K {
1486
1468
  constructor(e, t, i) {
1487
1469
  this.persistence = e, this.auth = t, this.userKey = i;
1488
1470
  const { config: r, name: s } = this.auth;
@@ -1493,7 +1475,7 @@ class J {
1493
1475
  }
1494
1476
  async getCurrentUser() {
1495
1477
  const e = await this.persistence._get(this.fullUserKey);
1496
- return e ? N._fromJSON(this.auth, e) : null;
1478
+ return e ? C._fromJSON(this.auth, e) : null;
1497
1479
  }
1498
1480
  removeCurrentUser() {
1499
1481
  return this.persistence._remove(this.fullUserKey);
@@ -1513,32 +1495,32 @@ class J {
1513
1495
  }
1514
1496
  static async create(e, t, i = "authUser") {
1515
1497
  if (!t.length)
1516
- return new J(O(st), e, i);
1498
+ return new K(N(st), e, i);
1517
1499
  const r = (await Promise.all(t.map(async (l) => {
1518
1500
  if (await l._isAvailable())
1519
1501
  return l;
1520
1502
  }))).filter((l) => l);
1521
- let s = r[0] || O(st);
1503
+ let s = r[0] || N(st);
1522
1504
  const o = he(i, e.config.apiKey, e.name);
1523
1505
  let c = null;
1524
1506
  for (const l of t)
1525
1507
  try {
1526
- const h = await l._get(o);
1527
- if (h) {
1528
- const m = N._fromJSON(e, h);
1508
+ const d = await l._get(o);
1509
+ if (d) {
1510
+ const m = C._fromJSON(e, d);
1529
1511
  l !== s && (c = m), s = l;
1530
1512
  break;
1531
1513
  }
1532
1514
  } catch {
1533
1515
  }
1534
1516
  const a = r.filter((l) => l._shouldAllowMigration);
1535
- return !s._shouldAllowMigration || !a.length ? new J(s, e, i) : (s = a[0], c && await s._set(o, c.toJSON()), await Promise.all(t.map(async (l) => {
1517
+ return !s._shouldAllowMigration || !a.length ? new K(s, e, i) : (s = a[0], c && await s._set(o, c.toJSON()), await Promise.all(t.map(async (l) => {
1536
1518
  if (l !== s)
1537
1519
  try {
1538
1520
  await l._remove(o);
1539
1521
  } catch {
1540
1522
  }
1541
- })), new J(s, e, i));
1523
+ })), new K(s, e, i));
1542
1524
  }
1543
1525
  }
1544
1526
  /**
@@ -1561,25 +1543,25 @@ function ot(n) {
1561
1543
  const e = n.toLowerCase();
1562
1544
  if (e.includes("opera/") || e.includes("opr/") || e.includes("opios/"))
1563
1545
  return "Opera";
1564
- if ($t(e))
1546
+ if (Vt(e))
1565
1547
  return "IEMobile";
1566
1548
  if (e.includes("msie") || e.includes("trident/"))
1567
1549
  return "IE";
1568
1550
  if (e.includes("edge/"))
1569
1551
  return "Edge";
1570
- if (Ft(e))
1552
+ if (xt(e))
1571
1553
  return "Firefox";
1572
1554
  if (e.includes("silk/"))
1573
1555
  return "Silk";
1574
- if (Wt(e))
1556
+ if (Ht(e))
1575
1557
  return "Blackberry";
1576
1558
  if (jt(e))
1577
1559
  return "Webos";
1578
1560
  if (Be(e))
1579
1561
  return "Safari";
1580
- if ((e.includes("chrome/") || Vt(e)) && !e.includes("edge/"))
1562
+ if ((e.includes("chrome/") || Ft(e)) && !e.includes("edge/"))
1581
1563
  return "Chrome";
1582
- if (Ht(e))
1564
+ if ($t(e))
1583
1565
  return "Android";
1584
1566
  {
1585
1567
  const t = /([a-zA-Z\d\.]+)\/[a-zA-Z\d\.]*$/, i = n.match(t);
@@ -1588,42 +1570,42 @@ function ot(n) {
1588
1570
  }
1589
1571
  return "Other";
1590
1572
  }
1591
- function Ft(n = k()) {
1573
+ function xt(n = w()) {
1592
1574
  return /firefox\//i.test(n);
1593
1575
  }
1594
- function Be(n = k()) {
1576
+ function Be(n = w()) {
1595
1577
  const e = n.toLowerCase();
1596
1578
  return e.includes("safari/") && !e.includes("chrome/") && !e.includes("crios/") && !e.includes("android");
1597
1579
  }
1598
- function Vt(n = k()) {
1580
+ function Ft(n = w()) {
1599
1581
  return /crios\//i.test(n);
1600
1582
  }
1601
- function $t(n = k()) {
1583
+ function Vt(n = w()) {
1602
1584
  return /iemobile/i.test(n);
1603
1585
  }
1604
- function Ht(n = k()) {
1586
+ function $t(n = w()) {
1605
1587
  return /android/i.test(n);
1606
1588
  }
1607
- function Wt(n = k()) {
1589
+ function Ht(n = w()) {
1608
1590
  return /blackberry/i.test(n);
1609
1591
  }
1610
- function jt(n = k()) {
1592
+ function jt(n = w()) {
1611
1593
  return /webos/i.test(n);
1612
1594
  }
1613
- function ke(n = k()) {
1595
+ function ke(n = w()) {
1614
1596
  return /iphone|ipad|ipod/i.test(n) || /macintosh/i.test(n) && /mobile/i.test(n);
1615
1597
  }
1616
- function Ei(n = k()) {
1598
+ function ki(n = w()) {
1617
1599
  var e;
1618
1600
  return ke(n) && !!(!((e = window.navigator) === null || e === void 0) && e.standalone);
1619
1601
  }
1620
- function Si() {
1621
- return Mn() && document.documentMode === 10;
1602
+ function bi() {
1603
+ return On() && document.documentMode === 10;
1622
1604
  }
1623
- function Bt(n = k()) {
1624
- return ke(n) || Ht(n) || jt(n) || Wt(n) || /windows phone/i.test(n) || $t(n);
1605
+ function Wt(n = w()) {
1606
+ return ke(n) || $t(n) || jt(n) || Ht(n) || /windows phone/i.test(n) || Vt(n);
1625
1607
  }
1626
- function Ri() {
1608
+ function Ei() {
1627
1609
  try {
1628
1610
  return !!(window && window !== window.top);
1629
1611
  } catch {
@@ -1646,14 +1628,14 @@ function Ri() {
1646
1628
  * See the License for the specific language governing permissions and
1647
1629
  * limitations under the License.
1648
1630
  */
1649
- function Gt(n, e = []) {
1631
+ function Bt(n, e = []) {
1650
1632
  let t;
1651
1633
  switch (n) {
1652
1634
  case "Browser":
1653
- t = ot(k());
1635
+ t = ot(w());
1654
1636
  break;
1655
1637
  case "Worker":
1656
- t = `${ot(k())}-${n}`;
1638
+ t = `${ot(w())}-${n}`;
1657
1639
  break;
1658
1640
  default:
1659
1641
  t = n;
@@ -1677,7 +1659,7 @@ function Gt(n, e = []) {
1677
1659
  * See the License for the specific language governing permissions and
1678
1660
  * limitations under the License.
1679
1661
  */
1680
- class Ai {
1662
+ class Si {
1681
1663
  constructor(e) {
1682
1664
  this.auth = e, this.queue = [];
1683
1665
  }
@@ -1732,8 +1714,8 @@ class Ai {
1732
1714
  * See the License for the specific language governing permissions and
1733
1715
  * limitations under the License.
1734
1716
  */
1735
- async function Pi(n, e = {}) {
1736
- return Z(n, "GET", "/v2/passwordPolicy", Te(n, e));
1717
+ async function Ri(n, e = {}) {
1718
+ return X(n, "GET", "/v2/passwordPolicy", Te(n, e));
1737
1719
  }
1738
1720
  /**
1739
1721
  * @license
@@ -1751,12 +1733,12 @@ async function Pi(n, e = {}) {
1751
1733
  * See the License for the specific language governing permissions and
1752
1734
  * limitations under the License.
1753
1735
  */
1754
- const Ci = 6;
1755
- class Ni {
1736
+ const Ai = 6;
1737
+ class Pi {
1756
1738
  constructor(e) {
1757
1739
  var t, i, r, s;
1758
1740
  const o = e.customStrengthOptions;
1759
- this.customStrengthOptions = {}, this.customStrengthOptions.minPasswordLength = (t = o.minPasswordLength) !== null && t !== void 0 ? t : Ci, o.maxPasswordLength && (this.customStrengthOptions.maxPasswordLength = o.maxPasswordLength), o.containsLowercaseCharacter !== void 0 && (this.customStrengthOptions.containsLowercaseLetter = o.containsLowercaseCharacter), o.containsUppercaseCharacter !== void 0 && (this.customStrengthOptions.containsUppercaseLetter = o.containsUppercaseCharacter), o.containsNumericCharacter !== void 0 && (this.customStrengthOptions.containsNumericCharacter = o.containsNumericCharacter), o.containsNonAlphanumericCharacter !== void 0 && (this.customStrengthOptions.containsNonAlphanumericCharacter = o.containsNonAlphanumericCharacter), this.enforcementState = e.enforcementState, this.enforcementState === "ENFORCEMENT_STATE_UNSPECIFIED" && (this.enforcementState = "OFF"), this.allowedNonAlphanumericCharacters = (r = (i = e.allowedNonAlphanumericCharacters) === null || i === void 0 ? void 0 : i.join("")) !== null && r !== void 0 ? r : "", this.forceUpgradeOnSignin = (s = e.forceUpgradeOnSignin) !== null && s !== void 0 ? s : !1, this.schemaVersion = e.schemaVersion;
1741
+ this.customStrengthOptions = {}, this.customStrengthOptions.minPasswordLength = (t = o.minPasswordLength) !== null && t !== void 0 ? t : Ai, o.maxPasswordLength && (this.customStrengthOptions.maxPasswordLength = o.maxPasswordLength), o.containsLowercaseCharacter !== void 0 && (this.customStrengthOptions.containsLowercaseLetter = o.containsLowercaseCharacter), o.containsUppercaseCharacter !== void 0 && (this.customStrengthOptions.containsUppercaseLetter = o.containsUppercaseCharacter), o.containsNumericCharacter !== void 0 && (this.customStrengthOptions.containsNumericCharacter = o.containsNumericCharacter), o.containsNonAlphanumericCharacter !== void 0 && (this.customStrengthOptions.containsNonAlphanumericCharacter = o.containsNonAlphanumericCharacter), this.enforcementState = e.enforcementState, this.enforcementState === "ENFORCEMENT_STATE_UNSPECIFIED" && (this.enforcementState = "OFF"), this.allowedNonAlphanumericCharacters = (r = (i = e.allowedNonAlphanumericCharacters) === null || i === void 0 ? void 0 : i.join("")) !== null && r !== void 0 ? r : "", this.forceUpgradeOnSignin = (s = e.forceUpgradeOnSignin) !== null && s !== void 0 ? s : !1, this.schemaVersion = e.schemaVersion;
1760
1742
  }
1761
1743
  validatePassword(e) {
1762
1744
  var t, i, r, s, o, c;
@@ -1839,14 +1821,14 @@ class Ni {
1839
1821
  * See the License for the specific language governing permissions and
1840
1822
  * limitations under the License.
1841
1823
  */
1842
- class Oi {
1824
+ class Ci {
1843
1825
  constructor(e, t, i, r) {
1844
- this.app = e, this.heartbeatServiceProvider = t, this.appCheckServiceProvider = i, this.config = r, this.currentUser = null, this.emulatorConfig = null, this.operations = Promise.resolve(), this.authStateSubscription = new at(this), this.idTokenSubscription = new at(this), this.beforeStateQueue = new Ai(this), this.redirectUser = null, this.isProactiveRefreshEnabled = !1, this.EXPECTED_PASSWORD_POLICY_SCHEMA_VERSION = 1, this._canInitEmulator = !0, this._isInitialized = !1, this._deleted = !1, this._initializationPromise = null, this._popupRedirectResolver = null, this._errorFactory = Pt, this._agentRecaptchaConfig = null, this._tenantRecaptchaConfigs = {}, this._projectPasswordPolicy = null, this._tenantPasswordPolicies = {}, this.lastNotifiedUid = void 0, this.languageCode = null, this.tenantId = null, this.settings = { appVerificationDisabledForTesting: !1 }, this.frameworks = [], this.name = e.name, this.clientVersion = r.sdkClientVersion;
1826
+ this.app = e, this.heartbeatServiceProvider = t, this.appCheckServiceProvider = i, this.config = r, this.currentUser = null, this.emulatorConfig = null, this.operations = Promise.resolve(), this.authStateSubscription = new at(this), this.idTokenSubscription = new at(this), this.beforeStateQueue = new Si(this), this.redirectUser = null, this.isProactiveRefreshEnabled = !1, this.EXPECTED_PASSWORD_POLICY_SCHEMA_VERSION = 1, this._canInitEmulator = !0, this._isInitialized = !1, this._deleted = !1, this._initializationPromise = null, this._popupRedirectResolver = null, this._errorFactory = At, this._agentRecaptchaConfig = null, this._tenantRecaptchaConfigs = {}, this._projectPasswordPolicy = null, this._tenantPasswordPolicies = {}, this.lastNotifiedUid = void 0, this.languageCode = null, this.tenantId = null, this.settings = { appVerificationDisabledForTesting: !1 }, this.frameworks = [], this.name = e.name, this.clientVersion = r.sdkClientVersion;
1845
1827
  }
1846
1828
  _initializeWithPersistence(e, t) {
1847
- return t && (this._popupRedirectResolver = O(t)), this._initializationPromise = this.queue(async () => {
1829
+ return t && (this._popupRedirectResolver = N(t)), this._initializationPromise = this.queue(async () => {
1848
1830
  var i, r;
1849
- if (!this._deleted && (this.persistenceManager = await J.create(this, e), !this._deleted)) {
1831
+ if (!this._deleted && (this.persistenceManager = await K.create(this, e), !this._deleted)) {
1850
1832
  if (!((i = this._popupRedirectResolver) === null || i === void 0) && i._shouldInitProactively)
1851
1833
  try {
1852
1834
  await this._popupRedirectResolver._initialize(this);
@@ -1877,7 +1859,7 @@ class Oi {
1877
1859
  }
1878
1860
  async initializeCurrentUserFromIdToken(e) {
1879
1861
  try {
1880
- const t = await Ut(this, { idToken: e }), i = await N._fromGetAccountInfoResponse(this, t, e);
1862
+ const t = await Mt(this, { idToken: e }), i = await C._fromGetAccountInfoResponse(this, t, e);
1881
1863
  await this.directlySetCurrentUser(i);
1882
1864
  } catch (t) {
1883
1865
  console.warn("FirebaseServerApp could not login user with provided authIdToken: ", t), await this.directlySetCurrentUser(null);
@@ -1885,7 +1867,7 @@ class Oi {
1885
1867
  }
1886
1868
  async initializeCurrentUser(e) {
1887
1869
  var t;
1888
- if (P(this.app)) {
1870
+ if (A(this.app)) {
1889
1871
  const o = this.app.settings.authIdToken;
1890
1872
  return o ? new Promise((c) => {
1891
1873
  setTimeout(() => this.initializeCurrentUserFromIdToken(o).then(c, c));
@@ -1935,15 +1917,15 @@ class Oi {
1935
1917
  return this.directlySetCurrentUser(e);
1936
1918
  }
1937
1919
  useDeviceLanguage() {
1938
- this.languageCode = fi();
1920
+ this.languageCode = di();
1939
1921
  }
1940
1922
  async _delete() {
1941
1923
  this._deleted = !0;
1942
1924
  }
1943
1925
  async updateCurrentUser(e) {
1944
- if (P(this.app))
1945
- return Promise.reject(H(this));
1946
- const t = e ? Q(e) : null;
1926
+ if (A(this.app))
1927
+ return Promise.reject($(this));
1928
+ const t = e ? Y(e) : null;
1947
1929
  return t && u(
1948
1930
  t.auth.config.apiKey === this.config.apiKey,
1949
1931
  this,
@@ -1963,15 +1945,15 @@ class Oi {
1963
1945
  });
1964
1946
  }
1965
1947
  async signOut() {
1966
- return P(this.app) ? Promise.reject(H(this)) : (await this.beforeStateQueue.runMiddleware(null), (this.redirectPersistenceManager || this._popupRedirectResolver) && await this._setRedirectUser(null), this._updateCurrentUser(
1948
+ return A(this.app) ? Promise.reject($(this)) : (await this.beforeStateQueue.runMiddleware(null), (this.redirectPersistenceManager || this._popupRedirectResolver) && await this._setRedirectUser(null), this._updateCurrentUser(
1967
1949
  null,
1968
1950
  /* skipBeforeStateCallbacks */
1969
1951
  !0
1970
1952
  ));
1971
1953
  }
1972
1954
  setPersistence(e) {
1973
- return P(this.app) ? Promise.reject(H(this)) : this.queue(async () => {
1974
- await this.assertedPersistence.setPersistence(O(e));
1955
+ return A(this.app) ? Promise.reject($(this)) : this.queue(async () => {
1956
+ await this.assertedPersistence.setPersistence(N(e));
1975
1957
  });
1976
1958
  }
1977
1959
  _getRecaptchaConfig() {
@@ -1986,7 +1968,7 @@ class Oi {
1986
1968
  return this.tenantId === null ? this._projectPasswordPolicy : this._tenantPasswordPolicies[this.tenantId];
1987
1969
  }
1988
1970
  async _updatePasswordPolicy() {
1989
- const e = await Pi(this), t = new Ni(e);
1971
+ const e = await Ri(this), t = new Pi(e);
1990
1972
  this.tenantId === null ? this._projectPasswordPolicy = t : this._tenantPasswordPolicies[this.tenantId] = t;
1991
1973
  }
1992
1974
  _getPersistence() {
@@ -2026,7 +2008,7 @@ class Oi {
2026
2008
  token: e,
2027
2009
  idToken: t
2028
2010
  };
2029
- this.tenantId != null && (i.tenantId = this.tenantId), await bi(this, i);
2011
+ this.tenantId != null && (i.tenantId = this.tenantId), await Ti(this, i);
2030
2012
  }
2031
2013
  }
2032
2014
  toJSON() {
@@ -2044,15 +2026,15 @@ class Oi {
2044
2026
  }
2045
2027
  async getOrInitRedirectPersistenceManager(e) {
2046
2028
  if (!this.redirectPersistenceManager) {
2047
- const t = e && O(e) || this._popupRedirectResolver;
2029
+ const t = e && N(e) || this._popupRedirectResolver;
2048
2030
  u(
2049
2031
  t,
2050
2032
  this,
2051
2033
  "argument-error"
2052
2034
  /* AuthErrorCode.ARGUMENT_ERROR */
2053
- ), this.redirectPersistenceManager = await J.create(
2035
+ ), this.redirectPersistenceManager = await K.create(
2054
2036
  this,
2055
- [O(t._redirectPersistence)],
2037
+ [N(t._redirectPersistence)],
2056
2038
  "redirectUser"
2057
2039
  /* KeyName.REDIRECT_USER */
2058
2040
  ), this.redirectUser = await this.redirectPersistenceManager.getCurrentUser();
@@ -2139,7 +2121,7 @@ class Oi {
2139
2121
  ), this.persistenceManager;
2140
2122
  }
2141
2123
  _logFramework(e) {
2142
- !e || this.frameworks.includes(e) || (this.frameworks.push(e), this.frameworks.sort(), this.clientVersion = Gt(this.config.clientPlatform, this._getFrameworks()));
2124
+ !e || this.frameworks.includes(e) || (this.frameworks.push(e), this.frameworks.sort(), this.clientVersion = Bt(this.config.clientPlatform, this._getFrameworks()));
2143
2125
  }
2144
2126
  _getFrameworks() {
2145
2127
  return this.frameworks;
@@ -2169,15 +2151,15 @@ class Oi {
2169
2151
  async _getAppCheckToken() {
2170
2152
  var e;
2171
2153
  const t = await ((e = this.appCheckServiceProvider.getImmediate({ optional: !0 })) === null || e === void 0 ? void 0 : e.getToken());
2172
- return t != null && t.error && ui(`Error while retrieving App Check token: ${t.error}`), t == null ? void 0 : t.token;
2154
+ return t != null && t.error && ci(`Error while retrieving App Check token: ${t.error}`), t == null ? void 0 : t.token;
2173
2155
  }
2174
2156
  }
2175
2157
  function be(n) {
2176
- return Q(n);
2158
+ return Y(n);
2177
2159
  }
2178
2160
  class at {
2179
2161
  constructor(e) {
2180
- this.auth = e, this.observer = null, this.addObserver = Pn((t) => this.observer = t);
2162
+ this.auth = e, this.observer = null, this.addObserver = Rn((t) => this.observer = t);
2181
2163
  }
2182
2164
  get next() {
2183
2165
  return u(
@@ -2212,16 +2194,16 @@ let Ge = {
2212
2194
  recaptchaEnterpriseScript: "",
2213
2195
  gapiScript: ""
2214
2196
  };
2215
- function Li(n) {
2197
+ function Ni(n) {
2216
2198
  Ge = n;
2217
2199
  }
2218
- function Mi(n) {
2200
+ function Oi(n) {
2219
2201
  return Ge.loadJS(n);
2220
2202
  }
2221
- function Ui() {
2203
+ function Li() {
2222
2204
  return Ge.gapiScript;
2223
2205
  }
2224
- function Di(n) {
2206
+ function Mi(n) {
2225
2207
  return `__${n}${Math.floor(Math.random() * 1e6)}`;
2226
2208
  }
2227
2209
  /**
@@ -2240,13 +2222,13 @@ function Di(n) {
2240
2222
  * See the License for the specific language governing permissions and
2241
2223
  * limitations under the License.
2242
2224
  */
2243
- function xi(n, e) {
2244
- const t = Et(n, "auth");
2225
+ function Ui(n, e) {
2226
+ const t = bt(n, "auth");
2245
2227
  if (t.isInitialized()) {
2246
2228
  const r = t.getImmediate(), s = t.getOptions();
2247
- if (On(s, e ?? {}))
2229
+ if (Cn(s, e ?? {}))
2248
2230
  return r;
2249
- L(
2231
+ O(
2250
2232
  r,
2251
2233
  "already-initialized"
2252
2234
  /* AuthErrorCode.ALREADY_INITIALIZED */
@@ -2254,11 +2236,11 @@ function xi(n, e) {
2254
2236
  }
2255
2237
  return t.initialize({ options: e });
2256
2238
  }
2257
- function Fi(n, e) {
2258
- const t = (e == null ? void 0 : e.persistence) || [], i = (Array.isArray(t) ? t : [t]).map(O);
2239
+ function Di(n, e) {
2240
+ const t = (e == null ? void 0 : e.persistence) || [], i = (Array.isArray(t) ? t : [t]).map(N);
2259
2241
  e != null && e.errorMap && n._updateErrorMap(e.errorMap), n._initializeWithPersistence(i, e == null ? void 0 : e.popupRedirectResolver);
2260
2242
  }
2261
- function Vi(n, e, t) {
2243
+ function xi(n, e, t) {
2262
2244
  const i = be(n);
2263
2245
  u(
2264
2246
  i._canInitEmulator,
@@ -2271,20 +2253,20 @@ function Vi(n, e, t) {
2271
2253
  "invalid-emulator-scheme"
2272
2254
  /* AuthErrorCode.INVALID_EMULATOR_SCHEME */
2273
2255
  );
2274
- const r = !1, s = zt(e), { host: o, port: c } = $i(e), a = c === null ? "" : `:${c}`;
2256
+ const r = !1, s = Gt(e), { host: o, port: c } = Fi(e), a = c === null ? "" : `:${c}`;
2275
2257
  i.config.emulator = { url: `${s}//${o}${a}/` }, i.settings.appVerificationDisabledForTesting = !0, i.emulatorConfig = Object.freeze({
2276
2258
  host: o,
2277
2259
  port: c,
2278
2260
  protocol: s.replace(":", ""),
2279
2261
  options: Object.freeze({ disableWarnings: r })
2280
- }), Hi();
2262
+ }), Vi();
2281
2263
  }
2282
- function zt(n) {
2264
+ function Gt(n) {
2283
2265
  const e = n.indexOf(":");
2284
2266
  return e < 0 ? "" : n.substr(0, e + 1);
2285
2267
  }
2286
- function $i(n) {
2287
- const e = zt(n), t = /(\/\/)?([^?#/]+)/.exec(n.substr(e.length));
2268
+ function Fi(n) {
2269
+ const e = Gt(n), t = /(\/\/)?([^?#/]+)/.exec(n.substr(e.length));
2288
2270
  if (!t)
2289
2271
  return { host: "", port: null };
2290
2272
  const i = t[2].split("@").pop() || "", r = /^(\[[^\]]+\])(:|$)/.exec(i);
@@ -2302,7 +2284,7 @@ function ct(n) {
2302
2284
  const e = Number(n);
2303
2285
  return isNaN(e) ? null : e;
2304
2286
  }
2305
- function Hi() {
2287
+ function Vi() {
2306
2288
  function n() {
2307
2289
  const e = document.createElement("p"), t = e.style;
2308
2290
  e.innerText = "Running in emulator mode. Do not use with production credentials.", t.position = "fixed", t.width = "100%", t.backgroundColor = "#ffffff", t.border = ".1em solid #000000", t.color = "#b50000", t.bottom = "0px", t.left = "0px", t.margin = "0px", t.zIndex = "10000", t.textAlign = "center", e.classList.add("firebase-emulator-warning"), document.body.appendChild(e);
@@ -2325,7 +2307,7 @@ function Hi() {
2325
2307
  * See the License for the specific language governing permissions and
2326
2308
  * limitations under the License.
2327
2309
  */
2328
- class qt {
2310
+ class zt {
2329
2311
  /** @internal */
2330
2312
  constructor(e, t) {
2331
2313
  this.providerId = e, this.signInMethod = t;
@@ -2336,19 +2318,19 @@ class qt {
2336
2318
  * @returns a JSON-serializable representation of this object.
2337
2319
  */
2338
2320
  toJSON() {
2339
- return C("not implemented");
2321
+ return P("not implemented");
2340
2322
  }
2341
2323
  /** @internal */
2342
2324
  _getIdTokenResponse(e) {
2343
- return C("not implemented");
2325
+ return P("not implemented");
2344
2326
  }
2345
2327
  /** @internal */
2346
2328
  _linkToIdToken(e, t) {
2347
- return C("not implemented");
2329
+ return P("not implemented");
2348
2330
  }
2349
2331
  /** @internal */
2350
2332
  _getReauthenticationResolver(e) {
2351
- return C("not implemented");
2333
+ return P("not implemented");
2352
2334
  }
2353
2335
  }
2354
2336
  /**
@@ -2367,8 +2349,8 @@ class qt {
2367
2349
  * See the License for the specific language governing permissions and
2368
2350
  * limitations under the License.
2369
2351
  */
2370
- async function Y(n, e) {
2371
- return Lt(n, "POST", "/v1/accounts:signInWithIdp", Te(n, e));
2352
+ async function J(n, e) {
2353
+ return Ot(n, "POST", "/v1/accounts:signInWithIdp", Te(n, e));
2372
2354
  }
2373
2355
  /**
2374
2356
  * @license
@@ -2386,15 +2368,15 @@ async function Y(n, e) {
2386
2368
  * See the License for the specific language governing permissions and
2387
2369
  * limitations under the License.
2388
2370
  */
2389
- const Wi = "http://localhost";
2390
- class B extends qt {
2371
+ const $i = "http://localhost";
2372
+ class W extends zt {
2391
2373
  constructor() {
2392
2374
  super(...arguments), this.pendingToken = null;
2393
2375
  }
2394
2376
  /** @internal */
2395
2377
  static _fromParams(e) {
2396
- const t = new B(e.providerId, e.signInMethod);
2397
- return e.idToken || e.accessToken ? (e.idToken && (t.idToken = e.idToken), e.accessToken && (t.accessToken = e.accessToken), e.nonce && !e.pendingToken && (t.nonce = e.nonce), e.pendingToken && (t.pendingToken = e.pendingToken)) : e.oauthToken && e.oauthTokenSecret ? (t.accessToken = e.oauthToken, t.secret = e.oauthTokenSecret) : L(
2378
+ const t = new W(e.providerId, e.signInMethod);
2379
+ return e.idToken || e.accessToken ? (e.idToken && (t.idToken = e.idToken), e.accessToken && (t.accessToken = e.accessToken), e.nonce && !e.pendingToken && (t.nonce = e.nonce), e.pendingToken && (t.pendingToken = e.pendingToken)) : e.oauthToken && e.oauthTokenSecret ? (t.accessToken = e.oauthToken, t.secret = e.oauthTokenSecret) : O(
2398
2380
  "argument-error"
2399
2381
  /* AuthErrorCode.ARGUMENT_ERROR */
2400
2382
  ), t;
@@ -2424,27 +2406,27 @@ class B extends qt {
2424
2406
  const t = typeof e == "string" ? JSON.parse(e) : e, { providerId: i, signInMethod: r } = t, s = $e(t, ["providerId", "signInMethod"]);
2425
2407
  if (!i || !r)
2426
2408
  return null;
2427
- const o = new B(i, r);
2409
+ const o = new W(i, r);
2428
2410
  return o.idToken = s.idToken || void 0, o.accessToken = s.accessToken || void 0, o.secret = s.secret, o.nonce = s.nonce, o.pendingToken = s.pendingToken || null, o;
2429
2411
  }
2430
2412
  /** @internal */
2431
2413
  _getIdTokenResponse(e) {
2432
2414
  const t = this.buildRequest();
2433
- return Y(e, t);
2415
+ return J(e, t);
2434
2416
  }
2435
2417
  /** @internal */
2436
2418
  _linkToIdToken(e, t) {
2437
2419
  const i = this.buildRequest();
2438
- return i.idToken = t, Y(e, i);
2420
+ return i.idToken = t, J(e, i);
2439
2421
  }
2440
2422
  /** @internal */
2441
2423
  _getReauthenticationResolver(e) {
2442
2424
  const t = this.buildRequest();
2443
- return t.autoCreate = !1, Y(e, t);
2425
+ return t.autoCreate = !1, J(e, t);
2444
2426
  }
2445
2427
  buildRequest() {
2446
2428
  const e = {
2447
- requestUri: Wi,
2429
+ requestUri: $i,
2448
2430
  returnSecureToken: !0
2449
2431
  };
2450
2432
  if (this.pendingToken)
@@ -2472,7 +2454,7 @@ class B extends qt {
2472
2454
  * See the License for the specific language governing permissions and
2473
2455
  * limitations under the License.
2474
2456
  */
2475
- class Kt {
2457
+ class qt {
2476
2458
  /**
2477
2459
  * Constructor for generic OAuth providers.
2478
2460
  *
@@ -2525,7 +2507,7 @@ class Kt {
2525
2507
  * See the License for the specific language governing permissions and
2526
2508
  * limitations under the License.
2527
2509
  */
2528
- class ce extends Kt {
2510
+ class ce extends qt {
2529
2511
  constructor() {
2530
2512
  super(...arguments), this.scopes = [];
2531
2513
  }
@@ -2560,7 +2542,7 @@ class ce extends Kt {
2560
2542
  * See the License for the specific language governing permissions and
2561
2543
  * limitations under the License.
2562
2544
  */
2563
- class x extends ce {
2545
+ class D extends ce {
2564
2546
  constructor() {
2565
2547
  super(
2566
2548
  "facebook.com"
@@ -2580,9 +2562,9 @@ class x extends ce {
2580
2562
  * @param accessToken - Facebook access token.
2581
2563
  */
2582
2564
  static credential(e) {
2583
- return B._fromParams({
2584
- providerId: x.PROVIDER_ID,
2585
- signInMethod: x.FACEBOOK_SIGN_IN_METHOD,
2565
+ return W._fromParams({
2566
+ providerId: D.PROVIDER_ID,
2567
+ signInMethod: D.FACEBOOK_SIGN_IN_METHOD,
2586
2568
  accessToken: e
2587
2569
  });
2588
2570
  }
@@ -2592,7 +2574,7 @@ class x extends ce {
2592
2574
  * @param userCredential - The user credential.
2593
2575
  */
2594
2576
  static credentialFromResult(e) {
2595
- return x.credentialFromTaggedObject(e);
2577
+ return D.credentialFromTaggedObject(e);
2596
2578
  }
2597
2579
  /**
2598
2580
  * Used to extract the underlying {@link OAuthCredential} from a {@link AuthError} which was
@@ -2601,20 +2583,20 @@ class x extends ce {
2601
2583
  * @param userCredential - The user credential.
2602
2584
  */
2603
2585
  static credentialFromError(e) {
2604
- return x.credentialFromTaggedObject(e.customData || {});
2586
+ return D.credentialFromTaggedObject(e.customData || {});
2605
2587
  }
2606
2588
  static credentialFromTaggedObject({ _tokenResponse: e }) {
2607
2589
  if (!e || !("oauthAccessToken" in e) || !e.oauthAccessToken)
2608
2590
  return null;
2609
2591
  try {
2610
- return x.credential(e.oauthAccessToken);
2592
+ return D.credential(e.oauthAccessToken);
2611
2593
  } catch {
2612
2594
  return null;
2613
2595
  }
2614
2596
  }
2615
2597
  }
2616
- x.FACEBOOK_SIGN_IN_METHOD = "facebook.com";
2617
- x.PROVIDER_ID = "facebook.com";
2598
+ D.FACEBOOK_SIGN_IN_METHOD = "facebook.com";
2599
+ D.PROVIDER_ID = "facebook.com";
2618
2600
  /**
2619
2601
  * @license
2620
2602
  * Copyright 2020 Google LLC
@@ -2631,7 +2613,7 @@ x.PROVIDER_ID = "facebook.com";
2631
2613
  * See the License for the specific language governing permissions and
2632
2614
  * limitations under the License.
2633
2615
  */
2634
- class F extends ce {
2616
+ class x extends ce {
2635
2617
  constructor() {
2636
2618
  super(
2637
2619
  "google.com"
@@ -2652,9 +2634,9 @@ class F extends ce {
2652
2634
  * @param accessToken - Google access token.
2653
2635
  */
2654
2636
  static credential(e, t) {
2655
- return B._fromParams({
2656
- providerId: F.PROVIDER_ID,
2657
- signInMethod: F.GOOGLE_SIGN_IN_METHOD,
2637
+ return W._fromParams({
2638
+ providerId: x.PROVIDER_ID,
2639
+ signInMethod: x.GOOGLE_SIGN_IN_METHOD,
2658
2640
  idToken: e,
2659
2641
  accessToken: t
2660
2642
  });
@@ -2665,7 +2647,7 @@ class F extends ce {
2665
2647
  * @param userCredential - The user credential.
2666
2648
  */
2667
2649
  static credentialFromResult(e) {
2668
- return F.credentialFromTaggedObject(e);
2650
+ return x.credentialFromTaggedObject(e);
2669
2651
  }
2670
2652
  /**
2671
2653
  * Used to extract the underlying {@link OAuthCredential} from a {@link AuthError} which was
@@ -2674,7 +2656,7 @@ class F extends ce {
2674
2656
  * @param userCredential - The user credential.
2675
2657
  */
2676
2658
  static credentialFromError(e) {
2677
- return F.credentialFromTaggedObject(e.customData || {});
2659
+ return x.credentialFromTaggedObject(e.customData || {});
2678
2660
  }
2679
2661
  static credentialFromTaggedObject({ _tokenResponse: e }) {
2680
2662
  if (!e)
@@ -2683,14 +2665,14 @@ class F extends ce {
2683
2665
  if (!t && !i)
2684
2666
  return null;
2685
2667
  try {
2686
- return F.credential(t, i);
2668
+ return x.credential(t, i);
2687
2669
  } catch {
2688
2670
  return null;
2689
2671
  }
2690
2672
  }
2691
2673
  }
2692
- F.GOOGLE_SIGN_IN_METHOD = "google.com";
2693
- F.PROVIDER_ID = "google.com";
2674
+ x.GOOGLE_SIGN_IN_METHOD = "google.com";
2675
+ x.PROVIDER_ID = "google.com";
2694
2676
  /**
2695
2677
  * @license
2696
2678
  * Copyright 2020 Google LLC
@@ -2707,7 +2689,7 @@ F.PROVIDER_ID = "google.com";
2707
2689
  * See the License for the specific language governing permissions and
2708
2690
  * limitations under the License.
2709
2691
  */
2710
- class V extends ce {
2692
+ class F extends ce {
2711
2693
  constructor() {
2712
2694
  super(
2713
2695
  "github.com"
@@ -2720,9 +2702,9 @@ class V extends ce {
2720
2702
  * @param accessToken - Github access token.
2721
2703
  */
2722
2704
  static credential(e) {
2723
- return B._fromParams({
2724
- providerId: V.PROVIDER_ID,
2725
- signInMethod: V.GITHUB_SIGN_IN_METHOD,
2705
+ return W._fromParams({
2706
+ providerId: F.PROVIDER_ID,
2707
+ signInMethod: F.GITHUB_SIGN_IN_METHOD,
2726
2708
  accessToken: e
2727
2709
  });
2728
2710
  }
@@ -2732,7 +2714,7 @@ class V extends ce {
2732
2714
  * @param userCredential - The user credential.
2733
2715
  */
2734
2716
  static credentialFromResult(e) {
2735
- return V.credentialFromTaggedObject(e);
2717
+ return F.credentialFromTaggedObject(e);
2736
2718
  }
2737
2719
  /**
2738
2720
  * Used to extract the underlying {@link OAuthCredential} from a {@link AuthError} which was
@@ -2741,20 +2723,20 @@ class V extends ce {
2741
2723
  * @param userCredential - The user credential.
2742
2724
  */
2743
2725
  static credentialFromError(e) {
2744
- return V.credentialFromTaggedObject(e.customData || {});
2726
+ return F.credentialFromTaggedObject(e.customData || {});
2745
2727
  }
2746
2728
  static credentialFromTaggedObject({ _tokenResponse: e }) {
2747
2729
  if (!e || !("oauthAccessToken" in e) || !e.oauthAccessToken)
2748
2730
  return null;
2749
2731
  try {
2750
- return V.credential(e.oauthAccessToken);
2732
+ return F.credential(e.oauthAccessToken);
2751
2733
  } catch {
2752
2734
  return null;
2753
2735
  }
2754
2736
  }
2755
2737
  }
2756
- V.GITHUB_SIGN_IN_METHOD = "github.com";
2757
- V.PROVIDER_ID = "github.com";
2738
+ F.GITHUB_SIGN_IN_METHOD = "github.com";
2739
+ F.PROVIDER_ID = "github.com";
2758
2740
  /**
2759
2741
  * @license
2760
2742
  * Copyright 2020 Google LLC
@@ -2771,7 +2753,7 @@ V.PROVIDER_ID = "github.com";
2771
2753
  * See the License for the specific language governing permissions and
2772
2754
  * limitations under the License.
2773
2755
  */
2774
- class $ extends ce {
2756
+ class V extends ce {
2775
2757
  constructor() {
2776
2758
  super(
2777
2759
  "twitter.com"
@@ -2785,9 +2767,9 @@ class $ extends ce {
2785
2767
  * @param secret - Twitter secret.
2786
2768
  */
2787
2769
  static credential(e, t) {
2788
- return B._fromParams({
2789
- providerId: $.PROVIDER_ID,
2790
- signInMethod: $.TWITTER_SIGN_IN_METHOD,
2770
+ return W._fromParams({
2771
+ providerId: V.PROVIDER_ID,
2772
+ signInMethod: V.TWITTER_SIGN_IN_METHOD,
2791
2773
  oauthToken: e,
2792
2774
  oauthTokenSecret: t
2793
2775
  });
@@ -2798,7 +2780,7 @@ class $ extends ce {
2798
2780
  * @param userCredential - The user credential.
2799
2781
  */
2800
2782
  static credentialFromResult(e) {
2801
- return $.credentialFromTaggedObject(e);
2783
+ return V.credentialFromTaggedObject(e);
2802
2784
  }
2803
2785
  /**
2804
2786
  * Used to extract the underlying {@link OAuthCredential} from a {@link AuthError} which was
@@ -2807,7 +2789,7 @@ class $ extends ce {
2807
2789
  * @param userCredential - The user credential.
2808
2790
  */
2809
2791
  static credentialFromError(e) {
2810
- return $.credentialFromTaggedObject(e.customData || {});
2792
+ return V.credentialFromTaggedObject(e.customData || {});
2811
2793
  }
2812
2794
  static credentialFromTaggedObject({ _tokenResponse: e }) {
2813
2795
  if (!e)
@@ -2816,14 +2798,14 @@ class $ extends ce {
2816
2798
  if (!t || !i)
2817
2799
  return null;
2818
2800
  try {
2819
- return $.credential(t, i);
2801
+ return V.credential(t, i);
2820
2802
  } catch {
2821
2803
  return null;
2822
2804
  }
2823
2805
  }
2824
2806
  }
2825
- $.TWITTER_SIGN_IN_METHOD = "twitter.com";
2826
- $.PROVIDER_ID = "twitter.com";
2807
+ V.TWITTER_SIGN_IN_METHOD = "twitter.com";
2808
+ V.PROVIDER_ID = "twitter.com";
2827
2809
  /**
2828
2810
  * @license
2829
2811
  * Copyright 2020 Google LLC
@@ -2840,13 +2822,13 @@ $.PROVIDER_ID = "twitter.com";
2840
2822
  * See the License for the specific language governing permissions and
2841
2823
  * limitations under the License.
2842
2824
  */
2843
- class G {
2825
+ class B {
2844
2826
  constructor(e) {
2845
2827
  this.user = e.user, this.providerId = e.providerId, this._tokenResponse = e._tokenResponse, this.operationType = e.operationType;
2846
2828
  }
2847
2829
  static async _fromIdTokenResponse(e, t, i, r = !1) {
2848
- const s = await N._fromIdTokenResponse(e, i, r), o = lt(i);
2849
- return new G({
2830
+ const s = await C._fromIdTokenResponse(e, i, r), o = lt(i);
2831
+ return new B({
2850
2832
  user: s,
2851
2833
  providerId: o,
2852
2834
  _tokenResponse: i,
@@ -2860,7 +2842,7 @@ class G {
2860
2842
  !0
2861
2843
  );
2862
2844
  const r = lt(i);
2863
- return new G({
2845
+ return new B({
2864
2846
  user: e,
2865
2847
  providerId: r,
2866
2848
  _tokenResponse: i,
@@ -2901,14 +2883,14 @@ class Ie extends Ve {
2901
2883
  return new Ie(e, t, i, r);
2902
2884
  }
2903
2885
  }
2904
- function Jt(n, e, t, i) {
2886
+ function Kt(n, e, t, i) {
2905
2887
  return (e === "reauthenticate" ? t._getReauthenticationResolver(n) : t._getIdTokenResponse(n)).catch((s) => {
2906
2888
  throw s.code === "auth/multi-factor-auth-required" ? Ie._fromErrorAndOperation(n, s, e, i) : s;
2907
2889
  });
2908
2890
  }
2909
- async function ji(n, e, t = !1) {
2891
+ async function Hi(n, e, t = !1) {
2910
2892
  const i = await re(n, e._linkToIdToken(n.auth, await n.getIdToken()), t);
2911
- return G._forOperation(n, "link", i);
2893
+ return B._forOperation(n, "link", i);
2912
2894
  }
2913
2895
  /**
2914
2896
  * @license
@@ -2926,20 +2908,20 @@ async function ji(n, e, t = !1) {
2926
2908
  * See the License for the specific language governing permissions and
2927
2909
  * limitations under the License.
2928
2910
  */
2929
- async function Bi(n, e, t = !1) {
2911
+ async function ji(n, e, t = !1) {
2930
2912
  const { auth: i } = n;
2931
- if (P(i.app))
2932
- return Promise.reject(H(i));
2913
+ if (A(i.app))
2914
+ return Promise.reject($(i));
2933
2915
  const r = "reauthenticate";
2934
2916
  try {
2935
- const s = await re(n, Jt(i, r, e, n), t);
2917
+ const s = await re(n, Kt(i, r, e, n), t);
2936
2918
  u(
2937
2919
  s.idToken,
2938
2920
  i,
2939
2921
  "internal-error"
2940
2922
  /* AuthErrorCode.INTERNAL_ERROR */
2941
2923
  );
2942
- const o = je(s.idToken);
2924
+ const o = We(s.idToken);
2943
2925
  u(
2944
2926
  o,
2945
2927
  i,
@@ -2952,9 +2934,9 @@ async function Bi(n, e, t = !1) {
2952
2934
  i,
2953
2935
  "user-mismatch"
2954
2936
  /* AuthErrorCode.USER_MISMATCH */
2955
- ), G._forOperation(n, r, s);
2937
+ ), B._forOperation(n, r, s);
2956
2938
  } catch (s) {
2957
- throw (s == null ? void 0 : s.code) === "auth/user-not-found" && L(
2939
+ throw (s == null ? void 0 : s.code) === "auth/user-not-found" && O(
2958
2940
  i,
2959
2941
  "user-mismatch"
2960
2942
  /* AuthErrorCode.USER_MISMATCH */
@@ -2977,10 +2959,10 @@ async function Bi(n, e, t = !1) {
2977
2959
  * See the License for the specific language governing permissions and
2978
2960
  * limitations under the License.
2979
2961
  */
2980
- async function Gi(n, e, t = !1) {
2981
- if (P(n.app))
2982
- return Promise.reject(H(n));
2983
- const i = "signIn", r = await Jt(n, i, e), s = await G._fromIdTokenResponse(n, i, r);
2962
+ async function Wi(n, e, t = !1) {
2963
+ if (A(n.app))
2964
+ return Promise.reject($(n));
2965
+ const i = "signIn", r = await Kt(n, i, e), s = await B._fromIdTokenResponse(n, i, r);
2984
2966
  return t || await n._updateCurrentUser(s.user), s;
2985
2967
  }
2986
2968
  /**
@@ -2999,8 +2981,8 @@ async function Gi(n, e, t = !1) {
2999
2981
  * See the License for the specific language governing permissions and
3000
2982
  * limitations under the License.
3001
2983
  */
3002
- async function zi(n, e) {
3003
- return Lt(n, "POST", "/v1/accounts:signInWithCustomToken", Te(n, e));
2984
+ async function Bi(n, e) {
2985
+ return Ot(n, "POST", "/v1/accounts:signInWithCustomToken", Te(n, e));
3004
2986
  }
3005
2987
  /**
3006
2988
  * @license
@@ -3018,20 +3000,20 @@ async function zi(n, e) {
3018
3000
  * See the License for the specific language governing permissions and
3019
3001
  * limitations under the License.
3020
3002
  */
3021
- async function qi(n, e) {
3022
- if (P(n.app))
3023
- return Promise.reject(H(n));
3024
- const t = be(n), i = await zi(t, {
3003
+ async function Gi(n, e) {
3004
+ if (A(n.app))
3005
+ return Promise.reject($(n));
3006
+ const t = be(n), i = await Bi(t, {
3025
3007
  token: e,
3026
3008
  returnSecureToken: !0
3027
- }), r = await G._fromIdTokenResponse(t, "signIn", i);
3009
+ }), r = await B._fromIdTokenResponse(t, "signIn", i);
3028
3010
  return await t._updateCurrentUser(r.user), r;
3029
3011
  }
3030
- function Ki(n, e, t, i) {
3031
- return Q(n).onIdTokenChanged(e, t, i);
3012
+ function zi(n, e, t, i) {
3013
+ return Y(n).onIdTokenChanged(e, t, i);
3032
3014
  }
3033
- function Ji(n, e, t) {
3034
- return Q(n).beforeAuthStateChanged(e, t);
3015
+ function qi(n, e, t) {
3016
+ return Y(n).beforeAuthStateChanged(e, t);
3035
3017
  }
3036
3018
  const ye = "__sak";
3037
3019
  /**
@@ -3050,7 +3032,7 @@ const ye = "__sak";
3050
3032
  * See the License for the specific language governing permissions and
3051
3033
  * limitations under the License.
3052
3034
  */
3053
- class Yt {
3035
+ class Jt {
3054
3036
  constructor(e, t) {
3055
3037
  this.storageRetriever = e, this.type = t;
3056
3038
  }
@@ -3091,18 +3073,18 @@ class Yt {
3091
3073
  * See the License for the specific language governing permissions and
3092
3074
  * limitations under the License.
3093
3075
  */
3094
- function Yi() {
3095
- const n = k();
3076
+ function Ki() {
3077
+ const n = w();
3096
3078
  return Be(n) || ke(n);
3097
3079
  }
3098
- const Xi = 1e3, Qi = 10;
3099
- class Xt extends Yt {
3080
+ const Ji = 1e3, Yi = 10;
3081
+ class Yt extends Jt {
3100
3082
  constructor() {
3101
3083
  super(
3102
3084
  () => window.localStorage,
3103
3085
  "LOCAL"
3104
3086
  /* PersistenceType.LOCAL */
3105
- ), this.boundEventHandler = (e, t) => this.onStorageEvent(e, t), this.listeners = {}, this.localCache = {}, this.pollTimer = null, this.safariLocalStorageNotSynced = Yi() && Ri(), this.fallbackToPolling = Bt(), this._shouldAllowMigration = !0;
3087
+ ), this.boundEventHandler = (e, t) => this.onStorageEvent(e, t), this.listeners = {}, this.localCache = {}, this.pollTimer = null, this.safariLocalStorageNotSynced = Ki() && Ei(), this.fallbackToPolling = Wt(), this._shouldAllowMigration = !0;
3106
3088
  }
3107
3089
  forAllChangedKeys(e) {
3108
3090
  for (const t of Object.keys(this.listeners)) {
@@ -3129,7 +3111,7 @@ class Xt extends Yt {
3129
3111
  const o = this.storage.getItem(i);
3130
3112
  !t && this.localCache[i] === o || this.notifyListeners(i, o);
3131
3113
  }, s = this.storage.getItem(i);
3132
- Si() && s !== e.newValue && e.newValue !== e.oldValue ? setTimeout(r, Qi) : r();
3114
+ bi() && s !== e.newValue && e.newValue !== e.oldValue ? setTimeout(r, Yi) : r();
3133
3115
  }
3134
3116
  notifyListeners(e, t) {
3135
3117
  this.localCache[e] = t;
@@ -3151,7 +3133,7 @@ class Xt extends Yt {
3151
3133
  !0
3152
3134
  );
3153
3135
  });
3154
- }, Xi);
3136
+ }, Ji);
3155
3137
  }
3156
3138
  stopPolling() {
3157
3139
  this.pollTimer && (clearInterval(this.pollTimer), this.pollTimer = null);
@@ -3180,8 +3162,8 @@ class Xt extends Yt {
3180
3162
  await super._remove(e), delete this.localCache[e];
3181
3163
  }
3182
3164
  }
3183
- Xt.type = "LOCAL";
3184
- const Zi = Xt;
3165
+ Yt.type = "LOCAL";
3166
+ const Xi = Yt;
3185
3167
  /**
3186
3168
  * @license
3187
3169
  * Copyright 2020 Google LLC
@@ -3198,7 +3180,7 @@ const Zi = Xt;
3198
3180
  * See the License for the specific language governing permissions and
3199
3181
  * limitations under the License.
3200
3182
  */
3201
- class Qt extends Yt {
3183
+ class Xt extends Jt {
3202
3184
  constructor() {
3203
3185
  super(
3204
3186
  () => window.sessionStorage,
@@ -3211,8 +3193,8 @@ class Qt extends Yt {
3211
3193
  _removeListener(e, t) {
3212
3194
  }
3213
3195
  }
3214
- Qt.type = "SESSION";
3215
- const Zt = Qt;
3196
+ Xt.type = "SESSION";
3197
+ const Qt = Xt;
3216
3198
  /**
3217
3199
  * @license
3218
3200
  * Copyright 2019 Google LLC
@@ -3229,7 +3211,7 @@ const Zt = Qt;
3229
3211
  * See the License for the specific language governing permissions and
3230
3212
  * limitations under the License.
3231
3213
  */
3232
- function er(n) {
3214
+ function Qi(n) {
3233
3215
  return Promise.all(n.map(async (e) => {
3234
3216
  try {
3235
3217
  return {
@@ -3299,7 +3281,7 @@ class Ee {
3299
3281
  eventId: i,
3300
3282
  eventType: r
3301
3283
  });
3302
- const c = Array.from(o).map(async (l) => l(t.origin, s)), a = await er(c);
3284
+ const c = Array.from(o).map(async (l) => l(t.origin, s)), a = await Qi(c);
3303
3285
  t.ports[0].postMessage({
3304
3286
  status: "done",
3305
3287
  eventId: i,
@@ -3367,7 +3349,7 @@ function ze(n = "", e = 10) {
3367
3349
  * See the License for the specific language governing permissions and
3368
3350
  * limitations under the License.
3369
3351
  */
3370
- class tr {
3352
+ class Zi {
3371
3353
  constructor(e) {
3372
3354
  this.target = e, this.handlers = /* @__PURE__ */ new Set();
3373
3355
  }
@@ -3403,7 +3385,7 @@ class tr {
3403
3385
  return new Promise((c, a) => {
3404
3386
  const l = ze("", 20);
3405
3387
  r.port1.start();
3406
- const h = setTimeout(() => {
3388
+ const d = setTimeout(() => {
3407
3389
  a(new Error(
3408
3390
  "unsupported_event"
3409
3391
  /* _MessageError.UNSUPPORTED_EVENT */
@@ -3412,11 +3394,11 @@ class tr {
3412
3394
  o = {
3413
3395
  messageChannel: r,
3414
3396
  onMessage(m) {
3415
- const v = m;
3416
- if (v.data.eventId === l)
3417
- switch (v.data.status) {
3397
+ const f = m;
3398
+ if (f.data.eventId === l)
3399
+ switch (f.data.status) {
3418
3400
  case "ack":
3419
- clearTimeout(h), s = setTimeout(
3401
+ clearTimeout(d), s = setTimeout(
3420
3402
  () => {
3421
3403
  a(new Error(
3422
3404
  "timeout"
@@ -3428,10 +3410,10 @@ class tr {
3428
3410
  );
3429
3411
  break;
3430
3412
  case "done":
3431
- clearTimeout(s), c(v.data.response);
3413
+ clearTimeout(s), c(f.data.response);
3432
3414
  break;
3433
3415
  default:
3434
- clearTimeout(h), clearTimeout(s), a(new Error(
3416
+ clearTimeout(d), clearTimeout(s), a(new Error(
3435
3417
  "invalid_response"
3436
3418
  /* _MessageError.INVALID_RESPONSE */
3437
3419
  ));
@@ -3464,11 +3446,11 @@ class tr {
3464
3446
  * See the License for the specific language governing permissions and
3465
3447
  * limitations under the License.
3466
3448
  */
3467
- function S() {
3449
+ function E() {
3468
3450
  return window;
3469
3451
  }
3470
- function nr(n) {
3471
- S().location.href = n;
3452
+ function er(n) {
3453
+ E().location.href = n;
3472
3454
  }
3473
3455
  /**
3474
3456
  * @license
@@ -3486,10 +3468,10 @@ function nr(n) {
3486
3468
  * See the License for the specific language governing permissions and
3487
3469
  * limitations under the License.
3488
3470
  */
3489
- function en() {
3490
- return typeof S().WorkerGlobalScope < "u" && typeof S().importScripts == "function";
3471
+ function Zt() {
3472
+ return typeof E().WorkerGlobalScope < "u" && typeof E().importScripts == "function";
3491
3473
  }
3492
- async function ir() {
3474
+ async function tr() {
3493
3475
  if (!(navigator != null && navigator.serviceWorker))
3494
3476
  return null;
3495
3477
  try {
@@ -3498,12 +3480,12 @@ async function ir() {
3498
3480
  return null;
3499
3481
  }
3500
3482
  }
3501
- function rr() {
3483
+ function nr() {
3502
3484
  var n;
3503
3485
  return ((n = navigator == null ? void 0 : navigator.serviceWorker) === null || n === void 0 ? void 0 : n.controller) || null;
3504
3486
  }
3505
- function sr() {
3506
- return en() ? self : null;
3487
+ function ir() {
3488
+ return Zt() ? self : null;
3507
3489
  }
3508
3490
  /**
3509
3491
  * @license
@@ -3521,7 +3503,7 @@ function sr() {
3521
3503
  * See the License for the specific language governing permissions and
3522
3504
  * limitations under the License.
3523
3505
  */
3524
- const tn = "firebaseLocalStorageDb", or = 1, we = "firebaseLocalStorage", nn = "fbase_key";
3506
+ const en = "firebaseLocalStorageDb", rr = 1, we = "firebaseLocalStorage", tn = "fbase_key";
3525
3507
  class le {
3526
3508
  constructor(e) {
3527
3509
  this.request = e;
@@ -3539,36 +3521,36 @@ class le {
3539
3521
  function Se(n, e) {
3540
3522
  return n.transaction([we], e ? "readwrite" : "readonly").objectStore(we);
3541
3523
  }
3542
- function ar() {
3543
- const n = indexedDB.deleteDatabase(tn);
3524
+ function sr() {
3525
+ const n = indexedDB.deleteDatabase(en);
3544
3526
  return new le(n).toPromise();
3545
3527
  }
3546
3528
  function De() {
3547
- const n = indexedDB.open(tn, or);
3529
+ const n = indexedDB.open(en, rr);
3548
3530
  return new Promise((e, t) => {
3549
3531
  n.addEventListener("error", () => {
3550
3532
  t(n.error);
3551
3533
  }), n.addEventListener("upgradeneeded", () => {
3552
3534
  const i = n.result;
3553
3535
  try {
3554
- i.createObjectStore(we, { keyPath: nn });
3536
+ i.createObjectStore(we, { keyPath: tn });
3555
3537
  } catch (r) {
3556
3538
  t(r);
3557
3539
  }
3558
3540
  }), n.addEventListener("success", async () => {
3559
3541
  const i = n.result;
3560
- i.objectStoreNames.contains(we) ? e(i) : (i.close(), await ar(), e(await De()));
3542
+ i.objectStoreNames.contains(we) ? e(i) : (i.close(), await sr(), e(await De()));
3561
3543
  });
3562
3544
  });
3563
3545
  }
3564
3546
  async function ut(n, e, t) {
3565
3547
  const i = Se(n, !0).put({
3566
- [nn]: e,
3548
+ [tn]: e,
3567
3549
  value: t
3568
3550
  });
3569
3551
  return new le(i).toPromise();
3570
3552
  }
3571
- async function cr(n, e) {
3553
+ async function or(n, e) {
3572
3554
  const t = Se(n, !1).get(e), i = await new le(t).toPromise();
3573
3555
  return i === void 0 ? null : i.value;
3574
3556
  }
@@ -3576,8 +3558,8 @@ function dt(n, e) {
3576
3558
  const t = Se(n, !0).delete(e);
3577
3559
  return new le(t).toPromise();
3578
3560
  }
3579
- const lr = 800, ur = 3;
3580
- class rn {
3561
+ const ar = 800, cr = 3;
3562
+ class nn {
3581
3563
  constructor() {
3582
3564
  this.type = "LOCAL", this._shouldAllowMigration = !0, this.listeners = {}, this.localCache = {}, this.pollTimer = null, this.pendingWrites = 0, this.receiver = null, this.sender = null, this.serviceWorkerReceiverAvailable = !1, this.activeServiceWorker = null, this._workerInitializationPromise = this.initializeServiceWorkerMessaging().then(() => {
3583
3565
  }, () => {
@@ -3593,7 +3575,7 @@ class rn {
3593
3575
  const i = await this._openDb();
3594
3576
  return await e(i);
3595
3577
  } catch (i) {
3596
- if (t++ > ur)
3578
+ if (t++ > cr)
3597
3579
  throw i;
3598
3580
  this.db && (this.db.close(), this.db = void 0);
3599
3581
  }
@@ -3603,13 +3585,13 @@ class rn {
3603
3585
  * postMessage interface to send these events to the worker ourselves.
3604
3586
  */
3605
3587
  async initializeServiceWorkerMessaging() {
3606
- return en() ? this.initializeReceiver() : this.initializeSender();
3588
+ return Zt() ? this.initializeReceiver() : this.initializeSender();
3607
3589
  }
3608
3590
  /**
3609
3591
  * As the worker we should listen to events from the main window.
3610
3592
  */
3611
3593
  async initializeReceiver() {
3612
- this.receiver = Ee._getInstance(sr()), this.receiver._subscribe("keyChanged", async (e, t) => ({
3594
+ this.receiver = Ee._getInstance(ir()), this.receiver._subscribe("keyChanged", async (e, t) => ({
3613
3595
  keyProcessed: (await this._poll()).includes(t.key)
3614
3596
  })), this.receiver._subscribe("ping", async (e, t) => [
3615
3597
  "keyChanged"
@@ -3625,9 +3607,9 @@ class rn {
3625
3607
  */
3626
3608
  async initializeSender() {
3627
3609
  var e, t;
3628
- if (this.activeServiceWorker = await ir(), !this.activeServiceWorker)
3610
+ if (this.activeServiceWorker = await tr(), !this.activeServiceWorker)
3629
3611
  return;
3630
- this.sender = new tr(this.activeServiceWorker);
3612
+ this.sender = new Zi(this.activeServiceWorker);
3631
3613
  const i = await this.sender._send(
3632
3614
  "ping",
3633
3615
  {},
@@ -3649,7 +3631,7 @@ class rn {
3649
3631
  * @param key - Storage key which changed.
3650
3632
  */
3651
3633
  async notifyServiceWorker(e) {
3652
- if (!(!this.sender || !this.activeServiceWorker || rr() !== this.activeServiceWorker))
3634
+ if (!(!this.sender || !this.activeServiceWorker || nr() !== this.activeServiceWorker))
3653
3635
  try {
3654
3636
  await this.sender._send(
3655
3637
  "keyChanged",
@@ -3683,7 +3665,7 @@ class rn {
3683
3665
  return this._withPendingWrite(async () => (await this._withRetries((i) => ut(i, e, t)), this.localCache[e] = t, this.notifyServiceWorker(e)));
3684
3666
  }
3685
3667
  async _get(e) {
3686
- const t = await this._withRetries((i) => cr(i, e));
3668
+ const t = await this._withRetries((i) => or(i, e));
3687
3669
  return this.localCache[e] = t, t;
3688
3670
  }
3689
3671
  async _remove(e) {
@@ -3714,7 +3696,7 @@ class rn {
3714
3696
  r(t);
3715
3697
  }
3716
3698
  startPolling() {
3717
- this.stopPolling(), this.pollTimer = setInterval(async () => this._poll(), lr);
3699
+ this.stopPolling(), this.pollTimer = setInterval(async () => this._poll(), ar);
3718
3700
  }
3719
3701
  stopPolling() {
3720
3702
  this.pollTimer && (clearInterval(this.pollTimer), this.pollTimer = null);
@@ -3726,8 +3708,8 @@ class rn {
3726
3708
  this.listeners[e] && (this.listeners[e].delete(t), this.listeners[e].size === 0 && delete this.listeners[e]), Object.keys(this.listeners).length === 0 && this.stopPolling();
3727
3709
  }
3728
3710
  }
3729
- rn.type = "LOCAL";
3730
- const dr = rn;
3711
+ nn.type = "LOCAL";
3712
+ const lr = nn;
3731
3713
  new ae(3e4, 6e4);
3732
3714
  /**
3733
3715
  * @license
@@ -3745,8 +3727,8 @@ new ae(3e4, 6e4);
3745
3727
  * See the License for the specific language governing permissions and
3746
3728
  * limitations under the License.
3747
3729
  */
3748
- function hr(n, e) {
3749
- return e ? O(e) : (u(
3730
+ function ur(n, e) {
3731
+ return e ? N(e) : (u(
3750
3732
  n._popupRedirectResolver,
3751
3733
  n,
3752
3734
  "argument-error"
@@ -3769,7 +3751,7 @@ function hr(n, e) {
3769
3751
  * See the License for the specific language governing permissions and
3770
3752
  * limitations under the License.
3771
3753
  */
3772
- class qe extends qt {
3754
+ class qe extends zt {
3773
3755
  constructor(e) {
3774
3756
  super(
3775
3757
  "custom",
@@ -3778,13 +3760,13 @@ class qe extends qt {
3778
3760
  ), this.params = e;
3779
3761
  }
3780
3762
  _getIdTokenResponse(e) {
3781
- return Y(e, this._buildIdpRequest());
3763
+ return J(e, this._buildIdpRequest());
3782
3764
  }
3783
3765
  _linkToIdToken(e, t) {
3784
- return Y(e, this._buildIdpRequest(t));
3766
+ return J(e, this._buildIdpRequest(t));
3785
3767
  }
3786
3768
  _getReauthenticationResolver(e) {
3787
- return Y(e, this._buildIdpRequest());
3769
+ return J(e, this._buildIdpRequest());
3788
3770
  }
3789
3771
  _buildIdpRequest(e) {
3790
3772
  const t = {
@@ -3799,26 +3781,26 @@ class qe extends qt {
3799
3781
  return e && (t.idToken = e), t;
3800
3782
  }
3801
3783
  }
3802
- function fr(n) {
3803
- return Gi(n.auth, new qe(n), n.bypassAuthState);
3784
+ function dr(n) {
3785
+ return Wi(n.auth, new qe(n), n.bypassAuthState);
3804
3786
  }
3805
- function pr(n) {
3787
+ function hr(n) {
3806
3788
  const { auth: e, user: t } = n;
3807
3789
  return u(
3808
3790
  t,
3809
3791
  e,
3810
3792
  "internal-error"
3811
3793
  /* AuthErrorCode.INTERNAL_ERROR */
3812
- ), Bi(t, new qe(n), n.bypassAuthState);
3794
+ ), ji(t, new qe(n), n.bypassAuthState);
3813
3795
  }
3814
- async function mr(n) {
3796
+ async function fr(n) {
3815
3797
  const { auth: e, user: t } = n;
3816
3798
  return u(
3817
3799
  t,
3818
3800
  e,
3819
3801
  "internal-error"
3820
3802
  /* AuthErrorCode.INTERNAL_ERROR */
3821
- ), ji(t, new qe(n), n.bypassAuthState);
3803
+ ), Hi(t, new qe(n), n.bypassAuthState);
3822
3804
  }
3823
3805
  /**
3824
3806
  * @license
@@ -3836,7 +3818,7 @@ async function mr(n) {
3836
3818
  * See the License for the specific language governing permissions and
3837
3819
  * limitations under the License.
3838
3820
  */
3839
- class sn {
3821
+ class rn {
3840
3822
  constructor(e, t, i, r, s = !1) {
3841
3823
  this.auth = e, this.resolver = i, this.user = r, this.bypassAuthState = s, this.pendingPromise = null, this.eventManager = null, this.filter = Array.isArray(t) ? t : [t];
3842
3824
  }
@@ -3878,15 +3860,15 @@ class sn {
3878
3860
  switch (e) {
3879
3861
  case "signInViaPopup":
3880
3862
  case "signInViaRedirect":
3881
- return fr;
3863
+ return dr;
3882
3864
  case "linkViaPopup":
3883
3865
  case "linkViaRedirect":
3884
- return mr;
3866
+ return fr;
3885
3867
  case "reauthViaPopup":
3886
3868
  case "reauthViaRedirect":
3887
- return pr;
3869
+ return hr;
3888
3870
  default:
3889
- L(
3871
+ O(
3890
3872
  this.auth,
3891
3873
  "internal-error"
3892
3874
  /* AuthErrorCode.INTERNAL_ERROR */
@@ -3894,10 +3876,10 @@ class sn {
3894
3876
  }
3895
3877
  }
3896
3878
  resolve(e) {
3897
- M(this.pendingPromise, "Pending promise was never set"), this.pendingPromise.resolve(e), this.unregisterAndCleanUp();
3879
+ L(this.pendingPromise, "Pending promise was never set"), this.pendingPromise.resolve(e), this.unregisterAndCleanUp();
3898
3880
  }
3899
3881
  reject(e) {
3900
- M(this.pendingPromise, "Pending promise was never set"), this.pendingPromise.reject(e), this.unregisterAndCleanUp();
3882
+ L(this.pendingPromise, "Pending promise was never set"), this.pendingPromise.reject(e), this.unregisterAndCleanUp();
3901
3883
  }
3902
3884
  unregisterAndCleanUp() {
3903
3885
  this.eventManager && this.eventManager.unregisterConsumer(this), this.pendingPromise = null, this.cleanUp();
@@ -3919,8 +3901,8 @@ class sn {
3919
3901
  * See the License for the specific language governing permissions and
3920
3902
  * limitations under the License.
3921
3903
  */
3922
- const gr = new ae(2e3, 1e4);
3923
- class z extends sn {
3904
+ const pr = new ae(2e3, 1e4);
3905
+ class z extends rn {
3924
3906
  constructor(e, t, i, r, s) {
3925
3907
  super(e, t, r, s), this.provider = i, this.authWindow = null, this.pollId = null, z.currentPopupAction && z.currentPopupAction.cancel(), z.currentPopupAction = this;
3926
3908
  }
@@ -3934,7 +3916,7 @@ class z extends sn {
3934
3916
  ), e;
3935
3917
  }
3936
3918
  async onExecution() {
3937
- M(this.filter.length === 1, "Popup operations only handle one event");
3919
+ L(this.filter.length === 1, "Popup operations only handle one event");
3938
3920
  const e = ze();
3939
3921
  this.authWindow = await this.resolver._openPopup(
3940
3922
  this.auth,
@@ -3945,7 +3927,7 @@ class z extends sn {
3945
3927
  ), this.authWindow.associatedEvent = e, this.resolver._originValidation(this.auth).catch((t) => {
3946
3928
  this.reject(t);
3947
3929
  }), this.resolver._isIframeWebStorageSupported(this.auth, (t) => {
3948
- t || this.reject(E(
3930
+ t || this.reject(b(
3949
3931
  this.auth,
3950
3932
  "web-storage-unsupported"
3951
3933
  /* AuthErrorCode.WEB_STORAGE_UNSUPPORTED */
@@ -3957,7 +3939,7 @@ class z extends sn {
3957
3939
  return ((e = this.authWindow) === null || e === void 0 ? void 0 : e.associatedEvent) || null;
3958
3940
  }
3959
3941
  cancel() {
3960
- this.reject(E(
3942
+ this.reject(b(
3961
3943
  this.auth,
3962
3944
  "cancelled-popup-request"
3963
3945
  /* AuthErrorCode.EXPIRED_POPUP_REQUEST */
@@ -3972,7 +3954,7 @@ class z extends sn {
3972
3954
  if (!((i = (t = this.authWindow) === null || t === void 0 ? void 0 : t.window) === null || i === void 0) && i.closed) {
3973
3955
  this.pollId = window.setTimeout(
3974
3956
  () => {
3975
- this.pollId = null, this.reject(E(
3957
+ this.pollId = null, this.reject(b(
3976
3958
  this.auth,
3977
3959
  "popup-closed-by-user"
3978
3960
  /* AuthErrorCode.POPUP_CLOSED_BY_USER */
@@ -3983,7 +3965,7 @@ class z extends sn {
3983
3965
  );
3984
3966
  return;
3985
3967
  }
3986
- this.pollId = window.setTimeout(e, gr.get());
3968
+ this.pollId = window.setTimeout(e, pr.get());
3987
3969
  };
3988
3970
  e();
3989
3971
  }
@@ -4005,8 +3987,8 @@ z.currentPopupAction = null;
4005
3987
  * See the License for the specific language governing permissions and
4006
3988
  * limitations under the License.
4007
3989
  */
4008
- const _r = "pendingRedirect", fe = /* @__PURE__ */ new Map();
4009
- class vr extends sn {
3990
+ const mr = "pendingRedirect", fe = /* @__PURE__ */ new Map();
3991
+ class gr extends rn {
4010
3992
  constructor(e, t, i = !1) {
4011
3993
  super(e, [
4012
3994
  "signInViaRedirect",
@@ -4024,7 +4006,7 @@ class vr extends sn {
4024
4006
  let e = fe.get(this.auth._key());
4025
4007
  if (!e) {
4026
4008
  try {
4027
- const i = await Ir(this.resolver, this.auth) ? await super.execute() : null;
4009
+ const i = await _r(this.resolver, this.auth) ? await super.execute() : null;
4028
4010
  e = () => Promise.resolve(i);
4029
4011
  } catch (t) {
4030
4012
  e = () => Promise.reject(t);
@@ -4052,26 +4034,26 @@ class vr extends sn {
4052
4034
  cleanUp() {
4053
4035
  }
4054
4036
  }
4055
- async function Ir(n, e) {
4056
- const t = Tr(e), i = wr(n);
4037
+ async function _r(n, e) {
4038
+ const t = yr(e), i = Ir(n);
4057
4039
  if (!await i._isAvailable())
4058
4040
  return !1;
4059
4041
  const r = await i._get(t) === "true";
4060
4042
  return await i._remove(t), r;
4061
4043
  }
4062
- function yr(n, e) {
4044
+ function vr(n, e) {
4063
4045
  fe.set(n._key(), e);
4064
4046
  }
4065
- function wr(n) {
4066
- return O(n._redirectPersistence);
4047
+ function Ir(n) {
4048
+ return N(n._redirectPersistence);
4067
4049
  }
4068
- function Tr(n) {
4069
- return he(_r, n.config.apiKey, n.name);
4050
+ function yr(n) {
4051
+ return he(mr, n.config.apiKey, n.name);
4070
4052
  }
4071
- async function kr(n, e, t = !1) {
4072
- if (P(n.app))
4073
- return Promise.reject(H(n));
4074
- const i = be(n), r = hr(i, e), o = await new vr(i, r, t).execute();
4053
+ async function wr(n, e, t = !1) {
4054
+ if (A(n.app))
4055
+ return Promise.reject($(n));
4056
+ const i = be(n), r = ur(i, e), o = await new gr(i, r, t).execute();
4075
4057
  return o && !t && (delete o.user._redirectEventId, await i._persistUserIfCurrent(o.user), await i._setRedirectUser(null, e)), o;
4076
4058
  }
4077
4059
  /**
@@ -4090,8 +4072,8 @@ async function kr(n, e, t = !1) {
4090
4072
  * See the License for the specific language governing permissions and
4091
4073
  * limitations under the License.
4092
4074
  */
4093
- const br = 10 * 60 * 1e3;
4094
- class Er {
4075
+ const Tr = 10 * 60 * 1e3;
4076
+ class kr {
4095
4077
  constructor(e) {
4096
4078
  this.auth = e, this.cachedEventUids = /* @__PURE__ */ new Set(), this.consumers = /* @__PURE__ */ new Set(), this.queuedRedirectEvent = null, this.hasHandledPotentialRedirect = !1, this.lastProcessedEventTime = Date.now();
4097
4079
  }
@@ -4107,13 +4089,13 @@ class Er {
4107
4089
  let t = !1;
4108
4090
  return this.consumers.forEach((i) => {
4109
4091
  this.isEventForConsumer(e, i) && (t = !0, this.sendToConsumer(e, i), this.saveEventToCache(e));
4110
- }), this.hasHandledPotentialRedirect || !Sr(e) || (this.hasHandledPotentialRedirect = !0, t || (this.queuedRedirectEvent = e, t = !0)), t;
4092
+ }), this.hasHandledPotentialRedirect || !br(e) || (this.hasHandledPotentialRedirect = !0, t || (this.queuedRedirectEvent = e, t = !0)), t;
4111
4093
  }
4112
4094
  sendToConsumer(e, t) {
4113
4095
  var i;
4114
- if (e.error && !on(e)) {
4096
+ if (e.error && !sn(e)) {
4115
4097
  const r = ((i = e.error.code) === null || i === void 0 ? void 0 : i.split("auth/")[1]) || "internal-error";
4116
- t.onError(E(this.auth, r));
4098
+ t.onError(b(this.auth, r));
4117
4099
  } else
4118
4100
  t.onAuthEvent(e);
4119
4101
  }
@@ -4122,7 +4104,7 @@ class Er {
4122
4104
  return t.filter.includes(e.type) && i;
4123
4105
  }
4124
4106
  hasEventBeenHandled(e) {
4125
- return Date.now() - this.lastProcessedEventTime >= br && this.cachedEventUids.clear(), this.cachedEventUids.has(ht(e));
4107
+ return Date.now() - this.lastProcessedEventTime >= Tr && this.cachedEventUids.clear(), this.cachedEventUids.has(ht(e));
4126
4108
  }
4127
4109
  saveEventToCache(e) {
4128
4110
  this.cachedEventUids.add(ht(e)), this.lastProcessedEventTime = Date.now();
@@ -4131,17 +4113,17 @@ class Er {
4131
4113
  function ht(n) {
4132
4114
  return [n.type, n.eventId, n.sessionId, n.tenantId].filter((e) => e).join("-");
4133
4115
  }
4134
- function on({ type: n, error: e }) {
4116
+ function sn({ type: n, error: e }) {
4135
4117
  return n === "unknown" && (e == null ? void 0 : e.code) === "auth/no-auth-event";
4136
4118
  }
4137
- function Sr(n) {
4119
+ function br(n) {
4138
4120
  switch (n.type) {
4139
4121
  case "signInViaRedirect":
4140
4122
  case "linkViaRedirect":
4141
4123
  case "reauthViaRedirect":
4142
4124
  return !0;
4143
4125
  case "unknown":
4144
- return on(n);
4126
+ return sn(n);
4145
4127
  default:
4146
4128
  return !1;
4147
4129
  }
@@ -4162,8 +4144,8 @@ function Sr(n) {
4162
4144
  * See the License for the specific language governing permissions and
4163
4145
  * limitations under the License.
4164
4146
  */
4165
- async function Rr(n, e = {}) {
4166
- return Z(n, "GET", "/v1/projects", e);
4147
+ async function Er(n, e = {}) {
4148
+ return X(n, "GET", "/v1/projects", e);
4167
4149
  }
4168
4150
  /**
4169
4151
  * @license
@@ -4181,32 +4163,32 @@ async function Rr(n, e = {}) {
4181
4163
  * See the License for the specific language governing permissions and
4182
4164
  * limitations under the License.
4183
4165
  */
4184
- const Ar = /^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/, Pr = /^https?/;
4185
- async function Cr(n) {
4166
+ const Sr = /^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/, Rr = /^https?/;
4167
+ async function Ar(n) {
4186
4168
  if (n.config.emulator)
4187
4169
  return;
4188
- const { authorizedDomains: e } = await Rr(n);
4170
+ const { authorizedDomains: e } = await Er(n);
4189
4171
  for (const t of e)
4190
4172
  try {
4191
- if (Nr(t))
4173
+ if (Pr(t))
4192
4174
  return;
4193
4175
  } catch {
4194
4176
  }
4195
- L(
4177
+ O(
4196
4178
  n,
4197
4179
  "unauthorized-domain"
4198
4180
  /* AuthErrorCode.INVALID_ORIGIN */
4199
4181
  );
4200
4182
  }
4201
- function Nr(n) {
4183
+ function Pr(n) {
4202
4184
  const e = Me(), { protocol: t, hostname: i } = new URL(e);
4203
4185
  if (n.startsWith("chrome-extension://")) {
4204
4186
  const o = new URL(n);
4205
4187
  return o.hostname === "" && i === "" ? t === "chrome-extension:" && n.replace("chrome-extension://", "") === e.replace("chrome-extension://", "") : t === "chrome-extension:" && o.hostname === i;
4206
4188
  }
4207
- if (!Pr.test(t))
4189
+ if (!Rr.test(t))
4208
4190
  return !1;
4209
- if (Ar.test(n))
4191
+ if (Sr.test(n))
4210
4192
  return i === n;
4211
4193
  const r = n.replace(/\./g, "\\.");
4212
4194
  return new RegExp("^(.+\\." + r + "|" + r + ")$", "i").test(i);
@@ -4227,9 +4209,9 @@ function Nr(n) {
4227
4209
  * See the License for the specific language governing permissions and
4228
4210
  * limitations under the License.
4229
4211
  */
4230
- const Or = new ae(3e4, 6e4);
4212
+ const Cr = new ae(3e4, 6e4);
4231
4213
  function ft() {
4232
- const n = S().___jsl;
4214
+ const n = E().___jsl;
4233
4215
  if (n != null && n.H) {
4234
4216
  for (const e of Object.keys(n.H))
4235
4217
  if (n.H[e].r = n.H[e].r || [], n.H[e].L = n.H[e].L || [], n.H[e].r = [...n.H[e].L], n.CP)
@@ -4237,7 +4219,7 @@ function ft() {
4237
4219
  n.CP[t] = null;
4238
4220
  }
4239
4221
  }
4240
- function Lr(n) {
4222
+ function Nr(n) {
4241
4223
  return new Promise((e, t) => {
4242
4224
  var i, r, s;
4243
4225
  function o() {
@@ -4246,36 +4228,36 @@ function Lr(n) {
4246
4228
  e(gapi.iframes.getContext());
4247
4229
  },
4248
4230
  ontimeout: () => {
4249
- ft(), t(E(
4231
+ ft(), t(b(
4250
4232
  n,
4251
4233
  "network-request-failed"
4252
4234
  /* AuthErrorCode.NETWORK_REQUEST_FAILED */
4253
4235
  ));
4254
4236
  },
4255
- timeout: Or.get()
4237
+ timeout: Cr.get()
4256
4238
  });
4257
4239
  }
4258
- if (!((r = (i = S().gapi) === null || i === void 0 ? void 0 : i.iframes) === null || r === void 0) && r.Iframe)
4240
+ if (!((r = (i = E().gapi) === null || i === void 0 ? void 0 : i.iframes) === null || r === void 0) && r.Iframe)
4259
4241
  e(gapi.iframes.getContext());
4260
- else if (!((s = S().gapi) === null || s === void 0) && s.load)
4242
+ else if (!((s = E().gapi) === null || s === void 0) && s.load)
4261
4243
  o();
4262
4244
  else {
4263
- const c = Di("iframefcb");
4264
- return S()[c] = () => {
4265
- gapi.load ? o() : t(E(
4245
+ const c = Mi("iframefcb");
4246
+ return E()[c] = () => {
4247
+ gapi.load ? o() : t(b(
4266
4248
  n,
4267
4249
  "network-request-failed"
4268
4250
  /* AuthErrorCode.NETWORK_REQUEST_FAILED */
4269
4251
  ));
4270
- }, Mi(`${Ui()}?onload=${c}`).catch((a) => t(a));
4252
+ }, Oi(`${Li()}?onload=${c}`).catch((a) => t(a));
4271
4253
  }
4272
4254
  }).catch((e) => {
4273
4255
  throw pe = null, e;
4274
4256
  });
4275
4257
  }
4276
4258
  let pe = null;
4277
- function Mr(n) {
4278
- return pe = pe || Lr(n), pe;
4259
+ function Or(n) {
4260
+ return pe = pe || Nr(n), pe;
4279
4261
  }
4280
4262
  /**
4281
4263
  * @license
@@ -4293,7 +4275,7 @@ function Mr(n) {
4293
4275
  * See the License for the specific language governing permissions and
4294
4276
  * limitations under the License.
4295
4277
  */
4296
- const Ur = new ae(5e3, 15e3), Dr = "__/auth/iframe", xr = "emulator/auth/iframe", Fr = {
4278
+ const Lr = new ae(5e3, 15e3), Mr = "__/auth/iframe", Ur = "emulator/auth/iframe", Dr = {
4297
4279
  style: {
4298
4280
  position: "absolute",
4299
4281
  top: "-100px",
@@ -4302,13 +4284,13 @@ const Ur = new ae(5e3, 15e3), Dr = "__/auth/iframe", xr = "emulator/auth/iframe"
4302
4284
  },
4303
4285
  "aria-hidden": "true",
4304
4286
  tabindex: "-1"
4305
- }, Vr = /* @__PURE__ */ new Map([
4287
+ }, xr = /* @__PURE__ */ new Map([
4306
4288
  ["identitytoolkit.googleapis.com", "p"],
4307
4289
  ["staging-identitytoolkit.sandbox.googleapis.com", "s"],
4308
4290
  ["test-identitytoolkit.sandbox.googleapis.com", "t"]
4309
4291
  // test
4310
4292
  ]);
4311
- function $r(n) {
4293
+ function Fr(n) {
4312
4294
  const e = n.config;
4313
4295
  u(
4314
4296
  e.authDomain,
@@ -4316,17 +4298,17 @@ function $r(n) {
4316
4298
  "auth-domain-config-required"
4317
4299
  /* AuthErrorCode.MISSING_AUTH_DOMAIN */
4318
4300
  );
4319
- const t = e.emulator ? We(e, xr) : `https://${n.config.authDomain}/${Dr}`, i = {
4301
+ const t = e.emulator ? je(e, Ur) : `https://${n.config.authDomain}/${Mr}`, i = {
4320
4302
  apiKey: e.apiKey,
4321
4303
  appName: n.name,
4322
4304
  v: se
4323
- }, r = Vr.get(n.config.apiHost);
4305
+ }, r = xr.get(n.config.apiHost);
4324
4306
  r && (i.eid = r);
4325
4307
  const s = n._getFrameworks();
4326
4308
  return s.length && (i.fw = s.join(",")), `${t}?${oe(i).slice(1)}`;
4327
4309
  }
4328
- async function Hr(n) {
4329
- const e = await Mr(n), t = S().gapi;
4310
+ async function Vr(n) {
4311
+ const e = await Or(n), t = E().gapi;
4330
4312
  return u(
4331
4313
  t,
4332
4314
  n,
@@ -4334,24 +4316,24 @@ async function Hr(n) {
4334
4316
  /* AuthErrorCode.INTERNAL_ERROR */
4335
4317
  ), e.open({
4336
4318
  where: document.body,
4337
- url: $r(n),
4319
+ url: Fr(n),
4338
4320
  messageHandlersFilter: t.iframes.CROSS_ORIGIN_IFRAMES_FILTER,
4339
- attributes: Fr,
4321
+ attributes: Dr,
4340
4322
  dontclear: !0
4341
4323
  }, (i) => new Promise(async (r, s) => {
4342
4324
  await i.restyle({
4343
4325
  // Prevent iframe from closing on mouse out.
4344
4326
  setHideOnLeave: !1
4345
4327
  });
4346
- const o = E(
4328
+ const o = b(
4347
4329
  n,
4348
4330
  "network-request-failed"
4349
4331
  /* AuthErrorCode.NETWORK_REQUEST_FAILED */
4350
- ), c = S().setTimeout(() => {
4332
+ ), c = E().setTimeout(() => {
4351
4333
  s(o);
4352
- }, Ur.get());
4334
+ }, Lr.get());
4353
4335
  function a() {
4354
- S().clearTimeout(c), r(i);
4336
+ E().clearTimeout(c), r(i);
4355
4337
  }
4356
4338
  i.ping(a).then(a, () => {
4357
4339
  s(o);
@@ -4374,12 +4356,12 @@ async function Hr(n) {
4374
4356
  * See the License for the specific language governing permissions and
4375
4357
  * limitations under the License.
4376
4358
  */
4377
- const Wr = {
4359
+ const $r = {
4378
4360
  location: "yes",
4379
4361
  resizable: "yes",
4380
4362
  statusbar: "yes",
4381
4363
  toolbar: "no"
4382
- }, jr = 500, Br = 600, Gr = "_blank", zr = "http://localhost";
4364
+ }, Hr = 500, jr = 600, Wr = "_blank", Br = "http://localhost";
4383
4365
  class pt {
4384
4366
  constructor(e) {
4385
4367
  this.window = e, this.associatedEvent = null;
@@ -4392,20 +4374,20 @@ class pt {
4392
4374
  }
4393
4375
  }
4394
4376
  }
4395
- function qr(n, e, t, i = jr, r = Br) {
4377
+ function Gr(n, e, t, i = Hr, r = jr) {
4396
4378
  const s = Math.max((window.screen.availHeight - r) / 2, 0).toString(), o = Math.max((window.screen.availWidth - i) / 2, 0).toString();
4397
4379
  let c = "";
4398
- const a = Object.assign(Object.assign({}, Wr), {
4380
+ const a = Object.assign(Object.assign({}, $r), {
4399
4381
  width: i.toString(),
4400
4382
  height: r.toString(),
4401
4383
  top: s,
4402
4384
  left: o
4403
- }), l = k().toLowerCase();
4404
- t && (c = Vt(l) ? Gr : t), Ft(l) && (e = e || zr, a.scrollbars = "yes");
4405
- const h = Object.entries(a).reduce((v, [y, f]) => `${v}${y}=${f},`, "");
4406
- if (Ei(l) && c !== "_self")
4407
- return Kr(e || "", c), new pt(null);
4408
- const m = window.open(e || "", c, h);
4385
+ }), l = w().toLowerCase();
4386
+ t && (c = Ft(l) ? Wr : t), xt(l) && (e = e || Br, a.scrollbars = "yes");
4387
+ const d = Object.entries(a).reduce((f, [y, _]) => `${f}${y}=${_},`, "");
4388
+ if (ki(l) && c !== "_self")
4389
+ return zr(e || "", c), new pt(null);
4390
+ const m = window.open(e || "", c, d);
4409
4391
  u(
4410
4392
  m,
4411
4393
  n,
@@ -4418,7 +4400,7 @@ function qr(n, e, t, i = jr, r = Br) {
4418
4400
  }
4419
4401
  return new pt(m);
4420
4402
  }
4421
- function Kr(n, e) {
4403
+ function zr(n, e) {
4422
4404
  const t = document.createElement("a");
4423
4405
  t.href = n, t.target = e;
4424
4406
  const i = document.createEvent("MouseEvent");
@@ -4440,7 +4422,7 @@ function Kr(n, e) {
4440
4422
  * See the License for the specific language governing permissions and
4441
4423
  * limitations under the License.
4442
4424
  */
4443
- const Jr = "__/auth/handler", Yr = "emulator/auth/handler", Xr = encodeURIComponent("fac");
4425
+ const qr = "__/auth/handler", Kr = "emulator/auth/handler", Jr = encodeURIComponent("fac");
4444
4426
  async function mt(n, e, t, i, r, s) {
4445
4427
  u(
4446
4428
  n.config.authDomain,
@@ -4461,24 +4443,24 @@ async function mt(n, e, t, i, r, s) {
4461
4443
  v: se,
4462
4444
  eventId: r
4463
4445
  };
4464
- if (e instanceof Kt) {
4465
- e.setDefaultLanguage(n.languageCode), o.providerId = e.providerId || "", Un(e.getCustomParameters()) || (o.customParameters = JSON.stringify(e.getCustomParameters()));
4466
- for (const [h, m] of Object.entries({}))
4467
- o[h] = m;
4446
+ if (e instanceof qt) {
4447
+ e.setDefaultLanguage(n.languageCode), o.providerId = e.providerId || "", Ln(e.getCustomParameters()) || (o.customParameters = JSON.stringify(e.getCustomParameters()));
4448
+ for (const [d, m] of Object.entries({}))
4449
+ o[d] = m;
4468
4450
  }
4469
4451
  if (e instanceof ce) {
4470
- const h = e.getScopes().filter((m) => m !== "");
4471
- h.length > 0 && (o.scopes = h.join(","));
4452
+ const d = e.getScopes().filter((m) => m !== "");
4453
+ d.length > 0 && (o.scopes = d.join(","));
4472
4454
  }
4473
4455
  n.tenantId && (o.tid = n.tenantId);
4474
4456
  const c = o;
4475
- for (const h of Object.keys(c))
4476
- c[h] === void 0 && delete c[h];
4477
- const a = await n._getAppCheckToken(), l = a ? `#${Xr}=${encodeURIComponent(a)}` : "";
4478
- return `${Qr(n)}?${oe(c).slice(1)}${l}`;
4457
+ for (const d of Object.keys(c))
4458
+ c[d] === void 0 && delete c[d];
4459
+ const a = await n._getAppCheckToken(), l = a ? `#${Jr}=${encodeURIComponent(a)}` : "";
4460
+ return `${Yr(n)}?${oe(c).slice(1)}${l}`;
4479
4461
  }
4480
- function Qr({ config: n }) {
4481
- return n.emulator ? We(n, Yr) : `https://${n.authDomain}/${Jr}`;
4462
+ function Yr({ config: n }) {
4463
+ return n.emulator ? je(n, Kr) : `https://${n.authDomain}/${qr}`;
4482
4464
  }
4483
4465
  /**
4484
4466
  * @license
@@ -4497,29 +4479,29 @@ function Qr({ config: n }) {
4497
4479
  * limitations under the License.
4498
4480
  */
4499
4481
  const Ne = "webStorageSupport";
4500
- class Zr {
4482
+ class Xr {
4501
4483
  constructor() {
4502
- this.eventManagers = {}, this.iframes = {}, this.originValidationPromises = {}, this._redirectPersistence = Zt, this._completeRedirectFn = kr, this._overrideRedirectResult = yr;
4484
+ this.eventManagers = {}, this.iframes = {}, this.originValidationPromises = {}, this._redirectPersistence = Qt, this._completeRedirectFn = wr, this._overrideRedirectResult = vr;
4503
4485
  }
4504
4486
  // Wrapping in async even though we don't await anywhere in order
4505
4487
  // to make sure errors are raised as promise rejections
4506
4488
  async _openPopup(e, t, i, r) {
4507
4489
  var s;
4508
- M((s = this.eventManagers[e._key()]) === null || s === void 0 ? void 0 : s.manager, "_initialize() not called before _openPopup()");
4490
+ L((s = this.eventManagers[e._key()]) === null || s === void 0 ? void 0 : s.manager, "_initialize() not called before _openPopup()");
4509
4491
  const o = await mt(e, t, i, Me(), r);
4510
- return qr(e, o, ze());
4492
+ return Gr(e, o, ze());
4511
4493
  }
4512
4494
  async _openRedirect(e, t, i, r) {
4513
4495
  await this._originValidation(e);
4514
4496
  const s = await mt(e, t, i, Me(), r);
4515
- return nr(s), new Promise(() => {
4497
+ return er(s), new Promise(() => {
4516
4498
  });
4517
4499
  }
4518
4500
  _initialize(e) {
4519
4501
  const t = e._key();
4520
4502
  if (this.eventManagers[t]) {
4521
4503
  const { manager: r, promise: s } = this.eventManagers[t];
4522
- return r ? Promise.resolve(r) : (M(s, "If manager is not set, promise should be"), s);
4504
+ return r ? Promise.resolve(r) : (L(s, "If manager is not set, promise should be"), s);
4523
4505
  }
4524
4506
  const i = this.initAndGetManager(e);
4525
4507
  return this.eventManagers[t] = { promise: i }, i.catch(() => {
@@ -4527,7 +4509,7 @@ class Zr {
4527
4509
  }), i;
4528
4510
  }
4529
4511
  async initAndGetManager(e) {
4530
- const t = await Hr(e), i = new Er(e);
4512
+ const t = await Vr(e), i = new kr(e);
4531
4513
  return t.register("authEvent", (r) => (u(
4532
4514
  r == null ? void 0 : r.authEvent,
4533
4515
  e,
@@ -4542,7 +4524,7 @@ class Zr {
4542
4524
  this.iframes[e._key()].send(Ne, { type: Ne }, (r) => {
4543
4525
  var s;
4544
4526
  const o = (s = r == null ? void 0 : r[0]) === null || s === void 0 ? void 0 : s[Ne];
4545
- o !== void 0 && t(!!o), L(
4527
+ o !== void 0 && t(!!o), O(
4546
4528
  e,
4547
4529
  "internal-error"
4548
4530
  /* AuthErrorCode.INTERNAL_ERROR */
@@ -4551,13 +4533,13 @@ class Zr {
4551
4533
  }
4552
4534
  _originValidation(e) {
4553
4535
  const t = e._key();
4554
- return this.originValidationPromises[t] || (this.originValidationPromises[t] = Cr(e)), this.originValidationPromises[t];
4536
+ return this.originValidationPromises[t] || (this.originValidationPromises[t] = Ar(e)), this.originValidationPromises[t];
4555
4537
  }
4556
4538
  get _shouldInitProactively() {
4557
- return Bt() || Be() || ke();
4539
+ return Wt() || Be() || ke();
4558
4540
  }
4559
4541
  }
4560
- const es = Zr;
4542
+ const Qr = Xr;
4561
4543
  var gt = "@firebase/auth", _t = "1.7.5";
4562
4544
  /**
4563
4545
  * @license
@@ -4575,7 +4557,7 @@ var gt = "@firebase/auth", _t = "1.7.5";
4575
4557
  * See the License for the specific language governing permissions and
4576
4558
  * limitations under the License.
4577
4559
  */
4578
- class ts {
4560
+ class Zr {
4579
4561
  constructor(e) {
4580
4562
  this.auth = e, this.internalListeners = /* @__PURE__ */ new Map();
4581
4563
  }
@@ -4626,7 +4608,7 @@ class ts {
4626
4608
  * See the License for the specific language governing permissions and
4627
4609
  * limitations under the License.
4628
4610
  */
4629
- function ns(n) {
4611
+ function es(n) {
4630
4612
  switch (n) {
4631
4613
  case "Node":
4632
4614
  return "node";
@@ -4642,7 +4624,7 @@ function ns(n) {
4642
4624
  return;
4643
4625
  }
4644
4626
  }
4645
- function is(n) {
4627
+ function ts(n) {
4646
4628
  Ze(new et(
4647
4629
  "auth",
4648
4630
  (e, { options: t }) => {
@@ -4655,9 +4637,9 @@ function is(n) {
4655
4637
  apiHost: "identitytoolkit.googleapis.com",
4656
4638
  tokenApiHost: "securetoken.googleapis.com",
4657
4639
  apiScheme: "https",
4658
- sdkClientVersion: Gt(n)
4659
- }, l = new Oi(i, r, s, a);
4660
- return Fi(l, t), l;
4640
+ sdkClientVersion: Bt(n)
4641
+ }, l = new Ci(i, r, s, a);
4642
+ return Di(l, t), l;
4661
4643
  },
4662
4644
  "PUBLIC"
4663
4645
  /* ComponentType.PUBLIC */
@@ -4676,14 +4658,14 @@ function is(n) {
4676
4658
  "auth"
4677
4659
  /* _ComponentName.AUTH */
4678
4660
  ).getImmediate());
4679
- return ((i) => new ts(i))(t);
4661
+ return ((i) => new Zr(i))(t);
4680
4662
  },
4681
4663
  "PRIVATE"
4682
4664
  /* ComponentType.PRIVATE */
4683
4665
  ).setInstantiationMode(
4684
4666
  "EXPLICIT"
4685
4667
  /* InstantiationMode.EXPLICIT */
4686
- )), Le(gt, _t, ns(n)), Le(gt, _t, "esm2017");
4668
+ )), Le(gt, _t, es(n)), Le(gt, _t, "esm2017");
4687
4669
  }
4688
4670
  /**
4689
4671
  * @license
@@ -4701,11 +4683,11 @@ function is(n) {
4701
4683
  * See the License for the specific language governing permissions and
4702
4684
  * limitations under the License.
4703
4685
  */
4704
- const rs = 5 * 60, ss = bt("authIdTokenMaxAge") || rs;
4686
+ const ns = 5 * 60, is = kt("authIdTokenMaxAge") || ns;
4705
4687
  let vt = null;
4706
- const os = (n) => async (e) => {
4688
+ const rs = (n) => async (e) => {
4707
4689
  const t = e && await e.getIdTokenResult(), i = t && ((/* @__PURE__ */ new Date()).getTime() - Date.parse(t.issuedAtTime)) / 1e3;
4708
- if (i && i > ss)
4690
+ if (i && i > is)
4709
4691
  return;
4710
4692
  const r = t == null ? void 0 : t.token;
4711
4693
  vt !== r && (vt = r, await fetch(n, {
@@ -4715,131 +4697,115 @@ const os = (n) => async (e) => {
4715
4697
  } : {}
4716
4698
  }));
4717
4699
  };
4718
- function as(n = Nn()) {
4719
- const e = Et(n, "auth");
4700
+ function ss(n = Pn()) {
4701
+ const e = bt(n, "auth");
4720
4702
  if (e.isInitialized())
4721
4703
  return e.getImmediate();
4722
- const t = xi(n, {
4723
- popupRedirectResolver: es,
4704
+ const t = Ui(n, {
4705
+ popupRedirectResolver: Qr,
4724
4706
  persistence: [
4725
- dr,
4726
- Zi,
4727
- Zt
4707
+ lr,
4708
+ Xi,
4709
+ Qt
4728
4710
  ]
4729
- }), i = bt("authTokenSyncURL");
4711
+ }), i = kt("authTokenSyncURL");
4730
4712
  if (i && typeof isSecureContext == "boolean" && isSecureContext) {
4731
4713
  const s = new URL(i, location.origin);
4732
4714
  if (location.origin === s.origin) {
4733
- const o = os(s.toString());
4734
- Ji(t, o, () => o(t.currentUser)), Ki(t, (c) => o(c));
4715
+ const o = rs(s.toString());
4716
+ qi(t, o, () => o(t.currentUser)), zi(t, (c) => o(c));
4735
4717
  }
4736
4718
  }
4737
- const r = Cn("auth");
4738
- return r && Vi(t, `http://${r}`), t;
4719
+ const r = An("auth");
4720
+ return r && xi(t, `http://${r}`), t;
4739
4721
  }
4740
- function cs() {
4722
+ function os() {
4741
4723
  var n, e;
4742
4724
  return (e = (n = document.getElementsByTagName("head")) === null || n === void 0 ? void 0 : n[0]) !== null && e !== void 0 ? e : document;
4743
4725
  }
4744
- Li({
4726
+ Ni({
4745
4727
  loadJS(n) {
4746
4728
  return new Promise((e, t) => {
4747
4729
  const i = document.createElement("script");
4748
4730
  i.setAttribute("src", n), i.onload = e, i.onerror = (r) => {
4749
- const s = E(
4731
+ const s = b(
4750
4732
  "internal-error"
4751
4733
  /* AuthErrorCode.INTERNAL_ERROR */
4752
4734
  );
4753
4735
  s.customData = r, t(s);
4754
- }, i.type = "text/javascript", i.charset = "UTF-8", cs().appendChild(i);
4736
+ }, i.type = "text/javascript", i.charset = "UTF-8", os().appendChild(i);
4755
4737
  });
4756
4738
  },
4757
4739
  gapiScript: "https://apis.google.com/js/api.js",
4758
4740
  recaptchaV2Script: "https://www.google.com/recaptcha/api.js",
4759
4741
  recaptchaEnterpriseScript: "https://www.google.com/recaptcha/enterprise.js?render="
4760
4742
  });
4761
- is(
4743
+ ts(
4762
4744
  "Browser"
4763
4745
  /* ClientPlatform.BROWSER */
4764
4746
  );
4765
- var ls = { firebase: { apiKey: "AIzaSyAj8JdCHtP0Vc5vZobCfgoLzWxPIn0WUG4", authDomain: "feedme-dev-4c3ef.firebaseapp.com", databaseURL: "https://feedme-dev-4c3ef.firebaseio.com", projectId: "feedme-dev-4c3ef", storageBucket: "feedme-dev-4c3ef.appspot.com", messagingSenderId: "458797803788", appId: "1:458797803788:web:37f2af2926a84288f0c129", measurementId: "G-J2QG09D2Q7" }, assetBucketUrl: "feedme-dev-4c3ef.appspot.com", importFilesBucketUrl: "feedme-dev-4c3ef.appspot.com", clientId: "1a362d621873497b277ea55258cc82594ba148d235257f7bd44ea2acc132d8a4", featureFlagApiKey: "MaGoXrEWuEJNpWgKTqseee" }, us = { authUrl: "https://portal-v2-dev.feedmeapi.com/", slackWebhookUrl: "https://hooks.slack.com/services/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", appUrl: "feedmedev.vip", crmUrl: "crm.feedmedev.cc", paymentPortalUrl: "https://portal.feedmedev.cc/payment/payout-account", licensePortalUrl: "https://license.feedmedev.cc/", marketingV1Portal: "https://marketing-v1.feedmedev.cc", voucherAppUrl: "https://voucher.feedmedev.cc/" };
4766
- const ds = {
4747
+ var as = { firebase: { apiKey: "AIzaSyA_isPR1-9bX7UmRiJIhsIRNNwdn6DdmW4", authDomain: "feedme-253402.firebaseapp.com", databaseURL: "https://feedme-253402.firebaseio.com", projectId: "feedme-253402", storageBucket: "image.feedme.cc", messagingSenderId: "128512026847", appId: "1:128512026847:web:7c5c8ab7e8b90502dc616a", measurementId: "G-LTKS7N2HQS" }, assetBucketUrl: "static.feedme.cc", importFilesBucketUrl: "feedme-253402.appspot.com", clientId: "d5f8840d63dbb758b6c4ee2a5e8b013d15dd25e242c457481326062b83962476", featureFlagApiKey: "6GhcttsJ9Rj9cTevcdrpin" }, cs = { authUrl: "https://portal-v2.feedmeapi.com/", slackWebhookUrl: "https://hooks.slack.com/services/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", appUrl: "member.feedme.cc", crmUrl: "crm.feedme.cc", paymentPortalUrl: "https://portal.feedme.cc/payment/payout-account", licensePortalUrl: "https://license.feedme.cc/", marketingV1Portal: "https://marketing-v1.feedme.cc", voucherAppUrl: "https://voucher.feedme.cc/" };
4748
+ const ls = {
4767
4749
  key: 2,
4768
4750
  class: "h-full w-full"
4769
- }, hs = ["src"], Ns = /* @__PURE__ */ xe({
4751
+ }, us = ["src"], As = /* @__PURE__ */ xe({
4770
4752
  __name: "App",
4771
4753
  setup(n) {
4772
- const e = ge(), t = gn(), i = _n(), r = Tt(), s = In(), o = yn(), c = wt(), a = ne(c.query.showHeader !== "false"), l = ne(!1), { currentBusiness: h } = ge();
4773
- q(
4774
- [
4775
- () => {
4776
- var d;
4777
- return (d = h.value) == null ? void 0 : d._id;
4778
- },
4779
- () => e.currentCountry.value,
4780
- () => {
4781
- var d;
4782
- return (d = e.sessionUser.value) == null ? void 0 : d.id;
4783
- }
4784
- ],
4785
- ([d]) => {
4786
- r.reset(), d && r.read(d);
4787
- },
4788
- { immediate: !0, flush: "sync" }
4789
- ), dn(() => r.reset()), q(
4754
+ const e = ge(), t = pn(), i = mn(), r = _n(), s = vn(), o = wt(), c = ee(o.query.showHeader !== "false"), a = ee(!1), { currentBusiness: l } = ge();
4755
+ ie(
4790
4756
  () => {
4791
- var d;
4792
- return (d = h.value) == null ? void 0 : d._id;
4757
+ var h;
4758
+ return (h = l.value) == null ? void 0 : h._id;
4793
4759
  },
4794
- (d) => {
4795
- d && vn(d);
4760
+ (h) => {
4761
+ h && gn(h);
4796
4762
  },
4797
4763
  { immediate: !0 }
4798
4764
  );
4799
- const m = ne(!1), v = X(() => i.version), y = X(() => {
4800
- const d = e.currentCountry.value || "MY", g = tt.getIdToken(), b = h.value._id;
4801
- return `${us.marketingV1Portal}/b/${b}/marketing/overview?showHeader=false&country=${d}&token=${g}`;
4765
+ const d = ee(!1), m = ne(() => i.version), f = ne(() => {
4766
+ const h = e.currentCountry.value || "MY", I = tt.getIdToken(), T = l.value._id;
4767
+ return `${cs.marketingV1Portal}/b/${T}/marketing/overview?showHeader=false&country=${h}&token=${I}`;
4802
4768
  });
4803
- async function f() {
4804
- if (Dn().length) {
4769
+ async function y() {
4770
+ if (Mn().length) {
4805
4771
  console.warn("CONNECT: initFirebase: Firebase already initialized");
4806
4772
  return;
4807
4773
  }
4808
- const d = xn(ls.firebase), g = await mn.getCustomToken(), b = as();
4809
- await qi(b, g), Fn(d), console.log("initFirebase", d);
4774
+ const h = Un(as.firebase), I = await fn.getCustomToken(), T = ss();
4775
+ await Gi(T, I), Dn(h), console.log("initFirebase", h);
4810
4776
  }
4811
- const w = async () => {
4812
- m.value = !1, await fn(), console.log("forceRerender"), tt.setBusinessId(h.value._id), await i.readPremium(), !l.value && v.value === "v2" ? e.registerSidebarComponent(Wn) : e.hideSidebarToggle(!0), await f(), l.value = !0, m.value = !0;
4777
+ const _ = async () => {
4778
+ d.value = !1, await dn(), console.log("forceRerender"), tt.setBusinessId(l.value._id), await i.readPremium(), !a.value && m.value === "v2" ? e.registerSidebarComponent($n) : e.hideSidebarToggle(!0), await y(), a.value = !0, d.value = !0;
4813
4779
  };
4814
- return hn(() => {
4815
- if (Vn.Config.setCountry(e.currentCountry.value || "MY"), t.initProvider(s, o), !a.value) {
4816
- const d = document.getElementsByClassName("app-header")[0], g = document.getElementsByClassName("app-sidebar")[0], b = document.getElementsByClassName("app-container")[0], T = document.getElementsByTagName("main")[0];
4817
- d == null || d.classList.add("!hidden"), g == null || g.classList.add("!pt-0"), b == null || b.classList.add("!pt-0"), T == null || T.classList.add("!pt-0"), e.hideSidebarToggle(!0);
4780
+ return un(() => {
4781
+ if (xn.Config.setCountry(e.currentCountry.value || "MY"), t.initProvider(r, s), !c.value) {
4782
+ const h = document.getElementsByClassName("app-header")[0], I = document.getElementsByClassName("app-sidebar")[0], T = document.getElementsByClassName("app-container")[0], M = document.getElementsByTagName("main")[0];
4783
+ h == null || h.classList.add("!hidden"), I == null || I.classList.add("!pt-0"), T == null || T.classList.add("!pt-0"), M == null || M.classList.add("!pt-0"), e.hideSidebarToggle(!0);
4818
4784
  }
4819
- h.value != null && (console.log("App mounted, forceRerender"), w());
4820
- }), q(
4785
+ l.value != null && (console.log("App mounted, forceRerender"), _());
4786
+ }), ie(
4821
4787
  () => e.currentBusiness.value,
4822
- async (d, g) => {
4823
- console.log("Current business changed"), d != null && d._id != g._id && (console.log("forceRerender when business changes", d, g), w());
4788
+ async (h, I) => {
4789
+ console.log("Current business changed"), h != null && h._id != I._id && (console.log("forceRerender when business changes", h, I), _());
4824
4790
  }
4825
- ), (d, g) => (j(), me(It, null, [
4826
- _(m) && _(v) === "v2" ? (j(), Oe(_(pn), { key: 0 })) : Pe("", !0),
4827
- _(m) && _(v) === "v2" && _(a) ? (j(), Oe(oi, { key: 1 })) : Pe("", !0),
4828
- _(m) && _(v) !== "v2" ? (j(), me("div", ds, [
4829
- R(bn, {
4830
- json: { url: _(y) }
4791
+ ), (h, I) => (j(), me(It, null, [
4792
+ g(d) && g(m) === "v2" ? (j(), Oe(g(hn), { key: 0 })) : Pe("", !0),
4793
+ g(d) && g(m) === "v2" && g(c) ? (j(), Oe(ri, { key: 1 })) : Pe("", !0),
4794
+ g(d) && g(m) !== "v2" ? (j(), me("div", ls, [
4795
+ S(Tn, {
4796
+ json: { url: g(f) }
4831
4797
  }, null, 8, ["json"]),
4832
- I("iframe", {
4798
+ v("iframe", {
4833
4799
  allow: "clipboard-read; clipboard-write",
4834
4800
  frameBorder: "0",
4835
4801
  height: "100%",
4836
4802
  width: "100%",
4837
- src: _(y)
4838
- }, null, 8, hs)
4803
+ src: g(f)
4804
+ }, null, 8, us)
4839
4805
  ])) : Pe("", !0)
4840
4806
  ], 64));
4841
4807
  }
4842
4808
  });
4843
4809
  export {
4844
- Ns as default
4810
+ As as default
4845
4811
  };