Skip to content

Conversation

@Lemeri123
Copy link
Contributor

Description of change

This pull request addresses the issue where the notification badge was displaying a fixed value of 1. The badge now dynamically shows the total number of announcements. Additionally, when a user views an announcement, the notification count decreases.
Screencast from 2025-08-11 19-01-48.webm

closes #96

Checklist

  • npm test and npm run build passes
  • documentation is changed or added (if applicable)
  • permission has been obtained to add new logo (if applicable)
  • contribution guidelines followed here

@netlify
Copy link

netlify bot commented Aug 11, 2025

Deploy Preview for adoptium-next ready!

Name Link
🔨 Latest commit af7f35f
🔍 Latest deploy log https://app.netlify.com/projects/adoptium-next/deploys/68dce212b2eff50008b2a060
😎 Deploy Preview https://deploy-preview-268--adoptium-next.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@Lemeri123 Lemeri123 changed the title Fixed Notification badge count Made Notification badge count dynamic Aug 11, 2025
@gdams
Copy link
Member

gdams commented Aug 12, 2025

Thank for raising this, my only concern here is that if you refresh the page the count returns to the original number. My thoughts are, keep this logic in place but only show notifications if they're from the last week. What do you think?

@codecov
Copy link

codecov bot commented Aug 12, 2025

Codecov Report

❌ Patch coverage is 15.51724% with 49 lines in your changes missing coverage. Please review.
✅ Project coverage is 70.79%. Comparing base (b3cb00d) to head (af7f35f).
⚠️ Report is 41 commits behind head on main.

Files with missing lines Patch % Lines
src/components/NavBar/index.tsx 0.00% 45 Missing ⚠️
src/components/Announcements/TabContent.tsx 66.66% 2 Missing ⚠️
src/components/Announcements/index.tsx 71.42% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #268      +/-   ##
==========================================
- Coverage   70.98%   70.79%   -0.20%     
==========================================
  Files         200      200              
  Lines       14029    14071      +42     
  Branches     1069     1069              
==========================================
+ Hits         9959     9961       +2     
- Misses       4053     4093      +40     
  Partials       17       17              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@Lemeri123
Copy link
Contributor Author

Thank for raising this, my only concern here is that if you refresh the page the count returns to the original number. My thoughts are, keep this logic in place but only show notifications if they're from the last week. What do you think?

Ohhhh okay thats a good idea. Let me adjust to that

@Lemeri123
Copy link
Contributor Author

@gdams

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.

Announcement notification is always on with 1 notification

3 participants