feat(iframe-drawer): close the drawer when open in new tab

This commit is contained in:
Hakadao
2024-12-09 02:47:22 +08:00
parent 726315299d
commit c497216dde

View File

@@ -99,8 +99,10 @@ async function releaseIframeResources() {
}
function handleOpenInNewTab() {
if (iframeRef.value)
if (iframeRef.value) {
window.open(iframeRef.value.contentWindow?.location.href.replace(/\/$/, ''), '_blank')
handleClose()
}
}
const isEscPressed = ref<boolean>(false)