Files
nucleic-remote-ios/NucleicRemote
abkslmandClaude Opus 4.8 fdad762d00 Nucleic: scope lavender accent to Nucleic Control projects only
Make the lavender/purple accent a signal that you are operating inside a
Nucleic Control project; every other project keeps the standard teal tint.

- AppPalette.make gains a 'controlled' flag. When true (and in standard
  color-vision mode) it swaps the teal accent for a cached, nightSoftened
  lavender (controlAccent); otherwise it returns the unchanged palette.
- RootView derives 'controlled' from store.contextProjectID ->
  Project.isNucleicControlled, so the tint follows the active project and
  reverts to teal on the home dashboard / non-control projects. Tracked
  through Observation, so it flips live as you navigate.
- Color-vision (deut/prot/trit) palettes keep their tuned accents; the
  swap only applies in standard mode.
- iOS NucleicRemote reverts to the standard teal: the remote has no
  Nucleic Control concept (the wire protocol doesn't carry it), so it
  can't distinguish controlled projects and stays teal everywhere.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
2026-06-17 19:33:05 -07:00
..

NucleicRemote (iPhone client)

The thin iOS remote client for Nucleic (PLAN milestone M4). It's a pure projection of the Mac host over LAN: monitor sessions, read transcripts/diffs, answer approvals, and send follow-up input — scope approve. No local git or CLI; the Mac is the single authority (see docs/UX_IOS.md and docs/SYNC_PROTOCOL.md).

Architecture

All wire/crypto logic is shared with the Mac via the NucleicProtocol SwiftPM library (this Xcode project links it as a local package at ../..):

  • Transport — NWFrameChannel (NWConnection) + LANDiscovery (Bonjour _nucleic._tcp).
  • Engine — NucleicProtocol.SyncClient runs the Noise handshake (XXpsk0 to pair, IK to reconnect), exchanges hello/welcome, and turns HostMsgs into a SyncClient.Event stream.
  • State — RemoteStore (ObservableObject) is the single on-device UI state, a pure projection of the host. Identity + pinned host live in IdentityStore (Keychain + UserDefaults).
  • UI — SwiftUI: SessionsView (attention-first list), SessionDetailView (transcript/diff + status-driven action area), ApprovalCardView (Face ID gate on high-risk), PairingScannerView (QR), SettingsView.

Build & run

# Resolves the local NucleicProtocol package automatically.
xcodebuild -project ios/NucleicRemote/NucleicRemote.xcodeproj \
  -scheme NucleicRemote \
  -destination 'platform=iOS Simulator,name=iPhone 17 Pro' build

Or open NucleicRemote.xcodeproj in Xcode and run. To pair, start the sync server on the Mac (Nucleic ▸ Settings ▸ Add iPhone shows the QR), then scan it. On a real device, both must be on the same Wi‑Fi.

Status

The full pair → list → subscribe → approve → reconnect path is implemented and the protocol/ server side is covered by tests in Tests/NucleicProtocolTests and Tests/NucleicCoreTests. Push notifications / Live Activity (UX_IOS §5.1/§5.3) are the M5 follow-up (needs the relay).