@php $showSearch = isset($searchUrl) && $searchUrl !== null && $searchUrl !== '#'; $gridCols = match (true) { ! empty($centerCompose) => $showSearch ? 'grid-cols-5' : 'grid-cols-4', default => $showSearch ? 'grid-cols-4' : 'grid-cols-3', }; $avatarUrl = $avatarUrl ?? null; $initials = $initials ?? 'U'; $notificationsUrl = $notificationsUrl ?? '#'; $unreadUrl = $unreadUrl ?? null; $profileUrl = $profileUrl ?? '#'; $profileName = trim((string) ($profileName ?? '')); $profileSubtitle = trim((string) ($profileSubtitle ?? '')); $profileMenuItems = $profileMenuItems ?? []; if ($profileMenuItems === [] && $profileUrl !== '#') { $profileMenuItems = [['type' => 'link', 'label' => 'Profile', 'href' => $profileUrl]]; } $walletBalanceRoute = (string) config('billing.wallet_balance_route', 'wallet.balance'); $showWalletInSheet = \Illuminate\Support\Facades\Route::has($walletBalanceRoute) || collect($profileMenuItems)->contains(fn (array $item): bool => ($item['type'] ?? '') === 'wallet'); $sheetMenuItems = array_values(array_filter( $profileMenuItems, fn (array $item): bool => ($item['type'] ?? 'link') !== 'wallet' )); $navActive = fn (bool $active) => $active ? 'text-indigo-600' : 'text-slate-600'; @endphp
{{ $profileName }}
@endif @if ($profileSubtitle !== ''){{ $profileSubtitle }}
@endifBilling
@include('partials.wallet-widget', [ 'onNavigate' => 'profileOpen = false', 'class' => 'mx-0', ])