@dereekb/firebase 13.11.14 → 13.11.15
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/index.cjs.js +1446 -1137
- package/index.esm.js +1437 -1128
- package/package.json +5 -5
- package/src/lib/client/error/error.d.ts +1 -1
- package/src/lib/client/firestore/array.d.ts +3 -2
- package/src/lib/client/firestore/driver.accessor.batch.d.ts +5 -4
- package/src/lib/client/firestore/driver.accessor.create.d.ts +4 -3
- package/src/lib/client/firestore/driver.accessor.d.ts +2 -1
- package/src/lib/client/firestore/driver.accessor.default.d.ts +5 -3
- package/src/lib/client/firestore/driver.accessor.transaction.d.ts +7 -5
- package/src/lib/client/firestore/driver.d.ts +1 -1
- package/src/lib/client/firestore/driver.query.d.ts +5 -5
- package/src/lib/client/firestore/increment.d.ts +3 -2
- package/src/lib/client/function/development.function.factory.d.ts +3 -2
- package/src/lib/client/function/error.d.ts +2 -2
- package/src/lib/client/function/function.callable.d.ts +5 -5
- package/src/lib/client/function/function.factory.d.ts +6 -4
- package/src/lib/client/function/model.function.factory.d.ts +9 -8
- package/src/lib/client/storage/driver.accessor.d.ts +14 -14
- package/src/lib/client/storage/driver.d.ts +1 -1
- package/src/lib/common/auth/auth.error.d.ts +2 -2
- package/src/lib/common/development/function.d.ts +5 -5
- package/src/lib/common/firestore/accessor/accessor.d.ts +22 -16
- package/src/lib/common/firestore/accessor/accessor.wrap.d.ts +33 -29
- package/src/lib/common/firestore/accessor/accessor.wrap.modify.d.ts +11 -7
- package/src/lib/common/firestore/accessor/array.d.ts +3 -2
- package/src/lib/common/firestore/accessor/document.d.ts +27 -24
- package/src/lib/common/firestore/accessor/document.paged.d.ts +2 -2
- package/src/lib/common/firestore/accessor/document.rxjs.d.ts +15 -12
- package/src/lib/common/firestore/accessor/document.utility.d.ts +81 -72
- package/src/lib/common/firestore/accessor/increment.d.ts +3 -2
- package/src/lib/common/firestore/cache/cache.d.ts +8 -7
- package/src/lib/common/firestore/cache/cache.memory.d.ts +13 -10
- package/src/lib/common/firestore/collection/collection.d.ts +62 -42
- package/src/lib/common/firestore/collection/collection.group.d.ts +4 -2
- package/src/lib/common/firestore/collection/collection.query.d.ts +7 -4
- package/src/lib/common/firestore/collection/collection.single.d.ts +4 -2
- package/src/lib/common/firestore/collection/collection.util.d.ts +3 -2
- package/src/lib/common/firestore/collection/subcollection.d.ts +4 -2
- package/src/lib/common/firestore/collection/subcollection.paged.d.ts +7 -3
- package/src/lib/common/firestore/collection/subcollection.single.d.ts +4 -2
- package/src/lib/common/firestore/context.d.ts +4 -2
- package/src/lib/common/firestore/driver/query.handler.d.ts +4 -3
- package/src/lib/common/firestore/error.d.ts +6 -5
- package/src/lib/common/firestore/query/constraint.d.ts +56 -36
- package/src/lib/common/firestore/query/constraint.template.d.ts +15 -7
- package/src/lib/common/firestore/query/iterator.d.ts +20 -13
- package/src/lib/common/firestore/query/query.d.ts +6 -4
- package/src/lib/common/firestore/query/query.iterate.array.d.ts +10 -6
- package/src/lib/common/firestore/query/query.iterate.d.ts +8 -8
- package/src/lib/common/firestore/query/query.util.d.ts +11 -7
- package/src/lib/common/firestore/query/watcher.d.ts +9 -7
- package/src/lib/common/firestore/snapshot/snapshot.d.ts +6 -3
- package/src/lib/common/firestore/snapshot/snapshot.field.d.ts +230 -132
- package/src/lib/common/firestore/util/id.batch.d.ts +4 -2
- package/src/lib/common/model/function.d.ts +21 -20
- package/src/lib/common/model/model/model.loader.d.ts +2 -2
- package/src/lib/common/model/model.service.d.ts +28 -20
- package/src/lib/common/model/permission/permission.service.d.ts +3 -2
- package/src/lib/common/model/permission/permission.service.grant.d.ts +27 -21
- package/src/lib/common/model/permission/permission.service.role.d.ts +7 -7
- package/src/lib/common/storage/accessor/path.model.d.ts +3 -2
- package/src/lib/common/storage/context.d.ts +3 -2
- package/src/lib/common/storage/driver/accessor.iterate.d.ts +7 -6
- package/src/lib/common/storage/driver/accessor.util.d.ts +4 -4
- package/src/lib/common/storage/driver/error.d.ts +3 -3
- package/src/lib/common/storage/driver/list.d.ts +4 -3
- package/src/lib/common/storage/storage.d.ts +9 -8
- package/src/lib/common/storage/types.d.ts +1 -1
- package/src/lib/model/notification/notification.api.d.ts +2 -2
- package/src/lib/model/notification/notification.api.util.d.ts +16 -16
- package/src/lib/model/notification/notification.config.d.ts +35 -34
- package/src/lib/model/notification/notification.create.d.ts +17 -15
- package/src/lib/model/notification/notification.create.loggedevent.d.ts +3 -2
- package/src/lib/model/notification/notification.create.task.d.ts +3 -2
- package/src/lib/model/notification/notification.d.ts +53 -45
- package/src/lib/model/notification/notification.details.d.ts +5 -4
- package/src/lib/model/notification/notification.id.d.ts +8 -8
- package/src/lib/model/notification/notification.item.d.ts +3 -3
- package/src/lib/model/notification/notification.loggedevent.loader.d.ts +2 -2
- package/src/lib/model/notification/notification.message.d.ts +6 -4
- package/src/lib/model/notification/notification.query.d.ts +12 -12
- package/src/lib/model/notification/notification.send.d.ts +3 -3
- package/src/lib/model/notification/notification.task.d.ts +15 -15
- package/src/lib/model/notification/notification.task.subtask.d.ts +3 -3
- package/src/lib/model/notification/notification.util.d.ts +29 -29
- package/src/lib/model/oidcmodel/oidcmodel.api.d.ts +2 -2
- package/src/lib/model/oidcmodel/oidcmodel.d.ts +6 -6
- package/src/lib/model/oidcmodel/oidcmodel.query.d.ts +18 -18
- package/src/lib/model/storagefile/storagefile.api.d.ts +2 -2
- package/src/lib/model/storagefile/storagefile.create.d.ts +8 -7
- package/src/lib/model/storagefile/storagefile.d.ts +19 -18
- package/src/lib/model/storagefile/storagefile.file.d.ts +2 -1
- package/src/lib/model/storagefile/storagefile.group.d.ts +5 -5
- package/src/lib/model/storagefile/storagefile.permission.d.ts +3 -2
- package/src/lib/model/storagefile/storagefile.query.d.ts +15 -15
- package/src/lib/model/storagefile/storagefile.task.d.ts +2 -2
- package/src/lib/model/storagefile/storagefile.upload.claims.d.ts +4 -4
- package/src/lib/model/storagefile/storagefile.upload.d.ts +8 -6
- package/src/lib/model/storagefile/storagefile.upload.determiner.d.ts +18 -16
- package/src/lib/model/storagefile/storagefile.util.d.ts +8 -8
- package/src/lib/model/system/system.d.ts +6 -6
- package/test/index.cjs.js +43 -43
- package/test/index.esm.js +38 -38
- package/test/package.json +6 -6
- package/test/src/lib/client/firebase.d.ts +1 -1
- package/test/src/lib/common/firestore/firestore.d.ts +3 -3
- package/test/src/lib/common/mock/mock.item.collection.fixture.d.ts +3 -3
- package/test/src/lib/common/mock/mock.item.d.ts +16 -16
- package/test/src/lib/common/mock/mock.item.query.d.ts +4 -4
- package/test/src/lib/common/mock/mock.item.storage.fixture.d.ts +3 -3
- package/test/src/lib/common/storage/storage.d.ts +1 -1
|
@@ -130,29 +130,30 @@ export type IterationQueryDocChangeWatcherChangeType = 'addedAndRemoved' | 'adde
|
|
|
130
130
|
* raw query snapshots and processed change events, making it easier to react to
|
|
131
131
|
* specific types of changes.
|
|
132
132
|
*
|
|
133
|
-
* @template T - The document data type
|
|
134
133
|
* @param config - Configuration for the watcher, including the iteration instance to watch
|
|
135
|
-
* and an optional delay before starting to monitor changes
|
|
136
|
-
* @returns A watcher object with observables for streaming changes
|
|
134
|
+
* and an optional delay before starting to monitor changes.
|
|
135
|
+
* @returns A watcher object with observables for streaming changes.
|
|
136
|
+
*
|
|
137
|
+
* @template T - The document data type
|
|
137
138
|
*
|
|
138
139
|
* @example
|
|
140
|
+
* ```ts
|
|
139
141
|
* // Create a watcher for changes to active users
|
|
140
142
|
* const usersIterator = firestoreItemPageIterator({
|
|
141
143
|
* queryFactory: () => collection(firestore, 'users').where('status', '==', 'active'),
|
|
142
144
|
* pageSize: 10
|
|
143
145
|
* });
|
|
144
|
-
*
|
|
145
146
|
* const watcher = iterationQueryDocChangeWatcher({
|
|
146
147
|
* instance: usersIterator,
|
|
147
148
|
* delay: 1000 // wait 1 second after first results before watching for changes
|
|
148
149
|
* });
|
|
149
|
-
*
|
|
150
150
|
* // React to specific change types
|
|
151
151
|
* watcher.event$.subscribe(event => {
|
|
152
152
|
* if (event.type === 'added') {
|
|
153
153
|
* console.log('New users added:', event.added.map(change => change.doc.data()));
|
|
154
154
|
* }
|
|
155
155
|
* });
|
|
156
|
+
* ```
|
|
156
157
|
*/
|
|
157
158
|
export declare function iterationQueryDocChangeWatcher<T = unknown>(config: IterationQueryDocChangeWatcherConfig<T>): IterationQueryDocChangeWatcher<T>;
|
|
158
159
|
/**
|
|
@@ -166,8 +167,9 @@ export declare function iterationQueryDocChangeWatcher<T = unknown>(config: Iter
|
|
|
166
167
|
* 4. If only modifications are present, classify as 'modified'.
|
|
167
168
|
* 5. If no changes are present, classify as 'none'.
|
|
168
169
|
*
|
|
170
|
+
* @param group - The change group to classify.
|
|
171
|
+
* @returns The overall change type classification.
|
|
172
|
+
*
|
|
169
173
|
* @template T - The document data type
|
|
170
|
-
* @param group - The change group to classify
|
|
171
|
-
* @returns The overall change type classification
|
|
172
174
|
*/
|
|
173
175
|
export declare function iterationQueryDocChangeWatcherChangeTypeForGroup<T = unknown>(group: IterationQueryDocChangeWatcherChangeGroup<T>): IterationQueryDocChangeWatcherChangeType;
|
|
@@ -10,12 +10,14 @@ import { type FirestoreModelData, type SnapshotConverterConfig, type SnapshotCon
|
|
|
10
10
|
* typed model objects and the data format stored in Firestore. It supports field-level conversions,
|
|
11
11
|
* custom modifiers, and handles Firestore's merge options appropriately.
|
|
12
12
|
*
|
|
13
|
+
* @param config - Field mappings and modifiers that drive the conversion.
|
|
14
|
+
* @returns Function set used to convert snapshots and writes for the model.
|
|
15
|
+
*
|
|
13
16
|
* @template T - The application model type that will be used in your application code
|
|
14
17
|
* @template O - The data type that will be stored in Firestore (defaults to FirestoreModelData<T>)
|
|
15
|
-
* @param config - Configuration for the converter, including field mappings and modifiers
|
|
16
|
-
* @returns A set of functions for converting between Firestore data and application models
|
|
17
18
|
*
|
|
18
19
|
* @example
|
|
20
|
+
* ```ts
|
|
19
21
|
* // Create a converter for a User model
|
|
20
22
|
* const userConverter = snapshotConverterFunctions<User, UserData>({
|
|
21
23
|
* fields: {
|
|
@@ -25,9 +27,10 @@ import { type FirestoreModelData, type SnapshotConverterConfig, type SnapshotCon
|
|
|
25
27
|
* }
|
|
26
28
|
* }
|
|
27
29
|
* });
|
|
28
|
-
*
|
|
29
30
|
* // Use with a collection reference
|
|
30
31
|
* const usersCollection = firestore.collection('users').withConverter(userConverter);
|
|
32
|
+
* ```
|
|
33
|
+
*
|
|
31
34
|
* @__NO_SIDE_EFFECTS__
|
|
32
35
|
*/
|
|
33
36
|
export declare function snapshotConverterFunctions<T extends object, O extends object = FirestoreModelData<T>>(config: SnapshotConverterConfig<T, O>): SnapshotConverterFunctions<T, O>;
|