hacktons / convex_bottom_bar

A Flutter package which implements a ConvexAppBar to show a convex tab in the bottom bar. Theming supported.
https://bar.hacktons.cn
Apache License 2.0
791 stars 147 forks source link

Error: Member not found: 'DefaultTabController.maybeOf'. Issue #193

Closed Phero49 closed 1 year ago

Phero49 commented 1 year ago

`Compile failed

../.pub-cache/hosted/pub.dartlang.org/convex_bottom_bar-3.2.0/lib/src/bar.dart:478:54: Error: Member not found: 'DefaultTabController.maybeOf'.

return widget.controller ?? DefaultTabController.maybeOf(context);

                                                 ^^^^^^^`
Phero49 commented 1 year ago

Am getting this issue when ever i run the code with the package

avenwu commented 1 year ago

Duplicate of #188

hp0632 commented 1 year ago

this #188 can't be fixed this problem , flutter version 3.3.9, the bottom_bar is 3.2.0 . I try it but can't work .

avenwu commented 1 year ago

There can be some misleading. #188 means you need to upgrade to flutter v3.7.0+ or downgrade the package version to v3.0.1+1

You may also update to 3.2.0 which fix the compiling error when using flutter 3.7

I did not found the change list of when "DefaultTabController.maybeOf" was first introduced, but flutter 3.7 has this api, maybe 3.6 too.