@xxmachina/common 20.67.0 → 20.73.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.
Files changed (45) hide show
  1. package/fesm2022/xxmachina-common-_shared-meta-redis.mjs +3 -3
  2. package/fesm2022/xxmachina-common-auth-core.mjs +3 -3
  3. package/fesm2022/xxmachina-common-auth.mjs +3 -3
  4. package/fesm2022/xxmachina-common-infra-external-quick-js.mjs +5 -5
  5. package/fesm2022/xxmachina-common-infra-external.mjs +3 -3
  6. package/fesm2022/xxmachina-common-infra-query-firestore.mjs +6 -6
  7. package/fesm2022/xxmachina-common-infra-query-hasura.mjs +3 -3
  8. package/fesm2022/xxmachina-common-infra-repository-firestore.mjs +9 -9
  9. package/fesm2022/xxmachina-common-infra-repository-hasura.mjs +6 -6
  10. package/fesm2022/xxmachina-common-infra-repository-notion.mjs +15 -15
  11. package/fesm2022/xxmachina-common-infra.mjs +48 -48
  12. package/fesm2022/xxmachina-common-invoice-usecase-contract.mjs +3 -3
  13. package/fesm2022/xxmachina-common-invoice-usecase-invoice.mjs +3 -3
  14. package/fesm2022/xxmachina-common-invoice-usecase-order.mjs +3 -3
  15. package/fesm2022/xxmachina-common-invoice-usecase-partner.mjs +3 -3
  16. package/fesm2022/xxmachina-common-services-device-profile.mjs +4 -4
  17. package/fesm2022/xxmachina-common-services-graphql.mjs +9 -9
  18. package/fesm2022/xxmachina-common-services-query-config.mjs +3 -3
  19. package/fesm2022/xxmachina-common-services-query.mjs +6 -6
  20. package/fesm2022/xxmachina-common-services-speech.mjs +10 -10
  21. package/fesm2022/xxmachina-common-services-transformer.mjs +3 -3
  22. package/fesm2022/xxmachina-common-stores-inmemory.mjs +3 -3
  23. package/fesm2022/xxmachina-common-usecase-assistant.mjs +3 -3
  24. package/fesm2022/xxmachina-common-usecase-database.mjs +3 -3
  25. package/fesm2022/xxmachina-common-usecase-graphql.mjs +3 -3
  26. package/fesm2022/xxmachina-common-usecase-project.mjs +3 -3
  27. package/fesm2022/xxmachina-common-usecase-spec.mjs +3 -3
  28. package/fesm2022/xxmachina-common-usecase.mjs +15 -15
  29. package/package.json +12 -44
  30. package/fesm2022/xxmachina-common-_shared-auth.mjs +0 -24
  31. package/fesm2022/xxmachina-common-_shared-meta.mjs +0 -24
  32. package/fesm2022/xxmachina-common-auth-azure.mjs +0 -159
  33. package/fesm2022/xxmachina-common-auth-passports-anonymous.mjs +0 -19
  34. package/fesm2022/xxmachina-common-auth-passports-firebase.mjs +0 -40
  35. package/fesm2022/xxmachina-common-auth-passports-internal.mjs +0 -33
  36. package/fesm2022/xxmachina-common-auth-passports-msal.mjs +0 -48
  37. package/fesm2022/xxmachina-common-auth-passports.mjs +0 -112
  38. package/types/xxmachina-common-_shared-auth.d.ts +0 -8
  39. package/types/xxmachina-common-_shared-meta.d.ts +0 -8
  40. package/types/xxmachina-common-auth-azure.d.ts +0 -41
  41. package/types/xxmachina-common-auth-passports-anonymous.d.ts +0 -8
  42. package/types/xxmachina-common-auth-passports-firebase.d.ts +0 -19
  43. package/types/xxmachina-common-auth-passports-internal.d.ts +0 -17
  44. package/types/xxmachina-common-auth-passports-msal.d.ts +0 -26
  45. package/types/xxmachina-common-auth-passports.d.ts +0 -60
@@ -43,10 +43,10 @@ class GraphqlService {
43
43
  fetchPolicy: 'network-only',
44
44
  })));
45
45
  }
46
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: GraphqlService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
47
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: GraphqlService, providedIn: 'root' });
46
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: GraphqlService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
47
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: GraphqlService, providedIn: 'root' });
48
48
  }
49
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: GraphqlService, decorators: [{
49
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: GraphqlService, decorators: [{
50
50
  type: Injectable,
51
51
  args: [{ providedIn: 'root' }]
52
52
  }] });
@@ -137,10 +137,10 @@ class AstSubscriptionSplitterService {
137
137
  return combined;
138
138
  }));
139
139
  }
140
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: AstSubscriptionSplitterService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
141
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: AstSubscriptionSplitterService, providedIn: 'root' });
140
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: AstSubscriptionSplitterService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
141
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: AstSubscriptionSplitterService, providedIn: 'root' });
142
142
  }
143
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: AstSubscriptionSplitterService, decorators: [{
143
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: AstSubscriptionSplitterService, decorators: [{
144
144
  type: Injectable,
145
145
  args: [{ providedIn: 'root' }]
146
146
  }] });
@@ -220,10 +220,10 @@ class GraphqlEnhancedService extends GraphqlService {
220
220
  };
221
221
  }));
222
222
  }
223
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: GraphqlEnhancedService, deps: null, target: i0.ɵɵFactoryTarget.Injectable });
224
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: GraphqlEnhancedService, providedIn: 'root' });
223
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: GraphqlEnhancedService, deps: null, target: i0.ɵɵFactoryTarget.Injectable });
224
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: GraphqlEnhancedService, providedIn: 'root' });
225
225
  }
226
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: GraphqlEnhancedService, decorators: [{
226
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: GraphqlEnhancedService, decorators: [{
227
227
  type: Injectable,
228
228
  args: [{ providedIn: 'root' }]
229
229
  }] });
@@ -28,10 +28,10 @@ class QueryConfigService {
28
28
  resolve(params) {
29
29
  return this.config$.pipe(map(config => this.replace(params, config)));
30
30
  }
31
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: QueryConfigService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
32
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: QueryConfigService, providedIn: 'root' });
31
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: QueryConfigService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
32
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: QueryConfigService, providedIn: 'root' });
33
33
  }
34
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: QueryConfigService, decorators: [{
34
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: QueryConfigService, decorators: [{
35
35
  type: Injectable,
36
36
  args: [{ providedIn: 'root' }]
37
37
  }] });
@@ -18,10 +18,10 @@ class QueryResolverService {
18
18
  }
19
19
  })));
20
20
  }
21
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: QueryResolverService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
22
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: QueryResolverService, providedIn: 'root' });
21
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: QueryResolverService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
22
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: QueryResolverService, providedIn: 'root' });
23
23
  }
24
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: QueryResolverService, decorators: [{
24
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: QueryResolverService, decorators: [{
25
25
  type: Injectable,
26
26
  args: [{ providedIn: 'root' }]
27
27
  }] });
@@ -49,10 +49,10 @@ class QueryService {
49
49
  getSchema(query) {
50
50
  return this.resolver.resolve(query).pipe(switchMap((executableQuery) => this.graphql.getSchema(executableQuery.graphql)), map((result) => result?.['data']));
51
51
  }
52
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: QueryService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
53
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: QueryService, providedIn: 'root' });
52
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: QueryService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
53
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: QueryService, providedIn: 'root' });
54
54
  }
55
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: QueryService, decorators: [{
55
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: QueryService, decorators: [{
56
56
  type: Injectable,
57
57
  args: [{ providedIn: 'root' }]
58
58
  }] });
@@ -41,20 +41,20 @@ class SpeechService {
41
41
  static instanceCounter = 0;
42
42
  PAUSE_THRESHOLD = 1000;
43
43
  recognition = null;
44
- lastSpeechTime = signal(Date.now(), ...(ngDevMode ? [{ debugName: "lastSpeechTime" }] : []));
44
+ lastSpeechTime = signal(Date.now(), ...(ngDevMode ? [{ debugName: "lastSpeechTime" }] : /* istanbul ignore next */ []));
45
45
  ignoreResults = false;
46
46
  lastKnownResultsLength = 0;
47
47
  resultIndexThreshold = 0;
48
- transcript = signal({ finalized: '', interim: '' }, ...(ngDevMode ? [{ debugName: "transcript" }] : []));
48
+ transcript = signal({ finalized: '', interim: '' }, ...(ngDevMode ? [{ debugName: "transcript" }] : /* istanbul ignore next */ []));
49
49
  transcript$ = toObservable(this.transcript);
50
- isListening = signal(false, ...(ngDevMode ? [{ debugName: "isListening" }] : []));
51
- activeComponentId = signal(null, ...(ngDevMode ? [{ debugName: "activeComponentId" }] : []));
50
+ isListening = signal(false, ...(ngDevMode ? [{ debugName: "isListening" }] : /* istanbul ignore next */ []));
51
+ activeComponentId = signal(null, ...(ngDevMode ? [{ debugName: "activeComponentId" }] : /* istanbul ignore next */ []));
52
52
  isSupported = typeof window !== 'undefined' &&
53
53
  (('SpeechRecognition' in window) || ('webkitSpeechRecognition' in window));
54
- finalized = computed(() => this.transcript().finalized, ...(ngDevMode ? [{ debugName: "finalized" }] : []));
54
+ finalized = computed(() => this.transcript().finalized, ...(ngDevMode ? [{ debugName: "finalized" }] : /* istanbul ignore next */ []));
55
55
  finalized$ = toObservable(this.finalized);
56
- autoModeEnabled = signal(false, ...(ngDevMode ? [{ debugName: "autoModeEnabled" }] : []));
57
- selectedSessionId = signal(null, ...(ngDevMode ? [{ debugName: "selectedSessionId" }] : []));
56
+ autoModeEnabled = signal(false, ...(ngDevMode ? [{ debugName: "autoModeEnabled" }] : /* istanbul ignore next */ []));
57
+ selectedSessionId = signal(null, ...(ngDevMode ? [{ debugName: "selectedSessionId" }] : /* istanbul ignore next */ []));
58
58
  constructor() {
59
59
  interval(this.PAUSE_THRESHOLD).pipe(filter(() => this.isListening() && (Date.now() - this.lastSpeechTime()) >= this.PAUSE_THRESHOLD)).subscribe(() => {
60
60
  this.transcript.update(current => ({
@@ -213,10 +213,10 @@ class SpeechService {
213
213
  this.recognition = null;
214
214
  }
215
215
  }
216
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: SpeechService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
217
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: SpeechService, providedIn: 'root' });
216
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: SpeechService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
217
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: SpeechService, providedIn: 'root' });
218
218
  }
219
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: SpeechService, decorators: [{
219
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: SpeechService, decorators: [{
220
220
  type: Injectable,
221
221
  args: [{ providedIn: 'root' }]
222
222
  }], ctorParameters: () => [] });
@@ -15,10 +15,10 @@ class TransformerService {
15
15
  }
16
16
  return typeof transformer === 'function' ? transformer(input) : input;
17
17
  }
18
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: TransformerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
19
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: TransformerService, providedIn: 'root' });
18
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: TransformerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
19
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: TransformerService, providedIn: 'root' });
20
20
  }
21
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: TransformerService, decorators: [{
21
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: TransformerService, decorators: [{
22
22
  type: Injectable,
23
23
  args: [{ providedIn: 'root' }]
24
24
  }] });
@@ -64,10 +64,10 @@ class InMemoryStore {
64
64
  ...data
65
65
  });
66
66
  }
67
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: InMemoryStore, deps: "invalid", target: i0.ɵɵFactoryTarget.Injectable });
68
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: InMemoryStore, providedIn: 'root' });
67
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: InMemoryStore, deps: "invalid", target: i0.ɵɵFactoryTarget.Injectable });
68
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: InMemoryStore, providedIn: 'root' });
69
69
  }
70
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: InMemoryStore, decorators: [{
70
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: InMemoryStore, decorators: [{
71
71
  type: Injectable,
72
72
  args: [{
73
73
  providedIn: 'root'
@@ -51,10 +51,10 @@ class AssistantService {
51
51
  return output;
52
52
  }
53
53
  }
54
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: AssistantService, deps: [{ token: i1.InfrastructureService }], target: i0.ɵɵFactoryTarget.Injectable });
55
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: AssistantService, providedIn: 'root' });
54
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: AssistantService, deps: [{ token: i1.InfrastructureService }], target: i0.ɵɵFactoryTarget.Injectable });
55
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: AssistantService, providedIn: 'root' });
56
56
  }
57
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: AssistantService, decorators: [{
57
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: AssistantService, decorators: [{
58
58
  type: Injectable,
59
59
  args: [{ providedIn: 'root' }]
60
60
  }], ctorParameters: () => [{ type: i1.InfrastructureService }] });
@@ -65,10 +65,10 @@ class DatabaseService {
65
65
  const objects = [obj];
66
66
  return objects.map(obj => getTitle(obj)).filter(Boolean).reverse().join('/');
67
67
  }
68
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: DatabaseService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
69
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: DatabaseService, providedIn: 'root' });
68
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatabaseService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
69
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatabaseService, providedIn: 'root' });
70
70
  }
71
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: DatabaseService, decorators: [{
71
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatabaseService, decorators: [{
72
72
  type: Injectable,
73
73
  args: [{ providedIn: 'root' }]
74
74
  }] });
@@ -34,10 +34,10 @@ class GraphqlService {
34
34
  validator: async (output) => this.graphql(output.query).then(() => []).catch(error => [error.message]),
35
35
  }).then((result) => result.query);
36
36
  }
37
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: GraphqlService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
38
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: GraphqlService, providedIn: 'root' });
37
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: GraphqlService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
38
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: GraphqlService, providedIn: 'root' });
39
39
  }
40
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: GraphqlService, decorators: [{
40
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: GraphqlService, decorators: [{
41
41
  type: Injectable,
42
42
  args: [{ providedIn: 'root' }]
43
43
  }], ctorParameters: () => [] });
@@ -19,10 +19,10 @@ class ProjectService {
19
19
  async update(project) {
20
20
  return this.infra.repo.redis.project.update(project);
21
21
  }
22
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: ProjectService, deps: [{ token: i1.InfrastructureService }], target: i0.ɵɵFactoryTarget.Injectable });
23
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: ProjectService, providedIn: 'root' });
22
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ProjectService, deps: [{ token: i1.InfrastructureService }], target: i0.ɵɵFactoryTarget.Injectable });
23
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ProjectService, providedIn: 'root' });
24
24
  }
25
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: ProjectService, decorators: [{
25
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ProjectService, decorators: [{
26
26
  type: Injectable,
27
27
  args: [{ providedIn: 'root' }]
28
28
  }], ctorParameters: () => [{ type: i1.InfrastructureService }] });
@@ -29,10 +29,10 @@ class SpecService {
29
29
  async delete(id) {
30
30
  return this.infra.repo.redis.spec.delete(id);
31
31
  }
32
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: SpecService, deps: [{ token: i1.InfrastructureService }], target: i0.ɵɵFactoryTarget.Injectable });
33
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: SpecService, providedIn: 'root' });
32
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: SpecService, deps: [{ token: i1.InfrastructureService }], target: i0.ɵɵFactoryTarget.Injectable });
33
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: SpecService, providedIn: 'root' });
34
34
  }
35
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: SpecService, decorators: [{
35
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: SpecService, decorators: [{
36
36
  type: Injectable,
37
37
  args: [{ providedIn: 'root' }]
38
38
  }], ctorParameters: () => [{ type: i1.InfrastructureService }] });
@@ -56,10 +56,10 @@ class AssistantService {
56
56
  return output;
57
57
  }
58
58
  }
59
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: AssistantService, deps: [{ token: i1.InfrastructureService }], target: i0.ɵɵFactoryTarget.Injectable });
60
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: AssistantService, providedIn: 'root' });
59
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: AssistantService, deps: [{ token: i1.InfrastructureService }], target: i0.ɵɵFactoryTarget.Injectable });
60
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: AssistantService, providedIn: 'root' });
61
61
  }
62
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: AssistantService, decorators: [{
62
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: AssistantService, decorators: [{
63
63
  type: Injectable,
64
64
  args: [{ providedIn: 'root' }]
65
65
  }], ctorParameters: () => [{ type: i1.InfrastructureService }] });
@@ -90,10 +90,10 @@ class SpecService {
90
90
  async delete(id) {
91
91
  return this.infra.repo.redis.spec.delete(id);
92
92
  }
93
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: SpecService, deps: [{ token: i1.InfrastructureService }], target: i0.ɵɵFactoryTarget.Injectable });
94
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: SpecService, providedIn: 'root' });
93
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: SpecService, deps: [{ token: i1.InfrastructureService }], target: i0.ɵɵFactoryTarget.Injectable });
94
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: SpecService, providedIn: 'root' });
95
95
  }
96
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: SpecService, decorators: [{
96
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: SpecService, decorators: [{
97
97
  type: Injectable,
98
98
  args: [{ providedIn: 'root' }]
99
99
  }], ctorParameters: () => [{ type: i1.InfrastructureService }] });
@@ -115,10 +115,10 @@ class ProjectService {
115
115
  async update(project) {
116
116
  return this.infra.repo.redis.project.update(project);
117
117
  }
118
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: ProjectService, deps: [{ token: i1.InfrastructureService }], target: i0.ɵɵFactoryTarget.Injectable });
119
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: ProjectService, providedIn: 'root' });
118
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ProjectService, deps: [{ token: i1.InfrastructureService }], target: i0.ɵɵFactoryTarget.Injectable });
119
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ProjectService, providedIn: 'root' });
120
120
  }
121
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: ProjectService, decorators: [{
121
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ProjectService, decorators: [{
122
122
  type: Injectable,
123
123
  args: [{ providedIn: 'root' }]
124
124
  }], ctorParameters: () => [{ type: i1.InfrastructureService }] });
@@ -151,10 +151,10 @@ class GraphqlService {
151
151
  validator: async (output) => this.graphql(output.query).then(() => []).catch(error => [error.message]),
152
152
  }).then((result) => result.query);
153
153
  }
154
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: GraphqlService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
155
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: GraphqlService, providedIn: 'root' });
154
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: GraphqlService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
155
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: GraphqlService, providedIn: 'root' });
156
156
  }
157
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: GraphqlService, decorators: [{
157
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: GraphqlService, decorators: [{
158
158
  type: Injectable,
159
159
  args: [{ providedIn: 'root' }]
160
160
  }], ctorParameters: () => [] });
@@ -164,10 +164,10 @@ class UsecaseService {
164
164
  project = inject(ProjectService);
165
165
  spec = inject(SpecService);
166
166
  graphql = inject(GraphqlService);
167
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: UsecaseService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
168
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: UsecaseService, providedIn: 'root' });
167
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: UsecaseService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
168
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: UsecaseService, providedIn: 'root' });
169
169
  }
170
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: UsecaseService, decorators: [{
170
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: UsecaseService, decorators: [{
171
171
  type: Injectable,
172
172
  args: [{ providedIn: 'root' }]
173
173
  }] });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xxmachina/common",
3
- "version": "20.67.0",
3
+ "version": "20.73.0",
4
4
  "license": "MIT",
5
5
  "main": "./index.js",
6
6
  "types": "./index.d.ts",
@@ -13,11 +13,11 @@
13
13
  "@nestjs/common": "10.2.8",
14
14
  "@nestjs/graphql": "^11.0.0",
15
15
  "@nestjs/passport": "^9.0.3",
16
- "@ng-atomic/common": "20.67.0",
17
- "@ng-atomic/components": "20.67.0",
18
- "@ng-atomic/core": "20.67.0",
19
- "@nx-ddd/common": "20.67.0",
20
- "@nx-ddd/core": "20.67.0",
16
+ "@ng-atomic/common": "20.73.0",
17
+ "@ng-atomic/components": "20.73.0",
18
+ "@ng-atomic/core": "20.73.0",
19
+ "@nx-ddd/common": "20.73.0",
20
+ "@nx-ddd/core": "20.73.0",
21
21
  "@tfarras/nestjs-firebase-auth": "^2.0.0",
22
22
  "apollo-angular": "^7.0.2",
23
23
  "class-transformer": "^0.5.1",
@@ -25,7 +25,7 @@
25
25
  "class-validator-extended": "^3.2.0",
26
26
  "dayjs": "1.11.13",
27
27
  "express": "4.21.2",
28
- "firebase-admin": "^12.6.0",
28
+ "firebase-admin": "^12.6.0 || ^13.0.0 || ^14.0.0",
29
29
  "flat": "^6.0.0",
30
30
  "genson-js": "^0.0.8",
31
31
  "graphql": "^16.8.1",
@@ -43,11 +43,11 @@
43
43
  "validate-azure-ad-token": "^2.2.0"
44
44
  },
45
45
  "optionalDependencies": {
46
- "@nx-ddd/any-func": "20.67.0",
47
- "@nx-ddd/firestore": "20.67.0",
48
- "@nx-ddd/google": "20.67.0",
49
- "@nx-ddd/hasura": "20.67.0",
50
- "@nx-ddd/notion": "20.67.0",
46
+ "@nx-ddd/any-func": "20.73.0",
47
+ "@nx-ddd/firestore": "20.73.0",
48
+ "@nx-ddd/google": "20.73.0",
49
+ "@nx-ddd/hasura": "20.73.0",
50
+ "@nx-ddd/notion": "20.73.0",
51
51
  "@notionhq/client": "^2.2.15"
52
52
  },
53
53
  "dependencies": {
@@ -67,14 +67,6 @@
67
67
  "types": "./types/xxmachina-common-_shared-ansi.d.ts",
68
68
  "default": "./fesm2022/xxmachina-common-_shared-ansi.mjs"
69
69
  },
70
- "./_shared/auth": {
71
- "types": "./types/xxmachina-common-_shared-auth.d.ts",
72
- "default": "./fesm2022/xxmachina-common-_shared-auth.mjs"
73
- },
74
- "./_shared/meta": {
75
- "types": "./types/xxmachina-common-_shared-meta.d.ts",
76
- "default": "./fesm2022/xxmachina-common-_shared-meta.mjs"
77
- },
78
70
  "./_shared/meta/redis": {
79
71
  "types": "./types/xxmachina-common-_shared-meta-redis.d.ts",
80
72
  "default": "./fesm2022/xxmachina-common-_shared-meta-redis.mjs"
@@ -83,10 +75,6 @@
83
75
  "types": "./types/xxmachina-common-auth.d.ts",
84
76
  "default": "./fesm2022/xxmachina-common-auth.mjs"
85
77
  },
86
- "./auth/azure": {
87
- "types": "./types/xxmachina-common-auth-azure.d.ts",
88
- "default": "./fesm2022/xxmachina-common-auth-azure.mjs"
89
- },
90
78
  "./auth/core": {
91
79
  "types": "./types/xxmachina-common-auth-core.d.ts",
92
80
  "default": "./fesm2022/xxmachina-common-auth-core.mjs"
@@ -95,26 +83,6 @@
95
83
  "types": "./types/xxmachina-common-auth-firebase.d.ts",
96
84
  "default": "./fesm2022/xxmachina-common-auth-firebase.mjs"
97
85
  },
98
- "./auth/passports": {
99
- "types": "./types/xxmachina-common-auth-passports.d.ts",
100
- "default": "./fesm2022/xxmachina-common-auth-passports.mjs"
101
- },
102
- "./auth/passports/anonymous": {
103
- "types": "./types/xxmachina-common-auth-passports-anonymous.d.ts",
104
- "default": "./fesm2022/xxmachina-common-auth-passports-anonymous.mjs"
105
- },
106
- "./auth/passports/firebase": {
107
- "types": "./types/xxmachina-common-auth-passports-firebase.d.ts",
108
- "default": "./fesm2022/xxmachina-common-auth-passports-firebase.mjs"
109
- },
110
- "./auth/passports/internal": {
111
- "types": "./types/xxmachina-common-auth-passports-internal.d.ts",
112
- "default": "./fesm2022/xxmachina-common-auth-passports-internal.mjs"
113
- },
114
- "./auth/passports/msal": {
115
- "types": "./types/xxmachina-common-auth-passports-msal.d.ts",
116
- "default": "./fesm2022/xxmachina-common-auth-passports-msal.mjs"
117
- },
118
86
  "./domain": {
119
87
  "types": "./types/xxmachina-common-domain.d.ts",
120
88
  "default": "./fesm2022/xxmachina-common-domain.mjs"
@@ -1,24 +0,0 @@
1
- import { __decorate } from 'tslib';
2
- import { Module } from '@nestjs/common';
3
- import { PassportModule } from '@nestjs/passport';
4
-
5
- var AuthModule_1;
6
- let AuthModule = AuthModule_1 = class AuthModule {
7
- static forRoot() {
8
- return { module: AuthModule_1, providers: [] };
9
- }
10
- };
11
- AuthModule = AuthModule_1 = __decorate([
12
- Module({
13
- imports: [PassportModule],
14
- providers: [],
15
- exports: [],
16
- controllers: [],
17
- })
18
- ], AuthModule);
19
-
20
- /**
21
- * Generated bundle index. Do not edit.
22
- */
23
-
24
- export { AuthModule };
@@ -1,24 +0,0 @@
1
- let ObjectType, Field, ID;
2
- const _decorators = {
3
- ObjectType: function () {
4
- return function (target) {
5
- void 0;
6
- };
7
- },
8
- Field: function () {
9
- return function (target, propertyKey) {
10
- void 0;
11
- };
12
- },
13
- ID: null,
14
- };
15
- ({ ObjectType, Field, ID } = _decorators);
16
- function provideNestjsGraphql(_decorators) {
17
- ({ ObjectType, Field, ID } = _decorators);
18
- }
19
-
20
- /**
21
- * Generated bundle index. Do not edit.
22
- */
23
-
24
- export { Field, ID, ObjectType, provideNestjsGraphql };
@@ -1,159 +0,0 @@
1
- import * as i0 from '@angular/core';
2
- import { InjectionToken, inject, signal, Injectable, makeEnvironmentProviders, ENVIRONMENT_INITIALIZER, importProvidersFrom } from '@angular/core';
3
- import * as i1 from '@azure/msal-angular';
4
- import { MsalModule } from '@azure/msal-angular';
5
- import { PublicClientApplication, InteractionType } from '@azure/msal-browser';
6
- import { provideEffect } from '@ng-atomic/core';
7
- import { AppFrameStore } from '@ng-atomic/components/frames/app';
8
- import { AuthService as AuthService$1 } from '@xxmachina/common/auth';
9
- import { toSignal, toObservable } from '@angular/core/rxjs-interop';
10
- import { ReplaySubject, interval, startWith, switchMap, filter, take, lastValueFrom } from 'rxjs';
11
- import { HttpClient } from '@angular/common/http';
12
-
13
- class AuthService {
14
- }
15
- const AZURE_AUTH_CONFIG = new InjectionToken('[@xxmachina/common] AZURE_AUTH_CONFIG');
16
- class AzureAuthService extends AuthService {
17
- msal;
18
- config = inject(AZURE_AUTH_CONFIG);
19
- auth$ = new ReplaySubject(1);
20
- auth = toSignal(this.auth$);
21
- accessToken = signal(null, ...(ngDevMode ? [{ debugName: "accessToken" }] : []));
22
- accessToken$ = toObservable(this.accessToken);
23
- http = inject(HttpClient);
24
- constructor(msal) {
25
- super();
26
- this.msal = msal;
27
- this.initialize().then(() => {
28
- const account = this.msal.instance.getActiveAccount();
29
- if (account) {
30
- this.auth$.next(account);
31
- }
32
- else {
33
- this.auth$.next(null);
34
- }
35
- });
36
- interval(1_000 * 60 * 5).pipe(startWith(null), switchMap(() => this.auth$.pipe(filter((auth) => !!auth), take(1))), filter(() => !!this.auth())).subscribe(() => {
37
- this.updateAccessToken();
38
- });
39
- }
40
- async initialize() {
41
- await lastValueFrom(this.msal.initialize()).then(() => {
42
- return this.msal.instance.handleRedirectPromise().then((response) => {
43
- if (response !== null) {
44
- this.msal.instance.setActiveAccount(response.account);
45
- }
46
- }).catch((error) => {
47
- console.error('リダイレクト処理エラー:', error);
48
- });
49
- });
50
- }
51
- async signIn() {
52
- try {
53
- const result = await lastValueFrom(this.msal.loginPopup({
54
- scopes: this.config.scopes,
55
- }));
56
- this.msal.instance.setActiveAccount(result.account);
57
- this.auth$.next(result.account);
58
- console.debug('Sign-in result:', result);
59
- await this.acquireAccessToken();
60
- return result.account;
61
- }
62
- catch (error) {
63
- console.error('Sign-in failed:', error);
64
- throw error;
65
- }
66
- }
67
- async signOut() {
68
- try {
69
- this.msal.instance.setActiveAccount(null);
70
- this.auth$.next(null);
71
- this.accessToken.set(null);
72
- }
73
- catch (error) {
74
- console.error('Sign-out failed:', error);
75
- throw error;
76
- }
77
- }
78
- async updateAccessToken(scopes = this.config.scopes) {
79
- try {
80
- const accessToken = await this.acquireAccessToken(scopes);
81
- this.accessToken.set(accessToken);
82
- }
83
- catch (error) {
84
- console.error('Failed to acquire access token:', error);
85
- this.accessToken.set(null);
86
- throw error;
87
- }
88
- }
89
- async acquireAccessToken(scopes = this.config.scopes) {
90
- const account = this.msal.instance.getActiveAccount();
91
- if (!account)
92
- throw new Error('No active account found.');
93
- return lastValueFrom(this.msal.acquireTokenSilent({
94
- account,
95
- scopes,
96
- forceRefresh: true,
97
- })).then((response) => {
98
- this.auth$.next(response.account);
99
- console.debug('[AzureAuthService] response:', response);
100
- return response.accessToken;
101
- });
102
- }
103
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: AzureAuthService, deps: [{ token: i1.MsalService }], target: i0.ɵɵFactoryTarget.Injectable });
104
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: AzureAuthService, providedIn: 'root' });
105
- }
106
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: AzureAuthService, decorators: [{
107
- type: Injectable,
108
- args: [{ providedIn: 'root' }]
109
- }], ctorParameters: () => [{ type: i1.MsalService }] });
110
-
111
- function provideAppInitializer(useValue) {
112
- return makeEnvironmentProviders([
113
- {
114
- provide: ENVIRONMENT_INITIALIZER,
115
- useValue,
116
- multi: true,
117
- },
118
- ]);
119
- }
120
- function provideAzureAuth(config) {
121
- return makeEnvironmentProviders([
122
- importProvidersFrom(MsalModule.forRoot(new PublicClientApplication(config?.configuration), {
123
- interactionType: InteractionType.Redirect,
124
- authRequest: {
125
- scopes: config.scopes,
126
- },
127
- }, {
128
- interactionType: InteractionType.Redirect,
129
- protectedResourceMap: new Map([
130
- ['https://graph.microsoft.com/v1.0/me', config.scopes],
131
- ]),
132
- })),
133
- { provide: AZURE_AUTH_CONFIG, useValue: config },
134
- { provide: AuthService$1, useClass: AzureAuthService },
135
- provideAppInitializer(() => { inject(AuthService$1); }),
136
- provideEffect(AppFrameStore.ActionId.SIGN_IN_WITH_MICROSOFT, () => {
137
- const auth = inject(AuthService$1);
138
- return () => {
139
- console.debug('auth:', auth);
140
- if (!auth.auth()) {
141
- auth.signIn();
142
- }
143
- else {
144
- console.log('既にログイン済みです。');
145
- }
146
- };
147
- }),
148
- provideEffect(AppFrameStore.ActionId.SIGN_OUT, () => {
149
- const auth = inject(AuthService$1);
150
- return () => auth.signOut();
151
- }),
152
- ]);
153
- }
154
-
155
- /**
156
- * Generated bundle index. Do not edit.
157
- */
158
-
159
- export { AZURE_AUTH_CONFIG, AzureAuthService, provideAppInitializer, provideAzureAuth };