dmux 3.1.1 → 3.2.0

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.
Files changed (232) hide show
  1. package/dist/CleanTextInput.d.ts +9 -0
  2. package/dist/CleanTextInput.d.ts.map +1 -1
  3. package/dist/CleanTextInput.js +127 -47
  4. package/dist/CleanTextInput.js.map +1 -1
  5. package/dist/DmuxApp.d.ts +2 -2
  6. package/dist/DmuxApp.d.ts.map +1 -1
  7. package/dist/DmuxApp.js +1396 -750
  8. package/dist/DmuxApp.js.map +1 -1
  9. package/dist/actions/paneActions.d.ts.map +1 -1
  10. package/dist/actions/paneActions.js +68 -11
  11. package/dist/actions/paneActions.js.map +1 -1
  12. package/dist/actions/types.d.ts +1 -0
  13. package/dist/actions/types.d.ts.map +1 -1
  14. package/dist/actions/types.js +1 -0
  15. package/dist/actions/types.js.map +1 -1
  16. package/dist/components/ActionInputDialog.d.ts.map +1 -1
  17. package/dist/components/ActionInputDialog.js +3 -2
  18. package/dist/components/ActionInputDialog.js.map +1 -1
  19. package/dist/components/DialogBox.d.ts +16 -0
  20. package/dist/components/DialogBox.d.ts.map +1 -0
  21. package/dist/components/DialogBox.js +12 -0
  22. package/dist/components/DialogBox.js.map +1 -0
  23. package/dist/components/FooterHelp.d.ts +9 -0
  24. package/dist/components/FooterHelp.d.ts.map +1 -1
  25. package/dist/components/FooterHelp.js +41 -5
  26. package/dist/components/FooterHelp.js.map +1 -1
  27. package/dist/components/PaneCard.d.ts +3 -1
  28. package/dist/components/PaneCard.d.ts.map +1 -1
  29. package/dist/components/PaneCard.js +50 -33
  30. package/dist/components/PaneCard.js.map +1 -1
  31. package/dist/components/PanesGrid.d.ts +3 -5
  32. package/dist/components/PanesGrid.d.ts.map +1 -1
  33. package/dist/components/PanesGrid.js +40 -10
  34. package/dist/components/PanesGrid.js.map +1 -1
  35. package/dist/dashboard.js +1 -1
  36. package/dist/decorative-pane.d.ts +3 -0
  37. package/dist/decorative-pane.d.ts.map +1 -0
  38. package/dist/decorative-pane.js +136 -0
  39. package/dist/decorative-pane.js.map +1 -0
  40. package/dist/hooks/useActionSystem.d.ts +14 -1
  41. package/dist/hooks/useActionSystem.d.ts.map +1 -1
  42. package/dist/hooks/useActionSystem.js +93 -4
  43. package/dist/hooks/useActionSystem.js.map +1 -1
  44. package/dist/hooks/useNavigation.js +1 -1
  45. package/dist/hooks/useNavigation.js.map +1 -1
  46. package/dist/hooks/usePaneCreation.d.ts +1 -2
  47. package/dist/hooks/usePaneCreation.d.ts.map +1 -1
  48. package/dist/hooks/usePaneCreation.js +13 -27
  49. package/dist/hooks/usePaneCreation.js.map +1 -1
  50. package/dist/hooks/usePaneRunner.d.ts.map +1 -1
  51. package/dist/hooks/usePaneRunner.js +8 -3
  52. package/dist/hooks/usePaneRunner.js.map +1 -1
  53. package/dist/hooks/usePanes.d.ts.map +1 -1
  54. package/dist/hooks/usePanes.js +210 -37
  55. package/dist/hooks/usePanes.js.map +1 -1
  56. package/dist/hooks/useWorktreeActions.d.ts.map +1 -1
  57. package/dist/hooks/useWorktreeActions.js +7 -13
  58. package/dist/hooks/useWorktreeActions.js.map +1 -1
  59. package/dist/index.js +217 -29
  60. package/dist/index.js.map +1 -1
  61. package/dist/popups/agentChoicePopup.d.ts +7 -0
  62. package/dist/popups/agentChoicePopup.d.ts.map +1 -0
  63. package/dist/popups/agentChoicePopup.js +74 -0
  64. package/dist/popups/agentChoicePopup.js.map +1 -0
  65. package/dist/popups/choicePopup.d.ts +7 -0
  66. package/dist/popups/choicePopup.d.ts.map +1 -0
  67. package/dist/popups/choicePopup.js +64 -0
  68. package/dist/popups/choicePopup.js.map +1 -0
  69. package/dist/popups/components/FileList.d.ts +13 -0
  70. package/dist/popups/components/FileList.d.ts.map +1 -0
  71. package/dist/popups/components/FileList.js +61 -0
  72. package/dist/popups/components/FileList.js.map +1 -0
  73. package/dist/popups/components/PopupContainer.d.ts +14 -0
  74. package/dist/popups/components/PopupContainer.d.ts.map +1 -0
  75. package/dist/popups/components/PopupContainer.js +15 -0
  76. package/dist/popups/components/PopupContainer.js.map +1 -0
  77. package/dist/popups/components/PopupInputBox.d.ts +11 -0
  78. package/dist/popups/components/PopupInputBox.d.ts.map +1 -0
  79. package/dist/popups/components/PopupInputBox.js +10 -0
  80. package/dist/popups/components/PopupInputBox.js.map +1 -0
  81. package/dist/popups/components/PopupWrapper.d.ts +37 -0
  82. package/dist/popups/components/PopupWrapper.d.ts.map +1 -0
  83. package/dist/popups/components/PopupWrapper.js +88 -0
  84. package/dist/popups/components/PopupWrapper.js.map +1 -0
  85. package/dist/popups/components/index.d.ts +8 -0
  86. package/dist/popups/components/index.d.ts.map +1 -0
  87. package/dist/popups/components/index.js +8 -0
  88. package/dist/popups/components/index.js.map +1 -0
  89. package/dist/popups/config.d.ts +40 -0
  90. package/dist/popups/config.d.ts.map +1 -0
  91. package/dist/popups/config.js +40 -0
  92. package/dist/popups/config.js.map +1 -0
  93. package/dist/popups/confirmPopup.d.ts +7 -0
  94. package/dist/popups/confirmPopup.d.ts.map +1 -0
  95. package/dist/popups/confirmPopup.js +72 -0
  96. package/dist/popups/confirmPopup.js.map +1 -0
  97. package/dist/popups/hooksPopup.d.ts +7 -0
  98. package/dist/popups/hooksPopup.d.ts.map +1 -0
  99. package/dist/popups/hooksPopup.js +71 -0
  100. package/dist/popups/hooksPopup.js.map +1 -0
  101. package/dist/popups/inputPopup.d.ts +7 -0
  102. package/dist/popups/inputPopup.d.ts.map +1 -0
  103. package/dist/popups/inputPopup.js +48 -0
  104. package/dist/popups/inputPopup.js.map +1 -0
  105. package/dist/popups/kebabMenuPopup.d.ts +7 -0
  106. package/dist/popups/kebabMenuPopup.d.ts.map +1 -0
  107. package/dist/popups/kebabMenuPopup.js +52 -0
  108. package/dist/popups/kebabMenuPopup.js.map +1 -0
  109. package/dist/popups/logsPopup.d.ts +12 -0
  110. package/dist/popups/logsPopup.d.ts.map +1 -0
  111. package/dist/popups/logsPopup.js +364 -0
  112. package/dist/popups/logsPopup.js.map +1 -0
  113. package/dist/popups/mergePopup.d.ts +7 -0
  114. package/dist/popups/mergePopup.d.ts.map +1 -0
  115. package/dist/popups/mergePopup.js +310 -0
  116. package/dist/popups/mergePopup.js.map +1 -0
  117. package/dist/popups/newPanePopup.d.ts +7 -0
  118. package/dist/popups/newPanePopup.d.ts.map +1 -0
  119. package/dist/popups/newPanePopup.js +234 -0
  120. package/dist/popups/newPanePopup.js.map +1 -0
  121. package/dist/popups/progressPopup.d.ts +8 -0
  122. package/dist/popups/progressPopup.d.ts.map +1 -0
  123. package/dist/popups/progressPopup.js +54 -0
  124. package/dist/popups/progressPopup.js.map +1 -0
  125. package/dist/popups/remotePopup.d.ts +6 -0
  126. package/dist/popups/remotePopup.d.ts.map +1 -0
  127. package/dist/popups/remotePopup.js +166 -0
  128. package/dist/popups/remotePopup.js.map +1 -0
  129. package/dist/popups/settingsPopup.d.ts +7 -0
  130. package/dist/popups/settingsPopup.d.ts.map +1 -0
  131. package/dist/popups/settingsPopup.js +212 -0
  132. package/dist/popups/settingsPopup.js.map +1 -0
  133. package/dist/popups/shortcutsPopup.d.ts +6 -0
  134. package/dist/popups/shortcutsPopup.d.ts.map +1 -0
  135. package/dist/popups/shortcutsPopup.js +74 -0
  136. package/dist/popups/shortcutsPopup.js.map +1 -0
  137. package/dist/popups/templates/SimpleInputPopup.d.ts +15 -0
  138. package/dist/popups/templates/SimpleInputPopup.d.ts.map +1 -0
  139. package/dist/popups/templates/SimpleInputPopup.js +28 -0
  140. package/dist/popups/templates/SimpleInputPopup.js.map +1 -0
  141. package/dist/server/embedded-assets.d.ts.map +1 -1
  142. package/dist/server/embedded-assets.js +2066 -968
  143. package/dist/server/embedded-assets.js.map +1 -1
  144. package/dist/server/index.js +1 -1
  145. package/dist/server/index.js.map +1 -1
  146. package/dist/server/routes.d.ts +1 -1
  147. package/dist/server/routes.d.ts.map +1 -1
  148. package/dist/server/routes.js +73 -6
  149. package/dist/server/routes.js.map +1 -1
  150. package/dist/services/ConfigWatcher.d.ts.map +1 -1
  151. package/dist/services/ConfigWatcher.js +10 -3
  152. package/dist/services/ConfigWatcher.js.map +1 -1
  153. package/dist/services/LogService.d.ts +112 -0
  154. package/dist/services/LogService.d.ts.map +1 -0
  155. package/dist/services/LogService.js +252 -0
  156. package/dist/services/LogService.js.map +1 -0
  157. package/dist/services/PaneWorkerManager.d.ts.map +1 -1
  158. package/dist/services/PaneWorkerManager.js +35 -9
  159. package/dist/services/PaneWorkerManager.js.map +1 -1
  160. package/dist/services/TunnelService.d.ts +1 -0
  161. package/dist/services/TunnelService.d.ts.map +1 -1
  162. package/dist/services/TunnelService.js +56 -15
  163. package/dist/services/TunnelService.js.map +1 -1
  164. package/dist/shared/StateManager.d.ts +49 -1
  165. package/dist/shared/StateManager.d.ts.map +1 -1
  166. package/dist/shared/StateManager.js +97 -2
  167. package/dist/shared/StateManager.js.map +1 -1
  168. package/dist/spacer-pane.d.ts +8 -0
  169. package/dist/spacer-pane.d.ts.map +1 -0
  170. package/dist/spacer-pane.js +40 -0
  171. package/dist/spacer-pane.js.map +1 -0
  172. package/dist/theme/colors.d.ts +25 -0
  173. package/dist/theme/colors.d.ts.map +1 -0
  174. package/dist/theme/colors.js +33 -0
  175. package/dist/theme/colors.js.map +1 -0
  176. package/dist/types.d.ts +14 -0
  177. package/dist/types.d.ts.map +1 -1
  178. package/dist/utils/asciiArt.d.ts +26 -0
  179. package/dist/utils/asciiArt.d.ts.map +1 -0
  180. package/dist/utils/asciiArt.js +88 -0
  181. package/dist/utils/asciiArt.js.map +1 -0
  182. package/dist/utils/conflictResolutionPane.d.ts.map +1 -1
  183. package/dist/utils/conflictResolutionPane.js +8 -4
  184. package/dist/utils/conflictResolutionPane.js.map +1 -1
  185. package/dist/utils/fileScanner.d.ts +23 -0
  186. package/dist/utils/fileScanner.d.ts.map +1 -0
  187. package/dist/utils/fileScanner.js +123 -0
  188. package/dist/utils/fileScanner.js.map +1 -0
  189. package/dist/utils/generated-agents-doc.d.ts +1 -1
  190. package/dist/utils/generated-agents-doc.js +1 -1
  191. package/dist/utils/hooks.d.ts.map +1 -1
  192. package/dist/utils/hooks.js +65 -36
  193. package/dist/utils/hooks.js.map +1 -1
  194. package/dist/utils/hooksDocs.d.ts +1 -1
  195. package/dist/utils/layoutManager.d.ts +45 -0
  196. package/dist/utils/layoutManager.d.ts.map +1 -0
  197. package/dist/utils/layoutManager.js +500 -0
  198. package/dist/utils/layoutManager.js.map +1 -0
  199. package/dist/utils/paneCreation.d.ts.map +1 -1
  200. package/dist/utils/paneCreation.js +125 -11
  201. package/dist/utils/paneCreation.js.map +1 -1
  202. package/dist/utils/popup.d.ts +97 -0
  203. package/dist/utils/popup.d.ts.map +1 -0
  204. package/dist/utils/popup.js +509 -0
  205. package/dist/utils/popup.js.map +1 -0
  206. package/dist/utils/postPaneCleanup.d.ts +12 -0
  207. package/dist/utils/postPaneCleanup.d.ts.map +1 -0
  208. package/dist/utils/postPaneCleanup.js +53 -0
  209. package/dist/utils/postPaneCleanup.js.map +1 -0
  210. package/dist/utils/shellPaneDetection.d.ts +44 -0
  211. package/dist/utils/shellPaneDetection.d.ts.map +1 -0
  212. package/dist/utils/shellPaneDetection.js +175 -0
  213. package/dist/utils/shellPaneDetection.js.map +1 -0
  214. package/dist/utils/tmux.d.ts +53 -1
  215. package/dist/utils/tmux.d.ts.map +1 -1
  216. package/dist/utils/tmux.js +352 -84
  217. package/dist/utils/tmux.js.map +1 -1
  218. package/dist/utils/welcomePane.d.ts +22 -0
  219. package/dist/utils/welcomePane.d.ts.map +1 -0
  220. package/dist/utils/welcomePane.js +119 -0
  221. package/dist/utils/welcomePane.js.map +1 -0
  222. package/dist/utils/welcomePaneManager.d.ts +36 -0
  223. package/dist/utils/welcomePaneManager.d.ts.map +1 -0
  224. package/dist/utils/welcomePaneManager.js +160 -0
  225. package/dist/utils/welcomePaneManager.js.map +1 -0
  226. package/dist/workers/PaneWorker.js +2 -0
  227. package/dist/workers/PaneWorker.js.map +1 -1
  228. package/package.json +5 -2
  229. package/dist/components/NewPaneDialog.d.ts +0 -9
  230. package/dist/components/NewPaneDialog.d.ts.map +0 -1
  231. package/dist/components/NewPaneDialog.js +0 -11
  232. package/dist/components/NewPaneDialog.js.map +0 -1
@@ -1,4 +1,52 @@
1
1
  import { execSync } from 'child_process';
2
+ import { LogService } from '../services/LogService.js';
3
+ import { recalculateAndApplyLayout } from './layoutManager.js';
4
+ // Layout configuration - adjust these to change layout behavior
5
+ export const SIDEBAR_WIDTH = 40;
6
+ export const MIN_COMFORTABLE_WIDTH = 60; // Minimum chars for comfortable code viewing
7
+ export const MAX_COMFORTABLE_WIDTH = 100; // Maximum chars before too wide for comfort
8
+ export const MIN_COMFORTABLE_HEIGHT = 15; // Minimum lines for comfortable pane viewing
9
+ /**
10
+ * Calculate tmux layout checksum
11
+ * Based on tmux source: layout.c - layout_checksum()
12
+ */
13
+ function calculateLayoutChecksum(layout) {
14
+ let checksum = 0;
15
+ for (let i = 0; i < layout.length; i++) {
16
+ checksum = (checksum >> 1) + ((checksum & 1) << 15);
17
+ checksum += layout.charCodeAt(i);
18
+ checksum &= 0xFFFF; // Mask to 16 bits (critical!)
19
+ }
20
+ // Tmux expects a 4-digit hex checksum (pad with leading zeros)
21
+ return checksum.toString(16).padStart(4, '0');
22
+ }
23
+ /**
24
+ * Gets current window dimensions
25
+ */
26
+ export const getWindowDimensions = () => {
27
+ try {
28
+ const output = execSync('tmux display-message -p "#{window_width} #{window_height}"', { encoding: 'utf-8', stdio: 'pipe' }).trim();
29
+ const [width, height] = output.split(' ').map(n => parseInt(n));
30
+ return { width, height };
31
+ }
32
+ catch {
33
+ return { width: 120, height: 40 }; // Fallback dimensions
34
+ }
35
+ };
36
+ /**
37
+ * Gets current terminal (client) dimensions
38
+ * This is the actual terminal size, not the tmux window size
39
+ */
40
+ export const getTerminalDimensions = () => {
41
+ try {
42
+ const output = execSync('tmux display-message -p "#{client_width} #{client_height}"', { encoding: 'utf-8', stdio: 'pipe' }).trim();
43
+ const [width, height] = output.split(' ').map(n => parseInt(n));
44
+ return { width, height };
45
+ }
46
+ catch {
47
+ return { width: 120, height: 40 }; // Fallback dimensions
48
+ }
49
+ };
2
50
  export const getPanePositions = () => {
3
51
  try {
4
52
  const output = execSync(`tmux list-panes -F '#{pane_id} #{pane_left} #{pane_top} #{pane_width} #{pane_height}'`, { encoding: 'utf-8', stdio: 'pipe' }).trim();
@@ -17,105 +65,325 @@ export const getPanePositions = () => {
17
65
  return [];
18
66
  }
19
67
  };
20
- export const applySmartLayout = (paneCount) => {
68
+ /**
69
+ * Gets all pane IDs in current window
70
+ */
71
+ export const getAllPaneIds = () => {
21
72
  try {
22
- if (paneCount <= 2) {
23
- execSync('tmux select-layout even-horizontal', { stdio: 'pipe' });
24
- }
25
- else if (paneCount === 3) {
26
- execSync('tmux select-layout main-horizontal', { stdio: 'pipe' });
27
- }
28
- else if (paneCount === 4) {
29
- execSync('tmux select-layout tiled', { stdio: 'pipe' });
73
+ const output = execSync('tmux list-panes -F "#{pane_id}"', {
74
+ encoding: 'utf-8',
75
+ stdio: 'pipe',
76
+ }).trim();
77
+ return output.split('\n').filter(id => id.trim());
78
+ }
79
+ catch {
80
+ return [];
81
+ }
82
+ };
83
+ /**
84
+ * Gets content pane IDs (excludes control pane and spacer pane)
85
+ */
86
+ export const getContentPaneIds = (controlPaneId) => {
87
+ const allPanes = getAllPaneIds();
88
+ return allPanes.filter(id => {
89
+ if (id === controlPaneId)
90
+ return false;
91
+ // Filter out spacer pane
92
+ try {
93
+ const title = execSync(`tmux display-message -t '${id}' -p '#{pane_title}'`, { encoding: 'utf-8', stdio: 'pipe' }).trim();
94
+ return title !== 'dmux-spacer';
30
95
  }
31
- else if (paneCount >= 5) {
32
- // For 5+ panes: 2 panes on top, 3+ panes on bottom
33
- applyCustomTwoRowLayout(paneCount);
96
+ catch {
97
+ return true; // Include pane if we can't get title
34
98
  }
99
+ });
100
+ };
101
+ /**
102
+ * Creates initial sidebar layout by splitting from control pane
103
+ * @param controlPaneId The pane ID running dmux TUI (left sidebar)
104
+ * @returns The newly created content area pane ID
105
+ */
106
+ export const setupSidebarLayout = (controlPaneId) => {
107
+ try {
108
+ // Split horizontally (left-right) from control pane
109
+ const newPaneId = execSync(`tmux split-window -h -t '${controlPaneId}' -P -F '#{pane_id}'`, { encoding: 'utf-8', stdio: 'pipe' }).trim();
110
+ // Wait for split to settle
111
+ execSync('sleep 0.1', { stdio: 'pipe' });
112
+ // Resize control pane to fixed width
113
+ enforceControlPaneSize(controlPaneId, SIDEBAR_WIDTH);
114
+ // Refresh to ensure panes are painted correctly after layout
35
115
  execSync('tmux refresh-client', { stdio: 'pipe' });
116
+ return newPaneId;
36
117
  }
37
118
  catch (error) {
119
+ throw new Error(`Failed to setup sidebar layout: ${error}`);
120
+ }
121
+ };
122
+ /**
123
+ * Generates a custom tmux layout string for [Sidebar | Grid] arrangement
124
+ * Format: checksum,WxH,X,Y{child1,child2,...}
125
+ * Each child: WxH,X,Y[pane_id] for leaf or WxH,X,Y{...} for container
126
+ */
127
+ export const generateSidebarGridLayout = (controlPaneId, contentPanes, sidebarWidth, windowWidth, windowHeight, columns, maxComfortableWidth = MAX_COMFORTABLE_WIDTH) => {
128
+ // Calculate grid dimensions for content panes
129
+ const numContentPanes = contentPanes.length;
130
+ // Use provided column count
131
+ const cols = columns;
132
+ const rows = Math.ceil(numContentPanes / cols);
133
+ // Content area dimensions
134
+ // Account for borders: horizontal split adds 1 char, vertical splits add 1 char per row
135
+ const contentWidth = windowWidth - sidebarWidth - 1; // -1 for border between sidebar and content
136
+ const contentStartX = sidebarWidth + 1; // +1 to account for border
137
+ // For width, account for borders between columns
138
+ const bordersWidth = cols - 1;
139
+ const availableWidth = contentWidth - bordersWidth;
140
+ const paneWidth = Math.floor(availableWidth / cols);
141
+ // Check if last pane is a spacer
142
+ const lastPaneIsSpacer = contentPanes.length > 0 && (() => {
38
143
  try {
39
- execSync('tmux select-layout even-horizontal', { stdio: 'pipe' });
144
+ const lastPaneId = contentPanes[contentPanes.length - 1];
145
+ const title = execSync(`tmux display-message -t '${lastPaneId}' -p '#{pane_title}'`, { encoding: 'utf-8', stdio: 'pipe' }).trim();
146
+ return title === 'dmux-spacer';
147
+ }
148
+ catch {
149
+ return false;
150
+ }
151
+ })();
152
+ // For height, account for borders between rows
153
+ // If we have 2 rows with 1 border, total consumed = row1 + 1 + row2 = windowHeight
154
+ const bordersHeight = rows - 1; // Number of borders between rows
155
+ const availableHeight = windowHeight - bordersHeight;
156
+ const paneHeight = Math.floor(availableHeight / rows);
157
+ // Extract numeric ID from controlPaneId (e.g., %1 -> 1)
158
+ const sidebarId = controlPaneId.replace('%', '');
159
+ // Debug logging
160
+ LogService.getInstance().debug(`generateSidebarGridLayout: ${numContentPanes} panes, ${cols} cols x ${rows} rows`, 'Layout');
161
+ LogService.getInstance().debug(`Window: ${windowWidth}x${windowHeight}, Content: ${contentWidth}x${windowHeight} starting at X=${contentStartX}`, 'Layout');
162
+ LogService.getInstance().debug(`Pane width: ${paneWidth}, borders: ${bordersWidth}`, 'Layout');
163
+ // Build grid rows (vertical splits within content area)
164
+ // Use ABSOLUTE coordinates everywhere (tmux requirement - yes, even inside containers!)
165
+ const gridRows = [];
166
+ let paneIndex = 0;
167
+ let currentY = 0; // Track Y position (starts at 0, relative to content area)
168
+ for (let row = 0; row < rows; row++) {
169
+ const rowPanes = [];
170
+ let absoluteX = contentStartX; // Track X position as ABSOLUTE from window origin
171
+ // Calculate height for this row
172
+ // Last row gets remainder to account for rounding
173
+ let rowHeight;
174
+ if (row === rows - 1) {
175
+ // Last row: use all remaining height
176
+ rowHeight = windowHeight - currentY;
177
+ }
178
+ else {
179
+ rowHeight = paneHeight;
180
+ }
181
+ // Determine panes in this row
182
+ const panesInThisRow = [];
183
+ for (let col = 0; col < cols && paneIndex + col < numContentPanes; col++) {
184
+ panesInThisRow.push(contentPanes[paneIndex + col]);
40
185
  }
41
- catch { }
186
+ // Check if this row has a spacer (last pane is spacer)
187
+ const rowHasSpacer = lastPaneIsSpacer && row === rows - 1 && panesInThisRow.length > 0 &&
188
+ panesInThisRow[panesInThisRow.length - 1] === contentPanes[numContentPanes - 1];
189
+ const numContentPanesInRow = rowHasSpacer ? panesInThisRow.length - 1 : panesInThisRow.length;
190
+ // Calculate widths for this row
191
+ let contentPaneWidths;
192
+ let spacerWidth = null;
193
+ if (rowHasSpacer) {
194
+ // Row with spacer: content panes get MAX_COMFORTABLE_WIDTH (from config), spacer gets remainder
195
+ const contentPaneWidth = maxComfortableWidth;
196
+ const bordersInRow = panesInThisRow.length - 1; // borders between ALL panes in row
197
+ const totalContentWidth = numContentPanesInRow * contentPaneWidth;
198
+ const remainingWidth = contentWidth - totalContentWidth - bordersInRow;
199
+ LogService.getInstance().debug(`Row ${row} with spacer: ${numContentPanesInRow} content panes @ ${contentPaneWidth} = ${totalContentWidth}, borders=${bordersInRow}, spacer=${remainingWidth}`, 'Layout');
200
+ if (remainingWidth < 0) {
201
+ LogService.getInstance().debug(`WARNING: Negative spacer width! contentWidth=${contentWidth}, totalContent=${totalContentWidth}, borders=${bordersInRow}`, 'Layout');
202
+ }
203
+ contentPaneWidths = Array(numContentPanesInRow).fill(contentPaneWidth);
204
+ spacerWidth = remainingWidth;
205
+ }
206
+ else {
207
+ // Row without spacer: divide width evenly
208
+ const bordersInRow = panesInThisRow.length - 1;
209
+ const availableWidth = contentWidth - bordersInRow;
210
+ const evenWidth = Math.floor(availableWidth / panesInThisRow.length);
211
+ const remainder = availableWidth - (evenWidth * panesInThisRow.length);
212
+ // CRITICAL: Distribute width evenly, with remainder going to FIRST pane (matches tmux behavior)
213
+ contentPaneWidths = Array(panesInThisRow.length).fill(evenWidth);
214
+ contentPaneWidths[0] += remainder; // First pane gets remainder, not last!
215
+ }
216
+ // Build row panes with calculated widths using ABSOLUTE coordinates
217
+ for (let col = 0; col < panesInThisRow.length; col++) {
218
+ const paneId = panesInThisRow[col].replace('%', '');
219
+ const isSpacerPane = rowHasSpacer && col === panesInThisRow.length - 1;
220
+ const colWidth = isSpacerPane ? spacerWidth : contentPaneWidths[col];
221
+ // Use ABSOLUTE coordinates (from window origin) - tmux requirement
222
+ rowPanes.push(`${colWidth}x${rowHeight},${absoluteX},${currentY},${paneId}`);
223
+ // Move X position right by pane width + border
224
+ absoluteX += colWidth;
225
+ if (col < panesInThisRow.length - 1) {
226
+ absoluteX += 1; // Add border
227
+ }
228
+ }
229
+ paneIndex += panesInThisRow.length;
230
+ // Wrap multi-pane rows in horizontal container (uses ABSOLUTE coordinates)
231
+ if (rowPanes.length > 1) {
232
+ // Horizontal split = use curly braces {}
233
+ // Row container also uses ABSOLUTE coordinates
234
+ const rowString = `${contentWidth}x${rowHeight},${contentStartX},${currentY}{${rowPanes.join(',')}}`;
235
+ LogService.getInstance().debug(`Row ${row}: ${rowPanes.length} panes → ${rowString}`, 'Layout');
236
+ gridRows.push(rowString);
237
+ }
238
+ else if (rowPanes.length === 1) {
239
+ // Single pane - no container needed, use ABSOLUTE coordinates
240
+ const paneStr = rowPanes[0];
241
+ const parts = paneStr.split(',');
242
+ parts[1] = contentStartX.toString(); // X absolute
243
+ parts[2] = currentY.toString(); // Y absolute
244
+ const singlePaneString = parts.join(',');
245
+ LogService.getInstance().debug(`Row ${row}: 1 pane → ${singlePaneString}`, 'Layout');
246
+ gridRows.push(singlePaneString);
247
+ }
248
+ // Move Y position down by pane height + 1 for border (except on last row)
249
+ if (row < rows - 1) {
250
+ currentY += paneHeight + 1;
251
+ }
252
+ }
253
+ // Build root container
254
+ const sidebar = `${sidebarWidth}x${windowHeight},0,0,${sidebarId}`;
255
+ let layoutWithoutChecksum;
256
+ if (gridRows.length > 1) {
257
+ // Multiple rows: wrap in vertical split container
258
+ const contentArea = `${contentWidth}x${windowHeight},${contentStartX},0[${gridRows.join(',')}]`;
259
+ layoutWithoutChecksum = `${windowWidth}x${windowHeight},0,0{${sidebar},${contentArea}}`;
260
+ }
261
+ else if (gridRows.length === 1) {
262
+ // Single row: keep the container structure to maintain binary splits
263
+ // tmux only supports 2 children per split, so we need {sidebar, content_container}
264
+ const row = gridRows[0];
265
+ // Adjust the container's X position from 0 to contentStartX
266
+ const contentArea = row.replace(/^(\d+x\d+),0,/, `$1,${contentStartX},`);
267
+ layoutWithoutChecksum = `${windowWidth}x${windowHeight},0,0{${sidebar},${contentArea}}`;
268
+ LogService.getInstance().debug(`Single row layout: {sidebar, content}`, 'Layout');
42
269
  }
270
+ else {
271
+ // No content panes
272
+ return '';
273
+ }
274
+ // Calculate checksum and prepend to layout string
275
+ const checksum = calculateLayoutChecksum(layoutWithoutChecksum);
276
+ const finalLayout = `${checksum},${layoutWithoutChecksum}`;
277
+ LogService.getInstance().debug(`Generated layout string: ${finalLayout}`, 'Layout');
278
+ return finalLayout;
279
+ };
280
+ /**
281
+ * Calculates optimal number of columns for pane layout based on dimensions
282
+ * @param numPanes Number of panes to arrange
283
+ * @param contentWidth Available width for content panes
284
+ * @param contentHeight Available height for content panes
285
+ * @returns Optimal number of columns
286
+ */
287
+ export const calculateOptimalColumns = (numPanes, contentWidth, contentHeight) => {
288
+ // Try different numbers of columns to find optimal layout
289
+ let bestCols = 1;
290
+ let bestScore = -1;
291
+ for (let cols = 1; cols <= numPanes; cols++) {
292
+ // Calculate width for this column count
293
+ const bordersWidth = cols - 1;
294
+ const paneWidth = Math.floor((contentWidth - bordersWidth) / cols);
295
+ // Calculate height for this column count
296
+ const rows = Math.ceil(numPanes / cols);
297
+ const bordersHeight = rows - 1;
298
+ const paneHeight = Math.floor((contentHeight - bordersHeight) / rows);
299
+ // Skip if width or height is too small
300
+ if (paneWidth < MIN_COMFORTABLE_WIDTH || paneHeight < MIN_COMFORTABLE_HEIGHT) {
301
+ continue;
302
+ }
303
+ // Score this configuration (prefer balanced layouts)
304
+ // Heavily penalize heights below comfortable threshold
305
+ const widthScore = paneWidth <= MAX_COMFORTABLE_WIDTH ? 1 : 0.5;
306
+ const heightScore = paneHeight >= MIN_COMFORTABLE_HEIGHT * 1.5 ? 1 : 0.7;
307
+ const score = widthScore * heightScore;
308
+ if (score > bestScore) {
309
+ bestScore = score;
310
+ bestCols = cols;
311
+ }
312
+ }
313
+ // If no valid layout found, fall back to what gives best height
314
+ if (bestScore === -1) {
315
+ // Find column count that maximizes height while keeping width above minimum
316
+ for (let cols = numPanes; cols >= 1; cols--) {
317
+ const bordersWidth = cols - 1;
318
+ const paneWidth = Math.floor((contentWidth - bordersWidth) / cols);
319
+ if (paneWidth >= MIN_COMFORTABLE_WIDTH * 0.8) { // Allow slightly narrower
320
+ bestCols = cols;
321
+ break;
322
+ }
323
+ }
324
+ }
325
+ return bestCols;
43
326
  };
44
327
  /**
45
- * Creates a custom layout with 2 panes on top and remaining panes on bottom
46
- * For 5 panes: 2 on top, 3 on bottom
47
- * For 6 panes: 2 on top, 4 on bottom
48
- * etc.
328
+ * Enforces left sidebar layout: 40-char wide sidebar on left, content panes in grid on right
329
+ * This maintains the structure: [Sidebar (40 chars, full height) | Content Grid Area]
330
+ *
331
+ * @deprecated This function now delegates to the centralized layout manager.
332
+ * Consider using recalculateAndApplyLayout() directly from layoutManager.ts
49
333
  */
50
- const applyCustomTwoRowLayout = (paneCount) => {
334
+ export const enforceControlPaneSize = (controlPaneId, width) => {
335
+ const logService = LogService.getInstance();
51
336
  try {
52
- // Get all pane IDs and their positions
53
- const paneInfo = execSync('tmux list-panes -F "#{pane_id} #{pane_index}"', {
54
- encoding: 'utf-8',
55
- stdio: 'pipe',
56
- })
57
- .trim()
58
- .split('\n')
59
- .map(line => {
60
- const [id, index] = line.split(' ');
61
- return { id, index: parseInt(index) };
62
- })
63
- .sort((a, b) => a.index - b.index);
64
- if (paneInfo.length !== paneCount) {
65
- throw new Error('Pane count mismatch');
66
- }
67
- // Start with tiled layout
68
- execSync('tmux select-layout tiled', { stdio: 'pipe' });
69
- // Strategy: Use main-horizontal layout and adjust
70
- // main-horizontal gives us one pane on top, rest on bottom
71
- // Then we'll adjust the top pane to be split in half
72
- // Get window dimensions
73
- const windowInfo = execSync('tmux display-message -p "#{window_width} #{window_height}"', { encoding: 'utf-8', stdio: 'pipe' }).trim();
74
- const [windowWidth, windowHeight] = windowInfo.split(' ').map(n => parseInt(n));
75
- // Calculate target dimensions
76
- const topRowHeight = Math.floor(windowHeight / 2);
77
- const bottomRowHeight = windowHeight - topRowHeight - 1; // -1 for border
78
- // We need to manually position panes
79
- // Top row: panes 0 and 1 (side by side)
80
- // Bottom row: panes 2, 3, 4, etc. (side by side)
81
- const topPaneWidth = Math.floor(windowWidth / 2);
82
- const bottomPaneCount = paneCount - 2;
83
- const bottomPaneWidth = Math.floor(windowWidth / bottomPaneCount);
84
- // Build a custom layout string
85
- // tmux layout format: {width}x{height},{x},{y},{pane_id}
86
- // For horizontal split at root: {width}x{height},{x},{y}[layout1,layout2]
87
- // For vertical split: {width}x{height},{x},{y}{pane1,pane2}
88
- // Extract numeric pane IDs (remove the % prefix)
89
- const pane0Num = paneInfo[0].id.replace('%', '');
90
- const pane1Num = paneInfo[1].id.replace('%', '');
91
- // Construct layout string for our desired 2-row layout
92
- // Format: widthxheight,x,y[top_row{bottom_row}]
93
- // top_row is a horizontal split: widthxheight,x,y{pane0,pane1}
94
- // bottom_row is a horizontal split: widthxheight,x,y{pane2,pane3,...}
95
- // Top row layout (2 panes side by side)
96
- const topRowLayout = `${windowWidth}x${topRowHeight},0,0{${topPaneWidth}x${topRowHeight},0,0,${pane0Num},${windowWidth - topPaneWidth - 1}x${topRowHeight},${topPaneWidth + 1},0,${pane1Num}}`;
97
- // Bottom row layout (remaining panes side by side)
98
- let bottomRowParts = [];
99
- let currentX = 0;
100
- for (let i = 2; i < paneCount; i++) {
101
- const isLast = i === paneCount - 1;
102
- const width = isLast ? windowWidth - currentX : bottomPaneWidth;
103
- const paneNum = paneInfo[i].id.replace('%', '');
104
- bottomRowParts.push(`${width}x${bottomRowHeight},${currentX},${topRowHeight + 1},${paneNum}`);
105
- currentX += width + 1;
106
- }
107
- const bottomRowLayout = `${windowWidth}x${bottomRowHeight},0,${topRowHeight + 1}{${bottomRowParts.join(',')}}`;
108
- // Complete layout
109
- const layoutString = `${windowWidth}x${windowHeight},0,0[${topRowLayout},${bottomRowLayout}]`;
110
- // Apply the layout
111
- execSync(`tmux select-layout '${layoutString}'`, { stdio: 'pipe' });
337
+ const contentPanes = getContentPaneIds(controlPaneId);
338
+ logService.debug(`enforceControlPaneSize called: ${contentPanes.length} content panes`, 'Layout');
339
+ // If we only have the control pane, nothing to enforce
340
+ if (contentPanes.length === 0) {
341
+ // Just resize the sidebar
342
+ try {
343
+ execSync(`tmux resize-pane -t '${controlPaneId}' -x ${width}`, { stdio: 'pipe' });
344
+ }
345
+ catch {
346
+ // Ignore errors
347
+ }
348
+ return;
349
+ }
350
+ // Check if we have only the welcome pane (should not be width-constrained)
351
+ if (contentPanes.length === 1) {
352
+ try {
353
+ const title = execSync(`tmux display-message -t '${contentPanes[0]}' -p '#{pane_title}'`, {
354
+ encoding: 'utf-8',
355
+ stdio: 'pipe'
356
+ }).trim();
357
+ if (title === 'Welcome') {
358
+ // Welcome pane should use full terminal width, not be constrained
359
+ // Get terminal dimensions and let window follow terminal
360
+ const termDims = getTerminalDimensions();
361
+ // Set window size to match terminal (manual mode but always tracking terminal)
362
+ execSync(`tmux set-window-option window-size manual`, { stdio: 'pipe' });
363
+ execSync(`tmux resize-window -x ${termDims.width} -y ${termDims.height}`, { stdio: 'pipe' });
364
+ // Apply main-vertical layout with fixed sidebar width
365
+ execSync(`tmux set-window-option main-pane-width ${width}`, { stdio: 'pipe' });
366
+ execSync('tmux select-layout main-vertical', { stdio: 'pipe' });
367
+ execSync('tmux refresh-client', { stdio: 'pipe' });
368
+ return;
369
+ }
370
+ }
371
+ catch {
372
+ // If we can't get the title, fall through to normal layout
373
+ }
374
+ }
375
+ // Use the new layout manager for regular content panes
376
+ // Read terminal dimensions (not window dimensions which may be stale in manual mode)
377
+ const dimensions = getTerminalDimensions();
378
+ logService.debug(`Terminal dimensions: ${dimensions.width}x${dimensions.height}`, 'Layout');
379
+ recalculateAndApplyLayout(controlPaneId, contentPanes, dimensions.width, dimensions.height);
380
+ // Refresh to apply changes (but don't select the pane - don't steal focus!)
381
+ execSync('tmux refresh-client', { stdio: 'pipe' });
112
382
  }
113
383
  catch (error) {
114
- // Fallback to tiled on any error
115
- try {
116
- execSync('tmux select-layout tiled', { stdio: 'pipe' });
117
- }
118
- catch { }
384
+ // Log error for debugging but don't crash
385
+ const msg = 'Layout enforcement failed';
386
+ LogService.getInstance().error(msg, 'tmux', undefined, error instanceof Error ? error : undefined);
119
387
  }
120
388
  };
121
389
  //# sourceMappingURL=tmux.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"tmux.js","sourceRoot":"","sources":["../../src/utils/tmux.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AAGzC,MAAM,CAAC,MAAM,gBAAgB,GAAG,GAAmB,EAAE;IACnD,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,QAAQ,CACrB,uFAAuF,EACvF,EAAE,QAAQ,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,CACrC,CAAC,IAAI,EAAE,CAAC;QAET,OAAO,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE;YACnC,MAAM,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,EAAE,MAAM,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;YAC3D,OAAO;gBACL,MAAM;gBACN,IAAI,EAAE,QAAQ,CAAC,IAAI,CAAC;gBACpB,GAAG,EAAE,QAAQ,CAAC,GAAG,CAAC;gBAClB,KAAK,EAAE,QAAQ,CAAC,KAAK,CAAC;gBACtB,MAAM,EAAE,QAAQ,CAAC,MAAM,CAAC;aACzB,CAAC;QACJ,CAAC,CAAC,CAAC;IACL,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,EAAE,CAA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AC;QAE5F,yBAAyB,CACvB,aAAa,EACb,YAAY,EACZ,UAAU,CAAC,KAAK,EAChB,UAAU,CAAC,MAAM,CAClB,CAAC;QAEF,4EAA4E;QAC5E,QAAQ,CAAC,qBAAqB,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,CAAC,CAAC;IACrD,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,0CAA0C;QAC1C,MAAM,GAAG,GAAG,2BAA2B,CAAC;QACxC,UAAU,CAAC,WAAW,EAAE,CAAC,KAAK,CAAC,GAAG,EAAE,MAAM,EAAE,SAAS,EAAE,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC;IACrG,CAAC;AACH,CAAC,CAAC"}
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Creates a welcome pane in the tmux session
3
+ * This pane displays ASCII art and has no command prompt
4
+ *
5
+ * @param controlPaneId - The ID of the control (sidebar) pane
6
+ * @returns The pane ID of the created welcome pane, or undefined if creation failed
7
+ */
8
+ export declare function createWelcomePane(controlPaneId: string): Promise<string | undefined>;
9
+ /**
10
+ * Destroys the welcome pane if it exists
11
+ *
12
+ * @param welcomePaneId - The pane ID of the welcome pane to destroy
13
+ */
14
+ export declare function destroyWelcomePane(welcomePaneId: string | undefined): void;
15
+ /**
16
+ * Checks if a welcome pane exists and is still alive
17
+ *
18
+ * @param welcomePaneId - The pane ID to check
19
+ * @returns true if the pane exists, false otherwise
20
+ */
21
+ export declare function welcomePaneExists(welcomePaneId: string | undefined): boolean;
22
+ //# sourceMappingURL=welcomePane.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"welcomePane.d.ts","sourceRoot":"","sources":["../../src/utils/welcomePane.ts"],"names":[],"mappings":"AAMA;;;;;;GAMG;AACH,wBAAsB,iBAAiB,CAAC,aAAa,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,CAoE1F;AAED;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,aAAa,EAAE,MAAM,GAAG,SAAS,GAAG,IAAI,CAwB1E;AAED;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAAC,aAAa,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,CAkB5E"}