@deepseek-harness-tui/dsh-tui 0.20.0 → 0.20.2
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/README.md +18 -3
- package/bin/dsh-tui.js +26 -8
- package/guide/dsh-tui-guide/claude-backend.en.md +6 -5
- package/guide/dsh-tui-guide/claude-backend.md +5 -5
- package/guide/dsh-tui-guide/configuration.en.md +26 -12
- package/guide/dsh-tui-guide/configuration.md +18 -9
- package/guide/dsh-tui-guide/getting-started.en.md +17 -9
- package/guide/dsh-tui-guide/getting-started.md +11 -7
- package/guide/dsh-tui-guide/interaction.en.md +1 -0
- package/guide/dsh-tui-guide/interaction.md +1 -0
- package/guide/dsh-tui-guide/migrate.en.md +5 -0
- package/guide/dsh-tui-guide/migrate.md +4 -0
- package/guide/dsh-tui-guide/plugins.en.md +17 -1
- package/guide/dsh-tui-guide/plugins.md +12 -1
- package/guide/dsh-tui-guide/themes.en.md +1 -1
- package/guide/dsh-tui-guide/themes.md +1 -1
- package/guide/dsh-tui-guide/user-guide.en.md +8 -2
- package/guide/dsh-tui-guide/user-guide.md +8 -2
- package/lib/settings.json +19 -3
- package/lib/types/adapter/kernel/host-facade.d.ts +3 -1
- package/lib/types/adapter/kernel/host-facade.d.ts.map +1 -1
- package/lib/types/adapter/kernel/host-facade.js +6 -0
- package/lib/types/adapter/kernel/runtime.d.ts.map +1 -1
- package/lib/types/adapter/kernel/runtime.js +5 -0
- package/lib/types/adapter/kernel/slices/extensions.d.ts +1 -0
- package/lib/types/adapter/kernel/slices/extensions.d.ts.map +1 -1
- package/lib/types/adapter/kernel/slices/extensions.js +6 -1
- package/lib/types/adapter/kernel/slices/index.d.ts +1 -1
- package/lib/types/adapter/kernel/slices/index.d.ts.map +1 -1
- package/lib/types/adapter/kernel/slices/index.js +3 -2
- package/lib/types/adapter/ports/channel-catalog.d.ts +19 -0
- package/lib/types/adapter/ports/channel-catalog.d.ts.map +1 -1
- package/lib/types/adapter/ports/channel-settings.d.ts +6 -0
- package/lib/types/adapter/ports/channel-settings.d.ts.map +1 -1
- package/lib/types/adapter/ports/channel-view.d.ts +28 -2
- package/lib/types/adapter/ports/channel-view.d.ts.map +1 -1
- package/lib/types/adapter/ports/extensions.d.ts +9 -0
- package/lib/types/adapter/ports/extensions.d.ts.map +1 -1
- package/lib/types/adapter/ports/index.d.ts +1 -1
- package/lib/types/adapter/ports/index.d.ts.map +1 -1
- package/lib/types/adapter/upstream/extensions-driver.d.ts +4 -1
- package/lib/types/adapter/upstream/extensions-driver.d.ts.map +1 -1
- package/lib/types/adapter/upstream/extensions-driver.js +111 -1
- package/lib/types/adapter/upstream/index.d.ts +1 -1
- package/lib/types/adapter/upstream/index.d.ts.map +1 -1
- package/lib/types/adapter/upstream/index.js +1 -1
- package/lib/types/api.d.ts +1 -1
- package/lib/types/api.d.ts.map +1 -1
- package/lib/types/backends/claude/backend.d.ts.map +1 -1
- package/lib/types/backends/claude/backend.js +7 -2
- package/lib/types/backends/claude/session/lifecycle.d.ts.map +1 -1
- package/lib/types/backends/claude/session/lifecycle.js +11 -9
- package/lib/types/backends/claude/side-query.d.ts +2 -0
- package/lib/types/backends/claude/side-query.d.ts.map +1 -1
- package/lib/types/backends/claude/side-query.js +30 -13
- package/lib/types/components/FileSuggestions.d.ts +2 -2
- package/lib/types/components/FileSuggestions.d.ts.map +1 -1
- package/lib/types/components/FileSuggestions.js +25 -5
- package/lib/types/components/PromptInput.d.ts +7 -1
- package/lib/types/components/PromptInput.d.ts.map +1 -1
- package/lib/types/components/PromptInput.js +81 -23
- package/lib/types/components/messages/AssistantToolUseMessage.d.ts +1 -1
- package/lib/types/components/messages/AssistantToolUseMessage.d.ts.map +1 -1
- package/lib/types/components/messages/AssistantToolUseMessage.js +228 -27
- package/lib/types/components/messages/presentCardBackground.d.ts +28 -0
- package/lib/types/components/messages/presentCardBackground.d.ts.map +1 -0
- package/lib/types/components/messages/presentCardBackground.js +23 -0
- package/lib/types/dsh-adapter/backend/translate.d.ts.map +1 -1
- package/lib/types/dsh-adapter/backend/translate.js +28 -1
- package/lib/types/dsh-adapter/channel/core/compose.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/core/files.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/file-actions.d.ts +1 -1
- package/lib/types/dsh-adapter/channel/file-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/file-actions.js +11 -4
- package/lib/types/dsh-adapter/channel/settings-host.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/settings-host.js +78 -12
- package/lib/types/dsh-adapter/channel/state.d.ts +4 -3
- package/lib/types/dsh-adapter/channel/state.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/state.js +4 -3
- package/lib/types/dsh-adapter/channel/types.d.ts +1 -1
- package/lib/types/dsh-adapter/channel/types.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel.d.ts +1 -1
- package/lib/types/dsh-adapter/channel.d.ts.map +1 -1
- package/lib/types/dsh-adapter/childStderr.d.ts +1 -1
- package/lib/types/dsh-adapter/childStderr.d.ts.map +1 -1
- package/lib/types/dsh-adapter/childStderr.js +5 -0
- package/lib/types/dsh-adapter/contract.d.ts +23 -8
- package/lib/types/dsh-adapter/contract.d.ts.map +1 -1
- package/lib/types/dsh-adapter/contract.js +27 -7
- package/lib/types/dsh-adapter/extensions.d.ts +3 -2
- package/lib/types/dsh-adapter/extensions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/extensions.js +5 -2
- package/lib/types/dsh-adapter/host-contract.d.ts +1 -1
- package/lib/types/dsh-adapter/host-contract.js +1 -1
- package/lib/types/dsh-adapter/host-dsh.d.ts +4 -0
- package/lib/types/dsh-adapter/host-dsh.d.ts.map +1 -1
- package/lib/types/dsh-adapter/host-dsh.js +26 -0
- package/lib/types/dsh-adapter/host-entry.js +4 -2
- package/lib/types/dsh-adapter/host-service-diagnostics.d.ts +61 -0
- package/lib/types/dsh-adapter/host-service-diagnostics.d.ts.map +1 -0
- package/lib/types/dsh-adapter/host-service-diagnostics.js +103 -0
- package/lib/types/dsh-adapter/index.d.ts +5 -0
- package/lib/types/dsh-adapter/index.d.ts.map +1 -1
- package/lib/types/dsh-adapter/index.js +1 -0
- package/lib/types/dsh-adapter/mention-providers.d.ts +91 -0
- package/lib/types/dsh-adapter/mention-providers.d.ts.map +1 -0
- package/lib/types/dsh-adapter/mention-providers.js +214 -0
- package/lib/types/dsh-adapter/migrate/entry.d.ts +2 -0
- package/lib/types/dsh-adapter/migrate/entry.d.ts.map +1 -0
- package/lib/types/dsh-adapter/migrate/entry.js +46 -0
- package/lib/types/dsh-adapter/plugin.d.ts.map +1 -1
- package/lib/types/dsh-adapter/plugin.js +42 -2
- package/lib/types/dsh-adapter/present-tool.d.ts +20 -0
- package/lib/types/dsh-adapter/present-tool.d.ts.map +1 -0
- package/lib/types/dsh-adapter/present-tool.js +96 -0
- package/lib/types/extensions.d.ts +2 -0
- package/lib/types/extensions.d.ts.map +1 -1
- package/lib/types/extensions.js +4 -1
- package/lib/types/i18n.d.ts +21 -2
- package/lib/types/i18n.d.ts.map +1 -1
- package/lib/types/i18n.js +9 -1
- package/lib/types/ink/components/ScrollBox.d.ts.map +1 -1
- package/lib/types/ink/components/ScrollBox.js +13 -0
- package/lib/types/ink/dom.d.ts +3 -0
- package/lib/types/ink/dom.d.ts.map +1 -1
- package/lib/types/ink/ink.d.ts.map +1 -1
- package/lib/types/ink/ink.js +30 -34
- package/lib/types/ink/render-node-to-output.d.ts +3 -0
- package/lib/types/ink/render-node-to-output.d.ts.map +1 -1
- package/lib/types/ink/render-node-to-output.js +54 -40
- package/lib/types/ink/selection.d.ts +38 -28
- package/lib/types/ink/selection.d.ts.map +1 -1
- package/lib/types/ink/selection.js +201 -130
- package/lib/types/kernelPrefs.d.ts +5 -2
- package/lib/types/kernelPrefs.d.ts.map +1 -1
- package/lib/types/kernelPrefs.js +5 -2
- package/lib/types/screens/Chat.d.ts +4 -1
- package/lib/types/screens/Chat.d.ts.map +1 -1
- package/lib/types/screens/Chat.js +2 -2
- package/lib/types/settings/definitions.d.ts +12 -0
- package/lib/types/settings/definitions.d.ts.map +1 -1
- package/lib/types/settings/definitions.js +10 -2
- package/lib/types/theme.d.ts +4 -0
- package/lib/types/theme.d.ts.map +1 -1
- package/lib/types/theme.js +20 -2
- package/lib/types/tuiDisplayPrefs.d.ts +3 -0
- package/lib/types/tuiDisplayPrefs.d.ts.map +1 -1
- package/lib/types/tuiDisplayPrefs.js +10 -0
- package/lib/types/update.d.ts +74 -5
- package/lib/types/update.d.ts.map +1 -1
- package/lib/types/update.js +297 -46
- package/lib/types/updateHost.d.ts.map +1 -1
- package/lib/types/updateHost.js +16 -5
- package/lib/types/usageStats.d.ts +6 -0
- package/lib/types/usageStats.d.ts.map +1 -1
- package/lib/types/usageStats.js +8 -0
- package/lib/types/utils/colorMix.d.ts +19 -0
- package/lib/types/utils/colorMix.d.ts.map +1 -0
- package/lib/types/utils/colorMix.js +51 -0
- package/lib/types/utils/commandLine.d.ts +8 -0
- package/lib/types/utils/commandLine.d.ts.map +1 -0
- package/lib/types/utils/commandLine.js +37 -0
- package/lib/types/utils/desktopEntry.d.ts +32 -0
- package/lib/types/utils/desktopEntry.d.ts.map +1 -0
- package/lib/types/utils/desktopEntry.js +302 -0
- package/lib/types/utils/externalEditor.d.ts +2 -5
- package/lib/types/utils/externalEditor.d.ts.map +1 -1
- package/lib/types/utils/externalEditor.js +4 -36
- package/lib/types/utils/fileSuggestions.d.ts +14 -3
- package/lib/types/utils/fileSuggestions.d.ts.map +1 -1
- package/lib/types/utils/fileSuggestions.js +33 -0
- package/lib/types/utils/openExternal.d.ts +9 -0
- package/lib/types/utils/openExternal.d.ts.map +1 -1
- package/lib/types/utils/openExternal.js +87 -3
- package/lib/types/utils/terminalLaunch.d.ts +16 -0
- package/lib/types/utils/terminalLaunch.d.ts.map +1 -0
- package/lib/types/utils/terminalLaunch.js +121 -0
- package/package.json +116 -110
- package/tui-profile/feed/README.md +1 -1
- package/tui-profile/feed/first-party.json +1 -1
|
@@ -95,6 +95,9 @@ export function startSelection(s, col, row, screen) {
|
|
|
95
95
|
s.scrolledOffBelow = [];
|
|
96
96
|
s.virtualAnchorRow = undefined;
|
|
97
97
|
s.virtualFocusRow = undefined;
|
|
98
|
+
s.virtualAnchorCol = undefined;
|
|
99
|
+
s.virtualFocusCol = undefined;
|
|
100
|
+
s.offScreen = undefined;
|
|
98
101
|
s.dragBounds = undefined;
|
|
99
102
|
s.lastPressHadAlt = false;
|
|
100
103
|
s.coveredFingerprint = null;
|
|
@@ -126,6 +129,8 @@ export function updateSelection(s, col, row) {
|
|
|
126
129
|
// the same reset moveFocus does. Without this, the next shift computes
|
|
127
130
|
// rawFocus from a stale pre-motion row.
|
|
128
131
|
s.virtualFocusRow = undefined;
|
|
132
|
+
s.virtualFocusCol = undefined;
|
|
133
|
+
s.offScreen = undefined;
|
|
129
134
|
}
|
|
130
135
|
/**
|
|
131
136
|
* End a drag: clear the dragging flag while keeping anchor/focus so the
|
|
@@ -167,6 +172,9 @@ export function clearSelection(s) {
|
|
|
167
172
|
s.scrolledOffBelow = [];
|
|
168
173
|
s.virtualAnchorRow = undefined;
|
|
169
174
|
s.virtualFocusRow = undefined;
|
|
175
|
+
s.virtualAnchorCol = undefined;
|
|
176
|
+
s.virtualFocusCol = undefined;
|
|
177
|
+
s.offScreen = undefined;
|
|
170
178
|
s.dragBounds = undefined;
|
|
171
179
|
s.lastPressHadAlt = false;
|
|
172
180
|
s.coveredFingerprint = null;
|
|
@@ -448,6 +456,8 @@ export function extendSelection(s, screen, col, row) {
|
|
|
448
456
|
return;
|
|
449
457
|
const span = s.anchorSpan;
|
|
450
458
|
s.virtualFocusRow = undefined;
|
|
459
|
+
s.virtualFocusCol = undefined;
|
|
460
|
+
s.offScreen = undefined;
|
|
451
461
|
let mLo;
|
|
452
462
|
let mHi;
|
|
453
463
|
if (span.kind === 'word') {
|
|
@@ -497,95 +507,121 @@ export function moveFocus(s, col, row) {
|
|
|
497
507
|
// shiftSelection clamp) no longer reflects intent. Anchor stays put so
|
|
498
508
|
// virtualAnchorRow is still valid for its own round-trip.
|
|
499
509
|
s.virtualFocusRow = undefined;
|
|
510
|
+
s.virtualFocusCol = undefined;
|
|
511
|
+
s.offScreen = undefined;
|
|
500
512
|
s.settledRevision += 1;
|
|
501
513
|
}
|
|
502
514
|
/**
|
|
503
|
-
* Shift
|
|
504
|
-
*
|
|
505
|
-
*
|
|
506
|
-
*
|
|
507
|
-
*
|
|
508
|
-
*
|
|
509
|
-
*
|
|
510
|
-
*
|
|
511
|
-
*
|
|
515
|
+
* Shift the selection by dRow, clamped to [minRow, maxRow]. Used by keyboard
|
|
516
|
+
* scroll (PgUp/PgDn/ctrl+u/d/b/f) and by the renderer's selection-follow
|
|
517
|
+
* pass. A released selection moves BOTH ends (text-anchored); a live drag
|
|
518
|
+
* passes moveFocus=false so only the anchor tracks the text and the focus
|
|
519
|
+
* stays under the held pointer. Any point that hits a clamp bound gets its
|
|
520
|
+
* col reset to the full-width edge — its original content scrolled off-screen
|
|
521
|
+
* and was captured by captureScrolledRows. The original column is kept in
|
|
522
|
+
* virtualAnchorCol/virtualFocusCol and restored when a reverse scroll brings
|
|
523
|
+
* that row back.
|
|
524
|
+
*
|
|
525
|
+
* allowClear=false keeps a selection that scrolled fully off-screen: the
|
|
526
|
+
* captured rows stay copyable and a reverse scroll restores the endpoints.
|
|
527
|
+
* The live-drag path uses it so a wheel cannot kill the gesture; the
|
|
528
|
+
* released path also uses it so the user can copy after scrolling away.
|
|
512
529
|
*
|
|
513
|
-
* If both ends overshoot the SAME viewport edge (select text → Home/End/g/G
|
|
514
|
-
* jumps far enough that both are out of view), clear — otherwise both clamp
|
|
515
|
-
* to the same corner cell and a ghost 1-cell highlight lingers, and
|
|
516
|
-
* getSelectedText returns one unrelated char from that corner. Symmetric
|
|
517
|
-
* with shiftSelectionForFollow's top-edge check, but bidirectional: keyboard
|
|
518
|
-
* scroll can jump either way.
|
|
519
530
|
* @param s - the selection state to mutate.
|
|
520
531
|
* @param dRow - signed row offset to shift by.
|
|
521
532
|
* @param minRow - lowest allowed row (viewport top).
|
|
522
533
|
* @param maxRow - highest allowed row (viewport bottom).
|
|
523
534
|
* @param width - screen width, used for the clamp-edge column.
|
|
535
|
+
* @param allowClear - clear when both ends leave the same edge (default true).
|
|
536
|
+
* @param moveFocus - also move focus (false for a live drag).
|
|
524
537
|
*/
|
|
525
|
-
export function shiftSelection(s, dRow, minRow, maxRow, width) {
|
|
526
|
-
if (!s.anchor
|
|
538
|
+
export function shiftSelection(s, dRow, minRow, maxRow, width, allowClear = true, moveFocus = true) {
|
|
539
|
+
if (!s.anchor)
|
|
540
|
+
return;
|
|
541
|
+
if (!s.focus) {
|
|
542
|
+
// A held press has no focus until the first motion, but its text anchor
|
|
543
|
+
// must already follow scrolling without turning a click into a selection.
|
|
544
|
+
shiftAnchor(s, dRow, minRow, maxRow);
|
|
527
545
|
return;
|
|
546
|
+
}
|
|
528
547
|
// Virtual rows track pre-clamp positions so reverse scrolls restore
|
|
529
548
|
// correctly. Without this, clamp(5→0) + shift(+10) = 10, not the true 5,
|
|
530
549
|
// and scrolledOffAbove stays stale (highlight ≠ copy).
|
|
531
550
|
const vAnchor = (s.virtualAnchorRow ?? s.anchor.row) + dRow;
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
(
|
|
551
|
+
// A live drag keeps focus at the mouse: only the anchor tracks the text.
|
|
552
|
+
const vFocus = moveFocus
|
|
553
|
+
? (s.virtualFocusRow ?? s.focus.row) + dRow
|
|
554
|
+
: s.focus.row;
|
|
555
|
+
if (allowClear &&
|
|
556
|
+
((vAnchor < minRow && vFocus < minRow) ||
|
|
557
|
+
(vAnchor > maxRow && vFocus > maxRow))) {
|
|
535
558
|
clearSelection(s);
|
|
536
559
|
return;
|
|
537
560
|
}
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
// Invariant: accumulator length ≤ debt. If the accumulator exceeds debt,
|
|
558
|
-
// the excess is stale — e.g., moveFocus cleared virtualFocusRow without
|
|
559
|
-
// trimming the accumulator, orphaning entries the pop above can never
|
|
560
|
-
// reach because oldDebt was ALREADY 0. Truncate to debt (keeping the
|
|
561
|
-
// newest = closest-to-on-screen entries). Check newDebt (not oldDebt):
|
|
562
|
-
// captureScrolledRows runs BEFORE this shift in the real flow (ink.tsx),
|
|
563
|
-
// so at entry the accumulator is populated but oldDebt is still 0 —
|
|
564
|
-
// that's the normal establish-debt path, not stale.
|
|
565
|
-
if (s.scrolledOffAbove.length > newAboveDebt) {
|
|
566
|
-
// Above pushes newest at END → keep END.
|
|
561
|
+
s.offScreen =
|
|
562
|
+
vAnchor < minRow && vFocus < minRow
|
|
563
|
+
? 'above'
|
|
564
|
+
: vAnchor > maxRow && vFocus > maxRow
|
|
565
|
+
? 'below'
|
|
566
|
+
: undefined;
|
|
567
|
+
// Number of SELECTED rows currently above/below the viewport. The old
|
|
568
|
+
// endpoint-overshoot debt overcounted whenever the selection was shorter
|
|
569
|
+
// than the scroll distance (both endpoints far off-screen), so a reverse
|
|
570
|
+
// scroll popped every captured row even though the selected rows had not
|
|
571
|
+
// re-entered yet. Count the selected span instead.
|
|
572
|
+
const selStart = Math.min(vAnchor, vFocus);
|
|
573
|
+
const selEnd = Math.max(vAnchor, vFocus);
|
|
574
|
+
const aboveRows = Math.max(0, Math.min(selEnd, minRow - 1) - selStart + 1);
|
|
575
|
+
const belowRows = Math.max(0, selEnd - Math.max(selStart, maxRow + 1) + 1);
|
|
576
|
+
// Rows re-enter from the viewport edge in reverse capture order: the
|
|
577
|
+
// NEWEST above entry (END) comes back first, so keep the oldest FRONT
|
|
578
|
+
// rows. Below is symmetric: newest at the FRONT, keep the oldest END.
|
|
579
|
+
if (aboveRows < s.scrolledOffAbove.length) {
|
|
567
580
|
s.scrolledOffAbove =
|
|
568
|
-
|
|
569
|
-
}
|
|
570
|
-
if (s.scrolledOffBelow.length
|
|
571
|
-
|
|
572
|
-
|
|
581
|
+
aboveRows > 0 ? s.scrolledOffAbove.slice(0, aboveRows) : [];
|
|
582
|
+
}
|
|
583
|
+
if (belowRows < s.scrolledOffBelow.length) {
|
|
584
|
+
s.scrolledOffBelow =
|
|
585
|
+
belowRows > 0 ? s.scrolledOffBelow.slice(-belowRows) : [];
|
|
586
|
+
}
|
|
587
|
+
// Restore the pre-clamp column when a reverse scroll brings the point
|
|
588
|
+
// back into the viewport; store it the first time it leaves. Without
|
|
589
|
+
// this, a selection that scrolled fully off and back keeps the edge
|
|
590
|
+
// column and truncates the first/last copied line.
|
|
591
|
+
if (vAnchor < minRow || vAnchor > maxRow) {
|
|
592
|
+
s.virtualAnchorCol ??= s.anchor.col;
|
|
593
|
+
}
|
|
594
|
+
else if (s.virtualAnchorCol !== undefined) {
|
|
595
|
+
s.anchor.col = s.virtualAnchorCol;
|
|
596
|
+
s.virtualAnchorCol = undefined;
|
|
597
|
+
}
|
|
598
|
+
if (moveFocus) {
|
|
599
|
+
if (vFocus < minRow || vFocus > maxRow) {
|
|
600
|
+
s.virtualFocusCol ??= s.focus.col;
|
|
601
|
+
}
|
|
602
|
+
else if (s.virtualFocusCol !== undefined) {
|
|
603
|
+
s.focus.col = s.virtualFocusCol;
|
|
604
|
+
s.virtualFocusCol = undefined;
|
|
605
|
+
}
|
|
573
606
|
}
|
|
574
607
|
// Clamp col depends on which EDGE (not dRow direction): virtual tracking
|
|
575
608
|
// means a top-clamped point can stay top-clamped during a dRow>0 reverse
|
|
576
609
|
// shift — dRow-based clampCol would give it the bottom col.
|
|
577
610
|
const shift = (p, vRow) => {
|
|
578
611
|
if (vRow < minRow)
|
|
579
|
-
return { col: 0, row: minRow };
|
|
612
|
+
return { col: s.fence?.colStart ?? 0, row: minRow };
|
|
580
613
|
if (vRow > maxRow)
|
|
581
|
-
return { col: width - 1, row: maxRow };
|
|
614
|
+
return { col: s.fence?.colEnd ?? width - 1, row: maxRow };
|
|
582
615
|
return { col: p.col, row: vRow };
|
|
583
616
|
};
|
|
584
617
|
s.anchor = shift(s.anchor, vAnchor);
|
|
585
|
-
|
|
618
|
+
if (moveFocus) {
|
|
619
|
+
s.focus = shift(s.focus, vFocus);
|
|
620
|
+
s.virtualFocusRow =
|
|
621
|
+
vFocus < minRow || vFocus > maxRow ? vFocus : undefined;
|
|
622
|
+
}
|
|
586
623
|
s.virtualAnchorRow =
|
|
587
624
|
vAnchor < minRow || vAnchor > maxRow ? vAnchor : undefined;
|
|
588
|
-
s.virtualFocusRow = vFocus < minRow || vFocus > maxRow ? vFocus : undefined;
|
|
589
625
|
// anchorSpan not virtual-tracked: it's for word/line extend-on-drag,
|
|
590
626
|
// irrelevant to the keyboard-scroll round-trip case.
|
|
591
627
|
if (s.anchorSpan) {
|
|
@@ -789,8 +825,9 @@ export function shiftSelectionForViewportTranslation(s, rowDelta, oldTop, oldBot
|
|
|
789
825
|
}
|
|
790
826
|
const rawAnchor = (s.virtualAnchorRow ?? s.anchor.row) + dRow;
|
|
791
827
|
const rawFocus = (s.virtualFocusRow ?? s.focus.row) + dRow;
|
|
792
|
-
if (
|
|
793
|
-
(rawAnchor
|
|
828
|
+
if (s.offScreen === undefined &&
|
|
829
|
+
((rawAnchor < newTop && rawFocus < newTop) ||
|
|
830
|
+
(rawAnchor > newBottom && rawFocus > newBottom))) {
|
|
794
831
|
clearSelection(s);
|
|
795
832
|
return true;
|
|
796
833
|
}
|
|
@@ -835,16 +872,12 @@ export function shiftSelectionForViewportTranslation(s, rowDelta, oldTop, oldBot
|
|
|
835
872
|
* before this frame's paint overwrites it with chrome cells. Growth edges
|
|
836
873
|
* have no band to capture; the shift below just re-widens the clamp.
|
|
837
874
|
*
|
|
838
|
-
* shiftSelection
|
|
839
|
-
*
|
|
840
|
-
*
|
|
841
|
-
*
|
|
842
|
-
*
|
|
843
|
-
*
|
|
844
|
-
* shiftSelection for BOTH drag and released states: with dRow=0 a live drag
|
|
845
|
-
* focus stays at the mouse unless the chrome covered it too, and
|
|
846
|
-
* shiftSelection is the only shift that pops debt on re-widening — the
|
|
847
|
-
* follow path never re-widens, a resize does (pill unmount).
|
|
875
|
+
* shiftSelection then re-clamps the logical endpoints to the new bounds.
|
|
876
|
+
* A box move translates the text anchor; a live focus stays at the pointer
|
|
877
|
+
* unless chrome covered its row. Captured rows are popped only as their
|
|
878
|
+
* selected span actually re-enters. A released, previously visible selection
|
|
879
|
+
* wholly covered by chrome still clears; an already retained off-screen
|
|
880
|
+
* selection survives valid geometry changes.
|
|
848
881
|
*
|
|
849
882
|
* Degenerate bounds are handled explicitly: a collapsed new viewport
|
|
850
883
|
* (innerHeight 0 — chrome taller than the box) clears the selection, an
|
|
@@ -858,7 +891,7 @@ export function shiftSelectionForViewportTranslation(s, rowDelta, oldTop, oldBot
|
|
|
858
891
|
* @param newTop - viewport top after this frame's layout.
|
|
859
892
|
* @param newBottom - viewport bottom after this frame's layout.
|
|
860
893
|
*/
|
|
861
|
-
export function shiftSelectionForViewportResize(s, screen, oldTop, oldBottom, newTop, newBottom) {
|
|
894
|
+
export function shiftSelectionForViewportResize(s, screen, oldTop, oldBottom, newTop, newBottom, boxDeltaY = 0) {
|
|
862
895
|
if (!s.anchor)
|
|
863
896
|
return;
|
|
864
897
|
// Degenerate ranges. A ScrollBox can fully collapse — chrome taller than
|
|
@@ -875,35 +908,28 @@ export function shiftSelectionForViewportResize(s, screen, oldTop, oldBottom, ne
|
|
|
875
908
|
}
|
|
876
909
|
if (oldTop > oldBottom)
|
|
877
910
|
return;
|
|
878
|
-
//
|
|
879
|
-
//
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
s.
|
|
888
|
-
}
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
// strand it before the first motion sets focus.
|
|
901
|
-
const raw = s.virtualAnchorRow ?? s.anchor.row;
|
|
902
|
-
s.anchor = { col: s.anchor.col, row: clamp(raw, newTop, newBottom) };
|
|
903
|
-
s.virtualAnchorRow = raw < newTop || raw > newBottom ? raw : undefined;
|
|
904
|
-
return;
|
|
905
|
-
}
|
|
906
|
-
shiftSelection(s, 0, newTop, newBottom, screen.width);
|
|
911
|
+
// The new viewport expressed in PREVIOUS-frame coordinates. A box move
|
|
912
|
+
// can cover a bottom row even when its screen-space bottom did not move.
|
|
913
|
+
const visibleTop = newTop - boxDeltaY;
|
|
914
|
+
const visibleBottom = newBottom - boxDeltaY;
|
|
915
|
+
const focusOffset = s.isDragging ? -boxDeltaY : 0;
|
|
916
|
+
if (visibleTop > oldTop) {
|
|
917
|
+
captureScrolledRows(s, screen, oldTop, Math.min(oldBottom, visibleTop - 1), 'above', 0, focusOffset);
|
|
918
|
+
}
|
|
919
|
+
if (visibleBottom < oldBottom) {
|
|
920
|
+
captureScrolledRows(s, screen, Math.max(oldTop, visibleBottom + 1), oldBottom, 'below', 0, focusOffset);
|
|
921
|
+
}
|
|
922
|
+
// Only the text origin moves with the box; a live focus remains at the
|
|
923
|
+
// pointer. Feed its untranslated raw row through the same clamp pass so
|
|
924
|
+
// chrome that covers the pointer still cannot enter the copied range.
|
|
925
|
+
if (s.isDragging && s.focus) {
|
|
926
|
+
s.virtualFocusRow = (s.virtualFocusRow ?? s.focus.row) - boxDeltaY;
|
|
927
|
+
}
|
|
928
|
+
// Previously captured, fully off-screen selections survive chrome changes.
|
|
929
|
+
// Keep the existing clear for a released on-screen selection wholly covered
|
|
930
|
+
// by chrome. Re-entering selected rows are popped by shiftSelection's debt,
|
|
931
|
+
// not by viewport growth alone (a far-off selection may not have returned).
|
|
932
|
+
shiftSelection(s, boxDeltaY, newTop, newBottom, screen.width, !s.isDragging && s.offScreen === undefined);
|
|
907
933
|
}
|
|
908
934
|
/**
|
|
909
935
|
* Pick which scroll event a selection belongs to when several ScrollBoxes
|
|
@@ -979,6 +1005,8 @@ export function selectionBounds(s) {
|
|
|
979
1005
|
* @returns true when the cell lies inside the selection range.
|
|
980
1006
|
*/
|
|
981
1007
|
export function isCellSelected(s, col, row) {
|
|
1008
|
+
if (s.offScreen !== undefined)
|
|
1009
|
+
return false;
|
|
982
1010
|
const b = selectionBounds(s);
|
|
983
1011
|
if (!b)
|
|
984
1012
|
return false;
|
|
@@ -1069,6 +1097,12 @@ export function refreshSelectionPane(s, screen, previous) {
|
|
|
1069
1097
|
const reverse = comparePoints(s.anchor, s.focus) > 0;
|
|
1070
1098
|
s.anchor = { ...after.points[reverse ? last : first] };
|
|
1071
1099
|
s.focus = { ...after.points[reverse ? first : last] };
|
|
1100
|
+
// The remapped points are visible again: old clamp columns would
|
|
1101
|
+
// restore a stale column from the pre-resize pane. Rows stay tracked
|
|
1102
|
+
// for the off-screen captured range.
|
|
1103
|
+
s.virtualAnchorCol = undefined;
|
|
1104
|
+
s.virtualFocusCol = undefined;
|
|
1105
|
+
s.offScreen = undefined;
|
|
1072
1106
|
// A completed word/line selection no longer needs the old screen span.
|
|
1073
1107
|
s.anchorSpan = null;
|
|
1074
1108
|
}
|
|
@@ -1086,6 +1120,12 @@ export function refreshSelectionPane(s, screen, previous) {
|
|
|
1086
1120
|
if (point)
|
|
1087
1121
|
point.col = clamp(point.col + delta, span.start, span.end - 1);
|
|
1088
1122
|
}
|
|
1123
|
+
if (s.virtualAnchorCol !== undefined) {
|
|
1124
|
+
s.virtualAnchorCol = clamp(s.virtualAnchorCol + delta, span.start, span.end - 1);
|
|
1125
|
+
}
|
|
1126
|
+
if (s.virtualFocusCol !== undefined) {
|
|
1127
|
+
s.virtualFocusCol = clamp(s.virtualFocusCol + delta, span.start, span.end - 1);
|
|
1128
|
+
}
|
|
1089
1129
|
}
|
|
1090
1130
|
s.fence = { colStart: span.start, colEnd: span.end - 1 };
|
|
1091
1131
|
return changed;
|
|
@@ -1436,30 +1476,41 @@ export function getSelectedText(s, screen) {
|
|
|
1436
1476
|
const { start, end } = b;
|
|
1437
1477
|
const lines = [];
|
|
1438
1478
|
const rows = [];
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1479
|
+
// When both endpoints left the same edge, the clamped start/end are NOT
|
|
1480
|
+
// selected: they now point at new content. The accumulators already hold
|
|
1481
|
+
// the whole selection, so skip the visible read entirely.
|
|
1482
|
+
if (s.offScreen === 'above') {
|
|
1483
|
+
rows.push(...s.scrolledOffAbove);
|
|
1484
|
+
}
|
|
1485
|
+
else if (s.offScreen === 'below') {
|
|
1486
|
+
rows.push(...s.scrolledOffBelow);
|
|
1487
|
+
}
|
|
1488
|
+
else {
|
|
1489
|
+
for (let i = 0; i < s.scrolledOffAbove.length; i++) {
|
|
1490
|
+
rows.push(s.scrolledOffAbove[i]);
|
|
1491
|
+
}
|
|
1492
|
+
for (let row = start.row; row <= end.row; row++) {
|
|
1493
|
+
let rowStart = row === start.row ? start.col : 0;
|
|
1494
|
+
let rowEnd = row === end.row ? end.col : screen.width - 1;
|
|
1495
|
+
// Fence (panel-origin gestures) applies to EVERY row, not just the
|
|
1496
|
+
// endpoints: intermediate rows must not span into the chat column.
|
|
1497
|
+
const pane = paneSpan(s, screen, row);
|
|
1498
|
+
if (s.paneId !== undefined && !pane)
|
|
1499
|
+
continue;
|
|
1500
|
+
const fence = pane ? { colStart: pane.start, colEnd: pane.end - 1 } : s.fence;
|
|
1501
|
+
if (fence !== undefined) {
|
|
1502
|
+
rowStart = Math.max(rowStart, fence.colStart);
|
|
1503
|
+
rowEnd = Math.min(rowEnd, fence.colEnd);
|
|
1504
|
+
if (rowStart > rowEnd)
|
|
1505
|
+
continue;
|
|
1506
|
+
}
|
|
1507
|
+
if (s.paneId !== undefined && (screen.noSelect.subarray(row * screen.width + rowStart, row * screen.width + rowEnd + 1).every(bit => bit === 1) || pane?.excluded?.some(range => range.start <= rowStart && range.end > rowEnd)))
|
|
1455
1508
|
continue;
|
|
1509
|
+
rows.push(extractRowText(screen, row, rowStart, rowEnd, row < end.row || s.scrolledOffBelow.length > 0, s.includeNoSelectCells, s));
|
|
1510
|
+
}
|
|
1511
|
+
for (let i = 0; i < s.scrolledOffBelow.length; i++) {
|
|
1512
|
+
rows.push(s.scrolledOffBelow[i]);
|
|
1456
1513
|
}
|
|
1457
|
-
if (s.paneId !== undefined && (screen.noSelect.subarray(row * screen.width + rowStart, row * screen.width + rowEnd + 1).every(bit => bit === 1) || pane?.excluded?.some(range => range.start <= rowStart && range.end > rowEnd)))
|
|
1458
|
-
continue;
|
|
1459
|
-
rows.push(extractRowText(screen, row, rowStart, rowEnd, row < end.row || s.scrolledOffBelow.length > 0, s.includeNoSelectCells, s));
|
|
1460
|
-
}
|
|
1461
|
-
for (let i = 0; i < s.scrolledOffBelow.length; i++) {
|
|
1462
|
-
rows.push(s.scrolledOffBelow[i]);
|
|
1463
1514
|
}
|
|
1464
1515
|
for (const row of resolveCopyRegions(rows))
|
|
1465
1516
|
joinRows(lines, row.text, row.sw);
|
|
@@ -1485,14 +1536,28 @@ export function getSelectedText(s, screen) {
|
|
|
1485
1536
|
* @param firstRow - first viewport row that is about to scroll out.
|
|
1486
1537
|
* @param lastRow - last viewport row that is about to scroll out.
|
|
1487
1538
|
* @param side - which viewport edge the rows scroll out of.
|
|
1539
|
+
* @param screenRowOffset - capture rows minus this offset index the previous screen.
|
|
1540
|
+
* @param focusRowOffset - map a screen-local drag focus back across the pending shift.
|
|
1488
1541
|
*/
|
|
1489
|
-
export function captureScrolledRows(s, screen, firstRow, lastRow, side, screenRowOffset = 0) {
|
|
1490
|
-
|
|
1491
|
-
if (!b || firstRow > lastRow)
|
|
1542
|
+
export function captureScrolledRows(s, screen, firstRow, lastRow, side, screenRowOffset = 0, focusRowOffset = 0) {
|
|
1543
|
+
if (!s.anchor || !s.focus || firstRow > lastRow)
|
|
1492
1544
|
return;
|
|
1493
|
-
|
|
1494
|
-
//
|
|
1495
|
-
//
|
|
1545
|
+
// Capture the logical endpoints, not their viewport-edge placeholders.
|
|
1546
|
+
// A live drag keeps focus screen-local: mapping its NEW extent back to
|
|
1547
|
+
// this frame's outgoing rows also includes content past the old focus.
|
|
1548
|
+
const anchor = {
|
|
1549
|
+
col: s.virtualAnchorCol ?? s.anchor.col,
|
|
1550
|
+
row: s.virtualAnchorRow ?? s.anchor.row,
|
|
1551
|
+
};
|
|
1552
|
+
const focus = {
|
|
1553
|
+
col: s.virtualFocusCol ?? s.focus.col,
|
|
1554
|
+
row: (s.virtualFocusRow ?? s.focus.row) + focusRowOffset,
|
|
1555
|
+
};
|
|
1556
|
+
const forward = comparePoints(anchor, focus) <= 0;
|
|
1557
|
+
const start = forward ? anchor : focus;
|
|
1558
|
+
const end = forward ? focus : anchor;
|
|
1559
|
+
// Only rows selected AFTER the movement belong in the outgoing capture.
|
|
1560
|
+
// This also handles a live drag reversing direction across its anchor.
|
|
1496
1561
|
const lo = Math.max(firstRow, start.row);
|
|
1497
1562
|
const hi = Math.min(lastRow, end.row);
|
|
1498
1563
|
if (lo > hi)
|
|
@@ -1520,7 +1585,8 @@ export function captureScrolledRows(s, screen, firstRow, lastRow, side, screenRo
|
|
|
1520
1585
|
// dragging down) is now pointing at content that will scroll out; its
|
|
1521
1586
|
// col constraint was applied to the captured row. Reset to the pane edge so
|
|
1522
1587
|
// the NEXT tick and the final getSelectedText read the full row.
|
|
1523
|
-
if (
|
|
1588
|
+
if (anchor.row === start.row && lo === start.row) {
|
|
1589
|
+
s.virtualAnchorCol ??= anchor.col;
|
|
1524
1590
|
s.anchor = { col: edgeLo, row: s.anchor.row };
|
|
1525
1591
|
if (s.anchorSpan) {
|
|
1526
1592
|
s.anchorSpan = {
|
|
@@ -1535,7 +1601,8 @@ export function captureScrolledRows(s, screen, firstRow, lastRow, side, screenRo
|
|
|
1535
1601
|
// Newest rows go at the TOP of the below-accumulator — they're
|
|
1536
1602
|
// closest to the on-screen content.
|
|
1537
1603
|
s.scrolledOffBelow.unshift(...captured);
|
|
1538
|
-
if (
|
|
1604
|
+
if (anchor.row === end.row && hi === end.row) {
|
|
1605
|
+
s.virtualAnchorCol ??= anchor.col;
|
|
1539
1606
|
s.anchor = { col: edgeHi, row: s.anchor.row };
|
|
1540
1607
|
if (s.anchorSpan) {
|
|
1541
1608
|
s.anchorSpan = {
|
|
@@ -1594,6 +1661,8 @@ function selectedRowColumns(screen, selection, row, start, end) {
|
|
|
1594
1661
|
* content is found. Wide glyphs use their head cell, as text copying does.
|
|
1595
1662
|
*/
|
|
1596
1663
|
export function getSelectionCursor(screen, selection) {
|
|
1664
|
+
if (selection.offScreen !== undefined)
|
|
1665
|
+
return null;
|
|
1597
1666
|
const bounds = selectionBounds(selection);
|
|
1598
1667
|
if (bounds === null)
|
|
1599
1668
|
return null;
|
|
@@ -1637,6 +1706,8 @@ export function getSelectionCursor(screen, selection) {
|
|
|
1637
1706
|
* @param stylePool - the style pool providing the selection background.
|
|
1638
1707
|
*/
|
|
1639
1708
|
export function applySelectionOverlay(screen, selection, stylePool, images = []) {
|
|
1709
|
+
if (selection.offScreen !== undefined)
|
|
1710
|
+
return;
|
|
1640
1711
|
const b = selectionBounds(selection);
|
|
1641
1712
|
if (!b)
|
|
1642
1713
|
return;
|
|
@@ -47,9 +47,12 @@ export declare function writeKernelPrefs(data: KernelPrefsData, file?: string, d
|
|
|
47
47
|
* config > env > remembered choice.
|
|
48
48
|
*/
|
|
49
49
|
export declare const KERNEL_SWITCH_HANDOFF_ENV = "DSH_TUI_BACKEND_HANDOFF";
|
|
50
|
-
/** The entry's path, set by the launcher:
|
|
51
|
-
*
|
|
50
|
+
/** The entry's path, set by the launcher: replacements relaunch through it
|
|
51
|
+
* unless an ordinary restart stays on the entry's delegated DSH path. */
|
|
52
52
|
export declare const HOST_ENTRY_PATH_ENV = "DSH_TUI_HOST_ENTRY_PATH";
|
|
53
|
+
/** The entry delegated to DSH: /restart replays that process directly rather
|
|
54
|
+
* than accumulating an entry supervisor that would delegate again. */
|
|
55
|
+
export declare const HOST_ENTRY_DELEGATED_ENV = "DSH_TUI_HOST_DELEGATED";
|
|
53
56
|
export declare function hostEntryDisabled(env?: NodeJS.ProcessEnv): boolean;
|
|
54
57
|
/** Why the entry could not use the installed dsh; set by the entry, read and
|
|
55
58
|
* cleared once by the runtime (plugin.ts), also in a delegated `dsh --profile`. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"kernelPrefs.d.ts","sourceRoot":"","sources":["../../src/kernelPrefs.ts"],"names":[],"mappings":"AAcA,OAAO,EAAqB,KAAK,SAAS,EAAE,MAAM,6BAA6B,CAAA;AAG/E;;;;;;;GAOG;AACH,eAAO,MAAM,mBAAmB,qCAAsC,CAAA;AAEtE;;;;;;;;;GASG;AACH,MAAM,MAAM,eAAe,GAAG,SAAS,CAAA;AAEvC;2EAC2E;AAC3E,eAAO,MAAM,cAAc,EAAY,eAAe,CAAA;AAEtD;;;;;;GAMG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,OAAO,GAAG,eAAe,GAAG,SAAS,CAI1E;AAED,oBAAoB;AACpB,MAAM,WAAW,eAAe;IAC9B,QAAQ,CAAC,OAAO,CAAC,EAAE,eAAe,CAAA;CACnC;AASD,mFAAmF;AACnF,wBAAgB,eAAe,CAAC,IAAI,GAAE,MAAsC,GAAG,eAAe,CAM7F;AAuBD,sFAAsF;AACtF,wBAAgB,gBAAgB,CAC9B,IAAI,EAAE,eAAe,EACrB,IAAI,GAAE,MAAsC,EAC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EAAmE;IACnE,QAAQ,CAAC,aAAa,EAAE,eAAe,CAAA;IACvC,yEAAyE;IACzE,QAAQ,CAAC,KAAK,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;CACrC,GAAG,YAAY,CAOf"}
|
package/lib/types/kernelPrefs.js
CHANGED
|
@@ -109,9 +109,12 @@ export const KERNEL_SWITCH_HANDOFF_ENV = 'DSH_TUI_BACKEND_HANDOFF';
|
|
|
109
109
|
* `DSH_TUI_HOST_ENTRY=0` keeps every kernel on `dsh --profile`.
|
|
110
110
|
*/
|
|
111
111
|
const HOST_ENTRY_ENV = 'DSH_TUI_HOST_ENTRY';
|
|
112
|
-
/** The entry's path, set by the launcher:
|
|
113
|
-
*
|
|
112
|
+
/** The entry's path, set by the launcher: replacements relaunch through it
|
|
113
|
+
* unless an ordinary restart stays on the entry's delegated DSH path. */
|
|
114
114
|
export const HOST_ENTRY_PATH_ENV = 'DSH_TUI_HOST_ENTRY_PATH';
|
|
115
|
+
/** The entry delegated to DSH: /restart replays that process directly rather
|
|
116
|
+
* than accumulating an entry supervisor that would delegate again. */
|
|
117
|
+
export const HOST_ENTRY_DELEGATED_ENV = 'DSH_TUI_HOST_DELEGATED';
|
|
115
118
|
export function hostEntryDisabled(env = process.env) {
|
|
116
119
|
return env[HOST_ENTRY_ENV] === '0';
|
|
117
120
|
}
|
|
@@ -5,6 +5,7 @@ import { TuiDialogStore } from '../dsh-adapter/dialogs.js';
|
|
|
5
5
|
import { TuiStatusStore } from '../dsh-adapter/status.js';
|
|
6
6
|
import { ActivityStore } from '../dsh-adapter/activity-store.js';
|
|
7
7
|
import type { TuiShortcutHost } from '../dsh-adapter/shortcuts.js';
|
|
8
|
+
import type { TuiMentionHost } from '../dsh-adapter/mention-providers.js';
|
|
8
9
|
import type { TuiThemeHost } from '../dsh-adapter/themes.js';
|
|
9
10
|
import { type PermissionPanelSource } from '../channel/permissions.js';
|
|
10
11
|
import { type StarAttempt } from '../components/StarPrompt.js';
|
|
@@ -17,7 +18,7 @@ import type { PluginManageFlow, PluginManageSink } from '../dsh-adapter/plugin-m
|
|
|
17
18
|
import type { TeamCommandSink } from '../dsh-adapter/team-mode.js';
|
|
18
19
|
import type { KernelEntry, KernelStatus } from '../components/kernelCatalog.js';
|
|
19
20
|
import type { KernelBackendId } from '../kernelPrefs.js';
|
|
20
|
-
export declare function Chat({ channel, questionStore, approvalStore, extensionDialogs, bonusNotices, extensionStatus, activityStore, extensionShortcuts, themeHost, onExit, onUpdate, onRestart, onSwitchBackend, onRestartFreshSession, onProbeKernels, kernelEntries, onResolveSdkInstall, onPluginInstall, onPluginManage, onTeamCommand, kernelPinned, fullscreen, trajectorySeen: trajectorySeenProp, injectControllerRef, promptControllerRef: promptControllerRefProp, renderScene, openHomeOnBoot, launchpadOnBoot, onboardingOnBoot, starPrompt, }: {
|
|
21
|
+
export declare function Chat({ channel, questionStore, approvalStore, extensionDialogs, bonusNotices, extensionStatus, activityStore, extensionShortcuts, extensionMentions, themeHost, onExit, onUpdate, onRestart, onSwitchBackend, onRestartFreshSession, onProbeKernels, kernelEntries, onResolveSdkInstall, onPluginInstall, onPluginManage, onTeamCommand, kernelPinned, fullscreen, trajectorySeen: trajectorySeenProp, injectControllerRef, promptControllerRef: promptControllerRefProp, renderScene, openHomeOnBoot, launchpadOnBoot, onboardingOnBoot, starPrompt, }: {
|
|
21
22
|
channel: Channel;
|
|
22
23
|
renderScene?: (id: string, channel: Channel) => React.ReactNode;
|
|
23
24
|
questionStore: QuestionStore;
|
|
@@ -43,6 +44,8 @@ export declare function Chat({ channel, questionStore, approvalStore, extensionD
|
|
|
43
44
|
activityStore?: ActivityStore;
|
|
44
45
|
/** Host-only keyboard shortcut dispatch path. */
|
|
45
46
|
extensionShortcuts?: TuiShortcutHost;
|
|
47
|
+
/** Plugin `@` completion providers; absent, `@` completes files only. */
|
|
48
|
+
extensionMentions?: TuiMentionHost;
|
|
46
49
|
/** Optional runtime theme host; static JSON themes work without it. */
|
|
47
50
|
themeHost?: T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ACH,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB;;;;;;OAMG;IACH,mBAAmB,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC,gBAAgB,GAAG,IAAI,CAAC,CAAA;IAC9D;;;;;;;OAOG;IACH,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB;;;;;;;;;;OAUG;IACH,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB;;;;;;;OAOG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B;;;;;;OAMG;IACH,UAAU,CAAC,EAAE;QAAE,GAAG,CAAC,EAAE,MAAM,CAAC;QAAC,MAAM,CAAC,EAAE,MAAM,WAAW,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;QAAC,MAAM,CAAC,EAAE,MAAM,IAAI,CAAA;KAAE,GAAG,IAAI,CAAA;IAC5G;;;;OAIG;IACH,mBAAmB,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC,gBAAgB,GAAG,IAAI,CAAC,CAAA;CAC/D,mBAy1NA"}
|
|
@@ -348,7 +348,7 @@ function peekKey(image, title) {
|
|
|
348
348
|
}
|
|
349
349
|
/** Distinguishes reveal keyspaces of concurrently mounted Chat roots. */
|
|
350
350
|
let revealRootSequence = 0;
|
|
351
|
-
export function Chat({ channel, questionStore, approvalStore, extensionDialogs, bonusNotices, extensionStatus, activityStore, extensionShortcuts, themeHost, onExit, onUpdate, onRestart, onSwitchBackend, onRestartFreshSession, onProbeKernels, kernelEntries = EMPTY_KERNEL_ENTRIES, onResolveSdkInstall, onPluginInstall, onPluginManage, onTeamCommand, kernelPinned, fullscreen = false, trajectorySeen: trajectorySeenProp, injectControllerRef, promptControllerRef: promptControllerRefProp, renderScene, openHomeOnBoot, launchpadOnBoot, onboardingOnBoot, starPrompt, }) {
|
|
351
|
+
export function Chat({ channel, questionStore, approvalStore, extensionDialogs, bonusNotices, extensionStatus, activityStore, extensionShortcuts, extensionMentions, themeHost, onExit, onUpdate, onRestart, onSwitchBackend, onRestartFreshSession, onProbeKernels, kernelEntries = EMPTY_KERNEL_ENTRIES, onResolveSdkInstall, onPluginInstall, onPluginManage, onTeamCommand, kernelPinned, fullscreen = false, trajectorySeen: trajectorySeenProp, injectControllerRef, promptControllerRef: promptControllerRefProp, renderScene, openHomeOnBoot, launchpadOnBoot, onboardingOnBoot, starPrompt, }) {
|
|
352
352
|
const { internal_eventEmitter: inputEmitter } = useStdin();
|
|
353
353
|
const writeRaw = React.useContext(TerminalWriteContext);
|
|
354
354
|
// Re-render whenever the channel mutates; rows/status are read fresh below.
|
|
@@ -6628,7 +6628,7 @@ export function Chat({ channel, questionStore, approvalStore, extensionDialogs,
|
|
|
6628
6628
|
void setClipboard(answer).then(raw => { if (raw)
|
|
6629
6629
|
writeRaw?.(raw); });
|
|
6630
6630
|
channel.notify(t('copied-chars', { n: answer.length }), { timeoutMs: 1500 });
|
|
6631
|
-
} }) })) : questionPanelNode !== null ? (questionPanelNode) : null, _jsx(PromptInput, { channel: channel, suspended: promptReplacementOpen,
|
|
6631
|
+
} }) })) : questionPanelNode !== null ? (questionPanelNode) : null, _jsx(PromptInput, { channel: channel, mentionProviders: extensionMentions, suspended: promptReplacementOpen,
|
|
6632
6632
|
// 选择器、搜索框或侧栏持有键盘焦点时,让对应输入框接管原生
|
|
6633
6633
|
// 光标与 IME 锚点,避免主输入框在后续提交中抢回声明。
|
|
6634
6634
|
cursorParking: overlay.kind === 'none' && sidePanel.focus !== 'panel',
|
|
@@ -330,6 +330,18 @@ export declare const SETTING_DEFINITIONS: {
|
|
|
330
330
|
};
|
|
331
331
|
kind: "boolean";
|
|
332
332
|
};
|
|
333
|
+
nerdFontIcons: {
|
|
334
|
+
label: string;
|
|
335
|
+
descriptions: {
|
|
336
|
+
zh: string;
|
|
337
|
+
};
|
|
338
|
+
group: string;
|
|
339
|
+
hint: string;
|
|
340
|
+
hintDescriptions: {
|
|
341
|
+
zh: string;
|
|
342
|
+
};
|
|
343
|
+
kind: "boolean";
|
|
344
|
+
};
|
|
333
345
|
notificationMethod: {
|
|
334
346
|
label: string;
|
|
335
347
|
descriptions: {
|