projek_padi/web_TA/resources/views/layouts/admin.blade.php

91 lines
5.8 KiB
PHP

<!DOCTYPE html>
<html lang="id">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Dashboard Admin - Padi</title>
<script src="https://cdn.tailwindcss.com"></script>
<link href="https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700&display=swap" rel="stylesheet">
<script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
<style>body { font-family: 'Plus Jakarta Sans', sans-serif; }</style>
</head>
<body class="bg-gray-50 text-gray-800">
<div class="flex h-screen overflow-hidden">
<aside class="w-64 bg-white border-r border-gray-200 hidden md:flex flex-col">
<div class="h-20 flex items-center px-8 border-b border-gray-100">
<div class="text-emerald-700 font-bold text-xl flex items-center gap-2">
<span class="text-2xl">🌾</span> PakarPadi
</div>
</div>
<nav class="flex-1 px-4 py-6 space-y-2 overflow-y-auto">
<a href="/dashboard" class="flex items-center gap-3 px-4 py-3 rounded-xl transition-all {{ request()->is('dashboard') ? 'bg-emerald-50 text-emerald-700 font-semibold' : 'text-gray-500 hover:bg-gray-50 hover:text-emerald-600' }}">
<svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5" fill="none" viewBox="0 0 24 24" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2V6zM14 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2V6zM4 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2v-2zM14 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2v-2z" />
</svg>
Dashboard
</a>
<p class="px-4 text-xs font-semibold text-gray-400 uppercase mt-6 mb-2">Master Data</p>
<a href="/dataset" class="flex items-center gap-3 px-4 py-3 rounded-xl transition-all {{ request()->is('dataset*') ? 'bg-emerald-50 text-emerald-700 font-semibold' : 'text-gray-500 hover:bg-gray-50 hover:text-emerald-600' }}">
<svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5" fill="none" viewBox="0 0 24 24" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z" />
</svg>
Manajemen Dataset
</a>
<a href="/produk" class="flex items-center gap-3 px-4 py-3 rounded-xl transition-all {{ request()->is('produk*') ? 'bg-emerald-50 text-emerald-700 font-semibold' : 'text-gray-500 hover:bg-gray-50 hover:text-emerald-600' }}">
<svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5" fill="none" viewBox="0 0 24 24" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M16 11V7a4 4 0 00-8 0v4M5 9h14l1 12H4L5 9z" />
</svg>
Manajemen Produk
</a>
<a href="/history-klasifikasi" class="flex items-center gap-3 px-4 py-3 rounded-xl transition-all {{ request()->is('history-klasifikasi*') ? 'bg-emerald-50 text-emerald-700 font-semibold' : 'text-gray-500 hover:bg-gray-50 hover:text-emerald-600' }}">
<svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5" fill="none" viewBox="0 0 24 24" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2" />
</svg>
History Classification
</a>
</nav>
<div class="p-4 border-t border-gray-100">
<form action="{{ route('logout') }}" method="POST">
@csrf
<button type="submit" class="w-full flex items-center justify-center gap-2 px-4 py-2 bg-red-50 text-red-600 rounded-lg hover:bg-red-100 transition text-sm font-medium">
<svg xmlns="http://www.w3.org/2000/svg" class="h-4 w-4" fill="none" viewBox="0 0 24 24" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17 16l4-4m0 0l-4-4m4 4H7m6 4v1a3 3 0 01-3 3H6a3 3 0 01-3-3V7a3 3 0 013-3h4a3 3 0 013 3v1" />
</svg>
Logout
</button>
</form>
</div>
</aside>
<main class="flex-1 flex flex-col h-screen overflow-hidden relative">
<header class="h-20 bg-white border-b border-gray-100 flex items-center justify-between px-8">
<h2 class="text-xl font-bold text-gray-800">
@yield('title', 'Dashboard')
</h2>
<div class="flex items-center gap-4">
<div class="text-right hidden sm:block">
<p class="text-sm font-bold text-gray-700">{{ Auth::user()->name ?? 'Administrator' }}</p>
<p class="text-xs text-gray-400">Admin Utama</p>
</div>
<div class="h-10 w-10 rounded-full bg-emerald-100 flex items-center justify-center text-emerald-600 font-bold">
A
</div>
</div>
</header>
<div class="flex-1 overflow-y-auto p-8 bg-gray-50">
@yield('content')
</div>
</main>
</div>
</body>
</html>