Skip to content

go_router should allow setting requestFocus on navigator. #129581

Closed
flutter/packages
#4636

Description

@jezell

Is there an existing issue for this?

Use case

We are building an app that redirects to keep a muliselect textbox in sync with the URL. This is like in iMessage where you can enter names in a to box and the feed is rendered below. GoRouter is stealing focus every time we redirect. Navigator has a requestFocus property which can be used to disable this, but there is no way too hook into the navigator creation in go_router.

Proposal

Add a requestFocus property to GoRouter which is passed to the Navigator constructor in _buildNavigator. We have verified by forking that setting this property to false solves the problem.

Activity

  1. added
    in triagePresently being triaged by the triage team
    c: new featureNothing broken; request for a new capability
    packageflutter/packages repository. See also p: labels.
    c: proposalA detailed proposal for a change to Flutter
    and removed
    in triagePresently being triaged by the triage team
    on Jun 27, 2023
  2. added
    P2Important issues not at the top of the work list
    on Jun 29, 2023
  3. github-actions commented on Aug 24, 2023

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  4. locked as resolved and limited conversation to collaborators on Aug 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

P2Important issues not at the top of the work listc: new featureNothing broken; request for a new capabilityc: proposalA detailed proposal for a change to Flutterp: go_routerThe go_router packagepackageflutter/packages repository. See also p: labels.r: fixedIssue is closed as already fixed in a newer version

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions