@storybook/nextjs 11.0.0-alpha.8 → 11.0.0-beta.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/dist/_node-chunks/{chunk-FMZIWMDY.js → chunk-MHCWNZ2L.js} +7 -7
- package/dist/_node-chunks/{chunk-A3JWAOV6.js → chunk-NICCLNVN.js} +6 -6
- package/dist/_node-chunks/{chunk-RU5GXEFG.js → chunk-WMC74MMO.js} +6 -6
- package/dist/_node-chunks/{configureNextFont-FORJG43V.js → configureNextFont-WESGSBQO.js} +6 -6
- package/dist/_node-chunks/{loader-5W3S5BYG.js → loader-3QUVLJSI.js} +8 -8
- package/dist/_node-chunks/{loader-AUQJOJIJ.js → loader-SXD4WC5F.js} +8 -8
- package/dist/_node-chunks/{utils-VGEZ7F4B.js → utils-BKGNUKMH.js} +8 -8
- package/dist/_node-chunks/{webpack-LZNFEU4C.js → webpack-HWV46HC3.js} +6 -6
- package/dist/_node-chunks/{webpack-7ANNYKPC.js → webpack-LLTUMDPN.js} +8 -8
- package/dist/_node-chunks/{webpack-EHLQQPAB.js → webpack-MWVMKIH7.js} +6 -6
- package/dist/_node-chunks/{webpack-APFA6JW3.js → webpack-TABTUKNA.js} +8 -8
- package/dist/_node-chunks/{webpack-RREL6B7L.js → webpack-UJCJBSTI.js} +6 -6
- package/dist/_node-chunks/{webpack-GTTCETL6.js → webpack-WEDVBG5C.js} +6 -6
- package/dist/_node-chunks/{webpack-F6H7ELN6.js → webpack-WJ3PLO7C.js} +6 -6
- package/dist/_node-chunks/{webpack-AMOKTP4O.js → webpack-YLQW7HPA.js} +6 -6
- package/dist/export-mocks/index.js +7 -7
- package/dist/export-mocks/link/index.js +2 -2
- package/dist/font/webpack/loader/storybook-nextjs-font-loader.js +6 -6
- package/dist/node/index.js +6 -6
- package/dist/preset.js +9 -9
- package/dist/swc/next-swc-loader-patch.js +6 -6
- package/package.json +6 -8
- package/template/cli/js/Button.jsx +11 -24
- package/template/cli/js/Header.jsx +7 -15
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.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
|
resolvePackageDir
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-NICCLNVN.js";
|
|
15
15
|
|
|
16
16
|
// src/utils.ts
|
|
17
17
|
import { readFileSync } from "node:fs";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.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_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.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_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.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
|
getNodeModulesExcludeRegex
|
|
14
|
-
} from "./chunk-
|
|
15
|
-
import "./chunk-
|
|
14
|
+
} from "./chunk-MHCWNZ2L.js";
|
|
15
|
+
import "./chunk-NICCLNVN.js";
|
|
16
16
|
|
|
17
17
|
// src/babel/loader.ts
|
|
18
18
|
import { fileURLToPath } from "node:url";
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.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
|
getNodeModulesExcludeRegex
|
|
14
|
-
} from "./chunk-
|
|
15
|
-
import "./chunk-
|
|
14
|
+
} from "./chunk-MHCWNZ2L.js";
|
|
15
|
+
import "./chunk-NICCLNVN.js";
|
|
16
16
|
|
|
17
17
|
// src/swc/loader.ts
|
|
18
18
|
import { join } from "node:path";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -18,8 +18,8 @@ import {
|
|
|
18
18
|
resolveNextConfig,
|
|
19
19
|
scopedResolve,
|
|
20
20
|
setAlias
|
|
21
|
-
} from "./chunk-
|
|
22
|
-
import "./chunk-
|
|
21
|
+
} from "./chunk-MHCWNZ2L.js";
|
|
22
|
+
import "./chunk-NICCLNVN.js";
|
|
23
23
|
export {
|
|
24
24
|
addScopedAlias,
|
|
25
25
|
configureRuntimeNextjsVersionResolution,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.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
|
addScopedAlias
|
|
14
|
-
} from "./chunk-
|
|
15
|
-
import "./chunk-
|
|
14
|
+
} from "./chunk-MHCWNZ2L.js";
|
|
15
|
+
import "./chunk-NICCLNVN.js";
|
|
16
16
|
|
|
17
17
|
// src/styledJsx/webpack.ts
|
|
18
18
|
var configureStyledJsx = (baseConfig) => {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.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
|
configureNextExportMocks
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-WMC74MMO.js";
|
|
15
15
|
import {
|
|
16
16
|
resolvePackageDir
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-NICCLNVN.js";
|
|
18
18
|
|
|
19
19
|
// src/aliases/webpack.ts
|
|
20
20
|
var configureAliases = (baseConfig) => {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.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_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.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_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.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_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.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
|
getPackageAliases
|
|
14
|
-
} from "../_node-chunks/chunk-
|
|
14
|
+
} from "../_node-chunks/chunk-WMC74MMO.js";
|
|
15
15
|
export {
|
|
16
16
|
getPackageAliases
|
|
17
17
|
};
|
|
@@ -15,7 +15,7 @@ var linkAction = fn().mockName("next/link::Link"), removeTrailingSlash = (route)
|
|
|
15
15
|
return path;
|
|
16
16
|
let { pathname, query, hash } = parsePath(path);
|
|
17
17
|
return process.env.__NEXT_TRAILING_SLASH ? /\.[^/]+\/?$/.test(pathname) ? `${removeTrailingSlash(pathname)}${query}${hash}` : `${pathname.endsWith("/") ? pathname : `${pathname}/`}${query}${hash}` : `${removeTrailingSlash(pathname)}${query}${hash}`;
|
|
18
|
-
}, MockLink = React.forwardRef(function({
|
|
18
|
+
}, formatHash = (hash) => hash ? hash.startsWith("#") ? hash : `#${hash}` : "", MockLink = React.forwardRef(function({
|
|
19
19
|
href,
|
|
20
20
|
as,
|
|
21
21
|
replace,
|
|
@@ -29,7 +29,7 @@ var linkAction = fn().mockName("next/link::Link"), removeTrailingSlash = (route)
|
|
|
29
29
|
children,
|
|
30
30
|
...rest
|
|
31
31
|
}, ref) {
|
|
32
|
-
let resolvedHref = as ?? href, rawHref = typeof resolvedHref == "object" ? `${resolvedHref.pathname || ""}${resolvedHref.query ? "?" + new URLSearchParams(resolvedHref.query).toString() : ""}${resolvedHref.hash
|
|
32
|
+
let resolvedHref = as ?? href, rawHref = typeof resolvedHref == "object" ? `${resolvedHref.pathname || ""}${resolvedHref.query ? "?" + new URLSearchParams(resolvedHref.query).toString() : ""}${formatHash(resolvedHref.hash)}` : resolvedHref, hrefString = typeof rawHref == "string" ? normalizePathTrailingSlash(rawHref) : rawHref, navigate = (e) => {
|
|
33
33
|
e.defaultPrevented || (e.preventDefault(), linkAction(hrefString, { replace, scroll, shallow, prefetch, locale }));
|
|
34
34
|
}, handleClick = (e) => {
|
|
35
35
|
onClick?.(e), navigate(e);
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
package/dist/node/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.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_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -13,8 +13,8 @@ import {
|
|
|
13
13
|
addScopedAlias,
|
|
14
14
|
isNextVersionGte,
|
|
15
15
|
resolveNextConfig
|
|
16
|
-
} from "./_node-chunks/chunk-
|
|
17
|
-
import "./_node-chunks/chunk-
|
|
16
|
+
} from "./_node-chunks/chunk-MHCWNZ2L.js";
|
|
17
|
+
import "./_node-chunks/chunk-NICCLNVN.js";
|
|
18
18
|
|
|
19
19
|
// src/preset.ts
|
|
20
20
|
import { fileURLToPath as fileURLToPath2 } from "node:url";
|
|
@@ -553,7 +553,7 @@ var addons = [
|
|
|
553
553
|
baseConfig,
|
|
554
554
|
nextConfigPath,
|
|
555
555
|
webpackInstance
|
|
556
|
-
}), { configureNextFont } = await import("./_node-chunks/configureNextFont-
|
|
556
|
+
}), { configureNextFont } = await import("./_node-chunks/configureNextFont-WESGSBQO.js"), { configureRuntimeNextjsVersionResolution } = await import("./_node-chunks/utils-BKGNUKMH.js"), { configureImports } = await import("./_node-chunks/webpack-WJ3PLO7C.js"), { configureCss } = await import("./_node-chunks/webpack-WEDVBG5C.js"), { configureImages } = await import("./_node-chunks/webpack-YLQW7HPA.js"), { configureStyledJsx } = await import("./_node-chunks/webpack-LLTUMDPN.js"), { configureNodePolyfills } = await import("./_node-chunks/webpack-HWV46HC3.js"), { configureAliases } = await import("./_node-chunks/webpack-TABTUKNA.js"), { configureFastRefresh } = await import("./_node-chunks/webpack-MWVMKIH7.js"), { configureRSC } = await import("./_node-chunks/webpack-UJCJBSTI.js"), { configureSWCLoader } = await import("./_node-chunks/loader-SXD4WC5F.js"), { configureBabelLoader } = await import("./_node-chunks/loader-3QUVLJSI.js"), hasBabelConfig = !!findBabelConfigFile(getProjectRoot()), isDevelopment = options.configType !== "PRODUCTION", useSWC = nextConfig.experimental?.forceSwcTransforms || !hasBabelConfig;
|
|
557
557
|
return configureNextFont(baseConfig, useSWC), configureRuntimeNextjsVersionResolution(baseConfig), configureImports({ baseConfig, configDir: options.configDir }), configureCss(baseConfig, nextConfig), configureImages(baseConfig, nextConfig), configureStyledJsx(baseConfig), configureNodePolyfills(baseConfig, webpackInstance), configureAliases(baseConfig), isDevelopment && configureFastRefresh(baseConfig), options.features?.experimentalRSC && configureRSC(baseConfig), useSWC ? (logger.info("Using SWC as compiler"), await configureSWCLoader(baseConfig, options, nextConfig)) : (logger.info("Using Babel as compiler"), await configureBabelLoader(baseConfig, options, nextConfig)), baseConfig;
|
|
558
558
|
};
|
|
559
559
|
export {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_6xund73j2xn from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_6xund73j2xn from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_6xund73j2xn from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_6xund73j2xn.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_6xund73j2xn.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_6xund73j2xn.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storybook/nextjs",
|
|
3
|
-
"version": "11.0.0-
|
|
3
|
+
"version": "11.0.0-beta.0",
|
|
4
4
|
"description": "Storybook for Next.js: Develop, document, and test UI components in isolation",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"storybook",
|
|
@@ -101,9 +101,9 @@
|
|
|
101
101
|
"@babel/preset-typescript": "^7.28.5",
|
|
102
102
|
"@babel/runtime": "^7.28.4",
|
|
103
103
|
"@pmmmwh/react-refresh-webpack-plugin": "^0.5.11",
|
|
104
|
-
"@storybook/builder-webpack5": "11.0.0-
|
|
105
|
-
"@storybook/preset-react-webpack": "11.0.0-
|
|
106
|
-
"@storybook/react": "11.0.0-
|
|
104
|
+
"@storybook/builder-webpack5": "11.0.0-beta.0",
|
|
105
|
+
"@storybook/preset-react-webpack": "11.0.0-beta.0",
|
|
106
|
+
"@storybook/react": "11.0.0-beta.0",
|
|
107
107
|
"@types/semver": "^7.7.1",
|
|
108
108
|
"babel-loader": "^9.1.3",
|
|
109
109
|
"browserify-zlib": "^0.2.0",
|
|
@@ -145,7 +145,8 @@
|
|
|
145
145
|
"next": "^15.0.0 || ^16.0.0",
|
|
146
146
|
"react": "^18.0.0 || ^19.0.0",
|
|
147
147
|
"react-dom": "^18.0.0 || ^19.0.0",
|
|
148
|
-
"storybook": "^11.0.0-
|
|
148
|
+
"storybook": "^11.0.0-beta.0",
|
|
149
|
+
"typescript": "^5.9.0 || ^6.0.0 || ^7.0.0",
|
|
149
150
|
"webpack": "^5.0.0"
|
|
150
151
|
},
|
|
151
152
|
"peerDependenciesMeta": {
|
|
@@ -155,9 +156,6 @@
|
|
|
155
156
|
"@types/react-dom": {
|
|
156
157
|
"optional": true
|
|
157
158
|
},
|
|
158
|
-
"typescript": {
|
|
159
|
-
"optional": true
|
|
160
|
-
},
|
|
161
159
|
"webpack": {
|
|
162
160
|
"optional": true
|
|
163
161
|
}
|
|
@@ -1,9 +1,16 @@
|
|
|
1
|
-
import PropTypes from 'prop-types';
|
|
2
|
-
|
|
3
1
|
import './button.css';
|
|
4
2
|
|
|
5
|
-
/**
|
|
6
|
-
|
|
3
|
+
/**
|
|
4
|
+
* Primary UI component for user interaction
|
|
5
|
+
*
|
|
6
|
+
* @param {object} props
|
|
7
|
+
* @param {boolean} [props.primary=false] Is this the principal call to action on the page?
|
|
8
|
+
* @param {string} [props.backgroundColor] What background color to use
|
|
9
|
+
* @param {'small' | 'medium' | 'large'} [props.size='medium'] How large should the button be?
|
|
10
|
+
* @param {string} props.label Button contents
|
|
11
|
+
* @param {() => void} [props.onClick] Optional click handler
|
|
12
|
+
*/
|
|
13
|
+
export const Button = ({ primary = false, backgroundColor, size = 'medium', label, ...props }) => {
|
|
7
14
|
const mode = primary ? 'storybook-button--primary' : 'storybook-button--secondary';
|
|
8
15
|
return (
|
|
9
16
|
<button
|
|
@@ -20,23 +27,3 @@ export const Button = ({ primary, backgroundColor, size, label, ...props }) => {
|
|
|
20
27
|
</button>
|
|
21
28
|
);
|
|
22
29
|
};
|
|
23
|
-
|
|
24
|
-
Button.propTypes = {
|
|
25
|
-
/** Is this the principal call to action on the page? */
|
|
26
|
-
primary: PropTypes.bool,
|
|
27
|
-
/** What background color to use */
|
|
28
|
-
backgroundColor: PropTypes.string,
|
|
29
|
-
/** How large should the button be? */
|
|
30
|
-
size: PropTypes.oneOf(['small', 'medium', 'large']),
|
|
31
|
-
/** Button contents */
|
|
32
|
-
label: PropTypes.string.isRequired,
|
|
33
|
-
/** Optional click handler */
|
|
34
|
-
onClick: PropTypes.func,
|
|
35
|
-
};
|
|
36
|
-
|
|
37
|
-
Button.defaultProps = {
|
|
38
|
-
backgroundColor: null,
|
|
39
|
-
primary: false,
|
|
40
|
-
size: 'medium',
|
|
41
|
-
onClick: undefined,
|
|
42
|
-
};
|
|
@@ -1,8 +1,13 @@
|
|
|
1
|
-
import PropTypes from 'prop-types';
|
|
2
|
-
|
|
3
1
|
import { Button } from './Button';
|
|
4
2
|
import './header.css';
|
|
5
3
|
|
|
4
|
+
/**
|
|
5
|
+
* @param {object} props
|
|
6
|
+
* @param {{ name: string }} [props.user] The signed-in user, if any
|
|
7
|
+
* @param {() => void} props.onLogin Called when the user clicks Log in
|
|
8
|
+
* @param {() => void} props.onLogout Called when the user clicks Log out
|
|
9
|
+
* @param {() => void} props.onCreateAccount Called when the user clicks Sign up
|
|
10
|
+
*/
|
|
6
11
|
export const Header = ({ user, onLogin, onLogout, onCreateAccount }) => (
|
|
7
12
|
<header>
|
|
8
13
|
<div className="storybook-header">
|
|
@@ -43,16 +48,3 @@ export const Header = ({ user, onLogin, onLogout, onCreateAccount }) => (
|
|
|
43
48
|
</div>
|
|
44
49
|
</header>
|
|
45
50
|
);
|
|
46
|
-
|
|
47
|
-
Header.propTypes = {
|
|
48
|
-
user: PropTypes.shape({
|
|
49
|
-
name: PropTypes.string.isRequired,
|
|
50
|
-
}),
|
|
51
|
-
onLogin: PropTypes.func.isRequired,
|
|
52
|
-
onLogout: PropTypes.func.isRequired,
|
|
53
|
-
onCreateAccount: PropTypes.func.isRequired,
|
|
54
|
-
};
|
|
55
|
-
|
|
56
|
-
Header.defaultProps = {
|
|
57
|
-
user: null,
|
|
58
|
-
};
|