Skip to content

The ultimate harness for coding agents and beyond. All your agents. All your machines. One command center. Start with code, then follow your curiosity and build across disciplines: CAD, circuits, robots, games and music.

Merge batch 11-03 bw: #2731 (#2749)

0xken15cf9aafd88657
diff --git a/desktop/lib/super_tabs/view.dart b/desktop/lib/super_tabs/view.dart
index 6714cdf32..33a8f7b55 100644
--- a/desktop/lib/super_tabs/view.dart
+++ b/desktop/lib/super_tabs/view.dart
@@ -2631,16 +2631,15 @@ class _SuperTabViewState extends State<SuperTabView>
);
/// The reader's own setting for a chat, kept on every device (Slack's channel
- /// notifications); a viewer has one too.
- Widget _notifyMenu(SuperTabConversation group, {bool asRow = false}) =>
+ /// notifications); a viewer has one too. A row like its menu's others, as
+ /// tall as their [finger] rows (Huy, #2342: the chat menu's had a border).
+ Widget _notifyMenu(SuperTabConversation group, {required bool finger}) =>
SubmenuButton(
key: const ValueKey('super-notify-menu'),
- style: asRow ? _menuRowStyle(finger: _phone) : null,
- submenuIcon: asRow
- ? const WidgetStatePropertyAll(
- Icon(AppIcons.chevronRight, size: 14),
- )
- : null,
+ style: _menuRowStyle(finger: finger),
+ submenuIcon: const WidgetStatePropertyAll(
+ Icon(AppIcons.chevronRight, size: 14),
+ ),
menuChildren: [
for (final (level, label) in const [
(SuperTabNotify.all, 'All new messages'),
@@ -2649,6 +2648,7 @@ class _SuperTabViewState extends State<SuperTabView>
])
MenuItemButton(
key: ValueKey('super-notify-${level.name}'),
+ style: _menuRowStyle(finger: finger),
leadingIcon: SizedBox(
width: 16,
child: c.notifyOf(group.id) == level
@@ -2703,7 +2703,7 @@ class _SuperTabViewState extends State<SuperTabView>
item('Instructions', () => _groupAction('instructions', group)),
if (editable && owner)
item('Sharing', () => _groupAction('sharing', group)),
- _notifyMenu(group, asRow: true),
+ _notifyMenu(group, finger: _phone),
const Divider(height: 9),
item(
'Project settings…',
@@ -2825,7 +2825,7 @@ class _SuperTabViewState extends State<SuperTabView>
),
],
],
- _notifyMenu(group),
+ _notifyMenu(group, finger: views),
if (_mayHaveArchived(group.projectId))
item('Archived conversations', () => _groupAction('archived', group)),
],
diff --git a/desktop/test/super_tab_attention_wave2_test.dart b/desktop/test/super_tab_attention_wave2_test.dart
index faf35c71a..0e4bc2bbc 100644
--- a/desktop/test/super_tab_attention_wave2_test.dart
+++ b/desktop/test/super_tab_attention_wave2_test.dart
@@ -1,8 +1,10 @@
import 'dart:io';
+import 'package:flutter/gestures.dart';
import 'package:flutter/material.dart';
import 'package:flutter/rendering.dart';
import 'package:flutter_test/flutter_test.dart';
+import 'package:harness/shared/theme/app_icons.dart';
import 'package:harness/shared/theme/app_theme.dart' as grid;
import 'package:flutter/services.dart';
import 'package:harness/super_tabs/attention.dart';
@@ -379,6 +381,76 @@ void main() {
},
variant: TargetPlatformVariant.only(TargetPlatform.macOS),
);
+
+ // Huy, #2342: in a chat's ⋮ menu the Notifications row had a rounded
+ // border no other row has. It draws as the row above it does, at rest and
+ // under the mouse, and keeps its submenu arrow, in each menu it is in.
+ for (final (menu, selected, neighbour) in const [
+ ('super-group-options', 'offline', 'Work details'),
+ ('super-project-menu', 'lead', 'Pull requests'),
+ ]) {
+ testWidgets('$menu: the Notifications row looks like $neighbour', (
+ tester,
+ ) async {
+ final (c, _) = await _show(tester, Brightness.dark, selected: selected);
+ await tester.tap(find.byKey(ValueKey(menu)));
+ await tester.pumpAndSettle();
+ // The PR's pictures: the menu is a route of its own.
+ if (shotsOn) await captureWindow(tester, shots, 'notify-row-$menu');
+ final notify = find.byKey(const ValueKey('super-notify-menu'));
+ final other = find
+ .ancestor(
+ of: find.text(neighbour),
+ matching: find.byType(MenuItemButton),
+ )
+ .first;
+ Material material(Finder row) => tester.widget<Material>(
+ find.descendant(of: row, matching: find.byType(Material)).first,
+ );
+ InkWell ink(Finder row) => tester.widget<InkWell>(
+ find.descendant(of: row, matching: find.byType(InkWell)).first,
+ );
+ double inset(Finder row, String label) =>
+ tester.getTopLeft(find.text(label)).dx - tester.getTopLeft(row).dx;
+
+ expect(material(notify).shape, material(other).shape);
+ expect(material(notify).color, material(other).color);
+ expect(tester.getSize(notify), tester.getSize(other));
+ expect(inset(notify, 'Notifications'), inset(other, neighbour));
+ expect(
+ find.descendant(
+ of: notify,
+ matching: find.byIcon(AppIcons.chevronRight),
+ ),
+ findsOneWidget,
+ );
+ const hovered = {WidgetState.hovered};
+ expect(
+ ink(notify).overlayColor?.resolve(hovered),
+ ink(other).overlayColor?.resolve(hovered),
+ );
+ final mouse = await tester.createGesture(kind: PointerDeviceKind.mouse);
+ await mouse.addPointer(location: tester.getCenter(other));
+ await tester.pump();
+ final otherHovered = material(other).shape;
+ await mouse.moveTo(tester.getCenter(notify));
+ await tester.pump();
+ if (shotsOn) {
+ await tester.pumpAndSettle();
+ await captureWindow(tester, shots, 'notify-row-$menu-hover');
+ }
+ expect(material(notify).shape, otherHovered);
+ // Its submenu's rows are rows of the same kind (they had the border too).
+ await tester.pumpAndSettle();
+ for (final level in SuperTabNotify.values) {
+ final row = find.byKey(ValueKey('super-notify-${level.name}'));
+ expect(material(row).shape, material(other).shape);
+ expect(tester.getSize(row).height, tester.getSize(other).height);
+ }
+ await mouse.removePointer();
+ await _done(tester, c);
+ }, variant: TargetPlatformVariant.only(TargetPlatform.macOS));
+ }
});
for (final brightness in Brightness.values) {
diff --git a/docs/plans/assets/2026-11-03-notify-row/after-chat-menu-notifications-open.png b/docs/plans/assets/2026-11-03-notify-row/after-chat-menu-notifications-open.png
new file mode 100644
index 000000000..aee5fd664
Binary files /dev/null and b/docs/plans/assets/2026-11-03-notify-row/after-chat-menu-notifications-open.png differ
diff --git a/docs/plans/assets/2026-11-03-notify-row/after-chat-menu.png b/docs/plans/assets/2026-11-03-notify-row/after-chat-menu.png
new file mode 100644
index 000000000..08656168c
Binary files /dev/null and b/docs/plans/assets/2026-11-03-notify-row/after-chat-menu.png differ
diff --git a/docs/plans/assets/2026-11-03-notify-row/after-project-menu.png b/docs/plans/assets/2026-11-03-notify-row/after-project-menu.png
new file mode 100644
index 000000000..910facb91
Binary files /dev/null and b/docs/plans/assets/2026-11-03-notify-row/after-project-menu.png differ
diff --git a/docs/plans/assets/2026-11-03-notify-row/before-chat-menu.png b/docs/plans/assets/2026-11-03-notify-row/before-chat-menu.png
new file mode 100644
index 000000000..53b94d139
Binary files /dev/null and b/docs/plans/assets/2026-11-03-notify-row/before-chat-menu.png differ