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

Expose Clipboard#read/write with data transfer #77790

Closed
liang2zhu1 opened this issue Jul 23, 2019 · 11 comments
Closed

Expose Clipboard#read/write with data transfer #77790

liang2zhu1 opened this issue Jul 23, 2019 · 11 comments
Assignees
Labels
api editor-clipboard Editor clipboard issues feature-request Request for new features or functionality *out-of-scope Posted issue is not in scope of VS Code upstream Issue identified as 'upstream' component related (exists outside of VS Code)
Milestone

Comments

@liang2zhu1
Copy link

Can you provide HTML clipboard access which is available in Electron? i.e. expose that in extHostClipboard.ts

@jrieken jrieken changed the title HTML clipboard access for extension developer Expose Clipboard#read/write with data transfer Jul 23, 2019
@jrieken jrieken added api editor-clipboard Editor clipboard issues feature-request Request for new features or functionality labels Jul 23, 2019
@jrieken
Copy link
Member

jrieken commented Jul 23, 2019

We have no plans of exposing any of the "custom" electron API but our plan is to explore the JS standard APIs: https://developer.mozilla.org/en-US/docs/Web/API/Clipboard. Once read/write is ready, and supported in Electron, we will expose them in the API.

@liang2zhu1
Copy link
Author

Thanks for the answer, sad but makes sense.

@jrieken jrieken reopened this Jul 25, 2019
@jrieken
Copy link
Member

jrieken commented Jul 25, 2019

I keeping this open so that we can tackle this once the underlying API is ready

@jrieken jrieken added the upstream Issue identified as 'upstream' component related (exists outside of VS Code) label Jul 25, 2019
@jrieken jrieken added this to the Backlog Candidates milestone Oct 31, 2019
@vscodebot
Copy link

vscodebot bot commented Jan 15, 2020

This feature request is now a candidate for our backlog. The community has 60 days to upvote the issue. If it receives 20 upvotes we will move it to our backlog. If not, we will close it. To learn more about how we handle feature requests, please see our documentation.

Happy Coding!

@jrieken jrieken modified the milestones: Backlog Candidates, Backlog Jan 16, 2020
@spottedmahn
Copy link

If this was implemented, would that allow for more than text in the Clipboard API?

Looks like this Paste Image extension doesn't work in WSL b/c of this?

Remote -> Tips & Tricks -> Clipboard does not work

Unfortunately, this may cause the extension to incorrectly integrate with the clipboard on the remote side.
Resolution: The extension can switch to the VS Code clipboard API to resolve the problem.

@mmdjiji
Copy link

mmdjiji commented Mar 14, 2022

But I saw https://developer.mozilla.org/en-US/docs/Web/API/Clipboard/read, mozilla standard supports read() method, which can be used to get image from the clipboard.

@Lemmingh
Copy link
Contributor

Lemmingh commented Mar 14, 2022

@mmdjiji

Everyone here is already aware of the Clipboard API, and waits patiently. You don't need to ping or bump. Just click Subscribe.

The specification is managed by W3C, not Mozilla.

The APIs still have a long way to go before becoming production-ready, and receive very limited support now.

@mmdjiji
Copy link

mmdjiji commented Mar 14, 2022

@mmdjiji

Everyone here is already aware of the Clipboard API, and waits patiently. You don't need to ping or bump.

The specification is managed by W3C, not Mozilla.

The APIs still have a long way to go before becoming production-ready, and receive very limited support now.

Okay, thank you! I am sorry about my ping or bump, and I will wait for it.

@jrieken jrieken added the *out-of-scope Posted issue is not in scope of VS Code label Dec 7, 2022
@vscodenpa
Copy link

We closed this issue because we don't plan to address it in the foreseeable future. If you disagree and feel that this issue is crucial: we are happy to listen and to reconsider.

If you wonder what we are up to, please see our roadmap and issue reporting guidelines.

Thanks for your understanding, and happy coding!

@vscodenpa vscodenpa closed this as not planned Won't fix, can't repro, duplicate, stale Dec 7, 2022
@jrieken
Copy link
Member

jrieken commented Dec 7, 2022

There is still no good support across browsers for this: https://developer.mozilla.org/en-US/docs/Web/API/Clipboard#browser_compatibility

@tkluck
Copy link

tkluck commented Jul 31, 2024

There is still no good support across browsers for this: https://developer.mozilla.org/en-US/docs/Web/API/Clipboard#browser_compatibility

Some time has passed and this seems pretty well supported by now 🥳 I'd be interested in this API should it become available, so I'm just posting a gentle bump here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api editor-clipboard Editor clipboard issues feature-request Request for new features or functionality *out-of-scope Posted issue is not in scope of VS Code upstream Issue identified as 'upstream' component related (exists outside of VS Code)
Projects
None yet
Development

No branches or pull requests

7 participants