@vibe-kit/grok-cli
Version:
An open-source AI agent that brings the power of Grok directly into your terminal.
24 lines • 1.42 kB
JavaScript
;
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.ModelSelection = void 0;
const react_1 = __importDefault(require("react"));
const ink_1 = require("ink");
function ModelSelection({ models, selectedIndex, isVisible, currentModel, }) {
if (!isVisible)
return null;
return (react_1.default.createElement(ink_1.Box, { marginTop: 1, flexDirection: "column" },
react_1.default.createElement(ink_1.Box, { marginBottom: 1 },
react_1.default.createElement(ink_1.Text, { color: "cyan" },
"Select Grok Model (current: ",
currentModel,
"):")),
models.map((modelOption, index) => (react_1.default.createElement(ink_1.Box, { key: index, paddingLeft: 1 },
react_1.default.createElement(ink_1.Text, { color: index === selectedIndex ? "black" : "white", backgroundColor: index === selectedIndex ? "cyan" : undefined }, modelOption.model)))),
react_1.default.createElement(ink_1.Box, { marginTop: 1 },
react_1.default.createElement(ink_1.Text, { color: "gray", dimColor: true }, "\u2191\u2193 navigate \u2022 Enter/Tab select \u2022 Esc cancel"))));
}
exports.ModelSelection = ModelSelection;
//# sourceMappingURL=model-selection.js.map