Greasy Fork

Greasy Fork is available in English.

Pixiv 历史记录增强

让非会员浏览历史记录

当前为 2019-08-26 提交的版本,查看 最新版本

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Greasemonkey 油猴子Violentmonkey 暴力猴,才能安装此脚本。

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

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

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

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

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

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

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

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

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

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

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

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

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

// ==UserScript==
// @name         Pixiv enhance history
// @name:zh-CN   Pixiv 历史记录增强
// @name:zh-TW   Pixiv 歷史記錄增强
// @namespace    http://tampermonkey.net/
// @icon         https://i.pximg.net/user-profile/img/2019/05/02/16/56/10/15718030_ded90a676c52836d9f739f7aa6d4faf6_170.jpg
// @version      0.1
// @description        Just let non-members browse history
// @description:zh-CN  让非会员浏览历史记录
// @description:zh-TW  讓非會員瀏覽歷史記錄
// @description:ja     非会員が履歴を閲覧できるようにする
// @author       Quantum-Electrodynamics
// @include      http*://www.pixiv.net/history.php
// @grant        none
// ==/UserScript==

(function() {
    'use strict';
    var count=60
    var temp=setInterval(function(){
        var historys=$("span._history-item")
        if (historys.length){
            historys.each(function(){
                var pid=/(?<=\/)\d*?(?=_)/.exec($(this).attr("style"))
                var url=/http.*?\.jpg/.exec($(this).attr("style"))
                var newelement="<a href=\"/member_illust.php?mode=medium&amp;illust_id="+pid+"\" target=\"_blank\" class=\"_history-item show-detail list-item\" style=\"background-image: url(&quot;"+url+"&quot;);\"><div class=\"status\"></div></a>"
                $(this).after(newelement)
                $(this).remove()
            })
            clearInterval(temp)
        } else {
            if (!--count) {
                console.log("can't find history")
                clearInterval(temp)
            }
        }
    }, 500)
})();