zidane 5.1.13 → 5.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.
- package/dist/{agent-skiQGYs2.d.ts → agent-BuGxYfqh.d.ts} +11 -4
- package/dist/agent-BuGxYfqh.d.ts.map +1 -0
- package/dist/chat.d.ts +172 -6
- package/dist/chat.d.ts.map +1 -1
- package/dist/chat.js +2 -2
- package/dist/{index-CjPh6CRE.d.ts → index-Aaa1tP6E.d.ts} +2 -2
- package/dist/{index-CjPh6CRE.d.ts.map → index-Aaa1tP6E.d.ts.map} +1 -1
- package/dist/{index-YM7SipFz.d.ts → index-Cv5wED8j.d.ts} +2 -2
- package/dist/{index-YM7SipFz.d.ts.map → index-Cv5wED8j.d.ts.map} +1 -1
- package/dist/index.d.ts +3 -3
- package/dist/index.js +5 -5
- package/dist/{login-Cc6Q-Fpu.js → login-DJscx_sS.js} +4 -4
- package/dist/{login-Cc6Q-Fpu.js.map → login-DJscx_sS.js.map} +1 -1
- package/dist/{mcp-CUt-N8zn.js → mcp-Bq_rD6e9.js} +2 -2
- package/dist/{mcp-CUt-N8zn.js.map → mcp-Bq_rD6e9.js.map} +1 -1
- package/dist/mcp.d.ts +1 -1
- package/dist/mcp.js +1 -1
- package/dist/{presets-Ce79MK4J.js → presets-BEruW0Ji.js} +2 -2
- package/dist/{presets-Ce79MK4J.js.map → presets-BEruW0Ji.js.map} +1 -1
- package/dist/presets.d.ts +2 -2
- package/dist/presets.js +1 -1
- package/dist/providers.d.ts +1 -1
- package/dist/session/sqlite.d.ts +1 -1
- package/dist/session.d.ts +1 -1
- package/dist/skills.d.ts +2 -2
- package/dist/{tools-BG2wMa3X.js → tools-BBFu1UsV.js} +3 -3
- package/dist/{tools-BG2wMa3X.js.map → tools-BBFu1UsV.js.map} +1 -1
- package/dist/tools.d.ts +2 -2
- package/dist/tools.js +1 -1
- package/dist/{tool-formatters-0aOMYbH-.d.ts → transcript-anchors-FJMZyLS4.d.ts} +242 -97
- package/dist/transcript-anchors-FJMZyLS4.d.ts.map +1 -0
- package/dist/tui.d.ts +55 -39
- package/dist/tui.d.ts.map +1 -1
- package/dist/tui.js +335 -314
- package/dist/tui.js.map +1 -1
- package/dist/{turn-operations-CDmQ2h-T.js → turn-operations-CeLlc7jt.js} +572 -91
- package/dist/turn-operations-CeLlc7jt.js.map +1 -0
- package/dist/{types-Bx_F8jet.js → types-IcokUOyC.js} +11 -4
- package/dist/{types-Bx_F8jet.js.map → types-IcokUOyC.js.map} +1 -1
- package/dist/types.d.ts +2 -2
- package/dist/types.js +1 -1
- package/package.json +1 -1
- package/dist/agent-skiQGYs2.d.ts.map +0 -1
- package/dist/tool-formatters-0aOMYbH-.d.ts.map +0 -1
- package/dist/turn-operations-CDmQ2h-T.js.map +0 -1
package/dist/tools.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { b as ToolMap, v as ToolContext, y as ToolDef } from "./agent-
|
|
2
|
-
import { A as listFiles, C as SkillsRunScriptToolOptions, D as shell, E as createSkillsReadTool, F as edit, M as createInteractionTool, N as grep, O as readFile, P as glob, S as createSkillsUseTool, T as SkillsReadToolOptions, _ as ChildAgent, b as createSpawnTool, d as writeFile, f as ValidationResult, g as createToolSearchTool, h as ToolSearchToolOptions, j as InteractionToolOptions, k as multiEdit, m as LazyToolEntry, p as validateToolArgs, v as SpawnToolOptions, w as createSkillsRunScriptTool, x as SkillsUseToolOptions, y as SpawnToolState } from "./index-
|
|
1
|
+
import { b as ToolMap, v as ToolContext, y as ToolDef } from "./agent-BuGxYfqh.js";
|
|
2
|
+
import { A as listFiles, C as SkillsRunScriptToolOptions, D as shell, E as createSkillsReadTool, F as edit, M as createInteractionTool, N as grep, O as readFile, P as glob, S as createSkillsUseTool, T as SkillsReadToolOptions, _ as ChildAgent, b as createSpawnTool, d as writeFile, f as ValidationResult, g as createToolSearchTool, h as ToolSearchToolOptions, j as InteractionToolOptions, k as multiEdit, m as LazyToolEntry, p as validateToolArgs, v as SpawnToolOptions, w as createSkillsRunScriptTool, x as SkillsUseToolOptions, y as SpawnToolState } from "./index-Aaa1tP6E.js";
|
|
3
3
|
export { ChildAgent, InteractionToolOptions, LazyToolEntry, SkillsReadToolOptions, SkillsRunScriptToolOptions, SkillsUseToolOptions, SpawnToolOptions, SpawnToolState, ToolContext, ToolDef, ToolMap, ToolSearchToolOptions, ValidationResult, createInteractionTool, createSkillsReadTool, createSkillsRunScriptTool, createSkillsUseTool, createSpawnTool, createToolSearchTool, edit, glob, grep, listFiles, multiEdit, readFile, shell, validateToolArgs, writeFile };
|
package/dist/tools.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as multiEdit, c as grep, f as createToolSearchTool, g as validateToolArgs, h as createSkillsReadTool, i as readFile, l as glob, m as createSkillsRunScriptTool, n as createSpawnTool, o as listFiles, p as createSkillsUseTool, r as shell, s as createInteractionTool, t as writeFile, u as edit } from "./tools-
|
|
1
|
+
import { a as multiEdit, c as grep, f as createToolSearchTool, g as validateToolArgs, h as createSkillsReadTool, i as readFile, l as glob, m as createSkillsRunScriptTool, n as createSpawnTool, o as listFiles, p as createSkillsUseTool, r as shell, s as createInteractionTool, t as writeFile, u as edit } from "./tools-BBFu1UsV.js";
|
|
2
2
|
export { createInteractionTool, createSkillsReadTool, createSkillsRunScriptTool, createSkillsUseTool, createSpawnTool, createToolSearchTool, edit, glob, grep, listFiles, multiEdit, readFile, shell, validateToolArgs, writeFile };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { A as SessionStore, Ft as ToolResultContent, Mt as ThinkingLevel, O as SessionData, W as Provider, gt as McpServerConfig, k as SessionRun, kt as SessionTurn, y as ToolDef } from "./agent-
|
|
2
|
-
import { t as Preset } from "./index-
|
|
1
|
+
import { A as SessionStore, Ft as ToolResultContent, Mt as ThinkingLevel, O as SessionData, W as Provider, gt as McpServerConfig, k as SessionRun, kt as SessionTurn, y as ToolDef } from "./agent-BuGxYfqh.js";
|
|
2
|
+
import { t as Preset } from "./index-Aaa1tP6E.js";
|
|
3
3
|
import { OAuthProviderInterface } from "@mariozechner/pi-ai/oauth";
|
|
4
4
|
import { ReactNode } from "react";
|
|
5
5
|
import * as _$react_jsx_runtime0 from "react/jsx-runtime";
|
|
@@ -1401,6 +1401,106 @@ interface ResolvedConfig {
|
|
|
1401
1401
|
/** Resolve user options into a fully-bound runtime config. Pure aside from disk reads. */
|
|
1402
1402
|
declare function resolveConfig(options: ChatOptions): ResolvedConfig;
|
|
1403
1403
|
//#endregion
|
|
1404
|
+
//#region src/chat/mcps-discovery.d.ts
|
|
1405
|
+
/**
|
|
1406
|
+
* One entry in the discovered list. `path` is the source file so a Settings
|
|
1407
|
+
* picker can show "Defined in ~/.zidane/mcps.json" tooltips.
|
|
1408
|
+
*/
|
|
1409
|
+
interface DiscoveredMcp {
|
|
1410
|
+
config: McpServerConfig;
|
|
1411
|
+
source: 'project' | 'user';
|
|
1412
|
+
path: string;
|
|
1413
|
+
}
|
|
1414
|
+
/**
|
|
1415
|
+
* Search order for `mcps.json` — see {@link projectUserPaths}. Project
|
|
1416
|
+
* beats user; the first file found for each (name) wins. Non-existent
|
|
1417
|
+
* files are skipped without error.
|
|
1418
|
+
*/
|
|
1419
|
+
declare function defaultMcpsConfigPaths(opts?: {
|
|
1420
|
+
cwd?: string;
|
|
1421
|
+
home?: string;
|
|
1422
|
+
prefix?: string;
|
|
1423
|
+
}): {
|
|
1424
|
+
path: string;
|
|
1425
|
+
source: 'project' | 'user';
|
|
1426
|
+
}[];
|
|
1427
|
+
/**
|
|
1428
|
+
* Parse one `mcps.json` file. Canonical zidane shape is a flat array; the
|
|
1429
|
+
* other shapes exist for copy-paste from neighboring tools:
|
|
1430
|
+
*
|
|
1431
|
+
* - `McpServerConfig[]` — flat array (recommended).
|
|
1432
|
+
* - `{ name: {...} }` — name-keyed map.
|
|
1433
|
+
* - `{ "mcpServers": { name: {...} } }` — Claude Desktop / Claude Code /
|
|
1434
|
+
* Cursor wrapper. Unwrapped before normalization (otherwise
|
|
1435
|
+
* `normalizeMcpServers` would treat the whole wrapper as a single server).
|
|
1436
|
+
*
|
|
1437
|
+
* Per-entry `enabled: false` (Cursor runtime state) drops the entry — same
|
|
1438
|
+
* intent as the source tool. Use the TUI toggle list for "show but disabled".
|
|
1439
|
+
*
|
|
1440
|
+
* Tolerant to common copy-paste artifacts: when strict `JSON.parse` fails,
|
|
1441
|
+
* retries after normalizing invisible whitespace that's valid Unicode but
|
|
1442
|
+
* not valid JSON whitespace (BOM, NBSP, zero-width spaces, line/paragraph
|
|
1443
|
+
* separators) — only OUTSIDE string literals, so user data isn't mutated.
|
|
1444
|
+
* If the sanitized version still fails, throws the original error with a
|
|
1445
|
+
* targeted hint when NBSPs are present.
|
|
1446
|
+
*
|
|
1447
|
+
* Validation flows through `normalizeMcpServers` so the result matches
|
|
1448
|
+
* what `createAgent` accepts. Throws on truly malformed JSON; the caller
|
|
1449
|
+
* decides whether to surface or swallow.
|
|
1450
|
+
*/
|
|
1451
|
+
declare function parseMcpsFile(text: string): McpServerConfig[];
|
|
1452
|
+
/**
|
|
1453
|
+
* Per-file failure surfaced from {@link discoverProjectMcps}. The TUI shows
|
|
1454
|
+
* these in the MCP settings empty / preamble state so a malformed
|
|
1455
|
+
* `mcps.json` doesn't look identical to a missing one.
|
|
1456
|
+
*/
|
|
1457
|
+
interface DiscoveryError {
|
|
1458
|
+
path: string;
|
|
1459
|
+
source: 'project' | 'user';
|
|
1460
|
+
message: string;
|
|
1461
|
+
}
|
|
1462
|
+
/**
|
|
1463
|
+
* Result of {@link discoverProjectMcps}. `servers` is the per-source-priority
|
|
1464
|
+
* merged list (project beats user, first-found wins on name collision).
|
|
1465
|
+
* `errors` is one entry per file that existed but failed to parse — empty
|
|
1466
|
+
* on the happy path.
|
|
1467
|
+
*/
|
|
1468
|
+
interface DiscoveryResult {
|
|
1469
|
+
servers: DiscoveredMcp[];
|
|
1470
|
+
errors: DiscoveryError[];
|
|
1471
|
+
}
|
|
1472
|
+
/**
|
|
1473
|
+
* Walk the default config paths, parse every file that exists, and return
|
|
1474
|
+
* `{ servers, errors }` in source-priority order. Project entries appear
|
|
1475
|
+
* before user entries; first occurrence of a `name` wins (later
|
|
1476
|
+
* duplicates dropped).
|
|
1477
|
+
*
|
|
1478
|
+
* Parse failures are captured into `errors` rather than thrown — the picker
|
|
1479
|
+
* surfaces them while still showing whatever DID parse. A `ZIDANE_DEBUG`
|
|
1480
|
+
* log line is also emitted for ops visibility.
|
|
1481
|
+
*/
|
|
1482
|
+
declare function discoverProjectMcps(opts?: {
|
|
1483
|
+
cwd?: string;
|
|
1484
|
+
home?: string;
|
|
1485
|
+
prefix?: string;
|
|
1486
|
+
}): DiscoveryResult;
|
|
1487
|
+
/**
|
|
1488
|
+
* Map a user-toggled enable list onto the `mcpServers` array the agent
|
|
1489
|
+
* receives. Conventions match `buildSkillsConfig`:
|
|
1490
|
+
*
|
|
1491
|
+
* - `enabled === undefined` → every discovered server enabled (default).
|
|
1492
|
+
* - `enabled === []` → no servers (the agent runs MCP-less).
|
|
1493
|
+
* - `enabled === [names]` → allowlist; servers not in the list are
|
|
1494
|
+
* dropped.
|
|
1495
|
+
*
|
|
1496
|
+
* Returns a fresh array — callers can mutate without affecting the
|
|
1497
|
+
* underlying discovery list.
|
|
1498
|
+
*/
|
|
1499
|
+
declare function buildMcpServers(opts: {
|
|
1500
|
+
discovered: readonly DiscoveredMcp[];
|
|
1501
|
+
enabled?: readonly string[];
|
|
1502
|
+
}): McpServerConfig[];
|
|
1503
|
+
//#endregion
|
|
1404
1504
|
//#region src/chat/enabled-toggle-set.d.ts
|
|
1405
1505
|
/**
|
|
1406
1506
|
* Renderer-agnostic state machine for an "enabled allowlist" — the shape
|
|
@@ -1444,6 +1544,68 @@ declare function useEnabledToggleSet<T>(opts: {
|
|
|
1444
1544
|
settingKey: EnabledAllowlistKey;
|
|
1445
1545
|
}): EnabledToggleSet;
|
|
1446
1546
|
//#endregion
|
|
1547
|
+
//#region src/chat/hints.d.ts
|
|
1548
|
+
/**
|
|
1549
|
+
* Single hint entry — `<key> <label>`, optionally followed by an inline
|
|
1550
|
+
* secondary chord (`<key><extra.key> <label> <extra.label>`) for compound
|
|
1551
|
+
* shortcuts like `ctrl+m/n model effort`.
|
|
1552
|
+
*
|
|
1553
|
+
* Colour fields are advisory hex strings (resolved against the active
|
|
1554
|
+
* theme by the renderer); leaving them undefined lets the renderer pick
|
|
1555
|
+
* its conventional fallback (e.g. `warn` for keys, `dim` for labels,
|
|
1556
|
+
* `mute` for secondary).
|
|
1557
|
+
*/
|
|
1558
|
+
interface Hint {
|
|
1559
|
+
key: string;
|
|
1560
|
+
label: string;
|
|
1561
|
+
/** Optional override for the key color. Renderer default: warn. */
|
|
1562
|
+
keyColor?: string;
|
|
1563
|
+
/** Optional override for the label color. Renderer default: dim. */
|
|
1564
|
+
labelColor?: string;
|
|
1565
|
+
/**
|
|
1566
|
+
* Optional secondary chord + value rendered inline after the primary
|
|
1567
|
+
* pair: `<key><extra.key> <label> <extra.label>`. Lets one hint advertise
|
|
1568
|
+
* a compound shortcut (e.g. `ctrl+m/n model effort`) without forcing
|
|
1569
|
+
* callers into a parallel struct or a custom renderer.
|
|
1570
|
+
*/
|
|
1571
|
+
extra?: {
|
|
1572
|
+
key: string;
|
|
1573
|
+
label: string; /** Defaults to mute on the renderer side. */
|
|
1574
|
+
keyColor?: string; /** Defaults to dim on the renderer side. */
|
|
1575
|
+
labelColor?: string;
|
|
1576
|
+
};
|
|
1577
|
+
}
|
|
1578
|
+
/**
|
|
1579
|
+
* Truncate `text` to at most `max` characters, replacing the trailing
|
|
1580
|
+
* overflow with `…`. Edge cases:
|
|
1581
|
+
* - `max <= 0` → empty string (no room to render at all).
|
|
1582
|
+
* - `max === 1` → just the ellipsis glyph.
|
|
1583
|
+
* - `text.length <= max` → unchanged.
|
|
1584
|
+
*
|
|
1585
|
+
* Trailing-style truncation matches the natural read order of titles:
|
|
1586
|
+
* the prefix carries enough signal to identify the surface.
|
|
1587
|
+
*/
|
|
1588
|
+
declare function truncateTrailing(text: string, max: number): string;
|
|
1589
|
+
/**
|
|
1590
|
+
* Plain-text width estimate for a list of {@link Hint}s rendered as
|
|
1591
|
+
* `<key> <label> · <key> <label> · …`. Exported so prompt-box overlays
|
|
1592
|
+
* can run the same responsive math as the bottom-bar footer when
|
|
1593
|
+
* deciding whether trigger hints fit. Pure / total.
|
|
1594
|
+
*/
|
|
1595
|
+
declare function hintsLength(hints: readonly Hint[]): number;
|
|
1596
|
+
/**
|
|
1597
|
+
* Return the longest prefix of `hints` whose rendered width fits within
|
|
1598
|
+
* `budget`. Used to degrade hint rows gracefully at narrow terminal
|
|
1599
|
+
* widths instead of letting an absolutely-positioned hint row wrap
|
|
1600
|
+
* mid-segment (which paints the overflow over surrounding borders and
|
|
1601
|
+
* looks like garbled glyphs in a TUI).
|
|
1602
|
+
*
|
|
1603
|
+
* Prefix-only (no reordering, no last-hint priority) so the survivors
|
|
1604
|
+
* keep their authored order — the user's muscle memory for "leftmost
|
|
1605
|
+
* hint = primary action" stays intact as the terminal shrinks.
|
|
1606
|
+
*/
|
|
1607
|
+
declare function clipHintsToWidth(hints: readonly Hint[], budget: number): readonly Hint[];
|
|
1608
|
+
//#endregion
|
|
1447
1609
|
//#region src/chat/interactions.d.ts
|
|
1448
1610
|
declare const PRESENT_PLAN_TOOL = "present_plan";
|
|
1449
1611
|
declare const ASK_USER_TOOL = "ask_user";
|
|
@@ -1661,105 +1823,45 @@ declare function useInteractionsActions(): InteractionsActions;
|
|
|
1661
1823
|
*/
|
|
1662
1824
|
declare function makeRequestInteraction(actions: InteractionsActions): CreateInteractionToolsOptions['requestInteraction'];
|
|
1663
1825
|
//#endregion
|
|
1664
|
-
//#region src/chat/
|
|
1665
|
-
/**
|
|
1666
|
-
* One
|
|
1667
|
-
*
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
|
|
1674
|
-
|
|
1675
|
-
|
|
1676
|
-
|
|
1677
|
-
|
|
1678
|
-
|
|
1679
|
-
|
|
1680
|
-
|
|
1681
|
-
|
|
1682
|
-
|
|
1683
|
-
|
|
1684
|
-
|
|
1685
|
-
source: 'project' | 'user';
|
|
1686
|
-
}[];
|
|
1687
|
-
/**
|
|
1688
|
-
* Parse one `mcps.json` file. Canonical zidane shape is a flat array; the
|
|
1689
|
-
* other shapes exist for copy-paste from neighboring tools:
|
|
1690
|
-
*
|
|
1691
|
-
* - `McpServerConfig[]` — flat array (recommended).
|
|
1692
|
-
* - `{ name: {...} }` — name-keyed map.
|
|
1693
|
-
* - `{ "mcpServers": { name: {...} } }` — Claude Desktop / Claude Code /
|
|
1694
|
-
* Cursor wrapper. Unwrapped before normalization (otherwise
|
|
1695
|
-
* `normalizeMcpServers` would treat the whole wrapper as a single server).
|
|
1696
|
-
*
|
|
1697
|
-
* Per-entry `enabled: false` (Cursor runtime state) drops the entry — same
|
|
1698
|
-
* intent as the source tool. Use the TUI toggle list for "show but disabled".
|
|
1699
|
-
*
|
|
1700
|
-
* Tolerant to common copy-paste artifacts: when strict `JSON.parse` fails,
|
|
1701
|
-
* retries after normalizing invisible whitespace that's valid Unicode but
|
|
1702
|
-
* not valid JSON whitespace (BOM, NBSP, zero-width spaces, line/paragraph
|
|
1703
|
-
* separators) — only OUTSIDE string literals, so user data isn't mutated.
|
|
1704
|
-
* If the sanitized version still fails, throws the original error with a
|
|
1705
|
-
* targeted hint when NBSPs are present.
|
|
1706
|
-
*
|
|
1707
|
-
* Validation flows through `normalizeMcpServers` so the result matches
|
|
1708
|
-
* what `createAgent` accepts. Throws on truly malformed JSON; the caller
|
|
1709
|
-
* decides whether to surface or swallow.
|
|
1710
|
-
*/
|
|
1711
|
-
declare function parseMcpsFile(text: string): McpServerConfig[];
|
|
1712
|
-
/**
|
|
1713
|
-
* Per-file failure surfaced from {@link discoverProjectMcps}. The TUI shows
|
|
1714
|
-
* these in the MCP settings empty / preamble state so a malformed
|
|
1715
|
-
* `mcps.json` doesn't look identical to a missing one.
|
|
1716
|
-
*/
|
|
1717
|
-
interface DiscoveryError {
|
|
1718
|
-
path: string;
|
|
1719
|
-
source: 'project' | 'user';
|
|
1720
|
-
message: string;
|
|
1826
|
+
//#region src/chat/markdown-segments.d.ts
|
|
1827
|
+
/**
|
|
1828
|
+
* One block returned by {@link splitMarkdownCodeBlocks}. Prose segments
|
|
1829
|
+
* carry their original markdown (including blank lines that bracketed
|
|
1830
|
+
* the fence) so the surrounding paragraph spacing stays faithful to the
|
|
1831
|
+
* original input. Code segments carry the raw body — fence markers and
|
|
1832
|
+
* info-string stripped — so a "copy code" action lands what the user
|
|
1833
|
+
* actually sees, byte-for-byte.
|
|
1834
|
+
*/
|
|
1835
|
+
interface MarkdownSegment {
|
|
1836
|
+
kind: 'prose' | 'code';
|
|
1837
|
+
content: string;
|
|
1838
|
+
/** Info-string (e.g. `ts`, `python`). Empty when the fence had none. */
|
|
1839
|
+
lang?: string;
|
|
1840
|
+
/**
|
|
1841
|
+
* `true` on a code segment whose closing fence hasn't arrived yet —
|
|
1842
|
+
* i.e. the trailing block during streaming. Consumers can render this
|
|
1843
|
+
* in "streaming" mode (no copy affordance, partial-highlight pipeline)
|
|
1844
|
+
* until the closer lands and it flips to a regular closed segment.
|
|
1845
|
+
*/
|
|
1846
|
+
open?: boolean;
|
|
1721
1847
|
}
|
|
1722
1848
|
/**
|
|
1723
|
-
*
|
|
1724
|
-
* merged list (project beats user, first-found wins on name collision).
|
|
1725
|
-
* `errors` is one entry per file that existed but failed to parse — empty
|
|
1726
|
-
* on the happy path.
|
|
1727
|
-
*/
|
|
1728
|
-
interface DiscoveryResult {
|
|
1729
|
-
servers: DiscoveredMcp[];
|
|
1730
|
-
errors: DiscoveryError[];
|
|
1731
|
-
}
|
|
1732
|
-
/**
|
|
1733
|
-
* Walk the default config paths, parse every file that exists, and return
|
|
1734
|
-
* `{ servers, errors }` in source-priority order. Project entries appear
|
|
1735
|
-
* before user entries; first occurrence of a `name` wins (later
|
|
1736
|
-
* duplicates dropped).
|
|
1849
|
+
* Split markdown text into alternating prose / fenced-code segments.
|
|
1737
1850
|
*
|
|
1738
|
-
*
|
|
1739
|
-
*
|
|
1740
|
-
*
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
cwd?: string;
|
|
1744
|
-
home?: string;
|
|
1745
|
-
prefix?: string;
|
|
1746
|
-
}): DiscoveryResult;
|
|
1747
|
-
/**
|
|
1748
|
-
* Map a user-toggled enable list onto the `mcpServers` array the agent
|
|
1749
|
-
* receives. Conventions match `buildSkillsConfig`:
|
|
1851
|
+
* Recognizes both ` ``` ` and `~~~` fences, with arbitrary length ≥ 3,
|
|
1852
|
+
* matching CommonMark's "fence indicator must be at least as long to
|
|
1853
|
+
* close" rule. Info-strings (the bit after the opening fence) are kept
|
|
1854
|
+
* as the `lang` hint; any trailing whitespace is trimmed. Closing
|
|
1855
|
+
* fences are detected on a line of their own (whitespace tolerated).
|
|
1750
1856
|
*
|
|
1751
|
-
*
|
|
1752
|
-
*
|
|
1753
|
-
*
|
|
1754
|
-
*
|
|
1857
|
+
* Unclosed fences fall back to emitting the would-be-code body as a
|
|
1858
|
+
* trailing prose segment so no content is dropped — finalized markdown
|
|
1859
|
+
* isn't expected to ship one, but the fallback keeps the renderer
|
|
1860
|
+
* truthful when the model produces malformed output.
|
|
1755
1861
|
*
|
|
1756
|
-
*
|
|
1757
|
-
* underlying discovery list.
|
|
1862
|
+
* Exported for unit tests.
|
|
1758
1863
|
*/
|
|
1759
|
-
declare function
|
|
1760
|
-
discovered: readonly DiscoveredMcp[];
|
|
1761
|
-
enabled?: readonly string[];
|
|
1762
|
-
}): McpServerConfig[];
|
|
1864
|
+
declare function splitMarkdownCodeBlocks(text: string): MarkdownSegment[];
|
|
1763
1865
|
//#endregion
|
|
1764
1866
|
//#region src/chat/prompt-segments.d.ts
|
|
1765
1867
|
/**
|
|
@@ -2193,5 +2295,48 @@ declare function displayNameFor(name: string): string;
|
|
|
2193
2295
|
*/
|
|
2194
2296
|
declare function formatToolCall(name: string, input: Record<string, unknown>): ToolFormatLine | null;
|
|
2195
2297
|
//#endregion
|
|
2196
|
-
|
|
2197
|
-
|
|
2298
|
+
//#region src/chat/transcript-anchors.d.ts
|
|
2299
|
+
/**
|
|
2300
|
+
* One entry in the partitioned transcript-row list. Single events
|
|
2301
|
+
* render as a normal row; `child-run`s group consecutive subagent
|
|
2302
|
+
* events into one bordered box (the TUI renders one outer container
|
|
2303
|
+
* for the whole run, hence the inner-events array).
|
|
2304
|
+
*
|
|
2305
|
+
* Currently produced by the TUI's `partitionTranscript`; a GUI shell
|
|
2306
|
+
* grouping subagent runs the same way can produce the same shape.
|
|
2307
|
+
*/
|
|
2308
|
+
type TranscriptItem = {
|
|
2309
|
+
kind: 'event';
|
|
2310
|
+
event: StreamEvent;
|
|
2311
|
+
previous?: StreamEvent;
|
|
2312
|
+
} | {
|
|
2313
|
+
kind: 'child-run';
|
|
2314
|
+
events: StreamEvent[];
|
|
2315
|
+
previous?: StreamEvent;
|
|
2316
|
+
};
|
|
2317
|
+
/**
|
|
2318
|
+
* Per-item anchor ids for auto-scroll. Walks `items` in render order
|
|
2319
|
+
* and, for each event, returns either:
|
|
2320
|
+
* - `'turn-anchor-<turnId>'` — the first event of this turn (the
|
|
2321
|
+
* scroll target).
|
|
2322
|
+
* - `undefined` — later event of an already-tagged turn (or a
|
|
2323
|
+
* synthetic event with no `turnId`).
|
|
2324
|
+
*
|
|
2325
|
+
* `ids[i]` is a tuple per item: length 1 for plain events, length N
|
|
2326
|
+
* for subagent runs (one entry per inner event). `idByTurn` is the
|
|
2327
|
+
* inverse lookup used by the scroll effect. `lastTurnId` is the
|
|
2328
|
+
* most-recently-rendered turn — the scroll effect special-cases it to
|
|
2329
|
+
* snap to bottom rather than scroll the anchor into view (which would
|
|
2330
|
+
* stop short of the actual tail).
|
|
2331
|
+
*
|
|
2332
|
+
* Exported so the anchor-tagging matrix can be unit-tested without
|
|
2333
|
+
* rendering anything.
|
|
2334
|
+
*/
|
|
2335
|
+
declare function computeTurnAnchors(items: readonly TranscriptItem[]): {
|
|
2336
|
+
idByTurn: ReadonlyMap<string, string>;
|
|
2337
|
+
ids: readonly (readonly (string | undefined)[])[];
|
|
2338
|
+
lastTurnId: string | undefined;
|
|
2339
|
+
};
|
|
2340
|
+
//#endregion
|
|
2341
|
+
export { Question as $, AgentProfile as $n, EditHunk as $t, SafeModeProvider as A, findActiveTrigger as An, ProviderRegistry as At, ConfirmQuestion as B, ProviderDescriptor as Bn, isVisible as Bt, renderSession as C, CompletionContext as Cn, DiscoveryError as Ct, ApprovalRequest as D, CompletionState as Dn, discoverProjectMcps as Dt, ApprovalDecision as E, CompletionReference as En, defaultMcpsConfigPaths as Et, splitPromptSegments as F, ProviderKey as Fn, createStateStore as Ft, InteractionsProvider as G, getContextWindow as Gn, saveState as Gt, InteractionRequest as H, cerebrasDescriptor as Hn, listSessionMeta as Ht, MarkdownSegment as I, detectAuth as In, deriveSessionTitle as It, PlanDecision as J, modelsForDescriptor as Jn, sumRunCosts as Jt, PRESENT_PLAN_TOOL as K, getModelInfo as Kn, selectableTurnIds as Kt, splitMarkdownCodeBlocks as L, BUILTIN_PROVIDERS as Ln, eventsFromTurns as Lt, useSafeModeQueue as M, useCompletion as Mn, resolveConfig as Mt, PromptSegment as N, AuthMethod as Nn, StateStoreApi as Nt, RequestApproval as O, applyInsert as On, parseMcpsFile as Ot, PromptSegmentRef as P, ProviderAuth as Pn, TuiState as Pt, PlanStep as Q, AgentAccent as Qn, turnSelectionOwnership as Qt, ASK_USER_TOOL as R, ModelInfo as Rn, isEditErrorResult as Rt, SessionExportTarget as S, ActiveTrigger as Sn, DiscoveredMcp as St, writeSessionExport as T, CompletionProvider as Tn, buildMcpServers as Tt, InteractionResponse as U, credKeyOf as Un, loadState as Ut, CreateInteractionToolsOptions as V, anthropicDescriptor as Vn, lastContextSizeFromTurns as Vt, InteractionsActions as W, effectiveContextWindow as Wn, marginTopFor as Wt, PlanRequest as X, openrouterDescriptor as Xn, toolCallPreview as Xt, PlanPayload as Y, openaiDescriptor as Yn, titleFromTurns as Yt, PlanResponse as Z, piIdOf as Zn, toolResultText as Zt, ThemeSurfaces as _, matchesBinding as _n, hintsLength as _t, ToolFormatLine as a, Settings as an, PLAN_AGENT as ar, SelectQuestion as at, SessionExportAnchor as b, readKeybindings as bn, EnabledToggleSet as bt, BUILTIN_THEMES as c, DEFAULT_KEYBINDINGS as cn, singleAgentRegistry as cr, createInteractionTools as ct, DEFAULT_THEME as d, KeyAction as dn, pendingInteractionsFromTurns as dt, EditPayload as en, AgentRegistry as er, QuestionChoice as et, SyntaxStyles as f, KeyBindingDef as fn, serializeInteractionResponse as ft, ThemeSelect as g, keybindingsPath as gn, clipHintsToWidth as gt, ThemeColors as h, ensureKeybindingsFile as hn, Hint as ht, ToolDisplayMeta as i, SessionMeta as in, DEFAULT_PERSIST_EXCLUDE_TOOLS as ir, QuestionType as it, useSafeModeActions as j, mergeReferences as jn, ResolvedConfig as jt, SafeModeActions as k, collectReferences as kn, ChatOptions as kt, ChipColor as l, KEYBINDING_DEFS as ln, isInteractionTool as lt, Theme as m, ParsedBinding as mn, useInteractionsQueue as mt, computeTurnAnchors as n, Picked as nn, BUILTIN_AGENTS as nr, QuestionRequest as nt, displayNameFor as o, StreamEvent as on, accentColor as or, TextQuestion as ot, SyntaxTokenStyle as p, KeyBindings as pn, useInteractionsActions as pt, PendingInteractionEntry as q, modelSupportsReasoning as qn, stripSpawnTokensLine as qt, TOOL_DISPLAY as r, Screen as rn, DEFAULT_AGENT_ID as rr, QuestionResponse as rt, formatToolCall as s, ToolCallDisplay as sn, resolveAgentId as sr, buildResumedToolResultsTurn as st, TranscriptItem as t, Owner as tn, BUILD_AGENT as tr, QuestionPayload as tt, ChipColorMap as u, KEYBINDING_DEF_BY_ACTION as un, makeRequestInteraction as ut, resolveChipColor as v, mergeKeybindings as vn, truncateTrailing as vt, resolveSessionExportTarget as w, CompletionItem as wn, DiscoveryResult as wt, SessionExportFormat as x, stripJsonComments as xn, useEnabledToggleSet as xt, resolveTheme as y, parseBindingSpec as yn, EnabledAllowlistKey as yt, AnswerValue as z, OUTPUT_RESERVE_TOKENS as zn, isTurnHighlighted as zt };
|
|
2342
|
+
//# sourceMappingURL=transcript-anchors-FJMZyLS4.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transcript-anchors-FJMZyLS4.d.ts","names":[],"sources":["../src/chat/agents.ts","../src/chat/providers.ts","../src/chat/auth.ts","../src/chat/completion.ts","../src/chat/keybindings.ts","../src/chat/types.ts","../src/chat/store.ts","../src/chat/config.ts","../src/chat/mcps-discovery.ts","../src/chat/enabled-toggle-set.ts","../src/chat/hints.ts","../src/chat/interactions.tsx","../src/chat/markdown-segments.ts","../src/chat/prompt-segments.ts","../src/chat/safe-mode-context.tsx","../src/chat/session-export.ts","../src/chat/theme.ts","../src/chat/tool-formatters.ts","../src/chat/transcript-anchors.ts"],"mappings":";;;;;;;;;;;;KAyBY,WAAA;;;;;AAuBZ;;;iBAdgB,WAAA,CACd,MAAA,EAAQ,WAAA,cACR,KAAA;EAAS,KAAA;EAAe,MAAA;EAAgB,IAAA;EAAc,KAAA;AAAA;AAAA,UAYvC,YAAA;EAeN;EAbT,EAAA;EAaoB;EAXpB,KAAA;EAcuB;EAZvB,WAAA;EAYkD;;;;;;EALlD,MAAA,EAAQ,MAAA;EAK0C;EAHlD,MAAA,GAAS,WAAA;AAAA;AAAA,KAGC,aAAA,GAAgB,QAAA,CAAS,MAAA,SAAe,YAAA;;;;;AAwFpD;;;;;AAqBA;;;;;AAkBA;;;;;AAMA;cAzGa,6BAAA;;;;AAiHb;;;;;;;;cArDa,WAAA,EAAa,YAAA;;AAwE1B;;;;;cAnDa,UAAA,EAAY,YAAA;;;;;;cAkBZ,cAAA,EAAgB,aAAA;ACrK7B;AAAA,cD2Ka,gBAAA;;;;;;;iBAQG,cAAA,CACd,QAAA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c,QAAA,CAAS,MAAA,SAAe,eAAA;;;;;;;;;;AjB8CnD;;;;;AA4DA;iBiBoHgB,cAAA,CAAe,IAAA;;;;AjB/F/B;;;iBiB6GgB,cAAA,CAAe,IAAA,UAAc,KAAA,EAAO,MAAA,oBAA0B,cAAA;;;;;;;;;AjBnQ9E;;;KkBCY,cAAA;EACJ,IAAA;EAAe,KAAA,EAAO,WAAA;EAAa,QAAA,GAAW,WAAA;AAAA;EAC9C,IAAA;EAAmB,MAAA,EAAQ,WAAA;EAAe,QAAA,GAAW,WAAA;AAAA;;;;;;;AlBoB7D;;;;;;;;;;;;iBkBAgB,kBAAA,CAAmB,KAAA,WAAgB,cAAA;EACjD,QAAA,EAAU,WAAA;EACV,GAAA;EACA,UAAA;AAAA"}
|
package/dist/tui.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Mt as ThinkingLevel, O as SessionData, kt as SessionTurn, x as SkillConfig } from "./agent-
|
|
2
|
-
import {
|
|
1
|
+
import { Mt as ThinkingLevel, O as SessionData, kt as SessionTurn, x as SkillConfig } from "./agent-BuGxYfqh.js";
|
|
2
|
+
import { Bt as isVisible, Ct as DiscoveryError, D as ApprovalRequest, Dn as CompletionState, E as ApprovalDecision, En as CompletionReference, F as splitPromptSegments, Fn as ProviderKey, H as InteractionRequest, I as MarkdownSegment, Kt as selectableTurnIds, L as splitMarkdownCodeBlocks, N as PromptSegment, P as PromptSegmentRef, Pn as ProviderAuth, Qt as turnSelectionOwnership, Rn as ModelInfo, Rt as isEditErrorResult, St as DiscoveredMcp, Tn as CompletionProvider, U as InteractionResponse, Wt as marginTopFor, _t as hintsLength, a as ToolFormatLine, an as Settings, er as AgentRegistry, gt as clipHintsToWidth, h as ThemeColors, ht as Hint, i as ToolDisplayMeta, in as SessionMeta, jt as ResolvedConfig, kt as ChatOptions, m as Theme, n as computeTurnAnchors, o as displayNameFor, on as StreamEvent, or as accentColor, pn as KeyBindings, r as TOOL_DISPLAY, s as formatToolCall, t as TranscriptItem, vt as truncateTrailing, x as SessionExportFormat, yt as EnabledAllowlistKey, zt as isTurnHighlighted } from "./transcript-anchors-FJMZyLS4.js";
|
|
3
3
|
import * as _$react from "react";
|
|
4
4
|
import { ReactNode } from "react";
|
|
5
5
|
import { SyntaxStyle } from "@opentui/core";
|
|
@@ -84,26 +84,6 @@ declare function CompletionPopup({
|
|
|
84
84
|
* the cast so each call site stays readable.
|
|
85
85
|
*/
|
|
86
86
|
declare function onInputSubmit(handler: (value: string) => void): never;
|
|
87
|
-
interface Hint {
|
|
88
|
-
key: string;
|
|
89
|
-
label: string;
|
|
90
|
-
/** Optional override for the key color. Defaults to `COLOR.warn`. */
|
|
91
|
-
keyColor?: string;
|
|
92
|
-
/** Optional override for the label color. Defaults to `COLOR.dim`. */
|
|
93
|
-
labelColor?: string;
|
|
94
|
-
/**
|
|
95
|
-
* Optional secondary chord + value rendered inline after the primary
|
|
96
|
-
* pair: `<key><extra.key> <label> <extra.label>`. Lets one hint advertise
|
|
97
|
-
* a compound shortcut (e.g. `ctrl+m/n model effort`) without forcing
|
|
98
|
-
* callers into a parallel struct or a custom renderer.
|
|
99
|
-
*/
|
|
100
|
-
extra?: {
|
|
101
|
-
key: string;
|
|
102
|
-
label: string; /** Defaults to `COLOR.mute` — the secondary key is rendered dimmer than the primary so the chord reads as one unit. */
|
|
103
|
-
keyColor?: string; /** Defaults to `COLOR.dim`. */
|
|
104
|
-
labelColor?: string;
|
|
105
|
-
};
|
|
106
|
-
}
|
|
107
87
|
interface ContextUsage {
|
|
108
88
|
used: number;
|
|
109
89
|
max: number;
|
|
@@ -245,14 +225,6 @@ declare function TitleOverlay({
|
|
|
245
225
|
*/
|
|
246
226
|
statusIconCells?: 1 | 2;
|
|
247
227
|
}): ReactNode;
|
|
248
|
-
/**
|
|
249
|
-
* Plain-text width estimate for a list of {@link Hint}s rendered via
|
|
250
|
-
* `renderHintSpans` — `<key> <label> · <key> <label> · …`. Exported so
|
|
251
|
-
* the prompt-box overlay (in `screens.tsx`) can run the same responsive
|
|
252
|
-
* math as the bottom-bar footer when deciding whether trigger hints
|
|
253
|
-
* fit. Pure / total.
|
|
254
|
-
*/
|
|
255
|
-
declare function hintsLength(hints: readonly Hint[]): number;
|
|
256
228
|
declare function Spinner({
|
|
257
229
|
label
|
|
258
230
|
}: {
|
|
@@ -366,13 +338,22 @@ declare function McpsSettingsModal({
|
|
|
366
338
|
errors,
|
|
367
339
|
onLogin,
|
|
368
340
|
onLogout,
|
|
369
|
-
onCancelLogin
|
|
341
|
+
onCancelLogin,
|
|
342
|
+
onRefresh
|
|
370
343
|
}: {
|
|
371
344
|
catalog: readonly DiscoveredMcp[];
|
|
372
345
|
errors?: readonly DiscoveryError[];
|
|
373
346
|
onLogin: (name: string) => Promise<void> | void;
|
|
374
347
|
onLogout: (name: string) => void;
|
|
375
348
|
onCancelLogin: (name: string) => void;
|
|
349
|
+
/**
|
|
350
|
+
* Optional force-rescan hook bound to `r` on this standalone modal.
|
|
351
|
+
* Hosts wire it to `discoverProjectMcps` (or the future async
|
|
352
|
+
* registry-aware variant). Unlike `SettingsModal`, here we use
|
|
353
|
+
* plain `r` because there's no search input to swallow the key —
|
|
354
|
+
* matches the single-letter convention of `l` / `o`.
|
|
355
|
+
*/
|
|
356
|
+
onRefresh?: () => Promise<void> | void;
|
|
376
357
|
}): _$react.ReactNode;
|
|
377
358
|
//#endregion
|
|
378
359
|
//#region src/tui/modal.d.ts
|
|
@@ -798,15 +779,36 @@ interface SettingsActions {
|
|
|
798
779
|
onLogoutMcp?: (name: string) => void;
|
|
799
780
|
/** Abort an in-flight MCP OAuth flow. */
|
|
800
781
|
onCancelLoginMcp?: (name: string) => void;
|
|
782
|
+
/**
|
|
783
|
+
* Force a fresh skills rescan, bypassing the background SWR throttle.
|
|
784
|
+
* Fired by `ctrl+R` on the Skills tab. When wired the host should
|
|
785
|
+
* call `discoverProjectSkills` directly and replace the catalog —
|
|
786
|
+
* an in-flight refresh promise resolves into the modal automatically
|
|
787
|
+
* via the catalog prop.
|
|
788
|
+
*/
|
|
789
|
+
onRefreshSkills?: () => Promise<void> | void;
|
|
790
|
+
/**
|
|
791
|
+
* Re-parse the project's `mcps.json` files. Fired by `ctrl+R` on
|
|
792
|
+
* the MCPs tab. Sync-shaped under the hood but typed as async so
|
|
793
|
+
* future discovery paths (registry lookups, etc.) can stay
|
|
794
|
+
* non-blocking without changing the contract.
|
|
795
|
+
*/
|
|
796
|
+
onRefreshMcps?: () => Promise<void> | void;
|
|
801
797
|
}
|
|
802
798
|
declare function SettingsModal({
|
|
803
|
-
skillsCatalog,
|
|
804
|
-
mcpsCatalog,
|
|
805
|
-
mcpsErrors,
|
|
799
|
+
skillsCatalog: skillsCatalogProp,
|
|
800
|
+
mcpsCatalog: mcpsCatalogProp,
|
|
801
|
+
mcpsErrors: mcpsErrorsProp,
|
|
806
802
|
actions
|
|
807
803
|
}?: {
|
|
808
|
-
/**
|
|
809
|
-
|
|
804
|
+
/**
|
|
805
|
+
* Embedder fallback — discovered skills when no `<DiscoveryProvider>`
|
|
806
|
+
* is mounted. In the in-app flow this is ignored; the modal reads
|
|
807
|
+
* live state from `useDiscovery()` so a `ctrl+R` rescan surfaces
|
|
808
|
+
* immediately even with the modal already open.
|
|
809
|
+
*/
|
|
810
|
+
skillsCatalog?: readonly SkillConfig[]; /** Embedder fallback — discovered MCP servers; superseded by context when present. */
|
|
811
|
+
mcpsCatalog?: readonly DiscoveredMcp[]; /** Embedder fallback — `mcps.json` parse errors; superseded by context when present. */
|
|
810
812
|
mcpsErrors?: readonly DiscoveryError[];
|
|
811
813
|
actions?: SettingsActions;
|
|
812
814
|
}): ReactNode;
|
|
@@ -816,11 +818,18 @@ declare function SettingsModal({
|
|
|
816
818
|
* List + toggle modal for discovered skills. State machine + keyboard +
|
|
817
819
|
* row geometry live in `<ToggleListModal>`; this file just supplies the
|
|
818
820
|
* skill-specific column (description) and the empty-state hint.
|
|
821
|
+
*
|
|
822
|
+
* Pass `onRefresh` to expose `ctrl+R` (force re-scan) on the list. The
|
|
823
|
+
* standalone modal is for embedders — the in-app flow goes through
|
|
824
|
+
* `<SettingsModal>` which exposes the same affordance via its own
|
|
825
|
+
* `SettingsActions.onRefreshSkills` plumbing.
|
|
819
826
|
*/
|
|
820
827
|
declare function SkillsSettingsModal({
|
|
821
|
-
catalog
|
|
828
|
+
catalog,
|
|
829
|
+
onRefresh
|
|
822
830
|
}: {
|
|
823
831
|
catalog: readonly SkillConfig[];
|
|
832
|
+
onRefresh?: () => Promise<void> | void;
|
|
824
833
|
}): _$react.ReactNode;
|
|
825
834
|
//#endregion
|
|
826
835
|
//#region src/tui/theme.d.ts
|
|
@@ -867,7 +876,8 @@ declare function ToggleListModal<T>({
|
|
|
867
876
|
title,
|
|
868
877
|
renderDetail,
|
|
869
878
|
emptyState,
|
|
870
|
-
preamble
|
|
879
|
+
preamble,
|
|
880
|
+
onRefresh
|
|
871
881
|
}: {
|
|
872
882
|
catalog: readonly T[];
|
|
873
883
|
keyOf: (entry: T) => string;
|
|
@@ -883,6 +893,12 @@ declare function ToggleListModal<T>({
|
|
|
883
893
|
* renders even when the catalog has entries.
|
|
884
894
|
*/
|
|
885
895
|
preamble?: ReactNode;
|
|
896
|
+
/**
|
|
897
|
+
* Optional force-rescan hook bound to `ctrl+R`. Hosts wire it to a
|
|
898
|
+
* discovery rerun (`discoverProjectSkills`, `discoverProjectMcps`,
|
|
899
|
+
* …); the modal just exposes the keybind and footer hint.
|
|
900
|
+
*/
|
|
901
|
+
onRefresh?: () => Promise<void> | void;
|
|
886
902
|
}): ReactNode;
|
|
887
903
|
//#endregion
|
|
888
904
|
//#region src/tui/turn-details-modal.d.ts
|
|
@@ -956,5 +972,5 @@ declare function TurnDetailsModal({
|
|
|
956
972
|
*/
|
|
957
973
|
declare function runTui(options?: Partial<ChatOptions>): Promise<never>;
|
|
958
974
|
//#endregion
|
|
959
|
-
export { AgentPickerModal, App, AuthScreen, ChatScreen, CompletionPopup, type ContextUsage, EffortPickerModal, Footer, type Hint, InteractionBlock, McpsSettingsModal, type MetaSegment, Modal, type ModalProps, ModalRoot, ModelPickerModal, type PickedModel, type PromptSegment, type PromptSegmentRef, type QueueShortcuts, type QueuedPreview, type SessionCompactResult, SessionDetailsModal, type SessionDetailsModalActions, type SessionExportResult, SessionsScreen, type SettingsActions, SettingsModal, SkillsSettingsModal, Spinner, StatusSpinner, TOOL_DISPLAY, TitleOverlay, ToggleListModal, type ToolDisplayMeta, type ToolFormatLine, Transcript, TurnDetailsModal, type TurnDetailsModalActions, accentColor, buildMdStyle, displayNameFor, formatToolCall, hintsLength, isEditErrorResult, isTurnHighlighted, isVisible, marginTopFor, onInputSubmit, renderHintSpans, runTui, selectableTurnIds, splitPromptSegments, turnSelectionOwnership, useMdStyle, useModal, useModalAwareFocus };
|
|
975
|
+
export { AgentPickerModal, App, AuthScreen, ChatScreen, CompletionPopup, type ContextUsage, EffortPickerModal, Footer, type Hint, InteractionBlock, type MarkdownSegment, McpsSettingsModal, type MetaSegment, Modal, type ModalProps, ModalRoot, ModelPickerModal, type PickedModel, type PromptSegment, type PromptSegmentRef, type QueueShortcuts, type QueuedPreview, type SessionCompactResult, SessionDetailsModal, type SessionDetailsModalActions, type SessionExportResult, SessionsScreen, type SettingsActions, SettingsModal, SkillsSettingsModal, Spinner, StatusSpinner, TOOL_DISPLAY, TitleOverlay, ToggleListModal, type ToolDisplayMeta, type ToolFormatLine, Transcript, type TranscriptItem, TurnDetailsModal, type TurnDetailsModalActions, accentColor, buildMdStyle, clipHintsToWidth, computeTurnAnchors, displayNameFor, formatToolCall, hintsLength, isEditErrorResult, isTurnHighlighted, isVisible, marginTopFor, onInputSubmit, renderHintSpans, runTui, selectableTurnIds, splitMarkdownCodeBlocks, splitPromptSegments, truncateTrailing, turnSelectionOwnership, useMdStyle, useModal, useModalAwareFocus };
|
|
960
976
|
//# sourceMappingURL=tui.d.ts.map
|