diff --git a/lib/app/views/app_page.dart b/lib/app/views/app_page.dart index a8c33e00..fed94f73 100755 --- a/lib/app/views/app_page.dart +++ b/lib/app/views/app_page.dart @@ -504,6 +504,12 @@ class _AppPageState extends ConsumerState { widget.detailViewBuilder != null || widget.keyActionsBuilder != null; var body = _buildMainContent(context, hasManage); + var navigationText = showNavigation + ? (fullyExpanded + ? l10n.s_collapse_navigation + : MaterialLocalizations.of(context).openAppDrawerTooltip) + : l10n.s_expand_navigation; + if (widget.onFileDropped != null) { body = FileDropTarget( onFileDropped: widget.onFileDropped!, @@ -631,13 +637,8 @@ class _AppPageState extends ConsumerState { child: Padding( padding: const EdgeInsets.symmetric(horizontal: 8), child: IconButton( - icon: const Icon(Symbols.menu), - tooltip: showNavigation - ? (fullyExpanded - ? l10n.s_collapse_navigation - : MaterialLocalizations.of(context) - .openAppDrawerTooltip) - : l10n.s_expand_navigation, + icon: Icon(Symbols.menu, semanticLabel: navigationText), + tooltip: navigationText, onPressed: fullyExpanded ? () { ref @@ -681,10 +682,12 @@ class _AppPageState extends ConsumerState { ); }, icon: widget.keyActionsBadge - ? const Badge( - child: Icon(Symbols.more_vert), + ? Badge( + child: Icon(Symbols.more_vert, + semanticLabel: l10n.s_configure_yk), ) - : const Icon(Symbols.more_vert), + : Icon(Symbols.more_vert, + semanticLabel: l10n.s_configure_yk), iconSize: 24, tooltip: l10n.s_configure_yk, padding: const EdgeInsets.all(12), diff --git a/lib/app/views/device_picker.dart b/lib/app/views/device_picker.dart index c6a7692f..b8b028ec 100644 --- a/lib/app/views/device_picker.dart +++ b/lib/app/views/device_picker.dart @@ -285,8 +285,11 @@ class _DeviceRowState extends ConsumerState<_DeviceRow> { overflow: TextOverflow.fade, softWrap: false, ), - subtitle: Text(widget.subtitle, - overflow: TextOverflow.fade, softWrap: false), + subtitle: Text( + widget.subtitle, + overflow: TextOverflow.fade, + softWrap: false, + ), dense: true, onTap: widget.onTap, ), @@ -314,19 +317,23 @@ class _DeviceRowState extends ConsumerState<_DeviceRow> { child: Padding( padding: const EdgeInsets.symmetric(vertical: 6.5), child: widget.selected - ? IconButton.filled( - tooltip: isDesktop ? tooltip : null, - icon: widget.leading, - padding: const EdgeInsets.symmetric(horizontal: 8), - onPressed: widget.onTap, - ) - : IconButton( - tooltip: isDesktop ? tooltip : null, - icon: widget.leading, - padding: const EdgeInsets.symmetric(horizontal: 8), - onPressed: widget.onTap, - color: colorScheme.secondary, - ), + ? Semantics( + label: tooltip, + child: IconButton.filled( + tooltip: isDesktop ? tooltip : null, + icon: widget.leading, + padding: const EdgeInsets.symmetric(horizontal: 8), + onPressed: widget.onTap, + )) + : Semantics( + label: tooltip, + child: IconButton( + tooltip: isDesktop ? tooltip : null, + icon: widget.leading, + padding: const EdgeInsets.symmetric(horizontal: 8), + onPressed: widget.onTap, + color: colorScheme.secondary, + )), ), ); } diff --git a/lib/app/views/navigation.dart b/lib/app/views/navigation.dart index cd2c953d..7f0d5f32 100644 --- a/lib/app/views/navigation.dart +++ b/lib/app/views/navigation.dart @@ -145,8 +145,12 @@ class NavigationContent extends ConsumerWidget { ...availableSections.map((app) => NavigationItem( key: app._key, title: app.getDisplayName(l10n), - leading: Icon(app._icon, - fill: app == currentSection ? 1.0 : 0.0), + leading: Icon( + app._icon, + fill: app == currentSection ? 1.0 : 0.0, + semanticLabel: + !extended ? app.getDisplayName(l10n) : null, + ), collapsed: !extended, selected: app == currentSection, onTap: data == null && currentSection == Section.home ||