Offset
This behavior keeps offset elements synchronized with the live size of the header and sidenav.
Offset elements are used as spacing references for layouts, navigation systems, and menu structures that need to account for fixed or persistent UI areas. Instead of manually setting spacing values, the offset elements use the current width and height of their matching source element as minimum dimensions.
The header-offset elements copy the live width and height of the header and apply them as min-width and min-height.
The sidenav-offset elements copy the live width and height of the sidenav and apply them as min-width and min-height.
This helps related elements stay aligned when the header or sidenav changes size across breakpoints, responsive states, interactions, or dynamic content updates.
The behavior updates on page load, resize, orientation change, content changes, class changes, style changes, hidden-state changes, and live element size changes. This keeps the offsets accurate even when the layout changes after the page has already loaded.
Use this behavior when a layout, menu, or spacing element needs to reserve at least the same space as the header or sidenav without relying on fixed values.
Mega Menu Close Sync
This behavior keeps the navbar and sidenav mega menu close elements synchronized with the open state of their matching mega menus.
The mega-menu-close-navbar and mega-menu-close-sidenav elements are hidden by default. When a matching mega menu is open, the correct close element is shown as flex. When no matching mega menu is open, the close element is hidden again.
The behavior checks each mega-menu for open states, aria-expanded states, and visible navigation panels. This allows the close element to stay accurate even when the menu state is controlled by Interactions (X), dropdown behavior, keyboard actions, or responsive layout changes.
The navbar close element responds to mega menus that contain mega-menu-navigation-navbar.
The sidenav close element responds to mega menus that contain mega-menu-navigation-sidenav.
The behavior updates after clicks, mouse actions, touch actions, keyboard actions, resize events, and class, style, or aria-expanded changes.
Use this behavior when a shared close element needs to appear only while a navbar or sidenav mega menu is open.
Navbar variants define how the navigation behaves across different breakpoints.
The Base variant does not activate a separate menu layout. In this setup, the navigation remains visible in the same way on desktop and mobile. This is useful when the menu should not collapse into a toggle-based layout.
The other variant classes define the breakpoint where the menu layout becomes active:
is-desktop-menu- The menu layout is active from desktop and below.
is-tablet-menu- The menu layout becomes active from tablet and below.
is-mobile-menu- The menu layout becomes active from mobile landscape and below.
is-mobile-portrait-menu- The menu layout becomes active only from mobile portrait and below.
These variant classes change the default styling of the main navbar structure so the component can switch between a visible navigation layout and a menu-based layout. The main classes affected by these variants are navbar-navigation, navbar-content, navbar-group, navbar-menu-visible, and navbar-menu-hidden.
The menu open and close behavior is controlled in the Interactions (X) panel under Navigation - Navbar Menu Open and Navigation - Navbar Menu Close.
The menu animation is handled through class addons. Instead of animating the navbar directly with standard interaction transforms, the interactions add and remove the following classes: is-open, on-enter, and on-exit are added to navbar-navigation, navbar-content, and navbar-backdrop.
The is-open class controls the open state. If no additional animation classes are used, is-open simply shows or hides the element.
When animation classes are used, is-open sets the starting structure for the animation, including the initial position. The on-enter class controls the opening animation, while on-exit controls the closing animation.
The on-exit class is added while is-open and on-enter are still active. This allows the closing animation to start from the same position where the opening animation finished.
Do not replace on-enter with on-exit immediately. If on-enter is removed before on-exit starts, the element may snap back to its original state instead of closing smoothly.
Once the on-exit animation is finished, the transition timing in the addon class should match the delay set in the interaction. After that delay, is-open, on-enter, and on-exit should all be removed together. This keeps the full animation sequence smooth from open to close.
This class-based animation setup is used because traditional interaction-based transforms can affect parent and nested elements in ways that limit functionality. For example, nested components such as mega menus may no longer display full screen if their parent elements are transformed by interactions. Adding and removing classes is safer because it allows the menu to animate while keeping nested components free to behave correctly.