Skip to content

Commit

Permalink
Fix navigation.tabs for non-leaf pages (#406)
Browse files Browse the repository at this point in the history
Previously, when using navigation.tabs on non-leaf pages, the integrated
TOC used for "layered" (mobile) navigation would incorrectly display as
well. The fix in 87d87f9 was was not
sufficient due to a CSS precedence issue, which is now corrected by
using `!important`.
  • Loading branch information
jbms authored Jan 30, 2025
1 parent d32b12a commit 4f7e08e
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .stylelintrc
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
"custom-property-empty-line-before": null,
"custom-property-pattern": null,
"declaration-colon-space-after": null,
"declaration-no-important": true,
"declaration-no-important": null,
"declaration-block-single-line-max-declarations": 0,
"function-calc-no-unspaced-operator": null,
"function-no-unknown": null,
Expand Down
4 changes: 2 additions & 2 deletions src/assets/stylesheets/main/layout/_nav.scss
Original file line number Diff line number Diff line change
Expand Up @@ -453,7 +453,7 @@
// sphinx-immaterial: hide nested nav items of current page, since
// they are redundant with integrated toc.
&__current-nested {
display: none;
display: none !important;
}

// Show link to table of contents
Expand Down Expand Up @@ -514,7 +514,7 @@

// sphinx-immaterial: hide integreated toc, since it is redundant with any nested items.
&__current-toc {
display: none;
display: none !important;
}

// Navigation title
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ some_module.method_name(
some_parameter_with_a_long_name: collections.abc.MutableMapping[
tuple[str, float, numbers.Real],
dict[int, tuple[list[frozenset[int]]]],
]
],
) -> collections.abc.MutableMapping[
tuple[str, float, numbers.Real],
dict[int, tuple[list[frozenset[int]]]],
Expand Down

0 comments on commit 4f7e08e

Please sign in to comment.