mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Fix close button on send screen
This commit is contained in:
parent
26f965bcce
commit
5529ec6efd
@ -1,23 +1,24 @@
|
||||
import React, { Component } from 'react'
|
||||
import PropTypes from 'prop-types'
|
||||
import PageContainerHeader from '../../page-container/page-container-header.component'
|
||||
import { DEFAULT_ROUTE } from '../../../routes'
|
||||
|
||||
export default class SendHeader extends Component {
|
||||
|
||||
static propTypes = {
|
||||
clearSend: PropTypes.func,
|
||||
goHome: PropTypes.func,
|
||||
history: PropTypes.object,
|
||||
isToken: PropTypes.bool,
|
||||
};
|
||||
|
||||
render () {
|
||||
const { isToken, clearSend, goHome } = this.props
|
||||
const { isToken, clearSend, history } = this.props
|
||||
|
||||
return (
|
||||
<PageContainerHeader
|
||||
onClose={() => {
|
||||
clearSend()
|
||||
goHome()
|
||||
history.push(DEFAULT_ROUTE)
|
||||
}}
|
||||
subtitle={this.context.t('onlySendToEtherAddress')}
|
||||
title={isToken ? this.context.t('sendTokens') : this.context.t('sendETH')}
|
||||
|
@ -129,7 +129,7 @@ export default class SendTransactionScreen extends PersistentForm {
|
||||
|
||||
return (
|
||||
<PageContainer>
|
||||
<SendHeader/>
|
||||
<SendHeader history={history}/>
|
||||
<SendContent/>
|
||||
<SendFooter history={history}/>
|
||||
</PageContainer>
|
||||
|
Loading…
Reference in New Issue
Block a user