From aa0051a841c28365d6d92082a0c0e5dfb6fad416 Mon Sep 17 00:00:00 2001 From: Adam Weston Date: Thu, 18 Jul 2024 12:16:13 -0400 Subject: [PATCH] Update README.md --- README.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/README.md b/README.md index fc982b7..373b595 100644 --- a/README.md +++ b/README.md @@ -222,3 +222,20 @@ public function panel(Panel $panel): Panel ]) } ``` + +### Forcing all resources to use modals + +Quick create will automatically determine if it should redirect to a create page or to show the form in a modal based on the resource. If you prefer to force all items to be show in a modal you can do so with the `alwaysShowModal()` modifier. + +```php +use Awcodes\FilamentQuickCreate\QuickCreatePlugin; + +public function panel(Panel $panel): Panel +{ + return $panel + ->plugins([ + QuickCreatePlugin::make() + ->alwaysShowModal(), + ]) +} +```