// ==UserScript== // @name 咚咚 // @namespace chensuiyi // @version 1.0.3 // @description 咚咚 - 敲开网络世界的超级门! // @author https://yicode.tech // @match http://*/* // @match https://*/* // @license GPL-3.0 // @run-at document-idle // @noframes // @grant unsafeWindow // @grant GM_addStyle // @grant GM_addElement // @grant GM_listValues // @grant GM_addValueChangeListener // @grant GM_removeValueChangeListener // @grant GM_setValue // @grant GM_getValue // @grant GM_deleteValue // @grant GM_log // @grant GM_getResourceText // @grant GM_getResourceURL // @grant GM_registerMenuCommand // @grant GM_unregisterMenuCommand // @grant GM_openInTab // @grant GM_xmlhttpRequest // @grant GM_download // @grant GM_getTab // @grant GM_saveTab // @grant GM_getTabs // @grant GM_notification // @grant GM_setClipboard // @grant GM_info // @require https://cdn.bootcdn.net/ajax/libs/jquery/3.6.0/jquery.slim.min.js // @require https://lf26-cdn-tos.bytecdntp.com/cdn/expire-1-M/vue/2.6.14/vue.min.js // @require https://lf9-cdn-tos.bytecdntp.com/cdn/expire-1-M/dayjs/1.10.8/dayjs.min.js // @downloadURL none // ==/UserScript== (function () { try { GM_addStyle(`.yigithub-user-script-js{position:fixed;right:0;top:0;bottom:0;left:0;background-color:#fff;z-index:999999999999999 !important;visibility:visible !important;transition:all .2s;display:flex;justify-content:center;align-items:center}.yigithub-user-script-js div,.yigithub-user-script-js span,.yigithub-user-script-js applet,.yigithub-user-script-js object,.yigithub-user-script-js iframe,.yigithub-user-script-js h1,.yigithub-user-script-js h2,.yigithub-user-script-js h3,.yigithub-user-script-js h4,.yigithub-user-script-js h5,.yigithub-user-script-js h6,.yigithub-user-script-js p,.yigithub-user-script-js blockquote,.yigithub-user-script-js pre,.yigithub-user-script-js a,.yigithub-user-script-js abbr,.yigithub-user-script-js acronym,.yigithub-user-script-js address,.yigithub-user-script-js big,.yigithub-user-script-js cite,.yigithub-user-script-js code,.yigithub-user-script-js del,.yigithub-user-script-js dfn,.yigithub-user-script-js em,.yigithub-user-script-js img,.yigithub-user-script-js ins,.yigithub-user-script-js kbd,.yigithub-user-script-js q,.yigithub-user-script-js s,.yigithub-user-script-js samp,.yigithub-user-script-js small,.yigithub-user-script-js strike,.yigithub-user-script-js strong,.yigithub-user-script-js sub,.yigithub-user-script-js sup,.yigithub-user-script-js tt,.yigithub-user-script-js var,.yigithub-user-script-js b,.yigithub-user-script-js u,.yigithub-user-script-js i,.yigithub-user-script-js center,.yigithub-user-script-js dl,.yigithub-user-script-js dt,.yigithub-user-script-js dd,.yigithub-user-script-js ol,.yigithub-user-script-js ul,.yigithub-user-script-js li,.yigithub-user-script-js fieldset,.yigithub-user-script-js form,.yigithub-user-script-js label,.yigithub-user-script-js legend,.yigithub-user-script-js table,.yigithub-user-script-js caption,.yigithub-user-script-js tbody,.yigithub-user-script-js tfoot,.yigithub-user-script-js thead,.yigithub-user-script-js tr,.yigithub-user-script-js th,.yigithub-user-script-js td,.yigithub-user-script-js article,.yigithub-user-script-js aside,.yigithub-user-script-js canvas,.yigithub-user-script-js details,.yigithub-user-script-js embed,.yigithub-user-script-js figure,.yigithub-user-script-js figcaption,.yigithub-user-script-js footer,.yigithub-user-script-js header,.yigithub-user-script-js hgroup,.yigithub-user-script-js menu,.yigithub-user-script-js nav,.yigithub-user-script-js output,.yigithub-user-script-js ruby,.yigithub-user-script-js section,.yigithub-user-script-js summary,.yigithub-user-script-js time,.yigithub-user-script-js mark,.yigithub-user-script-js audio,.yigithub-user-script-js video,.yigithub-user-script-js textarea,.yigithub-user-script-js input,.yigithub-user-script-js select{margin:0;padding:0;border:0;outline:0;box-sizing:border-box}.yigithub-user-script-js a{text-decoration:none;color:inherit}.yigithub-user-script-js .icon{width:1em;height:1em;vertical-align:-0.15em;fill:currentColor;overflow:hidden}.yigithub-user-script-js .layout-app{position:absolute;left:0;top:0;right:0;bottom:0}.yigithub-user-script-js .layout-app .layout-top{position:absolute;top:0;left:0;right:0;height:50px;border-bottom:1px solid #eee;display:flex;justify-content:space-between;background-color:#23263a}.yigithub-user-script-js .layout-app .layout-top .left{display:flex}.yigithub-user-script-js .layout-app .layout-top .left .logo{width:50px;height:50px;padding:8px}.yigithub-user-script-js .layout-app .layout-top .left .logo .logo-inner{width:100%;height:100%;background-repeat:no-repeat;background-position:center center;background-size:contain;background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIAAAACACAMAAAD04JH5AAAABGdBTUEAALGPC/xhBQAAAAFzUkdCAK7OHOkAAAHdUExURUdwTEa1/0i1/0m2/0i1/0i1/0i1/0iz/0e1/068/0i0/0i0/0i1/02r/0i3/0W1/0m1/1Cj/0e1/0yr/0m1/0i1/0i2/0i2/0yx/0uw/0e1/0+k/0ux/0i1/0mz/0qy/0+m/1Cp/0+m/0+n/0i2/0yv/0i1/0yv/02s/1Co/1Cg/+n2/0i1/////02v/1Ch/06s/0+q/06t/0+r/0yw/1Cn/0ux/02u/1Cp/1Cl/1Ck/1Ci/0m0/0qz//7+/0mz//L6/0qy/0uy//7//8/o/+v1/1Cm//z9//n8//j8//z+//D5/8rm/+33//b7/06u/06o/3a8/6rU/+74/0+l//T7/8Ph/3a2/4O9/7LX/63V/9/w/77e/4TD/1it/6LS/+Py/4vG/+Pz/+Dx/8bj/+z3/7/g/9js/7zd/87o/7HY//r9/+j1/12n/7zf/5LF/1qm/7LZ/8Pj/67Y/4vC/2u2/3S6/2Kq/7ja/7jd/9nt/9Pp/+fz/93v/12x/02r/02p/02q/4e//3i3/2W2/2qv/6bQ/0i0/1el/5nK/47C/3y5/5bJ/2m1/5fM/6bT/2+x/3q8/5zP/+Tz/+Px/4/E/1aj/1Sq/5LK/1Kh/1Sr/2Gx/26x/7TY/0qx/28GjN8AAAApdFJOUwA3qSqK3fyAaxd1Y5z2LjCo/nDQs9nsxvTmofzPju2t8/378OXD4vLnP2MAJwAABk1JREFUeNrFmwdDFEcUx0eK0kHs3fTMzA1XgDt0jwicGjiOGkCiAQQBuRy20MSCkMTEGDW9l8+au93Da7v7ZuYd5P8F/r+dV2Z2dx4h+SptPHX84JFDhz1SCncGmwAN+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D8KhaA9ir69+T481kkQID2I2ogqYtIAB9NYFIweS5CAvhpBJOCnP+EBKA0iklBzmdwAAFKezApyPlNHICPqlVBtC8fIIYD8FOq8komOvL9+Sc4gDZKH+htxNK7EQFykMYQGSjzcuAKMJAEWNIvwZR+QQGk/kv/hQkA57dQAOa9gEuyR0GbAMA56A5g/hlf19sELD3HAZi/xlf1E4DztSIA0D6lt6EcLTAcgPULaEynBVtaxgGELIBVeD/qtvcfYziAgfRfuHn1DmxpHAkQSAP81qvcAE1JfaqTAaCuHwi65xz84SM5BJC5oHNNNf2lDsQKAENOJ8NEh6P/xVtFBKDD9ucPZ3vJALgDZF8Rm7Vp/qNzLv53WHEBCn7YRvv7XOwlE0AFIGdXTIz2clctsOIDTC6mrD+IJno65jigO2wHAOjK76BxWiq/byWrwNLLz2Tsx56ynQKgk0uw/9VnbOcAki1p3d3+/hXGigYQsL0iNjHmsvrjjO04AKXTCzN27jMLy4wVFWDA8aLg5MTSg7yX0KvjdxkrMkDI9bbmysSr4dvxGzfiC8Mvxp8yXUmcCV3FsJI4Fe8ogBd+MXGXgQQwyFHElW3Va1u2VzqPIS5NK9/bKtQJclKjEWTfHEQCnCVntOvQkhcHcIA0IusQl4XeKlIaxJXBORTASCkhp3FlgMvCWkJITQsqC1FJYNQkAao7cVmISYLB6tSQowfXjBGtyPCYw48l7agkQGThZkl60CmI6YWt2klgpAedSFn4f0kCb0vZ62G3dkwS6MYgM+xGKpxv8zbvWCFmjfulBh67EJ3A0PPPG7ns3N0YbBUOnbbvYgyMQL5/auw3HNytGBj/Fo79moPP7ZoxUNuQjE3bwWdr9NtmrtRX3BgYg06j3+bwY0XD6aBGL5LdD7wjtQ0VdcAEfn3VmZPHjqqdSuCTodfYf+Lsgar6Arv/ADvJ6W7UKxiaAAAAAElFTkSuQmCC")}.yigithub-user-script-js .layout-app .layout-top .left .title{padding:4px;display:flex}.yigithub-user-script-js .layout-app .layout-top .left .title .main-name{height:100%}.yigithub-user-script-js .layout-app .layout-top .left .title .sub-name{display:flex;align-items:flex-end;font-size:12px;padding-bottom:2px;padding-left:6px;color:#cfcfcf;text-shadow:1px 1px 1px #000}.yigithub-user-script-js .layout-app .layout-menu{position:absolute;left:0;top:50px;bottom:30px;width:240px;border-right:1px solid #eee;background-color:#f9f9f9}.yigithub-user-script-js .layout-app .layout-side{position:absolute;top:50px;right:0;bottom:30px;width:200px;border-left:1px solid #eee;background-color:#fcfff2}.yigithub-user-script-js .layout-app .layout-side .title{padding:10px;text-align:center;border-bottom:1px solid #f3f3f3;color:#e33;font-size:15px}.yigithub-user-script-js .layout-app .layout-side .line{height:40px;display:flex;align-items:center;padding:0 10px;cursor:pointer;color:#08f}.yigithub-user-script-js .layout-app .layout-side .line:hover{background-color:#f5f5f5}.yigithub-user-script-js .layout-app .layout-side .line .icon{height:12px;width:12px;background-repeat:no-repeat;background-position:center center;background-size:cover;margin-top:3px;margin-right:4px}.yigithub-user-script-js .layout-app .layout-side .line .text{font-size:14px}.yigithub-user-script-js .layout-app .layout-main{position:absolute;top:50px;right:200px;bottom:30px;left:240px}.yigithub-user-script-js .layout-app .layout-foot{position:absolute;bottom:0;left:0;right:0;height:30px;border-top:1px solid #eee;background-color:#fff0f0}`); document.body.insertAdjacentHTML('beforeend', `
咚咚,敲开网络世界的超级门!
根据当前网站推荐
在线编辑器
油猴文档
`); !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e||self).tinykeys={})}(this,function(e){var t=["Shift","Meta","Alt","Control"],n="object"==typeof navigator&&/Mac|iPod|iPhone|iPad/.test(navigator.platform)?"Meta":"Control";function o(e,t){return"function"==typeof e.getModifierState&&e.getModifierState(t)}function i(e){return e.trim().split(" ").map(function(e){var t=e.split(/\b\+/),o=t.pop();return[t=t.map(function(e){return"$mod"===e?n:e}),o]})}function r(e,n){var r;void 0===n&&(n={});var f=null!=(r=n.timeout)?r:1e3,u=Object.keys(e).map(function(t){return[i(t),e[t]]}),a=new Map,d=null;return function(e){e instanceof KeyboardEvent&&(u.forEach(function(n){var i=n[0],r=n[1],f=a.get(i)||i;!function(e,n){return!(n[1].toUpperCase()!==e.key.toUpperCase()&&n[1]!==e.code||n[0].find(function(t){return!o(e,t)})||t.find(function(t){return!n[0].includes(t)&&n[1]!==t&&o(e,t)}))}(e,f[0])?o(e,e.key)||a.delete(i):f.length>1?a.set(i,f.slice(1)):(a.delete(i),r(e))}),d&&clearTimeout(d),d=setTimeout(a.clear.bind(a),f))}}e.createKeybindingsHandler=r,e.default=function(e,t,n){var o;void 0===n&&(n={});var i=null!=(o=n.event)?o:"keydown",f=r(t,n);return e.addEventListener(i,f),function(){e.removeEventListener(i,f)}},e.parseKeybinding=i}); "use strict"; var _tinykeys = tinykeys, createKeybindingsHandler = _tinykeys.createKeybindingsHandler; // vue界面和功能区域 var __vm = new Vue({ el: '#yigithub-user-script-js', data: { username: 'chensuiyi', isShow: { dongdong: false } }, mounted: function mounted() { var _this = this; this.$nextTick(function () { var that = _this; var handler = createKeybindingsHandler({ 'd d': function dD() { that.isShow.dongdong = !that.isShow.dongdong; if (that.isShow.dongdong === true) { $('body').css({ overflow: 'hidden' }); } else { $('body').css({ overflow: 'auto' }); } } }); window.addEventListener('keydown', handler); }); }, methods: { // 在vscode.dev打开当前项目 openInVscodeDev: function openInVscodeDev() { // https://vscode.dev/https://github.com/yicode-team/yiapi console.dir(window.location); GM_openInTab('https://vscode.dev/' + window.location.href, { active: true }); } } }); } catch (err) { GM_log(err); } })();