@firebase/firestore 3.12.1 → 3.12.2-20230531163950

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 (40) hide show
  1. package/dist/firestore/src/api/cache_config.d.ts +4 -0
  2. package/dist/firestore/src/api/database.d.ts +2 -0
  3. package/dist/firestore/src/api/settings.d.ts +6 -0
  4. package/dist/index.cjs.js +22 -15
  5. package/dist/index.cjs.js.map +1 -1
  6. package/dist/index.d.ts +12 -0
  7. package/dist/index.esm2017.js +22 -15
  8. package/dist/index.esm2017.js.map +1 -1
  9. package/dist/index.esm5.js +21 -14
  10. package/dist/index.esm5.js.map +1 -1
  11. package/dist/index.node.cjs.js +20 -13
  12. package/dist/index.node.cjs.js.map +1 -1
  13. package/dist/index.node.mjs +20 -13
  14. package/dist/index.node.mjs.map +1 -1
  15. package/dist/index.rn.js +22 -15
  16. package/dist/index.rn.js.map +1 -1
  17. package/dist/internal.d.ts +12 -0
  18. package/dist/lite/firestore/src/api/cache_config.d.ts +4 -0
  19. package/dist/lite/firestore/src/api/database.d.ts +2 -0
  20. package/dist/lite/firestore/src/api/settings.d.ts +6 -0
  21. package/dist/lite/index.browser.esm2017.js +2 -2
  22. package/dist/lite/index.browser.esm2017.js.map +1 -1
  23. package/dist/lite/index.browser.esm5.js +2 -2
  24. package/dist/lite/index.browser.esm5.js.map +1 -1
  25. package/dist/lite/index.cjs.js +2 -2
  26. package/dist/lite/index.cjs.js.map +1 -1
  27. package/dist/lite/index.node.cjs.js +2 -2
  28. package/dist/lite/index.node.mjs +2 -2
  29. package/dist/lite/index.node.mjs.map +1 -1
  30. package/dist/lite/index.rn.esm2017.js +2 -2
  31. package/dist/lite/index.rn.esm2017.js.map +1 -1
  32. package/dist/lite/packages/firestore/src/api/cache_config.d.ts +4 -0
  33. package/dist/lite/packages/firestore/src/api/database.d.ts +2 -0
  34. package/dist/lite/packages/firestore/src/api/settings.d.ts +6 -0
  35. package/dist/packages/firestore/dist/index.esm2017.d.ts +4 -0
  36. package/dist/packages/firestore/src/api/cache_config.d.ts +4 -0
  37. package/dist/packages/firestore/src/api/database.d.ts +2 -0
  38. package/dist/packages/firestore/src/api/settings.d.ts +6 -0
  39. package/dist/private.d.ts +12 -0
  40. package/package.json +2 -2
package/dist/index.rn.js CHANGED
@@ -70,7 +70,7 @@ D.MOCK_USER = new D("mock-user");
70
70
  * See the License for the specific language governing permissions and
71
71
  * limitations under the License.
72
72
  */
73
- let C = "9.22.1";
73
+ let C = "9.22.2-20230531163950";
74
74
 
75
75
  /**
76
76
  * @license
@@ -7977,25 +7977,28 @@ function Br(t, e) {
7977
7977
  const e = wt(t);
7978
7978
  if (void 0 !== e && !this.en(e)) return !1;
7979
7979
  const n = _t(t);
7980
- let s = 0, i = 0;
7980
+ let s = new Set, i = 0, r = 0;
7981
7981
  // Process all equalities first. Equalities can appear out of order.
7982
- for (;s < n.length && this.en(n[s]); ++s) ;
7982
+ for (;i < n.length && this.en(n[i]); ++i) s = s.add(n[i].fieldPath.canonicalString());
7983
7983
  // If we already have processed all segments, all segments are used to serve
7984
7984
  // the equality filters and we do not need to map any segments to the
7985
7985
  // target's inequality and orderBy clauses.
7986
- if (s === n.length) return !0;
7987
- // If there is an inequality filter, the next segment must match both the
7988
- // filter and the first orderBy clause.
7989
- if (void 0 !== this.Ze) {
7990
- const t = n[s];
7991
- if (!this.nn(this.Ze, t) || !this.sn(this.Ye[i++], t)) return !1;
7992
- ++s;
7986
+ if (i === n.length) return !0;
7987
+ if (void 0 !== this.Ze) {
7988
+ // If there is an inequality filter and the field was not in one of the
7989
+ // equality filters above, the next segment must match both the filter
7990
+ // and the first orderBy clause.
7991
+ if (!s.has(this.Ze.field.canonicalString())) {
7992
+ const t = n[i];
7993
+ if (!this.nn(this.Ze, t) || !this.sn(this.Ye[r++], t)) return !1;
7994
+ }
7995
+ ++i;
7993
7996
  }
7994
7997
  // All remaining segments need to represent the prefix of the target's
7995
7998
  // orderBy.
7996
- for (;s < n.length; ++s) {
7997
- const t = n[s];
7998
- if (i >= this.Ye.length || !this.sn(this.Ye[i++], t)) return !1;
7999
+ for (;i < n.length; ++i) {
8000
+ const t = n[i];
8001
+ if (r >= this.Ye.length || !this.sn(this.Ye[r++], t)) return !1;
7999
8002
  }
8000
8003
  return !0;
8001
8004
  }
@@ -18417,6 +18420,8 @@ function Ch(t) {
18417
18420
  * * unimplemented: The browser is incompatible with the offline
18418
18421
  * persistence implementation.
18419
18422
  *
18423
+ * Persistence cannot be used in a Node.js environment.
18424
+ *
18420
18425
  * @param firestore - The {@link Firestore} instance to enable persistence for.
18421
18426
  * @param persistenceSettings - Optional settings object to configure
18422
18427
  * persistence.
@@ -20916,6 +20921,8 @@ class xf {
20916
20921
  /**
20917
20922
  * Creates an instance of `PersistentLocalCache`. The instance can be set to
20918
20923
  * `FirestoreSettings.cache` to tell the SDK which cache layer to use.
20924
+ *
20925
+ * Persistent cache cannot be used in a Node.js environment.
20919
20926
  */ function Mf(t) {
20920
20927
  return new Df(t);
20921
20928
  }
@@ -21394,9 +21401,9 @@ function Zf(t, e) {
21394
21401
  return s = Object.assign({
21395
21402
  useFetchStreams: e
21396
21403
  }, s), r._setSettings(s), r;
21397
- }), "PUBLIC").setMultipleInstances(!0)), s(S, "3.12.1", t),
21404
+ }), "PUBLIC").setMultipleInstances(!0)), s(S, "3.12.2-20230531163950", t),
21398
21405
  // BUILD_TARGET will be replaced by values like esm5, esm2017, cjs5, etc during the compilation
21399
- s(S, "3.12.1", "esm2017");
21406
+ s(S, "3.12.2-20230531163950", "esm2017");
21400
21407
  }("rn", /* useFetchStreams= */ !1);
21401
21408
 
21402
21409
  export { Yl as AbstractUserDataWriter, Kh as AggregateField, Gh as AggregateQuerySnapshot, Qh as Bytes, Ph as CACHE_SIZE_UNLIMITED, gh as CollectionReference, _h as DocumentReference, uf as DocumentSnapshot, jh as FieldPath, Wh as FieldValue, bh as Firestore, G as FirestoreError, Hh as GeoPoint, Rh as LoadBundleTask, mh as Query, Cl as QueryCompositeFilterConstraint, bl as QueryConstraint, cf as QueryDocumentSnapshot, Ul as QueryEndAtConstraint, Sl as QueryFieldFilterConstraint, Ml as QueryLimitConstraint, kl as QueryOrderByConstraint, af as QuerySnapshot, Bl as QueryStartAtConstraint, of as SnapshotMetadata, ot as Timestamp, Gf as Transaction, Uf as WriteBatch, Le as _DatabaseId, ft as _DocumentKey, tt as _EmptyAppCheckTokenProvider, z as _EmptyAuthCredentialsProvider, lt as _FieldPath, li as _TestingHooks, hh as _cast, q as _debugAssert, De as _isBase64Available, O as _logWarn, oh as _validateIsNotUsedTogether, Ef as addDoc, sf as aggregateFieldEqual, rf as aggregateQuerySnapshotEqual, Nl as and, Hf as arrayRemove, Wf as arrayUnion, ef as average, $h as clearIndexedDbPersistence, yh as collection, ph as collectionGroup, wh as connectFirestoreEmulator, nf as count, Tf as deleteDoc, jf as deleteField, Fh as disableNetwork, Ih as doc, zh as documentId, xh as enableIndexedDbPersistence, Nh as enableMultiTabIndexedDbPersistence, Oh as enableNetwork, Gl as endAt, Kl as endBefore, Dh as ensureFirestoreConfigured, Rf as executeWrite, Vf as getAggregateFromServer, bf as getCountFromServer, ff as getDoc, wf as getDocFromCache, _f as getDocFromServer, mf as getDocs, gf as getDocsFromCache, yf as getDocsFromServer, Sh as getFirestore, Jf as increment, Vh as initializeFirestore, Ol as limit, Fl as limitToLast, Lh as loadBundle, Nf as memoryEagerGarbageCollector, $f as memoryLocalCache, kf as memoryLruGarbageCollector, qh as namedQuery, Af as onSnapshot, vf as onSnapshotsInSync, xl as or, $l as orderBy, Mf as persistentLocalCache, Lf as persistentMultipleTabManager, Bf as persistentSingleTabManager, Vl as query, Eh as queryEqual, Th as refEqual, Qf as runTransaction, zf as serverTimestamp, pf as setDoc, Xf as setIndexConfiguration, k as setLogLevel, lf as snapshotEqual, ql as startAfter, Ll as startAt, tf as sum, Bh as terminate, If as updateDoc, Mh as waitForPendingWrites, Dl as where, Yf as writeBatch };