feat(remediations): Remediations page — resolve a solution family in one action (RFC-015 Phase 2) - #231
Merged
Merged
Conversation
…one action (RFC-015 Phase 2) Frontend for the backend remediation-groups API (api#288). A single patch that fixes many findings can now be resolved in one click instead of closing each finding. - src/features/remediation-groups/: types, SWR hooks (useRemediationGroups + useResolveRemediationGroup), and the ResolveGroupDialog (outcome fix_applied default / resolved, optional note, large-bulk confirm). - /remediations page: DataTable of groups (fix title, finding/asset counts, severity breakdown reusing the shared SeverityBadge), per-row 'Resolve all' gated by findings:remediation:write. - Sidebar entry under Mobilization + route-permission entries. Reuses shared primitives (PageHeader, DataTable, SeverityBadge) and the API client (CSRF-safe post). Default outcome fix_applied → the next rescan verifies. Tests: hook URL construction (incl. key URL-encoding). type-check + lint clean; next build green (/remediations route registered).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Frontend for the remediation-groups backend (api #288). A single patch that fixes many findings (Tenable's "solution" family, an SCA upgrade) can now be resolved in one click instead of
done-ing each finding.What it adds
/remediationspage (under Mobilization): a table of remediation groups — the fix (title), findings + assets counts, and a severity breakdown (reusing the sharedSeverityBadge), with a per-row Resolve all button gated byfindings:remediation:write.ResolveGroupDialog: choose the outcome — Fix applied (default; pending rescan verification) or Resolved (close now) — an optional note, and a confirm checkbox for very large bulks (mirrors the backend abuse-guard ceiling).src/features/remediation-groups/: types + SWR hooks (useRemediationGroups,useResolveRemediationGroup) hitting/api/v1/findings/remediation-groups.Conventions
Reuses shared primitives (
PageHeader,DataTable,SeverityBadge) and the CSRF-safe API client — no hand-rolled severity color map, no new permission. Memoized columns (React Compiler off). Default outcomefix_appliedso the existing auto-resolve confirms the fix on the next scan.Tests
Hook URL construction incl. key URL-encoding (vitest).
type-check+lintclean;next buildgreen (/remediationsroute registered).Backend: api #288 (RFC-015 Phase 1). This is Phase 2.