I am getting this exception when pressing a button to open a bottomSheet
======== Exception caught by gesture ===============================================================
The following assertion was thrown while handling a gesture:
No Scaffold widget found.
CreateAccountView widgets require a Scaffold widget ancestor.
The specific widget that could not find a Scaffold ancestor was: CreateAccountView
dependencies: [MediaQuery]
state: _CreateAccountViewState#46a67
The ancestors of this widget were:
: PlatformApp
dependencies: [_InheritedTheme]
: PlatformTheme
state: _PlatformThemeState#080d1
: PlatformProvider
state: _PlatformProviderState#19eea
: MyApp
...
Typically, the Scaffold widget is introduced by the MaterialApp or WidgetsApp widget at the top of your application widget tree.
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.10.6, on macOS 13.4.1 22F770820d darwin-arm64, locale fr-CA)
[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.0)
[✓] Xcode - develop for iOS and macOS (Xcode 14.3.1)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2022.2)
[✓] Android Studio (version 2022.1)
[✓] VS Code (version 1.80.0)
[✓] Connected device (3 available)
[✓] Network resources
I am getting this exception when pressing a button to open a bottomSheet
======== Exception caught by gesture =============================================================== The following assertion was thrown while handling a gesture: No Scaffold widget found.
CreateAccountView widgets require a Scaffold widget ancestor. The specific widget that could not find a Scaffold ancestor was: CreateAccountView dependencies: [MediaQuery] state: _CreateAccountViewState#46a67 The ancestors of this widget were: : PlatformApp dependencies: [_InheritedTheme] : PlatformTheme state: _PlatformThemeState#080d1 : PlatformProvider state: _PlatformProviderState#19eea : MyApp ...
Typically, the Scaffold widget is introduced by the MaterialApp or WidgetsApp widget at the top of your application widget tree.
This my code:
Doctor summary (to see all details, run flutter doctor -v): [✓] Flutter (Channel stable, 3.10.6, on macOS 13.4.1 22F770820d darwin-arm64, locale fr-CA) [✓] Android toolchain - develop for Android devices (Android SDK version 33.0.0) [✓] Xcode - develop for iOS and macOS (Xcode 14.3.1) [✓] Chrome - develop for the web [✓] Android Studio (version 2022.2) [✓] Android Studio (version 2022.1) [✓] VS Code (version 1.80.0) [✓] Connected device (3 available) [✓] Network resources
flutter_platform_widgets: ^3.3.5