// ==UserScript== // @name 微信编辑器VIP爆破 // @namespace http://tampermonkey.net/ // @version 1.0 // @description 无视微信编辑器VIP限制,可以使用VIP模板 // @author Yim @ yeminch@qq.com // @match *://*.135editor.com // @match *://bj.96weixin.com // @match *://www.wxeditor.com // @match *://www.zhubian.com // @run-at document-end // @grant unsafeWindow // @require https://cdn.jsdelivr.net/npm/jquery@1.11.3/dist/jquery.min.js // @downloadURL none // ==/UserScript== (function() { 'use strict'; // Your code here... let setting={ item:null, }; var lists=[]; function init(){ var host = window.location.host; console.log('Hack=>'+host); if(host.search(/www.135editor.com/)>=0) init135(); if(host.search(/bj.96weixin.com/)>=0) init96(); if(host.search(/www.wxeditor.com/)>=0) initYD(); if(host.search(/www.zhubian.com/)>=0) initZB(); } function addStyle(cssText) { let a = document.createElement('style'); a.textContent = cssText; let doc = document.head || document.documentElement; doc.appendChild(a); } function init135(){ $('
点我使用
').appendTo('body').on('click',function(){ if(!setting.item) return false; var h=setting.item.find('._135editor').html(); if(h) unsafeWindow.current_editor.execCommand('inserthtml',h); }); $("body").on('mousemove',function(event){ var ele = $(event.target).parents('li.style-item'); var mouseX = event.pageX,mouseY = event.pageY; if(ele.length==0) return false; var y1 = ele.offset().top; var y2 = y1 + ele.height(); var x1 = ele.offset().left; var x2 = x1 + ele.width(); if( mouseX < x1 || mouseX > x2 || mouseY < y1 || mouseY > y2){ $('.ym_wx_plus_btn').hide(); setting.item=null; }else{ $('.ym_wx_plus_btn').css('left',(x2-120)+'px').css('top',(y1)+'px').show(); setting.item=ele; } }); } function init96(){ setInterval(function(){ $('.rich_media_content').attr('data-vip',1); },2000); } function initYD(){ setInterval(function(){ $('.yead_editor').attr('data-use',1); },2000); } function initZB(){ setInterval(function(){ $('.rich_media_content').attr('data-vip',1); },2000); } addStyle(` .ym_wx_plus_btn{position:absolute;display:none;left:0;top:0;cursor:pointer;width:120px;height:30px;line-height:30px;background:#f00;color:#fff;text-align:center;} `); init(); })();