Merge Confirmation Dialogs into Alert, Confirmation or Prompt#4114
Conversation
|
There's a good few, but I'll leave it at that for now. 😃 |
|
I wonder if we can't combine the dialogs, the only real difference is the cancel button? |
|
And later also add a |
|
I guess so. I'll take the android naming of an |
|
With prompt I meant this: https://developer.mozilla.org/en-US/docs/Web/API/Window/prompt |
|
So we would have: |
|
And I suggest we make 3 different helpers for the same dialog: |
|
Sorry should have set this to WIP. Still adding and changing, just pushing as I go 😃 |
|
OK, let me know what you think |
| ` | ||
| : this._params.text | ||
| ? html` | ||
| <p>${this._params.text}</p> |
There was a problem hiding this comment.
You can display text when it is a prompt?
There was a problem hiding this comment.
I'll move this above since a prompt might want an explanation above the input
bramkragten
left a comment
There was a problem hiding this comment.
OK to merge after comments are addressed.
Co-Authored-By: Bram Kragten <mail@bramkragten.nl>
|
Commited suggestions. I'll take a proper look when I get home and address the rest later as I'm remote at the moment |
|
OK, I think that's everything |
Co-Authored-By: Bram Kragten <mail@bramkragten.nl>
Co-Authored-By: Bram Kragten <mail@bramkragten.nl>









Description
Adds alert dialog and replaces the confirmation dialog so that prompts and alerts can be called in the same component. Also adds prompts to more sections of the UI.
Issue this references
Closes #4103
Screenshots
Dev tools - States (no entity_id):
Dev tools - Events (no event type)
Automation - Delete: