Skip to content

feat: remote PathBar Tab key triggers BrowseRequest when no suggestions#2

Open
aeroxy wants to merge 2 commits into
masterfrom
dev
Open

feat: remote PathBar Tab key triggers BrowseRequest when no suggestions#2
aeroxy wants to merge 2 commits into
masterfrom
dev

Conversation

@aeroxy
Copy link
Copy Markdown
Owner

@aeroxy aeroxy commented May 27, 2026

Previously, Tab in the remote address bar only completed from cached suggestions (remoteEntries). If the cache was stale or empty, Tab did nothing — unlike the local pane which always fetches fresh from /api/browse.

Added an optional onTabComplete callback to PathBar/FilePane. When Tab is pressed with no suggestions, it fires onTabComplete(inputValue). The remote pane wires this to handleRemoteNavigateTo, sending a BrowseRequest over WS so local and remote share the same Tab completion behavior.

Summary by CodeRabbit

  • New Features
    • Tab-completion in the file path input now activates when no autocomplete suggestions are present, enabling quicker path entry.
    • Tab-completion/navigation is now supported from remote file panes, allowing tab-triggered completion to initiate remote navigation when connected.

Review Change Stack

Previously, Tab in the remote address bar only completed from cached
suggestions (remoteEntries). If the cache was stale or empty, Tab did
nothing — unlike the local pane which always fetches fresh from /api/browse.

Added an optional onTabComplete callback to PathBar/FilePane. When Tab is
pressed with no suggestions, it fires onTabComplete(inputValue). The remote
pane wires this to handleRemoteNavigateTo, sending a BrowseRequest over WS
so local and remote share the same Tab completion behavior.
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 27, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: f9135936-a7b7-4d62-a92c-20ea692e58f9

📥 Commits

Reviewing files that changed from the base of the PR and between ffc4d97 and 1493b30.

📒 Files selected for processing (1)
  • frontend/src/components/PathBar.tsx
🚧 Files skipped from review as they are similar to previous changes (1)
  • frontend/src/components/PathBar.tsx

📝 Walkthrough

Walkthrough

This PR threads an optional onTabComplete callback from App -> FilePane -> PathBar. PathBar invokes the callback when Tab is pressed with no suggestions, and App supplies handleRemoteNavigateTo to handle remote navigation completions.

Changes

Tab-completion callback threading

Layer / File(s) Summary
PathBar tab-completion handler and interface
frontend/src/components/PathBar.tsx
PathBarProps adds optional onTabComplete?: (input: string) => void. When Tab is pressed and suggestions list is empty, the default action is prevented and the callback is invoked with the current input value.
FilePane prop forwarding
frontend/src/components/FilePane.tsx
FilePaneProps declares the optional onTabComplete prop, FilePane destructures it from props, and passes it through to the PathBar component.
App-level handler connection
frontend/src/App.tsx
Remote FilePane component receives onTabComplete={handleRemoteNavigateTo} to wire the existing remote navigation handler to tab-completion events.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Poem

🐰 I hop across the code with glee,
Threading callbacks quietly,
When Tab arrives and hints are thin,
I nudge the path and then begin,
A little leap — the file's within! 🥕

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and specifically describes the main change: adding Tab key handling in the remote PathBar to trigger a BrowseRequest when no suggestions are available, directly matching the core functionality introduced across the three modified files.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch dev

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces an onTabComplete callback prop across the App, FilePane, and PathBar components to handle tab completion when no suggestions are available. The review feedback points out a redundant type intersection in the PathBar component signature, as onTabComplete is already defined in PathBarProps.

Comment thread frontend/src/components/PathBar.tsx Outdated
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