Skip to content

feat: add add project to mobile and use lazyvstack#27

Merged
sirily11 merged 2 commits into
mainfrom
improve-scrolling-project
May 20, 2026
Merged

feat: add add project to mobile and use lazyvstack#27
sirily11 merged 2 commits into
mainfrom
improve-scrolling-project

Conversation

@sirily11
Copy link
Copy Markdown
Contributor

No description provided.

Copilot AI review requested due to automatic review settings May 20, 2026 08:37
@vercel
Copy link
Copy Markdown

vercel Bot commented May 20, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
rxcode Ready Ready Preview, Comment May 20, 2026 8:37am

Request Review

@autopilot-project-manager autopilot-project-manager Bot added the enhancement New feature or request label May 20, 2026
@sirily11 sirily11 enabled auto-merge (squash) May 20, 2026 08:38
@sirily11 sirily11 merged commit ee7a354 into main May 20, 2026
8 checks passed
@sirily11 sirily11 deleted the improve-scrolling-project branch May 20, 2026 08:40
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds “Add Project” support to the mobile app by introducing a remote folder picker backed by new RxCodeSync payloads and desktop-side handlers, and it updates the macOS chat message list to use ScrollView + LazyVStack (plus some theme/style tweaks).

Changes:

  • Add a mobile remote folder picker UI and wiring to create projects from a selected desktop folder.
  • Extend the sync protocol and desktop/mobile services to support folder tree requests and create-project requests/results.
  • Replace macOS chat List with ScrollView/LazyVStack, and adjust related row styling/cursor behavior.

Reviewed changes

Copilot reviewed 15 out of 15 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
RxCodeMobile/Views/RemoteFolderPickerView.swift New SwiftUI view for browsing remote folders and triggering project creation.
RxCodeMobile/Views/ProjectsSidebar.swift Adds toolbar button + sheet to present the remote folder picker; selects newly created project.
RxCodeMobile/Views/MobileChatView.swift Updates plan banner styling to use glassEffect.
RxCodeMobile/State/MobileAppState.swift Adds published state + request/response handlers for remote folder tree + create-project flows.
RxCode/Views/Sidebar/ProjectListView.swift Sidebar styling tweaks (selection-aware icon color, text colors).
RxCode/Views/Sidebar/ProjectChatRow.swift Adjusts timestamp foreground style.
RxCode/Services/MobileSyncService.swift Routes new payloads to NotificationCenter observers.
RxCode/App/AppState.swift Implements desktop handlers for folder tree requests and create-project requests; builds RemoteFolderNode trees.
Packages/Tests/RxCodeSyncTests/PayloadTests.swift Adds round-trip JSON tests for new payload types.
Packages/Sources/RxCodeSync/Protocol/Payload.swift Defines new payload cases and Codable structs for folder tree + create-project.
Packages/Sources/RxCodeCore/Views/SessionSidebarRow.swift Theme color adjustments.
Packages/Sources/RxCodeChatKit/MessageListView.swift Switches macOS message list to ScrollView + LazyVStack.
Packages/Sources/RxCodeChatKit/MessageBubble.swift Refines streaming cursor placement logic across render blocks.
Packages/Sources/RxCodeChatKit/MarkdownView.swift Forces markdown view identity updates via .id(renderedMarkdown).
Packages/Sources/RxCodeChatKit/ChatMessageListView.swift Adjusts row styling to work with ScrollView on macOS (padding added).
Comments suppressed due to low confidence (1)

RxCode/App/AppState.swift:1657

  • MobileFolderPickerError.notFolder uses the message “Folder does not exist on the desktop.” but it can be thrown for any requested path (including non-desktop locations, permission failures, etc.). Use a location-agnostic description (or differentiate not-found vs not-a-directory vs permission).
    private enum MobileFolderPickerError: LocalizedError {
        case notFolder

        var errorDescription: String? {
            switch self {
            case .notFolder:
                return "Folder does not exist on the desktop."
            }

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +423 to +433
func createProjectFromRemoteFolder(path: String) async {
guard isPaired else { return }
let trimmed = path.trimmingCharacters(in: .whitespacesAndNewlines)
guard !trimmed.isEmpty else { return }
let request = CreateProjectRequestPayload(path: trimmed)
pendingCreateProjectRequestID = request.clientRequestID
remoteProjectCreateInFlight = true
remoteProjectCreateError = nil
do {
try await client.send(.createProjectRequest(request), toHex: pairedDesktopPubkey)
} catch {
Comment thread RxCode/App/AppState.swift
Comment on lines +1449 to +1466
private func handleMobileFolderTreeRequest(_ request: FolderTreeRequestPayload, fromHex: String) async {
let result: FolderTreeResultPayload
do {
let root = try mobileFolderTreeRoot(for: request)
result = FolderTreeResultPayload(
clientRequestID: request.clientRequestID,
requestedPath: request.path,
ok: true,
root: root
)
} catch {
result = FolderTreeResultPayload(
clientRequestID: request.clientRequestID,
requestedPath: request.path,
ok: false,
errorMessage: mobileFolderErrorMessage(error)
)
}
Comment thread RxCode/App/AppState.swift
name: Host.current().localizedName ?? "Mac",
path: "",
isSelectable: false,
children: mobileFolderPickerRoots(depth: 1, includeHidden: request.includeHidden)
Comment thread RxCode/App/AppState.swift
requestID: request.clientRequestID,
ok: false,
project: nil,
errorMessage: "Folder does not exist on the desktop.",
@sirily11
Copy link
Copy Markdown
Contributor Author

🎉 This PR is included in version 1.7.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request released

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants