<!-- common/zmi_tabs_sub -->

<nav id="tabs_sub" class="navbar navbar-light navbar-expand-md mt-0 mb-0 pb-0" role="navigation">
	<div class="collapse navbar-collapse row" id="sub_tabs_items">
		<ul class="nav nav-pills" tal:define="
					current python:request['URL'].split('/')[-1];
					options options/options;
					actions python:[x.get('alias',x['action']) for x in options];
					active python:[
								(x==current and not here.id+'/'+current in actions) or 
								(x==here.id+'/'+current) or 
								(current not in actions and current.startswith(x)) for x in actions];
					noactive python:len([x for x in active if x])<1;
					">
			<tal:block tal:repeat="i python:range(len(options))">
				<tal:block tal:define="option python:options[i]">
					<li class="nav-item">
						<a 
							tal:attributes="
								href python:'%s/%s?lang=%s'%(here.getSelf().absolute_url(),option['action'],request['lang']);
								class python:' '.join(['nav-link']+[['','active'][int(active[i] or (i==0 and noactive))]])" 
							tal:content="structure python:here.getZMILangStr(option['label'])">the label</a>
					</li>
				</tal:block>
			</tal:block>
		</ul><!-- .nav.nav-pills -->
	</div>
</nav>

<!-- /common/zmi_tabs_sub -->