experiments in a post-browser web
10
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix(cmd): Tab completion enters PARAM_MODE for commands with params

+5 -4
+5 -4
app/cmd/state-machine.js
··· 281 281 ], 282 282 [Events.TAB]: [ 283 283 { 284 - // Command has params AND name is already fully typed → enter param mode 285 - guard: (p) => guard('hasMatches', p) && guard('commandHasParams', p) && guard('textAlreadyMatchesCommand', p), 284 + // Command has params → complete name and enter param mode in one step 285 + guard: (p) => guard('hasMatches', p) && guard('commandHasParams', p), 286 286 target: States.PARAM_MODE, 287 287 actions: ['tabCompleteCommand', 'enterParamMode', 'updateGhostText', 'updateResults'], 288 288 }, 289 289 { 290 - // Command has params but name is only partially typed → complete name first 291 - // (next Tab press will enter param mode since name will then be fully typed) 290 + // No params — just complete/cycle the name 292 291 guard: 'hasMatches', 293 292 target: States.TYPING, 294 293 actions: ['tabCompleteCommand', 'updateGhostText', 'updateResults'], ··· 371 370 actions: ['tabCompleteCommand', 'enterParamMode', 'updateGhostText', 'updateResults'], 372 371 }, 373 372 { 373 + // In RESULTS_OPEN, Tab cycles through results — only enter param mode 374 + // when the name is already fully typed (above guard). Otherwise cycle. 374 375 guard: 'hasMatches', 375 376 target: States.RESULTS_OPEN, 376 377 actions: ['tabCycleInResults', 'updateGhostText', 'renderResults'],