Skip to content

feat: add path autocomplete in new session pane#329

Merged
njbrake merged 1 commit intomainfrom
feature/ghost-text-path-autocomplete
Feb 26, 2026
Merged

feat: add path autocomplete in new session pane#329
njbrake merged 1 commit intomainfrom
feature/ghost-text-path-autocomplete

Conversation

@njbrake
Copy link
Copy Markdown
Owner

@njbrake njbrake commented Feb 26, 2026

Description

Replace Tab-triggered path completion cycling with fish-shell style ghost text in the new session dialog. Dimmed completion text now appears after the cursor showing directory completions, accepted with Right arrow or End key. Tab retains its normal field navigation role.

Key behaviors:

  • Ghost text shows directory completions when cursor is at end of input
  • Single match: shows remainder + /
  • Multiple matches: shows longest common prefix remainder
  • Recomputes reactively on every keystroke/cursor move
  • Includes staleness check to prevent stale ghost acceptance
  • Adds path navigation shortcuts: Ctrl+Left / Alt+B (previous segment), Home / Ctrl+A (start)
  • Invalid path input triggers a transient red flash highlight
  • Refactors tick() to return bool for smarter redraws

PR Type

  • New Feature
  • Bug Fix
  • Refactor
  • Documentation
  • Infrastructure / CI

Checklist

  • I understand the code I am submitting
  • New and existing tests pass
  • Documentation was updated where necessary
  • For UI changes: included screenshot or recording

AI Usage

  • No AI was used
  • AI was used for drafting/refactoring
  • This is fully AI-generated

AI Model/Tool used: Claude Opus 4.6 (via Claude Code)

Any Additional AI Details you'd like to share: Co-authored implementation and tests with Claude Opus 4.6.

NOTE:
When responding to reviewer questions, please respond yourself rather than copy/pasting reviewer comments into an AI and pasting back its answer. We want to discuss with you, not your AI :)

  • I am an AI Agent filling out this form (check box if true)

Replace Tab-triggered path completion cycling with fish-shell style ghost
text. Dimmed completion text appears after the cursor and is accepted with
Right arrow or End key. Tab keeps its normal field navigation role.

- Ghost text shows directory completions when cursor is at end of input
- Single match: shows remainder + /
- Multiple matches: shows longest common prefix remainder
- Recomputes reactively on every keystroke/cursor move
- Includes staleness check to prevent stale ghost acceptance
- Refactor tick() to return bool for smarter redraws

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@njbrake njbrake force-pushed the feature/ghost-text-path-autocomplete branch from cf7f139 to 736980c Compare February 26, 2026 10:24
@njbrake njbrake merged commit 6c0bc76 into main Feb 26, 2026
12 checks passed
@njbrake njbrake deleted the feature/ghost-text-path-autocomplete branch February 26, 2026 12:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant