mirror of
https://github.com/Kilo-Org/kilocode.git
synced 2026-09-24 16:02:55 +08:00
fix(tui): show docs URL in dialog when browser cannot open on headless systems
Resolve merge conflict with main (command structure refactored from onSelect to run) and add missing changeset.
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"@kilocode/cli": patch
|
||||
---
|
||||
|
||||
Show the docs URL in an alert dialog when the browser cannot be opened on headless systems instead of silently failing.
|
||||
@@ -685,8 +685,15 @@ function App(props: { onSnapshot?: () => Promise<string[]> }) {
|
||||
name: "docs.open",
|
||||
title: "Open docs",
|
||||
run: () => {
|
||||
open(KiloApp.DOCS_URL).catch(() => {}) // kilocode_change
|
||||
dialog.clear()
|
||||
open(KiloApp.DOCS_URL).catch(() => {
|
||||
dialog.replace(() => (
|
||||
<DialogAlert
|
||||
title="Cannot open browser"
|
||||
message={`No display detected.\n\nOpen the docs manually:\n${KiloApp.DOCS_URL}`}
|
||||
/>
|
||||
))
|
||||
}) // kilocode_change
|
||||
},
|
||||
category: "System",
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user