papermark icon indicating copy to clipboard operation
papermark copied to clipboard

feat: dropbox chooser intgn

Open yashsharma999 opened this issue 1 year ago • 8 comments

Users can upload files from Dropbox using Dropbox Chooser Screenshot 2024-09-16 at 10 25 54 PM

Authentication and selecting the file Screenshot 2024-09-16 at 10 42 00 PM

Screenshot 2024-09-16 at 10 27 30 PM

File is downloaded and upload to the existing Document Upload component. Screenshot 2024-09-16 at 10 31 28 PM

  • Dropbox Chooser documentation : https://www.dropbox.com/developers/chooser
  • Will require a dropbox app key. Using NEXT_PUBLIC_DROPBOX_APP_KEY env variable.
  • #64
  • UI similar to #590

yashsharma999 avatar Sep 16 '24 17:09 yashsharma999

@yashsharma999 is attempting to deploy a commit to the mftsio Team on Vercel.

A member of the Team first needs to authorize it.

vercel[bot] avatar Sep 16 '24 17:09 vercel[bot]

PR Summary

  • Improvement in File Validation Process The procedure for checking whether a file is valid or not has been made more efficient. This was achieved by shifting the logic for this validation into a separate function called fileValidations. This modification makes the process of uploading a document more streamlined.

  • Inclusion of DropboxChooser Component A new feature has been introduced, named the DropboxChooser component. It provides functionality for users to import files directly from their Dropbox account, making file uploading a more seamless process.

  • DropboxChooser Integrated with DocumentUploader The existing document uploading component, DocumentUpload, has been updated to include the new DropboxChooser component. This enhancement gives users an alternative solution to import files when there are no files selected for uploading.

  • Addition of Dropbox Icon A new graphical image (SVG file) for the Dropbox icon has been added. This icon is used within the DropboxChooser button, making it easy for users to recognize the Dropbox file import option.

what-the-diff[bot] avatar Sep 16 '24 17:09 what-the-diff[bot]

Awesome @yashsharma999

Does it allow multi-file uploads? We have @tus/server for multi-file uploads and I was wondering if we could integrate that somehow with these integration pickers to let users upload one or multiple files .

mfts avatar Sep 16 '24 17:09 mfts

Yes, it supports multiple file uploads. I'll look into how we can best integrate it with the existing setup.

yashsharma999 avatar Sep 16 '24 17:09 yashsharma999

All contributors have signed the CLA ✍️ ✅
Posted by the CLA Assistant Lite bot.

github-actions[bot] avatar Sep 30 '24 14:09 github-actions[bot]

I have read the CLA Document and I hereby sign the CLA

yashsharma999 avatar Sep 30 '24 14:09 yashsharma999

recheck

yashsharma999 avatar Sep 30 '24 14:09 yashsharma999

Made the following change to support multiple file upload

  • Add multiselect: true in Dropbox Chooser options
  • On selecting multiple files from dropbox, trigger a custom drop event on <UploadZone /> component, this component handles all validations and @tus/server related operations.

@mfts let me know your thoughts on this approach

yashsharma999 avatar Sep 30 '24 14:09 yashsharma999