radius-project / radius-project/docs

Copy code button not working

Open
#1,954 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug triaged
Dominant language
Bicep
Stars
26
Forks
52
Avg merge
3d 2h
Merged PRs (30d)
3

Description

Describe the bug

On a code block, there should be a copy code button on mouseover to copy the code to the clipboard. Now:

  1. On mouseover, the javascript responds by adding a new line to the outer box.
  2. If you mouseover the top right portion of the code block, the copy button appears, but it misaligned, and the "Copy to clipboard" label is flashes

See screenshots.

Steps to reproduce

  1. Visit the quickstart page https://docs.radapp.io/quick-start/
  2. Mouse over a code block
  3. Mouse over the top right of the code block

Expected behavior

  1. A copy code icon on the far right of the code block

Screenshots

No mouseover:

Image

On mouseover:

Image

Notice the box is extended down.

On mouse over the top right:

Image
Desktop (please complete the following information):

Tested on MacOS Chrome and Safari

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue on the quick-start page at https://docs.radapp.io/quick-start/ by hovering over its code blocks in Chrome or Safari. Trace the JavaScript responsible for the copy button and compare the button's position and container dimensions before and during hover. Done means the code block does not expand, the button stays aligned at the far right, and its label does not flash unexpectedly.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
documentation
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
58/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.