Skip to content
This repository has been archived by the owner on Feb 8, 2024. It is now read-only.

Implement move capability for directory sharing #1064

Closed
ibeckermayer opened this issue Aug 1, 2022 · 1 comment
Closed

Implement move capability for directory sharing #1064

ibeckermayer opened this issue Aug 1, 2022 · 1 comment
Assignees

Comments

@ibeckermayer
Copy link

ibeckermayer commented Aug 1, 2022

Currently, successfully fulfilling a TDP SharedDirectoryMoveRequest is unimplemented (the user will see an error modal) because (source)

The FileSystemHandle.move() method has shipped for files within the origin private file system (OPFS), is behind a flag for files if the source or destination is outside of the OPFS, and is not yet supported for directories.

One option for resolving this is to implement a move "manually" by (source):

creating a new file/directory, copying over data (recursively, in the case of a directory), and removing the original

however

This process is slow, error prone (e.g. disk full), and can require re-uploading files in some cases.

Ideally we will be able to use an inbuilt FileSystemHandle.move() method. The tracking issue appears to be whatwg/fs#10, and the closest thing I've found to a launch date is "relatively soon": WICG/file-system-access#50 (comment) (June 6, 2022)

See 53510cc for an implementation that should be close to working when the feature is added to browsers.

@ibeckermayer
Copy link
Author

Moved to gravitational/teleport#16048

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant