filamentphp / filament

A collection of beautiful full-stack components for Laravel. The perfect starting point for your next app. Using Livewire, Alpine.js and Tailwind CSS.
https://filamentphp.com
MIT License
19.55k stars 2.98k forks source link

Action ->hidden() does not hide but instead disabled the button #8196

Closed ezani92 closed 1 year ago

ezani92 commented 1 year ago

Package

filament/filament

Package Version

3

Laravel Version

10

Livewire Version

3

PHP Version

8.2

Problem description

return Action::make('posadminlogin') ->label('Sign In') ->url($this->account.'/sso/'.$this->sso()) ->hidden() ->extraAttributes(['class' => 'btn-wide w-full bg-indigo-800 text-white']);

Above is code how i add an action to custom page. instead of hide the action button. its show the button but in disabled mode.

Expected behavior

Button should be hidden instead of disabled when using hidden()

Steps to reproduce

return Action::make('posadminlogin') ->label('Sign In') ->url($this->account.'/sso/'.$this->sso()) ->hidden() ->extraAttributes(['class' => 'btn-wide w-full bg-indigo-800 text-white']);

Reproduction repository

https://github.com/filamentphp/filament

Relevant log output

No response

github-actions[bot] commented 1 year ago

Hey @ezani92! We're sorry to hear that you've hit this issue. 💛

However, it looks like you forgot to fill in the reproduction repository URL. Can you edit your original post and then we'll look at your issue?

We need a public GitHub repository which contains a Laravel app with the minimal amount of Filament code to reproduce the problem. Please do not link to your actual project, what we need instead is a minimal reproduction in a fresh project without any unnecessary code. This means it doesn't matter if your real project is private / confidential, since we want a link to a separate, isolated reproduction. That would allow us to download it and review your bug much easier, so it can be fixed quicker. Please make sure to include a database seeder with everything we need to set the app up quickly.

russdot commented 1 month ago

I am encountering this same problem. I have an Action on a widget and calling ->hidden() results in it showing as disabled?