Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(android): Copy image to clipboard via temp image (#551) #2127

Closed
wants to merge 0 commits into from

Conversation

tobeagram
Copy link

Currently there's an long outstanding bug with @capacitor/clipboard, where images on Android are copied as a base64 string rather than an image (#551).

The best workaround seems to be using a FileProvider to save an image to the clipboard. This approach ensures that the file URI is correctly exposed as a content URI, avoiding the FileUriExposedException and allowing other apps to access and paste the image.

I've validated and tested this on Android API 33 running Capacitor 5 and 6.

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

Successfully merging this pull request may close these issues.

None yet

1 participant