@storybook/builder-webpack5 10.3.0-beta.1 → 10.3.0-beta.3
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/dist/_node-chunks/{chunk-CHXKJ2TR.js → chunk-64H7R3X5.js} +6 -6
- package/dist/_node-chunks/{chunk-GMRUNEXB.js → chunk-SN3F55F7.js} +6 -6
- package/dist/index.js +8 -8
- package/dist/loaders/export-order-loader.js +7 -7
- package/dist/loaders/storybook-mock-transform-loader.js +7 -7
- package/dist/loaders/webpack-automock-loader.js +7 -7
- package/dist/presets/custom-webpack-preset.js +7 -7
- package/dist/presets/preview-preset.js +8 -8
- package/package.json +3 -3
- package/templates/virtualModuleModernEntry.js +6 -4
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_n2iqhxt540i from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_n2iqhxt540i from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_n2iqhxt540i from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_n2iqhxt540i.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_n2iqhxt540i.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_n2iqhxt540i.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_n2iqhxt540i from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_n2iqhxt540i from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_n2iqhxt540i from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_n2iqhxt540i.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_n2iqhxt540i.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_n2iqhxt540i.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
package/dist/index.js
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_n2iqhxt540i from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_n2iqhxt540i from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_n2iqhxt540i from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_n2iqhxt540i.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_n2iqhxt540i.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_n2iqhxt540i.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
11
|
// ------------------------------------------------------------
|
|
12
12
|
import {
|
|
13
13
|
getVirtualModules
|
|
14
|
-
} from "./_node-chunks/chunk-
|
|
14
|
+
} from "./_node-chunks/chunk-64H7R3X5.js";
|
|
15
15
|
import {
|
|
16
16
|
__commonJS,
|
|
17
17
|
__require,
|
|
18
18
|
__toESM
|
|
19
|
-
} from "./_node-chunks/chunk-
|
|
19
|
+
} from "./_node-chunks/chunk-SN3F55F7.js";
|
|
20
20
|
|
|
21
21
|
// ../../../node_modules/pretty-hrtime/index.js
|
|
22
22
|
var require_pretty_hrtime = __commonJS({
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_n2iqhxt540i from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_n2iqhxt540i from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_n2iqhxt540i from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_n2iqhxt540i.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_n2iqhxt540i.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_n2iqhxt540i.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
11
|
// ------------------------------------------------------------
|
|
12
|
-
import "../_node-chunks/chunk-
|
|
12
|
+
import "../_node-chunks/chunk-SN3F55F7.js";
|
|
13
13
|
|
|
14
14
|
// src/loaders/export-order-loader.ts
|
|
15
15
|
import assert from "node:assert";
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_n2iqhxt540i from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_n2iqhxt540i from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_n2iqhxt540i from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_n2iqhxt540i.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_n2iqhxt540i.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_n2iqhxt540i.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
11
|
// ------------------------------------------------------------
|
|
12
|
-
import "../_node-chunks/chunk-
|
|
12
|
+
import "../_node-chunks/chunk-SN3F55F7.js";
|
|
13
13
|
|
|
14
14
|
// src/loaders/storybook-mock-transform-loader.ts
|
|
15
15
|
import { rewriteSbMockImportCalls } from "storybook/internal/mocking-utils";
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_n2iqhxt540i from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_n2iqhxt540i from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_n2iqhxt540i from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_n2iqhxt540i.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_n2iqhxt540i.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_n2iqhxt540i.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
11
|
// ------------------------------------------------------------
|
|
12
|
-
import "../_node-chunks/chunk-
|
|
12
|
+
import "../_node-chunks/chunk-SN3F55F7.js";
|
|
13
13
|
|
|
14
14
|
// src/loaders/webpack-automock-loader.ts
|
|
15
15
|
import { babelParser, getAutomockCode } from "storybook/internal/mocking-utils";
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_n2iqhxt540i from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_n2iqhxt540i from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_n2iqhxt540i from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_n2iqhxt540i.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_n2iqhxt540i.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_n2iqhxt540i.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
11
|
// ------------------------------------------------------------
|
|
12
12
|
import {
|
|
13
13
|
__require
|
|
14
|
-
} from "../_node-chunks/chunk-
|
|
14
|
+
} from "../_node-chunks/chunk-SN3F55F7.js";
|
|
15
15
|
|
|
16
16
|
// src/presets/custom-webpack-preset.ts
|
|
17
17
|
import { fileURLToPath as fileURLToPath3 } from "node:url";
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_n2iqhxt540i from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_n2iqhxt540i from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_n2iqhxt540i from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_n2iqhxt540i.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_n2iqhxt540i.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_n2iqhxt540i.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
11
|
// ------------------------------------------------------------
|
|
12
12
|
import {
|
|
13
13
|
getVirtualModules
|
|
14
|
-
} from "../_node-chunks/chunk-
|
|
15
|
-
import "../_node-chunks/chunk-
|
|
14
|
+
} from "../_node-chunks/chunk-64H7R3X5.js";
|
|
15
|
+
import "../_node-chunks/chunk-SN3F55F7.js";
|
|
16
16
|
|
|
17
17
|
// src/presets/preview-preset.ts
|
|
18
18
|
import { fileURLToPath as fileURLToPath2 } from "node:url";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storybook/builder-webpack5",
|
|
3
|
-
"version": "10.3.0-beta.
|
|
3
|
+
"version": "10.3.0-beta.3",
|
|
4
4
|
"description": "A Storybook builder to dev and build with Webpack",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"storybook",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"!src/**/*"
|
|
53
53
|
],
|
|
54
54
|
"dependencies": {
|
|
55
|
-
"@storybook/core-webpack": "10.3.0-beta.
|
|
55
|
+
"@storybook/core-webpack": "10.3.0-beta.3",
|
|
56
56
|
"case-sensitive-paths-webpack-plugin": "^2.4.0",
|
|
57
57
|
"cjs-module-lexer": "^1.2.3",
|
|
58
58
|
"css-loader": "^7.1.2",
|
|
@@ -78,7 +78,7 @@
|
|
|
78
78
|
"typescript": "^5.9.3"
|
|
79
79
|
},
|
|
80
80
|
"peerDependencies": {
|
|
81
|
-
"storybook": "^10.3.0-beta.
|
|
81
|
+
"storybook": "^10.3.0-beta.3"
|
|
82
82
|
},
|
|
83
83
|
"peerDependenciesMeta": {
|
|
84
84
|
"typescript": {
|
|
@@ -33,16 +33,18 @@ window.__STORYBOOK_STORY_STORE__ = preview.storyStore;
|
|
|
33
33
|
window.__STORYBOOK_ADDONS_CHANNEL__ = channel;
|
|
34
34
|
|
|
35
35
|
if (import.meta.webpackHot) {
|
|
36
|
+
import.meta.webpackHot.addStatusHandler((status) => {
|
|
37
|
+
if (status === 'idle') {
|
|
38
|
+
preview.channel.emit(STORY_HOT_UPDATED);
|
|
39
|
+
}
|
|
40
|
+
});
|
|
41
|
+
|
|
36
42
|
import.meta.webpackHot.accept('{{storiesFilename}}', () => {
|
|
37
|
-
// Cancel any running play function before patching in the new importFn
|
|
38
|
-
preview.channel.emit(STORY_HOT_UPDATED);
|
|
39
43
|
// importFn has changed so we need to patch the new one in
|
|
40
44
|
preview.onStoriesChanged({ importFn });
|
|
41
45
|
});
|
|
42
46
|
|
|
43
47
|
import.meta.webpackHot.accept(['{{previewAnnotations}}'], () => {
|
|
44
|
-
// Cancel any running play function before patching in the new getProjectAnnotations
|
|
45
|
-
preview.channel.emit(STORY_HOT_UPDATED);
|
|
46
48
|
// getProjectAnnotations has changed so we need to patch the new one in
|
|
47
49
|
preview.onGetProjectAnnotationsChanged({ getProjectAnnotations });
|
|
48
50
|
});
|