From 400e6ed929c6aa4ec27e7b8b519fe4f88ecedb3b Mon Sep 17 00:00:00 2001 From: anime Date: Tue, 24 Dec 2024 15:57:47 +0800 Subject: [PATCH] =?UTF-8?q?feat(=E4=BC=98=E5=8C=96=E6=96=87=E7=AB=A0?= =?UTF-8?q?=E5=86=85Google=20AdSense=20=E5=A4=84=E7=90=86):?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit (cherry picked from commit ed8983171355976c20d9205665f9a880f0f49dd4) --- components/GoogleAdsense.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/components/GoogleAdsense.js b/components/GoogleAdsense.js index f102847b..a27d25dc 100644 --- a/components/GoogleAdsense.js +++ b/components/GoogleAdsense.js @@ -182,8 +182,9 @@ const AdEmbed = () => { useEffect(() => { setTimeout(() => { // 找到所有 class 为 notion-text 且内容为 '' 的 div 元素 - const notionTextElements = document.querySelectorAll('div.notion-text') - + const notionTextElements = document.querySelectorAll( + '#article-wrapper #notion-article div.notion-text' + ) // 遍历找到的元素 notionTextElements?.forEach(element => { // 检查元素的内容是否为 ''