storybook 10.0.0-beta.9 → 10.0.0-rc.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/_browser-chunks/{chunk-AM4PZYVQ.js → chunk-HMIIJ6UD.js} +59 -6
- package/dist/_browser-chunks/chunk-SHR3NNR3.js +5810 -0
- package/dist/_browser-chunks/{syntaxhighlighter-RJW7FE3A.js → syntaxhighlighter-R46XOLMC.js} +2 -3
- package/dist/_node-chunks/{builder-manager-ZMBCXQXV.js → builder-manager-5DZV3NH5.js} +12 -12
- package/dist/_node-chunks/camelcase-KM3CILTP.js +18 -0
- package/dist/_node-chunks/{chunk-NEEUVKLS.js → chunk-2IRRHUY6.js} +8 -8
- package/dist/_node-chunks/{chunk-U3TBYKZA.js → chunk-3KLEDJFU.js} +8 -8
- package/dist/_node-chunks/{chunk-VM3IJPAW.js → chunk-4JI3GYTR.js} +7 -7
- package/dist/_node-chunks/{chunk-2RLHFYFA.js → chunk-4T2EX3QY.js} +7 -7
- package/dist/_node-chunks/{chunk-V6E6RSUO.js → chunk-6KTXQPVV.js} +7 -7
- package/dist/_node-chunks/{chunk-R4BIB4NX.js → chunk-73JE2442.js} +8 -8
- package/dist/_node-chunks/{chunk-U3LOLMF3.js → chunk-7GOR4BTB.js} +7 -7
- package/dist/_node-chunks/{chunk-CALGSUC5.js → chunk-7L4E5FAU.js} +6 -6
- package/dist/_node-chunks/{chunk-BUQRXXWE.js → chunk-ATTQ5B3H.js} +7 -7
- package/dist/_node-chunks/{chunk-LTKYC6VP.js → chunk-B3BVSZUX.js} +7 -7
- package/dist/_node-chunks/{chunk-A33ZDBWG.js → chunk-BGGGKRRK.js} +7 -7
- package/dist/_node-chunks/{chunk-75N2O5FL.js → chunk-CZLSJXUC.js} +7 -7
- package/dist/_node-chunks/{chunk-AV6DOLF6.js → chunk-DXXS374Q.js} +29 -26
- package/dist/_node-chunks/{chunk-XBOE5GD4.js → chunk-G3DNEVQF.js} +6 -6
- package/dist/_node-chunks/{chunk-XHXUIPIC.js → chunk-H3EQM2KY.js} +12 -12
- package/dist/_node-chunks/{chunk-Z6UKYBDV.js → chunk-IDR56JX5.js} +8 -8
- package/dist/_node-chunks/{chunk-V5DK6ZKU.js → chunk-KNGDROKF.js} +7 -7
- package/dist/_node-chunks/{chunk-AEVVTNDL.js → chunk-L7POFJNQ.js} +7 -7
- package/dist/_node-chunks/{chunk-I5NPNO3G.js → chunk-MDI6XQQU.js} +7 -7
- package/dist/_node-chunks/chunk-MG4NC3KA.js +61 -0
- package/dist/_node-chunks/chunk-MOBEL6SU.js +18 -0
- package/dist/_node-chunks/{chunk-NRBIODYE.js → chunk-NEHX365L.js} +7 -7
- package/dist/_node-chunks/{chunk-O2AHQDZJ.js → chunk-OAWO55XX.js} +7 -7
- package/dist/_node-chunks/{chunk-JVFB6XG6.js → chunk-OYXXB4OM.js} +14 -10
- package/dist/_node-chunks/{chunk-JIERQ4FU.js → chunk-PVOTH5U7.js} +9 -9
- package/dist/_node-chunks/{chunk-GEDTSFBQ.js → chunk-R4L65Z37.js} +7 -7
- package/dist/_node-chunks/{chunk-XYRZ6AGE.js → chunk-VAUJQGO5.js} +10 -10
- package/dist/_node-chunks/{chunk-UOCLAXMF.js → chunk-WEVLMQUC.js} +7 -7
- package/dist/_node-chunks/{chunk-B5W4OROC.js → chunk-WFKQH23S.js} +9 -9
- package/dist/_node-chunks/{chunk-TO3ARZYO.js → chunk-XKXC26XV.js} +18 -15
- package/dist/_node-chunks/{chunk-IXMF5FBT.js → chunk-ZH4LFYU3.js} +7 -7
- package/dist/_node-chunks/{dist-HAF4OXIQ.js → dist-UT73SVAT.js} +9 -9
- package/dist/_node-chunks/{globby-HUMXQF7C.js → globby-ZQ3RX3ZV.js} +9 -9
- package/dist/_node-chunks/{lib-TOFZQAVG.js → lib-HX5MMWWS.js} +7 -7
- package/dist/_node-chunks/{mdx-N42X6CFJ-LCPMSYGS.js → mdx-N42X6CFJ-MCLYGNM2.js} +8 -8
- package/dist/_node-chunks/{p-limit-JSCSHFNF.js → p-limit-WFKT3URN.js} +7 -7
- package/dist/_node-chunks/{plugin-4OW72VQ5.js → plugin-MYXI4RLY.js} +11 -11
- package/dist/_node-chunks/{plugin-XRJQD5ND.js → plugin-ZWOPAFXY.js} +10 -10
- package/dist/_node-chunks/{webpack-inject-mocker-runtime-plugin-XI7KJK6X.js → webpack-inject-mocker-runtime-plugin-QKV56QIS.js} +10 -10
- package/dist/_node-chunks/{webpack-mock-plugin-6BAMUAJ3.js → webpack-mock-plugin-I6AWAO5P.js} +9 -9
- package/dist/babel/index.js +11 -11
- package/dist/bin/core.js +11 -11
- package/dist/bin/dispatcher.js +11 -11
- package/dist/bin/loader.js +77 -12
- package/dist/cli/index.js +21 -20
- package/dist/common/index.d.ts +5 -3
- package/dist/common/index.js +20 -20
- package/dist/components/index.js +74 -5746
- package/dist/core-server/index.js +49 -40
- package/dist/core-server/presets/common-manager.js +523 -29
- package/dist/core-server/presets/common-override-preset.js +9 -9
- package/dist/core-server/presets/common-preset.js +22 -22
- package/dist/core-server/presets/webpack/loaders/storybook-mock-transform-loader.js +9 -9
- package/dist/core-server/presets/webpack/loaders/webpack-automock-loader.js +10 -10
- package/dist/csf/index.js +2 -2
- package/dist/csf-tools/index.js +9 -9
- package/dist/manager/globals-runtime.js +24 -21
- package/dist/manager/runtime.js +68 -45
- package/dist/manager-api/index.js +24 -21
- package/dist/node-logger/index.js +18 -15
- package/dist/preview-api/index.d.ts +68 -67
- package/dist/preview-api/index.js +5 -5
- package/dist/server-errors.js +10 -10
- package/dist/telemetry/index.js +23 -23
- package/dist/types/index.d.ts +3 -1
- package/package.json +1 -1
- package/dist/_browser-chunks/chunk-GJ67EE65.js +0 -67
- package/dist/_node-chunks/camelcase-JMK43JMF.js +0 -18
- package/dist/_node-chunks/chunk-5G7GJHS7.js +0 -62
- package/dist/_node-chunks/chunk-7VDHEICM.js +0 -18
- package/dist/_browser-chunks/{chunk-OQ6NCFPL.js → chunk-PS3AOQI4.js} +5 -5
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_puee7uitcer from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_puee7uitcer from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_puee7uitcer from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_puee7uitcer.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_puee7uitcer.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_puee7uitcer.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -12,16 +12,16 @@ var require = CJS_COMPAT_NODE_MODULE_5dt5laqry3q.createRequire(import.meta.url);
|
|
|
12
12
|
import {
|
|
13
13
|
require_picomatch,
|
|
14
14
|
require_utils
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-6KTXQPVV.js";
|
|
16
16
|
import {
|
|
17
17
|
slash
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-R4L65Z37.js";
|
|
19
19
|
import {
|
|
20
20
|
__commonJS,
|
|
21
21
|
__name,
|
|
22
22
|
__require,
|
|
23
23
|
__toESM
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-7L4E5FAU.js";
|
|
25
25
|
|
|
26
26
|
// ../node_modules/fast-glob/out/utils/array.js
|
|
27
27
|
var require_array = __commonJS({
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_puee7uitcer from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_puee7uitcer from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_puee7uitcer from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_puee7uitcer.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_puee7uitcer.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_puee7uitcer.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
|
__name,
|
|
15
15
|
__require,
|
|
16
16
|
__toESM
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-7L4E5FAU.js";
|
|
18
18
|
|
|
19
19
|
// ../node_modules/app-root-dir/lib/index.js
|
|
20
20
|
var require_lib = __commonJS({
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_puee7uitcer from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_puee7uitcer from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_puee7uitcer from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_puee7uitcer.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_puee7uitcer.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_puee7uitcer.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -23,10 +23,10 @@ import {
|
|
|
23
23
|
start,
|
|
24
24
|
toEstree,
|
|
25
25
|
unreachable
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-MDI6XQQU.js";
|
|
27
27
|
import {
|
|
28
28
|
__name
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-7L4E5FAU.js";
|
|
30
30
|
|
|
31
31
|
// ../node_modules/@storybook/docs-mdx/dist/mdx-N42X6CFJ.js
|
|
32
32
|
import { default as default2 } from "path";
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_puee7uitcer from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_puee7uitcer from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_puee7uitcer from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_puee7uitcer.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_puee7uitcer.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_puee7uitcer.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
|
__name
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-7L4E5FAU.js";
|
|
15
15
|
|
|
16
16
|
// ../node_modules/yocto-queue/index.js
|
|
17
17
|
var Node = class {
|
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_puee7uitcer from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_puee7uitcer from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_puee7uitcer from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_puee7uitcer.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_puee7uitcer.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_puee7uitcer.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-
|
|
15
|
-
import "./chunk-
|
|
14
|
+
} from "./chunk-OYXXB4OM.js";
|
|
15
|
+
import "./chunk-ZH4LFYU3.js";
|
|
16
16
|
import {
|
|
17
17
|
require_dist
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-B3BVSZUX.js";
|
|
19
19
|
import {
|
|
20
20
|
__name,
|
|
21
21
|
__toESM
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-7L4E5FAU.js";
|
|
23
23
|
|
|
24
24
|
// src/core-server/presets/vitePlugins/vite-inject-mocker/plugin.ts
|
|
25
25
|
import { readFileSync } from "node:fs";
|
|
@@ -41,7 +41,7 @@ __name(escapeRegex, "escapeRegex");
|
|
|
41
41
|
var import_ts_dedent = __toESM(require_dist(), 1);
|
|
42
42
|
var entryPath = "/vite-inject-mocker-entry.js";
|
|
43
43
|
var entryCode = import_ts_dedent.dedent`
|
|
44
|
-
<script type="module" src="
|
|
44
|
+
<script type="module" src=".${entryPath}"></script>
|
|
45
45
|
`;
|
|
46
46
|
var server;
|
|
47
47
|
var viteInjectMockerRuntime = /* @__PURE__ */ __name((options) => {
|
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_puee7uitcer from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_puee7uitcer from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_puee7uitcer from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_puee7uitcer.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_puee7uitcer.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_puee7uitcer.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
|
getAutomockCode
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-7GOR4BTB.js";
|
|
15
15
|
import {
|
|
16
16
|
babelParser,
|
|
17
17
|
extractMockCalls,
|
|
18
18
|
getRealPath,
|
|
19
19
|
rewriteSbMockImportCalls
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-3KLEDJFU.js";
|
|
21
21
|
import {
|
|
22
22
|
normalize
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-ZH4LFYU3.js";
|
|
24
24
|
import {
|
|
25
25
|
__name
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-7L4E5FAU.js";
|
|
27
27
|
|
|
28
28
|
// src/core-server/presets/vitePlugins/vite-mock/plugin.ts
|
|
29
29
|
import { readFileSync } from "node:fs";
|
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_puee7uitcer from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_puee7uitcer from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_puee7uitcer from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_puee7uitcer.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_puee7uitcer.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_puee7uitcer.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-
|
|
15
|
-
import "./chunk-
|
|
14
|
+
} from "./chunk-OYXXB4OM.js";
|
|
15
|
+
import "./chunk-ZH4LFYU3.js";
|
|
16
16
|
import {
|
|
17
17
|
require_gen_mapping_umd,
|
|
18
18
|
require_trace_mapping_umd
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-WEVLMQUC.js";
|
|
20
20
|
import {
|
|
21
21
|
__commonJS,
|
|
22
22
|
__name,
|
|
23
23
|
__require
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-7L4E5FAU.js";
|
|
25
25
|
|
|
26
26
|
// ../node_modules/lodash/_freeGlobal.js
|
|
27
27
|
var require_freeGlobal = __commonJS({
|
package/dist/_node-chunks/{webpack-mock-plugin-6BAMUAJ3.js → webpack-mock-plugin-I6AWAO5P.js}
RENAMED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_puee7uitcer from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_puee7uitcer from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_puee7uitcer from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_puee7uitcer.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_puee7uitcer.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_puee7uitcer.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -15,11 +15,11 @@ import {
|
|
|
15
15
|
getIsExternal,
|
|
16
16
|
resolveExternalModule,
|
|
17
17
|
resolveWithExtensions
|
|
18
|
-
} from "./chunk-
|
|
19
|
-
import "./chunk-
|
|
18
|
+
} from "./chunk-3KLEDJFU.js";
|
|
19
|
+
import "./chunk-ZH4LFYU3.js";
|
|
20
20
|
import {
|
|
21
21
|
__name
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-7L4E5FAU.js";
|
|
23
23
|
|
|
24
24
|
// src/core-server/presets/webpack/plugins/webpack-mock-plugin.ts
|
|
25
25
|
import { createRequire } from "node:module";
|
package/dist/babel/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_puee7uitcer from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_puee7uitcer from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_puee7uitcer from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_puee7uitcer.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_puee7uitcer.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_puee7uitcer.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -22,11 +22,11 @@ import {
|
|
|
22
22
|
recast,
|
|
23
23
|
traverse,
|
|
24
24
|
types
|
|
25
|
-
} from "../_node-chunks/chunk-
|
|
26
|
-
import "../_node-chunks/chunk-
|
|
27
|
-
import "../_node-chunks/chunk-
|
|
28
|
-
import "../_node-chunks/chunk-
|
|
29
|
-
import "../_node-chunks/chunk-
|
|
25
|
+
} from "../_node-chunks/chunk-VAUJQGO5.js";
|
|
26
|
+
import "../_node-chunks/chunk-WEVLMQUC.js";
|
|
27
|
+
import "../_node-chunks/chunk-L7POFJNQ.js";
|
|
28
|
+
import "../_node-chunks/chunk-4T2EX3QY.js";
|
|
29
|
+
import "../_node-chunks/chunk-7L4E5FAU.js";
|
|
30
30
|
var export_transformSync = import_core.transformSync;
|
|
31
31
|
export {
|
|
32
32
|
BabelFileClass,
|
package/dist/bin/core.js
CHANGED
|
@@ -1,32 +1,32 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_puee7uitcer from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_puee7uitcer from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_puee7uitcer from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_puee7uitcer.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_puee7uitcer.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_puee7uitcer.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
|
version
|
|
14
|
-
} from "../_node-chunks/chunk-
|
|
14
|
+
} from "../_node-chunks/chunk-MOBEL6SU.js";
|
|
15
15
|
import {
|
|
16
16
|
globalSettings
|
|
17
|
-
} from "../_node-chunks/chunk-
|
|
17
|
+
} from "../_node-chunks/chunk-73JE2442.js";
|
|
18
18
|
import {
|
|
19
19
|
require_dist
|
|
20
|
-
} from "../_node-chunks/chunk-
|
|
20
|
+
} from "../_node-chunks/chunk-B3BVSZUX.js";
|
|
21
21
|
import {
|
|
22
22
|
require_picocolors
|
|
23
|
-
} from "../_node-chunks/chunk-
|
|
23
|
+
} from "../_node-chunks/chunk-4T2EX3QY.js";
|
|
24
24
|
import {
|
|
25
25
|
__commonJS,
|
|
26
26
|
__name,
|
|
27
27
|
__require,
|
|
28
28
|
__toESM
|
|
29
|
-
} from "../_node-chunks/chunk-
|
|
29
|
+
} from "../_node-chunks/chunk-7L4E5FAU.js";
|
|
30
30
|
|
|
31
31
|
// ../node_modules/commander/lib/error.js
|
|
32
32
|
var require_error = __commonJS({
|
package/dist/bin/dispatcher.js
CHANGED
|
@@ -1,31 +1,31 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
2
|
+
import CJS_COMPAT_NODE_URL_puee7uitcer from 'node:url';
|
|
3
|
+
import CJS_COMPAT_NODE_PATH_puee7uitcer from 'node:path';
|
|
4
|
+
import CJS_COMPAT_NODE_MODULE_puee7uitcer from "node:module";
|
|
5
5
|
|
|
6
|
-
var __filename =
|
|
7
|
-
var __dirname =
|
|
8
|
-
var require =
|
|
6
|
+
var __filename = CJS_COMPAT_NODE_URL_puee7uitcer.fileURLToPath(import.meta.url);
|
|
7
|
+
var __dirname = CJS_COMPAT_NODE_PATH_puee7uitcer.dirname(__filename);
|
|
8
|
+
var require = CJS_COMPAT_NODE_MODULE_puee7uitcer.createRequire(import.meta.url);
|
|
9
9
|
|
|
10
10
|
// ------------------------------------------------------------
|
|
11
11
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
12
12
|
// ------------------------------------------------------------
|
|
13
13
|
import {
|
|
14
14
|
versions_default
|
|
15
|
-
} from "../_node-chunks/chunk-
|
|
15
|
+
} from "../_node-chunks/chunk-MG4NC3KA.js";
|
|
16
16
|
import {
|
|
17
17
|
resolvePackageDir
|
|
18
|
-
} from "../_node-chunks/chunk-
|
|
18
|
+
} from "../_node-chunks/chunk-OYXXB4OM.js";
|
|
19
19
|
import {
|
|
20
20
|
join
|
|
21
|
-
} from "../_node-chunks/chunk-
|
|
21
|
+
} from "../_node-chunks/chunk-ZH4LFYU3.js";
|
|
22
22
|
import {
|
|
23
23
|
require_dist
|
|
24
|
-
} from "../_node-chunks/chunk-
|
|
24
|
+
} from "../_node-chunks/chunk-B3BVSZUX.js";
|
|
25
25
|
import {
|
|
26
26
|
__name,
|
|
27
27
|
__toESM
|
|
28
|
-
} from "../_node-chunks/chunk-
|
|
28
|
+
} from "../_node-chunks/chunk-7L4E5FAU.js";
|
|
29
29
|
|
|
30
30
|
// src/bin/dispatcher.ts
|
|
31
31
|
import { spawn } from "node:child_process";
|
package/dist/bin/loader.js
CHANGED
|
@@ -1,42 +1,107 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_puee7uitcer from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_puee7uitcer from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_puee7uitcer from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_puee7uitcer.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_puee7uitcer.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_puee7uitcer.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
|
NODE_TARGET
|
|
14
|
-
} from "../_node-chunks/chunk-
|
|
14
|
+
} from "../_node-chunks/chunk-G3DNEVQF.js";
|
|
15
15
|
import {
|
|
16
|
-
|
|
17
|
-
} from "../_node-chunks/chunk-
|
|
16
|
+
require_dist
|
|
17
|
+
} from "../_node-chunks/chunk-B3BVSZUX.js";
|
|
18
|
+
import {
|
|
19
|
+
__name,
|
|
20
|
+
__toESM
|
|
21
|
+
} from "../_node-chunks/chunk-7L4E5FAU.js";
|
|
18
22
|
|
|
19
23
|
// src/bin/loader.ts
|
|
24
|
+
var import_ts_dedent = __toESM(require_dist(), 1);
|
|
25
|
+
import { existsSync } from "node:fs";
|
|
20
26
|
import { readFile } from "node:fs/promises";
|
|
27
|
+
import * as path from "node:path";
|
|
21
28
|
import { fileURLToPath } from "node:url";
|
|
29
|
+
import { deprecate } from "storybook/internal/node-logger";
|
|
22
30
|
import { transform } from "esbuild";
|
|
31
|
+
var supportedExtensions = [
|
|
32
|
+
".js",
|
|
33
|
+
".mjs",
|
|
34
|
+
".cjs",
|
|
35
|
+
".jsx",
|
|
36
|
+
".ts",
|
|
37
|
+
".mts",
|
|
38
|
+
".cts",
|
|
39
|
+
".tsx"
|
|
40
|
+
];
|
|
41
|
+
function resolveWithExtension(importPath, currentFilePath) {
|
|
42
|
+
if (path.extname(importPath)) {
|
|
43
|
+
return importPath;
|
|
44
|
+
}
|
|
45
|
+
deprecate(import_ts_dedent.dedent`One or more extensionless imports detected: "${importPath}" in file "${currentFilePath}".
|
|
46
|
+
For maximum compatibility, you should add an explicit file extension to this import.
|
|
47
|
+
Storybook will attempt to resolve it automatically, but this may change in the future.
|
|
48
|
+
If adding the extension results in an error from TypeScript, we recommend setting moduleResolution to "bundler" in tsconfig.json
|
|
49
|
+
or alternatively look into the allowImportingTsExtensions option.`);
|
|
50
|
+
const currentDir = path.dirname(currentFilePath);
|
|
51
|
+
const absolutePath = path.resolve(currentDir, importPath);
|
|
52
|
+
for (const ext of supportedExtensions) {
|
|
53
|
+
const candidatePath = `${absolutePath}${ext}`;
|
|
54
|
+
if (existsSync(candidatePath)) {
|
|
55
|
+
return `${importPath}${ext}`;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
return importPath;
|
|
59
|
+
}
|
|
60
|
+
__name(resolveWithExtension, "resolveWithExtension");
|
|
61
|
+
function addExtensionsToRelativeImports(source, filePath) {
|
|
62
|
+
const patterns = [
|
|
63
|
+
// import/export ... from './path' or "../path" (including side-effect imports)
|
|
64
|
+
/(\b(?:import|export)\s+(?:[^'"]*?\s+from\s+)?['"])(\.[^'"]+)(['"])/g,
|
|
65
|
+
// import('./path') or import("../path") - dynamic imports with quotes (with closing paren, no concatenation)
|
|
66
|
+
/(\bimport\s*\(\s*['"])(\.[^'"]+)(['"]\s*\))/g,
|
|
67
|
+
// import(`./path`) - dynamic imports with backticks (with closing paren, no template interpolation)
|
|
68
|
+
/(\bimport\s*\(\s*`)(\.[^`$]+)(`\s*\))/g
|
|
69
|
+
];
|
|
70
|
+
let result = source;
|
|
71
|
+
for (const pattern of patterns) {
|
|
72
|
+
result = result.replace(pattern, (match, prefix, path2, suffix) => {
|
|
73
|
+
if (path2.startsWith("./") || path2.startsWith("../")) {
|
|
74
|
+
const resolvedPath = resolveWithExtension(path2, filePath);
|
|
75
|
+
return `${prefix}${resolvedPath}${suffix}`;
|
|
76
|
+
}
|
|
77
|
+
return match;
|
|
78
|
+
});
|
|
79
|
+
}
|
|
80
|
+
return result;
|
|
81
|
+
}
|
|
82
|
+
__name(addExtensionsToRelativeImports, "addExtensionsToRelativeImports");
|
|
23
83
|
var load = /* @__PURE__ */ __name(async (url, context, nextLoad) => {
|
|
24
84
|
if (url.endsWith(".ts") || url.endsWith(".tsx") || url.endsWith(".mts") || url.endsWith(".cts") || url.endsWith(".mtsx") || url.endsWith(".ctsx")) {
|
|
25
|
-
const
|
|
85
|
+
const filePath = fileURLToPath(url);
|
|
86
|
+
const rawSource = await readFile(filePath, "utf-8");
|
|
26
87
|
const transformedSource = await transform(rawSource, {
|
|
27
88
|
loader: "ts",
|
|
28
89
|
target: NODE_TARGET,
|
|
29
90
|
format: "esm",
|
|
30
91
|
platform: "neutral"
|
|
31
92
|
});
|
|
93
|
+
const sourceWithExtensions = addExtensionsToRelativeImports(transformedSource.code, filePath);
|
|
32
94
|
return {
|
|
33
95
|
format: "module",
|
|
34
96
|
shortCircuit: true,
|
|
35
|
-
source:
|
|
97
|
+
source: sourceWithExtensions
|
|
36
98
|
};
|
|
37
99
|
}
|
|
38
100
|
return nextLoad(url, context);
|
|
39
101
|
}, "load");
|
|
40
102
|
export {
|
|
41
|
-
|
|
103
|
+
addExtensionsToRelativeImports,
|
|
104
|
+
load,
|
|
105
|
+
resolveWithExtension,
|
|
106
|
+
supportedExtensions
|
|
42
107
|
};
|
package/dist/cli/index.js
CHANGED
|
@@ -1,57 +1,57 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_puee7uitcer from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_puee7uitcer from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_puee7uitcer from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_puee7uitcer.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_puee7uitcer.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_puee7uitcer.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
|
boxen
|
|
14
|
-
} from "../_node-chunks/chunk-
|
|
15
|
-
import "../_node-chunks/chunk-
|
|
14
|
+
} from "../_node-chunks/chunk-IDR56JX5.js";
|
|
15
|
+
import "../_node-chunks/chunk-4JI3GYTR.js";
|
|
16
16
|
import {
|
|
17
17
|
Settings,
|
|
18
18
|
_clearGlobalSettings,
|
|
19
19
|
globalSettings
|
|
20
|
-
} from "../_node-chunks/chunk-
|
|
20
|
+
} from "../_node-chunks/chunk-73JE2442.js";
|
|
21
21
|
import {
|
|
22
22
|
any,
|
|
23
23
|
up2 as up
|
|
24
|
-
} from "../_node-chunks/chunk-
|
|
24
|
+
} from "../_node-chunks/chunk-OAWO55XX.js";
|
|
25
25
|
import {
|
|
26
26
|
invariant
|
|
27
|
-
} from "../_node-chunks/chunk-
|
|
27
|
+
} from "../_node-chunks/chunk-ATTQ5B3H.js";
|
|
28
28
|
import {
|
|
29
29
|
resolvePackageDir
|
|
30
|
-
} from "../_node-chunks/chunk-
|
|
31
|
-
import "../_node-chunks/chunk-
|
|
30
|
+
} from "../_node-chunks/chunk-OYXXB4OM.js";
|
|
31
|
+
import "../_node-chunks/chunk-ZH4LFYU3.js";
|
|
32
32
|
import {
|
|
33
33
|
require_prompts
|
|
34
|
-
} from "../_node-chunks/chunk-
|
|
34
|
+
} from "../_node-chunks/chunk-KNGDROKF.js";
|
|
35
35
|
import {
|
|
36
36
|
require_dist
|
|
37
|
-
} from "../_node-chunks/chunk-
|
|
37
|
+
} from "../_node-chunks/chunk-B3BVSZUX.js";
|
|
38
38
|
import {
|
|
39
39
|
babelParse,
|
|
40
40
|
recast,
|
|
41
41
|
traverse,
|
|
42
42
|
types
|
|
43
|
-
} from "../_node-chunks/chunk-
|
|
44
|
-
import "../_node-chunks/chunk-
|
|
45
|
-
import "../_node-chunks/chunk-
|
|
43
|
+
} from "../_node-chunks/chunk-VAUJQGO5.js";
|
|
44
|
+
import "../_node-chunks/chunk-WEVLMQUC.js";
|
|
45
|
+
import "../_node-chunks/chunk-L7POFJNQ.js";
|
|
46
46
|
import {
|
|
47
47
|
require_picocolors
|
|
48
|
-
} from "../_node-chunks/chunk-
|
|
48
|
+
} from "../_node-chunks/chunk-4T2EX3QY.js";
|
|
49
49
|
import {
|
|
50
50
|
__commonJS,
|
|
51
51
|
__name,
|
|
52
52
|
__require,
|
|
53
53
|
__toESM
|
|
54
|
-
} from "../_node-chunks/chunk-
|
|
54
|
+
} from "../_node-chunks/chunk-7L4E5FAU.js";
|
|
55
55
|
|
|
56
56
|
// ../node_modules/wrappy/wrappy.js
|
|
57
57
|
var require_wrappy = __commonJS({
|
|
@@ -28106,6 +28106,7 @@ async function detectBuilder(packageManager, projectType) {
|
|
|
28106
28106
|
return "webpack5" /* Webpack5 */;
|
|
28107
28107
|
}
|
|
28108
28108
|
switch (projectType) {
|
|
28109
|
+
case "REACT_NATIVE_AND_RNW" /* REACT_NATIVE_AND_RNW */:
|
|
28109
28110
|
case "REACT_NATIVE_WEB" /* REACT_NATIVE_WEB */:
|
|
28110
28111
|
return "vite" /* Vite */;
|
|
28111
28112
|
case "REACT_SCRIPTS" /* REACT_SCRIPTS */:
|
package/dist/common/index.d.ts
CHANGED
|
@@ -10,7 +10,6 @@ import { ConfigFile } from 'storybook/internal/csf-tools';
|
|
|
10
10
|
declare const _default: {
|
|
11
11
|
'@storybook/addon-a11y': string;
|
|
12
12
|
'@storybook/addon-docs': string;
|
|
13
|
-
'@storybook/addon-jest': string;
|
|
14
13
|
'@storybook/addon-links': string;
|
|
15
14
|
'@storybook/addon-onboarding': string;
|
|
16
15
|
'storybook-addon-pseudo-states': string;
|
|
@@ -1106,9 +1105,10 @@ declare function getInterpretedFile(pathToFile: string): string | undefined;
|
|
|
1106
1105
|
|
|
1107
1106
|
declare function serverRequire(filePath: string | string[]): Promise<any> | null;
|
|
1108
1107
|
|
|
1109
|
-
declare function loadMainConfig({ configDir, cwd, }: {
|
|
1108
|
+
declare function loadMainConfig({ configDir, cwd, skipCache, }: {
|
|
1110
1109
|
configDir: string;
|
|
1111
1110
|
cwd?: string;
|
|
1111
|
+
skipCache?: boolean;
|
|
1112
1112
|
}): Promise<StorybookConfig>;
|
|
1113
1113
|
|
|
1114
1114
|
declare function loadManagerOrAddonsFile({ configDir }: {
|
|
@@ -1272,7 +1272,9 @@ declare const resolvePackageDir: (pkg: Parameters<ImportMeta["resolve"]>[0], par
|
|
|
1272
1272
|
* // Returns the default export or the entire module
|
|
1273
1273
|
* ```
|
|
1274
1274
|
*/
|
|
1275
|
-
declare function importModule(path: string
|
|
1275
|
+
declare function importModule(path: string, { skipCache }?: {
|
|
1276
|
+
skipCache?: boolean;
|
|
1277
|
+
}): Promise<any>;
|
|
1276
1278
|
/**
|
|
1277
1279
|
* Safely resolves a module specifier to its absolute file path.
|
|
1278
1280
|
*
|