@infrab4a/connect-angular 4.1.2-beta.0 → 4.1.2-beta.10

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.
@@ -1,21 +1,20 @@
1
1
  import * as i0 from '@angular/core';
2
2
  import { NgModule, InjectionToken, PLATFORM_ID, Injectable, Inject } from '@angular/core';
3
- import * as i1$3 from '@infrab4a/connect';
3
+ import * as i1$4 from '@angular/fire/app';
4
+ import { FirebaseApp, provideFirebaseApp, getApp, initializeApp } from '@angular/fire/app';
5
+ import * as i1$2 from '@infrab4a/connect';
4
6
  import { ProductsIndex, AxiosAdapter, Authentication, AuthenticationFirebaseAuthService, Register, RegisterFirebaseAuthService, SignOut, RecoveryPassword, UserBeautyProfileFirestoreRepository, Buy2WinFirestoreRepository, CategoryFirestoreRepository, CheckoutFirestoreRepository, CheckoutSubscriptionFirestoreRepository, CouponFirestoreRepository, CampaignHashtagFirestoreRepository, CampaignDashboardFirestoreRepository, SubscriptionEditionFirestoreRepository, HomeFirestoreRepository, LeadFirestoreRepository, LegacyOrderFirestoreRepository, ShopMenuFirestoreRepository, OrderFirestoreRepository, PaymentFirestoreRepository, ProductFirestoreRepository, ShopSettingsFirestoreRepository, SubscriptionPaymentFirestoreRepository, SubscriptionPlanFirestoreRepository, SubscriptionProductFirestoreRepository, SubscriptionFirestoreRepository, UserFirestoreRepository, UserAddressFirestoreRepository, UserPaymentMethodFirestoreRepository, ProductVariantFirestoreRepository, CategoryHasuraGraphQLRepository, ProductHasuraGraphQLRepository, CategoryFilterHasuraGraphQLRepository, VariantHasuraGraphQLRepository, FilterOptionHasuraGraphQLRepository, FilterHasuraGraphQLRepository, CategoryCollectionChildrenHasuraGraphQLRepository, WishlistHasuraGraphQLRepository, Where, Shops, CheckoutTypes, CouponTypes, Exclusivities, isNil, NotFoundError, Checkout, pick, LineItem, RoundProductPricesHelper, set, InvalidArgumentError, Category, CheckoutSubscription, Product, RequiredArgumentError, add, Order } from '@infrab4a/connect';
5
- import * as i1 from '@angular/fire/app';
6
- import { provideFirebaseApp, initializeApp, FirebaseApp } from '@angular/fire/app';
7
- import * as i1$1 from '@angular/fire/auth';
7
+ import * as i1 from '@angular/fire/auth';
8
8
  import { Auth, provideAuth, getAuth, getIdToken, authState } from '@angular/fire/auth';
9
9
  import { isPlatformBrowser } from '@angular/common';
10
- import * as i1$2 from '@angular/fire/firestore';
11
- import { Firestore, provideFirestore, getFirestore, initializeFirestore, enableIndexedDbPersistence, docSnapshots, doc } from '@angular/fire/firestore';
12
- import { initializeApp as initializeApp$1 } from 'firebase/app';
10
+ import * as i1$1 from '@angular/fire/firestore';
11
+ import { Firestore, provideFirestore, getFirestore, initializeFirestore, memoryLocalCache, docSnapshots, doc } from '@angular/fire/firestore';
13
12
  import { combineLatest, from, of, throwError, Subject, iif, forkJoin } from 'rxjs';
14
13
  import { map, mergeMap, catchError, concatMap, tap } from 'rxjs/operators';
15
14
  import cookie from 'js-cookie';
16
15
  import { __decorate, __metadata } from 'tslib';
17
16
  import { Type } from 'class-transformer';
18
- import * as i1$4 from '@angular/common/http';
17
+ import * as i1$3 from '@angular/common/http';
19
18
 
20
19
  const ES_CONFIG = 'ES_CONFIG';
21
20
 
@@ -72,7 +71,7 @@ class AngularFirebaseAuthModule {
72
71
  }
73
72
  }
74
73
  AngularFirebaseAuthModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: AngularFirebaseAuthModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
75
- AngularFirebaseAuthModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.1.0", ngImport: i0, type: AngularFirebaseAuthModule, imports: [i1.FirebaseAppModule, i1$1.AuthModule] });
74
+ AngularFirebaseAuthModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.1.0", ngImport: i0, type: AngularFirebaseAuthModule, imports: [i1.AuthModule] });
76
75
  AngularFirebaseAuthModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: AngularFirebaseAuthModule, providers: [
77
76
  {
78
77
  provide: 'Authentication',
@@ -116,25 +115,11 @@ AngularFirebaseAuthModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0
116
115
  },
117
116
  deps: ['AuthenticationService'],
118
117
  },
119
- ], imports: [provideFirebaseApp((injector) => {
120
- const appName = injector.get(FIREBASE_APP_NAME);
121
- return appName
122
- ? initializeApp(injector.get(FIREBASE_OPTIONS), `${appName}-auth`)
123
- : initializeApp(injector.get(FIREBASE_OPTIONS));
124
- }),
125
- provideAuth(() => getAuth())] });
118
+ ], imports: [provideAuth((injector) => getAuth(injector.get(FirebaseApp)))] });
126
119
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: AngularFirebaseAuthModule, decorators: [{
127
120
  type: NgModule,
128
121
  args: [{
129
- imports: [
130
- provideFirebaseApp((injector) => {
131
- const appName = injector.get(FIREBASE_APP_NAME);
132
- return appName
133
- ? initializeApp(injector.get(FIREBASE_OPTIONS), `${appName}-auth`)
134
- : initializeApp(injector.get(FIREBASE_OPTIONS));
135
- }),
136
- provideAuth(() => getAuth()),
137
- ],
122
+ imports: [provideAuth((injector) => getAuth(injector.get(FirebaseApp)))],
138
123
  providers: [
139
124
  {
140
125
  provide: 'Authentication',
@@ -202,7 +187,7 @@ class AngularFirestoreModule {
202
187
  }
203
188
  }
204
189
  AngularFirestoreModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: AngularFirestoreModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
205
- AngularFirestoreModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.1.0", ngImport: i0, type: AngularFirestoreModule, imports: [AngularElasticSeachModule, i1.FirebaseAppModule, i1$2.FirestoreModule] });
190
+ AngularFirestoreModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.1.0", ngImport: i0, type: AngularFirestoreModule, imports: [AngularElasticSeachModule, i1$1.FirestoreModule] });
206
191
  AngularFirestoreModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: AngularFirestoreModule, providers: [
207
192
  {
208
193
  provide: 'FirestoreOptions',
@@ -402,36 +387,26 @@ AngularFirestoreModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0",
402
387
  deps: ['FirestoreOptions', ProductFirestoreRepository],
403
388
  },
404
389
  ], imports: [AngularElasticSeachModule,
405
- provideFirebaseApp((injector) => {
406
- const appName = injector.get(FIREBASE_APP_NAME);
407
- return appName
408
- ? initializeApp$1(injector.get(FIREBASE_OPTIONS), `${appName}-firestore`)
409
- : initializeApp$1(injector.get(FIREBASE_OPTIONS));
410
- }),
411
390
  provideFirestore((injector) => {
412
391
  if (!MobileOperationSystemCheckerHelper.isAppleDevice())
413
- return getFirestore();
414
- const firestore = initializeFirestore(injector.get(FirebaseApp), { experimentalForceLongPolling: true });
415
- enableIndexedDbPersistence(firestore).catch(console.error);
416
- return firestore;
392
+ return getFirestore(injector.get(FirebaseApp));
393
+ return initializeFirestore(injector.get(FirebaseApp), {
394
+ experimentalForceLongPolling: true,
395
+ localCache: memoryLocalCache(),
396
+ });
417
397
  })] });
418
398
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: AngularFirestoreModule, decorators: [{
419
399
  type: NgModule,
420
400
  args: [{
421
401
  imports: [
422
402
  AngularElasticSeachModule,
423
- provideFirebaseApp((injector) => {
424
- const appName = injector.get(FIREBASE_APP_NAME);
425
- return appName
426
- ? initializeApp$1(injector.get(FIREBASE_OPTIONS), `${appName}-firestore`)
427
- : initializeApp$1(injector.get(FIREBASE_OPTIONS));
428
- }),
429
403
  provideFirestore((injector) => {
430
404
  if (!MobileOperationSystemCheckerHelper.isAppleDevice())
431
- return getFirestore();
432
- const firestore = initializeFirestore(injector.get(FirebaseApp), { experimentalForceLongPolling: true });
433
- enableIndexedDbPersistence(firestore).catch(console.error);
434
- return firestore;
405
+ return getFirestore(injector.get(FirebaseApp));
406
+ return initializeFirestore(injector.get(FirebaseApp), {
407
+ experimentalForceLongPolling: true,
408
+ localCache: memoryLocalCache(),
409
+ });
435
410
  }),
436
411
  ],
437
412
  providers: [
@@ -896,11 +871,11 @@ class AuthService {
896
871
  return authState(this.angularFireAuth).pipe(catchError(() => of(null)));
897
872
  }
898
873
  }
899
- AuthService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: AuthService, deps: [{ token: i1$1.Auth }, { token: 'UserRepository' }], target: i0.ɵɵFactoryTarget.Injectable });
874
+ AuthService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: AuthService, deps: [{ token: i1.Auth }, { token: 'UserRepository' }], target: i0.ɵɵFactoryTarget.Injectable });
900
875
  AuthService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: AuthService });
901
876
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: AuthService, decorators: [{
902
877
  type: Injectable
903
- }], ctorParameters: function () { return [{ type: i1$1.Auth }, { type: undefined, decorators: [{
878
+ }], ctorParameters: function () { return [{ type: i1.Auth }, { type: undefined, decorators: [{
904
879
  type: Inject,
905
880
  args: ['UserRepository']
906
881
  }] }]; } });
@@ -1105,7 +1080,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImpor
1105
1080
  }], ctorParameters: function () { return [{ type: undefined, decorators: [{
1106
1081
  type: Inject,
1107
1082
  args: ['CouponRepository']
1108
- }] }, { type: i1$3.Shops, decorators: [{
1083
+ }] }, { type: i1$2.Shops, decorators: [{
1109
1084
  type: Inject,
1110
1085
  args: [DEFAULT_SHOP]
1111
1086
  }] }, { type: undefined, decorators: [{
@@ -1172,7 +1147,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImpor
1172
1147
  }] }, { type: undefined, decorators: [{
1173
1148
  type: Inject,
1174
1149
  args: ['UserRepository']
1175
- }] }, { type: i1$3.Shops, decorators: [{
1150
+ }] }, { type: i1$2.Shops, decorators: [{
1176
1151
  type: Inject,
1177
1152
  args: [DEFAULT_SHOP]
1178
1153
  }] }]; } });
@@ -1430,7 +1405,7 @@ CartService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15
1430
1405
  CartService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: CartService });
1431
1406
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: CartService, decorators: [{
1432
1407
  type: Injectable
1433
- }], ctorParameters: function () { return [{ type: AuthService }, { type: CheckoutService }, { type: i1$3.Shops, decorators: [{
1408
+ }], ctorParameters: function () { return [{ type: AuthService }, { type: CheckoutService }, { type: i1$2.Shops, decorators: [{
1434
1409
  type: Inject,
1435
1410
  args: [DEFAULT_SHOP]
1436
1411
  }] }, { type: undefined, decorators: [{
@@ -1442,7 +1417,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImpor
1442
1417
  }] }, { type: undefined, decorators: [{
1443
1418
  type: Inject,
1444
1419
  args: ['VariantRepository']
1445
- }] }, { type: i1$3.Buy2WinFirestoreRepository, decorators: [{
1420
+ }] }, { type: i1$2.Buy2WinFirestoreRepository, decorators: [{
1446
1421
  type: Inject,
1447
1422
  args: ['Buy2WinRepository']
1448
1423
  }] }]; } });
@@ -1551,7 +1526,7 @@ class CatalogService {
1551
1526
  .then((data) => ({ id: { operator: Where.IN, value: data.hits.map(({ _source }) => _source.id) } }));
1552
1527
  }
1553
1528
  }
1554
- CatalogService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: CatalogService, deps: [{ token: 'ProductRepository' }, { token: CATEGORY_STRUCTURE }, { token: DEFAULT_SHOP }, { token: i1$3.ProductsIndex }], target: i0.ɵɵFactoryTarget.Injectable });
1529
+ CatalogService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: CatalogService, deps: [{ token: 'ProductRepository' }, { token: CATEGORY_STRUCTURE }, { token: DEFAULT_SHOP }, { token: i1$2.ProductsIndex }], target: i0.ɵɵFactoryTarget.Injectable });
1555
1530
  CatalogService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: CatalogService });
1556
1531
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: CatalogService, decorators: [{
1557
1532
  type: Injectable
@@ -1561,10 +1536,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImpor
1561
1536
  }] }, { type: undefined, decorators: [{
1562
1537
  type: Inject,
1563
1538
  args: [CATEGORY_STRUCTURE]
1564
- }] }, { type: i1$3.Shops, decorators: [{
1539
+ }] }, { type: i1$2.Shops, decorators: [{
1565
1540
  type: Inject,
1566
1541
  args: [DEFAULT_SHOP]
1567
- }] }, { type: i1$3.ProductsIndex }]; } });
1542
+ }] }, { type: i1$2.ProductsIndex }]; } });
1568
1543
 
1569
1544
  class CategoryService {
1570
1545
  constructor(productRepository, categoryRepository, categoryFilterRepository, categoryStructureAdapter, shop) {
@@ -1607,7 +1582,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImpor
1607
1582
  }] }, { type: undefined, decorators: [{
1608
1583
  type: Inject,
1609
1584
  args: [CATEGORY_STRUCTURE]
1610
- }] }, { type: i1$3.Shops, decorators: [{
1585
+ }] }, { type: i1$2.Shops, decorators: [{
1611
1586
  type: Inject,
1612
1587
  args: [DEFAULT_SHOP]
1613
1588
  }] }]; } });
@@ -1769,14 +1744,14 @@ class WishlistService {
1769
1744
  return wishlist;
1770
1745
  }
1771
1746
  }
1772
- WishlistService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: WishlistService, deps: [{ token: 'WishlistRepository' }, { token: DEFAULT_SHOP }, { token: 'ProductRepository' }, { token: 'CategoryFilterRepository' }, { token: i1$3.ProductsIndex }], target: i0.ɵɵFactoryTarget.Injectable });
1747
+ WishlistService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: WishlistService, deps: [{ token: 'WishlistRepository' }, { token: DEFAULT_SHOP }, { token: 'ProductRepository' }, { token: 'CategoryFilterRepository' }, { token: i1$2.ProductsIndex }], target: i0.ɵɵFactoryTarget.Injectable });
1773
1748
  WishlistService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: WishlistService });
1774
1749
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: WishlistService, decorators: [{
1775
1750
  type: Injectable
1776
1751
  }], ctorParameters: function () { return [{ type: undefined, decorators: [{
1777
1752
  type: Inject,
1778
1753
  args: ['WishlistRepository']
1779
- }] }, { type: i1$3.Shops, decorators: [{
1754
+ }] }, { type: i1$2.Shops, decorators: [{
1780
1755
  type: Inject,
1781
1756
  args: [DEFAULT_SHOP]
1782
1757
  }] }, { type: undefined, decorators: [{
@@ -1785,7 +1760,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImpor
1785
1760
  }] }, { type: undefined, decorators: [{
1786
1761
  type: Inject,
1787
1762
  args: ['CategoryFilterRepository']
1788
- }] }, { type: i1$3.ProductsIndex }]; } });
1763
+ }] }, { type: i1$2.ProductsIndex }]; } });
1789
1764
 
1790
1765
  class CheckoutSubscriptionService {
1791
1766
  constructor(checkoutSubscriptionRepository, subscriptionRepository, couponService) {
@@ -1952,7 +1927,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImpor
1952
1927
  }] }, { type: undefined, decorators: [{
1953
1928
  type: Inject,
1954
1929
  args: ['ProductRepository']
1955
- }] }, { type: i1$3.Shops, decorators: [{
1930
+ }] }, { type: i1$2.Shops, decorators: [{
1956
1931
  type: Inject,
1957
1932
  args: [DEFAULT_SHOP]
1958
1933
  }] }]; } });
@@ -1970,11 +1945,11 @@ class OrderService {
1970
1945
  return this.orderSubject;
1971
1946
  }
1972
1947
  }
1973
- OrderService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: OrderService, deps: [{ token: i1$2.Firestore }, { token: 'OrderRepository' }], target: i0.ɵɵFactoryTarget.Injectable });
1948
+ OrderService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: OrderService, deps: [{ token: i1$1.Firestore }, { token: 'OrderRepository' }], target: i0.ɵɵFactoryTarget.Injectable });
1974
1949
  OrderService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: OrderService });
1975
1950
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: OrderService, decorators: [{
1976
1951
  type: Injectable
1977
- }], ctorParameters: function () { return [{ type: i1$2.Firestore }, { type: i1$3.OrderFirestoreRepository, decorators: [{
1952
+ }], ctorParameters: function () { return [{ type: i1$1.Firestore }, { type: i1$2.OrderFirestoreRepository, decorators: [{
1978
1953
  type: Inject,
1979
1954
  args: ['OrderRepository']
1980
1955
  }] }]; } });
@@ -2056,11 +2031,11 @@ class ShippingService {
2056
2031
  return false;
2057
2032
  }
2058
2033
  }
2059
- ShippingService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: ShippingService, deps: [{ token: i1$4.HttpClient }, { token: BACKEND_URL }, { token: HomeShopService }], target: i0.ɵɵFactoryTarget.Injectable });
2034
+ ShippingService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: ShippingService, deps: [{ token: i1$3.HttpClient }, { token: BACKEND_URL }, { token: HomeShopService }], target: i0.ɵɵFactoryTarget.Injectable });
2060
2035
  ShippingService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: ShippingService });
2061
2036
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: ShippingService, decorators: [{
2062
2037
  type: Injectable
2063
- }], ctorParameters: function () { return [{ type: i1$4.HttpClient }, { type: undefined, decorators: [{
2038
+ }], ctorParameters: function () { return [{ type: i1$3.HttpClient }, { type: undefined, decorators: [{
2064
2039
  type: Inject,
2065
2040
  args: [BACKEND_URL]
2066
2041
  }] }, { type: HomeShopService }]; } });
@@ -2087,7 +2062,10 @@ class AngularConnectModule {
2087
2062
  }
2088
2063
  }
2089
2064
  AngularConnectModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: AngularConnectModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2090
- AngularConnectModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.1.0", ngImport: i0, type: AngularConnectModule, imports: [AngularElasticSeachModule, AngularFirebaseAuthModule, AngularFirestoreModule, AngularHasuraGraphQLModule] });
2065
+ AngularConnectModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.1.0", ngImport: i0, type: AngularConnectModule, imports: [i1$4.FirebaseAppModule, AngularElasticSeachModule,
2066
+ AngularFirebaseAuthModule,
2067
+ AngularFirestoreModule,
2068
+ AngularHasuraGraphQLModule] });
2091
2069
  AngularConnectModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: AngularConnectModule, providers: [
2092
2070
  AuthService,
2093
2071
  CartService,
@@ -2100,11 +2078,45 @@ AngularConnectModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", ve
2100
2078
  OrderService,
2101
2079
  ShippingService,
2102
2080
  WishlistService,
2103
- ], imports: [AngularElasticSeachModule, AngularFirebaseAuthModule, AngularFirestoreModule, AngularHasuraGraphQLModule] });
2081
+ ], imports: [provideFirebaseApp((injector) => {
2082
+ const appName = injector.get(FIREBASE_APP_NAME) || '[DEFAULT]';
2083
+ console.log('fire', appName);
2084
+ console.log('options', FIREBASE_OPTIONS);
2085
+ console.log('fire', getApp);
2086
+ try {
2087
+ return getApp(appName);
2088
+ }
2089
+ catch (error) {
2090
+ console.log('initializeApp', error instanceof Error && error.message);
2091
+ return initializeApp(injector.get(FIREBASE_OPTIONS), appName);
2092
+ }
2093
+ }),
2094
+ AngularElasticSeachModule,
2095
+ AngularFirebaseAuthModule,
2096
+ AngularFirestoreModule,
2097
+ AngularHasuraGraphQLModule] });
2104
2098
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: AngularConnectModule, decorators: [{
2105
2099
  type: NgModule,
2106
2100
  args: [{
2107
- imports: [AngularElasticSeachModule, AngularFirebaseAuthModule, AngularFirestoreModule, AngularHasuraGraphQLModule],
2101
+ imports: [
2102
+ provideFirebaseApp((injector) => {
2103
+ const appName = injector.get(FIREBASE_APP_NAME) || '[DEFAULT]';
2104
+ console.log('fire', appName);
2105
+ console.log('options', FIREBASE_OPTIONS);
2106
+ console.log('fire', getApp);
2107
+ try {
2108
+ return getApp(appName);
2109
+ }
2110
+ catch (error) {
2111
+ console.log('initializeApp', error instanceof Error && error.message);
2112
+ return initializeApp(injector.get(FIREBASE_OPTIONS), appName);
2113
+ }
2114
+ }),
2115
+ AngularElasticSeachModule,
2116
+ AngularFirebaseAuthModule,
2117
+ AngularFirestoreModule,
2118
+ AngularHasuraGraphQLModule,
2119
+ ],
2108
2120
  providers: [
2109
2121
  AuthService,
2110
2122
  CartService,