I'm currently available for full time hire! Inquire Here

Laravel Livewire Tables Documentation

🎉 Enjoying this package? Consider sponsoring me on GitHub or buying me a beer.

This is the documentation for v3. You can switch versions in the menu at the top. Check your current version with the following command:

composer show rappasoft/laravel-livewire-tables

Styling

setFooterTrAttributes

Set any attributes on the footer row element.

1public function configure(): void
2{
3 $this->setFooterTrAttributes(function($rows) {
4 return ['class' => 'bg-gray-100'];
5 });
6}

By default, this replaces the default classes on the tr element, if you would like to keep them, set the default flag to true.

1public function configure(): void
2{
3 $this->setFooterTrAttributes(function($rows) {
4 return [
5 'default' => true,
6 'class' => 'bg-gray-100'
7 ];
8 });
9}

setFooterTdAttributes

Set any attributes on the footer row cells.

1public function configure(): void
2{
3 $this->setFooterTdAttributes(function(Column $column, $rows) {
4 if ($column->isField('id')) {
5 return ['class' => 'text-red-500'];
6 }
7 });
8}

By default, this replaces the default classes on the td element, if you would like to keep them, set the default flag to true.

1public function configure(): void
2{
3 $this->setFooterTdAttributes(function(Column $column, $rows) {
4 if ($column->isField('id')) {
5 return [
6 'default' => true,
7 'class' => 'text-red-500'
8 ];
9 }
10 });
11}