@ukpc-lib/react 0.3.19 → 0.3.21
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.
- package/dist/components/index.cjs +2 -2
- package/dist/components/index.js +70 -70
- package/dist/{index.module-c91c4596.js → index.module-9cc5e50f.js} +5749 -5752
- package/dist/{index.module-af5a0d6e.cjs → index.module-cf6b1a78.cjs} +81 -81
- package/dist/share/index.cjs +1 -1
- package/dist/share/index.js +1 -1
- package/package.json +1 -1
- package/web-components-bundle/access-denied/index.js +2 -2
- package/web-components-bundle/global-menu/index.js +2 -2
- package/web-components-bundle/global-topbar/index.cjs +1 -1
- package/web-components-bundle/global-topbar/index.js +4 -4
- package/web-components-bundle/has-permission/index.cjs +1 -1
- package/web-components-bundle/has-permission/index.js +4 -4
- package/web-components-bundle/{index-c8d9f7f1.cjs → index-346b9a8b.cjs} +58 -58
- package/web-components-bundle/{index-034800b1.js → index-8c13462b.js} +370 -371
- package/web-components-bundle/{index-1bcd1263.js → index-9cc15059.js} +1 -1
- package/web-components-bundle/{index-97e78f5f.js → index-a73a841e.js} +1 -1
- package/web-components-bundle/{react-to-web-component-642fb54e.js → react-to-web-component-469d91d4.js} +2 -2
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { j as z, r as ee, R as Jp, g as _r, a as Js, c as ha, b as Ox,
|
|
2
|
-
import { c as ns, _ as Le, a as nr, b as Rx, o as Px, d as Nx, e as ho, p as po, n as Lx, l as Qp, E as $x, S as Fx, L as Yx } from "./index-
|
|
3
|
-
import { _ as Bx, t as eg, L as tg } from "./index-
|
|
1
|
+
import { j as z, r as ee, R as Jp, g as _r, a as Js, c as ha, b as Ox, d as Ix, s as nm } from "./react-to-web-component-469d91d4.js";
|
|
2
|
+
import { c as ns, _ as Le, a as nr, b as Rx, o as Px, d as Nx, e as ho, p as po, n as Lx, l as Qp, E as $x, S as Fx, L as Yx } from "./index-a73a841e.js";
|
|
3
|
+
import { _ as Bx, t as eg, L as tg } from "./index-9cc15059.js";
|
|
4
4
|
function rm(e) {
|
|
5
5
|
var t, r, a = "";
|
|
6
6
|
if (typeof e == "string" || typeof e == "number")
|
|
@@ -10665,6 +10665,62 @@ var jA = function(e, t) {
|
|
|
10665
10665
|
}
|
|
10666
10666
|
}]), t;
|
|
10667
10667
|
})(ee.PureComponent);
|
|
10668
|
+
function Fg(e) {
|
|
10669
|
+
Promise.resolve().then(e).catch(function(t) {
|
|
10670
|
+
return setTimeout(function() {
|
|
10671
|
+
throw t;
|
|
10672
|
+
});
|
|
10673
|
+
});
|
|
10674
|
+
}
|
|
10675
|
+
var qA = /* @__PURE__ */ function() {
|
|
10676
|
+
function e() {
|
|
10677
|
+
this.queue = [], this.transactions = 0, this.notifyFn = function(r) {
|
|
10678
|
+
r();
|
|
10679
|
+
}, this.batchNotifyFn = function(r) {
|
|
10680
|
+
r();
|
|
10681
|
+
};
|
|
10682
|
+
}
|
|
10683
|
+
var t = e.prototype;
|
|
10684
|
+
return t.batch = function(a) {
|
|
10685
|
+
var o;
|
|
10686
|
+
this.transactions++;
|
|
10687
|
+
try {
|
|
10688
|
+
o = a();
|
|
10689
|
+
} finally {
|
|
10690
|
+
this.transactions--, this.transactions || this.flush();
|
|
10691
|
+
}
|
|
10692
|
+
return o;
|
|
10693
|
+
}, t.schedule = function(a) {
|
|
10694
|
+
var o = this;
|
|
10695
|
+
this.transactions ? this.queue.push(a) : Fg(function() {
|
|
10696
|
+
o.notifyFn(a);
|
|
10697
|
+
});
|
|
10698
|
+
}, t.batchCalls = function(a) {
|
|
10699
|
+
var o = this;
|
|
10700
|
+
return function() {
|
|
10701
|
+
for (var c = arguments.length, h = new Array(c), b = 0; b < c; b++)
|
|
10702
|
+
h[b] = arguments[b];
|
|
10703
|
+
o.schedule(function() {
|
|
10704
|
+
a.apply(void 0, h);
|
|
10705
|
+
});
|
|
10706
|
+
};
|
|
10707
|
+
}, t.flush = function() {
|
|
10708
|
+
var a = this, o = this.queue;
|
|
10709
|
+
this.queue = [], o.length && Fg(function() {
|
|
10710
|
+
a.batchNotifyFn(function() {
|
|
10711
|
+
o.forEach(function(c) {
|
|
10712
|
+
a.notifyFn(c);
|
|
10713
|
+
});
|
|
10714
|
+
});
|
|
10715
|
+
});
|
|
10716
|
+
}, t.setNotifyFunction = function(a) {
|
|
10717
|
+
this.notifyFn = a;
|
|
10718
|
+
}, t.setBatchNotifyFunction = function(a) {
|
|
10719
|
+
this.batchNotifyFn = a;
|
|
10720
|
+
}, e;
|
|
10721
|
+
}(), zA = new qA(), VA = Ox.unstable_batchedUpdates;
|
|
10722
|
+
zA.setBatchNotifyFunction(VA);
|
|
10723
|
+
ee.createContext({});
|
|
10668
10724
|
var W0 = { exports: {} };
|
|
10669
10725
|
/*!
|
|
10670
10726
|
* jQuery JavaScript Library v3.7.1
|
|
@@ -14285,9 +14341,9 @@ var W0 = { exports: {} };
|
|
|
14285
14341
|
});
|
|
14286
14342
|
})(W0);
|
|
14287
14343
|
var j0 = W0.exports;
|
|
14288
|
-
const
|
|
14289
|
-
var
|
|
14290
|
-
const
|
|
14344
|
+
const GA = /* @__PURE__ */ Ix(j0);
|
|
14345
|
+
var KA = { exports: {} };
|
|
14346
|
+
const ZA = /* @__PURE__ */ _r(HD);
|
|
14291
14347
|
/**
|
|
14292
14348
|
* @version: 3.1
|
|
14293
14349
|
* @author: Dan Grossman http://www.dangrossman.info/
|
|
@@ -14300,7 +14356,7 @@ const VA = /* @__PURE__ */ _r(HD);
|
|
|
14300
14356
|
if (e.exports) {
|
|
14301
14357
|
var a = typeof window < "u" ? window.jQuery : void 0;
|
|
14302
14358
|
a || (a = j0, a.fn || (a.fn = {}));
|
|
14303
|
-
var o = typeof window < "u" && typeof window.moment < "u" ? window.moment :
|
|
14359
|
+
var o = typeof window < "u" && typeof window.moment < "u" ? window.moment : ZA;
|
|
14304
14360
|
e.exports = r(o, a);
|
|
14305
14361
|
} else
|
|
14306
14362
|
t.daterangepicker = r(t.moment, t.jQuery);
|
|
@@ -14705,7 +14761,7 @@ const VA = /* @__PURE__ */ _r(HD);
|
|
|
14705
14761
|
}), this;
|
|
14706
14762
|
}, a;
|
|
14707
14763
|
});
|
|
14708
|
-
})(
|
|
14764
|
+
})(KA);
|
|
14709
14765
|
var Zf = function(e, t) {
|
|
14710
14766
|
return Zf = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(r, a) {
|
|
14711
14767
|
r.__proto__ = a;
|
|
@@ -14714,7 +14770,7 @@ var Zf = function(e, t) {
|
|
|
14714
14770
|
Object.prototype.hasOwnProperty.call(a, o) && (r[o] = a[o]);
|
|
14715
14771
|
}, Zf(e, t);
|
|
14716
14772
|
};
|
|
14717
|
-
function
|
|
14773
|
+
function XA(e, t) {
|
|
14718
14774
|
if (typeof t != "function" && t !== null)
|
|
14719
14775
|
throw new TypeError("Class extends value " + String(t) + " is not a constructor or null");
|
|
14720
14776
|
Zf(e, t);
|
|
@@ -14724,14 +14780,14 @@ function GA(e, t) {
|
|
|
14724
14780
|
e.prototype = t === null ? Object.create(t) : (r.prototype = t.prototype, new r());
|
|
14725
14781
|
}
|
|
14726
14782
|
(function(e) {
|
|
14727
|
-
|
|
14783
|
+
XA(t, e);
|
|
14728
14784
|
function t(r) {
|
|
14729
14785
|
var a = e.call(this, r) || this;
|
|
14730
14786
|
return a.ref = null, a.$picker = null, a;
|
|
14731
14787
|
}
|
|
14732
14788
|
return t.prototype.componentDidMount = function() {
|
|
14733
14789
|
var r = this;
|
|
14734
|
-
this.$picker =
|
|
14790
|
+
this.$picker = GA(this.ref), this.$picker.daterangepicker(this.props.initialSettings, this.handleCallback.bind(this)), ["Show", "Hide", "ShowCalendar", "HideCalendar", "Apply", "Cancel"].forEach(function(a) {
|
|
14735
14791
|
var o, c = a.charAt(0).toLowerCase() + a.slice(1);
|
|
14736
14792
|
(o = r.$picker) === null || o === void 0 || o.on(c + ".daterangepicker", r.makeEventHandler("on" + a));
|
|
14737
14793
|
});
|
|
@@ -14848,7 +14904,7 @@ const H0 = function(e) {
|
|
|
14848
14904
|
o < 128 ? t[r++] = o : o < 2048 ? (t[r++] = o >> 6 | 192, t[r++] = o & 63 | 128) : (o & 64512) === 55296 && a + 1 < e.length && (e.charCodeAt(a + 1) & 64512) === 56320 ? (o = 65536 + ((o & 1023) << 10) + (e.charCodeAt(++a) & 1023), t[r++] = o >> 18 | 240, t[r++] = o >> 12 & 63 | 128, t[r++] = o >> 6 & 63 | 128, t[r++] = o & 63 | 128) : (t[r++] = o >> 12 | 224, t[r++] = o >> 6 & 63 | 128, t[r++] = o & 63 | 128);
|
|
14849
14905
|
}
|
|
14850
14906
|
return t;
|
|
14851
|
-
},
|
|
14907
|
+
}, JA = function(e) {
|
|
14852
14908
|
const t = [];
|
|
14853
14909
|
let r = 0, a = 0;
|
|
14854
14910
|
for (; r < e.length; ) {
|
|
@@ -14952,7 +15008,7 @@ const H0 = function(e) {
|
|
|
14952
15008
|
* @return string representing the decoded value.
|
|
14953
15009
|
*/
|
|
14954
15010
|
decodeString(e, t) {
|
|
14955
|
-
return this.HAS_NATIVE_SUPPORT && !t ? atob(e) :
|
|
15011
|
+
return this.HAS_NATIVE_SUPPORT && !t ? atob(e) : JA(this.decodeStringToByteArray(e, t));
|
|
14956
15012
|
},
|
|
14957
15013
|
/**
|
|
14958
15014
|
* Base64-decode a string.
|
|
@@ -14979,7 +15035,7 @@ const H0 = function(e) {
|
|
|
14979
15035
|
++o;
|
|
14980
15036
|
const F = o < e.length ? r[e.charAt(o)] : 64;
|
|
14981
15037
|
if (++o, c == null || b == null || D == null || F == null)
|
|
14982
|
-
throw new
|
|
15038
|
+
throw new QA();
|
|
14983
15039
|
const j = c << 2 | b >> 4;
|
|
14984
15040
|
if (a.push(j), D !== 64) {
|
|
14985
15041
|
const K = b << 4 & 240 | D >> 2;
|
|
@@ -15004,17 +15060,17 @@ const H0 = function(e) {
|
|
|
15004
15060
|
}
|
|
15005
15061
|
}
|
|
15006
15062
|
};
|
|
15007
|
-
class
|
|
15063
|
+
class QA extends Error {
|
|
15008
15064
|
constructor() {
|
|
15009
15065
|
super(...arguments), this.name = "DecodeBase64StringError";
|
|
15010
15066
|
}
|
|
15011
15067
|
}
|
|
15012
|
-
const
|
|
15068
|
+
const eO = function(e) {
|
|
15013
15069
|
const t = H0(e);
|
|
15014
15070
|
return U0.encodeByteArray(t, !0);
|
|
15015
15071
|
}, q0 = function(e) {
|
|
15016
|
-
return
|
|
15017
|
-
},
|
|
15072
|
+
return eO(e).replace(/\./g, "");
|
|
15073
|
+
}, tO = function(e) {
|
|
15018
15074
|
try {
|
|
15019
15075
|
return U0.decodeString(e, !0);
|
|
15020
15076
|
} catch (t) {
|
|
@@ -15038,7 +15094,7 @@ const XA = function(e) {
|
|
|
15038
15094
|
* See the License for the specific language governing permissions and
|
|
15039
15095
|
* limitations under the License.
|
|
15040
15096
|
*/
|
|
15041
|
-
function
|
|
15097
|
+
function nO() {
|
|
15042
15098
|
if (typeof self < "u")
|
|
15043
15099
|
return self;
|
|
15044
15100
|
if (typeof window < "u")
|
|
@@ -15063,13 +15119,13 @@ function QA() {
|
|
|
15063
15119
|
* See the License for the specific language governing permissions and
|
|
15064
15120
|
* limitations under the License.
|
|
15065
15121
|
*/
|
|
15066
|
-
const
|
|
15122
|
+
const rO = () => nO().__FIREBASE_DEFAULTS__, iO = () => {
|
|
15067
15123
|
if (typeof process > "u" || typeof process.env > "u")
|
|
15068
15124
|
return;
|
|
15069
15125
|
const e = process.env.__FIREBASE_DEFAULTS__;
|
|
15070
15126
|
if (e)
|
|
15071
15127
|
return JSON.parse(e);
|
|
15072
|
-
},
|
|
15128
|
+
}, aO = () => {
|
|
15073
15129
|
if (typeof document > "u")
|
|
15074
15130
|
return;
|
|
15075
15131
|
let e;
|
|
@@ -15078,18 +15134,18 @@ const eO = () => QA().__FIREBASE_DEFAULTS__, tO = () => {
|
|
|
15078
15134
|
} catch {
|
|
15079
15135
|
return;
|
|
15080
15136
|
}
|
|
15081
|
-
const t = e &&
|
|
15137
|
+
const t = e && tO(e[1]);
|
|
15082
15138
|
return t && JSON.parse(t);
|
|
15083
|
-
},
|
|
15139
|
+
}, sO = () => {
|
|
15084
15140
|
try {
|
|
15085
|
-
return
|
|
15141
|
+
return rO() || iO() || aO();
|
|
15086
15142
|
} catch (e) {
|
|
15087
15143
|
console.info(`Unable to get __FIREBASE_DEFAULTS__ due to: ${e}`);
|
|
15088
15144
|
return;
|
|
15089
15145
|
}
|
|
15090
15146
|
}, z0 = () => {
|
|
15091
15147
|
var e;
|
|
15092
|
-
return (e =
|
|
15148
|
+
return (e = sO()) === null || e === void 0 ? void 0 : e.config;
|
|
15093
15149
|
};
|
|
15094
15150
|
/**
|
|
15095
15151
|
* @license
|
|
@@ -15107,7 +15163,7 @@ const eO = () => QA().__FIREBASE_DEFAULTS__, tO = () => {
|
|
|
15107
15163
|
* See the License for the specific language governing permissions and
|
|
15108
15164
|
* limitations under the License.
|
|
15109
15165
|
*/
|
|
15110
|
-
class
|
|
15166
|
+
class oO {
|
|
15111
15167
|
constructor() {
|
|
15112
15168
|
this.reject = () => {
|
|
15113
15169
|
}, this.resolve = () => {
|
|
@@ -15152,7 +15208,7 @@ function G0() {
|
|
|
15152
15208
|
}
|
|
15153
15209
|
});
|
|
15154
15210
|
}
|
|
15155
|
-
function
|
|
15211
|
+
function uO() {
|
|
15156
15212
|
return !(typeof navigator > "u" || !navigator.cookieEnabled);
|
|
15157
15213
|
}
|
|
15158
15214
|
/**
|
|
@@ -15171,10 +15227,10 @@ function aO() {
|
|
|
15171
15227
|
* See the License for the specific language governing permissions and
|
|
15172
15228
|
* limitations under the License.
|
|
15173
15229
|
*/
|
|
15174
|
-
const
|
|
15230
|
+
const lO = "FirebaseError";
|
|
15175
15231
|
class cs extends Error {
|
|
15176
15232
|
constructor(t, r, a) {
|
|
15177
|
-
super(r), this.code = t, this.customData = a, this.name =
|
|
15233
|
+
super(r), this.code = t, this.customData = a, this.name = lO, Object.setPrototypeOf(this, cs.prototype), Error.captureStackTrace && Error.captureStackTrace(this, Jl.prototype.create);
|
|
15178
15234
|
}
|
|
15179
15235
|
}
|
|
15180
15236
|
class Jl {
|
|
@@ -15182,17 +15238,17 @@ class Jl {
|
|
|
15182
15238
|
this.service = t, this.serviceName = r, this.errors = a;
|
|
15183
15239
|
}
|
|
15184
15240
|
create(t, ...r) {
|
|
15185
|
-
const a = r[0] || {}, o = `${this.service}/${t}`, c = this.errors[t], h = c ?
|
|
15241
|
+
const a = r[0] || {}, o = `${this.service}/${t}`, c = this.errors[t], h = c ? cO(c, a) : "Error", b = `${this.serviceName}: ${h} (${o}).`;
|
|
15186
15242
|
return new cs(o, b, a);
|
|
15187
15243
|
}
|
|
15188
15244
|
}
|
|
15189
|
-
function
|
|
15190
|
-
return e.replace(
|
|
15245
|
+
function cO(e, t) {
|
|
15246
|
+
return e.replace(fO, (r, a) => {
|
|
15191
15247
|
const o = t[a];
|
|
15192
15248
|
return o != null ? String(o) : `<${a}?>`;
|
|
15193
15249
|
});
|
|
15194
15250
|
}
|
|
15195
|
-
const
|
|
15251
|
+
const fO = /\{\$([^}]+)}/g;
|
|
15196
15252
|
function Xf(e, t) {
|
|
15197
15253
|
if (e === t)
|
|
15198
15254
|
return !0;
|
|
@@ -15201,7 +15257,7 @@ function Xf(e, t) {
|
|
|
15201
15257
|
if (!a.includes(o))
|
|
15202
15258
|
return !1;
|
|
15203
15259
|
const c = e[o], h = t[o];
|
|
15204
|
-
if (
|
|
15260
|
+
if (Yg(c) && Yg(h)) {
|
|
15205
15261
|
if (!Xf(c, h))
|
|
15206
15262
|
return !1;
|
|
15207
15263
|
} else if (c !== h)
|
|
@@ -15212,7 +15268,7 @@ function Xf(e, t) {
|
|
|
15212
15268
|
return !1;
|
|
15213
15269
|
return !0;
|
|
15214
15270
|
}
|
|
15215
|
-
function
|
|
15271
|
+
function Yg(e) {
|
|
15216
15272
|
return e !== null && typeof e == "object";
|
|
15217
15273
|
}
|
|
15218
15274
|
/**
|
|
@@ -15290,7 +15346,7 @@ const da = "[DEFAULT]";
|
|
|
15290
15346
|
* See the License for the specific language governing permissions and
|
|
15291
15347
|
* limitations under the License.
|
|
15292
15348
|
*/
|
|
15293
|
-
class
|
|
15349
|
+
class dO {
|
|
15294
15350
|
constructor(t, r) {
|
|
15295
15351
|
this.name = t, this.container = r, this.component = null, this.instances = /* @__PURE__ */ new Map(), this.instancesDeferred = /* @__PURE__ */ new Map(), this.instancesOptions = /* @__PURE__ */ new Map(), this.onInitCallbacks = /* @__PURE__ */ new Map();
|
|
15296
15352
|
}
|
|
@@ -15301,7 +15357,7 @@ class lO {
|
|
|
15301
15357
|
get(t) {
|
|
15302
15358
|
const r = this.normalizeInstanceIdentifier(t);
|
|
15303
15359
|
if (!this.instancesDeferred.has(r)) {
|
|
15304
|
-
const a = new
|
|
15360
|
+
const a = new oO();
|
|
15305
15361
|
if (this.instancesDeferred.set(r, a), this.isInitialized(r) || this.shouldAutoInitialize())
|
|
15306
15362
|
try {
|
|
15307
15363
|
const o = this.getOrInitializeService({
|
|
@@ -15341,7 +15397,7 @@ class lO {
|
|
|
15341
15397
|
if (this.component)
|
|
15342
15398
|
throw Error(`Component for ${this.name} has already been provided`);
|
|
15343
15399
|
if (this.component = t, !!this.shouldAutoInitialize()) {
|
|
15344
|
-
if (
|
|
15400
|
+
if (pO(t))
|
|
15345
15401
|
try {
|
|
15346
15402
|
this.getOrInitializeService({ instanceIdentifier: da });
|
|
15347
15403
|
} catch {
|
|
@@ -15428,7 +15484,7 @@ class lO {
|
|
|
15428
15484
|
getOrInitializeService({ instanceIdentifier: t, options: r = {} }) {
|
|
15429
15485
|
let a = this.instances.get(t);
|
|
15430
15486
|
if (!a && this.component && (a = this.component.instanceFactory(this.container, {
|
|
15431
|
-
instanceIdentifier:
|
|
15487
|
+
instanceIdentifier: hO(t),
|
|
15432
15488
|
options: r
|
|
15433
15489
|
}), this.instances.set(t, a), this.instancesOptions.set(t, r), this.invokeOnInitCallbacks(a, t), this.component.onInstanceCreated))
|
|
15434
15490
|
try {
|
|
@@ -15444,10 +15500,10 @@ class lO {
|
|
|
15444
15500
|
return !!this.component && this.component.instantiationMode !== "EXPLICIT";
|
|
15445
15501
|
}
|
|
15446
15502
|
}
|
|
15447
|
-
function
|
|
15503
|
+
function hO(e) {
|
|
15448
15504
|
return e === da ? void 0 : e;
|
|
15449
15505
|
}
|
|
15450
|
-
function
|
|
15506
|
+
function pO(e) {
|
|
15451
15507
|
return e.instantiationMode === "EAGER";
|
|
15452
15508
|
}
|
|
15453
15509
|
/**
|
|
@@ -15466,7 +15522,7 @@ function fO(e) {
|
|
|
15466
15522
|
* See the License for the specific language governing permissions and
|
|
15467
15523
|
* limitations under the License.
|
|
15468
15524
|
*/
|
|
15469
|
-
class
|
|
15525
|
+
class gO {
|
|
15470
15526
|
constructor(t) {
|
|
15471
15527
|
this.name = t, this.providers = /* @__PURE__ */ new Map();
|
|
15472
15528
|
}
|
|
@@ -15498,7 +15554,7 @@ class dO {
|
|
|
15498
15554
|
getProvider(t) {
|
|
15499
15555
|
if (this.providers.has(t))
|
|
15500
15556
|
return this.providers.get(t);
|
|
15501
|
-
const r = new
|
|
15557
|
+
const r = new dO(t, this);
|
|
15502
15558
|
return this.providers.set(t, r), r;
|
|
15503
15559
|
}
|
|
15504
15560
|
getProviders() {
|
|
@@ -15525,29 +15581,29 @@ var lt;
|
|
|
15525
15581
|
(function(e) {
|
|
15526
15582
|
e[e.DEBUG = 0] = "DEBUG", e[e.VERBOSE = 1] = "VERBOSE", e[e.INFO = 2] = "INFO", e[e.WARN = 3] = "WARN", e[e.ERROR = 4] = "ERROR", e[e.SILENT = 5] = "SILENT";
|
|
15527
15583
|
})(lt || (lt = {}));
|
|
15528
|
-
const
|
|
15584
|
+
const mO = {
|
|
15529
15585
|
debug: lt.DEBUG,
|
|
15530
15586
|
verbose: lt.VERBOSE,
|
|
15531
15587
|
info: lt.INFO,
|
|
15532
15588
|
warn: lt.WARN,
|
|
15533
15589
|
error: lt.ERROR,
|
|
15534
15590
|
silent: lt.SILENT
|
|
15535
|
-
},
|
|
15591
|
+
}, yO = lt.INFO, vO = {
|
|
15536
15592
|
[lt.DEBUG]: "log",
|
|
15537
15593
|
[lt.VERBOSE]: "log",
|
|
15538
15594
|
[lt.INFO]: "info",
|
|
15539
15595
|
[lt.WARN]: "warn",
|
|
15540
15596
|
[lt.ERROR]: "error"
|
|
15541
|
-
},
|
|
15597
|
+
}, bO = (e, t, ...r) => {
|
|
15542
15598
|
if (t < e.logLevel)
|
|
15543
15599
|
return;
|
|
15544
|
-
const a = (/* @__PURE__ */ new Date()).toISOString(), o =
|
|
15600
|
+
const a = (/* @__PURE__ */ new Date()).toISOString(), o = vO[t];
|
|
15545
15601
|
if (o)
|
|
15546
15602
|
console[o](`[${a}] ${e.name}:`, ...r);
|
|
15547
15603
|
else
|
|
15548
15604
|
throw new Error(`Attempted to log a message with an invalid logType (value: ${t})`);
|
|
15549
15605
|
};
|
|
15550
|
-
class
|
|
15606
|
+
class _O {
|
|
15551
15607
|
/**
|
|
15552
15608
|
* Gives you an instance of a Logger to capture messages according to
|
|
15553
15609
|
* Firebase's logging scheme.
|
|
@@ -15555,7 +15611,7 @@ class yO {
|
|
|
15555
15611
|
* @param name The name that the logs will be associated with
|
|
15556
15612
|
*/
|
|
15557
15613
|
constructor(t) {
|
|
15558
|
-
this.name = t, this._logLevel =
|
|
15614
|
+
this.name = t, this._logLevel = yO, this._logHandler = bO, this._userLogHandler = null;
|
|
15559
15615
|
}
|
|
15560
15616
|
get logLevel() {
|
|
15561
15617
|
return this._logLevel;
|
|
@@ -15567,7 +15623,7 @@ class yO {
|
|
|
15567
15623
|
}
|
|
15568
15624
|
// Workaround for setter/getter having to be the same type.
|
|
15569
15625
|
setLogLevel(t) {
|
|
15570
|
-
this._logLevel = typeof t == "string" ?
|
|
15626
|
+
this._logLevel = typeof t == "string" ? mO[t] : t;
|
|
15571
15627
|
}
|
|
15572
15628
|
get logHandler() {
|
|
15573
15629
|
return this._logHandler;
|
|
@@ -15602,10 +15658,10 @@ class yO {
|
|
|
15602
15658
|
this._userLogHandler && this._userLogHandler(this, lt.ERROR, ...t), this._logHandler(this, lt.ERROR, ...t);
|
|
15603
15659
|
}
|
|
15604
15660
|
}
|
|
15605
|
-
const
|
|
15606
|
-
let
|
|
15607
|
-
function
|
|
15608
|
-
return
|
|
15661
|
+
const wO = (e, t) => t.some((r) => e instanceof r);
|
|
15662
|
+
let Bg, Wg;
|
|
15663
|
+
function xO() {
|
|
15664
|
+
return Bg || (Bg = [
|
|
15609
15665
|
IDBDatabase,
|
|
15610
15666
|
IDBObjectStore,
|
|
15611
15667
|
IDBIndex,
|
|
@@ -15613,15 +15669,15 @@ function bO() {
|
|
|
15613
15669
|
IDBTransaction
|
|
15614
15670
|
]);
|
|
15615
15671
|
}
|
|
15616
|
-
function
|
|
15617
|
-
return
|
|
15672
|
+
function SO() {
|
|
15673
|
+
return Wg || (Wg = [
|
|
15618
15674
|
IDBCursor.prototype.advance,
|
|
15619
15675
|
IDBCursor.prototype.continue,
|
|
15620
15676
|
IDBCursor.prototype.continuePrimaryKey
|
|
15621
15677
|
]);
|
|
15622
15678
|
}
|
|
15623
15679
|
const K0 = /* @__PURE__ */ new WeakMap(), Jf = /* @__PURE__ */ new WeakMap(), Z0 = /* @__PURE__ */ new WeakMap(), Df = /* @__PURE__ */ new WeakMap(), Kd = /* @__PURE__ */ new WeakMap();
|
|
15624
|
-
function
|
|
15680
|
+
function kO(e) {
|
|
15625
15681
|
const t = new Promise((r, a) => {
|
|
15626
15682
|
const o = () => {
|
|
15627
15683
|
e.removeEventListener("success", c), e.removeEventListener("error", h);
|
|
@@ -15637,7 +15693,7 @@ function wO(e) {
|
|
|
15637
15693
|
}).catch(() => {
|
|
15638
15694
|
}), Kd.set(t, e), t;
|
|
15639
15695
|
}
|
|
15640
|
-
function
|
|
15696
|
+
function CO(e) {
|
|
15641
15697
|
if (Jf.has(e))
|
|
15642
15698
|
return;
|
|
15643
15699
|
const t = new Promise((r, a) => {
|
|
@@ -15671,28 +15727,28 @@ let Qf = {
|
|
|
15671
15727
|
return e instanceof IDBTransaction && (t === "done" || t === "store") ? !0 : t in e;
|
|
15672
15728
|
}
|
|
15673
15729
|
};
|
|
15674
|
-
function
|
|
15730
|
+
function DO(e) {
|
|
15675
15731
|
Qf = e(Qf);
|
|
15676
15732
|
}
|
|
15677
|
-
function
|
|
15733
|
+
function TO(e) {
|
|
15678
15734
|
return e === IDBDatabase.prototype.transaction && !("objectStoreNames" in IDBTransaction.prototype) ? function(t, ...r) {
|
|
15679
15735
|
const a = e.call(Tf(this), t, ...r);
|
|
15680
15736
|
return Z0.set(a, t.sort ? t.sort() : [t]), mi(a);
|
|
15681
|
-
} :
|
|
15737
|
+
} : SO().includes(e) ? function(...t) {
|
|
15682
15738
|
return e.apply(Tf(this), t), mi(K0.get(this));
|
|
15683
15739
|
} : function(...t) {
|
|
15684
15740
|
return mi(e.apply(Tf(this), t));
|
|
15685
15741
|
};
|
|
15686
15742
|
}
|
|
15687
|
-
function
|
|
15688
|
-
return typeof e == "function" ?
|
|
15743
|
+
function MO(e) {
|
|
15744
|
+
return typeof e == "function" ? TO(e) : (e instanceof IDBTransaction && CO(e), wO(e, xO()) ? new Proxy(e, Qf) : e);
|
|
15689
15745
|
}
|
|
15690
15746
|
function mi(e) {
|
|
15691
15747
|
if (e instanceof IDBRequest)
|
|
15692
|
-
return
|
|
15748
|
+
return kO(e);
|
|
15693
15749
|
if (Df.has(e))
|
|
15694
15750
|
return Df.get(e);
|
|
15695
|
-
const t =
|
|
15751
|
+
const t = MO(e);
|
|
15696
15752
|
return t !== e && (Df.set(e, t), Kd.set(t, e)), t;
|
|
15697
15753
|
}
|
|
15698
15754
|
const Tf = (e) => Kd.get(e);
|
|
@@ -15719,16 +15775,16 @@ function Mf(e, { blocked: t } = {}) {
|
|
|
15719
15775
|
)), mi(r).then(() => {
|
|
15720
15776
|
});
|
|
15721
15777
|
}
|
|
15722
|
-
const
|
|
15723
|
-
function
|
|
15778
|
+
const EO = ["get", "getKey", "getAll", "getAllKeys", "count"], AO = ["put", "add", "delete", "clear"], Ef = /* @__PURE__ */ new Map();
|
|
15779
|
+
function jg(e, t) {
|
|
15724
15780
|
if (!(e instanceof IDBDatabase && !(t in e) && typeof t == "string"))
|
|
15725
15781
|
return;
|
|
15726
15782
|
if (Ef.get(t))
|
|
15727
15783
|
return Ef.get(t);
|
|
15728
|
-
const r = t.replace(/FromIndex$/, ""), a = t !== r, o =
|
|
15784
|
+
const r = t.replace(/FromIndex$/, ""), a = t !== r, o = AO.includes(r);
|
|
15729
15785
|
if (
|
|
15730
15786
|
// Bail if the target doesn't exist on the target. Eg, getAll isn't in Edge.
|
|
15731
|
-
!(r in (a ? IDBIndex : IDBObjectStore).prototype) || !(o ||
|
|
15787
|
+
!(r in (a ? IDBIndex : IDBObjectStore).prototype) || !(o || EO.includes(r))
|
|
15732
15788
|
)
|
|
15733
15789
|
return;
|
|
15734
15790
|
const c = async function(h, ...b) {
|
|
@@ -15741,10 +15797,10 @@ function Wg(e, t) {
|
|
|
15741
15797
|
};
|
|
15742
15798
|
return Ef.set(t, c), c;
|
|
15743
15799
|
}
|
|
15744
|
-
|
|
15800
|
+
DO((e) => ({
|
|
15745
15801
|
...e,
|
|
15746
|
-
get: (t, r, a) =>
|
|
15747
|
-
has: (t, r) => !!
|
|
15802
|
+
get: (t, r, a) => jg(t, r) || e.get(t, r, a),
|
|
15803
|
+
has: (t, r) => !!jg(t, r) || e.has(t, r)
|
|
15748
15804
|
}));
|
|
15749
15805
|
/**
|
|
15750
15806
|
* @license
|
|
@@ -15762,7 +15818,7 @@ SO((e) => ({
|
|
|
15762
15818
|
* See the License for the specific language governing permissions and
|
|
15763
15819
|
* limitations under the License.
|
|
15764
15820
|
*/
|
|
15765
|
-
class
|
|
15821
|
+
class OO {
|
|
15766
15822
|
constructor(t) {
|
|
15767
15823
|
this.container = t;
|
|
15768
15824
|
}
|
|
@@ -15770,7 +15826,7 @@ class MO {
|
|
|
15770
15826
|
// auth token refresh, and installations will send this string.
|
|
15771
15827
|
getPlatformInfoString() {
|
|
15772
15828
|
return this.container.getProviders().map((r) => {
|
|
15773
|
-
if (
|
|
15829
|
+
if (IO(r)) {
|
|
15774
15830
|
const a = r.getImmediate();
|
|
15775
15831
|
return `${a.library}/${a.version}`;
|
|
15776
15832
|
} else
|
|
@@ -15778,11 +15834,11 @@ class MO {
|
|
|
15778
15834
|
}).filter((r) => r).join(" ");
|
|
15779
15835
|
}
|
|
15780
15836
|
}
|
|
15781
|
-
function
|
|
15837
|
+
function IO(e) {
|
|
15782
15838
|
const t = e.getComponent();
|
|
15783
15839
|
return (t == null ? void 0 : t.type) === "VERSION";
|
|
15784
15840
|
}
|
|
15785
|
-
const ed = "@firebase/app",
|
|
15841
|
+
const ed = "@firebase/app", Hg = "0.9.28";
|
|
15786
15842
|
/**
|
|
15787
15843
|
* @license
|
|
15788
15844
|
* Copyright 2019 Google LLC
|
|
@@ -15799,7 +15855,7 @@ const ed = "@firebase/app", jg = "0.9.28";
|
|
|
15799
15855
|
* See the License for the specific language governing permissions and
|
|
15800
15856
|
* limitations under the License.
|
|
15801
15857
|
*/
|
|
15802
|
-
const va = new
|
|
15858
|
+
const va = new _O("@firebase/app"), RO = "@firebase/app-compat", PO = "@firebase/analytics-compat", NO = "@firebase/analytics", LO = "@firebase/app-check-compat", $O = "@firebase/app-check", FO = "@firebase/auth", YO = "@firebase/auth-compat", BO = "@firebase/database", WO = "@firebase/database-compat", jO = "@firebase/functions", HO = "@firebase/functions-compat", UO = "@firebase/installations", qO = "@firebase/installations-compat", zO = "@firebase/messaging", VO = "@firebase/messaging-compat", GO = "@firebase/performance", KO = "@firebase/performance-compat", ZO = "@firebase/remote-config", XO = "@firebase/remote-config-compat", JO = "@firebase/storage", QO = "@firebase/storage-compat", eI = "@firebase/firestore", tI = "@firebase/firestore-compat", nI = "firebase";
|
|
15803
15859
|
/**
|
|
15804
15860
|
* @license
|
|
15805
15861
|
* Copyright 2019 Google LLC
|
|
@@ -15816,33 +15872,33 @@ const va = new yO("@firebase/app"), AO = "@firebase/app-compat", OO = "@firebase
|
|
|
15816
15872
|
* See the License for the specific language governing permissions and
|
|
15817
15873
|
* limitations under the License.
|
|
15818
15874
|
*/
|
|
15819
|
-
const td = "[DEFAULT]",
|
|
15875
|
+
const td = "[DEFAULT]", rI = {
|
|
15820
15876
|
[ed]: "fire-core",
|
|
15821
|
-
[
|
|
15822
|
-
[
|
|
15823
|
-
[
|
|
15824
|
-
[
|
|
15825
|
-
[
|
|
15826
|
-
[
|
|
15827
|
-
[
|
|
15828
|
-
[
|
|
15829
|
-
[
|
|
15830
|
-
[
|
|
15831
|
-
[
|
|
15832
|
-
[
|
|
15833
|
-
[
|
|
15834
|
-
[
|
|
15835
|
-
[
|
|
15836
|
-
[
|
|
15837
|
-
[
|
|
15838
|
-
[
|
|
15839
|
-
[
|
|
15840
|
-
[
|
|
15841
|
-
[
|
|
15842
|
-
[
|
|
15843
|
-
[
|
|
15877
|
+
[RO]: "fire-core-compat",
|
|
15878
|
+
[NO]: "fire-analytics",
|
|
15879
|
+
[PO]: "fire-analytics-compat",
|
|
15880
|
+
[$O]: "fire-app-check",
|
|
15881
|
+
[LO]: "fire-app-check-compat",
|
|
15882
|
+
[FO]: "fire-auth",
|
|
15883
|
+
[YO]: "fire-auth-compat",
|
|
15884
|
+
[BO]: "fire-rtdb",
|
|
15885
|
+
[WO]: "fire-rtdb-compat",
|
|
15886
|
+
[jO]: "fire-fn",
|
|
15887
|
+
[HO]: "fire-fn-compat",
|
|
15888
|
+
[UO]: "fire-iid",
|
|
15889
|
+
[qO]: "fire-iid-compat",
|
|
15890
|
+
[zO]: "fire-fcm",
|
|
15891
|
+
[VO]: "fire-fcm-compat",
|
|
15892
|
+
[GO]: "fire-perf",
|
|
15893
|
+
[KO]: "fire-perf-compat",
|
|
15894
|
+
[ZO]: "fire-rc",
|
|
15895
|
+
[XO]: "fire-rc-compat",
|
|
15896
|
+
[JO]: "fire-gcs",
|
|
15897
|
+
[QO]: "fire-gcs-compat",
|
|
15898
|
+
[eI]: "fire-fst",
|
|
15899
|
+
[tI]: "fire-fst-compat",
|
|
15844
15900
|
"fire-js": "fire-js",
|
|
15845
|
-
[
|
|
15901
|
+
[nI]: "fire-js-all"
|
|
15846
15902
|
};
|
|
15847
15903
|
/**
|
|
15848
15904
|
* @license
|
|
@@ -15861,7 +15917,7 @@ const td = "[DEFAULT]", eI = {
|
|
|
15861
15917
|
* limitations under the License.
|
|
15862
15918
|
*/
|
|
15863
15919
|
const rl = /* @__PURE__ */ new Map(), nd = /* @__PURE__ */ new Map();
|
|
15864
|
-
function
|
|
15920
|
+
function iI(e, t) {
|
|
15865
15921
|
try {
|
|
15866
15922
|
e.container.addComponent(t);
|
|
15867
15923
|
} catch (r) {
|
|
@@ -15874,7 +15930,7 @@ function ba(e) {
|
|
|
15874
15930
|
return va.debug(`There were multiple attempts to register component ${t}.`), !1;
|
|
15875
15931
|
nd.set(t, e);
|
|
15876
15932
|
for (const r of rl.values())
|
|
15877
|
-
|
|
15933
|
+
iI(r, e);
|
|
15878
15934
|
return !0;
|
|
15879
15935
|
}
|
|
15880
15936
|
function Zd(e, t) {
|
|
@@ -15897,7 +15953,7 @@ function Zd(e, t) {
|
|
|
15897
15953
|
* See the License for the specific language governing permissions and
|
|
15898
15954
|
* limitations under the License.
|
|
15899
15955
|
*/
|
|
15900
|
-
const
|
|
15956
|
+
const aI = {
|
|
15901
15957
|
"no-app": "No Firebase App '{$appName}' has been created - call initializeApp() first",
|
|
15902
15958
|
"bad-app-name": "Illegal App name: '{$appName}",
|
|
15903
15959
|
"duplicate-app": "Firebase App named '{$appName}' already exists with different options or config",
|
|
@@ -15909,7 +15965,7 @@ const nI = {
|
|
|
15909
15965
|
"idb-get": "Error thrown when reading from IndexedDB. Original error: {$originalErrorMessage}.",
|
|
15910
15966
|
"idb-set": "Error thrown when writing to IndexedDB. Original error: {$originalErrorMessage}.",
|
|
15911
15967
|
"idb-delete": "Error thrown when deleting from IndexedDB. Original error: {$originalErrorMessage}."
|
|
15912
|
-
}, Hi = new Jl("app", "Firebase",
|
|
15968
|
+
}, Hi = new Jl("app", "Firebase", aI);
|
|
15913
15969
|
/**
|
|
15914
15970
|
* @license
|
|
15915
15971
|
* Copyright 2019 Google LLC
|
|
@@ -15926,7 +15982,7 @@ const nI = {
|
|
|
15926
15982
|
* See the License for the specific language governing permissions and
|
|
15927
15983
|
* limitations under the License.
|
|
15928
15984
|
*/
|
|
15929
|
-
class
|
|
15985
|
+
class sI {
|
|
15930
15986
|
constructor(t, r, a) {
|
|
15931
15987
|
this._isDeleted = !1, this._options = Object.assign({}, t), this._config = Object.assign({}, r), this._name = r.name, this._automaticDataCollectionEnabled = r.automaticDataCollectionEnabled, this._container = a, this.container.addComponent(new qi(
|
|
15932
15988
|
"app",
|
|
@@ -15987,13 +16043,13 @@ function Xd(e, t = {}) {
|
|
|
15987
16043
|
return c;
|
|
15988
16044
|
throw Hi.create("duplicate-app", { appName: o });
|
|
15989
16045
|
}
|
|
15990
|
-
const h = new
|
|
16046
|
+
const h = new gO(o);
|
|
15991
16047
|
for (const S of nd.values())
|
|
15992
16048
|
h.addComponent(S);
|
|
15993
|
-
const b = new
|
|
16049
|
+
const b = new sI(r, a, h);
|
|
15994
16050
|
return rl.set(o, b), b;
|
|
15995
16051
|
}
|
|
15996
|
-
function
|
|
16052
|
+
function oI(e = td) {
|
|
15997
16053
|
const t = rl.get(e);
|
|
15998
16054
|
if (!t && e === td && z0())
|
|
15999
16055
|
return Xd();
|
|
@@ -16003,7 +16059,7 @@ function iI(e = td) {
|
|
|
16003
16059
|
}
|
|
16004
16060
|
function Ui(e, t, r) {
|
|
16005
16061
|
var a;
|
|
16006
|
-
let o = (a =
|
|
16062
|
+
let o = (a = rI[e]) !== null && a !== void 0 ? a : e;
|
|
16007
16063
|
r && (o += `-${r}`);
|
|
16008
16064
|
const c = o.match(/\s|\//), h = t.match(/\s|\//);
|
|
16009
16065
|
if (c || h) {
|
|
@@ -16036,10 +16092,10 @@ function Ui(e, t, r) {
|
|
|
16036
16092
|
* See the License for the specific language governing permissions and
|
|
16037
16093
|
* limitations under the License.
|
|
16038
16094
|
*/
|
|
16039
|
-
const
|
|
16095
|
+
const uI = "firebase-heartbeat-database", lI = 1, co = "firebase-heartbeat-store";
|
|
16040
16096
|
let Af = null;
|
|
16041
16097
|
function X0() {
|
|
16042
|
-
return Af || (Af = Ql(
|
|
16098
|
+
return Af || (Af = Ql(uI, lI, {
|
|
16043
16099
|
upgrade: (e, t) => {
|
|
16044
16100
|
switch (t) {
|
|
16045
16101
|
case 0:
|
|
@@ -16056,7 +16112,7 @@ function X0() {
|
|
|
16056
16112
|
});
|
|
16057
16113
|
})), Af;
|
|
16058
16114
|
}
|
|
16059
|
-
async function
|
|
16115
|
+
async function cI(e) {
|
|
16060
16116
|
try {
|
|
16061
16117
|
const r = (await X0()).transaction(co), a = await r.objectStore(co).get(J0(e));
|
|
16062
16118
|
return await r.done, a;
|
|
@@ -16071,7 +16127,7 @@ async function oI(e) {
|
|
|
16071
16127
|
}
|
|
16072
16128
|
}
|
|
16073
16129
|
}
|
|
16074
|
-
async function
|
|
16130
|
+
async function Ug(e, t) {
|
|
16075
16131
|
try {
|
|
16076
16132
|
const a = (await X0()).transaction(co, "readwrite");
|
|
16077
16133
|
await a.objectStore(co).put(t, J0(e)), await a.done;
|
|
@@ -16105,12 +16161,12 @@ function J0(e) {
|
|
|
16105
16161
|
* See the License for the specific language governing permissions and
|
|
16106
16162
|
* limitations under the License.
|
|
16107
16163
|
*/
|
|
16108
|
-
const
|
|
16109
|
-
class
|
|
16164
|
+
const fI = 1024, dI = 30 * 24 * 60 * 60 * 1e3;
|
|
16165
|
+
class hI {
|
|
16110
16166
|
constructor(t) {
|
|
16111
16167
|
this.container = t, this._heartbeatsCache = null;
|
|
16112
16168
|
const r = this.container.getProvider("app").getImmediate();
|
|
16113
|
-
this._storage = new
|
|
16169
|
+
this._storage = new gI(r), this._heartbeatsCachePromise = this._storage.read().then((a) => (this._heartbeatsCache = a, a));
|
|
16114
16170
|
}
|
|
16115
16171
|
/**
|
|
16116
16172
|
* Called to report a heartbeat. The function will generate
|
|
@@ -16121,11 +16177,11 @@ class cI {
|
|
|
16121
16177
|
*/
|
|
16122
16178
|
async triggerHeartbeat() {
|
|
16123
16179
|
var t, r;
|
|
16124
|
-
const o = this.container.getProvider("platform-logger").getImmediate().getPlatformInfoString(), c =
|
|
16180
|
+
const o = this.container.getProvider("platform-logger").getImmediate().getPlatformInfoString(), c = qg();
|
|
16125
16181
|
if (!(((t = this._heartbeatsCache) === null || t === void 0 ? void 0 : t.heartbeats) == null && (this._heartbeatsCache = await this._heartbeatsCachePromise, ((r = this._heartbeatsCache) === null || r === void 0 ? void 0 : r.heartbeats) == null)) && !(this._heartbeatsCache.lastSentHeartbeatDate === c || this._heartbeatsCache.heartbeats.some((h) => h.date === c)))
|
|
16126
16182
|
return this._heartbeatsCache.heartbeats.push({ date: c, agent: o }), this._heartbeatsCache.heartbeats = this._heartbeatsCache.heartbeats.filter((h) => {
|
|
16127
16183
|
const b = new Date(h.date).valueOf();
|
|
16128
|
-
return Date.now() - b <=
|
|
16184
|
+
return Date.now() - b <= dI;
|
|
16129
16185
|
}), this._storage.overwrite(this._heartbeatsCache);
|
|
16130
16186
|
}
|
|
16131
16187
|
/**
|
|
@@ -16139,27 +16195,27 @@ class cI {
|
|
|
16139
16195
|
var t;
|
|
16140
16196
|
if (this._heartbeatsCache === null && await this._heartbeatsCachePromise, ((t = this._heartbeatsCache) === null || t === void 0 ? void 0 : t.heartbeats) == null || this._heartbeatsCache.heartbeats.length === 0)
|
|
16141
16197
|
return "";
|
|
16142
|
-
const r =
|
|
16198
|
+
const r = qg(), { heartbeatsToSend: a, unsentEntries: o } = pI(this._heartbeatsCache.heartbeats), c = q0(JSON.stringify({ version: 2, heartbeats: a }));
|
|
16143
16199
|
return this._heartbeatsCache.lastSentHeartbeatDate = r, o.length > 0 ? (this._heartbeatsCache.heartbeats = o, await this._storage.overwrite(this._heartbeatsCache)) : (this._heartbeatsCache.heartbeats = [], this._storage.overwrite(this._heartbeatsCache)), c;
|
|
16144
16200
|
}
|
|
16145
16201
|
}
|
|
16146
|
-
function
|
|
16202
|
+
function qg() {
|
|
16147
16203
|
return (/* @__PURE__ */ new Date()).toISOString().substring(0, 10);
|
|
16148
16204
|
}
|
|
16149
|
-
function
|
|
16205
|
+
function pI(e, t = fI) {
|
|
16150
16206
|
const r = [];
|
|
16151
16207
|
let a = e.slice();
|
|
16152
16208
|
for (const o of e) {
|
|
16153
16209
|
const c = r.find((h) => h.agent === o.agent);
|
|
16154
16210
|
if (c) {
|
|
16155
|
-
if (c.dates.push(o.date),
|
|
16211
|
+
if (c.dates.push(o.date), zg(r) > t) {
|
|
16156
16212
|
c.dates.pop();
|
|
16157
16213
|
break;
|
|
16158
16214
|
}
|
|
16159
16215
|
} else if (r.push({
|
|
16160
16216
|
agent: o.agent,
|
|
16161
16217
|
dates: [o.date]
|
|
16162
|
-
}),
|
|
16218
|
+
}), zg(r) > t) {
|
|
16163
16219
|
r.pop();
|
|
16164
16220
|
break;
|
|
16165
16221
|
}
|
|
@@ -16170,7 +16226,7 @@ function fI(e, t = uI) {
|
|
|
16170
16226
|
unsentEntries: a
|
|
16171
16227
|
};
|
|
16172
16228
|
}
|
|
16173
|
-
class
|
|
16229
|
+
class gI {
|
|
16174
16230
|
constructor(t) {
|
|
16175
16231
|
this.app = t, this._canUseIndexedDBPromise = this.runIndexedDBEnvironmentCheck();
|
|
16176
16232
|
}
|
|
@@ -16182,7 +16238,7 @@ class dI {
|
|
|
16182
16238
|
*/
|
|
16183
16239
|
async read() {
|
|
16184
16240
|
if (await this._canUseIndexedDBPromise) {
|
|
16185
|
-
const r = await
|
|
16241
|
+
const r = await cI(this.app);
|
|
16186
16242
|
return r != null && r.heartbeats ? r : { heartbeats: [] };
|
|
16187
16243
|
} else
|
|
16188
16244
|
return { heartbeats: [] };
|
|
@@ -16192,7 +16248,7 @@ class dI {
|
|
|
16192
16248
|
var r;
|
|
16193
16249
|
if (await this._canUseIndexedDBPromise) {
|
|
16194
16250
|
const o = await this.read();
|
|
16195
|
-
return
|
|
16251
|
+
return Ug(this.app, {
|
|
16196
16252
|
lastSentHeartbeatDate: (r = t.lastSentHeartbeatDate) !== null && r !== void 0 ? r : o.lastSentHeartbeatDate,
|
|
16197
16253
|
heartbeats: t.heartbeats
|
|
16198
16254
|
});
|
|
@@ -16204,7 +16260,7 @@ class dI {
|
|
|
16204
16260
|
var r;
|
|
16205
16261
|
if (await this._canUseIndexedDBPromise) {
|
|
16206
16262
|
const o = await this.read();
|
|
16207
|
-
return
|
|
16263
|
+
return Ug(this.app, {
|
|
16208
16264
|
lastSentHeartbeatDate: (r = t.lastSentHeartbeatDate) !== null && r !== void 0 ? r : o.lastSentHeartbeatDate,
|
|
16209
16265
|
heartbeats: [
|
|
16210
16266
|
...o.heartbeats,
|
|
@@ -16215,7 +16271,7 @@ class dI {
|
|
|
16215
16271
|
return;
|
|
16216
16272
|
}
|
|
16217
16273
|
}
|
|
16218
|
-
function
|
|
16274
|
+
function zg(e) {
|
|
16219
16275
|
return q0(
|
|
16220
16276
|
// heartbeatsCache wrapper properties
|
|
16221
16277
|
JSON.stringify({ version: 2, heartbeats: e })
|
|
@@ -16237,21 +16293,21 @@ function qg(e) {
|
|
|
16237
16293
|
* See the License for the specific language governing permissions and
|
|
16238
16294
|
* limitations under the License.
|
|
16239
16295
|
*/
|
|
16240
|
-
function
|
|
16296
|
+
function mI(e) {
|
|
16241
16297
|
ba(new qi(
|
|
16242
16298
|
"platform-logger",
|
|
16243
|
-
(t) => new
|
|
16299
|
+
(t) => new OO(t),
|
|
16244
16300
|
"PRIVATE"
|
|
16245
16301
|
/* ComponentType.PRIVATE */
|
|
16246
16302
|
)), ba(new qi(
|
|
16247
16303
|
"heartbeat",
|
|
16248
|
-
(t) => new
|
|
16304
|
+
(t) => new hI(t),
|
|
16249
16305
|
"PRIVATE"
|
|
16250
16306
|
/* ComponentType.PRIVATE */
|
|
16251
|
-
)), Ui(ed,
|
|
16307
|
+
)), Ui(ed, Hg, e), Ui(ed, Hg, "esm2017"), Ui("fire-js", "");
|
|
16252
16308
|
}
|
|
16253
|
-
|
|
16254
|
-
var
|
|
16309
|
+
mI("");
|
|
16310
|
+
var yI = "firebase", vI = "10.8.1";
|
|
16255
16311
|
/**
|
|
16256
16312
|
* @license
|
|
16257
16313
|
* Copyright 2020 Google LLC
|
|
@@ -16268,7 +16324,7 @@ var pI = "firebase", gI = "10.8.1";
|
|
|
16268
16324
|
* See the License for the specific language governing permissions and
|
|
16269
16325
|
* limitations under the License.
|
|
16270
16326
|
*/
|
|
16271
|
-
Ui(
|
|
16327
|
+
Ui(yI, vI, "app");
|
|
16272
16328
|
const Q0 = "@firebase/installations", Jd = "0.6.5";
|
|
16273
16329
|
/**
|
|
16274
16330
|
* @license
|
|
@@ -16286,7 +16342,7 @@ const Q0 = "@firebase/installations", Jd = "0.6.5";
|
|
|
16286
16342
|
* See the License for the specific language governing permissions and
|
|
16287
16343
|
* limitations under the License.
|
|
16288
16344
|
*/
|
|
16289
|
-
const ey = 1e4, ty = `w:${Jd}`, ny = "FIS_v2",
|
|
16345
|
+
const ey = 1e4, ty = `w:${Jd}`, ny = "FIS_v2", bI = "https://firebaseinstallations.googleapis.com/v1", _I = 60 * 60 * 1e3, wI = "installations", xI = "Installations";
|
|
16290
16346
|
/**
|
|
16291
16347
|
* @license
|
|
16292
16348
|
* Copyright 2019 Google LLC
|
|
@@ -16303,14 +16359,14 @@ const ey = 1e4, ty = `w:${Jd}`, ny = "FIS_v2", mI = "https://firebaseinstallatio
|
|
|
16303
16359
|
* See the License for the specific language governing permissions and
|
|
16304
16360
|
* limitations under the License.
|
|
16305
16361
|
*/
|
|
16306
|
-
const
|
|
16362
|
+
const SI = {
|
|
16307
16363
|
"missing-app-config-values": 'Missing App configuration value: "{$valueName}"',
|
|
16308
16364
|
"not-registered": "Firebase Installation is not registered.",
|
|
16309
16365
|
"installation-not-found": "Firebase Installation not found.",
|
|
16310
16366
|
"request-failed": '{$requestName} request failed with error "{$serverCode} {$serverStatus}: {$serverMessage}"',
|
|
16311
16367
|
"app-offline": "Could not process request. Application offline.",
|
|
16312
16368
|
"delete-pending-registration": "Can't delete installation while there is a pending registration request."
|
|
16313
|
-
}, _a = new Jl(
|
|
16369
|
+
}, _a = new Jl(wI, xI, SI);
|
|
16314
16370
|
function ry(e) {
|
|
16315
16371
|
return e instanceof cs && e.code.includes(
|
|
16316
16372
|
"request-failed"
|
|
@@ -16334,13 +16390,13 @@ function ry(e) {
|
|
|
16334
16390
|
* limitations under the License.
|
|
16335
16391
|
*/
|
|
16336
16392
|
function iy({ projectId: e }) {
|
|
16337
|
-
return `${
|
|
16393
|
+
return `${bI}/projects/${e}/installations`;
|
|
16338
16394
|
}
|
|
16339
16395
|
function ay(e) {
|
|
16340
16396
|
return {
|
|
16341
16397
|
token: e.token,
|
|
16342
16398
|
requestStatus: 2,
|
|
16343
|
-
expiresIn:
|
|
16399
|
+
expiresIn: CI(e.expiresIn),
|
|
16344
16400
|
creationTime: Date.now()
|
|
16345
16401
|
};
|
|
16346
16402
|
}
|
|
@@ -16360,18 +16416,18 @@ function oy({ apiKey: e }) {
|
|
|
16360
16416
|
"x-goog-api-key": e
|
|
16361
16417
|
});
|
|
16362
16418
|
}
|
|
16363
|
-
function
|
|
16419
|
+
function kI(e, { refreshToken: t }) {
|
|
16364
16420
|
const r = oy(e);
|
|
16365
|
-
return r.append("Authorization",
|
|
16421
|
+
return r.append("Authorization", DI(t)), r;
|
|
16366
16422
|
}
|
|
16367
16423
|
async function uy(e) {
|
|
16368
16424
|
const t = await e();
|
|
16369
16425
|
return t.status >= 500 && t.status < 600 ? e() : t;
|
|
16370
16426
|
}
|
|
16371
|
-
function
|
|
16427
|
+
function CI(e) {
|
|
16372
16428
|
return Number(e.replace("s", "000"));
|
|
16373
16429
|
}
|
|
16374
|
-
function
|
|
16430
|
+
function DI(e) {
|
|
16375
16431
|
return `${ny} ${e}`;
|
|
16376
16432
|
}
|
|
16377
16433
|
/**
|
|
@@ -16390,7 +16446,7 @@ function SI(e) {
|
|
|
16390
16446
|
* See the License for the specific language governing permissions and
|
|
16391
16447
|
* limitations under the License.
|
|
16392
16448
|
*/
|
|
16393
|
-
async function
|
|
16449
|
+
async function TI({ appConfig: e, heartbeatServiceProvider: t }, { fid: r }) {
|
|
16394
16450
|
const a = iy(e), o = oy(e), c = t.getImmediate({
|
|
16395
16451
|
optional: !0
|
|
16396
16452
|
});
|
|
@@ -16456,7 +16512,7 @@ function ly(e) {
|
|
|
16456
16512
|
* See the License for the specific language governing permissions and
|
|
16457
16513
|
* limitations under the License.
|
|
16458
16514
|
*/
|
|
16459
|
-
function
|
|
16515
|
+
function MI(e) {
|
|
16460
16516
|
return btoa(String.fromCharCode(...e)).replace(/\+/g, "-").replace(/\//g, "_");
|
|
16461
16517
|
}
|
|
16462
16518
|
/**
|
|
@@ -16475,19 +16531,19 @@ function CI(e) {
|
|
|
16475
16531
|
* See the License for the specific language governing permissions and
|
|
16476
16532
|
* limitations under the License.
|
|
16477
16533
|
*/
|
|
16478
|
-
const
|
|
16479
|
-
function
|
|
16534
|
+
const EI = /^[cdef][\w-]{21}$/, rd = "";
|
|
16535
|
+
function AI() {
|
|
16480
16536
|
try {
|
|
16481
16537
|
const e = new Uint8Array(17);
|
|
16482
16538
|
(self.crypto || self.msCrypto).getRandomValues(e), e[0] = 112 + e[0] % 16;
|
|
16483
|
-
const r =
|
|
16484
|
-
return
|
|
16539
|
+
const r = OI(e);
|
|
16540
|
+
return EI.test(r) ? r : rd;
|
|
16485
16541
|
} catch {
|
|
16486
16542
|
return rd;
|
|
16487
16543
|
}
|
|
16488
16544
|
}
|
|
16489
|
-
function
|
|
16490
|
-
return
|
|
16545
|
+
function OI(e) {
|
|
16546
|
+
return MI(e).substr(0, 22);
|
|
16491
16547
|
}
|
|
16492
16548
|
/**
|
|
16493
16549
|
* @license
|
|
@@ -16527,7 +16583,7 @@ function ec(e) {
|
|
|
16527
16583
|
const cy = /* @__PURE__ */ new Map();
|
|
16528
16584
|
function fy(e, t) {
|
|
16529
16585
|
const r = ec(e);
|
|
16530
|
-
dy(r, t),
|
|
16586
|
+
dy(r, t), II(r, t);
|
|
16531
16587
|
}
|
|
16532
16588
|
function dy(e, t) {
|
|
16533
16589
|
const r = cy.get(e);
|
|
@@ -16535,17 +16591,17 @@ function dy(e, t) {
|
|
|
16535
16591
|
for (const a of r)
|
|
16536
16592
|
a(t);
|
|
16537
16593
|
}
|
|
16538
|
-
function
|
|
16539
|
-
const r =
|
|
16540
|
-
r && r.postMessage({ key: e, fid: t }),
|
|
16594
|
+
function II(e, t) {
|
|
16595
|
+
const r = RI();
|
|
16596
|
+
r && r.postMessage({ key: e, fid: t }), PI();
|
|
16541
16597
|
}
|
|
16542
16598
|
let ma = null;
|
|
16543
|
-
function
|
|
16599
|
+
function RI() {
|
|
16544
16600
|
return !ma && "BroadcastChannel" in self && (ma = new BroadcastChannel("[Firebase] FID Change"), ma.onmessage = (e) => {
|
|
16545
16601
|
dy(e.data.key, e.data.fid);
|
|
16546
16602
|
}), ma;
|
|
16547
16603
|
}
|
|
16548
|
-
function
|
|
16604
|
+
function PI() {
|
|
16549
16605
|
cy.size === 0 && ma && (ma.close(), ma = null);
|
|
16550
16606
|
}
|
|
16551
16607
|
/**
|
|
@@ -16564,10 +16620,10 @@ function OI() {
|
|
|
16564
16620
|
* See the License for the specific language governing permissions and
|
|
16565
16621
|
* limitations under the License.
|
|
16566
16622
|
*/
|
|
16567
|
-
const
|
|
16623
|
+
const NI = "firebase-installations-database", LI = 1, wa = "firebase-installations-store";
|
|
16568
16624
|
let Of = null;
|
|
16569
16625
|
function Qd() {
|
|
16570
|
-
return Of || (Of = Ql(
|
|
16626
|
+
return Of || (Of = Ql(NI, LI, {
|
|
16571
16627
|
upgrade: (e, t) => {
|
|
16572
16628
|
switch (t) {
|
|
16573
16629
|
case 0:
|
|
@@ -16607,7 +16663,7 @@ async function tc(e, t) {
|
|
|
16607
16663
|
async function eh(e) {
|
|
16608
16664
|
let t;
|
|
16609
16665
|
const r = await tc(e.appConfig, (a) => {
|
|
16610
|
-
const o =
|
|
16666
|
+
const o = $I(a), c = FI(e, o);
|
|
16611
16667
|
return t = c.registrationPromise, c.installationEntry;
|
|
16612
16668
|
});
|
|
16613
16669
|
return r.fid === rd ? { installationEntry: await t } : {
|
|
@@ -16615,15 +16671,15 @@ async function eh(e) {
|
|
|
16615
16671
|
registrationPromise: t
|
|
16616
16672
|
};
|
|
16617
16673
|
}
|
|
16618
|
-
function
|
|
16674
|
+
function $I(e) {
|
|
16619
16675
|
const t = e || {
|
|
16620
|
-
fid:
|
|
16676
|
+
fid: AI(),
|
|
16621
16677
|
registrationStatus: 0
|
|
16622
16678
|
/* RequestStatus.NOT_STARTED */
|
|
16623
16679
|
};
|
|
16624
16680
|
return py(t);
|
|
16625
16681
|
}
|
|
16626
|
-
function
|
|
16682
|
+
function FI(e, t) {
|
|
16627
16683
|
if (t.registrationStatus === 0) {
|
|
16628
16684
|
if (!navigator.onLine) {
|
|
16629
16685
|
const o = Promise.reject(_a.create(
|
|
@@ -16639,17 +16695,17 @@ function NI(e, t) {
|
|
|
16639
16695
|
fid: t.fid,
|
|
16640
16696
|
registrationStatus: 1,
|
|
16641
16697
|
registrationTime: Date.now()
|
|
16642
|
-
}, a =
|
|
16698
|
+
}, a = YI(e, r);
|
|
16643
16699
|
return { installationEntry: r, registrationPromise: a };
|
|
16644
16700
|
} else
|
|
16645
16701
|
return t.registrationStatus === 1 ? {
|
|
16646
16702
|
installationEntry: t,
|
|
16647
|
-
registrationPromise:
|
|
16703
|
+
registrationPromise: BI(e)
|
|
16648
16704
|
} : { installationEntry: t };
|
|
16649
16705
|
}
|
|
16650
|
-
async function
|
|
16706
|
+
async function YI(e, t) {
|
|
16651
16707
|
try {
|
|
16652
|
-
const r = await
|
|
16708
|
+
const r = await TI(e, t);
|
|
16653
16709
|
return il(e.appConfig, r);
|
|
16654
16710
|
} catch (r) {
|
|
16655
16711
|
throw ry(r) && r.customData.serverCode === 409 ? await hy(e.appConfig) : await il(e.appConfig, {
|
|
@@ -16659,17 +16715,17 @@ async function LI(e, t) {
|
|
|
16659
16715
|
}), r;
|
|
16660
16716
|
}
|
|
16661
16717
|
}
|
|
16662
|
-
async function
|
|
16663
|
-
let t = await
|
|
16718
|
+
async function BI(e) {
|
|
16719
|
+
let t = await Vg(e.appConfig);
|
|
16664
16720
|
for (; t.registrationStatus === 1; )
|
|
16665
|
-
await ly(100), t = await
|
|
16721
|
+
await ly(100), t = await Vg(e.appConfig);
|
|
16666
16722
|
if (t.registrationStatus === 0) {
|
|
16667
16723
|
const { installationEntry: r, registrationPromise: a } = await eh(e);
|
|
16668
16724
|
return a || r;
|
|
16669
16725
|
}
|
|
16670
16726
|
return t;
|
|
16671
16727
|
}
|
|
16672
|
-
function
|
|
16728
|
+
function Vg(e) {
|
|
16673
16729
|
return tc(e, (t) => {
|
|
16674
16730
|
if (!t)
|
|
16675
16731
|
throw _a.create(
|
|
@@ -16680,13 +16736,13 @@ function zg(e) {
|
|
|
16680
16736
|
});
|
|
16681
16737
|
}
|
|
16682
16738
|
function py(e) {
|
|
16683
|
-
return
|
|
16739
|
+
return WI(e) ? {
|
|
16684
16740
|
fid: e.fid,
|
|
16685
16741
|
registrationStatus: 0
|
|
16686
16742
|
/* RequestStatus.NOT_STARTED */
|
|
16687
16743
|
} : e;
|
|
16688
16744
|
}
|
|
16689
|
-
function
|
|
16745
|
+
function WI(e) {
|
|
16690
16746
|
return e.registrationStatus === 1 && e.registrationTime + ey < Date.now();
|
|
16691
16747
|
}
|
|
16692
16748
|
/**
|
|
@@ -16705,8 +16761,8 @@ function FI(e) {
|
|
|
16705
16761
|
* See the License for the specific language governing permissions and
|
|
16706
16762
|
* limitations under the License.
|
|
16707
16763
|
*/
|
|
16708
|
-
async function
|
|
16709
|
-
const a =
|
|
16764
|
+
async function jI({ appConfig: e, heartbeatServiceProvider: t }, r) {
|
|
16765
|
+
const a = HI(e, r), o = kI(e, r), c = t.getImmediate({
|
|
16710
16766
|
optional: !0
|
|
16711
16767
|
});
|
|
16712
16768
|
if (c) {
|
|
@@ -16729,7 +16785,7 @@ async function YI({ appConfig: e, heartbeatServiceProvider: t }, r) {
|
|
|
16729
16785
|
} else
|
|
16730
16786
|
throw await sy("Generate Auth Token", S);
|
|
16731
16787
|
}
|
|
16732
|
-
function
|
|
16788
|
+
function HI(e, { fid: t }) {
|
|
16733
16789
|
return `${iy(e)}/${t}/authTokens:generate`;
|
|
16734
16790
|
}
|
|
16735
16791
|
/**
|
|
@@ -16757,30 +16813,30 @@ async function th(e, t = !1) {
|
|
|
16757
16813
|
/* ErrorCode.NOT_REGISTERED */
|
|
16758
16814
|
);
|
|
16759
16815
|
const h = c.authToken;
|
|
16760
|
-
if (!t &&
|
|
16816
|
+
if (!t && zI(h))
|
|
16761
16817
|
return c;
|
|
16762
16818
|
if (h.requestStatus === 1)
|
|
16763
|
-
return r =
|
|
16819
|
+
return r = UI(e, t), c;
|
|
16764
16820
|
{
|
|
16765
16821
|
if (!navigator.onLine)
|
|
16766
16822
|
throw _a.create(
|
|
16767
16823
|
"app-offline"
|
|
16768
16824
|
/* ErrorCode.APP_OFFLINE */
|
|
16769
16825
|
);
|
|
16770
|
-
const b =
|
|
16771
|
-
return r =
|
|
16826
|
+
const b = GI(c);
|
|
16827
|
+
return r = qI(e, b), b;
|
|
16772
16828
|
}
|
|
16773
16829
|
});
|
|
16774
16830
|
return r ? await r : a.authToken;
|
|
16775
16831
|
}
|
|
16776
|
-
async function
|
|
16777
|
-
let r = await
|
|
16832
|
+
async function UI(e, t) {
|
|
16833
|
+
let r = await Gg(e.appConfig);
|
|
16778
16834
|
for (; r.authToken.requestStatus === 1; )
|
|
16779
|
-
await ly(100), r = await
|
|
16835
|
+
await ly(100), r = await Gg(e.appConfig);
|
|
16780
16836
|
const a = r.authToken;
|
|
16781
16837
|
return a.requestStatus === 0 ? th(e, t) : a;
|
|
16782
16838
|
}
|
|
16783
|
-
function
|
|
16839
|
+
function Gg(e) {
|
|
16784
16840
|
return tc(e, (t) => {
|
|
16785
16841
|
if (!gy(t))
|
|
16786
16842
|
throw _a.create(
|
|
@@ -16788,15 +16844,15 @@ function Vg(e) {
|
|
|
16788
16844
|
/* ErrorCode.NOT_REGISTERED */
|
|
16789
16845
|
);
|
|
16790
16846
|
const r = t.authToken;
|
|
16791
|
-
return
|
|
16847
|
+
return KI(r) ? Object.assign(Object.assign({}, t), { authToken: {
|
|
16792
16848
|
requestStatus: 0
|
|
16793
16849
|
/* RequestStatus.NOT_STARTED */
|
|
16794
16850
|
} }) : t;
|
|
16795
16851
|
});
|
|
16796
16852
|
}
|
|
16797
|
-
async function
|
|
16853
|
+
async function qI(e, t) {
|
|
16798
16854
|
try {
|
|
16799
|
-
const r = await
|
|
16855
|
+
const r = await jI(e, t), a = Object.assign(Object.assign({}, t), { authToken: r });
|
|
16800
16856
|
return await il(e.appConfig, a), r;
|
|
16801
16857
|
} catch (r) {
|
|
16802
16858
|
if (ry(r) && (r.customData.serverCode === 401 || r.customData.serverCode === 404))
|
|
@@ -16814,21 +16870,21 @@ async function jI(e, t) {
|
|
|
16814
16870
|
function gy(e) {
|
|
16815
16871
|
return e !== void 0 && e.registrationStatus === 2;
|
|
16816
16872
|
}
|
|
16817
|
-
function
|
|
16818
|
-
return e.requestStatus === 2 && !
|
|
16873
|
+
function zI(e) {
|
|
16874
|
+
return e.requestStatus === 2 && !VI(e);
|
|
16819
16875
|
}
|
|
16820
|
-
function
|
|
16876
|
+
function VI(e) {
|
|
16821
16877
|
const t = Date.now();
|
|
16822
|
-
return t < e.creationTime || e.creationTime + e.expiresIn < t +
|
|
16878
|
+
return t < e.creationTime || e.creationTime + e.expiresIn < t + _I;
|
|
16823
16879
|
}
|
|
16824
|
-
function
|
|
16880
|
+
function GI(e) {
|
|
16825
16881
|
const t = {
|
|
16826
16882
|
requestStatus: 1,
|
|
16827
16883
|
requestTime: Date.now()
|
|
16828
16884
|
};
|
|
16829
16885
|
return Object.assign(Object.assign({}, e), { authToken: t });
|
|
16830
16886
|
}
|
|
16831
|
-
function
|
|
16887
|
+
function KI(e) {
|
|
16832
16888
|
return e.requestStatus === 1 && e.requestTime + ey < Date.now();
|
|
16833
16889
|
}
|
|
16834
16890
|
/**
|
|
@@ -16847,7 +16903,7 @@ function zI(e) {
|
|
|
16847
16903
|
* See the License for the specific language governing permissions and
|
|
16848
16904
|
* limitations under the License.
|
|
16849
16905
|
*/
|
|
16850
|
-
async function
|
|
16906
|
+
async function ZI(e) {
|
|
16851
16907
|
const t = e, { installationEntry: r, registrationPromise: a } = await eh(t);
|
|
16852
16908
|
return a ? a.catch(console.error) : th(t).catch(console.error), r.fid;
|
|
16853
16909
|
}
|
|
@@ -16867,11 +16923,11 @@ async function VI(e) {
|
|
|
16867
16923
|
* See the License for the specific language governing permissions and
|
|
16868
16924
|
* limitations under the License.
|
|
16869
16925
|
*/
|
|
16870
|
-
async function
|
|
16926
|
+
async function XI(e, t = !1) {
|
|
16871
16927
|
const r = e;
|
|
16872
|
-
return await
|
|
16928
|
+
return await JI(r), (await th(r, t)).token;
|
|
16873
16929
|
}
|
|
16874
|
-
async function
|
|
16930
|
+
async function JI(e) {
|
|
16875
16931
|
const { registrationPromise: t } = await eh(e);
|
|
16876
16932
|
t && await t;
|
|
16877
16933
|
}
|
|
@@ -16891,7 +16947,7 @@ async function KI(e) {
|
|
|
16891
16947
|
* See the License for the specific language governing permissions and
|
|
16892
16948
|
* limitations under the License.
|
|
16893
16949
|
*/
|
|
16894
|
-
function
|
|
16950
|
+
function QI(e) {
|
|
16895
16951
|
if (!e || !e.options)
|
|
16896
16952
|
throw If("App Configuration");
|
|
16897
16953
|
if (!e.name)
|
|
@@ -16932,35 +16988,35 @@ function If(e) {
|
|
|
16932
16988
|
* See the License for the specific language governing permissions and
|
|
16933
16989
|
* limitations under the License.
|
|
16934
16990
|
*/
|
|
16935
|
-
const my = "installations",
|
|
16936
|
-
const t = e.getProvider("app").getImmediate(), r =
|
|
16991
|
+
const my = "installations", eR = "installations-internal", tR = (e) => {
|
|
16992
|
+
const t = e.getProvider("app").getImmediate(), r = QI(t), a = Zd(t, "heartbeat");
|
|
16937
16993
|
return {
|
|
16938
16994
|
app: t,
|
|
16939
16995
|
appConfig: r,
|
|
16940
16996
|
heartbeatServiceProvider: a,
|
|
16941
16997
|
_delete: () => Promise.resolve()
|
|
16942
16998
|
};
|
|
16943
|
-
},
|
|
16999
|
+
}, nR = (e) => {
|
|
16944
17000
|
const t = e.getProvider("app").getImmediate(), r = Zd(t, my).getImmediate();
|
|
16945
17001
|
return {
|
|
16946
|
-
getId: () =>
|
|
16947
|
-
getToken: (o) =>
|
|
17002
|
+
getId: () => ZI(r),
|
|
17003
|
+
getToken: (o) => XI(r, o)
|
|
16948
17004
|
};
|
|
16949
17005
|
};
|
|
16950
|
-
function
|
|
17006
|
+
function rR() {
|
|
16951
17007
|
ba(new qi(
|
|
16952
17008
|
my,
|
|
16953
|
-
|
|
17009
|
+
tR,
|
|
16954
17010
|
"PUBLIC"
|
|
16955
17011
|
/* ComponentType.PUBLIC */
|
|
16956
17012
|
)), ba(new qi(
|
|
16957
|
-
|
|
16958
|
-
|
|
17013
|
+
eR,
|
|
17014
|
+
nR,
|
|
16959
17015
|
"PRIVATE"
|
|
16960
17016
|
/* ComponentType.PRIVATE */
|
|
16961
17017
|
));
|
|
16962
17018
|
}
|
|
16963
|
-
|
|
17019
|
+
rR();
|
|
16964
17020
|
Ui(Q0, Jd);
|
|
16965
17021
|
Ui(Q0, Jd, "esm2017");
|
|
16966
17022
|
/**
|
|
@@ -16979,11 +17035,11 @@ Ui(Q0, Jd, "esm2017");
|
|
|
16979
17035
|
* See the License for the specific language governing permissions and
|
|
16980
17036
|
* limitations under the License.
|
|
16981
17037
|
*/
|
|
16982
|
-
const
|
|
16983
|
-
var
|
|
17038
|
+
const iR = "/firebase-messaging-sw.js", aR = "/firebase-cloud-messaging-push-scope", yy = "BDOU99-h67HcA6JeFXHbSNMu7e2yNNu3RzoMj8TM4W88jITfq7ZmPvIM1Iv-4_l2LxQcYwhqby2xGpWwzjfAnG4", sR = "https://fcmregistrations.googleapis.com/v1", vy = "google.c.a.c_id", oR = "google.c.a.c_l", uR = "google.c.a.ts", lR = "google.c.a.e";
|
|
17039
|
+
var Kg;
|
|
16984
17040
|
(function(e) {
|
|
16985
17041
|
e[e.DATA_MESSAGE = 1] = "DATA_MESSAGE", e[e.DISPLAY_NOTIFICATION = 3] = "DISPLAY_NOTIFICATION";
|
|
16986
|
-
})(
|
|
17042
|
+
})(Kg || (Kg = {}));
|
|
16987
17043
|
/**
|
|
16988
17044
|
* @license
|
|
16989
17045
|
* Copyright 2018 Google LLC
|
|
@@ -17022,7 +17078,7 @@ function fi(e) {
|
|
|
17022
17078
|
const t = new Uint8Array(e);
|
|
17023
17079
|
return btoa(String.fromCharCode(...t)).replace(/=/g, "").replace(/\+/g, "-").replace(/\//g, "_");
|
|
17024
17080
|
}
|
|
17025
|
-
function
|
|
17081
|
+
function cR(e) {
|
|
17026
17082
|
const t = "=".repeat((4 - e.length % 4) % 4), r = (e + t).replace(/\-/g, "+").replace(/_/g, "/"), a = atob(r), o = new Uint8Array(a.length);
|
|
17027
17083
|
for (let c = 0; c < a.length; ++c)
|
|
17028
17084
|
o[c] = a.charCodeAt(c);
|
|
@@ -17044,17 +17100,17 @@ function oR(e) {
|
|
|
17044
17100
|
* See the License for the specific language governing permissions and
|
|
17045
17101
|
* limitations under the License.
|
|
17046
17102
|
*/
|
|
17047
|
-
const Rf = "fcm_token_details_db",
|
|
17048
|
-
async function
|
|
17103
|
+
const Rf = "fcm_token_details_db", fR = 5, Zg = "fcm_token_object_Store";
|
|
17104
|
+
async function dR(e) {
|
|
17049
17105
|
if ("databases" in indexedDB && !(await indexedDB.databases()).map((c) => c.name).includes(Rf))
|
|
17050
17106
|
return null;
|
|
17051
17107
|
let t = null;
|
|
17052
|
-
return (await Ql(Rf,
|
|
17108
|
+
return (await Ql(Rf, fR, {
|
|
17053
17109
|
upgrade: async (a, o, c, h) => {
|
|
17054
17110
|
var b;
|
|
17055
|
-
if (o < 2 || !a.objectStoreNames.contains(
|
|
17111
|
+
if (o < 2 || !a.objectStoreNames.contains(Zg))
|
|
17056
17112
|
return;
|
|
17057
|
-
const S = h.objectStore(
|
|
17113
|
+
const S = h.objectStore(Zg), D = await S.index("fcmSenderId").get(e);
|
|
17058
17114
|
if (await S.clear(), !!D) {
|
|
17059
17115
|
if (o === 2) {
|
|
17060
17116
|
const A = D;
|
|
@@ -17100,9 +17156,9 @@ async function lR(e) {
|
|
|
17100
17156
|
}
|
|
17101
17157
|
}
|
|
17102
17158
|
}
|
|
17103
|
-
})).close(), await Mf(Rf), await Mf("fcm_vapid_details_db"), await Mf("undefined"),
|
|
17159
|
+
})).close(), await Mf(Rf), await Mf("fcm_vapid_details_db"), await Mf("undefined"), hR(t) ? t : null;
|
|
17104
17160
|
}
|
|
17105
|
-
function
|
|
17161
|
+
function hR(e) {
|
|
17106
17162
|
if (!e || !e.subscriptionOptions)
|
|
17107
17163
|
return !1;
|
|
17108
17164
|
const { subscriptionOptions: t } = e;
|
|
@@ -17124,10 +17180,10 @@ function cR(e) {
|
|
|
17124
17180
|
* See the License for the specific language governing permissions and
|
|
17125
17181
|
* limitations under the License.
|
|
17126
17182
|
*/
|
|
17127
|
-
const
|
|
17183
|
+
const pR = "firebase-messaging-database", gR = 1, xa = "firebase-messaging-store";
|
|
17128
17184
|
let Pf = null;
|
|
17129
17185
|
function nh() {
|
|
17130
|
-
return Pf || (Pf = Ql(
|
|
17186
|
+
return Pf || (Pf = Ql(pR, gR, {
|
|
17131
17187
|
upgrade: (e, t) => {
|
|
17132
17188
|
switch (t) {
|
|
17133
17189
|
case 0:
|
|
@@ -17141,7 +17197,7 @@ async function by(e) {
|
|
|
17141
17197
|
if (a)
|
|
17142
17198
|
return a;
|
|
17143
17199
|
{
|
|
17144
|
-
const o = await
|
|
17200
|
+
const o = await dR(e.appConfig.senderId);
|
|
17145
17201
|
if (o)
|
|
17146
17202
|
return await rh(e, o), o;
|
|
17147
17203
|
}
|
|
@@ -17150,7 +17206,7 @@ async function rh(e, t) {
|
|
|
17150
17206
|
const r = ih(e), o = (await nh()).transaction(xa, "readwrite");
|
|
17151
17207
|
return await o.objectStore(xa).put(t, r), await o.done, t;
|
|
17152
17208
|
}
|
|
17153
|
-
async function
|
|
17209
|
+
async function mR(e) {
|
|
17154
17210
|
const t = ih(e), a = (await nh()).transaction(xa, "readwrite");
|
|
17155
17211
|
await a.objectStore(xa).delete(t), await a.done;
|
|
17156
17212
|
}
|
|
@@ -17173,7 +17229,7 @@ function ih({ appConfig: e }) {
|
|
|
17173
17229
|
* See the License for the specific language governing permissions and
|
|
17174
17230
|
* limitations under the License.
|
|
17175
17231
|
*/
|
|
17176
|
-
const
|
|
17232
|
+
const yR = {
|
|
17177
17233
|
"missing-app-config-values": 'Missing App configuration value: "{$valueName}"',
|
|
17178
17234
|
"only-available-in-window": "This method is available in a Window context.",
|
|
17179
17235
|
"only-available-in-sw": "This method is available in a service worker context.",
|
|
@@ -17192,7 +17248,7 @@ const pR = {
|
|
|
17192
17248
|
"invalid-bg-handler": "The input to setBackgroundMessageHandler() must be a function.",
|
|
17193
17249
|
"invalid-vapid-key": "The public VAPID key must be a string.",
|
|
17194
17250
|
"use-vapid-key-after-get-token": "The usePublicVapidKey() method may only be called once and must be called before calling getToken() to ensure your VAPID key is used."
|
|
17195
|
-
}, rn = new Jl("messaging", "Messaging",
|
|
17251
|
+
}, rn = new Jl("messaging", "Messaging", yR);
|
|
17196
17252
|
/**
|
|
17197
17253
|
* @license
|
|
17198
17254
|
* Copyright 2019 Google LLC
|
|
@@ -17209,7 +17265,7 @@ const pR = {
|
|
|
17209
17265
|
* See the License for the specific language governing permissions and
|
|
17210
17266
|
* limitations under the License.
|
|
17211
17267
|
*/
|
|
17212
|
-
async function
|
|
17268
|
+
async function vR(e, t) {
|
|
17213
17269
|
const r = await sh(e), a = wy(t), o = {
|
|
17214
17270
|
method: "POST",
|
|
17215
17271
|
headers: r,
|
|
@@ -17236,7 +17292,7 @@ async function gR(e, t) {
|
|
|
17236
17292
|
);
|
|
17237
17293
|
return c.token;
|
|
17238
17294
|
}
|
|
17239
|
-
async function
|
|
17295
|
+
async function bR(e, t) {
|
|
17240
17296
|
const r = await sh(e), a = wy(t.subscriptionOptions), o = {
|
|
17241
17297
|
method: "PATCH",
|
|
17242
17298
|
headers: r,
|
|
@@ -17283,7 +17339,7 @@ async function _y(e, t) {
|
|
|
17283
17339
|
}
|
|
17284
17340
|
}
|
|
17285
17341
|
function ah({ projectId: e }) {
|
|
17286
|
-
return `${
|
|
17342
|
+
return `${sR}/projects/${e}/registrations`;
|
|
17287
17343
|
}
|
|
17288
17344
|
async function sh({ appConfig: e, installations: t }) {
|
|
17289
17345
|
const r = await t.getToken();
|
|
@@ -17320,9 +17376,9 @@ function wy({ p256dh: e, auth: t, endpoint: r, vapidKey: a }) {
|
|
|
17320
17376
|
* See the License for the specific language governing permissions and
|
|
17321
17377
|
* limitations under the License.
|
|
17322
17378
|
*/
|
|
17323
|
-
const
|
|
17324
|
-
async function
|
|
17325
|
-
const t = await
|
|
17379
|
+
const _R = 7 * 24 * 60 * 60 * 1e3;
|
|
17380
|
+
async function wR(e) {
|
|
17381
|
+
const t = await kR(e.swRegistration, e.vapidKey), r = {
|
|
17326
17382
|
vapidKey: e.vapidKey,
|
|
17327
17383
|
swScope: e.swRegistration.scope,
|
|
17328
17384
|
endpoint: t.endpoint,
|
|
@@ -17330,8 +17386,8 @@ async function vR(e) {
|
|
|
17330
17386
|
p256dh: fi(t.getKey("p256dh"))
|
|
17331
17387
|
}, a = await by(e.firebaseDependencies);
|
|
17332
17388
|
if (a) {
|
|
17333
|
-
if (
|
|
17334
|
-
return Date.now() >= a.createTime +
|
|
17389
|
+
if (CR(a.subscriptionOptions, r))
|
|
17390
|
+
return Date.now() >= a.createTime + _R ? SR(e, {
|
|
17335
17391
|
token: a.token,
|
|
17336
17392
|
createTime: Date.now(),
|
|
17337
17393
|
subscriptionOptions: r
|
|
@@ -17341,42 +17397,42 @@ async function vR(e) {
|
|
|
17341
17397
|
} catch (o) {
|
|
17342
17398
|
console.warn(o);
|
|
17343
17399
|
}
|
|
17344
|
-
return
|
|
17400
|
+
return Xg(e.firebaseDependencies, r);
|
|
17345
17401
|
} else
|
|
17346
|
-
return
|
|
17402
|
+
return Xg(e.firebaseDependencies, r);
|
|
17347
17403
|
}
|
|
17348
|
-
async function
|
|
17404
|
+
async function xR(e) {
|
|
17349
17405
|
const t = await by(e.firebaseDependencies);
|
|
17350
|
-
t && (await _y(e.firebaseDependencies, t.token), await
|
|
17406
|
+
t && (await _y(e.firebaseDependencies, t.token), await mR(e.firebaseDependencies));
|
|
17351
17407
|
const r = await e.swRegistration.pushManager.getSubscription();
|
|
17352
17408
|
return r ? r.unsubscribe() : !0;
|
|
17353
17409
|
}
|
|
17354
|
-
async function
|
|
17410
|
+
async function SR(e, t) {
|
|
17355
17411
|
try {
|
|
17356
|
-
const r = await
|
|
17412
|
+
const r = await bR(e.firebaseDependencies, t), a = Object.assign(Object.assign({}, t), { token: r, createTime: Date.now() });
|
|
17357
17413
|
return await rh(e.firebaseDependencies, a), r;
|
|
17358
17414
|
} catch (r) {
|
|
17359
|
-
throw await
|
|
17415
|
+
throw await xR(e), r;
|
|
17360
17416
|
}
|
|
17361
17417
|
}
|
|
17362
|
-
async function
|
|
17418
|
+
async function Xg(e, t) {
|
|
17363
17419
|
const a = {
|
|
17364
|
-
token: await
|
|
17420
|
+
token: await vR(e, t),
|
|
17365
17421
|
createTime: Date.now(),
|
|
17366
17422
|
subscriptionOptions: t
|
|
17367
17423
|
};
|
|
17368
17424
|
return await rh(e, a), a.token;
|
|
17369
17425
|
}
|
|
17370
|
-
async function
|
|
17426
|
+
async function kR(e, t) {
|
|
17371
17427
|
const r = await e.pushManager.getSubscription();
|
|
17372
17428
|
return r || e.pushManager.subscribe({
|
|
17373
17429
|
userVisibleOnly: !0,
|
|
17374
17430
|
// Chrome <= 75 doesn't support base64-encoded VAPID key. For backward compatibility, VAPID key
|
|
17375
17431
|
// submitted to pushManager#subscribe must be of type Uint8Array.
|
|
17376
|
-
applicationServerKey:
|
|
17432
|
+
applicationServerKey: cR(t)
|
|
17377
17433
|
});
|
|
17378
17434
|
}
|
|
17379
|
-
function
|
|
17435
|
+
function CR(e, t) {
|
|
17380
17436
|
const r = t.vapidKey === e.vapidKey, a = t.endpoint === e.endpoint, o = t.auth === e.auth, c = t.p256dh === e.p256dh;
|
|
17381
17437
|
return r && a && o && c;
|
|
17382
17438
|
}
|
|
@@ -17396,7 +17452,7 @@ function xR(e, t) {
|
|
|
17396
17452
|
* See the License for the specific language governing permissions and
|
|
17397
17453
|
* limitations under the License.
|
|
17398
17454
|
*/
|
|
17399
|
-
function
|
|
17455
|
+
function Jg(e) {
|
|
17400
17456
|
const t = {
|
|
17401
17457
|
from: e.from,
|
|
17402
17458
|
// eslint-disable-next-line camelcase
|
|
@@ -17404,9 +17460,9 @@ function Xg(e) {
|
|
|
17404
17460
|
// eslint-disable-next-line camelcase
|
|
17405
17461
|
messageId: e.fcmMessageId
|
|
17406
17462
|
};
|
|
17407
|
-
return
|
|
17463
|
+
return DR(t, e), TR(t, e), MR(t, e), t;
|
|
17408
17464
|
}
|
|
17409
|
-
function
|
|
17465
|
+
function DR(e, t) {
|
|
17410
17466
|
if (!t.notification)
|
|
17411
17467
|
return;
|
|
17412
17468
|
e.notification = {};
|
|
@@ -17419,10 +17475,10 @@ function SR(e, t) {
|
|
|
17419
17475
|
const c = t.notification.icon;
|
|
17420
17476
|
c && (e.notification.icon = c);
|
|
17421
17477
|
}
|
|
17422
|
-
function
|
|
17478
|
+
function TR(e, t) {
|
|
17423
17479
|
t.data && (e.data = t.data);
|
|
17424
17480
|
}
|
|
17425
|
-
function
|
|
17481
|
+
function MR(e, t) {
|
|
17426
17482
|
var r, a, o, c, h;
|
|
17427
17483
|
if (!t.fcmOptions && !(!((r = t.notification) === null || r === void 0) && r.click_action))
|
|
17428
17484
|
return;
|
|
@@ -17448,7 +17504,7 @@ function CR(e, t) {
|
|
|
17448
17504
|
* See the License for the specific language governing permissions and
|
|
17449
17505
|
* limitations under the License.
|
|
17450
17506
|
*/
|
|
17451
|
-
function
|
|
17507
|
+
function ER(e) {
|
|
17452
17508
|
return typeof e == "object" && !!e && vy in e;
|
|
17453
17509
|
}
|
|
17454
17510
|
/**
|
|
@@ -17491,7 +17547,7 @@ function xy(e, t) {
|
|
|
17491
17547
|
* See the License for the specific language governing permissions and
|
|
17492
17548
|
* limitations under the License.
|
|
17493
17549
|
*/
|
|
17494
|
-
function
|
|
17550
|
+
function AR(e) {
|
|
17495
17551
|
if (!e || !e.options)
|
|
17496
17552
|
throw Nf("App Configuration Object");
|
|
17497
17553
|
if (!e.name)
|
|
@@ -17534,10 +17590,10 @@ function Nf(e) {
|
|
|
17534
17590
|
* See the License for the specific language governing permissions and
|
|
17535
17591
|
* limitations under the License.
|
|
17536
17592
|
*/
|
|
17537
|
-
class
|
|
17593
|
+
class OR {
|
|
17538
17594
|
constructor(t, r, a) {
|
|
17539
17595
|
this.deliveryMetricsExportedToBigQueryEnabled = !1, this.onBackgroundMessageHandler = null, this.onMessageHandler = null, this.logEvents = [], this.isLogServiceStarted = !1;
|
|
17540
|
-
const o =
|
|
17596
|
+
const o = AR(t);
|
|
17541
17597
|
this.firebaseDependencies = {
|
|
17542
17598
|
app: t,
|
|
17543
17599
|
appConfig: o,
|
|
@@ -17565,10 +17621,10 @@ class MR {
|
|
|
17565
17621
|
* See the License for the specific language governing permissions and
|
|
17566
17622
|
* limitations under the License.
|
|
17567
17623
|
*/
|
|
17568
|
-
async function
|
|
17624
|
+
async function IR(e) {
|
|
17569
17625
|
try {
|
|
17570
|
-
e.swRegistration = await navigator.serviceWorker.register(
|
|
17571
|
-
scope:
|
|
17626
|
+
e.swRegistration = await navigator.serviceWorker.register(iR, {
|
|
17627
|
+
scope: aR
|
|
17572
17628
|
}), e.swRegistration.update().catch(() => {
|
|
17573
17629
|
});
|
|
17574
17630
|
} catch (t) {
|
|
@@ -17593,8 +17649,8 @@ async function ER(e) {
|
|
|
17593
17649
|
* See the License for the specific language governing permissions and
|
|
17594
17650
|
* limitations under the License.
|
|
17595
17651
|
*/
|
|
17596
|
-
async function
|
|
17597
|
-
if (!t && !e.swRegistration && await
|
|
17652
|
+
async function RR(e, t) {
|
|
17653
|
+
if (!t && !e.swRegistration && await IR(e), !(!t && e.swRegistration)) {
|
|
17598
17654
|
if (!(t instanceof ServiceWorkerRegistration))
|
|
17599
17655
|
throw rn.create(
|
|
17600
17656
|
"invalid-sw-registration"
|
|
@@ -17619,7 +17675,7 @@ async function AR(e, t) {
|
|
|
17619
17675
|
* See the License for the specific language governing permissions and
|
|
17620
17676
|
* limitations under the License.
|
|
17621
17677
|
*/
|
|
17622
|
-
async function
|
|
17678
|
+
async function PR(e, t) {
|
|
17623
17679
|
t ? e.vapidKey = t : e.vapidKey || (e.vapidKey = yy);
|
|
17624
17680
|
}
|
|
17625
17681
|
/**
|
|
@@ -17649,7 +17705,7 @@ async function Sy(e, t) {
|
|
|
17649
17705
|
"permission-blocked"
|
|
17650
17706
|
/* ErrorCode.PERMISSION_BLOCKED */
|
|
17651
17707
|
);
|
|
17652
|
-
return await
|
|
17708
|
+
return await PR(e, t == null ? void 0 : t.vapidKey), await RR(e, t == null ? void 0 : t.serviceWorkerRegistration), wR(e);
|
|
17653
17709
|
}
|
|
17654
17710
|
/**
|
|
17655
17711
|
* @license
|
|
@@ -17667,18 +17723,18 @@ async function Sy(e, t) {
|
|
|
17667
17723
|
* See the License for the specific language governing permissions and
|
|
17668
17724
|
* limitations under the License.
|
|
17669
17725
|
*/
|
|
17670
|
-
async function
|
|
17671
|
-
const a =
|
|
17726
|
+
async function NR(e, t, r) {
|
|
17727
|
+
const a = LR(t);
|
|
17672
17728
|
(await e.firebaseDependencies.analyticsProvider.get()).logEvent(a, {
|
|
17673
17729
|
/* eslint-disable camelcase */
|
|
17674
17730
|
message_id: r[vy],
|
|
17675
|
-
message_name: r[
|
|
17676
|
-
message_time: r[
|
|
17731
|
+
message_name: r[oR],
|
|
17732
|
+
message_time: r[uR],
|
|
17677
17733
|
message_device_time: Math.floor(Date.now() / 1e3)
|
|
17678
17734
|
/* eslint-enable camelcase */
|
|
17679
17735
|
});
|
|
17680
17736
|
}
|
|
17681
|
-
function
|
|
17737
|
+
function LR(e) {
|
|
17682
17738
|
switch (e) {
|
|
17683
17739
|
case fo.NOTIFICATION_CLICKED:
|
|
17684
17740
|
return "notification_open";
|
|
@@ -17704,15 +17760,15 @@ function RR(e) {
|
|
|
17704
17760
|
* See the License for the specific language governing permissions and
|
|
17705
17761
|
* limitations under the License.
|
|
17706
17762
|
*/
|
|
17707
|
-
async function
|
|
17763
|
+
async function $R(e, t) {
|
|
17708
17764
|
const r = t.data;
|
|
17709
17765
|
if (!r.isFirebaseMessaging)
|
|
17710
17766
|
return;
|
|
17711
|
-
e.onMessageHandler && r.messageType === fo.PUSH_RECEIVED && (typeof e.onMessageHandler == "function" ? e.onMessageHandler(
|
|
17767
|
+
e.onMessageHandler && r.messageType === fo.PUSH_RECEIVED && (typeof e.onMessageHandler == "function" ? e.onMessageHandler(Jg(r)) : e.onMessageHandler.next(Jg(r)));
|
|
17712
17768
|
const a = r.data;
|
|
17713
|
-
|
|
17769
|
+
ER(a) && a[lR] === "1" && await NR(e, r.messageType, a);
|
|
17714
17770
|
}
|
|
17715
|
-
const
|
|
17771
|
+
const Qg = "@firebase/messaging", em = "0.12.6";
|
|
17716
17772
|
/**
|
|
17717
17773
|
* @license
|
|
17718
17774
|
* Copyright 2020 Google LLC
|
|
@@ -17729,27 +17785,27 @@ const Jg = "@firebase/messaging", Qg = "0.12.6";
|
|
|
17729
17785
|
* See the License for the specific language governing permissions and
|
|
17730
17786
|
* limitations under the License.
|
|
17731
17787
|
*/
|
|
17732
|
-
const
|
|
17733
|
-
const t = new
|
|
17734
|
-
return navigator.serviceWorker.addEventListener("message", (r) =>
|
|
17735
|
-
},
|
|
17788
|
+
const FR = (e) => {
|
|
17789
|
+
const t = new OR(e.getProvider("app").getImmediate(), e.getProvider("installations-internal").getImmediate(), e.getProvider("analytics-internal"));
|
|
17790
|
+
return navigator.serviceWorker.addEventListener("message", (r) => $R(t, r)), t;
|
|
17791
|
+
}, YR = (e) => {
|
|
17736
17792
|
const t = e.getProvider("messaging").getImmediate();
|
|
17737
17793
|
return {
|
|
17738
17794
|
getToken: (a) => Sy(t, a)
|
|
17739
17795
|
};
|
|
17740
17796
|
};
|
|
17741
|
-
function
|
|
17797
|
+
function BR() {
|
|
17742
17798
|
ba(new qi(
|
|
17743
17799
|
"messaging",
|
|
17744
|
-
|
|
17800
|
+
FR,
|
|
17745
17801
|
"PUBLIC"
|
|
17746
17802
|
/* ComponentType.PUBLIC */
|
|
17747
17803
|
)), ba(new qi(
|
|
17748
17804
|
"messaging-internal",
|
|
17749
|
-
|
|
17805
|
+
YR,
|
|
17750
17806
|
"PRIVATE"
|
|
17751
17807
|
/* ComponentType.PRIVATE */
|
|
17752
|
-
)), Ui(
|
|
17808
|
+
)), Ui(Qg, em), Ui(Qg, em, "esm2017");
|
|
17753
17809
|
}
|
|
17754
17810
|
/**
|
|
17755
17811
|
* @license
|
|
@@ -17767,13 +17823,13 @@ function $R() {
|
|
|
17767
17823
|
* See the License for the specific language governing permissions and
|
|
17768
17824
|
* limitations under the License.
|
|
17769
17825
|
*/
|
|
17770
|
-
async function
|
|
17826
|
+
async function WR() {
|
|
17771
17827
|
try {
|
|
17772
17828
|
await G0();
|
|
17773
17829
|
} catch {
|
|
17774
17830
|
return !1;
|
|
17775
17831
|
}
|
|
17776
|
-
return typeof window < "u" && V0() &&
|
|
17832
|
+
return typeof window < "u" && V0() && uO() && "serviceWorker" in navigator && "PushManager" in window && "Notification" in window && "fetch" in window && ServiceWorkerRegistration.prototype.hasOwnProperty("showNotification") && PushSubscription.prototype.hasOwnProperty("getKey");
|
|
17777
17833
|
}
|
|
17778
17834
|
/**
|
|
17779
17835
|
* @license
|
|
@@ -17791,7 +17847,7 @@ async function FR() {
|
|
|
17791
17847
|
* See the License for the specific language governing permissions and
|
|
17792
17848
|
* limitations under the License.
|
|
17793
17849
|
*/
|
|
17794
|
-
function
|
|
17850
|
+
function jR(e, t) {
|
|
17795
17851
|
if (!navigator)
|
|
17796
17852
|
throw rn.create(
|
|
17797
17853
|
"only-available-in-window"
|
|
@@ -17817,8 +17873,8 @@ function YR(e, t) {
|
|
|
17817
17873
|
* See the License for the specific language governing permissions and
|
|
17818
17874
|
* limitations under the License.
|
|
17819
17875
|
*/
|
|
17820
|
-
function ky(e =
|
|
17821
|
-
return
|
|
17876
|
+
function ky(e = oI()) {
|
|
17877
|
+
return WR().then((t) => {
|
|
17822
17878
|
if (!t)
|
|
17823
17879
|
throw rn.create(
|
|
17824
17880
|
"unsupported-browser"
|
|
@@ -17831,13 +17887,13 @@ function ky(e = iI()) {
|
|
|
17831
17887
|
);
|
|
17832
17888
|
}), Zd(Gd(e), "messaging").getImmediate();
|
|
17833
17889
|
}
|
|
17834
|
-
async function
|
|
17890
|
+
async function HR(e, t) {
|
|
17835
17891
|
return e = Gd(e), Sy(e, t);
|
|
17836
17892
|
}
|
|
17837
|
-
function
|
|
17838
|
-
return e = Gd(e),
|
|
17893
|
+
function UR(e, t) {
|
|
17894
|
+
return e = Gd(e), jR(e, t);
|
|
17839
17895
|
}
|
|
17840
|
-
|
|
17896
|
+
BR();
|
|
17841
17897
|
const Cy = (e) => {
|
|
17842
17898
|
"serviceWorker" in navigator && navigator.serviceWorker.register(e.path).then(function(t) {
|
|
17843
17899
|
console.log("Registration successful, scope is:", t.scope), console.log("initialize service worker props ", e);
|
|
@@ -17852,7 +17908,7 @@ const Cy = (e) => {
|
|
|
17852
17908
|
measurementId: e.measurementId
|
|
17853
17909
|
})
|
|
17854
17910
|
);
|
|
17855
|
-
|
|
17911
|
+
HR(r, {
|
|
17856
17912
|
// add your VPAID key here
|
|
17857
17913
|
serviceWorkerRegistration: t,
|
|
17858
17914
|
vapidKey: e.vapidKey
|
|
@@ -17884,7 +17940,7 @@ const Cy = (e) => {
|
|
|
17884
17940
|
}).catch(function(t) {
|
|
17885
17941
|
console.log("Service worker registration failed, error:", t);
|
|
17886
17942
|
});
|
|
17887
|
-
},
|
|
17943
|
+
}, qR = (e) => {
|
|
17888
17944
|
const t = new BroadcastChannel("my-channel");
|
|
17889
17945
|
t.onmessage = (r) => {
|
|
17890
17946
|
console.log("Broadcast chanel message", r), r && e((a) => ({
|
|
@@ -17895,7 +17951,7 @@ const Cy = (e) => {
|
|
|
17895
17951
|
}
|
|
17896
17952
|
}));
|
|
17897
17953
|
};
|
|
17898
|
-
},
|
|
17954
|
+
}, zR = (e) => new Promise((t) => {
|
|
17899
17955
|
const r = ky(
|
|
17900
17956
|
Xd({
|
|
17901
17957
|
apiKey: e.apiKey,
|
|
@@ -17907,7 +17963,7 @@ const Cy = (e) => {
|
|
|
17907
17963
|
measurementId: e.measurementId
|
|
17908
17964
|
})
|
|
17909
17965
|
);
|
|
17910
|
-
|
|
17966
|
+
UR(r, (a) => {
|
|
17911
17967
|
console.log("payload", a), t(a);
|
|
17912
17968
|
});
|
|
17913
17969
|
}), fa = {
|
|
@@ -17918,10 +17974,10 @@ const Cy = (e) => {
|
|
|
17918
17974
|
"subscription-btn__container": "_subscription-btn__container_1gvmm_38",
|
|
17919
17975
|
"btn-success": "_btn-success_1gvmm_44",
|
|
17920
17976
|
"btn-cancel": "_btn-cancel_1gvmm_45"
|
|
17921
|
-
},
|
|
17977
|
+
}, VR = ["granted", "denied"], GR = (e) => {
|
|
17922
17978
|
const [t, r] = ee.useState(!1), a = () => {
|
|
17923
17979
|
Notification.requestPermission(function(c) {
|
|
17924
|
-
c === "granted" && Cy(e),
|
|
17980
|
+
c === "granted" && Cy(e), VR.includes(c) && r(!0);
|
|
17925
17981
|
});
|
|
17926
17982
|
}, o = () => {
|
|
17927
17983
|
r(!0);
|
|
@@ -17946,7 +18002,7 @@ const Cy = (e) => {
|
|
|
17946
18002
|
"notification-name": "_notification-name_ql4az_18",
|
|
17947
18003
|
"notification-message_service": "_notification-message_service_ql4az_23",
|
|
17948
18004
|
"notification-message_button-close": "_notification-message_button-close_ql4az_27"
|
|
17949
|
-
}, zi = ee.createContext({}),
|
|
18005
|
+
}, zi = ee.createContext({}), KR = ({ children: e }) => {
|
|
17950
18006
|
const [t, r] = ee.useState(!0), [a, o] = ee.useState({
|
|
17951
18007
|
all: { rows: [], total: 0 },
|
|
17952
18008
|
unread: { rows: [], total: 0 }
|
|
@@ -17968,7 +18024,7 @@ const Cy = (e) => {
|
|
|
17968
18024
|
children: e
|
|
17969
18025
|
}
|
|
17970
18026
|
);
|
|
17971
|
-
},
|
|
18027
|
+
}, ZR = (e) => {
|
|
17972
18028
|
const [t, r] = ee.useState({
|
|
17973
18029
|
userName: "",
|
|
17974
18030
|
message: "",
|
|
@@ -17993,8 +18049,8 @@ const Cy = (e) => {
|
|
|
17993
18049
|
}, [t]), ee.useEffect(() => {
|
|
17994
18050
|
Notification.permission === "granted" && Cy(e);
|
|
17995
18051
|
}, [Notification.permission]), ee.useEffect(() => {
|
|
17996
|
-
|
|
17997
|
-
}, []),
|
|
18052
|
+
qR(a);
|
|
18053
|
+
}, []), zR(e).then((c) => {
|
|
17998
18054
|
var h, b, S;
|
|
17999
18055
|
console.log("aaa", c), r({
|
|
18000
18056
|
userName: (h = c == null ? void 0 : c.data) == null ? void 0 : h.userName,
|
|
@@ -18010,9 +18066,9 @@ const Cy = (e) => {
|
|
|
18010
18066
|
}
|
|
18011
18067
|
};
|
|
18012
18068
|
});
|
|
18013
|
-
}).catch((c) => console.log("failed: ", c)), /* @__PURE__ */ z.jsx("div", { children: "Notification" in window && Notification.permission === "default" ? /* @__PURE__ */ z.jsx(
|
|
18069
|
+
}).catch((c) => console.log("failed: ", c)), /* @__PURE__ */ z.jsx("div", { children: "Notification" in window && Notification.permission === "default" ? /* @__PURE__ */ z.jsx(GR, { ...e }) : "" });
|
|
18014
18070
|
};
|
|
18015
|
-
function
|
|
18071
|
+
function XR({
|
|
18016
18072
|
config: e,
|
|
18017
18073
|
pushError: t = po
|
|
18018
18074
|
}) {
|
|
@@ -18035,7 +18091,7 @@ function GR({
|
|
|
18035
18091
|
}
|
|
18036
18092
|
return r;
|
|
18037
18093
|
}
|
|
18038
|
-
const
|
|
18094
|
+
const JR = (e) => {
|
|
18039
18095
|
const [t, r] = ee.useState([]);
|
|
18040
18096
|
return ee.useEffect(() => {
|
|
18041
18097
|
ho.get(`${e}/user-management/api/v1/users/my-account/permissions`, {
|
|
@@ -18044,21 +18100,21 @@ const KR = (e) => {
|
|
|
18044
18100
|
console.error("Getting user permission error:", a);
|
|
18045
18101
|
});
|
|
18046
18102
|
}, [e]), t;
|
|
18047
|
-
},
|
|
18048
|
-
const a =
|
|
18103
|
+
}, QR = (e) => (t, r) => {
|
|
18104
|
+
const a = JR(e);
|
|
18049
18105
|
return r ? t.every(
|
|
18050
18106
|
(o) => a == null ? void 0 : a.includes(o)
|
|
18051
18107
|
) : t.some(
|
|
18052
18108
|
(o) => a == null ? void 0 : a.includes(o)
|
|
18053
18109
|
);
|
|
18054
|
-
},
|
|
18110
|
+
}, eP = ({
|
|
18055
18111
|
baseUrl: e,
|
|
18056
18112
|
accessWith: t,
|
|
18057
18113
|
requireAll: r,
|
|
18058
18114
|
children: a
|
|
18059
|
-
}) =>
|
|
18115
|
+
}) => QR(e)(t, r) ? /* @__PURE__ */ z.jsx(z.Fragment, { children: a }) : null;
|
|
18060
18116
|
{
|
|
18061
|
-
const e = nm(
|
|
18117
|
+
const e = nm(eP, {
|
|
18062
18118
|
props: {
|
|
18063
18119
|
baseUrl: "string",
|
|
18064
18120
|
accessWith: "json",
|
|
@@ -18069,64 +18125,7 @@ const KR = (e) => {
|
|
|
18069
18125
|
});
|
|
18070
18126
|
customElements.define("has-permission", e);
|
|
18071
18127
|
}
|
|
18072
|
-
const
|
|
18073
|
-
function em(e) {
|
|
18074
|
-
Promise.resolve().then(e).catch(function(t) {
|
|
18075
|
-
return setTimeout(function() {
|
|
18076
|
-
throw t;
|
|
18077
|
-
});
|
|
18078
|
-
});
|
|
18079
|
-
}
|
|
18080
|
-
var eP = /* @__PURE__ */ function() {
|
|
18081
|
-
function e() {
|
|
18082
|
-
this.queue = [], this.transactions = 0, this.notifyFn = function(r) {
|
|
18083
|
-
r();
|
|
18084
|
-
}, this.batchNotifyFn = function(r) {
|
|
18085
|
-
r();
|
|
18086
|
-
};
|
|
18087
|
-
}
|
|
18088
|
-
var t = e.prototype;
|
|
18089
|
-
return t.batch = function(a) {
|
|
18090
|
-
var o;
|
|
18091
|
-
this.transactions++;
|
|
18092
|
-
try {
|
|
18093
|
-
o = a();
|
|
18094
|
-
} finally {
|
|
18095
|
-
this.transactions--, this.transactions || this.flush();
|
|
18096
|
-
}
|
|
18097
|
-
return o;
|
|
18098
|
-
}, t.schedule = function(a) {
|
|
18099
|
-
var o = this;
|
|
18100
|
-
this.transactions ? this.queue.push(a) : em(function() {
|
|
18101
|
-
o.notifyFn(a);
|
|
18102
|
-
});
|
|
18103
|
-
}, t.batchCalls = function(a) {
|
|
18104
|
-
var o = this;
|
|
18105
|
-
return function() {
|
|
18106
|
-
for (var c = arguments.length, h = new Array(c), b = 0; b < c; b++)
|
|
18107
|
-
h[b] = arguments[b];
|
|
18108
|
-
o.schedule(function() {
|
|
18109
|
-
a.apply(void 0, h);
|
|
18110
|
-
});
|
|
18111
|
-
};
|
|
18112
|
-
}, t.flush = function() {
|
|
18113
|
-
var a = this, o = this.queue;
|
|
18114
|
-
this.queue = [], o.length && em(function() {
|
|
18115
|
-
a.batchNotifyFn(function() {
|
|
18116
|
-
o.forEach(function(c) {
|
|
18117
|
-
a.notifyFn(c);
|
|
18118
|
-
});
|
|
18119
|
-
});
|
|
18120
|
-
});
|
|
18121
|
-
}, t.setNotifyFunction = function(a) {
|
|
18122
|
-
this.notifyFn = a;
|
|
18123
|
-
}, t.setBatchNotifyFunction = function(a) {
|
|
18124
|
-
this.batchNotifyFn = a;
|
|
18125
|
-
}, e;
|
|
18126
|
-
}(), tP = new eP(), nP = Ix.unstable_batchedUpdates;
|
|
18127
|
-
tP.setBatchNotifyFunction(nP);
|
|
18128
|
-
ee.createContext({});
|
|
18129
|
-
const rP = GR({
|
|
18128
|
+
const tP = ee.createContext({}), nP = () => ee.useContext(tP), rP = XR({
|
|
18130
18129
|
config: {
|
|
18131
18130
|
withCredentials: !0
|
|
18132
18131
|
}
|
|
@@ -18658,9 +18657,9 @@ function hP({
|
|
|
18658
18657
|
children: /* @__PURE__ */ z.jsxs("div", { className: "navbar-container", children: [
|
|
18659
18658
|
/* @__PURE__ */ z.jsx("div", { className: "logo-container", children: /* @__PURE__ */ z.jsx("img", { src: S, alt: "logo-header", style: { height: "40px" } }) }),
|
|
18660
18659
|
/* @__PURE__ */ z.jsxs("div", { className: "right-side-container", children: [
|
|
18661
|
-
/* @__PURE__ */ z.jsx("span", { children: /* @__PURE__ */ z.jsxs(
|
|
18660
|
+
/* @__PURE__ */ z.jsx("span", { children: /* @__PURE__ */ z.jsxs(KR, { children: [
|
|
18662
18661
|
/* @__PURE__ */ z.jsx(
|
|
18663
|
-
|
|
18662
|
+
ZR,
|
|
18664
18663
|
{
|
|
18665
18664
|
baseUrl: b.baseUrl,
|
|
18666
18665
|
path: b.path,
|
|
@@ -18736,7 +18735,7 @@ function pP() {
|
|
|
18736
18735
|
ee.useState(
|
|
18737
18736
|
new Array(e.length).fill(!1)
|
|
18738
18737
|
);
|
|
18739
|
-
const { language: a, setLanguage: o } =
|
|
18738
|
+
const { language: a, setLanguage: o } = nP();
|
|
18740
18739
|
ee.useEffect(() => {
|
|
18741
18740
|
uh({
|
|
18742
18741
|
childrenClass: "languageDropdown",
|
|
@@ -18851,7 +18850,7 @@ function gP({
|
|
|
18851
18850
|
customElements.define("global-topbar", e);
|
|
18852
18851
|
}
|
|
18853
18852
|
export {
|
|
18854
|
-
|
|
18853
|
+
eP as H,
|
|
18855
18854
|
hP as T,
|
|
18856
|
-
|
|
18855
|
+
QR as g
|
|
18857
18856
|
};
|