Commit graph

336 commits

Author SHA1 Message Date
Peter Steinberger
c05d91e1b2 Fix mobile header truncation and dynamic home directory display
- Replace hardcoded home directory with dynamic detection using os.homedir()
- Add server-side path formatting using existing abbreviatePath utility
- Add displayWorkingDir field to Session interface
- Fix mobile header overflow with proper width constraints
- Update clickable-path component to accept pre-formatted display paths

This fixes both the regression where ~ substitution was broken and the
mobile header pushing content off-screen when session paths are long.

Fixes #96
2025-06-28 15:22:05 +02:00
Helmut Januschka
bdfd46a915
Add keyboard shortcut highlighter to terminal (#114)
* Add keyboard shortcut highlighter to terminal

- Create keyboard-shortcut-highlighter.ts with comprehensive pattern matching
- Integrate highlighter into terminal component alongside URL highlighting
- Support clickable shortcuts like "Ctrl+R", "Ctrl+A", "esc to interrupt"
- Style shortcuts with greyish color and dotted underlines (not blue links)
- Send actual key sequences when shortcuts are clicked
- Handle overlapping matches and avoid double-processing

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

* Fix keyboard shortcut input handling - add missing event listener

The keyboard shortcut highlighter was dispatching 'terminal-input' events
but the session-view component wasn't listening for them. Added:

- @terminal-input event listener on vibe-terminal component
- handleTerminalInput method that forwards to inputManager.sendInputText()

Now clicked shortcuts like 'Ctrl+R' properly send input to the terminal.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

* Add Claude Code interactive prompt support to keyboard shortcut highlighter

Make numbered options in Claude Code prompts clickable:
- Pattern: '❯ 1. Yes' or '  2. Yes, and don't ask again'
- Clicking sends the number (1, 2, 3, etc.) to terminal
- Handles both selected (❯) and unselected options
- Uses multiline regex matching for line-start patterns

Now users can click numbered options instead of typing numbers.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

* Fix Claude Code prompt patterns to handle indented options

Previous patterns required line-start anchors which failed for indented
options within bordered terminal output. Updated patterns:

- Remove restrictive line-start anchors (^)
- Add whitespace-flexible patterns for indented options
- Support both cursor-selected (❯) and plain numbered options
- Handle 'Yes, proceed' and 'No, exit' style options

Now correctly matches:
'❯ 1. Yes, proceed' and '  2. No, exit' patterns.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

* Simplify Claude Code prompt patterns to be fully generic

Replace keyword-specific patterns with generic numbered option matching:

- ❯ 1. (cursor-selected options)
- 1. xxxxx (any numbered option with text)

Now matches any numbered list item regardless of content:
'1. Yes, proceed', '2. No, exit', '3. Maybe later', etc.

Much cleaner and more flexible than keyword-based matching.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

* Fix Claude Code prompt patterns to highlight full option lines

Changed from matching only first word to matching entire lines:
- /❯\s*(\d+)\.\s+.*/ - highlights complete cursor-selected option
- /(\d+)\.\s+.*/ - highlights complete numbered option

Now '1. Yes, proceed' and '2. No, exit' are fully underlined
instead of just '1. Yes' and '2. No'.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

---------

Co-authored-by: Claude <noreply@anthropic.com>
2025-06-28 02:15:50 +02:00
Helmut Januschka
6e98fa9ce6
Fix Japanese input duplication on iOS web (GitHub #99) (#102)
Added comprehensive IME composition support to prevent duplication of Japanese, Chinese, and Korean text input on mobile devices.

Changes:
- DirectKeyboardManager: Added composition event handlers to wait for final text
- MobileInputOverlay: Added composition state tracking to prevent intermediate updates
- Fixed null safety issues and unused parameter warnings
- Comprehensive documentation explaining IME implementation

Bug Fixed:
Previously, intermediate composition characters were sent to terminal during Japanese typing, causing duplicated text. Now properly waits for composition completion before sending final text to terminal.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-authored-by: Claude <noreply@anthropic.com>
2025-06-27 21:37:43 +02:00
Helmut Januschka
b98a8d190e
Add Shift+Tab key to mobile QuickKeyboard (#111)
* Add Shift+Tab key to mobile QuickKeyboard per PR #105 feedback

Implements Peter's suggestion to add Shift+Tab key to mobile quick keyboard
for enhanced Claude Code planning mode support on mobile devices.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

* Fix Monaco Editor keyboard input cancellation

Enhanced isKeyboardShortcut detection to properly handle Monaco Editor
elements, preventing keyboard event interference while maintaining
terminal functionality.

- Added contentEditable detection
- Added .monaco-editor container detection
- Added data-keybinding-context detection
- Added .editor-container detection

This resolves the 'Canceled: Canceled' errors when typing in Monaco Editor
while preserving Shift+Tab functionality for Claude Code planning mode.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

---------

Co-authored-by: Claude <noreply@anthropic.com>
2025-06-27 21:32:06 +02:00
Helmut Januschka
9aaac17150
Add Shift+Tab support for Claude Code planning mode (GitHub #100) (#105)
* Add Shift+Tab support for Claude Code planning mode (GitHub #100)

Added proper Shift+Tab key sequence handling to enable Claude Code mode switching.

Changes:
- Added 'shift_tab' to SpecialKey type definition
- Updated input-manager.ts to detect Shift+Tab combination (e.shiftKey)
- Updated direct-keyboard-manager.ts for mobile Shift+Tab support
- Added shift_tab mapping to PTY manager (sends \x1b[Z escape sequence)

This allows users to press Shift+Tab in VibeTunnel to switch between Claude Code
modes (autoaccept, planning, regular) as expected.

Technical Details:
- Shift+Tab sends the standard terminal escape sequence \x1b[Z (CSI Z)
- Both desktop and mobile input handlers now support the key combination
- Maintains backward compatibility with regular Tab functionality

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

* Fix Shift+Tab not being sent as special key

Added 'shift_tab' to the special keys list in input-manager.ts so it gets
sent as {"key": "shift_tab"} instead of {"text": "shift_tab"}.

This was the missing piece - the frontend was correctly detecting Shift+Tab
but then sending it as text instead of a special key, so the server couldn't
map it to the \x1b[Z escape sequence.

Now Shift+Tab will properly send {"key": "shift_tab"} in the API request.

* Fix failing CI test in session-list.test.ts

Updated test expectation to check for 'compactMode' instead of
non-existent 'showCreateModal' property. This was a stale test
that was unrelated to the Shift+Tab changes but was blocking CI.

All tests now pass.

---------

Co-authored-by: Claude <noreply@anthropic.com>
2025-06-27 21:00:09 +02:00
Armin Ronacher
47e475b967 Claude knows how to flexbox 2025-06-27 12:26:42 +02:00
Armin Ronacher
ae2b8a2298 Fixed session status detection 2025-06-27 11:50:38 +02:00
Peter Steinberger
553dcff448 hide scoll down button when quick keyboard is active 2025-06-27 02:02:22 +02:00
Peter Steinberger
b84e6faea2 keyboard tweaks 2025-06-27 02:02:19 +02:00
Peter Steinberger
27416a7ce3 instead of transform, reduce terminal size with keyboard 2025-06-27 01:54:56 +02:00
Peter Steinberger
af44f2e7bb flip buttons 2025-06-27 01:54:40 +02:00
Peter Steinberger
664bdb75d4 reorganize header 2025-06-27 01:50:22 +02:00
Peter Steinberger
ddc0ea1b49 ensure keyboard shows up after tab key is pressed
works around Safari security, where focus only works when the user clicks and we dispatch sync
2025-06-27 01:50:17 +02:00
Peter Steinberger
86ba5eb78f keyboard tweaks 2025-06-27 01:38:19 +02:00
Peter Steinberger
924613bf55 use tailwind for blur 2025-06-27 01:38:13 +02:00
Peter Steinberger
24fe9043d1 create form moved up to be fully centered 2025-06-27 01:37:56 +02:00
Peter Steinberger
bf3e09a28c conect sidebar header 2025-06-27 01:37:42 +02:00
Peter Steinberger
4b7a073975 keyboard moves terminal up 2025-06-27 01:37:31 +02:00
Peter Steinberger
9d775e6b31 reduce heider height 2025-06-27 01:37:04 +02:00
Peter Steinberger
83137d25d6 dismiss sidebar in portrait mobile 2025-06-27 01:36:55 +02:00
Peter Steinberger
8eba43a536 Make sidebar dismissable 2025-06-27 01:09:18 +02:00
Peter Steinberger
35ed9556ca change ABC to Done to dismiss 2025-06-27 01:09:08 +02:00
Peter Steinberger
9cc2b9a195 direct mode is for mobile 2025-06-27 01:08:53 +02:00
Peter Steinberger
78659df911 ensure keyboard stays visible 2025-06-27 01:03:15 +02:00
Peter Steinberger
d19d275129 restore settings 2025-06-27 01:03:06 +02:00
Peter Steinberger
29ddfb9d8a add direct keyboard fob logic 2025-06-27 00:55:47 +02:00
Peter Steinberger
a571b59d0d unify settings with notifications 2025-06-27 00:55:36 +02:00
Peter Steinberger
76d520762f remove global fade 2025-06-27 00:54:55 +02:00
Peter Steinberger
f104974dce add blur to mobile fobs 2025-06-27 00:54:45 +02:00
Peter Steinberger
c78a162789 remove global view transition 2025-06-27 00:54:35 +02:00
Peter Steinberger
35ed9d2800 fix create session animation being stuttery om mobile 2025-06-27 00:42:23 +02:00
Peter Steinberger
b927d6665f restructure buttons 2025-06-27 00:41:53 +02:00
Peter Steinberger
77e3683802 Add keyboard fob 2025-06-27 00:41:37 +02:00
Peter Steinberger
7e089c3857 faster animations and consistent in/out 2025-06-27 00:41:20 +02:00
Peter Steinberger
f41b54799a realign buttons 2025-06-27 00:03:22 +02:00
Peter Steinberger
c70330bcfd
Migrate to Microsoft node-pty v1.1.0-beta34 (#87) 2025-06-26 23:10:05 +02:00
Helmut Januschka
5a4b939564
Fix URL link detection for wrapped URLs on mobile terminals (#85)
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Peter Steinberger <steipete@gmail.com>
2025-06-26 22:37:49 +02:00
Manuel Maly
328e000715
Split session view file (#89)
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Peter Steinberger <steipete@gmail.com>
2025-06-26 21:15:07 +02:00
Peter Steinberger
94fde5a75c Remove double buttons 2025-06-26 10:29:29 +02:00
Mario Zechner
ec64433632 Add Claude debugger patch and disable bell character handling
- Add claude-patch.ts to enable debugging Claude Code with Node.js --inspect flag
- Temporarily disable bell character handling in pty-manager.ts due to VS Code terminal hanging issue
- Fix TypeScript linter errors across test files (replace any types with proper interfaces)

The bell character handling was causing VS Code terminals to hang when pasting certain content.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-06-25 20:05:41 +02:00
Armin Ronacher
2441453287 Special case ios detection for push (still broken) 2025-06-25 15:27:50 +02:00
Peter Steinberger
e847223a32 wip: focus management for text input 2025-06-25 15:00:28 +02:00
Peter Steinberger
54414e2aeb Add settings icon 2025-06-25 15:00:28 +02:00
Peter Steinberger
222e746753 Show settings in no-auth mode 2025-06-25 12:22:13 +02:00
Peter Steinberger
58e85de2ea test tweaks 2025-06-25 12:22:13 +02:00
Peter Steinberger
f59df3c645 new linter 2025-06-25 12:22:13 +02:00
Peter Steinberger
60d4556a58 Add new terminal quick keyboard 2025-06-25 12:22:13 +02:00
Peter Steinberger
a210bae07c add setting to control if new terminal spawns windows 2025-06-25 10:18:10 +02:00
Peter Steinberger
81ec1a4a35 test fixes 2025-06-25 10:17:39 +02:00
Peter Steinberger
6cbaa55573 test fixes 2025-06-25 05:14:06 +02:00