HTML5 for arXiv

An extension that makes html5 source available in arxiv.org based on the amazing ar5iv project.

スクリプトをインストールするには、Tampermonkey, GreasemonkeyViolentmonkey のような拡張機能のインストールが必要です。

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

スクリプトをインストールするには、TampermonkeyViolentmonkey のような拡張機能のインストールが必要です。

スクリプトをインストールするには、TampermonkeyUserscripts のような拡張機能のインストールが必要です。

このスクリプトをインストールするには、Tampermonkeyなどの拡張機能をインストールする必要があります。

このスクリプトをインストールするには、ユーザースクリプト管理ツールの拡張機能をインストールする必要があります。

(ユーザースクリプト管理ツールは設定済みなのでインストール!)

このスタイルをインストールするには、Stylusなどの拡張機能をインストールする必要があります。

このスタイルをインストールするには、Stylus などの拡張機能をインストールする必要があります。

このスタイルをインストールするには、Stylus tなどの拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

(ユーザースタイル管理ツールは設定済みなのでインストール!)

このスクリプトの質問や評価の投稿はこちら通報はこちらへお寄せください
// ==UserScript==
// @name         HTML5 for arXiv
// @namespace    http://tampermonkey.net/
// @version      0.1
// @name:zh-CN   HTML5 for arXiv
// @description  An extension that makes html5 source available in arxiv.org based on the amazing ar5iv project.
// @description:zh-cn 更便捷的访问HTML5论文!
// @author       AnCoSONG
// @license      MIT
// @match        https://arxiv.org/abs/*
// @icon         https://www.google.com/s2/favicons?sz=64&domain=arxiv.org
// @grant        none
// ==/UserScript==

(function() {
    'use strict';
    function setup() {
        try {
            var prefix = location.pathname
            var ul = document.querySelector('.full-text ul')
            var li = document.createElement('li')
            var a = document.createElement('a')
            a.href = 'https://ar5iv.org' + prefix
            a.innerText = 'HTML5(ar5iv)'
            a.className = 'abs-button'
            a.target = '_blank'
            li.appendChild(a)
            ul.appendChild(li)
        }catch(e) {
            console.log('error happened, skip.\n', e)
        }
    }
    if (document.readyState === 'loading') {
        document.addEventListener('DOMContentLoaded', setup)
    } else {
        setup()
    }
})();