@aussieljk/forkbook 0.0.1-14 → 0.0.1-15
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/dist/_browser-chunks/{Color-SRJLV635.js → Color-OSKHEBLS.js} +1 -1
- package/dist/_browser-chunks/{WithTooltip-66AWY4VQ.js → WithTooltip-IPJFQHVQ.js} +1 -1
- package/dist/_browser-chunks/chunk-4ZGQ4YQ2.js +20 -0
- package/dist/_browser-chunks/{chunk-TISSQK65.js → chunk-74S4GA34.js} +1 -1
- package/dist/_browser-chunks/{chunk-S7N7Z5TY.js → chunk-TRXLBGLS.js} +21 -2
- package/dist/_browser-chunks/{chunk-J4UZWNQC.js → chunk-XRILAR4S.js} +11 -11
- package/dist/_node-chunks/{attached-runtime-6PIRX7CQ.js → attached-runtime-5ABH72AY.js} +28 -28
- package/dist/_node-chunks/{builder-manager-V5HY2EIW.js → builder-manager-4T5FVGUR.js} +18 -15
- package/dist/_node-chunks/{chunk-USLPZFTU.js → chunk-2FWG2MQN.js} +6 -6
- package/dist/_node-chunks/chunk-2YVNFDPN.js +18 -0
- package/dist/_node-chunks/{chunk-IWNGZZOH.js → chunk-33IC7FUB.js} +9 -9
- package/dist/_node-chunks/{chunk-HIUJFVVI.js → chunk-46E6YIPW.js} +7 -7
- package/dist/_node-chunks/{chunk-NRYRRB6R.js → chunk-4BWBFTBZ.js} +7 -7
- package/dist/_node-chunks/{chunk-475RIYQK.js → chunk-4ELXERU6.js} +6 -6
- package/dist/_node-chunks/{chunk-YAASP4OM.js → chunk-4GGXQOD4.js} +8 -8
- package/dist/_node-chunks/{chunk-DBZ3MV24.js → chunk-4ISTQSCO.js} +19 -7
- package/dist/_node-chunks/{chunk-ZDMZKYDQ.js → chunk-4XKLH4I3.js} +6 -6
- package/dist/_node-chunks/{chunk-DMIUL52J.js → chunk-56L6SVSQ.js} +6 -6
- package/dist/_node-chunks/{chunk-4IMBYVSQ.js → chunk-5NWCUFPU.js} +6 -6
- package/dist/_node-chunks/{chunk-6BYFV3Q7.js → chunk-5Y53QRNN.js} +6 -6
- package/dist/_node-chunks/{chunk-UZRRWBTM.js → chunk-6DHYHTHM.js} +8 -8
- package/dist/_node-chunks/{chunk-XOHD6XOU.js → chunk-6H3FQSQV.js} +52 -22
- package/dist/_node-chunks/{chunk-H7BW4AVF.js → chunk-6WHTGFDB.js} +6 -6
- package/dist/_node-chunks/{chunk-ESF43LCU.js → chunk-767UK7PX.js} +9 -9
- package/dist/_node-chunks/{chunk-K3M6GTPC.js → chunk-7IYNKFXW.js} +10 -10
- package/dist/_node-chunks/{chunk-DDKUSQFU.js → chunk-7LYHZMJO.js} +6 -6
- package/dist/_node-chunks/{chunk-KE27G2SG.js → chunk-7RE5WNOM.js} +7 -7
- package/dist/_node-chunks/{chunk-AYCHV6XS.js → chunk-A3EPCOVV.js} +7 -7
- package/dist/_node-chunks/chunk-AK4RPNTY.js +137 -0
- package/dist/_node-chunks/{chunk-H7OP7USW.js → chunk-AUUVNECB.js} +7 -7
- package/dist/_node-chunks/{chunk-AWQ6IMN5.js → chunk-B6JJQARD.js} +9 -9
- package/dist/_node-chunks/chunk-BVF25DJF.js +20 -0
- package/dist/_node-chunks/{chunk-CM4ALPXN.js → chunk-DASUWWHV.js} +6 -6
- package/dist/_node-chunks/{chunk-G7CEHU7W.js → chunk-DJPS7LWH.js} +7 -7
- package/dist/_node-chunks/{chunk-7F55FT5N.js → chunk-DTFPS5QE.js} +7 -7
- package/dist/_node-chunks/{chunk-TR5RJPQV.js → chunk-EHPAFXPB.js} +8 -8
- package/dist/_node-chunks/{chunk-XXQUU56M.js → chunk-FFE4YDDE.js} +9 -9
- package/dist/_node-chunks/{chunk-DLQVZMTD.js → chunk-FJE2XPLI.js} +6 -6
- package/dist/_node-chunks/{chunk-6C6EDUW3.js → chunk-FSSOM72N.js} +14 -14
- package/dist/_node-chunks/{chunk-PU4TVXCV.js → chunk-FVHSCRCK.js} +7 -7
- package/dist/_node-chunks/{chunk-2WWD7IJS.js → chunk-G6M5USWY.js} +8 -8
- package/dist/_node-chunks/{chunk-WWGYV7QI.js → chunk-G7NZ27DS.js} +7 -7
- package/dist/_node-chunks/{chunk-XAK4JWKF.js → chunk-GRJPH3NW.js} +8 -8
- package/dist/_node-chunks/{chunk-56Y4ZIQS.js → chunk-H4IDYTC4.js} +7 -7
- package/dist/_node-chunks/{chunk-PB5OW47R.js → chunk-H5AAYJZE.js} +8 -8
- package/dist/_node-chunks/{chunk-KO7CKNTP.js → chunk-HK47D3O3.js} +7 -7
- package/dist/_node-chunks/{chunk-5VLJNYCG.js → chunk-J2ZTT2OP.js} +33 -23
- package/dist/_node-chunks/{chunk-2DGZADP4.js → chunk-JAPFAHXG.js} +6 -6
- package/dist/_node-chunks/{chunk-OZM2N3ZY.js → chunk-JC4I7ZVM.js} +7 -7
- package/dist/_node-chunks/{chunk-YUZDQTG3.js → chunk-JCQU3LND.js} +7 -7
- package/dist/_node-chunks/{chunk-OGF5O46G.js → chunk-JQKD337A.js} +6 -6
- package/dist/_node-chunks/{chunk-QP5A3OYV.js → chunk-JYQSJLIK.js} +8 -8
- package/dist/_node-chunks/{chunk-4IRW4KVR.js → chunk-KFZRX33G.js} +8 -8
- package/dist/_node-chunks/{chunk-QVEPLFS4.js → chunk-KIAQML4H.js} +8 -8
- package/dist/_node-chunks/{chunk-YHXP7DMA.js → chunk-LHRQTTE7.js} +8 -8
- package/dist/_node-chunks/{chunk-JBQXQVOG.js → chunk-LNMVMXBN.js} +7 -7
- package/dist/_node-chunks/chunk-M6LN66WA.js +20 -0
- package/dist/_node-chunks/{chunk-DQHAJZYL.js → chunk-M75NG64K.js} +7 -7
- package/dist/_node-chunks/{chunk-4MFP6QG3.js → chunk-MBTS4OBP.js} +6 -6
- package/dist/_node-chunks/chunk-MBTTUFUX.js +11 -0
- package/dist/_node-chunks/{chunk-5A53X2WP.js → chunk-MLJPAH4O.js} +6 -6
- package/dist/_node-chunks/{chunk-T3SCXAMA.js → chunk-NGFVR7UO.js} +6 -6
- package/dist/_node-chunks/{chunk-IXZUAPGY.js → chunk-ONKMPF4O.js} +6 -6
- package/dist/_node-chunks/{chunk-CCJIZTUJ.js → chunk-OS6P62RS.js} +6 -6
- package/dist/_node-chunks/{chunk-PXN2IFPG.js → chunk-QAQWINPN.js} +7 -7
- package/dist/_node-chunks/{chunk-4RBPVBKC.js → chunk-QF4WUMRT.js} +10 -10
- package/dist/_node-chunks/{chunk-3MBZZMYZ.js → chunk-QF5RQWCH.js} +6 -6
- package/dist/_node-chunks/{chunk-TH6GIF3K.js → chunk-QZR6HJVD.js} +7 -7
- package/dist/_node-chunks/chunk-R5H4DAON.js +19 -0
- package/dist/_node-chunks/{chunk-LXLNUUFW.js → chunk-RENIT4CI.js} +6 -6
- package/dist/_node-chunks/{chunk-QTB7G4LF.js → chunk-SJVTZ4IO.js} +23 -23
- package/dist/_node-chunks/{chunk-5OVUKRFB.js → chunk-SL53Q3H4.js} +6 -6
- package/dist/_node-chunks/{chunk-CXSBVV4J.js → chunk-T34DVPWM.js} +6 -6
- package/dist/_node-chunks/{chunk-S2IX32KL.js → chunk-TVDV6YAE.js} +8 -8
- package/dist/_node-chunks/{chunk-CEBBAWIT.js → chunk-U6T34IDM.js} +6 -6
- package/dist/_node-chunks/{chunk-LGMNVTJZ.js → chunk-UAU6RMOS.js} +19 -19
- package/dist/_node-chunks/{chunk-3MBTHKMD.js → chunk-UMWJISED.js} +6 -6
- package/dist/_node-chunks/{chunk-Q7ADULRW.js → chunk-UO3EXKJC.js} +6 -6
- package/dist/_node-chunks/{chunk-ST7CLK7N.js → chunk-VCKRLODV.js} +8 -8
- package/dist/_node-chunks/{chunk-DYHMJVLZ.js → chunk-VS4AUXP2.js} +6 -6
- package/dist/_node-chunks/{chunk-MACS5P6Q.js → chunk-VUHK6VXL.js} +12 -12
- package/dist/_node-chunks/{chunk-EYZMI5JO.js → chunk-VUP4EHUR.js} +8 -8
- package/dist/_node-chunks/{chunk-IY3BJJVM.js → chunk-VXDKI65K.js} +26 -26
- package/dist/_node-chunks/{chunk-QGJV32VT.js → chunk-W32FBKF3.js} +10 -10
- package/dist/_node-chunks/{chunk-RH4PXLHE.js → chunk-W6AOA2O5.js} +7 -7
- package/dist/_node-chunks/{chunk-FMXUZSLI.js → chunk-W7352H3Q.js} +6 -6
- package/dist/_node-chunks/{chunk-VHSRKW3N.js → chunk-WMUNVUVG.js} +6 -6
- package/dist/_node-chunks/{chunk-UWM37IXC.js → chunk-WTZ24FWN.js} +8 -8
- package/dist/_node-chunks/{chunk-YMF2ZP77.js → chunk-X3BAGYZJ.js} +8 -8
- package/dist/_node-chunks/{chunk-FDWORQWO.js → chunk-XERNMHVC.js} +6 -6
- package/dist/_node-chunks/chunk-XU6HITGZ.js +25 -0
- package/dist/_node-chunks/chunk-XV76A4CX.js +47 -0
- package/dist/_node-chunks/{chunk-HXFN2M2F.js → chunk-XWHHBYMV.js} +6 -6
- package/dist/_node-chunks/{chunk-WDSTXRQP.js → chunk-Y3FJT543.js} +7 -7
- package/dist/_node-chunks/{chunk-LBAKDZV6.js → chunk-YHYL4HYS.js} +6 -6
- package/dist/_node-chunks/{chunk-CH5FN27Z.js → chunk-ZNT3JZI2.js} +7 -7
- package/dist/_node-chunks/{chunk-NZ2SSNU7.js → chunk-ZPWEQZYR.js} +7 -7
- package/dist/_node-chunks/{chunk-PTMZZHGA.js → chunk-ZSTCVYOA.js} +6 -6
- package/dist/_node-chunks/dist-2H6YEUMD.js +16 -0
- package/dist/_node-chunks/dist-HL4THRGZ.js +27 -0
- package/dist/_node-chunks/{local-runtime-2DFMXO2N.js → local-runtime-W3N7O65Q.js} +19 -19
- package/dist/_node-chunks/{mdx-plugin-FEC4UKBF.js → mdx-plugin-NVSAW2N3.js} +13 -13
- package/dist/_node-chunks/{monorepo-TRTFPD3M.js → monorepo-JDWM46J3.js} +11 -11
- package/dist/_node-chunks/{monorepo-optimized-tests-relaxed-limits-no-story-deletion-D3VPQGCI.js → monorepo-optimized-tests-relaxed-limits-no-story-deletion-56HEREMG.js} +11 -11
- package/dist/_node-chunks/optimized-tests-VZGTWCG4.js +22 -0
- package/dist/_node-chunks/{pattern-copy-play-ZUQ2ZQ7T.js → pattern-copy-play-ZWHYXQK5.js} +9 -9
- package/dist/_node-chunks/postinstallAddon-5TRUTJXJ.js +20 -0
- package/dist/_node-chunks/{rehype-external-links-MEOVNWZI.js → rehype-external-links-ME2XNDXH.js} +9 -9
- package/dist/_node-chunks/{rehype-slug-RRLOM7B4.js → rehype-slug-2UJLYPC6.js} +9 -9
- package/dist/_node-chunks/{relaxed-limits-RGYTFJP3.js → relaxed-limits-XWE3S456.js} +11 -11
- package/dist/_node-chunks/{run-FRTM74WS.js → run-5YG73LXV.js} +17 -17
- package/dist/_node-chunks/{run-YVMIX6AJ.js → run-DNDPGCFE.js} +15 -15
- package/dist/_node-chunks/{setup-4TBDLNSA.js → setup-MDNSLQIJ.js} +8 -8
- package/dist/_node-chunks/{vitest.config.4.template-GCYBLHAD.js → vitest.config.4.template-TXAUMPSS.js} +7 -7
- package/dist/addon-a11y/manager.js +4 -4
- package/dist/addon-a11y/preset.js +7 -7
- package/dist/addon-comments/manager.js +346 -0
- package/dist/addon-comments/preset.js +52 -0
- package/dist/addon-comments/preview.js +101 -0
- package/dist/addon-docs/blocks.js +10 -10
- package/dist/addon-docs/manager.js +1 -1
- package/dist/addon-docs/preset.js +10 -10
- package/dist/addon-links/preview.d.ts +1 -1
- package/dist/addon-mcp/preset.js +138 -38
- package/dist/addon-mcp/tools/preview-stories/preview-stories-app-script.js +13 -1
- package/dist/addon-themes/postinstall.js +7 -7
- package/dist/addon-vitest/constants.js +8 -8
- package/dist/addon-vitest/manager.js +3 -3
- 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 +14 -14
- package/dist/addon-vitest/vitest-plugin/global-setup.js +7 -7
- package/dist/addon-vitest/vitest-plugin/index.js +12 -12
- package/dist/babel/index.js +11 -11
- package/dist/bin/core.js +56 -56
- package/dist/bin/dispatcher.js +10 -10
- package/dist/bin/loader.js +8 -8
- package/dist/builder-vite/index.js +15 -15
- package/dist/builder-vite/preset.js +13 -13
- package/dist/channels/index.d.ts +2 -2
- package/dist/channels/index.js +68 -17
- package/dist/{chunk-BCG2ui5q.d.ts → chunk-BRMwIGWt.d.ts} +14 -3
- package/dist/{chunk-LWwxlbee.d.ts → chunk-C4-cnJ1R.d.ts} +1 -1
- package/dist/{chunk-u_gGuTrz.d.ts → chunk-QtkUsZCs.d.ts} +27 -2
- package/dist/{chunk-BV_hETtB.d.ts → chunk-s5Ka0eSs.d.ts} +1 -1
- package/dist/cli/index.d.ts +1 -1
- package/dist/cli/index.js +21 -21
- 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 +2 -2
- package/dist/cli/tools/sdk/index.js +18 -18
- package/dist/cli-commands/bin/index.js +7 -7
- package/dist/common/index.d.ts +3 -3
- package/dist/common/index.js +34 -34
- package/dist/components/index.js +29 -29
- package/dist/core-events/index.d.ts +3 -2
- package/dist/core-events/index.js +3 -1
- package/dist/core-server/index.d.ts +23 -3
- package/dist/core-server/index.js +206 -103
- package/dist/core-server/presets/common-manager.js +17 -9
- package/dist/core-server/presets/common-override-preset.js +10 -10
- package/dist/core-server/presets/common-preset.js +38 -38
- package/dist/create/bin/index.js +7 -7
- package/dist/create/index.js +15 -15
- package/dist/csf/index.js +1 -1
- package/dist/csf-tools/index.js +12 -12
- package/dist/manager/_manager-chunks/{globals-runtime-BIrCHXzl.js → globals-runtime-BUEqXras.js} +4 -4
- package/dist/manager/_manager-chunks/{globals-runtime-CHSN7ayG.js → globals-runtime-BsHjh8rR.js} +2 -2
- package/dist/manager/_manager-chunks/{globals-runtime-tTC_6sNF.js → globals-runtime-CQ0Et7dZ.js} +2 -2
- package/dist/manager/_manager-chunks/{globals-runtime-Cw7lbjdT.js → globals-runtime-DChrMWvh.js} +1 -1
- package/dist/manager/_manager-chunks/{globals-runtime-LBSQHYdZ.js → globals-runtime-DiIxNujJ.js} +2 -2
- package/dist/manager/_manager-chunks/{globals-runtime-BypvnYKb.js → globals-runtime-DjkYleFR.js} +174 -104
- package/dist/manager/_manager-chunks/{runtime-Db8fJ2MP.js → runtime-BMoEpoix.js} +24 -21
- package/dist/manager/_manager-chunks/{runtime-DNudxxRZ.js → runtime-BWASr_zc.js} +2 -2
- package/dist/manager/_manager-chunks/{runtime-BjFN_NTg.js → runtime-B_e-Zdqt.js} +12 -8
- package/dist/manager/_manager-chunks/{runtime-CmF_ONjM.js → runtime-CEi1oIg2.js} +420 -326
- package/dist/manager/_manager-chunks/{runtime-DAe0yHIe.js → runtime-CLIeRJL-.js} +2 -2
- package/dist/manager/_manager-chunks/{runtime-Bm0yxY5O.js → runtime-CWZ9qCi4.js} +51 -24
- package/dist/manager/_manager-chunks/{runtime-DE1NZ9Fx.js → runtime-CXOuNYw-.js} +3 -3
- package/dist/manager/_manager-chunks/{runtime-BUwzOVia.js → runtime-C_H6vGzi.js} +6 -5
- package/dist/manager/_manager-chunks/{runtime-X3QUx4F_.js → runtime-Dn2myy1z.js} +8 -8
- package/dist/manager/_manager-chunks/{runtime-CZtDJIYj.js → runtime-TSEq5lJd.js} +1 -1
- package/dist/manager/globals-runtime.js +1 -1
- package/dist/manager/runtime.js +1 -1
- package/dist/manager-api/index.d.ts +1 -1
- package/dist/manager-errors.d.ts +1 -1
- package/dist/mcp/index.js +8 -8
- package/dist/mocking-utils/index.js +9 -9
- package/dist/nextjs-vite/node/index.js +7 -7
- package/dist/nextjs-vite/preset.js +15 -11
- package/dist/nextjs-vite/vite-plugin/index.js +7 -7
- package/dist/nextjs-vite-plugin/index.js +8 -8
- package/dist/nextjs-vite-plugin/mocks/storybook.global.js +8 -8
- package/dist/node-logger/index.js +9 -9
- package/dist/oxc-parser/index.js +10 -10
- package/dist/oxc-parser/worker.js +10 -10
- package/dist/preview/_chunks/{runtime-tyJLgv6h.js → runtime-COMyPEkR.js} +97 -27
- package/dist/preview/_chunks/{runtime-CdZ1yk7m.js → runtime-CqTqsVg2.js} +2 -2
- package/dist/preview/_chunks/{runtime-U1Ycy25F.js → runtime-CrKf1OM4.js} +2 -2
- package/dist/preview/_chunks/{runtime-CsO4apr9.js → runtime-YJlypwja.js} +30 -5
- package/dist/preview/runtime.js +1 -1
- package/dist/preview-api/index.d.ts +2 -2
- package/dist/preview-api/index.js +1 -1
- package/dist/preview-errors.d.ts +1 -1
- package/dist/react/docgen/docgen-worker.js +11 -11
- package/dist/react/preset.js +13 -13
- package/dist/react-native/bin/get-stories.js +8 -8
- package/dist/react-native/metro/node.js +10 -10
- package/dist/react-native/metro/withForkbook.js +13 -13
- package/dist/react-native/scripts/generate.js +8 -8
- package/dist/react-vite/node/index.js +7 -7
- package/dist/react-vite/preset.d.ts +3 -1
- package/dist/react-vite/preset.js +16 -9
- 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 +11 -11
- package/dist/types/index.d.ts +2 -2
- package/package.json +13 -1
- package/dist/_node-chunks/chunk-DGXCQ24N.js +0 -20
- package/dist/_node-chunks/chunk-HLVUFCKZ.js +0 -18
- package/dist/_node-chunks/chunk-K5OUTGSQ.js +0 -25
- package/dist/_node-chunks/chunk-RG3VKQXD.js +0 -11
- package/dist/_node-chunks/chunk-SAVT2SUC.js +0 -20
- package/dist/_node-chunks/chunk-UOIQLKIA.js +0 -19
- package/dist/_node-chunks/dist-474BX4RE.js +0 -27
- package/dist/_node-chunks/dist-U25X3BJ2.js +0 -16
- package/dist/_node-chunks/optimized-tests-4LM55CRN.js +0 -22
- package/dist/_node-chunks/postinstallAddon-OUVXGSJV.js +0 -20
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
@@ -13,7 +13,7 @@ var require = CJS_COMPAT_NODE_MODULE_8s9wmxw3hps.createRequire(import.meta.url);
|
|
|
13
13
|
// package.json with { type: 'json' }
|
|
14
14
|
var package_default = {
|
|
15
15
|
name: "@aussieljk/forkbook",
|
|
16
|
-
version: "0.0.1-
|
|
16
|
+
version: "0.0.1-15",
|
|
17
17
|
description: "Forkbook: a small, fast fork of Storybook for React with Vite, Next.js with Vite and React Native",
|
|
18
18
|
keywords: [
|
|
19
19
|
"forkbook",
|
|
@@ -85,6 +85,18 @@ var package_default = {
|
|
|
85
85
|
types: "./dist/addon-a11y/preview.d.ts",
|
|
86
86
|
default: "./dist/addon-a11y/preview.js"
|
|
87
87
|
},
|
|
88
|
+
"./addon-comments/manager": {
|
|
89
|
+
code: "./src/addon-comments/manager.tsx",
|
|
90
|
+
default: "./dist/addon-comments/manager.js"
|
|
91
|
+
},
|
|
92
|
+
"./addon-comments/preset": {
|
|
93
|
+
code: "./src/addon-comments/preset.ts",
|
|
94
|
+
default: "./dist/addon-comments/preset.js"
|
|
95
|
+
},
|
|
96
|
+
"./addon-comments/preview": {
|
|
97
|
+
code: "./src/addon-comments/preview.ts",
|
|
98
|
+
default: "./dist/addon-comments/preview.js"
|
|
99
|
+
},
|
|
88
100
|
"./addon-docs": {
|
|
89
101
|
code: "./src/addon-docs/index.ts",
|
|
90
102
|
types: "./dist/addon-docs/index.d.ts",
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
@@ -15,10 +15,10 @@ import {
|
|
|
15
15
|
findVarInitialization,
|
|
16
16
|
pathForNode,
|
|
17
17
|
unwrapExpression
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-X3BAGYZJ.js";
|
|
19
19
|
import {
|
|
20
20
|
invariant
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-QF5RQWCH.js";
|
|
22
22
|
|
|
23
23
|
// src/csf-tools/configFileImports.ts
|
|
24
24
|
import { types as t } from "@aussieljk/forkbook/internal/babel";
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
11
11
|
// ------------------------------------------------------------
|
|
12
12
|
import {
|
|
13
13
|
invariant
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-QF5RQWCH.js";
|
|
15
15
|
import {
|
|
16
16
|
__commonJS,
|
|
17
17
|
__toESM
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-7LYHZMJO.js";
|
|
19
19
|
|
|
20
20
|
// ../../node_modules/telejson/dist/index.js
|
|
21
21
|
var require_dist = __commonJS({
|
|
@@ -1140,29 +1140,59 @@ var require_dist = __commonJS({
|
|
|
1140
1140
|
// src/channels/websocket/index.ts
|
|
1141
1141
|
var import_telejson = __toESM(require_dist(), 1);
|
|
1142
1142
|
import * as EVENTS from "@aussieljk/forkbook/internal/core-events";
|
|
1143
|
-
var SERVER_CHANNEL_PATH = "/storybook-server-channel", CHANNEL_OPTIONS = globalThis.CHANNEL_OPTIONS || {}, WebsocketTransport = class {
|
|
1144
|
-
constructor({ url, onError, page, createSocket }) {
|
|
1143
|
+
var SERVER_CHANNEL_PATH = "/storybook-server-channel", RECONNECT_INITIAL_DELAY = 500, RECONNECT_MAX_DELAY = 5e3, MAX_BUFFER = 500, CHANNEL_OPTIONS = globalThis.CHANNEL_OPTIONS || {}, WebsocketTransport = class {
|
|
1144
|
+
constructor({ url, onError, page, createSocket, reconnect }) {
|
|
1145
1145
|
this.buffer = [];
|
|
1146
1146
|
this.isReady = !1;
|
|
1147
1147
|
this.isClosed = !1;
|
|
1148
|
-
this.
|
|
1149
|
-
|
|
1150
|
-
|
|
1148
|
+
this.hasDisconnected = !1;
|
|
1149
|
+
this.attempt = 0;
|
|
1150
|
+
this.url = url, this.page = page || "preview", this.onError = onError, this.createSocket = createSocket ?? ((socketUrl) => new WebSocket(socketUrl)), this.reconnect = reconnect === !0 ? {} : reconnect || void 0, this.socket = this.connect(url);
|
|
1151
|
+
}
|
|
1152
|
+
connect(url) {
|
|
1153
|
+
let socket = this.createSocket(url);
|
|
1154
|
+
return socket.onopen = () => {
|
|
1155
|
+
this.isReady = !0, this.attempt = 0, this.flush(), this.hasDisconnected && (this.hasDisconnected = !1, this.handler?.({ type: EVENTS.CHANNEL_WS_RECONNECT, args: [], from: this.page }));
|
|
1156
|
+
}, socket.onmessage = ({ data }) => {
|
|
1151
1157
|
let event = typeof data == "string" && (0, import_telejson.isJSON)(data) ? (0, import_telejson.parse)(data) : data;
|
|
1152
1158
|
if (invariant(this.handler, "WebsocketTransport handler should be set"), event.type === "ping") {
|
|
1153
1159
|
this.send({ type: "pong" });
|
|
1154
1160
|
return;
|
|
1155
1161
|
}
|
|
1156
1162
|
this.handler(event);
|
|
1157
|
-
},
|
|
1158
|
-
onError && onError(e);
|
|
1159
|
-
},
|
|
1160
|
-
|
|
1163
|
+
}, socket.onerror = (e) => {
|
|
1164
|
+
this.onError && this.onError(e);
|
|
1165
|
+
}, socket.onclose = (ev) => {
|
|
1166
|
+
let wasOpen = this.isReady;
|
|
1167
|
+
if (this.isReady = !1, !this.reconnect) {
|
|
1168
|
+
invariant(this.handler, "WebsocketTransport handler should be set"), this.handler({
|
|
1169
|
+
type: EVENTS.CHANNEL_WS_DISCONNECT,
|
|
1170
|
+
args: [{ reason: ev.reason, code: ev.code }],
|
|
1171
|
+
from: this.page
|
|
1172
|
+
}), this.isClosed = !0;
|
|
1173
|
+
return;
|
|
1174
|
+
}
|
|
1175
|
+
(wasOpen || !this.hasDisconnected) && (this.hasDisconnected = !0, this.handler?.({
|
|
1161
1176
|
type: EVENTS.CHANNEL_WS_DISCONNECT,
|
|
1162
|
-
args: [{ reason: ev.reason, code: ev.code }],
|
|
1163
|
-
from: page
|
|
1164
|
-
}), this.
|
|
1165
|
-
};
|
|
1177
|
+
args: [{ reason: ev.reason, code: ev.code, reconnecting: !0 }],
|
|
1178
|
+
from: this.page
|
|
1179
|
+
})), this.scheduleReconnect();
|
|
1180
|
+
}, socket;
|
|
1181
|
+
}
|
|
1182
|
+
scheduleReconnect() {
|
|
1183
|
+
let {
|
|
1184
|
+
initialDelay = RECONNECT_INITIAL_DELAY,
|
|
1185
|
+
maxDelay = RECONNECT_MAX_DELAY,
|
|
1186
|
+
getUrl
|
|
1187
|
+
} = this.reconnect ?? {}, delay = Math.min(initialDelay * 2 ** this.attempt, maxDelay);
|
|
1188
|
+
this.attempt += 1, setTimeout(async () => {
|
|
1189
|
+
let nextUrl = this.url;
|
|
1190
|
+
try {
|
|
1191
|
+
nextUrl = getUrl ? await getUrl() : this.url;
|
|
1192
|
+
} catch {
|
|
1193
|
+
}
|
|
1194
|
+
this.socket = this.connect(nextUrl);
|
|
1195
|
+
}, delay);
|
|
1166
1196
|
}
|
|
1167
1197
|
setHandler(handler) {
|
|
1168
1198
|
this.handler = handler;
|
|
@@ -1171,7 +1201,7 @@ var SERVER_CHANNEL_PATH = "/storybook-server-channel", CHANNEL_OPTIONS = globalT
|
|
|
1171
1201
|
this.isClosed || (this.isReady ? this.sendNow(event) : this.sendLater(event));
|
|
1172
1202
|
}
|
|
1173
1203
|
sendLater(event) {
|
|
1174
|
-
this.buffer.push(event);
|
|
1204
|
+
event.type !== "pong" && (this.buffer.push(event), this.buffer.length > MAX_BUFFER && this.buffer.shift());
|
|
1175
1205
|
}
|
|
1176
1206
|
sendNow(event) {
|
|
1177
1207
|
let data = (0, import_telejson.stringify)(event, {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
11
11
|
// ------------------------------------------------------------
|
|
12
12
|
import {
|
|
13
13
|
isEqual
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-AUUVNECB.js";
|
|
15
15
|
import {
|
|
16
16
|
deserializeError,
|
|
17
17
|
serializeError
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-5NWCUFPU.js";
|
|
19
19
|
import {
|
|
20
20
|
OpenServiceAsyncRecipeError,
|
|
21
21
|
OpenServiceAsyncSchemaError,
|
|
@@ -31,7 +31,7 @@ import {
|
|
|
31
31
|
OpenServiceRemoteCommandUnhandledError,
|
|
32
32
|
OpenServiceUnimplementedOperationError,
|
|
33
33
|
OpenServiceValidationError
|
|
34
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-G6M5USWY.js";
|
|
35
35
|
|
|
36
36
|
// src/channels/main.ts
|
|
37
37
|
var isMulti = (args) => "transports" in args && args.transports !== void 0, generateRandomId = () => Math.random().toString(16).slice(2), Channel = class {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
@@ -17,7 +17,7 @@ import {
|
|
|
17
17
|
resolveStaticPath,
|
|
18
18
|
serviceRegistryApi,
|
|
19
19
|
validateSchema
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-767UK7PX.js";
|
|
21
21
|
import {
|
|
22
22
|
argumentsTag,
|
|
23
23
|
arrayBufferTag,
|
|
@@ -47,15 +47,15 @@ import {
|
|
|
47
47
|
uint32ArrayTag,
|
|
48
48
|
uint8ArrayTag,
|
|
49
49
|
uint8ClampedArrayTag
|
|
50
|
-
} from "./chunk-
|
|
50
|
+
} from "./chunk-AUUVNECB.js";
|
|
51
51
|
import {
|
|
52
52
|
any,
|
|
53
53
|
up,
|
|
54
54
|
up2
|
|
55
|
-
} from "./chunk-
|
|
55
|
+
} from "./chunk-4XKLH4I3.js";
|
|
56
56
|
import {
|
|
57
57
|
globSync
|
|
58
|
-
} from "./chunk-
|
|
58
|
+
} from "./chunk-KFZRX33G.js";
|
|
59
59
|
|
|
60
60
|
// src/shared/open-service/server.ts
|
|
61
61
|
import { mkdir, writeFile } from "node:fs/promises";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
@@ -12,7 +12,7 @@ var require = CJS_COMPAT_NODE_MODULE_8s9wmxw3hps.createRequire(import.meta.url);
|
|
|
12
12
|
import {
|
|
13
13
|
__commonJS,
|
|
14
14
|
__require
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-7LYHZMJO.js";
|
|
16
16
|
|
|
17
17
|
// ../../node_modules/tsconfig-paths/lib/filesystem.js
|
|
18
18
|
var require_filesystem = __commonJS({
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
11
11
|
// ------------------------------------------------------------
|
|
12
12
|
import {
|
|
13
13
|
slash
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-W7352H3Q.js";
|
|
15
15
|
|
|
16
16
|
// src/shared/open-service/services/module-graph/types.ts
|
|
17
17
|
import { posix, win32 } from "node:path";
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
|
+
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
|
+
|
|
9
|
+
// ------------------------------------------------------------
|
|
10
|
+
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
11
|
+
// ------------------------------------------------------------
|
|
12
|
+
|
|
13
|
+
// src/addon-comments/constants.ts
|
|
14
|
+
var ADDON_ID = "@aussieljk/forkbook/comments", PANEL_ID = `${ADDON_ID}/panel`, TOOL_ID = `${ADDON_ID}/tool`, COMMENTS_API_PATH = "/__forkbook/comments", COMMENTS_FILE = ".forkbook/comments.json", EVENTS = {
|
|
15
|
+
/** Manager to preview: start the element picker. */
|
|
16
|
+
PICK_START: `${ADDON_ID}/pick-start`,
|
|
17
|
+
/** Manager to preview: stop the element picker. */
|
|
18
|
+
PICK_CANCEL: `${ADDON_ID}/pick-cancel`,
|
|
19
|
+
/** Preview to manager: the user clicked an element. */
|
|
20
|
+
PICKED: `${ADDON_ID}/picked`,
|
|
21
|
+
/** Preview to manager: the user stopped the picker (Escape). */
|
|
22
|
+
PICK_ENDED: `${ADDON_ID}/pick-ended`
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
// src/addon-comments/store.ts
|
|
26
|
+
import { randomUUID } from "node:crypto";
|
|
27
|
+
import { mkdir, readFile, rename, writeFile } from "node:fs/promises";
|
|
28
|
+
import { dirname, join } from "node:path";
|
|
29
|
+
var getCommentsFilePath = (projectRoot) => join(projectRoot, COMMENTS_FILE), CommentStore = class {
|
|
30
|
+
constructor(filePath, now = () => /* @__PURE__ */ new Date(), createId = () => randomUUID().slice(0, 8)) {
|
|
31
|
+
this.filePath = filePath;
|
|
32
|
+
this.now = now;
|
|
33
|
+
this.createId = createId;
|
|
34
|
+
this.queue = Promise.resolve();
|
|
35
|
+
}
|
|
36
|
+
async list(filter = {}) {
|
|
37
|
+
await this.queue;
|
|
38
|
+
let { comments } = await this.read(), status = filter.status ?? "all";
|
|
39
|
+
return comments.filter(
|
|
40
|
+
(comment) => (status === "all" || comment.status === status) && (!filter.storyId || comment.storyId === filter.storyId)
|
|
41
|
+
);
|
|
42
|
+
}
|
|
43
|
+
add(input) {
|
|
44
|
+
let note = typeof input?.note == "string" ? input.note.trim() : "";
|
|
45
|
+
return note ? input.storyId ? this.update((comments) => {
|
|
46
|
+
let comment = {
|
|
47
|
+
id: this.createId(),
|
|
48
|
+
status: "open",
|
|
49
|
+
createdAt: this.now().toISOString(),
|
|
50
|
+
storyId: input.storyId,
|
|
51
|
+
title: input.title ?? "",
|
|
52
|
+
name: input.name ?? "",
|
|
53
|
+
...input.importPath ? { importPath: input.importPath } : {},
|
|
54
|
+
...input.element ? { element: input.element } : {},
|
|
55
|
+
...input.args ? { args: input.args } : {},
|
|
56
|
+
note
|
|
57
|
+
};
|
|
58
|
+
return comments.push(comment), comment;
|
|
59
|
+
}) : Promise.reject(new Error("A comment must have a story id")) : Promise.reject(new Error("A comment must have a note"));
|
|
60
|
+
}
|
|
61
|
+
resolve(id, reply) {
|
|
62
|
+
return this.change(id, (comment) => {
|
|
63
|
+
comment.status = "resolved", comment.resolvedAt = this.now().toISOString(), reply?.trim() && (comment.reply = reply.trim());
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
reopen(id) {
|
|
67
|
+
return this.change(id, (comment) => {
|
|
68
|
+
comment.status = "open", delete comment.resolvedAt;
|
|
69
|
+
});
|
|
70
|
+
}
|
|
71
|
+
delete(id) {
|
|
72
|
+
return this.update((comments) => {
|
|
73
|
+
let index = comments.findIndex((comment) => comment.id === id);
|
|
74
|
+
if (index === -1)
|
|
75
|
+
throw new Error(`No comment with id "${id}"`);
|
|
76
|
+
return comments.splice(index, 1)[0];
|
|
77
|
+
});
|
|
78
|
+
}
|
|
79
|
+
/** Applies an action from the REST route. */
|
|
80
|
+
apply(action) {
|
|
81
|
+
switch (action?.action) {
|
|
82
|
+
case "add":
|
|
83
|
+
return this.add(action.comment);
|
|
84
|
+
case "resolve":
|
|
85
|
+
return this.resolve(action.id, action.reply);
|
|
86
|
+
case "reopen":
|
|
87
|
+
return this.reopen(action.id);
|
|
88
|
+
case "delete":
|
|
89
|
+
return this.delete(action.id);
|
|
90
|
+
default:
|
|
91
|
+
return Promise.reject(new Error("Unknown comment action"));
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
change(id, fn) {
|
|
95
|
+
return this.update((comments) => {
|
|
96
|
+
let comment = comments.find((item) => item.id === id);
|
|
97
|
+
if (!comment)
|
|
98
|
+
throw new Error(`No comment with id "${id}"`);
|
|
99
|
+
return fn(comment), comment;
|
|
100
|
+
});
|
|
101
|
+
}
|
|
102
|
+
update(fn) {
|
|
103
|
+
let run = this.queue.then(async () => {
|
|
104
|
+
let file = await this.read(), result = fn(file.comments);
|
|
105
|
+
return await this.write(file), result;
|
|
106
|
+
});
|
|
107
|
+
return this.queue = run.catch(() => {
|
|
108
|
+
}), run;
|
|
109
|
+
}
|
|
110
|
+
async read() {
|
|
111
|
+
let text;
|
|
112
|
+
try {
|
|
113
|
+
text = await readFile(this.filePath, "utf8");
|
|
114
|
+
} catch (error) {
|
|
115
|
+
if (error.code === "ENOENT")
|
|
116
|
+
return { version: 1, comments: [] };
|
|
117
|
+
throw error;
|
|
118
|
+
}
|
|
119
|
+
let data = JSON.parse(text);
|
|
120
|
+
return { version: 1, comments: Array.isArray(data.comments) ? data.comments : [] };
|
|
121
|
+
}
|
|
122
|
+
async write(file) {
|
|
123
|
+
await mkdir(dirname(this.filePath), { recursive: !0 });
|
|
124
|
+
let temp = `${this.filePath}.${process.pid}.tmp`;
|
|
125
|
+
await writeFile(temp, `${JSON.stringify(file, null, 2)}
|
|
126
|
+
`), await rename(temp, this.filePath);
|
|
127
|
+
}
|
|
128
|
+
}, stores = /* @__PURE__ */ new Map();
|
|
129
|
+
function getCommentStore(projectRoot) {
|
|
130
|
+
let filePath = getCommentsFilePath(projectRoot), store = stores.get(filePath);
|
|
131
|
+
return store || (store = new CommentStore(filePath), stores.set(filePath, store)), store;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
export {
|
|
135
|
+
COMMENTS_API_PATH,
|
|
136
|
+
getCommentStore
|
|
137
|
+
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
@@ -12,7 +12,7 @@ var require = CJS_COMPAT_NODE_MODULE_8s9wmxw3hps.createRequire(import.meta.url);
|
|
|
12
12
|
import {
|
|
13
13
|
globalThis_,
|
|
14
14
|
noop
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-MLJPAH4O.js";
|
|
16
16
|
|
|
17
17
|
// ../../node_modules/es-toolkit/dist/compat/_internal/getSymbols.mjs
|
|
18
18
|
function getSymbols(object) {
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_wr9w1e50s8 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_wr9w1e50s8 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_wr9w1e50s8 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_wr9w1e50s8.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_wr9w1e50s8.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_wr9w1e50s8.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Forkbook's esbuild configuration
|
|
11
11
|
// ------------------------------------------------------------
|
|
12
12
|
import {
|
|
13
13
|
DOCUMENTATION_LINK
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-VS4AUXP2.js";
|
|
15
15
|
import {
|
|
16
16
|
any
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-4XKLH4I3.js";
|
|
18
18
|
|
|
19
19
|
// src/addon-vitest/postinstall.ts
|
|
20
20
|
import * as fs from "node:fs/promises";
|
|
@@ -47,7 +47,7 @@ import {
|
|
|
47
47
|
} from "@aussieljk/forkbook/internal/babel";
|
|
48
48
|
import { normalize } from "pathe";
|
|
49
49
|
async function getTemplatePath() {
|
|
50
|
-
return import("./vitest.config.4.template-
|
|
50
|
+
return import("./vitest.config.4.template-TXAUMPSS.js");
|
|
51
51
|
}
|
|
52
52
|
var loadTemplate = async (name, replacements) => {
|
|
53
53
|
let template = (await getTemplatePath()).default;
|