@equinor/fusion-framework-cli 10.0.3 → 10.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +18 -0
- package/dist/bin/create-dev-serve.js +1 -0
- package/dist/bin/create-dev-serve.js.map +1 -1
- package/dist/bin/public/assets/index-VsB-fOGc.js +4628 -0
- package/dist/bin/public/index.html +1 -1
- package/dist/lib/plugins/app-assets/app-asset-plugin.js +4 -4
- package/dist/lib/plugins/app-assets/app-asset-plugin.js.map +1 -1
- package/dist/lib/plugins/app-proxy/app-proxy-plugin.js +6 -5
- package/dist/lib/plugins/app-proxy/app-proxy-plugin.js.map +1 -1
- package/dist/types/lib/plugins/app-proxy/app-proxy-plugin.d.ts +18 -0
- package/dist/types/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +14 -14
- package/dist/bin/public/assets/index-D0eBBcR8.js +0 -5235
|
@@ -54,18 +54,18 @@ export const AppAssetExportPlugin = (options = {}) => {
|
|
|
54
54
|
configResolved(config) {
|
|
55
55
|
viteConfig = config;
|
|
56
56
|
},
|
|
57
|
-
resolveId(
|
|
58
|
-
return __awaiter(this,
|
|
57
|
+
resolveId(source, importer, opts) {
|
|
58
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
59
59
|
var _a;
|
|
60
60
|
if (viteConfig.build.lib === false) {
|
|
61
|
-
this.warn(
|
|
61
|
+
this.warn('this plugin is only for vite build lib');
|
|
62
62
|
}
|
|
63
63
|
// skip resolves triggered by plugin self
|
|
64
64
|
if (((_a = opts.custom) === null || _a === void 0 ? void 0 : _a.caller) === PLUGIN_NAME) {
|
|
65
65
|
return null;
|
|
66
66
|
}
|
|
67
67
|
// resolve asset ID, the ID should refer to the actual asset file
|
|
68
|
-
const assetId = yield resolveAssetId(this, source, importer, Object.assign(Object.assign({}, opts), { custom: Object.assign(Object.assign({}, opts.custom), { caller: PLUGIN_NAME }) }));
|
|
68
|
+
const assetId = yield resolveAssetId(this, source, importer !== null && importer !== void 0 ? importer : '', Object.assign(Object.assign({}, opts), { custom: Object.assign(Object.assign({}, opts.custom), { caller: PLUGIN_NAME }) }));
|
|
69
69
|
// skip if asset is not found or filtered out
|
|
70
70
|
const { id } = assetId !== null && assetId !== void 0 ? assetId : {};
|
|
71
71
|
const shouldIncludeAsset = id && filter(id);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"app-asset-plugin.js","sourceRoot":"","sources":["../../../../src/lib/plugins/app-assets/app-asset-plugin.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,YAAY,EAAwD,MAAM,MAAM,CAAC;AAE1F,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,4BAA4B,EAAE,MAAM,+BAA+B,CAAC;AAE7E,OAAO,EAAE,gBAAgB,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"app-asset-plugin.js","sourceRoot":"","sources":["../../../../src/lib/plugins/app-assets/app-asset-plugin.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,YAAY,EAAwD,MAAM,MAAM,CAAC;AAE1F,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,4BAA4B,EAAE,MAAM,+BAA+B,CAAC;AAE7E,OAAO,EAAE,gBAAgB,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAG5D,MAAM,cAAc,GAAG,4BAA4B,CAAC,gBAAgB,CAAC,CAAC;AAEtE;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAChC,UAII,EAAE,EACA,EAAE;IACR,MAAM,EAAE,IAAI,EAAE,OAAO,GAAG,cAAc,EAAE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,GAAG,aAAa,CAAC,IAAqB,EAAE,EAAE,EAAE;wBACvD,IAAI;wBACJ,MAAM;wBACN,SAAS;qBACZ,CAAC,CAAC;oBACH,aAAa,CAAC,GAAG,CAAC,EAAE,EAAE,SAAU,CAAC,CAAC;gBACtC,CAAC;gBAAC,OAAO,GAAG,EAAE,CAAC;oBACX,IAAI,CAAC,IAAI,CAAE,GAAa,CAAC,OAAO,CAAC,CAAC;oBAClC,OAAO,IAAI,CAAC;gBAChB,CAAC;YACL,CAAC;SAAA;QACD,IAAI,CAAC,EAAE;YACH,sCAAsC;YACtC,MAAM,SAAS,GAAG,aAAa,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;YACxC,IAAI,SAAS,EAAE,CAAC;gBACZ,0DAA0D;gBAC1D,OAAO,6CAA6C,SAAS,0BAA0B,CAAC;YAC5F,CAAC;QACL,CAAC;KACJ,CAAC;AACN,CAAC,CAAC;AAEF,eAAe,oBAAoB,CAAC"}
|
|
@@ -7,6 +7,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
7
7
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
|
+
import { join } from 'node:path';
|
|
10
11
|
/**
|
|
11
12
|
* Preserve token for executing proxy assets
|
|
12
13
|
*
|
|
@@ -93,25 +94,25 @@ export const appProxyPlugin = (options) => {
|
|
|
93
94
|
};
|
|
94
95
|
},
|
|
95
96
|
configureServer(server) {
|
|
97
|
+
var _a, _b, _c;
|
|
96
98
|
const { app } = options;
|
|
97
99
|
// disable local assets if no app configuration provided
|
|
98
100
|
if (!app)
|
|
99
101
|
return;
|
|
100
102
|
// serve app config if request matches the current app and version
|
|
101
|
-
const configPath =
|
|
103
|
+
const configPath = join(proxyPath, (_a = app.configPath) !== null && _a !== void 0 ? _a : `apps/${app.key}/builds/${app.version}/config`);
|
|
102
104
|
server.middlewares.use(configPath, (_req, res) => __awaiter(this, void 0, void 0, function* () {
|
|
103
105
|
res.setHeader('content-type', 'application/json');
|
|
104
106
|
res.end(JSON.stringify(yield app.generateConfig()));
|
|
105
107
|
}));
|
|
106
108
|
// serve app manifest if request matches the current app
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
server.middlewares.use(manifestPath, (_req, res) => __awaiter(this, void 0, void 0, function* () {
|
|
109
|
+
const manifestPath = join(proxyPath, (_b = app.manifestPath) !== null && _b !== void 0 ? _b : `apps/${app.key}`);
|
|
110
|
+
server.middlewares.use([proxyPath, manifestPath, app.key].join('/'), (_req, res) => __awaiter(this, void 0, void 0, function* () {
|
|
110
111
|
res.setHeader('content-type', 'application/json');
|
|
111
112
|
res.end(JSON.stringify(yield app.generateManifest()));
|
|
112
113
|
}));
|
|
113
114
|
// serve local bundles if request matches the current app and version
|
|
114
|
-
const bundlePath =
|
|
115
|
+
const bundlePath = join(proxyPath, (_c = app.bundlePath) !== null && _c !== void 0 ? _c : `bundles/apps/${app.key}/${app.version}`);
|
|
115
116
|
server.middlewares.use((req, _res, next) => __awaiter(this, void 0, void 0, function* () {
|
|
116
117
|
var _a;
|
|
117
118
|
if ((_a = req.url) === null || _a === void 0 ? void 0 : _a.match(bundlePath)) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"app-proxy-plugin.js","sourceRoot":"","sources":["../../../../src/lib/plugins/app-proxy/app-proxy-plugin.ts"],"names":[],"mappings":";;;;;;;;;
|
|
1
|
+
{"version":3,"file":"app-proxy-plugin.js","sourceRoot":"","sources":["../../../../src/lib/plugins/app-proxy/app-proxy-plugin.ts"],"names":[],"mappings":";;;;;;;;;AAOA,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEjC;;;;;;;;;;;;;;GAcG;AACH,IAAI,iBAAiB,GAAG,EAAE,CAAC;AAqD3B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AACH,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,OAA8B,EAAU,EAAE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G,CAAC,GAAG,0CAAE,KAAK,CAAC,UAAU,CAAC,EAAE,CAAC;oBAC7B,6BAA6B;oBAC7B,GAAG,CAAC,GAAG,GAAG,GAAG,CAAC,GAAI,CAAC,OAAO,CAAC,UAAU,EAAE,EAAE,CAAC,CAAC;gBAC/C,CAAC;gBACD,IAAI,EAAE,CAAC;YACX,CAAC,CAAA,CAAC,CAAC;QACP,CAAC;KACJ,CAAC;AACN,CAAC,CAAC;AAEF,eAAe,cAAc,CAAC"}
|
|
@@ -26,8 +26,26 @@ export type AppProxyPluginOptions = {
|
|
|
26
26
|
version: string;
|
|
27
27
|
/** callback function for generating configuration for the application */
|
|
28
28
|
generateConfig: () => Promise<ApiAppConfig>;
|
|
29
|
+
/**
|
|
30
|
+
* string path to the app config
|
|
31
|
+
* @example `persons/me/apps/${app.key}/builds/${app.version}/config`
|
|
32
|
+
* @default `apps/${app.key}/builds/${app.version}/config`
|
|
33
|
+
*/
|
|
34
|
+
configPath?: string;
|
|
29
35
|
/** callback function for generating manifest for the application */
|
|
30
36
|
generateManifest: () => Promise<AppManifest>;
|
|
37
|
+
/**
|
|
38
|
+
* string path to the app manifest
|
|
39
|
+
* @example `persons/me/apps/${app.key}`
|
|
40
|
+
* @default `apps/${app.key}`
|
|
41
|
+
*/
|
|
42
|
+
manifestPath?: string;
|
|
43
|
+
/**
|
|
44
|
+
* string path to the app bundle
|
|
45
|
+
* @default `bundles/apps/${app.key}/${app.version}`
|
|
46
|
+
* @example `bundles/apps/${app.key}/${app.version}`
|
|
47
|
+
*/
|
|
48
|
+
bundlePath?: string;
|
|
31
49
|
};
|
|
32
50
|
};
|
|
33
51
|
/**
|
package/dist/types/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const version = "10.0
|
|
1
|
+
export declare const version = "10.1.0";
|
package/dist/version.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@equinor/fusion-framework-cli",
|
|
3
|
-
"version": "10.0
|
|
3
|
+
"version": "10.1.0",
|
|
4
4
|
"keywords": [
|
|
5
5
|
"Fusion",
|
|
6
6
|
"Fusion Framework",
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
"zod": "^3.23.8"
|
|
59
59
|
},
|
|
60
60
|
"devDependencies": {
|
|
61
|
-
"@equinor/eds-core-react": "^0.
|
|
61
|
+
"@equinor/eds-core-react": "^0.42.3",
|
|
62
62
|
"@equinor/eds-icons": "^0.21.0",
|
|
63
63
|
"@equinor/eds-tokens": "^0.9.2",
|
|
64
64
|
"@equinor/eslint-config-fusion-react": "^2.0.1",
|
|
@@ -84,21 +84,21 @@
|
|
|
84
84
|
"rxjs": "^7.8.1",
|
|
85
85
|
"styled-components": "^6.0.7",
|
|
86
86
|
"typescript": "^5.5.4",
|
|
87
|
-
"@equinor/fusion-framework": "^
|
|
88
|
-
"@equinor/fusion-framework
|
|
89
|
-
"@equinor/fusion-framework-app": "^9.1.
|
|
90
|
-
"@equinor/fusion-framework-module-
|
|
87
|
+
"@equinor/fusion-framework-module-app": "^6.0.2",
|
|
88
|
+
"@equinor/fusion-framework": "^7.2.9",
|
|
89
|
+
"@equinor/fusion-framework-app": "^9.1.12",
|
|
90
|
+
"@equinor/fusion-framework-module-context": "^5.0.13",
|
|
91
|
+
"@equinor/fusion-framework-module-feature-flag": "^1.1.10",
|
|
91
92
|
"@equinor/fusion-framework-module-msal": "^3.1.5",
|
|
92
|
-
"@equinor/fusion-framework-module-
|
|
93
|
+
"@equinor/fusion-framework-module-bookmark": "^1.2.13",
|
|
93
94
|
"@equinor/fusion-framework-module-navigation": "^4.0.7",
|
|
94
95
|
"@equinor/fusion-framework-module-services": "^4.1.5",
|
|
95
|
-
"@equinor/fusion-framework-
|
|
96
|
-
"@equinor/fusion-framework-react": "^
|
|
97
|
-
"@equinor/fusion-
|
|
98
|
-
"@equinor/fusion-framework-react-
|
|
99
|
-
"@equinor/fusion-
|
|
100
|
-
"@equinor/fusion-query": "^5.1.
|
|
101
|
-
"@equinor/fusion-framework-react-module-bookmark": "^2.1.18"
|
|
96
|
+
"@equinor/fusion-framework-react-components-bookmark": "^0.5.3",
|
|
97
|
+
"@equinor/fusion-framework-react-components-people-provider": "^1.4.10",
|
|
98
|
+
"@equinor/fusion-observable": "^8.4.2",
|
|
99
|
+
"@equinor/fusion-framework-react-module-bookmark": "^2.1.19",
|
|
100
|
+
"@equinor/fusion-framework-react": "^7.3.1",
|
|
101
|
+
"@equinor/fusion-query": "^5.1.4"
|
|
102
102
|
},
|
|
103
103
|
"scripts": {
|
|
104
104
|
"prebuild": "pnpm build:source",
|