Skip to content

Commit

Permalink
Expand details before scrolling
Browse files Browse the repository at this point in the history
  • Loading branch information
brianrourkeboll committed May 25, 2024
1 parent 189f086 commit f52a6ab
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/content/fsdocs-theme.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ if (activeItem && mainMenu) {

function scrollToAndExpandSelectedMember() {
if (location.hash) {
const header = document.querySelector(`a[href='${location.hash}']`);
header.scrollIntoView({ behavior: 'instant'});
const details = document.querySelector(`tr > td.fsdocs-member-usage:has(a[href='${location.hash}']) ~ td.fsdocs-member-xmldoc > details`);
details?.setAttribute('open', 'true');
const header = document.querySelector(`a[href='${location.hash}']`);
header.scrollIntoView({ behavior: 'instant'});
}
}

Expand Down

0 comments on commit f52a6ab

Please sign in to comment.