Skip to content

699 add min and max diameter on laser page#885

Merged
kraemr merged 6 commits intomasterfrom
699-add-min-and-max-diameter-on-laser-page2
Nov 24, 2025
Merged

699 add min and max diameter on laser page#885
kraemr merged 6 commits intomasterfrom
699-add-min-and-max-diameter-on-laser-page2

Conversation

@TheBest6337
Copy link
Copy Markdown
Member

This pull request introduces a new MinMaxValue component for displaying minimum and maximum values from a timeseries, and integrates it into the laser control page to improve the display of diameter and roundness ranges. It also centralizes the timeframe selector for these statistics, enhancing usability and consistency.

New component and shared timeframe logic:

  • Added a new MinMaxValue React component in MinMaxValue.tsx that calculates and displays the min/max values for a given timeseries over a selectable timeframe, with support for custom rendering and units.
  • Introduced TIMEFRAME_OPTIONS for consistent timeframe selection

Integration into the laser control page:

  • Updated Laser1ControlPage.tsx to use the new MinMaxValue component for displaying diameter and roundness ranges, including logic to support both single-axis and two-axis lasers. [1] [2]
  • Added a shared timeframe state and selector to control the displayed statistics for both diameter and roundness, ensuring synchronized updates across related metrics. [1] [2]

Copilot AI review requested due to automatic review settings November 8, 2025 14:29
@TheBest6337 TheBest6337 linked an issue Nov 8, 2025 that may be closed by this pull request
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

This PR adds a new MinMaxValue component for displaying min/max values from time series data with configurable timeframes, and integrates it into the Laser1ControlPage to show diameter and roundness ranges.

  • Adds MinMaxValue component with support for controlled/uncontrolled timeframe selection
  • Integrates min/max display for diameter and roundness measurements in Laser1ControlPage
  • Implements shared timeframe selector for synchronized viewing across multiple metrics

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 6 comments.

File Description
electron/src/control/MinMaxValue.tsx New component for displaying min/max values from time series data with timeframe selector and custom zero-value filtering logic
electron/src/machines/laser/laser1/Laser1ControlPage.tsx Integrates MinMaxValue component with conditional rendering for 2-axis vs single-axis lasers and shared timeframe selector
Comments suppressed due to low confidence (1)

electron/src/control/MinMaxValue.tsx:11

  • Unused import getSeriesMinMax.
import { getSeriesMinMax } from "@/lib/timeseries";

Comment thread electron/src/control/MinMaxValue.tsx Outdated
Comment thread electron/src/control/MinMaxValue.tsx
Comment thread electron/src/control/MinMaxValue.tsx
Comment thread electron/src/machines/laser/laser1/Laser1ControlPage.tsx
Comment thread electron/src/control/MinMaxValue.tsx Outdated
@TheBest6337 TheBest6337 requested a review from kraemr November 9, 2025 15:21
@qitechgmbh qitechgmbh deleted a comment from Copilot AI Nov 9, 2025
@TheBest6337 TheBest6337 force-pushed the 699-add-min-and-max-diameter-on-laser-page2 branch from e5d2486 to bc9baa6 Compare November 13, 2025 12:40
@kraemr kraemr force-pushed the 699-add-min-and-max-diameter-on-laser-page2 branch from bc9baa6 to 63ab978 Compare November 18, 2025 13:00
@TheBest6337 TheBest6337 force-pushed the 699-add-min-and-max-diameter-on-laser-page2 branch from 63ab978 to 4025a68 Compare November 23, 2025 16:58
Copy link
Copy Markdown
Collaborator

@kraemr kraemr left a comment

Choose a reason for hiding this comment

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

LGTM

@kraemr kraemr merged commit 4e128de into master Nov 24, 2025
4 checks passed
@kraemr kraemr deleted the 699-add-min-and-max-diameter-on-laser-page2 branch November 24, 2025 12:02
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.

Add Min and Max Diameter on Laser Page

3 participants