[AAP-93044] XLAB Expand graphs after removing cards on the Dashboard page #3669
All Vouch review confidence checks passed
Residual risk 0.20 = Change Risk (0.50) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.50 · 566 lines diff across 7 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.379
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #3669"
general
weight: 0.35
lgalis
Summary
AAP-93044 Expand graphs after removing cards on the Dashboard page
<!-- What changed and why? -->
This pull request enhances the responsiveness and configurability of chart cards on the Automation Dashboard by allowing their width (and corresponding height) to adapt based on the grid layout. It introduces a new
widthprop toDashboardChartCard, updates the dashboard logic to set the appropriate width, and adds comprehensive tests to ensure correct behavior across different grid sizes.Dashboard layout and chart card sizing:
The
AutomationDashboardcomponent now calculates and passes achartCardWidthprop toDashboardChartCard, setting it to'md'for standard and wide layouts, and'xl'for extra-wide layouts. This ensures chart cards scale appropriately as the grid size changes. [[1]](diffhunk://#diff-a569d1be17b5811a84a220c557e8ed7be19740d2e150b5fb326afb86bc45f736R33) [[2]](diffhunk://#diff-a569d1be17b5811a84a220c557e8ed7be19740d2e150b5fb326afb86bc45f736R101) [[3]](diffhunk://#diff-a569d1be17b5811a84a220c557e8ed7be19740d2e150b5fb326afb86bc45f736R115)The
DashboardChartCardcomponent accepts a new optionalwidthprop and adjusts its rendered size accordingly, defaulting to'md'if not specified. The card height also adapts:'md'width uses'md'height, while'xl'width uses'lg'height. [[1]](diffhunk://#diff-f51170189987505a26524d81d8ac7f657848c3697d920393ee9d02ccc0745454L9-R20) [[2]](diffhunk://#diff-f51170189987505a26524d81d8ac7f657848c3697d920393ee9d02ccc0745454L68-R85)Testing and type improvements:
The dashboard test suite is extended to verify that chart cards receive the correct width based on the grid column count, including new tests for both
'md'and'xl'widths.The
DashboardChartCardmock in the dashboard tests is updated to accept and expose the newwidthprop, and the relevant type is imported. [[1]](diffhunk://#diff-33e16f5f652c6f94d73f671945e00b40fa8c08423615d9699878d8bc976acb81R20) [[2]](diffhunk://#diff-33e16f5f652c6f94d73f671945e00b40fa8c08423615d9699878d8bc976acb81L44-R49)DashboardChartCardcomponent's own test suite is expanded to verify the sizing logic for differentwidthvalues and grid contexts. [[1]](diffhunk://#diff-b808d284187b39b5c33276db0a8b4731c17d37b641363bed566a23fd6d35b075R3) [[2]](diffhunk://#diff-b808d284187b39b5c33276db0a8b4731c17d37b641363bed566a23fd6d35b075R131-R158)These changes collectively make the dashboard's chart cards more flexible and visually consistent across varying layouts.
Type of Change
Risk Analysis - REQUIRED
<!-- SELECT ONE. This is required — the PR check will fail if none is selected. -->
Dependencies
<!-- List any dependent PRs, required backend changes, or manual setup steps. Remove this section if none. -->
Testing
Ephemeral E2E Tests
Once PR is ready and preliminary checks pass, trigger tests by posting a comment
/run-playwrighton this PR.External Server E2E Runs
<!-- If applicable, attach run(s) from an external server using the GitHub Actions below. Mention the deployment type of the environment used.
-->
Manual Testing
<!-- Steps to verify this change, if not obvious from the Jira issue. -->
Screenshots
<!-- If applicable. Any visual/UI changes MUST include before and after screenshots. -->
<img width="2083" height="807" alt="image" src="https://github.com/user-attachments/assets/b1a93118-9471-401d-b67f-61ee485f3af4" />
<img width="2083" height="807" alt="image" src="https://github.com/user-attachments/assets/8ab66720-e35c-420f-b3e8-d69aedba7531" />