storybook 10.2.0-alpha.3 → 10.2.0-alpha.4
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-Y6HZAT53.js → chunk-HX32VQZR.js} +1 -1
- package/dist/{_node-chunks/chunk-MUWHX7GN.js → _browser-chunks/chunk-JVRDBUUP.js} +20 -13
- package/dist/_browser-chunks/{chunk-DOSERVNW.js → chunk-UXVP56J6.js} +1 -1
- package/dist/_browser-chunks/{chunk-GFY5R5EY.js → chunk-V5NV5R37.js} +1 -1
- package/dist/_node-chunks/{builder-manager-U6SN6ZED.js → builder-manager-UYH5WXWQ.js} +12 -12
- package/dist/_node-chunks/{camelcase-GLXVGCEV.js → camelcase-VC2MI4D3.js} +7 -7
- package/dist/_node-chunks/{chunk-4VZME5CV.js → chunk-2LVUTXDF.js} +6 -6
- package/dist/_node-chunks/chunk-2ZQ6Y2UX.js +18 -0
- package/dist/_node-chunks/{chunk-H4BZRGVO.js → chunk-3SB46FMB.js} +8 -8
- package/dist/_node-chunks/{chunk-5ZGZ22PV.js → chunk-5IKN22PK.js} +9 -9
- package/dist/_node-chunks/{chunk-HGYHQF7Z.js → chunk-5Y2B5Y2I.js} +9 -9
- package/dist/_node-chunks/{chunk-IKSK6CEY.js → chunk-6DSSKDEB.js} +6 -6
- package/dist/_node-chunks/{chunk-LHBDNMEP.js → chunk-6RZ6ESPF.js} +12 -12
- package/dist/{_browser-chunks/chunk-FQ7SLVLR.js → _node-chunks/chunk-6XCE5DKF.js} +32 -1
- package/dist/_node-chunks/{chunk-Q27GKV7Y.js → chunk-AEF4OCMB.js} +7 -7
- package/dist/_node-chunks/chunk-ATFXKLVA.js +61 -0
- package/dist/_node-chunks/{chunk-YPCGEC3N.js → chunk-BRVASHE4.js} +21 -17
- package/dist/_node-chunks/{chunk-HKTRFCJD.js → chunk-BXGPI53U.js} +6 -6
- package/dist/_node-chunks/{chunk-5SCVRD6U.js → chunk-CSLYLE5Z.js} +6 -6
- package/dist/_node-chunks/{chunk-HYH2IT7K.js → chunk-EGGWMXFM.js} +7 -7
- package/dist/_node-chunks/{chunk-KP6H4S3L.js → chunk-HATD2DIT.js} +6 -6
- package/dist/_node-chunks/{chunk-Q47IIVLL.js → chunk-I6C74YGE.js} +8 -8
- package/dist/_node-chunks/{chunk-B6AJKALV.js → chunk-IXZ54TG6.js} +6 -6
- package/dist/_node-chunks/chunk-JUQFZI7H.js +23 -0
- package/dist/_node-chunks/{chunk-NKUDIVPF.js → chunk-KLBUL53W.js} +7 -7
- package/dist/_node-chunks/{chunk-E6CKDKNL.js → chunk-NCENIJPW.js} +7 -7
- package/dist/_node-chunks/{chunk-DO56XDMZ.js → chunk-OBFKPAHB.js} +72 -11
- package/dist/_node-chunks/{chunk-SM7QXYN4.js → chunk-OW656GJO.js} +13 -13
- package/dist/_node-chunks/{chunk-6RXAFKLM.js → chunk-S3WG5D7I.js} +7 -7
- package/dist/_node-chunks/{chunk-N3O3HJMU.js → chunk-THYQIUTI.js} +7 -7
- package/dist/_node-chunks/{chunk-C2G5ML5F.js → chunk-VHJPAZFZ.js} +7 -7
- package/dist/_node-chunks/{chunk-VKFEIIOF.js → chunk-VJ5C7NTM.js} +40 -22
- package/dist/_node-chunks/{chunk-2IFACTU4.js → chunk-WI5ZJAAJ.js} +7 -7
- package/dist/_node-chunks/{chunk-XYVZIRZC.js → chunk-X6TQDZZW.js} +6 -6
- package/dist/_node-chunks/{dist-GGDI7EVD.js → dist-ZK2DO62Y.js} +9 -9
- package/dist/_node-chunks/{globby-DY2UCDKN.js → globby-3NVGNGRX.js} +9 -9
- package/dist/_node-chunks/{lib-PFKECSVA.js → lib-ALOTNL3B.js} +7 -7
- package/dist/_node-chunks/{mdx-N42X6CFJ-OPAAI5WZ.js → mdx-N42X6CFJ-AVHGVFIO.js} +8 -8
- package/dist/_node-chunks/{p-limit-PMYE6ZFC.js → p-limit-JMHEGI5E.js} +7 -7
- package/dist/babel/index.js +10 -10
- package/dist/bin/core.js +12 -12
- package/dist/bin/dispatcher.js +11 -11
- package/dist/bin/loader.js +9 -9
- package/dist/cli/index.js +18 -18
- package/dist/common/index.js +19 -19
- package/dist/core-server/index.d.ts +68 -1
- package/dist/core-server/index.js +33 -33
- package/dist/core-server/presets/common-override-preset.js +9 -9
- package/dist/core-server/presets/common-preset.js +25 -25
- package/dist/csf/index.js +1 -1
- package/dist/csf-tools/index.js +9 -9
- package/dist/manager/globals-runtime.js +21 -2
- package/dist/manager-api/index.js +4 -4
- package/dist/manager-errors.d.ts +24 -0
- package/dist/manager-errors.js +2 -2
- package/dist/mocking-utils/index.js +8 -8
- package/dist/node-logger/index.js +9 -9
- package/dist/preview/runtime.js +21 -2
- package/dist/preview-api/index.js +1 -1
- package/dist/preview-errors.d.ts +24 -0
- package/dist/preview-errors.js +2 -2
- package/dist/server-errors.d.ts +59 -3
- package/dist/server-errors.js +22 -11
- package/dist/telemetry/index.js +23 -23
- package/package.json +1 -1
- package/dist/_node-chunks/chunk-6WHPDWFA.js +0 -61
- package/dist/_node-chunks/chunk-CFCZ5PKC.js +0 -18
- package/dist/_node-chunks/chunk-O5OIO47U.js +0 -23
|
@@ -2230,7 +2230,7 @@ var DocsContext = class {
|
|
|
2230
2230
|
}
|
|
2231
2231
|
resolveModuleExport(moduleExportOrType) {
|
|
2232
2232
|
let csfFile = this.exportsToCSFFile.get(moduleExportOrType);
|
|
2233
|
-
if (csfFile)
|
|
2233
|
+
if (!csfFile && moduleExportOrType && typeof moduleExportOrType == "object" && "default" in moduleExportOrType && (csfFile = this.exportsToCSFFile.get(moduleExportOrType.default)), csfFile)
|
|
2234
2234
|
return { type: "meta", csfFile };
|
|
2235
2235
|
let story = this.exportToStory.get(
|
|
2236
2236
|
isStory3(moduleExportOrType) ? moduleExportOrType.input : moduleExportOrType
|
|
@@ -1,15 +1,3 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_2512dr0mzhu from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_2512dr0mzhu from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_2512dr0mzhu from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_2512dr0mzhu.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_2512dr0mzhu.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_2512dr0mzhu.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
|
-
|
|
13
1
|
// src/storybook-error.ts
|
|
14
2
|
function parseErrorCode({
|
|
15
3
|
code,
|
|
@@ -43,7 +31,26 @@ var StorybookError = class _StorybookError extends Error {
|
|
|
43
31
|
* user.
|
|
44
32
|
*/
|
|
45
33
|
this.isHandledError = !1;
|
|
46
|
-
|
|
34
|
+
/**
|
|
35
|
+
* A collection of sub errors which relate to a parent error.
|
|
36
|
+
*
|
|
37
|
+
* Sub-errors are used to represent multiple related errors that occurred together. When a
|
|
38
|
+
* StorybookError with sub-errors is sent to telemetry, both the parent error and each sub-error
|
|
39
|
+
* are sent as separate telemetry events. This allows for better error tracking and debugging.
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
*
|
|
43
|
+
* ```ts
|
|
44
|
+
* const error1 = new SomeError();
|
|
45
|
+
* const error2 = new AnotherError();
|
|
46
|
+
* const parentError = new ParentError({
|
|
47
|
+
* // ... other props
|
|
48
|
+
* subErrors: [error1, error2],
|
|
49
|
+
* });
|
|
50
|
+
* ```
|
|
51
|
+
*/
|
|
52
|
+
this.subErrors = [];
|
|
53
|
+
this.category = props.category, this.documentation = props.documentation ?? !1, this.code = props.code, this.isHandledError = props.isHandledError ?? !1, this.name = props.name, this.subErrors = props.subErrors ?? [];
|
|
47
54
|
}
|
|
48
55
|
get fullErrorCode() {
|
|
49
56
|
return parseErrorCode({ code: this.code, category: this.category });
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
StorybookError
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-JVRDBUUP.js";
|
|
4
4
|
|
|
5
5
|
// src/manager-errors.ts
|
|
6
6
|
var Category = /* @__PURE__ */ ((Category2) => (Category2.MANAGER_UNCAUGHT = "MANAGER_UNCAUGHT", Category2.MANAGER_UI = "MANAGER_UI", Category2.MANAGER_API = "MANAGER_API", Category2.MANAGER_CLIENT_LOGGER = "MANAGER_CLIENT-LOGGER", Category2.MANAGER_CHANNELS = "MANAGER_CHANNELS", Category2.MANAGER_CORE_EVENTS = "MANAGER_CORE-EVENTS", Category2.MANAGER_ROUTER = "MANAGER_ROUTER", Category2.MANAGER_THEMING = "MANAGER_THEMING", Category2))(Category || {}), ProviderDoesNotExtendBaseProviderError = class extends StorybookError {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -13,26 +13,26 @@ import {
|
|
|
13
13
|
BROWSER_TARGETS,
|
|
14
14
|
NODE_TARGET,
|
|
15
15
|
SUPPORTED_FEATURES
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-6DSSKDEB.js";
|
|
17
17
|
import {
|
|
18
18
|
require_build
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-S3WG5D7I.js";
|
|
20
20
|
import {
|
|
21
21
|
resolveModulePath,
|
|
22
22
|
resolvePackageDir
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-NCENIJPW.js";
|
|
24
24
|
import {
|
|
25
25
|
join,
|
|
26
26
|
parse
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-CSLYLE5Z.js";
|
|
28
28
|
import {
|
|
29
29
|
slash
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-IXZ54TG6.js";
|
|
31
31
|
import {
|
|
32
32
|
__commonJS,
|
|
33
33
|
__require,
|
|
34
34
|
__toESM
|
|
35
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-2LVUTXDF.js";
|
|
36
36
|
|
|
37
37
|
// ../../node_modules/ejs/lib/utils.js
|
|
38
38
|
var require_utils = __commonJS({
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.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 "./chunk-
|
|
12
|
+
import "./chunk-2LVUTXDF.js";
|
|
13
13
|
|
|
14
14
|
// ../../node_modules/camelcase/index.js
|
|
15
15
|
var UPPERCASE = /[\p{Lu}]/u, LOWERCASE = /[\p{Ll}]/u, LEADING_CAPITAL = /^[\p{Lu}](?![\p{Lu}])/gu, IDENTIFIER = /([\p{Alpha}\p{N}_]|$)/u, SEPARATORS = /[_.\- ]+/, LEADING_SEPARATORS = new RegExp("^" + SEPARATORS.source), SEPARATORS_AND_IDENTIFIER = new RegExp(SEPARATORS.source + IDENTIFIER.source, "gu"), NUMBERS_AND_IDENTIFIER = new RegExp("\\d+" + IDENTIFIER.source, "gu"), preserveCamelCase = (string, toLowerCase, toUpperCase, preserveConsecutiveUppercase2) => {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import CJS_COMPAT_NODE_URL_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
|
+
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.createRequire(import.meta.url);
|
|
8
|
+
|
|
9
|
+
// ------------------------------------------------------------
|
|
10
|
+
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
+
// ------------------------------------------------------------
|
|
12
|
+
|
|
13
|
+
// package.json
|
|
14
|
+
var version = "10.2.0-alpha.4";
|
|
15
|
+
|
|
16
|
+
export {
|
|
17
|
+
version
|
|
18
|
+
};
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.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_dist
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-THYQIUTI.js";
|
|
15
15
|
import {
|
|
16
16
|
__toESM
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-2LVUTXDF.js";
|
|
18
18
|
|
|
19
19
|
// src/csf-tools/CsfFile.ts
|
|
20
20
|
var import_ts_dedent = __toESM(require_dist(), 1);
|
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.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
|
invariant
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-X6TQDZZW.js";
|
|
15
15
|
import {
|
|
16
16
|
require_dist
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-THYQIUTI.js";
|
|
18
18
|
import {
|
|
19
19
|
__export,
|
|
20
20
|
__toESM
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-2LVUTXDF.js";
|
|
22
22
|
|
|
23
23
|
// src/cli/globalSettings.ts
|
|
24
24
|
var import_ts_dedent = __toESM(require_dist(), 1);
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -12,15 +12,15 @@ var require = CJS_COMPAT_NODE_MODULE_2512dr0mzhu.createRequire(import.meta.url);
|
|
|
12
12
|
import {
|
|
13
13
|
require_lib,
|
|
14
14
|
require_src
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-EGGWMXFM.js";
|
|
16
16
|
import {
|
|
17
17
|
require_picocolors
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-AEF4OCMB.js";
|
|
19
19
|
import {
|
|
20
20
|
__commonJS,
|
|
21
21
|
__require,
|
|
22
22
|
__toESM
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-2LVUTXDF.js";
|
|
24
24
|
|
|
25
25
|
// ../../node_modules/@babel/types/lib/utils/shallowEqual.js
|
|
26
26
|
var require_shallowEqual = __commonJS({
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.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_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -13,27 +13,27 @@ import {
|
|
|
13
13
|
any,
|
|
14
14
|
invariant,
|
|
15
15
|
up2 as up
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-BXGPI53U.js";
|
|
17
17
|
import {
|
|
18
18
|
resolvePackageDir
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-NCENIJPW.js";
|
|
20
20
|
import {
|
|
21
21
|
require_dist
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-THYQIUTI.js";
|
|
23
23
|
import {
|
|
24
24
|
babelParse,
|
|
25
25
|
recast,
|
|
26
26
|
traverse,
|
|
27
27
|
types
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-5Y2B5Y2I.js";
|
|
29
29
|
import {
|
|
30
30
|
require_picocolors
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-AEF4OCMB.js";
|
|
32
32
|
import {
|
|
33
33
|
__commonJS,
|
|
34
34
|
__require,
|
|
35
35
|
__toESM
|
|
36
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-2LVUTXDF.js";
|
|
37
37
|
|
|
38
38
|
// ../../node_modules/esprima/dist/esprima.js
|
|
39
39
|
var require_esprima = __commonJS({
|
|
@@ -1,3 +1,15 @@
|
|
|
1
|
+
import CJS_COMPAT_NODE_URL_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
|
+
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.createRequire(import.meta.url);
|
|
8
|
+
|
|
9
|
+
// ------------------------------------------------------------
|
|
10
|
+
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
+
// ------------------------------------------------------------
|
|
12
|
+
|
|
1
13
|
// src/storybook-error.ts
|
|
2
14
|
function parseErrorCode({
|
|
3
15
|
code,
|
|
@@ -31,7 +43,26 @@ var StorybookError = class _StorybookError extends Error {
|
|
|
31
43
|
* user.
|
|
32
44
|
*/
|
|
33
45
|
this.isHandledError = !1;
|
|
34
|
-
|
|
46
|
+
/**
|
|
47
|
+
* A collection of sub errors which relate to a parent error.
|
|
48
|
+
*
|
|
49
|
+
* Sub-errors are used to represent multiple related errors that occurred together. When a
|
|
50
|
+
* StorybookError with sub-errors is sent to telemetry, both the parent error and each sub-error
|
|
51
|
+
* are sent as separate telemetry events. This allows for better error tracking and debugging.
|
|
52
|
+
*
|
|
53
|
+
* @example
|
|
54
|
+
*
|
|
55
|
+
* ```ts
|
|
56
|
+
* const error1 = new SomeError();
|
|
57
|
+
* const error2 = new AnotherError();
|
|
58
|
+
* const parentError = new ParentError({
|
|
59
|
+
* // ... other props
|
|
60
|
+
* subErrors: [error1, error2],
|
|
61
|
+
* });
|
|
62
|
+
* ```
|
|
63
|
+
*/
|
|
64
|
+
this.subErrors = [];
|
|
65
|
+
this.category = props.category, this.documentation = props.documentation ?? !1, this.code = props.code, this.isHandledError = props.isHandledError ?? !1, this.name = props.name, this.subErrors = props.subErrors ?? [];
|
|
35
66
|
}
|
|
36
67
|
get fullErrorCode() {
|
|
37
68
|
return parseErrorCode({ code: this.code, category: this.category });
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.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
|
__commonJS
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-2LVUTXDF.js";
|
|
15
15
|
|
|
16
16
|
// ../../node_modules/picocolors/picocolors.js
|
|
17
17
|
var require_picocolors = __commonJS({
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import CJS_COMPAT_NODE_URL_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
|
+
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.createRequire(import.meta.url);
|
|
8
|
+
|
|
9
|
+
// ------------------------------------------------------------
|
|
10
|
+
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
+
// ------------------------------------------------------------
|
|
12
|
+
|
|
13
|
+
// src/common/versions.ts
|
|
14
|
+
var versions_default = {
|
|
15
|
+
"@storybook/addon-a11y": "10.2.0-alpha.4",
|
|
16
|
+
"@storybook/addon-docs": "10.2.0-alpha.4",
|
|
17
|
+
"@storybook/addon-links": "10.2.0-alpha.4",
|
|
18
|
+
"@storybook/addon-onboarding": "10.2.0-alpha.4",
|
|
19
|
+
"storybook-addon-pseudo-states": "10.2.0-alpha.4",
|
|
20
|
+
"@storybook/addon-themes": "10.2.0-alpha.4",
|
|
21
|
+
"@storybook/addon-vitest": "10.2.0-alpha.4",
|
|
22
|
+
"@storybook/builder-vite": "10.2.0-alpha.4",
|
|
23
|
+
"@storybook/builder-webpack5": "10.2.0-alpha.4",
|
|
24
|
+
storybook: "10.2.0-alpha.4",
|
|
25
|
+
"@storybook/angular": "10.2.0-alpha.4",
|
|
26
|
+
"@storybook/ember": "10.2.0-alpha.4",
|
|
27
|
+
"@storybook/html-vite": "10.2.0-alpha.4",
|
|
28
|
+
"@storybook/nextjs": "10.2.0-alpha.4",
|
|
29
|
+
"@storybook/nextjs-vite": "10.2.0-alpha.4",
|
|
30
|
+
"@storybook/preact-vite": "10.2.0-alpha.4",
|
|
31
|
+
"@storybook/react-native-web-vite": "10.2.0-alpha.4",
|
|
32
|
+
"@storybook/react-vite": "10.2.0-alpha.4",
|
|
33
|
+
"@storybook/react-webpack5": "10.2.0-alpha.4",
|
|
34
|
+
"@storybook/server-webpack5": "10.2.0-alpha.4",
|
|
35
|
+
"@storybook/svelte-vite": "10.2.0-alpha.4",
|
|
36
|
+
"@storybook/sveltekit": "10.2.0-alpha.4",
|
|
37
|
+
"@storybook/vue3-vite": "10.2.0-alpha.4",
|
|
38
|
+
"@storybook/web-components-vite": "10.2.0-alpha.4",
|
|
39
|
+
sb: "10.2.0-alpha.4",
|
|
40
|
+
"@storybook/cli": "10.2.0-alpha.4",
|
|
41
|
+
"@storybook/codemod": "10.2.0-alpha.4",
|
|
42
|
+
"@storybook/core-webpack": "10.2.0-alpha.4",
|
|
43
|
+
"create-storybook": "10.2.0-alpha.4",
|
|
44
|
+
"@storybook/csf-plugin": "10.2.0-alpha.4",
|
|
45
|
+
"eslint-plugin-storybook": "10.2.0-alpha.4",
|
|
46
|
+
"@storybook/react-dom-shim": "10.2.0-alpha.4",
|
|
47
|
+
"@storybook/preset-create-react-app": "10.2.0-alpha.4",
|
|
48
|
+
"@storybook/preset-react-webpack": "10.2.0-alpha.4",
|
|
49
|
+
"@storybook/preset-server-webpack": "10.2.0-alpha.4",
|
|
50
|
+
"@storybook/html": "10.2.0-alpha.4",
|
|
51
|
+
"@storybook/preact": "10.2.0-alpha.4",
|
|
52
|
+
"@storybook/react": "10.2.0-alpha.4",
|
|
53
|
+
"@storybook/server": "10.2.0-alpha.4",
|
|
54
|
+
"@storybook/svelte": "10.2.0-alpha.4",
|
|
55
|
+
"@storybook/vue3": "10.2.0-alpha.4",
|
|
56
|
+
"@storybook/web-components": "10.2.0-alpha.4"
|
|
57
|
+
};
|
|
58
|
+
|
|
59
|
+
export {
|
|
60
|
+
versions_default
|
|
61
|
+
};
|
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.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_build
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-S3WG5D7I.js";
|
|
15
15
|
import {
|
|
16
16
|
StorybookError
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-6XCE5DKF.js";
|
|
18
18
|
import {
|
|
19
19
|
resolvePackageDir
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-NCENIJPW.js";
|
|
21
21
|
import {
|
|
22
22
|
relative
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-CSLYLE5Z.js";
|
|
24
24
|
import {
|
|
25
25
|
require_dist
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-THYQIUTI.js";
|
|
27
27
|
import {
|
|
28
28
|
require_picocolors
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-AEF4OCMB.js";
|
|
30
30
|
import {
|
|
31
31
|
__toESM
|
|
32
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-2LVUTXDF.js";
|
|
33
33
|
|
|
34
34
|
// src/core-server/utils/server-statics.ts
|
|
35
35
|
import { existsSync, statSync } from "node:fs";
|
|
@@ -157,7 +157,7 @@ async function getErrorLevel({
|
|
|
157
157
|
let valueFromPrompt = await promptCrashReports();
|
|
158
158
|
return valueFromPrompt !== void 0 ? valueFromPrompt ? "full" : "error" : "full";
|
|
159
159
|
}
|
|
160
|
-
async function sendTelemetryError(_error, eventType, options, blocking = !0) {
|
|
160
|
+
async function sendTelemetryError(_error, eventType, options, blocking = !0, parent) {
|
|
161
161
|
try {
|
|
162
162
|
let errorLevel = "error";
|
|
163
163
|
try {
|
|
@@ -168,7 +168,7 @@ async function sendTelemetryError(_error, eventType, options, blocking = !0) {
|
|
|
168
168
|
let precedingUpgrade = await getPrecedingUpgrade(), error = _error, errorHash;
|
|
169
169
|
"message" in error ? errorHash = error.message ? oneWayHash(error.message) : "EMPTY_MESSAGE" : errorHash = "NO_MESSAGE";
|
|
170
170
|
let { code, name, category } = error;
|
|
171
|
-
await telemetry(
|
|
171
|
+
if (await telemetry(
|
|
172
172
|
"error",
|
|
173
173
|
{
|
|
174
174
|
code,
|
|
@@ -180,14 +180,18 @@ async function sendTelemetryError(_error, eventType, options, blocking = !0) {
|
|
|
180
180
|
error: errorLevel === "full" ? error : void 0,
|
|
181
181
|
errorHash,
|
|
182
182
|
// if we ever end up sending a non-error instance, we'd like to know
|
|
183
|
-
isErrorInstance: error instanceof Error
|
|
183
|
+
isErrorInstance: error instanceof Error,
|
|
184
|
+
// Include parent error information if this is a sub-error
|
|
185
|
+
...parent ? { parent: parent.fullErrorCode } : {}
|
|
184
186
|
},
|
|
185
187
|
{
|
|
186
188
|
immediate: !0,
|
|
187
189
|
configDir: options.cliOptions.configDir || options.presetOptions?.configDir,
|
|
188
190
|
enableCrashReports: errorLevel === "full"
|
|
189
191
|
}
|
|
190
|
-
)
|
|
192
|
+
), error instanceof StorybookError && error.subErrors.length > 0)
|
|
193
|
+
for (let subError of error.subErrors)
|
|
194
|
+
subError instanceof StorybookError && await sendTelemetryError(subError, eventType, options, blocking, error);
|
|
191
195
|
}
|
|
192
196
|
} catch {
|
|
193
197
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.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_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.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_uzmhoq39aog from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_uzmhoq39aog from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_uzmhoq39aog from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_uzmhoq39aog.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_uzmhoq39aog.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_uzmhoq39aog.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -12,7 +12,7 @@ var require = CJS_COMPAT_NODE_MODULE_2512dr0mzhu.createRequire(import.meta.url);
|
|
|
12
12
|
import {
|
|
13
13
|
__commonJS,
|
|
14
14
|
__require
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-2LVUTXDF.js";
|
|
16
16
|
|
|
17
17
|
// ../../node_modules/ms/index.js
|
|
18
18
|
var require_ms = __commonJS({
|