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

Fixed bunch of eslitn errors 2

This commit is contained in:
Vladimir Volek 2018-09-05 16:52:29 +02:00
parent 288a81775d
commit f5ddddc1fb
8 changed files with 19 additions and 41 deletions

View File

@ -59,6 +59,7 @@
"trezor-connect": "5.0.30", "trezor-connect": "5.0.30",
"web3": "^0.19.0", "web3": "^0.19.0",
"webpack": "^4.16.3", "webpack": "^4.16.3",
"webpack-bundle-analyzer": "^2.13.1",
"whatwg-fetch": "^2.0.4", "whatwg-fetch": "^2.0.4",
"yarn-run-all": "^3.1.1" "yarn-run-all": "^3.1.1"
}, },
@ -96,7 +97,6 @@
"stylelint-custom-processor-loader": "^0.5.0", "stylelint-custom-processor-loader": "^0.5.0",
"stylelint-processor-styled-components": "^1.3.2", "stylelint-processor-styled-components": "^1.3.2",
"stylelint-webpack-plugin": "^0.10.5", "stylelint-webpack-plugin": "^0.10.5",
"webpack-bundle-analyzer": "^2.13.1",
"webpack-cli": "^2.1.3", "webpack-cli": "^2.1.3",
"webpack-dev-server": "^3.1.4", "webpack-dev-server": "^3.1.4",
"yargs": "11.0.0" "yargs": "11.0.0"

7
src/support/PropTypes.js Normal file
View File

@ -0,0 +1,7 @@
import PropTypes from 'prop-types';
export const DEVICE_PROP_TYPES = PropTypes.shape({
id: PropTypes.number.isRequired,
text: PropTypes.string.isRequired,
author: authorPropType.isRequired,
});

View File

@ -1,4 +1,4 @@
import styled, { css } from 'styled-components'; import styled from 'styled-components';
import React from 'react'; import React from 'react';
import PropTypes from 'prop-types'; import PropTypes from 'prop-types';

View File

@ -1,30 +1,12 @@
/* @flow */
import styled from 'styled-components'; import styled from 'styled-components';
import React, { Component } from 'react'; import React from 'react';
import { NavLink } from 'react-router-dom';
type Props = {
pathname: string;
}
type State = {
style: {
width: number,
left: number
};
}
const Wrapper = styled.div``; const Wrapper = styled.div``;
const AccountTabs = (props: any): any => { const AccountTabs = () => (
const urlParams = props.match.params;
const basePath = `/device/${urlParams.device}/network/${urlParams.network}/account/${urlParams.account}`;
return (
<Wrapper> <Wrapper>
Device settings Device settings
</Wrapper> </Wrapper>
); );
};
export default AccountTabs; export default AccountTabs;

View File

@ -6,8 +6,8 @@ import styled from 'styled-components';
import { connect } from 'react-redux'; import { connect } from 'react-redux';
import { Route, withRouter } from 'react-router-dom'; import { Route, withRouter } from 'react-router-dom';
import type { MapStateToProps, MapDispatchToProps } from 'react-redux'; import type { MapStateToProps } from 'react-redux';
import type { State, Dispatch } from 'flowtype'; import type { State } from 'flowtype';
import Header from 'components/Header'; import Header from 'components/Header';
import Footer from 'components/Footer'; import Footer from 'components/Footer';

View File

@ -17,12 +17,6 @@ type Props = {
network: Coin network: Coin
} }
type Style = {
+color: string,
+background: string,
+borderColor: string
}
const Wrapper = styled.div` const Wrapper = styled.div`
border-top: 1px solid ${colors.DIVIDER}; border-top: 1px solid ${colors.DIVIDER};
`; `;

View File

@ -26,7 +26,7 @@ type DispatchProps = BaseDispatchProps & {
export type Props = StateProps & BaseStateProps & DispatchProps & BaseDispatchProps; export type Props = StateProps & BaseStateProps & DispatchProps & BaseDispatchProps;
const mapStateToProps: MapStateToProps<State, OwnProps, StateProps> = (state: State, own: OwnProps): StateProps => ({ const mapStateToProps: MapStateToProps<State, OwnProps, StateProps> = (state: State): StateProps => ({
className: 'summary', className: 'summary',
selectedAccount: state.selectedAccount, selectedAccount: state.selectedAccount,
wallet: state.wallet, wallet: state.wallet,

View File

@ -12,12 +12,7 @@ import type { State, Dispatch } from 'flowtype';
const Wrapper = styled.div``; const Wrapper = styled.div``;
type Props = { const UnreadableDevice = () => (
acquiring: boolean;
acquireDevice: typeof TrezorConnectActions.acquire
}
const UnreadableDevice = (props: Props) => (
<Wrapper> <Wrapper>
<Notification <Notification
title="Unreadable device" title="Unreadable device"