mirror of
https://github.com/anomalyco/opencode.git
synced 2026-04-29 01:07:04 +00:00
27 lines
615 B
TypeScript
27 lines
615 B
TypeScript
import { DialogSelect } from "@tui/ui/dialog-select"
|
|
import { useRoute } from "@tui/context/route"
|
|
|
|
export function DialogSubagent(props: { sessionID: string }) {
|
|
const route = useRoute()
|
|
|
|
return (
|
|
<DialogSelect
|
|
title="Subagent Actions"
|
|
options={[
|
|
{
|
|
title: "Open",
|
|
value: "subagent.view",
|
|
description: "open the subagent's session",
|
|
onSelect: (dialog) => {
|
|
route.navigate({
|
|
type: "session",
|
|
sessionID: props.sessionID,
|
|
})
|
|
dialog.clear()
|
|
},
|
|
},
|
|
]}
|
|
/>
|
|
)
|
|
}
|