mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Move getMaxModeOn selector to amount-max-button container.
This commit is contained in:
parent
4a8c3194c2
commit
beb8d1cf5e
@ -5,7 +5,7 @@ import {
|
|||||||
getSendFromBalance,
|
getSendFromBalance,
|
||||||
getTokenBalance,
|
getTokenBalance,
|
||||||
} from '../../../send.selectors.js'
|
} from '../../../send.selectors.js'
|
||||||
import { getMaxModeOn } from '../send-amount-row.selectors.js'
|
import { getMaxModeOn } from './amount-max-button.selectors.js'
|
||||||
import { calcMaxAmount } from './amount-max-button.utils.js'
|
import { calcMaxAmount } from './amount-max-button.utils.js'
|
||||||
import {
|
import {
|
||||||
updateSendAmount,
|
updateSendAmount,
|
||||||
|
@ -0,0 +1,9 @@
|
|||||||
|
const selectors = {
|
||||||
|
getMaxModeOn,
|
||||||
|
}
|
||||||
|
|
||||||
|
module.exports = selectors
|
||||||
|
|
||||||
|
function getMaxModeOn (state) {
|
||||||
|
return state.metamask.send.maxModeOn
|
||||||
|
}
|
@ -1,14 +1,9 @@
|
|||||||
const selectors = {
|
const selectors = {
|
||||||
getMaxModeOn,
|
|
||||||
sendAmountIsInError,
|
sendAmountIsInError,
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = selectors
|
module.exports = selectors
|
||||||
|
|
||||||
function getMaxModeOn (state) {
|
|
||||||
return state.metamask.send.maxModeOn
|
|
||||||
}
|
|
||||||
|
|
||||||
function sendAmountIsInError (state) {
|
function sendAmountIsInError (state) {
|
||||||
return Boolean(state.send.errors.amount)
|
return Boolean(state.send.errors.amount)
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user