2025-12-13 19:33:52 -06:00
|
|
|
<div class=" text-white pt-10 flex flex-col gap-5">
|
|
|
|
|
<div class="flex flex-row justify-between items-center mx-2 sm:mx-0">
|
|
|
|
|
<h1 class="text-2xl sm:text-3xl font-bold">{{$list->name}}</h1>
|
|
|
|
|
<button type="button" wire:click="toggleSettings"
|
|
|
|
|
class="hover:bg-blue-600 cursor-pointer text-white px-4 py-2 rounded">
|
2025-12-13 23:31:22 -06:00
|
|
|
<i class="fas fa-cog text-2xl"></i>
|
2025-12-13 19:33:52 -06:00
|
|
|
</button>
|
|
|
|
|
</div>
|
2025-12-12 23:07:04 -06:00
|
|
|
|
2025-12-13 19:33:52 -06:00
|
|
|
<x-ui.card class="overflow-hidden">
|
|
|
|
|
<div class="absolute">
|
|
|
|
|
<livewire:search-panel :list-id="$list->id"/>
|
|
|
|
|
<livewire:movie-details-panel/>
|
2025-12-12 23:07:04 -06:00
|
|
|
</div>
|
|
|
|
|
|
2025-12-13 19:33:52 -06:00
|
|
|
<div class="relative w-full overflow-hidden">
|
|
|
|
|
<div class="flex transition-transform duration-300 ease-in-out"
|
|
|
|
|
style="transform: translateX({{ $showSettings ? '-100%' : '0' }})">
|
2025-12-12 23:07:04 -06:00
|
|
|
|
2025-12-13 19:33:52 -06:00
|
|
|
<!-- Movie List View -->
|
|
|
|
|
<div class="w-full flex-shrink-0 flex flex-col gap-5">
|
|
|
|
|
<div class="flex flex-col-reverse sm:flex-row gap-5 sm:gap-0 justify-between w-full">
|
2025-12-13 23:31:22 -06:00
|
|
|
<input class="flex bg-white p-2 rounded sm:w-100" type="text" placeholder="Filter movies"
|
2025-12-15 23:53:07 -06:00
|
|
|
wire:model.live="filterText"
|
2025-12-13 19:33:52 -06:00
|
|
|
wire:keyup="filterMovies"/>
|
|
|
|
|
|
|
|
|
|
<button wire:click="$dispatch('openSearch')" class="bg-green-500 text-white p-2 rounded">
|
|
|
|
|
Add Movie
|
|
|
|
|
</button>
|
|
|
|
|
</div>
|
2025-12-16 00:19:12 -06:00
|
|
|
@if(!$filteredMovies->isEmpty())
|
2025-12-15 23:53:07 -06:00
|
|
|
<ul class="grid grid-cols-2 sm:grid-cols-4 gap-5">
|
|
|
|
|
@foreach ($filteredMovies as $movie)
|
|
|
|
|
<li class="bg-gray-200">
|
|
|
|
|
<x-movie :movie="$movie"/>
|
|
|
|
|
</li>
|
|
|
|
|
@endforeach
|
|
|
|
|
</ul>
|
|
|
|
|
@else
|
|
|
|
|
<div class="flex flex-col items-center justify-center my-10">
|
|
|
|
|
<span class="text-center p-5 font-bold text-2xl">"You complete me."</span>
|
|
|
|
|
<span class="text-center">Tom Cruise, <i>Jerry Maguire</i></span>
|
|
|
|
|
</div>
|
|
|
|
|
@endif
|
2025-12-13 19:33:52 -06:00
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<!-- Settings View -->
|
|
|
|
|
<div class="w-full flex-shrink-0 flex flex-col gap-5">
|
|
|
|
|
<div class="flex justify-between items-center">
|
|
|
|
|
<button wire:click="toggleSettings" class="text-white hover:text-gray-300">
|
|
|
|
|
← Back to List
|
|
|
|
|
</button>
|
|
|
|
|
<h2 class="text-xl font-semibold">Settings</h2>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="flex flex-col gap-2 w-full">
|
|
|
|
|
<label for="list-name">List Name</label>
|
|
|
|
|
<div class="flex flex-row">
|
2025-12-15 23:53:07 -06:00
|
|
|
<input type="text" wire:model.live="settingsForm.name" id="list-name"
|
2025-12-13 19:33:52 -06:00
|
|
|
class="w-full p-2 rounded rounded-r-none bg-white"/>
|
|
|
|
|
<button class="bg-green-400 p-2 rounded-r" type="submit" wire:click="saveSettings">Save
|
|
|
|
|
</button>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="flex items-center justify-between bg-gray-700 p-4 rounded">
|
|
|
|
|
<label for="is_public" class="text-white">Make list public</label>
|
|
|
|
|
<input type="checkbox"
|
|
|
|
|
id="is_public"
|
|
|
|
|
wire:model.live="settingsForm.isPublic"
|
|
|
|
|
class="w-5 h-5 text-blue-600 bg-gray-100 border-gray-300 rounded focus:ring-blue-500">
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</x-ui.card>
|
2025-12-12 23:07:04 -06:00
|
|
|
|
|
|
|
|
</div>
|