您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
showModalDialog Compatible For GZHU
当前为
// ==UserScript== // @name showModalDialog for gzhu the second lesson // @namespace https://greasyfork.org/zh-CN/users/220174-linepro // @version 0.1 // @description showModalDialog Compatible For GZHU // @author LinePro // @match *://172.17.1.123/* // @grant none // ==/UserScript== (function() { 'use strict'; // Your code here... function getValue(str, key) { const index = str.indexOf(key); return str.slice(index + key.length + 1, str.indexOf(';', index)); } const doc = document; window.showModalDialog = function (uri, _arguments, _options) { _options = _options.toLowerCase(); let window_feature = 'toolbar=no, menubar=no'; window_feature += getValue(_options, 'dialogwidth') ? ',width=' + getValue(_options, 'dialogwidth') : ''; window_feature += getValue(_options, 'dialogheight') ? ',height=' + getValue(_options, 'dialogheight') : ''; console.log(window_feature); window.open(uri, 'window', window_feature); } })();