diff --git a/doc/adr/0001-fix-tap-event-is-not-simulated-in-a-overlay-on-flutter-3-7-for-web-desktop.md b/doc/adr/0001-fix-tap-event-is-not-simulated-in-a-overlay-on-flutter-3-7-for-web-desktop.md new file mode 100644 index 0000000..0365173 --- /dev/null +++ b/doc/adr/0001-fix-tap-event-is-not-simulated-in-a-overlay-on-flutter-3-7-for-web-desktop.md @@ -0,0 +1,23 @@ +# 1. Fix tap event is not simulated in a overlay on Flutter 3.7 for Web/Desktop + +Date: 2023-04-24 + +## Status + +Accepted + +## Context + +Tap events are not being simulated to overlay on the `Web/Desktop` but work fine on mobile devices. This worked fine until the previous release stable 3.3. + +## Root causes + +Because the thing that the overlay is attached to is a `TextField`, so in order to keep from unfocused the text field when tapping outside of it, you need to tell the overlay widget that it's part of the TextField for purposes of the `tap outside` behavior by adding the `TextFieldTapRegion` around it, so that when the tap arrives, it's considered `inside` of the text field. + +## Decision + +Try wrapping a `TextFieldTapRegion` around the `Material` in the overlay. + +## Consequences + +This worked fine