@dereekb/dbx-firebase 13.11.1 → 13.11.3

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.
@@ -140,6 +140,7 @@ function firebaseAuthTokenFromUser(user) {
140
140
  *
141
141
  * @param stateForLoggedInUser Optional function that returns an observable for the user's state if they are logged in and not an anonymous user.
142
142
  * @returns
143
+ * @__NO_SIDE_EFFECTS__
143
144
  */
144
145
  function authUserStateFromFirebaseAuthServiceFunction(stateForLoggedInUser = () => of('user')) {
145
146
  return (dbxFirebaseAuthService) => {
@@ -161,6 +162,7 @@ function authUserStateFromFirebaseAuthServiceFunction(stateForLoggedInUser = ()
161
162
  * @param stateFromToken - Function that maps an IdTokenResult to an AuthUserState.
162
163
  * @param defaultState - The fallback state when no token is available. Defaults to 'user'.
163
164
  * @returns An AuthUserStateObsFunction that reads state from the ID token.
165
+ * @__NO_SIDE_EFFECTS__
164
166
  */
165
167
  function stateFromTokenForLoggedInUserFunction(stateFromToken, defaultState = 'user') {
166
168
  return (dbxFirebaseAuthService) => {
@@ -558,6 +560,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
558
560
  * Creates a EnvironmentProviders that provides a DbxFirebaseAnalyticsUserEventsListenerService and initialize it when the app is initialized.
559
561
  *
560
562
  * @returns EnvironmentProviders
563
+ * @__NO_SIDE_EFFECTS__
561
564
  */
562
565
  function provideDbxFirebaseAnalyticsUserEventsListenerService() {
563
566
  const providers = [
@@ -1488,6 +1491,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
1488
1491
  * Factory function for creating the default Firebase auth login providers.
1489
1492
  *
1490
1493
  * @returns Array of DbxFirebaseAuthLoginProvider
1494
+ * @__NO_SIDE_EFFECTS__
1491
1495
  */
1492
1496
  function defaultFirebaseAuthLoginProvidersFactory() {
1493
1497
  // Brand logos from @firebase-oss/ui-core via jsdelivr CDN.
@@ -2048,6 +2052,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
2048
2052
  *
2049
2053
  * @param config - Configuration specifying the claims service and optional auth user state inclusion.
2050
2054
  * @returns A function that, given a DbxFirebaseAuthService, returns an Observable of the decoded AuthRoleSet.
2055
+ * @__NO_SIDE_EFFECTS__
2051
2056
  */
2052
2057
  function authRolesObsWithClaimsService(config) {
2053
2058
  const { addAuthUserStateToRoles: addAuthUserState, claimsService } = config;
@@ -2066,6 +2071,7 @@ function authRolesObsWithClaimsService(config) {
2066
2071
  *
2067
2072
  * @param config - Configuration with the claims service and optional auth state customization.
2068
2073
  * @returns A DbxFirebaseAuthServiceDelegate configured for claims-based auth.
2074
+ * @__NO_SIDE_EFFECTS__
2069
2075
  */
2070
2076
  function defaultDbxFirebaseAuthServiceDelegateWithClaimsService(config) {
2071
2077
  if (filterMaybeArrayValues([config.stateForLoggedInUser, config.stateForLoggedInUserToken, config.authUserStateObs]).length > 1) {
@@ -2788,6 +2794,7 @@ function parseDbxFirebaseEmulatorsConfig(config) {
2788
2794
  * ```ts
2789
2795
  * const appCheck = createDbxFirebaseAppCheck({ app, options });
2790
2796
  * ```
2797
+ * @__NO_SIDE_EFFECTS__
2791
2798
  */
2792
2799
  function createDbxFirebaseAppCheck(params) {
2793
2800
  const { app, options } = params;
@@ -2819,6 +2826,7 @@ function createDbxFirebaseAppCheck(params) {
2819
2826
  * ```ts
2820
2827
  * const firestore = createDbxFirebaseFirestore({ app, options, emulators });
2821
2828
  * ```
2829
+ * @__NO_SIDE_EFFECTS__
2822
2830
  */
2823
2831
  function createDbxFirebaseFirestore(params) {
2824
2832
  const { app, options, emulators } = params;
@@ -2847,6 +2855,7 @@ function createDbxFirebaseFirestore(params) {
2847
2855
  * ```ts
2848
2856
  * const auth = createDbxFirebaseAuth({ app, emulators });
2849
2857
  * ```
2858
+ * @__NO_SIDE_EFFECTS__
2850
2859
  */
2851
2860
  function createDbxFirebaseAuth(params) {
2852
2861
  const { app, emulators } = params;
@@ -2866,6 +2875,7 @@ function createDbxFirebaseAuth(params) {
2866
2875
  * ```ts
2867
2876
  * const storage = createDbxFirebaseStorage({ app, emulators });
2868
2877
  * ```
2878
+ * @__NO_SIDE_EFFECTS__
2869
2879
  */
2870
2880
  function createDbxFirebaseStorage(params) {
2871
2881
  const { app, emulators } = params;
@@ -2885,6 +2895,7 @@ function createDbxFirebaseStorage(params) {
2885
2895
  * ```ts
2886
2896
  * const functions = createDbxFirebaseFunctions({ app, options, emulators });
2887
2897
  * ```
2898
+ * @__NO_SIDE_EFFECTS__
2888
2899
  */
2889
2900
  function createDbxFirebaseFunctions(params) {
2890
2901
  const { app, options, emulators } = params;
@@ -3005,6 +3016,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
3005
3016
  *
3006
3017
  * @param config Configuration for provideDbxFirebaseFunctions().
3007
3018
  * @returns EnvironmentProviders for the LazyFirebaseFunctions type.
3019
+ * @__NO_SIDE_EFFECTS__
3008
3020
  */
3009
3021
  function provideDbxFirebaseFunctions(config) {
3010
3022
  const providers = [
@@ -3504,6 +3516,7 @@ function dbxFirebaseDocumentLoaderInstanceWithAccessor(accessor) {
3504
3516
  *
3505
3517
  * @param context$ - Observable of the in-context Firebase models service.
3506
3518
  * @returns A factory function for creating model service instances by type and key.
3519
+ * @__NO_SIDE_EFFECTS__
3507
3520
  */
3508
3521
  function dbxFirebaseInContextFirebaseModelServiceInstanceFactory(context$) {
3509
3522
  return (type, keyObs) => {
@@ -3589,6 +3602,7 @@ class DbxFirebaseModelContextService {
3589
3602
  *
3590
3603
  * @param config - Configuration providing the model service factory and entity map observable.
3591
3604
  * @returns A factory function that creates model info instances from observable model keys.
3605
+ * @__NO_SIDE_EFFECTS__
3592
3606
  */
3593
3607
  function dbxFirebaseModelContextServiceInfoInstanceFactory(config) {
3594
3608
  const { modelService, entityMap$ } = config;
@@ -3625,6 +3639,7 @@ function firebaseContextServiceEntityMap() {
3625
3639
  *
3626
3640
  * @param config Configuration
3627
3641
  * @returns EnvironmentProviders
3642
+ * @__NO_SIDE_EFFECTS__
3628
3643
  */
3629
3644
  function provideDbxFirebaseModelContextService(config) {
3630
3645
  const { dbxFirebaseModelContextServiceClass, dbxFirebaseModelContextServiceFactory } = config;
@@ -3722,6 +3737,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
3722
3737
  *
3723
3738
  * @param service - The model types service used to resolve type info and instances.
3724
3739
  * @returns A factory that accepts model keys and returns an Observable of instance pairs with display info and segue refs.
3740
+ * @__NO_SIDE_EFFECTS__
3725
3741
  */
3726
3742
  function dbxFirebaseModelTypesServiceInstancePairForKeysFactory(service) {
3727
3743
  return (keys) => {
@@ -4102,6 +4118,7 @@ const DBX_FIREBASE_MODEL_ENTITY_WITH_STORE_TOKEN = new InjectionToken('DbxFireba
4102
4118
  *
4103
4119
  * @param injector Optional injector to use for the components.
4104
4120
  * @returns
4121
+ * @__NO_SIDE_EFFECTS__
4105
4122
  */
4106
4123
  function dbxFirebaseModelEntityWidgetInjectionConfigFactory(injector) {
4107
4124
  return (entry, entity) => {
@@ -4417,6 +4434,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
4417
4434
  *
4418
4435
  * @param config Configuration
4419
4436
  * @returns EnvironmentProviders
4437
+ * @__NO_SIDE_EFFECTS__
4420
4438
  */
4421
4439
  function provideDbxFirebaseModelEntitiesWidgetService(config) {
4422
4440
  const { dbxFirebaseModelEntitiesWidgetServiceConfigFactory } = config;
@@ -5119,6 +5137,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
5119
5137
  * @param store
5120
5138
  * @param fn
5121
5139
  * @returns
5140
+ * @__NO_SIDE_EFFECTS__
5122
5141
  */
5123
5142
  function firebaseCollectionStoreCreateFunction(store, fn) {
5124
5143
  return (params) => loadingStateFromObs(lazyFrom(() => fn(params).then((result) => {
@@ -5133,6 +5152,7 @@ function firebaseCollectionStoreCreateFunction(store, fn) {
5133
5152
  *
5134
5153
  * @param fn
5135
5154
  * @returns
5155
+ * @__NO_SIDE_EFFECTS__
5136
5156
  */
5137
5157
  function firebaseCollectionStoreCrudFunction(fn) {
5138
5158
  return (params) => loadingStateFromObs(from(fn(params)).pipe(shareReplay(1)));
@@ -5373,6 +5393,7 @@ AbstractRootSingleItemDbxFirebaseDocument = __decorate([
5373
5393
  * @param fn - The Firebase create function to wrap.
5374
5394
  * @param config - Optional config with an `onResult` callback.
5375
5395
  * @returns A function that executes the create and sets the resulting key on the store.
5396
+ * @__NO_SIDE_EFFECTS__
5376
5397
  */
5377
5398
  function firebaseDocumentStoreCreateFunction(store, fn, config) {
5378
5399
  return (params) => loadingStateFromObs(lazyFrom(() => fn(params).then((result) => {
@@ -5390,6 +5411,7 @@ function firebaseDocumentStoreCreateFunction(store, fn, config) {
5390
5411
  *
5391
5412
  * @param fn
5392
5413
  * @returns
5414
+ * @__NO_SIDE_EFFECTS__
5393
5415
  */
5394
5416
  function firebaseDocumentStoreCrudFunction(fn) {
5395
5417
  return (params) => loadingStateFromObs(from(fn(params)).pipe(shareReplay(1)));
@@ -5405,6 +5427,7 @@ function firebaseDocumentStoreCrudFunction(fn) {
5405
5427
  * @param store
5406
5428
  * @param fn
5407
5429
  * @returns
5430
+ * @__NO_SIDE_EFFECTS__
5408
5431
  */
5409
5432
  function firebaseDocumentStoreReadFunction(store, fn) {
5410
5433
  return firebaseDocumentStoreUpdateFunction(store, fn);
@@ -5419,6 +5442,7 @@ function firebaseDocumentStoreReadFunction(store, fn) {
5419
5442
  * @param fn - The Firebase update function to wrap.
5420
5443
  * @param config - Optional config with an `onResult` callback.
5421
5444
  * @returns A function that executes the update with the store's key injected.
5445
+ * @__NO_SIDE_EFFECTS__
5422
5446
  */
5423
5447
  function firebaseDocumentStoreUpdateFunction(store, fn, config) {
5424
5448
  return (params) => loadingStateFromObs(store.key$.pipe(first(), exhaustMap((key) => fn({
@@ -5438,6 +5462,7 @@ function firebaseDocumentStoreUpdateFunction(store, fn, config) {
5438
5462
  * @param store
5439
5463
  * @param fn
5440
5464
  * @returns
5465
+ * @__NO_SIDE_EFFECTS__
5441
5466
  */
5442
5467
  function firebaseDocumentStoreDeleteFunction(store, fn) {
5443
5468
  return (params) => loadingStateFromObs(store.key$.pipe(first(), exhaustMap((key) => fn({
@@ -7695,6 +7720,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
7695
7720
  *
7696
7721
  * @param storageAccessorFactory - The factory used to create prefixed storage accessors.
7697
7722
  * @returns A StorageAccessor scoped to the storage file download cache.
7723
+ * @__NO_SIDE_EFFECTS__
7698
7724
  */
7699
7725
  function defaultDbxFirebaseStorageFileDownloadStorageAccessorFactory(storageAccessorFactory) {
7700
7726
  return storageAccessorFactory.createStorageAccessor({
@@ -7705,6 +7731,7 @@ function defaultDbxFirebaseStorageFileDownloadStorageAccessorFactory(storageAcce
7705
7731
  * Creates EnvironmentProviders for the storage file download service and its dependencies.
7706
7732
  *
7707
7733
  * @returns EnvironmentProviders that register the storage file download storage accessor, storage, and service.
7734
+ * @__NO_SIDE_EFFECTS__
7708
7735
  */
7709
7736
  function provideDbxFirebaseStorageFileService() {
7710
7737
  const providers = [
@@ -7880,6 +7907,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
7880
7907
  *
7881
7908
  * @param base Optional base configuration to use.
7882
7909
  * @returns Factory function for the DbxFirebaseStorageContext.
7910
+ * @__NO_SIDE_EFFECTS__
7883
7911
  */
7884
7912
  function dbxFirebaseStorageProvidersContextConfigFactory(base) {
7885
7913
  return (app) => {
@@ -7930,6 +7958,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
7930
7958
  *
7931
7959
  * @param config Configuration
7932
7960
  * @returns EnvironmentProviders
7961
+ * @__NO_SIDE_EFFECTS__
7933
7962
  */
7934
7963
  function provideDbxFirebaseModelTypesService(config) {
7935
7964
  const { dbxFirebaseModelTypesServiceConfigFactory } = config;