UNPKG

automagik-cli

Version:

Automagik CLI - A powerful command-line interface for interacting with Automagik Hive multi-agent AI systems

26 lines (25 loc) 1.43 kB
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime"; import { Box, Text, useInput } from 'ink'; import { RadioButtonSelect } from './RadioButtonSelect.js'; export function SessionSelectionDialog({ selectedTarget, onSelect, onBack, }) { const items = [ { label: 'Start new conversation', value: 'new', }, { label: 'Continue existing session (coming soon)', value: 'existing', disabled: true, }, ]; const handleSelect = (sessionAction) => { onSelect(sessionAction); }; useInput((input, key) => { if (key.escape) { onBack(); } }); return (_jsxs(Box, { borderStyle: "round", borderColor: "#666666", flexDirection: "column", padding: 1, width: "100%", children: [_jsx(Text, { bold: true, children: "Session Options" }), _jsx(Box, { marginTop: 1, children: _jsxs(Text, { children: ["Ready to chat with: ", _jsx(Text, { color: "#00ff00", children: selectedTarget.name })] }) }), _jsx(Box, { marginTop: 1, children: _jsx(Text, { children: "How would you like to proceed?" }) }), _jsx(Box, { marginTop: 1, children: _jsx(RadioButtonSelect, { items: items, initialIndex: 0, onSelect: handleSelect, isFocused: true }) }), _jsx(Box, { marginTop: 1, children: _jsx(Text, { color: "#666666", children: "(Use \u2191/\u2193 arrows and Enter to select, Esc to go back)" }) })] })); }