-
Notifications
You must be signed in to change notification settings - Fork 455
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
Overlay not showing in flutter 3.7.0 #330
Comments
I'm having the same issue. Is there a fix? |
Yes, you need to wrap the widget directly in an Overlay like this : Overlay(
initialEntries: [
OverlayEntry(
builder: (context) => ShowcaseWidget(
child: child,
),
),
],
), |
@Thelm76 I'm curious, why we don't embed that wrapper to the plugin |
Hello, I have the same issue. btw, i use navigation 2.0 with materialApp.router
and it used to work fine 'till i upgraded to flutter 3.7 where i got this issue so until now, just like above. but when i tried to wrap it into an overlay as advised
it gets trickier with this error instead : and if i do so they tell me : i would love some help and advice on this one :) thank you |
We are experiencing the same issue since 3.7. Our ancestor was MaterialApp but seems that it could not be found using the new version. That is the solution which is also contained in the error message |
Hi, @robbyxulu. I have tried to replicate your issue with your given code snippets, you can refer below code as well and I didn't find any issue. Please let me know if I miss something as per your issue. Thanks !! Flutter doctor output
Code Snippets
|
Hi!
update: New metod of Overlay.maybeOf
|
@isafiulin, thank you for your contribution. Did you make a fork so we can test the fix? I am still thinking the problem is in combination of new flutter version above 3.7 and go router. The error message states that the context does not contain any overlay widget like MaterialApp, CupertinoApp or Navigator widget. But that's the case
The actual show case is placed in the screen widgets. It used to work until version 3.7 |
Hi @Spitzbua . Nope, I fixed this issue in production project. So I don't have fork. I use this plugin in th project, but I customized it with our design and necessity. But I found, that alarm with "No Overlay widget found" caused after function addToOverlay. In 3.7 flutter they modified Overlay and Overlay.of(context) works a little bit another. After modifying this function "addToOverlay" and nothing else , I dont have any alarm events with "No Overlay widget found" |
@isafiulin , thanks for the quick response. I have made a pull request to cover that change. Thank you for pointing out that of(context) behaviour changed!highly appreciated! There's a tiny issue in your code. You are checking against Overlay.maybeOf(showCaseContext) in the first condition but inserting the overlayEntry in Overlay.maybeOf(context). I have used and tested this piece of code:
|
same issue |
Any updates on this one? Having the same issue after upgrading to latest flutter version |
This modification was made on the origin `flutter_showcaseview` repo to address breaking overlay funcationality starting with Flutter v3.7. While on Flutter v3.3.8 we began to see errors on `debug` builds, fortunately `release` builds worked as expected. However, these changes _should_ be stable through the currently latest Fluttever v3.10. These changes originate from this origin PR: - https://github.com/SimformSolutionsPvtLtd/flutter_showcaseview/pull/288/files#diff-b2d82fcab3cc9afc9edfa76d01dc74baae2bc26ffa48352229249070f471d72aR174-R180 For more reference see: - flutter/flutter#120591 - SimformSolutionsPvtLtd#330
Before i update my flutter to 3.7.0 it is work properly
now it won't show and gave me this error
my flutter
i use some showcase like this
The text was updated successfully, but these errors were encountered: