⚗️ Ajoute un menu dynamique pour avoir la classe active automatique
This commit is contained in:
20
resources/views/vendor/laravel-menu/bootstrap-navbar-items.blade.php
vendored
Normal file
20
resources/views/vendor/laravel-menu/bootstrap-navbar-items.blade.php
vendored
Normal file
@@ -0,0 +1,20 @@
|
||||
@foreach($items as $item)
|
||||
<li @lm_attrs($item) @if($item->hasChildren()) class="nav-item dropdown" @endif @lm_endattrs>
|
||||
@if($item->link) <a @lm_attrs($item->link) @if($item->hasChildren()) class="nav-link dropdown-toggle" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" @else class="nav-link" @endif @lm_endattrs href="{!! $item->url() !!}">
|
||||
{!! $item->title !!}
|
||||
@if($item->hasChildren()) <b class="caret"></b> @endif
|
||||
</a>
|
||||
@else
|
||||
<span class="navbar-text">{!! $item->title !!}</span>
|
||||
@endif
|
||||
@if($item->hasChildren())
|
||||
<ul class="dropdown-menu">
|
||||
@include(config('laravel-menu.views.bootstrap-items'),
|
||||
array('items' => $item->children()))
|
||||
</ul>
|
||||
@endif
|
||||
</li>
|
||||
@if($item->divider)
|
||||
<li{!! Lavary\Menu\Builder::attributes($item->divider) !!}></li>
|
||||
@endif
|
||||
@endforeach
|
Reference in New Issue
Block a user