Last active
November 10, 2021 12:35
-
-
Save zklhp/c1a358f026358786bef58b49f65d8333 to your computer and use it in GitHub Desktop.
Close useless tabs in 163 mail
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Close useless tabs in 163 mail | |
// @namespace https://github.com/zklhp | |
// @icon https://mail.163.com/favicon.ico | |
// @version 3.3.0 | |
// @description Close useless tabs | |
// @homepageURL https://gist.github.com/zklhp/c1a358f026358786bef58b49f65d8333 | |
// @updateURL https://gist.github.com/zklhp/c1a358f026358786bef58b49f65d8333/raw/Close-uselesstabs-in-163-mail.user.js | |
// @author Chris Zheng <https://chriszheng.science/> | |
// @match *://mail.163.com/* | |
// ==/UserScript== | |
/* jshint esversion: 10 */ | |
(() => { | |
var to_close = ["#_mail_link_2_135", "#_mail_link_2_137", "#_mail_link_4_125", "#_mail_link_3_122"]; | |
for (let x of to_close) { | |
try { | |
document.querySelector(x).click(); | |
} catch {} | |
} | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks:)