@matterailab/orbcode 0.1.10 → 0.1.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,21 @@
1
+ import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
2
+ import { Box, Text, useInput } from "ink";
3
+ import { COLORS } from "../../branding.js";
4
+ const MAX_SHOWN = 8;
5
+ /**
6
+ * Shown at startup when the current project defines hooks that haven't been
7
+ * trusted yet. Project hooks run arbitrary shell commands, so they stay
8
+ * disabled until the user explicitly approves them here.
9
+ */
10
+ export function HookTrustPrompt({ cwd, commands, onDecision }) {
11
+ useInput((input, key) => {
12
+ const lower = input.toLowerCase();
13
+ if (lower === "y")
14
+ onDecision(true);
15
+ else if (lower === "n" || key.escape || key.return)
16
+ onDecision(false);
17
+ });
18
+ const shown = commands.slice(0, MAX_SHOWN);
19
+ const extra = commands.length - shown.length;
20
+ return (_jsxs(Box, { flexDirection: "column", borderStyle: "round", borderColor: COLORS.error, paddingX: 1, children: [_jsxs(Text, { bold: true, color: COLORS.error, children: ["\u26A0 This project defines ", commands.length, " hook command", commands.length === 1 ? "" : "s"] }), _jsxs(Box, { paddingLeft: 2, flexDirection: "column", children: [_jsxs(Text, { dimColor: true, children: [cwd, "/.orbcode/settings.json"] }), _jsx(Text, { children: "Project hooks run these shell commands automatically during the session:" }), shown.map((command, i) => (_jsxs(Text, { color: COLORS.warning, children: [" • ", command.length > 100 ? command.slice(0, 99) + "…" : command] }, i))), extra > 0 && _jsxs(Text, { dimColor: true, children: [" \u2026 ", extra, " more"] })] }), _jsx(Text, { dimColor: true, children: "Only trust hooks from a repository you trust. (y) trust & enable \u00B7 (n or Enter) keep disabled" })] }));
21
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@matterailab/orbcode",
3
- "version": "0.1.10",
3
+ "version": "0.1.14",
4
4
  "description": "OrbCode CLI — agentic coding in your terminal, powered by Axon models by MatterAI",
5
5
  "type": "module",
6
6
  "bin": {
@@ -36,6 +36,9 @@
36
36
  "prepublishOnly": "npm run typecheck && npm run build"
37
37
  },
38
38
  "dependencies": {
39
+ "@ai-sdk/anthropic": "^3.0.85",
40
+ "@ai-sdk/openai-compatible": "^2.0.51",
41
+ "ai": "^6.0.207",
39
42
  "chalk": "^5.3.0",
40
43
  "ink": "^5.2.1",
41
44
  "open": "^10.1.0",