您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
try to take over the world!
// ==UserScript== // @name Zendesk Events - Highlight tag changes // @namespace http://tampermonkey.net/ // @version 0.2 // @description try to take over the world! // @author Tal Admon ([email protected]) // @match https://*.zendesk.com/agent/tickets/*/events // @grant none // ==/UserScript== (function() { 'use strict'; // this.$ = this.jQuery = jQuery.noConflict(true); window.addEventListener('load', function() { jQuery('.audit-events .Change .info').each(function(){ var _type = jQuery(this).find('label').text().trim() if (_type == 'Tags') { var _hl = jQuery(this).find('label').html(); var _ht = jQuery(this).clone().children().remove().end().html(); var _hd = jQuery(this).find('del').html(); var _hv = jQuery(this).find('div.via').html(); var _v = jQuery(this).clone().children().remove().end().text().trim().split(' ') _v = _v.filter(function(e){return e!=''}); //console.log(_v); var _d = jQuery(this).find('del').text().trim().split(' '); //console.log(_d); var _added = _v.filter(function(e){ return !_d.includes(e) }); var _deleted = _d.filter(function(e){ return !_v.includes(e) }); //console.log(_added); _added.forEach(function(e){ _ht = _ht.replace(e,'<b style="color:green;">'+e+'</b>') //console.log(e); }) _deleted.forEach(function(e){ _hd = _hd.replace(e,'<b style="color:red;">'+e+'</b>') //console.log(e); }) console.log(_hl); jQuery(this).html('<label>'+_hl+'</label>'+_ht+'<del>'+_hd+'</del><div class="via">'+_hv+'</div>'); } }) }, false); })();
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址