storybook 10.0.0-beta.5 → 10.0.0-beta.7

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 (88) hide show
  1. package/assets/server/openBrowser.applescript +94 -0
  2. package/dist/_browser-chunks/{WithTooltip-ERFLZL6W.js → WithTooltip-SK46ZJ2J.js} +1 -1
  3. package/dist/_browser-chunks/{chunk-EOILZP2R.js → chunk-BOOOPFZF.js} +7 -2
  4. package/dist/_browser-chunks/{chunk-YQV3EGQ5.js → chunk-OQ6NCFPL.js} +38 -15
  5. package/dist/_browser-chunks/{chunk-O5R5CGFA.js → chunk-TMDZCWME.js} +1 -2
  6. package/dist/_node-chunks/{builder-manager-ZTS4EIKQ.js → builder-manager-VFP7HSCF.js} +21 -151
  7. package/dist/_node-chunks/camelcase-ZLZNQMDD.js +18 -0
  8. package/dist/_node-chunks/{chunk-VQN4WAIA.js → chunk-2GCKJYK6.js} +7 -7
  9. package/dist/_node-chunks/{chunk-H52PBBSK.js → chunk-3NIQHNDU.js} +7 -7
  10. package/dist/_node-chunks/{chunk-3VVGIILJ.js → chunk-3QZ7KLON.js} +8 -8
  11. package/dist/_node-chunks/{chunk-VWSUFVUF.js → chunk-3XXQRL3A.js} +7 -7
  12. package/dist/_node-chunks/{chunk-OC3TVLYU.js → chunk-46BWYN3K.js} +7 -7
  13. package/dist/_node-chunks/{chunk-VX5P3IYA.js → chunk-4DIDWIST.js} +7 -7
  14. package/dist/_node-chunks/{chunk-TBWOUVTA.js → chunk-5YUTWYNI.js} +709 -935
  15. package/dist/_node-chunks/{chunk-4VDRH7SM.js → chunk-A2DKPKBY.js} +7 -7
  16. package/dist/_node-chunks/{chunk-KU3JBNPY.js → chunk-BC23FKU4.js} +8 -8
  17. package/dist/_node-chunks/{chunk-KZB7ELL6.js → chunk-BID2X7MU.js} +7 -7
  18. package/dist/_node-chunks/{chunk-PIKDGR3O.js → chunk-C4EOB63P.js} +7 -7
  19. package/dist/_node-chunks/{chunk-TVKUJ3SE.js → chunk-DH7BCQMG.js} +8 -8
  20. package/dist/_node-chunks/{chunk-J3DQMIO4.js → chunk-FCNWWJV7.js} +7 -7
  21. package/dist/_node-chunks/{chunk-EIHJ5J3O.js → chunk-GBZZSL2K.js} +264 -109
  22. package/dist/_node-chunks/{chunk-F7YW5W6B.js → chunk-GCWAGPDV.js} +12 -12
  23. package/dist/_node-chunks/{chunk-K4YETNYJ.js → chunk-I7SRMFT5.js} +7 -7
  24. package/dist/_node-chunks/{chunk-TKN5TEZV.js → chunk-IEFSRAX2.js} +13 -13
  25. package/dist/_node-chunks/{chunk-AK5PHLUA.js → chunk-IGWCAXA2.js} +7 -7
  26. package/dist/_node-chunks/chunk-IYOHZPPC.js +18 -0
  27. package/dist/_node-chunks/{chunk-F3WE3456.js → chunk-KVOP6ASA.js} +7 -7
  28. package/dist/_node-chunks/{chunk-DZJNLBBL.js → chunk-MHVF6Y35.js} +7 -7
  29. package/dist/_node-chunks/{chunk-UTCFHTQH.js → chunk-MRCMZPA2.js} +7 -7
  30. package/dist/_node-chunks/chunk-RNHUADRS.js +62 -0
  31. package/dist/_node-chunks/{chunk-4KRR46V2.js → chunk-RP3VMQPF.js} +15 -15
  32. package/dist/_node-chunks/{chunk-P7YMEOXF.js → chunk-TFIGR2HH.js} +7 -7
  33. package/dist/_node-chunks/{chunk-SW3VZAH7.js → chunk-TXDIOSHI.js} +9 -9
  34. package/dist/_node-chunks/{chunk-WCSHG2QT.js → chunk-U6MJQ7C6.js} +7 -7
  35. package/dist/_node-chunks/{chunk-ACUNHBEO.js → chunk-XXVKM2ZR.js} +26 -23
  36. package/dist/_node-chunks/{chunk-QHIU5I7C.js → chunk-YWU65VY4.js} +6 -6
  37. package/dist/_node-chunks/{chunk-P3TWEOO5.js → chunk-Z3PLI7S2.js} +7 -7
  38. package/dist/_node-chunks/{chunk-2VMDKLSW.js → chunk-ZM2HT2RW.js} +6 -6
  39. package/dist/_node-chunks/{chunk-D7SDB4XE.js → chunk-ZPNXCXIT.js} +8 -8
  40. package/dist/_node-chunks/{dist-OGRBL76N.js → dist-PG4I7ZDU.js} +9 -9
  41. package/dist/_node-chunks/{globby-65LOULA6.js → globby-HXB6X43W.js} +17 -13
  42. package/dist/_node-chunks/{lib-TF7JCT3A.js → lib-4JJTZC7T.js} +7 -7
  43. package/dist/_node-chunks/{mdx-N42X6CFJ-6ZJEUZMZ.js → mdx-N42X6CFJ-3JBJ7PQF.js} +8 -8
  44. package/dist/_node-chunks/{p-limit-PF7JSPDT.js → p-limit-WBBNX4KI.js} +7 -7
  45. package/dist/_node-chunks/{plugin-A6XAWMXN.js → plugin-SEQ2OPRK.js} +10 -10
  46. package/dist/_node-chunks/{plugin-LGHGAC6J.js → plugin-SG6I7RFC.js} +10 -10
  47. package/dist/_node-chunks/{webpack-inject-mocker-runtime-plugin-HDSEOU3Z.js → webpack-inject-mocker-runtime-plugin-5O25VYCQ.js} +10 -10
  48. package/dist/_node-chunks/{webpack-mock-plugin-ZJJVMJUS.js → webpack-mock-plugin-35I32SAF.js} +9 -9
  49. package/dist/babel/index.js +11 -11
  50. package/dist/bin/core.js +11 -11
  51. package/dist/bin/dispatcher.js +11 -11
  52. package/dist/bin/loader.js +8 -8
  53. package/dist/cli/index.js +27 -22
  54. package/dist/common/index.js +21 -21
  55. package/dist/components/index.js +8 -4
  56. package/dist/core-events/index.d.ts +18 -2
  57. package/dist/core-events/index.js +7 -1
  58. package/dist/core-server/index.js +1157 -1024
  59. package/dist/core-server/presets/common-manager.js +84 -39
  60. package/dist/core-server/presets/common-override-preset.js +9 -9
  61. package/dist/core-server/presets/common-preset.js +691 -29
  62. package/dist/core-server/presets/webpack/loaders/storybook-mock-transform-loader.js +9 -9
  63. package/dist/core-server/presets/webpack/loaders/webpack-automock-loader.js +10 -10
  64. package/dist/csf/index.d.ts +9 -4
  65. package/dist/csf/index.js +37 -8
  66. package/dist/csf-tools/index.d.ts +13 -6
  67. package/dist/csf-tools/index.js +9 -9
  68. package/dist/manager/globals-runtime.js +1318 -1001
  69. package/dist/manager/globals.d.ts +0 -4
  70. package/dist/manager/globals.js +1 -6
  71. package/dist/manager/runtime.js +2198 -721
  72. package/dist/manager-api/index.d.ts +12 -5
  73. package/dist/manager-api/index.js +347 -76
  74. package/dist/node-logger/index.js +14 -14
  75. package/dist/preview/runtime.js +103 -63
  76. package/dist/preview-api/index.d.ts +70 -71
  77. package/dist/preview-api/index.js +1 -1
  78. package/dist/server-errors.js +10 -10
  79. package/dist/telemetry/index.d.ts +1 -1
  80. package/dist/telemetry/index.js +24 -24
  81. package/dist/types/index.d.ts +28 -7
  82. package/dist/viewport/index.d.ts +36 -4
  83. package/dist/viewport/index.js +1 -1
  84. package/package.json +5 -4
  85. package/dist/_node-chunks/camelcase-K3BM7RII.js +0 -18
  86. package/dist/_node-chunks/chunk-7LG5CLCT.js +0 -18
  87. package/dist/_node-chunks/chunk-DWJ7TV2O.js +0 -62
  88. package/dist/_node-chunks/default-browser-id-4RZZMHJE.js +0 -1719
@@ -32,7 +32,7 @@ declare const monorepoConfigs: {
32
32
  };
33
33
  type MonorepoType = keyof typeof monorepoConfigs | 'Workspaces' | undefined;
34
34
 
35
- type EventType = 'boot' | 'dev' | 'build' | 'index' | 'upgrade' | 'multi-upgrade' | 'init' | 'init-step' | 'scaffolded-empty' | 'browser' | 'canceled' | 'error' | 'error-metadata' | 'version-update' | 'core-config' | 'remove' | 'save-story' | 'create-new-story-file' | 'create-new-story-file-search' | 'testing-module-watch-mode' | 'testing-module-completed-report' | 'testing-module-crash-report' | 'addon-test' | 'test-run' | 'addon-onboarding' | 'onboarding-survey' | 'mocking';
35
+ type EventType = 'boot' | 'dev' | 'build' | 'index' | 'upgrade' | 'multi-upgrade' | 'init' | 'init-step' | 'scaffolded-empty' | 'browser' | 'canceled' | 'error' | 'error-metadata' | 'version-update' | 'core-config' | 'remove' | 'save-story' | 'create-new-story-file' | 'create-new-story-file-search' | 'open-in-editor' | 'testing-module-watch-mode' | 'testing-module-completed-report' | 'testing-module-crash-report' | 'addon-test' | 'test-run' | 'addon-onboarding' | 'onboarding-survey' | 'mocking';
36
36
  interface Dependency {
37
37
  version: string | undefined;
38
38
  versionSpecifier?: string;
@@ -1,10 +1,10 @@
1
- import CJS_COMPAT_NODE_URL_0oz6lpav6bgq from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_0oz6lpav6bgq from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_0oz6lpav6bgq from "node:module";
1
+ import CJS_COMPAT_NODE_URL_srln17sp2zh from 'node:url';
2
+ import CJS_COMPAT_NODE_PATH_srln17sp2zh from 'node:path';
3
+ import CJS_COMPAT_NODE_MODULE_srln17sp2zh from "node:module";
4
4
 
5
- var __filename = CJS_COMPAT_NODE_URL_0oz6lpav6bgq.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_0oz6lpav6bgq.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_0oz6lpav6bgq.createRequire(import.meta.url);
5
+ var __filename = CJS_COMPAT_NODE_URL_srln17sp2zh.fileURLToPath(import.meta.url);
6
+ var __dirname = CJS_COMPAT_NODE_PATH_srln17sp2zh.dirname(__filename);
7
+ var require = CJS_COMPAT_NODE_MODULE_srln17sp2zh.createRequire(import.meta.url);
8
8
 
9
9
  // ------------------------------------------------------------
10
10
  // end of CJS compatibility banner, injected by Storybook's esbuild configuration
@@ -22,24 +22,24 @@ import {
22
22
  sanitizeAddonName,
23
23
  sanitizeError,
24
24
  telemetry
25
- } from "../_node-chunks/chunk-4KRR46V2.js";
26
- import "../_node-chunks/chunk-7LG5CLCT.js";
27
- import "../_node-chunks/chunk-ACUNHBEO.js";
28
- import "../_node-chunks/chunk-OC3TVLYU.js";
29
- import "../_node-chunks/chunk-WCSHG2QT.js";
30
- import "../_node-chunks/chunk-DWJ7TV2O.js";
31
- import "../_node-chunks/chunk-D7SDB4XE.js";
32
- import "../_node-chunks/chunk-TBWOUVTA.js";
33
- import "../_node-chunks/chunk-DZJNLBBL.js";
34
- import "../_node-chunks/chunk-VWSUFVUF.js";
35
- import "../_node-chunks/chunk-KU3JBNPY.js";
36
- import "../_node-chunks/chunk-4VDRH7SM.js";
37
- import "../_node-chunks/chunk-VX5P3IYA.js";
38
- import "../_node-chunks/chunk-UTCFHTQH.js";
39
- import "../_node-chunks/chunk-J3DQMIO4.js";
40
- import "../_node-chunks/chunk-P7YMEOXF.js";
41
- import "../_node-chunks/chunk-P3TWEOO5.js";
42
- import "../_node-chunks/chunk-2VMDKLSW.js";
25
+ } from "../_node-chunks/chunk-RP3VMQPF.js";
26
+ import "../_node-chunks/chunk-IYOHZPPC.js";
27
+ import "../_node-chunks/chunk-XXVKM2ZR.js";
28
+ import "../_node-chunks/chunk-46BWYN3K.js";
29
+ import "../_node-chunks/chunk-U6MJQ7C6.js";
30
+ import "../_node-chunks/chunk-RNHUADRS.js";
31
+ import "../_node-chunks/chunk-ZPNXCXIT.js";
32
+ import "../_node-chunks/chunk-5YUTWYNI.js";
33
+ import "../_node-chunks/chunk-MHVF6Y35.js";
34
+ import "../_node-chunks/chunk-3XXQRL3A.js";
35
+ import "../_node-chunks/chunk-BC23FKU4.js";
36
+ import "../_node-chunks/chunk-A2DKPKBY.js";
37
+ import "../_node-chunks/chunk-4DIDWIST.js";
38
+ import "../_node-chunks/chunk-MRCMZPA2.js";
39
+ import "../_node-chunks/chunk-FCNWWJV7.js";
40
+ import "../_node-chunks/chunk-TFIGR2HH.js";
41
+ import "../_node-chunks/chunk-Z3PLI7S2.js";
42
+ import "../_node-chunks/chunk-ZM2HT2RW.js";
43
43
  export {
44
44
  addToGlobalContext,
45
45
  cleanPaths,
@@ -1,5 +1,5 @@
1
1
  import { StoryId as StoryId$1, StoryName, ComponentTitle, Tag as Tag$1, Parameters, Args, ArgTypes, ComponentId, StoryKind, Globals as Globals$1, GlobalTypes as GlobalTypes$1, InputType, Renderer, StoryContext, PartialStoryFn, LegacyStoryFn, ArgsStoryFn, StoryFn, DecoratorFunction, LoaderFunction as LoaderFunction$1, ViewMode as ViewMode$1, StoryIdentifier, ProjectAnnotations as ProjectAnnotations$1, StrictArgTypes, StrictGlobalTypes, StepRunner, BeforeAll, ComponentAnnotations, StoryAnnotations, StoryContextForEnhancers, CleanupCallback, Canvas, StoryAnnotationsOrFn, AnnotatedStoryFn } from 'storybook/internal/csf';
2
- export { AfterEach, AnnotatedStoryFn, ArgTypes, ArgTypesEnhancer, Args, ArgsEnhancer, ArgsFromMeta, ArgsStoryFn, BaseAnnotations, ProjectAnnotations as BaseProjectAnnotations, BeforeAll, BeforeEach, Canvas, CleanupCallback, ComponentAnnotations, ComponentId, ComponentTitle, Conditional, DecoratorApplicator, DecoratorFunction, GlobalTypes, Globals, IncludeExcludeOptions, InputType, LegacyAnnotatedStoryFn, LegacyStoryAnnotationsOrFn, LegacyStoryFn, LoaderFunction, Parameters, PartialStoryFn, PlayFunction, PlayFunctionContext, Renderer, SBArrayType, SBEnumType, SBIntersectionType, SBObjectType, SBOtherType, SBScalarType, SBType, SBUnionType, SeparatorOptions, StepFunction, StepLabel, StepRunner, StoryAnnotations, StoryAnnotationsOrFn, StoryContext, StoryContextForEnhancers, StoryContextForLoaders, StoryContextUpdate, StoryFn, StoryId, StoryIdentifier, StoryKind, StoryName, StrictArgTypes, StrictArgs, StrictGlobalTypes, StrictInputType, Tag } from 'storybook/internal/csf';
2
+ export { AfterEach, AnnotatedStoryFn, ArgTypes, ArgTypesEnhancer, Args, ArgsEnhancer, ArgsFromMeta, ArgsStoryFn, BaseAnnotations, ProjectAnnotations as BaseProjectAnnotations, BeforeAll, BeforeEach, Canvas, CleanupCallback, ComponentAnnotations, ComponentId, ComponentTitle, Conditional, DecoratorApplicator, DecoratorFunction, GlobalTypes, Globals, IncludeExcludeOptions, InputType, LegacyAnnotatedStoryFn, LegacyStoryAnnotationsOrFn, LegacyStoryFn, LoaderFunction, Parameters, PartialStoryFn, PlayFunction, PlayFunctionContext, Renderer, SBArrayType, SBEnumType, SBIntersectionType, SBObjectType, SBOtherType, SBScalarType, SBType, SBUnionType, SeparatorOptions, StepFunction, StepLabel, StepRunner, StoryAnnotations, StoryAnnotationsOrFn, StoryContext, StoryContextForEnhancers, StoryContextForLoaders, StoryContextUpdate, StoryFn, StoryId, StoryIdentifier, StoryKind, StoryName, StrictArgTypes, StrictArgs, StrictGlobalTypes, StrictInputType, Tag, TestFunction } from 'storybook/internal/csf';
3
3
  import { ReactElement, FC, ReactNode, PropsWithChildren } from 'react';
4
4
  import { RouterData as RouterData$1 } from 'storybook/internal/router';
5
5
  import { Globals, GlobalTypes, API_Layout as API_Layout$1, API_LayoutCustomisations as API_LayoutCustomisations$1, API_UI as API_UI$1, API_Notification as API_Notification$1, API_Refs as API_Refs$1, API_Settings as API_Settings$1, API_LoadedRefData as API_LoadedRefData$1, StoryId, API_PreparedStoryIndex as API_PreparedStoryIndex$1, API_ViewMode as API_ViewMode$1, API_FilterFunction as API_FilterFunction$1, API_Versions as API_Versions$2, API_UnknownEntries as API_UnknownEntries$1, API_OptionsData as API_OptionsData$1, NormalizedProjectAnnotations as NormalizedProjectAnnotations$1, ProjectAnnotations as ProjectAnnotations$2, ComposedStoryFn as ComposedStoryFn$1 } from 'storybook/internal/types';
@@ -679,6 +679,8 @@ interface API_Shortcuts {
679
679
  collapseAll: API_KeyCollection;
680
680
  expandAll: API_KeyCollection;
681
681
  remount: API_KeyCollection;
682
+ openInEditor: API_KeyCollection;
683
+ copyStoryLink: API_KeyCollection;
682
684
  }
683
685
 
684
686
  interface SubState$3 extends API_LoadedRefData$1 {
@@ -2062,6 +2064,9 @@ interface BaseIndexEntry {
2062
2064
  }
2063
2065
  type StoryIndexEntry = BaseIndexEntry & {
2064
2066
  type: 'story';
2067
+ subtype: 'story' | 'test';
2068
+ parent?: StoryId$1;
2069
+ parentName?: StoryName;
2065
2070
  };
2066
2071
  type DocsIndexEntry = BaseIndexEntry & {
2067
2072
  storiesImports: Path[];
@@ -2071,6 +2076,7 @@ type IndexEntry = StoryIndexEntry | DocsIndexEntry;
2071
2076
  interface IndexInputStats {
2072
2077
  loaders?: boolean;
2073
2078
  play?: boolean;
2079
+ tests?: boolean;
2074
2080
  render?: boolean;
2075
2081
  storyFn?: boolean;
2076
2082
  mount?: boolean;
@@ -2114,6 +2120,9 @@ type BaseIndexInput = {
2114
2120
  /** The input for indexing a story entry. */
2115
2121
  type StoryIndexInput = BaseIndexInput & {
2116
2122
  type: 'story';
2123
+ subtype: 'story' | 'test';
2124
+ parent?: StoryId$1;
2125
+ parentName?: StoryName;
2117
2126
  };
2118
2127
  /** The input for indexing a docs entry. */
2119
2128
  type DocsIndexInput = BaseIndexInput & {
@@ -2122,7 +2131,7 @@ type DocsIndexInput = BaseIndexInput & {
2122
2131
  storiesImports?: Path[];
2123
2132
  };
2124
2133
  type IndexInput = StoryIndexInput | DocsIndexInput;
2125
- interface V3CompatIndexEntry extends Omit<StoryIndexEntry, 'type' | 'tags'> {
2134
+ interface V3CompatIndexEntry extends Omit<StoryIndexEntry, 'type' | 'tags' | 'subtype'> {
2126
2135
  kind: ComponentTitle;
2127
2136
  story: StoryName;
2128
2137
  parameters: Parameters;
@@ -2287,6 +2296,7 @@ interface BuilderOptions {
2287
2296
  versionCheck?: VersionCheck;
2288
2297
  disableWebpackDefaults?: boolean;
2289
2298
  serverChannelUrl?: string;
2299
+ networkAddress?: string;
2290
2300
  }
2291
2301
  interface StorybookConfigOptions {
2292
2302
  presets: Presets;
@@ -2391,6 +2401,8 @@ interface TestBuildConfig {
2391
2401
  }
2392
2402
  type Tag = string;
2393
2403
  interface TagOptions {
2404
+ /** Visually include or exclude stories with this tag in the sidebar by default */
2405
+ defaultFilterSelection?: 'include' | 'exclude';
2394
2406
  excludeFromSidebar: boolean;
2395
2407
  excludeFromDocsStories: boolean;
2396
2408
  }
@@ -2665,7 +2677,7 @@ interface API_BaseEntry {
2665
2677
  name: string;
2666
2678
  tags: Tag$1[];
2667
2679
  refId?: string;
2668
- renderLabel?: (item: API_BaseEntry, api: any) => any;
2680
+ renderLabel?: (item: API_HashEntry, api: any) => any;
2669
2681
  }
2670
2682
  interface API_RootEntry extends API_BaseEntry {
2671
2683
  type: 'root';
@@ -2681,6 +2693,7 @@ interface API_ComponentEntry extends API_BaseEntry {
2681
2693
  type: 'component';
2682
2694
  parent?: StoryId$1;
2683
2695
  children: StoryId$1[];
2696
+ importPath?: Path;
2684
2697
  }
2685
2698
  interface API_DocsEntry extends API_BaseEntry {
2686
2699
  type: 'docs';
@@ -2694,9 +2707,11 @@ interface API_DocsEntry extends API_BaseEntry {
2694
2707
  }
2695
2708
  interface API_StoryEntry extends API_BaseEntry {
2696
2709
  type: 'story';
2710
+ subtype: 'story';
2697
2711
  parent: StoryId$1;
2698
2712
  title: ComponentTitle;
2699
2713
  importPath: Path;
2714
+ exportName: string;
2700
2715
  prepared: boolean;
2701
2716
  parameters?: {
2702
2717
  [parameterName: string]: any;
@@ -2704,9 +2719,13 @@ interface API_StoryEntry extends API_BaseEntry {
2704
2719
  args?: Args;
2705
2720
  argTypes?: ArgTypes;
2706
2721
  initialArgs?: Args;
2722
+ children?: StoryId$1[];
2723
+ }
2724
+ interface API_TestEntry extends Omit<API_StoryEntry, 'subtype' | 'children'> {
2725
+ subtype: 'test';
2707
2726
  }
2708
- type API_LeafEntry = API_DocsEntry | API_StoryEntry;
2709
- type API_HashEntry = API_RootEntry | API_GroupEntry | API_ComponentEntry | API_DocsEntry | API_StoryEntry;
2727
+ type API_LeafEntry = API_DocsEntry | API_StoryEntry | API_TestEntry;
2728
+ type API_HashEntry = API_RootEntry | API_GroupEntry | API_ComponentEntry | API_DocsEntry | API_StoryEntry | API_TestEntry;
2710
2729
  /**
2711
2730
  * The `IndexHash` is our manager-side representation of the `StoryIndex`. We create entries in the
2712
2731
  * hash not only for each story or docs entry, but also for each "group" of the component (split on
@@ -2876,6 +2895,7 @@ interface API_Layout {
2876
2895
  showToolbar: boolean;
2877
2896
  }
2878
2897
  interface API_LayoutCustomisations {
2898
+ showPanel?: (state: State, defaultValue: boolean) => boolean | undefined;
2879
2899
  showSidebar?: (state: State, defaultValue: boolean) => boolean | undefined;
2880
2900
  showToolbar?: (state: State, defaultValue: boolean) => boolean | undefined;
2881
2901
  }
@@ -3293,7 +3313,8 @@ interface Addon_ToolbarConfig {
3293
3313
  }
3294
3314
  interface Addon_Config {
3295
3315
  theme?: ThemeVars;
3296
- layout?: {
3316
+ layoutCustomisations?: {
3317
+ showPanel?: API_LayoutCustomisations['showPanel'];
3297
3318
  showSidebar?: API_LayoutCustomisations['showSidebar'];
3298
3319
  showToolbar?: API_LayoutCustomisations['showToolbar'];
3299
3320
  };
@@ -3589,4 +3610,4 @@ type SupportedFrameworks = 'angular' | 'ember' | 'html-vite' | 'nextjs' | 'nextj
3589
3610
 
3590
3611
  type SupportedRenderers = 'react' | 'react-native' | 'vue3' | 'angular' | 'ember' | 'preact' | 'svelte' | 'qwik' | 'html' | 'web-components' | 'server' | 'solid' | 'nuxt';
3591
3612
 
3592
- export { type API_ActiveTabsType, type API_BaseEntry, type API_ComponentEntry, type API_ComposedRef, type API_ComposedRefUpdate, type API_DocsEntry, type API_FilterFunction, type API_GroupEntry, type API_HashEntry, type API_IframeRenderer, type API_IndexHash, type API_Layout, type API_LayoutCustomisations, type API_LeafEntry, type API_LoadedRefData, type API_MatchOptions, type API_Notification, type API_OptionsData, type API_PanelPositions, type API_PreparedIndexEntry, type API_PreparedStoryIndex, type API_Provider, type API_ProviderData, type API_RefId, type API_RefUrl, type API_Refs, type API_ReleaseNotes, type API_RenderOptions, type API_RootEntry, type API_RouteOptions, type API_SetRefData, type API_Settings, type API_SidebarOptions, type API_StateMerger, type API_StoryEntry, type API_StoryMapper, type API_UI, type API_UIOptions, type API_UnknownEntries, type API_Version, type API_Versions$1 as API_Versions, type API_ViewMode, type Actor, type Addon_AddStoryArgs, type Addon_Annotations, type Addon_ArgType, type Addon_ArgsStoryFn, type Addon_BaseAnnotations, type Addon_BaseDecorators, type Addon_BaseMeta, type Addon_BaseStoryFn, type Addon_BaseStoryObject, type Addon_BaseType, type Addon_ClientApiAddon, type Addon_ClientApiAddons, type Addon_ClientApiReturnFn, type Addon_ClientStoryApi, type Addon_Collection, type Addon_Comparator, type Addon_Config, type Addon_DecoratorFunction, type Addon_Elements, type Addon_LegacyStoryFn, type Addon_LoadFn, type Addon_Loadable, type Addon_Loader, type Addon_LoaderFunction, type Addon_Loaders, type Addon_MakeDecoratorResult, type Addon_OptionsParameter, type Addon_OptionsParameterV7, type Addon_PageType, type Addon_PartialStoryFn, type Addon_RenderOptions, type Addon_RequireContext, type Addon_StoryApi, type Addon_StoryContext, type Addon_StoryContextUpdate, type Addon_StoryFn, type Addon_StorySortComparator, type Addon_StorySortComparatorV7, type Addon_StorySortMethod, type Addon_StorySortObjectParameter, type Addon_StorySortParameter, type Addon_StorySortParameterV7, type Addon_StoryWrapper, type Addon_TestProviderType, type Addon_ToolbarConfig, type Addon_Type, type Addon_Types, Addon_TypesEnum, type Addon_TypesMapping, type Addon_WrapperSettings, type Addon_WrapperType, type Addons_ArgTypes, type BaseIndexEntry, type BaseIndexInput, type BaseStory, type BoundStory, type Builder, type BuilderName, type BuilderOptions, type BuilderResult, type BuilderStats, type Builder_EnvsRaw, type Builder_Unpromise, type Builder_WithRequiredProperty, type CLIBaseOptions, type CLIOptions, type CSFFile, type CompatibleString, type ComposeStoryFn, type ComposedStoryFn, type CoreCommon_AddonEntry, type CoreCommon_AddonInfo, type CoreCommon_OptionsEntry, type CoreCommon_ResolvedAddonPreset, type CoreCommon_ResolvedAddonVirtual, type CoreCommon_StorybookInfo, type CoreConfig, type DocsContextProps, type DocsIndexEntry, type DocsIndexInput, type DocsOptions, type DocsPreparedPayload, type DocsRenderFunction, type Entry, type Event, type EventInfo, type GlobalsUpdatedPayload, type IndexEntry, type IndexEntryLegacy, type IndexInput, type IndexInputStats, type IndexedCSFFile, type IndexedStory, type Indexer, type IndexerOptions, type LoadOptions, type LoadedPreset, type Middleware, MockUniversalStore, type ModuleExport, type ModuleExports, type ModuleImportFn, type NamedOrDefaultProjectAnnotations, type NormalizedComponentAnnotations, type NormalizedProjectAnnotations, type NormalizedStoriesSpecifier, type NormalizedStoryAnnotations, type Options, type PackageJson, type PartialArgsStoryFn, type Path, type PreparedMeta, type PreparedStory, type Preset, type PresetConfig, type PresetProperty, type PresetPropertyFn, type PresetValue, type Presets, type PreviewAnnotation, type ProjectAnnotations, type Ref, type RenderContext, type RenderContextCallbacks, type RenderToCanvas, type RendererName, type ResolvedModuleExport, type ResolvedModuleExportFromType, type ResolvedModuleExportType, type SetGlobalsPayload, type SetStoriesPayload, type SetStoriesStory, type SetStoriesStoryData, type Stats, type Status, type StatusByTypeId, type StatusStore, type StatusStoreByTypeId, type StatusTypeId, type StatusValue, type StatusesByStoryIdAndTypeId, type StoreOptions, type Store_CSFExports, type StoriesEntry, type StoriesSpecifier, type StoriesWithPartialProps, type StoryIndex, type StoryIndexEntry, type StoryIndexInput, type StoryIndexV2, type StoryIndexV3, type StoryPreparedPayload, type StoryRenderOptions, type StorybookConfig, type StorybookConfigOptions, type StorybookConfigRaw, type StorybookInternalParameters, type StorybookParameters, type StorybookTypes, type SupportedFrameworks, type SupportedRenderers, type TagOptions, type TagsOptions, type TeardownRenderToCanvas, type TestBuildConfig, type TestBuildFlags, type TestProviderId, type TestProviderState, type TestProviderStateByProviderId, type TestProviderStoreById, type TypescriptOptions, UniversalStore, type UseStatusStore, type UseTestProviderStore, type V3CompatIndexEntry, type VersionCheck, type ViewMode, type WebRenderer };
3613
+ export { type API_ActiveTabsType, type API_BaseEntry, type API_ComponentEntry, type API_ComposedRef, type API_ComposedRefUpdate, type API_DocsEntry, type API_FilterFunction, type API_GroupEntry, type API_HashEntry, type API_IframeRenderer, type API_IndexHash, type API_Layout, type API_LayoutCustomisations, type API_LeafEntry, type API_LoadedRefData, type API_MatchOptions, type API_Notification, type API_OptionsData, type API_PanelPositions, type API_PreparedIndexEntry, type API_PreparedStoryIndex, type API_Provider, type API_ProviderData, type API_RefId, type API_RefUrl, type API_Refs, type API_ReleaseNotes, type API_RenderOptions, type API_RootEntry, type API_RouteOptions, type API_SetRefData, type API_Settings, type API_SidebarOptions, type API_StateMerger, type API_StoryEntry, type API_StoryMapper, type API_TestEntry, type API_UI, type API_UIOptions, type API_UnknownEntries, type API_Version, type API_Versions$1 as API_Versions, type API_ViewMode, type Actor, type Addon_AddStoryArgs, type Addon_Annotations, type Addon_ArgType, type Addon_ArgsStoryFn, type Addon_BaseAnnotations, type Addon_BaseDecorators, type Addon_BaseMeta, type Addon_BaseStoryFn, type Addon_BaseStoryObject, type Addon_BaseType, type Addon_ClientApiAddon, type Addon_ClientApiAddons, type Addon_ClientApiReturnFn, type Addon_ClientStoryApi, type Addon_Collection, type Addon_Comparator, type Addon_Config, type Addon_DecoratorFunction, type Addon_Elements, type Addon_LegacyStoryFn, type Addon_LoadFn, type Addon_Loadable, type Addon_Loader, type Addon_LoaderFunction, type Addon_Loaders, type Addon_MakeDecoratorResult, type Addon_OptionsParameter, type Addon_OptionsParameterV7, type Addon_PageType, type Addon_PartialStoryFn, type Addon_RenderOptions, type Addon_RequireContext, type Addon_StoryApi, type Addon_StoryContext, type Addon_StoryContextUpdate, type Addon_StoryFn, type Addon_StorySortComparator, type Addon_StorySortComparatorV7, type Addon_StorySortMethod, type Addon_StorySortObjectParameter, type Addon_StorySortParameter, type Addon_StorySortParameterV7, type Addon_StoryWrapper, type Addon_TestProviderType, type Addon_ToolbarConfig, type Addon_Type, type Addon_Types, Addon_TypesEnum, type Addon_TypesMapping, type Addon_WrapperSettings, type Addon_WrapperType, type Addons_ArgTypes, type BaseIndexEntry, type BaseIndexInput, type BaseStory, type BoundStory, type Builder, type BuilderName, type BuilderOptions, type BuilderResult, type BuilderStats, type Builder_EnvsRaw, type Builder_Unpromise, type Builder_WithRequiredProperty, type CLIBaseOptions, type CLIOptions, type CSFFile, type CompatibleString, type ComposeStoryFn, type ComposedStoryFn, type CoreCommon_AddonEntry, type CoreCommon_AddonInfo, type CoreCommon_OptionsEntry, type CoreCommon_ResolvedAddonPreset, type CoreCommon_ResolvedAddonVirtual, type CoreCommon_StorybookInfo, type CoreConfig, type DocsContextProps, type DocsIndexEntry, type DocsIndexInput, type DocsOptions, type DocsPreparedPayload, type DocsRenderFunction, type Entry, type Event, type EventInfo, type GlobalsUpdatedPayload, type IndexEntry, type IndexEntryLegacy, type IndexInput, type IndexInputStats, type IndexedCSFFile, type IndexedStory, type Indexer, type IndexerOptions, type LoadOptions, type LoadedPreset, type Middleware, MockUniversalStore, type ModuleExport, type ModuleExports, type ModuleImportFn, type NamedOrDefaultProjectAnnotations, type NormalizedComponentAnnotations, type NormalizedProjectAnnotations, type NormalizedStoriesSpecifier, type NormalizedStoryAnnotations, type Options, type PackageJson, type PartialArgsStoryFn, type Path, type PreparedMeta, type PreparedStory, type Preset, type PresetConfig, type PresetProperty, type PresetPropertyFn, type PresetValue, type Presets, type PreviewAnnotation, type ProjectAnnotations, type Ref, type RenderContext, type RenderContextCallbacks, type RenderToCanvas, type RendererName, type ResolvedModuleExport, type ResolvedModuleExportFromType, type ResolvedModuleExportType, type SetGlobalsPayload, type SetStoriesPayload, type SetStoriesStory, type SetStoriesStoryData, type Stats, type Status, type StatusByTypeId, type StatusStore, type StatusStoreByTypeId, type StatusTypeId, type StatusValue, type StatusesByStoryIdAndTypeId, type StoreOptions, type Store_CSFExports, type StoriesEntry, type StoriesSpecifier, type StoriesWithPartialProps, type StoryIndex, type StoryIndexEntry, type StoryIndexInput, type StoryIndexV2, type StoryIndexV3, type StoryPreparedPayload, type StoryRenderOptions, type StorybookConfig, type StorybookConfigOptions, type StorybookConfigRaw, type StorybookInternalParameters, type StorybookParameters, type StorybookTypes, type SupportedFrameworks, type SupportedRenderers, type TagOptions, type TagsOptions, type TeardownRenderToCanvas, type TestBuildConfig, type TestBuildFlags, type TestProviderId, type TestProviderState, type TestProviderStateByProviderId, type TestProviderStoreById, type TypescriptOptions, UniversalStore, type UseStatusStore, type UseTestProviderStore, type V3CompatIndexEntry, type VersionCheck, type ViewMode, type WebRenderer };
@@ -60,7 +60,7 @@ interface ViewportTypes {
60
60
  globals: ViewportGlobals;
61
61
  }
62
62
 
63
- declare const INITIAL_VIEWPORTS_DATA: {
63
+ declare const INITIAL_VIEWPORTS: {
64
64
  readonly iphone5: {
65
65
  readonly name: "iPhone 5";
66
66
  readonly styles: {
@@ -286,10 +286,42 @@ declare const INITIAL_VIEWPORTS_DATA: {
286
286
  readonly type: "mobile";
287
287
  };
288
288
  };
289
- type InitialViewportKeys = keyof typeof INITIAL_VIEWPORTS_DATA;
290
- declare const INITIAL_VIEWPORTS: ViewportMap;
289
+ type InitialViewportKeys = keyof typeof INITIAL_VIEWPORTS;
291
290
  declare const DEFAULT_VIEWPORT = "responsive";
292
- declare const MINIMAL_VIEWPORTS: ViewportMap;
291
+ declare const MINIMAL_VIEWPORTS: {
292
+ readonly mobile1: {
293
+ readonly name: "Small mobile";
294
+ readonly styles: {
295
+ readonly height: "568px";
296
+ readonly width: "320px";
297
+ };
298
+ readonly type: "mobile";
299
+ };
300
+ readonly mobile2: {
301
+ readonly name: "Large mobile";
302
+ readonly styles: {
303
+ readonly height: "896px";
304
+ readonly width: "414px";
305
+ };
306
+ readonly type: "mobile";
307
+ };
308
+ readonly tablet: {
309
+ readonly name: "Tablet";
310
+ readonly styles: {
311
+ readonly height: "1112px";
312
+ readonly width: "834px";
313
+ };
314
+ readonly type: "tablet";
315
+ };
316
+ readonly desktop: {
317
+ readonly name: "Desktop";
318
+ readonly styles: {
319
+ readonly height: "1024px";
320
+ readonly width: "1280px";
321
+ };
322
+ readonly type: "desktop";
323
+ };
324
+ };
293
325
 
294
326
  declare const responsiveViewport: Viewport;
295
327
 
@@ -3,7 +3,7 @@ import {
3
3
  INITIAL_VIEWPORTS,
4
4
  MINIMAL_VIEWPORTS,
5
5
  responsiveViewport
6
- } from "../_browser-chunks/chunk-O5R5CGFA.js";
6
+ } from "../_browser-chunks/chunk-TMDZCWME.js";
7
7
  import {
8
8
  ADDON_ID,
9
9
  PANEL_ID,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "storybook",
3
- "version": "10.0.0-beta.5",
3
+ "version": "10.0.0-beta.7",
4
4
  "description": "Storybook: Develop, document, and test UI components in isolation",
5
5
  "keywords": [
6
6
  "storybook",
@@ -228,13 +228,12 @@
228
228
  },
229
229
  "dependencies": {
230
230
  "@storybook/global": "^5.0.0",
231
- "@storybook/icons": "^1.4.0",
231
+ "@storybook/icons": "^1.6.0",
232
232
  "@testing-library/jest-dom": "^6.6.3",
233
233
  "@testing-library/user-event": "^14.6.1",
234
234
  "@vitest/expect": "3.2.4",
235
235
  "@vitest/mocker": "3.2.4",
236
236
  "@vitest/spy": "3.2.4",
237
- "better-opn": "^3.0.2",
238
237
  "esbuild": "^0.18.0 || ^0.19.0 || ^0.20.0 || ^0.21.0 || ^0.22.0 || ^0.23.0 || ^0.24.0 || ^0.25.0",
239
238
  "recast": "^0.23.5",
240
239
  "semver": "^7.6.2",
@@ -318,13 +317,14 @@
318
317
  "jiti": "^2.4.2",
319
318
  "js-yaml": "^4.1.0",
320
319
  "jsdoc-type-pratt-parser": "^4.0.0",
320
+ "launch-editor": "^2.11.1",
321
321
  "lazy-universal-dotenv": "^4.0.0",
322
322
  "leven": "^4.0.0",
323
323
  "memfs": "^4.11.1",
324
324
  "memoizerific": "^1.11.3",
325
325
  "nanoid": "^4.0.2",
326
326
  "npmlog": "^7.0.0",
327
- "open": "^8.4.0",
327
+ "open": "^10.2.0",
328
328
  "p-limit": "^6.2.0",
329
329
  "package-manager-detector": "^1.1.0",
330
330
  "picocolors": "^1.1.0",
@@ -335,6 +335,7 @@
335
335
  "prettier": "^3.5.3",
336
336
  "pretty-hrtime": "^1.0.3",
337
337
  "prompts": "^2.4.0",
338
+ "qrcode.react": "^4.2.0",
338
339
  "react": "^18.2.0",
339
340
  "react-dom": "^18.2.0",
340
341
  "react-helmet-async": "^1.3.0",
@@ -1,18 +0,0 @@
1
- import CJS_COMPAT_NODE_URL_0oz6lpav6bgq from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_0oz6lpav6bgq from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_0oz6lpav6bgq from "node:module";
4
-
5
- var __filename = CJS_COMPAT_NODE_URL_0oz6lpav6bgq.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_0oz6lpav6bgq.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_0oz6lpav6bgq.createRequire(import.meta.url);
8
-
9
- // ------------------------------------------------------------
10
- // end of CJS compatibility banner, injected by Storybook's esbuild configuration
11
- // ------------------------------------------------------------
12
- import {
13
- camelCase
14
- } from "./chunk-AK5PHLUA.js";
15
- import "./chunk-2VMDKLSW.js";
16
- export {
17
- camelCase as default
18
- };
@@ -1,18 +0,0 @@
1
- import CJS_COMPAT_NODE_URL_0oz6lpav6bgq from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_0oz6lpav6bgq from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_0oz6lpav6bgq from "node:module";
4
-
5
- var __filename = CJS_COMPAT_NODE_URL_0oz6lpav6bgq.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_0oz6lpav6bgq.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_0oz6lpav6bgq.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.0.0-beta.5";
15
-
16
- export {
17
- version
18
- };
@@ -1,62 +0,0 @@
1
- import CJS_COMPAT_NODE_URL_0oz6lpav6bgq from 'node:url';
2
- import CJS_COMPAT_NODE_PATH_0oz6lpav6bgq from 'node:path';
3
- import CJS_COMPAT_NODE_MODULE_0oz6lpav6bgq from "node:module";
4
-
5
- var __filename = CJS_COMPAT_NODE_URL_0oz6lpav6bgq.fileURLToPath(import.meta.url);
6
- var __dirname = CJS_COMPAT_NODE_PATH_0oz6lpav6bgq.dirname(__filename);
7
- var require = CJS_COMPAT_NODE_MODULE_0oz6lpav6bgq.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.0.0-beta.5",
16
- "@storybook/addon-docs": "10.0.0-beta.5",
17
- "@storybook/addon-jest": "10.0.0-beta.5",
18
- "@storybook/addon-links": "10.0.0-beta.5",
19
- "@storybook/addon-onboarding": "10.0.0-beta.5",
20
- "storybook-addon-pseudo-states": "10.0.0-beta.5",
21
- "@storybook/addon-themes": "10.0.0-beta.5",
22
- "@storybook/addon-vitest": "10.0.0-beta.5",
23
- "@storybook/builder-vite": "10.0.0-beta.5",
24
- "@storybook/builder-webpack5": "10.0.0-beta.5",
25
- storybook: "10.0.0-beta.5",
26
- "@storybook/angular": "10.0.0-beta.5",
27
- "@storybook/ember": "10.0.0-beta.5",
28
- "@storybook/html-vite": "10.0.0-beta.5",
29
- "@storybook/nextjs": "10.0.0-beta.5",
30
- "@storybook/nextjs-vite": "10.0.0-beta.5",
31
- "@storybook/preact-vite": "10.0.0-beta.5",
32
- "@storybook/react-native-web-vite": "10.0.0-beta.5",
33
- "@storybook/react-vite": "10.0.0-beta.5",
34
- "@storybook/react-webpack5": "10.0.0-beta.5",
35
- "@storybook/server-webpack5": "10.0.0-beta.5",
36
- "@storybook/svelte-vite": "10.0.0-beta.5",
37
- "@storybook/sveltekit": "10.0.0-beta.5",
38
- "@storybook/vue3-vite": "10.0.0-beta.5",
39
- "@storybook/web-components-vite": "10.0.0-beta.5",
40
- sb: "10.0.0-beta.5",
41
- "@storybook/cli": "10.0.0-beta.5",
42
- "@storybook/codemod": "10.0.0-beta.5",
43
- "@storybook/core-webpack": "10.0.0-beta.5",
44
- "create-storybook": "10.0.0-beta.5",
45
- "@storybook/csf-plugin": "10.0.0-beta.5",
46
- "eslint-plugin-storybook": "10.0.0-beta.5",
47
- "@storybook/react-dom-shim": "10.0.0-beta.5",
48
- "@storybook/preset-create-react-app": "10.0.0-beta.5",
49
- "@storybook/preset-react-webpack": "10.0.0-beta.5",
50
- "@storybook/preset-server-webpack": "10.0.0-beta.5",
51
- "@storybook/html": "10.0.0-beta.5",
52
- "@storybook/preact": "10.0.0-beta.5",
53
- "@storybook/react": "10.0.0-beta.5",
54
- "@storybook/server": "10.0.0-beta.5",
55
- "@storybook/svelte": "10.0.0-beta.5",
56
- "@storybook/vue3": "10.0.0-beta.5",
57
- "@storybook/web-components": "10.0.0-beta.5"
58
- };
59
-
60
- export {
61
- versions_default
62
- };