-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FR: Prompt option similar to action fields #18
Comments
Personally i think this would be waaay better: Button::make('Cancel Account')
->ask('Are you sure?')
->cancel('Nope')
->confirm('Yes i do!')
->addFields(function() {
return [
Text::make('Reason'),
];
}), |
Nice idea! Yeah I can definitely see the usefulness of being able to add fields for the button. It is almost like actions in that ability. I was planning on adding action support to this package and this may overlap and provide identical functionality. Button::make(‘Text’)->action(ActionWithFields::class), I’m going to think on this a bit |
My problem with this is that vue portal is used in nova for each index row to render delete modals. Adding all this markup per row of a table seems irresponsible lol 25 rows with 25 action modals with 5 fields and of course not just text fields turns into ALOT |
its a serious problem then |
It's not possible to execute the action with javascript trigger ?
|
Button triggering an action would be useful on the There would be no "flooding the markup" problem on the detail page. Maybe that could be implemented first? 🙏 |
Like the native javascript
prompt
, it would be awesome to have this option, where you can supply any fields in a callback like action fields. If no callback is defined (or empty), a default text field should be provided.The text was updated successfully, but these errors were encountered: