aws / mynah-ui

The chat interface of Amazon Q Developer (for IDEs)
https://aws.github.io/mynah-ui/
Apache License 2.0
15 stars 14 forks source link

Dogusata/add check statement to clipboard access #53

Closed dogusata closed 4 months ago

dogusata commented 4 months ago

Problem

If clipboard is not available, webviews throwing an error and blocks the rest of the usage when user hits copy button on code blocks.

Solution

Clipboard access is wrapped with a try/finally statement. Even though we don't have access to clipboard, we're still throwing internal event to make the text copy operation handled by the consumer.

License

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.