Skip to content

feat: add keyboard shortcut support for chat actions#632

Open
kareena0229 wants to merge 2 commits into
param20h:devfrom
kareena0229:feat-keyboard-shortcuts-chat
Open

feat: add keyboard shortcut support for chat actions#632
kareena0229 wants to merge 2 commits into
param20h:devfrom
kareena0229:feat-keyboard-shortcuts-chat

Conversation

@kareena0229

Copy link
Copy Markdown
Contributor

Summary

Implemented keyboard shortcut support for common chat actions to improve accessibility and productivity.

Added Shortcuts

  • Ctrl + Enter → Send message
  • Esc → Clear chat input
  • Ctrl + K → Focus chat input
  • Ctrl + Shift + C → Copy latest assistant response

Changes Made

  • Added global keyboard listener using useEffect
  • Added input focus support using inputRef
  • Implemented latest assistant message copy functionality
  • Prevented shortcut execution while typing in unrelated fields

Testing

  • Verified shortcuts work on Dashboard chat panel
  • Verified existing chat functionality remains unchanged
  • npm run build passes successfully
  • npm run lint passes with no new warnings introduced
  • Frontend builds successfully
  • Backend starts successfully
  • Authentication flow tested successfully
  • Document upload verified

Note: AI response generation could not be fully validated due to backend/RAG configuration issues unrelated to this PR.
Fixes #631

Screenshots

Screenshot 2026-06-17 211841

npm run build test

image

npm run lint tested

image

@kareena0229 kareena0229 requested a review from param20h as a code owner June 17, 2026 16:14
@kareena0229

Copy link
Copy Markdown
Contributor Author

@param20h do review this PR

Testing Completed

  • Successfully built the frontend using npm run build with no errors.
  • Successfully started the backend using python -m uvicorn app.main:app --reload.
  • Verified user authentication and login flow.
  • Verified document upload functionality.
  • Confirmed UI changes are working as expected and do not affect existing functionality.

Note: AI response generation could not be fully validated in the local environment due to backend/RAG configuration requirements (document/session authentication and model setup). This is unrelated to the changes introduced in this PR.

Screenshots and build verification have been attached for reference.

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.

[Enhancement] Add Keyboard Shortcut Support for Chat Actions

1 participant