Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 0 additions & 17 deletions packages/webui/docs/API.md
Original file line number Diff line number Diff line change
Expand Up @@ -629,23 +629,6 @@ field on the response is for the "no workspace needed" button.
}
```

### `POST /api/workspace/pick`

Spawn the native OS folder picker (`zenity` / `kdialog` / `osascript` /
PowerShell `FolderBrowser`) and return the chosen path. The route
never throws — a user cancel answers `200 {ok: true, path: null}`; a
spawn failure answers `200 {ok: false, error}`.

**Response 200** (user picked something)
```json
{ "ok": true, "path": "C:\\path\\to\\folder" }
```

**Response 200** (user cancelled)
```json
{ "ok": true, "path": null }
```

---

## Filesystem
Expand Down
17 changes: 0 additions & 17 deletions packages/webui/docs/API.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -610,23 +610,6 @@ Linux 上为 `/`)
}
```

### `POST /api/workspace/pick`

拉起系统原生的文件夹选择器(`zenity` / `kdialog` / `osascript` /
PowerShell `FolderBrowser`),返回所选路径。本路由绝不抛错 ——
用户取消时返回 `200 {ok: true, path: null}`;启动失败时返回
`200 {ok: false, error}`。

**响应 200**(用户已选择)
```json
{ "ok": true, "path": "C:\\path\\to\\folder" }
```

**响应 200**(用户取消)
```json
{ "ok": true, "path": null }
```

---

## 文件系统
Expand Down
4 changes: 0 additions & 4 deletions packages/webui/server/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,6 @@ export const OWNED_ROUTES = new Set([
"GET /api/workspace/tree",
"GET /api/workspace/resolve",
"GET /api/workspace/recent",
"POST /api/workspace/pick",
// Native-style fs picker.
"GET /api/fs/read",
"POST /api/fs/mkdir",
Expand Down Expand Up @@ -452,9 +451,6 @@ export function createHonoApp() {
app.get("/api/workspace/recent", (c) =>
invokeHandler(c, c.get(CAPTURE_KEY), workspaceRoute.handleWorkspaceRecent),
);
app.post("/api/workspace/pick", (c) =>
invokeHandler(c, c.get(CAPTURE_KEY), workspaceRoute.handleWorkspacePick),
);

// ----- Native-style fs picker -----
app.get("/api/fs/read", (c) =>
Expand Down
Loading
Loading