Change mute, block and domain block confirmations in web UI (#29576)

This commit is contained in:
Eugen Rochko authored and GitHub committed 2024-03-15 17:36:41 +00:00
1 parent be7a68b095
commit ec19d0a14b
27 files changed
+620 -349

No files matched your search

@@ -1,4 +1,4 @@
import { defineMessages, injectIntl, FormattedMessage } from 'react-intl';
import { defineMessages, injectIntl } from 'react-intl';
import { connect } from 'react-redux';
@@ -15,7 +15,7 @@ import {
directCompose,
} from '../actions/compose';
import {
blockDomain,
initDomainBlockModal,
unblockDomain,
} from '../actions/domain_blocks';
import {
@@ -253,15 +253,8 @@ const mapDispatchToProps = (dispatch, { intl, contextType }) => ({
dispatch(toggleStatusCollapse(status.get('id'), isCollapsed));
},
onBlockDomain (domain) {
dispatch(openModal({
modalType: 'CONFIRM',
modalProps: {
message: <FormattedMessage id='confirmations.domain_block.message' defaultMessage='Are you really, really sure you want to block the entire {domain}? In most cases a few targeted blocks or mutes are sufficient and preferable. You will not see content from that domain in any public timelines or your notifications. Your followers from that domain will be removed.' values={{ domain: <strong>{domain}</strong> }} />,
confirm: intl.formatMessage(messages.blockDomainConfirm),
onConfirm: () => dispatch(blockDomain(domain)),
},
}));
onBlockDomain (account) {
dispatch(initDomainBlockModal(account));
},
onUnblockDomain (domain) {