Filament

F

Filament

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

Join

Adding a record count alongside a navigation link

Hi could you point me to the feature that enables the display of the number of orders (in this case 193) shown in the attached?
I can see it's related to the number of "new" orders - just need to understand how the number gets put there. I have had a look at the source code on github and see the navigation title definition here...
Solution:
public static function getNavigationBadge(): ?string
{
return 420;
}
public static function getNavigationBadge(): ?string
{
return 420;
}
...
No description

User select

Hello, I'm starting to use FilamentPHP and would like to ask a question. How do I limit the user select to display only those with the role of realtor? I use this plugin: https://v2.filamentphp.com/plugins/althinect-spatie-roles-permissions ```...

SelectFilter default not working

I am trying to set a default value on my SelectFilter: ```php SelectFilter::make('status') ->multiple() ->options(RefundStatus::class)...
Solution:
Make sure you use RefundStatus::Pending->value.

universal date/time formatting

How come every page that has a date/time on it i have to keep telling my developers to fix the formatting to something proper such as MM/DD/YYYY 7:38 AM ? They told me there is no universal setting. Can someone build that to the core filament?

Duplicate query problem when using a relationship in a repeater

Hey all, I have the following repeater: ``` Repeater::make('answers') ->label('Answers') ->translateLabel()...

Several recordClasses

Hi guys. I would like to apply several css styles according to the added rules but I can't find a way to be able to do more than one check with recordClasses. If I create this rule it works perfectly:...

Displaying prefill data in action form select with relationship

```php Tables\Actions\Action::make('assign_role') ->form([ Forms\Components\Select::make('roles.name') ->relationship('roles', 'name')...
Solution:
You can do
->fillForm(fn($record) => return the data)
->fillForm(fn($record) => return the data)
...

All Tenant

Would it be possible to add an option 'All' in the tenant selector that allows users to view all the resources they have access to, for example: (All, team 1, team 2)?

Collapsible Content - Keep Column Headers

Would like a user to be able to expand a row and kindof peek some details about that record in the collapsible content. Using https://filamentphp.com/docs/3.x/tables/layout#collapsible-content works well... however, the headers disappear. Is this possible?...
Solution:
No, you could modify a single column to have a reveal using formateStateUsing and use HtmlString to format a custom revealer. Or just use an action to slide out the data....

Showing the last page as default

I would like when I go to my Posts page, and I get the table with results, to get the last page with the results, not the first, as it is default. Tried to find anything related in documentation, but no success.

Notification::duration() has no effect

I try to set the duration of a Notification, but if I set any value for duration, it disappear after ~6 sec, even if I add the persisitent() function. Can it be a bug or I missed something?

Inject custom filters in render hook TOOLBAR_START

Dear all, I want to add some custom filter tabs in the table builder on the line left of the search field. They should serve as something like a quick filter for my users. I found already that the only way to inject something in that place is via render hooks. I was able to successfully add the render hook by injecting the html via a ServiceProvider, like so:...

Could not resolve "../../vendor/filament/notifications/dist/module.esm" from "resources/js/app.js"

when running npm run build. it shows error. any idea how to fix it? the file that exist is index.js...

My Bulkaction buttons do not fit in the table, can we add scroll?

As shown in the picture, the bulkactions do not fit on the page, can I add a scroll to them or how do I fit them? Another question is, as soon as the page is loaded, can I bring one of the records as selected so that the bulkaction buttons are always visible?...
No description

Issue: Filament Shield

In my filament project used filament shield for role and permission and now in the created page i have this error ! ``` { "type": "project",...

Modify the filter icon display on table filters?

Is it possible to update how the Filter Display looks in the Table (when adding to a Livewire component)? I've got a client asking for it to be a more prominent button with the word "Filters" next to it, but not sure how to go about it. Thanks for any help!...

Handle uploaded images columns and rows

The image uploader, by default, displays the uploaded images in a single column. Is there a way to display the uploaded images in a row with multiple columns? For example, I have a container with 4 columns that I want to fill with the uploaded images. Currently, only one of the columns gets filled, and I can't display them in a row....
Solution:
->panelLayout(‘grid’)

Is it possible to add a badge to top line with a number on it?

I can see in the filament demo there is a bell icon with a number just above - i'd like to implement something similar using a different icon - could anyone point me to what I need to be reading in the documentation? Clicking the bell in the demo opens a slideover with a list of the items contained within - that's what I'd like to be able to implement albeit with a different icon. Thx for pointers,...

Seeking Help with Custom Login Design Overlap in Filament

Hello everyone, I'm currently working on a custom login page using Filament, but I'm running into an issue where my design overlaps with the default Filament styles. I want to ensure that my login page displays correctly without any interference from Filament's default components. Here's What I've Done So Far:...

Modal not working on Firefox

I have a project and the modals are working on Chrome, Opera, Safari. I found a bug report to the livewire repo that matches what we are facing, anyone else having this issue? Link to github discussion: https://github.com/livewire/livewire/discussions/7746),...