//use Filament\Actions\Action; public function fooAction(): Action { return Action::make('foo'); //->action(...) } protected function beforeCreate(): ?Action { if (true) { $this->mountAction('foo'); $this->halt(); } }