storybook 10.1.2 → 10.1.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.
Files changed (64) hide show
  1. package/dist/_node-chunks/{builder-manager-4QKD5MM3.js → builder-manager-7ZU5KYAD.js} +12 -12
  2. package/dist/_node-chunks/{camelcase-IRQCWULJ.js → camelcase-YSJ5EORN.js} +7 -7
  3. package/dist/_node-chunks/{chunk-JTVV3ILI.js → chunk-2IIRK2OT.js} +6 -6
  4. package/dist/_node-chunks/chunk-4FAPWW5I.js +61 -0
  5. package/dist/_node-chunks/{chunk-RGS3LXAW.js → chunk-4X3VTYIW.js} +7 -7
  6. package/dist/_node-chunks/chunk-5UYX4ZF6.js +23 -0
  7. package/dist/_node-chunks/{chunk-U5ZVDYGC.js → chunk-6KX7N5UF.js} +13 -13
  8. package/dist/_node-chunks/{chunk-AKO6A5CQ.js → chunk-6O3OB2PO.js} +16 -16
  9. package/dist/_node-chunks/{chunk-ZYCQYU5P.js → chunk-76KIYDRU.js} +7 -7
  10. package/dist/_node-chunks/{chunk-4EINUCZX.js → chunk-7KESMTGS.js} +43 -27
  11. package/dist/_node-chunks/chunk-CMI5GRPA.js +18 -0
  12. package/dist/_node-chunks/{chunk-SKFB37NZ.js → chunk-COZFRL72.js} +7 -7
  13. package/dist/_node-chunks/{chunk-TTOU3O3G.js → chunk-DMPGFWI4.js} +10 -10
  14. package/dist/_node-chunks/{chunk-OUCADXTV.js → chunk-F2RDEFFH.js} +7 -7
  15. package/dist/_node-chunks/{chunk-TXYTWWZH.js → chunk-FMYFRXPU.js} +6 -6
  16. package/dist/_node-chunks/{chunk-QZH7V7G5.js → chunk-FY6IUM4S.js} +8 -8
  17. package/dist/_node-chunks/chunk-GVOXGNOU.js +20 -0
  18. package/dist/_node-chunks/{chunk-TPC5WFN2.js → chunk-J4VC4I2M.js} +6 -6
  19. package/dist/_node-chunks/{chunk-M5WCOOCM.js → chunk-LJRKMWYC.js} +6 -6
  20. package/dist/_node-chunks/{chunk-NHMTWL5A.js → chunk-MZL4HRPC.js} +7 -7
  21. package/dist/_node-chunks/{chunk-5K3HCA3T.js → chunk-N54KYQ6P.js} +6 -6
  22. package/dist/_node-chunks/{chunk-GKZHMXCG.js → chunk-Q6B5LJGA.js} +7 -7
  23. package/dist/_node-chunks/{chunk-GGJB53L3.js → chunk-QIY6TMKF.js} +7 -7
  24. package/dist/_node-chunks/{chunk-2ROLNOX5.js → chunk-QZJSO2TW.js} +39 -24
  25. package/dist/_node-chunks/{chunk-HIQU6BTN.js → chunk-RZ2YFNVH.js} +7 -7
  26. package/dist/_node-chunks/{chunk-TAK5JLJT.js → chunk-S3DQCJWT.js} +9 -9
  27. package/dist/_node-chunks/{chunk-3E6FUWUR.js → chunk-T5WYRHJT.js} +6 -6
  28. package/dist/_node-chunks/{chunk-U255RR5H.js → chunk-VBZIULNK.js} +6 -6
  29. package/dist/_node-chunks/{chunk-QTUMNOBG.js → chunk-VUIYVJKC.js} +12 -16
  30. package/dist/_node-chunks/{chunk-QXZ53NSP.js → chunk-W6O6RFMF.js} +9 -9
  31. package/dist/_node-chunks/{dist-YCWFOINJ.js → dist-NF4P7GPD.js} +9 -9
  32. package/dist/_node-chunks/{globby-DJRLVC5S.js → globby-54L4JJRV.js} +9 -9
  33. package/dist/_node-chunks/{lib-IAG3XT2U.js → lib-GX44WIWA.js} +7 -7
  34. package/dist/_node-chunks/{mdx-N42X6CFJ-QMOKL6WQ.js → mdx-N42X6CFJ-WJFAHXML.js} +8 -8
  35. package/dist/_node-chunks/{p-limit-5RGYVFOA.js → p-limit-QB7Q2I4D.js} +7 -7
  36. package/dist/babel/index.js +10 -10
  37. package/dist/bin/core.js +24 -18
  38. package/dist/bin/dispatcher.js +11 -11
  39. package/dist/bin/loader.js +9 -9
  40. package/dist/cli/index.d.ts +1 -0
  41. package/dist/cli/index.js +18 -18
  42. package/dist/common/index.d.ts +25 -18
  43. package/dist/common/index.js +19 -19
  44. package/dist/components/index.js +9 -17
  45. package/dist/core-server/index.js +33 -33
  46. package/dist/core-server/presets/common-override-preset.js +9 -9
  47. package/dist/core-server/presets/common-preset.js +25 -25
  48. package/dist/csf-tools/index.js +9 -9
  49. package/dist/manager/globals-runtime.js +10 -18
  50. package/dist/manager/runtime.js +2 -1
  51. package/dist/manager-api/index.d.ts +178 -178
  52. package/dist/manager-api/index.js +1 -1
  53. package/dist/mocking-utils/index.js +8 -8
  54. package/dist/node-logger/index.d.ts +3 -3
  55. package/dist/node-logger/index.js +9 -9
  56. package/dist/preview-api/index.d.ts +68 -67
  57. package/dist/server-errors.js +11 -11
  58. package/dist/telemetry/index.js +23 -23
  59. package/dist/types/index.d.ts +3 -1
  60. package/package.json +1 -1
  61. package/dist/_node-chunks/chunk-2SKUXRHZ.js +0 -23
  62. package/dist/_node-chunks/chunk-4ROB3WCB.js +0 -61
  63. package/dist/_node-chunks/chunk-HLP3H23G.js +0 -20
  64. package/dist/_node-chunks/chunk-NUXVDK4C.js +0 -18
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_y9c3v0cnkub from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_y9c3v0cnkub from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_y9c3v0cnkub from "node:module";
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_y9c3v0cnkub.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_y9c3v0cnkub.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_y9c3v0cnkub.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.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-3E6FUWUR.js";
16
+ } from "./chunk-T5WYRHJT.js";
17
17
  import {
18
18
  require_build
19
- } from "./chunk-SKFB37NZ.js";
19
+ } from "./chunk-COZFRL72.js";
20
20
  import {
21
21
  resolveModulePath,
22
22
  resolvePackageDir
23
- } from "./chunk-GKZHMXCG.js";
23
+ } from "./chunk-Q6B5LJGA.js";
24
24
  import {
25
25
  join,
26
26
  parse
27
- } from "./chunk-U255RR5H.js";
27
+ } from "./chunk-VBZIULNK.js";
28
28
  import {
29
29
  slash
30
- } from "./chunk-HLP3H23G.js";
30
+ } from "./chunk-GVOXGNOU.js";
31
31
  import {
32
32
  __commonJS,
33
33
  __require,
34
34
  __toESM
35
- } from "./chunk-TPC5WFN2.js";
35
+ } from "./chunk-J4VC4I2M.js";
36
36
 
37
37
  // ../node_modules/ejs/lib/utils.js
38
38
  var require_utils = __commonJS({
@@ -1,15 +1,15 @@
1
- import CJS_COMPAT_NODE_URL_y9c3v0cnkub from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_y9c3v0cnkub from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_y9c3v0cnkub from "node:module";
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_y9c3v0cnkub.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_y9c3v0cnkub.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_y9c3v0cnkub.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.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-TPC5WFN2.js";
12
+ import "./chunk-J4VC4I2M.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 CJS_COMPAT_NODE_URL_y9c3v0cnkub from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_y9c3v0cnkub from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_y9c3v0cnkub from "node:module";
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_y9c3v0cnkub.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_y9c3v0cnkub.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_y9c3v0cnkub.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.createRequire(import.meta.url);
8
8
 
9
9
  // ------------------------------------------------------------
10
10
  // end of CJS compatibility banner, injected by Storybook's esbuild configuration
@@ -0,0 +1,61 @@
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
+
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.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.1.4",
16
+ "@storybook/addon-docs": "10.1.4",
17
+ "@storybook/addon-links": "10.1.4",
18
+ "@storybook/addon-onboarding": "10.1.4",
19
+ "storybook-addon-pseudo-states": "10.1.4",
20
+ "@storybook/addon-themes": "10.1.4",
21
+ "@storybook/addon-vitest": "10.1.4",
22
+ "@storybook/builder-vite": "10.1.4",
23
+ "@storybook/builder-webpack5": "10.1.4",
24
+ storybook: "10.1.4",
25
+ "@storybook/angular": "10.1.4",
26
+ "@storybook/ember": "10.1.4",
27
+ "@storybook/html-vite": "10.1.4",
28
+ "@storybook/nextjs": "10.1.4",
29
+ "@storybook/nextjs-vite": "10.1.4",
30
+ "@storybook/preact-vite": "10.1.4",
31
+ "@storybook/react-native-web-vite": "10.1.4",
32
+ "@storybook/react-vite": "10.1.4",
33
+ "@storybook/react-webpack5": "10.1.4",
34
+ "@storybook/server-webpack5": "10.1.4",
35
+ "@storybook/svelte-vite": "10.1.4",
36
+ "@storybook/sveltekit": "10.1.4",
37
+ "@storybook/vue3-vite": "10.1.4",
38
+ "@storybook/web-components-vite": "10.1.4",
39
+ sb: "10.1.4",
40
+ "@storybook/cli": "10.1.4",
41
+ "@storybook/codemod": "10.1.4",
42
+ "@storybook/core-webpack": "10.1.4",
43
+ "create-storybook": "10.1.4",
44
+ "@storybook/csf-plugin": "10.1.4",
45
+ "eslint-plugin-storybook": "10.1.4",
46
+ "@storybook/react-dom-shim": "10.1.4",
47
+ "@storybook/preset-create-react-app": "10.1.4",
48
+ "@storybook/preset-react-webpack": "10.1.4",
49
+ "@storybook/preset-server-webpack": "10.1.4",
50
+ "@storybook/html": "10.1.4",
51
+ "@storybook/preact": "10.1.4",
52
+ "@storybook/react": "10.1.4",
53
+ "@storybook/server": "10.1.4",
54
+ "@storybook/svelte": "10.1.4",
55
+ "@storybook/vue3": "10.1.4",
56
+ "@storybook/web-components": "10.1.4"
57
+ };
58
+
59
+ export {
60
+ versions_default
61
+ };
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_y9c3v0cnkub from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_y9c3v0cnkub from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_y9c3v0cnkub from "node:module";
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_y9c3v0cnkub.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_y9c3v0cnkub.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_y9c3v0cnkub.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.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_y9c3v0cnkub.createRequire(import.meta.url);
12
12
  import {
13
13
  __commonJS,
14
14
  __require
15
- } from "./chunk-TPC5WFN2.js";
15
+ } from "./chunk-J4VC4I2M.js";
16
16
 
17
17
  // ../node_modules/picomatch/lib/constants.js
18
18
  var require_constants = __commonJS({
@@ -0,0 +1,23 @@
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
+
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.createRequire(import.meta.url);
8
+
9
+ // ------------------------------------------------------------
10
+ // end of CJS compatibility banner, injected by Storybook's esbuild configuration
11
+ // ------------------------------------------------------------
12
+ import {
13
+ any
14
+ } from "./chunk-2IIRK2OT.js";
15
+
16
+ // src/cli/detect.ts
17
+ async function detectPnp() {
18
+ return !!any([".pnp.js", ".pnp.cjs"]);
19
+ }
20
+
21
+ export {
22
+ detectPnp
23
+ };
@@ -1,35 +1,35 @@
1
- import CJS_COMPAT_NODE_URL_y9c3v0cnkub from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_y9c3v0cnkub from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_y9c3v0cnkub from "node:module";
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_y9c3v0cnkub.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_y9c3v0cnkub.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_y9c3v0cnkub.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.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-SKFB37NZ.js";
14
+ } from "./chunk-COZFRL72.js";
15
15
  import {
16
16
  StorybookError
17
- } from "./chunk-M5WCOOCM.js";
17
+ } from "./chunk-LJRKMWYC.js";
18
18
  import {
19
19
  resolvePackageDir
20
- } from "./chunk-GKZHMXCG.js";
20
+ } from "./chunk-Q6B5LJGA.js";
21
21
  import {
22
22
  relative
23
- } from "./chunk-U255RR5H.js";
23
+ } from "./chunk-VBZIULNK.js";
24
24
  import {
25
25
  require_dist
26
- } from "./chunk-ZYCQYU5P.js";
26
+ } from "./chunk-76KIYDRU.js";
27
27
  import {
28
28
  require_picocolors
29
- } from "./chunk-HIQU6BTN.js";
29
+ } from "./chunk-RZ2YFNVH.js";
30
30
  import {
31
31
  __toESM
32
- } from "./chunk-TPC5WFN2.js";
32
+ } from "./chunk-J4VC4I2M.js";
33
33
 
34
34
  // src/core-server/utils/server-statics.ts
35
35
  import { existsSync, statSync } from "node:fs";
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_y9c3v0cnkub from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_y9c3v0cnkub from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_y9c3v0cnkub from "node:module";
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_y9c3v0cnkub.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_y9c3v0cnkub.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_y9c3v0cnkub.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.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-JTVV3ILI.js";
16
+ } from "./chunk-2IIRK2OT.js";
17
17
  import {
18
18
  resolvePackageDir
19
- } from "./chunk-GKZHMXCG.js";
19
+ } from "./chunk-Q6B5LJGA.js";
20
20
  import {
21
21
  require_dist
22
- } from "./chunk-ZYCQYU5P.js";
22
+ } from "./chunk-76KIYDRU.js";
23
23
  import {
24
24
  babelParse,
25
25
  recast,
26
26
  traverse,
27
27
  types
28
- } from "./chunk-QXZ53NSP.js";
28
+ } from "./chunk-W6O6RFMF.js";
29
29
  import {
30
30
  require_picocolors
31
- } from "./chunk-HIQU6BTN.js";
31
+ } from "./chunk-RZ2YFNVH.js";
32
32
  import {
33
33
  __commonJS,
34
34
  __require,
35
35
  __toESM
36
- } from "./chunk-TPC5WFN2.js";
36
+ } from "./chunk-J4VC4I2M.js";
37
37
 
38
38
  // ../node_modules/esprima/dist/esprima.js
39
39
  var require_esprima = __commonJS({
@@ -5871,7 +5871,7 @@ var AddonVitestService = class {
5871
5871
  * @returns Array of error messages if installation fails
5872
5872
  */
5873
5873
  async installPlaywright(options = {}) {
5874
- let errors = [], playwrightCommand = ["playwright", "install", "chromium", "--with-deps"], playwrightCommandString = this.packageManager.getPackageCommand(playwrightCommand);
5874
+ let errors = [], playwrightCommand = ["playwright", "install", "chromium", "--with-deps"], playwrightCommandString = this.packageManager.getPackageCommand(playwrightCommand), result;
5875
5875
  try {
5876
5876
  (options.yes ? !0 : await (async () => (logger3.log(import_ts_dedent2.dedent`
5877
5877
  Playwright browser binaries are necessary for @storybook/addon-vitest. The download can take some time. If you don't want to wait, you can skip the installation and run the following command manually later:
@@ -5892,11 +5892,11 @@ var AddonVitestService = class {
5892
5892
  success: "Playwright browser binaries installed successfully",
5893
5893
  abortable: !0
5894
5894
  }
5895
- ) : logger3.warn("Playwright installation skipped");
5895
+ ) ? result = "aborted" : result = "installed" : (logger3.warn("Playwright installation skipped"), result = "skipped");
5896
5896
  } catch (e) {
5897
- ErrorCollector.addError(e), e instanceof Error ? errors.push(e.stack ?? e.message) : errors.push(String(e));
5897
+ result = "failed", ErrorCollector.addError(e), e instanceof Error ? errors.push(e.stack ?? e.message) : errors.push(String(e));
5898
5898
  }
5899
- return { errors };
5899
+ return { errors, result };
5900
5900
  }
5901
5901
  /**
5902
5902
  * Validate full compatibility for @storybook/addon-vitest
@@ -1,17 +1,17 @@
1
- import CJS_COMPAT_NODE_URL_y9c3v0cnkub from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_y9c3v0cnkub from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_y9c3v0cnkub from "node:module";
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_y9c3v0cnkub.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_y9c3v0cnkub.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_y9c3v0cnkub.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.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-TPC5WFN2.js";
14
+ } from "./chunk-J4VC4I2M.js";
15
15
 
16
16
  // ../node_modules/ts-dedent/dist/index.js
17
17
  var require_dist = __commonJS({
@@ -1,17 +1,17 @@
1
- import CJS_COMPAT_NODE_URL_y9c3v0cnkub from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_y9c3v0cnkub from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_y9c3v0cnkub from "node:module";
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_y9c3v0cnkub.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_y9c3v0cnkub.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_y9c3v0cnkub.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.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 "./chunk-NUXVDK4C.js";
14
+ } from "./chunk-CMI5GRPA.js";
15
15
  import {
16
16
  createFileSystemCache,
17
17
  execa,
@@ -19,25 +19,25 @@ import {
19
19
  getProjectRoot,
20
20
  resolvePathInStorybookCache,
21
21
  up
22
- } from "./chunk-2ROLNOX5.js";
22
+ } from "./chunk-QZJSO2TW.js";
23
23
  import {
24
24
  getSessionId,
25
25
  nanoid,
26
26
  set
27
- } from "./chunk-5K3HCA3T.js";
27
+ } from "./chunk-N54KYQ6P.js";
28
28
  import {
29
29
  globalSettings
30
- } from "./chunk-TAK5JLJT.js";
30
+ } from "./chunk-S3DQCJWT.js";
31
31
  import {
32
32
  resolvePackageDir
33
- } from "./chunk-GKZHMXCG.js";
33
+ } from "./chunk-Q6B5LJGA.js";
34
34
  import {
35
35
  slash
36
- } from "./chunk-HLP3H23G.js";
36
+ } from "./chunk-GVOXGNOU.js";
37
37
  import {
38
38
  __commonJS,
39
39
  __toESM
40
- } from "./chunk-TPC5WFN2.js";
40
+ } from "./chunk-J4VC4I2M.js";
41
41
 
42
42
  // ../node_modules/fetch-retry/index.js
43
43
  var require_fetch_retry = __commonJS({
@@ -76,22 +76,22 @@ var require_fetch_retry = __commonJS({
76
76
  retryOn = init.retryOn;
77
77
  else
78
78
  throw new ArgumentError("retryOn property expects an array or function");
79
- return new Promise(function(resolve, reject) {
79
+ return new Promise(function(resolve2, reject) {
80
80
  var wrappedFetch = function(attempt) {
81
81
  var _input = typeof Request < "u" && input instanceof Request ? input.clone() : input;
82
82
  fetch2(_input, init).then(function(response) {
83
83
  if (Array.isArray(retryOn) && retryOn.indexOf(response.status) === -1)
84
- resolve(response);
84
+ resolve2(response);
85
85
  else if (typeof retryOn == "function")
86
86
  try {
87
87
  return Promise.resolve(retryOn(attempt, null, response)).then(function(retryOnResponse) {
88
- retryOnResponse ? retry2(attempt, null, response) : resolve(response);
88
+ retryOnResponse ? retry2(attempt, null, response) : resolve2(response);
89
89
  }).catch(reject);
90
90
  } catch (error) {
91
91
  reject(error);
92
92
  }
93
93
  else
94
- attempt < retries ? retry2(attempt, null, response) : resolve(response);
94
+ attempt < retries ? retry2(attempt, null, response) : resolve2(response);
95
95
  }).catch(function(error) {
96
96
  if (typeof retryOn == "function")
97
97
  try {
@@ -174,8 +174,10 @@ function sanitizeError(error, pathSeparator = path.sep) {
174
174
  }
175
175
 
176
176
  // src/telemetry/storybook-metadata.ts
177
+ import { createHash } from "node:crypto";
178
+ import { existsSync as existsSync2 } from "node:fs";
177
179
  import { readFile } from "node:fs/promises";
178
- import { dirname } from "node:path";
180
+ import { dirname, resolve } from "node:path";
179
181
  import {
180
182
  getStorybookConfiguration,
181
183
  getStorybookInfo as getStorybookInfo2,
@@ -183,6 +185,7 @@ import {
183
185
  loadMainConfig,
184
186
  versions
185
187
  } from "storybook/internal/common";
188
+ import { getInterpretedFile } from "storybook/internal/common";
186
189
  import { readConfig } from "storybook/internal/csf-tools";
187
190
 
188
191
  // src/telemetry/get-application-file-count.ts
@@ -753,21 +756,34 @@ async function getPackageJsonDetails() {
753
756
  packageJson: {}
754
757
  };
755
758
  }
756
- var cachedMetadata, getStorybookMetadata = async (_configDir) => {
757
- if (cachedMetadata)
758
- return cachedMetadata;
759
+ var metadataCache = /* @__PURE__ */ new Map();
760
+ async function hashMainConfig(configDir) {
761
+ try {
762
+ let mainPath = getInterpretedFile(resolve(configDir, "main"));
763
+ if (!mainPath || !existsSync2(mainPath))
764
+ return "missing";
765
+ let content = await readFile(mainPath);
766
+ return createHash("sha256").update(new Uint8Array(content)).digest("hex");
767
+ } catch {
768
+ return "unknown";
769
+ }
770
+ }
771
+ var getStorybookMetadata = async (_configDir) => {
759
772
  let { packageJson, packageJsonPath } = await getPackageJsonDetails(), configDir = (_configDir || getStorybookConfiguration(
760
773
  String(packageJson?.scripts?.storybook || ""),
761
774
  "-c",
762
775
  "--config-dir"
763
- )) ?? ".storybook", mainConfig = await loadMainConfig({ configDir }).catch(() => {
764
- });
765
- return cachedMetadata = await computeStorybookMetadata({
776
+ )) ?? ".storybook", contentHash = await hashMainConfig(configDir), cacheKey = `${configDir}::${contentHash}`, cached = metadataCache.get(cacheKey);
777
+ if (cached)
778
+ return cached;
779
+ let mainConfig = await loadMainConfig({ configDir }).catch(() => {
780
+ }), computed = await computeStorybookMetadata({
766
781
  mainConfig,
767
782
  packageJson,
768
783
  packageJsonPath,
769
784
  configDir
770
- }), cachedMetadata;
785
+ });
786
+ return metadataCache.set(cacheKey, computed), computed;
771
787
  };
772
788
 
773
789
  // src/telemetry/telemetry.ts
@@ -783,9 +799,9 @@ import { getProjectRoot as getProjectRoot3 } from "storybook/internal/common";
783
799
  import { execSync } from "child_process";
784
800
 
785
801
  // src/telemetry/one-way-hash.ts
786
- import { createHash } from "crypto";
802
+ import { createHash as createHash2 } from "crypto";
787
803
  var oneWayHash = (payload) => {
788
- let hash = createHash("sha256");
804
+ let hash = createHash2("sha256");
789
805
  return hash.update("storybook-telemetry-salt"), hash.update(payload), hash.digest("hex");
790
806
  };
791
807
 
@@ -0,0 +1,18 @@
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
+
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.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.1.4";
15
+
16
+ export {
17
+ version
18
+ };
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_y9c3v0cnkub from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_y9c3v0cnkub from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_y9c3v0cnkub from "node:module";
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_y9c3v0cnkub.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_y9c3v0cnkub.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_y9c3v0cnkub.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.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_y9c3v0cnkub.createRequire(import.meta.url);
12
12
  import {
13
13
  __commonJS,
14
14
  __require
15
- } from "./chunk-TPC5WFN2.js";
15
+ } from "./chunk-J4VC4I2M.js";
16
16
 
17
17
  // ../node_modules/totalist/sync/index.js
18
18
  var require_sync = __commonJS({
@@ -1,26 +1,26 @@
1
- import CJS_COMPAT_NODE_URL_y9c3v0cnkub from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_y9c3v0cnkub from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_y9c3v0cnkub from "node:module";
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_y9c3v0cnkub.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_y9c3v0cnkub.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_y9c3v0cnkub.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.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
  StorybookError
14
- } from "./chunk-M5WCOOCM.js";
14
+ } from "./chunk-LJRKMWYC.js";
15
15
  import {
16
16
  require_dist
17
- } from "./chunk-ZYCQYU5P.js";
17
+ } from "./chunk-76KIYDRU.js";
18
18
  import {
19
19
  require_picocolors
20
- } from "./chunk-HIQU6BTN.js";
20
+ } from "./chunk-RZ2YFNVH.js";
21
21
  import {
22
22
  __toESM
23
- } from "./chunk-TPC5WFN2.js";
23
+ } from "./chunk-J4VC4I2M.js";
24
24
 
25
25
  // src/server-errors.ts
26
26
  var import_picocolors = __toESM(require_picocolors(), 1), import_ts_dedent = __toESM(require_dist(), 1);
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_y9c3v0cnkub from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_y9c3v0cnkub from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_y9c3v0cnkub from "node:module";
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_y9c3v0cnkub.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_y9c3v0cnkub.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_y9c3v0cnkub.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.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_y9c3v0cnkub.createRequire(import.meta.url);
12
12
  import {
13
13
  __commonJS,
14
14
  __toESM
15
- } from "./chunk-TPC5WFN2.js";
15
+ } from "./chunk-J4VC4I2M.js";
16
16
 
17
17
  // ../node_modules/balanced-match/index.js
18
18
  var require_balanced_match = __commonJS({
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_y9c3v0cnkub from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_y9c3v0cnkub from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_y9c3v0cnkub from "node:module";
1
+ import CJS_COMPAT_NODE_URL_yr66iw5gef from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_yr66iw5gef from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_yr66iw5gef from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_y9c3v0cnkub.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_y9c3v0cnkub.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_y9c3v0cnkub.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_yr66iw5gef.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_yr66iw5gef.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_yr66iw5gef.createRequire(import.meta.url);
8
8
 
9
9
  // ------------------------------------------------------------
10
10
  // end of CJS compatibility banner, injected by Storybook's esbuild configuration