Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ui-manchette-with-spacetimechart: fix spacetimechart scaling if hidde… #621

Merged

Conversation

SharglutDev
Copy link
Contributor

@SharglutDev SharglutDev commented Oct 7, 2024

…n waypoints

Fix an issue where the space time chart wouldn't correspond to the manchette in linear mode when a bunch of waypoints were hidden in the middle of the path

add a new condition in getScales function

Fix an issue where the space time chart wouldn't correspond to the manchette when the first x waypoints were hidden

The code used to consider that the space origin only starts at 0 but it might not always be the case when hiding waypoints.

Important

To test these changes, you need to be able to launch osrd-ui inside osrd and be on this PR (to hide waypoints on the manchette)

@SharglutDev SharglutDev self-assigned this Oct 7, 2024
@SharglutDev SharglutDev requested a review from a team as a code owner October 7, 2024 16:08
@SharglutDev SharglutDev force-pushed the ui-manchette-with-spacetimechart/fix-spacetimechart-scaling branch 4 times, most recently from 0f0770f to 45a1ad5 Compare October 9, 2024 14:16
When the first waypoint or first x waypoints were hidden, the space time
chart wouldn't display the corresponding curve in linear mode

Signed-off-by: SharglutDev <[email protected]>
Copy link
Contributor

@clarani clarani left a comment

Choose a reason for hiding this comment

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

LGTM, can you separate your commit in 2 ? 1 for the SpaceTimeChart, 1 for the Manchette

In linear mode, the space time chart didn't shrink when there was some
waypoints hidden in the middle of the path

Signed-off-by: SharglutDev <[email protected]>
@SharglutDev SharglutDev force-pushed the ui-manchette-with-spacetimechart/fix-spacetimechart-scaling branch from 45a1ad5 to a0d0305 Compare October 9, 2024 15:25
Copy link
Contributor

@clarani clarani left a comment

Choose a reason for hiding this comment

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

LGTM ✅

@SharglutDev SharglutDev added this pull request to the merge queue Oct 9, 2024
Merged via the queue into dev with commit b820fcd Oct 9, 2024
6 checks passed
@SharglutDev SharglutDev deleted the ui-manchette-with-spacetimechart/fix-spacetimechart-scaling branch October 9, 2024 15:37
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.

2 participants