使用Ant设计的Im,但Modal未按预期在点击时关闭。
function Study(props) {
let data=props.data
const showConfirm=(e,val,view) =>{ debugger
confirm({
title: Are you sure you want to remove +val+ from your study list? ,
icon: <ExclamationCircleOutlined />,
okText: Yes ,
cancelText: No ,
onOk:()=>{confirmOk(val,view)},
onCancel() {
console.log( Cancel );
},
});
}
return (
<div>
{props.deleteOption && <img class="deleteIcon" src={crossIcon} onClick={(e)=>showConfirm(e,data.studyName,props.view)}></img>}
</div>
)
}
Please some one suggest the solution