テスト
広告非表示 by bamichan
Details
Authorbamichan
LicenseNo License
CategoryAll sites, Ad
Created
Updated
Size4.5 kB
Statistics
Learn how we calculate statistics in the FAQ.
Failed to fetch stats.
Description
Notes
Userstyle doesn't have notes.Source code
/* ==UserStyle==
@name 広告非表示
@namespace github.com/openstyles/stylus
@version 1.0.0
@description A new userstyle
@author ばみちゃん
==/UserStyle== */
@-moz-document regexp(".*") {
[class^="ad-"]
,[class$="-ad"]
,[class^="ad_"]
,[class$="_ad"]
,[id^="ad-"]
,[id$="-ad"]
,[id^="ad_"]
,[id$="_ad"]
,[class^="dac-"]
,[id^="dac-"]
,[id^="sas_iframe_fixed"]
,[id*="ad_widget"]
,[class$="ad_widget"]
,.ad
,.adWrap
,[class^="sitejack"]
,[alt*="autopromo"]
,[src^="https://ads.themoneytizer.com"]
,[href="https://us.themoneytizer.com"]
,[id*="google_ads"]
,iframe[src^="https://googleads"]
,iframe[src^="https://www.google.com"]
,iframe[id^="google_ads"]
,iframe[id^="sas"]
,[class*="adsbygoogle"]
,[rel*="sponsored"]
,div:has(> [rel*="sponsored"])
{display: none !important;}
}
@-moz-document url("https://www.yahoo.co.jp/") {
div#TBP
,#wrapper a[href="javascript:void(0);"]
,div#GDN
,div[id^="STREAMAD"]
{display: none !important;}
}
@-moz-document url("https://twitter.com/*") {
[data-testid="placementTracking"]
,[class$="css-1dbjc4n"][data-testid="placementTracking"]
,[class$="css-175oi2r"][data-testid="placementTracking"]
,[class="css-1dbjc4n"][data-testid="placementTracking"]:has([d^="M19.498 3h-15c-1.381 0-2.5 1.12-2.5"])
,[class="css-175oi2r"][data-testid="placementTracking"]:has([d^="M19.498 3h-15c-1.381 0-2.5 1.12-2.5"])
,.css-1dbjc4n > .css-1dbjc4n.r-1wtj0ep.r-1ny4l3l{
display: none !important;
height: 0 !important;
overflow: hidden;
margin-top: -1px;
padding: 0;
}
}
@-moz-document url("https://x.com/*") {
[data-testid="placementTracking"]
,[class$="css-1dbjc4n"][data-testid="placementTracking"]
,[class$="css-175oi2r"][data-testid="placementTracking"]
,[class="css-1dbjc4n"][data-testid="placementTracking"]:has([d^="M19.498 3h-15c-1.381 0-2.5 1.12-2.5"])
,[class="css-175oi2r"][data-testid="placementTracking"]:has([d^="M19.498 3h-15c-1.381 0-2.5 1.12-2.5"])
,.css-1dbjc4n > .css-1dbjc4n.r-1wtj0ep.r-1ny4l3l{
display: none !important;
height: 0 !important;
overflow: hidden;
margin-top: -1px;
padding: 0;
}
/* カラムの大きさを宣言,値は任意で設定可能 */
/* --full-width→全体の幅 */
/* --third-colmn-width→DM/設定などの画面で3つ目のカラムの幅 */
:root {
--full-width: 700px;
--third-colmn-width: 430px;
}
/* 右部サイドバーを非表示 */
[data-testid="sidebarColumn"] {
display: none !important;
}
/*右部サイドバーを非表示にしたので、中央カラム部分が大きくなりすぎる */
/* 全体幅を調整する */
main .r-rthrr5,
main .r-113js5t {
width: var(--full-width);
}
/* 全体幅を調整することによってDM/設定などの画面で2つ目のカラムが小さくなる */
/* 中央列、右列それぞれにサイズを指定する */
main .r-rthrr5 .r-1ye8kvj:nth-last-child(2),
main .r-113js5t .r-1ye8kvj:nth-last-child(2){
width: calc(100% - var(--third-colmn-width));
}
main .r-rthrr5 .r-1ye8kvj+.r-1ye8kvj,
main .r-113js5t .r-1ye8kvj+.r-1ye8kvj {
width: var(--third-colmn-width);
}
/* タイムライン部分のサイズは100%なので上書き */
.r-1ye8kvj[data-testid="primaryColumn"],
.r-1ye8kvj[data-testid="primaryColumn"] .r-1ye8kvj {
width: 100% !important;
max-width: 100%;
}
/* 広告・おすすめ・トピックを非表示に */
[class$="css-1dbjc4n"][data-testid="placementTracking"],
[class$="css-1dbjc4n"][aria-label$="のツイート"] [data-testid="UserCell"],
[class$="css-1dbjc4n"] [aria-label="タイムライン: Carousel"] {
height: 0 !important;
overflow: hidden;
margin-top: -1px;
padding: 0
}
/* プロフページ内[プロモーションする]ボタンを非表示に */
a[href$="quick_promote_web/intro"] {
display: none;
}
/* 認証済み組織ボタンを非表示に */
a[aria-label="認証済み組織"] {
display: none;
}
}
@-moz-document url("https://mail.google.com/*") {
/*Gmailの広告メール削除*/
tbody>tr:has(span>span.ast),tr.zE {
display: none !important;
}
}