-
Notifications
You must be signed in to change notification settings - Fork 734
Moved ColorPickerDialog to FC. #2823
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
Conversation
Moved some constants to the presenter file
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 a few more small comments
import {Colors} from '../../style'; | ||
import {ColorPickerDialogProps} from './ColorPickerDialog'; | ||
import {BORDER_RADIUS} from './ColorPickerPresenter'; | ||
type HeaderProps = Pick<ColorPickerDialogProps, 'doneButtonColor' | 'accessibilityLabels' | 'testID'> & { |
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.
Add space between imports and global declarations
@@ -0,0 +1,108 @@ | |||
import React, {useRef} from 'react'; | |||
import {View, TouchableOpacity, Text} from 'react-native-ui-lib'; |
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.
You can't/shouldn't import from uilib in a source code, you should import from the relevant components file directly
this can cause cyclic requires and TS build issues
Changed imports to import from relative path and not ui-lib
Description
Changing the ColorPickerDialog to a FC.
Changelog
ColorPickerDialog - Changed to FC