@visulima/storage-client 1.0.0-alpha.12 → 1.0.0-alpha.14
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/CHANGELOG.md +43 -0
- package/dist/index.d.ts +208 -1
- package/dist/index.js +1 -1
- package/dist/packem_shared/{createAbortAll-CIaZJY9f.js → createAbortAll-BVH_Wo6s.js} +1 -1
- package/dist/packem_shared/{createAbortAll-D3DlfIUX.js → createAbortAll-DMUWUL4C.js} +1 -1
- package/dist/packem_shared/{createAbortBatch-CYc_weio.js → createAbortBatch-C3t-Ho9c.js} +1 -1
- package/dist/packem_shared/{createAbortBatch-r3kaxuh8.js → createAbortBatch-bMvSBu1k.js} +1 -1
- package/dist/packem_shared/{createAbortItem-CDuIUi-c.js → createAbortItem-Bmhqhi8L.js} +1 -1
- package/dist/packem_shared/{createAbortItem-Dvd4L_J4.js → createAbortItem-BsqmmxdZ.js} +1 -1
- package/dist/packem_shared/{createAllAbortListener-DWB1otpM.js → createAllAbortListener-BChF9YcG.js} +1 -1
- package/dist/packem_shared/{createAllAbortListener-BehqWMv-.js → createAllAbortListener-BF9VhxQA.js} +1 -1
- package/dist/packem_shared/{createBatchCancelledListener-c6KcP08b.js → createBatchCancelledListener-DIHrRDNj.js} +1 -1
- package/dist/packem_shared/{createBatchCancelledListener-BXElG-Zl.js → createBatchCancelledListener-FsVlTbYv.js} +1 -1
- package/dist/packem_shared/createBatchDeleteFiles-B8bHItyS.js +1 -0
- package/dist/packem_shared/createBatchDeleteFiles-CN07ubNE.js +1 -0
- package/dist/packem_shared/{createBatchErrorListener-DFJkCUjM.js → createBatchErrorListener-BNXfdSlM.js} +1 -1
- package/dist/packem_shared/{createBatchErrorListener-Qe8LXCAz.js → createBatchErrorListener-CxEJhGOX.js} +1 -1
- package/dist/packem_shared/{createBatchFinalizeListener-Dd2Fiw8Z.js → createBatchFinalizeListener-DOK5uoog.js} +1 -1
- package/dist/packem_shared/{createBatchFinalizeListener-C-VHli8S.js → createBatchFinalizeListener-pjqAl9iM.js} +1 -1
- package/dist/packem_shared/{createBatchFinishListener-m7KNLv_1.js → createBatchFinishListener-BbMzJGlN.js} +1 -1
- package/dist/packem_shared/{createBatchFinishListener-DZHov2gR.js → createBatchFinishListener-DuMOo7Kn.js} +1 -1
- package/dist/packem_shared/{createBatchProgressListener-DXfegOiX.js → createBatchProgressListener-CUpa_7Nv.js} +1 -1
- package/dist/packem_shared/{createBatchProgressListener-C6EL7w7m.js → createBatchProgressListener-D28nm9Xe.js} +1 -1
- package/dist/packem_shared/{createBatchRetry-BnTMC2im.js → createBatchRetry-Bnaf10e9.js} +1 -1
- package/dist/packem_shared/{createBatchRetry-DssYfupW.js → createBatchRetry-DWOdovQt.js} +1 -1
- package/dist/packem_shared/{createBatchStartListener-e0RcceTB.js → createBatchStartListener-BwVzPsCB.js} +1 -1
- package/dist/packem_shared/{createBatchStartListener-D9gG-BHX.js → createBatchStartListener-DejGDAMY.js} +1 -1
- package/dist/packem_shared/{createBatchUpload-DCzjYF4B.js → createBatchUpload-Dm5vSg1j.js} +1 -1
- package/dist/packem_shared/createBatchUpload-Z-8vD9Ql.js +1 -0
- package/dist/packem_shared/createChunkedRestAdapter-CWFhVX6x.js +1 -0
- package/dist/packem_shared/createChunkedRestUpload-BH_5ZAr2.js +1 -0
- package/dist/packem_shared/createChunkedRestUpload-DAoXFznW.js +1 -0
- package/dist/packem_shared/createDeleteFile-D07PU21a.js +1 -0
- package/dist/packem_shared/createDeleteFile-mGIgeCQK.js +1 -0
- package/dist/packem_shared/createFileInput-CERPgCpc.js +1 -0
- package/dist/packem_shared/createFileInput-DyGrmzbc.js +1 -0
- package/dist/packem_shared/createGetFile-cUIB1L1M.js +1 -0
- package/dist/packem_shared/createGetFile-dT-EuNKP.js +1 -0
- package/dist/packem_shared/createGetFileList-C3lYvKGY.js +1 -0
- package/dist/packem_shared/createGetFileList-C_n3HgHG.js +1 -0
- package/dist/packem_shared/createGetFileMeta-CSYB0Oj1.js +1 -0
- package/dist/packem_shared/{createGetFileMeta-50LymNvf.js → createGetFileMeta-DZ46CHse.js} +1 -1
- package/dist/packem_shared/createHeadFile--rl2Ezgb.js +1 -0
- package/dist/packem_shared/{createHeadFile-DR8CwK_B.js → createHeadFile-Ch80NkDO.js} +1 -1
- package/dist/packem_shared/{createMultipartAdapter-BNppwu8z.js → createMultipartAdapter-B17aIZJS.js} +1 -1
- package/dist/packem_shared/{createMultipartUpload-BMu5EO-f.js → createMultipartUpload-BPcFYSwI.js} +1 -1
- package/dist/packem_shared/createMultipartUpload-CFsUjhvG.js +1 -0
- package/dist/packem_shared/createPatchChunk-7y5S60GE.js +1 -0
- package/dist/packem_shared/createPatchChunk-D-N2cYZ7.js +1 -0
- package/dist/packem_shared/createPutFile-BJcLUSQi.js +1 -0
- package/dist/packem_shared/createPutFile-CamOtR__.js +1 -0
- package/dist/packem_shared/{createRetry-2YY79v45.js → createRetry-BInLl1TV.js} +1 -1
- package/dist/packem_shared/{createRetry-DOYZZbrG.js → createRetry-D0eddvNY.js} +1 -1
- package/dist/packem_shared/{createRetryListener-CW4sOuow.js → createRetryListener-59bXI4qF.js} +1 -1
- package/dist/packem_shared/{createRetryListener-ISvMl_3n.js → createRetryListener-hZUkGq7P.js} +1 -1
- package/dist/packem_shared/createTransformFile-BaofH3n5.js +1 -0
- package/dist/packem_shared/createTransformFile-BcoA39lM.js +1 -0
- package/dist/packem_shared/createTransformMetadata-C9lWyhne.js +1 -0
- package/dist/packem_shared/{createTransformMetadata-zyl5UymO.js → createTransformMetadata-CqyCBOXk.js} +1 -1
- package/dist/packem_shared/createTusAdapter-BbFsUNsP.js +1 -0
- package/dist/packem_shared/{createTusUpload-60ceH2dH.js → createTusUpload-DKIIHh2X.js} +1 -1
- package/dist/packem_shared/createTusUpload-rZKMrL5n.js +1 -0
- package/dist/packem_shared/{createUpload-hMh93Gt9.js → createUpload-0qE79TWD.js} +1 -1
- package/dist/packem_shared/createUpload-BF6TujIH.js +1 -0
- package/dist/packem_shared/createUploader-KOsp3cZt.js +1 -0
- package/dist/packem_shared/parseApiError-BiXX3oHJ.js +1 -0
- package/dist/packem_shared/uploader.d-DsC50BbX.d.ts +223 -0
- package/dist/packem_shared/{useAbortAll-Dwl12wn5.js → useAbortAll-DNzPcfOt.js} +1 -1
- package/dist/packem_shared/{useAbortAll-BQ8eXNKW.js → useAbortAll-Xks2z0Rf.js} +1 -1
- package/dist/packem_shared/{useAbortBatch-CyHnX3HT.js → useAbortBatch-Jb37hbXq.js} +1 -1
- package/dist/packem_shared/{useAbortBatch-CZpDT_VG.js → useAbortBatch-y-KZjKTY.js} +1 -1
- package/dist/packem_shared/{useAbortItem-D-5h_Oyx.js → useAbortItem-BhdhRgs8.js} +1 -1
- package/dist/packem_shared/{useAbortItem-D_F-QSoR.js → useAbortItem-DTFUUKVu.js} +1 -1
- package/dist/packem_shared/{useAllAbortListener-BTmWEsU9.js → useAllAbortListener-BBw02ZoD.js} +1 -1
- package/dist/packem_shared/{useAllAbortListener-XvIsxprv.js → useAllAbortListener-Crsmf1kC.js} +1 -1
- package/dist/packem_shared/{useBatchCancelledListener-CYR2wnxk.js → useBatchCancelledListener-C3IW43nC.js} +1 -1
- package/dist/packem_shared/{useBatchCancelledListener-C0LDRfcv.js → useBatchCancelledListener-CVJULtua.js} +1 -1
- package/dist/packem_shared/useBatchDeleteFiles-BSG8D3Do.js +1 -0
- package/dist/packem_shared/useBatchDeleteFiles-DmKXrcBR.js +1 -0
- package/dist/packem_shared/{useBatchErrorListener-Czidx586.js → useBatchErrorListener-BAVIRlQE.js} +1 -1
- package/dist/packem_shared/{useBatchErrorListener-B_6NFnd9.js → useBatchErrorListener-Ck1BwfZA.js} +1 -1
- package/dist/packem_shared/{useBatchFinalizeListener-CHCTeAHu.js → useBatchFinalizeListener-D7TRElSE.js} +1 -1
- package/dist/packem_shared/{useBatchFinalizeListener-DPMYtpeD.js → useBatchFinalizeListener-nA7Qs-Ya.js} +1 -1
- package/dist/packem_shared/{useBatchFinishListener-BU_oqITL.js → useBatchFinishListener-C6zS5OI6.js} +1 -1
- package/dist/packem_shared/{useBatchFinishListener-C757MrUE.js → useBatchFinishListener-VdCzyg4J.js} +1 -1
- package/dist/packem_shared/{useBatchProgressListener-VgV-UnUC.js → useBatchProgressListener-B08x2n9U.js} +1 -1
- package/dist/packem_shared/{useBatchProgressListener-DLvO3sOl.js → useBatchProgressListener-CdcDM2sa.js} +1 -1
- package/dist/packem_shared/{useBatchRetry-DPDRWaAZ.js → useBatchRetry-B3FQ1DdH.js} +1 -1
- package/dist/packem_shared/{useBatchRetry-DgtOIHZS.js → useBatchRetry-DahiIOXJ.js} +1 -1
- package/dist/packem_shared/{useBatchStartListener-BtJWkFZl.js → useBatchStartListener-ByQlcF8F.js} +1 -1
- package/dist/packem_shared/{useBatchStartListener-VhNPXaew.js → useBatchStartListener-DndF1z5v.js} +1 -1
- package/dist/packem_shared/{useBatchUpload-OtoOJPyD.js → useBatchUpload-BJBdu6vh.js} +1 -1
- package/dist/packem_shared/useBatchUpload-IZkU_Gop.js +1 -0
- package/dist/packem_shared/useChunkedRestUpload-C9RhEtUt.js +1 -0
- package/dist/packem_shared/useChunkedRestUpload-tirJ_5VX.js +1 -0
- package/dist/packem_shared/useDeleteFile-BJnTMMUr.js +1 -0
- package/dist/packem_shared/useDeleteFile-Dsw372GL.js +1 -0
- package/dist/packem_shared/useFileInput-BUPBo2m_.js +1 -0
- package/dist/packem_shared/useFileInput-CgqlIlGE.js +1 -0
- package/dist/packem_shared/useGetFile-BkmKk12o.js +1 -0
- package/dist/packem_shared/useGetFile-CNOi9ZIM.js +1 -0
- package/dist/packem_shared/useGetFileList-BIGh4thc.js +1 -0
- package/dist/packem_shared/useGetFileList-CkAmk7lP.js +1 -0
- package/dist/packem_shared/useGetFileMeta-CHee8013.js +1 -0
- package/dist/packem_shared/useGetFileMeta-eKrJc2p1.js +1 -0
- package/dist/packem_shared/useHeadFile-CdIM_Xi1.js +1 -0
- package/dist/packem_shared/{useHeadFile-DBQdkWZG.js → useHeadFile-D5CQQnyf.js} +1 -1
- package/dist/packem_shared/{useMultipartUpload-DmdEn3r3.js → useMultipartUpload-CJMa-_Yo.js} +1 -1
- package/dist/packem_shared/{useMultipartUpload-CIZ1b2I0.js → useMultipartUpload-CbRSpnTb.js} +1 -1
- package/dist/packem_shared/usePatchChunk-B8ZCd9Th.js +1 -0
- package/dist/packem_shared/usePatchChunk-DqZtVBBl.js +1 -0
- package/dist/packem_shared/usePutFile-CFaBgDX4.js +1 -0
- package/dist/packem_shared/usePutFile-Db_uVkqT.js +1 -0
- package/dist/packem_shared/{useRetry-BKB7OLhh.js → useRetry-DHjDuH0H.js} +1 -1
- package/dist/packem_shared/{useRetry-CrCiJNIu.js → useRetry-trYC3K_p.js} +1 -1
- package/dist/packem_shared/{useRetryListener-DJuOCZP7.js → useRetryListener-CAIyK1_Q.js} +1 -1
- package/dist/packem_shared/{useRetryListener-CnCl5adt.js → useRetryListener-DC8G9lmY.js} +1 -1
- package/dist/packem_shared/useTransformFile-BCyX-R_e.js +1 -0
- package/dist/packem_shared/useTransformFile-BMqWIG7J.js +1 -0
- package/dist/packem_shared/useTransformMetadata-CUo8IdKP.js +1 -0
- package/dist/packem_shared/{useTransformMetadata-B0JbX1Ni.js → useTransformMetadata-DjcVDZOc.js} +1 -1
- package/dist/packem_shared/{useTusUpload-BkaFKsSN.js → useTusUpload-B5KsdwDR.js} +1 -1
- package/dist/packem_shared/{useTusUpload-CNRlzFRm.js → useTusUpload-BwF0G1LE.js} +1 -1
- package/dist/packem_shared/{useUpload-DHgLmMri.js → useUpload-7OjscFW6.js} +1 -1
- package/dist/packem_shared/{useUpload-hVpmaxT3.js → useUpload-C5ZiPWFM.js} +1 -1
- package/dist/react/index.d.ts +839 -61
- package/dist/react/index.js +1 -1
- package/dist/solid/index.d.ts +690 -60
- package/dist/solid/index.js +1 -1
- package/dist/svelte/index.d.ts +671 -60
- package/dist/svelte/index.js +1 -1
- package/dist/vue/index.d.ts +804 -60
- package/dist/vue/index.js +1 -1
- package/package.json +26 -26
- package/dist/core/chunked-rest-adapter.d.ts +0 -43
- package/dist/core/index.d.ts +0 -11
- package/dist/core/multipart-adapter.d.ts +0 -34
- package/dist/core/query-client.d.ts +0 -57
- package/dist/core/query-keys.d.ts +0 -34
- package/dist/core/tus-adapter.d.ts +0 -43
- package/dist/core/uploader.d.ts +0 -183
- package/dist/packem_shared/createBatchDeleteFiles-B0SYSdYj.js +0 -1
- package/dist/packem_shared/createBatchDeleteFiles-Z4S-30eN.js +0 -1
- package/dist/packem_shared/createBatchUpload-BAhrDNle.js +0 -1
- package/dist/packem_shared/createChunkedRestAdapter-Df1E_Adn.js +0 -1
- package/dist/packem_shared/createChunkedRestUpload-CJNQp68Z.js +0 -1
- package/dist/packem_shared/createChunkedRestUpload-DZIOry7M.js +0 -1
- package/dist/packem_shared/createDeleteFile-DsUMoSxn.js +0 -1
- package/dist/packem_shared/createDeleteFile-_Znrnika.js +0 -1
- package/dist/packem_shared/createFileInput-B7WPz_-r.js +0 -1
- package/dist/packem_shared/createFileInput-TTI-EsSq.js +0 -1
- package/dist/packem_shared/createGetFile-BOV5S7mX.js +0 -1
- package/dist/packem_shared/createGetFile-CY2ohQF-.js +0 -1
- package/dist/packem_shared/createGetFileList-DZHiTR4D.js +0 -1
- package/dist/packem_shared/createGetFileList-ZF0Luf6h.js +0 -1
- package/dist/packem_shared/createGetFileMeta-DmC_OvP4.js +0 -1
- package/dist/packem_shared/createHeadFile-DHJXsk3i.js +0 -1
- package/dist/packem_shared/createMultipartUpload-D5jXlOpN.js +0 -1
- package/dist/packem_shared/createPatchChunk-DqCMbHjI.js +0 -1
- package/dist/packem_shared/createPatchChunk-Zy6I60LN.js +0 -1
- package/dist/packem_shared/createPutFile-C95UgrTJ.js +0 -1
- package/dist/packem_shared/createPutFile-D8hN-9Ai.js +0 -1
- package/dist/packem_shared/createTransformFile-BlttN909.js +0 -1
- package/dist/packem_shared/createTransformFile-CJXLJEfg.js +0 -1
- package/dist/packem_shared/createTransformMetadata-BImjFF_i.js +0 -1
- package/dist/packem_shared/createTusAdapter-CIQM8UR2.js +0 -1
- package/dist/packem_shared/createTusUpload-DiGPefD0.js +0 -1
- package/dist/packem_shared/createUpload-zv3qcpf1.js +0 -1
- package/dist/packem_shared/createUploader-DzBPRYBP.js +0 -1
- package/dist/packem_shared/parseApiError-CUagSahh.js +0 -1
- package/dist/packem_shared/useBatchDeleteFiles-ASYuAVXn.js +0 -1
- package/dist/packem_shared/useBatchDeleteFiles-KthW4bon.js +0 -1
- package/dist/packem_shared/useBatchUpload-DQPzqa6X.js +0 -1
- package/dist/packem_shared/useChunkedRestUpload-ByEGSmgy.js +0 -1
- package/dist/packem_shared/useChunkedRestUpload-DmXiSpyb.js +0 -1
- package/dist/packem_shared/useDeleteFile-CND-6aNW.js +0 -1
- package/dist/packem_shared/useDeleteFile-CZUMjbYV.js +0 -1
- package/dist/packem_shared/useFileInput-Dvy2fNU7.js +0 -1
- package/dist/packem_shared/useFileInput-hIbzJ_JN.js +0 -1
- package/dist/packem_shared/useGetFile-CuST4rUN.js +0 -1
- package/dist/packem_shared/useGetFile-DvgluPgA.js +0 -1
- package/dist/packem_shared/useGetFileList-BiYDlEAl.js +0 -1
- package/dist/packem_shared/useGetFileList-D0tKDYAc.js +0 -1
- package/dist/packem_shared/useGetFileMeta-C2U1PExr.js +0 -1
- package/dist/packem_shared/useGetFileMeta-Ekre98Sg.js +0 -1
- package/dist/packem_shared/useHeadFile-CCu61b-B.js +0 -1
- package/dist/packem_shared/usePatchChunk-BO3S0Tx4.js +0 -1
- package/dist/packem_shared/usePatchChunk-DoKsCbBH.js +0 -1
- package/dist/packem_shared/usePutFile-B6cFjClD.js +0 -1
- package/dist/packem_shared/usePutFile-bQl10v42.js +0 -1
- package/dist/packem_shared/useTransformFile-DmfsqTjp.js +0 -1
- package/dist/packem_shared/useTransformFile-weII4bx_.js +0 -1
- package/dist/packem_shared/useTransformMetadata-DK1561-K.js +0 -1
- package/dist/react/types.d.ts +0 -65
- package/dist/react/use-abort-all.d.ts +0 -16
- package/dist/react/use-abort-batch.d.ts +0 -16
- package/dist/react/use-abort-item.d.ts +0 -16
- package/dist/react/use-all-abort-listener.d.ts +0 -14
- package/dist/react/use-batch-cancelled-listener.d.ts +0 -14
- package/dist/react/use-batch-delete-files.d.ts +0 -32
- package/dist/react/use-batch-error-listener.d.ts +0 -14
- package/dist/react/use-batch-finalize-listener.d.ts +0 -15
- package/dist/react/use-batch-finish-listener.d.ts +0 -14
- package/dist/react/use-batch-progress-listener.d.ts +0 -14
- package/dist/react/use-batch-retry.d.ts +0 -16
- package/dist/react/use-batch-start-listener.d.ts +0 -14
- package/dist/react/use-batch-upload.d.ts +0 -42
- package/dist/react/use-chunked-rest-upload.d.ts +0 -55
- package/dist/react/use-delete-file.d.ts +0 -25
- package/dist/react/use-file-input.d.ts +0 -32
- package/dist/react/use-get-file-list.d.ts +0 -46
- package/dist/react/use-get-file-meta.d.ts +0 -29
- package/dist/react/use-get-file.d.ts +0 -34
- package/dist/react/use-head-file.d.ts +0 -49
- package/dist/react/use-multipart-upload.d.ts +0 -35
- package/dist/react/use-paste-upload.d.ts +0 -20
- package/dist/react/use-patch-chunk.d.ts +0 -29
- package/dist/react/use-put-file.d.ts +0 -32
- package/dist/react/use-retry-listener.d.ts +0 -15
- package/dist/react/use-retry.d.ts +0 -16
- package/dist/react/use-transform-file.d.ts +0 -48
- package/dist/react/use-transform-metadata.d.ts +0 -33
- package/dist/react/use-tus-upload.d.ts +0 -55
- package/dist/react/use-upload.d.ts +0 -69
- package/dist/solid/create-abort-all.d.ts +0 -8
- package/dist/solid/create-abort-batch.d.ts +0 -8
- package/dist/solid/create-abort-item.d.ts +0 -8
- package/dist/solid/create-all-abort-listener.d.ts +0 -7
- package/dist/solid/create-batch-cancelled-listener.d.ts +0 -7
- package/dist/solid/create-batch-delete-files.d.ts +0 -29
- package/dist/solid/create-batch-error-listener.d.ts +0 -7
- package/dist/solid/create-batch-finalize-listener.d.ts +0 -7
- package/dist/solid/create-batch-finish-listener.d.ts +0 -7
- package/dist/solid/create-batch-progress-listener.d.ts +0 -7
- package/dist/solid/create-batch-retry.d.ts +0 -8
- package/dist/solid/create-batch-start-listener.d.ts +0 -7
- package/dist/solid/create-batch-upload.d.ts +0 -43
- package/dist/solid/create-chunked-rest-upload.d.ts +0 -56
- package/dist/solid/create-delete-file.d.ts +0 -22
- package/dist/solid/create-file-input.d.ts +0 -20
- package/dist/solid/create-get-file-list.d.ts +0 -46
- package/dist/solid/create-get-file-meta.d.ts +0 -29
- package/dist/solid/create-get-file.d.ts +0 -38
- package/dist/solid/create-head-file.d.ts +0 -46
- package/dist/solid/create-multipart-upload.d.ts +0 -36
- package/dist/solid/create-paste-upload.d.ts +0 -11
- package/dist/solid/create-patch-chunk.d.ts +0 -26
- package/dist/solid/create-put-file.d.ts +0 -29
- package/dist/solid/create-retry-listener.d.ts +0 -7
- package/dist/solid/create-retry.d.ts +0 -8
- package/dist/solid/create-transform-file.d.ts +0 -45
- package/dist/solid/create-transform-metadata.d.ts +0 -30
- package/dist/solid/create-tus-upload.d.ts +0 -56
- package/dist/solid/create-upload.d.ts +0 -70
- package/dist/svelte/create-abort-all.d.ts +0 -8
- package/dist/svelte/create-abort-batch.d.ts +0 -8
- package/dist/svelte/create-abort-item.d.ts +0 -8
- package/dist/svelte/create-all-abort-listener.d.ts +0 -7
- package/dist/svelte/create-batch-cancelled-listener.d.ts +0 -7
- package/dist/svelte/create-batch-delete-files.d.ts +0 -29
- package/dist/svelte/create-batch-error-listener.d.ts +0 -7
- package/dist/svelte/create-batch-finalize-listener.d.ts +0 -7
- package/dist/svelte/create-batch-finish-listener.d.ts +0 -7
- package/dist/svelte/create-batch-progress-listener.d.ts +0 -7
- package/dist/svelte/create-batch-retry.d.ts +0 -8
- package/dist/svelte/create-batch-start-listener.d.ts +0 -7
- package/dist/svelte/create-batch-upload.d.ts +0 -23
- package/dist/svelte/create-chunked-rest-upload.d.ts +0 -56
- package/dist/svelte/create-delete-file.d.ts +0 -26
- package/dist/svelte/create-file-input.d.ts +0 -19
- package/dist/svelte/create-get-file-list.d.ts +0 -43
- package/dist/svelte/create-get-file-meta.d.ts +0 -26
- package/dist/svelte/create-get-file.d.ts +0 -41
- package/dist/svelte/create-head-file.d.ts +0 -46
- package/dist/svelte/create-multipart-upload.d.ts +0 -36
- package/dist/svelte/create-paste-upload.d.ts +0 -11
- package/dist/svelte/create-patch-chunk.d.ts +0 -26
- package/dist/svelte/create-put-file.d.ts +0 -29
- package/dist/svelte/create-retry-listener.d.ts +0 -7
- package/dist/svelte/create-retry.d.ts +0 -8
- package/dist/svelte/create-transform-file.d.ts +0 -45
- package/dist/svelte/create-transform-metadata.d.ts +0 -30
- package/dist/svelte/create-tus-upload.d.ts +0 -56
- package/dist/svelte/create-upload.d.ts +0 -68
- package/dist/vue/use-abort-all.d.ts +0 -16
- package/dist/vue/use-abort-batch.d.ts +0 -16
- package/dist/vue/use-abort-item.d.ts +0 -16
- package/dist/vue/use-all-abort-listener.d.ts +0 -14
- package/dist/vue/use-batch-cancelled-listener.d.ts +0 -14
- package/dist/vue/use-batch-delete-files.d.ts +0 -29
- package/dist/vue/use-batch-error-listener.d.ts +0 -14
- package/dist/vue/use-batch-finalize-listener.d.ts +0 -15
- package/dist/vue/use-batch-finish-listener.d.ts +0 -14
- package/dist/vue/use-batch-progress-listener.d.ts +0 -14
- package/dist/vue/use-batch-retry.d.ts +0 -16
- package/dist/vue/use-batch-start-listener.d.ts +0 -14
- package/dist/vue/use-batch-upload.d.ts +0 -43
- package/dist/vue/use-chunked-rest-upload.d.ts +0 -56
- package/dist/vue/use-delete-file.d.ts +0 -22
- package/dist/vue/use-file-input.d.ts +0 -33
- package/dist/vue/use-get-file-list.d.ts +0 -43
- package/dist/vue/use-get-file-meta.d.ts +0 -26
- package/dist/vue/use-get-file.d.ts +0 -35
- package/dist/vue/use-head-file.d.ts +0 -46
- package/dist/vue/use-multipart-upload.d.ts +0 -36
- package/dist/vue/use-paste-upload.d.ts +0 -21
- package/dist/vue/use-patch-chunk.d.ts +0 -26
- package/dist/vue/use-put-file.d.ts +0 -29
- package/dist/vue/use-retry-listener.d.ts +0 -15
- package/dist/vue/use-retry.d.ts +0 -16
- package/dist/vue/use-transform-file.d.ts +0 -45
- package/dist/vue/use-transform-metadata.d.ts +0 -30
- package/dist/vue/use-tus-upload.d.ts +0 -56
- package/dist/vue/use-upload.d.ts +0 -68
package/dist/vue/index.d.ts
CHANGED
|
@@ -1,60 +1,804 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
1
|
+
import { c as UploadItem, B as BatchState, U as UploadResult, F as FileMeta, g as UploadMethod } from "../packem_shared/uploader.d-DsC50BbX.js";
|
|
2
|
+
import { Ref, MaybeRefOrGetter, ComputedRef } from 'vue';
|
|
3
|
+
interface UseAbortAllOptions {
|
|
4
|
+
/** Upload endpoint URL (used to create uploader instance) */
|
|
5
|
+
endpoint: string;
|
|
6
|
+
/** Additional metadata to include with the upload */
|
|
7
|
+
metadata?: Record<string, string>;
|
|
8
|
+
}
|
|
9
|
+
interface UseAbortAllReturn {
|
|
10
|
+
/** Abort all active uploads */
|
|
11
|
+
abortAll: () => void;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Vue composable to abort all active uploads.
|
|
15
|
+
* @param options Configuration options
|
|
16
|
+
* @returns Abort all function
|
|
17
|
+
*/
|
|
18
|
+
declare const useAbortAll: (options: UseAbortAllOptions) => UseAbortAllReturn;
|
|
19
|
+
interface UseAbortBatchOptions {
|
|
20
|
+
/** Upload endpoint URL (used to create uploader instance) */
|
|
21
|
+
endpoint: string;
|
|
22
|
+
/** Additional metadata to include with the upload */
|
|
23
|
+
metadata?: Record<string, string>;
|
|
24
|
+
}
|
|
25
|
+
interface UseAbortBatchReturn {
|
|
26
|
+
/** Abort a batch of uploads by batch ID */
|
|
27
|
+
abortBatch: (batchId: string) => void;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Vue composable to abort a batch of uploads.
|
|
31
|
+
* @param options Configuration options
|
|
32
|
+
* @returns Abort batch function
|
|
33
|
+
*/
|
|
34
|
+
declare const useAbortBatch: (options: UseAbortBatchOptions) => UseAbortBatchReturn;
|
|
35
|
+
interface UseAbortItemOptions {
|
|
36
|
+
/** Upload endpoint URL (used to create uploader instance) */
|
|
37
|
+
endpoint: string;
|
|
38
|
+
/** Additional metadata to include with the upload */
|
|
39
|
+
metadata?: Record<string, string>;
|
|
40
|
+
}
|
|
41
|
+
interface UseAbortItemReturn {
|
|
42
|
+
/** Abort a specific upload item by ID */
|
|
43
|
+
abortItem: (id: string) => void;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Vue composable to abort a specific upload item.
|
|
47
|
+
* @param options Configuration options
|
|
48
|
+
* @returns Abort function
|
|
49
|
+
*/
|
|
50
|
+
declare const useAbortItem: (options: UseAbortItemOptions) => UseAbortItemReturn;
|
|
51
|
+
interface UseAllAbortListenerOptions {
|
|
52
|
+
/** Upload endpoint URL (used to create uploader instance) */
|
|
53
|
+
endpoint: string;
|
|
54
|
+
/** Additional metadata to include with the upload */
|
|
55
|
+
metadata?: Record<string, string>;
|
|
56
|
+
/** Callback when any item is aborted */
|
|
57
|
+
onAbort: (item: UploadItem) => void;
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* Vue composable to listen to all abort events (item aborts).
|
|
61
|
+
* @param options Listener configuration options
|
|
62
|
+
*/
|
|
63
|
+
declare const useAllAbortListener: (options: UseAllAbortListenerOptions) => void;
|
|
64
|
+
interface UseBatchCancelledListenerOptions {
|
|
65
|
+
/** Upload endpoint URL (used to create uploader instance) */
|
|
66
|
+
endpoint: string;
|
|
67
|
+
/** Additional metadata to include with the upload */
|
|
68
|
+
metadata?: Record<string, string>;
|
|
69
|
+
/** Callback when batch is cancelled */
|
|
70
|
+
onBatchCancelled: (batch: BatchState) => void;
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* Vue composable to listen to batch cancelled events.
|
|
74
|
+
* @param options Listener configuration options
|
|
75
|
+
*/
|
|
76
|
+
declare const useBatchCancelledListener: (options: UseBatchCancelledListenerOptions) => void;
|
|
77
|
+
interface BatchDeleteResult {
|
|
78
|
+
/** Number of files that failed to delete */
|
|
79
|
+
failed?: number;
|
|
80
|
+
/** Number of files successfully deleted */
|
|
81
|
+
successful?: number;
|
|
82
|
+
}
|
|
83
|
+
interface UseBatchDeleteFilesOptions {
|
|
84
|
+
/** Base endpoint URL for file operations */
|
|
85
|
+
endpoint: string;
|
|
86
|
+
}
|
|
87
|
+
interface UseBatchDeleteFilesReturn {
|
|
88
|
+
/** Delete multiple files by IDs */
|
|
89
|
+
batchDeleteFiles: (ids: string[]) => Promise<BatchDeleteResult>;
|
|
90
|
+
/** Last request error, if any */
|
|
91
|
+
error: Readonly<Ref<Error | undefined>>;
|
|
92
|
+
/** Whether a request is currently in progress */
|
|
93
|
+
isLoading: Readonly<Ref<boolean>>;
|
|
94
|
+
/** Reset mutation state */
|
|
95
|
+
reset: () => void;
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* Vue composable for batch deleting files using TanStack Query.
|
|
99
|
+
* Supports both query parameter and JSON body methods.
|
|
100
|
+
* Automatically invalidates related queries.
|
|
101
|
+
* @param options Hook configuration options
|
|
102
|
+
* @returns Batch file deletion functions and state
|
|
103
|
+
*/
|
|
104
|
+
declare const useBatchDeleteFiles: (options: UseBatchDeleteFilesOptions) => UseBatchDeleteFilesReturn;
|
|
105
|
+
interface UseBatchErrorListenerOptions {
|
|
106
|
+
/** Upload endpoint URL (used to create uploader instance) */
|
|
107
|
+
endpoint: string;
|
|
108
|
+
/** Additional metadata to include with the upload */
|
|
109
|
+
metadata?: Record<string, string>;
|
|
110
|
+
/** Callback when batch encounters an error */
|
|
111
|
+
onBatchError: (batch: BatchState) => void;
|
|
112
|
+
}
|
|
113
|
+
/**
|
|
114
|
+
* Vue composable to listen to batch error events.
|
|
115
|
+
* @param options Listener configuration options
|
|
116
|
+
*/
|
|
117
|
+
declare const useBatchErrorListener: (options: UseBatchErrorListenerOptions) => void;
|
|
118
|
+
interface UseBatchFinalizeListenerOptions {
|
|
119
|
+
/** Upload endpoint URL (used to create uploader instance) */
|
|
120
|
+
endpoint: string;
|
|
121
|
+
/** Additional metadata to include with the upload */
|
|
122
|
+
metadata?: Record<string, string>;
|
|
123
|
+
/** Callback when batch finalizes (after all items complete) */
|
|
124
|
+
onBatchFinalize: (batch: BatchState) => void;
|
|
125
|
+
}
|
|
126
|
+
/**
|
|
127
|
+
* Vue composable to listen to batch finalize events.
|
|
128
|
+
* This event fires after all items in a batch have completed (successfully or with errors).
|
|
129
|
+
* @param options Listener configuration options
|
|
130
|
+
*/
|
|
131
|
+
declare const useBatchFinalizeListener: (options: UseBatchFinalizeListenerOptions) => void;
|
|
132
|
+
interface UseBatchFinishListenerOptions {
|
|
133
|
+
/** Upload endpoint URL (used to create uploader instance) */
|
|
134
|
+
endpoint: string;
|
|
135
|
+
/** Additional metadata to include with the upload */
|
|
136
|
+
metadata?: Record<string, string>;
|
|
137
|
+
/** Callback when batch finishes successfully */
|
|
138
|
+
onBatchFinish: (batch: BatchState) => void;
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* Vue composable to listen to batch finish events.
|
|
142
|
+
* @param options Listener configuration options
|
|
143
|
+
*/
|
|
144
|
+
declare const useBatchFinishListener: (options: UseBatchFinishListenerOptions) => void;
|
|
145
|
+
interface UseBatchProgressListenerOptions {
|
|
146
|
+
/** Upload endpoint URL (used to create uploader instance) */
|
|
147
|
+
endpoint: string;
|
|
148
|
+
/** Additional metadata to include with the upload */
|
|
149
|
+
metadata?: Record<string, string>;
|
|
150
|
+
/** Callback when batch progress updates */
|
|
151
|
+
onBatchProgress: (batch: BatchState) => void;
|
|
152
|
+
}
|
|
153
|
+
/**
|
|
154
|
+
* Vue composable to listen to batch progress events.
|
|
155
|
+
* @param options Listener configuration options
|
|
156
|
+
*/
|
|
157
|
+
declare const useBatchProgressListener: (options: UseBatchProgressListenerOptions) => void;
|
|
158
|
+
interface UseBatchRetryOptions {
|
|
159
|
+
/** Upload endpoint URL (used to create uploader instance) */
|
|
160
|
+
endpoint: string;
|
|
161
|
+
/** Additional metadata to include with the upload */
|
|
162
|
+
metadata?: Record<string, string>;
|
|
163
|
+
}
|
|
164
|
+
interface UseBatchRetryReturn {
|
|
165
|
+
/** Retry all failed items in a batch */
|
|
166
|
+
retryBatch: (batchId: string) => void;
|
|
167
|
+
}
|
|
168
|
+
/**
|
|
169
|
+
* Vue composable to retry all failed items in a batch.
|
|
170
|
+
* @param options Configuration options
|
|
171
|
+
* @returns Retry batch function
|
|
172
|
+
*/
|
|
173
|
+
declare const useBatchRetry: (options: UseBatchRetryOptions) => UseBatchRetryReturn;
|
|
174
|
+
interface UseBatchStartListenerOptions {
|
|
175
|
+
/** Upload endpoint URL (used to create uploader instance) */
|
|
176
|
+
endpoint: string;
|
|
177
|
+
/** Additional metadata to include with the upload */
|
|
178
|
+
metadata?: Record<string, string>;
|
|
179
|
+
/** Callback when batch starts */
|
|
180
|
+
onBatchStart: (batch: BatchState) => void;
|
|
181
|
+
}
|
|
182
|
+
/**
|
|
183
|
+
* Vue composable to listen to batch start events.
|
|
184
|
+
* @param options Listener configuration options
|
|
185
|
+
*/
|
|
186
|
+
declare const useBatchStartListener: (options: UseBatchStartListenerOptions) => void;
|
|
187
|
+
interface UseBatchUploadOptions {
|
|
188
|
+
/** Upload endpoint URL */
|
|
189
|
+
endpoint: string;
|
|
190
|
+
/** Additional metadata to include with the upload */
|
|
191
|
+
metadata?: Record<string, string>;
|
|
192
|
+
/** Callback when batch fails */
|
|
193
|
+
onError?: (error: Error, batchId: string) => void;
|
|
194
|
+
/** Callback when batch progress updates */
|
|
195
|
+
onProgress?: (progress: number, batchId: string) => void;
|
|
196
|
+
/** Callback when batch starts */
|
|
197
|
+
onStart?: (batchId: string) => void;
|
|
198
|
+
/** Callback when batch completes successfully */
|
|
199
|
+
onSuccess?: (results: UploadResult[], batchId: string) => void;
|
|
200
|
+
}
|
|
201
|
+
interface UseBatchUploadReturn {
|
|
202
|
+
/** Abort a specific batch */
|
|
203
|
+
abortBatch: (batchId: string) => void;
|
|
204
|
+
/** Number of completed items in current batch */
|
|
205
|
+
completedCount: Ref<number>;
|
|
206
|
+
/** Last batch error, if any */
|
|
207
|
+
error: Ref<Error | undefined>;
|
|
208
|
+
/** Number of failed items in current batch */
|
|
209
|
+
errorCount: Ref<number>;
|
|
210
|
+
/** Whether a batch is currently uploading */
|
|
211
|
+
isUploading: Ref<boolean>;
|
|
212
|
+
/** All upload items in current batch */
|
|
213
|
+
items: Ref<UploadItem[]>;
|
|
214
|
+
/** Current batch progress (0-100) */
|
|
215
|
+
progress: Ref<number>;
|
|
216
|
+
/** Reset batch state */
|
|
217
|
+
reset: () => void;
|
|
218
|
+
/** Upload multiple files as a batch */
|
|
219
|
+
uploadBatch: (files: File[]) => string[];
|
|
220
|
+
}
|
|
221
|
+
/**
|
|
222
|
+
* Vue composable for batch file uploads using multipart/form-data.
|
|
223
|
+
* @param options Upload configuration options
|
|
224
|
+
* @returns Batch upload functions and state
|
|
225
|
+
*/
|
|
226
|
+
declare const useBatchUpload: (options: UseBatchUploadOptions) => UseBatchUploadReturn;
|
|
227
|
+
interface UseChunkedRestUploadOptions {
|
|
228
|
+
/** Chunk size for chunked REST uploads (default: 5MB) */
|
|
229
|
+
chunkSize?: number;
|
|
230
|
+
/** Chunked REST upload endpoint URL */
|
|
231
|
+
endpoint: string;
|
|
232
|
+
/** Maximum number of retry attempts */
|
|
233
|
+
maxRetries?: number;
|
|
234
|
+
/** Additional metadata to include with the upload */
|
|
235
|
+
metadata?: Record<string, string>;
|
|
236
|
+
/** Callback when upload fails */
|
|
237
|
+
onError?: (error: Error) => void;
|
|
238
|
+
/** Callback when upload is paused */
|
|
239
|
+
onPause?: () => void;
|
|
240
|
+
/** Callback when upload progress updates */
|
|
241
|
+
onProgress?: (progress: number, offset: number) => void;
|
|
242
|
+
/** Callback when upload is resumed */
|
|
243
|
+
onResume?: () => void;
|
|
244
|
+
/** Callback when upload starts */
|
|
245
|
+
onStart?: () => void;
|
|
246
|
+
/** Callback when upload completes successfully */
|
|
247
|
+
onSuccess?: (file: UploadResult) => void;
|
|
248
|
+
/** Enable automatic retry on failure */
|
|
249
|
+
retry?: boolean;
|
|
250
|
+
}
|
|
251
|
+
interface UseChunkedRestUploadReturn {
|
|
252
|
+
/** Abort the current upload */
|
|
253
|
+
abort: () => void;
|
|
254
|
+
/** Last upload error, if any */
|
|
255
|
+
error: Ref<Error | undefined>;
|
|
256
|
+
/** Whether the upload is paused */
|
|
257
|
+
isPaused: Ref<boolean>;
|
|
258
|
+
/** Whether an upload is currently in progress */
|
|
259
|
+
isUploading: Ref<boolean>;
|
|
260
|
+
/** Current upload offset (bytes uploaded) */
|
|
261
|
+
offset: Ref<number>;
|
|
262
|
+
/** Pause the current upload */
|
|
263
|
+
pause: () => void;
|
|
264
|
+
/** Current upload progress (0-100) */
|
|
265
|
+
progress: Ref<number>;
|
|
266
|
+
/** Reset upload state */
|
|
267
|
+
reset: () => void;
|
|
268
|
+
/** Last upload result, if any */
|
|
269
|
+
result: Ref<UploadResult | undefined>;
|
|
270
|
+
/** Resume a paused upload */
|
|
271
|
+
resume: () => Promise<void>;
|
|
272
|
+
/** Upload a file using chunked REST protocol */
|
|
273
|
+
upload: (file: File) => Promise<UploadResult>;
|
|
274
|
+
}
|
|
275
|
+
/**
|
|
276
|
+
* Vue composable for chunked REST file uploads.
|
|
277
|
+
* @param options Upload configuration options
|
|
278
|
+
* @returns Upload functions and state
|
|
279
|
+
*/
|
|
280
|
+
declare const useChunkedRestUpload: (options: UseChunkedRestUploadOptions) => UseChunkedRestUploadReturn;
|
|
281
|
+
interface UseDeleteFileOptions {
|
|
282
|
+
/** Base endpoint URL for file operations */
|
|
283
|
+
endpoint: string;
|
|
284
|
+
}
|
|
285
|
+
interface UseDeleteFileReturn {
|
|
286
|
+
/** Delete a file by ID */
|
|
287
|
+
deleteFile: (id: string) => Promise<void>;
|
|
288
|
+
/** Last request error, if any */
|
|
289
|
+
error: Readonly<Ref<Error | undefined>>;
|
|
290
|
+
/** Whether a request is currently in progress */
|
|
291
|
+
isLoading: Readonly<Ref<boolean>>;
|
|
292
|
+
/** Reset mutation state */
|
|
293
|
+
reset: () => void;
|
|
294
|
+
}
|
|
295
|
+
/**
|
|
296
|
+
* Vue composable for deleting a single file using TanStack Query.
|
|
297
|
+
* Automatically invalidates related queries.
|
|
298
|
+
* @param options Hook configuration options
|
|
299
|
+
* @returns File deletion functions and state
|
|
300
|
+
*/
|
|
301
|
+
declare const useDeleteFile: (options: UseDeleteFileOptions) => UseDeleteFileReturn;
|
|
302
|
+
interface UseFileInputOptions {
|
|
303
|
+
/** Accept file types (e.g., "image/*", ".pdf") */
|
|
304
|
+
accept?: string;
|
|
305
|
+
/** Whether to allow multiple file selection */
|
|
306
|
+
multiple?: boolean;
|
|
307
|
+
/** Callback when files are selected */
|
|
308
|
+
onFilesSelected?: (files: File[]) => void;
|
|
309
|
+
}
|
|
310
|
+
interface UseFileInputReturn {
|
|
311
|
+
/** Currently selected files */
|
|
312
|
+
files: Ref<File[]>;
|
|
313
|
+
/** Handle drag leave event */
|
|
314
|
+
handleDragLeave: (event: DragEvent) => void;
|
|
315
|
+
/** Handle drag and drop events */
|
|
316
|
+
handleDragOver: (event: DragEvent) => void;
|
|
317
|
+
/** Handle drop event */
|
|
318
|
+
handleDrop: (event: DragEvent) => void;
|
|
319
|
+
/** Handle file input change event */
|
|
320
|
+
handleFileChange: (event: Event) => void;
|
|
321
|
+
/** File input element ref */
|
|
322
|
+
inputRef: Ref<HTMLInputElement | undefined>;
|
|
323
|
+
/** Open file dialog programmatically */
|
|
324
|
+
openFileDialog: () => void;
|
|
325
|
+
/** Reset selected files */
|
|
326
|
+
reset: () => void;
|
|
327
|
+
}
|
|
328
|
+
/**
|
|
329
|
+
* Vue composable for file input handling with drag & drop support.
|
|
330
|
+
* @param options Configuration options
|
|
331
|
+
* @returns File input functions and state
|
|
332
|
+
*/
|
|
333
|
+
declare const useFileInput: (options?: UseFileInputOptions) => UseFileInputReturn;
|
|
334
|
+
interface UseGetFileOptions {
|
|
335
|
+
/** Whether to enable the query */
|
|
336
|
+
enabled?: MaybeRefOrGetter<boolean>;
|
|
337
|
+
/** Base endpoint URL for file operations */
|
|
338
|
+
endpoint: string;
|
|
339
|
+
/** File ID to fetch */
|
|
340
|
+
id: MaybeRefOrGetter<string>;
|
|
341
|
+
/** Callback when request fails */
|
|
342
|
+
onError?: (error: Error) => void;
|
|
343
|
+
/** Callback when request succeeds */
|
|
344
|
+
onSuccess?: (data: Blob, meta: FileMeta | undefined) => void;
|
|
345
|
+
/** Transformation parameters for media files */
|
|
346
|
+
transform?: MaybeRefOrGetter<Record<string, string | number | boolean> | undefined>;
|
|
347
|
+
}
|
|
348
|
+
interface UseGetFileReturn {
|
|
349
|
+
/** File data as Blob */
|
|
350
|
+
data: Readonly<Ref<Blob | undefined>>;
|
|
351
|
+
/** Last request error, if any */
|
|
352
|
+
error: Readonly<Ref<Error | undefined>>;
|
|
353
|
+
/** Whether a request is currently in progress */
|
|
354
|
+
isLoading: Readonly<Ref<boolean>>;
|
|
355
|
+
/** File metadata from response headers */
|
|
356
|
+
meta: Readonly<Ref<FileMeta | undefined>>;
|
|
357
|
+
/** Refetch the file */
|
|
358
|
+
refetch: () => void;
|
|
359
|
+
}
|
|
360
|
+
/**
|
|
361
|
+
* Vue composable for fetching/downloading files using TanStack Query.
|
|
362
|
+
* Supports optional transformation parameters for media files.
|
|
363
|
+
* @param options Hook configuration options
|
|
364
|
+
* @returns File fetching functions and state
|
|
365
|
+
*/
|
|
366
|
+
declare const useGetFile: (options: UseGetFileOptions) => UseGetFileReturn;
|
|
367
|
+
interface FileListResponse {
|
|
368
|
+
data: FileMeta[];
|
|
369
|
+
meta?: {
|
|
370
|
+
firstPage?: number;
|
|
371
|
+
firstPageUrl?: string;
|
|
372
|
+
lastPage?: number;
|
|
373
|
+
lastPageUrl?: string;
|
|
374
|
+
nextPageUrl?: string;
|
|
375
|
+
page?: number;
|
|
376
|
+
perPage?: number;
|
|
377
|
+
previousPageUrl?: string;
|
|
378
|
+
total?: number;
|
|
379
|
+
};
|
|
380
|
+
}
|
|
381
|
+
interface UseGetFileListOptions {
|
|
382
|
+
/** Whether to enable the query */
|
|
383
|
+
enabled?: MaybeRefOrGetter<boolean>;
|
|
384
|
+
/** Base endpoint URL for file operations */
|
|
385
|
+
endpoint: string;
|
|
386
|
+
/** Maximum number of elements to retrieve */
|
|
387
|
+
limit?: MaybeRefOrGetter<number | undefined>;
|
|
388
|
+
/** Page number for pagination */
|
|
389
|
+
page?: MaybeRefOrGetter<number | undefined>;
|
|
390
|
+
}
|
|
391
|
+
interface UseGetFileListReturn {
|
|
392
|
+
/** File list data */
|
|
393
|
+
data: Readonly<Ref<FileListResponse | undefined>>;
|
|
394
|
+
/** Last request error, if any */
|
|
395
|
+
error: Readonly<Ref<Error | undefined>>;
|
|
396
|
+
/** Whether a request is currently in progress */
|
|
397
|
+
isLoading: Readonly<Ref<boolean>>;
|
|
398
|
+
/** Refetch the file list */
|
|
399
|
+
refetch: () => void;
|
|
400
|
+
}
|
|
401
|
+
/**
|
|
402
|
+
* Vue composable for fetching a list of files using TanStack Query.
|
|
403
|
+
* Supports pagination via query parameters.
|
|
404
|
+
* @param options Hook configuration options
|
|
405
|
+
* @returns File list fetching functions and state
|
|
406
|
+
*/
|
|
407
|
+
declare const useGetFileList: (options: UseGetFileListOptions) => UseGetFileListReturn;
|
|
408
|
+
interface UseGetFileMetaOptions {
|
|
409
|
+
/** Whether to enable the query */
|
|
410
|
+
enabled?: MaybeRefOrGetter<boolean>;
|
|
411
|
+
/** Base endpoint URL for file operations */
|
|
412
|
+
endpoint: string;
|
|
413
|
+
/** File ID to fetch metadata for */
|
|
414
|
+
id: MaybeRefOrGetter<string>;
|
|
415
|
+
}
|
|
416
|
+
interface UseGetFileMetaReturn {
|
|
417
|
+
/** File metadata */
|
|
418
|
+
data: Readonly<Ref<FileMeta | undefined>>;
|
|
419
|
+
/** Last request error, if any */
|
|
420
|
+
error: Readonly<Ref<Error | undefined>>;
|
|
421
|
+
/** Whether a request is currently in progress */
|
|
422
|
+
isLoading: Readonly<Ref<boolean>>;
|
|
423
|
+
/** Refetch the file metadata */
|
|
424
|
+
refetch: () => void;
|
|
425
|
+
}
|
|
426
|
+
/**
|
|
427
|
+
* Vue composable for fetching file metadata using TanStack Query.
|
|
428
|
+
* @param options Hook configuration options
|
|
429
|
+
* @returns File metadata fetching functions and state
|
|
430
|
+
*/
|
|
431
|
+
declare const useGetFileMeta: (options: UseGetFileMetaOptions) => UseGetFileMetaReturn;
|
|
432
|
+
interface FileHeadMetadata {
|
|
433
|
+
/** Whether this is a chunked upload session */
|
|
434
|
+
chunkedUpload?: boolean;
|
|
435
|
+
/** Content length in bytes */
|
|
436
|
+
contentLength?: number;
|
|
437
|
+
/** Content type */
|
|
438
|
+
contentType?: string;
|
|
439
|
+
/** Entity tag for caching */
|
|
440
|
+
etag?: string;
|
|
441
|
+
/** Last modified date */
|
|
442
|
+
lastModified?: string;
|
|
443
|
+
/** Received chunk offsets (chunked uploads) */
|
|
444
|
+
receivedChunks?: number[];
|
|
445
|
+
/** Whether upload is complete (chunked uploads) */
|
|
446
|
+
uploadComplete?: boolean;
|
|
447
|
+
/** Upload expiration date */
|
|
448
|
+
uploadExpires?: string;
|
|
449
|
+
/** Upload offset for chunked uploads */
|
|
450
|
+
uploadOffset?: number;
|
|
451
|
+
}
|
|
452
|
+
interface UseHeadFileOptions {
|
|
453
|
+
/** Whether to enable the query */
|
|
454
|
+
enabled?: MaybeRefOrGetter<boolean>;
|
|
455
|
+
/** Base endpoint URL for file operations */
|
|
456
|
+
endpoint: string;
|
|
457
|
+
/** File ID to fetch metadata for */
|
|
458
|
+
id: MaybeRefOrGetter<string>;
|
|
459
|
+
}
|
|
460
|
+
interface UseHeadFileReturn {
|
|
461
|
+
/** File metadata from HEAD request */
|
|
462
|
+
data: Readonly<Ref<FileHeadMetadata | undefined>>;
|
|
463
|
+
/** Last request error, if any */
|
|
464
|
+
error: Readonly<Ref<Error | undefined>>;
|
|
465
|
+
/** Whether a request is currently in progress */
|
|
466
|
+
isLoading: Readonly<Ref<boolean>>;
|
|
467
|
+
/** Refetch the file metadata */
|
|
468
|
+
refetch: () => void;
|
|
469
|
+
}
|
|
470
|
+
/**
|
|
471
|
+
* Vue composable for fetching file metadata via HEAD request using TanStack Query.
|
|
472
|
+
* Useful for checking upload progress and file status without downloading.
|
|
473
|
+
* @param options Hook configuration options
|
|
474
|
+
* @returns File HEAD request functions and state
|
|
475
|
+
*/
|
|
476
|
+
declare const useHeadFile: (options: UseHeadFileOptions) => UseHeadFileReturn;
|
|
477
|
+
interface UseMultipartUploadOptions {
|
|
478
|
+
/** Upload endpoint URL */
|
|
479
|
+
endpoint: string;
|
|
480
|
+
/** Additional metadata to include with the upload */
|
|
481
|
+
metadata?: Record<string, string>;
|
|
482
|
+
/** Callback when upload fails */
|
|
483
|
+
onError?: (error: Error) => void;
|
|
484
|
+
/** Callback when upload progress updates */
|
|
485
|
+
onProgress?: (progress: number) => void;
|
|
486
|
+
/** Callback when upload starts */
|
|
487
|
+
onStart?: () => void;
|
|
488
|
+
/** Callback when upload completes successfully */
|
|
489
|
+
onSuccess?: (file: UploadResult) => void;
|
|
490
|
+
}
|
|
491
|
+
interface UseMultipartUploadReturn {
|
|
492
|
+
/** Last upload error, if any */
|
|
493
|
+
error: Ref<Error | undefined>;
|
|
494
|
+
/** Whether an upload is currently in progress */
|
|
495
|
+
isUploading: Ref<boolean>;
|
|
496
|
+
/** Current upload progress (0-100) */
|
|
497
|
+
progress: Ref<number>;
|
|
498
|
+
/** Reset upload state */
|
|
499
|
+
reset: () => void;
|
|
500
|
+
/** Last upload result, if any */
|
|
501
|
+
result: Ref<UploadResult | undefined>;
|
|
502
|
+
/** Upload a file using multipart/form-data */
|
|
503
|
+
upload: (file: File) => Promise<UploadResult>;
|
|
504
|
+
}
|
|
505
|
+
/**
|
|
506
|
+
* Vue composable for multipart/form-data file uploads using rpldy uploader core.
|
|
507
|
+
* @param options Upload configuration options
|
|
508
|
+
* @returns Upload functions and state
|
|
509
|
+
*/
|
|
510
|
+
declare const useMultipartUpload: (options: UseMultipartUploadOptions) => UseMultipartUploadReturn;
|
|
511
|
+
interface UsePasteUploadOptions {
|
|
512
|
+
/** Filter function to determine which files to accept */
|
|
513
|
+
filter?: (file: File) => boolean;
|
|
514
|
+
/** Callback when files are pasted */
|
|
515
|
+
onFilesPasted?: (files: File[]) => void;
|
|
516
|
+
}
|
|
517
|
+
interface UsePasteUploadReturn {
|
|
518
|
+
/** Handle paste event */
|
|
519
|
+
handlePaste: (event: ClipboardEvent) => void;
|
|
520
|
+
/** Files that were pasted */
|
|
521
|
+
pastedFiles: Ref<File[]>;
|
|
522
|
+
/** Reset pasted files */
|
|
523
|
+
reset: () => void;
|
|
524
|
+
}
|
|
525
|
+
/**
|
|
526
|
+
* Vue composable for handling paste uploads from clipboard.
|
|
527
|
+
* @param options Configuration options
|
|
528
|
+
* @returns Paste upload functions and state
|
|
529
|
+
*/
|
|
530
|
+
declare const usePasteUpload: (options?: UsePasteUploadOptions) => UsePasteUploadReturn;
|
|
531
|
+
interface UsePatchChunkOptions {
|
|
532
|
+
/** Base endpoint URL for file operations */
|
|
533
|
+
endpoint: string;
|
|
534
|
+
}
|
|
535
|
+
interface UsePatchChunkReturn {
|
|
536
|
+
/** Last upload result, if any */
|
|
537
|
+
data: Readonly<Ref<UploadResult | undefined>>;
|
|
538
|
+
/** Last request error, if any */
|
|
539
|
+
error: Readonly<Ref<Error | undefined>>;
|
|
540
|
+
/** Whether a request is currently in progress */
|
|
541
|
+
isLoading: Readonly<Ref<boolean>>;
|
|
542
|
+
/** Upload a chunk for chunked uploads */
|
|
543
|
+
patchChunk: (id: string, chunk: Blob, offset: number, checksum?: string) => Promise<UploadResult>;
|
|
544
|
+
/** Reset mutation state */
|
|
545
|
+
reset: () => void;
|
|
546
|
+
}
|
|
547
|
+
/**
|
|
548
|
+
* Vue composable for uploading chunks in chunked uploads using TanStack Query.
|
|
549
|
+
* Requires X-Chunk-Offset header and chunk data.
|
|
550
|
+
* Automatically invalidates related queries when upload is complete.
|
|
551
|
+
* @param options Hook configuration options
|
|
552
|
+
* @returns Chunk upload functions and state
|
|
553
|
+
*/
|
|
554
|
+
declare const usePatchChunk: (options: UsePatchChunkOptions) => UsePatchChunkReturn;
|
|
555
|
+
interface UsePutFileOptions {
|
|
556
|
+
/** Base endpoint URL for file operations */
|
|
557
|
+
endpoint: string;
|
|
558
|
+
/** Callback when upload progress updates */
|
|
559
|
+
onProgress?: (progress: number) => void;
|
|
560
|
+
}
|
|
561
|
+
interface UsePutFileReturn {
|
|
562
|
+
/** Last upload result, if any */
|
|
563
|
+
data: Readonly<Ref<UploadResult | undefined>>;
|
|
564
|
+
/** Last request error, if any */
|
|
565
|
+
error: Readonly<Ref<Error | undefined>>;
|
|
566
|
+
/** Whether a request is currently in progress */
|
|
567
|
+
isLoading: Readonly<Ref<boolean>>;
|
|
568
|
+
/** Current upload progress (0-100) */
|
|
569
|
+
progress: Readonly<Ref<number>>;
|
|
570
|
+
/** Create or update a file by ID */
|
|
571
|
+
putFile: (id: string, file: File | Blob) => Promise<UploadResult>;
|
|
572
|
+
/** Reset mutation state */
|
|
573
|
+
reset: () => void;
|
|
574
|
+
}
|
|
575
|
+
/**
|
|
576
|
+
* Vue composable for creating or updating files via PUT request using TanStack Query.
|
|
577
|
+
* Automatically invalidates related queries.
|
|
578
|
+
* @param options Hook configuration options
|
|
579
|
+
* @returns File PUT functions and state
|
|
580
|
+
*/
|
|
581
|
+
declare const usePutFile: (options: UsePutFileOptions) => UsePutFileReturn;
|
|
582
|
+
interface UseRetryOptions {
|
|
583
|
+
/** Upload endpoint URL (used to create uploader instance) */
|
|
584
|
+
endpoint: string;
|
|
585
|
+
/** Additional metadata to include with the upload */
|
|
586
|
+
metadata?: Record<string, string>;
|
|
587
|
+
}
|
|
588
|
+
interface UseRetryReturn {
|
|
589
|
+
/** Retry a failed upload item by ID */
|
|
590
|
+
retryItem: (id: string) => void;
|
|
591
|
+
}
|
|
592
|
+
/**
|
|
593
|
+
* Vue composable to retry a failed upload item.
|
|
594
|
+
* @param options Configuration options
|
|
595
|
+
* @returns Retry function
|
|
596
|
+
*/
|
|
597
|
+
declare const useRetry: (options: UseRetryOptions) => UseRetryReturn;
|
|
598
|
+
interface UseRetryListenerOptions {
|
|
599
|
+
/** Upload endpoint URL (used to create uploader instance) */
|
|
600
|
+
endpoint: string;
|
|
601
|
+
/** Additional metadata to include with the upload */
|
|
602
|
+
metadata?: Record<string, string>;
|
|
603
|
+
/** Callback when an item is retried */
|
|
604
|
+
onRetry: (item: UploadItem) => void;
|
|
605
|
+
}
|
|
606
|
+
/**
|
|
607
|
+
* Vue composable to listen to retry events.
|
|
608
|
+
* Note: This listens to ITEM_START events for items that have been retried (retryCount > 0).
|
|
609
|
+
* @param options Listener configuration options
|
|
610
|
+
*/
|
|
611
|
+
declare const useRetryListener: (options: UseRetryListenerOptions) => void;
|
|
612
|
+
interface TransformOptions {
|
|
613
|
+
/** Additional transformation parameters */
|
|
614
|
+
[key: string]: string | number | boolean | undefined;
|
|
615
|
+
/** Resize fit mode */
|
|
616
|
+
fit?: "cover" | "contain" | "fill" | "inside" | "outside";
|
|
617
|
+
/** Output format (jpeg, png, webp, etc.) */
|
|
618
|
+
format?: string;
|
|
619
|
+
/** Desired height in pixels */
|
|
620
|
+
height?: number;
|
|
621
|
+
/** Quality setting (0-100) */
|
|
622
|
+
quality?: number;
|
|
623
|
+
/** Desired width in pixels */
|
|
624
|
+
width?: number;
|
|
625
|
+
}
|
|
626
|
+
interface UseTransformFileOptions {
|
|
627
|
+
/** Whether to enable the query */
|
|
628
|
+
enabled?: MaybeRefOrGetter<boolean>;
|
|
629
|
+
/** Base endpoint URL for transform operations */
|
|
630
|
+
endpoint: string;
|
|
631
|
+
/** File ID to transform */
|
|
632
|
+
id: MaybeRefOrGetter<string>;
|
|
633
|
+
/** Transformation parameters */
|
|
634
|
+
transform: MaybeRefOrGetter<TransformOptions>;
|
|
635
|
+
}
|
|
636
|
+
interface UseTransformFileReturn {
|
|
637
|
+
/** Transformed file data as Blob */
|
|
638
|
+
data: Readonly<Ref<Blob | undefined>>;
|
|
639
|
+
/** Last request error, if any */
|
|
640
|
+
error: Readonly<Ref<Error | undefined>>;
|
|
641
|
+
/** Whether a request is currently in progress */
|
|
642
|
+
isLoading: Readonly<Ref<boolean>>;
|
|
643
|
+
/** File metadata from response headers */
|
|
644
|
+
meta: Readonly<Ref<FileMeta | undefined>>;
|
|
645
|
+
/** Refetch the transformed file */
|
|
646
|
+
refetch: () => void;
|
|
647
|
+
}
|
|
648
|
+
/**
|
|
649
|
+
* Vue composable for fetching transformed files using TanStack Query.
|
|
650
|
+
* Supports image, video, and audio transformation parameters.
|
|
651
|
+
* @param options Hook configuration options
|
|
652
|
+
* @returns Transform file fetching functions and state
|
|
653
|
+
*/
|
|
654
|
+
declare const useTransformFile: (options: UseTransformFileOptions) => UseTransformFileReturn;
|
|
655
|
+
interface TransformMetadata {
|
|
656
|
+
/** Available transformation formats */
|
|
657
|
+
formats?: string[];
|
|
658
|
+
/** Supported transformation parameters */
|
|
659
|
+
parameters?: string[];
|
|
660
|
+
}
|
|
661
|
+
interface UseTransformMetadataOptions {
|
|
662
|
+
/** Whether to enable the query */
|
|
663
|
+
enabled?: MaybeRefOrGetter<boolean>;
|
|
664
|
+
/** Base endpoint URL for transform operations */
|
|
665
|
+
endpoint: string;
|
|
666
|
+
}
|
|
667
|
+
interface UseTransformMetadataReturn {
|
|
668
|
+
/** Transform metadata */
|
|
669
|
+
data: Readonly<Ref<TransformMetadata | undefined>>;
|
|
670
|
+
/** Last request error, if any */
|
|
671
|
+
error: Readonly<Ref<Error | undefined>>;
|
|
672
|
+
/** Whether a request is currently in progress */
|
|
673
|
+
isLoading: Readonly<Ref<boolean>>;
|
|
674
|
+
/** Refetch the transform metadata */
|
|
675
|
+
refetch: () => void;
|
|
676
|
+
}
|
|
677
|
+
/**
|
|
678
|
+
* Vue composable for fetching transformation metadata using TanStack Query.
|
|
679
|
+
* Returns available formats and transformation parameters.
|
|
680
|
+
* @param options Hook configuration options
|
|
681
|
+
* @returns Transform metadata fetching functions and state
|
|
682
|
+
*/
|
|
683
|
+
declare const useTransformMetadata: (options: UseTransformMetadataOptions) => UseTransformMetadataReturn;
|
|
684
|
+
interface UseTusUploadOptions {
|
|
685
|
+
/** Chunk size for TUS uploads (default: 1MB) */
|
|
686
|
+
chunkSize?: number;
|
|
687
|
+
/** TUS upload endpoint URL */
|
|
688
|
+
endpoint: string;
|
|
689
|
+
/** Maximum number of retry attempts */
|
|
690
|
+
maxRetries?: number;
|
|
691
|
+
/** Additional metadata to include with the upload */
|
|
692
|
+
metadata?: Record<string, string>;
|
|
693
|
+
/** Callback when upload fails */
|
|
694
|
+
onError?: (error: Error) => void;
|
|
695
|
+
/** Callback when upload is paused */
|
|
696
|
+
onPause?: () => void;
|
|
697
|
+
/** Callback when upload progress updates */
|
|
698
|
+
onProgress?: (progress: number) => void;
|
|
699
|
+
/** Callback when upload is resumed */
|
|
700
|
+
onResume?: () => void;
|
|
701
|
+
/** Callback when upload starts */
|
|
702
|
+
onStart?: () => void;
|
|
703
|
+
/** Callback when upload completes successfully */
|
|
704
|
+
onSuccess?: (file: UploadResult) => void;
|
|
705
|
+
/** Enable automatic retry on failure */
|
|
706
|
+
retry?: boolean;
|
|
707
|
+
}
|
|
708
|
+
interface UseTusUploadReturn {
|
|
709
|
+
/** Abort the current upload */
|
|
710
|
+
abort: () => void;
|
|
711
|
+
/** Last upload error, if any */
|
|
712
|
+
error: Ref<Error | undefined>;
|
|
713
|
+
/** Whether the upload is paused */
|
|
714
|
+
isPaused: Ref<boolean>;
|
|
715
|
+
/** Whether an upload is currently in progress */
|
|
716
|
+
isUploading: Ref<boolean>;
|
|
717
|
+
/** Current upload offset (bytes uploaded) */
|
|
718
|
+
offset: Ref<number>;
|
|
719
|
+
/** Pause the current upload */
|
|
720
|
+
pause: () => void;
|
|
721
|
+
/** Current upload progress (0-100) */
|
|
722
|
+
progress: Ref<number>;
|
|
723
|
+
/** Reset upload state */
|
|
724
|
+
reset: () => void;
|
|
725
|
+
/** Last upload result, if any */
|
|
726
|
+
result: Ref<UploadResult | undefined>;
|
|
727
|
+
/** Resume a paused upload */
|
|
728
|
+
resume: () => Promise<void>;
|
|
729
|
+
/** Upload a file using TUS protocol */
|
|
730
|
+
upload: (file: File) => Promise<UploadResult>;
|
|
731
|
+
}
|
|
732
|
+
/**
|
|
733
|
+
* Vue composable for TUS resumable file uploads.
|
|
734
|
+
* @param options Upload configuration options
|
|
735
|
+
* @returns Upload functions and state
|
|
736
|
+
*/
|
|
737
|
+
declare const useTusUpload: (options: UseTusUploadOptions) => UseTusUploadReturn;
|
|
738
|
+
interface UseUploadOptions {
|
|
739
|
+
/** Chunk size for TUS and chunked REST uploads (default: 1MB for TUS, 5MB for chunked REST) */
|
|
740
|
+
chunkSize?: number;
|
|
741
|
+
/** Chunked REST upload endpoint URL */
|
|
742
|
+
endpointChunkedRest?: string;
|
|
743
|
+
/** Multipart upload endpoint URL */
|
|
744
|
+
endpointMultipart?: string;
|
|
745
|
+
/** TUS upload endpoint URL */
|
|
746
|
+
endpointTus?: string;
|
|
747
|
+
/** Maximum number of retry attempts (TUS and chunked REST only) */
|
|
748
|
+
maxRetries?: number;
|
|
749
|
+
/** Additional metadata to include with the upload */
|
|
750
|
+
metadata?: Record<string, string>;
|
|
751
|
+
/** Upload method to use: 'multipart', 'tus', 'chunked-rest', or 'auto'. If undefined, auto-detected based on provided endpoints */
|
|
752
|
+
method?: UploadMethod;
|
|
753
|
+
/** Callback when upload fails */
|
|
754
|
+
onError?: (error: Error) => void;
|
|
755
|
+
/** Callback when upload is paused (TUS and chunked REST only) */
|
|
756
|
+
onPause?: () => void;
|
|
757
|
+
/** Callback when upload progress updates */
|
|
758
|
+
onProgress?: (progress: number) => void;
|
|
759
|
+
/** Callback when upload is resumed (TUS and chunked REST only) */
|
|
760
|
+
onResume?: () => void;
|
|
761
|
+
/** Callback when upload starts */
|
|
762
|
+
onStart?: () => void;
|
|
763
|
+
/** Callback when upload completes successfully */
|
|
764
|
+
onSuccess?: (file: UploadResult) => void;
|
|
765
|
+
/** Enable automatic retry on failure (TUS and chunked REST only) */
|
|
766
|
+
retry?: boolean;
|
|
767
|
+
/** File size threshold for auto-selecting TUS (default: 10MB) */
|
|
768
|
+
tusThreshold?: number;
|
|
769
|
+
}
|
|
770
|
+
interface UseUploadReturn {
|
|
771
|
+
/** Abort the current upload */
|
|
772
|
+
abort: () => void;
|
|
773
|
+
/** Current upload method being used */
|
|
774
|
+
currentMethod: ComputedRef<UploadMethod>;
|
|
775
|
+
/** Last upload error, if any */
|
|
776
|
+
error: ComputedRef<Error | undefined>;
|
|
777
|
+
/** Whether the upload is paused (TUS and chunked REST only) */
|
|
778
|
+
isPaused: ComputedRef<boolean | undefined>;
|
|
779
|
+
/** Whether an upload is currently in progress */
|
|
780
|
+
isUploading: ComputedRef<boolean>;
|
|
781
|
+
/** Current upload offset in bytes (TUS and chunked REST only) */
|
|
782
|
+
offset: ComputedRef<number | undefined>;
|
|
783
|
+
/** Pause the current upload (TUS and chunked REST only) */
|
|
784
|
+
pause: ComputedRef<(() => void) | undefined>;
|
|
785
|
+
/** Current upload progress (0-100) */
|
|
786
|
+
progress: ComputedRef<number>;
|
|
787
|
+
/** Reset upload state */
|
|
788
|
+
reset: () => void;
|
|
789
|
+
/** Last upload result, if any */
|
|
790
|
+
result: ComputedRef<UploadResult | undefined>;
|
|
791
|
+
/** Resume a paused upload (TUS and chunked REST only) */
|
|
792
|
+
resume: ComputedRef<(() => Promise<void>) | undefined>;
|
|
793
|
+
/** Upload a file using the configured method */
|
|
794
|
+
upload: (file: File) => Promise<UploadResult>;
|
|
795
|
+
}
|
|
796
|
+
/**
|
|
797
|
+
* Vue composable for file uploads with automatic method selection.
|
|
798
|
+
* Uses custom uploader implementations for multipart, TUS, and chunked REST.
|
|
799
|
+
* Automatically chooses between methods based on file size and method preference.
|
|
800
|
+
* @param options Upload configuration options
|
|
801
|
+
* @returns Upload functions and state
|
|
802
|
+
*/
|
|
803
|
+
declare const useUpload: (options: UseUploadOptions) => UseUploadReturn;
|
|
804
|
+
export { type BatchDeleteResult, type FileHeadMetadata, type FileListResponse, type TransformMetadata, type TransformOptions, type UseAbortAllOptions, type UseAbortAllReturn, type UseAbortBatchOptions, type UseAbortBatchReturn, type UseAbortItemOptions, type UseAbortItemReturn, type UseAllAbortListenerOptions, type UseBatchCancelledListenerOptions, type UseBatchDeleteFilesOptions, type UseBatchDeleteFilesReturn, type UseBatchErrorListenerOptions, type UseBatchFinalizeListenerOptions, type UseBatchFinishListenerOptions, type UseBatchProgressListenerOptions, type UseBatchRetryOptions, type UseBatchRetryReturn, type UseBatchStartListenerOptions, type UseBatchUploadOptions, type UseBatchUploadReturn, type UseChunkedRestUploadOptions, type UseChunkedRestUploadReturn, type UseDeleteFileOptions, type UseDeleteFileReturn, type UseFileInputOptions, type UseFileInputReturn, type UseGetFileListOptions, type UseGetFileListReturn, type UseGetFileMetaOptions, type UseGetFileMetaReturn, type UseGetFileOptions, type UseGetFileReturn, type UseHeadFileOptions, type UseHeadFileReturn, type UseMultipartUploadOptions, type UseMultipartUploadReturn, type UsePasteUploadOptions, type UsePasteUploadReturn, type UsePatchChunkOptions, type UsePatchChunkReturn, type UsePutFileOptions, type UsePutFileReturn, type UseRetryListenerOptions, type UseRetryOptions, type UseRetryReturn, type UseTransformFileOptions, type UseTransformFileReturn, type UseTransformMetadataOptions, type UseTransformMetadataReturn, type UseTusUploadOptions, type UseTusUploadReturn, type UseUploadOptions, type UseUploadReturn, useAbortAll, useAbortBatch, useAbortItem, useAllAbortListener, useBatchCancelledListener, useBatchDeleteFiles, useBatchErrorListener, useBatchFinalizeListener, useBatchFinishListener, useBatchProgressListener, useBatchRetry, useBatchStartListener, useBatchUpload, useChunkedRestUpload, useDeleteFile, useFileInput, useGetFile, useGetFileList, useGetFileMeta, useHeadFile, useMultipartUpload, usePasteUpload, usePatchChunk, usePutFile, useRetry, useRetryListener, useTransformFile, useTransformMetadata, useTusUpload, useUpload };
|