fix(sftp): make panel pause feel immediate

Paint paused optimistically, stop counting paused rows as "active", freeze
visible progress while paused, and soft-drain concurrent pause in ~50ms
without long writeStream waits on the contiguous-range path.
This commit is contained in:
bincxz committed 2026-07-25 21:55:47 +08:00
1 parent f5920ea56a
commit 8a97e3c555
5 files changed
+88 -48

No files matched your search

@@ -85,6 +85,8 @@ export const createUploadTaskCallbacks = ({
const durableCheckpoint = Number.isFinite(Number(progress.checkpointBytes))
? Math.max(0, Math.trunc(Number(progress.checkpointBytes)))
: progress.transferred;
// Only patch fingerprint/checkpoint while paused — do not keep animating
// high-water transferred after the user hit Pause.
updateExternalUpload?.(taskId, {
transferredBytes: progress.transferred,
// Soft-drain high-water transferred must not become the resume offset.