@acorex/connectivity 20.2.0-next.2 → 20.2.0-next.4
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/api/index.d.ts +30 -3
- package/fesm2022/acorex-connectivity-api.mjs +329 -306
- package/fesm2022/acorex-connectivity-api.mjs.map +1 -1
- package/fesm2022/acorex-connectivity-mock.mjs +5194 -1127
- package/fesm2022/acorex-connectivity-mock.mjs.map +1 -1
- package/fesm2022/acorex-connectivity-utils.mjs +7 -7
- package/fesm2022/acorex-connectivity-utils.mjs.map +1 -1
- package/mock/index.d.ts +193 -8
- package/package.json +1 -1
- package/fesm2022/acorex-connectivity-mock-countries-DHRrtbwM.mjs +0 -591
- package/fesm2022/acorex-connectivity-mock-countries-DHRrtbwM.mjs.map +0 -1
- package/fesm2022/acorex-connectivity-mock-currencies-B-x3Mxql.mjs +0 -13
- package/fesm2022/acorex-connectivity-mock-currencies-B-x3Mxql.mjs.map +0 -1
- package/fesm2022/acorex-connectivity-mock-profiles-MJ9xFTtp.mjs +0 -19
- package/fesm2022/acorex-connectivity-mock-profiles-MJ9xFTtp.mjs.map +0 -1
- package/fesm2022/acorex-connectivity-mock-timezones-CnNQ6EXw.mjs +0 -44
- package/fesm2022/acorex-connectivity-mock-timezones-CnNQ6EXw.mjs.map +0 -1
|
@@ -36,19 +36,19 @@ class AXCExternalAuthorizationService {
|
|
|
36
36
|
// Use window.location.assign to redirect
|
|
37
37
|
window.location.assign(authUrl);
|
|
38
38
|
}
|
|
39
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.
|
|
40
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.1.
|
|
39
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.4", ngImport: i0, type: AXCExternalAuthorizationService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
40
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.1.4", ngImport: i0, type: AXCExternalAuthorizationService }); }
|
|
41
41
|
}
|
|
42
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.
|
|
42
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.4", ngImport: i0, type: AXCExternalAuthorizationService, decorators: [{
|
|
43
43
|
type: Injectable
|
|
44
44
|
}] });
|
|
45
45
|
|
|
46
46
|
class AXCUtilsModule {
|
|
47
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.
|
|
48
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.1.
|
|
49
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.1.
|
|
47
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.4", ngImport: i0, type: AXCUtilsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
48
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.1.4", ngImport: i0, type: AXCUtilsModule, imports: [CommonModule] }); }
|
|
49
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.1.4", ngImport: i0, type: AXCUtilsModule, providers: [AXCExternalAuthorizationService], imports: [CommonModule] }); }
|
|
50
50
|
}
|
|
51
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.
|
|
51
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.4", ngImport: i0, type: AXCUtilsModule, decorators: [{
|
|
52
52
|
type: NgModule,
|
|
53
53
|
args: [{
|
|
54
54
|
imports: [CommonModule],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"acorex-connectivity-utils.mjs","sources":["../tmp-esm2022/utils/lib/external-authorization.service.js","../tmp-esm2022/utils/lib/utils.module.js","../tmp-esm2022/utils/acorex-connectivity-utils.js"],"sourcesContent":["import { AXM_AUTH_CONFIG_TOKEN } from '@acorex/modules/auth';\nimport { PkceUtil } from '@acorex/platform/auth';\nimport { inject, Injectable } from '@angular/core';\nimport * as i0 from \"@angular/core\";\nexport class AXCExternalAuthorizationService {\n constructor() {\n this.configs = inject(AXM_AUTH_CONFIG_TOKEN);\n }\n async signin(providerName) {\n // Get provider configuration (optional, for validation)\n const providerConfig = this.configs?.externalProviders?.[providerName];\n if (!providerConfig) {\n throw new Error(`Provider '${providerName}' is not configured`);\n }\n // Get application configuration for OIDC\n const clientId = this.configs?.authConfig?.clientId || 'spa-client';\n const redirectUri = encodeURIComponent(`${window.location.origin}/auth/axp-oauth-callback`);\n const authorizeUrl = `${this.configs?.authConfig?.issuer}/connect/authorize`;\n // Centralized PKCE code verifier logic\n const codeVerifier = PkceUtil.generateRandomString(128);\n localStorage.setItem('pkce_code_verifier', codeVerifier);\n const codeChallenge = await PkceUtil.generateCodeChallenge(codeVerifier);\n // Build the authorization URL according to the required format\n const authUrl = `${authorizeUrl}` +\n `?response_type=code` +\n `&client_id=${clientId}` +\n `&redirect_uri=${redirectUri}` +\n `&scope=openid profile email` +\n `&code_challenge=${codeChallenge}` +\n `&code_challenge_method=S256` +\n `&prompt=login` +\n `&acr_values=${providerName}`;\n console.log('Redirecting to:', authUrl);\n // Use window.location.assign to redirect\n window.location.assign(authUrl);\n }\n static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"20.1.3\", ngImport: i0, type: AXCExternalAuthorizationService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }\n static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: \"12.0.0\", version: \"20.1.3\", ngImport: i0, type: AXCExternalAuthorizationService }); }\n}\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"20.1.3\", ngImport: i0, type: AXCExternalAuthorizationService, decorators: [{\n type: Injectable\n }] });\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZXh0ZXJuYWwtYXV0aG9yaXphdGlvbi5zZXJ2aWNlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vbGlicy9jb25uZWN0aXZpdHkvdXRpbHMvc3JjL2xpYi9leHRlcm5hbC1hdXRob3JpemF0aW9uLnNlcnZpY2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLHFCQUFxQixFQUFrQixNQUFNLHNCQUFzQixDQUFDO0FBQzdFLE9BQU8sRUFBRSxRQUFRLEVBQUUsTUFBTSx1QkFBdUIsQ0FBQztBQUNqRCxPQUFPLEVBQUUsTUFBTSxFQUFFLFVBQVUsRUFBRSxNQUFNLGVBQWUsQ0FBQzs7QUFHbkQsTUFBTSxPQUFPLCtCQUErQjtJQUQ1QztRQUVVLFlBQU8sR0FBbUIsTUFBTSxDQUFpQixxQkFBcUIsQ0FBQyxDQUFDO0tBb0NqRjtJQWxDQyxLQUFLLENBQUMsTUFBTSxDQUFDLFlBQW9CO1FBQy9CLHdEQUF3RDtRQUN4RCxNQUFNLGNBQWMsR0FBRyxJQUFJLENBQUMsT0FBTyxFQUFFLGlCQUFpQixFQUFFLENBQUMsWUFBWSxDQUFDLENBQUM7UUFDdkUsSUFBSSxDQUFDLGNBQWMsRUFBRSxDQUFDO1lBQ3BCLE1BQU0sSUFBSSxLQUFLLENBQUMsYUFBYSxZQUFZLHFCQUFxQixDQUFDLENBQUM7UUFDbEUsQ0FBQztRQUVELHlDQUF5QztRQUN6QyxNQUFNLFFBQVEsR0FBRyxJQUFJLENBQUMsT0FBTyxFQUFFLFVBQVUsRUFBRSxRQUFRLElBQUksWUFBWSxDQUFDO1FBQ3BFLE1BQU0sV0FBVyxHQUFHLGtC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mVkaXJlY3RcbiAgICB3aW5kb3cubG9jYXRpb24uYXNzaWduKGF1dGhVcmwpO1xuICB9XG59XG4iXX0=","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXCExternalAuthorizationService } from './external-authorization.service';\nimport * as i0 from \"@angular/core\";\nexport class AXCUtilsModule {\n static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"20.1.3\", ngImport: i0, type: AXCUtilsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }\n static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: \"14.0.0\", version: \"20.1.3\", ngImport: i0, type: AXCUtilsModule, imports: [CommonModule] }); }\n static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: \"12.0.0\", version: \"20.1.3\", ngImport: i0, type: AXCUtilsModule, providers: [AXCExternalAuthorizationService], imports: [CommonModule] }); }\n}\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"20.1.3\", ngImport: i0, type: AXCUtilsModule, decorators: [{\n type: NgModule,\n args: [{\n imports: [CommonModule],\n providers: [AXCExternalAuthorizationService],\n }]\n }] });\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidXRpbHMubW9kdWxlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vbGlicy9jb25uZWN0aXZpdHkvdXRpbHMvc3JjL2xpYi91dGlscy5tb2R1bGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFlBQVksRUFBRSxNQUFNLGlCQUFpQixDQUFDO0FBQy9DLE9BQU8sRUFBRSxRQUFRLEVBQUUsTUFBTSxlQUFlLENBQUM7QUFDekMsT0FBTyxFQUFFLCtCQUErQixFQUFFLE1BQU0sa0NBQWtDLENBQUM7O0FBTW5GLE1BQU0sT0FBTyxjQUFjOzhHQUFkLGNBQWM7K0dBQWQsY0FBYyxZQUhmLFlBQVk7K0dBR1gsY0FBYyxhQUZkLENBQUMsK0JBQStCLENBQUMsWUFEbEMsWUFBWTs7MkZBR1gsY0FBYztrQkFKMUIsUUFBUTttQkFBQztvQkFDUixPQUFPLEVBQUUsQ0FBQyxZQUFZLENBQUM7b0JBQ3ZCLFNBQVMsRUFBRSxDQUFDLCtCQUErQixDQUFDO2lCQUM3QyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IENvbW1vbk1vZHVsZSB9IGZyb20gJ0Bhbmd1bGFyL2NvbW1vbic7XG5pbXBvcnQgeyBOZ01vZHVsZSB9IGZyb20gJ0Bhbmd1bGFyL2NvcmUnO1xuaW1wb3J0IHsgQVhDRXh0ZXJuYWxBdXRob3JpemF0aW9uU2VydmljZSB9IGZyb20gJy4vZXh0ZXJuYWwtYXV0aG9yaXphdGlvbi5zZXJ2aWNlJztcblxuQE5nTW9kdWxlKHtcbiAgaW1wb3J0czogW0NvbW1vbk1vZHVsZV0sXG4gIHByb3ZpZGVyczogW0FYQ0V4dGVybmFsQXV0aG9yaXphdGlvblNlcnZpY2VdLFxufSlcbmV4cG9ydCBjbGFzcyBBWENVdGlsc01vZHVsZSB7fVxuIl19","/**\n * Generated bundle index. Do not edit.\n */\nexport * from './index';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWNvcmV4LWNvbm5lY3Rpdml0eS11dGlscy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL2xpYnMvY29ubmVjdGl2aXR5L3V0aWxzL3NyYy9hY29yZXgtY29ubmVjdGl2aXR5LXV0aWxzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBRUgsY0FBYyxTQUFTLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEdlbmVyYXRlZCBidW5kbGUgaW5kZX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eAAe,CAAC,QAAQ,EAAE,CAAC,CAAC;AAC/K,IAAI,SAAS,IAAI,CAAC,IAAI,GAAG,EAAE,CAAC,mBAAmB,CAAC,EAAE,UAAU,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,cAAc,EAAE,OAAO,EAAE,CAAC,YAAY,CAAC,EAAE,CAAC,CAAC;AAC1J,IAAI,SAAS,IAAI,CAAC,IAAI,GAAG,EAAE,CAAC,mBAAmB,CAAC,EAAE,UAAU,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,cAAc,EAAE,SAAS,EAAE,CAAC,+BAA+B,CAAC,EAAE,OAAO,EAAE,CAAC,YAAY,CAAC,EAAE,CAAC,CAAC;AACxM;AACA,EAAE,CAAC,wBAAwB,CAAC,EAAE,UAAU,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,cAAc,EAAE,UAAU,EAAE,CAAC;AACxH,YAAY,IAAI,EAAE,QAAQ;AAC1B,YAAY,IAAI,EAAE,CAAC;AACnB,oBAAoB,OAAO,EAAE,CAAC,YAAY,CAAC;AAC3C,oBAAoB,SAAS,EAAE,CAAC,+BAA+B,CAAC;AAChE,iBAAiB;AACjB,SAAS,CAAC,EAAE,CAAC;;ACfb;AACA;AACA;;;;"}
|
|
1
|
+
{"version":3,"file":"acorex-connectivity-utils.mjs","sources":["../tmp-esm2022/utils/lib/external-authorization.service.js","../tmp-esm2022/utils/lib/utils.module.js","../tmp-esm2022/utils/acorex-connectivity-utils.js"],"sourcesContent":["import { AXM_AUTH_CONFIG_TOKEN } from '@acorex/modules/auth';\nimport { PkceUtil } from '@acorex/platform/auth';\nimport { inject, Injectable } from '@angular/core';\nimport * as i0 from \"@angular/core\";\nexport class AXCExternalAuthorizationService {\n constructor() {\n this.configs = inject(AXM_AUTH_CONFIG_TOKEN);\n }\n async signin(providerName) {\n // Get provider configuration (optional, for validation)\n const providerConfig = this.configs?.externalProviders?.[providerName];\n if (!providerConfig) {\n throw new Error(`Provider '${providerName}' is not configured`);\n }\n // Get application configuration for OIDC\n const clientId = this.configs?.authConfig?.clientId || 'spa-client';\n const redirectUri = encodeURIComponent(`${window.location.origin}/auth/axp-oauth-callback`);\n const authorizeUrl = `${this.configs?.authConfig?.issuer}/connect/authorize`;\n // Centralized PKCE code verifier logic\n const codeVerifier = PkceUtil.generateRandomString(128);\n localStorage.setItem('pkce_code_verifier', codeVerifier);\n const codeChallenge = await PkceUtil.generateCodeChallenge(codeVerifier);\n // Build the authorization URL according to the required format\n const authUrl = `${authorizeUrl}` +\n `?response_type=code` +\n `&client_id=${clientId}` +\n `&redirect_uri=${redirectUri}` +\n `&scope=openid profile email` +\n `&code_challenge=${codeChallenge}` +\n `&code_challenge_method=S256` +\n `&prompt=login` +\n `&acr_values=${providerName}`;\n console.log('Redirecting to:', authUrl);\n // Use window.location.assign to redirect\n window.location.assign(authUrl);\n }\n static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"20.1.4\", ngImport: i0, type: AXCExternalAuthorizationService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }\n static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: \"12.0.0\", version: \"20.1.4\", ngImport: i0, type: AXCExternalAuthorizationService }); }\n}\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"20.1.4\", ngImport: i0, type: AXCExternalAuthorizationService, decorators: [{\n type: Injectable\n }] });\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZXh0ZXJuYWwtYXV0aG9yaXphdGlvbi5zZXJ2aWNlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vbGlicy9jb25uZWN0aXZpdHkvdXRpbHM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0SXRlbSgncGtjZV9jb2RlX3ZlcmlmaWVyJywgY29kZVZlcmlmaWVyKTtcbiAgICBjb25zdCBjb2RlQ2hhbGxlbmdlID0gYXdhaXQgUGtjZVV0aWwuZ2VuZXJhdGVDb2RlQ2hhbGxlbmdlKGNvZGVWZXJpZmllcik7XG5cbiAgICAvLyBCdWlsZCB0aGUgYXV0aG9yaXphdGlvbiBVUkwgYWNjb3JkaW5nIHRvIHRoZSByZXF1aXJlZCBmb3JtYXRcbiAgICBjb25zdCBhdXRoVXJsID1cbiAgICAgIGAke2F1dGhvcml6ZVVybH1gICtcbiAgICAgIGA/cmVzcG9uc2VfdHlwZT1jb2RlYCArXG4gICAgICBgJmNsaWVudF9pZD0ke2NsaWVudElkfWAgK1xuICAgICAgYCZyZWRpcmVjdF91cmk9JHtyZWRpcmVjdFVyaX1gICtcbiAgICAgIGAmc2NvcGU9b3BlbmlkIHByb2ZpbGUgZW1haWxgICtcbiAgICAgIGAmY29kZV9jaGFsbGVuZ2U9JHtjb2RlQ2hhbGxlbmdlfWAgK1xuICAgICAgYCZjb2RlX2NoYWxsZW5nZV9tZXRob2Q9UzI1NmAgK1xuICAgICAgYCZwcm9tcHQ9bG9naW5gICtcbiAgICAgIGAmYWNyX3ZhbHVlcz0ke3Byb3ZpZGVyTmFtZX1gO1xuXG4gICAgY29uc29sZS5sb2coJ1JlZGlyZWN0aW5nIHRvOicsIGF1dGhVcmwpO1xuXG4gICAgLy8gVXNlIHdpbmRvdy5sb2NhdGlvbi5hc3NpZ24gdG8gcmVkaXJlY3RcbiAgICB3aW5kb3cubG9jYXRpb24uYXNzaWduKGF1dGhVcmwpO1xuICB9XG59XG4iXX0=","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXCExternalAuthorizationService } from './external-authorization.service';\nimport * as i0 from \"@angular/core\";\nexport class AXCUtilsModule {\n static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"20.1.4\", ngImport: i0, type: AXCUtilsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }\n static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: \"14.0.0\", version: \"20.1.4\", ngImport: i0, type: AXCUtilsModule, imports: [CommonModule] }); }\n static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: \"12.0.0\", version: \"20.1.4\", ngImport: i0, type: AXCUtilsModule, providers: [AXCExternalAuthorizationService], imports: [CommonModule] }); }\n}\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"20.1.4\", ngImport: i0, type: AXCUtilsModule, decorators: [{\n type: NgModule,\n args: [{\n imports: [CommonModule],\n providers: [AXCExternalAuthorizationService],\n }]\n }] });\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidXRpbHMubW9kdWxlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vbGlicy9jb25uZWN0aXZpdHkvdXRpbHMvc3JjL2xpYi91dGlscy5tb2R1bGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFlBQVksRUFBRSxNQUFNLGlCQUFpQixDQUFDO0FBQy9DLE9BQU8sRUFBRSxRQUFRLEVBQUUsTUFBTSxlQUFlLENBQUM7QUFDekMsT0FBTyxFQUFFLCtCQUErQixFQUFFLE1BQU0sa0NBQWtDLENBQUM7O0FBTW5GLE1BQU0sT0FBTyxjQUFjOzhHQUFkLGNBQWM7K0dBQWQsY0FBYyxZQUhmLFlBQVk7K0dBR1gsY0FBYyxhQUZkLENBQUMsK0JBQStCLENBQUMsWUFEbEMsWUFBWTs7MkZBR1gsY0FBYztrQkFKMUIsUUFBUTttQkFBQztvQkFDUixPQUFPLEVBQUUsQ0FBQyxZQUFZLENBQUM7b0JBQ3ZCLFNBQVMsRUFBRSxDQUFDLCtCQUErQixDQUFDO2lCQUM3QyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IENvbW1vbk1vZHVsZSB9IGZyb20gJ0Bhbmd1bGFyL2NvbW1vbic7XG5pbXBvcnQgeyBOZ01vZHVsZSB9IGZyb20gJ0Bhbmd1bGFyL2NvcmUnO1xuaW1wb3J0IHsgQVhDRXh0ZXJuYWxBdXRob3JpemF0aW9uU2VydmljZSB9IGZyb20gJy4vZXh0ZXJuYWwtYXV0aG9yaXphdGlvbi5zZXJ2aWNlJztcblxuQE5nTW9kdWxlKHtcbiAgaW1wb3J0czogW0NvbW1vbk1vZHVsZV0sXG4gIHByb3ZpZGVyczogW0FYQ0V4dGVybmFsQXV0aG9yaXphdGlvblNlcnZpY2VdLFxufSlcbmV4cG9ydCBjbGFzcyBBWENVdGlsc01vZHVsZSB7fVxuIl19","/**\n * Generated bundle index. Do not edit.\n */\nexport * from './index';\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWNvcmV4LWNvbm5lY3Rpdml0eS11dGlscy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL2xpYnMvY29ubmVjdGl2aXR5L3V0aWxzL3NyYy9hY29yZXgtY29ubmVjdGl2aXR5LXV0aWxzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBRUgsY0FBYyxTQUFTLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEdlbmVyYXRlZCBidW5kbGUgaW5kZXguIERvIG5vdCBlZGl0LlxuICovXG5cbmV4cG9ydCAqIGZyb20gJy4vaW5kZXgnO1xuIl19"],"names":[],"mappings":";;;;;;AAIO,MAAM,+BAA+B,CAAC;AAC7C,IAAI,WAAW,GAAG;AAClB,QAAQ,IAAI,CAAC,OAAO,GAAG,MAAM,CAAC,qBAAqB,CAAC;AACpD;AACA,IAAI,MAAM,MAAM,CAAC,YAAY,EAAE;AAC/B;AACA,QAAQ,MA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AI,CAAC,IAAI,GAAG,EAAE,CAAC,mBAAmB,CAAC,EAAE,UAAU,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,cAAc,EAAE,SAAS,EAAE,CAAC,+BAA+B,CAAC,EAAE,OAAO,EAAE,CAAC,YAAY,CAAC,EAAE,CAAC,CAAC;AACxM;AACA,EAAE,CAAC,wBAAwB,CAAC,EAAE,UAAU,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,cAAc,EAAE,UAAU,EAAE,CAAC;AACxH,YAAY,IAAI,EAAE,QAAQ;AAC1B,YAAY,IAAI,EAAE,CAAC;AACnB,oBAAoB,OAAO,EAAE,CAAC,YAAY,CAAC;AAC3C,oBAAoB,SAAS,EAAE,CAAC,+BAA+B,CAAC;AAChE,iBAAiB;AACjB,SAAS,CAAC,EAAE,CAAC;;ACfb;AACA;AACA;;;;"}
|
package/mock/index.d.ts
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import { AXPDataSeeder, AXPEntityStorageService, AXPEntityDefinitionRegistryService } from '@acorex/platform/layout/entity';
|
|
1
|
+
import { AXPDataSeeder, AXPEntityStorageService, AXPEntityDefinitionRegistryService, AXPEntityStorageWithMiddlewareService } from '@acorex/platform/layout/entity';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
3
|
import { Injector } from '@angular/core';
|
|
4
4
|
import { AXPLockService, AXPLockRequest, AXPLockInfo, AXPUnLockRequest, AXPLockGetInfoRequest, AXPFileStorageService, AXPFileStorageCreateRequest, AXPFileStorageInfo, AXPFileStorageUpdateRequest, AXPFileStorageFindRequest, AXPReportCategory, AXPReportDefinition, AXPExecutionReportCommand, AXPLayoutExecutionContext, AXPExecutionReportCommandResult } from '@acorex/platform/common';
|
|
5
5
|
import { AXMCommonDashboardEntityModel } from '@acorex/modules/dashboard-management';
|
|
6
|
-
import
|
|
6
|
+
import { AXPEntityEventDispatcherService, AXPQueryRequest, AXPPagedListResult, AXPAppStartUpService } from '@acorex/platform/core';
|
|
7
|
+
import * as dexie from 'dexie';
|
|
8
|
+
import dexie__default from 'dexie';
|
|
7
9
|
import * as _acorex_platform_auth from '@acorex/platform/auth';
|
|
8
10
|
import { AXPSessionService, AXPAuthStrategy, AXPBaseCredentials, AXPSessionContext, AXPSignInResult } from '@acorex/platform/auth';
|
|
9
|
-
import { AXPQueryRequest, AXPPagedListResult, AXPAppStartUpService } from '@acorex/platform/core';
|
|
10
11
|
import { AXMAuthConfigs } from '@acorex/modules/auth';
|
|
11
12
|
import { Router } from '@angular/router';
|
|
12
13
|
import * as i1 from '@acorex/platform/runtime';
|
|
@@ -176,8 +177,9 @@ declare class AXMAiResponderService {
|
|
|
176
177
|
declare class AXPMessageDataSeeder implements AXPDataSeeder {
|
|
177
178
|
private storageService;
|
|
178
179
|
private chatService;
|
|
180
|
+
private chatRealtimeService;
|
|
179
181
|
private commentService;
|
|
180
|
-
private
|
|
182
|
+
private commentRealtimeService;
|
|
181
183
|
private aiResponderService;
|
|
182
184
|
private usersService;
|
|
183
185
|
private sessionService;
|
|
@@ -223,10 +225,11 @@ declare class AXCDataManagementMockModule {
|
|
|
223
225
|
static ɵinj: i0.ɵɵInjectorDeclaration<AXCDataManagementMockModule>;
|
|
224
226
|
}
|
|
225
227
|
|
|
226
|
-
declare class AXPDexieEntityStorageService extends
|
|
228
|
+
declare class AXPDexieEntityStorageService extends dexie__default implements AXPEntityStorageService<string, any> {
|
|
227
229
|
protected sessionService: AXPSessionService;
|
|
228
230
|
protected entityRegistryService: AXPEntityDefinitionRegistryService;
|
|
229
231
|
protected lockService: AXPLockService;
|
|
232
|
+
protected entityEventDispatcher: AXPEntityEventDispatcherService;
|
|
230
233
|
constructor();
|
|
231
234
|
get dbName(): string;
|
|
232
235
|
private detectChanges;
|
|
@@ -311,6 +314,18 @@ declare class AXCReportManagementMockModule {
|
|
|
311
314
|
static ɵinj: i0.ɵɵInjectorDeclaration<AXCReportManagementMockModule>;
|
|
312
315
|
}
|
|
313
316
|
|
|
317
|
+
declare class AXCLocationManagementMockModule {
|
|
318
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXCLocationManagementMockModule, never>;
|
|
319
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<AXCLocationManagementMockModule, never, never, never>;
|
|
320
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<AXCLocationManagementMockModule>;
|
|
321
|
+
}
|
|
322
|
+
|
|
323
|
+
declare class AXCLocaleManagementMockModule {
|
|
324
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXCLocaleManagementMockModule, never>;
|
|
325
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<AXCLocaleManagementMockModule, never, never, never>;
|
|
326
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<AXCLocaleManagementMockModule>;
|
|
327
|
+
}
|
|
328
|
+
|
|
314
329
|
declare class AXCPlatformManagementMockModule {
|
|
315
330
|
static ɵfac: i0.ɵɵFactoryDeclaration<AXCPlatformManagementMockModule, never>;
|
|
316
331
|
static ɵmod: i0.ɵɵNgModuleDeclaration<AXCPlatformManagementMockModule, never, never, never>;
|
|
@@ -353,16 +368,28 @@ declare class AXMCalendarManagementMockModule {
|
|
|
353
368
|
static ɵinj: i0.ɵɵInjectorDeclaration<AXMCalendarManagementMockModule>;
|
|
354
369
|
}
|
|
355
370
|
|
|
371
|
+
declare class AXCWorkflowManagementMockModule {
|
|
372
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXCWorkflowManagementMockModule, never>;
|
|
373
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<AXCWorkflowManagementMockModule, never, never, never>;
|
|
374
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<AXCWorkflowManagementMockModule>;
|
|
375
|
+
}
|
|
376
|
+
|
|
356
377
|
declare class AXCNotificationManagementMockModule {
|
|
357
378
|
static ɵfac: i0.ɵɵFactoryDeclaration<AXCNotificationManagementMockModule, never>;
|
|
358
379
|
static ɵmod: i0.ɵɵNgModuleDeclaration<AXCNotificationManagementMockModule, never, never, never>;
|
|
359
380
|
static ɵinj: i0.ɵɵInjectorDeclaration<AXCNotificationManagementMockModule>;
|
|
360
381
|
}
|
|
361
382
|
|
|
383
|
+
declare class AXCTaskManagementMockModule {
|
|
384
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXCTaskManagementMockModule, never>;
|
|
385
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<AXCTaskManagementMockModule, never, never, never>;
|
|
386
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<AXCTaskManagementMockModule>;
|
|
387
|
+
}
|
|
388
|
+
|
|
362
389
|
declare class AXCMockModule {
|
|
363
390
|
constructor(appInitService: AXPAppStartUpService, injector: Injector);
|
|
364
391
|
static ɵfac: i0.ɵɵFactoryDeclaration<AXCMockModule, never>;
|
|
365
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<AXCMockModule, never, [typeof _acorex_platform_auth.AXPAuthModule, typeof AXCCommonMockModule, typeof AXCFormTemplateManagementMockModule, typeof AXCFOrganizationManagementMockModule, typeof AXCReportManagementMockModule, typeof AXCContactManagementMockModule, typeof AXCDashboardManagementMockModule, typeof AXCConversationMockModule, typeof AXCAuthMockModule, typeof AXCPlatformManagementMockModule, typeof AXCTextTemplateManagementMockModule, typeof AXCSecurityManagementMockModule, typeof AXCSchedulerJobManagementMockModule, typeof AXCApplicationManagementMockModule, typeof AXCTrainingManagementMockModule, typeof AXCProjectManagementMockModule, typeof AXCDocumentManagementMockModule, typeof AXCIssueManagementMockModule, typeof AXCLogManagementMockModule, typeof AXMCalendarManagementMockModule, typeof AXCDataManagementMockModule, typeof AXCNotificationManagementMockModule], never>;
|
|
392
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<AXCMockModule, never, [typeof _acorex_platform_auth.AXPAuthModule, typeof AXCCommonMockModule, typeof AXCFormTemplateManagementMockModule, typeof AXCFOrganizationManagementMockModule, typeof AXCReportManagementMockModule, typeof AXCContactManagementMockModule, typeof AXCLocationManagementMockModule, typeof AXCLocaleManagementMockModule, typeof AXCDashboardManagementMockModule, typeof AXCConversationMockModule, typeof AXCAuthMockModule, typeof AXCPlatformManagementMockModule, typeof AXCTextTemplateManagementMockModule, typeof AXCSecurityManagementMockModule, typeof AXCSchedulerJobManagementMockModule, typeof AXCApplicationManagementMockModule, typeof AXCTrainingManagementMockModule, typeof AXCProjectManagementMockModule, typeof AXCDocumentManagementMockModule, typeof AXCIssueManagementMockModule, typeof AXCLogManagementMockModule, typeof AXMCalendarManagementMockModule, typeof AXCDataManagementMockModule, typeof AXCWorkflowManagementMockModule, typeof AXCNotificationManagementMockModule, typeof AXCTaskManagementMockModule], never>;
|
|
366
393
|
static ɵinj: i0.ɵɵInjectorDeclaration<AXCMockModule>;
|
|
367
394
|
}
|
|
368
395
|
|
|
@@ -487,6 +514,79 @@ declare class AXPSecurityManagementUserDataSeeder implements AXPDataSeeder {
|
|
|
487
514
|
static ɵprov: i0.ɵɵInjectableDeclaration<AXPSecurityManagementUserDataSeeder>;
|
|
488
515
|
}
|
|
489
516
|
|
|
517
|
+
interface TaskType {
|
|
518
|
+
id: string;
|
|
519
|
+
name: string;
|
|
520
|
+
title: string;
|
|
521
|
+
description: string;
|
|
522
|
+
icon: string;
|
|
523
|
+
color: string;
|
|
524
|
+
isActive: boolean;
|
|
525
|
+
order: number;
|
|
526
|
+
features: string[];
|
|
527
|
+
workflowSteps: string[];
|
|
528
|
+
estimatedHours: number;
|
|
529
|
+
priority: string;
|
|
530
|
+
category: string;
|
|
531
|
+
}
|
|
532
|
+
declare const TASK_TYPES: TaskType[];
|
|
533
|
+
interface TaskStatus {
|
|
534
|
+
id: string;
|
|
535
|
+
taskTypeId: string;
|
|
536
|
+
name: string;
|
|
537
|
+
title: string;
|
|
538
|
+
description: string;
|
|
539
|
+
color: string;
|
|
540
|
+
icon: string;
|
|
541
|
+
isInitial: boolean;
|
|
542
|
+
isFinal: boolean;
|
|
543
|
+
order: number;
|
|
544
|
+
nextStatuses: string[];
|
|
545
|
+
isActive: boolean;
|
|
546
|
+
}
|
|
547
|
+
declare const TASK_STATUSES: TaskStatus[];
|
|
548
|
+
interface Task {
|
|
549
|
+
id: string;
|
|
550
|
+
title: string;
|
|
551
|
+
description: string;
|
|
552
|
+
taskTypeId: string;
|
|
553
|
+
taskStatusId: string;
|
|
554
|
+
priority: string;
|
|
555
|
+
estimatedHours: number;
|
|
556
|
+
actualHours: number;
|
|
557
|
+
startDate: Date;
|
|
558
|
+
dueDate: Date;
|
|
559
|
+
completedDate?: Date;
|
|
560
|
+
assignedToUserId: string;
|
|
561
|
+
createdByUserId: string;
|
|
562
|
+
tags: string[];
|
|
563
|
+
progress: number;
|
|
564
|
+
isActive: boolean;
|
|
565
|
+
}
|
|
566
|
+
declare const TASKS: Task[];
|
|
567
|
+
interface TaskTemplate {
|
|
568
|
+
id: string;
|
|
569
|
+
name: string;
|
|
570
|
+
title: string;
|
|
571
|
+
description: string;
|
|
572
|
+
taskTypeId: string;
|
|
573
|
+
templateData: {
|
|
574
|
+
title: string;
|
|
575
|
+
description: string;
|
|
576
|
+
estimatedHours: number;
|
|
577
|
+
priority: string;
|
|
578
|
+
tags: string[];
|
|
579
|
+
checklistItems: Array<{
|
|
580
|
+
title: string;
|
|
581
|
+
description?: string;
|
|
582
|
+
order: number;
|
|
583
|
+
}>;
|
|
584
|
+
};
|
|
585
|
+
isPublic: boolean;
|
|
586
|
+
createdBy: string;
|
|
587
|
+
}
|
|
588
|
+
declare const TASK_TEMPLATES: TaskTemplate[];
|
|
589
|
+
|
|
490
590
|
declare class AXCTextTemplateCategoryDataSeeder implements AXPDataSeeder {
|
|
491
591
|
private storageService;
|
|
492
592
|
seed(): Promise<void>;
|
|
@@ -508,5 +608,90 @@ declare const TEXT_TEMPLATE_CATEGORY: {
|
|
|
508
608
|
}[];
|
|
509
609
|
declare const TEXT_TEMPLATES: AXMTextTemplateManagementTemplateEntityModel[];
|
|
510
610
|
|
|
511
|
-
|
|
512
|
-
|
|
611
|
+
/**
|
|
612
|
+
* Simplified Dexie Storage Service without built-in middleware logic
|
|
613
|
+
* This extends the original service but removes the middleware-related code
|
|
614
|
+
*/
|
|
615
|
+
declare class AXPSimplifiedDexieStorageService extends AXPDexieEntityStorageService {
|
|
616
|
+
updateOne<T = any>(entityName: string, id: string, keyValue: {
|
|
617
|
+
[key: string]: any;
|
|
618
|
+
}): Promise<T>;
|
|
619
|
+
deleteOne(entityName: string, id: string): Promise<void>;
|
|
620
|
+
insertOne<T = any>(entityName: string, entity: T): Promise<string>;
|
|
621
|
+
private generateUuid;
|
|
622
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXPSimplifiedDexieStorageService, never>;
|
|
623
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<AXPSimplifiedDexieStorageService>;
|
|
624
|
+
}
|
|
625
|
+
/**
|
|
626
|
+
* Dexie Entity Storage Service with Middleware Support
|
|
627
|
+
*
|
|
628
|
+
* This service combines the simplified Dexie storage with a comprehensive middleware pipeline
|
|
629
|
+
* that handles locking, history logging, activity tracking, validation, and performance monitoring.
|
|
630
|
+
*/
|
|
631
|
+
declare class AXPDexieWithMiddlewareService extends AXPEntityStorageWithMiddlewareService<string, any> {
|
|
632
|
+
private sessionService;
|
|
633
|
+
private lockService;
|
|
634
|
+
private entityRegistryService;
|
|
635
|
+
private eventService;
|
|
636
|
+
constructor();
|
|
637
|
+
private setupMiddlewares;
|
|
638
|
+
/**
|
|
639
|
+
* Get the underlying Dexie instance for direct access if needed
|
|
640
|
+
*/
|
|
641
|
+
get dexieInstance(): AXPSimplifiedDexieStorageService;
|
|
642
|
+
/**
|
|
643
|
+
* Access to the Dexie table for advanced operations
|
|
644
|
+
*/
|
|
645
|
+
table(name: string): dexie.Table<any, dexie.IndexableType>;
|
|
646
|
+
/**
|
|
647
|
+
* Get database information
|
|
648
|
+
*/
|
|
649
|
+
getDatabaseInfo(): {
|
|
650
|
+
name: string;
|
|
651
|
+
isOpen: boolean;
|
|
652
|
+
version: number;
|
|
653
|
+
};
|
|
654
|
+
/**
|
|
655
|
+
* Clear all data for a specific entity (useful for testing)
|
|
656
|
+
*/
|
|
657
|
+
clearEntity(entityName: string): Promise<void>;
|
|
658
|
+
/**
|
|
659
|
+
* Get entity count
|
|
660
|
+
*/
|
|
661
|
+
getEntityCount(entityName: string): Promise<number>;
|
|
662
|
+
/**
|
|
663
|
+
* Bulk operations (bypassing some middleware for performance)
|
|
664
|
+
*/
|
|
665
|
+
bulkInsert<T = any>(entityName: string, entities: T[]): Promise<string[]>;
|
|
666
|
+
/**
|
|
667
|
+
* Export entity data (useful for backup/migration)
|
|
668
|
+
*/
|
|
669
|
+
exportEntity(entityName: string): Promise<any[]>;
|
|
670
|
+
/**
|
|
671
|
+
* Import entity data (useful for restore/migration)
|
|
672
|
+
*/
|
|
673
|
+
importEntity(entityName: string, data: any[], options?: {
|
|
674
|
+
clearFirst?: boolean;
|
|
675
|
+
}): Promise<void>;
|
|
676
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXPDexieWithMiddlewareService, never>;
|
|
677
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<AXPDexieWithMiddlewareService>;
|
|
678
|
+
}
|
|
679
|
+
/**
|
|
680
|
+
* Factory function to create a configured Dexie service with standard middleware
|
|
681
|
+
*/
|
|
682
|
+
declare function createDexieWithStandardMiddleware(): AXPDexieWithMiddlewareService;
|
|
683
|
+
/**
|
|
684
|
+
* Factory function to create a configured Dexie service with custom middleware
|
|
685
|
+
*/
|
|
686
|
+
declare function createDexieWithCustomMiddleware(customMiddlewares?: {
|
|
687
|
+
global?: any[];
|
|
688
|
+
operations?: {
|
|
689
|
+
[operation: string]: any[];
|
|
690
|
+
};
|
|
691
|
+
entities?: {
|
|
692
|
+
[entityName: string]: any[];
|
|
693
|
+
};
|
|
694
|
+
}): AXPDexieWithMiddlewareService;
|
|
695
|
+
|
|
696
|
+
export { APPLICATIONS, APPLICATIONS_MODULES, AXCAppTermDataSeeder, AXCAppVersionDataSeeder, AXCApplicationManagementMockModule, AXCApplicationTemplateDataSeeder, AXCAuthMockModule, AXCCommonMockModule, AXCContactManagementMockModule, AXCConversationMockModule, AXCDashboardManagementMockModule, AXCDataManagementMockModule, AXCDocumentManagementMockModule, AXCFOrganizationManagementMockModule, AXCFileStorageService, AXCFormTemplateManagementMockModule, AXCGlobalVariablesDataSeeder, AXCIssueManagementMockModule, AXCLocaleManagementMockModule, AXCLocationManagementMockModule, AXCLockService, AXCLogManagementMockModule, AXCMetaDataDefinitionDataSeeder, AXCMockModule, AXCNotificationManagementMockModule, AXCPlatformManagementMockModule, AXCProjectManagementMockModule, AXCReportManagementMockModule, AXCSchedulerJobDataSeeder, AXCSchedulerJobManagementMockModule, AXCSecurityManagementMockModule, AXCTaskManagementMockModule, AXCTextTemplateCategoryDataSeeder, AXCTextTemplateDataSeeder, AXCTextTemplateManagementMockModule, AXCTrainingManagementMockModule, AXMAiResponderService, AXMReportExecuteCommand, AXPDashboardDataSeeder, AXPDexieEntityStorageService, AXPDexieWithMiddlewareService, AXPMessageDataSeeder, AXPReportManagementDataSeeder, AXPRoomDataSeeder, AXPSecurityManagementRoleDataSeeder, AXPSecurityManagementUserDataSeeder, AXPSimplifiedDexieStorageService, CATEGORY_REPORT_MAPPING, DASHBOARDS, EDITIONS, ENTITIES, FEATURES, GLOBAL_VARIABLES, MOCKGoogleStrategy, MOCKStrategy, MODULES, PERMISSIONS, PROPERTIES, REPORT_CATEGORIES, REPORT_DEFINITIONS, TASKS, TASK_STATUSES, TASK_TEMPLATES, TASK_TYPES, TEXT_TEMPLATES, TEXT_TEMPLATE_CATEGORY, createDexieWithCustomMiddleware, createDexieWithStandardMiddleware, generateRandomDashboard };
|
|
697
|
+
export type { MockUserPassCredentials, Task, TaskStatus, TaskTemplate, TaskType };
|