arxiv2cn

An Arxiv Jumper to China Image Source

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Greasemonkey lub Violentmonkey.

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

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana będzie instalacja rozszerzenia Tampermonkey lub Userscripts.

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

Aby zainstalować ten skrypt, musisz zainstalować rozszerzenie menedżera skryptów użytkownika.

(Mam już menedżera skryptów użytkownika, pozwól mi to zainstalować!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Musisz zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

(Mam już menedżera stylów użytkownika, pozwól mi to zainstalować!)

// ==UserScript==
// @name         arxiv2cn
// @name:zh      arxiv2cn
// @name:en      arxiv2cn
// @namespace    arxiv2cn
// @homepage     arxiv2cn
// @version      1.0
// @author       KyanChen
// @description  An Arxiv Jumper to China Image Source
// @description:zh  An Arxiv Jumper to China Image Source
// @description:en  An Arxiv Jumper to China Image Source
// @include      /^https?://(.*\.)?arxiv\.org/.*/
// @run-at       document-end
// @license      MIT License
// ==/UserScript==
window.onload=function () {
    let h0 = document.querySelector('#abs-outer > div.extra-services > div.full-text > ul');
    let h1 = document.querySelector('#abs-outer > div.extra-services > div.full-text > ul > li:nth-child(1)');
    let h2 = h1.cloneNode(h1);
    h2.children[0].text='arxiv2cn';
    h2.children[0].href = h2.children[0].href.replace('https://arxiv.org','http://xxx.itp.ac.cn');
    h0.insertBefore(h2,h0.children[0]);
}();