Skip to content

feat(integrations): dedicated Activity window per macOS HIG, flatten Settings pane#986

Merged
datlechin merged 5 commits intomainfrom
feat/integrations-activity-window
May 4, 2026
Merged

feat(integrations): dedicated Activity window per macOS HIG, flatten Settings pane#986
datlechin merged 5 commits intomainfrom
feat/integrations-activity-window

Conversation

@datlechin
Copy link
Copy Markdown
Member

Summary

Refactors the Integrations area to follow native macOS / Apple HIG: Settings is for preferences only; data viewers and live operational state get their own window.

Before: Settings > Integrations bundled three things into one fixed-size 720×500 pane via a nested segmented Picker:

  • preferences (port, auth, network)
  • 1,000-row activity log with search/filter/export
  • live "Connected Clients" list with disconnect actions
  • "Setup Instructions" DisclosureGroup with sub-Picker

This caused layout jitter on refresh (loading state shrank the content area inside the fixed-size Settings window) and violated HIG ("avoid using a Settings window to display information that's accessible elsewhere").

After:

  • New window Window > Integrations Activity — resizable NSWindow with NavigationSplitView sidebar (Activity Log / Connected Clients), unified toolbar, native .searchable, filter Menu, refresh, export. Frame autosaved across launches.
  • Settings > Integrations is now a flat Form with sections: Integrations · Server Configuration · Authentication · Network · two buttons (Connect a Client… / View Activity…). No more nested picker, no more sub-tabs.
  • "Connect a Client" is a sheet (segmented Picker for client + numbered steps + copyable code) instead of a DisclosureGroup buried in Settings.
  • Connected Clients list lives in the new window with its own Disconnect toolbar action and context menu.
  • Activity Log uses List with rich rows + status indicators + relative time + category badge + outcome badge. Refresh button shows a small spinner inline; the list stays visible during refresh (no jitter, no content flash).

Architecture / HIG notes

  • IntegrationsActivityWindowFactory follows the same pattern as WelcomeWindowFactory / ConnectionFormWindowFactory and uses applyAutosaveName(_:) from PR fix(windows): persist welcome, connection form, feedback window positions #985 for native frame autosave.
  • NavigationSplitView with sidebar is the modern macOS pattern (Console.app, Mail, Notes). Selection-driven via List(selection:) with tagged Labels.
  • Each pane owns its .toolbar { }; SwiftUI bridges items to the window's NSToolbar automatically. Toolbar items swap on sidebar selection.
  • .searchable(text:placement: .toolbar) provides the native macOS search field in the toolbar.
  • .navigationTitle / .navigationSubtitle set window title + subtitle natively; subtitle shows "Activity is retained for 90 days" or live "N connected" count.
  • Old MCPAuditLogView deleted; helpers (AuditEntry row formatting, time-range enum) re-homed into the new pane file as ActivityLogRow and ActivityTimeRange.

Test plan

  • App launches; Settings > Integrations renders only the flat Form (no segmented picker, no Activity Log tab). All existing toggles and TextFields still work.
  • Click "Connect a Client…" — sheet opens, segmented Picker switches between Claude Desktop / Claude Code / Cursor instructions. Copy buttons on snippets work. "Done" dismisses.
  • Click "View Activity…" — opens the new window. Same window opens via Window > Integrations Activity menu item. Both routes focus the existing window if already open.
  • Sidebar: switch between "Activity Log" and "Connected Clients". Toolbar items swap accordingly.
  • Activity Log: search field in toolbar filters live; filter Menu (Range / Category / Token) re-queries; "Clear Filters" appears when filters active and resets to defaults.
  • Activity Log refresh button shows a small spinner during reload; the list stays visible (no jitter, no flash to empty state).
  • Activity Log empty states: no entries yet (tray icon), no matching filter (line.3.horizontal.decrease.circle icon), no search match (system search empty state).
  • Activity Log right-click on a row: "Copy Details" copies a multi-line summary; "Copy Connection ID" appears when applicable.
  • Activity Log Export — opens NSSavePanel, writes valid CSV.
  • Connected Clients: shows clients while server is running; empty state when none. Disconnect via toolbar (when row selected) or context menu opens confirmation alert; confirming disconnects the client.
  • Window position and size are remembered across app relaunches (frame autosave with key IntegrationsActivityWindow).
  • No regressions in unrelated Settings tabs.

@chatgpt-codex-connector
Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@datlechin datlechin merged commit 7a840c0 into main May 4, 2026
2 checks passed
@datlechin datlechin deleted the feat/integrations-activity-window branch May 4, 2026 11:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant