diff options
author | Brandon Millman <brandon.millman@gmail.com> | 2018-05-09 02:12:46 +0800 |
---|---|---|
committer | Brandon Millman <brandon.millman@gmail.com> | 2018-05-09 02:12:46 +0800 |
commit | 17f3d5f6bac178ffda6060eea227ef8deaaf73aa (patch) | |
tree | 2b31258b15d1c3a0ec549dfc4d121e3274f71f88 /packages/website/ts/components/top_bar | |
parent | 607d738342a839788b59e0dee63849ea447331bc (diff) | |
download | dexon-0x-contracts-17f3d5f6bac178ffda6060eea227ef8deaaf73aa.tar.gz dexon-0x-contracts-17f3d5f6bac178ffda6060eea227ef8deaaf73aa.tar.zst dexon-0x-contracts-17f3d5f6bac178ffda6060eea227ef8deaaf73aa.zip |
Suggestions and fix bad merge
Diffstat (limited to 'packages/website/ts/components/top_bar')
-rw-r--r-- | packages/website/ts/components/top_bar/provider_display.tsx | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/packages/website/ts/components/top_bar/provider_display.tsx b/packages/website/ts/components/top_bar/provider_display.tsx index fa5609014..4cd50dba9 100644 --- a/packages/website/ts/components/top_bar/provider_display.tsx +++ b/packages/website/ts/components/top_bar/provider_display.tsx @@ -11,7 +11,7 @@ import { ProviderType } from 'ts/types'; import { constants } from 'ts/utils/constants'; import { utils } from 'ts/utils/utils'; -const IDENTICON_DIAMETER = 24; +const ROOT_HEIGHT = 24; export interface ProviderDisplayProps { dispatcher: Dispatcher; @@ -27,12 +27,9 @@ interface ProviderDisplayState {} const styles: Styles = { root: { - height: 24, + height: ROOT_HEIGHT, backgroundColor: colors.white, - borderBottomRightRadius: 24, - borderBottomLeftRadius: 24, - borderTopRightRadius: 24, - borderTopLeftRadius: 24, + borderRadius: ROOT_HEIGHT, boxShadow: `0px 4px 6px ${colors.walletBoxShadow}`, }, }; @@ -52,21 +49,18 @@ export class ProviderDisplay extends React.Component<ProviderDisplayProps, Provi : 'Connect a wallet'; const providerTitle = this.props.providerType === ProviderType.Injected ? injectedProviderName : 'Ledger Nano S'; - const isProviderMetamask = providerTitle === 'Metamask'; + const isProviderMetamask = providerTitle === constants.PROVIDER_NAME_METAMASK; const hoverActiveNode = ( <div className="flex right lg-pr0 md-pr2 sm-pr2 p1" style={styles.root}> <div> - <Identicon address={this.props.userAddress} diameter={IDENTICON_DIAMETER} /> + <Identicon address={this.props.userAddress} diameter={ROOT_HEIGHT} /> </div> <div style={{ marginLeft: 12, paddingTop: 3 }}> <div style={{ fontSize: 16, color: colors.darkGrey }}>{displayAddress}</div> </div> {isProviderMetamask && ( <div style={{ marginLeft: 16 }}> - <img - src="/images/metamask_icon.png" - style={{ width: IDENTICON_DIAMETER, height: IDENTICON_DIAMETER }} - /> + <img src="/images/metamask_icon.png" style={{ width: ROOT_HEIGHT, height: ROOT_HEIGHT }} /> </div> )} </div> |