@extends('layouts.app') @section('title', 'Photo Gallery') @section('page-title', 'Photo Gallery') @section('content')
{{-- Header --}}

Photo Gallery

Browse photos from school events and activities

@if(auth()->user()->role === 'admin') @endif
{{-- Category Filters --}}
All @foreach(App\Models\GalleryAlbum::categories() as $key => $label) {{ $label }} @endforeach
{{-- Albums Grid --}}
@forelse($albums as $album) {{-- Cover --}}
@if($album->cover_url) {{ $album->title }} @else
@endif {{-- Photo count badge --}}
{{ $album->photos_count }}
{{-- Category badge --}} @php $catColors = ['sports'=>'bg-green-500','cultural'=>'bg-purple-500','academic'=>'bg-blue-500','celebration'=>'bg-pink-500','trip'=>'bg-cyan-500','graduation'=>'bg-yellow-500','general'=>'bg-stone-500','other'=>'bg-stone-400']; @endphp
{{ App\Models\GalleryAlbum::categories()[$album->category] ?? $album->category }}
{{-- Unpublished indicator --}} @if(!$album->is_published)
Draft
@endif
{{-- Info --}}

{{ $album->title }}

@if($album->event_date)

{{ $album->event_date->format('d M Y') }}

@endif @if($album->description)

{{ $album->description }}

@endif
@empty

No albums yet

Photo albums will appear here when uploaded

@endforelse
@if($albums->hasPages())
{{ $albums->links() }}
@endif
{{-- Create Album Modal --}} @if(auth()->user()->role === 'admin') @endif @endsection