v0l / snort

Feature packed nostr web UI, Mirror of https://git.v0l.io/Kieran/snort
https://snort.social
MIT License
321 stars 124 forks source link

Allow pasting images from clipboard #502

Closed vivganes closed 1 year ago

vivganes commented 1 year ago

Is your feature request related to a problem? Please describe. When I want to upload a screenshot to Snort, I first need to store it in my local desktop. That's a wee bit inconvenient when compared to flows in Telegram, etc.

Describe the solution you'd like I want to be able to paste from my clipboard.

Describe alternatives you've considered None

Additional context I am willing work on this feature Probable solution: https://stackoverflow.com/a/73659331

v0l commented 1 year ago

This is supported by void.cat, please use the code from here: https://github.com/v0l/void.cat/blob/v4-re/VoidCat/spa/src/Components/FileUpload/Dropzone.js

vivganes commented 1 year ago

@v01 void.cat seems to have a multi-file upload progress indicator too. I am hoping that's not needed here.

In that case, we just have to add a paste listener and upload the image, like you are already doing in the existing code.

Is my thinking correct?

v0l commented 1 year ago

Yea just pasting is fine, i will add progress myself at some stage, its badly needed