xkcd Tweaks

Some tweaks to xkcd.com and what-if.xkcd.com

当前为 2016-08-11 提交的版本,查看 最新版本

您需要先安装一个扩展,例如 篡改猴Greasemonkey暴力猴,之后才能安装此脚本。

You will need to install an extension such as Tampermonkey to install this script.

您需要先安装一个扩展,例如 篡改猴暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴Userscripts ,之后才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。

您需要先安装用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

作者
MitalAshok
评分
0 0 0
版本
1.0.1
创建于
2016-08-10
更新于
2016-08-11
大小
16.8 KB
许可证
http://creativecommons.org/licenses/by-sa/4.0/
适用于

xkcd Tweaks is a script that changes some little things that annoyed me. Made in an afternoon. Thought I would share.

Tested and works perfectly with Firefox 48.0* Mostly tested and probably works fine with Chrome 52.0* (Nothing else tested) *Latest as of 2016-08-10

xkcd.com Tweaks

  • Added the title text below comic and removed from hovering over comic (Disable with titleText = false)
  • Added the (normally hidden) transcript below the comic (Disable with transcript = false)
  • Added Explain! which links to the comic on www.explainxkcd.com (Disable with explainButton = false)
  • Added a hr (horizontal rule) above and below comic (Disable with hr = false)
  • Removed Next > and >| when on latest comic (as they don't do anything anyways)
  • Removed < Prev and |< when on first comic (likewise)
  • Made scrolling snap to the top of the comic (below info bar) after half a second. It doesn't work well in Chrome. Enable with snap = true. (Default false)
  • Added some keyboard shortcuts.
    • (Left arrow) and p go to the previous comic.
    • (Right arrow) and n go to the next comic.
    • r goes to a random comic.

what-if.xkcd.com Tweaks

  • If you are on 'whatif.xkcd.com', you are redirected to 'what_-_if.xkcd.com'.
  • Added a semi-transparant 2 pixel grey border around images (Disable with border = false)
  • Added the title text below images and removed from hovering over comic (Disable with titleText = false)
  • Added a First button on all but the first article (where it would go nowhere) that links to the first article.
  • Likewise for Last.
  • Added a Random button that goes to a random article.
  • Added some keyboard shortcuts.
    • (Left arrow) and p go to the previous article.
    • (Right arrow) and n go to the next article.
    • r goes to a random article.

Note: To edit variables after you have installed the script with GreaseMonkey on Firefox, go to 'about:addons' (Or do Ctrl+Shift+a), go to the 'User Scripts' tab, click Options and then 'Edit this User Script'.

If you are having issues, start a discussion here (GreasyFork).

Creative Commons Licence
xkcd Tweaks by Mital Ashok is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License. Icon image, xkcd and What If? by Randall P. Munroe are used under CC BY-NC 2.5 / Icon reencoded as .png base 64 data URI (data:image/png;base64,...).