Filament

F

Filament

Filament is a collection of beautiful full-stack components for Laravel.You can get help using it on our Discord.

Join

Tooltips not working on Disabled Action Button.

Here is the implementation ```php DirectPrintAction::make() ->visible(fn ($record) => $record->payment_status !== PaymentStatus::PENDING) ->disabled(function () {...

How to configure breadcrumbs url on manage related records

i have 2 models, forms & responses. a form has a page where the user can manage its responses (App\Filament\Resources\FormResource\Pages\ManageResponses) ive managed to put the record name in the breadcrumb setting up, in the App\Filament\Resources\FormResource, the recordtitleatribute - protected static ?string $recordTitleAttribute = 'name'; ...
No description

Injecting $record and using ->when

$record becomes an instance of TextColumn instead of Model when using the ->when condition. Is this expected behaviour? TextColumn::make('state') ->when(fn($record) => dd($record))...
Solution:

filament-spatie-translatable plugin in admin panel v2

Hello, If I am using the filament v2 admin panel where do I put the "Setting the default translatable locales"? attached screenshot
No description

Remove Title On Pages

Hi fellas any way to remove title on pages, when i use getTitle or just $title and set it to empty string whole heading disappears?
No description

element.requestFullscreen() inside a Filament modal

Hello, i want to requestFullscreen an element inside a filament modal, but it closes the modal automatically. Any idea on how to fix that ? My action : ```php Tables\Actions\Action::make('view')...
Solution:
Update : problem solved ! If anyone come across this, i just added type="button" to my buttons... 😅

Adding a progress bar to a filament form.

I have a form that performs an import of data that can run for a long time in some circumstances. I've got the backend sorted so it doesn't timeout but occasionally I get a timeout from Cloudflare. To solves this I thought I could add a progress bar that updates as the records are being processed but I can't figure out how to make this work. I started with a custom field that is has a html progress bar in it and linked that to a progress variable in the backend. But I can't seem to get it t...

filament issue

Target class [cache] does not exist when i run filament project

How to add javascript to a custom widget

I created a custom widget, How to add javascript to it, When I add it in the blade view it doesn't w

dataLabel error in Apexcharts

First and last column do not show dataLabel
No description

Slow table load and searching after adding custom action from impersonate package

I recenly add a package for impersonating user : https://github.com/stechstudio/filament-impersonate i notice that this package add a custom action to the table, but since i add the custom action to the user table the request time is increased from only 430 ms to sometimes 10 second...
No description

Halt on beforeSave is preventing actions within notification to work.

In essence I'm trying to add a check to see if a model instance exists with a 'is_home_page' boolean flag is true prior to updating or saving. I'll provide the current WIP code below for a clearer picture but in essence the notification pops up with the actions however clicking on them don't work but using the url example from the docs works perfectly fine. If anyone has any insight I'd love to hear it. Cheers! ```php protected function beforeSave(): void { $existingPage = Page::where('is_active', true)->where('is_home_page', true)->first();...

Filters On Sidebar

Hi folks, I was wondering if something like this is possible in any way with Filament? (paid plugin, view) I want to add filters to the side, based on the most popular attributes....
No description

Spatie Translatable with spatie laravel settings

Is it possible to run spatie translatable package with spatie laravel settings. And if is it possible, how?

Use cluster for user profile page

Hi I'd like to use a cluster for my profile settings page. The app I'm working on has a lot of user profile fields and I'd prefer to break them up with a cluster (sidebar) instead of tabs. Does anyone know if it's possible? When I specify the cluster at the top of my extended EditProfile class it breaks the routing. I haven't been able to get it to work....

Use HeaderAction to upload file in FileUpload.

Assume I have a fileupload component in a form on my page. By pressing a header action, is it possible to upload that file (to the specified disk)? Generally when you upload something, before you press create, that file is sitting in the livewire-tmp directory, and its only when you press "Create" that the file goes to its proper directory. In this case, we dont have a create action or a model.

Disable all browser validation

Is there a way to disable ALL browser validation from all form fields? like a global setting? Not only required, but minValue, maxValue... all possible validation errors...

getStateUsing() called 3 times on first load

Hey there, I just investigated some performance issues and noticed that each table that uses getStateUsing() has this function 3 times called on loading the table. So each query inside gets also executed 3 times! Why? Simple Example: ```php Tables\Columns\TextColumn::make('products')...
No description

Showing/Hiding buttons based on URL paramaters.

I'm using TrashedFilter and added restore button, but now I want to only show restore button when the value of param tableFilters[Trashed][value] is 0 and I want to dynamically hide/show this button when selecting new value from dropdown. How would I go on about doing this? JS? Got a bit stuck here now. Same thing for example with DeleteBulkAction button, when I'm on deleted record I want to hide it, since we can't delete the deleted records anymore for example....
No description