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

The copy to clipboard icon on code blocks is not displaying correctly #255

Open
marc1404 opened this issue Jan 17, 2025 · 0 comments
Open
Labels

Comments

@marc1404
Copy link
Member

What happened:

The copy icon of the copy to clipboard button on code blocks is not displaying correctly.

Image

What you expected to happen:

The copy icon should be displayed correctly.

Image

How to reproduce it (as minimally and precisely as possible):

  1. Open any documentation page on https://gardener.cloud that has a code block, e.g. https://gardener.cloud/docs/gardener/project/namespaced-cloud-profiles/
  2. Look at the copy to clipboard button at the top-right corner of the code block.

Anything else we need to know:

The Docsy code that generates the button and icon lives here:
https://github.com/google/docsy/blob/main/assets/js/click-to-copy.js

However, the code was changed last ~2-3 years ago.

A potential fix (like shown in the expected screenshot) is to create an <i class="fas fa-copy"></i> child element of the copy button.
As Docsy controls this code, this fix is not easily applied, suggesting the issue might lie on our side.

Environment:
https://gardener.cloud

Browsers: Latest MS Edge, latest Google Chrome

@marc1404 marc1404 added the kind/bug Bug label Jan 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant