8 lines
90 KiB
JavaScript
8 lines
90 KiB
JavaScript
/**
|
|
* Minified by jsDelivr using Terser v5.19.2.
|
|
* Original file: /npm/darkreader@4.9.66/darkreader.js
|
|
*
|
|
* Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files
|
|
*/
|
|
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).DarkReader={})}(this,(function(e){"use strict";var t,r,n,a,o,i,c,u,s,l=function(){return l=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var a in t=arguments[r])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e},l.apply(this,arguments)};function d(e,t,r,n){return new(r||(r=Promise))((function(a,o){function i(e){try{u(n.next(e))}catch(e){o(e)}}function c(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(i,c)}u((n=n.apply(e,t||[])).next())}))}function f(e,t){var r,n,a,o,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return o={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function c(c){return function(u){return function(c){if(r)throw new TypeError("Generator is already executing.");for(;o&&(o=0,c[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&c[0]?n.return:c[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,c[1])).done)return a;switch(n=0,a&&(c=[2&c[0],a.value]),c[0]){case 0:case 1:a=c;break;case 4:return i.label++,{value:c[1],done:!1};case 5:i.label++,n=c[1],c=[0];continue;case 7:c=i.ops.pop(),i.trys.pop();continue;default:if(!(a=i.trys,(a=a.length>0&&a[a.length-1])||6!==c[0]&&2!==c[0])){i=0;continue}if(3===c[0]&&(!a||c[1]>a[0]&&c[1]<a[3])){i.label=c[1];break}if(6===c[0]&&i.label<a[1]){i.label=a[1],a=c;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(c);break}a[2]&&i.ops.pop(),i.trys.pop();continue}c=t.call(e,i)}catch(e){c=[6,e],n=0}finally{r=a=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}([c,u])}}}function h(e){var t="function"==typeof Symbol&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function p(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,a,o=r.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(n=o.next()).done;)i.push(n.value)}catch(e){a={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(a)throw a.error}}return i}function v(e,t,r){if(r||2===arguments.length)for(var n,a=0,o=t.length;a<o;a++)!n&&a in t||(n||(n=Array.prototype.slice.call(t,0,a)),n[a]=t[a]);return e.concat(n||Array.prototype.slice.call(t))}"function"==typeof SuppressedError&&SuppressedError,function(e){e.GET_DATA="ui-bg-get-data",e.GET_DEVTOOLS_DATA="ui-bg-get-devtools-data",e.SUBSCRIBE_TO_CHANGES="ui-bg-subscribe-to-changes",e.UNSUBSCRIBE_FROM_CHANGES="ui-bg-unsubscribe-from-changes",e.CHANGE_SETTINGS="ui-bg-change-settings",e.SET_THEME="ui-bg-set-theme",e.TOGGLE_ACTIVE_TAB="ui-bg-toggle-active-tab",e.MARK_NEWS_AS_READ="ui-bg-mark-news-as-read",e.MARK_NEWS_AS_DISPLAYED="ui-bg-mark-news-as-displayed",e.LOAD_CONFIG="ui-bg-load-config",e.APPLY_DEV_DYNAMIC_THEME_FIXES="ui-bg-apply-dev-dynamic-theme-fixes",e.RESET_DEV_DYNAMIC_THEME_FIXES="ui-bg-reset-dev-dynamic-theme-fixes",e.APPLY_DEV_INVERSION_FIXES="ui-bg-apply-dev-inversion-fixes",e.RESET_DEV_INVERSION_FIXES="ui-bg-reset-dev-inversion-fixes",e.APPLY_DEV_STATIC_THEMES="ui-bg-apply-dev-static-themes",e.RESET_DEV_STATIC_THEMES="ui-bg-reset-dev-static-themes",e.COLOR_SCHEME_CHANGE="ui-bg-color-scheme-change",e.HIDE_HIGHLIGHTS="ui-bg-hide-highlights"}(t||(t={})),function(e){e.CHANGES="bg-ui-changes"}(r||(r={})),function(e){e.CSS_UPDATE="debug-bg-ui-css-update",e.UPDATE="debug-bg-ui-update"}(n||(n={})),function(e){e.ADD_CSS_FILTER="bg-cs-add-css-filter",e.ADD_DYNAMIC_THEME="bg-cs-add-dynamic-theme",e.ADD_STATIC_THEME="bg-cs-add-static-theme",e.ADD_SVG_FILTER="bg-cs-add-svg-filter",e.CLEAN_UP="bg-cs-clean-up",e.FETCH_RESPONSE="bg-cs-fetch-response",e.UNSUPPORTED_SENDER="bg-cs-unsupported-sender"}(a||(a={})),function(e){e.RELOAD="debug-bg-cs-reload"}(o||(o={})),function(e){e.COLOR_SCHEME_CHANGE="cs-bg-color-scheme-change",e.DARK_THEME_DETECTED="cs-bg-dark-theme-detected",e.DARK_THEME_NOT_DETECTED="cs-bg-dark-theme-not-detected",e.FETCH="cs-bg-fetch",e.DOCUMENT_CONNECT="cs-bg-document-connect",e.DOCUMENT_FORGET="cs-bg-document-forget",e.DOCUMENT_FREEZE="cs-bg-document-freeze",e.DOCUMENT_RESUME="cs-bg-document-resume"}(i||(i={})),function(e){e.LOG="debug-cs-bg-log"}(c||(c={})),function(e){e.EXPORT_CSS_RESPONSE="cs-ui-export-css-response"}(u||(u={})),function(e){e.EXPORT_CSS="ui-cs-export-css"}(s||(s={}));var m="undefined"!=typeof navigator,g=m?navigator.userAgentData&&Array.isArray(navigator.userAgentData.brands)?navigator.userAgentData.brands.map((function(e){return"".concat(e.brand.toLowerCase()," ").concat(e.version)})).join(" "):navigator.userAgent.toLowerCase():"some useragent",b=m?navigator.userAgentData&&"string"==typeof navigator.userAgentData.platform?navigator.userAgentData.platform.toLowerCase():navigator.platform.toLowerCase():"some platform",y=g.includes("chrome")||g.includes("chromium"),S=g.includes("firefox")||g.includes("thunderbird")||g.includes("librewolf"),w=g.includes("safari")&&!y,k=b.startsWith("win"),_=b.startsWith("mac");m&&navigator.userAgentData?navigator.userAgentData.mobile:g.includes("mobile");var E,C="function"==typeof ShadowRoot,x="function"==typeof MediaQueryList&&"function"==typeof MediaQueryList.prototype.addEventListener;(E=g.match(/chrom(?:e|ium)(?:\/| )([^ ]+)/))&&E[1]&&E[1],function(){var e=g.match(/(?:firefox|librewolf)(?:\/| )([^ ]+)/);e&&e[1]&&e[1]}();var T=function(){try{return document.querySelector(":defined"),!0}catch(e){return!1}}(),R=function(){try{if("undefined"==typeof document)return!1;var e=document.createElement("div");return!(!e||"object"!=typeof e.style)&&("string"==typeof e.style.colorScheme||(e.setAttribute("style","color-scheme: dark"),"dark"===e.style.colorScheme))}catch(e){return!1}}();function V(e,t,r){return d(this,void 0,void 0,(function(){var n;return f(this,(function(a){switch(a.label){case 0:return[4,fetch(e,{cache:"force-cache",credentials:"omit",referrer:r})];case 1:if(n=a.sent(),S&&"text/css"===t&&e.startsWith("moz-extension://")&&e.endsWith(".css"))return[2,n];if(t&&!n.headers.get("Content-Type").startsWith(t))throw new Error("Mime type mismatch when loading ".concat(e));if(!n.ok)throw new Error("Unable to load ".concat(e," ").concat(n.status," ").concat(n.statusText));return[2,n]}}))}))}function M(e,t){return d(this,void 0,void 0,(function(){return f(this,(function(r){switch(r.label){case 0:return[4,V(e,t)];case 1:return[4,A(r.sent())];case 2:return[2,r.sent()]}}))}))}function A(e){return d(this,void 0,void 0,(function(){var t;return f(this,(function(r){switch(r.label){case 0:return[4,e.blob()];case 1:return t=r.sent(),[4,new Promise((function(e){var r=new FileReader;r.onloadend=function(){return e(r.result)},r.readAsDataURL(t)}))];case 2:return[2,r.sent()]}}))}))}var L=function(e){return d(void 0,void 0,void 0,(function(){return f(this,(function(t){return[2,Promise.reject(new Error(["Embedded Dark Reader cannot access a cross-origin resource",e,"Overview your URLs and CORS policies or use","`DarkReader.setFetchMethod(fetch: (url) => Promise<Response>))`.","See if using `DarkReader.setFetchMethod(window.fetch)`","before `DarkReader.enable()` works."].join(" ")))]}))}))},O=L;function D(e){return d(this,void 0,void 0,(function(){return f(this,(function(t){switch(t.label){case 0:return[4,O(e)];case 1:return[2,t.sent()]}}))}))}window.chrome||(window.chrome={}),chrome.runtime||(chrome.runtime={});var P,N,j=new Set;function F(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return d(this,void 0,void 0,(function(){var t,r,n,o,c,u,s;return f(this,(function(l){switch(l.label){case 0:if(!e[0]||e[0].type!==i.FETCH)return[3,8];t=e[0].id,l.label=1;case 1:return l.trys.push([1,7,,8]),r=e[0].data,n=r.url,o=r.responseType,[4,D(n)];case 2:return c=l.sent(),"data-url"!==o?[3,4]:[4,A(c)];case 3:return u=l.sent(),[3,6];case 4:return[4,c.text()];case 5:u=l.sent(),l.label=6;case 6:return j.forEach((function(e){return e({type:a.FETCH_RESPONSE,data:u,error:null,id:t})})),[3,8];case 7:return s=l.sent(),console.error(s),j.forEach((function(e){return e({type:a.FETCH_RESPONSE,data:null,error:s,id:t})})),[3,8];case 8:return[2]}}))}))}function I(e){j.add(e)}if("function"==typeof chrome.runtime.sendMessage){var B=chrome.runtime.sendMessage;chrome.runtime.sendMessage=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];F.apply(void 0,v([],p(e),!1)),B.apply(chrome.runtime,e)}}else chrome.runtime.sendMessage=F;if(chrome.runtime.onMessage||(chrome.runtime.onMessage={}),"function"==typeof chrome.runtime.onMessage.addListener){var q=chrome.runtime.onMessage.addListener;chrome.runtime.onMessage.addListener=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];I(e[0]),q.apply(chrome.runtime.onMessage,e)}}else chrome.runtime.onMessage.addListener=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return I(e[0])};!function(e){e.cssFilter="cssFilter",e.svgFilter="svgFilter",e.staticTheme="staticTheme",e.dynamicTheme="dynamicTheme"}(P||(P={})),function(e){e.NONE="",e.TIME="time",e.SYSTEM="system",e.LOCATION="location"}(N||(N={}));var W={background:"#181a1b",text:"#e8e6e3"},H={background:"#dcdad7",text:"#181a1b"},U={mode:1,brightness:100,contrast:100,grayscale:0,sepia:0,useFont:!1,fontFamily:_?"Helvetica Neue":k?"Segoe UI":"Open Sans",textStroke:0,engine:P.dynamicTheme,stylesheet:"",darkSchemeBackgroundColor:W.background,darkSchemeTextColor:W.text,lightSchemeBackgroundColor:H.background,lightSchemeTextColor:H.text,scrollbarColor:_?"":"auto",selectionColor:"auto",styleSystemControls:!R,lightColorScheme:"Default",darkColorScheme:"Default",immediateModify:!1};function G(e,t){var r,n;if(function(e){return null!=e.length}(e))for(var a=0,o=e.length;a<o;a++)t(e[a]);else try{for(var i=h(e),c=i.next();!c.done;c=i.next()){t(c.value)}}catch(e){r={error:e}}finally{try{c&&!c.done&&(n=i.return)&&n.call(i)}finally{if(r)throw r.error}}}function $(e,t){G(t,(function(t){return e.push(t)}))}function z(e){var t,r=!1,n=null;return Object.assign((function(){for(var a=[],o=0;o<arguments.length;o++)a[o]=arguments[o];t=a,n?r=!0:(e.apply(void 0,v([],p(t),!1)),n=requestAnimationFrame((function(){n=null,r&&(e.apply(void 0,v([],p(t),!1)),r=!1)})))}),{cancel:function(){cancelAnimationFrame(n),r=!1,n=null}})}function Q(e){var t=0;return e.seconds&&(t+=1e3*e.seconds),e.minutes&&(t+=60*e.minutes*1e3),e.hours&&(t+=60*e.hours*60*1e3),e.days&&(t+=24*e.days*60*60*1e3),t}function K(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function Y(e,t,r){void 0===r&&(r=Function.prototype);var n=Q({seconds:2}),a=Q({seconds:10}),o=e.previousSibling,i=e.parentNode;if(!i)throw new Error("Unable to watch for node position: parent element not found");if("prev-sibling"===t&&!o)throw new Error("Unable to watch for node position: there is no previous sibling");var c=0,u=null,s=null,l=z((function(){if(!s){c++;var f=Date.now();if(null==u)u=f;else if(c>=10){if(f-u<a)return void(s=setTimeout((function(){u=null,c=0,s=null,l()}),n));u=f,c=1}if("head"===t&&o&&o.parentNode!==i)h();else{if("prev-sibling"===t){if(null==o.parentNode)return void h();o.parentNode!==i&&p(o.parentNode)}"head"!==t||i.isConnected||(i=document.head),i.insertBefore(e,o&&o.isConnected?o.nextSibling:i.firstChild),d.takeRecords(),r&&r()}}})),d=new MutationObserver((function(){("head"===t&&(e.parentNode!==i||!e.parentNode.isConnected)||"prev-sibling"===t&&e.previousSibling!==o)&&l()})),f=function(){d.observe(i,{childList:!0})},h=function(){clearTimeout(s),d.disconnect(),l.cancel()},p=function(e){i=e,h(),f()};return f(),{run:f,stop:h,skip:function(){d.takeRecords()}}}function X(e,t){if(null!=e)for(var r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:function(e){return null==e.shadowRoot?NodeFilter.FILTER_SKIP:NodeFilter.FILTER_ACCEPT}}),n=e.shadowRoot?r.currentNode:r.nextNode();null!=n;n=r.nextNode())n.classList.contains("surfingkeys_hints_host")||(t(n),X(n.shadowRoot,t))}N.NONE;var Z=function(){return"complete"===document.readyState||"interactive"===document.readyState};var J=new Set;function ee(e){Z()?e():J.add(e)}function te(e){J.delete(e)}function re(){return"complete"===document.readyState}var ne=new Set;function ae(e){re()?e():ne.add(e)}if(!Z()){var oe=function(){Z()&&(J.forEach((function(e){return e()})),J.clear(),re()&&(document.removeEventListener("readystatechange",oe),ne.forEach((function(e){return e()})),ne.clear()))};document.addEventListener("readystatechange",oe)}var ie=1e3;var ce,ue=new Map,se=new WeakMap;function le(e,t){var r,n,a;if(ue.has(e))r=ue.get(e),n=se.get(r);else{var o=!1,i=!1;r=new MutationObserver((function(t){if(function(e){if(e.length>ie)return!0;for(var t=0,r=0;r<e.length;r++)if((t+=e[r].addedNodes.length)>ie)return!0;return!1}(t))!o||Z()?n.forEach((function(t){return(0,t.onHugeMutations)(e)})):i||(ee(a=function(){return n.forEach((function(t){return(0,t.onHugeMutations)(e)}))}),i=!0),o=!0;else{var r=function(e){var t=new Set,r=new Set,n=new Set;e.forEach((function(e){G(e.addedNodes,(function(e){e instanceof Element&&e.isConnected&&t.add(e)})),G(e.removedNodes,(function(e){e instanceof Element&&(e.isConnected?(n.add(e),t.delete(e)):r.add(e))}))}));var a=[],o=[];return t.forEach((function(e){t.has(e.parentElement)&&a.push(e)})),r.forEach((function(e){r.has(e.parentElement)&&o.push(e)})),a.forEach((function(e){return t.delete(e)})),o.forEach((function(e){return r.delete(e)})),{additions:t,moves:n,deletions:r}}(t);n.forEach((function(e){return(0,e.onMinorMutations)(r)}))}})),r.observe(e,{childList:!0,subtree:!0}),ue.set(e,r),n=new Set,se.set(r,n)}return n.add(t),{disconnect:function(){n.delete(t),a&&te(a),0===n.size&&(r.disconnect(),se.delete(r),ue.delete(e))}}}var de=new Map;function fe(e){return ce||(ce=document.createElement("a")),ce.href=e,ce.href}function he(e,t){void 0===t&&(t=null);var r="".concat(e).concat(t?";".concat(t):"");if(de.has(r))return de.get(r);if(t){var n=new URL(e,fe(t));return de.set(r,n),n}var a=new URL(fe(e));return de.set(e,a),a}function pe(e,t){if(t.match(/^data\\?\:/))return t;if(/^\/\//.test(t))return"".concat(location.protocol).concat(t);var r=he(e);return he(t,r.href).href}function ve(e,t,r){G(e,(function(e){if(e.selectorText)t(e);else if(e.href)try{ve(e.styleSheet.cssRules,t,r)}catch(e){r&&r()}else if(e.media){var n=Array.from(e.media),a=n.some((function(e){return e.startsWith("screen")||e.startsWith("all")||e.startsWith("(")})),o=n.some((function(e){return e.startsWith("print")||e.startsWith("speech")}));!a&&o||ve(e.cssRules,t,r)}else e.conditionText&&CSS.supports(e.conditionText)&&ve(e.cssRules,t,r)}))}var me=["background","border","border-color","border-bottom","border-left","border-right","border-top","outline","outline-color"],ge=w?me.map((function(e){return[e,new RegExp("".concat(e,":\\s*(.*?)\\s*;"))]})):null;function be(e,t){G(e,(function(r){var n=e.getPropertyValue(r).trim();n&&t(r,n)}));var r=e.cssText;r.includes("var(")&&(w?ge.forEach((function(e){var n=p(e,2),a=n[0],o=n[1],i=r.match(o);if(i&&i[1]){var c=i[1].trim();t(a,c)}})):me.forEach((function(r){var n=e.getPropertyValue(r);n&&n.includes("var(")&&t(r,n)})))}var ye=/url\((('.*?')|(".*?")|([^\)]*?))\)/g,Se=/@import\s*(url\()?(('.+?')|(".+?")|([^\)]*?))\)? ?(screen)?;?/gi;function we(e){return e.trim().replace(/[\n\r\\]+/g,"").replace(/^url\((.*)\)$/,"$1").trim().replace(/^"(.*)"$/,"$1").replace(/^'(.*)'$/,"$1").replace(/(?:\\(.))/g,"$1")}function ke(e){var t=he(e);return"".concat(t.origin).concat(t.pathname.replace(/\?.*$/,"").replace(/(\/)([^\/]+)$/i,"$1"))}var _e=/\/\*[\s\S]*?\*\//g;var Ee=/@font-face\s*{[^}]*}/g;function Ce(e){for(var t,r=[],n=[],a=0,o=e.length;a<o;a++){var i=e[a];if(i&&" "!==i){if(Te.has(i)){for(var c=Te.get(i);n.length;){var u=Te.get(n[0]);if(!u)break;if(!c.lessOrEqualThan(u))break;r.push(n.shift())}n.unshift(i)}else!t||Te.has(t)?r.push(i):r[r.length-1]+=i;t=i}}r.push.apply(r,v([],p(n),!1));var s=[];for(a=0,o=r.length;a<o;a++){if(c=Te.get(r[a])){var l=s.splice(0,2);s.push(c.exec(l[1],l[0]))}else s.unshift(parseFloat(r[a]))}return s[0]}var xe=function(){function e(e,t){this.precendce=e,this.execMethod=t}return e.prototype.exec=function(e,t){return this.execMethod(e,t)},e.prototype.lessOrEqualThan=function(e){return this.precendce<=e.precendce},e}(),Te=new Map([["+",new xe(1,(function(e,t){return e+t}))],["-",new xe(1,(function(e,t){return e-t}))],["*",new xe(2,(function(e,t){return e*t}))],["/",new xe(2,(function(e,t){return e/t}))]]);function Re(e,t,r){void 0===r&&(r=0);for(var n,a=[];n=e.exec(t);)a.push(n[r]);return a}function Ve(e,t){void 0===t&&(t=0);for(var r=e.length,n=0,a=-1,o=t;o<r;o++)if(0===n){if((i=e.indexOf("(",o))<0)break;a=i,n++,o=i}else{var i,c=e.indexOf(")",o);if(c<0)break;if((i=e.indexOf("(",o))<0||c<i){if(0===--n)return{start:a,end:c+1};o=c}else n++,o=i}return null}var Me=new Map,Ae=new Map;function Le(e){if(e=e.trim(),Ae.has(e))return Ae.get(e);e.includes("calc(")&&(e=function(e){var t=0,r=function(t,r,n){e=e.substring(0,t)+n+e.substring(r)};for(;-1!==(t=e.indexOf("calc("));){var n=Ve(e,t);if(!n)break;var a=e.slice(n.start+1,n.end-1),o=a.includes("%");a=a.split("%").join("");var i=Math.round(Ce(a));r(n.start-4,n.end,i+(o?"%":""))}return e}(e));var t=function(e){var t=e.trim().toLowerCase();if(t.match(Fe))return r=p(qe(t,We,He),4),n=r[0],a=r[1],o=r[2],i=r[3],{r:n,g:a,b:o,a:void 0===i?1:i};var r,n,a,o,i;if(t.match(Ie))return function(e){var t=p(qe(e,Ue,Ge),4),r=t[0],n=t[1],a=t[2],o=t[3],i=void 0===o?1:o;return De({h:r,s:n,l:a,a:i})}(t);if(t.match(Be))return function(e){var t=e.substring(1);switch(t.length){case 3:case 4:var r=p([0,1,2].map((function(e){return parseInt("".concat(t[e]).concat(t[e]),16)})),3);return{r:r[0],g:r[1],b:r[2],a:3===t.length?1:parseInt("".concat(t[3]).concat(t[3]),16)/255};case 6:case 8:var n=p([0,2,4].map((function(e){return parseInt(t.substring(e,e+2),16)})),3);return{r:n[0],g:n[1],b:n[2],a:6===t.length?1:parseInt(t.substring(6,8),16)/255}}return null}(t);if($e.has(t))return function(e){var t=$e.get(e);return{r:t>>16&255,g:t>>8&255,b:t>>0&255,a:1}}(t);if(ze.has(t))return function(e){var t=ze.get(e);return{r:t>>16&255,g:t>>8&255,b:t>>0&255,a:1}}(t);if("transparent"===e)return{r:0,g:0,b:0,a:0};return null}(e);return t&&Ae.set(e,t),t}function Oe(e){if(Me.has(e))return Me.get(e);var t=Le(e);if(!t)return null;var r=Pe(t);return Me.set(e,r),r}function De(e){var t=e.h,r=e.s,n=e.l,a=e.a,o=void 0===a?1:a;if(0===r){var i=p([n,n,n].map((function(e){return Math.round(255*e)})),3),c=i[0],u=i[1];return{r:c,g:i[2],b:u,a:o}}var s=(1-Math.abs(2*n-1))*r,l=s*(1-Math.abs(t/60%2-1)),d=n-s/2,f=p((t<60?[s,l,0]:t<120?[l,s,0]:t<180?[0,s,l]:t<240?[0,l,s]:t<300?[l,0,s]:[s,0,l]).map((function(e){return Math.round(255*(e+d))})),3);return{r:f[0],g:f[1],b:f[2],a:o}}function Pe(e){var t=e.r,r=e.g,n=e.b,a=e.a,o=void 0===a?1:a,i=t/255,c=r/255,u=n/255,s=Math.max(i,c,u),l=Math.min(i,c,u),d=s-l,f=(s+l)/2;if(0===d)return{h:0,s:0,l:f,a:o};var h=60*(s===i?(c-u)/d%6:s===c?(u-i)/d+2:(i-c)/d+4);return h<0&&(h+=360),{h:h,s:d/(1-Math.abs(2*f-1)),l:f,a:o}}function Ne(e,t){void 0===t&&(t=0);var r=e.toFixed(t);if(0===t)return r;var n=r.indexOf(".");if(n>=0){var a=r.match(/0+$/);if(a)return a.index===n+1?r.substring(0,n):r.substring(0,a.index)}return r}function je(e){var t=e.h,r=e.s,n=e.l,a=e.a;return null!=a&&a<1?"hsla(".concat(Ne(t),", ").concat(Ne(100*r),"%, ").concat(Ne(100*n),"%, ").concat(Ne(a,2),")"):"hsl(".concat(Ne(t),", ").concat(Ne(100*r),"%, ").concat(Ne(100*n),"%)")}var Fe=/^rgba?\([^\(\)]+\)$/,Ie=/^hsla?\([^\(\)]+\)$/,Be=/^#[0-9a-f]+$/i;function qe(e,t,r){var n=function(e){var t=[],r=0,n=!1,a=e.indexOf("(");e=e.substring(a+1,e.length-1);for(var o=0;o<e.length;o++){var i=e[o];i>="0"&&i<="9"||"."===i||"+"===i||"-"===i?n=!0:!n||" "!==i&&","!==i&&"/"!==i?n||(r=o+1):(t.push(e.substring(r,o)),n=!1,r=o+1)}return n&&t.push(e.substring(r,e.length)),t}(e),a=Object.entries(r);return n.map((function(e){return e.trim()})).map((function(e,r){var n,o=a.find((function(t){var r=p(t,1)[0];return e.endsWith(r)}));return n=o?parseFloat(e.substring(0,e.length-o[0].length))/o[1]*t[r]:parseFloat(e),t[r]>1?Math.round(n):n}))}var We=[255,255,255,1],He={"%":100};var Ue=[360,1,1,1],Ge={"%":100,deg:360,rad:2*Math.PI,turn:1};var $e=new Map(Object.entries({aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgrey:11119017,darkgreen:25600,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,grey:8421504,green:32768,greenyellow:11403055,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgrey:13882323,lightgreen:9498256,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074})),ze=new Map(Object.entries({ActiveBorder:3906044,ActiveCaption:0,AppWorkspace:11184810,Background:6513614,ButtonFace:16777215,ButtonHighlight:15329769,ButtonShadow:10461343,ButtonText:0,CaptionText:0,GrayText:8355711,Highlight:11720703,HighlightText:0,InactiveBorder:16777215,InactiveCaption:16777215,InactiveCaptionText:0,InfoBackground:16514245,InfoText:0,Menu:16185078,MenuText:16777215,Scrollbar:11184810,ThreeDDarkShadow:0,ThreeDFace:12632256,ThreeDHighlight:16777215,ThreeDLightShadow:16777215,ThreeDShadow:0,Window:15527148,WindowFrame:11184810,WindowText:0,"-webkit-focus-ring-color":15046400}).map((function(e){var t=p(e,2),r=t[0],n=t[1];return[r.toLowerCase(),n]})));function Qe(e,t,r){return(.2126*e+.7152*t+.0722*r)/255}function Ke(e,t,r,n,a){return(e-t)*(a-n)/(r-t)+n}function Ye(e,t,r){return Math.min(r,Math.max(t,e))}function Xe(e,t){for(var r=[],n=0,a=e.length;n<a;n++){r[n]=[];for(var o=0,i=t[0].length;o<i;o++){for(var c=0,u=0,s=e[0].length;u<s;u++)c+=e[n][u]*t[u][o];r[n][o]=c}}return r}function Ze(e){var t=Je.identity();return 0!==e.sepia&&(t=Xe(t,Je.sepia(e.sepia/100))),0!==e.grayscale&&(t=Xe(t,Je.grayscale(e.grayscale/100))),100!==e.contrast&&(t=Xe(t,Je.contrast(e.contrast/100))),100!==e.brightness&&(t=Xe(t,Je.brightness(e.brightness/100))),1===e.mode&&(t=Xe(t,Je.invertNHue())),t}var Je={identity:function(){return[[1,0,0,0,0],[0,1,0,0,0],[0,0,1,0,0],[0,0,0,1,0],[0,0,0,0,1]]},invertNHue:function(){return[[.333,-.667,-.667,0,1],[-.667,.333,-.667,0,1],[-.667,-.667,.333,0,1],[0,0,0,1,0],[0,0,0,0,1]]},brightness:function(e){return[[e,0,0,0,0],[0,e,0,0,0],[0,0,e,0,0],[0,0,0,1,0],[0,0,0,0,1]]},contrast:function(e){var t=(1-e)/2;return[[e,0,0,0,t],[0,e,0,0,t],[0,0,e,0,t],[0,0,0,1,0],[0,0,0,0,1]]},sepia:function(e){return[[.393+.607*(1-e),.769-.769*(1-e),.189-.189*(1-e),0,0],[.349-.349*(1-e),.686+.314*(1-e),.168-.168*(1-e),0,0],[.272-.272*(1-e),.534-.534*(1-e),.131+.869*(1-e),0,0],[0,0,0,1,0],[0,0,0,0,1]]},grayscale:function(e){return[[.2126+.7874*(1-e),.7152-.7152*(1-e),.0722-.0722*(1-e),0,0],[.2126-.2126*(1-e),.7152+.2848*(1-e),.0722-.0722*(1-e),0,0],[.2126-.2126*(1-e),.7152-.7152*(1-e),.0722+.9278*(1-e),0,0],[0,0,0,1,0],[0,0,0,0,1]]}};function et(e){return e[1===e.mode?"darkSchemeBackgroundColor":"lightSchemeBackgroundColor"]}function tt(e){return e[1===e.mode?"darkSchemeTextColor":"lightSchemeTextColor"]}var rt=new Map;var nt=["r","g","b","a"],at=["mode","brightness","contrast","grayscale","sepia","darkSchemeBackgroundColor","darkSchemeTextColor","lightSchemeBackgroundColor","lightSchemeTextColor"];function ot(e,t,r,n,a){var o;rt.has(r)?o=rt.get(r):(o=new Map,rt.set(r,o));var i=function(e,t){var r="";return nt.forEach((function(t){r+="".concat(e[t],";")})),at.forEach((function(e){r+="".concat(t[e],";")})),r}(e,t);if(o.has(i))return o.get(i);var c=De(r(Pe(e),null==n?null:Oe(n),null==a?null:Oe(a))),u=c.r,s=c.g,l=c.b,d=c.a,f=p(function(e,t){var r=p(e,3),n=Xe(t,[[r[0]/255],[r[1]/255],[r[2]/255],[1],[1]]);return[0,1,2].map((function(e){return Ye(Math.round(255*n[e][0]),0,255)}))}([u,s,l],Ze(t)),3),h=f[0],v=f[1],m=f[2],g=1===d?function(e){var t=e.r,r=e.g,n=e.b,a=e.a;return"#".concat((null!=a&&a<1?[t,r,n,Math.round(255*a)]:[t,r,n]).map((function(e){return"".concat(e<16?"0":"").concat(e.toString(16))})).join(""))}({r:h,g:v,b:m}):function(e){var t=e.r,r=e.g,n=e.b,a=e.a;return null!=a&&a<1?"rgba(".concat(Ne(t),", ").concat(Ne(r),", ").concat(Ne(n),", ").concat(Ne(a,2),")"):"rgb(".concat(Ne(t),", ").concat(Ne(r),", ").concat(Ne(n),")")}({r:h,g:v,b:m,a:d});return o.set(i,g),g}function it(e){return e}function ct(e,t){var r=et(t);return ot(e,t,ut,tt(t),r)}function ut(e,t,r){var n,a=e.h,o=e.s,i=e.l,c=e.a,u=i<.5;u?n=i<.2||o<.12:n=o<.24||i>.8&&(a>200&&a<280);var s=a,l=i;return n&&(u?(s=t.h,l=t.s):(s=r.h,l=r.s)),{h:s,s:l,l:Ke(i,0,1,t.l,r.l),a:c}}var st=.4;function lt(e,t){var r=e.h,n=e.s,a=e.l,o=e.a,i=n<.12||a>.8&&(r>200&&r<280);if(a<.5){var c=Ke(a,0,.5,0,st);return i?{h:t.h,s:t.s,l:c,a:o}:{h:r,s:n,l:c,a:o}}var u=Ke(a,.5,1,st,t.l);if(i)return{h:t.h,s:t.s,l:u,a:o};var s=r;r>60&&r<180&&(s=r>120?Ke(r,120,180,135,180):Ke(r,60,120,60,105));return s>40&&s<80&&(u*=.75),{h:s,s:n,l:u,a:o}}function dt(e,t){if(0===t.mode)return ct(e,t);var r=et(t);return ot(e,l(l({},t),{mode:0}),lt,r)}var ft,ht=.55;function pt(e){return Ke(e,205,245,205,220)}function vt(e,t){var r=e.h,n=e.s,a=e.l,o=e.a,i=a<.2||n<.24,c=!i&&r>205&&r<245;if(a>.5){var u=Ke(a,.5,1,ht,t.l);if(i)return{h:t.h,s:t.s,l:u,a:o};var s=r;return c&&(s=pt(r)),{h:s,s:n,l:u,a:o}}if(i)return{h:t.h,s:t.s,l:Ke(a,0,.5,t.l,ht),a:o};var l,d=r;return c?(d=pt(r),l=Ke(a,0,.5,t.l,Math.min(1,ht+.05))):l=Ke(a,0,.5,t.l,ht),{h:d,s:n,l:l,a:o}}function mt(e,t){if(0===t.mode)return ct(e,t);var r=tt(t);return ot(e,l(l({},t),{mode:0}),vt,r)}function gt(e,t,r){var n=e.h,a=e.s,o=e.l,i=e.a,c=n,u=a;return(o<.2||a<.24)&&(o<.5?(c=t.h,u=t.s):(c=r.h,u=r.s)),{h:c,s:u,l:Ke(o,0,1,.5,.2),a:i}}function bt(e,t){if(0===t.mode)return ct(e,t);var r=tt(t),n=et(t);return ot(e,l(l({},t),{mode:0}),gt,r,n)}function yt(e,t){return dt(e,t)}function St(e){var t=[];return e.mode===ft.dark&&t.push("invert(100%) hue-rotate(180deg)"),100!==e.brightness&&t.push("brightness(".concat(e.brightness,"%)")),100!==e.contrast&&t.push("contrast(".concat(e.contrast,"%)")),0!==e.grayscale&&t.push("grayscale(".concat(e.grayscale,"%)")),0!==e.sepia&&t.push("sepia(".concat(e.sepia,"%)")),0===t.length?null:t.join(" ")}function wt(){if("randomUUID"in crypto){var e=crypto.randomUUID();return e.substring(0,8)+e.substring(9,13)+e.substring(14,18)+e.substring(19,23)+e.substring(24)}return"getRandomValues"in crypto?Array.from(crypto.getRandomValues(new Uint8Array(16))).map((function(e){return((t=e)<16?"0":"")+t.toString(16);var t})).join(""):Math.floor(Math.random()*Math.pow(2,55)).toString(36)}!function(e){e[e.light=0]="light",e[e.dark=1]="dark"}(ft||(ft={}));var kt=new Map,_t=new Map;function Et(e){return d(this,void 0,void 0,(function(){return f(this,(function(t){return[2,new Promise((function(t,r){var n=wt();kt.set(n,t),_t.set(n,r),chrome.runtime.sendMessage({type:i.FETCH,data:e,id:n})}))]}))}))}chrome.runtime.onMessage.addListener((function(e){var t=e.type,r=e.data,n=e.error,o=e.id;if(t===a.FETCH_RESPONSE){var i=kt.get(o),c=_t.get(o);kt.delete(o),_t.delete(o),n?c&&c(n):i&&i(r)}}));var Ct=new(function(){function e(){this.queue=[],this.timerId=null,this.frameDuration=1e3/60}return e.prototype.addToQueue=function(e){this.queue.push(e),this.startQueue()},e.prototype.stopQueue=function(){null!==this.timerId&&(cancelAnimationFrame(this.timerId),this.timerId=null),this.queue=[]},e.prototype.startQueue=function(){var e=this;this.timerId||(this.timerId=requestAnimationFrame((function(){e.timerId=null;for(var t,r=Date.now();t=e.queue.shift();)if(t(),Date.now()-r>=e.frameDuration){e.startQueue();break}})))},e}());function xt(e){return d(this,void 0,void 0,(function(){var t=this;return f(this,(function(r){return[2,new Promise((function(r,n){return d(t,void 0,void 0,(function(){var t,a,o,i;return f(this,(function(c){switch(c.label){case 0:return e.startsWith("data:")?(t=e,[3,4]):[3,1];case 1:return c.trys.push([1,3,,4]),[4,Tt(e)];case 2:return t=c.sent(),[3,4];case 3:return a=c.sent(),n(a),[2];case 4:return c.trys.push([4,6,,7]),[4,Rt(t)];case 5:return o=c.sent(),Ct.addToQueue((function(){r(l({src:e,dataURL:t,width:o.naturalWidth,height:o.naturalHeight},function(e){Vt||(t=At,r=At,(Vt=document.createElement("canvas")).width=t,Vt.height=r,(Mt=Vt.getContext("2d",{willReadFrequently:!0})).imageSmoothingEnabled=!1);var t,r;var n=e.naturalWidth,a=e.naturalHeight;if(0===a||0===n)return"logWarn(Image is empty ".concat(e.currentSrc,")"),{isDark:!1,isLight:!1,isTransparent:!1,isLarge:!1,isTooLarge:!1};if(n*a*4>Lt)return{isDark:!1,isLight:!1,isTransparent:!1,isLarge:!1,isTooLarge:!0};var o=n*a,i=Math.min(1,Math.sqrt(At/o)),c=Math.ceil(n*i),u=Math.ceil(a*i);Mt.clearRect(0,0,c,u),Mt.drawImage(e,0,0,n,a,0,0,c,u);var s,l,d,f,h,p,v,m=Mt.getImageData(0,0,c,u).data,g=.05,b=.4,y=.7,S=0,w=0,k=0;for(d=0;d<u;d++)for(l=0;l<c;l++)f=m[(s=4*(d*c+l))+0],h=m[s+1],p=m[s+2],m[s+3]/255<g?S++:((v=Qe(f,h,p))<b&&w++,v>y&&k++);var _=c*u,E=_-S;return{isDark:w/E>=.7,isLight:k/E>=.7,isTransparent:S/_>=.1,isLarge:o>=48e4,isTooLarge:!1}}(o)))})),[3,7];case 6:return i=c.sent(),n(i),[3,7];case 7:return[2]}}))}))}))]}))}))}function Tt(e){return d(this,void 0,void 0,(function(){return f(this,(function(t){switch(t.label){case 0:return new URL(e).origin!==location.origin?[3,2]:[4,M(e)];case 1:case 3:return[2,t.sent()];case 2:return[4,Et({url:e,responseType:"data-url"})]}}))}))}function Rt(e){return d(this,void 0,void 0,(function(){return f(this,(function(t){return[2,new Promise((function(t,r){var n=new Image;n.onload=function(){return t(n)},n.onerror=function(){return r("Unable to load image ".concat(e))},n.src=e}))]}))}))}var Vt,Mt,At=1024;var Lt=5242880;function Ot(e,t){var r=e.dataURL,n=e.width,a=e.height,o=Ze(t).slice(0,4).map((function(e){return e.map((function(e){return e.toFixed(3)})).join(" ")})).join(" "),i=['<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="'.concat(n,'" height="').concat(a,'">'),"<defs>",'<filter id="darkreader-image-filter">','<feColorMatrix type="matrix" values="'.concat(o,'" />'),"</filter>","</defs>",'<image width="'.concat(n,'" height="').concat(a,'" filter="url(#darkreader-image-filter)" xlink:href="').concat(r,'" />'),"</svg>"].join("");return"data:image/svg+xml;base64,".concat(btoa(i))}function Dt(){Ct&&Ct.stopQueue(),Vt=null,Mt=null}var Pt=8,Nt="conic-",jt=Nt.length,Ft="radial-",It="linear-";function Bt(e,t){return Boolean(e&&e.getPropertyPriority(t))}function qt(e,t,r,n,a,o){if(e.startsWith("--")){var i=function(e,t,r,n,a,o){return e.getModifierForVariable({varName:t,sourceValue:r,rule:n,ignoredImgSelectors:a,isCancelled:o})}(n,e,t,r,a,o);if(i)return{property:e,value:i,important:Bt(r.style,e),sourceValue:t}}else if(t.includes("var(")){i=function(e,t,r){return e.getModifierForVarDependant(t,r)}(n,e,t);if(i)return{property:e,value:i,important:Bt(r.style,e),sourceValue:t}}else{if("color-scheme"===e)return null;if(e.includes("color")&&"-webkit-print-color-adjust"!==e||"fill"===e||"stroke"===e||"stop-color"===e){i=function(e,t,r){if($t.has(t.toLowerCase()))return t;var n=Le(t);if(!n)return null;if(e.includes("background"))return r.style.webkitMaskImage&&"none"!==r.style.webkitMaskImage||r.style.webkitMask&&!r.style.webkitMask.startsWith("none")||r.style.mask&&"none"!==r.style.mask||r.style.getPropertyValue("mask-image")&&"none"!==r.style.getPropertyValue("mask-image")?function(e){return mt(n,e)}:function(e){return dt(n,e)};if(e.includes("border")||e.includes("outline"))return function(e){return bt(n,e)};return function(e){return mt(n,e)}}(e,t,r);if(i)return{property:e,value:i,important:Bt(r.style,e),sourceValue:t}}else if("background-image"===e||"list-style-image"===e){if(i=Kt(t,r,a,o))return{property:e,value:i,important:Bt(r.style,e),sourceValue:t}}else if(e.includes("shadow")){i=function(e){var t=Yt(e);if(!t)return null;return function(e){return t(e).result}}(t);if(i)return{property:e,value:i,important:Bt(r.style,e),sourceValue:t}}}return null}function Wt(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return e.filter(Boolean).join(", ")}function Ht(e,t,r){var n=[];t||(n.push("html {"),n.push(" background-color: ".concat(dt({r:255,g:255,b:255},e)," !important;")),n.push("}")),R&&(n.push("html {"),n.push(" color-scheme: ".concat(1===e.mode?"dark":"dark light"," !important;")),n.push("}"));var a=Wt(t?"":"html, body",r?"input, textarea, select, button, dialog":"");return a&&(n.push("".concat(a," {")),n.push(" background-color: ".concat(dt({r:255,g:255,b:255},e),";")),n.push("}")),n.push("".concat(Wt("html, body",r?"input, textarea, select, button":"")," {")),n.push(" border-color: ".concat(bt({r:76,g:76,b:76},e),";")),n.push(" color: ".concat(mt({r:0,g:0,b:0},e),";")),n.push("}"),n.push("a {"),n.push(" color: ".concat(mt({r:0,g:64,b:255},e),";")),n.push("}"),n.push("table {"),n.push(" border-color: ".concat(bt({r:128,g:128,b:128},e),";")),n.push("}"),n.push("::placeholder {"),n.push(" color: ".concat(mt({r:169,g:169,b:169},e),";")),n.push("}"),n.push("input:-webkit-autofill,"),n.push("textarea:-webkit-autofill,"),n.push("select:-webkit-autofill {"),n.push(" background-color: ".concat(dt({r:250,g:255,b:189},e)," !important;")),n.push(" color: ".concat(mt({r:0,g:0,b:0},e)," !important;")),n.push("}"),e.scrollbarColor&&n.push(function(e){var t,r,n,a,o,i,c=[];if("auto"===e.scrollbarColor)t=dt({r:241,g:241,b:241},e),r=mt({r:96,g:96,b:96},e),n=dt({r:176,g:176,b:176},e),a=dt({r:144,g:144,b:144},e),o=dt({r:96,g:96,b:96},e),i=dt({r:255,g:255,b:255},e);else{var u=Pe(Le(e.scrollbarColor)),s=u.l>.5,d=function(e){return l(l({},u),{l:Ye(u.l+e,0,1)})},f=function(e){return l(l({},u),{l:Ye(u.l-e,0,1)})};t=je(f(.4)),r=je(s?f(.4):d(.4)),n=je(u),a=je(d(.1)),o=je(d(.2)),i=je(f(.5))}c.push("::-webkit-scrollbar {"),c.push(" background-color: ".concat(t,";")),c.push(" color: ".concat(r,";")),c.push("}"),c.push("::-webkit-scrollbar-thumb {"),c.push(" background-color: ".concat(n,";")),c.push("}"),c.push("::-webkit-scrollbar-thumb:hover {"),c.push(" background-color: ".concat(a,";")),c.push("}"),c.push("::-webkit-scrollbar-thumb:active {"),c.push(" background-color: ".concat(o,";")),c.push("}"),c.push("::-webkit-scrollbar-corner {"),c.push(" background-color: ".concat(i,";")),c.push("}"),S&&(c.push("* {"),c.push(" scrollbar-color: ".concat(n," ").concat(t,";")),c.push("}"));return c.join("\n")}(e)),e.selectionColor&&n.push(function(e){var t=[],r=Ut(e),n=r.backgroundColorSelection,a=r.foregroundColorSelection;return["::selection","::-moz-selection"].forEach((function(e){t.push("".concat(e," {")),t.push(" background-color: ".concat(n," !important;")),t.push(" color: ".concat(a," !important;")),t.push("}")})),t.join("\n")}(e)),n.join("\n")}function Ut(e){var t,r;if("auto"===e.selectionColor)t=dt({r:0,g:96,b:212},l(l({},e),{grayscale:0})),r=mt({r:255,g:255,b:255},l(l({},e),{grayscale:0}));else{var n=Pe(Le(e.selectionColor));t=e.selectionColor,r=n.l<.5?"#FFF":"#000"}return{backgroundColorSelection:t,foregroundColorSelection:r}}function Gt(e,t){var r=t.strict,n=[],a=["microsoft.com","docs.microsoft.com"].includes(location.hostname);return n.push("html, body, ".concat(r?"body :not(iframe)".concat(a?':not(div[style^="position:absolute;top:0;left:-"]':""):"body > :not(iframe)"," {")),n.push(" background-color: ".concat(dt({r:255,g:255,b:255},e)," !important;")),n.push(" border-color: ".concat(bt({r:64,g:64,b:64},e)," !important;")),n.push(" color: ".concat(mt({r:0,g:0,b:0},e)," !important;")),n.push("}"),n.join("\n")}var $t=new Set(["inherit","transparent","initial","currentcolor","none","unset"]);var zt=new Map,Qt=new Map;function Kt(e,t,r,n){var a,o,i=this;try{var c=function(e){for(var t=[],r=0,n=Nt.length,a=function(){var a;if([It,Ft,Nt].find((function(t){if(r-t.length>=0&&e.substring(r-t.length,r)===t)return"repeating"===e.slice(r-t.length-10,r-t.length-1)?(a="repeating-".concat(t,"gradient"),!0):"-webkit"===e.slice(r-t.length-8,r-t.length-1)?(a="-webkit-".concat(t,"gradient"),!0):(a="".concat(t,"gradient"),!0)})),!a)return"break";var o=Ve(e,r+Pt),i=o.start,c=o.end,u=e.substring(i+1,c-1);n=c+1+jt,t.push({typeGradient:a,match:u,offset:a.length+2,index:r-a.length+Pt,hasComma:!0})};-1!==(r=e.indexOf("gradient",n))&&"break"!==a(););return t.length&&(t[t.length-1].hasComma=!1),t}(e),u=Re(ye,e);if(0===u.length&&0===c.length)return e;var s=c.map((function(e){return l({type:"gradient"},e)})).concat((a=u,o=0,a.map((function(t){var r=e.indexOf(t,o);return o=r+t.length,{match:t,index:r}}))).map((function(e){return l({type:"url",offset:0},e)}))).sort((function(e,t){return e.index>t.index?1:-1})),h=function(e,t){var r,n=e.isDark,a=e.isLight,o=e.isTransparent,i=e.isLarge,c=e.isTooLarge,u=e.width;if(c)"Not modifying too large image ".concat(e.src),r='url("'.concat(e.src,'")');else if(n&&o&&1===t.mode&&!i&&u>2){"Inverting dark image ".concat(e.src);var s=Ot(e,l(l({},t),{sepia:Ye(t.sepia+10,0,100)}));r='url("'.concat(s,'")')}else if(a&&!o&&1===t.mode)if(i)"Not modifying light non-transparent large image ".concat(e.src),r="none";else{"Dimming light image ".concat(e.src);var d=Ot(e,t);r='url("'.concat(d,'")')}else if(0===t.mode&&a&&!i){"Applying filter to image ".concat(e.src);var f=Ot(e,l(l({},t),{brightness:Ye(t.brightness-10,5,200),sepia:Ye(t.sepia+10,0,100)}));r='url("'.concat(f,'")')}else"Not modifying too large image ".concat(e.src),r=null;return r},p=[],v=0,m=!1;return s.forEach((function(a,o){var c=a.type,u=a.match,l=a.index,g=a.typeGradient,b=a.hasComma,y=a.offset,S=l,w=v,k=S+u.length+y;v=k,w!==S&&(m?p.push((function(){var t=e.substring(w,S);return","===t[0]&&(t=t.substring(1)),t})):p.push((function(){return e.substring(w,S)}))),m=b||!1,"url"===c?p.push(function(e){var a;if(function(e,t){if(!e||0===t.length)return!1;if(t.some((function(e){return"*"===e})))return!0;for(var r=e.split(/,\s*/g),n=function(e){var n=t[e];if(r.some((function(e){return e===n})))return{value:!0}},a=0;a<t.length;a++){var o=n(a);if("object"==typeof o)return o.value}return!1}(t.selectorText,r))return null;var o=we(e),c=0===o.length,u=t.parentStyleSheet,s=u&&u.href?ke(u.href):(null===(a=u.ownerNode)||void 0===a?void 0:a.baseURI)||location.origin;o=pe(s,o);var l='url("'.concat(o,'")');return function(e){return d(i,void 0,void 0,(function(){var t,r;return f(this,(function(a){switch(a.label){case 0:return c?[2,"url('')"]:zt.has(o)?(t=zt.get(o),[3,7]):[3,1];case 1:return a.trys.push([1,6,,7]),Qt.has(o)?(r=Qt.get(o),[4,new Promise((function(e){return r.push(e)}))]):[3,3];case 2:return(t=a.sent())?[3,5]:[2,null];case 3:return Qt.set(o,[]),[4,xt(o)];case 4:t=a.sent(),zt.set(o,t),Qt.get(o).forEach((function(e){return e(t)})),Qt.delete(o),a.label=5;case 5:return n()?[2,null]:[3,7];case 6:return a.sent(),Qt.has(o)&&(Qt.get(o).forEach((function(e){return e(null)})),Qt.delete(o)),[2,l];case 7:return[2,h(t,e)||l]}}))}))}}(u)):"gradient"===c&&p.push(function(e){var t=e.typeGradient,r=e.match,n=e.hasComma,a=/^(from|color-stop|to)\(([^\(\)]*?,\s*)?(.*?)\)$/,o=Re(/([^\(\),]+(\([^\(\)]*(\([^\(\)]*\)*[^\(\)]*)?\))?([^\(\), ]|( (?!calc)))*),?/g,r,1).map((function(e){var t=Le(e=e.trim());if(t)return function(e){return yt(t,e)};var r=e.lastIndexOf(" ");if(t=Le(e.substring(0,r)))return function(n){return"".concat(yt(t,n)," ").concat(e.substring(r+1))};var n=e.match(a);return n&&(t=Le(n[3]))?function(e){return"".concat(n[1],"(").concat(n[2]?"".concat(n[2],", "):"").concat(yt(t,e),")")}:function(){return e}}));return function(e){return"".concat(t,"(").concat(o.map((function(t){return t(e)})).join(", "),")").concat(n?", ":"")}}({match:u,index:l,typeGradient:g,hasComma:b||!1,offset:y})),o===s.length-1&&p.push((function(){return e.substring(k)}))})),function(e){var t=p.filter(Boolean).map((function(t){return t(e)}));if(t.some((function(e){return e instanceof Promise})))return Promise.all(t).then((function(e){return e.filter(Boolean).join("")}));var r=t.join("");return r.endsWith(", initial")?r.slice(0,-9):r}}catch(e){return null}}function Yt(e){try{var t=0,r=Re(/(^|\s)(?!calc)([a-z]+\(.+?\)|#[0-9a-f]+|[a-z]+)(.*?(inset|outset)?($|,))/gi,e,2),n=0,a=r.map((function(a,o){var i=t,c=e.indexOf(a,t),u=c+a.length;t=u;var s=Le(a);return s?function(t){return"".concat(e.substring(i,c)).concat(function(e,t){return dt(e,t)}(s,t)).concat(o===r.length-1?e.substring(u):"")}:(n++,function(){return e.substring(i,u)})}));return function(e){var t=a.map((function(t){return t(e)})).join("");return{matchesLength:r.length,unparseableMatchesLength:n,result:t}}}catch(e){return null}}function Xt(){rt.clear(),zt.clear(),Dt(),Qt.clear()}var Zt=new(function(){function e(){this.varTypes=new Map,this.rulesQueue=[],this.definedVars=new Set,this.varRefs=new Map,this.unknownColorVars=new Set,this.unknownBgVars=new Set,this.undefinedVars=new Set,this.initialVarTypes=new Map,this.changedTypeVars=new Set,this.typeChangeSubscriptions=new Map,this.unstableVarValues=new Map}return e.prototype.clear=function(){this.varTypes.clear(),this.rulesQueue.splice(0),this.definedVars.clear(),this.varRefs.clear(),this.unknownColorVars.clear(),this.unknownBgVars.clear(),this.undefinedVars.clear(),this.initialVarTypes.clear(),this.changedTypeVars.clear(),this.typeChangeSubscriptions.clear(),this.unstableVarValues.clear()},e.prototype.isVarType=function(e,t){return this.varTypes.has(e)&&(this.varTypes.get(e)&t)>0},e.prototype.addRulesForMatching=function(e){this.rulesQueue.push(e)},e.prototype.matchVariablesAndDependants=function(){var e=this;this.changedTypeVars.clear(),this.initialVarTypes=new Map(this.varTypes),this.collectRootVariables(),this.collectVariablesAndVarDep(this.rulesQueue),this.rulesQueue.splice(0),this.collectRootVarDependants(),this.varRefs.forEach((function(t,r){t.forEach((function(t){e.varTypes.has(r)&&e.resolveVariableType(t,e.varTypes.get(r))}))})),this.unknownColorVars.forEach((function(t){e.unknownBgVars.has(t)?(e.unknownColorVars.delete(t),e.unknownBgVars.delete(t),e.resolveVariableType(t,1)):e.isVarType(t,7)?e.unknownColorVars.delete(t):e.undefinedVars.add(t)})),this.unknownBgVars.forEach((function(t){null!=e.findVarRef(t,(function(t){return e.unknownColorVars.has(t)||e.isVarType(t,6)}))?e.itarateVarRefs(t,(function(t){e.resolveVariableType(t,1)})):e.isVarType(t,9)?e.unknownBgVars.delete(t):e.undefinedVars.add(t)})),this.changedTypeVars.forEach((function(t){e.typeChangeSubscriptions.has(t)&&e.typeChangeSubscriptions.get(t).forEach((function(e){e()}))})),this.changedTypeVars.clear()},e.prototype.getModifierForVariable=function(e){var t=this;return function(r){var n=e.varName,a=e.sourceValue,o=e.rule,i=e.ignoredImgSelectors,c=e.isCancelled,u=function(){var e=[],u=function(o,i,c){if(t.isVarType(n,o)){var u,s=i(n);if(ur(a))if(sr(a)){var l=mr(a,t.unstableVarValues);l||(l=1===o?"#ffffff":"#000000"),u=c(l,r)}else u=rr(a,(function(e){return i(e)}),(function(e){return c(e,r)}));else u=c(a,r);e.push({property:s,value:u})}};if(u(1,nr,hr),u(2,ar,pr),u(4,or,vr),t.isVarType(n,8)){var s=ir(n),l=a;ur(a)&&(l=rr(a,(function(e){return nr(e)}),(function(e){return hr(e,r)})));var d=Kt(l,o,i,c);l="function"==typeof d?d(r):d,e.push({property:s,value:l})}return e},s=new Set;return{declarations:u(),onTypeChange:{addListener:function(e){var r=function(){var t=u();e(t)};s.add(r),t.subscribeForVarTypeChange(n,r)},removeListeners:function(){s.forEach((function(e){t.unsubscribeFromVariableTypeChanges(n,e)}))}}}}},e.prototype.getModifierForVarDependant=function(e,t){var r=this;if(t.match(/^\s*(rgb|hsl)a?\(/)){var n=e.startsWith("background"),a=lr(e);return function(e){var o=mr(t,r.unstableVarValues);return o||(o=n?"#ffffff":"#000000"),(n?hr:a?pr:vr)(o,e)}}return"background-color"===e?function(e){return rr(t,(function(e){return nr(e)}),(function(t){return hr(t,e)}))}:lr(e)?function(e){return rr(t,(function(e){return ar(e)}),(function(t){return pr(t,e)}))}:"background"===e||"background-image"===e||"box-shadow"===e?function(n){var a=new Set,o=function(){var o=rr(t,(function(e){return r.isVarType(e,1)?nr(e):r.isVarType(e,8)?ir(e):(a.add(e),e)}),(function(e){return hr(e,n)}));if("box-shadow"===e){var i=Yt(o)(n);if(i.unparseableMatchesLength!==i.matchesLength)return i.result}return o},i=o();return a.size>0?new Promise((function(e){var t=a.values().next().value,n=function(){r.unsubscribeFromVariableTypeChanges(t,n);var a=o();e(a)};r.subscribeForVarTypeChange(t,n)})):i}:e.startsWith("border")||e.startsWith("outline")?function(e){return rr(t,(function(e){return or(e)}),(function(t){return vr(t,e)}))}:null},e.prototype.subscribeForVarTypeChange=function(e,t){this.typeChangeSubscriptions.has(e)||this.typeChangeSubscriptions.set(e,new Set);var r=this.typeChangeSubscriptions.get(e);r.has(t)||r.add(t)},e.prototype.unsubscribeFromVariableTypeChanges=function(e,t){this.typeChangeSubscriptions.has(e)&&this.typeChangeSubscriptions.get(e).delete(t)},e.prototype.collectVariablesAndVarDep=function(e){var t=this;e.forEach((function(e){ve(e,(function(e){e.style&&be(e.style,(function(e,r){cr(e)&&t.inspectVariable(e,r),ur(r)&&t.inspectVarDependant(e,r)}))}))}))},e.prototype.collectRootVariables=function(){var e=this;be(document.documentElement.style,(function(t,r){cr(t)&&e.inspectVariable(t,r)}))},e.prototype.inspectVariable=function(e,t){(this.unstableVarValues.set(e,t),ur(t)&&sr(t)&&(this.unknownColorVars.add(e),this.definedVars.add(e)),this.definedVars.has(e))||(this.definedVars.add(e),dr.test(t)||Le(t)?this.unknownColorVars.add(e):(t.includes("url(")||t.includes("linear-gradient(")||t.includes("radial-gradient("))&&this.resolveVariableType(e,8))},e.prototype.resolveVariableType=function(e,t){var r=this.initialVarTypes.get(e)||0,n=(this.varTypes.get(e)||0)|t;this.varTypes.set(e,n),(n!==r||this.undefinedVars.has(e))&&(this.changedTypeVars.add(e),this.undefinedVars.delete(e)),this.unknownColorVars.delete(e),this.unknownBgVars.delete(e)},e.prototype.collectRootVarDependants=function(){var e=this;be(document.documentElement.style,(function(t,r){ur(r)&&e.inspectVarDependant(t,r)}))},e.prototype.inspectVarDependant=function(e,t){var r=this;cr(e)?this.iterateVarDeps(t,(function(t){r.varRefs.has(e)||r.varRefs.set(e,new Set),r.varRefs.get(e).add(t)})):"background-color"===e||"box-shadow"===e?this.iterateVarDeps(t,(function(e){return r.resolveVariableType(e,1)})):lr(e)?this.iterateVarDeps(t,(function(e){return r.resolveVariableType(e,2)})):e.startsWith("border")||e.startsWith("outline")?this.iterateVarDeps(t,(function(e){return r.resolveVariableType(e,4)})):"background"!==e&&"background-image"!==e||this.iterateVarDeps(t,(function(e){if(!r.isVarType(e,9)){var t=null!=r.findVarRef(e,(function(e){return r.unknownColorVars.has(e)||r.isVarType(e,6)}));r.itarateVarRefs(e,(function(e){t?r.resolveVariableType(e,1):r.unknownBgVars.add(e)}))}}))},e.prototype.iterateVarDeps=function(e,t){var r=new Set;!function(e,t){rr(e,(function(e){return t(e),e}))}(e,(function(e){return r.add(e)})),r.forEach((function(e){return t(e)}))},e.prototype.findVarRef=function(e,t,r){var n,a;if(void 0===r&&(r=new Set),r.has(e))return null;if(r.add(e),t(e))return e;var o=this.varRefs.get(e);if(!o||0===o.size)return null;try{for(var i=h(o),c=i.next();!c.done;c=i.next()){var u=c.value,s=this.findVarRef(u,t,r);if(s)return s}}catch(e){n={error:e}}finally{try{c&&!c.done&&(a=i.return)&&a.call(i)}finally{if(n)throw n.error}}return null},e.prototype.itarateVarRefs=function(e,t){this.findVarRef(e,(function(e){return t(e),!1}))},e.prototype.setOnRootVariableChange=function(e){this.onRootVariableDefined=e},e.prototype.putRootVars=function(e,t){var r,n,a=this,o=e.sheet;o.cssRules.length>0&&o.deleteRule(0);var i=new Map;be(document.documentElement.style,(function(e,r){cr(e)&&(a.isVarType(e,1)&&i.set(nr(e),hr(r,t)),a.isVarType(e,2)&&i.set(ar(e),pr(r,t)),a.isVarType(e,4)&&i.set(or(e),vr(r,t)),a.subscribeForVarTypeChange(e,a.onRootVariableDefined))}));var c=[];c.push(":root {");try{for(var u=h(i),s=u.next();!s.done;s=u.next()){var l=p(s.value,2),d=l[0],f=l[1];c.push(" ".concat(d,": ").concat(f,";"))}}catch(e){r={error:e}}finally{try{s&&!s.done&&(n=u.return)&&n.call(u)}finally{if(r)throw r.error}}c.push("}");var v=c.join("\n");o.insertRule(v)},e}());function Jt(e,t){void 0===t&&(t=0);var r=e.indexOf("var(",t);if(r>=0){var n=Ve(e,r+3);if(n)return{start:r,end:n.end}}return null}function er(e,t){var r=function(e){for(var t,r=[],n=0;t=Jt(e,n);){var a=t.start,o=t.end;r.push({start:a,end:o,value:e.substring(a,o)}),n=t.end+1}return r}(e),n=r.length;if(0===n)return e;var a=e.length,o=r.map((function(e){return t(e.value)})),i=[];i.push(e.substring(0,r[0].start));for(var c=0;c<n;c++){i.push(o[c]);var u=r[c].end,s=c<n-1?r[c+1].start:a;i.push(e.substring(u,s))}return i.join("")}function tr(e){var t,r,n=e.indexOf(",");return n>=0?(t=e.substring(4,n).trim(),r=e.substring(n+1,e.length-1).trim()):(t=e.substring(4,e.length-1).trim(),r=""),{name:t,fallback:r}}function rr(e,t,r){return er(e,(function(e){var n,a=tr(e),o=a.name,i=a.fallback,c=t(o);return i?(n=ur(i)?rr(i,t,r):r?r(i):i,"var(".concat(c,", ").concat(n,")")):"var(".concat(c,")")}))}function nr(e){return"--darkreader-bg".concat(e)}function ar(e){return"--darkreader-text".concat(e)}function or(e){return"--darkreader-border".concat(e)}function ir(e){return"--darkreader-bgimg".concat(e)}function cr(e){return e.startsWith("--")}function ur(e){return e.includes("var(")}function sr(e){return e.match(/^\s*(rgb|hsl)a?\(/)}function lr(e){return"color"===e||"caret-color"===e||"-webkit-text-fill-color"===e}var dr=/^\d{1,3}, ?\d{1,3}, ?\d{1,3}$/;function fr(e,t,r){var n=function(e){if(dr.test(e)){var t=e.split(","),r="rgb(";return t.forEach((function(e){r+="".concat(e.trim(),", ")})),r=r.substring(0,r.length-2),{isRaw:!0,color:r+=")"}}return{isRaw:!1,color:e}}(e),a=n.isRaw,o=n.color,i=Le(o);if(i){var c=r(i,t);if(a){var u=Le(c);return u?"".concat(u.r,", ").concat(u.g,", ").concat(u.b):c}return c}return o}function hr(e,t){return fr(e,t,dt)}function pr(e,t){return fr(e,t,mt)}function vr(e,t){return fr(e,t,bt)}function mr(e,t,r){void 0===r&&(r=new Set);var n=!1,a=er(e,(function(e){var a=tr(e),o=a.name,i=a.fallback;if(r.has(o))return n=!0,null;r.add(o);var c=t.get(o)||i,u=null;return c&&(u=ur(c)?mr(c,t,r):c),u||(n=!0,null)}));return n?null:a}var gr={"background-color":{customProp:"--darkreader-inline-bgcolor",cssProp:"background-color",dataAttr:"data-darkreader-inline-bgcolor"},"background-image":{customProp:"--darkreader-inline-bgimage",cssProp:"background-image",dataAttr:"data-darkreader-inline-bgimage"},"border-color":{customProp:"--darkreader-inline-border",cssProp:"border-color",dataAttr:"data-darkreader-inline-border"},"border-bottom-color":{customProp:"--darkreader-inline-border-bottom",cssProp:"border-bottom-color",dataAttr:"data-darkreader-inline-border-bottom"},"border-left-color":{customProp:"--darkreader-inline-border-left",cssProp:"border-left-color",dataAttr:"data-darkreader-inline-border-left"},"border-right-color":{customProp:"--darkreader-inline-border-right",cssProp:"border-right-color",dataAttr:"data-darkreader-inline-border-right"},"border-top-color":{customProp:"--darkreader-inline-border-top",cssProp:"border-top-color",dataAttr:"data-darkreader-inline-border-top"},"box-shadow":{customProp:"--darkreader-inline-boxshadow",cssProp:"box-shadow",dataAttr:"data-darkreader-inline-boxshadow"},color:{customProp:"--darkreader-inline-color",cssProp:"color",dataAttr:"data-darkreader-inline-color"},fill:{customProp:"--darkreader-inline-fill",cssProp:"fill",dataAttr:"data-darkreader-inline-fill"},stroke:{customProp:"--darkreader-inline-stroke",cssProp:"stroke",dataAttr:"data-darkreader-inline-stroke"},"outline-color":{customProp:"--darkreader-inline-outline",cssProp:"outline-color",dataAttr:"data-darkreader-inline-outline"},"stop-color":{customProp:"--darkreader-inline-stopcolor",cssProp:"stop-color",dataAttr:"data-darkreader-inline-stopcolor"}},br=Object.values(gr),yr={};br.forEach((function(e){var t=e.cssProp,r=e.customProp;return yr[r]=t}));var Sr=["style","fill","stop-color","stroke","bgcolor","color"],wr=Sr.map((function(e){return"[".concat(e,"]")})).join(", ");function kr(){return br.map((function(e){var t=e.dataAttr,r=e.customProp,n=e.cssProp;return["[".concat(t,"] {")," ".concat(n,": var(").concat(r,") !important;"),"}"].join("\n")})).join("\n")}var _r=new Map,Er=new Map;function Cr(e,t,r){_r.has(e)&&(_r.get(e).disconnect(),Er.get(e).disconnect());var n=new WeakSet;function a(e){(function(e){var t=[];return e instanceof Element&&e.matches(wr)&&t.push(e),(e instanceof Element||C&&e instanceof ShadowRoot||e instanceof Document)&&$(t,e.querySelectorAll(wr)),t})(e).forEach((function(e){n.has(e)||(n.add(e),t(e))})),X(e,(function(a){n.has(e)||(n.add(e),r(a.shadowRoot),Cr(a.shadowRoot,t,r))}))}var o=le(e,{onMinorMutations:function(e){e.additions.forEach((function(e){return a(e)}))},onHugeMutations:function(){a(e)}});_r.set(e,o);var i=0,c=null,u=Q({seconds:10}),s=Q({seconds:2}),l=[],d=null,f=z((function(e){var r=new Set;e.forEach((function(e){var n=e.target;r.has(n)||Sr.includes(e.attributeName)&&(r.add(n),t(n))}))})),h=new MutationObserver((function(e){if(d)l.push.apply(l,v([],p(e),!1));else{i++;var t=Date.now();if(null==c)c=t;else if(i>=50){if(t-c<u)return d=setTimeout((function(){c=null,i=0,d=null;var e=l;l=[],f(e)}),s),void l.push.apply(l,v([],p(e),!1));c=t,i=1}f(e)}}));h.observe(e,{attributes:!0,attributeFilter:Sr.concat(br.map((function(e){return e.dataAttr}))),subtree:!0}),Er.set(e,h)}var xr=new WeakMap,Tr=["brightness","contrast","grayscale","sepia","mode"];function Rr(e,t){return Sr.map((function(t){return"".concat(t,'="').concat(e.getAttribute(t),'"')})).concat(Tr.map((function(e){return"".concat(e,'="').concat(t[e],'"')}))).join(" ")}function Vr(e,t,r,n){if(Rr(e,t)!==xr.get(e)){var a=new Set(Object.keys(gr));if(r.length>0&&function(e,t){for(var r=0,n=t.length;r<n;r++){var a=t[r];if(e.matches(a))return!0}return!1}(e,r))a.forEach((function(t){e.removeAttribute(gr[t].dataAttr)}));else{if(e.hasAttribute("bgcolor"))((c=e.getAttribute("bgcolor")).match(/^[0-9a-f]{3}$/i)||c.match(/^[0-9a-f]{6}$/i))&&(c="#".concat(c)),u("background-color","background-color",c);if(e.hasAttribute("color")&&"mask-icon"!==e.rel)((c=e.getAttribute("color")).match(/^[0-9a-f]{3}$/i)||c.match(/^[0-9a-f]{6}$/i))&&(c="#".concat(c)),u("color","color",c);if(e instanceof SVGElement){if(e.hasAttribute("fill")){var o=e.getAttribute("fill");if("none"!==o)if(e instanceof SVGTextElement)u("fill","color",o);else{var i=function(){var t=e.getBoundingClientRect(),r=t.width,n=t.height;u("fill",r>32||n>32?"background-color":"color",o)};re()?i():ae(i)}}e.hasAttribute("stop-color")&&u("stop-color","background-color",e.getAttribute("stop-color"))}if(e.hasAttribute("stroke")){var c=e.getAttribute("stroke");u("stroke",e instanceof SVGLineElement||e instanceof SVGTextElement?"border-color":"color",c)}e.style&&be(e.style,(function(t,r){if("background-image"!==t||!r.includes("url"))if(gr.hasOwnProperty(t)||t.startsWith("--")&&!yr[t])u(t,t,r);else{var n=yr[t];if(n&&!e.style.getPropertyValue(n)&&!e.hasAttribute(n)){if("background-color"===n&&e.hasAttribute("bgcolor"))return;e.style.setProperty(t,"")}}})),e.style&&e instanceof SVGTextElement&&e.style.fill&&u("fill","color",e.style.getPropertyValue("fill")),G(a,(function(t){e.removeAttribute(gr[t].dataAttr)})),xr.set(e,Rr(e,t))}}function u(r,o,i){var c=r.startsWith("--"),u=c?{}:gr[r],s=u.customProp,l=u.dataAttr,d=qt(o,i,{style:e.style},Zt,n,null);if(d){var f=d.value;if("function"==typeof f&&(f=f(t)),c&&"object"==typeof f)f.declarations.forEach((function(t){var r=t.property,n=t.value;!(n instanceof Promise)&&e.style.setProperty(r,n)}));else e.style.setProperty(s,f),e.hasAttribute(l)||e.setAttribute(l,""),a.delete(r)}}}var Mr="theme-color",Ar='meta[name="'.concat(Mr,'"]'),Lr=null,Or=null;function Dr(e,t){var r=Le(Lr=Lr||e.content);r&&(e.content=dt(r,t))}var Pr=["mode","brightness","contrast","grayscale","sepia","darkSchemeBackgroundColor","darkSchemeTextColor","lightSchemeBackgroundColor","lightSchemeTextColor"];var Nr=function(){var e=[],t=null;function r(){for(var r;r=e.shift();)r();t=null}return{add:function(n){e.push(n),t||(t=requestAnimationFrame(r))},cancel:function(){e.splice(0),cancelAnimationFrame(t),t=null}}}();function jr(){var e=0,t=new Set,r=new Map,n=new Set,a=null,o=!1,i=!1;return{modifySheet:function(c){var u=c.sourceCSSRules,s=c.theme,l=c.ignoreImageAnalysis,d=c.force,f=c.prepareSheet,h=c.isAsyncCancelled,m=0===r.size,g=new Set(r.keys()),b=function(e){var t="";return Pr.forEach((function(r){t+="".concat(r,":").concat(e[r],";")})),t}(s),y=b!==a;o&&(i=!0);var S=[];if(ve(u,(function(e){var n=e.cssText,a=!1;if(g.delete(n),e.parentRule instanceof CSSMediaRule&&(n+=";".concat(e.parentRule.media.mediaText)),t.has(n)||(t.add(n),a=!0),a){if(m=!0,"revert"!==e.style.all){var o=[];e.style&&be(e.style,(function(t,r){var n=qt(t,r,e,Zt,l,h);n&&o.push(n)}));var i=null;if(o.length>0){var c=e.parentRule;i={selector:e.selectorText,declarations:o,parentRule:c},S.push(i)}r.set(n,i)}}else S.push(r.get(n))}),(function(){o=!0})),g.forEach((function(e){t.delete(e),r.delete(e)})),a=b,d||m||y){e++;var w=new Map,k=new Map,_=0,E=0,C={rule:null,rules:[],isGroup:!0},x=new WeakMap;n.forEach((function(e){return e()})),n.clear(),S.filter((function(e){return e})).forEach((function(t){var r=t.selector,a=t.declarations,o=V(t.parentRule),i={selector:r,declarations:[],isGroup:!1},c=i.declarations;function u(t,r,n,a){var o=++_,i={property:t,value:null,important:n,asyncKey:o,sourceValue:a};c.push(i);var u=e;r.then((function(t){t&&!h()&&u===e&&(i.value=t,Nr.add((function(){h()||u!==e||function(e){var t=w.get(e),r=t.rule,n=t.target,a=t.index;n.deleteRule(a),R(n,a,r),w.delete(e)}(o)})))}))}function l(t,r,a,o){var i=r.declarations,s=r.onTypeChange,l=++E,d=e,f=c.length,m=[];if(0===i.length){var g={property:t,value:o,important:a,sourceValue:o,varKey:l};c.push(g),m=[g]}i.forEach((function(e){if(e.value instanceof Promise)u(e.property,e.value,a,o);else{var t={property:e.property,value:e.value,important:a,sourceValue:o,varKey:l};c.push(t),m.push(t)}})),s.addListener((function(t){if(!h()&&d===e){var r=t.map((function(e){return{property:e.property,value:e.value,important:a,sourceValue:o,varKey:l}})),n=c.indexOf(m[0],f);c.splice.apply(c,v([n,m.length],p(r),!1)),m=r,function(e){var t=k.get(e),r=t.rule,n=t.target,a=t.index;n.deleteRule(a),R(n,a,r)}(l)}})),n.add((function(){return s.removeListeners()}))}o.rules.push(i),a.forEach((function(e){var t=e.property,r=e.value,n=e.important,a=e.sourceValue;if("function"==typeof r){var o=r(s);o instanceof Promise?u(t,o,n,a):t.startsWith("--")?l(t,o,n,a):c.push({property:t,value:o,important:n,sourceValue:a})}else c.push({property:t,value:r,important:n,sourceValue:a})}))}));var T=f();!function e(t,r,n){t.rules.forEach((function(t){if(t.isGroup){var a=function(e,t){var r=e.rule;if(r instanceof CSSMediaRule){var n=r.media,a=t.cssRules.length;return t.insertRule("@media ".concat(n.mediaText," {}"),a),t.cssRules[a]}return t}(t,r);e(t,a,n)}else n(t,r)}))}(C,T,(function(e,t){var r=t.cssRules.length;e.declarations.forEach((function(n){var a=n.asyncKey,o=n.varKey;null!=a&&w.set(a,{rule:e,target:t,index:r}),null!=o&&k.set(o,{rule:e,target:t,index:r})})),R(t,r,e)}))}function R(e,t,r){var n=r.selector,a=r.declarations,o="";a.forEach((function(e){var t,r,n,a,i;o+="".concat((r=(t=e).property,n=t.value,a=t.important,i=t.sourceValue,"".concat(r,": ").concat(null==n?i:n).concat(a?" !important":"",";"))," ")}));var i="".concat(n," { ").concat(o," }");e.insertRule(i,t)}function V(e){if(null==e)return C;if(x.has(e))return x.get(e);var t={rule:e,rules:[],isGroup:!0};return x.set(e,t),V(e.parentRule).rules.push(t),t}},shouldRebuildStyle:function(){return o&&!i}}}var Fr='style, link[rel*="stylesheet" i]:not([disabled])';function Ir(e){return(e instanceof HTMLStyleElement||e instanceof SVGStyleElement||e instanceof HTMLLinkElement&&Boolean(e.rel)&&e.rel.toLowerCase().includes("stylesheet")&&Boolean(e.href)&&!e.disabled&&(!S||!e.href.startsWith("moz-extension://"))&&!function(e){if(!e.href)return!1;try{return"fonts.googleapis.com"===new URL(e.href).hostname}catch(t){return"Couldn't construct ".concat(e.href," as URL"),!1}}(e))&&!e.classList.contains("darkreader")&&"print"!==e.media.toLowerCase()&&!e.classList.contains("stylus")}function Br(e,t,r){return void 0===t&&(t=[]),void 0===r&&(r=!0),Ir(e)?t.push(e):(e instanceof Element||C&&e instanceof ShadowRoot||e===document)&&(G(e.querySelectorAll(Fr),(function(e){return Br(e,t,!1)})),r&&X(e,(function(e){return Br(e.shadowRoot,t,!1)}))),t}var qr=new WeakSet,Wr=new WeakSet,Hr=!1;document.addEventListener("__darkreader__inlineScriptsAllowed",(function(){Hr=!0}),{once:!0,passive:!0});var Ur=0,Gr=new Map;function $r(e,t){for(var r=t.update,n=t.loadingStart,a=t.loadingEnd,o=[],i=e;(i=i.nextElementSibling)&&i.matches(".darkreader");)o.push(i);var c=o.find((function(e){return e.matches(".darkreader--cors")&&!Wr.has(e)}))||null,u=o.find((function(e){return e.matches(".darkreader--sync")&&!qr.has(e)}))||null,s=null,l=null,h=!1,v=!0,m=jr(),g=new MutationObserver((function(){r()})),b={attributes:!0,childList:!0,subtree:!0,characterData:!0};function y(){return e instanceof HTMLStyleElement&&e.textContent.trim().match(Se)}function S(e,t){var r=!1;if(e){var n=void 0;e:for(var a=0,o=e.length;a<o;a++)if((n=e[a]).href){if(!t){r=!0;break e}if(!n.href.startsWith("https://fonts.googleapis.com/")&&n.href.startsWith("http")&&!n.href.startsWith(location.origin)){r=!0;break e}}}return r}function k(){if(c)return c.sheet.cssRules;if(y())return null;var t=M();return e instanceof HTMLLinkElement&&!function(e){if(e.startsWith("data:"))return!0;var t=he(e);return t.protocol===location.protocol&&t.hostname===location.hostname&&t.port===location.port&&t.pathname===location.pathname}(e.href)&&S(t,!1)||S(t,!0)?null:t}function _(){c?(e.nextSibling!==c&&e.parentNode.insertBefore(c,e.nextSibling),c.nextSibling!==u&&e.parentNode.insertBefore(u,c.nextSibling)):e.nextSibling!==u&&e.parentNode.insertBefore(u,e.nextSibling)}var E=!1,C=!1,x=++Ur;function T(){return d(this,void 0,void 0,(function(){var t,r,n,a,o,i,u;return f(this,(function(l){switch(l.label){case 0:if(!(e instanceof HTMLLinkElement))return[3,7];if(n=p(V(),2),a=n[0],o=n[1],!(w&&!e.sheet||!w&&!a&&!o||(d=o,d&&d.message&&d.message.includes("loading"))))return[3,5];l.label=1;case 1:return l.trys.push([1,3,,4]),[4,zr(e,x)];case 2:return l.sent(),[3,4];case 3:return l.sent(),C=!0,[3,4];case 4:if(h)return[2,null];u=p(V(),2),a=u[0],o=u[1],l.label=5;case 5:return a&&!S(a,!1)?[2,a]:[4,Qr(e.href)];case 6:return t=l.sent(),r=ke(e.href),h?[2,null]:[3,8];case 7:if(!y())return[2,null];t=e.textContent.trim(),r=ke(location.href),l.label=8;case 8:if(!t)return[3,13];l.label=9;case 9:return l.trys.push([9,11,,12]),[4,Kr(t,r)];case 10:return i=l.sent(),c=function(e,t){if(!t)return null;var r=document.createElement("style");return r.classList.add("darkreader"),r.classList.add("darkreader--cors"),r.media="screen",r.textContent=t,e.parentNode.insertBefore(r,e.nextSibling),r.sheet.disabled=!0,Wr.add(r),r}(e,i),[3,12];case 11:return l.sent(),[3,12];case 12:if(c)return s=Y(c,"prev-sibling"),[2,c.sheet.cssRules];l.label=13;case 13:return[2,null]}var d}))}))}var R=!1;function V(){try{return null==e.sheet?[null,null]:[e.sheet.cssRules,null]}catch(e){return[null,e]}}function M(){var e=p(V(),2),t=e[0];return e[1]?null:t}function A(){e.addEventListener("__darkreader__updateSheet",j,{passive:!0}),Hr&&e.sheet||function(){L=D(),P();var t=function(){D()!==L&&(L=D(),r()),Hr&&e.sheet?P():O=requestAnimationFrame(t)};t()}()}var L=null,O=null;function D(){var e=M();return e?e.length:null}function P(){cancelAnimationFrame(O)}var N=!1;function j(){function e(){N=!1,h||r()}Hr=!0,P(),N||(N=!0,"function"==typeof queueMicrotask?queueMicrotask(e):requestAnimationFrame(e))}function F(){e.removeEventListener("__darkreader__updateSheet",j),P()}function I(){g.disconnect(),h=!0,s&&s.stop(),l&&l.stop(),F()}var B=0;return{details:function(e){var t=k();return t?{rules:t}:(e.secondRound||E||C||(E=!0,n(),T().then((function(e){E=!1,a(),e&&r()})).catch((function(e){E=!1,a()}))),null)},render:function(t,n){var a=k();function o(){return u||((u=e instanceof SVGStyleElement?document.createElementNS("http://www.w3.org/2000/svg","style"):document.createElement("style")).classList.add("darkreader"),u.classList.add("darkreader--sync"),u.media="screen",e.title&&(u.title=e.title),qr.add(u)),l&&l.stop(),_(),null==u.sheet&&(u.textContent=""),function(e){if(e)for(var t=e.cssRules.length-1;t>=0;t--)e.deleteRule(t)}(u.sheet),l?l.run():l=Y(u,"prev-sibling",(function(){R=!0,i()})),u.sheet}function i(){var e=R;R=!1,m.modifySheet({prepareSheet:o,sourceCSSRules:a,theme:t,ignoreImageAnalysis:n,force:e,isAsyncCancelled:function(){return h}}),v=0===u.sheet.cssRules.length,m.shouldRebuildStyle()&&ae((function(){return r()}))}a&&(h=!1,i())},pause:I,destroy:function(){if(I(),K(c),K(u),a(),Gr.has(x)){var e=Gr.get(x);Gr.delete(x),e&&e()}},watch:function(){g.observe(e,b),e instanceof HTMLStyleElement&&A()},restore:function(){u&&(++B>10||(_(),s&&s.skip(),l&&l.skip(),v||(R=!0,r())))}}}function zr(e,t){return d(this,void 0,void 0,(function(){return f(this,(function(r){return[2,new Promise((function(r,n){var a=function(){e.removeEventListener("load",o),e.removeEventListener("error",i),Gr.delete(t)},o=function(){a(),r()},i=function(){a(),n("Linkelement ".concat(t," couldn't be loaded. ").concat(e.href))};Gr.set(t,(function(){a(),n()})),e.addEventListener("load",o,{passive:!0}),e.addEventListener("error",i,{passive:!0}),e.href||i()}))]}))}))}function Qr(e){return d(this,void 0,void 0,(function(){return f(this,(function(t){switch(t.label){case 0:return e.startsWith("data:")?[4,fetch(e)]:[3,3];case 1:return[4,t.sent().text()];case 2:case 4:return[2,t.sent()];case 3:return[4,Et({url:e,responseType:"text",mimeType:"text/css",origin:window.location.origin})]}}))}))}function Kr(e,t,r){return void 0===r&&(r=new Map),d(this,void 0,void 0,(function(){var n,a,o,i,c,u,s,l,d,p;return f(this,(function(f){switch(f.label){case 0:e=function(e,t){return e.replace(ye,(function(e){var r=we(e);try{return"url('".concat(pe(t,r),"')")}catch(t){return e}}))}(e=function(e){return e.replace(Ee,"")}(e=e.replace(_e,"")),t),n=Re(Se,e),f.label=1;case 1:f.trys.push([1,10,11,12]),a=h(n),o=a.next(),f.label=2;case 2:return o.done?[3,9]:(i=o.value,c=we(i.substring(7).trim().replace(/;$/,"").replace(/screen$/,"")),u=pe(t,c),s=void 0,r.has(u)?(s=r.get(u),[3,7]):[3,3]);case 3:return f.trys.push([3,6,,7]),[4,Qr(u)];case 4:return s=f.sent(),r.set(u,s),[4,Kr(s,ke(u),r)];case 5:return s=f.sent(),[3,7];case 6:return f.sent(),s="",[3,7];case 7:e=e.split(i).join(s),f.label=8;case 8:return o=a.next(),[3,2];case 9:return[3,12];case 10:return l=f.sent(),d={error:l},[3,12];case 11:try{o&&!o.done&&(p=a.return)&&p.call(a)}finally{if(d)throw d.error}return[7];case 12:return[2,e=e.trim()]}}))}))}var Yr,Xr,Zr=[],Jr=new Set,en=new Map;function tn(e){var t=e.tagName.toLowerCase();if(!t.includes("-")){var r=e.getAttribute("is");if(!r)return;t=r}en.has(t)||(en.set(t,new Set),function(e){return d(this,void 0,void 0,(function(){return f(this,(function(t){return Jr.has(e)?[2]:[2,new Promise((function(t){if(window.customElements&&"function"==typeof customElements.whenDefined)customElements.whenDefined(e).then((function(){return t()}));else if(nn)an.has(e)?an.get(e).push(t):an.set(e,[t]),document.dispatchEvent(new CustomEvent("__darkreader__addUndefinedResolver",{detail:{tag:e}}));else{var r=function(){var n=en.get(e);n&&n.size>0&&(n.values().next().value.matches(":defined")?t():requestAnimationFrame(r))};requestAnimationFrame(r)}}))]}))}))}(t).then((function(){if(Xr){var e=en.get(t);en.delete(t),Xr(Array.from(e))}}))),en.get(t).add(e)}function rn(e){T&&G(e.querySelectorAll(":not(:defined)"),tn)}var nn=!1;document.addEventListener("__darkreader__inlineScriptsAllowed",(function(){nn=!0}),{once:!0,passive:!0});var an=new Map;function on(e){nn=!0;var t=e.detail.tag;if(Jr.add(t),an.has(t)){var r=an.get(t);an.delete(t),r.forEach((function(e){return e()}))}}function cn(e,t,r){un();var n=new Set(e),a=new WeakMap,o=new WeakMap;function i(e){a.set(e,e.previousElementSibling),o.set(e,e.nextElementSibling)}function c(e){var r=e.createdStyles,c=e.removedStyles,u=e.movedStyles;r.forEach((function(e){return i(e)})),u.forEach((function(e){return i(e)})),c.forEach((function(e){return t=e,a.delete(t),void o.delete(t);var t})),r.forEach((function(e){return n.add(e)})),c.forEach((function(e){return n.delete(e)})),r.size+c.size+u.size>0&&t({created:Array.from(r),removed:Array.from(c),moved:Array.from(u),updated:[]})}function u(e){var t=e.additions,r=e.moves,n=e.deletions,a=new Set,o=new Set,i=new Set;t.forEach((function(e){return Br(e).forEach((function(e){return a.add(e)}))})),n.forEach((function(e){return Br(e).forEach((function(e){return o.add(e)}))})),r.forEach((function(e){return Br(e).forEach((function(e){return i.add(e)}))})),c({createdStyles:a,removedStyles:o,movedStyles:i}),t.forEach((function(e){h(e),rn(e)})),t.forEach((function(e){return!(!(t=e).tagName.includes("-")&&!t.getAttribute("is"))&&tn(e);var t}))}function s(e){var t=new Set(Br(e)),r=new Set,i=new Set,u=new Set;t.forEach((function(e){n.has(e)||r.add(e)})),n.forEach((function(e){t.has(e)||i.add(e)})),t.forEach((function(e){var t;r.has(e)||i.has(e)||(t=e).previousElementSibling===a.get(t)&&t.nextElementSibling===o.get(t)||u.add(e)})),c({createdStyles:r,removedStyles:i,movedStyles:u}),h(e),rn(e)}function l(e){var r=new Set,n=new Set;e.forEach((function(e){var t=e.target;t.isConnected&&(Ir(t)?r.add(t):t instanceof HTMLLinkElement&&t.disabled&&n.add(t))})),r.size+n.size>0&&t({updated:Array.from(r),created:[],removed:Array.from(n),moved:[]})}function d(e){if(!Yr.has(e)){var t=le(e,{onMinorMutations:u,onHugeMutations:s}),r=new MutationObserver(l);r.observe(e,{attributeFilter:["rel","disabled","media","href"],subtree:!0}),Zr.push(t,r),Yr.add(e)}}function f(e){var t=e.shadowRoot;null==t||Yr.has(t)||(d(t),r(t))}function h(e){X(e,f)}e.forEach(i),d(document),h(document.documentElement),Xr=function(e){var r=[];e.forEach((function(e){return $(r,Br(e.shadowRoot))})),t({created:r,updated:[],removed:[],moved:[]}),e.forEach((function(e){var t=e.shadowRoot;null!=t&&(f(e),h(t),rn(t))}))},document.addEventListener("__darkreader__isDefined",on,{passive:!0}),rn(document)}function un(){Zr.forEach((function(e){return e.disconnect()})),Zr.splice(0,Zr.length),Yr=new WeakSet,Xr=null,en.clear(),document.removeEventListener("__darkreader__isDefined",on)}var sn=new WeakMap,ln=new WeakSet;function dn(e){var t=!1;return{render:function(r,n){e.adoptedStyleSheets.forEach((function(a){if(!ln.has(a)){var o=a.rules,i=new CSSStyleSheet;jr().modifySheet({prepareSheet:function(){for(var t=i.cssRules.length-1;t>=0;t--)i.deleteRule(t);return function(t,r){var n=v([],p(e.adoptedStyleSheets),!1),a=n.indexOf(t),o=n.indexOf(r);a!==o-1&&(o>=0&&n.splice(o,1),n.splice(a+1,0,r),e.adoptedStyleSheets=n)}(a,i),sn.set(a,i),ln.add(i),i},sourceCSSRules:o,theme:r,ignoreImageAnalysis:n,force:!1,isAsyncCancelled:function(){return t}})}}))},destroy:function(){t=!0;var r=v([],p(e.adoptedStyleSheets),!1);e.adoptedStyleSheets.forEach((function(e){if(ln.has(e)){var t=r.indexOf(e);t>=0&&r.splice(t,1),sn.delete(e),ln.delete(e)}})),e.adoptedStyleSheets=r}}}function fn(e,t){document.dispatchEvent(new CustomEvent("__darkreader__inlineScriptsAllowed"));var r=Object.getOwnPropertyDescriptor(CSSStyleSheet.prototype,"addRule"),n=Object.getOwnPropertyDescriptor(CSSStyleSheet.prototype,"insertRule"),a=Object.getOwnPropertyDescriptor(CSSStyleSheet.prototype,"deleteRule"),o=Object.getOwnPropertyDescriptor(CSSStyleSheet.prototype,"removeRule"),i=e?Object.getOwnPropertyDescriptor(Document.prototype,"styleSheets"):null,c=t?Object.getOwnPropertyDescriptor(CustomElementRegistry.prototype,"define"):null,u=["baidu.com","baike.baidu.com","ditu.baidu.com","map.baidu.com","maps.baidu.com","haokan.baidu.com","pan.baidu.com","passport.baidu.com","tieba.baidu.com","www.baidu.com"].includes(location.hostname),s=u?Object.getOwnPropertyDescriptor(Element.prototype,"getElementsByTagName"):null,l="www.vy.no"===location.hostname,d=l?Object.getOwnPropertyDescriptor(Node.prototype,"childNodes"):null,f=function(){Object.defineProperty(CSSStyleSheet.prototype,"addRule",r),Object.defineProperty(CSSStyleSheet.prototype,"insertRule",n),Object.defineProperty(CSSStyleSheet.prototype,"deleteRule",a),Object.defineProperty(CSSStyleSheet.prototype,"removeRule",o),document.removeEventListener("__darkreader__cleanUp",f),document.removeEventListener("__darkreader__addUndefinedResolver",m),e&&Object.defineProperty(Document.prototype,"styleSheets",i),t&&Object.defineProperty(CustomElementRegistry.prototype,"define",c),u&&Object.defineProperty(Element.prototype,"getElementsByTagName",s),l&&Object.defineProperty(Node.prototype,"childNodes",d)},h=function(e){customElements.whenDefined(e).then((function(){document.dispatchEvent(new CustomEvent("__darkreader__isDefined",{detail:{tag:e}}))}))},m=function(e){return h(e.detail.tag)};document.addEventListener("__darkreader__cleanUp",f,{passive:!0}),document.addEventListener("__darkreader__addUndefinedResolver",m,{passive:!0});var g=new Event("__darkreader__updateSheet");Object.defineProperty(CSSStyleSheet.prototype,"addRule",Object.assign({},r,{value:function(e,t,n){return r.value.call(this,e,t,n),!this.ownerNode||this.ownerNode.classList&&this.ownerNode.classList.contains("darkreader")||this.ownerNode.dispatchEvent(g),-1}})),Object.defineProperty(CSSStyleSheet.prototype,"insertRule",Object.assign({},n,{value:function(e,t){var r=n.value.call(this,e,t);return!this.ownerNode||this.ownerNode.classList&&this.ownerNode.classList.contains("darkreader")||this.ownerNode.dispatchEvent(g),r}})),Object.defineProperty(CSSStyleSheet.prototype,"deleteRule",Object.assign({},a,{value:function(e){a.value.call(this,e),!this.ownerNode||this.ownerNode.classList&&this.ownerNode.classList.contains("darkreader")||this.ownerNode.dispatchEvent(g)}})),Object.defineProperty(CSSStyleSheet.prototype,"removeRule",Object.assign({},o,{value:function(e){o.value.call(this,e),!this.ownerNode||this.ownerNode.classList&&this.ownerNode.classList.contains("darkreader")||this.ownerNode.dispatchEvent(g)}})),e&&Object.defineProperty(Document.prototype,"styleSheets",Object.assign({},i,{get:function(){var e=this,t=function(){var t=v([],p(i.get.call(e)),!1).filter((function(e){return e.ownerNode&&!(e.ownerNode.classList&&e.ownerNode.classList.contains("darkreader"))}));return t.item=function(e){return t[e]},Object.setPrototypeOf(t,StyleSheetList.prototype)},r=t();return new Proxy(r,{get:function(e,r){return t()[r]}})}})),t&&Object.defineProperty(CustomElementRegistry.prototype,"define",Object.assign({},c,{value:function(e,t,r){h(e),c.value.call(this,e,t,r)}})),u&&Object.defineProperty(Element.prototype,"getElementsByTagName",Object.assign({},s,{value:function(e){var t=this;if("style"!==e)return s.value.call(this,e);var r=function(){var r=s.value.call(t,e);return Object.setPrototypeOf(v([],p(r),!1).filter((function(e){return e&&!(e.classList&&e.classList.contains("darkreader"))})),NodeList.prototype)},n=r();return new Proxy(n,{get:function(e,t){return r()[Number(t)||t]}})}})),l&&Object.defineProperty(Node.prototype,"childNodes",Object.assign({},d,{get:function(){var e=d.get.call(this);return Object.setPrototypeOf(v([],p(e),!1).filter((function(e){return!e.classList||!e.classList.contains("darkreader")})),NodeList.prototype)}}))}var hn=null,pn=!document.hidden,vn={capture:!0,passive:!0};function mn(e){var t=Boolean(hn);hn=function(){document.hidden||(gn(),e(),pn=!0)},t||(document.addEventListener("visibilitychange",hn,vn),window.addEventListener("pageshow",hn,vn),window.addEventListener("focus",hn,vn))}function gn(){document.removeEventListener("visibilitychange",hn,vn),window.removeEventListener("pageshow",hn,vn),window.removeEventListener("focus",hn,vn),hn=null}function bn(){return pn}var yn=wt(),Sn=new Map,wn=[],kn=null,_n=null,En=null,Cn=[],xn=[];function Tn(e,t){void 0===t&&(t=document.head||document);var r=t.querySelector(".".concat(e));return r||((r=document.createElement("style")).classList.add("darkreader"),r.classList.add(e),r.media="screen",r.textContent=""),r}var Rn=new Map;function Vn(e,t){Rn.has(t)&&Rn.get(t).stop(),Rn.set(t,Y(e,"head"))}function Mn(){var e=Tn("darkreader--fallback",document);e.textContent=Gt(kn,{strict:!0}),document.head.insertBefore(e,document.head.firstChild),Vn(e,"fallback");var t=Tn("darkreader--user-agent");t.textContent=Ht(kn,En,kn.styleSystemControls),document.head.insertBefore(t,e.nextSibling),Vn(t,"user-agent");var r,n,a=Tn("darkreader--text");kn.useFont||kn.textStroke>0?a.textContent=(r=kn,(n=[]).push('*:not(pre, pre *, code, .far, .fa, .glyphicon, [class*="vjs-"], .fab, .fa-github, .fas, .material-icons, .icofont, .typcn, mu, [class*="mu-"], .glyphicon, .icon) {'),r.useFont&&r.fontFamily&&n.push(" font-family: ".concat(r.fontFamily," !important;")),r.textStroke>0&&(n.push(" -webkit-text-stroke: ".concat(r.textStroke,"px !important;")),n.push(" text-stroke: ".concat(r.textStroke,"px !important;"))),n.push("}"),n.join("\n")):a.textContent="",document.head.insertBefore(a,e.nextSibling),Vn(a,"text");var o=Tn("darkreader--invert");_n&&Array.isArray(_n.invert)&&_n.invert.length>0?o.textContent=["".concat(_n.invert.join(", ")," {")," filter: ".concat(St(l(l({},kn),{contrast:0===kn.mode?kn.contrast:Ye(kn.contrast-10,0,100)}))," !important;"),"}"].join("\n"):o.textContent="",document.head.insertBefore(o,a.nextSibling),Vn(o,"invert");var i=Tn("darkreader--inline");i.textContent=kr(),document.head.insertBefore(i,o.nextSibling),Vn(i,"inline");var c=Tn("darkreader--override");c.textContent=_n&&_n.css?Dn(_n.css):"",document.head.appendChild(c),Vn(c,"override");var u=Tn("darkreader--variables"),s=Ut(kn),d=kn,f=d.darkSchemeBackgroundColor,h=d.darkSchemeTextColor,p=d.lightSchemeBackgroundColor,v=d.lightSchemeTextColor,m=d.mode,g=0===m?p:f,b=0===m?v:h;g=dt(Le(g),kn),b=mt(Le(b),kn),u.textContent=[":root {"," --darkreader-neutral-background: ".concat(g,";")," --darkreader-neutral-text: ".concat(b,";")," --darkreader-selection-background: ".concat(s.backgroundColorSelection,";")," --darkreader-selection-text: ".concat(s.foregroundColorSelection,";"),"}"].join("\n"),document.head.insertBefore(u,i.nextSibling),Vn(u,"variables");var y=Tn("darkreader--root-vars");document.head.insertBefore(y,u.nextSibling);var S=!(_n&&_n.disableStyleSheetsProxy),w=!(_n&&_n.disableCustomElementRegistryProxy),k=function(e,t){void 0===t&&(t=document.head||document);var r=t.querySelector(".".concat(e));return r||((r=document.createElement("script")).classList.add("darkreader"),r.classList.add(e)),r}("darkreader--proxy");k.append("(".concat(fn,")(").concat(S,", ").concat(w,")")),document.head.insertBefore(k,y.nextSibling),k.remove()}var An=new Set;function Ln(e){var t=Tn("darkreader--inline",e);t.textContent=kr(),e.insertBefore(t,e.firstChild);var r=Tn("darkreader--override",e);r.textContent=_n&&_n.css?Dn(_n.css):"",e.insertBefore(r,t.nextSibling);var n=Tn("darkreader--invert",e);_n&&Array.isArray(_n.invert)&&_n.invert.length>0?n.textContent=["".concat(_n.invert.join(", ")," {")," filter: ".concat(St(l(l({},kn),{contrast:0===kn.mode?kn.contrast:Ye(kn.contrast-10,0,100)}))," !important;"),"}"].join("\n"):n.textContent="",e.insertBefore(n,r.nextSibling),An.add(e)}function On(e){var t=null===e.firstChild;Ln(e),t&&function(e){new MutationObserver((function(t,r){var n,a,o,i;r.disconnect();try{for(var c=h(t),u=c.next();!u.done;u=c.next()){var s=u.value,l=s.type,d=s.removedNodes;if("childList"===l)try{for(var f=(o=void 0,h(d)),p=f.next();!p.done;p=f.next()){var v=p.value,m=v.nodeName,g=v.className;if("STYLE"===m&&["darkreader darkreader--inline","darkreader darkreader--override","darkreader darkreader--invert"].includes(g))return void Ln(e)}}catch(e){o={error:e}}finally{try{p&&!p.done&&(i=f.return)&&i.call(f)}finally{if(o)throw o.error}}}}catch(e){n={error:e}}finally{try{u&&!u.done&&(a=c.return)&&a.call(c)}finally{if(n)throw n.error}}})).observe(e,{childList:!0})}(e)}function Dn(e){return e.replace(/\${(.+?)}/g,(function(e,t){var r=Le(t);return r?ot(r,kn,it):t}))}function Pn(){var e=document.querySelector(".darkreader--fallback");e&&(e.textContent="")}var Nn=0,jn=new Set;function Fn(e){var t=++Nn;var r=$r(e,{update:function(){var e=r.details({secondRound:!0});e&&(Zt.addRulesForMatching(e.rules),Zt.matchVariablesAndDependants(),r.render(kn,Cn))},loadingStart:function(){if(!Z()||!bn()){jn.add(t),"Current amount of styles loading: ".concat(jn.size);var e=document.querySelector(".darkreader--fallback");e.textContent||(e.textContent=Gt(kn,{strict:!1}))}},loadingEnd:function(){jn.delete(t),"Removed loadingStyle ".concat(t,", now awaiting: ").concat(jn.size),0===jn.size&&Z()&&Pn()}});return Sn.set(e,r),r}function In(e){var t=Sn.get(e);t&&(t.destroy(),Sn.delete(e))}var Bn,qn=z((function(e){Sn.forEach((function(e){return e.render(kn,Cn)})),wn.forEach((function(e){return e.render(kn,Cn)})),e&&e()})),Wn=function(){qn.cancel()};function Hn(){0!==jn.size||Pn()}function Un(){var e,t;!function(){Wn();var e=Br(document).filter((function(e){return!Sn.has(e)})).map((function(e){return Fn(e)}));e.map((function(e){return e.details({secondRound:!1})})).filter((function(e){return e&&e.rules.length>0})).forEach((function(e){Zt.addRulesForMatching(e.rules)})),Zt.matchVariablesAndDependants(),Zt.setOnRootVariableChange((function(){var e=Tn("darkreader--root-vars");Zt.putRootVars(e,kn)}));var t=Tn("darkreader--root-vars");Zt.putRootVars(t,kn),Sn.forEach((function(e){return e.render(kn,Cn)})),0===jn.size&&Pn(),e.forEach((function(e){return e.watch()}));var r=function(e){for(var t=[],r=0,n=e.length;r<n;r++)t.push(e[r]);return t}(document.querySelectorAll(wr));X(document.documentElement,(function(e){On(e.shadowRoot);var t=e.shadowRoot.querySelectorAll(wr);t.length>0&&$(r,t)})),r.forEach((function(e){return Vr(e,kn,xn,Cn)})),$n(document)}(),cn(Array.from(Sn.keys()),(function(e){var t=e.created,r=e.updated,n=e.removed,a=e.moved,o=n,i=t.concat(r).concat(a).filter((function(e){return!Sn.has(e)})),c=a.filter((function(e){return Sn.has(e)}));o.forEach((function(e){return In(e)}));var u=i.map((function(e){return Fn(e)}));u.map((function(e){return e.details({secondRound:!1})})).filter((function(e){return e&&e.rules.length>0})).forEach((function(e){Zt.addRulesForMatching(e.rules)})),Zt.matchVariablesAndDependants(),u.forEach((function(e){return e.render(kn,Cn)})),u.forEach((function(e){return e.watch()})),c.forEach((function(e){return Sn.get(e).restore()}))}),(function(e){On(e),$n(e)})),e=function(e){if(Vr(e,kn,xn,Cn),e===document.documentElement&&(e.getAttribute("style")||"").includes("--")){Zt.matchVariablesAndDependants();var t=Tn("darkreader--root-vars");Zt.putRootVars(t,kn)}},t=function(e){On(e);var t=e.querySelectorAll(wr);t.length>0&&G(t,(function(e){return Vr(e,kn,xn,Cn)}))},Cr(document,e,t),X(document.documentElement,(function(r){Cr(r.shadowRoot,e,t)})),ee(Hn)}function Gn(){var e,t;Mn(),bn()||kn.immediateModify?Un():mn(Un),e=kn,(t=document.querySelector(Ar))?Dr(t,e):(Or&&Or.disconnect(),(Or=new MutationObserver((function(t){e:for(var r=0;r<t.length;r++)for(var n=t[r].addedNodes,a=0;a<n.length;a++){var o=n[a];if(o instanceof HTMLMetaElement&&o.name===Mr){Or.disconnect(),Or=null,Dr(o,e);break e}}}))).observe(document.head,{childList:!0}))}function $n(e){try{if(Array.isArray(e.adoptedStyleSheets)&&e.adoptedStyleSheets.length>0){var t=dn(e);wn.push(t),t.render(kn,Cn)}}catch(e){}}function zn(){Sn.forEach((function(e){return e.pause()})),G(Rn.values(),(function(e){return e.stop()})),Rn.clear(),un(),_r.forEach((function(e){return e.disconnect()})),Er.forEach((function(e){return e.disconnect()})),_r.clear(),Er.clear(),te(Hn),ne.clear()}function Qn(){if(document.querySelector('meta[name="darkreader-lock"]'))return!0;var e,t=document.querySelector('meta[name="darkreader"]');return t?t.content!==yn:((e=document.createElement("meta")).name="darkreader",e.content=yn,document.head.appendChild(e),(Bn=new MutationObserver((function(){document.querySelector('meta[name="darkreader-lock"]')&&(Bn.disconnect(),Yn())}))).observe(document.head,{childList:!0,subtree:!0}),!1)}function Kn(e,t,r){if(kn=e,(_n=t)?(Cn=Array.isArray(_n.ignoreImageAnalysis)?_n.ignoreImageAnalysis:[],xn=Array.isArray(_n.ignoreInlineStyle)?_n.ignoreInlineStyle:[]):(Cn=[],xn=[]),kn.immediateModify&&(Z=function(){return!0}),En=r,document.head){if(Qn())return void Yn();document.documentElement.setAttribute("data-darkreader-mode","dynamic"),document.documentElement.setAttribute("data-darkreader-scheme",kn.mode?"dark":"dimmed"),Gn()}else{if(!S){var n=Tn("darkreader--fallback");document.documentElement.appendChild(n),n.textContent=Gt(kn,{strict:!0})}var a=new MutationObserver((function(){if(document.head){if(a.disconnect(),Qn())return void Yn();Gn()}}));a.observe(document,{childList:!0,subtree:!0})}}function Yn(){document.documentElement.removeAttribute("data-darkreader-mode"),document.documentElement.removeAttribute("data-darkreader-scheme"),Zt.clear(),de.clear(),gn(),Wn(),zn(),Xt(),Me.clear(),Ae.clear(),K(document.querySelector(".darkreader--fallback")),document.head&&(!function(){Or&&(Or.disconnect(),Or=null);var e=document.querySelector(Ar);e&&Lr&&(e.content=Lr)}(),K(document.head.querySelector(".darkreader--user-agent")),K(document.head.querySelector(".darkreader--text")),K(document.head.querySelector(".darkreader--invert")),K(document.head.querySelector(".darkreader--inline")),K(document.head.querySelector(".darkreader--override")),K(document.head.querySelector(".darkreader--variables")),K(document.head.querySelector(".darkreader--root-vars")),K(document.head.querySelector('meta[name="darkreader"]')),document.dispatchEvent(new CustomEvent("__darkreader__cleanUp")),K(document.head.querySelector(".darkreader--proxy"))),An.forEach((function(e){K(e.querySelector(".darkreader--inline")),K(e.querySelector(".darkreader--override"))})),An.clear(),G(Sn.keys(),(function(e){return In(e)})),jn.clear(),Gr.clear(),G(document.querySelectorAll(".darkreader"),K),wn.forEach((function(e){e.destroy()})),wn.splice(0),Bn&&Bn.disconnect()}var Xn=/url\(\"(blob\:.*?)\"\)/g;function Zn(e){return d(this,void 0,void 0,(function(){var t,r;return f(this,(function(n){switch(n.label){case 0:return t=[],Re(Xn,e,1).forEach((function(e){var r=M(e);t.push(r)})),[4,Promise.all(t)];case 1:return r=n.sent(),[2,e.replace(Xn,(function(){return'url("'.concat(r.shift(),'")')}))]}}))}))}var Jn='/*\n _______\n / \\\n .==. .==.\n (( ))==(( ))\n / "==" "=="\\\n /____|| || ||___\\\n ________ ____ ________ ___ ___\n | ___ \\ / \\ | ___ \\ | | / /\n | | \\ \\ / /\\ \\ | | \\ \\| |_/ /\n | | ) / /__\\ \\ | |__/ /| ___ \\\n | |__/ / ______ \\| ____ \\| | \\ \\\n_______|_______/__/ ____ \\__\\__|___\\__\\__|___\\__\\____\n| ___ \\ | ____/ / \\ | ___ \\ | ____| ___ \\\n| | \\ \\| |___ / /\\ \\ | | \\ \\| |___| | \\ \\\n| |__/ /| ____/ /__\\ \\ | | ) | ____| |__/ /\n| ____ \\| |__/ ______ \\| |__/ /| |___| ____ \\\n|__| \\__\\____/__/ \\__\\_______/ |______|__| \\__\\\n https://darkreader.org\n*/\n\n/*! Dark reader generated CSS | Licensed under MIT https://github.com/darkreader/darkreader/blob/main/LICENSE */\n';function ea(){return d(this,void 0,void 0,(function(){function e(e,r){var n=document.querySelector(e);n&&n.textContent&&(t.push("/* ".concat(r," */")),t.push(n.textContent),t.push(""))}var t,r,n,a,o;return f(this,(function(i){switch(i.label){case 0:return t=[Jn],e(".darkreader--fallback","Fallback Style"),e(".darkreader--user-agent","User-Agent Style"),e(".darkreader--text","Text Style"),e(".darkreader--invert","Invert Style"),e(".darkreader--variables","Variables Style"),r=[],document.querySelectorAll(".darkreader--sync").forEach((function(e){G(e.sheet.cssRules,(function(e){e&&e.cssText&&r.push(e.cssText)}))})),r.length?(n=function(e){function t(e){return e.replace(/^\s+/,"")}function r(e){return 0===e?"":" ".repeat(4*e)}if(e.length<5e4)for(var n=/[^{}]+{\s*}/;n.test(e);)e=e.replace(n,"");for(var a=e.replace(/\s{2,}/g," ").replace(/\{/g,"{\n").replace(/\}/g,"\n}\n").replace(/\;(?![^\(|\"]*(\)|\"))/g,";\n").replace(/\,(?![^\(|\"]*(\)|\"))/g,",\n").replace(/\n\s*\n/g,"\n").split("\n"),o=0,i=[],c=0,u=a.length;c<u;c++){var s="".concat(a[c],"\n");s.includes("{")?i.push(r(o++)+t(s)):s.includes("}")?i.push(r(--o)+t(s)):i.push(r(o)+t(s))}return i.join("").trim()}(r.join("\n")),t.push("/* Modified CSS */"),o=(a=t).push,[4,Zn(n)]):[3,2];case 1:o.apply(a,[i.sent()]),t.push(""),i.label=2;case 2:return e(".darkreader--override","Override Style"),[2,t.join("\n")]}}))}))}var ta=!1,ra=function(){try{return window.self!==window.top}catch(e){return console.warn(e),!0}}();function na(e,t){void 0===e&&(e={}),void 0===t&&(t=null);var r=l(l({},U),e);if(r.engine!==P.dynamicTheme)throw new Error("Theme engine is not supported.");Kn(r,t,ra),ta=!0}function aa(){Yn(),ta=!1}var oa=matchMedia("(prefers-color-scheme: dark)"),ia={themeOptions:null,fixes:null};function ca(){oa.matches?na(ia.themeOptions,ia.fixes):aa()}var ua=function(e){O=e||L};e.auto=function(e,t){void 0===e&&(e={}),void 0===t&&(t=null),e?(ia={themeOptions:e,fixes:t},ca(),x?oa.addEventListener("change",ca):oa.addListener(ca)):(x?oa.removeEventListener("change",ca):oa.removeListener(ca),aa())},e.disable=aa,e.enable=na,e.exportGeneratedCSS=function(){return d(this,void 0,void 0,(function(){return f(this,(function(e){switch(e.label){case 0:return[4,ea()];case 1:return[2,e.sent()]}}))}))},e.isEnabled=function(){return ta},e.setFetchMethod=ua,Object.defineProperty(e,"__esModule",{value:!0})}));
|
|
//# sourceMappingURL=/sm/4cbb07793c4d01b4eb9bbeba973323dc228cabc153db0caed70235e3e8c8a641.map
|