Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement global search with cmdk and UI enhancements #1270

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

gupta-soham
Copy link

@gupta-soham gupta-soham commented Sep 19, 2024

PR Fixes:

  • Implemented global search functionality:

    • Added SearchBar within the Navbar
    • Implemented using the cmdk package (similar to shadcn/ui)
    • Implemented various memorization and debouncing techniques for better performance
    • Added navigation shortcuts within the extended dialog box using ⌘+K or Ctrl+K
  • Updated UI:

    • Improved logout button design
    • Enhanced questions icon appearance
  • Documentation and routing updates:

    • Removed duplicates from README.md
    • Updated assignment links for all cohorts
    • Added route to code100x repo

Checklist before requesting a review

  • I have performed a self-review of my code
  • I assure there is no similar/duplicate pull request regarding same issue
  • Tested with .next build

Preview: New Search Bar & UI Enhancements (Desktop)

Recording.2024-09-19.160609.2.mp4

Preview: New Search Bar (Mobile)

mobile.mp4

- Added `cmdk` for shortcuts whiletraversing
- Added Command component from `shadcn/ui`
- Fixed duplicates in `README.md`
- Replaced Questions icon in `Appbar.tsx` and `ProfileDropdown.tsx`
- Added external links for Cohorts 1, 2, 3 & Web3 in `ExternalLinks.tsx`
- Updated icon sizes and improved `Logout` button styling
- Integrated `cmdk` for enhanced command palette functionality
- Optimized Navbar components using `useCallback` and `useMemo` to prevent unnecessary re-renders
- Refined state and event handling within the Navbar
 - Enhanced mobile UI with toggleable search bar
- Add navigation hotkeys to command dialog
- Implemented debounced search & memoization for better performance
- Updated `package.json` and `pnpm-lock.yaml`
@gupta-soham
Copy link
Author

gupta-soham commented Sep 19, 2024

@devsargam @hkirat @manuarora700 @siinghd
Please have a look and review this PR.

@devsargam
Copy link
Collaborator

Another pr for global search is already in 3rd iteration so closing this

@devsargam devsargam closed this Sep 25, 2024
@devsargam devsargam reopened this Sep 26, 2024
@devsargam
Copy link
Collaborator

devsargam commented Sep 26, 2024

Context for kirat: This pr is alternate to #1205. It has 1k changes while other has 300lines. Feel free to pick and merge.

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.

2 participants