mirror of
https://github.com/ant-design/ant-design.git
synced 2025-01-18 06:03:38 +08:00
feat: components used in confirm title and content support prefixCls (#27376)
This commit is contained in:
parent
6880bf7073
commit
7c0e88839c
@ -3,6 +3,7 @@ import classNames from 'classnames';
|
||||
import Dialog, { ModalFuncProps } from './Modal';
|
||||
import ActionButton from './ActionButton';
|
||||
import devWarning from '../_util/devWarning';
|
||||
import ConfigProvider from '../config-provider';
|
||||
|
||||
interface ConfirmDialogProps extends ModalFuncProps {
|
||||
afterClose?: () => void;
|
||||
@ -96,13 +97,15 @@ const ConfirmDialog = (props: ConfirmDialogProps) => {
|
||||
getContainer={getContainer}
|
||||
>
|
||||
<div className={`${contentPrefixCls}-body-wrapper`}>
|
||||
<div className={`${contentPrefixCls}-body`} style={bodyStyle}>
|
||||
{icon}
|
||||
{props.title === undefined ? null : (
|
||||
<span className={`${contentPrefixCls}-title`}>{props.title}</span>
|
||||
)}
|
||||
<div className={`${contentPrefixCls}-content`}>{props.content}</div>
|
||||
</div>
|
||||
<ConfigProvider prefixCls={rootPrefixCls}>
|
||||
<div className={`${contentPrefixCls}-body`} style={bodyStyle}>
|
||||
{icon}
|
||||
{props.title === undefined ? null : (
|
||||
<span className={`${contentPrefixCls}-title`}>{props.title}</span>
|
||||
)}
|
||||
<div className={`${contentPrefixCls}-content`}>{props.content}</div>
|
||||
</div>
|
||||
</ConfigProvider>
|
||||
<div className={`${contentPrefixCls}-btns`}>
|
||||
{cancelButton}
|
||||
<ActionButton
|
||||
|
Loading…
Reference in New Issue
Block a user