You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
618 B
21 lines
618 B
4 years ago
|
import { connect } from 'react-redux';
|
||
4 years ago
|
import { CHAIN_ID_TO_NETWORK_ID_MAP } from '../../../../../shared/constants/network';
|
||
5 years ago
|
import {
|
||
|
getSendTo,
|
||
|
getSendToNickname,
|
||
5 years ago
|
getAddressBookEntry,
|
||
4 years ago
|
getCurrentChainId,
|
||
4 years ago
|
} from '../../../../selectors';
|
||
|
import EnsInput from './ens-input.component';
|
||
5 years ago
|
|
||
4 years ago
|
export default connect((state) => {
|
||
4 years ago
|
const selectedAddress = getSendTo(state);
|
||
4 years ago
|
const chainId = getCurrentChainId(state);
|
||
4 years ago
|
return {
|
||
4 years ago
|
network: CHAIN_ID_TO_NETWORK_ID_MAP[chainId],
|
||
4 years ago
|
selectedAddress,
|
||
|
selectedName: getSendToNickname(state),
|
||
|
contact: getAddressBookEntry(state, selectedAddress),
|
||
4 years ago
|
};
|
||
|
})(EnsInput);
|