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
6 changes: 2 additions & 4 deletions ietf/static/js/document_html.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,8 @@ document.addEventListener("DOMContentLoaded", function (event) {

// Set up a nav pane
const toc_pane = document.getElementById("toc-nav");
populate_nav(toc_pane,
`#content h2, #content h3, #content h4, #content h5, #content h6
#content .h1, #content .h2, #content .h3, #content .h4, #content .h5, #content .h6`,
["py-0"]);
const headings = document.querySelectorAll(`#content :is(h2, h3, h4, h5, h6, .h2, .h3, .h4, .h5, .h6)`);
populate_nav(toc_pane, headings, ["py-0"]);

// activate pref buttons selected by pref cookies or localStorage
const in_localStorage = ["deftab", "reflinks"];
Expand Down
2 changes: 1 addition & 1 deletion ietf/static/js/ietf.js
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ $(document)
$(function () {
const contentElement = $('#content.ietf-auto-nav');
if (contentElement.length > 0) {
const heading_selector = ":is(h2, h3, h4, h5, h6, .nav-heading):not([style='display:none']):not(.navskip)";
const heading_selector = ":is(h2, h3, h4, h5, h6, .h2, .h3, .h4, .h5, .h6, .nav-heading):not([style='display:none']):not(.navskip)";
const headings = contentElement
.find(heading_selector)
.filter((i, el) => !el.closest(".navskip"));
Expand Down