-
-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue when using super_context_menu with flutter_markdown as a child #389
Comments
Which platform does this happen on? |
iOS, I didn't test it on Android. |
@knopp this issue is preventing me from using the package, if you can please take a look |
This is a bug in class _BaseContextMenu extends StatefulWidget {
@override
State<_BaseContextMenu> createState() => _BaseContextMenuState();
}
class _BaseContextMenuState extends State<_BaseContextMenu> {
bool pointerDown = false;
final key = GlobalKey();
@override
Widget build(BuildContext context) {
final child = MarkdownBody(
key: key,
data: 'What is this [content](https://example.com)',
onTapLink: (text, _, __) {
print('Clicked on $text');
},
);
return Listener(
onPointerDown: (event) {
setState(() {
pointerDown = true;
});
},
onPointerUp: (event) {
setState(() {
pointerDown = false;
});
},
child: pointerDown
? ColoredBox(
color: Colors.green,
child: child,
)
: child,
);
}
} |
Reported the issue here: flutter/flutter#150558 |
Thanks @knopp. |
I am using
flutter_markdown
(which is an official package) on a widget that also usessuper_context_menu
, it happens that usingsuper_context_menu
brakes the tappable links defined byflutter_markdown
andIt looks like a bug.
Sample code combining the two pacakges:
The text was updated successfully, but these errors were encountered: