@equinor/fusion-framework-cli 9.8.2 → 10.0.0-widget-7844194d
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 +53 -4
- package/dist/bin/build-application.js +2 -1
- package/dist/bin/build-application.js.map +1 -1
- package/dist/bin/bundle-application.js +2 -2
- package/dist/bin/bundle-application.js.map +1 -1
- package/dist/bin/bundle-widget.js +61 -0
- package/dist/bin/bundle-widget.js.map +1 -0
- package/dist/bin/create-dev-serve.js +21 -3
- package/dist/bin/create-dev-serve.js.map +1 -1
- package/dist/bin/create-export-manifest-widget.js +68 -0
- package/dist/bin/create-export-manifest-widget.js.map +1 -0
- package/dist/bin/dev-portal/ContextSelector.js +1 -27
- package/dist/bin/dev-portal/ContextSelector.js.map +1 -1
- package/dist/bin/dev-portal/config.js +2 -0
- package/dist/bin/dev-portal/config.js.map +1 -1
- package/dist/bin/dev-proxy.js +13 -3
- package/dist/bin/dev-proxy.js.map +1 -1
- package/dist/bin/main.app.js +8 -2
- package/dist/bin/main.app.js.map +1 -1
- package/dist/bin/main.js +2 -0
- package/dist/bin/main.js.map +1 -1
- package/dist/bin/main.widget.js +78 -0
- package/dist/bin/main.widget.js.map +1 -0
- package/dist/bin/public/assets/{index-_xir6JCw.js → index-UrNngCGF.js} +410 -468
- package/dist/bin/public/index.html +1 -1
- package/dist/bin/utils/load-dev-proxy.js +48 -0
- package/dist/bin/utils/load-dev-proxy.js.map +1 -0
- package/dist/bin/utils/load-widget-manifest.js +35 -0
- package/dist/bin/utils/load-widget-manifest.js.map +1 -0
- package/dist/bin/utils/load-widget-package.js +24 -0
- package/dist/bin/utils/load-widget-package.js.map +1 -0
- package/dist/lib/dev-config.js +9 -0
- package/dist/lib/dev-config.js.map +1 -0
- package/dist/lib/index.js +3 -0
- package/dist/lib/index.js.map +1 -1
- package/dist/lib/utils/config.js.map +1 -1
- package/dist/lib/vite-config.js +5 -2
- package/dist/lib/vite-config.js.map +1 -1
- package/dist/lib/widget-config.js +57 -0
- package/dist/lib/widget-config.js.map +1 -0
- package/dist/lib/widget-manifest.js +73 -0
- package/dist/lib/widget-manifest.js.map +1 -0
- package/dist/lib/widget-package.js +33 -0
- package/dist/lib/widget-package.js.map +1 -0
- package/dist/types/bin/build-application.d.ts +1 -0
- package/dist/types/bin/bundle-application.d.ts +1 -0
- package/dist/types/bin/bundle-widget.d.ts +5 -0
- package/dist/types/bin/create-dev-serve.d.ts +3 -0
- package/dist/types/bin/create-export-manifest-widget.d.ts +20 -0
- package/dist/types/bin/dev-proxy.d.ts +9 -1
- package/dist/types/bin/main.widget.d.ts +3 -0
- package/dist/types/bin/utils/load-dev-proxy.d.ts +3 -0
- package/dist/types/bin/utils/load-widget-manifest.d.ts +8 -0
- package/dist/types/bin/utils/load-widget-package.d.ts +5 -0
- package/dist/types/lib/dev-config.d.ts +13 -0
- package/dist/types/lib/index.d.ts +3 -0
- package/dist/types/lib/utils/config.d.ts +3 -0
- package/dist/types/lib/widget-config.d.ts +26 -0
- package/dist/types/lib/widget-manifest.d.ts +53 -0
- package/dist/types/lib/widget-package.d.ts +23 -0
- package/dist/types/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +15 -14
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
import { type FindConfigOptions, type ResolvedConfig, ConfigExecuterEnv } from './utils/config.js';
|
|
3
|
+
import { RecursivePartial } from './utils/types.js';
|
|
4
|
+
import { AnyARecord } from 'node:dns';
|
|
5
|
+
import { ResolvedWidgetPackage } from './widget-package.js';
|
|
6
|
+
export type WidgetManifest = {
|
|
7
|
+
id: string;
|
|
8
|
+
name: string;
|
|
9
|
+
version: string;
|
|
10
|
+
description?: string;
|
|
11
|
+
maintainers?: string[];
|
|
12
|
+
entryPoint: string;
|
|
13
|
+
assetPath: string;
|
|
14
|
+
};
|
|
15
|
+
export type WidgetConfig = Omit<WidgetManifest, 'id' | 'description' | 'maintainers' | 'version'>;
|
|
16
|
+
export type WidgetEnv<TProps = unknown> = {
|
|
17
|
+
basename?: string;
|
|
18
|
+
manifest?: WidgetManifest;
|
|
19
|
+
props?: TProps;
|
|
20
|
+
};
|
|
21
|
+
export type WidgetProps = Record<PropertyKey, unknown>;
|
|
22
|
+
type Fusion = AnyARecord;
|
|
23
|
+
export type WidgetRenderArgs<TFusion extends Fusion = Fusion, TEnv = WidgetEnv, TProps extends WidgetProps = WidgetProps> = {
|
|
24
|
+
fusion: TFusion;
|
|
25
|
+
env: TEnv;
|
|
26
|
+
props?: TProps;
|
|
27
|
+
};
|
|
28
|
+
export type WidgetScriptModule<TProps extends WidgetProps = WidgetProps> = {
|
|
29
|
+
default: (el: HTMLElement, args: WidgetRenderArgs, props?: TProps) => VoidFunction;
|
|
30
|
+
renderWidget: (el: HTMLElement, args: WidgetRenderArgs, props?: TProps) => VoidFunction;
|
|
31
|
+
renderIcon: (el: HTMLElement, args: WidgetRenderArgs, props?: TProps) => VoidFunction;
|
|
32
|
+
render: (el: HTMLElement, args: WidgetRenderArgs, props?: TProps) => VoidFunction;
|
|
33
|
+
};
|
|
34
|
+
export type WidgetManifestFn = (env: ConfigExecuterEnv, args: {
|
|
35
|
+
base: WidgetManifest;
|
|
36
|
+
}) => WidgetManifest | Promise<WidgetManifest>;
|
|
37
|
+
type FindManifestOptions = FindConfigOptions & {
|
|
38
|
+
file?: string;
|
|
39
|
+
};
|
|
40
|
+
export declare const manifestConfigFilename = "widget.manifest.config";
|
|
41
|
+
export declare const defineWidgetManifest: (fn: WidgetManifestFn) => WidgetManifestFn;
|
|
42
|
+
export declare function assertWidgetManifest(value: WidgetManifest): asserts value;
|
|
43
|
+
export declare const mergeWidgetManifests: (base: RecursivePartial<WidgetManifest>, overrides: RecursivePartial<WidgetManifest>) => WidgetManifest;
|
|
44
|
+
export declare const loadWidgetManifest: (filename?: string) => Promise<import("./utils/config.js").ConfigExecuter<WidgetManifest, import("./utils/config.js").ConfigExecuterArgs>>;
|
|
45
|
+
export declare const resolveManifest: (options?: FindConfigOptions & {
|
|
46
|
+
file?: string;
|
|
47
|
+
}) => Promise<ResolvedConfig<WidgetManifestFn> | void>;
|
|
48
|
+
export declare const createWidgetManifestFromPackage: (pkg: ResolvedWidgetPackage) => WidgetManifest;
|
|
49
|
+
export declare const createWidgetManifest: (env: ConfigExecuterEnv, base: WidgetManifest, options?: FindManifestOptions) => Promise<{
|
|
50
|
+
manifest: WidgetManifest;
|
|
51
|
+
path?: string;
|
|
52
|
+
}>;
|
|
53
|
+
export {};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { PackageJson, type NormalizeOptions as ResolveAppPackageOptions } from 'read-package-up';
|
|
2
|
+
import { WidgetManifest } from './widget-manifest.js';
|
|
3
|
+
export type WidgetPackageJson = PackageJson & {
|
|
4
|
+
manifest?: WidgetManifest;
|
|
5
|
+
};
|
|
6
|
+
type DefinePackageFn = () => WidgetPackageJson | Promise<WidgetPackageJson>;
|
|
7
|
+
type DefinePackageExporter = WidgetPackageJson | DefinePackageFn;
|
|
8
|
+
export interface defineAppPackage {
|
|
9
|
+
(obj: WidgetPackageJson): WidgetPackageJson;
|
|
10
|
+
}
|
|
11
|
+
export interface defineAppPackage {
|
|
12
|
+
(fn: DefinePackageFn): void;
|
|
13
|
+
}
|
|
14
|
+
export type ResolvedWidgetPackage = {
|
|
15
|
+
packageJson: WidgetPackageJson;
|
|
16
|
+
path: string;
|
|
17
|
+
};
|
|
18
|
+
export declare function defineWidgetPackage(fnOrObject: DefinePackageExporter): DefinePackageExporter;
|
|
19
|
+
export declare const resolveWidgetEntryPoint: (packageJson: Pick<PackageJson, 'main' | 'module'>) => string;
|
|
20
|
+
export declare const resolveWidgetKey: (packageJson: Pick<PackageJson, 'name'>) => string;
|
|
21
|
+
export declare const assertPackage: (_pkg: Partial<WidgetPackageJson>) => void;
|
|
22
|
+
export declare const resolveWidgetPackage: (options?: ResolveAppPackageOptions) => Promise<ResolvedWidgetPackage>;
|
|
23
|
+
export default resolveWidgetPackage;
|
package/dist/types/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const version = "9.8.
|
|
1
|
+
export declare const version = "9.8.1";
|
package/dist/version.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const version = '9.8.
|
|
1
|
+
export const version = '9.8.1';
|
|
2
2
|
//# sourceMappingURL=version.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@equinor/fusion-framework-cli",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "10.0.0-widget-7844194d",
|
|
4
4
|
"keywords": [
|
|
5
5
|
"Fusion",
|
|
6
6
|
"Fusion Framework",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"@equinor/eds-core-react": "^0.36.0",
|
|
28
28
|
"@equinor/eds-icons": "^0.21.0",
|
|
29
29
|
"@equinor/eds-tokens": "^0.9.2",
|
|
30
|
-
"@equinor/fusion-wc-person": "^2.
|
|
30
|
+
"@equinor/fusion-wc-person": "^2.5.1",
|
|
31
31
|
"@types/adm-zip": "^0.5.0",
|
|
32
32
|
"@types/semver": "^7.5.0",
|
|
33
33
|
"@vitejs/plugin-react": "^4.0.4",
|
|
@@ -49,10 +49,11 @@
|
|
|
49
49
|
"vite-plugin-environment": "^1.1.3",
|
|
50
50
|
"vite-plugin-restart": "^0.4.0",
|
|
51
51
|
"vite-tsconfig-paths": "^4.2.0",
|
|
52
|
-
"@equinor/fusion-framework-app": "^8.1.
|
|
53
|
-
"@equinor/fusion-observable": "^8.1.5",
|
|
52
|
+
"@equinor/fusion-framework-app": "^8.1.1",
|
|
54
53
|
"@equinor/fusion-framework-module-feature-flag": "^1.0.2",
|
|
55
|
-
"@equinor/fusion-
|
|
54
|
+
"@equinor/fusion-observable": "^8.1.5",
|
|
55
|
+
"@equinor/fusion-framework-react-widget": "^1.0.1-widget-7844194d",
|
|
56
|
+
"@equinor/fusion-framework-react-components-people-provider": "^1.2.1"
|
|
56
57
|
},
|
|
57
58
|
"devDependencies": {
|
|
58
59
|
"@equinor/fusion-react-button": "^0.9.1",
|
|
@@ -61,7 +62,7 @@
|
|
|
61
62
|
"@equinor/fusion-react-menu": "^0.3.0",
|
|
62
63
|
"@equinor/fusion-react-person": "^0.7.0",
|
|
63
64
|
"@equinor/fusion-react-progress-indicator": "^0.2.1",
|
|
64
|
-
"@equinor/fusion-react-side-sheet": "1.
|
|
65
|
+
"@equinor/fusion-react-side-sheet": "1.3.0",
|
|
65
66
|
"@equinor/fusion-react-styles": "^0.6.0",
|
|
66
67
|
"@material-ui/styles": "^4.11.5",
|
|
67
68
|
"@types/express": "^4.17.17",
|
|
@@ -76,18 +77,18 @@
|
|
|
76
77
|
"styled-components": "^6.0.7",
|
|
77
78
|
"types": "link:./types",
|
|
78
79
|
"typescript": "^5.1.3",
|
|
79
|
-
"@equinor/fusion-framework": "^7.0.
|
|
80
|
-
"@equinor/fusion-framework-app": "^8.1.
|
|
80
|
+
"@equinor/fusion-framework": "^7.0.30",
|
|
81
|
+
"@equinor/fusion-framework-app": "^8.1.1",
|
|
81
82
|
"@equinor/fusion-framework-module-app": "^5.2.13",
|
|
83
|
+
"@equinor/fusion-framework-module-context": "^4.0.21",
|
|
82
84
|
"@equinor/fusion-framework-module-bookmark": "^1.1.2",
|
|
83
|
-
"@equinor/fusion-framework-module-context": "^4.1.0",
|
|
84
|
-
"@equinor/fusion-framework-module-msal": "^3.0.10",
|
|
85
85
|
"@equinor/fusion-framework-module-http": "^5.1.6",
|
|
86
|
-
"@equinor/fusion-framework-module-
|
|
86
|
+
"@equinor/fusion-framework-module-msal": "^3.0.10",
|
|
87
87
|
"@equinor/fusion-framework-module-navigation": "^3.1.4",
|
|
88
|
-
"@equinor/fusion-framework-react": "^
|
|
89
|
-
"@equinor/fusion-framework-
|
|
90
|
-
"@equinor/fusion-framework-react
|
|
88
|
+
"@equinor/fusion-framework-react-components-bookmark": "^0.3.8",
|
|
89
|
+
"@equinor/fusion-framework-module-services": "^3.2.4",
|
|
90
|
+
"@equinor/fusion-framework-react": "^6.0.2",
|
|
91
|
+
"@equinor/fusion-framework-react-module-bookmark": "^2.0.32",
|
|
91
92
|
"@equinor/fusion-query": "^4.0.6"
|
|
92
93
|
},
|
|
93
94
|
"scripts": {
|