diff --git a/src/css/custom.css b/src/css/custom.css index 88368f6..4fe2ca5 100644 --- a/src/css/custom.css +++ b/src/css/custom.css @@ -144,8 +144,11 @@ } } -/* when the window is narrow, the right-header icons are in the pull-down sidebar */ -.navbar-sidebar__items { +/* .navbar-sidebar__items: when the window is narrow, the right-header icons are in the pull-down sidebar + .navbar__inner .dropdown__menu: for dropdown menus in the navbar. (note, though, that the current design does not allow dropdowns in the left section.) + */ +.navbar-sidebar__items, +.navbar__inner .dropdown__menu { /* fontawesome-* classes were added in the item definitions in docusaurus.config.ts */ .fontawesome-container { display: flex; @@ -214,16 +217,23 @@ border-radius: 0.5rem; } -/* move the expand/contract caret to the far left for improved visibility/group offsetting */ -.menu__caret { +/* move the expand/contract caret to the far left for improved visibility/group offsetting. + The second class is active if the subdirectory has no linked-page (so clicking on it just opens the sublist w/o changing the main panel. + */ +.menu__caret, +.menu__link--sublist-caret::after { order: -1; padding-left: 0.45em; padding-right: 0; border-radius: 0.5rem 0 0 0.5rem; /* match the outer box's corner */ +} - &::before { - scale: 0.6; - } +/* The caret is placed differently depending on whether the subdirectory has an index page. + The first is when an "index" is present; the second when there's no linked page */ +.menu__caret::before, +.menu__link--sublist-caret::after { + scale: 0.6; + margin-left: 0; /* this is currently needed for .menu__link--sublist-caret::after, but is correct for both */ } /* split the padding between the caret (previous rule) and the text in the category header */