myvideogamelist.com/resources/views/partials/topbar/_user-menu.blade.php
Jimmy Brancaccio b39ecf1638 Initial Commit
The initial public commit of MVGL website code.
2024-01-14 13:51:43 -06:00

152 lines
4.6 KiB
PHP

@php
use Illuminate\Support\Facades\Storage;
@endphp
@if (Auth::check())
<!--begin::Menu-->
<div class="menu menu-sub menu-sub-dropdown menu-column menu-rounded menu-gray-800 menu-state-bg menu-state-primary fw-bold py-4 fs-6 w-275px" data-kt-menu="true">
<!--begin::Menu item-->
<div class="menu-item px-3">
<div class="menu-content d-flex align-items-center px-3">
<!--begin::Avatar-->
<div class="symbol symbol-50px me-5">
<img src="{{ Storage::url('assets/avatars/') . auth()->user()->avatar }}" alt="user"/>
</div>
<!--end::Avatar-->
<!--begin::Username-->
<div class="d-flex flex-column">
<div class="fw-bolder d-flex align-items-center fs-5">
{{ auth()->user()->username }}
{{-- <span class="badge badge-light-success fw-bolder fs-8 px-2 py-1 ms-2">Pro</span> --}}
</div>
<span class="fw-bold text-muted fs-7">{{ auth()->user()->role->name }}</span>
</div>
<!--end::Username-->
</div>
</div>
<!--end::Menu item-->
<!--begin::Menu separator-->
<div class="separator my-2"></div>
<!--end::Menu separator-->
<!--begin::Menu item-->
<div class="menu-item px-5">
<a href="{{ theme()->getPageUrl('profile.show') }}" class="menu-link px-5">
{{ __('My Profile') }}
</a>
</div>
<!--end::Menu item-->
<!--begin::Menu item-->
<div class="menu-item px-5">
<a href="{{ theme()->getPageUrl('games.list.index') }}" class="menu-link px-5">
{{ __('My List') }}
</a>
</div>
<!--end::Menu item-->
<!--begin::Menu item-->
<div class="menu-item px-5">
<a href="#" class="menu-link px-5">
{{ __('My Favorites') }}
</a>
</div>
<!--end::Menu item-->
<!--begin::Menu item-->
<div class="menu-item px-5">
<a href="#" class="menu-link px-5">
{{ __('My Wishlist') }}
</a>
</div>
<!--end::Menu item-->
<!--begin::Menu item-->
<div class="menu-item px-5">
<a href="#" class="menu-link px-5">
{{ __('My Blog') }}
</a>
</div>
<!--end::Menu item-->
<!--begin::Menu separator-->
<div class="separator my-2"></div>
<!--end::Menu separator-->
<!--begin::Menu item-->
<div class="menu-item px-5">
<a href="#" class="menu-link px-5">
{{ __('Account Settings') }}
</a>
</div>
<!--end::Menu item-->
@if (
auth()->user()->role->slug == 'founder' ||
auth()->user()->role->slug == 'developer' ||
auth()->user()->role->slug == 'game-database-admin' ||
auth()->user()->role->slug == 'site-content-admin'
)
<!--begin::Menu item-->
<div class="menu-item px-5">
<a href="#" class="menu-link px-5">
{{ __('Site Management') }}
</a>
</div>
<!--end::Menu item-->
@endif
<!--begin::Menu item-->
<div class="menu-item px-5">
<a href="#" data-action="{{ theme()->getPageUrl('logout') }}" data-method="post" data-csrf="{{ csrf_token() }}" data-reload="true" class="button-ajax menu-link px-5">
{{ __('Sign Out') }}
</a>
</div>
<!--end::Menu item-->
</div>
<!--end::Menu-->
@else
<!--begin::Menu-->
<div class="menu menu-sub menu-sub-dropdown menu-column menu-rounded menu-gray-800 menu-state-bg menu-state-primary fw-bold py-4 fs-6 w-275px" data-kt-menu="true">
<!--begin::Menu item-->
<div class="menu-item px-3">
<div class="menu-content d-flex align-items-center px-3">
<!--begin::Avatar-->
<div class="symbol symbol-50px me-5">
<img alt="Logo" src="{{ Storage::url('assets/avatars/default.png') }}"/>
</div>
<!--end::Avatar-->
<!--begin::Username-->
<div class="d-flex flex-column">
<div class="fw-bolder d-flex align-items-center fs-5">MVGL-User</div>
</div>
<!--end::Username-->
</div>
</div>
<!--end::Menu item-->
<!--begin::Menu separator-->
<div class="separator my-2"></div>
<!--end::Menu separator-->
<!--begin::Menu item-->
<div class="menu-item px-5">
<a href="{{ route('login') }}" class="menu-link px-5">
{{ __('Login') }}
</a>
</div>
<!--end::Menu item-->
<!--begin::Menu item-->
<div class="menu-item px-5">
<a href="{{ route('register') }}" class="menu-link px-5">
{{ __('Register') }}
</a>
</div>
<!--end::Menu item-->
</div>
<!--end::Menu-->
@endif