1
0
mirror of https://github.com/trezor/trezor-wallet synced 2024-11-18 06:18:12 +00:00

fixed flowtype in modals

This commit is contained in:
Szymon Lesisz 2018-10-05 17:49:51 +02:00
parent c570970b42
commit 5c9194e814
2 changed files with 11 additions and 3 deletions

View File

@ -48,13 +48,15 @@ class ForgetDevice extends Component<Props> {
keyboardHandler: (event: KeyboardEvent) => void;
foo(hidden: boolean) {
this.props.modalActions.onWalletTypeRequest(this.props.modal.device, hidden);
const { modal } = this.props;
if (!modal.opened) return;
this.props.modalActions.onWalletTypeRequest(modal.device, hidden);
}
render() {
if (!this.props.modal.opened) return null;
const { device } = this.props.modal;
const { onCancel } = this.props.modalActions;
// const { onCancel } = this.props.modalActions;
return (
<Wrapper>
<H3>RequestWalletType for { device.instanceLabel }?</H3>

View File

@ -1,9 +1,14 @@
/* @flow */
import React from 'react';
import Icon from 'components/Icon';
import colors from 'config/colors';
import icons from 'config/icons';
import styled from 'styled-components';
import { H3 } from 'components/Heading';
import P from 'components/Paragraph';
import type { Props } from 'components/modals/index';
const Wrapper = styled.div`
width: 360px;
@ -12,7 +17,7 @@ const Wrapper = styled.div`
const Header = styled.div``;
const Confirmation = (props) => {
const Confirmation = (props: Props) => {
if (!props.modal.opened) return null;
const { device } = props.modal;
@ -21,6 +26,7 @@ const Confirmation = (props) => {
<Header>
<Icon icon={icons.T1} size={60} color={colors.TEXT_SECONDARY} />
<H3>Complete the action on { device.label } device</H3>
<P isSmaller>TODO: add detailed text here. Explain passphrase/hidden wallet...</P>
</Header>
</Wrapper>
);