mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
remove warning on revoke approval for all nfts (#16953)
Co-authored-by: EresDev <eresdev@hotmail.com>
This commit is contained in:
parent
dbe77289d3
commit
074c2934fe
@ -260,7 +260,6 @@ describe('Collectibles', function () {
|
|||||||
|
|
||||||
// Confirm disabling set approval for all
|
// Confirm disabling set approval for all
|
||||||
await driver.clickElement({ text: 'Confirm', tag: 'button' });
|
await driver.clickElement({ text: 'Confirm', tag: 'button' });
|
||||||
await driver.clickElement({ text: 'Approve', tag: 'button' });
|
|
||||||
|
|
||||||
await driver.waitUntilXWindowHandles(2);
|
await driver.waitUntilXWindowHandles(2);
|
||||||
await driver.switchToWindow(extension);
|
await driver.switchToWindow(extension);
|
||||||
|
@ -109,6 +109,7 @@ export default class ConfirmPageContainer extends Component {
|
|||||||
supportsEIP1559: PropTypes.bool,
|
supportsEIP1559: PropTypes.bool,
|
||||||
nativeCurrency: PropTypes.string,
|
nativeCurrency: PropTypes.string,
|
||||||
isBuyableChain: PropTypes.bool,
|
isBuyableChain: PropTypes.bool,
|
||||||
|
isApprovalOrRejection: PropTypes.bool,
|
||||||
};
|
};
|
||||||
|
|
||||||
async componentDidMount() {
|
async componentDidMount() {
|
||||||
@ -186,6 +187,7 @@ export default class ConfirmPageContainer extends Component {
|
|||||||
///: END:ONLY_INCLUDE_IN
|
///: END:ONLY_INCLUDE_IN
|
||||||
accountBalance,
|
accountBalance,
|
||||||
assetStandard,
|
assetStandard,
|
||||||
|
isApprovalOrRejection,
|
||||||
} = this.props;
|
} = this.props;
|
||||||
|
|
||||||
const shouldDisplayWarning =
|
const shouldDisplayWarning =
|
||||||
@ -354,7 +356,11 @@ export default class ConfirmPageContainer extends Component {
|
|||||||
<PageContainerFooter
|
<PageContainerFooter
|
||||||
onCancel={onCancel}
|
onCancel={onCancel}
|
||||||
cancelText={t('reject')}
|
cancelText={t('reject')}
|
||||||
onSubmit={isSetApproveForAll ? onSetApprovalForAll : onSubmit}
|
onSubmit={
|
||||||
|
isSetApproveForAll && isApprovalOrRejection
|
||||||
|
? onSetApprovalForAll
|
||||||
|
: onSubmit
|
||||||
|
}
|
||||||
submitText={t('confirm')}
|
submitText={t('confirm')}
|
||||||
submitButtonType={
|
submitButtonType={
|
||||||
isSetApproveForAll ? 'danger-primary' : 'primary'
|
isSetApproveForAll ? 'danger-primary' : 'primary'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user