Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions docs/scripts/post-render.py
Original file line number Diff line number Diff line change
Expand Up @@ -362,4 +362,25 @@ def add_parens_to_functions(match):
print(f"Index file not found: {index_file}")


# Update quarto-secondary-nav-title to display "User Guide" text
# This improves the mobile navigation by making it clear what the sidebar toggle reveals
all_html_files = glob.glob("_site/**/*.html", recursive=True)
print(f"Found {len(all_html_files)} HTML files to check for secondary nav title")

for html_file in all_html_files:
with open(html_file, "r") as file:
content = file.read()

# Replace empty h1.quarto-secondary-nav-title with h5 containing "User Guide"
original_pattern = r'<h1 class="quarto-secondary-nav-title"></h1>'
replacement = '<h5 class="quarto-secondary-nav-title">User Guide</h5>'

if original_pattern in content:
print(f"Updating secondary nav title in: {html_file}")
content = content.replace(original_pattern, replacement)

with open(html_file, "w") as file:
file.write(content)


print("Finished processing all files")
8 changes: 8 additions & 0 deletions docs/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -263,3 +263,11 @@ a.sidebar-item-text.sidebar-link.text-start > span {
background-position: 0% 50%;
}
}

/* Adjust mobile secondary nav positioning */
@media (max-width: 991.98px) {
#quarto-header .container-fluid.d-flex {
margin-left: 0;
padding-left: 5px;
}
}
Loading