@dereekb/dbx-firebase 4.1.0 → 5.1.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/LICENSE +21 -0
- package/_index.scss +4 -4
- package/esm2020/lib/auth/appcheck/appcheck.interceptor.mjs +80 -0
- package/esm2020/lib/auth/appcheck/appcheck.mjs +11 -0
- package/esm2020/lib/auth/appcheck/index.mjs +3 -0
- package/esm2020/lib/auth/auth.mjs +1 -1
- package/esm2020/lib/auth/error.mjs +1 -1
- package/esm2020/lib/auth/firebase.auth.module.mjs +1 -1
- package/esm2020/lib/auth/index.mjs +2 -1
- package/esm2020/lib/auth/login/firebase.login.module.mjs +49 -57
- package/esm2020/lib/auth/login/login.anonymous.component.mjs +3 -3
- package/esm2020/lib/auth/login/login.apple.component.mjs +3 -3
- package/esm2020/lib/auth/login/login.button.component.mjs +36 -38
- package/esm2020/lib/auth/login/login.component.mjs +3 -3
- package/esm2020/lib/auth/login/login.context.back.component.mjs +8 -8
- package/esm2020/lib/auth/login/login.context.directive.mjs +13 -9
- package/esm2020/lib/auth/login/login.context.mjs +2 -2
- package/esm2020/lib/auth/login/login.email.component.mjs +4 -4
- package/esm2020/lib/auth/login/login.email.content.component.mjs +9 -9
- package/esm2020/lib/auth/login/login.email.form.component.mjs +12 -8
- package/esm2020/lib/auth/login/login.email.recovery.form.component.mjs +10 -6
- package/esm2020/lib/auth/login/login.facebook.component.mjs +3 -3
- package/esm2020/lib/auth/login/login.github.component.mjs +3 -3
- package/esm2020/lib/auth/login/login.google.component.mjs +3 -3
- package/esm2020/lib/auth/login/login.list.component.mjs +11 -13
- package/esm2020/lib/auth/login/login.microsoft.component.mjs +3 -3
- package/esm2020/lib/auth/login/login.mjs +1 -1
- package/esm2020/lib/auth/login/login.password.mjs +1 -1
- package/esm2020/lib/auth/login/login.service.mjs +8 -8
- package/esm2020/lib/auth/login/login.terms.component.mjs +10 -6
- package/esm2020/lib/auth/login/login.terms.mjs +1 -1
- package/esm2020/lib/auth/login/login.terms.simple.component.mjs +12 -12
- package/esm2020/lib/auth/login/login.twitter.component.mjs +3 -3
- package/esm2020/lib/auth/login/register.component.mjs +8 -4
- package/esm2020/lib/auth/login/register.email.component.mjs +4 -4
- package/esm2020/lib/auth/service/firebase.auth.rxjs.mjs +3 -3
- package/esm2020/lib/auth/service/firebase.auth.service.mjs +12 -12
- package/esm2020/lib/firebase/appcheck.mjs +2 -0
- package/esm2020/lib/firebase/emulators.mjs +1 -1
- package/esm2020/lib/firebase/firebase.emulator.module.mjs +6 -4
- package/esm2020/lib/firebase/firebase.module.mjs +137 -32
- package/esm2020/lib/firebase/index.mjs +2 -1
- package/esm2020/lib/firebase/options.mjs +3 -2
- package/esm2020/lib/firestore/firebase.firestore.context.service.mjs +1 -1
- package/esm2020/lib/firestore/firebase.firestore.module.mjs +11 -8
- package/esm2020/lib/function/firebase.function.module.mjs +8 -6
- package/esm2020/lib/model/error.mjs +2 -2
- package/esm2020/lib/model/loader/collection.loader.instance.mjs +9 -10
- package/esm2020/lib/model/loader/collection.loader.mjs +1 -1
- package/esm2020/lib/model/model.module.mjs +4 -6
- package/esm2020/lib/model/store/model.store.module.mjs +10 -30
- package/esm2020/lib/model/store/store.collection.change.directive.mjs +6 -4
- package/esm2020/lib/model/store/store.collection.change.if.directive.mjs +1 -1
- package/esm2020/lib/model/store/store.collection.directive.mjs +5 -3
- package/esm2020/lib/model/store/store.collection.list.directive.mjs +2 -2
- package/esm2020/lib/model/store/store.collection.mjs +8 -8
- package/esm2020/lib/model/store/store.document.auth.directive.mjs +4 -4
- package/esm2020/lib/model/store/store.document.directive.mjs +5 -3
- package/esm2020/lib/model/store/store.document.mjs +13 -13
- package/esm2020/lib/model/store/store.document.router.directive.mjs +2 -4
- package/esm2020/lib/model/store/store.subcollection.document.mjs +3 -3
- package/esm2020/lib/model/store/store.subcollection.mjs +3 -3
- package/esm2020/lib/model/store/store.subcollection.rxjs.mjs +3 -3
- package/esm2020/lib/module.mjs +4 -6
- package/fesm2015/dereekb-dbx-firebase.mjs +460 -272
- package/fesm2015/dereekb-dbx-firebase.mjs.map +1 -1
- package/fesm2020/dereekb-dbx-firebase.mjs +455 -272
- package/fesm2020/dereekb-dbx-firebase.mjs.map +1 -1
- package/lib/auth/appcheck/appcheck.d.ts +8 -0
- package/lib/auth/appcheck/appcheck.interceptor.d.ts +19 -0
- package/lib/auth/appcheck/index.d.ts +2 -0
- package/lib/auth/auth.d.ts +2 -3
- package/lib/auth/error.d.ts +2 -2
- package/lib/auth/index.d.ts +1 -0
- package/lib/auth/login/_login.scss +5 -5
- package/lib/auth/login/firebase.login.module.d.ts +1 -1
- package/lib/auth/login/login.anonymous.component.d.ts +2 -2
- package/lib/auth/login/login.apple.component.d.ts +2 -2
- package/lib/auth/login/login.button.component.d.ts +11 -12
- package/lib/auth/login/login.context.back.component.d.ts +3 -3
- package/lib/auth/login/login.context.d.ts +1 -1
- package/lib/auth/login/login.context.directive.d.ts +2 -2
- package/lib/auth/login/login.email.component.d.ts +2 -2
- package/lib/auth/login/login.email.content.component.d.ts +5 -5
- package/lib/auth/login/login.email.form.component.d.ts +7 -8
- package/lib/auth/login/login.email.recovery.form.component.d.ts +2 -2
- package/lib/auth/login/login.facebook.component.d.ts +2 -2
- package/lib/auth/login/login.github.component.d.ts +2 -2
- package/lib/auth/login/login.google.component.d.ts +2 -2
- package/lib/auth/login/login.list.component.d.ts +2 -2
- package/lib/auth/login/login.microsoft.component.d.ts +2 -2
- package/lib/auth/login/login.password.d.ts +2 -3
- package/lib/auth/login/login.service.d.ts +10 -10
- package/lib/auth/login/login.terms.component.d.ts +1 -1
- package/lib/auth/login/login.twitter.component.d.ts +2 -2
- package/lib/auth/login/register.email.component.d.ts +2 -2
- package/lib/auth/service/firebase.auth.rxjs.d.ts +1 -1
- package/lib/auth/service/firebase.auth.service.d.ts +3 -3
- package/lib/firebase/appcheck.d.ts +21 -0
- package/lib/firebase/firebase.module.d.ts +20 -10
- package/lib/firebase/index.d.ts +1 -0
- package/lib/firebase/options.d.ts +14 -3
- package/lib/firestore/firebase.firestore.module.d.ts +3 -3
- package/lib/function/firebase.function.module.d.ts +7 -7
- package/lib/model/loader/collection.loader.d.ts +5 -5
- package/lib/model/loader/collection.loader.instance.d.ts +4 -4
- package/lib/model/store/store.collection.change.directive.d.ts +5 -4
- package/lib/model/store/store.collection.change.if.directive.d.ts +2 -2
- package/lib/model/store/store.collection.d.ts +3 -3
- package/lib/model/store/store.collection.directive.d.ts +3 -3
- package/lib/model/store/store.document.auth.directive.d.ts +4 -4
- package/lib/model/store/store.document.d.ts +4 -4
- package/lib/model/store/store.document.directive.d.ts +3 -3
- package/lib/model/store/store.document.router.directive.d.ts +8 -9
- package/lib/model/store/store.subcollection.rxjs.d.ts +7 -7
- package/lib/style/_config.scss +8 -6
- package/lib/style/_core.scss +1 -1
- package/lib/style/_mixin.scss +1 -1
- package/lib/style/_theming.scss +2 -12
- package/lib/style/_variables.scss +1 -1
- package/package.json +8 -7
|
@@ -1,34 +1,122 @@
|
|
|
1
|
+
import { urlWithoutParameters, addToSet, removeFromSet, filterMaybeValues, mapIterable, asArray, excludeValuesFromArray, containsStringAnyCase, forEachKeyValue, readableError, isMaybeSo } from '@dereekb/util';
|
|
2
|
+
import * as i0 from '@angular/core';
|
|
3
|
+
import { InjectionToken, Injectable, Inject, Optional, Component, Input, Directive, EventEmitter, Output, NgModule, Injector, forwardRef, Host } from '@angular/core';
|
|
4
|
+
import { getToken, initializeAppCheck, ReCaptchaV3Provider } from 'firebase/app-check';
|
|
5
|
+
import { switchMap, from, first, map, of, shareReplay, timeout, startWith, distinctUntilChanged, BehaviorSubject, combineLatest, tap, firstValueFrom, Subject, throttleTime, NEVER, filter, take, exhaustMap } from 'rxjs';
|
|
6
|
+
import * as i1 from '@angular/fire/app-check';
|
|
7
|
+
import { provideAppCheck } from '@angular/fire/app-check';
|
|
1
8
|
import * as i4 from '@angular/material/button';
|
|
2
9
|
import { MatButtonModule } from '@angular/material/button';
|
|
3
10
|
import * as i2 from '@angular/material/icon';
|
|
4
11
|
import { MatIconModule } from '@angular/material/icon';
|
|
5
12
|
import * as i6 from '@angular/common';
|
|
6
13
|
import { CommonModule } from '@angular/common';
|
|
7
|
-
import * as i0 from '@angular/core';
|
|
8
|
-
import { Injectable, Optional, Component, InjectionToken, Inject, Input, Directive, EventEmitter, Output, NgModule, Injector, forwardRef, Host } from '@angular/core';
|
|
9
|
-
import { of, switchMap, shareReplay, map, timeout, startWith, distinctUntilChanged, from, BehaviorSubject, combineLatest, tap, firstValueFrom, Subject, throttleTime, NEVER, filter, take, exhaustMap, first } from 'rxjs';
|
|
10
14
|
import { filterMaybe, isNot, SubscriptionObject, cleanupDestroyable, accumulatorFlattenPageListLoadingState, useFirst, successResult, beginLoading, loadingStateFromObs, errorResult, cleanup } from '@dereekb/rxjs';
|
|
11
15
|
import * as i3$1 from '@dereekb/dbx-core';
|
|
12
16
|
import { loggedInObsFromIsLoggedIn, loggedOutObsFromIsLoggedIn, authUserIdentifier, DbxInjectionContext, AbstractForwardDbxInjectionContextDirective, DBX_INJECTION_COMPONENT_DATA, DbxInjectionComponentModule, DbxAuthService, AbstractSubscriptionDirective, AbstractIfDirective, LockSetComponentStore } from '@dereekb/dbx-core';
|
|
13
|
-
import * as i1 from '@angular/fire/auth';
|
|
17
|
+
import * as i1$1 from '@angular/fire/auth';
|
|
14
18
|
import { authState, GoogleAuthProvider, FacebookAuthProvider, TwitterAuthProvider, GithubAuthProvider, signInWithPopup, createUserWithEmailAndPassword, signInWithEmailAndPassword, signInAnonymously, provideAuth, getAuth, connectAuthEmulator } from '@angular/fire/auth';
|
|
15
19
|
import { sendPasswordResetEmail } from 'firebase/auth';
|
|
16
|
-
import { addToSet, removeFromSet, filterMaybeValues, mapIterable, asArray, excludeValuesFromArray, containsStringAnyCase, forEachKeyValue, readableError, isMaybeSo } from '@dereekb/util';
|
|
17
20
|
import * as i3 from '@dereekb/dbx-web';
|
|
18
21
|
import { DbxRouterAnchorModule, DbxReadableErrorModule, DbxActionModule, DbxButtonModule } from '@dereekb/dbx-web';
|
|
19
|
-
import * as i1$
|
|
20
|
-
import { AbstractAsyncFormlyFormDirective, usernamePasswordLoginFields,
|
|
22
|
+
import * as i1$2 from '@dereekb/dbx-form';
|
|
23
|
+
import { AbstractAsyncFormlyFormDirective, usernamePasswordLoginFields, provideFormlyContext, AbstractSyncFormlyFormDirective, emailField, DbxFormIoModule, DbxFormModule, DbxFormlyModule, DbxFormActionModule, DbxFormFormlyTextFieldModule } from '@dereekb/dbx-form';
|
|
21
24
|
import { initializeApp } from 'firebase/app';
|
|
22
|
-
import * as
|
|
23
|
-
import { provideFirebaseApp } from '@angular/fire/app';
|
|
24
|
-
import * as
|
|
25
|
+
import * as i6$1 from '@angular/fire/app';
|
|
26
|
+
import { FirebaseApp, provideFirebaseApp } from '@angular/fire/app';
|
|
27
|
+
import * as i4$1 from '@angular/fire/storage';
|
|
25
28
|
import { provideStorage, getStorage, connectStorageEmulator } from '@angular/fire/storage';
|
|
26
|
-
import * as
|
|
29
|
+
import * as i5 from '@angular/fire/functions';
|
|
27
30
|
import { provideFunctions, getFunctions, connectFunctionsEmulator, Functions } from '@angular/fire/functions';
|
|
28
|
-
import * as i1$
|
|
31
|
+
import * as i1$3 from '@angular/fire/firestore';
|
|
29
32
|
import { provideFirestore, getFirestore, connectFirestoreEmulator, enableIndexedDbPersistence, Firestore } from '@angular/fire/firestore';
|
|
33
|
+
import { HTTP_INTERCEPTORS } from '@angular/common/http';
|
|
30
34
|
import { firebaseFirestoreContextFactory, iterationQueryDocChangeWatcher, firebaseQueryItemAccumulator, documentDataWithId } from '@dereekb/firebase';
|
|
31
|
-
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* Enables debug token generation for AppCheck by setting FIREBASE_APPCHECK_DEBUG_TOKEN in the browser's self/window.
|
|
38
|
+
*
|
|
39
|
+
* https://firebase.google.com/docs/app-check/web/debug-provider
|
|
40
|
+
*
|
|
41
|
+
* @param enable
|
|
42
|
+
*/
|
|
43
|
+
function enableAppCheckDebugTokenGeneration(enable = true) {
|
|
44
|
+
self.FIREBASE_APPCHECK_DEBUG_TOKEN = enable;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
const DBX_FIREBASE_OPTIONS_TOKEN = new InjectionToken('DbxFirebaseOptions');
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* HTTP Interceptor that sets the X-Firebase-AppCheck for any requests to the routes configured in DbxFirebaseOptions.
|
|
51
|
+
*/
|
|
52
|
+
class DbxFirebaseAppCheckHttpInterceptor {
|
|
53
|
+
constructor(dbxFirebaseOptions, appCheck) {
|
|
54
|
+
this.dbxFirebaseOptions = dbxFirebaseOptions;
|
|
55
|
+
this.appCheck = appCheck;
|
|
56
|
+
let routes = [];
|
|
57
|
+
if (appCheck != null) {
|
|
58
|
+
routes = (this.dbxFirebaseOptions.appCheck?.appCheckRoutes ?? ['/api/*']).map((route) => {
|
|
59
|
+
const wildcardIndex = route.indexOf('*');
|
|
60
|
+
const isWildcard = (wildcardIndex === route.length - 1);
|
|
61
|
+
const match = (isWildcard) ? route.substring(0, wildcardIndex) : route;
|
|
62
|
+
return {
|
|
63
|
+
isWildcard,
|
|
64
|
+
match
|
|
65
|
+
};
|
|
66
|
+
});
|
|
67
|
+
}
|
|
68
|
+
this._appCheckRoutes = routes;
|
|
69
|
+
this._isEnabled = routes.length > 0;
|
|
70
|
+
}
|
|
71
|
+
intercept(req, next) {
|
|
72
|
+
let obs;
|
|
73
|
+
if (this._isEnabled) {
|
|
74
|
+
obs = this.matchesAnyRoute(req.url).pipe(switchMap((isMatch) => {
|
|
75
|
+
let nextEvent;
|
|
76
|
+
if (isMatch) {
|
|
77
|
+
nextEvent = from(getToken(this.appCheck).then((appCheckTokenResponse) => {
|
|
78
|
+
const token = appCheckTokenResponse.token;
|
|
79
|
+
let nextRequest = req;
|
|
80
|
+
if (token) {
|
|
81
|
+
nextRequest = req.clone({
|
|
82
|
+
headers: req.headers.set('X-Firebase-AppCheck', token)
|
|
83
|
+
});
|
|
84
|
+
}
|
|
85
|
+
return nextRequest;
|
|
86
|
+
})).pipe(switchMap((nextRequest) => next.handle(nextRequest)));
|
|
87
|
+
}
|
|
88
|
+
else {
|
|
89
|
+
nextEvent = next.handle(req);
|
|
90
|
+
}
|
|
91
|
+
return nextEvent;
|
|
92
|
+
}));
|
|
93
|
+
}
|
|
94
|
+
else {
|
|
95
|
+
obs = next.handle(req);
|
|
96
|
+
}
|
|
97
|
+
return obs;
|
|
98
|
+
}
|
|
99
|
+
matchesAnyRoute(inputUrl) {
|
|
100
|
+
const url = urlWithoutParameters(inputUrl);
|
|
101
|
+
function isEnabledRouteMatch(enabledRoute) {
|
|
102
|
+
if (enabledRoute.isWildcard) {
|
|
103
|
+
return url.startsWith(enabledRoute.match);
|
|
104
|
+
}
|
|
105
|
+
else {
|
|
106
|
+
return url === enabledRoute.match;
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
return from(this._appCheckRoutes).pipe(first((route) => isEnabledRouteMatch(route), false), map(x => Boolean(x)));
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
DbxFirebaseAppCheckHttpInterceptor.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseAppCheckHttpInterceptor, deps: [{ token: DBX_FIREBASE_OPTIONS_TOKEN }, { token: i1.AppCheck }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
113
|
+
DbxFirebaseAppCheckHttpInterceptor.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseAppCheckHttpInterceptor });
|
|
114
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseAppCheckHttpInterceptor, decorators: [{
|
|
115
|
+
type: Injectable
|
|
116
|
+
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
117
|
+
type: Inject,
|
|
118
|
+
args: [DBX_FIREBASE_OPTIONS_TOKEN]
|
|
119
|
+
}] }, { type: i1.AppCheck }]; } });
|
|
32
120
|
|
|
33
121
|
/**
|
|
34
122
|
* Derives a user state from the input firebase auth service.
|
|
@@ -41,7 +129,7 @@ function authUserStateFromFirebaseAuthService(dbxFirebaseAuthService, stateForLo
|
|
|
41
129
|
return dbxFirebaseAuthService.hasAuthUser$.pipe(switchMap((hasUser) => {
|
|
42
130
|
let obs;
|
|
43
131
|
if (hasUser) {
|
|
44
|
-
obs = dbxFirebaseAuthService.isAnonymousUser$.pipe(switchMap((isAnon) => isAnon ? of('anon') : stateForLoggedInUser(dbxFirebaseAuthService)));
|
|
132
|
+
obs = dbxFirebaseAuthService.isAnonymousUser$.pipe(switchMap((isAnon) => (isAnon ? of('anon') : stateForLoggedInUser(dbxFirebaseAuthService))));
|
|
45
133
|
}
|
|
46
134
|
else {
|
|
47
135
|
obs = of('none');
|
|
@@ -60,7 +148,7 @@ function authUserStateFromFirebaseAuthService(dbxFirebaseAuthService, stateForLo
|
|
|
60
148
|
function readValueFromIdToken(dbxFirebaseAuthService, readBooleanFromIdToken, defaultValue) {
|
|
61
149
|
return dbxFirebaseAuthService.currentAuthUserInfo$.pipe(switchMap((x) => {
|
|
62
150
|
if (x) {
|
|
63
|
-
return dbxFirebaseAuthService.idTokenResult$.pipe(switchMap(x => readBooleanFromIdToken(x)));
|
|
151
|
+
return dbxFirebaseAuthService.idTokenResult$.pipe(switchMap((x) => readBooleanFromIdToken(x)));
|
|
64
152
|
}
|
|
65
153
|
else {
|
|
66
154
|
return of(defaultValue);
|
|
@@ -85,10 +173,10 @@ const DEFAULT_DBX_FIREBASE_AUTH_SERVICE_DELEGATE = {
|
|
|
85
173
|
return authUserStateFromFirebaseAuthService(dbxFirebaseAuthService);
|
|
86
174
|
},
|
|
87
175
|
authRolesObs(dbxFirebaseAuthService) {
|
|
88
|
-
return dbxFirebaseAuthService.authUserState$.pipe(map(x => x === 'user' ? new Set(['user']) : new Set()));
|
|
176
|
+
return dbxFirebaseAuthService.authUserState$.pipe(map((x) => (x === 'user' ? new Set(['user']) : new Set())));
|
|
89
177
|
},
|
|
90
178
|
isOnboarded(dbxFirebaseAuthService) {
|
|
91
|
-
return dbxFirebaseAuthService.authUserState$.pipe(map(x => x === 'user'));
|
|
179
|
+
return dbxFirebaseAuthService.authUserState$.pipe(map((x) => x === 'user'));
|
|
92
180
|
}
|
|
93
181
|
};
|
|
94
182
|
class DbxFirebaseAuthService {
|
|
@@ -99,19 +187,19 @@ class DbxFirebaseAuthService {
|
|
|
99
187
|
first: 1000,
|
|
100
188
|
with: () => this._authState$.pipe(startWith(null))
|
|
101
189
|
}), distinctUntilChanged(), shareReplay(1));
|
|
102
|
-
this.currentAuthUserInfo$ = this.currentAuthUser$.pipe(map((x) => (x
|
|
190
|
+
this.currentAuthUserInfo$ = this.currentAuthUser$.pipe(map((x) => (x ? authUserInfoFromAuthUser(x) : undefined)));
|
|
103
191
|
this.authUser$ = this.currentAuthUser$.pipe(filterMaybe());
|
|
104
192
|
this.authUserInfo$ = this.authUser$.pipe(map(authUserInfoFromAuthUser));
|
|
105
|
-
this.hasAuthUser$ = this.currentAuthUser$.pipe(map(x => Boolean(x)), distinctUntilChanged(), shareReplay(1));
|
|
106
|
-
this.isAnonymousUser$ = this.authUser$.pipe(map(x => x.isAnonymous), distinctUntilChanged(), shareReplay(1));
|
|
193
|
+
this.hasAuthUser$ = this.currentAuthUser$.pipe(map((x) => Boolean(x)), distinctUntilChanged(), shareReplay(1));
|
|
194
|
+
this.isAnonymousUser$ = this.authUser$.pipe(map((x) => x.isAnonymous), distinctUntilChanged(), shareReplay(1));
|
|
107
195
|
this.isNotAnonymousUser$ = this.isAnonymousUser$.pipe(isNot());
|
|
108
196
|
this.isLoggedIn$ = this.hasAuthUser$;
|
|
109
197
|
this.isNotLoggedIn$ = this.isLoggedIn$.pipe(isNot());
|
|
110
198
|
this.onLogIn$ = loggedInObsFromIsLoggedIn(this.isLoggedIn$);
|
|
111
199
|
this.onLogOut$ = loggedOutObsFromIsLoggedIn(this.isLoggedIn$);
|
|
112
|
-
this.userIdentifier$ = this.currentAuthUser$.pipe(map(x => authUserIdentifier(x?.uid)));
|
|
113
|
-
this.idTokenResult$ = this.authUser$.pipe(switchMap(x => x.getIdTokenResult()));
|
|
114
|
-
this.claims$ = this.idTokenResult$.pipe(map(x => x.claims));
|
|
200
|
+
this.userIdentifier$ = this.currentAuthUser$.pipe(map((x) => authUserIdentifier(x?.uid)));
|
|
201
|
+
this.idTokenResult$ = this.authUser$.pipe(switchMap((x) => x.getIdTokenResult()));
|
|
202
|
+
this.claims$ = this.idTokenResult$.pipe(map((x) => x.claims));
|
|
115
203
|
delegate = delegate ?? DEFAULT_DBX_FIREBASE_AUTH_SERVICE_DELEGATE;
|
|
116
204
|
this.authUserState$ = delegate.authUserStateObs(this).pipe(distinctUntilChanged(), shareReplay(1));
|
|
117
205
|
this.authRoles$ = delegate.authRolesObs(this);
|
|
@@ -159,11 +247,11 @@ class DbxFirebaseAuthService {
|
|
|
159
247
|
return this.firebaseAuth.signOut();
|
|
160
248
|
}
|
|
161
249
|
}
|
|
162
|
-
DbxFirebaseAuthService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseAuthService, deps: [{ token: i1.Auth }, { token: DbxFirebaseAuthServiceDelegate, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
250
|
+
DbxFirebaseAuthService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseAuthService, deps: [{ token: i1$1.Auth }, { token: DbxFirebaseAuthServiceDelegate, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
163
251
|
DbxFirebaseAuthService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseAuthService });
|
|
164
252
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseAuthService, decorators: [{
|
|
165
253
|
type: Injectable
|
|
166
|
-
}], ctorParameters: function () { return [{ type: i1.Auth }, { type: DbxFirebaseAuthServiceDelegate, decorators: [{
|
|
254
|
+
}], ctorParameters: function () { return [{ type: i1$1.Auth }, { type: DbxFirebaseAuthServiceDelegate, decorators: [{
|
|
167
255
|
type: Optional
|
|
168
256
|
}] }]; } });
|
|
169
257
|
|
|
@@ -185,21 +273,21 @@ class DbxFirebaseLoginTermsSimpleComponent {
|
|
|
185
273
|
}
|
|
186
274
|
DbxFirebaseLoginTermsSimpleComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginTermsSimpleComponent, deps: [{ token: DbxFirebaseLoginTermsConfig }], target: i0.ɵɵFactoryTarget.Component });
|
|
187
275
|
DbxFirebaseLoginTermsSimpleComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseLoginTermsSimpleComponent, selector: "ng-component", ngImport: i0, template: `
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
276
|
+
<div class="dbx-firebase-login-terms-view">
|
|
277
|
+
<dbx-link [anchor]="tosAnchor">Terms</dbx-link>
|
|
278
|
+
<span class="dbx-link-spacer"></span>
|
|
279
|
+
<dbx-link [anchor]="privacyAnchor">Privacy</dbx-link>
|
|
280
|
+
</div>
|
|
193
281
|
`, isInline: true, components: [{ type: i3.DbxAnchorLinkComponent, selector: "dbx-link", inputs: ["anchor", "ref", "href"] }] });
|
|
194
282
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginTermsSimpleComponent, decorators: [{
|
|
195
283
|
type: Component,
|
|
196
284
|
args: [{
|
|
197
285
|
template: `
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
286
|
+
<div class="dbx-firebase-login-terms-view">
|
|
287
|
+
<dbx-link [anchor]="tosAnchor">Terms</dbx-link>
|
|
288
|
+
<span class="dbx-link-spacer"></span>
|
|
289
|
+
<dbx-link [anchor]="privacyAnchor">Privacy</dbx-link>
|
|
290
|
+
</div>
|
|
203
291
|
`
|
|
204
292
|
}]
|
|
205
293
|
}], ctorParameters: function () { return [{ type: DbxFirebaseLoginTermsConfig }]; } });
|
|
@@ -289,7 +377,7 @@ class DbxFirebaseAuthLoginService {
|
|
|
289
377
|
return Array.from(this._providers.keys());
|
|
290
378
|
}
|
|
291
379
|
getEnabledTypes() {
|
|
292
|
-
return
|
|
380
|
+
return this._enableAll ? this.getRegisteredTypes() : Array.from(this._enabled);
|
|
293
381
|
}
|
|
294
382
|
getLoginProvider(type) {
|
|
295
383
|
return this._providers.get(type);
|
|
@@ -301,7 +389,7 @@ class DbxFirebaseAuthLoginService {
|
|
|
301
389
|
return this._providers.get(type);
|
|
302
390
|
}
|
|
303
391
|
getRegisterProviders(types) {
|
|
304
|
-
return filterMaybeValues(mapIterable(types ?? [], (x) => this._providers.get(x))).filter(x => x.registrationComponentClass !== false);
|
|
392
|
+
return filterMaybeValues(mapIterable(types ?? [], (x) => this._providers.get(x))).filter((x) => x.registrationComponentClass !== false);
|
|
305
393
|
}
|
|
306
394
|
getProviderAssets(type) {
|
|
307
395
|
return this._assets.get(type);
|
|
@@ -318,7 +406,7 @@ DbxFirebaseAuthLoginService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "1
|
|
|
318
406
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseAuthLoginService, decorators: [{
|
|
319
407
|
type: Injectable,
|
|
320
408
|
args: [{
|
|
321
|
-
providedIn: 'root'
|
|
409
|
+
providedIn: 'root'
|
|
322
410
|
}]
|
|
323
411
|
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
324
412
|
type: Optional
|
|
@@ -348,11 +436,11 @@ class DbxFirebaseLoginContext extends DbxInjectionContext {
|
|
|
348
436
|
*/
|
|
349
437
|
class DbxFirebaseLoginButtonComponent {
|
|
350
438
|
constructor() {
|
|
351
|
-
this.handleAction = (
|
|
439
|
+
this.handleAction = () => {
|
|
352
440
|
const loginPromise = this.config.handleLogin();
|
|
353
441
|
return from(loginPromise);
|
|
354
442
|
};
|
|
355
|
-
this.onActionSuccess = (
|
|
443
|
+
this.onActionSuccess = () => {
|
|
356
444
|
// todo: show checkmark on success?
|
|
357
445
|
};
|
|
358
446
|
}
|
|
@@ -374,39 +462,37 @@ class DbxFirebaseLoginButtonComponent {
|
|
|
374
462
|
}
|
|
375
463
|
DbxFirebaseLoginButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
376
464
|
DbxFirebaseLoginButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseLoginButtonComponent, selector: "dbx-firebase-login-button", inputs: { config: "config" }, host: { classAttribute: "dbx-firebase-login-button" }, ngImport: i0, template: `
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
</
|
|
387
|
-
</
|
|
388
|
-
</ng-container>
|
|
465
|
+
<ng-container dbxAction [dbxActionHandler]="handleAction" dbxActionValue [dbxActionSuccessHandler]="onActionSuccess">
|
|
466
|
+
<dbx-button dbxActionButton [customTextColor]="buttonTextColor" [customButtonColor]="buttonColor" [raised]="true">
|
|
467
|
+
<div class="dbx-firebase-login-button-content">
|
|
468
|
+
<span class="dbx-firebase-login-button-icon dbx-icon-spacer">
|
|
469
|
+
<img *ngIf="iconUrl" [src]="iconUrl" />
|
|
470
|
+
<mat-icon *ngIf="icon">{{ icon }}</mat-icon>
|
|
471
|
+
</span>
|
|
472
|
+
<span class="dbx-firebase-login-button-text">{{ text }}</span>
|
|
473
|
+
</div>
|
|
474
|
+
</dbx-button>
|
|
475
|
+
</ng-container>
|
|
389
476
|
`, isInline: true, components: [{ type: i3.DbxButtonComponent, selector: "dbx-button", inputs: ["type", "raised", "stroked", "flat", "color", "customButtonColor", "customTextColor", "customSpinnerColor"] }, { type: i2.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], directives: [{ type: i3$1.DbxActionDirective, selector: "dbx-action,[dbxAction],dbx-action-context,[dbxActionContext]", exportAs: ["action", "dbxAction"] }, { type: i3$1.DbxActionValueDirective, selector: "[dbxActionValue]", inputs: ["dbxActionValue"] }, { type: i3$1.DbxActionHandlerDirective, selector: "[dbxActionHandler]", inputs: ["dbxActionHandler"] }, { type: i3$1.DbxActionSuccessHandlerDirective, selector: "[dbxActionSuccessHandler]", inputs: ["dbxActionSuccessHandler"] }, { type: i3$1.DbxActionButtonDirective, selector: "[dbxActionButton]" }, { type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
390
477
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginButtonComponent, decorators: [{
|
|
391
478
|
type: Component,
|
|
392
479
|
args: [{
|
|
393
480
|
selector: 'dbx-firebase-login-button',
|
|
394
481
|
template: `
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
</
|
|
405
|
-
</
|
|
406
|
-
</ng-container>
|
|
482
|
+
<ng-container dbxAction [dbxActionHandler]="handleAction" dbxActionValue [dbxActionSuccessHandler]="onActionSuccess">
|
|
483
|
+
<dbx-button dbxActionButton [customTextColor]="buttonTextColor" [customButtonColor]="buttonColor" [raised]="true">
|
|
484
|
+
<div class="dbx-firebase-login-button-content">
|
|
485
|
+
<span class="dbx-firebase-login-button-icon dbx-icon-spacer">
|
|
486
|
+
<img *ngIf="iconUrl" [src]="iconUrl" />
|
|
487
|
+
<mat-icon *ngIf="icon">{{ icon }}</mat-icon>
|
|
488
|
+
</span>
|
|
489
|
+
<span class="dbx-firebase-login-button-text">{{ text }}</span>
|
|
490
|
+
</div>
|
|
491
|
+
</dbx-button>
|
|
492
|
+
</ng-container>
|
|
407
493
|
`,
|
|
408
494
|
host: {
|
|
409
|
-
|
|
495
|
+
class: 'dbx-firebase-login-button'
|
|
410
496
|
}
|
|
411
497
|
}]
|
|
412
498
|
}], propDecorators: { config: [{
|
|
@@ -416,18 +502,18 @@ class DbxFirebaseLoginButtonContainerComponent {
|
|
|
416
502
|
}
|
|
417
503
|
DbxFirebaseLoginButtonContainerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginButtonContainerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
418
504
|
DbxFirebaseLoginButtonContainerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseLoginButtonContainerComponent, selector: "dbx-firebase-login-button-container", ngImport: i0, template: `
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
505
|
+
<div class="dbx-firebase-login-button-container">
|
|
506
|
+
<ng-content></ng-content>
|
|
507
|
+
</div>
|
|
422
508
|
`, isInline: true });
|
|
423
509
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginButtonContainerComponent, decorators: [{
|
|
424
510
|
type: Component,
|
|
425
511
|
args: [{
|
|
426
512
|
selector: 'dbx-firebase-login-button-container',
|
|
427
513
|
template: `
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
514
|
+
<div class="dbx-firebase-login-button-container">
|
|
515
|
+
<ng-content></ng-content>
|
|
516
|
+
</div>
|
|
431
517
|
`
|
|
432
518
|
}]
|
|
433
519
|
}] });
|
|
@@ -519,8 +605,8 @@ class DbxFirebaseLoginListComponent {
|
|
|
519
605
|
this._omitProviderTypes = new BehaviorSubject(undefined);
|
|
520
606
|
this._inputProviderTypes = new BehaviorSubject(undefined);
|
|
521
607
|
this.providerTypes$ = combineLatest([this._inputProviderTypes, this._omitProviderTypes]).pipe(map(([providerTypes, omitProviderTypes]) => {
|
|
522
|
-
const baseTypes =
|
|
523
|
-
const types =
|
|
608
|
+
const baseTypes = providerTypes ? asArray(providerTypes) : this.dbxFirebaseAuthLoginService.getEnabledTypes();
|
|
609
|
+
const types = omitProviderTypes ? excludeValuesFromArray(baseTypes, asArray(omitProviderTypes)) : baseTypes;
|
|
524
610
|
return types;
|
|
525
611
|
}), shareReplay(1));
|
|
526
612
|
this.providers$ = combineLatest([this.providerTypes$, this._inputProviderCategories]).pipe(map(([x, inputProviderCategories]) => {
|
|
@@ -528,14 +614,12 @@ class DbxFirebaseLoginListComponent {
|
|
|
528
614
|
let providers = this.dbxFirebaseAuthLoginService.getLoginProviders(x);
|
|
529
615
|
if (providerCategories.length) {
|
|
530
616
|
const categories = new Set(providerCategories);
|
|
531
|
-
providers = providers.filter(x => containsStringAnyCase(categories, x.category ?? ''));
|
|
617
|
+
providers = providers.filter((x) => containsStringAnyCase(categories, x.category ?? ''));
|
|
532
618
|
}
|
|
533
619
|
return providers;
|
|
534
620
|
}));
|
|
535
621
|
this.providerInjectionConfigs$ = combineLatest([this._loginMode, this.providers$]).pipe(map(([mode, providers]) => {
|
|
536
|
-
const mapFn =
|
|
537
|
-
((x) => ({ componentClass: x.registrationComponentClass ?? x.componentClass })) :
|
|
538
|
-
((x) => ({ componentClass: x.componentClass }));
|
|
622
|
+
const mapFn = mode === 'register' ? (x) => ({ componentClass: x.registrationComponentClass ?? x.componentClass }) : (x) => ({ componentClass: x.componentClass });
|
|
539
623
|
return providers.map(mapFn);
|
|
540
624
|
}));
|
|
541
625
|
}
|
|
@@ -560,21 +644,21 @@ class DbxFirebaseLoginListComponent {
|
|
|
560
644
|
}
|
|
561
645
|
DbxFirebaseLoginListComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginListComponent, deps: [{ token: DbxFirebaseAuthLoginService }], target: i0.ɵɵFactoryTarget.Component });
|
|
562
646
|
DbxFirebaseLoginListComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseLoginListComponent, selector: "dbx-firebase-login-list", inputs: { loginMode: "loginMode", providerTypes: "providerTypes", omitProviderTypes: "omitProviderTypes", providerCategories: "providerCategories" }, host: { classAttribute: "dbx-firebase-login-list" }, ngImport: i0, template: `
|
|
563
|
-
<div class="dbx-firebase-login-item" *ngFor="let config of
|
|
647
|
+
<div class="dbx-firebase-login-item" *ngFor="let config of providerInjectionConfigs$ | async">
|
|
564
648
|
<dbx-injection [config]="config"></dbx-injection>
|
|
565
649
|
</div>
|
|
566
|
-
`, isInline: true, components: [{ type: i3$1.DbxInjectionComponent, selector: "dbx-injection, [dbxInjection], [dbx-injection]", inputs: ["config", "template"] }], directives: [{ type: i6.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], pipes: { "async": i6.AsyncPipe } });
|
|
650
|
+
`, isInline: true, components: [{ type: i3$1.DbxInjectionComponent, selector: "dbx-injection, [dbxInjection], [dbx-injection]", inputs: ["config", "template"] }], directives: [{ type: i6.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], pipes: { "async": i6.AsyncPipe } });
|
|
567
651
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginListComponent, decorators: [{
|
|
568
652
|
type: Component,
|
|
569
653
|
args: [{
|
|
570
654
|
selector: 'dbx-firebase-login-list',
|
|
571
655
|
template: `
|
|
572
|
-
<div class="dbx-firebase-login-item" *ngFor="let config of
|
|
656
|
+
<div class="dbx-firebase-login-item" *ngFor="let config of providerInjectionConfigs$ | async">
|
|
573
657
|
<dbx-injection [config]="config"></dbx-injection>
|
|
574
658
|
</div>
|
|
575
|
-
`,
|
|
659
|
+
`,
|
|
576
660
|
host: {
|
|
577
|
-
|
|
661
|
+
class: 'dbx-firebase-login-list'
|
|
578
662
|
}
|
|
579
663
|
}]
|
|
580
664
|
}], ctorParameters: function () { return [{ type: DbxFirebaseAuthLoginService }]; }, propDecorators: { loginMode: [{
|
|
@@ -593,18 +677,22 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
593
677
|
class DbxFirebaseLoginContextDirective extends AbstractForwardDbxInjectionContextDirective {
|
|
594
678
|
}
|
|
595
679
|
DbxFirebaseLoginContextDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginContextDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
596
|
-
DbxFirebaseLoginContextDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseLoginContextDirective, selector: "[dbxFirebaseLoginContext]", providers: [
|
|
680
|
+
DbxFirebaseLoginContextDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseLoginContextDirective, selector: "[dbxFirebaseLoginContext]", providers: [
|
|
681
|
+
{
|
|
597
682
|
provide: DbxFirebaseLoginContext,
|
|
598
683
|
useExisting: DbxFirebaseLoginContextDirective
|
|
599
|
-
}
|
|
684
|
+
}
|
|
685
|
+
], usesInheritance: true, ngImport: i0 });
|
|
600
686
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginContextDirective, decorators: [{
|
|
601
687
|
type: Directive,
|
|
602
688
|
args: [{
|
|
603
|
-
|
|
604
|
-
providers: [
|
|
689
|
+
selector: '[dbxFirebaseLoginContext]',
|
|
690
|
+
providers: [
|
|
691
|
+
{
|
|
605
692
|
provide: DbxFirebaseLoginContext,
|
|
606
693
|
useExisting: DbxFirebaseLoginContextDirective
|
|
607
|
-
}
|
|
694
|
+
}
|
|
695
|
+
]
|
|
608
696
|
}]
|
|
609
697
|
}] });
|
|
610
698
|
|
|
@@ -632,7 +720,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
632
720
|
</ng-container>
|
|
633
721
|
`,
|
|
634
722
|
host: {
|
|
635
|
-
|
|
723
|
+
class: 'd-block dbx-firebase-login',
|
|
636
724
|
'[class]': '{ "dbx-firebase-register": loginMode === "register" }'
|
|
637
725
|
}
|
|
638
726
|
}]
|
|
@@ -679,7 +767,7 @@ class DbxFirebaseEmailFormComponent extends AbstractAsyncFormlyFormDirective {
|
|
|
679
767
|
super(...arguments);
|
|
680
768
|
this._config = new BehaviorSubject({ loginMode: 'login' });
|
|
681
769
|
this.fields$ = this._config.pipe(map(({ loginMode = 'login', passwordConfig }) => {
|
|
682
|
-
const fields = usernamePasswordLoginFields({ username: 'email', password: passwordConfig, verifyPassword:
|
|
770
|
+
const fields = usernamePasswordLoginFields({ username: 'email', password: passwordConfig, verifyPassword: loginMode === 'register' });
|
|
683
771
|
return fields;
|
|
684
772
|
}));
|
|
685
773
|
}
|
|
@@ -692,13 +780,17 @@ class DbxFirebaseEmailFormComponent extends AbstractAsyncFormlyFormDirective {
|
|
|
692
780
|
}
|
|
693
781
|
}
|
|
694
782
|
DbxFirebaseEmailFormComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseEmailFormComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
695
|
-
DbxFirebaseEmailFormComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseEmailFormComponent, selector: "dbx-firebase-email-form", inputs: { config: "config" }, providers: [
|
|
783
|
+
DbxFirebaseEmailFormComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseEmailFormComponent, selector: "dbx-firebase-email-form", inputs: { config: "config" }, providers: [provideFormlyContext()], usesInheritance: true, ngImport: i0, template: `
|
|
784
|
+
<dbx-formly></dbx-formly>
|
|
785
|
+
`, isInline: true, components: [{ type: i1$2.DbxFormlyFormComponent, selector: "dbx-formly", exportAs: ["formly"] }] });
|
|
696
786
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseEmailFormComponent, decorators: [{
|
|
697
787
|
type: Component,
|
|
698
788
|
args: [{
|
|
699
|
-
template:
|
|
789
|
+
template: `
|
|
790
|
+
<dbx-formly></dbx-formly>
|
|
791
|
+
`,
|
|
700
792
|
selector: 'dbx-firebase-email-form',
|
|
701
|
-
providers: [
|
|
793
|
+
providers: [provideFormlyContext()]
|
|
702
794
|
}]
|
|
703
795
|
}], propDecorators: { config: [{
|
|
704
796
|
type: Input
|
|
@@ -711,13 +803,17 @@ class DbxFirebaseEmailRecoveryFormComponent extends AbstractSyncFormlyFormDirect
|
|
|
711
803
|
}
|
|
712
804
|
}
|
|
713
805
|
DbxFirebaseEmailRecoveryFormComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseEmailRecoveryFormComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
714
|
-
DbxFirebaseEmailRecoveryFormComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseEmailRecoveryFormComponent, selector: "dbx-firebase-email-recovery-form", providers: [
|
|
806
|
+
DbxFirebaseEmailRecoveryFormComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseEmailRecoveryFormComponent, selector: "dbx-firebase-email-recovery-form", providers: [provideFormlyContext()], usesInheritance: true, ngImport: i0, template: `
|
|
807
|
+
<dbx-formly></dbx-formly>
|
|
808
|
+
`, isInline: true, components: [{ type: i1$2.DbxFormlyFormComponent, selector: "dbx-formly", exportAs: ["formly"] }] });
|
|
715
809
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseEmailRecoveryFormComponent, decorators: [{
|
|
716
810
|
type: Component,
|
|
717
811
|
args: [{
|
|
718
|
-
template:
|
|
812
|
+
template: `
|
|
813
|
+
<dbx-formly></dbx-formly>
|
|
814
|
+
`,
|
|
719
815
|
selector: 'dbx-firebase-email-recovery-form',
|
|
720
|
-
providers: [
|
|
816
|
+
providers: [provideFormlyContext()]
|
|
721
817
|
}]
|
|
722
818
|
}] });
|
|
723
819
|
|
|
@@ -756,15 +852,12 @@ class DbxFirebaseLoginEmailContentComponent {
|
|
|
756
852
|
this.handleRecoveryAction = (value) => {
|
|
757
853
|
this.recoveryFormValue = value;
|
|
758
854
|
this.emailFormValue = { username: value.email, password: '' };
|
|
759
|
-
|
|
855
|
+
const result = this.dbxFirebaseAuthService.sendPasswordResetEmail(value.email);
|
|
760
856
|
return from(result).pipe(tap(() => {
|
|
761
857
|
this.onRecoveringSuccess();
|
|
762
858
|
}));
|
|
763
859
|
};
|
|
764
860
|
}
|
|
765
|
-
ngOnDestroy() {
|
|
766
|
-
this._emailMode.complete();
|
|
767
|
-
}
|
|
768
861
|
static openEmailLoginContext(dbxFirebaseLoginContext, config) {
|
|
769
862
|
return dbxFirebaseLoginContext.showContext({
|
|
770
863
|
config: {
|
|
@@ -774,6 +867,9 @@ class DbxFirebaseLoginEmailContentComponent {
|
|
|
774
867
|
use: (instance) => firstValueFrom(instance.doneOrCancelled)
|
|
775
868
|
});
|
|
776
869
|
}
|
|
870
|
+
ngOnDestroy() {
|
|
871
|
+
this._emailMode.complete();
|
|
872
|
+
}
|
|
777
873
|
get loginMode() {
|
|
778
874
|
return this.config.loginMode;
|
|
779
875
|
}
|
|
@@ -792,6 +888,7 @@ class DbxFirebaseLoginEmailContentComponent {
|
|
|
792
888
|
}
|
|
793
889
|
// MARK: Recovering
|
|
794
890
|
onRecoveringSuccess() {
|
|
891
|
+
// optionally override in parent
|
|
795
892
|
}
|
|
796
893
|
// MARK: Cancel
|
|
797
894
|
onCancel() {
|
|
@@ -802,10 +899,10 @@ class DbxFirebaseLoginEmailContentComponent {
|
|
|
802
899
|
}
|
|
803
900
|
}
|
|
804
901
|
DbxFirebaseLoginEmailContentComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginEmailContentComponent, deps: [{ token: DbxFirebaseAuthService }, { token: DBX_INJECTION_COMPONENT_DATA }], target: i0.ɵɵFactoryTarget.Component });
|
|
805
|
-
DbxFirebaseLoginEmailContentComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseLoginEmailContentComponent, selector: "ng-component", ngImport: i0, template: "<div class=\"dbx-firebase-login-email-content\">\n <ng-container [ngSwitch]=\"emailMode$ | async\">\n <ng-container *ngSwitchCase=\"'login'\">\n <ng-container *ngTemplateOutlet=\"loginView\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"'recover'\">\n <ng-container *ngTemplateOutlet=\"resetPassword\"></ng-container>\n </ng-container>\n </ng-container>\n</div>\n\n<!-- Login View -->\n<ng-template #loginView>\n <ng-container dbxAction [dbxActionHandler]=\"handleLoginAction\">\n <dbx-firebase-email-form [config]=\"formConfig\" dbxActionForm [dbxFormSource]=\"emailFormValue\"
|
|
902
|
+
DbxFirebaseLoginEmailContentComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseLoginEmailContentComponent, selector: "ng-component", ngImport: i0, template: "<div class=\"dbx-firebase-login-email-content\">\n <ng-container [ngSwitch]=\"emailMode$ | async\">\n <ng-container *ngSwitchCase=\"'login'\">\n <ng-container *ngTemplateOutlet=\"loginView\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"'recover'\">\n <ng-container *ngTemplateOutlet=\"resetPassword\"></ng-container>\n </ng-container>\n </ng-container>\n</div>\n\n<!-- Login View -->\n<ng-template #loginView>\n <ng-container dbxAction [dbxActionHandler]=\"handleLoginAction\">\n <dbx-firebase-email-form [config]=\"formConfig\" dbxActionForm [dbxFormSource]=\"emailFormValue\"></dbx-firebase-email-form>\n <div class=\"dbx-firebase-login-email-forgot-prompt\" *ngIf=\"isLoginMode\">\n <dbx-link [anchor]=\"forgotAnchor\">Forgot Password?</dbx-link>\n </div>\n <div class=\"dbx-flex\">\n <dbx-button class=\"dbx-wide-button\" [text]=\"buttonText\" [raised]=\"true\" color=\"primary\" dbxActionButton></dbx-button>\n <dbx-button-spacer></dbx-button-spacer>\n <span class=\"dbx-spacer\"></span>\n <button mat-flat-button (click)=\"onCancel()\">Cancel</button>\n </div>\n <dbx-error dbxActionError></dbx-error>\n </ng-container>\n</ng-template>\n\n<!-- Reset Password View -->\n<ng-template #resetPassword>\n <ng-container dbxAction [dbxActionHandler]=\"handleRecoveryAction\">\n <dbx-firebase-email-recovery-form dbxActionForm [dbxFormSource]=\"recoveryFormValue\"></dbx-firebase-email-recovery-form>\n <p class=\"dbx-hint\">An email will be sent to the above address to help you reset your password.</p>\n <div class=\"dbx-flex\">\n <dbx-button class=\"dbx-wide-button\" text=\"Send Recovery Email\" [raised]=\"true\" color=\"primary\" dbxActionButton></dbx-button>\n <span class=\"dbx-spacer\"></span>\n <button mat-flat-button (click)=\"onCancelReset()\">Cancel Recovery</button>\n </div>\n <dbx-error dbxActionError></dbx-error>\n </ng-container>\n</ng-template>\n", components: [{ type: DbxFirebaseEmailFormComponent, selector: "dbx-firebase-email-form", inputs: ["config"] }, { type: i3.DbxAnchorLinkComponent, selector: "dbx-link", inputs: ["anchor", "ref", "href"] }, { type: i3.DbxButtonComponent, selector: "dbx-button", inputs: ["type", "raised", "stroked", "flat", "color", "customButtonColor", "customTextColor", "customSpinnerColor"] }, { type: i4.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i3.DbxReadableErrorComponent, selector: "dbx-error", inputs: ["error"] }, { type: DbxFirebaseEmailRecoveryFormComponent, selector: "dbx-firebase-email-recovery-form" }], directives: [{ type: i6.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i6.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i6.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i3$1.DbxActionDirective, selector: "dbx-action,[dbxAction],dbx-action-context,[dbxActionContext]", exportAs: ["action", "dbxAction"] }, { type: i3$1.DbxActionHandlerDirective, selector: "[dbxActionHandler]", inputs: ["dbxActionHandler"] }, { type: i1$2.DbxActionFormDirective, selector: "[dbxActionForm]", inputs: ["dbxActionFormValidator", "dbxActionFormModified", "formDisabledOnWorking"] }, { type: i1$2.DbxFormSourceDirective, selector: "[dbxFormSource]", inputs: ["dbxFormSourceMode", "dbxFormSource"] }, { type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$1.DbxActionButtonDirective, selector: "[dbxActionButton]" }, { type: i3.DbxButtonSpacerDirective, selector: "dbx-button-spacer,[dbxButtonSpacer]" }, { type: i3.DbxActionErrorDirective, selector: "[dbxActionError]" }], pipes: { "async": i6.AsyncPipe } });
|
|
806
903
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginEmailContentComponent, decorators: [{
|
|
807
904
|
type: Component,
|
|
808
|
-
args: [{ template: "<div class=\"dbx-firebase-login-email-content\">\n <ng-container [ngSwitch]=\"emailMode$ | async\">\n <ng-container *ngSwitchCase=\"'login'\">\n <ng-container *ngTemplateOutlet=\"loginView\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"'recover'\">\n <ng-container *ngTemplateOutlet=\"resetPassword\"></ng-container>\n </ng-container>\n </ng-container>\n</div>\n\n<!-- Login View -->\n<ng-template #loginView>\n <ng-container dbxAction [dbxActionHandler]=\"handleLoginAction\">\n <dbx-firebase-email-form [config]=\"formConfig\" dbxActionForm [dbxFormSource]=\"emailFormValue\"
|
|
905
|
+
args: [{ template: "<div class=\"dbx-firebase-login-email-content\">\n <ng-container [ngSwitch]=\"emailMode$ | async\">\n <ng-container *ngSwitchCase=\"'login'\">\n <ng-container *ngTemplateOutlet=\"loginView\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"'recover'\">\n <ng-container *ngTemplateOutlet=\"resetPassword\"></ng-container>\n </ng-container>\n </ng-container>\n</div>\n\n<!-- Login View -->\n<ng-template #loginView>\n <ng-container dbxAction [dbxActionHandler]=\"handleLoginAction\">\n <dbx-firebase-email-form [config]=\"formConfig\" dbxActionForm [dbxFormSource]=\"emailFormValue\"></dbx-firebase-email-form>\n <div class=\"dbx-firebase-login-email-forgot-prompt\" *ngIf=\"isLoginMode\">\n <dbx-link [anchor]=\"forgotAnchor\">Forgot Password?</dbx-link>\n </div>\n <div class=\"dbx-flex\">\n <dbx-button class=\"dbx-wide-button\" [text]=\"buttonText\" [raised]=\"true\" color=\"primary\" dbxActionButton></dbx-button>\n <dbx-button-spacer></dbx-button-spacer>\n <span class=\"dbx-spacer\"></span>\n <button mat-flat-button (click)=\"onCancel()\">Cancel</button>\n </div>\n <dbx-error dbxActionError></dbx-error>\n </ng-container>\n</ng-template>\n\n<!-- Reset Password View -->\n<ng-template #resetPassword>\n <ng-container dbxAction [dbxActionHandler]=\"handleRecoveryAction\">\n <dbx-firebase-email-recovery-form dbxActionForm [dbxFormSource]=\"recoveryFormValue\"></dbx-firebase-email-recovery-form>\n <p class=\"dbx-hint\">An email will be sent to the above address to help you reset your password.</p>\n <div class=\"dbx-flex\">\n <dbx-button class=\"dbx-wide-button\" text=\"Send Recovery Email\" [raised]=\"true\" color=\"primary\" dbxActionButton></dbx-button>\n <span class=\"dbx-spacer\"></span>\n <button mat-flat-button (click)=\"onCancelReset()\">Cancel Recovery</button>\n </div>\n <dbx-error dbxActionError></dbx-error>\n </ng-container>\n</ng-template>\n" }]
|
|
809
906
|
}], ctorParameters: function () { return [{ type: DbxFirebaseAuthService }, { type: undefined, decorators: [{
|
|
810
907
|
type: Inject,
|
|
811
908
|
args: [DBX_INJECTION_COMPONENT_DATA]
|
|
@@ -871,12 +968,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
871
968
|
class DbxFirebaseRegisterComponent {
|
|
872
969
|
}
|
|
873
970
|
DbxFirebaseRegisterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseRegisterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
874
|
-
DbxFirebaseRegisterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseRegisterComponent, selector: "dbx-firebase-register", inputs: { providerTypes: "providerTypes", omitProviderTypes: "omitProviderTypes", providerCategories: "providerCategories" }, ngImport: i0, template:
|
|
971
|
+
DbxFirebaseRegisterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseRegisterComponent, selector: "dbx-firebase-register", inputs: { providerTypes: "providerTypes", omitProviderTypes: "omitProviderTypes", providerCategories: "providerCategories" }, ngImport: i0, template: `
|
|
972
|
+
<dbx-firebase-login loginMode="register" [providerTypes]="providerTypes" [omitProviderTypes]="omitProviderTypes" [providerCategories]="providerCategories"></dbx-firebase-login>
|
|
973
|
+
`, isInline: true, components: [{ type: DbxFirebaseLoginComponent, selector: "dbx-firebase-login", inputs: ["loginMode", "providerTypes", "omitProviderTypes", "providerCategories"] }] });
|
|
875
974
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseRegisterComponent, decorators: [{
|
|
876
975
|
type: Component,
|
|
877
976
|
args: [{
|
|
878
977
|
selector: 'dbx-firebase-register',
|
|
879
|
-
template:
|
|
978
|
+
template: `
|
|
979
|
+
<dbx-firebase-login loginMode="register" [providerTypes]="providerTypes" [omitProviderTypes]="omitProviderTypes" [providerCategories]="providerCategories"></dbx-firebase-login>
|
|
980
|
+
`
|
|
880
981
|
}]
|
|
881
982
|
}], propDecorators: { providerTypes: [{
|
|
882
983
|
type: Input
|
|
@@ -965,39 +1066,43 @@ class DbxFirebaseLoginTermsComponent {
|
|
|
965
1066
|
}
|
|
966
1067
|
}
|
|
967
1068
|
DbxFirebaseLoginTermsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginTermsComponent, deps: [{ token: DbxFirebaseAuthLoginService }], target: i0.ɵɵFactoryTarget.Component });
|
|
968
|
-
DbxFirebaseLoginTermsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseLoginTermsComponent, selector: "dbx-firebase-login-terms", host: { classAttribute: "dbx-firebase-login-terms d-block" }, ngImport: i0, template:
|
|
1069
|
+
DbxFirebaseLoginTermsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseLoginTermsComponent, selector: "dbx-firebase-login-terms", host: { classAttribute: "dbx-firebase-login-terms d-block" }, ngImport: i0, template: `
|
|
1070
|
+
<dbx-injection [config]="config"></dbx-injection>
|
|
1071
|
+
`, isInline: true, components: [{ type: i3$1.DbxInjectionComponent, selector: "dbx-injection, [dbxInjection], [dbx-injection]", inputs: ["config", "template"] }] });
|
|
969
1072
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginTermsComponent, decorators: [{
|
|
970
1073
|
type: Component,
|
|
971
1074
|
args: [{
|
|
972
1075
|
selector: 'dbx-firebase-login-terms',
|
|
973
|
-
template:
|
|
1076
|
+
template: `
|
|
1077
|
+
<dbx-injection [config]="config"></dbx-injection>
|
|
1078
|
+
`,
|
|
974
1079
|
host: {
|
|
975
|
-
|
|
1080
|
+
class: 'dbx-firebase-login-terms d-block'
|
|
976
1081
|
}
|
|
977
1082
|
}]
|
|
978
1083
|
}], ctorParameters: function () { return [{ type: DbxFirebaseAuthLoginService }]; } });
|
|
979
1084
|
|
|
980
1085
|
class DbxFirebaseLoginContextBackButtonComponent {
|
|
981
1086
|
constructor() {
|
|
982
|
-
this.
|
|
1087
|
+
this.cancelLogin = new EventEmitter();
|
|
983
1088
|
this.anchor = {
|
|
984
|
-
onClick: () => this.
|
|
1089
|
+
onClick: () => this.cancelLogin.emit()
|
|
985
1090
|
};
|
|
986
1091
|
}
|
|
987
1092
|
}
|
|
988
1093
|
DbxFirebaseLoginContextBackButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginContextBackButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
989
|
-
DbxFirebaseLoginContextBackButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseLoginContextBackButtonComponent, selector: "dbx-firebase-login-context-back-button", outputs: {
|
|
1094
|
+
DbxFirebaseLoginContextBackButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.2", type: DbxFirebaseLoginContextBackButtonComponent, selector: "dbx-firebase-login-context-back-button", outputs: { cancelLogin: "cancelLogin" }, ngImport: i0, template: `
|
|
990
1095
|
<dbx-link [anchor]="anchor">Choose other login method.</dbx-link>
|
|
991
1096
|
`, isInline: true, components: [{ type: i3.DbxAnchorLinkComponent, selector: "dbx-link", inputs: ["anchor", "ref", "href"] }] });
|
|
992
1097
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginContextBackButtonComponent, decorators: [{
|
|
993
1098
|
type: Component,
|
|
994
1099
|
args: [{
|
|
995
|
-
|
|
996
|
-
|
|
1100
|
+
selector: 'dbx-firebase-login-context-back-button',
|
|
1101
|
+
template: `
|
|
997
1102
|
<dbx-link [anchor]="anchor">Choose other login method.</dbx-link>
|
|
998
1103
|
`
|
|
999
1104
|
}]
|
|
1000
|
-
}], propDecorators: {
|
|
1105
|
+
}], propDecorators: { cancelLogin: [{
|
|
1001
1106
|
type: Output
|
|
1002
1107
|
}] } });
|
|
1003
1108
|
|
|
@@ -1008,7 +1113,8 @@ function defaultFirebaseAuthLoginProvidersFactory() {
|
|
|
1008
1113
|
// https://firebase.google.com/docs/auth/web/firebaseui
|
|
1009
1114
|
const baseFirebaseJSUrl = `https://www.gstatic.com/firebasejs/ui/2.0.0/images/auth`;
|
|
1010
1115
|
// NOTE: Colors are from https://brandcolors.net/
|
|
1011
|
-
return [
|
|
1116
|
+
return [
|
|
1117
|
+
{
|
|
1012
1118
|
category: DEFAULT_FIREBASE_LOGIN_METHOD_CATEGORY,
|
|
1013
1119
|
loginMethodType: 'email',
|
|
1014
1120
|
componentClass: DbxFirebaseLoginEmailComponent,
|
|
@@ -1019,7 +1125,8 @@ function defaultFirebaseAuthLoginProvidersFactory() {
|
|
|
1019
1125
|
backgroundColor: '#ea4335',
|
|
1020
1126
|
textColor: '#FFF'
|
|
1021
1127
|
}
|
|
1022
|
-
},
|
|
1128
|
+
},
|
|
1129
|
+
{
|
|
1023
1130
|
category: OAUTH_FIREBASE_LOGIN_METHOD_CATEGORY,
|
|
1024
1131
|
loginMethodType: 'google',
|
|
1025
1132
|
componentClass: DbxFirebaseLoginGoogleComponent,
|
|
@@ -1029,7 +1136,8 @@ function defaultFirebaseAuthLoginProvidersFactory() {
|
|
|
1029
1136
|
backgroundColor: '#FFF',
|
|
1030
1137
|
textColor: '#757575'
|
|
1031
1138
|
}
|
|
1032
|
-
},
|
|
1139
|
+
},
|
|
1140
|
+
{
|
|
1033
1141
|
category: OAUTH_FIREBASE_LOGIN_METHOD_CATEGORY,
|
|
1034
1142
|
loginMethodType: 'facebook',
|
|
1035
1143
|
componentClass: DbxFirebaseLoginFacebookComponent,
|
|
@@ -1039,7 +1147,8 @@ function defaultFirebaseAuthLoginProvidersFactory() {
|
|
|
1039
1147
|
backgroundColor: '#4267B2',
|
|
1040
1148
|
textColor: '#FFF'
|
|
1041
1149
|
}
|
|
1042
|
-
},
|
|
1150
|
+
},
|
|
1151
|
+
{
|
|
1043
1152
|
category: OAUTH_FIREBASE_LOGIN_METHOD_CATEGORY,
|
|
1044
1153
|
loginMethodType: 'twitter',
|
|
1045
1154
|
componentClass: DbxFirebaseLoginTwitterComponent,
|
|
@@ -1049,7 +1158,8 @@ function defaultFirebaseAuthLoginProvidersFactory() {
|
|
|
1049
1158
|
backgroundColor: '#1da1f2',
|
|
1050
1159
|
textColor: '#FFF'
|
|
1051
1160
|
}
|
|
1052
|
-
},
|
|
1161
|
+
},
|
|
1162
|
+
{
|
|
1053
1163
|
category: OAUTH_FIREBASE_LOGIN_METHOD_CATEGORY,
|
|
1054
1164
|
loginMethodType: 'github',
|
|
1055
1165
|
componentClass: DbxFirebaseLoginGitHubComponent,
|
|
@@ -1060,7 +1170,27 @@ function defaultFirebaseAuthLoginProvidersFactory() {
|
|
|
1060
1170
|
textColor: '#FFF'
|
|
1061
1171
|
}
|
|
1062
1172
|
},
|
|
1063
|
-
{
|
|
1173
|
+
/*{
|
|
1174
|
+
category: OAUTH_FIREBASE_LOGIN_METHOD_CATEGORY,
|
|
1175
|
+
loginMethodType: 'apple' as KnownFirebaseLoginMethodType,
|
|
1176
|
+
componentClass: DbxFirebaseLoginGitHubComponent,
|
|
1177
|
+
assets: {
|
|
1178
|
+
logoUrl: `${baseFirebaseJSUrl}/apple.svg`,
|
|
1179
|
+
loginText: 'Continue with Apple',
|
|
1180
|
+
backgroundColor: '#333',
|
|
1181
|
+
textColor: '#FFF'
|
|
1182
|
+
}
|
|
1183
|
+
}, {
|
|
1184
|
+
category: OAUTH_FIREBASE_LOGIN_METHOD_CATEGORY,
|
|
1185
|
+
loginMethodType: 'microsoft' as KnownFirebaseLoginMethodType,
|
|
1186
|
+
componentClass: DbxFirebaseLoginGitHubComponent,
|
|
1187
|
+
assets: {
|
|
1188
|
+
logoUrl: `${baseFirebaseJSUrl}/microsoft.svg`,
|
|
1189
|
+
loginText: 'Continue with Microsoft',
|
|
1190
|
+
backgroundColor: '#ea3e23',
|
|
1191
|
+
textColor: '#FFF'
|
|
1192
|
+
}
|
|
1193
|
+
},*/ {
|
|
1064
1194
|
category: DEFAULT_FIREBASE_LOGIN_METHOD_CATEGORY,
|
|
1065
1195
|
loginMethodType: 'anonymous',
|
|
1066
1196
|
componentClass: DbxFirebaseLoginAnonymousComponent,
|
|
@@ -1070,7 +1200,8 @@ function defaultFirebaseAuthLoginProvidersFactory() {
|
|
|
1070
1200
|
backgroundColor: '#000',
|
|
1071
1201
|
textColor: '#FFF'
|
|
1072
1202
|
}
|
|
1073
|
-
}
|
|
1203
|
+
}
|
|
1204
|
+
];
|
|
1074
1205
|
}
|
|
1075
1206
|
/**
|
|
1076
1207
|
* Contains components related to logging in.
|
|
@@ -1087,22 +1218,28 @@ class DbxFirebaseLoginModule {
|
|
|
1087
1218
|
static forRoot(config) {
|
|
1088
1219
|
return {
|
|
1089
1220
|
ngModule: DbxFirebaseLoginModule,
|
|
1090
|
-
providers: [
|
|
1221
|
+
providers: [
|
|
1222
|
+
{
|
|
1091
1223
|
provide: DEFAULT_FIREBASE_AUTH_LOGIN_PROVIDERS_TOKEN,
|
|
1092
1224
|
useFactory: defaultFirebaseAuthLoginProvidersFactory
|
|
1093
|
-
},
|
|
1225
|
+
},
|
|
1226
|
+
{
|
|
1094
1227
|
provide: DEFAULT_FIREBASE_AUTH_LOGIN_TERMS_COMPONENT_CLASS_TOKEN,
|
|
1095
1228
|
useValue: config.termsComponentClass
|
|
1096
|
-
},
|
|
1229
|
+
},
|
|
1230
|
+
{
|
|
1097
1231
|
provide: DEFAULT_FIREBASE_AUTH_LOGIN_PASSWORD_CONFIG_TOKEN,
|
|
1098
1232
|
useValue: config.passwordConfig
|
|
1099
|
-
},
|
|
1233
|
+
},
|
|
1234
|
+
{
|
|
1100
1235
|
provide: DbxFirebaseLoginModuleRootConfig,
|
|
1101
1236
|
useValue: config
|
|
1102
|
-
},
|
|
1237
|
+
},
|
|
1238
|
+
{
|
|
1103
1239
|
provide: DbxFirebaseLoginTermsConfig,
|
|
1104
1240
|
useValue: config
|
|
1105
|
-
}
|
|
1241
|
+
}
|
|
1242
|
+
]
|
|
1106
1243
|
};
|
|
1107
1244
|
}
|
|
1108
1245
|
}
|
|
@@ -1127,19 +1264,7 @@ DbxFirebaseLoginModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0",
|
|
|
1127
1264
|
DbxFirebaseLoginFacebookComponent,
|
|
1128
1265
|
DbxFirebaseLoginAnonymousComponent,
|
|
1129
1266
|
DbxFirebaseLoginTermsComponent,
|
|
1130
|
-
DbxFirebaseLoginTermsSimpleComponent], imports: [CommonModule,
|
|
1131
|
-
MatIconModule,
|
|
1132
|
-
MatButtonModule,
|
|
1133
|
-
DbxRouterAnchorModule,
|
|
1134
|
-
DbxFormIoModule,
|
|
1135
|
-
DbxFormModule,
|
|
1136
|
-
DbxFormlyModule,
|
|
1137
|
-
DbxFormActionModule,
|
|
1138
|
-
DbxFormFormlyTextFieldModule,
|
|
1139
|
-
DbxReadableErrorModule,
|
|
1140
|
-
DbxActionModule,
|
|
1141
|
-
DbxButtonModule,
|
|
1142
|
-
DbxInjectionComponentModule], exports: [DbxFirebaseLoginComponent,
|
|
1267
|
+
DbxFirebaseLoginTermsSimpleComponent], imports: [CommonModule, MatIconModule, MatButtonModule, DbxRouterAnchorModule, DbxFormIoModule, DbxFormModule, DbxFormlyModule, DbxFormActionModule, DbxFormFormlyTextFieldModule, DbxReadableErrorModule, DbxActionModule, DbxButtonModule, DbxInjectionComponentModule], exports: [DbxFirebaseLoginComponent,
|
|
1143
1268
|
DbxFirebaseLoginContextDirective,
|
|
1144
1269
|
DbxFirebaseLoginContextBackButtonComponent,
|
|
1145
1270
|
DbxFirebaseRegisterComponent,
|
|
@@ -1160,39 +1285,11 @@ DbxFirebaseLoginModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0",
|
|
|
1160
1285
|
DbxFirebaseLoginAnonymousComponent,
|
|
1161
1286
|
DbxFirebaseLoginTermsComponent,
|
|
1162
1287
|
DbxFirebaseLoginTermsSimpleComponent] });
|
|
1163
|
-
DbxFirebaseLoginModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginModule, providers: [], imports: [[
|
|
1164
|
-
CommonModule,
|
|
1165
|
-
MatIconModule,
|
|
1166
|
-
MatButtonModule,
|
|
1167
|
-
DbxRouterAnchorModule,
|
|
1168
|
-
DbxFormIoModule,
|
|
1169
|
-
DbxFormModule,
|
|
1170
|
-
DbxFormlyModule,
|
|
1171
|
-
DbxFormActionModule,
|
|
1172
|
-
DbxFormFormlyTextFieldModule,
|
|
1173
|
-
DbxReadableErrorModule,
|
|
1174
|
-
DbxActionModule,
|
|
1175
|
-
DbxButtonModule,
|
|
1176
|
-
DbxInjectionComponentModule
|
|
1177
|
-
]] });
|
|
1288
|
+
DbxFirebaseLoginModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginModule, providers: [], imports: [[CommonModule, MatIconModule, MatButtonModule, DbxRouterAnchorModule, DbxFormIoModule, DbxFormModule, DbxFormlyModule, DbxFormActionModule, DbxFormFormlyTextFieldModule, DbxReadableErrorModule, DbxActionModule, DbxButtonModule, DbxInjectionComponentModule]] });
|
|
1178
1289
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseLoginModule, decorators: [{
|
|
1179
1290
|
type: NgModule,
|
|
1180
1291
|
args: [{
|
|
1181
|
-
imports: [
|
|
1182
|
-
CommonModule,
|
|
1183
|
-
MatIconModule,
|
|
1184
|
-
MatButtonModule,
|
|
1185
|
-
DbxRouterAnchorModule,
|
|
1186
|
-
DbxFormIoModule,
|
|
1187
|
-
DbxFormModule,
|
|
1188
|
-
DbxFormlyModule,
|
|
1189
|
-
DbxFormActionModule,
|
|
1190
|
-
DbxFormFormlyTextFieldModule,
|
|
1191
|
-
DbxReadableErrorModule,
|
|
1192
|
-
DbxActionModule,
|
|
1193
|
-
DbxButtonModule,
|
|
1194
|
-
DbxInjectionComponentModule
|
|
1195
|
-
],
|
|
1292
|
+
imports: [CommonModule, MatIconModule, MatButtonModule, DbxRouterAnchorModule, DbxFormIoModule, DbxFormModule, DbxFormlyModule, DbxFormActionModule, DbxFormFormlyTextFieldModule, DbxReadableErrorModule, DbxActionModule, DbxButtonModule, DbxInjectionComponentModule],
|
|
1196
1293
|
declarations: [
|
|
1197
1294
|
DbxFirebaseLoginComponent,
|
|
1198
1295
|
DbxFirebaseLoginContextDirective,
|
|
@@ -1283,10 +1380,11 @@ class DbxFirebaseParsedEmulatorsConfig {
|
|
|
1283
1380
|
class DbxFirebaseDefaultFirestoreProviderModule {
|
|
1284
1381
|
}
|
|
1285
1382
|
DbxFirebaseDefaultFirestoreProviderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultFirestoreProviderModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1286
|
-
DbxFirebaseDefaultFirestoreProviderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultFirestoreProviderModule, imports: [i1$
|
|
1383
|
+
DbxFirebaseDefaultFirestoreProviderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultFirestoreProviderModule, imports: [i1$3.FirestoreModule] });
|
|
1287
1384
|
DbxFirebaseDefaultFirestoreProviderModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultFirestoreProviderModule, imports: [[
|
|
1288
1385
|
provideFirestore(((injector) => {
|
|
1289
|
-
const
|
|
1386
|
+
const firebaseApp = injector.get(FirebaseApp);
|
|
1387
|
+
const firestore = getFirestore(firebaseApp);
|
|
1290
1388
|
const emulators = injector.get(DbxFirebaseParsedEmulatorsConfig, undefined);
|
|
1291
1389
|
if (emulators?.useEmulators && emulators?.firestore) {
|
|
1292
1390
|
connectFirestoreEmulator(firestore, emulators.firestore.host, emulators.firestore.port, {});
|
|
@@ -1300,7 +1398,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
1300
1398
|
args: [{
|
|
1301
1399
|
imports: [
|
|
1302
1400
|
provideFirestore(((injector) => {
|
|
1303
|
-
const
|
|
1401
|
+
const firebaseApp = injector.get(FirebaseApp);
|
|
1402
|
+
const firestore = getFirestore(firebaseApp);
|
|
1304
1403
|
const emulators = injector.get(DbxFirebaseParsedEmulatorsConfig, undefined);
|
|
1305
1404
|
if (emulators?.useEmulators && emulators?.firestore) {
|
|
1306
1405
|
connectFirestoreEmulator(firestore, emulators.firestore.host, emulators.firestore.port, {});
|
|
@@ -1311,16 +1410,100 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
1311
1410
|
]
|
|
1312
1411
|
}]
|
|
1313
1412
|
}] });
|
|
1413
|
+
/**
|
|
1414
|
+
* Default firebase app check provider module.
|
|
1415
|
+
*
|
|
1416
|
+
* Also configures the DbxFirebaseAppCheckHttpInterceptor with HTTP_INTERCEPTORS in order for appCheck to be appended to requests to the api.
|
|
1417
|
+
*/
|
|
1418
|
+
class DbxFirebaseDefaultAppCheckProviderModule {
|
|
1419
|
+
}
|
|
1420
|
+
DbxFirebaseDefaultAppCheckProviderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultAppCheckProviderModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1421
|
+
DbxFirebaseDefaultAppCheckProviderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultAppCheckProviderModule, imports: [i1.AppCheckModule] });
|
|
1422
|
+
DbxFirebaseDefaultAppCheckProviderModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultAppCheckProviderModule, providers: [
|
|
1423
|
+
{
|
|
1424
|
+
provide: HTTP_INTERCEPTORS,
|
|
1425
|
+
useClass: DbxFirebaseAppCheckHttpInterceptor,
|
|
1426
|
+
multi: true
|
|
1427
|
+
}
|
|
1428
|
+
], imports: [[
|
|
1429
|
+
provideAppCheck(((injector) => {
|
|
1430
|
+
const firebaseApp = injector.get(FirebaseApp);
|
|
1431
|
+
const firebaseOptions = injector.get(DBX_FIREBASE_OPTIONS_TOKEN);
|
|
1432
|
+
const appCheckOptions = firebaseOptions.appCheck;
|
|
1433
|
+
const appCheckKnowinglyDisabled = appCheckOptions?.disabled === true || firebaseOptions.emulators?.useEmulators === true;
|
|
1434
|
+
let appCheck;
|
|
1435
|
+
if (appCheckOptions && !appCheckKnowinglyDisabled) {
|
|
1436
|
+
// enable the debug tokens if not using emulators and allowDebugTokens is set true
|
|
1437
|
+
if (firebaseOptions.emulators?.useEmulators !== true && appCheckOptions.allowDebugTokens) {
|
|
1438
|
+
enableAppCheckDebugTokenGeneration(true);
|
|
1439
|
+
}
|
|
1440
|
+
// Only enabled outside of app-check environments. The emulators will not use appcheck.
|
|
1441
|
+
appCheck = initializeAppCheck(firebaseApp, {
|
|
1442
|
+
provider: new ReCaptchaV3Provider(appCheckOptions.reCaptchaV3),
|
|
1443
|
+
isTokenAutoRefreshEnabled: appCheckOptions.isTokenAutoRefreshEnabled ?? true
|
|
1444
|
+
});
|
|
1445
|
+
console.debug('Enabled AppCheck.');
|
|
1446
|
+
}
|
|
1447
|
+
else {
|
|
1448
|
+
appCheck = undefined;
|
|
1449
|
+
if (!appCheckKnowinglyDisabled) {
|
|
1450
|
+
console.error('dbx-firebase: No appcheck configuration for the app, and not specifically disabled in config either.');
|
|
1451
|
+
}
|
|
1452
|
+
}
|
|
1453
|
+
return appCheck;
|
|
1454
|
+
}))
|
|
1455
|
+
]] });
|
|
1456
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultAppCheckProviderModule, decorators: [{
|
|
1457
|
+
type: NgModule,
|
|
1458
|
+
args: [{
|
|
1459
|
+
imports: [
|
|
1460
|
+
provideAppCheck(((injector) => {
|
|
1461
|
+
const firebaseApp = injector.get(FirebaseApp);
|
|
1462
|
+
const firebaseOptions = injector.get(DBX_FIREBASE_OPTIONS_TOKEN);
|
|
1463
|
+
const appCheckOptions = firebaseOptions.appCheck;
|
|
1464
|
+
const appCheckKnowinglyDisabled = appCheckOptions?.disabled === true || firebaseOptions.emulators?.useEmulators === true;
|
|
1465
|
+
let appCheck;
|
|
1466
|
+
if (appCheckOptions && !appCheckKnowinglyDisabled) {
|
|
1467
|
+
// enable the debug tokens if not using emulators and allowDebugTokens is set true
|
|
1468
|
+
if (firebaseOptions.emulators?.useEmulators !== true && appCheckOptions.allowDebugTokens) {
|
|
1469
|
+
enableAppCheckDebugTokenGeneration(true);
|
|
1470
|
+
}
|
|
1471
|
+
// Only enabled outside of app-check environments. The emulators will not use appcheck.
|
|
1472
|
+
appCheck = initializeAppCheck(firebaseApp, {
|
|
1473
|
+
provider: new ReCaptchaV3Provider(appCheckOptions.reCaptchaV3),
|
|
1474
|
+
isTokenAutoRefreshEnabled: appCheckOptions.isTokenAutoRefreshEnabled ?? true
|
|
1475
|
+
});
|
|
1476
|
+
console.debug('Enabled AppCheck.');
|
|
1477
|
+
}
|
|
1478
|
+
else {
|
|
1479
|
+
appCheck = undefined;
|
|
1480
|
+
if (!appCheckKnowinglyDisabled) {
|
|
1481
|
+
console.error('dbx-firebase: No appcheck configuration for the app, and not specifically disabled in config either.');
|
|
1482
|
+
}
|
|
1483
|
+
}
|
|
1484
|
+
return appCheck;
|
|
1485
|
+
}))
|
|
1486
|
+
],
|
|
1487
|
+
providers: [
|
|
1488
|
+
{
|
|
1489
|
+
provide: HTTP_INTERCEPTORS,
|
|
1490
|
+
useClass: DbxFirebaseAppCheckHttpInterceptor,
|
|
1491
|
+
multi: true
|
|
1492
|
+
}
|
|
1493
|
+
]
|
|
1494
|
+
}]
|
|
1495
|
+
}] });
|
|
1314
1496
|
/**
|
|
1315
1497
|
* Default firebase auth provider module.
|
|
1316
1498
|
*/
|
|
1317
1499
|
class DbxFirebaseDefaultAuthProviderModule {
|
|
1318
1500
|
}
|
|
1319
1501
|
DbxFirebaseDefaultAuthProviderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultAuthProviderModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1320
|
-
DbxFirebaseDefaultAuthProviderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultAuthProviderModule, imports: [i1.AuthModule] });
|
|
1502
|
+
DbxFirebaseDefaultAuthProviderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultAuthProviderModule, imports: [i1$1.AuthModule] });
|
|
1321
1503
|
DbxFirebaseDefaultAuthProviderModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultAuthProviderModule, imports: [[
|
|
1322
1504
|
provideAuth(((injector) => {
|
|
1323
|
-
const
|
|
1505
|
+
const firebaseApp = injector.get(FirebaseApp);
|
|
1506
|
+
const auth = getAuth(firebaseApp);
|
|
1324
1507
|
const emulators = injector.get(DbxFirebaseParsedEmulatorsConfig, undefined);
|
|
1325
1508
|
if (emulators?.useEmulators && emulators?.auth) {
|
|
1326
1509
|
connectAuthEmulator(auth, `http://${emulators.auth.host}:${emulators.auth.port}`);
|
|
@@ -1333,7 +1516,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
1333
1516
|
args: [{
|
|
1334
1517
|
imports: [
|
|
1335
1518
|
provideAuth(((injector) => {
|
|
1336
|
-
const
|
|
1519
|
+
const firebaseApp = injector.get(FirebaseApp);
|
|
1520
|
+
const auth = getAuth(firebaseApp);
|
|
1337
1521
|
const emulators = injector.get(DbxFirebaseParsedEmulatorsConfig, undefined);
|
|
1338
1522
|
if (emulators?.useEmulators && emulators?.auth) {
|
|
1339
1523
|
connectAuthEmulator(auth, `http://${emulators.auth.host}:${emulators.auth.port}`);
|
|
@@ -1349,10 +1533,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
1349
1533
|
class DbxFirebaseDefaultStorageProviderModule {
|
|
1350
1534
|
}
|
|
1351
1535
|
DbxFirebaseDefaultStorageProviderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultStorageProviderModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1352
|
-
DbxFirebaseDefaultStorageProviderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultStorageProviderModule, imports: [
|
|
1536
|
+
DbxFirebaseDefaultStorageProviderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultStorageProviderModule, imports: [i4$1.StorageModule] });
|
|
1353
1537
|
DbxFirebaseDefaultStorageProviderModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultStorageProviderModule, imports: [[
|
|
1354
1538
|
provideStorage(((injector) => {
|
|
1355
|
-
const
|
|
1539
|
+
const firebaseApp = injector.get(FirebaseApp);
|
|
1540
|
+
const storage = getStorage(firebaseApp);
|
|
1356
1541
|
const emulators = injector.get(DbxFirebaseParsedEmulatorsConfig, undefined);
|
|
1357
1542
|
if (emulators?.useEmulators && emulators?.storage) {
|
|
1358
1543
|
connectStorageEmulator(storage, emulators.storage.host, emulators.storage.port, {});
|
|
@@ -1365,7 +1550,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
1365
1550
|
args: [{
|
|
1366
1551
|
imports: [
|
|
1367
1552
|
provideStorage(((injector) => {
|
|
1368
|
-
const
|
|
1553
|
+
const firebaseApp = injector.get(FirebaseApp);
|
|
1554
|
+
const storage = getStorage(firebaseApp);
|
|
1369
1555
|
const emulators = injector.get(DbxFirebaseParsedEmulatorsConfig, undefined);
|
|
1370
1556
|
if (emulators?.useEmulators && emulators?.storage) {
|
|
1371
1557
|
connectStorageEmulator(storage, emulators.storage.host, emulators.storage.port, {});
|
|
@@ -1381,10 +1567,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
1381
1567
|
class DbxFirebaseDefaultFunctionsProviderModule {
|
|
1382
1568
|
}
|
|
1383
1569
|
DbxFirebaseDefaultFunctionsProviderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultFunctionsProviderModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1384
|
-
DbxFirebaseDefaultFunctionsProviderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultFunctionsProviderModule, imports: [
|
|
1570
|
+
DbxFirebaseDefaultFunctionsProviderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultFunctionsProviderModule, imports: [i5.FunctionsModule] });
|
|
1385
1571
|
DbxFirebaseDefaultFunctionsProviderModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultFunctionsProviderModule, imports: [[
|
|
1386
1572
|
provideFunctions(((injector) => {
|
|
1387
|
-
const
|
|
1573
|
+
const firebaseApp = injector.get(FirebaseApp);
|
|
1574
|
+
const firebaseOptions = injector.get(DBX_FIREBASE_OPTIONS_TOKEN);
|
|
1575
|
+
const { functionsRegionOrCustomDomain } = firebaseOptions;
|
|
1576
|
+
const functions = getFunctions(firebaseApp, functionsRegionOrCustomDomain);
|
|
1388
1577
|
const emulators = injector.get(DbxFirebaseParsedEmulatorsConfig, undefined);
|
|
1389
1578
|
if (emulators?.useEmulators && emulators?.functions) {
|
|
1390
1579
|
connectFunctionsEmulator(functions, emulators.functions.host, emulators.functions.port);
|
|
@@ -1397,7 +1586,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
1397
1586
|
args: [{
|
|
1398
1587
|
imports: [
|
|
1399
1588
|
provideFunctions(((injector) => {
|
|
1400
|
-
const
|
|
1589
|
+
const firebaseApp = injector.get(FirebaseApp);
|
|
1590
|
+
const firebaseOptions = injector.get(DBX_FIREBASE_OPTIONS_TOKEN);
|
|
1591
|
+
const { functionsRegionOrCustomDomain } = firebaseOptions;
|
|
1592
|
+
const functions = getFunctions(firebaseApp, functionsRegionOrCustomDomain);
|
|
1401
1593
|
const emulators = injector.get(DbxFirebaseParsedEmulatorsConfig, undefined);
|
|
1402
1594
|
if (emulators?.useEmulators && emulators?.functions) {
|
|
1403
1595
|
connectFunctionsEmulator(functions, emulators.functions.host, emulators.functions.port);
|
|
@@ -1407,7 +1599,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
1407
1599
|
]
|
|
1408
1600
|
}]
|
|
1409
1601
|
}] });
|
|
1410
|
-
const DBX_FIREBASE_OPTIONS_TOKEN = new InjectionToken('DbxFirebaseOptions');
|
|
1411
1602
|
/**
|
|
1412
1603
|
* Default provider module.
|
|
1413
1604
|
*/
|
|
@@ -1415,37 +1606,41 @@ class DbxFirebaseDefaultFirebaseProvidersModule {
|
|
|
1415
1606
|
static forRoot(firebaseOptions) {
|
|
1416
1607
|
return {
|
|
1417
1608
|
ngModule: DbxFirebaseDefaultFirebaseProvidersModule,
|
|
1418
|
-
providers: [
|
|
1609
|
+
providers: [
|
|
1610
|
+
{
|
|
1419
1611
|
provide: DBX_FIREBASE_OPTIONS_TOKEN,
|
|
1420
1612
|
useValue: firebaseOptions
|
|
1421
|
-
}
|
|
1613
|
+
}
|
|
1614
|
+
]
|
|
1422
1615
|
};
|
|
1423
1616
|
}
|
|
1424
1617
|
}
|
|
1425
1618
|
DbxFirebaseDefaultFirebaseProvidersModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultFirebaseProvidersModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1426
|
-
DbxFirebaseDefaultFirebaseProvidersModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultFirebaseProvidersModule, imports: [DbxFirebaseDefaultFirestoreProviderModule, DbxFirebaseDefaultAuthProviderModule, DbxFirebaseDefaultStorageProviderModule, DbxFirebaseDefaultFunctionsProviderModule
|
|
1619
|
+
DbxFirebaseDefaultFirebaseProvidersModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultFirebaseProvidersModule, imports: [i6$1.FirebaseAppModule, DbxFirebaseDefaultAppCheckProviderModule, DbxFirebaseDefaultFirestoreProviderModule, DbxFirebaseDefaultAuthProviderModule, DbxFirebaseDefaultStorageProviderModule, DbxFirebaseDefaultFunctionsProviderModule] });
|
|
1427
1620
|
DbxFirebaseDefaultFirebaseProvidersModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultFirebaseProvidersModule, imports: [[
|
|
1428
|
-
DbxFirebaseDefaultFirestoreProviderModule,
|
|
1429
|
-
DbxFirebaseDefaultAuthProviderModule,
|
|
1430
|
-
DbxFirebaseDefaultStorageProviderModule,
|
|
1431
|
-
DbxFirebaseDefaultFunctionsProviderModule,
|
|
1432
1621
|
provideFirebaseApp(((injector) => {
|
|
1433
1622
|
const firebaseOptions = injector.get(DBX_FIREBASE_OPTIONS_TOKEN);
|
|
1434
1623
|
return initializeApp(firebaseOptions);
|
|
1435
|
-
}))
|
|
1624
|
+
})),
|
|
1625
|
+
DbxFirebaseDefaultAppCheckProviderModule,
|
|
1626
|
+
DbxFirebaseDefaultFirestoreProviderModule,
|
|
1627
|
+
DbxFirebaseDefaultAuthProviderModule,
|
|
1628
|
+
DbxFirebaseDefaultStorageProviderModule,
|
|
1629
|
+
DbxFirebaseDefaultFunctionsProviderModule
|
|
1436
1630
|
]] });
|
|
1437
1631
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseDefaultFirebaseProvidersModule, decorators: [{
|
|
1438
1632
|
type: NgModule,
|
|
1439
1633
|
args: [{
|
|
1440
1634
|
imports: [
|
|
1441
|
-
DbxFirebaseDefaultFirestoreProviderModule,
|
|
1442
|
-
DbxFirebaseDefaultAuthProviderModule,
|
|
1443
|
-
DbxFirebaseDefaultStorageProviderModule,
|
|
1444
|
-
DbxFirebaseDefaultFunctionsProviderModule,
|
|
1445
1635
|
provideFirebaseApp(((injector) => {
|
|
1446
1636
|
const firebaseOptions = injector.get(DBX_FIREBASE_OPTIONS_TOKEN);
|
|
1447
1637
|
return initializeApp(firebaseOptions);
|
|
1448
|
-
}))
|
|
1638
|
+
})),
|
|
1639
|
+
DbxFirebaseDefaultAppCheckProviderModule,
|
|
1640
|
+
DbxFirebaseDefaultFirestoreProviderModule,
|
|
1641
|
+
DbxFirebaseDefaultAuthProviderModule,
|
|
1642
|
+
DbxFirebaseDefaultStorageProviderModule,
|
|
1643
|
+
DbxFirebaseDefaultFunctionsProviderModule
|
|
1449
1644
|
]
|
|
1450
1645
|
}]
|
|
1451
1646
|
}] });
|
|
@@ -1457,7 +1652,7 @@ class DbxFirebaseEmulatorModule {
|
|
|
1457
1652
|
static forRoot(config) {
|
|
1458
1653
|
const defaultHost = config.host ?? 'localhost';
|
|
1459
1654
|
function emulatorConfig(emulator) {
|
|
1460
|
-
return
|
|
1655
|
+
return emulator ? { host: emulator.host ?? defaultHost, port: emulator.port } : undefined;
|
|
1461
1656
|
}
|
|
1462
1657
|
const finalConfig = {
|
|
1463
1658
|
useEmulators: config.useEmulators !== false,
|
|
@@ -1469,10 +1664,12 @@ class DbxFirebaseEmulatorModule {
|
|
|
1469
1664
|
};
|
|
1470
1665
|
return {
|
|
1471
1666
|
ngModule: DbxFirebaseEmulatorModule,
|
|
1472
|
-
providers: [
|
|
1667
|
+
providers: [
|
|
1668
|
+
{
|
|
1473
1669
|
provide: DbxFirebaseParsedEmulatorsConfig,
|
|
1474
1670
|
useValue: finalConfig
|
|
1475
|
-
}
|
|
1671
|
+
}
|
|
1672
|
+
]
|
|
1476
1673
|
};
|
|
1477
1674
|
}
|
|
1478
1675
|
}
|
|
@@ -1495,15 +1692,18 @@ class DbxFirebaseFirestoreCollectionModule {
|
|
|
1495
1692
|
static forRoot(config) {
|
|
1496
1693
|
return {
|
|
1497
1694
|
ngModule: DbxFirebaseFirestoreCollectionModule,
|
|
1498
|
-
providers: [
|
|
1695
|
+
providers: [
|
|
1696
|
+
{
|
|
1499
1697
|
provide: DBX_FIRESTORE_CONTEXT_TOKEN,
|
|
1500
1698
|
useFactory: firebaseFirestoreContextFactory,
|
|
1501
1699
|
deps: [Firestore]
|
|
1502
|
-
},
|
|
1700
|
+
},
|
|
1701
|
+
{
|
|
1503
1702
|
provide: config.appCollectionClass,
|
|
1504
1703
|
useFactory: config.collectionFactory,
|
|
1505
1704
|
deps: [DBX_FIRESTORE_CONTEXT_TOKEN]
|
|
1506
|
-
}
|
|
1705
|
+
}
|
|
1706
|
+
]
|
|
1507
1707
|
};
|
|
1508
1708
|
}
|
|
1509
1709
|
}
|
|
@@ -1539,11 +1739,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
1539
1739
|
*/
|
|
1540
1740
|
class DbxFirebaseFunctionsModule {
|
|
1541
1741
|
static forRoot(config) {
|
|
1542
|
-
const providers = [
|
|
1742
|
+
const providers = [
|
|
1743
|
+
{
|
|
1543
1744
|
provide: config.functionsGetterToken,
|
|
1544
1745
|
useFactory: config.functionsGetterFactory,
|
|
1545
1746
|
deps: [Functions]
|
|
1546
|
-
}
|
|
1747
|
+
}
|
|
1748
|
+
];
|
|
1547
1749
|
if (config.functionsConfigMap) {
|
|
1548
1750
|
forEachKeyValue(config.functionsConfigMap, {
|
|
1549
1751
|
forEach: ([key, entry]) => {
|
|
@@ -1591,10 +1793,7 @@ class DbxFirebaseCollectionLoaderInstance {
|
|
|
1591
1793
|
this._maxPagesSub = new SubscriptionObject();
|
|
1592
1794
|
this.collection$ = this._collection.pipe(distinctUntilChanged());
|
|
1593
1795
|
this.constraints$ = this._constraints.pipe(distinctUntilChanged());
|
|
1594
|
-
this.iteratorFilter$ = combineLatest([
|
|
1595
|
-
this._itemsPerPage.pipe(distinctUntilChanged()),
|
|
1596
|
-
this.constraints$
|
|
1597
|
-
]).pipe(map(([limit, constraints]) => ({ limit, constraints, maxPageLoadLimit: this.maxPages })), shareReplay(1));
|
|
1796
|
+
this.iteratorFilter$ = combineLatest([this._itemsPerPage.pipe(distinctUntilChanged()), this.constraints$]).pipe(map(([limit, constraints]) => ({ limit, constraints, maxPageLoadLimit: this.maxPages })), shareReplay(1));
|
|
1598
1797
|
this.firestoreIteration$ = this.collection$.pipe(switchMap((collection) => {
|
|
1599
1798
|
if (collection) {
|
|
1600
1799
|
return combineLatest([this.iteratorFilter$, this._restart.pipe(startWith(undefined))]).pipe(throttleTime(100, undefined, { trailing: true }), // prevent rapid changes and executing filters too quickly.
|
|
@@ -1606,16 +1805,18 @@ class DbxFirebaseCollectionLoaderInstance {
|
|
|
1606
1805
|
}
|
|
1607
1806
|
}), cleanupDestroyable(), // cleanup the iteration
|
|
1608
1807
|
shareReplay(1));
|
|
1609
|
-
this.queryChangeWatcher$ = this.firestoreIteration$.pipe(map(instance => iterationQueryDocChangeWatcher({ instance })), shareReplay(1));
|
|
1610
|
-
this.accumulator$ = this.firestoreIteration$.pipe(map(x => firebaseQueryItemAccumulator(x)), cleanupDestroyable(), shareReplay(1));
|
|
1611
|
-
this.pageLoadingState$ = this.accumulator$.pipe(switchMap(x => accumulatorFlattenPageListLoadingState(x)), shareReplay(1));
|
|
1808
|
+
this.queryChangeWatcher$ = this.firestoreIteration$.pipe(map((instance) => iterationQueryDocChangeWatcher({ instance })), shareReplay(1));
|
|
1809
|
+
this.accumulator$ = this.firestoreIteration$.pipe(map((x) => firebaseQueryItemAccumulator(x)), cleanupDestroyable(), shareReplay(1));
|
|
1810
|
+
this.pageLoadingState$ = this.accumulator$.pipe(switchMap((x) => accumulatorFlattenPageListLoadingState(x)), shareReplay(1));
|
|
1612
1811
|
}
|
|
1613
1812
|
init() {
|
|
1614
1813
|
// When max pages changes, update the iteration's max page limit.
|
|
1615
|
-
this._maxPagesSub.subscription = this._maxPages
|
|
1814
|
+
this._maxPagesSub.subscription = this._maxPages
|
|
1815
|
+
.pipe(distinctUntilChanged(), filterMaybe(), // do not pass null/undefined values
|
|
1616
1816
|
switchMap((maxPageLoadLimit) => this.firestoreIteration$.pipe(tap((iteration) => {
|
|
1617
1817
|
iteration.maxPageLoadLimit = maxPageLoadLimit;
|
|
1618
|
-
}))))
|
|
1818
|
+
}))))
|
|
1819
|
+
.subscribe();
|
|
1619
1820
|
}
|
|
1620
1821
|
destroy() {
|
|
1621
1822
|
this._maxPages.complete();
|
|
@@ -1715,10 +1916,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
1715
1916
|
type: Input
|
|
1716
1917
|
}] } });
|
|
1717
1918
|
function provideDbxFirebaseCollectionStoreDirective(sourceType, storeType) {
|
|
1718
|
-
const providers = [
|
|
1919
|
+
const providers = [
|
|
1920
|
+
{
|
|
1719
1921
|
provide: DbxFirebaseCollectionStoreDirective,
|
|
1720
1922
|
useExisting: forwardRef(() => sourceType)
|
|
1721
|
-
}
|
|
1923
|
+
}
|
|
1924
|
+
];
|
|
1722
1925
|
if (storeType) {
|
|
1723
1926
|
providers.push(storeType);
|
|
1724
1927
|
}
|
|
@@ -1734,16 +1937,18 @@ class DbxFirebaseCollectionChangeDirective extends AbstractSubscriptionDirective
|
|
|
1734
1937
|
this.dbxFirebaseCollectionStoreDirective = dbxFirebaseCollectionStoreDirective;
|
|
1735
1938
|
this._mode = new BehaviorSubject('manual');
|
|
1736
1939
|
this.mode$ = this._mode.pipe(distinctUntilChanged());
|
|
1737
|
-
this.event$ = this.dbxFirebaseCollectionStoreDirective.store.queryChangeWatcher$.pipe(switchMap((x) => x.event$.pipe(filter(x => x.type !== 'none'), // do not share 'none' events.
|
|
1940
|
+
this.event$ = this.dbxFirebaseCollectionStoreDirective.store.queryChangeWatcher$.pipe(switchMap((x) => x.event$.pipe(filter((x) => x.type !== 'none'), // do not share 'none' events.
|
|
1738
1941
|
take(1), // only need one event to mark as change is available.
|
|
1739
1942
|
startWith({
|
|
1740
1943
|
time: new Date(),
|
|
1741
1944
|
type: 'none'
|
|
1742
1945
|
}))), shareReplay(1));
|
|
1743
|
-
this.hasChangeAvailable$ = this.event$.pipe(map(x => x.type !== 'none'), shareReplay(1));
|
|
1946
|
+
this.hasChangeAvailable$ = this.event$.pipe(map((x) => x.type !== 'none'), shareReplay(1));
|
|
1744
1947
|
}
|
|
1745
1948
|
ngOnInit() {
|
|
1746
|
-
this.sub = combineLatest([this.mode$, this.hasChangeAvailable$])
|
|
1949
|
+
this.sub = combineLatest([this.mode$, this.hasChangeAvailable$])
|
|
1950
|
+
.pipe(filter(([mode, hasChange]) => mode === 'auto' && hasChange))
|
|
1951
|
+
.subscribe(() => {
|
|
1747
1952
|
this.restart();
|
|
1748
1953
|
});
|
|
1749
1954
|
}
|
|
@@ -1879,10 +2084,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
1879
2084
|
type: Input
|
|
1880
2085
|
}] } });
|
|
1881
2086
|
function provideDbxFirebaseDocumentStoreDirective(sourceType, storeType) {
|
|
1882
|
-
const providers = [
|
|
2087
|
+
const providers = [
|
|
2088
|
+
{
|
|
1883
2089
|
provide: DbxFirebaseDocumentStoreDirective,
|
|
1884
2090
|
useExisting: forwardRef(() => sourceType)
|
|
1885
|
-
}
|
|
2091
|
+
}
|
|
2092
|
+
];
|
|
1886
2093
|
if (storeType) {
|
|
1887
2094
|
providers.push(storeType);
|
|
1888
2095
|
}
|
|
@@ -1928,7 +2135,7 @@ class DbxFirebaseDocumentStoreRouteIdDirective extends AbstractSubscriptionDirec
|
|
|
1928
2135
|
this.idParamKey$ = this._idParamKey.asObservable();
|
|
1929
2136
|
this.idFromParams$ = combineLatest([this.idParamKey$, this.dbxRouterService.params$]).pipe(map(([key, params]) => {
|
|
1930
2137
|
return params[key] ?? undefined;
|
|
1931
|
-
}), distinctUntilChanged(), shareReplay
|
|
2138
|
+
}), distinctUntilChanged(), shareReplay(1));
|
|
1932
2139
|
}
|
|
1933
2140
|
ngOnInit() {
|
|
1934
2141
|
this.sub = this.dbxFirebaseDocumentStoreDirective.store.setId(this.idFromParams$);
|
|
@@ -1962,34 +2169,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
1962
2169
|
class DbxFirebaseModelStoreModule {
|
|
1963
2170
|
}
|
|
1964
2171
|
DbxFirebaseModelStoreModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseModelStoreModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1965
|
-
DbxFirebaseModelStoreModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseModelStoreModule, declarations: [DbxFirebaseCollectionListDirective,
|
|
1966
|
-
DbxFirebaseCollectionChangeDirective,
|
|
1967
|
-
DbxFirebaseCollectionHasChangeDirective,
|
|
1968
|
-
DbxFirebaseDocumentStoreRouteIdDirective,
|
|
1969
|
-
DbxFirebaseDocumentAuthIdDirective], exports: [DbxFirebaseCollectionListDirective,
|
|
1970
|
-
DbxFirebaseCollectionChangeDirective,
|
|
1971
|
-
DbxFirebaseCollectionHasChangeDirective,
|
|
1972
|
-
DbxFirebaseDocumentStoreRouteIdDirective,
|
|
1973
|
-
DbxFirebaseDocumentAuthIdDirective] });
|
|
2172
|
+
DbxFirebaseModelStoreModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseModelStoreModule, declarations: [DbxFirebaseCollectionListDirective, DbxFirebaseCollectionChangeDirective, DbxFirebaseCollectionHasChangeDirective, DbxFirebaseDocumentStoreRouteIdDirective, DbxFirebaseDocumentAuthIdDirective], exports: [DbxFirebaseCollectionListDirective, DbxFirebaseCollectionChangeDirective, DbxFirebaseCollectionHasChangeDirective, DbxFirebaseDocumentStoreRouteIdDirective, DbxFirebaseDocumentAuthIdDirective] });
|
|
1974
2173
|
DbxFirebaseModelStoreModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseModelStoreModule, imports: [[]] });
|
|
1975
2174
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseModelStoreModule, decorators: [{
|
|
1976
2175
|
type: NgModule,
|
|
1977
2176
|
args: [{
|
|
1978
2177
|
imports: [],
|
|
1979
|
-
declarations: [
|
|
1980
|
-
|
|
1981
|
-
DbxFirebaseCollectionChangeDirective,
|
|
1982
|
-
DbxFirebaseCollectionHasChangeDirective,
|
|
1983
|
-
DbxFirebaseDocumentStoreRouteIdDirective,
|
|
1984
|
-
DbxFirebaseDocumentAuthIdDirective
|
|
1985
|
-
],
|
|
1986
|
-
exports: [
|
|
1987
|
-
DbxFirebaseCollectionListDirective,
|
|
1988
|
-
DbxFirebaseCollectionChangeDirective,
|
|
1989
|
-
DbxFirebaseCollectionHasChangeDirective,
|
|
1990
|
-
DbxFirebaseDocumentStoreRouteIdDirective,
|
|
1991
|
-
DbxFirebaseDocumentAuthIdDirective
|
|
1992
|
-
]
|
|
2178
|
+
declarations: [DbxFirebaseCollectionListDirective, DbxFirebaseCollectionChangeDirective, DbxFirebaseCollectionHasChangeDirective, DbxFirebaseDocumentStoreRouteIdDirective, DbxFirebaseDocumentAuthIdDirective],
|
|
2179
|
+
exports: [DbxFirebaseCollectionListDirective, DbxFirebaseCollectionChangeDirective, DbxFirebaseCollectionHasChangeDirective, DbxFirebaseDocumentStoreRouteIdDirective, DbxFirebaseDocumentAuthIdDirective]
|
|
1993
2180
|
}]
|
|
1994
2181
|
}] });
|
|
1995
2182
|
|
|
@@ -2001,10 +2188,10 @@ class AbstractDbxFirebaseCollectionStore extends LockSetComponentStore {
|
|
|
2001
2188
|
super(...arguments);
|
|
2002
2189
|
// MARK: Effects
|
|
2003
2190
|
this.setMaxPages = this.effect((input) => {
|
|
2004
|
-
return input.pipe(switchMap((maxPages) => this.loader$.pipe(tap((x) => x.maxPages = maxPages))));
|
|
2191
|
+
return input.pipe(switchMap((maxPages) => this.loader$.pipe(tap((x) => (x.maxPages = maxPages)))));
|
|
2005
2192
|
});
|
|
2006
2193
|
this.setItemsPerPage = this.effect((input) => {
|
|
2007
|
-
return input.pipe(switchMap((itemsPerPage) => this.loader$.pipe(tap((x) => x.itemsPerPage = itemsPerPage))));
|
|
2194
|
+
return input.pipe(switchMap((itemsPerPage) => this.loader$.pipe(tap((x) => (x.itemsPerPage = itemsPerPage)))));
|
|
2008
2195
|
});
|
|
2009
2196
|
this.setConstraints = this.effect((input) => {
|
|
2010
2197
|
return input.pipe(switchMap((constraints) => this.loader$.pipe(tap((x) => x.setConstraints(constraints)))));
|
|
@@ -2018,16 +2205,16 @@ class AbstractDbxFirebaseCollectionStore extends LockSetComponentStore {
|
|
|
2018
2205
|
// MARK: Accessors
|
|
2019
2206
|
this.currentFirestoreCollection$ = this.state$.pipe(map((x) => x.firestoreCollection), distinctUntilChanged(), shareReplay(1));
|
|
2020
2207
|
this.firestoreCollection$ = this.currentFirestoreCollection$.pipe(filterMaybe());
|
|
2021
|
-
this.loader$ = this.currentFirestoreCollection$.pipe(switchMap((collection) => this.state$.pipe(first(), map(x => dbxFirebaseCollectionLoaderInstance({
|
|
2208
|
+
this.loader$ = this.currentFirestoreCollection$.pipe(switchMap((collection) => this.state$.pipe(first(), map((x) => dbxFirebaseCollectionLoaderInstance({
|
|
2022
2209
|
collection,
|
|
2023
2210
|
maxPages: x.maxPages,
|
|
2024
2211
|
itemsPerPage: x.itemsPerPage,
|
|
2025
2212
|
constraints: x.constraints
|
|
2026
2213
|
})))), cleanupDestroyable(), distinctUntilChanged(), shareReplay(1));
|
|
2027
|
-
this.firestoreIteration$ = this.loader$.pipe(switchMap(x => x.firestoreIteration$));
|
|
2028
|
-
this.queryChangeWatcher$ = this.loader$.pipe(switchMap(x => x.queryChangeWatcher$));
|
|
2029
|
-
this.accumulator$ = this.loader$.pipe(switchMap(x => x.accumulator$));
|
|
2030
|
-
this.pageLoadingState$ = this.loader$.pipe(switchMap(x => x.pageLoadingState$));
|
|
2214
|
+
this.firestoreIteration$ = this.loader$.pipe(switchMap((x) => x.firestoreIteration$));
|
|
2215
|
+
this.queryChangeWatcher$ = this.loader$.pipe(switchMap((x) => x.queryChangeWatcher$));
|
|
2216
|
+
this.accumulator$ = this.loader$.pipe(switchMap((x) => x.accumulator$));
|
|
2217
|
+
this.pageLoadingState$ = this.loader$.pipe(switchMap((x) => x.pageLoadingState$));
|
|
2031
2218
|
this.setFirestoreCollection = this.updater((state, firestoreCollection) => ({ ...state, firestoreCollection }));
|
|
2032
2219
|
}
|
|
2033
2220
|
}
|
|
@@ -2052,9 +2239,9 @@ class AbstractDbxFirebaseDocumentStore extends LockSetComponentStore {
|
|
|
2052
2239
|
// MARK: Accessors
|
|
2053
2240
|
this.currentFirestoreCollection$ = this.state$.pipe(map((x) => x.firestoreCollection), distinctUntilChanged(), shareReplay(1));
|
|
2054
2241
|
this.firestoreCollection$ = this.currentFirestoreCollection$.pipe(filterMaybe());
|
|
2055
|
-
this.currentInputId$ = this.state$.pipe(map(x => x.id), distinctUntilChanged(), shareReplay(1));
|
|
2242
|
+
this.currentInputId$ = this.state$.pipe(map((x) => x.id), distinctUntilChanged(), shareReplay(1));
|
|
2056
2243
|
this.inputId$ = this.currentInputId$.pipe(filterMaybe(), distinctUntilChanged(), shareReplay(1));
|
|
2057
|
-
this.currentInputRef$ = this.state$.pipe(map(x => x.ref), distinctUntilChanged(), shareReplay(1));
|
|
2244
|
+
this.currentInputRef$ = this.state$.pipe(map((x) => x.ref), distinctUntilChanged(), shareReplay(1));
|
|
2058
2245
|
this.inputRef$ = this.currentInputRef$.pipe(filterMaybe(), distinctUntilChanged(), shareReplay(1));
|
|
2059
2246
|
this.currentDocument$ = combineLatest([this.currentFirestoreCollection$, this.currentInputId$, this.currentInputRef$]).pipe(map(([collection, id, ref]) => {
|
|
2060
2247
|
let document;
|
|
@@ -2069,12 +2256,12 @@ class AbstractDbxFirebaseDocumentStore extends LockSetComponentStore {
|
|
|
2069
2256
|
return document;
|
|
2070
2257
|
}), distinctUntilChanged(), shareReplay(1));
|
|
2071
2258
|
this.document$ = this.currentDocument$.pipe(filterMaybe(), distinctUntilChanged(), shareReplay(1));
|
|
2072
|
-
this.documentLoadingState$ = this.currentDocument$.pipe(map(x => (x
|
|
2073
|
-
this.id$ = this.document$.pipe(map(x => x.id), shareReplay());
|
|
2074
|
-
this.ref$ = this.document$.pipe(map(x => x.documentRef), shareReplay());
|
|
2075
|
-
this.snapshot$ = this.document$.pipe(switchMap(x => x.accessor.stream()), shareReplay(1));
|
|
2076
|
-
this.snapshotLoadingState$ = this.currentDocument$.pipe(switchMap(
|
|
2077
|
-
this.currentData$ = this.document$.pipe(switchMap(x => x.accessor.stream().pipe(map(y => documentDataWithId(y)))), shareReplay(1));
|
|
2259
|
+
this.documentLoadingState$ = this.currentDocument$.pipe(map((x) => (x ? successResult(x) : beginLoading())), shareReplay(1));
|
|
2260
|
+
this.id$ = this.document$.pipe(map((x) => x.id), shareReplay());
|
|
2261
|
+
this.ref$ = this.document$.pipe(map((x) => x.documentRef), shareReplay());
|
|
2262
|
+
this.snapshot$ = this.document$.pipe(switchMap((x) => x.accessor.stream()), shareReplay(1));
|
|
2263
|
+
this.snapshotLoadingState$ = this.currentDocument$.pipe(switchMap(() => loadingStateFromObs(this.snapshot$)), shareReplay(1));
|
|
2264
|
+
this.currentData$ = this.document$.pipe(switchMap((x) => x.accessor.stream().pipe(map((y) => documentDataWithId(y)))), shareReplay(1));
|
|
2078
2265
|
this.data$ = this.currentDocument$.pipe(switchMap(() => this.currentData$.pipe(filterMaybe())), shareReplay(1));
|
|
2079
2266
|
this.dataLoadingState$ = this.snapshotLoadingState$.pipe(map((x) => {
|
|
2080
2267
|
let result;
|
|
@@ -2095,17 +2282,17 @@ class AbstractDbxFirebaseDocumentStore extends LockSetComponentStore {
|
|
|
2095
2282
|
}
|
|
2096
2283
|
return result;
|
|
2097
2284
|
}), shareReplay(1));
|
|
2098
|
-
this.exists$ = this.currentData$.pipe(map(x => isMaybeSo(x)), shareReplay(1));
|
|
2099
|
-
this.doesNotExist$ = this.exists$.pipe(map(x => !x), shareReplay(1));
|
|
2285
|
+
this.exists$ = this.currentData$.pipe(map((x) => isMaybeSo(x)), shareReplay(1));
|
|
2286
|
+
this.doesNotExist$ = this.exists$.pipe(map((x) => !x), shareReplay(1));
|
|
2100
2287
|
// MARK: State Changes
|
|
2101
2288
|
/**
|
|
2102
2289
|
* Sets the id of the document to load.
|
|
2103
2290
|
*/
|
|
2104
|
-
this.setId = this.updater((state, id) => (id
|
|
2291
|
+
this.setId = this.updater((state, id) => (id ? { ...state, id, ref: undefined } : { ...state, id }));
|
|
2105
2292
|
/**
|
|
2106
2293
|
* Sets the ref of the document to load.
|
|
2107
2294
|
*/
|
|
2108
|
-
this.setRef = this.updater((state, ref) => (ref
|
|
2295
|
+
this.setRef = this.updater((state, ref) => (ref ? { ...state, id: undefined, ref } : { ...state, ref }));
|
|
2109
2296
|
this.setFirestoreCollection = this.updater((state, firestoreCollection) => ({ ...state, firestoreCollection }));
|
|
2110
2297
|
}
|
|
2111
2298
|
}
|
|
@@ -2165,9 +2352,9 @@ class AbstractDbxFirebaseCollectionWithParentStore extends AbstractDbxFirebaseCo
|
|
|
2165
2352
|
this.setParent = setParentEffect(this);
|
|
2166
2353
|
this.setParentStore = setParentStoreEffect(this);
|
|
2167
2354
|
// MARK: Accessors
|
|
2168
|
-
this.currentParent$ = this.state$.pipe(map(x => x.parent), distinctUntilChanged(), shareReplay(1));
|
|
2355
|
+
this.currentParent$ = this.state$.pipe(map((x) => x.parent), distinctUntilChanged(), shareReplay(1));
|
|
2169
2356
|
this.parent$ = this.currentParent$.pipe(filterMaybe());
|
|
2170
|
-
this.currentCollectionFactory$ = this.state$.pipe(map(x => x.collectionFactory), distinctUntilChanged(), shareReplay(1));
|
|
2357
|
+
this.currentCollectionFactory$ = this.state$.pipe(map((x) => x.collectionFactory), distinctUntilChanged(), shareReplay(1));
|
|
2171
2358
|
this.collectionFactory$ = this.currentCollectionFactory$.pipe(filterMaybe());
|
|
2172
2359
|
// MARK: State Changes
|
|
2173
2360
|
/**
|
|
@@ -2196,9 +2383,9 @@ class AbstractDbxFirebaseDocumentWithParentStore extends AbstractDbxFirebaseDocu
|
|
|
2196
2383
|
this.setParent = setParentEffect(this);
|
|
2197
2384
|
this.setParentStore = setParentStoreEffect(this);
|
|
2198
2385
|
// MARK: Accessors
|
|
2199
|
-
this.currentParent$ = this.state$.pipe(map(x => x.parent), distinctUntilChanged(), shareReplay(1));
|
|
2386
|
+
this.currentParent$ = this.state$.pipe(map((x) => x.parent), distinctUntilChanged(), shareReplay(1));
|
|
2200
2387
|
this.parent$ = this.currentParent$.pipe(filterMaybe());
|
|
2201
|
-
this.currentCollectionFactory$ = this.state$.pipe(map(x => x.collectionFactory), distinctUntilChanged(), shareReplay(1));
|
|
2388
|
+
this.currentCollectionFactory$ = this.state$.pipe(map((x) => x.collectionFactory), distinctUntilChanged(), shareReplay(1));
|
|
2202
2389
|
this.collectionFactory$ = this.currentCollectionFactory$.pipe(filterMaybe());
|
|
2203
2390
|
// MARK: State Changes
|
|
2204
2391
|
/**
|
|
@@ -2225,9 +2412,7 @@ DbxFirebaseModelModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0",
|
|
|
2225
2412
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseModelModule, decorators: [{
|
|
2226
2413
|
type: NgModule,
|
|
2227
2414
|
args: [{
|
|
2228
|
-
exports: [
|
|
2229
|
-
DbxFirebaseModelStoreModule
|
|
2230
|
-
]
|
|
2415
|
+
exports: [DbxFirebaseModelStoreModule]
|
|
2231
2416
|
}]
|
|
2232
2417
|
}] });
|
|
2233
2418
|
|
|
@@ -2239,9 +2424,7 @@ DbxFirebaseModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", versi
|
|
|
2239
2424
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: DbxFirebaseModule, decorators: [{
|
|
2240
2425
|
type: NgModule,
|
|
2241
2426
|
args: [{
|
|
2242
|
-
exports: [
|
|
2243
|
-
DbxFirebaseModelModule
|
|
2244
|
-
]
|
|
2427
|
+
exports: [DbxFirebaseModelModule]
|
|
2245
2428
|
}]
|
|
2246
2429
|
}] });
|
|
2247
2430
|
|
|
@@ -2249,5 +2432,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImpor
|
|
|
2249
2432
|
* Generated bundle index. Do not edit.
|
|
2250
2433
|
*/
|
|
2251
2434
|
|
|
2252
|
-
export { AbstractConfiguredDbxFirebaseLoginButtonDirective, AbstractDbxFirebaseCollectionStore, AbstractDbxFirebaseCollectionWithParentStore, AbstractDbxFirebaseDocumentStore, AbstractDbxFirebaseDocumentWithParentStore, DBX_FIREBASE_MODEL_DOES_NOT_EXIST_ERROR, DBX_FIREBASE_OPTIONS_TOKEN, DBX_FIREBASE_ROUTER_SYNC_DEFAULT_ID_PARAM_KEY, DBX_FIRESTORE_CONTEXT_TOKEN, DEFAULT_CONFIGURED_DBX_FIREBASE_LOGIN_BUTTON_TEMPLATE, DEFAULT_DBX_FIREBASE_AUTH_SERVICE_DELEGATE, DEFAULT_FIREBASE_AUTH_LOGIN_PASSWORD_CONFIG, DEFAULT_FIREBASE_AUTH_LOGIN_PASSWORD_CONFIG_TOKEN, DEFAULT_FIREBASE_AUTH_LOGIN_PROVIDERS_TOKEN, DEFAULT_FIREBASE_AUTH_LOGIN_TERMS_COMPONENT_CLASS_TOKEN, DEFAULT_FIREBASE_LOGIN_METHOD_CATEGORY, DbxFirebaseAuthLoginService, DbxFirebaseAuthModule, DbxFirebaseAuthService, DbxFirebaseAuthServiceDelegate, DbxFirebaseCollectionChangeDirective, DbxFirebaseCollectionHasChangeDirective, DbxFirebaseCollectionListDirective, DbxFirebaseCollectionLoaderInstance, DbxFirebaseCollectionStoreDirective, DbxFirebaseDefaultAuthProviderModule, DbxFirebaseDefaultFirebaseProvidersModule, DbxFirebaseDefaultFirestoreProviderModule, DbxFirebaseDefaultFunctionsProviderModule, DbxFirebaseDefaultStorageProviderModule, DbxFirebaseDocumentAuthIdDirective, DbxFirebaseDocumentStoreDirective, DbxFirebaseDocumentStoreRouteIdDirective, DbxFirebaseEmailFormComponent, DbxFirebaseEmailRecoveryFormComponent, DbxFirebaseEmulatorModule, DbxFirebaseFirestoreCollectionModule, DbxFirebaseFunctionsModule, DbxFirebaseLoginAnonymousComponent, DbxFirebaseLoginAppleComponent, DbxFirebaseLoginButtonComponent, DbxFirebaseLoginButtonContainerComponent, DbxFirebaseLoginComponent, DbxFirebaseLoginContext, DbxFirebaseLoginContextBackButtonComponent, DbxFirebaseLoginContextDirective, DbxFirebaseLoginEmailComponent, DbxFirebaseLoginEmailContentComponent, DbxFirebaseLoginFacebookComponent, DbxFirebaseLoginGitHubComponent, DbxFirebaseLoginGoogleComponent, DbxFirebaseLoginListComponent, DbxFirebaseLoginMicrosoftComponent, DbxFirebaseLoginModule, DbxFirebaseLoginModuleRootConfig, DbxFirebaseLoginTermsComponent, DbxFirebaseLoginTermsSimpleComponent, DbxFirebaseLoginTwitterComponent, DbxFirebaseModelModule, DbxFirebaseModelStoreModule, DbxFirebaseModule, DbxFirebaseParsedEmulatorsConfig, DbxFirebaseRegisterComponent, DbxFirebaseRegisterEmailComponent, DbxFirestoreContextService, FIREBASE_AUTH_NETWORK_REQUEST_ERROR, FIREBASE_AUTH_USER_NOT_FOUND_ERROR, OAUTH_FIREBASE_LOGIN_METHOD_CATEGORY, authUserInfoFromAuthUser, authUserStateFromFirebaseAuthService, dbxFirebaseCollectionLoaderInstance, dbxFirebaseCollectionLoaderInstanceWithCollection, defaultFirebaseAuthLoginProvidersFactory, firebaseAuthErrorToReadableError, modelDoesNotExistError, provideDbxFirebaseCollectionStoreDirective, provideDbxFirebaseDocumentStoreDirective, readValueFromIdToken, setParentEffect, setParentStoreEffect };
|
|
2435
|
+
export { AbstractConfiguredDbxFirebaseLoginButtonDirective, AbstractDbxFirebaseCollectionStore, AbstractDbxFirebaseCollectionWithParentStore, AbstractDbxFirebaseDocumentStore, AbstractDbxFirebaseDocumentWithParentStore, DBX_FIREBASE_MODEL_DOES_NOT_EXIST_ERROR, DBX_FIREBASE_OPTIONS_TOKEN, DBX_FIREBASE_ROUTER_SYNC_DEFAULT_ID_PARAM_KEY, DBX_FIRESTORE_CONTEXT_TOKEN, DEFAULT_CONFIGURED_DBX_FIREBASE_LOGIN_BUTTON_TEMPLATE, DEFAULT_DBX_FIREBASE_AUTH_SERVICE_DELEGATE, DEFAULT_FIREBASE_AUTH_LOGIN_PASSWORD_CONFIG, DEFAULT_FIREBASE_AUTH_LOGIN_PASSWORD_CONFIG_TOKEN, DEFAULT_FIREBASE_AUTH_LOGIN_PROVIDERS_TOKEN, DEFAULT_FIREBASE_AUTH_LOGIN_TERMS_COMPONENT_CLASS_TOKEN, DEFAULT_FIREBASE_LOGIN_METHOD_CATEGORY, DbxFirebaseAppCheckHttpInterceptor, DbxFirebaseAuthLoginService, DbxFirebaseAuthModule, DbxFirebaseAuthService, DbxFirebaseAuthServiceDelegate, DbxFirebaseCollectionChangeDirective, DbxFirebaseCollectionHasChangeDirective, DbxFirebaseCollectionListDirective, DbxFirebaseCollectionLoaderInstance, DbxFirebaseCollectionStoreDirective, DbxFirebaseDefaultAppCheckProviderModule, DbxFirebaseDefaultAuthProviderModule, DbxFirebaseDefaultFirebaseProvidersModule, DbxFirebaseDefaultFirestoreProviderModule, DbxFirebaseDefaultFunctionsProviderModule, DbxFirebaseDefaultStorageProviderModule, DbxFirebaseDocumentAuthIdDirective, DbxFirebaseDocumentStoreDirective, DbxFirebaseDocumentStoreRouteIdDirective, DbxFirebaseEmailFormComponent, DbxFirebaseEmailRecoveryFormComponent, DbxFirebaseEmulatorModule, DbxFirebaseFirestoreCollectionModule, DbxFirebaseFunctionsModule, DbxFirebaseLoginAnonymousComponent, DbxFirebaseLoginAppleComponent, DbxFirebaseLoginButtonComponent, DbxFirebaseLoginButtonContainerComponent, DbxFirebaseLoginComponent, DbxFirebaseLoginContext, DbxFirebaseLoginContextBackButtonComponent, DbxFirebaseLoginContextDirective, DbxFirebaseLoginEmailComponent, DbxFirebaseLoginEmailContentComponent, DbxFirebaseLoginFacebookComponent, DbxFirebaseLoginGitHubComponent, DbxFirebaseLoginGoogleComponent, DbxFirebaseLoginListComponent, DbxFirebaseLoginMicrosoftComponent, DbxFirebaseLoginModule, DbxFirebaseLoginModuleRootConfig, DbxFirebaseLoginTermsComponent, DbxFirebaseLoginTermsSimpleComponent, DbxFirebaseLoginTwitterComponent, DbxFirebaseModelModule, DbxFirebaseModelStoreModule, DbxFirebaseModule, DbxFirebaseParsedEmulatorsConfig, DbxFirebaseRegisterComponent, DbxFirebaseRegisterEmailComponent, DbxFirestoreContextService, FIREBASE_AUTH_NETWORK_REQUEST_ERROR, FIREBASE_AUTH_USER_NOT_FOUND_ERROR, OAUTH_FIREBASE_LOGIN_METHOD_CATEGORY, authUserInfoFromAuthUser, authUserStateFromFirebaseAuthService, dbxFirebaseCollectionLoaderInstance, dbxFirebaseCollectionLoaderInstanceWithCollection, defaultFirebaseAuthLoginProvidersFactory, enableAppCheckDebugTokenGeneration, firebaseAuthErrorToReadableError, modelDoesNotExistError, provideDbxFirebaseCollectionStoreDirective, provideDbxFirebaseDocumentStoreDirective, readValueFromIdToken, setParentEffect, setParentStoreEffect };
|
|
2253
2436
|
//# sourceMappingURL=dereekb-dbx-firebase.mjs.map
|