Add useDeleteButtonTooltip property for Chip#68237
Conversation
63cfb79 to
1f90be4
Compare
| /// [deleteButtonTooltipMessage]. | ||
| /// | ||
| /// If null, defaults to `true`. | ||
| bool? get useDeleteButtonTooltip; |
There was a problem hiding this comment.
Why is this allowed to be null? Seems like it should just be non-nullable, and available on all the subclasses, like autofocus is.
There was a problem hiding this comment.
Should I add an assert in that case?
There was a problem hiding this comment.
If you remove the ?, it will then be non-nullable. You can add an assert: it will be useful while we are still in "hybrid" mode non-nullability support, but the assert will eventually be removed, because the compiler will just prevent it from happening, and it won't be needed anymore.
|
@royarg02 I've removed the "work in progress" label, since it looks like this PR is done, but I won't commit it until you give the go-ahead. |
|
@gspencergoog sure, I'm all done from my side. |

Description
This PR adds a new property for Chips which have a "delete" button, i.e., extend DeletableChipAttributes (Chip, InputChip, and RawChip) named
useDeleteButtonTooltip, which enables the user to optionally disable the tooltip for the chip's delete button byuseDeleteButtonTooltip: false.When unspecified, the default value of
useDeleteButtonTooltipistrue.Related Issues
Fixes #67944.
Tests
I added the following tests:
Checklist
Before you create this PR, confirm that it meets all requirements listed below by checking the relevant checkboxes (
[x]). This will ensure a smooth and quick review process.///).flutter analyze --flutter-repo) does not report any problems on my PR.Breaking Change
Did any tests fail when you ran them? Please read Handling breaking changes.