32 lines
1.2 KiB
PHP
32 lines
1.2 KiB
PHP
<?php
|
|
$authService = new \App\Modules\Auth\Services\AuthService();
|
|
$currentUser = $authService->currentUser();
|
|
$currentUri = service('request')->getPath();
|
|
?>
|
|
<!DOCTYPE html>
|
|
<html lang="id">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title><?= esc($title ?? 'Dashboard') ?> | SMAN 1 Garut</title>
|
|
<script src="https://cdn.tailwindcss.com"></script>
|
|
<script>
|
|
tailwind.config = { theme: { extend: { colors: { primary: { DEFAULT: '#3C50E0', hover: '#2E43C7' } } } } };
|
|
</script>
|
|
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/boxicons@2.1.4/css/boxicons.min.css">
|
|
</head>
|
|
<body class="bg-gray-100 dark:bg-gray-900 text-gray-800 dark:text-gray-200">
|
|
<div class="flex min-h-screen">
|
|
<?= view('partials/sidebar', ['user' => $currentUser, 'current_uri' => $currentUri]) ?>
|
|
<div class="flex-1 flex flex-col">
|
|
<?= view('partials/header', ['user' => $currentUser ?? $user ?? null]) ?>
|
|
<main class="flex-1 p-6 overflow-auto">
|
|
<?= $content ?>
|
|
</main>
|
|
<?= view('partials/footer') ?>
|
|
</div>
|
|
</div>
|
|
<?= view('partials/scripts') ?>
|
|
</body>
|
|
</html>
|