Commit Graph

12 Commits

  • fix: RPC mode session management not saving sessions
    Since version 0.9.0, RPC mode (--mode rpc) was not saving messages to
    session files. The agent.subscribe() call with session management logic
    was only present in the TUI renderer after it was refactored.
    
    RPC mode now properly saves sessions just like interactive mode.
    
    Added test for RPC mode session management to prevent regression.
    
    Fixes #83
    
    Thanks @kiliman for reporting this issue!
  • fix(tui): use consistent accent color for entire selected line in file selector
    Previously, the selected line in @ fuzzy search and Tab completion used
    accent color for prefix/label but muted color for description. Now the
    entire selected line uses the accent color for better visual consistency.
  • Improved HTML export with timestamps, better styling, and comprehensive stats
    - Added timestamps to each user and assistant message (HH:MM:SS format)
    - Fixed text clipping issues with comprehensive word-wrapping CSS
    - Improved font selection: ui-monospace, Cascadia Code, Source Code Pro
    - Reduced font sizes for more compact display (12px base, down from 14px)
    - Added model switch indicators in conversation timeline with subtle background
    - Created dedicated Tokens & Cost section showing:
      - Cumulative input/output/cache read/write tokens
      - Cost breakdown by token type with 4 decimal precision
      - Total cost in bold
      - Context usage with token count, percentage, and model identification
    - Now displays all unique models used during session (not just initial model)
    - Made Messages section more compact (reduced gaps, removed redundant fields)
    
    Closes #51
    Closes #52
  • Fix editor cursor navigation for wrapped lines, add word navigation
    - Up/down arrows now navigate visual (wrapped) lines instead of logical lines
    - Fixed double cursor display at wrap boundaries
    - Added word by word navigation via Option+Left/Right or Ctrl+Left/Right
    - Updated README keyboard shortcuts documentation
    
    Closes #61
  • WIP: Add theming system with /theme command
    - Consolidated theme system into single src/theme/ directory
    - Created Theme class with fg(), bg(), bold(), italic(), underline()
    - Added dark and light built-in themes with 36 color tokens
    - Support for custom themes in ~/.pi/agent/themes/*.json
    - JSON schema for theme validation
    - Theme selector UI with /theme command
    - Save theme preference to settings
    - Uses chalk for text formatting to preserve colors
    
    TODO:
    - Replace hardcoded colors throughout TUI components
    - Apply markdown theming to Markdown components
    - Add theme support to all TUI elements
  • feat(tui): improve editor Ctrl/Alt word and line deletion shortcuts
    - Add Ctrl+W for word deletion (stops at whitespace/punctuation)
    - Add Ctrl+U for delete to start of line (merges with previous line at col 0)
    - Change Ctrl+K from delete entire line to delete to end of line (merges with next line at EOL)
    - Add Option+Backspace support in Ghostty (maps to Ctrl+W via ESC+DEL sequence)
    - Cmd+Backspace in Ghostty works as Ctrl+U (terminal sends same control code)
    - Update README and CHANGELOG with new keyboard shortcuts
    
    Fixes #2, Fixes #3