diff --git a/src/contentScripts/views/App.vue b/src/contentScripts/views/App.vue index 84f94cce..48b0aae0 100644 --- a/src/contentScripts/views/App.vue +++ b/src/contentScripts/views/App.vue @@ -63,6 +63,14 @@ const showBewlyPage = computed((): boolean => { } }) +const showIframePage = computed((): boolean => { + // If the iframe is not the BiliBili homepage, then don't show the iframe page + if (!isHomePage(window.self.location.href)) + return false + // use `!isInIframe()` to prevent nested calls to the BiliBili homepage + return !isInIframe() && !!iframePageURL.value && !!activatedPage.value +}) + const isFirstTimeActivatedPageChange = ref(true) watch( () => activatedPage.value, @@ -276,7 +284,7 @@ provide('BEWLY_APP', { pointer-events-none > ('BEWLY_APP', { - - +