Skip to content

ENG-3578: Assessment Status dashboard card#8134

Open
kruulik wants to merge 23 commits into
mainfrom
3578-assessments-card
Open

ENG-3578: Assessment Status dashboard card#8134
kruulik wants to merge 23 commits into
mainfrom
3578-assessments-card

Conversation

@kruulik
Copy link
Copy Markdown
Contributor

@kruulik kruulik commented May 7, 2026

Ticket ENG-3578

Description Of Changes

Adds an Assessment Status card to the home dashboard. This intentionally replaces the Astralis status card, which was far from being complete, and required a lot of backend changes still.

Code Changes

  • clients/admin-ui/src/home/AssessmentStatusCard.tsx — new card component; pure-function computeMetrics exported for unit tests; honest 4-bucket partition (each assessment counted once); isStale skips GENERATING and treats missing timestamps as not-stale.
  • clients/admin-ui/src/home/AstralisPanel.tsx, AstralisPanel.module.scss — deleted; the component was orphaned and the corresponding feature flag was removed.
  • clients/admin-ui/src/flags.json — removed the unused alphaDashboardAstralisCard flag entry, replace with alphaDashboardAssessmentStatusCard

Steps to Confirm

  1. cd clients/admin-ui && npm run dev:mock
  2. On the home dashboard, confirm the Assessment Status card renders with the stacked bar, legend, Purposes column, and Owners column.
  3. Click any segment / row / "View all" link and confirm it navigates to the Privacy Assessments page.

Known limitations (called out in the file comments):

  • The risk_level filter is applied client-side post-fetch; once the backend list endpoint supports it, move the filter server-side.
  • The card fetches the full assessments list to compute counts. There's a TODO marker pointing at a future /privacy-assessments/summary endpoint.

Pre-Merge Checklist

  • Issue requirements met
  • All CI pipelines succeeded
  • `CHANGELOG.md` updated (via fragment `changelog/8134-assessment-status-dashboard-card.yaml`)
    • Add a db-migration This indicates that a change includes a database migration label to the entry if your change includes a DB migration
    • Add a high-risk This issue suggests changes that have a high-probability of breaking existing code label to the entry if your change includes a high-risk change (i.e. potential for performance impact or unexpected regression) that should be flagged
    • Updates unreleased work already in Changelog, no new entry necessary
  • UX feedback:
    • All UX related changes have been reviewed by a designer
    • No UX review needed
  • Followup issues:
    • Followup issues created — backend `risk_level` filter on the assessments list endpoint; `/privacy-assessments/summary` endpoint to replace the full-list fetch on the dashboard.
    • No followup issues
  • Database migrations:
    • Ensure that your downrev is up to date with the latest revision on `main`
    • Ensure that your `downgrade()` migration is correct and works
      • If a downgrade migration is not possible for this change, please call this out in the PR description!
    • No migrations
  • Documentation:
    • Documentation complete, PR opened in fidesdocs
    • Documentation issue created in fidesdocs
    • If there are any new client scopes created as part of the pull request, remember to update public-facing documentation that references our scope registry
    • No documentation updates required

@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented May 7, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
fides-plus-nightly Ready Ready Preview, Comment May 14, 2026 4:07pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
fides-privacy-center Ignored Ignored May 14, 2026 4:07pm

Request Review

kruulik and others added 4 commits May 11, 2026 11:48
Prevents the overflow scrollbar from covering the right-side row content
(e.g. "N risk" labels) in the Assessment Status card columns.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 13, 2026

Title Lines Statements Branches Functions
admin-ui Coverage: 8%
6.69% (3048/45507) 6.05% (1592/26301) 4.68% (631/13479)
fides-js Coverage: 78%
79.17% (1977/2497) 66.25% (1249/1885) 73.31% (349/476)
privacy-center Coverage: 85%
82.53% (364/441) 79.74% (189/237) 74.07% (60/81)

Adds alphaDashboardAssessmentStatusCard and uses it to gate the card's
column (and the surrounding row when paired with the activity feed),
matching the pattern previously used for the removed Astralis card flag.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- Replace the custom CSS segment bar with the existing StackedBarChart from
  fidesui (same component DSRStatusCard uses)
- Make segmentForAssessment exhaustive over AssessmentStatus so future enum
  values fail type-check instead of silently landing in "open"
- Drop the getOrInsert Map helper; inline the get-or-create pattern
- Trim isStale to a single guard clause; lean on date-fns subDays for the
  staleness threshold
- Restore a brief TODO noting that this client-side aggregation should move
  to a /privacy-assessments/summary endpoint

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Drops the unit tests for the dashboard card's computeMetrics helper and
unexports the helpers that were only exposed for testing.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The assessments page doesn't yet support status / risk_level query
filters, so each segment legend link just dropped the user on the
unfiltered list. Point every link to the route root until the page
gains real filtering.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@kruulik kruulik marked this pull request as ready for review May 14, 2026 16:38
@kruulik kruulik requested a review from a team as a code owner May 14, 2026 16:38
@kruulik kruulik requested review from speaker-ender and removed request for a team May 14, 2026 16:38
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