'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')); } }