@ama-mfe/ng-utils 13.0.0-next.3 → 13.0.0-next.31
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/fesm2022/ama-mfe-ng-utils.mjs +45 -45
- package/fesm2022/ama-mfe-ng-utils.mjs.map +1 -1
- package/index.d.ts +736 -4
- package/index.d.ts.map +1 -0
- package/package.json +13 -13
- package/schematics/ng-add/schema.json +3 -2
- package/ama-mfe-ng-utils.d.ts.map +0 -1
- package/connect/connect.directive.d.ts +0 -24
- package/connect/connect.directive.d.ts.map +0 -1
- package/connect/connect.providers.d.ts +0 -15
- package/connect/connect.providers.d.ts.map +0 -1
- package/connect/connect.resources.d.ts +0 -3
- package/connect/connect.resources.d.ts.map +0 -1
- package/connect/index.d.ts +0 -4
- package/connect/index.d.ts.map +0 -1
- package/history/history.providers.d.ts +0 -13
- package/history/history.providers.d.ts.map +0 -1
- package/history/index.d.ts +0 -2
- package/history/index.d.ts.map +0 -1
- package/host-info/host-info.d.ts +0 -48
- package/host-info/host-info.d.ts.map +0 -1
- package/host-info/host-info.pipe.d.ts +0 -30
- package/host-info/host-info.pipe.d.ts.map +0 -1
- package/host-info/index.d.ts +0 -3
- package/host-info/index.d.ts.map +0 -1
- package/managers/consumer.manager.service.d.ts +0 -36
- package/managers/consumer.manager.service.d.ts.map +0 -1
- package/managers/index.d.ts +0 -5
- package/managers/index.d.ts.map +0 -1
- package/managers/interfaces.d.ts +0 -49
- package/managers/interfaces.d.ts.map +0 -1
- package/managers/producer.manager.service.d.ts +0 -29
- package/managers/producer.manager.service.d.ts.map +0 -1
- package/managers/utils.d.ts +0 -14
- package/managers/utils.d.ts.map +0 -1
- package/messages/available.sender.d.ts +0 -15
- package/messages/available.sender.d.ts.map +0 -1
- package/messages/error/base.d.ts +0 -18
- package/messages/error/base.d.ts.map +0 -1
- package/messages/error/error.versions.d.ts +0 -10
- package/messages/error/error.versions.d.ts.map +0 -1
- package/messages/error/index.d.ts +0 -6
- package/messages/error/index.d.ts.map +0 -1
- package/messages/error.sender.d.ts +0 -17
- package/messages/error.sender.d.ts.map +0 -1
- package/messages/index.d.ts +0 -4
- package/messages/index.d.ts.map +0 -1
- package/navigation/index.d.ts +0 -5
- package/navigation/index.d.ts.map +0 -1
- package/navigation/navigation.consumer.service.d.ts +0 -60
- package/navigation/navigation.consumer.service.d.ts.map +0 -1
- package/navigation/restore-route.pipe.d.ts +0 -44
- package/navigation/restore-route.pipe.d.ts.map +0 -1
- package/navigation/route-memorize/index.d.ts +0 -3
- package/navigation/route-memorize/index.d.ts.map +0 -1
- package/navigation/route-memorize/route-memorize.directive.d.ts +0 -31
- package/navigation/route-memorize/route-memorize.directive.d.ts.map +0 -1
- package/navigation/route-memorize/route-memorize.service.d.ts +0 -27
- package/navigation/route-memorize/route-memorize.service.d.ts.map +0 -1
- package/navigation/routing.service.d.ts +0 -64
- package/navigation/routing.service.d.ts.map +0 -1
- package/public_api.d.ts +0 -9
- package/public_api.d.ts.map +0 -1
- package/resize/index.d.ts +0 -4
- package/resize/index.d.ts.map +0 -1
- package/resize/resize.consumer.service.d.ts +0 -44
- package/resize/resize.consumer.service.d.ts.map +0 -1
- package/resize/resize.directive.d.ts +0 -24
- package/resize/resize.directive.d.ts.map +0 -1
- package/resize/resize.producer.service.d.ts +0 -30
- package/resize/resize.producer.service.d.ts.map +0 -1
- package/theme/apply-theme.pipe.d.ts +0 -21
- package/theme/apply-theme.pipe.d.ts.map +0 -1
- package/theme/index.d.ts +0 -5
- package/theme/index.d.ts.map +0 -1
- package/theme/theme.consumer.service.d.ts +0 -38
- package/theme/theme.consumer.service.d.ts.map +0 -1
- package/theme/theme.helpers.d.ts +0 -40
- package/theme/theme.helpers.d.ts.map +0 -1
- package/theme/theme.producer.service.d.ts +0 -37
- package/theme/theme.producer.service.d.ts.map +0 -1
- package/utils.d.ts +0 -18
- package/utils.d.ts.map +0 -1
package/index.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sources":["../src/messages/error/base.ts","../src/messages/error/error.versions.ts","../src/messages/error/index.ts","../src/messages/error.sender.ts","../src/messages/available.sender.ts","../src/managers/interfaces.ts","../src/managers/consumer.manager.service.ts","../src/managers/producer.manager.service.ts","../src/managers/utils.ts","../src/resize/resize.consumer.service.ts","../src/resize/resize.producer.service.ts","../src/resize/resize.directive.ts","../src/navigation/navigation.consumer.service.ts","../src/navigation/route-memorize/route-memorize.directive.ts","../src/navigation/route-memorize/route-memorize.service.ts","../src/navigation/routing.service.ts","../src/navigation/restore-route.pipe.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/connect/connect.directive.ts","../src/connect/connect.providers.ts","../src/utils.ts","../src/host-info/host-info.ts","../src/host-info/host-info.pipe.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],"names":[],"mappings":"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"}
|
package/package.json
CHANGED
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ama-mfe/ng-utils",
|
|
3
|
-
"version": "13.0.0-next.
|
|
3
|
+
"version": "13.0.0-next.31",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
7
7
|
"peerDependencies": {
|
|
8
|
-
"@ama-mfe/messages": "^13.0.0-next.
|
|
8
|
+
"@ama-mfe/messages": "^13.0.0-next.31",
|
|
9
9
|
"@amadeus-it-group/microfrontends": "0.0.7",
|
|
10
10
|
"@amadeus-it-group/microfrontends-angular": "0.0.7",
|
|
11
|
-
"@angular-devkit/core": "
|
|
12
|
-
"@angular-devkit/schematics": "
|
|
13
|
-
"@angular/common": "^
|
|
14
|
-
"@angular/core": "^
|
|
15
|
-
"@angular/platform-browser": "
|
|
16
|
-
"@angular/router": "
|
|
17
|
-
"@o3r/logger": "^13.0.0-next.
|
|
18
|
-
"@o3r/schematics": "^13.0.0-next.
|
|
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": "^13.0.0-next.31",
|
|
18
|
+
"@o3r/schematics": "^13.0.0-next.31",
|
|
19
19
|
"rxjs": "^7.8.1",
|
|
20
|
-
"type-fest": "^4.
|
|
20
|
+
"type-fest": "^4.30.1"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
23
|
"@amadeus-it-group/microfrontends": "0.0.7",
|
|
24
24
|
"@amadeus-it-group/microfrontends-angular": "0.0.7",
|
|
25
|
-
"@o3r/logger": "^13.0.0-next.
|
|
26
|
-
"@o3r/schematics": "^13.0.0-next.
|
|
25
|
+
"@o3r/logger": "^13.0.0-next.31",
|
|
26
|
+
"@o3r/schematics": "^13.0.0-next.31",
|
|
27
27
|
"tslib": "^2.6.2"
|
|
28
28
|
},
|
|
29
29
|
"sideEffects": false,
|
|
@@ -9,12 +9,13 @@
|
|
|
9
9
|
"description": "Project name",
|
|
10
10
|
"$default": {
|
|
11
11
|
"$source": "projectName"
|
|
12
|
-
}
|
|
12
|
+
},
|
|
13
|
+
"alias": "project"
|
|
13
14
|
},
|
|
14
15
|
"skipLinter": {
|
|
15
16
|
"type": "boolean",
|
|
16
17
|
"description": "Skip the linter process which includes EsLint and EditorConfig rules applying",
|
|
17
|
-
"default":
|
|
18
|
+
"default": false
|
|
18
19
|
},
|
|
19
20
|
"skipInstall": {
|
|
20
21
|
"type": "boolean",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ama-mfe-ng-utils.d.ts","sourceRoot":"","sources":["../src/ama-mfe-ng-utils.ts"],"names":[],"mappings":"AAAA;;GAEG;;AAEH,cAAc,cAAc,CAAC"}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { SafeResourceUrl } from '@angular/platform-browser';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
export declare class ConnectDirective {
|
|
4
|
-
/**
|
|
5
|
-
* The connection ID required for the message peer service.
|
|
6
|
-
*/
|
|
7
|
-
connect: import("@angular/core").InputSignal<string>;
|
|
8
|
-
/**
|
|
9
|
-
* The sanitized source URL for the iframe.
|
|
10
|
-
*/
|
|
11
|
-
src: import("@angular/core").InputSignal<SafeResourceUrl | undefined>;
|
|
12
|
-
/**
|
|
13
|
-
* Binds the `src` attribute of the iframe to the sanitized source URL.
|
|
14
|
-
*/
|
|
15
|
-
get srcAttr(): SafeResourceUrl | undefined;
|
|
16
|
-
private readonly messageService;
|
|
17
|
-
private readonly domSanitizer;
|
|
18
|
-
private readonly elRef;
|
|
19
|
-
private readonly clientOrigin;
|
|
20
|
-
constructor();
|
|
21
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<ConnectDirective, never>;
|
|
22
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<ConnectDirective, "iframe[connect]", never, { "connect": { "alias": "connect"; "required": true; "isSignal": true; }; "src": { "alias": "src"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
23
|
-
}
|
|
24
|
-
//# sourceMappingURL=connect.directive.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"connect.directive.d.ts","sourceRoot":"","sources":["../../src/connect/connect.directive.ts"],"names":[],"mappings":"AAcA,OAAO,EAEL,eAAe,EAChB,MAAM,2BAA2B,CAAC;;AAKnC,qBAIa,gBAAgB;IAC3B;;OAEG;IACI,OAAO,8CAA4B;IAE1C;;OAEG;IACI,GAAG,mEAA4B;IAEtC;;OAEG;IACH,IACW,OAAO,gCAEjB;IAED,OAAO,CAAC,QAAQ,CAAC,cAAc,CAA8B;IAC7D,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAwB;IACrD,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAsB;IAE5C,OAAO,CAAC,QAAQ,CAAC,YAAY,CAI1B;;yCA3BQ,gBAAgB;2CAAhB,gBAAgB;CAoD5B"}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { type Logger } from '@o3r/logger';
|
|
2
|
-
import { ConnectionConfig } from './connect.resources';
|
|
3
|
-
/** Options to configure the connection inside the communication protocol */
|
|
4
|
-
export interface ConnectionConfigOptions extends Omit<ConnectionConfig, 'id'> {
|
|
5
|
-
/** @inheritdoc */
|
|
6
|
-
id?: string;
|
|
7
|
-
/** Logger used to gather information */
|
|
8
|
-
logger?: Logger;
|
|
9
|
-
}
|
|
10
|
-
/**
|
|
11
|
-
* Provide the communication protocol connection configuration
|
|
12
|
-
* @param connectionConfigOptions The identifier of the application in the communication protocol ecosystem plus the types of messages able to exchange and a logger object
|
|
13
|
-
*/
|
|
14
|
-
export declare function provideConnection(connectionConfigOptions?: ConnectionConfigOptions): import("@angular/core").EnvironmentProviders;
|
|
15
|
-
//# sourceMappingURL=connect.providers.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"connect.providers.d.ts","sourceRoot":"","sources":["../../src/connect/connect.providers.ts"],"names":[],"mappings":"AASA,OAAO,EACL,KAAK,MAAM,EACZ,MAAM,aAAa,CAAC;AAarB,OAAO,EACL,gBAAgB,EAEjB,MAAM,qBAAqB,CAAC;AAE7B,4EAA4E;AAC5E,MAAM,WAAW,uBAAwB,SAAQ,IAAI,CAAC,gBAAgB,EAAE,IAAI,CAAC;IAC3E,kBAAkB;IAClB,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,wCAAwC;IACxC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED;;;GAGG;AACH,wBAAgB,iBAAiB,CAAC,uBAAuB,CAAC,EAAE,uBAAuB,gDA0BlF"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"connect.resources.d.ts","sourceRoot":"","sources":["../../src/connect/connect.resources.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,iBAAiB,IAAI,gBAAgB,EAAE,MAAM,0CAA0C,CAAC;AACtG,OAAO,EAAE,kBAAkB,IAAI,iBAAiB,EAAE,MAAM,0CAA0C,CAAC"}
|
package/connect/index.d.ts
DELETED
package/connect/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/connect/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* No operation function used to override the history API methods.
|
|
3
|
-
*/
|
|
4
|
-
export declare function noop(): void;
|
|
5
|
-
/**
|
|
6
|
-
* If an iframe is not sandboxed or is of the same origin, navigation inside it will mess up the main window history.
|
|
7
|
-
* This disables writing to and overriding history API from inside the iframe to prevent this.
|
|
8
|
-
* Theoretically, this might break applications that rely on reading history API from inside the iframe.
|
|
9
|
-
*
|
|
10
|
-
* This should also allow having `CustomPathLocationStrategy` in the iframe if necessary.
|
|
11
|
-
*/
|
|
12
|
-
export declare function provideDisableHistoryWrites(): import("@angular/core").EnvironmentProviders;
|
|
13
|
-
//# sourceMappingURL=history.providers.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"history.providers.d.ts","sourceRoot":"","sources":["../../src/history/history.providers.ts"],"names":[],"mappings":"AAIA;;GAEG;AACH,wBAAgB,IAAI,SAAK;AAEzB;;;;;;GAMG;AACH,wBAAgB,2BAA2B,iDAK1C"}
|
package/history/index.d.ts
DELETED
package/history/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/history/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,2BAA2B,EAAE,MAAM,qBAAqB,CAAC"}
|
package/host-info/host-info.d.ts
DELETED
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Search parameter to add to the URL when embedding an iframe containing the URL of the host.
|
|
3
|
-
* This is needed to support Firefox (on which {@link https://developer.mozilla.org/docs/Web/API/Location/ancestorOrigins | location.ancestorOrigins} is not currently supported)
|
|
4
|
-
* in case of redirection inside the iframe.
|
|
5
|
-
*/
|
|
6
|
-
export declare const MFE_HOST_URL_PARAM = "ama-mfe-host-url";
|
|
7
|
-
/**
|
|
8
|
-
* Search parameter to add to the URL to let a module know on which application it's embedded
|
|
9
|
-
*/
|
|
10
|
-
export declare const MFE_HOST_APPLICATION_ID_PARAM = "ama-mfe-host-app-id";
|
|
11
|
-
/**
|
|
12
|
-
* Search parameter to add to the URL to identify the application in the network of peers in the communication protocol
|
|
13
|
-
*/
|
|
14
|
-
export declare const MFE_MODULE_APPLICATION_ID_PARAM = "ama-mfe-module-app-id";
|
|
15
|
-
/** The list of query parameters which can be set by the host */
|
|
16
|
-
export declare const hostQueryParams: string[];
|
|
17
|
-
/**
|
|
18
|
-
* Information set up at host level to use in embedded context
|
|
19
|
-
*/
|
|
20
|
-
export interface MFEHostInformation {
|
|
21
|
-
/**
|
|
22
|
-
* URL of the host application
|
|
23
|
-
*/
|
|
24
|
-
hostURL?: string;
|
|
25
|
-
/**
|
|
26
|
-
* ID of the host application
|
|
27
|
-
*/
|
|
28
|
-
hostApplicationId?: string;
|
|
29
|
-
/**
|
|
30
|
-
* ID of the module to embed defined at host level
|
|
31
|
-
*/
|
|
32
|
-
moduleApplicationId?: string;
|
|
33
|
-
}
|
|
34
|
-
/**
|
|
35
|
-
* Gather the host information from the url parameters
|
|
36
|
-
* The host url will use the first found among:
|
|
37
|
-
* - look for the search parameter {@link MFE_HOST_URL_PARAM} in the URL of the iframe
|
|
38
|
-
* - use the first item in `location.ancestorOrigins` (currently not supported on Firefox)
|
|
39
|
-
* - use `document.referrer` (will only work if called before any redirection in the iframe)
|
|
40
|
-
* The host application ID is taken from the search parameter {@link MFE_HOST_APPLICATION_ID_PARAM} in the URL of the iframe
|
|
41
|
-
* The module application ID is taken from the search parameter {@link MFE_APPLICATION_ID_PARAM} in the URL of the iframe
|
|
42
|
-
*/
|
|
43
|
-
export declare function getHostInfo(): MFEHostInformation;
|
|
44
|
-
/**
|
|
45
|
-
* Gather the host information from the url parameters and handle the persistence in session storage.
|
|
46
|
-
*/
|
|
47
|
-
export declare function persistHostInfo(): void;
|
|
48
|
-
//# sourceMappingURL=host-info.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"host-info.d.ts","sourceRoot":"","sources":["../../src/host-info/host-info.ts"],"names":[],"mappings":"AAEA;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,qBAAqB,CAAC;AAErD;;GAEG;AACH,eAAO,MAAM,6BAA6B,wBAAwB,CAAC;AAEnE;;GAEG;AACH,eAAO,MAAM,+BAA+B,0BAA0B,CAAC;AAEvE,gEAAgE;AAChE,eAAO,MAAM,eAAe,UAAuF,CAAC;AAEpH;;GAEG;AACH,MAAM,WAAW,kBAAkB;IACjC;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAE3B;;OAEG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B;AAED;;;;;;;;GAQG;AACH,wBAAgB,WAAW,IAAI,kBAAkB,CAQhD;AAED;;GAEG;AACH,wBAAgB,eAAe,SAG9B"}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { PipeTransform } from '@angular/core';
|
|
2
|
-
import { type SafeResourceUrl } from '@angular/platform-browser';
|
|
3
|
-
import * as i0 from "@angular/core";
|
|
4
|
-
/**
|
|
5
|
-
* A pipe that adds the host information in the URL of an iframe,
|
|
6
|
-
*/
|
|
7
|
-
export declare class HostInfoPipe implements PipeTransform {
|
|
8
|
-
private readonly domSanitizer;
|
|
9
|
-
/**
|
|
10
|
-
* Transforms the given URL or SafeResourceUrl by appending query parameters.
|
|
11
|
-
* @param url - The URL or SafeResourceUrl to be transformed.
|
|
12
|
-
* @param options - hostId and moduleId
|
|
13
|
-
* @returns - The transformed SafeResourceUrl or undefined if the input URL is invalid.
|
|
14
|
-
*/
|
|
15
|
-
transform(url: string, options: {
|
|
16
|
-
hostId: string;
|
|
17
|
-
moduleId?: string;
|
|
18
|
-
}): string;
|
|
19
|
-
transform(url: SafeResourceUrl, options: {
|
|
20
|
-
hostId: string;
|
|
21
|
-
moduleId?: string;
|
|
22
|
-
}): SafeResourceUrl;
|
|
23
|
-
transform(url: undefined, options: {
|
|
24
|
-
hostId: string;
|
|
25
|
-
moduleId?: string;
|
|
26
|
-
}): undefined;
|
|
27
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<HostInfoPipe, never>;
|
|
28
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<HostInfoPipe, "hostInfo", true>;
|
|
29
|
-
}
|
|
30
|
-
//# sourceMappingURL=host-info.pipe.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"host-info.pipe.d.ts","sourceRoot":"","sources":["../../src/host-info/host-info.pipe.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,aAAa,EAEd,MAAM,eAAe,CAAC;AACvB,OAAO,EAEL,KAAK,eAAe,EACrB,MAAM,2BAA2B,CAAC;;AAOnC;;GAEG;AACH,qBAGa,YAAa,YAAW,aAAa;IAChD,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAwB;IAErD;;;;;OAKG;IACI,SAAS,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,EAAE;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,MAAM;IAC9E,SAAS,CAAC,GAAG,EAAE,eAAe,EAAE,OAAO,EAAE;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,eAAe;IAChG,SAAS,CAAC,GAAG,EAAE,SAAS,EAAE,OAAO,EAAE;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,SAAS;yCAXhF,YAAY;uCAAZ,YAAY;CAiCxB"}
|
package/host-info/index.d.ts
DELETED
package/host-info/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/host-info/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,kBAAkB,CAAC"}
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import { VersionedMessage } from '@amadeus-it-group/microfrontends';
|
|
2
|
-
import type { BasicMessageConsumer } from './interfaces';
|
|
3
|
-
import * as i0 from "@angular/core";
|
|
4
|
-
export declare class ConsumerManagerService {
|
|
5
|
-
private readonly messageService;
|
|
6
|
-
private readonly producerManagerService;
|
|
7
|
-
private readonly registeredConsumers;
|
|
8
|
-
private readonly logger;
|
|
9
|
-
/** The list of registered consumers */
|
|
10
|
-
readonly consumers: import("@angular/core").Signal<BasicMessageConsumer<VersionedMessage>[]>;
|
|
11
|
-
constructor();
|
|
12
|
-
/**
|
|
13
|
-
* Consume a received message
|
|
14
|
-
* @param message the received message body
|
|
15
|
-
*/
|
|
16
|
-
private consumeMessage;
|
|
17
|
-
/**
|
|
18
|
-
* Call the registered message callback(s) to consume the given message
|
|
19
|
-
* Handle error messages of internal communication protocol messages
|
|
20
|
-
* @param message message to consume
|
|
21
|
-
*/
|
|
22
|
-
private consumeAdditionalMessage;
|
|
23
|
-
/**
|
|
24
|
-
* Register a message consumer
|
|
25
|
-
* @param consumer an instance of message consumer
|
|
26
|
-
*/
|
|
27
|
-
register(consumer: BasicMessageConsumer): void;
|
|
28
|
-
/**
|
|
29
|
-
* Unregister a message consumer
|
|
30
|
-
* @param consumer an instance of message consumer
|
|
31
|
-
*/
|
|
32
|
-
unregister(consumer: BasicMessageConsumer): void;
|
|
33
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<ConsumerManagerService, never>;
|
|
34
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<ConsumerManagerService>;
|
|
35
|
-
}
|
|
36
|
-
//# sourceMappingURL=consumer.manager.service.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"consumer.manager.service.d.ts","sourceRoot":"","sources":["../../src/managers/consumer.manager.service.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,gBAAgB,EACjB,MAAM,kCAAkC,CAAC;AAuB1C,OAAO,KAAK,EACV,oBAAoB,EACrB,MAAM,cAAc,CAAC;;AAKtB,qBAGa,sBAAsB;IACjC,OAAO,CAAC,QAAQ,CAAC,cAAc,CAA8B;IAC7D,OAAO,CAAC,QAAQ,CAAC,sBAAsB,CAAkC;IACzE,OAAO,CAAC,QAAQ,CAAC,mBAAmB,CAAsC;IAC1E,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAyB;IAEhD,uCAAuC;IACvC,SAAgB,SAAS,2EAAyC;;IAgBlE;;;OAGG;YACW,cAAc;IAY5B;;;;OAIG;YACW,wBAAwB;IAqCtC;;;OAGG;IACI,QAAQ,CAAC,QAAQ,EAAE,oBAAoB;IAM9C;;;OAGG;IACI,UAAU,CAAC,QAAQ,EAAE,oBAAoB;yCA/FrC,sBAAsB;6CAAtB,sBAAsB;CAoGlC"}
|
package/managers/index.d.ts
DELETED
package/managers/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/managers/index.ts"],"names":[],"mappings":"AAAA,cAAc,4BAA4B,CAAC;AAC3C,cAAc,4BAA4B,CAAC;AAC3C,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC"}
|
package/managers/interfaces.d.ts
DELETED
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
import type { RoutedMessage, VersionedMessage } from '@amadeus-it-group/microfrontends';
|
|
2
|
-
import type { ErrorContent } from '../messages/index';
|
|
3
|
-
/**
|
|
4
|
-
* Use the message payload to execute an action based on message type
|
|
5
|
-
* @param message message to consume
|
|
6
|
-
*/
|
|
7
|
-
export type MessageCallback<T extends VersionedMessage> = (message: RoutedMessage<T>) => void | Promise<void>;
|
|
8
|
-
/**
|
|
9
|
-
* Description of the accepted messages versions and their callbacks for a given message type
|
|
10
|
-
*/
|
|
11
|
-
export interface MessageVersions<T extends VersionedMessage> {
|
|
12
|
-
/** The message callback coresponding to the version */
|
|
13
|
-
[version: string]: MessageCallback<T>;
|
|
14
|
-
}
|
|
15
|
-
/** Description for the base message consumer */
|
|
16
|
-
export interface BasicMessageConsumer<T extends VersionedMessage = VersionedMessage> {
|
|
17
|
-
/** Contains the message type */
|
|
18
|
-
type: T['type'];
|
|
19
|
-
/** A map of messages versions and their callbacks */
|
|
20
|
-
supportedVersions: Record<string, MessageCallback<any>>;
|
|
21
|
-
}
|
|
22
|
-
/** The consumer of a given message type */
|
|
23
|
-
export interface MessageConsumer<T extends VersionedMessage = VersionedMessage> extends BasicMessageConsumer {
|
|
24
|
-
/** The message type which will be handled */
|
|
25
|
-
type: T['type'];
|
|
26
|
-
/** The map of functions which will be executed for each supported version */
|
|
27
|
-
supportedVersions: {
|
|
28
|
-
[V in T['version']]: MessageCallback<T & {
|
|
29
|
-
version: V;
|
|
30
|
-
}>;
|
|
31
|
-
};
|
|
32
|
-
/** Prepare the registration of the consumer */
|
|
33
|
-
start(): void;
|
|
34
|
-
/** Unregister the consumer */
|
|
35
|
-
stop(): void;
|
|
36
|
-
}
|
|
37
|
-
/**
|
|
38
|
-
* Definition of a message producer and which types of messages are produced
|
|
39
|
-
*/
|
|
40
|
-
export interface MessageProducer<T extends VersionedMessage = VersionedMessage> {
|
|
41
|
-
/** The types of the produced message */
|
|
42
|
-
types: T['type'] | T['type'][];
|
|
43
|
-
/**
|
|
44
|
-
* The producer should handle an error in case that it has produced a message which cannot be consumed by other peers
|
|
45
|
-
* @param message the error message received from a peer when the message sent previously has raised an error
|
|
46
|
-
*/
|
|
47
|
-
handleError(message: ErrorContent<T>): void | Promise<void>;
|
|
48
|
-
}
|
|
49
|
-
//# sourceMappingURL=interfaces.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../../src/managers/interfaces.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACb,gBAAgB,EACjB,MAAM,kCAAkC,CAAC;AAC1C,OAAO,KAAK,EACV,YAAY,EACb,MAAM,mBAAmB,CAAC;AAE3B;;;GAGG;AACH,MAAM,MAAM,eAAe,CAAC,CAAC,SAAS,gBAAgB,IAAI,CAAC,OAAO,EAAE,aAAa,CAAC,CAAC,CAAC,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;AAE9G;;GAEG;AACH,MAAM,WAAW,eAAe,CAAC,CAAC,SAAS,gBAAgB;IACzD,uDAAuD;IACvD,CAAC,OAAO,EAAE,MAAM,GAAG,eAAe,CAAC,CAAC,CAAC,CAAC;CACvC;AAED,gDAAgD;AAChD,MAAM,WAAW,oBAAoB,CAAC,CAAC,SAAS,gBAAgB,GAAG,gBAAgB;IACjF,gCAAgC;IAChC,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC;IAChB,qDAAqD;IACrD,iBAAiB,EAAE,MAAM,CAAC,MAAM,EAAE,eAAe,CAAC,GAAG,CAAC,CAAC,CAAC;CACzD;AAED,2CAA2C;AAC3C,MAAM,WAAW,eAAe,CAAC,CAAC,SAAS,gBAAgB,GAAG,gBAAgB,CAAE,SAAQ,oBAAoB;IAE1G,6CAA6C;IAC7C,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC;IAChB,6EAA6E;IAC7E,iBAAiB,EAAE;SAIhB,CAAC,IAAI,CAAC,CAAC,SAAS,CAAC,GAAG,eAAe,CAAC,CAAC,GAAG;YAAE,OAAO,EAAE,CAAC,CAAA;SAAE,CAAC;KACzD,CAAC;IAEF,+CAA+C;IAC/C,KAAK,IAAI,IAAI,CAAC;IACd,8BAA8B;IAC9B,IAAI,IAAI,IAAI,CAAC;CACd;AAED;;GAEG;AACH,MAAM,WAAW,eAAe,CAAC,CAAC,SAAS,gBAAgB,GAAG,gBAAgB;IAC5E,wCAAwC;IACxC,KAAK,EAAE,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC;IAE/B;;;OAGG;IACH,WAAW,CAAC,OAAO,EAAE,YAAY,CAAC,CAAC,CAAC,GAAG,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CAC7D"}
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import type { VersionedMessage } from '@amadeus-it-group/microfrontends';
|
|
2
|
-
import type { ErrorContent } from '../messages/index';
|
|
3
|
-
import type { MessageProducer } from './interfaces';
|
|
4
|
-
import * as i0 from "@angular/core";
|
|
5
|
-
export declare class ProducerManagerService {
|
|
6
|
-
private readonly registeredProducers;
|
|
7
|
-
/** Get the list of registered producers of messages. The list will contain unique elements */
|
|
8
|
-
get producers(): MessageProducer<VersionedMessage>[];
|
|
9
|
-
/**
|
|
10
|
-
* Register a producer of a message
|
|
11
|
-
* @param producer The instance of the message producer
|
|
12
|
-
*/
|
|
13
|
-
register(producer: MessageProducer): void;
|
|
14
|
-
/**
|
|
15
|
-
* Unregister a producer of a message
|
|
16
|
-
* @param producer The instance of the message producer
|
|
17
|
-
*/
|
|
18
|
-
unregister(producer: MessageProducer): void;
|
|
19
|
-
/**
|
|
20
|
-
* Handles the received error message for the given message type by invoking the appropriate producer handlers.
|
|
21
|
-
* @template T - The type of the message, extending from Message.
|
|
22
|
-
* @param message - The error message to handle.
|
|
23
|
-
* @returns - A promise that resolves to true if the error was handled by at least one handler, false otherwise.
|
|
24
|
-
*/
|
|
25
|
-
dispatchError<T extends VersionedMessage = VersionedMessage>(message: ErrorContent<T>): Promise<boolean>;
|
|
26
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<ProducerManagerService, never>;
|
|
27
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<ProducerManagerService>;
|
|
28
|
-
}
|
|
29
|
-
//# sourceMappingURL=producer.manager.service.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"producer.manager.service.d.ts","sourceRoot":"","sources":["../../src/managers/producer.manager.service.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,gBAAgB,EACjB,MAAM,kCAAkC,CAAC;AAI1C,OAAO,KAAK,EACV,YAAY,EACb,MAAM,mBAAmB,CAAC;AAC3B,OAAO,KAAK,EACV,eAAe,EAChB,MAAM,cAAc,CAAC;;AAEtB,qBAGa,sBAAsB;IACjC,OAAO,CAAC,QAAQ,CAAC,mBAAmB,CAA8B;IAElE,8FAA8F;IAC9F,IAAW,SAAS,wCAEnB;IAED;;;OAGG;IACI,QAAQ,CAAC,QAAQ,EAAE,eAAe;IAIzC;;;OAGG;IACI,UAAU,CAAC,QAAQ,EAAE,eAAe;IAI3C;;;;;OAKG;IACU,aAAa,CAAC,CAAC,SAAS,gBAAgB,GAAG,gBAAgB,EAAE,OAAO,EAAE,YAAY,CAAC,CAAC,CAAC;yCA9BvF,sBAAsB;6CAAtB,sBAAsB;CA0ClC"}
|
package/managers/utils.d.ts
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import type { MessageConsumer, MessageProducer } from './interfaces';
|
|
2
|
-
/**
|
|
3
|
-
* Method to call in the constructor of a producer
|
|
4
|
-
* @note should be used in injection context
|
|
5
|
-
* @param producer
|
|
6
|
-
*/
|
|
7
|
-
export declare const registerProducer: (producer: MessageProducer) => void;
|
|
8
|
-
/**
|
|
9
|
-
* Method to call in the constructor of a consumer
|
|
10
|
-
* @note should be used in injection context
|
|
11
|
-
* @param consumer
|
|
12
|
-
*/
|
|
13
|
-
export declare const registerConsumer: (consumer: MessageConsumer) => void;
|
|
14
|
-
//# sourceMappingURL=utils.d.ts.map
|
package/managers/utils.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/managers/utils.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EACV,eAAe,EACf,eAAe,EAChB,MAAM,cAAc,CAAC;AAKtB;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,GAAI,UAAU,eAAe,SAOzD,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,GAAI,UAAU,eAAe,SAOzD,CAAC"}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import type { BasicMessageConsumer } from '../managers/interfaces';
|
|
2
|
-
/**
|
|
3
|
-
* Gets the available consumers and formats them into a {@see DeclareMessages} object.
|
|
4
|
-
* @param consumers - The list of registered message consumers.
|
|
5
|
-
* @returns The formatted DeclareMessages object.
|
|
6
|
-
*/
|
|
7
|
-
export declare const getAvailableConsumers: (consumers: BasicMessageConsumer[]) => {
|
|
8
|
-
type: "declare_messages";
|
|
9
|
-
version: "1.0";
|
|
10
|
-
messages: {
|
|
11
|
-
type: string;
|
|
12
|
-
version: string;
|
|
13
|
-
}[];
|
|
14
|
-
};
|
|
15
|
-
//# sourceMappingURL=available.sender.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"available.sender.d.ts","sourceRoot":"","sources":["../../src/messages/available.sender.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EACV,oBAAoB,EACrB,MAAM,wBAAwB,CAAC;AAEhC;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,GAAI,WAAW,oBAAoB,EAAE;;;;;;;CAMtE,CAAC"}
|
package/messages/error/base.d.ts
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import type { VersionedMessage } from '@amadeus-it-group/microfrontends';
|
|
2
|
-
/** the error message type */
|
|
3
|
-
export declare const ERROR_MESSAGE_TYPE = "error";
|
|
4
|
-
/**
|
|
5
|
-
* The possible reasons for an error.
|
|
6
|
-
*/
|
|
7
|
-
export type ErrorReason = 'unknown_type' | 'version_mismatch' | 'internal_error';
|
|
8
|
-
/**
|
|
9
|
-
* The content of an error message.
|
|
10
|
-
* @template S - The type of the source message.
|
|
11
|
-
*/
|
|
12
|
-
export interface ErrorContent<S extends VersionedMessage = VersionedMessage> {
|
|
13
|
-
/** The reason for the error */
|
|
14
|
-
reason: ErrorReason;
|
|
15
|
-
/** The source message that caused the error */
|
|
16
|
-
source: S;
|
|
17
|
-
}
|
|
18
|
-
//# sourceMappingURL=base.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"base.d.ts","sourceRoot":"","sources":["../../../src/messages/error/base.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,gBAAgB,EACjB,MAAM,kCAAkC,CAAC;AAE1C,6BAA6B;AAC7B,eAAO,MAAM,kBAAkB,UAAU,CAAC;AAE1C;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG,cAAc,GAAG,kBAAkB,GAAG,gBAAgB,CAAC;AAEjF;;;GAGG;AACH,MAAM,WAAW,YAAY,CAAC,CAAC,SAAS,gBAAgB,GAAG,gBAAgB;IACzE,+BAA+B;IAC/B,MAAM,EAAE,WAAW,CAAC;IACpB,+CAA+C;IAC/C,MAAM,EAAE,CAAC,CAAC;CACX"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import type { VersionedMessage } from '@amadeus-it-group/microfrontends';
|
|
2
|
-
import type { ErrorContent } from './base';
|
|
3
|
-
/** An error message with the version 1.0 */
|
|
4
|
-
export interface ErrorMessageV1_0<S extends VersionedMessage = VersionedMessage> extends VersionedMessage, ErrorContent<S> {
|
|
5
|
-
/** @inheritdoc */
|
|
6
|
-
type: 'error';
|
|
7
|
-
/** @inheritdoc */
|
|
8
|
-
version: '1.0';
|
|
9
|
-
}
|
|
10
|
-
//# sourceMappingURL=error.versions.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"error.versions.d.ts","sourceRoot":"","sources":["../../../src/messages/error/error.versions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,gBAAgB,EACjB,MAAM,kCAAkC,CAAC;AAC1C,OAAO,KAAK,EACV,YAAY,EACb,MAAM,QAAQ,CAAC;AAEhB,4CAA4C;AAC5C,MAAM,WAAW,gBAAgB,CAAC,CAAC,SAAS,gBAAgB,GAAG,gBAAgB,CAAE,SAAQ,gBAAgB,EAAE,YAAY,CAAC,CAAC,CAAC;IACxH,kBAAkB;IAClB,IAAI,EAAE,OAAO,CAAC;IACd,kBAAkB;IAClB,OAAO,EAAE,KAAK,CAAC;CAChB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/messages/error/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,gBAAgB,EACjB,MAAM,kBAAkB,CAAC;AAE1B,cAAc,QAAQ,CAAC;AACvB,cAAc,kBAAkB,CAAC;AAEjC,gDAAgD;AAChD,MAAM,MAAM,YAAY,GAAG,gBAAgB,CAAC"}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import type { VersionedMessage } from '@amadeus-it-group/microfrontends';
|
|
2
|
-
import type { MessagePeerServiceType } from '@amadeus-it-group/microfrontends-angular';
|
|
3
|
-
import type { ERROR_MESSAGE_TYPE, ErrorContent } from './error/index';
|
|
4
|
-
/**
|
|
5
|
-
* Helper function to send an error message by the given endpoint (peer)
|
|
6
|
-
* @param peer The endpoint sending the message
|
|
7
|
-
* @param content the content of the error message to be sent
|
|
8
|
-
*/
|
|
9
|
-
export declare const sendError: (peer: MessagePeerServiceType<any>, content: ErrorContent) => void;
|
|
10
|
-
/**
|
|
11
|
-
* Check if the given message is of type error and the error reson is present too
|
|
12
|
-
* @param message the message to be checked
|
|
13
|
-
*/
|
|
14
|
-
export declare const isErrorMessage: (message: any) => message is VersionedMessage & {
|
|
15
|
-
type: typeof ERROR_MESSAGE_TYPE;
|
|
16
|
-
} & ErrorContent;
|
|
17
|
-
//# sourceMappingURL=error.sender.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"error.sender.d.ts","sourceRoot":"","sources":["../../src/messages/error.sender.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,gBAAgB,EACjB,MAAM,kCAAkC,CAAC;AAC1C,OAAO,KAAK,EACV,sBAAsB,EACvB,MAAM,0CAA0C,CAAC;AAClD,OAAO,KAAK,EACV,kBAAkB,EAClB,YAAY,EAEb,MAAM,eAAe,CAAC;AAEvB;;;;GAIG;AACH,eAAO,MAAM,SAAS,GAAI,MAAM,sBAAsB,CAAC,GAAG,CAAC,EAAE,SAAS,YAAY,SAMjF,CAAC;AAEF;;;GAGG;AAEH,eAAO,MAAM,cAAc,GAAI,SAAS,GAAG,KAAG,OAAO,IAAI,gBAAgB,GAAG;IAAE,IAAI,EAAE,OAAO,kBAAkB,CAAA;CAAE,GAAG,YAAwG,CAAC"}
|
package/messages/index.d.ts
DELETED
package/messages/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/messages/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC"}
|
package/navigation/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/navigation/index.ts"],"names":[],"mappings":"AAAA,cAAc,+BAA+B,CAAC;AAC9C,cAAc,wBAAwB,CAAC;AACvC,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC"}
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
import type { NavigationMessage, NavigationV1_0 } from '@ama-mfe/messages';
|
|
2
|
-
import type { RoutedMessage } from '@amadeus-it-group/microfrontends';
|
|
3
|
-
import { type MessageConsumer } from '../managers/index';
|
|
4
|
-
import * as i0 from "@angular/core";
|
|
5
|
-
/**
|
|
6
|
-
* A service that handles navigation messages and routing.
|
|
7
|
-
*
|
|
8
|
-
* This service listens for navigation messages and updates the router state accordingly.
|
|
9
|
-
*/
|
|
10
|
-
export declare class NavigationConsumerService implements MessageConsumer<NavigationMessage> {
|
|
11
|
-
private readonly router;
|
|
12
|
-
private readonly activeRoute;
|
|
13
|
-
private readonly requestedUrl;
|
|
14
|
-
/**
|
|
15
|
-
* An observable that emits the requested URL and optional channel ID.
|
|
16
|
-
*/
|
|
17
|
-
readonly requestedUrl$: import("rxjs").Observable<{
|
|
18
|
-
url: string;
|
|
19
|
-
channelId?: string;
|
|
20
|
-
}>;
|
|
21
|
-
/**
|
|
22
|
-
* The type of messages this service handles.
|
|
23
|
-
*/
|
|
24
|
-
readonly type = "navigation";
|
|
25
|
-
/**
|
|
26
|
-
* @inheritdoc
|
|
27
|
-
*/
|
|
28
|
-
readonly supportedVersions: {
|
|
29
|
-
/**
|
|
30
|
-
* Use the message paylod to compute a new url and emit it via the public subject
|
|
31
|
-
* Additionally navigate to the new url
|
|
32
|
-
* @param message message to consume
|
|
33
|
-
*/
|
|
34
|
-
'1.0': (message: RoutedMessage<NavigationV1_0>) => void;
|
|
35
|
-
};
|
|
36
|
-
private readonly consumerManagerService;
|
|
37
|
-
constructor();
|
|
38
|
-
/**
|
|
39
|
-
* Parses a URL and returns an object containing the paths and query parameters.
|
|
40
|
-
* @param url - The URL to parse.
|
|
41
|
-
* @returns An object containing the paths and query parameters.
|
|
42
|
-
*/
|
|
43
|
-
private parseUrl;
|
|
44
|
-
/**
|
|
45
|
-
* Navigates to the specified URL.
|
|
46
|
-
* @param url - The URL to navigate to.
|
|
47
|
-
*/
|
|
48
|
-
private navigate;
|
|
49
|
-
/**
|
|
50
|
-
* @inheritdoc
|
|
51
|
-
*/
|
|
52
|
-
start(): void;
|
|
53
|
-
/**
|
|
54
|
-
* @inheritdoc
|
|
55
|
-
*/
|
|
56
|
-
stop(): void;
|
|
57
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<NavigationConsumerService, never>;
|
|
58
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<NavigationConsumerService>;
|
|
59
|
-
}
|
|
60
|
-
//# sourceMappingURL=navigation.consumer.service.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"navigation.consumer.service.d.ts","sourceRoot":"","sources":["../../src/navigation/navigation.consumer.service.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EACV,iBAAiB,EACjB,cAAc,EACf,MAAM,mBAAmB,CAAC;AAC3B,OAAO,KAAK,EACV,aAAa,EACd,MAAM,kCAAkC,CAAC;AAgB1C,OAAO,EAEL,KAAK,eAAe,EACrB,MAAM,mBAAmB,CAAC;;AAE3B;;;;GAIG;AACH,qBAGa,yBAA0B,YAAW,eAAe,CAAC,iBAAiB,CAAC;IAClF,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAkB;IACzC,OAAO,CAAC,QAAQ,CAAC,WAAW,CAA0B;IACtD,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAsD;IAEnF;;OAEG;IACH,SAAgB,aAAa;aALsB,MAAM;oBAAc,MAAM;OAKZ;IAEjE;;OAEG;IACH,SAAgB,IAAI,gBAA2B;IAE/C;;OAEG;IACH,SAAgB,iBAAiB;QAC/B;;;;WAIG;yBACc,aAAa,CAAC,cAAc,CAAC;MAK9C;IAEF,OAAO,CAAC,QAAQ,CAAC,sBAAsB,CAAkC;;IAOzE;;;;OAIG;IACH,OAAO,CAAC,QAAQ;IAOhB;;;OAGG;IACH,OAAO,CAAC,QAAQ;IAOhB;;OAEG;IACI,KAAK;IAIZ;;OAEG;IACI,IAAI;yCAvEA,yBAAyB;6CAAzB,yBAAyB;CA0ErC"}
|