Skip to content

Issue 2204 - added modal to compare up to 3 analysis#2236

Merged
rmroot merged 2 commits intodevelopfrom
issue-2204
Feb 25, 2026
Merged

Issue 2204 - added modal to compare up to 3 analysis#2236
rmroot merged 2 commits intodevelopfrom
issue-2204

Conversation

@jamlokim
Copy link
Copy Markdown
Contributor

@jamlokim jamlokim commented Feb 9, 2026

connects #2204

This pull request adds a new feature to the Analysis Dashboard that allows users to compare up to three analysis items side-by-side. It introduces a modal for selecting and comparing analyses, updates the UI to include a "Compare Analysis" button, and styles the new components appropriately.

New Analysis Comparison Feature:

  • Added a "Compare Analysis" button to the dashboard header, which appears when there are multiple analysis items. Clicking this button opens a modal for selecting analyses to compare.
  • Implemented a modal dialog (compareAnalysisModal) that allows users to select up to three analysis items and view their details side-by-side. The modal includes logic for selecting/deselecting items and enabling the "Compare" button only when at least two items are selected.
  • Added logic to the component class to manage modal state, selected analysis items, and the display of comparison details.

UI and Styling Enhancements:

  • Updated the CSS to style the new comparison modal, buttons, badges, and analysis cards for a consistent and visually appealing user experience.
  • Adjusted the overlay logic to handle both the "Create New Analysis" and "Compare Analysis" modals.

Data Handling:

  • Ensured that the list of analysis items (facilityAnalysisItems) is kept up-to-date when the selected facility changes, supporting accurate comparison selection.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds an “Analysis Comparison” modal to the facility Analysis Dashboard, enabling users to select and compare up to three analysis items side-by-side from the dashboard UI.

Changes:

  • Added dashboard UI controls (“Compare Analysis” button) and a new modal to select up to 3 analyses and render their detail cards side-by-side.
  • Added component state and selection logic to manage modal open/close, selection toggling, and showing comparison details.
  • Added CSS styles for the comparison modal, compare button, and category badges.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.

File Description
src/app/data-evaluation/facility/analysis/analysis-dashboard/analysis-dashboard.component.ts Adds modal state + selection logic for choosing up to 3 analysis items and showing comparison details.
src/app/data-evaluation/facility/analysis/analysis-dashboard/analysis-dashboard.component.html Adds “Compare Analysis” button, comparison modal markup, and overlays modal state into the existing overlay logic.
src/app/data-evaluation/facility/analysis/analysis-dashboard/analysis-dashboard.component.css Adds styling for the compare modal layout, compare button, and category badges.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.


<div>
<button class="btn action-btn m-0" (click)="openCreateAnalysis()">+Add New Analysis</button>
<div class="d-flex align-items-right">
Copy link

Copilot AI Feb 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

align-items-right is not a Bootstrap utility class (and it isn’t defined anywhere in the repo), so it has no effect. Use the intended Bootstrap alignment utility (e.g., align-items-center for vertical alignment, and/or justify-content-end for right alignment) or add a defined class.

Suggested change
<div class="d-flex align-items-right">
<div class="d-flex align-items-center justify-content-end">

Copilot uses AI. Check for mistakes.
Comment on lines +66 to +67
<div class="fw-bold italic d-flex justify-content-center title">Select up to 3 analysis items to compare</div>
<div class="row g-3 mt-4 mb-4">
Copy link

Copilot AI Feb 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Class italic isn’t defined anywhere in the codebase and isn’t a Bootstrap utility. If italics are intended here, use Bootstrap’s fst-italic (or add a local/global .italic style).

Copilot uses AI. Check for mistakes.
@jamlokim jamlokim requested a review from rmroot February 9, 2026 20:39
@jamlokim jamlokim requested a review from rmroot February 25, 2026 17:17
@rmroot rmroot merged commit e210657 into develop Feb 25, 2026
3 checks passed
@jamlokim jamlokim deleted the issue-2204 branch March 25, 2026 20:56
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.

3 participants