Use server naming for shared API/events

This commit is contained in:
Shantur Rathore
2025-11-21 00:04:01 +00:00
parent d6fdef68d9
commit 2ff51c1866
9 changed files with 31 additions and 31 deletions

View File

@@ -1,7 +1,7 @@
import { Component, createSignal, createEffect, For, Show, onCleanup } from "solid-js"
import type { Agent } from "../types/session"
import type { OpencodeClient } from "@opencode-ai/sdk/client"
import { cliApi } from "../lib/api-client"
import { serverApi } from "../lib/api-client"
const SEARCH_RESULT_LIMIT = 100
const SEARCH_DEBOUNCE_MS = 200
@@ -115,7 +115,7 @@ const UnifiedPicker: Component<UnifiedPickerProps> = (props) => {
}
inflightWorkspaceId = workspaceId
inflightSnapshotPromise = cliApi
inflightSnapshotPromise = serverApi
.listWorkspaceFiles(workspaceId)
.then((entries) => mapEntriesToFileItems(entries))
.then((snapshot) => {
@@ -169,7 +169,7 @@ const UnifiedPicker: Component<UnifiedPickerProps> = (props) => {
return
}
const results = await cliApi.searchWorkspaceFiles(workspaceId, normalizedQuery, {
const results = await serverApi.searchWorkspaceFiles(workspaceId, normalizedQuery, {
limit: SEARCH_RESULT_LIMIT,
})
if (!shouldApplyResults(requestId, workspaceId)) {