Skip to content

feat(tabs): shell picker in caret dropdown + WSL home fix + dropdown overflow fixes#43

Open
egertaia wants to merge 6 commits into
amirlehmam:masterfrom
egertaia:feat/shell-picker-upstream
Open

feat(tabs): shell picker in caret dropdown + WSL home fix + dropdown overflow fixes#43
egertaia wants to merge 6 commits into
amirlehmam:masterfrom
egertaia:feat/shell-picker-upstream

Conversation

@egertaia

@egertaia egertaia commented Jun 18, 2026

Copy link
Copy Markdown

Summary

Adds a shell picker to the new-tab caret dropdown, plus a WSL home-directory fix.

Stacked on #38. This branch merges in the terminal-toolbar redesign (#38), so the diff includes its icon-based toolbar. The dropdown-clipping fix is provided by #38's portal-rendered menus — this PR layers the shell picker into that menu. Merge #38 first, then this PR shows only the shell-picker delta.

This PR's own changes

  • Shell picker in the dropdown: the caret next to + lists all detected shells (PowerShell 7, Windows PowerShell, WSL, Command Prompt) so you can open each in its own tab. Falls back to a generic Terminal entry if none are detected. Each shell spawns a PTY with its specific executable.
  • WSL starts in Linux home: wsl.exe was being spawned with a Windows CWD, which made it mount into /mnt/c/.... Added --cd ~ so WSL always starts in the Linux home directory.

From #38 (merged in here)

  • Real SVG icon toolbar (New / Layout split-buttons / Close).
  • Portal-rendered dropdowns — fixes the menu being clipped by .surface-tab-bar { overflow: hidden } and by adjacent panes.

Test plan

  • Click caret — menu lists detected shells above Browser / Markdown
  • Select WSL — new tab opens in Linux home (~), not /mnt/c/...
  • Select PowerShell — new tab opens PowerShell
  • Split into two panes, open the menu on the left pane — it renders on top of the right pane (not clipped)

Notes

🤖 Generated with Claude Code

kevmtt and others added 5 commits June 16, 2026 19:28
…ehmam#34)

Replace the Unicode-glyph toolbar controls (+, caret, split glyphs, x) with
stroke-based inline SVG icons, consolidate the two split buttons into a single
Layout split-button with a dropdown, and fix the new-tab dropdown that was
invisible.

- New `icons.tsx`: small `currentColor` SVG icons (add, split, split-down,
  close, caret).
- `SurfaceTabBar`: icon split-buttons (New / Layout / Close); dropdown menus
  rendered via portal so they aren't clipped.
- Dropdown bug: `.surface-tab-bar` is height:28px + overflow:hidden, so the
  absolutely-positioned menu (top:30px) was clipped and never painted —
  rendering the menu in a portal fixes it.
- Restyle the control cluster in `splitpane.css` (rounded hover pills, accent
  colors).

Behavior, IPC, and store are unchanged.
… menu

- SurfaceTabBar: fetch available shells and show them in the ▾ dropdown
  (PowerShell, WSL, cmd, etc.) above Browser/Markdown
- PaneWrapper: load shells via window.wmux.system.getShells() on mount,
  pass shell command to addSurface so each tab spawns the right PTY
- splitpane.css: change surface-tab-bar overflow hidden→visible so the
  absolute-positioned dropdown is no longer clipped by its parent

Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
wsl.exe spawned with a Windows cwd mounts it as /mnt/c/... which puts
you in the Windows filesystem. Passing --cd ~ overrides that and starts
WSL in the Linux home directory.

Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
…panes

Render the new-surface menu via createPortal at document.body with
position:fixed, anchored to the caret button's getBoundingClientRect.
This lets it float above all pane boundaries regardless of split layout.

Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
@kevmtt

kevmtt commented Jun 18, 2026

Copy link
Copy Markdown

Dropdowns are also fixed in this PR: #38

# Conflicts:
#	src/renderer/components/SplitPane/SurfaceTabBar.tsx
#	src/renderer/styles/splitpane.css
@egertaia egertaia force-pushed the feat/shell-picker-upstream branch from f260ad4 to 60dc862 Compare June 18, 2026 17:38
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.

2 participants