Add group creation and show current groups

This commit is contained in:
2026-03-02 00:19:55 +01:00
parent e405fec5c2
commit 4bdaf7a8ab
19 changed files with 1010 additions and 160 deletions

View File

@@ -1,13 +1,30 @@
<?php
use Illuminate\Support\Collection;
use Livewire\Component;
new class extends Component
{
//
new class extends Component {
public Collection $crews;
public function mount(): void
{
$this->crews = Auth::user()
->crews()
->withCount(['users', 'patches'])
->get();
}
};
?>
<div>
{{-- Order your soul. Reduce your wants. - Augustine --}}
</div>
<div class="flex flex-col gap-3 px-4 pt-6 pb-4">
<div class="flex items-center justify-between">
<h1 class="text-xl font-bold text-foreground">Your Groups</h1>
<div class="flex gap-2">
<button class="btn-outline w-full text-base bg-background">Join</button>
<livewire:groups.create/>
</div>
</div>
@foreach($crews as $crew)
<livewire:group-card :crew="$crew" :key="$crew->id"/>
@endforeach
</div>