Skip to content

Instantly share code, notes, and snippets.

@LorseKudos
Created June 19, 2022 07:41
Show Gist options
  • Save LorseKudos/63a0597be08c677475bddc4467287b99 to your computer and use it in GitHub Desktop.
Save LorseKudos/63a0597be08c677475bddc4467287b99 to your computer and use it in GitHub Desktop.
// ==UserScript==
// @name RemoveAdInYahooMail
// @namespace https://github.com/LorseKudos
// @version 0.1
// @description ヤフーメールの広告カラムを削除します
// @author Lorse
// @match https://mail.yahoo.co.jp/u/pc/f/*
// @grant none
// @require https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js
// ==/UserScript==
(function() {
'use strict';
let removed_flag = false;
function removeAd() {
if($('.sc-1xxziom-0').length !== 0){
$('.sc-1xxziom-0').remove();
removed_flag = true;
}
if(!removed_flag) {
window.setTimeout(removeAd, 500);
}
}
removeAd();
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment