hypothes.isFloatingButton

This is a shortcut for using hypothes.is service. It combines the hypothes.is bookmarklet to the page directly for a further convience.

当前为 2019-06-19 提交的版本,查看 最新版本

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

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

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

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

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

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

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

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

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

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

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

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

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

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

// ==UserScript==
// @name         hypothes.isFloatingButton
// @version      1.0.2
// @author       Lancelotly.Sagirrarimeow
// @description  This is a shortcut for using hypothes.is service. It combines the hypothes.is bookmarklet to the page directly for a further convience.
// @match        *://*/*
// @exclude      https://hypothes.is/*
// @grant        GM_addStyle
// @update      
// @namespace https://greasyfork.org/users/296362
// ==/UserScript==

/*--- Create a button in a container div.  It will be styled and positioned with CSS.*/
var zNode=document.createElement("div");function buttonClickAction(t){!function(){window.hypothesisConfig=function(){return{showHighlights:!0,appType:"bookmarklet"}};var t=document,e=t.createElement("script");e.setAttribute("src","https://hypothes.is/embed.js"),t.body.appendChild(e)}()}zNode.innerHTML='<div id="fButton" data-toggle="tooltip" data-placement="left" data-original-title="Create"></div>',zNode.setAttribute("id","myFloatingButton"),document.body.appendChild(zNode),document.getElementById("fButton").addEventListener("click",buttonClickAction,!1);

//--- Style our newly added elements using CSS.
GM_addStyle(`
#myFloatingButton {
    width: 2em;
    height: 2em;
    border-radius: 50%;
    background-image: url(https://blogresources.lancelotly.ml/img/hypothesis-favicon.png);
    background-repeat: no-repeat;
    background-size: cover;
    position: fixed;
    bottom: 20px;
    left: 20px;
    box-shadow: 0px 2px 5px #666;
}

#fButton {
    cursor: pointer;
    width: 2em;
    height: 2em;
}

#myFloatingButton p {
    color: white;
    display: block;
    text-align: center;
    margin: 0px;
    font-family: 'Roboto';
    font-size: 18px;
}
`);