@storybook/angular-vite 10.5.0-beta.2 → 10.6.0-alpha.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/build-schema.json +3 -2
- package/dist/_node-chunks/{chunk-7P2DTZAK.js → chunk-3QJ6LM3G.js} +6 -6
- package/dist/_node-chunks/{run-compodoc-ZAWZJ7ZI.js → run-compodoc-BYLOJ3KQ.js} +6 -6
- package/dist/builders/build-storybook/index.js +7 -7
- package/dist/builders/start-storybook/index.js +7 -7
- package/dist/node/index.js +6 -6
- package/dist/node/vitest.js +6 -6
- package/dist/preset.js +11 -10
- package/package.json +3 -3
- package/start-schema.json +3 -2
package/build-schema.json
CHANGED
|
@@ -114,9 +114,10 @@
|
|
|
114
114
|
"description": "Configure sourcemaps. See: https://angular.io/guide/workspace-config#source-map-configuration",
|
|
115
115
|
"default": false
|
|
116
116
|
},
|
|
117
|
-
"
|
|
117
|
+
"zoneless": {
|
|
118
118
|
"type": "boolean",
|
|
119
|
-
"description": "
|
|
119
|
+
"description": "Use zoneless change detection.",
|
|
120
|
+
"default": true
|
|
120
121
|
}
|
|
121
122
|
},
|
|
122
123
|
"additionalProperties": false,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_d2leqlufgt9 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_d2leqlufgt9 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_d2leqlufgt9 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_d2leqlufgt9.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_d2leqlufgt9.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_d2leqlufgt9.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_d2leqlufgt9 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_d2leqlufgt9 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_d2leqlufgt9 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_d2leqlufgt9.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_d2leqlufgt9.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_d2leqlufgt9.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_d2leqlufgt9 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_d2leqlufgt9 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_d2leqlufgt9 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_d2leqlufgt9.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_d2leqlufgt9.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_d2leqlufgt9.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
printErrorDetails,
|
|
15
15
|
up,
|
|
16
16
|
up2
|
|
17
|
-
} from "../../_node-chunks/chunk-
|
|
17
|
+
} from "../../_node-chunks/chunk-3QJ6LM3G.js";
|
|
18
18
|
|
|
19
19
|
// src/builders/build-storybook/index.ts
|
|
20
20
|
import { readFileSync } from "node:fs";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_d2leqlufgt9 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_d2leqlufgt9 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_d2leqlufgt9 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_d2leqlufgt9.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_d2leqlufgt9.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_d2leqlufgt9.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
printErrorDetails,
|
|
15
15
|
up,
|
|
16
16
|
up2
|
|
17
|
-
} from "../../_node-chunks/chunk-
|
|
17
|
+
} from "../../_node-chunks/chunk-3QJ6LM3G.js";
|
|
18
18
|
|
|
19
19
|
// src/builders/start-storybook/index.ts
|
|
20
20
|
import { readFileSync } from "node:fs";
|
package/dist/node/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_d2leqlufgt9 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_d2leqlufgt9 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_d2leqlufgt9 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_d2leqlufgt9.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_d2leqlufgt9.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_d2leqlufgt9.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
package/dist/node/vitest.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_d2leqlufgt9 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_d2leqlufgt9 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_d2leqlufgt9 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_d2leqlufgt9.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_d2leqlufgt9.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_d2leqlufgt9.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
package/dist/preset.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_d2leqlufgt9 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_d2leqlufgt9 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_d2leqlufgt9 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_d2leqlufgt9.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_d2leqlufgt9.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_d2leqlufgt9.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -64,7 +64,7 @@ var viteFinal = async (config, options) => {
|
|
|
64
64
|
if (framework.options?.compodoc !== !1) {
|
|
65
65
|
let { existsSync } = await import("node:fs"), path = await import("node:path"), workspaceRoot = options?.angularBuilderContext?.workspaceRoot ?? config?.root ?? process.cwd(), documentationJsonPath = path.resolve(workspaceRoot, "documentation.json");
|
|
66
66
|
if (!existsSync(documentationJsonPath)) {
|
|
67
|
-
let { runCompodoc } = await import("./_node-chunks/run-compodoc-
|
|
67
|
+
let { runCompodoc } = await import("./_node-chunks/run-compodoc-BYLOJ3KQ.js"), tsconfig = framework.options?.tsconfig ?? options?.tsConfig ?? options?.angularBuilderOptions?.tsConfig ?? path.resolve(workspaceRoot, "tsconfig.json"), compodocArgs = framework.options?.compodocArgs ?? ["-e", "json", "-d", "."];
|
|
68
68
|
try {
|
|
69
69
|
await runCompodoc({ compodocArgs, tsconfig, workspaceRoot });
|
|
70
70
|
} catch (err) {
|
|
@@ -134,11 +134,11 @@ var viteFinal = async (config, options) => {
|
|
|
134
134
|
});
|
|
135
135
|
};
|
|
136
136
|
function angularOptionsPlugin(options, { normalizePath, zoneless }) {
|
|
137
|
-
let resolvedConfig;
|
|
137
|
+
let resolvedConfig, resolvedPreviewPath;
|
|
138
138
|
return {
|
|
139
139
|
name: "storybook-angular-vite-options-plugin",
|
|
140
140
|
config(userConfig) {
|
|
141
|
-
resolvedConfig = userConfig;
|
|
141
|
+
resolvedConfig = userConfig, resolvedPreviewPath = findConfigFile("preview", options.configDir) ?? void 0;
|
|
142
142
|
let loadPaths = options?.angularBuilderOptions?.stylePreprocessorOptions?.loadPaths, sassOptions = options?.angularBuilderOptions?.stylePreprocessorOptions?.sass;
|
|
143
143
|
if (Array.isArray(loadPaths)) {
|
|
144
144
|
let workspaceRoot = options.angularBuilderContext?.workspaceRoot ?? userConfig?.root ?? process.cwd();
|
|
@@ -155,7 +155,7 @@ function angularOptionsPlugin(options, { normalizePath, zoneless }) {
|
|
|
155
155
|
}
|
|
156
156
|
},
|
|
157
157
|
async transform(code, id) {
|
|
158
|
-
if (normalizePath(id).endsWith(normalizePath(
|
|
158
|
+
if (resolvedPreviewPath && normalizePath(id).endsWith(normalizePath(resolvedPreviewPath))) {
|
|
159
159
|
let imports = [], styles = options?.angularBuilderOptions?.styles;
|
|
160
160
|
Array.isArray(styles) && styles.forEach((style) => {
|
|
161
161
|
imports.push(style);
|
|
@@ -247,6 +247,7 @@ var typescript = async (config) => ({
|
|
|
247
247
|
});
|
|
248
248
|
export {
|
|
249
249
|
addons,
|
|
250
|
+
angularOptionsPlugin,
|
|
250
251
|
core,
|
|
251
252
|
previewAnnotations,
|
|
252
253
|
typescript,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storybook/angular-vite",
|
|
3
|
-
"version": "10.
|
|
3
|
+
"version": "10.6.0-alpha.0",
|
|
4
4
|
"description": "Storybook for Angular: Develop, document, and test UI components in isolation",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"storybook",
|
|
@@ -62,7 +62,7 @@
|
|
|
62
62
|
"!src/**/*"
|
|
63
63
|
],
|
|
64
64
|
"dependencies": {
|
|
65
|
-
"@storybook/builder-vite": "10.
|
|
65
|
+
"@storybook/builder-vite": "10.6.0-alpha.0",
|
|
66
66
|
"@storybook/global": "^5.0.0",
|
|
67
67
|
"telejson": "8.0.0",
|
|
68
68
|
"ts-dedent": "^2.0.0",
|
|
@@ -101,7 +101,7 @@
|
|
|
101
101
|
"@angular/platform-browser": ">=21.0.0 < 23.0.0",
|
|
102
102
|
"@angular/platform-browser-dynamic": ">=21.0.0 < 23.0.0",
|
|
103
103
|
"rxjs": "^7.4.0",
|
|
104
|
-
"storybook": "^10.
|
|
104
|
+
"storybook": "^10.6.0-alpha.0",
|
|
105
105
|
"typescript": "^5.9.0",
|
|
106
106
|
"vite": ">=8.0.0",
|
|
107
107
|
"zone.js": ">=0.16.0"
|
package/start-schema.json
CHANGED
|
@@ -149,9 +149,10 @@
|
|
|
149
149
|
"description": "Configure sourcemaps. See: https://angular.io/guide/workspace-config#source-map-configuration",
|
|
150
150
|
"default": false
|
|
151
151
|
},
|
|
152
|
-
"
|
|
152
|
+
"zoneless": {
|
|
153
153
|
"type": "boolean",
|
|
154
|
-
"description": "
|
|
154
|
+
"description": "Use zoneless change detection.",
|
|
155
|
+
"default": true
|
|
155
156
|
}
|
|
156
157
|
},
|
|
157
158
|
"additionalProperties": false,
|