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.
TypeScript 3d-modelingagent-frameworkagent-harnessai-agentscadclaude-codecodexcoding-agentsdeveloper-toolsesp32game-developmentmcp-servermulti-agentopen-hardwareopencodeopenharnesspcbroboticsterminaltmux
Polish Harness entry buttons and align tab actions
dee804eb935afb2
diff --git a/desktop/assets/harness_device.webp b/desktop/assets/harness_device.webpindex ca142a0c0..1d21dfbbe 100644Binary files a/desktop/assets/harness_device.webp and b/desktop/assets/harness_device.webp differdiff --git a/desktop/lib/screens/swarm_screen.dart b/desktop/lib/screens/swarm_screen.dartindex 36556d24c..654a77333 100644--- a/desktop/lib/screens/swarm_screen.dart+++ b/desktop/lib/screens/swarm_screen.dart@@ -1499,6 +1499,7 @@ class _SwarmScreenState extends State<SwarmScreen> {),onPressed: create ? _newAgent : _addAgent,style: TextButton.styleFrom(+ enabledMouseCursor: SystemMouseCursors.click,minimumSize: Size(create ? 122 : 128, 34),padding: const EdgeInsets.symmetric(horizontal: 20),tapTargetSize: MaterialTapTargetSize.shrinkWrap,@@ -1506,11 +1507,12 @@ class _SwarmScreenState extends State<SwarmScreen> {?.copyWith(fontSize: 12, fontWeight: FontWeight.w500),backgroundColor: create? grid.AppPalette.swarmAccent- : grid.AppPalette.swarmSearchSurface,+ : Colors.transparent,foregroundColor: create? grid.AppPalette.swarmTabBar: grid.AppPalette.swarmAccent,shape: const StadiumBorder(),+ side: create ? BorderSide.none : const BorderSide(color: Colors.white24),),child: Text(label),);diff --git a/desktop/lib/shortcuts/app_shortcuts.dart b/desktop/lib/shortcuts/app_shortcuts.dartindex c67228c67..1440e12c4 100644--- a/desktop/lib/shortcuts/app_shortcuts.dart+++ b/desktop/lib/shortcuts/app_shortcuts.dart@@ -370,7 +370,7 @@ const kSwarmShortcuts = [AppShortcut(action: ShortcutAction.closeSwarm,activator: SingleActivator(LogicalKeyboardKey.keyW, meta: true),- label: 'Close Harness',+ label: 'Close Tab',group: ShortcutGroup.navigate,),AppShortcut(@@ -380,7 +380,7 @@ const kSwarmShortcuts = [meta: true,shift: true,),- label: 'Rename Harness',+ label: 'Rename Tab',group: ShortcutGroup.navigate,),AppShortcut(diff --git a/desktop/lib/shortcuts/keymap_commands.dart b/desktop/lib/shortcuts/keymap_commands.dartindex d12504ce7..3038781e0 100644--- a/desktop/lib/shortcuts/keymap_commands.dart+++ b/desktop/lib/shortcuts/keymap_commands.dart@@ -63,7 +63,7 @@ final harnessCommands = <HarnessCommand>[),const HarnessCommand('swarm.close',- 'Close Harness',+ 'Close Tab',ShortcutGroup.navigate,action: ShortcutAction.closeSwarm,nativeAction: 'closeActive',@@ -93,7 +93,7 @@ final harnessCommands = <HarnessCommand>[),const HarnessCommand('swarm.rename',- 'Rename Harness',+ 'Rename Tab',ShortcutGroup.actions,action: ShortcutAction.renameSwarm,nativeAction: 'renameActive',diff --git a/desktop/lib/widgets/harness_start_page.dart b/desktop/lib/widgets/harness_start_page.dartindex 023679be9..83c3d6370 100644--- a/desktop/lib/widgets/harness_start_page.dart+++ b/desktop/lib/widgets/harness_start_page.dart@@ -209,13 +209,13 @@ class _HarnessStartPageState extends State<HarnessStartPage> {key: const ValueKey('harness-start-open'),onPressed: _open,style: OutlinedButton.styleFrom(+ enabledMouseCursor: SystemMouseCursors.click,minimumSize: const Size(160, 44),+ padding: const EdgeInsets.symmetric(horizontal: 24),backgroundColor: Colors.transparent,foregroundColor: Colors.white,side: const BorderSide(color: Colors.white24),- shape: RoundedRectangleBorder(- borderRadius: BorderRadius.circular(8),- ),+ shape: const StadiumBorder(),),child: const Text('Open Harness'),),@@ -225,12 +225,12 @@ class _HarnessStartPageState extends State<HarnessStartPage> {icon: const Icon(Icons.add, size: 18),label: const Text('New Harness'),style: FilledButton.styleFrom(+ enabledMouseCursor: SystemMouseCursors.click,minimumSize: const Size(160, 44),+ padding: const EdgeInsets.symmetric(horizontal: 24),backgroundColor: grid.AppPalette.swarmAccent,foregroundColor: grid.AppPalette.swarmTabBar,- shape: RoundedRectangleBorder(- borderRadius: BorderRadius.circular(8),- ),+ shape: const StadiumBorder(),),),],@@ -240,6 +240,7 @@ class _HarnessStartPageState extends State<HarnessStartPage> {link: true,child: InkWell(key: const ValueKey('harness-device-link'),+ mouseCursor: SystemMouseCursors.click,onTap: () => launchUrl(Uri.parse('https://www.autonomous.ai/harness-device'),mode: LaunchMode.externalApplication,@@ -251,12 +252,18 @@ class _HarnessStartPageState extends State<HarnessStartPage> {children: [ClipRRect(borderRadius: BorderRadius.circular(10),- child: Image.asset(- 'assets/harness_device.webp',- width: 256,- height: 144,- fit: BoxFit.contain,- semanticLabel: 'Harness Device',+ child: Transform.scale(+ // Frame the device, which sits left of center+ // in the original photo, without altering it.+ scale: 1.7,+ alignment: const Alignment(-0.5, 0.08),+ child: Image.asset(+ 'assets/harness_device.webp',+ width: 256,+ height: 144,+ fit: BoxFit.cover,+ semanticLabel: 'Harness Device',+ ),),),const SizedBox(height: 16),diff --git a/desktop/lib/widgets/swarm_dialogs.dart b/desktop/lib/widgets/swarm_dialogs.dartindex 847a1d9ad..36b5e6149 100644--- a/desktop/lib/widgets/swarm_dialogs.dart+++ b/desktop/lib/widgets/swarm_dialogs.dart@@ -30,7 +30,7 @@ class _RenameSwarmDialogState extends State<_RenameSwarmDialog> {late final _text = TextEditingController(text: widget.name,)..selection = TextSelection(baseOffset: 0, extentOffset: widget.name.length);- final _focus = FocusNode(debugLabel: 'Rename Harness name');+ final _focus = FocusNode(debugLabel: 'Rename Tab name');@overridevoid initState() {@@ -51,7 +51,7 @@ class _RenameSwarmDialogState extends State<_RenameSwarmDialog> {@overrideWidget build(BuildContext context) => AlertDialog(- title: const Text('Rename Harness'),+ title: const Text('Rename Tab'),content: SizedBox(width: 360,child: TextField(diff --git a/desktop/macos/Runner/SwarmTitlebar.swift b/desktop/macos/Runner/SwarmTitlebar.swiftindex 258451e3e..9ddaae17a 100644--- a/desktop/macos/Runner/SwarmTitlebar.swift+++ b/desktop/macos/Runner/SwarmTitlebar.swift@@ -197,7 +197,7 @@ final class SwarmTitlebar: NSObject, NSMenuItemValidation, NSMenuDelegate {"new": "plus.square", "newAgent": "plus", "addAgent": "magnifyingglass","renameActive": "pencil", "closeActive": "xmark","splitRight": "rectangle.split.2x1", "splitDown": "rectangle.split.1x2",- "zoomPane": "arrow.up.left.and.arrow.down.right", "closePane": "xmark.square",+ "zoomPane": "viewfinder", "closePane": "xmark","commands": "command", "notifications": "bell",]if let symbol = symbols[action] {@@ -215,8 +215,8 @@ final class SwarmTitlebar: NSObject, NSMenuItemValidation, NSMenuDelegate {add(file, "New Tab", "t", "new")add(file, "New Harness…", "n", "newAgent")add(file, "Open Harness…", "o", "addAgent")- add(file, "Rename Harness…", "r", "renameActive", [.command, .shift])- add(file, "Close Harness", "w", "closeActive")+ add(file, "Rename Tab…", "r", "renameActive", [.command, .shift])+ add(file, "Close Tab", "w", "closeActive")file.addItem(.separator())add(file, "Split Right…", "r", "splitRight")add(file, "Split Down…", "d", "splitDown")@@ -727,11 +727,22 @@ private final class SwarmNotificationButton: NSButton {/// its own label color in active/inactive windows, ignoring contentTintColor.private final class SwarmActionButton: NSButton {var fillColor = NSColor.clear { didSet { needsDisplay = true } }+ var borderColor: NSColor? { didSet { needsDisplay = true } }var labelColor = NSColor.labelColor { didSet { needsDisplay = true } }private var hovered = false- override var isEnabled: Bool { didSet { needsDisplay = true } }+ override var isEnabled: Bool {+ didSet {+ needsDisplay = true+ window?.invalidateCursorRects(for: self)+ }+ }override var mouseDownCanMoveWindow: Bool { false }+ override func resetCursorRects() {+ super.resetCursorRects()+ if isEnabled { addCursorRect(bounds, cursor: .pointingHand) }+ }+override func updateTrackingAreas() {super.updateTrackingAreas()trackingAreas.forEach(removeTrackingArea)@@ -743,11 +754,20 @@ private final class SwarmActionButton: NSButton {override func draw(_ dirtyRect: NSRect) {let opacity: CGFloat = isEnabled ? 1 : 0.35- let fill = isEnabled && (hovered || isHighlighted)- ? fillColor.blended(withFraction: isHighlighted ? 0.16 : 0.08, of: labelColor) ?? fillColor- : fillColor- fill.withAlphaComponent(opacity).setFill()+ let emphasis: CGFloat = isHighlighted ? 0.16 : 0.08+ let hoverFill = fillColor.alphaComponent == 0+ ? labelColor.withAlphaComponent(emphasis)+ : fillColor.blended(withFraction: emphasis, of: labelColor) ?? fillColor+ let fill = isEnabled && (hovered || isHighlighted) ? hoverFill : fillColor+ fill.withAlphaComponent(fill.alphaComponent * opacity).setFill()NSBezierPath(roundedRect: bounds, xRadius: bounds.height / 2, yRadius: bounds.height / 2).fill()+ if let borderColor {+ borderColor.withAlphaComponent(borderColor.alphaComponent * opacity).setStroke()+ let border = NSBezierPath(roundedRect: bounds.insetBy(dx: 0.5, dy: 0.5),+ xRadius: (bounds.height - 1) / 2, yRadius: (bounds.height - 1) / 2)+ border.lineWidth = 1+ border.stroke()+ }let label = NSAttributedString(string: title, attributes: [.font: font ?? NSFont.systemFont(ofSize: 12, weight: .medium),.foregroundColor: labelColor.withAlphaComponent(opacity),@@ -833,7 +853,8 @@ private final class SwarmTabStrip: NSView {private func updateActionColors() {createButton.fillColor = palette.accentcreateButton.labelColor = palette.tabBar- openButton.fillColor = palette.search+ openButton.fillColor = .clear+ openButton.borderColor = NSColor.white.withAlphaComponent(0.24)openButton.labelColor = palette.accent}@@ -1042,7 +1063,7 @@ private final class SwarmTabButton: NSView, NSDraggingSource, NSMenuItemValidatiselectButton.target = selfselectButton.action = #selector(selectSwarm)addSubview(selectButton)- closeButton.image = NSImage(systemSymbolName: "xmark", accessibilityDescription: "Close Harness")+ closeButton.image = NSImage(systemSymbolName: "xmark", accessibilityDescription: "Close Tab")closeButton.symbolConfiguration = NSImage.SymbolConfiguration(pointSize: 10, weight: .semibold)closeButton.contentTintColor = NSColor(white: 0.78, alpha: 1)closeButton.isBordered = false@@ -1050,7 +1071,7 @@ private final class SwarmTabButton: NSView, NSDraggingSource, NSMenuItemValidaticloseButton.action = #selector(closeSwarm)addSubview(closeButton)let menu = NSMenu()- for (title, action) in [("Rename Harness…", #selector(renameSwarm)), ("Close Harness", #selector(closeSwarm))] {+ for (title, action) in [("Rename Tab…", #selector(renameSwarm)), ("Close Tab", #selector(closeSwarm))] {let item = NSMenuItem(title: title, action: action, keyEquivalent: "")item.target = selfmenu.addItem(item)diff --git a/desktop/test/swarm_interactions_test.dart b/desktop/test/swarm_interactions_test.dartindex 60ab24b64..cabad798f 100644--- a/desktop/test/swarm_interactions_test.dart+++ b/desktop/test/swarm_interactions_test.dart@@ -262,7 +262,7 @@ void main() {expect(input.single.streamId, 'stream-a1');expect(String.fromCharCodes(input.single.bytes), 'x');await activate('rename', {'id': second});- expect(find.text('Rename Harness'), findsOneWidget);+ expect(find.text('Rename Tab'), findsOneWidget);final name = tester.widget<TextField>(find.byType(TextField));expect(name.focusNode!.hasPrimaryFocus, isTrue);tester.testTextInput.enterText('Keyboard work');diff --git a/desktop/tool/swarm_titlebar_checks.swift b/desktop/tool/swarm_titlebar_checks.swiftindex 53a0ee46c..962bdf61a 100644--- a/desktop/tool/swarm_titlebar_checks.swift+++ b/desktop/tool/swarm_titlebar_checks.swift@@ -505,8 +505,8 @@ private extension SwarmTitlebar {try checkTitlebar(agent.items.map { $0.isSeparatorItem ? "separator" : ($0.representedObject as? String ?? "") } == ["new", "newAgent", "addAgent", "renameActive", "closeActive", "separator", "splitRight", "splitDown", "zoomPane", "closePane"], "File groups Harness and Pane actions, without Pin or Add Project clutter")try checkTitlebar(agent.items.filter { !$0.isSeparatorItem }.allSatisfy { $0.image != nil && $0.toolTip == nil },"Every File action has a native icon and no hover hint")- try checkTitlebar(agent.items.contains { $0.title == "Rename Harness…" && $0.representedObject as? String == "renameActive" }, "Rename Harness preserves its command")- try checkTitlebar(agent.items.contains { $0.title == "Close Harness" && $0.representedObject as? String == "closeActive" }, "Close Harness preserves its command")+ try checkTitlebar(agent.items.contains { $0.title == "Rename Tab…" && $0.representedObject as? String == "renameActive" }, "Rename Tab preserves its command")+ try checkTitlebar(agent.items.contains { $0.title == "Close Tab" && $0.representedObject as? String == "closeActive" }, "Close Tab preserves its command")let commands = edit.submenu!.items.first(where: { $0.representedObject as? String == "commands" })!try checkTitlebar(commands.keyEquivalent == "p" && commands.keyEquivalentModifierMask == [.command, .shift], "Command search keeps its native menu owner")try checkTitlebar(edit.submenu!.items.allSatisfy { $0.representedObject as? String != "jump" }, "Edit has no Navigate action")diff --git a/docs/harness-agent-first-tabs.md b/docs/harness-agent-first-tabs.mdindex e64ee2de8..3d99b8df7 100644--- a/docs/harness-agent-first-tabs.md+++ b/docs/harness-agent-first-tabs.md@@ -24,10 +24,12 @@ Opening the dropdown keeps its whole list viewport inside the window. Resizingor changing text size reveals the highlighted row without changing the selection.A small product image and introduction sit well below the controls and link tohttps://www.autonomous.ai/harness-device. The bundled image is the official-device image from https://cdn.autonomous.ai/production/ecm/260731/1-2.webp,-as shown on https://www.autonomous.ai/harness. The short introduction is+device image from https://cdn.autonomous.ai/production/ecm/260731/2.webp,+cropped in the viewport so the device is larger and centered. The short introduction is“The ultimate Harness setup” / “Scroll, switch panes, and give voice commands.”-The start-page Open Harness button is transparent with a subtle border; New+The start-page actions use the same pill shape as the titlebar. The device link+and both pairs of New/Open buttons show a hand cursor. Open Harness on the start+page is transparent with a subtle border; NewHarness retains its accent fill.Unused default-name empty pages are excluded from Recently Closed.@@ -39,7 +41,7 @@ no Back to Search button in creation, and no stacked dialog on dismissal.The titlebar actions are 34-point-high pills with generous horizontal padding,12 points between them and at the right edge. AppKit uses one unified toolbarrow; the Flutter titlebar is 52 points high and uses the same accent/secondary-treatment and app font. Titlebar and native menu hover hints are+treatment and app font. Open Harness has a transparent fill and subtle border on both surfaces. Titlebar and native menu hover hints areremoved. Accessible names remain, and menus and Keyboard Shortcuts show bindings.The creation dialog title and CTA are **New Harness**. Cancel is removed; Escapeand clicking outside dismiss it. Launch-in-progress and uncertain-outcome states@@ -88,9 +90,10 @@ agent disappears from discovery. Tab names remain editable. Former default namesthe first agent's name when opened.The macOS menus are **Harness, File, Edit, View, History, Models, Machines,-Window, Help**. File groups **New Tab, New Harness, Open Harness, Rename Harness, Close Harness**;+Window, Help**. File groups **New Tab, New Harness, Open Harness, Rename Tab, Close Tab**;then **Split Right, Split Down, Zoom Pane, Close Pane**. Pin/Unpin and Add Project-are removed from this menu. File actions have native system icons. Machines starts with **Open Machines Manager**, then+are removed from this menu. File actions have native system icons, with the same+four-corner Zoom and plain Close cross as the pane header. Machines starts with **Open Machines Manager**, thenlinked computers with their status, followed by Link Machine and Refresh Machines.The manager has a visible **Rename** action on each computer and uses the existingmachine rename API. It reports failures inline and refreshes names in the menu