test(actions): cover native modals for actions with fields

This commit is contained in:
MeghdadFadaee committed 2026-07-30 14:26:02 +03:30
1 parent ade3fc100a
commit 237bcab43b
3 files changed
+44

No files matched your search

+19
View File
@@ -67,6 +67,25 @@ public function actions(NovaRequest $request): array
`exceptInline()` leaves actions available in Nova's bulk selector and detail
view while removing them from the row ellipsis.
### Actions with form fields
Actions that define fields use Nova's native action modal automatically. Leave
`confirm` unset so the action's own confirmation strategy, fields, validation,
file uploads, and dependent-field behavior are preserved.
```php
RowActions::make('Actions')
->add(
Reject::make(),
icon: 'x-mark',
color: 'danger',
);
```
Do not set `confirm: false` on a field-bearing action unless it is intentionally
safe to execute with the fields' default values. That option maps directly to
Nova's `withoutConfirmation` behavior and bypasses the entire action modal.
## Button options
`add()` accepts the following named arguments: