storybook 10.2.0-beta.2 → 10.2.0-beta.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 (68) hide show
  1. package/assets/server/base-preview-head.html +66 -44
  2. package/dist/_browser-chunks/{chunk-QOXZ7W26.js → chunk-2N4WE3KZ.js} +4 -6
  3. package/dist/_node-chunks/{builder-manager-N2LWOX5D.js → builder-manager-QV5RDRX3.js} +12 -12
  4. package/dist/_node-chunks/{camelcase-5FSYVCZS.js → camelcase-BMCEZEHU.js} +7 -7
  5. package/dist/_node-chunks/{chunk-HODKH6S2.js → chunk-2MIIBCWO.js} +6 -6
  6. package/dist/_node-chunks/chunk-3G6JTYYU.js +18 -0
  7. package/dist/_node-chunks/{chunk-P2XLDRN4.js → chunk-3WAOMPEV.js} +20 -20
  8. package/dist/_node-chunks/{chunk-ZYMMEEUR.js → chunk-5BZY2EBX.js} +6 -6
  9. package/dist/_node-chunks/{chunk-J6PIL7K6.js → chunk-7C3OCMOV.js} +7 -7
  10. package/dist/_node-chunks/chunk-7CC7KOAY.js +61 -0
  11. package/dist/_node-chunks/{chunk-EABA3I6M.js → chunk-A635UKUK.js} +36 -15
  12. package/dist/_node-chunks/{chunk-6BGWV535.js → chunk-B6PRKQBU.js} +43 -25
  13. package/dist/_node-chunks/{chunk-CQFU5LUX.js → chunk-C2PW44X2.js} +20 -11
  14. package/dist/_node-chunks/{chunk-OJV6TVDO.js → chunk-DX2OTMAX.js} +7 -7
  15. package/dist/_node-chunks/{chunk-5J2THD7E.js → chunk-HNJNGHJI.js} +7 -7
  16. package/dist/_node-chunks/{chunk-GHY5BYFV.js → chunk-HSLEWKPT.js} +7 -7
  17. package/dist/_node-chunks/{chunk-HBFPHSFB.js → chunk-JGB6IJ7A.js} +6 -6
  18. package/dist/_node-chunks/{chunk-WXDEINTE.js → chunk-JZDQQ34S.js} +10 -10
  19. package/dist/_node-chunks/{chunk-XEBN3C26.js → chunk-LDPGDFBN.js} +8 -8
  20. package/dist/_node-chunks/{chunk-4VD35T6X.js → chunk-LQF2YX4Z.js} +6 -6
  21. package/dist/_node-chunks/{chunk-M4QILBFD.js → chunk-LY42XGJX.js} +7 -7
  22. package/dist/_node-chunks/{chunk-5PCZPYCJ.js → chunk-M3NUJKHF.js} +9 -9
  23. package/dist/_node-chunks/{chunk-ZQQYNNTB.js → chunk-NM76NNBF.js} +9 -9
  24. package/dist/_node-chunks/{chunk-SBB2XM7N.js → chunk-PFCD6HBP.js} +7 -7
  25. package/dist/_node-chunks/{chunk-FWIMIUHV.js → chunk-QLZIG3XC.js} +7 -7
  26. package/dist/_node-chunks/chunk-TJGUM3J6.js +23 -0
  27. package/dist/_node-chunks/{chunk-2LRLWFCA.js → chunk-TOAOZCOV.js} +16 -16
  28. package/dist/_node-chunks/{chunk-7UVJF2ZL.js → chunk-UJMJ7W5H.js} +7 -7
  29. package/dist/_node-chunks/{chunk-BTTNDYQ6.js → chunk-V2LVNLAT.js} +6 -6
  30. package/dist/_node-chunks/{chunk-PGC5F6XL.js → chunk-WC6YF7PX.js} +6 -6
  31. package/dist/_node-chunks/{chunk-2LLPTUG2.js → chunk-XOGYJBNU.js} +6 -6
  32. package/dist/_node-chunks/{chunk-M62QO44I.js → chunk-Z4WARWVA.js} +6 -6
  33. package/dist/_node-chunks/{globby-SSZCWWA6.js → globby-OVGPC72V.js} +9 -9
  34. package/dist/_node-chunks/{lib-L2HJYQNA.js → lib-GNBN4EH6.js} +7 -7
  35. package/dist/_node-chunks/{mdx-N42X6CFJ-H4SZRJXB.js → mdx-N42X6CFJ-I3J2JFL4.js} +8 -8
  36. package/dist/_node-chunks/{p-limit-EA5PER7Y.js → p-limit-2LNUZG3W.js} +7 -7
  37. package/dist/babel/index.js +10 -10
  38. package/dist/bin/core.js +12 -12
  39. package/dist/bin/dispatcher.js +11 -11
  40. package/dist/bin/loader.js +9 -9
  41. package/dist/cli/index.js +18 -18
  42. package/dist/common/index.js +19 -19
  43. package/dist/components/index.d.ts +2 -0
  44. package/dist/components/index.js +49 -16
  45. package/dist/core-server/index.js +35 -35
  46. package/dist/core-server/presets/common-manager.js +15 -21
  47. package/dist/core-server/presets/common-override-preset.js +9 -9
  48. package/dist/core-server/presets/common-preset.js +25 -25
  49. package/dist/csf/index.d.ts +333 -8
  50. package/dist/csf/index.js +1 -1
  51. package/dist/csf-tools/index.js +9 -9
  52. package/dist/manager/globals-runtime.js +58 -25
  53. package/dist/manager/runtime.js +167 -148
  54. package/dist/manager-api/index.d.ts +13 -13
  55. package/dist/manager-api/index.js +1 -1
  56. package/dist/mocking-utils/index.js +8 -8
  57. package/dist/node-logger/index.js +9 -9
  58. package/dist/preview/runtime.js +4 -6
  59. package/dist/preview-api/index.d.ts +69 -68
  60. package/dist/preview-api/index.js +1 -1
  61. package/dist/server-errors.js +11 -11
  62. package/dist/telemetry/index.d.ts +5 -0
  63. package/dist/telemetry/index.js +23 -23
  64. package/dist/types/index.d.ts +2 -3
  65. package/package.json +1 -1
  66. package/dist/_node-chunks/chunk-2WBHN5ZN.js +0 -23
  67. package/dist/_node-chunks/chunk-ADG4FYMH.js +0 -61
  68. package/dist/_node-chunks/chunk-J4YBZOS2.js +0 -18
@@ -2,19 +2,19 @@
2
2
 
3
3
  <style>
4
4
  /* While we aren't showing the main block yet, but still preparing, we want everything the user has rendered, which may or may not be in #storybook-root, to be display none */
5
- .sb-show-preparing-story:not(.sb-show-main) > :not(.sb-preparing-story) {
5
+ .sb-show-preparing-story:not(.sb-show-main)> :not(.sb-preparing-story) {
6
6
  display: none;
7
7
  }
8
8
 
9
- .sb-show-preparing-docs:not(.sb-show-main) > :not(.sb-preparing-docs) {
9
+ .sb-show-preparing-docs:not(.sb-show-main)> :not(.sb-preparing-docs) {
10
10
  display: none;
11
11
  }
12
12
 
13
13
  /* Hide our own blocks when we aren't supposed to be showing them */
14
- :not(.sb-show-preparing-story) > .sb-preparing-story,
15
- :not(.sb-show-preparing-docs) > .sb-preparing-docs,
16
- :not(.sb-show-nopreview) > .sb-nopreview,
17
- :not(.sb-show-errordisplay) > .sb-errordisplay {
14
+ :not(.sb-show-preparing-story)>.sb-preparing-story,
15
+ :not(.sb-show-preparing-docs)>.sb-preparing-docs,
16
+ :not(.sb-show-nopreview)>.sb-nopreview,
17
+ :not(.sb-show-errordisplay)>.sb-errordisplay {
18
18
  display: none;
19
19
  }
20
20
 
@@ -34,7 +34,8 @@
34
34
  }
35
35
 
36
36
  /* Vertical centering fix for IE11 */
37
- @media screen and (-ms-high-contrast: none), (-ms-high-contrast: active) {
37
+ @media screen and (-ms-high-contrast: none),
38
+ (-ms-high-contrast: active) {
38
39
  .sb-show-main.sb-main-centered:after {
39
40
  content: '';
40
41
  min-height: inherit;
@@ -110,7 +111,13 @@
110
111
  margin: auto;
111
112
  padding: 30px;
112
113
  border-radius: 10px;
113
- background: rgba(0, 0, 0, 0.03);
114
+ background: rgb(247, 247, 247);
115
+ color: rgb(46, 52, 56);
116
+
117
+ & * {
118
+ background: rgb(247, 247, 247);
119
+ color: rgb(46, 52, 56);
120
+ }
114
121
  }
115
122
 
116
123
  .sb-nopreview_heading {
@@ -124,12 +131,35 @@
124
131
  width: 100vw;
125
132
  min-height: 100vh;
126
133
  box-sizing: border-box;
134
+ }
135
+
136
+ .sb-errordisplay_main {
137
+ margin: auto;
138
+ padding: 24px;
139
+ display: flex;
140
+ box-sizing: border-box;
141
+
142
+ flex-direction: column;
143
+ min-height: 100%;
144
+ width: 100%;
145
+ border-radius: 6px;
146
+ background: white;
147
+ color: black;
148
+ border: 1px solid #ff0000;
149
+ box-shadow: 0 0 64px rgba(0, 0, 0, 0.1);
150
+ gap: 24px;
127
151
 
128
152
  & ol {
129
153
  padding-left: 18px;
130
154
  margin: 0;
131
155
  }
132
156
 
157
+ /* Redefine colors to ensure readability regardless of user-provided * selectors. */
158
+ * {
159
+ background: white;
160
+ color: black;
161
+ }
162
+
133
163
  & h1 {
134
164
  font-family: Nunito Sans;
135
165
  font-size: 22px;
@@ -158,7 +188,7 @@
158
188
  margin: 0;
159
189
  }
160
190
 
161
- & li + li {
191
+ & li+li {
162
192
  margin: 0;
163
193
  padding: 0;
164
194
  padding-top: 12px;
@@ -167,47 +197,37 @@
167
197
  & a {
168
198
  color: currentColor;
169
199
  }
170
- }
171
200
 
172
- .sb-errordisplay_main {
173
- margin: auto;
174
- padding: 24px;
175
- display: flex;
176
- box-sizing: border-box;
201
+ & .sb-errordisplay_code {
202
+ padding: 10px;
203
+ flex: 1;
204
+ background: #242424;
205
+ color: #c6c6c6;
206
+ box-sizing: border-box;
177
207
 
178
- flex-direction: column;
179
- min-height: 100%;
180
- width: 100%;
181
- border-radius: 6px;
182
- background: white;
183
- border: 1px solid #ff0000;
184
- box-shadow: 0 0 64px rgba(0, 0, 0, 0.1);
185
- gap: 24px;
186
- }
208
+ font-size: 14px;
209
+ font-weight: 400;
210
+ line-height: 19px;
211
+ border-radius: 4px;
187
212
 
188
- .sb-errordisplay_code {
189
- padding: 10px;
190
- flex: 1;
191
- background: #242424;
192
- color: #c6c6c6;
193
- box-sizing: border-box;
213
+ font-family:
214
+ 'Operator Mono', 'Fira Code Retina', 'Fira Code', 'FiraCode-Retina', 'Andale Mono',
215
+ 'Lucida Console', Consolas, Monaco, monospace;
216
+ margin: 0;
217
+ overflow: auto;
194
218
 
195
- font-size: 14px;
196
- font-weight: 400;
197
- line-height: 19px;
198
- border-radius: 4px;
219
+ & code {
220
+ background-color: inherit;
221
+ color: inherit;
222
+ }
223
+ }
199
224
 
200
- font-family:
201
- 'Operator Mono', 'Fira Code Retina', 'Fira Code', 'FiraCode-Retina', 'Andale Mono',
202
- 'Lucida Console', Consolas, Monaco, monospace;
203
- margin: 0;
204
- overflow: auto;
225
+ & .sb-errordisplay pre {
226
+ white-space: pre-wrap;
227
+ white-space: revert;
228
+ }
205
229
  }
206
230
 
207
- .sb-errordisplay pre {
208
- white-space: pre-wrap;
209
- white-space: revert;
210
- }
211
231
 
212
232
  @-webkit-keyframes sb-rotate360 {
213
233
  from {
@@ -230,6 +250,7 @@
230
250
  }
231
251
 
232
252
  @-webkit-keyframes sb-glow {
253
+
233
254
  0%,
234
255
  100% {
235
256
  opacity: 1;
@@ -241,6 +262,7 @@
241
262
  }
242
263
 
243
264
  @keyframes sb-glow {
265
+
244
266
  0%,
245
267
  100% {
246
268
  opacity: 1;
@@ -468,4 +490,4 @@
468
490
  // eslint-disable-next-line no-console
469
491
  console.warn('unable to connect to top frame for connecting dev tools');
470
492
  }
471
- </script>
493
+ </script>
@@ -461,8 +461,8 @@ var ArgsStore = class {
461
461
  // src/preview-api/modules/store/GlobalsStore.ts
462
462
  import { logger as logger2 } from "storybook/internal/client-logger";
463
463
 
464
- // src/preview-api/modules/store/csf/getValuesFromArgTypes.ts
465
- var getValuesFromArgTypes = (argTypes = {}) => Object.entries(argTypes).reduce((acc, [arg, { defaultValue }]) => (typeof defaultValue < "u" && (acc[arg] = defaultValue), acc), {});
464
+ // src/preview-api/modules/store/csf/getValuesFromGlobalTypes.ts
465
+ var getValuesFromGlobalTypes = (globalTypes = {}) => Object.entries(globalTypes).reduce((acc, [arg, { defaultValue }]) => (typeof defaultValue < "u" && (acc[arg] = defaultValue), acc), {});
466
466
 
467
467
  // src/preview-api/modules/store/GlobalsStore.ts
468
468
  var GlobalsStore = class {
@@ -475,7 +475,7 @@ var GlobalsStore = class {
475
475
  set({ globals = {}, globalTypes = {} }) {
476
476
  let delta = this.initialGlobals && deepDiff(this.initialGlobals, this.globals);
477
477
  this.allowedGlobalNames = /* @__PURE__ */ new Set([...Object.keys(globals), ...Object.keys(globalTypes)]);
478
- let defaultGlobals = getValuesFromArgTypes(globalTypes);
478
+ let defaultGlobals = getValuesFromGlobalTypes(globalTypes);
479
479
  this.initialGlobals = { ...defaultGlobals, ...globals }, this.globals = this.initialGlobals, delta && delta !== DEEPLY_EQUAL && this.updateFromPersisted(delta);
480
480
  }
481
481
  filterAllowedGlobals(globals) {
@@ -994,7 +994,6 @@ inferControls.secondPass = !0;
994
994
  // src/preview-api/modules/store/csf/normalizeProjectAnnotations.ts
995
995
  function normalizeProjectAnnotations({
996
996
  argTypes,
997
- globalTypes,
998
997
  argTypesEnhancers,
999
998
  decorators,
1000
999
  loaders,
@@ -1005,7 +1004,6 @@ function normalizeProjectAnnotations({
1005
1004
  }) {
1006
1005
  return {
1007
1006
  ...argTypes && { argTypes: normalizeInputTypes(argTypes) },
1008
- ...globalTypes && { globalTypes: normalizeInputTypes(globalTypes) },
1009
1007
  decorators: normalizeArrays(decorators),
1010
1008
  loaders: normalizeArrays(loaders),
1011
1009
  beforeEach: normalizeArrays(beforeEach),
@@ -1167,7 +1165,7 @@ function composeStory(storyAnnotations, componentAnnotations, projectAnnotations
1167
1165
  normalizedComponentAnnotations,
1168
1166
  normalizedProjectAnnotations
1169
1167
  ), globals = {
1170
- ...getValuesFromArgTypes(normalizedProjectAnnotations.globalTypes),
1168
+ ...getValuesFromGlobalTypes(normalizedProjectAnnotations.globalTypes),
1171
1169
  ...normalizedProjectAnnotations.initialGlobals,
1172
1170
  ...story.storyGlobals
1173
1171
  }, reporting = new ReporterAPI(), initializeContext = () => {
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_dxneh53ovgi from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_dxneh53ovgi from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_dxneh53ovgi from "node:module";
1
+ import CJS_COMPAT_NODE_URL_96u9uvlttj6 from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_96u9uvlttj6 from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_96u9uvlttj6 from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_dxneh53ovgi.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_dxneh53ovgi.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_dxneh53ovgi.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_96u9uvlttj6.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_96u9uvlttj6.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_96u9uvlttj6.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-M62QO44I.js";
16
+ } from "./chunk-Z4WARWVA.js";
17
17
  import {
18
18
  require_build
19
- } from "./chunk-J6PIL7K6.js";
19
+ } from "./chunk-7C3OCMOV.js";
20
20
  import {
21
21
  resolveModulePath,
22
22
  resolvePackageDir
23
- } from "./chunk-SBB2XM7N.js";
23
+ } from "./chunk-PFCD6HBP.js";
24
24
  import {
25
25
  join,
26
26
  parse
27
- } from "./chunk-HODKH6S2.js";
27
+ } from "./chunk-2MIIBCWO.js";
28
28
  import {
29
29
  slash
30
- } from "./chunk-HBFPHSFB.js";
30
+ } from "./chunk-JGB6IJ7A.js";
31
31
  import {
32
32
  __commonJS,
33
33
  __require,
34
34
  __toESM
35
- } from "./chunk-ZYMMEEUR.js";
35
+ } from "./chunk-5BZY2EBX.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_dxneh53ovgi from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_dxneh53ovgi from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_dxneh53ovgi from "node:module";
1
+ import CJS_COMPAT_NODE_URL_96u9uvlttj6 from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_96u9uvlttj6 from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_96u9uvlttj6 from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_dxneh53ovgi.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_dxneh53ovgi.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_dxneh53ovgi.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_96u9uvlttj6.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_96u9uvlttj6.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_96u9uvlttj6.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-ZYMMEEUR.js";
12
+ import "./chunk-5BZY2EBX.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}])/u, SEPARATORS = /[_.\- ]+/, IDENTIFIER = /([\p{Alpha}\p{N}_]|$)/u, LEADING_SEPARATORS = new RegExp("^" + SEPARATORS.source), SEPARATORS_AND_IDENTIFIER = new RegExp(SEPARATORS.source + IDENTIFIER.source, "gu"), NUMBERS_AND_IDENTIFIER = new RegExp(String.raw`\d+` + IDENTIFIER.source, "gu"), preserveCamelCase = (string, toLowerCase, toUpperCase, preserveConsecutiveUppercase2) => {
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_dxneh53ovgi from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_dxneh53ovgi from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_dxneh53ovgi from "node:module";
1
+ import CJS_COMPAT_NODE_URL_96u9uvlttj6 from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_96u9uvlttj6 from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_96u9uvlttj6 from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_dxneh53ovgi.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_dxneh53ovgi.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_dxneh53ovgi.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_96u9uvlttj6.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_96u9uvlttj6.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_96u9uvlttj6.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_96u9uvlttj6 from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_96u9uvlttj6 from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_96u9uvlttj6 from "node:module";
4
+
5
+ var __filename = CJS_COMPAT_NODE_URL_96u9uvlttj6.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_96u9uvlttj6.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_96u9uvlttj6.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-beta.4";
15
+
16
+ export {
17
+ version
18
+ };
@@ -1,25 +1,25 @@
1
- import CJS_COMPAT_NODE_URL_dxneh53ovgi from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_dxneh53ovgi from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_dxneh53ovgi from "node:module";
1
+ import CJS_COMPAT_NODE_URL_96u9uvlttj6 from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_96u9uvlttj6 from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_96u9uvlttj6 from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_dxneh53ovgi.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_dxneh53ovgi.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_dxneh53ovgi.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_96u9uvlttj6.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_96u9uvlttj6.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_96u9uvlttj6.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
  versions_default
14
- } from "./chunk-ADG4FYMH.js";
14
+ } from "./chunk-7CC7KOAY.js";
15
15
  import {
16
16
  require_picomatch,
17
17
  toPath,
18
18
  traversePathUp
19
- } from "./chunk-5J2THD7E.js";
19
+ } from "./chunk-HNJNGHJI.js";
20
20
  import {
21
21
  logger
22
- } from "./chunk-XEBN3C26.js";
22
+ } from "./chunk-LDPGDFBN.js";
23
23
  import {
24
24
  any,
25
25
  detectIndent,
@@ -27,31 +27,31 @@ import {
27
27
  invariant,
28
28
  up,
29
29
  up2
30
- } from "./chunk-BTTNDYQ6.js";
30
+ } from "./chunk-V2LVNLAT.js";
31
31
  import {
32
32
  importModule,
33
33
  resolveModulePath,
34
34
  resolvePackageDir,
35
35
  safeResolveModule
36
- } from "./chunk-SBB2XM7N.js";
36
+ } from "./chunk-PFCD6HBP.js";
37
37
  import {
38
38
  join,
39
39
  parse,
40
40
  resolve
41
- } from "./chunk-HODKH6S2.js";
41
+ } from "./chunk-2MIIBCWO.js";
42
42
  import {
43
43
  slash
44
- } from "./chunk-HBFPHSFB.js";
44
+ } from "./chunk-JGB6IJ7A.js";
45
45
  import {
46
46
  glob,
47
47
  globSync
48
- } from "./chunk-FWIMIUHV.js";
48
+ } from "./chunk-QLZIG3XC.js";
49
49
  import {
50
50
  require_dist
51
- } from "./chunk-7UVJF2ZL.js";
51
+ } from "./chunk-UJMJ7W5H.js";
52
52
  import {
53
53
  require_picocolors
54
- } from "./chunk-OJV6TVDO.js";
54
+ } from "./chunk-DX2OTMAX.js";
55
55
  import {
56
56
  __commonJS,
57
57
  __esm,
@@ -59,7 +59,7 @@ import {
59
59
  __require,
60
60
  __toCommonJS,
61
61
  __toESM
62
- } from "./chunk-ZYMMEEUR.js";
62
+ } from "./chunk-5BZY2EBX.js";
63
63
 
64
64
  // ../../node_modules/resolve/lib/homedir.js
65
65
  var require_homedir = __commonJS({
@@ -11083,7 +11083,7 @@ function normalizeStoryPath(filename) {
11083
11083
 
11084
11084
  // src/common/utils/envs.ts
11085
11085
  async function loadEnvs(options = {}) {
11086
- let { getEnvironment } = await import("./lib-L2HJYQNA.js"), defaultNodeEnv = options.production ? "production" : "development", baseEnv = {
11086
+ let { getEnvironment } = await import("./lib-GNBN4EH6.js"), defaultNodeEnv = options.production ? "production" : "development", baseEnv = {
11087
11087
  // eslint-disable-next-line @typescript-eslint/dot-notation
11088
11088
  NODE_ENV: process.env.NODE_ENV || defaultNodeEnv,
11089
11089
  NODE_PATH: process.env.NODE_PATH || "",
@@ -18552,7 +18552,7 @@ async function scanAndTransformFiles({
18552
18552
  initialValue: defaultGlob
18553
18553
  });
18554
18554
  logger15.log("Scanning for affected files...");
18555
- let globby = (await import("./globby-SSZCWWA6.js")).globby, sourceFiles = await globby([glob2], {
18555
+ let globby = (await import("./globby-OVGPC72V.js")).globby, sourceFiles = await globby([glob2], {
18556
18556
  ...commonGlobOptions(""),
18557
18557
  ignore: ["**/node_modules/**"],
18558
18558
  dot: !0,
@@ -18573,7 +18573,7 @@ function transformImports(source, renamedImports) {
18573
18573
  return hasChanges ? transformed : null;
18574
18574
  }
18575
18575
  var transformImportFiles = async (files, renamedImports, dryRun) => {
18576
- let errors = [], { default: pLimit } = await import("./p-limit-EA5PER7Y.js"), limit = pLimit(10);
18576
+ let errors = [], { default: pLimit } = await import("./p-limit-2LNUZG3W.js"), limit = pLimit(10);
18577
18577
  return await Promise.all(
18578
18578
  files.map(
18579
18579
  (file) => limit(async () => {
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_dxneh53ovgi from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_dxneh53ovgi from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_dxneh53ovgi from "node:module";
1
+ import CJS_COMPAT_NODE_URL_96u9uvlttj6 from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_96u9uvlttj6 from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_96u9uvlttj6 from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_dxneh53ovgi.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_dxneh53ovgi.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_dxneh53ovgi.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_96u9uvlttj6.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_96u9uvlttj6.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_96u9uvlttj6.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 CJS_COMPAT_NODE_URL_dxneh53ovgi from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_dxneh53ovgi from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_dxneh53ovgi from "node:module";
1
+ import CJS_COMPAT_NODE_URL_96u9uvlttj6 from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_96u9uvlttj6 from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_96u9uvlttj6 from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_dxneh53ovgi.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_dxneh53ovgi.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_dxneh53ovgi.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_96u9uvlttj6.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_96u9uvlttj6.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_96u9uvlttj6.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_dxneh53ovgi.createRequire(import.meta.url);
12
12
  import {
13
13
  __commonJS,
14
14
  __require
15
- } from "./chunk-ZYMMEEUR.js";
15
+ } from "./chunk-5BZY2EBX.js";
16
16
 
17
17
  // ../../node_modules/totalist/sync/index.js
18
18
  var require_sync = __commonJS({
@@ -0,0 +1,61 @@
1
+ import CJS_COMPAT_NODE_URL_96u9uvlttj6 from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_96u9uvlttj6 from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_96u9uvlttj6 from "node:module";
4
+
5
+ var __filename = CJS_COMPAT_NODE_URL_96u9uvlttj6.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_96u9uvlttj6.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_96u9uvlttj6.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-beta.4",
16
+ "@storybook/addon-docs": "10.2.0-beta.4",
17
+ "@storybook/addon-links": "10.2.0-beta.4",
18
+ "@storybook/addon-onboarding": "10.2.0-beta.4",
19
+ "storybook-addon-pseudo-states": "10.2.0-beta.4",
20
+ "@storybook/addon-themes": "10.2.0-beta.4",
21
+ "@storybook/addon-vitest": "10.2.0-beta.4",
22
+ "@storybook/builder-vite": "10.2.0-beta.4",
23
+ "@storybook/builder-webpack5": "10.2.0-beta.4",
24
+ storybook: "10.2.0-beta.4",
25
+ "@storybook/angular": "10.2.0-beta.4",
26
+ "@storybook/ember": "10.2.0-beta.4",
27
+ "@storybook/html-vite": "10.2.0-beta.4",
28
+ "@storybook/nextjs": "10.2.0-beta.4",
29
+ "@storybook/nextjs-vite": "10.2.0-beta.4",
30
+ "@storybook/preact-vite": "10.2.0-beta.4",
31
+ "@storybook/react-native-web-vite": "10.2.0-beta.4",
32
+ "@storybook/react-vite": "10.2.0-beta.4",
33
+ "@storybook/react-webpack5": "10.2.0-beta.4",
34
+ "@storybook/server-webpack5": "10.2.0-beta.4",
35
+ "@storybook/svelte-vite": "10.2.0-beta.4",
36
+ "@storybook/sveltekit": "10.2.0-beta.4",
37
+ "@storybook/vue3-vite": "10.2.0-beta.4",
38
+ "@storybook/web-components-vite": "10.2.0-beta.4",
39
+ sb: "10.2.0-beta.4",
40
+ "@storybook/cli": "10.2.0-beta.4",
41
+ "@storybook/codemod": "10.2.0-beta.4",
42
+ "@storybook/core-webpack": "10.2.0-beta.4",
43
+ "create-storybook": "10.2.0-beta.4",
44
+ "@storybook/csf-plugin": "10.2.0-beta.4",
45
+ "eslint-plugin-storybook": "10.2.0-beta.4",
46
+ "@storybook/react-dom-shim": "10.2.0-beta.4",
47
+ "@storybook/preset-create-react-app": "10.2.0-beta.4",
48
+ "@storybook/preset-react-webpack": "10.2.0-beta.4",
49
+ "@storybook/preset-server-webpack": "10.2.0-beta.4",
50
+ "@storybook/html": "10.2.0-beta.4",
51
+ "@storybook/preact": "10.2.0-beta.4",
52
+ "@storybook/react": "10.2.0-beta.4",
53
+ "@storybook/server": "10.2.0-beta.4",
54
+ "@storybook/svelte": "10.2.0-beta.4",
55
+ "@storybook/vue3": "10.2.0-beta.4",
56
+ "@storybook/web-components": "10.2.0-beta.4"
57
+ };
58
+
59
+ export {
60
+ versions_default
61
+ };
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_dxneh53ovgi from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_dxneh53ovgi from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_dxneh53ovgi from "node:module";
1
+ import CJS_COMPAT_NODE_URL_96u9uvlttj6 from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_96u9uvlttj6 from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_96u9uvlttj6 from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_dxneh53ovgi.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_dxneh53ovgi.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_dxneh53ovgi.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_96u9uvlttj6.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_96u9uvlttj6.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_96u9uvlttj6.createRequire(import.meta.url);
8
8
 
9
9
  // ------------------------------------------------------------
10
10
  // end of CJS compatibility banner, injected by Storybook's esbuild configuration
@@ -14,27 +14,27 @@ import {
14
14
  detectIndent,
15
15
  invariant,
16
16
  up2 as up
17
- } from "./chunk-BTTNDYQ6.js";
17
+ } from "./chunk-V2LVNLAT.js";
18
18
  import {
19
19
  resolvePackageDir
20
- } from "./chunk-SBB2XM7N.js";
20
+ } from "./chunk-PFCD6HBP.js";
21
21
  import {
22
22
  require_dist
23
- } from "./chunk-7UVJF2ZL.js";
23
+ } from "./chunk-UJMJ7W5H.js";
24
24
  import {
25
25
  babelParse,
26
26
  recast,
27
27
  traverse,
28
28
  types
29
- } from "./chunk-5PCZPYCJ.js";
29
+ } from "./chunk-M3NUJKHF.js";
30
30
  import {
31
31
  require_picocolors
32
- } from "./chunk-OJV6TVDO.js";
32
+ } from "./chunk-DX2OTMAX.js";
33
33
  import {
34
34
  __commonJS,
35
35
  __require,
36
36
  __toESM
37
- } from "./chunk-ZYMMEEUR.js";
37
+ } from "./chunk-5BZY2EBX.js";
38
38
 
39
39
  // ../../node_modules/esprima/dist/esprima.js
40
40
  var require_esprima = __commonJS({
@@ -5621,13 +5621,19 @@ function unwrapTSExpression(expr) {
5621
5621
  return expr && (types.isTSAsExpression(expr) || types.isTSSatisfiesExpression(expr) ? unwrapTSExpression(expr.expression) : expr);
5622
5622
  }
5623
5623
  var configureFlatConfig = async (code) => {
5624
- let ast = babelParse(code), tsEslintLocalName = "", eslintConfigExpression = null;
5624
+ let ast = babelParse(code), tsEslintLocalName = "", eslintDefineConfigLocalName = "", eslintConfigExpression = null;
5625
5625
  return traverse(ast, {
5626
5626
  ImportDeclaration(path2) {
5627
5627
  if (path2.node.source.value === "typescript-eslint") {
5628
5628
  let defaultSpecifier = path2.node.specifiers.find((s) => types.isImportDefaultSpecifier(s));
5629
5629
  defaultSpecifier && (tsEslintLocalName = defaultSpecifier.local.name);
5630
5630
  }
5631
+ if (path2.node.source.value === "eslint/config") {
5632
+ let defineConfigSpecifier = path2.node.specifiers.find(
5633
+ (s) => types.isImportSpecifier(s) && types.isIdentifier(s.imported, { name: "defineConfig" })
5634
+ );
5635
+ defineConfigSpecifier && types.isImportSpecifier(defineConfigSpecifier) && (eslintDefineConfigLocalName = defineConfigSpecifier.local.name);
5636
+ }
5631
5637
  },
5632
5638
  ExportDefaultDeclaration(path2) {
5633
5639
  let node = path2.node;
@@ -5637,11 +5643,26 @@ var configureFlatConfig = async (code) => {
5637
5643
  types.stringLiteral("flat/recommended"),
5638
5644
  !0
5639
5645
  );
5640
- if (types.isArrayExpression(eslintConfigExpression) && eslintConfigExpression.elements.push(types.spreadElement(storybookConfig)), types.isCallExpression(eslintConfigExpression) && types.isMemberExpression(eslintConfigExpression.callee) && tsEslintLocalName && types.isIdentifier(eslintConfigExpression.callee.object, { name: tsEslintLocalName }) && types.isIdentifier(eslintConfigExpression.callee.property, { name: "config" }) && eslintConfigExpression.arguments.push(storybookConfig), types.isIdentifier(eslintConfigExpression)) {
5646
+ if (types.isArrayExpression(eslintConfigExpression) && eslintConfigExpression.elements.push(types.spreadElement(storybookConfig)), types.isCallExpression(eslintConfigExpression) && types.isMemberExpression(eslintConfigExpression.callee) && tsEslintLocalName && types.isIdentifier(eslintConfigExpression.callee.object, { name: tsEslintLocalName }) && types.isIdentifier(eslintConfigExpression.callee.property, { name: "config" }) && eslintConfigExpression.arguments.push(storybookConfig), types.isCallExpression(eslintConfigExpression) && types.isIdentifier(eslintConfigExpression.callee) && eslintDefineConfigLocalName && eslintConfigExpression.callee.name === eslintDefineConfigLocalName && eslintConfigExpression.arguments.length > 0) {
5647
+ let firstArg = eslintConfigExpression.arguments[0];
5648
+ if (types.isExpression(firstArg)) {
5649
+ let unwrappedArg = unwrapTSExpression(firstArg);
5650
+ unwrappedArg && types.isArrayExpression(unwrappedArg) && unwrappedArg.elements.push(types.spreadElement(storybookConfig));
5651
+ }
5652
+ }
5653
+ if (types.isIdentifier(eslintConfigExpression)) {
5641
5654
  let binding = path2.scope.getBinding(eslintConfigExpression.name);
5642
5655
  if (binding && types.isVariableDeclarator(binding.path.node)) {
5643
5656
  let init = unwrapTSExpression(binding.path.node.init);
5644
- types.isArrayExpression(init) && init.elements.push(types.spreadElement(storybookConfig));
5657
+ if (types.isArrayExpression(init))
5658
+ init.elements.push(types.spreadElement(storybookConfig));
5659
+ else if (types.isCallExpression(init) && init.arguments.length > 0 && types.isIdentifier(init.callee) && eslintDefineConfigLocalName && init.callee.name === eslintDefineConfigLocalName) {
5660
+ let firstArg = init.arguments[0];
5661
+ if (types.isExpression(firstArg)) {
5662
+ let unwrappedArg = unwrapTSExpression(firstArg);
5663
+ unwrappedArg && types.isArrayExpression(unwrappedArg) && unwrappedArg.elements.push(types.spreadElement(storybookConfig));
5664
+ }
5665
+ }
5645
5666
  }
5646
5667
  }
5647
5668
  },