Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
113 adjust
toggle_slider
ranges (#315)
This is solution for #133 `toggle_slider` is a component that is a sliderInput that can be toggled to become a numericInput. <img width="172" alt="image" src="https://github.com/user-attachments/assets/df97ef6a-e7a5-4f96-bb43-8159f5f9dd83"> <img width="172" alt="image" src="https://github.com/user-attachments/assets/64aa88ec-a041-4c3a-93ee-d5fd12a1def2"> The PR fixes the issue with ranges on sliderInput that should be adjusted based on numericInput. So if slider had ranges min_sliderInput and max_sliderInput and values for numercInput are changed, so that min(numercInput) is lower than min_sliderInput or max(numercInput) is greater than max_sliderInput, then `min_sliderInput` or `max_sliderInput` should be extended for new ranges. # Example 1 min_sliderInput, max_sliderInput - on start 0, 55 <img width="166" alt="image" src="https://github.com/user-attachments/assets/e3bfcb1a-a2f4-435e-8569-54d45c549486"> hence numericInput on start 0, 55 <img width="166" alt="image" src="https://github.com/user-attachments/assets/e4988200-5e89-452e-a287-12fbabc6f4bb"> numericInput changes to -5, 65 <img width="173" alt="image" src="https://github.com/user-attachments/assets/1635521c-ace1-468a-8a8c-a3d758093fcc"> sliderInput changes to -5, 65 <img width="170" alt="image" src="https://github.com/user-attachments/assets/62aee129-083c-4286-afef-86cb5ab0e0a8"> # Example 2 Continuation of the previous one, if you change numericInput from -5, 65 <img width="170" alt="image" src="https://github.com/user-attachments/assets/416ff11a-b5ed-4e0c-9ff6-3695019b8c1f"> to 4, 45 <img width="172" alt="image" src="https://github.com/user-attachments/assets/0d25721f-9da0-4d77-ae21-d7bc579d2963"> sliderInput is reset (the min and max) to original 0, 55 but values are set to 4, 45 <img width="172" alt="image" src="https://github.com/user-attachments/assets/e39ac970-5bb2-4297-89f1-062fcab74d5e"> --------- Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
- Loading branch information