Skip to content

Updated tabs in settings with modern window scene - #388

Open
oliverames wants to merge 61 commits into
mattt:mainfrom
oliverames:feat/settings-redesign-v2
Open

oliverames wants to merge 61 commits into
mattt:mainfrom
oliverames:feat/settings-redesign-v2

Conversation

@oliverames

@oliverames oliverames commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

Stacked on #387 (the Setup Assistant), which is itself stacked on #374, #376, #377 and #381; merge those first; review the commits after 6452ddf. The earlier commits are the ones from those branches. They will drop out as the others merge.

This moves Settings out of the Settings scene into its own window, with five tabs above the Services list, and rebuilds the tabs around rows that share one icon size.

Why

The Settings pane list had grown to hold remote access, tokens, the phone link, client setup and the approval modes, and each had its own layout. Remote Access in particular showed every technical detail at once, whether or not it applied. The Settings scene also draws a gap above the content and puts the sidebar button inside the sidebar.

What changed

Window (App/Views/SettingsWindow.swift)

  • A plain window with a unified toolbar and a full-size content view, so the sidebar starts under the traffic lights and the sidebar button sits in the toolbar. The pane's name is the window title. It has a default size of 760 by 560, a minimum of 640 by 440, and remembers its frame through an autosave name.
  • Command-comma, the menu's Settings item and the Setup Assistant's Open Settings button open it. The Settings scene is removed.

Tabs (App/Models/SettingsCatalog.swift, App/Views/*SettingsView.swift)

  • General: Server, Show in menu bar, Launch at login, the approval mode with a one-line caption, Setup Assistant, Updates.
  • Clients: the AI apps iMCP knows (Claude Desktop, Claude Code, Claude Web, Claude Duet, Muse, Gemini) with their logos, setup or copy-address buttons and a connected state, the connector address, trusted apps, and connected cloud apps.
  • iPhone & iPad: paired devices, the routes with their on and off switches, how the phone connects, Approve on iPhone and activity history.
  • Remote Access: Tailscale and Cloudflare Tunnel as plain sections. Each shows the checklist from Reworked Setup Assistant with modern design and new flows for additional features, Remote Access checklists and Dock presence #387 and folds finished steps into one row.
  • Advanced: access tokens, Tailscale sign-in with an auth key, the phone's route details and client setup text, under a Developer section.
  • The Services list below the tabs and each service page are unchanged.
  • SettingsItem lists every control and the tab it lives in, and a test checks that no tab is empty and that each setting is in the tab a person would look in. A stored pane reopens to the same pane.

Rows (App/Views/SettingsComponents.swift, from #387)

  • Every row icon and app logo is 32 pt. Details sit in expandable rows with the arrow at the trailing edge.

Debug-only snapshot renderer (App/Debug/SettingsSnapshot.swift)

  • --snapshot-settings=<directory> draws every pane at the default and the minimum size to a PNG and exits. It is compiled only into Debug builds.

Two things in the integration version are not here because the stack does not have what they need: a Tailscale VPN port field in Advanced, and the call that re-applies remote access settings after a phone route changes.

Testing

  • swift format lint --strict -r . is clean.
  • Debug build of the iMCP scheme succeeds.
  • imcp-serverTests: 576 tests run, 1 skipped, 0 failures. New: SettingsCatalogTests.
  • This Settings window ran in my integration build, which is installed as a signed Release build on my Mac and used every day. I looked at the window, the sidebar, the tabs, the expandable rows and the Cloudflare section in the live app. Renders of every pane at the default and the minimum size, in light and dark, are the checks for layout; offscreen renders cannot show the sidebar list or the toolbar button.
  • On 2026-11-18 a read-only sweep of the tools from Claude Web, through the connector, passed on that build.
  • CI: see the checks on this PR.

Not verified

  • Drag to reorder in the Services list, the pairing sheet, collapsing the sidebar, and the window remembering its size.
  • The glass buttons on macOS 26 and later.
  • The Tailscale and Cloudflare API token flows, end to end.
  • The Setup Assistant on a clean install.
  • Approvals on a device.
  • This exact branch has not been installed. The live checks above were on the integration build, whose code this was copied from.
  • The Settings window and the old menu: the menu's Settings item now calls the new window, and Use plain-language system voice in folder-access alerts #382 replaces that menu, so one line will conflict when both merge.

Screenshots

These come from my integration build. Its bottom sidebar tab says "Developer & Advanced" in these captures, and is now "Advanced". The Files and Notes pages are the per-service pages, which this PR does not change.

General

Clients

iPhone & iPad

Files

Notes

mattt added 30 commits October 26, 2026 11:21
Clients on another device in the owner's tailnet can now use iMCP
while the Mac keeps the data, permissions, and tool settings.
iMCP listens on the Mac's tailnet address, accepts only untagged devices
that belong to the Mac's Tailscale user, and requires a named access token
on every request. Settings creates, edits, re-rolls, and deletes tokens,
and a token can never use a service or tool that is off in iMCP.
Remote sessions pass a pre-approved ConnectionApprovalGate, because a valid access token takes the place of the approval dialog. The remote access test file moves to Tests/imcp-serverTests with the other tests.
Link TailscaleKit 0.2.0-imcp.1 from mattt/libtailscale into the app target, which embeds it like Sparkle. The framework is arm64-only and requires macOS 15.6, so the app target now builds only for arm64 with a deployment target of 15.6, and the app no longer runs on Intel Macs. The CLI, the helper, and the tests don't link the framework and keep their settings.
A sandboxed iMCP can't run the Tailscale command-line tool, and a listener on the Mac's shared tailnet address can be taken over by another local process. iMCP now runs an embedded Tailscale node with its own identity and address, and listens only on that address.

The node keeps its state in the app's container and runs only while remote access is on. Settings shows the login link, the node's state, MagicDNS name, and tailnet address, and lets the owner log in with an auth key, rename the device, and log out.

For each connection, the server asks the node who the peer is, and accepts only untagged devices of the node's own user. Access tokens, their permissions, and their binding to one device stay the same. The HTTP server reads and writes TailscaleKit connections, and runs their blocking calls on their own threads.

The node is behind a small protocol, so the tests use a fake node to check authorization, Host and Origin validation, and the login states.
The README no longer asks for the Tailscale app on the Mac. It describes the login, auth keys, and logout, and says that WireGuard encrypts the plain HTTP traffic and that the node's address belongs only to iMCP. The download requirements now say macOS 15.6 on Apple silicon.
Link TailscaleKit 0.2.0-imcp.2 from mattt/libtailscale, which is universal (arm64 and x86_64) and requires macOS 15.1. The app target builds for the default architectures again, with a deployment target of macOS 15.1, as on main, and the README's download requirement is macOS 15.3 again. A later TailscaleKit release will drop the x86_64 slice.
TailscaleKit contains only a Swift interface that Swift 6.4 generated, so the app needs Xcode 27.1 or later. Of the GitHub-hosted images, only xcode-27 has Xcode 27.1; macos-26 stops at Xcode 26.6. CI now builds with Xcode 27.1 on xcode-27 and drops the Xcode 26.0 and 27.0 entries, which can't build the framework. The release workflow also moves from Xcode 26.0 on macos-26 to Xcode 27.1 on xcode-27.
…ailscalekit

# Conflicts:
#	App/Controllers/ServerController.swift
#	iMCP.xcodeproj/project.pbxproj
Define the Health, Finance, and Alarms tools once in Shared/Companion,
store what the iPhone sends in an encrypted SQLite cache,
and answer read-only calls from that cache with synced_at and stale.
Generalize HomeInput into ToolInput so both services validate arguments.
The iPhone app dials the Mac over TLS with pre-shared keys,
pairs with a one-time code from a QR code in Settings > Companion,
and serves the companion tools as an MCP server on that connection.
The Mac calls tools live when the phone is connected,
retries a lost read or an alarm change that carries its ID,
and pulls queued changes from the phone's outbox into its cache.
Scripts/install-companion.sh builds and installs the app with your team.
Answer the Health tools live from HealthKit,
let the user allow each group of types from the app,
and queue anchored changes for the Mac: daily statistics for quantity types
and full records for sleep, workouts, and health records.
When HealthKit is locked, the Mac answers reads from its cache.
Create one-time, weekly, and countdown alarms with the ID the Mac sends,
so a retried call returns the existing alarm instead of a second one.
A widget extension shows a running timer as a Live Activity with a stop button,
the app lists the alarms that AI apps created and cancels them,
and the phone sends its alarm list to the Mac whenever AlarmKit reports a change.
Answer the Finance tools live and queue account, balance, and transaction
changes for the Mac with FinanceKit history tokens.
A background delivery extension queues changes while the app isn't running.
The code stays inactive until a build carries the FinanceKit entitlement,
which Scripts/install-companion.sh --finance requests;
without it, the Finance tools say why they're unavailable.
Add Alarms, Finance, and Health to the README and its hero image,
describe how to install, pair, and use the companion,
add Scripts/check-companion.py for read-only checks through imcp-server,
and build the companion unsigned in CI.
When the iPhone drops a connection, disconnect the Mac's MCP client,
so pending calls fail over to the cache and syncing resumes on the next connection.
Keep lines that arrive before MCP reads them, end a closed channel's stream
with an error, and enforce read and open time limits.
Reject outbox writes from a sync that a cache reset overtook, run each
service's sync one at a time, and give the FinanceKit reason in cached answers.
The Mac used to send the device key inside the pairing session,
so anyone with the QR secret who recorded that session could recover it.
Now each side sends a one-time X25519 public key, both derive the device key
from the shared secret salted with the pairing key, and each side's proof
covers the public keys so neither can be swapped.
The iOS app is now iMCP on the device and builds for iPhone and iPad.
Targets, folders, and shared code use iOS and Mobile names,
the Mac's Settings pane is iPhone & iPad,
and the Bonjour type, pairing link, and status tool drop the companion name.
The name no longer collides with the separate Companion debugging app
that the README describes.
The macOS 26 runner's Xcode 26.0 has no iOS platform,
so the iOS app's build couldn't find a destination.
Download the platform when it's missing and allow time for the download.
AlarmKit shows its own stop control on the alarm alert,
so the app doesn't need an App Intent for it.
The timer Live Activity now shows the countdown without a stop button.
Oliver Ames added 21 commits November 18, 2026 13:46
Trusting a client used to mean copying a credential into its MCP settings.

iMCP now finds the app responsible for the connecting imcp-server, validates
its code signature, and shows that app's name, icon, and developer in the
approval window. Always Allow stores trust keyed to the app's designated
requirement, so there is nothing to copy.

Terminals and unsigned, ad hoc, or non-bundle clients are never trusted by
signature, since that would trust everything running inside them. For those,
imcp-server persists a credential at
~/Library/Application Support/iMCP/client-credential when
IMCP_CLIENT_CREDENTIAL is not set. Every client gets a single-step Allow Once
or Always Allow prompt on first connection. Settings lists trusted apps and
credentials with a Remove button.

The responsible-app lookup uses the private
responsibility_get_pid_responsible_for_pid symbol.
A reusable window shows the client, the recipient, and the full text, waits
50 seconds, shows one request at a time, and has no "always allow". It is for
tools that send something to another person. Also documents Allow writes and
adds the new files to the Xcode project.
Cloud apps such as claude.ai can't join a tailnet, so iMCP can now serve
its MCP endpoint at a public HTTPS address and authorize apps with OAuth 2.1.

- OAuth 2.1 authority and endpoints (RFC 9728 and RFC 8414 metadata, RFC 7591
  dynamic registration, Client ID Metadata Documents, PKCE S256, refresh token
  rotation), a native approval window bound to the starting browser, and a
  list of connected apps with revocation in Settings.
- Tailscale Funnel through the embedded node, with stricter request limits
  for public traffic and guidance for the missing funnel ACL capability.
- Cloudflare Tunnel: sign in, find the zone, create or reuse a named tunnel,
  set the ingress and DNS record, and supervise cloudflared.
- The tunnel restarts with backoff when cloudflared exits, reconnects after
  wake and when the network returns, and retries after a discovery or
  provisioning failure.
A setting in General chooses whether iMCP asks before every tool call, only
before writes, or leaves approval to the client. One gate in CallTool enforces
it, concurrent confirmations wait their turn, and the two hands-off modes skip
iMCP's own pop-ups and per-service Allow writes blocks without changing the
stored choices.
… crash

The Mac keeps a live link when the same device connects twice, and the phone
shares one in-flight dial and bounds pull to refresh to 8 seconds.
The Mac records each tool call in an activity history that syncs to the
phone, which shows it under Activity. Syncs run under a background task
assertion and the outbox moves out of the App Group container, which ended
the app with 0xdead10cc when it suspended holding a SQLite lock.
Adds the transport modes, an encrypted WebSocket channel, candidate dialing
with per-route and total time budgets, the Connection Mode screen on the
phone, and route settings in the Mac's iPhone & iPad pane.
The Mac numbers its route list with a revision, sends it in the welcome and
with config_apply when its settings change, and shows the revision each
phone has applied. The phone follows the Mac's route order.
The Mac offers each connection request to the paired phone as well as showing
its own dialog, and the first answer wins. Approving on the phone allows one
connection and never trusts the client. The Mac withdraws the request when it
answers, expires an unanswered one as a denial, and ignores answers from
devices that aren't paired. The phone lists waiting requests and can answer
from a notification after device authentication.
SettingsIcon, RowLabel, ExpandableRow and ClientLogo are the rows that the Setup Assistant uses, and that the Settings window will reuse. KnownClient matches an app by the name it reports and carries its logo.
…Tailscale public address access

The checklists turn the state of Tailscale and Cloudflare into the steps a person still has to take. A Cloudflare API token can be checked and used to sign in. A Tailscale API token lets iMCP ask the tailnet to allow public addresses.
…re open

The Setup Assistant walks through a welcome, the services, remote access, connecting an AI app, the iPhone and a finish screen. While Setup or another titled window is open, iMCP shows in the Dock. A Debug-only renderer draws each screen to a PNG.
SettingsPane names the five tabs above the Services list and stores the open pane. SettingsItem lists every control and the tab it lives in, so a setting cannot vanish when a tab is rearranged. The test checks that, and that a stored pane reopens.
… Remote Access and Advanced above the Services list

The window is a plain window with a unified toolbar, so the sidebar starts under the traffic lights. Rows share one 32 pt icon size, details fold into expandable rows with the arrow at the trailing edge, and Remote Access shows only the steps still to do. The per-service pages are unchanged. A Debug-only renderer draws every pane to a PNG.
@oliverames oliverames changed the title Move Settings to its own window with five tabs Updated tabs in settings with modern window with five tabs Nov 18, 2026
@oliverames oliverames changed the title Updated tabs in settings with modern window with five tabs Updated tabs in settings with modern window scene Nov 18, 2026
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.

2 participants