右下角通知弹窗关闭

This commit is contained in:
yj 2025-01-22 09:58:00 +08:00
parent 1d2f1072ef
commit 54a5b442cd
1 changed files with 9 additions and 7 deletions

View File

@ -68,13 +68,15 @@ const NoticeWindow: React.FC = () => {
</div> </div>
</div>, </div>,
onClose: () => { onClose: () => {
const dom = document.getElementsByClassName('ant-notification') setTimeout(() => {
if (dom.length === 0) { const dom = document.getElementsByClassName('ant-notification')
window.electron.setChildWindowShow({ if (dom.length === 0) {
key: 'noticeWindow', window.electron.setChildWindowShow({
bool: false key: 'noticeWindow',
}) bool: false
} })
}
}, 0);
}, },
duration: 10, duration: 10,
placement: 'bottomRight', placement: 'bottomRight',