WelcomeUser Guide
ToSPrivacyCanary
DonateBugsLicense

©2024 Poal.co

1.1K

(post is archived)

[–] 2 pts 4y

Yes.

[–] 2 pts 4y

Interesting. Help me better understand what you're going for.

When you paste your image, is it just a path to the screenshot on your local machine? Or is it the actual binary image data itself?

Are you working from a mobile device, or a desktop?

[–] 1 pt 4y

When I hit PrintScreen on a laptop, it pastes an image to the clipboard. In Imgur, I can then place the cursor in the url field, and it will accept the image.

Pretty sure it is transporting the binary. The file is not saved, officially, on the machine, so it is possible it is floating around in some temporary folder. On PC, anyways.

On android, it works almost exactly the same. You simply hold your finger on an image, and it allows you to copy to the clipboard. Very few things will allow you to paste from the android clipboard, but Imgur is one of them.

I don't know about Apple. They usually suck compared to everyone else because they intentionally design their portable device UIs to slow people down.

[–] 3 pts 4y (edited 4y)

Pretty sure it is transporting the binary. The file is not saved, officially, on the machine, so it is possible it is floating around in some temporary folder. On PC, anyways.

The image is actually saved in your device's clipboard encoded in base64 and converted back to a file and stored in your browser's FileList when you paste it, then it is sent with the form when you submit it.

https://w3c.github.io/clipboard-apis

I'm working on a homemade version to paste images from clipboard. Stay Tuned!

[–] 2 pts 4y

This can be easily done with Clipboard API (common in most recent browsers)

https://w3c.github.io/clipboard-apis/

[–] 1 pt 4y

Thanks for the reference. Would you be able to help me narrow down the functions of the API which could be used to achieve this?

Thanks!

[–] 1 pt 4y

Sure!

Come to matrix chat, we can discuss it there.