Skip to content

feat(ui): Implement Global Command Palette for Enhanced Navigation and Search - #8387

Open
nishtha-agarwal-211 wants to merge 1 commit into
JhaSourav07:mainfrom
nishtha-agarwal-211:feat/command-palette-cmd-k
Open

feat(ui): Implement Global Command Palette for Enhanced Navigation and Search#8387
nishtha-agarwal-211 wants to merge 1 commit into
JhaSourav07:mainfrom
nishtha-agarwal-211:feat/command-palette-cmd-k

Conversation

@nishtha-agarwal-211

Copy link
Copy Markdown
Contributor

Description

Fixes #8357

Implements a global Command Palette modal (Cmd+K / Ctrl+K) for CommitPulse, enabling instant keyboard-driven search, page navigation, theme shortcuts, and external repository links from anywhere in the application.

Key Enhancements

  • Global Command Palette Component (components/CommandPalette.tsx): Real-time fuzzy search filtering, arrow key navigation (ArrowUp/ArrowDown), item execution (Enter), escape key dismiss (Esc), and proper ARIA accessibility attributes (role="dialog", aria-modal="true", aria-label="Command Palette").
  • Navbar Layout Integration (app/components/navbar.tsx): Wired up global Cmd+K / Ctrl+K keyboard event listener across all routes, safely scoped so it does not trigger when typing inside text input elements.
  • Comprehensive Unit Testing (components/CommandPalette.test.tsx): Added 7 new unit tests covering initial hidden state, search query filtering, empty results fallback, keyboard navigation, and accessibility standards.

Pillar

  • 🎨 Pillar 1 — New Theme Design
  • 📐 Pillar 2 — Geometric SVG Improvement
  • 🕐 Pillar 3 — Timezone Logic Optimization
  • 🛠️ Other (Feature / UI Enhancement)

Visual Preview

  • Trigger Shortcut: Cmd + K (macOS) / Ctrl + K (Windows & Linux)
  • Categorized Actions:
    • Navigation: Home (/), SVG Generator (/generator), Developer Compare (/compare), Burnout Radar (/burnout-analyzer), Customization Studio (/#customization-studio).
    • Quick Actions: Open Keyboard Shortcuts modal (?), Scroll to Top.
    • External: GitHub Repository.

Checklist before requesting a review:

  • I have read the CONTRIBUTING.md file.
  • I have tested these changes locally (localhost:3000).
  • I have run npm run format and npm run lint locally and resolved all errors.
  • My commits follow the Conventional Commits format (feat(ui): add Command Palette (Cmd+K / Ctrl+K) for global navigation and search).
  • I have made sure that I have only 1 clean commit to merge in this PR.
  • All automated unit tests pass (components/CommandPalette.test.tsx & app/components/navbar).

Copilot AI review requested due to automatic review settings July 27, 2026 02:02
@vercel

vercel Bot commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

@nishtha-agarwal-211 is attempting to deploy a commit to the jhasourav07's projects Team on Vercel.

A member of the Team first needs to authorize it.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@retenta-bot

retenta-bot Bot commented Jul 27, 2026

Copy link
Copy Markdown

This PR adds a Command Palette feature that enhances navigation and search capabilities through keyboard shortcuts, aligning with our previous decisions to improve accessibility and user productivity. Similar enhancements have been validated in past decisions, such as adding keyboard shortcuts for common actions and improving accessibility with ARIA support. This implementation not only streamlines user interactions but also adheres to our commitment to accessibility standards. Great work on this feature! Looking forward to your updates.

@retenta-bot retenta-bot Bot changed the title feat(ui): add Command Palette (Cmd+K / Ctrl+K) for global navigation and search feat(ui): Implement Global Command Palette for Enhanced Navigation and Search Jul 27, 2026
@github-actions

Copy link
Copy Markdown
Contributor

📦 Next.js Bundle Size Report (Gzipped Sizes)

Asset PR Size Base Size Difference Status
static/chunks/1925-[hash].js - 2.17 KB -2.17 KB (-100.00%) 🗑️ Deleted
static/chunks/2759-[hash].js 165.15 KB - +165.15 KB (++100%) 🆕 New
static/chunks/4116-[hash].js - 2.54 KB -2.54 KB (-100.00%) 🗑️ Deleted
static/chunks/4885-[hash].js 2.68 KB - +2.68 KB (++100%) 🆕 New
static/chunks/498-[hash].js - 5.56 KB -5.56 KB (-100.00%) 🗑️ Deleted
static/chunks/5366-[hash].js 3.15 KB - +3.15 KB (++100%) 🆕 New
static/chunks/5894-[hash].js 3.36 KB - +3.36 KB (++100%) 🆕 New
static/chunks/6595-[hash].js - 5.06 KB -5.06 KB (-100.00%) 🗑️ Deleted
static/chunks/6995-[hash].js 5.67 KB - +5.67 KB (++100%) 🆕 New
static/chunks/7704-[hash].js 2.67 KB 2.50 KB +0.17 KB (+6.76%) 🔴 Regression
static/chunks/8002-[hash].js - 52.58 KB -52.58 KB (-100.00%) 🗑️ Deleted
static/chunks/8083-[hash].js 5.08 KB - +5.08 KB (++100%) 🆕 New
static/chunks/8117-[hash].js - 5.66 KB -5.66 KB (-100.00%) 🗑️ Deleted
static/chunks/8277-[hash].js 50.47 KB - +50.47 KB (++100%) 🆕 New
static/chunks/9376-[hash].js 5.59 KB - +5.59 KB (++100%) 🆕 New
static/chunks/9433-[hash].js - 6.21 KB -6.21 KB (-100.00%) 🗑️ Deleted
static/chunks/9822-[hash].js 2.66 KB 2.52 KB +0.14 KB (+5.75%) 🔴 Regression
static/chunks/app/(root)/dashboard/[username]/wrapped/page-[hash].js 3.26 KB 3.12 KB +0.14 KB (+4.54%) 🔴 Regression
static/chunks/app/burnout-analyzer/page-[hash].js 11.60 KB 13.10 KB -1.50 KB (-11.43%) 🟢 Improvement
static/chunks/app/documentation/page-[hash].js 1.97 KB 1.83 KB +0.14 KB (+7.41%) 🔴 Regression
static/chunks/app/guidelines/page-[hash].js 4.44 KB 4.27 KB +0.17 KB (+4.10%) 🔴 Regression
static/chunks/app/layout-[hash].js 15.26 KB 13.69 KB +1.57 KB (+11.50%) 🔴 Regression
static/chunks/e2ce8796-[hash].js 38.90 KB - +38.90 KB (++100%) 🆕 New
static/css/[hash].css 41.99 KB 41.95 KB +0.04 KB (+0.11%) 🔴 Regression

📊 Summary of Totals

Category PR Size Base Size Difference
Total JS 4832.85 KB 4052.50 KB +780.35 KB (+19.26%)
Total CSS 339.57 KB 338.94 KB +0.62 KB (+0.18%)

@Aamod007 Aamod007 added level:intermediate Moderate complexity tasks quality:clean PR follows clean coding practices, proper formatting, documentation, and maintainability standards. mentor:Aamod007 type:feature New features, additions, or enhancements type:testing Adding, updating, or fixing tests labels Jul 27, 2026

@Aamod007 Aamod007 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

The Command Palette implementation is well structured — clean keyboard shortcut handling (Cmd+K with typing-target guard), proper dialog accessibility (aria-modal, aria-label), and comprehensive test coverage with search filtering and keyboard navigation. The fade-in/out animation with mount/unmount timing is a nice UX touch.

CI is failing though. Please check the logs and push fixes.

Labels: level:intermediate (3 files, 499 lines, full feature + tests), quality:clean, type:feature, type:testing, mentor:Aamod007

@Aamod007 Aamod007 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Re-reviewing after noting the only CI failure is Vercel authorization (not code-related). All other checks (Format · Lint · Typecheck · Test, Production Build, CodeQL) pass. Approving — the Vercel deploy auth is a repo-level config issue, not a code problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

level:intermediate Moderate complexity tasks mentor:Aamod007 quality:clean PR follows clean coding practices, proper formatting, documentation, and maintainability standards. type:feature New features, additions, or enhancements type:testing Adding, updating, or fixing tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature Request: Global Command Palette (Cmd+K / Ctrl+K) for Quick Navigation & Actions

3 participants