-
Notifications
You must be signed in to change notification settings - Fork 20
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
Differenciate desktop and mobile to clean up tests #465
Conversation
@@ -27,7 +28,7 @@ const isOptionEqualToValue = (option?: MultiProxy, value?: MultiProxy) => { | |||
return option.multisigs[0].address === value.multisigs[0].address | |||
} | |||
|
|||
const MultiProxySelection = ({ className }: Props) => { | |||
const MultiProxySelection = ({ className, isDesktop }: Props) => { |
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.
I would probably use the hook, to avoid passing the props to the component. F.e
const isDesktop = useMediaQuery((theme: Theme) => theme.breakpoints.up('md'))
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.
I don't think this hook should be used here. At the end of the day, it's just a testId
to identify the specific MultiProxySelection
component. The fact that we're using it for dektop or mobile is not relevant.
I'll rename it in 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.
Looks good! There is a suggestion about isDesktop variable
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.
Looks great, thanks!
closes #447
Submission checklist:
Layout