您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
用 Cubox 将此页面保存为书签
当前为
// ==UserScript== // @name MonaKit Cubox 书签 // @name:zh MonaKit Cubox 书签 // @name:en Monakit Cubox // @namespace https://github.com/scris/monakit.git // @homepageURL https://ds.scris.top/ // @version 1.0.2 // @description 用 Cubox 将此页面保存为书签 // @description:zh 用 Cubox 将此页面保存为书签 // @description:en Add this page to Cubox Bookmark // @icon https://cubox.pro/favicon.ico // @author Tianze Ds Qiu <https://ds.scris.top/> // @match *://*/* // @grant none // @run-at document-end // @require http://libs.baidu.com/jquery/2.1.4/jquery.min.js // @license MPL-2.0 // @noframes // ==/UserScript== const style = document.createElement("style"); style.innerText = ` .monakit-cubox { position: fixed; left: 8px; bottom: 7px; width: 80px; height: 30px; } `; document.body.appendChild(style); this.alt = document.createElement("button"); this.alt.className = "monakit-cubox"; this.alt.innerText = "Cubox"; document.body.appendChild(this.alt); $(".monakit-cubox").click(function () { var url = location.href; var title = document.title; var desc = ""; if (document.getSelection) { desc = document.getSelection(); } if (desc.toString().length === 0) { let descTag = document.querySelector("[name=description]"); desc = descTag ? descTag.getAttribute("content") : ""; } if (desc != null) { if (desc.length > 500) { desc = desc.slice(0, 500) + "..."; } } void open( "https://cubox.pro/web/tool/collection?url=" + encodeURIComponent(url) + "&title=" + encodeURIComponent(title) + "&description=" + encodeURIComponent(desc) + "&groupId=" + "&tags=" + "&starTarget=false" + "&editable=false", "cubox", "toolbar=no,resizable=no,location=no,menubar=no,width=300,height=100" ); });