diff --git a/packages/blockchain-wallet-v4-frontend/src/components/Form/SelectBoxBankAccountType/index.js b/packages/blockchain-wallet-v4-frontend/src/components/Form/SelectBoxBankAccountType/index.js index 84ab4c6923c..e0383f886b2 100644 --- a/packages/blockchain-wallet-v4-frontend/src/components/Form/SelectBoxBankAccountType/index.js +++ b/packages/blockchain-wallet-v4-frontend/src/components/Form/SelectBoxBankAccountType/index.js @@ -1,39 +1,34 @@ import React from 'react' import { FormattedMessage } from 'react-intl' -import { connect } from 'react-redux' import SelectBox from '../SelectBox' +const ACCOUNT_TYPES = [ + { + text: ( + + ), + value: 'checking' + }, + + { + text: ( + + ), + value: 'savings' + } +] class SelectBoxBankAccountType extends React.PureComponent { render() { - const { accountTypes, ...rest } = this.props - const elements = [{ group: '', items: accountTypes }] - return + const elements = [{ group: '', items: ACCOUNT_TYPES }] + return } } -const mapStateToProps = (state, ownProps) => ({ - accountTypes: [ - { - text: ( - - ), - value: 'checking' - }, - - { - text: ( - - ), - value: 'savings' - } - ] -}) - -export default connect(mapStateToProps)(SelectBoxBankAccountType) +export default SelectBoxBankAccountType diff --git a/packages/blockchain-wallet-v4-frontend/src/components/Form/SelectBoxCoinPriceChart/index.js b/packages/blockchain-wallet-v4-frontend/src/components/Form/SelectBoxCoinPriceChart/index.js index f949aa9a742..6dde27118e3 100644 --- a/packages/blockchain-wallet-v4-frontend/src/components/Form/SelectBoxCoinPriceChart/index.js +++ b/packages/blockchain-wallet-v4-frontend/src/components/Form/SelectBoxCoinPriceChart/index.js @@ -1,11 +1,9 @@ import React from 'react' -import { connect } from 'react-redux' import styled from 'styled-components' import { Icon, Text } from 'blockchain-info-components' import SelectBox from '../SelectBox' -import { getCoins } from './selectors' const HeaderWrapper = styled.div` display: flex; @@ -43,8 +41,7 @@ const SelectBoxCoin = styled(SelectBox)` } ` -const renderItem = (props) => { - const { text, value } = props +const renderItem = ({ text, value }) => { const coinValue = value || 'BTC' return ( @@ -56,8 +53,7 @@ const renderItem = (props) => { ) } -const renderDisplay = (props, children) => { - const { value } = props +const renderDisplay = ({ value }, children) => { const coinValue = value || 'BTC' const e2eTag = `${coinValue}CurrencyOption` @@ -71,24 +67,27 @@ const renderDisplay = (props, children) => { ) } +const COINS = [ + { text: 'Bitcoin', value: 'BTC' }, + { text: 'Ether', value: 'ETH' }, + { text: 'Bitcoin Cash', value: 'BCH' }, + { text: 'Stellar', value: 'XLM' } +] + class SelectBoxCoinPriceChart extends React.PureComponent { render() { - const { coins, ...rest } = this.props - const elements = [{ group: '', items: coins }] + const elements = [{ group: '', items: COINS }] return ( ) } } -const mapStateToProps = (state, ownProps) => ({ - coins: getCoins(state, ownProps) -}) - -export default connect(mapStateToProps)(SelectBoxCoinPriceChart) +export default SelectBoxCoinPriceChart diff --git a/packages/blockchain-wallet-v4-frontend/src/components/Form/SelectBoxCoinPriceChart/selectors.js b/packages/blockchain-wallet-v4-frontend/src/components/Form/SelectBoxCoinPriceChart/selectors.js deleted file mode 100644 index efe5b0eb6f9..00000000000 --- a/packages/blockchain-wallet-v4-frontend/src/components/Form/SelectBoxCoinPriceChart/selectors.js +++ /dev/null @@ -1,8 +0,0 @@ -export const getCoins = () => [ - { text: 'Bitcoin', value: 'BTC' }, - { text: 'Ether', value: 'ETH' }, - { text: 'Bitcoin Cash', value: 'BCH' }, - { text: 'Stellar', value: 'XLM' } -] - -export default getCoins