Skip to content

feat: add search functionality to notifications drawer#1238

Open
anishachoudhary5 wants to merge 1 commit into
Priyanshu-byte-coder:mainfrom
anishachoudhary5:feat/notification-search
Open

feat: add search functionality to notifications drawer#1238
anishachoudhary5 wants to merge 1 commit into
Priyanshu-byte-coder:mainfrom
anishachoudhary5:feat/notification-search

Conversation

@anishachoudhary5
Copy link
Copy Markdown

Summary

Implemented searchable notifications inside the NotificationBell drawer to improve usability for users with large notification histories.

The feature adds real-time client-side filtering with debounce, accessibility improvements, and empty-state handling while preserving the existing UI and functionality.


Changes Made

  • Added search input at the top of notifications drawer
  • Implemented real-time client-side filtering
  • Added 150ms debounce for search performance
  • Added case-insensitive search support
  • Added clear (×) button to reset search
  • Added empty-state message for no matching notifications
  • Added autofocus when drawer opens
  • Added accessibility improvements (aria-label, keyboard support)
  • Preserved existing notification styling and layout
  • Kept implementation fully client-side (no backend/API changes)

Technical Details

  • Added searchQuery and debouncedQuery states
  • Added debounced filtering using useEffect
  • Added filtered notifications using .filter() and useMemo
  • Replaced original notification rendering with filtered results
  • Added search input UI and conditional empty-state rendering

Verification

  • Search updates results dynamically while typing
  • Clear button resets notifications list
  • Empty state appears correctly when no matches exist
  • Search works regardless of uppercase/lowercase
  • Existing notification functionality remains intact

Notes

  • No API or backend modifications were required
  • Existing UI/UX patterns were preserved
  • Minimal and production-ready implementation

@vercel
Copy link
Copy Markdown

vercel Bot commented May 27, 2026

@anishachoudhary5 is attempting to deploy a commit to the PRIYANSHU DOSHI's projects Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions github-actions Bot added gssoc26 GSSoC 2026 contribution type:feature GSSoC type bonus: new feature labels May 27, 2026
@github-actions
Copy link
Copy Markdown

GSSoC Label Checklist 🏷️

@Priyanshu-byte-coder — please apply the appropriate labels before merging:

Difficulty (pick one):

  • level:beginner — 20 pts
  • level:intermediate — 35 pts
  • level:advanced — 55 pts
  • level:critical — 80 pts

Quality (optional):

  • quality:clean — ×1.2 multiplier
  • quality:exceptional — ×1.5 multiplier

Validation (required to score):

  • gssoc:approved — counts for points
  • gssoc:invalid / gssoc:spam / gssoc:ai-slop — does not score

Type labels (type:*) are auto-detected from files and title. Review and adjust if needed.
Points formula: (difficulty × quality_multiplier) + type_bonus

Copy link
Copy Markdown

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

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

Thanks for your first PR on DevTrack! 🎉

A maintainer will review it within 48 hours. While you wait:

  • Make sure CI is passing (type-check + lint)
  • Double-check the PR description is filled out and the issue is linked
  • Feel free to ask questions in Discussions if you need help

If you find DevTrack useful, a ⭐ star on the repo is always appreciated — it helps the project grow and attract more contributors!

@anishachoudhary5
Copy link
Copy Markdown
Author

Hi @Priyanshu-byte-coder
i have made the PR please check.

@Priyanshu-byte-coder
Copy link
Copy Markdown
Owner

The auth.ts change adds the repo OAuth scope, which grants broad read/write access to all private and public repositories. This is a significant permission escalation beyond what's needed for this app. Please clarify why repo scope is required and whether a more narrow scope (e.g. public_repo) would suffice. The NotificationBell search feature looks good otherwise.

Copy link
Copy Markdown
Owner

@Priyanshu-byte-coder Priyanshu-byte-coder left a comment

Choose a reason for hiding this comment

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

This PR has merge conflicts with current main in src/lib/auth.ts and src/components/NotificationBell.tsx. Please rebase onto current main and resolve the conflicts.

@Priyanshu-byte-coder Priyanshu-byte-coder added gssoc:approved GSSoC: PR approved for scoring level:intermediate GSSoC: Intermediate difficulty (35 pts) labels May 28, 2026
@Priyanshu-byte-coder
Copy link
Copy Markdown
Owner

Your PR has conflicts with the current main branch. Please rebase on main to resolve conflicts and this can be reviewed for merging. Labels have been added ✅

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

Labels

gssoc:approved GSSoC: PR approved for scoring gssoc26 GSSoC 2026 contribution level:intermediate GSSoC: Intermediate difficulty (35 pts) type:feature GSSoC type bonus: new feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants