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.
📜 Description
Adds the option to define
supportedModes
so that, for instance,FeedbackMode.navigate
is not displayed.💡 Motivation and Context
For a single page desktop application, the
navigate
option may not be required. Moreover, the user can continue to interact with the application as usual (i.e. right click), thus there can be cases where we do not want to allow the user to interact while the feedback window is open.Conversely, I am not sure if there are real-world use-cases where the user can interact/navigate but not draw, nevertheless those would be covered by this PR.
💚 How did you test it?
Update
example/lib/main.dart
, changesupportedModes
accordingly.Technically the user can select
which is non-sensical. A check in
FeedbackWidget
ensures correct state, however the api could be updated, i.e. first value ofsupportedModes
.Moreover, assets/errors could be raised when
supportedModes
is empty;📝 Checklist
🔮 Next steps
FeedbackMode.navigate
perhaps needs a renaming tointeractive
. This, perhaps, could be more descriptive. Such a change, however, would be a breaking change best suited to another PR.mode
was left as-is to not introduce any breaking changes (see discussion above).