Skip to content

Widgets inserted to an Overlay have different ancestral InheritedWidget(s) than commonly expected #36220

@LongCatIsLooong

Description

@LongCatIsLooong

This seems to be a very common source of bugs when using the Hero API:

and in the framework:

Workaround

As a temporary workaround, manually wrap whatever is missing inside the hero, or in its shuttleBuilder.
See: #30647 (comment)

additional context:
#6072 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1High-priority issues at the top of the work listcustomer: crowdAffects or could affect many people, though not necessarily a specific customer.f: routesNavigator, Router, and related APIs.frameworkflutter/packages/flutter repository. See also f: labels.team-frameworkOwned by Framework team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions