quankee-framework-common-ts 1.0.1 → 1.3.2
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/.angular/cache/19.2.15/ng-packagr/4d54d937dc0fb0c6f29a333038ccf08c7481d9a9c9842c3c69d60b448a8fcd48 +1 -0
- package/.angular/cache/19.2.15/ng-packagr/4ec9d7c95b688865fdda7559138c701cd4f3b51c24f3fc2679687ee4e8d6f807 +1 -0
- package/.angular/cache/19.2.15/ng-packagr/8dc2d5a35f40f993f8e8f007e3ec70ea61d38a9543aaf987838096a6461cfa75 +1 -0
- package/.angular/cache/19.2.15/ng-packagr/b1851331ce1d33cd48496fe17422276a2b380a319e716db97547784e4d9cc1a1 +1 -0
- package/.angular/cache/19.2.15/ng-packagr/bafae0f01f0cf8807646a7eb9e3b6bd5a1edd0fd3752c9f8c93ba0b66b824928 +1 -0
- package/.angular/cache/19.2.15/ng-packagr/df9030ba5c4a68a5dd0cb41b53506348a54f8da563888061b23946418e6eb5c4 +1 -0
- package/.editorconfig +17 -17
- package/.gitlab-ci.yml +3 -3
- package/LICENSE +15 -15
- package/README.md +42 -42
- package/angular.json +109 -109
- package/package.json +59 -57
- package/projects/quankee-framework-keycloak/LICENSE +15 -0
- package/projects/quankee-framework-keycloak/ng-package.json +6 -6
- package/projects/quankee-framework-keycloak/package-lock.json +37 -0
- package/projects/quankee-framework-keycloak/package.json +26 -2
- package/projects/quankee-framework-language/ng-package.json +6 -6
- package/projects/quankee-framework-language/package.json +22 -1
- package/projects/quankee-framework-response/ng-package.json +6 -6
- package/projects/quankee-framework-response/package.json +22 -1
- package/publish-all.js +11 -0
- package/sync-versions.js +26 -26
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"hash":"697369bc375ac8ba965ca6f6e0ff8379e39ed9e9463c8f65f67e8ba6c5719222","fesm2022":[{"exports":["KeycloakService"],"facadeModuleId":"C:\\usr\\local\\workspaces\\workspace-quankee\\quankee-framework\\quankee-framework-common-ts\\dist\\quankee-framework-keycloak\\esm2022\\quankee-framework-keycloak.mjs","isDynamicEntry":false,"isEntry":true,"isImplicitEntry":false,"moduleIds":["C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/keycloak-token.mjs","C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/authenticated-user.mjs","C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/keycloak.service.mjs","C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/public-api.mjs","C:\\usr\\local\\workspaces\\workspace-quankee\\quankee-framework\\quankee-framework-common-ts\\dist\\quankee-framework-keycloak\\esm2022\\quankee-framework-keycloak.mjs"],"name":"quankee-framework-keycloak","type":"chunk","dynamicImports":[],"fileName":"quankee-framework-keycloak.mjs","implicitlyLoadedBefore":[],"importedBindings":{"@angular/core":["*","Injectable"],"keycloak-js":["default"]},"imports":["@angular/core","keycloak-js"],"modules":{"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/keycloak-token.mjs":{"code":"","originalLength":1017,"removedExports":[],"renderedExports":[],"renderedLength":0},"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/authenticated-user.mjs":{"code":"","originalLength":649,"removedExports":[],"renderedExports":[],"renderedLength":0},"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/keycloak.service.mjs":{"code":"class KeycloakService {\n keycloak;\n initialized = false;\n constructor() { }\n async init(config) {\n this.keycloak = new Keycloak({\n url: config.url,\n realm: config.realm,\n clientId: config.clientId,\n });\n const initOptions = {\n onLoad: config.onLoad ?? \"login-required\",\n checkLoginIframe: config.checkLoginIframe ?? false,\n silentCheckSsoRedirectUri: config.silentCheckSsoRedirectUri,\n pkceMethod: config.pkceMethod ?? \"S256\",\n flow: config.flow ?? \"standard\",\n };\n try {\n const authenticated = await this.keycloak.init(initOptions);\n this.initialized = true;\n return authenticated;\n }\n catch (error) {\n console.error(\"Keycloak initialization failed\", error);\n return false;\n }\n }\n login() {\n this.keycloak?.login();\n }\n logout(redirectUri) {\n this.keycloak?.logout({ redirectUri });\n }\n accountManagement() {\n this.keycloak?.accountManagement();\n }\n getToken() {\n return this.keycloak?.token;\n }\n getParsedToken() {\n return this.keycloak?.tokenParsed;\n }\n async refreshToken(minValidity = 5) {\n if (!this.keycloak)\n return false;\n try {\n return await this.keycloak.updateToken(minValidity);\n }\n catch (e) {\n console.error(\"Token refresh failed\", e);\n return false;\n }\n }\n getUsername() {\n return this.getParsedToken()?.preferred_username;\n }\n isLoggedIn() {\n return !!this.keycloak?.authenticated;\n }\n async getUser() {\n if (!this.keycloak?.token || !this.keycloak.tokenParsed)\n return;\n const profile = await this.keycloak.loadUserProfile();\n return {\n token: this.keycloak.token,\n parsedToken: this.keycloak.tokenParsed,\n profile,\n };\n }\n getKeycloak() {\n return this.keycloak;\n }\n static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"19.2.14\", ngImport: i0, type: KeycloakService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });\n static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: \"12.0.0\", version: \"19.2.14\", ngImport: i0, type: KeycloakService, providedIn: 'root' });\n}\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"19.2.14\", ngImport: i0, type: KeycloakService, decorators: [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n }]\n }], ctorParameters: () => [] });","originalLength":10325,"removedExports":[],"renderedExports":["KeycloakService"],"renderedLength":2662},"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/public-api.mjs":{"code":"/*\n * Public API Surface of quankee-framework-keycloak\n */","originalLength":876,"removedExports":[],"renderedExports":[],"renderedLength":58},"C:\\usr\\local\\workspaces\\workspace-quankee\\quankee-framework\\quankee-framework-common-ts\\dist\\quankee-framework-keycloak\\esm2022\\quankee-framework-keycloak.mjs":{"code":"/**\n * Generated bundle index. Do not edit.\n */","originalLength":560,"removedExports":[],"renderedExports":[],"renderedLength":47}},"referencedFiles":[],"code":"import * as i0 from '@angular/core';\nimport { Injectable } from '@angular/core';\nimport Keycloak from 'keycloak-js';\n\nclass KeycloakService {\n keycloak;\n initialized = false;\n constructor() { }\n async init(config) {\n this.keycloak = new Keycloak({\n url: config.url,\n realm: config.realm,\n clientId: config.clientId,\n });\n const initOptions = {\n onLoad: config.onLoad ?? \"login-required\",\n checkLoginIframe: config.checkLoginIframe ?? false,\n silentCheckSsoRedirectUri: config.silentCheckSsoRedirectUri,\n pkceMethod: config.pkceMethod ?? \"S256\",\n flow: config.flow ?? \"standard\",\n };\n try {\n const authenticated = await this.keycloak.init(initOptions);\n this.initialized = true;\n return authenticated;\n }\n catch (error) {\n console.error(\"Keycloak initialization failed\", error);\n return false;\n }\n }\n login() {\n this.keycloak?.login();\n }\n logout(redirectUri) {\n this.keycloak?.logout({ redirectUri });\n }\n accountManagement() {\n this.keycloak?.accountManagement();\n }\n getToken() {\n return this.keycloak?.token;\n }\n getParsedToken() {\n return this.keycloak?.tokenParsed;\n }\n async refreshToken(minValidity = 5) {\n if (!this.keycloak)\n return false;\n try {\n return await this.keycloak.updateToken(minValidity);\n }\n catch (e) {\n console.error(\"Token refresh failed\", e);\n return false;\n }\n }\n getUsername() {\n return this.getParsedToken()?.preferred_username;\n }\n isLoggedIn() {\n return !!this.keycloak?.authenticated;\n }\n async getUser() {\n if (!this.keycloak?.token || !this.keycloak.tokenParsed)\n return;\n const profile = await this.keycloak.loadUserProfile();\n return {\n token: this.keycloak.token,\n parsedToken: this.keycloak.tokenParsed,\n profile,\n };\n }\n getKeycloak() {\n return this.keycloak;\n }\n static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"19.2.14\", ngImport: i0, type: KeycloakService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });\n static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: \"12.0.0\", version: \"19.2.14\", ngImport: i0, type: KeycloakService, providedIn: 'root' });\n}\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"19.2.14\", ngImport: i0, type: KeycloakService, decorators: [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n }]\n }], ctorParameters: () => [] });\n\n/*\n * Public API Surface of quankee-framework-keycloak\n */\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { KeycloakService };\n//# sourceMappingURL=quankee-framework-keycloak.mjs.map\n","map":null,"preliminaryFileName":"quankee-framework-keycloak.mjs","sourcemapFileName":"quankee-framework-keycloak.mjs.map"},{"fileName":"quankee-framework-keycloak.mjs.map","names":[],"needsCodeReference":false,"originalFileName":null,"originalFileNames":[],"source":"{\"version\":3,\"file\":\"quankee-framework-keycloak.mjs\",\"sources\":[\"../../../projects/quankee-framework-keycloak/src/lib/core/keycloak.service.ts\",\"../../../projects/quankee-framework-keycloak/src/public-api.ts\",\"../../../projects/quankee-framework-keycloak/src/quankee-framework-keycloak.ts\"],\"sourcesContent\":[\"import {Injectable} from '@angular/core';\\r\\nimport Keycloak from 'keycloak-js';\\r\\nimport {AuthenticatedUser} from './authenticated-user';\\r\\nimport {KeycloakToken} from './keycloak-token';\\r\\n\\r\\n// Your own type definition for 'onLoad' because keycloak-js doesn't export it\\r\\nexport type AppKeycloakOnLoad = \\\"login-required\\\" | \\\"check-sso\\\";\\r\\n\\r\\nexport type KeycloakPkceMethod = \\\"S256\\\";\\r\\n\\r\\n// Your own config interface\\r\\nexport interface KeycloakConfig {\\r\\n url: string;\\r\\n realm: string;\\r\\n clientId: string;\\r\\n onLoad?: AppKeycloakOnLoad;\\r\\n checkLoginIframe?: boolean;\\r\\n silentCheckSsoRedirectUri?: string;\\r\\n pkceMethod?: KeycloakPkceMethod;\\r\\n flow?: \\\"standard\\\" | \\\"implicit\\\";\\r\\n}\\r\\n\\r\\n\\r\\n@Injectable({\\r\\n providedIn: 'root',\\r\\n})\\r\\nexport class KeycloakService{\\r\\n\\r\\n private keycloak?: Keycloak;\\r\\n\\r\\n private initialized = false;\\r\\n\\r\\n constructor() {}\\r\\n\\r\\n async init(config: KeycloakConfig): Promise<boolean> {\\r\\n this.keycloak = new Keycloak({\\r\\n url: config.url,\\r\\n realm: config.realm,\\r\\n clientId: config.clientId,\\r\\n });\\r\\n\\r\\n const initOptions: {\\r\\n onLoad: \\\"login-required\\\" | \\\"check-sso\\\";\\r\\n checkLoginIframe: boolean;\\r\\n silentCheckSsoRedirectUri?: string;\\r\\n pkceMethod: KeycloakPkceMethod;\\r\\n flow: \\\"standard\\\" | \\\"implicit\\\";\\r\\n } = {\\r\\n onLoad: config.onLoad ?? \\\"login-required\\\",\\r\\n checkLoginIframe: config.checkLoginIframe ?? false,\\r\\n silentCheckSsoRedirectUri: config.silentCheckSsoRedirectUri,\\r\\n pkceMethod: config.pkceMethod ?? \\\"S256\\\",\\r\\n flow: config.flow ?? \\\"standard\\\",\\r\\n };\\r\\n\\r\\n try {\\r\\n const authenticated = await this.keycloak.init(initOptions);\\r\\n this.initialized = true;\\r\\n return authenticated;\\r\\n } catch (error) {\\r\\n console.error(\\\"Keycloak initialization failed\\\", error);\\r\\n return false;\\r\\n }\\r\\n\\r\\n }\\r\\n\\r\\n login(): void {\\r\\n this.keycloak?.login();\\r\\n }\\r\\n\\r\\n logout(redirectUri?: string): void {\\r\\n this.keycloak?.logout({ redirectUri });\\r\\n }\\r\\n\\r\\n accountManagement(): void {\\r\\n this.keycloak?.accountManagement();\\r\\n }\\r\\n\\r\\n getToken(): string | undefined {\\r\\n return this.keycloak?.token;\\r\\n }\\r\\n\\r\\n getParsedToken(): KeycloakToken | undefined {\\r\\n return this.keycloak?.tokenParsed as KeycloakToken;\\r\\n }\\r\\n\\r\\n async refreshToken(minValidity = 5): Promise<boolean> {\\r\\n if (!this.keycloak) return false;\\r\\n try {\\r\\n return await this.keycloak.updateToken(minValidity);\\r\\n } catch (e) {\\r\\n console.error(\\\"Token refresh failed\\\", e);\\r\\n return false;\\r\\n }\\r\\n }\\r\\n\\r\\n getUsername(): string | undefined {\\r\\n return this.getParsedToken()?.preferred_username;\\r\\n }\\r\\n\\r\\n isLoggedIn(): boolean {\\r\\n return !!this.keycloak?.authenticated;\\r\\n }\\r\\n\\r\\n async getUser(): Promise<AuthenticatedUser | undefined> {\\r\\n if (!this.keycloak?.token || !this.keycloak.tokenParsed) return;\\r\\n\\r\\n const profile = await this.keycloak.loadUserProfile();\\r\\n return {\\r\\n token: this.keycloak.token,\\r\\n parsedToken: this.keycloak.tokenParsed as KeycloakToken,\\r\\n profile,\\r\\n };\\r\\n }\\r\\n\\r\\n getKeycloak(): Keycloak | undefined {\\r\\n return this.keycloak;\\r\\n }\\r\\n\\r\\n\\r\\n}\\r\\n\",\"/*\\r\\n * Public API Surface of quankee-framework-keycloak\\r\\n */\\r\\n\\r\\nexport * from './lib/core/keycloak-token';\\r\\nexport * from './lib/core/authenticated-user';\\r\\nexport * from './lib/core/keycloak.service';\\r\\n\\r\\n\",\"/**\\n * Generated bundle index. Do not edit.\\n */\\n\\nexport * from './public-api';\\n\"],\"names\":[],\"mappings\":\";;;;MA0Ba,eAAe,CAAA;AAEjB,IAAA,QAAQ;IAET,WAAW,GAAG,KAAK;AAE3B,IAAA,WAAA,GAAA;IAEA,MAAM,IAAI,CAAC,MAAsB,EAAA;AAC/B,QAAA,IAAI,CAAC,QAAQ,GAAG,IAAI,QAAQ,CAAC;YAC3B,GAAG,EAAE,MAAM,CAAC,GAAG;YACf,KAAK,EAAE,MAAM,CAAC,KAAK;YACnB,QAAQ,EAAE,MAAM,CAAC,QAAQ;AAC1B,SAAA,C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sBAAsB,EAAE,CAAC,CAAC;AACxC,YAAA,OAAO,KAAK;;;IAIhB,WAAW,GAAA;AACT,QAAA,OAAO,IAAI,CAAC,cAAc,EAAE,EAAE,kBAAkB;;IAGlD,UAAU,GAAA;AACR,QAAA,OAAO,CAAC,CAAC,IAAI,CAAC,QAAQ,EAAE,aAAa;;AAGvC,IAAA,MAAM,OAAO,GAAA;AACX,QAAA,IAAI,CAAC,IAAI,CAAC,QAAQ,EAAE,KAAK,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,WAAW;YAAE;QAEzD,MAAM,OAAO,GAAG,MAAM,IAAI,CAAC,QAAQ,CAAC,eAAe,EAAE;QACrD,OAAO;AACL,YAAA,KAAK,EAAE,IAAI,CAAC,QAAQ,CAAC,KAAK;AAC1B,YAAA,WAAW,EAAE,IAAI,CAAC,QAAQ,CAAC,WAA4B;YACvD,OAAO;SACR;;IAGH,WAAW,GAAA;QACT,OAAO,IAAI,CAAC,QAAQ;;wGA1FX,eAAe,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA;AAAf,IAAA,OAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,cAFd,MAAM,EAAA,CAAA;;4FAEP,eAAe,EAAA,UAAA,EAAA,CAAA;kBAH3B,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE,MAAM;AACnB,iBAAA;;;ACzBD;;AAEG;;ACFH;;AAEG;;;;\"}","type":"asset"}]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"hash":"9957767042121fac2c7778cdc7e9b0fe4af87177331d9e22238273e27c7de987","fesm2022":[{"exports":[],"facadeModuleId":"C:\\usr\\local\\workspaces\\workspace-quankee\\quankee-framework\\quankee-framework-common-ts\\dist\\quankee-framework-response\\esm2022\\quankee-framework-response.mjs","isDynamicEntry":false,"isEntry":true,"isImplicitEntry":false,"moduleIds":["C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-response/esm2022/lib/core/response.mjs","C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-response/esm2022/public-api.mjs","C:\\usr\\local\\workspaces\\workspace-quankee\\quankee-framework\\quankee-framework-common-ts\\dist\\quankee-framework-response\\esm2022\\quankee-framework-response.mjs"],"name":"quankee-framework-response","type":"chunk","dynamicImports":[],"fileName":"quankee-framework-response.mjs","implicitlyLoadedBefore":[],"importedBindings":{},"imports":[],"modules":{"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-response/esm2022/lib/core/response.mjs":{"code":"","originalLength":453,"removedExports":[],"renderedExports":[],"renderedLength":0},"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-response/esm2022/public-api.mjs":{"code":"/*\n * Public API Surface of quankee-framework-response\n */","originalLength":578,"removedExports":[],"renderedExports":[],"renderedLength":58},"C:\\usr\\local\\workspaces\\workspace-quankee\\quankee-framework\\quankee-framework-common-ts\\dist\\quankee-framework-response\\esm2022\\quankee-framework-response.mjs":{"code":"/**\n * Generated bundle index. Do not edit.\n */","originalLength":560,"removedExports":[],"renderedExports":[],"renderedLength":47}},"referencedFiles":[],"code":"/*\n * Public API Surface of quankee-framework-response\n */\n\n/**\n * Generated bundle index. Do not edit.\n */\n//# sourceMappingURL=quankee-framework-response.mjs.map\n","map":null,"preliminaryFileName":"quankee-framework-response.mjs","sourcemapFileName":"quankee-framework-response.mjs.map"},{"fileName":"quankee-framework-response.mjs.map","names":[],"needsCodeReference":false,"originalFileName":null,"originalFileNames":[],"source":"{\"version\":3,\"file\":\"quankee-framework-response.mjs\",\"sources\":[\"../../../projects/quankee-framework-response/src/public-api.ts\",\"../../../projects/quankee-framework-response/src/quankee-framework-response.ts\"],\"sourcesContent\":[\"/*\\r\\n * Public API Surface of quankee-framework-response\\r\\n */\\r\\n\\r\\nexport * from './lib/core/response';\\r\\n\\r\\n\",\"/**\\n * Generated bundle index. Do not edit.\\n */\\n\\nexport * from './public-api';\\n\"],\"names\":[],\"mappings\":\"AAAA;;AAEG;;ACFH;;AAEG\"}","type":"asset"}]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"modules":[{"ast":{"type":"Program","start":0,"end":421,"body":[{"type":"ExportNamedDeclaration","start":0,"end":10,"specifiers":[],"source":null,"attributes":[],"declaration":null}],"_rollupRemoved":[{"end":421,"start":11,"type":"sourcemap"}],"sourceType":"module"},"attributes":{},"code":"export {};\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibGFuZ3VhZ2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9xdWFua2VlLWZyYW1ld29yay1sYW5ndWFnZS9zcmMvbGliL2NvcmUvbGFuZ3VhZ2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCBpbnRlcmZhY2UgTGFuZ3VhZ2Uge1xyXG4gIGxhbmd1YWdlOiBzdHJpbmc7XHJcbiAgY291bnRyeTogc3RyaW5nO1xyXG59XHJcbiJdfQ==","customTransformCache":false,"dependencies":[],"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-language/esm2022/lib/core/language.mjs","meta":{},"moduleSideEffects":true,"originalCode":"export {};\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibGFuZ3VhZ2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9xdWFua2VlLWZyYW1ld29yay1sYW5ndWFnZS9zcmMvbGliL2NvcmUvbGFuZ3VhZ2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCBpbnRlcmZhY2UgTGFuZ3VhZ2Uge1xyXG4gIGxhbmd1YWdlOiBzdHJpbmc7XHJcbiAgY291bnRyeTogc3RyaW5nO1xyXG59XHJcbiJdfQ==","originalSourcemap":{"mappings":[],"names":[],"sources":[],"version":3},"resolvedIds":{},"sourcemapChain":[],"syntheticNamedExports":false,"transformDependencies":[]},{"ast":{"type":"Program","start":0,"end":574,"body":[{"type":"ExportAllDeclaration","start":59,"end":95,"exported":null,"source":{"type":"Literal","start":73,"end":94,"value":"./lib/core/language","raw":"'./lib/core/language'"},"attributes":[]}],"_rollupRemoved":[{"end":574,"start":96,"type":"sourcemap"}],"sourceType":"module"},"attributes":{},"code":"/*\n * Public API Surface of quankee-framework-language\n */\nexport * from './lib/core/language';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljLWFwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3Byb2plY3RzL3F1YW5rZWUtZnJhbWV3b3JrLWxhbmd1YWdlL3NyYy9wdWJsaWMtYXBpLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBRUgsY0FBYyxxQkFBcUIsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qXHJcbiAqIFB1YmxpYyBBUEkgU3VyZmFjZSBvZiBxdWFua2VlLWZyYW1ld29yay1sYW5ndWFnZVxyXG4gKi9cclxuXHJcbmV4cG9ydCAqIGZyb20gJy4vbGliL2NvcmUvbGFuZ3VhZ2UnO1xyXG4iXX0=","customTransformCache":false,"dependencies":["C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-language/esm2022/lib/core/language.mjs"],"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-language/esm2022/public-api.mjs","meta":{},"moduleSideEffects":true,"originalCode":"/*\n * Public API Surface of quankee-framework-language\n */\nexport * from './lib/core/language';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljLWFwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3Byb2plY3RzL3F1YW5rZWUtZnJhbWV3b3JrLWxhbmd1YWdlL3NyYy9wdWJsaWMtYXBpLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBRUgsY0FBYyxxQkFBcUIsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qXHJcbiAqIFB1YmxpYyBBUEkgU3VyZmFjZSBvZiBxdWFua2VlLWZyYW1ld29yay1sYW5ndWFnZVxyXG4gKi9cclxuXHJcbmV4cG9ydCAqIGZyb20gJy4vbGliL2NvcmUvbGFuZ3VhZ2UnO1xyXG4iXX0=","originalSourcemap":{"version":3,"file":"public-api.js","sourceRoot":"","sources":["../../../projects/quankee-framework-language/src/public-api.ts"],"names":[],"mappings":[[[0,0,0,0]],[],[[3,0,2,3]],[[0,0,4,0],[14,0,4,14],[35,0,4,35],[36,0,4,36]]],"sourcesContent":["/*\r\n * Public API Surface of quankee-framework-language\r\n */\r\n\r\nexport * from './lib/core/language';\r\n"]},"resolvedIds":{"./lib/core/language":{"attributes":{},"external":false,"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-language/esm2022/lib/core/language.mjs","meta":{},"moduleSideEffects":true,"resolvedBy":"file-loader","syntheticNamedExports":false}},"sourcemapChain":[],"syntheticNamedExports":false,"transformDependencies":[]},{"ast":{"type":"Program","start":0,"end":560,"body":[{"type":"ExportAllDeclaration","start":48,"end":77,"exported":null,"source":{"type":"Literal","start":62,"end":76,"value":"./public-api","raw":"'./public-api'"},"attributes":[]}],"_rollupRemoved":[{"end":560,"start":78,"type":"sourcemap"}],"sourceType":"module"},"attributes":{},"code":"/**\n * Generated bundle index. Do not edit.\n */\nexport * from './public-api';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicXVhbmtlZS1mcmFtZXdvcmstbGFuZ3VhZ2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9wcm9qZWN0cy9xdWFua2VlLWZyYW1ld29yay1sYW5ndWFnZS9zcmMvcXVhbmtlZS1mcmFtZXdvcmstbGFuZ3VhZ2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7O0dBRUc7QUFFSCxjQUFjLGNBQWMsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogR2VuZXJhdGVkIGJ1bmRsZSBpbmRleC4gRG8gbm90IGVkaXQuXG4gKi9cblxuZXhwb3J0ICogZnJvbSAnLi9wdWJsaWMtYXBpJztcbiJdfQ==","customTransformCache":false,"dependencies":["C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-language/esm2022/public-api.mjs"],"id":"C:\\usr\\local\\workspaces\\workspace-quankee\\quankee-framework\\quankee-framework-common-ts\\dist\\quankee-framework-language\\esm2022\\quankee-framework-language.mjs","meta":{},"moduleSideEffects":true,"originalCode":"/**\n * Generated bundle index. Do not edit.\n */\nexport * from './public-api';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicXVhbmtlZS1mcmFtZXdvcmstbGFuZ3VhZ2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9wcm9qZWN0cy9xdWFua2VlLWZyYW1ld29yay1sYW5ndWFnZS9zcmMvcXVhbmtlZS1mcmFtZXdvcmstbGFuZ3VhZ2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7O0dBRUc7QUFFSCxjQUFjLGNBQWMsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogR2VuZXJhdGVkIGJ1bmRsZSBpbmRleC4gRG8gbm90IGVkaXQuXG4gKi9cblxuZXhwb3J0ICogZnJvbSAnLi9wdWJsaWMtYXBpJztcbiJdfQ==","originalSourcemap":{"version":3,"file":"quankee-framework-language.js","sourceRoot":"","sources":["../../../projects/quankee-framework-language/src/quankee-framework-language.ts"],"names":[],"mappings":[[[0,0,0,0]],[],[[3,0,2,3]],[[0,0,4,0],[14,0,4,14],[28,0,4,28],[29,0,4,29]]],"sourcesContent":["/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"]},"resolvedIds":{"./public-api":{"attributes":{},"external":false,"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-language/esm2022/public-api.mjs","meta":{},"moduleSideEffects":true,"resolvedBy":"file-loader","syntheticNamedExports":false}},"sourcemapChain":[],"syntheticNamedExports":false,"transformDependencies":[]}],"plugins":{"file-loader":{},"json":{}}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"modules":[{"ast":{"type":"Program","start":0,"end":1017,"body":[{"type":"ExportNamedDeclaration","start":0,"end":10,"specifiers":[],"source":null,"attributes":[],"declaration":null}],"_rollupRemoved":[{"end":1017,"start":11,"type":"sourcemap"}],"sourceType":"module"},"attributes":{},"code":"export {};\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoia2V5Y2xvYWstdG9rZW4uanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9xdWFua2VlLWZyYW1ld29yay1rZXljbG9hay9zcmMvbGliL2NvcmUva2V5Y2xvYWstdG9rZW4udHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCBpbnRlcmZhY2UgS2V5Y2xvYWtUb2tlbiB7XHJcbiAgZXhwOiBudW1iZXI7XHJcbiAgaWF0OiBudW1iZXI7XHJcbiAganRpOiBzdHJpbmc7XHJcbiAgaXNzOiBzdHJpbmc7XHJcbiAgc3ViOiBzdHJpbmc7XHJcbiAgdHlwOiBzdHJpbmc7XHJcbiAgYXpwPzogc3RyaW5nO1xyXG4gIHNlc3Npb25fc3RhdGU/OiBzdHJpbmc7XHJcbiAgYWNyPzogc3RyaW5nO1xyXG4gIHJlYWxtX2FjY2Vzcz86IHtcclxuICAgIHJvbGVzOiBzdHJpbmdbXTtcclxuICB9O1xyXG4gIHJlc291cmNlX2FjY2Vzcz86IHtcclxuICAgIFtjbGllbnRJZDogc3RyaW5nXToge1xyXG4gICAgICByb2xlczogc3RyaW5nW107XHJcbiAgICB9O1xyXG4gIH07XHJcbiAgc2NvcGU/OiBzdHJpbmc7XHJcbiAgZW1haWw/OiBzdHJpbmc7XHJcbiAgcHJlZmVycmVkX3VzZXJuYW1lPzogc3RyaW5nO1xyXG4gIGdpdmVuX25hbWU/OiBzdHJpbmc7XHJcbiAgZmFtaWx5X25hbWU/OiBzdHJpbmc7XHJcbiAgbmFtZT86IHN0cmluZztcclxufVxyXG4iXX0=","customTransformCache":false,"dependencies":[],"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/keycloak-token.mjs","meta":{},"moduleSideEffects":true,"originalCode":"export {};\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoia2V5Y2xvYWstdG9rZW4uanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9xdWFua2VlLWZyYW1ld29yay1rZXljbG9hay9zcmMvbGliL2NvcmUva2V5Y2xvYWstdG9rZW4udHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCBpbnRlcmZhY2UgS2V5Y2xvYWtUb2tlbiB7XHJcbiAgZXhwOiBudW1iZXI7XHJcbiAgaWF0OiBudW1iZXI7XHJcbiAganRpOiBzdHJpbmc7XHJcbiAgaXNzOiBzdHJpbmc7XHJcbiAgc3ViOiBzdHJpbmc7XHJcbiAgdHlwOiBzdHJpbmc7XHJcbiAgYXpwPzogc3RyaW5nO1xyXG4gIHNlc3Npb25fc3RhdGU/OiBzdHJpbmc7XHJcbiAgYWNyPzogc3RyaW5nO1xyXG4gIHJlYWxtX2FjY2Vzcz86IHtcclxuICAgIHJvbGVzOiBzdHJpbmdbXTtcclxuICB9O1xyXG4gIHJlc291cmNlX2FjY2Vzcz86IHtcclxuICAgIFtjbGllbnRJZDogc3RyaW5nXToge1xyXG4gICAgICByb2xlczogc3RyaW5nW107XHJcbiAgICB9O1xyXG4gIH07XHJcbiAgc2NvcGU/OiBzdHJpbmc7XHJcbiAgZW1haWw/OiBzdHJpbmc7XHJcbiAgcHJlZmVycmVkX3VzZXJuYW1lPzogc3RyaW5nO1xyXG4gIGdpdmVuX25hbWU/OiBzdHJpbmc7XHJcbiAgZmFtaWx5X25hbWU/OiBzdHJpbmc7XHJcbiAgbmFtZT86IHN0cmluZztcclxufVxyXG4iXX0=","originalSourcemap":{"mappings":[],"names":[],"sources":[],"version":3},"resolvedIds":{},"sourcemapChain":[],"syntheticNamedExports":false,"transformDependencies":[]},{"ast":{"type":"Program","start":0,"end":649,"body":[{"type":"ExportNamedDeclaration","start":0,"end":10,"specifiers":[],"source":null,"attributes":[],"declaration":null}],"_rollupRemoved":[{"end":649,"start":11,"type":"sourcemap"}],"sourceType":"module"},"attributes":{},"code":"export {};\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXV0aGVudGljYXRlZC11c2VyLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvcXVhbmtlZS1mcmFtZXdvcmsta2V5Y2xvYWsvc3JjL2xpYi9jb3JlL2F1dGhlbnRpY2F0ZWQtdXNlci50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHtLZXljbG9ha1Rva2VufSBmcm9tICcuL2tleWNsb2FrLXRva2VuJztcclxuaW1wb3J0IEtleWNsb2FrIGZyb20gJ2tleWNsb2FrLWpzJztcclxuXHJcbmV4cG9ydCBpbnRlcmZhY2UgQXV0aGVudGljYXRlZFVzZXIge1xyXG4gIHRva2VuOiBzdHJpbmc7XHJcbiAgcGFyc2VkVG9rZW46IEtleWNsb2FrVG9rZW47XHJcbiAgcHJvZmlsZT86IEtleWNsb2FrLktleWNsb2FrUHJvZmlsZTtcclxufVxyXG4iXX0=","customTransformCache":false,"dependencies":[],"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/authenticated-user.mjs","meta":{},"moduleSideEffects":true,"originalCode":"export {};\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXV0aGVudGljYXRlZC11c2VyLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvcXVhbmtlZS1mcmFtZXdvcmsta2V5Y2xvYWsvc3JjL2xpYi9jb3JlL2F1dGhlbnRpY2F0ZWQtdXNlci50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHtLZXljbG9ha1Rva2VufSBmcm9tICcuL2tleWNsb2FrLXRva2VuJztcclxuaW1wb3J0IEtleWNsb2FrIGZyb20gJ2tleWNsb2FrLWpzJztcclxuXHJcbmV4cG9ydCBpbnRlcmZhY2UgQXV0aGVudGljYXRlZFVzZXIge1xyXG4gIHRva2VuOiBzdHJpbmc7XHJcbiAgcGFyc2VkVG9rZW46IEtleWNsb2FrVG9rZW47XHJcbiAgcHJvZmlsZT86IEtleWNsb2FrLktleWNsb2FrUHJvZmlsZTtcclxufVxyXG4iXX0=","originalSourcemap":{"mappings":[],"names":[],"sources":[],"version":3},"resolvedIds":{},"sourcemapChain":[],"syntheticNamedExports":false,"transformDependencies":[]},{"ast":{"type":"Program","start":0,"end":10325,"body":[{"type":"ImportDeclaration","start":0,"end":43,"specifiers":[{"type":"ImportSpecifier","start":9,"end":19,"imported":{"type":"Identifier","start":9,"end":19,"name":"Injectable"},"local":{"type":"Identifier","start":9,"end":19,"name":"Injectable"}}],"source":{"type":"Literal","start":27,"end":42,"value":"@angular/core","raw":"'@angular/core'"},"attributes":[]},{"type":"ImportDeclaration","start":44,"end":79,"specifiers":[{"type":"ImportDefaultSpecifier","start":51,"end":59,"local":{"type":"Identifier","start":51,"end":59,"name":"Keycloak"}}],"source":{"type":"Literal","start":65,"end":78,"value":"keycloak-js","raw":"'keycloak-js'"},"attributes":[]},{"type":"ImportDeclaration","start":80,"end":116,"specifiers":[{"type":"ImportNamespaceSpecifier","start":87,"end":94,"local":{"type":"Identifier","start":92,"end":94,"name":"i0"}}],"source":{"type":"Literal","start":100,"end":115,"value":"@angular/core","raw":"\"@angular/core\""},"attributes":[]},{"type":"ExportNamedDeclaration","start":117,"end":2511,"specifiers":[],"source":null,"attributes":[],"declaration":{"type":"ClassDeclaration","start":124,"end":2511,"decorators":[],"id":{"type":"Identifier","start":130,"end":145,"name":"KeycloakService"},"superClass":null,"body":{"type":"ClassBody","start":146,"end":2511,"body":[{"type":"PropertyDefinition","start":152,"end":161,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":152,"end":160,"name":"keycloak"},"value":null},{"type":"PropertyDefinition","start":166,"end":186,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":166,"end":177,"name":"initialized"},"value":{"type":"Literal","start":180,"end":185,"value":false,"raw":"false"}},{"type":"MethodDefinition","start":191,"end":208,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":191,"end":202,"name":"constructor"},"value":{"type":"FunctionExpression","start":202,"end":208,"async":false,"generator":false,"id":null,"params":[],"body":{"type":"BlockStatement","start":205,"end":208,"body":[]},"expression":false},"kind":"constructor"},{"type":"MethodDefinition","start":213,"end":1018,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":219,"end":223,"name":"init"},"value":{"type":"FunctionExpression","start":223,"end":1018,"async":true,"generator":false,"id":null,"params":[{"type":"Identifier","start":224,"end":230,"name":"config"}],"body":{"type":"BlockStatement","start":232,"end":1018,"body":[{"type":"ExpressionStatement","start":242,"end":385,"expression":{"type":"AssignmentExpression","start":242,"end":384,"operator":"=","left":{"type":"MemberExpression","start":242,"end":255,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":242,"end":246},"property":{"type":"Identifier","start":247,"end":255,"name":"keycloak"}},"right":{"type":"NewExpression","start":258,"end":384,"callee":{"type":"Identifier","start":262,"end":270,"name":"Keycloak"},"arguments":[{"type":"ObjectExpression","start":271,"end":383,"properties":[{"type":"Property","start":285,"end":300,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":285,"end":288,"name":"url"},"value":{"type":"MemberExpression","start":290,"end":300,"computed":false,"optional":false,"object":{"type":"Identifier","start":290,"end":296,"name":"config"},"property":{"type":"Identifier","start":297,"end":300,"name":"url"}},"kind":"init"},{"type":"Property","start":314,"end":333,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":314,"end":319,"name":"realm"},"value":{"type":"MemberExpression","start":321,"end":333,"computed":false,"optional":false,"object":{"type":"Identifier","start":321,"end":327,"name":"config"},"property":{"type":"Identifier","start":328,"end":333,"name":"realm"}},"kind":"init"},{"type":"Property","start":347,"end":372,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":347,"end":355,"name":"clientId"},"value":{"type":"MemberExpression","start":357,"end":372,"computed":false,"optional":false,"object":{"type":"Identifier","start":357,"end":363,"name":"config"},"property":{"type":"Identifier","start":364,"end":372,"name":"clientId"}},"kind":"init"}]}]}}},{"type":"VariableDeclaration","start":394,"end":716,"kind":"const","declarations":[{"type":"VariableDeclarator","start":400,"end":715,"id":{"type":"Identifier","start":400,"end":411,"name":"initOptions"},"init":{"type":"ObjectExpression","start":414,"end":715,"properties":[{"type":"Property","start":428,"end":469,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":428,"end":434,"name":"onLoad"},"value":{"type":"LogicalExpression","start":436,"end":469,"operator":"??","left":{"type":"MemberExpression","start":436,"end":449,"computed":false,"optional":false,"object":{"type":"Identifier","start":436,"end":442,"name":"config"},"property":{"type":"Identifier","start":443,"end":449,"name":"onLoad"}},"right":{"type":"Literal","start":453,"end":469,"value":"login-required","raw":"\"login-required\""}},"kind":"init"},{"type":"Property","start":483,"end":533,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":483,"end":499,"name":"checkLoginIframe"},"value":{"type":"LogicalExpression","start":501,"end":533,"operator":"??","left":{"type":"MemberExpression","start":501,"end":524,"computed":false,"optional":false,"object":{"type":"Identifier","start":501,"end":507,"name":"config"},"property":{"type":"Identifier","start":508,"end":524,"name":"checkLoginIframe"}},"right":{"type":"Literal","start":528,"end":533,"value":false,"raw":"false"}},"kind":"init"},{"type":"Property","start":547,"end":606,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":547,"end":572,"name":"silentCheckSsoRedirectUri"},"value":{"type":"MemberExpression","start":574,"end":606,"computed":false,"optional":false,"object":{"type":"Identifier","start":574,"end":580,"name":"config"},"property":{"type":"Identifier","start":581,"end":606,"name":"silentCheckSsoRedirectUri"}},"kind":"init"},{"type":"Property","start":620,"end":659,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":620,"end":630,"name":"pkceMethod"},"value":{"type":"LogicalExpression","start":632,"end":659,"operator":"??","left":{"type":"MemberExpression","start":632,"end":649,"computed":false,"optional":false,"object":{"type":"Identifier","start":632,"end":638,"name":"config"},"property":{"type":"Identifier","start":639,"end":649,"name":"pkceMethod"}},"right":{"type":"Literal","start":653,"end":659,"value":"S256","raw":"\"S256\""}},"kind":"init"},{"type":"Property","start":673,"end":704,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":673,"end":677,"name":"flow"},"value":{"type":"LogicalExpression","start":679,"end":704,"operator":"??","left":{"type":"MemberExpression","start":679,"end":690,"computed":false,"optional":false,"object":{"type":"Identifier","start":679,"end":685,"name":"config"},"property":{"type":"Identifier","start":686,"end":690,"name":"flow"}},"right":{"type":"Literal","start":694,"end":704,"value":"standard","raw":"\"standard\""}},"kind":"init"}]}}]},{"type":"TryStatement","start":725,"end":1012,"block":{"type":"BlockStatement","start":729,"end":884,"body":[{"type":"VariableDeclaration","start":743,"end":803,"kind":"const","declarations":[{"type":"VariableDeclarator","start":749,"end":802,"id":{"type":"Identifier","start":749,"end":762,"name":"authenticated"},"init":{"type":"AwaitExpression","start":765,"end":802,"argument":{"type":"CallExpression","start":771,"end":802,"optional":false,"callee":{"type":"MemberExpression","start":771,"end":789,"computed":false,"optional":false,"object":{"type":"MemberExpression","start":771,"end":784,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":771,"end":775},"property":{"type":"Identifier","start":776,"end":784,"name":"keycloak"}},"property":{"type":"Identifier","start":785,"end":789,"name":"init"}},"arguments":[{"type":"Identifier","start":790,"end":801,"name":"initOptions"}]}}}]},{"type":"ExpressionStatement","start":816,"end":840,"expression":{"type":"AssignmentExpression","start":816,"end":839,"operator":"=","left":{"type":"MemberExpression","start":816,"end":832,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":816,"end":820},"property":{"type":"Identifier","start":821,"end":832,"name":"initialized"}},"right":{"type":"Literal","start":835,"end":839,"value":true,"raw":"true"}}},{"type":"ReturnStatement","start":853,"end":874,"argument":{"type":"Identifier","start":860,"end":873,"name":"authenticated"}}]},"handler":{"type":"CatchClause","start":893,"end":1012,"param":{"type":"Identifier","start":900,"end":905,"name":"error"},"body":{"type":"BlockStatement","start":907,"end":1012,"body":[{"type":"ExpressionStatement","start":921,"end":976,"expression":{"type":"CallExpression","start":921,"end":975,"optional":false,"callee":{"type":"MemberExpression","start":921,"end":934,"computed":false,"optional":false,"object":{"type":"Identifier","start":921,"end":928,"name":"console"},"property":{"type":"Identifier","start":929,"end":934,"name":"error"}},"arguments":[{"type":"Literal","start":935,"end":967,"value":"Keycloak initialization failed","raw":"\"Keycloak initialization failed\""},{"type":"Identifier","start":969,"end":974,"name":"error"}]}},{"type":"ReturnStatement","start":989,"end":1002,"argument":{"type":"Literal","start":996,"end":1001,"value":false,"raw":"false"}}]}},"finalizer":null}]},"expression":false},"kind":"method"},{"type":"MethodDefinition","start":1023,"end":1070,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":1023,"end":1028,"name":"login"},"value":{"type":"FunctionExpression","start":1028,"end":1070,"async":false,"generator":false,"id":null,"params":[],"body":{"type":"BlockStatement","start":1031,"end":1070,"body":[{"type":"ExpressionStatement","start":1041,"end":1064,"expression":{"type":"ChainExpression","start":1041,"end":1063,"expression":{"type":"CallExpression","start":1041,"end":1063,"optional":false,"callee":{"type":"MemberExpression","start":1041,"end":1061,"computed":false,"optional":true,"object":{"type":"MemberExpression","start":1041,"end":1054,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":1041,"end":1045},"property":{"type":"Identifier","start":1046,"end":1054,"name":"keycloak"}},"property":{"type":"Identifier","start":1056,"end":1061,"name":"login"}},"arguments":[]}}}]},"expression":false},"kind":"method"},{"type":"MethodDefinition","start":1075,"end":1150,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":1075,"end":1081,"name":"logout"},"value":{"type":"FunctionExpression","start":1081,"end":1150,"async":false,"generator":false,"id":null,"params":[{"type":"Identifier","start":1082,"end":1093,"name":"redirectUri"}],"body":{"type":"BlockStatement","start":1095,"end":1150,"body":[{"type":"ExpressionStatement","start":1105,"end":1144,"expression":{"type":"ChainExpression","start":1105,"end":1143,"expression":{"type":"CallExpression","start":1105,"end":1143,"optional":false,"callee":{"type":"MemberExpression","start":1105,"end":1126,"computed":false,"optional":true,"object":{"type":"MemberExpression","start":1105,"end":1118,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":1105,"end":1109},"property":{"type":"Identifier","start":1110,"end":1118,"name":"keycloak"}},"property":{"type":"Identifier","start":1120,"end":1126,"name":"logout"}},"arguments":[{"type":"ObjectExpression","start":1127,"end":1142,"properties":[{"type":"Property","start":1129,"end":1140,"method":false,"shorthand":true,"computed":false,"key":{"type":"Identifier","start":1129,"end":1140,"name":"redirectUri"},"value":{"type":"Identifier","start":1129,"end":1140,"name":"redirectUri"},"kind":"init"}]}]}}}]},"expression":false},"kind":"method"},{"type":"MethodDefinition","start":1155,"end":1226,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":1155,"end":1172,"name":"accountManagement"},"value":{"type":"FunctionExpression","start":1172,"end":1226,"async":false,"generator":false,"id":null,"params":[],"body":{"type":"BlockStatement","start":1175,"end":1226,"body":[{"type":"ExpressionStatement","start":1185,"end":1220,"expression":{"type":"ChainExpression","start":1185,"end":1219,"expression":{"type":"CallExpression","start":1185,"end":1219,"optional":false,"callee":{"type":"MemberExpression","start":1185,"end":1217,"computed":false,"optional":true,"object":{"type":"MemberExpression","start":1185,"end":1198,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":1185,"end":1189},"property":{"type":"Identifier","start":1190,"end":1198,"name":"keycloak"}},"property":{"type":"Identifier","start":1200,"end":1217,"name":"accountManagement"}},"arguments":[]}}}]},"expression":false},"kind":"method"},{"type":"MethodDefinition","start":1231,"end":1286,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":1231,"end":1239,"name":"getToken"},"value":{"type":"FunctionExpression","start":1239,"end":1286,"async":false,"generator":false,"id":null,"params":[],"body":{"type":"BlockStatement","start":1242,"end":1286,"body":[{"type":"ReturnStatement","start":1252,"end":1280,"argument":{"type":"ChainExpression","start":1259,"end":1279,"expression":{"type":"MemberExpression","start":1259,"end":1279,"computed":false,"optional":true,"object":{"type":"MemberExpression","start":1259,"end":1272,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":1259,"end":1263},"property":{"type":"Identifier","start":1264,"end":1272,"name":"keycloak"}},"property":{"type":"Identifier","start":1274,"end":1279,"name":"token"}}}}]},"expression":false},"kind":"method"},{"type":"MethodDefinition","start":1291,"end":1358,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":1291,"end":1305,"name":"getParsedToken"},"value":{"type":"FunctionExpression","start":1305,"end":1358,"async":false,"generator":false,"id":null,"params":[],"body":{"type":"BlockStatement","start":1308,"end":1358,"body":[{"type":"ReturnStatement","start":1318,"end":1352,"argument":{"type":"ChainExpression","start":1325,"end":1351,"expression":{"type":"MemberExpression","start":1325,"end":1351,"computed":false,"optional":true,"object":{"type":"MemberExpression","start":1325,"end":1338,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":1325,"end":1329},"property":{"type":"Identifier","start":1330,"end":1338,"name":"keycloak"}},"property":{"type":"Identifier","start":1340,"end":1351,"name":"tokenParsed"}}}}]},"expression":false},"kind":"method"},{"type":"MethodDefinition","start":1363,"end":1659,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":1369,"end":1381,"name":"refreshToken"},"value":{"type":"FunctionExpression","start":1381,"end":1659,"async":true,"generator":false,"id":null,"params":[{"type":"AssignmentPattern","start":1382,"end":1397,"left":{"type":"Identifier","start":1382,"end":1393,"name":"minValidity"},"right":{"type":"Literal","start":1396,"end":1397,"raw":"5","value":5}}],"body":{"type":"BlockStatement","start":1399,"end":1659,"body":[{"type":"IfStatement","start":1409,"end":1454,"test":{"type":"UnaryExpression","start":1413,"end":1427,"operator":"!","argument":{"type":"MemberExpression","start":1414,"end":1427,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":1414,"end":1418},"property":{"type":"Identifier","start":1419,"end":1427,"name":"keycloak"}},"prefix":true},"consequent":{"type":"ReturnStatement","start":1441,"end":1454,"argument":{"type":"Literal","start":1448,"end":1453,"value":false,"raw":"false"}},"alternate":null},{"type":"TryStatement","start":1463,"end":1653,"block":{"type":"BlockStatement","start":1467,"end":1543,"body":[{"type":"ReturnStatement","start":1481,"end":1533,"argument":{"type":"AwaitExpression","start":1488,"end":1532,"argument":{"type":"CallExpression","start":1494,"end":1532,"optional":false,"callee":{"type":"MemberExpression","start":1494,"end":1519,"computed":false,"optional":false,"object":{"type":"MemberExpression","start":1494,"end":1507,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":1494,"end":1498},"property":{"type":"Identifier","start":1499,"end":1507,"name":"keycloak"}},"property":{"type":"Identifier","start":1508,"end":1519,"name":"updateToken"}},"arguments":[{"type":"Identifier","start":1520,"end":1531,"name":"minValidity"}]}}}]},"handler":{"type":"CatchClause","start":1552,"end":1653,"param":{"type":"Identifier","start":1559,"end":1560,"name":"e"},"body":{"type":"BlockStatement","start":1562,"end":1653,"body":[{"type":"ExpressionStatement","start":1576,"end":1617,"expression":{"type":"CallExpression","start":1576,"end":1616,"optional":false,"callee":{"type":"MemberExpression","start":1576,"end":1589,"computed":false,"optional":false,"object":{"type":"Identifier","start":1576,"end":1583,"name":"console"},"property":{"type":"Identifier","start":1584,"end":1589,"name":"error"}},"arguments":[{"type":"Literal","start":1590,"end":1612,"value":"Token refresh failed","raw":"\"Token refresh failed\""},{"type":"Identifier","start":1614,"end":1615,"name":"e"}]}},{"type":"ReturnStatement","start":1630,"end":1643,"argument":{"type":"Literal","start":1637,"end":1642,"value":false,"raw":"false"}}]}},"finalizer":null}]},"expression":false},"kind":"method"},{"type":"MethodDefinition","start":1664,"end":1743,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":1664,"end":1675,"name":"getUsername"},"value":{"type":"FunctionExpression","start":1675,"end":1743,"async":false,"generator":false,"id":null,"params":[],"body":{"type":"BlockStatement","start":1678,"end":1743,"body":[{"type":"ReturnStatement","start":1688,"end":1737,"argument":{"type":"ChainExpression","start":1695,"end":1736,"expression":{"type":"MemberExpression","start":1695,"end":1736,"computed":false,"optional":true,"object":{"type":"CallExpression","start":1695,"end":1716,"optional":false,"callee":{"type":"MemberExpression","start":1695,"end":1714,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":1695,"end":1699},"property":{"type":"Identifier","start":1700,"end":1714,"name":"getParsedToken"}},"arguments":[]},"property":{"type":"Identifier","start":1718,"end":1736,"name":"preferred_username"}}}}]},"expression":false},"kind":"method"},{"type":"MethodDefinition","start":1748,"end":1815,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":1748,"end":1758,"name":"isLoggedIn"},"value":{"type":"FunctionExpression","start":1758,"end":1815,"async":false,"generator":false,"id":null,"params":[],"body":{"type":"BlockStatement","start":1761,"end":1815,"body":[{"type":"ReturnStatement","start":1771,"end":1809,"argument":{"type":"UnaryExpression","start":1778,"end":1808,"operator":"!","argument":{"type":"UnaryExpression","start":1779,"end":1808,"operator":"!","argument":{"type":"ChainExpression","start":1780,"end":1808,"expression":{"type":"MemberExpression","start":1780,"end":1808,"computed":false,"optional":true,"object":{"type":"MemberExpression","start":1780,"end":1793,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":1780,"end":1784},"property":{"type":"Identifier","start":1785,"end":1793,"name":"keycloak"}},"property":{"type":"Identifier","start":1795,"end":1808,"name":"authenticated"}}},"prefix":true},"prefix":true}}]},"expression":false},"kind":"method"},{"type":"MethodDefinition","start":1820,"end":2132,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":1826,"end":1833,"name":"getUser"},"value":{"type":"FunctionExpression","start":1833,"end":2132,"async":true,"generator":false,"id":null,"params":[],"body":{"type":"BlockStatement","start":1836,"end":2132,"body":[{"type":"IfStatement","start":1846,"end":1922,"test":{"type":"LogicalExpression","start":1850,"end":1901,"operator":"||","left":{"type":"UnaryExpression","start":1850,"end":1871,"operator":"!","argument":{"type":"ChainExpression","start":1851,"end":1871,"expression":{"type":"MemberExpression","start":1851,"end":1871,"computed":false,"optional":true,"object":{"type":"MemberExpression","start":1851,"end":1864,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":1851,"end":1855},"property":{"type":"Identifier","start":1856,"end":1864,"name":"keycloak"}},"property":{"type":"Identifier","start":1866,"end":1871,"name":"token"}}},"prefix":true},"right":{"type":"UnaryExpression","start":1875,"end":1901,"operator":"!","argument":{"type":"MemberExpression","start":1876,"end":1901,"computed":false,"optional":false,"object":{"type":"MemberExpression","start":1876,"end":1889,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":1876,"end":1880},"property":{"type":"Identifier","start":1881,"end":1889,"name":"keycloak"}},"property":{"type":"Identifier","start":1890,"end":1901,"name":"tokenParsed"}},"prefix":true}},"consequent":{"type":"ReturnStatement","start":1915,"end":1922,"argument":null},"alternate":null},{"type":"VariableDeclaration","start":1931,"end":1985,"kind":"const","declarations":[{"type":"VariableDeclarator","start":1937,"end":1984,"id":{"type":"Identifier","start":1937,"end":1944,"name":"profile"},"init":{"type":"AwaitExpression","start":1947,"end":1984,"argument":{"type":"CallExpression","start":1953,"end":1984,"optional":false,"callee":{"type":"MemberExpression","start":1953,"end":1982,"computed":false,"optional":false,"object":{"type":"MemberExpression","start":1953,"end":1966,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":1953,"end":1957},"property":{"type":"Identifier","start":1958,"end":1966,"name":"keycloak"}},"property":{"type":"Identifier","start":1967,"end":1982,"name":"loadUserProfile"}},"arguments":[]}}}]},{"type":"ReturnStatement","start":1994,"end":2126,"argument":{"type":"ObjectExpression","start":2001,"end":2125,"properties":[{"type":"Property","start":2015,"end":2041,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2015,"end":2020,"name":"token"},"value":{"type":"MemberExpression","start":2022,"end":2041,"computed":false,"optional":false,"object":{"type":"MemberExpression","start":2022,"end":2035,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":2022,"end":2026},"property":{"type":"Identifier","start":2027,"end":2035,"name":"keycloak"}},"property":{"type":"Identifier","start":2036,"end":2041,"name":"token"}},"kind":"init"},{"type":"Property","start":2055,"end":2093,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2055,"end":2066,"name":"parsedToken"},"value":{"type":"MemberExpression","start":2068,"end":2093,"computed":false,"optional":false,"object":{"type":"MemberExpression","start":2068,"end":2081,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":2068,"end":2072},"property":{"type":"Identifier","start":2073,"end":2081,"name":"keycloak"}},"property":{"type":"Identifier","start":2082,"end":2093,"name":"tokenParsed"}},"kind":"init"},{"type":"Property","start":2107,"end":2114,"method":false,"shorthand":true,"computed":false,"key":{"type":"Identifier","start":2107,"end":2114,"name":"profile"},"value":{"type":"Identifier","start":2107,"end":2114,"name":"profile"},"kind":"init"}]}}]},"expression":false},"kind":"method"},{"type":"MethodDefinition","start":2137,"end":2188,"static":false,"computed":false,"decorators":[],"key":{"type":"Identifier","start":2137,"end":2148,"name":"getKeycloak"},"value":{"type":"FunctionExpression","start":2148,"end":2188,"async":false,"generator":false,"id":null,"params":[],"body":{"type":"BlockStatement","start":2151,"end":2188,"body":[{"type":"ReturnStatement","start":2161,"end":2182,"argument":{"type":"MemberExpression","start":2168,"end":2181,"computed":false,"optional":false,"object":{"type":"ThisExpression","start":2168,"end":2172},"property":{"type":"Identifier","start":2173,"end":2181,"name":"keycloak"}}}]},"expression":false},"kind":"method"},{"type":"PropertyDefinition","start":2193,"end":2361,"static":true,"computed":false,"decorators":[],"key":{"type":"Identifier","start":2200,"end":2204,"name":"ɵfac"},"value":{"type":"CallExpression","start":2207,"end":2360,"optional":false,"callee":{"type":"MemberExpression","start":2207,"end":2228,"computed":false,"optional":false,"object":{"type":"Identifier","start":2207,"end":2209,"name":"i0"},"property":{"type":"Identifier","start":2210,"end":2228,"name":"ɵɵngDeclareFactory"}},"arguments":[{"type":"ObjectExpression","start":2229,"end":2359,"properties":[{"type":"Property","start":2231,"end":2251,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2231,"end":2241,"name":"minVersion"},"value":{"type":"Literal","start":2243,"end":2251,"value":"12.0.0","raw":"\"12.0.0\""},"kind":"init"},{"type":"Property","start":2253,"end":2271,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2253,"end":2260,"name":"version"},"value":{"type":"Literal","start":2262,"end":2271,"value":"19.2.14","raw":"\"19.2.14\""},"kind":"init"},{"type":"Property","start":2273,"end":2285,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2273,"end":2281,"name":"ngImport"},"value":{"type":"Identifier","start":2283,"end":2285,"name":"i0"},"kind":"init"},{"type":"Property","start":2287,"end":2308,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2287,"end":2291,"name":"type"},"value":{"type":"Identifier","start":2293,"end":2308,"name":"KeycloakService"},"kind":"init"},{"type":"Property","start":2310,"end":2318,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2310,"end":2314,"name":"deps"},"value":{"type":"ArrayExpression","start":2316,"end":2318,"elements":[]},"kind":"init"},{"type":"Property","start":2320,"end":2357,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2320,"end":2326,"name":"target"},"value":{"type":"MemberExpression","start":2328,"end":2357,"computed":false,"optional":false,"object":{"type":"MemberExpression","start":2328,"end":2346,"computed":false,"optional":false,"object":{"type":"Identifier","start":2328,"end":2330,"name":"i0"},"property":{"type":"Identifier","start":2331,"end":2346,"name":"ɵɵFactoryTarget"}},"property":{"type":"Identifier","start":2347,"end":2357,"name":"Injectable"}},"kind":"init"}]}]}},{"type":"PropertyDefinition","start":2366,"end":2509,"static":true,"computed":false,"decorators":[],"key":{"type":"Identifier","start":2373,"end":2378,"name":"ɵprov"},"value":{"type":"CallExpression","start":2381,"end":2508,"optional":false,"callee":{"type":"MemberExpression","start":2381,"end":2405,"computed":false,"optional":false,"object":{"type":"Identifier","start":2381,"end":2383,"name":"i0"},"property":{"type":"Identifier","start":2384,"end":2405,"name":"ɵɵngDeclareInjectable"}},"arguments":[{"type":"ObjectExpression","start":2406,"end":2507,"properties":[{"type":"Property","start":2408,"end":2428,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2408,"end":2418,"name":"minVersion"},"value":{"type":"Literal","start":2420,"end":2428,"value":"12.0.0","raw":"\"12.0.0\""},"kind":"init"},{"type":"Property","start":2430,"end":2448,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2430,"end":2437,"name":"version"},"value":{"type":"Literal","start":2439,"end":2448,"value":"19.2.14","raw":"\"19.2.14\""},"kind":"init"},{"type":"Property","start":2450,"end":2462,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2450,"end":2458,"name":"ngImport"},"value":{"type":"Identifier","start":2460,"end":2462,"name":"i0"},"kind":"init"},{"type":"Property","start":2464,"end":2485,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2464,"end":2468,"name":"type"},"value":{"type":"Identifier","start":2470,"end":2485,"name":"KeycloakService"},"kind":"init"},{"type":"Property","start":2487,"end":2505,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2487,"end":2497,"name":"providedIn"},"value":{"type":"Literal","start":2499,"end":2505,"value":"root","raw":"'root'"},"kind":"init"}]}]}}]}}},{"type":"ExpressionStatement","start":2512,"end":2786,"expression":{"type":"CallExpression","start":2512,"end":2785,"optional":false,"callee":{"type":"MemberExpression","start":2512,"end":2539,"computed":false,"optional":false,"object":{"type":"Identifier","start":2512,"end":2514,"name":"i0"},"property":{"type":"Identifier","start":2515,"end":2539,"name":"ɵɵngDeclareClassMetadata"}},"arguments":[{"type":"ObjectExpression","start":2540,"end":2784,"properties":[{"type":"Property","start":2542,"end":2562,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2542,"end":2552,"name":"minVersion"},"value":{"type":"Literal","start":2554,"end":2562,"value":"12.0.0","raw":"\"12.0.0\""},"kind":"init"},{"type":"Property","start":2564,"end":2582,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2564,"end":2571,"name":"version"},"value":{"type":"Literal","start":2573,"end":2582,"value":"19.2.14","raw":"\"19.2.14\""},"kind":"init"},{"type":"Property","start":2584,"end":2596,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2584,"end":2592,"name":"ngImport"},"value":{"type":"Identifier","start":2594,"end":2596,"name":"i0"},"kind":"init"},{"type":"Property","start":2598,"end":2619,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2598,"end":2602,"name":"type"},"value":{"type":"Identifier","start":2604,"end":2619,"name":"KeycloakService"},"kind":"init"},{"type":"Property","start":2621,"end":2756,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2621,"end":2631,"name":"decorators"},"value":{"type":"ArrayExpression","start":2633,"end":2756,"elements":[{"type":"ObjectExpression","start":2634,"end":2755,"properties":[{"type":"Property","start":2648,"end":2664,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2648,"end":2652,"name":"type"},"value":{"type":"Identifier","start":2654,"end":2664,"name":"Injectable"},"kind":"init"},{"type":"Property","start":2678,"end":2745,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2678,"end":2682,"name":"args"},"value":{"type":"ArrayExpression","start":2684,"end":2745,"elements":[{"type":"ObjectExpression","start":2685,"end":2744,"properties":[{"type":"Property","start":2707,"end":2725,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2707,"end":2717,"name":"providedIn"},"value":{"type":"Literal","start":2719,"end":2725,"value":"root","raw":"'root'"},"kind":"init"}]}]},"kind":"init"}]}]},"kind":"init"},{"type":"Property","start":2758,"end":2782,"method":false,"shorthand":false,"computed":false,"key":{"type":"Identifier","start":2758,"end":2772,"name":"ctorParameters"},"value":{"type":"ArrowFunctionExpression","start":2774,"end":2782,"async":false,"expression":true,"generator":false,"params":[],"body":{"type":"ArrayExpression","start":2780,"end":2782,"elements":[]},"id":null},"kind":"init"}]}]}}],"_rollupRemoved":[{"end":10325,"start":2787,"type":"sourcemap"}],"sourceType":"module"},"attributes":{},"code":"import { Injectable } from '@angular/core';\nimport Keycloak from 'keycloak-js';\nimport * as i0 from \"@angular/core\";\nexport class KeycloakService {\n keycloak;\n initialized = false;\n constructor() { }\n async init(config) {\n this.keycloak = new Keycloak({\n url: config.url,\n realm: config.realm,\n clientId: config.clientId,\n });\n const initOptions = {\n onLoad: config.onLoad ?? \"login-required\",\n checkLoginIframe: config.checkLoginIframe ?? false,\n silentCheckSsoRedirectUri: config.silentCheckSsoRedirectUri,\n pkceMethod: config.pkceMethod ?? \"S256\",\n flow: config.flow ?? \"standard\",\n };\n try {\n const authenticated = await this.keycloak.init(initOptions);\n this.initialized = true;\n return authenticated;\n }\n catch (error) {\n console.error(\"Keycloak initialization failed\", error);\n return false;\n }\n }\n login() {\n this.keycloak?.login();\n }\n logout(redirectUri) {\n this.keycloak?.logout({ redirectUri });\n }\n accountManagement() {\n this.keycloak?.accountManagement();\n }\n getToken() {\n return this.keycloak?.token;\n }\n getParsedToken() {\n return this.keycloak?.tokenParsed;\n }\n async refreshToken(minValidity = 5) {\n if (!this.keycloak)\n return false;\n try {\n return await this.keycloak.updateToken(minValidity);\n }\n catch (e) {\n console.error(\"Token refresh failed\", e);\n return false;\n }\n }\n getUsername() {\n return this.getParsedToken()?.preferred_username;\n }\n isLoggedIn() {\n return !!this.keycloak?.authenticated;\n }\n async getUser() {\n if (!this.keycloak?.token || !this.keycloak.tokenParsed)\n return;\n const profile = await this.keycloak.loadUserProfile();\n return {\n token: this.keycloak.token,\n parsedToken: this.keycloak.tokenParsed,\n profile,\n };\n }\n getKeycloak() {\n return this.keycloak;\n }\n static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"19.2.14\", ngImport: i0, type: KeycloakService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });\n static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: \"12.0.0\", version: \"19.2.14\", ngImport: i0, type: KeycloakService, providedIn: 'root' });\n}\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"19.2.14\", ngImport: i0, type: KeycloakService, decorators: [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n }]\n }], ctorParameters: () => [] });\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoia2V5Y2xvYWsuc2VydmljZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL3F1YW5rZWUtZnJhbWV3b3JrLWtleWNsb2FrL3NyYy9saWIvY29yZS9rZXljbG9hay5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBQyxVQUFVLEVBQUMsTUFBTSxlQUFlLENBQUM7QUFDekMsT0FBTyxRQUFRLE1BQU0sYUFBYSxDQUFDOztBQXlCbkMsTUFBTSxPQUFPLGVBQWU7SUFFakIsUUFBUSxDQUFZO0lBRXJCLFdBQVcsR0FBRyxLQUFLLENBQUM7SUFFNUIsZ0JBQWUsQ0FBQztJQUVoQixLQUFLLENBQUMsSUFBSSxDQUFDLE1BQXNCO1FBQy9CLElBQUksQ0FBQyxRQUFRLEdBQUcsSUFBSSxRQUFRLENBQUM7WUFDM0IsR0FBRyxFQUFFLE1BQU0sQ0FBQyxHQUFHO1lBQ2YsS0FBSyxFQUFFLE1BQU0sQ0FBQyxLQUFLO1lBQ25CLFFBQVEsRUFBRSxNQUFNLENBQUMsUUFBUTtTQUMxQixDQUFDLENBQUM7UUFFSCxNQUFNLFdBQVcsR0FNYjtZQUNGLE1BQU0sRUFBRSxNQUFNLENBQUMsTUFBTSxJQUFJLGdCQUFnQjtZQUN6QyxnQkFBZ0IsRUFBRSxNQUFNLENBQUMsZ0JBQWdCLElBQUksS0FBSztZQUNsRCx5QkFBeUIsRUFBRSxNQUFNLENBQUMseUJBQXlCO1lBQzNELFVBQVUsRUFBRSxNQUFNLENBQUMsVUFBVSxJQUFJLE1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IHRoaXMua2V5Y2xvYWs7XHJcbiAgfVxyXG5cclxuXHJcbn1cclxuIl19","customTransformCache":false,"dependencies":["@angular/core","keycloak-js"],"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/keycloak.service.mjs","meta":{},"moduleSideEffects":true,"originalCode":"import { Injectable } from '@angular/core';\nimport Keycloak from 'keycloak-js';\nimport * as i0 from \"@angular/core\";\nexport class KeycloakService {\n keycloak;\n initialized = false;\n constructor() { }\n async init(config) {\n this.keycloak = new Keycloak({\n url: config.url,\n realm: config.realm,\n clientId: config.clientId,\n });\n const initOptions = {\n onLoad: config.onLoad ?? \"login-required\",\n checkLoginIframe: config.checkLoginIframe ?? false,\n silentCheckSsoRedirectUri: config.silentCheckSsoRedirectUri,\n pkceMethod: config.pkceMethod ?? \"S256\",\n flow: config.flow ?? \"standard\",\n };\n try {\n const authenticated = await this.keycloak.init(initOptions);\n this.initialized = true;\n return authenticated;\n }\n catch (error) {\n console.error(\"Keycloak initialization failed\", error);\n return false;\n }\n }\n login() {\n this.keycloak?.login();\n }\n logout(redirectUri) {\n this.keycloak?.logout({ redirectUri });\n }\n accountManagement() {\n this.keycloak?.accountManagement();\n }\n getToken() {\n return this.keycloak?.token;\n }\n getParsedToken() {\n return this.keycloak?.tokenParsed;\n }\n async refreshToken(minValidity = 5) {\n if (!this.keycloak)\n return false;\n try {\n return await this.keycloak.updateToken(minValidity);\n }\n catch (e) {\n console.error(\"Token refresh failed\", e);\n return false;\n }\n }\n getUsername() {\n return this.getParsedToken()?.preferred_username;\n }\n isLoggedIn() {\n return !!this.keycloak?.authenticated;\n }\n async getUser() {\n if (!this.keycloak?.token || !this.keycloak.tokenParsed)\n return;\n const profile = await this.keycloak.loadUserProfile();\n return {\n token: this.keycloak.token,\n parsedToken: this.keycloak.tokenParsed,\n profile,\n };\n }\n getKeycloak() {\n return this.keycloak;\n }\n static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"19.2.14\", ngImport: i0, type: KeycloakService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });\n static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: \"12.0.0\", version: \"19.2.14\", ngImport: i0, type: KeycloakService, providedIn: 'root' });\n}\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"19.2.14\", ngImport: i0, type: KeycloakService, decorators: [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n }]\n }], ctorParameters: () => [] });\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoia2V5Y2xvYWsuc2VydmljZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL3F1YW5rZWUtZnJhbWV3b3JrLWtleWNsb2FrL3NyYy9saWIvY29yZS9rZXljbG9hay5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBQyxVQUFVLEVBQUMsTUFBTSxlQUFlLENBQUM7QUFDekMsT0FBTyxRQUFRLE1BQU0sYUFBYSxDQUFDOztBQXlCbkMsTUFBTSxPQUFPLGVBQWU7SUFFakIsUUFBUSxDQUFZO0lBRXJCLFdBQVcsR0FBRyxLQUFLLENBQUM7SUFFNUIsZ0JBQWUsQ0FBQztJQUVoQixLQUFLLENBQUMsSUFBSSxDQUFDLE1BQXNCO1FBQy9CLElBQUksQ0FBQyxRQUFRLEdBQUcsSUFBSSxRQUFRLENBQUM7WUFDM0IsR0FBRyxFQUFFLE1BQU0sQ0FBQyxHQUFHO1lBQ2YsS0FBSyxFQUFFLE1BQU0sQ0FBQyxLQUFLO1lBQ25CLFFBQVEsRUFBRSxNQUFNLENBQUMsUUFBUTtTQUMxQixDQUFDLENBQUM7UUFFSCxNQUFNLFdBQVcsR0FNYjtZQUNGLE1BQU0sRUFBRSxNQUFNLENBQUMsTUF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leWNsb2FrLnRva2VuUGFyc2VkIGFzIEtleWNsb2FrVG9rZW4sXHJcbiAgICAgIHByb2ZpbGUsXHJcbiAgICB9O1xyXG4gIH1cclxuXHJcbiAgZ2V0S2V5Y2xvYWsoKTogS2V5Y2xvYWsgfCB1bmRlZmluZWQge1xyXG4gICAgcmV0dXJuIHRoaXMua2V5Y2xvYWs7XHJcbiAgfVxyXG5cclxuXHJcbn1cclxuIl19","originalSourcemap":{"version":3,"file":"keycloak.service.js","sourceRoot":"","sources":["../../../../../projects/quankee-framework-keycloak/src/lib/core/keycloak.service.ts"],"names":[],"mappings":[[[0,0,0,0],[7,0,0,7],[9,0,0,8],[19,0,0,18],[21,0,0,19],[27,0,0,25],[42,0,0,40],[43,0,0,41]],[[0,0,1,0],[7,0,1,7],[15,0,1,15],[21,0,1,21],[34,0,1,34],[35,0,1,35]],[],[[0,0,26,0],[6,0,26,6],[13,0,26,13],[28,0,26,28]],[[4,0,28,11],[12,0,28,19],[13,0,28,31]],[[4,0,30,10],[15,0,30,21],[18,0,30,24],[23,0,30,29],[24,0,30,30]],[[4,0,32,2],[20,0,32,17],[21,0,32,18]],[[4,0,34,2],[9,0,34,7],[10,0,34,8],[14,0,34,12],[15,0,34,13],[21,0,34,35]],[[8,0,35,4],[12,0,35,8],[13,0,35,9],[21,0,35,17],[24,0,35,20],[28,0,35,24],[36,0,35,32],[37,0,35,33]],[[12,0,36,6],[15,0,36,9],[17,0,36,11],[23,0,36,17],[24,0,36,18],[27,0,36,21]],[[12,0,37,6],[17,0,37,11],[19,0,37,13],[25,0,37,19],[26,0,37,20],[31,0,37,25]],[[12,0,38,6],[20,0,38,14],[22,0,38,16],[28,0,38,22],[29,0,38,23],[37,0,38,31]],[[9,0,39,5],[10,0,39,6],[11,0,39,7]],[[8,0,41,4],[14,0,41,10],[25,0,41,21],[28,0,47,8]],[[12,0,48,6],[18,0,48,12],[20,0,48,14],[26,0,48,20],[27,0,48,21],[33,0,48,27],[37,0,48,31],[53,0,48,47]],[[12,0,49,6],[28,0,49,22],[30,0,49,24],[36,0,49,30],[37,0,49,31],[53,0,49,47],[57,0,49,51],[62,0,49,56]],[[12,0,50,6],[37,0,50,31],[39,0,50,33],[45,0,50,39],[46,0,50,40],[71,0,50,65]],[[12,0,51,6],[22,0,51,16],[24,0,51,18],[30,0,51,24],[31,0,51,25],[41,0,51,35],[45,0,51,39],[51,0,51,45]],[[12,0,52,6],[16,0,52,10],[18,0,52,12],[24,0,52,18],[25,0,52,19],[29,0,52,23],[33,0,52,27],[43,0,52,37]],[[9,0,53,5],[10,0,53,6]],[[8,0,55,4],[12,0,55,8],[13,0,55,9]],[[12,0,56,6],[18,0,56,12],[31,0,56,25],[34,0,56,28],[40,0,56,34],[44,0,56,38],[45,0,56,39],[53,0,56,47],[54,0,56,48],[58,0,56,52],[59,0,56,53],[70,0,56,64],[71,0,56,65],[72,0,56,66]],[[12,0,57,6],[16,0,57,10],[17,0,57,11],[28,0,57,22],[31,0,57,25],[35,0,57,29],[36,0,57,30]],[[12,0,58,6],[19,0,58,13],[32,0,58,26],[33,0,58,27]],[[8,0,59,4],[9,0,59,5]],[[8,0,59,6],[15,0,59,13],[20,0,59,18],[22,0,59,20],[23,0,59,21]],[[12,0,60,6],[19,0,60,13],[20,0,60,14],[25,0,60,19],[26,0,60,20],[58,0,60,52],[60,0,60,54],[65,0,60,59],[66,0,60,60],[67,0,60,61]],[[12,0,61,6],[19,0,61,13],[24,0,61,18],[25,0,61,19]],[[8,0,62,4],[9,0,62,5]],[[4,0,64,2],[5,0,64,3]],[[4,0,66,2],[9,0,66,7]],[[8,0,67,4],[12,0,67,8],[13,0,67,9],[21,0,67,17],[23,0,67,19],[28,0,67,24],[30,0,67,26],[31,0,67,27]],[[4,0,68,2],[5,0,68,3]],[[4,0,70,2],[10,0,70,8],[11,0,70,9],[22,0,70,29]],[[8,0,71,4],[12,0,71,8],[13,0,71,9],[21,0,71,17],[23,0,71,19],[29,0,71,25],[30,0,71,26],[32,0,71,28],[43,0,71,39],[45,0,71,41],[46,0,71,42],[47,0,71,43]],[[4,0,72,2],[5,0,72,3]],[[4,0,74,2],[21,0,74,19]],[[8,0,75,4],[12,0,75,8],[13,0,75,9],[21,0,75,17],[23,0,75,19],[40,0,75,36],[42,0,75,38],[43,0,75,39]],[[4,0,76,2],[5,0,76,3]],[[4,0,78,2],[12,0,78,10]],[[8,0,79,4],[15,0,79,11],[19,0,79,15],[20,0,79,16],[28,0,79,24],[30,0,79,26],[35,0,79,31],[36,0,79,32]],[[4,0,80,2],[5,0,80,3]],[[4,0,82,2],[18,0,82,16]],[[8,0,83,4],[15,0,83,11],[19,0,83,15],[20,0,83,16],[28,0,83,24],[30,0,83,26],[41,0,83,54],[42,0,83,55]],[[4,0,84,2],[5,0,84,3]],[[4,0,86,2],[9,0,86,7],[10,0,86,8],[22,0,86,20],[23,0,86,21],[34,0,86,32],[37,0,86,35],[38,0,86,36]],[[8,0,87,4],[12,0,87,8],[13,0,87,9],[17,0,87,13],[18,0,87,14],[26,0,87,22]],[[12,0,87,24],[19,0,87,31],[24,0,87,36],[25,0,87,37]],[[8,0,88,4],[12,0,88,8],[13,0,88,9]],[[12,0,89,6],[19,0,89,13],[25,0,89,19],[29,0,89,23],[30,0,89,24],[38,0,89,32],[39,0,89,33],[50,0,89,44],[51,0,89,45],[62,0,89,56],[63,0,89,57],[64,0,89,58]],[[8,0,90,4],[9,0,90,5]],[[8,0,90,6],[15,0,90,13],[16,0,90,14],[18,0,90,16],[19,0,90,17]],[[12,0,91,6],[19,0,91,13],[20,0,91,14],[25,0,91,19],[26,0,91,20],[48,0,91,42],[50,0,91,44],[51,0,91,45],[52,0,91,46],[53,0,91,47]],[[12,0,92,6],[19,0,92,13],[24,0,92,18],[25,0,92,19]],[[8,0,93,4],[9,0,93,5]],[[4,0,94,2],[5,0,94,3]],[[4,0,96,2],[15,0,96,13]],[[8,0,97,4],[15,0,97,11],[19,0,97,15],[20,0,97,16],[34,0,97,30],[36,0,97,32],[38,0,97,34],[56,0,97,52],[57,0,97,53]],[[4,0,98,2],[5,0,98,3]],[[4,0,100,2],[14,0,100,12]],[[8,0,101,4],[15,0,101,11],[16,0,101,12],[17,0,101,13],[21,0,101,17],[22,0,101,18],[30,0,101,26],[32,0,101,28],[45,0,101,41],[46,0,101,42]],[[4,0,102,2],[5,0,102,3]],[[4,0,104,2],[9,0,104,7],[10,0,104,8],[17,0,104,15]],[[8,0,105,4],[12,0,105,8],[13,0,105,9],[17,0,105,13],[18,0,105,14],[26,0,105,22],[28,0,105,24],[33,0,105,29],[37,0,105,33],[38,0,105,34],[42,0,105,38],[43,0,105,39],[51,0,105,47],[52,0,105,48],[63,0,105,59]],[[12,0,105,61],[19,0,105,68]],[[8,0,107,4],[14,0,107,10],[21,0,107,17],[24,0,107,20],[30,0,107,26],[34,0,107,30],[35,0,107,31],[43,0,107,39],[44,0,107,40],[59,0,107,55],[61,0,107,57],[62,0,107,58]],[[8,0,108,4],[15,0,108,11]],[[12,0,109,6],[17,0,109,11],[19,0,109,13],[23,0,109,17],[24,0,109,18],[32,0,109,26],[33,0,109,27],[38,0,109,32]],[[12,0,110,6],[23,0,110,17],[25,0,110,19],[29,0,110,23],[30,0,110,24],[38,0,110,32],[39,0,110,33],[50,0,110,61]],[[12,0,111,6],[19,0,111,13]],[[9,0,112,5],[10,0,112,6]],[[4,0,113,2],[5,0,113,3]],[[4,0,115,2],[15,0,115,13]],[[8,0,116,4],[15,0,116,11],[19,0,116,15],[20,0,116,16],[28,0,116,24],[29,0,116,25]],[[4,0,117,2],[5,0,117,3]],[[104,0,26,13],[119,0,26,28]],[[108,0,26,13],[123,0,26,28],[137,0,24,14],[143,0,24,20]],[],[[92,0,26,13],[107,0,26,28]],[[18,0,23,1],[28,0,23,11]],[[19,0,23,12]],[[20,0,24,2],[30,0,24,12],[32,0,24,14],[38,0,24,20]],[[17,0,25,1]]],"sourcesContent":["import {Injectable} from '@angular/core';\r\nimport Keycloak from 'keycloak-js';\r\nimport {AuthenticatedUser} from './authenticated-user';\r\nimport {KeycloakToken} from './keycloak-token';\r\n\r\n// Your own type definition for 'onLoad' because keycloak-js doesn't export it\r\nexport type AppKeycloakOnLoad = \"login-required\" | \"check-sso\";\r\n\r\nexport type KeycloakPkceMethod = \"S256\";\r\n\r\n// Your own config interface\r\nexport interface KeycloakConfig {\r\n url: string;\r\n realm: string;\r\n clientId: string;\r\n onLoad?: AppKeycloakOnLoad;\r\n checkLoginIframe?: boolean;\r\n silentCheckSsoRedirectUri?: string;\r\n pkceMethod?: KeycloakPkceMethod;\r\n flow?: \"standard\" | \"implicit\";\r\n}\r\n\r\n\r\n@Injectable({\r\n providedIn: 'root',\r\n})\r\nexport class KeycloakService{\r\n\r\n private keycloak?: Keycloak;\r\n\r\n private initialized = false;\r\n\r\n constructor() {}\r\n\r\n async init(config: KeycloakConfig): Promise<boolean> {\r\n this.keycloak = new Keycloak({\r\n url: config.url,\r\n realm: config.realm,\r\n clientId: config.clientId,\r\n });\r\n\r\n const initOptions: {\r\n onLoad: \"login-required\" | \"check-sso\";\r\n checkLoginIframe: boolean;\r\n silentCheckSsoRedirectUri?: string;\r\n pkceMethod: KeycloakPkceMethod;\r\n flow: \"standard\" | \"implicit\";\r\n } = {\r\n onLoad: config.onLoad ?? \"login-required\",\r\n checkLoginIframe: config.checkLoginIframe ?? false,\r\n silentCheckSsoRedirectUri: config.silentCheckSsoRedirectUri,\r\n pkceMethod: config.pkceMethod ?? \"S256\",\r\n flow: config.flow ?? \"standard\",\r\n };\r\n\r\n try {\r\n const authenticated = await this.keycloak.init(initOptions);\r\n this.initialized = true;\r\n return authenticated;\r\n } catch (error) {\r\n console.error(\"Keycloak initialization failed\", error);\r\n return false;\r\n }\r\n\r\n }\r\n\r\n login(): void {\r\n this.keycloak?.login();\r\n }\r\n\r\n logout(redirectUri?: string): void {\r\n this.keycloak?.logout({ redirectUri });\r\n }\r\n\r\n accountManagement(): void {\r\n this.keycloak?.accountManagement();\r\n }\r\n\r\n getToken(): string | undefined {\r\n return this.keycloak?.token;\r\n }\r\n\r\n getParsedToken(): KeycloakToken | undefined {\r\n return this.keycloak?.tokenParsed as KeycloakToken;\r\n }\r\n\r\n async refreshToken(minValidity = 5): Promise<boolean> {\r\n if (!this.keycloak) return false;\r\n try {\r\n return await this.keycloak.updateToken(minValidity);\r\n } catch (e) {\r\n console.error(\"Token refresh failed\", e);\r\n return false;\r\n }\r\n }\r\n\r\n getUsername(): string | undefined {\r\n return this.getParsedToken()?.preferred_username;\r\n }\r\n\r\n isLoggedIn(): boolean {\r\n return !!this.keycloak?.authenticated;\r\n }\r\n\r\n async getUser(): Promise<AuthenticatedUser | undefined> {\r\n if (!this.keycloak?.token || !this.keycloak.tokenParsed) return;\r\n\r\n const profile = await this.keycloak.loadUserProfile();\r\n return {\r\n token: this.keycloak.token,\r\n parsedToken: this.keycloak.tokenParsed as KeycloakToken,\r\n profile,\r\n };\r\n }\r\n\r\n getKeycloak(): Keycloak | undefined {\r\n return this.keycloak;\r\n }\r\n\r\n\r\n}\r\n"]},"resolvedIds":{"@angular/core":{"attributes":{},"external":true,"id":"@angular/core","meta":{},"moduleSideEffects":true,"resolvedBy":"rollup","syntheticNamedExports":false},"keycloak-js":{"attributes":{},"external":true,"id":"keycloak-js","meta":{},"moduleSideEffects":true,"resolvedBy":"rollup","syntheticNamedExports":false}},"sourcemapChain":[],"syntheticNamedExports":false,"transformDependencies":[]},{"ast":{"type":"Program","start":0,"end":876,"body":[{"type":"ExportAllDeclaration","start":59,"end":101,"exported":null,"source":{"type":"Literal","start":73,"end":100,"value":"./lib/core/keycloak-token","raw":"'./lib/core/keycloak-token'"},"attributes":[]},{"type":"ExportAllDeclaration","start":102,"end":148,"exported":null,"source":{"type":"Literal","start":116,"end":147,"value":"./lib/core/authenticated-user","raw":"'./lib/core/authenticated-user'"},"attributes":[]},{"type":"ExportAllDeclaration","start":149,"end":193,"exported":null,"source":{"type":"Literal","start":163,"end":192,"value":"./lib/core/keycloak.service","raw":"'./lib/core/keycloak.service'"},"attributes":[]}],"_rollupRemoved":[{"end":876,"start":194,"type":"sourcemap"}],"sourceType":"module"},"attributes":{},"code":"/*\n * Public API Surface of quankee-framework-keycloak\n */\nexport * from './lib/core/keycloak-token';\nexport * from './lib/core/authenticated-user';\nexport * from './lib/core/keycloak.service';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljLWFwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3Byb2plY3RzL3F1YW5rZWUtZnJhbWV3b3JrLWtleWNsb2FrL3NyYy9wdWJsaWMtYXBpLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBRUgsY0FBYywyQkFBMkIsQ0FBQztBQUMxQyxjQUFjLCtCQUErQixDQUFDO0FBQzlDLGNBQWMsNkJBQTZCLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvKlxyXG4gKiBQdWJsaWMgQVBJIFN1cmZhY2Ugb2YgcXVhbmtlZS1mcmFtZXdvcmsta2V5Y2xvYWtcclxuICovXHJcblxyXG5leHBvcnQgKiBmcm9tICcuL2xpYi9jb3JlL2tleWNsb2FrLXRva2VuJztcclxuZXhwb3J0ICogZnJvbSAnLi9saWIvY29yZS9hdXRoZW50aWNhdGVkLXVzZXInO1xyXG5leHBvcnQgKiBmcm9tICcuL2xpYi9jb3JlL2tleWNsb2FrLnNlcnZpY2UnO1xyXG5cclxuIl19","customTransformCache":false,"dependencies":["C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/keycloak-token.mjs","C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/authenticated-user.mjs","C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/keycloak.service.mjs"],"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/public-api.mjs","meta":{},"moduleSideEffects":true,"originalCode":"/*\n * Public API Surface of quankee-framework-keycloak\n */\nexport * from './lib/core/keycloak-token';\nexport * from './lib/core/authenticated-user';\nexport * from './lib/core/keycloak.service';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljLWFwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3Byb2plY3RzL3F1YW5rZWUtZnJhbWV3b3JrLWtleWNsb2FrL3NyYy9wdWJsaWMtYXBpLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBRUgsY0FBYywyQkFBMkIsQ0FBQztBQUMxQyxjQUFjLCtCQUErQixDQUFDO0FBQzlDLGNBQWMsNkJBQTZCLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvKlxyXG4gKiBQdWJsaWMgQVBJIFN1cmZhY2Ugb2YgcXVhbmtlZS1mcmFtZXdvcmsta2V5Y2xvYWtcclxuICovXHJcblxyXG5leHBvcnQgKiBmcm9tICcuL2xpYi9jb3JlL2tleWNsb2FrLXRva2VuJztcclxuZXhwb3J0ICogZnJvbSAnLi9saWIvY29yZS9hdXRoZW50aWNhdGVkLXVzZXInO1xyXG5leHBvcnQgKiBmcm9tICcuL2xpYi9jb3JlL2tleWNsb2FrLnNlcnZpY2UnO1xyXG5cclxuIl19","originalSourcemap":{"version":3,"file":"public-api.js","sourceRoot":"","sources":["../../../projects/quankee-framework-keycloak/src/public-api.ts"],"names":[],"mappings":[[[0,0,0,0]],[],[[3,0,2,3]],[[0,0,4,0],[14,0,4,14],[41,0,4,41],[42,0,4,42]],[[0,0,5,0],[14,0,5,14],[45,0,5,45],[46,0,5,46]],[[0,0,6,0],[14,0,6,14],[43,0,6,43],[44,0,6,44]]],"sourcesContent":["/*\r\n * Public API Surface of quankee-framework-keycloak\r\n */\r\n\r\nexport * from './lib/core/keycloak-token';\r\nexport * from './lib/core/authenticated-user';\r\nexport * from './lib/core/keycloak.service';\r\n\r\n"]},"resolvedIds":{"./lib/core/keycloak-token":{"attributes":{},"external":false,"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/keycloak-token.mjs","meta":{},"moduleSideEffects":true,"resolvedBy":"file-loader","syntheticNamedExports":false},"./lib/core/authenticated-user":{"attributes":{},"external":false,"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/authenticated-user.mjs","meta":{},"moduleSideEffects":true,"resolvedBy":"file-loader","syntheticNamedExports":false},"./lib/core/keycloak.service":{"attributes":{},"external":false,"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/lib/core/keycloak.service.mjs","meta":{},"moduleSideEffects":true,"resolvedBy":"file-loader","syntheticNamedExports":false}},"sourcemapChain":[],"syntheticNamedExports":false,"transformDependencies":[]},{"ast":{"type":"Program","start":0,"end":560,"body":[{"type":"ExportAllDeclaration","start":48,"end":77,"exported":null,"source":{"type":"Literal","start":62,"end":76,"value":"./public-api","raw":"'./public-api'"},"attributes":[]}],"_rollupRemoved":[{"end":560,"start":78,"type":"sourcemap"}],"sourceType":"module"},"attributes":{},"code":"/**\n * Generated bundle index. Do not edit.\n */\nexport * from './public-api';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicXVhbmtlZS1mcmFtZXdvcmsta2V5Y2xvYWsuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9wcm9qZWN0cy9xdWFua2VlLWZyYW1ld29yay1rZXljbG9hay9zcmMvcXVhbmtlZS1mcmFtZXdvcmsta2V5Y2xvYWsudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7O0dBRUc7QUFFSCxjQUFjLGNBQWMsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogR2VuZXJhdGVkIGJ1bmRsZSBpbmRleC4gRG8gbm90IGVkaXQuXG4gKi9cblxuZXhwb3J0ICogZnJvbSAnLi9wdWJsaWMtYXBpJztcbiJdfQ==","customTransformCache":false,"dependencies":["C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/public-api.mjs"],"id":"C:\\usr\\local\\workspaces\\workspace-quankee\\quankee-framework\\quankee-framework-common-ts\\dist\\quankee-framework-keycloak\\esm2022\\quankee-framework-keycloak.mjs","meta":{},"moduleSideEffects":true,"originalCode":"/**\n * Generated bundle index. Do not edit.\n */\nexport * from './public-api';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicXVhbmtlZS1mcmFtZXdvcmsta2V5Y2xvYWsuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9wcm9qZWN0cy9xdWFua2VlLWZyYW1ld29yay1rZXljbG9hay9zcmMvcXVhbmtlZS1mcmFtZXdvcmsta2V5Y2xvYWsudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7O0dBRUc7QUFFSCxjQUFjLGNBQWMsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogR2VuZXJhdGVkIGJ1bmRsZSBpbmRleC4gRG8gbm90IGVkaXQuXG4gKi9cblxuZXhwb3J0ICogZnJvbSAnLi9wdWJsaWMtYXBpJztcbiJdfQ==","originalSourcemap":{"version":3,"file":"quankee-framework-keycloak.js","sourceRoot":"","sources":["../../../projects/quankee-framework-keycloak/src/quankee-framework-keycloak.ts"],"names":[],"mappings":[[[0,0,0,0]],[],[[3,0,2,3]],[[0,0,4,0],[14,0,4,14],[28,0,4,28],[29,0,4,29]]],"sourcesContent":["/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"]},"resolvedIds":{"./public-api":{"attributes":{},"external":false,"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-keycloak/esm2022/public-api.mjs","meta":{},"moduleSideEffects":true,"resolvedBy":"file-loader","syntheticNamedExports":false}},"sourcemapChain":[],"syntheticNamedExports":false,"transformDependencies":[]}],"plugins":{"file-loader":{},"json":{}}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"hash":"d513dd3e480468a33146364297d5d9c2adce15f4d60d01d5ca67ba49e6348adc","fesm2022":[{"exports":[],"facadeModuleId":"C:\\usr\\local\\workspaces\\workspace-quankee\\quankee-framework\\quankee-framework-common-ts\\dist\\quankee-framework-language\\esm2022\\quankee-framework-language.mjs","isDynamicEntry":false,"isEntry":true,"isImplicitEntry":false,"moduleIds":["C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-language/esm2022/lib/core/language.mjs","C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-language/esm2022/public-api.mjs","C:\\usr\\local\\workspaces\\workspace-quankee\\quankee-framework\\quankee-framework-common-ts\\dist\\quankee-framework-language\\esm2022\\quankee-framework-language.mjs"],"name":"quankee-framework-language","type":"chunk","dynamicImports":[],"fileName":"quankee-framework-language.mjs","implicitlyLoadedBefore":[],"importedBindings":{},"imports":[],"modules":{"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-language/esm2022/lib/core/language.mjs":{"code":"","originalLength":421,"removedExports":[],"renderedExports":[],"renderedLength":0},"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-language/esm2022/public-api.mjs":{"code":"/*\n * Public API Surface of quankee-framework-language\n */","originalLength":574,"removedExports":[],"renderedExports":[],"renderedLength":58},"C:\\usr\\local\\workspaces\\workspace-quankee\\quankee-framework\\quankee-framework-common-ts\\dist\\quankee-framework-language\\esm2022\\quankee-framework-language.mjs":{"code":"/**\n * Generated bundle index. Do not edit.\n */","originalLength":560,"removedExports":[],"renderedExports":[],"renderedLength":47}},"referencedFiles":[],"code":"/*\n * Public API Surface of quankee-framework-language\n */\n\n/**\n * Generated bundle index. Do not edit.\n */\n//# sourceMappingURL=quankee-framework-language.mjs.map\n","map":null,"preliminaryFileName":"quankee-framework-language.mjs","sourcemapFileName":"quankee-framework-language.mjs.map"},{"fileName":"quankee-framework-language.mjs.map","names":[],"needsCodeReference":false,"originalFileName":null,"originalFileNames":[],"source":"{\"version\":3,\"file\":\"quankee-framework-language.mjs\",\"sources\":[\"../../../projects/quankee-framework-language/src/public-api.ts\",\"../../../projects/quankee-framework-language/src/quankee-framework-language.ts\"],\"sourcesContent\":[\"/*\\r\\n * Public API Surface of quankee-framework-language\\r\\n */\\r\\n\\r\\nexport * from './lib/core/language';\\r\\n\",\"/**\\n * Generated bundle index. Do not edit.\\n */\\n\\nexport * from './public-api';\\n\"],\"names\":[],\"mappings\":\"AAAA;;AAEG;;ACFH;;AAEG\"}","type":"asset"}]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"modules":[{"ast":{"type":"Program","start":0,"end":453,"body":[{"type":"ExportNamedDeclaration","start":0,"end":10,"specifiers":[],"source":null,"attributes":[],"declaration":null}],"_rollupRemoved":[{"end":453,"start":11,"type":"sourcemap"}],"sourceType":"module"},"attributes":{},"code":"export {};\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVzcG9uc2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9xdWFua2VlLWZyYW1ld29yay1yZXNwb25zZS9zcmMvbGliL2NvcmUvcmVzcG9uc2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCBpbnRlcmZhY2UgUmVzcG9uc2UgPFQ+IHtcclxuICBzdWNjZXNzZnVsOiBib29sZWFuO1xyXG4gIG1lc3NhZ2U6IHN0cmluZztcclxuICBwYXlsb2FkOiBUO1xyXG59XHJcbiJdfQ==","customTransformCache":false,"dependencies":[],"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-response/esm2022/lib/core/response.mjs","meta":{},"moduleSideEffects":true,"originalCode":"export {};\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVzcG9uc2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9xdWFua2VlLWZyYW1ld29yay1yZXNwb25zZS9zcmMvbGliL2NvcmUvcmVzcG9uc2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCBpbnRlcmZhY2UgUmVzcG9uc2UgPFQ+IHtcclxuICBzdWNjZXNzZnVsOiBib29sZWFuO1xyXG4gIG1lc3NhZ2U6IHN0cmluZztcclxuICBwYXlsb2FkOiBUO1xyXG59XHJcbiJdfQ==","originalSourcemap":{"mappings":[],"names":[],"sources":[],"version":3},"resolvedIds":{},"sourcemapChain":[],"syntheticNamedExports":false,"transformDependencies":[]},{"ast":{"type":"Program","start":0,"end":578,"body":[{"type":"ExportAllDeclaration","start":59,"end":95,"exported":null,"source":{"type":"Literal","start":73,"end":94,"value":"./lib/core/response","raw":"'./lib/core/response'"},"attributes":[]}],"_rollupRemoved":[{"end":578,"start":96,"type":"sourcemap"}],"sourceType":"module"},"attributes":{},"code":"/*\n * Public API Surface of quankee-framework-response\n */\nexport * from './lib/core/response';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljLWFwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3Byb2plY3RzL3F1YW5rZWUtZnJhbWV3b3JrLXJlc3BvbnNlL3NyYy9wdWJsaWMtYXBpLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBRUgsY0FBYyxxQkFBcUIsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qXHJcbiAqIFB1YmxpYyBBUEkgU3VyZmFjZSBvZiBxdWFua2VlLWZyYW1ld29yay1yZXNwb25zZVxyXG4gKi9cclxuXHJcbmV4cG9ydCAqIGZyb20gJy4vbGliL2NvcmUvcmVzcG9uc2UnO1xyXG5cclxuIl19","customTransformCache":false,"dependencies":["C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-response/esm2022/lib/core/response.mjs"],"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-response/esm2022/public-api.mjs","meta":{},"moduleSideEffects":true,"originalCode":"/*\n * Public API Surface of quankee-framework-response\n */\nexport * from './lib/core/response';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljLWFwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3Byb2plY3RzL3F1YW5rZWUtZnJhbWV3b3JrLXJlc3BvbnNlL3NyYy9wdWJsaWMtYXBpLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBRUgsY0FBYyxxQkFBcUIsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qXHJcbiAqIFB1YmxpYyBBUEkgU3VyZmFjZSBvZiBxdWFua2VlLWZyYW1ld29yay1yZXNwb25zZVxyXG4gKi9cclxuXHJcbmV4cG9ydCAqIGZyb20gJy4vbGliL2NvcmUvcmVzcG9uc2UnO1xyXG5cclxuIl19","originalSourcemap":{"version":3,"file":"public-api.js","sourceRoot":"","sources":["../../../projects/quankee-framework-response/src/public-api.ts"],"names":[],"mappings":[[[0,0,0,0]],[],[[3,0,2,3]],[[0,0,4,0],[14,0,4,14],[35,0,4,35],[36,0,4,36]]],"sourcesContent":["/*\r\n * Public API Surface of quankee-framework-response\r\n */\r\n\r\nexport * from './lib/core/response';\r\n\r\n"]},"resolvedIds":{"./lib/core/response":{"attributes":{},"external":false,"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-response/esm2022/lib/core/response.mjs","meta":{},"moduleSideEffects":true,"resolvedBy":"file-loader","syntheticNamedExports":false}},"sourcemapChain":[],"syntheticNamedExports":false,"transformDependencies":[]},{"ast":{"type":"Program","start":0,"end":560,"body":[{"type":"ExportAllDeclaration","start":48,"end":77,"exported":null,"source":{"type":"Literal","start":62,"end":76,"value":"./public-api","raw":"'./public-api'"},"attributes":[]}],"_rollupRemoved":[{"end":560,"start":78,"type":"sourcemap"}],"sourceType":"module"},"attributes":{},"code":"/**\n * Generated bundle index. Do not edit.\n */\nexport * from './public-api';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicXVhbmtlZS1mcmFtZXdvcmstcmVzcG9uc2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9wcm9qZWN0cy9xdWFua2VlLWZyYW1ld29yay1yZXNwb25zZS9zcmMvcXVhbmtlZS1mcmFtZXdvcmstcmVzcG9uc2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7O0dBRUc7QUFFSCxjQUFjLGNBQWMsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogR2VuZXJhdGVkIGJ1bmRsZSBpbmRleC4gRG8gbm90IGVkaXQuXG4gKi9cblxuZXhwb3J0ICogZnJvbSAnLi9wdWJsaWMtYXBpJztcbiJdfQ==","customTransformCache":false,"dependencies":["C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-response/esm2022/public-api.mjs"],"id":"C:\\usr\\local\\workspaces\\workspace-quankee\\quankee-framework\\quankee-framework-common-ts\\dist\\quankee-framework-response\\esm2022\\quankee-framework-response.mjs","meta":{},"moduleSideEffects":true,"originalCode":"/**\n * Generated bundle index. Do not edit.\n */\nexport * from './public-api';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicXVhbmtlZS1mcmFtZXdvcmstcmVzcG9uc2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9wcm9qZWN0cy9xdWFua2VlLWZyYW1ld29yay1yZXNwb25zZS9zcmMvcXVhbmtlZS1mcmFtZXdvcmstcmVzcG9uc2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7O0dBRUc7QUFFSCxjQUFjLGNBQWMsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogR2VuZXJhdGVkIGJ1bmRsZSBpbmRleC4gRG8gbm90IGVkaXQuXG4gKi9cblxuZXhwb3J0ICogZnJvbSAnLi9wdWJsaWMtYXBpJztcbiJdfQ==","originalSourcemap":{"version":3,"file":"quankee-framework-response.js","sourceRoot":"","sources":["../../../projects/quankee-framework-response/src/quankee-framework-response.ts"],"names":[],"mappings":[[[0,0,0,0]],[],[[3,0,2,3]],[[0,0,4,0],[14,0,4,14],[28,0,4,28],[29,0,4,29]]],"sourcesContent":["/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"]},"resolvedIds":{"./public-api":{"attributes":{},"external":false,"id":"C:/usr/local/workspaces/workspace-quankee/quankee-framework/quankee-framework-common-ts/dist/quankee-framework-response/esm2022/public-api.mjs","meta":{},"moduleSideEffects":true,"resolvedBy":"file-loader","syntheticNamedExports":false}},"sourcemapChain":[],"syntheticNamedExports":false,"transformDependencies":[]}],"plugins":{"file-loader":{},"json":{}}}
|
package/.editorconfig
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
# Editor configuration, see https://editorconfig.org
|
|
2
|
-
root = true
|
|
3
|
-
|
|
4
|
-
[*]
|
|
5
|
-
charset = utf-8
|
|
6
|
-
indent_style = space
|
|
7
|
-
indent_size = 2
|
|
8
|
-
insert_final_newline = true
|
|
9
|
-
trim_trailing_whitespace = true
|
|
10
|
-
|
|
11
|
-
[*.ts]
|
|
12
|
-
quote_type = single
|
|
13
|
-
ij_typescript_use_double_quotes = false
|
|
14
|
-
|
|
15
|
-
[*.md]
|
|
16
|
-
max_line_length = off
|
|
17
|
-
trim_trailing_whitespace = false
|
|
1
|
+
# Editor configuration, see https://editorconfig.org
|
|
2
|
+
root = true
|
|
3
|
+
|
|
4
|
+
[*]
|
|
5
|
+
charset = utf-8
|
|
6
|
+
indent_style = space
|
|
7
|
+
indent_size = 2
|
|
8
|
+
insert_final_newline = true
|
|
9
|
+
trim_trailing_whitespace = true
|
|
10
|
+
|
|
11
|
+
[*.ts]
|
|
12
|
+
quote_type = single
|
|
13
|
+
ij_typescript_use_double_quotes = false
|
|
14
|
+
|
|
15
|
+
[*.md]
|
|
16
|
+
max_line_length = off
|
|
17
|
+
trim_trailing_whitespace = false
|
package/.gitlab-ci.yml
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
include:
|
|
3
|
-
- project: 'quankee-framework/quankee-ci'
|
|
1
|
+
|
|
2
|
+
include:
|
|
3
|
+
- project: 'quankee-framework/quankee-ci'
|
|
4
4
|
file: '/templates/typescript/common-build.yml'
|
package/LICENSE
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
ISC License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2025 Quankee Software, Lda
|
|
4
|
-
|
|
5
|
-
Permission to use, copy, modify, and/or distribute this software for any
|
|
6
|
-
purpose with or without fee is hereby granted, provided that the above
|
|
7
|
-
copyright notice and this permission notice appear in all copies.
|
|
8
|
-
|
|
9
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
|
10
|
-
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
|
11
|
-
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
|
12
|
-
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
|
13
|
-
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
|
14
|
-
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
|
15
|
-
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|
1
|
+
ISC License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 Quankee Software, Lda
|
|
4
|
+
|
|
5
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
6
|
+
purpose with or without fee is hereby granted, provided that the above
|
|
7
|
+
copyright notice and this permission notice appear in all copies.
|
|
8
|
+
|
|
9
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
|
10
|
+
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
|
11
|
+
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
|
12
|
+
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
|
13
|
+
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
|
14
|
+
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
|
15
|
+
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,42 +1,42 @@
|
|
|
1
|
-
# Quankee Framework Common Ts
|
|
2
|
-
|
|
3
|
-
This project was generated using [Angular CLI](https://github.com/angular/angular-cli) version 19.2.11.
|
|
4
|
-
|
|
5
|
-
# create workspace
|
|
6
|
-
ng new quankee-framework-common-ts --create-application=false
|
|
7
|
-
|
|
8
|
-
# create the lib
|
|
9
|
-
ng generate library quankee-framework-common-ts
|
|
10
|
-
|
|
11
|
-
# version bump
|
|
12
|
-
npm run bump:patch # bumps 1.0.0 → 1.0.1
|
|
13
|
-
npm run bump:minor # bumps 1.0.0 → 1.1.0
|
|
14
|
-
npm run bump:major # bumps 1.0.0 → 2.0.0
|
|
15
|
-
|
|
16
|
-
# create lib for common http response
|
|
17
|
-
ng generate library quankee-framework-response
|
|
18
|
-
|
|
19
|
-
# create lib for language
|
|
20
|
-
ng generate library quankee-framework-language
|
|
21
|
-
|
|
22
|
-
# create lib for keycloak integration
|
|
23
|
-
ng generate library quankee-framework-keycloak
|
|
24
|
-
|
|
25
|
-
# Keycloak
|
|
26
|
-
npm install keycloak-angular keycloak-js
|
|
27
|
-
|
|
28
|
-
# JWT
|
|
29
|
-
npm install jwt-decode
|
|
30
|
-
|
|
31
|
-
# install jest
|
|
32
|
-
npm install --save-dev @types/jest
|
|
33
|
-
|
|
34
|
-
# clean cache
|
|
35
|
-
rm -rf dist node_modules package-lock.json
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
# build
|
|
39
|
-
npm run build
|
|
40
|
-
|
|
41
|
-
# test npm run test -- --watch=false --browsers=ChromeHeadless
|
|
42
|
-
ng test --watch=false --browsers=ChromeHeadless
|
|
1
|
+
# Quankee Framework Common Ts
|
|
2
|
+
|
|
3
|
+
This project was generated using [Angular CLI](https://github.com/angular/angular-cli) version 19.2.11.
|
|
4
|
+
|
|
5
|
+
# create workspace
|
|
6
|
+
ng new quankee-framework-common-ts --create-application=false
|
|
7
|
+
|
|
8
|
+
# create the lib
|
|
9
|
+
ng generate library quankee-framework-common-ts
|
|
10
|
+
|
|
11
|
+
# version bump
|
|
12
|
+
npm run bump:patch # bumps 1.0.0 → 1.0.1
|
|
13
|
+
npm run bump:minor # bumps 1.0.0 → 1.1.0
|
|
14
|
+
npm run bump:major # bumps 1.0.0 → 2.0.0
|
|
15
|
+
|
|
16
|
+
# create lib for common http response
|
|
17
|
+
ng generate library quankee-framework-response
|
|
18
|
+
|
|
19
|
+
# create lib for language
|
|
20
|
+
ng generate library quankee-framework-language
|
|
21
|
+
|
|
22
|
+
# create lib for keycloak integration
|
|
23
|
+
ng generate library quankee-framework-keycloak
|
|
24
|
+
|
|
25
|
+
# Keycloak
|
|
26
|
+
npm install keycloak-angular keycloak-js
|
|
27
|
+
|
|
28
|
+
# JWT
|
|
29
|
+
npm install jwt-decode
|
|
30
|
+
|
|
31
|
+
# install jest
|
|
32
|
+
npm install --save-dev @types/jest
|
|
33
|
+
|
|
34
|
+
# clean cache
|
|
35
|
+
rm -rf dist node_modules package-lock.json
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
# build
|
|
39
|
+
npm run build
|
|
40
|
+
|
|
41
|
+
# test npm run test -- --watch=false --browsers=ChromeHeadless
|
|
42
|
+
ng test --watch=false --browsers=ChromeHeadless
|
package/angular.json
CHANGED
|
@@ -1,109 +1,109 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
|
|
3
|
-
"version": 1,
|
|
4
|
-
"newProjectRoot": "projects",
|
|
5
|
-
"projects": {
|
|
6
|
-
"quankee-framework-response": {
|
|
7
|
-
"projectType": "library",
|
|
8
|
-
"root": "projects/quankee-framework-response",
|
|
9
|
-
"sourceRoot": "projects/quankee-framework-response/src",
|
|
10
|
-
"prefix": "lib",
|
|
11
|
-
"architect": {
|
|
12
|
-
"build": {
|
|
13
|
-
"builder": "@angular-devkit/build-angular:ng-packagr",
|
|
14
|
-
"options": {
|
|
15
|
-
"project": "projects/quankee-framework-response/ng-package.json"
|
|
16
|
-
},
|
|
17
|
-
"configurations": {
|
|
18
|
-
"production": {
|
|
19
|
-
"tsConfig": "projects/quankee-framework-response/tsconfig.lib.prod.json"
|
|
20
|
-
},
|
|
21
|
-
"development": {
|
|
22
|
-
"tsConfig": "projects/quankee-framework-response/tsconfig.lib.json"
|
|
23
|
-
}
|
|
24
|
-
},
|
|
25
|
-
"defaultConfiguration": "production"
|
|
26
|
-
},
|
|
27
|
-
"test": {
|
|
28
|
-
"builder": "@angular-devkit/build-angular:karma",
|
|
29
|
-
"options": {
|
|
30
|
-
"tsConfig": "projects/quankee-framework-response/tsconfig.spec.json",
|
|
31
|
-
"polyfills": [
|
|
32
|
-
"zone.js",
|
|
33
|
-
"zone.js/testing"
|
|
34
|
-
]
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
"quankee-framework-language": {
|
|
40
|
-
"projectType": "library",
|
|
41
|
-
"root": "projects/quankee-framework-language",
|
|
42
|
-
"sourceRoot": "projects/quankee-framework-language/src",
|
|
43
|
-
"prefix": "lib",
|
|
44
|
-
"architect": {
|
|
45
|
-
"build": {
|
|
46
|
-
"builder": "@angular-devkit/build-angular:ng-packagr",
|
|
47
|
-
"options": {
|
|
48
|
-
"project": "projects/quankee-framework-language/ng-package.json"
|
|
49
|
-
},
|
|
50
|
-
"configurations": {
|
|
51
|
-
"production": {
|
|
52
|
-
"tsConfig": "projects/quankee-framework-language/tsconfig.lib.prod.json"
|
|
53
|
-
},
|
|
54
|
-
"development": {
|
|
55
|
-
"tsConfig": "projects/quankee-framework-language/tsconfig.lib.json"
|
|
56
|
-
}
|
|
57
|
-
},
|
|
58
|
-
"defaultConfiguration": "production"
|
|
59
|
-
},
|
|
60
|
-
"test": {
|
|
61
|
-
"builder": "@angular-devkit/build-angular:karma",
|
|
62
|
-
"options": {
|
|
63
|
-
"tsConfig": "projects/quankee-framework-language/tsconfig.spec.json",
|
|
64
|
-
"polyfills": [
|
|
65
|
-
"zone.js",
|
|
66
|
-
"zone.js/testing"
|
|
67
|
-
]
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
},
|
|
72
|
-
"quankee-framework-keycloak": {
|
|
73
|
-
"projectType": "library",
|
|
74
|
-
"root": "projects/quankee-framework-keycloak",
|
|
75
|
-
"sourceRoot": "projects/quankee-framework-keycloak/src",
|
|
76
|
-
"prefix": "lib",
|
|
77
|
-
"architect": {
|
|
78
|
-
"build": {
|
|
79
|
-
"builder": "@angular-devkit/build-angular:ng-packagr",
|
|
80
|
-
"options": {
|
|
81
|
-
"project": "projects/quankee-framework-keycloak/ng-package.json"
|
|
82
|
-
},
|
|
83
|
-
"configurations": {
|
|
84
|
-
"production": {
|
|
85
|
-
"tsConfig": "projects/quankee-framework-keycloak/tsconfig.lib.prod.json"
|
|
86
|
-
},
|
|
87
|
-
"development": {
|
|
88
|
-
"tsConfig": "projects/quankee-framework-keycloak/tsconfig.lib.json"
|
|
89
|
-
}
|
|
90
|
-
},
|
|
91
|
-
"defaultConfiguration": "production"
|
|
92
|
-
},
|
|
93
|
-
"test": {
|
|
94
|
-
"builder": "@angular-devkit/build-angular:karma",
|
|
95
|
-
"options": {
|
|
96
|
-
"tsConfig": "projects/quankee-framework-keycloak/tsconfig.spec.json",
|
|
97
|
-
"polyfills": [
|
|
98
|
-
"zone.js",
|
|
99
|
-
"zone.js/testing"
|
|
100
|
-
]
|
|
101
|
-
}
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
},
|
|
106
|
-
"cli": {
|
|
107
|
-
"analytics": "5f6f9f58-7562-4078-b930-99069ac7e701"
|
|
108
|
-
}
|
|
109
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
|
|
3
|
+
"version": 1,
|
|
4
|
+
"newProjectRoot": "projects",
|
|
5
|
+
"projects": {
|
|
6
|
+
"quankee-framework-response": {
|
|
7
|
+
"projectType": "library",
|
|
8
|
+
"root": "projects/quankee-framework-response",
|
|
9
|
+
"sourceRoot": "projects/quankee-framework-response/src",
|
|
10
|
+
"prefix": "lib",
|
|
11
|
+
"architect": {
|
|
12
|
+
"build": {
|
|
13
|
+
"builder": "@angular-devkit/build-angular:ng-packagr",
|
|
14
|
+
"options": {
|
|
15
|
+
"project": "projects/quankee-framework-response/ng-package.json"
|
|
16
|
+
},
|
|
17
|
+
"configurations": {
|
|
18
|
+
"production": {
|
|
19
|
+
"tsConfig": "projects/quankee-framework-response/tsconfig.lib.prod.json"
|
|
20
|
+
},
|
|
21
|
+
"development": {
|
|
22
|
+
"tsConfig": "projects/quankee-framework-response/tsconfig.lib.json"
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
"defaultConfiguration": "production"
|
|
26
|
+
},
|
|
27
|
+
"test": {
|
|
28
|
+
"builder": "@angular-devkit/build-angular:karma",
|
|
29
|
+
"options": {
|
|
30
|
+
"tsConfig": "projects/quankee-framework-response/tsconfig.spec.json",
|
|
31
|
+
"polyfills": [
|
|
32
|
+
"zone.js",
|
|
33
|
+
"zone.js/testing"
|
|
34
|
+
]
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
"quankee-framework-language": {
|
|
40
|
+
"projectType": "library",
|
|
41
|
+
"root": "projects/quankee-framework-language",
|
|
42
|
+
"sourceRoot": "projects/quankee-framework-language/src",
|
|
43
|
+
"prefix": "lib",
|
|
44
|
+
"architect": {
|
|
45
|
+
"build": {
|
|
46
|
+
"builder": "@angular-devkit/build-angular:ng-packagr",
|
|
47
|
+
"options": {
|
|
48
|
+
"project": "projects/quankee-framework-language/ng-package.json"
|
|
49
|
+
},
|
|
50
|
+
"configurations": {
|
|
51
|
+
"production": {
|
|
52
|
+
"tsConfig": "projects/quankee-framework-language/tsconfig.lib.prod.json"
|
|
53
|
+
},
|
|
54
|
+
"development": {
|
|
55
|
+
"tsConfig": "projects/quankee-framework-language/tsconfig.lib.json"
|
|
56
|
+
}
|
|
57
|
+
},
|
|
58
|
+
"defaultConfiguration": "production"
|
|
59
|
+
},
|
|
60
|
+
"test": {
|
|
61
|
+
"builder": "@angular-devkit/build-angular:karma",
|
|
62
|
+
"options": {
|
|
63
|
+
"tsConfig": "projects/quankee-framework-language/tsconfig.spec.json",
|
|
64
|
+
"polyfills": [
|
|
65
|
+
"zone.js",
|
|
66
|
+
"zone.js/testing"
|
|
67
|
+
]
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
"quankee-framework-keycloak": {
|
|
73
|
+
"projectType": "library",
|
|
74
|
+
"root": "projects/quankee-framework-keycloak",
|
|
75
|
+
"sourceRoot": "projects/quankee-framework-keycloak/src",
|
|
76
|
+
"prefix": "lib",
|
|
77
|
+
"architect": {
|
|
78
|
+
"build": {
|
|
79
|
+
"builder": "@angular-devkit/build-angular:ng-packagr",
|
|
80
|
+
"options": {
|
|
81
|
+
"project": "projects/quankee-framework-keycloak/ng-package.json"
|
|
82
|
+
},
|
|
83
|
+
"configurations": {
|
|
84
|
+
"production": {
|
|
85
|
+
"tsConfig": "projects/quankee-framework-keycloak/tsconfig.lib.prod.json"
|
|
86
|
+
},
|
|
87
|
+
"development": {
|
|
88
|
+
"tsConfig": "projects/quankee-framework-keycloak/tsconfig.lib.json"
|
|
89
|
+
}
|
|
90
|
+
},
|
|
91
|
+
"defaultConfiguration": "production"
|
|
92
|
+
},
|
|
93
|
+
"test": {
|
|
94
|
+
"builder": "@angular-devkit/build-angular:karma",
|
|
95
|
+
"options": {
|
|
96
|
+
"tsConfig": "projects/quankee-framework-keycloak/tsconfig.spec.json",
|
|
97
|
+
"polyfills": [
|
|
98
|
+
"zone.js",
|
|
99
|
+
"zone.js/testing"
|
|
100
|
+
]
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
},
|
|
106
|
+
"cli": {
|
|
107
|
+
"analytics": "5f6f9f58-7562-4078-b930-99069ac7e701"
|
|
108
|
+
}
|
|
109
|
+
}
|
package/package.json
CHANGED
|
@@ -1,57 +1,59 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "quankee-framework-common-ts",
|
|
3
|
-
"description": "Quankee Framework Typescript Lib",
|
|
4
|
-
"version": "1.
|
|
5
|
-
"author": {
|
|
6
|
-
"email": "info@quankee.co.mz",
|
|
7
|
-
"name": "Quankee Software, Lda",
|
|
8
|
-
"repository": {
|
|
9
|
-
"type": "git",
|
|
10
|
-
"url": "https://gitlab.com/quankee-framework/quankee-framework-common-ts"
|
|
11
|
-
},
|
|
12
|
-
"homepage": "https://gitlab.com/quankee-framework/quankee-framework-common-ts#readme",
|
|
13
|
-
"publishConfig": {
|
|
14
|
-
"registry": "https://registry.npmjs.org/"
|
|
15
|
-
}
|
|
16
|
-
},
|
|
17
|
-
"scripts": {
|
|
18
|
-
"ng": "ng",
|
|
19
|
-
"start": "ng serve",
|
|
20
|
-
"build": "ng build quankee-framework-response && ng build quankee-framework-language && ng build quankee-framework-keycloak",
|
|
21
|
-
"watch": "ng build --watch --configuration development",
|
|
22
|
-
"test": "echo",
|
|
23
|
-
"
|
|
24
|
-
"
|
|
25
|
-
"bump:
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
"@angular/
|
|
31
|
-
"@angular/
|
|
32
|
-
"@angular/
|
|
33
|
-
"@angular/
|
|
34
|
-
"@angular/
|
|
35
|
-
"
|
|
36
|
-
"
|
|
37
|
-
"
|
|
38
|
-
"
|
|
39
|
-
"
|
|
40
|
-
"
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
"@angular/
|
|
46
|
-
"@
|
|
47
|
-
"@
|
|
48
|
-
"jasmine
|
|
49
|
-
"
|
|
50
|
-
"
|
|
51
|
-
"karma
|
|
52
|
-
"karma-
|
|
53
|
-
"karma-
|
|
54
|
-
"
|
|
55
|
-
"
|
|
56
|
-
|
|
57
|
-
|
|
1
|
+
{
|
|
2
|
+
"name": "quankee-framework-common-ts",
|
|
3
|
+
"description": "Quankee Framework Typescript Lib",
|
|
4
|
+
"version": "1.3.2",
|
|
5
|
+
"author": {
|
|
6
|
+
"email": "info@quankee.co.mz",
|
|
7
|
+
"name": "Quankee Software, Lda",
|
|
8
|
+
"repository": {
|
|
9
|
+
"type": "git",
|
|
10
|
+
"url": "https://gitlab.com/quankee-framework/quankee-framework-common-ts"
|
|
11
|
+
},
|
|
12
|
+
"homepage": "https://gitlab.com/quankee-framework/quankee-framework-common-ts#readme",
|
|
13
|
+
"publishConfig": {
|
|
14
|
+
"registry": "https://registry.npmjs.org/"
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
"scripts": {
|
|
18
|
+
"ng": "ng",
|
|
19
|
+
"start": "ng serve",
|
|
20
|
+
"build": "ng build quankee-framework-response && ng build quankee-framework-language && ng build quankee-framework-keycloak",
|
|
21
|
+
"watch": "ng build --watch --configuration development",
|
|
22
|
+
"test": "echo",
|
|
23
|
+
"publish:libs": "node publish-all.js",
|
|
24
|
+
"publish": "npm run build && npm run publish:libs",
|
|
25
|
+
"bump:major": "npm version major && node sync-versions.js",
|
|
26
|
+
"bump:minor": "npm version minor && node sync-versions.js",
|
|
27
|
+
"bump:patch": "npm version patch && node sync-versions.js"
|
|
28
|
+
},
|
|
29
|
+
"dependencies": {
|
|
30
|
+
"@angular/common": "^19.2.0",
|
|
31
|
+
"@angular/compiler": "^19.2.0",
|
|
32
|
+
"@angular/core": "^19.2.0",
|
|
33
|
+
"@angular/forms": "^19.2.0",
|
|
34
|
+
"@angular/platform-browser": "^19.2.0",
|
|
35
|
+
"@angular/platform-browser-dynamic": "^19.2.0",
|
|
36
|
+
"@angular/router": "^19.2.0",
|
|
37
|
+
"jwt-decode": "4.0.0",
|
|
38
|
+
"keycloak-angular": "20.0.0",
|
|
39
|
+
"keycloak-js": "26.2.0",
|
|
40
|
+
"rxjs": "~7.8.0",
|
|
41
|
+
"tslib": "^2.3.0",
|
|
42
|
+
"zone.js": "~0.15.0"
|
|
43
|
+
},
|
|
44
|
+
"devDependencies": {
|
|
45
|
+
"@angular-devkit/build-angular": "^19.2.15",
|
|
46
|
+
"@angular/cli": "^19.2.11",
|
|
47
|
+
"@angular/compiler-cli": "^19.2.0",
|
|
48
|
+
"@types/jasmine": "~5.1.0",
|
|
49
|
+
"@types/jest": "30.0.0",
|
|
50
|
+
"jasmine-core": "~5.6.0",
|
|
51
|
+
"karma": "~6.4.0",
|
|
52
|
+
"karma-chrome-launcher": "~3.2.0",
|
|
53
|
+
"karma-coverage": "~2.2.0",
|
|
54
|
+
"karma-jasmine": "~5.1.0",
|
|
55
|
+
"karma-jasmine-html-reporter": "~2.1.0",
|
|
56
|
+
"ng-packagr": "^19.2.0",
|
|
57
|
+
"typescript": "~5.7.2"
|
|
58
|
+
}
|
|
59
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
ISC License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 Quankee Software, Lda
|
|
4
|
+
|
|
5
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
6
|
+
purpose with or without fee is hereby granted, provided that the above
|
|
7
|
+
copyright notice and this permission notice appear in all copies.
|
|
8
|
+
|
|
9
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
|
10
|
+
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
|
11
|
+
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
|
12
|
+
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
|
13
|
+
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
|
14
|
+
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
|
15
|
+
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "../../node_modules/ng-packagr/ng-package.schema.json",
|
|
3
|
-
"dest": "../../dist/quankee-framework-keycloak",
|
|
4
|
-
"lib": {
|
|
5
|
-
"entryFile": "src/public-api.ts"
|
|
6
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"$schema": "../../node_modules/ng-packagr/ng-package.schema.json",
|
|
3
|
+
"dest": "../../dist/quankee-framework-keycloak",
|
|
4
|
+
"lib": {
|
|
5
|
+
"entryFile": "src/public-api.ts"
|
|
6
|
+
}
|
|
7
7
|
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "quankee-framework-keycloak",
|
|
3
|
+
"version": "1.0.1",
|
|
4
|
+
"lockfileVersion": 3,
|
|
5
|
+
"requires": true,
|
|
6
|
+
"packages": {
|
|
7
|
+
"": {
|
|
8
|
+
"name": "quankee-framework-keycloak",
|
|
9
|
+
"version": "1.0.1",
|
|
10
|
+
"dependencies": {
|
|
11
|
+
"jwt-decode": "4.0.0",
|
|
12
|
+
"tslib": "^2.3.0"
|
|
13
|
+
},
|
|
14
|
+
"peerDependencies": {
|
|
15
|
+
"@angular/common": "^19.2.0",
|
|
16
|
+
"@angular/core": "^19.2.0",
|
|
17
|
+
"keycloak-angular": "20.0.0",
|
|
18
|
+
"keycloak-js": "26.2.0"
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
"node_modules/jwt-decode": {
|
|
22
|
+
"version": "4.0.0",
|
|
23
|
+
"resolved": "https://registry.npmjs.org/jwt-decode/-/jwt-decode-4.0.0.tgz",
|
|
24
|
+
"integrity": "sha512-+KJGIyHgkGuIq3IEBNftfhW/LfWhXUIY6OmyVWjliu5KH1y0fw7VQ8YndE2O4qZdMSd9SqbnC8GOcZEy0Om7sA==",
|
|
25
|
+
"license": "MIT",
|
|
26
|
+
"engines": {
|
|
27
|
+
"node": ">=18"
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
"node_modules/tslib": {
|
|
31
|
+
"version": "2.8.1",
|
|
32
|
+
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz",
|
|
33
|
+
"integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==",
|
|
34
|
+
"license": "0BSD"
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
|
@@ -1,12 +1,36 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "quankee-framework-keycloak",
|
|
3
|
-
"
|
|
3
|
+
"description": "Quankee Framework Keycloak Lib",
|
|
4
|
+
"version": "1.3.2",
|
|
5
|
+
"author": {
|
|
6
|
+
"email": "info@quankee.co.mz",
|
|
7
|
+
"name": "Quankee Software, Lda",
|
|
8
|
+
"license": "MIT",
|
|
9
|
+
"repository": {
|
|
10
|
+
"type": "git",
|
|
11
|
+
"url": "https://gitlab.com/quankee-framework/quankee-framework-common-ts"
|
|
12
|
+
},
|
|
13
|
+
"homepage": "https://gitlab.com/quankee-framework/quankee-framework-common-ts#readme",
|
|
14
|
+
"publishConfig": {
|
|
15
|
+
"registry": "https://registry.npmjs.org/"
|
|
16
|
+
}
|
|
17
|
+
},
|
|
4
18
|
"peerDependencies": {
|
|
5
19
|
"@angular/common": "^19.2.0",
|
|
6
|
-
"@angular/core": "^19.2.0"
|
|
20
|
+
"@angular/core": "^19.2.0",
|
|
21
|
+
"keycloak-angular": "20.0.0",
|
|
22
|
+
"keycloak-js": "26.2.0",
|
|
23
|
+
"jwt-decode": "4.0.0"
|
|
7
24
|
},
|
|
8
25
|
"dependencies": {
|
|
9
26
|
"tslib": "^2.3.0"
|
|
10
27
|
},
|
|
28
|
+
"ngPackage": {
|
|
29
|
+
"$schema": "../../node_modules/ng-packagr/ng-package.schema.json",
|
|
30
|
+
"dest": "../../dist/quankee-framework-keycloak",
|
|
31
|
+
"lib": {
|
|
32
|
+
"entryFile": "src/public-api.ts"
|
|
33
|
+
}
|
|
34
|
+
},
|
|
11
35
|
"sideEffects": false
|
|
12
36
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "../../node_modules/ng-packagr/ng-package.schema.json",
|
|
3
|
-
"dest": "../../dist/quankee-framework-language",
|
|
4
|
-
"lib": {
|
|
5
|
-
"entryFile": "src/public-api.ts"
|
|
6
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"$schema": "../../node_modules/ng-packagr/ng-package.schema.json",
|
|
3
|
+
"dest": "../../dist/quankee-framework-language",
|
|
4
|
+
"lib": {
|
|
5
|
+
"entryFile": "src/public-api.ts"
|
|
6
|
+
}
|
|
7
7
|
}
|
|
@@ -1,6 +1,20 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "quankee-framework-language",
|
|
3
|
-
"
|
|
3
|
+
"description": "Quankee Framework Language Lib",
|
|
4
|
+
"version": "1.3.2",
|
|
5
|
+
"author": {
|
|
6
|
+
"email": "info@quankee.co.mz",
|
|
7
|
+
"name": "Quankee Software, Lda",
|
|
8
|
+
"license": "MIT",
|
|
9
|
+
"repository": {
|
|
10
|
+
"type": "git",
|
|
11
|
+
"url": "https://gitlab.com/quankee-framework/quankee-framework-common-ts"
|
|
12
|
+
},
|
|
13
|
+
"homepage": "https://gitlab.com/quankee-framework/quankee-framework-common-ts#readme",
|
|
14
|
+
"publishConfig": {
|
|
15
|
+
"registry": "https://registry.npmjs.org/"
|
|
16
|
+
}
|
|
17
|
+
},
|
|
4
18
|
"peerDependencies": {
|
|
5
19
|
"@angular/common": "^19.2.0",
|
|
6
20
|
"@angular/core": "^19.2.0"
|
|
@@ -8,5 +22,12 @@
|
|
|
8
22
|
"dependencies": {
|
|
9
23
|
"tslib": "^2.3.0"
|
|
10
24
|
},
|
|
25
|
+
"ngPackage": {
|
|
26
|
+
"$schema": "../../node_modules/ng-packagr/ng-package.schema.json",
|
|
27
|
+
"dest": "../../dist/quankee-framework-keycloak",
|
|
28
|
+
"lib": {
|
|
29
|
+
"entryFile": "src/public-api.ts"
|
|
30
|
+
}
|
|
31
|
+
},
|
|
11
32
|
"sideEffects": false
|
|
12
33
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "../../node_modules/ng-packagr/ng-package.schema.json",
|
|
3
|
-
"dest": "../../dist/quankee-framework-response",
|
|
4
|
-
"lib": {
|
|
5
|
-
"entryFile": "src/public-api.ts"
|
|
6
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"$schema": "../../node_modules/ng-packagr/ng-package.schema.json",
|
|
3
|
+
"dest": "../../dist/quankee-framework-response",
|
|
4
|
+
"lib": {
|
|
5
|
+
"entryFile": "src/public-api.ts"
|
|
6
|
+
}
|
|
7
7
|
}
|
|
@@ -1,6 +1,20 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "quankee-framework-response",
|
|
3
|
-
"
|
|
3
|
+
"description": "Quankee Framework Response Lib",
|
|
4
|
+
"version": "1.3.2",
|
|
5
|
+
"author": {
|
|
6
|
+
"email": "info@quankee.co.mz",
|
|
7
|
+
"name": "Quankee Software, Lda",
|
|
8
|
+
"license": "MIT",
|
|
9
|
+
"repository": {
|
|
10
|
+
"type": "git",
|
|
11
|
+
"url": "https://gitlab.com/quankee-framework/quankee-framework-common-ts"
|
|
12
|
+
},
|
|
13
|
+
"homepage": "https://gitlab.com/quankee-framework/quankee-framework-common-ts#readme",
|
|
14
|
+
"publishConfig": {
|
|
15
|
+
"registry": "https://registry.npmjs.org/"
|
|
16
|
+
}
|
|
17
|
+
},
|
|
4
18
|
"peerDependencies": {
|
|
5
19
|
"@angular/common": "^19.2.0",
|
|
6
20
|
"@angular/core": "^19.2.0"
|
|
@@ -8,5 +22,12 @@
|
|
|
8
22
|
"dependencies": {
|
|
9
23
|
"tslib": "^2.3.0"
|
|
10
24
|
},
|
|
25
|
+
"ngPackage": {
|
|
26
|
+
"$schema": "../../node_modules/ng-packagr/ng-package.schema.json",
|
|
27
|
+
"dest": "../../dist/quankee-framework-keycloak",
|
|
28
|
+
"lib": {
|
|
29
|
+
"entryFile": "src/public-api.ts"
|
|
30
|
+
}
|
|
31
|
+
},
|
|
11
32
|
"sideEffects": false
|
|
12
33
|
}
|
package/publish-all.js
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
const { execSync } = require('child_process');
|
|
2
|
+
const libs = [
|
|
3
|
+
'quankee-framework-response',
|
|
4
|
+
'quankee-framework-language',
|
|
5
|
+
'quankee-framework-keycloak'
|
|
6
|
+
];
|
|
7
|
+
|
|
8
|
+
for (const lib of libs) {
|
|
9
|
+
console.log(`\nPublishing ${lib}...`);
|
|
10
|
+
execSync(`npm publish dist/${lib}/ --access public`, { stdio: 'inherit' });
|
|
11
|
+
}
|
package/sync-versions.js
CHANGED
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
const fs = require('fs');
|
|
2
|
-
const path = require('path');
|
|
3
|
-
|
|
4
|
-
const ROOT_DIR = process.cwd();
|
|
5
|
-
const LIBS_DIR = path.join(ROOT_DIR, 'projects');
|
|
6
|
-
|
|
7
|
-
const rootPackage = JSON.parse(fs.readFileSync('package.json', 'utf8'));
|
|
8
|
-
const newVersion = rootPackage.version;
|
|
9
|
-
|
|
10
|
-
function updateLibVersion(libPath) {
|
|
11
|
-
const pkgJsonPath = path.join(libPath, 'package.json');
|
|
12
|
-
if (fs.existsSync(pkgJsonPath)) {
|
|
13
|
-
const pkg = JSON.parse(fs.readFileSync(pkgJsonPath, 'utf8'));
|
|
14
|
-
pkg.version = newVersion;
|
|
15
|
-
fs.writeFileSync(pkgJsonPath, JSON.stringify(pkg, null, 2));
|
|
16
|
-
console.log(`✔ Updated ${pkg.name} to version ${newVersion}`);
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
fs.readdirSync(LIBS_DIR).forEach((dir) => {
|
|
21
|
-
const libPath = path.join(LIBS_DIR, dir);
|
|
22
|
-
const stat = fs.statSync(libPath);
|
|
23
|
-
if (stat.isDirectory()) {
|
|
24
|
-
updateLibVersion(libPath);
|
|
25
|
-
}
|
|
26
|
-
});
|
|
1
|
+
const fs = require('fs');
|
|
2
|
+
const path = require('path');
|
|
3
|
+
|
|
4
|
+
const ROOT_DIR = process.cwd();
|
|
5
|
+
const LIBS_DIR = path.join(ROOT_DIR, 'projects');
|
|
6
|
+
|
|
7
|
+
const rootPackage = JSON.parse(fs.readFileSync('package.json', 'utf8'));
|
|
8
|
+
const newVersion = rootPackage.version;
|
|
9
|
+
|
|
10
|
+
function updateLibVersion(libPath) {
|
|
11
|
+
const pkgJsonPath = path.join(libPath, 'package.json');
|
|
12
|
+
if (fs.existsSync(pkgJsonPath)) {
|
|
13
|
+
const pkg = JSON.parse(fs.readFileSync(pkgJsonPath, 'utf8'));
|
|
14
|
+
pkg.version = newVersion;
|
|
15
|
+
fs.writeFileSync(pkgJsonPath, JSON.stringify(pkg, null, 2));
|
|
16
|
+
console.log(`✔ Updated ${pkg.name} to version ${newVersion}`);
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
fs.readdirSync(LIBS_DIR).forEach((dir) => {
|
|
21
|
+
const libPath = path.join(LIBS_DIR, dir);
|
|
22
|
+
const stat = fs.statSync(libPath);
|
|
23
|
+
if (stat.isDirectory()) {
|
|
24
|
+
updateLibVersion(libPath);
|
|
25
|
+
}
|
|
26
|
+
});
|