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
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
View file Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Fixed

- **[Web]** Remove unnecessary `KeyboardListener` that was causing an extra Tab stop in focus traversal, improving keyboard navigation efficiency.

## [11.4.2] - 2025εΉ΄07月22ζ—₯

### Fixed
Expand Down
18 changes: 1 addition & 17 deletions lib/src/editor/editor.dart
View file Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ class QuillEditorState extends State<QuillEditor>
),
);

final editor = selectionEnabled
return selectionEnabled
? _selectionGestureDetectorBuilder.build(
behavior: HitTestBehavior.translucent,
detectWordBoundary: config.detectWordBoundary,
Expand All @@ -339,22 +339,6 @@ class QuillEditorState extends State<QuillEditor>
quillMagnifierBuilder: config.quillMagnifierBuilder,
)
: child;

if (kIsWeb) {
// Intercept RawKeyEvent on Web to prevent it from propagating to parents
// that might interfere with the editor key behavior, such as
// SingleChildScrollView. Thanks to @wliumelb for the workaround.
// See issue https://github.com/singerdmx/flutter-quill/issues/304
return KeyboardListener(
onKeyEvent: (_) {},
focusNode: FocusNode(
onKeyEvent: (node, event) => KeyEventResult.skipRemainingHandlers,
),
child: editor,
);
}

return editor;
}

EmbedBuilder _getEmbedBuilder(Embed node) {
Expand Down
Loading

AltStyle γ«γ‚ˆγ£γ¦ε€‰ζ›γ•γ‚ŒγŸγƒšγƒΌγ‚Έ (->γ‚ͺγƒͺγ‚ΈγƒŠγƒ«) /