小叽资源自动填写密码

自动填写小叽资源网站的密码

// ==UserScript==
// @name         小叽资源自动填写密码
// @namespace    http://tampermonkey.net/
// @version      2024-05-25
// @description  自动填写小叽资源网站的密码
// @author       kakasearch
// @match        https://acgxj.com/XJ*
// @match        https://91bpw.com/XJ*
// @match        https://acfb.top/XJ*
// @match        https://acgxj.com/xj*
// @match        https://91bpw.com/xj*
// @match        https://acfb.top/xj*
// @icon         https://www.google.com/s2/favicons?sz=64&domain=acgxj.com
// @grant        none
// @license      MIT
// @run-at       document-end
// ==/UserScript==

(function() {
    'use strict';
    let content = null
    if(/acgxj/.test(window.location.href)){
       content = document.querySelector(".kratos-post-content").innerText
    }else if(/91bpw/.test(window.location.href)){
       content = document.querySelector(".post-countent-data").innerText
    }else{
       content = document.querySelector("#lightgallery").innerText
    }
    let password = /\d+/.test(content)?/\d+/.exec(content)[0] :""
    let password_input = document.querySelector("form.post-password-form").querySelector("input")
    password_input.type = ""
    password_input.value = password
    // Your code here...
})();