storybook 9.0.0-alpha.3 → 9.0.0-alpha.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/actions/decorator.d.ts +6 -0
- package/dist/actions/decorator.js +139 -0
- package/dist/actions/index.cjs +127 -0
- package/dist/actions/index.d.ts +105 -0
- package/dist/actions/index.js +112 -0
- package/dist/actions/manager.js +1196 -0
- package/dist/actions/preview.cjs +165 -0
- package/dist/actions/preview.d.ts +55 -0
- package/dist/actions/preview.js +156 -0
- package/dist/bin/index.cjs +63 -64
- package/dist/bin/index.js +63 -64
- package/dist/channels/index.cjs +207 -230
- package/dist/channels/index.js +302 -304
- package/dist/cli/bin/index.cjs +405 -405
- package/dist/cli/bin/index.js +410 -410
- package/dist/client-logger/index.cjs +56 -88
- package/dist/client-logger/index.js +41 -47
- package/dist/common/index.cjs +65 -67
- package/dist/common/index.d.ts +1 -4
- package/dist/common/index.js +65 -67
- package/dist/components/index.cjs +9413 -11578
- package/dist/components/index.d.ts +92 -92
- package/dist/components/index.js +6768 -7544
- package/dist/core-events/index.d.ts +138 -25
- package/dist/core-server/index.cjs +5241 -5265
- package/dist/core-server/index.js +5353 -5375
- package/dist/core-server/presets/common-manager.js +11 -19
- package/dist/core-server/presets/common-preset.cjs +243 -242
- package/dist/core-server/presets/common-preset.js +379 -378
- package/dist/csf/index.cjs +76 -120
- package/dist/csf/index.d.ts +1 -3
- package/dist/csf/index.js +69 -113
- package/dist/docs-tools/index.cjs +1 -1
- package/dist/docs-tools/index.d.ts +2 -2
- package/dist/docs-tools/index.js +1 -1
- package/dist/instrumenter/index.cjs +1260 -1289
- package/dist/instrumenter/index.js +1344 -1348
- package/dist/manager/globals-module-info.cjs +272 -135
- package/dist/manager/globals-module-info.d.ts +1 -1
- package/dist/manager/globals-module-info.js +257 -120
- package/dist/manager/globals-runtime.js +59553 -22371
- package/dist/manager/globals.cjs +23 -19
- package/dist/manager/globals.d.ts +8 -5
- package/dist/manager/globals.js +10 -6
- package/dist/manager/runtime.js +129 -129
- package/dist/manager-api/index.cjs +1182 -1205
- package/dist/manager-api/index.d.ts +2 -2
- package/dist/manager-api/index.js +1010 -1008
- package/dist/preview/globals.cjs +21 -17
- package/dist/preview/globals.d.ts +4 -1
- package/dist/preview/globals.js +6 -2
- package/dist/preview/runtime.js +43946 -6546
- package/dist/preview-api/index.cjs +1243 -1239
- package/dist/preview-api/index.d.ts +104 -60
- package/dist/preview-api/index.js +1310 -1270
- package/dist/router/index.cjs +847 -871
- package/dist/router/index.js +193 -199
- package/dist/test/index.cjs +10068 -10205
- package/dist/test/index.d.ts +4 -4
- package/dist/test/index.js +9741 -9623
- package/dist/test/preview.cjs +15870 -0
- package/dist/test/preview.d.ts +54 -0
- package/dist/test/preview.js +14441 -0
- package/dist/test/spy.cjs +258 -0
- package/dist/test/spy.d.ts +66 -0
- package/dist/test/spy.js +240 -0
- package/dist/theming/create.cjs +79 -2269
- package/dist/theming/create.js +67 -841
- package/dist/theming/index.cjs +1065 -3232
- package/dist/theming/index.js +951 -1719
- package/dist/types/index.d.ts +242 -242
- package/package.json +134 -3
|
@@ -6,7 +6,7 @@ const __dirname = ESM_COMPAT_dirname(__filename);
|
|
|
6
6
|
const require = ESM_COMPAT_Module.createRequire(import.meta.url);
|
|
7
7
|
|
|
8
8
|
// src/manager/globals/exports.ts
|
|
9
|
-
var
|
|
9
|
+
var t = {
|
|
10
10
|
react: [
|
|
11
11
|
"Children",
|
|
12
12
|
"Component",
|
|
@@ -306,6 +306,164 @@ var r = {
|
|
|
306
306
|
"ZoomResetIcon",
|
|
307
307
|
"iconList"
|
|
308
308
|
],
|
|
309
|
+
"storybook/manager-api": [
|
|
310
|
+
"ActiveTabs",
|
|
311
|
+
"Consumer",
|
|
312
|
+
"ManagerContext",
|
|
313
|
+
"Provider",
|
|
314
|
+
"RequestResponseError",
|
|
315
|
+
"addons",
|
|
316
|
+
"combineParameters",
|
|
317
|
+
"controlOrMetaKey",
|
|
318
|
+
"controlOrMetaSymbol",
|
|
319
|
+
"eventMatchesShortcut",
|
|
320
|
+
"eventToShortcut",
|
|
321
|
+
"experimental_MockUniversalStore",
|
|
322
|
+
"experimental_UniversalStore",
|
|
323
|
+
"experimental_requestResponse",
|
|
324
|
+
"experimental_useUniversalStore",
|
|
325
|
+
"isMacLike",
|
|
326
|
+
"isShortcutTaken",
|
|
327
|
+
"keyToSymbol",
|
|
328
|
+
"merge",
|
|
329
|
+
"mockChannel",
|
|
330
|
+
"optionOrAltSymbol",
|
|
331
|
+
"shortcutMatchesShortcut",
|
|
332
|
+
"shortcutToHumanString",
|
|
333
|
+
"types",
|
|
334
|
+
"useAddonState",
|
|
335
|
+
"useArgTypes",
|
|
336
|
+
"useArgs",
|
|
337
|
+
"useChannel",
|
|
338
|
+
"useGlobalTypes",
|
|
339
|
+
"useGlobals",
|
|
340
|
+
"useParameter",
|
|
341
|
+
"useSharedState",
|
|
342
|
+
"useStoryPrepared",
|
|
343
|
+
"useStorybookApi",
|
|
344
|
+
"useStorybookState"
|
|
345
|
+
],
|
|
346
|
+
"storybook/theming": [
|
|
347
|
+
"CacheProvider",
|
|
348
|
+
"ClassNames",
|
|
349
|
+
"Global",
|
|
350
|
+
"ThemeProvider",
|
|
351
|
+
"background",
|
|
352
|
+
"color",
|
|
353
|
+
"convert",
|
|
354
|
+
"create",
|
|
355
|
+
"createCache",
|
|
356
|
+
"createGlobal",
|
|
357
|
+
"createReset",
|
|
358
|
+
"css",
|
|
359
|
+
"darken",
|
|
360
|
+
"ensure",
|
|
361
|
+
"ignoreSsrWarning",
|
|
362
|
+
"isPropValid",
|
|
363
|
+
"jsx",
|
|
364
|
+
"keyframes",
|
|
365
|
+
"lighten",
|
|
366
|
+
"styled",
|
|
367
|
+
"themes",
|
|
368
|
+
"typography",
|
|
369
|
+
"useTheme",
|
|
370
|
+
"withTheme"
|
|
371
|
+
],
|
|
372
|
+
"storybook/theming/create": ["create", "themes"],
|
|
373
|
+
"storybook/test": [
|
|
374
|
+
"buildQueries",
|
|
375
|
+
"clearAllMocks",
|
|
376
|
+
"configure",
|
|
377
|
+
"createEvent",
|
|
378
|
+
"expect",
|
|
379
|
+
"findAllByAltText",
|
|
380
|
+
"findAllByDisplayValue",
|
|
381
|
+
"findAllByLabelText",
|
|
382
|
+
"findAllByPlaceholderText",
|
|
383
|
+
"findAllByRole",
|
|
384
|
+
"findAllByTestId",
|
|
385
|
+
"findAllByText",
|
|
386
|
+
"findAllByTitle",
|
|
387
|
+
"findByAltText",
|
|
388
|
+
"findByDisplayValue",
|
|
389
|
+
"findByLabelText",
|
|
390
|
+
"findByPlaceholderText",
|
|
391
|
+
"findByRole",
|
|
392
|
+
"findByTestId",
|
|
393
|
+
"findByText",
|
|
394
|
+
"findByTitle",
|
|
395
|
+
"fireEvent",
|
|
396
|
+
"fn",
|
|
397
|
+
"getAllByAltText",
|
|
398
|
+
"getAllByDisplayValue",
|
|
399
|
+
"getAllByLabelText",
|
|
400
|
+
"getAllByPlaceholderText",
|
|
401
|
+
"getAllByRole",
|
|
402
|
+
"getAllByTestId",
|
|
403
|
+
"getAllByText",
|
|
404
|
+
"getAllByTitle",
|
|
405
|
+
"getByAltText",
|
|
406
|
+
"getByDisplayValue",
|
|
407
|
+
"getByLabelText",
|
|
408
|
+
"getByPlaceholderText",
|
|
409
|
+
"getByRole",
|
|
410
|
+
"getByTestId",
|
|
411
|
+
"getByText",
|
|
412
|
+
"getByTitle",
|
|
413
|
+
"getConfig",
|
|
414
|
+
"getDefaultNormalizer",
|
|
415
|
+
"getElementError",
|
|
416
|
+
"getNodeText",
|
|
417
|
+
"getQueriesForElement",
|
|
418
|
+
"getRoles",
|
|
419
|
+
"getSuggestedQuery",
|
|
420
|
+
"isInaccessible",
|
|
421
|
+
"isMockFunction",
|
|
422
|
+
"logDOM",
|
|
423
|
+
"logRoles",
|
|
424
|
+
"mocked",
|
|
425
|
+
"mocks",
|
|
426
|
+
"onMockCall",
|
|
427
|
+
"prettyDOM",
|
|
428
|
+
"prettyFormat",
|
|
429
|
+
"queries",
|
|
430
|
+
"queryAllByAltText",
|
|
431
|
+
"queryAllByAttribute",
|
|
432
|
+
"queryAllByDisplayValue",
|
|
433
|
+
"queryAllByLabelText",
|
|
434
|
+
"queryAllByPlaceholderText",
|
|
435
|
+
"queryAllByRole",
|
|
436
|
+
"queryAllByTestId",
|
|
437
|
+
"queryAllByText",
|
|
438
|
+
"queryAllByTitle",
|
|
439
|
+
"queryByAltText",
|
|
440
|
+
"queryByAttribute",
|
|
441
|
+
"queryByDisplayValue",
|
|
442
|
+
"queryByLabelText",
|
|
443
|
+
"queryByPlaceholderText",
|
|
444
|
+
"queryByRole",
|
|
445
|
+
"queryByTestId",
|
|
446
|
+
"queryByText",
|
|
447
|
+
"queryByTitle",
|
|
448
|
+
"queryHelpers",
|
|
449
|
+
"resetAllMocks",
|
|
450
|
+
"restoreAllMocks",
|
|
451
|
+
"screen",
|
|
452
|
+
"spyOn",
|
|
453
|
+
"userEvent",
|
|
454
|
+
"waitFor",
|
|
455
|
+
"waitForElementToBeRemoved",
|
|
456
|
+
"within"
|
|
457
|
+
],
|
|
458
|
+
"storybook/internal/channels": [
|
|
459
|
+
"Channel",
|
|
460
|
+
"HEARTBEAT_INTERVAL",
|
|
461
|
+
"HEARTBEAT_MAX_LATENCY",
|
|
462
|
+
"PostMessageTransport",
|
|
463
|
+
"WebsocketTransport",
|
|
464
|
+
"createBrowserChannel"
|
|
465
|
+
],
|
|
466
|
+
"storybook/internal/client-logger": ["deprecate", "logger", "once", "pretty"],
|
|
309
467
|
"storybook/internal/components": [
|
|
310
468
|
"A",
|
|
311
469
|
"ActionBar",
|
|
@@ -377,110 +535,6 @@ var r = {
|
|
|
377
535
|
"resetComponents",
|
|
378
536
|
"withReset"
|
|
379
537
|
],
|
|
380
|
-
"storybook/internal/manager-api": [
|
|
381
|
-
"ActiveTabs",
|
|
382
|
-
"Consumer",
|
|
383
|
-
"ManagerContext",
|
|
384
|
-
"Provider",
|
|
385
|
-
"RequestResponseError",
|
|
386
|
-
"addons",
|
|
387
|
-
"combineParameters",
|
|
388
|
-
"controlOrMetaKey",
|
|
389
|
-
"controlOrMetaSymbol",
|
|
390
|
-
"eventMatchesShortcut",
|
|
391
|
-
"eventToShortcut",
|
|
392
|
-
"experimental_MockUniversalStore",
|
|
393
|
-
"experimental_UniversalStore",
|
|
394
|
-
"experimental_requestResponse",
|
|
395
|
-
"experimental_useUniversalStore",
|
|
396
|
-
"isMacLike",
|
|
397
|
-
"isShortcutTaken",
|
|
398
|
-
"keyToSymbol",
|
|
399
|
-
"merge",
|
|
400
|
-
"mockChannel",
|
|
401
|
-
"optionOrAltSymbol",
|
|
402
|
-
"shortcutMatchesShortcut",
|
|
403
|
-
"shortcutToHumanString",
|
|
404
|
-
"types",
|
|
405
|
-
"useAddonState",
|
|
406
|
-
"useArgTypes",
|
|
407
|
-
"useArgs",
|
|
408
|
-
"useChannel",
|
|
409
|
-
"useGlobalTypes",
|
|
410
|
-
"useGlobals",
|
|
411
|
-
"useParameter",
|
|
412
|
-
"useSharedState",
|
|
413
|
-
"useStoryPrepared",
|
|
414
|
-
"useStorybookApi",
|
|
415
|
-
"useStorybookState"
|
|
416
|
-
],
|
|
417
|
-
"storybook/internal/router": [
|
|
418
|
-
"BaseLocationProvider",
|
|
419
|
-
"DEEPLY_EQUAL",
|
|
420
|
-
"Link",
|
|
421
|
-
"Location",
|
|
422
|
-
"LocationProvider",
|
|
423
|
-
"Match",
|
|
424
|
-
"Route",
|
|
425
|
-
"buildArgsParam",
|
|
426
|
-
"deepDiff",
|
|
427
|
-
"getMatch",
|
|
428
|
-
"parsePath",
|
|
429
|
-
"queryFromLocation",
|
|
430
|
-
"stringifyQuery",
|
|
431
|
-
"useNavigate"
|
|
432
|
-
],
|
|
433
|
-
"@storybook/router": [
|
|
434
|
-
"BaseLocationProvider",
|
|
435
|
-
"DEEPLY_EQUAL",
|
|
436
|
-
"Link",
|
|
437
|
-
"Location",
|
|
438
|
-
"LocationProvider",
|
|
439
|
-
"Match",
|
|
440
|
-
"Route",
|
|
441
|
-
"buildArgsParam",
|
|
442
|
-
"deepDiff",
|
|
443
|
-
"getMatch",
|
|
444
|
-
"parsePath",
|
|
445
|
-
"queryFromLocation",
|
|
446
|
-
"stringifyQuery",
|
|
447
|
-
"useNavigate"
|
|
448
|
-
],
|
|
449
|
-
"storybook/internal/theming": [
|
|
450
|
-
"CacheProvider",
|
|
451
|
-
"ClassNames",
|
|
452
|
-
"Global",
|
|
453
|
-
"ThemeProvider",
|
|
454
|
-
"background",
|
|
455
|
-
"color",
|
|
456
|
-
"convert",
|
|
457
|
-
"create",
|
|
458
|
-
"createCache",
|
|
459
|
-
"createGlobal",
|
|
460
|
-
"createReset",
|
|
461
|
-
"css",
|
|
462
|
-
"darken",
|
|
463
|
-
"ensure",
|
|
464
|
-
"ignoreSsrWarning",
|
|
465
|
-
"isPropValid",
|
|
466
|
-
"jsx",
|
|
467
|
-
"keyframes",
|
|
468
|
-
"lighten",
|
|
469
|
-
"styled",
|
|
470
|
-
"themes",
|
|
471
|
-
"typography",
|
|
472
|
-
"useTheme",
|
|
473
|
-
"withTheme"
|
|
474
|
-
],
|
|
475
|
-
"storybook/internal/theming/create": ["create", "themes"],
|
|
476
|
-
"storybook/internal/channels": [
|
|
477
|
-
"Channel",
|
|
478
|
-
"HEARTBEAT_INTERVAL",
|
|
479
|
-
"HEARTBEAT_MAX_LATENCY",
|
|
480
|
-
"PostMessageTransport",
|
|
481
|
-
"WebsocketTransport",
|
|
482
|
-
"createBrowserChannel"
|
|
483
|
-
],
|
|
484
538
|
"storybook/internal/core-errors": [
|
|
485
539
|
"ARGTYPES_INFO_REQUEST",
|
|
486
540
|
"ARGTYPES_INFO_RESPONSE",
|
|
@@ -609,45 +663,128 @@ var r = {
|
|
|
609
663
|
"UPDATE_QUERY_PARAMS",
|
|
610
664
|
"UPDATE_STORY_ARGS"
|
|
611
665
|
],
|
|
612
|
-
"storybook/internal/types": ["Addon_TypesEnum"],
|
|
613
666
|
"storybook/internal/manager-errors": [
|
|
614
667
|
"Category",
|
|
615
668
|
"ProviderDoesNotExtendBaseProviderError",
|
|
616
669
|
"UncaughtManagerError"
|
|
617
670
|
],
|
|
618
|
-
"storybook/internal/
|
|
671
|
+
"storybook/internal/router": [
|
|
672
|
+
"BaseLocationProvider",
|
|
673
|
+
"DEEPLY_EQUAL",
|
|
674
|
+
"Link",
|
|
675
|
+
"Location",
|
|
676
|
+
"LocationProvider",
|
|
677
|
+
"Match",
|
|
678
|
+
"Route",
|
|
679
|
+
"buildArgsParam",
|
|
680
|
+
"deepDiff",
|
|
681
|
+
"getMatch",
|
|
682
|
+
"parsePath",
|
|
683
|
+
"queryFromLocation",
|
|
684
|
+
"stringifyQuery",
|
|
685
|
+
"useNavigate"
|
|
686
|
+
],
|
|
687
|
+
"storybook/internal/types": ["Addon_TypesEnum"],
|
|
688
|
+
"storybook/internal/manager-api": [
|
|
689
|
+
"ActiveTabs",
|
|
690
|
+
"Consumer",
|
|
691
|
+
"ManagerContext",
|
|
692
|
+
"Provider",
|
|
693
|
+
"RequestResponseError",
|
|
694
|
+
"addons",
|
|
695
|
+
"combineParameters",
|
|
696
|
+
"controlOrMetaKey",
|
|
697
|
+
"controlOrMetaSymbol",
|
|
698
|
+
"eventMatchesShortcut",
|
|
699
|
+
"eventToShortcut",
|
|
700
|
+
"experimental_MockUniversalStore",
|
|
701
|
+
"experimental_UniversalStore",
|
|
702
|
+
"experimental_requestResponse",
|
|
703
|
+
"experimental_useUniversalStore",
|
|
704
|
+
"isMacLike",
|
|
705
|
+
"isShortcutTaken",
|
|
706
|
+
"keyToSymbol",
|
|
707
|
+
"merge",
|
|
708
|
+
"mockChannel",
|
|
709
|
+
"optionOrAltSymbol",
|
|
710
|
+
"shortcutMatchesShortcut",
|
|
711
|
+
"shortcutToHumanString",
|
|
712
|
+
"types",
|
|
713
|
+
"useAddonState",
|
|
714
|
+
"useArgTypes",
|
|
715
|
+
"useArgs",
|
|
716
|
+
"useChannel",
|
|
717
|
+
"useGlobalTypes",
|
|
718
|
+
"useGlobals",
|
|
719
|
+
"useParameter",
|
|
720
|
+
"useSharedState",
|
|
721
|
+
"useStoryPrepared",
|
|
722
|
+
"useStorybookApi",
|
|
723
|
+
"useStorybookState"
|
|
724
|
+
],
|
|
725
|
+
"storybook/internal/theming": [
|
|
726
|
+
"CacheProvider",
|
|
727
|
+
"ClassNames",
|
|
728
|
+
"Global",
|
|
729
|
+
"ThemeProvider",
|
|
730
|
+
"background",
|
|
731
|
+
"color",
|
|
732
|
+
"convert",
|
|
733
|
+
"create",
|
|
734
|
+
"createCache",
|
|
735
|
+
"createGlobal",
|
|
736
|
+
"createReset",
|
|
737
|
+
"css",
|
|
738
|
+
"darken",
|
|
739
|
+
"ensure",
|
|
740
|
+
"ignoreSsrWarning",
|
|
741
|
+
"isPropValid",
|
|
742
|
+
"jsx",
|
|
743
|
+
"keyframes",
|
|
744
|
+
"lighten",
|
|
745
|
+
"styled",
|
|
746
|
+
"themes",
|
|
747
|
+
"typography",
|
|
748
|
+
"useTheme",
|
|
749
|
+
"withTheme"
|
|
750
|
+
],
|
|
751
|
+
"storybook/internal/theming/create": ["create", "themes"]
|
|
619
752
|
};
|
|
620
753
|
|
|
621
754
|
// src/manager/globals/globals.ts
|
|
622
|
-
var
|
|
755
|
+
var o = {
|
|
623
756
|
react: "__REACT__",
|
|
624
757
|
"react-dom": "__REACT_DOM__",
|
|
625
758
|
"react-dom/client": "__REACT_DOM_CLIENT__",
|
|
626
759
|
"@storybook/icons": "__STORYBOOK_ICONS__",
|
|
627
|
-
"storybook/
|
|
628
|
-
"storybook/
|
|
760
|
+
"storybook/manager-api": "__STORYBOOK_API__",
|
|
761
|
+
"storybook/test": "__STORYBOOK_TEST__",
|
|
762
|
+
"storybook/theming": "__STORYBOOK_THEMING__",
|
|
763
|
+
"storybook/theming/create": "__STORYBOOK_THEMING_CREATE__",
|
|
629
764
|
"storybook/internal/channels": "__STORYBOOK_CHANNELS__",
|
|
765
|
+
"storybook/internal/client-logger": "__STORYBOOK_CLIENT_LOGGER__",
|
|
766
|
+
"storybook/internal/components": "__STORYBOOK_COMPONENTS__",
|
|
630
767
|
"storybook/internal/core-errors": "__STORYBOOK_CORE_EVENTS__",
|
|
631
768
|
"storybook/internal/core-events": "__STORYBOOK_CORE_EVENTS__",
|
|
632
769
|
"storybook/internal/manager-errors": "__STORYBOOK_CORE_EVENTS_MANAGER_ERRORS__",
|
|
633
770
|
"storybook/internal/router": "__STORYBOOK_ROUTER__",
|
|
634
|
-
"
|
|
771
|
+
"storybook/internal/types": "__STORYBOOK_TYPES__",
|
|
772
|
+
// @deprecated TODO: delete in 9.1
|
|
773
|
+
"storybook/internal/manager-api": "__STORYBOOK_API__",
|
|
635
774
|
"storybook/internal/theming": "__STORYBOOK_THEMING__",
|
|
636
|
-
"storybook/internal/theming/create": "__STORYBOOK_THEMING_CREATE__"
|
|
637
|
-
|
|
638
|
-
"storybook/internal/types": "__STORYBOOK_TYPES__"
|
|
639
|
-
}, t = Object.keys(e);
|
|
775
|
+
"storybook/internal/theming/create": "__STORYBOOK_THEMING_CREATE__"
|
|
776
|
+
}, r = Object.keys(o);
|
|
640
777
|
|
|
641
778
|
// src/manager/globals/globals-module-info.ts
|
|
642
|
-
var
|
|
643
|
-
(n,
|
|
779
|
+
var l = r.reduce(
|
|
780
|
+
(n, e) => (n[e] = {
|
|
644
781
|
type: "esm",
|
|
645
|
-
varName: e
|
|
646
|
-
namedExports:
|
|
782
|
+
varName: o[e],
|
|
783
|
+
namedExports: t[e],
|
|
647
784
|
defaultExport: !0
|
|
648
785
|
}, n),
|
|
649
786
|
{}
|
|
650
787
|
);
|
|
651
788
|
export {
|
|
652
|
-
|
|
789
|
+
l as globalsModuleInfoMap
|
|
653
790
|
};
|