mirror of
https://github.com/the1812/Bilibili-Evolved.git
synced 2025-11-04 21:22:45 +08:00
1 line
604 B
JavaScript
1 line
604 B
JavaScript
(()=>{return(e,t)=>{const r=/(.*?)@(.*)\./;const o=["certify-img1","certify-img2"];function s(e){if(o.includes(e.id)){return}const t=new Observer(e,()=>{const o=e.getAttribute("src");const s=o.match(r);if(s&&s[1]){t.stop();e.setAttribute("src",s[1])}});t.options={childList:false,attributes:true,subtree:false};t.start()}document.querySelectorAll("img").forEach(e=>s(e));Observer.childListSubtree("body",e=>{for(const t of e){for(const e of t.addedNodes){if(e.nodeName.toLowerCase()==="img"){s(e)}e.querySelectorAll&&e.querySelectorAll("img").forEach(e=>s(e))}}});return{export:{imageResolution:s}}}})(); |