tmux-ide 2.9.0-beta.39 → 2.9.0-beta.40
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/bin/cli.js +1 -1
- package/package.json +1 -1
- package/packages/daemon/dist/tui/mirror/runtime/application-machine-sidebar.jsx +2 -14
- package/packages/daemon/src/tui/mirror/runtime/application-machine-sidebar.tsx +3 -17
- package/packages/daemon/src/tui/mirror/runtime/application-palette-command-owner.ts +1 -1
- package/packages/daemon/src/tui/mirror/runtime/application-reference-sheet.tsx +55 -4
- package/packages/daemon/src/tui/mirror/runtime/application-shell-catalog.tsx +6 -2
- package/packages/daemon/src/tui/mirror/runtime/application-shell-overlays.tsx +4 -4
- package/packages/daemon/src/tui/mirror/runtime/application-shell-view.tsx +6 -2
package/bin/cli.js
CHANGED
|
@@ -11279,7 +11279,7 @@ var require_package = __commonJS({
|
|
|
11279
11279
|
"package.json"(exports, module) {
|
|
11280
11280
|
module.exports = {
|
|
11281
11281
|
name: "tmux-ide",
|
|
11282
|
-
version: "2.9.0-beta.
|
|
11282
|
+
version: "2.9.0-beta.40",
|
|
11283
11283
|
description: "A visual, agent-aware IDE for any tmux session, with optional workspace presets",
|
|
11284
11284
|
type: "module",
|
|
11285
11285
|
bin: {
|
package/package.json
CHANGED
|
@@ -12,7 +12,6 @@ import { Surface } from "../ui/surface.jsx";
|
|
|
12
12
|
import { useKeyboardRoute } from "../ui/keyboard-router.jsx";
|
|
13
13
|
/** Pure machine navigation. All connection and session authority stays with the caller. */
|
|
14
14
|
export function ApplicationMachineSidebar(props) {
|
|
15
|
-
const [showHelp, setShowHelp] = createSignal(false);
|
|
16
15
|
const [localFocused, setLocalFocused] = createSignal(false);
|
|
17
16
|
const focused = () => props.model.focused?.() ?? localFocused();
|
|
18
17
|
const [localCollapsed, setCollapsed] = createSignal(new Set());
|
|
@@ -31,14 +30,12 @@ export function ApplicationMachineSidebar(props) {
|
|
|
31
30
|
const start = Math.max(0, active - tabHeight() + 1);
|
|
32
31
|
return tabs.slice(start, start + tabHeight());
|
|
33
32
|
};
|
|
34
|
-
const helpHeight = () => showHelp() ? Math.min(5, Math.max(0, Math.floor(props.height / 3))) : 0;
|
|
35
33
|
const machineHeight = () => Math.max(0, props.height -
|
|
36
34
|
1 -
|
|
37
35
|
(props.model.onAddMachine ? 1 : 0) -
|
|
38
36
|
agentHeight() -
|
|
39
37
|
controlsHeight() -
|
|
40
38
|
searchHeight() -
|
|
41
|
-
helpHeight() -
|
|
42
39
|
tabHeight());
|
|
43
40
|
const active = (row) => row.group.id === props.model.activeMachineId() &&
|
|
44
41
|
(row.agent
|
|
@@ -238,7 +235,7 @@ export function ApplicationMachineSidebar(props) {
|
|
|
238
235
|
event.preventDefault();
|
|
239
236
|
event.stopPropagation();
|
|
240
237
|
if (key === "help") {
|
|
241
|
-
|
|
238
|
+
props.onHelp?.("keyboard");
|
|
242
239
|
return true;
|
|
243
240
|
}
|
|
244
241
|
if (key === "search") {
|
|
@@ -246,10 +243,6 @@ export function ApplicationMachineSidebar(props) {
|
|
|
246
243
|
return true;
|
|
247
244
|
}
|
|
248
245
|
if (key === "escape") {
|
|
249
|
-
if (showHelp()) {
|
|
250
|
-
setShowHelp(false);
|
|
251
|
-
return true;
|
|
252
|
-
}
|
|
253
246
|
setLocalFocused(false);
|
|
254
247
|
props.model.onBlur?.();
|
|
255
248
|
return true;
|
|
@@ -309,7 +302,7 @@ export function ApplicationMachineSidebar(props) {
|
|
|
309
302
|
<Show when={props.model.tabs?.().length && props.width >= 28}>
|
|
310
303
|
<KeyHint theme={props.theme} keys="F9" label="Tabs" quiet/>
|
|
311
304
|
</Show>
|
|
312
|
-
<KeyHint theme={props.theme} keys="?" label={props.width >= 20 ? "Help" : undefined} quiet button onPress={() =>
|
|
305
|
+
<KeyHint theme={props.theme} keys="?" label={props.width >= 20 ? "Help" : undefined} quiet button onPress={() => props.onHelp?.("mouse")}/>
|
|
313
306
|
</box>
|
|
314
307
|
<For each={visibleTabs()}>
|
|
315
308
|
{(tab) => (<box height={1} flexDirection="row">
|
|
@@ -416,11 +409,6 @@ export function ApplicationMachineSidebar(props) {
|
|
|
416
409
|
{props.agents}
|
|
417
410
|
</scrollbox>)}
|
|
418
411
|
</For>
|
|
419
|
-
<Show when={helpHeight() > 0}>
|
|
420
|
-
<text height={helpHeight()} fg={props.theme.roles.text.secondary}>
|
|
421
|
-
{"j/k ↑↓ move · g/G ends\nPgUp/Dn · Ctrl-U/D half\nh/l ←→ collapse/expand\nEnter open · / search\nf favorite · Esc terminal"}
|
|
422
|
-
</text>
|
|
423
|
-
</Show>
|
|
424
412
|
<Show when={props.model.onOpenSwitcher}>
|
|
425
413
|
<KeyHint theme={props.theme} keys="F6" label="Sessions" width={props.width} quiet button onPress={() => props.model.onOpenSwitcher?.()}/>
|
|
426
414
|
</Show>
|
|
@@ -117,8 +117,8 @@ export function ApplicationMachineSidebar(props: {
|
|
|
117
117
|
readonly theme: SemanticThemeSnapshot;
|
|
118
118
|
readonly agents?: JSX.Element;
|
|
119
119
|
readonly agentRows?: number;
|
|
120
|
+
readonly onHelp?: (source: "keyboard" | "mouse") => void;
|
|
120
121
|
}) {
|
|
121
|
-
const [showHelp, setShowHelp] = createSignal(false);
|
|
122
122
|
const [localFocused, setLocalFocused] = createSignal(false);
|
|
123
123
|
const focused = () => props.model.focused?.() ?? localFocused();
|
|
124
124
|
const [localCollapsed, setCollapsed] = createSignal<ReadonlySet<string>>(new Set());
|
|
@@ -141,8 +141,6 @@ export function ApplicationMachineSidebar(props: {
|
|
|
141
141
|
const start = Math.max(0, active - tabHeight() + 1);
|
|
142
142
|
return tabs.slice(start, start + tabHeight());
|
|
143
143
|
};
|
|
144
|
-
const helpHeight = () =>
|
|
145
|
-
showHelp() ? Math.min(5, Math.max(0, Math.floor(props.height / 3))) : 0;
|
|
146
144
|
const machineHeight = () =>
|
|
147
145
|
Math.max(
|
|
148
146
|
0,
|
|
@@ -152,7 +150,6 @@ export function ApplicationMachineSidebar(props: {
|
|
|
152
150
|
agentHeight() -
|
|
153
151
|
controlsHeight() -
|
|
154
152
|
searchHeight() -
|
|
155
|
-
helpHeight() -
|
|
156
153
|
tabHeight(),
|
|
157
154
|
);
|
|
158
155
|
const active = (row: Row) =>
|
|
@@ -378,7 +375,7 @@ export function ApplicationMachineSidebar(props: {
|
|
|
378
375
|
event.preventDefault();
|
|
379
376
|
event.stopPropagation();
|
|
380
377
|
if (key === "help") {
|
|
381
|
-
|
|
378
|
+
props.onHelp?.("keyboard");
|
|
382
379
|
return true;
|
|
383
380
|
}
|
|
384
381
|
if (key === "search") {
|
|
@@ -386,10 +383,6 @@ export function ApplicationMachineSidebar(props: {
|
|
|
386
383
|
return true;
|
|
387
384
|
}
|
|
388
385
|
if (key === "escape") {
|
|
389
|
-
if (showHelp()) {
|
|
390
|
-
setShowHelp(false);
|
|
391
|
-
return true;
|
|
392
|
-
}
|
|
393
386
|
setLocalFocused(false);
|
|
394
387
|
props.model.onBlur?.();
|
|
395
388
|
return true;
|
|
@@ -471,7 +464,7 @@ export function ApplicationMachineSidebar(props: {
|
|
|
471
464
|
label={props.width >= 20 ? "Help" : undefined}
|
|
472
465
|
quiet
|
|
473
466
|
button
|
|
474
|
-
onPress={() =>
|
|
467
|
+
onPress={() => props.onHelp?.("mouse")}
|
|
475
468
|
/>
|
|
476
469
|
</box>
|
|
477
470
|
<For each={visibleTabs()}>
|
|
@@ -657,13 +650,6 @@ export function ApplicationMachineSidebar(props: {
|
|
|
657
650
|
</scrollbox>
|
|
658
651
|
)}
|
|
659
652
|
</For>
|
|
660
|
-
<Show when={helpHeight() > 0}>
|
|
661
|
-
<text height={helpHeight()} fg={props.theme.roles.text.secondary}>
|
|
662
|
-
{
|
|
663
|
-
"j/k ↑↓ move · g/G ends\nPgUp/Dn · Ctrl-U/D half\nh/l ←→ collapse/expand\nEnter open · / search\nf favorite · Esc terminal"
|
|
664
|
-
}
|
|
665
|
-
</text>
|
|
666
|
-
</Show>
|
|
667
653
|
<Show when={props.model.onOpenSwitcher}>
|
|
668
654
|
<KeyHint
|
|
669
655
|
theme={props.theme}
|
|
@@ -39,7 +39,7 @@ export function createApplicationPaletteCommandOwner(options: {
|
|
|
39
39
|
readonly disabledReason?: (command: ApplicationPaletteCommand) => string | null;
|
|
40
40
|
readonly targetKey?: () => string;
|
|
41
41
|
}) {
|
|
42
|
-
const [referencePage, setReferencePage] = createSignal<"shortcuts" | "changes">();
|
|
42
|
+
const [referencePage, setReferencePage] = createSignal<"shortcuts" | "changes" | "help">();
|
|
43
43
|
const [closeArmed, setCloseArmed] = createSignal(false);
|
|
44
44
|
const [busy, setBusy] = createSignal(false);
|
|
45
45
|
let armedTarget: string | undefined;
|
|
@@ -44,7 +44,7 @@ const releases = [
|
|
|
44
44
|
type Row = { kind: "heading" | "text" | "action" | "gap"; label: string; detail?: string };
|
|
45
45
|
|
|
46
46
|
export function ApplicationReferenceSheet(props: {
|
|
47
|
-
page: "shortcuts" | "changes";
|
|
47
|
+
page: "shortcuts" | "changes" | "help";
|
|
48
48
|
width: number;
|
|
49
49
|
height: number;
|
|
50
50
|
theme: SemanticThemeSnapshot;
|
|
@@ -78,7 +78,48 @@ export function ApplicationReferenceSheet(props: {
|
|
|
78
78
|
}
|
|
79
79
|
if (!result.length) result.push({ kind: "text", label: "No matching shortcuts" });
|
|
80
80
|
} else {
|
|
81
|
-
|
|
81
|
+
const sections =
|
|
82
|
+
page() === "help"
|
|
83
|
+
? [
|
|
84
|
+
{
|
|
85
|
+
version: "Find your work",
|
|
86
|
+
lines: [
|
|
87
|
+
"Machines are your local computer and connected SSH hosts. Each session contains terminal windows and panes.",
|
|
88
|
+
"Open a session or agent in the sidebar to jump to its terminal. Home brings agents from your connected machines together.",
|
|
89
|
+
],
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
version: "Move around",
|
|
93
|
+
lines: [
|
|
94
|
+
"F1 Home · F2 Terminals · F6 Sessions · F7 Attention",
|
|
95
|
+
"F10 shows or hides the sidebar. F5 opens Commands for actions, appearance and keyboard shortcuts.",
|
|
96
|
+
],
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
version: "Use the sidebar",
|
|
100
|
+
lines: [
|
|
101
|
+
"Click a row to open it. With the sidebar focused, use ↑↓ or j/k to move and Enter to open.",
|
|
102
|
+
"←→ or h/l collapse/expand machines. / searches sessions. f toggles a session favorite. Esc returns to the terminal.",
|
|
103
|
+
"PgUp/PgDn scroll a page; Ctrl-U/D scroll half a page. g/G jump to the first or last row.",
|
|
104
|
+
],
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
version: "Follow your agents",
|
|
108
|
+
lines: [
|
|
109
|
+
"On Home, search by name and choose All, Working or Needs attention. Select an agent and press Enter to open its pane.",
|
|
110
|
+
"Unavailable means the connection or observation is missing; it does not mean the agent has stopped.",
|
|
111
|
+
],
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
version: "Connect another machine",
|
|
115
|
+
lines: [
|
|
116
|
+
"Choose Add machine in the sidebar and enter an SSH alias or user@host. Set up SSH key access and host trust first.",
|
|
117
|
+
"Run tmux-ide --headless on the remote machine before connecting.",
|
|
118
|
+
],
|
|
119
|
+
},
|
|
120
|
+
]
|
|
121
|
+
: releases;
|
|
122
|
+
for (const release of sections) {
|
|
82
123
|
if (result.length) result.push({ kind: "gap", label: "" });
|
|
83
124
|
result.push({ kind: "heading", label: release.version });
|
|
84
125
|
for (const line of release.lines) {
|
|
@@ -139,8 +180,18 @@ export function ApplicationReferenceSheet(props: {
|
|
|
139
180
|
viewportHeight={props.height}
|
|
140
181
|
width={metrics().width}
|
|
141
182
|
height={metrics().height}
|
|
142
|
-
title={
|
|
143
|
-
|
|
183
|
+
title={
|
|
184
|
+
page() === "help"
|
|
185
|
+
? "Using tmux-ide"
|
|
186
|
+
: page() === "shortcuts"
|
|
187
|
+
? "Keyboard shortcuts"
|
|
188
|
+
: "What's new"
|
|
189
|
+
}
|
|
190
|
+
footer={
|
|
191
|
+
page() === "help"
|
|
192
|
+
? "Tab shortcuts · ↑↓ scroll · Esc back"
|
|
193
|
+
: "Tab switch sheet · ↑↓ scroll · Esc back"
|
|
194
|
+
}
|
|
144
195
|
zIndex={100}
|
|
145
196
|
onDismiss={props.onClose}
|
|
146
197
|
>
|
|
@@ -51,8 +51,8 @@ export interface ApplicationCatalogShellProps {
|
|
|
51
51
|
readonly paletteSelection?: Accessor<number>;
|
|
52
52
|
readonly palettePreviewActive?: Accessor<boolean>;
|
|
53
53
|
readonly onPaletteModalChange?: (open: boolean) => void;
|
|
54
|
-
readonly paletteReferencePage?: Accessor<"shortcuts" | "changes" | undefined>;
|
|
55
|
-
readonly onPaletteReferenceChange?: (page: "shortcuts" | "changes" | undefined) => void;
|
|
54
|
+
readonly paletteReferencePage?: Accessor<"shortcuts" | "changes" | "help" | undefined>;
|
|
55
|
+
readonly onPaletteReferenceChange?: (page: "shortcuts" | "changes" | "help" | undefined) => void;
|
|
56
56
|
readonly paletteKeyboardHint?: Accessor<string>;
|
|
57
57
|
readonly paletteQuery?: Accessor<string>;
|
|
58
58
|
readonly paletteDisabledReason?: (command: ApplicationPaletteCommand) => string | null;
|
|
@@ -418,6 +418,10 @@ export function ApplicationCatalogShell(props: ApplicationCatalogShellProps): JS
|
|
|
418
418
|
{(model) => (
|
|
419
419
|
<ApplicationMachineSidebar
|
|
420
420
|
model={model()}
|
|
421
|
+
onHelp={(source) => {
|
|
422
|
+
props.onSetPaletteOpen(true, source);
|
|
423
|
+
props.onPaletteReferenceChange?.("help");
|
|
424
|
+
}}
|
|
421
425
|
width={chrome().sidebar.width}
|
|
422
426
|
height={chrome().sidebar.height}
|
|
423
427
|
theme={props.theme}
|
|
@@ -106,8 +106,8 @@ export function MinimalPalette(props: {
|
|
|
106
106
|
readonly title?: string;
|
|
107
107
|
readonly onViewport?: (rows: number) => void;
|
|
108
108
|
readonly onFavorite?: (command: ApplicationPaletteCommand) => void;
|
|
109
|
-
readonly referencePage?: "shortcuts" | "changes";
|
|
110
|
-
readonly onReferenceChange?: (page: "shortcuts" | "changes" | undefined) => void;
|
|
109
|
+
readonly referencePage?: "shortcuts" | "changes" | "help";
|
|
110
|
+
readonly onReferenceChange?: (page: "shortcuts" | "changes" | "help" | undefined) => void;
|
|
111
111
|
readonly keyboardHint?: string;
|
|
112
112
|
readonly previewActive?: boolean;
|
|
113
113
|
readonly onModalChange?: (open: boolean) => void;
|
|
@@ -123,8 +123,8 @@ export function MinimalPalette(props: {
|
|
|
123
123
|
}): JSX.Element {
|
|
124
124
|
const [expanded, setExpanded] = createSignal(false);
|
|
125
125
|
const [modal, setModal] = createSignal(false);
|
|
126
|
-
const [sheet, setSheet] = createSignal<"shortcuts" | "changes">();
|
|
127
|
-
const openSheet = (page: "shortcuts" | "changes" | undefined) => {
|
|
126
|
+
const [sheet, setSheet] = createSignal<"shortcuts" | "changes" | "help">();
|
|
127
|
+
const openSheet = (page: "shortcuts" | "changes" | "help" | undefined) => {
|
|
128
128
|
props.onReferenceChange?.(page);
|
|
129
129
|
setSheet(page);
|
|
130
130
|
setModal(!!page);
|
|
@@ -100,8 +100,8 @@ export interface ApplicationShellViewProps {
|
|
|
100
100
|
readonly paletteOpen: Accessor<boolean>;
|
|
101
101
|
readonly paneRenameDialog?: Accessor<ApplicationPaneRenameDraft | null>;
|
|
102
102
|
readonly paletteSelection?: Accessor<number>;
|
|
103
|
-
readonly paletteReferencePage?: Accessor<"shortcuts" | "changes" | undefined>;
|
|
104
|
-
readonly onPaletteReferenceChange?: (page: "shortcuts" | "changes" | undefined) => void;
|
|
103
|
+
readonly paletteReferencePage?: Accessor<"shortcuts" | "changes" | "help" | undefined>;
|
|
104
|
+
readonly onPaletteReferenceChange?: (page: "shortcuts" | "changes" | "help" | undefined) => void;
|
|
105
105
|
readonly paletteKeyboardHint?: Accessor<string>;
|
|
106
106
|
readonly palettePreviewActive?: Accessor<boolean>;
|
|
107
107
|
readonly onPaletteModalChange?: (open: boolean) => void;
|
|
@@ -455,6 +455,10 @@ export function ApplicationShellView(props: ApplicationShellViewProps): JSX.Elem
|
|
|
455
455
|
{(model) => (
|
|
456
456
|
<ApplicationMachineSidebar
|
|
457
457
|
model={model()}
|
|
458
|
+
onHelp={(source) => {
|
|
459
|
+
props.onSetPaletteOpen(true, source);
|
|
460
|
+
props.onPaletteReferenceChange?.("help");
|
|
461
|
+
}}
|
|
458
462
|
agentRows={
|
|
459
463
|
model()
|
|
460
464
|
.groups()
|