@luigi-project/client-support-angular 1.19.1-dev.20211292107 → 1.20.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/luigi-project-client-support-angular.umd.js +11 -5
- package/bundles/luigi-project-client-support-angular.umd.js.map +1 -1
- package/bundles/luigi-project-client-support-angular.umd.min.js +1 -1
- package/bundles/luigi-project-client-support-angular.umd.min.js.map +1 -1
- package/esm2015/lib/service/luigi-context.service.impl.js +12 -7
- package/fesm2015/luigi-project-client-support-angular.js +11 -6
- package/fesm2015/luigi-project-client-support-angular.js.map +1 -1
- package/lib/service/luigi-context.service.impl.d.ts +3 -1
- package/lib/service/luigi-context.service.impl.d.ts.map +1 -1
- package/luigi-project-client-support-angular.metadata.json +1 -1
- package/package.json +2 -2
|
@@ -29,8 +29,9 @@
|
|
|
29
29
|
})(exports.ILuigiContextTypes || (exports.ILuigiContextTypes = {}));
|
|
30
30
|
|
|
31
31
|
var LuigiContextServiceImpl = /** @class */ (function () {
|
|
32
|
-
function LuigiContextServiceImpl() {
|
|
32
|
+
function LuigiContextServiceImpl(zone) {
|
|
33
33
|
var _this = this;
|
|
34
|
+
this.zone = zone;
|
|
34
35
|
this.subject = new rxjs.ReplaySubject(1);
|
|
35
36
|
this.currentContext = null;
|
|
36
37
|
client.addInitListener(function (initContext) {
|
|
@@ -71,8 +72,11 @@
|
|
|
71
72
|
* Set current context
|
|
72
73
|
*/
|
|
73
74
|
LuigiContextServiceImpl.prototype.setContext = function (obj) {
|
|
74
|
-
|
|
75
|
-
this.
|
|
75
|
+
var _this = this;
|
|
76
|
+
this.zone.run(function () {
|
|
77
|
+
_this.currentContext = obj;
|
|
78
|
+
_this.subject.next(obj);
|
|
79
|
+
});
|
|
76
80
|
};
|
|
77
81
|
LuigiContextServiceImpl.prototype.addListener = function (contextType, context) {
|
|
78
82
|
this.setContext({
|
|
@@ -82,13 +86,15 @@
|
|
|
82
86
|
};
|
|
83
87
|
return LuigiContextServiceImpl;
|
|
84
88
|
}());
|
|
85
|
-
LuigiContextServiceImpl.ɵprov = i0.ɵɵdefineInjectable({ factory: function LuigiContextServiceImpl_Factory() { return new LuigiContextServiceImpl(); }, token: LuigiContextServiceImpl, providedIn: "root" });
|
|
89
|
+
LuigiContextServiceImpl.ɵprov = i0.ɵɵdefineInjectable({ factory: function LuigiContextServiceImpl_Factory() { return new LuigiContextServiceImpl(i0.ɵɵinject(i0.NgZone)); }, token: LuigiContextServiceImpl, providedIn: "root" });
|
|
86
90
|
LuigiContextServiceImpl.decorators = [
|
|
87
91
|
{ type: i0.Injectable, args: [{
|
|
88
92
|
providedIn: 'root'
|
|
89
93
|
},] }
|
|
90
94
|
];
|
|
91
|
-
LuigiContextServiceImpl.ctorParameters = function () { return [
|
|
95
|
+
LuigiContextServiceImpl.ctorParameters = function () { return [
|
|
96
|
+
{ type: i0.NgZone }
|
|
97
|
+
]; };
|
|
92
98
|
|
|
93
99
|
var LuigiActivatedRouteSnapshotHelper = /** @class */ (function () {
|
|
94
100
|
function LuigiActivatedRouteSnapshotHelper() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"luigi-project-client-support-angular.umd.js","sources":["../../projects/client-support-angular/src/lib/component/luigi.preload.component.ts","../../projects/client-support-angular/src/lib/service/luigi-context-service.ts","../../projects/client-support-angular/src/lib/service/luigi-context.service.impl.ts","../../projects/client-support-angular/src/lib/route/luigi-activated-route-snapshot-helper.ts","../../projects/client-support-angular/src/lib/service/luigi-auto-routing.service.ts","../../../node_modules/tslib/tslib.es6.js","../../projects/client-support-angular/src/lib/route/luigi-route-strategy.ts","../../../projects/client-support-angular/src/lib/luigi.angular.support.module.ts","../../projects/client-support-angular/src/lib/luigi-mock/luigi-mock.module.ts","../../../../projects/client-support-angular/src/public-api.ts","../../../../projects/client-support-angular/src/luigi-project-client-support-angular.ts"],"sourcesContent":["import { Component, OnInit } from '@angular/core';\n\n@Component({\n selector: 'lib-client-support-angular',\n templateUrl: './luigi.preload.component.html',\n styles: []\n})\nexport class LuigiPreloadComponent implements OnInit {\n constructor() {}\n ngOnInit(): void {}\n}\n","import { Context } from '@luigi-project/client';\nimport { Observable } from 'rxjs';\n\nexport abstract class LuigiContextService {\n /**\n * Listen to context changes\n * Receives current value, even if the event was already dispatched earlier.\n */\n abstract contextObservable(): Observable<IContextMessage>;\n\n /**\n * Get latest set context object (can be null/undefined, if not set yet)\n */\n abstract getContext(): Context;\n\n /**\n * Get a promise that resolves when context is set.\n */\n abstract getContextAsync(): Promise<Context>;\n}\n\nexport enum ILuigiContextTypes {\n INIT,\n UPDATE\n}\n\nexport interface IContextMessage {\n contextType: ILuigiContextTypes; // will be init or update\n context: Context;\n}\n","import { Injectable } from '@angular/core';\nimport { ReplaySubject, Observable } from 'rxjs';\nimport { first } from 'rxjs/operators';\nimport {\n Context,\n addInitListener,\n addContextUpdateListener\n} from '@luigi-project/client';\nimport {\n IContextMessage,\n ILuigiContextTypes,\n LuigiContextService\n} from './luigi-context-service';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LuigiContextServiceImpl implements LuigiContextService {\n private subject: ReplaySubject<IContextMessage> = new ReplaySubject<\n IContextMessage\n >(1);\n private currentContext: IContextMessage = (null as unknown) as IContextMessage;\n\n constructor() {\n addInitListener(initContext => {\n this.addListener(ILuigiContextTypes.INIT, initContext);\n });\n addContextUpdateListener(updateContext => {\n this.addListener(ILuigiContextTypes.UPDATE, updateContext);\n });\n }\n\n public contextObservable(): Observable<IContextMessage> {\n return this.subject.asObservable();\n }\n\n /**\n * Get latest context object retrieved from luigi core application or none, if not yet set.\n */\n public getContext(): Context {\n return this.currentContext && this.currentContext.context;\n }\n\n /**\n * Get a promise that resolves when context is set.\n */\n public getContextAsync(): Promise<Context> {\n return new Promise<Context>((resolve, reject) => {\n if (this.getContext()) {\n resolve(this.getContext());\n } else {\n this.contextObservable()\n .pipe(first())\n .subscribe(ctx => {\n resolve(ctx.context);\n });\n }\n });\n }\n\n /**\n * Set current context\n */\n protected setContext(obj: IContextMessage): void {\n this.currentContext = obj;\n this.subject.next(obj);\n }\n\n addListener(contextType: ILuigiContextTypes, context: Context): void {\n this.setContext({\n contextType,\n context\n } as IContextMessage);\n }\n}\n","import { ActivatedRouteSnapshot } from '@angular/router';\n\nexport class LuigiActivatedRouteSnapshotHelper {\n // tslint:disable-next-line:variable-name\n private static _current: ActivatedRouteSnapshot = (null as unknown) as ActivatedRouteSnapshot;\n\n static getCurrent(): ActivatedRouteSnapshot {\n return LuigiActivatedRouteSnapshotHelper._current;\n }\n\n static setCurrent(current: ActivatedRouteSnapshot): void {\n LuigiActivatedRouteSnapshotHelper._current = current;\n }\n}\n","import { Injectable, OnDestroy } from '@angular/core';\nimport { OperatorFunction, PartialObserver, Subscription } from 'rxjs';\nimport {\n convertToParamMap,\n NavigationEnd,\n ParamMap,\n Router,\n RouterEvent\n} from '@angular/router';\nimport { linkManager } from '@luigi-project/client';\nimport { filter } from 'rxjs/operators';\nimport { LuigiActivatedRouteSnapshotHelper } from '../route/luigi-activated-route-snapshot-helper';\nimport { LuigiContextService } from './luigi-context-service';\nimport { ActivatedRouteSnapshot } from '@angular/router';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LuigiAutoRoutingService implements OnDestroy {\n private subscription: Subscription = new Subscription();\n\n constructor(\n private router: Router,\n private luigiContextService: LuigiContextService\n ) {\n this.subscription.add(\n this.router.events\n .pipe(this.doFilter())\n .subscribe(this.doSubscription.bind(this) as () => void)\n );\n }\n\n doFilter(): OperatorFunction<unknown, RouterEvent> {\n return filter((event): event is RouterEvent => {\n return !!(\n event instanceof NavigationEnd &&\n event.url &&\n event.url.length > 0 &&\n !(history.state && history.state.luigiInduced)\n );\n });\n }\n\n /**\n * This method will be take in consideration angular route that having in data object the paramter\n * fromVirtualTreeRoot: true, here an example:\n * {path: 'demo', component: DemoComponent, data:{fromVirtualTreeRoot: true}}\n * Another option is to specify the LuigiPath: if you add in route data luigiRoute:'/xxxx/xxx';\n * in the case we will update the path in LuigiCore navigation, here an example\n * {path: 'demo', component: DemoComponent, data:{luigiRoute: '/home/demo''}}\n * @param event the NavigationEnd event\n */\n doSubscription(event: NavigationEnd): void {\n let current: ActivatedRouteSnapshot | null = LuigiActivatedRouteSnapshotHelper.getCurrent();\n\n if (!current) {\n current = this.router.routerState.root.snapshot;\n while (current?.children?.length > 0) {\n // handle multiple children\n let primary: ActivatedRouteSnapshot | null = null;\n\n current?.children.forEach(childSnapshot => {\n if (childSnapshot.outlet === 'primary') {\n primary = childSnapshot;\n }\n });\n if (primary) {\n current = primary;\n } else if (current.firstChild) {\n current = current.firstChild;\n } else {\n break;\n }\n }\n }\n\n if (current?.data) {\n if (current.data.luigiRoute) {\n let route = current.data.luigiRoute;\n\n if (current.params) {\n const pmap: ParamMap = convertToParamMap(current.params);\n pmap.keys.forEach(key => {\n const val = pmap.getAll(key).forEach(param => {\n route = route.replace(':' + key, param);\n });\n });\n }\n let lm = linkManager();\n if (current.data.fromContext) {\n if (!this.luigiContextService.getContext()) {\n console.debug(\n 'Ignoring auto navigation request, luigi context not set'\n );\n return;\n }\n if (current.data.fromContext === true) {\n lm = lm.fromClosestContext();\n } else {\n lm = lm.fromContext(current.data.fromContext);\n }\n }\n\n lm.withoutSync().navigate(route);\n return;\n }\n if (current.data.fromVirtualTreeRoot) {\n let url = event.url;\n const truncate = current.data.fromVirtualTreeRoot.truncate;\n if (truncate) {\n if (truncate.indexOf('*') === 0) {\n const index = url.indexOf(truncate.substr(1));\n url = url.substr(index + truncate.length - 1);\n }\n else if (url.indexOf(truncate) === 0) {\n url = url.substr(truncate.length);\n }\n }\n console.debug('Calling fromVirtualTreeRoot for url ==> ' + url);\n linkManager()\n .fromVirtualTreeRoot()\n .withoutSync()\n .navigate(url);\n }\n }\n }\n\n ngOnDestroy(): void {\n this.subscription.unsubscribe();\n }\n}\n","/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n};\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, privateMap) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to get private field on non-instance\");\r\n }\r\n return privateMap.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, privateMap, value) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to set private field on non-instance\");\r\n }\r\n privateMap.set(receiver, value);\r\n return value;\r\n}\r\n","import { BaseRouteReuseStrategy } from '@angular/router';\nimport { ActivatedRouteSnapshot, DetachedRouteHandle } from '@angular/router';\nimport { LuigiActivatedRouteSnapshotHelper } from './luigi-activated-route-snapshot-helper';\n\nexport class LuigiRouteStrategy extends BaseRouteReuseStrategy {\n retrieve(route: ActivatedRouteSnapshot): DetachedRouteHandle | null {\n LuigiActivatedRouteSnapshotHelper.setCurrent(route);\n return super.retrieve(route);\n }\n}\n","import { NgModule } from '@angular/core';\nimport { RouteReuseStrategy, RouterModule, Routes } from '@angular/router';\nimport { LuigiPreloadComponent } from './component/luigi.preload.component';\nimport { LuigiContextService } from './service/luigi-context-service';\nimport { LuigiContextServiceImpl } from './service/luigi-context.service.impl';\nimport { LuigiAutoRoutingService } from './service/luigi-auto-routing.service';\nimport { LuigiRouteStrategy } from './route/luigi-route-strategy';\n\nexport const staticRoutes: Routes = [\n /** here an example if you want to specify that this component is a virtualTree element in Luigi Core navigation*/\n {\n path: 'luigi-client-support-preload',\n component: LuigiPreloadComponent,\n data: { fromVirtualTreeRoot: true }\n },\n /** here an example if you want to specify that this component it is a luigi component and u want to change the navigation in Luigi core*/\n {\n path: 'luigi-client-support-preload',\n component: LuigiPreloadComponent,\n data: { luigiRoute: '/home/reload' }\n },\n /** here an example if you want to reuse the component and not recreating every time you navigate to it (a singleton Component) It requires in your module to redefine */\n {\n path: 'luigi-client-support-preload=component',\n component: LuigiPreloadComponent,\n data: { reuse: true }\n }\n];\n\n@NgModule({\n declarations: [LuigiPreloadComponent],\n imports: [RouterModule.forChild(staticRoutes)],\n providers: [\n {\n provide: LuigiContextService,\n useClass: LuigiContextServiceImpl\n },\n {\n provide: RouteReuseStrategy,\n useClass: LuigiRouteStrategy\n }\n ],\n exports: [LuigiPreloadComponent]\n})\nexport class LuigiAngularSupportModule {\n constructor(\n navigation: LuigiAutoRoutingService,\n context: LuigiContextService\n ) {}\n}\n","import { APP_INITIALIZER, NgModule } from '@angular/core';\n\n// @dynamic\n@NgModule({\n providers: [\n {\n provide: APP_INITIALIZER,\n useFactory: LuigiMockModule.initPostMessageHook,\n multi: true\n }\n ]\n})\n\n/*\n * This class mocks Luigi Core related functionality.\n *\n * Micro Frontends that use Luigi Client would usually communicate with Luigi Core\n * back and forth. When testing Luigi Client based components, Luigi Core might\n * not be present which leads into limitations on integration/e2e testing for standalone\n * microfrontends.\n *\n * This module adds a hook to the window postMessage API by adding an event listener to the\n * global message event of the window object and mocking the callback.\n * In the normal workflow this message would picked up by Luigi Core which then sends the response back.\n */\nexport class LuigiMockModule {\n // Add a hook to the post message api to mock the LuigiCore response to the Client\n public static initPostMessageHook() {\n return async (): Promise<void> => {\n // Check if Luigi Client is running standalone\n if (window.parent === window) {\n console.debug('Detected standalone mode');\n\n // Check and skip if Luigi environment is already mocked\n if ((window as any).luigiMockEnvironment) {\n return;\n }\n\n (window as any).luigiMockEnvironment = {\n msgListener: function(e: any) {\n if (e.data.msg && (e.data.msg.startsWith('luigi.') || e.data.msg === 'storage')) {\n console.debug('Luigi msg', e.data);\n\n if (e.data.msg === 'luigi.get-context') {\n window.postMessage(\n {\n msg: 'luigi.init',\n emulated: true,\n internal: {\n viewStackSize: 1\n },\n context: e.data.context\n },\n '*'\n );\n }\n\n // vizualise retrieved event data\n LuigiMockModule.visualize(JSON.stringify(e.data));\n\n // Check and run mocked callback if it exists\n const mockListener = (window as any).luigiMockEnvironment.mockListeners[e.data.msg];\n if (mockListener) {\n mockListener(e);\n }\n }\n },\n mockListeners: {\n 'luigi.navigation.pathExists': (event: any) => {\n const mockData = window.sessionStorage.getItem('luigiMockData');\n let mockDataParsed = mockData ? JSON.parse(mockData) : undefined;\n const inputPath = event.data.data.link;\n const pathExists = mockDataParsed && mockDataParsed.pathExists && mockDataParsed.pathExists[inputPath];\n\n const response = {\n msg: 'luigi.navigation.pathExists.answer',\n data: {\n correlationId: event.data.data.id,\n pathExists: pathExists ? pathExists : false\n },\n emulated: true\n };\n window.postMessage(response, '*');\n },\n //ux\n 'luigi.ux.confirmationModal.show': (event: any) => {\n const response = {\n msg: 'luigi.ux.confirmationModal.hide',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.ux.alert.show': (event: any) => {\n const response = {\n msg: 'luigi.ux.alert.hide',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.ux.set-current-locale': (event: any) => {\n const response = {\n msg: 'luigi.current-locale-changed',\n currentLocale: event.data.data.currentLocale,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n // linkManager\n 'luigi.navigation.open': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.close': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.collapse': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.expand': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n // storage\n storage: () => {}\n }\n };\n\n // Listen to the global 'message' event of the window object\n window.addEventListener('message', (window as any).luigiMockEnvironment.msgListener);\n }\n };\n }\n\n /*\n * This method takes a data object of type 'any' and vizualizes a simple container\n * which holds data that is useful for e2e testing.\n */\n public static visualize(data: string): void {\n let luigiVisualizationContainer: Element | null = document.querySelector('#luigi-debug-vis-cnt');\n // Construct element structure if not already constructed\n if (!luigiVisualizationContainer) {\n luigiVisualizationContainer = document.createElement('div');\n luigiVisualizationContainer.setAttribute('id', 'luigi-debug-vis-cnt');\n // Hide the added DOM element to avoid interferring/overlapping with other elements during testing.\n luigiVisualizationContainer.setAttribute('style', 'display:none');\n document.body.appendChild(luigiVisualizationContainer);\n }\n const line: HTMLDivElement = document.createElement('div');\n line.textContent = data;\n luigiVisualizationContainer.appendChild(line);\n }\n}\n","/*\n * Public API Surface of client-support-angular\n */\n\nexport * from './lib/component/luigi.preload.component';\nexport * from './lib/luigi.angular.support.module';\nexport * from './lib/service/luigi-context-service';\nexport * from './lib/service/luigi-context.service.impl';\nexport * from './lib/service/luigi-auto-routing.service';\nexport * from './lib/luigi-mock/luigi-mock.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {LuigiRouteStrategy as ɵa} from './lib/route/luigi-route-strategy';"],"names":["Component","ILuigiContextTypes","ReplaySubject","addInitListener","addContextUpdateListener","first","Injectable","Subscription","filter","NavigationEnd","convertToParamMap","linkManager","Router","BaseRouteReuseStrategy","NgModule","RouterModule","RouteReuseStrategy","APP_INITIALIZER"],"mappings":";;;;;;;QAQE;SAAgB;QAChB,wCAAQ,GAAR,eAAmB;;;;gBAPpBA,YAAS,SAAC;oBACT,QAAQ,EAAE,4BAA4B;oBACtC,mDAA6C;iBAE9C;;;;;QCHD;SAgBC;kCAAA;KAAA,IAAA;IAED,WAAY,kBAAkB;QAC5B,2DAAI,CAAA;QACJ,+DAAM,CAAA;IACR,CAAC,EAHWC,0BAAkB,KAAlBA,0BAAkB;;;QCE5B;YAAA,iBAOC;YAZO,YAAO,GAAmC,IAAIC,kBAAa,CAEjE,CAAC,CAAC,CAAC;YACG,mBAAc,GAAqB,IAAmC,CAAC;YAG7EC,sBAAe,CAAC,UAAA,WAAW;gBACzB,KAAI,CAAC,WAAW,CAACF,0BAAkB,CAAC,IAAI,EAAE,WAAW,CAAC,CAAC;aACxD,CAAC,CAAC;YACHG,+BAAwB,CAAC,UAAA,aAAa;gBACpC,KAAI,CAAC,WAAW,CAACH,0BAAkB,CAAC,MAAM,EAAE,aAAa,CAAC,CAAC;aAC5D,CAAC,CAAC;SACJ;QAEM,mDAAiB,GAAjB;YACL,OAAO,IAAI,CAAC,OAAO,CAAC,YAAY,EAAE,CAAC;SACp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SAAS,EAAE;wBACT;4BACE,OAAO,EAAEG,kBAAe;4BACxB,UAAU,EAAE,eAAe,CAAC,mBAAmB;4BAC/C,KAAK,EAAE,IAAI;yBACZ;qBACF;iBACF;;;ICXD;;;;ICAA;;;;;;;;;;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"luigi-project-client-support-angular.umd.js","sources":["../../projects/client-support-angular/src/lib/component/luigi.preload.component.ts","../../projects/client-support-angular/src/lib/service/luigi-context-service.ts","../../projects/client-support-angular/src/lib/service/luigi-context.service.impl.ts","../../projects/client-support-angular/src/lib/route/luigi-activated-route-snapshot-helper.ts","../../projects/client-support-angular/src/lib/service/luigi-auto-routing.service.ts","../../../node_modules/tslib/tslib.es6.js","../../projects/client-support-angular/src/lib/route/luigi-route-strategy.ts","../../../projects/client-support-angular/src/lib/luigi.angular.support.module.ts","../../projects/client-support-angular/src/lib/luigi-mock/luigi-mock.module.ts","../../../../projects/client-support-angular/src/public-api.ts","../../../../projects/client-support-angular/src/luigi-project-client-support-angular.ts"],"sourcesContent":["import { Component, OnInit } from '@angular/core';\n\n@Component({\n selector: 'lib-client-support-angular',\n templateUrl: './luigi.preload.component.html',\n styles: []\n})\nexport class LuigiPreloadComponent implements OnInit {\n constructor() {}\n ngOnInit(): void {}\n}\n","import { Context } from '@luigi-project/client';\nimport { Observable } from 'rxjs';\n\nexport abstract class LuigiContextService {\n /**\n * Listen to context changes\n * Receives current value, even if the event was already dispatched earlier.\n */\n abstract contextObservable(): Observable<IContextMessage>;\n\n /**\n * Get latest set context object (can be null/undefined, if not set yet)\n */\n abstract getContext(): Context;\n\n /**\n * Get a promise that resolves when context is set.\n */\n abstract getContextAsync(): Promise<Context>;\n}\n\nexport enum ILuigiContextTypes {\n INIT,\n UPDATE\n}\n\nexport interface IContextMessage {\n contextType: ILuigiContextTypes; // will be init or update\n context: Context;\n}\n","import { Injectable, NgZone } from '@angular/core';\nimport { ReplaySubject, Observable } from 'rxjs';\nimport { first } from 'rxjs/operators';\nimport { Context, addInitListener, addContextUpdateListener } from '@luigi-project/client';\nimport { IContextMessage, ILuigiContextTypes, LuigiContextService } from './luigi-context-service';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LuigiContextServiceImpl implements LuigiContextService {\n private subject: ReplaySubject<IContextMessage> = new ReplaySubject<IContextMessage>(1);\n private currentContext: IContextMessage = (null as unknown) as IContextMessage;\n\n constructor(private zone: NgZone) {\n addInitListener(initContext => {\n this.addListener(ILuigiContextTypes.INIT, initContext);\n });\n addContextUpdateListener(updateContext => {\n this.addListener(ILuigiContextTypes.UPDATE, updateContext);\n });\n }\n\n public contextObservable(): Observable<IContextMessage> {\n return this.subject.asObservable();\n }\n\n /**\n * Get latest context object retrieved from luigi core application or none, if not yet set.\n */\n public getContext(): Context {\n return this.currentContext && this.currentContext.context;\n }\n\n /**\n * Get a promise that resolves when context is set.\n */\n public getContextAsync(): Promise<Context> {\n return new Promise<Context>((resolve, reject) => {\n if (this.getContext()) {\n resolve(this.getContext());\n } else {\n this.contextObservable()\n .pipe(first())\n .subscribe(ctx => {\n resolve(ctx.context);\n });\n }\n });\n }\n\n /**\n * Set current context\n */\n protected setContext(obj: IContextMessage): void {\n this.zone.run(() => {\n this.currentContext = obj;\n this.subject.next(obj);\n });\n }\n\n addListener(contextType: ILuigiContextTypes, context: Context): void {\n this.setContext({\n contextType,\n context\n } as IContextMessage);\n }\n}\n","import { ActivatedRouteSnapshot } from '@angular/router';\n\nexport class LuigiActivatedRouteSnapshotHelper {\n // tslint:disable-next-line:variable-name\n private static _current: ActivatedRouteSnapshot = (null as unknown) as ActivatedRouteSnapshot;\n\n static getCurrent(): ActivatedRouteSnapshot {\n return LuigiActivatedRouteSnapshotHelper._current;\n }\n\n static setCurrent(current: ActivatedRouteSnapshot): void {\n LuigiActivatedRouteSnapshotHelper._current = current;\n }\n}\n","import { Injectable, OnDestroy } from '@angular/core';\nimport { OperatorFunction, PartialObserver, Subscription } from 'rxjs';\nimport {\n convertToParamMap,\n NavigationEnd,\n ParamMap,\n Router,\n RouterEvent\n} from '@angular/router';\nimport { linkManager } from '@luigi-project/client';\nimport { filter } from 'rxjs/operators';\nimport { LuigiActivatedRouteSnapshotHelper } from '../route/luigi-activated-route-snapshot-helper';\nimport { LuigiContextService } from './luigi-context-service';\nimport { ActivatedRouteSnapshot } from '@angular/router';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LuigiAutoRoutingService implements OnDestroy {\n private subscription: Subscription = new Subscription();\n\n constructor(\n private router: Router,\n private luigiContextService: LuigiContextService\n ) {\n this.subscription.add(\n this.router.events\n .pipe(this.doFilter())\n .subscribe(this.doSubscription.bind(this) as () => void)\n );\n }\n\n doFilter(): OperatorFunction<unknown, RouterEvent> {\n return filter((event): event is RouterEvent => {\n return !!(\n event instanceof NavigationEnd &&\n event.url &&\n event.url.length > 0 &&\n !(history.state && history.state.luigiInduced)\n );\n });\n }\n\n /**\n * This method will be take in consideration angular route that having in data object the paramter\n * fromVirtualTreeRoot: true, here an example:\n * {path: 'demo', component: DemoComponent, data:{fromVirtualTreeRoot: true}}\n * Another option is to specify the LuigiPath: if you add in route data luigiRoute:'/xxxx/xxx';\n * in the case we will update the path in LuigiCore navigation, here an example\n * {path: 'demo', component: DemoComponent, data:{luigiRoute: '/home/demo''}}\n * @param event the NavigationEnd event\n */\n doSubscription(event: NavigationEnd): void {\n let current: ActivatedRouteSnapshot | null = LuigiActivatedRouteSnapshotHelper.getCurrent();\n\n if (!current) {\n current = this.router.routerState.root.snapshot;\n while (current?.children?.length > 0) {\n // handle multiple children\n let primary: ActivatedRouteSnapshot | null = null;\n\n current?.children.forEach(childSnapshot => {\n if (childSnapshot.outlet === 'primary') {\n primary = childSnapshot;\n }\n });\n if (primary) {\n current = primary;\n } else if (current.firstChild) {\n current = current.firstChild;\n } else {\n break;\n }\n }\n }\n\n if (current?.data) {\n if (current.data.luigiRoute) {\n let route = current.data.luigiRoute;\n\n if (current.params) {\n const pmap: ParamMap = convertToParamMap(current.params);\n pmap.keys.forEach(key => {\n const val = pmap.getAll(key).forEach(param => {\n route = route.replace(':' + key, param);\n });\n });\n }\n let lm = linkManager();\n if (current.data.fromContext) {\n if (!this.luigiContextService.getContext()) {\n console.debug(\n 'Ignoring auto navigation request, luigi context not set'\n );\n return;\n }\n if (current.data.fromContext === true) {\n lm = lm.fromClosestContext();\n } else {\n lm = lm.fromContext(current.data.fromContext);\n }\n }\n\n lm.withoutSync().navigate(route);\n return;\n }\n if (current.data.fromVirtualTreeRoot) {\n let url = event.url;\n const truncate = current.data.fromVirtualTreeRoot.truncate;\n if (truncate) {\n if (truncate.indexOf('*') === 0) {\n const index = url.indexOf(truncate.substr(1));\n url = url.substr(index + truncate.length - 1);\n }\n else if (url.indexOf(truncate) === 0) {\n url = url.substr(truncate.length);\n }\n }\n console.debug('Calling fromVirtualTreeRoot for url ==> ' + url);\n linkManager()\n .fromVirtualTreeRoot()\n .withoutSync()\n .navigate(url);\n }\n }\n }\n\n ngOnDestroy(): void {\n this.subscription.unsubscribe();\n }\n}\n","/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n};\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, privateMap) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to get private field on non-instance\");\r\n }\r\n return privateMap.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, privateMap, value) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to set private field on non-instance\");\r\n }\r\n privateMap.set(receiver, value);\r\n return value;\r\n}\r\n","import { BaseRouteReuseStrategy } from '@angular/router';\nimport { ActivatedRouteSnapshot, DetachedRouteHandle } from '@angular/router';\nimport { LuigiActivatedRouteSnapshotHelper } from './luigi-activated-route-snapshot-helper';\n\nexport class LuigiRouteStrategy extends BaseRouteReuseStrategy {\n retrieve(route: ActivatedRouteSnapshot): DetachedRouteHandle | null {\n LuigiActivatedRouteSnapshotHelper.setCurrent(route);\n return super.retrieve(route);\n }\n}\n","import { NgModule } from '@angular/core';\nimport { RouteReuseStrategy, RouterModule, Routes } from '@angular/router';\nimport { LuigiPreloadComponent } from './component/luigi.preload.component';\nimport { LuigiContextService } from './service/luigi-context-service';\nimport { LuigiContextServiceImpl } from './service/luigi-context.service.impl';\nimport { LuigiAutoRoutingService } from './service/luigi-auto-routing.service';\nimport { LuigiRouteStrategy } from './route/luigi-route-strategy';\n\nexport const staticRoutes: Routes = [\n /** here an example if you want to specify that this component is a virtualTree element in Luigi Core navigation*/\n {\n path: 'luigi-client-support-preload',\n component: LuigiPreloadComponent,\n data: { fromVirtualTreeRoot: true }\n },\n /** here an example if you want to specify that this component it is a luigi component and u want to change the navigation in Luigi core*/\n {\n path: 'luigi-client-support-preload',\n component: LuigiPreloadComponent,\n data: { luigiRoute: '/home/reload' }\n },\n /** here an example if you want to reuse the component and not recreating every time you navigate to it (a singleton Component) It requires in your module to redefine */\n {\n path: 'luigi-client-support-preload=component',\n component: LuigiPreloadComponent,\n data: { reuse: true }\n }\n];\n\n@NgModule({\n declarations: [LuigiPreloadComponent],\n imports: [RouterModule.forChild(staticRoutes)],\n providers: [\n {\n provide: LuigiContextService,\n useClass: LuigiContextServiceImpl\n },\n {\n provide: RouteReuseStrategy,\n useClass: LuigiRouteStrategy\n }\n ],\n exports: [LuigiPreloadComponent]\n})\nexport class LuigiAngularSupportModule {\n constructor(\n navigation: LuigiAutoRoutingService,\n context: LuigiContextService\n ) {}\n}\n","import { APP_INITIALIZER, NgModule } from '@angular/core';\n\n// @dynamic\n@NgModule({\n providers: [\n {\n provide: APP_INITIALIZER,\n useFactory: LuigiMockModule.initPostMessageHook,\n multi: true\n }\n ]\n})\n\n/*\n * This class mocks Luigi Core related functionality.\n *\n * Micro Frontends that use Luigi Client would usually communicate with Luigi Core\n * back and forth. When testing Luigi Client based components, Luigi Core might\n * not be present which leads into limitations on integration/e2e testing for standalone\n * microfrontends.\n *\n * This module adds a hook to the window postMessage API by adding an event listener to the\n * global message event of the window object and mocking the callback.\n * In the normal workflow this message would picked up by Luigi Core which then sends the response back.\n */\nexport class LuigiMockModule {\n // Add a hook to the post message api to mock the LuigiCore response to the Client\n public static initPostMessageHook() {\n return async (): Promise<void> => {\n // Check if Luigi Client is running standalone\n if (window.parent === window) {\n console.debug('Detected standalone mode');\n\n // Check and skip if Luigi environment is already mocked\n if ((window as any).luigiMockEnvironment) {\n return;\n }\n\n (window as any).luigiMockEnvironment = {\n msgListener: function(e: any) {\n if (e.data.msg && (e.data.msg.startsWith('luigi.') || e.data.msg === 'storage')) {\n console.debug('Luigi msg', e.data);\n\n if (e.data.msg === 'luigi.get-context') {\n window.postMessage(\n {\n msg: 'luigi.init',\n emulated: true,\n internal: {\n viewStackSize: 1\n },\n context: e.data.context\n },\n '*'\n );\n }\n\n // vizualise retrieved event data\n LuigiMockModule.visualize(JSON.stringify(e.data));\n\n // Check and run mocked callback if it exists\n const mockListener = (window as any).luigiMockEnvironment.mockListeners[e.data.msg];\n if (mockListener) {\n mockListener(e);\n }\n }\n },\n mockListeners: {\n 'luigi.navigation.pathExists': (event: any) => {\n const mockData = window.sessionStorage.getItem('luigiMockData');\n let mockDataParsed = mockData ? JSON.parse(mockData) : undefined;\n const inputPath = event.data.data.link;\n const pathExists = mockDataParsed && mockDataParsed.pathExists && mockDataParsed.pathExists[inputPath];\n\n const response = {\n msg: 'luigi.navigation.pathExists.answer',\n data: {\n correlationId: event.data.data.id,\n pathExists: pathExists ? pathExists : false\n },\n emulated: true\n };\n window.postMessage(response, '*');\n },\n //ux\n 'luigi.ux.confirmationModal.show': (event: any) => {\n const response = {\n msg: 'luigi.ux.confirmationModal.hide',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.ux.alert.show': (event: any) => {\n const response = {\n msg: 'luigi.ux.alert.hide',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.ux.set-current-locale': (event: any) => {\n const response = {\n msg: 'luigi.current-locale-changed',\n currentLocale: event.data.data.currentLocale,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n // linkManager\n 'luigi.navigation.open': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.close': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.collapse': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.expand': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n // storage\n storage: () => {}\n }\n };\n\n // Listen to the global 'message' event of the window object\n window.addEventListener('message', (window as any).luigiMockEnvironment.msgListener);\n }\n };\n }\n\n /*\n * This method takes a data object of type 'any' and vizualizes a simple container\n * which holds data that is useful for e2e testing.\n */\n public static visualize(data: string): void {\n let luigiVisualizationContainer: Element | null = document.querySelector('#luigi-debug-vis-cnt');\n // Construct element structure if not already constructed\n if (!luigiVisualizationContainer) {\n luigiVisualizationContainer = document.createElement('div');\n luigiVisualizationContainer.setAttribute('id', 'luigi-debug-vis-cnt');\n // Hide the added DOM element to avoid interferring/overlapping with other elements during testing.\n luigiVisualizationContainer.setAttribute('style', 'display:none');\n document.body.appendChild(luigiVisualizationContainer);\n }\n const line: HTMLDivElement = document.createElement('div');\n line.textContent = data;\n luigiVisualizationContainer.appendChild(line);\n }\n}\n","/*\n * Public API Surface of client-support-angular\n */\n\nexport * from './lib/component/luigi.preload.component';\nexport * from './lib/luigi.angular.support.module';\nexport * from './lib/service/luigi-context-service';\nexport * from './lib/service/luigi-context.service.impl';\nexport * from './lib/service/luigi-auto-routing.service';\nexport * from './lib/luigi-mock/luigi-mock.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {LuigiRouteStrategy as ɵa} from './lib/route/luigi-route-strategy';"],"names":["Component","ILuigiContextTypes","ReplaySubject","addInitListener","addContextUpdateListener","first","Injectable","NgZone","Subscription","filter","NavigationEnd","convertToParamMap","linkManager","Router","BaseRouteReuseStrategy","NgModule","RouterModule","RouteReuseStrategy","APP_INITIALIZER"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qCACf,CAAC;oCACF,MAAM,CAAC,WAAW,CAAC,QAAQ,EAAE,GAAG,CAAC,CAAC;iCACnC;;gCAED,OAAO,EAAE,eAAQ;6BAClB;yBACF,CAAC;;wBAGF,MAAM,CAAC,gBAAgB,CAAC,SAAS,EAAG,MAAc,CAAC,oBAAoB,CAAC,WAAW,CAAC,CAAC;qBACtF;;;aACF,CAAA,GAAA,CAAC;SACH;;;;;QAMa,yBAAS,GAAhB,UAAiB,IAAY;YAClC,IAAI,2BAA2B,GAAmB,QAAQ,CAAC,aAAa,CAAC,sBAAsB,CAAC,CAAC;;YAEjG,IAAI,CAAC,2BAA2B,EAAE;gBAChC,2BAA2B,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;gBAC5D,2BAA2B,CAAC,YAAY,CAAC,IAAI,EAAE,qBAAqB,CAAC,CAAC;;gBAEtE,2BAA2B,CAAC,YAAY,CAAC,OAAO,EAAE,cAAc,CAAC,CAAC;gBAClE,QAAQ,CAAC,IAAI,CAAC,WAAW,CAAC,2BAA2B,CAAC,CAAC;aACxD;YACD,IAAM,IAAI,GAAmB,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;YAC3D,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC;YACxB,2BAA2B,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;SAC/C;;;;gBAvKFF,WAAQ,SAAC;oBACR,SAAS,EAAE;wBACT;4BACE,OAAO,EAAEG,kBAAe;4BACxB,UAAU,EAAE,eAAe,CAAC,mBAAmB;4BAC/C,KAAK,EAAE,IAAI;yBACZ;qBACF;iBACF;;;ICXD;;;;ICAA;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@angular/core"),require("@angular/router"),require("rxjs"),require("rxjs/operators"),require("@luigi-project/client")):"function"==typeof define&&define.amd?define("@luigi-project/client-support-angular",["exports","@angular/core","@angular/router","rxjs","rxjs/operators","@luigi-project/client"],e):e(((t="undefined"!=typeof globalThis?globalThis:t||self)["luigi-project"]=t["luigi-project"]||{},t["luigi-project"]["client-support-angular"]={}),t.ng.core,t.ng.router,t.rxjs,t.rxjs.operators,t.client)}(this,(function(t,e,n,o,i,r){"use strict";var a=function(){function t(){}return t.prototype.ngOnInit=function(){},t}();a.decorators=[{type:e.Component,args:[{selector:"lib-client-support-angular",template:'<p luigipreload="luigipreload"></p>\n'}]}],a.ctorParameters=function(){return[]};var u,s=function(){};(u=t.ILuigiContextTypes||(t.ILuigiContextTypes={}))[u.INIT=0]="INIT",u[u.UPDATE=1]="UPDATE";var c=function(){function e(){var
|
|
1
|
+
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@angular/core"),require("@angular/router"),require("rxjs"),require("rxjs/operators"),require("@luigi-project/client")):"function"==typeof define&&define.amd?define("@luigi-project/client-support-angular",["exports","@angular/core","@angular/router","rxjs","rxjs/operators","@luigi-project/client"],e):e(((t="undefined"!=typeof globalThis?globalThis:t||self)["luigi-project"]=t["luigi-project"]||{},t["luigi-project"]["client-support-angular"]={}),t.ng.core,t.ng.router,t.rxjs,t.rxjs.operators,t.client)}(this,(function(t,e,n,o,i,r){"use strict";var a=function(){function t(){}return t.prototype.ngOnInit=function(){},t}();a.decorators=[{type:e.Component,args:[{selector:"lib-client-support-angular",template:'<p luigipreload="luigipreload"></p>\n'}]}],a.ctorParameters=function(){return[]};var u,s=function(){};(u=t.ILuigiContextTypes||(t.ILuigiContextTypes={}))[u.INIT=0]="INIT",u[u.UPDATE=1]="UPDATE";var c=function(){function e(e){var n=this;this.zone=e,this.subject=new o.ReplaySubject(1),this.currentContext=null,r.addInitListener((function(e){n.addListener(t.ILuigiContextTypes.INIT,e)})),r.addContextUpdateListener((function(e){n.addListener(t.ILuigiContextTypes.UPDATE,e)}))}return e.prototype.contextObservable=function(){return this.subject.asObservable()},e.prototype.getContext=function(){return this.currentContext&&this.currentContext.context},e.prototype.getContextAsync=function(){var t=this;return new Promise((function(e,n){t.getContext()?e(t.getContext()):t.contextObservable().pipe(i.first()).subscribe((function(t){e(t.context)}))}))},e.prototype.setContext=function(t){var e=this;this.zone.run((function(){e.currentContext=t,e.subject.next(t)}))},e.prototype.addListener=function(t,e){this.setContext({contextType:t,context:e})},e}();c.ɵprov=e.ɵɵdefineInjectable({factory:function(){return new c(e.ɵɵinject(e.NgZone))},token:c,providedIn:"root"}),c.decorators=[{type:e.Injectable,args:[{providedIn:"root"}]}],c.ctorParameters=function(){return[{type:e.NgZone}]};var l=function(){function t(){}return t.getCurrent=function(){return t._current},t.setCurrent=function(e){t._current=e},t}();l._current=null;var d=function(){function t(t,e){this.router=t,this.luigiContextService=e,this.subscription=new o.Subscription,this.subscription.add(this.router.events.pipe(this.doFilter()).subscribe(this.doSubscription.bind(this)))}return t.prototype.doFilter=function(){return i.filter((function(t){return!(!(t instanceof n.NavigationEnd&&t.url&&t.url.length>0)||history.state&&history.state.luigiInduced)}))},t.prototype.doSubscription=function(t){var e,o=l.getCurrent();if(!o){o=this.router.routerState.root.snapshot;for(var i=function(){var t=null;if(null==o||o.children.forEach((function(e){"primary"===e.outlet&&(t=e)})),t)o=t;else{if(!o.firstChild)return"break";o=o.firstChild}};(null===(e=null==o?void 0:o.children)||void 0===e?void 0:e.length)>0;){if("break"===i())break}}if(null==o?void 0:o.data){if(o.data.luigiRoute){var a=o.data.luigiRoute;if(o.params){var u=n.convertToParamMap(o.params);u.keys.forEach((function(t){u.getAll(t).forEach((function(e){a=a.replace(":"+t,e)}))}))}var s=r.linkManager();if(o.data.fromContext){if(!this.luigiContextService.getContext())return void console.debug("Ignoring auto navigation request, luigi context not set");s=!0===o.data.fromContext?s.fromClosestContext():s.fromContext(o.data.fromContext)}return void s.withoutSync().navigate(a)}if(o.data.fromVirtualTreeRoot){var c=t.url,d=o.data.fromVirtualTreeRoot.truncate;if(d)if(0===d.indexOf("*")){var p=c.indexOf(d.substr(1));c=c.substr(p+d.length-1)}else 0===c.indexOf(d)&&(c=c.substr(d.length));console.debug("Calling fromVirtualTreeRoot for url ==> "+c),r.linkManager().fromVirtualTreeRoot().withoutSync().navigate(c)}}},t.prototype.ngOnDestroy=function(){this.subscription.unsubscribe()},t}();d.ɵprov=e.ɵɵdefineInjectable({factory:function(){return new d(e.ɵɵinject(n.Router),e.ɵɵinject(s))},token:d,providedIn:"root"}),d.decorators=[{type:e.Injectable,args:[{providedIn:"root"}]}],d.ctorParameters=function(){return[{type:n.Router},{type:s}]};
|
|
2
2
|
/*! *****************************************************************************
|
|
3
3
|
Copyright (c) Microsoft Corporation.
|
|
4
4
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../projects/client-support-angular/src/lib/component/luigi.preload.component.ts","../../projects/client-support-angular/src/lib/service/luigi-context-service.ts","../../projects/client-support-angular/src/lib/service/luigi-context.service.impl.ts","../../projects/client-support-angular/src/lib/route/luigi-activated-route-snapshot-helper.ts","../../projects/client-support-angular/src/lib/service/luigi-auto-routing.service.ts","../../../node_modules/tslib/tslib.es6.js","../../projects/client-support-angular/src/lib/route/luigi-route-strategy.ts","../../../projects/client-support-angular/src/lib/luigi.angular.support.module.ts","../../projects/client-support-angular/src/lib/luigi-mock/luigi-mock.module.ts"],"names":["LuigiPreloadComponent","prototype","ngOnInit","Component","args","selector","template","ILuigiContextTypes","LuigiContextServiceImpl","_this","this","subject","ReplaySubject","currentContext","addInitListener","initContext","addListener","INIT","addContextUpdateListener","updateContext","UPDATE","contextObservable","asObservable","getContext","context","getContextAsync","Promise","resolve","reject","pipe","first","subscribe","ctx","setContext","obj","next","contextType","Injectable","providedIn","LuigiActivatedRouteSnapshotHelper","getCurrent","_current","setCurrent","current","LuigiAutoRoutingService","router","luigiContextService","subscription","Subscription","add","events","doFilter","doSubscription","bind","filter","event","NavigationEnd","url","length","history","state","luigiInduced","routerState","root","snapshot","primary","children","forEach","childSnapshot","outlet","firstChild","_a","data","luigiRoute","route_1","params","pmap_1","convertToParamMap","keys","key","getAll","param","replace","lm","linkManager","fromContext","console","debug","fromClosestContext","withoutSync","navigate","fromVirtualTreeRoot","truncate","indexOf","index","substr","ngOnDestroy","unsubscribe","Router","LuigiContextService","extendStatics","d","b","Object","setPrototypeOf","__proto__","Array","p","hasOwnProperty","call","__awaiter","thisArg","_arguments","P","generator","fulfilled","value","step","e","rejected","result","done","then","apply","__generator","body","f","y","t","g","_","label","sent","trys","ops","verb","throw","return","Symbol","iterator","n","v","op","TypeError","pop","push","create","LuigiRouteStrategy","__","constructor","__extends","_super","retrieve","route","BaseRouteReuseStrategy","ɵ1","ɵ2","reuse","staticRoutes","path","component","ɵ0","navigation","NgModule","declarations","imports","RouterModule","forChild","providers","provide","useClass","RouteReuseStrategy","exports","LuigiMockModule","initPostMessageHook","window","parent","luigiMockEnvironment","msgListener","msg","startsWith","postMessage","emulated","internal","viewStackSize","visualize","JSON","stringify","mockListener","mockListeners","luigi.navigation.pathExists","mockData","sessionStorage","getItem","mockDataParsed","parse","undefined","inputPath","link","pathExists","response","correlationId","id","luigi.ux.confirmationModal.show","luigi.ux.alert.show","luigi.ux.set-current-locale","currentLocale","luigi.navigation.open","luigi.navigation.splitview.close","luigi.navigation.splitview.collapse","luigi.navigation.splitview.expand","storage","addEventListener","luigiVisualizationContainer","document","querySelector","createElement","setAttribute","appendChild","line","textContent","APP_INITIALIZER","useFactory","multi"],"mappings":"yoBAQE,SAAAA,YACAA,EAAAC,UAAAC,SAAA,sCAPDC,EAAAA,UAASC,KAAA,CAAC,CACTC,SAAU,6BACVC,SAAA,sFCiBUC,IAlBZ,cAkBYA,EAAAA,EAAAA,qBAAAA,EAAAA,mBAAkB,KAC5BA,EAAA,KAAA,GAAA,OACAA,EAAAA,EAAA,OAAA,GAAA,0BCAA,SAAAC,IAAA,IAAAC,EAAAC,KALQA,KAAAC,QAA0C,IAAIC,EAAAA,cAEpD,GACMF,KAAAG,eAAmC,KAGzCC,EAAAA,iBAAgB,SAA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BL,SAASE,cAAc,OACpDG,EAAKC,YAAcpJ,EACnB6I,EAA4BK,YAAYC,6BAtK3CxD,EAAAA,SAAQ/J,KAAA,CAAC,CACRoK,UAAW,CACT,CACEC,QAASoD,EAAAA,gBACTC,WAAYjD,EAAgBC,oBAC5BiD,OAAO","sourcesContent":["import { Component, OnInit } from '@angular/core';\n\n@Component({\n selector: 'lib-client-support-angular',\n templateUrl: './luigi.preload.component.html',\n styles: []\n})\nexport class LuigiPreloadComponent implements OnInit {\n constructor() {}\n ngOnInit(): void {}\n}\n","import { Context } from '@luigi-project/client';\nimport { Observable } from 'rxjs';\n\nexport abstract class LuigiContextService {\n /**\n * Listen to context changes\n * Receives current value, even if the event was already dispatched earlier.\n */\n abstract contextObservable(): Observable<IContextMessage>;\n\n /**\n * Get latest set context object (can be null/undefined, if not set yet)\n */\n abstract getContext(): Context;\n\n /**\n * Get a promise that resolves when context is set.\n */\n abstract getContextAsync(): Promise<Context>;\n}\n\nexport enum ILuigiContextTypes {\n INIT,\n UPDATE\n}\n\nexport interface IContextMessage {\n contextType: ILuigiContextTypes; // will be init or update\n context: Context;\n}\n","import { Injectable } from '@angular/core';\nimport { ReplaySubject, Observable } from 'rxjs';\nimport { first } from 'rxjs/operators';\nimport {\n Context,\n addInitListener,\n addContextUpdateListener\n} from '@luigi-project/client';\nimport {\n IContextMessage,\n ILuigiContextTypes,\n LuigiContextService\n} from './luigi-context-service';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LuigiContextServiceImpl implements LuigiContextService {\n private subject: ReplaySubject<IContextMessage> = new ReplaySubject<\n IContextMessage\n >(1);\n private currentContext: IContextMessage = (null as unknown) as IContextMessage;\n\n constructor() {\n addInitListener(initContext => {\n this.addListener(ILuigiContextTypes.INIT, initContext);\n });\n addContextUpdateListener(updateContext => {\n this.addListener(ILuigiContextTypes.UPDATE, updateContext);\n });\n }\n\n public contextObservable(): Observable<IContextMessage> {\n return this.subject.asObservable();\n }\n\n /**\n * Get latest context object retrieved from luigi core application or none, if not yet set.\n */\n public getContext(): Context {\n return this.currentContext && this.currentContext.context;\n }\n\n /**\n * Get a promise that resolves when context is set.\n */\n public getContextAsync(): Promise<Context> {\n return new Promise<Context>((resolve, reject) => {\n if (this.getContext()) {\n resolve(this.getContext());\n } else {\n this.contextObservable()\n .pipe(first())\n .subscribe(ctx => {\n resolve(ctx.context);\n });\n }\n });\n }\n\n /**\n * Set current context\n */\n protected setContext(obj: IContextMessage): void {\n this.currentContext = obj;\n this.subject.next(obj);\n }\n\n addListener(contextType: ILuigiContextTypes, context: Context): void {\n this.setContext({\n contextType,\n context\n } as IContextMessage);\n }\n}\n","import { ActivatedRouteSnapshot } from '@angular/router';\n\nexport class LuigiActivatedRouteSnapshotHelper {\n // tslint:disable-next-line:variable-name\n private static _current: ActivatedRouteSnapshot = (null as unknown) as ActivatedRouteSnapshot;\n\n static getCurrent(): ActivatedRouteSnapshot {\n return LuigiActivatedRouteSnapshotHelper._current;\n }\n\n static setCurrent(current: ActivatedRouteSnapshot): void {\n LuigiActivatedRouteSnapshotHelper._current = current;\n }\n}\n","import { Injectable, OnDestroy } from '@angular/core';\nimport { OperatorFunction, PartialObserver, Subscription } from 'rxjs';\nimport {\n convertToParamMap,\n NavigationEnd,\n ParamMap,\n Router,\n RouterEvent\n} from '@angular/router';\nimport { linkManager } from '@luigi-project/client';\nimport { filter } from 'rxjs/operators';\nimport { LuigiActivatedRouteSnapshotHelper } from '../route/luigi-activated-route-snapshot-helper';\nimport { LuigiContextService } from './luigi-context-service';\nimport { ActivatedRouteSnapshot } from '@angular/router';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LuigiAutoRoutingService implements OnDestroy {\n private subscription: Subscription = new Subscription();\n\n constructor(\n private router: Router,\n private luigiContextService: LuigiContextService\n ) {\n this.subscription.add(\n this.router.events\n .pipe(this.doFilter())\n .subscribe(this.doSubscription.bind(this) as () => void)\n );\n }\n\n doFilter(): OperatorFunction<unknown, RouterEvent> {\n return filter((event): event is RouterEvent => {\n return !!(\n event instanceof NavigationEnd &&\n event.url &&\n event.url.length > 0 &&\n !(history.state && history.state.luigiInduced)\n );\n });\n }\n\n /**\n * This method will be take in consideration angular route that having in data object the paramter\n * fromVirtualTreeRoot: true, here an example:\n * {path: 'demo', component: DemoComponent, data:{fromVirtualTreeRoot: true}}\n * Another option is to specify the LuigiPath: if you add in route data luigiRoute:'/xxxx/xxx';\n * in the case we will update the path in LuigiCore navigation, here an example\n * {path: 'demo', component: DemoComponent, data:{luigiRoute: '/home/demo''}}\n * @param event the NavigationEnd event\n */\n doSubscription(event: NavigationEnd): void {\n let current: ActivatedRouteSnapshot | null = LuigiActivatedRouteSnapshotHelper.getCurrent();\n\n if (!current) {\n current = this.router.routerState.root.snapshot;\n while (current?.children?.length > 0) {\n // handle multiple children\n let primary: ActivatedRouteSnapshot | null = null;\n\n current?.children.forEach(childSnapshot => {\n if (childSnapshot.outlet === 'primary') {\n primary = childSnapshot;\n }\n });\n if (primary) {\n current = primary;\n } else if (current.firstChild) {\n current = current.firstChild;\n } else {\n break;\n }\n }\n }\n\n if (current?.data) {\n if (current.data.luigiRoute) {\n let route = current.data.luigiRoute;\n\n if (current.params) {\n const pmap: ParamMap = convertToParamMap(current.params);\n pmap.keys.forEach(key => {\n const val = pmap.getAll(key).forEach(param => {\n route = route.replace(':' + key, param);\n });\n });\n }\n let lm = linkManager();\n if (current.data.fromContext) {\n if (!this.luigiContextService.getContext()) {\n console.debug(\n 'Ignoring auto navigation request, luigi context not set'\n );\n return;\n }\n if (current.data.fromContext === true) {\n lm = lm.fromClosestContext();\n } else {\n lm = lm.fromContext(current.data.fromContext);\n }\n }\n\n lm.withoutSync().navigate(route);\n return;\n }\n if (current.data.fromVirtualTreeRoot) {\n let url = event.url;\n const truncate = current.data.fromVirtualTreeRoot.truncate;\n if (truncate) {\n if (truncate.indexOf('*') === 0) {\n const index = url.indexOf(truncate.substr(1));\n url = url.substr(index + truncate.length - 1);\n }\n else if (url.indexOf(truncate) === 0) {\n url = url.substr(truncate.length);\n }\n }\n console.debug('Calling fromVirtualTreeRoot for url ==> ' + url);\n linkManager()\n .fromVirtualTreeRoot()\n .withoutSync()\n .navigate(url);\n }\n }\n }\n\n ngOnDestroy(): void {\n this.subscription.unsubscribe();\n }\n}\n","/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n};\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, privateMap) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to get private field on non-instance\");\r\n }\r\n return privateMap.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, privateMap, value) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to set private field on non-instance\");\r\n }\r\n privateMap.set(receiver, value);\r\n return value;\r\n}\r\n","import { BaseRouteReuseStrategy } from '@angular/router';\nimport { ActivatedRouteSnapshot, DetachedRouteHandle } from '@angular/router';\nimport { LuigiActivatedRouteSnapshotHelper } from './luigi-activated-route-snapshot-helper';\n\nexport class LuigiRouteStrategy extends BaseRouteReuseStrategy {\n retrieve(route: ActivatedRouteSnapshot): DetachedRouteHandle | null {\n LuigiActivatedRouteSnapshotHelper.setCurrent(route);\n return super.retrieve(route);\n }\n}\n","import { NgModule } from '@angular/core';\nimport { RouteReuseStrategy, RouterModule, Routes } from '@angular/router';\nimport { LuigiPreloadComponent } from './component/luigi.preload.component';\nimport { LuigiContextService } from './service/luigi-context-service';\nimport { LuigiContextServiceImpl } from './service/luigi-context.service.impl';\nimport { LuigiAutoRoutingService } from './service/luigi-auto-routing.service';\nimport { LuigiRouteStrategy } from './route/luigi-route-strategy';\n\nexport const staticRoutes: Routes = [\n /** here an example if you want to specify that this component is a virtualTree element in Luigi Core navigation*/\n {\n path: 'luigi-client-support-preload',\n component: LuigiPreloadComponent,\n data: { fromVirtualTreeRoot: true }\n },\n /** here an example if you want to specify that this component it is a luigi component and u want to change the navigation in Luigi core*/\n {\n path: 'luigi-client-support-preload',\n component: LuigiPreloadComponent,\n data: { luigiRoute: '/home/reload' }\n },\n /** here an example if you want to reuse the component and not recreating every time you navigate to it (a singleton Component) It requires in your module to redefine */\n {\n path: 'luigi-client-support-preload=component',\n component: LuigiPreloadComponent,\n data: { reuse: true }\n }\n];\n\n@NgModule({\n declarations: [LuigiPreloadComponent],\n imports: [RouterModule.forChild(staticRoutes)],\n providers: [\n {\n provide: LuigiContextService,\n useClass: LuigiContextServiceImpl\n },\n {\n provide: RouteReuseStrategy,\n useClass: LuigiRouteStrategy\n }\n ],\n exports: [LuigiPreloadComponent]\n})\nexport class LuigiAngularSupportModule {\n constructor(\n navigation: LuigiAutoRoutingService,\n context: LuigiContextService\n ) {}\n}\n","import { APP_INITIALIZER, NgModule } from '@angular/core';\n\n// @dynamic\n@NgModule({\n providers: [\n {\n provide: APP_INITIALIZER,\n useFactory: LuigiMockModule.initPostMessageHook,\n multi: true\n }\n ]\n})\n\n/*\n * This class mocks Luigi Core related functionality.\n *\n * Micro Frontends that use Luigi Client would usually communicate with Luigi Core\n * back and forth. When testing Luigi Client based components, Luigi Core might\n * not be present which leads into limitations on integration/e2e testing for standalone\n * microfrontends.\n *\n * This module adds a hook to the window postMessage API by adding an event listener to the\n * global message event of the window object and mocking the callback.\n * In the normal workflow this message would picked up by Luigi Core which then sends the response back.\n */\nexport class LuigiMockModule {\n // Add a hook to the post message api to mock the LuigiCore response to the Client\n public static initPostMessageHook() {\n return async (): Promise<void> => {\n // Check if Luigi Client is running standalone\n if (window.parent === window) {\n console.debug('Detected standalone mode');\n\n // Check and skip if Luigi environment is already mocked\n if ((window as any).luigiMockEnvironment) {\n return;\n }\n\n (window as any).luigiMockEnvironment = {\n msgListener: function(e: any) {\n if (e.data.msg && (e.data.msg.startsWith('luigi.') || e.data.msg === 'storage')) {\n console.debug('Luigi msg', e.data);\n\n if (e.data.msg === 'luigi.get-context') {\n window.postMessage(\n {\n msg: 'luigi.init',\n emulated: true,\n internal: {\n viewStackSize: 1\n },\n context: e.data.context\n },\n '*'\n );\n }\n\n // vizualise retrieved event data\n LuigiMockModule.visualize(JSON.stringify(e.data));\n\n // Check and run mocked callback if it exists\n const mockListener = (window as any).luigiMockEnvironment.mockListeners[e.data.msg];\n if (mockListener) {\n mockListener(e);\n }\n }\n },\n mockListeners: {\n 'luigi.navigation.pathExists': (event: any) => {\n const mockData = window.sessionStorage.getItem('luigiMockData');\n let mockDataParsed = mockData ? JSON.parse(mockData) : undefined;\n const inputPath = event.data.data.link;\n const pathExists = mockDataParsed && mockDataParsed.pathExists && mockDataParsed.pathExists[inputPath];\n\n const response = {\n msg: 'luigi.navigation.pathExists.answer',\n data: {\n correlationId: event.data.data.id,\n pathExists: pathExists ? pathExists : false\n },\n emulated: true\n };\n window.postMessage(response, '*');\n },\n //ux\n 'luigi.ux.confirmationModal.show': (event: any) => {\n const response = {\n msg: 'luigi.ux.confirmationModal.hide',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.ux.alert.show': (event: any) => {\n const response = {\n msg: 'luigi.ux.alert.hide',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.ux.set-current-locale': (event: any) => {\n const response = {\n msg: 'luigi.current-locale-changed',\n currentLocale: event.data.data.currentLocale,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n // linkManager\n 'luigi.navigation.open': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.close': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.collapse': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.expand': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n // storage\n storage: () => {}\n }\n };\n\n // Listen to the global 'message' event of the window object\n window.addEventListener('message', (window as any).luigiMockEnvironment.msgListener);\n }\n };\n }\n\n /*\n * This method takes a data object of type 'any' and vizualizes a simple container\n * which holds data that is useful for e2e testing.\n */\n public static visualize(data: string): void {\n let luigiVisualizationContainer: Element | null = document.querySelector('#luigi-debug-vis-cnt');\n // Construct element structure if not already constructed\n if (!luigiVisualizationContainer) {\n luigiVisualizationContainer = document.createElement('div');\n luigiVisualizationContainer.setAttribute('id', 'luigi-debug-vis-cnt');\n // Hide the added DOM element to avoid interferring/overlapping with other elements during testing.\n luigiVisualizationContainer.setAttribute('style', 'display:none');\n document.body.appendChild(luigiVisualizationContainer);\n }\n const line: HTMLDivElement = document.createElement('div');\n line.textContent = data;\n luigiVisualizationContainer.appendChild(line);\n }\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../../projects/client-support-angular/src/lib/component/luigi.preload.component.ts","../../projects/client-support-angular/src/lib/service/luigi-context-service.ts","../../projects/client-support-angular/src/lib/service/luigi-context.service.impl.ts","../../projects/client-support-angular/src/lib/route/luigi-activated-route-snapshot-helper.ts","../../projects/client-support-angular/src/lib/service/luigi-auto-routing.service.ts","../../../node_modules/tslib/tslib.es6.js","../../projects/client-support-angular/src/lib/route/luigi-route-strategy.ts","../../../projects/client-support-angular/src/lib/luigi.angular.support.module.ts","../../projects/client-support-angular/src/lib/luigi-mock/luigi-mock.module.ts"],"names":["LuigiPreloadComponent","prototype","ngOnInit","Component","args","selector","template","ILuigiContextTypes","LuigiContextServiceImpl","zone","_this","this","subject","ReplaySubject","currentContext","addInitListener","initContext","addListener","INIT","addContextUpdateListener","updateContext","UPDATE","contextObservable","asObservable","getContext","context","getContextAsync","Promise","resolve","reject","pipe","first","subscribe","ctx","setContext","obj","run","next","contextType","Injectable","providedIn","NgZone","LuigiActivatedRouteSnapshotHelper","getCurrent","_current","setCurrent","current","LuigiAutoRoutingService","router","luigiContextService","subscription","Subscription","add","events","doFilter","doSubscription","bind","filter","event","NavigationEnd","url","length","history","state","luigiInduced","routerState","root","snapshot","primary","children","forEach","childSnapshot","outlet","firstChild","_a","data","luigiRoute","route_1","params","pmap_1","convertToParamMap","keys","key","getAll","param","replace","lm","linkManager","fromContext","console","debug","fromClosestContext","withoutSync","navigate","fromVirtualTreeRoot","truncate","indexOf","index","substr","ngOnDestroy","unsubscribe","Router","LuigiContextService","extendStatics","d","b","Object","setPrototypeOf","__proto__","Array","p","hasOwnProperty","call","__awaiter","thisArg","_arguments","P","generator","fulfilled","value","step","e","rejected","result","done","then","apply","__generator","body","f","y","t","g","_","label","sent","trys","ops","verb","throw","return","Symbol","iterator","n","v","op","TypeError","pop","push","create","LuigiRouteStrategy","__","constructor","__extends","_super","retrieve","route","BaseRouteReuseStrategy","ɵ1","ɵ2","reuse","staticRoutes","path","component","ɵ0","navigation","NgModule","declarations","imports","RouterModule","forChild","providers","provide","useClass","RouteReuseStrategy","exports","LuigiMockModule","initPostMessageHook","window","parent","luigiMockEnvironment","msgListener","msg","startsWith","postMessage","emulated","internal","viewStackSize","visualize","JSON","stringify","mockListener","mockListeners","luigi.navigation.pathExists","mockData","sessionStorage","getItem","mockDataParsed","parse","undefined","inputPath","link","pathExists","response","correlationId","id","luigi.ux.confirmationModal.show","luigi.ux.alert.show","luigi.ux.set-current-locale","currentLocale","luigi.navigation.open","luigi.navigation.splitview.close","luigi.navigation.splitview.collapse","luigi.navigation.splitview.expand","storage","addEventListener","luigiVisualizationContainer","document","querySelector","createElement","setAttribute","appendChild","line","textContent","APP_INITIALIZER","useFactory","multi"],"mappings":"yoBAQE,SAAAA,YACAA,EAAAC,UAAAC,SAAA,sCAPDC,EAAAA,UAASC,KAAA,CAAC,CACTC,SAAU,6BACVC,SAAA,sFCiBUC,IAlBZ,cAkBYA,EAAAA,EAAAA,qBAAAA,EAAAA,mBAAkB,KAC5BA,EAAA,KAAA,GAAA,OACAA,EAAAA,EAAA,OAAA,GAAA,0BCVA,SAAAC,EAAoBC,GAApB,IAAAC,EAAAC,KAAoBA,KAAAF,KAAAA,EAHZE,KAAAC,QAA0C,IAAIC,EAAAA,cAA+B,GAC7EF,KAAAG,eAAmC,KAGzCC,EAAAA,iBAAgB,SAAAC,GACdN,EAAKO,YAAYV,EAAAA,mBAAmBW,KAAMF,MAE5CG,EAAAA,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ASE,cAAc,OACpDG,EAAKC,YAAcpJ,EACnB6I,EAA4BK,YAAYC,6BAtK3CxD,EAAAA,SAAQlK,KAAA,CAAC,CACRuK,UAAW,CACT,CACEC,QAASoD,EAAAA,gBACTC,WAAYjD,EAAgBC,oBAC5BiD,OAAO","sourcesContent":["import { Component, OnInit } from '@angular/core';\n\n@Component({\n selector: 'lib-client-support-angular',\n templateUrl: './luigi.preload.component.html',\n styles: []\n})\nexport class LuigiPreloadComponent implements OnInit {\n constructor() {}\n ngOnInit(): void {}\n}\n","import { Context } from '@luigi-project/client';\nimport { Observable } from 'rxjs';\n\nexport abstract class LuigiContextService {\n /**\n * Listen to context changes\n * Receives current value, even if the event was already dispatched earlier.\n */\n abstract contextObservable(): Observable<IContextMessage>;\n\n /**\n * Get latest set context object (can be null/undefined, if not set yet)\n */\n abstract getContext(): Context;\n\n /**\n * Get a promise that resolves when context is set.\n */\n abstract getContextAsync(): Promise<Context>;\n}\n\nexport enum ILuigiContextTypes {\n INIT,\n UPDATE\n}\n\nexport interface IContextMessage {\n contextType: ILuigiContextTypes; // will be init or update\n context: Context;\n}\n","import { Injectable, NgZone } from '@angular/core';\nimport { ReplaySubject, Observable } from 'rxjs';\nimport { first } from 'rxjs/operators';\nimport { Context, addInitListener, addContextUpdateListener } from '@luigi-project/client';\nimport { IContextMessage, ILuigiContextTypes, LuigiContextService } from './luigi-context-service';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LuigiContextServiceImpl implements LuigiContextService {\n private subject: ReplaySubject<IContextMessage> = new ReplaySubject<IContextMessage>(1);\n private currentContext: IContextMessage = (null as unknown) as IContextMessage;\n\n constructor(private zone: NgZone) {\n addInitListener(initContext => {\n this.addListener(ILuigiContextTypes.INIT, initContext);\n });\n addContextUpdateListener(updateContext => {\n this.addListener(ILuigiContextTypes.UPDATE, updateContext);\n });\n }\n\n public contextObservable(): Observable<IContextMessage> {\n return this.subject.asObservable();\n }\n\n /**\n * Get latest context object retrieved from luigi core application or none, if not yet set.\n */\n public getContext(): Context {\n return this.currentContext && this.currentContext.context;\n }\n\n /**\n * Get a promise that resolves when context is set.\n */\n public getContextAsync(): Promise<Context> {\n return new Promise<Context>((resolve, reject) => {\n if (this.getContext()) {\n resolve(this.getContext());\n } else {\n this.contextObservable()\n .pipe(first())\n .subscribe(ctx => {\n resolve(ctx.context);\n });\n }\n });\n }\n\n /**\n * Set current context\n */\n protected setContext(obj: IContextMessage): void {\n this.zone.run(() => {\n this.currentContext = obj;\n this.subject.next(obj);\n });\n }\n\n addListener(contextType: ILuigiContextTypes, context: Context): void {\n this.setContext({\n contextType,\n context\n } as IContextMessage);\n }\n}\n","import { ActivatedRouteSnapshot } from '@angular/router';\n\nexport class LuigiActivatedRouteSnapshotHelper {\n // tslint:disable-next-line:variable-name\n private static _current: ActivatedRouteSnapshot = (null as unknown) as ActivatedRouteSnapshot;\n\n static getCurrent(): ActivatedRouteSnapshot {\n return LuigiActivatedRouteSnapshotHelper._current;\n }\n\n static setCurrent(current: ActivatedRouteSnapshot): void {\n LuigiActivatedRouteSnapshotHelper._current = current;\n }\n}\n","import { Injectable, OnDestroy } from '@angular/core';\nimport { OperatorFunction, PartialObserver, Subscription } from 'rxjs';\nimport {\n convertToParamMap,\n NavigationEnd,\n ParamMap,\n Router,\n RouterEvent\n} from '@angular/router';\nimport { linkManager } from '@luigi-project/client';\nimport { filter } from 'rxjs/operators';\nimport { LuigiActivatedRouteSnapshotHelper } from '../route/luigi-activated-route-snapshot-helper';\nimport { LuigiContextService } from './luigi-context-service';\nimport { ActivatedRouteSnapshot } from '@angular/router';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LuigiAutoRoutingService implements OnDestroy {\n private subscription: Subscription = new Subscription();\n\n constructor(\n private router: Router,\n private luigiContextService: LuigiContextService\n ) {\n this.subscription.add(\n this.router.events\n .pipe(this.doFilter())\n .subscribe(this.doSubscription.bind(this) as () => void)\n );\n }\n\n doFilter(): OperatorFunction<unknown, RouterEvent> {\n return filter((event): event is RouterEvent => {\n return !!(\n event instanceof NavigationEnd &&\n event.url &&\n event.url.length > 0 &&\n !(history.state && history.state.luigiInduced)\n );\n });\n }\n\n /**\n * This method will be take in consideration angular route that having in data object the paramter\n * fromVirtualTreeRoot: true, here an example:\n * {path: 'demo', component: DemoComponent, data:{fromVirtualTreeRoot: true}}\n * Another option is to specify the LuigiPath: if you add in route data luigiRoute:'/xxxx/xxx';\n * in the case we will update the path in LuigiCore navigation, here an example\n * {path: 'demo', component: DemoComponent, data:{luigiRoute: '/home/demo''}}\n * @param event the NavigationEnd event\n */\n doSubscription(event: NavigationEnd): void {\n let current: ActivatedRouteSnapshot | null = LuigiActivatedRouteSnapshotHelper.getCurrent();\n\n if (!current) {\n current = this.router.routerState.root.snapshot;\n while (current?.children?.length > 0) {\n // handle multiple children\n let primary: ActivatedRouteSnapshot | null = null;\n\n current?.children.forEach(childSnapshot => {\n if (childSnapshot.outlet === 'primary') {\n primary = childSnapshot;\n }\n });\n if (primary) {\n current = primary;\n } else if (current.firstChild) {\n current = current.firstChild;\n } else {\n break;\n }\n }\n }\n\n if (current?.data) {\n if (current.data.luigiRoute) {\n let route = current.data.luigiRoute;\n\n if (current.params) {\n const pmap: ParamMap = convertToParamMap(current.params);\n pmap.keys.forEach(key => {\n const val = pmap.getAll(key).forEach(param => {\n route = route.replace(':' + key, param);\n });\n });\n }\n let lm = linkManager();\n if (current.data.fromContext) {\n if (!this.luigiContextService.getContext()) {\n console.debug(\n 'Ignoring auto navigation request, luigi context not set'\n );\n return;\n }\n if (current.data.fromContext === true) {\n lm = lm.fromClosestContext();\n } else {\n lm = lm.fromContext(current.data.fromContext);\n }\n }\n\n lm.withoutSync().navigate(route);\n return;\n }\n if (current.data.fromVirtualTreeRoot) {\n let url = event.url;\n const truncate = current.data.fromVirtualTreeRoot.truncate;\n if (truncate) {\n if (truncate.indexOf('*') === 0) {\n const index = url.indexOf(truncate.substr(1));\n url = url.substr(index + truncate.length - 1);\n }\n else if (url.indexOf(truncate) === 0) {\n url = url.substr(truncate.length);\n }\n }\n console.debug('Calling fromVirtualTreeRoot for url ==> ' + url);\n linkManager()\n .fromVirtualTreeRoot()\n .withoutSync()\n .navigate(url);\n }\n }\n }\n\n ngOnDestroy(): void {\n this.subscription.unsubscribe();\n }\n}\n","/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n};\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, privateMap) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to get private field on non-instance\");\r\n }\r\n return privateMap.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, privateMap, value) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to set private field on non-instance\");\r\n }\r\n privateMap.set(receiver, value);\r\n return value;\r\n}\r\n","import { BaseRouteReuseStrategy } from '@angular/router';\nimport { ActivatedRouteSnapshot, DetachedRouteHandle } from '@angular/router';\nimport { LuigiActivatedRouteSnapshotHelper } from './luigi-activated-route-snapshot-helper';\n\nexport class LuigiRouteStrategy extends BaseRouteReuseStrategy {\n retrieve(route: ActivatedRouteSnapshot): DetachedRouteHandle | null {\n LuigiActivatedRouteSnapshotHelper.setCurrent(route);\n return super.retrieve(route);\n }\n}\n","import { NgModule } from '@angular/core';\nimport { RouteReuseStrategy, RouterModule, Routes } from '@angular/router';\nimport { LuigiPreloadComponent } from './component/luigi.preload.component';\nimport { LuigiContextService } from './service/luigi-context-service';\nimport { LuigiContextServiceImpl } from './service/luigi-context.service.impl';\nimport { LuigiAutoRoutingService } from './service/luigi-auto-routing.service';\nimport { LuigiRouteStrategy } from './route/luigi-route-strategy';\n\nexport const staticRoutes: Routes = [\n /** here an example if you want to specify that this component is a virtualTree element in Luigi Core navigation*/\n {\n path: 'luigi-client-support-preload',\n component: LuigiPreloadComponent,\n data: { fromVirtualTreeRoot: true }\n },\n /** here an example if you want to specify that this component it is a luigi component and u want to change the navigation in Luigi core*/\n {\n path: 'luigi-client-support-preload',\n component: LuigiPreloadComponent,\n data: { luigiRoute: '/home/reload' }\n },\n /** here an example if you want to reuse the component and not recreating every time you navigate to it (a singleton Component) It requires in your module to redefine */\n {\n path: 'luigi-client-support-preload=component',\n component: LuigiPreloadComponent,\n data: { reuse: true }\n }\n];\n\n@NgModule({\n declarations: [LuigiPreloadComponent],\n imports: [RouterModule.forChild(staticRoutes)],\n providers: [\n {\n provide: LuigiContextService,\n useClass: LuigiContextServiceImpl\n },\n {\n provide: RouteReuseStrategy,\n useClass: LuigiRouteStrategy\n }\n ],\n exports: [LuigiPreloadComponent]\n})\nexport class LuigiAngularSupportModule {\n constructor(\n navigation: LuigiAutoRoutingService,\n context: LuigiContextService\n ) {}\n}\n","import { APP_INITIALIZER, NgModule } from '@angular/core';\n\n// @dynamic\n@NgModule({\n providers: [\n {\n provide: APP_INITIALIZER,\n useFactory: LuigiMockModule.initPostMessageHook,\n multi: true\n }\n ]\n})\n\n/*\n * This class mocks Luigi Core related functionality.\n *\n * Micro Frontends that use Luigi Client would usually communicate with Luigi Core\n * back and forth. When testing Luigi Client based components, Luigi Core might\n * not be present which leads into limitations on integration/e2e testing for standalone\n * microfrontends.\n *\n * This module adds a hook to the window postMessage API by adding an event listener to the\n * global message event of the window object and mocking the callback.\n * In the normal workflow this message would picked up by Luigi Core which then sends the response back.\n */\nexport class LuigiMockModule {\n // Add a hook to the post message api to mock the LuigiCore response to the Client\n public static initPostMessageHook() {\n return async (): Promise<void> => {\n // Check if Luigi Client is running standalone\n if (window.parent === window) {\n console.debug('Detected standalone mode');\n\n // Check and skip if Luigi environment is already mocked\n if ((window as any).luigiMockEnvironment) {\n return;\n }\n\n (window as any).luigiMockEnvironment = {\n msgListener: function(e: any) {\n if (e.data.msg && (e.data.msg.startsWith('luigi.') || e.data.msg === 'storage')) {\n console.debug('Luigi msg', e.data);\n\n if (e.data.msg === 'luigi.get-context') {\n window.postMessage(\n {\n msg: 'luigi.init',\n emulated: true,\n internal: {\n viewStackSize: 1\n },\n context: e.data.context\n },\n '*'\n );\n }\n\n // vizualise retrieved event data\n LuigiMockModule.visualize(JSON.stringify(e.data));\n\n // Check and run mocked callback if it exists\n const mockListener = (window as any).luigiMockEnvironment.mockListeners[e.data.msg];\n if (mockListener) {\n mockListener(e);\n }\n }\n },\n mockListeners: {\n 'luigi.navigation.pathExists': (event: any) => {\n const mockData = window.sessionStorage.getItem('luigiMockData');\n let mockDataParsed = mockData ? JSON.parse(mockData) : undefined;\n const inputPath = event.data.data.link;\n const pathExists = mockDataParsed && mockDataParsed.pathExists && mockDataParsed.pathExists[inputPath];\n\n const response = {\n msg: 'luigi.navigation.pathExists.answer',\n data: {\n correlationId: event.data.data.id,\n pathExists: pathExists ? pathExists : false\n },\n emulated: true\n };\n window.postMessage(response, '*');\n },\n //ux\n 'luigi.ux.confirmationModal.show': (event: any) => {\n const response = {\n msg: 'luigi.ux.confirmationModal.hide',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.ux.alert.show': (event: any) => {\n const response = {\n msg: 'luigi.ux.alert.hide',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.ux.set-current-locale': (event: any) => {\n const response = {\n msg: 'luigi.current-locale-changed',\n currentLocale: event.data.data.currentLocale,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n // linkManager\n 'luigi.navigation.open': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.close': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.collapse': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.expand': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n // storage\n storage: () => {}\n }\n };\n\n // Listen to the global 'message' event of the window object\n window.addEventListener('message', (window as any).luigiMockEnvironment.msgListener);\n }\n };\n }\n\n /*\n * This method takes a data object of type 'any' and vizualizes a simple container\n * which holds data that is useful for e2e testing.\n */\n public static visualize(data: string): void {\n let luigiVisualizationContainer: Element | null = document.querySelector('#luigi-debug-vis-cnt');\n // Construct element structure if not already constructed\n if (!luigiVisualizationContainer) {\n luigiVisualizationContainer = document.createElement('div');\n luigiVisualizationContainer.setAttribute('id', 'luigi-debug-vis-cnt');\n // Hide the added DOM element to avoid interferring/overlapping with other elements during testing.\n luigiVisualizationContainer.setAttribute('style', 'display:none');\n document.body.appendChild(luigiVisualizationContainer);\n }\n const line: HTMLDivElement = document.createElement('div');\n line.textContent = data;\n luigiVisualizationContainer.appendChild(line);\n }\n}\n"]}
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import { Injectable } from '@angular/core';
|
|
1
|
+
import { Injectable, NgZone } from '@angular/core';
|
|
2
2
|
import { ReplaySubject } from 'rxjs';
|
|
3
3
|
import { first } from 'rxjs/operators';
|
|
4
4
|
import { addInitListener, addContextUpdateListener } from '@luigi-project/client';
|
|
5
5
|
import { ILuigiContextTypes } from './luigi-context-service';
|
|
6
6
|
import * as i0 from "@angular/core";
|
|
7
7
|
export class LuigiContextServiceImpl {
|
|
8
|
-
constructor() {
|
|
8
|
+
constructor(zone) {
|
|
9
|
+
this.zone = zone;
|
|
9
10
|
this.subject = new ReplaySubject(1);
|
|
10
11
|
this.currentContext = null;
|
|
11
12
|
addInitListener(initContext => {
|
|
@@ -45,8 +46,10 @@ export class LuigiContextServiceImpl {
|
|
|
45
46
|
* Set current context
|
|
46
47
|
*/
|
|
47
48
|
setContext(obj) {
|
|
48
|
-
this.
|
|
49
|
-
|
|
49
|
+
this.zone.run(() => {
|
|
50
|
+
this.currentContext = obj;
|
|
51
|
+
this.subject.next(obj);
|
|
52
|
+
});
|
|
50
53
|
}
|
|
51
54
|
addListener(contextType, context) {
|
|
52
55
|
this.setContext({
|
|
@@ -55,11 +58,13 @@ export class LuigiContextServiceImpl {
|
|
|
55
58
|
});
|
|
56
59
|
}
|
|
57
60
|
}
|
|
58
|
-
LuigiContextServiceImpl.ɵprov = i0.ɵɵdefineInjectable({ factory: function LuigiContextServiceImpl_Factory() { return new LuigiContextServiceImpl(); }, token: LuigiContextServiceImpl, providedIn: "root" });
|
|
61
|
+
LuigiContextServiceImpl.ɵprov = i0.ɵɵdefineInjectable({ factory: function LuigiContextServiceImpl_Factory() { return new LuigiContextServiceImpl(i0.ɵɵinject(i0.NgZone)); }, token: LuigiContextServiceImpl, providedIn: "root" });
|
|
59
62
|
LuigiContextServiceImpl.decorators = [
|
|
60
63
|
{ type: Injectable, args: [{
|
|
61
64
|
providedIn: 'root'
|
|
62
65
|
},] }
|
|
63
66
|
];
|
|
64
|
-
LuigiContextServiceImpl.ctorParameters = () => [
|
|
65
|
-
|
|
67
|
+
LuigiContextServiceImpl.ctorParameters = () => [
|
|
68
|
+
{ type: NgZone }
|
|
69
|
+
];
|
|
70
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibHVpZ2ktY29udGV4dC5zZXJ2aWNlLmltcGwuanMiLCJzb3VyY2VSb290IjoiLi4vLi4vLi4vLi4vcHJvamVjdHMvY2xpZW50LXN1cHBvcnQtYW5ndWxhci9zcmMvIiwic291cmNlcyI6WyJsaWIvc2VydmljZS9sdWlnaS1jb250ZXh0LnNlcnZpY2UuaW1wbC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsVUFBVSxFQUFFLE1BQU0sRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUNuRCxPQUFPLEVBQUUsYUFBYSxFQUFjLE1BQU0sTUFBTSxDQUFDO0FBQ2pELE9BQU8sRUFBRSxLQUFLLEVBQUUsTUFBTSxnQkFBZ0IsQ0FBQztBQUN2QyxPQUFPLEVBQVcsZUFBZSxFQUFFLHdCQUF3QixFQUFFLE1BQU0sdUJBQXVCLENBQUM7QUFDM0YsT0FBTyxFQUFtQixrQkFBa0IsRUFBdUIsTUFBTSx5QkFBeUIsQ0FBQzs7QUFLbkcsTUFBTSxPQUFPLHVCQUF1QjtJQUlsQyxZQUFvQixJQU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IH0gYXMgSUNvbnRleHRNZXNzYWdlKTtcbiAgfVxufVxuIl19
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Component, ɵɵdefineInjectable,
|
|
1
|
+
import { Component, ɵɵdefineInjectable, ɵɵinject, NgZone, Injectable, NgModule, APP_INITIALIZER } from '@angular/core';
|
|
2
2
|
import { NavigationEnd, convertToParamMap, Router, BaseRouteReuseStrategy, RouterModule, RouteReuseStrategy } from '@angular/router';
|
|
3
3
|
import { ReplaySubject, Subscription } from 'rxjs';
|
|
4
4
|
import { first, filter } from 'rxjs/operators';
|
|
@@ -26,7 +26,8 @@ var ILuigiContextTypes;
|
|
|
26
26
|
})(ILuigiContextTypes || (ILuigiContextTypes = {}));
|
|
27
27
|
|
|
28
28
|
class LuigiContextServiceImpl {
|
|
29
|
-
constructor() {
|
|
29
|
+
constructor(zone) {
|
|
30
|
+
this.zone = zone;
|
|
30
31
|
this.subject = new ReplaySubject(1);
|
|
31
32
|
this.currentContext = null;
|
|
32
33
|
addInitListener(initContext => {
|
|
@@ -66,8 +67,10 @@ class LuigiContextServiceImpl {
|
|
|
66
67
|
* Set current context
|
|
67
68
|
*/
|
|
68
69
|
setContext(obj) {
|
|
69
|
-
this.
|
|
70
|
-
|
|
70
|
+
this.zone.run(() => {
|
|
71
|
+
this.currentContext = obj;
|
|
72
|
+
this.subject.next(obj);
|
|
73
|
+
});
|
|
71
74
|
}
|
|
72
75
|
addListener(contextType, context) {
|
|
73
76
|
this.setContext({
|
|
@@ -76,13 +79,15 @@ class LuigiContextServiceImpl {
|
|
|
76
79
|
});
|
|
77
80
|
}
|
|
78
81
|
}
|
|
79
|
-
LuigiContextServiceImpl.ɵprov = ɵɵdefineInjectable({ factory: function LuigiContextServiceImpl_Factory() { return new LuigiContextServiceImpl(); }, token: LuigiContextServiceImpl, providedIn: "root" });
|
|
82
|
+
LuigiContextServiceImpl.ɵprov = ɵɵdefineInjectable({ factory: function LuigiContextServiceImpl_Factory() { return new LuigiContextServiceImpl(ɵɵinject(NgZone)); }, token: LuigiContextServiceImpl, providedIn: "root" });
|
|
80
83
|
LuigiContextServiceImpl.decorators = [
|
|
81
84
|
{ type: Injectable, args: [{
|
|
82
85
|
providedIn: 'root'
|
|
83
86
|
},] }
|
|
84
87
|
];
|
|
85
|
-
LuigiContextServiceImpl.ctorParameters = () => [
|
|
88
|
+
LuigiContextServiceImpl.ctorParameters = () => [
|
|
89
|
+
{ type: NgZone }
|
|
90
|
+
];
|
|
86
91
|
|
|
87
92
|
class LuigiActivatedRouteSnapshotHelper {
|
|
88
93
|
static getCurrent() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"luigi-project-client-support-angular.js","sources":["../../projects/client-support-angular/src/lib/component/luigi.preload.component.ts","../../projects/client-support-angular/src/lib/service/luigi-context-service.ts","../../projects/client-support-angular/src/lib/service/luigi-context.service.impl.ts","../../projects/client-support-angular/src/lib/route/luigi-activated-route-snapshot-helper.ts","../../projects/client-support-angular/src/lib/service/luigi-auto-routing.service.ts","../../projects/client-support-angular/src/lib/route/luigi-route-strategy.ts","../../../projects/client-support-angular/src/lib/luigi.angular.support.module.ts","../../projects/client-support-angular/src/lib/luigi-mock/luigi-mock.module.ts","../../../../projects/client-support-angular/src/public-api.ts","../../../../projects/client-support-angular/src/luigi-project-client-support-angular.ts"],"sourcesContent":["import { Component, OnInit } from '@angular/core';\n\n@Component({\n selector: 'lib-client-support-angular',\n templateUrl: './luigi.preload.component.html',\n styles: []\n})\nexport class LuigiPreloadComponent implements OnInit {\n constructor() {}\n ngOnInit(): void {}\n}\n","import { Context } from '@luigi-project/client';\nimport { Observable } from 'rxjs';\n\nexport abstract class LuigiContextService {\n /**\n * Listen to context changes\n * Receives current value, even if the event was already dispatched earlier.\n */\n abstract contextObservable(): Observable<IContextMessage>;\n\n /**\n * Get latest set context object (can be null/undefined, if not set yet)\n */\n abstract getContext(): Context;\n\n /**\n * Get a promise that resolves when context is set.\n */\n abstract getContextAsync(): Promise<Context>;\n}\n\nexport enum ILuigiContextTypes {\n INIT,\n UPDATE\n}\n\nexport interface IContextMessage {\n contextType: ILuigiContextTypes; // will be init or update\n context: Context;\n}\n","import { Injectable } from '@angular/core';\nimport { ReplaySubject, Observable } from 'rxjs';\nimport { first } from 'rxjs/operators';\nimport {\n Context,\n addInitListener,\n addContextUpdateListener\n} from '@luigi-project/client';\nimport {\n IContextMessage,\n ILuigiContextTypes,\n LuigiContextService\n} from './luigi-context-service';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LuigiContextServiceImpl implements LuigiContextService {\n private subject: ReplaySubject<IContextMessage> = new ReplaySubject<\n IContextMessage\n >(1);\n private currentContext: IContextMessage = (null as unknown) as IContextMessage;\n\n constructor() {\n addInitListener(initContext => {\n this.addListener(ILuigiContextTypes.INIT, initContext);\n });\n addContextUpdateListener(updateContext => {\n this.addListener(ILuigiContextTypes.UPDATE, updateContext);\n });\n }\n\n public contextObservable(): Observable<IContextMessage> {\n return this.subject.asObservable();\n }\n\n /**\n * Get latest context object retrieved from luigi core application or none, if not yet set.\n */\n public getContext(): Context {\n return this.currentContext && this.currentContext.context;\n }\n\n /**\n * Get a promise that resolves when context is set.\n */\n public getContextAsync(): Promise<Context> {\n return new Promise<Context>((resolve, reject) => {\n if (this.getContext()) {\n resolve(this.getContext());\n } else {\n this.contextObservable()\n .pipe(first())\n .subscribe(ctx => {\n resolve(ctx.context);\n });\n }\n });\n }\n\n /**\n * Set current context\n */\n protected setContext(obj: IContextMessage): void {\n this.currentContext = obj;\n this.subject.next(obj);\n }\n\n addListener(contextType: ILuigiContextTypes, context: Context): void {\n this.setContext({\n contextType,\n context\n } as IContextMessage);\n }\n}\n","import { ActivatedRouteSnapshot } from '@angular/router';\n\nexport class LuigiActivatedRouteSnapshotHelper {\n // tslint:disable-next-line:variable-name\n private static _current: ActivatedRouteSnapshot = (null as unknown) as ActivatedRouteSnapshot;\n\n static getCurrent(): ActivatedRouteSnapshot {\n return LuigiActivatedRouteSnapshotHelper._current;\n }\n\n static setCurrent(current: ActivatedRouteSnapshot): void {\n LuigiActivatedRouteSnapshotHelper._current = current;\n }\n}\n","import { Injectable, OnDestroy } from '@angular/core';\nimport { OperatorFunction, PartialObserver, Subscription } from 'rxjs';\nimport {\n convertToParamMap,\n NavigationEnd,\n ParamMap,\n Router,\n RouterEvent\n} from '@angular/router';\nimport { linkManager } from '@luigi-project/client';\nimport { filter } from 'rxjs/operators';\nimport { LuigiActivatedRouteSnapshotHelper } from '../route/luigi-activated-route-snapshot-helper';\nimport { LuigiContextService } from './luigi-context-service';\nimport { ActivatedRouteSnapshot } from '@angular/router';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LuigiAutoRoutingService implements OnDestroy {\n private subscription: Subscription = new Subscription();\n\n constructor(\n private router: Router,\n private luigiContextService: LuigiContextService\n ) {\n this.subscription.add(\n this.router.events\n .pipe(this.doFilter())\n .subscribe(this.doSubscription.bind(this) as () => void)\n );\n }\n\n doFilter(): OperatorFunction<unknown, RouterEvent> {\n return filter((event): event is RouterEvent => {\n return !!(\n event instanceof NavigationEnd &&\n event.url &&\n event.url.length > 0 &&\n !(history.state && history.state.luigiInduced)\n );\n });\n }\n\n /**\n * This method will be take in consideration angular route that having in data object the paramter\n * fromVirtualTreeRoot: true, here an example:\n * {path: 'demo', component: DemoComponent, data:{fromVirtualTreeRoot: true}}\n * Another option is to specify the LuigiPath: if you add in route data luigiRoute:'/xxxx/xxx';\n * in the case we will update the path in LuigiCore navigation, here an example\n * {path: 'demo', component: DemoComponent, data:{luigiRoute: '/home/demo''}}\n * @param event the NavigationEnd event\n */\n doSubscription(event: NavigationEnd): void {\n let current: ActivatedRouteSnapshot | null = LuigiActivatedRouteSnapshotHelper.getCurrent();\n\n if (!current) {\n current = this.router.routerState.root.snapshot;\n while (current?.children?.length > 0) {\n // handle multiple children\n let primary: ActivatedRouteSnapshot | null = null;\n\n current?.children.forEach(childSnapshot => {\n if (childSnapshot.outlet === 'primary') {\n primary = childSnapshot;\n }\n });\n if (primary) {\n current = primary;\n } else if (current.firstChild) {\n current = current.firstChild;\n } else {\n break;\n }\n }\n }\n\n if (current?.data) {\n if (current.data.luigiRoute) {\n let route = current.data.luigiRoute;\n\n if (current.params) {\n const pmap: ParamMap = convertToParamMap(current.params);\n pmap.keys.forEach(key => {\n const val = pmap.getAll(key).forEach(param => {\n route = route.replace(':' + key, param);\n });\n });\n }\n let lm = linkManager();\n if (current.data.fromContext) {\n if (!this.luigiContextService.getContext()) {\n console.debug(\n 'Ignoring auto navigation request, luigi context not set'\n );\n return;\n }\n if (current.data.fromContext === true) {\n lm = lm.fromClosestContext();\n } else {\n lm = lm.fromContext(current.data.fromContext);\n }\n }\n\n lm.withoutSync().navigate(route);\n return;\n }\n if (current.data.fromVirtualTreeRoot) {\n let url = event.url;\n const truncate = current.data.fromVirtualTreeRoot.truncate;\n if (truncate) {\n if (truncate.indexOf('*') === 0) {\n const index = url.indexOf(truncate.substr(1));\n url = url.substr(index + truncate.length - 1);\n }\n else if (url.indexOf(truncate) === 0) {\n url = url.substr(truncate.length);\n }\n }\n console.debug('Calling fromVirtualTreeRoot for url ==> ' + url);\n linkManager()\n .fromVirtualTreeRoot()\n .withoutSync()\n .navigate(url);\n }\n }\n }\n\n ngOnDestroy(): void {\n this.subscription.unsubscribe();\n }\n}\n","import { BaseRouteReuseStrategy } from '@angular/router';\nimport { ActivatedRouteSnapshot, DetachedRouteHandle } from '@angular/router';\nimport { LuigiActivatedRouteSnapshotHelper } from './luigi-activated-route-snapshot-helper';\n\nexport class LuigiRouteStrategy extends BaseRouteReuseStrategy {\n retrieve(route: ActivatedRouteSnapshot): DetachedRouteHandle | null {\n LuigiActivatedRouteSnapshotHelper.setCurrent(route);\n return super.retrieve(route);\n }\n}\n","import { NgModule } from '@angular/core';\nimport { RouteReuseStrategy, RouterModule, Routes } from '@angular/router';\nimport { LuigiPreloadComponent } from './component/luigi.preload.component';\nimport { LuigiContextService } from './service/luigi-context-service';\nimport { LuigiContextServiceImpl } from './service/luigi-context.service.impl';\nimport { LuigiAutoRoutingService } from './service/luigi-auto-routing.service';\nimport { LuigiRouteStrategy } from './route/luigi-route-strategy';\n\nexport const staticRoutes: Routes = [\n /** here an example if you want to specify that this component is a virtualTree element in Luigi Core navigation*/\n {\n path: 'luigi-client-support-preload',\n component: LuigiPreloadComponent,\n data: { fromVirtualTreeRoot: true }\n },\n /** here an example if you want to specify that this component it is a luigi component and u want to change the navigation in Luigi core*/\n {\n path: 'luigi-client-support-preload',\n component: LuigiPreloadComponent,\n data: { luigiRoute: '/home/reload' }\n },\n /** here an example if you want to reuse the component and not recreating every time you navigate to it (a singleton Component) It requires in your module to redefine */\n {\n path: 'luigi-client-support-preload=component',\n component: LuigiPreloadComponent,\n data: { reuse: true }\n }\n];\n\n@NgModule({\n declarations: [LuigiPreloadComponent],\n imports: [RouterModule.forChild(staticRoutes)],\n providers: [\n {\n provide: LuigiContextService,\n useClass: LuigiContextServiceImpl\n },\n {\n provide: RouteReuseStrategy,\n useClass: LuigiRouteStrategy\n }\n ],\n exports: [LuigiPreloadComponent]\n})\nexport class LuigiAngularSupportModule {\n constructor(\n navigation: LuigiAutoRoutingService,\n context: LuigiContextService\n ) {}\n}\n","import { APP_INITIALIZER, NgModule } from '@angular/core';\n\n// @dynamic\n@NgModule({\n providers: [\n {\n provide: APP_INITIALIZER,\n useFactory: LuigiMockModule.initPostMessageHook,\n multi: true\n }\n ]\n})\n\n/*\n * This class mocks Luigi Core related functionality.\n *\n * Micro Frontends that use Luigi Client would usually communicate with Luigi Core\n * back and forth. When testing Luigi Client based components, Luigi Core might\n * not be present which leads into limitations on integration/e2e testing for standalone\n * microfrontends.\n *\n * This module adds a hook to the window postMessage API by adding an event listener to the\n * global message event of the window object and mocking the callback.\n * In the normal workflow this message would picked up by Luigi Core which then sends the response back.\n */\nexport class LuigiMockModule {\n // Add a hook to the post message api to mock the LuigiCore response to the Client\n public static initPostMessageHook() {\n return async (): Promise<void> => {\n // Check if Luigi Client is running standalone\n if (window.parent === window) {\n console.debug('Detected standalone mode');\n\n // Check and skip if Luigi environment is already mocked\n if ((window as any).luigiMockEnvironment) {\n return;\n }\n\n (window as any).luigiMockEnvironment = {\n msgListener: function(e: any) {\n if (e.data.msg && (e.data.msg.startsWith('luigi.') || e.data.msg === 'storage')) {\n console.debug('Luigi msg', e.data);\n\n if (e.data.msg === 'luigi.get-context') {\n window.postMessage(\n {\n msg: 'luigi.init',\n emulated: true,\n internal: {\n viewStackSize: 1\n },\n context: e.data.context\n },\n '*'\n );\n }\n\n // vizualise retrieved event data\n LuigiMockModule.visualize(JSON.stringify(e.data));\n\n // Check and run mocked callback if it exists\n const mockListener = (window as any).luigiMockEnvironment.mockListeners[e.data.msg];\n if (mockListener) {\n mockListener(e);\n }\n }\n },\n mockListeners: {\n 'luigi.navigation.pathExists': (event: any) => {\n const mockData = window.sessionStorage.getItem('luigiMockData');\n let mockDataParsed = mockData ? JSON.parse(mockData) : undefined;\n const inputPath = event.data.data.link;\n const pathExists = mockDataParsed && mockDataParsed.pathExists && mockDataParsed.pathExists[inputPath];\n\n const response = {\n msg: 'luigi.navigation.pathExists.answer',\n data: {\n correlationId: event.data.data.id,\n pathExists: pathExists ? pathExists : false\n },\n emulated: true\n };\n window.postMessage(response, '*');\n },\n //ux\n 'luigi.ux.confirmationModal.show': (event: any) => {\n const response = {\n msg: 'luigi.ux.confirmationModal.hide',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.ux.alert.show': (event: any) => {\n const response = {\n msg: 'luigi.ux.alert.hide',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.ux.set-current-locale': (event: any) => {\n const response = {\n msg: 'luigi.current-locale-changed',\n currentLocale: event.data.data.currentLocale,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n // linkManager\n 'luigi.navigation.open': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.close': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.collapse': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.expand': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n // storage\n storage: () => {}\n }\n };\n\n // Listen to the global 'message' event of the window object\n window.addEventListener('message', (window as any).luigiMockEnvironment.msgListener);\n }\n };\n }\n\n /*\n * This method takes a data object of type 'any' and vizualizes a simple container\n * which holds data that is useful for e2e testing.\n */\n public static visualize(data: string): void {\n let luigiVisualizationContainer: Element | null = document.querySelector('#luigi-debug-vis-cnt');\n // Construct element structure if not already constructed\n if (!luigiVisualizationContainer) {\n luigiVisualizationContainer = document.createElement('div');\n luigiVisualizationContainer.setAttribute('id', 'luigi-debug-vis-cnt');\n // Hide the added DOM element to avoid interferring/overlapping with other elements during testing.\n luigiVisualizationContainer.setAttribute('style', 'display:none');\n document.body.appendChild(luigiVisualizationContainer);\n }\n const line: HTMLDivElement = document.createElement('div');\n line.textContent = data;\n luigiVisualizationContainer.appendChild(line);\n }\n}\n","/*\n * Public API Surface of client-support-angular\n */\n\nexport * from './lib/component/luigi.preload.component';\nexport * from './lib/luigi.angular.support.module';\nexport * from './lib/service/luigi-context-service';\nexport * from './lib/service/luigi-context.service.impl';\nexport * from './lib/service/luigi-auto-routing.service';\nexport * from './lib/luigi-mock/luigi-mock.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {LuigiRouteStrategy as ɵa} from './lib/route/luigi-route-strategy';"],"names":[],"mappings":";;;;;;;MAOa,qBAAqB;IAChC,iBAAgB;IAChB,QAAQ,MAAW;;;YAPpB,SAAS,SAAC;gBACT,QAAQ,EAAE,4BAA4B;gBACtC,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AC,OAAO,EAAE,cAAc,CAAC,CAAC;YAClE,QAAQ,CAAC,IAAI,CAAC,WAAW,CAAC,2BAA2B,CAAC,CAAC;SACxD;QACD,MAAM,IAAI,GAAmB,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;QAC3D,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC;QACxB,2BAA2B,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;KAC/C;;;YAvKF,QAAQ,SAAC;gBACR,SAAS,EAAE;oBACT;wBACE,OAAO,EAAE,eAAe;wBACxB,UAAU,EAAE,eAAe,CAAC,mBAAmB;wBAC/C,KAAK,EAAE,IAAI;qBACZ;iBACF;aACF;;;ACXD;;;;ACAA;;;;;;"}
|
|
1
|
+
{"version":3,"file":"luigi-project-client-support-angular.js","sources":["../../projects/client-support-angular/src/lib/component/luigi.preload.component.ts","../../projects/client-support-angular/src/lib/service/luigi-context-service.ts","../../projects/client-support-angular/src/lib/service/luigi-context.service.impl.ts","../../projects/client-support-angular/src/lib/route/luigi-activated-route-snapshot-helper.ts","../../projects/client-support-angular/src/lib/service/luigi-auto-routing.service.ts","../../projects/client-support-angular/src/lib/route/luigi-route-strategy.ts","../../../projects/client-support-angular/src/lib/luigi.angular.support.module.ts","../../projects/client-support-angular/src/lib/luigi-mock/luigi-mock.module.ts","../../../../projects/client-support-angular/src/public-api.ts","../../../../projects/client-support-angular/src/luigi-project-client-support-angular.ts"],"sourcesContent":["import { Component, OnInit } from '@angular/core';\n\n@Component({\n selector: 'lib-client-support-angular',\n templateUrl: './luigi.preload.component.html',\n styles: []\n})\nexport class LuigiPreloadComponent implements OnInit {\n constructor() {}\n ngOnInit(): void {}\n}\n","import { Context } from '@luigi-project/client';\nimport { Observable } from 'rxjs';\n\nexport abstract class LuigiContextService {\n /**\n * Listen to context changes\n * Receives current value, even if the event was already dispatched earlier.\n */\n abstract contextObservable(): Observable<IContextMessage>;\n\n /**\n * Get latest set context object (can be null/undefined, if not set yet)\n */\n abstract getContext(): Context;\n\n /**\n * Get a promise that resolves when context is set.\n */\n abstract getContextAsync(): Promise<Context>;\n}\n\nexport enum ILuigiContextTypes {\n INIT,\n UPDATE\n}\n\nexport interface IContextMessage {\n contextType: ILuigiContextTypes; // will be init or update\n context: Context;\n}\n","import { Injectable, NgZone } from '@angular/core';\nimport { ReplaySubject, Observable } from 'rxjs';\nimport { first } from 'rxjs/operators';\nimport { Context, addInitListener, addContextUpdateListener } from '@luigi-project/client';\nimport { IContextMessage, ILuigiContextTypes, LuigiContextService } from './luigi-context-service';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LuigiContextServiceImpl implements LuigiContextService {\n private subject: ReplaySubject<IContextMessage> = new ReplaySubject<IContextMessage>(1);\n private currentContext: IContextMessage = (null as unknown) as IContextMessage;\n\n constructor(private zone: NgZone) {\n addInitListener(initContext => {\n this.addListener(ILuigiContextTypes.INIT, initContext);\n });\n addContextUpdateListener(updateContext => {\n this.addListener(ILuigiContextTypes.UPDATE, updateContext);\n });\n }\n\n public contextObservable(): Observable<IContextMessage> {\n return this.subject.asObservable();\n }\n\n /**\n * Get latest context object retrieved from luigi core application or none, if not yet set.\n */\n public getContext(): Context {\n return this.currentContext && this.currentContext.context;\n }\n\n /**\n * Get a promise that resolves when context is set.\n */\n public getContextAsync(): Promise<Context> {\n return new Promise<Context>((resolve, reject) => {\n if (this.getContext()) {\n resolve(this.getContext());\n } else {\n this.contextObservable()\n .pipe(first())\n .subscribe(ctx => {\n resolve(ctx.context);\n });\n }\n });\n }\n\n /**\n * Set current context\n */\n protected setContext(obj: IContextMessage): void {\n this.zone.run(() => {\n this.currentContext = obj;\n this.subject.next(obj);\n });\n }\n\n addListener(contextType: ILuigiContextTypes, context: Context): void {\n this.setContext({\n contextType,\n context\n } as IContextMessage);\n }\n}\n","import { ActivatedRouteSnapshot } from '@angular/router';\n\nexport class LuigiActivatedRouteSnapshotHelper {\n // tslint:disable-next-line:variable-name\n private static _current: ActivatedRouteSnapshot = (null as unknown) as ActivatedRouteSnapshot;\n\n static getCurrent(): ActivatedRouteSnapshot {\n return LuigiActivatedRouteSnapshotHelper._current;\n }\n\n static setCurrent(current: ActivatedRouteSnapshot): void {\n LuigiActivatedRouteSnapshotHelper._current = current;\n }\n}\n","import { Injectable, OnDestroy } from '@angular/core';\nimport { OperatorFunction, PartialObserver, Subscription } from 'rxjs';\nimport {\n convertToParamMap,\n NavigationEnd,\n ParamMap,\n Router,\n RouterEvent\n} from '@angular/router';\nimport { linkManager } from '@luigi-project/client';\nimport { filter } from 'rxjs/operators';\nimport { LuigiActivatedRouteSnapshotHelper } from '../route/luigi-activated-route-snapshot-helper';\nimport { LuigiContextService } from './luigi-context-service';\nimport { ActivatedRouteSnapshot } from '@angular/router';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class LuigiAutoRoutingService implements OnDestroy {\n private subscription: Subscription = new Subscription();\n\n constructor(\n private router: Router,\n private luigiContextService: LuigiContextService\n ) {\n this.subscription.add(\n this.router.events\n .pipe(this.doFilter())\n .subscribe(this.doSubscription.bind(this) as () => void)\n );\n }\n\n doFilter(): OperatorFunction<unknown, RouterEvent> {\n return filter((event): event is RouterEvent => {\n return !!(\n event instanceof NavigationEnd &&\n event.url &&\n event.url.length > 0 &&\n !(history.state && history.state.luigiInduced)\n );\n });\n }\n\n /**\n * This method will be take in consideration angular route that having in data object the paramter\n * fromVirtualTreeRoot: true, here an example:\n * {path: 'demo', component: DemoComponent, data:{fromVirtualTreeRoot: true}}\n * Another option is to specify the LuigiPath: if you add in route data luigiRoute:'/xxxx/xxx';\n * in the case we will update the path in LuigiCore navigation, here an example\n * {path: 'demo', component: DemoComponent, data:{luigiRoute: '/home/demo''}}\n * @param event the NavigationEnd event\n */\n doSubscription(event: NavigationEnd): void {\n let current: ActivatedRouteSnapshot | null = LuigiActivatedRouteSnapshotHelper.getCurrent();\n\n if (!current) {\n current = this.router.routerState.root.snapshot;\n while (current?.children?.length > 0) {\n // handle multiple children\n let primary: ActivatedRouteSnapshot | null = null;\n\n current?.children.forEach(childSnapshot => {\n if (childSnapshot.outlet === 'primary') {\n primary = childSnapshot;\n }\n });\n if (primary) {\n current = primary;\n } else if (current.firstChild) {\n current = current.firstChild;\n } else {\n break;\n }\n }\n }\n\n if (current?.data) {\n if (current.data.luigiRoute) {\n let route = current.data.luigiRoute;\n\n if (current.params) {\n const pmap: ParamMap = convertToParamMap(current.params);\n pmap.keys.forEach(key => {\n const val = pmap.getAll(key).forEach(param => {\n route = route.replace(':' + key, param);\n });\n });\n }\n let lm = linkManager();\n if (current.data.fromContext) {\n if (!this.luigiContextService.getContext()) {\n console.debug(\n 'Ignoring auto navigation request, luigi context not set'\n );\n return;\n }\n if (current.data.fromContext === true) {\n lm = lm.fromClosestContext();\n } else {\n lm = lm.fromContext(current.data.fromContext);\n }\n }\n\n lm.withoutSync().navigate(route);\n return;\n }\n if (current.data.fromVirtualTreeRoot) {\n let url = event.url;\n const truncate = current.data.fromVirtualTreeRoot.truncate;\n if (truncate) {\n if (truncate.indexOf('*') === 0) {\n const index = url.indexOf(truncate.substr(1));\n url = url.substr(index + truncate.length - 1);\n }\n else if (url.indexOf(truncate) === 0) {\n url = url.substr(truncate.length);\n }\n }\n console.debug('Calling fromVirtualTreeRoot for url ==> ' + url);\n linkManager()\n .fromVirtualTreeRoot()\n .withoutSync()\n .navigate(url);\n }\n }\n }\n\n ngOnDestroy(): void {\n this.subscription.unsubscribe();\n }\n}\n","import { BaseRouteReuseStrategy } from '@angular/router';\nimport { ActivatedRouteSnapshot, DetachedRouteHandle } from '@angular/router';\nimport { LuigiActivatedRouteSnapshotHelper } from './luigi-activated-route-snapshot-helper';\n\nexport class LuigiRouteStrategy extends BaseRouteReuseStrategy {\n retrieve(route: ActivatedRouteSnapshot): DetachedRouteHandle | null {\n LuigiActivatedRouteSnapshotHelper.setCurrent(route);\n return super.retrieve(route);\n }\n}\n","import { NgModule } from '@angular/core';\nimport { RouteReuseStrategy, RouterModule, Routes } from '@angular/router';\nimport { LuigiPreloadComponent } from './component/luigi.preload.component';\nimport { LuigiContextService } from './service/luigi-context-service';\nimport { LuigiContextServiceImpl } from './service/luigi-context.service.impl';\nimport { LuigiAutoRoutingService } from './service/luigi-auto-routing.service';\nimport { LuigiRouteStrategy } from './route/luigi-route-strategy';\n\nexport const staticRoutes: Routes = [\n /** here an example if you want to specify that this component is a virtualTree element in Luigi Core navigation*/\n {\n path: 'luigi-client-support-preload',\n component: LuigiPreloadComponent,\n data: { fromVirtualTreeRoot: true }\n },\n /** here an example if you want to specify that this component it is a luigi component and u want to change the navigation in Luigi core*/\n {\n path: 'luigi-client-support-preload',\n component: LuigiPreloadComponent,\n data: { luigiRoute: '/home/reload' }\n },\n /** here an example if you want to reuse the component and not recreating every time you navigate to it (a singleton Component) It requires in your module to redefine */\n {\n path: 'luigi-client-support-preload=component',\n component: LuigiPreloadComponent,\n data: { reuse: true }\n }\n];\n\n@NgModule({\n declarations: [LuigiPreloadComponent],\n imports: [RouterModule.forChild(staticRoutes)],\n providers: [\n {\n provide: LuigiContextService,\n useClass: LuigiContextServiceImpl\n },\n {\n provide: RouteReuseStrategy,\n useClass: LuigiRouteStrategy\n }\n ],\n exports: [LuigiPreloadComponent]\n})\nexport class LuigiAngularSupportModule {\n constructor(\n navigation: LuigiAutoRoutingService,\n context: LuigiContextService\n ) {}\n}\n","import { APP_INITIALIZER, NgModule } from '@angular/core';\n\n// @dynamic\n@NgModule({\n providers: [\n {\n provide: APP_INITIALIZER,\n useFactory: LuigiMockModule.initPostMessageHook,\n multi: true\n }\n ]\n})\n\n/*\n * This class mocks Luigi Core related functionality.\n *\n * Micro Frontends that use Luigi Client would usually communicate with Luigi Core\n * back and forth. When testing Luigi Client based components, Luigi Core might\n * not be present which leads into limitations on integration/e2e testing for standalone\n * microfrontends.\n *\n * This module adds a hook to the window postMessage API by adding an event listener to the\n * global message event of the window object and mocking the callback.\n * In the normal workflow this message would picked up by Luigi Core which then sends the response back.\n */\nexport class LuigiMockModule {\n // Add a hook to the post message api to mock the LuigiCore response to the Client\n public static initPostMessageHook() {\n return async (): Promise<void> => {\n // Check if Luigi Client is running standalone\n if (window.parent === window) {\n console.debug('Detected standalone mode');\n\n // Check and skip if Luigi environment is already mocked\n if ((window as any).luigiMockEnvironment) {\n return;\n }\n\n (window as any).luigiMockEnvironment = {\n msgListener: function(e: any) {\n if (e.data.msg && (e.data.msg.startsWith('luigi.') || e.data.msg === 'storage')) {\n console.debug('Luigi msg', e.data);\n\n if (e.data.msg === 'luigi.get-context') {\n window.postMessage(\n {\n msg: 'luigi.init',\n emulated: true,\n internal: {\n viewStackSize: 1\n },\n context: e.data.context\n },\n '*'\n );\n }\n\n // vizualise retrieved event data\n LuigiMockModule.visualize(JSON.stringify(e.data));\n\n // Check and run mocked callback if it exists\n const mockListener = (window as any).luigiMockEnvironment.mockListeners[e.data.msg];\n if (mockListener) {\n mockListener(e);\n }\n }\n },\n mockListeners: {\n 'luigi.navigation.pathExists': (event: any) => {\n const mockData = window.sessionStorage.getItem('luigiMockData');\n let mockDataParsed = mockData ? JSON.parse(mockData) : undefined;\n const inputPath = event.data.data.link;\n const pathExists = mockDataParsed && mockDataParsed.pathExists && mockDataParsed.pathExists[inputPath];\n\n const response = {\n msg: 'luigi.navigation.pathExists.answer',\n data: {\n correlationId: event.data.data.id,\n pathExists: pathExists ? pathExists : false\n },\n emulated: true\n };\n window.postMessage(response, '*');\n },\n //ux\n 'luigi.ux.confirmationModal.show': (event: any) => {\n const response = {\n msg: 'luigi.ux.confirmationModal.hide',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.ux.alert.show': (event: any) => {\n const response = {\n msg: 'luigi.ux.alert.hide',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.ux.set-current-locale': (event: any) => {\n const response = {\n msg: 'luigi.current-locale-changed',\n currentLocale: event.data.data.currentLocale,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n // linkManager\n 'luigi.navigation.open': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.close': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.collapse': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n 'luigi.navigation.splitview.expand': (event: any) => {\n const response = {\n msg: 'luigi.navigate.ok',\n data: event.data,\n emulated: true\n };\n window.postMessage(response, '*');\n },\n // storage\n storage: () => {}\n }\n };\n\n // Listen to the global 'message' event of the window object\n window.addEventListener('message', (window as any).luigiMockEnvironment.msgListener);\n }\n };\n }\n\n /*\n * This method takes a data object of type 'any' and vizualizes a simple container\n * which holds data that is useful for e2e testing.\n */\n public static visualize(data: string): void {\n let luigiVisualizationContainer: Element | null = document.querySelector('#luigi-debug-vis-cnt');\n // Construct element structure if not already constructed\n if (!luigiVisualizationContainer) {\n luigiVisualizationContainer = document.createElement('div');\n luigiVisualizationContainer.setAttribute('id', 'luigi-debug-vis-cnt');\n // Hide the added DOM element to avoid interferring/overlapping with other elements during testing.\n luigiVisualizationContainer.setAttribute('style', 'display:none');\n document.body.appendChild(luigiVisualizationContainer);\n }\n const line: HTMLDivElement = document.createElement('div');\n line.textContent = data;\n luigiVisualizationContainer.appendChild(line);\n }\n}\n","/*\n * Public API Surface of client-support-angular\n */\n\nexport * from './lib/component/luigi.preload.component';\nexport * from './lib/luigi.angular.support.module';\nexport * from './lib/service/luigi-context-service';\nexport * from './lib/service/luigi-context.service.impl';\nexport * from './lib/service/luigi-auto-routing.service';\nexport * from './lib/luigi-mock/luigi-mock.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {LuigiRouteStrategy as ɵa} from './lib/route/luigi-route-strategy';"],"names":[],"mappings":";;;;;;;MAOa,qBAAqB;IAChC,iBAAgB;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C;;QAEjG,IAAI,CAAC,2BAA2B,EAAE;YAChC,2BAA2B,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;YAC5D,2BAA2B,CAAC,YAAY,CAAC,IAAI,EAAE,qBAAqB,CAAC,CAAC;;YAEtE,2BAA2B,CAAC,YAAY,CAAC,OAAO,EAAE,cAAc,CAAC,CAAC;YAClE,QAAQ,CAAC,IAAI,CAAC,WAAW,CAAC,2BAA2B,CAAC,CAAC;SACxD;QACD,MAAM,IAAI,GAAmB,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;QAC3D,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC;QACxB,2BAA2B,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;KAC/C;;;YAvKF,QAAQ,SAAC;gBACR,SAAS,EAAE;oBACT;wBACE,OAAO,EAAE,eAAe;wBACxB,UAAU,EAAE,eAAe,CAAC,mBAAmB;wBAC/C,KAAK,EAAE,IAAI;qBACZ;iBACF;aACF;;;ACXD;;;;ACAA;;;;;;"}
|
|
@@ -1,10 +1,12 @@
|
|
|
1
|
+
import { NgZone } from '@angular/core';
|
|
1
2
|
import { Observable } from 'rxjs';
|
|
2
3
|
import { Context } from '@luigi-project/client';
|
|
3
4
|
import { IContextMessage, ILuigiContextTypes, LuigiContextService } from './luigi-context-service';
|
|
4
5
|
export declare class LuigiContextServiceImpl implements LuigiContextService {
|
|
6
|
+
private zone;
|
|
5
7
|
private subject;
|
|
6
8
|
private currentContext;
|
|
7
|
-
constructor();
|
|
9
|
+
constructor(zone: NgZone);
|
|
8
10
|
contextObservable(): Observable<IContextMessage>;
|
|
9
11
|
/**
|
|
10
12
|
* Get latest context object retrieved from luigi core application or none, if not yet set.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"luigi-context.service.impl.d.ts","sourceRoot":"../../../../projects/client-support-angular/src/","sources":["lib/service/luigi-context.service.impl.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"luigi-context.service.impl.d.ts","sourceRoot":"../../../../projects/client-support-angular/src/","sources":["lib/service/luigi-context.service.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAc,MAAM,EAAE,MAAM,eAAe,CAAC;AACnD,OAAO,EAAiB,UAAU,EAAE,MAAM,MAAM,CAAC;AAEjD,OAAO,EAAE,OAAO,EAA6C,MAAM,uBAAuB,CAAC;AAC3F,OAAO,EAAE,eAAe,EAAE,kBAAkB,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAEnG,qBAGa,uBAAwB,YAAW,mBAAmB;IAIrD,OAAO,CAAC,IAAI;IAHxB,OAAO,CAAC,OAAO,CAAyE;IACxF,OAAO,CAAC,cAAc,CAAyD;gBAE3D,IAAI,EAAE,MAAM;IASzB,iBAAiB,IAAI,UAAU,CAAC,eAAe,CAAC;IAIvD;;OAEG;IACI,UAAU,IAAI,OAAO;IAI5B;;OAEG;IACI,eAAe,IAAI,OAAO,CAAC,OAAO,CAAC;IAc1C;;OAEG;IACH,SAAS,CAAC,UAAU,CAAC,GAAG,EAAE,eAAe,GAAG,IAAI;IAOhD,WAAW,CAAC,WAAW,EAAE,kBAAkB,EAAE,OAAO,EAAE,OAAO,GAAG,IAAI;CAMrE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"__symbolic":"module","version":4,"metadata":{"LuigiPreloadComponent":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component","line":2,"character":1},"arguments":[{"selector":"lib-client-support-angular","styles":[],"template":"<p luigipreload=\"luigipreload\"></p>\n"}]}],"members":{"__ctor__":[{"__symbolic":"constructor"}],"ngOnInit":[{"__symbolic":"method"}]}},"staticRoutes":[{"path":"luigi-client-support-preload","component":{"__symbolic":"reference","name":"LuigiPreloadComponent"},"data":{"fromVirtualTreeRoot":true}},{"path":"luigi-client-support-preload","component":{"__symbolic":"reference","name":"LuigiPreloadComponent"},"data":{"luigiRoute":"/home/reload"}},{"path":"luigi-client-support-preload=component","component":{"__symbolic":"reference","name":"LuigiPreloadComponent"},"data":{"reuse":true}}],"LuigiAngularSupportModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule","line":29,"character":1},"arguments":[{"declarations":[{"__symbolic":"reference","name":"LuigiPreloadComponent"}],"imports":[{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"@angular/router","name":"RouterModule","line":31,"character":12},"member":"forChild"},"arguments":[{"__symbolic":"reference","name":"staticRoutes"}]}],"providers":[{"provide":{"__symbolic":"reference","name":"LuigiContextService"},"useClass":{"__symbolic":"reference","name":"LuigiContextServiceImpl"}},{"provide":{"__symbolic":"reference","module":"@angular/router","name":"RouteReuseStrategy","line":38,"character":15},"useClass":{"__symbolic":"reference","name":"ɵa"}}],"exports":[{"__symbolic":"reference","name":"LuigiPreloadComponent"}]}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"LuigiAutoRoutingService"},{"__symbolic":"reference","name":"LuigiContextService"}]}]}},"LuigiContextService":{"__symbolic":"class","members":{"contextObservable":[{"__symbolic":"method"}],"getContext":[{"__symbolic":"method"}],"getContextAsync":[{"__symbolic":"method"}]}},"ILuigiContextTypes":{"INIT":0,"UPDATE":1},"IContextMessage":{"__symbolic":"interface"},"LuigiContextServiceImpl":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":
|
|
1
|
+
{"__symbolic":"module","version":4,"metadata":{"LuigiPreloadComponent":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component","line":2,"character":1},"arguments":[{"selector":"lib-client-support-angular","styles":[],"template":"<p luigipreload=\"luigipreload\"></p>\n"}]}],"members":{"__ctor__":[{"__symbolic":"constructor"}],"ngOnInit":[{"__symbolic":"method"}]}},"staticRoutes":[{"path":"luigi-client-support-preload","component":{"__symbolic":"reference","name":"LuigiPreloadComponent"},"data":{"fromVirtualTreeRoot":true}},{"path":"luigi-client-support-preload","component":{"__symbolic":"reference","name":"LuigiPreloadComponent"},"data":{"luigiRoute":"/home/reload"}},{"path":"luigi-client-support-preload=component","component":{"__symbolic":"reference","name":"LuigiPreloadComponent"},"data":{"reuse":true}}],"LuigiAngularSupportModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule","line":29,"character":1},"arguments":[{"declarations":[{"__symbolic":"reference","name":"LuigiPreloadComponent"}],"imports":[{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"@angular/router","name":"RouterModule","line":31,"character":12},"member":"forChild"},"arguments":[{"__symbolic":"reference","name":"staticRoutes"}]}],"providers":[{"provide":{"__symbolic":"reference","name":"LuigiContextService"},"useClass":{"__symbolic":"reference","name":"LuigiContextServiceImpl"}},{"provide":{"__symbolic":"reference","module":"@angular/router","name":"RouteReuseStrategy","line":38,"character":15},"useClass":{"__symbolic":"reference","name":"ɵa"}}],"exports":[{"__symbolic":"reference","name":"LuigiPreloadComponent"}]}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"LuigiAutoRoutingService"},{"__symbolic":"reference","name":"LuigiContextService"}]}]}},"LuigiContextService":{"__symbolic":"class","members":{"contextObservable":[{"__symbolic":"method"}],"getContext":[{"__symbolic":"method"}],"getContextAsync":[{"__symbolic":"method"}]}},"ILuigiContextTypes":{"INIT":0,"UPDATE":1},"IContextMessage":{"__symbolic":"interface"},"LuigiContextServiceImpl":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":6,"character":1},"arguments":[{"providedIn":"root"}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"NgZone","line":13,"character":28}]}],"contextObservable":[{"__symbolic":"method"}],"getContext":[{"__symbolic":"method"}],"getContextAsync":[{"__symbolic":"method"}],"setContext":[{"__symbolic":"method"}],"addListener":[{"__symbolic":"method"}]},"statics":{"ɵprov":{}}},"LuigiAutoRoutingService":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":15,"character":1},"arguments":[{"providedIn":"root"}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/router","name":"Router","line":22,"character":20},{"__symbolic":"reference","name":"LuigiContextService"}]}],"doFilter":[{"__symbolic":"method"}],"doSubscription":[{"__symbolic":"method"}],"ngOnDestroy":[{"__symbolic":"method"}]},"statics":{"ɵprov":{}}},"LuigiMockModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule","line":3,"character":1},"arguments":[{"providers":[{"provide":{"__symbolic":"reference","module":"@angular/core","name":"APP_INITIALIZER","line":6,"character":15},"useFactory":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"LuigiMockModule"},"member":"initPostMessageHook"},"multi":true}]}]}],"members":{},"statics":{"initPostMessageHook":{"__symbolic":"function","parameters":[],"value":{"__symbolic":"error","message":"Lambda not supported","line":28,"character":11,"module":"./lib/luigi-mock/luigi-mock.module"}}}},"ɵa":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"@angular/router","name":"BaseRouteReuseStrategy","line":4,"character":40},"members":{"retrieve":[{"__symbolic":"method"}]}}},"origins":{"LuigiPreloadComponent":"./lib/component/luigi.preload.component","staticRoutes":"./lib/luigi.angular.support.module","LuigiAngularSupportModule":"./lib/luigi.angular.support.module","LuigiContextService":"./lib/service/luigi-context-service","ILuigiContextTypes":"./lib/service/luigi-context-service","IContextMessage":"./lib/service/luigi-context-service","LuigiContextServiceImpl":"./lib/service/luigi-context.service.impl","LuigiAutoRoutingService":"./lib/service/luigi-auto-routing.service","LuigiMockModule":"./lib/luigi-mock/luigi-mock.module","ɵa":"./lib/route/luigi-route-strategy"},"importAs":"@luigi-project/client-support-angular"}
|
package/package.json
CHANGED
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"publishConfig": {
|
|
18
18
|
"tag": "client-support-angular"
|
|
19
19
|
},
|
|
20
|
-
"version": "1.
|
|
20
|
+
"version": "1.20.0",
|
|
21
21
|
"main": "bundles/luigi-project-client-support-angular.umd.js",
|
|
22
22
|
"module": "fesm2015/luigi-project-client-support-angular.js",
|
|
23
23
|
"es2015": "fesm2015/luigi-project-client-support-angular.js",
|
|
@@ -26,4 +26,4 @@
|
|
|
26
26
|
"typings": "luigi-project-client-support-angular.d.ts",
|
|
27
27
|
"metadata": "luigi-project-client-support-angular.metadata.json",
|
|
28
28
|
"sideEffects": false
|
|
29
|
-
}
|
|
29
|
+
}
|