mirror of
https://gitee.com/ant-design/ant-design.git
synced 2024-11-30 02:59:04 +08:00
fix: Modal conflicting props classNames.wrapper and centered (#47076)
* fix: conflict wrapper and centered * test: update snap * fix: undefined className * refactor: use classNames for merge class
This commit is contained in:
parent
87b45e6198
commit
d25b4c1b46
@ -144,9 +144,9 @@ const Modal: React.FC<ModalProps> = (props) => {
|
||||
className={classNames(hashId, className, modal?.className)}
|
||||
style={{ ...modal?.style, ...style }}
|
||||
classNames={{
|
||||
wrapper: wrapClassNameExtended,
|
||||
...modal?.classNames,
|
||||
...modalClassNames,
|
||||
wrapper: classNames(wrapClassNameExtended, modalClassNames?.wrapper),
|
||||
}}
|
||||
styles={{
|
||||
...modal?.styles,
|
||||
|
@ -52,7 +52,7 @@ export interface ModalProps extends ModalCommonProps {
|
||||
transitionName?: string;
|
||||
className?: string;
|
||||
rootClassName?: string;
|
||||
classNames?: Omit<NonNullable<DialogProps['classNames']>, 'wrapper'>;
|
||||
classNames?: NonNullable<DialogProps['classNames']>;
|
||||
getContainer?: string | HTMLElement | getContainerFunc | false;
|
||||
zIndex?: number;
|
||||
/** @deprecated Please use `styles.body` instead */
|
||||
|
Loading…
Reference in New Issue
Block a user