Greasy Fork is available in English.
移除蝦皮廣告
当前为
// ==UserScript==
// @name Shopee ad blocker
// @version 1.0.1
// @description 移除蝦皮廣告
// @author Danny H.
// @match https://shopee.tw/*
// @icon https://freepngimg.com/save/109004-shopee-logo-free-transparent-image-hq/128x128
// @grant GM_addStyle
// @license MIT
// @require https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js
// @namespace http://greasyfork.icu/users/1166167
// ==/UserScript==
(function() {
'use strict';
const removead = setInterval(() => {
const $items = $('.col-xs-2-4.shopee-search-item-result__item');
$items.each(function() {
const $text = $(this).find('.F7xq8U');
if ($text.text().indexOf('Ad') !== -1 || $text.text().indexOf('廣告') !== -1) {
$(this).hide();
}
// 隱藏 shopee-header-section shopee-header-section--simple
const $header = $('.shopee-header-section.shopee-header-section--simple');
$header.remove();
});
const $List = $('.OLut87');
$List.each(function() {
const $text = $(this).find('.Y8EPKl');
if ($text.text().indexOf('Ad') !== -1 || $text.text().indexOf('廣告') !== -1) {
$(this).hide();
}
});
});
window.addEventListener('locationchange', removead);
})();