@ama-mfe/ng-utils 14.0.0-next.9 → 14.0.0-prerelease.1

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/README.md CHANGED
@@ -12,6 +12,7 @@ Key features include:
12
12
  look and feel.
13
13
  - [Resize](https://github.com/AmadeusITGroup/otter/blob/main/packages/%40ama-mfe/ng-utils/src/resize/): Dynamically adjusts the iframe dimensions to fit the content of the embedded application, enhancing the
14
14
  user experience.
15
+ - [User Activity](https://github.com/AmadeusITGroup/otter/blob/main/packages/%40ama-mfe/ng-utils/src/user-activity/): Tracks user interactions across embedded micro-frontends for session timeout functionality, analytics, or any feature that needs to detect user activity.
15
16
 
16
17
  ## Installation
17
18
  To install the package, run:
@@ -146,6 +147,7 @@ You will find more information for each service in their respective `README.md`:
146
147
  - [Navigation](https://github.com/AmadeusITGroup/otter/tree/main/packages/%40ama-mfe/ng-utils/src/navigation/README.md)
147
148
  - [Resize](https://github.com/AmadeusITGroup/otter/tree/main/packages/%40ama-mfe/ng-utils/src/resize/README.md)
148
149
  - [Theme](https://github.com/AmadeusITGroup/otter/tree/main/packages/%40ama-mfe/ng-utils/src/theme/README.md)
150
+ - [User Activity](https://github.com/AmadeusITGroup/otter/tree/main/packages/%40ama-mfe/ng-utils/src/user-activity/README.md)
149
151
 
150
152
  ### Write your own producer and consumers.
151
153
  Use the `ProducerManagerService` and the `ConsumerManagerService` to support your own custom messages.
@@ -300,152 +302,4 @@ To avoid this, the `@ama-mfe/ng-utils` will forbid the application running in th
300
302
 
301
303
  The User Activity Tracking feature allows a host application (shell) to monitor user interactions across embedded micro-frontends. This is useful for implementing session timeout functionality, analytics, or any feature that needs to know when users are actively interacting with the application.
302
304
 
303
- #### How it works
304
-
305
- - **Producer**: The `ActivityProducerService` listens for DOM events (click, keydown, scroll, touchstart, focus) and:
306
- - Exposes a `localActivity` signal for consumers within the same application (not throttled for local detection).
307
- - Sends throttled activity messages via the communication protocol to connected peers.
308
- - **Consumer**: The `ActivityConsumerService` receives activity messages from connected peers via the communication protocol and exposes them via the `latestReceivedActivity` signal.
309
-
310
- Both services can be used in either the shell (host) or embedded applications depending on your use case. For example:
311
- - A shell can produce activity signals to notify embedded modules of user interactions in the host.
312
- - An embedded module can consume activity signals from the shell.
313
- - An application can use the producer's `localActivity` signal to detect activity locally.
314
-
315
- The service automatically throttles messages sent to peers to prevent flooding the communication channel. High-frequency events like `scroll` have additional throttling.
316
-
317
- #### Producer Configuration
318
-
319
- Start the `ActivityProducerService` to send activity signals to connected peers:
320
-
321
- ```typescript
322
- import { inject, runInInjectionContext } from '@angular/core';
323
- import { bootstrapApplication } from '@angular/platform-browser';
324
- import { ConnectionService, ActivityProducerService } from '@ama-mfe/ng-utils';
325
-
326
- bootstrapApplication(App, appConfig)
327
- .then((m) => {
328
- runInInjectionContext(m.injector, () => {
329
- if (window.top !== window.self) {
330
- inject(ConnectionService).connect('hostUniqueID');
331
- // Start activity tracking with custom throttle
332
- inject(ActivityProducerService).start({
333
- throttleMs: 5000 // Send at most one message every 5 seconds
334
- });
335
- }
336
- });
337
- });
338
- ```
339
-
340
- ##### Configuration Options
341
-
342
- | Option | Type | Default | Description |
343
- |--------|------|---------|-------------|
344
- | `throttleMs` | `number` | `1000` | Minimum interval between activity messages sent to the host |
345
- | `trackNestedIframes` | `boolean` | `false` | Enable tracking of nested iframes within the application |
346
- | `nestedIframePollIntervalMs` | `number` | `1000` | Polling interval for detecting iframe focus changes |
347
- | `nestedIframeActivityEmitIntervalMs` | `number` | `30000` | Interval for sending activity signals while an iframe has focus |
348
- | `highFrequencyThrottleMs` | `number` | `300` | Throttle time for high-frequency events (scroll) |
349
- | `shouldBroadcast` | `(event: Event) => boolean` | - | Optional filter function to control which events are broadcast |
350
-
351
- ##### Filtering Events with shouldBroadcast
352
-
353
- The `shouldBroadcast` option allows you to filter which events trigger activity messages. This is useful in the shell application to exclude events that occur on iframes, since user activity inside embedded modules is already tracked via the communication protocol.
354
-
355
- ```typescript
356
- // In the shell application
357
- inject(ActivityProducerService).start({
358
- throttleMs: 1000,
359
- shouldBroadcast: (event: Event) => {
360
- // Exclude events on iframes - activity from embedded modules comes via the communication protocol
361
- return !(event.target instanceof HTMLIFrameElement);
362
- }
363
- });
364
- ```
365
-
366
- ##### Tracking Nested Iframes
367
-
368
- When a user interacts with content inside an iframe (e.g., a third-party widget, payment form, or embedded content), the parent application cannot detect those interactions directly. This is because:
369
-
370
- 1. **Cross-origin restrictions**: DOM events inside cross-origin iframes do not bubble up to the parent document.
371
- 2. **Focus isolation**: When an iframe has focus, the parent document stops receiving keyboard and mouse events.
372
-
373
- This creates a problem for detection of user interactions: a user could be actively filling out a form inside an iframe, but the host application would see no activity and might incorrectly trigger a session timeout.
374
-
375
- **Solution**: When `trackNestedIframes` is enabled, the `ActivityProducerService` polls `document.activeElement` to detect when an iframe gains focus. While an iframe has focus, the service simulates activity by periodically emitting `iframeinteraction` events. This ensures the host application knows the user is still active, even though it cannot see the actual interactions inside the iframe.
376
-
377
- Enable nested iframe tracking in embedded applications that contain other iframes:
378
-
379
- ```typescript
380
- inject(ActivityProducerService).start({
381
- throttleMs: 5000,
382
- trackNestedIframes: true,
383
- nestedIframePollIntervalMs: 1000, // Check for iframe focus every second
384
- nestedIframeActivityEmitIntervalMs: 30000 // Send activity every 30s while iframe has focus
385
- });
386
- ```
387
-
388
- **When to use**: Enable this option in embedded modules that contain iframes whose content you cannot modify to include activity tracking (e.g., third-party widgets, payment providers, or external content).
389
-
390
- #### Consumer Configuration
391
-
392
- Start the `ActivityConsumerService` to receive activity signals from connected peers:
393
-
394
- ```typescript
395
- import { Component, inject, effect } from '@angular/core';
396
- import { ActivityConsumerService } from '@ama-mfe/ng-utils';
397
-
398
- @Component({
399
- selector: 'app-shell',
400
- template: '...'
401
- })
402
- export class ShellComponent {
403
- private readonly activityConsumer = inject(ActivityConsumerService);
404
-
405
- constructor() {
406
- // Start listening for activity messages
407
- this.activityConsumer.start();
408
-
409
- // React to activity changes
410
- effect(() => {
411
- const activity = this.activityConsumer.latestReceivedActivity();
412
- if (activity) {
413
- console.log(`Activity from ${activity.channelId}: ${activity.eventType} at ${activity.timestamp}`);
414
- // Reset session timeout, update analytics, etc.
415
- }
416
- });
417
- }
418
-
419
- ngOnDestroy() {
420
- this.activityConsumer.stop();
421
- }
422
- }
423
- ```
424
-
425
- #### Local Activity Signal
426
-
427
- The `ActivityProducerService` also exposes a `localActivity` signal for detecting activity within the same application:
428
-
429
- ```typescript
430
- import { Component, inject, effect } from '@angular/core';
431
- import { ActivityProducerService } from '@ama-mfe/ng-utils';
432
-
433
- @Component({
434
- selector: 'app-root',
435
- template: '...'
436
- })
437
- export class AppComponent {
438
- private readonly activityProducer = inject(ActivityProducerService);
439
-
440
- constructor() {
441
- this.activityProducer.start({ throttleMs: 1000 });
442
-
443
- effect(() => {
444
- const activity = this.activityProducer.localActivity();
445
- if (activity) {
446
- // React to local activity (not throttled for local detection)
447
- }
448
- });
449
- }
450
- }
451
- ```
305
+ For detailed documentation, configuration options, and examples, see the [User Activity README](https://github.com/AmadeusITGroup/otter/tree/main/packages/%40ama-mfe/ng-utils/src/user-activity/README.md).
@@ -58,10 +58,10 @@ class ConnectDirective {
58
58
  });
59
59
  });
60
60
  }
61
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ConnectDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
62
- /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.15", type: ConnectDirective, isStandalone: true, selector: "iframe[connect]", inputs: { connect: { classPropertyName: "connect", publicName: "connect", isSignal: true, isRequired: true, transformFunction: null }, src: { classPropertyName: "src", publicName: "src", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "src": "this.srcAttr" } }, ngImport: i0 }); }
61
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ConnectDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
62
+ /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.0.8", type: ConnectDirective, isStandalone: true, selector: "iframe[connect]", inputs: { connect: { classPropertyName: "connect", publicName: "connect", isSignal: true, isRequired: true, transformFunction: null }, src: { classPropertyName: "src", publicName: "src", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "src": "this.srcAttr" } }, ngImport: i0 }); }
63
63
  }
64
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ConnectDirective, decorators: [{
64
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ConnectDirective, decorators: [{
65
65
  type: Directive,
66
66
  args: [{
67
67
  selector: 'iframe[connect]',
@@ -143,10 +143,10 @@ class ProducerManagerService {
143
143
  }
144
144
  return handlersPresent;
145
145
  }
146
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ProducerManagerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
147
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ProducerManagerService, providedIn: 'root' }); }
146
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ProducerManagerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
147
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ProducerManagerService, providedIn: 'root' }); }
148
148
  }
149
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ProducerManagerService, decorators: [{
149
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ProducerManagerService, decorators: [{
150
150
  type: Injectable,
151
151
  args: [{
152
152
  providedIn: 'root'
@@ -238,10 +238,10 @@ class ConsumerManagerService {
238
238
  return consumers.filter((c) => c !== consumer);
239
239
  });
240
240
  }
241
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ConsumerManagerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
242
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ConsumerManagerService, providedIn: 'root' }); }
241
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ConsumerManagerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
242
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ConsumerManagerService, providedIn: 'root' }); }
243
243
  }
244
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ConsumerManagerService, decorators: [{
244
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ConsumerManagerService, decorators: [{
245
245
  type: Injectable,
246
246
  args: [{
247
247
  providedIn: 'root'
@@ -312,10 +312,10 @@ class HistoryConsumerService {
312
312
  stop() {
313
313
  this.consumerManagerService.unregister(this);
314
314
  }
315
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: HistoryConsumerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
316
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: HistoryConsumerService, providedIn: 'root' }); }
315
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: HistoryConsumerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
316
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: HistoryConsumerService, providedIn: 'root' }); }
317
317
  }
318
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: HistoryConsumerService, decorators: [{
318
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: HistoryConsumerService, decorators: [{
319
319
  type: Injectable,
320
320
  args: [{
321
321
  providedIn: 'root'
@@ -431,10 +431,10 @@ class HostInfoPipe {
431
431
  return typeof url === 'string' ? moduleUrlStringyfied : this.domSanitizer.bypassSecurityTrustResourceUrl(moduleUrlStringyfied);
432
432
  }
433
433
  }
434
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: HostInfoPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
435
- /** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.15", ngImport: i0, type: HostInfoPipe, isStandalone: true, name: "hostInfo" }); }
434
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: HostInfoPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
435
+ /** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "21.0.8", ngImport: i0, type: HostInfoPipe, isStandalone: true, name: "hostInfo" }); }
436
436
  }
437
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: HostInfoPipe, decorators: [{
437
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: HostInfoPipe, decorators: [{
438
438
  type: Pipe,
439
439
  args: [{
440
440
  name: 'hostInfo'
@@ -587,10 +587,10 @@ class NavigationConsumerService {
587
587
  stop() {
588
588
  this.consumerManagerService.unregister(this);
589
589
  }
590
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: NavigationConsumerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
591
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: NavigationConsumerService, providedIn: 'root' }); }
590
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: NavigationConsumerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
591
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: NavigationConsumerService, providedIn: 'root' }); }
592
592
  }
593
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: NavigationConsumerService, decorators: [{
593
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: NavigationConsumerService, decorators: [{
594
594
  type: Injectable,
595
595
  args: [{
596
596
  providedIn: 'root'
@@ -633,10 +633,10 @@ class RouteMemorizeService {
633
633
  getRoute(channelId) {
634
634
  return this.routeStack[channelId];
635
635
  }
636
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: RouteMemorizeService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
637
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: RouteMemorizeService, providedIn: 'root' }); }
636
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: RouteMemorizeService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
637
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: RouteMemorizeService, providedIn: 'root' }); }
638
638
  }
639
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: RouteMemorizeService, decorators: [{
639
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: RouteMemorizeService, decorators: [{
640
640
  type: Injectable,
641
641
  args: [{
642
642
  providedIn: 'root'
@@ -684,10 +684,10 @@ class RestoreRoute {
684
684
  return typeof url === 'string' ? moduleUrlStringyfied : this.domSanitizer.bypassSecurityTrustResourceUrl(moduleUrlStringyfied);
685
685
  }
686
686
  }
687
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: RestoreRoute, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
688
- /** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.15", ngImport: i0, type: RestoreRoute, isStandalone: true, name: "restoreRoute" }); }
687
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: RestoreRoute, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
688
+ /** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "21.0.8", ngImport: i0, type: RestoreRoute, isStandalone: true, name: "restoreRoute" }); }
689
689
  }
690
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: RestoreRoute, decorators: [{
690
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: RestoreRoute, decorators: [{
691
691
  type: Pipe,
692
692
  args: [{
693
693
  name: 'restoreRoute'
@@ -741,10 +741,10 @@ class RouteMemorizeDirective {
741
741
  }
742
742
  });
743
743
  }
744
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: RouteMemorizeDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
745
- /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.15", type: RouteMemorizeDirective, isStandalone: true, selector: "iframe[memorizeRoute]", inputs: { memorizeRoute: { classPropertyName: "memorizeRoute", publicName: "memorizeRoute", isSignal: true, isRequired: false, transformFunction: null }, memorizeRouteId: { classPropertyName: "memorizeRouteId", publicName: "memorizeRouteId", isSignal: true, isRequired: false, transformFunction: null }, memorizeMaxAge: { classPropertyName: "memorizeMaxAge", publicName: "memorizeMaxAge", isSignal: true, isRequired: false, transformFunction: null }, memorizeRouteMaxAge: { classPropertyName: "memorizeRouteMaxAge", publicName: "memorizeRouteMaxAge", isSignal: true, isRequired: false, transformFunction: null }, connect: { classPropertyName: "connect", publicName: "connect", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0 }); }
744
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: RouteMemorizeDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
745
+ /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.0.8", type: RouteMemorizeDirective, isStandalone: true, selector: "iframe[memorizeRoute]", inputs: { memorizeRoute: { classPropertyName: "memorizeRoute", publicName: "memorizeRoute", isSignal: true, isRequired: false, transformFunction: null }, memorizeRouteId: { classPropertyName: "memorizeRouteId", publicName: "memorizeRouteId", isSignal: true, isRequired: false, transformFunction: null }, memorizeMaxAge: { classPropertyName: "memorizeMaxAge", publicName: "memorizeMaxAge", isSignal: true, isRequired: false, transformFunction: null }, memorizeRouteMaxAge: { classPropertyName: "memorizeRouteMaxAge", publicName: "memorizeRouteMaxAge", isSignal: true, isRequired: false, transformFunction: null }, connect: { classPropertyName: "connect", publicName: "connect", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0 }); }
746
746
  }
747
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: RouteMemorizeDirective, decorators: [{
747
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: RouteMemorizeDirective, decorators: [{
748
748
  type: Directive,
749
749
  args: [{
750
750
  selector: 'iframe[memorizeRoute]',
@@ -836,10 +836,10 @@ class RoutingService {
836
836
  }
837
837
  });
838
838
  }
839
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: RoutingService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
840
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: RoutingService, providedIn: 'root' }); }
839
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: RoutingService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
840
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: RoutingService, providedIn: 'root' }); }
841
841
  }
842
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: RoutingService, decorators: [{
842
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: RoutingService, decorators: [{
843
843
  type: Injectable,
844
844
  args: [{
845
845
  providedIn: 'root'
@@ -886,10 +886,10 @@ class ResizeConsumerService {
886
886
  stop() {
887
887
  this.consumerManagerService.unregister(this);
888
888
  }
889
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ResizeConsumerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
890
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ResizeConsumerService, providedIn: 'root' }); }
889
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ResizeConsumerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
890
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ResizeConsumerService, providedIn: 'root' }); }
891
891
  }
892
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ResizeConsumerService, decorators: [{
892
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ResizeConsumerService, decorators: [{
893
893
  type: Injectable,
894
894
  args: [{
895
895
  providedIn: 'root'
@@ -936,10 +936,10 @@ class ResizeService {
936
936
  });
937
937
  afterNextRender(() => this.resizeObserver?.observe(document.body));
938
938
  }
939
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ResizeService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
940
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ResizeService, providedIn: 'root' }); }
939
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ResizeService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
940
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ResizeService, providedIn: 'root' }); }
941
941
  }
942
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ResizeService, decorators: [{
942
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ResizeService, decorators: [{
943
943
  type: Injectable,
944
944
  args: [{
945
945
  providedIn: 'root'
@@ -983,10 +983,10 @@ class ScalableDirective {
983
983
  }
984
984
  });
985
985
  }
986
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ScalableDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
987
- /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.15", type: ScalableDirective, isStandalone: true, selector: "[scalable]", inputs: { connect: { classPropertyName: "connect", publicName: "connect", isSignal: true, isRequired: false, transformFunction: null }, scalable: { classPropertyName: "scalable", publicName: "scalable", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0 }); }
986
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ScalableDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
987
+ /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.0.8", type: ScalableDirective, isStandalone: true, selector: "[scalable]", inputs: { connect: { classPropertyName: "connect", publicName: "connect", isSignal: true, isRequired: false, transformFunction: null }, scalable: { classPropertyName: "scalable", publicName: "scalable", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0 }); }
988
988
  }
989
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ScalableDirective, decorators: [{
989
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ScalableDirective, decorators: [{
990
990
  type: Directive,
991
991
  args: [{
992
992
  selector: '[scalable]',
@@ -1144,10 +1144,10 @@ class ThemeProducerService {
1144
1144
  this.logger.error('Error in theme service message', message);
1145
1145
  this.revertToPreviousTheme();
1146
1146
  }
1147
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ThemeProducerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1148
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ThemeProducerService, providedIn: 'root' }); }
1147
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ThemeProducerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1148
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ThemeProducerService, providedIn: 'root' }); }
1149
1149
  }
1150
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ThemeProducerService, decorators: [{
1150
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ThemeProducerService, decorators: [{
1151
1151
  type: Injectable,
1152
1152
  args: [{
1153
1153
  providedIn: 'root'
@@ -1180,10 +1180,10 @@ class ApplyTheme {
1180
1180
  }
1181
1181
  return undefined;
1182
1182
  }
1183
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ApplyTheme, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
1184
- /** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.15", ngImport: i0, type: ApplyTheme, isStandalone: true, name: "applyTheme" }); }
1183
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ApplyTheme, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
1184
+ /** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "21.0.8", ngImport: i0, type: ApplyTheme, isStandalone: true, name: "applyTheme" }); }
1185
1185
  }
1186
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ApplyTheme, decorators: [{
1186
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ApplyTheme, decorators: [{
1187
1187
  type: Pipe,
1188
1188
  args: [{
1189
1189
  name: 'applyTheme'
@@ -1239,10 +1239,10 @@ class ThemeConsumerService {
1239
1239
  stop() {
1240
1240
  this.consumerManagerService.unregister(this);
1241
1241
  }
1242
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ThemeConsumerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1243
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ThemeConsumerService, providedIn: 'root' }); }
1242
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ThemeConsumerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1243
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ThemeConsumerService, providedIn: 'root' }); }
1244
1244
  }
1245
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ThemeConsumerService, decorators: [{
1245
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ThemeConsumerService, decorators: [{
1246
1246
  type: Injectable,
1247
1247
  args: [{
1248
1248
  providedIn: 'root'
@@ -1415,10 +1415,10 @@ class IframeActivityTrackerService {
1415
1415
  this.stopActivityInterval();
1416
1416
  this.config = undefined;
1417
1417
  }
1418
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: IframeActivityTrackerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1419
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: IframeActivityTrackerService, providedIn: 'root' }); }
1418
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: IframeActivityTrackerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1419
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: IframeActivityTrackerService, providedIn: 'root' }); }
1420
1420
  }
1421
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: IframeActivityTrackerService, decorators: [{
1421
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: IframeActivityTrackerService, decorators: [{
1422
1422
  type: Injectable,
1423
1423
  args: [{
1424
1424
  providedIn: 'root'
@@ -1469,24 +1469,20 @@ class ActivityProducerService {
1469
1469
  this.destroyRef.onDestroy(() => this.stop());
1470
1470
  }
1471
1471
  /**
1472
- * Handles high-frequency events by applying a per-eventType throttle before calling onActivity.
1473
- *
1474
- * Difference with onActivity:
1475
- * - onActivityThrottled limits how often a given high-frequency event type (e.g. scroll) is processed
1476
- * (based on highFrequencyThrottleMs and lastEmitTimestamps)
1477
- * - onActivity updates the local activity signal and applies the global message throttle
1478
- * (based on global throttleMs and lastSentTimestamp)
1479
- * @param eventType The type of activity event that occurred
1480
- * @param configObject
1472
+ * Checks if a high-frequency event should be processed based on throttle timing.
1473
+ * This is called before shouldBroadcast to avoid expensive filter operations on every event.
1474
+ * @param eventType The type of activity event
1475
+ * @param throttleMs The throttle interval in milliseconds
1476
+ * @returns true if the event should be processed, false if it should be skipped
1481
1477
  */
1482
- onActivityThrottled(eventType, configObject) {
1478
+ shouldProcessHighFrequencyEvent(eventType, throttleMs) {
1483
1479
  const now = Date.now();
1484
1480
  const lastEmit = this.lastEmitTimestamps.get(eventType) ?? 0;
1485
- const throttleMs = configObject.highFrequencyThrottleMs;
1486
1481
  if (now - lastEmit >= throttleMs) {
1487
1482
  this.lastEmitTimestamps.set(eventType, now);
1488
- this.onActivity(eventType, configObject);
1483
+ return true;
1489
1484
  }
1485
+ return false;
1490
1486
  }
1491
1487
  /**
1492
1488
  * Handles activity by sending a throttled message and emitting to local signal.
@@ -1556,16 +1552,16 @@ class ActivityProducerService {
1556
1552
  if (eventType === 'keydown' && event instanceof KeyboardEvent && event.repeat) {
1557
1553
  return;
1558
1554
  }
1555
+ // For high-frequency events, apply throttle BEFORE shouldBroadcast
1556
+ // to avoid expensive filter operations on every event (e.g. reflows)
1557
+ if (isHighFrequency && !this.shouldProcessHighFrequencyEvent(eventType, configObject.highFrequencyThrottleMs)) {
1558
+ return;
1559
+ }
1559
1560
  // Apply filter if provided
1560
1561
  if (configObject.shouldBroadcast?.(event) === false) {
1561
1562
  return;
1562
1563
  }
1563
- if (isHighFrequency) {
1564
- this.onActivityThrottled(eventType, configObject);
1565
- }
1566
- else {
1567
- this.onActivity(eventType, configObject);
1568
- }
1564
+ this.onActivity(eventType, configObject);
1569
1565
  };
1570
1566
  this.boundListeners.set(eventType, listener);
1571
1567
  document.addEventListener(eventType, listener, { passive: true, capture: true });
@@ -1599,10 +1595,10 @@ class ActivityProducerService {
1599
1595
  this.lastEmitTimestamps.clear();
1600
1596
  this.iframeActivityTracker.stop();
1601
1597
  }
1602
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ActivityProducerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1603
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ActivityProducerService, providedIn: 'root' }); }
1598
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ActivityProducerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1599
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ActivityProducerService, providedIn: 'root' }); }
1604
1600
  }
1605
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ActivityProducerService, decorators: [{
1601
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ActivityProducerService, decorators: [{
1606
1602
  type: Injectable,
1607
1603
  args: [{
1608
1604
  providedIn: 'root'
@@ -1655,10 +1651,10 @@ class ActivityConsumerService {
1655
1651
  stop() {
1656
1652
  this.consumerManagerService.unregister(this);
1657
1653
  }
1658
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ActivityConsumerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1659
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ActivityConsumerService, providedIn: 'root' }); }
1654
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ActivityConsumerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1655
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ActivityConsumerService, providedIn: 'root' }); }
1660
1656
  }
1661
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ActivityConsumerService, decorators: [{
1657
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: ActivityConsumerService, decorators: [{
1662
1658
  type: Injectable,
1663
1659
  args: [{
1664
1660
  providedIn: 'root'
@@ -1 +1 @@
1
- {"version":3,"file":"ama-mfe-ng-utils.mjs","sources":["../../src/connect/connect-directive.ts","../../src/messages/available-sender.ts","../../src/messages/error-sender.ts","../../src/managers/producer-manager-service.ts","../../src/managers/consumer-manager-service.ts","../../src/managers/utils.ts","../../src/history/history-consumer-service.ts","../../src/history/history-providers.ts","../../src/host-info/host-info.ts","../../src/host-info/host-info-pipe.ts","../../src/messages/error/base.ts","../../src/messages/user-activity.ts","../../src/utils.ts","../../src/connect/connect-providers.ts","../../src/navigation/navigation-consumer-service.ts","../../src/navigation/route-memorize/route-memorize-service.ts","../../src/navigation/restore-route-pipe.ts","../../src/navigation/route-memorize/route-memorize-directive.ts","../../src/navigation/routing-service.ts","../../src/resize/resize-consumer-service.ts","../../src/resize/resize-producer-service.ts","../../src/resize/scalable-directive.ts","../../src/theme/theme-helpers.ts","../../src/theme/theme-producer-service.ts","../../src/theme/apply-theme-pipe.ts","../../src/theme/theme-consumer-service.ts","../../src/user-activity/config.ts","../../src/user-activity/iframe-activity-tracker.service.ts","../../src/user-activity/activity-producer.service.ts","../../src/user-activity/activity-consumer.service.ts","../../src/ama-mfe-ng-utils.ts"],"sourcesContent":["import {\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n computed,\n Directive,\n effect,\n ElementRef,\n HostBinding,\n inject,\n input,\n SecurityContext,\n} from '@angular/core';\nimport {\n DomSanitizer,\n SafeResourceUrl,\n} from '@angular/platform-browser';\nimport {\n LoggerService,\n} from '@o3r/logger';\n\n@Directive({\n selector: 'iframe[connect]',\n standalone: true\n})\nexport class ConnectDirective {\n /**\n * The connection ID required for the message peer service.\n */\n public connect = input.required<string>();\n\n /**\n * The sanitized source URL for the iframe.\n */\n public src = input<SafeResourceUrl>();\n\n /**\n * Binds the `src` attribute of the iframe to the sanitized source URL.\n */\n @HostBinding('src')\n public get srcAttr() {\n return this.src();\n }\n\n private readonly messageService = inject(MessagePeerService);\n private readonly domSanitizer = inject(DomSanitizer);\n private readonly iframeElement = inject<ElementRef<HTMLIFrameElement>>(ElementRef).nativeElement;\n\n private readonly clientOrigin = computed(() => {\n const src = this.src();\n const srcString = src && this.domSanitizer.sanitize(SecurityContext.RESOURCE_URL, src);\n return srcString && new URL(srcString).origin;\n });\n\n constructor() {\n const logger = inject(LoggerService);\n\n // When the origin or connection ID change - reconnect the message service\n effect((onCleanup) => {\n let stopHandshakeListening = () => { /* no op */ };\n\n const origin = this.clientOrigin();\n const id = this.connect();\n const source = this.iframeElement.contentWindow;\n\n // listen for handshakes only if we know the origin and were given a connection ID\n if (origin && source && id) {\n try {\n stopHandshakeListening = this.messageService.listen({ id, source, origin });\n } catch (e) {\n logger.error(`Failed to start listening for (connection ID: ${id})`, e);\n }\n }\n\n // stop listening for handshakes and disconnect previous connection when:\n // - origin/connection ID change\n // - the directive is destroyed\n onCleanup(() => {\n stopHandshakeListening();\n this.messageService.disconnect();\n });\n });\n }\n}\n","import type {\n DeclareMessages,\n} from '@amadeus-it-group/microfrontends';\nimport type {\n BasicMessageConsumer,\n} from '../managers/interfaces';\n\n/**\n * Gets the available consumers and formats them into a {@link DeclareMessages} object.\n * @param consumers - The list of registered message consumers.\n * @returns The formatted DeclareMessages object.\n */\nexport const getAvailableConsumers = (consumers: BasicMessageConsumer[]) => {\n return {\n type: 'declare_messages',\n version: '1.0',\n messages: consumers.flatMap(({ type, supportedVersions }) => Object.keys(supportedVersions).map((version) => ({ type, version })))\n } satisfies DeclareMessages;\n};\n","import type {\n VersionedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport type {\n MessagePeerServiceType,\n} from '@amadeus-it-group/microfrontends-angular';\nimport type {\n ERROR_MESSAGE_TYPE,\n ErrorContent,\n ErrorMessageV1_0,\n} from './error/index';\n\n/**\n * Helper function to send an error message by the given endpoint (peer)\n * @param peer The endpoint sending the message\n * @param content the content of the error message to be sent\n */\nexport const sendError = (peer: MessagePeerServiceType<any>, content: ErrorContent) => {\n return peer.send({\n type: 'error',\n version: '1.0',\n ...content\n } satisfies ErrorMessageV1_0);\n};\n\n/**\n * Check if the given message is of type error and the error reson is present too\n * @param message the message to be checked\n */\n// eslint-disable-next-line @stylistic/max-len -- constant definition\nexport const isErrorMessage = (message: any): message is VersionedMessage & { type: typeof ERROR_MESSAGE_TYPE } & ErrorContent => (message && typeof message === 'object' && message.type === 'error' && !!message.reason);\n","import type {\n VersionedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n Injectable,\n} from '@angular/core';\nimport type {\n ErrorContent,\n} from '../messages/index';\nimport type {\n MessageProducer,\n} from './interfaces';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class ProducerManagerService {\n private readonly registeredProducers = new Set<MessageProducer>();\n\n /** Get the list of registered producers of messages. The list will contain unique elements */\n public get producers() {\n return [...this.registeredProducers];\n }\n\n /**\n * Register a producer of a message\n * @param producer The instance of the message producer\n */\n public register(producer: MessageProducer) {\n this.registeredProducers.add((producer));\n }\n\n /**\n * Unregister a producer of a message\n * @param producer The instance of the message producer\n */\n public unregister(producer: MessageProducer) {\n this.registeredProducers.delete((producer));\n }\n\n /**\n * Handles the received error message for the given message type by invoking the appropriate producer handlers.\n * @template T - The type of the message, extending from Message.\n * @param message - The error message to handle.\n * @returns - A promise that resolves to true if the error was handled by at least one handler, false otherwise.\n */\n public async dispatchError<T extends VersionedMessage = VersionedMessage>(message: ErrorContent<T>) {\n const handlers = this.producers\n .filter(({ types }) => (Array.isArray(types) ? types : [types]).includes(message.source.type));\n\n const handlersPresent = handlers.length > 0;\n if (handlersPresent) {\n await Promise.all(\n // eslint-disable-next-line @typescript-eslint/await-thenable -- `handleError` can return void or Promise<void>\n handlers.map((handler) => handler.handleError(message))\n );\n }\n return handlersPresent;\n }\n}\n","import {\n RoutedMessage,\n VersionedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n effect,\n inject,\n Injectable,\n signal,\n} from '@angular/core';\nimport {\n takeUntilDestroyed,\n} from '@angular/core/rxjs-interop';\nimport {\n LoggerService,\n} from '@o3r/logger';\nimport {\n getAvailableConsumers,\n} from '../messages/available-sender';\nimport {\n isErrorMessage,\n sendError,\n} from '../messages/error-sender';\nimport type {\n BasicMessageConsumer,\n} from './interfaces';\nimport {\n ProducerManagerService,\n} from './producer-manager-service';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class ConsumerManagerService {\n private readonly messageService = inject(MessagePeerService);\n private readonly producerManagerService = inject(ProducerManagerService);\n private readonly registeredConsumers = signal<BasicMessageConsumer[]>([]);\n private readonly logger = inject(LoggerService);\n\n /** The list of registered consumers */\n public readonly consumers = this.registeredConsumers.asReadonly();\n\n constructor() {\n this.messageService.messages$.pipe(takeUntilDestroyed()).subscribe((message) => this.consumeMessage(message));\n\n // Each time a consumer is registered/unregistered update the list of registered messages\n effect(() => {\n const declareMessages = getAvailableConsumers(this.consumers());\n\n // registering consumed messages locally for validation\n for (const message of declareMessages.messages) {\n this.messageService.registerMessage(message);\n }\n });\n }\n\n /**\n * Consume a received message\n * @param message the received message body\n */\n private async consumeMessage(message: RoutedMessage<VersionedMessage>) {\n if (isErrorMessage(message.payload)) {\n const isHandled = await this.producerManagerService.dispatchError(message.payload);\n if (!isHandled) {\n this.logger.warn('Error message not handled', message);\n }\n return;\n }\n\n return this.consumeAdditionalMessage(message);\n }\n\n /**\n * Call the registered message callback(s) to consume the given message\n * Handle error messages of internal communication protocol messages\n * @param message message to consume\n */\n private async consumeAdditionalMessage(message: RoutedMessage<VersionedMessage>) {\n if (!message.payload) {\n this.logger.warn('Cannot consume a messages with undefined payload.');\n return;\n }\n\n const consumers = this.consumers();\n const typeMatchingConsumers = consumers\n .filter((consumer) => consumer.type === message.payload.type);\n\n if (typeMatchingConsumers.length === 0) {\n this.logger.warn(`No consumer found for message type: ${message.payload.type}`);\n return sendError(this.messageService, { reason: 'unknown_type', source: message.payload });\n }\n\n const versionMatchingConsumers = typeMatchingConsumers\n .filter((consumer) => consumer.supportedVersions[message.payload.version])\n .flat();\n\n if (versionMatchingConsumers.length === 0) {\n this.logger.warn(`No consumer found for message version: ${message.payload.version}`);\n return sendError(this.messageService, { reason: 'version_mismatch', source: message.payload });\n }\n\n await Promise.all(\n versionMatchingConsumers\n .map(async (consumer) => {\n try {\n await consumer.supportedVersions[message.payload.version](message);\n } catch (error) {\n this.logger.error('Error while consuming message', error);\n sendError(this.messageService, { reason: 'internal_error', source: message.payload });\n }\n })\n );\n }\n\n /**\n * Register a message consumer\n * @param consumer an instance of message consumer\n */\n public register(consumer: BasicMessageConsumer) {\n this.registeredConsumers.update((consumers) => {\n return [...new Set(consumers).add(consumer)];\n });\n }\n\n /**\n * Unregister a message consumer\n * @param consumer an instance of message consumer\n */\n public unregister(consumer: BasicMessageConsumer) {\n this.registeredConsumers.update((consumers) => {\n return consumers.filter((c) => c !== consumer);\n });\n }\n}\n","import {\n DestroyRef,\n inject,\n} from '@angular/core';\nimport {\n ConsumerManagerService,\n} from './consumer-manager-service';\nimport type {\n MessageConsumer,\n MessageProducer,\n} from './interfaces';\nimport {\n ProducerManagerService,\n} from './producer-manager-service';\n\n/**\n * Method to call in the constructor of a producer\n * @note should be used in injection context\n * @param producer\n */\nexport const registerProducer = (producer: MessageProducer) => {\n const producerManagerService = inject(ProducerManagerService);\n producerManagerService.register(producer);\n\n inject(DestroyRef).onDestroy(() => {\n producerManagerService.unregister(producer);\n });\n};\n\n/**\n * Method to call in the constructor of a consumer\n * @note should be used in injection context\n * @param consumer\n */\nexport const registerConsumer = (consumer: MessageConsumer) => {\n const consumerManagerService = inject(ConsumerManagerService);\n consumerManagerService.register(consumer);\n\n inject(DestroyRef).onDestroy(() => {\n consumerManagerService.unregister(consumer);\n });\n};\n","import type {\n HistoryMessage,\n HistoryV1_0,\n} from '@ama-mfe/messages';\nimport {\n HISTORY_MESSAGE_TYPE,\n} from '@ama-mfe/messages';\nimport type {\n RoutedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n DestroyRef,\n inject,\n Injectable,\n} from '@angular/core';\nimport {\n ConsumerManagerService,\n type MessageConsumer,\n} from '../managers/index';\n\n/**\n * A service that handles history messages.\n *\n * This service listens for history messages and navigates accordingly.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class HistoryConsumerService implements MessageConsumer<HistoryMessage> {\n /**\n * The type of messages this service handles.\n */\n public readonly type = HISTORY_MESSAGE_TYPE;\n\n /**\n * @inheritdoc\n */\n public readonly supportedVersions = {\n /**\n * Use the message payload to navigate in the history\n * @param message message to consume\n */\n '1.0': (message: RoutedMessage<HistoryV1_0>) => {\n history.go(message.payload.delta);\n }\n };\n\n private readonly consumerManagerService = inject(ConsumerManagerService);\n\n constructor() {\n this.start();\n inject(DestroyRef).onDestroy(() => this.stop());\n }\n\n /**\n * @inheritdoc\n */\n public start() {\n this.consumerManagerService.register(this);\n }\n\n /**\n * @inheritdoc\n */\n public stop() {\n this.consumerManagerService.unregister(this);\n }\n}\n","import {\n HistoryMessage,\n HistoryV1_0,\n} from '@ama-mfe/messages';\nimport {\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n inject,\n provideAppInitializer,\n} from '@angular/core';\n\n/**\n * Provides necessary overrides to make the module navigation in history work in an embedded context :\n * - Prevent pushing states to history, replace state instead\n * - Handle history navigation via History messages to let the host manage the states\n */\nexport function provideHistoryOverrides() {\n return provideAppInitializer(() => {\n const messageService = inject(MessagePeerService<HistoryMessage>);\n const navigate = (delta: number) => {\n messageService.send({\n type: 'history',\n version: '1.0',\n delta\n } satisfies HistoryV1_0);\n };\n Object.defineProperty(history, 'pushState', {\n value: (data: any, unused: string, url?: string | URL | null) => {\n history.replaceState(data, unused, url);\n },\n writable: false,\n configurable: false\n });\n Object.defineProperty(history, 'back', {\n value: () => navigate(-1),\n writable: false,\n configurable: false\n });\n Object.defineProperty(history, 'forward', {\n value: () => navigate(1),\n writable: false,\n configurable: false\n });\n Object.defineProperty(history, 'go', {\n value: (delta: number) => navigate(delta),\n writable: false,\n configurable: false\n });\n });\n}\n","const SESSION_STORAGE_KEY = 'ama-mfe-host-info';\n\n/**\n * Search parameter to add to the URL when embedding an iframe containing the URL of the host.\n * This is needed to support Firefox (on which {@link https://developer.mozilla.org/docs/Web/API/Location/ancestorOrigins | location.ancestorOrigins} is not currently supported)\n * in case of redirection inside the iframe.\n */\nexport const MFE_HOST_URL_PARAM = 'ama-mfe-host-url';\n\n/**\n * Search parameter to add to the URL to let a module know on which application it's embedded\n */\nexport const MFE_HOST_APPLICATION_ID_PARAM = 'ama-mfe-host-app-id';\n\n/**\n * Search parameter to add to the URL to identify the application in the network of peers in the communication protocol\n */\nexport const MFE_MODULE_APPLICATION_ID_PARAM = 'ama-mfe-module-app-id';\n\n/** The list of query parameters which can be set by the host */\nexport const hostQueryParams = [MFE_HOST_URL_PARAM, MFE_HOST_APPLICATION_ID_PARAM, MFE_MODULE_APPLICATION_ID_PARAM];\n\n/**\n * Information set up at host level to use in embedded context\n */\nexport interface MFEHostInformation {\n /**\n * URL of the host application\n */\n hostURL?: string;\n /**\n * ID of the host application\n */\n hostApplicationId?: string;\n\n /**\n * ID of the module to embed defined at host level\n */\n moduleApplicationId?: string;\n}\n\n/**\n * Gather the host information from the url parameters\n * The host url will use the first found among:\n * - look for the search parameter {@link MFE_HOST_URL_PARAM} in the URL of the iframe\n * - use the first item in `location.ancestorOrigins` (currently not supported on Firefox)\n * - use `document.referrer` (will only work if called before any redirection in the iframe)\n * The host application ID is taken from the search parameter {@link MFE_HOST_APPLICATION_ID_PARAM} in the URL of the iframe\n * The module application ID is taken from the search parameter {@link MFE_APPLICATION_ID_PARAM} in the URL of the iframe\n * @param locationParam - A {@link Location} object with information about the current location of the document. Defaults to global {@link location}.\n */\nexport function getHostInfo(locationParam: Location = location): MFEHostInformation {\n const searchParams = new URLSearchParams(locationParam.search);\n const storedHostInfo = JSON.parse(sessionStorage.getItem(SESSION_STORAGE_KEY) || '{}') as MFEHostInformation;\n return {\n hostURL: searchParams.get(MFE_HOST_URL_PARAM) || storedHostInfo.hostURL || locationParam.ancestorOrigins?.[0] || document.referrer,\n hostApplicationId: searchParams.get(MFE_HOST_APPLICATION_ID_PARAM) || storedHostInfo.hostApplicationId,\n moduleApplicationId: searchParams.get(MFE_MODULE_APPLICATION_ID_PARAM) || storedHostInfo.moduleApplicationId\n };\n}\n\n/**\n * Gather the host information from the url parameters and handle the persistence in session storage.\n */\nexport function persistHostInfo() {\n const hostInfo = getHostInfo();\n sessionStorage.setItem(SESSION_STORAGE_KEY, JSON.stringify(hostInfo));\n}\n","import {\n inject,\n Pipe,\n PipeTransform,\n SecurityContext,\n} from '@angular/core';\nimport {\n DomSanitizer,\n type SafeResourceUrl,\n} from '@angular/platform-browser';\nimport {\n MFE_HOST_APPLICATION_ID_PARAM,\n MFE_HOST_URL_PARAM,\n MFE_MODULE_APPLICATION_ID_PARAM,\n} from './host-info';\n\n/**\n * A pipe that adds the host information in the URL of an iframe,\n */\n@Pipe({\n name: 'hostInfo'\n})\nexport class HostInfoPipe implements PipeTransform {\n private readonly domSanitizer = inject(DomSanitizer);\n\n /**\n * Transforms the given URL or SafeResourceUrl by appending query parameters.\n * @param url - The URL or SafeResourceUrl to be transformed.\n * @param options - hostId and moduleId\n * @returns - The transformed SafeResourceUrl or undefined if the input URL is invalid.\n */\n public transform(url: string, options: { hostId: string; moduleId?: string }): string;\n public transform(url: SafeResourceUrl, options: { hostId: string; moduleId?: string }): SafeResourceUrl;\n public transform(url: undefined, options: { hostId: string; moduleId?: string }): undefined;\n public transform(url: string | SafeResourceUrl | undefined, options: { hostId: string; moduleId?: string }): string | SafeResourceUrl | undefined {\n const urlString = typeof url === 'string'\n ? url\n : this.domSanitizer.sanitize(SecurityContext.RESOURCE_URL, url || null);\n\n if (!url) {\n return undefined;\n }\n\n if (urlString) {\n const moduleUrl = new URL(urlString);\n moduleUrl.searchParams.set(MFE_HOST_URL_PARAM, window.location.origin);\n moduleUrl.searchParams.set(MFE_HOST_APPLICATION_ID_PARAM, options.hostId);\n if (options.moduleId) {\n moduleUrl.searchParams.set(MFE_MODULE_APPLICATION_ID_PARAM, options.moduleId);\n }\n\n const moduleUrlStringyfied = moduleUrl.toString();\n return typeof url === 'string' ? moduleUrlStringyfied : this.domSanitizer.bypassSecurityTrustResourceUrl(moduleUrlStringyfied);\n }\n }\n}\n","import type {\n VersionedMessage,\n} from '@amadeus-it-group/microfrontends';\n\n/** the error message type */\nexport const ERROR_MESSAGE_TYPE = 'error';\n\n/**\n * The possible reasons for an error.\n */\nexport type ErrorReason = 'unknown_type' | 'version_mismatch' | 'internal_error';\n\n/**\n * The content of an error message.\n * @template S - The type of the source message.\n */\nexport interface ErrorContent<S extends VersionedMessage = VersionedMessage> {\n /** The reason for the error */\n reason: ErrorReason;\n /** The source message that caused the error */\n source: S;\n}\n","import {\n USER_ACTIVITY_MESSAGE_TYPE,\n type UserActivityMessage,\n} from '@ama-mfe/messages';\n\n/**\n * Type guard to check if a message is a user activity message\n * @param message The message to check\n */\nexport function isUserActivityMessage(message: unknown): message is UserActivityMessage {\n return (\n typeof message === 'object'\n && message !== null\n && 'type' in message\n && message.type === USER_ACTIVITY_MESSAGE_TYPE\n );\n}\n","import type {\n Message,\n PeerConnectionOptions,\n} from '@amadeus-it-group/microfrontends';\nimport {\n getHostInfo,\n} from './host-info';\nimport {\n ERROR_MESSAGE_TYPE,\n} from './messages';\n\n/**\n * A constant array of known message types and their versions.\n */\nexport const KNOWN_MESSAGES = [\n {\n type: ERROR_MESSAGE_TYPE,\n version: '1.0'\n }\n] as const satisfies Message[];\n\n/**\n * Returns the default options for starting a client endpoint peer connection.\n * As `origin`, it will take the hostURL from {@link getHostInfo} and the `window` will be the parent window.\n */\nexport function getDefaultClientEndpointStartOptions(): PeerConnectionOptions {\n const hostInfo = getHostInfo();\n if (hostInfo.hostURL) {\n return {\n origin: new URL(hostInfo.hostURL).origin,\n window: window.parent\n };\n }\n return {};\n}\n\n/**\n * Return `true` if embedded inside an iframe, `false` otherwise\n * @param windowParam - A {@link window} object with information about the current window of the document. Defaults to global {@link window}.\n */\nexport function isEmbedded(windowParam: Window = window) {\n return windowParam.top !== windowParam.self;\n}\n","import {\n MESSAGE_PEER_CONFIG,\n MESSAGE_PEER_CONNECT_OPTIONS,\n MessagePeerConfig,\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n makeEnvironmentProviders,\n} from '@angular/core';\nimport {\n type Logger,\n} from '@o3r/logger';\nimport {\n provideHistoryOverrides,\n} from '../history';\nimport {\n getHostInfo,\n persistHostInfo,\n} from '../host-info';\nimport {\n getDefaultClientEndpointStartOptions,\n isEmbedded,\n KNOWN_MESSAGES,\n} from '../utils';\nimport {\n ConnectionConfig,\n ConnectionService,\n} from './connect-resources';\n\n/** Options to configure the connection inside the communication protocol */\nexport interface ConnectionConfigOptions extends Omit<ConnectionConfig, 'id'> {\n /** @inheritdoc */\n id?: string;\n /** Logger used to gather information */\n logger?: Logger;\n}\n\n/**\n * Provide the communication protocol connection configuration\n * @param connectionConfigOptions The identifier of the application in the communication protocol ecosystem plus the types of messages able to exchange and a logger object\n */\nexport function provideConnection(connectionConfigOptions?: ConnectionConfigOptions) {\n persistHostInfo();\n const connectionId = (isEmbedded() && getHostInfo().moduleApplicationId) || connectionConfigOptions?.id;\n if (!connectionId) {\n (connectionConfigOptions?.logger || console).error('An id (moduleId) needs to be provided for the application in order to establish a connection inside the communication protocol');\n return makeEnvironmentProviders([]);\n }\n const config: MessagePeerConfig = {\n id: connectionId,\n messageCheckStrategy: 'version',\n knownMessages: [...KNOWN_MESSAGES, ...(connectionConfigOptions?.knownMessages || [])]\n };\n return makeEnvironmentProviders([\n {\n provide: MESSAGE_PEER_CONFIG, useValue: config\n },\n {\n provide: MESSAGE_PEER_CONNECT_OPTIONS, useValue: getDefaultClientEndpointStartOptions()\n },\n {\n // in the case of the ConnectionService will extend the base service 'useExisting' should be used\n provide: MessagePeerService, useClass: ConnectionService, deps: [MESSAGE_PEER_CONFIG]\n },\n ...isEmbedded() ? [provideHistoryOverrides()] : []\n ]);\n}\n","import {\n NAVIGATION_MESSAGE_TYPE,\n} from '@ama-mfe/messages';\nimport type {\n NavigationMessage,\n NavigationV1_0,\n} from '@ama-mfe/messages';\nimport type {\n RoutedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n DestroyRef,\n inject,\n Injectable,\n} from '@angular/core';\nimport {\n ActivatedRoute,\n Router,\n} from '@angular/router';\nimport {\n Subject,\n} from 'rxjs';\nimport {\n hostQueryParams,\n} from '../host-info';\nimport {\n ConsumerManagerService,\n type MessageConsumer,\n} from '../managers/index';\n\n/**\n * A service that handles navigation messages and routing.\n *\n * This service listens for navigation messages and updates the router state accordingly.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class NavigationConsumerService implements MessageConsumer<NavigationMessage> {\n private readonly router = inject(Router);\n private readonly activeRoute = inject(ActivatedRoute);\n private readonly requestedUrl = new Subject<{ url: string; channelId?: string }>();\n\n /**\n * An observable that emits the requested URL and optional channel ID.\n */\n public readonly requestedUrl$ = this.requestedUrl.asObservable();\n\n /**\n * The type of messages this service handles.\n */\n public readonly type = NAVIGATION_MESSAGE_TYPE;\n\n /**\n * @inheritdoc\n */\n public readonly supportedVersions = {\n /**\n * Use the message paylod to compute a new url and emit it via the public subject\n * Additionally navigate to the new url\n * @param message message to consume\n */\n '1.0': (message: RoutedMessage<NavigationV1_0>) => {\n const channelId = message.from || undefined;\n this.requestedUrl.next({ url: message.payload.url, channelId });\n this.navigate(message.payload.url);\n }\n };\n\n private readonly consumerManagerService = inject(ConsumerManagerService);\n\n constructor() {\n this.start();\n inject(DestroyRef).onDestroy(() => this.stop());\n }\n\n /**\n * Parses a URL and returns an object containing the paths and query parameters.\n * @param url - The URL to parse.\n * @returns An object containing the paths and query parameters.\n */\n private parseUrl(url: string): { paths: string[]; queryParams: { [key: string]: string } } {\n const urlObject = new URL(window.origin + url);\n const paths = urlObject.pathname.split('/').filter((segment) => !!segment);\n const queryParams = Object.fromEntries(urlObject.searchParams.entries());\n return { paths, queryParams };\n }\n\n /**\n * Navigates to the specified URL.\n * @param url - The URL to navigate to.\n */\n private navigate(url: string) {\n const { paths, queryParams } = this.parseUrl(url);\n // No need to keep these in the URL\n hostQueryParams.forEach((key) => delete queryParams[key]);\n void this.router.navigate(paths, { relativeTo: this.activeRoute.children.at(-1), queryParams });\n }\n\n /**\n * @inheritdoc\n */\n public start() {\n this.consumerManagerService.register(this);\n }\n\n /**\n * @inheritdoc\n */\n public stop() {\n this.consumerManagerService.unregister(this);\n }\n}\n","import {\n Injectable,\n} from '@angular/core';\n\n/**\n * This service allows routes to be memorized with an optional lifetime and provides methods to retrieve and manage these routes.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class RouteMemorizeService {\n private readonly routeTimers: { [x: string]: ReturnType<typeof setTimeout> } = {};\n /** All memorized routes */\n public readonly routeStack: { [x: string]: string } = {};\n\n /**\n * Memorizes a route for a given channel ID with an optional lifetime.\n * @param channelId - The ID of the channel to memorize the route for.\n * @param url - The URL of the route to memorize.\n * @param liveTime - The optional lifetime of the memorized route in milliseconds. If provided, the route will be removed after this time.\n */\n public memorizeRoute(channelId: string, url: string, liveTime?: number): void {\n this.routeStack[channelId] = url;\n\n const timerRef = this.routeTimers[channelId];\n if (timerRef) {\n clearTimeout(timerRef);\n }\n if (liveTime && liveTime > 0) {\n this.routeTimers[channelId] = setTimeout(() => {\n delete this.routeStack[channelId];\n delete this.routeTimers[channelId];\n }, liveTime);\n }\n }\n\n /**\n * Retrieves the memorized route for a given channel ID.\n * @param channelId - The ID of the channel to retrieve the memorized route for.\n * @returns The memorized route URL or undefined if no route is memorized for the given channel ID.\n */\n public getRoute(channelId: string): string | undefined {\n return this.routeStack[channelId];\n }\n}\n","import {\n inject,\n Pipe,\n PipeTransform,\n SecurityContext,\n} from '@angular/core';\nimport {\n DomSanitizer,\n type SafeResourceUrl,\n} from '@angular/platform-browser';\nimport {\n ActivatedRoute,\n} from '@angular/router';\nimport {\n RouteMemorizeService,\n} from './route-memorize/route-memorize-service';\n\n/**\n * Options for restoring a route with optional query parameters and memory channel ID.\n */\nexport interface RestoreRouteOptions {\n /**\n * Whether to propagate query parameters from the top window to the module URL.\n */\n propagateQueryParams?: boolean;\n\n /**\n * Whether to override existing query parameters in the module URL with those from the top window.\n */\n overrideQueryParams?: boolean;\n\n /**\n * The memory channel ID used to retrieve the memorized route.\n * If provided, the memorized route associated with this ID will be used.\n */\n memoryChannelId?: string;\n}\n\n/**\n * A pipe that restores a route with optional query parameters and memory channel ID.\n *\n * This pipe is used to transform a URL or SafeResourceUrl by appending query parameters\n * and adjusting the pathname based on the current active route and memorized route.\n */\n@Pipe({\n name: 'restoreRoute'\n})\nexport class RestoreRoute implements PipeTransform {\n private readonly activeRoute = inject(ActivatedRoute);\n private readonly domSanitizer = inject(DomSanitizer);\n private readonly routeMemorizeService = inject(RouteMemorizeService, { optional: true });\n private readonly window = inject(Window, { optional: true }) || window;\n\n /**\n * Transforms the given URL or SafeResourceUrl by appending query parameters and adjusting the pathname.\n * @param url - The URL or SafeResourceUrl to be transformed.\n * @param options - Optional parameters to control the transformation. {@link RestoreRouteOptions}\n * @returns - The transformed SafeResourceUrl or undefined if the input URL is invalid.\n */\n public transform(url: string, options?: Partial<RestoreRouteOptions>): string;\n public transform(url: SafeResourceUrl, options?: Partial<RestoreRouteOptions>): SafeResourceUrl;\n public transform(url: undefined, options?: Partial<RestoreRouteOptions>): undefined;\n public transform(url: string | SafeResourceUrl | undefined, options?: Partial<RestoreRouteOptions>): string | SafeResourceUrl | undefined {\n const urlString = typeof url === 'string'\n ? url\n : this.domSanitizer.sanitize(SecurityContext.RESOURCE_URL, url || null);\n\n if (!url) {\n return undefined;\n }\n\n if (urlString) {\n const moduleUrl = new URL(urlString);\n const queryParamsModule = new URLSearchParams(moduleUrl.searchParams);\n\n const channelId = options?.memoryChannelId;\n const memorizedRoute = channelId && this.routeMemorizeService?.getRoute(channelId);\n const topWindowUrl = new URL(memorizedRoute ? this.window.origin + memorizedRoute : this.window.location.href);\n const queryParamsTopWindow = new URLSearchParams(topWindowUrl.search);\n\n if (options?.propagateQueryParams) {\n for (const [key, value] of queryParamsTopWindow) {\n if (options?.overrideQueryParams || !queryParamsModule.has(key)) {\n queryParamsModule.set(key, value);\n }\n }\n }\n moduleUrl.search = queryParamsModule.toString();\n moduleUrl.pathname += topWindowUrl.pathname.split(`/${this.activeRoute.routeConfig?.path}`).pop() || '';\n moduleUrl.pathname = moduleUrl.pathname.replace(/\\/{2,}/g, '/');\n const moduleUrlStringyfied = moduleUrl.toString();\n return typeof url === 'string' ? moduleUrlStringyfied : this.domSanitizer.bypassSecurityTrustResourceUrl(moduleUrlStringyfied);\n }\n }\n}\n","import {\n computed,\n Directive,\n effect,\n inject,\n input,\n untracked,\n} from '@angular/core';\nimport {\n toSignal,\n} from '@angular/core/rxjs-interop';\nimport {\n NavigationConsumerService,\n} from '../navigation-consumer-service';\nimport {\n RouteMemorizeService,\n} from './route-memorize-service';\n\n@Directive({\n selector: 'iframe[memorizeRoute]',\n standalone: true\n})\nexport class RouteMemorizeDirective {\n /**\n * Whether to memorize the route.\n * Default is true.\n */\n public memorizeRoute = input<boolean | undefined | ''>(true);\n\n /**\n * The ID used to memorize the route.\n */\n public memorizeRouteId = input<string>();\n\n /**\n * The maximum age for memorizing the route.\n * Default is 0.\n */\n public memorizeMaxAge = input<number>(0);\n\n /**\n * The maximum age for memorizing the route, used as a fallback.\n * Default is 0.\n */\n public memorizeRouteMaxAge = input<number>(0);\n\n /**\n * The connection ID for the iframe where the actual directive is applied.\n */\n public connect = input<string>();\n\n private readonly maxAge = computed(() => {\n return this.memorizeMaxAge() || this.memorizeRouteMaxAge();\n });\n\n constructor() {\n const memory = inject(RouteMemorizeService);\n const requestedUrlSignal = toSignal(inject(NavigationConsumerService).requestedUrl$);\n\n /**\n * This effect listens for changes in the `memorizeRoute`, `requestedUrlSignal`, and `memorizeRouteId` or `connect` inputs.\n * If `memorizeRoute` is not false and a requested URL with a matching channel ID is found, it memorizes the route using the route memory service.\n */\n effect(() => {\n const memorizeRoute = this.memorizeRoute();\n if (memorizeRoute === false) {\n return;\n }\n const requested = requestedUrlSignal();\n const channelId = this.connect();\n const id = this.memorizeRouteId() || channelId;\n if (requested && id && requested.channelId === channelId) {\n memory.memorizeRoute(id, requested.url, untracked(this.maxAge));\n }\n });\n }\n}\n","import type {\n NavigationMessage,\n NavigationV1_0,\n} from '@ama-mfe/messages';\nimport {\n NAVIGATION_MESSAGE_TYPE,\n} from '@ama-mfe/messages';\nimport type {\n RoutedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n inject,\n Injectable,\n} from '@angular/core';\nimport {\n takeUntilDestroyed,\n} from '@angular/core/rxjs-interop';\nimport {\n ActivatedRoute,\n NavigationEnd,\n Router,\n} from '@angular/router';\nimport {\n LoggerService,\n} from '@o3r/logger';\nimport {\n filter,\n map,\n} from 'rxjs';\nimport {\n type MessageConsumer,\n type MessageProducer,\n registerConsumer,\n registerProducer,\n} from '../managers/index';\nimport {\n type ErrorContent,\n} from '../messages/error';\nimport {\n isEmbedded,\n} from '../utils';\n\n/** Options for the routing handling in case of navigation producer message */\nexport interface RoutingServiceOptions {\n /**\n * Whether to handle only sub-routes.\n * If true, the routing service will handle only sub-routes.\n * Default is false.\n */\n subRouteOnly?: boolean;\n}\n\n/**\n * A service that keeps in sync Router navigation and navigation messages.\n *\n * - listens to Router events and sends navigation messages\n * - handles incoming navigation messages and triggers Router navigation\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class RoutingService implements MessageProducer<NavigationMessage>, MessageConsumer<NavigationMessage> {\n private readonly router = inject(Router);\n private readonly activatedRoute = inject(ActivatedRoute);\n private readonly messageService = inject(MessagePeerService<NavigationMessage>);\n private readonly logger = inject(LoggerService);\n private readonly window = inject(Window, { optional: true }) || window;\n\n /**\n * @inheritdoc\n */\n public readonly types = NAVIGATION_MESSAGE_TYPE;\n\n /**\n * @inheritdoc\n */\n public readonly type = 'navigation';\n\n /**\n * Use the message payload to navigate to the specified URL.\n * @param message message to consume\n */\n public readonly supportedVersions = {\n '1.0': async (message: RoutedMessage<any>) => {\n await this.router.navigateByUrl(message.payload.url);\n }\n };\n\n constructor() {\n registerProducer(this);\n registerConsumer(this);\n }\n\n /**\n * @inheritdoc\n */\n public start(): void {}\n\n /**\n * @inheritdoc\n */\n public stop(): void {}\n\n /**\n * @inheritdoc\n */\n public handleError(message: ErrorContent<NavigationV1_0>): void {\n this.logger.error('Error in navigation service message', message);\n }\n\n /**\n * Handles embedded routing by listening to router events and sending navigation messages to the connected endpoints.\n * It can be a parent window or another iframe\n * @note - This method has to be called in an injection context\n * @param options - Optional parameters to control the routing behavior {@link RoutingServiceOptions}.\n */\n public handleEmbeddedRouting(options?: RoutingServiceOptions): void {\n const subRouteOnly = options?.subRouteOnly ?? false;\n this.router.events.pipe(\n takeUntilDestroyed(),\n filter((event): event is NavigationEnd => event instanceof NavigationEnd),\n filter((_event) => !this.router.getCurrentNavigation()?.extras?.skipLocationChange),\n map(({ urlAfterRedirects }) => {\n const channelId = this.router.getCurrentNavigation()?.extras?.state?.channelId;\n const currentRouteRegExp = subRouteOnly && this.activatedRoute.routeConfig?.path && new RegExp('^' + this.activatedRoute.routeConfig.path.replace(/(?=\\W)/g, '\\\\'), 'i');\n return ({ url: currentRouteRegExp ? urlAfterRedirects.replace(currentRouteRegExp, '') : urlAfterRedirects, channelId });\n })\n ).subscribe(({ url, channelId }) => {\n const messageV10 = {\n type: 'navigation',\n version: '1.0',\n url\n } satisfies NavigationV1_0;\n // TODO: sendBest() is not implemented -- https://github.com/AmadeusITGroup/microfrontends/issues/11\n if (isEmbedded(this.window)) {\n this.messageService.send(messageV10);\n } else {\n if (channelId === undefined) {\n this.logger.warn('No channelId provided for navigation message');\n } else {\n try {\n this.messageService.send(messageV10, { to: [channelId] });\n } catch (error) {\n this.logger.error('Error sending navigation message', error);\n }\n }\n }\n });\n }\n}\n","import type {\n ResizeMessage,\n ResizeV1_0,\n} from '@ama-mfe/messages';\nimport {\n RESIZE_MESSAGE_TYPE,\n} from '@ama-mfe/messages';\nimport type {\n RoutedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n DestroyRef,\n inject,\n Injectable,\n signal,\n} from '@angular/core';\nimport {\n ConsumerManagerService,\n MessageConsumer,\n} from '../managers/index';\n\n/**\n * This service listens for resize messages and updates the height of elements based on the received messages.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ResizeConsumerService implements MessageConsumer<ResizeMessage> {\n private readonly newHeight = signal<{ height: number; channelId: string } | undefined>(undefined);\n\n /**\n * A readonly signal that provides the new height information from the channel.\n */\n public readonly newHeightFromChannel = this.newHeight.asReadonly();\n\n /**\n * The type of messages this service handles ('resize').\n */\n public readonly type = RESIZE_MESSAGE_TYPE;\n\n /**\n * The supported versions of resize messages and their handlers.\n */\n public supportedVersions = {\n /**\n * Use the message paylod to compute a new height and emit it via the public signal\n * @param message message to consume\n */\n '1.0': (message: RoutedMessage<ResizeV1_0>) => this.newHeight.set({ height: message.payload.height, channelId: message.from })\n };\n\n private readonly consumerManagerService = inject(ConsumerManagerService);\n\n constructor() {\n this.start();\n inject(DestroyRef).onDestroy(() => this.stop());\n }\n\n /**\n * Starts the resize handler service by registering it into the consumer manager service.\n */\n public start() {\n this.consumerManagerService.register(this);\n }\n\n /**\n * Stops the resize handler service by unregistering it from the consumer manager service.\n */\n public stop() {\n this.consumerManagerService.unregister(this);\n }\n}\n","import type {\n ResizeMessage,\n ResizeV1_0,\n} from '@ama-mfe/messages';\nimport {\n RESIZE_MESSAGE_TYPE,\n} from '@ama-mfe/messages';\nimport {\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n afterNextRender,\n inject,\n Injectable,\n} from '@angular/core';\nimport {\n type MessageProducer,\n registerProducer,\n} from '../managers/index';\nimport {\n type ErrorContent,\n} from '../messages/index';\n\n/**\n * This service observe changes in the document's body height.\n * When the height changes, it sends a resize message with the new height, to the connected peers\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ResizeService implements MessageProducer<ResizeMessage> {\n private actualHeight?: number;\n private readonly messageService = inject(MessagePeerService<ResizeMessage>);\n private resizeObserver?: ResizeObserver;\n\n /**\n * @inheritdoc\n */\n public readonly types = RESIZE_MESSAGE_TYPE;\n\n constructor() {\n registerProducer(this);\n }\n\n /**\n * @inheritdoc\n */\n public handleError(message: ErrorContent<ResizeMessage>): void {\n // eslint-disable-next-line no-console -- error handling placeholder\n console.error('Error in resize service message', message);\n }\n\n /**\n * This method sets up a `ResizeObserver` to observe changes in the document's body height.\n * When the height changes, it sends a resize message with the new height, to the connected peers\n */\n public startResizeObserver() {\n this.resizeObserver = new ResizeObserver(() => {\n const newHeight = document.body.getBoundingClientRect().height;\n if (!this.actualHeight || newHeight !== this.actualHeight) {\n this.actualHeight = newHeight;\n const messageV10 = {\n type: 'resize',\n version: '1.0',\n height: this.actualHeight\n } satisfies ResizeV1_0;\n // TODO: sendBest() is not implemented -- https://github.com/AmadeusITGroup/microfrontends/issues/11\n this.messageService.send(messageV10);\n }\n });\n\n afterNextRender(() => this.resizeObserver?.observe(document.body));\n }\n}\n","import {\n computed,\n Directive,\n effect,\n ElementRef,\n inject,\n input,\n Renderer2,\n} from '@angular/core';\nimport {\n ResizeConsumerService,\n} from './resize-consumer-service';\n\n/**\n * A directive that adjusts the height of an element based on resize messages from a specified channel.\n */\n@Directive({\n selector: '[scalable]',\n standalone: true\n})\nexport class ScalableDirective {\n /**\n * The connection ID for the element, used as channel id backup\n */\n public connect = input<string>();\n\n /**\n * The channel id\n */\n public scalable = input<string>();\n\n private readonly resizeHandler = inject(ResizeConsumerService);\n\n /**\n * This signal checks if the current channel requesting the resize matches the channel ID from the resize handler.\n * If they match, it returns the new height information; otherwise, it returns undefined.\n */\n private readonly newHeightFromChannel = computed(() => {\n const channelAskingResize = this.scalable() || this.connect();\n const newHeightFromChannel = this.resizeHandler.newHeightFromChannel();\n if (channelAskingResize && newHeightFromChannel?.channelId === channelAskingResize) {\n return newHeightFromChannel;\n }\n return undefined;\n });\n\n constructor() {\n const elem = inject(ElementRef);\n const renderer = inject(Renderer2);\n\n this.resizeHandler.start();\n\n /** When a new height value is received set the height of the host element (in pixels) */\n effect(() => {\n const newHeightFromChannel = this.newHeightFromChannel();\n if (newHeightFromChannel) {\n renderer.setStyle(elem.nativeElement, 'height', `${newHeightFromChannel.height}px`);\n }\n });\n }\n}\n","import {\n type Logger,\n} from '@o3r/logger';\nimport {\n getHostInfo,\n} from '../host-info';\n\n/** Default suffix for an url containing a theme css file */\nexport const THEME_URL_SUFFIX = '-theme.css';\n/** Default name for the query parameter containing the theme name */\nexport const THEME_QUERY_PARAM_NAME = 'theme';\n\n/** Options and context for Style helpers */\nexport interface StyleHelperOptions {\n /**\n * Logger to reporter the logs\n */\n logger?: Logger;\n}\n\n/**\n * Fetches a CSS document and returns the content as a string.\n * @param cssPath - The path to download the CSS.\n * @param options Options and context for Style helpers\n * @returns The content of the CSS document as a string, empty string if the fetch fails.\n */\nexport async function getStyle(cssPath: string, options?: StyleHelperOptions): Promise<string> {\n try {\n const myRequest = new Request(cssPath);\n const response = await fetch(myRequest);\n const cssText = response.ok ? await response.text() : '';\n return cssText;\n } catch (error) {\n options?.logger?.warn(`Failed to download style from: ${cssPath} with error: ${error?.toString()}`);\n }\n return '';\n}\n\n/**\n * Applies the given CSS theme as a stylesheet.\n * @param themeValue - CSS as text containing a theme definition.\n * @param cleanPrevious - Whether to remove previously applied stylesheets if no themeValue provided. Default is true.\n */\nexport function applyTheme(themeValue?: string, cleanPrevious = true): void {\n if (themeValue !== undefined) {\n const sheet = new CSSStyleSheet();\n sheet.replaceSync(themeValue);\n document.adoptedStyleSheets = cleanPrevious ? [sheet] : [...document.adoptedStyleSheets, sheet];\n } else if (cleanPrevious) { // remove the styles if the theme value comes undefined or empty string\n document.adoptedStyleSheets = [];\n }\n}\n\n/**\n * Download the application additional theme\n * @param theme Name of the theme to download from the current application\n * @param options Options and context for Style helpers\n */\nexport function downloadApplicationThemeCss(theme: string, options?: StyleHelperOptions) {\n const cssHref = `${theme.endsWith('.css') ? theme : theme + THEME_URL_SUFFIX}`;\n return getStyle(cssHref, options);\n}\n\n/**\n * Applies the initial theme based on the URL query parameters.\n *\n * This function fetches the CSS theme specified in the URL query parameters and applies it as a stylesheet.\n * If a referrer is present, it also attempts to fetch and apply the theme from the referrer's URL.\n * @param options Options and context for Style helpers\n */\nexport async function applyInitialTheme(options?: StyleHelperOptions): Promise<PromiseSettledResult<void>[] | undefined> {\n const searchParams = new URLSearchParams(window.location.search);\n const theme = searchParams.get(THEME_QUERY_PARAM_NAME);\n document.adoptedStyleSheets = [];\n if (theme) {\n const themeRequest: Promise<void>[] = [\n downloadApplicationThemeCss(theme, options).then((styleToApply) => applyTheme(styleToApply, false))\n ];\n const hostInfo = getHostInfo();\n if (hostInfo.hostURL) {\n const url = new URL(hostInfo.hostURL);\n url.pathname += `${url.pathname.endsWith('/') ? '' : '/'}${theme}`;\n themeRequest.unshift(getStyle(url.toString(), options).then((styleToApply) => applyTheme(styleToApply, false)));\n }\n\n return Promise.allSettled(themeRequest);\n }\n return undefined;\n}\n","import type {\n ThemeMessage,\n ThemeV1_0,\n} from '@ama-mfe/messages';\nimport {\n THEME_MESSAGE_TYPE,\n ThemeStructure,\n} from '@ama-mfe/messages';\nimport {\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n effect,\n inject,\n Injectable,\n signal,\n} from '@angular/core';\nimport {\n LoggerService,\n} from '@o3r/logger';\nimport {\n type MessageProducer,\n registerProducer,\n} from '../managers/index';\nimport {\n type ErrorContent,\n} from '../messages/index';\nimport {\n applyTheme,\n getStyle,\n THEME_QUERY_PARAM_NAME,\n THEME_URL_SUFFIX,\n} from './theme-helpers';\n/**\n * This service exposing the current theme signal\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ThemeProducerService implements MessageProducer<ThemeMessage> {\n private readonly messageService = inject(MessagePeerService<ThemeMessage>);\n private readonly logger = inject(LoggerService);\n private previousTheme: ThemeStructure | undefined;\n private readonly window = inject(Window, { optional: true }) || window;\n\n private readonly currentThemeSelection;\n /** Current selected theme signal */\n public readonly currentTheme;\n\n /**\n * The type of messages this service handles ('theme').\n */\n public readonly types = THEME_MESSAGE_TYPE;\n\n constructor() {\n registerProducer(this);\n\n // get the current theme name from the url (if any) and emit a first value for the current theme\n const parentUrl = new URL(this.window.location.toString());\n const selectedThemeName = parentUrl.searchParams.get(THEME_QUERY_PARAM_NAME);\n this.currentThemeSelection = signal<ThemeStructure | undefined>(selectedThemeName\n ? {\n name: selectedThemeName,\n css: null\n }\n : undefined);\n this.currentTheme = this.currentThemeSelection.asReadonly();\n\n if (selectedThemeName) {\n void this.changeTheme(selectedThemeName);\n }\n\n // When the current theme changes, apply it to the current application\n effect(() => {\n const themeObj = this.currentTheme();\n if (themeObj?.css !== null) {\n applyTheme(themeObj?.css);\n }\n });\n\n /**\n * This effect listens for changes in the `currentTheme` signal. If a valid theme object with CSS is present,\n * it creates a theme message and sends it via the message service.\n */\n effect(() => {\n const themeObj = this.currentTheme();\n if (themeObj && themeObj.css !== null) {\n const messageV10 = {\n type: 'theme',\n name: themeObj.name,\n css: themeObj.css,\n version: '1.0'\n } satisfies ThemeV1_0;\n // TODO: sendBest() is not yet implemented -- https://github.com/AmadeusITGroup/microfrontends/issues/11\n this.messageService.send(messageV10);\n }\n });\n }\n\n /**\n * Changes the current theme to the specified theme name.\n * @param themeName - The name of the theme to change to.\n */\n public async changeTheme(themeName?: string): Promise<void> {\n const cssHref = themeName && `${themeName}${THEME_URL_SUFFIX}`;\n const styleObj = cssHref ? await getStyle(cssHref) : '';\n this.currentThemeSelection.update((theme) => {\n this.previousTheme = theme;\n return themeName\n ? { name: themeName, css: styleObj }\n : undefined;\n });\n }\n\n /**\n * Reverts to the previous theme.\n */\n public revertToPreviousTheme(): void {\n this.currentThemeSelection.set(this.previousTheme);\n }\n\n /**\n * @inheritdoc\n */\n public handleError(message: ErrorContent<ThemeV1_0>): void {\n this.logger.error('Error in theme service message', message);\n this.revertToPreviousTheme();\n }\n}\n","import {\n inject,\n Pipe,\n PipeTransform,\n SecurityContext,\n} from '@angular/core';\nimport {\n DomSanitizer,\n type SafeResourceUrl,\n} from '@angular/platform-browser';\nimport {\n ThemeProducerService,\n} from './theme-producer-service';\n\n/**\n * A pipe that applies the current theme from a theme manager service, to a given URL or SafeResourceUrl, as query param\n */\n@Pipe({\n name: 'applyTheme'\n})\nexport class ApplyTheme implements PipeTransform {\n private readonly themeManagerService = inject(ThemeProducerService);\n private readonly domSanitizer = inject(DomSanitizer);\n\n /**\n * Transforms the given URL or SafeResourceUrl by appending the current theme value as a query parameter.\n * @param url - The URL or SafeResourceUrl to be transformed.\n * @returns The transformed SafeResourceUrl or undefined if the input URL is invalid.\n */\n public transform(url: string): string;\n public transform(url: SafeResourceUrl): SafeResourceUrl;\n public transform(url: undefined): undefined;\n public transform(url: string | SafeResourceUrl | undefined): string | SafeResourceUrl | undefined {\n if (!url) {\n return undefined;\n }\n const currentTheme = this.themeManagerService.currentTheme();\n const urlString = typeof url === 'string'\n ? url\n : this.domSanitizer.sanitize(SecurityContext.RESOURCE_URL, url);\n\n if (urlString) {\n const moduleUrl = new URL(urlString);\n if (currentTheme) {\n moduleUrl.searchParams.set('theme', currentTheme.name);\n }\n const moduleUrlStringyfied = moduleUrl.toString();\n return typeof url === 'string' ? moduleUrlStringyfied : this.domSanitizer.bypassSecurityTrustResourceUrl(moduleUrlStringyfied);\n }\n\n return undefined;\n }\n}\n","import type {\n ThemeMessage,\n ThemeV1_0,\n} from '@ama-mfe/messages';\nimport {\n THEME_MESSAGE_TYPE,\n} from '@ama-mfe/messages';\nimport type {\n RoutedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n DestroyRef,\n inject,\n Injectable,\n SecurityContext,\n} from '@angular/core';\nimport {\n DomSanitizer,\n} from '@angular/platform-browser';\nimport {\n LoggerService,\n} from '@o3r/logger';\nimport {\n ConsumerManagerService,\n MessageConsumer,\n} from '../managers/index';\nimport {\n applyTheme,\n downloadApplicationThemeCss,\n} from './theme-helpers';\n\n/**\n * A service that handles theme messages and applies the received theme.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ThemeConsumerService implements MessageConsumer<ThemeMessage> {\n private readonly domSanitizer = inject(DomSanitizer);\n private readonly consumerManagerService = inject(ConsumerManagerService);\n private readonly logger = inject(LoggerService);\n /**\n * The type of messages this service handles ('theme').\n */\n public readonly type = THEME_MESSAGE_TYPE;\n\n /**\n * The supported versions of theme messages and their handlers.\n */\n public readonly supportedVersions = {\n /**\n * Use the message paylod to get the theme and apply it\n * @param message message to consume\n */\n '1.0': async (message: RoutedMessage<ThemeV1_0>) => {\n const sanitizedCss = this.domSanitizer.sanitize(SecurityContext.STYLE, message.payload.css);\n if (sanitizedCss !== null) {\n applyTheme(sanitizedCss);\n }\n try {\n const css = await downloadApplicationThemeCss(message.payload.name, { logger: this.logger });\n applyTheme(css, false);\n } catch (e) {\n this.logger.warn(`No CSS variable for the theme ${message.payload.name}`, e);\n }\n }\n };\n\n constructor() {\n this.start();\n inject(DestroyRef).onDestroy(() => this.stop());\n }\n\n /**\n * Starts the theme handler service by registering it into the consumer manager service.\n */\n public start() {\n this.consumerManagerService.register(this);\n }\n\n /**\n * Stops the theme handler service by unregistering it from the consumer manager service.\n */\n public stop() {\n this.consumerManagerService.unregister(this);\n }\n}\n","import type {\n UserActivityEventType,\n} from '@ama-mfe/messages';\nimport type {\n ActivityProducerConfig,\n} from './interfaces';\n\n/**\n * DOM events that indicate user activity\n */\nexport const ACTIVITY_EVENTS: readonly Exclude<UserActivityEventType, 'visibilitychange'>[] = [\n 'click',\n 'keydown',\n 'scroll',\n 'touchstart',\n 'focus'\n];\n\n/**\n * Custom activity event type for iframe interactions.\n * Emitted programmatically when an iframe gains focus, not from a DOM event listener.\n */\nexport const IFRAME_INTERACTION_EVENT: UserActivityEventType = 'iframeinteraction';\n\n/**\n * Custom activity event type for visibility changes.\n * Emitted programmatically when the document becomes visible, not from a DOM event listener.\n */\nexport const VISIBILITY_CHANGE_EVENT: UserActivityEventType = 'visibilitychange';\n\n/**\n * High-frequency events that require throttling to avoid performance issues\n */\nexport const HIGH_FREQUENCY_EVENTS: readonly UserActivityEventType[] = [\n 'scroll'\n];\n\n/**\n * Default configuration values for the ActivityProducerService\n */\nexport const DEFAULT_ACTIVITY_PRODUCER_CONFIG: Readonly<ActivityProducerConfig> = {\n /** Default throttle time in milliseconds between activity messages */\n throttleMs: 1000,\n /** Default throttle time in milliseconds for high-frequency events */\n highFrequencyThrottleMs: 300,\n /** Whether to track nested iframes by default */\n trackNestedIframes: false,\n /** Default interval for iframe activity signals (30 seconds) */\n nestedIframeActivityEmitIntervalMs: 30_000,\n /** Default polling interval for detecting iframe focus changes (1 second) */\n nestedIframePollIntervalMs: 1000\n};\n","import {\n Injectable,\n} from '@angular/core';\nimport type {\n IframeActivityTrackerConfig,\n} from './interfaces';\n\n/**\n * Service that tracks user activity within nested iframes.\n *\n * Polls document.activeElement frequently to detect when an iframe has focus.\n * When an iframe gains focus, emits immediately and then at the configured interval.\n * When focus leaves the iframe, it stops emitting.\n *\n * This is needed because cross-origin iframes don't fire focus/blur events\n * that bubble to the parent, and the regular activity tracker can't detect\n * user interactions inside iframes.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class IframeActivityTrackerService {\n /**\n * Interval ID for polling activeElement\n */\n private pollIntervalId?: ReturnType<typeof setInterval>;\n\n /**\n * Interval ID for emitting activity at configured interval\n */\n private activityIntervalId?: ReturnType<typeof setInterval>;\n\n /**\n * Current configuration\n */\n private config?: IframeActivityTrackerConfig;\n\n /**\n * Bound visibility change handler for cleanup\n */\n private readonly visibilityChangeHandler = () => this.handleVisibilityChange();\n\n /**\n * Whether the service has been started\n */\n private get started() {\n return this.config !== undefined;\n }\n\n /**\n * Whether we are currently tracking iframe activity (iframe had focus on last poll)\n */\n private get isTrackingIframeActivity() {\n return this.activityIntervalId !== undefined;\n }\n\n /**\n * Polls document.activeElement to detect iframe focus changes.\n * When iframe gains focus: emit immediately and start activity interval.\n * When iframe loses focus: stop activity interval.\n */\n private checkActiveElement(): void {\n const activeElement = document.activeElement;\n const iframeFocused = activeElement instanceof HTMLIFrameElement;\n\n if (iframeFocused && !this.isTrackingIframeActivity) {\n // Iframe just gained focus - emit immediately and start activity interval\n this.config?.onActivity();\n this.startActivityInterval();\n } else if (!iframeFocused && this.isTrackingIframeActivity) {\n // Focus left the iframe - stop activity interval\n this.stopActivityInterval();\n }\n }\n\n /**\n * Handles visibility change events to pause/resume polling when tab visibility changes.\n */\n private handleVisibilityChange(): void {\n if (document.visibilityState === 'visible') {\n this.startPolling();\n } else {\n this.stopPolling();\n this.stopActivityInterval();\n }\n }\n\n /**\n * Starts polling for active element changes.\n */\n private startPolling(): void {\n if (this.pollIntervalId) {\n return;\n }\n this.pollIntervalId = setInterval(\n () => this.checkActiveElement(),\n this.config!.pollIntervalMs\n );\n }\n\n /**\n * Stops polling for active element changes.\n */\n private stopPolling(): void {\n if (this.pollIntervalId) {\n clearInterval(this.pollIntervalId);\n this.pollIntervalId = undefined;\n }\n }\n\n /**\n * Starts the activity emission interval.\n */\n private startActivityInterval(): void {\n this.stopActivityInterval();\n this.activityIntervalId = setInterval(() => {\n this.config?.onActivity();\n }, this.config!.activityIntervalMs);\n }\n\n /**\n * Stops the activity emission interval.\n */\n private stopActivityInterval(): void {\n if (this.activityIntervalId) {\n clearInterval(this.activityIntervalId);\n this.activityIntervalId = undefined;\n }\n }\n\n /**\n * Starts tracking nested iframes within the document.\n * @param config Configuration for the tracker\n */\n public start(config: IframeActivityTrackerConfig): void {\n if (this.started) {\n return;\n }\n this.config = config;\n\n // Listen for visibility changes to pause/resume polling\n document.addEventListener('visibilitychange', this.visibilityChangeHandler);\n\n // Only start polling if document is currently visible\n if (document.visibilityState === 'visible') {\n this.startPolling();\n }\n }\n\n /**\n * Stops tracking nested iframes and cleans up resources.\n */\n public stop(): void {\n if (!this.started) {\n return;\n }\n\n document.removeEventListener('visibilitychange', this.visibilityChangeHandler);\n this.stopPolling();\n this.stopActivityInterval();\n this.config = undefined;\n }\n}\n","import {\n USER_ACTIVITY_MESSAGE_TYPE,\n type UserActivityEventType,\n type UserActivityMessage,\n type UserActivityMessageV1_0,\n} from '@ama-mfe/messages';\nimport {\n afterNextRender,\n DestroyRef,\n inject,\n Injectable,\n signal,\n} from '@angular/core';\nimport {\n LoggerService,\n} from '@o3r/logger';\nimport {\n ConnectionService,\n} from '../connect/index';\nimport {\n type MessageProducer,\n registerProducer,\n} from '../managers';\nimport type {\n ErrorContent,\n} from '../messages';\nimport {\n ACTIVITY_EVENTS,\n DEFAULT_ACTIVITY_PRODUCER_CONFIG,\n HIGH_FREQUENCY_EVENTS,\n IFRAME_INTERACTION_EVENT,\n VISIBILITY_CHANGE_EVENT,\n} from './config';\nimport {\n IframeActivityTrackerService,\n} from './iframe-activity-tracker.service';\nimport type {\n ActivityInfo,\n ActivityProducerConfig,\n} from './interfaces';\n\n/**\n * Generic service that tracks user activity and sends messages.\n * Can be configured for different contexts (cockpit or modules) via start() method parameter.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ActivityProducerService implements MessageProducer<UserActivityMessage> {\n private readonly messageService = inject(ConnectionService);\n private readonly destroyRef = inject(DestroyRef);\n private readonly iframeActivityTracker = inject(IframeActivityTrackerService);\n private readonly logger = inject(LoggerService);\n\n /**\n * Timestamp of the last sent activity message\n */\n private lastSentTimestamp = 0;\n\n /**\n * Bound event listeners for cleanup\n */\n private readonly boundListeners = new Map<UserActivityEventType, EventListener>();\n\n /**\n * Last emission timestamps for throttled high-frequency events\n */\n private readonly lastEmitTimestamps = new Map<UserActivityEventType, number>();\n\n /**\n * Whether the service has been started\n */\n private started = false;\n\n /**\n * Signal that emits local activity information.\n * This allows consumers to react to activity detected by this producer.\n */\n private readonly localActivityWritable = signal<ActivityInfo | undefined>(undefined);\n\n /**\n * Read-only signal containing the latest local activity info.\n * Use this signal to react to locally detected activity.\n */\n public readonly localActivity = this.localActivityWritable.asReadonly();\n\n /**\n * @inheritdoc\n */\n public readonly types = USER_ACTIVITY_MESSAGE_TYPE;\n\n constructor() {\n registerProducer(this);\n this.destroyRef.onDestroy(() => this.stop());\n }\n\n /**\n * Handles high-frequency events by applying a per-eventType throttle before calling onActivity.\n *\n * Difference with onActivity:\n * - onActivityThrottled limits how often a given high-frequency event type (e.g. scroll) is processed\n * (based on highFrequencyThrottleMs and lastEmitTimestamps)\n * - onActivity updates the local activity signal and applies the global message throttle\n * (based on global throttleMs and lastSentTimestamp)\n * @param eventType The type of activity event that occurred\n * @param configObject\n */\n private onActivityThrottled(eventType: UserActivityEventType, configObject: ActivityProducerConfig): void {\n const now = Date.now();\n const lastEmit = this.lastEmitTimestamps.get(eventType) ?? 0;\n const throttleMs = configObject.highFrequencyThrottleMs!;\n\n if (now - lastEmit >= throttleMs) {\n this.lastEmitTimestamps.set(eventType, now);\n this.onActivity(eventType, configObject);\n }\n }\n\n /**\n * Handles activity by sending a throttled message and emitting to local signal.\n * @param eventType The type of activity event that occurred\n * @param configObject\n */\n private onActivity(eventType: UserActivityEventType, configObject: ActivityProducerConfig): void {\n const now = Date.now();\n\n // Always emit local activity signal (not throttled for local detection)\n this.localActivityWritable.set({\n channelId: 'local',\n eventType,\n timestamp: now\n });\n\n // Send message with throttling\n if (now - this.lastSentTimestamp >= configObject.throttleMs) {\n this.lastSentTimestamp = now;\n this.sendActivityMessage(eventType, now);\n }\n }\n\n /**\n * Sends an activity message.\n * @param eventType The type of activity event\n * @param timestamp The timestamp of the event\n */\n private sendActivityMessage(eventType: UserActivityEventType, timestamp: number): void {\n const message: UserActivityMessageV1_0 = {\n type: USER_ACTIVITY_MESSAGE_TYPE,\n version: '1.0',\n eventType,\n timestamp\n };\n const registeredPeersIdsForUserActivity = [...this.messageService.knownPeers.entries()]\n .filter(([peerId]) => peerId !== this.messageService.id)\n .filter(([, messages]) => messages.some((msg) => msg.type === USER_ACTIVITY_MESSAGE_TYPE))\n .map((peer) => peer[0]);\n // send messages to the peers waiting for user activity\n // avoids sending the message to modules which are not using it\n if (registeredPeersIdsForUserActivity.length > 0) {\n this.messageService.send(message, { to: registeredPeersIdsForUserActivity });\n }\n }\n\n /**\n * @inheritdoc\n */\n public handleError(message: ErrorContent<UserActivityMessage>): void {\n this.logger.error('Error in user activity service message', message);\n }\n\n /**\n * Starts observing user activity events.\n * When activity is detected, it sends a throttled message.\n * Event listeners are attached after the next render to ensure DOM is ready.\n * @param config Configuration for the activity producer\n */\n public start(config?: Partial<ActivityProducerConfig>): void {\n if (this.started) {\n return;\n }\n this.started = true;\n const configObject: ActivityProducerConfig = { ...DEFAULT_ACTIVITY_PRODUCER_CONFIG, ...config };\n\n // Always use afterNextRender to ensure DOM is ready in all contexts\n afterNextRender(() => {\n ACTIVITY_EVENTS.forEach((eventType) => {\n const isHighFrequency = HIGH_FREQUENCY_EVENTS.includes(eventType);\n const listener = (event: Event) => {\n // do nothing if the event is a key kept pressed\n if (eventType === 'keydown' && event instanceof KeyboardEvent && event.repeat) {\n return;\n }\n // Apply filter if provided\n if (configObject.shouldBroadcast?.(event) === false) {\n return;\n }\n if (isHighFrequency) {\n this.onActivityThrottled(eventType, configObject);\n } else {\n this.onActivity(eventType, configObject);\n }\n };\n this.boundListeners.set(eventType, listener);\n document.addEventListener(eventType, listener, { passive: true, capture: true });\n });\n\n // Also listen for visibility changes\n const visibilityListener = () => {\n if (document.visibilityState === 'visible') {\n this.onActivity(VISIBILITY_CHANGE_EVENT, configObject);\n }\n };\n this.boundListeners.set(VISIBILITY_CHANGE_EVENT, visibilityListener);\n document.addEventListener(VISIBILITY_CHANGE_EVENT, visibilityListener, { passive: true, capture: true });\n\n // Set up nested iframe tracking if enabled\n if (configObject.trackNestedIframes) {\n this.iframeActivityTracker.start({\n pollIntervalMs: configObject.nestedIframePollIntervalMs,\n activityIntervalMs: configObject.nestedIframeActivityEmitIntervalMs,\n onActivity: () => this.onActivity(IFRAME_INTERACTION_EVENT, configObject)\n });\n }\n });\n }\n\n /**\n * Stops observing user activity events.\n */\n public stop(): void {\n this.boundListeners.forEach((listener, eventType) => {\n document.removeEventListener(eventType, listener, { capture: true });\n });\n this.boundListeners.clear();\n this.lastEmitTimestamps.clear();\n this.iframeActivityTracker.stop();\n }\n}\n","import {\n USER_ACTIVITY_MESSAGE_TYPE,\n type UserActivityMessageV1_0,\n} from '@ama-mfe/messages';\nimport type {\n RoutedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n inject,\n Injectable,\n signal,\n} from '@angular/core';\nimport {\n type BasicMessageConsumer,\n ConsumerManagerService,\n} from '../managers';\nimport {\n ActivityInfo,\n} from './interfaces';\n\n/**\n * Generic service that consumes user activity messages.\n * Can be used in both shell (to receive from modules) and modules (to receive from shell).\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ActivityConsumerService implements BasicMessageConsumer<UserActivityMessageV1_0> {\n private readonly consumerManagerService = inject(ConsumerManagerService);\n\n /**\n * Signal containing the latest activity info\n */\n private readonly latestReceivedActivityWritable = signal<ActivityInfo | undefined>(undefined);\n\n /**\n * Read-only signal containing the latest activity info received from other peers via the message protocol.\n * Access the timestamp via latestReceivedActivity()?.timestamp\n */\n public readonly latestReceivedActivity = this.latestReceivedActivityWritable.asReadonly();\n\n /**\n * @inheritdoc\n */\n public readonly type = USER_ACTIVITY_MESSAGE_TYPE;\n\n /**\n * @inheritdoc\n */\n public readonly supportedVersions: Record<string, (message: RoutedMessage<UserActivityMessageV1_0>) => void> = {\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Version keys follow message versioning convention\n '1.0': (message) => {\n this.latestReceivedActivityWritable.set({\n channelId: message.from || 'unknown',\n eventType: message.payload.eventType,\n timestamp: message.payload.timestamp\n });\n }\n };\n\n /**\n * Starts the activity consumer service by registering it with the consumer manager.\n */\n public start(): void {\n this.consumerManagerService.register(this);\n }\n\n /**\n * Stops the activity consumer service by unregistering it from the consumer manager.\n */\n public stop(): void {\n this.consumerManagerService.unregister(this);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["ConnectionService"],"mappings":";;;;;;;;;;;MAyBa,gBAAgB,CAAA;AAW3B;;AAEG;AACH,IAAA,IACW,OAAO,GAAA;AAChB,QAAA,OAAO,IAAI,CAAC,GAAG,EAAE;IACnB;AAYA,IAAA,WAAA,GAAA;AA5BA;;AAEG;AACI,QAAA,IAAA,CAAA,OAAO,GAAG,KAAK,CAAC,QAAQ,kDAAU;AAEzC;;AAEG;QACI,IAAA,CAAA,GAAG,GAAG,KAAK,CAAA,IAAA,SAAA,GAAA,CAAA,SAAA,EAAA,EAAA,SAAA,EAAA,KAAA,EAAA,CAAA,GAAA,EAAA,CAAA,CAAmB;AAUpB,QAAA,IAAA,CAAA,cAAc,GAAG,MAAM,CAAC,kBAAkB,CAAC;AAC3C,QAAA,IA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C,IAAI,CAAC;IAC5C;AAEA;;AAEG;IACI,IAAI,GAAA;AACT,QAAA,IAAI,CAAC,sBAAsB,CAAC,UAAU,CAAC,IAAI,CAAC;IAC9C;kIA7CW,uBAAuB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAvB,uBAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,uBAAuB,cAFtB,MAAM,EAAA,CAAA,CAAA;;4FAEP,uBAAuB,EAAA,UAAA,EAAA,CAAA;kBAHnC,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE;AACb,iBAAA;;;AC1BD;;AAEG;;;;"}
1
+ {"version":3,"file":"ama-mfe-ng-utils.mjs","sources":["../../src/connect/connect-directive.ts","../../src/messages/available-sender.ts","../../src/messages/error-sender.ts","../../src/managers/producer-manager-service.ts","../../src/managers/consumer-manager-service.ts","../../src/managers/utils.ts","../../src/history/history-consumer-service.ts","../../src/history/history-providers.ts","../../src/host-info/host-info.ts","../../src/host-info/host-info-pipe.ts","../../src/messages/error/base.ts","../../src/messages/user-activity.ts","../../src/utils.ts","../../src/connect/connect-providers.ts","../../src/navigation/navigation-consumer-service.ts","../../src/navigation/route-memorize/route-memorize-service.ts","../../src/navigation/restore-route-pipe.ts","../../src/navigation/route-memorize/route-memorize-directive.ts","../../src/navigation/routing-service.ts","../../src/resize/resize-consumer-service.ts","../../src/resize/resize-producer-service.ts","../../src/resize/scalable-directive.ts","../../src/theme/theme-helpers.ts","../../src/theme/theme-producer-service.ts","../../src/theme/apply-theme-pipe.ts","../../src/theme/theme-consumer-service.ts","../../src/user-activity/config.ts","../../src/user-activity/iframe-activity-tracker.service.ts","../../src/user-activity/activity-producer.service.ts","../../src/user-activity/activity-consumer.service.ts","../../src/ama-mfe-ng-utils.ts"],"sourcesContent":["import {\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n computed,\n Directive,\n effect,\n ElementRef,\n HostBinding,\n inject,\n input,\n SecurityContext,\n} from '@angular/core';\nimport {\n DomSanitizer,\n SafeResourceUrl,\n} from '@angular/platform-browser';\nimport {\n LoggerService,\n} from '@o3r/logger';\n\n@Directive({\n selector: 'iframe[connect]',\n standalone: true\n})\nexport class ConnectDirective {\n /**\n * The connection ID required for the message peer service.\n */\n public connect = input.required<string>();\n\n /**\n * The sanitized source URL for the iframe.\n */\n public src = input<SafeResourceUrl>();\n\n /**\n * Binds the `src` attribute of the iframe to the sanitized source URL.\n */\n @HostBinding('src')\n public get srcAttr() {\n return this.src();\n }\n\n private readonly messageService = inject(MessagePeerService);\n private readonly domSanitizer = inject(DomSanitizer);\n private readonly iframeElement = inject<ElementRef<HTMLIFrameElement>>(ElementRef).nativeElement;\n\n private readonly clientOrigin = computed(() => {\n const src = this.src();\n const srcString = src && this.domSanitizer.sanitize(SecurityContext.RESOURCE_URL, src);\n return srcString && new URL(srcString).origin;\n });\n\n constructor() {\n const logger = inject(LoggerService);\n\n // When the origin or connection ID change - reconnect the message service\n effect((onCleanup) => {\n let stopHandshakeListening = () => { /* no op */ };\n\n const origin = this.clientOrigin();\n const id = this.connect();\n const source = this.iframeElement.contentWindow;\n\n // listen for handshakes only if we know the origin and were given a connection ID\n if (origin && source && id) {\n try {\n stopHandshakeListening = this.messageService.listen({ id, source, origin });\n } catch (e) {\n logger.error(`Failed to start listening for (connection ID: ${id})`, e);\n }\n }\n\n // stop listening for handshakes and disconnect previous connection when:\n // - origin/connection ID change\n // - the directive is destroyed\n onCleanup(() => {\n stopHandshakeListening();\n this.messageService.disconnect();\n });\n });\n }\n}\n","import type {\n DeclareMessages,\n} from '@amadeus-it-group/microfrontends';\nimport type {\n BasicMessageConsumer,\n} from '../managers/interfaces';\n\n/**\n * Gets the available consumers and formats them into a {@link DeclareMessages} object.\n * @param consumers - The list of registered message consumers.\n * @returns The formatted DeclareMessages object.\n */\nexport const getAvailableConsumers = (consumers: BasicMessageConsumer[]) => {\n return {\n type: 'declare_messages',\n version: '1.0',\n messages: consumers.flatMap(({ type, supportedVersions }) => Object.keys(supportedVersions).map((version) => ({ type, version })))\n } satisfies DeclareMessages;\n};\n","import type {\n VersionedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport type {\n MessagePeerServiceType,\n} from '@amadeus-it-group/microfrontends-angular';\nimport type {\n ERROR_MESSAGE_TYPE,\n ErrorContent,\n ErrorMessageV1_0,\n} from './error/index';\n\n/**\n * Helper function to send an error message by the given endpoint (peer)\n * @param peer The endpoint sending the message\n * @param content the content of the error message to be sent\n */\nexport const sendError = (peer: MessagePeerServiceType<any>, content: ErrorContent) => {\n return peer.send({\n type: 'error',\n version: '1.0',\n ...content\n } satisfies ErrorMessageV1_0);\n};\n\n/**\n * Check if the given message is of type error and the error reson is present too\n * @param message the message to be checked\n */\n// eslint-disable-next-line @stylistic/max-len -- constant definition\nexport const isErrorMessage = (message: any): message is VersionedMessage & { type: typeof ERROR_MESSAGE_TYPE } & ErrorContent => (message && typeof message === 'object' && message.type === 'error' && !!message.reason);\n","import type {\n VersionedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n Injectable,\n} from '@angular/core';\nimport type {\n ErrorContent,\n} from '../messages/index';\nimport type {\n MessageProducer,\n} from './interfaces';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class ProducerManagerService {\n private readonly registeredProducers = new Set<MessageProducer>();\n\n /** Get the list of registered producers of messages. The list will contain unique elements */\n public get producers() {\n return [...this.registeredProducers];\n }\n\n /**\n * Register a producer of a message\n * @param producer The instance of the message producer\n */\n public register(producer: MessageProducer) {\n this.registeredProducers.add((producer));\n }\n\n /**\n * Unregister a producer of a message\n * @param producer The instance of the message producer\n */\n public unregister(producer: MessageProducer) {\n this.registeredProducers.delete((producer));\n }\n\n /**\n * Handles the received error message for the given message type by invoking the appropriate producer handlers.\n * @template T - The type of the message, extending from Message.\n * @param message - The error message to handle.\n * @returns - A promise that resolves to true if the error was handled by at least one handler, false otherwise.\n */\n public async dispatchError<T extends VersionedMessage = VersionedMessage>(message: ErrorContent<T>) {\n const handlers = this.producers\n .filter(({ types }) => (Array.isArray(types) ? types : [types]).includes(message.source.type));\n\n const handlersPresent = handlers.length > 0;\n if (handlersPresent) {\n await Promise.all(\n // eslint-disable-next-line @typescript-eslint/await-thenable -- `handleError` can return void or Promise<void>\n handlers.map((handler) => handler.handleError(message))\n );\n }\n return handlersPresent;\n }\n}\n","import {\n RoutedMessage,\n VersionedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n effect,\n inject,\n Injectable,\n signal,\n} from '@angular/core';\nimport {\n takeUntilDestroyed,\n} from '@angular/core/rxjs-interop';\nimport {\n LoggerService,\n} from '@o3r/logger';\nimport {\n getAvailableConsumers,\n} from '../messages/available-sender';\nimport {\n isErrorMessage,\n sendError,\n} from '../messages/error-sender';\nimport type {\n BasicMessageConsumer,\n} from './interfaces';\nimport {\n ProducerManagerService,\n} from './producer-manager-service';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class ConsumerManagerService {\n private readonly messageService = inject(MessagePeerService);\n private readonly producerManagerService = inject(ProducerManagerService);\n private readonly registeredConsumers = signal<BasicMessageConsumer[]>([]);\n private readonly logger = inject(LoggerService);\n\n /** The list of registered consumers */\n public readonly consumers = this.registeredConsumers.asReadonly();\n\n constructor() {\n this.messageService.messages$.pipe(takeUntilDestroyed()).subscribe((message) => this.consumeMessage(message));\n\n // Each time a consumer is registered/unregistered update the list of registered messages\n effect(() => {\n const declareMessages = getAvailableConsumers(this.consumers());\n\n // registering consumed messages locally for validation\n for (const message of declareMessages.messages) {\n this.messageService.registerMessage(message);\n }\n });\n }\n\n /**\n * Consume a received message\n * @param message the received message body\n */\n private async consumeMessage(message: RoutedMessage<VersionedMessage>) {\n if (isErrorMessage(message.payload)) {\n const isHandled = await this.producerManagerService.dispatchError(message.payload);\n if (!isHandled) {\n this.logger.warn('Error message not handled', message);\n }\n return;\n }\n\n return this.consumeAdditionalMessage(message);\n }\n\n /**\n * Call the registered message callback(s) to consume the given message\n * Handle error messages of internal communication protocol messages\n * @param message message to consume\n */\n private async consumeAdditionalMessage(message: RoutedMessage<VersionedMessage>) {\n if (!message.payload) {\n this.logger.warn('Cannot consume a messages with undefined payload.');\n return;\n }\n\n const consumers = this.consumers();\n const typeMatchingConsumers = consumers\n .filter((consumer) => consumer.type === message.payload.type);\n\n if (typeMatchingConsumers.length === 0) {\n this.logger.warn(`No consumer found for message type: ${message.payload.type}`);\n return sendError(this.messageService, { reason: 'unknown_type', source: message.payload });\n }\n\n const versionMatchingConsumers = typeMatchingConsumers\n .filter((consumer) => consumer.supportedVersions[message.payload.version])\n .flat();\n\n if (versionMatchingConsumers.length === 0) {\n this.logger.warn(`No consumer found for message version: ${message.payload.version}`);\n return sendError(this.messageService, { reason: 'version_mismatch', source: message.payload });\n }\n\n await Promise.all(\n versionMatchingConsumers\n .map(async (consumer) => {\n try {\n await consumer.supportedVersions[message.payload.version](message);\n } catch (error) {\n this.logger.error('Error while consuming message', error);\n sendError(this.messageService, { reason: 'internal_error', source: message.payload });\n }\n })\n );\n }\n\n /**\n * Register a message consumer\n * @param consumer an instance of message consumer\n */\n public register(consumer: BasicMessageConsumer) {\n this.registeredConsumers.update((consumers) => {\n return [...new Set(consumers).add(consumer)];\n });\n }\n\n /**\n * Unregister a message consumer\n * @param consumer an instance of message consumer\n */\n public unregister(consumer: BasicMessageConsumer) {\n this.registeredConsumers.update((consumers) => {\n return consumers.filter((c) => c !== consumer);\n });\n }\n}\n","import {\n DestroyRef,\n inject,\n} from '@angular/core';\nimport {\n ConsumerManagerService,\n} from './consumer-manager-service';\nimport type {\n MessageConsumer,\n MessageProducer,\n} from './interfaces';\nimport {\n ProducerManagerService,\n} from './producer-manager-service';\n\n/**\n * Method to call in the constructor of a producer\n * @note should be used in injection context\n * @param producer\n */\nexport const registerProducer = (producer: MessageProducer) => {\n const producerManagerService = inject(ProducerManagerService);\n producerManagerService.register(producer);\n\n inject(DestroyRef).onDestroy(() => {\n producerManagerService.unregister(producer);\n });\n};\n\n/**\n * Method to call in the constructor of a consumer\n * @note should be used in injection context\n * @param consumer\n */\nexport const registerConsumer = (consumer: MessageConsumer) => {\n const consumerManagerService = inject(ConsumerManagerService);\n consumerManagerService.register(consumer);\n\n inject(DestroyRef).onDestroy(() => {\n consumerManagerService.unregister(consumer);\n });\n};\n","import type {\n HistoryMessage,\n HistoryV1_0,\n} from '@ama-mfe/messages';\nimport {\n HISTORY_MESSAGE_TYPE,\n} from '@ama-mfe/messages';\nimport type {\n RoutedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n DestroyRef,\n inject,\n Injectable,\n} from '@angular/core';\nimport {\n ConsumerManagerService,\n type MessageConsumer,\n} from '../managers/index';\n\n/**\n * A service that handles history messages.\n *\n * This service listens for history messages and navigates accordingly.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class HistoryConsumerService implements MessageConsumer<HistoryMessage> {\n /**\n * The type of messages this service handles.\n */\n public readonly type = HISTORY_MESSAGE_TYPE;\n\n /**\n * @inheritdoc\n */\n public readonly supportedVersions = {\n /**\n * Use the message payload to navigate in the history\n * @param message message to consume\n */\n '1.0': (message: RoutedMessage<HistoryV1_0>) => {\n history.go(message.payload.delta);\n }\n };\n\n private readonly consumerManagerService = inject(ConsumerManagerService);\n\n constructor() {\n this.start();\n inject(DestroyRef).onDestroy(() => this.stop());\n }\n\n /**\n * @inheritdoc\n */\n public start() {\n this.consumerManagerService.register(this);\n }\n\n /**\n * @inheritdoc\n */\n public stop() {\n this.consumerManagerService.unregister(this);\n }\n}\n","import {\n HistoryMessage,\n HistoryV1_0,\n} from '@ama-mfe/messages';\nimport {\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n inject,\n provideAppInitializer,\n} from '@angular/core';\n\n/**\n * Provides necessary overrides to make the module navigation in history work in an embedded context :\n * - Prevent pushing states to history, replace state instead\n * - Handle history navigation via History messages to let the host manage the states\n */\nexport function provideHistoryOverrides() {\n return provideAppInitializer(() => {\n const messageService = inject(MessagePeerService<HistoryMessage>);\n const navigate = (delta: number) => {\n messageService.send({\n type: 'history',\n version: '1.0',\n delta\n } satisfies HistoryV1_0);\n };\n Object.defineProperty(history, 'pushState', {\n value: (data: any, unused: string, url?: string | URL | null) => {\n history.replaceState(data, unused, url);\n },\n writable: false,\n configurable: false\n });\n Object.defineProperty(history, 'back', {\n value: () => navigate(-1),\n writable: false,\n configurable: false\n });\n Object.defineProperty(history, 'forward', {\n value: () => navigate(1),\n writable: false,\n configurable: false\n });\n Object.defineProperty(history, 'go', {\n value: (delta: number) => navigate(delta),\n writable: false,\n configurable: false\n });\n });\n}\n","const SESSION_STORAGE_KEY = 'ama-mfe-host-info';\n\n/**\n * Search parameter to add to the URL when embedding an iframe containing the URL of the host.\n * This is needed to support Firefox (on which {@link https://developer.mozilla.org/docs/Web/API/Location/ancestorOrigins | location.ancestorOrigins} is not currently supported)\n * in case of redirection inside the iframe.\n */\nexport const MFE_HOST_URL_PARAM = 'ama-mfe-host-url';\n\n/**\n * Search parameter to add to the URL to let a module know on which application it's embedded\n */\nexport const MFE_HOST_APPLICATION_ID_PARAM = 'ama-mfe-host-app-id';\n\n/**\n * Search parameter to add to the URL to identify the application in the network of peers in the communication protocol\n */\nexport const MFE_MODULE_APPLICATION_ID_PARAM = 'ama-mfe-module-app-id';\n\n/** The list of query parameters which can be set by the host */\nexport const hostQueryParams = [MFE_HOST_URL_PARAM, MFE_HOST_APPLICATION_ID_PARAM, MFE_MODULE_APPLICATION_ID_PARAM];\n\n/**\n * Information set up at host level to use in embedded context\n */\nexport interface MFEHostInformation {\n /**\n * URL of the host application\n */\n hostURL?: string;\n /**\n * ID of the host application\n */\n hostApplicationId?: string;\n\n /**\n * ID of the module to embed defined at host level\n */\n moduleApplicationId?: string;\n}\n\n/**\n * Gather the host information from the url parameters\n * The host url will use the first found among:\n * - look for the search parameter {@link MFE_HOST_URL_PARAM} in the URL of the iframe\n * - use the first item in `location.ancestorOrigins` (currently not supported on Firefox)\n * - use `document.referrer` (will only work if called before any redirection in the iframe)\n * The host application ID is taken from the search parameter {@link MFE_HOST_APPLICATION_ID_PARAM} in the URL of the iframe\n * The module application ID is taken from the search parameter {@link MFE_APPLICATION_ID_PARAM} in the URL of the iframe\n * @param locationParam - A {@link Location} object with information about the current location of the document. Defaults to global {@link location}.\n */\nexport function getHostInfo(locationParam: Location = location): MFEHostInformation {\n const searchParams = new URLSearchParams(locationParam.search);\n const storedHostInfo = JSON.parse(sessionStorage.getItem(SESSION_STORAGE_KEY) || '{}') as MFEHostInformation;\n return {\n hostURL: searchParams.get(MFE_HOST_URL_PARAM) || storedHostInfo.hostURL || locationParam.ancestorOrigins?.[0] || document.referrer,\n hostApplicationId: searchParams.get(MFE_HOST_APPLICATION_ID_PARAM) || storedHostInfo.hostApplicationId,\n moduleApplicationId: searchParams.get(MFE_MODULE_APPLICATION_ID_PARAM) || storedHostInfo.moduleApplicationId\n };\n}\n\n/**\n * Gather the host information from the url parameters and handle the persistence in session storage.\n */\nexport function persistHostInfo() {\n const hostInfo = getHostInfo();\n sessionStorage.setItem(SESSION_STORAGE_KEY, JSON.stringify(hostInfo));\n}\n","import {\n inject,\n Pipe,\n PipeTransform,\n SecurityContext,\n} from '@angular/core';\nimport {\n DomSanitizer,\n type SafeResourceUrl,\n} from '@angular/platform-browser';\nimport {\n MFE_HOST_APPLICATION_ID_PARAM,\n MFE_HOST_URL_PARAM,\n MFE_MODULE_APPLICATION_ID_PARAM,\n} from './host-info';\n\n/**\n * A pipe that adds the host information in the URL of an iframe,\n */\n@Pipe({\n name: 'hostInfo'\n})\nexport class HostInfoPipe implements PipeTransform {\n private readonly domSanitizer = inject(DomSanitizer);\n\n /**\n * Transforms the given URL or SafeResourceUrl by appending query parameters.\n * @param url - The URL or SafeResourceUrl to be transformed.\n * @param options - hostId and moduleId\n * @returns - The transformed SafeResourceUrl or undefined if the input URL is invalid.\n */\n public transform(url: string, options: { hostId: string; moduleId?: string }): string;\n public transform(url: SafeResourceUrl, options: { hostId: string; moduleId?: string }): SafeResourceUrl;\n public transform(url: undefined, options: { hostId: string; moduleId?: string }): undefined;\n public transform(url: string | SafeResourceUrl | undefined, options: { hostId: string; moduleId?: string }): string | SafeResourceUrl | undefined {\n const urlString = typeof url === 'string'\n ? url\n : this.domSanitizer.sanitize(SecurityContext.RESOURCE_URL, url || null);\n\n if (!url) {\n return undefined;\n }\n\n if (urlString) {\n const moduleUrl = new URL(urlString);\n moduleUrl.searchParams.set(MFE_HOST_URL_PARAM, window.location.origin);\n moduleUrl.searchParams.set(MFE_HOST_APPLICATION_ID_PARAM, options.hostId);\n if (options.moduleId) {\n moduleUrl.searchParams.set(MFE_MODULE_APPLICATION_ID_PARAM, options.moduleId);\n }\n\n const moduleUrlStringyfied = moduleUrl.toString();\n return typeof url === 'string' ? moduleUrlStringyfied : this.domSanitizer.bypassSecurityTrustResourceUrl(moduleUrlStringyfied);\n }\n }\n}\n","import type {\n VersionedMessage,\n} from '@amadeus-it-group/microfrontends';\n\n/** the error message type */\nexport const ERROR_MESSAGE_TYPE = 'error';\n\n/**\n * The possible reasons for an error.\n */\nexport type ErrorReason = 'unknown_type' | 'version_mismatch' | 'internal_error';\n\n/**\n * The content of an error message.\n * @template S - The type of the source message.\n */\nexport interface ErrorContent<S extends VersionedMessage = VersionedMessage> {\n /** The reason for the error */\n reason: ErrorReason;\n /** The source message that caused the error */\n source: S;\n}\n","import {\n USER_ACTIVITY_MESSAGE_TYPE,\n type UserActivityMessage,\n} from '@ama-mfe/messages';\n\n/**\n * Type guard to check if a message is a user activity message\n * @param message The message to check\n */\nexport function isUserActivityMessage(message: unknown): message is UserActivityMessage {\n return (\n typeof message === 'object'\n && message !== null\n && 'type' in message\n && message.type === USER_ACTIVITY_MESSAGE_TYPE\n );\n}\n","import type {\n Message,\n PeerConnectionOptions,\n} from '@amadeus-it-group/microfrontends';\nimport {\n getHostInfo,\n} from './host-info';\nimport {\n ERROR_MESSAGE_TYPE,\n} from './messages';\n\n/**\n * A constant array of known message types and their versions.\n */\nexport const KNOWN_MESSAGES = [\n {\n type: ERROR_MESSAGE_TYPE,\n version: '1.0'\n }\n] as const satisfies Message[];\n\n/**\n * Returns the default options for starting a client endpoint peer connection.\n * As `origin`, it will take the hostURL from {@link getHostInfo} and the `window` will be the parent window.\n */\nexport function getDefaultClientEndpointStartOptions(): PeerConnectionOptions {\n const hostInfo = getHostInfo();\n if (hostInfo.hostURL) {\n return {\n origin: new URL(hostInfo.hostURL).origin,\n window: window.parent\n };\n }\n return {};\n}\n\n/**\n * Return `true` if embedded inside an iframe, `false` otherwise\n * @param windowParam - A {@link window} object with information about the current window of the document. Defaults to global {@link window}.\n */\nexport function isEmbedded(windowParam: Window = window) {\n return windowParam.top !== windowParam.self;\n}\n","import {\n MESSAGE_PEER_CONFIG,\n MESSAGE_PEER_CONNECT_OPTIONS,\n MessagePeerConfig,\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n makeEnvironmentProviders,\n} from '@angular/core';\nimport {\n type Logger,\n} from '@o3r/logger';\nimport {\n provideHistoryOverrides,\n} from '../history';\nimport {\n getHostInfo,\n persistHostInfo,\n} from '../host-info';\nimport {\n getDefaultClientEndpointStartOptions,\n isEmbedded,\n KNOWN_MESSAGES,\n} from '../utils';\nimport {\n ConnectionConfig,\n ConnectionService,\n} from './connect-resources';\n\n/** Options to configure the connection inside the communication protocol */\nexport interface ConnectionConfigOptions extends Omit<ConnectionConfig, 'id'> {\n /** @inheritdoc */\n id?: string;\n /** Logger used to gather information */\n logger?: Logger;\n}\n\n/**\n * Provide the communication protocol connection configuration\n * @param connectionConfigOptions The identifier of the application in the communication protocol ecosystem plus the types of messages able to exchange and a logger object\n */\nexport function provideConnection(connectionConfigOptions?: ConnectionConfigOptions) {\n persistHostInfo();\n const connectionId = (isEmbedded() && getHostInfo().moduleApplicationId) || connectionConfigOptions?.id;\n if (!connectionId) {\n (connectionConfigOptions?.logger || console).error('An id (moduleId) needs to be provided for the application in order to establish a connection inside the communication protocol');\n return makeEnvironmentProviders([]);\n }\n const config: MessagePeerConfig = {\n id: connectionId,\n messageCheckStrategy: 'version',\n knownMessages: [...KNOWN_MESSAGES, ...(connectionConfigOptions?.knownMessages || [])]\n };\n return makeEnvironmentProviders([\n {\n provide: MESSAGE_PEER_CONFIG, useValue: config\n },\n {\n provide: MESSAGE_PEER_CONNECT_OPTIONS, useValue: getDefaultClientEndpointStartOptions()\n },\n {\n // in the case of the ConnectionService will extend the base service 'useExisting' should be used\n provide: MessagePeerService, useClass: ConnectionService, deps: [MESSAGE_PEER_CONFIG]\n },\n ...isEmbedded() ? [provideHistoryOverrides()] : []\n ]);\n}\n","import {\n NAVIGATION_MESSAGE_TYPE,\n} from '@ama-mfe/messages';\nimport type {\n NavigationMessage,\n NavigationV1_0,\n} from '@ama-mfe/messages';\nimport type {\n RoutedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n DestroyRef,\n inject,\n Injectable,\n} from '@angular/core';\nimport {\n ActivatedRoute,\n Router,\n} from '@angular/router';\nimport {\n Subject,\n} from 'rxjs';\nimport {\n hostQueryParams,\n} from '../host-info';\nimport {\n ConsumerManagerService,\n type MessageConsumer,\n} from '../managers/index';\n\n/**\n * A service that handles navigation messages and routing.\n *\n * This service listens for navigation messages and updates the router state accordingly.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class NavigationConsumerService implements MessageConsumer<NavigationMessage> {\n private readonly router = inject(Router);\n private readonly activeRoute = inject(ActivatedRoute);\n private readonly requestedUrl = new Subject<{ url: string; channelId?: string }>();\n\n /**\n * An observable that emits the requested URL and optional channel ID.\n */\n public readonly requestedUrl$ = this.requestedUrl.asObservable();\n\n /**\n * The type of messages this service handles.\n */\n public readonly type = NAVIGATION_MESSAGE_TYPE;\n\n /**\n * @inheritdoc\n */\n public readonly supportedVersions = {\n /**\n * Use the message paylod to compute a new url and emit it via the public subject\n * Additionally navigate to the new url\n * @param message message to consume\n */\n '1.0': (message: RoutedMessage<NavigationV1_0>) => {\n const channelId = message.from || undefined;\n this.requestedUrl.next({ url: message.payload.url, channelId });\n this.navigate(message.payload.url);\n }\n };\n\n private readonly consumerManagerService = inject(ConsumerManagerService);\n\n constructor() {\n this.start();\n inject(DestroyRef).onDestroy(() => this.stop());\n }\n\n /**\n * Parses a URL and returns an object containing the paths and query parameters.\n * @param url - The URL to parse.\n * @returns An object containing the paths and query parameters.\n */\n private parseUrl(url: string): { paths: string[]; queryParams: { [key: string]: string } } {\n const urlObject = new URL(window.origin + url);\n const paths = urlObject.pathname.split('/').filter((segment) => !!segment);\n const queryParams = Object.fromEntries(urlObject.searchParams.entries());\n return { paths, queryParams };\n }\n\n /**\n * Navigates to the specified URL.\n * @param url - The URL to navigate to.\n */\n private navigate(url: string) {\n const { paths, queryParams } = this.parseUrl(url);\n // No need to keep these in the URL\n hostQueryParams.forEach((key) => delete queryParams[key]);\n void this.router.navigate(paths, { relativeTo: this.activeRoute.children.at(-1), queryParams });\n }\n\n /**\n * @inheritdoc\n */\n public start() {\n this.consumerManagerService.register(this);\n }\n\n /**\n * @inheritdoc\n */\n public stop() {\n this.consumerManagerService.unregister(this);\n }\n}\n","import {\n Injectable,\n} from '@angular/core';\n\n/**\n * This service allows routes to be memorized with an optional lifetime and provides methods to retrieve and manage these routes.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class RouteMemorizeService {\n private readonly routeTimers: { [x: string]: ReturnType<typeof setTimeout> } = {};\n /** All memorized routes */\n public readonly routeStack: { [x: string]: string } = {};\n\n /**\n * Memorizes a route for a given channel ID with an optional lifetime.\n * @param channelId - The ID of the channel to memorize the route for.\n * @param url - The URL of the route to memorize.\n * @param liveTime - The optional lifetime of the memorized route in milliseconds. If provided, the route will be removed after this time.\n */\n public memorizeRoute(channelId: string, url: string, liveTime?: number): void {\n this.routeStack[channelId] = url;\n\n const timerRef = this.routeTimers[channelId];\n if (timerRef) {\n clearTimeout(timerRef);\n }\n if (liveTime && liveTime > 0) {\n this.routeTimers[channelId] = setTimeout(() => {\n delete this.routeStack[channelId];\n delete this.routeTimers[channelId];\n }, liveTime);\n }\n }\n\n /**\n * Retrieves the memorized route for a given channel ID.\n * @param channelId - The ID of the channel to retrieve the memorized route for.\n * @returns The memorized route URL or undefined if no route is memorized for the given channel ID.\n */\n public getRoute(channelId: string): string | undefined {\n return this.routeStack[channelId];\n }\n}\n","import {\n inject,\n Pipe,\n PipeTransform,\n SecurityContext,\n} from '@angular/core';\nimport {\n DomSanitizer,\n type SafeResourceUrl,\n} from '@angular/platform-browser';\nimport {\n ActivatedRoute,\n} from '@angular/router';\nimport {\n RouteMemorizeService,\n} from './route-memorize/route-memorize-service';\n\n/**\n * Options for restoring a route with optional query parameters and memory channel ID.\n */\nexport interface RestoreRouteOptions {\n /**\n * Whether to propagate query parameters from the top window to the module URL.\n */\n propagateQueryParams?: boolean;\n\n /**\n * Whether to override existing query parameters in the module URL with those from the top window.\n */\n overrideQueryParams?: boolean;\n\n /**\n * The memory channel ID used to retrieve the memorized route.\n * If provided, the memorized route associated with this ID will be used.\n */\n memoryChannelId?: string;\n}\n\n/**\n * A pipe that restores a route with optional query parameters and memory channel ID.\n *\n * This pipe is used to transform a URL or SafeResourceUrl by appending query parameters\n * and adjusting the pathname based on the current active route and memorized route.\n */\n@Pipe({\n name: 'restoreRoute'\n})\nexport class RestoreRoute implements PipeTransform {\n private readonly activeRoute = inject(ActivatedRoute);\n private readonly domSanitizer = inject(DomSanitizer);\n private readonly routeMemorizeService = inject(RouteMemorizeService, { optional: true });\n private readonly window = inject(Window, { optional: true }) || window;\n\n /**\n * Transforms the given URL or SafeResourceUrl by appending query parameters and adjusting the pathname.\n * @param url - The URL or SafeResourceUrl to be transformed.\n * @param options - Optional parameters to control the transformation. {@link RestoreRouteOptions}\n * @returns - The transformed SafeResourceUrl or undefined if the input URL is invalid.\n */\n public transform(url: string, options?: Partial<RestoreRouteOptions>): string;\n public transform(url: SafeResourceUrl, options?: Partial<RestoreRouteOptions>): SafeResourceUrl;\n public transform(url: undefined, options?: Partial<RestoreRouteOptions>): undefined;\n public transform(url: string | SafeResourceUrl | undefined, options?: Partial<RestoreRouteOptions>): string | SafeResourceUrl | undefined {\n const urlString = typeof url === 'string'\n ? url\n : this.domSanitizer.sanitize(SecurityContext.RESOURCE_URL, url || null);\n\n if (!url) {\n return undefined;\n }\n\n if (urlString) {\n const moduleUrl = new URL(urlString);\n const queryParamsModule = new URLSearchParams(moduleUrl.searchParams);\n\n const channelId = options?.memoryChannelId;\n const memorizedRoute = channelId && this.routeMemorizeService?.getRoute(channelId);\n const topWindowUrl = new URL(memorizedRoute ? this.window.origin + memorizedRoute : this.window.location.href);\n const queryParamsTopWindow = new URLSearchParams(topWindowUrl.search);\n\n if (options?.propagateQueryParams) {\n for (const [key, value] of queryParamsTopWindow) {\n if (options?.overrideQueryParams || !queryParamsModule.has(key)) {\n queryParamsModule.set(key, value);\n }\n }\n }\n moduleUrl.search = queryParamsModule.toString();\n moduleUrl.pathname += topWindowUrl.pathname.split(`/${this.activeRoute.routeConfig?.path}`).pop() || '';\n moduleUrl.pathname = moduleUrl.pathname.replace(/\\/{2,}/g, '/');\n const moduleUrlStringyfied = moduleUrl.toString();\n return typeof url === 'string' ? moduleUrlStringyfied : this.domSanitizer.bypassSecurityTrustResourceUrl(moduleUrlStringyfied);\n }\n }\n}\n","import {\n computed,\n Directive,\n effect,\n inject,\n input,\n untracked,\n} from '@angular/core';\nimport {\n toSignal,\n} from '@angular/core/rxjs-interop';\nimport {\n NavigationConsumerService,\n} from '../navigation-consumer-service';\nimport {\n RouteMemorizeService,\n} from './route-memorize-service';\n\n@Directive({\n selector: 'iframe[memorizeRoute]',\n standalone: true\n})\nexport class RouteMemorizeDirective {\n /**\n * Whether to memorize the route.\n * Default is true.\n */\n public memorizeRoute = input<boolean | undefined | ''>(true);\n\n /**\n * The ID used to memorize the route.\n */\n public memorizeRouteId = input<string>();\n\n /**\n * The maximum age for memorizing the route.\n * Default is 0.\n */\n public memorizeMaxAge = input<number>(0);\n\n /**\n * The maximum age for memorizing the route, used as a fallback.\n * Default is 0.\n */\n public memorizeRouteMaxAge = input<number>(0);\n\n /**\n * The connection ID for the iframe where the actual directive is applied.\n */\n public connect = input<string>();\n\n private readonly maxAge = computed(() => {\n return this.memorizeMaxAge() || this.memorizeRouteMaxAge();\n });\n\n constructor() {\n const memory = inject(RouteMemorizeService);\n const requestedUrlSignal = toSignal(inject(NavigationConsumerService).requestedUrl$);\n\n /**\n * This effect listens for changes in the `memorizeRoute`, `requestedUrlSignal`, and `memorizeRouteId` or `connect` inputs.\n * If `memorizeRoute` is not false and a requested URL with a matching channel ID is found, it memorizes the route using the route memory service.\n */\n effect(() => {\n const memorizeRoute = this.memorizeRoute();\n if (memorizeRoute === false) {\n return;\n }\n const requested = requestedUrlSignal();\n const channelId = this.connect();\n const id = this.memorizeRouteId() || channelId;\n if (requested && id && requested.channelId === channelId) {\n memory.memorizeRoute(id, requested.url, untracked(this.maxAge));\n }\n });\n }\n}\n","import type {\n NavigationMessage,\n NavigationV1_0,\n} from '@ama-mfe/messages';\nimport {\n NAVIGATION_MESSAGE_TYPE,\n} from '@ama-mfe/messages';\nimport type {\n RoutedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n inject,\n Injectable,\n} from '@angular/core';\nimport {\n takeUntilDestroyed,\n} from '@angular/core/rxjs-interop';\nimport {\n ActivatedRoute,\n NavigationEnd,\n Router,\n} from '@angular/router';\nimport {\n LoggerService,\n} from '@o3r/logger';\nimport {\n filter,\n map,\n} from 'rxjs';\nimport {\n type MessageConsumer,\n type MessageProducer,\n registerConsumer,\n registerProducer,\n} from '../managers/index';\nimport {\n type ErrorContent,\n} from '../messages/error';\nimport {\n isEmbedded,\n} from '../utils';\n\n/** Options for the routing handling in case of navigation producer message */\nexport interface RoutingServiceOptions {\n /**\n * Whether to handle only sub-routes.\n * If true, the routing service will handle only sub-routes.\n * Default is false.\n */\n subRouteOnly?: boolean;\n}\n\n/**\n * A service that keeps in sync Router navigation and navigation messages.\n *\n * - listens to Router events and sends navigation messages\n * - handles incoming navigation messages and triggers Router navigation\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class RoutingService implements MessageProducer<NavigationMessage>, MessageConsumer<NavigationMessage> {\n private readonly router = inject(Router);\n private readonly activatedRoute = inject(ActivatedRoute);\n private readonly messageService = inject(MessagePeerService<NavigationMessage>);\n private readonly logger = inject(LoggerService);\n private readonly window = inject(Window, { optional: true }) || window;\n\n /**\n * @inheritdoc\n */\n public readonly types = NAVIGATION_MESSAGE_TYPE;\n\n /**\n * @inheritdoc\n */\n public readonly type = 'navigation';\n\n /**\n * Use the message payload to navigate to the specified URL.\n * @param message message to consume\n */\n public readonly supportedVersions = {\n '1.0': async (message: RoutedMessage<any>) => {\n await this.router.navigateByUrl(message.payload.url);\n }\n };\n\n constructor() {\n registerProducer(this);\n registerConsumer(this);\n }\n\n /**\n * @inheritdoc\n */\n public start(): void {}\n\n /**\n * @inheritdoc\n */\n public stop(): void {}\n\n /**\n * @inheritdoc\n */\n public handleError(message: ErrorContent<NavigationV1_0>): void {\n this.logger.error('Error in navigation service message', message);\n }\n\n /**\n * Handles embedded routing by listening to router events and sending navigation messages to the connected endpoints.\n * It can be a parent window or another iframe\n * @note - This method has to be called in an injection context\n * @param options - Optional parameters to control the routing behavior {@link RoutingServiceOptions}.\n */\n public handleEmbeddedRouting(options?: RoutingServiceOptions): void {\n const subRouteOnly = options?.subRouteOnly ?? false;\n this.router.events.pipe(\n takeUntilDestroyed(),\n filter((event): event is NavigationEnd => event instanceof NavigationEnd),\n filter((_event) => !this.router.getCurrentNavigation()?.extras?.skipLocationChange),\n map(({ urlAfterRedirects }) => {\n const channelId = this.router.getCurrentNavigation()?.extras?.state?.channelId;\n const currentRouteRegExp = subRouteOnly && this.activatedRoute.routeConfig?.path && new RegExp('^' + this.activatedRoute.routeConfig.path.replace(/(?=\\W)/g, '\\\\'), 'i');\n return ({ url: currentRouteRegExp ? urlAfterRedirects.replace(currentRouteRegExp, '') : urlAfterRedirects, channelId });\n })\n ).subscribe(({ url, channelId }) => {\n const messageV10 = {\n type: 'navigation',\n version: '1.0',\n url\n } satisfies NavigationV1_0;\n // TODO: sendBest() is not implemented -- https://github.com/AmadeusITGroup/microfrontends/issues/11\n if (isEmbedded(this.window)) {\n this.messageService.send(messageV10);\n } else {\n if (channelId === undefined) {\n this.logger.warn('No channelId provided for navigation message');\n } else {\n try {\n this.messageService.send(messageV10, { to: [channelId] });\n } catch (error) {\n this.logger.error('Error sending navigation message', error);\n }\n }\n }\n });\n }\n}\n","import type {\n ResizeMessage,\n ResizeV1_0,\n} from '@ama-mfe/messages';\nimport {\n RESIZE_MESSAGE_TYPE,\n} from '@ama-mfe/messages';\nimport type {\n RoutedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n DestroyRef,\n inject,\n Injectable,\n signal,\n} from '@angular/core';\nimport {\n ConsumerManagerService,\n MessageConsumer,\n} from '../managers/index';\n\n/**\n * This service listens for resize messages and updates the height of elements based on the received messages.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ResizeConsumerService implements MessageConsumer<ResizeMessage> {\n private readonly newHeight = signal<{ height: number; channelId: string } | undefined>(undefined);\n\n /**\n * A readonly signal that provides the new height information from the channel.\n */\n public readonly newHeightFromChannel = this.newHeight.asReadonly();\n\n /**\n * The type of messages this service handles ('resize').\n */\n public readonly type = RESIZE_MESSAGE_TYPE;\n\n /**\n * The supported versions of resize messages and their handlers.\n */\n public supportedVersions = {\n /**\n * Use the message paylod to compute a new height and emit it via the public signal\n * @param message message to consume\n */\n '1.0': (message: RoutedMessage<ResizeV1_0>) => this.newHeight.set({ height: message.payload.height, channelId: message.from })\n };\n\n private readonly consumerManagerService = inject(ConsumerManagerService);\n\n constructor() {\n this.start();\n inject(DestroyRef).onDestroy(() => this.stop());\n }\n\n /**\n * Starts the resize handler service by registering it into the consumer manager service.\n */\n public start() {\n this.consumerManagerService.register(this);\n }\n\n /**\n * Stops the resize handler service by unregistering it from the consumer manager service.\n */\n public stop() {\n this.consumerManagerService.unregister(this);\n }\n}\n","import type {\n ResizeMessage,\n ResizeV1_0,\n} from '@ama-mfe/messages';\nimport {\n RESIZE_MESSAGE_TYPE,\n} from '@ama-mfe/messages';\nimport {\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n afterNextRender,\n inject,\n Injectable,\n} from '@angular/core';\nimport {\n type MessageProducer,\n registerProducer,\n} from '../managers/index';\nimport {\n type ErrorContent,\n} from '../messages/index';\n\n/**\n * This service observe changes in the document's body height.\n * When the height changes, it sends a resize message with the new height, to the connected peers\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ResizeService implements MessageProducer<ResizeMessage> {\n private actualHeight?: number;\n private readonly messageService = inject(MessagePeerService<ResizeMessage>);\n private resizeObserver?: ResizeObserver;\n\n /**\n * @inheritdoc\n */\n public readonly types = RESIZE_MESSAGE_TYPE;\n\n constructor() {\n registerProducer(this);\n }\n\n /**\n * @inheritdoc\n */\n public handleError(message: ErrorContent<ResizeMessage>): void {\n // eslint-disable-next-line no-console -- error handling placeholder\n console.error('Error in resize service message', message);\n }\n\n /**\n * This method sets up a `ResizeObserver` to observe changes in the document's body height.\n * When the height changes, it sends a resize message with the new height, to the connected peers\n */\n public startResizeObserver() {\n this.resizeObserver = new ResizeObserver(() => {\n const newHeight = document.body.getBoundingClientRect().height;\n if (!this.actualHeight || newHeight !== this.actualHeight) {\n this.actualHeight = newHeight;\n const messageV10 = {\n type: 'resize',\n version: '1.0',\n height: this.actualHeight\n } satisfies ResizeV1_0;\n // TODO: sendBest() is not implemented -- https://github.com/AmadeusITGroup/microfrontends/issues/11\n this.messageService.send(messageV10);\n }\n });\n\n afterNextRender(() => this.resizeObserver?.observe(document.body));\n }\n}\n","import {\n computed,\n Directive,\n effect,\n ElementRef,\n inject,\n input,\n Renderer2,\n} from '@angular/core';\nimport {\n ResizeConsumerService,\n} from './resize-consumer-service';\n\n/**\n * A directive that adjusts the height of an element based on resize messages from a specified channel.\n */\n@Directive({\n selector: '[scalable]',\n standalone: true\n})\nexport class ScalableDirective {\n /**\n * The connection ID for the element, used as channel id backup\n */\n public connect = input<string>();\n\n /**\n * The channel id\n */\n public scalable = input<string>();\n\n private readonly resizeHandler = inject(ResizeConsumerService);\n\n /**\n * This signal checks if the current channel requesting the resize matches the channel ID from the resize handler.\n * If they match, it returns the new height information; otherwise, it returns undefined.\n */\n private readonly newHeightFromChannel = computed(() => {\n const channelAskingResize = this.scalable() || this.connect();\n const newHeightFromChannel = this.resizeHandler.newHeightFromChannel();\n if (channelAskingResize && newHeightFromChannel?.channelId === channelAskingResize) {\n return newHeightFromChannel;\n }\n return undefined;\n });\n\n constructor() {\n const elem = inject(ElementRef);\n const renderer = inject(Renderer2);\n\n this.resizeHandler.start();\n\n /** When a new height value is received set the height of the host element (in pixels) */\n effect(() => {\n const newHeightFromChannel = this.newHeightFromChannel();\n if (newHeightFromChannel) {\n renderer.setStyle(elem.nativeElement, 'height', `${newHeightFromChannel.height}px`);\n }\n });\n }\n}\n","import {\n type Logger,\n} from '@o3r/logger';\nimport {\n getHostInfo,\n} from '../host-info';\n\n/** Default suffix for an url containing a theme css file */\nexport const THEME_URL_SUFFIX = '-theme.css';\n/** Default name for the query parameter containing the theme name */\nexport const THEME_QUERY_PARAM_NAME = 'theme';\n\n/** Options and context for Style helpers */\nexport interface StyleHelperOptions {\n /**\n * Logger to reporter the logs\n */\n logger?: Logger;\n}\n\n/**\n * Fetches a CSS document and returns the content as a string.\n * @param cssPath - The path to download the CSS.\n * @param options Options and context for Style helpers\n * @returns The content of the CSS document as a string, empty string if the fetch fails.\n */\nexport async function getStyle(cssPath: string, options?: StyleHelperOptions): Promise<string> {\n try {\n const myRequest = new Request(cssPath);\n const response = await fetch(myRequest);\n const cssText = response.ok ? await response.text() : '';\n return cssText;\n } catch (error) {\n options?.logger?.warn(`Failed to download style from: ${cssPath} with error: ${error?.toString()}`);\n }\n return '';\n}\n\n/**\n * Applies the given CSS theme as a stylesheet.\n * @param themeValue - CSS as text containing a theme definition.\n * @param cleanPrevious - Whether to remove previously applied stylesheets if no themeValue provided. Default is true.\n */\nexport function applyTheme(themeValue?: string, cleanPrevious = true): void {\n if (themeValue !== undefined) {\n const sheet = new CSSStyleSheet();\n sheet.replaceSync(themeValue);\n document.adoptedStyleSheets = cleanPrevious ? [sheet] : [...document.adoptedStyleSheets, sheet];\n } else if (cleanPrevious) { // remove the styles if the theme value comes undefined or empty string\n document.adoptedStyleSheets = [];\n }\n}\n\n/**\n * Download the application additional theme\n * @param theme Name of the theme to download from the current application\n * @param options Options and context for Style helpers\n */\nexport function downloadApplicationThemeCss(theme: string, options?: StyleHelperOptions) {\n const cssHref = `${theme.endsWith('.css') ? theme : theme + THEME_URL_SUFFIX}`;\n return getStyle(cssHref, options);\n}\n\n/**\n * Applies the initial theme based on the URL query parameters.\n *\n * This function fetches the CSS theme specified in the URL query parameters and applies it as a stylesheet.\n * If a referrer is present, it also attempts to fetch and apply the theme from the referrer's URL.\n * @param options Options and context for Style helpers\n */\nexport async function applyInitialTheme(options?: StyleHelperOptions): Promise<PromiseSettledResult<void>[] | undefined> {\n const searchParams = new URLSearchParams(window.location.search);\n const theme = searchParams.get(THEME_QUERY_PARAM_NAME);\n document.adoptedStyleSheets = [];\n if (theme) {\n const themeRequest: Promise<void>[] = [\n downloadApplicationThemeCss(theme, options).then((styleToApply) => applyTheme(styleToApply, false))\n ];\n const hostInfo = getHostInfo();\n if (hostInfo.hostURL) {\n const url = new URL(hostInfo.hostURL);\n url.pathname += `${url.pathname.endsWith('/') ? '' : '/'}${theme}`;\n themeRequest.unshift(getStyle(url.toString(), options).then((styleToApply) => applyTheme(styleToApply, false)));\n }\n\n return Promise.allSettled(themeRequest);\n }\n return undefined;\n}\n","import type {\n ThemeMessage,\n ThemeV1_0,\n} from '@ama-mfe/messages';\nimport {\n THEME_MESSAGE_TYPE,\n ThemeStructure,\n} from '@ama-mfe/messages';\nimport {\n MessagePeerService,\n} from '@amadeus-it-group/microfrontends-angular';\nimport {\n effect,\n inject,\n Injectable,\n signal,\n} from '@angular/core';\nimport {\n LoggerService,\n} from '@o3r/logger';\nimport {\n type MessageProducer,\n registerProducer,\n} from '../managers/index';\nimport {\n type ErrorContent,\n} from '../messages/index';\nimport {\n applyTheme,\n getStyle,\n THEME_QUERY_PARAM_NAME,\n THEME_URL_SUFFIX,\n} from './theme-helpers';\n/**\n * This service exposing the current theme signal\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ThemeProducerService implements MessageProducer<ThemeMessage> {\n private readonly messageService = inject(MessagePeerService<ThemeMessage>);\n private readonly logger = inject(LoggerService);\n private previousTheme: ThemeStructure | undefined;\n private readonly window = inject(Window, { optional: true }) || window;\n\n private readonly currentThemeSelection;\n /** Current selected theme signal */\n public readonly currentTheme;\n\n /**\n * The type of messages this service handles ('theme').\n */\n public readonly types = THEME_MESSAGE_TYPE;\n\n constructor() {\n registerProducer(this);\n\n // get the current theme name from the url (if any) and emit a first value for the current theme\n const parentUrl = new URL(this.window.location.toString());\n const selectedThemeName = parentUrl.searchParams.get(THEME_QUERY_PARAM_NAME);\n this.currentThemeSelection = signal<ThemeStructure | undefined>(selectedThemeName\n ? {\n name: selectedThemeName,\n css: null\n }\n : undefined);\n this.currentTheme = this.currentThemeSelection.asReadonly();\n\n if (selectedThemeName) {\n void this.changeTheme(selectedThemeName);\n }\n\n // When the current theme changes, apply it to the current application\n effect(() => {\n const themeObj = this.currentTheme();\n if (themeObj?.css !== null) {\n applyTheme(themeObj?.css);\n }\n });\n\n /**\n * This effect listens for changes in the `currentTheme` signal. If a valid theme object with CSS is present,\n * it creates a theme message and sends it via the message service.\n */\n effect(() => {\n const themeObj = this.currentTheme();\n if (themeObj && themeObj.css !== null) {\n const messageV10 = {\n type: 'theme',\n name: themeObj.name,\n css: themeObj.css,\n version: '1.0'\n } satisfies ThemeV1_0;\n // TODO: sendBest() is not yet implemented -- https://github.com/AmadeusITGroup/microfrontends/issues/11\n this.messageService.send(messageV10);\n }\n });\n }\n\n /**\n * Changes the current theme to the specified theme name.\n * @param themeName - The name of the theme to change to.\n */\n public async changeTheme(themeName?: string): Promise<void> {\n const cssHref = themeName && `${themeName}${THEME_URL_SUFFIX}`;\n const styleObj = cssHref ? await getStyle(cssHref) : '';\n this.currentThemeSelection.update((theme) => {\n this.previousTheme = theme;\n return themeName\n ? { name: themeName, css: styleObj }\n : undefined;\n });\n }\n\n /**\n * Reverts to the previous theme.\n */\n public revertToPreviousTheme(): void {\n this.currentThemeSelection.set(this.previousTheme);\n }\n\n /**\n * @inheritdoc\n */\n public handleError(message: ErrorContent<ThemeV1_0>): void {\n this.logger.error('Error in theme service message', message);\n this.revertToPreviousTheme();\n }\n}\n","import {\n inject,\n Pipe,\n PipeTransform,\n SecurityContext,\n} from '@angular/core';\nimport {\n DomSanitizer,\n type SafeResourceUrl,\n} from '@angular/platform-browser';\nimport {\n ThemeProducerService,\n} from './theme-producer-service';\n\n/**\n * A pipe that applies the current theme from a theme manager service, to a given URL or SafeResourceUrl, as query param\n */\n@Pipe({\n name: 'applyTheme'\n})\nexport class ApplyTheme implements PipeTransform {\n private readonly themeManagerService = inject(ThemeProducerService);\n private readonly domSanitizer = inject(DomSanitizer);\n\n /**\n * Transforms the given URL or SafeResourceUrl by appending the current theme value as a query parameter.\n * @param url - The URL or SafeResourceUrl to be transformed.\n * @returns The transformed SafeResourceUrl or undefined if the input URL is invalid.\n */\n public transform(url: string): string;\n public transform(url: SafeResourceUrl): SafeResourceUrl;\n public transform(url: undefined): undefined;\n public transform(url: string | SafeResourceUrl | undefined): string | SafeResourceUrl | undefined {\n if (!url) {\n return undefined;\n }\n const currentTheme = this.themeManagerService.currentTheme();\n const urlString = typeof url === 'string'\n ? url\n : this.domSanitizer.sanitize(SecurityContext.RESOURCE_URL, url);\n\n if (urlString) {\n const moduleUrl = new URL(urlString);\n if (currentTheme) {\n moduleUrl.searchParams.set('theme', currentTheme.name);\n }\n const moduleUrlStringyfied = moduleUrl.toString();\n return typeof url === 'string' ? moduleUrlStringyfied : this.domSanitizer.bypassSecurityTrustResourceUrl(moduleUrlStringyfied);\n }\n\n return undefined;\n }\n}\n","import type {\n ThemeMessage,\n ThemeV1_0,\n} from '@ama-mfe/messages';\nimport {\n THEME_MESSAGE_TYPE,\n} from '@ama-mfe/messages';\nimport type {\n RoutedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n DestroyRef,\n inject,\n Injectable,\n SecurityContext,\n} from '@angular/core';\nimport {\n DomSanitizer,\n} from '@angular/platform-browser';\nimport {\n LoggerService,\n} from '@o3r/logger';\nimport {\n ConsumerManagerService,\n MessageConsumer,\n} from '../managers/index';\nimport {\n applyTheme,\n downloadApplicationThemeCss,\n} from './theme-helpers';\n\n/**\n * A service that handles theme messages and applies the received theme.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ThemeConsumerService implements MessageConsumer<ThemeMessage> {\n private readonly domSanitizer = inject(DomSanitizer);\n private readonly consumerManagerService = inject(ConsumerManagerService);\n private readonly logger = inject(LoggerService);\n /**\n * The type of messages this service handles ('theme').\n */\n public readonly type = THEME_MESSAGE_TYPE;\n\n /**\n * The supported versions of theme messages and their handlers.\n */\n public readonly supportedVersions = {\n /**\n * Use the message paylod to get the theme and apply it\n * @param message message to consume\n */\n '1.0': async (message: RoutedMessage<ThemeV1_0>) => {\n const sanitizedCss = this.domSanitizer.sanitize(SecurityContext.STYLE, message.payload.css);\n if (sanitizedCss !== null) {\n applyTheme(sanitizedCss);\n }\n try {\n const css = await downloadApplicationThemeCss(message.payload.name, { logger: this.logger });\n applyTheme(css, false);\n } catch (e) {\n this.logger.warn(`No CSS variable for the theme ${message.payload.name}`, e);\n }\n }\n };\n\n constructor() {\n this.start();\n inject(DestroyRef).onDestroy(() => this.stop());\n }\n\n /**\n * Starts the theme handler service by registering it into the consumer manager service.\n */\n public start() {\n this.consumerManagerService.register(this);\n }\n\n /**\n * Stops the theme handler service by unregistering it from the consumer manager service.\n */\n public stop() {\n this.consumerManagerService.unregister(this);\n }\n}\n","import type {\n UserActivityEventType,\n} from '@ama-mfe/messages';\nimport type {\n ActivityProducerConfig,\n} from './interfaces';\n\n/**\n * DOM events that indicate user activity\n */\nexport const ACTIVITY_EVENTS: readonly Exclude<UserActivityEventType, 'visibilitychange'>[] = [\n 'click',\n 'keydown',\n 'scroll',\n 'touchstart',\n 'focus'\n];\n\n/**\n * Custom activity event type for iframe interactions.\n * Emitted programmatically when an iframe gains focus, not from a DOM event listener.\n */\nexport const IFRAME_INTERACTION_EVENT: UserActivityEventType = 'iframeinteraction';\n\n/**\n * Custom activity event type for visibility changes.\n * Emitted programmatically when the document becomes visible, not from a DOM event listener.\n */\nexport const VISIBILITY_CHANGE_EVENT: UserActivityEventType = 'visibilitychange';\n\n/**\n * High-frequency events that require throttling to avoid performance issues\n */\nexport const HIGH_FREQUENCY_EVENTS: readonly UserActivityEventType[] = [\n 'scroll'\n];\n\n/**\n * Default configuration values for the ActivityProducerService\n */\nexport const DEFAULT_ACTIVITY_PRODUCER_CONFIG: Readonly<ActivityProducerConfig> = {\n /** Default throttle time in milliseconds between activity messages */\n throttleMs: 1000,\n /** Default throttle time in milliseconds for high-frequency events */\n highFrequencyThrottleMs: 300,\n /** Whether to track nested iframes by default */\n trackNestedIframes: false,\n /** Default interval for iframe activity signals (30 seconds) */\n nestedIframeActivityEmitIntervalMs: 30_000,\n /** Default polling interval for detecting iframe focus changes (1 second) */\n nestedIframePollIntervalMs: 1000\n};\n","import {\n Injectable,\n} from '@angular/core';\nimport type {\n IframeActivityTrackerConfig,\n} from './interfaces';\n\n/**\n * Service that tracks user activity within nested iframes.\n *\n * Polls document.activeElement frequently to detect when an iframe has focus.\n * When an iframe gains focus, emits immediately and then at the configured interval.\n * When focus leaves the iframe, it stops emitting.\n *\n * This is needed because cross-origin iframes don't fire focus/blur events\n * that bubble to the parent, and the regular activity tracker can't detect\n * user interactions inside iframes.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class IframeActivityTrackerService {\n /**\n * Interval ID for polling activeElement\n */\n private pollIntervalId?: ReturnType<typeof setInterval>;\n\n /**\n * Interval ID for emitting activity at configured interval\n */\n private activityIntervalId?: ReturnType<typeof setInterval>;\n\n /**\n * Current configuration\n */\n private config?: IframeActivityTrackerConfig;\n\n /**\n * Bound visibility change handler for cleanup\n */\n private readonly visibilityChangeHandler = () => this.handleVisibilityChange();\n\n /**\n * Whether the service has been started\n */\n private get started() {\n return this.config !== undefined;\n }\n\n /**\n * Whether we are currently tracking iframe activity (iframe had focus on last poll)\n */\n private get isTrackingIframeActivity() {\n return this.activityIntervalId !== undefined;\n }\n\n /**\n * Polls document.activeElement to detect iframe focus changes.\n * When iframe gains focus: emit immediately and start activity interval.\n * When iframe loses focus: stop activity interval.\n */\n private checkActiveElement(): void {\n const activeElement = document.activeElement;\n const iframeFocused = activeElement instanceof HTMLIFrameElement;\n\n if (iframeFocused && !this.isTrackingIframeActivity) {\n // Iframe just gained focus - emit immediately and start activity interval\n this.config?.onActivity();\n this.startActivityInterval();\n } else if (!iframeFocused && this.isTrackingIframeActivity) {\n // Focus left the iframe - stop activity interval\n this.stopActivityInterval();\n }\n }\n\n /**\n * Handles visibility change events to pause/resume polling when tab visibility changes.\n */\n private handleVisibilityChange(): void {\n if (document.visibilityState === 'visible') {\n this.startPolling();\n } else {\n this.stopPolling();\n this.stopActivityInterval();\n }\n }\n\n /**\n * Starts polling for active element changes.\n */\n private startPolling(): void {\n if (this.pollIntervalId) {\n return;\n }\n this.pollIntervalId = setInterval(\n () => this.checkActiveElement(),\n this.config!.pollIntervalMs\n );\n }\n\n /**\n * Stops polling for active element changes.\n */\n private stopPolling(): void {\n if (this.pollIntervalId) {\n clearInterval(this.pollIntervalId);\n this.pollIntervalId = undefined;\n }\n }\n\n /**\n * Starts the activity emission interval.\n */\n private startActivityInterval(): void {\n this.stopActivityInterval();\n this.activityIntervalId = setInterval(() => {\n this.config?.onActivity();\n }, this.config!.activityIntervalMs);\n }\n\n /**\n * Stops the activity emission interval.\n */\n private stopActivityInterval(): void {\n if (this.activityIntervalId) {\n clearInterval(this.activityIntervalId);\n this.activityIntervalId = undefined;\n }\n }\n\n /**\n * Starts tracking nested iframes within the document.\n * @param config Configuration for the tracker\n */\n public start(config: IframeActivityTrackerConfig): void {\n if (this.started) {\n return;\n }\n this.config = config;\n\n // Listen for visibility changes to pause/resume polling\n document.addEventListener('visibilitychange', this.visibilityChangeHandler);\n\n // Only start polling if document is currently visible\n if (document.visibilityState === 'visible') {\n this.startPolling();\n }\n }\n\n /**\n * Stops tracking nested iframes and cleans up resources.\n */\n public stop(): void {\n if (!this.started) {\n return;\n }\n\n document.removeEventListener('visibilitychange', this.visibilityChangeHandler);\n this.stopPolling();\n this.stopActivityInterval();\n this.config = undefined;\n }\n}\n","import {\n USER_ACTIVITY_MESSAGE_TYPE,\n type UserActivityEventType,\n type UserActivityMessage,\n type UserActivityMessageV1_0,\n} from '@ama-mfe/messages';\nimport {\n afterNextRender,\n DestroyRef,\n inject,\n Injectable,\n signal,\n} from '@angular/core';\nimport {\n LoggerService,\n} from '@o3r/logger';\nimport {\n ConnectionService,\n} from '../connect/index';\nimport {\n type MessageProducer,\n registerProducer,\n} from '../managers';\nimport type {\n ErrorContent,\n} from '../messages';\nimport {\n ACTIVITY_EVENTS,\n DEFAULT_ACTIVITY_PRODUCER_CONFIG,\n HIGH_FREQUENCY_EVENTS,\n IFRAME_INTERACTION_EVENT,\n VISIBILITY_CHANGE_EVENT,\n} from './config';\nimport {\n IframeActivityTrackerService,\n} from './iframe-activity-tracker.service';\nimport type {\n ActivityInfo,\n ActivityProducerConfig,\n} from './interfaces';\n\n/**\n * Generic service that tracks user activity and sends messages.\n * Can be configured for different contexts (cockpit or modules) via start() method parameter.\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ActivityProducerService implements MessageProducer<UserActivityMessage> {\n private readonly messageService = inject(ConnectionService);\n private readonly destroyRef = inject(DestroyRef);\n private readonly iframeActivityTracker = inject(IframeActivityTrackerService);\n private readonly logger = inject(LoggerService);\n\n /**\n * Timestamp of the last sent activity message\n */\n private lastSentTimestamp = 0;\n\n /**\n * Bound event listeners for cleanup\n */\n private readonly boundListeners = new Map<UserActivityEventType, EventListener>();\n\n /**\n * Last emission timestamps for throttled high-frequency events\n */\n private readonly lastEmitTimestamps = new Map<UserActivityEventType, number>();\n\n /**\n * Whether the service has been started\n */\n private started = false;\n\n /**\n * Signal that emits local activity information.\n * This allows consumers to react to activity detected by this producer.\n */\n private readonly localActivityWritable = signal<ActivityInfo | undefined>(undefined);\n\n /**\n * Read-only signal containing the latest local activity info.\n * Use this signal to react to locally detected activity.\n */\n public readonly localActivity = this.localActivityWritable.asReadonly();\n\n /**\n * @inheritdoc\n */\n public readonly types = USER_ACTIVITY_MESSAGE_TYPE;\n\n constructor() {\n registerProducer(this);\n this.destroyRef.onDestroy(() => this.stop());\n }\n\n /**\n * Checks if a high-frequency event should be processed based on throttle timing.\n * This is called before shouldBroadcast to avoid expensive filter operations on every event.\n * @param eventType The type of activity event\n * @param throttleMs The throttle interval in milliseconds\n * @returns true if the event should be processed, false if it should be skipped\n */\n private shouldProcessHighFrequencyEvent(eventType: UserActivityEventType, throttleMs: number): boolean {\n const now = Date.now();\n const lastEmit = this.lastEmitTimestamps.get(eventType) ?? 0;\n\n if (now - lastEmit >= throttleMs) {\n this.lastEmitTimestamps.set(eventType, now);\n return true;\n }\n return false;\n }\n\n /**\n * Handles activity by sending a throttled message and emitting to local signal.\n * @param eventType The type of activity event that occurred\n * @param configObject\n */\n private onActivity(eventType: UserActivityEventType, configObject: ActivityProducerConfig): void {\n const now = Date.now();\n\n // Always emit local activity signal (not throttled for local detection)\n this.localActivityWritable.set({\n channelId: 'local',\n eventType,\n timestamp: now\n });\n\n // Send message with throttling\n if (now - this.lastSentTimestamp >= configObject.throttleMs) {\n this.lastSentTimestamp = now;\n this.sendActivityMessage(eventType, now);\n }\n }\n\n /**\n * Sends an activity message.\n * @param eventType The type of activity event\n * @param timestamp The timestamp of the event\n */\n private sendActivityMessage(eventType: UserActivityEventType, timestamp: number): void {\n const message: UserActivityMessageV1_0 = {\n type: USER_ACTIVITY_MESSAGE_TYPE,\n version: '1.0',\n eventType,\n timestamp\n };\n const registeredPeersIdsForUserActivity = [...this.messageService.knownPeers.entries()]\n .filter(([peerId]) => peerId !== this.messageService.id)\n .filter(([, messages]) => messages.some((msg) => msg.type === USER_ACTIVITY_MESSAGE_TYPE))\n .map((peer) => peer[0]);\n // send messages to the peers waiting for user activity\n // avoids sending the message to modules which are not using it\n if (registeredPeersIdsForUserActivity.length > 0) {\n this.messageService.send(message, { to: registeredPeersIdsForUserActivity });\n }\n }\n\n /**\n * @inheritdoc\n */\n public handleError(message: ErrorContent<UserActivityMessage>): void {\n this.logger.error('Error in user activity service message', message);\n }\n\n /**\n * Starts observing user activity events.\n * When activity is detected, it sends a throttled message.\n * Event listeners are attached after the next render to ensure DOM is ready.\n * @param config Configuration for the activity producer\n */\n public start(config?: Partial<ActivityProducerConfig>): void {\n if (this.started) {\n return;\n }\n this.started = true;\n const configObject: ActivityProducerConfig = { ...DEFAULT_ACTIVITY_PRODUCER_CONFIG, ...config };\n\n // Always use afterNextRender to ensure DOM is ready in all contexts\n afterNextRender(() => {\n ACTIVITY_EVENTS.forEach((eventType) => {\n const isHighFrequency = HIGH_FREQUENCY_EVENTS.includes(eventType);\n const listener = (event: Event) => {\n // do nothing if the event is a key kept pressed\n if (eventType === 'keydown' && event instanceof KeyboardEvent && event.repeat) {\n return;\n }\n // For high-frequency events, apply throttle BEFORE shouldBroadcast\n // to avoid expensive filter operations on every event (e.g. reflows)\n if (isHighFrequency && !this.shouldProcessHighFrequencyEvent(eventType, configObject.highFrequencyThrottleMs!)) {\n return;\n }\n // Apply filter if provided\n if (configObject.shouldBroadcast?.(event) === false) {\n return;\n }\n this.onActivity(eventType, configObject);\n };\n this.boundListeners.set(eventType, listener);\n document.addEventListener(eventType, listener, { passive: true, capture: true });\n });\n\n // Also listen for visibility changes\n const visibilityListener = () => {\n if (document.visibilityState === 'visible') {\n this.onActivity(VISIBILITY_CHANGE_EVENT, configObject);\n }\n };\n this.boundListeners.set(VISIBILITY_CHANGE_EVENT, visibilityListener);\n document.addEventListener(VISIBILITY_CHANGE_EVENT, visibilityListener, { passive: true, capture: true });\n\n // Set up nested iframe tracking if enabled\n if (configObject.trackNestedIframes) {\n this.iframeActivityTracker.start({\n pollIntervalMs: configObject.nestedIframePollIntervalMs,\n activityIntervalMs: configObject.nestedIframeActivityEmitIntervalMs,\n onActivity: () => this.onActivity(IFRAME_INTERACTION_EVENT, configObject)\n });\n }\n });\n }\n\n /**\n * Stops observing user activity events.\n */\n public stop(): void {\n this.boundListeners.forEach((listener, eventType) => {\n document.removeEventListener(eventType, listener, { capture: true });\n });\n this.boundListeners.clear();\n this.lastEmitTimestamps.clear();\n this.iframeActivityTracker.stop();\n }\n}\n","import {\n USER_ACTIVITY_MESSAGE_TYPE,\n type UserActivityMessageV1_0,\n} from '@ama-mfe/messages';\nimport type {\n RoutedMessage,\n} from '@amadeus-it-group/microfrontends';\nimport {\n inject,\n Injectable,\n signal,\n} from '@angular/core';\nimport {\n type BasicMessageConsumer,\n ConsumerManagerService,\n} from '../managers';\nimport {\n ActivityInfo,\n} from './interfaces';\n\n/**\n * Generic service that consumes user activity messages.\n * Can be used in both shell (to receive from modules) and modules (to receive from shell).\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ActivityConsumerService implements BasicMessageConsumer<UserActivityMessageV1_0> {\n private readonly consumerManagerService = inject(ConsumerManagerService);\n\n /**\n * Signal containing the latest activity info\n */\n private readonly latestReceivedActivityWritable = signal<ActivityInfo | undefined>(undefined);\n\n /**\n * Read-only signal containing the latest activity info received from other peers via the message protocol.\n * Access the timestamp via latestReceivedActivity()?.timestamp\n */\n public readonly latestReceivedActivity = this.latestReceivedActivityWritable.asReadonly();\n\n /**\n * @inheritdoc\n */\n public readonly type = USER_ACTIVITY_MESSAGE_TYPE;\n\n /**\n * @inheritdoc\n */\n public readonly supportedVersions: Record<string, (message: RoutedMessage<UserActivityMessageV1_0>) => void> = {\n // eslint-disable-next-line @typescript-eslint/naming-convention -- Version keys follow message versioning convention\n '1.0': (message) => {\n this.latestReceivedActivityWritable.set({\n channelId: message.from || 'unknown',\n eventType: message.payload.eventType,\n timestamp: message.payload.timestamp\n });\n }\n };\n\n /**\n * Starts the activity consumer service by registering it with the consumer manager.\n */\n public start(): void {\n this.consumerManagerService.register(this);\n }\n\n /**\n * Stops the activity consumer service by unregistering it from the consumer manager.\n */\n public stop(): void {\n this.consumerManagerService.unregister(this);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["ConnectionService"],"mappings":";;;;;;;;;;;MAyBa,gBAAgB,CAAA;AAW3B;;AAEG;AACH,IAAA,IACW,OAAO,GAAA;AAChB,QAAA,OAAO,IAAI,CAAC,GAAG,EAAE;IACnB;AAYA,IAAA,WAAA,GAAA;AA5BA;;AAEG;AACI,QAAA,IAAA,CAAA,OAAO,GAAG,KAAK,CAAC,QAAQ,kDAAU;AAEzC;;AAEG;QACI,IAAA,CAAA,GAAG,GAAG,KAAK,CAAA,IAAA,SAAA,GAAA,CAAA,SAAA,EAAA,EAAA,SAAA,EAAA,KAAA,EAAA,CAAA,GAAA,EAAA,CAAA,CAAmB;AAUpB,QAAA,IAAA,CAAA,cAAc,GAAG,MAAM,CAAC,kBAAkB,CAAC;AAC3C,QAAA,IAAA,CAAA,YAAY,GAAG,MAAM,CAAC,YAAY,CAAC;AACnC,QAAA,IAAA,CAAA,aAAa,GAAG,MAAM,CAAgC,UAAU,CAAC,CAAC,aAA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AA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAvB,uBAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,uBAAuB,cAFtB,MAAM,EAAA,CAAA,CAAA;;2FAEP,uBAAuB,EAAA,UAAA,EAAA,CAAA;kBAHnC,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE;AACb,iBAAA;;;AC1BD;;AAEG;;;;"}
package/package.json CHANGED
@@ -1,29 +1,29 @@
1
1
  {
2
2
  "name": "@ama-mfe/ng-utils",
3
- "version": "14.0.0-next.9",
3
+ "version": "14.0.0-prerelease.1",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
7
7
  "peerDependencies": {
8
- "@ama-mfe/messages": "~14.0.0-next.9",
8
+ "@ama-mfe/messages": "~14.0.0-prerelease.1",
9
9
  "@amadeus-it-group/microfrontends": "0.0.10",
10
10
  "@amadeus-it-group/microfrontends-angular": "0.0.10",
11
- "@angular-devkit/core": "^20.0.0",
12
- "@angular-devkit/schematics": "^20.0.0",
13
- "@angular/common": "^20.0.0",
14
- "@angular/core": "^20.0.0",
15
- "@angular/platform-browser": "^20.0.0",
16
- "@angular/router": "^20.0.0",
17
- "@o3r/logger": "~14.0.0-next.9",
18
- "@o3r/schematics": "~14.0.0-next.9",
11
+ "@angular-devkit/core": "^21.0.0",
12
+ "@angular-devkit/schematics": "^21.0.0",
13
+ "@angular/common": "^21.0.0",
14
+ "@angular/core": "^21.0.0",
15
+ "@angular/platform-browser": "^21.0.0",
16
+ "@angular/router": "^21.0.0",
17
+ "@o3r/logger": "~14.0.0-prerelease.1",
18
+ "@o3r/schematics": "~14.0.0-prerelease.1",
19
19
  "rxjs": "^7.8.1",
20
20
  "type-fest": "^5.3.1"
21
21
  },
22
22
  "dependencies": {
23
23
  "@amadeus-it-group/microfrontends": "0.0.10",
24
24
  "@amadeus-it-group/microfrontends-angular": "0.0.10",
25
- "@o3r/logger": "~14.0.0-next.9",
26
- "@o3r/schematics": "~14.0.0-next.9",
25
+ "@o3r/logger": "~14.0.0-prerelease.1",
26
+ "@o3r/schematics": "~14.0.0-prerelease.1",
27
27
  "tslib": "^2.6.2"
28
28
  },
29
29
  "sideEffects": false,
@@ -64,13 +64,13 @@
64
64
  }
65
65
  },
66
66
  "module": "fesm2022/ama-mfe-ng-utils.mjs",
67
- "typings": "index.d.ts",
67
+ "typings": "types/ama-mfe-ng-utils.d.ts",
68
68
  "exports": {
69
69
  "./package.json": {
70
70
  "default": "./package.json"
71
71
  },
72
72
  ".": {
73
- "types": "./index.d.ts",
73
+ "types": "./types/ama-mfe-ng-utils.d.ts",
74
74
  "default": "./fesm2022/ama-mfe-ng-utils.mjs"
75
75
  }
76
76
  },
@@ -906,17 +906,13 @@ declare class ActivityProducerService implements MessageProducer<UserActivityMes
906
906
  readonly types = "user_activity";
907
907
  constructor();
908
908
  /**
909
- * Handles high-frequency events by applying a per-eventType throttle before calling onActivity.
910
- *
911
- * Difference with onActivity:
912
- * - onActivityThrottled limits how often a given high-frequency event type (e.g. scroll) is processed
913
- * (based on highFrequencyThrottleMs and lastEmitTimestamps)
914
- * - onActivity updates the local activity signal and applies the global message throttle
915
- * (based on global throttleMs and lastSentTimestamp)
916
- * @param eventType The type of activity event that occurred
917
- * @param configObject
909
+ * Checks if a high-frequency event should be processed based on throttle timing.
910
+ * This is called before shouldBroadcast to avoid expensive filter operations on every event.
911
+ * @param eventType The type of activity event
912
+ * @param throttleMs The throttle interval in milliseconds
913
+ * @returns true if the event should be processed, false if it should be skipped
918
914
  */
919
- private onActivityThrottled;
915
+ private shouldProcessHighFrequencyEvent;
920
916
  /**
921
917
  * Handles activity by sending a throttled message and emitting to local signal.
922
918
  * @param eventType The type of activity event that occurred
@@ -1078,4 +1074,4 @@ declare function isEmbedded(windowParam?: Window): boolean;
1078
1074
 
1079
1075
  export { ACTIVITY_EVENTS, ActivityConsumerService, ActivityProducerService, ApplyTheme, ConnectDirective, ConsumerManagerService, DEFAULT_ACTIVITY_PRODUCER_CONFIG, ERROR_MESSAGE_TYPE, HIGH_FREQUENCY_EVENTS, HistoryConsumerService, HostInfoPipe, IFRAME_INTERACTION_EVENT, IframeActivityTrackerService, KNOWN_MESSAGES, MFE_HOST_APPLICATION_ID_PARAM, MFE_HOST_URL_PARAM, MFE_MODULE_APPLICATION_ID_PARAM, NavigationConsumerService, ProducerManagerService, ResizeConsumerService, ResizeService, RestoreRoute, RouteMemorizeDirective, RouteMemorizeService, RoutingService, ScalableDirective, THEME_QUERY_PARAM_NAME, THEME_URL_SUFFIX, ThemeConsumerService, ThemeProducerService, VISIBILITY_CHANGE_EVENT, applyInitialTheme, applyTheme, downloadApplicationThemeCss, getAvailableConsumers, getDefaultClientEndpointStartOptions, getHostInfo, getStyle, hostQueryParams, isEmbedded, isErrorMessage, isUserActivityMessage, persistHostInfo, provideConnection, provideHistoryOverrides, registerConsumer, registerProducer, sendError };
1080
1076
  export type { ActivityInfo, ActivityProducerConfig, BasicMessageConsumer, ConnectionConfigOptions, ErrorContent, ErrorMessage, ErrorMessageV1_0, ErrorReason, IframeActivityTrackerConfig, MFEHostInformation, MessageCallback, MessageConsumer, MessageProducer, MessageVersions, RestoreRouteOptions, RoutingServiceOptions, StyleHelperOptions };
1081
- //# sourceMappingURL=index.d.ts.map
1077
+ //# sourceMappingURL=ama-mfe-ng-utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ama-mfe-ng-utils.d.ts","sources":["../../src/connect/connect-directive.ts","../../src/connect/connect-providers.ts","../../src/messages/available-sender.ts","../../src/messages/error/base.ts","../../src/messages/error/error-versions.ts","../../src/messages/error/index.ts","../../src/messages/error-sender.ts","../../src/messages/user-activity.ts","../../src/managers/interfaces.ts","../../src/managers/consumer-manager-service.ts","../../src/managers/producer-manager-service.ts","../../src/managers/utils.ts","../../src/history/history-consumer-service.ts","../../src/history/history-providers.ts","../../src/host-info/host-info.ts","../../src/host-info/host-info-pipe.ts","../../src/navigation/navigation-consumer-service.ts","../../src/navigation/restore-route-pipe.ts","../../src/navigation/route-memorize/route-memorize-directive.ts","../../src/navigation/route-memorize/route-memorize-service.ts","../../src/navigation/routing-service.ts","../../src/resize/resize-consumer-service.ts","../../src/resize/resize-producer-service.ts","../../src/resize/scalable-directive.ts","../../src/theme/apply-theme-pipe.ts","../../src/theme/theme-consumer-service.ts","../../src/theme/theme-helpers.ts","../../src/theme/theme-producer-service.ts","../../src/user-activity/interfaces.ts","../../src/user-activity/config.ts","../../src/user-activity/activity-producer.service.ts","../../src/user-activity/activity-consumer.service.ts","../../src/user-activity/iframe-activity-tracker.service.ts","../../src/utils.ts"],"sourcesContent":[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null],"names":["_angular_core","ConnectionConfig"],"mappings":";;;;;;;;;;AAqBA,cAAA,gBAAA;AAKE;;AAEG;AACI,aAAOA,EAAA,CAAA,WAAA;AAEd;;AAEG;AACI,SAAGA,EAAA,CAAA,WAAA,CAAA,eAAA;AAEV;;AAEG;AACH,mBAAA,eAAA;AAKA;AACA;AACA;AAEA;;;;AAmCD;;ACtDD;AACM,UAAA,uBAAA,SAAA,IAAA,CAAAC,iBAAA;;;;;AAKL;AAED;;;AAGG;AACH,iBAAA,iBAAA,2BAAA,uBAAA,GAAmFD,EAAA,CAAA,oBAAA;;AClCnF;;;;AAIG;AACH,cAAA,qBAAA,cAAA,oBAAA;;;;;;;;;ACRA;AACA,cAAA,kBAAA;AAEA;;AAEG;AACG,KAAA,WAAA;AAEN;;;AAGG;;;;;;AAMF;;ACdD;AACM,UAAA,gBAAA,WAAA,gBAAA,GAAA,gBAAA,UAAA,gBAAA,EAAA,YAAA;;;;;AAKL;;ACND;AACM,KAAA,YAAA,GAAA,g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;AAoDH;;AAEG;AACI;;;AAQR;;ACtND;;;AAGG;AACH,cAAA,uBAAA,YAAA,oBAAA,CAAA,uBAAA;AAIE;AAEA;;AAEG;AACH;AAEA;;;AAGG;AACH,qCAAsCA,EAAA,CAAA,MAAA,CAAA,YAAA;AAEtC;;AAEG;AACH;AAEA;;AAEG;AACH,gCAAA,MAAA,mBAAA,aAAA,CAAA,uBAAA;AAWA;;AAEG;AACI;AAIP;;AAEG;AACI;;;AAGR;;AClED;;;;;;;;;;AAUG;AACH,cAAA,4BAAA;AAIE;;AAEG;;AAGH;;AAEG;;AAGH;;AAEG;;AAGH;;AAEG;AACH;AAEA;;AAEG;;AAKH;;AAEG;;AAKH;;;;AAIG;AACH;AAcA;;AAEG;AACH;AASA;;AAEG;AACH;AAUA;;AAEG;AACH;AAOA;;AAEG;AACH;AAOA;;AAEG;AACH;AAOA;;;AAGG;AACI,kBAAA,2BAAA;AAeP;;AAEG;AACI;;;AAUR;;ACvJD;;AAEG;AACH,cAAA,cAAA;;;;AAOA;;;AAGG;AACH,iBAAA,oCAAA,IAAA,qBAAA;AAWA;;;AAGG;AACH,iBAAA,UAAA,eAAA,MAAA;;;;"}
package/index.d.ts.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sources":["../src/connect/connect-directive.ts","../src/connect/connect-providers.ts","../src/messages/available-sender.ts","../src/messages/error/base.ts","../src/messages/error/error-versions.ts","../src/messages/error/index.ts","../src/messages/error-sender.ts","../src/messages/user-activity.ts","../src/managers/interfaces.ts","../src/managers/consumer-manager-service.ts","../src/managers/producer-manager-service.ts","../src/managers/utils.ts","../src/history/history-consumer-service.ts","../src/history/history-providers.ts","../src/host-info/host-info.ts","../src/host-info/host-info-pipe.ts","../src/navigation/navigation-consumer-service.ts","../src/navigation/restore-route-pipe.ts","../src/navigation/route-memorize/route-memorize-directive.ts","../src/navigation/route-memorize/route-memorize-service.ts","../src/navigation/routing-service.ts","../src/resize/resize-consumer-service.ts","../src/resize/resize-producer-service.ts","../src/resize/scalable-directive.ts","../src/theme/apply-theme-pipe.ts","../src/theme/theme-consumer-service.ts","../src/theme/theme-helpers.ts","../src/theme/theme-producer-service.ts","../src/user-activity/interfaces.ts","../src/user-activity/config.ts","../src/user-activity/activity-producer.service.ts","../src/user-activity/activity-consumer.service.ts","../src/user-activity/iframe-activity-tracker.service.ts","../src/utils.ts"],"sourcesContent":[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null],"names":["_angular_core","ConnectionConfig"],"mappings":";;;;;;;;;;AAqBA,cAAA,gBAAA;AAKE;;AAEG;AACI,aAAOA,EAAA,CAAA,WAAA;AAEd;;AAEG;AACI,SAAGA,EAAA,CAAA,WAAA,CAAA,eAAA;AAEV;;AAEG;AACH,mBAAA,eAAA;AAKA;AACA;AACA;AAEA;;;;AAmCD;;ACtDD;AACM,UAAA,uBAAA,SAAA,IAAA,CAAAC,iBAAA;;;;;AAKL;AAED;;;AAGG;AACH,iBAAA,iBAAA,2BAAA,uBAAA,GAAmFD,EAAA,CAAA,oBAAA;;AClCnF;;;;AAIG;AACH,cAAA,qBAAA,cAAA,oBAAA;;;;;;;;;ACRA;AACA,cAAA,kBAAA;AAEA;;AAEG;AACG,KAAA,WAAA;AAEN;;;AAGG;;;;;;AAMF;;ACdD;AACM,UAAA,gBAAA,WAAA,gBAAA,GAAA,gBAAA,UAAA,gBAAA,EAAA,YAAA;;;;;AAKL;;ACND;AACM,KAAA,YAAA,GAAA,gBAAA;;ACIN;;;;AAIG;AACH,cAAA,SAAA,SAAA,sBAAA,gBAAA,YAAA;AAQA;;;AAGG;AAEH,cAAA,cAAA,+BAAA,gBAAA;;AAA+G,IAAA,YAAA;;ACzB/G;;;AAGG;AACH,iBAAA,qBAAA,+BAAA,mBAAA;;ACDA;;;AAGG;AACG,KAAA,eAAA,WAAA,gBAAA,cAAA,aAAA,eAAA,OAAA;AAEN;;AAEG;AACG,UAAA,eA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