From 3727ea2c3354e2d0f519d9b75e8f990eb1ed1f00 Mon Sep 17 00:00:00 2001 From: Alex Chao Date: Wed, 19 Jul 2017 09:21:20 +0800 Subject: [PATCH] feat: Modal.confirm supports zIndex prop #6722 (#6880) * Modal.confirm supports zIndex prop #6722 * Fix filename * Fix the zIndex missing in ModalFuncProps interface --- components/modal/Modal.tsx | 2 ++ components/modal/__tests__/{comfirm.test.js => confirm.test.js} | 0 components/modal/confirm.tsx | 1 + 3 files changed, 3 insertions(+) rename components/modal/__tests__/{comfirm.test.js => confirm.test.js} (100%) diff --git a/components/modal/Modal.tsx b/components/modal/Modal.tsx index 99b892828f..3e3af69ac8 100644 --- a/components/modal/Modal.tsx +++ b/components/modal/Modal.tsx @@ -40,6 +40,7 @@ export interface ModalProps { transitionName?: string; className?: string; getContainer?: (instance: React.ReactInstance) => HTMLElement; + zIndex?: boolean; } export interface ModalContext { @@ -61,6 +62,7 @@ export interface ModalFuncProps { cancelText?: string; iconType?: string; maskClosable?: boolean; + zIndex?: boolean; } export type ModalFunc = (props: ModalFuncProps) => { destroy: () => void, diff --git a/components/modal/__tests__/comfirm.test.js b/components/modal/__tests__/confirm.test.js similarity index 100% rename from components/modal/__tests__/comfirm.test.js rename to components/modal/__tests__/confirm.test.js diff --git a/components/modal/confirm.tsx b/components/modal/confirm.tsx index 2f22766fad..71dd928be3 100644 --- a/components/modal/confirm.tsx +++ b/components/modal/confirm.tsx @@ -91,6 +91,7 @@ export default function confirm(config) { maskClosable={maskClosable} style={style} width={width} + zIndex={props.zIndex} >
{body} {footer}