Skip to content

Commit

Permalink
Merge pull request #9784 from quarto-dev/fix/margin-sidebar-toggle
Browse files Browse the repository at this point in the history
  • Loading branch information
cderv authored May 28, 2024
2 parents f2da66d + d5aa2de commit e7741a4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions news/changelog-1.5.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ All changes included in 1.5:
- ([#8851](https://github.com/quarto-dev/quarto-cli/issues/8851)): Don't strip `index.html` from external paths.
- ([#8977](https://github.com/quarto-dev/quarto-cli/issues/8977)): Don't decorate about links within external link icons.
- ([#9356](https://github.com/quarto-dev/quarto-cli/issues/9356)): Don't process column classes for figures inside the About divs.
- ([#9781](https://github.com/quarto-dev/quarto-cli/issues/9781)): Correctly hide elements from click event in collapsed margin sidebar.

## Book

Expand Down
3 changes: 3 additions & 0 deletions src/resources/formats/html/quarto.js
Original file line number Diff line number Diff line change
Expand Up @@ -319,6 +319,7 @@ window.document.addEventListener("DOMContentLoaded", function (_event) {
for (const child of el.children) {
child.style.opacity = 0;
child.style.overflow = "hidden";
child.style.pointerEvents = "none";
}

nexttick(() => {
Expand Down Expand Up @@ -360,6 +361,7 @@ window.document.addEventListener("DOMContentLoaded", function (_event) {

const clone = child.cloneNode(true);
clone.style.opacity = 1;
clone.style.pointerEvents = null;
clone.style.display = null;
toggleContents.append(clone);
}
Expand Down Expand Up @@ -434,6 +436,7 @@ window.document.addEventListener("DOMContentLoaded", function (_event) {
for (const child of el.children) {
child.style.opacity = 1;
child.style.overflow = null;
child.style.pointerEvents = null;
}

const placeholderEl = window.document.getElementById(
Expand Down

0 comments on commit e7741a4

Please sign in to comment.