{{ __('Home') }} @auth Dashboard @endauth {{ __('Menu') }} {{ __('Contact') }} {{ __('Cart') }} @php $items = session('cart.items', []); $count = 0; if (is_array($items)) { foreach ($items as $it) { // support structures like ['qty'=>x] or raw numeric values if (is_array($it) && isset($it['qty'])) { $count += (int) $it['qty']; } elseif (is_numeric($it)) { $count += (int) $it; } } } @endphp @if($count) {{ $count }} @else 0 @endif @auth {{ __('My Orders') }} {{ __('Addresses') }} @endauth
@auth {{ __('Profile') }} {{ __('Log Out') }} @endauth @guest
{{ __('Log in') }} {{ __('Register') }}
@endguest
{{ __('Home') }} @auth Dashboard @endauth {{ __('Menu') }} {{ __('Contact') }} {{ __('Cart') }} @auth {{ __('My Orders') }} {{ __('Addresses') }} @endauth
@auth
{{ optional(Auth::user())->display_name ?? 'Account' }}
{{ optional(Auth::user())->email ?? '' }}
{{ __('Profile') }} {{ __('Log Out') }}
@endauth @guest
{{ __('Log in') }} {{ __('Register') }}
@endguest