quarto-dev / quarto-dev/quarto-cli

Code annotation marker is masking content

Open
#13,449 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug code-annotation code-blocks
Dominant language
JavaScript
Stars
6k
Forks
458
Avg merge
1d 9h
Merged PRs (30d)
41

Description

Bug description

The code annotation marker is masking content unless code-overflow: wrap is used.

This issue is there since at least 1.7, but is likely there since the beginning (not tested earlier version).

Steps to reproduce
---
title: "Code annotation marker is masking content"
format: html
code-annotations: select
---

```{.bash}
# Some comment
# to avoid overlapping copy button and annotation marker
echo "Hello, World!" # <1>
echo "This is a very long line that will not fit on a single line in the document. It should wrap around to the next line automatically, demonstrating how text wrapping works in a Word document generated from Quarto." > long_text.txt # <1>
```

1. This is an annotation.
Actual behavior
Image
Quarto 99.9.9
[✓] Checking environment information...
      Quarto cache location: /Users/mcanouil/Library/Caches/quarto
[✓] Checking versions of quarto binary dependencies...
      Pandoc version 3.6.3: OK
      Dart Sass version 1.87.0: OK
      NOTE: Deno version 2.4.5 does not strictly match 2.3.1 and strict checking is enabled. Please use 2.3.1.
      Typst version 0.13.0: OK
[✓] Checking versions of quarto dependencies......OK
[✓] Checking Quarto installation......OK
      Version: 99.9.9
      commit: e858bba000cc35277bdb8911d6ad86ccc74e6552
      Path: /Users/mcanouil/Projects/quarto-dev/quarto-cli/package/dist/bin

[✓] Checking tools....................OK
      TinyTeX: v2025.08.02
      Chromium: (not installed)

[✓] Checking LaTeX....................OK
      Using: TinyTex
      Path: /Users/mcanouil/Library/TinyTeX/bin/universal-darwin
      Version: 2025

[✓] Checking Chrome Headless....................OK
      Using: Chrome found on system
      Path: /Applications/Brave Browser.app/Contents/MacOS/Brave Browser
      Source: QUARTO_CHROMIUM

[✓] Checking basic markdown render....OK

[✓] Checking Python 3 installation....OK
      Version: 3.13.2
      Path: /Users/mcanouil/Projects/quarto-dev/quarto-playground/.venv/bin/python3
      Jupyter: 5.8.1
      Kernels: julia-1.11, uv, python3

[✓] Checking Jupyter engine render....OK

(\) Checking R installation...........ℹ R version 4.5.1 (2025-06-13)
! Config '~/.Rprofile' was loaded!
[✓] Checking R installation...........OK
      Version: 4.5.1
      Path: /Library/Frameworks/R.framework/Resources
      LibPaths:
        - /Users/mcanouil/Projects/quarto-dev/quarto-playground/renv/library/macos/R-4.5/aarch64-apple-darwin20
        - /Users/mcanouil/Library/Caches/org.R-project.R/R/renv/sandbox/macos/R-4.5/aarch64-apple-darwin20/4cd76b74
      knitr: 1.50
      rmarkdown: 2.29

[✓] Checking Knitr engine render......OK

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

Start by rendering the provided Quarto document with code-annotations: select and compare it with the same example using code-overflow: wrap. Trace the code-annotation rendering path responsible for the marker and add a regression test covering a long annotated line; done means the marker no longer masks content without requiring wrapping.

Written by the indexing model from the issue text.

Assessment

Tech stack
html, javascript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.