first(); return [ 'name' => config('app.name'), 'version' => $latestUpdate?->version ?? 'v1.0.0', 'stack' => [ 'PHP' => PHP_VERSION, 'Laravel' => app()->version(), 'Filament' => 'v5.x', 'Database' => config('database.default'), ], ]; } #[Computed] public function changelogs(): Collection { return Changelog::latest('release_date')->get(); } protected function getHeaderActions(): array { return [ CreateChangelogAction::make() ->visible(fn () => auth()->user()?->can('Create:Changelog')), ]; } public function editChangelogAction(): Action { return EditChangelogAction::make() ->visible(fn () => auth()->user()?->can('Update:Changelog')); } public function deleteChangelogAction(): Action { return DeleteChangelogAction::make() ->visible(fn () => auth()->user()?->can('Delete:Changelog')); } #[Computed] public function emptyHeading(): string { return SystemNotification::getByKey('labels.empty_changelog.title'); } #[Computed] public function emptyDescription(): string { return SystemNotification::getByKey('labels.empty_changelog.description'); } public function changelogFormSchema(): array { return [ Grid::make(3) ->schema([ TextInput::make('version') ->label('Versi') ->placeholder('v1.0.0') ->required() ->unique(ignoreRecord: true), DatePicker::make('release_date') ->label('Tanggal Rilis') ->required() ->native(false) ->default(now()) ->displayFormat('d F Y'), Select::make('type') ->label('Tipe Update') ->options(ChangelogType::class) ->required() ->native(false), ]), TextInput::make('title') ->label('Judul Update') ->placeholder('Sistem Notifikasi & Estetika Baru') ->required() ->maxLength(100) ->autocomplete(false), TagsInput::make('changes') ->label('Daftar Perubahan') ->placeholder('Tambah perubahan...') ->required(), RichEditor::make('description') ->label('Deskripsi') ->placeholder('...') ->required(), ]; } }