Skip to content

Conversation

@Neeraj-gagat
Copy link
Contributor

@Neeraj-gagat Neeraj-gagat commented Nov 20, 2025

Description

This PR introduces keyboard shortcut support and arrow-key navigation for the Tasks dashboard. It improves usability by allowing users to interact with tasks quickly using the keyboard.

###- Fixes: #153

1.Features Added

F ====> Focus search input
A ====> Open “Add New Task” dialog
R ====> Sync tasks
C ====> Mark selected task as completed
D ====> Mark selected task as deleted
E ====> Open the edit dialog for the selected task

Shortcuts automatically disable when:
User is typing in any input field
Reports view is open
A dialog is open

2. Arrow-Key Navigation (↑ / ↓)

Up/Down arrow keys move the selection through the currently visible task rows.
Selected row stays highlighted.
Auto-scroll keeps the selected row visible when navigating.

3. Safety Guards

Keyboard shortcuts do not fire while typing in text inputs.
Navigation keys stop working while dialogs are open.

4. Structural Improvements

Added unique element IDs for automation (task-row-{id}, mark-task-complete-{id}, etc.).
Introduced hotkey guard logic using useHotkeys as hook.
Used useref so the arrows keys only override browser arrow keys when task dashboad is in view

let me know if you need any more chnages or want to chnage hot keys

Note : right now only single keys like f,a,c,d,r can trigger these shortcuts we dont need to press cntrl or alt or shift with it. let me kow if you want me to change it to that

video after chnages
Screencast from 20-11-25 06:20:17 PM IST.webm

Copy link
Collaborator

@its-me-abhishek its-me-abhishek left a comment

Choose a reason for hiding this comment

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

Great Work @Neeraj-gagat! Could you also please add PC only icons for those keys, wherever they are intended to trigger anything (e.g. show Sync <S_key> to show pressing S will trigger that, can use Key.pics Icons

@Neeraj-gagat
Copy link
Contributor Author

hey @its-me-abhishek can you suggest where should i add these {C ====> Mark selected task as completed, D ====> Mark selected task as deleted} two icons on task dashboard or should i directly add them on buttons for example == mark task as delete button.

@Neeraj-gagat
Copy link
Contributor Author

hey @its-me-abhishek i have added keys for search bar ,sync button and add task button

images after changes

image let me know if it is fine or do we need to change it . i am confused about where should i add mark task completed and mark task delete button. would appreciate your suggestion on that

@its-me-abhishek
Copy link
Collaborator

i am confused about where should i add mark task completed and mark task delete button. would appreciate your suggestion on that

It should work fine imo if you'd add C, D keys next to the complete and delete tasks buttons inside the Task Dialog

@Neeraj-gagat
Copy link
Contributor Author

added Keys c,d with buttons
image

@Neeraj-gagat
Copy link
Contributor Author

hey @its-me-abhishek i have made the changes you asked for can you review it now

@its-me-abhishek its-me-abhishek merged commit 2cfac47 into CCExtractor:main Nov 27, 2025
4 checks passed
ShivaGupta-14 pushed a commit to ShivaGupta-14/ccsync that referenced this pull request Dec 25, 2025
* added keyboard shortcut keys

* added-keys with keyboard-shortcuts

* fixed merge conflicts

* fixed tests
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.

Add Keyboard Shortcuts Support (Desktop ONLY with Key.pics Icons)

2 participants