@angular/fire 19.2.0 → 20.0.0-rc.0
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/ai/index.d.ts +32 -5
- package/analytics/index.d.ts +87 -5
- package/app/index.d.ts +36 -5
- package/app-check/index.d.ts +33 -5
- package/auth/index.d.ts +86 -5
- package/auth-guard/index.d.ts +43 -5
- package/compat/analytics/index.d.ts +52 -5
- package/compat/auth/index.d.ts +58 -5
- package/compat/auth-guard/index.d.ts +44 -5
- package/compat/database/index.d.ts +107 -3
- package/compat/firestore/index.d.ts +450 -3
- package/compat/functions/index.d.ts +31 -5
- package/compat/index.d.ts +57 -5
- package/compat/messaging/index.d.ts +32 -5
- package/compat/performance/index.d.ts +43 -5
- package/compat/remote-config/index.d.ts +64 -5
- package/compat/storage/index.d.ts +104 -3
- package/data-connect/index.d.ts +34 -5
- package/database/index.d.ts +77 -5
- package/fesm2022/angular-fire-ai.mjs +4 -4
- package/fesm2022/angular-fire-analytics.mjs +10 -10
- package/fesm2022/angular-fire-app-check.mjs +4 -4
- package/fesm2022/angular-fire-app.mjs +5 -5
- package/fesm2022/angular-fire-auth-guard.mjs +7 -7
- package/fesm2022/angular-fire-auth.mjs +4 -4
- package/fesm2022/angular-fire-compat-analytics.mjs +14 -14
- package/fesm2022/angular-fire-compat-auth-guard.mjs +7 -7
- package/fesm2022/angular-fire-compat-auth.mjs +8 -8
- package/fesm2022/angular-fire-compat-database.mjs +9 -9
- package/fesm2022/angular-fire-compat-firestore.mjs +9 -9
- package/fesm2022/angular-fire-compat-functions.mjs +8 -8
- package/fesm2022/angular-fire-compat-messaging.mjs +8 -8
- package/fesm2022/angular-fire-compat-messaging.mjs.map +1 -1
- package/fesm2022/angular-fire-compat-performance.mjs +11 -11
- package/fesm2022/angular-fire-compat-remote-config.mjs +8 -8
- package/fesm2022/angular-fire-compat-storage.mjs +16 -16
- package/fesm2022/angular-fire-compat.mjs +5 -5
- package/fesm2022/angular-fire-data-connect.mjs +4 -4
- package/fesm2022/angular-fire-database.mjs +4 -4
- package/fesm2022/angular-fire-firestore-lite.mjs +4 -4
- package/fesm2022/angular-fire-firestore.mjs +4 -4
- package/fesm2022/angular-fire-functions.mjs +4 -4
- package/fesm2022/angular-fire-messaging.mjs +4 -4
- package/fesm2022/angular-fire-performance.mjs +4 -4
- package/fesm2022/angular-fire-remote-config.mjs +4 -4
- package/fesm2022/angular-fire-storage.mjs +4 -4
- package/fesm2022/angular-fire-vertexai.mjs +4 -4
- package/fesm2022/angular-fire.mjs +9 -6
- package/fesm2022/angular-fire.mjs.map +1 -1
- package/firestore/index.d.ts +99 -5
- package/firestore/lite/index.d.ts +77 -5
- package/functions/index.d.ts +35 -5
- package/index.d.ts +34 -3
- package/messaging/index.d.ts +33 -5
- package/package.json +13 -13
- package/performance/index.d.ts +40 -5
- package/publish.sh +1 -1
- package/remote-config/index.d.ts +48 -5
- package/schematics/add/index.js +1 -1
- package/schematics/deploy/actions.js +76 -86
- package/schematics/deploy/builder.js +166 -176
- package/schematics/setup/index.js +147 -162
- package/schematics/update/v7/index.js +1 -1
- package/storage/index.d.ts +47 -5
- package/vertexai/index.d.ts +33 -5
- package/ai/ai.d.ts +0 -13
- package/ai/ai.module.d.ts +0 -15
- package/ai/firebase.d.ts +0 -6
- package/ai/public_api.d.ts +0 -3
- package/analytics/analytics.d.ts +0 -13
- package/analytics/analytics.module.d.ts +0 -17
- package/analytics/firebase.d.ts +0 -14
- package/analytics/public_api.d.ts +0 -5
- package/analytics/screen-tracking.service.d.ts +0 -40
- package/analytics/user-tracking.service.d.ts +0 -11
- package/app/app.d.ts +0 -12
- package/app/app.module.d.ts +0 -14
- package/app/firebase.d.ts +0 -10
- package/app/public_api.d.ts +0 -3
- package/app-check/app-check.d.ts +0 -13
- package/app-check/app-check.module.d.ts +0 -15
- package/app-check/firebase.d.ts +0 -7
- package/app-check/public_api.d.ts +0 -3
- package/auth/auth.d.ts +0 -13
- package/auth/auth.module.d.ts +0 -15
- package/auth/firebase.d.ts +0 -55
- package/auth/public_api.d.ts +0 -4
- package/auth/rxfire.d.ts +0 -4
- package/auth-guard/auth-guard.d.ts +0 -29
- package/auth-guard/auth-guard.module.d.ts +0 -7
- package/auth-guard/public_api.d.ts +0 -2
- package/compat/analytics/analytics.d.ts +0 -22
- package/compat/analytics/analytics.module.d.ts +0 -10
- package/compat/analytics/base.d.ts +0 -8
- package/compat/analytics/public_api.d.ts +0 -4
- package/compat/analytics/screen-tracking.service.d.ts +0 -13
- package/compat/analytics/user-tracking.service.d.ts +0 -12
- package/compat/auth/auth.d.ts +0 -50
- package/compat/auth/auth.module.d.ts +0 -7
- package/compat/auth/base.d.ts +0 -36
- package/compat/auth/public_api.d.ts +0 -3
- package/compat/auth-guard/auth-guard.d.ts +0 -31
- package/compat/auth-guard/auth-guard.module.d.ts +0 -7
- package/compat/auth-guard/public_api.d.ts +0 -2
- package/compat/cache.d.ts +0 -1
- package/compat/database/database.d.ts +0 -28
- package/compat/database/database.module.d.ts +0 -7
- package/compat/database/interfaces.d.ts +0 -62
- package/compat/database/list/audit-trail.d.ts +0 -3
- package/compat/database/list/changes.d.ts +0 -3
- package/compat/database/list/create-reference.d.ts +0 -4
- package/compat/database/list/data-operation.d.ts +0 -2
- package/compat/database/list/remove.d.ts +0 -2
- package/compat/database/list/snapshot-changes.d.ts +0 -3
- package/compat/database/list/state-changes.d.ts +0 -3
- package/compat/database/list/utils.d.ts +0 -1
- package/compat/database/object/create-reference.d.ts +0 -4
- package/compat/database/object/snapshot-changes.d.ts +0 -3
- package/compat/database/observable/fromRef.d.ts +0 -10
- package/compat/database/public_api.d.ts +0 -8
- package/compat/database/utils.d.ts +0 -14
- package/compat/firebase.app.d.ts +0 -6
- package/compat/firebase.app.module.d.ts +0 -14
- package/compat/firestore/collection/changes.d.ts +0 -22
- package/compat/firestore/collection/collection.d.ts +0 -90
- package/compat/firestore/collection-group/collection-group.d.ts +0 -65
- package/compat/firestore/document/document.d.ts +0 -74
- package/compat/firestore/firestore.d.ts +0 -131
- package/compat/firestore/firestore.module.d.ts +0 -13
- package/compat/firestore/interfaces.d.ts +0 -70
- package/compat/firestore/observable/fromRef.d.ts +0 -5
- package/compat/firestore/public_api.d.ts +0 -8
- package/compat/functions/base.d.ts +0 -5
- package/compat/functions/functions.d.ts +0 -21
- package/compat/functions/functions.module.d.ts +0 -7
- package/compat/functions/public_api.d.ts +0 -3
- package/compat/messaging/base.d.ts +0 -6
- package/compat/messaging/messaging.d.ts +0 -22
- package/compat/messaging/messaging.module.d.ts +0 -7
- package/compat/messaging/public_api.d.ts +0 -2
- package/compat/performance/base.d.ts +0 -6
- package/compat/performance/performance.d.ts +0 -26
- package/compat/performance/performance.module.d.ts +0 -9
- package/compat/performance/performance.service.d.ts +0 -9
- package/compat/performance/public_api.d.ts +0 -3
- package/compat/proxy.d.ts +0 -32
- package/compat/public_api.d.ts +0 -4
- package/compat/remote-config/base.d.ts +0 -17
- package/compat/remote-config/interfaces.d.ts +0 -2
- package/compat/remote-config/public_api.d.ts +0 -2
- package/compat/remote-config/remote-config.d.ts +0 -52
- package/compat/remote-config/remote-config.module.d.ts +0 -7
- package/compat/storage/interfaces.d.ts +0 -9
- package/compat/storage/observable/fromTask.d.ts +0 -3
- package/compat/storage/pipes/storageUrl.pipe.d.ts +0 -21
- package/compat/storage/public_api.d.ts +0 -6
- package/compat/storage/ref.d.ts +0 -20
- package/compat/storage/storage.d.ts +0 -31
- package/compat/storage/storage.module.d.ts +0 -8
- package/compat/storage/task.d.ts +0 -18
- package/core.d.ts +0 -6
- package/data-connect/data-connect.d.ts +0 -9
- package/data-connect/data-connect.module.d.ts +0 -13
- package/data-connect/firebase.d.ts +0 -12
- package/data-connect/public_api.d.ts +0 -3
- package/database/database.d.ts +0 -13
- package/database/database.module.d.ts +0 -15
- package/database/firebase.d.ts +0 -40
- package/database/public_api.d.ts +0 -4
- package/database/rxfire.d.ts +0 -10
- package/firestore/firebase.d.ts +0 -60
- package/firestore/firestore.d.ts +0 -13
- package/firestore/firestore.module.d.ts +0 -15
- package/firestore/lite/firebase.d.ts +0 -41
- package/firestore/lite/lite.d.ts +0 -13
- package/firestore/lite/lite.module.d.ts +0 -15
- package/firestore/lite/public_api.d.ts +0 -4
- package/firestore/lite/rxfire.d.ts +0 -9
- package/firestore/public_api.d.ts +0 -4
- package/firestore/rxfire.d.ts +0 -12
- package/functions/firebase.d.ts +0 -6
- package/functions/functions.d.ts +0 -13
- package/functions/functions.module.d.ts +0 -15
- package/functions/public_api.d.ts +0 -4
- package/functions/rxfire.d.ts +0 -2
- package/messaging/firebase.d.ts +0 -7
- package/messaging/messaging.d.ts +0 -13
- package/messaging/messaging.module.d.ts +0 -14
- package/messaging/public_api.d.ts +0 -3
- package/performance/firebase.d.ts +0 -5
- package/performance/performance.d.ts +0 -13
- package/performance/performance.module.d.ts +0 -15
- package/performance/public_api.d.ts +0 -4
- package/performance/rxfire.d.ts +0 -8
- package/public_api.d.ts +0 -2
- package/remote-config/firebase.d.ts +0 -15
- package/remote-config/public_api.d.ts +0 -4
- package/remote-config/remote-config.d.ts +0 -13
- package/remote-config/remote-config.module.d.ts +0 -15
- package/remote-config/rxfire.d.ts +0 -6
- package/storage/firebase.d.ts +0 -17
- package/storage/public_api.d.ts +0 -4
- package/storage/rxfire.d.ts +0 -3
- package/storage/storage.d.ts +0 -13
- package/storage/storage.module.d.ts +0 -15
- package/vertexai/firebase.d.ts +0 -6
- package/vertexai/public_api.d.ts +0 -3
- package/vertexai/vertexai.d.ts +0 -13
- package/vertexai/vertexai.module.d.ts +0 -15
- package/zones.d.ts +0 -26
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
import firebase from 'firebase/compat/app';
|
|
2
|
-
import { Observable } from 'rxjs';
|
|
3
|
-
import { AngularFirestore } from '../firestore';
|
|
4
|
-
import { DocumentChangeAction, DocumentChangeType, DocumentData, Query } from '../interfaces';
|
|
5
|
-
/**
|
|
6
|
-
* AngularFirestoreCollectionGroup service
|
|
7
|
-
*
|
|
8
|
-
* This class holds a reference to a Firestore Collection Group Query.
|
|
9
|
-
*
|
|
10
|
-
* This class uses Symbol.observable to transform into Observable using Observable.from().
|
|
11
|
-
*
|
|
12
|
-
* This class is rarely used directly and should be created from the AngularFirestore service.
|
|
13
|
-
*
|
|
14
|
-
* Example:
|
|
15
|
-
*
|
|
16
|
-
* const collectionGroup = firebase.firestore.collectionGroup('stocks');
|
|
17
|
-
* const query = collectionRef.where('price', '>', '0.01');
|
|
18
|
-
* const fakeStock = new AngularFirestoreCollectionGroup<Stock>(query, afs);
|
|
19
|
-
*
|
|
20
|
-
* // Subscribe to changes as snapshots. This provides you data updates as well as delta updates.
|
|
21
|
-
* fakeStock.valueChanges().subscribe(value => console.log(value));
|
|
22
|
-
*/
|
|
23
|
-
export declare class AngularFirestoreCollectionGroup<T = DocumentData> {
|
|
24
|
-
private readonly query;
|
|
25
|
-
private readonly afs;
|
|
26
|
-
private readonly injector;
|
|
27
|
-
/**
|
|
28
|
-
* The constructor takes in a CollectionGroupQuery to provide wrapper methods
|
|
29
|
-
* for data operations and data streaming.
|
|
30
|
-
*/
|
|
31
|
-
constructor(query: Query<T>, afs: AngularFirestore);
|
|
32
|
-
/**
|
|
33
|
-
* Listen to the latest change in the stream. This method returns changes
|
|
34
|
-
* as they occur and they are not sorted by query order. This allows you to construct
|
|
35
|
-
* your own data structure.
|
|
36
|
-
*/
|
|
37
|
-
stateChanges(events?: DocumentChangeType[]): Observable<DocumentChangeAction<T>[]>;
|
|
38
|
-
/**
|
|
39
|
-
* Create a stream of changes as they occur it time. This method is similar to stateChanges()
|
|
40
|
-
* but it collects each event in an array over time.
|
|
41
|
-
*/
|
|
42
|
-
auditTrail(events?: DocumentChangeType[]): Observable<DocumentChangeAction<T>[]>;
|
|
43
|
-
/**
|
|
44
|
-
* Create a stream of synchronized changes. This method keeps the local array in sorted
|
|
45
|
-
* query order.
|
|
46
|
-
*/
|
|
47
|
-
snapshotChanges(events?: DocumentChangeType[]): Observable<DocumentChangeAction<T>[]>;
|
|
48
|
-
/**
|
|
49
|
-
* Listen to all documents in the collection and its possible query as an Observable.
|
|
50
|
-
*
|
|
51
|
-
* If the `idField` option is provided, document IDs are included and mapped to the
|
|
52
|
-
* provided `idField` property name.
|
|
53
|
-
*/
|
|
54
|
-
valueChanges(): Observable<T[]>;
|
|
55
|
-
valueChanges({}: {}): Observable<T[]>;
|
|
56
|
-
valueChanges<K extends string>(options: {
|
|
57
|
-
idField: K;
|
|
58
|
-
}): Observable<(T & {
|
|
59
|
-
[T in K]: string;
|
|
60
|
-
})[]>;
|
|
61
|
-
/**
|
|
62
|
-
* Retrieve the results of the query once.
|
|
63
|
-
*/
|
|
64
|
-
get(options?: firebase.firestore.GetOptions): Observable<firebase.firestore.QuerySnapshot<T>>;
|
|
65
|
-
}
|
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
import firebase from 'firebase/compat/app';
|
|
2
|
-
import { Observable } from 'rxjs';
|
|
3
|
-
import { AngularFirestoreCollection } from '../collection/collection';
|
|
4
|
-
import { AngularFirestore } from '../firestore';
|
|
5
|
-
import { Action, DocumentData, DocumentReference, DocumentSnapshot, QueryFn, SetOptions } from '../interfaces';
|
|
6
|
-
/**
|
|
7
|
-
* AngularFirestoreDocument service
|
|
8
|
-
*
|
|
9
|
-
* This class creates a reference to a Firestore Document. A reference is provided in
|
|
10
|
-
* in the constructor. The class is generic which gives you type safety for data update
|
|
11
|
-
* methods and data streaming.
|
|
12
|
-
*
|
|
13
|
-
* This class uses Symbol.observable to transform into Observable using Observable.from().
|
|
14
|
-
*
|
|
15
|
-
* This class is rarely used directly and should be created from the AngularFirestore service.
|
|
16
|
-
*
|
|
17
|
-
* Example:
|
|
18
|
-
*
|
|
19
|
-
* const fakeStock = new AngularFirestoreDocument<Stock>(doc('stocks/FAKE'));
|
|
20
|
-
* await fakeStock.set({ name: 'FAKE', price: 0.01 });
|
|
21
|
-
* fakeStock.valueChanges().map(snap => {
|
|
22
|
-
* if(snap.exists) return snap.data();
|
|
23
|
-
* return null;
|
|
24
|
-
* }).subscribe(value => console.log(value));
|
|
25
|
-
* // OR! Transform using Observable.from() and the data is unwrapped for you
|
|
26
|
-
* Observable.from(fakeStock).subscribe(value => console.log(value));
|
|
27
|
-
*/
|
|
28
|
-
export declare class AngularFirestoreDocument<T = DocumentData> {
|
|
29
|
-
ref: DocumentReference<T>;
|
|
30
|
-
private afs;
|
|
31
|
-
private readonly injector;
|
|
32
|
-
/**
|
|
33
|
-
* The constructor takes in a DocumentReference to provide wrapper methods
|
|
34
|
-
* for data operations, data streaming, and Symbol.observable.
|
|
35
|
-
*/
|
|
36
|
-
constructor(ref: DocumentReference<T>, afs: AngularFirestore);
|
|
37
|
-
/**
|
|
38
|
-
* Create or overwrite a single document.
|
|
39
|
-
*/
|
|
40
|
-
set(data: T, options?: SetOptions): Promise<void>;
|
|
41
|
-
/**
|
|
42
|
-
* Update some fields of a document without overwriting the entire document.
|
|
43
|
-
*/
|
|
44
|
-
update(data: Partial<T>): Promise<void>;
|
|
45
|
-
/**
|
|
46
|
-
* Delete a document.
|
|
47
|
-
*/
|
|
48
|
-
delete(): Promise<void>;
|
|
49
|
-
/**
|
|
50
|
-
* Create a reference to a sub-collection given a path and an optional query
|
|
51
|
-
* function.
|
|
52
|
-
*/
|
|
53
|
-
collection<R = DocumentData>(path: string, queryFn?: QueryFn): AngularFirestoreCollection<R>;
|
|
54
|
-
/**
|
|
55
|
-
* Listen to snapshot updates from the document.
|
|
56
|
-
*/
|
|
57
|
-
snapshotChanges(): Observable<Action<DocumentSnapshot<T>>>;
|
|
58
|
-
/**
|
|
59
|
-
* Listen to unwrapped snapshot updates from the document.
|
|
60
|
-
*
|
|
61
|
-
* If the `idField` option is provided, document IDs are included and mapped to the
|
|
62
|
-
* provided `idField` property name.
|
|
63
|
-
*/
|
|
64
|
-
valueChanges(options?: unknown): Observable<T | undefined>;
|
|
65
|
-
valueChanges<K extends string>(options: {
|
|
66
|
-
idField: K;
|
|
67
|
-
}): Observable<(T & {
|
|
68
|
-
[T in K]: string;
|
|
69
|
-
}) | undefined>;
|
|
70
|
-
/**
|
|
71
|
-
* Retrieve the document once.
|
|
72
|
-
*/
|
|
73
|
-
get(options?: firebase.firestore.GetOptions): Observable<firebase.firestore.DocumentSnapshot<T>>;
|
|
74
|
-
}
|
|
@@ -1,131 +0,0 @@
|
|
|
1
|
-
import { InjectionToken, NgZone } from '@angular/core';
|
|
2
|
-
import { ɵAngularFireSchedulers } from '@angular/fire';
|
|
3
|
-
import { AppCheckInstances } from '@angular/fire/app-check';
|
|
4
|
-
import { AngularFireAuth } from '@angular/fire/compat/auth';
|
|
5
|
-
import { FirebaseOptions } from 'firebase/app';
|
|
6
|
-
import firebase from 'firebase/compat/app';
|
|
7
|
-
import { Observable } from 'rxjs';
|
|
8
|
-
import { AngularFirestoreCollection } from './collection/collection';
|
|
9
|
-
import { AngularFirestoreCollectionGroup } from './collection-group/collection-group';
|
|
10
|
-
import { AngularFirestoreDocument } from './document/document';
|
|
11
|
-
import { AssociatedReference, CollectionReference, DocumentReference, PersistenceSettings, QueryFn, QueryGroupFn, Settings } from './interfaces';
|
|
12
|
-
import 'firebase/compat/auth';
|
|
13
|
-
import 'firebase/compat/firestore';
|
|
14
|
-
import * as i0 from "@angular/core";
|
|
15
|
-
/**
|
|
16
|
-
* The value of this token determines whether or not the firestore will have persistance enabled
|
|
17
|
-
*/
|
|
18
|
-
export declare const ENABLE_PERSISTENCE: InjectionToken<boolean>;
|
|
19
|
-
export declare const PERSISTENCE_SETTINGS: InjectionToken<firebase.firestore.PersistenceSettings>;
|
|
20
|
-
export declare const SETTINGS: InjectionToken<firebase.firestore.Settings>;
|
|
21
|
-
export declare const USE_EMULATOR: InjectionToken<[host: string, port: number, options?: {
|
|
22
|
-
mockUserToken?: firebase.firestore.EmulatorMockTokenOptions | string;
|
|
23
|
-
}]>;
|
|
24
|
-
/**
|
|
25
|
-
* A utility methods for associating a collection reference with
|
|
26
|
-
* a query.
|
|
27
|
-
*
|
|
28
|
-
* @param collectionRef - A collection reference to query
|
|
29
|
-
* @param queryFn - The callback to create a query
|
|
30
|
-
*
|
|
31
|
-
* Example:
|
|
32
|
-
* const { query, ref } = associateQuery(docRef.collection('items'), ref => {
|
|
33
|
-
* return ref.where('age', '<', 200);
|
|
34
|
-
* });
|
|
35
|
-
*/
|
|
36
|
-
export declare function associateQuery<T>(collectionRef: CollectionReference<T>, queryFn?: (ref: any) => any): AssociatedReference<T>;
|
|
37
|
-
/**
|
|
38
|
-
* AngularFirestore Service
|
|
39
|
-
*
|
|
40
|
-
* This service is the main entry point for this feature module. It provides
|
|
41
|
-
* an API for creating Collection and Reference services. These services can
|
|
42
|
-
* then be used to do data updates and observable streams of the data.
|
|
43
|
-
*
|
|
44
|
-
* Example:
|
|
45
|
-
*
|
|
46
|
-
* import { Component } from '@angular/core';
|
|
47
|
-
* import { AngularFirestore, AngularFirestoreCollection, AngularFirestoreDocument } from '@angular/fire/firestore';
|
|
48
|
-
* import { Observable } from 'rxjs/Observable';
|
|
49
|
-
* import { from } from 'rxjs/observable';
|
|
50
|
-
*
|
|
51
|
-
* @Component({
|
|
52
|
-
* selector: 'app-my-component',
|
|
53
|
-
* template: `
|
|
54
|
-
* <h2>Items for {{ (profile | async)?.name }}
|
|
55
|
-
* <ul>
|
|
56
|
-
* <li *ngFor="let item of items | async">{{ item.name }}</li>
|
|
57
|
-
* </ul>
|
|
58
|
-
* <div class="control-input">
|
|
59
|
-
* <input type="text" #itemname />
|
|
60
|
-
* <button (click)="addItem(itemname.value)">Add Item</button>
|
|
61
|
-
* </div>
|
|
62
|
-
* `
|
|
63
|
-
* })
|
|
64
|
-
* export class MyComponent implements OnInit {
|
|
65
|
-
*
|
|
66
|
-
* // services for data operations and data streaming
|
|
67
|
-
* private readonly itemsRef: AngularFirestoreCollection<Item>;
|
|
68
|
-
* private readonly profileRef: AngularFirestoreDocument<Profile>;
|
|
69
|
-
*
|
|
70
|
-
* // observables for template
|
|
71
|
-
* items: Observable<Item[]>;
|
|
72
|
-
* profile: Observable<Profile>;
|
|
73
|
-
*
|
|
74
|
-
* // inject main service
|
|
75
|
-
* constructor(private readonly afs: AngularFirestore) {}
|
|
76
|
-
*
|
|
77
|
-
* ngOnInit() {
|
|
78
|
-
* this.itemsRef = afs.collection('items', ref => ref.where('user', '==', 'davideast').limit(10));
|
|
79
|
-
* this.items = this.itemsRef.valueChanges().map(snap => snap.docs.map(data => doc.data()));
|
|
80
|
-
* // this.items = from(this.itemsRef); // you can also do this with no mapping
|
|
81
|
-
*
|
|
82
|
-
* this.profileRef = afs.doc('users/davideast');
|
|
83
|
-
* this.profile = this.profileRef.valueChanges();
|
|
84
|
-
* }
|
|
85
|
-
*
|
|
86
|
-
* addItem(name: string) {
|
|
87
|
-
* const user = 'davideast';
|
|
88
|
-
* this.itemsRef.add({ name, user });
|
|
89
|
-
* }
|
|
90
|
-
* }
|
|
91
|
-
*/
|
|
92
|
-
export declare class AngularFirestore {
|
|
93
|
-
schedulers: ɵAngularFireSchedulers;
|
|
94
|
-
readonly firestore: firebase.firestore.Firestore;
|
|
95
|
-
readonly persistenceEnabled$: Observable<boolean>;
|
|
96
|
-
private readonly ngZone;
|
|
97
|
-
/**
|
|
98
|
-
* Each Feature of AngularFire has a FirebaseApp injected. This way we
|
|
99
|
-
* don't rely on the main Firebase App instance and we can create named
|
|
100
|
-
* apps and use multiple apps.
|
|
101
|
-
*/
|
|
102
|
-
constructor(options: FirebaseOptions, name: string | null | undefined, shouldEnablePersistence: boolean | null, settings: Settings | null, platformId: Object, zone: NgZone, schedulers: ɵAngularFireSchedulers, persistenceSettings: PersistenceSettings | null, _useEmulator: any, auth: AngularFireAuth, useAuthEmulator: any, authSettings: any, // can't use firebase.auth.AuthSettings here
|
|
103
|
-
tenantId: string | null, languageCode: string | null, useDeviceLanguage: boolean | null, persistence: string | null, _appCheckInstances: AppCheckInstances);
|
|
104
|
-
/**
|
|
105
|
-
* Create a reference to a Firestore Collection based on a path or
|
|
106
|
-
* CollectionReference and an optional query function to narrow the result
|
|
107
|
-
* set.
|
|
108
|
-
*/
|
|
109
|
-
collection<T>(path: string, queryFn?: QueryFn): AngularFirestoreCollection<T>;
|
|
110
|
-
collection<T>(ref: CollectionReference, queryFn?: QueryFn): AngularFirestoreCollection<T>;
|
|
111
|
-
/**
|
|
112
|
-
* Create a reference to a Firestore Collection Group based on a collectionId
|
|
113
|
-
* and an optional query function to narrow the result
|
|
114
|
-
* set.
|
|
115
|
-
*/
|
|
116
|
-
collectionGroup<T>(collectionId: string, queryGroupFn?: QueryGroupFn<T>): AngularFirestoreCollectionGroup<T>;
|
|
117
|
-
/**
|
|
118
|
-
* Create a reference to a Firestore Document based on a path or
|
|
119
|
-
* DocumentReference. Note that documents are not queryable because they are
|
|
120
|
-
* simply objects. However, documents have sub-collections that return a
|
|
121
|
-
* Collection reference and can be queried.
|
|
122
|
-
*/
|
|
123
|
-
doc<T>(path: string): AngularFirestoreDocument<T>;
|
|
124
|
-
doc<T>(ref: DocumentReference): AngularFirestoreDocument<T>;
|
|
125
|
-
/**
|
|
126
|
-
* Returns a generated Firestore Document Id.
|
|
127
|
-
*/
|
|
128
|
-
createId(): string;
|
|
129
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AngularFirestore, [null, { optional: true; }, { optional: true; }, { optional: true; }, null, null, null, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }]>;
|
|
130
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<AngularFirestore>;
|
|
131
|
-
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { ModuleWithProviders } from '@angular/core';
|
|
2
|
-
import { PersistenceSettings } from './interfaces';
|
|
3
|
-
import * as i0 from "@angular/core";
|
|
4
|
-
export declare class AngularFirestoreModule {
|
|
5
|
-
constructor();
|
|
6
|
-
/**
|
|
7
|
-
* Attempt to enable persistent storage, if possible
|
|
8
|
-
*/
|
|
9
|
-
static enablePersistence(persistenceSettings?: PersistenceSettings): ModuleWithProviders<AngularFirestoreModule>;
|
|
10
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AngularFirestoreModule, never>;
|
|
11
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<AngularFirestoreModule, never, never, never>;
|
|
12
|
-
static ɵinj: i0.ɵɵInjectorDeclaration<AngularFirestoreModule>;
|
|
13
|
-
}
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
import firebase from 'firebase/compat/app';
|
|
2
|
-
import { Subscriber } from 'rxjs';
|
|
3
|
-
export type Settings = firebase.firestore.Settings;
|
|
4
|
-
export type CollectionReference<T = DocumentData> = firebase.firestore.CollectionReference<T>;
|
|
5
|
-
export type DocumentReference<T = DocumentData> = firebase.firestore.DocumentReference<T>;
|
|
6
|
-
export type PersistenceSettings = firebase.firestore.PersistenceSettings;
|
|
7
|
-
export type DocumentChangeType = firebase.firestore.DocumentChangeType;
|
|
8
|
-
export type SnapshotOptions = firebase.firestore.SnapshotOptions;
|
|
9
|
-
export type FieldPath = firebase.firestore.FieldPath;
|
|
10
|
-
export type Query<T = DocumentData> = firebase.firestore.Query<T>;
|
|
11
|
-
export type SetOptions = firebase.firestore.SetOptions;
|
|
12
|
-
export type DocumentData = firebase.firestore.DocumentData;
|
|
13
|
-
export interface DocumentSnapshotExists<T> extends firebase.firestore.DocumentSnapshot<T> {
|
|
14
|
-
readonly exists: true;
|
|
15
|
-
data(options?: SnapshotOptions): T;
|
|
16
|
-
}
|
|
17
|
-
export interface DocumentSnapshotDoesNotExist extends firebase.firestore.DocumentSnapshot {
|
|
18
|
-
readonly exists: false;
|
|
19
|
-
data(options?: SnapshotOptions): undefined;
|
|
20
|
-
get(fieldPath: string | FieldPath, options?: SnapshotOptions): undefined;
|
|
21
|
-
}
|
|
22
|
-
export type DocumentSnapshot<T> = DocumentSnapshotExists<T> | DocumentSnapshotDoesNotExist;
|
|
23
|
-
export interface QueryDocumentSnapshot<T> extends firebase.firestore.QueryDocumentSnapshot<T> {
|
|
24
|
-
data(options?: SnapshotOptions): T;
|
|
25
|
-
}
|
|
26
|
-
export interface QuerySnapshot<T> extends firebase.firestore.QuerySnapshot<T> {
|
|
27
|
-
readonly docs: QueryDocumentSnapshot<T>[];
|
|
28
|
-
}
|
|
29
|
-
export interface DocumentChange<T> extends firebase.firestore.DocumentChange<T> {
|
|
30
|
-
readonly doc: QueryDocumentSnapshot<T>;
|
|
31
|
-
}
|
|
32
|
-
export interface DocumentChangeAction<T> {
|
|
33
|
-
type: DocumentChangeType;
|
|
34
|
-
payload: DocumentChange<T>;
|
|
35
|
-
}
|
|
36
|
-
export interface Action<T> {
|
|
37
|
-
type: string;
|
|
38
|
-
payload: T;
|
|
39
|
-
}
|
|
40
|
-
export interface Reference {
|
|
41
|
-
onSnapshot: (options: firebase.firestore.SnapshotListenOptions, sub: Subscriber<any>) => any;
|
|
42
|
-
}
|
|
43
|
-
export type QueryFn<T = DocumentData> = (ref: CollectionReference<T>) => Query<T>;
|
|
44
|
-
export type QueryGroupFn<T = DocumentData> = (query: Query<T>) => Query<T>;
|
|
45
|
-
/**
|
|
46
|
-
* A structure that provides an association between a reference
|
|
47
|
-
* and a query on that reference. Note: Performing operations
|
|
48
|
-
* on the reference can lead to confusing results with complicated
|
|
49
|
-
* queries.
|
|
50
|
-
*
|
|
51
|
-
* Example:
|
|
52
|
-
*
|
|
53
|
-
* const query = ref.where('type', '==', 'Book').
|
|
54
|
-
* .where('price', '>' 18.00)
|
|
55
|
-
* .where('price', '<' 100.00)
|
|
56
|
-
* .where('category', '==', 'Fiction')
|
|
57
|
-
* .where('publisher', '==', 'BigPublisher')
|
|
58
|
-
*
|
|
59
|
-
* // This addition would not be a result of the query above
|
|
60
|
-
* ref.add({
|
|
61
|
-
* type: 'Magazine',
|
|
62
|
-
* price: 4.99,
|
|
63
|
-
* category: 'Sports',
|
|
64
|
-
* publisher: 'SportsPublisher'
|
|
65
|
-
* });
|
|
66
|
-
*/
|
|
67
|
-
export interface AssociatedReference<T = DocumentData> {
|
|
68
|
-
ref: CollectionReference<T>;
|
|
69
|
-
query: Query<T>;
|
|
70
|
-
}
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { Observable, SchedulerLike } from 'rxjs';
|
|
2
|
-
import { Action, DocumentReference, DocumentSnapshot, Query, QuerySnapshot } from '../interfaces';
|
|
3
|
-
export declare function fromRef<R, T>(ref: DocumentReference<T> | Query<T>, scheduler?: SchedulerLike): Observable<R>;
|
|
4
|
-
export declare function fromDocRef<T>(ref: DocumentReference<T>, scheduler?: SchedulerLike): Observable<Action<DocumentSnapshot<T>>>;
|
|
5
|
-
export declare function fromCollectionRef<T>(ref: Query<T>, scheduler?: SchedulerLike): Observable<Action<QuerySnapshot<T>>>;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
export * from './firestore';
|
|
2
|
-
export * from './firestore.module';
|
|
3
|
-
export * from './collection/collection';
|
|
4
|
-
export * from './collection-group/collection-group';
|
|
5
|
-
export * from './document/document';
|
|
6
|
-
export * from './collection/changes';
|
|
7
|
-
export * from './observable/fromRef';
|
|
8
|
-
export * from './interfaces';
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { InjectionToken, NgZone } from '@angular/core';
|
|
2
|
-
import { ɵAngularFireSchedulers } from '@angular/fire';
|
|
3
|
-
import { AppCheckInstances } from '@angular/fire/app-check';
|
|
4
|
-
import { ɵPromiseProxy } from '@angular/fire/compat';
|
|
5
|
-
import { HttpsCallableOptions } from '@firebase/functions-types';
|
|
6
|
-
import { FirebaseOptions } from 'firebase/app';
|
|
7
|
-
import firebase from 'firebase/compat/app';
|
|
8
|
-
import { Observable } from 'rxjs';
|
|
9
|
-
import * as i0 from "@angular/core";
|
|
10
|
-
export declare const ORIGIN: InjectionToken<string>;
|
|
11
|
-
export declare const REGION: InjectionToken<string>;
|
|
12
|
-
export declare const USE_EMULATOR: InjectionToken<[host: string, port: number]>;
|
|
13
|
-
export interface AngularFireFunctions extends Omit<ɵPromiseProxy<firebase.functions.Functions>, 'httpsCallable'> {
|
|
14
|
-
}
|
|
15
|
-
export declare class AngularFireFunctions {
|
|
16
|
-
readonly httpsCallable: <T = any, R = any>(name: string, options?: HttpsCallableOptions) => (data: T) => Observable<R>;
|
|
17
|
-
constructor(options: FirebaseOptions, name: string | null | undefined, zone: NgZone, schedulers: ɵAngularFireSchedulers, region: string | null, origin: string | null, _useEmulator: any, // can't use the tuple here
|
|
18
|
-
_appCheckInstances: AppCheckInstances);
|
|
19
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AngularFireFunctions, [null, { optional: true; }, null, null, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; }]>;
|
|
20
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<AngularFireFunctions>;
|
|
21
|
-
}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import * as i0 from "@angular/core";
|
|
2
|
-
export declare class AngularFireFunctionsModule {
|
|
3
|
-
constructor();
|
|
4
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AngularFireFunctionsModule, never>;
|
|
5
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<AngularFireFunctionsModule, never, never, never>;
|
|
6
|
-
static ɵinj: i0.ɵɵInjectorDeclaration<AngularFireFunctionsModule>;
|
|
7
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { InjectionToken, NgZone } from '@angular/core';
|
|
2
|
-
import { ɵAngularFireSchedulers } from '@angular/fire';
|
|
3
|
-
import { ɵPromiseProxy } from '@angular/fire/compat';
|
|
4
|
-
import { FirebaseOptions } from 'firebase/app';
|
|
5
|
-
import firebase from 'firebase/compat/app';
|
|
6
|
-
import { Observable } from 'rxjs';
|
|
7
|
-
import * as i0 from "@angular/core";
|
|
8
|
-
export declare const VAPID_KEY: InjectionToken<string>;
|
|
9
|
-
export declare const SERVICE_WORKER: InjectionToken<Promise<ServiceWorkerRegistration>>;
|
|
10
|
-
export interface AngularFireMessaging extends Omit<ɵPromiseProxy<firebase.messaging.Messaging>, 'deleteToken' | 'getToken' | 'requestPermission'> {
|
|
11
|
-
}
|
|
12
|
-
export declare class AngularFireMessaging {
|
|
13
|
-
readonly requestPermission: Observable<NotificationPermission>;
|
|
14
|
-
readonly getToken: Observable<string | null>;
|
|
15
|
-
readonly tokenChanges: Observable<string | null>;
|
|
16
|
-
readonly messages: Observable<firebase.messaging.MessagePayload>;
|
|
17
|
-
readonly requestToken: Observable<string | null>;
|
|
18
|
-
readonly deleteToken: (token: string) => Observable<boolean>;
|
|
19
|
-
constructor(options: FirebaseOptions, name: string | null | undefined, platformId: Object, zone: NgZone, schedulers: ɵAngularFireSchedulers, vapidKey: string | null, _serviceWorker: any);
|
|
20
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AngularFireMessaging, [null, { optional: true; }, null, null, null, { optional: true; }, { optional: true; }]>;
|
|
21
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<AngularFireMessaging>;
|
|
22
|
-
}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import * as i0 from "@angular/core";
|
|
2
|
-
export declare class AngularFireMessagingModule {
|
|
3
|
-
constructor();
|
|
4
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AngularFireMessagingModule, never>;
|
|
5
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<AngularFireMessagingModule, never, never, never>;
|
|
6
|
-
static ɵinj: i0.ɵɵInjectorDeclaration<AngularFireMessagingModule>;
|
|
7
|
-
}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { InjectionToken, NgZone } from '@angular/core';
|
|
2
|
-
import { ɵPromiseProxy } from '@angular/fire/compat';
|
|
3
|
-
import { FirebaseApp } from '@angular/fire/compat';
|
|
4
|
-
import firebase from 'firebase/compat/app';
|
|
5
|
-
import { Observable } from 'rxjs';
|
|
6
|
-
import * as i0 from "@angular/core";
|
|
7
|
-
export declare const INSTRUMENTATION_ENABLED: InjectionToken<boolean>;
|
|
8
|
-
export declare const DATA_COLLECTION_ENABLED: InjectionToken<boolean>;
|
|
9
|
-
export interface AngularFirePerformance extends ɵPromiseProxy<firebase.performance.Performance> {
|
|
10
|
-
}
|
|
11
|
-
export declare class AngularFirePerformance {
|
|
12
|
-
private zone;
|
|
13
|
-
private readonly performance;
|
|
14
|
-
constructor(app: FirebaseApp, instrumentationEnabled: boolean | null, dataCollectionEnabled: boolean | null, zone: NgZone, platformId: Object);
|
|
15
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AngularFirePerformance, [null, { optional: true; }, { optional: true; }, null, null]>;
|
|
16
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<AngularFirePerformance>;
|
|
17
|
-
}
|
|
18
|
-
export declare const traceUntil: <T = any>(name: string, test: (a: T) => boolean, options?: {
|
|
19
|
-
orComplete?: boolean;
|
|
20
|
-
}) => (source$: Observable<T>) => Observable<T>;
|
|
21
|
-
export declare const traceWhile: <T = any>(name: string, test: (a: T) => boolean, options?: {
|
|
22
|
-
orComplete?: boolean;
|
|
23
|
-
}) => (source$: Observable<T>) => Observable<T>;
|
|
24
|
-
export declare const traceUntilComplete: <T = any>(name: string) => (source$: Observable<T>) => Observable<T>;
|
|
25
|
-
export declare const traceUntilFirst: <T = any>(name: string) => (source$: Observable<T>) => Observable<T>;
|
|
26
|
-
export declare const trace: <T = any>(name: string) => (source$: Observable<T>) => Observable<T>;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { AngularFirePerformance } from './performance';
|
|
2
|
-
import { PerformanceMonitoringService } from './performance.service';
|
|
3
|
-
import * as i0 from "@angular/core";
|
|
4
|
-
export declare class AngularFirePerformanceModule {
|
|
5
|
-
constructor(perf: AngularFirePerformance, _: PerformanceMonitoringService);
|
|
6
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AngularFirePerformanceModule, [null, { optional: true; }]>;
|
|
7
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<AngularFirePerformanceModule, never, never, never>;
|
|
8
|
-
static ɵinj: i0.ɵɵInjectorDeclaration<AngularFirePerformanceModule>;
|
|
9
|
-
}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { ApplicationRef, OnDestroy } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
export declare class PerformanceMonitoringService implements OnDestroy {
|
|
4
|
-
private disposable;
|
|
5
|
-
constructor(appRef: ApplicationRef);
|
|
6
|
-
ngOnDestroy(): void;
|
|
7
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<PerformanceMonitoringService, never>;
|
|
8
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<PerformanceMonitoringService>;
|
|
9
|
-
}
|
package/compat/proxy.d.ts
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { NgZone } from '@angular/core';
|
|
2
|
-
import { Observable } from 'rxjs';
|
|
3
|
-
type MyFunction = (...args: any[]) => any;
|
|
4
|
-
type FunctionPropertyNames<T> = {
|
|
5
|
-
[K in keyof T]: T[K] extends MyFunction ? K : never;
|
|
6
|
-
}[keyof T];
|
|
7
|
-
type ReturnTypeOrNever<T> = T extends MyFunction ? ReturnType<T> : never;
|
|
8
|
-
type ParametersOrNever<T> = T extends MyFunction ? Parameters<T> : never;
|
|
9
|
-
type PromiseReturningFunctionPropertyNames<T> = {
|
|
10
|
-
[K in FunctionPropertyNames<T>]: ReturnTypeOrNever<T[K]> extends Promise<any> ? K : never;
|
|
11
|
-
}[FunctionPropertyNames<T>];
|
|
12
|
-
type NonPromiseReturningFunctionPropertyNames<T> = {
|
|
13
|
-
[K in FunctionPropertyNames<T>]: ReturnTypeOrNever<T[K]> extends Promise<any> ? never : K;
|
|
14
|
-
}[FunctionPropertyNames<T>];
|
|
15
|
-
type NonFunctionPropertyNames<T> = {
|
|
16
|
-
[K in keyof T]: T[K] extends MyFunction ? never : K;
|
|
17
|
-
}[keyof T];
|
|
18
|
-
export type ɵPromiseProxy<T> = {
|
|
19
|
-
[K in NonFunctionPropertyNames<T>]: Promise<T[K]>;
|
|
20
|
-
} & {
|
|
21
|
-
[K in NonPromiseReturningFunctionPropertyNames<T>]: (...args: ParametersOrNever<T[K]>) => Promise<ReturnTypeOrNever<T[K]>>;
|
|
22
|
-
} & {
|
|
23
|
-
[K in PromiseReturningFunctionPropertyNames<T>]: T[K];
|
|
24
|
-
};
|
|
25
|
-
export declare const ɵlazySDKProxy: (klass: any, observable: Observable<any>, zone: NgZone, options?: {
|
|
26
|
-
spy?: {
|
|
27
|
-
get?: ((name: string, it: any) => void);
|
|
28
|
-
apply?: ((name: string, args: any[], it: any) => void);
|
|
29
|
-
};
|
|
30
|
-
}) => any;
|
|
31
|
-
export declare const ɵapplyMixins: (derivedCtor: any, constructors: any[]) => void;
|
|
32
|
-
export {};
|
package/compat/public_api.d.ts
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
export declare const proxyPolyfillCompat: {
|
|
2
|
-
app: any;
|
|
3
|
-
settings: any;
|
|
4
|
-
defaultConfig: any;
|
|
5
|
-
fetchTimeMillis: any;
|
|
6
|
-
lastFetchStatus: any;
|
|
7
|
-
activate: any;
|
|
8
|
-
ensureInitialized: any;
|
|
9
|
-
fetch: any;
|
|
10
|
-
fetchAndActivate: any;
|
|
11
|
-
getAll: any;
|
|
12
|
-
getBoolean: any;
|
|
13
|
-
getNumber: any;
|
|
14
|
-
getString: any;
|
|
15
|
-
getValue: any;
|
|
16
|
-
setLogLevel: any;
|
|
17
|
-
};
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { InjectionToken, NgZone } from '@angular/core';
|
|
2
|
-
import { ɵAngularFireSchedulers } from '@angular/fire';
|
|
3
|
-
import { ɵPromiseProxy } from '@angular/fire/compat';
|
|
4
|
-
import { FirebaseOptions } from 'firebase/app';
|
|
5
|
-
import firebase from 'firebase/compat/app';
|
|
6
|
-
import { MonoTypeOperatorFunction, Observable, OperatorFunction } from 'rxjs';
|
|
7
|
-
import { Settings } from './interfaces';
|
|
8
|
-
import * as i0 from "@angular/core";
|
|
9
|
-
export type ConfigTemplate = Record<string, string | number | boolean>;
|
|
10
|
-
export declare const SETTINGS: InjectionToken<firebase.remoteConfig.Settings>;
|
|
11
|
-
export declare const DEFAULTS: InjectionToken<ConfigTemplate>;
|
|
12
|
-
export interface AngularFireRemoteConfig extends ɵPromiseProxy<firebase.remoteConfig.RemoteConfig> {
|
|
13
|
-
}
|
|
14
|
-
export declare class Value implements firebase.remoteConfig.Value {
|
|
15
|
-
_source: firebase.remoteConfig.ValueSource;
|
|
16
|
-
_value: string;
|
|
17
|
-
asBoolean(): boolean;
|
|
18
|
-
asString(): string;
|
|
19
|
-
asNumber(): number;
|
|
20
|
-
getSource(): firebase.remoteConfig.ValueSource;
|
|
21
|
-
constructor(_source: firebase.remoteConfig.ValueSource, _value: string);
|
|
22
|
-
}
|
|
23
|
-
export declare class Parameter extends Value {
|
|
24
|
-
key: string;
|
|
25
|
-
fetchTimeMillis: number;
|
|
26
|
-
constructor(key: string, fetchTimeMillis: number, source: firebase.remoteConfig.ValueSource, value: string);
|
|
27
|
-
}
|
|
28
|
-
export declare const filterRemote: () => MonoTypeOperatorFunction<Parameter | Parameter[]>;
|
|
29
|
-
export declare const filterFresh: (howRecentInMillis: number) => MonoTypeOperatorFunction<Parameter | Parameter[]>;
|
|
30
|
-
export declare class AngularFireRemoteConfig {
|
|
31
|
-
private zone;
|
|
32
|
-
readonly changes: Observable<Parameter>;
|
|
33
|
-
readonly parameters: Observable<Parameter[]>;
|
|
34
|
-
readonly numbers: Observable<Record<string, number | undefined>> & Record<string, Observable<number>>;
|
|
35
|
-
readonly booleans: Observable<Record<string, boolean | undefined>> & Record<string, Observable<boolean>>;
|
|
36
|
-
readonly strings: Observable<Record<string, string | undefined>> & Record<string, Observable<string | undefined>>;
|
|
37
|
-
private readonly injector;
|
|
38
|
-
constructor(options: FirebaseOptions, name: string | null | undefined, settings: Settings | null, defaultConfig: ConfigTemplate | null, zone: NgZone, schedulers: ɵAngularFireSchedulers, platformId: Object);
|
|
39
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AngularFireRemoteConfig, [null, { optional: true; }, { optional: true; }, { optional: true; }, null, null, null]>;
|
|
40
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<AngularFireRemoteConfig>;
|
|
41
|
-
}
|
|
42
|
-
export declare const budget: <T>(interval: number) => MonoTypeOperatorFunction<T>;
|
|
43
|
-
export declare function scanToObject(): OperatorFunction<Parameter, Record<string, string | undefined>>;
|
|
44
|
-
export declare function scanToObject(to: 'numbers'): OperatorFunction<Parameter, Record<string, number | undefined>>;
|
|
45
|
-
export declare function scanToObject(to: 'booleans'): OperatorFunction<Parameter, Record<string, boolean | undefined>>;
|
|
46
|
-
export declare function scanToObject(to: 'strings'): OperatorFunction<Parameter, Record<string, string | undefined>>;
|
|
47
|
-
export declare function scanToObject<T extends ConfigTemplate>(template: T): OperatorFunction<Parameter, T & Record<string, string | undefined>>;
|
|
48
|
-
export declare function mapToObject(): OperatorFunction<Parameter[], Record<string, string | undefined>>;
|
|
49
|
-
export declare function mapToObject(to: 'numbers'): OperatorFunction<Parameter[], Record<string, number | undefined>>;
|
|
50
|
-
export declare function mapToObject(to: 'booleans'): OperatorFunction<Parameter[], Record<string, boolean | undefined>>;
|
|
51
|
-
export declare function mapToObject(to: 'strings'): OperatorFunction<Parameter[], Record<string, string | undefined>>;
|
|
52
|
-
export declare function mapToObject<T extends ConfigTemplate>(template: T): OperatorFunction<Parameter[], T & Record<string, string | undefined>>;
|