Skip to content

Commit

Permalink
Use @auth
Browse files Browse the repository at this point in the history
  • Loading branch information
kreaweb.be committed Apr 28, 2024
1 parent 537299d commit f523877
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions resources/views/layouts/partials/offcanvas.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
</div>

<div class="basis-1/2">
@if (auth()->check())
@auth
{{ auth()->user()->teamRole(auth()->user()->currentTeam)->name }}

<x-hr.narrow class="w-full h-1 max-md:mx-auto my-1 bg-gray-100 border-0 rounded dark:bg-gray-700" />
Expand All @@ -24,15 +24,15 @@
@else
{{ __('auth.guest') }}
<x-hr.narrow class="w-full h-1 max-md:mx-auto my-1 bg-gray-100 border-0 rounded dark:bg-gray-700" />
@endif
@endauth
</div>
</div>
</div>
</div>

{{-- offcanvas menu --}}
<div class="flex-grow overflow-y-auto">
@if (auth()->check())
@auth
@if (auth()->user()->is_developer)
{{-- developer --}}
<div>{{ __('auth.developer') }} ...</div>
Expand Down Expand Up @@ -133,10 +133,7 @@
</p>
</div>
@endif
@endif

@guest
{{-- guest --}}
@else
<div>{{ __('auth.guest') }} ...</div>

<div><x-hr.narrow class="w-full h-1 max-md:mx-auto my-1 bg-gray-100 border-0 rounded dark:bg-gray-700" />
Expand All @@ -147,7 +144,7 @@
{{ __('app.help') }}
</x-nav-link-responsive>
</p>
@endguest
@endauth
</div>

<x-slot:footer end>
Expand Down

0 comments on commit f523877

Please sign in to comment.