Stryker
Stryker
FFilament
Created by Stryker on 11/5/2023 in #❓┊help
Change row color in table builder
I am using Laravel Filament v3 in my project, and I am wondering, how could I change the row color for a specific record in a table, in my case, if payments_left === 0 I would like to change the row color to green (or any other color for example) I tried this: https://filamentphp.com/docs/3.x/tables/advanced#custom-row-classes but it doesn't change the row color. this adds the classes to the html tag, but it doesn't change the color of the row.
->recordClasses(function (RecurringExpense $record) {
if ($record->payments_left === 0) {
return 'bg-green-100 dark:bg-green-800';
}
})
->recordClasses(function (RecurringExpense $record) {
if ($record->payments_left === 0) {
return 'bg-green-100 dark:bg-green-800';
}
})
14 replies