Add dialog-box warning support #7356
Merged
bramkragten merged 3 commits intohome-assistant:devfrom Oct 19, 2020
Merged
Conversation
bramkragten
reviewed
Oct 17, 2020
0fb32f8 to
bd765b7
Compare
bramkragten
approved these changes
Oct 19, 2020
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Breaking change
Proposed change
Helper function to create a question dialog with default Yes/No option (no button selection so user has to purposely select an option). The confirm and dismiss texts can still be override as before.
Also added the option to flag a dialog as containing a warning so that the matching CSS class gets applied.
The idea came to me when I changed the name of a device. The user then gets asked whether the entity IDs should also be changed. I saw two issues here:
Type of change
Example configuration
Additional information
Checklist
If user exposed functionality or configuration variables are added/changed: