Matches Ladill Stock, whose header is now just AI, notifications, launcher and the account menu. This partial is byte-identical to Stock's again. Only the desktop block goes. The mobile full-screen search (partials/search-screen) is untouched and still reached from the bottom nav, the `/` shortcut still focuses page-level search inputs, and the search route and controller are left in place — the Alpine topbarSearch component is still used by the mobile screen, so none of it is dead code. Ladill Webmail deliberately keeps its header search: it is the only desktop route into mail search, and dropping it there would remove a core function rather than tidy a header.
30 lines
1.3 KiB
PHP
30 lines
1.3 KiB
PHP
@php
|
|
$user = auth()->user();
|
|
$initials = collect(explode(' ', trim((string) $user?->name)))
|
|
->filter()
|
|
->take(2)
|
|
->map(fn ($part) => strtoupper(substr($part, 0, 1)))
|
|
->implode('');
|
|
@endphp
|
|
|
|
<header class="flex h-16 items-center justify-between border-b border-slate-200 bg-white px-6">
|
|
<div class="flex min-w-0 flex-1 items-center gap-3">
|
|
<button @click="sidebarOpen = !sidebarOpen" class="shrink-0 text-slate-500 hover:text-slate-700 lg:hidden">
|
|
<svg class="h-6 w-6" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 6h16M4 12h16M4 18h16"/></svg>
|
|
</button>
|
|
@include('partials.mobile-topbar-title')
|
|
</div>
|
|
|
|
<div class="flex items-center gap-3">
|
|
@auth
|
|
@includeIf('partials.topbar-account-switcher')
|
|
@includeIf('partials.topbar-widgets-prepend')
|
|
@include('partials.topbar-desktop-widgets', ['user' => $user ?? $u ?? auth()->user(), 'showUser' => true])
|
|
@includeIf('partials.topbar-widgets-append')
|
|
@else
|
|
<a href="{{ route('login') }}" class="btn-primary">Sign in</a>
|
|
@include('partials.launcher')
|
|
@endauth
|
|
</div>
|
|
</header>
|