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
Slider 'enableShadow' prop and ColorPicker - minor UI changes #2934
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wrote small comments.
Anyway approved.
Btw, I pushed a small change in the screen name
borderBottomWidth: 0.5, | ||
borderBottomColor: Colors.$outlineDisabled, | ||
borderTopWidth: 0.5, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider using StyleSheet.hairlineWidth
for the thin border..
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
const [color, setColor] = useState(Colors.getHSL(propsColors)); | ||
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove extra space
@@ -94,25 +94,31 @@ const GradientSlider = (props: Props) => { | |||
return color || sliderContext.value; | |||
}, [color, sliderContext.value]); | |||
|
|||
const renderDefaultGradient = useCallback(() => { | |||
const getHueColor = useCallback(() => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It feels like this should be a memoize value more than a callback.. WDYT?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. Good idea
Description
Slider - add 'enableShadow' prop
GradientSlider - display color only changes on hue change
ColorPicker - minor UI changes
Slider - bug fix - invoke onChange only when user move slider
Changelog
Slider - add 'enableShadow' prop
GradientSlider - display color only changes on hue change
ColorPicker - minor UI changes
Slider - bug fix - invoke onChange only when user move slider
Additional info
MADS-3847