opensearch-docs-cn/assets/js/header-nav.js

6 lines
267 B
JavaScript
Raw Normal View History

document.querySelector('.menu-button')?.addEventListener('click', el => {
Redesigned top nav and footer (#5113) * Ports over redesigned top banner header navigation, and footer Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Adds style overrides for search functionality Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Adds Font Awesome for menu icons Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Adds style overrides and updated menu item configurations Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Adds whitespace to fix SASS style rule causing Github action failure Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Adds dynamic navigation submenu height determination for smooth expand/collapse transitions instead of hardcoded values potentiating effortless change management Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Removes outdated message about old version release Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Corrects padding, positioning, typography for the site footer Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Adds new footer logo Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Sets footer legal copy right padding on mobile to that of the scroll-to-top button Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Adds footer link styles Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Adjusts page layout to fit the new container width requirements Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Fixes mobile layout with new header and footer Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Fixes mobile navigation menu errors Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Adjusts padding Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Removes commented out code Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> * Updates top navigation menu items with latest from project site Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> --------- Signed-off-by: Aaron Stephanus <taoist.futility@pm.me> Signed-off-by: astephanus <124592019+astephanus@users.noreply.github.com>
2023-11-07 17:17:05 -06:00
const siteNavigation = document.querySelector('div[role="navigation"].nav-menu-on');
siteNavigation?.classList?.toggle?.('active');
el.currentTarget.classList?.toggle?.('active');
});