rmarkdown icon indicating copy to clipboard operation
rmarkdown copied to clipboard

Notebook Suggestion - Improve Show/Hide code chunk button animation

Open dfalty opened this issue 9 years ago • 2 comments

Notebook Suggestion - Improve Show/Hide code chunk button animation. The transition is a little awkward since the button is hidden for a moment when the chunk is opening. Also, selecting "Hide" the chunk animation minimizes below the button. chunkoutput

dfalty avatar Oct 18 '16 21:10 dfalty

Is this reproducible? I see no overlaps among buttons and code blocks, and hence no hiding of buttons.

If I add some CSS rules, then I can see code blocks hide the button during the transition.

If we need to ensure suppressing the issue, we may add .code-folding-btn {z-index: 1} to the template file.

---
title: test
output:
  html_document:
    code_folding: show
---

```{css}
.code-folding-btn {top:2em; position: relative}
```

```{r, eval=FALSE}
'foo'
'bar'
```

atusy avatar Jul 21 '20 13:07 atusy

I confirm this happens only when touching the CSS rule for the button.

It also happens for boostrap 4 using bslib. Maybe we could add a rule there in the bslib part 🤔

cderv avatar Jan 12 '22 15:01 cderv