Deploy Ladill Hosting / deploy (push) Successful in 46s
Wire UserProfileMenu and shared Blade partial into topbar, mobile nav, and layouts so menu items match the account portal (Ladill Mail excluded). Co-authored-by: Cursor <cursoragent@cursor.com>
65 lines
3.2 KiB
PHP
65 lines
3.2 KiB
PHP
<!DOCTYPE html>
|
|
<html lang="en" class="h-full bg-slate-100">
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover">
|
|
<meta name="csrf-token" content="{{ csrf_token() }}">
|
|
<title>@yield('title', 'Ladill Email')</title>
|
|
@include('partials.favicon')
|
|
<link rel="preconnect" href="https://fonts.bunny.net">
|
|
<link href="https://fonts.bunny.net/css?family=figtree:400,500,600&display=swap" rel="stylesheet" />
|
|
@vite(['resources/css/app.css', 'resources/js/app.js'])
|
|
</head>
|
|
<body class="h-full font-sans antialiased bg-slate-100" x-data="{ sidebarOpen: false }">
|
|
<div class="min-h-screen max-lg:min-h-dvh">
|
|
<div x-show="sidebarOpen" x-cloak class="fixed inset-0 z-30 bg-black/50 lg:hidden" @click="sidebarOpen = false"></div>
|
|
<aside x-cloak class="fixed inset-y-0 left-0 z-40 w-64 transform transition-transform lg:translate-x-0"
|
|
:class="sidebarOpen ? 'translate-x-0' : '-translate-x-full'">
|
|
@include('partials.sidebar')
|
|
</aside>
|
|
<div class="flex min-h-screen flex-col min-w-0 lg:pl-64">
|
|
@include('partials.topbar')
|
|
<main class="flex-1 p-6 pb-24 lg:p-6 lg:pb-6">
|
|
@include('partials.flash')
|
|
@include('partials.mailbox-link-banner')
|
|
@yield('content')
|
|
</main>
|
|
</div>
|
|
</div>
|
|
@auth
|
|
@php
|
|
$navUser = auth()->user();
|
|
$navInitials = collect(explode(' ', trim((string) $navUser?->name)))
|
|
->filter()->take(2)
|
|
->map(fn ($part) => strtoupper(substr($part, 0, 1)))
|
|
->implode('');
|
|
$navAcct = 'https://'.config('app.account_domain');
|
|
@endphp
|
|
@include('partials.mobile-bottom-nav', [
|
|
'homeUrl' => route('email.dashboard'),
|
|
'homeActive' => request()->routeIs('email.dashboard'),
|
|
'searchUrl' => route('email.mailboxes.index'),
|
|
'searchActive' => request()->routeIs('email.mailboxes.*'),
|
|
'notificationsUrl' => route('notifications.index'),
|
|
'notificationsActive' => request()->routeIs('notifications.*'),
|
|
'unreadUrl' => route('notifications.unread'),
|
|
'profileActive' => false,
|
|
'profileName' => $navUser?->name ?? '',
|
|
'profileSubtitle' => $navUser?->email ?? '',
|
|
'profileMenuItems' => \App\Support\UserProfileMenu::items($navUser),
|
|
['type' => 'link', 'label' => 'Profile', 'href' => ladill_account_url('profile')],
|
|
['type' => 'link', 'label' => 'Account Settings', 'href' => ladill_account_url('account-settings')],
|
|
['type' => 'link', 'label' => 'Dashboard', 'href' => route('email.dashboard')],
|
|
['type' => 'link', 'label' => 'Billing', 'href' => ladill_account_url('billing')],
|
|
['type' => 'logout', 'label' => 'Logout', 'action' => route('logout')],
|
|
],
|
|
'avatarUrl' => $navUser?->avatar_url,
|
|
'initials' => $navInitials !== '' ? $navInitials : 'U',
|
|
])
|
|
@include('partials.afia')
|
|
@endauth
|
|
@include('partials.sso-keepalive')
|
|
@include('partials.confirm-prompt')
|
|
</body>
|
|
</html>
|