Added XenForo route system and custom menu render.

This commit is contained in:
2026-05-21 13:20:16 +02:00
parent 95f0b4ff01
commit 7cd6dfddda
13 changed files with 310 additions and 14 deletions

View File

@@ -0,0 +1,37 @@
<?php
namespace App\Livewire;
use App\Models\Entry;
use Livewire\Component;
class EntryFilesModal extends Component
{
public bool $open = false;
public ?int $entryId = null;
protected $listeners = [
'entryOpenFilesModal' => 'openModal'
];
public function openModal( int $entryId ): void
{
$this->entryId = $entryId;
$this->open = true;
$this->dispatch('modal:opened');
}
public function close(): void
{
$this->open = false;
$this->entryId = null;
}
public function render()
{
$files = $this->entryId ? Entry::find($this->entryId)?->files : collect();
return view('livewire.entry-files-modal', compact('files'));
}
}