mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
added tooltip
This commit is contained in:
parent
80e875308b
commit
2a0a785324
@ -740,7 +740,7 @@
|
||||
"message": "remove"
|
||||
},
|
||||
"removeAccount": {
|
||||
"message": "Remove account?"
|
||||
"message": "Remove account"
|
||||
},
|
||||
"removeAccountDescription": {
|
||||
"message": "This account will be removed from your wallet. Please make sure you have the original seed phrase or private key for this imported account before continuing. You can import or create accounts again from the account drop-down. "
|
||||
|
@ -11,6 +11,7 @@ const Identicon = require('../identicon')
|
||||
const { formatBalance } = require('../../util')
|
||||
const { ENVIRONMENT_TYPE_POPUP } = require('../../../../app/scripts/lib/enums')
|
||||
const { getEnvironmentType } = require('../../../../app/scripts/lib/util')
|
||||
const Tooltip = require('../tooltip')
|
||||
|
||||
|
||||
const {
|
||||
@ -202,7 +203,17 @@ AccountMenu.prototype.renderRemoveAccount = function (keyring, address) {
|
||||
// Any account that's not from the HD wallet Keyring can be removed
|
||||
const type = keyring.type
|
||||
const isRemovable = type !== 'HD Key Tree'
|
||||
return isRemovable ? h('a.remove-account-icon', { onClick: (e) => this.removeAccount(e, address) }, '') : null
|
||||
if (isRemovable) {
|
||||
return h(Tooltip, {
|
||||
title: this.context.t('removeAccount'),
|
||||
position: 'bottom',
|
||||
}, [
|
||||
h('a.remove-account-icon', {
|
||||
onClick: (e) => this.removeAccount(e, address),
|
||||
}, ''),
|
||||
])
|
||||
}
|
||||
return null
|
||||
}
|
||||
|
||||
AccountMenu.prototype.removeAccount = function (e, address) {
|
||||
|
@ -26,7 +26,7 @@ class ConfirmRemoveAccount extends Component {
|
||||
<div className="modal-container">
|
||||
<div className="modal-container__content">
|
||||
<div className="modal-container__title">
|
||||
{ `${t('removeAccount')}` }
|
||||
{ `${t('removeAccount')}` }?
|
||||
</div>
|
||||
<div className="modal-container__address">
|
||||
{addressSummary(this.props.address)}
|
||||
|
@ -87,9 +87,9 @@
|
||||
}
|
||||
|
||||
.remove-account-icon {
|
||||
width: 25px;
|
||||
padding-left: 10px;
|
||||
height: 25px;
|
||||
width: 15px;
|
||||
margin-left: 10px;
|
||||
height: 15px;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
|
Loading…
Reference in New Issue
Block a user