@firebase/firestore 3.4.8-canary.5ce067663 → 3.4.8-canary.63caee2a5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. package/dist/firestore/lite/index.d.ts +1 -0
  2. package/dist/firestore/src/api/transaction.d.ts +2 -1
  3. package/dist/firestore/src/api/transaction_options.d.ts +17 -0
  4. package/dist/firestore/src/api.d.ts +1 -0
  5. package/dist/firestore/src/core/firestore_client.d.ts +2 -1
  6. package/dist/firestore/src/core/transaction_options.d.ts +25 -0
  7. package/dist/firestore/src/core/transaction_runner.d.ts +3 -2
  8. package/dist/firestore/src/lite-api/transaction.d.ts +2 -1
  9. package/dist/firestore/src/lite-api/transaction_options.d.ts +23 -0
  10. package/dist/index.d.ts +24 -1
  11. package/dist/index.esm2017.js +224 -200
  12. package/dist/index.esm2017.js.map +1 -1
  13. package/dist/index.esm5.js +158 -135
  14. package/dist/index.esm5.js.map +1 -1
  15. package/dist/index.node.cjs.js +36 -9
  16. package/dist/index.node.cjs.js.map +1 -1
  17. package/dist/index.node.mjs +36 -9
  18. package/dist/index.node.mjs.map +1 -1
  19. package/dist/index.rn.js +95 -71
  20. package/dist/index.rn.js.map +1 -1
  21. package/dist/internal.d.ts +25 -1
  22. package/dist/lite/firestore/lite/index.d.ts +1 -0
  23. package/dist/lite/firestore/src/api/transaction.d.ts +2 -1
  24. package/dist/lite/firestore/src/api/transaction_options.d.ts +17 -0
  25. package/dist/lite/firestore/src/api.d.ts +1 -0
  26. package/dist/lite/firestore/src/core/firestore_client.d.ts +2 -1
  27. package/dist/lite/firestore/src/core/transaction_options.d.ts +25 -0
  28. package/dist/lite/firestore/src/core/transaction_runner.d.ts +3 -2
  29. package/dist/lite/firestore/src/lite-api/transaction.d.ts +2 -1
  30. package/dist/lite/firestore/src/lite-api/transaction_options.d.ts +23 -0
  31. package/dist/lite/index.browser.esm2017.js +246 -223
  32. package/dist/lite/index.browser.esm2017.js.map +1 -1
  33. package/dist/lite/index.browser.esm5.js +118 -116
  34. package/dist/lite/index.browser.esm5.js.map +1 -1
  35. package/dist/lite/index.d.ts +24 -1
  36. package/dist/lite/index.node.cjs.js +34 -7
  37. package/dist/lite/index.node.cjs.js.map +1 -1
  38. package/dist/lite/index.node.mjs +34 -7
  39. package/dist/lite/index.node.mjs.map +1 -1
  40. package/dist/lite/index.rn.esm2017.js +127 -104
  41. package/dist/lite/index.rn.esm2017.js.map +1 -1
  42. package/dist/lite/internal.d.ts +25 -1
  43. package/dist/lite/packages/firestore/dist/lite/index.browser.esm2017.d.ts +28 -28
  44. package/dist/lite/packages/firestore/lite/index.d.ts +1 -0
  45. package/dist/lite/packages/firestore/src/api/transaction.d.ts +2 -1
  46. package/dist/lite/packages/firestore/src/api/transaction_options.d.ts +17 -0
  47. package/dist/lite/packages/firestore/src/api.d.ts +1 -0
  48. package/dist/lite/packages/firestore/src/core/firestore_client.d.ts +2 -1
  49. package/dist/lite/packages/firestore/src/core/transaction_options.d.ts +25 -0
  50. package/dist/lite/packages/firestore/src/core/transaction_runner.d.ts +3 -2
  51. package/dist/lite/packages/firestore/src/lite-api/transaction.d.ts +2 -1
  52. package/dist/lite/packages/firestore/src/lite-api/transaction_options.d.ts +23 -0
  53. package/dist/lite/private.d.ts +25 -1
  54. package/dist/packages/firestore/dist/index.esm2017.d.ts +37 -36
  55. package/dist/packages/firestore/lite/index.d.ts +1 -0
  56. package/dist/packages/firestore/src/api/transaction.d.ts +2 -1
  57. package/dist/packages/firestore/src/api/transaction_options.d.ts +17 -0
  58. package/dist/packages/firestore/src/api.d.ts +1 -0
  59. package/dist/packages/firestore/src/core/firestore_client.d.ts +2 -1
  60. package/dist/packages/firestore/src/core/transaction_options.d.ts +25 -0
  61. package/dist/packages/firestore/src/core/transaction_runner.d.ts +3 -2
  62. package/dist/packages/firestore/src/lite-api/transaction.d.ts +2 -1
  63. package/dist/packages/firestore/src/lite-api/transaction_options.d.ts +23 -0
  64. package/dist/private.d.ts +25 -1
  65. package/package.json +10 -10
@@ -70,7 +70,7 @@ V.MOCK_USER = new V("mock-user");
70
70
  * See the License for the specific language governing permissions and
71
71
  * limitations under the License.
72
72
  */
73
- var P = "9.7.0-canary.5ce067663", O = new l("@firebase/firestore");
73
+ var P = "9.7.0-canary.63caee2a5", O = new l("@firebase/firestore");
74
74
 
75
75
  /**
76
76
  * @license
@@ -5242,7 +5242,7 @@ function Ur(t) {
5242
5242
  }), t.prototype.abort = function(t) {
5243
5243
  t && this.At.reject(t), this.aborted || (U("SimpleDb", "Aborting transaction:", t ? t.message : "Client-initiated abort"),
5244
5244
  this.aborted = !0, this.transaction.abort());
5245
- }, t.prototype.Pt = function() {
5245
+ }, t.prototype.bt = function() {
5246
5246
  // If the browser supports V3 IndexedDB, we invoke commit() explicitly to
5247
5247
  // speed up index DB processing if the event loop remains blocks.
5248
5248
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
@@ -5273,7 +5273,7 @@ function Ur(t) {
5273
5273
  * objectstores.
5274
5274
  */
5275
5275
  function t(e, n, r) {
5276
- this.name = e, this.version = n, this.bt = r,
5276
+ this.name = e, this.version = n, this.Pt = r,
5277
5277
  // NOTE: According to https://bugs.webkit.org/show_bug.cgi?id=197050, the
5278
5278
  // bug we're checking for should exist in iOS >= 12.2 and < 13, but for
5279
5279
  // whatever reason it's much harder to hit after 12.2 so we only proactively
@@ -5355,7 +5355,7 @@ function Ur(t) {
5355
5355
  }, i.onupgradeneeded = function(t) {
5356
5356
  U("SimpleDb", 'Database "' + n.name + '" requires upgrade from version:', t.oldVersion);
5357
5357
  var e = t.target.result;
5358
- n.bt.kt(e, i.transaction, t.oldVersion, n.version).next((function() {
5358
+ n.Pt.kt(e, i.transaction, t.oldVersion, n.version).next((function() {
5359
5359
  U("SimpleDb", "Database upgrade to version " + n.version + " complete");
5360
5360
  }));
5361
5361
  };
@@ -5396,7 +5396,7 @@ function Ur(t) {
5396
5396
  // fire), but still return the original transactionFnResult back to the
5397
5397
  // caller.
5398
5398
  return a.db = r.sent(), e = yi.open(a.db, t, n ? "readonly" : "readwrite", i), s = o(e).next((function(t) {
5399
- return e.Pt(), t;
5399
+ return e.bt(), t;
5400
5400
  })).catch((function(t) {
5401
5401
  // Abort the transaction if there was an error.
5402
5402
  return e.abort(t), vi.reject(t);
@@ -6378,8 +6378,8 @@ var Xi = /** @class */ function() {
6378
6378
  * Writes the "infinity" byte sequence that sorts after all other byte
6379
6379
  * sequences written in ascending order.
6380
6380
  */
6381
- t.prototype.Pe = function() {
6382
- this.be(255), this.be(255);
6381
+ t.prototype.be = function() {
6382
+ this.Pe(255), this.Pe(255);
6383
6383
  },
6384
6384
  /**
6385
6385
  * Writes the "infinity" byte sequence that sorts before all other byte
@@ -6423,16 +6423,16 @@ var Xi = /** @class */ function() {
6423
6423
  },
6424
6424
  /** Writes a single byte ascending to the buffer. */ t.prototype._e = function(t) {
6425
6425
  var e = 255 & t;
6426
- 0 === e ? (this.be(0), this.be(255)) : 255 === e ? (this.be(255), this.be(0)) : this.be(e);
6426
+ 0 === e ? (this.Pe(0), this.Pe(255)) : 255 === e ? (this.Pe(255), this.Pe(0)) : this.Pe(e);
6427
6427
  },
6428
6428
  /** Writes a single byte descending to the buffer. */ t.prototype.ge = function(t) {
6429
6429
  var e = 255 & t;
6430
6430
  0 === e ? (this.ve(0), this.ve(255)) : 255 === e ? (this.ve(255), this.ve(0)) : this.ve(t);
6431
6431
  }, t.prototype.we = function() {
6432
- this.be(0), this.be(1);
6432
+ this.Pe(0), this.Pe(1);
6433
6433
  }, t.prototype.ye = function() {
6434
6434
  this.ve(0), this.ve(1);
6435
- }, t.prototype.be = function(t) {
6435
+ }, t.prototype.Pe = function(t) {
6436
6436
  this.Ae(1), this.buffer[this.position++] = t;
6437
6437
  }, t.prototype.ve = function(t) {
6438
6438
  this.Ae(1), this.buffer[this.position++] = ~t;
@@ -6460,7 +6460,7 @@ var Xi = /** @class */ function() {
6460
6460
  }, t.prototype.se = function(t) {
6461
6461
  this.De.Te(t);
6462
6462
  }, t.prototype.ee = function() {
6463
- this.De.Pe();
6463
+ this.De.be();
6464
6464
  }, t;
6465
6465
  }(), $i = /** @class */ function() {
6466
6466
  function t(t) {
@@ -7939,10 +7939,10 @@ function So(t) {
7939
7939
  function t(t) {
7940
7940
  this.An = t, this.buffer = new we(Ao), this.Rn = 0;
7941
7941
  }
7942
- return t.prototype.Pn = function() {
7942
+ return t.prototype.bn = function() {
7943
7943
  return ++this.Rn;
7944
- }, t.prototype.bn = function(t) {
7945
- var e = [ t, this.Pn() ];
7944
+ }, t.prototype.Pn = function(t) {
7945
+ var e = [ t, this.bn() ];
7946
7946
  if (this.buffer.size < this.An) this.buffer = this.buffer.add(e); else {
7947
7947
  var n = this.buffer.last();
7948
7948
  Ao(e, n) < 0 && (this.buffer = this.buffer.delete(n).add(e));
@@ -8026,10 +8026,10 @@ function So(t) {
8026
8026
  if (0 === e) return vi.resolve(ut.A);
8027
8027
  var r = new xo(e);
8028
8028
  return this.Dn.forEachTarget(t, (function(t) {
8029
- return r.bn(t.sequenceNumber);
8029
+ return r.Pn(t.sequenceNumber);
8030
8030
  })).next((function() {
8031
8031
  return n.Dn.xn(t, (function(t) {
8032
- return r.bn(t);
8032
+ return r.Pn(t);
8033
8033
  }));
8034
8034
  })).next((function() {
8035
8035
  return r.maxValue;
@@ -9072,7 +9072,7 @@ var jo = "Failed to obtain exclusive access to the persistence layer. To allow s
9072
9072
  })).next((function(n) {
9073
9073
  return t.isPrimary && !n ? t.Rs(e).next((function() {
9074
9074
  return !1;
9075
- })) : !!n && t.Ps(e).next((function() {
9075
+ })) : !!n && t.bs(e).next((function() {
9076
9076
  return !0;
9077
9077
  }));
9078
9078
  }));
@@ -9092,7 +9092,7 @@ var jo = "Failed to obtain exclusive access to the persistence layer. To allow s
9092
9092
  }, t.prototype.Es = function(t) {
9093
9093
  var e = this;
9094
9094
  return Qo(t).get("owner").next((function(t) {
9095
- return vi.resolve(e.bs(t));
9095
+ return vi.resolve(e.Ps(t));
9096
9096
  }));
9097
9097
  }, t.prototype.Vs = function(t) {
9098
9098
  return Wo(t).delete(this.clientId);
@@ -9155,7 +9155,7 @@ var jo = "Failed to obtain exclusive access to the persistence layer. To allow s
9155
9155
  }));
9156
9156
  }));
9157
9157
  },
9158
- /** Checks whether `client` is the local client. */ t.prototype.bs = function(t) {
9158
+ /** Checks whether `client` is the local client. */ t.prototype.Ps = function(t) {
9159
9159
  return !!t && t.ownerId === this.clientId;
9160
9160
  },
9161
9161
  /**
@@ -9178,8 +9178,8 @@ var jo = "Failed to obtain exclusive access to the persistence layer. To allow s
9178
9178
  // the foreground.
9179
9179
  // - the `forceOwningTab` setting was passed in.
9180
9180
  if (null !== n && e.Ss(n.leaseTimestampMs, 5e3) && !e.xs(n.ownerId)) {
9181
- if (e.bs(n) && e.networkEnabled) return !0;
9182
- if (!e.bs(n)) {
9181
+ if (e.Ps(n) && e.networkEnabled) return !0;
9182
+ if (!e.Ps(n)) {
9183
9183
  if (!n.allowTabSynchronization)
9184
9184
  // Fail the `canActAsPrimary` check if the current leaseholder has
9185
9185
  // not opted into multi-tab synchronization. If this happens at
@@ -9301,7 +9301,7 @@ var jo = "Failed to obtain exclusive access to the persistence layer. To allow s
9301
9301
  })), new Y(H.FAILED_PRECONDITION, di);
9302
9302
  return n(o);
9303
9303
  })).next((function(t) {
9304
- return r.Ps(o).next((function() {
9304
+ return r.bs(o).next((function() {
9305
9305
  return t;
9306
9306
  }));
9307
9307
  })) : r.$s(o).next((function() {
@@ -9320,14 +9320,14 @@ var jo = "Failed to obtain exclusive access to the persistence layer. To allow s
9320
9320
  t.prototype.$s = function(t) {
9321
9321
  var e = this;
9322
9322
  return Qo(t).get("owner").next((function(t) {
9323
- if (null !== t && e.Ss(t.leaseTimestampMs, 5e3) && !e.xs(t.ownerId) && !e.bs(t) && !(e.Zn || e.allowTabSynchronization && t.allowTabSynchronization)) throw new Y(H.FAILED_PRECONDITION, jo);
9323
+ if (null !== t && e.Ss(t.leaseTimestampMs, 5e3) && !e.xs(t.ownerId) && !e.Ps(t) && !(e.Zn || e.allowTabSynchronization && t.allowTabSynchronization)) throw new Y(H.FAILED_PRECONDITION, jo);
9324
9324
  }));
9325
9325
  },
9326
9326
  /**
9327
9327
  * Obtains or extends the new primary lease for the local client. This
9328
9328
  * method does not verify that the client is eligible for this lease.
9329
9329
  */
9330
- t.prototype.Ps = function(t) {
9330
+ t.prototype.bs = function(t) {
9331
9331
  var e = {
9332
9332
  ownerId: this.clientId,
9333
9333
  allowTabSynchronization: this.allowTabSynchronization,
@@ -9340,7 +9340,7 @@ var jo = "Failed to obtain exclusive access to the persistence layer. To allow s
9340
9340
  /** Checks the primary lease and removes it if we are the current primary. */ t.prototype.Rs = function(t) {
9341
9341
  var e = this, n = Qo(t);
9342
9342
  return n.get("owner").next((function(t) {
9343
- return e.bs(t) ? (U("IndexedDbPersistence", "Releasing primary lease."), n.delete("owner")) : vi.resolve();
9343
+ return e.Ps(t) ? (U("IndexedDbPersistence", "Releasing primary lease."), n.delete("owner")) : vi.resolve();
9344
9344
  }));
9345
9345
  },
9346
9346
  /** Verifies that `updateTimeMs` is within `maxAgeMs`. */ t.prototype.Ss = function(t, e) {
@@ -10414,7 +10414,7 @@ function hu(t, e, n) {
10414
10414
  var n = new mu(t, e);
10415
10415
  this.Ti = this.Ti.add(n), this.Ai = this.Ai.add(n);
10416
10416
  },
10417
- /** Add references to the given document keys for the given ID. */ t.prototype.Pi = function(t, e) {
10417
+ /** Add references to the given document keys for the given ID. */ t.prototype.bi = function(t, e) {
10418
10418
  var n = this;
10419
10419
  t.forEach((function(t) {
10420
10420
  return n.addReference(t, e);
@@ -10425,7 +10425,7 @@ function hu(t, e, n) {
10425
10425
  * ID.
10426
10426
  */
10427
10427
  t.prototype.removeReference = function(t, e) {
10428
- this.bi(new mu(t, e));
10428
+ this.Pi(new mu(t, e));
10429
10429
  }, t.prototype.Vi = function(t, e) {
10430
10430
  var n = this;
10431
10431
  t.forEach((function(t) {
@@ -10439,14 +10439,14 @@ function hu(t, e, n) {
10439
10439
  t.prototype.vi = function(t) {
10440
10440
  var e = this, n = new Pt(new gt([])), r = new mu(n, t), i = new mu(n, t + 1), o = [];
10441
10441
  return this.Ai.forEachInRange([ r, i ], (function(t) {
10442
- e.bi(t), o.push(t.key);
10442
+ e.Pi(t), o.push(t.key);
10443
10443
  })), o;
10444
10444
  }, t.prototype.Si = function() {
10445
10445
  var t = this;
10446
10446
  this.Ti.forEach((function(e) {
10447
- return t.bi(e);
10447
+ return t.Pi(e);
10448
10448
  }));
10449
- }, t.prototype.bi = function(t) {
10449
+ }, t.prototype.Pi = function(t) {
10450
10450
  this.Ti = this.Ti.delete(t), this.Ai = this.Ai.delete(t);
10451
10451
  }, t.prototype.Di = function(t) {
10452
10452
  var e = new Pt(new gt([])), n = new mu(e, t), r = new mu(e, t + 1), i = $n();
@@ -10748,7 +10748,7 @@ function hu(t, e, n) {
10748
10748
  var n = this.Li.get(e) || null;
10749
10749
  return vi.resolve(n);
10750
10750
  }, t.prototype.addMatchingKeys = function(t, e, n) {
10751
- return this.qi.Pi(e, n), vi.resolve();
10751
+ return this.qi.bi(e, n), vi.resolve();
10752
10752
  }, t.prototype.removeMatchingKeys = function(t, e, n) {
10753
10753
  this.qi.Vi(e, n);
10754
10754
  var r = this.persistence.referenceDelegate, i = [];
@@ -11156,7 +11156,7 @@ var Au = /** @class */ function() {
11156
11156
  }, t.prototype.clearQueryState = function(t) {
11157
11157
  this.removeItem(Du(this.persistenceKey, t));
11158
11158
  }, t.prototype.updateQueryState = function(t, e, n) {
11159
- this.Pr(t, e, n);
11159
+ this.br(t, e, n);
11160
11160
  }, t.prototype.handleUserChange = function(t, e, n) {
11161
11161
  var r = this;
11162
11162
  e.forEach((function(t) {
@@ -11165,7 +11165,7 @@ var Au = /** @class */ function() {
11165
11165
  r.addPendingMutation(t);
11166
11166
  }));
11167
11167
  }, t.prototype.setOnlineState = function(t) {
11168
- this.br(t);
11168
+ this.Pr(t);
11169
11169
  }, t.prototype.notifyBundleLoaded = function(t) {
11170
11170
  this.Vr(t);
11171
11171
  }, t.prototype.shutdown = function() {
@@ -11249,13 +11249,13 @@ var Au = /** @class */ function() {
11249
11249
  }, t.prototype.Ar = function(t) {
11250
11250
  var e = Nu(this.persistenceKey, this.currentUser, t);
11251
11251
  this.removeItem(e);
11252
- }, t.prototype.br = function(t) {
11252
+ }, t.prototype.Pr = function(t) {
11253
11253
  var e = {
11254
11254
  clientId: this.ir,
11255
11255
  onlineState: t
11256
11256
  };
11257
11257
  this.storage.setItem(this.mr, JSON.stringify(e));
11258
- }, t.prototype.Pr = function(t, e, n) {
11258
+ }, t.prototype.br = function(t, e, n) {
11259
11259
  var r = Du(this.persistenceKey, t), i = new xu(t, e, n);
11260
11260
  this.setItem(r, i.er());
11261
11261
  }, t.prototype.Vr = function(t) {
@@ -11786,7 +11786,7 @@ function Uu() {
11786
11786
  this.cancel();
11787
11787
  // First schedule using the current base (which may be 0 and should be
11788
11788
  // honored as such).
11789
- var n = Math.floor(this.Io + this.Po()), r = Math.max(0, Date.now() - this.Eo), i = Math.max(0, n - r);
11789
+ var n = Math.floor(this.Io + this.bo()), r = Math.max(0, Date.now() - this.Eo), i = Math.max(0, n - r);
11790
11790
  // Guard against lastAttemptTime being in the future due to a clock change.
11791
11791
  i > 0 && U("ExponentialBackoff", "Backing off for " + i + " ms (base delay: " + this.Io + " ms, delay with jitter: " + n + " ms, last attempt: " + r + " ms ago)"),
11792
11792
  this.To = this.Yn.enqueueAfterDelay(this.timerId, i, (function() {
@@ -11795,12 +11795,12 @@ function Uu() {
11795
11795
  // Apply backoff factor to determine next delay and ensure it is within
11796
11796
  // bounds.
11797
11797
  this.Io *= this.yo, this.Io < this.mo && (this.Io = this.mo), this.Io > this.po && (this.Io = this.po);
11798
- }, t.prototype.bo = function() {
11798
+ }, t.prototype.Po = function() {
11799
11799
  null !== this.To && (this.To.skipDelay(), this.To = null);
11800
11800
  }, t.prototype.cancel = function() {
11801
11801
  null !== this.To && (this.To.cancel(), this.To = null);
11802
11802
  },
11803
- /** Returns a random value in the range [-currentBaseMs/2, currentBaseMs/2] */ t.prototype.Po = function() {
11803
+ /** Returns a random value in the range [-currentBaseMs/2, currentBaseMs/2] */ t.prototype.bo = function() {
11804
11804
  return (Math.random() - .5) * this.Io;
11805
11805
  }, t;
11806
11806
  }(), ju = /** @class */ function() {
@@ -13350,7 +13350,7 @@ var Es = /** @class */ function() {
13350
13350
  }, As = function() {
13351
13351
  this.queries = new jn((function(t) {
13352
13352
  return tn(t);
13353
- }), Ze), this.onlineState = "Unknown" /* Unknown */ , this.Pu = new Set;
13353
+ }), Ze), this.onlineState = "Unknown" /* Unknown */ , this.bu = new Set;
13354
13354
  };
13355
13355
 
13356
13356
  /**
@@ -13395,7 +13395,7 @@ var Es = /** @class */ function() {
13395
13395
  case 4:
13396
13396
  return n.queries.set(i, u), u.listeners.push(e),
13397
13397
  // Run global snapshot listeners if a consistent snapshot has been emitted.
13398
- e.bu(n.onlineState), u.Ru && e.Vu(u.Ru) && Rs(n), [ 2 /*return*/ ];
13398
+ e.Pu(n.onlineState), u.Ru && e.Vu(u.Ru) && Rs(n), [ 2 /*return*/ ];
13399
13399
  }
13400
13400
  }));
13401
13401
  }));
@@ -13436,7 +13436,7 @@ function Ms(t, e, n) {
13436
13436
 
13437
13437
  // Call all global snapshot listeners that have been set.
13438
13438
  function Rs(t) {
13439
- t.Pu.forEach((function(t) {
13439
+ t.bu.forEach((function(t) {
13440
13440
  t.next();
13441
13441
  }));
13442
13442
  }
@@ -13478,7 +13478,7 @@ function Rs(t) {
13478
13478
  }, t.prototype.onError = function(t) {
13479
13479
  this.vu.error(t);
13480
13480
  },
13481
- /** Returns whether a snapshot was raised. */ t.prototype.bu = function(t) {
13481
+ /** Returns whether a snapshot was raised. */ t.prototype.Pu = function(t) {
13482
13482
  this.onlineState = t;
13483
13483
  var e = !1;
13484
13484
  return this.Du && !this.Su && this.xu(this.Du, t) && (this.Nu(this.Du), e = !0),
@@ -13809,7 +13809,7 @@ function Fs(t) {
13809
13809
  * Applies an OnlineState change to the view, potentially generating a
13810
13810
  * ViewChange if the view's syncState changes as a result.
13811
13811
  */
13812
- t.prototype.bu = function(t) {
13812
+ t.prototype.Pu = function(t) {
13813
13813
  return this.current && "Offline" /* Offline */ === t ? (
13814
13814
  // If we're offline, set `current` to false and then call applyChanges()
13815
13815
  // to refresh our syncState and generate a ViewChange as appropriate. We
@@ -14225,7 +14225,7 @@ function zs(t, e) {
14225
14225
  if (r.isPrimaryClient && 0 /* RemoteStore */ === n || !r.isPrimaryClient && 1 /* SharedClientState */ === n) {
14226
14226
  var i = [];
14227
14227
  r.ia.forEach((function(t, n) {
14228
- var r = n.view.bu(e);
14228
+ var r = n.view.Pu(e);
14229
14229
  r.snapshot && i.push(r.snapshot);
14230
14230
  })), function(t, e) {
14231
14231
  var n = W(t);
@@ -14234,7 +14234,7 @@ function zs(t, e) {
14234
14234
  n.queries.forEach((function(t, n) {
14235
14235
  for (var i = 0, o = n.listeners; i < o.length; i++) {
14236
14236
  // Run global snapshot listeners if a consistent snapshot has been emitted.
14237
- o[i].bu(e) && (r = !0);
14237
+ o[i].Pu(e) && (r = !0);
14238
14238
  }
14239
14239
  })), r && Rs(n);
14240
14240
  }(r.eventManager, e), i.length && r.sa.zo(i), r.onlineState = e, r.isPrimaryClient && r.sharedClientState.setOnlineState(e);
@@ -15425,9 +15425,9 @@ function Da(t, e) {
15425
15425
  * Internal buffer to hold bundle content, accumulating incomplete element
15426
15426
  * content.
15427
15427
  */
15428
- this.buffer = new Uint8Array, this.Pa = new TextDecoder("utf-8"),
15428
+ this.buffer = new Uint8Array, this.ba = new TextDecoder("utf-8"),
15429
15429
  // Read the metadata (which is the first element).
15430
- this.ba().then((function(t) {
15430
+ this.Pa().then((function(t) {
15431
15431
  t && t.Mu() ? n.metadata.resolve(t.payload.metadata) : n.metadata.reject(new Error("The first element of the bundle is not a metadata, it is\n " + JSON.stringify(null == t ? void 0 : t.payload)));
15432
15432
  }), (function(t) {
15433
15433
  return n.metadata.reject(t);
@@ -15450,7 +15450,7 @@ function Da(t, e) {
15450
15450
 
15451
15451
  case 1:
15452
15452
  // Makes sure metadata is read before proceeding.
15453
- return [ 2 /*return*/ , (t.sent(), this.ba()) ];
15453
+ return [ 2 /*return*/ , (t.sent(), this.Pa()) ];
15454
15454
  }
15455
15455
  }));
15456
15456
  }));
@@ -15465,7 +15465,7 @@ function Da(t, e) {
15465
15465
  * Returns either the bundled element, or null if we have reached the end of
15466
15466
  * the stream.
15467
15467
  */
15468
- t.prototype.ba = function() {
15468
+ t.prototype.Pa = function() {
15469
15469
  return n(this, void 0, void 0, (function() {
15470
15470
  var t, e, n, i;
15471
15471
  return r(this, (function(r) {
@@ -15474,7 +15474,7 @@ function Da(t, e) {
15474
15474
  return [ 4 /*yield*/ , this.Va() ];
15475
15475
 
15476
15476
  case 1:
15477
- return null === (t = r.sent()) ? [ 2 /*return*/ , null ] : (e = this.Pa.decode(t),
15477
+ return null === (t = r.sent()) ? [ 2 /*return*/ , null ] : (e = this.ba.decode(t),
15478
15478
  n = Number(e), isNaN(n) && this.va("length string (" + e + ") is not valid number"),
15479
15479
  [ 4 /*yield*/ , this.Sa(n) ]);
15480
15480
 
@@ -15545,7 +15545,7 @@ function Da(t, e) {
15545
15545
 
15546
15546
  case 3:
15547
15547
  // Update the internal buffer to drop the read json string.
15548
- return e = this.Pa.decode(this.buffer.slice(0, t)), [ 2 /*return*/ , (this.buffer = this.buffer.slice(t),
15548
+ return e = this.ba.decode(this.buffer.slice(0, t)), [ 2 /*return*/ , (this.buffer = this.buffer.slice(t),
15549
15549
  e) ];
15550
15550
  }
15551
15551
  }));
@@ -15748,9 +15748,9 @@ function Da(t, e) {
15748
15748
  this.ensureCommitNotCalled(), this.mutations.push(t);
15749
15749
  }, t.prototype.ensureCommitNotCalled = function() {}, t;
15750
15750
  }(), ka = /** @class */ function() {
15751
- function t(t, e, n, r) {
15752
- this.asyncQueue = t, this.datastore = e, this.updateFunction = n, this.deferred = r,
15753
- this.xa = 5, this.No = new Gu(this.asyncQueue, "transaction_retry" /* TransactionRetry */)
15751
+ function t(t, e, n, r, i) {
15752
+ this.asyncQueue = t, this.datastore = e, this.options = n, this.updateFunction = r,
15753
+ this.deferred = i, this.xa = n.maxAttempts, this.No = new Gu(this.asyncQueue, "transaction_retry" /* TransactionRetry */)
15754
15754
  /** Runs the transaction and sets the result on deferred. */;
15755
15755
  }
15756
15756
  return t.prototype.run = function() {
@@ -16648,7 +16648,7 @@ var cc = /** @class */ function() {
16648
16648
  // after page comes into foreground.
16649
16649
  this.Qa = function() {
16650
16650
  var e = Bu();
16651
- e && U("AsyncQueue", "Visibility state changed to " + e.visibilityState), t.No.bo();
16651
+ e && U("AsyncQueue", "Visibility state changed to " + e.visibilityState), t.No.Po();
16652
16652
  };
16653
16653
  var e = Bu();
16654
16654
  e && "function" == typeof e.addEventListener && e.addEventListener("visibilitychange", this.Qa);
@@ -18803,7 +18803,7 @@ function Ll(t, e, n) {
18803
18803
 
18804
18804
  /**
18805
18805
  * @license
18806
- * Copyright 2020 Google LLC
18806
+ * Copyright 2022 Google LLC
18807
18807
  *
18808
18808
  * Licensed under the Apache License, Version 2.0 (the "License");
18809
18809
  * you may not use this file except in compliance with the License.
@@ -18816,13 +18816,9 @@ function Ll(t, e, n) {
18816
18816
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18817
18817
  * See the License for the specific language governing permissions and
18818
18818
  * limitations under the License.
18819
- */
18820
- /**
18821
- * Converts Firestore's internal types to the JavaScript types that we expose
18822
- * to the user.
18823
- *
18824
- * @internal
18825
- */ var Vl = /** @class */ function() {
18819
+ */ var Vl = {
18820
+ maxAttempts: 5
18821
+ }, Pl = /** @class */ function() {
18826
18822
  function t() {}
18827
18823
  return t.prototype.convertValue = function(t, e) {
18828
18824
  switch (void 0 === e && (e = "none"), qt(t)) {
@@ -18900,6 +18896,28 @@ function Ll(t, e, n) {
18900
18896
  }, t;
18901
18897
  }();
18902
18898
 
18899
+ /**
18900
+ * @license
18901
+ * Copyright 2020 Google LLC
18902
+ *
18903
+ * Licensed under the Apache License, Version 2.0 (the "License");
18904
+ * you may not use this file except in compliance with the License.
18905
+ * You may obtain a copy of the License at
18906
+ *
18907
+ * http://www.apache.org/licenses/LICENSE-2.0
18908
+ *
18909
+ * Unless required by applicable law or agreed to in writing, software
18910
+ * distributed under the License is distributed on an "AS IS" BASIS,
18911
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18912
+ * See the License for the specific language governing permissions and
18913
+ * limitations under the License.
18914
+ */
18915
+ /**
18916
+ * Converts Firestore's internal types to the JavaScript types that we expose
18917
+ * to the user.
18918
+ *
18919
+ * @internal
18920
+ */
18903
18921
  /**
18904
18922
  * @license
18905
18923
  * Copyright 2020 Google LLC
@@ -18924,14 +18942,15 @@ function Ll(t, e, n) {
18924
18942
  * because we want to provide the user with a more specific error message if
18925
18943
  * their `set()` or fails due to invalid data originating from a `toFirestore()`
18926
18944
  * call.
18927
- */ function Pl(t, e, n) {
18945
+ */
18946
+ function Ol(t, e, n) {
18928
18947
  // Cast to `any` in order to satisfy the union type constraint on
18929
18948
  // toFirestore().
18930
18949
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
18931
18950
  return t ? n && (n.merge || n.mergeFields) ? t.toFirestore(e, n) : t.toFirestore(e) : e;
18932
18951
  }
18933
18952
 
18934
- var Ol = /** @class */ function(e) {
18953
+ var Fl = /** @class */ function(e) {
18935
18954
  function n(t) {
18936
18955
  var n = this;
18937
18956
  return (n = e.call(this) || this).firestore = t, n;
@@ -18942,7 +18961,7 @@ var Ol = /** @class */ function(e) {
18942
18961
  var e = this.convertDocumentKey(t, this.firestore._databaseId);
18943
18962
  return new ec(this.firestore, /* converter= */ null, e);
18944
18963
  }, n;
18945
- }(Vl), Fl = /** @class */ function() {
18964
+ }(Pl), ql = /** @class */ function() {
18946
18965
  /** @hideconstructor */
18947
18966
  function t(t, e) {
18948
18967
  this._firestore = t, this._commitHandler = e, this._mutations = [], this._committed = !1,
@@ -18950,12 +18969,12 @@ var Ol = /** @class */ function(e) {
18950
18969
  }
18951
18970
  return t.prototype.set = function(t, e, n) {
18952
18971
  this._verifyNotCommitted();
18953
- var r = ql(t, this._firestore), i = Pl(r.converter, e, n), o = Bc(this._dataReader, "WriteBatch.set", r._key, i, null !== r.converter, n);
18972
+ var r = Ul(t, this._firestore), i = Ol(r.converter, e, n), o = Bc(this._dataReader, "WriteBatch.set", r._key, i, null !== r.converter, n);
18954
18973
  return this._mutations.push(o.toMutation(r._key, Sn.none())), this;
18955
18974
  }, t.prototype.update = function(t, e, n) {
18956
18975
  for (var r = [], i = 3; i < arguments.length; i++) r[i - 3] = arguments[i];
18957
18976
  this._verifyNotCommitted();
18958
- var o, u = ql(t, this._firestore);
18977
+ var o, u = Ul(t, this._firestore);
18959
18978
  // For Compat types, we have to "extract" the underlying types before
18960
18979
  // performing validation.
18961
18980
  return o = "string" == typeof (e = I(e)) || e instanceof xc ? Yc(this._dataReader, "WriteBatch.update", u._key, e, n, r) : Hc(this._dataReader, "WriteBatch.update", u._key, e),
@@ -18969,7 +18988,7 @@ var Ol = /** @class */ function(e) {
18969
18988
  */
18970
18989
  t.prototype.delete = function(t) {
18971
18990
  this._verifyNotCommitted();
18972
- var e = ql(t, this._firestore);
18991
+ var e = Ul(t, this._firestore);
18973
18992
  return this._mutations = this._mutations.concat(new qn(e._key, Sn.none())), this;
18974
18993
  },
18975
18994
  /**
@@ -19014,7 +19033,7 @@ var Ol = /** @class */ function(e) {
19014
19033
  * provides methods for adding writes to the write batch. None of the writes
19015
19034
  * will be committed (or visible locally) until {@link WriteBatch.commit} is
19016
19035
  * called.
19017
- */ function ql(t, e) {
19036
+ */ function Ul(t, e) {
19018
19037
  if ((t = I(t)).firestore !== e) throw new Y(H.INVALID_ARGUMENT, "Provided document reference is from a different Firestore instance.");
19019
19038
  return t;
19020
19039
  }
@@ -19071,15 +19090,15 @@ var Ol = /** @class */ function(e) {
19071
19090
  * @param reference - The reference of the document to fetch.
19072
19091
  * @returns A Promise resolved with a `DocumentSnapshot` containing the
19073
19092
  * current document contents.
19074
- */ function Ul(t) {
19093
+ */ function Bl(t) {
19075
19094
  t = Xa(t, ec);
19076
19095
  var e = Xa(t.firestore, dc);
19077
19096
  return Ka(yc(e), t._key).then((function(n) {
19078
- return th(e, t, n);
19097
+ return eh(e, t, n);
19079
19098
  }));
19080
19099
  }
19081
19100
 
19082
- var Bl = /** @class */ function(e) {
19101
+ var Kl = /** @class */ function(e) {
19083
19102
  function n(t) {
19084
19103
  var n = this;
19085
19104
  return (n = e.call(this) || this).firestore = t, n;
@@ -19090,7 +19109,7 @@ var Bl = /** @class */ function(e) {
19090
19109
  var e = this.convertDocumentKey(t, this.firestore._databaseId);
19091
19110
  return new ec(this.firestore, /* converter= */ null, e);
19092
19111
  }, n;
19093
- }(Vl);
19112
+ }(Pl);
19094
19113
 
19095
19114
  /**
19096
19115
  * Reads the document referred to by this `DocumentReference` from cache.
@@ -19098,9 +19117,9 @@ var Bl = /** @class */ function(e) {
19098
19117
  *
19099
19118
  * @returns A `Promise` resolved with a `DocumentSnapshot` containing the
19100
19119
  * current document contents.
19101
- */ function Kl(t) {
19120
+ */ function Gl(t) {
19102
19121
  t = Xa(t, ec);
19103
- var e = Xa(t.firestore, dc), i = yc(e), o = new Bl(e);
19122
+ var e = Xa(t.firestore, dc), i = yc(e), o = new Kl(e);
19104
19123
  return function(t, e) {
19105
19124
  var i = this, o = new X;
19106
19125
  return t.asyncQueue.enqueueAndForget((function() {
@@ -19155,13 +19174,13 @@ var Bl = /** @class */ function(e) {
19155
19174
  *
19156
19175
  * @returns A `Promise` resolved with a `DocumentSnapshot` containing the
19157
19176
  * current document contents.
19158
- */ function Gl(t) {
19177
+ */ function jl(t) {
19159
19178
  t = Xa(t, ec);
19160
19179
  var e = Xa(t.firestore, dc);
19161
19180
  return Ka(yc(e), t._key, {
19162
19181
  source: "server"
19163
19182
  }).then((function(n) {
19164
- return th(e, t, n);
19183
+ return eh(e, t, n);
19165
19184
  }));
19166
19185
  }
19167
19186
 
@@ -19174,9 +19193,9 @@ var Bl = /** @class */ function(e) {
19174
19193
  * invoke {@link getDocsFromCache} or {@link getDocsFromServer}.
19175
19194
  *
19176
19195
  * @returns A `Promise` that will be resolved with the results of the query.
19177
- */ function jl(t) {
19196
+ */ function zl(t) {
19178
19197
  t = Xa(t, nc);
19179
- var e = Xa(t.firestore, dc), n = yc(e), r = new Bl(e);
19198
+ var e = Xa(t.firestore, dc), n = yc(e), r = new Kl(e);
19180
19199
  return vl(t._query), Ga(n, t._query).then((function(n) {
19181
19200
  return new fl(e, r, t, n);
19182
19201
  }))
@@ -19188,9 +19207,9 @@ var Bl = /** @class */ function(e) {
19188
19207
  */;
19189
19208
  }
19190
19209
 
19191
- function zl(t) {
19210
+ function Ql(t) {
19192
19211
  t = Xa(t, nc);
19193
- var e = Xa(t.firestore, dc), i = yc(e), o = new Bl(e);
19212
+ var e = Xa(t.firestore, dc), i = yc(e), o = new Kl(e);
19194
19213
  return function(t, e) {
19195
19214
  var i = this, o = new X;
19196
19215
  return t.asyncQueue.enqueueAndForget((function() {
@@ -19239,9 +19258,9 @@ function zl(t) {
19239
19258
  * server. Returns an error if the network is not available.
19240
19259
  *
19241
19260
  * @returns A `Promise` that will be resolved with the results of the query.
19242
- */ function Ql(t) {
19261
+ */ function Wl(t) {
19243
19262
  t = Xa(t, nc);
19244
- var e = Xa(t.firestore, dc), n = yc(e), r = new Bl(e);
19263
+ var e = Xa(t.firestore, dc), n = yc(e), r = new Kl(e);
19245
19264
  return Ga(n, t._query, {
19246
19265
  source: "server"
19247
19266
  }).then((function(n) {
@@ -19249,17 +19268,17 @@ function zl(t) {
19249
19268
  }));
19250
19269
  }
19251
19270
 
19252
- function Wl(t, e, n) {
19271
+ function Hl(t, e, n) {
19253
19272
  t = Xa(t, ec);
19254
- var r = Xa(t.firestore, dc), i = Pl(t.converter, e, n);
19255
- return Zl(r, [ Bc(Uc(r), "setDoc", t._key, i, null !== t.converter, n).toMutation(t._key, Sn.none()) ]);
19273
+ var r = Xa(t.firestore, dc), i = Ol(t.converter, e, n);
19274
+ return th(r, [ Bc(Uc(r), "setDoc", t._key, i, null !== t.converter, n).toMutation(t._key, Sn.none()) ]);
19256
19275
  }
19257
19276
 
19258
- function Hl(t, e, n) {
19277
+ function Yl(t, e, n) {
19259
19278
  for (var r = [], i = 3; i < arguments.length; i++) r[i - 3] = arguments[i];
19260
19279
  t = Xa(t, ec);
19261
19280
  var o = Xa(t.firestore, dc), u = Uc(o);
19262
- return Zl(o, [ ("string" == typeof (
19281
+ return th(o, [ ("string" == typeof (
19263
19282
  // For Compat types, we have to "extract" the underlying types before
19264
19283
  // performing validation.
19265
19284
  e = I(e)) || e instanceof xc ? Yc(u, "updateDoc", t._key, e, n, r) : Hc(u, "updateDoc", t._key, e)).toMutation(t._key, Sn.exists(!0)) ]);
@@ -19271,8 +19290,8 @@ function Hl(t, e, n) {
19271
19290
  * @param reference - A reference to the document to delete.
19272
19291
  * @returns A Promise resolved once the document has been successfully
19273
19292
  * deleted from the backend (note that it won't resolve while you're offline).
19274
- */ function Yl(t) {
19275
- return Zl(Xa(t.firestore, dc), [ new qn(t._key, Sn.none()) ]);
19293
+ */ function Xl(t) {
19294
+ return th(Xa(t.firestore, dc), [ new qn(t._key, Sn.none()) ]);
19276
19295
  }
19277
19296
 
19278
19297
  /**
@@ -19284,14 +19303,14 @@ function Hl(t, e, n) {
19284
19303
  * @returns A `Promise` resolved with a `DocumentReference` pointing to the
19285
19304
  * newly created document after it has been written to the backend (Note that it
19286
19305
  * won't resolve while you're offline).
19287
- */ function Xl(t, e) {
19288
- var n = Xa(t.firestore, dc), r = uc(t), i = Pl(t.converter, e);
19289
- return Zl(n, [ Bc(Uc(t.firestore), "addDoc", r._key, i, null !== t.converter, {}).toMutation(r._key, Sn.exists(!1)) ]).then((function() {
19306
+ */ function Jl(t, e) {
19307
+ var n = Xa(t.firestore, dc), r = uc(t), i = Ol(t.converter, e);
19308
+ return th(n, [ Bc(Uc(t.firestore), "addDoc", r._key, i, null !== t.converter, {}).toMutation(r._key, Sn.exists(!1)) ]).then((function() {
19290
19309
  return r;
19291
19310
  }));
19292
19311
  }
19293
19312
 
19294
- function Jl(t) {
19313
+ function $l(t) {
19295
19314
  for (var e, i, o, u = [], s = 1; s < arguments.length; s++) u[s - 1] = arguments[s];
19296
19315
  t = I(t);
19297
19316
  var a = {
@@ -19308,14 +19327,14 @@ function Jl(t) {
19308
19327
  }
19309
19328
  if (t instanceof ec) h = Xa(t.firestore, dc), f = Qe(t._key.path), l = {
19310
19329
  next: function(e) {
19311
- u[c] && u[c](th(h, t, e));
19330
+ u[c] && u[c](eh(h, t, e));
19312
19331
  },
19313
19332
  error: u[c + 1],
19314
19333
  complete: u[c + 2]
19315
19334
  }; else {
19316
19335
  var v = Xa(t, nc);
19317
19336
  h = Xa(v.firestore, dc), f = v._query;
19318
- var y = new Bl(h);
19337
+ var y = new Kl(h);
19319
19338
  l = {
19320
19339
  next: function(t) {
19321
19340
  u[c] && u[c](new fl(h, y, v, t));
@@ -19358,7 +19377,7 @@ function Jl(t) {
19358
19377
  }(yc(h), f, d, l);
19359
19378
  }
19360
19379
 
19361
- function $l(t, e) {
19380
+ function Zl(t, e) {
19362
19381
  return function(t, e) {
19363
19382
  var i = this, o = new Aa(e);
19364
19383
  return t.asyncQueue.enqueueAndForget((function() {
@@ -19368,7 +19387,7 @@ function $l(t, e) {
19368
19387
  switch (n.label) {
19369
19388
  case 0:
19370
19389
  return e = function(t, e) {
19371
- W(t).Pu.add(e),
19390
+ W(t).bu.add(e),
19372
19391
  // Immediately fire an initial event, indicating all existing listeners
19373
19392
  // are in-sync.
19374
19393
  e.next();
@@ -19387,7 +19406,7 @@ function $l(t, e) {
19387
19406
  switch (n.label) {
19388
19407
  case 0:
19389
19408
  return e = function(t, e) {
19390
- W(t).Pu.delete(e);
19409
+ W(t).bu.delete(e);
19391
19410
  }, [ 4 /*yield*/ , Ba(t) ];
19392
19411
 
19393
19412
  case 1:
@@ -19420,7 +19439,7 @@ function $l(t, e) {
19420
19439
  /**
19421
19440
  * Locally writes `mutations` on the async queue.
19422
19441
  * @internal
19423
- */ function Zl(t, e) {
19442
+ */ function th(t, e) {
19424
19443
  return function(t, e) {
19425
19444
  var i = this, o = new X;
19426
19445
  return t.asyncQueue.enqueueAndForget((function() {
@@ -19443,8 +19462,8 @@ function $l(t, e) {
19443
19462
  /**
19444
19463
  * Converts a {@link ViewSnapshot} that contains the single document specified by `ref`
19445
19464
  * to a {@link DocumentSnapshot}.
19446
- */ function th(t, e, n) {
19447
- var r = n.docs.get(e._key), i = new Bl(t);
19465
+ */ function eh(t, e, n) {
19466
+ var r = n.docs.get(e._key), i = new Kl(t);
19448
19467
  return new ll(t, i, e._key, r, new cl(n.hasPendingWrites, n.fromCache), e.converter);
19449
19468
  }
19450
19469
 
@@ -19470,7 +19489,7 @@ function $l(t, e) {
19470
19489
  * The `Transaction` object passed to a transaction's `updateFunction` provides
19471
19490
  * the methods to read and write data within the transaction context. See
19472
19491
  * {@link runTransaction}.
19473
- */ var eh, nh = /** @class */ function(e) {
19492
+ */ var nh, rh = /** @class */ function(e) {
19474
19493
  // This class implements the same logic as the Transaction API in the Lite SDK
19475
19494
  // but is subclassed in order to return its own DocumentSnapshot types.
19476
19495
  /** @hideconstructor */
@@ -19484,7 +19503,7 @@ function $l(t, e) {
19484
19503
  * @param documentRef - A reference to the document to be read.
19485
19504
  * @returns A `DocumentSnapshot` with the read data.
19486
19505
  */ return t(n, e), n.prototype.get = function(t) {
19487
- var n = this, r = ql(t, this._firestore), i = new Bl(this._firestore);
19506
+ var n = this, r = Ul(t, this._firestore), i = new Kl(this._firestore);
19488
19507
  return e.prototype.get.call(this, t).then((function(t) {
19489
19508
  return new ll(n._firestore, i, r._key, t._document, new cl(
19490
19509
  /* hasPendingWrites= */ !1,
@@ -19503,7 +19522,7 @@ function $l(t, e) {
19503
19522
  */;
19504
19523
  }
19505
19524
  return t.prototype.get = function(t) {
19506
- var e = this, n = ql(t, this._firestore), r = new Ol(this._firestore);
19525
+ var e = this, n = Ul(t, this._firestore), r = new Fl(this._firestore);
19507
19526
  return this._transaction.lookup([ n._key ]).then((function(t) {
19508
19527
  if (!t || 1 !== t.length) return j();
19509
19528
  var i = t[0];
@@ -19512,11 +19531,11 @@ function $l(t, e) {
19512
19531
  throw j();
19513
19532
  }));
19514
19533
  }, t.prototype.set = function(t, e, n) {
19515
- var r = ql(t, this._firestore), i = Pl(r.converter, e, n), o = Bc(this._dataReader, "Transaction.set", r._key, i, null !== r.converter, n);
19534
+ var r = Ul(t, this._firestore), i = Ol(r.converter, e, n), o = Bc(this._dataReader, "Transaction.set", r._key, i, null !== r.converter, n);
19516
19535
  return this._transaction.set(r._key, o), this;
19517
19536
  }, t.prototype.update = function(t, e, n) {
19518
19537
  for (var r = [], i = 3; i < arguments.length; i++) r[i - 3] = arguments[i];
19519
- var o, u = ql(t, this._firestore);
19538
+ var o, u = Ul(t, this._firestore);
19520
19539
  // For Compat types, we have to "extract" the underlying types before
19521
19540
  // performing validation.
19522
19541
  return o = "string" == typeof (e = I(e)) || e instanceof xc ? Yc(this._dataReader, "Transaction.update", u._key, e, n, r) : Hc(this._dataReader, "Transaction.update", u._key, e),
@@ -19529,7 +19548,7 @@ function $l(t, e) {
19529
19548
  * @returns This `Transaction` instance. Used for chaining method calls.
19530
19549
  */
19531
19550
  t.prototype.delete = function(t) {
19532
- var e = ql(t, this._firestore);
19551
+ var e = Ul(t, this._firestore);
19533
19552
  return this._transaction.delete(e._key), this;
19534
19553
  }, t;
19535
19554
  }());
@@ -19550,11 +19569,15 @@ function $l(t, e) {
19550
19569
  * (the `updateFunction` returned a failed promise), the promise returned by the
19551
19570
  * `updateFunction `is returned here. Otherwise, if the transaction failed, a
19552
19571
  * rejected promise with the corresponding failure error is returned.
19553
- */ function rh(t, e) {
19554
- return function(t, e) {
19555
- var i = this, o = new X;
19572
+ */ function ih(t, e, i) {
19573
+ t = Xa(t, dc);
19574
+ var o = Object.assign(Object.assign({}, Vl), i);
19575
+ return function(t) {
19576
+ if (t.maxAttempts < 1) throw new Y(H.INVALID_ARGUMENT, "Max attempts must be at least 1");
19577
+ }(o), function(t, e, i) {
19578
+ var o = this, u = new X;
19556
19579
  return t.asyncQueue.enqueueAndForget((function() {
19557
- return n(i, void 0, void 0, (function() {
19580
+ return n(o, void 0, void 0, (function() {
19558
19581
  var n;
19559
19582
  return r(this, (function(r) {
19560
19583
  switch (r.label) {
@@ -19566,14 +19589,14 @@ function $l(t, e) {
19566
19589
  }(t) ];
19567
19590
 
19568
19591
  case 1:
19569
- return n = r.sent(), new ka(t.asyncQueue, n, e, o).run(), [ 2 /*return*/ ];
19592
+ return n = r.sent(), new ka(t.asyncQueue, n, i, e, u).run(), [ 2 /*return*/ ];
19570
19593
  }
19571
19594
  }));
19572
19595
  }));
19573
- })), o.promise;
19574
- }(yc(t = Xa(t, dc)), (function(n) {
19575
- return e(new nh(t, n));
19576
- }));
19596
+ })), u.promise;
19597
+ }(yc(t), (function(n) {
19598
+ return e(new rh(t, n));
19599
+ }), o);
19577
19600
  }
19578
19601
 
19579
19602
  /**
@@ -19595,14 +19618,14 @@ function $l(t, e) {
19595
19618
  /**
19596
19619
  * Returns a sentinel for use with {@link @firebase/firestore/lite#(updateDoc:1)} or
19597
19620
  * {@link @firebase/firestore/lite#(setDoc:1)} with `{merge: true}` to mark a field for deletion.
19598
- */ function ih() {
19621
+ */ function oh() {
19599
19622
  return new Kc("deleteField");
19600
19623
  }
19601
19624
 
19602
19625
  /**
19603
19626
  * Returns a sentinel used with {@link @firebase/firestore/lite#(setDoc:1)} or {@link @firebase/firestore/lite#(updateDoc:1)} to
19604
19627
  * include a server-generated timestamp in the written data.
19605
- */ function oh() {
19628
+ */ function uh() {
19606
19629
  return new jc("serverTimestamp");
19607
19630
  }
19608
19631
 
@@ -19617,7 +19640,7 @@ function $l(t, e) {
19617
19640
  * @param elements - The elements to union into the array.
19618
19641
  * @returns The `FieldValue` sentinel for use in a call to `setDoc()` or
19619
19642
  * `updateDoc()`.
19620
- */ function uh() {
19643
+ */ function sh() {
19621
19644
  for (var t = [], e = 0; e < arguments.length; e++) t[e] = arguments[e];
19622
19645
  // NOTE: We don't actually parse the data until it's used in set() or
19623
19646
  // update() since we'd need the Firestore instance to do this.
@@ -19634,7 +19657,7 @@ function $l(t, e) {
19634
19657
  * @param elements - The elements to remove from the array.
19635
19658
  * @returns The `FieldValue` sentinel for use in a call to `setDoc()` or
19636
19659
  * `updateDoc()`
19637
- */ function sh() {
19660
+ */ function ah() {
19638
19661
  for (var t = [], e = 0; e < arguments.length; e++) t[e] = arguments[e];
19639
19662
  // NOTE: We don't actually parse the data until it's used in set() or
19640
19663
  // update() since we'd need the Firestore instance to do this.
@@ -19659,7 +19682,7 @@ function $l(t, e) {
19659
19682
  * @param n - The value to increment by.
19660
19683
  * @returns The `FieldValue` sentinel for use in a call to `setDoc()` or
19661
19684
  * `updateDoc()`
19662
- */ function ah(t) {
19685
+ */ function ch(t) {
19663
19686
  return new Wc("increment", t);
19664
19687
  }
19665
19688
 
@@ -19689,9 +19712,9 @@ function $l(t, e) {
19689
19712
  *
19690
19713
  * @returns A {@link WriteBatch} that can be used to atomically execute multiple
19691
19714
  * writes.
19692
- */ function ch(t) {
19693
- return yc(t = Xa(t, dc)), new Fl(t, (function(e) {
19694
- return Zl(t, e);
19715
+ */ function lh(t) {
19716
+ return yc(t = Xa(t, dc)), new ql(t, (function(e) {
19717
+ return th(t, e);
19695
19718
  }))
19696
19719
  /**
19697
19720
  * @license
@@ -19711,7 +19734,7 @@ function $l(t, e) {
19711
19734
  */;
19712
19735
  }
19713
19736
 
19714
- function lh(t, e) {
19737
+ function hh(t, e) {
19715
19738
  yc(t = Xa(t, dc));
19716
19739
  var n = "string" == typeof e ? function(t) {
19717
19740
  try {
@@ -19723,9 +19746,9 @@ function lh(t, e) {
19723
19746
  // PORTING NOTE: We don't return an error if the user has not enabled
19724
19747
  // persistence since `enableIndexeddbPersistence()` can fail on the Web.
19725
19748
  if (Array.isArray(n.indexes)) for (var i = 0, o = n.indexes; i < o.length; i++) {
19726
- var u = o[i], s = hh(u, "collectionGroup"), a = [];
19749
+ var u = o[i], s = fh(u, "collectionGroup"), a = [];
19727
19750
  if (Array.isArray(u.fields)) for (var c = 0, l = u.fields; c < l.length; c++) {
19728
- var h = l[c], f = rl("setIndexConfiguration", hh(h, "fieldPath"));
19751
+ var h = l[c], f = rl("setIndexConfiguration", fh(h, "fieldPath"));
19729
19752
  "CONTAINS" === h.arrayConfig ? a.push(new le(f, 2 /* CONTAINS */)) : "ASCENDING" === h.order ? a.push(new le(f, 0 /* ASCENDING */)) : "DESCENDING" === h.order && a.push(new le(f, 1 /* DESCENDING */));
19730
19753
  }
19731
19754
  r.push(new se(se.UNKNOWN_ID, s, a, he.empty()));
@@ -19734,7 +19757,7 @@ function lh(t, e) {
19734
19757
  return Promise.resolve();
19735
19758
  }
19736
19759
 
19737
- function hh(t, e) {
19760
+ function fh(t, e) {
19738
19761
  if ("string" != typeof t[e]) throw new Y(H.INVALID_ARGUMENT, "Missing string value for: " + e);
19739
19762
  return t[e];
19740
19763
  }
@@ -19743,14 +19766,14 @@ function hh(t, e) {
19743
19766
  * Cloud Firestore
19744
19767
  *
19745
19768
  * @packageDocumentation
19746
- */ void 0 === eh && (eh = !0), P = i, o(new c("firestore", (function(t, e) {
19769
+ */ void 0 === nh && (nh = !0), P = i, o(new c("firestore", (function(t, e) {
19747
19770
  var n = e.options, r = t.getProvider("app").getImmediate(), i = new dc(r, new tt(t.getProvider("auth-internal")), new it(t.getProvider("app-check-internal")));
19748
19771
  return n = Object.assign({
19749
- useFetchStreams: eh
19772
+ useFetchStreams: nh
19750
19773
  }, n), i._setSettings(n), i;
19751
- }), "PUBLIC")), u(L, "3.4.8-canary.5ce067663", void 0),
19774
+ }), "PUBLIC")), u(L, "3.4.8-canary.63caee2a5", void 0),
19752
19775
  // BUILD_TARGET will be replaced by values like esm5, esm2017, cjs5, etc during the compilation
19753
- u(L, "3.4.8-canary.5ce067663", "esm5");
19776
+ u(L, "3.4.8-canary.63caee2a5", "esm5");
19754
19777
 
19755
- export { Vl as AbstractUserDataWriter, kc as Bytes, fc as CACHE_SIZE_UNLIMITED, rc as CollectionReference, ec as DocumentReference, ll as DocumentSnapshot, xc as FieldPath, Mc as FieldValue, dc as Firestore, Y as FirestoreError, Rc as GeoPoint, hc as LoadBundleTask, nc as Query, yl as QueryConstraint, hl as QueryDocumentSnapshot, fl as QuerySnapshot, cl as SnapshotMetadata, ft as Timestamp, nh as Transaction, Fl as WriteBatch, Mt as _DatabaseId, Pt as _DocumentKey, ot as _EmptyAppCheckTokenProvider, $ as _EmptyAuthCredentialsProvider, bt as _FieldPath, Xa as _cast, Q as _debugAssert, Et as _isBase64Available, K as _logWarn, lh as _setIndexConfiguration, Qa as _validateIsNotUsedTogether, Xl as addDoc, sh as arrayRemove, uh as arrayUnion, Ic as clearIndexedDbPersistence, ic as collection, oc as collectionGroup, tc as connectFirestoreEmulator, Yl as deleteDoc, ih as deleteField, Sc as disableNetwork, uc as doc, Cc as documentId, gc as enableIndexedDbPersistence, wc as enableMultiTabIndexedDbPersistence, Tc as enableNetwork, Cl as endAt, xl as endBefore, yc as ensureFirestoreConfigured, Zl as executeWrite, Ul as getDoc, Kl as getDocFromCache, Gl as getDocFromServer, jl as getDocs, zl as getDocsFromCache, Ql as getDocsFromServer, vc as getFirestore, ah as increment, pc as initializeFirestore, Tl as limit, Sl as limitToLast, Nc as loadBundle, Dc as namedQuery, Jl as onSnapshot, $l as onSnapshotsInSync, Il as orderBy, ml as query, ac as queryEqual, sc as refEqual, rh as runTransaction, oh as serverTimestamp, Wl as setDoc, q as setLogLevel, pl as snapshotEqual, Dl as startAfter, Nl as startAt, _c as terminate, Hl as updateDoc, Ec as waitForPendingWrites, wl as where, ch as writeBatch };
19778
+ export { Pl as AbstractUserDataWriter, kc as Bytes, fc as CACHE_SIZE_UNLIMITED, rc as CollectionReference, ec as DocumentReference, ll as DocumentSnapshot, xc as FieldPath, Mc as FieldValue, dc as Firestore, Y as FirestoreError, Rc as GeoPoint, hc as LoadBundleTask, nc as Query, yl as QueryConstraint, hl as QueryDocumentSnapshot, fl as QuerySnapshot, cl as SnapshotMetadata, ft as Timestamp, rh as Transaction, ql as WriteBatch, Mt as _DatabaseId, Pt as _DocumentKey, ot as _EmptyAppCheckTokenProvider, $ as _EmptyAuthCredentialsProvider, bt as _FieldPath, Xa as _cast, Q as _debugAssert, Et as _isBase64Available, K as _logWarn, hh as _setIndexConfiguration, Qa as _validateIsNotUsedTogether, Jl as addDoc, ah as arrayRemove, sh as arrayUnion, Ic as clearIndexedDbPersistence, ic as collection, oc as collectionGroup, tc as connectFirestoreEmulator, Xl as deleteDoc, oh as deleteField, Sc as disableNetwork, uc as doc, Cc as documentId, gc as enableIndexedDbPersistence, wc as enableMultiTabIndexedDbPersistence, Tc as enableNetwork, Cl as endAt, xl as endBefore, yc as ensureFirestoreConfigured, th as executeWrite, Bl as getDoc, Gl as getDocFromCache, jl as getDocFromServer, zl as getDocs, Ql as getDocsFromCache, Wl as getDocsFromServer, vc as getFirestore, ch as increment, pc as initializeFirestore, Tl as limit, Sl as limitToLast, Nc as loadBundle, Dc as namedQuery, $l as onSnapshot, Zl as onSnapshotsInSync, Il as orderBy, ml as query, ac as queryEqual, sc as refEqual, ih as runTransaction, uh as serverTimestamp, Hl as setDoc, q as setLogLevel, pl as snapshotEqual, Dl as startAfter, Nl as startAt, _c as terminate, Yl as updateDoc, Ec as waitForPendingWrites, wl as where, lh as writeBatch };
19756
19779
  //# sourceMappingURL=index.esm5.js.map