您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
百度搜索框背景模糊,去广告,美化
当前为
// ==UserScript== // @name 百度去广告,blur(毛玻璃)搜索框,美化 // @version 20.5.1.5 // @description 百度搜索框背景模糊,去广告,美化 // @author L // @include *://www.baidu.com/ // @include *://www.baidu.com/?tn* // @include *://www.baidu.com/s?* // @include *://www.baidu.com/*wd* // @include *://www.baidu.com/search/* // @include *://baidu.com/ // @include *://baidu.com/s?* // @include *://baidu.com/*wd* // @include *://baidu.com/search/* // @grant none // @namespace L-BaiduBlur // @homepage https://www.ihawo.com // @run-at document-body // ==/UserScript== (function() { function Blur() { var _this = this; this.updata = 1; this.attrNum = 1; this.initStatus = 1; this.right = localStorage.getItem('blur-right'); this.beautify = localStorage.getItem('blur-beautify'); this.tab = localStorage.getItem('blur-tab'); this.browser = myBrowser(); this.css = 0; this.showSetting = 0; this.init = function() { _this.addBaseStyle(); window.onload = function() { if (_this.browser == 'Chrome') { var version = getChromeVersion(); if (version >= 76) { _this.css = 1; } } else if (_this.browser == 'Safari') { _this.css = 1; } _this.addSettingDiv(); _this.initTab(); _this.initBlur(); _this.initShowRight(); _this.initBeautify(); _this.initStatus = 0; } } this.addSettingDiv = function() { $('html').append('<div style="width:210px;height:170px;background:white;position: fixed;z-index: 999999999999999999999;top:15%;left:0;right:0;margin-right: auto;margin-left:auto;box-shadow:0px 0px 10px 2px #ccc;border-radius: 10px;display:none;padding: 10px;" id="bsetting"><div style="font-size:18px;padding: 15px;">blur插件设置</div></div>'); var option = '<span class="c-gap-left" id="showBsetting"><label><span>显示插件设置</span></label></span>'; $(".search_tool_conter").append(option); $("html").on('click', '#showBsetting', function(){ $("#bsetting").fadeIn(300); $("#wrapper").css("filter", 'blur(15px)'); $("#wrapper *").css("pointer-events", 'none'); setTimeout(function(){ _this.showSetting = 1; }, 500) }) $("html").on('click', '#wrapper' ,function(){ if (_this.showSetting) { $("#bsetting").fadeOut(300); $("#wrapper").css("filter", ''); $("#wrapper *").css("pointer-events", 'auto'); _this.showSetting = 0; } }) } this.addBaseStyle = function () { var style = document.createElement('style'); style.type = 'text/css'; style.innerHTML=".result,.c-container,.result div,.c-container div,#t_tab,#head,#u,.s_form,#content_right{transition:all 0.3s ease} #content_right>div{display:none} .wrapper_s .s_ipt_wr,.s_ipt_wr.bg{background:rgba(255,255,255,0.7)}.soutu-btn{background: url(https://ss1.bdstatic.com/5eN1bjq8AAUYm2zgoY3K/r/www/cache/static/protocol/https/soutu/img/camera_new_5606e8f.png) no-repeat;} #s_kw_wrap,#s_top_wrap,#bottom_layer{background:#eee!important}#pageBulrBg{pointer-events:none}"; document.getElementsByTagName('body').item(0).appendChild(style); if (_this.beautify == 1 || _this.beautify == null) { var style = document.createElement('style'); style.type = 'text/css'; style.className = 'mainStyle'; style.innerHTML="document,html,body,.c-table th,#page{background:#eee} #page .fk,a .fk,.qrcodeCon{display:none} #s_tab{height:47px} .result:hover,.c-container:hover,.result-op:hover{box-shadow: 5px 5px 7px #ccc;} .result>div,.c-container>div,.result-op>div{margin:10px 0} .result,.c-container,.result-op{background:#fafafa;padding:20px;border-radius: 5px;box-shadow: 5px 5px 7px #ddd;transition:all 0.3s;margin: 0 15px 25px 0!important;} em{ color: #ce4343;} .result a,.c-container a,.result-op a,.result em,.c-container em,.result-op em,#u a{text-decoration:none!important;} a{color:#4879BD} #rs{background:none;padding:20px} #rs a{text-decoration:none} #page a, #page strong{height:auto;background:none;border:none} #page .pc,#page .n{border: 1px solid #eee;} #s_tab{background:none} .c-border{border: none; box-shadow: none;} #foot,#help{background:none}#u{margin-top:30px} #s_tab{padding-top:86px } .c-border{padding:0;background:none}.result-op>tbody>tr>td{padding:20px!important}@media screen and (max-width: 1216px){.result,.c-container,.result-op,.result-op>tbody>tr>td{padding:15px;}}"; if (document.URL.indexOf('wd=') != -1) { style.innerHTML="document,html,body,.c-table th,#page{background:#eee} #page .fk,a .fk,.qrcodeCon{display:none} #s_tab{height:47px} .result:hover,.c-container:hover,.result-op:hover{box-shadow: 5px 5px 7px #ccc;} .result>div,.c-container>div,.result-op>div{margin:10px 0} .result,.c-container,.result-op{background:#fafafa;padding:20px;border-radius: 5px;box-shadow: 5px 5px 7px #ddd;transition:all 0.3s;margin: 0 15px 25px 0!important;} em{ color: #ce4343;} .result a,.c-container a,.result-op a,.result em,.c-container em,.result-op em,#u a{text-decoration:none!important;} a{color:#4879BD} #rs{background:none;padding:20px} #rs a{text-decoration:none} #page a, #page strong{height:auto;background:none;border:none} #page .pc,#page .n{border: 1px solid #eee;} #s_tab{background:none} .c-border{border: none; box-shadow: none;} #foot,#help{background:none}#u{margin-top:30px} #s_tab{padding-top:86px }body,#head{background:#eee}#head{height: 86px;top:0} .c-border{padding:0;background:none}.result-op>tbody>tr>td{padding:20px!important}@media screen and (max-width: 1216px){.result,.c-container,.result-op>tbody>tr>td{padding:15px;}}"; } document.getElementsByTagName('body').item(0).appendChild(style); } } this.initShowRight = function () { if (_this.right == undefined || _this.right == null) { _this.right = 1; localStorage.setItem('blur-right', 1); } _this.isShowRight(); $(function () { _this.addShowRightTool(); }) } this.initBeautify = function () { if (_this.beautify == undefined || _this.beautify == null || _this.beautify == 1) { _this.beautify = 1; localStorage.setItem('blur-beautify', 1); } _this.doBeautify(); $(function () { _this.addBeautifyTool(); _this.doBeautify(); $(".head_wrapper").on('DOMNodeInserted', function(e) { if (e.target.id == 'ent_sug') { setTimeout(function() { _this.doBeautify(); }, 100) } }) $(document).ajaxSuccess(function(e,xhr,opt) { var url = opt.url; if (url.indexOf('submit/setuskin') != -1) { _this.doBeautify(); } }); $('#kw').on('change', function() { if ($('.s-skin-container').length > 0) { setTimeout(function() { _this.doBeautify() },50) } }) }) } this.initBlur = function () { if (_this.css) { $(function(){ _this.blur(); }) } else { $('html').append('<style></style>'); $(function () { $(window).scroll(function() { var top = $(window).scrollTop(); $("#headerBulrBg").css('top', -top + "px"); }); $(document).ajaxSend(function(e,xhr,opt){ var url = opt.url; if (url.indexOf('/s?') != -1 && (url.indexOf('&wd=') != -1 || url.indexOf('?wd=') != -1) && url.indexOf('&_ck=') == -1) { $(".headBgDiv").remove(); } }); _this.blur(); }) } $(function(){ $(document).ajaxSuccess(function(e,xhr,opt) { var url = opt.url; if (url.indexOf('/s?') != -1 && (url.indexOf('&wd=') != -1 || url.indexOf('?wd=') != -1) && url.indexOf('&_ck=') == -1) { setTimeout(function(){ _this.addSettingDiv(); _this.addShowRightTool(); _this.addBeautifyTool(); _this.addTabTool(); _this.doBeautify(); setTimeout(function(){ _this.removeAd(); }, 2300) _this.removeAd(); _this.blur(); }, 100) } }); $("#wrapper_wrapper").on('DOMNodeInserted', function(e) { if (e.target.id == "container" && e.target.class == undefined) { setTimeout(function(){ _this.addShowRightTool(); _this.addBeautifyTool(); _this.doBeautify(); _this.removeAd(); _this.blur(); }, 100) } }) }) } this.initTab = function () { if (_this.tab == undefined || _this.tab == null || _this.tab == 1) { _this.tab = 1; localStorage.setItem('blur-tab', 1); } _this.setTab(); $(function () { _this.addTabTool(); }) } this.addShowRightTool = function () { if($('.blur-right').length == 0){ var checked = 'checked'; if (_this.right == 0) { checked = ''; } var option = '<div class="c-gap-left" style="font-size:14px;padding: 5px 0;"><label><input type="checkbox" class="blur-right" style="margin-top:3px;vertical-align:middle; " ' + checked + ' ><span style="vertical-align:middle;cursor: pointer;">显示右侧</span></label></div>'; $("#bsetting").append(option); setTimeout(function(){ $(".blur-right").change(_this.toggleRight); },50) } } this.isShowRight = function () { if (_this.right == 0) { $('html').append("<style class='bright'>#content_right{opacity:0} </style>"); setTimeout(function() { if (_this.right == 0) { $(".bright").text('#content_right{display:none}'); } }, 500) } else { $(".bright").text('#content_right{opacity:0}') setTimeout(function() { if (_this.right == 1) { $(".bright").text('#content_right{opacity:1}'); } }, 100) setTimeout(function() { if (_this.right == 1) { $(".bright").remove(); } }, 500) } _this.setTab() } this.toggleRight = function () { if(this.checked){ _this.right = 1; localStorage.setItem('blur-right', 1); } else{ _this.right = 0; localStorage.setItem('blur-right', 0); } _this.isShowRight(); } this.beautifyLogo = function () { if(_this.isNotHaveBackGround()) { if (_this.beautify != 0) { $("#lg img,#result_logo img").attr('src','data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjIuMSwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHZlcnNpb249IjEuMSIgaWQ9IuWbvuWxgl8xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4PSIwcHgiIHk9IjBweCIKCSB2aWV3Qm94PSIwIDAgMTAxIDMzIiBzdHlsZT0iZW5hYmxlLWJhY2tncm91bmQ6bmV3IDAgMCAxMDEgMzM7IiB4bWw6c3BhY2U9InByZXNlcnZlIj4KPHN0eWxlIHR5cGU9InRleHQvY3NzIj4KCS5zdDB7ZmlsbDojNDg3OUJEO30KCS5zdDF7ZmlsbDojREQ0NDM2O30KCS5zdDJ7ZmlsbDojRkZGRkZGO30KPC9zdHlsZT4KPHBhdGggY2xhc3M9InN0MCIgZD0iTTUwLjQsMTUuM2MtMy44LDAuMy00LDIuNi01LjcsNC43Yy0xLjgsMi4yLTUuNSw0LjEtNiw2LjdjLTAuNiwzLjMsMS4zLDUuMSwzLDUuN2MxLjksMC42LDYuMi0wLjUsOC40LTAuNWgw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43Yy0xLjEsMC4xLTEuNywwLjktMS44LDIuMlYyNWMwLjEsMi4xLTAuNCw0LjQtMS4xLDYuN2wxLjksMC42CglDODcuOSwyOS45LDg4LjMsMjcuNiw4OC4zLDI1LjJ6Ii8+CjxwYXRoIGNsYXNzPSJzdDIiIGQ9Ik00Ni4zLDI0LjJjMC42LDAsMS4yLDAuMSwxLjcsMC40djMuNGMwLDAuMy0wLjYsMS0xLjksMWMtMS41LDAtMS44LTAuNi0xLjgtMi4xdi0wLjYKCUM0NC4yLDI0LjgsNDQuNywyNC4yLDQ2LjMsMjQuMnogTTQ5LjIsMjAuN0g0OHYyLjVDNDcuNiwyMy4xLDQ3LDIzLDQ2LjMsMjNjLTIuNywwLTMuMywxLTMuMywzLjV2MC4zYzAsMi40LDAuOSwzLjMsMy4yLDMuMwoJYzAuOCwwLDEuMy0wLjEsMS44LTAuNWwwLjEsMC42aDEuMUw0OS4yLDIwLjdMNDkuMiwyMC43eiIvPgo8cGF0aCBjbGFzcz0ic3QyIiBkPSJNNTYuNywyM2gtMS4ydjUuMmMtMC42LDAuNC0xLjcsMC42LTIuNCwwLjZjLTAuOCwwLTEtMC40LTEtMS4zdi00LjZoLTEuMXY0LjhjMCwxLjYsMC41LDIuMywyLjEsMi4zCgljMSwwLDIuMS0wLjMsMi42LTAuNmwwLjEsMC42aDEuMVYyM3oiLz4KPHBhdGggY2xhc3M9InN0MSIgZD0iTTkyLjcsMTUuN2MwLTAuNywwLjYtMS4zLDEuMi0xLjNjMC42LDAsMS4yLDAuNiwxLjIsMS4zUzk0LjUsMTcsOTMuOSwxN0M5My4zLDE2LjksOTIuNywxNi4zLDkyLjcsMTUuN3oiLz4KPC9zdmc+Cg=='); } else { $("#lg img,#result_logo img").attr('src','//www.baidu.com/img/bd_logo1.png?where=super'); } } } this.addBeautifyTool = function() { var checked = 'checked'; if (_this.beautify == 0) { checked = ''; } if($('.blur-beautify').length == 0){ var option = '<div class="c-gap-left" style="font-size:14px;padding: 5px 0;"><label><input type="checkbox" class="blur-beautify" style="margin-top:3px;vertical-align:middle;" ' + checked + ' ><span style="vertical-align:middle;cursor: pointer;">美化</span></label></div>'; $("#bsetting").append(option); setTimeout(function(){ $(".blur-beautify").change(_this.toggleBeautify); },50) } } this.toggleBeautify = function () { if(this.checked){ _this.beautify = 1; localStorage.setItem('blur-beautify', 1); } else{ _this.beautify = 0; localStorage.setItem('blur-beautify', 0); } _this.doBeautify(); } this.doBeautify = function() { $(".headBgDiv").remove(); if (_this.beautify == 1 || _this.beautify == null) { _this.beautifyLogo(); $(function(){ _this.beautifyLogo(); }) var style = "<style class='mainStyle'>document,html,body,.c-table th,#page{background:#eee} #page .fk,a .fk,.qrcodeCon{display:none} #s_tab{height:47px} .result:hover,.c-container:hover,.result-op:hover{box-shadow: 5px 5px 7px #ccc;} .result>div,.c-container>div,.result-op>div{margin:10px 0} .result,.c-container,.result-op{background:#fafafa;padding:20px;border-radius: 5px;box-shadow: 5px 5px 7px #ddd;transition:all 0.3s;margin: 0 15px 25px 0!important;} em{color: #ce4343;} .result a,.c-container a,.result-op a,.result em,.c-container em,.result-op em,#u a{text-decoration:none!important;} a{color:#4879BD} #rs{background:none;padding:20px} #rs a{text-decoration:none} #page a, #page strong{height:auto;background:none;border:none} #page .pc,#page .n{border: 1px solid #eee;} #s_tab{background:none} .c-border{border: none; box-shadow: none;} #foot,#help{background:none}#u{margin-top:30px} #s_tab{padding-top:86px } .c-border{padding:0;background:none}.result-op>tbody>tr>td{padding:20px!important}@media screen and (max-width: 1216px){.result,.c-container,.result-op,.result-op>tbody>tr>td{padding:15px;!important}}"; if(_this.isNotHaveBackGround() && (_this.initStatus == 0 || document.URL.indexOf('wd=') != -1 || document.URL.indexOf('word=') != -1)) { style += 'body,#head{background:#eee} .s_form{padding-top: 15px}#s_kw_wrap,#s_top_wrap,#bottom_layer{background:none!important}' } if ((!$("#u_sp").length || $("#u_sp").is(':hidden')) && (!$("#u1").length || $("#u1").is(':hidden'))) { style += '#head{height: 86px;top:0}' } style += '</style>'; $(".mainStyle").remove(); $("html").append(style); } else { $(".mainStyle").remove(); } setTimeout(function () { _this.setTab() _this.blur() },350) } this.isNotHaveBackGround = function() { return ($('.s-skin-container').length == 0 || $('.s-skin-container').attr('style') == null || $('.s-skin-container').attr('style').indexOf('background-image') == -1); } this.removeAd = function () { if ($('.tab-wrapper b').text() != '资讯') { $('#content_left>div:not(.c-container):not(#super_se_tip):not(.video_list_container):not(.result)').remove(); } $(".c-container>.f13").each(function(){ var text = $(this).text(); if (text.indexOf('广告') != -1) { $(this).parents('.c-container').remove(); } }) $("#ecomScript").remove(); $('#content_right>div').remove(); $("#con-ar").next().remove(); $(".t>a").unbind('click').click(function(){ window.open($(this).attr('href')); return false; }) } this.blur = function () { if (_this.css){ if (_this.isNotHaveBackGround() && ((!$("#u_sp").length || $("#u_sp").is(':hidden')) && (!$("#u1").length || $("#u1").is(':hidden')))) { $('#head').css({'backdrop-filter': 'blur(15px)'}); if (_this.tab && _this.beautify) { $('#page').css({'backdrop-filter': 'blur(15px)','background': 'rgba(0, 0, 0, 0)'}) } } setTimeout(function(){ $('#head').css({'background': 'rgba(0,0,0,0)'}); }, 1000) $("#s_kw_wrap").css({'background': 'rgba(255,255,255,0.8)'}); } else { var top = -$(window).scrollTop(); var subHeight = $('#head').outerHeight(); var headBgDiv = '<div style="height:'+subHeight+'px;width:100%;overflow:hidden;position: absolute;top:0;z-index:-1;display: inline-block;left:0" id="headBgDiv" class="headBgDiv"><div style="position: absolute;top: '+top+'px;left: 0;width:100%;filter: blur(13px);z-index: -1" class="bulrBg" id="headerBulrBg"></div>'; if (_this.isNotHaveBackGround() && ((!$("#u_sp").length || $("#u_sp").is(':hidden')) && (!$("#u1").length || $("#u1").is(':hidden')))) { $(".headBgDiv").remove(); $('#head').prepend(headBgDiv); } else { $(".headBgDiv").remove(); } $('#wrapper_wrapper #container').addClass('container_l'); _this.removeAd(); $(".bulrBg").append($('#s_tab').clone()); $(".bulrBg").append($('#wrapper_wrapper').clone()); $(".headBgDiv #c-tips-container").remove(); } } this.addTabTool = function() { var checked = 'checked'; if (_this.tab == 0) { checked = ''; } if($('.blur-tab').length == 0){ var option = '<div class="c-gap-left" style="font-size:14px;padding: 5px 0;"><label><input type="checkbox" class="blur-tab" style="margin-top:3px;vertical-align:middle;" ' + checked + ' ><span style="vertical-align:middle;cursor: pointer;">平板模式(只对大屏幕有效)</span></label></div>'; $("#bsetting").append(option); setTimeout(function(){ $(".blur-tab").change(_this.toggleTab); },50) } } this.toggleTab = function () { if(this.checked){ _this.tab = 1; localStorage.setItem('blur-tab', 1); } else{ _this.tab = 0; localStorage.setItem('blur-tab', 0); } _this.setTab(); } this.setTab = function () { $("#bTab").remove(); if ($('.s_tab_inner b').text() == '视频') { return; } if (_this.tab == 1) { var column = _this.right == 1 ? 2 : 3; if ($('.tab-wrapper b').text() == '资讯') { column = 3; } var style = '<style id="bTab">@media screen and (min-width: 1216px){#content_left,#rs_top_new{width:1215px;}.cr-offset{padding-left: 35px;}'; if (column == 3) { var style = '<style id="bTab">@media screen and (min-width: 1216px){.result, .c-container{padding:15px}#content_left,#rs_top_new{width:1750px;}'; } if (_this.beautify == 1) { style += 'html{padding-bottom:50px}#page{position: fixed;bottom: 0;width: 100%;padding: 15px 0;text-align: center;margin: 0;}html #page .pc, #page .n{border-color:rgba(200,200,200,0.55);}#page a{ color: rgba(100,100,100,0.95);}#page strong{background: rgba(51,136,255,0.7)!important;color: white;}'; } style += '#container{width:1775px}#content_left{column-count: ' + column + ';column-width:570px}.result,.c-container{-moz-page-break-inside:avoid;-webkit-column-break-inside:avoid;break-inside:avoid;margin:15px}}</style>'; $('html').append(style); } } } Blur = new Blur,Blur.init(); function myBrowser(){ var userAgent = navigator.userAgent; //取得浏览器的userAgent字符串 var isOpera = userAgent.indexOf("Opera") > -1; if (isOpera) { return "Opera" }; //判断是否Opera浏览器 if (userAgent.indexOf("Firefox") > -1) { return "FF"; } //判断是否Firefox浏览器 if (userAgent.indexOf("Chrome") > -1){ return "Chrome"; } if (userAgent.indexOf("Safari") > -1) { return "Safari"; } //判断是否Safari浏览器 if (userAgent.indexOf("compatible") > -1 && userAgent.indexOf("MSIE") > -1 && !isOpera) { return "IE"; }; //判断是否IE浏览器 } function getChromeVersion() { var arr = navigator.userAgent.split(' '); var chromeVersion = ''; for(var i=0;i < arr.length;i++){ if(/chrome/i.test(arr[i])) chromeVersion = arr[i] } if(chromeVersion){ return Number(chromeVersion.split('/')[1].split('.')[0]); } else { return false; } } })();
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址