Zero icon indicating copy to clipboard operation
Zero copied to clipboard

feat: custom shortcuts, fixed reset, optimised

Open krakenftw opened this issue 7 months ago • 3 comments

READ CAREFULLY THEN REMOVE

Remove bullet points that are not relevant.

PLEASE REFRAIN FROM USING AI TO WRITE YOUR CODE AND PR DESCRIPTION. IF YOU DO USE AI TO WRITE YOUR CODE PLEASE PROVIDE A DESCRIPTION AND REVIEW IT CAREFULLY. MAKE SURE YOU UNDERSTAND THE CODE YOU ARE SUBMITTING USING AI.

  • Pull requests that do not follow these guidelines will be closed without review or comment.
  • If you use AI to write your PR description your pr will be close without review or comment.
  • If you are unsure about anything, feel free to ask for clarification.

Description

Please provide a clear description of your changes.

Added custom shortcuts, user can record keys and it will be saved in db, pull from db on page load and if overrides found, it will use those as shortcut.


Type of Change

Please delete options that are not relevant.

  • [x] 🐛 Bug fix (non-breaking change which fixes an issue)
  • [x] ✨ New feature (non-breaking change which adds functionality)
  • [ ] 💥 Breaking change (fix or feature with breaking changes)
  • [ ] 📝 Documentation update
  • [ ] 🎨 UI/UX improvement
  • [ ] 🔒 Security enhancement
  • [x] ⚡ Performance improvement

Areas Affected

Please check all that apply:

  • [ ] Email Integration (Gmail, IMAP, etc.)
  • [ ] User Interface/Experience
  • [ ] Authentication/Authorization
  • [ ] Data Storage/Management
  • [ ] API Endpoints
  • [ ] Documentation
  • [ ] Testing Infrastructure
  • [ ] Development Workflow
  • [ ] Deployment/Infrastructure

Testing Done

Describe the tests you've done:

  • [ ] Unit tests added/updated
  • [ ] Integration tests added/updated
  • [ ] Manual testing performed
  • [ ] Cross-browser testing (if UI changes)
  • [ ] Mobile responsiveness verified (if UI changes)

Security Considerations

For changes involving data or authentication:

  • [ ] No sensitive data is exposed
  • [ ] Authentication checks are in place
  • [ ] Input validation is implemented
  • [ ] Rate limiting is considered (if applicable)

Checklist

  • [ ] I have read the CONTRIBUTING document
  • [ ] My code follows the project's style guidelines
  • [ ] I have performed a self-review of my code
  • [ ] I have commented my code, particularly in complex areas
  • [ ] I have updated the documentation
  • [ ] My changes generate no new warnings
  • [ ] I have added tests that prove my fix/feature works
  • [ ] All tests pass locally
  • [ ] Any dependent changes are merged and published

Additional Notes

Add any other context about the pull request here.

Screenshots/Recordings

Add screenshots or recordings here if applicable.


By submitting this pull request, I confirm that my contribution is made under the terms of the project's license.

Summary by CodeRabbit

  • New Features

    • Enabled full keyboard shortcut customization, including hotkey recording and resetting to defaults.
    • Added the ability to fetch, update, and reset user-specific keyboard shortcuts with immediate feedback.
  • Improvements

    • Shortcut management is now dynamic and synced with the server for a more consistent experience across devices.
    • Enhanced shortcut formatting for better readability and usability in the interface.
  • Bug Fixes

    • Resolved issues with shortcut state not updating correctly after changes.

krakenftw avatar Jun 24 '25 18:06 krakenftw

@ahmetskilinc here you go, also apologies for all the chaos

krakenftw avatar Jun 24 '25 18:06 krakenftw

## Walkthrough

This change replaces the static and SWR-based keyboard shortcut management with a dynamic React Query and tRPC-powered store throughout the mail app. It enables live updating, resetting, and recording of user shortcuts, updates the UI to use these new features, and introduces corresponding backend procedures for fetching and pruning user hotkeys.

## Changes

| File(s)                                                                                         | Change Summary                                                                                           |
|-------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------|
| apps/mail/app/(routes)/settings/shortcuts/page.tsx                                              | Switched to `useShortcutStore` for shortcut management, enabled shortcut recording/reset, UI logic cleanup|
| apps/mail/lib/hotkeys/compose-hotkeys.tsx<br>apps/mail/lib/hotkeys/global-hotkeys.tsx<br>apps/mail/lib/hotkeys/mail-list-hotkeys.tsx<br>apps/mail/lib/hotkeys/navigation-hotkeys.tsx<br>apps/mail/lib/hotkeys/thread-display-hotkeys.tsx | All hotkey modules now use `useShortcutStore` for dynamic shortcut retrieval instead of static config     |
| apps/mail/lib/hotkeys/use-hotkey-utils.ts                                                       | Replaced SWR shortcut cache with React Query/tRPC store, added reset, updated key formatting              |
| apps/server/src/db/schema.ts                                                                    | Added type import for `Shortcut` (no logic change)                                                       |
| apps/server/src/main.ts                                                                         | Updated `findUserHotkeys` to return a single record, added `pruneUserHotkeys` method                     |
| apps/server/src/trpc/routes/shortcut.ts                                                         | Added `get` and `prune` procedures to shortcutRouter for fetching and pruning user hotkeys               |

## Sequence Diagram(s)

```mermaid
sequenceDiagram
    participant User
    participant ShortcutsPage
    participant useShortcutStore
    participant tRPC_Server
    participant Database

    User->>ShortcutsPage: Open Shortcuts Settings
    ShortcutsPage->>useShortcutStore: Fetch shortcuts
    useShortcutStore->>tRPC_Server: get user hotkeys
    tRPC_Server->>Database: query userHotkeys
    Database-->>tRPC_Server: return hotkeys
    tRPC_Server-->>useShortcutStore: return hotkeys
    useShortcutStore-->>ShortcutsPage: provide merged shortcuts

    User->>ShortcutsPage: Click "Reset Shortcuts"
    ShortcutsPage->>useShortcutStore: resetShortcuts()
    useShortcutStore->>tRPC_Server: prune user hotkeys
    tRPC_Server->>Database: delete userHotkeys
    Database-->>tRPC_Server: confirm deletion
    tRPC_Server-->>useShortcutStore: success
    useShortcutStore-->>ShortcutsPage: update shortcuts

Possibly related PRs

  • Mail-0/Zero#1341: Updates ZeroDB methods for user hotkeys management, including pruning, directly related to backend changes in this PR.
  • Mail-0/Zero#649: Introduces foundational hotkey hooks and recorder components that this PR activates and builds upon.

Suggested labels

High Priority

Suggested reviewers

  • ahmetskilinc
  • MrgSub

Poem

In the meadow of code, shortcuts bloom anew,
With stores and queries, their magic grew.
Rabbits hop and reset with glee,
Recording keys for all to see.
Backend and frontend now dance in sync—
Hotkeys refreshed in a single blink!
🐇⌨️✨


<!-- walkthrough_end -->


---

<details>
<summary>📜 Recent review details</summary>

**Configuration used: CodeRabbit UI**
**Review profile: CHILL**
**Plan: Pro**


<details>
<summary>📥 Commits</summary>

Reviewing files that changed from the base of the PR and between 33408bc587bc010835a61df8f41b79427bc6841d and 7c0723d72e3df2aac3e55fca644ca5cada7397c7.

</details>

<details>
<summary>📒 Files selected for processing (5)</summary>

* `apps/mail/app/(routes)/settings/shortcuts/page.tsx` (4 hunks)
* `apps/mail/lib/hotkeys/use-hotkey-utils.ts` (3 hunks)
* `apps/server/src/db/schema.ts` (1 hunks)
* `apps/server/src/main.ts` (3 hunks)
* `apps/server/src/trpc/routes/shortcut.ts` (2 hunks)

</details>

<details>
<summary>✅ Files skipped from review due to trivial changes (1)</summary>

* apps/server/src/db/schema.ts

</details>

<details>
<summary>🚧 Files skipped from review as they are similar to previous changes (4)</summary>

* apps/mail/lib/hotkeys/use-hotkey-utils.ts
* apps/mail/app/(routes)/settings/shortcuts/page.tsx
* apps/server/src/main.ts
* apps/server/src/trpc/routes/shortcut.ts

</details>

</details>
<!-- internal state start -->


<!-- DwQgtGAEAqAWCWBnSTIEMB26CuAXA9mAOYCmGJATmriQCaQDG+Ats2bgFyQAOFk+AIwBWJBrngA3EsgEBPRvlqU0AgfFwA6NPEgQAfACgjoCEYDEZyAAUASpETZWaCrKNwSPbABsvkCiQBHbGlcSHFcLzpIACIAMxJqLgZsRAJme1h8Clxk3EQAGkhY+AAPKP9EElxC/G5xZiQ6aMgAdzRkBwEG3Bp6OTDYDxTKSABrKlGyWNwW9GRbSAxHARGARgAWAHYAJg0YQchmbSx46mx/FAxcCkVsBijUXAOVeC91eVisyGGKZAJGfzUDzJVIsMYkWQCfDOeiITLZXIyeT+JgUWjwDBEcHyJjMNQYajwfAYAqtBAMWDoC5PMj2NBSegYgYeWjUFTtEh7ACq3GJPDQpEgXmhtEKNPQ3G4bwYhL5/mu8BIUj+g0qdIZGSyOTwyEw9DQkre0mZzBqUgoFHg6MxzMgSliaG8oThWsRKFijBSaX45GQJBKSE0+xZ0gYlrqRKwGIYXmwSl19muxKxGHwNG+FCIGKxTCuloEeCyf3wjGcJFi3i8yIS9HFRGwVpIb196Aw+ok+Ct30Q2cgAEEAJLEMjKXoKJT8PjxsPwCPE5AtdSZPA8G7cEb+CSK2Z675tyipPXZvbuax2VBHCiTfUJgtY4olQrkWanXDnEiFXfriifChHDD3CgzC8PgUhsFcewAHIlog64MPAxQMFSCS6rE8RiHQYohL236/m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AAGSQDm82+QDUeaMAC+m1Z74r+jXaVvvvhgqv6v37kAYsg3WixRMjt3uZfID3K0Fwn+omfnu8wv8nYvFA5oOnFAenS8BnsvxnYm/whTct8M63GHm3QPsJZRKvavGvS2qvaAbQ6gdoAgGgG3RHCj+h3esge8IfEf6vVvBAVvkfmvbfHfoQnjPftfff4Om85PvsrrPfBE9mw/k/Y/UArPMWN3FLSfWAKfXn/PGfQvIvrH4v7jUvxfMvRndC8vR9Jb74TfU/rfq4ikyvq4+vJAhvxvTkL12P6bwvuS1T3mIBKCQB/ekAAALx6A22LADth2CtB6A94O/Oxupwbizw04LEX+NnECa2x1U/cdvkhmRyjxgEVACeLXGnjYCm4asboAAH0rQiARgRzAWR0BGBh4BnDPHoEABmPgesAAAMAADgEAMAAArCIM2DiChBqwUQXwIkFoAAAbKsFoCxARBsQdYKsAECbAAAnOsG2AyCGAygkQdoPoDJx6BmwBgEIJ2B8DaAOwEgPYNiDbA0A4CPgSQAkESDYgMoZQesHWAygJBMoVkJsD4F6DrBmweuIYAMD0CCY6gZgVzTYEBwOBtARgenCiFAA== -->

<!-- internal state end -->
<!-- finishing_touch_checkbox_start -->

<details open="true">
<summary>✨ Finishing Touches</summary>

- [ ] <!-- {"checkboxId": "7962f53c-55bc-4827-bfbf-6a18da830691"} --> 📝 Generate Docstrings

</details>

<!-- finishing_touch_checkbox_end -->
<!-- tips_start -->

---

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

<details>
<summary>❤️ Share</summary>

- [X](https://twitter.com/intent/tweet?text=I%20just%20used%20%40coderabbitai%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20the%20proprietary%20code.%20Check%20it%20out%3A&url=https%3A//coderabbit.ai)
- [Mastodon](https://mastodon.social/share?text=I%20just%20used%20%40coderabbitai%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20the%20proprietary%20code.%20Check%20it%20out%3A%20https%3A%2F%2Fcoderabbit.ai)
- [Reddit](https://www.reddit.com/submit?title=Great%20tool%20for%20code%20review%20-%20CodeRabbit&text=I%20just%20used%20CodeRabbit%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20proprietary%20code.%20Check%20it%20out%3A%20https%3A//coderabbit.ai)
- [LinkedIn](https://www.linkedin.com/sharing/share-offsite/?url=https%3A%2F%2Fcoderabbit.ai&mini=true&title=Great%20tool%20for%20code%20review%20-%20CodeRabbit&summary=I%20just%20used%20CodeRabbit%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20proprietary%20code)

</details>

<details>
<summary>🪧 Tips</summary>

### Chat

There are 3 ways to chat with [CodeRabbit](https://coderabbit.ai?utm_source=oss&utm_medium=github&utm_campaign=Mail-0/Zero&utm_content=1472):

- Review comments: Directly reply to a review comment made by CodeRabbit. Example:
  - `I pushed a fix in commit <commit_id>, please review it.`
  - `Explain this complex logic.`
  - `Open a follow-up GitHub issue for this discussion.`
- Files and specific lines of code (under the "Files changed" tab): Tag `@coderabbitai` in a new review comment at the desired location with your query. Examples:
  - `@coderabbitai explain this code block.`
  -	`@coderabbitai modularize this function.`
- PR comments: Tag `@coderabbitai` in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
  - `@coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.`
  - `@coderabbitai read src/utils.ts and explain its main purpose.`
  - `@coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.`
  - `@coderabbitai help me debug CodeRabbit configuration file.`

### Support

Need help? Create a ticket on our [support page](https://www.coderabbit.ai/contact-us/support) for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

### CodeRabbit Commands (Invoked using PR comments)

- `@coderabbitai pause` to pause the reviews on a PR.
- `@coderabbitai resume` to resume the paused reviews.
- `@coderabbitai review` to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
- `@coderabbitai full review` to do a full review from scratch and review all the files again.
- `@coderabbitai summary` to regenerate the summary of the PR.
- `@coderabbitai generate docstrings` to [generate docstrings](https://docs.coderabbit.ai/finishing-touches/docstrings) for this PR.
- `@coderabbitai generate sequence diagram` to generate a sequence diagram of the changes in this PR.
- `@coderabbitai resolve` resolve all the CodeRabbit review comments.
- `@coderabbitai configuration` to show the current CodeRabbit configuration for the repository.
- `@coderabbitai help` to get help.

### Other keywords and placeholders

- Add `@coderabbitai ignore` anywhere in the PR description to prevent this PR from being reviewed.
- Add `@coderabbitai summary` to generate the high-level summary at a specific location in the PR description.
- Add `@coderabbitai` anywhere in the PR title to generate the title automatically.

### CodeRabbit Configuration File (`.coderabbit.yaml`)

- You can programmatically configure CodeRabbit by adding a `.coderabbit.yaml` file to the root of your repository.
- Please see the [configuration documentation](https://docs.coderabbit.ai/guides/configure-coderabbit) for more information.
- If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: `# yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json`

### Documentation and Community

- Visit our [Documentation](https://docs.coderabbit.ai) for detailed information on how to use CodeRabbit.
- Join our [Discord Community](http://discord.gg/coderabbit) to get help, request features, and share feedback.
- Follow us on [X/Twitter](https://twitter.com/coderabbitai) for updates and announcements.

</details>

<!-- tips_end -->

coderabbitai[bot] avatar Jun 24 '25 18:06 coderabbitai[bot]

@MrgSub lgtm, please review. closing my pr.

@krakenftw please consider the comments from the other prs you opened, to make it easier for us.

ahmetskilinc avatar Jun 24 '25 18:06 ahmetskilinc

bugbot run

MrgSub avatar Jun 27 '25 19:06 MrgSub

Will it auto rerun or manual trigger required? @MrgSub

krakenftw avatar Jun 27 '25 19:06 krakenftw

bugbot run

MrgSub avatar Jun 27 '25 20:06 MrgSub

bump @MrgSub

krakenftw avatar Jul 03 '25 12:07 krakenftw

This PR has merge conflicts and has been open for more than 3 days. It will be automatically closed. Please resolve the conflicts and reopen the PR if you'd like to continue working on it.

github-actions[bot] avatar Aug 07 '25 07:08 github-actions[bot]