diff --git a/components/Modal/Modal.tsx b/components/Modal/Modal.tsx index 75f5347..6072780 100644 --- a/components/Modal/Modal.tsx +++ b/components/Modal/Modal.tsx @@ -89,7 +89,8 @@ class Modal extends Component { className, style, title, bodyCotent, content, icon, width, zIndex, showCancel, okText, cancelText, type, closeText, showClose, - maskStyle, maskClosable, showMask, maskClick, + maskStyle, maskClosable, showMask, maskClick, onOk, + onCancel, ...otherProps } = this.props; const preCls = 'yoshino-modal'; diff --git a/docs/pages/Modal/demo/modalDemo.tsx b/docs/pages/Modal/demo/modalDemo.tsx index 1ad2bae..45f3bcc 100644 --- a/docs/pages/Modal/demo/modalDemo.tsx +++ b/docs/pages/Modal/demo/modalDemo.tsx @@ -8,6 +8,7 @@ export default function () { title: '这是一个标题!!!', content: '这是一个内容主题!这是一个内容主题!这是一个内容主题!这是一个内容主题!!', width: 400, + onOk: () => true, }); };