@feedmepos/mf-connect 0.0.39-prod → 0.1.0-beta.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (101) hide show
  1. package/dist/Analytic-DSD9TsKr.js +622 -0
  2. package/dist/{App-X3fNEBF3.js → App-D8a5eW51.js} +250 -249
  3. package/dist/Broadcast-C8jgMe6g.js +223 -0
  4. package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-CRYS_tzZ.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-pG8WvV4I.js} +20 -20
  5. package/dist/Card-C1K7ULPo.js +825 -0
  6. package/dist/Collections-lMrdPUuM.js +453 -0
  7. package/dist/Credit-CJfU5tP4.js +220 -0
  8. package/dist/{EditCampaignSheet.vue_vue_type_script_setup_true_lang-DoZyevfa.js → EditCampaignSheet.vue_vue_type_script_setup_true_lang-BYoaa_-x.js} +1042 -1011
  9. package/dist/EffectSheet.vue_vue_type_style_index_0_lang-CzEtOmp0.js +345 -0
  10. package/dist/Experience-Bp2ki8gU.js +221 -0
  11. package/dist/Game-BpTf6ebE.js +255 -0
  12. package/dist/ImageInput.vue_vue_type_script_setup_true_lang-rWUkV9gn.js +144 -0
  13. package/dist/{MainLayout-DpZC6o3R.js → LottieAnimation.vue_vue_type_script_setup_true_lang-CyGJxUol.js} +19 -53
  14. package/dist/MainLayout-B1aJoR95.js +41 -0
  15. package/dist/Marketing-BiKE2gxA.js +316 -0
  16. package/dist/Member-BSWyy32a.js +69 -0
  17. package/dist/MemberList-CHlGREyR.js +1733 -0
  18. package/dist/MemberOverview-wL_ailso.js +58 -0
  19. package/dist/{MemberTransactions-DueaXBCy.js → MemberTransactions-BzHiXCnp.js} +1 -1
  20. package/dist/MessageInput.vue_vue_type_script_setup_true_lang-e-zWg08J.js +432 -0
  21. package/dist/Mission-8IGT3T2C.js +261 -0
  22. package/dist/Point-CbbJ6ohd.js +222 -0
  23. package/dist/Promotion-BYXCJa_S.js +247 -0
  24. package/dist/{RuleGroup.vue_vue_type_script_setup_true_lang-_RX1J0Br.js → RuleGroup.vue_vue_type_script_setup_true_lang-Bruh-umZ.js} +557 -557
  25. package/dist/Segment-DXDNM0yd.js +437 -0
  26. package/dist/Setting-CLpvvZTv.js +1901 -0
  27. package/dist/Store-C6-P6bwc.js +1511 -0
  28. package/dist/StoreRewards-CUM2irXK.js +401 -0
  29. package/dist/{StoreTransactions.vue_vue_type_script_setup_true_lang-CLFiuO5k.js → StoreTransactions.vue_vue_type_script_setup_true_lang-JaRdmqif.js} +10 -10
  30. package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-CoMQBL4P.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-DEb4OBcX.js} +1 -1
  31. package/dist/{Tier-CftEoP_R.js → Tier-DZTDxWBo.js} +481 -453
  32. package/dist/{Title-BsavXbYh.js → Title-C2Dr5ceK.js} +314 -295
  33. package/dist/Transaction-BL4mS29d.js +39 -0
  34. package/dist/Voucher-Cx0r2-df.js +490 -0
  35. package/dist/ZodTextField.vue_vue_type_script_setup_true_lang-DWuAODUF.js +56 -0
  36. package/dist/{app-BNmAx3zq.js → app-B_xuZ5HB.js} +1 -1
  37. package/dist/app-wE5HTF_Y.js +5762 -0
  38. package/dist/app.js +5 -3
  39. package/dist/{business-DGL4Ayx0.js → business-DSv8zM8C.js} +1 -1
  40. package/dist/{campaign-D94sS1kM.js → campaign-7y5qquHZ.js} +5 -3
  41. package/dist/{collection.fn-BHJ1ISqO.js → collection.fn-BxVZQAx0.js} +2 -2
  42. package/dist/dto-Ew1QwLci.js +2778 -0
  43. package/dist/{effect-CFRICzlM.js → effect-BzPh8fRI.js} +9 -9
  44. package/dist/{export-w2o9NYcy.js → export-C9tDplkA.js} +3 -3
  45. package/dist/{helper-CUDWQ8vq.js → helper-Sz7oQ0F4.js} +1 -1
  46. package/dist/{index-BGuLhEym.js → index-BQm0C3Jm.js} +3 -3
  47. package/dist/{index-BjwyxNSp.js → index-C-SOz7jt.js} +1 -1
  48. package/dist/{index-BcWJcD9f.js → index-C0lpADCo.js} +1 -1
  49. package/dist/{index-DIq2KVis.js → index-C3_4GUiI.js} +1 -1
  50. package/dist/{index-BPEV5Tzg.js → index-D-2nFLsg.js} +59 -47
  51. package/dist/{index-CFMBSL24.js → index-DBMaUGYI.js} +2 -2
  52. package/dist/{index-CpwFQFTV.js → index-DH_1nOJ_.js} +3 -3
  53. package/dist/index-Dy4pmQpt.js +29193 -0
  54. package/dist/{index-BQ6isIeo.js → index-_3qBsogG.js} +1 -1
  55. package/dist/index-gIRszcHf.js +3 -0
  56. package/dist/{index-VjUw31dN.js → index-tv4t0Pnh.js} +1 -1
  57. package/dist/{index-tZ1aqhks.js → index-z0IfdrZk.js} +319 -281
  58. package/dist/{index.esm2017-zciuPty-.js → index.esm2017-BnKJDxUo.js} +55 -55
  59. package/dist/{loading-GuXe5bYG.js → loading-Ds-yFYhc.js} +469 -460
  60. package/dist/{membership-BHWJVI3e.js → membership-DaiVw9qF.js} +3 -3
  61. package/dist/money-BHtBdZoz.js +15 -0
  62. package/dist/number-CZhcB8ef.js +12 -0
  63. package/dist/{rule-MgNa_8FF.js → rule-Cd2M6Ri2.js} +2 -2
  64. package/dist/{rule-builder-BsBCWzq_.js → rule-builder-B6og27Q1.js} +1 -1
  65. package/dist/style.css +1 -1
  66. package/dist/{template-D6k3lusq.js → template-DouRWBpv.js} +63 -63
  67. package/dist/{usePagination-JoYaROkV.js → usePagination-BeF5K3M7.js} +85 -85
  68. package/dist/vue-i18n-BTlOChXs.js +2365 -0
  69. package/dist/{xlsx-ClrA4KOh.js → xlsx-SahfXQ70.js} +517 -517
  70. package/dist/zod-Bg2FbC-D.js +90 -0
  71. package/package.json +7 -4
  72. package/dist/Analytic-DMFueUju.js +0 -620
  73. package/dist/Broadcast-YIfWIXeA.js +0 -216
  74. package/dist/Card-BIxlgQm7.js +0 -824
  75. package/dist/Collections-M6DaHM2W.js +0 -441
  76. package/dist/Credit-BtRy-xoY.js +0 -214
  77. package/dist/EffectSheet.vue_vue_type_style_index_0_lang-D5DNTBSQ.js +0 -344
  78. package/dist/Experience-DGm1lnqj.js +0 -211
  79. package/dist/Game-B8-lG7qq.js +0 -250
  80. package/dist/ImageInput.vue_vue_type_script_setup_true_lang-ByhTB9Ie.js +0 -144
  81. package/dist/Marketing-DtG3AIWr.js +0 -309
  82. package/dist/Member-K443-9Vy.js +0 -92
  83. package/dist/MemberList-CYXHXFTL.js +0 -1735
  84. package/dist/MemberOverview-C2n9oJZh.js +0 -58
  85. package/dist/MessageInput.vue_vue_type_script_setup_true_lang-Bk2HLVmt.js +0 -203
  86. package/dist/Mission-CN5umXXA.js +0 -248
  87. package/dist/Point-XAm6H2p_.js +0 -220
  88. package/dist/Promotion-DsrA4KiE.js +0 -244
  89. package/dist/Segment-CZGGHoAu.js +0 -435
  90. package/dist/Setting-BjfxLKyp.js +0 -1870
  91. package/dist/Store-D_B-vhh3.js +0 -1513
  92. package/dist/StoreRewards-BjHffUKj.js +0 -429
  93. package/dist/Transaction-CdxzoKDG.js +0 -36
  94. package/dist/Voucher-B_9Nv1Mr.js +0 -485
  95. package/dist/ZodTextField.vue_vue_type_script_setup_true_lang-3LlSDiq0.js +0 -140
  96. package/dist/app--1Ks5Hms.js +0 -2974
  97. package/dist/dto-X0Eeujxx.js +0 -1151
  98. package/dist/index-BPNG8N-w.js +0 -11
  99. package/dist/index-DWM9MWGj.js +0 -28058
  100. package/dist/money-CrttVpCp.js +0 -15
  101. package/dist/number-CIndGU4O.js +0 -12
@@ -2,67 +2,68 @@ import { defineComponent as lt, ref as te, h as Q, watch as ut, resolveComponent
2
2
  import { useRouter as nn, useRoute as ht, RouterView as rn } from "vue-router";
3
3
  import { useCoreStore as We, FeedMeAuth as sn } from "@feedmepos/mf-common";
4
4
  import { u as on } from "./app-wDQR6dpb.js";
5
- import { u as an } from "./business-DGL4Ayx0.js";
6
- import "./index-BPNG8N-w.js";
5
+ import { u as an } from "./business-DSv8zM8C.js";
6
+ import "./index-gIRszcHf.js";
7
7
  import { components as Z, useSnackbar as cn, useDialog as ln } from "@feedmepos/ui-library";
8
- import { R as f } from "./app--1Ks5Hms.js";
9
- import { J as un } from "./JsonViewer-v8_C7l5N.js";
10
- import { r as ye, L as dn, g as ft, i as hn, a as fn, _ as je, C as Ge, b as pn, S as z, c as w, d as j, E as be, e as mn, f as pt, h as gn, j as _n, k as mt, l as g, m as vn, F as Re, n as In, q as K, o as Tn, p as wn, s as yn, t as En, u as kn } from "./index.esm2017-zciuPty-.js";
8
+ import { u as un } from "./vue-i18n-BTlOChXs.js";
9
+ import { R as f } from "./app-wE5HTF_Y.js";
10
+ import { J as dn } from "./JsonViewer-v8_C7l5N.js";
11
+ import { r as ye, L as hn, g as ft, i as fn, a as pn, _ as je, C as Ge, b as mn, S as z, c as w, d as j, E as be, e as gn, f as pt, h as _n, j as vn, k as mt, l as g, m as In, F as Re, n as Tn, q as K, o as wn, p as yn, s as En, t as kn, u as Sn } from "./index.esm2017-BnKJDxUo.js";
11
12
  import { _ as Pe } from "./tslib.es6-BCqqvLQ_.js";
12
- import { S as Be } from "./index-DWM9MWGj.js";
13
- const Sn = /* @__PURE__ */ lt({
13
+ import { S as Be } from "./index-Dy4pmQpt.js";
14
+ const bn = /* @__PURE__ */ lt({
14
15
  __name: "NavigationTab",
15
16
  setup(n) {
16
- const e = te(), t = [
17
+ const { t: e } = un(), t = te(), i = [
17
18
  {
18
- label: "Analytic",
19
+ label: e("connect.navigation.analytic"),
19
20
  value: f["$connect-ANALYTIC"]
20
21
  },
21
22
  {
22
- label: "Campaign",
23
+ label: e("connect.navigation.campaign"),
23
24
  value: f["$connect-CAMPAIGN"],
24
25
  children: [
25
26
  {
26
- label: "Promotion",
27
+ label: e("connect.navigation.promotion"),
27
28
  value: f["$connect-CAMPAIGN_PROMOTION"]
28
29
  },
29
30
  {
30
- label: "Voucher",
31
+ label: e("connect.navigation.voucher"),
31
32
  value: f["$connect-CAMPAIGN_VOUCHER"]
32
33
  },
33
34
  {
34
- label: "Broadcast",
35
+ label: e("connect.navigation.broadcast"),
35
36
  value: f["$connect-CAMPAIGN_BROADCAST"]
36
37
  }
37
38
  ]
38
39
  },
39
40
  {
40
- label: "Program",
41
+ label: e("connect.navigation.program"),
41
42
  value: f["$connect-PROGRAM"],
42
43
  children: [
43
44
  {
44
- label: "Tier",
45
+ label: e("connect.navigation.tier"),
45
46
  value: f["$connect-PROGRAM_TIER"]
46
47
  },
47
48
  {
48
- label: "Title",
49
+ label: e("connect.navigation.title"),
49
50
  value: f["$connect-PROGRAM_TITLE"]
50
51
  },
51
52
  {
52
- label: "Experience",
53
+ label: e("connect.navigation.experience"),
53
54
  value: f["$connect-PROGRAM_EXPERIENCE"]
54
55
  },
55
56
  {
56
- label: "Point",
57
+ label: e("connect.navigation.point"),
57
58
  value: f["$connect-PROGRAM_POINT"],
58
59
  badge: () => Q(Z.FmPill, { variant: "premium" })
59
60
  },
60
61
  {
61
- label: "Credit",
62
+ label: e("connect.navigation.credit"),
62
63
  value: f["$connect-PROGRAM_CREDIT"]
63
64
  },
64
65
  {
65
- label: "Game",
66
+ label: e("connect.navigation.game"),
66
67
  value: f["$connect-PROGRAM_GAME"],
67
68
  badge: () => Q(Z.FmPill, { variant: "premium" })
68
69
  },
@@ -73,31 +74,31 @@ const Sn = /* @__PURE__ */ lt({
73
74
  ]
74
75
  },
75
76
  {
76
- label: "Loyalty",
77
+ label: e("connect.navigation.loyalty"),
77
78
  value: f["$connect-LOYALTY"],
78
79
  children: [
79
80
  {
80
- label: "Member",
81
+ label: e("connect.navigation.member"),
81
82
  value: f["$connect-LOYALTY_MEMBER_LIST"]
82
83
  },
83
84
  {
84
- label: "Segments",
85
+ label: e("connect.navigation.segments"),
85
86
  value: f["$connect-LOYALTY_SEGMENT"],
86
87
  badge: () => Q(Z.FmPill, { variant: "premium" })
87
88
  },
88
89
  {
89
- label: "Card",
90
+ label: e("connect.navigation.card"),
90
91
  value: f["$connect-LOYALTY_CARD"],
91
92
  badge: () => Q(Z.FmPill, { variant: "premium" })
92
93
  }
93
94
  ]
94
95
  },
95
96
  {
96
- label: "Store",
97
+ label: e("connect.navigation.store"),
97
98
  value: f["$connect-STORE"]
98
99
  },
99
100
  {
100
- label: "Transaction",
101
+ label: e("connect.navigation.transaction"),
101
102
  value: f["$connect-TRANSACTION"]
102
103
  },
103
104
  // {
@@ -105,34 +106,34 @@ const Sn = /* @__PURE__ */ lt({
105
106
  // value: ROUTE_NAME['$connect-MARKETING'],
106
107
  // },
107
108
  {
108
- label: "Setting",
109
+ label: e("connect.navigation.setting"),
109
110
  value: f["$connect-SETTING"]
110
111
  }
111
- ], i = nn(), r = ht(), s = t.reduce((c, a) => [...(a.children ?? []).map((l) => l.value), ...c, a.value], []);
112
+ ], r = nn(), s = ht(), o = i.reduce((a, l) => [...(l.children ?? []).map((d) => d.value), ...a, l.value], []);
112
113
  ut(
113
- () => r,
114
- (c) => {
115
- const a = c.matched.map((l) => l.name).reverse();
116
- e.value = a.find((l) => s.includes(l));
114
+ () => s,
115
+ (a) => {
116
+ const l = a.matched.map((d) => d.name).reverse();
117
+ t.value = l.find((d) => o.includes(d));
117
118
  },
118
119
  { immediate: !0 }
119
120
  );
120
- async function o(c) {
121
- await i.push({ name: c });
121
+ async function c(a) {
122
+ await r.push({ name: a });
122
123
  }
123
- return (c, a) => {
124
- var d;
125
- const l = Yt("FmCollapsibleTabs");
126
- return ne(), dt(l, {
124
+ return (a, l) => {
125
+ var h;
126
+ const d = Yt("FmCollapsibleTabs");
127
+ return ne(), dt(d, {
127
128
  class: "border-fm-color-neutral-gray-100 border-r py-16 px-4",
128
- "model-value": (d = P(e)) == null ? void 0 : d.toString(),
129
- items: t,
130
- "onUpdate:modelValue": o
129
+ "model-value": (h = P(t)) == null ? void 0 : h.toString(),
130
+ items: i,
131
+ "onUpdate:modelValue": c
131
132
  }, null, 8, ["model-value"]);
132
133
  };
133
134
  }
134
135
  });
135
- var bn = "firebase", Rn = "10.12.4";
136
+ var Rn = "firebase", Pn = "10.12.4";
136
137
  /**
137
138
  * @license
138
139
  * Copyright 2020 Google LLC
@@ -149,13 +150,13 @@ var bn = "firebase", Rn = "10.12.4";
149
150
  * See the License for the specific language governing permissions and
150
151
  * limitations under the License.
151
152
  */
152
- ye(bn, Rn, "app");
153
+ ye(Rn, Pn, "app");
153
154
  function gt() {
154
155
  return {
155
156
  "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."
156
157
  };
157
158
  }
158
- const Pn = gt, _t = new be("auth", "Firebase", gt());
159
+ const An = gt, _t = new be("auth", "Firebase", gt());
159
160
  /**
160
161
  * @license
161
162
  * Copyright 2020 Google LLC
@@ -172,8 +173,8 @@ const Pn = gt, _t = new be("auth", "Firebase", gt());
172
173
  * See the License for the specific language governing permissions and
173
174
  * limitations under the License.
174
175
  */
175
- const ae = new dn("@firebase/auth");
176
- function An(n, ...e) {
176
+ const ae = new hn("@firebase/auth");
177
+ function Cn(n, ...e) {
177
178
  ae.logLevel <= mt.WARN && ae.warn(`Auth (${z}): ${n}`, ...e);
178
179
  }
179
180
  function ie(n, ...e) {
@@ -202,7 +203,7 @@ function I(n, ...e) {
202
203
  return Ae(n, ...e);
203
204
  }
204
205
  function vt(n, e, t) {
205
- const i = Object.assign(Object.assign({}, Pn()), { [e]: t });
206
+ const i = Object.assign(Object.assign({}, An()), { [e]: t });
206
207
  return new be("auth", "Firebase", i).create(e, {
207
208
  appName: n.name
208
209
  });
@@ -248,7 +249,7 @@ function Ee() {
248
249
  var n;
249
250
  return typeof self < "u" && ((n = self.location) === null || n === void 0 ? void 0 : n.href) || "";
250
251
  }
251
- function Cn() {
252
+ function On() {
252
253
  return qe() === "http:" || qe() === "https:";
253
254
  }
254
255
  function qe() {
@@ -271,15 +272,15 @@ function qe() {
271
272
  * See the License for the specific language governing permissions and
272
273
  * limitations under the License.
273
274
  */
274
- function On() {
275
+ function Nn() {
275
276
  return typeof navigator < "u" && navigator && "onLine" in navigator && typeof navigator.onLine == "boolean" && // Apply only for traditional web apps and Chrome extensions.
276
277
  // This is especially true for Cordova apps which have unreliable
277
278
  // navigator.onLine behavior unless cordova-plugin-network-information is
278
279
  // installed which overwrites the native navigator.onLine value and
279
280
  // defines navigator.connection.
280
- (Cn() || pn() || "connection" in navigator) ? navigator.onLine : !0;
281
+ (On() || mn() || "connection" in navigator) ? navigator.onLine : !0;
281
282
  }
282
- function Nn() {
283
+ function Ln() {
283
284
  if (typeof navigator > "u")
284
285
  return null;
285
286
  const n = navigator;
@@ -309,10 +310,10 @@ function Nn() {
309
310
  */
310
311
  class J {
311
312
  constructor(e, t) {
312
- this.shortDelay = e, this.longDelay = t, b(t > e, "Short delay should be less than long delay!"), this.isMobile = hn() || fn();
313
+ this.shortDelay = e, this.longDelay = t, b(t > e, "Short delay should be less than long delay!"), this.isMobile = fn() || pn();
313
314
  }
314
315
  get() {
315
- return On() ? this.isMobile ? this.longDelay : this.shortDelay : Math.min(5e3, this.shortDelay);
316
+ return Nn() ? this.isMobile ? this.longDelay : this.shortDelay : Math.min(5e3, this.shortDelay);
316
317
  }
317
318
  }
318
319
  /**
@@ -406,7 +407,7 @@ class It {
406
407
  * See the License for the specific language governing permissions and
407
408
  * limitations under the License.
408
409
  */
409
- const Ln = {
410
+ const Mn = {
410
411
  // Custom token errors.
411
412
  CREDENTIAL_MISMATCH: "custom-token-mismatch",
412
413
  // This can only happen if the SDK sends a bad request.
@@ -497,7 +498,7 @@ const Ln = {
497
498
  * See the License for the specific language governing permissions and
498
499
  * limitations under the License.
499
500
  */
500
- const Mn = new J(3e4, 6e4);
501
+ const Un = new J(3e4, 6e4);
501
502
  function he(n, e) {
502
503
  return n.tenantId && !e.tenantId ? Object.assign(Object.assign({}, e), { tenantId: n.tenantId }) : e;
503
504
  }
@@ -523,9 +524,9 @@ async function G(n, e, t, i, r = {}) {
523
524
  }
524
525
  async function Tt(n, e, t) {
525
526
  n._canInitEmulator = !1;
526
- const i = Object.assign(Object.assign({}, Ln), e);
527
+ const i = Object.assign(Object.assign({}, Mn), e);
527
528
  try {
528
- const r = new Un(n), s = await Promise.race([
529
+ const r = new Dn(n), s = await Promise.race([
529
530
  t(),
530
531
  r.promise
531
532
  ]);
@@ -564,14 +565,14 @@ function yt(n, e, t, i) {
564
565
  const r = `${e}${t}?${i}`;
565
566
  return n.config.emulator ? Ce(n.config, r) : `${n.config.apiScheme}://${r}`;
566
567
  }
567
- class Un {
568
+ class Dn {
568
569
  constructor(e) {
569
570
  this.auth = e, this.timer = null, this.promise = new Promise((t, i) => {
570
571
  this.timer = setTimeout(() => i(I(
571
572
  this.auth,
572
573
  "network-request-failed"
573
574
  /* AuthErrorCode.NETWORK_REQUEST_FAILED */
574
- )), Mn.get());
575
+ )), Un.get());
575
576
  });
576
577
  }
577
578
  clearNetworkTimeout() {
@@ -602,7 +603,7 @@ function ee(n, e, t) {
602
603
  * See the License for the specific language governing permissions and
603
604
  * limitations under the License.
604
605
  */
605
- async function Dn(n, e) {
606
+ async function Fn(n, e) {
606
607
  return G(n, "POST", "/v1/accounts:delete", e);
607
608
  }
608
609
  async function Et(n, e) {
@@ -633,7 +634,7 @@ function B(n) {
633
634
  } catch {
634
635
  }
635
636
  }
636
- async function Fn(n, e = !1) {
637
+ async function xn(n, e = !1) {
637
638
  const t = j(n), i = await t.getIdToken(e), r = Oe(i);
638
639
  u(
639
640
  r && r.exp && r.auth_time && r.iat,
@@ -660,7 +661,7 @@ function Oe(n) {
660
661
  if (e === void 0 || t === void 0 || i === void 0)
661
662
  return ie("JWT malformed, contained fewer than 3 sections"), null;
662
663
  try {
663
- const r = In(t);
664
+ const r = Tn(t);
664
665
  return r ? JSON.parse(r) : (ie("Failed to decode base64 JWT payload"), null);
665
666
  } catch (r) {
666
667
  return ie("Caught error parsing JWT payload as JSON", r == null ? void 0 : r.toString()), null;
@@ -704,10 +705,10 @@ async function q(n, e, t = !1) {
704
705
  try {
705
706
  return await e;
706
707
  } catch (i) {
707
- throw i instanceof Re && xn(i) && n.auth.currentUser === n && await n.auth.signOut(), i;
708
+ throw i instanceof Re && Vn(i) && n.auth.currentUser === n && await n.auth.signOut(), i;
708
709
  }
709
710
  }
710
- function xn({ code: n }) {
711
+ function Vn({ code: n }) {
711
712
  return n === "auth/user-disabled" || n === "auth/user-token-expired";
712
713
  }
713
714
  /**
@@ -726,7 +727,7 @@ function xn({ code: n }) {
726
727
  * See the License for the specific language governing permissions and
727
728
  * limitations under the License.
728
729
  */
729
- class Vn {
730
+ class Hn {
730
731
  constructor(e) {
731
732
  this.user = e, this.isRunning = !1, this.timerId = null, this.errorBackoff = 3e4;
732
733
  }
@@ -832,7 +833,7 @@ async function ce(n) {
832
833
  );
833
834
  const s = r.users[0];
834
835
  n._notifyReloadListener(s);
835
- const o = !((e = s.providerUserInfo) === null || e === void 0) && e.length ? kt(s.providerUserInfo) : [], c = $n(n.providerData, o), a = n.isAnonymous, l = !(n.email && s.passwordHash) && !(c != null && c.length), d = a ? l : !1, h = {
836
+ const o = !((e = s.providerUserInfo) === null || e === void 0) && e.length ? kt(s.providerUserInfo) : [], c = Wn(n.providerData, o), a = n.isAnonymous, l = !(n.email && s.passwordHash) && !(c != null && c.length), d = a ? l : !1, h = {
836
837
  uid: s.localId,
837
838
  displayName: s.displayName || null,
838
839
  photoURL: s.photoUrl || null,
@@ -846,11 +847,11 @@ async function ce(n) {
846
847
  };
847
848
  Object.assign(n, h);
848
849
  }
849
- async function Hn(n) {
850
+ async function $n(n) {
850
851
  const e = j(n);
851
852
  await ce(e), await e.auth._persistUserIfCurrent(e), e.auth._notifyListenersIfCurrent(e);
852
853
  }
853
- function $n(n, e) {
854
+ function Wn(n, e) {
854
855
  return [...n.filter((i) => !e.some((r) => r.providerId === i.providerId)), ...e];
855
856
  }
856
857
  function kt(n) {
@@ -882,7 +883,7 @@ function kt(n) {
882
883
  * See the License for the specific language governing permissions and
883
884
  * limitations under the License.
884
885
  */
885
- async function Wn(n, e) {
886
+ async function jn(n, e) {
886
887
  const t = await Tt(n, {}, async () => {
887
888
  const i = K({
888
889
  grant_type: "refresh_token",
@@ -903,7 +904,7 @@ async function Wn(n, e) {
903
904
  refreshToken: t.refresh_token
904
905
  };
905
906
  }
906
- async function jn(n, e) {
907
+ async function Gn(n, e) {
907
908
  return G(n, "POST", "/v2/accounts:revokeToken", he(n, e));
908
909
  }
909
910
  /**
@@ -967,7 +968,7 @@ class H {
967
968
  this.refreshToken = null;
968
969
  }
969
970
  async refresh(e, t) {
970
- const { accessToken: i, refreshToken: r, expiresIn: s } = await Wn(e, t);
971
+ const { accessToken: i, refreshToken: r, expiresIn: s } = await jn(e, t);
971
972
  this.updateTokensAndExpiration(i, r, Number(s));
972
973
  }
973
974
  updateTokensAndExpiration(e, t, i) {
@@ -1022,7 +1023,7 @@ function R(n, e) {
1022
1023
  class E {
1023
1024
  constructor(e) {
1024
1025
  var { uid: t, auth: i, stsTokenManager: r } = e, s = Pe(e, ["uid", "auth", "stsTokenManager"]);
1025
- this.providerId = "firebase", this.proactiveRefresh = new Vn(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 ke(s.createdAt || void 0, s.lastLoginAt || void 0);
1026
+ this.providerId = "firebase", this.proactiveRefresh = new Hn(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 ke(s.createdAt || void 0, s.lastLoginAt || void 0);
1026
1027
  }
1027
1028
  async getIdToken(e) {
1028
1029
  const t = await q(this, this.stsTokenManager.getToken(this.auth, e));
@@ -1034,10 +1035,10 @@ class E {
1034
1035
  ), this.accessToken !== t && (this.accessToken = t, await this.auth._persistUserIfCurrent(this), this.auth._notifyListenersIfCurrent(this)), t;
1035
1036
  }
1036
1037
  getIdTokenResult(e) {
1037
- return Fn(this, e);
1038
+ return xn(this, e);
1038
1039
  }
1039
1040
  reload() {
1040
- return Hn(this);
1041
+ return $n(this);
1041
1042
  }
1042
1043
  _assign(e) {
1043
1044
  this !== e && (u(
@@ -1076,7 +1077,7 @@ class E {
1076
1077
  if (w(this.auth.app))
1077
1078
  return Promise.reject(L(this.auth));
1078
1079
  const e = await this.getIdToken();
1079
- return await q(this, Dn(this.auth, { idToken: e })), this.stsTokenManager.clearRefreshToken(), this.auth.signOut();
1080
+ return await q(this, Fn(this.auth, { idToken: e })), this.stsTokenManager.clearRefreshToken(), this.auth.signOut();
1080
1081
  }
1081
1082
  toJSON() {
1082
1083
  return Object.assign(Object.assign({
@@ -1406,17 +1407,17 @@ function Ot(n = g()) {
1406
1407
  function fe(n = g()) {
1407
1408
  return /iphone|ipad|ipod/i.test(n) || /macintosh/i.test(n) && /mobile/i.test(n);
1408
1409
  }
1409
- function Gn(n = g()) {
1410
+ function Bn(n = g()) {
1410
1411
  var e;
1411
1412
  return fe(n) && !!(!((e = window.navigator) === null || e === void 0) && e.standalone);
1412
1413
  }
1413
- function Bn() {
1414
- return Tn() && document.documentMode === 10;
1414
+ function qn() {
1415
+ return wn() && document.documentMode === 10;
1415
1416
  }
1416
1417
  function Nt(n = g()) {
1417
1418
  return fe(n) || At(n) || Ot(n) || Ct(n) || /windows phone/i.test(n) || Pt(n);
1418
1419
  }
1419
- function qn() {
1420
+ function zn() {
1420
1421
  try {
1421
1422
  return !!(window && window !== window.top);
1422
1423
  } catch {
@@ -1470,7 +1471,7 @@ function Lt(n, e = []) {
1470
1471
  * See the License for the specific language governing permissions and
1471
1472
  * limitations under the License.
1472
1473
  */
1473
- class zn {
1474
+ class Kn {
1474
1475
  constructor(e) {
1475
1476
  this.auth = e, this.queue = [];
1476
1477
  }
@@ -1525,7 +1526,7 @@ class zn {
1525
1526
  * See the License for the specific language governing permissions and
1526
1527
  * limitations under the License.
1527
1528
  */
1528
- async function Kn(n, e = {}) {
1529
+ async function Jn(n, e = {}) {
1529
1530
  return G(n, "GET", "/v2/passwordPolicy", he(n, e));
1530
1531
  }
1531
1532
  /**
@@ -1544,12 +1545,12 @@ async function Kn(n, e = {}) {
1544
1545
  * See the License for the specific language governing permissions and
1545
1546
  * limitations under the License.
1546
1547
  */
1547
- const Jn = 6;
1548
- class Yn {
1548
+ const Yn = 6;
1549
+ class Xn {
1549
1550
  constructor(e) {
1550
1551
  var t, i, r, s;
1551
1552
  const o = e.customStrengthOptions;
1552
- this.customStrengthOptions = {}, this.customStrengthOptions.minPasswordLength = (t = o.minPasswordLength) !== null && t !== void 0 ? t : Jn, 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;
1553
+ this.customStrengthOptions = {}, this.customStrengthOptions.minPasswordLength = (t = o.minPasswordLength) !== null && t !== void 0 ? t : Yn, 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;
1553
1554
  }
1554
1555
  validatePassword(e) {
1555
1556
  var t, i, r, s, o, c;
@@ -1632,9 +1633,9 @@ class Yn {
1632
1633
  * See the License for the specific language governing permissions and
1633
1634
  * limitations under the License.
1634
1635
  */
1635
- class Xn {
1636
+ class Qn {
1636
1637
  constructor(e, t, i, r) {
1637
- 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 Xe(this), this.idTokenSubscription = new Xe(this), this.beforeStateQueue = new zn(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 = _t, 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;
1638
+ 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 Xe(this), this.idTokenSubscription = new Xe(this), this.beforeStateQueue = new Kn(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 = _t, 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;
1638
1639
  }
1639
1640
  _initializeWithPersistence(e, t) {
1640
1641
  return t && (this._popupRedirectResolver = k(t)), this._initializationPromise = this.queue(async () => {
@@ -1728,7 +1729,7 @@ class Xn {
1728
1729
  return this.directlySetCurrentUser(e);
1729
1730
  }
1730
1731
  useDeviceLanguage() {
1731
- this.languageCode = Nn();
1732
+ this.languageCode = Ln();
1732
1733
  }
1733
1734
  async _delete() {
1734
1735
  this._deleted = !0;
@@ -1779,7 +1780,7 @@ class Xn {
1779
1780
  return this.tenantId === null ? this._projectPasswordPolicy : this._tenantPasswordPolicies[this.tenantId];
1780
1781
  }
1781
1782
  async _updatePasswordPolicy() {
1782
- const e = await Kn(this), t = new Yn(e);
1783
+ const e = await Jn(this), t = new Xn(e);
1783
1784
  this.tenantId === null ? this._projectPasswordPolicy = t : this._tenantPasswordPolicies[this.tenantId] = t;
1784
1785
  }
1785
1786
  _getPersistence() {
@@ -1819,7 +1820,7 @@ class Xn {
1819
1820
  token: e,
1820
1821
  idToken: t
1821
1822
  };
1822
- this.tenantId != null && (i.tenantId = this.tenantId), await jn(this, i);
1823
+ this.tenantId != null && (i.tenantId = this.tenantId), await Gn(this, i);
1823
1824
  }
1824
1825
  }
1825
1826
  toJSON() {
@@ -1962,7 +1963,7 @@ class Xn {
1962
1963
  async _getAppCheckToken() {
1963
1964
  var e;
1964
1965
  const t = await ((e = this.appCheckServiceProvider.getImmediate({ optional: !0 })) === null || e === void 0 ? void 0 : e.getToken());
1965
- return t != null && t.error && An(`Error while retrieving App Check token: ${t.error}`), t == null ? void 0 : t.token;
1966
+ return t != null && t.error && Cn(`Error while retrieving App Check token: ${t.error}`), t == null ? void 0 : t.token;
1966
1967
  }
1967
1968
  }
1968
1969
  function pe(n) {
@@ -1970,7 +1971,7 @@ function pe(n) {
1970
1971
  }
1971
1972
  class Xe {
1972
1973
  constructor(e) {
1973
- this.auth = e, this.observer = null, this.addObserver = mn((t) => this.observer = t);
1974
+ this.auth = e, this.observer = null, this.addObserver = gn((t) => this.observer = t);
1974
1975
  }
1975
1976
  get next() {
1976
1977
  return u(
@@ -2005,16 +2006,16 @@ let Le = {
2005
2006
  recaptchaEnterpriseScript: "",
2006
2007
  gapiScript: ""
2007
2008
  };
2008
- function Qn(n) {
2009
+ function Zn(n) {
2009
2010
  Le = n;
2010
2011
  }
2011
- function Zn(n) {
2012
+ function ei(n) {
2012
2013
  return Le.loadJS(n);
2013
2014
  }
2014
- function ei() {
2015
+ function ti() {
2015
2016
  return Le.gapiScript;
2016
2017
  }
2017
- function ti(n) {
2018
+ function ni(n) {
2018
2019
  return `__${n}${Math.floor(Math.random() * 1e6)}`;
2019
2020
  }
2020
2021
  /**
@@ -2033,11 +2034,11 @@ function ti(n) {
2033
2034
  * See the License for the specific language governing permissions and
2034
2035
  * limitations under the License.
2035
2036
  */
2036
- function ni(n, e) {
2037
+ function ii(n, e) {
2037
2038
  const t = pt(n, "auth");
2038
2039
  if (t.isInitialized()) {
2039
2040
  const r = t.getImmediate(), s = t.getOptions();
2040
- if (vn(s, e ?? {}))
2041
+ if (In(s, e ?? {}))
2041
2042
  return r;
2042
2043
  S(
2043
2044
  r,
@@ -2047,11 +2048,11 @@ function ni(n, e) {
2047
2048
  }
2048
2049
  return t.initialize({ options: e });
2049
2050
  }
2050
- function ii(n, e) {
2051
+ function ri(n, e) {
2051
2052
  const t = (e == null ? void 0 : e.persistence) || [], i = (Array.isArray(t) ? t : [t]).map(k);
2052
2053
  e != null && e.errorMap && n._updateErrorMap(e.errorMap), n._initializeWithPersistence(i, e == null ? void 0 : e.popupRedirectResolver);
2053
2054
  }
2054
- function ri(n, e, t) {
2055
+ function si(n, e, t) {
2055
2056
  const i = pe(n);
2056
2057
  u(
2057
2058
  i._canInitEmulator,
@@ -2064,19 +2065,19 @@ function ri(n, e, t) {
2064
2065
  "invalid-emulator-scheme"
2065
2066
  /* AuthErrorCode.INVALID_EMULATOR_SCHEME */
2066
2067
  );
2067
- const r = !1, s = Mt(e), { host: o, port: c } = si(e), a = c === null ? "" : `:${c}`;
2068
+ const r = !1, s = Mt(e), { host: o, port: c } = oi(e), a = c === null ? "" : `:${c}`;
2068
2069
  i.config.emulator = { url: `${s}//${o}${a}/` }, i.settings.appVerificationDisabledForTesting = !0, i.emulatorConfig = Object.freeze({
2069
2070
  host: o,
2070
2071
  port: c,
2071
2072
  protocol: s.replace(":", ""),
2072
2073
  options: Object.freeze({ disableWarnings: r })
2073
- }), oi();
2074
+ }), ai();
2074
2075
  }
2075
2076
  function Mt(n) {
2076
2077
  const e = n.indexOf(":");
2077
2078
  return e < 0 ? "" : n.substr(0, e + 1);
2078
2079
  }
2079
- function si(n) {
2080
+ function oi(n) {
2080
2081
  const e = Mt(n), t = /(\/\/)?([^?#/]+)/.exec(n.substr(e.length));
2081
2082
  if (!t)
2082
2083
  return { host: "", port: null };
@@ -2095,7 +2096,7 @@ function Qe(n) {
2095
2096
  const e = Number(n);
2096
2097
  return isNaN(e) ? null : e;
2097
2098
  }
2098
- function oi() {
2099
+ function ai() {
2099
2100
  function n() {
2100
2101
  const e = document.createElement("p"), t = e.style;
2101
2102
  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);
@@ -2179,7 +2180,7 @@ async function W(n, e) {
2179
2180
  * See the License for the specific language governing permissions and
2180
2181
  * limitations under the License.
2181
2182
  */
2182
- const ai = "http://localhost";
2183
+ const ci = "http://localhost";
2183
2184
  class U extends Ut {
2184
2185
  constructor() {
2185
2186
  super(...arguments), this.pendingToken = null;
@@ -2237,7 +2238,7 @@ class U extends Ut {
2237
2238
  }
2238
2239
  buildRequest() {
2239
2240
  const e = {
2240
- requestUri: ai,
2241
+ requestUri: ci,
2241
2242
  returnSecureToken: !0
2242
2243
  };
2243
2244
  if (this.pendingToken)
@@ -2699,7 +2700,7 @@ function Ft(n, e, t, i) {
2699
2700
  throw s.code === "auth/multi-factor-auth-required" ? le._fromErrorAndOperation(n, s, e, i) : s;
2700
2701
  });
2701
2702
  }
2702
- async function ci(n, e, t = !1) {
2703
+ async function li(n, e, t = !1) {
2703
2704
  const i = await q(n, e._linkToIdToken(n.auth, await n.getIdToken()), t);
2704
2705
  return D._forOperation(n, "link", i);
2705
2706
  }
@@ -2719,7 +2720,7 @@ async function ci(n, e, t = !1) {
2719
2720
  * See the License for the specific language governing permissions and
2720
2721
  * limitations under the License.
2721
2722
  */
2722
- async function li(n, e, t = !1) {
2723
+ async function ui(n, e, t = !1) {
2723
2724
  const { auth: i } = n;
2724
2725
  if (w(i.app))
2725
2726
  return Promise.reject(L(i));
@@ -2770,7 +2771,7 @@ async function li(n, e, t = !1) {
2770
2771
  * See the License for the specific language governing permissions and
2771
2772
  * limitations under the License.
2772
2773
  */
2773
- async function ui(n, e, t = !1) {
2774
+ async function di(n, e, t = !1) {
2774
2775
  if (w(n.app))
2775
2776
  return Promise.reject(L(n));
2776
2777
  const i = "signIn", r = await Ft(n, i, e), s = await D._fromIdTokenResponse(n, i, r);
@@ -2792,7 +2793,7 @@ async function ui(n, e, t = !1) {
2792
2793
  * See the License for the specific language governing permissions and
2793
2794
  * limitations under the License.
2794
2795
  */
2795
- async function di(n, e) {
2796
+ async function hi(n, e) {
2796
2797
  return wt(n, "POST", "/v1/accounts:signInWithCustomToken", he(n, e));
2797
2798
  }
2798
2799
  /**
@@ -2811,19 +2812,19 @@ async function di(n, e) {
2811
2812
  * See the License for the specific language governing permissions and
2812
2813
  * limitations under the License.
2813
2814
  */
2814
- async function hi(n, e) {
2815
+ async function fi(n, e) {
2815
2816
  if (w(n.app))
2816
2817
  return Promise.reject(L(n));
2817
- const t = pe(n), i = await di(t, {
2818
+ const t = pe(n), i = await hi(t, {
2818
2819
  token: e,
2819
2820
  returnSecureToken: !0
2820
2821
  }), r = await D._fromIdTokenResponse(t, "signIn", i);
2821
2822
  return await t._updateCurrentUser(r.user), r;
2822
2823
  }
2823
- function fi(n, e, t, i) {
2824
+ function pi(n, e, t, i) {
2824
2825
  return j(n).onIdTokenChanged(e, t, i);
2825
2826
  }
2826
- function pi(n, e, t) {
2827
+ function mi(n, e, t) {
2827
2828
  return j(n).beforeAuthStateChanged(e, t);
2828
2829
  }
2829
2830
  const ue = "__sak";
@@ -2884,18 +2885,18 @@ class xt {
2884
2885
  * See the License for the specific language governing permissions and
2885
2886
  * limitations under the License.
2886
2887
  */
2887
- function mi() {
2888
+ function gi() {
2888
2889
  const n = g();
2889
2890
  return Ne(n) || fe(n);
2890
2891
  }
2891
- const gi = 1e3, _i = 10;
2892
+ const _i = 1e3, vi = 10;
2892
2893
  class Vt extends xt {
2893
2894
  constructor() {
2894
2895
  super(
2895
2896
  () => window.localStorage,
2896
2897
  "LOCAL"
2897
2898
  /* PersistenceType.LOCAL */
2898
- ), this.boundEventHandler = (e, t) => this.onStorageEvent(e, t), this.listeners = {}, this.localCache = {}, this.pollTimer = null, this.safariLocalStorageNotSynced = mi() && qn(), this.fallbackToPolling = Nt(), this._shouldAllowMigration = !0;
2899
+ ), this.boundEventHandler = (e, t) => this.onStorageEvent(e, t), this.listeners = {}, this.localCache = {}, this.pollTimer = null, this.safariLocalStorageNotSynced = gi() && zn(), this.fallbackToPolling = Nt(), this._shouldAllowMigration = !0;
2899
2900
  }
2900
2901
  forAllChangedKeys(e) {
2901
2902
  for (const t of Object.keys(this.listeners)) {
@@ -2922,7 +2923,7 @@ class Vt extends xt {
2922
2923
  const o = this.storage.getItem(i);
2923
2924
  !t && this.localCache[i] === o || this.notifyListeners(i, o);
2924
2925
  }, s = this.storage.getItem(i);
2925
- Bn() && s !== e.newValue && e.newValue !== e.oldValue ? setTimeout(r, _i) : r();
2926
+ qn() && s !== e.newValue && e.newValue !== e.oldValue ? setTimeout(r, vi) : r();
2926
2927
  }
2927
2928
  notifyListeners(e, t) {
2928
2929
  this.localCache[e] = t;
@@ -2944,7 +2945,7 @@ class Vt extends xt {
2944
2945
  !0
2945
2946
  );
2946
2947
  });
2947
- }, gi);
2948
+ }, _i);
2948
2949
  }
2949
2950
  stopPolling() {
2950
2951
  this.pollTimer && (clearInterval(this.pollTimer), this.pollTimer = null);
@@ -2974,7 +2975,7 @@ class Vt extends xt {
2974
2975
  }
2975
2976
  }
2976
2977
  Vt.type = "LOCAL";
2977
- const vi = Vt;
2978
+ const Ii = Vt;
2978
2979
  /**
2979
2980
  * @license
2980
2981
  * Copyright 2020 Google LLC
@@ -3022,7 +3023,7 @@ const $t = Ht;
3022
3023
  * See the License for the specific language governing permissions and
3023
3024
  * limitations under the License.
3024
3025
  */
3025
- function Ii(n) {
3026
+ function Ti(n) {
3026
3027
  return Promise.all(n.map(async (e) => {
3027
3028
  try {
3028
3029
  return {
@@ -3092,7 +3093,7 @@ class me {
3092
3093
  eventId: i,
3093
3094
  eventType: r
3094
3095
  });
3095
- const c = Array.from(o).map(async (l) => l(t.origin, s)), a = await Ii(c);
3096
+ const c = Array.from(o).map(async (l) => l(t.origin, s)), a = await Ti(c);
3096
3097
  t.ports[0].postMessage({
3097
3098
  status: "done",
3098
3099
  eventId: i,
@@ -3160,7 +3161,7 @@ function Me(n = "", e = 10) {
3160
3161
  * See the License for the specific language governing permissions and
3161
3162
  * limitations under the License.
3162
3163
  */
3163
- class Ti {
3164
+ class wi {
3164
3165
  constructor(e) {
3165
3166
  this.target = e, this.handlers = /* @__PURE__ */ new Set();
3166
3167
  }
@@ -3260,7 +3261,7 @@ class Ti {
3260
3261
  function T() {
3261
3262
  return window;
3262
3263
  }
3263
- function wi(n) {
3264
+ function yi(n) {
3264
3265
  T().location.href = n;
3265
3266
  }
3266
3267
  /**
@@ -3282,7 +3283,7 @@ function wi(n) {
3282
3283
  function Wt() {
3283
3284
  return typeof T().WorkerGlobalScope < "u" && typeof T().importScripts == "function";
3284
3285
  }
3285
- async function yi() {
3286
+ async function Ei() {
3286
3287
  if (!(navigator != null && navigator.serviceWorker))
3287
3288
  return null;
3288
3289
  try {
@@ -3291,11 +3292,11 @@ async function yi() {
3291
3292
  return null;
3292
3293
  }
3293
3294
  }
3294
- function Ei() {
3295
+ function ki() {
3295
3296
  var n;
3296
3297
  return ((n = navigator == null ? void 0 : navigator.serviceWorker) === null || n === void 0 ? void 0 : n.controller) || null;
3297
3298
  }
3298
- function ki() {
3299
+ function Si() {
3299
3300
  return Wt() ? self : null;
3300
3301
  }
3301
3302
  /**
@@ -3314,7 +3315,7 @@ function ki() {
3314
3315
  * See the License for the specific language governing permissions and
3315
3316
  * limitations under the License.
3316
3317
  */
3317
- const jt = "firebaseLocalStorageDb", Si = 1, de = "firebaseLocalStorage", Gt = "fbase_key";
3318
+ const jt = "firebaseLocalStorageDb", bi = 1, de = "firebaseLocalStorage", Gt = "fbase_key";
3318
3319
  class X {
3319
3320
  constructor(e) {
3320
3321
  this.request = e;
@@ -3332,12 +3333,12 @@ class X {
3332
3333
  function ge(n, e) {
3333
3334
  return n.transaction([de], e ? "readwrite" : "readonly").objectStore(de);
3334
3335
  }
3335
- function bi() {
3336
+ function Ri() {
3336
3337
  const n = indexedDB.deleteDatabase(jt);
3337
3338
  return new X(n).toPromise();
3338
3339
  }
3339
3340
  function Se() {
3340
- const n = indexedDB.open(jt, Si);
3341
+ const n = indexedDB.open(jt, bi);
3341
3342
  return new Promise((e, t) => {
3342
3343
  n.addEventListener("error", () => {
3343
3344
  t(n.error);
@@ -3350,7 +3351,7 @@ function Se() {
3350
3351
  }
3351
3352
  }), n.addEventListener("success", async () => {
3352
3353
  const i = n.result;
3353
- i.objectStoreNames.contains(de) ? e(i) : (i.close(), await bi(), e(await Se()));
3354
+ i.objectStoreNames.contains(de) ? e(i) : (i.close(), await Ri(), e(await Se()));
3354
3355
  });
3355
3356
  });
3356
3357
  }
@@ -3361,7 +3362,7 @@ async function et(n, e, t) {
3361
3362
  });
3362
3363
  return new X(i).toPromise();
3363
3364
  }
3364
- async function Ri(n, e) {
3365
+ async function Pi(n, e) {
3365
3366
  const t = ge(n, !1).get(e), i = await new X(t).toPromise();
3366
3367
  return i === void 0 ? null : i.value;
3367
3368
  }
@@ -3369,7 +3370,7 @@ function tt(n, e) {
3369
3370
  const t = ge(n, !0).delete(e);
3370
3371
  return new X(t).toPromise();
3371
3372
  }
3372
- const Pi = 800, Ai = 3;
3373
+ const Ai = 800, Ci = 3;
3373
3374
  class Bt {
3374
3375
  constructor() {
3375
3376
  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(() => {
@@ -3386,7 +3387,7 @@ class Bt {
3386
3387
  const i = await this._openDb();
3387
3388
  return await e(i);
3388
3389
  } catch (i) {
3389
- if (t++ > Ai)
3390
+ if (t++ > Ci)
3390
3391
  throw i;
3391
3392
  this.db && (this.db.close(), this.db = void 0);
3392
3393
  }
@@ -3402,7 +3403,7 @@ class Bt {
3402
3403
  * As the worker we should listen to events from the main window.
3403
3404
  */
3404
3405
  async initializeReceiver() {
3405
- this.receiver = me._getInstance(ki()), this.receiver._subscribe("keyChanged", async (e, t) => ({
3406
+ this.receiver = me._getInstance(Si()), this.receiver._subscribe("keyChanged", async (e, t) => ({
3406
3407
  keyProcessed: (await this._poll()).includes(t.key)
3407
3408
  })), this.receiver._subscribe("ping", async (e, t) => [
3408
3409
  "keyChanged"
@@ -3418,9 +3419,9 @@ class Bt {
3418
3419
  */
3419
3420
  async initializeSender() {
3420
3421
  var e, t;
3421
- if (this.activeServiceWorker = await yi(), !this.activeServiceWorker)
3422
+ if (this.activeServiceWorker = await Ei(), !this.activeServiceWorker)
3422
3423
  return;
3423
- this.sender = new Ti(this.activeServiceWorker);
3424
+ this.sender = new wi(this.activeServiceWorker);
3424
3425
  const i = await this.sender._send(
3425
3426
  "ping",
3426
3427
  {},
@@ -3442,7 +3443,7 @@ class Bt {
3442
3443
  * @param key - Storage key which changed.
3443
3444
  */
3444
3445
  async notifyServiceWorker(e) {
3445
- if (!(!this.sender || !this.activeServiceWorker || Ei() !== this.activeServiceWorker))
3446
+ if (!(!this.sender || !this.activeServiceWorker || ki() !== this.activeServiceWorker))
3446
3447
  try {
3447
3448
  await this.sender._send(
3448
3449
  "keyChanged",
@@ -3476,7 +3477,7 @@ class Bt {
3476
3477
  return this._withPendingWrite(async () => (await this._withRetries((i) => et(i, e, t)), this.localCache[e] = t, this.notifyServiceWorker(e)));
3477
3478
  }
3478
3479
  async _get(e) {
3479
- const t = await this._withRetries((i) => Ri(i, e));
3480
+ const t = await this._withRetries((i) => Pi(i, e));
3480
3481
  return this.localCache[e] = t, t;
3481
3482
  }
3482
3483
  async _remove(e) {
@@ -3507,7 +3508,7 @@ class Bt {
3507
3508
  r(t);
3508
3509
  }
3509
3510
  startPolling() {
3510
- this.stopPolling(), this.pollTimer = setInterval(async () => this._poll(), Pi);
3511
+ this.stopPolling(), this.pollTimer = setInterval(async () => this._poll(), Ai);
3511
3512
  }
3512
3513
  stopPolling() {
3513
3514
  this.pollTimer && (clearInterval(this.pollTimer), this.pollTimer = null);
@@ -3520,7 +3521,7 @@ class Bt {
3520
3521
  }
3521
3522
  }
3522
3523
  Bt.type = "LOCAL";
3523
- const Ci = Bt;
3524
+ const Oi = Bt;
3524
3525
  new J(3e4, 6e4);
3525
3526
  /**
3526
3527
  * @license
@@ -3538,7 +3539,7 @@ new J(3e4, 6e4);
3538
3539
  * See the License for the specific language governing permissions and
3539
3540
  * limitations under the License.
3540
3541
  */
3541
- function Oi(n, e) {
3542
+ function Ni(n, e) {
3542
3543
  return e ? k(e) : (u(
3543
3544
  n._popupRedirectResolver,
3544
3545
  n,
@@ -3592,26 +3593,26 @@ class Ue extends Ut {
3592
3593
  return e && (t.idToken = e), t;
3593
3594
  }
3594
3595
  }
3595
- function Ni(n) {
3596
- return ui(n.auth, new Ue(n), n.bypassAuthState);
3597
- }
3598
3596
  function Li(n) {
3597
+ return di(n.auth, new Ue(n), n.bypassAuthState);
3598
+ }
3599
+ function Mi(n) {
3599
3600
  const { auth: e, user: t } = n;
3600
3601
  return u(
3601
3602
  t,
3602
3603
  e,
3603
3604
  "internal-error"
3604
3605
  /* AuthErrorCode.INTERNAL_ERROR */
3605
- ), li(t, new Ue(n), n.bypassAuthState);
3606
+ ), ui(t, new Ue(n), n.bypassAuthState);
3606
3607
  }
3607
- async function Mi(n) {
3608
+ async function Ui(n) {
3608
3609
  const { auth: e, user: t } = n;
3609
3610
  return u(
3610
3611
  t,
3611
3612
  e,
3612
3613
  "internal-error"
3613
3614
  /* AuthErrorCode.INTERNAL_ERROR */
3614
- ), ci(t, new Ue(n), n.bypassAuthState);
3615
+ ), li(t, new Ue(n), n.bypassAuthState);
3615
3616
  }
3616
3617
  /**
3617
3618
  * @license
@@ -3671,13 +3672,13 @@ class qt {
3671
3672
  switch (e) {
3672
3673
  case "signInViaPopup":
3673
3674
  case "signInViaRedirect":
3674
- return Ni;
3675
+ return Li;
3675
3676
  case "linkViaPopup":
3676
3677
  case "linkViaRedirect":
3677
- return Mi;
3678
+ return Ui;
3678
3679
  case "reauthViaPopup":
3679
3680
  case "reauthViaRedirect":
3680
- return Li;
3681
+ return Mi;
3681
3682
  default:
3682
3683
  S(
3683
3684
  this.auth,
@@ -3712,7 +3713,7 @@ class qt {
3712
3713
  * See the License for the specific language governing permissions and
3713
3714
  * limitations under the License.
3714
3715
  */
3715
- const Ui = new J(2e3, 1e4);
3716
+ const Di = new J(2e3, 1e4);
3716
3717
  class V extends qt {
3717
3718
  constructor(e, t, i, r, s) {
3718
3719
  super(e, t, r, s), this.provider = i, this.authWindow = null, this.pollId = null, V.currentPopupAction && V.currentPopupAction.cancel(), V.currentPopupAction = this;
@@ -3776,7 +3777,7 @@ class V extends qt {
3776
3777
  );
3777
3778
  return;
3778
3779
  }
3779
- this.pollId = window.setTimeout(e, Ui.get());
3780
+ this.pollId = window.setTimeout(e, Di.get());
3780
3781
  };
3781
3782
  e();
3782
3783
  }
@@ -3798,8 +3799,8 @@ V.currentPopupAction = null;
3798
3799
  * See the License for the specific language governing permissions and
3799
3800
  * limitations under the License.
3800
3801
  */
3801
- const Di = "pendingRedirect", se = /* @__PURE__ */ new Map();
3802
- class Fi extends qt {
3802
+ const Fi = "pendingRedirect", se = /* @__PURE__ */ new Map();
3803
+ class xi extends qt {
3803
3804
  constructor(e, t, i = !1) {
3804
3805
  super(e, [
3805
3806
  "signInViaRedirect",
@@ -3817,7 +3818,7 @@ class Fi extends qt {
3817
3818
  let e = se.get(this.auth._key());
3818
3819
  if (!e) {
3819
3820
  try {
3820
- const i = await xi(this.resolver, this.auth) ? await super.execute() : null;
3821
+ const i = await Vi(this.resolver, this.auth) ? await super.execute() : null;
3821
3822
  e = () => Promise.resolve(i);
3822
3823
  } catch (t) {
3823
3824
  e = () => Promise.reject(t);
@@ -3845,26 +3846,26 @@ class Fi extends qt {
3845
3846
  cleanUp() {
3846
3847
  }
3847
3848
  }
3848
- async function xi(n, e) {
3849
- const t = $i(e), i = Hi(n);
3849
+ async function Vi(n, e) {
3850
+ const t = Wi(e), i = $i(n);
3850
3851
  if (!await i._isAvailable())
3851
3852
  return !1;
3852
3853
  const r = await i._get(t) === "true";
3853
3854
  return await i._remove(t), r;
3854
3855
  }
3855
- function Vi(n, e) {
3856
+ function Hi(n, e) {
3856
3857
  se.set(n._key(), e);
3857
3858
  }
3858
- function Hi(n) {
3859
+ function $i(n) {
3859
3860
  return k(n._redirectPersistence);
3860
3861
  }
3861
- function $i(n) {
3862
- return re(Di, n.config.apiKey, n.name);
3862
+ function Wi(n) {
3863
+ return re(Fi, n.config.apiKey, n.name);
3863
3864
  }
3864
- async function Wi(n, e, t = !1) {
3865
+ async function ji(n, e, t = !1) {
3865
3866
  if (w(n.app))
3866
3867
  return Promise.reject(L(n));
3867
- const i = pe(n), r = Oi(i, e), o = await new Fi(i, r, t).execute();
3868
+ const i = pe(n), r = Ni(i, e), o = await new xi(i, r, t).execute();
3868
3869
  return o && !t && (delete o.user._redirectEventId, await i._persistUserIfCurrent(o.user), await i._setRedirectUser(null, e)), o;
3869
3870
  }
3870
3871
  /**
@@ -3883,8 +3884,8 @@ async function Wi(n, e, t = !1) {
3883
3884
  * See the License for the specific language governing permissions and
3884
3885
  * limitations under the License.
3885
3886
  */
3886
- const ji = 10 * 60 * 1e3;
3887
- class Gi {
3887
+ const Gi = 10 * 60 * 1e3;
3888
+ class Bi {
3888
3889
  constructor(e) {
3889
3890
  this.auth = e, this.cachedEventUids = /* @__PURE__ */ new Set(), this.consumers = /* @__PURE__ */ new Set(), this.queuedRedirectEvent = null, this.hasHandledPotentialRedirect = !1, this.lastProcessedEventTime = Date.now();
3890
3891
  }
@@ -3900,7 +3901,7 @@ class Gi {
3900
3901
  let t = !1;
3901
3902
  return this.consumers.forEach((i) => {
3902
3903
  this.isEventForConsumer(e, i) && (t = !0, this.sendToConsumer(e, i), this.saveEventToCache(e));
3903
- }), this.hasHandledPotentialRedirect || !Bi(e) || (this.hasHandledPotentialRedirect = !0, t || (this.queuedRedirectEvent = e, t = !0)), t;
3904
+ }), this.hasHandledPotentialRedirect || !qi(e) || (this.hasHandledPotentialRedirect = !0, t || (this.queuedRedirectEvent = e, t = !0)), t;
3904
3905
  }
3905
3906
  sendToConsumer(e, t) {
3906
3907
  var i;
@@ -3915,7 +3916,7 @@ class Gi {
3915
3916
  return t.filter.includes(e.type) && i;
3916
3917
  }
3917
3918
  hasEventBeenHandled(e) {
3918
- return Date.now() - this.lastProcessedEventTime >= ji && this.cachedEventUids.clear(), this.cachedEventUids.has(nt(e));
3919
+ return Date.now() - this.lastProcessedEventTime >= Gi && this.cachedEventUids.clear(), this.cachedEventUids.has(nt(e));
3919
3920
  }
3920
3921
  saveEventToCache(e) {
3921
3922
  this.cachedEventUids.add(nt(e)), this.lastProcessedEventTime = Date.now();
@@ -3927,7 +3928,7 @@ function nt(n) {
3927
3928
  function zt({ type: n, error: e }) {
3928
3929
  return n === "unknown" && (e == null ? void 0 : e.code) === "auth/no-auth-event";
3929
3930
  }
3930
- function Bi(n) {
3931
+ function qi(n) {
3931
3932
  switch (n.type) {
3932
3933
  case "signInViaRedirect":
3933
3934
  case "linkViaRedirect":
@@ -3955,7 +3956,7 @@ function Bi(n) {
3955
3956
  * See the License for the specific language governing permissions and
3956
3957
  * limitations under the License.
3957
3958
  */
3958
- async function qi(n, e = {}) {
3959
+ async function zi(n, e = {}) {
3959
3960
  return G(n, "GET", "/v1/projects", e);
3960
3961
  }
3961
3962
  /**
@@ -3974,14 +3975,14 @@ async function qi(n, e = {}) {
3974
3975
  * See the License for the specific language governing permissions and
3975
3976
  * limitations under the License.
3976
3977
  */
3977
- const zi = /^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/, Ki = /^https?/;
3978
- async function Ji(n) {
3978
+ const Ki = /^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/, Ji = /^https?/;
3979
+ async function Yi(n) {
3979
3980
  if (n.config.emulator)
3980
3981
  return;
3981
- const { authorizedDomains: e } = await qi(n);
3982
+ const { authorizedDomains: e } = await zi(n);
3982
3983
  for (const t of e)
3983
3984
  try {
3984
- if (Yi(t))
3985
+ if (Xi(t))
3985
3986
  return;
3986
3987
  } catch {
3987
3988
  }
@@ -3991,15 +3992,15 @@ async function Ji(n) {
3991
3992
  /* AuthErrorCode.INVALID_ORIGIN */
3992
3993
  );
3993
3994
  }
3994
- function Yi(n) {
3995
+ function Xi(n) {
3995
3996
  const e = Ee(), { protocol: t, hostname: i } = new URL(e);
3996
3997
  if (n.startsWith("chrome-extension://")) {
3997
3998
  const o = new URL(n);
3998
3999
  return o.hostname === "" && i === "" ? t === "chrome-extension:" && n.replace("chrome-extension://", "") === e.replace("chrome-extension://", "") : t === "chrome-extension:" && o.hostname === i;
3999
4000
  }
4000
- if (!Ki.test(t))
4001
+ if (!Ji.test(t))
4001
4002
  return !1;
4002
- if (zi.test(n))
4003
+ if (Ki.test(n))
4003
4004
  return i === n;
4004
4005
  const r = n.replace(/\./g, "\\.");
4005
4006
  return new RegExp("^(.+\\." + r + "|" + r + ")$", "i").test(i);
@@ -4020,7 +4021,7 @@ function Yi(n) {
4020
4021
  * See the License for the specific language governing permissions and
4021
4022
  * limitations under the License.
4022
4023
  */
4023
- const Xi = new J(3e4, 6e4);
4024
+ const Qi = new J(3e4, 6e4);
4024
4025
  function it() {
4025
4026
  const n = T().___jsl;
4026
4027
  if (n != null && n.H) {
@@ -4030,7 +4031,7 @@ function it() {
4030
4031
  n.CP[t] = null;
4031
4032
  }
4032
4033
  }
4033
- function Qi(n) {
4034
+ function Zi(n) {
4034
4035
  return new Promise((e, t) => {
4035
4036
  var i, r, s;
4036
4037
  function o() {
@@ -4045,7 +4046,7 @@ function Qi(n) {
4045
4046
  /* AuthErrorCode.NETWORK_REQUEST_FAILED */
4046
4047
  ));
4047
4048
  },
4048
- timeout: Xi.get()
4049
+ timeout: Qi.get()
4049
4050
  });
4050
4051
  }
4051
4052
  if (!((r = (i = T().gapi) === null || i === void 0 ? void 0 : i.iframes) === null || r === void 0) && r.Iframe)
@@ -4053,22 +4054,22 @@ function Qi(n) {
4053
4054
  else if (!((s = T().gapi) === null || s === void 0) && s.load)
4054
4055
  o();
4055
4056
  else {
4056
- const c = ti("iframefcb");
4057
+ const c = ni("iframefcb");
4057
4058
  return T()[c] = () => {
4058
4059
  gapi.load ? o() : t(I(
4059
4060
  n,
4060
4061
  "network-request-failed"
4061
4062
  /* AuthErrorCode.NETWORK_REQUEST_FAILED */
4062
4063
  ));
4063
- }, Zn(`${ei()}?onload=${c}`).catch((a) => t(a));
4064
+ }, ei(`${ti()}?onload=${c}`).catch((a) => t(a));
4064
4065
  }
4065
4066
  }).catch((e) => {
4066
4067
  throw oe = null, e;
4067
4068
  });
4068
4069
  }
4069
4070
  let oe = null;
4070
- function Zi(n) {
4071
- return oe = oe || Qi(n), oe;
4071
+ function er(n) {
4072
+ return oe = oe || Zi(n), oe;
4072
4073
  }
4073
4074
  /**
4074
4075
  * @license
@@ -4086,7 +4087,7 @@ function Zi(n) {
4086
4087
  * See the License for the specific language governing permissions and
4087
4088
  * limitations under the License.
4088
4089
  */
4089
- const er = new J(5e3, 15e3), tr = "__/auth/iframe", nr = "emulator/auth/iframe", ir = {
4090
+ const tr = new J(5e3, 15e3), nr = "__/auth/iframe", ir = "emulator/auth/iframe", rr = {
4090
4091
  style: {
4091
4092
  position: "absolute",
4092
4093
  top: "-100px",
@@ -4095,13 +4096,13 @@ const er = new J(5e3, 15e3), tr = "__/auth/iframe", nr = "emulator/auth/iframe",
4095
4096
  },
4096
4097
  "aria-hidden": "true",
4097
4098
  tabindex: "-1"
4098
- }, rr = /* @__PURE__ */ new Map([
4099
+ }, sr = /* @__PURE__ */ new Map([
4099
4100
  ["identitytoolkit.googleapis.com", "p"],
4100
4101
  ["staging-identitytoolkit.sandbox.googleapis.com", "s"],
4101
4102
  ["test-identitytoolkit.sandbox.googleapis.com", "t"]
4102
4103
  // test
4103
4104
  ]);
4104
- function sr(n) {
4105
+ function or(n) {
4105
4106
  const e = n.config;
4106
4107
  u(
4107
4108
  e.authDomain,
@@ -4109,17 +4110,17 @@ function sr(n) {
4109
4110
  "auth-domain-config-required"
4110
4111
  /* AuthErrorCode.MISSING_AUTH_DOMAIN */
4111
4112
  );
4112
- const t = e.emulator ? Ce(e, nr) : `https://${n.config.authDomain}/${tr}`, i = {
4113
+ const t = e.emulator ? Ce(e, ir) : `https://${n.config.authDomain}/${nr}`, i = {
4113
4114
  apiKey: e.apiKey,
4114
4115
  appName: n.name,
4115
4116
  v: z
4116
- }, r = rr.get(n.config.apiHost);
4117
+ }, r = sr.get(n.config.apiHost);
4117
4118
  r && (i.eid = r);
4118
4119
  const s = n._getFrameworks();
4119
4120
  return s.length && (i.fw = s.join(",")), `${t}?${K(i).slice(1)}`;
4120
4121
  }
4121
- async function or(n) {
4122
- const e = await Zi(n), t = T().gapi;
4122
+ async function ar(n) {
4123
+ const e = await er(n), t = T().gapi;
4123
4124
  return u(
4124
4125
  t,
4125
4126
  n,
@@ -4127,9 +4128,9 @@ async function or(n) {
4127
4128
  /* AuthErrorCode.INTERNAL_ERROR */
4128
4129
  ), e.open({
4129
4130
  where: document.body,
4130
- url: sr(n),
4131
+ url: or(n),
4131
4132
  messageHandlersFilter: t.iframes.CROSS_ORIGIN_IFRAMES_FILTER,
4132
- attributes: ir,
4133
+ attributes: rr,
4133
4134
  dontclear: !0
4134
4135
  }, (i) => new Promise(async (r, s) => {
4135
4136
  await i.restyle({
@@ -4142,7 +4143,7 @@ async function or(n) {
4142
4143
  /* AuthErrorCode.NETWORK_REQUEST_FAILED */
4143
4144
  ), c = T().setTimeout(() => {
4144
4145
  s(o);
4145
- }, er.get());
4146
+ }, tr.get());
4146
4147
  function a() {
4147
4148
  T().clearTimeout(c), r(i);
4148
4149
  }
@@ -4167,12 +4168,12 @@ async function or(n) {
4167
4168
  * See the License for the specific language governing permissions and
4168
4169
  * limitations under the License.
4169
4170
  */
4170
- const ar = {
4171
+ const cr = {
4171
4172
  location: "yes",
4172
4173
  resizable: "yes",
4173
4174
  statusbar: "yes",
4174
4175
  toolbar: "no"
4175
- }, cr = 500, lr = 600, ur = "_blank", dr = "http://localhost";
4176
+ }, lr = 500, ur = 600, dr = "_blank", hr = "http://localhost";
4176
4177
  class rt {
4177
4178
  constructor(e) {
4178
4179
  this.window = e, this.associatedEvent = null;
@@ -4185,19 +4186,19 @@ class rt {
4185
4186
  }
4186
4187
  }
4187
4188
  }
4188
- function hr(n, e, t, i = cr, r = lr) {
4189
+ function fr(n, e, t, i = lr, r = ur) {
4189
4190
  const s = Math.max((window.screen.availHeight - r) / 2, 0).toString(), o = Math.max((window.screen.availWidth - i) / 2, 0).toString();
4190
4191
  let c = "";
4191
- const a = Object.assign(Object.assign({}, ar), {
4192
+ const a = Object.assign(Object.assign({}, cr), {
4192
4193
  width: i.toString(),
4193
4194
  height: r.toString(),
4194
4195
  top: s,
4195
4196
  left: o
4196
4197
  }), l = g().toLowerCase();
4197
- t && (c = Rt(l) ? ur : t), bt(l) && (e = e || dr, a.scrollbars = "yes");
4198
+ t && (c = Rt(l) ? dr : t), bt(l) && (e = e || hr, a.scrollbars = "yes");
4198
4199
  const d = Object.entries(a).reduce((_, [F, M]) => `${_}${F}=${M},`, "");
4199
- if (Gn(l) && c !== "_self")
4200
- return fr(e || "", c), new rt(null);
4200
+ if (Bn(l) && c !== "_self")
4201
+ return pr(e || "", c), new rt(null);
4201
4202
  const h = window.open(e || "", c, d);
4202
4203
  u(
4203
4204
  h,
@@ -4211,7 +4212,7 @@ function hr(n, e, t, i = cr, r = lr) {
4211
4212
  }
4212
4213
  return new rt(h);
4213
4214
  }
4214
- function fr(n, e) {
4215
+ function pr(n, e) {
4215
4216
  const t = document.createElement("a");
4216
4217
  t.href = n, t.target = e;
4217
4218
  const i = document.createEvent("MouseEvent");
@@ -4233,7 +4234,7 @@ function fr(n, e) {
4233
4234
  * See the License for the specific language governing permissions and
4234
4235
  * limitations under the License.
4235
4236
  */
4236
- const pr = "__/auth/handler", mr = "emulator/auth/handler", gr = encodeURIComponent("fac");
4237
+ const mr = "__/auth/handler", gr = "emulator/auth/handler", _r = encodeURIComponent("fac");
4237
4238
  async function st(n, e, t, i, r, s) {
4238
4239
  u(
4239
4240
  n.config.authDomain,
@@ -4255,7 +4256,7 @@ async function st(n, e, t, i, r, s) {
4255
4256
  eventId: r
4256
4257
  };
4257
4258
  if (e instanceof Dt) {
4258
- e.setDefaultLanguage(n.languageCode), o.providerId = e.providerId || "", wn(e.getCustomParameters()) || (o.customParameters = JSON.stringify(e.getCustomParameters()));
4259
+ e.setDefaultLanguage(n.languageCode), o.providerId = e.providerId || "", yn(e.getCustomParameters()) || (o.customParameters = JSON.stringify(e.getCustomParameters()));
4259
4260
  for (const [d, h] of Object.entries({}))
4260
4261
  o[d] = h;
4261
4262
  }
@@ -4267,11 +4268,11 @@ async function st(n, e, t, i, r, s) {
4267
4268
  const c = o;
4268
4269
  for (const d of Object.keys(c))
4269
4270
  c[d] === void 0 && delete c[d];
4270
- const a = await n._getAppCheckToken(), l = a ? `#${gr}=${encodeURIComponent(a)}` : "";
4271
- return `${_r(n)}?${K(c).slice(1)}${l}`;
4271
+ const a = await n._getAppCheckToken(), l = a ? `#${_r}=${encodeURIComponent(a)}` : "";
4272
+ return `${vr(n)}?${K(c).slice(1)}${l}`;
4272
4273
  }
4273
- function _r({ config: n }) {
4274
- return n.emulator ? Ce(n, mr) : `https://${n.authDomain}/${pr}`;
4274
+ function vr({ config: n }) {
4275
+ return n.emulator ? Ce(n, gr) : `https://${n.authDomain}/${mr}`;
4275
4276
  }
4276
4277
  /**
4277
4278
  * @license
@@ -4290,9 +4291,9 @@ function _r({ config: n }) {
4290
4291
  * limitations under the License.
4291
4292
  */
4292
4293
  const we = "webStorageSupport";
4293
- class vr {
4294
+ class Ir {
4294
4295
  constructor() {
4295
- this.eventManagers = {}, this.iframes = {}, this.originValidationPromises = {}, this._redirectPersistence = $t, this._completeRedirectFn = Wi, this._overrideRedirectResult = Vi;
4296
+ this.eventManagers = {}, this.iframes = {}, this.originValidationPromises = {}, this._redirectPersistence = $t, this._completeRedirectFn = ji, this._overrideRedirectResult = Hi;
4296
4297
  }
4297
4298
  // Wrapping in async even though we don't await anywhere in order
4298
4299
  // to make sure errors are raised as promise rejections
@@ -4300,12 +4301,12 @@ class vr {
4300
4301
  var s;
4301
4302
  b((s = this.eventManagers[e._key()]) === null || s === void 0 ? void 0 : s.manager, "_initialize() not called before _openPopup()");
4302
4303
  const o = await st(e, t, i, Ee(), r);
4303
- return hr(e, o, Me());
4304
+ return fr(e, o, Me());
4304
4305
  }
4305
4306
  async _openRedirect(e, t, i, r) {
4306
4307
  await this._originValidation(e);
4307
4308
  const s = await st(e, t, i, Ee(), r);
4308
- return wi(s), new Promise(() => {
4309
+ return yi(s), new Promise(() => {
4309
4310
  });
4310
4311
  }
4311
4312
  _initialize(e) {
@@ -4320,7 +4321,7 @@ class vr {
4320
4321
  }), i;
4321
4322
  }
4322
4323
  async initAndGetManager(e) {
4323
- const t = await or(e), i = new Gi(e);
4324
+ const t = await ar(e), i = new Bi(e);
4324
4325
  return t.register("authEvent", (r) => (u(
4325
4326
  r == null ? void 0 : r.authEvent,
4326
4327
  e,
@@ -4344,13 +4345,13 @@ class vr {
4344
4345
  }
4345
4346
  _originValidation(e) {
4346
4347
  const t = e._key();
4347
- return this.originValidationPromises[t] || (this.originValidationPromises[t] = Ji(e)), this.originValidationPromises[t];
4348
+ return this.originValidationPromises[t] || (this.originValidationPromises[t] = Yi(e)), this.originValidationPromises[t];
4348
4349
  }
4349
4350
  get _shouldInitProactively() {
4350
4351
  return Nt() || Ne() || fe();
4351
4352
  }
4352
4353
  }
4353
- const Ir = vr;
4354
+ const Tr = Ir;
4354
4355
  var ot = "@firebase/auth", at = "1.7.5";
4355
4356
  /**
4356
4357
  * @license
@@ -4368,7 +4369,7 @@ var ot = "@firebase/auth", at = "1.7.5";
4368
4369
  * See the License for the specific language governing permissions and
4369
4370
  * limitations under the License.
4370
4371
  */
4371
- class Tr {
4372
+ class wr {
4372
4373
  constructor(e) {
4373
4374
  this.auth = e, this.internalListeners = /* @__PURE__ */ new Map();
4374
4375
  }
@@ -4419,7 +4420,7 @@ class Tr {
4419
4420
  * See the License for the specific language governing permissions and
4420
4421
  * limitations under the License.
4421
4422
  */
4422
- function wr(n) {
4423
+ function yr(n) {
4423
4424
  switch (n) {
4424
4425
  case "Node":
4425
4426
  return "node";
@@ -4435,7 +4436,7 @@ function wr(n) {
4435
4436
  return;
4436
4437
  }
4437
4438
  }
4438
- function yr(n) {
4439
+ function Er(n) {
4439
4440
  je(new Ge(
4440
4441
  "auth",
4441
4442
  (e, { options: t }) => {
@@ -4449,8 +4450,8 @@ function yr(n) {
4449
4450
  tokenApiHost: "securetoken.googleapis.com",
4450
4451
  apiScheme: "https",
4451
4452
  sdkClientVersion: Lt(n)
4452
- }, l = new Xn(i, r, s, a);
4453
- return ii(l, t), l;
4453
+ }, l = new Qn(i, r, s, a);
4454
+ return ri(l, t), l;
4454
4455
  },
4455
4456
  "PUBLIC"
4456
4457
  /* ComponentType.PUBLIC */
@@ -4469,14 +4470,14 @@ function yr(n) {
4469
4470
  "auth"
4470
4471
  /* _ComponentName.AUTH */
4471
4472
  ).getImmediate());
4472
- return ((i) => new Tr(i))(t);
4473
+ return ((i) => new wr(i))(t);
4473
4474
  },
4474
4475
  "PRIVATE"
4475
4476
  /* ComponentType.PRIVATE */
4476
4477
  ).setInstantiationMode(
4477
4478
  "EXPLICIT"
4478
4479
  /* InstantiationMode.EXPLICIT */
4479
- )), ye(ot, at, wr(n)), ye(ot, at, "esm2017");
4480
+ )), ye(ot, at, yr(n)), ye(ot, at, "esm2017");
4480
4481
  }
4481
4482
  /**
4482
4483
  * @license
@@ -4494,11 +4495,11 @@ function yr(n) {
4494
4495
  * See the License for the specific language governing permissions and
4495
4496
  * limitations under the License.
4496
4497
  */
4497
- const Er = 5 * 60, kr = ft("authIdTokenMaxAge") || Er;
4498
+ const kr = 5 * 60, Sr = ft("authIdTokenMaxAge") || kr;
4498
4499
  let ct = null;
4499
- const Sr = (n) => async (e) => {
4500
+ const br = (n) => async (e) => {
4500
4501
  const t = e && await e.getIdTokenResult(), i = t && ((/* @__PURE__ */ new Date()).getTime() - Date.parse(t.issuedAtTime)) / 1e3;
4501
- if (i && i > kr)
4502
+ if (i && i > Sr)
4502
4503
  return;
4503
4504
  const r = t == null ? void 0 : t.token;
4504
4505
  ct !== r && (ct = r, await fetch(n, {
@@ -4508,33 +4509,33 @@ const Sr = (n) => async (e) => {
4508
4509
  } : {}
4509
4510
  }));
4510
4511
  };
4511
- function br(n = _n()) {
4512
+ function Rr(n = vn()) {
4512
4513
  const e = pt(n, "auth");
4513
4514
  if (e.isInitialized())
4514
4515
  return e.getImmediate();
4515
- const t = ni(n, {
4516
- popupRedirectResolver: Ir,
4516
+ const t = ii(n, {
4517
+ popupRedirectResolver: Tr,
4517
4518
  persistence: [
4518
- Ci,
4519
- vi,
4519
+ Oi,
4520
+ Ii,
4520
4521
  $t
4521
4522
  ]
4522
4523
  }), i = ft("authTokenSyncURL");
4523
4524
  if (i && typeof isSecureContext == "boolean" && isSecureContext) {
4524
4525
  const s = new URL(i, location.origin);
4525
4526
  if (location.origin === s.origin) {
4526
- const o = Sr(s.toString());
4527
- pi(t, o, () => o(t.currentUser)), fi(t, (c) => o(c));
4527
+ const o = br(s.toString());
4528
+ mi(t, o, () => o(t.currentUser)), pi(t, (c) => o(c));
4528
4529
  }
4529
4530
  }
4530
- const r = gn("auth");
4531
- return r && ri(t, `http://${r}`), t;
4531
+ const r = _n("auth");
4532
+ return r && si(t, `http://${r}`), t;
4532
4533
  }
4533
- function Rr() {
4534
+ function Pr() {
4534
4535
  var n, e;
4535
4536
  return (e = (n = document.getElementsByTagName("head")) === null || n === void 0 ? void 0 : n[0]) !== null && e !== void 0 ? e : document;
4536
4537
  }
4537
- Qn({
4538
+ Zn({
4538
4539
  loadJS(n) {
4539
4540
  return new Promise((e, t) => {
4540
4541
  const i = document.createElement("script");
@@ -4544,38 +4545,38 @@ Qn({
4544
4545
  /* AuthErrorCode.INTERNAL_ERROR */
4545
4546
  );
4546
4547
  s.customData = r, t(s);
4547
- }, i.type = "text/javascript", i.charset = "UTF-8", Rr().appendChild(i);
4548
+ }, i.type = "text/javascript", i.charset = "UTF-8", Pr().appendChild(i);
4548
4549
  });
4549
4550
  },
4550
4551
  gapiScript: "https://apis.google.com/js/api.js",
4551
4552
  recaptchaV2Script: "https://www.google.com/recaptcha/api.js",
4552
4553
  recaptchaEnterpriseScript: "https://www.google.com/recaptcha/enterprise.js?render="
4553
4554
  });
4554
- yr(
4555
+ Er(
4555
4556
  "Browser"
4556
4557
  /* ClientPlatform.BROWSER */
4557
4558
  );
4558
- var Pr = { 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", clientId: "d5f8840d63dbb758b6c4ee2a5e8b013d15dd25e242c457481326062b83962476" }, Ar = { 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", marketingV1Portal: "https://marketing-v1.feedme.cc" };
4559
- const Cr = {
4559
+ var Ar = { 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", clientId: "1a362d621873497b277ea55258cc82594ba148d235257f7bd44ea2acc132d8a4" }, Cr = { authUrl: "https://portal-v2-dev.feedmeapi.com/", slackWebhookUrl: "https://hooks.slack.com/services/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", appUrl: "member.feedmedev.cc", crmUrl: "crm.feedmedev.cc", paymentPortalUrl: "https://portal.feedmedev.cc/payment/payout-account", marketingV1Portal: "https://marketing-v1.feedmedev.cc" };
4560
+ const Or = {
4560
4561
  key: 1,
4561
4562
  class: "h-full w-full"
4562
- }, Or = ["src"], Gr = /* @__PURE__ */ lt({
4563
+ }, Nr = ["src"], qr = /* @__PURE__ */ lt({
4563
4564
  __name: "App",
4564
4565
  setup(n) {
4565
4566
  const e = We(), t = on(), i = an(), r = cn(), s = ln(), o = ht(), c = te(o.query.showHeader !== "false"), a = te(!1), { currentBusiness: l } = We(), d = te(!1), h = Ve(() => i.version), _ = Ve(() => {
4566
4567
  const p = e.currentCountry.value || "MY", m = Be.getIdToken(), v = l.value._id;
4567
- return `${Ar.marketingV1Portal}/b/${v}/marketing/overview?showHeader=false&country=${p}&token=${m}`;
4568
+ return `${Cr.marketingV1Portal}/b/${v}/marketing/overview?showHeader=false&country=${p}&token=${m}`;
4568
4569
  });
4569
4570
  async function F() {
4570
- if (yn().length) {
4571
+ if (En().length) {
4571
4572
  console.warn("CONNECT: initFirebase: Firebase already initialized");
4572
4573
  return;
4573
4574
  }
4574
- const p = En(Pr.firebase), m = await sn.getCustomToken(), v = br();
4575
- await hi(v, m), kn(p), console.log("initFirebase", p);
4575
+ const p = kn(Ar.firebase), m = await sn.getCustomToken(), v = Rr();
4576
+ await fi(v, m), Sn(p), console.log("initFirebase", p);
4576
4577
  }
4577
4578
  const M = async () => {
4578
- d.value = !1, await tn(), console.log("forceRerender"), Be.setBusinessId(l.value._id), await i.readPremium(), !a.value && h.value === "v2" ? e.registerSidebarComponent(Sn) : e.hideSidebarToggle(!0), await F(), a.value = !0, d.value = !0;
4579
+ d.value = !1, await tn(), console.log("forceRerender"), Be.setBusinessId(l.value._id), await i.readPremium(), !a.value && h.value === "v2" ? e.registerSidebarComponent(bn) : e.hideSidebarToggle(!0), await F(), a.value = !0, d.value = !0;
4579
4580
  };
4580
4581
  return Xt(() => {
4581
4582
  if (t.initProvider(r, s), !c.value) {
@@ -4590,8 +4591,8 @@ const Cr = {
4590
4591
  }
4591
4592
  ), (p, m) => (ne(), He(Qt, null, [
4592
4593
  P(d) && P(h) === "v2" ? (ne(), dt(P(rn), { key: 0 })) : $e("", !0),
4593
- P(d) && P(h) !== "v2" ? (ne(), He("div", Cr, [
4594
- Zt(un, {
4594
+ P(d) && P(h) !== "v2" ? (ne(), He("div", Or, [
4595
+ Zt(dn, {
4595
4596
  json: { url: P(_) }
4596
4597
  }, null, 8, ["json"]),
4597
4598
  en("iframe", {
@@ -4600,11 +4601,11 @@ const Cr = {
4600
4601
  height: "100%",
4601
4602
  width: "100%",
4602
4603
  src: P(_)
4603
- }, null, 8, Or)
4604
+ }, null, 8, Nr)
4604
4605
  ])) : $e("", !0)
4605
4606
  ], 64));
4606
4607
  }
4607
4608
  });
4608
4609
  export {
4609
- Gr as default
4610
+ qr as default
4610
4611
  };