-
-
Notifications
You must be signed in to change notification settings - Fork 114
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
7f794e0
commit fa99cab
Showing
2 changed files
with
70 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<?php | ||
|
||
namespace App\View\Components; | ||
|
||
use Closure; | ||
use Illuminate\Contracts\View\View; | ||
use Illuminate\View\Component; | ||
|
||
class AppLayout extends Component | ||
{ | ||
/** | ||
* Get the view / contents that represent the component. | ||
*/ | ||
public function render(): View|Closure|string | ||
{ | ||
return view('layouts.app'); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
<!DOCTYPE html> | ||
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}"> | ||
<head> | ||
<meta charset="utf-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
|
||
<title>{{ $title ?? 'Page Title' }}</title> | ||
|
||
{{-- Fonts --}} | ||
<link href="{{ asset('fonts/inter/inter.css') }}" rel="stylesheet" /> | ||
|
||
{{-- Styles --}} | ||
@filamentStyles | ||
@vite('resources/css/app.css') | ||
|
||
<script> | ||
const theme = localStorage.getItem('theme') ?? 'system' | ||
if ( | ||
theme === 'dark' || | ||
(theme === 'system' && | ||
window.matchMedia('(prefers-color-scheme: dark)') | ||
.matches) | ||
) { | ||
document.documentElement.classList.add('dark') | ||
} | ||
</script> | ||
</head> | ||
<body class="min-h-screen antialiased bg-gray-50 dark:bg-gray-950 text-gray-950 dark:text-white"> | ||
<main class="p-4 sm:p-6 lg:p-8mx-auto max-w-{{ config('speedtest.content_width') }} space-y-4 sm:space-y-8"> | ||
<header class="flex flex-col gap-4 sm:flex-row sm:justify-between sm:items-center"> | ||
<div> | ||
<h1 class="text-2xl font-bold tracking-tight text-gray-950 dark:text-white sm:text-3xl">{{ $title ?? 'Page Title' }}</h1> | ||
</div> | ||
<div class="flex-shrink-0"> | ||
<x-filament::button | ||
href="{{ url('/admin') }}" | ||
tag="a" | ||
> | ||
Admin Panel | ||
</x-filament::button> | ||
</div> | ||
</header> | ||
{{ $slot }} | ||
</main> | ||
{{-- Scripts --}} | ||
@filamentScripts | ||
</body> | ||
</html> |