[Slider] add custom styling for mark at the end for horizontal slider
fixes: https://github.com/mui/material-ui/issues/32345
This PR add custom styling to the mark at the end of the slider. Instead of having the mark text on the middle of the mark, now the text is alligned to the right of the mark, so that the text doesn't get out of bound.
This solution might be too specific. Feedback would be greatly appreciated.
An alternative solution I had is to call getBoundingClientRect function to check if the mark is inside the Slider Component. But I'm reluctant to try that because it is an expensive function to call for all marks.
- [x] I have followed (at least) the PR section of the contributing guide.
Netlify deploy preview
https://deploy-preview-36891--material-ui.netlify.app/
Bundle size report
Generated by :no_entry_sign: dangerJS against 599922fc518f047ec86add476b815e22d7acee4c
hey @mnajdova , you might have missed this PR
@ZeeshanTamboli yes, I agree. I guess there is nothing else to do other than to close this PR, right?
Do you think a solution with getBoundingClientRect might have a future? More conretely, checking all the label position with it and position them accordingly
I guess there is nothing else to do other than to close this PR, right?
Yes, I am closing it.
Do you think a solution with getBoundingClientRect might have a future? More conretely, checking all the label position with it and position them accordingly
The label should be positioned by overriding the styles. I think, we can't control it.