fix(ui): use the info tone for unrecognized skip reasons in the audit feed - #8726
fix(ui): use the info tone for unrecognized skip reasons in the audit feed#8726rsnetworkinginc wants to merge 1 commit into
Conversation
… instead of ready skipReasonTone fell back to the green ready tone for any reason string outside the four enumerated skip reasons, so an unrecognized/legacy value from the API rendered as a healthy-looking pill in the audit feed. Mirror the established convention from contributor-quality-table-model (band: string degrades to a neutral pill): the fallback now returns info. Adds direct fallback-branch coverage and a render test asserting an unmapped reason never gets the ready tone; the four enumerated reasons keep their existing tones.
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
|
Tip ✅ LoopOver review result - approve/merge recommendedReview updated: 2026-07-26 01:15:29 UTC
Review summary Nits — 3 non-blocking
Decision drivers
Context & advisory signals — never blocks the verdict
Linked issue satisfactionAddressed Review context
Contributor next steps
Signal definitions
🧪 Chat with LoopOverAsk LoopOver a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.
Full command reference: https://loopover.ai/docs/loopover-commands 🧪 Experimental — new and may change. Visual preview
Click any thumbnail to open the full-size screenshot. Before = production · After = this PR's preview deploy. Scroll preview
A short scroll-through clip (desktop) — click either thumbnail to open the full animation. Evidence for scroll-linked behavior a single screenshot can't show. 🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by LoopOver, a quiet PR intelligence layer for OSS maintainers.
|
|
This pull request changes UI/visual code but its screenshot evidence is incomplete. Every required viewport × theme combination needs its own before/after image pair in a labeled table row (e.g. "Desktop · Light | before | after"). Still missing: Desktop · Dark, Tablet · Dark, Mobile · Dark. Please resubmit with the remaining rows filled in. See https://github.com/JSONbored/loopover/blob/main/.claude/skills/contributing-to-loopover/SKILL.md for the exact format and examples. This is an automated maintenance action. |


Closes #8666
Problem
skipReasonTone(apps/loopover-ui/src/components/site/audit-feed-model.ts) falls back to"ready"— the green, healthy-looking tone — for any reason string outside the four enumerated skip reasons.SkippedPrAuditItem.reasonis a plainstringat the API boundary (the same intentional widening ascontributor-quality-table-model.ts'sband: string), so a new or legacy backend skip reason silently rendered in the audit feed as a green "ready" pill, implying a positive state for something actually unclassified — contrary to the sibling model's explicit "an unrecognized value degrades to a neutral pill" convention.Fix
The fallback branch now returns the neutral
"info"tone, mirroringcontributor-quality-table-model.ts's established convention. None of the four enumerated reasons map to"ready", so no enumerated reason's behavior changes — only the unrecognized-value fallback.Tests (new coverage for a branch that had none)
Added to
apps/loopover-ui/src/components/site/audit-feed.test.tsx, both red onmainbefore the fix:"info", not"ready"skipReasonTone("legacy_skip_reason")assertion (plus""), exercising the previously zero-coverage fallback branchexpected 'ready' to be 'info'<AuditFeed />with an unmappedreason: "legacy_skip_reason"item and asserts the pill's classes contain the info tone (text-mint) and not the ready tone (text-success)border-success/40 bg-success/10 text-successinfo/warn/degraded); existingsurface_offrender tests untouchedFull file run: 17/17 passing;
tsc --noEmitclean; prettier/eslint clean on both changed files.