NWS Design System: sidebar navigation

The nds_sidebar_nav_item_with_subnav can be used to create nested navigation item inside sidebar navigation. Its content consists of sidebar_nav_item and other nds_sidebar_nav_item_with_subnav items.

If nds_sidebar_nav_item_with_subnav contains active item, it must be also marked as active.

{%- call ui.util.call(show_example) -%} {%- raw %} {%- call ui.util.call(ui.sidebar_nav, title="Nested navigation") -%} {{ ui.sidebar_nav_item("Simple link", href="") }} {%- call ui.util.call(ui.nds_sidebar_nav_item_with_subnav, title="Tree", active=true) -%} {{ ui.sidebar_nav_item("Level 1: simple", href="") }} {%- call ui.util.call(ui.nds_sidebar_nav_item_with_subnav, title="Level 1: tree", active=true) -%} {{ ui.sidebar_nav_item("Level 2: simple", href="") }} {{ ui.sidebar_nav_item("Level 2: active", href="", active=true) }} {%- endcall %} {{ ui.sidebar_nav_item("Level 1: tail", href="") }} {%- endcall %} {{ ui.sidebar_nav_item("Tail", href="") }} {%- endcall %} {%- endraw %} {%- endcall %}