PageSourceSearch

https://blog.sddc.be/wp-content/plugins/dark-mode-toggle/assets/js/darkmode-js.min.js?ver=1.7.6

js sddc.be collected 2026-10-06 06:43:51 UTC 8,353 bytes, 1 lines download raw bytes

vendor: 6,176 bytes, line 1
1!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("darkmode-js",[],t):"object"==typeof exports?exports["darkmode-js"]=t():e["darkmode-js"]=t()}("undefined"!=typeof self?self:this,function(){return function(e){var t={};function n(o){if(t[o])return t[o].exports;var a=t[o]={i:o,l:!1,exports:{}};return e[o].call(a.exports,a,a.exports,n),a.l=!0,a.exports}return n.m=e,n.c=t,n.d=function(e,t,o){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)n.d(o,a,function(t){return e[t]}.bind(null,a));return o},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=0)}([function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var o=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,n):{};o.get||o.set?Object.defineProperty(t,n,o):t[n]=e[n]}return t.default=e,t}(n(1));var a=o.default;t.default=a,o.IS_BROWSER&&function(e){e.Darkmode=o.default}(window),e.exports=t.default},function(e,t,n){"use strict";function o(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.IS_BROWSER=void 0;var a="undefined"!=typeof window;t.IS_BROWSER=a;var r=function(){function e(t){if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),a){t=Object.assign({},{bottom:"32px",right:"32px",left:"unset",top:"unset",width:"40px",height:"40px",borderRadius:"40px",fontSize:"18px",time:"0s",mixColor:"#fff",backgroundColor:"transparent",buttonColorLight:"#656565",buttonColorTLight:"#eeeeee",buttonColorDark:"#4f4f4f",buttonColorTDark:"#cacaca",label:"",saveInCookies:!0,autoMatchOsTheme:!1,onDefault:!1,buttonAriaLabel:"Toggle dark mode"},t);var n="\n      .darkmode-layer {\n        position: fixed;\n        pointer-events: none;\n        background: ".concat(t.mixColor,";\n        transition: all ").concat(t.time," ease;\n        mix-blend-mode: difference;\n      }\n      .darkmode-layer--button {\n        width: ").concat(t.width,";\n        height: ").concat(t.height,";\n        border-radius: ").concat(t.borderRadius,";\n        right: ").concat(t.right,";\n        bottom: ").concat(t.bottom,";\n        left: ").concat(t.left,";\n        top: ").concat(t.top,";\n        transform: scale(0.98);\n      }\n      .darkmode-layer--simple {\n        width: 100%;\n        height: 120vh;\n        top: 0;\n        bottom: 0;\n        left: 0;\n        right: 0;\n        transform: scale(1) !important;\n      }\n      .darkmode-layer--expanded {\n        transform: scale(100);\n        border-radius: 0;\n      }\n      .darkmode-layer--no-transition {\n        transition: none;\n      }\n      .darkmode-toggle {\n        min-width: unset;\n        width: ").concat(t.width,";\n        height: ").concat(t.height,";\n        position: fixed;\n        padding: 0 !important;\n        margin: 0;\n        border-radius: ").concat(t.borderRadius," !important;\n        border: none;\n        right: ").concat(t.right,";\n        bottom: ").concat(t.bottom,";\n        left: ").concat(t.left,";\n        top: ").concat(t.top,";\n        font-size: ").concat(t.fontSize," !important;\n        font-family: sans-serif;\n        font-weight: 600;\n        line-height: 1 !important;\n        cursor: pointer;\n        transition: .3s background-color ease;\n        display: flex;\n        justify-content: center;\n        align-items: center;\n      }\n      .darkmode-toggle,\n      .darkmode-toggle:hover,\n      .darkmode-toggle:focus,\n      .darkmode-toggle:active {\n        box-shadow: none !important;\n        background: ").concat(t.buttonColorLight,";\n        color: ").concat(t.buttonColorTLight,";\n      }\n      .darkmode-toggle--white,\n      .darkmode-toggle--white:hover,\n      .darkmode-toggle--white:focus,\n      .darkmode-toggle--white:active {\n        background: ").concat(t.buttonColorDark,";\n        color: ").concat(t.buttonColorTDark,";\n      }\n      .darkmode-toggle--inactive {\n        display: none;\n      }\n      .darkmode-background {\n        background: ").concat(t.backgroundColor,";\n        position: fixed;\n        pointer-events: none;\n        z-index: -10;\n        width: 100%;\n        height: 120vh;\n        top: 0;\n        left: 0;\n      }\n      img, .darkmode-ignore {\n        isolation: isolate;\n      }\n      @media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) {\n        .darkmode-toggle {display: none !important}\n      }\n      .darkmode-toggle span {\n        display: contents;\n      }\n      .darkmode-toggle img.emoji {\n        display: inline;\n        border: none;\n        box-shadow: none;\n        height: 1em;\n        width: 1em;\n        margin: 0 0.07em;\n        vertical-align: -0.1em;\n        background: none;\n        padding: 0;\n      }\n    "),o=document.createElement("div"),r=document.createElement("button"),i=document.createElement("span"),d=document.createElement("div");i.innerHTML=t.label,r.appendChild(i),r.classList.add("darkmode-toggle--inactive"),o.classList.add("darkmode-layer"),d.classList.add("darkmode-background");var s="true"===window.localStorage.getItem("darkmode"),c=t.autoMatchOsTheme&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches,l=null===window.localStorage.getItem("darkmode");
1t.saveInCookies&&!0===s||t.saveInCookies&&l&&(t.onDefault||c)||!t.saveInCookies&&(t.onDefault||c)?(o.classList.add("darkmode-layer--expanded","darkmode-layer--simple","darkmode-layer--no-transition"),r.classList.add("darkmode-toggle--white"),r.setAttribute("aria-checked","true"),document.body.classList.add("darkmode--activated")):r.setAttribute("aria-checked","false"),document.body.insertBefore(r,document.body.firstChild),document.body.insertBefore(o,document.body.firstChild),document.body.insertBefore(d,document.body.firstChild),this.addStyle(n),this.button=r,this.span=i,this.layer=o,this.saveInCookies=t.saveInCookies,this.time=t.time,this.buttonAriaLabel=t.buttonAriaLabel}}var t,n,r;return t=e,(n=[{key:"addStyle",value:function(e){var t=document.createElement("link");t.setAttribute("rel","stylesheet"),t.setAttribute("type","text/css"),t.setAttribute("href","data:text/css;charset=UTF-8,"+encodeURIComponent(e)),document.head.appendChild(t)}},{key:"showWidget",value:function(){var e=this;if(a){var t=this.button,n=this.layer,o=1e3*parseFloat(this.time);t.classList.add("darkmode-toggle"),t.classList.remove("darkmode-toggle--inactive"),t.setAttribute("aria-label",this.buttonAriaLabel),t.setAttribute("role","checkbox"),n.classList.add("darkmode-layer--button"),t.addEventListener("click",function(){var a=e.isActivated();a?(n.classList.remove("darkmode-layer--simple"),t.setAttribute("disabled",!0),setTimeout(function(){n.classList.remove("darkmode-layer--no-transition"),n.classList.remove("darkmode-layer--expanded"),t.setAttribute("aria-checked","false"),t.removeAttribute("disabled")},1)):(n.classList.add("darkmode-layer--expanded"),t.setAttribute("disabled",!0),setTimeout(function(){n.classList.add("darkmode-layer--no-transition"),n.classList.add("darkmode-layer--simple"),t.setAttribute("aria-checked","true"),t.removeAttribute("disabled")},o)),t.classList.toggle("darkmode-toggle--white"),document.body.classList.toggle("darkmode--activated"),window.localStorage.setItem("darkmode",!a)})}}},{key:"isActivated",value:function(){return a?document.body.classList.contains("darkmode--activated"):null}}])&&o(t.prototype,n),r&&o(t,r),e}();t.default=r}])});

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.