@dxos/plugin-wnfs 0.8.3 → 0.8.4-main.f9ba587
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/lib/browser/{FileContainer-7YOCEQ6P.mjs → FileContainer-Q4GUPBVD.mjs} +12 -11
- package/dist/lib/browser/FileContainer-Q4GUPBVD.mjs.map +7 -0
- package/dist/lib/browser/{blockstore-UT7233RJ.mjs → blockstore-KQO2NTVM.mjs} +7 -7
- package/dist/lib/browser/chunk-BANMVVJV.mjs +16 -0
- package/dist/lib/browser/{chunk-SCL6PT4P.mjs → chunk-GVBV2QWA.mjs} +4 -4
- package/dist/lib/browser/{chunk-DL7BBH57.mjs → chunk-KZANQHJY.mjs} +3 -3
- package/dist/lib/browser/{chunk-PHTWWADN.mjs → chunk-VDDGZWAY.mjs} +2 -2
- package/dist/lib/browser/{chunk-YYAW4U6J.mjs → chunk-VRRXG6IB.mjs} +6 -6
- package/dist/lib/browser/{file-uploader-RHINBPDQ.mjs → file-uploader-JA55DPMW.mjs} +4 -4
- package/dist/lib/browser/index.mjs +10 -10
- package/dist/lib/browser/index.mjs.map +3 -3
- package/dist/lib/browser/{intent-resolver-JDRRPIZC.mjs → intent-resolver-YM6QRFIH.mjs} +6 -6
- package/dist/lib/browser/{markdown-BWBHUHHH.mjs → markdown-6VH477GB.mjs} +7 -7
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/{react-surface-6GM4J4YG.mjs → react-surface-XAHVMWIH.mjs} +9 -9
- package/dist/lib/browser/types/index.mjs +2 -2
- package/dist/lib/node-esm/FileContainer-22IPNDDA.mjs +108 -0
- package/dist/lib/node-esm/FileContainer-22IPNDDA.mjs.map +7 -0
- package/dist/lib/node-esm/blockstore-7KQTFHK5.mjs +192 -0
- package/dist/lib/node-esm/blockstore-7KQTFHK5.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-47QYKNA6.mjs +17 -0
- package/dist/lib/node-esm/chunk-47QYKNA6.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-BM37ZAHF.mjs +65 -0
- package/dist/lib/node-esm/chunk-BM37ZAHF.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-CGW32EZB.mjs +161 -0
- package/dist/lib/node-esm/chunk-CGW32EZB.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-DWYM7FD7.mjs +18 -0
- package/dist/lib/node-esm/chunk-DWYM7FD7.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-YTWL64Z6.mjs +17 -0
- package/dist/lib/node-esm/chunk-YTWL64Z6.mjs.map +7 -0
- package/dist/lib/node-esm/file-uploader-WGDG2YV5.mjs +30 -0
- package/dist/lib/node-esm/file-uploader-WGDG2YV5.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +117 -0
- package/dist/lib/node-esm/index.mjs.map +7 -0
- package/dist/lib/node-esm/intent-resolver-5QOT2SLD.mjs +50 -0
- package/dist/lib/node-esm/intent-resolver-5QOT2SLD.mjs.map +7 -0
- package/dist/lib/node-esm/markdown-R4PBXDJO.mjs +197 -0
- package/dist/lib/node-esm/markdown-R4PBXDJO.mjs.map +7 -0
- package/dist/lib/node-esm/meta.json +1 -0
- package/dist/lib/node-esm/react-surface-HAOUJUXJ.mjs +89 -0
- package/dist/lib/node-esm/react-surface-HAOUJUXJ.mjs.map +7 -0
- package/dist/lib/node-esm/types/index.mjs +11 -0
- package/dist/lib/node-esm/types/index.mjs.map +7 -0
- package/dist/types/src/components/FileContainer.d.ts +4 -3
- package/dist/types/src/components/FileContainer.d.ts.map +1 -1
- package/dist/types/src/components/index.d.ts +1 -4
- package/dist/types/src/components/index.d.ts.map +1 -1
- package/dist/types/src/translations.d.ts +11 -11
- package/dist/types/src/translations.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +24 -26
- package/src/WnfsPlugin.tsx +1 -1
- package/src/components/FileContainer.tsx +6 -1
- package/src/translations.ts +6 -4
- package/dist/lib/browser/FileContainer-7YOCEQ6P.mjs.map +0 -7
- package/dist/lib/browser/chunk-WJVYRUYQ.mjs +0 -16
- /package/dist/lib/browser/{blockstore-UT7233RJ.mjs.map → blockstore-KQO2NTVM.mjs.map} +0 -0
- /package/dist/lib/browser/{chunk-WJVYRUYQ.mjs.map → chunk-BANMVVJV.mjs.map} +0 -0
- /package/dist/lib/browser/{chunk-SCL6PT4P.mjs.map → chunk-GVBV2QWA.mjs.map} +0 -0
- /package/dist/lib/browser/{chunk-DL7BBH57.mjs.map → chunk-KZANQHJY.mjs.map} +0 -0
- /package/dist/lib/browser/{chunk-PHTWWADN.mjs.map → chunk-VDDGZWAY.mjs.map} +0 -0
- /package/dist/lib/browser/{chunk-YYAW4U6J.mjs.map → chunk-VRRXG6IB.mjs.map} +0 -0
- /package/dist/lib/browser/{file-uploader-RHINBPDQ.mjs.map → file-uploader-JA55DPMW.mjs.map} +0 -0
- /package/dist/lib/browser/{intent-resolver-JDRRPIZC.mjs.map → intent-resolver-YM6QRFIH.mjs.map} +0 -0
- /package/dist/lib/browser/{markdown-BWBHUHHH.mjs.map → markdown-6VH477GB.mjs.map} +0 -0
- /package/dist/lib/browser/{react-surface-6GM4J4YG.mjs.map → react-surface-XAHVMWIH.mjs.map} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"inputs":{"packages/plugins/plugin-wnfs/src/meta.ts":{"bytes":1463,"imports":[],"format":"esm"},"packages/plugins/plugin-wnfs/src/capabilities/capabilities.ts":{"bytes":1937,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/helpers/common.ts":{"bytes":7615,"imports":[{"path":"multiformats/cid","kind":"import-statement","external":true},{"path":"multiformats/hashes/sha2","kind":"import-statement","external":true},{"path":"@dxos/crypto","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-wnfs/src/helpers/load.ts":{"bytes":8933,"imports":[{"path":"multiformats","kind":"import-statement","external":true},{"path":"uint8arrays","kind":"import-statement","external":true},{"path":"wnfs","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/helpers/common.ts","kind":"import-statement","original":"./common"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/helpers/wnfs-url.ts":{"bytes":3338,"imports":[{"path":"packages/plugins/plugin-wnfs/src/helpers/common.ts","kind":"import-statement","original":"./common"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/helpers/upload.ts":{"bytes":6696,"imports":[{"path":"multiformats","kind":"import-statement","external":true},{"path":"multiformats/codecs/raw","kind":"import-statement","external":true},{"path":"multiformats/hashes/sha2","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/helpers/common.ts","kind":"import-statement","original":"./common"},{"path":"packages/plugins/plugin-wnfs/src/helpers/load.ts","kind":"import-statement","original":"./load"},{"path":"packages/plugins/plugin-wnfs/src/helpers/wnfs-url.ts","kind":"import-statement","original":"./wnfs-url"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/helpers/index.ts":{"bytes":724,"imports":[{"path":"packages/plugins/plugin-wnfs/src/helpers/common.ts","kind":"import-statement","original":"./common"},{"path":"packages/plugins/plugin-wnfs/src/helpers/load.ts","kind":"import-statement","original":"./load"},{"path":"packages/plugins/plugin-wnfs/src/helpers/upload.ts","kind":"import-statement","original":"./upload"},{"path":"packages/plugins/plugin-wnfs/src/helpers/wnfs-url.ts","kind":"import-statement","original":"./wnfs-url"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/blockstore.ts":{"bytes":19260,"imports":[{"path":"@ipld/car","kind":"import-statement","external":true},{"path":"blockstore-core","kind":"import-statement","external":true},{"path":"blockstore-idb","kind":"import-statement","external":true},{"path":"debounce","kind":"import-statement","external":true},{"path":"idb-keyval","kind":"import-statement","external":true},{"path":"it-all","kind":"import-statement","external":true},{"path":"multiformats","kind":"import-statement","external":true},{"path":"uint8arrays","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/helpers/index.ts","kind":"import-statement","original":"./helpers"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/capabilities/blockstore.ts":{"bytes":2526,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/capabilities/capabilities.ts","kind":"import-statement","original":"./capabilities"},{"path":"packages/plugins/plugin-wnfs/src/blockstore.ts","kind":"import-statement","original":"../blockstore"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/types/file.ts":{"bytes":1653,"imports":[{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-wnfs/src/types/types.ts":{"bytes":4909,"imports":[{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/types/file.ts","kind":"import-statement","original":"./file"},{"path":"packages/plugins/plugin-wnfs/src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/types/index.ts":{"bytes":547,"imports":[{"path":"packages/plugins/plugin-wnfs/src/types/file.ts","kind":"import-statement","original":"./file"},{"path":"packages/plugins/plugin-wnfs/src/types/types.ts","kind":"import-statement","original":"./types"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/capabilities/file-uploader.ts":{"bytes":3392,"imports":[{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/capabilities/intent-resolver.ts":{"bytes":4471,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/capabilities/capabilities.ts","kind":"import-statement","original":"./capabilities"},{"path":"packages/plugins/plugin-wnfs/src/helpers/index.ts","kind":"import-statement","original":"../helpers"},{"path":"packages/plugins/plugin-wnfs/src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/extensions/image.tsx":{"bytes":21204,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dom/client","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-editor","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/helpers/index.ts","kind":"import-statement","original":"../helpers"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/extensions/index.ts":{"bytes":472,"imports":[{"path":"packages/plugins/plugin-wnfs/src/extensions/image.tsx","kind":"import-statement","original":"./image"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/capabilities/markdown.ts":{"bytes":3134,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-markdown","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/capabilities/capabilities.ts","kind":"import-statement","original":"./capabilities"},{"path":"packages/plugins/plugin-wnfs/src/extensions/index.ts","kind":"import-statement","original":"../extensions"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/components/FileInput.tsx":{"bytes":5198,"imports":[{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dropzone","kind":"import-statement","external":true},{"path":"@dxos/effect","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/meta.ts","kind":"import-statement","original":"../meta"},{"path":"packages/plugins/plugin-wnfs/src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/components/FilePreview.tsx":{"bytes":3109,"imports":[{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-wnfs/src/components/FileContainer.tsx":{"bytes":6271,"imports":[{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui-stack","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/components/FilePreview.tsx","kind":"import-statement","original":"./FilePreview"},{"path":"packages/plugins/plugin-wnfs/src/capabilities/index.ts","kind":"import-statement","original":"../capabilities"},{"path":"packages/plugins/plugin-wnfs/src/helpers/index.ts","kind":"import-statement","original":"../helpers"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/components/index.ts":{"bytes":852,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/components/FileInput.tsx","kind":"import-statement","original":"./FileInput"},{"path":"packages/plugins/plugin-wnfs/src/components/FileContainer.tsx","kind":"dynamic-import","original":"./FileContainer"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/capabilities/react-surface.tsx":{"bytes":5922,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true},{"path":"@dxos/effect","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/components/index.ts","kind":"import-statement","original":"../components"},{"path":"packages/plugins/plugin-wnfs/src/meta.ts","kind":"import-statement","original":"../meta"},{"path":"packages/plugins/plugin-wnfs/src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/capabilities/index.ts":{"bytes":1832,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/capabilities/capabilities.ts","kind":"import-statement","original":"./capabilities"},{"path":"packages/plugins/plugin-wnfs/src/capabilities/blockstore.ts","kind":"dynamic-import","original":"./blockstore"},{"path":"packages/plugins/plugin-wnfs/src/capabilities/file-uploader.ts","kind":"dynamic-import","original":"./file-uploader"},{"path":"packages/plugins/plugin-wnfs/src/capabilities/intent-resolver.ts","kind":"dynamic-import","original":"./intent-resolver"},{"path":"packages/plugins/plugin-wnfs/src/capabilities/markdown.ts","kind":"dynamic-import","original":"./markdown"},{"path":"packages/plugins/plugin-wnfs/src/capabilities/react-surface.tsx","kind":"dynamic-import","original":"./react-surface"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/translations.ts":{"bytes":1852,"imports":[{"path":"packages/plugins/plugin-wnfs/src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"packages/plugins/plugin-wnfs/src/types/index.ts","kind":"import-statement","original":"./types"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/WnfsPlugin.tsx":{"bytes":10989,"imports":[{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@dxos/plugin-markdown","kind":"import-statement","external":true},{"path":"@dxos/plugin-space","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/src/capabilities/index.ts","kind":"import-statement","original":"./capabilities"},{"path":"packages/plugins/plugin-wnfs/src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"packages/plugins/plugin-wnfs/src/translations.ts","kind":"import-statement","original":"./translations"},{"path":"packages/plugins/plugin-wnfs/src/types/index.ts","kind":"import-statement","original":"./types"}],"format":"esm"},"packages/plugins/plugin-wnfs/src/index.ts":{"bytes":737,"imports":[{"path":"packages/plugins/plugin-wnfs/src/capabilities/index.ts","kind":"import-statement","original":"./capabilities"},{"path":"packages/plugins/plugin-wnfs/src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"packages/plugins/plugin-wnfs/src/WnfsPlugin.tsx","kind":"import-statement","original":"./WnfsPlugin"}],"format":"esm"}},"outputs":{"packages/plugins/plugin-wnfs/dist/lib/browser/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":6184},"packages/plugins/plugin-wnfs/dist/lib/browser/index.mjs":{"imports":[{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-WJVYRUYQ.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-DL7BBH57.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-SCL6PT4P.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-PHTWWADN.mjs","kind":"import-statement"},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@dxos/plugin-markdown","kind":"import-statement","external":true},{"path":"@dxos/plugin-space","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true}],"exports":["WNFS_PLUGIN","WnfsCapabilities","WnfsPlugin","meta"],"entryPoint":"packages/plugins/plugin-wnfs/src/index.ts","inputs":{"packages/plugins/plugin-wnfs/src/index.ts":{"bytesInOutput":0},"packages/plugins/plugin-wnfs/src/WnfsPlugin.tsx":{"bytesInOutput":2380},"packages/plugins/plugin-wnfs/src/translations.ts":{"bytesInOutput":363}},"bytes":3304},"packages/plugins/plugin-wnfs/dist/lib/browser/types/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":93},"packages/plugins/plugin-wnfs/dist/lib/browser/types/index.mjs":{"imports":[{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-SCL6PT4P.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-PHTWWADN.mjs","kind":"import-statement"}],"exports":["FileType","WnfsAction"],"entryPoint":"packages/plugins/plugin-wnfs/src/types/index.ts","inputs":{},"bytes":170},"packages/plugins/plugin-wnfs/dist/lib/browser/blockstore-UT7233RJ.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":10739},"packages/plugins/plugin-wnfs/dist/lib/browser/blockstore-UT7233RJ.mjs":{"imports":[{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-YYAW4U6J.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-DL7BBH57.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-PHTWWADN.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@ipld/car","kind":"import-statement","external":true},{"path":"blockstore-core","kind":"import-statement","external":true},{"path":"blockstore-idb","kind":"import-statement","external":true},{"path":"debounce","kind":"import-statement","external":true},{"path":"idb-keyval","kind":"import-statement","external":true},{"path":"it-all","kind":"import-statement","external":true},{"path":"multiformats","kind":"import-statement","external":true},{"path":"uint8arrays","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"packages/plugins/plugin-wnfs/src/capabilities/blockstore.ts","inputs":{"packages/plugins/plugin-wnfs/src/capabilities/blockstore.ts":{"bytesInOutput":449},"packages/plugins/plugin-wnfs/src/blockstore.ts":{"bytesInOutput":4273}},"bytes":5136},"packages/plugins/plugin-wnfs/dist/lib/browser/file-uploader-RHINBPDQ.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1829},"packages/plugins/plugin-wnfs/dist/lib/browser/file-uploader-RHINBPDQ.mjs":{"imports":[{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-SCL6PT4P.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-PHTWWADN.mjs","kind":"import-statement"},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"packages/plugins/plugin-wnfs/src/capabilities/file-uploader.ts","inputs":{"packages/plugins/plugin-wnfs/src/capabilities/file-uploader.ts":{"bytesInOutput":742}},"bytes":992},"packages/plugins/plugin-wnfs/dist/lib/browser/intent-resolver-JDRRPIZC.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":2095},"packages/plugins/plugin-wnfs/dist/lib/browser/intent-resolver-JDRRPIZC.mjs":{"imports":[{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-YYAW4U6J.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-DL7BBH57.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-SCL6PT4P.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-PHTWWADN.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"packages/plugins/plugin-wnfs/src/capabilities/intent-resolver.ts","inputs":{"packages/plugins/plugin-wnfs/src/capabilities/intent-resolver.ts":{"bytesInOutput":918}},"bytes":1294},"packages/plugins/plugin-wnfs/dist/lib/browser/markdown-BWBHUHHH.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":12475},"packages/plugins/plugin-wnfs/dist/lib/browser/markdown-BWBHUHHH.mjs":{"imports":[{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-YYAW4U6J.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-DL7BBH57.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-PHTWWADN.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-markdown","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dom/client","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-editor","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"packages/plugins/plugin-wnfs/src/capabilities/markdown.ts","inputs":{"packages/plugins/plugin-wnfs/src/capabilities/markdown.ts":{"bytesInOutput":643},"packages/plugins/plugin-wnfs/src/extensions/image.tsx":{"bytesInOutput":4786},"packages/plugins/plugin-wnfs/src/extensions/index.ts":{"bytesInOutput":0}},"bytes":5873},"packages/plugins/plugin-wnfs/dist/lib/browser/FileContainer-7YOCEQ6P.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":4340},"packages/plugins/plugin-wnfs/dist/lib/browser/FileContainer-7YOCEQ6P.mjs":{"imports":[{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-WJVYRUYQ.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-YYAW4U6J.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-DL7BBH57.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-PHTWWADN.mjs","kind":"import-statement"},{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui-stack","kind":"import-statement","external":true},{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"packages/plugins/plugin-wnfs/src/components/FileContainer.tsx","inputs":{"packages/plugins/plugin-wnfs/src/components/FileContainer.tsx":{"bytesInOutput":1767},"packages/plugins/plugin-wnfs/src/components/FilePreview.tsx":{"bytesInOutput":863}},"bytes":3134},"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-WJVYRUYQ.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":909},"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-WJVYRUYQ.mjs":{"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/blockstore-UT7233RJ.mjs","kind":"dynamic-import"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/file-uploader-RHINBPDQ.mjs","kind":"dynamic-import"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/intent-resolver-JDRRPIZC.mjs","kind":"dynamic-import"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/markdown-BWBHUHHH.mjs","kind":"dynamic-import"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/react-surface-6GM4J4YG.mjs","kind":"dynamic-import"}],"exports":["Blockstore","FileUploader","IntentResolver","Markdown","ReactSurface"],"inputs":{"packages/plugins/plugin-wnfs/src/capabilities/index.ts":{"bytesInOutput":389}},"bytes":579},"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-YYAW4U6J.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":13383},"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-YYAW4U6J.mjs":{"imports":[{"path":"multiformats/cid","kind":"import-statement","external":true},{"path":"multiformats/hashes/sha2","kind":"import-statement","external":true},{"path":"@dxos/crypto","kind":"import-statement","external":true},{"path":"multiformats","kind":"import-statement","external":true},{"path":"uint8arrays","kind":"import-statement","external":true},{"path":"wnfs","kind":"import-statement","external":true},{"path":"multiformats","kind":"import-statement","external":true},{"path":"multiformats/codecs/raw","kind":"import-statement","external":true},{"path":"multiformats/hashes/sha2","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true}],"exports":["filePath","getBlobUrl","getPathFromUrl","loadWnfs","storeName","upload","wnfsUrl"],"inputs":{"packages/plugins/plugin-wnfs/src/helpers/common.ts":{"bytesInOutput":1077},"packages/plugins/plugin-wnfs/src/helpers/load.ts":{"bytesInOutput":1918},"packages/plugins/plugin-wnfs/src/helpers/wnfs-url.ts":{"bytesInOutput":567},"packages/plugins/plugin-wnfs/src/helpers/upload.ts":{"bytesInOutput":1281},"packages/plugins/plugin-wnfs/src/helpers/index.ts":{"bytesInOutput":0}},"bytes":5208},"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-DL7BBH57.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1040},"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-DL7BBH57.mjs":{"imports":[{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-PHTWWADN.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true}],"exports":["WnfsCapabilities"],"inputs":{"packages/plugins/plugin-wnfs/src/capabilities/capabilities.ts":{"bytesInOutput":338}},"bytes":534},"packages/plugins/plugin-wnfs/dist/lib/browser/react-surface-6GM4J4YG.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":5915},"packages/plugins/plugin-wnfs/dist/lib/browser/react-surface-6GM4J4YG.mjs":{"imports":[{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-SCL6PT4P.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-PHTWWADN.mjs","kind":"import-statement"},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true},{"path":"@dxos/effect","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dropzone","kind":"import-statement","external":true},{"path":"@dxos/effect","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/FileContainer-7YOCEQ6P.mjs","kind":"dynamic-import"}],"exports":["default"],"entryPoint":"packages/plugins/plugin-wnfs/src/capabilities/react-surface.tsx","inputs":{"packages/plugins/plugin-wnfs/src/capabilities/react-surface.tsx":{"bytesInOutput":1243},"packages/plugins/plugin-wnfs/src/components/index.ts":{"bytesInOutput":102},"packages/plugins/plugin-wnfs/src/components/FileInput.tsx":{"bytesInOutput":1320}},"bytes":3195},"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-SCL6PT4P.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":3266},"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-SCL6PT4P.mjs":{"imports":[{"path":"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-PHTWWADN.mjs","kind":"import-statement"},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true}],"exports":["FileType","WnfsAction"],"inputs":{"packages/plugins/plugin-wnfs/src/types/file.ts":{"bytesInOutput":320},"packages/plugins/plugin-wnfs/src/types/index.ts":{"bytesInOutput":0},"packages/plugins/plugin-wnfs/src/types/types.ts":{"bytesInOutput":1197}},"bytes":1756},"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-PHTWWADN.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":711},"packages/plugins/plugin-wnfs/dist/lib/browser/chunk-PHTWWADN.mjs":{"imports":[],"exports":["WNFS_PLUGIN","meta"],"inputs":{"packages/plugins/plugin-wnfs/src/meta.ts":{"bytesInOutput":292}},"bytes":415}}}
|
|
1
|
+
{"inputs":{"src/meta.ts":{"bytes":1450,"imports":[],"format":"esm"},"src/capabilities/capabilities.ts":{"bytes":1924,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"src/helpers/common.ts":{"bytes":7602,"imports":[{"path":"multiformats/cid","kind":"import-statement","external":true},{"path":"multiformats/hashes/sha2","kind":"import-statement","external":true},{"path":"@dxos/crypto","kind":"import-statement","external":true}],"format":"esm"},"src/helpers/load.ts":{"bytes":8920,"imports":[{"path":"multiformats","kind":"import-statement","external":true},{"path":"uint8arrays","kind":"import-statement","external":true},{"path":"wnfs","kind":"import-statement","external":true},{"path":"src/helpers/common.ts","kind":"import-statement","original":"./common"}],"format":"esm"},"src/helpers/wnfs-url.ts":{"bytes":3325,"imports":[{"path":"src/helpers/common.ts","kind":"import-statement","original":"./common"}],"format":"esm"},"src/helpers/upload.ts":{"bytes":6683,"imports":[{"path":"multiformats","kind":"import-statement","external":true},{"path":"multiformats/codecs/raw","kind":"import-statement","external":true},{"path":"multiformats/hashes/sha2","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"src/helpers/common.ts","kind":"import-statement","original":"./common"},{"path":"src/helpers/load.ts","kind":"import-statement","original":"./load"},{"path":"src/helpers/wnfs-url.ts","kind":"import-statement","original":"./wnfs-url"}],"format":"esm"},"src/helpers/index.ts":{"bytes":711,"imports":[{"path":"src/helpers/common.ts","kind":"import-statement","original":"./common"},{"path":"src/helpers/load.ts","kind":"import-statement","original":"./load"},{"path":"src/helpers/upload.ts","kind":"import-statement","original":"./upload"},{"path":"src/helpers/wnfs-url.ts","kind":"import-statement","original":"./wnfs-url"}],"format":"esm"},"src/blockstore.ts":{"bytes":19247,"imports":[{"path":"@ipld/car","kind":"import-statement","external":true},{"path":"blockstore-core","kind":"import-statement","external":true},{"path":"blockstore-idb","kind":"import-statement","external":true},{"path":"debounce","kind":"import-statement","external":true},{"path":"idb-keyval","kind":"import-statement","external":true},{"path":"it-all","kind":"import-statement","external":true},{"path":"multiformats","kind":"import-statement","external":true},{"path":"uint8arrays","kind":"import-statement","external":true},{"path":"src/helpers/index.ts","kind":"import-statement","original":"./helpers"}],"format":"esm"},"src/capabilities/blockstore.ts":{"bytes":2513,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"src/capabilities/capabilities.ts","kind":"import-statement","original":"./capabilities"},{"path":"src/blockstore.ts","kind":"import-statement","original":"../blockstore"}],"format":"esm"},"src/types/file.ts":{"bytes":1640,"imports":[{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true}],"format":"esm"},"src/types/types.ts":{"bytes":4896,"imports":[{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"src/types/file.ts","kind":"import-statement","original":"./file"},{"path":"src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"src/types/index.ts":{"bytes":534,"imports":[{"path":"src/types/file.ts","kind":"import-statement","original":"./file"},{"path":"src/types/types.ts","kind":"import-statement","original":"./types"}],"format":"esm"},"src/capabilities/file-uploader.ts":{"bytes":3379,"imports":[{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true},{"path":"src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"src/capabilities/intent-resolver.ts":{"bytes":4458,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true},{"path":"src/capabilities/capabilities.ts","kind":"import-statement","original":"./capabilities"},{"path":"src/helpers/index.ts","kind":"import-statement","original":"../helpers"},{"path":"src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"src/extensions/image.tsx":{"bytes":21191,"imports":[{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dom/client","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-editor","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"src/helpers/index.ts","kind":"import-statement","original":"../helpers"}],"format":"esm"},"src/extensions/index.ts":{"bytes":459,"imports":[{"path":"src/extensions/image.tsx","kind":"import-statement","original":"./image"}],"format":"esm"},"src/capabilities/markdown.ts":{"bytes":3121,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-markdown","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"src/capabilities/capabilities.ts","kind":"import-statement","original":"./capabilities"},{"path":"src/extensions/index.ts","kind":"import-statement","original":"../extensions"}],"format":"esm"},"src/components/FileInput.tsx":{"bytes":5185,"imports":[{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dropzone","kind":"import-statement","external":true},{"path":"@dxos/effect","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"src/meta.ts","kind":"import-statement","original":"../meta"},{"path":"src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"src/components/FilePreview.tsx":{"bytes":3096,"imports":[{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"format":"esm"},"src/components/FileContainer.tsx":{"bytes":6373,"imports":[{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui-stack","kind":"import-statement","external":true},{"path":"src/components/FilePreview.tsx","kind":"import-statement","original":"./FilePreview"},{"path":"src/capabilities/index.ts","kind":"import-statement","original":"../capabilities"},{"path":"src/helpers/index.ts","kind":"import-statement","original":"../helpers"}],"format":"esm"},"src/components/index.ts":{"bytes":839,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"src/components/FileInput.tsx","kind":"import-statement","original":"./FileInput"},{"path":"src/components/FileContainer.tsx","kind":"dynamic-import","original":"./FileContainer"}],"format":"esm"},"src/capabilities/react-surface.tsx":{"bytes":5909,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true},{"path":"@dxos/effect","kind":"import-statement","external":true},{"path":"src/components/index.ts","kind":"import-statement","original":"../components"},{"path":"src/meta.ts","kind":"import-statement","original":"../meta"},{"path":"src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"src/capabilities/index.ts":{"bytes":1819,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/capabilities/capabilities.ts","kind":"import-statement","original":"./capabilities"},{"path":"src/capabilities/blockstore.ts","kind":"dynamic-import","original":"./blockstore"},{"path":"src/capabilities/file-uploader.ts","kind":"dynamic-import","original":"./file-uploader"},{"path":"src/capabilities/intent-resolver.ts","kind":"dynamic-import","original":"./intent-resolver"},{"path":"src/capabilities/markdown.ts","kind":"dynamic-import","original":"./markdown"},{"path":"src/capabilities/react-surface.tsx","kind":"dynamic-import","original":"./react-surface"}],"format":"esm"},"src/translations.ts":{"bytes":2001,"imports":[{"path":"src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"src/types/index.ts","kind":"import-statement","original":"./types"}],"format":"esm"},"src/WnfsPlugin.tsx":{"bytes":10988,"imports":[{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@dxos/plugin-markdown","kind":"import-statement","external":true},{"path":"@dxos/plugin-space","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true},{"path":"src/capabilities/index.ts","kind":"import-statement","original":"./capabilities"},{"path":"src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"src/translations.ts","kind":"import-statement","original":"./translations"},{"path":"src/types/index.ts","kind":"import-statement","original":"./types"}],"format":"esm"},"src/index.ts":{"bytes":724,"imports":[{"path":"src/capabilities/index.ts","kind":"import-statement","original":"./capabilities"},{"path":"src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"src/WnfsPlugin.tsx","kind":"import-statement","original":"./WnfsPlugin"}],"format":"esm"}},"outputs":{"dist/lib/browser/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":6291},"dist/lib/browser/index.mjs":{"imports":[{"path":"dist/lib/browser/chunk-BANMVVJV.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-KZANQHJY.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-GVBV2QWA.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-VDDGZWAY.mjs","kind":"import-statement"},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@dxos/plugin-markdown","kind":"import-statement","external":true},{"path":"@dxos/plugin-space","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true}],"exports":["WNFS_PLUGIN","WnfsCapabilities","WnfsPlugin","meta"],"entryPoint":"src/index.ts","inputs":{"src/index.ts":{"bytesInOutput":0},"src/WnfsPlugin.tsx":{"bytesInOutput":2372},"src/translations.ts":{"bytesInOutput":351}},"bytes":3197},"dist/lib/browser/types/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":93},"dist/lib/browser/types/index.mjs":{"imports":[{"path":"dist/lib/browser/chunk-GVBV2QWA.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-VDDGZWAY.mjs","kind":"import-statement"}],"exports":["FileType","WnfsAction"],"entryPoint":"src/types/index.ts","inputs":{},"bytes":170},"dist/lib/browser/blockstore-KQO2NTVM.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":10739},"dist/lib/browser/blockstore-KQO2NTVM.mjs":{"imports":[{"path":"dist/lib/browser/chunk-VRRXG6IB.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-KZANQHJY.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-VDDGZWAY.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@ipld/car","kind":"import-statement","external":true},{"path":"blockstore-core","kind":"import-statement","external":true},{"path":"blockstore-idb","kind":"import-statement","external":true},{"path":"debounce","kind":"import-statement","external":true},{"path":"idb-keyval","kind":"import-statement","external":true},{"path":"it-all","kind":"import-statement","external":true},{"path":"multiformats","kind":"import-statement","external":true},{"path":"uint8arrays","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/blockstore.ts","inputs":{"src/capabilities/blockstore.ts":{"bytesInOutput":449},"src/blockstore.ts":{"bytesInOutput":4273}},"bytes":5049},"dist/lib/browser/file-uploader-JA55DPMW.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1829},"dist/lib/browser/file-uploader-JA55DPMW.mjs":{"imports":[{"path":"dist/lib/browser/chunk-GVBV2QWA.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-VDDGZWAY.mjs","kind":"import-statement"},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/file-uploader.ts","inputs":{"src/capabilities/file-uploader.ts":{"bytesInOutput":742}},"bytes":963},"dist/lib/browser/intent-resolver-YM6QRFIH.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":2095},"dist/lib/browser/intent-resolver-YM6QRFIH.mjs":{"imports":[{"path":"dist/lib/browser/chunk-VRRXG6IB.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-KZANQHJY.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-GVBV2QWA.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-VDDGZWAY.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/intent-resolver.ts","inputs":{"src/capabilities/intent-resolver.ts":{"bytesInOutput":918}},"bytes":1265},"dist/lib/browser/markdown-6VH477GB.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":12475},"dist/lib/browser/markdown-6VH477GB.mjs":{"imports":[{"path":"dist/lib/browser/chunk-VRRXG6IB.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-KZANQHJY.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-VDDGZWAY.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-markdown","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@codemirror/language","kind":"import-statement","external":true},{"path":"@codemirror/state","kind":"import-statement","external":true},{"path":"@codemirror/view","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dom/client","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-editor","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/markdown.ts","inputs":{"src/capabilities/markdown.ts":{"bytesInOutput":643},"src/extensions/image.tsx":{"bytesInOutput":4786},"src/extensions/index.ts":{"bytesInOutput":0}},"bytes":5786},"dist/lib/browser/FileContainer-Q4GUPBVD.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":4410},"dist/lib/browser/FileContainer-Q4GUPBVD.mjs":{"imports":[{"path":"dist/lib/browser/chunk-BANMVVJV.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-VRRXG6IB.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-KZANQHJY.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-VDDGZWAY.mjs","kind":"import-statement"},{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui-stack","kind":"import-statement","external":true},{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"exports":["FileContainer","default"],"entryPoint":"src/components/FileContainer.tsx","inputs":{"src/components/FileContainer.tsx":{"bytesInOutput":1754},"src/components/FilePreview.tsx":{"bytesInOutput":863}},"bytes":3051},"dist/lib/browser/chunk-BANMVVJV.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":909},"dist/lib/browser/chunk-BANMVVJV.mjs":{"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"dist/lib/browser/blockstore-KQO2NTVM.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/file-uploader-JA55DPMW.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/intent-resolver-YM6QRFIH.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/markdown-6VH477GB.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/react-surface-XAHVMWIH.mjs","kind":"dynamic-import"}],"exports":["Blockstore","FileUploader","IntentResolver","Markdown","ReactSurface"],"inputs":{"src/capabilities/index.ts":{"bytesInOutput":389}},"bytes":550},"dist/lib/browser/chunk-VRRXG6IB.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":13383},"dist/lib/browser/chunk-VRRXG6IB.mjs":{"imports":[{"path":"multiformats/cid","kind":"import-statement","external":true},{"path":"multiformats/hashes/sha2","kind":"import-statement","external":true},{"path":"@dxos/crypto","kind":"import-statement","external":true},{"path":"multiformats","kind":"import-statement","external":true},{"path":"uint8arrays","kind":"import-statement","external":true},{"path":"wnfs","kind":"import-statement","external":true},{"path":"multiformats","kind":"import-statement","external":true},{"path":"multiformats/codecs/raw","kind":"import-statement","external":true},{"path":"multiformats/hashes/sha2","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true}],"exports":["filePath","getBlobUrl","getPathFromUrl","loadWnfs","storeName","upload","wnfsUrl"],"inputs":{"src/helpers/common.ts":{"bytesInOutput":1077},"src/helpers/load.ts":{"bytesInOutput":1918},"src/helpers/wnfs-url.ts":{"bytesInOutput":567},"src/helpers/upload.ts":{"bytesInOutput":1268},"src/helpers/index.ts":{"bytesInOutput":0}},"bytes":5079},"dist/lib/browser/chunk-KZANQHJY.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1040},"dist/lib/browser/chunk-KZANQHJY.mjs":{"imports":[{"path":"dist/lib/browser/chunk-VDDGZWAY.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true}],"exports":["WnfsCapabilities"],"inputs":{"src/capabilities/capabilities.ts":{"bytesInOutput":338}},"bytes":505},"dist/lib/browser/react-surface-XAHVMWIH.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":5915},"dist/lib/browser/react-surface-XAHVMWIH.mjs":{"imports":[{"path":"dist/lib/browser/chunk-GVBV2QWA.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-VDDGZWAY.mjs","kind":"import-statement"},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true},{"path":"@dxos/effect","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dropzone","kind":"import-statement","external":true},{"path":"@dxos/effect","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"dist/lib/browser/FileContainer-Q4GUPBVD.mjs","kind":"dynamic-import"}],"exports":["default"],"entryPoint":"src/capabilities/react-surface.tsx","inputs":{"src/capabilities/react-surface.tsx":{"bytesInOutput":1243},"src/components/index.ts":{"bytesInOutput":102},"src/components/FileInput.tsx":{"bytesInOutput":1320}},"bytes":3050},"dist/lib/browser/chunk-GVBV2QWA.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":3266},"dist/lib/browser/chunk-GVBV2QWA.mjs":{"imports":[{"path":"dist/lib/browser/chunk-VDDGZWAY.mjs","kind":"import-statement"},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true}],"exports":["FileType","WnfsAction"],"inputs":{"src/types/file.ts":{"bytesInOutput":320},"src/types/index.ts":{"bytesInOutput":0},"src/types/types.ts":{"bytesInOutput":1197}},"bytes":1698},"dist/lib/browser/chunk-VDDGZWAY.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":711},"dist/lib/browser/chunk-VDDGZWAY.mjs":{"imports":[],"exports":["WNFS_PLUGIN","meta"],"inputs":{"src/meta.ts":{"bytesInOutput":292}},"bytes":386}}}
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import {
|
|
2
2
|
FileType,
|
|
3
3
|
WnfsAction
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-GVBV2QWA.mjs";
|
|
5
5
|
import {
|
|
6
6
|
WNFS_PLUGIN
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-VDDGZWAY.mjs";
|
|
8
8
|
|
|
9
|
-
//
|
|
9
|
+
// src/capabilities/react-surface.tsx
|
|
10
10
|
import React2, { useCallback as useCallback2 } from "react";
|
|
11
11
|
import { contributes, Capabilities, createSurface } from "@dxos/app-framework";
|
|
12
12
|
import { Obj } from "@dxos/echo";
|
|
13
13
|
import { findAnnotation as findAnnotation2 } from "@dxos/effect";
|
|
14
14
|
|
|
15
|
-
//
|
|
15
|
+
// src/components/index.ts
|
|
16
16
|
import { lazy } from "react";
|
|
17
17
|
|
|
18
|
-
//
|
|
18
|
+
// src/components/FileInput.tsx
|
|
19
19
|
import { useSignals as _useSignals } from "@preact-signals/safe-react/tracking";
|
|
20
20
|
import React, { useCallback } from "react";
|
|
21
21
|
import { useDropzone } from "react-dropzone";
|
|
@@ -44,10 +44,10 @@ var FileInput = ({ schema, onChange }) => {
|
|
|
44
44
|
}
|
|
45
45
|
};
|
|
46
46
|
|
|
47
|
-
//
|
|
48
|
-
var FileContainer = lazy(() => import("./FileContainer-
|
|
47
|
+
// src/components/index.ts
|
|
48
|
+
var FileContainer = lazy(() => import("./FileContainer-Q4GUPBVD.mjs"));
|
|
49
49
|
|
|
50
|
-
//
|
|
50
|
+
// src/capabilities/react-surface.tsx
|
|
51
51
|
var react_surface_default = () => contributes(Capabilities.ReactSurface, [
|
|
52
52
|
createSurface({
|
|
53
53
|
id: `${WNFS_PLUGIN}/article`,
|
|
@@ -85,4 +85,4 @@ var react_surface_default = () => contributes(Capabilities.ReactSurface, [
|
|
|
85
85
|
export {
|
|
86
86
|
react_surface_default as default
|
|
87
87
|
};
|
|
88
|
-
//# sourceMappingURL=react-surface-
|
|
88
|
+
//# sourceMappingURL=react-surface-XAHVMWIH.mjs.map
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
|
|
2
|
+
import "./chunk-DWYM7FD7.mjs";
|
|
3
|
+
import {
|
|
4
|
+
filePath,
|
|
5
|
+
getBlobUrl,
|
|
6
|
+
loadWnfs,
|
|
7
|
+
wnfsUrl
|
|
8
|
+
} from "./chunk-CGW32EZB.mjs";
|
|
9
|
+
import {
|
|
10
|
+
WnfsCapabilities
|
|
11
|
+
} from "./chunk-YTWL64Z6.mjs";
|
|
12
|
+
import "./chunk-47QYKNA6.mjs";
|
|
13
|
+
|
|
14
|
+
// src/components/FileContainer.tsx
|
|
15
|
+
import { useSignals as _useSignals2 } from "@preact-signals/safe-react/tracking";
|
|
16
|
+
import React2, { useEffect, useState } from "react";
|
|
17
|
+
import { useCapability } from "@dxos/app-framework";
|
|
18
|
+
import { invariant } from "@dxos/invariant";
|
|
19
|
+
import { getSpace } from "@dxos/react-client/echo";
|
|
20
|
+
import { StackItem } from "@dxos/react-ui-stack";
|
|
21
|
+
|
|
22
|
+
// src/components/FilePreview.tsx
|
|
23
|
+
import { useSignals as _useSignals } from "@preact-signals/safe-react/tracking";
|
|
24
|
+
import React from "react";
|
|
25
|
+
import { mx } from "@dxos/react-ui-theme";
|
|
26
|
+
var FilePreview = ({ type, url, classNames }) => {
|
|
27
|
+
var _effect = _useSignals();
|
|
28
|
+
try {
|
|
29
|
+
if (type.startsWith("image/")) {
|
|
30
|
+
return /* @__PURE__ */ React.createElement("img", {
|
|
31
|
+
className: mx("w-full h-full object-contain", classNames),
|
|
32
|
+
src: url
|
|
33
|
+
});
|
|
34
|
+
} else if (type.startsWith("video/")) {
|
|
35
|
+
return /* @__PURE__ */ React.createElement("video", {
|
|
36
|
+
className: mx("w-full h-full object-contain", classNames),
|
|
37
|
+
src: url,
|
|
38
|
+
controls: true
|
|
39
|
+
});
|
|
40
|
+
} else {
|
|
41
|
+
return /* @__PURE__ */ React.createElement("iframe", {
|
|
42
|
+
className: mx("w-full h-full overflow-auto", classNames),
|
|
43
|
+
src: url
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
} finally {
|
|
47
|
+
_effect.f();
|
|
48
|
+
}
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
// src/components/FileContainer.tsx
|
|
52
|
+
var __dxlog_file = "/__w/dxos/dxos/packages/plugins/plugin-wnfs/src/components/FileContainer.tsx";
|
|
53
|
+
var FileContainer = ({ role, file }) => {
|
|
54
|
+
var _effect = _useSignals2();
|
|
55
|
+
try {
|
|
56
|
+
const blockstore = useCapability(WnfsCapabilities.Blockstore);
|
|
57
|
+
const instances = useCapability(WnfsCapabilities.Instances);
|
|
58
|
+
const [blobUrl, setBlobUrl] = useState();
|
|
59
|
+
useEffect(() => {
|
|
60
|
+
const timeout = setTimeout(async () => {
|
|
61
|
+
const space = getSpace(file);
|
|
62
|
+
invariant(space, void 0, {
|
|
63
|
+
F: __dxlog_file,
|
|
64
|
+
L: 30,
|
|
65
|
+
S: void 0,
|
|
66
|
+
A: [
|
|
67
|
+
"space",
|
|
68
|
+
""
|
|
69
|
+
]
|
|
70
|
+
});
|
|
71
|
+
const { directory, forest } = await loadWnfs({
|
|
72
|
+
blockstore,
|
|
73
|
+
instances,
|
|
74
|
+
space
|
|
75
|
+
});
|
|
76
|
+
const path = filePath(file.cid.toString(), space);
|
|
77
|
+
const url = await getBlobUrl({
|
|
78
|
+
wnfsUrl: wnfsUrl(path),
|
|
79
|
+
blockstore,
|
|
80
|
+
directory,
|
|
81
|
+
forest,
|
|
82
|
+
type: file.type
|
|
83
|
+
});
|
|
84
|
+
setBlobUrl(url);
|
|
85
|
+
});
|
|
86
|
+
return () => clearTimeout(timeout);
|
|
87
|
+
}, [
|
|
88
|
+
file
|
|
89
|
+
]);
|
|
90
|
+
if (!blobUrl) {
|
|
91
|
+
return null;
|
|
92
|
+
}
|
|
93
|
+
return /* @__PURE__ */ React2.createElement(StackItem.Content, {
|
|
94
|
+
role
|
|
95
|
+
}, /* @__PURE__ */ React2.createElement(FilePreview, {
|
|
96
|
+
type: file.type,
|
|
97
|
+
url: blobUrl
|
|
98
|
+
}));
|
|
99
|
+
} finally {
|
|
100
|
+
_effect.f();
|
|
101
|
+
}
|
|
102
|
+
};
|
|
103
|
+
var FileContainer_default = FileContainer;
|
|
104
|
+
export {
|
|
105
|
+
FileContainer,
|
|
106
|
+
FileContainer_default as default
|
|
107
|
+
};
|
|
108
|
+
//# sourceMappingURL=FileContainer-22IPNDDA.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/components/FileContainer.tsx", "../../../src/components/FilePreview.tsx"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport React, { useEffect, useState } from 'react';\n\nimport { useCapability } from '@dxos/app-framework';\nimport { invariant } from '@dxos/invariant';\nimport { getSpace } from '@dxos/react-client/echo';\nimport { StackItem } from '@dxos/react-ui-stack';\n\nimport { FilePreview } from './FilePreview';\nimport { WnfsCapabilities } from '../capabilities';\nimport { filePath, getBlobUrl, loadWnfs, wnfsUrl } from '../helpers';\nimport { type FileType } from '../types';\n\nexport type FileContainerProps = {\n role: string;\n file: FileType;\n};\n\nexport const FileContainer = ({ role, file }: FileContainerProps) => {\n const blockstore = useCapability(WnfsCapabilities.Blockstore);\n const instances = useCapability(WnfsCapabilities.Instances);\n const [blobUrl, setBlobUrl] = useState<string>();\n\n useEffect(() => {\n const timeout = setTimeout(async () => {\n const space = getSpace(file);\n invariant(space);\n const { directory, forest } = await loadWnfs({ blockstore, instances, space });\n const path = filePath(file.cid.toString(), space);\n const url = await getBlobUrl({ wnfsUrl: wnfsUrl(path), blockstore, directory, forest, type: file.type });\n setBlobUrl(url);\n });\n\n return () => clearTimeout(timeout);\n }, [file]);\n\n if (!blobUrl) {\n return null;\n }\n\n return (\n <StackItem.Content role={role}>\n <FilePreview type={file.type} url={blobUrl} />\n </StackItem.Content>\n );\n};\n\nexport default FileContainer;\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport React from 'react';\n\nimport { type ThemedClassName } from '@dxos/react-ui';\nimport { mx } from '@dxos/react-ui-theme';\n\nexport type FilePreviewProps = ThemedClassName<{ type: string; url: string }>;\n\n/**\n * File/content preview iframe.\n */\nexport const FilePreview = ({ type, url, classNames }: FilePreviewProps) => {\n if (type.startsWith('image/')) {\n return <img className={mx('w-full h-full object-contain', classNames)} src={url} />;\n } else if (type.startsWith('video/')) {\n return <video className={mx('w-full h-full object-contain', classNames)} src={url} controls />;\n } else {\n return <iframe className={mx('w-full h-full overflow-auto', classNames)} src={url} />;\n }\n};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;AAIA,OAAOA,UAASC,WAAWC,gBAAgB;AAE3C,SAASC,qBAAqB;AAC9B,SAASC,iBAAiB;AAC1B,SAASC,gBAAgB;AACzB,SAASC,iBAAiB;;;;ACL1B,OAAOC,WAAW;AAGlB,SAASC,UAAU;AAOZ,IAAMC,cAAc,CAAC,EAAEC,MAAMC,KAAKC,WAAU,MAAoB;;;AACrE,QAAIF,KAAKG,WAAW,QAAA,GAAW;AAC7B,aAAO,sBAAA,cAACC,OAAAA;QAAIC,WAAWC,GAAG,gCAAgCJ,UAAAA;QAAaK,KAAKN;;IAC9E,WAAWD,KAAKG,WAAW,QAAA,GAAW;AACpC,aAAO,sBAAA,cAACK,SAAAA;QAAMH,WAAWC,GAAG,gCAAgCJ,UAAAA;QAAaK,KAAKN;QAAKQ,UAAAA;;IACrF,OAAO;AACL,aAAO,sBAAA,cAACC,UAAAA;QAAOL,WAAWC,GAAG,+BAA+BJ,UAAAA;QAAaK,KAAKN;;IAChF;;;;AACF;;;;ADDO,IAAMU,gBAAgB,CAAC,EAAEC,MAAMC,KAAI,MAAsB;;;AAC9D,UAAMC,aAAaC,cAAcC,iBAAiBC,UAAU;AAC5D,UAAMC,YAAYH,cAAcC,iBAAiBG,SAAS;AAC1D,UAAM,CAACC,SAASC,UAAAA,IAAcC,SAAAA;AAE9BC,cAAU,MAAA;AACR,YAAMC,UAAUC,WAAW,YAAA;AACzB,cAAMC,QAAQC,SAASd,IAAAA;AACvBe,kBAAUF,OAAAA,QAAAA;;;;;;;;;AACV,cAAM,EAAEG,WAAWC,OAAM,IAAK,MAAMC,SAAS;UAAEjB;UAAYI;UAAWQ;QAAM,CAAA;AAC5E,cAAMM,OAAOC,SAASpB,KAAKqB,IAAIC,SAAQ,GAAIT,KAAAA;AAC3C,cAAMU,MAAM,MAAMC,WAAW;UAAEC,SAASA,QAAQN,IAAAA;UAAOlB;UAAYe;UAAWC;UAAQS,MAAM1B,KAAK0B;QAAK,CAAA;AACtGlB,mBAAWe,GAAAA;MACb,CAAA;AAEA,aAAO,MAAMI,aAAahB,OAAAA;IAC5B,GAAG;MAACX;KAAK;AAET,QAAI,CAACO,SAAS;AACZ,aAAO;IACT;AAEA,WACE,gBAAAqB,OAAA,cAACC,UAAUC,SAAO;MAAC/B;OACjB,gBAAA6B,OAAA,cAACG,aAAAA;MAAYL,MAAM1B,KAAK0B;MAAMH,KAAKhB;;;;;AAGzC;AAEA,IAAA,wBAAeT;",
|
|
6
|
+
"names": ["React", "useEffect", "useState", "useCapability", "invariant", "getSpace", "StackItem", "React", "mx", "FilePreview", "type", "url", "classNames", "startsWith", "img", "className", "mx", "src", "video", "controls", "iframe", "FileContainer", "role", "file", "blockstore", "useCapability", "WnfsCapabilities", "Blockstore", "instances", "Instances", "blobUrl", "setBlobUrl", "useState", "useEffect", "timeout", "setTimeout", "space", "getSpace", "invariant", "directory", "forest", "loadWnfs", "path", "filePath", "cid", "toString", "url", "getBlobUrl", "wnfsUrl", "type", "clearTimeout", "React", "StackItem", "Content", "FilePreview"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
|
|
2
|
+
import {
|
|
3
|
+
storeName
|
|
4
|
+
} from "./chunk-CGW32EZB.mjs";
|
|
5
|
+
import {
|
|
6
|
+
WnfsCapabilities
|
|
7
|
+
} from "./chunk-YTWL64Z6.mjs";
|
|
8
|
+
import "./chunk-47QYKNA6.mjs";
|
|
9
|
+
|
|
10
|
+
// src/capabilities/blockstore.ts
|
|
11
|
+
import { contributes } from "@dxos/app-framework";
|
|
12
|
+
import { ClientCapabilities } from "@dxos/plugin-client";
|
|
13
|
+
|
|
14
|
+
// src/blockstore.ts
|
|
15
|
+
import { CarWriter } from "@ipld/car";
|
|
16
|
+
import { BaseBlockstore } from "blockstore-core";
|
|
17
|
+
import { IDBBlockstore } from "blockstore-idb";
|
|
18
|
+
import debounce from "debounce";
|
|
19
|
+
import * as IDB from "idb-keyval";
|
|
20
|
+
import all from "it-all";
|
|
21
|
+
import { CID } from "multiformats";
|
|
22
|
+
import * as Uint8Arrays from "uint8arrays";
|
|
23
|
+
var create = (apiHost) => {
|
|
24
|
+
return new MixedBlockstore(apiHost);
|
|
25
|
+
};
|
|
26
|
+
var MixedBlockstore = class extends BaseBlockstore {
|
|
27
|
+
constructor(apiHost) {
|
|
28
|
+
super();
|
|
29
|
+
// QUEUE
|
|
30
|
+
this.queueCacheName = `${storeName()}/state/queue`;
|
|
31
|
+
this.#apiHost = apiHost ? apiHost.replace(/\/?$/, "") : void 0;
|
|
32
|
+
this.#localStore = new IDBBlockstore(storeName());
|
|
33
|
+
this.#isConnected = navigator.onLine;
|
|
34
|
+
this.#queue = [];
|
|
35
|
+
this.#flushQueue = debounce(this.#flushQueueInt, 5e3);
|
|
36
|
+
}
|
|
37
|
+
#apiHost;
|
|
38
|
+
#localStore;
|
|
39
|
+
#isConnected;
|
|
40
|
+
#flushQueue;
|
|
41
|
+
#queue;
|
|
42
|
+
async open() {
|
|
43
|
+
await this.#localStore.open();
|
|
44
|
+
await this.#restoreQueue();
|
|
45
|
+
window.addEventListener("offline", async () => {
|
|
46
|
+
this.#isConnected = false;
|
|
47
|
+
});
|
|
48
|
+
window.addEventListener("online", async () => {
|
|
49
|
+
this.#isConnected = true;
|
|
50
|
+
this.#flushQueue();
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
url(apiHost, cid) {
|
|
54
|
+
const path = cid ? cid.toString() : "";
|
|
55
|
+
return `${apiHost}/api/file${path.length ? "/" + path : ""}`;
|
|
56
|
+
}
|
|
57
|
+
// BLOCKSTORE IMPLEMENTATION
|
|
58
|
+
async delete(key) {
|
|
59
|
+
await this.#localStore.delete(key);
|
|
60
|
+
if (this.#isConnected && this.#apiHost) {
|
|
61
|
+
await fetch(this.url(this.#apiHost, key), {
|
|
62
|
+
method: "DELETE"
|
|
63
|
+
});
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
async get(key) {
|
|
67
|
+
if (await this.#localStore.has(key)) {
|
|
68
|
+
return await this.#localStore.get(key);
|
|
69
|
+
}
|
|
70
|
+
if (this.#isConnected && this.#apiHost) {
|
|
71
|
+
const block = await fetch(this.url(this.#apiHost, key), {
|
|
72
|
+
method: "GET"
|
|
73
|
+
}).then((r) => r.arrayBuffer()).then((r) => new Uint8Array(r));
|
|
74
|
+
await this.#localStore.put(key, block);
|
|
75
|
+
return block;
|
|
76
|
+
}
|
|
77
|
+
return await this.#localStore.get(key);
|
|
78
|
+
}
|
|
79
|
+
async has(key) {
|
|
80
|
+
if (await this.#localStore.has(key)) {
|
|
81
|
+
return true;
|
|
82
|
+
}
|
|
83
|
+
if (this.#isConnected && this.#apiHost) {
|
|
84
|
+
return await fetch(this.url(this.#apiHost, key), {
|
|
85
|
+
method: "HEAD"
|
|
86
|
+
}).then((r) => r.ok);
|
|
87
|
+
}
|
|
88
|
+
return false;
|
|
89
|
+
}
|
|
90
|
+
async put(key, val) {
|
|
91
|
+
await this.#localStore.put(key, val);
|
|
92
|
+
await this.#addToQueue(key);
|
|
93
|
+
this.#flushQueue();
|
|
94
|
+
return key;
|
|
95
|
+
}
|
|
96
|
+
async destroy() {
|
|
97
|
+
await this.#localStore.destroy();
|
|
98
|
+
}
|
|
99
|
+
// REMOTE
|
|
100
|
+
async putRemote(key, val) {
|
|
101
|
+
if (this.#apiHost) {
|
|
102
|
+
await fetch(this.url(this.#apiHost, key), {
|
|
103
|
+
method: "POST",
|
|
104
|
+
body: val
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
async putCarRemote(car) {
|
|
109
|
+
if (this.#apiHost) {
|
|
110
|
+
await fetch(this.url(this.#apiHost), {
|
|
111
|
+
method: "POST",
|
|
112
|
+
headers: {
|
|
113
|
+
"Content-Type": "application/vnd.ipld.car"
|
|
114
|
+
},
|
|
115
|
+
body: car
|
|
116
|
+
});
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
async #addToQueue(key) {
|
|
120
|
+
await this.#saveQueue([
|
|
121
|
+
...this.#queue,
|
|
122
|
+
key.toString()
|
|
123
|
+
]);
|
|
124
|
+
}
|
|
125
|
+
async #flushQueueInt() {
|
|
126
|
+
if (!this.#isConnected || !this.#apiHost) {
|
|
127
|
+
return;
|
|
128
|
+
}
|
|
129
|
+
const keys = [
|
|
130
|
+
...this.#queue
|
|
131
|
+
];
|
|
132
|
+
if (keys.length === 0) {
|
|
133
|
+
return;
|
|
134
|
+
}
|
|
135
|
+
const blocks = await Promise.all(keys.map(async (key) => {
|
|
136
|
+
const cid = CID.parse(key);
|
|
137
|
+
const bytes = await this.#localStore.get(cid);
|
|
138
|
+
return {
|
|
139
|
+
cid,
|
|
140
|
+
bytes
|
|
141
|
+
};
|
|
142
|
+
}));
|
|
143
|
+
const car = await this.#createCar(blocks);
|
|
144
|
+
await this.putCarRemote(car);
|
|
145
|
+
const queue = [
|
|
146
|
+
...this.#queue
|
|
147
|
+
].filter((k) => {
|
|
148
|
+
if (keys.includes(k)) {
|
|
149
|
+
return false;
|
|
150
|
+
}
|
|
151
|
+
return true;
|
|
152
|
+
});
|
|
153
|
+
await this.#saveQueue(queue);
|
|
154
|
+
}
|
|
155
|
+
async #restoreQueue() {
|
|
156
|
+
const fromCache = await IDB.get(this.queueCacheName);
|
|
157
|
+
if (fromCache && Array.isArray(fromCache)) {
|
|
158
|
+
this.#queue = fromCache;
|
|
159
|
+
this.#flushQueue();
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
async #saveQueue(items) {
|
|
163
|
+
const arr = [
|
|
164
|
+
...items
|
|
165
|
+
];
|
|
166
|
+
this.#queue = arr;
|
|
167
|
+
await IDB.set(this.queueCacheName, arr);
|
|
168
|
+
}
|
|
169
|
+
// 🛠️
|
|
170
|
+
async #createCar(blocks) {
|
|
171
|
+
const { writer, out } = CarWriter.create();
|
|
172
|
+
const outPromise = all(out);
|
|
173
|
+
await Promise.all(blocks.map((block) => {
|
|
174
|
+
return writer.put(block);
|
|
175
|
+
}));
|
|
176
|
+
await writer.close();
|
|
177
|
+
return Uint8Arrays.concat(await outPromise);
|
|
178
|
+
}
|
|
179
|
+
};
|
|
180
|
+
|
|
181
|
+
// src/capabilities/blockstore.ts
|
|
182
|
+
var blockstore_default = async (context) => {
|
|
183
|
+
const client = context.getCapability(ClientCapabilities.Client);
|
|
184
|
+
const apiHost = client.config.values.runtime?.services?.edge?.url || "http://localhost:8787";
|
|
185
|
+
const blockstore = create(apiHost);
|
|
186
|
+
await blockstore.open();
|
|
187
|
+
return contributes(WnfsCapabilities.Blockstore, blockstore);
|
|
188
|
+
};
|
|
189
|
+
export {
|
|
190
|
+
blockstore_default as default
|
|
191
|
+
};
|
|
192
|
+
//# sourceMappingURL=blockstore-7KQTFHK5.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/capabilities/blockstore.ts", "../../../src/blockstore.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { contributes, type PluginContext } from '@dxos/app-framework';\nimport { ClientCapabilities } from '@dxos/plugin-client';\n\nimport { WnfsCapabilities } from './capabilities';\nimport * as Blockstore from '../blockstore';\n\nexport default async (context: PluginContext) => {\n const client = context.getCapability(ClientCapabilities.Client);\n const apiHost = client.config.values.runtime?.services?.edge?.url || 'http://localhost:8787';\n const blockstore = Blockstore.create(apiHost);\n await blockstore.open();\n\n return contributes(WnfsCapabilities.Blockstore, blockstore);\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport { CarWriter } from '@ipld/car';\nimport type { Block } from '@ipld/car/reader';\nimport { BaseBlockstore } from 'blockstore-core';\nimport { IDBBlockstore } from 'blockstore-idb';\nimport debounce from 'debounce';\nimport * as IDB from 'idb-keyval';\nimport all from 'it-all';\nimport { CID } from 'multiformats';\nimport * as Uint8Arrays from 'uint8arrays';\n\nimport { storeName } from './helpers';\n\nexport const create = (apiHost?: string) => {\n return new MixedBlockstore(apiHost);\n};\n\n/**\n * A blockstore that communicates with the DXOS blob service,\n * and which uses an indexedDB blockstore as a client cache.\n */\nexport class MixedBlockstore extends BaseBlockstore {\n readonly #apiHost: string | undefined;\n readonly #localStore: IDBBlockstore;\n\n #isConnected: boolean;\n #flushQueue: () => void;\n #queue: string[];\n\n constructor(apiHost?: string) {\n super();\n\n this.#apiHost = apiHost ? apiHost.replace(/\\/?$/, '') : undefined;\n this.#localStore = new IDBBlockstore(storeName());\n this.#isConnected = navigator.onLine;\n this.#queue = [];\n\n this.#flushQueue = debounce(this.#flushQueueInt, 5000);\n }\n\n async open(): Promise<void> {\n await this.#localStore.open();\n await this.#restoreQueue();\n\n window.addEventListener('offline', async () => {\n this.#isConnected = false;\n });\n\n window.addEventListener('online', async () => {\n this.#isConnected = true;\n this.#flushQueue();\n });\n }\n\n url(apiHost: string, cid?: CID): string {\n const path = cid ? cid.toString() : '';\n return `${apiHost}/api/file${path.length ? '/' + path : ''}`;\n }\n\n // BLOCKSTORE IMPLEMENTATION\n\n override async delete(key: CID): Promise<void> {\n await this.#localStore.delete(key);\n\n if (this.#isConnected && this.#apiHost) {\n await fetch(this.url(this.#apiHost, key), {\n method: 'DELETE',\n });\n }\n }\n\n override async get(key: CID): Promise<Uint8Array> {\n if (await this.#localStore.has(key)) {\n return await this.#localStore.get(key);\n }\n\n if (this.#isConnected && this.#apiHost) {\n const block = await fetch(this.url(this.#apiHost, key), {\n method: 'GET',\n })\n .then((r) => r.arrayBuffer())\n .then((r) => new Uint8Array(r));\n\n // Make sure it is cached locally\n await this.#localStore.put(key, block);\n\n return block;\n }\n\n return await this.#localStore.get(key);\n }\n\n override async has(key: CID): Promise<boolean> {\n if (await this.#localStore.has(key)) {\n return true;\n }\n\n if (this.#isConnected && this.#apiHost) {\n return await fetch(this.url(this.#apiHost, key), {\n method: 'HEAD',\n }).then((r) => r.ok);\n }\n\n return false;\n }\n\n override async put(key: CID, val: Uint8Array): Promise<CID> {\n await this.#localStore.put(key, val);\n\n await this.#addToQueue(key);\n this.#flushQueue();\n\n return key;\n }\n\n async destroy(): Promise<void> {\n await this.#localStore.destroy();\n }\n\n // REMOTE\n\n async putRemote(key: CID, val: Uint8Array): Promise<void> {\n if (this.#apiHost) {\n await fetch(this.url(this.#apiHost, key), {\n method: 'POST',\n body: val,\n });\n }\n }\n\n async putCarRemote(car: Uint8Array): Promise<void> {\n if (this.#apiHost) {\n await fetch(this.url(this.#apiHost), {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/vnd.ipld.car',\n },\n body: car,\n });\n }\n }\n\n // QUEUE\n\n readonly queueCacheName = `${storeName()}/state/queue`;\n\n async #addToQueue(key: CID): Promise<void> {\n await this.#saveQueue([...this.#queue, key.toString()]);\n }\n\n async #flushQueueInt(): Promise<void> {\n if (!this.#isConnected || !this.#apiHost) {\n return;\n }\n\n const keys = [...this.#queue];\n if (keys.length === 0) {\n return;\n }\n\n // Collect blocks\n const blocks = await Promise.all(\n keys.map(async (key) => {\n const cid = CID.parse(key);\n const bytes = await this.#localStore.get(cid);\n return { cid, bytes };\n }),\n );\n\n // Create & submit CAR\n const car = await this.#createCar(blocks);\n await this.putCarRemote(car);\n\n // Adjust queue\n const queue = [...this.#queue].filter((k) => {\n if (keys.includes(k)) {\n return false;\n }\n\n return true;\n });\n\n await this.#saveQueue(queue);\n }\n\n async #restoreQueue(): Promise<void> {\n const fromCache = await IDB.get(this.queueCacheName);\n if (fromCache && Array.isArray(fromCache)) {\n this.#queue = fromCache;\n this.#flushQueue();\n }\n }\n\n async #saveQueue(items: string[]): Promise<void> {\n const arr = [...items];\n this.#queue = arr;\n await IDB.set(this.queueCacheName, arr);\n }\n\n // 🛠️\n\n async #createCar(blocks: Block[]): Promise<Uint8Array> {\n const { writer, out } = CarWriter.create();\n const outPromise = all(out);\n\n await Promise.all(\n blocks.map((block) => {\n return writer.put(block);\n }),\n );\n\n await writer.close();\n return Uint8Arrays.concat(await outPromise);\n }\n}\n"],
|
|
5
|
+
"mappings": "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",
|
|
6
|
+
"names": ["contributes", "ClientCapabilities", "CarWriter", "BaseBlockstore", "IDBBlockstore", "debounce", "IDB", "all", "CID", "Uint8Arrays", "create", "apiHost", "MixedBlockstore", "BaseBlockstore", "queueCacheName", "storeName", "replace", "undefined", "IDBBlockstore", "navigator", "onLine", "debounce", "open", "window", "addEventListener", "url", "cid", "path", "toString", "length", "delete", "key", "fetch", "method", "get", "has", "block", "then", "r", "arrayBuffer", "Uint8Array", "put", "ok", "val", "destroy", "putRemote", "body", "putCarRemote", "car", "headers", "keys", "blocks", "Promise", "all", "map", "CID", "parse", "bytes", "queue", "filter", "k", "includes", "fromCache", "Array", "isArray", "items", "arr", "set", "writer", "out", "CarWriter", "outPromise", "close", "concat", "context", "client", "getCapability", "ClientCapabilities", "Client", "apiHost", "config", "values", "runtime", "services", "edge", "url", "blockstore", "create", "open", "contributes", "WnfsCapabilities", "Blockstore"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
|
|
2
|
+
|
|
3
|
+
// src/meta.ts
|
|
4
|
+
var WNFS_PLUGIN = "dxos.org/plugin/wnfs";
|
|
5
|
+
var meta = {
|
|
6
|
+
id: WNFS_PLUGIN,
|
|
7
|
+
name: "WNFS",
|
|
8
|
+
description: "Manage and view files with via the Web Native File System (WNFS).",
|
|
9
|
+
icon: "ph--file-cloud--regular",
|
|
10
|
+
source: "https://github.com/dxos/dxos/tree/main/packages/plugins/plugin-wnfs"
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
export {
|
|
14
|
+
WNFS_PLUGIN,
|
|
15
|
+
meta
|
|
16
|
+
};
|
|
17
|
+
//# sourceMappingURL=chunk-47QYKNA6.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/meta.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { type PluginMeta } from '@dxos/app-framework';\n\nexport const WNFS_PLUGIN = 'dxos.org/plugin/wnfs';\n\nexport const meta: PluginMeta = {\n id: WNFS_PLUGIN,\n name: 'WNFS',\n description: 'Manage and view files with via the Web Native File System (WNFS).',\n icon: 'ph--file-cloud--regular',\n source: 'https://github.com/dxos/dxos/tree/main/packages/plugins/plugin-wnfs',\n};\n"],
|
|
5
|
+
"mappings": ";;;AAMO,IAAMA,cAAc;AAEpB,IAAMC,OAAmB;EAC9BC,IAAIF;EACJG,MAAM;EACNC,aAAa;EACbC,MAAM;EACNC,QAAQ;AACV;",
|
|
6
|
+
"names": ["WNFS_PLUGIN", "meta", "id", "name", "description", "icon", "source"]
|
|
7
|
+
}
|