Open source Grok Bot alternative, Bring your own agent and subscription: message Claude Code, Codex, Gemini CLI, Cursor, Copilot and 40+ AI agents as bots on your own computer, from iPhone, Mac, Windows, Linux or terminal. Agent-agnostic and free. Also a Muse and Dots alternative. Built in Rust.
Rust acpagent-client-protocolai-agentsai-assistantclaudeclaude-codecodexcoding-agentscursorgeminigemini-cligrok-bot-alternativeiosiphonelinuxmacosmcpopen-sourcerustself-hosted
feat(ios): use the system tab bar
leepokaia095d7d9654e
diff --git a/AGENTS.md b/AGENTS.mdindex f1f93565..e754b068 100644--- a/AGENTS.md+++ b/AGENTS.md@@ -41,7 +41,7 @@ Use four-space indentation for Swift and Rust, two spaces for TypeScript. FollowName Swift files after their main `UpperCamelCase` type; use `snake_case.rs` and `kebab-case.ts`. Follow role suffixes such as `View`, `Row`, and `Store`. See `docs/architecture/file-structure.md` and `CLAUDE.md` for architectural conventions.-- UI controls default to the shared custom components. Explicit exception: iOS BotListView and ThreadView use native navigation/toolbar items and automatic back navigation for system Liquid Glass, as specified in `docs/design/ui-conventions.md`. The desktop app's menu bar/tray menu is the system menu. Keep system authentication and widget containers native. On iOS `.codyncSheet` presents the system sheet (grabber, swipe down). Outside these exceptions, avoid: no `Menu`/`Picker`, `.switch` toggles, `Form`/`List` styling, `confirmationDialog`/`alert`, `ProgressView`, `.sheet`/`.popover`/`.fullScreenCover`, `.toolbar`/navigation bars, `TabView`, `ContentUnavailableView`. Use `apps/ios/Kit/Sources/CodyncUI/Controls.swift` + `Chrome.swift` (`.codyncSheet`, `ModalHeader`, `ScreenHeader`, `TabBar`, `.codyncDialog`, `ToggleStyle.codync`); on the desktop, `apps/desktop/src/renderer/components/` (`Sheet`, `Dialog`, `AnchoredMenu`, `ModalHeader`, `Controls.tsx`, `Icon` for SF Symbols). Every tap that shows/hides something animates (`Motion`). Anything with a background fill gets no border line.+- UI controls default to the shared custom components. Explicit exception: iOS BotListView and ThreadView use native navigation/toolbar items and automatic back navigation, and the iPhone root uses the system `TabView`, for system Liquid Glass, as specified in `docs/design/ui-conventions.md`. The desktop app's menu bar/tray menu is the system menu. Keep system authentication and widget containers native. On iOS `.codyncSheet` presents the system sheet (grabber, swipe down). Outside these exceptions, avoid: no `Menu`/`Picker`, `.switch` toggles, `Form`/`List` styling, `confirmationDialog`/`alert`, `ProgressView`, `.sheet`/`.popover`/`.fullScreenCover`, `.toolbar`/navigation bars, `ContentUnavailableView`. Use `apps/ios/Kit/Sources/CodyncUI/Controls.swift` + `Chrome.swift` (`.codyncSheet`, `ModalHeader`, `ScreenHeader`, `.codyncDialog`, `ToggleStyle.codync`); on the desktop, `apps/desktop/src/renderer/components/` (`Sheet`, `Dialog`, `AnchoredMenu`, `ModalHeader`, `Controls.tsx`, `Icon` for SF Symbols). Every tap that shows/hides something animates (`Motion`). Anything with a background fill gets no border line.## Clean codediff --git a/CLAUDE.md b/CLAUDE.mdindex 4655bb00..fa8c8f08 100644--- a/CLAUDE.md+++ b/CLAUDE.md@@ -22,7 +22,7 @@ Bot-based remote for coding agents: persistent named bots on your computer, mess- Clients: iOS app (SwiftUI), desktop app for macOS, Linux and Windows (`apps/desktop/`, Electron: menu bar/tray + chat window; why and how: [docs/architecture/desktop-app.md](docs/architecture/desktop-app.md)), terminal UI (`codync-host tui`, `host/src/tui/`, ratatui; layout and state vocabulary modeled on herdr). All talk to the host API.- iPhone Swift package (`apps/ios/Kit/`, iOS only): `CodyncKit` (models, client, theme, avatars; also used by the widgets and the notification extension) + `CodyncUI` (`BotStore` + screens).- UI principle: buttons an icon can express are icon-only (with tooltip / accessibility label); text only where an icon would be ambiguous (approval choices).-- UI controls default to the shared custom components. Explicit exception: iOS BotListView and ThreadView use native navigation/toolbar items and automatic back navigation for system Liquid Glass, as specified in `docs/design/ui-conventions.md`. **iOS menus are always the system ones**: tap menus through `DropdownMenu`/`ChoicePicker` (native `Menu`), long-press through `.contextActions` (native `contextMenu`). Never hand-build a dropdown on iOS: a custom overlay lands in the wrong place (sheets, scroll views, the composer's + menu). The desktop app's menu bar/tray menu is the system menu. Keep system authentication and widget containers native. On iOS `.codyncSheet` presents the system sheet (grabber, swipe down). Outside these exceptions, avoid: no `Menu`/`Picker`, `.switch` toggles, `Form`/`List` styling, `confirmationDialog`/`alert`, `ProgressView`, `.sheet`/`.popover`/`.fullScreenCover`, `.toolbar`/navigation bars, `TabView`, `ContentUnavailableView`. Use `apps/ios/Kit/Sources/CodyncUI/Controls.swift` + `Chrome.swift` (`.codyncSheet`, `ModalHeader`, `ScreenHeader`, `TabBar`, `.codyncDialog`, `ToggleStyle.codync`); on the desktop, `apps/desktop/src/renderer/components/` (`Sheet`, `Dialog`, `AnchoredMenu`, `ModalHeader`, `Controls.tsx`, `Icon` for SF Symbols). Every tap that shows/hides something animates (`Motion`). Anything with a background fill gets no border line.+- UI controls default to the shared custom components. Explicit exception: iOS BotListView and ThreadView use native navigation/toolbar items and automatic back navigation, and the iPhone root uses the system `TabView`, for system Liquid Glass, as specified in `docs/design/ui-conventions.md`. **iOS menus are always the system ones**: tap menus through `DropdownMenu`/`ChoicePicker` (native `Menu`), long-press through `.contextActions` (native `contextMenu`). Never hand-build a dropdown on iOS: a custom overlay lands in the wrong place (sheets, scroll views, the composer's + menu). The desktop app's menu bar/tray menu is the system menu. Keep system authentication and widget containers native. On iOS `.codyncSheet` presents the system sheet (grabber, swipe down). Outside these exceptions, avoid: no `Menu`/`Picker`, `.switch` toggles, `Form`/`List` styling, `confirmationDialog`/`alert`, `ProgressView`, `.sheet`/`.popover`/`.fullScreenCover`, `.toolbar`/navigation bars, `ContentUnavailableView`. Use `apps/ios/Kit/Sources/CodyncUI/Controls.swift` + `Chrome.swift` (`.codyncSheet`, `ModalHeader`, `ScreenHeader`, `.codyncDialog`, `ToggleStyle.codync`); on the desktop, `apps/desktop/src/renderer/components/` (`Sheet`, `Dialog`, `AnchoredMenu`, `ModalHeader`, `Controls.tsx`, `Icon` for SF Symbols). Every tap that shows/hides something animates (`Motion`). Anything with a background fill gets no border line.- `host/` — **codync-host** (Rust, macOS + Linux + Windows; platform differences in `service/` and `shell.rs`). Detects installed harnesses (`agent/backends.rs`: login-shell PATH + known dirs) and the ACP registry (`agent/registry.rs`, cached in `~/.codync/registry.json`, binaries under `~/.codync/agents`). Drives agents over **ACP** (JSON-RPC on stdio, hand-rolled in `agent/acp.rs`, updates kept as `serde_json::Value` so new adapter variants never break parsing). One actor per bot (`agent/bot/`) owns the agent process + session and maps `session/update` onto transcript entries.- Chat/session ownership, groups, collaboration, Engram memory and visible-message rules: [conversation runtime](docs/architecture/conversation-runtime.md).- **Sync**: every mutation stamps a global `rev`. Clients call `GET /events?since=<rev>` (catch-up in rev order, then live). Emission happens under `Hub::emit_lock` so events leave in rev order. Clients upsert by id; never skip undecodable events (the iOS app rewinds to rev 0).diff --git a/apps/ios/Kit/Sources/CodyncUI/Chrome.swift b/apps/ios/Kit/Sources/CodyncUI/Chrome.swiftindex df1fb0cb..eb168b99 100644--- a/apps/ios/Kit/Sources/CodyncUI/Chrome.swift+++ b/apps/ios/Kit/Sources/CodyncUI/Chrome.swift@@ -287,46 +287,3 @@ public extension View {.background(SwipeBackEnabler().frame(width: 0, height: 0))}}--// MARK: - Tab bar--/// The iPhone's bottom bar (replaces `TabView`): a floating capsule of icon tabs.-public struct TabBar<ID: Hashable>: View {- @Binding var selection: ID- let tabs: [(id: ID, title: String, icon: String)]- @Namespace private var thumb- @Environment(\.accessibilityReduceMotion) private var reduceMotion-- public init(selection: Binding<ID>, tabs: [(id: ID, title: String, icon: String)]) {- _selection = selection- self.tabs = tabs- }-- public var body: some View {- HStack(spacing: 4) {- ForEach(tabs, id: \.id) { tab in- let on = tab.id == selection- Button {- withAnimation(Motion.reduced(Motion.morph, reduceMotion)) { selection = tab.id }- } label: {- VStack(spacing: 3) {- Image(systemName: tab.icon).font(.system(size: 18, weight: .medium))- Text(tab.title).font(.caption2.weight(.medium))- }- .foregroundStyle(on ? Palette.text : Palette.secondary)- .frame(width: 76, height: 50)- .background {- if on {- Capsule().fill(Palette.text.opacity(0.08)).matchedGeometryEffect(id: "tab", in: thumb)- }- }- .contentShape(Capsule())- }- .buttonStyle(PressScale())- .accessibilityAddTraits(on ? .isSelected : [])- }- }- .padding(5)- .glass(in: Capsule())- }-}diff --git a/apps/ios/Views/RootView.swift b/apps/ios/Views/RootView.swiftindex c0d20de0..27efe96d 100644--- a/apps/ios/Views/RootView.swift+++ b/apps/ios/Views/RootView.swift@@ -69,32 +69,25 @@ struct RootView: View {}}- /// Both tab stacks stay alive (scroll position, open thread); the tab bar hides while a thread is open.+ /// The system tab bar; both tabs stay alive (scroll position, open thread) and the bar hides while a+ /// thread is open.private var tabs: some View {- ZStack {- NavigationStack(path: path) {- BotListView()- .navigationDestination(for: BotReference.self) { ref in ChatScreen(ref: ref) }- }- .tabLayer(app.tab == .bots)- StateTab()- .tabLayer(app.tab == .state)- }- .animation(Motion.reduced(Motion.fade, reduceMotion), value: app.tab)- .safeAreaInset(edge: .bottom, spacing: 0) {- if accounts.selection == nil {- VStack(spacing: 8) {- AccessBanners()- TabBar(selection: Bindable(app).tab, tabs: [- (id: AppTab.bots, title: "Bots", icon: "bubble.left.and.bubble.right.fill"),- (id: AppTab.state, title: "State", icon: "rectangle.stack.fill"),- ])- .padding(.bottom, 4)+ TabView(selection: Bindable(app).tab) {+ Tab("Bots", systemImage: "bubble.left.and.bubble.right.fill", value: AppTab.bots) {+ NavigationStack(path: path) {+ BotListView()+ .safeAreaInset(edge: .bottom, spacing: 0) { AccessBanners() }+ .navigationDestination(for: BotReference.self) { ref in+ ChatScreen(ref: ref).toolbar(.hidden, for: .tabBar)+ }}- .transition(.move(edge: .bottom).combined(with: .opacity))+ }+ Tab("State", systemImage: "rectangle.stack.fill", value: AppTab.state) {+ StateTab()+ .safeAreaInset(edge: .bottom, spacing: 0) { AccessBanners() }}}- .animation(Motion.reduced(Motion.layout, reduceMotion), value: accounts.selection == nil)+ .tint(Palette.text)// Opening a bot (notification, widget, link) always lands on the Bots tab..onChange(of: accounts.selection) { _, ref in if ref != nil { app.tab = .bots } }}@@ -349,6 +342,7 @@ private struct AccessBanners: View {}}.padding(.horizontal, 16)+ .padding(.bottom, accounts.pendingAccess.isEmpty ? 0 : 8).animation(Motion.layout, value: accounts.pendingAccess.keys.sorted()).accessibilityElement(children: .contain)}diff --git a/docs/design/ui-conventions.md b/docs/design/ui-conventions.mdindex 881e192e..1c82e2fc 100644--- a/docs/design/ui-conventions.md+++ b/docs/design/ui-conventions.md@@ -56,12 +56,12 @@ Other custom iPhone screens use `Chrome.swift` and `Controls.swift`. The desktop| Modal or full-window overlay | `.codyncSheet` (system sheet), `.codyncOverlay` || Header outside the native bot navigation flow | `ModalHeader`, `ScreenHeader` || Icon action | `IconButton` |-| Tab selection | `TabBar` |+| iPhone app tabs | System `TabView` (Liquid Glass tab bar, hidden inside a chat) || Menu / confirmation | `DropdownMenu` / `.contextActions` (system menus), `.codyncDialog` || Toggle | `ToggleStyle.codync` || Form-like content | `CardForm`, `CardSection` (a small bold heading over a filled, rounded group; rows split by inset hairlines; a row is `ValueRow` with an optional one-line `detail`, and its picker is an outlined `ChoicePicker`) |-Avoid adding stock `Menu`, `Picker`, `Form`/`List` styling, switch toggles, alerts, `ProgressView`, `TabView` or system sheets to these flows. System presentation APIs inside the shared chrome implementation are implementation details, not permission to bypass the components in feature screens. Native WidgetKit/ActivityKit containers and OS authentication/permission flows remain system integrations.+Avoid adding stock `Menu`, `Picker`, `Form`/`List` styling, switch toggles, alerts, `ProgressView` or system sheets to these flows. System presentation APIs inside the shared chrome implementation are implementation details, not permission to bypass the components in feature screens. Native WidgetKit/ActivityKit containers and OS authentication/permission flows remain system integrations.No scroll bars: scroll indicators never show (`.scrollIndicators(.never)` on the iPhone app's root, so every scroll view inherits it; hidden scrollbars in `apps/desktop/src/renderer/styles/theme.css`).