diff --git a/docs/filters/available-methods.md b/docs/filters/available-methods.md index 5246704e9..820916003 100644 --- a/docs/filters/available-methods.md +++ b/docs/filters/available-methods.md @@ -206,6 +206,30 @@ public function configure(): void } ``` +### setFilterPopoverAttributes + +Allows for the customisation of the appearance of the Filter Popover Menu. + +Note the addition of a "default-width" boolean, allowing you to customise the width more smoothly without impacting other applied classes. + +You may also replace default colors by setting "default-colors" to false, or default styling by setting "default-styling" to false, and specifying replacement classes in the "class" property. + +You can also replace the default transition behaviours (Tailwind) by specifying replacement attributes in the array. + +```php +public function configure(): void +{ + $this->setFilterPopoverAttributes( + [ + 'class' => 'w-96', + 'default-width' => false, + 'default-colors' => true, + 'default-styling' => true, + 'x-transition:enter' => 'transition ease-out duration-100', + ] + ); +} +``` ---- diff --git a/resources/views/components/tools/toolbar/items/filter-popover.blade.php b/resources/views/components/tools/toolbar/items/filter-popover.blade.php index a12755277..2321f9f18 100644 --- a/resources/views/components/tools/toolbar/items/filter-popover.blade.php +++ b/resources/views/components/tools/toolbar/items/filter-popover.blade.php @@ -1,66 +1,51 @@ -@aware([ 'tableName','isBootstrap','isBootstrap4','isBootstrap5']) +@aware(['tableName']) @if($this->isBootstrap) -