@aussieljk/forkbook 0.0.1-4 → 0.0.1-6
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/LICENSE +22 -0
- package/README.md +35 -53
- package/dist/_browser-chunks/{Color-KRDPNBZS.js → Color-2BMQTRYG.js} +3 -3
- package/dist/_browser-chunks/WithTooltip-GJACFWKM.js +196 -0
- package/dist/_browser-chunks/chunk-6AKCRYVX.js +6 -0
- package/dist/_browser-chunks/chunk-6EJEEII7.js +1149 -0
- package/dist/_browser-chunks/{chunk-LXQPPHMD.js → chunk-6IKB2UHQ.js} +27 -27
- package/dist/_browser-chunks/chunk-DPRGR3QP.js +5995 -0
- package/dist/_browser-chunks/{chunk-K6GRZSXS.js → chunk-EQKMUQF3.js} +4 -3
- package/dist/_browser-chunks/{chunk-GU3X2J4S.js → chunk-FRAOQJDI.js} +3 -1
- package/dist/_browser-chunks/{chunk-2SCZVUKW.js → chunk-H4ZHAXN3.js} +1 -1
- package/dist/_browser-chunks/{chunk-ZLWA5RIE.js → chunk-I4ATZPNZ.js} +1 -1
- package/dist/_browser-chunks/{chunk-6SHRDXGF.js → chunk-IJYLSHY7.js} +173 -87
- package/dist/_browser-chunks/{chunk-SZCSXISG.js → chunk-NA4ITZTK.js} +7 -5
- package/dist/_browser-chunks/chunk-NGMQJMCY.js +53 -0
- package/dist/_browser-chunks/{chunk-K2B36HKM.js → chunk-O24AZJZ7.js} +1 -1
- package/dist/_browser-chunks/{chunk-BZGX2THJ.js → chunk-QAHDGPZ7.js} +3 -3
- package/dist/_browser-chunks/{chunk-NMRSYACM.js → chunk-SFMQDIN2.js} +4 -3
- package/dist/_browser-chunks/{chunk-ZTQ5MEJ5.js → chunk-UMGDO2ZM.js} +3 -37
- package/dist/_browser-chunks/{chunk-FVSEPWWX.js → chunk-X7D777E6.js} +547 -1622
- package/dist/_browser-chunks/{chunk-52CW7FF7.js → chunk-YYWKZ7O3.js} +3 -1
- package/dist/_node-chunks/{attached-runtime-CYMSKF3A.js → attached-runtime-EBWIOQZN.js} +29 -29
- package/dist/_node-chunks/{builder-manager-RMLSIO45.js → builder-manager-ETBLZ2RH.js} +288 -349
- package/dist/_node-chunks/{chunk-IR34HUSL.js → chunk-252Y5WHZ.js} +7 -7
- package/dist/_node-chunks/{chunk-VPOJCHKM.js → chunk-25PXULSJ.js} +14 -14
- package/dist/_node-chunks/chunk-2DBJWMYE.js +495 -0
- package/dist/_node-chunks/{chunk-KXDJ77EW.js → chunk-3UWWRDA5.js} +7 -7
- package/dist/_node-chunks/{chunk-DVLFCSDG.js → chunk-4KCQYJT6.js} +7 -7
- package/dist/_node-chunks/{chunk-X3E55W5S.js → chunk-4MJIPOJ5.js} +6 -6
- package/dist/_node-chunks/{chunk-5TPSYG4L.js → chunk-4WLIN3VZ.js} +8 -8
- package/dist/_node-chunks/{chunk-WBTLBIED.js → chunk-4XNPO23I.js} +6 -6
- package/dist/_node-chunks/{chunk-NHIRHARE.js → chunk-5T635FTI.js} +10 -10
- package/dist/_node-chunks/{chunk-YU2WFBFL.js → chunk-5Z6MT4RI.js} +8 -8
- package/dist/_node-chunks/{chunk-2QWFS23O.js → chunk-644CUCK5.js} +7 -7
- package/dist/_node-chunks/{chunk-7XCJ7RAJ.js → chunk-7E27CGRU.js} +7 -7
- package/dist/_node-chunks/{chunk-WS367FSJ.js → chunk-A35J7YYA.js} +6 -6
- package/dist/_node-chunks/{chunk-ILFIERUB.js → chunk-ALHPFKVB.js} +8 -8
- package/dist/_node-chunks/{chunk-SQMCVWOR.js → chunk-ANDQVXYX.js} +8 -8
- package/dist/_node-chunks/{chunk-HUFAUSEX.js → chunk-AS4SFRCZ.js} +6 -6
- package/dist/_node-chunks/{chunk-XBXGLD3K.js → chunk-BLUMKQQB.js} +6 -6
- package/dist/_node-chunks/{chunk-QU5ANYM7.js → chunk-C5JG7EKF.js} +6 -6
- package/dist/_node-chunks/{chunk-P6QAFJ5M.js → chunk-CBUQY454.js} +7 -15
- package/dist/_node-chunks/{chunk-4LPAWP5S.js → chunk-CF7KLGUW.js} +22 -20
- package/dist/_node-chunks/{chunk-MOITZTEA.js → chunk-CGVPHZVD.js} +8 -8
- package/dist/_node-chunks/{chunk-2NWHHNNI.js → chunk-DABFUVLR.js} +6 -6
- package/dist/_node-chunks/{chunk-XH6TDVML.js → chunk-DCNZ6SFN.js} +6 -6
- package/dist/_node-chunks/{chunk-F2N6BJRH.js → chunk-DDGW2EBW.js} +29843 -51588
- package/dist/_node-chunks/{chunk-OS5LQEC6.js → chunk-DRLBJM6X.js} +7 -7
- package/dist/_node-chunks/{chunk-GEMKJCEE.js → chunk-E3O7VAPG.js} +10 -10
- package/dist/_node-chunks/{chunk-4GD7MMLJ.js → chunk-FIFCNBTL.js} +7 -7
- package/dist/_node-chunks/{chunk-UMZSNFWM.js → chunk-FQWTUSYB.js} +6 -6
- package/dist/_node-chunks/{chunk-JEEXR245.js → chunk-G6YNW4FK.js} +7 -7
- package/dist/_node-chunks/{chunk-HP5UY6OY.js → chunk-GDFQQO5U.js} +6 -6
- package/dist/_node-chunks/{chunk-653BSJIX.js → chunk-GGTXOH3W.js} +6 -6
- package/dist/_node-chunks/{chunk-PDCSUZ4L.js → chunk-GIOREKIG.js} +7 -7
- package/dist/_node-chunks/{chunk-V2JDVM46.js → chunk-GOFK4EKU.js} +6 -6
- package/dist/_node-chunks/{chunk-INEYTOWF.js → chunk-GQ3HJNIH.js} +10 -13
- package/dist/_node-chunks/{chunk-2APY2YSW.js → chunk-GRTI5653.js} +7 -7
- package/dist/_node-chunks/{chunk-KN2S7JF2.js → chunk-HKL3VOYX.js} +6 -6
- package/dist/_node-chunks/{chunk-A2UMIN5B.js → chunk-HUPRQZ3I.js} +7 -7
- package/dist/_node-chunks/{chunk-7JA2DMCJ.js → chunk-HWRHYM7Z.js} +6 -6
- package/dist/_node-chunks/{chunk-SBQT3LMM.js → chunk-I7HRDCNY.js} +10 -10
- package/dist/_node-chunks/{chunk-2IJCISIB.js → chunk-IFPMZ247.js} +6 -6
- package/dist/_node-chunks/{chunk-DIUBMAMV.js → chunk-J6M5CRYZ.js} +8 -8
- package/dist/_node-chunks/{chunk-IBO346NQ.js → chunk-JPXJI6QR.js} +60 -134
- package/dist/_node-chunks/{chunk-STRSG3GT.js → chunk-JS2J2SKX.js} +6 -6
- package/dist/_node-chunks/{chunk-FNGLVURC.js → chunk-JZWF3XLN.js} +6 -6
- package/dist/_node-chunks/{chunk-KINEBDMM.js → chunk-KF3FT3NI.js} +9 -9
- package/dist/_node-chunks/chunk-KWPWQA7G.js +2609 -0
- package/dist/_node-chunks/{chunk-OIIORQX5.js → chunk-L4JGWK4K.js} +6 -6
- package/dist/_node-chunks/{chunk-MRZD5SBV.js → chunk-LFIFBDMS.js} +6 -6
- package/dist/_node-chunks/{chunk-UAALLQAQ.js → chunk-LWKLJYYQ.js} +6 -6
- package/dist/_node-chunks/{chunk-AFKKN27O.js → chunk-LXVSVTQ3.js} +6 -6
- package/dist/_node-chunks/chunk-MDW3GSU3.js +69 -0
- package/dist/_node-chunks/{chunk-UXW4I2CN.js → chunk-MFN2XBPL.js} +7 -7
- package/dist/_node-chunks/{chunk-ESZVID7Q.js → chunk-MQFB44YS.js} +7 -7
- package/dist/_node-chunks/{chunk-3XDIBUGD.js → chunk-MZ2GSR3G.js} +23 -51
- package/dist/_node-chunks/{chunk-POXTROIX.js → chunk-N7HEOGTM.js} +9 -6
- package/dist/_node-chunks/{chunk-UIFLXDUL.js → chunk-NUAQC3XP.js} +16 -13
- package/dist/_node-chunks/{chunk-BOUA7OB7.js → chunk-NX6CSWF3.js} +8 -8
- package/dist/_node-chunks/{chunk-B3LK7C7B.js → chunk-NZ7EQWYA.js} +9 -9
- package/dist/_node-chunks/{chunk-U5QMVW3H.js → chunk-OLGIDCVD.js} +650 -9
- package/dist/_node-chunks/{chunk-NAYTBC72.js → chunk-P65JVLO3.js} +8 -8
- package/dist/_node-chunks/{chunk-M2UZP5GC.js → chunk-PAN35AYX.js} +7 -7
- package/dist/_node-chunks/{chunk-GZBUCUF7.js → chunk-PLWLCVP2.js} +6 -6
- package/dist/_node-chunks/{chunk-A4YELYR3.js → chunk-Q4BEWGMK.js} +6 -6
- package/dist/_node-chunks/{chunk-YYIZ2PC4.js → chunk-QNUXGVZZ.js} +6 -6
- package/dist/_node-chunks/{chunk-WHZWLJGO.js → chunk-R5DWO2S2.js} +31 -30
- package/dist/_node-chunks/{chunk-RMLENEZC.js → chunk-SLZV7PTQ.js} +8 -8
- package/dist/_node-chunks/{chunk-B5VFV3ZW.js → chunk-TIRP5JQM.js} +11 -10
- package/dist/_node-chunks/{chunk-TLVEPWBN.js → chunk-TMXWDY2O.js} +6 -6
- package/dist/_node-chunks/{chunk-LGUMVMBA.js → chunk-TN3ULFFZ.js} +6 -6
- package/dist/_node-chunks/{chunk-5ZLOPVTG.js → chunk-TPSJW4CQ.js} +6 -6
- package/dist/_node-chunks/{chunk-RNF3Z4ZJ.js → chunk-TYBPAV3X.js} +6 -6
- package/dist/_node-chunks/chunk-UUE3PSJB.js +11 -0
- package/dist/_node-chunks/chunk-VKNRNBTB.js +18 -0
- package/dist/_node-chunks/{chunk-6Y6RBJD7.js → chunk-VPU4E7DI.js} +25 -8
- package/dist/_node-chunks/{chunk-FJDJE7XC.js → chunk-WIQ6Y3NX.js} +6 -6
- package/dist/_node-chunks/{chunk-DD2S4BFV.js → chunk-WRG3CFGS.js} +6 -6
- package/dist/_node-chunks/{chunk-FAZ3MUOI.js → chunk-X3RTVNRN.js} +7 -7
- package/dist/_node-chunks/chunk-XOGU5PWI.js +347 -0
- package/dist/_node-chunks/{chunk-AU3SF2WM.js → chunk-XWGMQW2H.js} +6 -6
- package/dist/_node-chunks/chunk-YCXTTQ7K.js +620 -0
- package/dist/_node-chunks/{chunk-KZBZYQTZ.js → chunk-YHH57LHY.js} +9 -9
- package/dist/_node-chunks/{chunk-J3M3X7GO.js → chunk-YMZ2SGFK.js} +6 -6
- package/dist/_node-chunks/{chunk-AY6B2C46.js → chunk-YNENOZRY.js} +7 -7
- package/dist/_node-chunks/{chunk-CGWACHNW.js → chunk-YPGVYNJB.js} +6 -6
- package/dist/_node-chunks/{chunk-OQ4NCWE4.js → chunk-YQDBSAXW.js} +7 -7
- package/dist/_node-chunks/{chunk-YGXJOSRU.js → chunk-Z4NZLBOX.js} +7 -7
- package/dist/_node-chunks/{chunk-74IEHSIR.js → chunk-ZC3ZZKMS.js} +8 -8
- package/dist/_node-chunks/{chunk-QDLR4JF5.js → chunk-ZCITDAV4.js} +34 -949
- package/dist/_node-chunks/chunk-ZNSGFYAT.js +25 -0
- package/dist/_node-chunks/{chunk-XD5SYXAU.js → chunk-ZSH6BUCW.js} +25 -25
- package/dist/_node-chunks/{chunk-X2KWNNFB.js → chunk-ZTFNOXZF.js} +6 -6
- package/dist/_node-chunks/dist-GGTGKXZA.js +27 -0
- package/dist/_node-chunks/dist-NS676VJR.js +16 -0
- package/dist/_node-chunks/{local-runtime-KTI3DH6X.js → local-runtime-BUTEKJYV.js} +20 -20
- package/dist/_node-chunks/{mdx-plugin-2E3SW5TL.js → mdx-plugin-7WXQIHPV.js} +2263 -130
- package/dist/_node-chunks/{monorepo-MWAMFHKY.js → monorepo-NCD3X2BR.js} +11 -11
- package/dist/_node-chunks/{monorepo-optimized-tests-relaxed-limits-no-story-deletion-MGORG6W7.js → monorepo-optimized-tests-relaxed-limits-no-story-deletion-SD3B272K.js} +11 -11
- package/dist/_node-chunks/optimized-tests-ITVOHEOA.js +22 -0
- package/dist/_node-chunks/{pattern-copy-play-QTQOY7E7.js → pattern-copy-play-3QJANDJD.js} +9 -9
- package/dist/_node-chunks/postinstallAddon-LEUHOKX6.js +20 -0
- package/dist/_node-chunks/{rehype-external-links-T7DZNKMB.js → rehype-external-links-4LR5BDR2.js} +9 -9
- package/dist/_node-chunks/{rehype-slug-CSHI5WYI.js → rehype-slug-PWFRGOEV.js} +9 -9
- package/dist/_node-chunks/{relaxed-limits-RAZD36YR.js → relaxed-limits-VNNWUW7X.js} +11 -11
- package/dist/_node-chunks/{run-S6XSLPEB.js → run-RUAAWEQT.js} +13 -13
- package/dist/_node-chunks/{run-KJ3Z2TTY.js → run-YK6ARCWS.js} +17 -17
- package/dist/_node-chunks/session-id-JJYVZAKO.js +23 -0
- package/dist/_node-chunks/{setup-35J66GFB.js → setup-4QKCICV6.js} +8 -8
- package/dist/_node-chunks/{vitest.config.4.template-Z7OCRDKD.js → vitest.config.4.template-WVFLIXN7.js} +7 -7
- package/dist/actions/decorator.js +2 -1
- package/dist/actions/index.js +2 -1
- package/dist/addon-a11y/index.js +2 -1
- package/dist/addon-a11y/manager.js +24 -17
- package/dist/addon-a11y/preset.js +7 -7
- package/dist/addon-a11y/preview.js +2 -1
- package/dist/addon-docs/blocks.js +46 -25
- package/dist/addon-docs/manager.js +2 -2
- package/dist/addon-docs/preset.js +10 -10
- package/dist/addon-links/index.js +3 -2
- package/dist/addon-links/preview.d.ts +1 -1
- package/dist/addon-links/preview.js +3 -2
- package/dist/addon-links/react/index.js +2 -1
- package/dist/addon-mcp/preset.js +8 -8
- package/dist/addon-mcp/tools/preview-stories/preview-stories-app-script.js +17 -45
- package/dist/addon-ondevice-actions/index.js +5 -1
- package/dist/addon-ondevice-actions/register.js +5 -1
- package/dist/addon-pseudo-states/manager.js +2 -2
- package/dist/addon-pseudo-states/preview.d.ts +1 -1
- package/dist/addon-themes/manager.js +1 -1
- package/dist/addon-themes/postinstall.js +7 -7
- package/dist/addon-vitest/constants.js +8 -8
- package/dist/addon-vitest/manager.js +8 -8
- package/dist/addon-vitest/node/coverage-reporter.js +8 -8
- package/dist/addon-vitest/node/vitest.js +16 -16
- package/dist/addon-vitest/postinstall.js +10 -10
- package/dist/addon-vitest/preset.js +15 -16
- package/dist/addon-vitest/vitest-plugin/global-setup.js +7 -7
- package/dist/addon-vitest/vitest-plugin/index.js +17 -17
- package/dist/babel/index.d.ts +91 -842
- package/dist/babel/index.js +13 -19
- package/dist/bin/core.js +61 -60
- package/dist/bin/dispatcher.js +10 -10
- package/dist/bin/loader.js +16 -15
- package/dist/builder-vite/index.js +15 -15
- package/dist/builder-vite/preset.js +13 -13
- package/dist/{chunk-DF6btpT3.d.ts → chunk-BGhyFTJO.d.ts} +2 -2
- package/dist/chunk-CV4-Z2pn.d.ts +30 -0
- package/dist/{chunk-DvufcbCc.d.ts → chunk-CVY28Ngy.d.ts} +1 -1
- package/dist/{chunk-B2t1tGRh.d.ts → chunk-CYuvV2sR.d.ts} +11 -13
- package/dist/{chunk-BYnH2sbb.d.ts → chunk-ClI-HEh5.d.ts} +1 -1
- package/dist/{chunk-DIz17UEJ.d.ts → chunk-CzmZhVrn.d.ts} +35 -1
- package/dist/{chunk-B2xylxt5.d.ts → chunk-DROZ9oel.d.ts} +7 -271
- package/dist/cli/index.d.ts +13 -866
- package/dist/cli/index.js +42 -4952
- package/dist/cli/tools/sdk/child-host.d.ts +1 -1
- package/dist/cli/tools/sdk/child-host.js +17 -17
- package/dist/cli/tools/sdk/index.d.ts +1 -1
- package/dist/cli/tools/sdk/index.js +18 -18
- package/dist/cli-commands/bin/index.js +7 -7
- package/dist/client-logger/index.js +3 -1
- package/dist/common/index.d.ts +5 -4
- package/dist/common/index.js +35 -37
- package/dist/components/index.d.ts +14 -231
- package/dist/components/index.js +2518 -8365
- package/dist/core-events/index.d.ts +4 -3
- package/dist/core-events/index.js +3 -1
- package/dist/core-server/index.d.ts +2 -2
- package/dist/core-server/index.js +450 -147
- package/dist/core-server/presets/common-manager.js +96 -894
- package/dist/core-server/presets/common-override-preset.js +12 -10
- package/dist/core-server/presets/common-preset.js +39 -40
- package/dist/create/bin/index.js +7 -7
- package/dist/create/index.js +15 -15
- package/dist/csf/index.d.ts +2 -2
- package/dist/csf/index.js +27 -93
- package/dist/csf-tools/index.d.ts +2 -12
- package/dist/csf-tools/index.js +14 -14
- package/dist/instrumenter/index.js +3 -1
- package/dist/manager/_manager-chunks/{globals-runtime-dKGpUUSb.js → globals-runtime-B-IeQLQu.js} +285 -61
- package/dist/manager/_manager-chunks/{globals-runtime-DuLFjsF4.js → globals-runtime-B5-0Ccbv.js} +1 -1
- package/dist/manager/_manager-chunks/{globals-runtime-8HkdnU2F.js → globals-runtime-B71TiXST.js} +93 -2146
- package/dist/manager/_manager-chunks/globals-runtime-BMCaBukU.js +413 -0
- package/dist/manager/_manager-chunks/globals-runtime-BUP5e_t9.js +1396 -0
- package/dist/manager/_manager-chunks/globals-runtime-C7mqoHpE.js +2093 -0
- package/dist/manager/_manager-chunks/globals-runtime-CBviMKtt.js +446 -0
- package/dist/manager/_manager-chunks/{globals-runtime-eLPTIfX-.js → globals-runtime-CYNosEiD.js} +1 -2
- package/dist/manager/_manager-chunks/globals-runtime-C_evJrEn.js +1960 -0
- package/dist/manager/_manager-chunks/{globals-runtime-C02fvgcd.js → globals-runtime-CdgVeAbk.js} +408 -377
- package/dist/manager/_manager-chunks/{globals-runtime-BmphMP6z.js → globals-runtime-Cqn8KdSZ.js} +4 -4
- package/dist/manager/_manager-chunks/{globals-runtime-ZHrQFa3-.js → globals-runtime-CrIF09P8.js} +1246 -539
- package/dist/manager/_manager-chunks/{globals-runtime-BvM-NY2g.js → globals-runtime-Ct1kY4wb.js} +638 -1731
- package/dist/manager/_manager-chunks/globals-runtime-CvyFEPIY.js +5282 -0
- package/dist/manager/_manager-chunks/{globals-runtime-FC201B7s.js → globals-runtime-DMBjo1QS.js} +2 -1
- package/dist/manager/_manager-chunks/{globals-runtime-C9P2ZbMM.js → globals-runtime-DUK6bGcb.js} +52 -25
- package/dist/manager/_manager-chunks/globals-runtime-DedfO-DP.js +3414 -0
- package/dist/manager/_manager-chunks/{globals-runtime-q5R9dawi.js → globals-runtime-DqhIYwLp.js} +165 -152
- package/dist/manager/_manager-chunks/globals-runtime-XSxCU7PR.js +41 -0
- package/dist/manager/_manager-chunks/runtime-BR5z0WoJ.js +456 -0
- package/dist/manager/_manager-chunks/{runtime-DdCaBowH.js → runtime-BgYvp1WN.js} +15 -7
- package/dist/manager/_manager-chunks/{runtime-BGvLm94o.js → runtime-CHI-LHF1.js} +3 -3
- package/dist/manager/_manager-chunks/{runtime-BdLdsHca.js → runtime-CUymj6EY.js} +280 -288
- package/dist/manager/_manager-chunks/runtime-CaU1DSEZ.js +528 -0
- package/dist/manager/_manager-chunks/{runtime-DMig8mT7.js → runtime-CqItbdKW.js} +3 -2
- package/dist/manager/_manager-chunks/{runtime-B9QzcYO3.js → runtime-D4ZOOIV0.js} +5 -531
- package/dist/manager/_manager-chunks/{runtime-50_aob4S.js → runtime-DER98nV0.js} +3 -19
- package/dist/manager/_manager-chunks/{runtime-CE2sHVqs.js → runtime-DrTLBe7a.js} +39 -40
- package/dist/manager/_manager-chunks/runtime-MAf7Wpk5.js +692 -0
- package/dist/manager/_manager-chunks/{runtime-CKP1i0--.js → runtime-cVFIMcca.js} +1 -1
- package/dist/manager/globals-runtime.js +1 -1
- package/dist/manager/globals.d.ts +1 -1
- package/dist/manager/globals.js +1 -1
- package/dist/manager/runtime.js +1 -1
- package/dist/manager-api/index.d.ts +1 -1
- package/dist/manager-api/index.js +22 -28
- package/dist/manager-errors.d.ts +1 -1
- package/dist/mcp/index.js +8 -8
- package/dist/mocking-utils/index.js +16 -11
- package/dist/nextjs-vite/index.js +3 -2
- package/dist/nextjs-vite/node/index.js +7 -7
- package/dist/nextjs-vite/preset.js +11 -11
- package/dist/nextjs-vite/vite-plugin/index.js +7 -7
- package/dist/nextjs-vite-plugin/index.d.ts +1 -2
- package/dist/nextjs-vite-plugin/index.js +12 -27
- package/dist/nextjs-vite-plugin/mocks/storybook.global.js +8 -8
- package/dist/node-logger/index.d.ts +65 -72
- package/dist/node-logger/index.js +11 -12
- package/dist/oxc-parser/index.js +11 -13
- package/dist/oxc-parser/worker.js +10 -10
- package/dist/preview/_chunks/{runtime-DVM_AHbR.js → runtime-6P-h06Te.js} +51 -50
- package/dist/preview/_chunks/{runtime-BoxmlDdB.js → runtime-B9KKIDGa.js} +202 -81
- package/dist/preview/_chunks/{runtime-BIzIdDbb.js → runtime-BPwAnlRx.js} +482 -334
- package/dist/preview/_chunks/{runtime-q3wt0e_N.js → runtime-BUnOhg9h.js} +2 -2
- package/dist/preview/_chunks/runtime-Bcv1hJky.js +6305 -0
- package/dist/preview/_chunks/{runtime-CqHxptiK.js → runtime-C1jgT6tJ.js} +93 -2145
- package/dist/preview/_chunks/{runtime-D7B4bVe_.js → runtime-C8QFpkFV.js} +6 -6
- package/dist/preview/_chunks/{runtime-CijtAN7R.js → runtime-DdqR8Fd0.js} +15 -6
- package/dist/preview/_chunks/{runtime-B3y8ocOg.js → runtime-DvBfMhis.js} +2 -2
- package/dist/preview/_chunks/{runtime-BZSnICCg.js → runtime-WapFVPAh.js} +29 -29
- package/dist/preview/runtime.js +1 -1
- package/dist/preview-api/index.d.ts +1 -1
- package/dist/preview-api/index.js +2 -1
- package/dist/preview-errors.d.ts +1 -1
- package/dist/react/docgen/docgen-worker.js +11 -12
- package/dist/react/entry-preview.js +2 -1
- package/dist/react/index.js +6 -4
- package/dist/react/preset.js +13 -14
- package/dist/react/preview.js +3 -2
- package/dist/react-native/bin/get-stories.js +8 -8
- package/dist/react-native/index.js +25 -211
- package/dist/react-native/metro/node.js +10 -9
- package/dist/react-native/metro/withStorybook.js +11 -10
- package/dist/react-native/scripts/generate.js +8 -8
- package/dist/react-vite/node/index.js +7 -7
- package/dist/react-vite/preset.js +7 -7
- package/dist/router/index.js +3 -1
- package/dist/server-errors.d.ts +1 -1
- package/dist/server-errors.js +9 -9
- package/dist/shared/open-service/index.d.ts +1 -1
- package/dist/shared/open-service/services/docgen/worker/docgen-worker.js +9 -9
- package/dist/telemetry/index.js +43 -45
- package/dist/test/index.js +808 -573
- package/dist/theming/create.js +2 -1
- package/dist/theming/index.js +22 -1
- package/dist/types/index.d.ts +1 -1
- package/package.json +17 -45
- package/dist/_browser-chunks/WithTooltip-523JD6VH.js +0 -1619
- package/dist/_browser-chunks/chunk-5P4QA6MY.js +0 -20
- package/dist/_browser-chunks/chunk-UDQ3XQFC.js +0 -108
- package/dist/_node-chunks/chunk-7XCEKQGV.js +0 -18
- package/dist/_node-chunks/chunk-EGS2SAD2.js +0 -5414
- package/dist/_node-chunks/chunk-GKTCJPLL.js +0 -36
- package/dist/_node-chunks/chunk-HENM5ZK3.js +0 -1877
- package/dist/_node-chunks/chunk-HQM4ISVU.js +0 -11
- package/dist/_node-chunks/chunk-K3I3G4VL.js +0 -4731
- package/dist/_node-chunks/chunk-MZMPFII2.js +0 -29
- package/dist/_node-chunks/chunk-NYAWUR6L.js +0 -3823
- package/dist/_node-chunks/chunk-NYRUWAL3.js +0 -23
- package/dist/_node-chunks/chunk-SSZ5REKS.js +0 -3008
- package/dist/_node-chunks/chunk-WEW23EEE.js +0 -662
- package/dist/_node-chunks/chunk-XWQEWRFD.js +0 -51
- package/dist/_node-chunks/dist-CNA633FI.js +0 -16
- package/dist/_node-chunks/globby-HRQV5N3V.js +0 -2884
- package/dist/_node-chunks/jiti-WE7NHS2Y.js +0 -3848
- package/dist/_node-chunks/lib-7MVA6CTW.js +0 -366
- package/dist/_node-chunks/optimized-tests-IAX6YURR.js +0 -22
- package/dist/_node-chunks/postinstallAddon-ROH2TBJX.js +0 -20
- package/dist/_node-chunks/session-id-GM226DGP.js +0 -23
- package/dist/chunk-BfBzpgct.d.ts +0 -916
- package/dist/core-server/presets/common-manager.css +0 -170
- package/dist/manager/_manager-chunks/globals-runtime-BIKBO23x.js +0 -3389
- package/dist/manager/_manager-chunks/globals-runtime-DkAPXCvc.js +0 -9766
- package/dist/manager/_manager-chunks/globals-runtime-DtcOnYHR.js +0 -5357
- package/dist/manager/_manager-chunks/runtime-89Cb0A8U.js +0 -998
- package/dist/manager/_manager-chunks/runtime-wL4UO7YO.js +0 -452
- package/dist/preview/_chunks/runtime-BTPtVY1p.js +0 -1102
- package/dist/preview/_chunks/runtime-DZToXfvO.js +0 -9767
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
applyDecorators
|
|
3
3
|
} from "./chunk-WHQRNHXD.js";
|
|
4
|
+
import {
|
|
5
|
+
global
|
|
6
|
+
} from "./chunk-6AKCRYVX.js";
|
|
4
7
|
import {
|
|
5
8
|
__export
|
|
6
9
|
} from "./chunk-IMSF75WX.js";
|
|
@@ -18,7 +21,6 @@ __export(entry_preview_exports, {
|
|
|
18
21
|
});
|
|
19
22
|
import * as React3 from "react";
|
|
20
23
|
import { Tag } from "@aussieljk/forkbook/internal/preview-api";
|
|
21
|
-
import { global as global2 } from "@storybook/global";
|
|
22
24
|
import { configure } from "@aussieljk/forkbook/test";
|
|
23
25
|
|
|
24
26
|
// src/react/act-compat.ts
|
|
@@ -86,7 +88,6 @@ var render = (args, context) => {
|
|
|
86
88
|
|
|
87
89
|
// src/react/renderToCanvas.tsx
|
|
88
90
|
import { Fragment, Component as ReactComponent, StrictMode } from "react";
|
|
89
|
-
import { global } from "@storybook/global";
|
|
90
91
|
import { jsx as jsx2 } from "react/jsx-runtime";
|
|
91
92
|
var { FRAMEWORK_OPTIONS } = global, ErrorBoundary = class extends ReactComponent {
|
|
92
93
|
constructor() {
|
|
@@ -167,7 +168,7 @@ var decorators = [
|
|
|
167
168
|
return jsx3(React3.Suspense, { children: story() });
|
|
168
169
|
},
|
|
169
170
|
(story, context) => {
|
|
170
|
-
if (context.tags?.includes(Tag.TEST_FN) && !
|
|
171
|
+
if (context.tags?.includes(Tag.TEST_FN) && !global.FEATURES?.experimentalTestSyntax)
|
|
171
172
|
throw new Error(
|
|
172
173
|
"To use the experimental test function, you must enable the experimentalTestSyntax feature flag. See https://forkbook.ljk.dev/docs/api/main-config/main-config-features#experimentaltestsyntax"
|
|
173
174
|
);
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
EVENT_ID
|
|
3
3
|
} from "./chunk-N5WQGLI7.js";
|
|
4
|
+
import {
|
|
5
|
+
global
|
|
6
|
+
} from "./chunk-6AKCRYVX.js";
|
|
4
7
|
|
|
5
8
|
// src/actions/runtime/configureActions.ts
|
|
6
9
|
var config = {
|
|
@@ -13,7 +16,6 @@ var config = {
|
|
|
13
16
|
|
|
14
17
|
// src/actions/runtime/action.ts
|
|
15
18
|
import { ImplicitActionsDuringRendering } from "@aussieljk/forkbook/internal/preview-errors";
|
|
16
|
-
import { global } from "@storybook/global";
|
|
17
19
|
import { addons } from "@aussieljk/forkbook/preview-api";
|
|
18
20
|
var findProto = (obj, callback) => {
|
|
19
21
|
let proto = Object.getPrototypeOf(obj);
|
|
@@ -48,6 +48,9 @@ import {
|
|
|
48
48
|
MINIMAL_VIEWPORTS,
|
|
49
49
|
PARAM_KEY
|
|
50
50
|
} from "./chunk-QDXFODK4.js";
|
|
51
|
+
import {
|
|
52
|
+
global
|
|
53
|
+
} from "./chunk-6AKCRYVX.js";
|
|
51
54
|
import {
|
|
52
55
|
__toESM
|
|
53
56
|
} from "./chunk-IMSF75WX.js";
|
|
@@ -89,7 +92,6 @@ import {
|
|
|
89
92
|
UPDATE_GLOBALS,
|
|
90
93
|
UPDATE_STORY_ARGS
|
|
91
94
|
} from "@aussieljk/forkbook/internal/core-events";
|
|
92
|
-
import { global } from "@storybook/global";
|
|
93
95
|
var HooksContext = class {
|
|
94
96
|
constructor() {
|
|
95
97
|
this.hookListsMap = void 0;
|
|
@@ -324,9 +326,6 @@ import {
|
|
|
324
326
|
} from "@aussieljk/forkbook/internal/preview-errors";
|
|
325
327
|
var import_memoizerific2 = __toESM(require_memoizerific(), 1);
|
|
326
328
|
|
|
327
|
-
// src/preview-api/modules/store/ArgsStore.ts
|
|
328
|
-
import { global as global2 } from "@storybook/global";
|
|
329
|
-
|
|
330
329
|
// src/preview-api/modules/store/args.ts
|
|
331
330
|
import { once } from "@aussieljk/forkbook/internal/client-logger";
|
|
332
331
|
import { dedent } from "ts-dedent";
|
|
@@ -428,7 +427,7 @@ function groupArgsByTarget({
|
|
|
428
427
|
function deleteUndefined(obj) {
|
|
429
428
|
return Object.keys(obj).forEach((key) => obj[key] === void 0 && delete obj[key]), obj;
|
|
430
429
|
}
|
|
431
|
-
var argTypesForValidation = (story) =>
|
|
430
|
+
var argTypesForValidation = (story) => global.FEATURES?.docgenServer ? inferArgTypes({
|
|
432
431
|
id: story.id,
|
|
433
432
|
argTypes: story.argTypes,
|
|
434
433
|
initialArgs: story.initialArgs
|
|
@@ -644,8 +643,6 @@ import {
|
|
|
644
643
|
includeConditionalArg
|
|
645
644
|
} from "@aussieljk/forkbook/internal/csf";
|
|
646
645
|
import { NoRenderFunctionError } from "@aussieljk/forkbook/internal/preview-errors";
|
|
647
|
-
import { global as global3 } from "@storybook/global";
|
|
648
|
-
import { global as globalThis2 } from "@storybook/global";
|
|
649
646
|
|
|
650
647
|
// src/preview-api/modules/preview-web/render/mount-utils.ts
|
|
651
648
|
function mountDestructured(playFunction) {
|
|
@@ -801,7 +798,7 @@ function prepareMeta(componentAnnotations, projectAnnotations, moduleExport) {
|
|
|
801
798
|
};
|
|
802
799
|
}
|
|
803
800
|
function preparePartialAnnotations(storyAnnotations, componentAnnotations, projectAnnotations) {
|
|
804
|
-
let defaultTags = [Tag.DEV, Tag.TEST], extraTags =
|
|
801
|
+
let defaultTags = [Tag.DEV, Tag.TEST], extraTags = global.DOCS_OPTIONS?.autodocs === !0 ? [Tag.AUTODOCS] : [], overrideTags = storyAnnotations?.tags?.includes(Tag.TEST_FN) ? [`!${Tag.AUTODOCS}`] : [], tags = combineTags(
|
|
805
802
|
...defaultTags,
|
|
806
803
|
...extraTags,
|
|
807
804
|
...projectAnnotations.tags ?? [],
|
|
@@ -846,7 +843,7 @@ function preparePartialAnnotations(storyAnnotations, componentAnnotations, proje
|
|
|
846
843
|
argTypes: passedArgTypes,
|
|
847
844
|
storyGlobals
|
|
848
845
|
};
|
|
849
|
-
contextForEnhancers.argTypes = argTypesEnhancers.filter((enhancer) => !(
|
|
846
|
+
contextForEnhancers.argTypes = argTypesEnhancers.filter((enhancer) => !(global.FEATURES?.docgenServer && enhancer.secondPass)).reduce(
|
|
850
847
|
(accumulatedArgTypes, enhancer) => enhancer({ ...contextForEnhancers, argTypes: accumulatedArgTypes }),
|
|
851
848
|
contextForEnhancers.argTypes
|
|
852
849
|
);
|
|
@@ -870,7 +867,7 @@ function prepareContext(context) {
|
|
|
870
867
|
allArgs: void 0,
|
|
871
868
|
argsByTarget: void 0
|
|
872
869
|
};
|
|
873
|
-
if (
|
|
870
|
+
if (global.FEATURES?.argTypeTargetsV7) {
|
|
874
871
|
let argsByTarget = groupArgsByTarget(context);
|
|
875
872
|
targetedContext = {
|
|
876
873
|
...context,
|
|
@@ -1495,7 +1492,6 @@ import {
|
|
|
1495
1492
|
StoryIndexFetchError,
|
|
1496
1493
|
StoryStoreAccessedBeforeInitializationError
|
|
1497
1494
|
} from "@aussieljk/forkbook/internal/preview-errors";
|
|
1498
|
-
import { global as global4 } from "@storybook/global";
|
|
1499
1495
|
|
|
1500
1496
|
// src/preview-api/modules/preview-web/render/StoryRender.ts
|
|
1501
1497
|
import {
|
|
@@ -1762,7 +1758,7 @@ var StoryRender = class {
|
|
|
1762
1758
|
};
|
|
1763
1759
|
|
|
1764
1760
|
// src/preview-api/modules/preview-web/Preview.tsx
|
|
1765
|
-
var { fetch } =
|
|
1761
|
+
var { fetch } = global, STORY_INDEX_PATH = "./index.json", Preview = class {
|
|
1766
1762
|
constructor(importFn, getProjectAnnotations, channel = addons.getChannel(), shouldInitialize = !0) {
|
|
1767
1763
|
this.importFn = importFn;
|
|
1768
1764
|
this.getProjectAnnotations = getProjectAnnotations;
|
|
@@ -2031,9 +2027,6 @@ var { fetch } = global4, STORY_INDEX_PATH = "./index.json", Preview = class {
|
|
|
2031
2027
|
}
|
|
2032
2028
|
};
|
|
2033
2029
|
|
|
2034
|
-
// src/preview-api/modules/preview-web/PreviewWeb.tsx
|
|
2035
|
-
import { global as global9 } from "@storybook/global";
|
|
2036
|
-
|
|
2037
2030
|
// src/preview-api/modules/preview-web/PreviewWithSelection.tsx
|
|
2038
2031
|
import { logger as logger5 } from "@aussieljk/forkbook/internal/client-logger";
|
|
2039
2032
|
import {
|
|
@@ -2066,28 +2059,8 @@ function isMdxEntry({ tags }) {
|
|
|
2066
2059
|
return tags?.includes(Tag.UNATTACHED_MDX) || tags?.includes(Tag.ATTACHED_MDX);
|
|
2067
2060
|
}
|
|
2068
2061
|
|
|
2069
|
-
// src/preview-api/modules/preview-web/
|
|
2070
|
-
|
|
2071
|
-
|
|
2072
|
-
// src/preview-api/modules/preview-web/getEmbedResizeViewport.ts
|
|
2073
|
-
var getEmbedResizeViewport = (storyStore, render, reference) => {
|
|
2074
|
-
if (!storyStore || !render?.story)
|
|
2075
|
-
return;
|
|
2076
|
-
let { globals, storyGlobals, userGlobals, parameters } = storyStore.getStoryContext(
|
|
2077
|
-
render.story
|
|
2078
|
-
), viewportParameters = parameters[PARAM_KEY];
|
|
2079
|
-
return toResolvedViewportDimensions(
|
|
2080
|
-
resolveViewport({
|
|
2081
|
-
globals,
|
|
2082
|
-
storyGlobals,
|
|
2083
|
-
userGlobals,
|
|
2084
|
-
options: viewportParameters?.options ?? MINIMAL_VIEWPORTS,
|
|
2085
|
-
disable: viewportParameters?.disable ?? !1,
|
|
2086
|
-
viewMode: "story"
|
|
2087
|
-
}),
|
|
2088
|
-
reference
|
|
2089
|
-
);
|
|
2090
|
-
};
|
|
2062
|
+
// src/preview-api/modules/preview-web/InfiniteDocs.ts
|
|
2063
|
+
import { DOCS_PAGE_IN_VIEW } from "@aussieljk/forkbook/internal/core-events";
|
|
2091
2064
|
|
|
2092
2065
|
// src/preview-api/modules/preview-web/render/CsfDocsRender.ts
|
|
2093
2066
|
import { DOCS_RENDERED } from "@aussieljk/forkbook/internal/core-events";
|
|
@@ -2390,8 +2363,105 @@ var MdxDocsRender = class {
|
|
|
2390
2363
|
}
|
|
2391
2364
|
};
|
|
2392
2365
|
|
|
2393
|
-
// src/preview-api/modules/preview-web/
|
|
2394
|
-
|
|
2366
|
+
// src/preview-api/modules/preview-web/InfiniteDocs.ts
|
|
2367
|
+
var { document: document2, IntersectionObserver } = globalThis, docsEntriesInOrder = (entries) => {
|
|
2368
|
+
let docs = Object.values(entries).filter((entry) => entry.type === "docs"), isTopLevel = (entry) => !entry.title.includes("/");
|
|
2369
|
+
return [...docs.filter(isTopLevel), ...docs.filter((entry) => !isTopLevel(entry))];
|
|
2370
|
+
}, nextDocsEntry = (entries, id) => {
|
|
2371
|
+
let docs = docsEntriesInOrder(entries), index = docs.findIndex((entry) => entry.id === id);
|
|
2372
|
+
return index === -1 ? void 0 : docs[index + 1];
|
|
2373
|
+
}, InfiniteDocs = class {
|
|
2374
|
+
constructor(channel, store, renderStoryToElement, callbacks) {
|
|
2375
|
+
this.channel = channel;
|
|
2376
|
+
this.store = store;
|
|
2377
|
+
this.renderStoryToElement = renderStoryToElement;
|
|
2378
|
+
this.callbacks = callbacks;
|
|
2379
|
+
this.renders = [];
|
|
2380
|
+
this.loading = !1;
|
|
2381
|
+
}
|
|
2382
|
+
/** Starts after the main docs page `entry` rendered into `docsRoot`. */
|
|
2383
|
+
start(entry, docsRoot) {
|
|
2384
|
+
if (this.stop(), typeof IntersectionObserver > "u" || typeof document2 > "u" || !docsRoot?.dataset || this.store.projectAnnotations?.parameters?.docs?.infiniteScroll === !1)
|
|
2385
|
+
return;
|
|
2386
|
+
this.lastId = entry.id, this.inViewId = entry.id, docsRoot.dataset.docsId = entry.id;
|
|
2387
|
+
let container = document2.createElement("div");
|
|
2388
|
+
container.className = "fb-infinite-docs";
|
|
2389
|
+
let sentinel = document2.createElement("div");
|
|
2390
|
+
sentinel.className = "fb-infinite-docs-sentinel", sentinel.style.height = "1px", container.appendChild(sentinel), docsRoot.after(container), this.container = container, this.pageObserver = new IntersectionObserver(
|
|
2391
|
+
(records) => {
|
|
2392
|
+
for (let record of records) {
|
|
2393
|
+
let id = record.target.dataset.docsId;
|
|
2394
|
+
record.isIntersecting && id && id !== this.inViewId && (this.inViewId = id, this.channel.emit(DOCS_PAGE_IN_VIEW, { storyId: id }));
|
|
2395
|
+
}
|
|
2396
|
+
},
|
|
2397
|
+
{ rootMargin: "-10% 0px -60% 0px" }
|
|
2398
|
+
), this.pageObserver.observe(docsRoot), this.sentinelObserver = new IntersectionObserver(
|
|
2399
|
+
(records) => {
|
|
2400
|
+
records.some((record) => record.isIntersecting) && this.loadNext();
|
|
2401
|
+
},
|
|
2402
|
+
{ rootMargin: "0px 0px 600px 0px" }
|
|
2403
|
+
), this.sentinelObserver.observe(sentinel);
|
|
2404
|
+
}
|
|
2405
|
+
async loadNext() {
|
|
2406
|
+
let { container, lastId } = this;
|
|
2407
|
+
if (this.loading || !container || !lastId)
|
|
2408
|
+
return;
|
|
2409
|
+
let entry = nextDocsEntry(this.store.storyIndex.entries, lastId);
|
|
2410
|
+
if (!entry) {
|
|
2411
|
+
this.sentinelObserver?.disconnect();
|
|
2412
|
+
return;
|
|
2413
|
+
}
|
|
2414
|
+
this.loading = !0, this.lastId = entry.id;
|
|
2415
|
+
let element = document2.createElement("div");
|
|
2416
|
+
element.className = "fb-infinite-docs-page", element.dataset.docsId = entry.id, container.insertBefore(element, container.lastChild);
|
|
2417
|
+
let render = isMdxEntry(entry) ? new MdxDocsRender(this.channel, this.store, entry, this.callbacks(entry.id)) : new CsfDocsRender(this.channel, this.store, entry, this.callbacks(entry.id));
|
|
2418
|
+
this.renders.push(render);
|
|
2419
|
+
try {
|
|
2420
|
+
if (await render.prepare(), this.container !== container)
|
|
2421
|
+
return;
|
|
2422
|
+
await render.renderToElement(
|
|
2423
|
+
element,
|
|
2424
|
+
this.renderStoryToElement
|
|
2425
|
+
), this.pageObserver?.observe(element);
|
|
2426
|
+
} catch {
|
|
2427
|
+
this.sentinelObserver?.disconnect();
|
|
2428
|
+
} finally {
|
|
2429
|
+
this.loading = !1;
|
|
2430
|
+
}
|
|
2431
|
+
let sentinel = container.lastElementChild;
|
|
2432
|
+
sentinel && sentinel.getBoundingClientRect().top < globalThis.innerHeight + 600 && this.loadNext();
|
|
2433
|
+
}
|
|
2434
|
+
/** Removes the pages below the main page. */
|
|
2435
|
+
stop() {
|
|
2436
|
+
this.sentinelObserver?.disconnect(), this.pageObserver?.disconnect(), this.sentinelObserver = void 0, this.pageObserver = void 0;
|
|
2437
|
+
for (let render of this.renders)
|
|
2438
|
+
render.teardown({ viewModeChanged: !0 });
|
|
2439
|
+
this.renders = [], this.container?.remove(), this.container = void 0, this.lastId = void 0, this.inViewId = void 0, this.loading = !1;
|
|
2440
|
+
}
|
|
2441
|
+
};
|
|
2442
|
+
|
|
2443
|
+
// src/preview-api/modules/preview-web/embedMode.ts
|
|
2444
|
+
var shouldEmbed = ({ search }) => new URLSearchParams(search).get("embed") === "true", shouldAutoplay = ({ search }) => !shouldEmbed({ search });
|
|
2445
|
+
|
|
2446
|
+
// src/preview-api/modules/preview-web/getEmbedResizeViewport.ts
|
|
2447
|
+
var getEmbedResizeViewport = (storyStore, render, reference) => {
|
|
2448
|
+
if (!storyStore || !render?.story)
|
|
2449
|
+
return;
|
|
2450
|
+
let { globals, storyGlobals, userGlobals, parameters } = storyStore.getStoryContext(
|
|
2451
|
+
render.story
|
|
2452
|
+
), viewportParameters = parameters[PARAM_KEY];
|
|
2453
|
+
return toResolvedViewportDimensions(
|
|
2454
|
+
resolveViewport({
|
|
2455
|
+
globals,
|
|
2456
|
+
storyGlobals,
|
|
2457
|
+
userGlobals,
|
|
2458
|
+
options: viewportParameters?.options ?? MINIMAL_VIEWPORTS,
|
|
2459
|
+
disable: viewportParameters?.disable ?? !1,
|
|
2460
|
+
viewMode: "story"
|
|
2461
|
+
}),
|
|
2462
|
+
reference
|
|
2463
|
+
);
|
|
2464
|
+
};
|
|
2395
2465
|
|
|
2396
2466
|
// src/shared/constants/iframe-resize.ts
|
|
2397
2467
|
var IFRAME_RESIZE_CONTEXT = "iframe.resize", IFRAME_RESIZE_REQUEST_CONTEXT = "iframe.resize.request";
|
|
@@ -2402,7 +2472,6 @@ import {
|
|
|
2402
2472
|
STORY_HOT_UPDATED as STORY_HOT_UPDATED2,
|
|
2403
2473
|
STORY_RENDER_PHASE_CHANGED as STORY_RENDER_PHASE_CHANGED2
|
|
2404
2474
|
} from "@aussieljk/forkbook/internal/core-events";
|
|
2405
|
-
import { global as global5 } from "@storybook/global";
|
|
2406
2475
|
var FREEZE_STYLE_ID = "storybook-freeze-after-finished", PRE_FREEZE_STYLE_ID = "storybook-freeze-end-frame-preload", tryReplaceProperty = (target, key, value) => {
|
|
2407
2476
|
try {
|
|
2408
2477
|
let descriptor = Object.getOwnPropertyDescriptor(target, key);
|
|
@@ -2523,7 +2592,7 @@ var FREEZE_STYLE_ID = "storybook-freeze-after-finished", PRE_FREEZE_STYLE_ID = "
|
|
|
2523
2592
|
}
|
|
2524
2593
|
} };
|
|
2525
2594
|
}, setupStoryFreezer = (channel, options = {}) => {
|
|
2526
|
-
let windowRef =
|
|
2595
|
+
let windowRef = global.window, documentRef = global.document;
|
|
2527
2596
|
if (!windowRef || !documentRef || !shouldFreeze({ search: documentRef.location.search }))
|
|
2528
2597
|
return !1;
|
|
2529
2598
|
addPreFreezeStyles(documentRef);
|
|
@@ -2729,7 +2798,7 @@ var EMBED_STYLE_ID = "storybook-embed-sizing", EMBED_UI_STYLE_ID = "storybook-em
|
|
|
2729
2798
|
rafId !== null && (cancelAnimationFrame(rafId), rafId = null);
|
|
2730
2799
|
}, debounced;
|
|
2731
2800
|
}, setupContentResizeBroadcast = (options = {}) => {
|
|
2732
|
-
let { getViewport } = options, windowRef =
|
|
2801
|
+
let { getViewport } = options, windowRef = global.window, documentRef = global.document;
|
|
2733
2802
|
if (!windowRef || !documentRef)
|
|
2734
2803
|
return {};
|
|
2735
2804
|
if (!shouldEmbed({ search: documentRef.location.search }))
|
|
@@ -2914,7 +2983,9 @@ var PreviewWithSelection = class extends Preview {
|
|
|
2914
2983
|
let { selection } = this.selectionStore;
|
|
2915
2984
|
if (!selection)
|
|
2916
2985
|
throw new Error("Cannot call renderSelection as no selection was made");
|
|
2917
|
-
let { storyId } = selection
|
|
2986
|
+
let { storyId } = selection;
|
|
2987
|
+
this.infiniteDocs?.stop();
|
|
2988
|
+
let entry;
|
|
2918
2989
|
try {
|
|
2919
2990
|
entry = await this.storyStoreValue.storyIdToEntry(storyId);
|
|
2920
2991
|
} catch (err) {
|
|
@@ -3001,15 +3072,35 @@ var PreviewWithSelection = class extends Preview {
|
|
|
3001
3072
|
parameters
|
|
3002
3073
|
});
|
|
3003
3074
|
}
|
|
3004
|
-
|
|
3005
|
-
this.
|
|
3006
|
-
|
|
3007
|
-
|
|
3008
|
-
|
|
3009
|
-
|
|
3010
|
-
|
|
3011
|
-
this.
|
|
3012
|
-
|
|
3075
|
+
if (isStoryRender(render))
|
|
3076
|
+
invariant(!!render.story), this.storyRenders.push(render), this.currentRender.renderToElement(
|
|
3077
|
+
this.view.prepareForStory(render.story, {
|
|
3078
|
+
scrollReset: storyIdChanged || viewModeChanged
|
|
3079
|
+
})
|
|
3080
|
+
);
|
|
3081
|
+
else {
|
|
3082
|
+
let docsRoot = this.view.prepareForDocs({ scrollReset: storyIdChanged || viewModeChanged }), docsRender = this.currentRender;
|
|
3083
|
+
docsRender.renderToElement(
|
|
3084
|
+
docsRoot,
|
|
3085
|
+
// This argument is used for docs, which is currently only compatible with HTMLElements
|
|
3086
|
+
this.renderStoryToElement.bind(this)
|
|
3087
|
+
).then(() => {
|
|
3088
|
+
this.currentRender === docsRender && this.storyStoreValue && (this.infiniteDocs ??= new InfiniteDocs(
|
|
3089
|
+
this.channel,
|
|
3090
|
+
this.storyStoreValue,
|
|
3091
|
+
this.renderStoryToElement.bind(this),
|
|
3092
|
+
() => ({
|
|
3093
|
+
showStoryDuringRender: () => {
|
|
3094
|
+
},
|
|
3095
|
+
showMain: () => {
|
|
3096
|
+
},
|
|
3097
|
+
showError: () => {
|
|
3098
|
+
},
|
|
3099
|
+
showException: (err) => logger5.error(err)
|
|
3100
|
+
})
|
|
3101
|
+
), this.infiniteDocs.start(entry, docsRoot));
|
|
3102
|
+
});
|
|
3103
|
+
}
|
|
3013
3104
|
}
|
|
3014
3105
|
async teardownRender(render, {
|
|
3015
3106
|
viewModeChanged = !1,
|
|
@@ -3048,9 +3139,6 @@ var PreviewWithSelection = class extends Preview {
|
|
|
3048
3139
|
}
|
|
3049
3140
|
};
|
|
3050
3141
|
|
|
3051
|
-
// src/preview-api/modules/preview-web/UrlStore.ts
|
|
3052
|
-
import { global as global7 } from "@storybook/global";
|
|
3053
|
-
|
|
3054
3142
|
// src/preview-api/modules/preview-web/parseArgsParam.ts
|
|
3055
3143
|
import { once as once2 } from "@aussieljk/forkbook/internal/client-logger";
|
|
3056
3144
|
import { dedent as dedent4 } from "ts-dedent";
|
|
@@ -3092,7 +3180,7 @@ var VALIDATION_REGEXP = /^[a-zA-Z0-9 _-]*$/, NUMBER_REGEXP = /^-?[0-9]+(\.[0-9]+
|
|
|
3092
3180
|
};
|
|
3093
3181
|
|
|
3094
3182
|
// src/preview-api/modules/preview-web/UrlStore.ts
|
|
3095
|
-
var { history, document:
|
|
3183
|
+
var { history, document: document3 } = global, PATH_REGEX = /^\/(story|docs)\/(.+)/;
|
|
3096
3184
|
function pathToId(path) {
|
|
3097
3185
|
let match = (path || "").match(PATH_REGEX);
|
|
3098
3186
|
if (!match)
|
|
@@ -3106,7 +3194,7 @@ var getQueryString = ({
|
|
|
3106
3194
|
selection,
|
|
3107
3195
|
extraParams
|
|
3108
3196
|
}) => {
|
|
3109
|
-
let search =
|
|
3197
|
+
let search = document3?.location.search.slice(1), { path, selectedKind, selectedStory, ...rest } = parse(search);
|
|
3110
3198
|
return `?${stringify({
|
|
3111
3199
|
...rest,
|
|
3112
3200
|
...extraParams,
|
|
@@ -3115,8 +3203,8 @@ var getQueryString = ({
|
|
|
3115
3203
|
}, setPath = (selection) => {
|
|
3116
3204
|
if (!selection)
|
|
3117
3205
|
return;
|
|
3118
|
-
let query = getQueryString({ selection }), { hash = "" } =
|
|
3119
|
-
|
|
3206
|
+
let query = getQueryString({ selection }), { hash = "" } = document3.location;
|
|
3207
|
+
document3.title = selection.storyId, history.replaceState({}, "", `${document3.location.pathname}${query}${hash}`);
|
|
3120
3208
|
}, isObject = (val) => val != null && typeof val == "object" && Array.isArray(val) === !1, getFirstString = (v) => {
|
|
3121
3209
|
if (v !== void 0) {
|
|
3122
3210
|
if (typeof v == "string")
|
|
@@ -3129,8 +3217,8 @@ var getQueryString = ({
|
|
|
3129
3217
|
);
|
|
3130
3218
|
}
|
|
3131
3219
|
}, getSelectionSpecifierFromPath = () => {
|
|
3132
|
-
if (typeof
|
|
3133
|
-
let queryStr =
|
|
3220
|
+
if (typeof document3 < "u") {
|
|
3221
|
+
let queryStr = document3.location.search.slice(1), query = parse(queryStr), args = typeof query.args == "string" ? parseArgsParam(query.args) : void 0, globals = typeof query.globals == "string" ? parseArgsParam(query.globals) : void 0, path = getFirstString(query.path), viewMode = getFirstString(query.viewMode);
|
|
3134
3222
|
if (typeof viewMode != "string" || !viewMode)
|
|
3135
3223
|
viewMode = path && pathToViewMode(path) || "story";
|
|
3136
3224
|
else if (!viewMode.match(/docs|story/))
|
|
@@ -3148,17 +3236,16 @@ var getQueryString = ({
|
|
|
3148
3236
|
this.selection = selection, setPath(this.selection);
|
|
3149
3237
|
}
|
|
3150
3238
|
setQueryParams(queryParams) {
|
|
3151
|
-
let query = getQueryString({ extraParams: queryParams }), { hash = "" } =
|
|
3152
|
-
history.replaceState({}, "", `${
|
|
3239
|
+
let query = getQueryString({ extraParams: queryParams }), { hash = "" } = document3.location;
|
|
3240
|
+
history.replaceState({}, "", `${document3.location.pathname}${query}${hash}`);
|
|
3153
3241
|
}
|
|
3154
3242
|
};
|
|
3155
3243
|
|
|
3156
3244
|
// src/preview-api/modules/preview-web/WebView.ts
|
|
3157
|
-
var import_ansi_to_html = __toESM(require_ansi_to_html(), 1);
|
|
3158
3245
|
import { logger as logger6 } from "@aussieljk/forkbook/internal/client-logger";
|
|
3159
|
-
|
|
3246
|
+
var import_ansi_to_html = __toESM(require_ansi_to_html(), 1);
|
|
3160
3247
|
import { dedent as dedent5 } from "ts-dedent";
|
|
3161
|
-
var { document:
|
|
3248
|
+
var { document: document4 } = global, PREPARING_DELAY = 100, Mode = /* @__PURE__ */ ((Mode2) => (Mode2.MAIN = "MAIN", Mode2.NOPREVIEW = "NOPREVIEW", Mode2.PREPARING_STORY = "PREPARING_STORY", Mode2.PREPARING_DOCS = "PREPARING_DOCS", Mode2.ERROR = "ERROR", Mode2))(Mode || {}), classes = {
|
|
3162
3249
|
PREPARING_STORY: "fb-show-preparing-story",
|
|
3163
3250
|
PREPARING_DOCS: "fb-show-preparing-docs",
|
|
3164
3251
|
MAIN: "fb-show-main",
|
|
@@ -3173,8 +3260,8 @@ var { document: document3 } = global8, PREPARING_DELAY = 100, Mode = /* @__PURE_
|
|
|
3173
3260
|
}), WebView = class {
|
|
3174
3261
|
constructor() {
|
|
3175
3262
|
this.testing = !1;
|
|
3176
|
-
if (typeof
|
|
3177
|
-
let { __SPECIAL_TEST_PARAMETER__ } = parse(
|
|
3263
|
+
if (typeof document4 < "u") {
|
|
3264
|
+
let { __SPECIAL_TEST_PARAMETER__ } = parse(document4.location.search.slice(1));
|
|
3178
3265
|
switch (__SPECIAL_TEST_PARAMETER__) {
|
|
3179
3266
|
case "preparing-story": {
|
|
3180
3267
|
this.showPreparingStory(), this.testing = !0;
|
|
@@ -3190,30 +3277,30 @@ var { document: document3 } = global8, PREPARING_DELAY = 100, Mode = /* @__PURE_
|
|
|
3190
3277
|
}
|
|
3191
3278
|
// Get ready to render a story, returning the element to render to
|
|
3192
3279
|
prepareForStory(story, { scrollReset = !0 } = {}) {
|
|
3193
|
-
this.showStory(), this.applyLayout(story.parameters.layout), scrollReset && (
|
|
3280
|
+
this.showStory(), this.applyLayout(story.parameters.layout), scrollReset && (document4.documentElement.scrollTop = 0, document4.documentElement.scrollLeft = 0);
|
|
3194
3281
|
let storyRoot = this.storyRoot();
|
|
3195
3282
|
return this.applyHtmlLang(storyRoot, story.parameters.htmlLang), storyRoot;
|
|
3196
3283
|
}
|
|
3197
3284
|
storyRoot() {
|
|
3198
|
-
return
|
|
3285
|
+
return document4.getElementById("storybook-root");
|
|
3199
3286
|
}
|
|
3200
3287
|
prepareForDocs({ scrollReset = !0 } = {}) {
|
|
3201
|
-
return this.showMain(), this.showDocs(), this.applyLayout("fullscreen"), scrollReset && (
|
|
3288
|
+
return this.showMain(), this.showDocs(), this.applyLayout("fullscreen"), scrollReset && (document4.documentElement.scrollTop = 0, document4.documentElement.scrollLeft = 0), this.docsRoot();
|
|
3202
3289
|
}
|
|
3203
3290
|
docsRoot() {
|
|
3204
|
-
return
|
|
3291
|
+
return document4.getElementById("storybook-docs");
|
|
3205
3292
|
}
|
|
3206
3293
|
scrollToAnchor(hash) {
|
|
3207
|
-
|
|
3294
|
+
document4.getElementById(decodeURIComponent(hash.substring(1)))?.scrollIntoView({ behavior: "smooth" });
|
|
3208
3295
|
}
|
|
3209
3296
|
applyLayout(layout = "padded") {
|
|
3210
3297
|
if (layout === "none") {
|
|
3211
|
-
|
|
3298
|
+
document4.body.classList.remove(this.currentLayoutClass), this.currentLayoutClass = null;
|
|
3212
3299
|
return;
|
|
3213
3300
|
}
|
|
3214
3301
|
this.checkIfLayoutExists(layout);
|
|
3215
3302
|
let layoutClass = layoutClassMap[layout];
|
|
3216
|
-
|
|
3303
|
+
document4.body.classList.remove(this.currentLayoutClass), document4.body.classList.add(layoutClass), this.currentLayoutClass = layoutClass;
|
|
3217
3304
|
}
|
|
3218
3305
|
/**
|
|
3219
3306
|
* Injects a BCP-47 lang attribute to the story root, or removes it if `lang` is null.
|
|
@@ -3231,14 +3318,14 @@ var { document: document3 } = global8, PREPARING_DELAY = 100, Mode = /* @__PURE_
|
|
|
3231
3318
|
}
|
|
3232
3319
|
showMode(mode) {
|
|
3233
3320
|
clearTimeout(this.preparingTimeout), Object.keys(Mode).forEach((otherMode) => {
|
|
3234
|
-
otherMode === mode ?
|
|
3321
|
+
otherMode === mode ? document4.body.classList.add(classes[otherMode]) : document4.body.classList.remove(classes[otherMode]);
|
|
3235
3322
|
});
|
|
3236
3323
|
}
|
|
3237
3324
|
showErrorDisplay({ message = "", stack = "" }) {
|
|
3238
3325
|
let header = message, detail = stack, parts = message.split(`
|
|
3239
3326
|
`);
|
|
3240
3327
|
parts.length > 1 && ([header] = parts, detail = parts.slice(1).join(`
|
|
3241
|
-
`).replace(/^\n/, "")),
|
|
3328
|
+
`).replace(/^\n/, "")), document4.getElementById("error-message").innerHTML = ansiConverter.toHtml(header), document4.getElementById("error-stack").innerHTML = ansiConverter.toHtml(detail), this.showMode("ERROR" /* ERROR */);
|
|
3242
3329
|
}
|
|
3243
3330
|
showNoPreview() {
|
|
3244
3331
|
this.testing || (this.showMode("NOPREVIEW" /* NOPREVIEW */), this.storyRoot()?.setAttribute("hidden", "true"), this.docsRoot()?.setAttribute("hidden", "true"));
|
|
@@ -3262,7 +3349,7 @@ var { document: document3 } = global8, PREPARING_DELAY = 100, Mode = /* @__PURE_
|
|
|
3262
3349
|
this.docsRoot().setAttribute("hidden", "true"), this.storyRoot().removeAttribute("hidden");
|
|
3263
3350
|
}
|
|
3264
3351
|
showStoryDuringRender() {
|
|
3265
|
-
|
|
3352
|
+
document4.body.classList.add(classes.MAIN);
|
|
3266
3353
|
}
|
|
3267
3354
|
};
|
|
3268
3355
|
|
|
@@ -3272,13 +3359,12 @@ var PreviewWeb = class extends PreviewWithSelection {
|
|
|
3272
3359
|
super(importFn, getProjectAnnotations, new UrlStore(), new WebView());
|
|
3273
3360
|
this.importFn = importFn;
|
|
3274
3361
|
this.getProjectAnnotations = getProjectAnnotations;
|
|
3275
|
-
|
|
3362
|
+
global.__FORKBOOK_PREVIEW__ = this;
|
|
3276
3363
|
}
|
|
3277
3364
|
};
|
|
3278
3365
|
|
|
3279
3366
|
// src/preview-api/modules/preview-web/simulate-pageload.ts
|
|
3280
|
-
|
|
3281
|
-
var { document: document4 } = global10, runScriptTypes = [
|
|
3367
|
+
var { document: document5 } = global, runScriptTypes = [
|
|
3282
3368
|
"application/javascript",
|
|
3283
3369
|
"application/ecmascript",
|
|
3284
3370
|
"application/x-ecmascript",
|
|
@@ -3299,12 +3385,12 @@ var { document: document4 } = global10, runScriptTypes = [
|
|
|
3299
3385
|
"module"
|
|
3300
3386
|
], SCRIPT = "script", SCRIPTS_ROOT_ID = "scripts-root";
|
|
3301
3387
|
function simulateDOMContentLoaded() {
|
|
3302
|
-
let DOMContentLoadedEvent =
|
|
3303
|
-
DOMContentLoadedEvent.initEvent("DOMContentLoaded", !0, !0),
|
|
3388
|
+
let DOMContentLoadedEvent = document5.createEvent("Event");
|
|
3389
|
+
DOMContentLoadedEvent.initEvent("DOMContentLoaded", !0, !0), document5.dispatchEvent(DOMContentLoadedEvent);
|
|
3304
3390
|
}
|
|
3305
3391
|
function insertScript($script, callback, $scriptRoot) {
|
|
3306
|
-
let scriptEl =
|
|
3307
|
-
scriptEl.type = $script.type === "module" ? "module" : "text/javascript", $script.src ? (scriptEl.onload = callback, scriptEl.onerror = callback, scriptEl.src = $script.src) : scriptEl.textContent = $script.innerText, $scriptRoot ? $scriptRoot.appendChild(scriptEl) :
|
|
3392
|
+
let scriptEl = document5.createElement("script");
|
|
3393
|
+
scriptEl.type = $script.type === "module" ? "module" : "text/javascript", $script.src ? (scriptEl.onload = callback, scriptEl.onerror = callback, scriptEl.src = $script.src) : scriptEl.textContent = $script.innerText, $scriptRoot ? $scriptRoot.appendChild(scriptEl) : document5.head.appendChild(scriptEl), $script.parentNode.removeChild($script), $script.src || callback();
|
|
3308
3394
|
}
|
|
3309
3395
|
function insertScriptsSequentially(scriptsToExecute, callback, index = 0) {
|
|
3310
3396
|
scriptsToExecute[index](() => {
|
|
@@ -3312,8 +3398,8 @@ function insertScriptsSequentially(scriptsToExecute, callback, index = 0) {
|
|
|
3312
3398
|
});
|
|
3313
3399
|
}
|
|
3314
3400
|
function simulatePageLoad($container) {
|
|
3315
|
-
let $scriptsRoot =
|
|
3316
|
-
$scriptsRoot ? $scriptsRoot.innerHTML = "" : ($scriptsRoot =
|
|
3401
|
+
let $scriptsRoot = document5.getElementById(SCRIPTS_ROOT_ID);
|
|
3402
|
+
$scriptsRoot ? $scriptsRoot.innerHTML = "" : ($scriptsRoot = document5.createElement("div"), $scriptsRoot.id = SCRIPTS_ROOT_ID, document5.body.appendChild($scriptsRoot));
|
|
3317
3403
|
let $scripts = Array.from($container.querySelectorAll(SCRIPT));
|
|
3318
3404
|
if ($scripts.length) {
|
|
3319
3405
|
let scriptsToExecute = [];
|
|
@@ -3,6 +3,9 @@ import {
|
|
|
3
3
|
curriedLighten$1,
|
|
4
4
|
rgba
|
|
5
5
|
} from "./chunk-S6TK43XQ.js";
|
|
6
|
+
import {
|
|
7
|
+
global
|
|
8
|
+
} from "./chunk-6AKCRYVX.js";
|
|
6
9
|
|
|
7
10
|
// src/theming/base.ts
|
|
8
11
|
var easing = {
|
|
@@ -67,7 +70,7 @@ var easing = {
|
|
|
67
70
|
content: color.lightest,
|
|
68
71
|
preview: color.lightest,
|
|
69
72
|
gridCellSize: 10,
|
|
70
|
-
hoverable: "#
|
|
73
|
+
hoverable: "#E5E5EA",
|
|
71
74
|
// Notification, error, and warning backgrounds
|
|
72
75
|
positive: "#EAF9EE",
|
|
73
76
|
warning: "#FFF4E5",
|
|
@@ -199,7 +202,7 @@ var border = "rgba(84, 84, 88, 0.6)", theme = {
|
|
|
199
202
|
appBg: "#000000",
|
|
200
203
|
appContentBg: "#1C1C1E",
|
|
201
204
|
// systemGray6
|
|
202
|
-
appHoverBg: "#
|
|
205
|
+
appHoverBg: "#2C2C2E",
|
|
203
206
|
appPreviewBg: color.lightest,
|
|
204
207
|
appBorderColor: border,
|
|
205
208
|
appBorderRadius: 4,
|
|
@@ -212,7 +215,7 @@ var border = "rgba(84, 84, 88, 0.6)", theme = {
|
|
|
212
215
|
textMutedColor: "#98989F",
|
|
213
216
|
// Toolbar default and active colors
|
|
214
217
|
barTextColor: "#98989F",
|
|
215
|
-
barHoverColor: "#
|
|
218
|
+
barHoverColor: "#F2F2F7",
|
|
216
219
|
barSelectedColor: "#0A84FF",
|
|
217
220
|
barBg: "#1C1C1E",
|
|
218
221
|
// Form colors
|
|
@@ -250,7 +253,7 @@ var theme2 = {
|
|
|
250
253
|
textMutedColor: color.dark,
|
|
251
254
|
// Toolbar default and active colors
|
|
252
255
|
barTextColor: color.dark,
|
|
253
|
-
barHoverColor:
|
|
256
|
+
barHoverColor: color.darkest,
|
|
254
257
|
barSelectedColor: color.secondary,
|
|
255
258
|
barBg: color.lightest,
|
|
256
259
|
// Form colors
|
|
@@ -266,7 +269,6 @@ var theme2 = {
|
|
|
266
269
|
|
|
267
270
|
// src/theming/utils.ts
|
|
268
271
|
import { logger } from "@aussieljk/forkbook/internal/client-logger";
|
|
269
|
-
import { global } from "@storybook/global";
|
|
270
272
|
var { window: globalWindow } = global;
|
|
271
273
|
var isColorString = (color2) => typeof color2 != "string" ? (logger.warn(
|
|
272
274
|
`Color passed to theme object should be a string. Instead ${color2}(${typeof color2}) was passed.`
|