您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Enable to paste the GIF directly in a GitHub comment or anywhere else that requires a Markdown syntax
当前为
// ==UserScript== // @name Giphy - add Markdown format // @namespace http://splintor.wordpress.com/ // @version 0.2 // @description Enable to paste the GIF directly in a GitHub comment or anywhere else that requires a Markdown syntax // @author [email protected] // @updateUrl https://gist.github.com/splintor/d17771cf706a5d874222651577be7e8a/raw // @match https://giphy.com/gifs/*/links // ==/UserScript== (function() { 'use strict'; const gifLink = Array.from(document.querySelectorAll('input')).find(i => i.value.endsWith('giphy.gif')).parentNode; const markdownTag = gifLink.cloneNode(true); markdownTag.firstChild.innerText = 'Markdown Tag'; const input = markdownTag.querySelector('input'); input.value = ``; input.addEventListener('focus', e => e.target.select()); gifLink.after(markdownTag); })();