Skip to content

feat(faq): add explanatory tooltips to FreshnessBadge states - #225

Open
MohammedSameerInamdar wants to merge 1 commit into
vicharanashala:mainfrom
MohammedSameerInamdar:feat/freshness-badge-tooltips
Open

feat(faq): add explanatory tooltips to FreshnessBadge states#225
MohammedSameerInamdar wants to merge 1 commit into
vicharanashala:mainfrom
MohammedSameerInamdar:feat/freshness-badge-tooltips

Conversation

@MohammedSameerInamdar

Copy link
Copy Markdown

What changed

Adds a title attribute to each state of the FreshnessBadge component (Verified, Under review, Update requested, Nearing expiry) so users can hover over a badge to see a plain-language explanation of what it means. Currently the badges show only an icon and short label with no context for what "under review" or "verified" actually signifies to the reader.

Related issue

No linked issue — this is a self-proposed feature (confirmed with program contact as no open issues were unclaimed at time of contribution).

Type of change

  • Bug fix
  • Feature
  • Refactor (no behaviour change)
  • Docs / comments only
  • CI / tooling

Area affected

  • Backend (Express / Mongoose)
  • Frontend (React / Vite)
  • Admin / Train tab (/admin/*)
  • Community (/community — posts, comments, auto-answer)
  • Search (hybrid text retrieval, training stats)
  • Auth / middleware / samagama.in bridge
  • Crons / schedulers / embedding-warm
  • Observability (Sentry / logging / Discord alerts)
  • Docs

CI verification

  • cd apps/backend && npx tsc --noEmit exits 0
  • cd apps/backend && npx vitest run — all tests pass
  • cd apps/frontend && npx tsc --noEmit exits 0
  • cd apps/frontend && npx vitest run — all tests pass
  • pnpm run lint — 0 errors (152 warnings is the baseline)
  • GitHub Actions green on the merge commit (CI, CodeQL, Build & Deploy)
  • Tested with a real API hit or browser interaction if behaviour changed
  • Tests added or updated for the change
  • Single logical change — unrelated fixes noted in description, not fixed here
  • Docs updated if route / API / env var / pipeline behaviour changed
  • Rebased onto main, no merge commits

Notes for reviewer

Could not verify the tooltip visually in a running browser — local MongoDB Atlas instance has no seeded FAQ data and registration is currently disabled, so no FAQ cards were available to hover over. Verified correctness instead via a component-level Vitest test (FreshnessBadge.test.tsx) asserting the title attribute renders with the correct text for all badge states. The pre-existing lint error in ai-client.service.ts (line 623) is unrelated to this change.

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.

1 participant