Simple Redirection Buttons for Pahe

Simplify link jumping on pahe websites (Intercelestial and Linegee).

Från och med 2023-04-04. Se den senaste versionen.

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

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

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

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

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

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

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.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name         Simple Redirection Buttons for Pahe
// @namespace    https://naeembolchhi.github.io/
// @version      0.56
// @description  Simplify link jumping on pahe websites (Intercelestial and Linegee).
// @author       NaeemBolchhi
// @match        https://intercelestial.com/*
// @match        https://linegee.net/*
// @license      GPL-3.0-or-later
// @icon         https://pahe.li/wp-content/uploads/2017/12/favicon.ico
// @require      https://greatest.deepsurf.us/scripts/456228/code/456228.js?version=1125944
// @run-at       document-body
// @grant        none
// ==/UserScript==

(function() {
    'use strict';

    function addStyle(css) {
        var head, style;
        head = document.querySelector('head');
        if (!head) {
            window.location.reload();
        }
        style = document.createElement('style');
        style.innerHTML = css;
        head.appendChild(style);
    }

    if (window.location.hostname == "linegee.net") {
        addStyle(`.btn.btn-primary.btn-xs {
                    position: fixed;
                    top: 0;
                    left: 0;
                    height: 100%;
                    width: 100%;
                    z-index: 2147483647 !important;
                    opacity: 1 !important;
                    display: flex;
                    align-items: center;
                    justify-content: center;
                    font-size: 4rem;
                    border-radius: 0;
                  }
                  #backdrop {
                    position: fixed;
                    top: 0;
                    left: 0;
                    height: 100%;
                    width: 100%;
                    z-index: 2147483646 !important;
                    background: black;
                    opacity: 1;
                  }
                  * {
                    overflow: hidden;
                  }`);
    } else if (window.location.hostname == "intercelestial.com") {
        addStyle(`.qc-cmp2-persistent-link {
                    z-index: 0;
                  }
                  #qc-cmp2-container {
                    display: none;
                  }
                  div.wait > center > img {
                    position: fixed;
                    left: 0;
                    top: 0;
                    height: 100%;
                    width: 100%;
                    z-index: 2147483646 !important;
                    background: green;
                    opacity: 1 !important;
                  }
                  #generater > img {
                    display: none;
                  }
                  #generater {
                    position: fixed;
                    height: 100%;
                    width: 50%;
                    z-index: 2147483646 !important;
                    background: red;
                    opacity: 1 !important;
                  }
                  #showlink {
                    position: fixed;
                    height: 100%;
                    width: 50%;
                    z-index: 2147483646 !important;
                    background: blue;
                    opacity: 1 !important;
                  }
                  @media only screen and (orientation: landscape) {
                    #generater {
                      left: 0;
                    }
                    #showlink {
                      right: 0;
                    }
                    #generater, #showlink {
                      top: 0;
                      height: 100%;
                      width: 50%;
                    }
                  }
                  @media only screen and (orientation: portrait) {
                    #generater {
                      top: 0;
                    }
                    #showlink {
                      bottom: 0;
                    }
                    #generater, #showlink {
                      left: 0;
                      height: 50%;
                      width: 100%;
                    }
                  }
                  #backdrop {
                    position: fixed;
                    top: 0;
                    left: 0;
                    height: 100%;
                    width: 100%;
                    z-index: 2147483645 !important;
                    background: black;
                    opacity: 1;
                  }
                  #soralink-human-verif-main-cxxd {
                    display: none;
                  }
                  #timeshow {
                    position: fixed;
                    top: 0;
                    left: 0;
                    display: flex;
                    height: 100%;
                    width: 100%;
                    background: transparent;
                    z-index: 2147483647 !important;
                    align-items: center;
                    justify-content: center;
                  }
                  #timeshow circle {
                    background: #181818;
                    box-shadow: #181818 0 0 1rem;
                    height: 10rem;
                    width: 10rem;
                    border-radius: 100%;
                    display: flex;
                    align-items: center;
                    justify-content: center;
                  }
                  #timeshow span {
                    font-size: 5rem;
                    font-family: monospace;
                    color: white;
                  }
                  #timeshow.countOFF {
                    display: none;
                  }
                  /*
                  span[id*='countdown'], span[id^='_'] {
                    position: fixed;
                    display: flex;
                    bottom: 0;
                    left: 0;
                    width: 100%;
                    justify-content: center;
                    font-size: 5rem;
                    z-index: 2147483647 !important;
                  }
                  */
                  * {
                    overflow: hidden;
                  }`);
    }

    const makeZERO = "data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 0 0' xml:space='preserve'></svg>";

    setInterval(function() {
        try {
            document.querySelector("#soralink-human-verif-main").src = makeZERO;
        } catch {}
        try {
            document.querySelector("#showlink").src = makeZERO;
        } catch {}
    }, 200);

    try {
        let element;

        element = document.createElement("div");
        element.id = "backdrop";
        document.body.appendChild(element);

        if (window.location.hostname !== "intercelestial.com") {return;}

        element = document.createElement("div");
        element.id = "timeshow";
        element.className = "countOFF";
        element.innerHTML = "<circle><span>#</span></circle>";
        document.body.appendChild(element);
    } catch {}
/*
    function showCounter() {
        const timeshow = document.getElementById("timeshow");

        if (document.querySelector("span[id*='countdown']")) {
            let home = document.querySelector("span[id*='countdown']"),
                show = document.querySelector("#timeshow span");

            show.innerText = home.innerText.replace(/\s.(*)/,"");

            if (home.innerText.replace(/\s.(*)/,"").match(/[0-9]/)) {
                timeshow.className = "countON";
                if (parseFloat(home.innerText.replace(/\s.(*)/,"")) === 0) {
                    home.innerText = "X";
                    setTimeout(function() {
                        timeshow.className = "countOFF";
                    }, 1000);
                }
            } else {
                timeshow.className = "countOFF";
            }
        } else if (document.querySelectorAll("span[id^='_']")[0] && document.querySelectorAll("span[id^='_']")[0].innerText.replace(/\s.(*)/,"").match(/[0-9]/)) {
            let home = document.querySelectorAll("span[id^='_']"),
                show = document.querySelector("#timeshow span");

            show.innerText = home[0].innerText.replace(/\s.(*)/,"");

            if (home[0].innerText.replace(/\s.(*)/,"").match(/[0-9]/)) {
                timeshow.className = "countON";
                if (parseFloat(home[0].innerText.replace(/\s.(*)/,"")) === 0) {
                    home[0].innerText = "X";
                    setTimeout(function() {
                        timeshow.className = "countOFF";
                    }, 1000);
                }
            } else {
                timeshow.className = "countOFF";
            }
        } else if (document.querySelectorAll("span[id^='_']")[1] && document.querySelectorAll("span[id^='_']")[1].innerText.replace(/\s.(*)/,"").match(/[0-9]/)) {
            let home = document.querySelectorAll("span[id^='_']"),
                show = document.querySelector("#timeshow span");

            show.innerText = home[1].innerText.replace(/\s.(*)/,"");

            if (home[1].innerText.replace(/\s.(*)/,"").match(/[0-9]/)) {
                timeshow.className = "countON";
                if (parseFloat(home[1].innerText.replace(/\s.(*)/,"")) === 0) {
                    home[1].innerText = "X";
                    setTimeout(function() {
                        timeshow.className = "countOFF";
                    }, 1000);
                }
            } else {
                timeshow.className = "countOFF";
            }
        } else {
            timeshow.className = "countOFF";
        }
    }

    const showtimer = setInterval(showCounter, 100);
*/
})();