Replaces ConfirmationModal with ConfirmationDialog
This commit is contained in:
parent
c9d74654bf
commit
e75bba1c52
25 changed files with 456 additions and 737 deletions
|
@ -3,7 +3,7 @@
|
|||
|
||||
import * as React from 'react';
|
||||
import { ContactName, PropsType as ContactNameProps } from './ContactName';
|
||||
import { ConfirmationModal } from '../ConfirmationModal';
|
||||
import { ConfirmationDialog } from '../ConfirmationDialog';
|
||||
import { Intl } from '../Intl';
|
||||
import { LocalizerType } from '../../types/Util';
|
||||
|
||||
|
@ -42,7 +42,7 @@ export const MessageRequestActionsConfirmation = ({
|
|||
}: Props): JSX.Element | null => {
|
||||
if (state === MessageRequestState.blocking) {
|
||||
return (
|
||||
<ConfirmationModal
|
||||
<ConfirmationDialog
|
||||
i18n={i18n}
|
||||
onClose={() => {
|
||||
onChangeState(MessageRequestState.default);
|
||||
|
@ -77,13 +77,13 @@ export const MessageRequestActionsConfirmation = ({
|
|||
]}
|
||||
>
|
||||
{i18n(`MessageRequests--block-${conversationType}-confirm-body`)}
|
||||
</ConfirmationModal>
|
||||
</ConfirmationDialog>
|
||||
);
|
||||
}
|
||||
|
||||
if (state === MessageRequestState.unblocking) {
|
||||
return (
|
||||
<ConfirmationModal
|
||||
<ConfirmationDialog
|
||||
i18n={i18n}
|
||||
onClose={() => {
|
||||
onChangeState(MessageRequestState.default);
|
||||
|
@ -113,13 +113,13 @@ export const MessageRequestActionsConfirmation = ({
|
|||
]}
|
||||
>
|
||||
{i18n(`MessageRequests--unblock-${conversationType}-confirm-body`)}
|
||||
</ConfirmationModal>
|
||||
</ConfirmationDialog>
|
||||
);
|
||||
}
|
||||
|
||||
if (state === MessageRequestState.deleting) {
|
||||
return (
|
||||
<ConfirmationModal
|
||||
<ConfirmationDialog
|
||||
i18n={i18n}
|
||||
onClose={() => {
|
||||
onChangeState(MessageRequestState.default);
|
||||
|
@ -149,7 +149,7 @@ export const MessageRequestActionsConfirmation = ({
|
|||
]}
|
||||
>
|
||||
{i18n(`MessageRequests--delete-${conversationType}-confirm-body`)}
|
||||
</ConfirmationModal>
|
||||
</ConfirmationDialog>
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@ import React from 'react';
|
|||
import classNames from 'classnames';
|
||||
|
||||
import { LocalizerType } from '../../../types/Util';
|
||||
import { ConfirmationModal } from '../../ConfirmationModal';
|
||||
import { ConfirmationDialog } from '../../ConfirmationDialog';
|
||||
import { Tooltip, TooltipPlacement } from '../../Tooltip';
|
||||
|
||||
import { PanelRow } from './PanelRow';
|
||||
|
@ -88,7 +88,7 @@ export const ConversationDetailsActions: React.ComponentType<Props> = ({
|
|||
</PanelSection>
|
||||
|
||||
{confirmingLeave && (
|
||||
<ConfirmationModal
|
||||
<ConfirmationDialog
|
||||
actions={[
|
||||
{
|
||||
text: i18n(
|
||||
|
@ -103,11 +103,11 @@ export const ConversationDetailsActions: React.ComponentType<Props> = ({
|
|||
title={i18n('ConversationDetailsActions--leave-group-modal-title')}
|
||||
>
|
||||
{i18n('ConversationDetailsActions--leave-group-modal-content')}
|
||||
</ConfirmationModal>
|
||||
</ConfirmationDialog>
|
||||
)}
|
||||
|
||||
{confirmingBlock && (
|
||||
<ConfirmationModal
|
||||
<ConfirmationDialog
|
||||
actions={[
|
||||
{
|
||||
text: i18n(
|
||||
|
@ -124,7 +124,7 @@ export const ConversationDetailsActions: React.ComponentType<Props> = ({
|
|||
])}
|
||||
>
|
||||
{i18n('ConversationDetailsActions--block-group-modal-content')}
|
||||
</ConfirmationModal>
|
||||
</ConfirmationDialog>
|
||||
)}
|
||||
</>
|
||||
);
|
||||
|
|
|
@ -8,7 +8,7 @@ import _ from 'lodash';
|
|||
import { ConversationType } from '../../../state/ducks/conversations';
|
||||
import { LocalizerType } from '../../../types/Util';
|
||||
import { Avatar } from '../../Avatar';
|
||||
import { ConfirmationModal } from '../../ConfirmationModal';
|
||||
import { ConfirmationDialog } from '../../ConfirmationDialog';
|
||||
import { PanelSection } from './PanelSection';
|
||||
import { PanelRow } from './PanelRow';
|
||||
import { ConversationDetailsIcon } from './ConversationDetailsIcon';
|
||||
|
@ -206,7 +206,7 @@ function MembershipActionConfirmation({
|
|||
}
|
||||
|
||||
return (
|
||||
<ConfirmationModal
|
||||
<ConfirmationDialog
|
||||
actions={[
|
||||
{
|
||||
action: modalAction,
|
||||
|
@ -223,7 +223,7 @@ function MembershipActionConfirmation({
|
|||
ourConversationId,
|
||||
stagedMemberships,
|
||||
})}
|
||||
</ConfirmationModal>
|
||||
</ConfirmationDialog>
|
||||
);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue