@blinkk/root-cms 1.0.0-rc.0 → 1.0.0-rc.1

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/ui/signin.js CHANGED
@@ -289,7 +289,7 @@
289
289
  this.__v && (this.__e = true, n2 && this.__h.push(n2), b(this));
290
290
  }, d.prototype.render = p, t = [], g.__r = 0, r = 0;
291
291
 
292
- // ../../node_modules/.pnpm/@tabler+icons-preact@2.17.0_preact@10.11.0/node_modules/@tabler/icons-preact/dist/esm/defaultAttributes.js
292
+ // ../../node_modules/.pnpm/@tabler+icons-preact@2.39.0_preact@10.11.0/node_modules/@tabler/icons-preact/dist/esm/defaultAttributes.js
293
293
  var defaultAttributes = {
294
294
  xmlns: "http://www.w3.org/2000/svg",
295
295
  width: 24,
@@ -302,7 +302,7 @@
302
302
  "stroke-linejoin": "round"
303
303
  };
304
304
 
305
- // ../../node_modules/.pnpm/@tabler+icons-preact@2.17.0_preact@10.11.0/node_modules/@tabler/icons-preact/dist/esm/createPreactComponent.js
305
+ // ../../node_modules/.pnpm/@tabler+icons-preact@2.39.0_preact@10.11.0/node_modules/@tabler/icons-preact/dist/esm/createPreactComponent.js
306
306
  var __defProp = Object.defineProperty;
307
307
  var __defProps = Object.defineProperties;
308
308
  var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
@@ -353,7 +353,7 @@
353
353
  return Component2;
354
354
  };
355
355
 
356
- // ../../node_modules/.pnpm/@tabler+icons-preact@2.17.0_preact@10.11.0/node_modules/@tabler/icons-preact/dist/esm/icons/IconSitemap.js
356
+ // ../../node_modules/.pnpm/@tabler+icons-preact@2.39.0_preact@10.11.0/node_modules/@tabler/icons-preact/dist/esm/icons/IconSitemap.js
357
357
  var IconSitemap = createPreactComponent("sitemap", "IconSitemap", [
358
358
  [
359
359
  "path",
@@ -1437,7 +1437,7 @@
1437
1437
  }
1438
1438
  };
1439
1439
 
1440
- // ../../node_modules/.pnpm/idb@7.0.1/node_modules/idb/build/wrap-idb-value.js
1440
+ // ../../node_modules/.pnpm/idb@7.1.1/node_modules/idb/build/wrap-idb-value.js
1441
1441
  var instanceOfAny = (object, constructors) => constructors.some((c2) => object instanceof c2);
1442
1442
  var idbProxyableTypes;
1443
1443
  var cursorAdvanceMethods;
@@ -1580,22 +1580,29 @@
1580
1580
  }
1581
1581
  var unwrap = (value) => reverseTransformCache.get(value);
1582
1582
 
1583
- // ../../node_modules/.pnpm/idb@7.0.1/node_modules/idb/build/index.js
1583
+ // ../../node_modules/.pnpm/idb@7.1.1/node_modules/idb/build/index.js
1584
1584
  function openDB(name4, version4, { blocked, upgrade, blocking, terminated } = {}) {
1585
1585
  const request = indexedDB.open(name4, version4);
1586
1586
  const openPromise = wrap(request);
1587
1587
  if (upgrade) {
1588
1588
  request.addEventListener("upgradeneeded", (event) => {
1589
- upgrade(wrap(request.result), event.oldVersion, event.newVersion, wrap(request.transaction));
1589
+ upgrade(wrap(request.result), event.oldVersion, event.newVersion, wrap(request.transaction), event);
1590
1590
  });
1591
1591
  }
1592
- if (blocked)
1593
- request.addEventListener("blocked", () => blocked());
1592
+ if (blocked) {
1593
+ request.addEventListener("blocked", (event) => blocked(
1594
+ // Casting due to https://github.com/microsoft/TypeScript-DOM-lib-generator/pull/1405
1595
+ event.oldVersion,
1596
+ event.newVersion,
1597
+ event
1598
+ ));
1599
+ }
1594
1600
  openPromise.then((db) => {
1595
1601
  if (terminated)
1596
1602
  db.addEventListener("close", () => terminated());
1597
- if (blocking)
1598
- db.addEventListener("versionchange", () => blocking());
1603
+ if (blocking) {
1604
+ db.addEventListener("versionchange", (event) => blocking(event.oldVersion, event.newVersion, event));
1605
+ }
1599
1606
  }).catch(() => {
1600
1607
  });
1601
1608
  return openPromise;
@@ -1637,7 +1644,7 @@
1637
1644
  has: (target, prop) => !!getMethod(target, prop) || oldTraps.has(target, prop)
1638
1645
  }));
1639
1646
 
1640
- // ../../node_modules/.pnpm/@firebase+app@0.9.4/node_modules/@firebase/app/dist/esm/index.esm2017.js
1647
+ // ../../node_modules/.pnpm/@firebase+app@0.9.19/node_modules/@firebase/app/dist/esm/index.esm2017.js
1641
1648
  var PlatformLoggerServiceImpl = class {
1642
1649
  constructor(container) {
1643
1650
  this.container = container;
@@ -1661,7 +1668,7 @@
1661
1668
  return (component === null || component === void 0 ? void 0 : component.type) === "VERSION";
1662
1669
  }
1663
1670
  var name$o = "@firebase/app";
1664
- var version$1 = "0.9.4";
1671
+ var version$1 = "0.9.19";
1665
1672
  var logger = new Logger("@firebase/app");
1666
1673
  var name$n = "@firebase/app-compat";
1667
1674
  var name$m = "@firebase/analytics-compat";
@@ -1687,7 +1694,7 @@
1687
1694
  var name$2 = "@firebase/firestore";
1688
1695
  var name$1 = "@firebase/firestore-compat";
1689
1696
  var name = "firebase";
1690
- var version = "9.17.2";
1697
+ var version = "10.4.0";
1691
1698
  var DEFAULT_ENTRY_NAME2 = "[DEFAULT]";
1692
1699
  var PLATFORM_LOG_STRING = {
1693
1700
  [name$o]: "fire-core",
@@ -1749,7 +1756,7 @@
1749
1756
  [
1750
1757
  "no-app"
1751
1758
  /* AppError.NO_APP */
1752
- ]: "No Firebase App '{$appName}' has been created - call Firebase App.initializeApp()",
1759
+ ]: "No Firebase App '{$appName}' has been created - call initializeApp() first",
1753
1760
  [
1754
1761
  "bad-app-name"
1755
1762
  /* AppError.BAD_APP_NAME */
@@ -1885,7 +1892,7 @@
1885
1892
  }
1886
1893
  function getApp(name4 = DEFAULT_ENTRY_NAME2) {
1887
1894
  const app2 = _apps.get(name4);
1888
- if (!app2 && name4 === DEFAULT_ENTRY_NAME2) {
1895
+ if (!app2 && name4 === DEFAULT_ENTRY_NAME2 && getDefaultAppConfig()) {
1889
1896
  return initializeApp();
1890
1897
  }
1891
1898
  if (!app2) {
@@ -1948,7 +1955,8 @@
1948
1955
  async function readHeartbeatsFromIndexedDB(app2) {
1949
1956
  try {
1950
1957
  const db = await getDbPromise();
1951
- return db.transaction(STORE_NAME).objectStore(STORE_NAME).get(computeKey(app2));
1958
+ const result = await db.transaction(STORE_NAME).objectStore(STORE_NAME).get(computeKey(app2));
1959
+ return result;
1952
1960
  } catch (e2) {
1953
1961
  if (e2 instanceof FirebaseError) {
1954
1962
  logger.warn(e2.message);
@@ -1966,7 +1974,7 @@
1966
1974
  const tx = db.transaction(STORE_NAME, "readwrite");
1967
1975
  const objectStore = tx.objectStore(STORE_NAME);
1968
1976
  await objectStore.put(heartbeatObject, computeKey(app2));
1969
- return tx.done;
1977
+ await tx.done;
1970
1978
  } catch (e2) {
1971
1979
  if (e2 instanceof FirebaseError) {
1972
1980
  logger.warn(e2.message);
@@ -2161,9 +2169,9 @@
2161
2169
  }
2162
2170
  registerCoreComponents("");
2163
2171
 
2164
- // ../../node_modules/.pnpm/firebase@9.17.2/node_modules/firebase/app/dist/esm/index.esm.js
2172
+ // ../../node_modules/.pnpm/firebase@10.4.0/node_modules/firebase/app/dist/esm/index.esm.js
2165
2173
  var name2 = "firebase";
2166
- var version2 = "9.17.2";
2174
+ var version2 = "10.4.0";
2167
2175
  registerVersion(name2, version2, "app");
2168
2176
 
2169
2177
  // ../../node_modules/.pnpm/tslib@2.4.1/node_modules/tslib/tslib.es6.js
@@ -2180,7 +2188,21 @@
2180
2188
  return t2;
2181
2189
  }
2182
2190
 
2183
- // ../../node_modules/.pnpm/@firebase+auth@0.21.4_@firebase+app@0.9.4/node_modules/@firebase/auth/dist/esm2017/index-e3f1fbba.js
2191
+ // ../../node_modules/.pnpm/@firebase+auth@1.3.0_@firebase+app@0.9.19/node_modules/@firebase/auth/dist/esm2017/index-9a76d29a.js
2192
+ function isEnterprise(grecaptcha) {
2193
+ return grecaptcha !== void 0 && grecaptcha.enterprise !== void 0;
2194
+ }
2195
+ var RecaptchaConfig = class {
2196
+ constructor(response) {
2197
+ this.siteKey = "";
2198
+ this.emailPasswordEnabled = false;
2199
+ if (response.recaptchaKey === void 0) {
2200
+ throw new Error("recaptchaKey undefined");
2201
+ }
2202
+ this.siteKey = response.recaptchaKey.split("/")[3];
2203
+ this.emailPasswordEnabled = response.recaptchaEnforcementState.some((enforcementState) => enforcementState.provider === "EMAIL_PASSWORD_PROVIDER" && enforcementState.enforcementState !== "OFF");
2204
+ }
2205
+ };
2184
2206
  function _prodErrorMap() {
2185
2207
  return {
2186
2208
  [
@@ -2192,6 +2214,11 @@
2192
2214
  var prodErrorMap = _prodErrorMap;
2193
2215
  var _DEFAULT_AUTH_ERROR_FACTORY = new ErrorFactory("auth", "Firebase", _prodErrorMap());
2194
2216
  var logClient = new Logger("@firebase/auth");
2217
+ function _logWarn(msg, ...args) {
2218
+ if (logClient.logLevel <= LogLevel.WARN) {
2219
+ logClient.warn(`Auth (${SDK_VERSION}): ${msg}`, ...args);
2220
+ }
2221
+ }
2195
2222
  function _logError(msg, ...args) {
2196
2223
  if (logClient.logLevel <= LogLevel.ERROR) {
2197
2224
  logClient.error(`Auth (${SDK_VERSION}): ${msg}`, ...args);
@@ -2249,44 +2276,6 @@
2249
2276
  debugFail(message);
2250
2277
  }
2251
2278
  }
2252
- var instanceCache = /* @__PURE__ */ new Map();
2253
- function _getInstance(cls) {
2254
- debugAssert(cls instanceof Function, "Expected a class definition");
2255
- let instance = instanceCache.get(cls);
2256
- if (instance) {
2257
- debugAssert(instance instanceof cls, "Instance stored in cache mismatched with class");
2258
- return instance;
2259
- }
2260
- instance = new cls();
2261
- instanceCache.set(cls, instance);
2262
- return instance;
2263
- }
2264
- function initializeAuth(app2, deps) {
2265
- const provider = _getProvider(app2, "auth");
2266
- if (provider.isInitialized()) {
2267
- const auth3 = provider.getImmediate();
2268
- const initialOptions = provider.getOptions();
2269
- if (deepEqual(initialOptions, deps !== null && deps !== void 0 ? deps : {})) {
2270
- return auth3;
2271
- } else {
2272
- _fail(
2273
- auth3,
2274
- "already-initialized"
2275
- /* AuthErrorCode.ALREADY_INITIALIZED */
2276
- );
2277
- }
2278
- }
2279
- const auth2 = provider.initialize({ options: deps });
2280
- return auth2;
2281
- }
2282
- function _initializeAuthInstance(auth2, deps) {
2283
- const persistence = (deps === null || deps === void 0 ? void 0 : deps.persistence) || [];
2284
- const hierarchy = (Array.isArray(persistence) ? persistence : [persistence]).map(_getInstance);
2285
- if (deps === null || deps === void 0 ? void 0 : deps.errorMap) {
2286
- auth2._updateErrorMap(deps.errorMap);
2287
- }
2288
- auth2._initializeWithPersistence(hierarchy, deps === null || deps === void 0 ? void 0 : deps.popupRedirectResolver);
2289
- }
2290
2279
  function _getCurrentUrl() {
2291
2280
  var _a;
2292
2281
  return typeof self !== "undefined" && ((_a = self.location) === null || _a === void 0 ? void 0 : _a.href) || "";
@@ -2412,7 +2401,7 @@
2412
2401
  [
2413
2402
  "MISSING_PASSWORD"
2414
2403
  /* ServerError.MISSING_PASSWORD */
2415
- ]: "internal-error",
2404
+ ]: "missing-password",
2416
2405
  // Sign up with email and password errors.
2417
2406
  [
2418
2407
  "EMAIL_EXISTS"
@@ -2484,6 +2473,10 @@
2484
2473
  "TOO_MANY_ATTEMPTS_TRY_LATER"
2485
2474
  /* ServerError.TOO_MANY_ATTEMPTS_TRY_LATER */
2486
2475
  ]: "too-many-requests",
2476
+ [
2477
+ "PASSWORD_DOES_NOT_MEET_REQUIREMENTS"
2478
+ /* ServerError.PASSWORD_DOES_NOT_MEET_REQUIREMENTS */
2479
+ ]: "password-does-not-meet-requirements",
2487
2480
  // Phone Auth related errors.
2488
2481
  [
2489
2482
  "INVALID_CODE"
@@ -2555,8 +2548,41 @@
2555
2548
  [
2556
2549
  "BLOCKING_FUNCTION_ERROR_RESPONSE"
2557
2550
  /* ServerError.BLOCKING_FUNCTION_ERROR_RESPONSE */
2558
- ]: "internal-error"
2559
- /* AuthErrorCode.INTERNAL_ERROR */
2551
+ ]: "internal-error",
2552
+ // Recaptcha related errors.
2553
+ [
2554
+ "RECAPTCHA_NOT_ENABLED"
2555
+ /* ServerError.RECAPTCHA_NOT_ENABLED */
2556
+ ]: "recaptcha-not-enabled",
2557
+ [
2558
+ "MISSING_RECAPTCHA_TOKEN"
2559
+ /* ServerError.MISSING_RECAPTCHA_TOKEN */
2560
+ ]: "missing-recaptcha-token",
2561
+ [
2562
+ "INVALID_RECAPTCHA_TOKEN"
2563
+ /* ServerError.INVALID_RECAPTCHA_TOKEN */
2564
+ ]: "invalid-recaptcha-token",
2565
+ [
2566
+ "INVALID_RECAPTCHA_ACTION"
2567
+ /* ServerError.INVALID_RECAPTCHA_ACTION */
2568
+ ]: "invalid-recaptcha-action",
2569
+ [
2570
+ "MISSING_CLIENT_TYPE"
2571
+ /* ServerError.MISSING_CLIENT_TYPE */
2572
+ ]: "missing-client-type",
2573
+ [
2574
+ "MISSING_RECAPTCHA_VERSION"
2575
+ /* ServerError.MISSING_RECAPTCHA_VERSION */
2576
+ ]: "missing-recaptcha-version",
2577
+ [
2578
+ "INVALID_RECAPTCHA_VERSION"
2579
+ /* ServerError.INVALID_RECAPTCHA_VERSION */
2580
+ ]: "invalid-recaptcha-version",
2581
+ [
2582
+ "INVALID_REQ_TYPE"
2583
+ /* ServerError.INVALID_REQ_TYPE */
2584
+ ]: "invalid-req-type"
2585
+ /* AuthErrorCode.INVALID_REQ_TYPE */
2560
2586
  };
2561
2587
  var DEFAULT_API_TIMEOUT_MS = new Delay(3e4, 6e4);
2562
2588
  function _addTidIfNecessary(auth2, request) {
@@ -2634,7 +2660,7 @@
2634
2660
  if (e2 instanceof FirebaseError) {
2635
2661
  throw e2;
2636
2662
  }
2637
- _fail(auth2, "internal-error", { "message": String(e2) });
2663
+ _fail(auth2, "network-request-failed", { "message": String(e2) });
2638
2664
  }
2639
2665
  }
2640
2666
  async function _performSignInRequest(auth2, method, path, request, customErrorMap = {}) {
@@ -2685,6 +2711,9 @@
2685
2711
  error.customData._tokenResponse = response;
2686
2712
  return error;
2687
2713
  }
2714
+ async function getRecaptchaConfig(auth2, request) {
2715
+ return _performApiRequest(auth2, "GET", "/v2/recaptchaConfig", _addTidIfNecessary(auth2, request));
2716
+ }
2688
2717
  async function deleteAccount(auth2, request) {
2689
2718
  return _performApiRequest(auth2, "POST", "/v1/accounts:delete", request);
2690
2719
  }
@@ -3115,7 +3144,9 @@
3115
3144
  this.stsTokenManager._assign(user.stsTokenManager);
3116
3145
  }
3117
3146
  _clone(auth2) {
3118
- return new _UserImpl(Object.assign(Object.assign({}, this), { auth: auth2, stsTokenManager: this.stsTokenManager._clone() }));
3147
+ const newUser = new _UserImpl(Object.assign(Object.assign({}, this), { auth: auth2, stsTokenManager: this.stsTokenManager._clone() }));
3148
+ newUser.metadata._copy(this.metadata);
3149
+ return newUser;
3119
3150
  }
3120
3151
  _onReload(callback) {
3121
3152
  _assert(
@@ -3271,6 +3302,18 @@
3271
3302
  return user;
3272
3303
  }
3273
3304
  };
3305
+ var instanceCache = /* @__PURE__ */ new Map();
3306
+ function _getInstance(cls) {
3307
+ debugAssert(cls instanceof Function, "Expected a class definition");
3308
+ let instance = instanceCache.get(cls);
3309
+ if (instance) {
3310
+ debugAssert(instance instanceof cls, "Instance stored in cache mismatched with class");
3311
+ return instance;
3312
+ }
3313
+ instance = new cls();
3314
+ instanceCache.set(cls, instance);
3315
+ return instance;
3316
+ }
3274
3317
  var InMemoryPersistence = class {
3275
3318
  constructor() {
3276
3319
  this.type = "NONE";
@@ -3522,10 +3565,136 @@
3522
3565
  }
3523
3566
  }
3524
3567
  };
3568
+ async function _getPasswordPolicy(auth2, request = {}) {
3569
+ return _performApiRequest(auth2, "GET", "/v2/passwordPolicy", _addTidIfNecessary(auth2, request));
3570
+ }
3571
+ var MINIMUM_MIN_PASSWORD_LENGTH = 6;
3572
+ var PasswordPolicyImpl = class {
3573
+ constructor(response) {
3574
+ var _a, _b, _c, _d;
3575
+ const responseOptions = response.customStrengthOptions;
3576
+ this.customStrengthOptions = {};
3577
+ this.customStrengthOptions.minPasswordLength = (_a = responseOptions.minPasswordLength) !== null && _a !== void 0 ? _a : MINIMUM_MIN_PASSWORD_LENGTH;
3578
+ if (responseOptions.maxPasswordLength) {
3579
+ this.customStrengthOptions.maxPasswordLength = responseOptions.maxPasswordLength;
3580
+ }
3581
+ if (responseOptions.containsLowercaseCharacter !== void 0) {
3582
+ this.customStrengthOptions.containsLowercaseLetter = responseOptions.containsLowercaseCharacter;
3583
+ }
3584
+ if (responseOptions.containsUppercaseCharacter !== void 0) {
3585
+ this.customStrengthOptions.containsUppercaseLetter = responseOptions.containsUppercaseCharacter;
3586
+ }
3587
+ if (responseOptions.containsNumericCharacter !== void 0) {
3588
+ this.customStrengthOptions.containsNumericCharacter = responseOptions.containsNumericCharacter;
3589
+ }
3590
+ if (responseOptions.containsNonAlphanumericCharacter !== void 0) {
3591
+ this.customStrengthOptions.containsNonAlphanumericCharacter = responseOptions.containsNonAlphanumericCharacter;
3592
+ }
3593
+ this.enforcementState = response.enforcementState;
3594
+ if (this.enforcementState === "ENFORCEMENT_STATE_UNSPECIFIED") {
3595
+ this.enforcementState = "OFF";
3596
+ }
3597
+ this.allowedNonAlphanumericCharacters = (_c = (_b = response.allowedNonAlphanumericCharacters) === null || _b === void 0 ? void 0 : _b.join("")) !== null && _c !== void 0 ? _c : "";
3598
+ this.forceUpgradeOnSignin = (_d = response.forceUpgradeOnSignin) !== null && _d !== void 0 ? _d : false;
3599
+ this.schemaVersion = response.schemaVersion;
3600
+ }
3601
+ validatePassword(password) {
3602
+ var _a, _b, _c, _d, _e, _f;
3603
+ const status = {
3604
+ isValid: true,
3605
+ passwordPolicy: this
3606
+ };
3607
+ this.validatePasswordLengthOptions(password, status);
3608
+ this.validatePasswordCharacterOptions(password, status);
3609
+ status.isValid && (status.isValid = (_a = status.meetsMinPasswordLength) !== null && _a !== void 0 ? _a : true);
3610
+ status.isValid && (status.isValid = (_b = status.meetsMaxPasswordLength) !== null && _b !== void 0 ? _b : true);
3611
+ status.isValid && (status.isValid = (_c = status.containsLowercaseLetter) !== null && _c !== void 0 ? _c : true);
3612
+ status.isValid && (status.isValid = (_d = status.containsUppercaseLetter) !== null && _d !== void 0 ? _d : true);
3613
+ status.isValid && (status.isValid = (_e = status.containsNumericCharacter) !== null && _e !== void 0 ? _e : true);
3614
+ status.isValid && (status.isValid = (_f = status.containsNonAlphanumericCharacter) !== null && _f !== void 0 ? _f : true);
3615
+ return status;
3616
+ }
3617
+ /**
3618
+ * Validates that the password meets the length options for the policy.
3619
+ *
3620
+ * @param password Password to validate.
3621
+ * @param status Validation status.
3622
+ */
3623
+ validatePasswordLengthOptions(password, status) {
3624
+ const minPasswordLength = this.customStrengthOptions.minPasswordLength;
3625
+ const maxPasswordLength = this.customStrengthOptions.maxPasswordLength;
3626
+ if (minPasswordLength) {
3627
+ status.meetsMinPasswordLength = password.length >= minPasswordLength;
3628
+ }
3629
+ if (maxPasswordLength) {
3630
+ status.meetsMaxPasswordLength = password.length <= maxPasswordLength;
3631
+ }
3632
+ }
3633
+ /**
3634
+ * Validates that the password meets the character options for the policy.
3635
+ *
3636
+ * @param password Password to validate.
3637
+ * @param status Validation status.
3638
+ */
3639
+ validatePasswordCharacterOptions(password, status) {
3640
+ this.updatePasswordCharacterOptionsStatuses(
3641
+ status,
3642
+ /* containsLowercaseCharacter= */
3643
+ false,
3644
+ /* containsUppercaseCharacter= */
3645
+ false,
3646
+ /* containsNumericCharacter= */
3647
+ false,
3648
+ /* containsNonAlphanumericCharacter= */
3649
+ false
3650
+ );
3651
+ let passwordChar;
3652
+ for (let i2 = 0; i2 < password.length; i2++) {
3653
+ passwordChar = password.charAt(i2);
3654
+ this.updatePasswordCharacterOptionsStatuses(
3655
+ status,
3656
+ /* containsLowercaseCharacter= */
3657
+ passwordChar >= "a" && passwordChar <= "z",
3658
+ /* containsUppercaseCharacter= */
3659
+ passwordChar >= "A" && passwordChar <= "Z",
3660
+ /* containsNumericCharacter= */
3661
+ passwordChar >= "0" && passwordChar <= "9",
3662
+ /* containsNonAlphanumericCharacter= */
3663
+ this.allowedNonAlphanumericCharacters.includes(passwordChar)
3664
+ );
3665
+ }
3666
+ }
3667
+ /**
3668
+ * Updates the running validation status with the statuses for the character options.
3669
+ * Expected to be called each time a character is processed to update each option status
3670
+ * based on the current character.
3671
+ *
3672
+ * @param status Validation status.
3673
+ * @param containsLowercaseCharacter Whether the character is a lowercase letter.
3674
+ * @param containsUppercaseCharacter Whether the character is an uppercase letter.
3675
+ * @param containsNumericCharacter Whether the character is a numeric character.
3676
+ * @param containsNonAlphanumericCharacter Whether the character is a non-alphanumeric character.
3677
+ */
3678
+ updatePasswordCharacterOptionsStatuses(status, containsLowercaseCharacter, containsUppercaseCharacter, containsNumericCharacter, containsNonAlphanumericCharacter) {
3679
+ if (this.customStrengthOptions.containsLowercaseLetter) {
3680
+ status.containsLowercaseLetter || (status.containsLowercaseLetter = containsLowercaseCharacter);
3681
+ }
3682
+ if (this.customStrengthOptions.containsUppercaseLetter) {
3683
+ status.containsUppercaseLetter || (status.containsUppercaseLetter = containsUppercaseCharacter);
3684
+ }
3685
+ if (this.customStrengthOptions.containsNumericCharacter) {
3686
+ status.containsNumericCharacter || (status.containsNumericCharacter = containsNumericCharacter);
3687
+ }
3688
+ if (this.customStrengthOptions.containsNonAlphanumericCharacter) {
3689
+ status.containsNonAlphanumericCharacter || (status.containsNonAlphanumericCharacter = containsNonAlphanumericCharacter);
3690
+ }
3691
+ }
3692
+ };
3525
3693
  var AuthImpl = class {
3526
- constructor(app2, heartbeatServiceProvider, config) {
3694
+ constructor(app2, heartbeatServiceProvider, appCheckServiceProvider, config) {
3527
3695
  this.app = app2;
3528
3696
  this.heartbeatServiceProvider = heartbeatServiceProvider;
3697
+ this.appCheckServiceProvider = appCheckServiceProvider;
3529
3698
  this.config = config;
3530
3699
  this.currentUser = null;
3531
3700
  this.emulatorConfig = null;
@@ -3535,12 +3704,17 @@
3535
3704
  this.beforeStateQueue = new AuthMiddlewareQueue(this);
3536
3705
  this.redirectUser = null;
3537
3706
  this.isProactiveRefreshEnabled = false;
3707
+ this.EXPECTED_PASSWORD_POLICY_SCHEMA_VERSION = 1;
3538
3708
  this._canInitEmulator = true;
3539
3709
  this._isInitialized = false;
3540
3710
  this._deleted = false;
3541
3711
  this._initializationPromise = null;
3542
3712
  this._popupRedirectResolver = null;
3543
3713
  this._errorFactory = _DEFAULT_AUTH_ERROR_FACTORY;
3714
+ this._agentRecaptchaConfig = null;
3715
+ this._tenantRecaptchaConfigs = {};
3716
+ this._projectPasswordPolicy = null;
3717
+ this._tenantPasswordPolicies = {};
3544
3718
  this.lastNotifiedUid = void 0;
3545
3719
  this.languageCode = null;
3546
3720
  this.tenantId = null;
@@ -3717,6 +3891,39 @@
3717
3891
  await this.assertedPersistence.setPersistence(_getInstance(persistence));
3718
3892
  });
3719
3893
  }
3894
+ _getRecaptchaConfig() {
3895
+ if (this.tenantId == null) {
3896
+ return this._agentRecaptchaConfig;
3897
+ } else {
3898
+ return this._tenantRecaptchaConfigs[this.tenantId];
3899
+ }
3900
+ }
3901
+ async validatePassword(password) {
3902
+ if (!this._getPasswordPolicyInternal()) {
3903
+ await this._updatePasswordPolicy();
3904
+ }
3905
+ const passwordPolicy = this._getPasswordPolicyInternal();
3906
+ if (passwordPolicy.schemaVersion !== this.EXPECTED_PASSWORD_POLICY_SCHEMA_VERSION) {
3907
+ return Promise.reject(this._errorFactory.create("unsupported-password-policy-schema-version", {}));
3908
+ }
3909
+ return passwordPolicy.validatePassword(password);
3910
+ }
3911
+ _getPasswordPolicyInternal() {
3912
+ if (this.tenantId === null) {
3913
+ return this._projectPasswordPolicy;
3914
+ } else {
3915
+ return this._tenantPasswordPolicies[this.tenantId];
3916
+ }
3917
+ }
3918
+ async _updatePasswordPolicy() {
3919
+ const response = await _getPasswordPolicy(this);
3920
+ const passwordPolicy = new PasswordPolicyImpl(response);
3921
+ if (this.tenantId === null) {
3922
+ this._projectPasswordPolicy = passwordPolicy;
3923
+ } else {
3924
+ this._tenantPasswordPolicies[this.tenantId] = passwordPolicy;
3925
+ }
3926
+ }
3720
3927
  _getPersistence() {
3721
3928
  return this.assertedPersistence.persistence.type;
3722
3929
  }
@@ -3732,6 +3939,18 @@
3732
3939
  onIdTokenChanged(nextOrObserver, error, completed) {
3733
3940
  return this.registerStateListener(this.idTokenSubscription, nextOrObserver, error, completed);
3734
3941
  }
3942
+ authStateReady() {
3943
+ return new Promise((resolve, reject) => {
3944
+ if (this.currentUser) {
3945
+ resolve();
3946
+ } else {
3947
+ const unsubscribe = this.onAuthStateChanged(() => {
3948
+ unsubscribe();
3949
+ resolve();
3950
+ }, reject);
3951
+ }
3952
+ });
3953
+ }
3735
3954
  toJSON() {
3736
3955
  var _a;
3737
3956
  return {
@@ -3826,6 +4045,7 @@
3826
4045
  };
3827
4046
  }
3828
4047
  const cb = typeof nextOrObserver === "function" ? nextOrObserver : nextOrObserver.next.bind(nextOrObserver);
4048
+ let isUnsubscribed = false;
3829
4049
  const promise = this._isInitialized ? Promise.resolve() : this._initializationPromise;
3830
4050
  _assert(
3831
4051
  promise,
@@ -3833,11 +4053,24 @@
3833
4053
  "internal-error"
3834
4054
  /* AuthErrorCode.INTERNAL_ERROR */
3835
4055
  );
3836
- promise.then(() => cb(this.currentUser));
4056
+ promise.then(() => {
4057
+ if (isUnsubscribed) {
4058
+ return;
4059
+ }
4060
+ cb(this.currentUser);
4061
+ });
3837
4062
  if (typeof nextOrObserver === "function") {
3838
- return subscription.addObserver(nextOrObserver, error, completed);
4063
+ const unsubscribe = subscription.addObserver(nextOrObserver, error, completed);
4064
+ return () => {
4065
+ isUnsubscribed = true;
4066
+ unsubscribe();
4067
+ };
3839
4068
  } else {
3840
- return subscription.addObserver(nextOrObserver);
4069
+ const unsubscribe = subscription.addObserver(nextOrObserver);
4070
+ return () => {
4071
+ isUnsubscribed = true;
4072
+ unsubscribe();
4073
+ };
3841
4074
  }
3842
4075
  }
3843
4076
  /**
@@ -3906,8 +4139,23 @@
3906
4139
  /* HttpHeader.X_FIREBASE_CLIENT */
3907
4140
  ] = heartbeatsHeader;
3908
4141
  }
4142
+ const appCheckToken = await this._getAppCheckToken();
4143
+ if (appCheckToken) {
4144
+ headers[
4145
+ "X-Firebase-AppCheck"
4146
+ /* HttpHeader.X_FIREBASE_APP_CHECK */
4147
+ ] = appCheckToken;
4148
+ }
3909
4149
  return headers;
3910
4150
  }
4151
+ async _getAppCheckToken() {
4152
+ var _a;
4153
+ const appCheckTokenResult = await ((_a = this.appCheckServiceProvider.getImmediate({ optional: true })) === null || _a === void 0 ? void 0 : _a.getToken());
4154
+ if (appCheckTokenResult === null || appCheckTokenResult === void 0 ? void 0 : appCheckTokenResult.error) {
4155
+ _logWarn(`Error while retrieving App Check token: ${appCheckTokenResult.error}`);
4156
+ }
4157
+ return appCheckTokenResult === null || appCheckTokenResult === void 0 ? void 0 : appCheckTokenResult.token;
4158
+ }
3911
4159
  };
3912
4160
  function _castAuth(auth2) {
3913
4161
  return getModularInstance(auth2);
@@ -3928,6 +4176,166 @@
3928
4176
  return this.observer.next.bind(this.observer);
3929
4177
  }
3930
4178
  };
4179
+ function getScriptParentElement() {
4180
+ var _a, _b;
4181
+ return (_b = (_a = document.getElementsByTagName("head")) === null || _a === void 0 ? void 0 : _a[0]) !== null && _b !== void 0 ? _b : document;
4182
+ }
4183
+ function _loadJS(url) {
4184
+ return new Promise((resolve, reject) => {
4185
+ const el = document.createElement("script");
4186
+ el.setAttribute("src", url);
4187
+ el.onload = resolve;
4188
+ el.onerror = (e2) => {
4189
+ const error = _createError(
4190
+ "internal-error"
4191
+ /* AuthErrorCode.INTERNAL_ERROR */
4192
+ );
4193
+ error.customData = e2;
4194
+ reject(error);
4195
+ };
4196
+ el.type = "text/javascript";
4197
+ el.charset = "UTF-8";
4198
+ getScriptParentElement().appendChild(el);
4199
+ });
4200
+ }
4201
+ function _generateCallbackName(prefix) {
4202
+ return `__${prefix}${Math.floor(Math.random() * 1e6)}`;
4203
+ }
4204
+ var RECAPTCHA_ENTERPRISE_URL = "https://www.google.com/recaptcha/enterprise.js?render=";
4205
+ var RECAPTCHA_ENTERPRISE_VERIFIER_TYPE = "recaptcha-enterprise";
4206
+ var FAKE_TOKEN = "NO_RECAPTCHA";
4207
+ var RecaptchaEnterpriseVerifier = class {
4208
+ /**
4209
+ *
4210
+ * @param authExtern - The corresponding Firebase {@link Auth} instance.
4211
+ *
4212
+ */
4213
+ constructor(authExtern) {
4214
+ this.type = RECAPTCHA_ENTERPRISE_VERIFIER_TYPE;
4215
+ this.auth = _castAuth(authExtern);
4216
+ }
4217
+ /**
4218
+ * Executes the verification process.
4219
+ *
4220
+ * @returns A Promise for a token that can be used to assert the validity of a request.
4221
+ */
4222
+ async verify(action = "verify", forceRefresh = false) {
4223
+ async function retrieveSiteKey(auth2) {
4224
+ if (!forceRefresh) {
4225
+ if (auth2.tenantId == null && auth2._agentRecaptchaConfig != null) {
4226
+ return auth2._agentRecaptchaConfig.siteKey;
4227
+ }
4228
+ if (auth2.tenantId != null && auth2._tenantRecaptchaConfigs[auth2.tenantId] !== void 0) {
4229
+ return auth2._tenantRecaptchaConfigs[auth2.tenantId].siteKey;
4230
+ }
4231
+ }
4232
+ return new Promise(async (resolve, reject) => {
4233
+ getRecaptchaConfig(auth2, {
4234
+ clientType: "CLIENT_TYPE_WEB",
4235
+ version: "RECAPTCHA_ENTERPRISE"
4236
+ /* RecaptchaVersion.ENTERPRISE */
4237
+ }).then((response) => {
4238
+ if (response.recaptchaKey === void 0) {
4239
+ reject(new Error("recaptcha Enterprise site key undefined"));
4240
+ } else {
4241
+ const config = new RecaptchaConfig(response);
4242
+ if (auth2.tenantId == null) {
4243
+ auth2._agentRecaptchaConfig = config;
4244
+ } else {
4245
+ auth2._tenantRecaptchaConfigs[auth2.tenantId] = config;
4246
+ }
4247
+ return resolve(config.siteKey);
4248
+ }
4249
+ }).catch((error) => {
4250
+ reject(error);
4251
+ });
4252
+ });
4253
+ }
4254
+ function retrieveRecaptchaToken(siteKey, resolve, reject) {
4255
+ const grecaptcha = window.grecaptcha;
4256
+ if (isEnterprise(grecaptcha)) {
4257
+ grecaptcha.enterprise.ready(() => {
4258
+ grecaptcha.enterprise.execute(siteKey, { action }).then((token) => {
4259
+ resolve(token);
4260
+ }).catch(() => {
4261
+ resolve(FAKE_TOKEN);
4262
+ });
4263
+ });
4264
+ } else {
4265
+ reject(Error("No reCAPTCHA enterprise script loaded."));
4266
+ }
4267
+ }
4268
+ return new Promise((resolve, reject) => {
4269
+ retrieveSiteKey(this.auth).then((siteKey) => {
4270
+ if (!forceRefresh && isEnterprise(window.grecaptcha)) {
4271
+ retrieveRecaptchaToken(siteKey, resolve, reject);
4272
+ } else {
4273
+ if (typeof window === "undefined") {
4274
+ reject(new Error("RecaptchaVerifier is only supported in browser"));
4275
+ return;
4276
+ }
4277
+ _loadJS(RECAPTCHA_ENTERPRISE_URL + siteKey).then(() => {
4278
+ retrieveRecaptchaToken(siteKey, resolve, reject);
4279
+ }).catch((error) => {
4280
+ reject(error);
4281
+ });
4282
+ }
4283
+ }).catch((error) => {
4284
+ reject(error);
4285
+ });
4286
+ });
4287
+ }
4288
+ };
4289
+ async function injectRecaptchaFields(auth2, request, action, captchaResp = false) {
4290
+ const verifier = new RecaptchaEnterpriseVerifier(auth2);
4291
+ let captchaResponse;
4292
+ try {
4293
+ captchaResponse = await verifier.verify(action);
4294
+ } catch (error) {
4295
+ captchaResponse = await verifier.verify(action, true);
4296
+ }
4297
+ const newRequest = Object.assign({}, request);
4298
+ if (!captchaResp) {
4299
+ Object.assign(newRequest, { captchaResponse });
4300
+ } else {
4301
+ Object.assign(newRequest, { "captchaResp": captchaResponse });
4302
+ }
4303
+ Object.assign(newRequest, {
4304
+ "clientType": "CLIENT_TYPE_WEB"
4305
+ /* RecaptchaClientType.WEB */
4306
+ });
4307
+ Object.assign(newRequest, {
4308
+ "recaptchaVersion": "RECAPTCHA_ENTERPRISE"
4309
+ /* RecaptchaVersion.ENTERPRISE */
4310
+ });
4311
+ return newRequest;
4312
+ }
4313
+ function initializeAuth(app2, deps) {
4314
+ const provider = _getProvider(app2, "auth");
4315
+ if (provider.isInitialized()) {
4316
+ const auth3 = provider.getImmediate();
4317
+ const initialOptions = provider.getOptions();
4318
+ if (deepEqual(initialOptions, deps !== null && deps !== void 0 ? deps : {})) {
4319
+ return auth3;
4320
+ } else {
4321
+ _fail(
4322
+ auth3,
4323
+ "already-initialized"
4324
+ /* AuthErrorCode.ALREADY_INITIALIZED */
4325
+ );
4326
+ }
4327
+ }
4328
+ const auth2 = provider.initialize({ options: deps });
4329
+ return auth2;
4330
+ }
4331
+ function _initializeAuthInstance(auth2, deps) {
4332
+ const persistence = (deps === null || deps === void 0 ? void 0 : deps.persistence) || [];
4333
+ const hierarchy = (Array.isArray(persistence) ? persistence : [persistence]).map(_getInstance);
4334
+ if (deps === null || deps === void 0 ? void 0 : deps.errorMap) {
4335
+ auth2._updateErrorMap(deps.errorMap);
4336
+ }
4337
+ auth2._initializeWithPersistence(hierarchy, deps === null || deps === void 0 ? void 0 : deps.popupRedirectResolver);
4338
+ }
3931
4339
  function connectAuthEmulator(auth2, url, options) {
3932
4340
  const authInternal = _castAuth(auth2);
3933
4341
  _assert(
@@ -4107,13 +4515,40 @@
4107
4515
  }
4108
4516
  /** @internal */
4109
4517
  async _getIdTokenResponse(auth2) {
4518
+ var _a;
4110
4519
  switch (this.signInMethod) {
4111
4520
  case "password":
4112
- return signInWithPassword(auth2, {
4521
+ const request = {
4113
4522
  returnSecureToken: true,
4114
4523
  email: this._email,
4115
- password: this._password
4116
- });
4524
+ password: this._password,
4525
+ clientType: "CLIENT_TYPE_WEB"
4526
+ /* RecaptchaClientType.WEB */
4527
+ };
4528
+ if ((_a = auth2._getRecaptchaConfig()) === null || _a === void 0 ? void 0 : _a.emailPasswordEnabled) {
4529
+ const requestWithRecaptcha = await injectRecaptchaFields(
4530
+ auth2,
4531
+ request,
4532
+ "signInWithPassword"
4533
+ /* RecaptchaActionName.SIGN_IN_WITH_PASSWORD */
4534
+ );
4535
+ return signInWithPassword(auth2, requestWithRecaptcha);
4536
+ } else {
4537
+ return signInWithPassword(auth2, request).catch(async (error) => {
4538
+ if (error.code === `auth/${"missing-recaptcha-token"}`) {
4539
+ console.log("Sign-in with email address and password is protected by reCAPTCHA for this project. Automatically triggering the reCAPTCHA flow and restarting the sign-in flow.");
4540
+ const requestWithRecaptcha = await injectRecaptchaFields(
4541
+ auth2,
4542
+ request,
4543
+ "signInWithPassword"
4544
+ /* RecaptchaActionName.SIGN_IN_WITH_PASSWORD */
4545
+ );
4546
+ return signInWithPassword(auth2, requestWithRecaptcha);
4547
+ } else {
4548
+ return Promise.reject(error);
4549
+ }
4550
+ });
4551
+ }
4117
4552
  case "emailLink":
4118
4553
  return signInWithEmailLink$1(auth2, {
4119
4554
  email: this._email,
@@ -4940,6 +5375,12 @@
4940
5375
  function finalizeEnrollPhoneMfa(auth2, request) {
4941
5376
  return _performApiRequest(auth2, "POST", "/v2/accounts/mfaEnrollment:finalize", _addTidIfNecessary(auth2, request));
4942
5377
  }
5378
+ function startEnrollTotpMfa(auth2, request) {
5379
+ return _performApiRequest(auth2, "POST", "/v2/accounts/mfaEnrollment:start", _addTidIfNecessary(auth2, request));
5380
+ }
5381
+ function finalizeEnrollTotpMfa(auth2, request) {
5382
+ return _performApiRequest(auth2, "POST", "/v2/accounts/mfaEnrollment:finalize", _addTidIfNecessary(auth2, request));
5383
+ }
4943
5384
  var STORAGE_AVAILABLE_KEY = "__sak";
4944
5385
  var BrowserPersistenceClass = class {
4945
5386
  constructor(storageRetriever, type) {
@@ -5686,30 +6127,8 @@
5686
6127
  function finalizeSignInPhoneMfa(auth2, request) {
5687
6128
  return _performApiRequest(auth2, "POST", "/v2/accounts/mfaSignIn:finalize", _addTidIfNecessary(auth2, request));
5688
6129
  }
5689
- function getScriptParentElement() {
5690
- var _a, _b;
5691
- return (_b = (_a = document.getElementsByTagName("head")) === null || _a === void 0 ? void 0 : _a[0]) !== null && _b !== void 0 ? _b : document;
5692
- }
5693
- function _loadJS(url) {
5694
- return new Promise((resolve, reject) => {
5695
- const el = document.createElement("script");
5696
- el.setAttribute("src", url);
5697
- el.onload = resolve;
5698
- el.onerror = (e2) => {
5699
- const error = _createError(
5700
- "internal-error"
5701
- /* AuthErrorCode.INTERNAL_ERROR */
5702
- );
5703
- error.customData = e2;
5704
- reject(error);
5705
- };
5706
- el.type = "text/javascript";
5707
- el.charset = "UTF-8";
5708
- getScriptParentElement().appendChild(el);
5709
- });
5710
- }
5711
- function _generateCallbackName(prefix) {
5712
- return `__${prefix}${Math.floor(Math.random() * 1e6)}`;
6130
+ function finalizeSignInTotpMfa(auth2, request) {
6131
+ return _performApiRequest(auth2, "POST", "/v2/accounts/mfaSignIn:finalize", _addTidIfNecessary(auth2, request));
5713
6132
  }
5714
6133
  var _JSLOAD_CALLBACK = _generateCallbackName("rcb");
5715
6134
  var NETWORK_TIMEOUT_DELAY = new Delay(3e4, 6e4);
@@ -6159,7 +6578,7 @@
6159
6578
  /* AuthErrorCode.POPUP_CLOSED_BY_USER */
6160
6579
  ));
6161
6580
  },
6162
- 2e3
6581
+ 8e3
6163
6582
  /* _Timeout.AUTH_EVENT */
6164
6583
  );
6165
6584
  return;
@@ -6601,7 +7020,8 @@
6601
7020
  }
6602
7021
  var WIDGET_PATH = "__/auth/handler";
6603
7022
  var EMULATOR_WIDGET_PATH = "emulator/auth/handler";
6604
- function _getRedirectUrl(auth2, provider, authType, redirectUrl, eventId, additionalParams) {
7023
+ var FIREBASE_APP_CHECK_FRAGMENT_ID = encodeURIComponent("fac");
7024
+ async function _getRedirectUrl(auth2, provider, authType, redirectUrl, eventId, additionalParams) {
6605
7025
  _assert(
6606
7026
  auth2.config.authDomain,
6607
7027
  auth2,
@@ -6647,7 +7067,9 @@
6647
7067
  delete paramsDict[key];
6648
7068
  }
6649
7069
  }
6650
- return `${getHandlerBase(auth2)}?${querystring(paramsDict).slice(1)}`;
7070
+ const appCheckToken = await auth2._getAppCheckToken();
7071
+ const appCheckTokenFragment = appCheckToken ? `#${FIREBASE_APP_CHECK_FRAGMENT_ID}=${encodeURIComponent(appCheckToken)}` : "";
7072
+ return `${getHandlerBase(auth2)}?${querystring(paramsDict).slice(1)}${appCheckTokenFragment}`;
6651
7073
  }
6652
7074
  function getHandlerBase({ config }) {
6653
7075
  if (!config.emulator) {
@@ -6670,12 +7092,13 @@
6670
7092
  async _openPopup(auth2, provider, authType, eventId) {
6671
7093
  var _a;
6672
7094
  debugAssert((_a = this.eventManagers[auth2._key()]) === null || _a === void 0 ? void 0 : _a.manager, "_initialize() not called before _openPopup()");
6673
- const url = _getRedirectUrl(auth2, provider, authType, _getCurrentUrl(), eventId);
7095
+ const url = await _getRedirectUrl(auth2, provider, authType, _getCurrentUrl(), eventId);
6674
7096
  return _open(auth2, url, _generateEventId());
6675
7097
  }
6676
7098
  async _openRedirect(auth2, provider, authType, eventId) {
6677
7099
  await this._originValidation(auth2);
6678
- _setWindowLocation(_getRedirectUrl(auth2, provider, authType, _getCurrentUrl(), eventId));
7100
+ const url = await _getRedirectUrl(auth2, provider, authType, _getCurrentUrl(), eventId);
7101
+ _setWindowLocation(url);
6679
7102
  return new Promise(() => {
6680
7103
  });
6681
7104
  }
@@ -6793,6 +7216,9 @@
6793
7216
  /**
6794
7217
  * Provides a {@link PhoneMultiFactorAssertion} to confirm ownership of the phone second factor.
6795
7218
  *
7219
+ * @remarks
7220
+ * This method does not work in a Node.js environment.
7221
+ *
6796
7222
  * @param phoneAuthCredential - A credential provided by {@link PhoneAuthProvider.credential}.
6797
7223
  * @returns A {@link PhoneMultiFactorAssertion} which can be used with
6798
7224
  * {@link MultiFactorResolver.resolveSignIn}
@@ -6802,8 +7228,156 @@
6802
7228
  }
6803
7229
  };
6804
7230
  PhoneMultiFactorGenerator.FACTOR_ID = "phone";
7231
+ var TotpMultiFactorGenerator = class {
7232
+ /**
7233
+ * Provides a {@link TotpMultiFactorAssertion} to confirm ownership of
7234
+ * the TOTP (time-based one-time password) second factor.
7235
+ * This assertion is used to complete enrollment in TOTP second factor.
7236
+ *
7237
+ * @param secret A {@link TotpSecret} containing the shared secret key and other TOTP parameters.
7238
+ * @param oneTimePassword One-time password from TOTP App.
7239
+ * @returns A {@link TotpMultiFactorAssertion} which can be used with
7240
+ * {@link MultiFactorUser.enroll}.
7241
+ */
7242
+ static assertionForEnrollment(secret, oneTimePassword) {
7243
+ return TotpMultiFactorAssertionImpl._fromSecret(secret, oneTimePassword);
7244
+ }
7245
+ /**
7246
+ * Provides a {@link TotpMultiFactorAssertion} to confirm ownership of the TOTP second factor.
7247
+ * This assertion is used to complete signIn with TOTP as the second factor.
7248
+ *
7249
+ * @param enrollmentId identifies the enrolled TOTP second factor.
7250
+ * @param oneTimePassword One-time password from TOTP App.
7251
+ * @returns A {@link TotpMultiFactorAssertion} which can be used with
7252
+ * {@link MultiFactorResolver.resolveSignIn}.
7253
+ */
7254
+ static assertionForSignIn(enrollmentId, oneTimePassword) {
7255
+ return TotpMultiFactorAssertionImpl._fromEnrollmentId(enrollmentId, oneTimePassword);
7256
+ }
7257
+ /**
7258
+ * Returns a promise to {@link TotpSecret} which contains the TOTP shared secret key and other parameters.
7259
+ * Creates a TOTP secret as part of enrolling a TOTP second factor.
7260
+ * Used for generating a QR code URL or inputting into a TOTP app.
7261
+ * This method uses the auth instance corresponding to the user in the multiFactorSession.
7262
+ *
7263
+ * @param session The {@link MultiFactorSession} that the user is part of.
7264
+ * @returns A promise to {@link TotpSecret}.
7265
+ */
7266
+ static async generateSecret(session) {
7267
+ var _a;
7268
+ const mfaSession = session;
7269
+ _assert(
7270
+ typeof ((_a = mfaSession.user) === null || _a === void 0 ? void 0 : _a.auth) !== "undefined",
7271
+ "internal-error"
7272
+ /* AuthErrorCode.INTERNAL_ERROR */
7273
+ );
7274
+ const response = await startEnrollTotpMfa(mfaSession.user.auth, {
7275
+ idToken: mfaSession.credential,
7276
+ totpEnrollmentInfo: {}
7277
+ });
7278
+ return TotpSecret._fromStartTotpMfaEnrollmentResponse(response, mfaSession.user.auth);
7279
+ }
7280
+ };
7281
+ TotpMultiFactorGenerator.FACTOR_ID = "totp";
7282
+ var TotpMultiFactorAssertionImpl = class _TotpMultiFactorAssertionImpl extends MultiFactorAssertionImpl {
7283
+ constructor(otp, enrollmentId, secret) {
7284
+ super(
7285
+ "totp"
7286
+ /* FactorId.TOTP */
7287
+ );
7288
+ this.otp = otp;
7289
+ this.enrollmentId = enrollmentId;
7290
+ this.secret = secret;
7291
+ }
7292
+ /** @internal */
7293
+ static _fromSecret(secret, otp) {
7294
+ return new _TotpMultiFactorAssertionImpl(otp, void 0, secret);
7295
+ }
7296
+ /** @internal */
7297
+ static _fromEnrollmentId(enrollmentId, otp) {
7298
+ return new _TotpMultiFactorAssertionImpl(otp, enrollmentId);
7299
+ }
7300
+ /** @internal */
7301
+ async _finalizeEnroll(auth2, idToken, displayName) {
7302
+ _assert(
7303
+ typeof this.secret !== "undefined",
7304
+ auth2,
7305
+ "argument-error"
7306
+ /* AuthErrorCode.ARGUMENT_ERROR */
7307
+ );
7308
+ return finalizeEnrollTotpMfa(auth2, {
7309
+ idToken,
7310
+ displayName,
7311
+ totpVerificationInfo: this.secret._makeTotpVerificationInfo(this.otp)
7312
+ });
7313
+ }
7314
+ /** @internal */
7315
+ async _finalizeSignIn(auth2, mfaPendingCredential) {
7316
+ _assert(
7317
+ this.enrollmentId !== void 0 && this.otp !== void 0,
7318
+ auth2,
7319
+ "argument-error"
7320
+ /* AuthErrorCode.ARGUMENT_ERROR */
7321
+ );
7322
+ const totpVerificationInfo = { verificationCode: this.otp };
7323
+ return finalizeSignInTotpMfa(auth2, {
7324
+ mfaPendingCredential,
7325
+ mfaEnrollmentId: this.enrollmentId,
7326
+ totpVerificationInfo
7327
+ });
7328
+ }
7329
+ };
7330
+ var TotpSecret = class _TotpSecret {
7331
+ // The public members are declared outside the constructor so the docs can be generated.
7332
+ constructor(secretKey, hashingAlgorithm, codeLength, codeIntervalSeconds, enrollmentCompletionDeadline, sessionInfo, auth2) {
7333
+ this.sessionInfo = sessionInfo;
7334
+ this.auth = auth2;
7335
+ this.secretKey = secretKey;
7336
+ this.hashingAlgorithm = hashingAlgorithm;
7337
+ this.codeLength = codeLength;
7338
+ this.codeIntervalSeconds = codeIntervalSeconds;
7339
+ this.enrollmentCompletionDeadline = enrollmentCompletionDeadline;
7340
+ }
7341
+ /** @internal */
7342
+ static _fromStartTotpMfaEnrollmentResponse(response, auth2) {
7343
+ return new _TotpSecret(response.totpSessionInfo.sharedSecretKey, response.totpSessionInfo.hashingAlgorithm, response.totpSessionInfo.verificationCodeLength, response.totpSessionInfo.periodSec, new Date(response.totpSessionInfo.finalizeEnrollmentTime).toUTCString(), response.totpSessionInfo.sessionInfo, auth2);
7344
+ }
7345
+ /** @internal */
7346
+ _makeTotpVerificationInfo(otp) {
7347
+ return { sessionInfo: this.sessionInfo, verificationCode: otp };
7348
+ }
7349
+ /**
7350
+ * Returns a QR code URL as described in
7351
+ * https://github.com/google/google-authenticator/wiki/Key-Uri-Format
7352
+ * This can be displayed to the user as a QR code to be scanned into a TOTP app like Google Authenticator.
7353
+ * If the optional parameters are unspecified, an accountName of <userEmail> and issuer of <firebaseAppName> are used.
7354
+ *
7355
+ * @param accountName the name of the account/app along with a user identifier.
7356
+ * @param issuer issuer of the TOTP (likely the app name).
7357
+ * @returns A QR code URL string.
7358
+ */
7359
+ generateQrCodeUrl(accountName, issuer) {
7360
+ var _a;
7361
+ let useDefaults = false;
7362
+ if (_isEmptyString(accountName) || _isEmptyString(issuer)) {
7363
+ useDefaults = true;
7364
+ }
7365
+ if (useDefaults) {
7366
+ if (_isEmptyString(accountName)) {
7367
+ accountName = ((_a = this.auth.currentUser) === null || _a === void 0 ? void 0 : _a.email) || "unknownuser";
7368
+ }
7369
+ if (_isEmptyString(issuer)) {
7370
+ issuer = this.auth.name;
7371
+ }
7372
+ }
7373
+ return `otpauth://totp/${issuer}:${accountName}?secret=${this.secretKey}&issuer=${issuer}&algorithm=${this.hashingAlgorithm}&digits=${this.codeLength}`;
7374
+ }
7375
+ };
7376
+ function _isEmptyString(input) {
7377
+ return typeof input === "undefined" || (input === null || input === void 0 ? void 0 : input.length) === 0;
7378
+ }
6805
7379
  var name3 = "@firebase/auth";
6806
- var version3 = "0.21.4";
7380
+ var version3 = "1.3.0";
6807
7381
  var AuthInterop = class {
6808
7382
  constructor(auth2) {
6809
7383
  this.auth = auth2;
@@ -6879,25 +7453,21 @@
6879
7453
  (container, { options: deps }) => {
6880
7454
  const app2 = container.getProvider("app").getImmediate();
6881
7455
  const heartbeatServiceProvider = container.getProvider("heartbeat");
7456
+ const appCheckServiceProvider = container.getProvider("app-check-internal");
6882
7457
  const { apiKey, authDomain } = app2.options;
6883
- return ((app3, heartbeatServiceProvider2) => {
6884
- _assert(apiKey && !apiKey.includes(":"), "invalid-api-key", { appName: app3.name });
6885
- _assert(!(authDomain === null || authDomain === void 0 ? void 0 : authDomain.includes(":")), "argument-error", {
6886
- appName: app3.name
6887
- });
6888
- const config = {
6889
- apiKey,
6890
- authDomain,
6891
- clientPlatform,
6892
- apiHost: "identitytoolkit.googleapis.com",
6893
- tokenApiHost: "securetoken.googleapis.com",
6894
- apiScheme: "https",
6895
- sdkClientVersion: _getClientVersion(clientPlatform)
6896
- };
6897
- const authInstance = new AuthImpl(app3, heartbeatServiceProvider2, config);
6898
- _initializeAuthInstance(authInstance, deps);
6899
- return authInstance;
6900
- })(app2, heartbeatServiceProvider);
7458
+ _assert(apiKey && !apiKey.includes(":"), "invalid-api-key", { appName: app2.name });
7459
+ const config = {
7460
+ apiKey,
7461
+ authDomain,
7462
+ clientPlatform,
7463
+ apiHost: "identitytoolkit.googleapis.com",
7464
+ tokenApiHost: "securetoken.googleapis.com",
7465
+ apiScheme: "https",
7466
+ sdkClientVersion: _getClientVersion(clientPlatform)
7467
+ };
7468
+ const authInstance = new AuthImpl(app2, heartbeatServiceProvider, appCheckServiceProvider, config);
7469
+ _initializeAuthInstance(authInstance, deps);
7470
+ return authInstance;
6901
7471
  },
6902
7472
  "PUBLIC"
6903
7473
  /* ComponentType.PUBLIC */
@@ -7527,7 +8097,7 @@ firebase/app/dist/esm/index.esm.js:
7527
8097
  * limitations under the License.
7528
8098
  *)
7529
8099
 
7530
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8100
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7531
8101
  (**
7532
8102
  * @license
7533
8103
  * Copyright 2021 Google LLC
@@ -7545,7 +8115,7 @@ firebase/app/dist/esm/index.esm.js:
7545
8115
  * limitations under the License.
7546
8116
  *)
7547
8117
 
7548
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8118
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7549
8119
  (**
7550
8120
  * @license
7551
8121
  * Copyright 2020 Google LLC
@@ -7563,7 +8133,7 @@ firebase/app/dist/esm/index.esm.js:
7563
8133
  * limitations under the License.
7564
8134
  *)
7565
8135
 
7566
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8136
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7567
8137
  (**
7568
8138
  * @license
7569
8139
  * Copyright 2020 Google LLC
@@ -7581,7 +8151,7 @@ firebase/app/dist/esm/index.esm.js:
7581
8151
  * limitations under the License.
7582
8152
  *)
7583
8153
 
7584
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8154
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7585
8155
  (**
7586
8156
  * @license
7587
8157
  * Copyright 2020 Google LLC
@@ -7599,7 +8169,43 @@ firebase/app/dist/esm/index.esm.js:
7599
8169
  * limitations under the License.
7600
8170
  *)
7601
8171
 
7602
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8172
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8173
+ (**
8174
+ * @license
8175
+ * Copyright 2020 Google LLC
8176
+ *
8177
+ * Licensed under the Apache License, Version 2.0 (the "License");
8178
+ * you may not use this file except in compliance with the License.
8179
+ * You may obtain a copy of the License at
8180
+ *
8181
+ * http://www.apache.org/licenses/LICENSE-2.0
8182
+ *
8183
+ * Unless required by applicable law or agreed to in writing, software
8184
+ * distributed under the License is distributed on an "AS IS" BASIS,
8185
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
8186
+ * See the License for the specific language governing permissions and
8187
+ * limitations under the License.
8188
+ *)
8189
+
8190
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8191
+ (**
8192
+ * @license
8193
+ * Copyright 2020 Google LLC
8194
+ *
8195
+ * Licensed under the Apache License, Version 2.0 (the "License");
8196
+ * you may not use this file except in compliance with the License.
8197
+ * You may obtain a copy of the License at
8198
+ *
8199
+ * http://www.apache.org/licenses/LICENSE-2.0
8200
+ *
8201
+ * Unless required by applicable law or agreed to in writing, software
8202
+ * distributed under the License is distributed on an "AS IS" BASIS,
8203
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
8204
+ * See the License for the specific language governing permissions and
8205
+ * limitations under the License.
8206
+ *)
8207
+
8208
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7603
8209
  (**
7604
8210
  * @license
7605
8211
  * Copyright 2020 Google LLC
@@ -7633,7 +8239,7 @@ firebase/app/dist/esm/index.esm.js:
7633
8239
  * limitations under the License.
7634
8240
  *)
7635
8241
 
7636
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8242
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7637
8243
  (**
7638
8244
  * @license
7639
8245
  * Copyright 2020 Google LLC
@@ -7666,8 +8272,42 @@ firebase/app/dist/esm/index.esm.js:
7666
8272
  * See the License for the specific language governing permissions and
7667
8273
  * limitations under the License.
7668
8274
  *)
8275
+ (**
8276
+ * @license
8277
+ * Copyright 2023 Google LLC
8278
+ *
8279
+ * Licensed under the Apache License, Version 2.0 (the "License");
8280
+ * you may not use this file except in compliance with the License.
8281
+ * You may obtain a copy of the License at
8282
+ *
8283
+ * http://www.apache.org/licenses/LICENSE-2.0
8284
+ *
8285
+ * Unless required by applicable law or agreed to in writing, software
8286
+ * distributed under the License is distributed on an "AS IS" BASIS,
8287
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
8288
+ * See the License for the specific language governing permissions and
8289
+ * limitations under the License.
8290
+ *)
8291
+
8292
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8293
+ (**
8294
+ * @license
8295
+ * Copyright 2020 Google LLC
8296
+ *
8297
+ * Licensed under the Apache License, Version 2.0 (the "License");
8298
+ * you may not use this file except in compliance with the License.
8299
+ * You may obtain a copy of the License at
8300
+ *
8301
+ * http://www.apache.org/licenses/LICENSE-2.0
8302
+ *
8303
+ * Unless required by applicable law or agreed to in writing, software
8304
+ * distributed under the License is distributed on an "AS IS" BASIS,
8305
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
8306
+ * See the License for the specific language governing permissions and
8307
+ * limitations under the License.
8308
+ *)
7669
8309
 
7670
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8310
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7671
8311
  (**
7672
8312
  * @license
7673
8313
  * Copyright 2020 Google LLC
@@ -7685,7 +8325,7 @@ firebase/app/dist/esm/index.esm.js:
7685
8325
  * limitations under the License.
7686
8326
  *)
7687
8327
 
7688
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8328
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7689
8329
  (**
7690
8330
  * @license
7691
8331
  * Copyright 2020 Google LLC
@@ -7703,7 +8343,7 @@ firebase/app/dist/esm/index.esm.js:
7703
8343
  * limitations under the License.
7704
8344
  *)
7705
8345
 
7706
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8346
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7707
8347
  (**
7708
8348
  * @license
7709
8349
  * Copyright 2020 Google LLC
@@ -7737,7 +8377,7 @@ firebase/app/dist/esm/index.esm.js:
7737
8377
  * limitations under the License.
7738
8378
  *)
7739
8379
 
7740
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8380
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7741
8381
  (**
7742
8382
  * @license
7743
8383
  * Copyright 2020 Google LLC
@@ -7755,7 +8395,7 @@ firebase/app/dist/esm/index.esm.js:
7755
8395
  * limitations under the License.
7756
8396
  *)
7757
8397
 
7758
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8398
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7759
8399
  (**
7760
8400
  * @license
7761
8401
  * Copyright 2020 Google LLC
@@ -7773,7 +8413,7 @@ firebase/app/dist/esm/index.esm.js:
7773
8413
  * limitations under the License.
7774
8414
  *)
7775
8415
 
7776
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8416
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7777
8417
  (**
7778
8418
  * @license
7779
8419
  * Copyright 2020 Google LLC
@@ -7791,7 +8431,7 @@ firebase/app/dist/esm/index.esm.js:
7791
8431
  * limitations under the License.
7792
8432
  *)
7793
8433
 
7794
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8434
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7795
8435
  (**
7796
8436
  * @license
7797
8437
  * Copyright 2020 Google LLC
@@ -7809,7 +8449,7 @@ firebase/app/dist/esm/index.esm.js:
7809
8449
  * limitations under the License.
7810
8450
  *)
7811
8451
 
7812
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8452
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7813
8453
  (**
7814
8454
  * @license
7815
8455
  * Copyright 2020 Google LLC
@@ -7827,7 +8467,7 @@ firebase/app/dist/esm/index.esm.js:
7827
8467
  * limitations under the License.
7828
8468
  *)
7829
8469
 
7830
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8470
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7831
8471
  (**
7832
8472
  * @license
7833
8473
  * Copyright 2019 Google LLC
@@ -7845,7 +8485,7 @@ firebase/app/dist/esm/index.esm.js:
7845
8485
  * limitations under the License.
7846
8486
  *)
7847
8487
 
7848
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8488
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7849
8489
  (**
7850
8490
  * @license
7851
8491
  * Copyright 2019 Google LLC
@@ -7879,7 +8519,7 @@ firebase/app/dist/esm/index.esm.js:
7879
8519
  * limitations under the License.
7880
8520
  *)
7881
8521
 
7882
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8522
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7883
8523
  (**
7884
8524
  * @license
7885
8525
  * Copyright 2020 Google LLC
@@ -7897,7 +8537,7 @@ firebase/app/dist/esm/index.esm.js:
7897
8537
  * limitations under the License.
7898
8538
  *)
7899
8539
 
7900
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8540
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7901
8541
  (**
7902
8542
  * @license
7903
8543
  * Copyright 2020 Google LLC
@@ -7915,7 +8555,7 @@ firebase/app/dist/esm/index.esm.js:
7915
8555
  * limitations under the License.
7916
8556
  *)
7917
8557
 
7918
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8558
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7919
8559
  (**
7920
8560
  * @license
7921
8561
  * Copyright 2020 Google LLC
@@ -7933,7 +8573,7 @@ firebase/app/dist/esm/index.esm.js:
7933
8573
  * limitations under the License.
7934
8574
  *)
7935
8575
 
7936
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8576
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7937
8577
  (**
7938
8578
  * @license
7939
8579
  * Copyright 2020 Google LLC
@@ -7951,7 +8591,7 @@ firebase/app/dist/esm/index.esm.js:
7951
8591
  * limitations under the License.
7952
8592
  *)
7953
8593
 
7954
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8594
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7955
8595
  (**
7956
8596
  * @license
7957
8597
  * Copyright 2020 Google LLC
@@ -7969,7 +8609,7 @@ firebase/app/dist/esm/index.esm.js:
7969
8609
  * limitations under the License.
7970
8610
  *)
7971
8611
 
7972
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8612
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7973
8613
  (**
7974
8614
  * @license
7975
8615
  * Copyright 2020 Google LLC
@@ -7987,7 +8627,7 @@ firebase/app/dist/esm/index.esm.js:
7987
8627
  * limitations under the License.
7988
8628
  *)
7989
8629
 
7990
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8630
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
7991
8631
  (**
7992
8632
  * @license
7993
8633
  * Copyright 2020 Google LLC
@@ -8005,7 +8645,7 @@ firebase/app/dist/esm/index.esm.js:
8005
8645
  * limitations under the License.
8006
8646
  *)
8007
8647
 
8008
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8648
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8009
8649
  (**
8010
8650
  * @license
8011
8651
  * Copyright 2020 Google LLC
@@ -8023,7 +8663,7 @@ firebase/app/dist/esm/index.esm.js:
8023
8663
  * limitations under the License.
8024
8664
  *)
8025
8665
 
8026
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8666
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8027
8667
  (**
8028
8668
  * @license
8029
8669
  * Copyright 2020 Google LLC
@@ -8041,7 +8681,7 @@ firebase/app/dist/esm/index.esm.js:
8041
8681
  * limitations under the License.
8042
8682
  *)
8043
8683
 
8044
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8684
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8045
8685
  (**
8046
8686
  * @license
8047
8687
  * Copyright 2020 Google LLC
@@ -8059,7 +8699,7 @@ firebase/app/dist/esm/index.esm.js:
8059
8699
  * limitations under the License.
8060
8700
  *)
8061
8701
 
8062
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8702
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8063
8703
  (**
8064
8704
  * @license
8065
8705
  * Copyright 2019 Google LLC
@@ -8077,7 +8717,7 @@ firebase/app/dist/esm/index.esm.js:
8077
8717
  * limitations under the License.
8078
8718
  *)
8079
8719
 
8080
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8720
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8081
8721
  (**
8082
8722
  * @license
8083
8723
  * Copyright 2020 Google LLC
@@ -8095,7 +8735,7 @@ firebase/app/dist/esm/index.esm.js:
8095
8735
  * limitations under the License.
8096
8736
  *)
8097
8737
 
8098
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8738
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8099
8739
  (**
8100
8740
  * @license
8101
8741
  * Copyright 2020 Google LLC
@@ -8113,7 +8753,7 @@ firebase/app/dist/esm/index.esm.js:
8113
8753
  * limitations under the License.
8114
8754
  *)
8115
8755
 
8116
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8756
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8117
8757
  (**
8118
8758
  * @license
8119
8759
  * Copyright 2020 Google LLC
@@ -8131,10 +8771,10 @@ firebase/app/dist/esm/index.esm.js:
8131
8771
  * limitations under the License.
8132
8772
  *)
8133
8773
 
8134
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8774
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8135
8775
  (**
8136
8776
  * @license
8137
- * Copyright 2019 Google LLC
8777
+ * Copyright 2020 Google LLC
8138
8778
  *
8139
8779
  * Licensed under the Apache License, Version 2.0 (the "License");
8140
8780
  * you may not use this file except in compliance with the License.
@@ -8148,9 +8788,11 @@ firebase/app/dist/esm/index.esm.js:
8148
8788
  * See the License for the specific language governing permissions and
8149
8789
  * limitations under the License.
8150
8790
  *)
8791
+
8792
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8151
8793
  (**
8152
8794
  * @license
8153
- * Copyright 2020 Google LLC
8795
+ * Copyright 2019 Google LLC
8154
8796
  *
8155
8797
  * Licensed under the Apache License, Version 2.0 (the "License");
8156
8798
  * you may not use this file except in compliance with the License.
@@ -8166,7 +8808,7 @@ firebase/app/dist/esm/index.esm.js:
8166
8808
  *)
8167
8809
  (**
8168
8810
  * @license
8169
- * Copyright 2020 Google LLC.
8811
+ * Copyright 2020 Google LLC
8170
8812
  *
8171
8813
  * Licensed under the Apache License, Version 2.0 (the "License");
8172
8814
  * you may not use this file except in compliance with the License.
@@ -8180,11 +8822,9 @@ firebase/app/dist/esm/index.esm.js:
8180
8822
  * See the License for the specific language governing permissions and
8181
8823
  * limitations under the License.
8182
8824
  *)
8183
-
8184
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8185
8825
  (**
8186
8826
  * @license
8187
- * Copyright 2020 Google LLC
8827
+ * Copyright 2020 Google LLC.
8188
8828
  *
8189
8829
  * Licensed under the Apache License, Version 2.0 (the "License");
8190
8830
  * you may not use this file except in compliance with the License.
@@ -8199,7 +8839,7 @@ firebase/app/dist/esm/index.esm.js:
8199
8839
  * limitations under the License.
8200
8840
  *)
8201
8841
 
8202
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8842
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8203
8843
  (**
8204
8844
  * @license
8205
8845
  * Copyright 2020 Google LLC
@@ -8217,7 +8857,7 @@ firebase/app/dist/esm/index.esm.js:
8217
8857
  * limitations under the License.
8218
8858
  *)
8219
8859
 
8220
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8860
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8221
8861
  (**
8222
8862
  * @license
8223
8863
  * Copyright 2020 Google LLC
@@ -8235,7 +8875,7 @@ firebase/app/dist/esm/index.esm.js:
8235
8875
  * limitations under the License.
8236
8876
  *)
8237
8877
 
8238
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8878
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8239
8879
  (**
8240
8880
  * @license
8241
8881
  * Copyright 2020 Google LLC
@@ -8253,7 +8893,7 @@ firebase/app/dist/esm/index.esm.js:
8253
8893
  * limitations under the License.
8254
8894
  *)
8255
8895
 
8256
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8896
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8257
8897
  (**
8258
8898
  * @license
8259
8899
  * Copyright 2020 Google LLC
@@ -8303,7 +8943,7 @@ firebase/app/dist/esm/index.esm.js:
8303
8943
  * limitations under the License.
8304
8944
  *)
8305
8945
 
8306
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8946
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8307
8947
  (**
8308
8948
  * @license
8309
8949
  * Copyright 2020 Google LLC
@@ -8321,7 +8961,7 @@ firebase/app/dist/esm/index.esm.js:
8321
8961
  * limitations under the License.
8322
8962
  *)
8323
8963
 
8324
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8964
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8325
8965
  (**
8326
8966
  * @license
8327
8967
  * Copyright 2020 Google LLC
@@ -8339,7 +8979,7 @@ firebase/app/dist/esm/index.esm.js:
8339
8979
  * limitations under the License.
8340
8980
  *)
8341
8981
 
8342
- @firebase/auth/dist/esm2017/index-e3f1fbba.js:
8982
+ @firebase/auth/dist/esm2017/index-9a76d29a.js:
8343
8983
  (**
8344
8984
  * @license
8345
8985
  * Copyright 2020 Google LLC