Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

fix(web): Remove KeyboardListener causing extra Tab stop in focus traversal #2648

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

Open
Ladegeraet wants to merge 2 commits into singerdmx:master
base: master
Choose a base branch
Loading
from Ladegeraet:bug/web_focus_traversal

Conversation

Copy link

@Ladegeraet Ladegeraet commented Sep 2, 2025

Description

This PR removes the web-specific KeyboardListener that was causing inefficient Tab navigation focus on Flutter Web.

Current behavior: On Flutter Web, users need an extra Tab press to reach the Quill editor because a KeyboardListener with a FocusNode creates an additional focus stop in the tab order, making keyboard navigation inefficient.

New behavior: Tab navigation works efficiently across all platforms, allowing users to focus the editor directly without unnecessary extra tab stops.

Motivation: The original KeyboardListener was added as a workaround for issue #304 to prevent key event interference with parent widgets like SingleChildScrollView. However, the original issue could not be reproduced in current Flutter/Quill versions, while the workaround was creating an unnecessary focus traversal step. This change prioritizes efficient keyboard navigation and code simplification.

Alternative solution: If the original issue #304 resurfaces, an alternative approach would be to add skipTraversal: true to the FocusNode instead of removing the entire KeyboardListener.

Type of Change

  • Feature: New functionality without breaking existing features.
  • 🛠️ Bug fix: Resolves an issue without altering current behavior.
  • 🧹 Refactor: Code reorganization, no behavior change.
  • Breaking: Alters existing functionality and requires updates.
  • 🧪 Tests: New or modified tests
  • 📝 Documentation: Updates or additions to documentation.
  • 🗑️ Chore: Routine tasks, or maintenance.
  • Build configuration change: Build/configuration changes.

Knupper, mmattes-vetz, and mmattes reacted with thumbs up emoji Brainyoo reacted with rocket emoji
The web-specific KeyboardListener was creating an unnecessary focus node
that required users to press Tab one extra time to reach the editor.
This change improves keyboard navigation efficiency by removing the
workaround that is no longer needed.
@Ladegeraet Ladegeraet marked this pull request as ready for review September 2, 2025 11:16
Removes unnecessary variable assignment.
Simplifies the conditional return statement within the editor widget for improved readability and efficiency.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

1 participant

AltStyle によって変換されたページ (->オリジナル) /