Skip to content

Commit 5b4c599

Browse files
committed
update
1 parent a764404 commit 5b4c599

File tree

1 file changed

+17
-15
lines changed

1 file changed

+17
-15
lines changed

src/components/CheckAdBlocked.svelte

+17-15
Original file line numberDiff line numberDiff line change
@@ -26,21 +26,21 @@
2626
}
2727
2828
// check script banned
29-
checkAdScriptBanned('https://log.mmstat.com/eg.js');
29+
checkAdScriptBanned("https://cdn.wwads.cn/js/makemoney.js");
3030
}
31-
31+
3232
function checkAdScriptBanned(scriptUrl) {
3333
fetch(scriptUrl)
34-
.then(response => {
35-
if (!response.ok) {
36-
console.log("ADBlock detected, cause script can't be loaded");
37-
hasAdBlockDetected = true;
38-
}
39-
})
40-
.catch(() => {
41-
console.log("ADBlock detected, cause script banned");
34+
.then((response) => {
35+
if (!response.ok) {
36+
console.log("ADBlock detected, cause script can't be loaded");
4237
hasAdBlockDetected = true;
43-
});
38+
}
39+
})
40+
.catch(() => {
41+
console.log("ADBlock detected, cause script banned");
42+
hasAdBlockDetected = true;
43+
});
4444
}
4545
4646
onMount(() => {
@@ -55,10 +55,6 @@
5555
: 'hidden'} fixed inset-0 bg-black bg-opacity-90 z-[99999]"
5656
>
5757
<div class="m-auto p-5 bg-white rounded-lg text-center space-y-4">
58-
<button
59-
class="absolute top-3 right-3 text-black text-white bg-transparent"
60-
on:click={closeNotice}>×</button
61-
>
6258
<p class="text-center text-lg text-gray-700">
6359
我们的广告服务商并不跟踪您的隐私,为了支持本站的长期运营,请将我们的网站加入广告拦截器的白名单,谢谢!
6460
</p>
@@ -77,6 +73,12 @@
7773
>
7874
查看加入白名单教程
7975
</a>
76+
<button
77+
class="px-4 py-2 bg-neutral-300 text-white rounded hover:bg-neutral-400 transition duration-300 text-current no-underline hover:no-underline"
78+
on:click={closeNotice}
79+
>
80+
关闭
81+
</button>
8082
</div>
8183
</div>
8284
</div>

0 commit comments

Comments
 (0)