[% comment %]
This uses NavigationMenuItemDrop as the model
[% endcomment %]

[% if Model.Children == empty %]
    <li>
        <a href="[[Model.Url]]" onclick="insite.nav.hideMenu();" [% if Model.OpenInNewTab %] target="_blank" rel="noopener noreferrer" [% endif %]>[[Model.Title]]</a>
    </li>
[% else %]
    <li>
        <span class="nav-item-container">
            <a href="[[Model.Url]]">[[Model.Title]]</a>
            <label id="tst_mainMenu_nav_[[Model.Identifier]]" for="nav-[[Model.Identifier]]" class="toggle-sub" onclick="insite.nav.goToSubnav(this)">&#9658;</label>
        </span>
        <input type="checkbox" name="nav" id="nav-[[Model.Identifier]]" class="subnav-check" />
        <ul id="sub-[[Model.Identifier]]" class="subnav sub-tier-panel">
            <li class="sub-heading">[[Model.Title]]</li>
            [% for childItem in Model.Children %]
                [% navigationMenuItem childItem %]
            [% endfor %]
        </ul>
    </li>
[% endif %]
