Repository navigation
Description
Steps to reproduce
Run the sample code as a flutter web app (Chrome).
Turn on accessibility (VoiceOver) and enable accessibility by triggering the hidden accessibility button.
Using the control+option+arrow keys, navigate between the widgets on the screen.
Run the same app on android.
Turn on accessibility (TalkBack).
Tap on the widgets to select them or swipe to navigate between the widgets on the screen.
This is related to this PR that has been closed: #182789
Expected results
Chrome and android should behave the same.
When the user selects the +/- buttons, the screen reader should announce the current count.
The count Text widget should not be selectable/focusable by the screen reader.
Actual results
On Chrome and android, selecting the +/- buttons is updating and announcing the count as expected, but on Chrome, the count text is selectable by the screen reader and is announced when in focus. This should not happen.
Code sample
Code sample
import 'package:flutter/material.dart';
import 'package:flutter/semantics.dart';
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({super.key});
@override
Widget build(BuildContext context) {
return const MaterialApp(
debugShowCheckedModeBanner: false,
home: CounterPage(),
);
}
}
class CounterPage extends StatefulWidget {
const CounterPage({super.key});
@override
State<CounterPage> createState() => _CounterPageState();
}
class _CounterPageState extends State<CounterPage> {
int _counter = 0;
@override
Widget build(BuildContext context) {
return Scaffold(
body: Center(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Semantics(
liveRegion: true,
label: 'Counter: $_counter',
accessibilityFocusBlockType:
AccessibilityFocusBlockType.blockNode,
child: ExcludeSemantics(
child: Text(
'$_counter',
style: Theme.of(context).textTheme.displayLarge,
),
),
),
const SizedBox(height: 32),
Row(
mainAxisAlignment: MainAxisAlignment.center,
spacing: 16,
children: [
IconButton.filled(
onPressed: () => setState(() => _counter--),
icon: const Icon(Icons.remove),
tooltip: 'Decrement',
),
IconButton.filled(
onPressed: () => setState(() => _counter++),
icon: const Icon(Icons.add),
tooltip: 'Increment',
),
],
),
],
),
),
);
}
}
Screenshots or Video
Screenshots / Video demonstration
Screen.Recording.2026-08-21.at.10.50.50.AM.mov
Screen.Recording.2026-08-21.at.10.55.08.AM.mov
Logs
Logs
[Paste your logs here]Flutter Doctor output
Doctor output
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.47.0, on macOS 26.4.1 25E253 darwin-arm64, locale en-US)
[✓] Android toolchain - develop for Android devices (Android SDK version 36.1.0)
[!] Xcode - develop for iOS and macOS (Xcode 26.6)
! CocoaPods 1.15.2 out of date (1.16.2 is recommended).
CocoaPods is a package manager for iOS or macOS platform code.
Without CocoaPods, plugins will not work on iOS or macOS.
For more info, see https://flutter.dev/to/platform-plugins
To update CocoaPods, see https://guides.cocoapods.org/using/getting-started.html#updating-cocoapods
[✓] Chrome - develop for the web
Activity
mbcorona commentedon Aug 21, 2026
HI @marwfair, thanks for the detailed report and video evidence.
Routing to the accessibility team and flagging web, noted related #182789
mdebbar commentedon Aug 26, 2026
Idea: set
role="none"when a node is blocked withblockNode.Quick question: why are you using
blockNodewithExcludeSemanticson the same node? I'm trying to understand your use case better.hannah-hyj commentedon Aug 26, 2026
thought: To achieve blocking one node but not its children, maybe we should just not building the semantics dom node in web engine?
marwfair commentedon Sep 1, 2026
Good question.
ExcludeSemanticsmay not be needed. I just ran the example again on android and it seemed to work without out it.The use case here is that I want want be able to use a
liveRegionon the counter text so the updated count is announced when the +/- buttons are pressed, and I don't want theTextwidget to be selectable by the screen reader and announced when focused. In the example, it is announcing "Counter 1", but I could also change it to announce something like "Counter updated to 1", which could be confusing to the user if they just focused on the text and didn't actually update the quantity.[web] Preserve DOM focus on role update and honor isAccessibilityFocu…
github-actions commentedon Oct 16, 2026
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 -vand a minimal reproduction of the issue.[web] Preserve DOM focus on role update and honor isAccessibilityFocu…