/******/ (() => { // webpackBootstrap
/******/ 	var __webpack_modules__ = ({

/***/ 6907:
/***/ ((__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";

// EXTERNAL MODULE: ./vendor/webext-sdk/dist/ewe-api.js
var ewe_api = __webpack_require__(3817);
;// CONCATENATED MODULE: ./node_modules/@eyeo/snippets/webext/ml.mjs
/*!
 * This file is part of eyeo's Anti-Circumvention Snippets module (@eyeo/snippets),
 * Copyright (C) 2006-present eyeo GmbH
 * 
 * @eyeo/snippets is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 * 
 * @eyeo/snippets is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with @eyeo/snippets.  If not, see <http://www.gnu.org/licenses/>.
 */

const callback = (environment, ...filters) => {
const e=Proxy,{apply:t,bind:r,call:n}=Function,P=n.bind(t),a=n.bind(r),o=n.bind(n),u={get:(e,t)=>a(n,e[t])},s=t=>new e(t,u),v={get:(e,t)=>a(e[t],e)},i=t=>new e(t,v),{assign:l,defineProperties:c,freeze:O,getOwnPropertyDescriptor:D,getOwnPropertyDescriptors:j,getPrototypeOf:h}=i(Object);s({});const{species:p}=Symbol,m={get(e,t){const r=e[t];class n extends r{}const P=j(r.prototype);delete P.constructor,O(c(n.prototype,P));const a=j(r);return delete a.length,delete a.prototype,a[p]={value:n},O(c(n,a))}},g=t=>new e(t,m),b="undefined"!=typeof environment?environment:{};"undefined"==typeof globalThis&&(window.globalThis=window);const{apply:T,ownKeys:z}=i(Reflect),d="world"in b,y=d&&"ISOLATED"===b.world,w=d&&"MAIN"===b.world,L="object"==typeof chrome&&!!chrome.runtime,f="object"==typeof browser&&!!browser.runtime,I=!w&&(y||L||f),S=e=>I?e:A(e,E(e)),{create:A,defineProperties:x,defineProperty:Y,freeze:k,getOwnPropertyDescriptor:C,getOwnPropertyDescriptors:E}=i(Object),Q=i(globalThis),W=I?globalThis:g(globalThis),{Map:U,RegExp:q,Set:G,WeakMap:M,WeakSet:K}=W,N=(e,t,r=null)=>{const n=z(t);for(const P of z(e)){if(n.includes(P))continue;const a=C(e,P);if(r&&"value"in a){const{value:e}=a;"function"==typeof e&&(a.value=r(e))}Y(t,P,a)}},R=e=>{const t=W[e];class r extends t{}const{toString:n,valueOf:P}=t.prototype;x(r.prototype,{toString:{value:n},valueOf:{value:P}});const a=e.toLowerCase(),o=e=>function(){const t=T(e,this,arguments);return typeof t===a?new r(t):t};return N(t,r,o),N(t.prototype,r.prototype,o),r},F=k({frozen:new M,hidden:new K,iframePropertiesToAbort:{read:new G,write:new G},abortedIframes:new M}),B=new q("^[A-Z]");var Z=new Proxy(new U([["chrome",I&&(L&&chrome||f&&browser)||void 0],["isExtensionContext",I],["variables",F],["console",S(console)],["document",globalThis.document],["performance",S(performance)],["JSON",S(JSON)],["Map",U],["Math",S(Math)],["Number",I?Number:R("Number")],["RegExp",q],["Set",G],["String",I?String:R("String")],["WeakMap",M],["WeakSet",K],["MouseEvent",MouseEvent]]),{get(e,t){if(e.has(t))return e.get(t);let r=globalThis[t];return"function"==typeof r&&(r=(B.test(t)?W:Q)[t]),e.set(t,r),r},has:(e,t)=>e.has(t)});const V={WeakSet:WeakSet,WeakMap:WeakMap,WeakValue:class{has(){return!1}set(){}}},{apply:X}=Reflect;const{Map:H,WeakMap:J,WeakSet:_,setTimeout:$}=Z;let ee=!0,te=e=>{e.clear(),ee=!ee};var re=function(e){const{WeakSet:t,WeakMap:r,WeakValue:n}=this||V,P=new t,a=new r,o=new n;return function(t){if(P.has(t))return t;if(a.has(t))return a.get(t);if(o.has(t))return o.get(t);const r=X(e,this,arguments);return P.add(r),r!==t&&("object"==typeof t&&t?a:o).set(t,r),r}}.bind({WeakMap:J,WeakSet:_,WeakValue:class extends H{set(e,t){return ee&&(ee=!ee,$(te,0,this)),super.set(e,t)}}});const{concat:ne,includes:Pe,join:ae,reduce:oe,unshift:ue}=s([]),se=g(globalThis),{Map:ve,WeakMap:ie}=se,le=new ve,ce=t=>{const r=(e=>{const t=[];let r=e;for(;r;){if(le.has(r))ue(t,le.get(r));else{const e=j(r);le.set(r,e),ue(t,e)}r=h(r)}return ue(t,{}),P(l,null,t)})("function"==typeof t?t.prototype:t),n={get(e,t){if(t in r){const{value:n,get:P}=r[t];if(P)return o(P,e);if("function"==typeof n)return a(n,e)}return e[t]},set(e,t,n){if(t in r){const{set:P}=r[t];if(P)return o(P,e,n),!0}return e[t]=n,!0}};return t=>new e(t,n)},{isExtensionContext:Oe,Array:De,Number:je,String:he,Object:pe}=Z,{isArray:me}=De,{getOwnPropertyDescriptor:ge,setPrototypeOf:be}=pe,{toString:Te}=pe.prototype,{slice:ze}=he.prototype,{get:de}=ge(Node.prototype,"nodeType"),ye=Oe?{}:{Attr:ce(Attr),CanvasRenderingContext2D:ce(CanvasRenderingContext2D),CSSStyleDeclaration:ce(CSSStyleDeclaration),Document:ce(Document),Element:ce(Element),HTMLCanvasElement:ce(HTMLCanvasElement),HTMLElement:ce(HTMLElement),HTMLImageElement:ce(HTMLImageElement),HTMLScriptElement:ce(HTMLScriptElement),MutationRecord:ce(MutationRecord),Node:ce(Node),ShadowRoot:ce(ShadowRoot),get CSS2Properties(){return ye.CSSStyleDeclaration}},we=(e,t)=>{if("Element"!==t&&t in ye)return ye[t](e);if(me(e))return be(e,De.prototype);const r=(e=>o(ze,o(Te,e),8,-1))(e);if(r in ye)return ye[r](e);if(r in Z)return be(e,Z[r].prototype);if("nodeType"in e)switch(o(de,e)){case 1:if(!(t in ye))throw new Error("unknown hint "+t);return ye[t](e);case 2:return ye.Attr(e);case 3:return ye.Node(e);case 9:return ye.Document(e)}throw new Error("unknown brand "+r)};var Le=Oe?e=>e===window||e===globalThis?Z:e:re(((e,t="Element")=>{if(e===window||e===globalThis)return Z;switch(typeof e){case"object":return e&&we(e,t);case"string":return new he(e);case"number":return new je(e);default:throw new Error("unsupported value")}}));let{document:fe,getComputedStyle:Ie,isExtensionContext:Se,variables:Ae,Array:xe,MutationObserver:Ye,Object:ke,XPathEvaluator:Ce,XPathExpression:Ee,XPathResult:Qe}=Le(window),{querySelectorAll:We}=fe,Ue=We&&a(We,fe);const{assign:qe,setPrototypeOf:Ge}=ke;class Me extends Ee{evaluate(...e){return Ge(P(super.evaluate,this,e),Qe.prototype)}}class Ke extends Ce{createExpression(...e){return Ge(P(super.createExpression,this,e),Me.prototype)}}function Ne(e){if(Ae.hidden.has(e))return;!function(e){Se&&"function"==typeof checkElement&&checkElement(e)}(e),Ae.hidden.add(e);let{style:t}=Le(e),r=Le(t,"CSSStyleDeclaration"),n=Le([]),{debugCSSProperties:P}=b;for(let[e,t]of P||[["display","none"]])r.setProperty(e,t,"important"),n.push([e,r.getPropertyValue(e)]);new Ye((()=>{for(let[e,t]of n){let n=r.getPropertyValue(e),P=r.getPropertyPriority(e);n==t&&"important"==P||r.setProperty(e,t,"important")}})).observe(e,{attributes:!0,attributeFilter:["style"]})}function Re(e){let t=e;if(t.startsWith("xpath(")&&t.endsWith(")")){let e=t.slice(6,-1),r=(new Ke).createExpression(e,null),n=Qe.ORDERED_NODE_SNAPSHOT_TYPE;return e=>{if(!e)return;let t=r.evaluate(fe,n,null),{snapshotLength:P}=t;for(let r=0;r<P;r++)e(t.snapshotItem(r))}}return t=>Ue(e).forEach(t)}function Fe(e,t,r){let n;null==r&&(r=t);const P=()=>{for(const P of Ue(r)){const r=Le(P).closest(t);r&&e(P,r)&&(n(),Ne(r))}};return qe(new Ye(P),{race(e){n=e,this.observe(fe,{childList:!0,characterData:!0,subtree:!0}),P()}})}function Be(e,t,r){let n=Le(t,"CSSStyleDeclaration");if("none"==n.getPropertyValue("display"))return!1;let P=n.getPropertyValue("visibility");if("hidden"==P||"collapse"==P)return!1;if(!r||e==r)return!0;let a=Le(e).parentElement;return!a||Be(a,Ie(a),r)}function Ze(e){let t=Ie(e),{cssText:r}=t;if(r)return r;for(let e of t)r+=`${e}: ${t[e]}; `;return Le(r).trim()}let{Math:Ve,RegExp:Xe}=Le(window);function He(e){let{length:t}=e;if(t>1&&"/"===e[0]){let r="/"===e[t-1];if(r||t>2&&Le(e).endsWith("/i")){let t=[Le(e).slice(1,r?-1:-2)];return r||t.push("i"),new Xe(...t)}}return new Xe(Le(e).replace(/[-/\\^$*+?.()|[\]{}]/g,"\\$&"))}let Je=!1;function _e(){return Je}const{console:$e}=Le(window),et=()=>{};function tt(...e){_e()&&Le(e).unshift("%c DEBUG","font-weight: bold"),$e.log(...e)}function rt(e){return a(_e()?tt:et,null,e)}let{Array:nt,Error:Pt,Map:at,parseInt:ot}=Le(window),ut=null,st=null;function vt(e,t){if(null===ut)return et;let r=ut,{participants:n}=r;return n.set(P,t),P;function P(){if(r.winners<1)return;if(rt("race")(`${e} won the race`),r===ut)st.push(P);else if(n.delete(P),--r.winners<1){for(let e of n.values())e();n.clear()}}}let{MutationObserver:it}=Le(window);let{clearTimeout:lt,fetch:ct,getComputedStyle:Ot,setTimeout:Dt,Map:jt,MutationObserver:ht,Uint8Array:pt}=Le(window);let mt=new jt;function gt(e,{as:t="arrayBuffer",cleanup:r=6e4}={}){let n=t+":"+e,P=mt.get(n)||{remove:()=>mt.delete(n),result:null,timer:0};return lt(P.timer),P.timer=Dt(P.remove,r),P.result||(P.result=ct(e).then((e=>e[t]())).catch(P.remove),mt.set(n,P)),P.result}const{parseFloat:bt,Math:Tt,MutationObserver:zt,WeakSet:dt}=Le(window),{min:yt}=Tt,wt=(e,t)=>{const r=e.length+1,n=t.length+1,P=[[0]];let a=0,o=0;for(;++a<n;)P[0][a]=a;for(a=0;++a<r;){const r=e[o];let u=0,s=0;for(P[a]=[a];++u<n;)P[a][u]=yt(P[o][u]+1,P[a][s]+1,P[o][s]+(r!=t[s])),++s;++o}return P[r-1][n-1]};let{getComputedStyle:Lt,Map:ft,WeakSet:It,parseFloat:St}=Le(window);const{ELEMENT_NODE:At,TEXT_NODE:xt}=Node;let{MutationObserver:Yt}=Le(window);let{getComputedStyle:kt,MutationObserver:Ct,WeakSet:Et}=Le(window);Le(window);const Qt={mark(){},end(){},toString:()=>"{mark(){},end(){}}"};let{MutationObserver:Wt}=Le(window);const{ELEMENT_NODE:Ut}=Node;let{parseInt:qt,setTimeout:Gt,Error:Mt,MouseEvent:Kt,MutationObserver:Nt,WeakSet:Rt}=Le(window);let{parseInt:Ft,setTimeout:Bt,Error:Zt,MouseEvent:Vt,MutationObserver:Xt,WeakSet:Ht}=Le(window);const Jt={log:tt,race:function(e,t="1"){switch(e){case"start":ut={winners:ot(t,10)||1,participants:new at},st=new nt;break;case"end":case"finish":case"stop":ut=null;for(let e of st)e();st=null;break;default:throw new Pt(`Invalid action: ${e}`)}},debug:function(){Je=!0},"hide-if-matches-xpath":function(e){let{mark:t,end:r}=Qt,n=Re(`xpath(${e})`),P=()=>{t(),n((e=>{o(),Le(e).nodeType===Ut?Ne(e):Le(e).textContent=""})),r()},a=new Wt(P),o=vt("hide-if-matches-xpath",(()=>a.disconnect()));a.observe(document,{characterData:!0,childList:!0,subtree:!0}),P()},"hide-if-contains":function(e,t="*",r=null){let n=He(e);const P=Fe((e=>n.test(Le(e).textContent)),t,r);P.race(vt("hide-if-contains",(()=>{P.disconnect()})))},"hide-if-contains-similar-text":function(e,t,r=null,n=0,P=0){const a=new dt,o=rt("hide-if-contains-similar-text"),u=Le(e),{length:s}=u,v=s+bt(n)||0,i=Le([...u]).sort(),l=bt(P)||1/0;null==r&&(r=t),o("Looking for similar text: "+u);const c=()=>{for(const e of Ue(r)){if(a.has(e))continue;a.add(e);const{innerText:r}=Le(e),P=yt(l,r.length-v+1);for(let a=0;a<P;a++){const P=Le(r).substr(a,v);if(wt(i,Le([...P]).sort())-n<=0){const r=Le(e).closest(t);if(o("Found similar text: "+u,r),r){D(),Ne(r);break}}}}};let O=new zt(c),D=vt("hide-if-contains-similar-text",(()=>O.disconnect()));O.observe(document,{childList:!0,characterData:!0,subtree:!0}),c()},"hide-if-contains-visible-text":function(e,t,r=null,...n){let P=Le([]);const a=new ft([["-snippet-box-margin","2"]]);for(let e of n){e=Le(e);let t=e.indexOf(":");if(t<0)continue;let r=e.slice(0,t).trim().toString(),n=e.slice(t+1).trim().toString();r&&n&&(a.has(r)?a.set(r,n):P.push([r,n]))}let o=Le([["opacity","0"],["font-size","0px"],["color","rgba(0, 0, 0, 0)"]]),u=new ft(o.concat(P));function s(e,t){t||(t=Lt(e)),t=Le(t);for(const[e,r]of u){if(He(r).test(t.getPropertyValue(e)))return!1}let r=t.getPropertyValue("color");return t.getPropertyValue("background-color")!=r}function v(e,t){let r=Lt(e,t);if(!Be(e,r)||!s(e,r))return"";let{content:n}=Le(r);if(n&&"none"!==n){let t=Le([]);return n=Le(n).trim().replace(/(["'])(?:(?=(\\?))\2.)*?\1/g,(e=>""+(t.push(Le(e).slice(1,-1))-1))),n=n.replace(/\s*attr\(\s*([^\s,)]+)[^)]*?\)\s*/g,((t,r)=>Le(e).getAttribute(r)||"")),n.replace(/\x01(\d+)/g,((e,r)=>t[r]))}return""}function i(e,t,{boxMargin:r=2}={}){const n=Le(e).getBoundingClientRect(),P=Le(t).getBoundingClientRect(),a=P.left-r,o=P.right+r,u=P.top-r,s=P.bottom+r;return a<=n.left&&n.left<=o&&u<=n.top&&n.top<=s&&u<=n.bottom&&n.bottom<=s&&a<=n.right&&n.right<=o}function l(e,t,r,n,{boxMargin:P=2}={}){let a=!r;if(a&&(r=Lt(e)),!Be(e,r,a&&t))return"";n||"hidden"!==Le(r).getPropertyValue("overflow-x")&&"hidden"!==Le(r).getPropertyValue("overflow-y")||(n=e);let o=v(e,":before");for(let t of Le(e).childNodes)switch(Le(t).nodeType){case At:o+=l(t,e,Lt(t),n,{boxMargin:P});break;case xt:n?i(e,n,{boxMargin:P})&&s(e,r)&&(o+=Le(t).nodeValue):s(e,r)&&(o+=Le(t).nodeValue)}return o+v(e,":after")}const c=a.get("-snippet-box-margin"),O=St(c)||0;let D=He(e),j=new It;const h=Fe(((e,t)=>{if(j.has(e))return!1;j.add(e);let r=l(e,t,null,null,{boxMargin:O}),n=D.test(r);return _e()&&r.length&&tt(n,D,r),n}),t,r);h.race(vt("hide-if-contains-visible-text",(()=>{h.disconnect()})))},"hide-if-contains-and-matches-style":function(e,t="*",r=null,n=null,P=null){null==r&&(r=t);let a=He(e),o=n?He(n):null,u=P?He(P):null,s=()=>{for(let e of Ue(r))if(a.test(Le(e).textContent)&&(!u||u.test(Ze(e)))){let r=Le(e).closest(t);!r||o&&!o.test(Ze(r))||(i(),Ne(r))}},v=new it(s),i=vt("hide-if-contains-and-matches-style",(()=>v.disconnect()));v.observe(document,{childList:!0,characterData:!0,subtree:!0}),s()},"hide-if-has-and-matches-style":function(e,t="*",r=null,n=null,P=null){null==r&&(r=t);let a=n?He(n):null,o=P?He(P):null,u=()=>{for(let n of Ue(r))if(Le(n).querySelector(e)&&(!o||o.test(Ze(n)))){let e=Le(n).closest(t);!e||a&&!a.test(Ze(e))||(v(),Ne(e))}},s=new Yt(u),v=vt("hide-if-has-and-matches-style",(()=>s.disconnect()));s.observe(document,{childList:!0,subtree:!0}),u()},"hide-if-labelled-by":function(e,t,r=null){let n=null==r,P=He(e),a=new Et,o=()=>{for(let e of Ue(t)){let t=n?e:Le(e).closest(r);if(!t||!Be(e,kt(e),t))continue;let o=Le(e).getAttribute("aria-labelledby"),u=()=>{a.has(t)||P.test(Le(e).getAttribute("aria-label")||"")&&(s(),a.add(t),Ne(t))};if(o)for(let e of Le(o).split(/\s+/)){let r=Le(document).getElementById(e);r?!a.has(r)&&P.test(r.innerText)&&(s(),a.add(r),Ne(t)):u()}else u()}},u=new Ct(o),s=vt("hide-if-labelled-by",(()=>u.disconnect()));u.observe(document,{characterData:!0,childList:!0,subtree:!0}),o()},"hide-if-contains-image":function(e,t,r){null==r&&(r=t);let n=He(e),P=()=>{for(let e of Ue(r)){let r=Ot(e),P=Le(r["background-image"]).match(/^url\("(.*)"\)$/);P&&gt(P[1]).then((r=>{if(n.test(new pt(r).reduce(((e,t)=>e+function(e,t=2){let r=Le(e).toString(16);r.length<t&&(r=Le("0").repeat(t-r.length)+r);return r}(t)),""))){let r=Le(e).closest(t);r&&(o(),Ne(r))}}))}},a=new ht(P),o=vt("hide-if-contains-image",(()=>a.disconnect()));a.observe(document,{childList:!0,subtree:!0}),P()},"simulate-event-poc":function(e,t,r="0"){if(!e)throw new Mt("[simulate-event snippet]: No event type provided.");if(!t)throw new Mt("[simulate-event snippet]: No selector provided.");let n=Re(t),P=qt(r,10),a=new Rt;function o(){n((t=>{a.has(t)||(a.add(t),Gt((()=>{Le(t).dispatchEvent(new Kt(e,{bubbles:!0,cancelable:!0}))}),P))}))}new Nt(o).observe(document,{childList:!0,subtree:!0}),o()},"simulate-mouse-event":function(...e){if(e.length<1)throw new Zt("[simulate-mouse-event snippet]: No selector provided.");e.length>7&&(e=e.slice(0,7));const t=Le([]);function r(){return t.forEach((e=>{if(!e.found){(function(e){let t=e;if(t.startsWith("xpath(")&&t.endsWith(")")){let t=Re(e);return()=>{let e=Le([]);return t((t=>e.push(t))),e}}return()=>xe.from(Ue(e))})(e.selector)().length>0&&(e.found=!0)}})),t.every((e=>e.found))}function n(e,t){e&&t&&("click"===t&&e.click?e.click():e.dispatchEvent(new Vt(t,{bubbles:!0,cancelable:!0})))}Le(e).forEach((e=>{const r=function(e){if(!e)return null;const t={selector:"",continue:!1,trigger:!1,event:"click",delay:"500",clicked:!1,found:!1},r=e.split("$");let n=[];r.length>=2&&(n=r[1].toLowerCase().split(",")),[t.selector]=r;for(const e of n)if("trigger"===e)t.trigger=!0;else if("continue"===e)t.continue=!0;else if(e.startsWith("event")){const r=e.toLowerCase().split("=");r[1]?t.event=r[1]:t.event="click"}else if(e.startsWith("delay")){const r=e.toLowerCase().split("=");r[1]?t.delay=r[1]:t.delay="500"}return t}(e);t.push(r)}));let P=!1;const[a]=t.slice(-1);a.trigger=!0;let o=new Ht;function u(){if(P||(P=r()),P)for(const e of t){const t=Re(e.selector),r=Ft(e.delay,10);e.trigger&&t((t=>{o.has(t)||(o.add(t),e.continue?setInterval((()=>{n(t,e.event)}),r):Bt((()=>{n(t,e.event)}),r))}))}}new Xt(u).observe(document,{childList:!0,subtree:!0}),u()}};let{requestAnimationFrame:_t,MutationObserver:$t,WeakSet:er}=Le(window);Jt["hide-if-graph-matches"]=function(e,t){let r=globalThis.graphMLUtil,n=new er,P=!1,a=new $t((function(){P||(P=!0,_t((()=>{P=!1,u()})))})),o=vt("hide-if-graph-matches",(()=>a.disconnect()));function u(){let P=Ue(e);for(let e of P){if(!Le(e).innerHTML)continue;let P=Le(e).querySelectorAll(t);0===P.length&&(P=[e]);for(let t of P)n.has(e)||(n.add(e),Le(t).innerHTML&&r.inference(t).then((t=>{t&&(o(),Ne(e))})))}}!function e(t=0){if(!r)throw new Error("graphMLUtil not available.");if(!r.initialized){if(t>2e3)throw new Error("graphMLUtil failed to initialize.");return _t(e)}a.observe(document,{childList:!0,subtree:!0}),u()}()}
/*!
 * This file is part of eyeo's Anti-Circumvention Snippets module (@eyeo/snippets),
 * Copyright (C) 2006-present eyeo GmbH
 * 
 * @eyeo/snippets is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 * 
 * @eyeo/snippets is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with @eyeo/snippets.  If not, see <http://www.gnu.org/licenses/>.
 */;

const snippets=Jt;
let context;
for (const [name, ...args] of filters) {
if (snippets.hasOwnProperty(name)) {
try { context = snippets[name].apply(context, args); }
catch (error) { console.error(error); }
}
}
context = void 0;
};
const graph = new Map([["log",null],["race",null],["debug",null],["hide-if-matches-xpath",null],["hide-if-contains",null],["hide-if-contains-similar-text",null],["hide-if-contains-visible-text",null],["hide-if-contains-and-matches-style",null],["hide-if-has-and-matches-style",null],["hide-if-labelled-by",null],["hide-if-contains-image",null],["simulate-event-poc",null],["simulate-mouse-event",null],["hide-if-graph-matches",function(){if(!globalThis.graphMLUtil){
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
const ze=1e-7,de=1e-4;class ye{constructor(e,t){this.backend=e,this.dataMover=t,this.data=new WeakMap,this.dataIdsCount=0}get(e){return this.data.has(e)||this.dataMover.moveData(this.backend,e),this.data.get(e)}set(e,t){this.dataIdsCount++,this.data.set(e,t)}has(e){return this.data.has(e)}delete(e){return this.dataIdsCount--,this.data.delete(e)}numDataIds(){return this.dataIdsCount}}class we{refCount(e){return Le("refCount")}incRef(e){return Le("incRef")}timerAvailable(){return!0}time(e){return Le("time")}read(e){return Le("read")}readSync(e){return Le("readSync")}readToGPU(e,t){return Le("readToGPU")}numDataIds(){return Le("numDataIds")}disposeData(e,t){return Le("disposeData")}write(e,t,r){return Le("write")}move(e,t,r,n,P){return Le("move")}memory(){return Le("memory")}floatPrecision(){return Le("floatPrecision")}epsilon(){return 32===this.floatPrecision()?ze:de}dispose(){return Le("dispose")}}function Le(e){throw new Error(`'${e}' not yet implemented or not found in the registry. This kernel may not be supported by the tfjs backend you have chosen`)}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function fe(e,t,r){return Math.max(e,Math.min(t,r))}function Ie(e){return e%2==0?e:e+1}function Se(e,t,r){const n=e[t];e[t]=e[r],e[r]=n}function Ae(e){let t=0;for(let r=0;r<e.length;r++)t+=e[r];return t}function xe(e,t){if(!e)throw new Error("string"==typeof t?t:t())}function Ye(e,t,r=""){xe(Qe(e,t),(()=>r+` Shapes ${e} and ${t} must match`))}function ke(e){xe(null!=e,(()=>"The input to the tensor constructor must be a non-null value."))}function Ce(e,t=[],r=!1){if(null==t&&(t=[]),Array.isArray(e)||Xe(e)&&!r)for(let n=0;n<e.length;++n)Ce(e[n],t,r);else t.push(e);return t}function Ee(e){if(0===e.length)return 1;let t=e[0];for(let r=1;r<e.length;r++)t*=e[r];return t}function Qe(e,t){if(e===t)return!0;if(null==e||null==t)return!1;if(e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}function We(e){return e%1==0}function Ue(e){const t=Math.ceil(Math.sqrt(e));return[t,Math.ceil(e/t)]}function qe(e,t){return t<=e.length?e:e+" ".repeat(t-e.length)}function Ge(e,t=(e=>0),r){return new Promise(((n,P)=>{let a=0;const o=()=>{if(e())return void n();a++;const u=t(a);null!=r&&a>=r?P():setTimeout(o,u)};o()}))}function Me(e,t){let r=1,n=-1;for(let t=0;t<e.length;++t)if(e[t]>=0)r*=e[t];else if(-1===e[t]){if(-1!==n)throw Error(`Shapes can only have 1 implicit size. Found -1 at dim ${n} and dim ${t}`);n=t}else if(e[t]<0)throw Error(`Shapes can not be < 0. Found ${e[t]} at dim ${t}`);if(-1===n){if(t>0&&t!==r)throw Error(`Size(${t}) must match the product of shape ${e}`);return e}if(0===r)throw Error(`Cannot infer the missing size in [${e}] when there are 0 elements`);if(t%r!=0)throw Error(`The implicit shape can't be a fractional number. Got ${t} / ${r}`);const P=e.slice();return P[n]=t/r,P}function Ke(e,t){const r=t.length;return xe((e=null==e?t.map(((e,t)=>t)):[].concat(e)).every((e=>e>=-r&&e<r)),(()=>`All values in axis param must be in range [-${r}, ${r}) but got axis ${e}`)),xe(e.every((e=>We(e))),(()=>`All values in axis param must be integers but got axis ${e}`)),e.map((e=>e<0?r+e:e))}function Ne(e,t){const r=[],n=[],P=null!=t&&Array.isArray(t)&&0===t.length,a=null==t||P?null:Ke(t,e).sort();let o=0;for(let t=0;t<e.length;++t){if(null!=a){if(a[o]===t&&1!==e[t])throw new Error(`Can't squeeze axis ${t} since its dim '${e[t]}' is not 1`);(null==a[o]||a[o]>t)&&1===e[t]&&(r.push(e[t]),n.push(t)),a[o]<=t&&o++}1!==e[t]&&(r.push(e[t]),n.push(t))}return{newShape:r,keptDims:n}}function Re(e,t){let r=null;if(null==e||"float32"===e)r=new Float32Array(t);else if("int32"===e)r=new Int32Array(t);else{if("bool"!==e)throw new Error(`Unknown data type ${e}`);r=new Uint8Array(t)}return r}function Fe(e,t){let r=null;if(null==e||"float32"===e)r=new Float32Array(t);else if("int32"===e)r=new Int32Array(t);else if("bool"===e)r=new Uint8Array(t);else{if("string"!==e)throw new Error(`Unknown data type ${e}`);r=new Array(t)}return r}function Be(e,t){for(let r=0;r<e.length;r++){const n=e[r];if(isNaN(n)||!isFinite(n))throw Error(`A tensor of type ${t} being uploaded contains ${n}.`)}}function Ze(e){return"bool"===e||"complex64"===e||"float32"===e||"int32"===e||"string"===e}function Ve(e,t){return"complex64"!==t&&(("float32"!==t||"complex64"===e)&&(("int32"!==t||"float32"===e||"complex64"===e)&&("bool"!==t||"bool"!==e)))}function Xe(e){return e instanceof Float32Array||e instanceof Int32Array||e instanceof Uint8Array||e instanceof Uint8ClampedArray}function He(e){if("float32"===e||"int32"===e)return 4;if("complex64"===e)return 8;if("bool"===e)return 1;throw new Error(`Unknown dtype ${e}`)}function Je(e){if(null==e)return 0;let t=0;return e.forEach((e=>t+=e.length)),t}function _e(e){return"string"==typeof e||e instanceof String}function $e(e){return"boolean"==typeof e}function et(e){return"number"==typeof e}function tt(e){return Array.isArray(e)?tt(e[0]):e instanceof Float32Array?"float32":e instanceof Int32Array||e instanceof Uint8Array||e instanceof Uint8ClampedArray?"int32":et(e)?"float32":_e(e)?"string":$e(e)?"bool":"float32"}function rt(e){return!!(e&&e.constructor&&e.call&&e.apply)}function nt(e,t){for(let r=t;r<e;++r)if(e%r==0)return r;return e}function Pt(e){const t=e.length;if(t<2)return[];const r=new Array(t-1);r[t-2]=e[t-1];for(let n=t-3;n>=0;--n)r[n]=r[n+1]*e[n+1];return r}function at(e,t,r,n=!1){const P=new Array;if(1===t.length){const a=t[0]*(n?2:1);for(let t=0;t<a;t++)P[t]=r[e+t]}else{const a=t[0],o=t.slice(1),u=o.reduce(((e,t)=>e*t))*(n?2:1);for(let t=0;t<a;t++)P[t]=at(e+t*u,o,r,n)}return P}function ot(e,t,r=!1){if(0===e.length)return t[0];const n=e.reduce(((e,t)=>e*t))*(r?2:1);if(0===n)return[];if(n!==t.length)throw new Error(`[${e}] does not match the input size ${t.length}${r?" for a complex tensor":""}.`);return at(0,e,t,r)}function ut(e,t){const r=st(e,t);for(let e=0;e<r.length;e++)r[e]=1;return r}function st(e,t){if(null==t||"float32"===t||"complex64"===t)return new Float32Array(e);if("int32"===t)return new Int32Array(e);if("bool"===t)return new Uint8Array(e);throw new Error(`Unknown data type ${t}`)}function vt(e){e.forEach((t=>{xe(Number.isInteger(t)&&t>=0,(()=>`Tensor must have a shape comprised of positive integers but got shape [${e}].`))}))}function it(e,t,r){if(0===t)return 0;if(1===t)return e[0];let n=e[e.length-1];for(let t=0;t<e.length-1;++t)n+=r[t]*e[t];return n}function lt(e,t,r){if(0===t)return[];if(1===t)return[e];const n=new Array(t);for(let t=0;t<n.length-1;++t)n[t]=Math.floor(e/r[t]),e-=n[t]*r[t];return n[n.length-1]=e,n}function ct(e){return e&&e.then&&"function"==typeof e.then}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Ot="tfjsflags";class Dt{constructor(e){this.global=e,this.flags={},this.flagRegistry={},this.urlFlags={},this.getQueryParams=jt,this.populateURLFlags()}setPlatform(e,t){null!=this.platform&&(mt().getBool("IS_TEST")||mt().getBool("PROD")||console.warn(`Platform ${this.platformName} has already been set. Overwriting the platform with ${e}.`)),this.platformName=e,this.platform=t}registerFlag(e,t,r){if(this.flagRegistry[e]={evaluationFn:t,setHook:r},null!=this.urlFlags[e]){const t=this.urlFlags[e];mt().getBool("IS_TEST")||mt().getBool("PROD")||console.warn(`Setting feature override from URL ${e}: ${t}.`),this.set(e,t)}}async getAsync(e){return e in this.flags||(this.flags[e]=await this.evaluateFlag(e)),this.flags[e]}get(e){if(e in this.flags)return this.flags[e];const t=this.evaluateFlag(e);if(ct(t))throw new Error(`Flag ${e} cannot be synchronously evaluated. Please use getAsync() instead.`);return this.flags[e]=t,this.flags[e]}getNumber(e){return this.get(e)}getBool(e){return this.get(e)}getFlags(){return this.flags}get features(){return this.flags}set(e,t){if(null==this.flagRegistry[e])throw new Error(`Cannot set flag ${e} as it has not been registered.`);this.flags[e]=t,null!=this.flagRegistry[e].setHook&&this.flagRegistry[e].setHook(t)}evaluateFlag(e){if(null==this.flagRegistry[e])throw new Error(`Cannot evaluate flag '${e}': no evaluation function found.`);return this.flagRegistry[e].evaluationFn()}setFlags(e){this.flags=Object.assign({},e)}reset(){this.flags={},this.urlFlags={},this.populateURLFlags()}populateURLFlags(){if(void 0===this.global||void 0===this.global.location||void 0===this.global.location.search)return;const e=this.getQueryParams(this.global.location.search);if(Ot in e){e[Ot].split(",").forEach((e=>{const[t,r]=e.split(":");this.urlFlags[t]=pt(t,r)}))}}}function jt(e){const t={};return e.replace(/[?&]([^=?&]+)(?:=([^&]*))?/g,((e,...r)=>(ht(t,r[0],r[1]),r.join("=")))),t}function ht(e,t,r){e[decodeURIComponent(t)]=decodeURIComponent(r||"")}function pt(e,t){if("true"===(t=t.toLowerCase())||"false"===t)return"true"===t;if(""+ +t===t)return+t;throw new Error(`Could not parse value flag value ${t} for flag ${e}.`)}function mt(){return bt}let gt,bt=null;function Tt(e){bt=e}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function zt(){if(null==gt){let e;if("undefined"!=typeof window)e=window;else if("undefined"!=typeof global)e=global;else if("undefined"!=typeof process)e=process;else{if("undefined"==typeof self)throw new Error("Could not find a global object");e=self}gt=e}return gt}function dt(){const e=zt();return null==e._tfGlobals&&(e._tfGlobals=new Map),e._tfGlobals}function yt(e,t){const r=dt();if(r.has(e))return r.get(e);{const n=t();return r.set(e,n),r.get(e)}}const wt="Abs",Lt="Acos",ft="Acosh",It="Add",St="AddN",At="All",xt="Any",Yt="ArgMax",kt="ArgMin",Ct="Asin",Et="Asinh",Qt="Atan",Wt="Atanh",Ut="Atan2",qt="AvgPool",Gt="AvgPool3D",Mt="BatchMatMul",Kt="BatchToSpaceND",Nt="Bincount",Rt="BroadcastArgs",Ft="Cast",Bt="Ceil",Zt="ClipByValue",Vt="Complex",Xt="ComplexAbs",Ht="Concat",Jt="Conv2D",_t="Conv2DBackpropFilter",$t="Conv2DBackpropInput",er="Conv3D",tr="Conv3DBackpropInputV2",rr="Cos",nr="Cosh",Pr="Cumprod",ar="Cumsum",or="CropAndResize",ur="DenseBincount",sr="DepthToSpace",vr="DepthwiseConv2dNative",ir="DepthwiseConv2dNativeBackpropFilter",lr="DepthwiseConv2dNativeBackpropInput",cr="Diag",Or="Dilation2D",Dr="RealDiv",jr="Einsum",hr="Elu",pr="Erf",mr="Equal",gr="Exp",br="ExpandDims",Tr="Expm1",zr="FFT",dr="Fill",yr="FlipLeftRight",wr="Floor",Lr="FloorDiv",fr="FusedBatchNorm",Ir="GatherV2",Sr="GatherNd",Ar="Greater",xr="GreaterEqual",Yr="Identity",kr="IFFT",Cr="Imag",Er="IsFinite",Qr="IsInf",Wr="IsNan",Ur="LeakyRelu",qr="Less",Gr="LessEqual",Mr="LinSpace",Kr="Log",Nr="Log1p",Rr="LogicalAnd",Fr="LogicalNot",Br="LogicalOr",Zr="LRN",Vr="Max",Xr="Maximum",Hr="MaxPool",Jr="MaxPool3D",_r="MaxPoolWithArgmax",$r="Mean",en="Min",tn="Minimum",rn="MirrorPad",nn="Mod",Pn="Multinomial",an="Multiply",on="Neg",un="NotEqual",sn="NonMaxSuppressionV3",vn="NonMaxSuppressionV4",ln="NonMaxSuppressionV5",cn="OnesLike",On="OneHot",Dn="Pack",jn="PadV2",hn="Pow",pn="Prelu",mn="Prod",gn="Range",bn="Real",Tn="Reciprocal",zn="Relu",dn="Reshape",yn="ResizeNearestNeighbor",wn="ResizeBilinear",Ln="Relu6",fn="Reverse",In="Round",Sn="Rsqrt",An="ScatterNd",xn="SearchSorted",Yn="Select",kn="Selu",Cn="Slice",En="Sin",Qn="Sinh",Wn="Sign",Un="Sigmoid",qn="Softplus",Gn="Sqrt",Mn="Sum",Kn="SpaceToBatchND",Nn="SplitV",Rn="Softmax",Fn="SparseFillEmptyRows",Bn="SparseReshape",Zn="SparseSegmentMean",Vn="SparseSegmentSum",Xn="SparseToDense",Hn="SquaredDifference",Jn="StridedSlice",_n="StringNGrams",$n="StringSplit",eP="StringToHashBucketFast",tP="Sub",rP="Tan",nP="Tanh",PP="Tile",aP="TopK",oP="Transform",uP="Transpose",sP="Unique",vP="Unpack",iP="UnsortedSegmentSum",lP="ZerosLike",cP="Step",OP="FromPixels",DP="RotateWithOffset",jP="_FusedMatMul",hP="FusedConv2D",pP="FusedDepthwiseConv2D";
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function mP(...e){mt().getBool("IS_TEST")||mt().getBool("PROD")||console.warn(...e)}function gP(...e){mt().getBool("IS_TEST")||mt().getBool("PROD")||console.log(...e)}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const bP=yt("kernelRegistry",(()=>new Map)),TP=yt("gradRegistry",(()=>new Map));function zP(e,t){const r=LP(e,t);return bP.get(r)}function dP(e){return TP.get(e)}function yP(e){const t=bP.entries(),r=[];for(;;){const{done:n,value:P}=t.next();if(n)break;const[a,o]=P,[u]=a.split("_");u===e&&r.push(o)}return r}function wP(e){const{kernelName:t,backendName:r}=e,n=LP(t,r);bP.has(n)&&mP(`The kernel '${t}' for backend '${r}' is already registered`),bP.set(n,e)}function LP(e,t){return`${t}_${e}`}var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},t=fP,r=null;try{r=new WebAssembly.Instance(new WebAssembly.Module(new Uint8Array([0,97,115,109,1,0,0,0,1,13,2,96,0,1,127,96,4,127,127,127,127,1,127,3,7,6,0,1,1,1,1,1,6,6,1,127,1,65,0,11,7,50,6,3,109,117,108,0,1,5,100,105,118,95,115,0,2,5,100,105,118,95,117,0,3,5,114,101,109,95,115,0,4,5,114,101,109,95,117,0,5,8,103,101,116,95,104,105,103,104,0,0,10,191,1,6,4,0,35,0,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,126,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,127,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,128,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,129,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,130,34,4,66,32,135,167,36,0,32,4,167,11])),{}).exports}catch(Te){}function fP(e,t,r){this.low=0|e,this.high=0|t,this.unsigned=!!r}function IP(e){return!0===(e&&e.__isLong__)}fP.prototype.__isLong__,Object.defineProperty(fP.prototype,"__isLong__",{value:!0}),fP.isLong=IP;var n={},P={};function SP(e,t){var r,a,o;return t?(o=0<=(e>>>=0)&&e<256)&&(a=P[e])?a:(r=xP(e,(0|e)<0?-1:0,!0),o&&(P[e]=r),r):(o=-128<=(e|=0)&&e<128)&&(a=n[e])?a:(r=xP(e,e<0?-1:0,!1),o&&(n[e]=r),r)}function AP(e,t){if(isNaN(e))return t?l:i;if(t){if(e<0)return l;if(e>=u)return h}else{if(e<=-s)return p;if(e+1>=s)return j}return e<0?AP(-e,t).neg():xP(e%o|0,e/o|0,t)}function xP(e,t,r){return new fP(e,t,r)}fP.fromInt=SP,fP.fromNumber=AP,fP.fromBits=xP;var a=Math.pow;function YP(e,t,r){if(0===e.length)throw Error("empty string");if("NaN"===e||"Infinity"===e||"+Infinity"===e||"-Infinity"===e)return i;if("number"==typeof t?(r=t,t=!1):t=!!t,(r=r||10)<2||36<r)throw RangeError("radix");var n;if((n=e.indexOf("-"))>0)throw Error("interior hyphen");if(0===n)return YP(e.substring(1),t,r).neg();for(var P=AP(a(r,8)),o=i,u=0;u<e.length;u+=8){var s=Math.min(8,e.length-u),v=parseInt(e.substring(u,u+s),r);if(s<8){var l=AP(a(r,s));o=o.mul(l).add(AP(v))}else o=(o=o.mul(P)).add(AP(v))}return o.unsigned=t,o}function kP(e,t){return"number"==typeof e?AP(e,t):"string"==typeof e?YP(e,t):xP(e.low,e.high,"boolean"==typeof t?t:e.unsigned)}fP.fromString=YP,fP.fromValue=kP;var o=4294967296,u=o*o,s=u/2,v=SP(1<<24),i=SP(0);fP.ZERO=i;var l=SP(0,!0);fP.UZERO=l;var c=SP(1);fP.ONE=c;var O=SP(1,!0);fP.UONE=O;var D=SP(-1);fP.NEG_ONE=D;var j=xP(-1,2147483647,!1);fP.MAX_VALUE=j;var h=xP(-1,-1,!0);fP.MAX_UNSIGNED_VALUE=h;var p=xP(0,-2147483648,!1);fP.MIN_VALUE=p;var m=fP.prototype;m.toInt=function(){return this.unsigned?this.low>>>0:this.low},m.toNumber=function(){return this.unsigned?(this.high>>>0)*o+(this.low>>>0):this.high*o+(this.low>>>0)},m.toString=function(e){if((e=e||10)<2||36<e)throw RangeError("radix");if(this.isZero())return"0";if(this.isNegative()){if(this.eq(p)){var t=AP(e),r=this.div(t),n=r.mul(t).sub(this);return r.toString(e)+n.toInt().toString(e)}return"-"+this.neg().toString(e)}for(var P=AP(a(e,6),this.unsigned),o=this,u="";;){var s=o.div(P),v=(o.sub(s.mul(P)).toInt()>>>0).toString(e);if((o=s).isZero())return v+u;for(;v.length<6;)v="0"+v;u=""+v+u}},m.getHighBits=function(){return this.high},m.getHighBitsUnsigned=function(){return this.high>>>0},m.getLowBits=function(){return this.low},m.getLowBitsUnsigned=function(){return this.low>>>0},m.getNumBitsAbs=function(){if(this.isNegative())return this.eq(p)?64:this.neg().getNumBitsAbs();for(var e=0!=this.high?this.high:this.low,t=31;t>0&&0==(e&1<<t);t--);return 0!=this.high?t+33:t+1},m.isZero=function(){return 0===this.high&&0===this.low},m.eqz=m.isZero,m.isNegative=function(){return!this.unsigned&&this.high<0},m.isPositive=function(){return this.unsigned||this.high>=0},m.isOdd=function(){return 1==(1&this.low)},m.isEven=function(){return 0==(1&this.low)},m.equals=function(e){return IP(e)||(e=kP(e)),(this.unsigned===e.unsigned||this.high>>>31!=1||e.high>>>31!=1)&&(this.high===e.high&&this.low===e.low)},m.eq=m.equals,m.notEquals=function(e){return!this.eq(e)},m.neq=m.notEquals,m.ne=m.notEquals,m.lessThan=function(e){return this.comp(e)<0},m.lt=m.lessThan,m.lessThanOrEqual=function(e){return this.comp(e)<=0},m.lte=m.lessThanOrEqual,m.le=m.lessThanOrEqual,m.greaterThan=function(e){return this.comp(e)>0},m.gt=m.greaterThan,m.greaterThanOrEqual=function(e){return this.comp(e)>=0},m.gte=m.greaterThanOrEqual,m.ge=m.greaterThanOrEqual,m.compare=function(e){if(IP(e)||(e=kP(e)),this.eq(e))return 0;var t=this.isNegative(),r=e.isNegative();return t&&!r?-1:!t&&r?1:this.unsigned?e.high>>>0>this.high>>>0||e.high===this.high&&e.low>>>0>this.low>>>0?-1:1:this.sub(e).isNegative()?-1:1},m.comp=m.compare,m.negate=function(){return!this.unsigned&&this.eq(p)?p:this.not().add(c)},m.neg=m.negate,m.add=function(e){IP(e)||(e=kP(e));var t=this.high>>>16,r=65535&this.high,n=this.low>>>16,P=65535&this.low,a=e.high>>>16,o=65535&e.high,u=e.low>>>16,s=0,v=0,i=0,l=0;return i+=(l+=P+(65535&e.low))>>>16,v+=(i+=n+u)>>>16,s+=(v+=r+o)>>>16,s+=t+a,xP((i&=65535)<<16|(l&=65535),(s&=65535)<<16|(v&=65535),this.unsigned)},m.subtract=function(e){return IP(e)||(e=kP(e)),this.add(e.neg())},m.sub=m.subtract,m.multiply=function(e){if(this.isZero())return i;if(IP(e)||(e=kP(e)),r)return xP(r.mul(this.low,this.high,e.low,e.high),r.get_high(),this.unsigned);if(e.isZero())return i;if(this.eq(p))return e.isOdd()?p:i;if(e.eq(p))return this.isOdd()?p:i;if(this.isNegative())return e.isNegative()?this.neg().mul(e.neg()):this.neg().mul(e).neg();if(e.isNegative())return this.mul(e.neg()).neg();if(this.lt(v)&&e.lt(v))return AP(this.toNumber()*e.toNumber(),this.unsigned);var t=this.high>>>16,n=65535&this.high,P=this.low>>>16,a=65535&this.low,o=e.high>>>16,u=65535&e.high,s=e.low>>>16,l=65535&e.low,c=0,O=0,D=0,j=0;return D+=(j+=a*l)>>>16,O+=(D+=P*l)>>>16,D&=65535,O+=(D+=a*s)>>>16,c+=(O+=n*l)>>>16,O&=65535,c+=(O+=P*s)>>>16,O&=65535,c+=(O+=a*u)>>>16,c+=t*l+n*s+P*u+a*o,xP((D&=65535)<<16|(j&=65535),(c&=65535)<<16|(O&=65535),this.unsigned)},m.mul=m.multiply,m.divide=function(e){if(IP(e)||(e=kP(e)),e.isZero())throw Error("division by zero");var t,n,P;if(r)return this.unsigned||-2147483648!==this.high||-1!==e.low||-1!==e.high?xP((this.unsigned?r.div_u:r.div_s)(this.low,this.high,e.low,e.high),r.get_high(),this.unsigned):this;if(this.isZero())return this.unsigned?l:i;if(this.unsigned){if(e.unsigned||(e=e.toUnsigned()),e.gt(this))return l;if(e.gt(this.shru(1)))return O;P=l}else{if(this.eq(p))return e.eq(c)||e.eq(D)?p:e.eq(p)?c:(t=this.shr(1).div(e).shl(1)).eq(i)?e.isNegative()?c:D:(n=this.sub(e.mul(t)),P=t.add(n.div(e)));if(e.eq(p))return this.unsigned?l:i;if(this.isNegative())return e.isNegative()?this.neg().div(e.neg()):this.neg().div(e).neg();if(e.isNegative())return this.div(e.neg()).neg();P=i}for(n=this;n.gte(e);){t=Math.max(1,Math.floor(n.toNumber()/e.toNumber()));for(var o=Math.ceil(Math.log(t)/Math.LN2),u=o<=48?1:a(2,o-48),s=AP(t),v=s.mul(e);v.isNegative()||v.gt(n);)v=(s=AP(t-=u,this.unsigned)).mul(e);s.isZero()&&(s=c),P=P.add(s),n=n.sub(v)}return P},m.div=m.divide,m.modulo=function(e){return IP(e)||(e=kP(e)),r?xP((this.unsigned?r.rem_u:r.rem_s)(this.low,this.high,e.low,e.high),r.get_high(),this.unsigned):this.sub(this.div(e).mul(e))},m.mod=m.modulo,m.rem=m.modulo,m.not=function(){return xP(~this.low,~this.high,this.unsigned)},m.and=function(e){return IP(e)||(e=kP(e)),xP(this.low&e.low,this.high&e.high,this.unsigned)},m.or=function(e){return IP(e)||(e=kP(e)),xP(this.low|e.low,this.high|e.high,this.unsigned)},m.xor=function(e){return IP(e)||(e=kP(e)),xP(this.low^e.low,this.high^e.high,this.unsigned)},m.shiftLeft=function(e){return IP(e)&&(e=e.toInt()),0==(e&=63)?this:e<32?xP(this.low<<e,this.high<<e|this.low>>>32-e,this.unsigned):xP(0,this.low<<e-32,this.unsigned)},m.shl=m.shiftLeft,m.shiftRight=function(e){return IP(e)&&(e=e.toInt()),0==(e&=63)?this:e<32?xP(this.low>>>e|this.high<<32-e,this.high>>e,this.unsigned):xP(this.high>>e-32,this.high>=0?0:-1,this.unsigned)},m.shr=m.shiftRight,m.shiftRightUnsigned=function(e){if(IP(e)&&(e=e.toInt()),0===(e&=63))return this;var t=this.high;return e<32?xP(this.low>>>e|t<<32-e,t>>>e,this.unsigned):xP(32===e?t:t>>>e-32,0,this.unsigned)},m.shru=m.shiftRightUnsigned,m.shr_u=m.shiftRightUnsigned,m.toSigned=function(){return this.unsigned?xP(this.low,this.high,!1):this},m.toUnsigned=function(){return this.unsigned?this:xP(this.low,this.high,!0)},m.toBytes=function(e){return e?this.toBytesLE():this.toBytesBE()},m.toBytesLE=function(){var e=this.high,t=this.low;return[255&t,t>>>8&255,t>>>16&255,t>>>24,255&e,e>>>8&255,e>>>16&255,e>>>24]},m.toBytesBE=function(){var e=this.high,t=this.low;return[e>>>24,e>>>16&255,e>>>8&255,255&e,t>>>24,t>>>16&255,t>>>8&255,255&t]},fP.fromBytes=function(e,t,r){return r?fP.fromBytesLE(e,t):fP.fromBytesBE(e,t)},fP.fromBytesLE=function(e,t){return new fP(e[0]|e[1]<<8|e[2]<<16|e[3]<<24,e[4]|e[5]<<8|e[6]<<16|e[7]<<24,t)},fP.fromBytesBE=function(e,t){return new fP(e[4]<<24|e[5]<<16|e[6]<<8|e[7],e[0]<<24|e[1]<<16|e[2]<<8|e[3],t)};var g=(Te={__proto__:null,default:t},[t].forEach((function(e){e&&"string"!=typeof e&&!Array.isArray(e)&&Object.keys(e).forEach((function(t){if("default"!==t&&!(t in Te)){var r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(Te,t,r.get?r:{enumerable:!0,get:function(){return e[t]}})}}))})),Object.freeze(Te));
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const CP=t||g;function EP(e){return CP.fromString(e,!0,16)}const QP=EP("c3a5c85c97cb3127"),WP=EP("b492b66fbe98f273"),UP=EP("9ae16a3b2f90404f");function qP(e){return e.xor(e.shru(47))}function GP(e,t,r){const n=e.slice(t,t+r);return CP.fromBytes(Array.from(n),!0,!0)}function MP(e,t){return GP(e,t,8)}function KP(e,t){return GP(e,t,4)}function NP(e,t){return 0===t?e:e.shru(t).or(e.shl(64-t))}function RP(e,t,r=EP("9ddfea08eb382d69")){let n=e.xor(t).mul(r);n=n.xor(n.shru(47));let P=t.xor(n).mul(r);return P=P.xor(P.shru(47)),P=P.mul(r),P}function FP(e,t,r,n,P,a){P=P.add(e),a=NP(a.add(P).add(n),21);const o=P;return P=(P=P.add(t)).add(r),a=a.add(NP(P,44)),[P.add(n),a.add(o)]}function BP(e,t,r,n){return FP(MP(e,t),MP(e,t+8),MP(e,t+16),MP(e,t+24),r,n)}function ZP(e,t=e.length){if(t>=8){const r=UP.add(2*t),n=MP(e,0).add(UP),P=MP(e,t-8);return RP(NP(P,37).mul(r).add(n),NP(n,25).add(P).mul(r),r)}if(t>=4){const r=UP.add(2*t);return RP(KP(e,0).shl(3).add(t),KP(e,t-4),r)}if(t>0){const r=e[0]+(e[t>>1]<<8),n=t+(e[t-1]<<2);return qP(UP.mul(r).xor(QP.mul(n))).mul(UP)}return UP}function VP(e,t=e.length){const r=UP.add(2*t),n=MP(e,0).mul(WP),P=MP(e,8),a=MP(e,t-8).mul(r),o=MP(e,t-16).mul(UP);return RP(NP(n.add(P),43).add(NP(a,30)).add(o),n.add(NP(P.add(UP),18)).add(a),r)}function XP(e,t=e.length){const r=UP.add(2*t),n=MP(e,0).mul(UP),P=MP(e,8),a=MP(e,t-8).mul(r),o=MP(e,t-16).mul(UP),u=NP(n.add(P),43).add(NP(a,30)).add(o),s=RP(u,n.add(NP(P.add(UP),18)).add(a),r),v=MP(e,16).mul(r),i=MP(e,24),l=u.add(MP(e,t-32)).mul(r),c=s.add(MP(e,t-24)).mul(r);return RP(NP(v.add(i),43).add(NP(l,30)).add(c),v.add(NP(i.add(n),18)).add(l),r)}function HP(e,t=e.length){const r=CP.fromNumber(81,!0);if(t<=32)return t<=16?ZP(e,t):VP(e,t);if(t<=64)return XP(e,t);let n=r,P=r.mul(WP).add(113),a=qP(P.mul(UP).add(113)).mul(UP),o=[CP.UZERO,CP.UZERO],u=[CP.UZERO,CP.UZERO];n=n.mul(UP).add(MP(e,0));let s=0;const v=64*(t-1>>6),i=v+(t-1&63)-63;do{n=NP(n.add(P).add(o[0]).add(MP(e,s+8)),37).mul(WP),P=NP(P.add(o[1]).add(MP(e,s+48)),42).mul(WP),n=n.xor(u[1]),P=P.add(o[0]).add(MP(e,s+40)),a=NP(a.add(u[0]),33).mul(WP),o=BP(e,s,o[1].mul(WP),n.add(u[0])),u=BP(e,s+32,a.add(u[1]),P.add(MP(e,s+16))),[a,n]=[n,a],s+=64}while(s!==v);const l=WP.add(a.and(255).shl(1));return s=i,u[0]=u[0].add(t-1&63),o[0]=o[0].add(u[0]),u[0]=u[0].add(o[0]),n=NP(n.add(P).add(o[0]).add(MP(e,s+8)),37).mul(l),P=NP(P.add(o[1]).add(MP(e,s+48)),42).mul(l),n=n.xor(u[1].mul(9)),P=P.add(o[0].mul(9).add(MP(e,s+40))),a=NP(a.add(u[0]),33).mul(l),o=BP(e,s,o[1].mul(l),n.add(u[0])),u=BP(e,s+32,a.add(u[1]),P.add(MP(e,s+16))),[a,n]=[n,a],RP(RP(o[0],u[0],l).add(qP(P).mul(QP)).add(a),RP(o[1],u[1],l).add(n),l)}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function JP(e,t){return"string"===t?ta(e):$P([e],t)}function _P(e,t){return e instanceof Float32Array&&"float32"===t||e instanceof Int32Array&&"int32"===t||e instanceof Uint8Array&&"bool"===t}function $P(e,t){if("string"===t)throw new Error("Cannot convert a string[] to a TypedArray");if(Array.isArray(e)&&(e=Ce(e)),mt().getBool("DEBUG")&&Be(e,t),_P(e,t))return e;if(null==t||"float32"===t||"complex64"===t)return new Float32Array(e);if("int32"===t)return new Int32Array(e);if("bool"===t){const t=new Uint8Array(e.length);for(let r=0;r<t.length;++r)0!==Math.round(e[r])&&(t[r]=1);return t}throw new Error(`Unknown data type ${t}`)}function ea(){return mt().platform.now()}function ta(e,t="utf-8"){return t=t||"utf-8",mt().platform.encode(e,t)}function ra(e,t="utf-8"){return t=t||"utf-8",mt().platform.decode(e,t)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class na{constructor(e,t){this.backendTimer=e,this.logger=t,null==t&&(this.logger=new aa)}profileKernel(e,t,r){let n;const P=()=>{n=r()};let a;const o=ea();if(this.backendTimer.timerAvailable())a=this.backendTimer.time(P);else{P();for(const e of n)e.dataSync();a=Promise.resolve({kernelMs:ea()-o})}if(mt().getBool("CHECK_COMPUTATION_FOR_ERRORS"))for(let t=0;t<n.length;t++){const r=n[t];r.data().then((t=>{Pa(t,r.dtype,e)}))}const u={kernelName:e,outputs:n,inputs:t,timeMs:a.then((e=>e.kernelMs)),extraInfo:a.then((e=>null!=e.getExtraProfileInfo?e.getExtraProfileInfo():""))};return u}logKernelProfile(e){const{kernelName:t,outputs:r,timeMs:n,inputs:P,extraInfo:a}=e;r.forEach((e=>{Promise.all([e.data(),n,a]).then((r=>{this.logger.logKernelProfile(t,e,r[0],r[1],P,r[2])}))}))}}function Pa(e,t,r){if("float32"!==t)return!1;for(let t=0;t<e.length;t++){const n=e[t];if(isNaN(n)||!isFinite(n))return console.warn(`Found ${n} in the result of '${r}'`),!0}return!1}class aa{logKernelProfile(e,t,r,n,P,a){const o="number"==typeof n?qe(`${n}ms`,9):n.error,u=qe(e,25),s=t.rank,v=t.size,i=qe(t.shape.toString(),14);let l="";for(const e in P){const r=P[e];if(null!=r){const n=r.shape||t.shape,P=n.length;l+=`${e}: ${P}D ${P>0?n:""} `}}console.log(`%c${u}\t%c${o}\t%c${s}D ${i}\t%c${v}\t%c${l}\t%c${a}`,"font-weight:bold","color:red","color:blue","color: orange","color: green","color: steelblue")}}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function oa(e,t,r){const n={},P={};for(let e=0;e<t.length;e++)n[t[e].id]=!0;for(let r=0;r<e.length;r++){const a=e[r],o=a.inputs;for(const e in o){const r=o[e];let u=!1;for(let e=0;e<t.length;e++)if(n[r.id]){a.outputs.forEach((e=>n[e.id]=!0)),u=!0,P[a.id]=!0;break}if(u)break}}const a={};a[r.id]=!0;const o={};for(let t=e.length-1;t>=0;t--){const r=e[t],n=r.inputs;for(let e=0;e<r.outputs.length;e++)if(a[r.outputs[e].id]){for(const e in n)a[n[e].id]=!0,o[r.id]=!0;break}}const u=[];for(let t=0;t<e.length;t++){const r=e[t];if(P[r.id]&&o[r.id]){const e={};for(const t in r.inputs){const P=r.inputs[t];n[P.id]&&(e[t]=P)}const t=Object.assign({},r);t.inputs=e,t.outputs=r.outputs,u.push(t)}}return u}function ua(e,t,r,n){for(let P=t.length-1;P>=0;P--){const a=t[P],o=[];if(a.outputs.forEach((t=>{const r=e[t.id];null!=r?o.push(r):o.push(null)})),null==a.gradient)throw new Error(`Cannot compute gradient: gradient function not found for ${a.kernelName}.`);const u=a.gradient(o);for(const t in a.inputs){if(!(t in u))throw new Error(`Cannot backprop through input ${t}. Available gradients found: ${Object.keys(u)}.`);const P=r((()=>u[t]()));if("float32"!==P.dtype)throw new Error(`Error in gradient for op ${a.kernelName}. The gradient of input ${t} must have 'float32' dtype, but has '${P.dtype}'`);const o=a.inputs[t];if(!Qe(P.shape,o.shape))throw new Error(`Error in gradient for op ${a.kernelName}. The gradient of input '${t}' has shape '${P.shape}', which does not match the shape of the input '${o.shape}'`);if(null==e[o.id])e[o.id]=P;else{const t=e[o.id];e[o.id]=n(t,P),t.dispose()}}}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const sa=20,va=3,ia=7;function la(e,t,r,n){const P=Pt(t),a=ca(e,t,r,P),o=t.length,u=ja(e,t,r,P,a),s=["Tensor"];return n&&(s.push(`  dtype: ${r}`),s.push(`  rank: ${o}`),s.push(`  shape: [${t}]`),s.push("  values:")),s.push(u.map((e=>"    "+e)).join("\n")),s.join("\n")}function ca(e,t,r,n){const P=Ee(t),a=n[n.length-1],o=new Array(a).fill(0),u=t.length,s="complex64"===r?ha(e):e;if(u>1)for(let e=0;e<P/a;e++){const t=e*a;for(let e=0;e<a;e++)o[e]=Math.max(o[e],Oa(s[t+e],0,r).length)}return o}function Oa(e,t,r){let n;return n=Array.isArray(e)?`${parseFloat(e[0].toFixed(ia))} + ${parseFloat(e[1].toFixed(ia))}j`:_e(e)?`'${e}'`:"bool"===r?Da(e):parseFloat(e.toFixed(ia)).toString(),qe(n,t)}function Da(e){return 0===e?"false":"true"}function ja(e,t,r,n,P,a=!0){const o="complex64"===r?2:1,u=t[0],s=t.length;if(0===s){if("complex64"===r){return[Oa(ha(e)[0],0,r)]}return"bool"===r?[Da(e[0])]:[e[0].toString()]}if(1===s){if(u>sa){const t=va*o;let n=Array.from(e.slice(0,t)),a=Array.from(e.slice((u-va)*o,u*o));return"complex64"===r&&(n=ha(n),a=ha(a)),["["+n.map(((e,t)=>Oa(e,P[t],r))).join(", ")+", ..., "+a.map(((e,t)=>Oa(e,P[u-va+t],r))).join(", ")+"]"]}return["["+("complex64"===r?ha(e):Array.from(e)).map(((e,t)=>Oa(e,P[t],r))).join(", ")+"]"]}const v=t.slice(1),i=n.slice(1),l=n[0]*o,c=[];if(u>sa){for(let t=0;t<va;t++){const n=t*l,a=n+l;c.push(...ja(e.slice(n,a),v,r,i,P,!1))}c.push("...");for(let t=u-va;t<u;t++){const n=t*l,a=n+l;c.push(...ja(e.slice(n,a),v,r,i,P,t===u-1))}}else for(let t=0;t<u;t++){const n=t*l,a=n+l;c.push(...ja(e.slice(n,a),v,r,i,P,t===u-1))}const O=2===s?",":"";c[0]="["+c[0]+O;for(let e=1;e<c.length-1;e++)c[e]=" "+c[e]+O;let D=",\n";for(let e=2;e<s;e++)D+="\n";return c[c.length-1]=" "+c[c.length-1]+"]"+(a?"":D),c}function ha(e){const t=[];for(let r=0;r<e.length;r+=2)t.push([e[r],e[r+1]]);return t}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class pa{constructor(e,t,r){if(this.dtype=t,this.shape=e.slice(),this.size=Ee(e),null!=r){const e=r.length;xe(e===this.size,(()=>`Length of values '${e}' does not match the size inferred by the shape '${this.size}'.`))}if("complex64"===t)throw new Error("complex64 dtype TensorBuffers are not supported. Please create a TensorBuffer for the real and imaginary parts separately and call tf.complex(real, imag).");this.values=r||Fe(t,this.size),this.strides=Pt(e)}set(e,...t){0===t.length&&(t=[0]),xe(t.length===this.rank,(()=>`The number of provided coordinates (${t.length}) must match the rank (${this.rank})`));const r=this.locToIndex(t);this.values[r]=e}get(...e){0===e.length&&(e=[0]);let t=0;for(const r of e){if(r<0||r>=this.shape[t]){const t=`Requested out of range element at ${e}.   Buffer shape=${this.shape}`;throw new Error(t)}t++}let r=e[e.length-1];for(let t=0;t<e.length-1;++t)r+=this.strides[t]*e[t];return this.values[r]}locToIndex(e){if(0===this.rank)return 0;if(1===this.rank)return e[0];let t=e[e.length-1];for(let r=0;r<e.length-1;++r)t+=this.strides[r]*e[r];return t}indexToLoc(e){if(0===this.rank)return[];if(1===this.rank)return[e];const t=new Array(this.shape.length);for(let r=0;r<t.length-1;++r)t[r]=Math.floor(e/this.strides[r]),e-=t[r]*this.strides[r];return t[t.length-1]=e,t}get rank(){return this.shape.length}toTensor(){return ma().makeTensor(this.values,this.shape,this.dtype)}}let ma=null,ga=null;function ba(e){ma=e}function Ta(e){ga=e}class za{constructor(e,t,r,n){this.kept=!1,this.isDisposedInternal=!1,this.shape=e.slice(),this.dtype=t||"float32",this.size=Ee(e),this.strides=Pt(e),this.dataId=r,this.id=n,this.rankType=this.rank<5?this.rank.toString():"higher"}get rank(){return this.shape.length}async buffer(){const e=await this.data();return ga.buffer(this.shape,this.dtype,e)}bufferSync(){return ga.buffer(this.shape,this.dtype,this.dataSync())}async array(){const e=await this.data();return ot(this.shape,e,"complex64"===this.dtype)}arraySync(){return ot(this.shape,this.dataSync(),"complex64"===this.dtype)}async data(){this.throwIfDisposed();const e=ma().read(this.dataId);if("string"===this.dtype){const t=await e;try{return t.map((e=>ra(e)))}catch(e){throw new Error("Failed to decode the string bytes into utf-8. To get the original bytes, call tensor.bytes().")}}return e}dataToGPU(e){return this.throwIfDisposed(),ma().readToGPU(this.dataId,e)}dataSync(){this.throwIfDisposed();const e=ma().readSync(this.dataId);if("string"===this.dtype)try{return e.map((e=>ra(e)))}catch(e){throw new Error("Failed to decode the string bytes into utf-8. To get the original bytes, call tensor.bytes().")}return e}async bytes(){this.throwIfDisposed();const e=await ma().read(this.dataId);return"string"===this.dtype?e:new Uint8Array(e.buffer)}dispose(){this.isDisposed||(ma().disposeTensor(this),this.isDisposedInternal=!0)}get isDisposed(){return this.isDisposedInternal}throwIfDisposed(){if(this.isDisposed)throw new Error("Tensor is disposed.")}print(e=!1){return ga.print(this,e)}clone(){return this.throwIfDisposed(),ga.clone(this)}toString(e=!1){return la(this.dataSync(),this.shape,this.dtype,e)}cast(e){return this.throwIfDisposed(),ga.cast(this,e)}variable(e=!0,t,r){return this.throwIfDisposed(),ma().makeVariable(this,e,t,r)}}function da(){return yt("Tensor",(()=>za))}Object.defineProperty(za,Symbol.hasInstance,{value:e=>!!e&&null!=e.data&&null!=e.dataSync&&null!=e.throwIfDisposed}),da();class ya extends za{constructor(e,t,r,n){super(e.shape,e.dtype,e.dataId,n),this.trainable=t,this.name=r}assign(e){if(e.dtype!==this.dtype)throw new Error(`dtype of the new value (${e.dtype}) and previous value (${this.dtype}) must match`);if(!Qe(e.shape,this.shape))throw new Error(`shape of the new value (${e.shape}) and previous value (${this.shape}) must match`);ma().disposeTensor(this),this.dataId=e.dataId,ma().incRef(this,null)}dispose(){ma().disposeVariable(this),this.isDisposedInternal=!0}}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
var b,T,z,d,y;Object.defineProperty(ya,Symbol.hasInstance,{value:e=>e instanceof za&&null!=e.assign&&e.assign instanceof Function}),function(e){e.R0="R0",e.R1="R1",e.R2="R2",e.R3="R3",e.R4="R4",e.R5="R5",e.R6="R6"}(b||(b={})),function(e){e.float32="float32",e.int32="int32",e.bool="int32",e.complex64="complex64"}(T||(T={})),function(e){e.float32="float32",e.int32="int32",e.bool="bool",e.complex64="complex64"}(z||(z={})),function(e){e.float32="float32",e.int32="float32",e.bool="float32",e.complex64="complex64"}(d||(d={})),function(e){e.float32="complex64",e.int32="complex64",e.bool="complex64",e.complex64="complex64"}(y||(y={}));const wa={float32:d,int32:T,bool:z,complex64:y};function La(e,t){if("string"===e||"string"===t){if("string"===e&&"string"===t)return"string";throw new Error(`Can not upcast ${e} with ${t}`)}return wa[e][t]}function fa(e){return La(e,"int32")}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ia(e,t){if(e.dtype===t.dtype)return[e,t];const r=La(e.dtype,t.dtype);return[e.cast(r),t.cast(r)]}function Sa(e,t){xe(e.dtype===t.dtype,(()=>`The dtypes of the first(${e.dtype}) and second(${t.dtype}) input must match`))}function Aa(e){const t=[];return xa(e,t,new Set),t}function xa(e,t,r){if(null==e)return;if(e instanceof za)return void t.push(e);if(!Ya(e))return;const n=e;for(const e in n){const P=n[e];r.has(P)||(r.add(P),xa(P,t,r))}}function Ya(e){return Array.isArray(e)||"object"==typeof e}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ka(e){return null!=e.kernelName}class Ca{constructor(){this.registeredVariables={},this.nextTapeNodeId=0,this.numBytes=0,this.numTensors=0,this.numStringTensors=0,this.numDataBuffers=0,this.gradientDepth=0,this.kernelDepth=0,this.scopeStack=[],this.numDataMovesStack=[],this.nextScopeId=0,this.tensorInfo=new WeakMap,this.profiling=!1,this.activeProfile={newBytes:0,newTensors:0,peakBytes:0,kernels:[],result:null,get kernelNames(){return Array.from(new Set(this.kernels.map((e=>e.name))))}}}dispose(){for(const e in this.registeredVariables)this.registeredVariables[e].dispose()}}class Ea{constructor(e){this.ENV=e,this.registry={},this.registryFactory={},this.pendingBackendInitId=0,this.state=new Ca}async ready(){if(null!=this.pendingBackendInit)return this.pendingBackendInit.then((()=>{}));if(null!=this.backendInstance)return;const e=this.getSortedBackends();for(let t=0;t<e.length;t++){const r=e[t];if(await this.initializeBackend(r).success)return void await this.setBackend(r)}throw new Error("Could not initialize any backends, all backend initializations failed.")}get backend(){if(null!=this.pendingBackendInit)throw new Error(`Backend '${this.backendName}' has not yet been initialized. Make sure to await tf.ready() or await tf.setBackend() before calling other methods`);if(null==this.backendInstance){const{name:e,asyncInit:t}=this.initializeBackendsAndReturnBest();if(t)throw new Error(`The highest priority backend '${e}' has not yet been initialized. Make sure to await tf.ready() or await tf.setBackend() before calling other methods`);this.setBackend(e)}return this.backendInstance}backendNames(){return Object.keys(this.registryFactory)}findBackend(e){if(!(e in this.registry)){if(!(e in this.registryFactory))return null;{const{asyncInit:t}=this.initializeBackend(e);if(t)return null}}return this.registry[e]}findBackendFactory(e){return e in this.registryFactory?this.registryFactory[e].factory:null}registerBackend(e,t,r=1){return e in this.registryFactory?(mP(`${e} backend was already registered. Reusing existing backend factory.`),!1):(this.registryFactory[e]={factory:t,priority:r},!0)}async setBackend(e){if(null==this.registryFactory[e])throw new Error(`Backend name '${e}' not found in registry`);if(this.backendName=e,null==this.registry[e]){this.backendInstance=null;const{success:t,asyncInit:r}=this.initializeBackend(e);if(!(r?await t:t))return!1}return this.backendInstance=this.registry[e],this.setupRegisteredKernels(),this.profiler=new na(this.backendInstance),!0}setupRegisteredKernels(){yP(this.backendName).forEach((e=>{null!=e.setupFunc&&e.setupFunc(this.backendInstance)}))}disposeRegisteredKernels(e){yP(e).forEach((t=>{null!=t.disposeFunc&&t.disposeFunc(this.registry[e])}))}initializeBackend(e){const t=this.registryFactory[e];if(null==t)throw new Error(`Cannot initialize backend ${e}, no registration found.`);try{const r=t.factory();if(!r||r instanceof we||"function"!=typeof r.then)return this.registry[e]=r,{success:!0,asyncInit:!1};{const t=++this.pendingBackendInitId,n=r.then((r=>!(t<this.pendingBackendInitId)&&(this.registry[e]=r,this.pendingBackendInit=null,!0))).catch((r=>(t<this.pendingBackendInitId||(this.pendingBackendInit=null,mP(`Initialization of backend ${e} failed`),mP(r.stack||r.message)),!1)));return this.pendingBackendInit=n,{success:n,asyncInit:!0}}}catch(t){return mP(`Initialization of backend ${e} failed`),mP(t.stack||t.message),{success:!1,asyncInit:!1}}}removeBackend(e){if(!(e in this.registryFactory))throw new Error(`${e} backend not found in registry`);this.backendName===e&&null!=this.pendingBackendInit&&this.pendingBackendInitId++,e in this.registry&&(this.disposeRegisteredKernels(e),this.registry[e].dispose(),delete this.registry[e]),delete this.registryFactory[e],this.backendName===e&&(this.pendingBackendInit=null,this.backendName=null,this.backendInstance=null)}getSortedBackends(){if(0===Object.keys(this.registryFactory).length)throw new Error("No backend found in registry.");return Object.keys(this.registryFactory).sort(((e,t)=>this.registryFactory[t].priority-this.registryFactory[e].priority))}initializeBackendsAndReturnBest(){const e=this.getSortedBackends();for(let t=0;t<e.length;t++){const r=e[t],{success:n,asyncInit:P}=this.initializeBackend(r);if(P||n)return{name:r,asyncInit:P}}throw new Error("Could not initialize any backends, all backend initializations failed.")}moveData(e,t){const r=this.state.tensorInfo.get(t),n=r.backend,P=this.readSync(t),a=n.refCount(t);n.disposeData(t,!0),r.backend=e,e.move(t,P,r.shape,r.dtype,a),this.shouldCheckForMemLeaks()&&this.state.numDataMovesStack[this.state.numDataMovesStack.length-1]++}tidy(e,t){let r,n=null;if(null==t){if("function"!=typeof e)throw new Error("Please provide a function to tidy()");t=e}else{if("string"!=typeof e&&!(e instanceof String))throw new Error("When calling with two arguments, the first argument to tidy() must be a string");if("function"!=typeof t)throw new Error("When calling with two arguments, the 2nd argument to tidy() must be a function");n=e}return this.scopedRun((()=>this.startScope(n)),(()=>this.endScope(r)),(()=>(r=t(),r instanceof Promise&&console.error("Cannot return a Promise inside of tidy."),r)))}scopedRun(e,t,r){e();try{const e=r();return t(),e}catch(e){throw t(),e}}nextTensorId(){return Ea.nextTensorId++}nextVariableId(){return Ea.nextVariableId++}clone(e){const t=Ua.runKernel(Yr,{x:e}),r={x:e};return this.addTapeNode(this.state.activeScope.name,r,[t],(e=>({x:()=>{const t={x:e},r={dtype:"float32"};return Ua.runKernel(Ft,t,r)}})),[],{}),t}runKernel(e,t,r){null==this.backendName&&this.backend;if(!(null!=zP(e,this.backendName)))throw new Error(`Kernel '${e}' not registered for backend '${this.backendName}'`);return this.runKernelFunc({kernelName:e,inputs:t,attrs:r})}shouldCheckForMemLeaks(){return this.ENV.getBool("IS_TEST")}checkKernelForMemLeak(e,t,r){const n=this.backend.numDataIds();let P=0;r.forEach((e=>{P+="complex64"===e.dtype?3:1}));const a=this.state.numDataMovesStack[this.state.numDataMovesStack.length-1],o=n-t-P-a;if(o>0)throw new Error(`Backend '${this.backendName}' has an internal memory leak (${o} data ids) after running '${e}'`)}runKernelFunc(e){let t,r=[];const n=this.isTapeOn(),P=this.state.numBytes,a=this.state.numTensors;let o,u;this.shouldCheckForMemLeaks()&&this.state.numDataMovesStack.push(0),null==this.backendName&&this.backend;const s=ka(e)?e.kernelName:null!=this.state.activeScope?this.state.activeScope.name:"";if(ka(e)){const{kernelName:t,inputs:P,attrs:a}=e;null==this.backendName&&this.backend;const s=zP(t,this.backendName);xe(null!=s,(()=>`Cannot find registered kernel '${t}' for backend '${this.backendName}'`)),o=()=>{const e=this.backend.numDataIds();u=s.kernelFunc({inputs:P,attrs:a,backend:this.backend});const o=Array.isArray(u)?u:[u];this.shouldCheckForMemLeaks()&&this.checkKernelForMemLeak(t,e,o);const v=o.map((e=>null!=e.rank?e:this.makeTensorFromTensorInfo(e)));if(n){const e=this.getTensorsForGradient(t,P,v);r=this.saveTensorsForBackwardMode(e)}return v}}else{const{forwardFunc:t}=e,P=e=>{n&&(r=e.map((e=>this.keep(this.clone(e)))))};o=()=>{const e=this.backend.numDataIds();u=this.tidy((()=>t(this.backend,P)));const r=Array.isArray(u)?u:[u];return this.shouldCheckForMemLeaks()&&this.checkKernelForMemLeak(s,e,r),r}}const{inputs:v,attrs:i}=e,l=ka(e)?null:e.backwardsFunc;let c;return this.scopedRun((()=>this.state.kernelDepth++),(()=>this.state.kernelDepth--),(()=>{this.ENV.getBool("DEBUG")||this.state.profiling?(c=this.profiler.profileKernel(s,v,(()=>o())),this.ENV.getBool("DEBUG")&&this.profiler.logKernelProfile(c),t=c.outputs):t=o()})),n&&this.addTapeNode(s,v,t,l,r,i),this.state.profiling&&this.state.activeProfile.kernels.push({name:s,bytesAdded:this.state.numBytes-P,totalBytesSnapshot:this.state.numBytes,tensorsAdded:this.state.numTensors-a,totalTensorsSnapshot:this.state.numTensors,inputShapes:Object.keys(v).map((e=>null!=v[e]?v[e].shape:null)),outputShapes:t.map((e=>e.shape)),kernelTimeMs:c.timeMs,extraInfo:c.extraInfo}),Array.isArray(u)?t:t[0]}saveTensorsForBackwardMode(e){return e.map((e=>this.keep(this.clone(e))))}getTensorsForGradient(e,t,r){const n=dP(e);if(null!=n){const e=n.inputsToSave||[],P=n.outputsToSave||[];let a;n.saveAllInputs?(xe(Array.isArray(t),(()=>"saveAllInputs is true, expected inputs to be an array.")),a=Object.keys(t).map((e=>t[e]))):a=e.map((e=>t[e]));const o=r.filter(((e,t)=>P[t]));return a.concat(o)}return[]}makeTensor(e,t,r,n){if(null==e)throw new Error("Values passed to engine.makeTensor() are null");r=r||"float32",n=n||this.backend;let P=e;"string"===r&&_e(e[0])&&(P=e.map((e=>ta(e))));const a=n.write(P,t,r),o=new za(t,r,a,this.nextTensorId());if(this.trackTensor(o,n),"string"===r){const e=this.state.tensorInfo.get(a),t=Je(P);this.state.numBytes+=t-e.bytes,e.bytes=t}return o}makeTensorFromDataId(e,t,r,n){const P={dataId:e,shape:t,dtype:r=r||"float32"};return this.makeTensorFromTensorInfo(P,n)}makeTensorFromTensorInfo(e,t){const{dataId:r,shape:n,dtype:P}=e,a=new za(n,P,r,this.nextTensorId());return this.trackTensor(a,t),a}makeVariable(e,t=!0,r,n){r=r||this.nextVariableId().toString(),null!=n&&n!==e.dtype&&(e=e.cast(n));const P=new ya(e,t,r,this.nextTensorId());if(null!=this.state.registeredVariables[P.name])throw new Error(`Variable with name ${P.name} was already registered`);return this.state.registeredVariables[P.name]=P,this.incRef(P,this.backend),P}trackTensor(e,t){this.state.numTensors++,"string"===e.dtype&&this.state.numStringTensors++;let r=0;"complex64"!==e.dtype&&"string"!==e.dtype&&(r=e.size*He(e.dtype)),this.state.numBytes+=r,this.state.tensorInfo.has(e.dataId)||(this.state.numDataBuffers++,this.state.tensorInfo.set(e.dataId,{backend:t||this.backend,dtype:e.dtype,shape:e.shape,bytes:r})),e instanceof ya||this.track(e)}incRef(e,t){this.trackTensor(e,t),this.backend.incRef(e.dataId)}removeDataId(e,t){this.state.tensorInfo.has(e)&&this.state.tensorInfo.get(e).backend===t&&(this.state.tensorInfo.delete(e),this.state.numDataBuffers--)}disposeTensor(e){if(!this.state.tensorInfo.has(e.dataId))return;const t=this.state.tensorInfo.get(e.dataId);if(this.state.numTensors--,"string"===e.dtype&&(this.state.numStringTensors--,this.state.numBytes-=t.bytes),"complex64"!==e.dtype&&"string"!==e.dtype){const t=e.size*He(e.dtype);this.state.numBytes-=t}t.backend.disposeData(e.dataId)&&this.removeDataId(e.dataId,t.backend)}disposeVariables(){for(const e in this.state.registeredVariables){const t=this.state.registeredVariables[e];this.disposeVariable(t)}}disposeVariable(e){this.disposeTensor(e),null!=this.state.registeredVariables[e.name]&&delete this.state.registeredVariables[e.name]}memory(){const e=this.backend.memory();return e.numTensors=this.state.numTensors,e.numDataBuffers=this.state.numDataBuffers,e.numBytes=this.state.numBytes,this.state.numStringTensors>0&&(e.unreliable=!0,null==e.reasons&&(e.reasons=[]),e.reasons.push("Memory usage by string tensors is approximate (2 bytes per character)")),e}async profile(e){this.state.profiling=!0;const t=this.state.numBytes,r=this.state.numTensors;this.state.activeProfile.kernels=[],this.state.activeProfile.result=await e(),this.state.profiling=!1,this.state.activeProfile.peakBytes=Math.max(...this.state.activeProfile.kernels.map((e=>e.totalBytesSnapshot))),this.state.activeProfile.newBytes=this.state.numBytes-t,this.state.activeProfile.newTensors=this.state.numTensors-r;for(const e of this.state.activeProfile.kernels)e.kernelTimeMs=await e.kernelTimeMs,e.extraInfo=await e.extraInfo;return this.state.activeProfile}isTapeOn(){return this.state.gradientDepth>0&&0===this.state.kernelDepth}addTapeNode(e,t,r,n,P,a){const o={id:this.state.nextTapeNodeId++,kernelName:e,inputs:t,outputs:r,saved:P},u=dP(e);null!=u&&(n=u.gradFunc),null!=n&&(o.gradient=e=>(e=e.map(((e,t)=>{if(null==e){const e=r[t],n=st(e.size,e.dtype);return this.makeTensor(n,e.shape,e.dtype)}return e})),n(e.length>1?e:e[0],P,a))),this.state.activeTape.push(o)}keep(e){return e.kept=!0,e}startTape(){0===this.state.gradientDepth&&(this.state.activeTape=[]),this.state.gradientDepth++}endTape(){this.state.gradientDepth--}startScope(e){const t={track:[],name:"unnamed scope",id:this.state.nextScopeId++};e&&(t.name=e),this.state.scopeStack.push(t),this.state.activeScope=t}endScope(e){const t=Aa(e),r=new Set(t.map((e=>e.id)));for(let e=0;e<this.state.activeScope.track.length;e++){const t=this.state.activeScope.track[e];t.kept||r.has(t.id)||t.dispose()}const n=this.state.scopeStack.pop();this.state.activeScope=0===this.state.scopeStack.length?null:this.state.scopeStack[this.state.scopeStack.length-1],t.forEach((e=>{e.kept||e.scopeId!==n.id||this.track(e)}))}gradients(e,t,r,n=!1){if(xe(t.length>0,(()=>"gradients() received an empty list of xs.")),null!=r&&"float32"!==r.dtype)throw new Error(`dy must have 'float32' dtype, but has '${r.dtype}'`);const P=this.scopedRun((()=>this.startTape()),(()=>this.endTape()),(()=>this.tidy("forward",e)));xe(P instanceof za,(()=>"The result y returned by f() must be a tensor."));const a=oa(this.state.activeTape,t,P);if(!n&&0===a.length&&t.length>0)throw new Error("Cannot compute gradient of y=f(x) with respect to x. Make sure that the f you passed encloses all operations that lead from x to y.");return this.tidy("backward",(()=>{const e={};e[P.id]=null==r?Qa(P.shape):r,ua(e,a,(e=>this.tidy(e)),qa);const n=t.map((t=>e[t.id]));return 0===this.state.gradientDepth&&(this.state.activeTape.forEach((e=>{for(const t of e.saved)t.dispose()})),this.state.activeTape=null),{value:P,grads:n}}))}customGrad(e){return xe(rt(e),(()=>"The f passed in customGrad(f) must be a function.")),(...t)=>{let r;xe(t.every((e=>e instanceof za)),(()=>"The args passed in customGrad(f)(x1, x2,...) must all be tensors"));const n={};t.forEach(((e,t)=>{n[t]=e}));return this.runKernelFunc({forwardFunc:(n,P)=>(r=e(...t,P),xe(r.value instanceof za,(()=>"The function f passed in customGrad(f) must return an object where `obj.value` is a tensor")),xe(rt(r.gradFunc),(()=>"The function f passed in customGrad(f) must return an object where `obj.gradFunc` is a function.")),r.value),backwardsFunc:(e,n)=>{const P=r.gradFunc(e,n),a=Array.isArray(P)?P:[P];xe(a.length===t.length,(()=>"The function f passed in customGrad(f) must return an object where `obj.gradFunc` is a function that returns the same number of tensors as inputs passed to f(...).")),xe(a.every((e=>e instanceof za)),(()=>"The function f passed in customGrad(f) must return an object where `obj.gradFunc` is a function that returns a list of only tensors."));const o={};return a.forEach(((e,t)=>{o[t]=()=>e})),o},inputs:n})}}readSync(e){return this.state.tensorInfo.get(e).backend.readSync(e)}read(e){return this.state.tensorInfo.get(e).backend.read(e)}readToGPU(e,t){return this.state.tensorInfo.get(e).backend.readToGPU(e,t)}async time(e){const t=ea(),r=await this.backend.time(e);return r.wallMs=ea()-t,r}track(e){return null!=this.state.activeScope&&(e.scopeId=this.state.activeScope.id,this.state.activeScope.track.push(e)),e}get registeredVariables(){return this.state.registeredVariables}reset(){this.pendingBackendInitId++,this.state.dispose(),this.ENV.reset(),this.state=new Ca;for(const e in this.registry)this.disposeRegisteredKernels(e),this.registry[e].dispose(),delete this.registry[e];this.backendName=null,this.backendInstance=null,this.pendingBackendInit=null}}function Qa(e){const t=ut(Ee(e),"float32");return Ua.makeTensor(t,e,"float32")}function Wa(){const e=zt();if(null==e._tfengine){const t=new Dt(e);e._tfengine=new Ea(t)}return Tt(e._tfengine.ENV),ba((()=>e._tfengine)),e._tfengine}Ea.nextTensorId=0,Ea.nextVariableId=0;const Ua=Wa();function qa(e,t){const r={a:e,b:t};return Ua.runKernel(It,r)}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ga(e){if(e||"undefined"!=typeof navigator&&null!=navigator){if(e||(e=navigator),"ReactNative"===e.product)return!0;const t=e.userAgent||e.vendor||("undefined"!=typeof window?window.opera:"");if(!t){const t=e;return t.userAgentData&&t.userAgentData.mobile}return/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(t)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(t.substr(0,4))}return!1}function Ma(){return"undefined"!=typeof window&&null!=window.document||"undefined"!=typeof WorkerGlobalScope}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Ka=mt();
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function Na(e,t){let r=e;if(Xe(e))return"string"===t?[]:[e.length];if(!Array.isArray(e))return[];const n=[];for(;Array.isArray(r)||Xe(r)&&"string"!==t;)n.push(r.length),r=r[0];return Array.isArray(e)&&mt().getBool("TENSORLIKE_CHECK_SHAPE_CONSISTENCY")&&Ra(e,n,[]),n}function Ra(e,t,r){if(r=r||[],!Array.isArray(e)&&!Xe(e))return void xe(0===t.length,(()=>`Element arr[${r.join("][")}] is a primitive, but should be an array/TypedArray of ${t[0]} elements`));xe(t.length>0,(()=>`Element arr[${r.join("][")}] should be a primitive, but is an array of ${e.length} elements`)),xe(e.length===t[0],(()=>`Element arr[${r.join("][")}] should have ${t[0]} elements, but has ${e.length} elements`));const n=t.slice(1);for(let t=0;t<e.length;++t)Ra(e[t],n,r.concat(t))}function Fa(e,t,r,n){if("string_or_numeric"!==e){if(null==e)throw new Error("Expected dtype cannot be null.");if("numeric"!==e&&e!==t||"numeric"===e&&"string"===t)throw new Error(`Argument '${r}' passed to '${n}' must be ${e} tensor, but got ${t} tensor`)}}function Ba(e,t,r,n="numeric"){if(e instanceof za)return Fa(n,e.dtype,t,r),e;let P=tt(e);if("string"!==P&&["bool","int32","float32"].indexOf(n)>=0&&(P=n),Fa(n,P,t,r),null==e||!Xe(e)&&!Array.isArray(e)&&"number"!=typeof e&&"boolean"!=typeof e&&"string"!=typeof e){const n=null==e?"null":e.constructor.name;throw new Error(`Argument '${t}' passed to '${r}' must be a Tensor or TensorLike, but got '${n}'`)}const a=Na(e,P);Xe(e)||Array.isArray(e)||(e=[e]);const o="string"!==P?$P(e,P):Ce(e,[],!0);return Ua.makeTensor(o,a,P)}function Za(e,t,r,n="numeric"){if(!Array.isArray(e))throw new Error(`Argument ${t} passed to ${r} must be a \`Tensor[]\` or \`TensorLike[]\``);return e.map(((e,P)=>Ba(e,`${t}[${P}]`,r,n)))}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */Ka.registerFlag("DEBUG",(()=>!1),(e=>{e&&console.warn("Debugging mode is ON. The output of every math call will be downloaded to CPU and checked for NaNs. This significantly impacts performance.")})),Ka.registerFlag("IS_BROWSER",(()=>Ma())),Ka.registerFlag("IS_NODE",(()=>"undefined"!=typeof process&&void 0!==process.versions&&void 0!==process.versions.node)),Ka.registerFlag("IS_CHROME",(()=>"undefined"!=typeof navigator&&null!=navigator&&null!=navigator.userAgent&&/Chrome/.test(navigator.userAgent)&&/Google Inc/.test(navigator.vendor))),Ka.registerFlag("PROD",(()=>!1)),Ka.registerFlag("TENSORLIKE_CHECK_SHAPE_CONSISTENCY",(()=>Ka.getBool("DEBUG"))),Ka.registerFlag("DEPRECATION_WARNINGS_ENABLED",(()=>!0)),Ka.registerFlag("IS_TEST",(()=>!1)),Ka.registerFlag("CHECK_COMPUTATION_FOR_ERRORS",(()=>!0)),Ka.registerFlag("WRAP_TO_IMAGEBITMAP",(()=>!1)),Ka.registerFlag("ENGINE_COMPILE_ONLY",(()=>!1));const Va="__op";function Xa(e){const t=Object.keys(e);if(1!==t.length)throw new Error(`Please provide an object with a single key (operation name) mapping to a function. Got an object with ${t.length} keys.`);let r=t[0];const n=e[r];r.endsWith("_")&&(r=r.substring(0,r.length-1)),r+=Va;const P=(...e)=>{Ua.startScope(r);try{const t=n(...e);return ct(t)&&console.error("Cannot return a Promise inside of tidy."),Ua.endScope(t),t}catch(e){throw Ua.endScope(null),e}};return Object.defineProperty(P,"name",{value:r,configurable:!0}),P}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ha(e,t){const r=Ba(e,"real","complex"),n=Ba(t,"imag","complex");Ye(r.shape,n.shape,`real and imag shapes, ${r.shape} and ${n.shape}, must match in call to tf.complex().`);const P={real:r,imag:n};return Ua.runKernel(Vt,P)}const Ja=Xa({complex_:Ha});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function _a(e,t,r,n){if(null==n&&(n=tt(e)),"complex64"===n)throw new Error("Cannot construct a complex64 tensor directly. Please use tf.complex(real, imag).");if(!Xe(e)&&!Array.isArray(e)&&"number"!=typeof e&&"boolean"!=typeof e&&"string"!=typeof e)throw new Error("values passed to tensor(values) must be a number/boolean/string or an array of numbers/booleans/strings, or a TypedArray");if(null!=t){vt(t);const e=Ee(t),n=Ee(r);xe(e===n,(()=>`Based on the provided shape, [${t}], the tensor should have ${e} values but has ${n}`));for(let e=0;e<r.length;++e){const n=r[e],P=e!==r.length-1||n!==Ee(t.slice(e));xe(r[e]===t[e]||!P,(()=>`Error creating a new Tensor. Inferred shape (${r}) does not match the provided shape (${t}). `))}}return Xe(e)||Array.isArray(e)||(e=[e]),t=t||r,e="string"!==n?$P(e,n):Ce(e,[],!0),Ua.makeTensor(e,t,n)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function $a(e,t,r){return _a(e,t,Na(e,r),r)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const eo={float32:4,float16:2,int32:4,uint16:2,uint8:1,bool:1,complex64:8},to=4;
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */async function ro(e,t){const r=[],n=[],P=Array.isArray(e)?e.map((e=>e.name)):Object.keys(e);for(let a=0;a<P.length;++a){const o=P[a],u=Array.isArray(e)?e[a].tensor:e[o];if("float32"!==u.dtype&&"int32"!==u.dtype&&"bool"!==u.dtype&&"string"!==u.dtype&&"complex64"!==u.dtype)throw new Error(`Unsupported dtype in weight '${o}': ${u.dtype}`);const s={name:o,shape:u.shape,dtype:u.dtype};if("string"===u.dtype){const e=new Promise((async e=>{const t=await u.bytes(),r=t.reduce(((e,t)=>e+t.length),0)+to*t.length,n=new Uint8Array(r);let P=0;for(let e=0;e<t.length;e++){const r=t[e],a=new Uint8Array(new Uint32Array([r.length]).buffer);n.set(a,P),P+=to,n.set(r,P),P+=r.length}e(n)}));n.push(e)}else n.push(u.data());null!=t&&(s.group=t),r.push(s)}return{data:Po(await Promise.all(n)),specs:r}}function no(e,t){const r={};let n,P=0;for(const a of t){const t=a.name,o=a.dtype,u=a.shape,s=Ee(u);let v;if("quantization"in a){const r=a.quantization;if("uint8"===r.dtype||"uint16"===r.dtype){if(!("min"in r)||!("scale"in r))throw new Error(`Weight ${a.name} with quantization ${r.dtype} doesn't have corresponding metadata min and scale.`)}else{if("float16"!==r.dtype)throw new Error(`Weight ${a.name} has unknown quantization dtype ${r.dtype}. Supported quantization dtypes are: 'uint8', 'uint16', and 'float16'.`);if("float32"!==o)throw new Error(`Weight ${a.name} is quantized with ${r.dtype} which only supports weights of type float32 not ${o}.`)}const u=eo[r.dtype],i=e.slice(P,P+s*u),l="uint8"===r.dtype?new Uint8Array(i):new Uint16Array(i);if("float32"===o)if("uint8"===r.dtype||"uint16"===r.dtype){v=new Float32Array(l.length);for(let e=0;e<l.length;e++){const t=l[e];v[e]=t*r.scale+r.min}}else{if("float16"!==r.dtype)throw new Error(`Unsupported quantization type ${r.dtype} for weight type float32.`);void 0===n&&(n=po()),v=n(l)}else{if("int32"!==o)throw new Error(`Unsupported dtype in weight '${t}': ${o}`);if("uint8"!==r.dtype&&"uint16"!==r.dtype)throw new Error(`Unsupported quantization type ${r.dtype} for weight type int32.`);v=new Int32Array(l.length);for(let e=0;e<l.length;e++){const t=l[e];v[e]=Math.round(t*r.scale+r.min)}}P+=s*u}else if("string"===o){const t=Ee(a.shape);v=[];for(let r=0;r<t;r++){const t=new Uint32Array(e.slice(P,P+to))[0];P+=to;const r=new Uint8Array(e.slice(P,P+t));v.push(r),P+=t}}else{const n=eo[o],a=e.slice(P,P+s*n);if("float32"===o)v=new Float32Array(a);else if("int32"===o)v=new Int32Array(a);else if("bool"===o)v=new Uint8Array(a);else{if("complex64"!==o)throw new Error(`Unsupported dtype in weight '${t}': ${o}`);{v=new Float32Array(a);const e=new Float32Array(v.length/2),n=new Float32Array(v.length/2);for(let t=0;t<e.length;t++)e[t]=v[2*t],n[t]=v[2*t+1];const P=$a(e,u,"float32"),o=$a(n,u,"float32");r[t]=Ja(P,o),P.dispose(),o.dispose()}}P+=s*n}"complex64"!==o&&(r[t]=$a(v,u,o))}return r}function Po(e){if(null===e)throw new Error(`Invalid input value: ${JSON.stringify(e)}`);let t=0;const r=[];e.forEach((e=>{if(t+=e.byteLength,r.push(e.byteLength===e.buffer.byteLength?e:new e.constructor(e)),!(e instanceof Float32Array||e instanceof Int32Array||e instanceof Uint8Array))throw new Error(`Unsupported TypedArray subtype: ${e.constructor.name}`)}));const n=new Uint8Array(t);let P=0;return r.forEach((e=>{n.set(new Uint8Array(e.buffer),P),P+=e.byteLength})),n.buffer}const ao="undefined"!=typeof Buffer&&("undefined"==typeof Blob||"undefined"==typeof atob||"undefined"==typeof btoa);function oo(e){return ao?Buffer.byteLength(e):new Blob([e]).size}function uo(e){if(ao)return Buffer.from(e).toString("base64");const t=new Uint8Array(e);let r="";for(let e=0,n=t.length;e<n;e++)r+=String.fromCharCode(t[e]);return btoa(r)}function so(e){if(ao){const t=Buffer.from(e,"base64");return t.buffer.slice(t.byteOffset,t.byteOffset+t.byteLength)}const t=atob(e),r=new Uint8Array(t.length);for(let e=0;e<t.length;++e)r.set([t.charCodeAt(e)],e);return r.buffer}function vo(e){if(1===e.length)return e[0];let t=0;e.forEach((e=>{t+=e.byteLength}));const r=new Uint8Array(t);let n=0;return e.forEach((e=>{r.set(new Uint8Array(e),n),n+=e.byteLength})),r.buffer}function io(e){for(e=e.trim();e.endsWith("/");)e=e.slice(0,e.length-1);const t=e.split("/");return t[t.length-1]}function lo(e,t){const r={modelTopology:e.modelTopology,format:e.format,generatedBy:e.generatedBy,convertedBy:e.convertedBy,weightsManifest:t};return null!=e.signature&&(r.signature=e.signature),null!=e.userDefinedMetadata&&(r.userDefinedMetadata=e.userDefinedMetadata),null!=e.modelInitializer&&(r.modelInitializer=e.modelInitializer),null!=e.trainingConfig&&(r.trainingConfig=e.trainingConfig),r}async function co(e,t){const r={modelTopology:e.modelTopology,format:e.format,generatedBy:e.generatedBy,convertedBy:e.convertedBy};if(null!=e.trainingConfig&&(r.trainingConfig=e.trainingConfig),null!=e.weightsManifest){const[n,P]=await t(e.weightsManifest);r.weightSpecs=n,r.weightData=P}return null!=e.signature&&(r.signature=e.signature),null!=e.userDefinedMetadata&&(r.userDefinedMetadata=e.userDefinedMetadata),null!=e.modelInitializer&&(r.modelInitializer=e.modelInitializer),r}function Oo(e){if(e.modelTopology instanceof ArrayBuffer)throw new Error("Expected JSON model topology, received ArrayBuffer.");return{dateSaved:new Date,modelTopologyType:"JSON",modelTopologyBytes:null==e.modelTopology?0:oo(JSON.stringify(e.modelTopology)),weightSpecsBytes:null==e.weightSpecs?0:oo(JSON.stringify(e.weightSpecs)),weightDataBytes:null==e.weightData?0:e.weightData.byteLength}}function Do(){const e=e=>{let t=e<<13,r=0;for(;0==(8388608&t);)r-=8388608,t<<=1;return t&=-8388609,r+=947912704,t|r},t=new Uint32Array(2048);t[0]=0;for(let r=1;r<1024;r++)t[r]=e(r);for(let e=1024;e<2048;e++)t[e]=939524096+(e-1024<<13);return t}function jo(){const e=new Uint32Array(64);e[0]=0,e[31]=1199570944,e[32]=2147483648,e[63]=3347054592;for(let t=1;t<31;t++)e[t]=t<<23;for(let t=33;t<63;t++)e[t]=2147483648+(t-32<<23);return e}function ho(){const e=new Uint32Array(64);for(let t=0;t<64;t++)e[t]=1024;return e[0]=e[32]=0,e}function po(){const e=Do(),t=jo(),r=ho();return n=>{const P=new ArrayBuffer(4*n.length),a=new Uint32Array(P);for(let P=0;P<n.length;P++){const o=n[P],u=e[r[o>>10]+(1023&o)]+t[o>>10];a[P]=u}return new Float32Array(P)}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class mo{constructor(){this.saveRouters=[],this.loadRouters=[]}static getInstance(){return null==mo.instance&&(mo.instance=new mo),mo.instance}static registerSaveRouter(e){mo.getInstance().saveRouters.push(e)}static registerLoadRouter(e){mo.getInstance().loadRouters.push(e)}static getSaveHandlers(e){return mo.getHandlers(e,"save")}static getLoadHandlers(e,t){return mo.getHandlers(e,"load",t)}static getHandlers(e,t,r){const n=[];return("load"===t?mo.getInstance().loadRouters:mo.getInstance().saveRouters).forEach((t=>{const P=t(e,r);null!==P&&n.push(P)})),n}}const go=e=>mo.registerSaveRouter(e),bo=e=>mo.registerLoadRouter(e),To=e=>mo.getSaveHandlers(e),zo=(e,t)=>mo.getLoadHandlers(e,t)
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */,yo="tensorflowjs",wo=1,Lo="models_store",fo="model_info_store";function Io(){if(!mt().getBool("IS_BROWSER"))throw new Error("Failed to obtain IndexedDB factory because the current environmentis not a web browser.");const e="undefined"==typeof window?self:window,t=e.indexedDB||e.mozIndexedDB||e.webkitIndexedDB||e.msIndexedDB||e.shimIndexedDB;if(null==t)throw new Error("The current browser does not appear to support IndexedDB.");return t}function So(e){const t=e.result;t.createObjectStore(Lo,{keyPath:"modelPath"}),t.createObjectStore(fo,{keyPath:"modelPath"})}class Ao{constructor(e){if(this.indexedDB=Io(),null==e||!e)throw new Error("For IndexedDB, modelPath must not be null, undefined or empty.");this.modelPath=e}async save(e){if(e.modelTopology instanceof ArrayBuffer)throw new Error("BrowserLocalStorage.save() does not support saving model topology in binary formats yet.");return this.databaseAction(this.modelPath,e)}async load(){return this.databaseAction(this.modelPath)}databaseAction(e,t){return new Promise(((e,r)=>{const n=this.indexedDB.open(yo,wo);n.onupgradeneeded=()=>So(n),n.onsuccess=()=>{const P=n.result;if(null==t){const t=P.transaction(Lo,"readonly"),n=t.objectStore(Lo).get(this.modelPath);n.onsuccess=()=>{if(null==n.result)return P.close(),r(new Error(`Cannot find model with path '${this.modelPath}' in IndexedDB.`));e(n.result.modelArtifacts)},n.onerror=e=>(P.close(),r(n.error)),t.oncomplete=()=>P.close()}else{const n=Oo(t),a=P.transaction(fo,"readwrite");let o=a.objectStore(fo);const u=o.put({modelPath:this.modelPath,modelArtifactsInfo:n});let s;u.onsuccess=()=>{s=P.transaction(Lo,"readwrite");const u=s.objectStore(Lo).put({modelPath:this.modelPath,modelArtifacts:t,modelArtifactsInfo:n});u.onsuccess=()=>e({modelArtifactsInfo:n}),u.onerror=e=>{o=a.objectStore(fo);const t=o.delete(this.modelPath);t.onsuccess=()=>(P.close(),r(u.error)),t.onerror=e=>(P.close(),r(u.error))}},u.onerror=e=>(P.close(),r(u.error)),a.oncomplete=()=>{null==s?P.close():s.oncomplete=()=>P.close()}}},n.onerror=e=>r(n.error)}))}}Ao.URL_SCHEME="indexeddb://";const xo=e=>mt().getBool("IS_BROWSER")&&!Array.isArray(e)&&e.startsWith(Ao.URL_SCHEME)?Yo(e.slice(Ao.URL_SCHEME.length)):null;function Yo(e){return new Ao(e)}function ko(e){return e.startsWith(Ao.URL_SCHEME)?e.slice(Ao.URL_SCHEME.length):e}mo.registerSaveRouter(xo),mo.registerLoadRouter(xo);class Co{constructor(){this.indexedDB=Io()}async listModels(){return new Promise(((e,t)=>{const r=this.indexedDB.open(yo,wo);r.onupgradeneeded=()=>So(r),r.onsuccess=()=>{const n=r.result,P=n.transaction(fo,"readonly"),a=P.objectStore(fo).getAll();a.onsuccess=()=>{const t={};for(const e of a.result)t[e.modelPath]=e.modelArtifactsInfo;e(t)},a.onerror=e=>(n.close(),t(a.error)),P.oncomplete=()=>n.close()},r.onerror=e=>t(r.error)}))}async removeModel(e){return e=ko(e),new Promise(((t,r)=>{const n=this.indexedDB.open(yo,wo);n.onupgradeneeded=()=>So(n),n.onsuccess=()=>{const P=n.result,a=P.transaction(fo,"readwrite"),o=a.objectStore(fo),u=o.get(e);let s;u.onsuccess=()=>{if(null==u.result)return P.close(),r(new Error(`Cannot find model with path '${e}' in IndexedDB.`));{const n=o.delete(e),a=()=>{s=P.transaction(Lo,"readwrite");const n=s.objectStore(Lo).delete(e);n.onsuccess=()=>t(u.result.modelArtifactsInfo),n.onerror=e=>r(u.error)};n.onsuccess=a,n.onerror=e=>(a(),P.close(),r(u.error))}},u.onerror=e=>(P.close(),r(u.error)),a.oncomplete=()=>{null==s?P.close():s.oncomplete=()=>P.close()}},n.onerror=e=>r(n.error)}))}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Eo="/",Qo="tensorflowjs_models",Wo="info",Uo="model_topology",qo="weight_specs",Go="weight_data",Mo="model_metadata";function Ko(e){return{info:[Qo,e,Wo].join(Eo),topology:[Qo,e,Uo].join(Eo),weightSpecs:[Qo,e,qo].join(Eo),weightData:[Qo,e,Go].join(Eo),modelMetadata:[Qo,e,Mo].join(Eo)}}function No(e){for(const t of Object.values(e))window.localStorage.removeItem(t)}function Ro(e){const t=e.split(Eo);if(t.length<3)throw new Error(`Invalid key format: ${e}`);return t.slice(1,t.length-1).join(Eo)}function Fo(e){return e.startsWith(Bo.URL_SCHEME)?e.slice(Bo.URL_SCHEME.length):e}class Bo{constructor(e){if(!mt().getBool("IS_BROWSER")||"undefined"==typeof window||void 0===window.localStorage)throw new Error("The current environment does not support local storage.");if(this.LS=window.localStorage,null==e||!e)throw new Error("For local storage, modelPath must not be null, undefined or empty.");this.modelPath=e,this.keys=Ko(this.modelPath)}async save(e){if(e.modelTopology instanceof ArrayBuffer)throw new Error("BrowserLocalStorage.save() does not support saving model topology in binary formats yet.");{const t=JSON.stringify(e.modelTopology),r=JSON.stringify(e.weightSpecs),n=Oo(e);try{this.LS.setItem(this.keys.info,JSON.stringify(n)),this.LS.setItem(this.keys.topology,t),this.LS.setItem(this.keys.weightSpecs,r),this.LS.setItem(this.keys.weightData,uo(e.weightData));const P={format:e.format,generatedBy:e.generatedBy,convertedBy:e.convertedBy,signature:null!=e.signature?e.signature:void 0,userDefinedMetadata:null!=e.userDefinedMetadata?e.userDefinedMetadata:void 0,modelInitializer:null!=e.modelInitializer?e.modelInitializer:void 0,trainingConfig:null!=e.trainingConfig?e.trainingConfig:void 0};return this.LS.setItem(this.keys.modelMetadata,JSON.stringify(P)),{modelArtifactsInfo:n}}catch(e){throw No(this.keys),new Error(`Failed to save model '${this.modelPath}' to local storage: size quota being exceeded is a possible cause of this failure: modelTopologyBytes=${n.modelTopologyBytes}, weightSpecsBytes=${n.weightSpecsBytes}, weightDataBytes=${n.weightDataBytes}.`)}}}async load(){const e=JSON.parse(this.LS.getItem(this.keys.info));if(null==e)throw new Error(`In local storage, there is no model with name '${this.modelPath}'`);if("JSON"!==e.modelTopologyType)throw new Error("BrowserLocalStorage does not support loading non-JSON model topology yet.");const t={},r=JSON.parse(this.LS.getItem(this.keys.topology));if(null==r)throw new Error(`In local storage, the topology of model '${this.modelPath}' is missing.`);t.modelTopology=r;const n=JSON.parse(this.LS.getItem(this.keys.weightSpecs));if(null==n)throw new Error(`In local storage, the weight specs of model '${this.modelPath}' are missing.`);t.weightSpecs=n;const P=this.LS.getItem(this.keys.modelMetadata);if(null!=P){const e=JSON.parse(P);t.format=e.format,t.generatedBy=e.generatedBy,t.convertedBy=e.convertedBy,null!=e.signature&&(t.signature=e.signature),null!=e.userDefinedMetadata&&(t.userDefinedMetadata=e.userDefinedMetadata),null!=e.modelInitializer&&(t.modelInitializer=e.modelInitializer),null!=e.trainingConfig&&(t.trainingConfig=e.trainingConfig)}const a=this.LS.getItem(this.keys.weightData);if(null==a)throw new Error(`In local storage, the binary weight values of model '${this.modelPath}' are missing.`);return t.weightData=so(a),t}}Bo.URL_SCHEME="localstorage://";const Zo=e=>mt().getBool("IS_BROWSER")&&!Array.isArray(e)&&e.startsWith(Bo.URL_SCHEME)?Vo(e.slice(Bo.URL_SCHEME.length)):null;function Vo(e){return new Bo(e)}mo.registerSaveRouter(Zo),mo.registerLoadRouter(Zo);class Xo{constructor(){xe(mt().getBool("IS_BROWSER"),(()=>"Current environment is not a web browser")),xe("undefined"==typeof window||void 0!==window.localStorage,(()=>"Current browser does not appear to support localStorage")),this.LS=window.localStorage}async listModels(){const e={},t=Qo+Eo,r=Eo+Wo;for(let n=0;n<this.LS.length;++n){const P=this.LS.key(n);if(P.startsWith(t)&&P.endsWith(r)){e[Ro(P)]=JSON.parse(this.LS.getItem(P))}}return e}async removeModel(e){const t=Ko(e=Fo(e));if(null==this.LS.getItem(t.info))throw new Error(`Cannot find model at path '${e}'`);const r=JSON.parse(this.LS.getItem(t.info));return No(t),r}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Ho="://";class Jo{constructor(){this.managers={}}static getInstance(){return null==Jo.instance&&(Jo.instance=new Jo),Jo.instance}static registerManager(e,t){xe(null!=e,(()=>"scheme must not be undefined or null.")),e.endsWith(Ho)&&(e=e.slice(0,e.indexOf(Ho))),xe(e.length>0,(()=>"scheme must not be an empty string."));const r=Jo.getInstance();xe(null==r.managers[e],(()=>`A model store manager is already registered for scheme '${e}'.`)),r.managers[e]=t}static getManager(e){const t=Jo.getInstance().managers[e];if(null==t)throw new Error(`Cannot find model manager for scheme '${e}'`);return t}static getSchemes(){return Object.keys(Jo.getInstance().managers)}}function _o(e){if(-1===e.indexOf(Ho))throw new Error(`The url string provided does not contain a scheme. Supported schemes are: ${Jo.getSchemes().join(",")}`);return{scheme:e.split(Ho)[0],path:e.split(Ho)[1]}}async function $o(e,t,r=!1){xe(e!==t,(()=>`Old path and new path are the same: '${e}'`));const n=mo.getLoadHandlers(e);xe(n.length>0,(()=>`Copying failed because no load handler is found for source URL ${e}.`)),xe(n.length<2,(()=>`Copying failed because more than one (${n.length}) load handlers for source URL ${e}.`));const P=n[0],a=mo.getSaveHandlers(t);xe(a.length>0,(()=>`Copying failed because no save handler is found for destination URL ${t}.`)),xe(a.length<2,(()=>`Copying failed because more than one (${n.length}) save handlers for destination URL ${t}.`));const o=a[0],u=_o(e).scheme,s=_o(e).path,v=u===_o(e).scheme,i=await P.load();r&&v&&await Jo.getManager(u).removeModel(s);const l=await o.save(i);return r&&!v&&await Jo.getManager(u).removeModel(s),l.modelArtifactsInfo}async function eu(){const e=Jo.getSchemes(),t={};for(const r of e){const e=await Jo.getManager(r).listModels();for(const n in e){t[r+Ho+n]=e[n]}}return t}async function tu(e){const t=_o(e);return Jo.getManager(t.scheme).removeModel(t.path)}async function ru(e,t){return $o(e,t,!1)}async function nu(e,t){return $o(e,t,!0)}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class Pu{fetch(e,t){return fetch(e,t)}now(){return performance.now()}encode(e,t){if("utf-8"!==t&&"utf8"!==t)throw new Error(`Browser's encoder only supports utf-8, but got ${t}`);return null==this.textEncoder&&(this.textEncoder=new TextEncoder),this.textEncoder.encode(e)}decode(e,t){return new TextDecoder(t).decode(e)}}if(mt().get("IS_BROWSER")){mt().setPlatform("browser",new Pu);try{Jo.registerManager(Bo.URL_SCHEME,new Xo)}catch(Te){}try{Jo.registerManager(Ao.URL_SCHEME,new Co)}catch(Te){}}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2020 Google Inc. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function au(e,t="float32",r){return t=t||"float32",vt(e),new pa(e,t,r)}
/**
     * @license
     * Copyright 2020 Google Inc. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ou(e,t){const r=Ba(e,"x","cast");if(!Ze(t))throw new Error(`Failed to cast to unknown dtype ${t}`);if("string"===t&&"string"!==r.dtype||"string"!==t&&"string"===r.dtype)throw new Error("Only strings can be casted to strings");const n={x:r},P={dtype:t};return Ua.runKernel(Ft,n,P)}const uu=Xa({cast_:ou});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function su(e){const t={x:Ba(e,"x","clone","string_or_numeric")};return Ua.runKernel(Yr,t)}const vu=Xa({clone_:su});
/**
     * @license
     * Copyright 2020 Google Inc. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function iu(e,t=!1){console.log(e.toString(t))}
/**
     * @license
     * Copyright 2020 Google Inc. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */Wa();Ta({buffer:au,cast:uu,clone:vu,print:iu});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
const lu="model",cu=".json",Ou=".weights.bin";function Du(e){return new Promise((e=>setTimeout(e))).then(e)}class ju{constructor(e){if(!mt().getBool("IS_BROWSER"))throw new Error("browserDownloads() cannot proceed because the current environment is not a browser.");e.startsWith(ju.URL_SCHEME)&&(e=e.slice(ju.URL_SCHEME.length)),null!=e&&0!==e.length||(e=lu),this.modelJsonFileName=e+cu,this.weightDataFileName=e+Ou}async save(e){if("undefined"==typeof document)throw new Error("Browser downloads are not supported in this environment since `document` is not present");const t=window.URL.createObjectURL(new Blob([e.weightData],{type:"application/octet-stream"}));if(e.modelTopology instanceof ArrayBuffer)throw new Error("BrowserDownloads.save() does not support saving model topology in binary formats yet.");{const r=lo(e,[{paths:["./"+this.weightDataFileName],weights:e.weightSpecs}]),n=window.URL.createObjectURL(new Blob([JSON.stringify(r)],{type:"application/json"})),P=null==this.modelJsonAnchor?document.createElement("a"):this.modelJsonAnchor;if(P.download=this.modelJsonFileName,P.href=n,await Du((()=>P.dispatchEvent(new MouseEvent("click")))),null!=e.weightData){const e=null==this.weightDataAnchor?document.createElement("a"):this.weightDataAnchor;e.download=this.weightDataFileName,e.href=t,await Du((()=>e.dispatchEvent(new MouseEvent("click"))))}return{modelArtifactsInfo:Oo(e)}}}}ju.URL_SCHEME="downloads://";class hu{constructor(e){if(null==e||e.length<1)throw new Error(`When calling browserFiles, at least 1 file is required, but received ${e}`);this.jsonFile=e[0],this.weightsFiles=e.slice(1)}async load(){return new Promise(((e,t)=>{const r=new FileReader;r.onload=r=>{const n=JSON.parse(r.target.result),P=n.modelTopology;if(null==P)return void t(new Error(`modelTopology field is missing from file ${this.jsonFile.name}`));if(null==n.weightsManifest)return void t(new Error(`weightManifest field is missing from file ${this.jsonFile.name}`));if(0===this.weightsFiles.length)return void e({modelTopology:P});const a=co(n,(e=>this.loadWeights(e)));e(a)},r.onerror=e=>t(`Failed to read model topology and weights manifest JSON from file '${this.jsonFile.name}'. BrowserFiles supports loading Keras-style tf.Model artifacts only.`),r.readAsText(this.jsonFile)}))}loadWeights(e){const t=[],r=[];for(const n of e)t.push(...n.weights),r.push(...n.paths);const n=this.checkManifestAndWeightFiles(e),P=r.map((e=>this.loadWeightsFile(e,n[e])));return Promise.all(P).then((e=>[t,vo(e)]))}loadWeightsFile(e,t){return new Promise(((r,n)=>{const P=new FileReader;P.onload=e=>{const t=e.target.result;r(t)},P.onerror=t=>n(`Failed to weights data from file of path '${e}'.`),P.readAsArrayBuffer(t)}))}checkManifestAndWeightFiles(e){const t=[],r=this.weightsFiles.map((e=>io(e.name))),n={};for(const P of e)P.paths.forEach((e=>{const P=io(e);if(-1!==t.indexOf(P))throw new Error(`Duplicate file basename found in weights manifest: '${P}'`);if(t.push(P),-1===r.indexOf(P))throw new Error(`Weight file with basename '${P}' is not provided.`);n[e]=this.weightsFiles[r.indexOf(P)]}));if(t.length!==this.weightsFiles.length)throw new Error(`Mismatch in the number of files in weights manifest (${t.length}) and the number of weight files provided (${this.weightsFiles.length}).`);return n}}const pu=e=>mt().getBool("IS_BROWSER")&&!Array.isArray(e)&&e.startsWith(ju.URL_SCHEME)?mu(e.slice(ju.URL_SCHEME.length)):null;function mu(e="model"){return new ju(e)}function gu(e){return new hu(e)}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function bu(e,t,r,n){!function(e){xe(null!=e&&Array.isArray(e)&&e.length>0,(()=>"promises must be a none empty array"))}(e),function(e,t){xe(e>=0&&e<=1,(()=>`Progress fraction must be in range [0, 1], but got startFraction ${e}`)),xe(t>=0&&t<=1,(()=>`Progress fraction must be in range [0, 1], but got endFraction ${t}`)),xe(t>=e,(()=>`startFraction must be no more than endFraction, but got startFraction ${e} and endFraction ${t}`))}(r=null==r?0:r,n=null==n?1:n);let P=0;return Promise.all(e.map((a=>(a.then((a=>{const o=r+ ++P/e.length*(n-r);return t(o),a})),a))))}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */async function Tu(e,t){null==t&&(t={});const r=null==t.fetchFunc?mt().platform.fetch:t.fetchFunc,n=e.map((e=>r(e,t.requestInit,{isBinary:!0}))),P=(null==t.onProgress?await Promise.all(n):await bu(n,t.onProgress,0,.5)).map((e=>e.arrayBuffer()));return null==t.onProgress?await Promise.all(P):await bu(P,t.onProgress,.5,1)}async function zu(e,t="",r,n){const P=du((e=>Tu(e,{requestInit:n})));return P(e,t,r)}function du(e){return async(t,r="",n)=>{const P=t.map((()=>!1)),a={},o=null!=n?n.map((()=>!1)):[],u=[];if(t.forEach(((e,t)=>{let r=0;e.weights.forEach((e=>{const s="quantization"in e?e.quantization.dtype:e.dtype,v=eo[s]*Ee(e.shape),i=()=>{P[t]=!0,null==a[t]&&(a[t]=[]),a[t].push({manifestEntry:e,groupOffset:r,sizeBytes:v})};null!=n?n.forEach(((t,r)=>{t===e.name&&(i(),o[r]=!0)})):i(),u.push(e.name),r+=v}))})),!o.every((e=>e))){const e=n.filter(((e,t)=>!o[t]));throw new Error(`Could not find weights in manifest with names: ${e.join(", ")}. \nManifest JSON has weights with names: ${u.join(", ")}.`)}const s=P.reduce(((e,t,r)=>(t&&e.push(r),e)),[]),v=[];s.forEach((e=>{t[e].paths.forEach((e=>{const t=r+(r.endsWith("/")?"":"/")+e;v.push(t)}))}));const i=await e(v),l={};let c=0;return s.forEach((e=>{const r=t[e].paths.length;let n=0;for(let e=0;e<r;e++)n+=i[c+e].byteLength;const P=new ArrayBuffer(n),o=new Uint8Array(P);let u=0;for(let e=0;e<r;e++){const t=new Uint8Array(i[c+e]);o.set(t,u),u+=t.byteLength}a[e].forEach((e=>{const t=no(P.slice(e.groupOffset,e.groupOffset+e.sizeBytes),[e.manifestEntry]);for(const e in t)l[e]=t[e]})),c+=r})),l}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */mo.registerSaveRouter(pu);const yu="application/octet-stream",wu="application/json";class Lu{constructor(e,t){if(this.DEFAULT_METHOD="POST",null==t&&(t={}),this.weightPathPrefix=t.weightPathPrefix,this.onProgress=t.onProgress,this.weightUrlConverter=t.weightUrlConverter,null!=t.fetchFunc?(xe("function"==typeof t.fetchFunc,(()=>"Must pass a function that matches the signature of `fetch` (see https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API)")),this.fetch=t.fetchFunc):this.fetch=mt().platform.fetch,xe(null!=e&&e.length>0,(()=>"URL path for http must not be null, undefined or empty.")),Array.isArray(e)&&xe(2===e.length,(()=>`URL paths for http must have a length of 2, (actual length is ${e.length}).`)),this.path=e,null!=t.requestInit&&null!=t.requestInit.body)throw new Error("requestInit is expected to have no pre-existing body, but has one.");this.requestInit=t.requestInit||{}}async save(e){if(e.modelTopology instanceof ArrayBuffer)throw new Error("BrowserHTTPRequest.save() does not support saving model topology in binary formats yet.");const t=Object.assign({method:this.DEFAULT_METHOD},this.requestInit);t.body=new FormData;const r=lo(e,[{paths:["./model.weights.bin"],weights:e.weightSpecs}]);t.body.append("model.json",new Blob([JSON.stringify(r)],{type:wu}),"model.json"),null!=e.weightData&&t.body.append("model.weights.bin",new Blob([e.weightData],{type:yu}),"model.weights.bin");const n=await this.fetch(this.path,t);if(n.ok)return{modelArtifactsInfo:Oo(e),responses:[n]};throw new Error(`BrowserHTTPRequest.save() failed due to HTTP response status ${n.status}.`)}async load(){const e=await this.fetch(this.path,this.requestInit);if(!e.ok)throw new Error(`Request to ${this.path} failed with status code ${e.status}. Please verify this URL points to the model JSON of the model to load.`);let t;try{t=await e.json()}catch(e){let t=`Failed to parse model JSON of response from ${this.path}.`;throw this.path.endsWith(".pb")?t+=" Your path contains a .pb file extension. Support for .pb models have been removed in TensorFlow.js 1.0 in favor of .json models. You can re-convert your Python TensorFlow model using the TensorFlow.js 1.0 conversion scripts or you can convert your.pb models with the 'pb2json'NPM script in the tensorflow/tfjs-converter repository.":t+=" Please make sure the server is serving valid JSON for this request.",new Error(t)}const r=t.modelTopology,n=t.weightsManifest;if(null==r&&null==n)throw new Error(`The JSON from HTTP path ${this.path} contains neither model topology or manifest for weights.`);return co(t,(e=>this.loadWeights(e)))}async loadWeights(e){const t=Array.isArray(this.path)?this.path[1]:this.path,[r,n]=fu(t),P=this.weightPathPrefix||r,a=[];for(const t of e)a.push(...t.weights);const o=[],u=[];for(const t of e)for(const e of t.paths)null!=this.weightUrlConverter?u.push(this.weightUrlConverter(e)):o.push(P+e+n);this.weightUrlConverter&&o.push(...await Promise.all(u));return[a,vo(await Tu(o,{requestInit:this.requestInit,fetchFunc:this.fetch,onProgress:this.onProgress}))]}}function fu(e){const t=e.lastIndexOf("/"),r=e.lastIndexOf("?");return[e.substring(0,t)+"/",r>t?e.substring(r):""]}function Iu(e){return null!=e.match(Lu.URL_SCHEME_REGEX)}Lu.URL_SCHEME_REGEX=/^https?:\/\//;const Su=(e,t)=>{if("undefined"==typeof fetch&&(null==t||null==t.fetchFunc))return null;{let r=!0;if(r=Array.isArray(e)?e.every((e=>Iu(e))):Iu(e),r)return Au(e,t)}return null};function Au(e,t){return new Lu(e,t)}function xu(e,t){return Au(e,t)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */mo.registerSaveRouter(Su),mo.registerLoadRouter(Su);class Yu{constructor(e){this.modelArtifacts=e}load(){return this.modelArtifacts}}class ku{constructor(e){this.saveHandler=e}save(e){return this.saveHandler(e)}}class Cu{constructor(e){e.load&&(this.load=()=>Promise.resolve(e.load())),e.save&&(this.save=t=>Promise.resolve(e.save(t)))}}function Eu(e,t,r,n){const P=arguments;return new Cu(Qu(...P))}function Qu(e,t,r,n){if(1===arguments.length){return null!=e.modelTopology||null!=e.weightSpecs?new Yu(e):(console.warn("Please call tf.io.fromMemory() with only one argument. The argument should be of type ModelArtifacts. The multi-argument signature of tf.io.fromMemory() has been deprecated and will be removed in a future release."),new Yu({modelTopology:e}))}return console.warn("Please call tf.io.fromMemory() with only one argument. The argument should be of type ModelArtifacts. The multi-argument signature of tf.io.fromMemory() has been deprecated and will be removed in a future release."),new Yu({modelTopology:e,weightSpecs:t,weightData:r,trainingConfig:n})}function Wu(e){return new ku(e)}function Uu(e){return new ku(e)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */var w=Object.freeze({__proto__:null,browserFiles:gu,browserHTTPRequest:xu,concatenateArrayBuffers:vo,decodeWeights:no,encodeWeights:ro,fromMemory:Eu,fromMemorySync:Qu,getLoadHandlers:zo,getModelArtifactsForJSON:co,getModelArtifactsInfoForJSON:Oo,getSaveHandlers:To,http:Au,isHTTPScheme:Iu,loadWeights:zu,registerLoadRouter:bo,registerSaveRouter:go,weightsLoaderFactory:du,withSaveHandler:Wu,withSaveHandlerSync:Uu,copyModel:ru,listModels:eu,moveModel:nu,removeModel:tu});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function qu(e,t,r=!1,n=!1){let P=Ba(e,"a","matMul"),a=Ba(t,"b","matMul");[P,a]=Ia(P,a);const o={a:P,b:a},u={transposeA:r,transposeB:n};return Ua.runKernel(Mt,o,u)}const Gu=Xa({matMul_:qu});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Mu(e,t,r=1,n=0){if(t<2)throw new Error(`Error in oneHot: depth must be >=2, but it is ${t}`);const P={indices:Ba(e,"indices","oneHot","int32")},a={depth:t,onValue:r,offValue:n};return Ua.runKernel(On,P,a)}const Ku=Xa({oneHot_:Mu});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Nu(){mt().set("PROD",!0)}function Ru(){return Ua}function Fu(e,t){return Ua.tidy(e,t)}function Bu(e){Aa(e).forEach((e=>e.dispose()))}function Zu(e){return Ua.keep(e)}function Vu(e,t,r=1){return Ua.registerBackend(e,t,r)}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Xu(e){const t={input:Ba(e,"input","imag")};return Ua.runKernel(Cr,t)}const Hu=Xa({imag_:Xu});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ju(e){const t={x:Ba(e,"x","neg")};return Ua.runKernel(on,t)}const _u=Xa({neg_:Ju});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function $u(e){const t={input:Ba(e,"input","real")};return Ua.runKernel(bn,t)}const es=Xa({real_:$u});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ts(e,t,r){const n=Ba(e,"x","transpose");if(null==t&&(t=n.shape.map(((e,t)=>t)).reverse()),xe(n.rank===t.length,(()=>`Error in transpose: rank of input ${n.rank} must match length of perm ${t}.`)),t.forEach((e=>{xe(e>=0&&e<n.rank,(()=>"All entries in 'perm' must be between 0 and "+(n.rank-1)+` but got ${t}`))})),n.rank<=1)return n.clone();const P={x:n},a={perm:t};return"complex64"===n.dtype?Fu((()=>{let e=es(n),t=Hu(n);return e=Ua.runKernel(uP,{x:e},a),t=Ua.runKernel(uP,{x:t},a),r&&(t=_u(t)),Ja(e,t)})):Ua.runKernel(uP,P,a)}const rs=Xa({transpose_:ts});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ns(e,t,r){const n=Ba(e,"labels","confusionMatrix"),P=Ba(t,"predictions","confusionMatrix");xe(null==r||r>0&&Number.isInteger(r),(()=>`If provided, numClasses must be a positive integer, but got ${r}`)),xe(1===n.rank,(()=>`Expected the rank of labels to be 1, but got ${n.rank}`)),xe(1===P.rank,(()=>`Expected the rank of predictions to be 1, but got ${P.rank}`)),xe(n.shape[0]===P.shape[0],(()=>`Mismatch in the number of examples: ${n.shape[0]} vs. ${P.shape[0]}. Labels and predictions should have the same number of elements.`)),xe(r>0&&Number.isInteger(r),(()=>`numClasses is required to be a positive integer, but got ${r}`));const a=Ku(uu(n,"int32"),r),o=Ku(uu(P,"int32"),r),u=rs(a),s=Gu(u,o);return uu(s,"int32")}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function Ps(e,t){const r=e.length,n=[];for(let P=0;P<r;P++){const a=r-1-P,o=e[a]||1;(t[t.length-1-P]||1)>1&&1===o&&n.unshift(a)}return n}function as(e,t){const r=[];for(let n=0;n<t.length;n++){const P=e[e.length-n-1],a=t.length-n-1,o=t[a];(null==P||1===P&&o>1)&&r.unshift(a)}return r}function os(e,t){const r=[],n=Math.max(e.length,t.length);for(let P=0;P<n;P++){let n=e[e.length-P-1];null==n&&(n=1);let a=t[t.length-P-1];if(null==a&&(a=1),1===n)r.unshift(a);else if(1===a)r.unshift(n);else{if(n!==a){throw Error(`Operands could not be broadcast together with shapes ${e} and ${t}.`)}r.unshift(n)}}return r}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function us(e,t,r){if(ke(e),null!=t&&3!==t.length)throw new Error("tensor3d() requires shape to have three numbers");const n=Na(e,r);if(3!==n.length&&1!==n.length)throw new Error("tensor3d() requires values to be number[][][] or flat/TypedArray");if(1===n.length&&null==t)throw new Error("tensor3d() requires shape to be provided when `values` are a flat array");return _a(e,t,n,r)}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */let ss;function vs(e,t=3){if(t>4)throw new Error("Cannot construct Tensor with more than 4 channels from pixels.");if(null==e)throw new Error("pixels passed to tf.browser.fromPixels() can not be null");let r=!1,n=!1,P=!1,a=!1,o=!1,u=!1;if(e.data instanceof Uint8Array)r=!0;else if("undefined"!=typeof ImageData&&e instanceof ImageData)n=!0;else if("undefined"!=typeof HTMLVideoElement&&e instanceof HTMLVideoElement)P=!0;else if("undefined"!=typeof HTMLImageElement&&e instanceof HTMLImageElement)a=!0;else if(null!=e.getContext)o=!0;else{if(!("undefined"!=typeof ImageBitmap&&e instanceof ImageBitmap))throw new Error(`pixels passed to tf.browser.fromPixels() must be either an HTMLVideoElement, HTMLImageElement, HTMLCanvasElement, ImageData in browser, or OffscreenCanvas, ImageData in webworker or {data: Uint32Array, width: number, height: number}, but was ${e.constructor.name}`);u=!0}if(P){const t=2;if(P&&e.readyState<t)throw new Error("The video element has not loaded data yet. Please wait for `loadeddata` event on the <video> element.")}if(null!=zP(OP,Ua.backendName)){const r={pixels:e},n={numChannels:t};return Ua.runKernel(OP,r,n)}const[s,v]=P?[e.videoWidth,e.videoHeight]:[e.width,e.height];let i,l;if(o)i=e.getContext("2d").getImageData(0,0,s,v).data;else if(n||r)i=e.data;else if(a||P||u){if(null==ss)if("undefined"==typeof document){if("undefined"==typeof OffscreenCanvas||"undefined"==typeof OffscreenCanvasRenderingContext2D)throw new Error("Cannot parse input in current context. Reason: OffscreenCanvas Context2D rendering is not supported.");ss=new OffscreenCanvas(1,1).getContext("2d")}else ss=document.createElement("canvas").getContext("2d",{willReadFrequently:!0});ss.canvas.width=s,ss.canvas.height=v,ss.drawImage(e,0,0,s,v),i=ss.getImageData(0,0,s,v).data}if(4===t)l=new Int32Array(i);else{const e=s*v;l=new Int32Array(e*t);for(let r=0;r<e;r++)for(let e=0;e<t;++e)l[r*t+e]=i[4*r+e]}return us(l,[v,s,t],"int32")}function is(e,t){const r=e.shape.length,n=t.shape.length;if(r<1)throw new Error(`tf.gatherND() expects the input to be rank 1 or higher, but the rank was ${r}.`);if(n<1)throw new Error(`tf.gatherND() expects the indices to be rank 1 or higher, but the rank was ${n}.`);if("int32"!==t.dtype)throw new Error(`tf.gatherND() expects the indices to be int32 type, but the dtype was ${t.dtype}.`);if(t.shape[n-1]>r)throw new Error(`index innermost dimension length must be <= tensor rank; saw: ${t.shape[n-1]} vs. ${r}`);if(0===Ee(e.shape))throw new Error(`Requested more than 0 entries, but input is empty. Input shape: ${e.shape}.`);const P=t.shape,a=P[P.length-1];let o=1;for(let e=0;e<P.length-1;++e)o*=P[e];const u=e.shape,s=P.slice();s.pop();let v=1;for(let e=a;e<r;++e)v*=u[e],s.push(u[e]);const i=[...Pt(e.shape).map((e=>e/v)),1].slice(0,a);return[s,o,v,i]}function ls(e,t,r){const n=t.rank>1?t.shape[t.rank-1]:1,P=t.rank>1?t.rank-1:1,a=`Must have updates.shape = indices.shape[:batchDim] + shape[sliceDim:], got updates.shape: ${r.shape}, indices.shape: ${t.shape}, shape: ${e}, sliceDim: ${n}, and batchDim: ${P}.`;if(r.rank<P)throw new Error(a+` update.rank < ${P}. `);if(e.length<n+(r.rank-P))throw new Error(a+` Output shape length < ${n+(r.rank-P)}`);if(r.rank!==P+e.length-n)throw new Error(a+" update.rank != "+(P+e.length-n));for(let e=0;e<P;++e)if(r.shape[e]!==t.shape[e])throw new Error(a+` updates.shape[${e}] (${r.shape[e]}) != indices.shape[${e}] (${t.shape[e]}).`);for(let t=0;t<r.rank-P;++t)if(r.shape[t+P]!==e[t+n])throw new Error(a+` updates.shape[${t+P}] (${r.shape[t+P]}) != shape[${t+P}] (${e[t+P]})`)}function cs(e,t,r){if(t.rank<1)throw new Error(`tf.scatterND() expects the indices to be rank 1 or higher, but the rank was ${t.rank}.`);if(e.rank<1)throw new Error(`tf.scatterND() expects the updates to be rank 1 or higher, but the rank was ${e.rank}.`);if("int32"!==t.dtype)throw new Error(`The dtype of 'indices' should be int32, but got dtype: ${t.dtype}`);if(r.length<1)throw new Error(`Output rank must be greater or equal to 1, but got shape: ${r}`);if(0===r.length){if(0===t.size)throw new Error(`Indices specified for empty output. indices shape: ${t.shape}`);if(0===e.size)throw new Error(`Updates specified for empty output. updates shape: ${e.shape}`)}ls(r,t,e)}function Os(e,t,r){const n=t.shape.length,P=n>1?t.shape[n-1]:1,a=r.length;let o=1;for(let e=P;e<a;++e)o*=r[e];const u=P<1?1:P;return{sliceRank:P,numUpdates:Ee(t.shape)/u,sliceSize:o,strides:[...Pt(r.slice(0,P)),1],outputSize:Ee(r)}}
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */Xa({confusionMatrix_:ns}),Xa({fromPixels_:vs});const Ds=-2,js=-1;function hs(e,t,r){const n=e.shape.length;xe(n===t.length,(()=>`Error in slice${n}D: Length of begin ${t} must match the rank of the array (${n}).`)),xe(n===r.length,(()=>`Error in slice${n}D: Length of size ${r} must match the rank of the array (${n}).`));for(let P=0;P<n;++P)xe(t[P]+r[P]<=e.shape[P],(()=>`Error in slice${n}D: begin[${P}] + size[${P}] (${t[P]+r[P]}) would overflow input.shape[${P}] (${e.shape[P]})`))}function ps(e){const t=[];let r=0;for(;e>0;)1&e&&t.push(r),e/=2,r++;return t}function ms(e,t,r){const n=[];for(let P=0;P<e.length;P++)n[P]=Math.ceil((t[P]-e[P])/r[P]);return n}function gs(e,t,r,n){const P=[...e];for(let e=P.length;e<n.length;e++)P.push(1);for(let e=0;e<r;e++)0===e?P[t]=1:(P.splice(t,0,1),P.pop());return P}function bs(e,t,r){return r<=e?r:r-(t-1)}function Ts(e,t){const r=[];for(let n=0;n<e;n++)r.push(t+n);return r}function zs(e,t,r,n,P,a,o,u,s){const v=e.length;let i=new Array(v),l=new Array(v),c=new Array(v);if(t.length&&r>0){const s=t[0],v=r+1;i=ds(o,s,v,n,e),l=ys(u,s,v,P,e),c=gs(a,s,v,e)}else for(let t=0;t<v;t++)i[t]=Ls(o,n,a,e,t,s),l[t]=fs(u,P,a,e,t,s),c[t]=ws(a,t,s);return{begin:i,end:l,strides:c}}function ds(e,t,r,n,P){const a=[...P],o=Ts(r,t);for(let P=0;P<a.length;P++)if(o.indexOf(P)>-1)a[P]=0;else{const o=bs(t,r,P);let u=n[o];e&1<<o&&(u=0),a[P]=u}return a}function ys(e,t,r,n,P){const a=[...P],o=Ts(r,t);for(let P=0;P<a.length;P++)if(o.indexOf(P)>-1)a[P]=Number.MAX_SAFE_INTEGER;else{const o=bs(t,r,P);let u=n[o];e&1<<o&&(u=Number.MAX_SAFE_INTEGER),a[P]=u}for(let e=0;e<a.length;e++){const t=P[e];a[e]<0&&(a[e]+=t),a[e]=fe(0,a[e],P[e])}return a}function ws(e,t,r){let n=e[t];return(r&1<<t||null==n)&&(n=1),n}function Ls(e,t,r,n,P,a){let o=t[P];const u=r[P]||1;(e&1<<P||a&1<<P||null==o)&&(o=u>0?Number.MIN_SAFE_INTEGER:Number.MAX_SAFE_INTEGER);const s=n[P];return o<0&&(o+=s),o=fe(0,o,s-1),o}function fs(e,t,r,n,P,a){let o=t[P];const u=r[P]||1;(e&1<<P||a&1<<P||null==o)&&(o=u>0?Number.MAX_SAFE_INTEGER:Number.MIN_SAFE_INTEGER);const s=n[P];return o<0&&(o+=s),o=u>0?fe(0,o,s):fe(-1,o,s-1),o}function Is(e,t,r){let n=r.length;for(let e=0;e<r.length;e++)if(r[e]>1){n=e;break}for(let P=n+1;P<r.length;P++)if(t[P]>0||r[P]!==e[P])return!1;return!0}function Ss(e,t){let r=e.length>0?e[e.length-1]:1;for(let n=0;n<e.length-1;n++)r+=e[n]*t[n];return r}function As(e,t,r){let n;const P=e.shape.length;let a;return n="number"==typeof t?[t,...new Array(P-1).fill(0)]:t.length<P?t.concat(new Array(P-t.length).fill(0)):t.slice(),n.forEach((e=>{xe(-1!==e,(()=>"slice() does not support negative begin indexing."))})),a=null==r?new Array(P).fill(-1):"number"==typeof r?[r,...new Array(P-1).fill(-1)]:r.length<P?r.concat(new Array(P-r.length).fill(-1)):r,a=a.map(((t,r)=>t>=0?t:(xe(-1===t,(()=>`Negative size values should be exactly -1 but got ${t} for the slice() size at index ${r}.`)),e.shape[r]-n[r]))),[n,a]}function xs(e,t,r,n,P,a,o,u,s){let v;if(null==n?(v=new Array(t.length),v.fill(1)):v=n,null!=o&&0!=(o&o-1))throw new Error("Multiple ellipses in slice is not allowed.");let i=!1;const l={dims:v.length,numAddAxisAfterEllipsis:0,begin:t.slice(),end:r.slice(),strides:v.slice(),beginMask:P,endMask:a,ellipsisMask:o,newAxisMask:u,shrinkAxisMask:s};for(let e=0;e<l.dims;e++)i&&0!=(1<<e&u)&&l.numAddAxisAfterEllipsis++,1<<e&o&&(i=!0);i||(l.ellipsisMask|=1<<l.dims,l.dims++);const c={dims:e.length,beginMask:0,endMask:0,beginValid:!1,endValid:!1};Ys(l,c);let O=!0,D=!0,j=!0;const h=[],p=[];for(let t=0;t<e.length;++t){if(0===c.strides[t])throw Error(`strides[${t}] must be non-zero`);const r=!!(c.shrinkAxisMask&1<<t),n=e[t];if(-1===n){h.push(r?1:-1);continue}const P=[c.beginMask&1<<t,c.endMask&1<<t],a=[c.strides[t]>0?0:-1,c.strides[t]>0?n:n-1];if(r&&c.strides[t]<=0)throw Error("only stride 1 allowed on non-range indexing.");j=j&&1===c.strides[t];const o=!!(c.beginMask&1<<t&&c.endMask&1<<t);if(c.beginValid&&c.endValid){if(r){const e=c.begin[t]<0?n+c.begin[t]:c.begin[t];if(c.begin[t]=e,c.end[t]=c.begin[t]+1,e<0||e>=n)throw Error(`slice index ${c.begin[t]} of dimension ${t} out of bounds.`)}else c.begin[t]=ks(c.begin[t],0,c.strides[t],n,P,a),c.end[t]=ks(c.end[t],1,c.strides[t],n,P,a);const e=1===c.strides[t]&&0===c.begin[t]&&c.end[t]===n;O=O&&e,D=D&&(0===t&&1===c.strides[t]||e)}else O=O&&1===c.strides[t]&&o,D=D&&(0===t&&1===c.strides[t]||o);let u,s=!1;if(c.beginValid&&c.endValid?(u=c.end[t]-c.begin[t],s=!0):r?(u=1,s=!0):o&&n>=0&&(u=c.strides[t]<0?-n:n,s=!0),s){let e;e=0===u||u<0!=c.strides[t]<0?0:Math.trunc(u/c.strides[t])+(u%c.strides[t]!=0?1:0),h.push(e)}else h.push(-1)}for(let e=0;e<c.finalShapeGatherIndices.length;++e){const t=c.finalShapeGatherIndices[e];t>=0?p.push(h[t]):t===Ds&&p.push(1)}const m=p.filter(((e,t)=>c.finalShapeGatherIndices[t]!==Ds));return{finalShapeSparse:m,finalShape:p,isIdentity:O,sliceDim0:D,isSimpleSlice:j,begin:c.begin,end:c.end,strides:c.strides}}function Ys(e,t){t.beginMask=0,t.endMask=0,t.shrinkAxisMask=0;let r=0;t.beginValid=null!=e.begin,t.endValid=null!=e.end,t.begin=new Array(t.dims),t.end=new Array(t.dims),t.strides=new Array(t.dims),t.finalShapeGatherIndices=[],t.finalShapeGatherIndicesSparse=[],t.inputShapeGatherIndicesSparse=new Array(t.dims);for(let n=0;n<e.dims;n++)if(1<<n&e.ellipsisMask){const P=Math.min(t.dims-(e.dims-n)+1+e.numAddAxisAfterEllipsis,t.dims);for(;r<P;r++)t.begin[r]=0,t.end[r]=0,t.strides[r]=1,t.beginMask|=1<<r,t.endMask|=1<<r,t.finalShapeGatherIndices.push(r),t.finalShapeGatherIndicesSparse.push(-1),t.inputShapeGatherIndicesSparse[r]=n}else if(1<<n&e.newAxisMask)t.finalShapeGatherIndices.push(Ds),t.finalShapeGatherIndicesSparse.push(-1);else{if(r===t.begin.length)throw Error(`Index out of range using input dim ${r}; input has only ${t.dims} dims, ${t.begin.length}.`);null!=e.begin&&(t.begin[r]=e.begin[n]),null!=e.end&&(t.end[r]=e.end[n]),t.strides[r]=e.strides[n],e.beginMask&1<<n&&(t.beginMask|=1<<r),e.endMask&1<<n&&(t.endMask|=1<<r),e.shrinkAxisMask&1<<n?(t.finalShapeGatherIndices.push(js),t.finalShapeGatherIndicesSparse.push(-1),t.shrinkAxisMask|=1<<r):(t.finalShapeGatherIndices.push(r),t.finalShapeGatherIndicesSparse.push(n)),t.inputShapeGatherIndicesSparse[r]=n,r++}}function ks(e,t,r,n,P,a){if(P[t])return r>0?a[t]:a[t+1&1];{const t=e<0?n+e:e;return t<a[0]?a[0]:t>a[1]?a[1]:t}}var L=Object.freeze({__proto__:null,assertParamsValid:hs,maskToAxes:ps,computeOutShape:ms,stridesWithElidedDims:gs,getNormalizedAxes:zs,startIndicesWithElidedDims:ds,stopIndicesWithElidedDims:ys,stridesForAxis:ws,startForAxis:Ls,stopForAxis:fs,isSliceContinous:Is,computeFlatOffset:Ss,parseSliceParams:As,sliceInfo:xs});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class Cs{getClassName(){return this.constructor.className}static fromConfig(e,t){return new e(t)}}class Es{constructor(){this.classNameMap={}}static getMap(){return null==Es.instance&&(Es.instance=new Es),Es.instance}static register(e){Es.getMap().classNameMap[e.className]=[e,e.fromConfig]}}function Qs(e){xe(null!=e.className,(()=>"Class being registered does not have the static className property defined.")),xe("string"==typeof e.className,(()=>"className is required to be a string, but got type "+typeof e.className)),xe(e.className.length>0,(()=>"Class being registered has an empty-string as its className, which is disallowed.")),Es.register(e)}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ws(e,t){let r=Ba(e,"a","add"),n=Ba(t,"b","add");[r,n]=Ia(r,n);const P={a:r,b:n};return Ua.runKernel(It,P)}const Us=Xa({add_:Ws});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function qs(e,t){let r=Ba(e,"a","floorDiv"),n=Ba(t,"b","floorDiv");[r,n]=Ia(r,n);const P={a:r,b:n};return Ua.runKernel(Lr,P)}const Gs=Xa({floorDiv_:qs});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ms(e,t){let r=Ba(e,"a","div"),n=Ba(t,"b","div");if([r,n]=Ia(r,n),"int32"===r.dtype&&"int32"===n.dtype)return Gs(r,n);const P={a:r,b:n};return Ua.runKernel(Dr,P,{})}const Ks=Xa({div_:Ms});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ns(e,t){let r=Ba(e,"a","mul"),n=Ba(t,"b","mul");[r,n]=Ia(r,n);const P={a:r,b:n};return Ua.runKernel(an,P)}const Rs=Xa({mul_:Ns});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Fs(e){const t=Ba(e,"x","abs");if("complex64"===t.dtype){const e={x:t};return Ua.runKernel(Xt,e)}{const e={x:t};return Ua.runKernel(wt,e)}}const Bs=Xa({abs_:Fs});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Zs(e){const t={x:Ba(e,"x","acos")};return Ua.runKernel(Lt,t)}const Vs=Xa({acos_:Zs});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Xs(e){const t={x:Ba(e,"x","acosh")};return Ua.runKernel(ft,t)}const Hs=Xa({acosh_:Xs});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Js(e){xe(Array.isArray(e),(()=>"The argument passed to tf.addN() must be a list of tensors")),xe(e.length>=1,(()=>`Must pass at least one tensor to tf.addN(), but got ${e.length}`));const t=e.map(((e,t)=>Ba(e,`tensors${t}`,"addN"))),r=t[0];t.forEach((e=>{if(e.dtype!==r.dtype)throw new Error("All tensors passed to tf.addN() must have the same dtype")})),t.forEach((e=>{if(!Qe(e.shape,r.shape))throw new Error("All tensors passed to tf.addN() must have the same shape")}));const n=t;return Ua.runKernel(St,n)}const _s=Xa({addN_:Js});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function $s(e,t=null,r=!1){const n={x:Ba(e,"x","all","bool")},P={axis:t,keepDims:r};return Ua.runKernel(At,n,P)}const ev=Xa({all_:$s});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function tv(e,t=null,r=!1){const n={x:Ba(e,"x","any","bool")},P={axis:t,keepDims:r};return Ua.runKernel(xt,n,P)}const rv=Xa({any_:tv});
/**
     * @license
     * Copyright 2020 Google Inc. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function nv(e,t=0){const r={x:Ba(e,"x","argMax")},n={axis:t};return Ua.runKernel(Yt,r,n)}const Pv=Xa({argMax_:nv});
/**
     * @license
     * Copyright 2020 Google Inc. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function av(e,t=0){const r={x:Ba(e,"x","argMin")},n={axis:t};return Ua.runKernel(kt,r,n)}const ov=Xa({argMin_:av});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function uv(e){const t={x:Ba(e,"x","asin")};return Ua.runKernel(Ct,t)}const sv=Xa({asin_:uv});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function vv(e){const t={x:Ba(e,"x","asinh")};return Ua.runKernel(Et,t)}const iv=Xa({asinh_:vv});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function lv(e){const t={x:Ba(e,"x","atan")};return Ua.runKernel(Qt,t)}const cv=Xa({atan_:lv});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ov(e,t){let r=Ba(e,"a","atan2"),n=Ba(t,"b","atan2");[r,n]=Ia(r,n);const P={a:r,b:n};return Ua.runKernel(Ut,P)}const Dv=Xa({atan2_:Ov});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function jv(e){const t={x:Ba(e,"x","atanh")};return Ua.runKernel(Wt,t)}const hv=Xa({atanh_:jv});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function pv(e,t,r,n,P="NHWC",a){return bv(e,[...t,e[3]],r,a,n,null,null,kv(P))}function mv(e,t,r,n,P,a,o="channelsLast"){const[u,s]=wv(t);let v;if("channelsLast"===o)v=[u,s,e[3],e[3]];else{if("channelsFirst"!==o)throw new Error(`Unknown dataFormat ${o}`);v=[u,s,e[1],e[1]]}return bv(e,v,r,n,P,a,!1,o)}function gv(e,t,r,n,P,a,o="NDHWC"){const[u,s,v]=Lv(t);let i,l;if("NDHWC"===o)l="channelsLast",i=[u,s,v,e[4],e[4]];else{if("NCDHW"!==o)throw new Error(`Unknown dataFormat ${o}`);l="channelsFirst",i=[u,s,v,e[1],e[1]]}return Tv(e,i,r,n,P,!1,l,a)}function bv(e,t,r,n,P,a,o=!1,u="channelsLast"){let[s,v,i,l]=[-1,-1,-1,-1];if("channelsLast"===u)[s,v,i,l]=e;else{if("channelsFirst"!==u)throw new Error(`Unknown dataFormat ${u}`);[s,l,v,i]=e}const[c,O,,D]=t,[j,h]=wv(r),[p,m]=wv(n),g=fv(c,p),b=fv(O,m),{padInfo:T,outHeight:z,outWidth:d}=Iv(P,v,i,j,h,g,b,a,u),y=o?D*l:D;let w;return"channelsFirst"===u?w=[s,y,z,d]:"channelsLast"===u&&(w=[s,z,d,y]),{batchSize:s,dataFormat:u,inHeight:v,inWidth:i,inChannels:l,outHeight:z,outWidth:d,outChannels:y,padInfo:T,strideHeight:j,strideWidth:h,filterHeight:c,filterWidth:O,effectiveFilterHeight:g,effectiveFilterWidth:b,dilationHeight:p,dilationWidth:m,inShape:e,outShape:w,filterShape:t}}function Tv(e,t,r,n,P,a=!1,o="channelsLast",u){let[s,v,i,l,c]=[-1,-1,-1,-1,-1];if("channelsLast"===o)[s,v,i,l,c]=e;else{if("channelsFirst"!==o)throw new Error(`Unknown dataFormat ${o}`);[s,c,v,i,l]=e}const[O,D,j,,h]=t,[p,m,g]=Lv(r),[b,T,z]=Lv(n),d=fv(O,b),y=fv(D,T),w=fv(j,z),{padInfo:L,outDepth:f,outHeight:I,outWidth:S}=Sv(P,v,i,l,p,m,g,d,y,w,u),A=a?h*c:h;let x;return"channelsFirst"===o?x=[s,A,f,I,S]:"channelsLast"===o&&(x=[s,f,I,S,A]),{batchSize:s,dataFormat:o,inDepth:v,inHeight:i,inWidth:l,inChannels:c,outDepth:f,outHeight:I,outWidth:S,outChannels:A,padInfo:L,strideDepth:p,strideHeight:m,strideWidth:g,filterDepth:O,filterHeight:D,filterWidth:j,effectiveFilterDepth:d,effectiveFilterHeight:y,effectiveFilterWidth:w,dilationDepth:b,dilationHeight:T,dilationWidth:z,inShape:e,outShape:x,filterShape:t}}function zv(e,t,r,n,P){null==n&&(n=yv(e,t,r));const a=e[0],o=e[1];return[Av((a-t+2*n)/r+1,P),Av((o-t+2*n)/r+1,P)]}function dv(e,t,r,n,P,a){null==P&&(P=yv(e,t,n));const o=e[0],u=e[1],s=e[2];return[Av((o-t+2*P)/n+1,a),Av((u-t+2*P)/n+1,a),Av((s-t+2*P)/n+1,a),r]}function yv(e,t,r,n=1){const P=fv(t,n);return Math.floor((e[0]*(r-1)-r+P)/2)}function wv(e){return"number"==typeof e?[e,e,e]:2===e.length?[e[0],e[1],1]:e}function Lv(e){return"number"==typeof e?[e,e,e]:e}function fv(e,t){return t<=1?e:e+(e-1)*(t-1)}function Iv(e,t,r,n,P,a,o,u,s){let v,i,l;if("number"==typeof e){v={top:e,bottom:e,left:e,right:e,type:0===e?"VALID":"NUMBER"};const P=zv([t,r],a,n,e,u);i=P[0],l=P[1]}else if("same"===e){i=Math.ceil(t/n),l=Math.ceil(r/P);const e=Math.max(0,(i-1)*n+a-t),u=Math.max(0,(l-1)*P+o-r),s=Math.floor(e/2),c=e-s,O=Math.floor(u/2);v={top:s,bottom:c,left:O,right:u-O,type:"SAME"}}else if("valid"===e)v={top:0,bottom:0,left:0,right:0,type:"VALID"},i=Math.ceil((t-a+1)/n),l=Math.ceil((r-o+1)/P);else{if("object"!=typeof e)throw Error(`Unknown padding parameter: ${e}`);{const c="channelsLast"===s?e[1][0]:e[2][0],O="channelsLast"===s?e[1][1]:e[2][1],D="channelsLast"===s?e[2][0]:e[3][0],j="channelsLast"===s?e[2][1]:e[3][1];v={top:c,bottom:O,left:D,right:j,type:0===c&&0===O&&0===D&&0===j?"VALID":"EXPLICIT"},i=Av((t-a+c+O)/n+1,u),l=Av((r-o+D+j)/P+1,u)}}return{padInfo:v,outHeight:i,outWidth:l}}function Sv(e,t,r,n,P,a,o,u,s,v,i){let l,c,O,D;if("number"==typeof e){l={top:e,bottom:e,left:e,right:e,front:e,back:e,type:0===e?"VALID":"NUMBER"};const a=dv([t,r,n,1],u,1,P,e,i);c=a[0],O=a[1],D=a[2]}else if("same"===e){c=Math.ceil(t/P),O=Math.ceil(r/a),D=Math.ceil(n/o);const e=(c-1)*P+u-t,i=(O-1)*a+s-r,j=(D-1)*o+v-n,h=Math.floor(e/2),p=e-h,m=Math.floor(i/2),g=i-m,b=Math.floor(j/2);l={top:m,bottom:g,left:b,right:j-b,front:h,back:p,type:"SAME"}}else{if("valid"!==e)throw Error(`Unknown padding parameter: ${e}`);l={top:0,bottom:0,left:0,right:0,front:0,back:0,type:"VALID"},c=Math.ceil((t-u+1)/P),O=Math.ceil((r-s+1)/a),D=Math.ceil((n-v+1)/o)}return{padInfo:l,outDepth:c,outHeight:O,outWidth:D}}function Av(e,t){if(!t)return Math.trunc(e);switch(t){case"round":return Math.round(e);case"ceil":return Math.ceil(e);case"floor":return Math.floor(e);default:throw new Error(`Unknown roundingMode ${t}`)}}function xv(e){const[t,r,n]=wv(e);return 1===t&&1===r&&1===n}function Yv(e,t){return xv(e)||xv(t)}function kv(e){if("NHWC"===e)return"channelsLast";if("NCHW"===e)return"channelsFirst";throw new Error(`Unknown dataFormat ${e}`)}function Cv(e,t,r){if(null!=r){if("string"==typeof t)throw Error(`Error in ${e}: pad must be an integer when using dimRoundingMode ${r} but got pad ${t}.`);if("number"==typeof t)xe(We(t),(()=>`Error in ${e}: pad must be an integer when using dimRoundingMode ${r} but got pad ${t}.`));else{if("object"!=typeof t)throw Error(`Error in ${e}: Unknown padding parameter: ${t}`);t.forEach((t=>{t.forEach((t=>{xe(We(t),(()=>`Error in ${e}: pad must be an integer when using dimRoundingMode ${r} but got pad ${t}.`))}))}))}}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ev(e,t){const r={x:Ba(e,"x","reshape","string_or_numeric")},n={shape:t};return Ua.runKernel(dn,r,n)}const Qv=Xa({reshape_:Ev});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Wv(e,t,r,n,P){const a=Ba(e,"x","avgPool","float32");xe(Yv(r,1),(()=>`Error in avgPool: Either strides or dilations must be 1. Got strides ${r} and dilations '1'`));let o=a,u=!1;3===a.rank&&(u=!0,o=Qv(a,[1,a.shape[0],a.shape[1],a.shape[2]])),xe(4===o.rank,(()=>`Error in avgPool: x must be rank 4 but got rank ${o.rank}.`)),Cv("avgPool",n,P);const s={x:o},v={filterSize:t,strides:r,pad:n,dimRoundingMode:P};let i=Ua.runKernel(qt,s,v);return i=uu(i,a.dtype),u?Qv(i,[i.shape[1],i.shape[2],i.shape[3]]):i}const Uv=Xa({avgPool_:Wv});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function qv(e,t,r,n,P,a="NDHWC"){const o=Ba(e,"x","avgPool3d","float32");let u=o,s=!1;4===o.rank&&(s=!0,u=Qv(o,[1,o.shape[0],o.shape[1],o.shape[2],o.shape[3]])),xe(5===u.rank,(()=>`Error in avgPool3d: x must be rank 5 but got rank ${u.rank}.`)),xe("NDHWC"===a,(()=>`Error in avgPool3d: Only NDHWC is currently supported, but got dataFormat of ${a}`)),Cv("avgPool3d",n,P);const v={x:u},i={filterSize:t,strides:r,pad:n,dimRoundingMode:P,dataFormat:a};let l=Ua.runKernel(Gt,v,i);return l=uu(l,u.dtype),s?Qv(l,[l.shape[1],l.shape[2],l.shape[3],l.shape[4]]):l}const Gv=Xa({avgPool3d_:qv});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Mv(e,t=0){xe(e.length>=1,(()=>"Pass at least one tensor to concat"));const r=Za(e,"tensors","concat","string_or_numeric");if("complex64"===r[0].dtype&&r.forEach((e=>{if("complex64"!==e.dtype)throw new Error(`Cannot concatenate complex64 tensors with a tensor\n          with dtype ${e.dtype}. `)})),1===r.length)return vu(r[0]);const n=r,P={axis:t};return Ua.runKernel(Ht,n,P)}const Kv=Xa({concat_:Mv});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Nv(e){const t={x:Ba(e,"x","sigmoid","float32")};return Ua.runKernel(Un,t)}const Rv=Xa({sigmoid_:Nv});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Fv(e,t,r){const n=Ba(e,"x","slice","string_or_numeric");if(0===n.rank)throw new Error("Slicing scalar is not possible");const P={x:n},a={begin:t,size:r};return Ua.runKernel(Cn,P,a)}const Bv=Xa({slice_:Fv});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Zv(e){const t={x:Ba(e,"x","tanh","float32")};return Ua.runKernel(nP,t)}const Vv=Xa({tanh_:Zv});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Xv(e,t,r,n,P,a){const o=Ba(e,"forgetBias","basicLSTMCell"),u=Ba(t,"lstmKernel","basicLSTMCell"),s=Ba(r,"lstmBias","basicLSTMCell"),v=Ba(n,"data","basicLSTMCell"),i=Ba(P,"c","basicLSTMCell"),l=Ba(a,"h","basicLSTMCell"),c=Kv([v,l],1),O=Gu(c,u),D=Us(O,s),j=D.shape[0],h=D.shape[1]/4,p=[j,h],m=Bv(D,[0,0],p),g=Bv(D,[0,h],p),b=Bv(D,[0,2*h],p),T=Bv(D,[0,3*h],p),z=Us(Rs(Rv(m),Vv(g)),Rs(i,Rv(Us(o,b))));return[z,Rs(Vv(z),Rv(T))]}const Hv=Xa({basicLSTMCell_:Xv});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Jv(e,t,r){const n=Ba(e,"x","batchToSpaceND"),P=t.reduce(((e,t)=>e*t));xe(n.rank>=1+t.length,(()=>`input rank is ${n.rank} but should be > than blockShape.length ${t.length}`)),xe(r.length===t.length,(()=>`crops.length is ${r.length} but should be equal to blockShape.length  ${t.length}`)),xe(n.shape[0]%P==0,(()=>`input tensor batch is ${n.shape[0]} but is not divisible by the product of the elements of blockShape ${t.join(" * ")} === ${P}`));const a={x:n},o={blockShape:t,crops:r};return Ua.runKernel(Kt,a,o)}const _v=Xa({batchToSpaceND_:Jv});function $v(e){let t;return t=0===e.rank||1===e.rank?Qv(e,[1,1,1,e.size]):2===e.rank?Qv(e,[1,1,e.shape[0],e.shape[1]]):3===e.rank?Qv(e,[1,e.shape[0],e.shape[1],e.shape[2]]):e,t}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ei(e,t,r,n,P,a){null==a&&(a=.001);const o=Ba(e,"x","batchNorm"),u=Ba(t,"mean","batchNorm"),s=Ba(r,"variance","batchNorm");let v,i;null!=P&&(v=Ba(P,"scale","batchNorm")),null!=n&&(i=Ba(n,"offset","batchNorm")),xe(u.rank===s.rank,(()=>"Batch normalization gradient requires mean and variance to have equal ranks.")),xe(null==i||u.rank===i.rank,(()=>"Batch normalization gradient requires mean and offset to have equal ranks.")),xe(null==v||u.rank===v.rank,(()=>"Batch normalization gradient requires mean and scale to have equal ranks."));const l={x:$v(o),scale:v,offset:i,mean:u,variance:s},c={varianceEpsilon:a},O=Ua.runKernel(fr,l,c);return Qv(O,o.shape)}const ti=Xa({batchNorm_:ei});function ri(e,t,r,n,P,a){const o=Ba(e,"x","batchNorm"),u=Ba(t,"mean","batchNorm"),s=Ba(r,"variance","batchNorm");let v,i;return null!=P&&(v=Ba(P,"scale","batchNorm")),null!=n&&(i=Ba(n,"offset","batchNorm")),xe(2===o.rank,(()=>`Error in batchNorm2D: x must be rank 2 but got rank ${o.rank}.`)),xe(2===u.rank||1===u.rank,(()=>`Error in batchNorm2D: mean must be rank 2 or rank 1 but got rank ${u.rank}.`)),xe(2===s.rank||1===s.rank,(()=>`Error in batchNorm2D: variance must be rank 2 or rank 1 but got rank ${s.rank}.`)),null!=v&&xe(2===v.rank||1===v.rank,(()=>`Error in batchNorm2D: scale must be rank 2 or rank 1 but got rank ${v.rank}.`)),null!=i&&xe(2===i.rank||1===i.rank,(()=>`Error in batchNorm2D: offset must be rank 2 or rank 1 but got rank ${i.rank}.`)),ti(o,u,s,i,v,a)}const ni=Xa({batchNorm2d_:ri});function Pi(e,t,r,n,P,a){const o=Ba(e,"x","batchNorm"),u=Ba(t,"mean","batchNorm"),s=Ba(r,"variance","batchNorm");let v,i;return null!=P&&(v=Ba(P,"scale","batchNorm")),null!=n&&(i=Ba(n,"offset","batchNorm")),xe(3===o.rank,(()=>`Error in batchNorm3D: x must be rank 3 but got rank ${o.rank}.`)),xe(3===u.rank||1===u.rank,(()=>`Error in batchNorm3D: mean must be rank 3 or rank 1 but got rank ${u.rank}.`)),xe(3===s.rank||1===s.rank,(()=>`Error in batchNorm3D: variance must be rank 3 or rank 1 but got rank ${s.rank}.`)),null!=v&&xe(3===v.rank||1===v.rank,(()=>`Error in batchNorm3D: scale must be rank 3 or rank 1 but got rank ${v.rank}.`)),null!=i&&xe(3===i.rank||1===i.rank,(()=>`Error in batchNorm3D: offset must be rank 3 or rank 1 but got rank ${i.rank}.`)),ti(o,u,s,i,v,a)}const ai=Xa({batchNorm3d_:Pi});function oi(e,t,r,n,P,a){const o=Ba(e,"x","batchNorm"),u=Ba(t,"mean","batchNorm"),s=Ba(r,"variance","batchNorm");let v,i;return null!=P&&(v=Ba(P,"scale","batchNorm")),null!=n&&(i=Ba(n,"offset","batchNorm")),xe(4===o.rank,(()=>`Error in batchNorm4D: x must be rank 4 but got rank ${o.rank}.`)),xe(4===u.rank||1===u.rank,(()=>`Error in batchNorm4D: mean must be rank 4 or rank 1 but got rank ${u.rank}.`)),xe(4===s.rank||1===s.rank,(()=>`Error in batchNorm4D: variance must be rank 4 or rank 1 but got rank ${s.rank}.`)),null!=v&&xe(4===v.rank||1===v.rank,(()=>`Error in batchNorm4D: scale must be rank 4 or rank 1 but got rank ${v.rank}.`)),null!=i&&xe(4===i.rank||1===i.rank,(()=>`Error in batchNorm4D: offset must be rank 4 or rank 1 but got rank ${i.rank}.`)),ti(o,u,s,i,v,a)}const ui=Xa({batchNorm4d_:oi});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function si(e,t,r){const n=Ba(e,"x","bincount"),P=Ba(t,"weights","bincount");xe("int32"===n.dtype,(()=>`Error in bincount: input dtype must be int32, but got ${n.dtype}`)),xe(r>=0,(()=>`size must be non-negative, but got ${r}.`)),xe(P.size===n.size||0===P.size,(()=>`Error in bincount: weights must have the same size as input or0-length, but got input shape: ${n.shape}, weights shape: ${P.shape}.`));const a={x:n,weights:P},o={size:r};return Ua.runKernel(Nt,a,o)}const vi=Xa({bincount_:si});
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ii(e,t){const r=Ba(e,"s0","broadcastArgs","int32"),n=Ba(t,"s1","broadcastArgs","int32");if(1!==r.rank)throw new Error(`broadcastArgs(): first input must be a vector (rank=1). Has rank ${r.rank}`);if(1!==n.rank)throw new Error(`broadcastArgs(): second input must be a vector (rank=1). Has rank ${n.rank}`);const P={s0:r,s1:n};return Ua.runKernel(Rt,P)}const li=Xa({broadcastArgs_:ii});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ci(e,t){let r=Ba(e,"broadcastTo","x");const n=r.shape;if(t.some((e=>!(e>0)||e%1!=0)))throw new Error(`broadcastTo(): Invalid broadcast shape [${t}].`);if(t.length<r.rank)throw new Error(`broadcastTo(): shape.length=${t.length} < input.rank=${r.rank}.`);if(t.length>r.rank){const e=r.shape.slice();for(;e.length<t.length;)e.unshift(1);r=Qv(r,e)}const P=r.shape,a=Array.from(t);for(let e=t.length-1;e>=0;e--)if(P[e]===t[e])a[e]=1;else if(1!==r.shape[e])throw new Error(`broadcastTo(): [${n}] cannot be broadcast to [${t}].`);const o=a.map(((e,t)=>e>1?t:-1)).filter((e=>e>=0));if(0===o.length)return vu(r);const u={x:r},s={reps:a};return Ua.runKernel(PP,u,s)}const Oi=Xa({broadcastTo_:ci});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Di(e){const t={x:Ba(e,"x","ceil","float32")};return Ua.runKernel(Bt,t)}const ji=Xa({ceil_:Di});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function hi(e,t,r){const n=Ba(e,"x","clipByValue");xe(t<=r,(()=>`Error in clip: min (${t}) must be less than or equal to max (${r}).`));const P={x:n},a={clipValueMin:t,clipValueMax:r};return Ua.runKernel(Zt,P,a)}const pi=Xa({clipByValue_:hi});function mi(e){return Kv(e,0)}const gi=Xa({concat1d_:mi});function bi(e,t){return Kv(e,t)}const Ti=Xa({concat2d_:bi});function zi(e,t){return Kv(e,t)}const di=Xa({concat3d_:zi});function yi(e,t){return Kv(e,t)}const wi=Xa({concat4d_:yi});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Li(e,t,r,n,P="NHWC",a=[1,1],o){const u=Ba(e,"x","conv2d","float32"),s=Ba(t,"filter","conv2d","float32");let v=u,i=!1;3===u.rank&&(i=!0,v=Qv(u,[1,u.shape[0],u.shape[1],u.shape[2]])),xe(4===v.rank,(()=>`Error in conv2d: input must be rank 4, but got rank ${v.rank}.`)),xe(4===s.rank,(()=>`Error in conv2d: filter must be rank 4, but got rank ${s.rank}.`)),Cv("conv2d",n,o);const l="NHWC"===P?v.shape[3]:v.shape[1];xe(l===s.shape[2],(()=>`Error in conv2d: depth of input (${l}) must match input depth for filter ${s.shape[2]}.`)),xe(Yv(r,a),(()=>`Error in conv2D: Either strides or dilations must be 1. Got strides ${r} and dilations '${a}'`));const c={x:v,filter:s},O={strides:r,pad:n,dataFormat:P,dilations:a,dimRoundingMode:o},D=Ua.runKernel(Jt,c,O);return i?Qv(D,[D.shape[1],D.shape[2],D.shape[3]]):D}const fi=Xa({conv2d_:Li});function Ii(e,t,r,n,P="NWC",a=1,o){const u=Ba(e,"x","conv1d"),s=Ba(t,"filter","conv1d");let v=u,i=!1;2===u.rank&&(i=!0,v=Qv(u,[1,u.shape[0],u.shape[1]])),xe(3===v.rank,(()=>`Error in conv1d: input must be rank 3, but got rank ${v.rank}.`)),xe(3===s.rank,(()=>`Error in conv1d: filter must be rank 3, but got rank ${s.rank}.`)),Cv("conv1d",n,o),xe(v.shape[2]===s.shape[1],(()=>`Error in conv1d: depth of input (${v.shape[2]}) must match input depth for filter ${s.shape[1]}.`)),xe(Yv(r,a),(()=>`Error in conv1D: Either stride or dilation must be 1. Got stride ${r} and dilation '${a}'`)),xe("NWC"===P,(()=>`Error in conv1d: got dataFormat of ${P} but only NWC is currently supported.`));const l=Qv(s,[1,s.shape[0],s.shape[1],s.shape[2]]),c=Qv(v,[v.shape[0],1,v.shape[1],v.shape[2]]),O=fi(c,l,[1,r],n,"NHWC",[1,a],o);return Qv(O,i?[O.shape[2],O.shape[3]]:[O.shape[0],O.shape[2],O.shape[3]])}const Si=Xa({conv1d_:Ii});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ai(e,t,r,n,P,a="NHWC",o){xe(e.length===t.rank,(()=>`Length of inShape (${e.length}) and rank of dy (${t.rank}) must match`));let u=e,s=t,v=!1;3===t.rank&&(v=!0,s=Qv(t,[1,t.shape[0],t.shape[1],t.shape[2]]),u=[1,e[0],e[1],e[2]]),xe(4===u.length,(()=>`Error in conv2dDerInput: inShape must be length 4, but got length ${u.length}.`)),xe(4===s.rank,(()=>`Error in conv2dDerInput: dy must be rank 4, but got rank ${s.rank}`)),xe(4===r.rank,(()=>`Error in conv2dDerInput: filter must be rank 4, but got rank ${r.rank}`));const i="NHWC"===a?u[3]:u[1],l="NHWC"===a?s.shape[3]:s.shape[1];xe(i===r.shape[2],(()=>`Error in conv2dDerInput: depth of input (${i}) must match input depth for filter ${r.shape[2]}.`)),xe(l===r.shape[3],(()=>`Error in conv2dDerInput: depth of output (${l}) must match output depth for filter ${r.shape[3]}.`)),Cv("conv2dDerInput",P,o);const c={dy:s,filter:r},O={strides:n,pad:P,dataFormat:a,dimRoundingMode:o,inputShape:u},D=Ua.runKernel($t,c,O);return v?Qv(D,[D.shape[1],D.shape[2],D.shape[3]]):D}const xi=Xa({conv2DBackpropInput_:Ai});function Yi(e,t,r,n,P,a){const o=Ba(e,"x","conv2dTranspose"),u=Ba(t,"filter","conv2dTranspose");return xi(r,o,u,n,P,"NHWC",a)}const ki=Xa({conv2dTranspose_:Yi});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ci(e,t,r,n,P="NDHWC",a=[1,1,1]){const o=Ba(e,"x","conv3d"),u=Ba(t,"filter","conv3d");let s=o,v=!1;4===o.rank&&(v=!0,s=Qv(o,[1,o.shape[0],o.shape[1],o.shape[2],o.shape[3]])),xe(5===s.rank,(()=>`Error in conv3d: input must be rank 5, but got rank ${s.rank}.`)),xe(5===u.rank,(()=>`Error in conv3d: filter must be rank 5, but got rank ${u.rank}.`)),xe(s.shape[4]===u.shape[3],(()=>`Error in conv3d: depth of input (${s.shape[4]}) must match input depth for filter ${u.shape[3]}.`)),xe(Yv(r,a),(()=>`Error in conv3D: Either strides or dilations must be 1. Got strides ${r} and dilations '${a}'`)),xe("NDHWC"===P,(()=>`Error in conv3d: got dataFormat of ${P} but only NDHWC is currently supported.`));const i={x:s,filter:u},l={strides:r,pad:n,dataFormat:P,dilations:a},c=Ua.runKernel(er,i,l);return v?Qv(c,[c.shape[1],c.shape[2],c.shape[3],c.shape[4]]):c}const Ei=Xa({conv3d_:Ci});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Qi(e,t,r,n,P){xe(e.length===t.rank,(()=>`Length of inShape (${e.length}) and rank of dy (${t.rank}) must match`));let a=e,o=t,u=!1;4===t.rank&&(u=!0,o=Qv(t,[1,t.shape[0],t.shape[1],t.shape[2],t.shape[3]]),a=[1,e[0],e[1],e[2],e[3]]);const s=a[4],v=o.shape[4];xe(5===a.length,(()=>`Error in conv3dDerInput: inShape must be length 5, but got length ${a.length}.`)),xe(5===o.rank,(()=>`Error in conv3dDerInput: dy must be rank 5, but got rank ${o.rank}`)),xe(5===r.rank,(()=>`Error in conv3dDerInput: filter must be rank 5, but got rank ${r.rank}`)),xe(s===r.shape[3],(()=>`Error in conv3dDerInput: depth of input (${s}) must match input depth for filter ${r.shape[3]}.`)),xe(v===r.shape[4],(()=>`Error in conv3dDerInput: depth of output (${v}) must match output depth for filter ${r.shape[4]}.`));const i={dy:o,filter:r},l={pad:P,strides:n,inputShape:a},c=Ua.runKernel(tr,i,l);return u?Qv(c,[c.shape[1],c.shape[2],c.shape[3],c.shape[4]]):c}const Wi=Xa({conv3DBackpropInput_:Qi});function Ui(e,t,r,n,P){const a=Ba(e,"x","conv3dTranspose"),o=Ba(t,"filter","conv3dTranspose");return Wi(r,a,o,n,P)}const qi=Xa({conv3dTranspose_:Ui});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Gi(e){const t={x:Ba(e,"x","cos","float32")};return Ua.runKernel(rr,t)}const Mi=Xa({cos_:Gi});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ki(e){const t={x:Ba(e,"x","cosh","float32")};return Ua.runKernel(nr,t)}const Ni=Xa({cosh_:Ki});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the 'License');
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an 'AS IS' BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ri(e,t=0,r=!1,n=!1){const P={x:Ba(e,"x","cumprod")},a={axis:t,exclusive:r,reverse:n};return Ua.runKernel(Pr,P,a)}const Fi=Xa({cumprod_:Ri});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Bi(e,t=0,r=!1,n=!1){const P={x:Ba(e,"x","cumsum")},a={axis:t,exclusive:r,reverse:n};return Ua.runKernel(ar,P,a)}const Zi=Xa({cumsum_:Bi});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Vi(e,t,r,n=!1){const P=Ba(e,"x","denseBincount"),a=Ba(t,"weights","denseBincount");xe("int32"===P.dtype,(()=>`Error in denseBincount: input dtype must be int32, but got ${P.dtype}`)),xe(P.rank<=2,(()=>`Error in denseBincount: input must be at most rank 2, but got rank ${P.rank}.`)),xe(r>=0,(()=>`size must be non-negative, but got ${r}.`)),xe(a.size===P.size||0===a.size,(()=>`Error in denseBincount: weights must have the same shape as x or 0-length, but got x shape: ${P.shape}, weights shape: ${a.shape}.`));const o={x:P,weights:a},u={size:r,binaryOutput:n};return Ua.runKernel(ur,o,u)}const Xi=Xa({denseBincount_:Vi});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Hi(e,t,r="NHWC"){const n=Ba(e,"x","depthToSpace","float32"),P="NHWC"===r?n.shape[1]:n.shape[2],a="NHWC"===r?n.shape[2]:n.shape[3],o="NHWC"===r?n.shape[3]:n.shape[1];xe(t>1,(()=>`blockSize should be > 1 for depthToSpace, but was: ${t}`)),xe(P*t>=0,(()=>`Negative dimension size caused by overflow when multiplying\n    ${P} and ${t}  for depthToSpace with input shape\n    ${n.shape}`)),xe(a*t>=0,(()=>`Negative dimension size caused by overflow when multiplying\n    ${a} and ${t} for depthToSpace with input shape\n        ${n.shape}`)),xe(o%(t*t)==0,(()=>`Dimension size must be evenly divisible by ${t*t} but is ${o} for depthToSpace with input shape ${n.shape}`));const u={x:n},s={blockSize:t,dataFormat:r};return Ua.runKernel(sr,u,s)}const Ji=Xa({depthToSpace_:Hi});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function _i(e,t,r,n,P="NHWC",a=[1,1],o){const u=Ba(e,"x","depthwiseConv2d","float32"),s=Ba(t,"filter","depthwiseConv2d","float32");let v=u,i=!1;3===u.rank&&(i=!0,v=Qv(u,[1,u.shape[0],u.shape[1],u.shape[2]])),xe(4===v.rank,(()=>`Error in depthwiseConv2d: input must be rank 4, but got rank ${v.rank}.`)),xe(4===s.rank,(()=>`Error in depthwiseConv2d: filter must be rank 4, but got rank ${s.rank}.`));const l="NHWC"===P?v.shape[3]:v.shape[1];xe(l===s.shape[2],(()=>`Error in depthwiseConv2d: number of input channels (${l}) must match the inChannels dimension in filter ${s.shape[2]}.`)),Cv("depthwiseConv2d",n,o);const c={x:v,filter:s},O={strides:r,pad:n,dataFormat:P,dilations:a,dimRoundingMode:o},D=Ua.runKernel(vr,c,O);return i?Qv(D,[D.shape[1],D.shape[2],D.shape[3]]):D}const $i=Xa({depthwiseConv2d_:_i});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function el(e){const t={x:Ba(e,"x","diag")};return Ua.runKernel(cr,t)}const tl=Xa({diag_:el});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function rl(e,t,r,n,P=[1,1],a="NHWC"){const o=Ba(e,"x","dilation2d"),u=Ba(t,"filter","dilation2d");xe(3===o.rank||4===o.rank,(()=>`Error in dilation2d: input must be rank 3 or 4, but got rank ${o.rank}.`)),xe(3===u.rank,(()=>`Error in dilation2d: filter must be rank 3, but got rank ${u.rank}.`)),xe("NHWC"===a,(()=>`Error in dilation2d: Only NHWC is currently supported, but got dataFormat of ${a}`));let s=o,v=!1;3===o.rank&&(s=Qv(o,[1,o.shape[0],o.shape[1],o.shape[2]]),v=!0);const i={x:s,filter:u},l={strides:r,pad:n,dilations:P},c=Ua.runKernel(Or,i,l);return v?Qv(c,[c.shape[1],c.shape[2],c.shape[3]]):c}const nl=Xa({dilation2d_:rl});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Pl(e,t){let r=Ba(e,"a","equal","string_or_numeric"),n=Ba(t,"b","equal","string_or_numeric");[r,n]=Ia(r,n),os(r.shape,n.shape);const P={a:r,b:n};return Ua.runKernel(mr,P)}const al=Xa({equal_:Pl});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ol(e,t,r){const n=Ba(t,"a","where"),P=Ba(r,"b","where"),a=Ba(e,"condition","where","bool"),o=os(os(a.shape,n.shape),P.shape),u={condition:Oi(a,o),t:Oi(n,o),e:Oi(P,o)};return Ua.runKernel(Yn,u)}const ul=Xa({where_:ol});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function sl(e){const t={x:Ba(e,"x","zerosLike")};return Ua.runKernel(lP,t)}const vl=Xa({zerosLike_:sl});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function il(e,t){let r=Ba(e,"a","div"),n=Ba(t,"b","div");[r,n]=Ia(r,n);const P=Ks(r,n),a=vl(P),o=al(n,a);return ul(o,a,P)}const ll=Xa({divNoNan_:il});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function cl(e,t){const r=Ba(e,"t1","dot"),n=Ba(t,"t2","dot");xe(!(1!==r.rank&&2!==r.rank||1!==n.rank&&2!==n.rank),(()=>`Error in dot: inputs must all be rank 1 or 2, but got ranks ${r.rank} and ${n.rank}.`));const P=1===r.rank?r.size:r.shape[1],a=1===n.rank?n.size:n.shape[0];if(xe(P===a,(()=>`Error in dot: inner dimensions of inputs must match, but got ${P} and ${a}.`)),1===r.rank&&1===n.rank){const e=Qv(r,[1,-1]),t=Qv(n,[-1,1]),P=Gu(e,t);return Qv(P,[])}if(1===r.rank&&2===n.rank){const e=Qv(r,[1,-1]),t=Qv(n,[n.shape[0],n.shape[1]]),P=Gu(e,t);return Qv(P,[P.size])}if(2===r.rank&&1===n.rank){const e=Qv(n,[-1,1]),t=Gu(r,e);return Qv(t,[t.size])}{const e=Qv(n,[n.shape[0],n.shape[1]]);return Gu(r,e)}}const Ol=Xa({dot_:cl});
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Dl(e,...t){const r=t.map(((e,t)=>Ba(e,`tensors${t}`,"einsum"))),n={equation:e};return Ua.runKernel(jr,r,n)}const jl=Xa({einsum_:Dl});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function hl(e){const t={x:Ba(e,"x","elu","float32")};return Ua.runKernel(hr,t)}const pl=Xa({elu_:hl});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ml(e){let t=Ba(e,"x","erf");xe("int32"===t.dtype||"float32"===t.dtype,(()=>"Input dtype must be `int32` or `float32`.")),"int32"===t.dtype&&(t=uu(t,"float32"));const r={x:t};return Ua.runKernel(pr,r)}const gl=Xa({erf_:ml});
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function bl(e,t){for(let r=0;r<e.length;++r)if(e[e.length-r-1]!==t-1-r)return!1;return!0}function Tl(e,t,r){const n=e.length+t.length,P=[];let a=0,o=0;for(let u=0;u<n;u++)-1===r.indexOf(u)?P.push(e[a++]):P.push(t[o++]);return P}function zl(e,t){const r=[],n=e.length;for(let P=0;P<n;P++)-1===t.indexOf(P)&&r.push(e[P]);return[r,t.map((t=>e[t]))]}function dl(e,t){return Tl(e,t.map((e=>1)),t)}function yl(e,t,r){xe(bl(t,r),(()=>`${e} supports only inner-most axes for now. Got axes ${t} and rank-${r} input.`))}function wl(e,t){if(bl(e,t))return null;const r=[];for(let n=0;n<t;++n)-1===e.indexOf(n)&&r.push(n);return e.forEach((e=>r.push(e))),r}function Ll(e){return e.map(((e,t)=>[t,e])).sort(((e,t)=>e[1]-t[1])).map((e=>e[0]))}function fl(e,t){const r=[];for(let n=t-e;n<t;++n)r.push(n);return r}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Il(e,t=null,r=!1){const n={x:Ba(e,"x","max")},P={reductionIndices:t,keepDims:r};return Ua.runKernel(Vr,n,P)}const Sl=Xa({max_:Il});
/**
     * @license
     * Copyright 2020 Google Inc. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Al(e,t=null,r=!1){const n={x:Ba(e,"x","min")},P={axis:t,keepDims:r};return Ua.runKernel(en,n,P)}const xl=Xa({min_:Al});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Yl(e,t){let r=Ba(e,"base","pow"),n=Ba(t,"exp","pow");[r,n]=Ia(r,n);const P={a:r,b:n};return Ua.runKernel(hn,P)}const kl=Xa({pow_:Yl});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Cl(e,t){if((Xe(e)&&"string"!==t||Array.isArray(e))&&"complex64"!==t)throw new Error("Error creating a new Scalar: value must be a primitive (number|boolean|string)");if("string"===t&&Xe(e)&&!(e instanceof Uint8Array))throw new Error("When making a scalar from encoded string, the value must be `Uint8Array`.");return _a(e,[],[],t)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function El(e){const t={x:Ba(e,"x","sqrt","float32")};return Ua.runKernel(Gn,t)}const Ql=Xa({sqrt_:El});
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Wl(e){const t=Ba(e,"x","square");return Ua.runKernel("Square",{x:t},{})}const Ul=Xa({square_:Wl});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ql(e,t=null,r=!1){let n=Ba(e,"x","sum");"bool"===n.dtype&&(n=uu(n,"int32"));const P={x:n},a={axis:t,keepDims:r};return Ua.runKernel(Mn,P,a)}const Gl=Xa({sum_:ql});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ml(e,t="euclidean",r=null,n=!1){const P=Kl(e=Ba(e,"x","norm"),t,r);let a=P.shape;if(n){const t=Ke(r,e.shape);a=dl(P.shape,t)}return Qv(P,a)}function Kl(e,t,r=null){if(0===e.rank)return Bs(e);if(1!==e.rank&&null===r)return Kl(Qv(e,[-1]),t,r);if(1===e.rank||"number"==typeof r||Array.isArray(r)&&1===r.length){if(1===t)return Gl(Bs(e),r);if(t===1/0)return Sl(Bs(e),r);if(t===-1/0)return xl(Bs(e),r);if("euclidean"===t||2===t)return Ql(Gl(kl(Bs(e),Cl(2,"int32")),r));throw new Error(`Error in norm: invalid ord value: ${t}`)}if(Array.isArray(r)&&2===r.length){if(1===t)return Sl(Gl(Bs(e),r[0]),r[1]-1);if(t===1/0)return Sl(Gl(Bs(e),r[1]),r[0]);if(t===-1/0)return xl(Gl(Bs(e),r[1]),r[0]);if("fro"===t||"euclidean"===t)return Ql(Gl(Ul(e),r));throw new Error(`Error in norm: invalid ord value: ${t}`)}throw new Error(`Error in norm: invalid axis: ${r}`)}const Nl=Xa({norm_:Ml});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Rl(e,t=null,r=!1){return Nl(e,"euclidean",t,r)}const Fl=Xa({euclideanNorm_:Rl});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Bl(e){const t={x:Ba(e,"x","exp")};return Ua.runKernel(gr,t)}const Zl=Xa({exp_:Bl});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Vl(e,t=0){const r=Ba(e,"x","expandDims","string_or_numeric");xe(t<=r.rank,(()=>"Axis must be <= rank of the tensor"));const n={input:r},P={dim:t};return Ua.runKernel(br,n,P)}const Xl=Xa({expandDims_:Vl});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Hl(e){const t={x:Ba(e,"x","expm1")};return Ua.runKernel(Tr,t)}const Jl=Xa({expm1_:Hl});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function _l(e,t){const r=Ba(e,"x","tile","string_or_numeric");xe(r.rank===t.length,(()=>`Error in transpose: rank of input ${r.rank} must match length of reps ${t}.`));const n={x:r},P={reps:t};return Ua.runKernel(PP,n,P)}const $l=Xa({tile_:_l});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ec(e,t,r,n="float32"){null==t&&(t=e);const P=au([e,t],n),a=e<=t?e:t;for(let e=0;e<a;++e)P.set(1,e,e);const o=Qv(P.toTensor(),[e,t]);if(null==r)return o;if(1===r.length)return $l(Xl(o,0),[r[0],1,1]);if(2===r.length)return $l(Xl(Xl(o,0),0),[r[0],r[1],1,1]);if(3===r.length)return $l(Xl(Xl(Xl(o,0),0),0),[r[0],r[1],r[2],1,1]);throw new Error(`eye() currently supports only 1D and 2D batchShapes, but received ${r.length}D.`)}const tc=Xa({eye_:ec});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function rc(e,t,r){const n={shape:e,value:t,dtype:r};return Ua.runKernel(dr,{},n)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function nc(e){const t={x:Ba(e,"x","floor","float32")};return Ua.runKernel(wr,t)}const Pc=Xa({floor_:nc});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ac(e,t,r=0,n=0){const P={x:Ba(e,"x","gather"),indices:Ba(t,"indices","gather","int32")},a={axis:r,batchDims:n};return Ua.runKernel(Ir,P,a)}const oc=Xa({gather_:ac});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function uc(e,t){let r=Ba(e,"a","greater","string_or_numeric"),n=Ba(t,"b","greater","string_or_numeric");[r,n]=Ia(r,n),os(r.shape,n.shape);const P={a:r,b:n};return Ua.runKernel(Ar,P)}const sc=Xa({greater_:uc});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function vc(e,t){let r=Ba(e,"a","greaterEqual","string_or_numeric"),n=Ba(t,"b","greaterEqual","string_or_numeric");[r,n]=Ia(r,n),os(r.shape,n.shape);const P={a:r,b:n};return Ua.runKernel(xr,P)}const ic=Xa({greaterEqual_:vc});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function lc(e){const t={x:Ba(e,"x","isFinite")};return Ua.runKernel(Er,t)}const cc=Xa({isFinite_:lc});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Oc(e){const t={x:Ba(e,"x","isInf")};return Ua.runKernel(Qr,t)}const Dc=Xa({isInf_:Oc});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function jc(e){const t={x:Ba(e,"x","isNaN")};return Ua.runKernel(Wr,t)}const hc=Xa({isNaN_:jc});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function pc(e,t=.2){const r={x:Ba(e,"x","leakyRelu")},n={alpha:t};return Ua.runKernel(Ur,r,n)}const mc=Xa({leakyRelu_:pc});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function gc(e,t){let r=Ba(e,"a","less","string_or_numeric"),n=Ba(t,"b","less","string_or_numeric");[r,n]=Ia(r,n),os(r.shape,n.shape);const P={a:r,b:n};return Ua.runKernel(qr,P)}const bc=Xa({less_:gc});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Tc(e,t){let r=Ba(e,"a","lessEqual","string_or_numeric"),n=Ba(t,"b","lessEqual","string_or_numeric");[r,n]=Ia(r,n),os(r.shape,n.shape);const P={a:r,b:n};return Ua.runKernel(Gr,P)}const zc=Xa({lessEqual_:Tc});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function dc(e,t,r){if(r<=0)throw new Error("The number of values should be positive.");const n={start:e,stop:t,num:r};return Ua.runKernel(Mr,{},n)}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function yc(e,t=5,r=1,n=1,P=.5){const a=Ba(e,"x","localResponseNormalization");xe(4===a.rank||3===a.rank,(()=>`Error in localResponseNormalization: x must be rank 3 or 4 but got\n               rank ${a.rank}.`)),xe(We(t),(()=>`Error in localResponseNormalization: depthRadius must be an integer but got depthRadius ${t}.`));let o=a,u=!1;3===a.rank&&(u=!0,o=Qv(a,[1,a.shape[0],a.shape[1],a.shape[2]]));const s={x:o},v={depthRadius:t,bias:r,alpha:n,beta:P},i=Ua.runKernel(Zr,s,v);return u?Qv(i,[i.shape[1],i.shape[2],i.shape[3]]):i}const wc=Xa({localResponseNormalization_:yc});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Lc(e){const t={x:Ba(e,"x","log","float32")};return Ua.runKernel(Kr,t)}const fc=Xa({log_:Lc});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ic(e){const t={x:Ba(e,"x","log1p")};return Ua.runKernel(Nr,t)}const Sc=Xa({log1p_:Ic});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ac(e,t){xe(rt(e),(()=>"The f passed in variableGrads(f) must be a function")),xe(null==t||Array.isArray(t)&&t.every((e=>e instanceof ya)),(()=>"The varList passed in variableGrads(f, varList) must be an array of variables"));const r=null!=t;if(!r){t=[];for(const e in Ua.registeredVariables)t.push(Ua.registeredVariables[e])}const n=r?t.filter((e=>!e.trainable)):null,P=t.length;t=t.filter((e=>e.trainable)),xe(t.length>0,(()=>`variableGrads() expects at least one of the input variables to be trainable, but none of the ${P} variables is trainable.`));const{value:a,grads:o}=Ua.gradients(e,t,null,!0);xe(o.some((e=>null!=e)),(()=>"Cannot find a connection between any variable and the result of the loss function y=f(x). Please make sure the operations that use variables are inside the function f passed to minimize().")),xe(0===a.rank,(()=>`The f passed in variableGrads(f) must return a scalar, but it returned a rank-${a.rank} tensor`));const u={};return t.forEach(((e,t)=>{null!=o[t]&&(u[e.name]=o[t])})),null!=n&&n.forEach((e=>u[e.name]=null)),{value:a,grads:u}}function xc(e){return Ua.customGrad(e)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Yc(e){const t={x:Ba(e,"x","softplus")};return Ua.runKernel(qn,t)}const kc=Xa({softplus_:Yc});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Cc(e){const t=Ba(e,"x","logSigmoid"),r=xc((e=>({value:_u(kc(_u(e))),gradFunc:t=>Rs(t,Rv(_u(e)))})));return r(t)}const Ec=Xa({logSigmoid_:Cc});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Qc(e,t){let r=Ba(e,"a","sub"),n=Ba(t,"b","sub");[r,n]=Ia(r,n);const P={a:r,b:n};return Ua.runKernel(tP,P)}const Wc=Xa({sub_:Qc});
/**
     * @license
     * Copyright 2020 Google Inc. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Uc(e,t=-1){const r=Ba(e,"logits","logSoftmax");if(-1===t&&(t=r.rank-1),t!==r.rank-1)throw Error(`Log Softmax along a non-last dimension is not yet supported. Logits was rank ${r.rank} and axis was ${t}`);const n=xc(((e,r)=>{const n=Sl(e,t,!0),P=Wc(e,n),a=Wc(uu(P,"float32"),fc(Gl(Zl(P),t,!0)));r([a]);return{value:a,gradFunc:(e,r)=>{const[n]=r,P=Zl(n);return Wc(e,Rs(Gl(e,t,!0),P))}}}));return n(r)}const qc=Xa({logSoftmax_:Uc});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Gc(e,t=null,r=!1){const n=Ba(e,"x","logSumExp"),P=Ke(t,n.shape),a=Sl(n,P,!0),o=Wc(n,a),u=Zl(o),s=Gl(u,P),v=fc(s),i=Us(Qv(a,v.shape),v);if(r){const e=dl(i.shape,P);return Qv(i,e)}return i}const Mc=Xa({logSumExp_:Gc});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Kc(e,t){const r=Ba(e,"a","logicalAnd","bool"),n=Ba(t,"b","logicalAnd","bool");os(r.shape,n.shape);const P={a:r,b:n};return Ua.runKernel(Rr,P)}const Nc=Xa({logicalAnd_:Kc});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Rc(e){const t={x:Ba(e,"x","logicalNot","bool")};return Ua.runKernel(Fr,t)}const Fc=Xa({logicalNot_:Rc});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Bc(e,t){const r=Ba(e,"a","logicalOr","bool"),n=Ba(t,"b","logicalOr","bool");os(r.shape,n.shape);const P={a:r,b:n};return Ua.runKernel(Br,P)}const Zc=Xa({logicalOr_:Bc});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Vc(e,t){const r=Ba(e,"a","logicalXor","bool"),n=Ba(t,"b","logicalXor","bool");return os(r.shape,n.shape),Nc(Zc(e,t),Fc(Nc(e,t)))}const Xc=Xa({logicalXor_:Vc}),Hc=2147483648;
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Jc(e,t,r="left"){const n=Ba(e,"sortedSequence","searchSorted"),P=Ba(t,"values","searchSorted"),a=n.shape[n.shape.length-1],o=P.shape[P.shape.length-1],u=Qv(n,[-1,a]),s=Qv(P,[-1,o]);if(u.rank<2)throw new Error("Sorted input argument must be at least 2-dimensional");if(u.shape[0]!==s.shape[0])throw new Error("Leading dimension of 'sortedSequence' and 'values' must match.");if(Ee(s.shape)>=Hc)throw new Error(`values tensor size must less than ${Hc}`);if(u.shape[1]>=Hc)throw new Error(`trailing dim_size must less than ${Hc} for int32 output type, was ${u.shape[1]}`);const v={sortedSequence:u,values:s},i={side:r};return Ua.runKernel(xn,v,i)}const _c=Xa({searchSorted_:Jc});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function $c(e,t){return _c(e,t,"left")}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function eO(e,t,r,n,P){const a=Ba(e,"x","maxPool");let o=a,u=!1;3===a.rank&&(u=!0,o=Qv(a,[1,a.shape[0],a.shape[1],a.shape[2]])),xe(4===o.rank,(()=>`Error in maxPool: input must be rank 4 but got rank ${o.rank}.`)),xe(Yv(r,1),(()=>`Error in maxPool: Either strides or dilations must be 1. Got strides ${r} and dilations '1'`)),Cv("maxPool",n,P);const s={x:o},v={filterSize:t,strides:r,pad:n,dimRoundingMode:P},i=Ua.runKernel(Hr,s,v);return u?Qv(i,[i.shape[1],i.shape[2],i.shape[3]]):i}const tO=Xa({maxPool_:eO});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function rO(e,t=[1,1,1],r,n,P,a="NDHWC"){const o=Ba(e,"x","maxPool3d");let u=o,s=!1;4===o.rank&&(s=!0,u=Qv(o,[1,o.shape[0],o.shape[1],o.shape[2],o.shape[3]])),xe(5===u.rank,(()=>`Error in maxPool3d: x must be rank 5 but got rank ${u.rank}.`)),xe("NDHWC"===a,(()=>`Error in maxPool3d: Only NDHWC is currently supported, but got dataFormat of ${a}`)),Cv("maxPool3d",n,P);const v={x:u},i={filterSize:t,strides:r,pad:n,dimRoundingMode:P,dataFormat:a},l=Ua.runKernel(Jr,v,i);return s?Qv(l,[l.shape[1],l.shape[2],l.shape[3],l.shape[4]]):l}const nO=Xa({maxPool3d_:rO});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function PO(e,t,r,n,P=!1){const a={x:Ba(e,"x","maxPoolWithArgmax")},o={filterSize:t,strides:r,pad:n,includeBatchInIndex:P},u=Ua.runKernel(_r,a,o);return{result:u[0],indexes:u[1]}}const aO=Xa({maxPoolWithArgmax_:PO});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function oO(e,t){let r=Ba(e,"a","maximum"),n=Ba(t,"b","maximum");[r,n]=Ia(r,n),"bool"===r.dtype&&(r=uu(r,"int32"),n=uu(n,"int32")),os(r.shape,n.shape);const P={a:r,b:n};return Ua.runKernel(Xr,P)}const uO=Xa({maximum_:oO});
/**
     * @license
     * Copyright 2020 Google Inc. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function sO(e,t=null,r=!1){const n={x:Ba(e,"x","mean")},P={axis:t,keepDims:r};return Ua.runKernel($r,n,P)}const vO=Xa({mean_:sO});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function iO(e,t="float32"){if("complex64"===t){const t=iO(e,"float32"),r=iO(e,"float32");return Ja(t,r)}const r=st(Ee(e),t);return Ua.makeTensor(r,e,t)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function lO(e,t="float32"){if("complex64"===t){const t=lO(e,"float32"),r=iO(e,"float32");return Ja(t,r)}const r=ut(Ee(e),t);return Ua.makeTensor(r,e,t)}
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function cO(e,t,{indexing:r="xy"}={}){if("xy"!==r&&"ij"!==r)throw new TypeError(`${r} is not a valid third argument to meshgrid`);if(void 0===e)return[];let n=Ba(e,"x","meshgrid",e instanceof za?e.dtype:"float32");if(void 0===t)return[n];let P=Ba(t,"y","meshgrid",t instanceof za?t.dtype:"float32");const a=Ee(n.shape),o=Ee(P.shape);return"xy"===r?(n=Qv(n,[1,-1]),P=Qv(P,[-1,1]),[Gu(lO([o,1],n.dtype),n),Gu(P,lO([1,a],P.dtype))]):(n=Qv(n,[-1,1]),P=Qv(P,[1,-1]),[Gu(n,lO([1,o],n.dtype)),Gu(lO([a,1],P.dtype),P)])}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function OO(e,t){let r=Ba(e,"a","minimum"),n=Ba(t,"b","minimum");[r,n]=Ia(r,n),"bool"===r.dtype&&(r=uu(r,"int32"),n=uu(n,"int32")),os(r.shape,n.shape);const P={a:r,b:n};return Ua.runKernel(tn,P)}const DO=Xa({minimum_:OO});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function jO(e,t,r){xe("reflect"===r||"symmetric"===r,(()=>`Invalid mode. Mode must be either reflect or symmetric. Got ${r}.`));const n=Ba(e,"x","mirrorPad");if(0===n.rank)throw new Error("mirrorPad(scalar) is not defined. Pass non-scalar to mirrorPad");xe(t.length===n.rank,(()=>`Padding doesn't match input. Must be ${n.rank}. Got ${t.length}.`));const P="reflect"===r?1:0;for(let e=0;e<n.rank;e++)xe(2===t[e].length,(()=>"Invalid number of paddings. Must be length of 2 each.")),xe(t[e][0]>=0&&t[e][0]<=n.shape[e]-P&&t[e][1]>=0&&t[e][1]<=n.shape[e]-P,(()=>`Padding in dimension ${e} cannot be greater than or equal to ${n.shape[e]-P} or less than 0 for input of shape ${n.shape}`));const a={paddings:t,mode:r},o={x:n};return Ua.runKernel(rn,o,a)}const hO=Xa({mirrorPad_:jO});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function pO(e,t){let r=Ba(e,"a","mod"),n=Ba(t,"b","mod");[r,n]=Ia(r,n);const P={a:r,b:n};return Ua.runKernel(nn,P)}const mO=Xa({mod_:pO});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function gO(e,t=null,r=!1){const n=Ke(t,(e=Ba(e,"x","moments")).shape),P=vO(e,n,r);let a=P.shape;r||(a=dl(P.shape,n));const o=Ul(Wc(uu(e,"float32"),Qv(P,a)));return{mean:P,variance:vO(o,n,r)}}const bO=Xa({moments_:gO});function TO(e,t,r,n){const P=Ba(t,"data","multiRNNCell"),a=Za(r,"c","multiRNNCell"),o=Za(n,"h","multiRNNCell");let u=P;const s=[];for(let t=0;t<e.length;t++){const r=e[t](u,a[t],o[t]);s.push(r[0]),s.push(r[1]),u=r[1]}const v=[],i=[];for(let e=0;e<s.length;e+=2)v.push(s[e]),i.push(s[e+1]);return[v,i]}const zO=Xa({multiRNNCell_:TO});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function dO(e,t,r,n=!1){const P=Ba(e,"logits","multinomial"),a=P.size,o=P.rank;if(a<2)throw new Error(`Error in multinomial: you need at least 2 outcomes, but got ${a}.`);if(o>2)throw new Error(`Rank of probabilities must be 1 or 2, but is ${o}`);r=r||Math.random();const u={logits:1===o?Qv(P,[1,-1]):P},s={numSamples:t,seed:r,normalized:n},v=Ua.runKernel(Pn,u,s);return 1===o?Qv(v,[v.size]):v}const yO=Xa({multinomial_:dO});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function wO(e,t){let r=Ba(e,"a","notEqual","string_or_numeric"),n=Ba(t,"b","notEqual","string_or_numeric");[r,n]=Ia(r,n),os(r.shape,n.shape);const P={a:r,b:n};return Ua.runKernel(un,P)}const LO=Xa({notEqual_:wO});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function fO(e){const t={x:Ba(e,"x","onesLike")};return Ua.runKernel(cn,t)}const IO=Xa({onesLike_:fO});function SO(e,t){const r=Ba(e,"v1","outerProduct"),n=Ba(t,"v2","outerProduct");xe(1===r.rank&&1===n.rank,(()=>`Error in outerProduct: inputs must be rank 1, but got ranks ${r.rank} and ${n.rank}.`));const P=Qv(r,[-1,1]),a=Qv(n,[1,-1]);return Gu(P,a)}const AO=Xa({outerProduct_:SO});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function xO(e,t,r=0){const n=Ba(e,"x","pad");if(0===n.rank)throw new Error("pad(scalar) is not defined. Pass non-scalar to pad");const P={paddings:t,constantValue:r},a={x:n};return Ua.runKernel(jn,a,P)}const YO=Xa({pad_:xO});function kO(e,t,r=0){return xe(2===t.length,(()=>"Invalid number of paddings. Must be length of 2.")),YO(e,[t],r)}const CO=Xa({pad1d_:kO});function EO(e,t,r=0){return xe(2===t.length&&2===t[0].length&&2===t[1].length,(()=>"Invalid number of paddings. Must be length of 2 each.")),YO(e,t,r)}const QO=Xa({pad2d_:EO});function WO(e,t,r=0){return xe(3===t.length&&2===t[0].length&&2===t[1].length&&2===t[2].length,(()=>"Invalid number of paddings. Must be length of 2 each.")),YO(e,t,r)}const UO=Xa({pad3d_:WO});function qO(e,t,r=0){return xe(4===t.length&&2===t[0].length&&2===t[1].length&&2===t[2].length&&2===t[3].length,(()=>"Invalid number of paddings. Must be length of 2 each.")),YO(e,t,r)}const GO=Xa({pad4d_:qO});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function MO(e,t,r){const n=Ba(e,"x","spaceToBatchND");xe(n.rank>=1+t.length,(()=>`input rank ${n.rank} should be > than [blockShape] ${t.length}`)),xe(r.length===t.length,(()=>`paddings.shape[0] ${r.length} must be equal to [blockShape] ${t.length}`)),xe(n.shape.reduce(((e,n,P)=>P>0&&P<=t.length?e&&(n+r[P-1][0]+r[P-1][1])%t[P-1]==0:e),!0),(()=>`input spatial dimensions ${n.shape.slice(1)} with paddings ${r.toString()} must be divisible by blockShapes ${t.toString()}`));const P={x:n},a={blockShape:t,paddings:r};return Ua.runKernel(Kn,P,a)}const KO=Xa({spaceToBatchND_:MO});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function NO(e,t,r,n,P,a,o){null==P&&(P=[1,1]),null==a&&(a=1),0===n&&(n="valid");const u=Ba(e,"x","maxPool");let s=u,v=!1;3===u.rank&&(v=!0,s=Qv(u,[1,u.shape[0],u.shape[1],u.shape[2]])),xe(Yv(a,P),(()=>`Error in pool: Either strides or dilations must be 1. Got strides ${a} and dilations '${P}'`));const i=mv(s.shape,t,a,P,n),l=[i.dilationHeight,i.dilationWidth];let c;c="same"===n?FO([i.filterHeight,i.filterWidth],l):[[0,0],[0,0]];const O=1===l[0]&&1===l[1],[D,j]=RO([i.inHeight,i.inWidth],l,c),h=O?n:"valid",p=O?s:KO(s,l,D),m=("avg"===r?()=>Uv(p,t,a,h,o):()=>tO(p,t,a,h,o))(),g=O?m:_v(m,l,j);return v?Qv(g,[g.shape[1],g.shape[2],g.shape[3]]):g}function RO(e,t,r){const n=r.map((e=>e[0])),P=r.map((e=>e[1])),a=e.concat(n,P),o=t.map(((e,t)=>(e-a[t]%e)%e)),u=P.map(((e,t)=>e+o[t]));return[t.map(((e,t)=>[n[t],u[t]])),t.map(((e,t)=>[0,o[t]]))]}function FO(e,t){const r=e.map(((e,r)=>e+(e-1)*(t[r]-1))).map((e=>e-1)),n=r.map((e=>Math.floor(e/2))),P=r.map(((e,t)=>e-n[t]));return r.map(((e,t)=>[n[t],P[t]]))}const BO=Xa({pool_:NO});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ZO(e,t){const r={x:Ba(e,"x","prelu"),alpha:Ba(t,"alpha","prelu")};return Ua.runKernel(pn,r)}const VO=Xa({prelu_:ZO});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function XO(e,t=null,r=!1){let n=Ba(e,"x","prod");"bool"===n.dtype&&(n=uu(n,"int32"));const P={x:n},a={axis:t,keepDims:r};return Ua.runKernel(mn,P,a)}const HO=Xa({prod_:XO});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function JO(e,t,r){const n=Ee(e);let P=null;if(null==r||"float32"===r)P=new Float32Array(n);else if("int32"===r)P=new Int32Array(n);else{if("bool"!==r)throw new Error(`Unknown data type ${r}`);P=new Uint8Array(n)}for(let e=0;e<n;e++)P[e]=t();return Ua.makeTensor(P,e,r)}const _O=Xa({rand_:JO});var f={exports:{}};!function(e){!function(e,t,r){function n(e){var t=this,r=function(){var e=4022871197,t=function(t){t=String(t);for(var r=0;r<t.length;r++){var n=.02519603282416938*(e+=t.charCodeAt(r));n-=e=n>>>0,e=(n*=e)>>>0,e+=4294967296*(n-=e)}return 2.3283064365386963e-10*(e>>>0)};return t}();t.next=function(){var e=2091639*t.s0+2.3283064365386963e-10*t.c;return t.s0=t.s1,t.s1=t.s2,t.s2=e-(t.c=0|e)},t.c=1,t.s0=r(" "),t.s1=r(" "),t.s2=r(" "),t.s0-=r(e),t.s0<0&&(t.s0+=1),t.s1-=r(e),t.s1<0&&(t.s1+=1),t.s2-=r(e),t.s2<0&&(t.s2+=1),r=null}function P(e,t){return t.c=e.c,t.s0=e.s0,t.s1=e.s1,t.s2=e.s2,t}function a(e,t){var r=new n(e),a=t&&t.state,o=r.next;return o.int32=function(){return 4294967296*r.next()|0},o.double=function(){return o()+11102230246251565e-32*(2097152*o()|0)},o.quick=o,a&&("object"==typeof a&&P(a,r),o.state=function(){return P(r,{})}),o}t&&t.exports?t.exports=a:r&&r.amd?r((function(){return a})):this.alea=a}(0,e,!1)}(f);var I={exports:{}};!function(e){!function(e,t,r){function n(e){var t=this,r="";t.x=0,t.y=0,t.z=0,t.w=0,t.next=function(){var e=t.x^t.x<<11;return t.x=t.y,t.y=t.z,t.z=t.w,t.w^=t.w>>>19^e^e>>>8},e===(0|e)?t.x=e:r+=e;for(var n=0;n<r.length+64;n++)t.x^=0|r.charCodeAt(n),t.next()}function P(e,t){return t.x=e.x,t.y=e.y,t.z=e.z,t.w=e.w,t}function a(e,t){var r=new n(e),a=t&&t.state,o=function(){return(r.next()>>>0)/4294967296};return o.double=function(){do{var e=((r.next()>>>11)+(r.next()>>>0)/4294967296)/(1<<21)}while(0===e);return e},o.int32=r.next,o.quick=o,a&&("object"==typeof a&&P(a,r),o.state=function(){return P(r,{})}),o}t&&t.exports?t.exports=a:r&&r.amd?r((function(){return a})):this.xor128=a}(0,e,!1)}(I);var S={exports:{}};!function(e){!function(e,t,r){function n(e){var t=this,r="";t.next=function(){var e=t.x^t.x>>>2;return t.x=t.y,t.y=t.z,t.z=t.w,t.w=t.v,(t.d=t.d+362437|0)+(t.v=t.v^t.v<<4^e^e<<1)|0},t.x=0,t.y=0,t.z=0,t.w=0,t.v=0,e===(0|e)?t.x=e:r+=e;for(var n=0;n<r.length+64;n++)t.x^=0|r.charCodeAt(n),n==r.length&&(t.d=t.x<<10^t.x>>>4),t.next()}function P(e,t){return t.x=e.x,t.y=e.y,t.z=e.z,t.w=e.w,t.v=e.v,t.d=e.d,t}function a(e,t){var r=new n(e),a=t&&t.state,o=function(){return(r.next()>>>0)/4294967296};return o.double=function(){do{var e=((r.next()>>>11)+(r.next()>>>0)/4294967296)/(1<<21)}while(0===e);return e},o.int32=r.next,o.quick=o,a&&("object"==typeof a&&P(a,r),o.state=function(){return P(r,{})}),o}t&&t.exports?t.exports=a:r&&r.amd?r((function(){return a})):this.xorwow=a}(0,e,!1)}(S);var A={exports:{}};!function(e){!function(e,t,r){function n(e){var t=this;t.next=function(){var e,r,n=t.x,P=t.i;return e=n[P],r=(e^=e>>>7)^e<<24,r^=(e=n[P+1&7])^e>>>10,r^=(e=n[P+3&7])^e>>>3,r^=(e=n[P+4&7])^e<<7,e=n[P+7&7],r^=(e^=e<<13)^e<<9,n[P]=r,t.i=P+1&7,r},function(e,t){var r,n=[];if(t===(0|t))n[0]=t;else for(t=""+t,r=0;r<t.length;++r)n[7&r]=n[7&r]<<15^t.charCodeAt(r)+n[r+1&7]<<13;for(;n.length<8;)n.push(0);for(r=0;r<8&&0===n[r];++r);for(8==r?n[7]=-1:n[r],e.x=n,e.i=0,r=256;r>0;--r)e.next()}(t,e)}function P(e,t){return t.x=e.x.slice(),t.i=e.i,t}function a(e,t){null==e&&(e=+new Date);var r=new n(e),a=t&&t.state,o=function(){return(r.next()>>>0)/4294967296};return o.double=function(){do{var e=((r.next()>>>11)+(r.next()>>>0)/4294967296)/(1<<21)}while(0===e);return e},o.int32=r.next,o.quick=o,a&&(a.x&&P(a,r),o.state=function(){return P(r,{})}),o}t&&t.exports?t.exports=a:r&&r.amd?r((function(){return a})):this.xorshift7=a}(0,e,!1)}(A);var x={exports:{}};!function(e){!function(e,t,r){function n(e){var t=this;t.next=function(){var e,r,n=t.w,P=t.X,a=t.i;return t.w=n=n+1640531527|0,r=P[a+34&127],e=P[a=a+1&127],r^=r<<13,e^=e<<17,r^=r>>>15,e^=e>>>12,r=P[a]=r^e,t.i=a,r+(n^n>>>16)|0},function(e,t){var r,n,P,a,o,u=[],s=128;for(t===(0|t)?(n=t,t=null):(t+="\0",n=0,s=Math.max(s,t.length)),P=0,a=-32;a<s;++a)t&&(n^=t.charCodeAt((a+32)%t.length)),0===a&&(o=n),n^=n<<10,n^=n>>>15,n^=n<<4,n^=n>>>13,a>=0&&(o=o+1640531527|0,P=0==(r=u[127&a]^=n+o)?P+1:0);for(P>=128&&(u[127&(t&&t.length||0)]=-1),P=127,a=512;a>0;--a)n=u[P+34&127],r=u[P=P+1&127],n^=n<<13,r^=r<<17,n^=n>>>15,r^=r>>>12,u[P]=n^r;e.w=o,e.X=u,e.i=P}(t,e)}function P(e,t){return t.i=e.i,t.w=e.w,t.X=e.X.slice(),t}function a(e,t){null==e&&(e=+new Date);var r=new n(e),a=t&&t.state,o=function(){return(r.next()>>>0)/4294967296};return o.double=function(){do{var e=((r.next()>>>11)+(r.next()>>>0)/4294967296)/(1<<21)}while(0===e);return e},o.int32=r.next,o.quick=o,a&&(a.X&&P(a,r),o.state=function(){return P(r,{})}),o}t&&t.exports?t.exports=a:r&&r.amd?r((function(){return a})):this.xor4096=a}(0,e,!1)}(x);var Y={exports:{}};!function(e){!function(e,t,r){function n(e){var t=this,r="";t.next=function(){var e=t.b,r=t.c,n=t.d,P=t.a;return e=e<<25^e>>>7^r,r=r-n|0,n=n<<24^n>>>8^P,P=P-e|0,t.b=e=e<<20^e>>>12^r,t.c=r=r-n|0,t.d=n<<16^r>>>16^P,t.a=P-e|0},t.a=0,t.b=0,t.c=-1640531527,t.d=1367130551,e===Math.floor(e)?(t.a=e/4294967296|0,t.b=0|e):r+=e;for(var n=0;n<r.length+20;n++)t.b^=0|r.charCodeAt(n),t.next()}function P(e,t){return t.a=e.a,t.b=e.b,t.c=e.c,t.d=e.d,t}function a(e,t){var r=new n(e),a=t&&t.state,o=function(){return(r.next()>>>0)/4294967296};return o.double=function(){do{var e=((r.next()>>>11)+(r.next()>>>0)/4294967296)/(1<<21)}while(0===e);return e},o.int32=r.next,o.quick=o,a&&("object"==typeof a&&P(a,r),o.state=function(){return P(r,{})}),o}t&&t.exports?t.exports=a:r&&r.amd?r((function(){return a})):this.tychei=a}(0,e,!1)}(Y);var k={exports:{}};!function(t){!function(e,r,n){var P,a=256,o="random",u=n.pow(a,6),s=n.pow(2,52),v=2*s,i=255;function l(e,t,P){var i=[],l=j(D((t=1==t?{entropy:!0}:t||{}).entropy?[e,p(r)]:null==e?h():e,3),i),m=new c(i),g=function(){for(var e=m.g(6),t=u,r=0;e<s;)e=(e+r)*a,t*=a,r=m.g(1);for(;e>=v;)e/=2,t/=2,r>>>=1;return(e+r)/t};return g.int32=function(){return 0|m.g(4)},g.quick=function(){return m.g(4)/4294967296},g.double=g,j(p(m.S),r),(t.pass||P||function(e,t,r,P){return P&&(P.S&&O(P,m),e.state=function(){return O(m,{})}),r?(n[o]=e,t):e})(g,l,"global"in t?t.global:this==n,t.state)}function c(e){var t,r=e.length,n=this,P=0,o=n.i=n.j=0,u=n.S=[];for(r||(e=[r++]);P<a;)u[P]=P++;for(P=0;P<a;P++)u[P]=u[o=i&o+e[P%r]+(t=u[P])],u[o]=t;(n.g=function(e){for(var t,r=0,P=n.i,o=n.j,u=n.S;e--;)t=u[P=i&P+1],r=r*a+u[i&(u[P]=u[o=i&o+t])+(u[o]=t)];return n.i=P,n.j=o,r})(a)}function O(e,t){return t.i=e.i,t.j=e.j,t.S=e.S.slice(),t}function D(e,t){var r,n=[],P=typeof e;if(t&&"object"==P)for(r in e)try{n.push(D(e[r],t-1))}catch(e){}return n.length?n:"string"==P?e:e+"\0"}function j(e,t){for(var r,n=e+"",P=0;P<n.length;)t[i&P]=i&(r^=19*t[i&P])+n.charCodeAt(P++);return p(t)}function h(){try{var t;return P&&(t=P.randomBytes)?t=t(a):(t=new Uint8Array(a),(e.crypto||e.msCrypto).getRandomValues(t)),p(t)}catch(t){var n=e.navigator,o=n&&n.plugins;return[+new Date,e,o,e.screen,p(r)]}}function p(e){return String.fromCharCode.apply(0,e)}if(j(n.random(),r),t.exports){t.exports=l;try{P=require("crypto")}catch(e){}}else n["seed"+o]=l}("undefined"!=typeof self?self:e,[],Math)}(k);var C=f.exports,E=I.exports,Q=S.exports,W=A.exports,U=x.exports,q=Y.exports,G=k.exports;G.alea=C,G.xor128=E,G.xorwow=Q,G.xorshift7=W,G.xor4096=U,G.tychei=q;var M=G;
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class $O{constructor(e,t,r,n,P){this.mean=e,this.stdDev=t,this.dtype=r,this.nextVal=NaN,this.truncated=n,this.truncated&&(this.upper=this.mean+2*this.stdDev,this.lower=this.mean-2*this.stdDev);const a=P||Math.random();this.random=M.alea(a.toString())}nextValue(){if(!isNaN(this.nextVal)){const e=this.nextVal;return this.nextVal=NaN,e}let e,t,r=!1;for(;!r;){let n,P,a;do{n=2*this.random()-1,P=2*this.random()-1,a=n*n+P*P}while(a>=1||0===a);const o=Math.sqrt(-2*Math.log(a)/a);e=this.mean+this.stdDev*n*o,t=this.mean+this.stdDev*P*o,this.truncated&&!this.isValidTruncated(e)||(r=!0)}return this.truncated&&!this.isValidTruncated(t)||(this.nextVal=this.convertValue(t)),this.convertValue(e)}convertValue(e){return null==this.dtype||"float32"===this.dtype?e:Math.round(e)}isValidTruncated(e){return e<=this.upper&&e>=this.lower}}class eD{constructor(e,t,r,n){this.alpha=e,this.beta=1/t,this.dtype=r;const P=n||Math.random();this.randu=M.alea(P.toString()),this.randn=new $O(0,1,r,!1,this.randu()),this.d=e<1?e+2/3:e-1/3,this.c=1/Math.sqrt(9*this.d)}nextValue(){let e,t,r,n,P,a;for(;;){do{n=this.randn.nextValue(),a=1+this.c*n}while(a<=0);if(a*=a*a,e=n*n,t=1-.331*e*e,r=.5*e+this.d*(1-a+Math.log(a)),P=this.randu(),P<t||Math.log(P)<r)break}return a=1/this.beta*this.d*a,this.alpha<1&&(a*=Math.pow(this.randu(),1/this.alpha)),this.convertValue(a)}convertValue(e){return"float32"===this.dtype?e:Math.round(e)}}class tD{constructor(e=0,t=1,r,n){if(this.canReturnFloat=()=>null==this.dtype||"float32"===this.dtype,this.min=e,this.range=t-e,this.dtype=r,null==n&&(n=Math.random()),"number"==typeof n&&(n=n.toString()),!this.canReturnFloat()&&this.range<=1)throw new Error(`The difference between ${e} - ${t} <= 1 and dtype is not float`);this.random=M.alea(n)}convertValue(e){return this.canReturnFloat()?e:Math.round(e)}nextValue(){return this.convertValue(this.min+this.range*this.random())}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function rD(e,t,r=1,n="float32",P){if(null==r&&(r=1),null==n&&(n="float32"),"float32"!==n&&"int32"!==n)throw new Error(`Unsupported data type ${n}`);const a=new eD(t,r,n,P),o=au(e,n);for(let e=0;e<o.values.length;e++)o.values[e]=a.nextValue();return o.toTensor()}const nD=Xa({randomGamma_:rD});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function PD(e,t=0,r=1,n,P){if(null!=n&&"bool"===n)throw new Error(`Unsupported data type ${n}`);const a=new $O(t,r,n,!1,P),o=au(e,n);for(let e=0;e<o.values.length;e++)o.values[e]=a.nextValue();return o.toTensor()}const aD=Xa({randomNormal_:PD});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function oD(e,t,r){if(null!=t&&"bool"===t)throw new Error(`Unsupported data type ${t}`);return aD(e,0,1,t,r)}const uD=Xa({randomStandardNormal_:oD});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function sD(e,t=0,r=1,n="float32",P){const a=au(e,n),o=new tD(t,r,null,P);for(let e=0;e<a.values.length;e++)a.values[e]=o.nextValue();return a.toTensor()}const vD=Xa({randomUniform_:sD});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function iD(e,t,r=1,n="float32"){if(0===r)throw new Error("Cannot have a step of zero");const P={start:e,stop:t,step:r,dtype:n};return Ua.runKernel(gn,{},P)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function lD(e){const t={x:Ba(e,"x","reciprocal")};return Ua.runKernel(Tn,t)}const cD=Xa({reciprocal_:lD});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function OD(e){const t={x:Ba(e,"x","relu")};return Ua.runKernel(zn,t)}const DD=Xa({relu_:OD});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function jD(e){const t={x:Ba(e,"x","relu6")};return Ua.runKernel(Ln,t)}const hD=Xa({relu6_:jD});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function pD(e,t){const r={x:Ba(e,"x","reverse")},n={dims:t};return Ua.runKernel(fn,r,n)}const mD=Xa({reverse_:pD});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function gD(e){const t=Ba(e,"x","reverse");return xe(1===t.rank,(()=>`Error in reverse1D: x must be rank 1 but got rank ${t.rank}.`)),mD(t,0)}const bD=Xa({reverse1d_:gD});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function TD(e,t){const r=Ba(e,"x","reverse");return xe(2===r.rank,(()=>`Error in reverse2D: x must be rank 2 but got rank ${r.rank}.`)),mD(r,t)}const zD=Xa({reverse2d_:TD});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function dD(e,t){const r=Ba(e,"x","reverse");return xe(3===r.rank,(()=>`Error in reverse3D: x must be rank 3 but got rank ${r.rank}.`)),mD(r,t)}const yD=Xa({reverse3d_:dD});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function wD(e,t){const r=Ba(e,"x","reverse");return xe(4===r.rank,(()=>`Error in reverse4D: x must be rank 4 but got rank ${r.rank}.`)),mD(r,t)}const LD=Xa({reverse4d_:wD});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function fD(e){const t={x:Ba(e,"x","round")};return Ua.runKernel(In,t)}const ID=Xa({round_:fD});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function SD(e){const t={x:Ba(e,"x","rsqrt","float32")};return Ua.runKernel(Sn,t)}const AD=Xa({rsqrt_:SD});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function xD(e){const t={x:Ba(e,"x","selu")};return Ua.runKernel(kn,t)}const YD=Xa({selu_:xD});function kD(e,t,r,n,P,a=[1,1],o="NHWC"){const u=Ba(e,"x","separableConv2d"),s=Ba(t,"depthwiseFilter","separableConv2d"),v=Ba(r,"pointwiseFilter","separableConv2d");let i=u,l=!1;if(3===u.rank&&(l=!0,i=Qv(u,[1,u.shape[0],u.shape[1],u.shape[2]])),"NCHW"===o)throw new Error("separableConv2d currently does not support dataFormat NCHW; only NHWC is supported");xe(4===i.rank,(()=>`Error in separableConv2d: input must be rank 4, but got rank ${i.rank}.`)),xe(4===s.rank,(()=>`Error in separableConv2d: depthwise filter must be rank 4, but got rank ${s.rank}.`)),xe(4===v.rank,(()=>`Error in separableConv2d: pointwise filter must be rank 4, but got rank ${s.rank}.`)),xe(1===v.shape[0],(()=>`Error in separableConv2d: the first dimension of pointwise filter  must be 1, but got ${v.shape[0]}.`)),xe(1===v.shape[1],(()=>`Error in separableConv2d: the second dimension of pointwise filter must be 1, but got ${v.shape[1]}.`));const c=s.shape[2],O=s.shape[3];xe(v.shape[2]===c*O,(()=>`Error in separableConv2d: the third dimension of pointwise filter must be ${c*O}, but got ${v.shape[2]}.`));const D=$i(i,s,n,P,o,a),j=fi(D,v,1,"valid",o);return l?Qv(j,[j.shape[1],j.shape[2],j.shape[3]]):j}const CD=Xa({separableConv2d_:kD});
/**
     * @license
     * Copyright 2020 Google Inc. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */async function ED(e,t){const r=Ba(e,"x","setdiff1d"),n=Ba(t,"y","setdiff1d");xe(r.dtype===n.dtype,(()=>`x and y should have the same dtype, but got x (${r.dtype}) and y (${n.dtype}).`)),xe(1===r.rank,(()=>`x should be 1D tensor, but got x (${r.shape}).`)),xe(1===n.rank,(()=>`y should be 1D tensor, but got y (${n.shape}).`));const P=await r.data(),a=await n.data(),o=new Set(a);let u=0;for(let e=0;e<P.length;e++)o.has(P[e])||u++;const s=new pa([u],r.dtype),v=new pa([u],"int32");for(let e=0,t=0;e<P.length;e++)o.has(P[e])||(s.values[t]=P[e],v.values[t]=e,t++);return[s.toTensor(),v.toTensor()]}const QD=ED;
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function WD(e){const t={x:Ba(e,"x","sign")};return Ua.runKernel(Wn,t)}const UD=Xa({sign_:WD});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function qD(e){const t={x:Ba(e,"x","sin","float32")};return Ua.runKernel(En,t)}const GD=Xa({sin_:qD});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function MD(e){const t={x:Ba(e,"x","sinh")};return Ua.runKernel(Qn,t)}const KD=Xa({sinh_:MD});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ND(e,t,r){const n=Ba(e,"x","slice1d");return xe(1===n.rank,(()=>`slice1d expects a rank-1 tensor, but got a rank-${n.rank} tensor`)),Bv(n,[t],[r])}const RD=Xa({slice1d_:ND});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function FD(e,t,r){const n=Ba(e,"x","slice2d");return xe(2===n.rank,(()=>`slice2d expects a rank-2 tensor, but got a rank-${n.rank} tensor`)),Bv(n,t,r)}const BD=Xa({slice2d_:FD});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ZD(e,t,r){const n=Ba(e,"x","slice3d");return xe(3===n.rank,(()=>`slice3d expects a rank-3 tensor, but got a rank-${n.rank} tensor`)),Bv(n,t,r)}const VD=Xa({slice3d_:ZD});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function XD(e,t,r){const n=Ba(e,"x","slice4d");return xe(4===n.rank,(()=>`slice4d expects a rank-4 tensor, but got a rank-${n.rank} tensor`)),Bv(n,t,r)}const HD=Xa({slice4d_:XD});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function JD(e,t=-1){const r=Ba(e,"logits","softmax","float32");if(-1===t&&(t=r.rank-1),t!==r.rank-1)throw Error(`Softmax along a non-last dimension is not yet supported. Logits was rank ${r.rank} and dim was ${t}`);const n={logits:r},P={dim:t};return Ua.runKernel(Rn,n,P)}const _D=Xa({softmax_:JD});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function $D(e){xe("complex64"===e.dtype,(()=>`The dtype for tf.spectral.fft() must be complex64 but got ${e.dtype}.`));const t={input:e};return Ua.runKernel(zr,t)}const ej=Xa({fft_:$D});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function tj(e){xe("complex64"===e.dtype,(()=>`The dtype for tf.spectral.ifft() must be complex64 but got ${e.dtype}.`));const t={input:e};return Ua.runKernel(kr,t)}const rj=Xa({ifft_:tj});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function nj(e){const t=e.shape[e.shape.length-1],r=e.size/t;let n;if(t<=2){const P=Qv(e,[r,t]);n=rj(P)}else{const P=[r,2*(t-1)],a=Qv(es(e),[r,t]),o=Qv(Hu(e),[r,t]),u=mD(Bv(a,[0,1],[r,t-2]),1),s=Rs(mD(Bv(o,[0,1],[r,t-2]),1),Cl(-1)),v=Kv([a,u],1),i=Kv([o,s],1),l=Qv(Ja(v,i),[P[0],P[1]]);n=rj(l)}if(n=es(n),3===e.rank&&0!==e.shape[0]){const t=n,r=e.shape[0];n=Qv(n,[r,n.shape[0]/r,n.shape[1]]),t.dispose()}return n}const Pj=Xa({irfft_:nj});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function aj(e,t,r=0){const n={x:Ba(e,"x","split")},P={numOrSizeSplits:t,axis:r};return Ua.runKernel(Nn,n,P)}const oj=Xa({split_:aj});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function uj(e,t){xe("float32"===e.dtype,(()=>`The dtype for rfft() must be real value but got ${e.dtype}`));let r=e.shape[e.shape.length-1];const n=e.size/r;let P;if(null!=t&&t<r){const n=e.shape.map((e=>0)),a=e.shape.map((e=>e));a[e.shape.length-1]=t,P=Bv(e,n,a),r=t}else if(null!=t&&t>r){const n=e.shape.map((e=>e));n[e.shape.length-1]=t-r,P=Kv([e,iO(n)],e.shape.length-1),r=t}else P=e;const a=vl(P),o=Qv(Ja(P,a),[n,r]),u=ej(o),s=Math.floor(r/2)+1,v=es(u),i=Hu(u),l=oj(v,[s,r-s],v.shape.length-1),c=oj(i,[s,r-s],i.shape.length-1),O=P.shape.slice();return O[P.shape.length-1]=s,Qv(Ja(l[0],c[0]),O)}const sj=Xa({rfft_:uj});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function vj(e,t){let r=Ba(e,"a","squaredDifference"),n=Ba(t,"b","squaredDifference");[r,n]=Ia(r,n),os(r.shape,n.shape);const P={a:r,b:n};return Ua.runKernel(Hn,P,{})}const ij=Xa({squaredDifference_:vj});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function lj(e,t){const r=Ba(e,"x","squeeze","string_or_numeric");return Qv(r,Ne(r.shape,t).newShape)}const cj=Xa({squeeze_:lj});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Oj(e,t=0){const r=Za(e,"tensors","stack","string_or_numeric");xe(r.length>=1,(()=>"Pass at least one tensor to tf.stack")),r.length>0&&xe(t<=r[0].rank,(()=>"Axis must be <= rank of the tensor"));const n=r,P={axis:t};return Ua.runKernel(Dn,n,P)}const Dj=Xa({stack_:Oj});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function jj(e,t=0){const r={x:Ba(e,"x","step")},n={alpha:t};return Ua.runKernel(cP,r,n)}const hj=Xa({step_:jj});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function pj(e,t,r,n,P=0,a=0,o=0,u=0,s=0){const v={x:Ba(e,"x","stridedSlice","string_or_numeric")},i={begin:t,end:r,strides:n,beginMask:P,endMask:a,ellipsisMask:o,newAxisMask:u,shrinkAxisMask:s};return Ua.runKernel(Jn,v,i)}const mj=Xa({stridedSlice_:pj});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function gj(e){const t={x:Ba(e,"x","tan","float32")};return Ua.runKernel(rP,t)}const bj=Xa({tan_:gj});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Tj(e,t){ke(e);const r=Na(e,t);if(1!==r.length)throw new Error("tensor1d() requires values to be a flat/TypedArray");return _a(e,null,r,t)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function zj(e,t,r){if(ke(e),null!=t&&2!==t.length)throw new Error("tensor2d() requires shape to have two numbers");const n=Na(e,r);if(2!==n.length&&1!==n.length)throw new Error("tensor2d() requires values to be number[][] or flat/TypedArray");if(1===n.length&&null==t)throw new Error("tensor2d() requires shape to be provided when `values` are a flat/TypedArray");return _a(e,t,n,r)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function dj(e,t,r){if(ke(e),null!=t&&4!==t.length)throw new Error("tensor4d() requires shape to have four numbers");const n=Na(e,r);if(4!==n.length&&1!==n.length)throw new Error("tensor4d() requires values to be number[][][][] or flat/TypedArray");if(1===n.length&&null==t)throw new Error("tensor4d() requires shape to be provided when `values` are a flat array");return _a(e,t,n,r)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function yj(e,t,r){if(ke(e),null!=t&&5!==t.length)throw new Error("tensor5d() requires shape to have five numbers");const n=Na(e,r);if(5!==n.length&&1!==n.length)throw new Error("tensor5d() requires values to be number[][][][][] or flat/TypedArray");if(1===n.length&&null==t)throw new Error("tensor5d() requires shape to be provided when `values` are a flat array");return _a(e,t,n,r)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function wj(e,t,r){if(ke(e),null!=t&&6!==t.length)throw new Error("tensor6d() requires shape to have six numbers");const n=Na(e,r);if(6!==n.length&&1!==n.length)throw new Error("tensor6d() requires values to be number[][][][][][] or flat/TypedArray");if(1===n.length&&null==t)throw new Error("tensor6d() requires shape to be provided when `values` are a flat array");return _a(e,t=t||n,n,r)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Lj(e,t=1,r=!0){const n=Ba(e,"x","topk");if(0===n.rank)throw new Error("topk() expects the input to be of rank 1 or higher");const P=n.shape[n.shape.length-1];if(t<0)throw new Error(`'k' passed to topk() must be >= 0 but got ${t}`);if(t>P)throw new Error(`'k' passed to topk() must be <= the last dimension (${P}) but got ${t}`);const a={x:n},o={k:t,sorted:r},[u,s]=Ua.runKernel(aP,a,o);return{values:u,indices:s}}const fj=Xa({topk_:Lj});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ij(e,t=0,r=1,n,P){if(null!=n&&"bool"===n)throw new Error("Unsupported data type $ { dtype }");const a=new $O(t,r,n,!0,P),o=au(e,n);for(let e=0;e<o.values.length;e++)o.values[e]=a.nextValue();return o.toTensor()}const Sj=Xa({truncatedNormal_:Ij});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Aj(e,t=0){const r=Ba(e,"x","unique","string_or_numeric");xe(r.rank>0,(()=>"The input tensor must be at least 1D"));const n={x:r},P={axis:t},[a,o]=Ua.runKernel(sP,n,P);return{values:a,indices:o}}const xj=Xa({unique_:Aj});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Yj(e,t,r){const n=Ba(e,"x","unsortedSegmentSum"),P=Ba(t,"segmentIds","unsortedSegmentSum","int32");xe(We(r),(()=>"numSegments must be of dtype int"));const a={x:n,segmentIds:P},o={numSegments:r};return Ua.runKernel(iP,a,o)}const kj=Xa({unsortedSegmentSum_:Yj});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Cj(e,t=0){const r=Ba(e,"x","unstack","string_or_numeric");xe(t>=-r.shape.length&&t<r.shape.length,(()=>`Axis = ${t} is not in [-${r.shape.length}, ${r.shape.length})`));const n={value:r},P={axis:t};return Ua.runKernel(vP,n,P)}const Ej=Xa({unstack_:Cj});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Qj(e,t){return _c(e,t,"right")}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Wj(e,t=!0,r,n){return Ua.makeVariable(e,t,r,n)}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Uj(e,t){const r=[];for(let e=0;e<t.length;e++)t[e]&&r.push(e);const n=au(e,"int32"),P=au([r.length,e.length],"int32");for(let t=0;t<r.length;t++){const a=n.indexToLoc(r[t]),o=t*e.length;P.values.set(a,o)}return P.toTensor()}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */async function qj(e){const t=Ba(e,"condition","whereAsync","bool"),r=await t.data(),n=Uj(t.shape,r);return e!==t&&t.dispose(),n}const Gj=qj;
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */async function Mj(e,t,r){const n=Ba(e,"tensor","boolMask"),P=Ba(t,"mask","boolMask","bool"),a=null==r?0:r,o=P.rank,u=n.shape;xe(o>0,(()=>"mask cannot be scalar")),Ye(u.slice(a,a+o),P.shape,"mask's shape must match the first K dimensions of tensor's shape,");let s=1;for(let e=a;e<a+o;e++)s*=u[e];const v=u.slice(0,a).concat([s],u.slice(a+o)),i=Qv(n,v),l=Qv(P,[-1]),c=await Gj(l),O=cj(c,[1]),D=oc(i,O,a);return e!==n&&n.dispose(),t!==P&&P.dispose(),O.dispose(),i.dispose(),l.dispose(),c.dispose(),D}const Kj=Mj;
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Nj(e,t,r,n,P=!0){const a=Ba(e,"v","movingAverage"),o=Ba(t,"x","movingAverage"),u=Ba(r,"decay","movingAverage");Sa(a,o),xe(Qe(a.shape,o.shape),(()=>"Shape mismatch in v and x"));const s=Cl(1),v=Wc(s,u);let i=Rs(Wc(o,a),v);if(P){xe(null!=n,(()=>"When using zeroDebias: true, step is required."));const e=Ba(n,"step","movingAverage");i=Ks(i,Wc(s,kl(u,e)))}return Us(a,i)}const Rj=Xa({movingAverage_:Nj});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Fj(e,t,r){const n=Ba(e,"indices","scatterND","int32"),P=Ba(t,"updates","scatterND");cs(P,n,r);const a={indices:n,updates:P},o={shape:r};return Ua.runKernel(An,a,o)}const Bj=Xa({scatterND_:Fj});function Zj(e,t,r,n){if("int32"!==e.dtype)throw new Error(`tf.sparseToDense() expects the indices to be int32 type, but the dtype was ${e.dtype}.`);if(e.rank>2)throw new Error(`sparseIndices should be a scalar, vector, or matrix, but got shape ${e.shape}.`);const P=e.rank>0?e.shape[0]:1,a=e.rank>1?e.shape[1]:1;if(r.length!==a)throw new Error(`outputShape has incorrect number of elements:, ${r.length}, should be: ${a}.`);const o=t.size;if(0!==t.rank&&(1!==t.rank||o!==P))throw new Error(`sparseValues has incorrect shape ${t.shape}, should be [] or [${P}]`);if(t.dtype!==n.dtype)throw new Error("sparseValues.dtype must match defaultValues.dtype")}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Vj(e,t,r,n=0){const P=Ba(e,"sparseIndices","sparseToDense","int32"),a=Ba(t,"sparseValues","sparseToDense","string_or_numeric"),o=Ba(n,"defaultValue","sparseToDense",a.dtype);Zj(P,a,r,o);const u={sparseIndices:P,sparseValues:a,defaultValue:o},s={outputShape:r};return Ua.runKernel(Xn,u,s)}const Xj=Xa({sparseToDense_:Vj});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Hj(e,t){const r=Ba(t,"indices","gatherND","int32"),n={params:Ba(e,"x","gatherND","string_or_numeric"),indices:r};return Ua.runKernel(Sr,n)}const Jj=Xa({gatherND_:Hj});
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function _j(e,t){if(null==t)return e.shape.slice();if(Qe(e.shape,t))return t;if(e.shape.length===t.length){const r=[];for(let n=0;n<e.shape.length;n++)null==t[n]&&null!=e.shape[n]?r.push(e.shape[n]):r.push(t[n]);return r}return t}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function $j(e,t,r,n){const P=Ba(e,"x","dropout");if(xe("float32"===P.dtype,(()=>`x has to be a floating point tensor since it's going to be scaled, but got a ${P.dtype} tensor instead.`)),xe(t>=0&&t<1,(()=>`rate must be a float in the range [0, 1), but got ${t}.`)),0===t)return e instanceof za?P.clone():P;const a=_j(P,r),o=1-t,u=Ks(Pc(Us(vD(a,0,1,"float32",n),o)),o);return Rs(P,u)}const eh=Xa({dropout_:$j});
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function th(e){return Math.floor(Math.pow(2,Math.ceil(Math.log(e)/Math.log(2))))}function rh(e,t,r){const n=1-e%2,P=new Float32Array(e);for(let a=0;a<e;++a){const o=2*Math.PI*a/(e+n-1);P[a]=t-r*Math.cos(o)}return Tj(P,"float32")}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */async function nh(e,t,r=1){const n=Ba(e,"predictions","inTopK"),P=Ba(t,"targets","inTopK");xe(n.rank>1,(()=>`inTopK() expects the predictions to be of rank 2 or higher, but got ${n.rank}`)),xe(n.rank-1===P.rank,(()=>`predictions rank should be 1 larger than targets rank, but got predictions rank ${n.rank} and targets rank ${P.rank}`)),Ye(n.shape.slice(0,n.shape.length-1),P.shape,"predictions's shape should be align with the targets' shape, except the last dimension.");const a=n.shape[n.shape.length-1];xe(r>0&&r<=a,(()=>`'k' passed to inTopK() must be > 0 && <= the predictions last dimension (${a}), but got ${r}`));const o=await n.data(),u=await P.data(),[s,v]=[o.length/a,a],i=Re("bool",s);for(let e=0;e<s;e++){const t=e*v,n=o.subarray(t,t+v),P=[];for(let e=0;e<n.length;e++)P.push({value:n[e],index:e});P.sort(((e,t)=>t.value-e.value)),i[e]=0;for(let t=0;t<r;t++)if(P[t].index===u[e]){i[e]=1;break}}return e!==n&&n.dispose(),t!==P&&P.dispose(),$a(i,P.shape,"bool")}const Ph=nh;
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ah(e,t,r,n,P,a="NHWC",o){let u=e;3===e.rank&&(u=Qv(e,[1,e.shape[0],e.shape[1],e.shape[2]]));let s=t;3===s.rank&&(s=Qv(t,[1,t.shape[0],t.shape[1],t.shape[2]])),xe(4===u.rank,(()=>`Error in conv2dDerFilter: input must be rank 4, but got shape ${u.shape}.`)),xe(4===s.rank,(()=>`Error in conv2dDerFilter: dy must be rank 4, but got shape ${s.shape}.`)),xe(4===r.length,(()=>`Error in conv2dDerFilter: filterShape must be length 4, but got ${r}.`));const v="NHWC"===a?u.shape[3]:u.shape[1],i="NHWC"===a?s.shape[3]:s.shape[1];xe(v===r[2],(()=>`Error in conv2dDerFilter: depth of input ${v}) must match input depth in filter (${r[2]}.`)),xe(i===r[3],(()=>`Error in conv2dDerFilter: depth of dy (${i}) must match output depth for filter (${r[3]}).`)),Cv("conv2dDerFilter",P,o);const l={x:u,dy:s},c={strides:n,pad:P,dataFormat:a,dimRoundingMode:o,filterShape:r};return Ua.runKernel(_t,l,c)}const oh=Xa({conv2DBackpropFilter_:ah});
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function uh(e,t,r){if(null==r||"linear"===r)return e;if("relu"===r)return Rs(e,hj(t));throw new Error(`Cannot compute gradient for fused activation ${r}.`)}function sh(e,t){let r=t;const n=as(e.shape,t.shape);return n.length>0&&(r=Gl(r,n)),Qv(r,e.shape)}function vh(e,t,r,n){if("linear"===t)return e;if("relu"===t)return DD(e);if("elu"===t)return pl(e);if("relu6"===t)return hD(e);if("prelu"===t)return VO(e,r);if("leakyrelu"===t)return mc(e,n);if("sigmoid"===t)return Rv(e);throw new Error(`Unknown fused activation ${t}.`)}const ih=(e,t)=>!(e>0)||"linear"===t;
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function lh({x:e,filter:t,strides:r,pad:n,dataFormat:P="NHWC",dilations:a=[1,1],dimRoundingMode:o,bias:u,activation:s="linear",preluActivationWeights:v,leakyreluAlpha:i}){if(s=s||"linear",!1===ih(Ua.state.gradientDepth,s)){xe("NHWC"===P,(()=>`Error in fused conv2d: got dataFormat of ${P} but only NHWC is currently supported for the case of gradient depth is 0 and the activation is not linear.`));let l=fi(e,t,r,n,P,a,o);return null!=u&&(l=Us(l,u)),vh(l,s,v,i)}const l=Ba(e,"x","conv2d","float32"),c=Ba(t,"filter","conv2d","float32");let O=l,D=!1;3===l.rank&&(D=!0,O=Qv(l,[1,l.shape[0],l.shape[1],l.shape[2]])),xe(4===O.rank,(()=>`Error in fused conv2d: input must be rank 4, but got rank ${O.rank}.`)),xe(4===c.rank,(()=>`Error in fused conv2d: filter must be rank 4, but got rank ${c.rank}.`)),Cv("fused conv2d",n,o);const j="NHWC"===P?O.shape[3]:O.shape[1];xe(c.shape[2]===j,(()=>`Error in conv2d: depth of input (${j}) must match input depth for filter ${c.shape[2]}.`)),xe(Yv(r,a),(()=>`Error in conv2D: Either strides or dilations must be 1. Got strides ${r} and dilations '${a}'`));const h=bv(O.shape,c.shape,r,a,n,o);let p,m;if(null!=u&&(p=Ba(u,"bias","fused conv2d"),[p]=Ia(p,l),"NHWC"===P?os(h.outShape,p.shape):(xe(p.shape.length<=1,(()=>`Error in fused conv2d: only supports scalar or 1-D Tensor bias for NCHW format but got the bias of rank-${p.shape.length}.`)),xe(0===p.shape.length||p.shape[0]===h.outChannels||1===p.shape[0],(()=>`Error in fused conv2d: bias shape (${p.shape}) is not compatible with the number of output channels (${h.outChannels})`)))),null!=v){const e=v.shape;if(xe(e.length<=1||3===e.length,(()=>`Error in fused conv2d: only supports scalar, 1-D Tensor or 3-D Tensor PReLU activation weights but got a tensor of rank-${e.length}.`)),1===e.length)xe(1===e[0]||e[0]===h.outChannels,(()=>`Error in fused conv2d: PReLU activation weights (${e}) is not compatible with the number of output channels (${h.outChannels}).`));else if(3===e.length)try{os(e,h.outShape)}catch(t){const r=`Error in fused conv2d: PReLU activation weights (${e}) is not compatible with the output shape of the conv2d (${h.outShape}).`;throw Error(r)}m=Ba(v,"prelu weights","fused conv2d")}const g=(e,t)=>{xe("NHWC"===P,(()=>`Error in gradient of fused conv2D: got dataFormat of ${P} but only NHWC is currently supported.`));const[o,u,v,i]=t,l=uh(e,v,s);xe(xv(a),(()=>`Error in gradient of fused conv2D: dilation rates greater than 1 are not yet supported in gradients. Got dilations '${a}'`));const c=[xi(u.shape,l,o,r,n),oh(u,l,o.shape,r,n)];if(null!=i){const e=sh(i,l);c.push(e)}return c},b={x:O,filter:c,bias:p,preluActivationWeights:m},T={strides:r,pad:n,dataFormat:P,dilations:a,dimRoundingMode:o,activation:s,leakyreluAlpha:i};if(null==u){const e=xc(((e,t,r)=>{let n=Ua.runKernel(hP,b,T);return r([t,e,n]),D&&(n=Qv(n,[n.shape[1],n.shape[2],n.shape[3]])),{value:n,gradFunc:g}}));return e(O,c)}{const e=xc(((e,t,r,n)=>{let P=Ua.runKernel(hP,b,T);return n([t,e,P,r]),D&&(P=Qv(P,[P.shape[1],P.shape[2],P.shape[3]])),{value:P,gradFunc:g}}));return e(O,c,p)}}const ch=Xa({fusedConv2d_:lh});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Oh(e,t,r,n,P,a=[1,1],o){let u=e;3===e.rank&&(u=Qv(e,[1,e.shape[0],e.shape[1],e.shape[2]]));let s=t;3===s.rank&&(s=Qv(t,[1,t.shape[0],t.shape[1],t.shape[2]]));const v={x:u,dy:s},i={strides:n,pad:P,dimRoundingMode:o,dilations:a,filterShape:r};return Ua.runKernel(ir,v,i)}const Dh=Xa({depthwiseConv2dNativeBackpropFilter_:Oh});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function jh(e,t,r,n,P,a=[1,1],o){let u=t,s=!1;3===t.rank&&(s=!0,u=Qv(t,[1,t.shape[0],t.shape[1],t.shape[2]]));const v={dy:u,filter:r},i={strides:n,pad:P,dimRoundingMode:o,dilations:a,inputShape:e},l=Ua.runKernel(lr,v,i);return s?Qv(l,[l.shape[1],l.shape[2],l.shape[3]]):l}const hh=Xa({depthwiseConv2dNativeBackpropInput_:jh});
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ph({x:e,filter:t,strides:r,pad:n,dataFormat:P="NHWC",dilations:a=[1,1],dimRoundingMode:o,bias:u,activation:s="linear",preluActivationWeights:v,leakyreluAlpha:i}){if(!1===ih(Ua.state.gradientDepth,s)){let l=$i(e,t,r,n,P,a,o);return null!=u&&(l=Us(l,u)),vh(l,s,v,i)}const l=Ba(e,"x","depthwiseConv2d","float32"),c=Ba(t,"filter","depthwiseConv2d","float32");let O=l,D=!1;3===l.rank&&(D=!0,O=Qv(l,[1,l.shape[0],l.shape[1],l.shape[2]])),xe(4===O.rank,(()=>`Error in fused depthwiseConv2d: input must be rank 4, but got rank ${O.rank}.`)),xe(4===c.rank,(()=>`Error in fused depthwiseConv2d: filter must be rank 4, but got rank ${c.rank}.`)),xe(O.shape[3]===c.shape[2],(()=>`Error in fused depthwiseConv2d: number of input channels (${O.shape[3]}) must match the inChannels dimension in filter ${c.shape[2]}.`)),null==a&&(a=[1,1]),xe(Yv(r,a),(()=>`Error in fused depthwiseConv2d: Either strides or dilations must be 1. Got strides ${r} and dilations '${a}'`)),Cv("fused depthwiseConv2d",n,o);const j=bv(O.shape,c.shape,r,a,n,o,!0);let h,p;null!=u&&(h=Ba(u,"bias","fused conv2d"),[h]=Ia(h,l),os(j.outShape,h.shape)),null!=v&&(p=Ba(v,"prelu weights","fused depthwiseConv2d"));const m=(e,t)=>{xe(xv(a),(()=>`Error in gradient of fused depthwiseConv2d: dilation rates greater than 1 are not yet supported. Got dilations '${a}'`));const[P,u,v,i]=t,l=uh(e,v,s),c=hh(u.shape,l,P,r,n,a,o),O=Dh(u,l,P.shape,r,n,a,o);if(null!=i){return[c,O,sh(h,l)]}return[c,O]},g={x:O,filter:c,bias:h,preluActivationWeights:p},b={strides:r,pad:n,dataFormat:P,dilations:a,dimRoundingMode:o,activation:s,leakyreluAlpha:i};if(null==u){const e=xc(((e,t,r)=>{let n=Ua.runKernel(pP,g,b);return r([t,e,n]),D&&(n=Qv(n,[n.shape[1],n.shape[2],n.shape[3]])),{value:n,gradFunc:m}}));return e(O,c)}{const e=xc(((e,t,r,n)=>{let P=Ua.runKernel(pP,g,b);return n([t,e,P,r]),D&&(P=Qv(P,[P.shape[1],P.shape[2],P.shape[3]])),{value:P,gradFunc:m}}));return e(O,c,h)}}const mh=Xa({fusedDepthwiseConv2d_:ph});
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function gh({a:e,b:t,transposeA:r=!1,transposeB:n=!1,bias:P,activation:a="linear",preluActivationWeights:o,leakyreluAlpha:u=.2}){if(!1===ih(Ua.state.gradientDepth,a)){let s=Gu(e,t,r,n);return null!=P&&(s=Us(s,P)),vh(s,a,o,u)}let s=Ba(e,"a","fused matMul"),v=Ba(t,"b","fused matMul");[s,v]=Ia(s,v);const i=r?s.shape[s.rank-2]:s.shape[s.rank-1],l=n?v.shape[v.rank-1]:v.shape[v.rank-2],c=r?s.shape[s.rank-1]:s.shape[s.rank-2],O=n?v.shape[v.rank-2]:v.shape[v.rank-1],D=s.shape.slice(0,-2),j=v.shape.slice(0,-2),h=Ee(D),p=Ee(j);xe(i===l,(()=>`Error in fused matMul: inner shapes (${i}) and (${l}) of Tensors with shapes ${s.shape} and ${v.shape} and transposeA=${r} and transposeB=${n} must match.`));const m=os(s.shape.slice(0,-2),v.shape.slice(0,-2)).concat([c,O]),g=Qv(s,r?[h,i,c]:[h,c,i]),b=Qv(v,n?[p,O,l]:[p,l,O]);let T,z;null!=P&&(T=Ba(P,"bias","fused matMul"),[T]=Ia(T,s),os(m,T.shape)),null!=o&&(z=Ba(o,"prelu weights","fused matMul"));const d=(e,t)=>{const[o,u,s,v]=t,i=uh(Qv(e,s.shape),s,a);let l,c;if(r||n?!r&&n?(l=Gu(i,u,!1,!1),c=Gu(i,o,!0,!1)):r&&!n?(l=Gu(u,i,!1,!0),c=Gu(o,i,!1,!1)):(l=Gu(u,i,!0,!0),c=Gu(i,o,!0,!0)):(l=Gu(i,u,!1,!0),c=Gu(o,i,!0,!1)),null!=P){return[l,c,sh(v,i)]}return[l,c]},y={a:g,b:b,bias:T,preluActivationWeights:z},w={transposeA:r,transposeB:n,activation:a,leakyreluAlpha:u};if(null==P){const e=xc(((e,t,r)=>{const n=Ua.runKernel(jP,y,w);return r([e,t,n]),{value:Qv(n,m),gradFunc:d}}));return e(g,b)}{const e=xc(((e,t,r,n)=>{const P=Ua.runKernel(jP,y,w);return n([e,t,P,r]),{value:Qv(P,m),gradFunc:d}}));return e(g,b,T)}}const bh=Xa({fusedMatMul_:gh});
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */var K=Object.freeze({__proto__:null,conv2d:ch,depthwiseConv2d:mh,matMul:bh});
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Th(e){return rh(e,.54,.46)}const zh=Xa({hammingWindow_:Th});
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function dh(e){return rh(e,.5,.5)}const yh=Xa({hannWindow_:dh});
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function wh(e,t,r,n=!1,P=0){let a=0;const o=[];for(;a+t<=e.size;)o.push(Bv(e,a,t)),a+=r;if(n)for(;a<e.size;){const n=a+t-e.size,u=Kv([Bv(e,a,t-n),rc([n],P)]);o.push(u),a+=r}return 0===o.length?zj([],[0,t]):Qv(Kv(o),[o.length,t])}const Lh=Xa({frame_:wh});
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function fh(e,t,r,n,P=yh){null==n&&(n=th(t));const a=Lh(e,t,r),o=Rs(a,P(t));return sj(o,n)}const Ih=Xa({stft_:fh});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Sh(e,t,r,n,P="bilinear",a=0){const o=Ba(e,"image","cropAndResize"),u=Ba(t,"boxes","cropAndResize","float32"),s=Ba(r,"boxInd","cropAndResize","int32"),v=u.shape[0];xe(4===o.rank,(()=>`Error in cropAndResize: image must be rank 4,but got rank ${o.rank}.`)),xe(2===u.rank&&4===u.shape[1],(()=>`Error in cropAndResize: boxes must be have size [${v},4] but had shape ${u.shape}.`)),xe(1===s.rank&&s.shape[0]===v,(()=>`Error in cropAndResize: boxInd must be have size [${v}] but had shape ${u.shape}.`)),xe(2===n.length,(()=>`Error in cropAndResize: cropSize must be of length 2, but got length ${n.length}.`)),xe(n[0]>=1&&n[1]>=1,(()=>`cropSize must be atleast [1,1], but was ${n}`)),xe("bilinear"===P||"nearest"===P,(()=>`method must be bilinear or nearest, but was ${P}`));const i={image:o,boxes:u,boxInd:s},l={method:P,extrapolationValue:a,cropSize:n};return Ua.runKernel(or,i,l)}const Ah=Xa({cropAndResize_:Sh});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function xh(e){const t=Ba(e,"image","flipLeftRight","float32");xe(4===t.rank,(()=>`Error in flipLeftRight: image must be rank 4,but got rank ${t.rank}.`));const r={image:t};return Ua.runKernel(yr,r,{})}const Yh=Xa({flipLeftRight_:xh});
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function kh(e){const t=Ba(e,"image","grayscaleToRGB"),r=t.rank-1,n=t.shape[r];xe(t.rank>=2,(()=>`Error in grayscaleToRGB: images must be at least rank 2, but got rank ${t.rank}.`)),xe(1===n,(()=>`Error in grayscaleToRGB: last dimension of a grayscale image should be size 1, but got size ${n}.`));const P=new Array(t.rank);return P.fill(1,0,r),P[r]=3,$l(t,P)}const Ch=Xa({grayscaleToRGB_:kh});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Eh(e,t,r=0,n=.5){const P=Ba(e,"image","rotateWithOffset","float32");xe(4===P.rank,(()=>`Error in rotateWithOffset: image must be rank 4,but got rank ${P.rank}.`));const a={image:P},o={radians:t,fillValue:r,center:n};return Ua.runKernel(DP,a,o)}const Qh=Xa({rotateWithOffset_:Eh});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Wh(e,t,r,n,P,a){null==n&&(n=.5),null==P&&(P=Number.NEGATIVE_INFINITY),null==a&&(a=0);const o=e.shape[0];return r=Math.min(r,o),xe(0<=n&&n<=1,(()=>`iouThreshold must be in [0, 1], but was '${n}'`)),xe(2===e.rank,(()=>`boxes must be a 2D tensor, but was of rank '${e.rank}'`)),xe(4===e.shape[1],(()=>`boxes must have 4 columns, but 2nd dimension was ${e.shape[1]}`)),xe(1===t.rank,(()=>"scores must be a 1D tensor")),xe(t.shape[0]===o,(()=>`scores has incompatible shape with boxes. Expected ${o}, but was ${t.shape[0]}`)),xe(0<=a&&a<=1,(()=>`softNmsSigma must be in [0, 1], but was '${a}'`)),{maxOutputSize:r,iouThreshold:n,scoreThreshold:P,softNmsSigma:a}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Uh(e,t,r,n=.5,P=Number.NEGATIVE_INFINITY){const a=Ba(e,"boxes","nonMaxSuppression","float32"),o=Ba(t,"scores","nonMaxSuppression","float32"),u=Wh(a,o,r,n,P),s={maxOutputSize:r=u.maxOutputSize,iouThreshold:n=u.iouThreshold,scoreThreshold:P=u.scoreThreshold};return Ua.runKernel(sn,{boxes:a,scores:o},s)}const qh=Xa({nonMaxSuppression_:Uh});
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Gh(e,t,r){const n=Mh(e,t,r),P=n<0?-(n+1):n;e.splice(P,0,t)}function Mh(e,t,r){return Nh(e,t,r||Kh)}function Kh(e,t){return e>t?1:e<t?-1:0}function Nh(e,t,r){let n=0,P=e.length,a=0,o=!1;for(;n<P;){a=n+(P-n>>>1);const u=r(t,e[a]);u>0?n=a+1:(P=a,o=!u)}return o?n:-n-1}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Rh(e,t,r,n,P){return Zh(e,t,r,n,P,0)}function Fh(e,t,r,n,P,a){return Zh(e,t,r,n,P,0,!1,a,!0)}function Bh(e,t,r,n,P,a){return Zh(e,t,r,n,P,a,!0)}function Zh(e,t,r,n,P,a,o=!1,u=!1,s=!1){const v=[];for(let e=0;e<t.length;e++)t[e]>P&&v.push({score:t[e],boxIndex:e,suppressBeginIndex:0});v.sort(Hh);const i=a>0?-.5/a:0,l=[],c=[];for(;l.length<r&&v.length>0;){const t=v.pop(),{score:r,boxIndex:a,suppressBeginIndex:o}=t;if(r<P)break;let u=!1;for(let r=l.length-1;r>=o;--r){const o=Vh(e,a,l[r]);if(o>=n){u=!0;break}if(t.score=t.score*Xh(n,i,o),t.score<=P)break}t.suppressBeginIndex=l.length,u||(t.score===r?(l.push(a),c.push(t.score)):t.score>P&&Gh(v,t,Hh))}const O=l.length,D=r-O;u&&D>0&&(l.push(...new Array(D).fill(0)),c.push(...new Array(D).fill(0)));const j={selectedIndices:l};return o&&(j.selectedScores=c),s&&(j.validOutputs=O),j}function Vh(e,t,r){const n=e.subarray(4*t,4*t+4),P=e.subarray(4*r,4*r+4),a=Math.min(n[0],n[2]),o=Math.min(n[1],n[3]),u=Math.max(n[0],n[2]),s=Math.max(n[1],n[3]),v=Math.min(P[0],P[2]),i=Math.min(P[1],P[3]),l=Math.max(P[0],P[2]),c=Math.max(P[1],P[3]),O=(u-a)*(s-o),D=(l-v)*(c-i);if(O<=0||D<=0)return 0;const j=Math.max(a,v),h=Math.max(o,i),p=Math.min(u,l),m=Math.min(s,c),g=Math.max(p-j,0)*Math.max(m-h,0);return g/(O+D-g)}function Xh(e,t,r){const n=Math.exp(t*r*r);return r<=e?n:0}function Hh(e,t){return e.score-t.score||e.score===t.score&&t.boxIndex-e.boxIndex}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */async function Jh(e,t,r,n=.5,P=Number.NEGATIVE_INFINITY){const a=Ba(e,"boxes","nonMaxSuppressionAsync"),o=Ba(t,"scores","nonMaxSuppressionAsync"),u=Wh(a,o,r,n,P);r=u.maxOutputSize,n=u.iouThreshold,P=u.scoreThreshold;const s=await Promise.all([a.data(),o.data()]),v=s[0],i=s[1],{selectedIndices:l}=Rh(v,i,r,n,P);return a!==e&&a.dispose(),o!==t&&o.dispose(),Tj(l,"int32")}const _h=Jh;
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function $h(e,t,r,n=.5,P=Number.NEGATIVE_INFINITY,a=0){const o=Ba(e,"boxes","nonMaxSuppression"),u=Ba(t,"scores","nonMaxSuppression"),s=Wh(o,u,r,n,P,a),v={boxes:o,scores:u},i={maxOutputSize:r=s.maxOutputSize,iouThreshold:n=s.iouThreshold,scoreThreshold:P=s.scoreThreshold,softNmsSigma:a=s.softNmsSigma},l=Ua.runKernel(ln,v,i);return{selectedIndices:l[0],selectedScores:l[1]}}const ep=Xa({nonMaxSuppressionWithScore_:$h});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */async function tp(e,t,r,n=.5,P=Number.NEGATIVE_INFINITY,a=0){const o=Ba(e,"boxes","nonMaxSuppressionAsync"),u=Ba(t,"scores","nonMaxSuppressionAsync"),s=Wh(o,u,r,n,P,a);r=s.maxOutputSize,n=s.iouThreshold,P=s.scoreThreshold,a=s.softNmsSigma;const v=await Promise.all([o.data(),u.data()]),i=v[0],l=v[1],{selectedIndices:c,selectedScores:O}=Bh(i,l,r,n,P,a);return o!==e&&o.dispose(),u!==t&&u.dispose(),{selectedIndices:Tj(c,"int32"),selectedScores:Tj(O)}}const rp=tp;
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function np(e,t,r,n=.5,P=Number.NEGATIVE_INFINITY,a=!1){const o=Ba(e,"boxes","nonMaxSuppression"),u=Ba(t,"scores","nonMaxSuppression"),s=Wh(o,u,r,n,P,null),v={boxes:o,scores:u},i={maxOutputSize:s.maxOutputSize,iouThreshold:s.iouThreshold,scoreThreshold:s.scoreThreshold,padToMaxOutputSize:a},l=Ua.runKernel(vn,v,i);return{selectedIndices:l[0],validOutputs:l[1]}}const Pp=Xa({nonMaxSuppressionPadded_:np});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */async function ap(e,t,r,n=.5,P=Number.NEGATIVE_INFINITY,a=!1){const o=Ba(e,"boxes","nonMaxSuppressionAsync"),u=Ba(t,"scores","nonMaxSuppressionAsync"),s=Wh(o,u,r,n,P,null),v=s.maxOutputSize,i=s.iouThreshold,l=s.scoreThreshold,[c,O]=await Promise.all([o.data(),u.data()]),{selectedIndices:D,validOutputs:j}=Fh(c,O,v,i,l,a);return o!==e&&o.dispose(),u!==t&&u.dispose(),{selectedIndices:Tj(D,"int32"),validOutputs:Cl(j,"int32")}}const op=ap;
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function up(e,t,r=!1,n=!1){const P=Ba(e,"images","resizeBilinear");xe(3===P.rank||4===P.rank,(()=>`Error in resizeBilinear: x must be rank 3 or 4, but got rank ${P.rank}.`)),xe(2===t.length,(()=>`Error in resizeBilinear: new shape must 2D, but got shape ${t}.`)),xe(!1===n||!1===r,(()=>"Error in resizeBilinear: If halfPixelCenters is true, alignCorners must be false."));let a=P,o=!1;3===P.rank&&(o=!0,a=Qv(P,[1,P.shape[0],P.shape[1],P.shape[2]]));const u={images:a},s={alignCorners:r,halfPixelCenters:n,size:t},v=Ua.runKernel(wn,u,s);return o?Qv(v,[v.shape[1],v.shape[2],v.shape[3]]):v}const sp=Xa({resizeBilinear_:up});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function vp(e,t,r=!1,n=!1){const P=Ba(e,"images","resizeNearestNeighbor");xe(3===P.rank||4===P.rank,(()=>`Error in resizeNearestNeighbor: x must be rank 3 or 4, but got rank ${P.rank}.`)),xe(2===t.length,(()=>`Error in resizeNearestNeighbor: new shape must 2D, but got shape ${t}.`)),xe("float32"===P.dtype||"int32"===P.dtype,(()=>"`images` must have `int32` or `float32` as dtype")),xe(!1===n||!1===r,(()=>"Error in resizeNearestNeighbor: If halfPixelCenters is true, alignCorners must be false."));let a=P,o=!1;3===P.rank&&(o=!0,a=Qv(P,[1,P.shape[0],P.shape[1],P.shape[2]]));const u={images:a},s={alignCorners:r,halfPixelCenters:n,size:t},v=Ua.runKernel(yn,u,s);return o?Qv(v,[v.shape[1],v.shape[2],v.shape[3]]):v}const ip=Xa({resizeNearestNeighbor_:vp});
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * https://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function lp(e,t="binary",r=!1,n=.5){const P=Ba(e,"image","threshold"),a=P.shape[0]*P.shape[1];let o,u,s,v,i=Rs(Tj([n]),255);if(xe(3===P.rank,(()=>`Error in threshold: image must be rank 3,but got rank ${P.rank}.`)),xe(3===P.shape[2]||1===P.shape[2],(()=>`Error in threshold: image color channel must be equal to 3 or 1but got ${P.shape[2]}.`)),xe("int32"===P.dtype||"float32"===P.dtype,(()=>`Error in dtype: image dtype must be int32 or float32,but got dtype ${P.dtype}.`)),xe("otsu"===t||"binary"===t,(()=>`Method must be binary or otsu, but was ${t}`)),3===P.shape[2]){[o,u,s]=oj(P,[1,1,1],-1);const e=Rs(o,.2989),t=Rs(u,.587),r=Rs(s,.114);v=Us(Us(e,t),r)}else v=e;if("otsu"===t){i=cp(vi(uu(ID(v),"int32"),$a([]),256),a)}const l=r?zc(v,i):sc(v,i);return uu(Rs(l,255),"int32")}function cp(e,t){let r,n,P,a,o,u,s=Tj([-1]),v=Tj([0]),i=Tj([0]);for(let l=0;l<e.size-1;l++){r=Bv(e,0,l+1),n=Bv(e,l+1),o=Ks(Gl(r),t),u=Ks(Gl(n),t);const c=Gl(Rs(r,iD(0,r.size)));P=Ks(c,Gl(r));const O=rc(n.shape,r.size),D=Us(iD(0,n.size),O),j=Rs(n,D);a=Ks(Gl(j),Gl(n));const h=Wc(P,a),p=Wc(P,a),m=Rs(o,u);i=Rs(Rs(m,h),p);const g=sc(i,v);v=ul(g,i,v),s=ul(g,Tj([l]),s)}return s}const Op=Xa({threshold_:lp});
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Dp(e,t,r="nearest",n="constant",P=0,a){const o=Ba(e,"image","transform","float32"),u=Ba(t,"transforms","transform","float32");xe(4===o.rank,(()=>`Error in transform: image must be rank 4,but got rank ${o.rank}.`)),xe(2===u.rank&&(u.shape[0]===o.shape[0]||1===u.shape[0])&&8===u.shape[1],(()=>"Error in transform: Input transform should be batch x 8 or 1 x 8")),xe(null==a||2===a.length,(()=>`Error in transform: outputShape must be [height, width] or null, but got ${a}.`));const s={image:o,transforms:u},v={interpolation:r,fillMode:n,fillValue:P,outputShape:a};return Ua.runKernel(oP,s,v)}const jp=Xa({transform_:Dp});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function hp(e,t,r){xe(t%1==0,(()=>`bandPart(): numLower must be an integer, got ${t}.`)),xe(r%1==0,(()=>`bandPart(): numUpper must be an integer, got ${r}.`));const n=Ba(e,"a","bandPart");xe(n.rank>=2,(()=>`bandPart(): Rank must be at least 2, got ${n.rank}.`));const P=n.shape,[a,o]=n.shape.slice(-2);if(!(t<=a))throw new Error(`bandPart(): numLower (${t}) must not be greater than the number of rows (${a}).`);if(!(r<=o))throw new Error(`bandPart(): numUpper (${r}) must not be greater than the number of columns (${o}).`);t<0&&(t=a),r<0&&(r=o);const u=Qv(iD(0,a,1,"int32"),[-1,1]),s=iD(0,o,1,"int32"),v=Wc(u,s),i=Nc(zc(v,Cl(+t,"int32")),ic(v,Cl(-r,"int32"))),l=iO([a,o],n.dtype);return Qv(Dj(Ej(Qv(n,[-1,a,o])).map((e=>ul(i,e,l)))),P)}const pp=Xa({bandPart_:hp});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function mp(e){let t;if(Array.isArray(e)){t=!1,xe(null!=e&&e.length>0,(()=>"Gram-Schmidt process: input must not be null, undefined, or empty"));const r=e[0].shape[0];for(let t=1;t<e.length;++t)xe(e[t].shape[0]===r,(()=>`Gram-Schmidt: Non-unique lengths found in the input vectors: (${e[t].shape[0]} vs. ${r})`))}else t=!0,e=oj(e,e.shape[0],0).map((e=>cj(e,[0])));xe(e.length<=e[0].shape[0],(()=>`Gram-Schmidt: Number of vectors (${e.length}) exceeds number of dimensions (${e[0].shape[0]}).`));const r=[],n=e;for(let t=0;t<e.length;++t)r.push(Ua.tidy((()=>{let e=n[t];if(t>0)for(let n=0;n<t;++n){const t=Rs(Gl(Rs(r[n],e)),r[n]);e=Wc(e,t)}return Ks(e,Nl(e,"euclidean"))})));return t?Dj(r,0):r}const gp=Xa({gramSchmidt_:mp});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function bp(e,t=!1){if(xe(e.rank>=2,(()=>`qr() requires input tensor to have a rank >= 2, but got rank ${e.rank}`)),2===e.rank)return Tp(e,t);{const r=e.shape.slice(0,e.shape.length-2).reduce(((e,t)=>e*t)),n=Ej(Qv(e,[r,e.shape[e.shape.length-2],e.shape[e.shape.length-1]]),0),P=[],a=[];n.forEach((e=>{const[r,n]=Tp(e,t);P.push(r),a.push(n)}));return[Qv(Dj(P,0),e.shape),Qv(Dj(a,0),e.shape)]}}function Tp(e,t=!1){return Ua.tidy((()=>{xe(2===e.shape.length,(()=>`qr2d() requires a 2D Tensor, but got a ${e.shape.length}D Tensor.`));const r=e.shape[0],n=e.shape[1];let P=tc(r),a=vu(e);const o=zj([[1]],[1,1]);let u=vu(o);const s=r>=n?n:r;for(let e=0;e<s;++e){const t=a,s=u,v=P;[u,a,P]=Ua.tidy((()=>{const t=Bv(a,[e,e],[r-e,1]),s=Nl(t),v=Bv(a,[e,e],[1,1]),i=ul(sc(v,0),zj([[-1]]),zj([[1]])),l=Wc(v,Rs(i,s)),c=Ks(t,l);u=1===c.shape[0]?vu(o):Kv([o,Bv(c,[1,0],[c.shape[0]-1,c.shape[1]])],0);const O=_u(Ks(Gu(i,l),s)),D=Bv(a,[e,0],[r-e,n]),j=Rs(O,u),h=rs(u);if(0===e)a=Wc(D,Gu(j,Gu(h,D)));else{const t=Wc(D,Gu(j,Gu(h,D)));a=Kv([Bv(a,[0,0],[e,n]),t],0)}const p=rs(j),m=Bv(P,[0,e],[r,P.shape[1]-e]);if(0===e)P=Wc(m,Gu(Gu(m,u),p));else{const t=Wc(m,Gu(Gu(m,u),p));P=Kv([Bv(P,[0,0],[r,e]),t],1)}return[u,a,P]})),Bu([t,s,v])}return!t&&r>n&&(P=Bv(P,[0,0],[r,n]),a=Bv(a,[0,0],[n,n])),[P,a]}))}const zp=Xa({qr_:bp});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */var N;function dp(e,t,r=N.SUM_BY_NONZERO_WEIGHTS){const n=Ba(e,"losses","computeWeightedLoss");let P=null;null!=t&&(P=Ba(t,"weights","computeWeightedLoss"));const a=null==P?n:Rs(n,P);if(r===N.NONE)return a;if(r===N.SUM)return Gl(a);if(r===N.MEAN){if(null==P)return vO(a);{const e=n.size/P.size,t=Ks(Gl(a),Gl(P));return e>1?Ks(t,Cl(e)):t}}if(r===N.SUM_BY_NONZERO_WEIGHTS){if(null==P)return Ks(Gl(a),Cl(n.size));{const e=Rs(P,lO(n.shape)),t=uu(Gl(LO(e,Cl(0))),"float32");return Ks(Gl(a),t)}}throw Error(`Unknown reduction: ${r}`)}!function(e){e[e.NONE=0]="NONE",e[e.MEAN=1]="MEAN",e[e.SUM=2]="SUM",e[e.SUM_BY_NONZERO_WEIGHTS=3]="SUM_BY_NONZERO_WEIGHTS"}(N||(N={}));const yp=Xa({computeWeightedLoss_:dp});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function wp(e,t,r,n=N.SUM_BY_NONZERO_WEIGHTS){const P=Ba(e,"labels","absoluteDifference"),a=Ba(t,"predictions","absoluteDifference");let o=null;null!=r&&(o=Ba(r,"weights","absoluteDifference")),Ye(P.shape,a.shape,"Error in absoluteDifference: ");const u=Bs(Wc(P,a));return yp(u,o,n)}const Lp=Xa({absoluteDifference_:wp});function fp(e,t,r,n,P=N.SUM_BY_NONZERO_WEIGHTS){const a=Ba(e,"labels","cosineDistance"),o=Ba(t,"predictions","cosineDistance");let u=null;null!=n&&(u=Ba(n,"weights","cosineDistance")),Ye(a.shape,o.shape,"Error in cosineDistance: ");const s=Cl(1),v=Wc(s,Gl(Rs(a,o),r,!0));return yp(v,u,P)}const Ip=Xa({cosineDistance_:fp});function Sp(e,t,r,n=N.SUM_BY_NONZERO_WEIGHTS){let P=Ba(e,"labels","hingeLoss");const a=Ba(t,"predictions","hingeLoss");let o=null;null!=r&&(o=Ba(r,"weights","hingeLoss")),Ye(P.shape,a.shape,"Error in hingeLoss: ");const u=Cl(1);P=Wc(Rs(Cl(2),P),u);const s=DD(Wc(u,Rs(P,a)));return yp(s,o,n)}const Ap=Xa({hingeLoss_:Sp});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function xp(e,t,r,n=1,P=N.SUM_BY_NONZERO_WEIGHTS){const a=Ba(e,"labels","huberLoss"),o=Ba(t,"predictions","huberLoss");let u=null;null!=r&&(u=Ba(r,"weights","huberLoss")),Ye(a.shape,o.shape,"Error in huberLoss: ");const s=Cl(n),v=Bs(Wc(o,a)),i=DO(v,s),l=Wc(v,i),c=Us(Rs(Cl(.5),Ul(i)),Rs(s,l));return yp(c,u,P)}const Yp=Xa({huberLoss_:xp});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function kp(e,t,r,n=1e-7,P=N.SUM_BY_NONZERO_WEIGHTS){const a=Ba(e,"labels","logLoss"),o=Ba(t,"predictions","logLoss");let u=null;null!=r&&(u=Ba(r,"weights","logLoss")),Ye(a.shape,o.shape,"Error in logLoss: ");const s=Cl(1),v=Cl(n),i=_u(Rs(a,fc(Us(o,v)))),l=Rs(Wc(s,a),fc(Us(Wc(s,o),v))),c=Wc(i,l);return yp(c,u,P)}const Cp=Xa({logLoss_:kp});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ep(e,t,r,n=N.SUM_BY_NONZERO_WEIGHTS){const P=Ba(e,"labels","meanSquaredError"),a=Ba(t,"predictions","meanSquaredError");let o=null;null!=r&&(o=Ba(r,"weights","meanSquaredError")),Ye(P.shape,a.shape,"Error in meanSquaredError: ");const u=ij(P,a);return yp(u,o,n)}const Qp=Xa({meanSquaredError_:Ep});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Wp(e,t){const r=Ba(e,"labels","sigmoidCrossEntropyWithLogits"),n=Ba(t,"logits","sigmoidCrossEntropyWithLogits");Ye(r.shape,n.shape,"Error in sigmoidCrossEntropyWithLogits: ");const P=DD(n),a=Rs(n,r),o=Sc(Zl(_u(Bs(n))));return Us(Wc(P,a),o)}function Up(e,t,r,n=0,P=N.SUM_BY_NONZERO_WEIGHTS){let a=Ba(e,"multiClassLabels","sigmoidCrossEntropy");const o=Ba(t,"logits","sigmoidCrossEntropy");let u=null;if(null!=r&&(u=Ba(r,"weights","sigmoidCrossEntropy")),Ye(a.shape,o.shape,"Error in sigmoidCrossEntropy: "),n>0){const e=Cl(n),t=Cl(1),r=Cl(.5);a=Us(Rs(a,Wc(t,e)),Rs(r,e))}const s=Wp(a,o);return yp(s,u,P)}const qp=Xa({sigmoidCrossEntropy_:Up});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Gp(e,t,r=-1){if(-1===r&&(r=t.rank-1),r!==t.rank-1)throw Error(`Softmax cross entropy along a non-last dimension is not yet supported. Labels / logits was rank ${t.rank} and dim was ${r}`);const n=xc(((e,t,n)=>{const P=Mc(t,[r],!0),a=Wc(uu(t,"float32"),P);n([e,a]);const o=_u(Rs(a,e));return{value:Gl(o,[r]),gradFunc:(e,t)=>{const[n,P]=t,a=dl(e.shape,[r]);return[Rs(Qv(e,a),Wc(uu(n,"float32"),Zl(P))),Rs(Qv(e,a),Wc(Zl(P),uu(n,"float32")))]}}}));return n(e,t)}function Mp(e,t,r,n=0,P=N.SUM_BY_NONZERO_WEIGHTS){let a=Ba(e,"onehotLabels","softmaxCrossEntropy");const o=Ba(t,"logits","softmaxCrossEntropy");let u=null;if(null!=r&&(u=Ba(r,"weights","softmaxCrossEntropy")),Ye(a.shape,o.shape,"Error in softmaxCrossEntropy: "),n>0){const e=Cl(n),t=Cl(1),r=Cl(a.shape[1]);a=Us(Rs(a,Wc(t,e)),Ks(e,r))}const s=Gp(a,o);return yp(s,u,P)}const Kp=Xa({softmaxCrossEntropy_:Mp});
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Np(e,t,r,n){const P=Ba(e,"indices","sparseFillEmptyRows","int32"),a=Ba(t,"values","sparseFillEmptyRows"),o=Ba(r,"denseShape","sparseFillEmptyRows","int32"),u=Ba(n,"defaultValue","sparseFillEmptyRows",a.dtype);if(2!==P.rank)throw new Error(`Indices should be Tensor2D but received shape\n        ${P.shape}`);if(1!==a.rank)throw new Error(`Values should be Tensor1D but received shape ${a.shape}`);if(1!==o.rank)throw new Error(`Dense shape should be Tensor1D but received shape ${o.shape}`);if(0!==u.rank)throw new Error(`Default value should be a scalar but received shape ${u.shape}`);const s={indices:P,values:a,denseShape:o,defaultValue:u},v=Ua.runKernel(Fn,s);return{outputIndices:v[0],outputValues:v[1],emptyRowIndicator:v[2],reverseIndexMap:v[3]}}const Rp=Xa({sparseFillEmptyRows_:Np});
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Fp(e,t,r){const n=Ba(e,"inputIndices","sparseReshape","int32"),P=Ba(t,"inputShape","sparseReshape","int32"),a=Ba(r,"newShape","sparseReshape","int32");if(2!==n.rank)throw new Error(`Input indices should be Tensor2D but received shape\n        ${n.shape}`);if(1!==P.rank)throw new Error(`Input shape should be Tensor1D but received shape ${P.shape}`);if(1!==a.rank)throw new Error(`New shape should be Tensor1D but received shape ${a.shape}`);const o={inputIndices:n,inputShape:P,newShape:a},u=Ua.runKernel(Bn,o);return{outputIndices:u[0],outputShape:u[1]}}const Bp=Xa({sparseReshape_:Fp});
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Zp(e,t,r){const n=Ba(e,"data","sparseSegmentMean"),P=Ba(t,"indices","sparseSegmentMean","int32"),a=Ba(r,"segmentIds","sparseSegmentMean","int32");if(n.rank<1)throw new Error("Data should be at least 1 dimensional but received scalar");if(1!==P.rank)throw new Error(`Indices should be Tensor1D but received shape\n          ${P.shape}`);if(1!==a.rank)throw new Error(`Segment ids should be Tensor1D but received shape\n          ${a.shape}`);const o={data:n,indices:P,segmentIds:a};return Ua.runKernel(Zn,o)}const Vp=Xa({sparseSegmentMean_:Zp});
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Xp(e,t,r){const n=Ba(e,"data","sparseSegmentSum"),P=Ba(t,"indices","sparseSegmentSum","int32"),a=Ba(r,"segmentIds","sparseSegmentSum","int32");if(n.rank<1)throw new Error("Data should be at least 1 dimensional but received scalar");if(1!==P.rank)throw new Error(`Indices should be Tensor1D but received shape\n         ${P.shape}`);if(1!==a.rank)throw new Error(`Segment ids should be Tensor1D but received shape\n         ${a.shape}`);const o={data:n,indices:P,segmentIds:a};return Ua.runKernel(Vn,o)}const Hp=Xa({sparseSegmentSum_:Xp});
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Jp(e,t,r,n,P,a,o,u){const s=Ba(e,"data","stringNGrams","string");if("string"!==s.dtype)throw new Error("Data must be of datatype string");if(1!==s.shape.length)throw new Error(`Data must be a vector, saw: ${s.shape}`);const v=Ba(t,"dataSplits","stringNGrams");if("int32"!==v.dtype)throw new Error("Data splits must be of datatype int32");const i={separator:r,nGramWidths:n,leftPad:P,rightPad:a,padWidth:o,preserveShortSequences:u},l={data:s,dataSplits:v},c=Ua.runKernel(_n,l,i);return{nGrams:c[0],nGramsSplits:c[1]}}const _p=Xa({stringNGrams_:Jp});
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function $p(e,t,r=!0){const n=Ba(e,"input","stringSplit","string"),P=Ba(t,"delimiter","stringSplit","string");if(1!==n.rank)throw new Error(`Input should be Tensor1D but received shape ${n.shape}`);if(0!==P.rank)throw new Error(`Delimiter should be a scalar but received shape ${P.shape}`);const a={skipEmpty:r},o={input:n,delimiter:P},u=Ua.runKernel($n,o,a);return{indices:u[0],values:u[1],shape:u[2]}}const em=Xa({stringSplit_:$p});
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function tm(e,t){const r=Ba(e,"input","stringToHashBucketFast","string"),n={numBuckets:t};if(t<=0)throw new Error("Number of buckets must be at least 1");const P={input:r};return Ua.runKernel(eP,P,n)}const rm=Xa({stringToHashBucketFast_:tm}),nm={fft:ej,ifft:rj,rfft:sj,irfft:Pj},Pm={hammingWindow:zh,hannWindow:yh,frame:Lh,stft:Ih},am={flipLeftRight:Yh,grayscaleToRGB:Ch,resizeNearestNeighbor:ip,resizeBilinear:sp,rotateWithOffset:Qh,cropAndResize:Ah,nonMaxSuppression:qh,nonMaxSuppressionAsync:_h,nonMaxSuppressionWithScore:ep,nonMaxSuppressionWithScoreAsync:rp,nonMaxSuppressionPadded:Pp,nonMaxSuppressionPaddedAsync:op,threshold:Op,transform:jp},om={bandPart:pp,gramSchmidt:gp,qr:zp},um={absoluteDifference:Lp,computeWeightedLoss:yp,cosineDistance:Ip,hingeLoss:Ap,huberLoss:Yp,logLoss:Cp,meanSquaredError:Qp,sigmoidCrossEntropy:qp,softmaxCrossEntropy:Kp},sm={sparseFillEmptyRows:Rp,sparseReshape:Bp,sparseSegmentMean:Vp,sparseSegmentSum:Hp},vm={stringNGrams:_p,stringSplit:em,stringToHashBucketFast:rm};
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
class im extends Cs{minimize(e,t=!1,r){const{value:n,grads:P}=this.computeGradients(e,r);if(null!=r){const e=r.map((e=>({name:e.name,tensor:P[e.name]})));this.applyGradients(e)}else this.applyGradients(P);return Bu(P),t?n:(n.dispose(),null)}get iterations(){return null==this.iterations_&&(this.iterations_=0),this.iterations_}incrementIterations(){this.iterations_=this.iterations+1}computeGradients(e,t){return Ac(e,t)}dispose(){null!=this.iterations_&&Bu(this.iterations_)}async saveIterations(){return null==this.iterations_&&(this.iterations_=0),{name:"iter",tensor:Cl(this.iterations_,"int32")}}async getWeights(){throw new Error("getWeights() is not implemented for this optimizer yet.")}async setWeights(e){throw new Error(`setWeights() is not implemented for this optimizer class ${this.getClassName()}`)}async extractIterations(e){return this.iterations_=(await e[0].tensor.data())[0],e.slice(1)}}Object.defineProperty(im,Symbol.hasInstance,{value:e=>null!=e.minimize&&null!=e.computeGradients&&null!=e.applyGradients});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
class lm extends im{constructor(e,t,r=null){super(),this.learningRate=e,this.rho=t,this.epsilon=r,this.accumulatedGrads=[],this.accumulatedUpdates=[],null==r&&(this.epsilon=Ua.backend.epsilon())}applyGradients(e){(Array.isArray(e)?e.map((e=>e.name)):Object.keys(e)).forEach(((t,r)=>{const n=Ua.registeredVariables[t];null==this.accumulatedGrads[r]&&(this.accumulatedGrads[r]={originalName:`${t}/accum_grad`,variable:Fu((()=>vl(n).variable(false)))}),null==this.accumulatedUpdates[r]&&(this.accumulatedUpdates[r]={originalName:`${t}/accum_var`,variable:Fu((()=>vl(n).variable(false)))});const P=Array.isArray(e)?e[r].tensor:e[t];if(null==P)return;const a=this.accumulatedGrads[r].variable,o=this.accumulatedUpdates[r].variable;Fu((()=>{const e=Us(Rs(a,this.rho),Rs(Ul(P),1-this.rho)),t=Rs(Ks(Ql(Us(o,this.epsilon)),Ql(Us(a,this.epsilon))),P),r=Us(Rs(o,this.rho),Rs(Ul(t),1-this.rho));a.assign(e),o.assign(r);const u=Us(Rs(t,-this.learningRate),n);n.assign(u)}))})),this.incrementIterations()}dispose(){null!=this.accumulatedUpdates&&(Bu(this.accumulatedGrads.map((e=>e.variable))),Bu(this.accumulatedUpdates.map((e=>e.variable))))}async getWeights(){const e=[...this.accumulatedGrads,...this.accumulatedUpdates];return[await this.saveIterations()].concat(e.map((e=>({name:e.originalName,tensor:e.variable}))))}async setWeights(e){const t=(e=await this.extractIterations(e)).length/2;this.accumulatedGrads=e.slice(0,t).map((e=>({originalName:e.name,variable:e.tensor.variable(false)}))),this.accumulatedUpdates=e.slice(t,2*t).map((e=>({originalName:e.name,variable:e.tensor.variable(false)})))}getConfig(){return{learningRate:this.learningRate,rho:this.rho,epsilon:this.epsilon}}static fromConfig(e,t){return new e(t.learningRate,t.rho,t.epsilon)}}lm.className="Adadelta",Qs(lm);
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
class cm extends im{constructor(e,t=.1){super(),this.learningRate=e,this.initialAccumulatorValue=t,this.accumulatedGrads=[]}applyGradients(e){(Array.isArray(e)?e.map((e=>e.name)):Object.keys(e)).forEach(((t,r)=>{const n=Ua.registeredVariables[t];if(null==this.accumulatedGrads[r]){const e=!1;this.accumulatedGrads[r]={originalName:`${t}/accumulator`,variable:Fu((()=>rc(n.shape,this.initialAccumulatorValue).variable(e)))}}const P=Array.isArray(e)?e[r].tensor:e[t];if(null==P)return;const a=this.accumulatedGrads[r].variable;Fu((()=>{const e=Us(a,Ul(P));a.assign(e);const t=Us(Rs(Ks(P,Ql(Us(e,Ua.backend.epsilon()))),-this.learningRate),n);n.assign(t)}))})),this.incrementIterations()}dispose(){null!=this.accumulatedGrads&&Bu(this.accumulatedGrads.map((e=>e.variable)))}async getWeights(){return[await this.saveIterations()].concat(this.accumulatedGrads.map((e=>({name:e.originalName,tensor:e.variable}))))}async setWeights(e){e=await this.extractIterations(e);this.accumulatedGrads=e.map((e=>({originalName:e.name,variable:e.tensor.variable(false)})))}getConfig(){return{learningRate:this.learningRate,initialAccumulatorValue:this.initialAccumulatorValue}}static fromConfig(e,t){return new e(t.learningRate,t.initialAccumulatorValue)}}cm.className="Adagrad",Qs(cm);
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
class Om extends im{constructor(e,t,r,n=null){super(),this.learningRate=e,this.beta1=t,this.beta2=r,this.epsilon=n,this.accumulatedFirstMoment=[],this.accumulatedSecondMoment=[],Fu((()=>{this.accBeta1=Cl(t).variable(),this.accBeta2=Cl(r).variable()})),null==n&&(this.epsilon=Ua.backend.epsilon())}applyGradients(e){const t=Array.isArray(e)?e.map((e=>e.name)):Object.keys(e);Fu((()=>{const r=Wc(1,this.accBeta1),n=Wc(1,this.accBeta2);t.forEach(((t,P)=>{const a=Ua.registeredVariables[t];null==this.accumulatedFirstMoment[P]&&(this.accumulatedFirstMoment[P]={originalName:`${t}/m`,variable:Fu((()=>vl(a).variable(false)))}),null==this.accumulatedSecondMoment[P]&&(this.accumulatedSecondMoment[P]={originalName:`${t}/v`,variable:Fu((()=>vl(a).variable(false)))});const o=Array.isArray(e)?e[P].tensor:e[t];if(null==o)return;const u=this.accumulatedFirstMoment[P].variable,s=this.accumulatedSecondMoment[P].variable,v=Us(Rs(u,this.beta1),Rs(o,1-this.beta1)),i=Us(Rs(s,this.beta2),Rs(Ul(o),1-this.beta2)),l=Ks(v,r),c=Ks(i,n);u.assign(v),s.assign(i);const O=Us(Rs(Ks(l,Us(Ql(c),this.epsilon)),-this.learningRate),a);a.assign(O)})),this.accBeta1.assign(Rs(this.accBeta1,this.beta1)),this.accBeta2.assign(Rs(this.accBeta2,this.beta2))})),this.incrementIterations()}dispose(){this.accBeta1.dispose(),this.accBeta2.dispose(),null!=this.accumulatedFirstMoment&&Bu(this.accumulatedFirstMoment.map((e=>e.variable))),null!=this.accumulatedSecondMoment&&Bu(this.accumulatedSecondMoment.map((e=>e.variable)))}async getWeights(){const e=[...this.accumulatedFirstMoment,...this.accumulatedSecondMoment];return[await this.saveIterations()].concat(e.map((e=>({name:e.originalName,tensor:e.variable}))))}async setWeights(e){e=await this.extractIterations(e),Fu((()=>{this.accBeta1.assign(kl(this.beta1,this.iterations_+1)),this.accBeta2.assign(kl(this.beta2,this.iterations_+1))}));const t=e.length/2;this.accumulatedFirstMoment=e.slice(0,t).map((e=>({originalName:e.name,variable:e.tensor.variable(false)}))),this.accumulatedSecondMoment=e.slice(t,2*t).map((e=>({originalName:e.name,variable:e.tensor.variable(false)})))}getConfig(){return{learningRate:this.learningRate,beta1:this.beta1,beta2:this.beta2,epsilon:this.epsilon}}static fromConfig(e,t){return new e(t.learningRate,t.beta1,t.beta2,t.epsilon)}}Om.className="Adam",Qs(Om);
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
class Dm extends im{constructor(e,t,r,n=null,P=0){super(),this.learningRate=e,this.beta1=t,this.beta2=r,this.epsilon=n,this.decay=P,this.accumulatedFirstMoment=[],this.accumulatedWeightedInfNorm=[],Fu((()=>{this.iteration=Cl(0).variable(),this.accBeta1=Cl(t).variable()})),null==n&&(this.epsilon=Ua.backend.epsilon())}applyGradients(e){const t=Array.isArray(e)?e.map((e=>e.name)):Object.keys(e);Fu((()=>{const r=Wc(1,this.accBeta1),n=Ks(-this.learningRate,Us(Rs(this.iteration,this.decay),1));t.forEach(((t,P)=>{const a=Ua.registeredVariables[t];null==this.accumulatedFirstMoment[P]&&(this.accumulatedFirstMoment[P]={originalName:`${t}/m`,variable:vl(a).variable(false)}),null==this.accumulatedWeightedInfNorm[P]&&(this.accumulatedWeightedInfNorm[P]={originalName:`${t}/v`,variable:vl(a).variable(false)});const o=Array.isArray(e)?e[P].tensor:e[t];if(null==o)return;const u=this.accumulatedFirstMoment[P].variable,s=this.accumulatedWeightedInfNorm[P].variable,v=Us(Rs(u,this.beta1),Rs(o,1-this.beta1)),i=Rs(s,this.beta2),l=Bs(o),c=uO(i,l);u.assign(v),s.assign(c);const O=Us(Rs(Ks(n,r),Ks(v,Us(c,this.epsilon))),a);a.assign(O)})),this.iteration.assign(Us(this.iteration,1)),this.accBeta1.assign(Rs(this.accBeta1,this.beta1))})),this.incrementIterations()}dispose(){this.accBeta1.dispose(),this.iteration.dispose(),null!=this.accumulatedFirstMoment&&Bu(this.accumulatedFirstMoment.map((e=>e.variable))),null!=this.accumulatedWeightedInfNorm&&Bu(this.accumulatedWeightedInfNorm.map((e=>e.variable)))}async getWeights(){throw new Error("getWeights() is not implemented for Adamax yet.")}async setWeights(e){throw new Error("setWeights() is not implemented for Adamax yet.")}getConfig(){return{learningRate:this.learningRate,beta1:this.beta1,beta2:this.beta2,epsilon:this.epsilon,decay:this.decay}}static fromConfig(e,t){return new e(t.learningRate,t.beta1,t.beta2,t.epsilon,t.decay)}}Dm.className="Adamax",Qs(Dm);
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
class jm extends im{constructor(e){super(),this.learningRate=e,this.setLearningRate(e)}applyGradients(e){(Array.isArray(e)?e.map((e=>e.name)):Object.keys(e)).forEach(((t,r)=>{const n=Array.isArray(e)?e[r].tensor:e[t];if(null==n)return;const P=Ua.registeredVariables[t];Fu((()=>{const e=Us(Rs(this.c,n),P);P.assign(e)}))})),this.incrementIterations()}setLearningRate(e){this.learningRate=e,null!=this.c&&this.c.dispose(),this.c=Zu(Cl(-e))}dispose(){this.c.dispose()}async getWeights(){return[await this.saveIterations()]}async setWeights(e){if(0!==(e=await this.extractIterations(e)).length)throw new Error("SGD optimizer does not have settable weights.")}getConfig(){return{learningRate:this.learningRate}}static fromConfig(e,t){return new e(t.learningRate)}}jm.className="SGD",Qs(jm);
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
class hm extends jm{constructor(e,t,r=!1){super(e),this.learningRate=e,this.momentum=t,this.useNesterov=r,this.accumulations=[],this.m=Cl(this.momentum)}applyGradients(e){(Array.isArray(e)?e.map((e=>e.name)):Object.keys(e)).forEach(((t,r)=>{const n=Ua.registeredVariables[t];if(null==this.accumulations[r]){const e=!1;this.accumulations[r]={originalName:`${t}/momentum`,variable:Fu((()=>vl(n).variable(e)))}}const P=this.accumulations[r].variable,a=Array.isArray(e)?e[r].tensor:e[t];null!=a&&Fu((()=>{let e;const t=Us(Rs(this.m,P),a);e=this.useNesterov?Us(Rs(this.c,Us(a,Rs(t,this.m))),n):Us(Rs(this.c,t),n),P.assign(t),n.assign(e)}))})),this.incrementIterations()}dispose(){this.m.dispose(),null!=this.accumulations&&Bu(this.accumulations.map((e=>e.variable)))}setMomentum(e){this.momentum=e}async getWeights(){return[await this.saveIterations()].concat(this.accumulations.map((e=>({name:e.originalName,tensor:e.variable}))))}async setWeights(e){e=await this.extractIterations(e);this.accumulations=e.map((e=>({originalName:e.name,variable:e.tensor.variable(false)})))}getConfig(){return{learningRate:this.learningRate,momentum:this.momentum,useNesterov:this.useNesterov}}static fromConfig(e,t){return new e(t.learningRate,t.momentum,t.useNesterov)}}hm.className="Momentum",Qs(hm);
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
class pm extends im{constructor(e,t=.9,r=0,n=null,P=!1){if(super(),this.learningRate=e,this.decay=t,this.momentum=r,this.epsilon=n,this.accumulatedMeanSquares=[],this.accumulatedMoments=[],this.accumulatedMeanGrads=[],this.centered=P,null==n&&(this.epsilon=Ua.backend.epsilon()),null==e)throw new Error("learningRate for RMSPropOptimizer must be defined.")}applyGradients(e){(Array.isArray(e)?e.map((e=>e.name)):Object.keys(e)).forEach(((t,r)=>{const n=Ua.registeredVariables[t],P=!1;null==this.accumulatedMeanSquares[r]&&(this.accumulatedMeanSquares[r]={originalName:`${t}/rms`,variable:Fu((()=>vl(n).variable(P)))}),null==this.accumulatedMoments[r]&&(this.accumulatedMoments[r]={originalName:`${t}/momentum`,variable:Fu((()=>vl(n).variable(P)))}),null==this.accumulatedMeanGrads[r]&&this.centered&&(this.accumulatedMeanGrads[r]={originalName:`${t}/mg`,variable:Fu((()=>vl(n).variable(P)))});const a=Array.isArray(e)?e[r].tensor:e[t];if(null==a)return;const o=this.accumulatedMeanSquares[r].variable,u=this.accumulatedMoments[r].variable;Fu((()=>{const e=Us(Rs(o,this.decay),Rs(Ul(a),1-this.decay));if(this.centered){const t=this.accumulatedMeanGrads[r].variable,P=Us(Rs(t,this.decay),Rs(a,1-this.decay)),s=Ks(Rs(a,this.learningRate),Ql(Wc(e,Us(Ul(P),this.epsilon)))),v=Us(Rs(u,this.momentum),s);o.assign(e),t.assign(P),u.assign(v);const i=Wc(n,v);n.assign(i)}else{const e=Us(Rs(o,this.decay),Rs(Ul(a),1-this.decay)),t=Us(Rs(u,this.momentum),Ks(Rs(a,this.learningRate),Ql(Us(e,this.epsilon))));o.assign(e),u.assign(t);const r=Wc(n,t);n.assign(r)}}))})),this.incrementIterations()}dispose(){null!=this.accumulatedMeanSquares&&Bu(this.accumulatedMeanSquares.map((e=>e.variable))),null!=this.accumulatedMeanGrads&&this.centered&&Bu(this.accumulatedMeanGrads.map((e=>e.variable))),null!=this.accumulatedMoments&&Bu(this.accumulatedMoments.map((e=>e.variable)))}async getWeights(){const e=[...this.accumulatedMeanSquares,...this.accumulatedMoments];return this.centered&&e.push(...this.accumulatedMeanGrads),[await this.saveIterations()].concat(e.map((e=>({name:e.originalName,tensor:e.variable}))))}async setWeights(e){e=await this.extractIterations(e);const t=this.centered?e.length/3:e.length/2,r=!1;this.accumulatedMeanSquares=e.slice(0,t).map((e=>({originalName:e.name,variable:e.tensor.variable(r)}))),this.accumulatedMoments=e.slice(t,2*t).map((e=>({originalName:e.name,variable:e.tensor.variable(r)}))),this.centered&&(this.accumulatedMeanGrads=e.slice(2*t,3*t).map((e=>({originalName:e.name,variable:e.tensor.variable(r)}))))}getConfig(){return{learningRate:this.learningRate,decay:this.decay,momentum:this.momentum,epsilon:this.epsilon,centered:this.centered}}static fromConfig(e,t){return new e(t.learningRate,t.decay,t.momentum,t.epsilon,t.centered)}}pm.className="RMSProp",Qs(pm);
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
const mm="undefined"!=typeof requestAnimationFrame?requestAnimationFrame:"undefined"!=typeof setImmediate?setImmediate:e=>e();
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function gm(e,t){const r=e[0].length;e.forEach(((e,t)=>{xe(e.length===r,(()=>`Error in concat${r}D: rank of tensors[${t}] must be the same as the rank of the rest (${r})`))})),xe(t>=0&&t<r,(()=>`Error in concat${r}D: axis must be between 0 and ${r-1}.`));const n=e[0];e.forEach(((e,P)=>{for(let a=0;a<r;a++)xe(a===t||e[a]===n[a],(()=>`Error in concat${r}D: Shape of tensors[${P}] (${e}) does not match the shape of the rest (${n}) along the non-concatenated axis ${P}.`))}))}function bm(e,t){const r=e[0].slice();for(let n=1;n<e.length;n++)r[t]+=e[n][t];return r}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Tm=30;function zm(e){return e<=Tm?e:nt(e,Math.floor(Math.sqrt(e)))}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function dm(e,t,r){return[r*("number"==typeof e?e:e[0]),t*("number"==typeof e?e:e[1])]}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ym(e,t,r,n=!0){let P=[];if(n)P=P.concat(t.slice(0)),P.push(e[0]/r),P=P.concat(e.slice(1));else{P=P.concat(e[0]);const r=t.length;for(let n=0;n<r;++n)P=P.concat([e[n+1]/t[n],t[n]]);P=P.concat(e.slice(r+1))}return P}function wm(e,t,r=!0){const n=[];if(r){n.push(t);for(let r=t+1;r<e;++r)r<=2*t?(n.push(r),n.push(r-(t+1))):n.push(r)}else{const r=[],P=[];for(let n=1;n<e;++n)n>=2*t+1||n%2==1?P.push(n):r.push(n);n.push(...r),n.push(0),n.push(...P)}return n}function Lm(e,t,r,n=!0){const P=[];n?P.push(e[0]/r):P.push(e[0]*r);for(let r=1;r<e.length;++r)r<=t.length?n?P.push(t[r-1]*e[r]):P.push(e[r]/t[r-1]):P.push(e[r]);return P}function fm(e,t){const r=[0];for(let n=0;n<t;++n)r.push(e[n][0]);return r}function Im(e,t,r){const n=e.slice(0,1);for(let P=0;P<r;++P)n.push(e[P+1]-t[P][0]-t[P][1]);return n}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Sm=1.7580993408473768,Am=1.0507009873554805,xm=.3275911,Ym=.254829592,km=-.284496736,Cm=1.421413741,Em=-1.453152027,Qm=1.061405429;
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function Wm(e,t){if(e.length!==t.length)throw new Error(`Cannot merge real and imag arrays of different lengths. real:${e.length}, imag: ${t.length}.`);const r=new Float32Array(2*e.length);for(let n=0;n<r.length;n+=2)r[n]=e[n/2],r[n+1]=t[n/2];return r}function Um(e){const t=new Float32Array(e.length/2),r=new Float32Array(e.length/2);for(let n=0;n<e.length;n+=2)t[n/2]=e[n],r[n/2]=e[n+1];return{real:t,imag:r}}function qm(e){const t=Math.ceil(e.length/4),r=new Float32Array(t),n=new Float32Array(t);for(let t=0;t<e.length;t+=4)r[Math.floor(t/4)]=e[t],n[Math.floor(t/4)]=e[t+1];return{real:r,imag:n}}function Gm(e){const t=Math.floor(e.length/4),r=new Float32Array(t),n=new Float32Array(t);for(let t=2;t<e.length;t+=4)r[Math.floor(t/4)]=e[t],n[Math.floor(t/4)]=e[t+1];return{real:r,imag:n}}function Mm(e,t){return{real:e[2*t],imag:e[2*t+1]}}function Km(e,t,r,n){e[2*n]=t,e[2*n+1]=r}function Nm(e,t){const r=new Float32Array(e/2),n=new Float32Array(e/2);for(let P=0;P<Math.ceil(e/2);P++){const a=(t?2:-2)*Math.PI*(P/e);r[P]=Math.cos(a),n[P]=Math.sin(a)}return{real:r,imag:n}}function Rm(e,t,r){const n=(r?2:-2)*Math.PI*(e/t);return{real:Math.cos(n),imag:Math.sin(n)}}
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Fm="->",Bm=/->/g,Zm=",",Vm="...";function Xm(e,t){const r=((e=e.replace(/\s/g,"")).length-e.replace(Bm,"").length)/Fm.length;if(r<1)throw new Error("Equations without an arrow are not supported.");if(r>1)throw new Error(`Equation must contain exactly one arrow ("${Fm}").`);const[n,P]=e.split(Fm);xe(-1===n.indexOf(Vm),(()=>`The ellipsis notation ("${Vm}") is not supported yet.`));const a=n.split(Zm),o=a.length;if(t!==o)throw new Error(`Expected ${o} input tensors, received ${t}`);if(o>2)throw new Error("Support for more than 2 input tensors is not implemented yet.");const u=[];for(let e=0;e<P.length;++e){const t=P[e];if(!a.some((e=>-1!==e.indexOf(t))))throw new Error(`Output subscripts contain the label ${t} not present in the input subscripts.`);-1===u.indexOf(t)&&u.push(t)}for(let e=0;e<n.length;++e){const t=n[e];-1===u.indexOf(t)&&t!==Zm&&u.push(t)}const s=new Array(a.length);for(let e=0;e<o;++e){if(new Set(a[e].split("")).size!==a[e].length)throw new Error(`Found duplicate axes in input component ${a[e]}. Support for duplicate axes in input is not implemented yet.`);s[e]=[];for(let t=0;t<a[e].length;++t)s[e].push(u.indexOf(a[e][t]))}const v=u.length,i=[];for(let e=P.length;e<v;++e)i.push(e);return{allDims:u,summedDims:i,idDims:s}}function Hm(e,t){let r=new Array(e);r.fill(-1);for(let e=0;e<t.length;++e)r[t[e]]=e;const n=[];for(let t=0;t<e;++t)-1===r[t]&&n.push(t);return r=r.filter((e=>-1!==e)),{permutationIndices:r,expandDims:n}}function Jm(e,t,r){const n=new Array(e);for(let e=0;e<r.length;++e){const P=r[e].shape;for(let r=0;r<t[e].length;++r)void 0===n[t[e][r]]?n[t[e][r]]=P[r]:xe(n[t[e][r]]===P[r],(()=>`Expected dimension ${n[t[e][r]]} at axis ${r} of input shaped ${JSON.stringify(P)}, but got dimension ${P[r]}`))}}function _m(e,t){const r=e,n=[];let P=0;0===e.length&&r.push(-1),P=e.length+1;for(let e=0;e<P;++e)n.push([]);const a=[];for(let e=0;e<r.length;++e){const P=eg(t,r[e]);for(const t of P)-1===a.indexOf(t)&&(n[e].push(t),a.push(t))}return{path:r,steps:n}}function $m(e){return e.every(((e,t)=>e===t))}function eg(e,t){const r=[];for(let n=0;n<e.length;++n)0!==e[n].length&&-1===e[n].indexOf(t)&&-1!==t||r.push(n);return r}function tg(e,t,r=0){let n=[];if("number"==typeof t)xe(e.shape[r]%t==0,(()=>"Number of splits must evenly divide the axis.")),n=new Array(t).fill(e.shape[r]/t);else{const P=t.reduce(((e,t)=>(-1===t&&(e+=1),e)),0);xe(P<=1,(()=>"There should be only one negative value in split array."));const a=t.indexOf(-1);if(-1!==a){const n=t.reduce(((e,t)=>t>0?e+t:e));t[a]=e.shape[r]-n}xe(e.shape[r]===t.reduce(((e,t)=>e+t)),(()=>"The sum of sizes must match the size of the axis dimension.")),n=t}return n}
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function rg(e){return`Received SparseTensor with denseShape[0] = 0 but\n  indices.shape[0] = ${e}`}function ng(e,t){return`indices(${e}, 0) is invalid: ${t} < 0`}function Pg(e,t,r){return`indices(${e}, 0) is invalid: ${t} >= ${r}`
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */}function ag(e,t){return`only one output dimension may be -1, not both ${e} and ${t}`}function og(e,t){return`size ${e} must be non-negative, not ${t}`}function ug(){return"reshape cannot infer the missing input size for an empty tensor unless all specified input sizes are non-zero"}function sg(e,t){return`Input to reshape is a SparseTensor with ${Ee(e)}\n  dense values, but the requested shape requires a multiple of ${Ee(t)}. inputShape=${e} outputShape= ${t}`}function vg(e,t){return`Input to reshape is a tensor with ${Ee(e)} dense values, but the requested shape has ${Ee(t)}. inputShape=${e} outputShape=${t}`
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */}function ig(){return"segment ids must be >= 0"}function lg(){return"segment ids are not increasing"}function cg(e,t){return`Segment id ${e} out of range [0, ${t}), possibly because segmentIds input is not sorted.`}function Og(e,t,r){return`Bad: indices[${e}] == ${t} out of range [0, ${r})`
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */}function Dg(e,t){let r,n=!1;for(e<=Tm?(r=e,n=!0):r=nt(e,Math.floor(Math.sqrt(e)));!n;)r>t||r===e?n=!0:r=nt(e,r+1);return r}function jg(e,t,r){const n=[],P=e.length;for(let a=0;a<P;a++)a!==t?n.push(e[a]):n.push(r);return n}function hg(e,t,r,n){const P=t.shape.length,a=e.shape.length;if(0!==n&&(n<-P||n>P))throw new Error(`Expect batchDims in the range of [-${P}, ${P}], but got ${n}`);if(n<0&&(n+=P),n>a)throw new Error(`batchDims (${n}) must be less than rank(x) (\n    ${a}).`);if(r<n)throw new Error(`batchDims (${n}) must be less than or equal to axis (${r}).`);for(let r=0;r<n;++r)if(e.shape[r]!==t.shape[r])throw new Error(`x.shape[${r}]: ${e.shape[r]} should be equal to indices.shape[${r}]: ${t.shape[r]}.`);const o=e.shape[r],u=[];let s=1,v=1,i=1;for(let t=0;t<n;++t)u.push(e.shape[t]),s*=e.shape[t];for(let t=n;t<r;t++)u.push(e.shape[t]),v*=e.shape[t];for(let e=n;e<P;e++)u.push(t.shape[e]);for(let t=r+1;t<a;t++)u.push(e.shape[t]),i*=e.shape[t];return{batchSize:s,sliceSize:i,outerSize:v,dimSize:o,outputShape:u}}var R=Object.freeze({__proto__:null,segOpComputeOptimalWindowSize:Dg,computeOutShape:jg,collectGatherOpShapeInfo:hg});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function pg(e){try{return e.map((e=>ra(e)))}catch(e){throw new Error(`Failed to decode encoded string bytes into utf-8, error: ${e}`)}}function mg(e){return e.map((e=>ta(e)))}var F=Object.freeze({__proto__:null,slice_util:L,segment_util:R,fromUint8ToStringArray:pg,fromStringArrayToUint8:mg,upcastType:La,axesAreInnerMostDims:bl,combineLocations:Tl,computeOutAndReduceShapes:zl,expandShapeToKeepDim:dl,assertAxesAreInnerMostDims:yl,getAxesPermutation:wl,getUndoAxesPermutation:Ll,getInnerMostAxes:fl,getBroadcastDims:Ps,getReductionAxes:as,assertAndGetBroadcastShape:os,assertParamsConsistent:gm,computeOutShape:bm,computeDilation2DInfo:pv,computePool2DInfo:mv,computePool3DInfo:gv,computeConv2DInfo:bv,computeConv3DInfo:Tv,computeDefaultPad:yv,tupleValuesAreOne:xv,eitherStridesOrDilationsAreOne:Yv,convertConv2DDataFormat:kv,checkPadOnDimRoundingMode:Cv,getFusedDyActivation:uh,getFusedBiasGradient:sh,applyActivation:vh,shouldFuse:ih,PARALLELIZE_THRESHOLD:Tm,computeOptimalWindowSize:zm,getImageCenter:dm,getReshaped:ym,getPermuted:wm,getReshapedPermuted:Lm,getSliceBeginCoords:fm,getSliceSize:Im,prepareAndValidate:is,validateUpdateShape:ls,validateInput:cs,calculateShapes:Os,SELU_SCALEALPHA:Sm,SELU_SCALE:Am,ERF_P:xm,ERF_A1:Ym,ERF_A2:km,ERF_A3:Cm,ERF_A4:Em,ERF_A5:Qm,warn:mP,log:gP,mergeRealAndImagArrays:Wm,splitRealAndImagArrays:Um,complexWithEvenIndex:qm,complexWithOddIndex:Gm,getComplexWithIndex:Mm,assignToTypedArray:Km,exponents:Nm,exponent:Rm,decodeEinsumEquation:Xm,getEinsumPermutation:Hm,checkEinsumDimSizes:Jm,getEinsumComputePath:_m,isIdentityPermutation:$m,prepareSplitSize:tg,getSparseFillEmptyRowsIndicesDenseShapeMismatch:rg,getSparseFillEmptyRowsNegativeIndexErrorMessage:ng,getSparseFillEmptyRowsOutOfRangeIndexErrorMessage:Pg,getSparseReshapeMultipleNegativeOneOutputDimErrorMessage:ag,getSparseReshapeNegativeOutputDimErrorMessage:og,getSparseReshapeEmptyTensorZeroOutputDimErrorMessage:ug,getSparseReshapeInputOutputMultipleErrorMessage:sg,getSparseReshapeInputOutputMismatchErrorMessage:vg,getSparseSegmentReductionNegativeSegmentIdsErrorMessage:ig,getSparseSegmentReductionNonIncreasingSegmentIdsErrorMessage:lg,getSparseSegmentReductionSegmentIdOutOfRangeErrorMessage:cg,getSparseSegmentReductionIndicesOutOfRangeErrorMessage:Og});
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     *
     * =============================================================================
     */
var B,Z;mt().registerFlag("KEEP_INTERMEDIATE_TENSORS",(()=>!1),(e=>{e&&console.warn("Keep intermediate tensors is ON. This will print the values of all intermediate tensors during model inference. Not all models support this mode. For details, check e2e/benchmarks/ model_config.js. This significantly impacts performance.")})),function(e){e[e.DT_INVALID=0]="DT_INVALID",e[e.DT_FLOAT=1]="DT_FLOAT",e[e.DT_DOUBLE=2]="DT_DOUBLE",e[e.DT_INT32=3]="DT_INT32",e[e.DT_UINT8=4]="DT_UINT8",e[e.DT_INT16=5]="DT_INT16",e[e.DT_INT8=6]="DT_INT8",e[e.DT_STRING=7]="DT_STRING",e[e.DT_COMPLEX64=8]="DT_COMPLEX64",e[e.DT_INT64=9]="DT_INT64",e[e.DT_BOOL=10]="DT_BOOL",e[e.DT_QINT8=11]="DT_QINT8",e[e.DT_QUINT8=12]="DT_QUINT8",e[e.DT_QINT32=13]="DT_QINT32",e[e.DT_BFLOAT16=14]="DT_BFLOAT16",e[e.DT_QINT16=15]="DT_QINT16",e[e.DT_QUINT16=16]="DT_QUINT16",e[e.DT_UINT16=17]="DT_UINT16",e[e.DT_COMPLEX128=18]="DT_COMPLEX128",e[e.DT_HALF=19]="DT_HALF",e[e.DT_RESOURCE=20]="DT_RESOURCE",e[e.DT_VARIANT=21]="DT_VARIANT",e[e.DT_UINT32=22]="DT_UINT32",e[e.DT_UINT64=23]="DT_UINT64",e[e.DT_FLOAT_REF=101]="DT_FLOAT_REF",e[e.DT_DOUBLE_REF=102]="DT_DOUBLE_REF",e[e.DT_INT32_REF=103]="DT_INT32_REF",e[e.DT_UINT8_REF=104]="DT_UINT8_REF",e[e.DT_INT16_REF=105]="DT_INT16_REF",e[e.DT_INT8_REF=106]="DT_INT8_REF",e[e.DT_STRING_REF=107]="DT_STRING_REF",e[e.DT_COMPLEX64_REF=108]="DT_COMPLEX64_REF",e[e.DT_INT64_REF=109]="DT_INT64_REF",e[e.DT_BOOL_REF=110]="DT_BOOL_REF",e[e.DT_QINT8_REF=111]="DT_QINT8_REF",e[e.DT_QUINT8_REF=112]="DT_QUINT8_REF",e[e.DT_QINT32_REF=113]="DT_QINT32_REF",e[e.DT_BFLOAT16_REF=114]="DT_BFLOAT16_REF",e[e.DT_QINT16_REF=115]="DT_QINT16_REF",e[e.DT_QUINT16_REF=116]="DT_QUINT16_REF",e[e.DT_UINT16_REF=117]="DT_UINT16_REF",e[e.DT_COMPLEX128_REF=118]="DT_COMPLEX128_REF",e[e.DT_HALF_REF=119]="DT_HALF_REF",e[e.DT_RESOURCE_REF=120]="DT_RESOURCE_REF",e[e.DT_VARIANT_REF=121]="DT_VARIANT_REF",e[e.DT_UINT32_REF=122]="DT_UINT32_REF",e[e.DT_UINT64_REF=123]="DT_UINT64_REF"}(B||(B={})),function(e){!function(e){e[e.LEGACY=0]="LEGACY",e[e.V1=1]="V1",e[e.V2=2]="V2"}(e.CheckpointFormatVersion||(e.CheckpointFormatVersion={}))}(Z||(Z={}));
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
const gg={};function bg(e){return gg[e]}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Tg(e,t,r,n,P){const a=t.inputParams[e];if(a&&void 0!==a.inputIndexStart){const e=a.inputIndexStart,o=0===a.inputIndexEnd?void 0:void 0===a.inputIndexEnd?e+1:a.inputIndexEnd;if("tensor"===a.type)return zg(t.inputNames[a.inputIndexStart],r,n,P);if("tensors"===a.type){return t.inputNames.slice(e,o).map((e=>zg(e,r,n,P)))}const u=zg(t.inputNames.slice(e)[0],r,n,P),s=u.dataSync();return"number"===a.type?s[0]:ot(u.shape,s)}const o=t.attrParams[e];return o&&o.value}function zg(e,t,r,n){const[P,a]=Lg(e);if(null!=n){const e=n.getHashTableHandleByName(P);if(null!=e)return e}const o=r.currentContextIds.find((e=>!!t[wg(P,e)]));return void 0!==o?t[wg(P,o)][a]:void 0}function dg(e,t,r){return t[wg(e,r.currentContextId)]}function yg(e,t){const[r,n,P]=Lg(e);return[wg(r,t&&t.currentContextId),n,P]}function wg(e,t){return t?`${e}-${t}`:e}function Lg(e){const t=e.split(":");if(1===t.length)return[e,0,void 0];const r=t[0],n=3===t.length?t[1]:void 0;return[r,Number(t[t.length-1]),n]}function fg(e,t,r){let n=Tg("pad",e,t,r);if("explicit"===n){n=Tg("explicitPaddings",e,t,r);const P=[[0,0],[0,0],[0,0],[0,0]];for(let e=0;e<4;e++)P[e][0]=n[2*e],P[e][1]=n[2*e+1];return P}return n}function Ig(e){return e.kept?e:vu(e)}
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Sg=[{tfOpName:"Add",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"AddV2",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"AddN",category:"arithmetic",inputs:[{start:0,end:0,name:"tensors",type:"tensors"}]},{tfOpName:"BiasAdd",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0},{tfName:"data_format",name:"dataFormat",type:"string",notSupported:!0}]},{tfOpName:"Sub",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"RealDiv",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Div",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"DivNoNan",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"FloorDiv",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Mul",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Maximum",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Minimum",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Pow",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"SquaredDifference",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Mod",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"FloorMod",category:"arithmetic",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]}];var V=Object.freeze({__proto__:null,json:Sg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Ag=[{tfOpName:"Abs",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Acos",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Asin",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Atan",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Atan2",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"y",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Ceil",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"ClipByValue",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"clipValueMin",type:"number"},{start:2,name:"clipValueMax",type:"number"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Complex",category:"basic_math",inputs:[{start:0,name:"real",type:"tensor"},{start:1,name:"imag",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"ComplexAbs",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Cos",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Cosh",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Elu",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Exp",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Floor",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Log",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Imag",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0},{tfName:"Tout",name:"outputType",type:"dtype",notSupported:!0}]},{tfOpName:"Neg",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Real",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0},{tfName:"Tout",name:"outputType",type:"dtype",notSupported:!0}]},{tfOpName:"Prelu",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"alpha",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Relu",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Relu6",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Selu",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Sigmoid",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Sin",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Sinh",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Sqrt",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Rsqrt",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Square",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Tan",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Tanh",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Sign",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Round",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Expm1",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Log1p",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Reciprocal",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Softplus",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Asinh",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Acosh",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Atanh",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Erf",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Prod",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axes",type:"number[]"}],attrs:[{tfName:"keep_dims",name:"keepDims",type:"bool",notSupported:!0},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"LeakyRelu",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"alpha",name:"alpha",type:"number",defaultValue:.2},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"IsNan",category:"basic_math",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]}];var X=Object.freeze({__proto__:null,json:Ag});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const xg=[{tfOpName:"EmptyTensorList",category:"control",inputs:[{start:0,name:"elementShape",type:"shape"},{start:1,name:"maxNumElements",type:"number"}],attrs:[{tfName:"element_dtype",name:"elementDType",type:"dtype"}]},{tfOpName:"LoopCond",category:"control",inputs:[{start:0,name:"pred",type:"tensor"}]},{tfOpName:"Switch",category:"control",inputs:[{start:0,name:"data",type:"tensor"},{start:1,name:"pred",type:"tensor"}]},{tfOpName:"Merge",category:"control",inputs:[{start:0,end:0,name:"tensors",type:"tensors"}]},{tfOpName:"Enter",category:"control",inputs:[{start:0,name:"tensor",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0},{tfName:"frame_name",name:"frameName",type:"string"},{tfName:"is_constant",name:"isConstant",type:"bool"}]},{tfOpName:"Exit",category:"control",inputs:[{start:0,name:"tensor",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"NextIteration",category:"control",inputs:[{start:0,name:"tensor",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"TensorArrayV3",category:"control",inputs:[{start:0,name:"size",type:"number"}],attrs:[{tfName:"dtype",name:"dtype",type:"dtype"},{tfName:"element_shape",name:"elementShape",type:"shape"},{tfName:"dynamic_size",name:"dynamicSize",type:"bool"},{tfName:"clear_after_read",name:"clearAfterRead",type:"bool"},{tfName:"identical_element_shapes",name:"identicalElementShapes",type:"bool"},{tfName:"tensor_array_name",name:"name",type:"string"}]},{tfOpName:"TensorArrayWriteV3",category:"control",inputs:[{start:0,name:"tensorArrayId",type:"tensor"},{start:1,name:"index",type:"number"},{start:2,name:"tensor",type:"tensor"},{start:3,name:"flowIn",type:"number"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"TensorArrayReadV3",category:"control",inputs:[{start:0,name:"tensorArrayId",type:"tensor"},{start:1,name:"index",type:"number"},{start:2,name:"flowIn",type:"number"}],attrs:[{tfName:"dtype",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"TensorArrayGatherV3",category:"control",inputs:[{start:0,name:"tensorArrayId",type:"tensor"},{start:1,name:"indices",type:"number[]"},{start:2,name:"flowIn",type:"number"}],attrs:[{tfName:"dtype",name:"dtype",type:"dtype"},{tfName:"element_shape",name:"elementShape",type:"shape"}]},{tfOpName:"TensorArrayScatterV3",category:"control",inputs:[{start:0,name:"tensorArrayId",type:"tensor"},{start:1,name:"indices",type:"number[]"},{start:2,name:"tensor",type:"tensor"},{start:3,name:"flowIn",type:"number"}],attrs:[{tfName:"T",name:"dtype",type:"dtype"}]},{tfOpName:"TensorArrayConcatV3",category:"control",inputs:[{start:0,name:"tensorArrayId",type:"tensor"},{start:1,name:"flowIn",type:"number"}],attrs:[{tfName:"dtype",name:"dtype",type:"dtype"},{tfName:"element_shape_except0",name:"elementShapeExcept0",type:"shape",notSupported:!0}]},{tfOpName:"TensorArraySplitV3",category:"control",inputs:[{start:0,name:"tensorArrayId",type:"tensor"},{start:1,name:"tensor",type:"tensor"},{start:2,name:"lengths",type:"number[]"},{start:3,name:"flowIn",type:"number"}],attrs:[{tfName:"T",name:"dtype",type:"dtype"}]},{tfOpName:"TensorArraySizeV3",category:"control",inputs:[{start:0,name:"tensorArrayId",type:"tensor"},{start:1,name:"flowIn",type:"number"}]},{tfOpName:"TensorArrayCloseV3",category:"control",inputs:[{start:0,name:"tensorArrayId",type:"tensor"}]},{tfOpName:"StatelessIf",category:"control",inputs:[{start:0,name:"cond",type:"tensor"},{start:1,end:0,name:"args",type:"tensors"}],attrs:[{tfName:"then_branch",name:"thenBranch",type:"func"},{tfName:"else_branch",name:"elseBranch",type:"func"}]},{tfOpName:"If",category:"control",inputs:[{start:0,name:"cond",type:"tensor"},{start:1,end:0,name:"args",type:"tensors"}],attrs:[{tfName:"then_branch",name:"thenBranch",type:"func"},{tfName:"else_branch",name:"elseBranch",type:"func"}]},{tfOpName:"StatelessWhile",category:"control",inputs:[{start:0,end:0,name:"args",type:"tensors"}],attrs:[{tfName:"cond",name:"cond",type:"func"},{tfName:"body",name:"body",type:"func"}]},{tfOpName:"While",category:"control",inputs:[{start:0,end:0,name:"args",type:"tensors"}],attrs:[{tfName:"cond",name:"cond",type:"func"},{tfName:"body",name:"body",type:"func"}]},{tfOpName:"TensorListScatter",category:"control",inputs:[{start:0,name:"tensor",type:"tensor"},{start:1,name:"indices",type:"number[]"},{start:2,name:"elementShape",type:"shape"}],attrs:[{tfName:"element_dtype",name:"elementDType",type:"dtype"}]},{tfOpName:"TensorListScatterV2",category:"control",inputs:[{start:0,name:"tensor",type:"tensor"},{start:1,name:"indices",type:"number[]"},{start:2,name:"elementShape",type:"shape"},{start:3,name:"numElements",type:"number"}],attrs:[{tfName:"element_dtype",name:"elementDType",type:"dtype"}]},{tfOpName:"TensorListGather",category:"control",inputs:[{start:0,name:"tensorListId",type:"tensor"},{start:1,name:"indices",type:"number[]"},{start:2,name:"elementShape",type:"shape"}],attrs:[{tfName:"element_dtype",name:"elementDType",type:"dtype"}]},{tfOpName:"TensorListGetItem",category:"control",inputs:[{start:0,name:"tensorListId",type:"tensor"},{start:1,name:"index",type:"number"},{start:2,name:"elementShape",type:"shape"}],attrs:[{tfName:"element_dtype",name:"elementDType",type:"dtype"}]},{tfOpName:"TensorListSetItem",category:"control",inputs:[{start:0,name:"tensorListId",type:"tensor"},{start:1,name:"index",type:"number"},{start:2,name:"tensor",type:"tensor"}],attrs:[{tfName:"element_dtype",name:"elementDType",type:"dtype"}]},{tfOpName:"TensorListReserve",category:"control",inputs:[{start:0,name:"elementShape",type:"shape"},{start:1,name:"numElements",type:"number"}],attrs:[{tfName:"element_dtype",name:"elementDType",type:"dtype"}]},{tfOpName:"TensorListFromTensor",category:"control",inputs:[{start:0,name:"tensor",type:"tensor"},{start:1,name:"elementShape",type:"shape"}],attrs:[{tfName:"element_dtype",name:"elementDType",type:"dtype"}]},{tfOpName:"TensorListStack",category:"control",inputs:[{start:0,name:"tensorListId",type:"tensor"},{start:1,name:"elementShape",type:"shape"}],attrs:[{tfName:"element_dtype",name:"elementDType",type:"dtype"},{tfName:"num_elements",name:"numElements",type:"dtype"}]},{tfOpName:"TensorListSplit",category:"control",inputs:[{start:0,name:"tensor",type:"tensor"},{start:1,name:"elementShape",type:"shape"},{start:2,name:"lengths",type:"number[]"}],attrs:[{tfName:"element_dtype",name:"elementDType",type:"dtype"}]},{tfOpName:"TensorListConcat",category:"control",inputs:[{start:0,name:"tensorListId",type:"tensor"}],attrs:[{tfName:"element_shape",name:"elementShape",type:"shape"},{tfName:"element_dtype",name:"elementDType",type:"dtype"}]},{tfOpName:"TensorListConcatV2",category:"control",inputs:[{start:0,name:"tensorListId",type:"tensor"}],attrs:[{tfName:"element_shape",name:"elementShape",type:"shape"},{tfName:"element_dtype",name:"elementDType",type:"dtype"}]},{tfOpName:"TensorListPopBack",category:"control",inputs:[{start:0,name:"tensorListId",type:"tensor"},{start:1,name:"elementShape",type:"shape"}],attrs:[{tfName:"element_dtype",name:"elementDType",type:"dtype"}]},{tfOpName:"TensorListPushBack",category:"control",inputs:[{start:0,name:"tensorListId",type:"tensor"},{start:1,name:"tensor",type:"tensor"}],attrs:[{tfName:"element_dtype",name:"elementDType",type:"dtype"}]},{tfOpName:"TensorListLength",category:"control",inputs:[{start:0,name:"tensorListId",type:"tensor"}]},{tfOpName:"TensorListResize",category:"control",inputs:[{start:0,name:"tensorListId",type:"tensor"},{start:1,name:"size",type:"number"}]}];var H=Object.freeze({__proto__:null,json:xg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Yg=[{tfOpName:"AvgPool",category:"convolution",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"strides",name:"strides",type:"number[]"},{tfName:"padding",name:"pad",type:"string"},{tfName:"data_format",name:"dataFormat",type:"string",notSupported:!0},{tfName:"ksize",name:"kernelSize",type:"number[]"},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"MaxPool",category:"convolution",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"strides",name:"strides",type:"number[]"},{tfName:"padding",name:"pad",type:"string"},{tfName:"data_format",name:"dataFormat",type:"string",notSupported:!0},{tfName:"ksize",name:"kernelSize",type:"number[]"},{tfName:"explicit_paddings",name:"explicitPaddings",type:"number[]",defaultValue:[],notSupported:!0},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"MaxPoolWithArgmax",category:"convolution",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"strides",name:"strides",type:"number[]"},{tfName:"padding",name:"pad",type:"string"},{tfName:"ksize",name:"kernelSize",type:"number[]"},{tfName:"include_batch_in_index",name:"includeBatchInIndex",type:"bool"},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"AvgPool3D",category:"convolution",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"strides",name:"strides",type:"number[]"},{tfName:"padding",name:"pad",type:"string"},{tfName:"data_format",name:"dataFormat",type:"string",notSupported:!0},{tfName:"ksize",name:"kernelSize",type:"number[]"},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"MaxPool3D",category:"convolution",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"strides",name:"strides",type:"number[]"},{tfName:"padding",name:"pad",type:"string"},{tfName:"data_format",name:"dataFormat",type:"string",notSupported:!0},{tfName:"ksize",name:"kernelSize",type:"number[]"},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Conv1D",category:"convolution",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"filter",type:"tensor"}],attrs:[{tfName:"stride",name:"stride",type:"number"},{tfName:"padding",name:"pad",type:"string"},{tfName:"data_format",name:"dataFormat",type:"string",defaultValue:"NWC"},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0},{tfName:"dilation",name:"dilation",type:"number",defaultValue:1}]},{tfOpName:"Conv2D",category:"convolution",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"filter",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0},{tfName:"strides",name:"strides",type:"number[]"},{tfName:"padding",name:"pad",type:"string"},{tfName:"useCudnnOnGpu",name:"useCudnnOnGpu",type:"bool"},{tfName:"data_format",name:"dataFormat",type:"string",defaultValue:"NHWC"},{tfName:"explicit_paddings",name:"explicitPaddings",type:"number[]",defaultValue:[]},{tfName:"dilations",name:"dilations",type:"number[]"}]},{tfOpName:"_FusedConv2D",category:"convolution",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"filter",type:"tensor"},{start:2,end:0,name:"args",type:"tensors"}],attrs:[{tfName:"num_args",name:"numArgs",type:"number"},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0},{tfName:"strides",name:"strides",type:"number[]"},{tfName:"padding",name:"pad",type:"string"},{tfName:"explicit_paddings",name:"explicitPaddings",type:"number[]",defaultValue:[]},{tfName:"use_cudnn_on_gpu",name:"useCudnnOnGpu",type:"bool",defaultValue:!0},{tfName:"data_format",name:"dataFormat",type:"string",defaultValue:"NHWC"},{tfName:"dilations",name:"dilations",type:"number[]",defaultValue:[1,1,1,1]},{tfName:"fused_ops",name:"fusedOps",type:"string[]",defaultValue:[]},{tfName:"epsilon",name:"epsilon",type:"number",defaultValue:1e-4},{tfName:"leakyrelu_alpha",name:"leakyreluAlpha",type:"number",defaultValue:.2}]},{tfOpName:"Conv2DBackpropInput",category:"convolution",inputs:[{start:2,name:"x",type:"tensor"},{start:1,name:"filter",type:"tensor"},{start:0,name:"outputShape",type:"number[]"}],attrs:[{tfName:"strides",name:"strides",type:"number[]"},{tfName:"padding",name:"pad",type:"string"},{tfName:"data_format",name:"dataFormat",type:"string",notSupported:!0},{tfName:"explicit_paddings",name:"explicitPaddings",type:"number[]",defaultValue:[]},{tfName:"dilations",name:"dilations",type:"number[]",notSupported:!0}]},{tfOpName:"DepthwiseConv2d",category:"convolution",inputs:[{start:0,name:"input",type:"tensor"},{start:1,name:"filter",type:"tensor"}],attrs:[{tfName:"strides",name:"strides",type:"number[]"},{tfName:"padding",name:"pad",type:"string"},{tfName:"data_format",name:"dataFormat",type:"string",defaultValue:"NHWC"},{tfName:"explicit_paddings",name:"explicitPaddings",type:"number[]",defaultValue:[]},{tfName:"dilations",name:"dilations",type:"number[]"}]},{tfOpName:"DepthwiseConv2dNative",category:"convolution",inputs:[{start:0,name:"input",type:"tensor"},{start:1,name:"filter",type:"tensor"}],attrs:[{tfName:"strides",name:"strides",type:"number[]"},{tfName:"padding",name:"pad",type:"string"},{tfName:"data_format",name:"dataFormat",type:"string",defaultValue:"NHWC"},{tfName:"explicit_paddings",name:"explicitPaddings",type:"number[]",defaultValue:[]},{tfName:"dilations",name:"dilations",type:"number[]"}]},{tfOpName:"FusedDepthwiseConv2dNative",category:"convolution",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"filter",type:"tensor"},{start:2,end:0,name:"args",type:"tensors"}],attrs:[{tfName:"num_args",name:"numArgs",type:"number"},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0},{tfName:"strides",name:"strides",type:"number[]"},{tfName:"padding",name:"pad",type:"string"},{tfName:"data_format",name:"dataFormat",type:"string",defaultValue:"NHWC"},{tfName:"dilations",name:"dilations",type:"number[]",defaultValue:[1,1,1,1]},{tfName:"fused_ops",name:"fusedOps",type:"string[]",defaultValue:[]},{tfName:"explicit_paddings",name:"explicitPaddings",type:"number[]",defaultValue:[]}]},{tfOpName:"Conv3D",category:"convolution",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"filter",type:"tensor"}],attrs:[{tfName:"strides",name:"strides",type:"number[]"},{tfName:"padding",name:"pad",type:"string"},{tfName:"data_format",name:"dataFormat",type:"string",defaultValue:"NHWC"},{tfName:"dilations",name:"dilations",type:"number[]"}]},{tfOpName:"Dilation2D",category:"convolution",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"filter",type:"tensor"}],attrs:[{tfName:"strides",name:"strides",type:"number[]"},{tfName:"rates",name:"dilations",type:"number[]"},{tfName:"padding",name:"pad",type:"string"}]}];var J=Object.freeze({__proto__:null,json:Yg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const kg=[{tfOpName:"Fill",category:"creation",inputs:[{start:0,name:"shape",type:"number[]"},{start:1,name:"value",type:"number"}],attrs:[{tfName:"T",name:"dtype",type:"dtype"}]},{tfOpName:"LinSpace",category:"creation",inputs:[{start:0,name:"start",type:"number"},{start:1,name:"stop",type:"number"},{start:2,name:"num",type:"number"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"OneHot",category:"creation",inputs:[{start:0,name:"indices",type:"tensor"},{start:1,name:"depth",type:"number"},{start:2,name:"onValue",type:"number",defaultValue:1},{start:3,name:"offValue",type:"number",defaultValue:0}],attrs:[{tfName:"axis",name:"axis",type:"number",notSupported:!0},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Ones",category:"creation",inputs:[{start:0,name:"shape",type:"number[]"}],attrs:[{tfName:"T",name:"dtype",type:"dtype"}]},{tfOpName:"OnesLike",category:"creation",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"dtype",name:"dtype",type:"dtype"}]},{tfOpName:"RandomStandardNormal",category:"creation",inputs:[{start:0,name:"shape",type:"number[]"}],attrs:[{tfName:"seed",name:"seed",type:"number",defaultValue:0},{tfName:"seed2",name:"seed2",type:"number",defaultValue:0,notSupported:!0},{tfName:"dtype",name:"dtype",type:"dtype"},{tfName:"T",name:"T",type:"number",notSupported:!0}]},{tfOpName:"RandomUniform",category:"creation",inputs:[{start:0,name:"shape",type:"number[]"}],attrs:[{tfName:"minval",name:"minval",type:"number",defaultValue:0},{tfName:"maxval",name:"maxval",type:"number",defaultValue:1},{tfName:"dtype",name:"dtype",type:"dtype"},{tfName:"seed",name:"seed",type:"number",defaultValue:0},{tfName:"seed2",name:"seed2",type:"number",defaultValue:0,notSupported:!0},{tfName:"T",name:"T",type:"number",notSupported:!0}]},{tfOpName:"Range",category:"creation",inputs:[{start:0,name:"start",type:"number"},{start:1,name:"stop",type:"number"},{start:2,name:"step",type:"number",defaultValue:0}],attrs:[{tfName:"Tidx",name:"dtype",type:"dtype"}]},{tfOpName:"TruncatedNormal",category:"creation",inputs:[{start:0,name:"shape",type:"number[]"}],attrs:[{tfName:"means",name:"mean",type:"number",defaultValue:0},{tfName:"stddev",name:"stdDev",type:"number",defaultValue:1},{tfName:"seed",name:"seed",type:"number"},{tfName:"seed2",name:"seed2",type:"number",defaultValue:0,notSupported:!0},{tfName:"dtype",name:"dtype",type:"dtype"},{tfName:"T",name:"T",type:"number",notSupported:!0}]},{tfOpName:"Zeros",category:"creation",inputs:[{start:0,name:"shape",type:"number[]"}],attrs:[{tfName:"T",name:"dtype",type:"dtype"}]},{tfOpName:"ZerosLike",category:"creation",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype"}]},{tfOpName:"Multinomial",category:"creation",inputs:[{start:0,name:"logits",type:"tensor"},{start:1,name:"numSamples",type:"number"}],attrs:[{tfName:"seed",name:"seed",type:"number"},{tfName:"seed2",name:"seed2",type:"number"},{tfName:"T",name:"dtype",type:"dtype"},{tfName:"output_dtype",name:"output_dtype",type:"dtype"}]}];var _=Object.freeze({__proto__:null,json:kg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Cg=[{tfOpName:"NonMaxSuppressionV2",category:"dynamic",inputs:[{start:0,name:"boxes",type:"tensor"},{start:1,name:"scores",type:"tensor"},{start:2,name:"maxOutputSize",type:"number"},{start:3,name:"iouThreshold",type:"number"}]},{tfOpName:"NonMaxSuppressionV3",category:"dynamic",inputs:[{start:0,name:"boxes",type:"tensor"},{start:1,name:"scores",type:"tensor"},{start:2,name:"maxOutputSize",type:"number"},{start:3,name:"iouThreshold",type:"number"},{start:4,name:"scoreThreshold",type:"number"}]},{tfOpName:"NonMaxSuppressionV4",category:"dynamic",inputs:[{start:0,name:"boxes",type:"tensor"},{start:1,name:"scores",type:"tensor"},{start:2,name:"maxOutputSize",type:"number"},{start:3,name:"iouThreshold",type:"number"},{start:4,name:"scoreThreshold",type:"number"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0},{tfName:"T_threshold",name:"threshold",type:"dtype",notSupported:!0},{tfName:"pad_to_max_output_size",name:"padToMaxOutputSize",type:"bool"}]},{tfOpName:"NonMaxSuppressionV5",category:"dynamic",inputs:[{start:0,name:"boxes",type:"tensor"},{start:1,name:"scores",type:"tensor"},{start:2,name:"maxOutputSize",type:"number"},{start:3,name:"iouThreshold",type:"number"},{start:4,name:"scoreThreshold",type:"number"},{start:5,name:"softNmsSigma",type:"number"}]},{tfOpName:"Where",category:"dynamic",inputs:[{start:0,name:"condition",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"ListDiff",category:"dynamic",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"y",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]}];var $=Object.freeze({__proto__:null,json:Cg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Eg=[{tfOpName:"LowerBound",category:"evaluation",inputs:[{start:0,name:"sortedSequence",type:"tensor"},{start:1,name:"values",type:"tensor"}]},{tfOpName:"TopKV2",category:"evaluation",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"k",type:"number"}],attrs:[{tfName:"sorted",name:"sorted",type:"bool"}]},{tfOpName:"UpperBound",category:"evaluation",inputs:[{start:0,name:"sortedSequence",type:"tensor"},{start:1,name:"values",type:"tensor"}]},{tfOpName:"Unique",category:"evaluation",inputs:[{start:0,name:"x",type:"tensor"}]},{tfOpName:"UniqueV2",category:"evaluation",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number"}]}];var ee=Object.freeze({__proto__:null,json:Eg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Qg=[{tfOpName:"PlaceholderWithDefault",category:"graph",inputs:[{start:0,name:"default",type:"tensor"}],attrs:[{tfName:"shape",name:"shape",type:"shape"},{tfName:"dtype",name:"dtype",type:"dtype"}]},{tfOpName:"Placeholder",category:"graph",attrs:[{tfName:"shape",name:"shape",type:"shape"},{tfName:"dtype",name:"dtype",type:"dtype"}]},{tfOpName:"Const",category:"graph"},{tfOpName:"Identity",category:"graph",inputs:[{start:0,name:"x",type:"tensor"}]},{tfOpName:"IdentityN",category:"graph",inputs:[{start:0,end:0,name:"x",type:"tensors"}]},{tfOpName:"Snapshot",category:"graph",inputs:[{start:0,name:"x",type:"tensor"}]},{tfOpName:"Rank",category:"graph",inputs:[{start:0,name:"x",type:"tensor"}]},{tfOpName:"Size",category:"graph",inputs:[{start:0,name:"x",type:"tensor"}]},{tfOpName:"Shape",category:"graph",inputs:[{start:0,name:"x",type:"tensor"}]},{tfOpName:"ShapeN",category:"graph",inputs:[{start:0,end:0,name:"x",type:"tensors"}]},{tfOpName:"Print",category:"graph",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"data",type:"tensors"}],attrs:[{tfName:"message",name:"message",type:"string"},{tfName:"first_n",name:"firstN",type:"number",notSupported:!0},{tfName:"summarize",name:"summarize",type:"number",defaultValue:3}]},{tfOpName:"NoOp",category:"graph",inputs:[]},{tfOpName:"StopGradient",category:"graph",inputs:[{start:0,name:"x",type:"tensor"}]},{tfOpName:"FakeQuantWithMinMaxVars",category:"graph",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"min",name:"min",type:"number"},{tfName:"max",name:"max",type:"number"}]}];var te=Object.freeze({__proto__:null,json:Qg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Wg=[{tfOpName:"HashTable",category:"hash_table",inputs:[],attrs:[{tfName:"shared_name",name:"sharedName",type:"string"},{tfName:"use_node_name_sharing",name:"useNodeNameSharing",type:"bool"},{tfName:"key_dtype",name:"keyDType",type:"dtype"},{tfName:"value_dtype",name:"valueDType",type:"dtype"}]},{tfOpName:"HashTableV2",category:"hash_table",inputs:[],attrs:[{tfName:"shared_name",name:"sharedName",type:"string"},{tfName:"use_node_name_sharing",name:"useNodeNameSharing",type:"bool"},{tfName:"key_dtype",name:"keyDType",type:"dtype"},{tfName:"value_dtype",name:"valueDType",type:"dtype"}]},{tfOpName:"LookupTableImport",category:"hash_table",inputs:[{start:0,name:"tableHandle",type:"tensor"},{start:1,name:"keys",type:"tensor"},{start:2,name:"values",type:"tensor"}],attrs:[{tfName:"Tin",name:"tIn",type:"dtype",notSupported:!0},{tfName:"Tout",name:"tOut",type:"dtype",notSupported:!0}]},{tfOpName:"LookupTableImportV2",category:"hash_table",inputs:[{start:0,name:"tableHandle",type:"tensor"},{start:1,name:"keys",type:"tensor"},{start:2,name:"values",type:"tensor"}],attrs:[{tfName:"Tin",name:"tIn",type:"dtype",notSupported:!0},{tfName:"Tout",name:"tOut",type:"dtype",notSupported:!0}]},{tfOpName:"LookupTableFind",category:"hash_table",inputs:[{start:0,name:"tableHandle",type:"tensor"},{start:1,name:"keys",type:"tensor"},{start:2,name:"defaultValue",type:"tensor"}],attrs:[{tfName:"Tin",name:"tIn",type:"dtype",notSupported:!0},{tfName:"Tout",name:"tOut",type:"dtype",notSupported:!0}]},{tfOpName:"LookupTableFindV2",category:"hash_table",inputs:[{start:0,name:"tableHandle",type:"tensor"},{start:1,name:"keys",type:"tensor"},{start:2,name:"defaultValue",type:"tensor"}],attrs:[{tfName:"Tin",name:"tIn",type:"dtype",notSupported:!0},{tfName:"Tout",name:"tOut",type:"dtype",notSupported:!0}]},{tfOpName:"LookupTableSize",category:"hash_table",inputs:[{start:0,name:"tableHandle",type:"tensor"}]},{tfOpName:"LookupTableSizeV2",category:"hash_table",inputs:[{start:0,name:"tableHandle",type:"tensor"}]}];var re=Object.freeze({__proto__:null,json:Wg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Ug=[{tfOpName:"ResizeBilinear",category:"image",inputs:[{start:0,name:"images",type:"tensor"},{start:1,name:"size",type:"number[]"}],attrs:[{tfName:"align_corners",name:"alignCorners",type:"bool"},{tfName:"half_pixel_centers",name:"halfPixelCenters",type:"bool"},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"ResizeNearestNeighbor",category:"image",inputs:[{start:0,name:"images",type:"tensor"},{start:1,name:"size",type:"number[]"}],attrs:[{tfName:"align_corners",name:"alignCorners",type:"bool"},{tfName:"half_pixel_centers",name:"halfPixelCenters",type:"bool"},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"CropAndResize",category:"image",inputs:[{start:0,name:"image",type:"tensor"},{start:1,name:"boxes",type:"tensor"},{start:2,name:"boxInd",type:"tensor"},{start:3,name:"cropSize",type:"number[]"}],attrs:[{tfName:"method",name:"method",type:"string"},{tfName:"extrapolation_value",name:"extrapolationValue",type:"number"}]},{tfOpName:"ImageProjectiveTransformV3",category:"image",inputs:[{start:0,name:"images",type:"tensor"},{start:1,name:"transforms",type:"tensor"},{start:2,name:"outputShape",type:"number[]"},{start:3,name:"fillValue",type:"number"}],attrs:[{tfName:"interpolation",name:"interpolation",type:"string"},{tfName:"fill_mode",name:"fillMode",type:"string"}]}];var ne=Object.freeze({__proto__:null,json:Ug});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const qg=[{tfOpName:"Equal",category:"logical",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"NotEqual",category:"logical",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Greater",category:"logical",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"GreaterEqual",category:"logical",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Less",category:"logical",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"LessEqual",category:"logical",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"LogicalAnd",category:"logical",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"LogicalNot",category:"logical",inputs:[{start:0,name:"a",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"LogicalOr",category:"logical",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Select",category:"logical",inputs:[{start:0,name:"condition",type:"tensor"},{start:1,name:"a",type:"tensor"},{start:2,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"SelectV2",category:"logical",inputs:[{start:0,name:"condition",type:"tensor"},{start:1,name:"a",type:"tensor"},{start:2,name:"b",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]}];var Pe=Object.freeze({__proto__:null,json:qg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Gg=[{tfOpName:"_FusedMatMul",category:"matrices",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"},{start:2,end:0,name:"args",type:"tensors"}],attrs:[{tfName:"num_args",name:"numArgs",type:"number"},{tfName:"fused_ops",name:"fusedOps",type:"string[]",defaultValue:[]},{tfName:"epsilon",name:"epsilon",type:"number",defaultValue:1e-4},{tfName:"transpose_a",name:"transposeA",type:"bool",defaultValue:!1},{tfName:"transpose_b",name:"transposeB",type:"bool",defaultValue:!1},{tfName:"leakyrelu_alpha",name:"leakyreluAlpha",type:"number",defaultValue:.2},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"MatMul",category:"matrices",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"transpose_a",name:"transposeA",type:"bool",defaultValue:!1},{tfName:"transpose_b",name:"transposeB",type:"bool",defaultValue:!1},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"BatchMatMul",category:"matrices",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"adj_x",name:"transposeA",type:"bool",defaultValue:!1},{tfName:"adj_y",name:"transposeB",type:"bool",defaultValue:!1},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"BatchMatMulV2",category:"matrices",inputs:[{start:0,name:"a",type:"tensor"},{start:1,name:"b",type:"tensor"}],attrs:[{tfName:"adj_x",name:"transposeA",type:"bool",defaultValue:!1},{tfName:"adj_y",name:"transposeB",type:"bool",defaultValue:!1},{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Transpose",category:"matrices",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"perm",type:"number[]"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"Einsum",category:"matrices",inputs:[{start:0,end:0,name:"tensors",type:"tensors"}],attrs:[{tfName:"equation",name:"equation",type:"string"},{tfName:"N",name:"n",type:"number",defaultValue:2},{tfName:"T",name:"dtype",type:"dtype"}]}];var ae=Object.freeze({__proto__:null,json:Gg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Mg=[{tfOpName:"EuclideanNorm",category:"normalization",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number[]"}],attrs:[{tfName:"keep_dims",name:"keepDims",type:"bool",defaultValue:!1}]},{tfOpName:"FusedBatchNorm",category:"normalization",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"scale",type:"tensor"},{start:2,name:"offset",type:"tensor"},{start:3,name:"mean",type:"tensor"},{start:4,name:"variance",type:"tensor"}],attrs:[{tfName:"epsilon",name:"epsilon",type:"number",defaultValue:.001},{tfName:"data_format",name:"dataFormat",type:"string",notSupported:!0}]},{tfOpName:"FusedBatchNormV2",category:"normalization",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"scale",type:"tensor"},{start:2,name:"offset",type:"tensor"},{start:3,name:"mean",type:"tensor"},{start:4,name:"variance",type:"tensor"}],attrs:[{tfName:"epsilon",name:"epsilon",type:"number",defaultValue:.001},{tfName:"data_format",name:"dataFormat",type:"string",notSupported:!0}]},{tfOpName:"FusedBatchNormV3",category:"normalization",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"scale",type:"tensor"},{start:2,name:"offset",type:"tensor"},{start:3,name:"mean",type:"tensor"},{start:4,name:"variance",type:"tensor"}],attrs:[{tfName:"epsilon",name:"epsilon",type:"number",defaultValue:.001},{tfName:"data_format",name:"dataFormat",type:"string",notSupported:!0}]},{tfOpName:"LRN",category:"normalization",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"depth_radius",name:"radius",type:"number",defaultValue:5},{tfName:"bias",name:"bias",type:"number",defaultValue:1},{tfName:"alpha",name:"alpha",type:"number",defaultValue:1},{tfName:"beta",name:"beta",type:"number",defaultValue:.5}]},{tfOpName:"Softmax",category:"normalization",inputs:[{start:0,name:"x",type:"tensor"}]},{tfOpName:"LogSoftmax",category:"normalization",inputs:[{start:0,name:"x",type:"tensor"}]},{tfOpName:"SparseToDense",category:"normalization",inputs:[{start:0,name:"sparseIndices",type:"tensor"},{start:1,name:"outputShape",type:"number[]"},{start:2,name:"sparseValues",type:"tensor"},{start:3,name:"defaultValue",type:"tensor"}],attrs:[{tfName:"validate_indices",name:"validateIndices",type:"bool",defaultValue:!0,notSupported:!0}]}];var oe=Object.freeze({__proto__:null,json:Mg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Kg=[{tfOpName:"Bincount",category:"reduction",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"size",type:"number"},{start:2,name:"weights",type:"tensor"}]},{tfOpName:"DenseBincount",category:"reduction",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"size",type:"number"},{start:2,name:"weights",type:"tensor"}],attrs:[{tfName:"binary_output",name:"binaryOutput",type:"bool"}]},{tfOpName:"Max",category:"reduction",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number[]"}],attrs:[{tfName:"keep_dims",name:"keepDims",type:"bool"}]},{tfOpName:"Mean",category:"reduction",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number[]"}],attrs:[{tfName:"keep_dims",name:"keepDims",type:"bool"}]},{tfOpName:"Min",category:"reduction",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number[]"}],attrs:[{tfName:"keep_dims",name:"keepDims",type:"bool"}]},{tfOpName:"Sum",category:"reduction",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number[]"}],attrs:[{tfName:"keep_dims",name:"keepDims",type:"bool"}]},{tfOpName:"All",category:"reduction",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number[]"}],attrs:[{tfName:"keep_dims",name:"keepDims",type:"bool"}]},{tfOpName:"Any",category:"reduction",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number[]"}],attrs:[{tfName:"keep_dims",name:"keepDims",type:"bool"}]},{tfOpName:"ArgMax",category:"reduction",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number"}]},{tfOpName:"ArgMin",category:"reduction",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number"}]},{tfOpName:"Prod",category:"reduction",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number[]"}],attrs:[{tfName:"keep_dims",name:"keepDims",type:"bool"}]},{tfOpName:"Cumprod",category:"reduction",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number"}],attrs:[{tfName:"exclusive",name:"exclusive",type:"bool"},{tfName:"reverse",name:"reverse",type:"bool"}]},{tfOpName:"Cumsum",category:"reduction",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number"}],attrs:[{tfName:"exclusive",name:"exclusive",type:"bool"},{tfName:"reverse",name:"reverse",type:"bool"}]}];var ue=Object.freeze({__proto__:null,json:Kg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Ng=[{tfOpName:"ConcatV2",category:"slice_join",inputs:[{start:0,end:-1,name:"tensors",type:"tensors"},{start:-1,name:"axis",type:"number"}],attrs:[{tfName:"N",name:"n",type:"number",defaultValue:2}]},{tfOpName:"Concat",category:"slice_join",inputs:[{start:1,end:0,name:"tensors",type:"tensors"},{start:0,name:"axis",type:"number"}],attrs:[{tfName:"N",name:"n",type:"number",defaultValue:2}]},{tfOpName:"GatherV2",category:"slice_join",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"indices",type:"tensor"},{start:2,name:"axis",type:"number",defaultValue:0}],attrs:[{tfName:"batch_dims",name:"batchDims",type:"number",defaultValue:0}]},{tfOpName:"Gather",category:"slice_join",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"indices",type:"tensor"}],attrs:[{tfName:"validate_indices",name:"validateIndices",type:"bool",notSupported:!0}]},{tfOpName:"Reverse",category:"slice_join",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"dims",type:"bool[]"}]},{tfOpName:"ReverseV2",category:"slice_join",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number[]"}]},{tfOpName:"Slice",category:"slice_join",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"begin",type:"number[]"},{start:2,name:"size",type:"number[]"}]},{tfOpName:"StridedSlice",category:"slice_join",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"begin",type:"number[]"},{start:2,name:"end",type:"number[]"},{start:3,name:"strides",type:"number[]"}],attrs:[{tfName:"begin_mask",name:"beginMask",type:"number",defaultValue:0},{tfName:"end_mask",name:"endMask",type:"number",defaultValue:0},{tfName:"new_axis_mask",name:"newAxisMask",type:"number",defaultValue:0},{tfName:"ellipsis_mask",name:"ellipsisMask",type:"number",defaultValue:0},{tfName:"shrink_axis_mask",name:"shrinkAxisMask",type:"number",defaultValue:0}]},{tfOpName:"Pack",category:"slice_join",inputs:[{start:0,end:0,name:"tensors",type:"tensors"}],attrs:[{tfName:"axis",name:"axis",type:"number",defaultValue:0}]},{tfOpName:"Unpack",category:"slice_join",inputs:[{start:0,name:"tensor",type:"tensor"}],attrs:[{tfName:"axis",name:"axis",type:"number",defaultValue:0},{tfName:"num",name:"num",type:"number",defaultValue:0,notSupported:!0}]},{tfOpName:"Tile",category:"slice_join",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"reps",type:"number[]"}]},{tfOpName:"Split",category:"slice_join",inputs:[{start:0,name:"axis",type:"number",defaultValue:0},{start:1,name:"x",type:"tensor"}],attrs:[{tfName:"num_split",name:"numOrSizeSplits",type:"number",defaultValue:1}]},{tfOpName:"SplitV",category:"slice_join",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"numOrSizeSplits",type:"number[]"},{start:2,name:"axis",type:"number",defaultValue:0}]},{tfOpName:"ScatterNd",category:"slice_join",inputs:[{start:0,name:"indices",type:"tensor"},{start:1,name:"values",type:"tensor"},{start:2,name:"shape",type:"number[]"}]},{tfOpName:"GatherNd",category:"slice_join",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"indices",type:"tensor"}]},{tfOpName:"SparseToDense",category:"slice_join",inputs:[{start:0,name:"sparseIndices",type:"tensor"},{start:1,name:"outputShape",type:"number[]"},{start:2,name:"sparseValues",type:"tensor"},{start:3,name:"defaultValue",type:"tensor"}],attrs:[{tfName:"validate_indices",name:"validateIndices",type:"bool",defaultValue:!1,notSupported:!0}]}];var se=Object.freeze({__proto__:null,json:Ng});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Rg=[{tfOpName:"SparseFillEmptyRows",category:"sparse",inputs:[{start:0,name:"indices",type:"tensor"},{start:1,name:"values",type:"tensor"},{start:2,name:"denseShape",type:"tensor"},{start:3,name:"defaultValue",type:"tensor"}]},{tfOpName:"SparseReshape",category:"sparse",inputs:[{start:0,name:"inputIndices",type:"tensor"},{start:1,name:"inputShape",type:"tensor"},{start:2,name:"newShape",type:"tensor"}],attrs:[{tfName:"T",name:"dtype",type:"dtype",notSupported:!0}]},{tfOpName:"SparseSegmentMean",category:"sparse",inputs:[{start:0,name:"data",type:"tensor"},{start:1,name:"indices",type:"tensor"},{start:2,name:"segmentIds",type:"tensor"}]},{tfOpName:"SparseSegmentSum",category:"sparse",inputs:[{start:0,name:"data",type:"tensor"},{start:1,name:"indices",type:"tensor"},{start:2,name:"segmentIds",type:"tensor"}]}];var ve=Object.freeze({__proto__:null,json:Rg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Fg=[{tfOpName:"FFT",category:"spectral",inputs:[{start:0,name:"x",type:"tensor"}]},{tfOpName:"IFFT",category:"spectral",inputs:[{start:0,name:"x",type:"tensor"}]},{tfOpName:"RFFT",category:"spectral",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"fft_length",type:"number",notSupported:!0}]},{tfOpName:"IRFFT",category:"spectral",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"fft_length",type:"number",notSupported:!0}]}];var ie=Object.freeze({__proto__:null,json:Fg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Bg=[{tfOpName:"StringNGrams",category:"string",inputs:[{start:0,name:"data",type:"tensor"},{start:1,name:"dataSplits",type:"tensor"}],attrs:[{tfName:"separator",name:"separator",type:"string"},{tfName:"ngram_widths",name:"nGramWidths",type:"number[]"},{tfName:"left_pad",name:"leftPad",type:"string"},{tfName:"right_pad",name:"rightPad",type:"string"},{tfName:"pad_width",name:"padWidth",type:"number"},{tfName:"preserve_short_sequences",name:"preserveShortSequences",type:"bool"}],outputs:["ngrams","ngrams_splits"]},{tfOpName:"StringSplit",category:"string",inputs:[{start:0,name:"input",type:"tensor"},{start:1,name:"delimiter",type:"tensor"}],attrs:[{tfName:"skip_empty",name:"skipEmpty",type:"bool"}],outputs:["indices","values","shape"]},{tfOpName:"StringToHashBucketFast",category:"string",inputs:[{start:0,name:"input",type:"tensor"}],attrs:[{tfName:"num_buckets",name:"numBuckets",type:"number"}]}];var le=Object.freeze({__proto__:null,json:Bg});
/**
     * @license
     * Copyright 2022 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Zg=[{tfOpName:"Cast",category:"transformation",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"SrcT",name:"sdtype",type:"dtype",notSupported:!0},{tfName:"DstT",name:"dtype",type:"dtype"}]},{tfOpName:"ExpandDims",category:"transformation",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"axis",type:"number"}]},{tfOpName:"MirrorPad",category:"transformation",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"padding",type:"number[]"}],attrs:[{tfName:"mode",name:"mode",type:"string"}]},{tfOpName:"Pad",category:"transformation",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"padding",type:"number[]"}],attrs:[{tfName:"constant_value",name:"constantValue",type:"number",defaultValue:0}]},{tfOpName:"PadV2",category:"transformation",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"padding",type:"number[]"},{start:2,name:"constantValue",type:"number",defaultValue:0}]},{tfOpName:"Reshape",category:"transformation",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"shape",type:"number[]"}]},{tfOpName:"Squeeze",category:"transformation",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"axis",tfDeprecatedName:"squeeze_dims",name:"axis",type:"number[]"}]},{tfOpName:"SpaceToBatchND",category:"transformation",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"blockShape",type:"number[]"},{start:2,name:"paddings",type:"number[]"}]},{tfOpName:"BatchToSpaceND",category:"transformation",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"blockShape",type:"number[]"},{start:2,name:"crops",type:"number[]"}]},{tfOpName:"DepthToSpace",category:"transformation",inputs:[{start:0,name:"x",type:"tensor"}],attrs:[{tfName:"block_size",name:"blockSize",type:"number"},{tfName:"data_format",name:"dataFormat",type:"string"}]},{tfOpName:"BroadcastTo",category:"transformation",inputs:[{start:0,name:"x",type:"tensor"},{start:1,name:"shape",type:"number[]"}],attrs:[]},{tfOpName:"BroadcastArgs",category:"transformation",inputs:[{start:0,name:"s0",type:"tensor"},{start:1,name:"s1",type:"tensor"}],attrs:[]}];var ce=Object.freeze({__proto__:null,json:Zg});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class Vg{static get Instance(){return this._instance||(this._instance=new this)}constructor(){const e=[].concat(...[V,X,H,J,_,$,ee,te,re,ne,Pe,ae,oe,ue,se,ve,ie,le,ce].map((e=>e.json)));this.opMappers=e.reduce(((e,t)=>(e[t.tfOpName]=t,e)),{})}transformGraph(e,t={}){const r=e.node,n=[],P=[],a=[],o=r.reduce(((e,t)=>(e[t.name]=this.mapNode(t),t.op.startsWith("Placeholder")?n.push(e[t.name]):"Const"===t.op?P.push(e[t.name]):null!=t.input&&0!==t.input.length||a.push(e[t.name]),e)),{});let u=[];const s=[];let v={},i={};null!=t&&(v=this.mapSignatureEntries(t.inputs),i=this.mapSignatureEntries(t.outputs));const l=Object.keys(o);l.forEach((e=>{const t=o[e];t.inputNames.forEach(((e,r)=>{const[n,,P]=yg(e),a=o[n];if(null!=a.outputs){const e=a.outputs.indexOf(P);if(-1!==e){const P=`${n}:${e}`;t.inputNames[r]=P}}t.inputs.push(a),a.children.push(t)}))})),0===Object.keys(i).length?l.forEach((e=>{const t=o[e];0===t.children.length&&s.push(t)})):Object.keys(i).forEach((e=>{const[t]=yg(e),r=o[t];null!=r&&(r.signatureKey=i[e],s.push(r))})),Object.keys(v).length>0?Object.keys(v).forEach((e=>{const[t]=yg(e),r=o[t];r&&(r.signatureKey=v[e],u.push(r))})):u=n;let c={};null!=e.library&&null!=e.library.function&&(c=e.library.function.reduce(((e,t)=>(e[t.signature.name]=this.mapFunction(t),e)),{}));const O={nodes:o,inputs:u,outputs:s,weights:P,placeholders:n,signature:t,functions:c};return a.length>0&&(O.initNodes=a),O}mapSignatureEntries(e){return Object.keys(e||{}).reduce(((t,r)=>(t[e[r].name]=r,t)),{})}mapNode(e){const t=bg(e.op)||this.opMappers[e.op]||{};null==e.attr&&(e.attr={});const r={name:e.name,op:e.op,category:t.category,inputNames:(e.input||[]).map((e=>e.startsWith("^")?e.slice(1):e)),inputs:[],children:[],inputParams:{},attrParams:{},rawAttrs:e.attr,outputs:t.outputs};return null!=t.inputs&&(r.inputParams=t.inputs.reduce(((e,t)=>(e[t.name]={type:t.type,inputIndexStart:t.start,inputIndexEnd:t.end},e)),{})),null!=t.attrs&&(r.attrParams=t.attrs.reduce(((t,r)=>{const n=r.type;let P;switch(r.type){case"string":P=Jg(e.attr,r.tfName,r.defaultValue),void 0===P&&r.tfDeprecatedName&&(P=Jg(e.attr,r.tfDeprecatedName,r.defaultValue));break;case"string[]":P=ub(e.attr,r.tfName,r.defaultValue),void 0===P&&r.tfDeprecatedName&&(P=ub(e.attr,r.tfDeprecatedName,r.defaultValue));break;case"number":P=$g(e.attr,r.tfName,r.defaultValue||0),void 0===P&&r.tfDeprecatedName&&(P=$g(e.attr,r.tfDeprecatedName,r.defaultValue));break;case"number[]":P=ob(e.attr,r.tfName,r.defaultValue),void 0===P&&r.tfDeprecatedName&&(P=ob(e.attr,r.tfDeprecatedName,r.defaultValue));break;case"bool":P=_g(e.attr,r.tfName,r.defaultValue),void 0===P&&r.tfDeprecatedName&&(P=_g(e.attr,r.tfDeprecatedName,r.defaultValue));break;case"bool[]":P=vb(e.attr,r.tfName,r.defaultValue),void 0===P&&r.tfDeprecatedName&&(P=vb(e.attr,r.tfDeprecatedName,r.defaultValue));break;case"shape":P=ab(e.attr,r.tfName,r.defaultValue),void 0===P&&r.tfDeprecatedName&&(P=ab(e.attr,r.tfDeprecatedName,r.defaultValue));break;case"shape[]":P=sb(e.attr,r.tfName,r.defaultValue),void 0===P&&r.tfDeprecatedName&&(P=sb(e.attr,r.tfDeprecatedName,r.defaultValue));break;case"dtype":P=rb(e.attr,r.tfName,r.defaultValue),void 0===P&&r.tfDeprecatedName&&(P=rb(e.attr,r.tfDeprecatedName,r.defaultValue));break;case"dtype[]":P=nb(e.attr,r.tfName,r.defaultValue),void 0===P&&r.tfDeprecatedName&&(P=nb(e.attr,r.tfDeprecatedName,r.defaultValue));break;case"func":P=tb(e.attr,r.tfName,r.defaultValue),void 0===P&&r.tfDeprecatedName&&(P=tb(e.attr,r.tfDeprecatedName,r.defaultValue));break;case"tensor":case"tensors":break;default:throw new Error(`Unsupported param type: ${r.type} for op: ${e.op}`)}return t[r.name]={value:P,type:n},t}),{})),r}mapFunction(e){const t=e.nodeDef,r=[];let n={};null!=t&&(n=t.reduce(((e,t)=>(e[t.name]=this.mapNode(t),"Const"===t.op&&r.push(e[t.name]),e)),{}));const P=[],a=[];e.signature.inputArg.forEach((e=>{const[t]=yg(e.name),r={name:t,op:"Placeholder",inputs:[],inputNames:[],category:"graph",inputParams:{},attrParams:{dtype:{value:eb(e.type),type:"dtype"}},children:[]};r.signatureKey=e.name,P.push(r),n[t]=r}));Object.keys(n).forEach((e=>{const t=n[e];t.inputNames.forEach(((e,r)=>{const[P,,a]=yg(e),o=n[P];if(null!=o.outputs){const e=o.outputs.indexOf(a);if(-1!==e){const n=`${P}:${e}`;t.inputNames[r]=n}}t.inputs.push(o),o.children.push(t)}))}));const o=e.ret;e.signature.outputArg.forEach((e=>{const[t,r]=yg(o[e.name]),P=n[t];null!=P&&(P.defaultOutput=r,a.push(P))}));const u=this.mapArgsToSignature(e);return{nodes:n,inputs:P,outputs:a,weights:r,placeholders:[],signature:u}}mapArgsToSignature(e){return{methodName:e.signature.name,inputs:e.signature.inputArg.reduce(((e,t)=>(e[t.name]=this.mapArgToTensorInfo(t),e)),{}),outputs:e.signature.outputArg.reduce(((t,r)=>(t[r.name]=this.mapArgToTensorInfo(r,e.ret),t)),{})}}mapArgToTensorInfo(e,t){let r=e.name;return null!=t&&(r=t[r]),{name:r,dtype:e.type}}}function Xg(e){const t=mt().global;if(void 0!==t.atob)return t.atob(e);if("undefined"!=typeof Buffer)return new Buffer(e,"base64").toString();throw new Error("Unable to decode base64 in this environment. Missing built-in atob() or Buffer()")}function Hg(e,t){const r=Array.isArray(e)?String.fromCharCode.apply(null,e):Xg(e);return t?r:r.toLowerCase()}function Jg(e,t,r,n=!1){const P=e[t];return null!=P?Hg(P.s,n):r}function _g(e,t,r){const n=e[t];return n?n.b:r}function $g(e,t,r){const n=e[t]||{},P=null!=n.i?n.i:null!=n.f?n.f:r;return"number"==typeof P?P:parseInt(P,10)}function eb(e){switch("string"==typeof e&&(e=B[e]),e){case B.DT_FLOAT:case B.DT_HALF:return"float32";case B.DT_INT32:case B.DT_INT64:case B.DT_INT8:case B.DT_UINT8:return"int32";case B.DT_BOOL:return"bool";case B.DT_DOUBLE:return"float32";case B.DT_STRING:return"string";default:return null}}function tb(e,t,r){const n=e[t];return n&&n.func?n.func.name:r}function rb(e,t,r){const n=e[t];return n&&n.type?eb(n.type):r}function nb(e,t,r){const n=e[t];return n&&n.list&&n.list.type?n.list.type.map((e=>eb(e))):r}function Pb(e){if(!e.unknownRank)return null!=e.dim?e.dim.map((e=>"number"==typeof e.size?e.size:parseInt(e.size,10))):[]}function ab(e,t,r){const n=e[t];return n&&n.shape?Pb(n.shape):r}function ob(e,t,r){const n=e[t];return n?((n.list.f&&n.list.f.length?n.list.f:n.list.i)||[]).map((e=>"number"==typeof e?e:parseInt(e,10))):r}function ub(e,t,r,n=!1){const P=e[t];return P&&P.list&&P.list.s?P.list.s.map((e=>Hg(e,n))):r}function sb(e,t,r){const n=e[t];return n&&n.list&&n.list.shape?n.list.shape.map((e=>Pb(e))):r}function vb(e,t,r){const n=e[t];return n&&n.list&&n.list.b?n.list.b:r}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class ib{constructor(e,t,r){this.node=e,this.tensorMap=t,this.context=r,this.inputs=[],this.attrs={},this.inputs=e.inputNames.map((e=>this.getInput(e))),null!=e.rawAttrs&&(this.attrs=Object.keys(e.rawAttrs).reduce(((e,t)=>(e[t]=this.getAttr(t),e)),{}))}getInput(e){return zg(e,this.tensorMap,this.context)}getAttr(e,t){const r=this.node.rawAttrs[e];if(null!=r.tensor)return zg(e,this.tensorMap,this.context);if(null!=r.i||null!=r.f)return $g(this.node.rawAttrs,e,t);if(null!=r.s)return Jg(this.node.rawAttrs,e,t);if(null!=r.b)return _g(this.node.rawAttrs,e,t);if(null!=r.shape)return ab(this.node.rawAttrs,e,t);if(null!=r.type)return rb(this.node.rawAttrs,e,t);if(null!=r.list){if(null!=r.list.i||null!=r.list.f)return ob(this.node.rawAttrs,e,t);if(null!=r.list.s)return ub(this.node.rawAttrs,e,t);if(null!=r.list.shape)return sb(this.node.rawAttrs,e,t);if(null!=r.list.b)return vb(this.node.rawAttrs,e,t);if(null!=r.list.type)return nb(this.node.rawAttrs,e,t)}return t}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */var Oe=Object.freeze({__proto__:null,abs:Bs,acos:Vs,acosh:Hs,add:Us,addN:_s,all:ev,any:rv,argMax:Pv,argMin:ov,asin:sv,asinh:iv,atan:cv,atan2:Dv,atanh:hv,avgPool:Uv,avgPool3d:Gv,basicLSTMCell:Hv,batchToSpaceND:_v,batchNorm:ti,batchNorm2d:ni,batchNorm3d:ai,batchNorm4d:ui,bincount:vi,broadcastArgs:li,broadcastTo:Oi,buffer:au,cast:uu,ceil:ji,clipByValue:pi,clone:vu,complex:Ja,concat:Kv,concat1d:gi,concat2d:Ti,concat3d:di,concat4d:wi,conv1d:Si,conv2d:fi,conv2dTranspose:ki,conv3d:Ei,conv3dTranspose:qi,cos:Mi,cosh:Ni,cumprod:Fi,cumsum:Zi,denseBincount:Xi,depthToSpace:Ji,depthwiseConv2d:$i,diag:tl,dilation2d:nl,div:Ks,divNoNan:ll,dot:Ol,einsum:jl,elu:pl,equal:al,erf:gl,euclideanNorm:Fl,exp:Zl,expandDims:Xl,expm1:Jl,eye:tc,fill:rc,floor:Pc,floorDiv:Gs,gather:oc,greater:sc,greaterEqual:ic,imag:Hu,isFinite:cc,isInf:Dc,isNaN:hc,leakyRelu:mc,less:bc,lessEqual:zc,linspace:dc,localResponseNormalization:wc,log:fc,log1p:Sc,logSigmoid:Ec,logSoftmax:qc,logSumExp:Mc,logicalAnd:Nc,logicalNot:Fc,logicalOr:Zc,logicalXor:Xc,lowerBound:$c,matMul:Gu,max:Sl,maxPool:tO,maxPool3d:nO,maxPoolWithArgmax:aO,maximum:uO,mean:vO,meshgrid:cO,min:xl,minimum:DO,mirrorPad:hO,mod:mO,moments:bO,mul:Rs,multiRNNCell:zO,multinomial:yO,neg:_u,notEqual:LO,oneHot:Ku,ones:lO,onesLike:IO,outerProduct:AO,pad:YO,pad1d:CO,pad2d:QO,pad3d:UO,pad4d:GO,pool:BO,pow:kl,prelu:VO,print:iu,prod:HO,rand:_O,randomGamma:nD,randomNormal:aD,randomStandardNormal:uD,randomUniform:vD,range:iD,real:es,reciprocal:cD,relu:DD,relu6:hD,reshape:Qv,reverse:mD,reverse1d:bD,reverse2d:zD,reverse3d:yD,reverse4d:LD,round:ID,rsqrt:AD,scalar:Cl,selu:YD,separableConv2d:CD,setdiff1dAsync:QD,sigmoid:Rv,sign:UD,sin:GD,sinh:KD,slice:Bv,slice1d:RD,slice2d:BD,slice3d:VD,slice4d:HD,softmax:_D,softplus:kc,spaceToBatchND:KO,fft:ej,ifft:rj,irfft:Pj,rfft:sj,split:oj,sqrt:Ql,square:Ul,squaredDifference:ij,squeeze:cj,stack:Dj,step:hj,stridedSlice:mj,sub:Wc,sum:Gl,tan:bj,tanh:Vv,tensor:$a,tensor1d:Tj,tensor2d:zj,tensor3d:us,tensor4d:dj,tensor5d:yj,tensor6d:wj,tile:$l,topk:fj,truncatedNormal:Sj,unique:xj,unsortedSegmentSum:kj,unstack:Ej,upperBound:Qj,variable:Wj,where:ul,whereAsync:Gj,zeros:iO,zerosLike:vl,op:Xa,OP_SCOPE_SUFFIX:Va,booleanMaskAsync:Kj,transpose:rs,norm:Nl,movingAverage:Rj,scatterND:Bj,searchSorted:_c,sparseToDense:Xj,gatherND:Jj,dropout:eh,enclosingPowerOfTwo:th,cosineWindow:rh,inTopKAsync:Ph,image:am,linalg:om,losses:um,spectral:nm,fused:K,signal:Pm,sparse:sm,string:vm});
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const lb=(e,t,r,n=Oe)=>{switch(e.op){case"BiasAdd":case"AddV2":case"Add":return[n.add(Tg("a",e,t,r),Tg("b",e,t,r))];case"AddN":return[n.addN(Tg("tensors",e,t,r))];case"FloorMod":case"Mod":return[n.mod(Tg("a",e,t,r),Tg("b",e,t,r))];case"Mul":return[n.mul(Tg("a",e,t,r),Tg("b",e,t,r))];case"RealDiv":case"Div":return[n.div(Tg("a",e,t,r),Tg("b",e,t,r))];case"DivNoNan":return[n.divNoNan(Tg("a",e,t,r),Tg("b",e,t,r))];case"FloorDiv":return[n.floorDiv(Tg("a",e,t,r),Tg("b",e,t,r))];case"Sub":return[n.sub(Tg("a",e,t,r),Tg("b",e,t,r))];case"Minimum":return[n.minimum(Tg("a",e,t,r),Tg("b",e,t,r))];case"Maximum":return[n.maximum(Tg("a",e,t,r),Tg("b",e,t,r))];case"Pow":return[n.pow(Tg("a",e,t,r),Tg("b",e,t,r))];case"SquaredDifference":return[n.squaredDifference(Tg("a",e,t,r),Tg("b",e,t,r))];default:throw TypeError(`Node type ${e.op} is not implemented`)}},cb=(e,t,r,n=Oe)=>{switch(e.op){case"Abs":case"ComplexAbs":return[n.abs(Tg("x",e,t,r))];case"Acos":return[n.acos(Tg("x",e,t,r))];case"Acosh":return[n.acosh(Tg("x",e,t,r))];case"Asin":return[n.asin(Tg("x",e,t,r))];case"Asinh":return[n.asinh(Tg("x",e,t,r))];case"Atan":return[n.atan(Tg("x",e,t,r))];case"Atan2":return[n.atan2(Tg("x",e,t,r),Tg("y",e,t,r))];case"Atanh":return[n.atanh(Tg("x",e,t,r))];case"Ceil":return[n.ceil(Tg("x",e,t,r))];case"Complex":return[n.complex(Tg("real",e,t,r),Tg("imag",e,t,r))];case"Cos":return[n.cos(Tg("x",e,t,r))];case"Cosh":return[n.cosh(Tg("x",e,t,r))];case"Elu":return[n.elu(Tg("x",e,t,r))];case"Erf":return[n.erf(Tg("x",e,t,r))];case"Exp":return[n.exp(Tg("x",e,t,r))];case"Expm1":return[n.expm1(Tg("x",e,t,r))];case"Floor":return[n.floor(Tg("x",e,t,r))];case"Log":return[n.log(Tg("x",e,t,r))];case"Log1p":return[n.log1p(Tg("x",e,t,r))];case"Imag":return[n.imag(Tg("x",e,t,r))];case"Neg":return[n.neg(Tg("x",e,t,r))];case"Reciprocal":return[n.reciprocal(Tg("x",e,t,r))];case"Real":return[n.real(Tg("x",e,t,r))];case"Relu":return[n.relu(Tg("x",e,t,r))];case"Round":return[n.round(Tg("x",e,t,r))];case"Selu":return[n.selu(Tg("x",e,t,r))];case"Sigmoid":return[n.sigmoid(Tg("x",e,t,r))];case"Sin":return[n.sin(Tg("x",e,t,r))];case"Sign":return[n.sign(Tg("x",e,t,r))];case"Sinh":return[n.sinh(Tg("x",e,t,r))];case"Softplus":return[n.softplus(Tg("x",e,t,r))];case"Sqrt":return[n.sqrt(Tg("x",e,t,r))];case"Square":return[n.square(Tg("x",e,t,r))];case"Tanh":return[n.tanh(Tg("x",e,t,r))];case"Tan":return[n.tan(Tg("x",e,t,r))];case"ClipByValue":return[n.clipByValue(Tg("x",e,t,r),Tg("clipValueMin",e,t,r),Tg("clipValueMax",e,t,r))];case"Relu6":return[n.relu6(Tg("x",e,t,r))];case"Rsqrt":return[n.rsqrt(zg(e.inputNames[0],t,r))];case"Prod":return[n.prod(Tg("x",e,t,r),Tg("axes",e,t,r))];case"LeakyRelu":return[n.leakyRelu(Tg("x",e,t,r),Tg("alpha",e,t,r))];case"Prelu":return[n.prelu(Tg("x",e,t,r),Tg("alpha",e,t,r))];case"IsNan":return[n.isNaN(zg(e.inputNames[0],t,r))];default:throw TypeError(`Node type ${e.op} is not implemented`)}};
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function Ob(e,t,r=""){if("number"!=typeof e&&"number"!=typeof t){xe(e.length===t.length,(()=>r+` Shapes ${e} and ${t} must match`));for(let n=0;n<e.length;n++){const P=e[n],a=t[n];xe(P<0||a<0||P===a,(()=>r+` Shapes ${e} and ${t} must match`))}}}function Db(e){return"number"!=typeof e&&!e.some((e=>e<0))}function jb(e,t,r){let n=hb(e,r);const P=!Db(n);if(P&&0===t.length)throw new Error(`Tried to calculate elements of an empty list with non-fully-defined elementShape: ${n}`);if(P&&t.forEach((e=>{n=hb(e.shape,n)})),!Db(n))throw new Error(`Non-fully-defined elementShape: ${n}`);return n}function hb(e,t){if("number"==typeof e)return t;if("number"==typeof t)return e;if(e.length!==t.length)throw new Error(`Incompatible ranks during merge: ${e} vs. ${t}`);const r=[];for(let n=0;n<e.length;++n){const P=e[n],a=t[n];if(P>=0&&a>=0&&P!==a)throw new Error(`Incompatible shape during merge: ${e} vs. ${t}`);r[n]=P>=0?P:a}return r}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class pb{constructor(e,t,r,n,P,a,o){this.name=e,this.dtype=t,this.maxSize=r,this.elementShape=n,this.identicalElementShapes=P,this.dynamicSize=a,this.clearAfterRead=o,this.tensors=[],this.closed_=!1,this.idTensor=Cl(0),Zu(this.idTensor)}get id(){return this.idTensor.id}get closed(){return this.closed_}clearAndClose(e){this.tensors.forEach((t=>{null!=e&&e.has(t.tensor.id)||t.tensor.dispose()})),this.tensors=[],this.closed_=!0,this.idTensor.dispose()}size(){return this.tensors.length}read(e){if(this.closed_)throw new Error(`TensorArray ${this.name} has already been closed.`);if(e<0||e>=this.size())throw new Error(`Tried to read from index ${e}, but array size is: ${this.size()}`);const t=this.tensors[e];if(t.cleared)throw new Error(`TensorArray ${this.name}: Could not read index ${e} twice because it was cleared after a previous read (perhaps try setting clear_after_read = false?).`);return this.clearAfterRead&&(t.cleared=!0),t.read=!0,t.tensor}readMany(e){return e.map((e=>this.read(e)))}write(e,t){if(this.closed_)throw new Error(`TensorArray ${this.name} has already been closed.`);if(e<0||!this.dynamicSize&&e>=this.maxSize)throw new Error(`Tried to write to index ${e}, but array is not resizeable and size is: ${this.maxSize}`);const r=this.tensors[e]||{};if(t.dtype!==this.dtype)throw new Error(`TensorArray ${this.name}: Could not write to TensorArray index ${e},\n          because the value dtype is ${t.dtype}, but TensorArray dtype is ${this.dtype}.`);if(0!==this.size()||null!=this.elementShape&&0!==this.elementShape.length||(this.elementShape=t.shape),Ob(this.elementShape,t.shape,`TensorArray ${this.name}: Could not write to TensorArray index ${e}.`),r.read)throw new Error(`TensorArray ${this.name}: Could not write to TensorArray index ${e}, because it has already been read.`);if(r.written)throw new Error(`TensorArray ${this.name}: Could not write to TensorArray index ${e}, because it has already been written.`);r.tensor=t,Zu(t),r.written=!0,this.tensors[e]=r}writeMany(e,t){if(e.length!==t.length)throw new Error(`TensorArray ${this.name}: could not write multiple tensors,because the index size: ${e.length} is not the same as tensors size: ${t.length}.`);e.forEach(((e,r)=>this.write(e,t[r])))}gather(e,t){if(t&&t!==this.dtype)throw new Error(`TensorArray dtype is ${this.dtype} but gather requested dtype ${t}`);if(e)e=e.slice(0,this.size());else{e=[];for(let t=0;t<this.size();t++)e.push(t)}if(0===e.length)return $a([],[0].concat(this.elementShape));const r=this.readMany(e);return Ob(this.elementShape,r[0].shape,"TensorArray shape mismatch: "),Dj(r,0)}concat(e){if(e&&e!==this.dtype)throw new Error(`TensorArray dtype is ${this.dtype} but concat requested dtype ${e}`);if(0===this.size())return $a([],[0].concat(this.elementShape));const t=[];for(let e=0;e<this.size();e++)t.push(e);const r=this.readMany(t);return Ob(this.elementShape,r[0].shape,`TensorArray shape mismatch: tensor array shape (${this.elementShape}) vs first tensor shape (${r[0].shape})`),Kv(r,0)}scatter(e,t){if(t.dtype!==this.dtype)throw new Error(`TensorArray dtype is ${this.dtype} but tensor has dtype ${t.dtype}`);if(e.length!==t.shape[0])throw new Error(`Expected len(indices) == tensor.shape[0], but saw: ${e.length} vs. ${t.shape[0]}`);const r=Math.max(...e);if(!this.dynamicSize&&r>=this.maxSize)throw new Error(`Max index must be < array size (${r}  vs. ${this.maxSize})`);this.writeMany(e,Ej(t,0))}split(e,t){if(t.dtype!==this.dtype)throw new Error(`TensorArray dtype is ${this.dtype} but tensor has dtype ${t.dtype}`);let r=0;const n=e.map((e=>(r+=e,r)));if(r!==t.shape[0])throw new Error(`Expected sum of lengths to be equal to\n          tensor.shape[0], but sum of lengths is\n        ${r}, and tensor's shape is: ${t.shape}`);if(!this.dynamicSize&&e.length!==this.maxSize)throw new Error(`TensorArray's size is not equal to the size of lengths (${this.maxSize} vs. ${e.length}), and the TensorArray is not marked as dynamically resizeable`);const P=0===r?0:t.size/r,a=[];Fu((()=>{t=Qv(t,[1,r,P]);for(let r=0;r<e.length;++r){const o=[0,0===r?0:n[r-1],0],u=[1,e[r],P];a[r]=Qv(Bv(t,o,u),this.elementShape)}return a}));const o=[];for(let t=0;t<e.length;t++)o[t]=t;this.writeMany(o,a)}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class mb{constructor(e,t,r,n=-1){this.tensors=e,this.elementShape=t,this.elementDtype=r,null!=e&&e.forEach((e=>{if(r!==e.dtype)throw new Error(`Invalid data types; op elements ${r}, but list elements ${e.dtype}`);Ob(t,e.shape,"TensorList shape mismatch: "),Zu(e)})),this.idTensor=Cl(0),this.maxNumElements=n,Zu(this.idTensor)}get id(){return this.idTensor.id}copy(){return new mb([...this.tensors],this.elementShape,this.elementDtype)}clearAndClose(e){this.tensors.forEach((t=>{null!=e&&e.has(t.id)||t.dispose()})),this.tensors.length=0,this.idTensor.dispose()}size(){return this.tensors.length}stack(e,t,r=-1){if(t!==this.elementDtype)throw new Error(`Invalid data types; op elements ${t}, but list elements ${this.elementDtype}`);if(-1!==r&&this.tensors.length!==r)throw new Error(`Operation expected a list with ${r} elements but got a list with ${this.tensors.length} elements.`);Ob(e,this.elementShape,"TensorList shape mismatch: ");const n=jb(this.elementShape,this.tensors,e);return Fu((()=>{const e=this.tensors.map((e=>Qv(e,n)));return Dj(e,0)}))}popBack(e,t){if(t!==this.elementDtype)throw new Error(`Invalid data types; op elements ${t}, but list elements ${this.elementDtype}`);if(0===this.size())throw new Error("Trying to pop from an empty list.");const r=jb(this.elementShape,this.tensors,e),n=this.tensors.pop();return Ob(n.shape,e,"TensorList shape mismatch: "),Qv(n,r)}pushBack(e){if(e.dtype!==this.elementDtype)throw new Error(`Invalid data types; op elements ${e.dtype}, but list elements ${this.elementDtype}`);if(Ob(e.shape,this.elementShape,"TensorList shape mismatch: "),this.maxNumElements===this.size())throw new Error("Trying to push element into a full list.");Zu(e),this.tensors.push(e)}resize(e){if(e<0)throw new Error(`TensorListResize expects size to be non-negative. Got: ${e}`);if(-1!==this.maxNumElements&&e>this.maxNumElements)throw new Error(`TensorListResize input size ${e} is greater maxNumElement ${this.maxNumElements}.`);const t=new mb([],this.elementShape,this.elementDtype,this.maxNumElements);t.tensors.length=e;for(let r=0;r<Math.min(this.tensors.length,e);++r)t.tensors[r]=this.tensors[r];return t}getItem(e,t,r){if(r!==this.elementDtype)throw new Error(`Invalid data types; op elements ${r}, but list elements ${this.elementDtype}`);if(e<0||e>this.tensors.length)throw new Error(`Trying to access element ${e} in a list with ${this.tensors.length} elements.`);if(null==this.tensors[e])throw new Error(`element at index ${e} is null.`);Ob(this.tensors[e].shape,t,"TensorList shape mismatch: ");const n=jb(this.elementShape,this.tensors,t);return Qv(this.tensors[e],n)}setItem(e,t){if(t.dtype!==this.elementDtype)throw new Error(`Invalid data types; op elements ${t.dtype}, but list elements ${this.elementDtype}`);if(e<0||-1!==this.maxNumElements&&e>=this.maxNumElements)throw new Error(`Trying to set element ${e} in a list with max ${this.maxNumElements} elements.`);Ob(this.elementShape,t.shape,"TensorList shape mismatch: "),Zu(t),this.tensors[e]=t}gather(e,t,r){if(t!==this.elementDtype)throw new Error(`Invalid data types; op elements ${t}, but list elements ${this.elementDtype}`);Ob(this.elementShape,r,"TensorList shape mismatch: "),e=e.slice(0,this.size());const n=jb(this.elementShape,this.tensors,r);return 0===e.length?$a([],[0].concat(n)):Fu((()=>{const t=e.map((e=>Qv(this.tensors[e],n)));return Dj(t,0)}))}concat(e,t){if(e&&e!==this.elementDtype)throw new Error(`TensorList dtype is ${this.elementDtype} but concat requested dtype ${e}`);Ob(this.elementShape,t,"TensorList shape mismatch: ");const r=jb(this.elementShape,this.tensors,t);return 0===this.size()?$a([],[0].concat(r)):Fu((()=>{const e=this.tensors.map((e=>Qv(e,r)));return Kv(e,0)}))}}function gb(e,t,r){const n=e.dtype;if(e.shape.length<1)throw new Error(`Tensor must be at least a vector, but saw shape: ${e.shape}`);if(e.dtype!==r)throw new Error(`Invalid data types; op elements ${e.dtype}, but list elements ${r}`);Ob(e.shape.slice(1),t,"TensorList shape mismatch: ");const P=Ej(e);return new mb(P,t,n)}function bb(e,t,r,n){return new mb([],e,t,n)}function Tb(e,t,r,n){if(t.length!==e.shape[0])throw new Error(`Expected len(indices) == tensor.shape[0], but saw: ${t.length} vs. ${e.shape[0]}`);const P=Math.max(...t);if(null!=n&&-1!==n&&P>=n)throw new Error(`Max index must be < array size (${P}  vs. ${n})`);const a=new mb([],r,e.dtype,n),o=Ej(e,0);return t.forEach(((e,t)=>{a.setItem(e,o[t])})),a}function zb(e,t,r){let n=0;const P=t.map((e=>(n+=e,n)));if(n!==e.shape[0])throw new Error(`Expected sum of lengths to be equal to\n          tensor.shape[0], but sum of lengths is\n        ${n}, and tensor's shape is: ${e.shape}`);const a=hb(e.shape.slice(1),r),o=0===n?0:e.size/n,u=Fu((()=>{const r=[];e=Qv(e,[1,n,o]);for(let n=0;n<t.length;++n){const u=[0,0===n?0:P[n-1],0],s=[1,t[n],o];r[n]=Qv(Bv(e,u,s),a)}return e.dispose(),r})),s=new mb([],r,e.dtype,t.length);for(let e=0;e<u.length;e++)s.setItem(e,u[e]);return s}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const db=async(e,t,r)=>{switch(e.op){case"If":case"StatelessIf":{const n=Tg("thenBranch",e,t,r),P=Tg("elseBranch",e,t,r),a=Tg("cond",e,t,r),o=Tg("args",e,t,r);return(await a.data())[0]?r.functionMap[n].executeFunctionAsync(o,r.tensorArrayMap,r.tensorListMap):r.functionMap[P].executeFunctionAsync(o,r.tensorArrayMap,r.tensorListMap)}case"While":case"StatelessWhile":{const n=Tg("body",e,t,r),P=Tg("cond",e,t,r),a=Tg("args",e,t,r),o=await r.functionMap[P].executeFunctionAsync(a,r.tensorArrayMap,r.tensorListMap),u=a.map((e=>e.id));let s=await o[0].data();o.forEach((e=>{e.kept||-1!==u.indexOf(e.id)||e.dispose()}));let v=a;for(;s[0];){const e=v;v=await r.functionMap[n].executeFunctionAsync(v,r.tensorArrayMap,r.tensorListMap);const t=v.map((e=>e.id));e.forEach((e=>{e.kept||-1!==u.indexOf(e.id)||-1!==t.indexOf(e.id)||e.dispose()}));const a=await r.functionMap[P].executeFunctionAsync(v,r.tensorArrayMap,r.tensorListMap);s=await a[0].data(),a.forEach((e=>{e.kept||-1!==u.indexOf(e.id)||-1!==t.indexOf(e.id)||e.dispose()}))}return v}case"LoopCond":return[Ig(Tg("pred",e,t,r))];case"Switch":{const n=Tg("pred",e,t,r);let P=Tg("data",e,t,r);return P.kept||(P=Ig(P)),(await n.data())[0]?[void 0,P]:[P,void 0]}case"Merge":{const n=e.inputNames.find((e=>void 0!==zg(e,t,r)));if(n){return[Ig(zg(n,t,r))]}return}case"Enter":{const n=Tg("frameName",e,t,r),P=Tg("tensor",e,t,r);return r.enterFrame(n),[Ig(P)]}case"Exit":{const n=Tg("tensor",e,t,r);return r.exitFrame(),[Ig(n)]}case"NextIteration":{const n=Tg("tensor",e,t,r);return r.nextIteration(),[Ig(n)]}case"TensorArrayV3":{const n=Tg("size",e,t,r),P=Tg("dtype",e,t,r),a=Tg("elementShape",e,t,r),o=Tg("dynamicSize",e,t,r),u=Tg("clearAfterRead",e,t,r),s=Tg("identicalElementShapes",e,t,r),v=Tg("name",e,t,r),i=new pb(v,P,n,a,s,o,u);return r.addTensorArray(i),[i.idTensor,Cl(1)]}case"TensorArrayWriteV3":{const n=Tg("tensorArrayId",e,t,r),P=Tg("index",e,t,r),a=Tg("tensor",e,t,r),o=r.getTensorArray(n.id);return o.write(P,a),[o.idTensor]}case"TensorArrayReadV3":{const n=Tg("tensorArrayId",e,t,r),P=Tg("index",e,t,r);return[r.getTensorArray(n.id).read(P)]}case"TensorArrayGatherV3":{const n=Tg("tensorArrayId",e,t,r),P=Tg("indices",e,t,r),a=Tg("dtype",e,t,r);return[r.getTensorArray(n.id).gather(P,a)]}case"TensorArrayScatterV3":{const n=Tg("tensorArrayId",e,t,r),P=Tg("indices",e,t,r),a=Tg("tensor",e,t,r),o=r.getTensorArray(n.id);return o.scatter(P,a),[o.idTensor]}case"TensorArrayConcatV3":{const n=Tg("tensorArrayId",e,t,r),P=r.getTensorArray(n.id),a=Tg("dtype",e,t,r);return[P.concat(a)]}case"TensorArraySplitV3":{const n=Tg("tensorArrayId",e,t,r),P=Tg("tensor",e,t,r),a=Tg("lengths",e,t,r),o=r.getTensorArray(n.id);return o.split(a,P),[o.idTensor]}case"TensorArraySizeV3":{const n=Tg("tensorArrayId",e,t,r);return[Cl(r.getTensorArray(n.id).size(),"int32")]}case"TensorArrayCloseV3":{const n=Tg("tensorArrayId",e,t,r),P=r.getTensorArray(n.id);return P.clearAndClose(),[P.idTensor]}case"TensorListSetItem":{const n=Tg("tensorListId",e,t,r),P=Tg("index",e,t,r),a=Tg("tensor",e,t,r),o=r.getTensorList(n.id);return o.setItem(P,a),[o.idTensor]}case"TensorListGetItem":{const n=Tg("tensorListId",e,t,r),P=Tg("index",e,t,r),a=Tg("elementShape",e,t,r),o=Tg("elementDType",e,t,r);return[r.getTensorList(n.id).getItem(P,a,o)]}case"TensorListScatterV2":case"TensorListScatter":{const n=Tg("indices",e,t,r),P=Tb(Tg("tensor",e,t,r),n,Tg("elementShape",e,t,r),Tg("numElements",e,t,r));return r.addTensorList(P),[P.idTensor]}case"TensorListReserve":case"EmptyTensorList":{const n=Tg("elementShape",e,t,r),P=Tg("elementDType",e,t,r);let a;a="TensorListReserve"===e.op?"numElements":"maxNumElements";const o=Tg(a,e,t,r),u=bb(n,P,0,"TensorListReserve"===e.op?-1:o);return r.addTensorList(u),[u.idTensor]}case"TensorListGather":{const n=Tg("tensorListId",e,t,r),P=Tg("indices",e,t,r),a=Tg("elementShape",e,t,r),o=Tg("elementDType",e,t,r);return[r.getTensorList(n.id).gather(P,o,a)]}case"TensorListStack":{const n=Tg("tensorListId",e,t,r),P=Tg("elementShape",e,t,r),a=Tg("elementDType",e,t,r),o=Tg("numElements",e,t,r);return[r.getTensorList(n.id).stack(P,a,o)]}case"TensorListFromTensor":{const n=gb(Tg("tensor",e,t,r),Tg("elementShape",e,t,r),Tg("elementDType",e,t,r));return r.addTensorList(n),[n.idTensor]}case"TensorListConcat":case"TensorListConcatV2":{const n=Tg("tensorListId",e,t,r),P=r.getTensorList(n.id),a=Tg("dtype",e,t,r),o=Tg("elementShape",e,t,r);return[P.concat(a,o)]}case"TensorListPushBack":{const n=Tg("tensorListId",e,t,r),P=Tg("tensor",e,t,r),a=r.getTensorList(n.id);return a.pushBack(P),[a.idTensor]}case"TensorListPopBack":{const n=Tg("tensorListId",e,t,r),P=Tg("elementShape",e,t,r),a=Tg("elementDType",e,t,r);return[r.getTensorList(n.id).popBack(P,a)]}case"TensorListSplit":{const n=Tg("tensor",e,t,r),P=Tg("elementShape",e,t,r),a=zb(n,Tg("lengths",e,t,r),P);return r.addTensorList(a),[a.idTensor]}case"TensorListLength":{const n=Tg("tensorListId",e,t,r);return[Cl(r.getTensorList(n.id).size(),"int32")]}case"TensorListResize":{const n=Tg("tensorListId",e,t,r),P=Tg("size",e,t,r),a=r.getTensorList(n.id).resize(P);return r.addTensorList(a),[a.idTensor]}default:throw TypeError(`Node type ${e.op} is not implemented`)}};
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function yb(e,t,r){const[n,P]=Tg("fusedOps",e,t,r),a="biasadd"===n,o=!a,u="prelu"===P,s="fusedbatchnorm"===n,v=Tg("numArgs",e,t,r);if(a){if(u&&2!==v)throw new Error("FusedConv2d and DepthwiseConv2d with BiasAdd and Prelu must have two extra arguments: bias and alpha.");if(!u&&a&&1!==v)throw new Error("FusedConv2d and DepthwiseConv2d with BiasAdd must have one extra argument: bias.")}if(s)throw new Error("FusedConv2d and DepthwiseConv2d with FusedBatchNorm is not supported");const i=Tg("strides",e,t,r),l=fg(e,t,r),c=Tg("dataFormat",e,t,r).toUpperCase(),O=Tg("dilations",e,t,r);let[D,j]=Tg("args",e,t,r);o&&(j=D,D=void 0);return{stride:i,pad:l,dataFormat:c,dilations:O,biasArg:D,preluArg:j,activationFunc:P,leakyreluAlpha:Tg("leakyreluAlpha",e,t,r)}}const wb=(e,t,r,n=Oe)=>{switch(e.op){case"Conv1D":{const P=Tg("stride",e,t,r),a=Tg("pad",e,t,r),o=Tg("dataFormat",e,t,r).toUpperCase(),u=Tg("dilation",e,t,r);return[n.conv1d(Tg("x",e,t,r),Tg("filter",e,t,r),P,a,o,u)]}case"Conv2D":{const P=Tg("strides",e,t,r),a=fg(e,t,r),o=Tg("dataFormat",e,t,r).toUpperCase(),u=Tg("dilations",e,t,r);return[n.conv2d(Tg("x",e,t,r),Tg("filter",e,t,r),[P[1],P[2]],a,o,[u[1],u[2]])]}case"_FusedConv2D":{const{stride:P,pad:a,dataFormat:o,dilations:u,biasArg:s,preluArg:v,activationFunc:i,leakyreluAlpha:l}=yb(e,t,r);return[n.fused.conv2d({x:Tg("x",e,t,r),filter:Tg("filter",e,t,r),strides:[P[1],P[2]],pad:a,dataFormat:o,dilations:[u[1],u[2]],bias:s,activation:i,preluActivationWeights:v,leakyreluAlpha:l})]}case"FusedDepthwiseConv2dNative":{const{stride:P,pad:a,dataFormat:o,dilations:u,biasArg:s,preluArg:v,activationFunc:i,leakyreluAlpha:l}=yb(e,t,r);return[n.fused.depthwiseConv2d({x:Tg("x",e,t,r),filter:Tg("filter",e,t,r),strides:[P[1],P[2]],pad:a,dataFormat:o,dilations:[u[1],u[2]],bias:s,activation:i,preluActivationWeights:v,leakyreluAlpha:l})]}case"Conv2DBackpropInput":case"Conv2dTranspose":{const P=Tg("outputShape",e,t,r),a=Tg("strides",e,t,r),o=fg(e,t,r);return[n.conv2dTranspose(Tg("x",e,t,r),Tg("filter",e,t,r),P,[a[1],a[2]],o)]}case"DepthwiseConv2dNative":case"DepthwiseConv2d":{const P=Tg("strides",e,t,r),a=fg(e,t,r),o=Tg("dilations",e,t,r),u=Tg("dataFormat",e,t,r).toUpperCase();return[n.depthwiseConv2d(Tg("input",e,t,r),Tg("filter",e,t,r),[P[1],P[2]],a,u,[o[1],o[2]])]}case"Conv3D":{const P=Tg("strides",e,t,r),a=Tg("pad",e,t,r),o=Tg("dataFormat",e,t,r).toUpperCase(),u=Tg("dilations",e,t,r);return[n.conv3d(Tg("x",e,t,r),Tg("filter",e,t,r),[P[1],P[2],P[3]],a,o,[u[1],u[2],u[3]])]}case"AvgPool":{const P=Tg("strides",e,t,r),a=Tg("pad",e,t,r),o=Tg("kernelSize",e,t,r);return[n.avgPool(Tg("x",e,t,r),[o[1],o[2]],[P[1],P[2]],a)]}case"MaxPool":{const P=Tg("strides",e,t,r),a=Tg("pad",e,t,r),o=Tg("kernelSize",e,t,r);return[n.maxPool(Tg("x",e,t,r),[o[1],o[2]],[P[1],P[2]],a)]}case"MaxPoolWithArgmax":{const P=Tg("strides",e,t,r),a=Tg("pad",e,t,r),o=Tg("kernelSize",e,t,r),u=Tg("includeBatchInIndex",e,t,r),{result:s,indexes:v}=n.maxPoolWithArgmax(Tg("x",e,t,r),[o[1],o[2]],[P[1],P[2]],a,u);return[s,v]}case"AvgPool3D":{const P=Tg("strides",e,t,r),a=Tg("pad",e,t,r),o=Tg("kernelSize",e,t,r);return[n.avgPool3d(Tg("x",e,t,r),[o[1],o[2],o[3]],[P[1],P[2],P[3]],a)]}case"MaxPool3D":{const P=Tg("strides",e,t,r),a=Tg("pad",e,t,r),o=Tg("kernelSize",e,t,r);return[n.maxPool3d(Tg("x",e,t,r),[o[1],o[2],o[3]],[P[1],P[2],P[3]],a)]}case"Dilation2D":{const P=Tg("strides",e,t,r),a=Tg("pad",e,t,r),o=Tg("dilations",e,t,r),u=P[1],s=P[2],v=o[1],i=o[2];return[n.dilation2d(Tg("x",e,t,r),Tg("filter",e,t,r),[u,s],a,[v,i],"NHWC")]}default:throw TypeError(`Node type ${e.op} is not implemented`)}},Lb=(e,t,r,n=Oe)=>{switch(e.op){case"Fill":{const P=Tg("shape",e,t,r),a=Tg("dtype",e,t,r),o=Tg("value",e,t,r);return[n.fill(P,o,a)]}case"LinSpace":{const P=Tg("start",e,t,r),a=Tg("stop",e,t,r),o=Tg("num",e,t,r);return[n.linspace(P,a,o)]}case"Multinomial":{const P=Tg("logits",e,t,r),a=Tg("numSamples",e,t,r),o=Tg("seed",e,t,r);return[n.multinomial(P,a,o)]}case"OneHot":{const P=Tg("indices",e,t,r),a=Tg("depth",e,t,r),o=Tg("onValue",e,t,r),u=Tg("offValue",e,t,r);return[n.oneHot(P,a,o,u)]}case"Ones":return[n.ones(Tg("shape",e,t,r),Tg("dtype",e,t,r))];case"OnesLike":return[n.onesLike(Tg("x",e,t,r))];case"RandomStandardNormal":return[n.randomStandardNormal(Tg("shape",e,t,r),Tg("dtype",e,t,r),Tg("seed",e,t,r))];case"RandomUniform":return[n.randomUniform(Tg("shape",e,t,r),Tg("minval",e,t,r),Tg("maxval",e,t,r),Tg("dtype",e,t,r))];case"Range":{const P=Tg("start",e,t,r),a=Tg("stop",e,t,r),o=Tg("step",e,t,r);return[n.range(P,a,o,Tg("dtype",e,t,r))]}case"TruncatedNormal":{const P=Tg("shape",e,t,r),a=Tg("mean",e,t,r),o=Tg("stdDev",e,t,r),u=Tg("seed",e,t,r);return[n.truncatedNormal(P,a,o,Tg("dtype",e,t,r),u)]}case"Zeros":return[n.zeros(Tg("shape",e,t,r),Tg("dtype",e,t,r))];case"ZerosLike":return[n.zerosLike(Tg("x",e,t,r))];default:throw TypeError(`Node type ${e.op} is not implemented`)}};
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function fb(e,t,r){return{boxes:Tg("boxes",e,t,r),scores:Tg("scores",e,t,r),maxOutputSize:Tg("maxOutputSize",e,t,r),iouThreshold:Tg("iouThreshold",e,t,r),scoreThreshold:Tg("scoreThreshold",e,t,r),softNmsSigma:Tg("softNmsSigma",e,t,r)}}const Ib=async(e,t,r,n,P=Oe)=>{switch(e.op){case"NonMaxSuppressionV5":{const{boxes:n,scores:a,maxOutputSize:o,iouThreshold:u,scoreThreshold:s,softNmsSigma:v}=fb(e,t,r),i=await P.image.nonMaxSuppressionWithScoreAsync(n,a,o,u,s,v);return[i.selectedIndices,i.selectedScores]}case"NonMaxSuppressionV4":{const{boxes:n,scores:a,maxOutputSize:o,iouThreshold:u,scoreThreshold:s}=fb(e,t,r),v=Tg("padToMaxOutputSize",e,t,r),i=await P.image.nonMaxSuppressionPaddedAsync(n,a,o,u,s,v);return[i.selectedIndices,i.validOutputs]}case"NonMaxSuppressionV3":case"NonMaxSuppressionV2":{const{boxes:n,scores:a,maxOutputSize:o,iouThreshold:u,scoreThreshold:s}=fb(e,t,r);return[await P.image.nonMaxSuppressionAsync(n,a,o,u,s)]}case"Where":{const n=P.cast(Tg("condition",e,t,r),"bool"),a=[await P.whereAsync(n)];return n.dispose(),a}case"ListDiff":return P.setdiff1dAsync(Tg("x",e,t,r),Tg("y",e,t,r));default:throw TypeError(`Node type ${e.op} is not implemented`)}},Sb=(e,t,r,n=Oe)=>{switch(e.op){case"LowerBound":{const P=Tg("sortedSequence",e,t,r),a=Tg("values",e,t,r);return[n.lowerBound(P,a)]}case"TopKV2":{const P=Tg("x",e,t,r),a=Tg("k",e,t,r),o=Tg("sorted",e,t,r),u=n.topk(P,a,o);return[u.values,u.indices]}case"UpperBound":{const P=Tg("sortedSequence",e,t,r),a=Tg("values",e,t,r);return[n.upperBound(P,a)]}case"Unique":{const P=Tg("x",e,t,r),a=n.unique(P);return[a.values,a.indices]}case"UniqueV2":{const P=Tg("x",e,t,r),a=Tg("axis",e,t,r),o=n.unique(P,a);return[o.values,o.indices]}default:throw TypeError(`Node type ${e.op} is not implemented`)}},Ab=(e,t,r,n=Oe)=>{switch(e.op){case"Const":return t[e.name];case"PlaceholderWithDefault":const P=Tg("default",e,t,r);return[zg(e.name,t,r)||P];case"Placeholder":return[zg(e.name,t,r)];case"Identity":case"StopGradient":case"FakeQuantWithMinMaxVars":return[Ig(Tg("x",e,t,r))];case"IdentityN":return Tg("x",e,t,r).map((e=>Ig(e)));case"Snapshot":return[Ig(Tg("x",e,t,r))];case"Shape":return[n.tensor1d(Tg("x",e,t,r).shape,"int32")];case"ShapeN":return Tg("x",e,t,r).map((e=>n.tensor1d(e.shape)));case"Size":return[n.scalar(Tg("x",e,t,r).size,"int32")];case"Rank":return[n.scalar(Tg("x",e,t,r).rank,"int32")];case"NoOp":return[n.scalar(1)];case"Print":const a=Tg("x",e,t,r),o=Tg("data",e,t,r),u=Tg("message",e,t,r),s=Tg("summarize",e,t,r);console.warn("The graph has a tf.print() operation,usually used for debugging, which slows down performance."),console.log(u);for(let e=0;e<o.length;e++)console.log(Array.prototype.slice.call(o[e].dataSync()).slice(0,s));return[a];default:throw TypeError(`Node type ${e.op} is not implemented`)}};
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
class xb{constructor(e,t){this.keyDType=e,this.valueDType=t,this.handle=Cl(0),this.tensorMap=new Map,Zu(this.handle)}get id(){return this.handle.id}clearAndClose(){this.tensorMap.forEach((e=>e.dispose())),this.tensorMap.clear(),this.handle.dispose()}size(){return this.tensorMap.size}tensorSize(){return Cl(this.size(),"int32")}async import(e,t){this.checkKeyAndValueTensor(e,t);const r=await e.data();return this.tensorMap.forEach((e=>e.dispose())),this.tensorMap.clear(),Fu((()=>{const e=Ej(t),n=r.length,P=e.length;xe(n===P,(()=>`The number of elements doesn't match, keys has ${n} elements, the values has ${P} elements.`));for(let t=0;t<n;t++){const n=r[t],P=e[t];Zu(P),this.tensorMap.set(n,P)}return this.handle}))}async find(e,t){this.checkKeyAndValueTensor(e,t);const r=await e.data();return Fu((()=>{const e=[];for(let n=0;n<r.length;n++){const P=r[n],a=this.findWithDefault(P,t);e.push(a)}return Dj(e)}))}findWithDefault(e,t){const r=this.tensorMap.get(e);return null!=r?r:t}checkKeyAndValueTensor(e,t){if(e.dtype!==this.keyDType)throw new Error(`Expect key dtype ${this.keyDType}, but got ${e.dtype}`);if(t.dtype!==this.valueDType)throw new Error(`Expect value dtype ${this.valueDType}, but got ${t.dtype}`)}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Yb=async(e,t,r,n)=>{switch(e.op){case"HashTable":case"HashTableV2":{const P=Tg("keyDType",e,t,r),a=Tg("valueDType",e,t,r),o=new xb(P,a);return n.addHashTable(e.name,o),[o.handle]}case"LookupTableImport":case"LookupTableImportV2":{const P=Tg("tableHandle",e,t,r,n),a=Tg("keys",e,t,r),o=Tg("values",e,t,r),u=n.getHashTableById(P.id);return[await u.import(a,o)]}case"LookupTableFind":case"LookupTableFindV2":{const P=Tg("tableHandle",e,t,r,n),a=Tg("keys",e,t,r),o=Tg("defaultValue",e,t,r),u=n.getHashTableById(P.id);return[await u.find(a,o)]}case"LookupTableSize":case"LookupTableSizeV2":{const P=Tg("tableHandle",e,t,r,n);return[n.getHashTableById(P.id).tensorSize()]}default:throw TypeError(`Node type ${e.op} is not implemented`)}},kb=(e,t,r,n=Oe)=>{switch(e.op){case"ResizeBilinear":{const P=Tg("images",e,t,r),a=Tg("size",e,t,r),o=Tg("alignCorners",e,t,r),u=Tg("halfPixelCenters",e,t,r);return[n.image.resizeBilinear(P,[a[0],a[1]],o,u)]}case"ResizeNearestNeighbor":{const P=Tg("images",e,t,r),a=Tg("size",e,t,r),o=Tg("alignCorners",e,t,r),u=Tg("halfPixelCenters",e,t,r);return[n.image.resizeNearestNeighbor(P,[a[0],a[1]],o,u)]}case"CropAndResize":{const P=Tg("image",e,t,r),a=Tg("boxes",e,t,r),o=Tg("boxInd",e,t,r),u=Tg("cropSize",e,t,r),s=Tg("method",e,t,r),v=Tg("extrapolationValue",e,t,r);return[n.image.cropAndResize(P,a,o,u,s,v)]}case"ImageProjectiveTransformV3":{const P=Tg("images",e,t,r),a=Tg("transforms",e,t,r),o=Tg("outputShape",e,t,r),u=Tg("fillValue",e,t,r),s=Tg("interpolation",e,t,r),v=Tg("fillMode",e,t,r);return[n.image.transform(P,a,s.toLowerCase(),v.toLowerCase(),u,o)]}default:throw TypeError(`Node type ${e.op} is not implemented`)}},Cb=(e,t,r,n=Oe)=>{switch(e.op){case"Equal":return[n.equal(Tg("a",e,t,r),Tg("b",e,t,r))];case"NotEqual":return[n.notEqual(Tg("a",e,t,r),Tg("b",e,t,r))];case"Greater":return[n.greater(Tg("a",e,t,r),Tg("b",e,t,r))];case"GreaterEqual":return[n.greaterEqual(Tg("a",e,t,r),Tg("b",e,t,r))];case"Less":return[n.less(Tg("a",e,t,r),Tg("b",e,t,r))];case"LessEqual":return[n.lessEqual(Tg("a",e,t,r),Tg("b",e,t,r))];case"LogicalAnd":return[n.logicalAnd(Tg("a",e,t,r),Tg("b",e,t,r))];case"LogicalNot":return[n.logicalNot(Tg("a",e,t,r))];case"LogicalOr":return[n.logicalOr(Tg("a",e,t,r),Tg("b",e,t,r))];case"Select":case"SelectV2":return[n.where(Tg("condition",e,t,r),Tg("a",e,t,r),Tg("b",e,t,r))];default:throw TypeError(`Node type ${e.op} is not implemented`)}},Eb=(e,t,r,n=Oe)=>{switch(e.op){case"BatchMatMul":case"BatchMatMulV2":case"MatMul":return[n.matMul(Tg("a",e,t,r),Tg("b",e,t,r),Tg("transposeA",e,t,r),Tg("transposeB",e,t,r))];case"Einsum":return[n.einsum(Tg("equation",e,t,r),...Tg("tensors",e,t,r))];case"Transpose":return[n.transpose(Tg("x",e,t,r),Tg("perm",e,t,r))];case"_FusedMatMul":const[P,a]=Tg("fusedOps",e,t,r),o="biasadd"===P,u="prelu"===a,s=Tg("numArgs",e,t,r),v=Tg("leakyreluAlpha",e,t,r);if(o){if(u&&2!==s)throw new Error("Fused MatMul with BiasAdd and Prelu must have two extra arguments: bias and alpha.");if(!u&&1!==s)throw new Error("Fused MatMul with BiasAdd must have one extra argument: bias.")}const[i,l]=Tg("args",e,t,r);return[n.fused.matMul({a:Tg("a",e,t,r),b:Tg("b",e,t,r),transposeA:Tg("transposeA",e,t,r),transposeB:Tg("transposeB",e,t,r),bias:i,activation:a,preluActivationWeights:l,leakyreluAlpha:v})];default:throw TypeError(`Node type ${e.op} is not implemented`)}},Qb=(e,t,r,n=Oe)=>{switch(e.op){case"EuclideanNorm":return[n.euclideanNorm(Tg("x",e,t,r),Tg("axis",e,t,r),Tg("keepDims",e,t,r))];case"FusedBatchNorm":case"FusedBatchNormV2":case"FusedBatchNormV3":return[n.batchNorm(Tg("x",e,t,r),Tg("mean",e,t,r),Tg("variance",e,t,r),Tg("offset",e,t,r),Tg("scale",e,t,r),Tg("epsilon",e,t,r))];case"LRN":return[n.localResponseNormalization(Tg("x",e,t,r),Tg("radius",e,t,r),Tg("bias",e,t,r),Tg("alpha",e,t,r),Tg("beta",e,t,r))];case"Softmax":return[n.softmax(Tg("x",e,t,r))];case"LogSoftmax":return[n.logSoftmax(Tg("x",e,t,r))];case"SparseToDense":return[n.sparseToDense(Tg("sparseIndices",e,t,r),Tg("outputShape",e,t,r),Tg("sparseValues",e,t,r),Tg("defaultValue",e,t,r))];default:throw TypeError(`Node type ${e.op} is not implemented`)}},Wb=(e,t,r,n=Oe)=>{switch(e.op){case"Max":{const P=Tg("axis",e,t,r),a=Tg("keepDims",e,t,r);return[n.max(Tg("x",e,t,r),P,a)]}case"Mean":{const P=Tg("axis",e,t,r),a=Tg("keepDims",e,t,r);return[n.mean(Tg("x",e,t,r),P,a)]}case"Min":{const P=Tg("axis",e,t,r),a=Tg("keepDims",e,t,r);return[n.min(Tg("x",e,t,r),P,a)]}case"Sum":{const P=Tg("axis",e,t,r),a=Tg("keepDims",e,t,r);return[n.sum(Tg("x",e,t,r),P,a)]}case"All":{const P=Tg("axis",e,t,r),a=Tg("keepDims",e,t,r);return[n.all(Tg("x",e,t,r),P,a)]}case"Any":{const P=Tg("axis",e,t,r),a=Tg("keepDims",e,t,r);return[n.any(Tg("x",e,t,r),P,a)]}case"ArgMax":{const P=Tg("axis",e,t,r);return[n.argMax(Tg("x",e,t,r),P)]}case"ArgMin":{const P=Tg("axis",e,t,r);return[n.argMin(Tg("x",e,t,r),P)]}case"Prod":{const P=Tg("axis",e,t,r),a=Tg("keepDims",e,t,r);return[n.prod(Tg("x",e,t,r),P,a)]}case"Cumprod":{const P=Tg("axis",e,t,r),a=Tg("exclusive",e,t,r),o=Tg("reverse",e,t,r);return[n.cumprod(Tg("x",e,t,r),P,a,o)]}case"Cumsum":{const P=Tg("axis",e,t,r),a=Tg("exclusive",e,t,r),o=Tg("reverse",e,t,r);return[n.cumsum(Tg("x",e,t,r),P,a,o)]}case"Bincount":const P=Tg("x",e,t,r),a=Tg("weights",e,t,r),o=Tg("size",e,t,r);return[n.bincount(P,a,o)];case"DenseBincount":{const P=Tg("x",e,t,r),a=Tg("weights",e,t,r),o=Tg("size",e,t,r),u=Tg("binaryOutput",e,t,r);return[n.denseBincount(P,a,o,u)]}default:throw TypeError(`Node type ${e.op} is not implemented`)}},Ub=(e,t,r,n=Oe)=>{switch(e.op){case"ConcatV2":case"Concat":{const P=Tg("n",e,t,r),a=Tg("axis",e,t,r);let o=Tg("tensors",e,t,r);return o=o.slice(0,P),[n.concat(o,a)]}case"Gather":{const P=Tg("x",e,t,r),a=Tg("indices",e,t,r);return[n.gather(P,n.cast(a,"int32"),0)]}case"GatherV2":{const P=Tg("axis",e,t,r),a=Tg("batchDims",e,t,r),o=Tg("x",e,t,r),u=Tg("indices",e,t,r);return[n.gather(o,n.cast(u,"int32"),P,a)]}case"Reverse":{const P=Tg("dims",e,t,r),a=[];for(let e=0;e<P.length;e++)P[e]&&a.push(e);const o=Tg("x",e,t,r);return[n.reverse(o,a)]}case"ReverseV2":{const P=Tg("axis",e,t,r),a=Tg("x",e,t,r);return[n.reverse(a,P)]}case"Slice":{const P=Tg("begin",e,t,r),a=Tg("size",e,t,r);return[n.slice(Tg("x",e,t,r),P,a)]}case"StridedSlice":{const P=Tg("begin",e,t,r),a=Tg("end",e,t,r),o=Tg("strides",e,t,r),u=Tg("beginMask",e,t,r),s=Tg("endMask",e,t,r),v=Tg("ellipsisMask",e,t,r),i=Tg("newAxisMask",e,t,r),l=Tg("shrinkAxisMask",e,t,r),c=Tg("x",e,t,r);return[n.stridedSlice(c,P,a,o,u,s,v,i,l)]}case"Pack":return Fu((()=>{const P=Tg("axis",e,t,r),a=Tg("tensors",e,t,r),o=a[0].shape,u=n.squeeze(a[0]).shape,s=a.map((e=>{const t=Qe(e.shape,o);if(!t&&!Qe(n.squeeze(e).shape,u))throw new Error("the input tensors shape does not match");return t?e:n.reshape(e,o)}));return[n.stack(s,P)]}));case"Unpack":{const P=Tg("axis",e,t,r),a=Tg("tensor",e,t,r);return n.unstack(a,P)}case"Tile":{const P=Tg("reps",e,t,r);return[n.tile(Tg("x",e,t,r),P)]}case"Split":case"SplitV":{const P=Tg("axis",e,t,r),a=Tg("numOrSizeSplits",e,t,r),o=Tg("x",e,t,r);return n.split(o,a,P)}case"ScatterNd":{const P=Tg("indices",e,t,r),a=Tg("values",e,t,r),o=Tg("shape",e,t,r);return[n.scatterND(P,a,o)]}case"GatherNd":{const P=Tg("x",e,t,r),a=Tg("indices",e,t,r);return[n.gatherND(P,a)]}case"SparseToDense":{const P=Tg("sparseIndices",e,t,r),a=Tg("outputShape",e,t,r),o=Tg("sparseValues",e,t,r),u=Tg("defaultValue",e,t,r);return[n.sparseToDense(P,o,a,o.dtype===u.dtype?u:n.cast(u,o.dtype))]}default:throw TypeError(`Node type ${e.op} is not implemented`)}},qb=(e,t,r,n=Oe)=>{switch(e.op){case"SparseFillEmptyRows":{const{outputIndices:P,outputValues:a,emptyRowIndicator:o,reverseIndexMap:u}=n.sparse.sparseFillEmptyRows(Tg("indices",e,t,r),Tg("values",e,t,r),Tg("denseShape",e,t,r),Tg("defaultValue",e,t,r));return[P,a,o,u]}case"SparseReshape":{const{outputIndices:P,outputShape:a}=n.sparse.sparseReshape(Tg("inputIndices",e,t,r),Tg("inputShape",e,t,r),Tg("newShape",e,t,r));return[P,a]}case"SparseSegmentMean":return[n.sparse.sparseSegmentMean(Tg("data",e,t,r),Tg("indices",e,t,r),Tg("segmentIds",e,t,r))];case"SparseSegmentSum":return[n.sparse.sparseSegmentSum(Tg("data",e,t,r),Tg("indices",e,t,r),Tg("segmentIds",e,t,r))];default:throw TypeError(`Node type ${e.op} is not implemented`)}},Gb=(e,t,r,n=Oe)=>{switch(e.op){case"FFT":return[n.fft(Tg("x",e,t,r))];case"IFFT":return[n.ifft(Tg("x",e,t,r))];case"RFFT":return[n.rfft(Tg("x",e,t,r))];case"IRFFT":return[n.irfft(Tg("x",e,t,r))];default:throw TypeError(`Node type ${e.op} is not implemented`)}},Mb=(e,t,r,n=Oe)=>{switch(e.op){case"StringNGrams":{const{nGrams:P,nGramsSplits:a}=n.string.stringNGrams(Tg("data",e,t,r),Tg("dataSplits",e,t,r),Tg("separator",e,t,r),Tg("nGramWidths",e,t,r),Tg("leftPad",e,t,r),Tg("rightPad",e,t,r),Tg("padWidth",e,t,r),Tg("preserveShortSequences",e,t,r));return[P,a]}case"StringSplit":{const{indices:P,values:a,shape:o}=n.string.stringSplit(Tg("input",e,t,r),Tg("delimiter",e,t,r),Tg("skipEmpty",e,t,r));return[P,a,o]}case"StringToHashBucketFast":return[n.string.stringToHashBucketFast(Tg("input",e,t,r),Tg("numBuckets",e,t,r))];default:throw TypeError(`Node type ${e.op} is not implemented`)}},Kb=(e,t,r,n=Oe)=>{switch(e.op){case"Cast":return[n.cast(Tg("x",e,t,r),Tg("dtype",e,t,r))];case"ExpandDims":{const P=Tg("axis",e,t,r);return[n.expandDims(Tg("x",e,t,r),P)]}case"Squeeze":{const P=Tg("axis",e,t,r);return[n.squeeze(Tg("x",e,t,r),P)]}case"Reshape":return[n.reshape(Tg("x",e,t,r),Tg("shape",e,t,r))];case"MirrorPad":return[n.mirrorPad(Tg("x",e,t,r),Tg("padding",e,t,r),Tg("mode",e,t,r))];case"PadV2":case"Pad":return[n.pad(Tg("x",e,t,r),Tg("padding",e,t,r),Tg("constantValue",e,t,r))];case"SpaceToBatchND":{const P=Tg("blockShape",e,t,r),a=Tg("paddings",e,t,r);return[n.spaceToBatchND(Tg("x",e,t,r),P,a)]}case"BatchToSpaceND":{const P=Tg("blockShape",e,t,r),a=Tg("crops",e,t,r);return[n.batchToSpaceND(Tg("x",e,t,r),P,a)]}case"DepthToSpace":{const P=Tg("blockSize",e,t,r),a=Tg("dataFormat",e,t,r).toUpperCase();return[n.depthToSpace(Tg("x",e,t,r),P,a)]}case"BroadcastTo":return[n.broadcastTo(Tg("x",e,t,r),Tg("shape",e,t,r))];case"BroadcastArgs":return[n.broadcastArgs(Tg("s0",e,t,r),Tg("s1",e,t,r))];default:throw TypeError(`Node type ${e.op} is not implemented`)}};
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function Nb(e,t,r,n,P=Fu){const a=((e,t,r)=>{switch(e.category){case"arithmetic":return P((()=>lb(e,t,r)));case"basic_math":return P((()=>cb(e,t,r)));case"control":return db(e,t,r);case"convolution":return P((()=>wb(e,t,r)));case"creation":return P((()=>Lb(e,t,r)));case"dynamic":return Ib(e,t,r);case"evaluation":return P((()=>Sb(e,t,r)));case"image":return P((()=>kb(e,t,r)));case"graph":return P((()=>Ab(e,t,r)));case"logical":return P((()=>Cb(e,t,r)));case"matrices":return P((()=>Eb(e,t,r)));case"normalization":return P((()=>Qb(e,t,r)));case"reduction":return P((()=>Wb(e,t,r)));case"slice_join":return P((()=>Ub(e,t,r)));case"sparse":return P((()=>qb(e,t,r)));case"spectral":return P((()=>Gb(e,t,r)));case"string":return P((()=>Mb(e,t,r)));case"transformation":return P((()=>Kb(e,t,r)));case"hash_table":return Yb(e,t,r,n);case"custom":const a=bg(e.op);if(a&&a.customExecutor)return a.customExecutor(new ib(e,t,r));throw TypeError(`Custom op ${e.op} is not registered.`);default:throw TypeError(`Unknown op '${e.op}'. File an issue at https://github.com/tensorflow/tfjs/issues so we can add it, or register a custom execution with tf.registerOp()`)}})(e,t,r);return ct(a)?a.then((e=>[].concat(e))):[].concat(a)}class Rb{constructor(e={},t={},r={},n={}){this.weightMap=e,this.tensorArrayMap=t,this.tensorListMap=r,this.functionMap=n,this.rootContext={id:0,frameName:"",iterationId:0},this.contexts=[this.rootContext],this.lastId=0,this.generateCurrentContextIds()}newFrame(e,t){return{id:e,frameName:t,iterationId:0}}set currentContext(e){this.contexts!==e&&(this.contexts=e,this.generateCurrentContextIds())}get currentContext(){return this.contexts}get currentContextId(){return this._currentContextIds[0]}get currentContextIds(){return this._currentContextIds}generateCurrentContextIds(){const e=[];for(let t=0;t<this.contexts.length-1;t++){const r=this.contexts.slice(0,this.contexts.length-t);e.push(this.contextIdforContexts(r))}e.push(""),this._currentContextIds=e}contextIdforContexts(e){return e?e.map((e=>0===e.id&&0===e.iterationId?"":`${e.frameName}-${e.iterationId}`)).join("/"):""}enterFrame(e){this.contexts&&(this.lastId++,this.contexts=this.contexts.slice(),this.contexts.push(this.newFrame(this.lastId,e)),this._currentContextIds.unshift(this.contextIdforContexts(this.contexts)))}exitFrame(){if(!(this.contexts&&this.contexts.length>1))throw new Error("Cannot exit frame, the context is empty");this.contexts=this.contexts.slice(),this.contexts.splice(-1),this.currentContextIds.shift()}nextIteration(){if(!(this.contexts&&this.contexts.length>0))throw new Error("Cannot increase frame iteration, the context is empty");{this.contexts=this.contexts.slice(),this.lastId++;const e=Object.assign({},this.contexts[this.contexts.length-1]);e.iterationId+=1,e.id=this.lastId,this.contexts.splice(-1,1,e),this._currentContextIds.splice(0,1,this.contextIdforContexts(this.contexts))}}getWeight(e){return this.weightMap[e]}addTensorArray(e){this.tensorArrayMap[e.id]=e}getTensorArray(e){return this.tensorArrayMap[e]}addTensorList(e){this.tensorListMap[e.id]=e}getTensorList(e){return this.tensorListMap[e]}dispose(e){for(const t in this.tensorArrayMap)this.tensorArrayMap[t].clearAndClose(e);for(const t in this.tensorListMap)this.tensorListMap[t].clearAndClose(e)}}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Fb(e,t,r,n){const P=new Set,a=[];let o=null,u=null;const s=new Set,v=Object.keys(e).map((e=>Lg(e)[0]));let i=[];null!=n&&(i=n.map((e=>Lg(e.name)[0])));const l=[...t];for(;l.length>0;){const e=l.pop();(Hb(e)||Jb(e)||_b(e))&&null==o&&(o=e,u=o.children.map((e=>e.name)).filter((e=>P.has(e)))),P.add(e.name),null==r[e.name]&&(-1===v.indexOf(e.name)&&-1===i.indexOf(e.name)&&(0!==e.inputs.length?e.inputs.forEach((e=>{s.has(e.name)||(s.add(e.name),l.push(e))})):a.push(e.name)))}return{inputs:e,outputs:t,usedNodes:P,missingInputs:a,dynamicNode:o,syncInputs:u}}function Bb(e,t,r){const{usedNodes:n,inputs:P}=r,a=[],o=Object.keys(P).map((e=>Lg(e)[0])).map((t=>e.nodes[t])),u=e.initNodes;o.forEach((e=>{n.has(e.name)&&a.push(e)})),e.weights.forEach((e=>{n.has(e.name)&&a.push(e)})),null!=u&&u.forEach((e=>{n.has(e.name)&&a.push(e)}));const s=new Set,v=[];for(;a.length>0;){const e=a.pop();s.add(e.name),t[e.name]||v.push(e),e.children.forEach((e=>{!s.has(e.name)&&n.has(e.name)&&e.inputs.every((e=>s.has(e.name)))&&a.push(e)}))}return v}const Zb=["Switch","Merge","Enter","Exit","NextIteration","StatelessIf","StatelessWhile","if","While"],Vb=["NonMaxSuppressionV2","NonMaxSuppressionV3","NonMaxSuppressionV5","Where"],Xb=["HashTable","HashTableV2","LookupTableImport","LookupTableImportV2","LookupTableFind","LookupTableFindV2","LookupTableSize","LookupTableSizeV2"];function Hb(e){return Zb.indexOf(e.op)>=0}function Jb(e){return Vb.indexOf(e.op)>=0}function _b(e){return Xb.indexOf(e.op)>=0}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class $b{constructor(e,t){this.graph=e,this.parent=t,this.compiledMap=new Map,this._weightMap={},this.SEPERATOR=",",this._functions={},this._functionExecutorMap={},this.intermediateTensors={},this.keepTensorForDebug=!1,this._outputs=e.outputs,this._inputs=e.inputs,this._initNodes=e.initNodes,this._signature=e.signature,this._functions=e.functions,null!=e.functions&&Object.keys(e.functions).forEach((t=>{this._functionExecutorMap[t]=new $b(e.functions[t],this)}))}get weightIds(){return this.parent?this.parent.weightIds:this._weightIds}get functionExecutorMap(){return this.parent?this.parent.functionExecutorMap:this._functionExecutorMap}get weightMap(){return this.parent?this.parent.weightMap:this._weightMap}set weightMap(e){const t=Object.keys(e).map((t=>e[t].map((e=>e.id))));this._weightIds=[].concat(...t),this._weightMap=e}set resourceManager(e){this._resourceManager=e}get inputs(){return this._inputs.map((e=>({name:e.name,shape:e.attrParams.shape?e.attrParams.shape.value:void 0,dtype:e.attrParams.dtype?e.attrParams.dtype.value:void 0})))}get outputs(){return this._outputs.map((e=>({name:e.name,shape:e.attrParams.shape?e.attrParams.shape.value:void 0,dtype:e.attrParams.dtype?e.attrParams.dtype.value:void 0})))}get inputNodes(){return this._inputs.map((e=>e.signatureKey||e.name))}get outputNodes(){return this._outputs.map((e=>{const t=e.signatureKey||e.name;return e.defaultOutput?`${t}:${e.defaultOutput}`:t}))}get functions(){return Object.keys(this._functions).reduce(((e,t)=>(e[t]=this._functions[t].signature,e)),{})}getCompilationKey(e,t){const r=e.map((e=>e.name)).sort(),n=t.map((e=>e.name)).sort();return r.join(this.SEPERATOR)+"--"+n.join(this.SEPERATOR)}compile(e,t){const r=Fb(e,t,this.weightMap,this._initNodes),{missingInputs:n,dynamicNode:P,syncInputs:a}=r;if(null!=P)throw new Error(`This execution contains the node '${P.name}', which has the dynamic op '${P.op}'. Please use model.executeAsync() instead. Alternatively, to avoid the dynamic ops, specify the inputs [${a}]`);if(n.length>0){const r=t.map((e=>e.name)),P=Object.keys(e);throw new Error(`Cannot compute the outputs [${r}] from the provided inputs [${P}]. Missing the following inputs: [${n}]`)}return Bb(this.graph,this.weightMap,r)}execute(e,t){e=this.mapInputs(e);const r=Object.keys(e).sort();this.checkInputs(e),this.checkInputShapeAndType(e),t=this.mapOutputs(t),this.checkOutputs(t);const n=r.map((e=>this.graph.nodes[Lg(e)[0]])),P=t.map((e=>Lg(e)[0]));let a=P.map((e=>this.graph.nodes[e]));this.resetIntermediateTensors(),0===a.length&&(a=this._outputs);const o=this.getCompilationKey(n,a);let u=this.compiledMap.get(o);null==u&&(u=this.compile(e,a),this.compiledMap.set(o,u));const s={},v={};return Fu((()=>{const r=new Rb(this.weightMap,s,v,this.functionExecutorMap),n=Object.assign({},this.weightMap);Object.keys(e).forEach((t=>{const[r,P]=Lg(t),a=[];a[P]=e[t],n[r]=a}));const a=this.getFrozenTensorIds(n),o={};for(let e=0;e<u.length;e++){const t=u[e];if(!n[t.name]){const e=Nb(t,n,r,this._resourceManager);if(ct(e))throw new Error(`The execution of the op '${t.op}' returned a promise. Please use model.executeAsync() instead.`);n[t.name]=e,this.checkTensorForDisposal(t.name,t,n,r,a,P,o)}}return null==this.parent&&r.dispose(a),t.map((e=>zg(e,n,r)))}))}getFrozenTensorIds(e){const t=[].concat.apply([],Object.keys(e).map((t=>e[t])).map((e=>e.map((e=>e.id)))));return new Set(t)}checkTensorForDisposal(e,t,r,n,P,a,o){"control"!==t.category&&-1===a.indexOf(e)&&(r[e].forEach((e=>{null!=e&&(o[e.id]=(o[e.id]||0)+t.children.length)})),t.inputs.forEach((e=>{if("control"!==e.category){const a=dg(e.name,r,n);null!=a&&a.forEach((e=>{if(e&&!e.kept&&!P.has(e.id)){const r=o[e.id];if(1===r){if(this.keepTensorForDebug){const[r,P]=yg(t.name,n);this.intermediateTensors[r]||(this.intermediateTensors[r]=[]),this.intermediateTensors[r][P]=e}else e.dispose();delete o[e.id]}else null!=r&&o[e.id]--}}))}})))}async executeAsync(e,t){return this._executeAsync(e,t)}disposeIntermediateTensors(){this.intermediateTensors&&(Object.keys(this.intermediateTensors).forEach((e=>this.intermediateTensors[e].forEach((e=>e.dispose())))),this.disposeTensorsMap())}disposeTensorsMap(){this.tensorsMap&&Object.keys(this.tensorsMap).forEach((e=>{this.tensorsMap[e].forEach((e=>{!e||e.kept||e.isDisposed||this.keepIds.has(e.id)||e.dispose()}))}))}getIntermediateTensors(){return this.tensorsMap}resetIntermediateTensors(){for(const e in this.intermediateTensors)this.intermediateTensors[e].forEach((e=>e.dispose())),delete this.intermediateTensors[e]}async _executeAsync(e,t,r=!1,n={},P={}){r||(e=this.mapInputs(e),this.checkInputs(e),this.checkInputShapeAndType(e),t=this.mapOutputs(t),this.checkOutputs(t));try{this.keepTensorForDebug=mt().getBool("KEEP_INTERMEDIATE_TENSORS")}catch(e){console.warn(e.message)}this.resetIntermediateTensors();const a=new Rb(this.weightMap,n,P,this.functionExecutorMap);this.tensorsMap=await this.executeWithControlFlow(e,a,t,r);const o=t.map((e=>zg(e,this.tensorsMap,a))),u=o.map((e=>e.id)),s=Object.keys(e).map((t=>e[t].id));return this.keepIds=new Set([...u,...s,...this.weightIds]),this.keepTensorForDebug||this.disposeTensorsMap(),null==this.parent&&a.dispose(this.keepIds),o}async executeFunctionAsync(e,t,r){const n=e.reduce(((e,t,r)=>(e[this.inputs[r].name]=t,e)),{});return this._executeAsync(n,this.outputNodes,!0,t,r)}async executeWithControlFlow(e,t,r,n){const P=Object.keys(e),a=P.map((e=>this.graph.nodes[Lg(e)[0]])),o=r.map((e=>Lg(e)[0]));let u=o.map((e=>this.graph.nodes[e]));0===u.length&&(u=this._outputs);const{usedNodes:s,missingInputs:v,dynamicNode:i,syncInputs:l}=Fb(e,u,this.weightMap,this._initNodes),c=[...a,...this.graph.weights,...this._initNodes||[]].map((e=>({node:e,contexts:t.currentContext}))),O=Object.assign({},this.weightMap);Object.keys(e).forEach((t=>{const[r,n]=Lg(t),P=[];P[n]=e[t],O[r]=P}));const D={},j=this.getFrozenTensorIds(O),h={};for(;c.length>0;){const e=this.processStack(a,c,t,O,h,j,o,D,s);await Promise.all(e)}null!=i||n||console.warn("This model execution did not contain any nodes with control flow or dynamic output shapes. You can use model.execute() instead.");const p=u.filter((e=>!Hb(e)&&!zg(e.name,O,t))).map((e=>e.name));if(p.length>0){let e="";throw null!=i&&(e=`Alternatively, to avoid the dynamic ops, use model.execute() and specify the inputs [${l}]`),new Error(`Cannot compute the outputs [${p}] from the provided inputs [${P}]. Consider providing the following inputs: [${v}]. ${e}`)}return O}processStack(e,t,r,n,P,a,o,u,s){const v=[];for(;t.length>0;){const e=t.pop();r.currentContext=e.contexts;let i="";if("Enter"===e.node.op&&Tg("isConstant",e.node,n,r)&&([i]=yg(e.node.name,r)),null==n[e.node.name]){const l=Nb(e.node,n,r,this._resourceManager);i||([i]=yg(e.node.name,r));const c=r.currentContext;ct(l)?v.push(l.then((v=>(n[i]=v,r.currentContext=c,this.checkTensorForDisposal(i,e.node,n,r,a,o,u),this.processChildNodes(e.node,t,r,n,P,s),v)))):(n[i]=l,this.checkTensorForDisposal(i,e.node,n,r,a,o,u),this.processChildNodes(e.node,t,r,n,P,s))}else this.processChildNodes(e.node,t,r,n,P,s)}return v}processChildNodes(e,t,r,n,P,a){e.children.forEach((e=>{const[o]=yg(e.name,r);!P[o]&&a.has(e.name)&&("Merge"===e.op?e.inputNames.some((e=>!!zg(e,n,r)))&&(P[o]=!0,t.push({contexts:r.currentContext,node:e})):e.inputNames.every((e=>!!zg(e,n,r)))&&(P[o]=!0,t.push({contexts:r.currentContext,node:e})))}))}dispose(){Object.keys(this.weightMap).forEach((e=>this.weightMap[e].forEach((e=>e.dispose()))))}checkInputShapeAndType(e){Object.keys(e).forEach((t=>{const r=e[t],[n]=Lg(t),P=this.graph.nodes[n];if(P.attrParams.shape&&P.attrParams.shape.value){const e=P.attrParams.shape.value;xe(e.length===r.shape.length&&r.shape.every(((t,r)=>-1===e[r]||e[r]===t)),(()=>`The shape of dict['${P.name}'] provided in model.execute(dict) must be [${e}], but was [${r.shape}]`))}P.attrParams.dtype&&P.attrParams.dtype.value&&xe(r.dtype===P.attrParams.dtype.value,(()=>`The dtype of dict['${P.name}'] provided in model.execute(dict) must be ${P.attrParams.dtype.value}, but was ${r.dtype}`))}))}mapInputs(e){const t={};for(const r in e)if(null!=this._signature&&null!=this._signature.inputs&&null!=this._signature.inputs[r]){t[this._signature.inputs[r].name]=e[r]}else t[r]=e[r];return t}checkInputs(e){const t=Object.keys(e).filter((e=>{const[t]=Lg(e);return null==this.graph.nodes[t]}));if(t.length>0)throw new Error(`The dict provided in model.execute(dict) has keys: [${t}] that are not part of graph`)}mapOutputs(e){return e.map((e=>{if(null!=this._signature&&null!=this._signature.outputs&&null!=this._signature.outputs[e]){return this._signature.outputs[e].name}return e}),{})}checkOutputs(e){e.forEach((e=>{const[t]=Lg(e);if(!this.graph.nodes[t])throw new Error(`The output '${e}' is not found in the graph`)}))}}class eT{constructor(e={},t={}){this.hashTableNameToHandle=e,this.hashTableMap=t}addHashTable(e,t){this.hashTableNameToHandle[e]=t.handle,this.hashTableMap[t.id]=t}getHashTableHandleByName(e){return this.hashTableNameToHandle[e]}getHashTableById(e){return this.hashTableMap[e]}dispose(){for(const e in this.hashTableMap)this.hashTableMap[e].clearAndClose(),delete this.hashTableMap[e];for(const e in this.hashTableNameToHandle)this.hashTableNameToHandle[e].dispose(),delete this.hashTableNameToHandle[e]}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const tT="?tfjs-format=file",rT="model.json";class nT{constructor(e,t={},r=w){this.modelUrl=e,this.loadOptions=t,this.version="n/a",this.io=r,null==t&&(this.loadOptions={}),this.resourceManager=new eT}get modelVersion(){return this.version}get inputNodes(){return this.executor.inputNodes}get outputNodes(){return this.executor.outputNodes}get inputs(){return this.executor.inputs}get outputs(){return this.executor.outputs}get weights(){return this.executor.weightMap}get metadata(){return this.artifacts.userDefinedMetadata}get modelSignature(){return this.signature}get modelStructuredOutputKeys(){return this.structuredOutputKeys}findIOHandler(){const e=this.modelUrl;if(null!=e.load)this.handler=e;else if(null!=this.loadOptions.requestInit)this.handler=this.io.browserHTTPRequest(e,this.loadOptions);else{const t=this.io.getLoadHandlers(e,this.loadOptions);if(0===t.length)t.push(this.io.browserHTTPRequest(e,this.loadOptions));else if(t.length>1)throw new Error(`Found more than one (${t.length}) load handlers for URL '${[e]}'`);this.handler=t[0]}}load(){if(this.findIOHandler(),null==this.handler.load)throw new Error("Cannot proceed with model loading because the IOHandler provided does not have the `load` method implemented.");const e=this.handler.load();return ct(e)?e.then((e=>this.loadSync(e))):this.loadSync(e)}loadSync(e){this.artifacts=e;const t=this.artifacts.modelTopology;let r=this.artifacts.signature;if(null!=this.artifacts.userDefinedMetadata){const e=this.artifacts.userDefinedMetadata;null!=e.signature&&(r=e.signature),null!=e.structuredOutputKeys&&(this.structuredOutputKeys=e.structuredOutputKeys)}this.signature=r,this.version=`${t.versions.producer}.${t.versions.minConsumer}`;const n=this.io.decodeWeights(this.artifacts.weightData,this.artifacts.weightSpecs);if(this.executor=new $b(Vg.Instance.transformGraph(t,this.signature)),this.executor.weightMap=this.convertTensorMapToTensorsMap(n),this.executor.resourceManager=this.resourceManager,null!=e.modelInitializer&&null!=e.modelInitializer.node){const t=Vg.Instance.transformGraph(e.modelInitializer);this.initializer=new $b(t),this.initializer.weightMap=this.executor.weightMap,this.initializer.resourceManager=this.resourceManager,this.initializer.executeAsync({},[])}return!0}async save(e,t){if("string"==typeof e){const t=this.io.getSaveHandlers(e);if(0===t.length)throw new Error(`Cannot find any save handlers for URL '${e}'`);if(t.length>1)throw new Error(`Found more than one (${t.length}) save handlers for URL '${e}'`);e=t[0]}if(null==e.save)throw new Error("GraphModel.save() cannot proceed because the IOHandler provided does not have the `save` attribute defined.");return e.save(this.artifacts)}predict(e,t){const r=this.execute(e,this.outputNodes);if(this.structuredOutputKeys){const e={};return(r instanceof za?[r]:r).forEach(((t,r)=>e[this.structuredOutputKeys[r]]=t)),e}return r}normalizeInputs(e){if(!(e instanceof za||Array.isArray(e)))return e;if((e=Array.isArray(e)?e:[e]).length!==this.inputNodes.length)throw new Error(`Input tensor count mismatch,the graph model has ${this.inputNodes.length} placeholders, while there are ${e.length} input tensors.`);return this.inputNodes.reduce(((t,r,n)=>(t[r]=e[n],t)),{})}normalizeOutputs(e){return e=e||this.outputNodes,Array.isArray(e)?e:[e]}execute(e,t){e=this.normalizeInputs(e),t=this.normalizeOutputs(t);const r=this.executor.execute(e,t);return r.length>1?r:r[0]}async executeAsync(e,t){e=this.normalizeInputs(e),t=this.normalizeOutputs(t);const r=await this.executor.executeAsync(e,t);return r.length>1?r:r[0]}getIntermediateTensors(){return this.executor.getIntermediateTensors()}disposeIntermediateTensors(){this.executor.disposeIntermediateTensors()}convertTensorMapToTensorsMap(e){return Object.keys(e).reduce(((t,r)=>(t[r]=[e[r]],t)),{})}dispose(){this.executor.dispose(),this.initializer&&this.initializer.dispose(),this.resourceManager.dispose()}}async function PT(e,t={},r=w){if(null==e)throw new Error("modelUrl in loadGraphModel() cannot be null. Please provide a url or an IOHandler that loads the model");null==t&&(t={}),t.fromTFHub&&"string"==typeof e&&(e=aT(e));const n=new nT(e,t,r);return await n.load(),n}function aT(e){return e.endsWith("/")||(e+="/"),`${e}${rT}${tT}`
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */}da().prototype.pad=function(e,t){return this.throwIfDisposed(),YO(this,e,t)},
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
da().prototype.where=function(e,t){return this.throwIfDisposed(),ul(e,this,t)},
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
da().prototype.mul=function(e){return this.throwIfDisposed(),Rs(this,e)},
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
da().prototype.dot=function(e){return this.throwIfDisposed(),Ol(this,e)},
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
da().prototype.add=function(e){return this.throwIfDisposed(),Us(this,e)};
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
const oT={},uT={alpha:!1,antialias:!1,premultipliedAlpha:!1,preserveDrawingBuffer:!1,depth:!1,stencil:!1,failIfMajorPerformanceCaveat:!0};function sT(e,t){oT[e]=t}function vT(e,t){if(!(e in oT)||null!=t){const r=lT(e,t);if(null===r)return console.log("Could not get context for WebGL version",e),null;oT[e]=r}const r=oT[e];return null==r||r.isContextLost()?(delete oT[e],vT(e)):(r.disable(r.DEPTH_TEST),r.disable(r.STENCIL_TEST),r.disable(r.BLEND),r.disable(r.DITHER),r.disable(r.POLYGON_OFFSET_FILL),r.disable(r.SAMPLE_COVERAGE),r.enable(r.SCISSOR_TEST),r.enable(r.CULL_FACE),r.cullFace(r.BACK),oT[e])}function iT(e){if("undefined"!=typeof OffscreenCanvas&&2===e)return new OffscreenCanvas(300,150);if("undefined"!=typeof document)return document.createElement("canvas");throw new Error("Cannot create a canvas in this context")}function lT(e,t){if(1!==e&&2!==e)throw new Error("Cannot get WebGL rendering context, WebGL is disabled.");const r=null==t?iT(e):t;return r.addEventListener("webglcontextlost",(t=>{t.preventDefault(),delete oT[e]}),!1),1===e?r.getContext("webgl",uT)||r.getContext("experimental-webgl",uT):r.getContext("webgl2",uT)}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */var De,je,he;function cT(e,t){return[t,e]}function OT(e,t){return e*t}function DT(e){const t=Ee(e);return Ue(Math.ceil(t/4))}function jT(e,t){return[Math.max(1,Math.ceil(t/2)),Math.max(1,Math.ceil(e/2))]}function hT(e,t){const[r,n]=jT(e,t);return r*n*4}function pT(e,t){const r=e;let n,P,a,o,u,s,v,i,l,c;return 2===mt().getNumber("WEBGL_VERSION")?(n=r.R32F,P=r.R16F,a=r.RGBA16F,o=r.RGBA32F,u=r.RED,v=4,i=1,l=r.HALF_FLOAT,c=r.FLOAT,s=r.RGBA8):(n=e.RGBA,P=e.RGBA,a=e.RGBA,o=r.RGBA,u=e.RGBA,v=4,i=4,l=null!=t?t.HALF_FLOAT_OES:null,c=e.FLOAT,s=e.RGBA),{internalFormatFloat:n,internalFormatHalfFloat:P,internalFormatPackedHalfFloat:a,internalFormatPackedFloat:o,textureFormatFloat:u,downloadTextureFormat:s,downloadUnpackNumChannels:v,defaultNumChannels:i,textureTypeHalfFloat:l,textureTypeFloat:c}}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function mT(e,t){const r=t();return mt().getBool("DEBUG")&&gT(e),r}function gT(e){const t=e.getError();if(t!==e.NO_ERROR)throw new Error("WebGL Error: "+dT(e,t))}!function(e){e[e.DENSE=0]="DENSE",e[e.SHARED_BATCH=1]="SHARED_BATCH"}(De||(De={})),function(e){e[e.RENDER=0]="RENDER",e[e.UPLOAD=1]="UPLOAD",e[e.PIXELS=2]="PIXELS",e[e.DOWNLOAD=3]="DOWNLOAD"}(je||(je={})),function(e){e[e.UNPACKED_FLOAT16=0]="UNPACKED_FLOAT16",e[e.UNPACKED_FLOAT32=1]="UNPACKED_FLOAT32",e[e.PACKED_4X1_UNSIGNED_BYTE=2]="PACKED_4X1_UNSIGNED_BYTE",e[e.PACKED_2X2_FLOAT32=3]="PACKED_2X2_FLOAT32",e[e.PACKED_2X2_FLOAT16=4]="PACKED_2X2_FLOAT16"}(he||(he={}));const bT=5.96e-8,TT=65504;function zT(e){return!!(mt().getBool("WEBGL_RENDER_FLOAT32_ENABLED")||0===e||bT<Math.abs(e)&&Math.abs(e)<TT)}function dT(e,t){switch(t){case e.NO_ERROR:return"NO_ERROR";case e.INVALID_ENUM:return"INVALID_ENUM";case e.INVALID_VALUE:return"INVALID_VALUE";case e.INVALID_OPERATION:return"INVALID_OPERATION";case e.INVALID_FRAMEBUFFER_OPERATION:return"INVALID_FRAMEBUFFER_OPERATION";case e.OUT_OF_MEMORY:return"OUT_OF_MEMORY";case e.CONTEXT_LOST_WEBGL:return"CONTEXT_LOST_WEBGL";default:return`Unknown error code ${t}`}}function yT(e,t){return BT(e,(()=>e.getExtension(t)),'Extension "'+t+'" not supported on this browser.')}function wT(e,t){const r=BT(e,(()=>e.createShader(e.VERTEX_SHADER)),"Unable to create vertex WebGLShader.");if(mT(e,(()=>e.shaderSource(r,t))),mT(e,(()=>e.compileShader(r))),!1===e.getShaderParameter(r,e.COMPILE_STATUS))throw console.log(e.getShaderInfoLog(r)),new Error("Failed to compile vertex shader.");return r}function LT(e,t){const r=BT(e,(()=>e.createShader(e.FRAGMENT_SHADER)),"Unable to create fragment WebGLShader.");if(mT(e,(()=>e.shaderSource(r,t))),mT(e,(()=>e.compileShader(r))),mt().get("ENGINE_COMPILE_ONLY"))return r;if(!1===e.getShaderParameter(r,e.COMPILE_STATUS))throw IT(t,e.getShaderInfoLog(r)),new Error("Failed to compile fragment shader.");return r}const fT=/ERROR: [0-9]+:([0-9]+):/g;function IT(e,t){const r=fT.exec(t);if(null==r)return console.log(`Couldn't parse line number in error: ${t}`),void console.log(e);const n=+r[1],P=e.split("\n"),a=P.length.toString().length+2,o=P.map(((e,t)=>qe((t+1).toString(),a)+e));let u=0;for(let e=0;e<o.length;e++)u=Math.max(o[e].length,u);const s=o.slice(0,n-1),v=o.slice(n-1,n),i=o.slice(n);console.log(s.join("\n")),console.log(t.split("\n")[0]),console.log(`%c ${qe(v[0],u)}`,"border:1px solid red; background-color:#e3d2d2; color:#a61717"),console.log(i.join("\n"))}function ST(e){return BT(e,(()=>e.createProgram()),"Unable to create WebGLProgram.")}function AT(e,t){if(mT(e,(()=>e.linkProgram(t))),!mt().get("ENGINE_COMPILE_ONLY")&&!1===e.getProgramParameter(t,e.LINK_STATUS))throw console.log(e.getProgramInfoLog(t)),new Error("Failed to link vertex and fragment shaders.")}function xT(e,t){if(mT(e,(()=>e.validateProgram(t))),!1===e.getProgramParameter(t,e.VALIDATE_STATUS))throw console.log(e.getProgramInfoLog(t)),new Error("Shader program validation failed.")}function YT(e,t){const r=BT(e,(()=>e.createBuffer()),"Unable to create WebGLBuffer");return mT(e,(()=>e.bindBuffer(e.ARRAY_BUFFER,r))),mT(e,(()=>e.bufferData(e.ARRAY_BUFFER,t,e.STATIC_DRAW))),r}function kT(e,t){const r=BT(e,(()=>e.createBuffer()),"Unable to create WebGLBuffer");return mT(e,(()=>e.bindBuffer(e.ELEMENT_ARRAY_BUFFER,r))),mT(e,(()=>e.bufferData(e.ELEMENT_ARRAY_BUFFER,t,e.STATIC_DRAW))),r}function CT(e){return BT(e,(()=>e.createTexture()),"Unable to create WebGLTexture.")}function ET(e,t){const r=mt().getNumber("WEBGL_MAX_TEXTURE_SIZE");if(e<=0||t<=0){throw new Error("Requested texture size "+`[${e}x${t}]`+" is invalid.")}if(e>r||t>r){throw new Error("Requested texture size "+`[${e}x${t}]`+" greater than WebGL maximum on this browser / GPU "+`[${r}x${r}]`+".")}}function QT(e){return BT(e,(()=>e.createFramebuffer()),"Unable to create WebGLFramebuffer.")}function WT(e,t,r,n,P,a,o){const u=e.getAttribLocation(t,r);return-1!==u&&(mT(e,(()=>e.bindBuffer(e.ARRAY_BUFFER,n))),mT(e,(()=>e.vertexAttribPointer(u,P,e.FLOAT,!1,a,o))),mT(e,(()=>e.enableVertexAttribArray(u))),!0)}function UT(e,t,r){ZT(e,r),mT(e,(()=>e.activeTexture(e.TEXTURE0+r))),mT(e,(()=>e.bindTexture(e.TEXTURE_2D,t)))}function qT(e,t,r){return BT(e,(()=>e.getUniformLocation(t,r)),'uniform "'+r+'" not present in program.')}function GT(e,t,r){return e.getUniformLocation(t,r)}function MT(e,t,r,n){mT(e,(()=>UT(e,t,n))),mT(e,(()=>e.uniform1i(r,n)))}function KT(e,t,r){mT(e,(()=>e.bindFramebuffer(e.FRAMEBUFFER,r))),mT(e,(()=>e.framebufferTexture2D(e.FRAMEBUFFER,e.COLOR_ATTACHMENT0,e.TEXTURE_2D,t,0)))}function NT(e,t){mT(e,(()=>e.bindFramebuffer(e.FRAMEBUFFER,t))),mT(e,(()=>e.framebufferTexture2D(e.FRAMEBUFFER,e.COLOR_ATTACHMENT0,e.TEXTURE_2D,null,0)))}function RT(e){const t=e.checkFramebufferStatus(e.FRAMEBUFFER);if(t!==e.FRAMEBUFFER_COMPLETE)throw new Error("Error binding framebuffer: "+FT(e,t))}function FT(e,t){switch(t){case e.FRAMEBUFFER_INCOMPLETE_ATTACHMENT:return"FRAMEBUFFER_INCOMPLETE_ATTACHMENT";case e.FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT:return"FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT";case e.FRAMEBUFFER_INCOMPLETE_DIMENSIONS:return"FRAMEBUFFER_INCOMPLETE_DIMENSIONS";case e.FRAMEBUFFER_UNSUPPORTED:return"FRAMEBUFFER_UNSUPPORTED";default:return`unknown error ${t}`}}function BT(e,t,r){const n=mT(e,(()=>t()));if(null==n)throw new Error(r);return n}function ZT(e,t){const r=e.MAX_COMBINED_TEXTURE_IMAGE_UNITS-1,n=t+e.TEXTURE0;if(n<e.TEXTURE0||n>r){throw new Error(`textureUnit must be in ${`[gl.TEXTURE0, gl.TEXTURE${r}]`}.`)}}function VT(e,t=2){return Ee(e.slice(0,e.length-t))}function XT(e){if(0===e.length)throw Error("Cannot get rows and columns of an empty shape array.");return[e.length>1?e[e.length-2]:1,e[e.length-1]]}function HT(e){let t=[1,1,1];return 0===e.length||1===e.length&&1===e[0]||(t=[VT(e),...XT(e)]),t}function JT(e,t=!1){let r=mt().getNumber("WEBGL_MAX_TEXTURE_SIZE");if(t&&(r*=2,e=e.map(((t,r)=>r>=e.length-2?Ie(e[r]):e[r])),1===e.length&&(e=[2,e[0]])),2!==e.length){const t=Ne(e);e=t.newShape}let n=Ee(e);if(e.length<=1&&n<=r)return[1,n];if(2===e.length&&e[0]<=r&&e[1]<=r)return e;if(3===e.length&&e[0]*e[1]<=r&&e[2]<=r)return[e[0]*e[1],e[2]];if(3===e.length&&e[0]<=r&&e[1]*e[2]<=r)return[e[0],e[1]*e[2]];if(4===e.length&&e[0]*e[1]*e[2]<=r&&e[3]<=r)return[e[0]*e[1]*e[2],e[3]];if(4===e.length&&e[0]<=r&&e[1]*e[2]*e[3]<=r)return[e[0],e[1]*e[2]*e[3]];if(t){const t=VT(e);let r=2,P=2;return e.length&&([r,P]=XT(e)),n=t*(r/2)*(P/2),Ue(n).map((e=>2*e))}return Ue(n)}function _T(e){return e%2==0}function $T(e,t){if(Qe(e=e.slice(-2),t=t.slice(-2)))return!0;if(!e.length||!t.length)return!0;if(0===e[0]||0===e[1]||0===t[0]||0===t[1])return!0;if(e.length!==t.length){const r=e.slice(-1)[0],n=t.slice(-1)[0];if(r===n)return!0;if(_T(r)&&_T(n)&&(1===e[0]||1===t[0]))return!0}return e[1]===t[1]&&_T(e[0])&&_T(t[0])}let ez,tz;function rz(e){if(null==ez){const t=vT(e);ez=t.getParameter(t.MAX_TEXTURE_SIZE)}return ez}function nz(e){if(null==tz){const t=vT(e);tz=t.getParameter(t.MAX_TEXTURE_IMAGE_UNITS)}return Math.min(16,tz)}function Pz(e){if(0===e)return 0;let t;const r=vT(e);return t=az(r,"EXT_disjoint_timer_query_webgl2")&&2===e?2:az(r,"EXT_disjoint_timer_query")?1:0,t}function az(e,t){return null!=e.getExtension(t)}function oz(e){try{if(null!=vT(e))return!0}catch(e){return console.log("Error when getting WebGL context: ",e),!1}return!1}function uz(e){if(0===e)return!1;const t=vT(e);if(1===e){if(!az(t,"OES_texture_float"))return!1}else if(!az(t,"EXT_color_buffer_float"))return!1;return vz(t)}function sz(e){if(0===e)return!1;const t=vT(e);if(1!==e){if(az(t,"EXT_color_buffer_float"))return vz(t);const e="EXT_color_buffer_half_float";if(az(t,e)){const r=t.getExtension(e);return iz(t,r)}return!1}if(!az(t,"OES_texture_float"))return!1;if(!az(t,"WEBGL_color_buffer_float"))return!1;return vz(t)}function vz(e){const t=pT(e),r=e.createTexture();e.bindTexture(e.TEXTURE_2D,r);e.texImage2D(e.TEXTURE_2D,0,t.internalFormatFloat,1,1,0,t.textureFormatFloat,t.textureTypeFloat,null);const n=e.createFramebuffer();e.bindFramebuffer(e.FRAMEBUFFER,n),e.framebufferTexture2D(e.FRAMEBUFFER,e.COLOR_ATTACHMENT0,e.TEXTURE_2D,r,0);const P=e.checkFramebufferStatus(e.FRAMEBUFFER)===e.FRAMEBUFFER_COMPLETE;return e.bindTexture(e.TEXTURE_2D,null),e.bindFramebuffer(e.FRAMEBUFFER,null),e.deleteTexture(r),e.deleteFramebuffer(n),P}function iz(e,t){const r=pT(e,t),n=e.createTexture();e.bindTexture(e.TEXTURE_2D,n);e.texImage2D(e.TEXTURE_2D,0,r.internalFormatHalfFloat,1,1,0,r.textureFormatFloat,r.textureTypeHalfFloat,null);const P=e.createFramebuffer();e.bindFramebuffer(e.FRAMEBUFFER,P),e.framebufferTexture2D(e.FRAMEBUFFER,e.COLOR_ATTACHMENT0,e.TEXTURE_2D,n,0);const a=e.checkFramebufferStatus(e.FRAMEBUFFER)===e.FRAMEBUFFER_COMPLETE;return e.bindTexture(e.TEXTURE_2D,null),e.bindFramebuffer(e.FRAMEBUFFER,null),e.deleteTexture(n),e.deleteFramebuffer(P),a}function lz(e){if(2!==e)return!1;return null!=vT(e).fenceSync}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const cz=mt();
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function Oz(){let e,t,r,n,P,a,o,u,s,v;return 2===mt().getNumber("WEBGL_VERSION")?(e="#version 300 es",t="in",r="out",n="in",P="texture",a="outputColor",o="out vec4 outputColor;",u="\n      bool isnan_custom(float val) {\n        uint floatToUint = floatBitsToUint(val);\n        return (floatToUint & 0x7fffffffu) > 0x7f800000u;\n      }\n\n      bvec4 isnan_custom(vec4 val) {\n        return bvec4(isnan_custom(val.x),\n          isnan_custom(val.y), isnan_custom(val.z), isnan_custom(val.w));\n      }\n\n      #define isnan(value) isnan_custom(value)\n    ",s="",v="\n      #define round(value) newRound(value)\n      int newRound(float value) {\n        return int(floor(value + 0.5));\n      }\n\n      ivec4 newRound(vec4 value) {\n        return ivec4(floor(value + vec4(0.5)));\n      }\n    "):(e="",t="attribute",r="varying",n="varying",P="texture2D",a="gl_FragColor",o="",u="\n      #define isnan(value) isnan_custom(value)\n      bool isnan_custom(float val) {\n        return (val > 0. || val < 1. || val == 0.) ? false : true;\n      }\n      bvec4 isnan_custom(vec4 val) {\n        return bvec4(isnan(val.x), isnan(val.y), isnan(val.z), isnan(val.w));\n      }\n    ",s="\n      uniform float INFINITY;\n\n      bool isinf(float val) {\n        return abs(val) == INFINITY;\n      }\n      bvec4 isinf(vec4 val) {\n        return equal(abs(val), vec4(INFINITY));\n      }\n    ",v="\n      int round(float value) {\n        return int(floor(value + 0.5));\n      }\n\n      ivec4 round(vec4 value) {\n        return ivec4(floor(value + vec4(0.5)));\n      }\n    "),{version:e,attribute:t,varyingVs:r,varyingFs:n,texture2D:P,output:a,defineOutput:o,defineSpecialNaN:u,defineSpecialInf:s,defineRound:v}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Dz(e,t,r="index"){const n=Pt(t);return n.map(((t,P)=>`${`int ${e[P]} = ${r} / ${t}`}; ${P===n.length-1?`int ${e[P+1]} = ${r} - ${e[P]} * ${t}`:`index -= ${e[P]} * ${t}`};`)).join("")}function jz(e,t,r="index"){const n=Pt(t);return n.map(((t,P)=>`${`int ${e[P]} = ${r} / outShapeStrides[${P}]`}; ${P===n.length-1?`int ${e[P+1]} = ${r} - ${e[P]} * outShapeStrides[${P}]`:`index -= ${e[P]} * outShapeStrides[${P}]`};`)).join("")}function hz(e,t){const r=e.length,n=e.map((e=>`${t}[${e}]`)),P=new Array(r-1);P[r-2]=n[r-1];for(let e=r-3;e>=0;--e)P[e]=`(${P[e+1]} * ${n[e+1]})`;return P}function pz(e,t,r="index"){const n=e.map(((e,t)=>t)),P=hz(n,t);return P.map(((t,n)=>`${`int ${e[n]} = ${r} / ${P[n]}`}; ${n===P.length-1?`int ${e[n+1]} = ${r} - ${e[n]} * ${P[n]}`:`index -= ${e[n]} * ${P[n]}`};`)).join("")}function mz(e){const t=Pt(e).map((e=>e.toString()));return`\n  int getFlatIndex(ivec3 coords) {\n    return coords.x * ${t[0]} + coords.y * ${t[1]} + coords.z;\n  }\n`}cz.registerFlag("HAS_WEBGL",(()=>cz.getNumber("WEBGL_VERSION")>0)),cz.registerFlag("WEBGL_VERSION",(()=>oz(2)?2:oz(1)?1:0)),cz.registerFlag("WEBGL_CHECK_NUMERICAL_PROBLEMS",(()=>!1)),cz.registerFlag("WEBGL_BUFFER_SUPPORTED",(()=>2===cz.get("WEBGL_VERSION"))),cz.registerFlag("WEBGL_CPU_FORWARD",(()=>!0)),cz.registerFlag("WEBGL_FORCE_F16_TEXTURES",(()=>!1)),cz.registerFlag("WEBGL_PACK",(()=>cz.getBool("HAS_WEBGL"))),cz.registerFlag("WEBGL_PACK_NORMALIZATION",(()=>cz.getBool("WEBGL_PACK"))),cz.registerFlag("WEBGL_PACK_CLIP",(()=>cz.getBool("WEBGL_PACK"))),cz.registerFlag("WEBGL_PACK_DEPTHWISECONV",(()=>cz.getBool("WEBGL_PACK"))),cz.registerFlag("WEBGL_PACK_BINARY_OPERATIONS",(()=>cz.getBool("WEBGL_PACK"))),cz.registerFlag("WEBGL_PACK_UNARY_OPERATIONS",(()=>cz.getBool("WEBGL_PACK"))),cz.registerFlag("WEBGL_PACK_ARRAY_OPERATIONS",(()=>cz.getBool("WEBGL_PACK"))),cz.registerFlag("WEBGL_PACK_IMAGE_OPERATIONS",(()=>cz.getBool("WEBGL_PACK"))),cz.registerFlag("WEBGL_PACK_REDUCE",(()=>cz.getBool("WEBGL_PACK"))),cz.registerFlag("WEBGL_LAZILY_UNPACK",(()=>cz.getBool("WEBGL_PACK"))),cz.registerFlag("WEBGL_CONV_IM2COL",(()=>cz.getBool("WEBGL_PACK"))),cz.registerFlag("WEBGL_MAX_TEXTURE_SIZE",(()=>rz(cz.getNumber("WEBGL_VERSION")))),cz.registerFlag("WEBGL_MAX_TEXTURES_IN_SHADER",(()=>nz(cz.getNumber("WEBGL_VERSION")))),cz.registerFlag("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION",(()=>{const e=cz.getNumber("WEBGL_VERSION");return 0===e?0:Pz(e)})),cz.registerFlag("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE",(()=>cz.getNumber("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION")>0&&!Ga())),cz.registerFlag("WEBGL_RENDER_FLOAT32_CAPABLE",(()=>uz(cz.getNumber("WEBGL_VERSION")))),cz.registerFlag("WEBGL_RENDER_FLOAT32_ENABLED",(()=>!cz.getBool("WEBGL_FORCE_F16_TEXTURES")&&cz.getBool("WEBGL_RENDER_FLOAT32_CAPABLE"))),cz.registerFlag("WEBGL_DOWNLOAD_FLOAT_ENABLED",(()=>sz(cz.getNumber("WEBGL_VERSION")))),cz.registerFlag("WEBGL_FENCE_API_ENABLED",(()=>lz(cz.getNumber("WEBGL_VERSION")))),cz.registerFlag("WEBGL_SIZE_UPLOAD_UNIFORM",(()=>cz.getBool("WEBGL_RENDER_FLOAT32_ENABLED")?4:0)),cz.registerFlag("WEBGL_DELETE_TEXTURE_THRESHOLD",(()=>-1),(e=>{if(e<0&&-1!==e)throw new Error(`WEBGL_DELETE_TEXTURE_THRESHOLD must be -1 (indicating never delete) or at least 0, but got ${e}.`)})),cz.registerFlag("WEBGL_FLUSH_THRESHOLD",(()=>Ga()?1:-1),(e=>{if(e<0&&-1!==e)throw new Error(`WEBGL_FLUSH_THRESHOLD must be -1 (indicating never manual flush) or at least 0, but got ${e}.`)})),cz.registerFlag("CPU_HANDOFF_SIZE_THRESHOLD",(()=>128)),cz.registerFlag("WEBGL_USE_SHAPES_UNIFORMS",(()=>!1)),cz.registerFlag("TOPK_LAST_DIM_CPU_HANDOFF_SIZE_THRESHOLD",(()=>1e5)),cz.registerFlag("TOPK_K_CPU_HANDOFF_THRESHOLD",(()=>128));const gz="\n  const float FLOAT_MAX = 1.70141184e38;\n  const float FLOAT_MIN = 1.17549435e-38;\n\n  lowp vec4 encode_float(highp float v) {\n    if (isnan(v)) {\n      return vec4(255, 255, 255, 255);\n    }\n\n    highp float av = abs(v);\n\n    if(av < FLOAT_MIN) {\n      return vec4(0.0, 0.0, 0.0, 0.0);\n    } else if(v > FLOAT_MAX) {\n      return vec4(0.0, 0.0, 128.0, 127.0) / 255.0;\n    } else if(v < -FLOAT_MAX) {\n      return vec4(0.0, 0.0,  128.0, 255.0) / 255.0;\n    }\n\n    highp vec4 c = vec4(0,0,0,0);\n\n    highp float e = floor(log2(av));\n    highp float m = exp2(fract(log2(av))) - 1.0;\n\n    c[2] = floor(128.0 * m);\n    m -= c[2] / 128.0;\n    c[1] = floor(32768.0 * m);\n    m -= c[1] / 32768.0;\n    c[0] = floor(8388608.0 * m);\n\n    highp float ebias = e + 127.0;\n    c[3] = floor(ebias / 2.0);\n    ebias -= c[3] * 2.0;\n    c[2] += floor(ebias) * 128.0;\n\n    c[3] += 128.0 * step(0.0, -v);\n\n    return c / 255.0;\n  }\n"
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */,{getBroadcastDims:bz}=F;function Tz(e,t,r){const n=[];if(e.forEach((e=>{const t=Ee(e.shapeInfo.logicalShape);if(e.shapeInfo.isUniform?n.push(`uniform float ${e.name}${t>1?`[${t}]`:""};`):(n.push(`uniform sampler2D ${e.name};`),n.push(`uniform int offset${e.name};`)),r.enableShapeUniforms){const{uniformShape:t}=vd(r.packedInputs,e.shapeInfo.logicalShape,e.shapeInfo.texShape);switch(t.length){case 1:n.push(`uniform int ${e.name}Shape;`);break;case 2:n.push(`uniform ivec2 ${e.name}Shape;`);break;case 3:n.push(`uniform ivec3 ${e.name}Shape;`);break;case 4:n.push(`uniform ivec4 ${e.name}Shape;`)}n.push(`uniform ivec2 ${e.name}TexShape;`)}})),r.enableShapeUniforms){switch(t.logicalShape.length){case 1:n.push("uniform int outShape;");break;case 2:n.push("uniform ivec2 outShape;"),n.push("uniform int outShapeStrides;");break;case 3:n.push("uniform ivec3 outShape;"),n.push("uniform ivec2 outShapeStrides;");break;case 4:n.push("uniform ivec4 outShape;"),n.push("uniform ivec3 outShapeStrides;")}n.push("uniform ivec2 outTexShape;")}r.customUniforms&&r.customUniforms.forEach((e=>{n.push(`uniform ${e.type} ${e.name}${e.arrayIndex?`[${e.arrayIndex}]`:""};`)}));const P=n.join("\n"),a=e.map((e=>yz(e,t,r.packedInputs,r.enableShapeUniforms))).join("\n"),o=t.texShape,u=Oz(),s=fz(u);let v,i,l=Az(u);t.isPacked?(v=wz(t.logicalShape,o,r.enableShapeUniforms),i=Sz(u)):(v=Lz(t.logicalShape,o,r.enableShapeUniforms),i=Iz(u)),r.packedInputs&&(l+=Cz);return[l,s,i,P,v,a,r.userCode].join("\n")}function zz(e,t=!1){const r=e.shapeInfo.logicalShape;switch(r.length){case 0:return Vz(e,t);case 1:return Hz(e,t);case 2:return _z(e,t);case 3:return ed(e,t);case 4:return rd(e,t);case 5:return nd(e);case 6:return Pd(e);default:throw new Error(`${r.length}-D input sampling is not yet supported`)}}function dz(e,t){switch(e.shapeInfo.logicalShape.length){case 0:return Zz(e);case 1:return Xz(e,t);case 2:return Jz(e,t);case 3:return $z(e,t);default:return td(e,t)}}function yz(e,t,r=!1,n){let P="";P+=r?dz(e,n):zz(e,n);const a=e.shapeInfo.logicalShape,o=t.logicalShape;return a.length<=o.length&&(P+=r?od(e,t):ud(e,t)),P}function wz(e,t,r){switch(e.length){case 0:return Ez();case 1:return Qz(e,t,r);case 2:return Rz(e,t,r);case 3:return Uz(e,t,r);default:return Gz(e,t,r)}}function Lz(e,t,r){switch(e.length){case 0:return Ez();case 1:return Wz(e,t,r);case 2:return Fz(e,t,r);case 3:return qz(e,t,r);case 4:return Mz(e,t,r);case 5:return Kz(e,t);case 6:return Nz(e,t);default:throw new Error(`${e.length}-D output sampling is not yet supported`)}}function fz(e){return`\n    float sampleTexture(sampler2D textureSampler, vec2 uv) {\n      return ${e.texture2D}(textureSampler, uv).r;\n    }\n  `}function Iz(e){return`\n    void setOutput(float val) {\n      ${e.output} = vec4(val, 0, 0, 0);\n    }\n  `}function Sz(e){return`\n    void setOutput(vec4 val) {\n      ${e.output} = val;\n    }\n  `}function Az(e){return`${e.version}\n    precision highp float;\n    precision highp int;\n    precision highp sampler2D;\n    ${e.varyingFs} vec2 resultUV;\n    ${e.defineOutput}\n    const vec2 halfCR = vec2(0.5, 0.5);\n\n    struct ivec5\n    {\n      int x;\n      int y;\n      int z;\n      int w;\n      int u;\n    };\n\n    struct ivec6\n    {\n      int x;\n      int y;\n      int z;\n      int w;\n      int u;\n      int v;\n    };\n\n    uniform float NAN;\n    ${e.defineSpecialNaN}\n    ${e.defineSpecialInf}\n    ${e.defineRound}\n\n    int imod(int x, int y) {\n      return x - y * (x / y);\n    }\n\n    int idiv(int a, int b, float sign) {\n      int res = a / b;\n      int mod = imod(a, b);\n      if (sign < 0. && mod != 0) {\n        res -= 1;\n      }\n      return res;\n    }\n\n    //Based on the work of Dave Hoskins\n    //https://www.shadertoy.com/view/4djSRW\n    #define HASHSCALE1 443.8975\n    float random(float seed){\n      vec2 p = resultUV * seed;\n      vec3 p3  = fract(vec3(p.xyx) * HASHSCALE1);\n      p3 += dot(p3, p3.yzx + 19.19);\n      return fract((p3.x + p3.y) * p3.z);\n    }\n\n    ${xz}\n    ${Yz}\n    ${kz}\n  `}const xz="\nvec2 uvFromFlat(int texNumR, int texNumC, int index) {\n  int texR = index / texNumC;\n  int texC = index - texR * texNumC;\n  return (vec2(texC, texR) + halfCR) / vec2(texNumC, texNumR);\n}\nvec2 packedUVfrom1D(int texNumR, int texNumC, int index) {\n  int texelIndex = index / 2;\n  int texR = texelIndex / texNumC;\n  int texC = texelIndex - texR * texNumC;\n  return (vec2(texC, texR) + halfCR) / vec2(texNumC, texNumR);\n}\n",Yz="\nvec2 packedUVfrom2D(int texelsInLogicalRow, int texNumR,\n  int texNumC, int row, int col) {\n  int texelIndex = (row / 2) * texelsInLogicalRow + (col / 2);\n  int texR = texelIndex / texNumC;\n  int texC = texelIndex - texR * texNumC;\n  return (vec2(texC, texR) + halfCR) / vec2(texNumC, texNumR);\n}\n",kz="\nvec2 packedUVfrom3D(int texNumR, int texNumC,\n    int texelsInBatch, int texelsInLogicalRow, int b,\n    int row, int col) {\n  int index = b * texelsInBatch + (row / 2) * texelsInLogicalRow + (col / 2);\n  int texR = index / texNumC;\n  int texC = index - texR * texNumC;\n  return (vec2(texC, texR) + halfCR) / vec2(texNumC, texNumR);\n}\n",Cz="\n  float getChannel(vec4 frag, vec2 innerDims) {\n    vec2 modCoord = mod(innerDims, 2.);\n    return modCoord.x == 0. ?\n      (modCoord.y == 0. ? frag.r : frag.g) :\n      (modCoord.y == 0. ? frag.b : frag.a);\n  }\n  float getChannel(vec4 frag, int dim) {\n    float modCoord = mod(float(dim), 2.);\n    return modCoord == 0. ? frag.r : frag.g;\n  }\n";function Ez(){return"\n    int getOutputCoords() {\n      return 0;\n    }\n  "}function Qz(e,t,r){const n=[Math.ceil(t[0]/2),Math.ceil(t[1]/2)];return 1===n[0]?r?"\n      int getOutputCoords() {\n        return 2 * int(resultUV.x * ceil(float(outTexShape[1]) / 2.0));\n      }\n    ":`\n      int getOutputCoords() {\n        return 2 * int(resultUV.x * ${n[1]}.0);\n      }\n    `:1===n[1]?r?"\n      int getOutputCoords() {\n        return 2 * int(resultUV.y * ceil(float(outTexShape[0]) / 2.0));\n      }\n    ":`\n      int getOutputCoords() {\n        return 2 * int(resultUV.y * ${n[0]}.0);\n      }\n    `:r?"\n    int getOutputCoords() {\n      ivec2 packedTexShape = ivec2(ceil(float(outTexShape[0]) / 2.0), ceil(float(outTexShape[1]) / 2.0));\n      ivec2 resTexRC = ivec2(resultUV.yx *\n                             vec2(packedTexShape[0], packedTexShape[1]));\n      return 2 * (resTexRC.x * packedTexShape[1] + resTexRC.y);\n    }\n  ":`\n    int getOutputCoords() {\n      ivec2 resTexRC = ivec2(resultUV.yx *\n                             vec2(${n[0]}, ${n[1]}));\n      return 2 * (resTexRC.x * ${n[1]} + resTexRC.y);\n    }\n  `}function Wz(e,t,r){return 1===t[0]?r?"\n      int getOutputCoords() {\n        return int(resultUV.x * float(outTexShape[1]));\n      }\n    ":`\n      int getOutputCoords() {\n        return int(resultUV.x * ${t[1]}.0);\n      }\n    `:1===t[1]?r?"\n      int getOutputCoords() {\n        return int(resultUV.y * float(outTexShape[0]));\n      }\n    ":`\n      int getOutputCoords() {\n        return int(resultUV.y * ${t[0]}.0);\n      }\n    `:r?"\n    int getOutputCoords() {\n      ivec2 resTexRC = ivec2(resultUV.yx *\n                             vec2(outTexShape[0], outTexShape[1]));\n      return resTexRC.x * outTexShape[1] + resTexRC.y;\n    }\n  ":`\n    int getOutputCoords() {\n      ivec2 resTexRC = ivec2(resultUV.yx *\n                             vec2(${t[0]}, ${t[1]}));\n      return resTexRC.x * ${t[1]} + resTexRC.y;\n    }\n  `}function Uz(e,t,r){if(r)return"\n    ivec3 getOutputCoords() {\n      ivec2 packedTexShape = ivec2(ceil(float(outTexShape[0]) / 2.0), ceil(float(outTexShape[1]) / 2.0));\n      int texelsInLogicalRow = int(ceil(float(outShape[2]) / 2.0));\n      int texelsInBatch = texelsInLogicalRow * int(ceil(float(outShape[1]) / 2.0));\n      ivec2 resTexRC = ivec2(resultUV.yx *\n                             vec2(packedTexShape[0], packedTexShape[1]));\n      int index = resTexRC.x * packedTexShape[1] + resTexRC.y;\n\n      int b = index / texelsInBatch;\n      index -= b * texelsInBatch;\n\n      int r = 2 * (index / texelsInLogicalRow);\n      int c = imod(index, texelsInLogicalRow) * 2;\n\n      return ivec3(b, r, c);\n    }\n  ";const n=[Math.ceil(t[0]/2),Math.ceil(t[1]/2)],P=Math.ceil(e[2]/2),a=P*Math.ceil(e[1]/2);return`\n    ivec3 getOutputCoords() {\n      ivec2 resTexRC = ivec2(resultUV.yx *\n                             vec2(${n[0]}, ${n[1]}));\n      int index = resTexRC.x * ${n[1]} + resTexRC.y;\n\n      int b = index / ${a};\n      index -= b * ${a};\n\n      int r = 2 * (index / ${P});\n      int c = imod(index, ${P}) * 2;\n\n      return ivec3(b, r, c);\n    }\n  `}function qz(e,t,r){if(r){return`\n  ivec3 getOutputCoords() {\n    ivec2 resTexRC = ivec2(resultUV.yx *\n                           vec2(outTexShape[0], outTexShape[1]));\n    int index = resTexRC.x * outTexShape[1] + resTexRC.y;\n    ${jz(["r","c","d"],e)}\n    return ivec3(r, c, d);\n  }\n`}const n=Dz(["r","c","d"],e);return`\n    ivec3 getOutputCoords() {\n      ivec2 resTexRC = ivec2(resultUV.yx *\n                             vec2(${t[0]}, ${t[1]}));\n      int index = resTexRC.x * ${t[1]} + resTexRC.y;\n      ${n}\n      return ivec3(r, c, d);\n    }\n  `}function Gz(e,t,r){if(r)return"\n    ivec4 getOutputCoords() {\n      ivec2 packedTexShape = ivec2(ceil(float(outTexShape[0]) / 2.0), ceil(float(outTexShape[1]) / 2.0));\n      ivec2 resTexRC = ivec2(resultUV.yx *\n                             vec2(packedTexShape[0], packedTexShape[1]));\n      int index = resTexRC.x * packedTexShape[1] + resTexRC.y;\n\n      int texelsInLogicalRow = int(ceil(float(outShape[3]) / 2.0));\n      int texelsInBatch = texelsInLogicalRow * int(ceil(float(outShape[2]) / 2.0));\n      int texelsInBatchN = texelsInBatch * outShape[1];\n\n      int b2 = index / texelsInBatchN;\n      index -= b2 * texelsInBatchN;\n\n      int b = index / texelsInBatch;\n      index -= b * texelsInBatch;\n\n      int r = 2 * (index / texelsInLogicalRow);\n      int c = imod(index, texelsInLogicalRow) * 2;\n\n      return ivec4(b2, b, r, c);\n    }\n  ";const n=[Math.ceil(t[0]/2),Math.ceil(t[1]/2)],P=Math.ceil(e[e.length-1]/2),a=P*Math.ceil(e[e.length-2]/2);let o=a,u="",s="b, r, c";for(let t=2;t<e.length-1;t++)o*=e[e.length-t-1],u=`\n      int b${t} = index / ${o};\n      index -= b${t} * ${o};\n    `+u,s=`b${t}, `+s;return`\n    ivec${e.length} getOutputCoords() {\n      ivec2 resTexRC = ivec2(resultUV.yx *\n                             vec2(${n[0]}, ${n[1]}));\n      int index = resTexRC.x * ${n[1]} + resTexRC.y;\n\n      ${u}\n\n      int b = index / ${a};\n      index -= b * ${a};\n\n      int r = 2 * (index / ${P});\n      int c = imod(index, ${P}) * 2;\n\n      return ivec${e.length}(${s});\n    }\n  `}function Mz(e,t,r){if(r){return`\n    ivec4 getOutputCoords() {\n      ivec2 resTexRC = ivec2(resultUV.yx *\n        vec2(outTexShape[0], outTexShape[1]));\n      int index = resTexRC.x * outTexShape[1] + resTexRC.y;\n      ${jz(["r","c","d","d2"],e)}\n      return ivec4(r, c, d, d2);\n    }\n  `}const n=Dz(["r","c","d","d2"],e);return`\n    ivec4 getOutputCoords() {\n      ivec2 resTexRC = ivec2(resultUV.yx *\n        vec2(${t[0]}, ${t[1]}));\n      int index = resTexRC.x * ${t[1]} + resTexRC.y;\n      ${n}\n      return ivec4(r, c, d, d2);\n    }\n  `}function Kz(e,t){const r=Dz(["r","c","d","d2","d3"],e);return`\n    ivec5 getOutputCoords() {\n      ivec2 resTexRC = ivec2(resultUV.yx * vec2(${t[0]},\n                             ${t[1]}));\n\n      int index = resTexRC.x * ${t[1]} + resTexRC.y;\n\n      ${r}\n\n      ivec5 outShape = ivec5(r, c, d, d2, d3);\n      return outShape;\n    }\n  `}function Nz(e,t){const r=Dz(["r","c","d","d2","d3","d4"],e);return`\n    ivec6 getOutputCoords() {\n      ivec2 resTexRC = ivec2(resultUV.yx *\n        vec2(${t[0]}, ${t[1]}));\n      int index = resTexRC.x * ${t[1]} + resTexRC.y;\n\n      ${r}\n\n      ivec6 result = ivec6(r, c, d, d2, d3, d4);\n      return result;\n    }\n  `}function Rz(e,t,r){const n=[Math.ceil(t[0]/2),Math.ceil(t[1]/2)];if(Qe(e,t))return r?"\n      ivec2 getOutputCoords() {\n        ivec2 packedTexShape = ivec2(ceil(float(outTexShape[0]) / 2.0), ceil(float(outTexShape[1]) / 2.0));\n        return 2 * ivec2(resultUV.yx * vec2(packedTexShape[0], packedTexShape[1]));\n      }\n    ":`\n      ivec2 getOutputCoords() {\n        return 2 * ivec2(resultUV.yx * vec2(${n[0]}, ${n[1]}));\n      }\n    `;const P=Math.ceil(e[1]/2);return r?"\n    ivec2 getOutputCoords() {\n      ivec2 packedTexShape = ivec2(ceil(float(outTexShape[0]) / 2.0), ceil(float(outTexShape[1]) / 2.0));\n      int texelsInLogicalRow = int(ceil(float(outShape[1]) / 2.0));\n      ivec2 resTexRC = ivec2(resultUV.yx *\n                             vec2(packedTexShape[0], packedTexShape[1]));\n\n      int index = resTexRC.x * packedTexShape[1] + resTexRC.y;\n      int r = 2 * (index / texelsInLogicalRow);\n      int c = imod(index, texelsInLogicalRow) * 2;\n\n      return ivec2(r, c);\n    }\n  ":`\n    ivec2 getOutputCoords() {\n      ivec2 resTexRC = ivec2(resultUV.yx *\n                             vec2(${n[0]}, ${n[1]}));\n\n      int index = resTexRC.x * ${n[1]} + resTexRC.y;\n      int r = 2 * (index / ${P});\n      int c = imod(index, ${P}) * 2;\n\n      return ivec2(r, c);\n    }\n  `}function Fz(e,t,r){return Qe(e,t)?r?"\n      ivec2 getOutputCoords() {\n        return ivec2(resultUV.yx * vec2(outTexShape[0], outTexShape[1]));\n      }\n    ":`\n      ivec2 getOutputCoords() {\n        return ivec2(resultUV.yx * vec2(${t[0]}, ${t[1]}));\n      }\n    `:1===e[1]?r?"\n      ivec2 getOutputCoords() {\n        ivec2 resTexRC = ivec2(resultUV.yx *\n                               vec2(outTexShape[0], outTexShape[1]));\n        int index = resTexRC.x * outTexShape[1] + resTexRC.y;\n        return ivec2(index, 0);\n      }\n    ":`\n      ivec2 getOutputCoords() {\n        ivec2 resTexRC = ivec2(resultUV.yx *\n                               vec2(${t[0]}, ${t[1]}));\n        int index = resTexRC.x * ${t[1]} + resTexRC.y;\n        return ivec2(index, 0);\n      }\n    `:1===e[0]?r?"\n      ivec2 getOutputCoords() {\n        ivec2 resTexRC = ivec2(resultUV.yx *\n                               vec2(outTexShape[0], outTexShape[1]));\n        int index = resTexRC.x * outTexShape[1] + resTexRC.y;\n        return ivec2(0, index);\n      }\n    ":`\n      ivec2 getOutputCoords() {\n        ivec2 resTexRC = ivec2(resultUV.yx *\n                               vec2(${t[0]}, ${t[1]}));\n        int index = resTexRC.x * ${t[1]} + resTexRC.y;\n        return ivec2(0, index);\n      }\n    `:r?"\n    ivec2 getOutputCoords() {\n      ivec2 resTexRC = ivec2(resultUV.yx *\n                             vec2(outTexShape[0], outTexShape[1]));\n      int index = resTexRC.x * outTexShape[1] + resTexRC.y;\n      int r = index / outShape[1];\n      int c = index - r * outShape[1];\n      return ivec2(r, c);\n    }\n  ":`\n    ivec2 getOutputCoords() {\n      ivec2 resTexRC = ivec2(resultUV.yx *\n                             vec2(${t[0]}, ${t[1]}));\n      int index = resTexRC.x * ${t[1]} + resTexRC.y;\n      int r = index / ${e[1]};\n      int c = index - r * ${e[1]};\n      return ivec2(r, c);\n    }\n  `}function Bz(e){return`offset${e}`}function Zz(e){const t=e.name;return`\n    vec4 ${"get"+t.charAt(0).toUpperCase()+t.slice(1)}() {\n      return ${Oz().texture2D}(${t}, halfCR);\n    }\n  `}function Vz(e,t){const r=e.name,n="get"+r.charAt(0).toUpperCase()+r.slice(1);if(e.shapeInfo.isUniform)return`float ${n}() {return ${r};}`;const[P,a]=e.shapeInfo.texShape;if(1===P&&1===a)return`\n      float ${n}() {\n        return sampleTexture(${r}, halfCR);\n      }\n    `;const o=Bz(r);if(t)return`\n    float ${n}() {\n      vec2 uv = uvFromFlat(${r}TexShape[0], ${r}TexShape[1], ${o});\n      return sampleTexture(${r}, uv);\n    }\n  `;const[u,s]=e.shapeInfo.texShape;return`\n    float ${n}() {\n      vec2 uv = uvFromFlat(${u}, ${s}, ${o});\n      return sampleTexture(${r}, uv);\n    }\n  `}function Xz(e,t){const r=e.name,n="get"+r.charAt(0).toUpperCase()+r.slice(1),P=e.shapeInfo.texShape,a=Oz();if(t)return`\n    vec4 ${n}(int index) {\n      ivec2 packedTexShape = ivec2(ceil(float(${r}TexShape[0]) / 2.0), ceil(float(${r}TexShape[1]) / 2.0));\n      vec2 uv = packedUVfrom1D(\n        packedTexShape[0], packedTexShape[1], index);\n      return ${a.texture2D}(${r}, uv);\n    }\n  `;const o=[Math.ceil(P[0]/2),Math.ceil(P[1]/2)];return`\n    vec4 ${n}(int index) {\n      vec2 uv = packedUVfrom1D(\n        ${o[0]}, ${o[1]}, index);\n      return ${a.texture2D}(${r}, uv);\n    }\n  `}function Hz(e,t){const r=e.name,n="get"+r.charAt(0).toUpperCase()+r.slice(1);if(e.shapeInfo.isUniform)return`\n      float ${n}(int index) {\n        ${ad(e)}\n      }\n    `;const P=e.shapeInfo.texShape,a=P[0],o=P[1];if(1===o&&1===a)return`\n      float ${n}(int index) {\n        return sampleTexture(${r}, halfCR);\n      }\n    `;const u=Bz(r);return 1===o?t?`\n      float ${n}(int index) {\n        vec2 uv = vec2(0.5, (float(index + ${u}) + 0.5) / float(${r}TexShape[0]));\n        return sampleTexture(${r}, uv);\n      }\n    `:`\n      float ${n}(int index) {\n        vec2 uv = vec2(0.5, (float(index + ${u}) + 0.5) / ${a}.0);\n        return sampleTexture(${r}, uv);\n      }\n    `:1===a?t?`\n      float ${n}(int index) {\n        vec2 uv = vec2((float(index + ${u}) + 0.5) / float(${r}TexShape[1]), 0.5);\n        return sampleTexture(${r}, uv);\n      }\n    `:`\n      float ${n}(int index) {\n        vec2 uv = vec2((float(index + ${u}) + 0.5) / ${o}.0, 0.5);\n        return sampleTexture(${r}, uv);\n      }\n    `:t?`\n    float ${n}(int index) {\n      vec2 uv = uvFromFlat(${r}TexShape[0], ${r}TexShape[1], index + ${u});\n      return sampleTexture(${r}, uv);\n    }\n  `:`\n    float ${n}(int index) {\n      vec2 uv = uvFromFlat(${a}, ${o}, index + ${u});\n      return sampleTexture(${r}, uv);\n    }\n  `}function Jz(e,t){const r=e.shapeInfo.logicalShape,n=e.name,P="get"+n.charAt(0).toUpperCase()+n.slice(1),a=e.shapeInfo.texShape,o=a[0],u=a[1],s=Oz();if(null!=a&&Qe(r,a))return t?`\n      vec4 ${P}(int row, int col) {\n        vec2 uv = (vec2(col, row) + halfCR) / vec2(${n}TexShape[1], ${n}TexShape[0]);\n\n        return ${s.texture2D}(${n}, uv);\n      }\n    `:`\n      vec4 ${P}(int row, int col) {\n        vec2 uv = (vec2(col, row) + halfCR) / vec2(${u}.0, ${o}.0);\n\n        return ${s.texture2D}(${n}, uv);\n      }\n    `;if(t)return`\n    vec4 ${P}(int row, int col) {\n      ivec2 packedTexShape = ivec2(ceil(float(${n}TexShape[0]) / 2.0), ceil(float(${n}TexShape[1]) / 2.0));\n      int valuesPerRow = int(ceil(float(${n}Shape[1]) / 2.0));\n      vec2 uv = packedUVfrom2D(valuesPerRow, packedTexShape[0], packedTexShape[1], row, col);\n      return ${s.texture2D}(${n}, uv);\n    }\n  `;const v=[Math.ceil(a[0]/2),Math.ceil(a[1]/2)];return`\n    vec4 ${P}(int row, int col) {\n      vec2 uv = packedUVfrom2D(${Math.ceil(r[1]/2)}, ${v[0]}, ${v[1]}, row, col);\n      return ${s.texture2D}(${n}, uv);\n    }\n  `}function _z(e,t){const r=e.shapeInfo.logicalShape,n=e.name,P="get"+n.charAt(0).toUpperCase()+n.slice(1),a=e.shapeInfo.texShape;if(null!=a&&Qe(r,a)){if(t)return`\n      float ${P}(int row, int col) {\n        vec2 uv = (vec2(col, row) + halfCR) / vec2(${n}TexShape[1], ${n}TexShape[0]);\n        return sampleTexture(${n}, uv);\n      }\n    `;const e=a[0];return`\n    float ${P}(int row, int col) {\n      vec2 uv = (vec2(col, row) + halfCR) / vec2(${a[1]}.0, ${e}.0);\n      return sampleTexture(${n}, uv);\n    }\n  `}const{newShape:o,keptDims:u}=Ne(r),s=o;if(s.length<r.length){const r=["row","col"];return`\n      ${zz(id(e,s),t)}\n      float ${P}(int row, int col) {\n        return ${P}(${ld(r,u)});\n      }\n    `}if(e.shapeInfo.isUniform)return`\n      float ${P}(int row, int col) {\n        int index = round(dot(vec2(row, col), vec2(${r[1]}, 1)));\n        ${ad(e)}\n      }\n    `;const v=a[0],i=a[1],l=Bz(n);return 1===i?t?`\n      float ${P}(int row, int col) {\n        float index = dot(vec3(row, col, ${l}), vec3(${n}Shape[1], 1, 1));\n        vec2 uv = vec2(0.5, (index + 0.5) / float(${n}TexShape[0]));\n        return sampleTexture(${n}, uv);\n      }\n    `:`\n    float ${P}(int row, int col) {\n      float index = dot(vec3(row, col, ${l}), vec3(${r[1]}, 1, 1));\n      vec2 uv = vec2(0.5, (index + 0.5) / ${v}.0);\n      return sampleTexture(${n}, uv);\n    }\n  `:1===v?t?`\n      float ${P}(int row, int col) {\n        float index = dot(vec3(row, col, ${l}), vec3(${n}Shape[1], 1, 1));\n        vec2 uv = vec2((index + 0.5) / float(${n}TexShape[1]), 0.5);\n        return sampleTexture(${n}, uv);\n      }\n    `:`\n    float ${P}(int row, int col) {\n      float index = dot(vec3(row, col, ${l}), vec3(${r[1]}, 1, 1));\n      vec2 uv = vec2((index + 0.5) / ${i}.0, 0.5);\n      return sampleTexture(${n}, uv);\n    }\n  `:t?`\n      float ${P}(int row, int col) {\n        // Explicitly use integer operations as dot() only works on floats.\n        int index = row * ${n}Shape[1] + col + ${l};\n        vec2 uv = uvFromFlat(${n}TexShape[0], ${n}TexShape[1], index);\n        return sampleTexture(${n}, uv);\n      }\n    `:`\n  float ${P}(int row, int col) {\n    // Explicitly use integer operations as dot() only works on floats.\n    int index = row * ${r[1]} + col + ${l};\n    vec2 uv = uvFromFlat(${v}, ${i}, index);\n    return sampleTexture(${n}, uv);\n  }\n`}function $z(e,t){const r=e.shapeInfo.logicalShape,n=e.name,P="get"+n.charAt(0).toUpperCase()+n.slice(1),a=e.shapeInfo.texShape,o=[Math.ceil(a[0]/2),Math.ceil(a[1]/2)];if(1===r[0]){const n=[1,2],a=["b","row","col"];return`\n        ${dz(id(e,r.slice(1)),t)}\n        vec4 ${P}(int b, int row, int col) {\n          return ${P}(${ld(a,n)});\n        }\n      `}const u=Oz();if(t)return`\n    vec4 ${P}(int b, int row, int col) {\n      ivec2 packedTexShape = ivec2(ceil(float(${n}TexShape[0]) / 2.0), ceil(float(${n}TexShape[1]) / 2.0));\n      int valuesPerRow = int(ceil(float(${n}Shape[2]) / 2.0));\n      int texelsInBatch = valuesPerRow * int(ceil(float(${n}Shape[1]) / 2.0));\n      vec2 uv = packedUVfrom3D(\n        packedTexShape[0], packedTexShape[1], texelsInBatch, valuesPerRow, b, row, col);\n      return ${u.texture2D}(${n}, uv);\n    }\n  `;const s=o[0],v=o[1],i=Math.ceil(r[2]/2);return`\n    vec4 ${P}(int b, int row, int col) {\n      vec2 uv = packedUVfrom3D(\n        ${s}, ${v}, ${i*Math.ceil(r[1]/2)}, ${i}, b, row, col);\n      return ${u.texture2D}(${n}, uv);\n    }\n  `}function ed(e,t){const r=e.shapeInfo.logicalShape,n=e.name,P="get"+n.charAt(0).toUpperCase()+n.slice(1),a=r[1]*r[2],o=r[2],{newShape:u,keptDims:s}=Ne(r),v=u;if(v.length<r.length){const r=["row","col","depth"];return`\n        ${zz(id(e,v),t)}\n        float ${P}(int row, int col, int depth) {\n          return ${P}(${ld(r,s)});\n        }\n      `}if(e.shapeInfo.isUniform)return`\n      float ${P}(int row, int col, int depth) {\n        int index = round(dot(vec3(row, col, depth),\n                          vec3(${a}, ${o}, 1)));\n        ${ad(e)}\n      }\n    `;const i=e.shapeInfo.texShape,l=i[0],c=i[1],O=e.shapeInfo.flatOffset;if(c===a&&null==O)return t?`\n      float ${P}(int row, int col, int depth) {\n        int stride1 = ${n}Shape[2];\n        float texR = float(row);\n        float texC = dot(vec2(col, depth), vec2(stride1, 1));\n        vec2 uv = (vec2(texC, texR) + halfCR) /\n                   vec2(${n}TexShape[1], ${n}TexShape[0]);\n        return sampleTexture(${n}, uv);\n      }\n    `:`\n        float ${P}(int row, int col, int depth) {\n          float texR = float(row);\n          float texC = dot(vec2(col, depth), vec2(${o}, 1));\n          vec2 uv = (vec2(texC, texR) + halfCR) /\n                     vec2(${c}.0, ${l}.0);\n          return sampleTexture(${n}, uv);\n        }\n      `;if(c===o&&null==O)return t?`\n      float ${P}(int row, int col, int depth) {\n        float texR = dot(vec2(row, col), vec2(${n}Shape[1], 1));\n        float texC = float(depth);\n        vec2 uv = (vec2(texC, texR) + halfCR) / vec2(${n}TexShape[1], ${n}TexShape[0]);\n        return sampleTexture(${n}, uv);\n      }\n    `:`\n    float ${P}(int row, int col, int depth) {\n      float texR = dot(vec2(row, col), vec2(${r[1]}, 1));\n      float texC = float(depth);\n      vec2 uv = (vec2(texC, texR) + halfCR) / vec2(${c}.0, ${l}.0);\n      return sampleTexture(${n}, uv);\n    }\n  `;const D=Bz(n);return t?`\n    float ${P}(int row, int col, int depth) {\n      // Explicitly use integer operations as dot() only works on floats.\n      int stride0 = ${n}Shape[1] * ${n}Shape[2];\n      int stride1 = ${n}Shape[2];\n      int index = row * ${a} + col * ${o} + depth + ${D};\n      vec2 uv = uvFromFlat(${n}TexShape[0], ${n}TexShape[1], index);\n      return sampleTexture(${n}, uv);\n    }\n    `:`\n      float ${P}(int row, int col, int depth) {\n        // Explicitly use integer operations as dot() only works on floats.\n        int index = row * ${a} + col * ${o} + depth + ${D};\n        vec2 uv = uvFromFlat(${l}, ${c}, index);\n        return sampleTexture(${n}, uv);\n      }\n  `}function td(e,t){const r=e.name,n="get"+r.charAt(0).toUpperCase()+r.slice(1),P=Oz();if(t)return`\n    vec4 ${n}(int b2, int b, int row, int col) {\n      int valuesPerRow = int(ceil(float(${r}Shape[3]) / 2.0));\n      int texelsInBatch = valuesPerRow * int(ceil(float(${r}Shape[2]) / 2.0));\n      int index = b * texelsInBatch + (row / 2) * valuesPerRow + (col / 2);\n      texelsInBatch *= ${r}Shape[1];\n      index = b2 * texelsInBatch + index;\n      ivec2 packedTexShape = ivec2(ceil(float(${r}TexShape[0]) / 2.0), ceil(float(${r}TexShape[1]) / 2.0));\n      int texR = index / packedTexShape[1];\n      int texC = index - texR * packedTexShape[1];\n      vec2 uv = (vec2(texC, texR) + halfCR) / vec2(packedTexShape[1], packedTexShape[0]); return ${P.texture2D}(${r}, uv);\n    }\n  `;const a=e.shapeInfo.logicalShape,o=a.length,u=e.shapeInfo.texShape,s=[Math.ceil(u[0]/2),Math.ceil(u[1]/2)],v=s[0],i=s[1],l=Math.ceil(a[o-1]/2);let c=l*Math.ceil(a[o-2]/2),O="int b, int row, int col",D=`b * ${c} + (row / 2) * ${l} + (col / 2)`;for(let e=2;e<o-1;e++)O=`int b${e}, `+O,c*=a[o-e-1],D=`b${e} * ${c} + `+D;return`\n    vec4 ${n}(${O}) {\n      int index = ${D};\n      int texR = index / ${i};\n      int texC = index - texR * ${i};\n      vec2 uv = (vec2(texC, texR) + halfCR) / vec2(${i}, ${v});\n      return ${P.texture2D}(${r}, uv);\n    }\n  `}function rd(e,t){const r=e.shapeInfo.logicalShape,n=e.name,P="get"+n.charAt(0).toUpperCase()+n.slice(1),a=r[3],o=r[2]*a,u=r[1]*o,{newShape:s,keptDims:v}=Ne(r);if(s.length<r.length){const r=["row","col","depth","depth2"];return`\n      ${zz(id(e,s),t)}\n      float ${P}(int row, int col, int depth, int depth2) {\n        return ${P}(${ld(r,v)});\n      }\n    `}if(e.shapeInfo.isUniform)return`\n      float ${P}(int row, int col, int depth, int depth2) {\n        int index = round(dot(vec4(row, col, depth, depth2),\n                          vec4(${u}, ${o}, ${a}, 1)));\n        ${ad(e)}\n      }\n    `;const i=e.shapeInfo.flatOffset,l=e.shapeInfo.texShape,c=l[0],O=l[1],D=`int stride2 = ${n}Shape[3];`,j=`int stride1 = ${n}Shape[2] * stride2;`,h=`int stride0 = ${n}Shape[1] * stride1;`;if(O===u&&null==i)return t?`\n      float ${P}(int row, int col, int depth, int depth2) {\n        ${D}\n        ${j}\n        float texR = float(row);\n        float texC =\n            dot(vec3(col, depth, depth2),\n                vec3(stride1, stride2, 1));\n        vec2 uv = (vec2(texC, texR) + halfCR) /\n                   vec2(${n}TexShape[1], ${n}TexShape[0]);\n        return sampleTexture(${n}, uv);\n      }\n    `:`\n      float ${P}(int row, int col, int depth, int depth2) {\n        float texR = float(row);\n        float texC =\n            dot(vec3(col, depth, depth2),\n                vec3(${o}, ${a}, 1));\n        vec2 uv = (vec2(texC, texR) + halfCR) /\n                   vec2(${O}.0, ${c}.0);\n        return sampleTexture(${n}, uv);\n      }\n    `;if(O===a&&null==i)return t?`\n      float ${P}(int row, int col, int depth, int depth2) {\n        float texR = dot(vec3(row, col, depth),\n                         vec3(${n}Shape[1] * ${n}Shape[2], ${n}Shape[2], 1));\n        float texC = float(depth2);\n        vec2 uv = (vec2(texC, texR) + halfCR) /\n                  vec2(${n}TexShape[1], ${n}TexShape[0]);\n        return sampleTexture(${n}, uv);\n      }\n    `:`\n      float ${P}(int row, int col, int depth, int depth2) {\n        float texR = dot(vec3(row, col, depth),\n                         vec3(${r[1]*r[2]}, ${r[2]}, 1));\n        float texC = float(depth2);\n        vec2 uv = (vec2(texC, texR) + halfCR) /\n                  vec2(${O}.0, ${c}.0);\n        return sampleTexture(${n}, uv);\n      }\n    `;const p=Bz(n);return t?`\n    float ${P}(int row, int col, int depth, int depth2) {\n      // Explicitly use integer operations as dot() only works on floats.\n      ${D}\n      ${j}\n      ${h}\n      int index = row * stride0 + col * stride1 +\n          depth * stride2 + depth2;\n      vec2 uv = uvFromFlat(${n}TexShape[0], ${n}TexShape[1], index + ${p});\n      return sampleTexture(${n}, uv);\n    }\n  `:`\n    float ${P}(int row, int col, int depth, int depth2) {\n      // Explicitly use integer operations as dot() only works on floats.\n      int index = row * ${u} + col * ${o} +\n          depth * ${a} + depth2;\n      vec2 uv = uvFromFlat(${c}, ${O}, index + ${p});\n      return sampleTexture(${n}, uv);\n    }\n  `}function nd(e){const t=e.shapeInfo.logicalShape,r=e.name,n="get"+r.charAt(0).toUpperCase()+r.slice(1),P=t[4],a=t[3]*P,o=t[2]*a,u=t[1]*o,{newShape:s,keptDims:v}=Ne(t);if(s.length<t.length){const t=["row","col","depth","depth2","depth3"];return`\n      ${zz(id(e,s))}\n      float ${n}(int row, int col, int depth, int depth2, int depth3) {\n        return ${n}(${ld(t,v)});\n      }\n    `}if(e.shapeInfo.isUniform)return`\n      float ${n}(int row, int col, int depth, int depth2, int depth3) {\n        float index = dot(\n          vec4(row, col, depth, depth2),\n          vec4(${u}, ${o}, ${a}, ${P})) +\n          depth3;\n        ${ad(e)}\n      }\n    `;const i=e.shapeInfo.flatOffset,l=e.shapeInfo.texShape,c=l[0],O=l[1];if(O===u&&null==i)return`\n      float ${n}(int row, int col, int depth, int depth2, int depth3) {\n        int texR = row;\n        float texC = dot(vec4(col, depth, depth2, depth3),\n                         vec4(${o}, ${a}, ${P}, 1));\n        vec2 uv = (vec2(texC, texR) + halfCR) /\n                   vec2(${O}.0, ${c}.0);\n        return sampleTexture(${r}, uv);\n      }\n    `;if(O===P&&null==i)return`\n      float ${n}(int row, int col, int depth, int depth2, int depth3) {\n        float texR = dot(\n          vec4(row, col, depth, depth2),\n          vec4(${t[1]*t[2]*t[3]},\n               ${t[2]*t[3]}, ${t[3]}, 1));\n        int texC = depth3;\n        vec2 uv = (vec2(texC, texR) + halfCR) /\n                  vec2(${O}.0, ${c}.0);\n        return sampleTexture(${r}, uv);\n      }\n    `;return`\n    float ${n}(int row, int col, int depth, int depth2, int depth3) {\n      // Explicitly use integer operations as dot() only works on floats.\n      int index = row * ${u} + col * ${o} + depth * ${a} +\n          depth2 * ${P} + depth3 + ${Bz(r)};\n      vec2 uv = uvFromFlat(${c}, ${O}, index);\n      return sampleTexture(${r}, uv);\n    }\n  `}function Pd(e){const t=e.shapeInfo.logicalShape,r=e.name,n="get"+r.charAt(0).toUpperCase()+r.slice(1),{newShape:P,keptDims:a}=Ne(t);if(P.length<t.length){const t=["row","col","depth","depth2","depth3","depth4"];return`\n      ${zz(id(e,P))}\n      float ${n}(int row, int col, int depth,\n                    int depth2, int depth3, int depth4) {\n        return ${n}(${ld(t,a)});\n      }\n    `}const o=t[5],u=t[4]*o,s=t[3]*u,v=t[2]*s,i=t[1]*v;if(e.shapeInfo.isUniform)return`\n      float ${n}(int row, int col, int depth,\n                  int depth2, int depth3, int depth4) {\n        int index = round(dot(\n          vec4(row, col, depth, depth2),\n          vec4(${i}, ${v}, ${s}, ${u})) +\n          dot(\n            vec2(depth3, depth4),\n            vec2(${o}, 1)));\n        ${ad(e)}\n      }\n    `;const l=e.shapeInfo.flatOffset,c=e.shapeInfo.texShape,O=c[0],D=c[1];if(D===i&&null==l)return`\n      float ${n}(int row, int col, int depth,\n                    int depth2, int depth3, int depth4) {\n        int texR = row;\n        float texC = dot(vec4(col, depth, depth2, depth3),\n          vec4(${v}, ${s}, ${u}, ${o})) +\n               float(depth4);\n        vec2 uv = (vec2(texC, texR) + halfCR) /\n                   vec2(${D}.0, ${O}.0);\n        return sampleTexture(${r}, uv);\n      }\n    `;if(D===o&&null==l)return`\n      float ${n}(int row, int col, int depth,\n                    int depth2, int depth3, int depth4) {\n        float texR = dot(vec4(row, col, depth, depth2),\n          vec4(${t[1]*t[2]*t[3]*t[4]},\n               ${t[2]*t[3]*t[4]},\n               ${t[3]*t[4]},\n               ${t[4]})) + float(depth3);\n        int texC = depth4;\n        vec2 uv = (vec2(texC, texR) + halfCR) /\n                  vec2(${D}.0, ${O}.0);\n        return sampleTexture(${r}, uv);\n      }\n    `;return`\n    float ${n}(int row, int col, int depth,\n                  int depth2, int depth3, int depth4) {\n      // Explicitly use integer operations as dot() only works on floats.\n      int index = row * ${i} + col * ${v} + depth * ${s} +\n          depth2 * ${u} + depth3 * ${o} + depth4 + ${Bz(r)};\n      vec2 uv = uvFromFlat(${O}, ${D}, index);\n      return sampleTexture(${r}, uv);\n    }\n  `}function ad(e){const t=e.name,r=Ee(e.shapeInfo.logicalShape);return r<2?`return ${t};`:`\n    for (int i = 0; i < ${r}; i++) {\n      if (i == index) {\n        return ${t}[i];\n      }\n    }\n  `}function od(e,t){const r=e.name,n=r.charAt(0).toUpperCase()+r.slice(1),P="get"+n+"AtOutCoords",a=e.shapeInfo.logicalShape.length,o=t.logicalShape.length,u=bz(e.shapeInfo.logicalShape,t.logicalShape),s=sd(o),v=o-a;let i;const l=["x","y","z","w","u","v"];i=0===a?"":o<2&&u.length>=1?"coords = 0;":u.map((e=>`coords.${l[e+v]} = 0;`)).join("\n");let c="";c=o<2&&a>0?"coords":e.shapeInfo.logicalShape.map(((e,t)=>`coords.${l[t+v]}`)).join(", ");let O="return outputValue;";const D=1===Ee(e.shapeInfo.logicalShape),j=1===Ee(t.logicalShape);if(1!==a||D||j){if(D&&!j)O=1===o?"\n        return vec4(outputValue.x, outputValue.x, 0., 0.);\n      ":"\n        return vec4(outputValue.x);\n      ";else if(u.length){const e=a-2,t=a-1;u.indexOf(e)>-1&&u.indexOf(t)>-1?O="return vec4(outputValue.x);":u.indexOf(e)>-1?O="return vec4(outputValue.x, outputValue.y, outputValue.x, outputValue.y);":u.indexOf(t)>-1&&(O="return vec4(outputValue.xx, outputValue.zz);")}}else O="\n      return vec4(outputValue.xy, outputValue.xy);\n    ";return`\n    vec4 ${P}() {\n      ${s} coords = getOutputCoords();\n      ${i}\n      vec4 outputValue = get${n}(${c});\n      ${O}\n    }\n  `}function ud(e,t){const r=e.name,n=r.charAt(0).toUpperCase()+r.slice(1),P="get"+n+"AtOutCoords",a=t.texShape,o=e.shapeInfo.texShape,u=e.shapeInfo.logicalShape.length,s=t.logicalShape.length;if(!e.shapeInfo.isUniform&&u===s&&null==e.shapeInfo.flatOffset&&Qe(o,a))return`\n      float ${P}() {\n        return sampleTexture(${r}, resultUV);\n      }\n    `;const v=sd(s),i=bz(e.shapeInfo.logicalShape,t.logicalShape),l=s-u;let c;const O=["x","y","z","w","u","v"];c=0===u?"":s<2&&i.length>=1?"coords = 0;":i.map((e=>`coords.${O[e+l]} = 0;`)).join("\n");let D="";return D=s<2&&u>0?"coords":e.shapeInfo.logicalShape.map(((e,t)=>`coords.${O[t+l]}`)).join(", "),`\n    float ${P}() {\n      ${v} coords = getOutputCoords();\n      ${c}\n      return get${n}(${D});\n    }\n  `}function sd(e){if(e<=1)return"int";if(2===e)return"ivec2";if(3===e)return"ivec3";if(4===e)return"ivec4";if(5===e)return"ivec5";if(6===e)return"ivec6";throw Error(`GPU for rank ${e} is not yet supported`)}function vd(e,t,r){const{newShape:n,keptDims:P}=Ne(t),a=t.length,o=e&&3===a&&1===t[0],u=o?t.slice(1):n,s=!e&&a>1&&!Qe(t,r)&&n.length<a||o;return{useSqueezeShape:s,uniformShape:s?u:t,keptDims:P}}function id(e,t){const r=JSON.parse(JSON.stringify(e));return r.shapeInfo.logicalShape=t,r}function ld(e,t){return t.map((t=>e[t])).join(", ")}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function cd(e,t,r,n){const P=r.map(((e,r)=>{const n={logicalShape:e.shape,texShape:e.isUniform?null:e.texData.texShape,isUniform:e.isUniform,isPacked:!e.isUniform&&e.texData.isPacked,flatOffset:null};return null!=e.texData&&null!=e.texData.slice&&e.texData.slice.flatOffset>0&&(n.flatOffset=e.texData.slice.flatOffset),{name:t.variableNames[r],shapeInfo:n}})),a=P.map((e=>e.shapeInfo)),o={logicalShape:n.shape,texShape:n.texData.texShape,isUniform:!1,isPacked:n.texData.isPacked,flatOffset:null},u=Tz(P,o,t),s=LT(e.gl,u),v=e.createProgram(s);return mt().get("ENGINE_COMPILE_ONLY")?{program:t,fragmentShader:s,source:u,webGLProgram:v,inShapeInfos:a,outShapeInfo:o,uniformLocations:null,customUniformLocations:null,infLoc:null,nanLoc:null,inShapesLocations:null,inTexShapesLocations:null,outShapeLocation:null,outShapeStridesLocation:null,outTexShapeLocation:null}:Object.assign({program:t,fragmentShader:s,source:u,webGLProgram:v,inShapeInfos:a,outShapeInfo:o},Od(e,t,v))}function Od(e,t,r){const n={},P={},a={},o=[];let u,s,v,i=null,l=null;l=e.getUniformLocation(r,"NAN",!1),1===mt().getNumber("WEBGL_VERSION")&&(i=e.getUniformLocation(r,"INFINITY",!1));const c=!1;for(let o=0;o<t.variableNames.length;o++){const u=t.variableNames[o];n[u]=e.getUniformLocation(r,u,c),n[`offset${u}`]=e.getUniformLocation(r,`offset${u}`,c),t.enableShapeUniforms&&(P[`${u}Shape`]=e.getUniformLocation(r,`${u}Shape`,c),a[`${u}TexShape`]=e.getUniformLocation(r,`${u}TexShape`,c))}return t.enableShapeUniforms&&(u=e.getUniformLocation(r,"outShape",c),v=e.getUniformLocation(r,"outShapeStrides",c),s=e.getUniformLocation(r,"outTexShape",c)),t.customUniforms&&t.customUniforms.forEach(((t,n)=>{o[n]=e.getUniformLocation(r,t.name,c)})),{uniformLocations:n,customUniformLocations:o,infLoc:i,nanLoc:l,inShapesLocations:P,inTexShapesLocations:a,outShapeLocation:u,outShapeStridesLocation:v,outTexShapeLocation:s}}function Dd(e,t){if(e.length!==t.length)throw Error(`Binary was compiled with ${e.length} inputs, but was executed with ${t.length} inputs`);e.forEach(((e,r)=>{const n=e.logicalShape,P=t[r],a=P.shape;if(!Qe(n,a))throw Error(`Binary was compiled with different shapes than the current args. Shapes ${n} and ${a} must match`);if(e.isUniform&&P.isUniform)return;const o=e.texShape,u=P.isUniform?null:P.texData.texShape;if(!Qe(o,u))throw Error(`Binary was compiled with different texture shapes than the current args. Shape ${o} and ${u} must match`)}))}function jd(e,t,r,n,P){t.program.enableShapeUniforms||(Dd(t.inShapeInfos,r),Dd([t.outShapeInfo],[n]));const a=n.texData.texture,o=n.texData.texShape;n.texData.isPacked?e.setOutputPackedMatrixTexture(a.texture,o[0],o[1]):e.setOutputMatrixTexture(a.texture,o[0],o[1]),e.setProgram(t.webGLProgram),1===mt().getNumber("WEBGL_VERSION")&&null!==t.infLoc&&e.gl.uniform1f(t.infLoc,1/0),null!==t.nanLoc&&e.gl.uniform1f(t.nanLoc,NaN),r.forEach(((r,n)=>{const P=t.program.variableNames[n],a=t.uniformLocations[P],o=t.uniformLocations[`offset${P}`],u=t.inShapesLocations[`${P}Shape`],s=t.inTexShapesLocations[`${P}TexShape`];if(u){const{uniformShape:n}=vd(t.program.packedInputs,r.shape,r.texData.texShape);switch(n.length){case 1:e.gl.uniform1iv(u,new Int32Array(n));break;case 2:e.gl.uniform2iv(u,new Int32Array(n));break;case 3:e.gl.uniform3iv(u,new Int32Array(n));break;case 4:e.gl.uniform4iv(u,new Int32Array(n))}}if(s&&e.gl.uniform2i(s,r.texData.texShape[0],r.texData.texShape[1]),null!=a)if(r.isUniform)if(Ee(r.shape)<2)e.gl.uniform1f(a,r.uniformValues[0]);else{let t=r.uniformValues;t instanceof Float32Array||(t=new Float32Array(t)),e.gl.uniform1fv(a,t)}else null!=r.texData.slice&&null!=o&&e.gl.uniform1i(o,r.texData.slice.flatOffset),e.setInputMatrixTexture(r.texData.texture.texture,a,n)}));const u=t.outShapeLocation;if(u)switch(n.shape.length){case 1:e.gl.uniform1iv(u,new Int32Array(n.shape));break;case 2:e.gl.uniform2iv(u,new Int32Array(n.shape));break;case 3:e.gl.uniform3iv(u,new Int32Array(n.shape));break;case 4:e.gl.uniform4iv(u,new Int32Array(n.shape))}if(t.outShapeStridesLocation){const r=Pt(n.shape);switch(n.shape.length){case 2:e.gl.uniform1iv(t.outShapeStridesLocation,new Int32Array(r));break;case 3:e.gl.uniform2iv(t.outShapeStridesLocation,new Int32Array(r));break;case 4:e.gl.uniform3iv(t.outShapeStridesLocation,new Int32Array(r))}}t.outTexShapeLocation&&e.gl.uniform2i(t.outTexShapeLocation,n.texData.texShape[0],n.texData.texShape[1]),t.program.customUniforms&&P&&t.program.customUniforms.forEach(((r,n)=>{const a=t.customUniformLocations[n],o=P[n];if("float"===r.type)e.gl.uniform1fv(a,o);else if("vec2"===r.type)e.gl.uniform2fv(a,o);else if("vec3"===r.type)e.gl.uniform3fv(a,o);else if("vec4"===r.type)e.gl.uniform4fv(a,o);else if("int"===r.type)e.gl.uniform1iv(a,o);else if("ivec2"===r.type)e.gl.uniform2iv(a,o);else if("ivec3"===r.type)e.gl.uniform3iv(a,o);else{if("ivec4"!==r.type)throw Error(`uniform type ${r.type} is not supported yet.`);e.gl.uniform4iv(a,o)}})),e.executeProgram()}function hd(e,t,r){let n="";t.concat(r).forEach((t=>{const P=null!=t.texData&&null!=t.texData.slice&&t.texData.slice.flatOffset>0;if(e.enableShapeUniforms&&!t.isUniform){const a=t.texData.texShape,{useSqueezeShape:o,uniformShape:u,keptDims:s}=vd(e.packedInputs,t.shape,a);let v="",i="",l="";if(1===u.length&&e.packedInputs){const e=[Math.ceil(a[0]/2),Math.ceil(a[1]/2)];v=`${e[0]>1}_${e[1]>1}`}else if(2!==u.length||e.packedInputs){if(u.length>2&&!e.packedInputs){const e=Pt(u);l=`${e[0]===a[1]}_${e[e.length-1]===a[1]}`}}else i=`${u[0]>1}_${u[1]>1}`;const c=t.shape.length,O=2===u.length&&Qe(t.shape,a),D=1===Ee(t.shape),j=Ps(t.shape,r.shape),h=!e.packedInputs&&c===r.shape.length&&Qe(a,r.texData.texShape),p=e.packedInputs||u.length>2?"":`${a[0]>1}_${a[1]>1}`;n+=`${c}_${h}_${o?s:""}_${u.length}_${D}_${j}_${O}_${v}_${i}_${l}_${p}_${P}`}else{const e=t.isUniform?"uniform":t.texData.texShape;n+=`${t.shape}_${e}_${P}`}}));const P=e.userCode;let a=e.constructor.name;return a+="_"+n+"_"+P+`${mt().getNumber("WEBGL_VERSION")}`,a}function pd(e){return mt().getBool("WEBGL_USE_SHAPES_UNIFORMS")&&e<=4}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class md{constructor(e){this.variableNames=["A"],this.packedInputs=!1,this.packedOutput=!0,this.outPackingScheme=De.DENSE,this.customUniforms=[{name:"texShape",type:"ivec2"}];const t=Oz();this.outputShape=e,this.enableShapeUniforms=pd(this.outputShape.length),this.userCode=`\n      ivec3 outCoordsFromFlatIndex(int index) {\n        ${this.enableShapeUniforms?jz(["r","c","d"],e):Dz(["r","c","d"],e)}\n        return ivec3(r, c, d);\n      }\n\n      void main() {\n        ivec2 resTexRC = ivec2(resultUV.yx * vec2(texShape[0], texShape[1]));\n        int index = 4 * (resTexRC.x * texShape[1] + resTexRC.y);\n\n        vec4 result = vec4(0.);\n\n        for (int i=0; i<4; i++) {\n          int flatIndex = index + i;\n          ivec3 rc = outCoordsFromFlatIndex(flatIndex);\n          result[i] = getA(rc.x, rc.y, rc.z);\n        }\n\n        ${t.output} = result;\n      }\n    `}}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class gd{constructor(e){this.variableNames=["A"],this.packedInputs=!0,this.packedOutput=!0,this.outPackingScheme=De.DENSE,this.customUniforms=[{name:"texShape",type:"ivec2"}];const t=Oz();this.outputShape=e,this.enableShapeUniforms=pd(this.outputShape.length),this.userCode=`\n      ivec3 outCoordsFromFlatIndex(int index) {\n        ${this.enableShapeUniforms?jz(["r","c","d"],e):Dz(["r","c","d"],e)}\n        return ivec3(r, c, d);\n      }\n\n      void main() {\n        ivec2 resTexRC = ivec2(resultUV.yx * vec2(texShape[0], texShape[1]));\n        int index = 4 * (resTexRC.x * texShape[1] + resTexRC.y);\n\n        vec4 result = vec4(0.);\n\n        for (int i=0; i<4; i++) {\n          int flatIndex = index + i;\n          ivec3 rc = outCoordsFromFlatIndex(flatIndex);\n          result[i] = getChannel(getA(rc.x, rc.y, rc.z), vec2(rc.y, rc.z));\n        }\n\n        ${t.output} = result;\n      }\n    `}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class bd{constructor(e){this.variableNames=["A"],this.outTexUsage=je.DOWNLOAD;const t=Oz();this.outputShape=e,this.userCode=`\n      ${gz}\n\n      void main() {\n        float x = getAAtOutCoords();\n        ${t.output} = encode_float(x);\n      }\n    `}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class Td{constructor(e){this.variableNames=["A"],this.packedInputs=!0,this.packedOutput=!1,this.outTexUsage=je.DOWNLOAD;const t=Oz();this.outputShape=e,this.userCode=`\n      ${gz}\n\n      void main() {\n        ivec3 coords = getOutputCoords();\n        float x = getChannel(getAAtOutCoords(), vec2(coords.y, coords.z));\n        ${t.output} = encode_float(x);\n      }\n    `}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class zd{constructor(e,t=!1){this.variableNames=["A"],this.customUniforms=[{name:"texShape",type:"ivec2"}];const r=Oz();this.outputShape=e,this.enableShapeUniforms=pd(this.outputShape.length);let n="result";t&&(n="floor(result * 255. + 0.5)"),this.userCode=`\n      ${this.enableShapeUniforms?"\n  int getFlatIndex(ivec3 coords) {\n    return coords.x * outShapeStrides[0] + coords.y * outShapeStrides[1] + coords.z;\n  }\n":mz(e)}\n\n      void main() {\n        ivec3 coords = getOutputCoords();\n\n        int flatIndex = getFlatIndex(coords);\n        int offset = imod(flatIndex, 4);\n\n        flatIndex = idiv(flatIndex, 4, 1.);\n\n        int r = flatIndex / texShape[1];\n        int c = imod(flatIndex, texShape[1]);\n        vec2 uv = (vec2(c, r) + halfCR) / vec2(texShape[1], texShape[0]);\n        vec4 values = ${r.texture2D}(A, uv);\n\n        float result;\n\n        if(offset == 0) {\n          result = values[0];\n        } else if(offset == 1) {\n          result = values[1];\n        } else if(offset == 2) {\n          result = values[2];\n        } else {\n          result = values[3];\n        }\n\n        ${r.output} = vec4(${n}, 0., 0., 0.);\n      }\n    `}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class dd{constructor(e,t=!1){this.variableNames=["A"],this.packedInputs=!1,this.packedOutput=!0,this.customUniforms=[{name:"texShape",type:"ivec2"}];const r=Oz();this.outputShape=e,this.enableShapeUniforms=pd(this.outputShape.length);let n="",P="result";t&&(P="floor(result * 255. + 0.5)");for(let t=0;t<=1;t++)for(let P=0;P<=1;P++){const a=2*t+P;n+=`\n          localCoords = coords;\n          if(localCoords[2] + ${P} < ${this.enableShapeUniforms?"outShape[2]":`${e[2]}`}) {\n          localCoords[2] += ${P};\n          if (localCoords[1] + ${t} < ${this.enableShapeUniforms?"outShape[1]":`${e[1]}`}) {\n            localCoords[1] += ${t};\n\n            flatIndex = getFlatIndex(localCoords);\n            offset = imod(flatIndex, 4);\n\n            flatIndex = idiv(flatIndex, 4, 1.);\n\n            int r = flatIndex / texShape[1];\n            int c = imod(flatIndex, texShape[1]);\n            vec2 uv = (vec2(c, r) + halfCR) / vec2(texShape[1], texShape[0]);\n            values = ${r.texture2D}(A, uv);\n\n            if (offset == 0) {\n              result[${a}] = values[0];\n            } else if (offset == 1) {\n              result[${a}] = values[1];\n            } else if (offset == 2) {\n              result[${a}] = values[2];\n            } else {\n              result[${a}] = values[3];\n            }\n          }\n        }\n        `}this.userCode=`\n        ${this.enableShapeUniforms?"\n  int getFlatIndex(ivec3 coords) {\n    return coords.x * outShapeStrides[0] + coords.y * outShapeStrides[1] + coords.z;\n  }\n":mz(e)}\n\n        void main() {\n          ivec3 coords = getOutputCoords();\n\n          vec4 result = vec4(0.);\n          int flatIndex, r, c, offset;\n          ivec3 localCoords;\n          vec2 uv;\n          vec4 values;\n\n          ${n}\n\n          ${r.output} = ${P};\n        }\n    `}}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function yd(e){const t=Oz();return wT(e,`${t.version}\n    precision highp float;\n    ${t.attribute} vec3 clipSpacePos;\n    ${t.attribute} vec2 uv;\n    ${t.varyingVs} vec2 resultUV;\n\n    void main() {\n      gl_Position = vec4(clipSpacePos, 1);\n      resultUV = uv;\n    }`)}function wd(e){return YT(e,new Float32Array([-1,1,0,0,1,-1,-1,0,0,0,1,1,0,1,1,1,-1,0,1,0]))}function Ld(e){return kT(e,new Uint16Array([0,1,2,2,1,3]))}function fd(e,t,r,n,P,a){ET(t,r);const o=CT(e),u=e.TEXTURE_2D;return mT(e,(()=>e.bindTexture(u,o))),mT(e,(()=>e.texParameteri(u,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE))),mT(e,(()=>e.texParameteri(u,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE))),mT(e,(()=>e.texParameteri(u,e.TEXTURE_MIN_FILTER,e.NEAREST))),mT(e,(()=>e.texParameteri(u,e.TEXTURE_MAG_FILTER,e.NEAREST))),1===mt().getNumber("WEBGL_VERSION")?mT(e,(()=>e.texImage2D(u,0,n,t,r,0,P,a,null))):mT(e,(()=>e.texStorage2D(u,1,n,t,r))),mT(e,(()=>e.bindTexture(e.TEXTURE_2D,null))),{texture:o,texShape:[r,t]}}function Id(e){return e.internalFormatFloat}function Sd(e,t,r,n){const[P,a]=cT(t,r);return fd(e,P,a,Id(n),n.textureFormatFloat,e.FLOAT)}function Ad(e){return e.internalFormatHalfFloat}function xd(e,t,r,n){const[P,a]=cT(t,r);return fd(e,P,a,Ad(n),n.textureFormatFloat,n.textureTypeHalfFloat)}function Yd(e){return e.downloadTextureFormat}function kd(e,t,r,n){const[P,a]=cT(t,r);return fd(e,P,a,Yd(n),e.RGBA,e.UNSIGNED_BYTE)}function Cd(e){return e.internalFormatPackedFloat}function Ed(e,t,r,n){const[P,a]=jT(t,r);return fd(e,P,a,Cd(n),e.RGBA,e.FLOAT)}function Qd(e){return e.internalFormatPackedHalfFloat}function Wd(e,t,r,n){const[P,a]=jT(t,r);return fd(e,P,a,Qd(n),e.RGBA,n.textureTypeHalfFloat)}function Ud(e,t,r){mT(e,(()=>e.bindBuffer(e.ARRAY_BUFFER,r)));return WT(e,t,"clipSpacePos",r,3,20,0)&&WT(e,t,"uv",r,2,20,12)}function qd(e,t,r,n,P,a){let o,u,s;mT(e,(()=>e.bindTexture(e.TEXTURE_2D,t))),P instanceof Uint8Array?(o=new Uint8Array(r*n*4),u=e.UNSIGNED_BYTE,s=e.RGBA):(o=new Float32Array(r*n*4),u=e.FLOAT,s=a.internalFormatPackedFloat),o.set(P),2===mt().getNumber("WEBGL_VERSION")?mT(e,(()=>e.texSubImage2D(e.TEXTURE_2D,0,0,0,r,n,e.RGBA,u,o))):mT(e,(()=>e.texImage2D(e.TEXTURE_2D,0,s,r,n,0,e.RGBA,u,o))),mT(e,(()=>e.bindTexture(e.TEXTURE_2D,null)))}function Gd(e,t,r){mT(e,(()=>e.bindTexture(e.TEXTURE_2D,t))),r.data instanceof Uint8Array?2===mt().getNumber("WEBGL_VERSION")?mT(e,(()=>e.texSubImage2D(e.TEXTURE_2D,0,0,0,r.width,r.height,e.RGBA,e.UNSIGNED_BYTE,r.data))):mT(e,(()=>e.texImage2D(e.TEXTURE_2D,0,e.RGBA,r.width,r.height,0,e.RGBA,e.UNSIGNED_BYTE,r.data))):2===mt().getNumber("WEBGL_VERSION")?mT(e,(()=>e.texSubImage2D(e.TEXTURE_2D,0,0,0,e.RGBA,e.UNSIGNED_BYTE,r))):mT(e,(()=>e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,r))),mT(e,(()=>e.bindTexture(e.TEXTURE_2D,null)))}function Md(e,t,r,n){const P=e.createBuffer();mT(e,(()=>e.bindBuffer(e.PIXEL_PACK_BUFFER,P)));const a=16*t*r;return mT(e,(()=>e.bufferData(e.PIXEL_PACK_BUFFER,a,e.STREAM_READ))),mT(e,(()=>e.readPixels(0,0,r,t,e.RGBA,e.FLOAT,0))),mT(e,(()=>e.bindBuffer(e.PIXEL_PACK_BUFFER,null))),P}function Kd(e,t,r){const n=e,P=new Float32Array(r);return n.bindBuffer(n.PIXEL_PACK_BUFFER,t),n.getBufferSubData(n.PIXEL_PACK_BUFFER,0,P),n.bindBuffer(n.PIXEL_PACK_BUFFER,null),P}function Nd(e,t,r,n){const[P,a]=cT(t,r),o=new Uint8Array(OT(t*r,4));return mT(e,(()=>e.readPixels(0,0,P,a,n.downloadTextureFormat,e.UNSIGNED_BYTE,o))),new Float32Array(o.buffer)}function Rd(e,t,r,n,P,a,o,u){const s=e,v=new Float32Array(hT(a,o));return s.bindBuffer(s.PIXEL_PACK_BUFFER,t),s.getBufferSubData(s.PIXEL_PACK_BUFFER,0,v),s.bindBuffer(s.PIXEL_PACK_BUFFER,null),v}function Fd(e,t,r){const n=new Float32Array(t*r*4);return mT(e,(()=>e.readPixels(0,0,r,t,e.RGBA,e.FLOAT,n))),n}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class Bd{constructor(e){this.outputTexture=null,this.program=null,this.disposed=!1,this.vertexAttrsAreBound=!1,this.itemsToPoll=[];const t=mt().getNumber("WEBGL_VERSION");null!=e?(this.gl=e,sT(t,e)):this.gl=vT(t);let r="WEBGL_color_buffer_float";const n="EXT_color_buffer_half_float";if(this.parallelCompilationExtension=this.gl.getExtension("KHR_parallel_shader_compile"),1===mt().getNumber("WEBGL_VERSION")){const e="OES_texture_float",t="OES_texture_half_float";if(this.textureFloatExtension=yT(this.gl,e),az(this.gl,t))this.textureHalfFloatExtension=yT(this.gl,t);else if(mt().get("WEBGL_FORCE_F16_TEXTURES"))throw new Error("GL context does not support half float textures, yet the environment flag WEBGL_FORCE_F16_TEXTURES is set to true.");if(this.colorBufferFloatExtension=this.gl.getExtension(r),az(this.gl,n))this.colorBufferHalfFloatExtension=yT(this.gl,n);else if(mt().get("WEBGL_FORCE_F16_TEXTURES"))throw new Error("GL context does not support color renderable half floats, yet the environment flag WEBGL_FORCE_F16_TEXTURES is set to true.")}else if(r="EXT_color_buffer_float",az(this.gl,r))this.colorBufferFloatExtension=this.gl.getExtension(r);else{if(!az(this.gl,n))throw new Error("GL context does not support color renderable floats");this.colorBufferHalfFloatExtension=this.gl.getExtension(n)}this.vertexBuffer=wd(this.gl),this.indexBuffer=Ld(this.gl),this.framebuffer=QT(this.gl),this.textureConfig=pT(this.gl,this.textureHalfFloatExtension)}get debug(){return mt().getBool("DEBUG")}dispose(){if(this.disposed)return;null!=this.program&&console.warn("Disposing a GPGPUContext that still has a bound WebGLProgram. This is probably a resource leak, delete the program with GPGPUContext.deleteProgram before disposing."),null!=this.outputTexture&&console.warn("Disposing a GPGPUContext that still has a bound output matrix texture.  This is probably a resource leak, delete the output matrix texture with GPGPUContext.deleteMatrixTexture before disposing.");const e=this.gl;mT(e,(()=>e.finish())),mT(e,(()=>e.bindFramebuffer(e.FRAMEBUFFER,null))),mT(e,(()=>e.deleteFramebuffer(this.framebuffer))),mT(e,(()=>e.bindBuffer(e.ARRAY_BUFFER,null))),mT(e,(()=>e.bindBuffer(e.ELEMENT_ARRAY_BUFFER,null))),mT(e,(()=>e.deleteBuffer(this.indexBuffer))),this.disposed=!0}createFloat32MatrixTexture(e,t){return this.throwIfDisposed(),Sd(this.gl,e,t,this.textureConfig)}createFloat16MatrixTexture(e,t){return this.throwIfDisposed(),xd(this.gl,e,t,this.textureConfig)}createUnsignedBytesMatrixTexture(e,t){return this.throwIfDisposed(),kd(this.gl,e,t,this.textureConfig)}uploadPixelDataToTexture(e,t){this.throwIfDisposed(),Gd(this.gl,e,t)}uploadDenseMatrixToTexture(e,t,r,n){this.throwIfDisposed(),qd(this.gl,e,t,r,n,this.textureConfig)}createFloat16PackedMatrixTexture(e,t){return this.throwIfDisposed(),Wd(this.gl,e,t,this.textureConfig)}createPackedMatrixTexture(e,t){return this.throwIfDisposed(),Ed(this.gl,e,t,this.textureConfig)}deleteMatrixTexture(e){this.throwIfDisposed(),this.outputTexture===e&&(NT(this.gl,this.framebuffer),this.outputTexture=null),mT(this.gl,(()=>this.gl.deleteTexture(e)))}downloadByteEncodedFloatMatrixFromOutputTexture(e,t,r){return this.downloadMatrixDriver(e,(()=>Nd(this.gl,t,r,this.textureConfig)))}downloadPackedMatrixFromBuffer(e,t,r,n,P,a){return Rd(this.gl,e,0,0,0,P,a,this.textureConfig)}downloadFloat32MatrixFromBuffer(e,t){return Kd(this.gl,e,t)}createBufferFromTexture(e,t,r){this.bindTextureToFrameBuffer(e);const n=Md(this.gl,t,r,this.textureConfig);return this.unbindTextureToFrameBuffer(),n}createAndWaitForFence(){const e=this.createFence(this.gl);return this.pollFence(e)}createFence(e){let t,r;if(mt().getBool("WEBGL_FENCE_API_ENABLED")){const n=e,P=n.fenceSync(n.SYNC_GPU_COMMANDS_COMPLETE,0);e.flush(),r=()=>{const e=n.clientWaitSync(P,0,0);return e===n.ALREADY_SIGNALED||e===n.CONDITION_SATISFIED},t=P}else mt().getNumber("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION")>0?(t=this.beginQuery(),this.endQuery(),r=()=>this.isQueryAvailable(t,mt().getNumber("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION"))):r=()=>!0;return{query:t,isFencePassed:r}}downloadMatrixFromPackedTexture(e,t,r){return this.downloadMatrixDriver(e,(()=>Fd(this.gl,t,r)))}createProgram(e){this.throwIfDisposed();const t=this.gl;null==this.vertexShader&&(this.vertexShader=yd(t));const r=ST(t);return mT(t,(()=>t.attachShader(r,this.vertexShader))),mT(t,(()=>t.attachShader(r,e))),AT(t,r),this.debug&&xT(t,r),this.vertexAttrsAreBound||(this.setProgram(r),this.vertexAttrsAreBound=Ud(t,this.program,this.vertexBuffer)),r}deleteProgram(e){this.throwIfDisposed(),e===this.program&&(this.program=null),null!=e&&mT(this.gl,(()=>this.gl.deleteProgram(e)))}setProgram(e){this.throwIfDisposed(),this.program=e,null!=this.program&&this.debug&&xT(this.gl,this.program),mT(this.gl,(()=>this.gl.useProgram(e)))}getUniformLocation(e,t,r=!0){return this.throwIfDisposed(),r?qT(this.gl,e,t):GT(this.gl,e,t)}getAttributeLocation(e,t){return this.throwIfDisposed(),mT(this.gl,(()=>this.gl.getAttribLocation(e,t)))}getUniformLocationNoThrow(e,t){return this.throwIfDisposed(),this.gl.getUniformLocation(e,t)}setInputMatrixTexture(e,t,r){this.throwIfDisposed(),this.throwIfNoProgram(),MT(this.gl,e,t,r)}setOutputMatrixTexture(e,t,r){this.setOutputMatrixTextureDriver(e,r,t)}setOutputPackedMatrixTexture(e,t,r){this.throwIfDisposed();const[n,P]=jT(t,r);this.setOutputMatrixTextureDriver(e,n,P)}setOutputMatrixWriteRegion(e,t,r,n){this.setOutputMatrixWriteRegionDriver(r,e,n,t)}setOutputPackedMatrixWriteRegion(e,t,r,n){throw new Error("setOutputPackedMatrixWriteRegion not implemented.")}debugValidate(){null!=this.program&&xT(this.gl,this.program),RT(this.gl)}executeProgram(){this.throwIfDisposed(),this.throwIfNoProgram();const e=this.gl;this.debug&&this.debugValidate(),mT(e,(()=>e.drawElements(e.TRIANGLES,6,e.UNSIGNED_SHORT,0)))}blockUntilAllProgramsCompleted(){this.throwIfDisposed(),mT(this.gl,(()=>this.gl.finish()))}getQueryTimerExtension(){return null==this.disjointQueryTimerExtension&&(this.disjointQueryTimerExtension=yT(this.gl,2===mt().getNumber("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION")?"EXT_disjoint_timer_query_webgl2":"EXT_disjoint_timer_query")),this.disjointQueryTimerExtension}getQueryTimerExtensionWebGL2(){return this.getQueryTimerExtension()}getQueryTimerExtensionWebGL1(){return this.getQueryTimerExtension()}beginQuery(){if(2===mt().getNumber("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION")){const e=this.gl,t=this.getQueryTimerExtensionWebGL2(),r=e.createQuery();return e.beginQuery(t.TIME_ELAPSED_EXT,r),r}const e=this.getQueryTimerExtensionWebGL1(),t=e.createQueryEXT();return e.beginQueryEXT(e.TIME_ELAPSED_EXT,t),t}endQuery(){if(2===mt().getNumber("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION")){const e=this.gl,t=this.getQueryTimerExtensionWebGL2();return void e.endQuery(t.TIME_ELAPSED_EXT)}const e=this.getQueryTimerExtensionWebGL1();e.endQueryEXT(e.TIME_ELAPSED_EXT)}async waitForQueryAndGetTime(e){return await Ge((()=>this.disposed||this.isQueryAvailable(e,mt().getNumber("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION")))),this.getQueryTime(e,mt().getNumber("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION"))}getQueryTime(e,t){if(0===t)return null;if(2===t){const t=this.gl;return t.getQueryParameter(e,t.QUERY_RESULT)/1e6}{const t=this.getQueryTimerExtensionWebGL1();return t.getQueryObjectEXT(e,t.QUERY_RESULT_EXT)/1e6}}isQueryAvailable(e,t){if(0===t)return!0;if(2===t){const t=this.gl,r=this.getQueryTimerExtensionWebGL2(),n=t.getQueryParameter(e,t.QUERY_RESULT_AVAILABLE);return null==this.disjoint&&(this.disjoint=this.gl.getParameter(r.GPU_DISJOINT_EXT)),n&&!this.disjoint}{const t=this.getQueryTimerExtensionWebGL1(),r=t.getQueryObjectEXT(e,t.QUERY_RESULT_AVAILABLE_EXT);return null==this.disjoint&&(this.disjoint=this.gl.getParameter(t.GPU_DISJOINT_EXT)),r&&!this.disjoint}}pollFence(e){return new Promise((t=>{this.addItemToPoll((()=>e.isFencePassed()),(()=>t()))}))}pollItems(){const e=Zd(this.itemsToPoll.map((e=>e.isDoneFn)));for(let t=0;t<=e;++t){const{resolveFn:e}=this.itemsToPoll[t];e()}this.itemsToPoll=this.itemsToPoll.slice(e+1)}addItemToPoll(e,t){this.itemsToPoll.push({isDoneFn:e,resolveFn:t}),this.itemsToPoll.length>1||Ge((()=>(this.pollItems(),0===this.itemsToPoll.length)))}bindTextureToFrameBuffer(e){this.throwIfDisposed(),KT(this.gl,e,this.framebuffer),this.debug&&RT(this.gl)}unbindTextureToFrameBuffer(){null!=this.outputTexture?(KT(this.gl,this.outputTexture,this.framebuffer),this.debug&&RT(this.gl)):NT(this.gl,this.framebuffer)}downloadMatrixDriver(e,t){this.bindTextureToFrameBuffer(e);const r=t();return this.unbindTextureToFrameBuffer(),r}setOutputMatrixTextureDriver(e,t,r){this.throwIfDisposed();const n=this.gl;KT(n,e,this.framebuffer),this.debug&&RT(n),this.outputTexture=e,mT(n,(()=>n.viewport(0,0,t,r))),mT(n,(()=>n.scissor(0,0,t,r)))}setOutputMatrixWriteRegionDriver(e,t,r,n){this.throwIfDisposed(),mT(this.gl,(()=>this.gl.scissor(e,t,r,n)))}throwIfDisposed(){if(this.disposed)throw new Error("Attempted to use disposed GPGPUContext.")}throwIfNoProgram(){if(null==this.program)throw new Error("No GPU program is currently set.")}}function Zd(e){let t=0;for(;t<e.length;++t){if(!e[t]())break}return t-1}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the License);
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an AS IS BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Vd(e){const t=new Float32Array(e.length);for(let r=0;r<e.length;++r)t[r]=Math.abs(e[r]);return t}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Xd(e){return(t,r,n,P,a)=>{const o=os(t,r),u=o.length,s=Pt(o),v=Re(a,Ee(o)),i=t.length,l=r.length,c=Pt(t),O=Pt(r),D=Ps(t,o),j=Ps(r,o);if(D.length+j.length===0)for(let t=0;t<v.length;++t)v[t]=e(n[t%n.length],P[t%P.length]);else for(let t=0;t<v.length;++t){const r=lt(t,u,s),a=r.slice(-i);D.forEach((e=>a[e]=0));const o=it(a,i,c),h=r.slice(-l);j.forEach((e=>h[e]=0));const p=it(h,l,O);v[t]=e(n[o],P[p])}return[v,o]}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Hd=Xd(((e,t)=>e+t));
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Jd(e,t,r,n,P){const a=Ee(n),o=st(P,r);for(let r=0;r<e.length;r++){const n=e[r];if(n<0)throw new Error("Input x must be non-negative!");n>=P||(o[n]+=a>0?t[r]:1)}return o}function _d(e,t,r,n=!1){const P=e.shape[0],a=e.shape[1],o=au([P,r],t.dtype);for(let u=0;u<P;u++)for(let P=0;P<a;P++){const a=e.get(u,P);if(a<0)throw new Error("Input x must be non-negative!");a>=r||(n?o.set(1,u,a):t.size>0?o.set(o.get(u,a)+t.get(u,P),u,a):o.set(o.get(u,a)+1,u,a))}return o}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function $d(e){return(t,r,n)=>{const P=Re(r,t.length);for(let r=0;r<t.length;++r)P[r]=e(t[r],n);return P}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the License);
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an AS IS BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const ey=$d((e=>Math.ceil(e)));
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ty(e,t,r,n){const P=Fe(r,Ee(t));if(n&&"string"!==r){let t=0;e.forEach((e=>{const r=Ee(e.shape);P.set(e.vals,t),t+=r}))}else{let n=0;e.forEach((e=>{const a="string"===r?pg(e.vals):e.vals;let o=0;for(let r=0;r<e.shape[0];++r){const u=r*t[1]+n;for(let t=0;t<e.shape[1];++t)P[u+t]=a[o++]}n+=e.shape[1]}))}return P}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const ry=Xd(((e,t)=>e===t?1:0)),ny=$d((e=>Math.exp(e))),Py=$d((e=>Math.expm1(e))),ay=$d((e=>Math.floor(e)));
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the License);
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an AS IS BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function oy(e,t,r,n,P,a,o,u,s){const v=au([n,a],r);for(let r=0;r<n;r++){const n=[];let i=0;for(let t=0;t<P;t++){const a=e[r*P+t];i+=a*o[t],n.push(a)}if(i<0||i>=s/a)throw new Error(`Invalid indices: ${n} does not index into ${u}`);for(let e=0;e<a;e++)v.values[r*a+e]=t.get(...t.indexToLoc(i*a+e))}return v}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function uy(e,t,r){const n=au(r,e.dtype);for(let r=0;r<n.size;++r){const P=n.indexToLoc(r).slice(),a=P[0],o=P[2],u=t.locToIndex([a,o]);P[2]=t.values[u];const s=e.locToIndex(P);0<=s&&s<e.values.length&&(n.values[r]=e.values[s])}return n}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const sy=Xd(((e,t)=>e>t?1:0)),vy=Xd(((e,t)=>e>=t?1:0)),iy=Xd(((e,t)=>e<t?1:0)),ly=Xd(((e,t)=>e<=t?1:0));
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function cy(e,t,r){const n=(t-e)/(r-1),P=st(r,"float32");P[0]=e;for(let e=1;e<P.length;e++)P[e]=P[e-1]+n;return P}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the License);
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an AS IS BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Oy=$d((e=>Math.log(e)));
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Dy(e,t,r,n){const P=Re(n,Ee(r));for(let r=0;r<P.length;++r){const n=r*t;let a=e[n];for(let r=0;r<t;++r){const t=e[n+r];(Number.isNaN(t)||t>a)&&(a=t)}P[r]=a}return P}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const jy=Xd(((e,t)=>Math.max(e,t))),hy=Xd(((e,t)=>Math.min(e,t))),py=Xd(((e,t)=>e*t));
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function my(e,t,r){const n=JP(-1,r);return py([],t,n,e,r)}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const gy=Xd(((e,t)=>e!==t?1:0));
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function by(e,t,r,n,P){const a=t.length,o=Ee(t),u=Pt(t),s=Pt(P),v=Re(r,Ee(P));for(let t=0;t<o;++t){const r=lt(t,a,u),P=new Array(r.length);for(let e=0;e<P.length;e++)P[e]=r[n[e]];v[it(P,a,s)]=e[t]}return v}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ty(e,t,r,n){const[P,a]=zl(e,n),o=La(t,"int32"),u=st(Ee(P),o),s=Ee(a);for(let e=0;e<u.length;++e){const t=e*s;let n=1;for(let e=0;e<s;++e)n*=r[t+e];u[e]=n}return{outVals:u,outShape:P,outDtype:o}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function zy(e,t,r,n){if(e===t||e<t&&r<0||t<e&&r>1)return st(0,n);const P=st(Math.abs(Math.ceil((t-e)/r)),n);t<e&&1===r&&(r=-1),P[0]=e;for(let e=1;e<P.length;e++)P[e]=P[e-1]+r;return P}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the License);
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an AS IS BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const dy=$d((e=>1/Math.sqrt(e)));
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function yy(e,t,r,n,P,a,o,u,s,v){const i=[n/P,P],l=e.values,c=t.values;if(0===n)return au(r,t.dtype);const O=au(i,t.dtype);"string"==typeof s||"number"==typeof s?O.values.fill(s):"boolean"==typeof s&&O.values.fill(+s);for(let e=0;e<a;e++){const a=[];let s=0;for(let t=0;t<o;t++){const r=l[e*o+t];a.push(r),s+=r*u[t]}if(s<0||s>=n/P)throw new Error(`Invalid indices: ${a} does not index into ${r}`);for(let r=0;r<P;r++)v?O.values[s*P+r]+=c[e*P+r]:O.values[s*P+r]=0===t.rank?c[0]:c[e*P+r]}return O}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the License);
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an AS IS BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const wy=$d((e=>1/(1+Math.exp(-e))));
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ly(e,t,r,n,P){const a=Is(n,t,r),o=Ee(r),u=Pt(n);if(a){const r=Ss(t,u);return"string"===P?e.slice(r,r+o):e.subarray(r,r+o)}const s=au(n,P,"string"===P?pg(e):e),v=au(r,P);for(let e=0;e<v.size;++e){const r=v.indexToLoc(e),n=r.map(((e,r)=>e+t[r]));v.set(s.get(...n),...r)}return"string"===P?mg(v.values):v.values}
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function fy(e,t,r,n,P,a,o){const u=t[0],s=a[0],v=new Array(s),i=new Array(u),l=t[1];if(0===s){if(0!==u)throw new Error(rg(u));return[Fe(r,0),[0,l],Fe(P,0),v,i]}let c=!0,O=0;const D=new Array(s).fill(0);for(let t=0;t<u;++t){const r=e[t*l];if(r<0)throw new Error(ng(t,r));if(r>=s)throw new Error(Pg(t,r,s));++D[r],c=c&&r>=O,O=r}let j=!0;for(let e=0;e<s;++e){const t=0===D[e];v[e]=t,j=j&&!t,D[e]=Math.max(D[e],1),e>0&&(D[e]+=D[e-1])}if(j&&c){const t=e,r=n;for(let e=0;e<u;++e)i[e]=e;return[t,[u,l],r,v,i]}{const t=D[s-1],a=Fe(r,t*l),c=Fe(P,t),O=new Array(s).fill(0);for(let t=0;t<u;++t){const r=e[t*l],P=O[r],o=(0===r?0:D[r-1])+P;O[r]++;for(let r=0;r<l;++r)a[o*l+r]=e[t*l+r];c[o]=n[t],i[t]=o}for(let e=0;e<s;++e){if(0===O[e]){const t=0===e?0:D[e-1];a[t*l+0]=e;for(let e=1;e<l;++e)a[t*l+e]=0;c[t]=o}}return[a,[t,l],c,v,i]}}
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Iy(e,t,r,n,P){const a=Ee(n),o=t[0],u=P.length,s=[];let v=1,i=-1;for(let e=0;e<u;++e){const t=P[e];if(-1===t){if(-1!==i)throw new Error(ag(i,e));i=e,s.push(1)}else{if(t<0)throw new Error(og(e,t));v*=t,s.push(t)}}if(-1!==i){if(v<=0)throw new Error("reshape cannot infer the missing input size for an empty tensor unless all specified input sizes are non-zero");const e=Math.trunc(a/v);if(v*e!==a)throw new Error(sg(n,s));s[i]=e}if(Ee(s)!==a)throw new Error(vg(n,s));const l=n.length,c=[];if(l>0){c[l-1]=1;for(let e=l-2;e>=0;--e)c[e]=c[e+1]*n[e+1]}const O=[];if(u>0){O[u-1]=1;for(let e=u-2;e>=0;--e)O[e]=O[e+1]*s[e+1]}const D=Fe(r,o*u);for(let t=0;t<o;++t){let r=0;for(let n=0;n<l;++n)r+=e[t*l+n]*c[n];for(let e=0;e<u;++e)D[t*u+e]=Math.trunc(r/O[e]),r%=O[e]}return[D,[o,u],s]}
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Sy(e,t,r,n,P,a=!1,o=0){const u=n.length,s=[t[0],e.length/t[0]],v=s[1],i=u>0?P[u-1]+1:0;if(i<0)throw new Error("segment ids must be >= 0");const l=t.slice();l[0]=i;const c=l.reduce(((e,t)=>e*t),1),O=Fe(r,c);if(0===u)return i>0&&O.fill(o),[O,l];if(i<=0)throw new Error("segment ids must be >= 0");let D=0,j=1,h=0,p=P[D];for(;;){let t=0;if(j<u){if(t=P[j],p===t){++j;continue}if(p>=t)throw new Error("segment ids are not increasing")}if(p<0||p>=i)throw new Error(cg(p,i));p>h&&O.fill(o,h*v,p*v);for(let t=D;t<j;++t){const r=n[t];if(r<0||r>=s[0])throw new Error(Og(t,n[t],s[0]));for(let t=0;t<v;t++)O[p*v+t]+=e[r*v+t]}if(a)for(let e=0;e<v;e++)O[p*v+e]/=j-D;if(D=j,++j,h=p+1,p=t,j>u)break}return h<i&&O.fill(o,h*v,i*v),[O,l]}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the License);
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an AS IS BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Ay=$d((e=>Math.sqrt(e))),xy=Xd(((e,t)=>{const r=e-t;return r*r}));
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function Yy(e,t,r,n){const P=au(e,t.dtype);for(let e=0;e<P.size;e++){const a=P.indexToLoc(e),o=new Array(a.length);for(let e=0;e<o.length;e++)o[e]=a[e]*r[e]+n[e];P.set(t.get(...o),...a)}return P}
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class ky{constructor(e,t,r,n,P,a){this.separator=ta(e),this.nGramWidths=t,this.leftPad=ta(r),this.rightPad=ta(n),this.padWidth=P,this.preserveShort=a}getPadWidth(e){return Math.min(this.padWidth<0?e-1:this.padWidth,e-1)}getNumNGrams(e,t){const r=this.getPadWidth(t);return Math.max(0,e+2*r-t+1)}createNGrams(e,t,r,n,P,a){for(let o=0;o<P;++o){const u=this.getPadWidth(a),s=Math.max(0,u-o),v=Math.max(0,u-(P-(o+1))),i=a-(s+v),l=t+(s>0?0:o-u);let c=0;c+=s*this.leftPad.length;for(let t=0;t<i;++t)c+=e[l+t].length;c+=v*this.rightPad.length;c+=(s+v+i-1)*this.separator.length,r[n+o]=new Uint8Array(c);const O=r[n+o];let D=0;const j=e=>e.forEach((e=>O[D++]=e));for(let e=0;e<s;++e)j(this.leftPad),j(this.separator);for(let t=0;t<i-1;++t)j(e[l+t]),j(this.separator);if(i>0){j(e[l+i-1]);for(let e=0;e<v;++e)j(this.separator),j(this.rightPad)}else{for(let e=0;e<v-1;++e)j(this.rightPad),j(this.separator);j(this.rightPad)}}}compute(e,t){const r=e.length,n=t.length;if(n>0){let e=t[0];if(0!==e)throw new Error(`First split value must be 0, got ${e}`);for(let P=1;P<n;++P){let n=t[P]>=e;if(n=n&&t[P]<=r,!n)throw new Error(`Invalid split value ${t[P]}, must be in [${e}, ${r}]`);e=t[P]}if(e!==r)throw new Error(`Last split value must be data size. Expected ${r}, got ${e}`)}const P=n-1,a=Fe("int32",n);if(0===r||0===n){const e=new Array(r);for(let e=0;e<=P;++e)a[e]=0;return[e,a]}a[0]=0;for(let e=1;e<=P;++e){const r=t[e]-t[e-1];let n=0;this.nGramWidths.forEach((e=>{n+=this.getNumNGrams(r,e)})),this.preserveShort&&r>0&&0===n&&(n=1),a[e]=a[e-1]+n}const o=new Array(a[P]);for(let r=0;r<P;++r){const n=t[r];let P=a[r];if(this.nGramWidths.forEach((a=>{const u=t[r+1]-t[r],s=this.getNumNGrams(u,a);this.createNGrams(e,n,o,P,s,a),P+=s})),this.preserveShort&&P===a[r]){const a=t[r+1]-t[r];if(0===a)continue;const u=a+2*this.padWidth,s=1;this.createNGrams(e,n,o,P,s,u)}}return[o,a]}}function Cy(e,t,r,n,P,a,o,u){return new ky(r,n,P,a,o,u).compute(e,t)}
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ey(e,t,r,n){if(!e.length)return;if(0===t.length){for(let t=0;t<e.length;++t)n.push(e.subarray(t,t+1));return}if(1===t.length){const P=t[0];let a=e.indexOf(P);for(;-1!==a;){const t=e.subarray(0,a);r&&0===t.length||n.push(t),e=e.subarray(a+1),a=e.indexOf(P)}return void(r&&0===e.length||n.push(e))}let P=0;for(let a=0;a<e.length+1;a++)if(a===e.length||-1!==t.indexOf(e[a])){const t=e.subarray(P,a);r&&0===t.length||n.push(t),P=a+1}}function Qy(e,t,r){const n=e.length,P=[];let a=0,o=0;const u=new Array(n);for(let s=0;s<n;++s){const n=P.length;Ey(e[s],t,r,P);const v=P.length-n;u[s]=v,a+=v,o=Math.max(o,v)}const s=Fe("int32",2*a),v=new Array(a),i=[n,o];let l=0;for(let e=0;e<n;++e)for(let t=0;t<u[e];++t)s[2*l]=e,s[2*l+1]=t,v[l]=P[l],++l;return[s,v,i]}
/**
     * @license
     * Copyright 2021 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Wy(e,t){const r=Fe("int32",e.length);for(let n=0;n<e.length;++n)r[n]=HP(e[n]).modulo(t).getLowBitsUnsigned();return r}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Uy=Xd(((e,t)=>e-t));
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function qy(e,t){const r=new Array(e.rank);for(let n=0;n<r.length;n++)r[n]=e.shape[n]*t[n];const n=au(r,e.dtype);for(let t=0;t<n.values.length;++t){const r=n.indexToLoc(t),P=new Array(e.rank);for(let t=0;t<P.length;t++)P[t]=r[t]%e.shape[t];const a=e.locToIndex(P);n.values[t]=e.values[a]}return n}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Gy=(e,t)=>{const r=t.value-e.value;return 0===r?e.index-t.index:r};function My(e,t,r=0,n=e.length-1){for(;n>r;){if(n-r>600){const P=n-r+1,a=t-r+1,o=Math.log(P),u=.5*Math.exp(2*o/3),s=.5*Math.sqrt(o*u*(P-u)/P)*Math.sign(a-P/2);My(e,t,Math.max(r,Math.floor(t-a*u/P+s)),Math.min(n,Math.floor(t+(P-a)*u/P+s)))}const P=e[t];let a=r,o=n;for(Se(e,r,t),Gy(e[n],P)>0&&Se(e,r,n);a<o;){for(Se(e,a,o),a++,o--;Gy(e[a],P)<0;)a+=1;for(;Gy(e[o],P)>0;)o-=1}0===Gy(e[r],P)?Se(e,r,o):(o+=1,Se(e,o,n)),o<=t&&(r=o+1),t<=o&&(n=o-1)}}function Ky(e,t,r,n,P){const a=t[t.length-1],[o,u]=[e.length/a,a],s=Re(r,o*n),v=Re("int32",o*n);for(let t=0;t<o;t++){const r=t*u,a=e.subarray(r,r+u);let o=new Array(a.length);a.forEach(((e,t)=>o[t]={value:e,index:t})),n<o.length&&(My(o,n),o=o.slice(0,n)),P&&o.sort(Gy);const i=t*n,l=s.subarray(i,i+n),c=v.subarray(i,i+n);for(let e=0;e<n;e++)l[e]=o[e].value,c[e]=o[e].index}const i=t.slice();return i[i.length-1]=n,[au(i,r,s),au(i,"int32",v)]}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Ny(e,t,r,n){const P=Ke(t,r)[0],a=[1,r[0],1];for(let e=0;e<P;e++)a[0]*=r[e];a[1]=r[P];for(let e=P+1;e<r.length;e++)a[2]*=r[e];const o={},u=new Int32Array(r[P]),s=new pa(a,n,e),v=[],i=1===a[0]&&1===a[2];for(let t=0;t<r[P];t++){let r;if(i)r=e[t].toString();else{const e=[];for(let r=0;r<a[0];r++)for(let n=0;n<a[2];n++)e.push(s.get(r,t,n));r=e.join(",")}if(void 0!==o[r])u[t]=o[r];else{const e=Object.keys(o).length;o[r]=e,u[t]=e,v.push(t)}}const l=a.slice();l[1]=Object.keys(o).length;const c=new pa(l,n);v.forEach(((e,t)=>{for(let r=0;r<a[0];r++)for(let n=0;n<a[2];n++)c.set(s.get(r,e,n),r,t,n)}));const O=r.slice();return O[P]=l[1],{outputValues:c.values,outputShape:O,indices:u}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */var pe=Object.freeze({__proto__:null,simpleAbsImpl:Vd,addImpl:Hd,bincountImpl:Jd,bincountReduceImpl:_d,ceilImpl:ey,concatImpl:ty,equalImpl:ry,expImpl:ny,expm1Impl:Py,floorImpl:ay,gatherNdImpl:oy,gatherV2Impl:uy,greaterImpl:sy,greaterEqualImpl:vy,lessImpl:iy,lessEqualImpl:ly,linSpaceImpl:cy,logImpl:Oy,maxImpl:Dy,maximumImpl:jy,minimumImpl:hy,multiplyImpl:py,negImpl:my,notEqualImpl:gy,prodImpl:Ty,rangeImpl:zy,rsqrtImpl:dy,scatterImpl:yy,sigmoidImpl:wy,sliceImpl:Ly,sparseFillEmptyRowsImpl:fy,sparseReshapeImpl:Iy,sparseSegmentReductionImpl:Sy,sqrtImpl:Ay,squaredDifferenceImpl:xy,stridedSliceImpl:Yy,stringNGramsImpl:Cy,stringSplitImpl:Qy,stringToHashBucketFastImpl:Wy,subImpl:Uy,tileImpl:qy,topKImpl:Ky,transposeImpl:by,uniqueImpl:Ny});
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const{addImpl:Ry,bincountImpl:Fy,bincountReduceImpl:By,ceilImpl:Zy,concatImpl:Vy,equalImpl:Xy,expImpl:Hy,expm1Impl:Jy,floorImpl:_y,gatherNdImpl:$y,gatherV2Impl:ew,greaterImpl:tw,greaterEqualImpl:rw,lessImpl:nw,lessEqualImpl:Pw,linSpaceImpl:aw,logImpl:ow,maxImpl:uw,maximumImpl:sw,minimumImpl:vw,multiplyImpl:iw,negImpl:lw,notEqualImpl:cw,prodImpl:Ow,rangeImpl:Dw,rsqrtImpl:jw,scatterImpl:hw,sigmoidImpl:pw,simpleAbsImpl:mw,sliceImpl:gw,sparseFillEmptyRowsImpl:bw,sparseReshapeImpl:Tw,sparseSegmentReductionImpl:zw,sqrtImpl:dw,stridedSliceImpl:yw,stringNGramsImpl:ww,stringSplitImpl:Lw,stringToHashBucketFastImpl:fw,subImpl:Iw,tileImpl:Sw,topKImpl:Aw,transposeImpl:xw,uniqueImpl:Yw}=pe;
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function kw(e,t){return["x","y","z","w","u","v"].slice(0,t).map((t=>`${e}.${t}`))}function Cw(e,t){return 1===t?[e]:kw(e,t)}function Ew(e,t){if(1===e)return"rc";let r="";for(let n=0;n<e;n++)r+=t[n],n<e-1&&(r+=",");return r}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class Qw{constructor(e){if(this.variableNames=["A"],this.packedInputs=!1,this.packedOutput=!0,this.outputShape=e,this.rank=e.length,this.enableShapeUniforms=pd(this.outputShape.length),0===this.rank)this.userCode="\n        void main() {\n          setOutput(vec4(getA(), 0., 0., 0.));\n        }\n      ";else{const e=Cw("rc",this.rank),t=sd(this.rank),r=this.getOutOfBoundsCondition(e),n=this.getSetup(e),P=this.getOutput(e);this.userCode=`\n        void main() {\n          ${t} rc = getOutputCoords();\n\n          if(${r}) {\n            setOutput(vec4(0));\n          } else {\n            ${n}\n\n            setOutput(vec4(${P}));\n          }\n        }\n      `}}getSourceCoordsArr(e){const t=[];for(let r=0;r<=1;r++)for(let n=0;n<=1;n++){let P=`${0===r?"r":"rp1"}, ${0===n?"c":"cp1"}`;for(let t=2;t<this.rank;t++)P=`${e[e.length-1-t]},`+P;t.push(P)}return t}getOutOfBoundsCondition(e){if(1===this.rank)return`rc > ${this.enableShapeUniforms?"outShape":this.outputShape[0]}`;let t="";for(let r=this.rank-2;r<this.rank;r++)t+=`${e[r]} >= ${this.enableShapeUniforms?`outShape[${r}]`:this.outputShape[r]}`,r<this.rank-1&&(t+="||");return t}getSetup(e){if(1===this.rank)return"";const t=e.slice(-2),r=this.enableShapeUniforms?`outShape[${this.rank} - 1]`:this.outputShape[this.rank-1],n=this.enableShapeUniforms?`outShape[${this.rank} - 2]`:this.outputShape[this.rank-2];return`\n      int r = ${t[0]};\n      int c = ${t[1]};\n      int rp1 = r + 1;\n      int cp1 = c + 1;\n\n      bool cEdge = cp1 >= ${r};\n      bool rEdge = rp1 >= ${n};\n    `}getOutput(e){const t=this.getSourceCoordsArr(e);if(1===this.rank){return`getA(rc), (rc + 1 >= ${this.enableShapeUniforms?"outShape":this.outputShape[0]} ? 0. : getA(rc + 1)), 0, 0`}return`getA(${t[0]}),\n            cEdge ? 0. : getA(${t[1]}),\n            rEdge ? 0. : getA(${t[2]}),\n            rEdge || cEdge ? 0. : getA(${t[3]})`}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class Ww{constructor(e,t){this.variableNames=["A"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:"inputShape",type:"ivec3"}],this.outputShape=e,this.enableShapeUniforms=pd(this.outputShape.length);let r="";for(let e=0;e<4;e++){let t="thisRC = rc;";e%2==1&&(t+="thisRC.z += 1;"),e>1&&(t+="thisRC.y += 1;"),r+=`\n        ${t}\n        ${e>0?"if(thisRC.y < rows && thisRC.z < cols){":""}\n          int flatIndex = getFlatIndex(thisRC);\n\n          ivec3 inputRC = inputCoordsFromReshapedOutCoords(flatIndex);\n          vec2 inputRCInnerDims = vec2(float(inputRC.y),float(inputRC.z));\n\n          result[${e}] =\n            getChannel(getA(inputRC.x, inputRC.y, inputRC.z), inputRCInnerDims);\n        ${e>0?"}":""}\n      `}this.userCode=`\n      ${Uw(t,this.enableShapeUniforms)}\n      ${this.enableShapeUniforms?"\n  int getFlatIndex(ivec3 coords) {\n    return coords.x * outShapeStrides[0] + coords.y * outShapeStrides[1] + coords.z;\n  }\n":mz(e)}\n\n      void main() {\n        ivec3 rc = getOutputCoords();\n\n        vec4 result = vec4(0.);\n\n        ivec3 thisRC;\n        int rows = ${this.enableShapeUniforms?"outShape[1]":e[1]};\n        int cols = ${this.enableShapeUniforms?"outShape[2]":e[2]};\n\n        ${r}\n\n        setOutput(result);\n      }\n    `}}function Uw(e,t){return`\n    ivec3 inputCoordsFromReshapedOutCoords(int index) {\n      ${t?pz(["r","c","d"],"inputShape"):Dz(["r","c","d"],e)}\n      return ivec3(r, c, d);\n    }\n  `
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */}class qw{constructor(e){this.gpgpu=e,this.numUsedTextures=0,this.numFreeTextures=0,this._numBytesAllocated=0,this._numBytesFree=0,this.freeTextures={},this.logEnabled=!1,this.usedTextures={}}acquireTexture(e,t,r){const n=Rw(t,r),P=Fw(e,n,r);P in this.freeTextures||(this.freeTextures[P]=[]),P in this.usedTextures||(this.usedTextures[P]=[]);const a=Mw(e,n,this.gpgpu.gl,this.gpgpu.textureConfig,r);if(this.freeTextures[P].length>0){this.numFreeTextures--,this.numUsedTextures++,this._numBytesFree-=a,this.log();const e=this.freeTextures[P].shift();return this.usedTextures[P].push(e),e}let o;return n===he.PACKED_2X2_FLOAT32?o=this.gpgpu.createPackedMatrixTexture(e[0],e[1]):n===he.PACKED_2X2_FLOAT16?o=this.gpgpu.createFloat16PackedMatrixTexture(e[0],e[1]):n===he.UNPACKED_FLOAT32?o=this.gpgpu.createFloat32MatrixTexture(e[0],e[1]):n===he.UNPACKED_FLOAT16?o=this.gpgpu.createFloat16MatrixTexture(e[0],e[1]):n===he.PACKED_4X1_UNSIGNED_BYTE&&(o=this.gpgpu.createUnsignedBytesMatrixTexture(e[0],e[1])),this.usedTextures[P].push(o),this.numUsedTextures++,this._numBytesAllocated+=a,this.log(),o}releaseTexture(e,t,r,n){if(null==this.freeTextures)return;const P=Rw(r,n),a=Fw(t,P,n);a in this.freeTextures||(this.freeTextures[a]=[]);const o=Mw(t,P,this.gpgpu.gl,this.gpgpu.textureConfig,n),u=mt().get("WEBGL_DELETE_TEXTURE_THRESHOLD");-1!==u&&this._numBytesAllocated>u?(this.gpgpu.deleteMatrixTexture(e.texture),this._numBytesAllocated-=o):(this.freeTextures[a].push(e),this.numFreeTextures++,this._numBytesFree+=o),this.numUsedTextures--;const s=this.usedTextures[a],v=s.indexOf(e);if(v<0)throw new Error("Cannot release a texture that was never provided by this texture manager");s.splice(v,1),this.log()}log(){if(!this.logEnabled)return;const e=this.numFreeTextures+this.numUsedTextures;console.log("Free/Used",`${this.numFreeTextures} / ${this.numUsedTextures}`,`(${e})`);const t=this._numBytesFree/this._numBytesAllocated;console.log(`Bytes allocated: ${this._numBytesAllocated}`),console.log(`Bytes unused: ${this._numBytesFree} (${Math.round(100*t)}%)`)}get numBytesAllocated(){return this._numBytesAllocated}get numBytesFree(){return this._numBytesFree}getNumUsedTextures(){return this.numUsedTextures}getNumFreeTextures(){return this.numFreeTextures}dispose(){if(null!=this.freeTextures){for(const e in this.freeTextures)this.freeTextures[e].forEach((e=>{this.gpgpu.deleteMatrixTexture(e.texture)}));for(const e in this.usedTextures)this.usedTextures[e].forEach((e=>{this.gpgpu.deleteMatrixTexture(e.texture)}));this.freeTextures=null,this.usedTextures=null,this.numUsedTextures=0,this.numFreeTextures=0,this._numBytesAllocated=0,this._numBytesFree=0}}}function Gw(e,t){const r=e;if(t===r.R32F)return 4;if(t===r.R16F)return 2;if(t===r.RGBA32F)return 16;if(t===e.RGBA)return 16;if(t===r.RGBA16F)return 8;if(t===r.RGBA8)return 4;throw new Error(`Unknown internal format ${t}`)}function Mw(e,t,r,n,P){const a=Kw(t,n);let o;if(P){const[t,r]=jT(e[0],e[1]);o=t*r}else{const[t,r]=cT(e[0],e[1]);o=t*r}return o*Gw(r,a)}function Kw(e,t){switch(e){case he.PACKED_2X2_FLOAT32:return Cd(t);case he.PACKED_2X2_FLOAT16:return Qd(t);case he.UNPACKED_FLOAT32:return Id(t);case he.UNPACKED_FLOAT16:return Ad(t);case he.PACKED_4X1_UNSIGNED_BYTE:return Yd(t);default:throw new Error(`Unknown physical texture type ${e}`)}}function Nw(e){return mt().getBool("WEBGL_RENDER_FLOAT32_ENABLED")?e?he.PACKED_2X2_FLOAT32:he.UNPACKED_FLOAT32:e?he.PACKED_2X2_FLOAT16:he.UNPACKED_FLOAT16}function Rw(e,t){if(e===je.UPLOAD)return he.PACKED_2X2_FLOAT32;if(e===je.RENDER||null==e)return Nw(t);if(e===je.DOWNLOAD||e===je.PIXELS)return he.PACKED_4X1_UNSIGNED_BYTE;throw new Error(`Unknown logical texture type ${e}`)}function Fw(e,t,r){return`${e[0]}_${e[1]}_${t}_${r}`
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */}class Bw{constructor(e,t){this.variableNames=["A"],this.outputShape=e,this.enableShapeUniforms=pd(this.outputShape.length),this.userCode=`\n      float unaryOperation(float x) {\n        ${t}\n      }\n\n      void main() {\n        float x = getAAtOutCoords();\n        float y = unaryOperation(x);\n\n        setOutput(y);\n      }\n    `}}const Zw="if (isnan(x)) return x;",Vw="return x;",Xw="return abs(x);",Hw="return (x >= 0.0) ? x : (exp(x) - 1.0);",Jw=Zw+"\n  return (x < 0.0) ? 0.0 : x;\n",_w=Zw+"\n  return (x < 0.0) ? 0.0 : min(6.0, x);\n",$w="return x;",eL="return 1.0 / (1.0 + exp(-1.0 * x));"
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */,tL="return x;",rL="\n  vec4 result;\n\n  result.r = (x.r >= 0.0) ? x.r : (exp(x.r) - 1.0);\n  result.g = (x.g >= 0.0) ? x.g : (exp(x.g) - 1.0);\n  result.b = (x.b >= 0.0) ? x.b : (exp(x.b) - 1.0);\n  result.a = (x.a >= 0.0) ? x.a : (exp(x.a) - 1.0);\n\n  return result;\n",nL="\n  vec4 result = x * vec4(greaterThanEqual(x, vec4(0.0)));\n  bvec4 isNaN = isnan(x);\n\n  result.r = isNaN.r ? x.r : result.r;\n  result.g = isNaN.g ? x.g : result.g;\n  result.b = isNaN.b ? x.b : result.b;\n  result.a = isNaN.a ? x.a : result.a;\n\n  return result;\n",PL="\n  vec4 result = min(x, vec4(6.)) * vec4(greaterThanEqual(x, vec4(0.0)));\n  bvec4 isNaN = isnan(x);\n\n  result.r = isNaN.r ? x.r : result.r;\n  result.g = isNaN.g ? x.g : result.g;\n  result.b = isNaN.b ? x.b : result.b;\n  result.a = isNaN.a ? x.a : result.a;\n\n  return result;\n",aL="return 1.0 / (1.0 + exp(-1.0 * x));";class oL{constructor(e,t){this.variableNames=["A"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=e,this.enableShapeUniforms=pd(this.outputShape.length),this.userCode=`\n      vec4 unaryOperation(vec4 x) {\n        ${t}\n      }\n\n      void main() {\n        vec4 x = getAAtOutCoords();\n        vec4 y = unaryOperation(x);\n\n        setOutput(y);\n      }\n    `}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class uL{constructor(e){this.variableNames=["A"],this.packedInputs=!0,this.packedOutput=!1,this.outputShape=e,this.enableShapeUniforms=pd(this.outputShape.length);const t=e.length,r=Cw("rc",t),n=sd(t),P=Ew(t,r),a=r.slice(-2),o=t<=1?"rc":`vec2(${a.join(",")})`;this.userCode=`\n      void main() {\n        ${n} rc = getOutputCoords();\n        vec4 packedInput = getA(${P});\n\n        setOutput(getChannel(packedInput, ${o}));\n      }\n    `}}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const sL=Uj,vL=1e-7,iL=1e-4,lL={};function cL(e){return e in lL||(lL[e]={}),lL[e]}const OL=mt().getNumber("CPU_HANDOFF_SIZE_THRESHOLD"),DL=600;class jL extends we{constructor(e){if(super(),this.pendingRead=new WeakMap,this.pendingDisposal=new WeakSet,this.dataRefCount=new WeakMap,this.numBytesInGPU=0,this.uploadWaitMs=0,this.downloadWaitMs=0,this.lastGlFlushTime=0,this.warnedAboutMemory=!1,this.pendingDeletes=0,this.disposed=!1,!mt().getBool("HAS_WEBGL"))throw new Error("WebGL is not supported on this device");let t;if(null!=e){if(e instanceof Bd)t=e;else{const r=vT(mt().getNumber("WEBGL_VERSION"),e);t=new Bd(r)}this.binaryCache={},this.gpgpuCreatedLocally=!1}else{const e=vT(mt().getNumber("WEBGL_VERSION"));t=new Bd(e),this.binaryCache=cL(mt().getNumber("WEBGL_VERSION")),this.gpgpuCreatedLocally=!0}this.gpgpu=t,this.canvas=this.gpgpu.gl.canvas,this.textureManager=new qw(this.gpgpu),this.numMBBeforeWarning=null==mt().global.screen?1024:mt().global.screen.height*mt().global.screen.width*window.devicePixelRatio*DL/1024/1024,this.texData=new ye(this,Ru())}nextDataId(){return jL.nextDataId++}numDataIds(){return this.texData.numDataIds()-this.pendingDeletes}write(e,t,r){if((mt().getBool("WEBGL_CHECK_NUMERICAL_PROBLEMS")||mt().getBool("DEBUG"))&&this.checkNumericalProblems(e),"complex64"===r&&null!=e)throw new Error("Cannot write to a complex64 dtype. Please use tf.complex(real, imag).");const n={id:this.nextDataId()};return this.texData.set(n,{shape:t,dtype:r,values:e,usage:je.UPLOAD,refCount:1}),n}refCount(e){if(this.texData.has(e)){return this.texData.get(e).refCount}return 0}incRef(e){this.texData.get(e).refCount++}decRef(e){if(this.texData.has(e)){this.texData.get(e).refCount--}}move(e,t,r,n,P){if(mt().getBool("DEBUG")&&this.checkNumericalProblems(t),"complex64"===n)throw new Error("Cannot write to a complex64 dtype. Please use tf.complex(real, imag).");this.texData.set(e,{shape:r,dtype:n,values:t,usage:je.UPLOAD,refCount:P})}disposeIntermediateTensorInfo(e){this.disposeData(e.dataId)}readSync(e){const t=this.texData.get(e),{values:r,dtype:n,complexTensorInfos:P,slice:a,shape:o,isPacked:u}=t;if(null!=a){let t;t=u?new oL(o,$w):new Bw(o,$w);const r=this.runWebGLProgram(t,[{dataId:e,shape:o,dtype:n}],n),P=this.readSync(r.dataId);return this.disposeIntermediateTensorInfo(r),P}if(null!=r)return this.convertAndCacheOnCPU(e);if("string"===n)return r;const s=null!=this.activeTimers;let v,i;if(s&&(v=ea()),"complex64"===n){i=Wm(this.readSync(P.real.dataId),this.readSync(P.imag.dataId))}else i=this.getValuesFromTexture(e);return s&&(this.downloadWaitMs+=ea()-v),this.convertAndCacheOnCPU(e,i)}async read(e){if(this.pendingRead.has(e)){const t=this.pendingRead.get(e);return new Promise((e=>t.push(e)))}const t=this.texData.get(e),{values:r,shape:n,slice:P,dtype:a,complexTensorInfos:o,isPacked:u}=t;if(null!=P){let t;t=u?new oL(n,$w):new Bw(n,$w);const r=this.runWebGLProgram(t,[{dataId:e,shape:n,dtype:a}],a),P=this.read(r.dataId);return this.disposeIntermediateTensorInfo(r),P}if(null!=r)return this.convertAndCacheOnCPU(e);if(mt().getBool("DEBUG")&&!mt().getBool("WEBGL_DOWNLOAD_FLOAT_ENABLED")&&2===mt().getNumber("WEBGL_VERSION"))throw new Error("tensor.data() with WEBGL_DOWNLOAD_FLOAT_ENABLED=false and WEBGL_VERSION=2 not yet supported.");let s,v,i=null;if("complex64"!==a&&mt().get("WEBGL_BUFFER_SUPPORTED")){s=this.decode(e);const t=this.texData.get(s.dataId);i=this.gpgpu.createBufferFromTexture(t.texture.texture,...DT(n))}if(this.pendingRead.set(e,[]),"complex64"!==a&&await this.gpgpu.createAndWaitForFence(),"complex64"===a){const e=await Promise.all([this.read(o.real.dataId),this.read(o.imag.dataId)]);v=Wm(e[0],e[1])}else if(null==i)v=this.getValuesFromTexture(e);else{const e=Ee(n);v=this.gpgpu.downloadFloat32MatrixFromBuffer(i,e)}if(null!=s&&this.disposeIntermediateTensorInfo(s),null!=i){const e=this.gpgpu.gl;mT(e,(()=>e.deleteBuffer(i)))}const l=this.convertAndCacheOnCPU(e,v),c=this.pendingRead.get(e);return this.pendingRead.delete(e),c.forEach((e=>e(l))),this.pendingDisposal.has(e)&&(this.pendingDisposal.delete(e),this.disposeData(e)&&Ru().removeDataId(e,this),this.pendingDeletes--),l}readToGPU(e,t={}){const r=this.texData.get(e),{values:n,shape:P,slice:a,dtype:o,isPacked:u,texture:s}=r;if("complex64"===o)throw new Error("Does not support reading texture for complex64 dtype.");if(null!=a){let r;r=u?new oL(P,$w):new Bw(P,$w);const n=this.runWebGLProgram(r,[{dataId:e,shape:P,dtype:o}],o),a=this.readToGPU(n,t);return this.disposeIntermediateTensorInfo(n),a}if(null==s)throw null!=n?new Error("Data is not on GPU but on CPU."):new Error("There is no data on GPU or CPU.");const v=this.decode(e,t.customTexShape),i=Ru().makeTensorFromTensorInfo(v),l=this.texData.get(v.dataId);return Object.assign({tensorRef:i},l.texture)}bufferSync(e){const t=this.readSync(e.dataId);if("string"===e.dtype)try{const r=t.map((e=>ra(e)));return au(e.shape,e.dtype,r)}catch(e){throw new Error("Failed to decode encoded string bytes into utf-8")}return au(e.shape,e.dtype,t)}checkNumericalProblems(e){if(null!=e)for(let t=0;t<e.length;t++){const r=e[t];if(!zT(r)){if(mt().getBool("WEBGL_RENDER_FLOAT32_CAPABLE"))throw Error(`The value ${r} cannot be represented with your current settings. Consider enabling float32 rendering: 'tf.env().set('WEBGL_RENDER_FLOAT32_ENABLED', true);'`);throw Error(`The value ${r} cannot be represented on this device.`)}}}getValuesFromTexture(e){const{shape:t,dtype:r,isPacked:n}=this.texData.get(e),P=Ee(t);if(mt().getBool("WEBGL_DOWNLOAD_FLOAT_ENABLED")){const r=this.decode(e),n=this.texData.get(r.dataId),a=this.gpgpu.downloadMatrixFromPackedTexture(n.texture.texture,...DT(t)).subarray(0,P);return this.disposeIntermediateTensorInfo(r),a}const a=mt().getBool("WEBGL_PACK")&&!0===n,o=a?HT(t):t,u=a?new Td(o):new bd(o),s=this.runWebGLProgram(u,[{shape:o,dtype:r,dataId:e}],"float32"),v=this.texData.get(s.dataId),i=this.gpgpu.downloadByteEncodedFloatMatrixFromOutputTexture(v.texture.texture,v.texShape[0],v.texShape[1]).subarray(0,P);return this.disposeIntermediateTensorInfo(s),i}timerAvailable(){return mt().getNumber("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE")>0}time(e){const t=this.activeTimers,r=[];let n=!1;null==this.programTimersStack?(this.programTimersStack=r,n=!0):this.activeTimers.push(r),this.activeTimers=r,e();const P=Ce(this.activeTimers.map((e=>e.query))).filter((e=>null!=e)),a=Ce(this.activeTimers.map((e=>e.name))).filter((e=>null!=e));this.activeTimers=t,n&&(this.programTimersStack=null);const o={uploadWaitMs:this.uploadWaitMs,downloadWaitMs:this.downloadWaitMs,kernelMs:null,wallMs:null};return(async()=>{if(mt().getNumber("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE")>0){const e=await Promise.all(P);o.kernelMs=Ae(e),o.getExtraProfileInfo=()=>e.map(((e,t)=>({name:a[t],ms:e}))).map((e=>`${e.name}: ${e.ms}`)).join(", ")}else o.kernelMs={error:"WebGL query timers are not supported in this environment."};return this.uploadWaitMs=0,this.downloadWaitMs=0,o})()}memory(){return{unreliable:!1,numBytesInGPU:this.numBytesInGPU,numBytesInGPUAllocated:this.textureManager.numBytesAllocated,numBytesInGPUFree:this.textureManager.numBytesFree}}startTimer(){return mt().getNumber("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE")>0?this.gpgpu.beginQuery():{startMs:ea(),endMs:null}}endTimer(e){return mt().getNumber("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE")>0?(this.gpgpu.endQuery(),e):(e.endMs=ea(),e)}async getQueryTime(e){if(mt().getNumber("WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE")>0)return this.gpgpu.waitForQueryAndGetTime(e);const t=e;return t.endMs-t.startMs}disposeData(e,t=!1){if(this.pendingDisposal.has(e))return!1;if(!this.texData.has(e))return!0;if(t?this.texData.get(e).refCount=0:this.texData.get(e).refCount--,!t&&this.texData.get(e).refCount>0)return!1;if(this.pendingRead.has(e))return this.pendingDisposal.add(e),this.pendingDeletes++,!1;this.releaseGPUData(e);const{complexTensorInfos:r}=this.texData.get(e);return null!=r&&(this.disposeData(r.real.dataId,t),this.disposeData(r.imag.dataId,t)),this.texData.delete(e),!0}releaseGPUData(e){const{texture:t,dtype:r,texShape:n,usage:P,isPacked:a,slice:o}=this.texData.get(e),u=o&&o.origDataId||e,s=this.dataRefCount.get(u);s>1?this.dataRefCount.set(u,s-1):(this.dataRefCount.delete(u),null!=t&&(this.numBytesInGPU-=this.computeBytes(n,r),this.textureManager.releaseTexture(t,n,P,a)));const v=this.texData.get(e);v.texture=null,v.texShape=null,v.isPacked=!1,v.slice=null}getTexture(e){return this.uploadToGPU(e),this.texData.get(e).texture.texture}getDataInfo(e){return this.texData.get(e)}shouldExecuteOnCPU(e,t=OL){return mt().getBool("WEBGL_CPU_FORWARD")&&e.every((e=>null==this.texData.get(e.dataId).texture&&Ee(e.shape)<t))}getGPGPUContext(){return this.gpgpu}where(e){mP("tf.where() in webgl locks the UI thread. Call tf.whereAsync() instead");const t=e.dataSync();return sL(e.shape,t)}packedUnaryOp(e,t,r){const n=new oL(e.shape,t),P=this.compileAndRun(n,[e],r);return Ru().makeTensorFromTensorInfo(P)}abs(e){if(this.shouldExecuteOnCPU([e])&&"complex64"!==e.dtype){const t=mw(this.texData.get(e.dataId).values);return this.makeOutput(e.shape,e.dtype,t)}if(mt().getBool("WEBGL_PACK_UNARY_OPERATIONS"))return this.packedUnaryOp(e,Xw,e.dtype);const t=new Bw(e.shape,Xw),r=this.compileAndRun(t,[e]);return Ru().makeTensorFromTensorInfo(r)}makeTensorInfo(e,t,r){let n;if("string"===t&&null!=r&&r.length>0&&_e(r[0])){const P=r.map((e=>ta(e)));n=this.write(P,e,t)}else n=this.write(r,e,t);return this.texData.get(n).usage=null,{dataId:n,shape:e,dtype:t}}makeOutput(e,t,r){return Ru().makeTensorFromTensorInfo(this.makeTensorInfo(e,t,r),this)}unpackTensor(e){const t=new uL(e.shape);return this.runWebGLProgram(t,[e],e.dtype)}packTensor(e){const t=new Qw(e.shape);return this.runWebGLProgram(t,[e],e.dtype,null,!0)}packedReshape(e,t){const r=[VT(e.shape),...XT(e.shape)],n={dtype:e.dtype,shape:r,dataId:e.dataId},P=[VT(t),...XT(t)],a=new Ww(P,r),o=[r],u=this.runWebGLProgram(a,[n],e.dtype,o,!0);return{dataId:u.dataId,shape:t,dtype:u.dtype}}decode(e,t){const r=this.texData.get(e),{isPacked:n,shape:P,dtype:a}=r;if(null!=t){xe(Ee(P)<=t[0]*t[1]*4,(()=>"customTexShape is too small. Row * Column * 4 should be equal or larger than the size of the tensor data."))}const o=HT(P);let u;u=n?new gd(o):new md(o);const s=[null!=t?t:DT(o)];return{dtype:a,shape:P,dataId:this.runWebGLProgram(u,[{shape:o,dtype:a,dataId:e}],a,s,!0,t).dataId}}runWebGLProgram(e,t,r,n,P=!1,a){const o=this.makeTensorInfo(e.outputShape,r),u=this.texData.get(o.dataId);if(e.packedOutput&&(u.isPacked=!0),e.outPackingScheme===De.DENSE){const t=null!=a?a:DT(e.outputShape);u.texShape=t.map((e=>2*e))}if(null!=e.outTexUsage&&(u.usage=e.outTexUsage),0===Ee(o.shape))return u.values=Re(o.dtype,0),o;const s=[],v=t.map((t=>{if("complex64"===t.dtype)throw new Error("GPGPUProgram does not support complex64 input. For complex64 dtypes, please separate the program into real and imaginary parts.");let r=this.texData.get(t.dataId);if(null==r.texture){if(!e.packedInputs&&Ee(t.shape)<=mt().getNumber("WEBGL_SIZE_UPLOAD_UNIFORM"))return{shape:t.shape,texData:null,isUniform:!0,uniformValues:r.values};e.packedInputs&&(r.isPacked=!0,r.shape=t.shape)}if(this.uploadToGPU(t.dataId),!!r.isPacked!=!!e.packedInputs)t=r.isPacked?this.unpackTensor(t):this.packTensor(t),s.push(t),r=this.texData.get(t.dataId);else if(r.isPacked&&!$T(r.shape,t.shape)){const e=t,n=t.shape;t.shape=r.shape,t=this.packedReshape(t,n),s.push(t),r=this.texData.get(t.dataId),e.shape=n}return{shape:t.shape,texData:r,isUniform:!1}}));this.uploadToGPU(o.dataId);const i={shape:o.shape,texData:u,isUniform:!1},l=hd(e,v,i),c=this.getAndSaveBinary(l,(()=>cd(this.gpgpu,e,v,i))),O=null!=this.activeTimers;let D;O&&(D=this.startTimer()),mt().get("ENGINE_COMPILE_ONLY")||jd(this.gpgpu,c,v,i,n),s.forEach((e=>this.disposeIntermediateTensorInfo(e))),O&&(D=this.endTimer(D),this.activeTimers.push({name:e.constructor.name,query:this.getQueryTime(D)}));const j=mt().get("WEBGL_FLUSH_THRESHOLD");if(j>0){const e=ea();e-this.lastGlFlushTime>j&&(this.gpgpu.gl.flush(),this.lastGlFlushTime=e)}if(!mt().getBool("WEBGL_LAZILY_UNPACK")&&u.isPacked&&!1===P){const e=this.unpackTensor(o);return this.disposeIntermediateTensorInfo(o),e}return o}compileAndRun(e,t,r,n,P=!1){r=r||t[0].dtype;return this.runWebGLProgram(e,t,r,n,P)}getAndSaveBinary(e,t){return e in this.binaryCache||(this.binaryCache[e]=t()),this.binaryCache[e]}getTextureManager(){return this.textureManager}dispose(){if(!this.disposed){if(!mt().getBool("IS_TEST")){Object.keys(this.binaryCache).forEach((e=>{this.gpgpu.deleteProgram(this.binaryCache[e].webGLProgram),delete this.binaryCache[e]}))}this.textureManager.dispose(),null!=this.canvas&&"undefined"!=typeof HTMLCanvasElement&&this.canvas instanceof HTMLCanvasElement?this.canvas.remove():this.canvas=null,this.gpgpuCreatedLocally&&(this.gpgpu.program=null,this.gpgpu.dispose()),this.disposed=!0}}floatPrecision(){return null==this.floatPrecisionValue&&(this.floatPrecisionValue=Fu((()=>{if(!mt().get("WEBGL_RENDER_FLOAT32_ENABLED")){const e=mt().getBool("DEBUG");mt().set("DEBUG",!1);const t=this.abs(Cl(1e-8)).dataSync()[0];if(mt().set("DEBUG",e),t>0)return 32}return 16}))),this.floatPrecisionValue}epsilon(){return 32===this.floatPrecision()?vL:iL}uploadToGPU(e){const t=this.texData.get(e),{shape:r,dtype:n,values:P,texture:a,usage:o,isPacked:u}=t;if(null!=a)return;const s=null!=this.activeTimers;let v;s&&(v=ea());let i=t.texShape;if(null==i&&(i=JT(r,u),t.texShape=i),null!=P){const e=HT(r);let a,o=i[1],l=i[0];const c=P instanceof Uint8Array||P instanceof Uint8ClampedArray;!u&&c||([o,l]=jT(i[0],i[1])),a=u?new dd(e,c):new zd(e,c);const O=c?[l,o]:i,D=this.makeTensorInfo(O,n),j=this.texData.get(D.dataId);j.usage=c?je.PIXELS:je.UPLOAD,j.texShape=O,this.gpgpu.uploadDenseMatrixToTexture(this.getTexture(D.dataId),o,l,P);const h=[[l,o]],p=!0,m=this.runWebGLProgram(a,[D],n,h,p),g=this.texData.get(m.dataId);t.texShape=g.texShape,t.isPacked=g.isPacked,t.usage=g.usage,mt().get("ENGINE_COMPILE_ONLY")?this.disposeData(m.dataId):(t.texture=g.texture,t.values=null,this.texData.delete(m.dataId)),this.disposeIntermediateTensorInfo(D),s&&(this.uploadWaitMs+=ea()-v)}else{const e=this.acquireTexture(i,o,n,u);t.texture=e}}convertAndCacheOnCPU(e,t){const r=this.texData.get(e),{dtype:n}=r;return this.releaseGPUData(e),null!=t&&(r.values=hL(t,n)),r.values}acquireTexture(e,t,r,n){if(this.numBytesInGPU+=this.computeBytes(e,r),!this.warnedAboutMemory&&this.numBytesInGPU>1024*this.numMBBeforeWarning*1024){const e=(this.numBytesInGPU/1024/1024).toFixed(2);this.warnedAboutMemory=!0,console.warn(`High memory usage in GPU: ${e} MB, most likely due to a memory leak`)}return this.textureManager.acquireTexture(e,t,n)}computeBytes(e,t){return e[0]*e[1]*He(t)}checkCompileCompletion(){for(const[,e]of Object.entries(this.binaryCache))this.checkCompletion_(e)}async checkCompileCompletionAsync(){const e=[];if(this.gpgpu.parallelCompilationExtension){for(const[,t]of Object.entries(this.binaryCache))e.push(this.checkCompletionAsync_(t));return Promise.all(e)}for(const[,t]of Object.entries(this.binaryCache)){const r=new Promise((e=>{try{this.checkCompletion_(t),e(!0)}catch(e){throw e}}));e.push(r)}return Promise.all(e)}async checkCompletionAsync_(e){return this.gpgpu.gl.getProgramParameter(e.webGLProgram,this.gpgpu.parallelCompilationExtension.COMPLETION_STATUS_KHR)?this.checkCompletion_(e):(await new Promise((e=>mm((()=>e())))),this.checkCompletionAsync_(e))}checkCompletion_(e){if(!1===this.gpgpu.gl.getProgramParameter(e.webGLProgram,this.gpgpu.gl.LINK_STATUS)){if(console.log(this.gpgpu.gl.getProgramInfoLog(e.webGLProgram)),!1===this.gpgpu.gl.getShaderParameter(e.fragmentShader,this.gpgpu.gl.COMPILE_STATUS))throw IT(e.source,this.gpgpu.gl.getShaderInfoLog(e.fragmentShader)),new Error("Failed to compile fragment shader.");throw new Error("Failed to link vertex and fragment shaders.")}return!0}getUniformLocations(){for(const[,e]of Object.entries(this.binaryCache)){const{uniformLocations:t,customUniformLocations:r,infLoc:n,nanLoc:P,inShapesLocations:a,inTexShapesLocations:o,outShapeLocation:u,outShapeStridesLocation:s,outTexShapeLocation:v}=Od(this.gpgpu,e.program,e.webGLProgram);e.uniformLocations=t,e.customUniformLocations=r,e.infLoc=n,e.nanLoc=P,e.inShapesLocations=a,e.inTexShapesLocations=o,e.outShapeLocation=u,e.outShapeStridesLocation=s,e.outTexShapeLocation=v}}}function hL(e,t){if("float32"===t||"complex64"===t)return e;if("int32"===t||"bool"===t){const r="int32"===t?new Int32Array(e.length):new Uint8Array(e.length);for(let t=0;t<r.length;++t)r[t]=Math.round(e[t]);return r}throw new Error(`Unknown dtype ${t}`)}
/**
     * @license
     * Copyright 2020 Google Inc. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */jL.nextDataId=0,Ma()&&Vu("webgl",(()=>new jL),2)
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */;class pL{constructor(e,t,r){this.variableNames=["A","B"],this.outputShape=os(t,r),this.enableShapeUniforms=pd(this.outputShape.length),this.userCode=`\n      float binaryOperation(float a, float b) {\n        ${e}\n      }\n\n      void main() {\n        float a = getAAtOutCoords();\n        float b = getBAtOutCoords();\n        setOutput(binaryOperation(a, b));\n      }\n    `}}
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const mL="\n  result.r = isNaN.r > 0. ? NAN : result.r;\n  result.g = isNaN.g > 0. ? NAN : result.g;\n  result.b = isNaN.b > 0. ? NAN : result.b;\n  result.a = isNaN.a > 0. ? NAN : result.a;\n";class gL{constructor(e,t,r,n=!1){this.variableNames=["A","B"],this.supportsBroadcasting=!0,this.packedInputs=!0,this.packedOutput=!0,this.outputShape=os(t,r);const P=this.outputShape.length;this.enableShapeUniforms=pd(P);let a="";if(n)if(0===P||1===Ee(this.outputShape))a="\n          result.y = 0.;\n          result.z = 0.;\n          result.w = 0.;\n        ";else{if(a=`\n          ${sd(P)} coords = getOutputCoords();\n        `,1===P)this.enableShapeUniforms?a+="\n            result.y = (coords + 1) >= outShape ? 0. : result.y;\n            result.z = 0.;\n            result.w = 0.;\n          ":a+=`\n            result.y = (coords + 1) >= ${this.outputShape[0]} ? 0. : result.y;\n            result.z = 0.;\n            result.w = 0.;\n          `;else{const e=Cw("coords",P);this.enableShapeUniforms?a+=`\n            bool nextRowOutOfBounds =\n              (${e[P-2]} + 1) >= outShape[${P} - 2];\n            bool nextColOutOfBounds =\n              (${e[P-1]} + 1) >= outShape[${P} - 1];\n            result.y = nextColOutOfBounds ? 0. : result.y;\n            result.z = nextRowOutOfBounds ? 0. : result.z;\n            result.w = nextColOutOfBounds || nextRowOutOfBounds ? 0. : result.w;\n          `:a+=`\n            bool nextRowOutOfBounds =\n              (${e[P-2]} + 1) >= ${this.outputShape[P-2]};\n            bool nextColOutOfBounds =\n              (${e[P-1]} + 1) >= ${this.outputShape[P-1]};\n            result.y = nextColOutOfBounds ? 0. : result.y;\n            result.z = nextRowOutOfBounds ? 0. : result.z;\n            result.w = nextColOutOfBounds || nextRowOutOfBounds ? 0. : result.w;\n          `}}this.userCode=`\n      vec4 binaryOperation(vec4 a, vec4 b) {\n        ${e}\n      }\n\n      void main() {\n        vec4 a = getAAtOutCoords();\n        vec4 b = getBAtOutCoords();\n\n        vec4 result = binaryOperation(a, b);\n        ${a}\n\n        setOutput(result);\n      }\n    `}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function bL(e){const{inputs:t,backend:r}=e,{x:n}=t;return r.incRef(n.dataId),{dataId:n.dataId,shape:n.shape,dtype:n.dtype}}const TL={kernelName:Yr,backendName:"webgl",kernelFunc:bL};
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function zL(e){const{inputs:t,backend:r}=e,{real:n,imag:P}=t,a=r.makeTensorInfo(n.shape,"complex64"),o=r.texData.get(a.dataId),u=bL({inputs:{x:n},backend:r}),s=bL({inputs:{x:P},backend:r});return o.complexTensorInfos={real:u,imag:s},a}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const dL="return (a < 0.) ? b * a : a;",yL="\n  vec4 aLessThanZero = vec4(lessThan(a, vec4(0.)));\n  return (aLessThanZero * (b * a)) + ((vec4(1.0) - aLessThanZero) * a);\n"
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */,wL="return (a < 0.) ? b * a : a;",LL="\n  vec4 aLessThanZero = vec4(lessThan(a, vec4(0.)));\n  return (aLessThanZero * (b * a)) + ((vec4(1.0) - aLessThanZero) * a);\n"
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */,fL="if (isnan(x)) return x;";function IL({opSnippet:e,packedOpSnippet:t,cpuKernelImpl:r,dtype:n}){return({inputs:P,backend:a})=>{const{x:o}=P,u=a,s=n||o.dtype;if(u.shouldExecuteOnCPU([o])&&null!=r){const e=u.texData.get(o.dataId),t=r(e.values,s);return u.makeTensorInfo(o.shape,s,t)}let v;return v=mt().getBool("WEBGL_PACK_UNARY_OPERATIONS")&&null!=t?new oL(o.shape,t):new Bw(o.shape,e),u.runWebGLProgram(v,[o],s)}}function SL({opSnippet:e,packedOpSnippet:t,checkOutOfBounds:r=!1,supportsComplex:n=!1,cpuKernelImpl:P,dtype:a}){return({inputs:o,backend:u})=>{const{a:s,b:v}=o,i=u;if(n&&"complex64"===s.dtype){const t=i.texData.get(s.dataId),r=i.texData.get(v.dataId),[n,P]=[[t.complexTensorInfos.real,r.complexTensorInfos.real],[t.complexTensorInfos.imag,r.complexTensorInfos.imag]].map((t=>{const[r,n]=t,P={dataId:r.dataId,dtype:r.dtype,shape:s.shape},a={dataId:n.dataId,dtype:n.dtype,shape:v.shape},o=new pL(e,s.shape,v.shape);return i.runWebGLProgram(o,[P,a],La(r.dtype,n.dtype))})),a=zL({inputs:{real:n,imag:P},backend:i});return i.disposeIntermediateTensorInfo(n),i.disposeIntermediateTensorInfo(P),a}const l=a||La(s.dtype,v.dtype);if(("string"===s.dtype||"string"===v.dtype||i.shouldExecuteOnCPU([s,v]))&&null!=P){const e=i.texData.get(s.dataId).values,t=i.texData.get(v.dataId).values,r="string"===s.dtype?pg(e):e,n="string"===s.dtype?pg(t):t,[a,o]=P(s.shape,v.shape,r,n,l),u=i.makeTensorInfo(o,l);return i.texData.get(u.dataId).values=a,u}let c;return c=mt().getBool("WEBGL_PACK_BINARY_OPERATIONS")&&null!=t?new gL(t,s.shape,v.shape,r):new pL(e,s.shape,v.shape),i.runWebGLProgram(c,[s,v],l)}}function AL(e,t=!1){if("linear"===e)return t?tL:Vw;if("relu"===e)return t?nL:Jw;if("elu"===e)return t?rL:Hw;if("relu6"===e)return t?PL:_w;if("prelu"===e)return t?LL:wL;if("leakyrelu"===e)return t?yL:dL;if("sigmoid"===e)return t?aL:eL;throw new Error(`Activation ${e} has not been implemented for the WebGL backend.`)}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const xL="return a + b;",YL=SL({opSnippet:xL,packedOpSnippet:xL,supportsComplex:!0,cpuKernelImpl:Ry}),kL={kernelName:It,backendName:"webgl",kernelFunc:YL};
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
class CL{constructor(e,t){this.variableNames=["x"];const{windowSize:r,batchSize:n,inSize:P,outSize:a}=e;this.outputShape=[n,a];const o=4*Math.floor(r/4),u=r%4;let s="sumValue += dot(values, ones);";if(null!=t){const e=1/t;s=`sumValue += dot(values * ${We(e)?e.toPrecision(2):e}, ones);`}let v="";P%r>0&&(v=`\n        if (inIdx < 0 || inIdx >= ${P}) {\n          return 0.0;\n        }\n      `),this.userCode=`\n      const vec4 ones = vec4(1.0, 1.0, 1.0, 1.0);\n\n      float getValue(int batch, int inIdx) {\n        ${v}\n        return getX(batch, inIdx);\n      }\n\n      void main() {\n        ivec2 coords = getOutputCoords();\n        int batch = coords[0];\n        int outIdx = coords[1];\n        int inOffset = outIdx * ${r};\n\n        float sumValue = 0.0;\n\n        for (int i = 0; i < ${o}; i += 4) {\n          int inIdx = inOffset + i;\n          vec4 values = vec4(\n            getValue(batch, inIdx),\n            getValue(batch, inIdx + 1),\n            getValue(batch, inIdx + 2),\n            getValue(batch, inIdx + 3)\n          );\n\n          ${s}\n        }\n\n        int inIdx = inOffset + ${o};\n        if (${1===u}) {\n          vec4 values = vec4(getValue(batch, inIdx), 0.0, 0.0, 0.0);\n\n          ${s}\n        } else if (${2===u}) {\n          vec4 values = vec4(\n            getValue(batch, inIdx),\n            getValue(batch, inIdx + 1), 0.0, 0.0);\n\n          ${s}\n        } else if (${3===u}) {\n          vec4 values = vec4(\n            getValue(batch, inIdx),\n            getValue(batch, inIdx + 1),\n            getValue(batch, inIdx + 2), 0.0);\n\n          ${s}\n        }\n        setOutput(sumValue);\n      }\n    `}}
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class EL{constructor(e,t){this.variableNames=["x"];const{windowSize:r,batchSize:n,inSize:P,outSize:a}=e;this.outputShape=[n,a];let o="0.0",u="";"prod"===t?o="1.0":"min"===t?(o="1.0 / 1e-20",u="min"):"max"===t&&(o="-1.0 / 1e-20",u="max");let s=`${t}(${t}(${t}(minMaxValue[0], minMaxValue[1]), minMaxValue[2]), minMaxValue[3])`;"sum"===t?s="sumValue":"prod"===t?s="prodValue":"all"===t?s="allValue":"any"===t&&(s="anyValue");const v=4*Math.floor(r/4),i=r%4;let l=`\n      if (${"sum"===t}) {\n        sumValue += dot(values, ones);\n      } else if (${"prod"===t}) {\n        vec2 tmp = vec2(values[0], values[1]) * vec2(values[2], values[3]);\n        prodValue *= tmp[0] * tmp[1];\n      } else {\n        minMaxValue = ${u}(values, minMaxValue);\n        if (${"min"===t} || ${"max"===t}) {\n          minMaxValue = ${u}(values, minMaxValue);\n          bvec4 isNaN = isnan(values);\n          if (isNaN.r || isNaN.g || isNaN.b || isNaN.a) {\n            minMaxValue = vec4(NAN);\n          }\n        }\n      }\n    `,c="vec4";"all"===t?(o="1.0",l="\n        bool reducedAllValue = all(values);\n        float floatedReducedAllValue = float(reducedAllValue);\n        allValue = float(allValue >= 1.0 && floatedReducedAllValue >= 1.0);\n      ",c="bvec4"):"any"===t&&(o="0.0",l="\n        bool reducedAnyValue = any(values);\n        float floatedReducedAnyValue = float(reducedAnyValue);\n        anyValue = float(anyValue >= 1.0 || floatedReducedAnyValue >= 1.0);\n      ",c="bvec4");let O="";P%r>0&&(O=`\n        if (inIdx < 0 || inIdx >= ${P}) {\n          return initializationValue;\n        }\n      `),this.userCode=`\n      const float initializationValue = ${o};\n      const vec4 ones = vec4(1.0, 1.0, 1.0, 1.0);\n\n      float getValue(int batch, int inIdx) {\n        ${O}\n        return getX(batch, inIdx);\n      }\n\n      void main() {\n        ivec2 coords = getOutputCoords();\n        int batch = coords[0];\n        int outIdx = coords[1];\n        int inOffset = outIdx * ${r};\n\n        vec4 minMaxValue = vec4(${o});\n        float prodValue = 1.0;\n        float sumValue = 0.0;\n        float allValue = 1.0;\n        float anyValue = 0.0;\n\n        for (int i = 0; i < ${v}; i += 4) {\n          int inIdx = inOffset + i;\n          ${c} values = ${c}(\n            getValue(batch, inIdx),\n            getValue(batch, inIdx + 1),\n            getValue(batch, inIdx + 2),\n            getValue(batch, inIdx + 3)\n          );\n\n          ${l}\n        }\n\n        int inIdx = inOffset + ${v};\n        if (${1===i}) {\n          ${c} values = ${c}(\n            getValue(batch, inIdx),\n            initializationValue,\n            initializationValue,\n            initializationValue\n          );\n\n          ${l}\n        } else if (${2===i}) {\n          ${c} values = ${c}(\n            getValue(batch, inIdx),\n            getValue(batch, inIdx + 1),\n            initializationValue,\n            initializationValue\n          );\n\n          ${l}\n        } else if (${3===i}) {\n          ${c} values = ${c}(\n            getValue(batch, inIdx),\n            getValue(batch, inIdx + 1),\n            getValue(batch, inIdx + 2),\n            initializationValue\n          );\n\n          ${l}\n        }\n        setOutput(${s});\n      }\n    `}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function QL(e){const t=[];for(;0===t.length||1!==t[t.length-1].outSize;){const r=t.length?t[t.length-1].outSize:e[1],n=zm(r);t.push({inSize:r,windowSize:n,outSize:Math.ceil(r/n)})}return t}function WL(e,t,r,n){const P=QL(e.shape);let a=e;for(let o=0;o<P.length;o++){const{inSize:u,windowSize:s,outSize:v}=P[o];let i,l;i="mean"===r?0===o?new CL({windowSize:s,inSize:u,batchSize:e.shape[0],outSize:v},u):new CL({windowSize:s,inSize:u,batchSize:e.shape[0],outSize:v}):new EL({windowSize:s,inSize:u,batchSize:e.shape[0],outSize:v},r),l=a,a=n.runWebGLProgram(i,[a],t),l.dataId!==e.dataId&&n.disposeIntermediateTensorInfo(l)}return a}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function UL(e,t,r){const n=[VT(e.shape),...XT(e.shape)],P={dtype:e.dtype,shape:n,dataId:e.dataId},a=[VT(t),...XT(t)],o=new Ww(a,n),u=[n],s=r.runWebGLProgram(o,[P],e.dtype,u,!0);return{dataId:s.dataId,shape:t,dtype:s.dtype}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function qL(e){const{inputs:t,backend:r,attrs:n}=e,{x:P}=t,{shape:a}=n,o=r,u=Ee(P.shape),s=Me(a,u),v=Ee(s);xe(u===v,(()=>`The new shape (${s}) has ${v} elements and the old shape (${P.shape}) has ${u} elements. The new shape and old shape must have the same number of elements.`));const i=o.texData.get(P.dataId);return!i.isPacked||$T(P.shape,s)||null!==i.texture&&$T(i.shape,s)?(o.incRef(P.dataId),{dataId:P.dataId,shape:s,dtype:P.dtype}):UL(P,s,o)}const GL={kernelName:dn,backendName:"webgl",kernelFunc:qL};
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class ML{constructor(e,t){this.variableNames=["A"];const r=new Array(e.length);for(let n=0;n<r.length;n++)r[n]=e[t[n]];this.outputShape=r,this.rank=r.length;const n=sd(this.rank),P=KL(t);this.userCode=`\n    void main() {\n      ${n} resRC = getOutputCoords();\n      setOutput(getA(${P}));\n    }\n    `}}function KL(e){const t=e.length;if(t>6)throw Error(`Transpose for rank ${t} is not yet supported`);const r=["resRC.x","resRC.y","resRC.z","resRC.w","resRC.u","resRC.v"],n=new Array(t);for(let t=0;t<e.length;t++)n[e[t]]=r[t];return n.join()}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class NL{constructor(e,t){this.variableNames=["A"],this.packedInputs=!0,this.packedOutput=!0;const r=new Array(e.length);for(let n=0;n<r.length;n++)r[n]=e[t[n]];if(this.outputShape=r,this.rank=r.length,this.rank>6)throw Error(`Packed transpose for rank ${this.rank} is not yet supported.`);const n=sd(this.rank),P=kw("rc",this.rank),a=new Array(this.rank);for(let e=0;e<t.length;e++)a[t[e]]=P[e];const o=`vec2(${a.slice(-2).join()})`,u=`++${P[this.rank-1]} < ${r[this.rank-1]}`,s=`getChannel(getA(${a.join()}), ${o})`;this.userCode=`\n    void main() {\n      ${n} rc = getOutputCoords();\n      vec4 result = vec4(0.);\n      result[0] = ${s};\n      if(${u}) {\n        result[1] = ${s};\n      }\n      --${P[this.rank-1]};\n      if(++${P[this.rank-2]} < ${r[this.rank-2]}) {\n        result[2] = ${s};\n        if(${u}) {\n          result[3] = ${s};\n        }\n      }\n      setOutput(result);\n    }\n    `}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function RL(e,t,r){const n=mt().getBool("WEBGL_PACK_ARRAY_OPERATIONS")?new NL(e.shape,t):new ML(e.shape,t);return r.runWebGLProgram(n,[e],e.dtype)}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function FL(e,t,r,n){const P=t,a=e.shape.length,o=Ke(P,e.shape);let u=o;const s=wl(u,a),v=null!=s;let i=e;v&&(i=RL(e,s,n),u=fl(u.length,a)),yl("sum",u,a);const[l,c]=zl(i.shape,u);let O=l;r&&(O=dl(l,o));const D=Ee(c),j=qL({inputs:{x:i},attrs:{shape:[Ee(e.shape)/D,D]},backend:n}),h=WL(j,fa(e.dtype),"sum",n),p=qL({inputs:{x:h},attrs:{shape:O},backend:n});return n.disposeIntermediateTensorInfo(j),n.disposeIntermediateTensorInfo(h),v&&n.disposeIntermediateTensorInfo(i),p}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function BL(e){const{inputs:t,backend:r,attrs:n}=e,{x:P}=t,{axis:a,keepDims:o}=n;return FL(P,a,o,r)}const ZL={kernelName:Mn,backendName:"webgl",kernelFunc:BL},VL=SL({opSnippet:"\n  if(a < 0.0 && floor(b) < b){\n    return NAN;\n  }\n  if (b == 0.0) {\n    return 1.0;\n  }\n  return (round(mod(b, 2.0)) != 1) ?\n      pow(abs(a), b) : sign(a) * pow(abs(a), b);\n",packedOpSnippet:"\n  // isModRound1 has 1 for components with round(mod(b, 2.0)) == 1, 0 otherwise.\n  vec4 isModRound1 = vec4(equal(round(mod(b, 2.0)), ivec4(1)));\n  vec4 multiplier = sign(a) * isModRound1 + (vec4(1.0) - isModRound1);\n  vec4 result = multiplier * pow(abs(a), b);\n\n  // Ensure that a^0 = 1, including 0^0 = 1 as this correspond to TF and JS\n  bvec4 isExpZero = equal(b, vec4(0.0));\n  result.r = isExpZero.r ? 1.0 : result.r;\n  result.g = isExpZero.g ? 1.0 : result.g;\n  result.b = isExpZero.b ? 1.0 : result.b;\n  result.a = isExpZero.a ? 1.0 : result.a;\n\n  vec4 isNaN = vec4(lessThan(a, vec4(0.0))) * vec4(lessThan(floor(b), b));\n  "+mL+"\n  return result;\n"}),XL={kernelName:hn,backendName:"webgl",kernelFunc:VL};
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
class HL{constructor(e){this.outputShape=[],this.outputShape=bm(e,1),this.variableNames=e.map(((e,t)=>`T${t}`));const t=new Array(e.length-1);t[0]=e[0][1];for(let r=1;r<t.length;r++)t[r]=t[r-1]+e[r][1];const r=[`if (yC < ${t[0]}) setOutput(getT0(yR, yC));`];for(let e=1;e<t.length;e++){const n=t[e-1];r.push(`else if (yC < ${t[e]}) setOutput(getT${e}(yR, yC-${n}));`)}const n=t.length,P=t[t.length-1];r.push(`else setOutput(getT${n}(yR, yC-${P}));`),this.userCode=`\n      void main() {\n        ivec2 coords = getOutputCoords();\n        int yR = coords.x;\n        int yC = coords.y;\n\n        ${r.join("\n        ")}\n      }\n    `}}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class JL{constructor(e,t){this.packedInputs=!0,this.packedOutput=!0,this.outputShape=[],this.outputShape=bm(e,t);const r=this.outputShape,n=r.length,P=sd(n),a=Cw("coords",n),o=["x","y","z","w","u","v"].slice(0,n);this.variableNames=e.map(((e,t)=>`T${t}`));const u=new Array(e.length-1);u[0]=e[0][t];for(let r=1;r<u.length;r++)u[r]=u[r-1]+e[r][t];const s=o[t],v=o.slice(-2),i=o.join();let l=`if (${s} < ${u[0]}) {\n        return getChannel(\n            getT0(${i}), vec2(${v.join()}));\n        }`;for(let e=1;e<u.length;e++){const t=u[e-1];l+=`\n        if (${s} < ${u[e]}  && ${s} >= ${u[e-1]}) {\n          return getChannel(\n            getT${e}(${_L(o,s,t)}),\n            vec2(${_L(v,s,t)}));\n        }`}const c=u.length,O=u[u.length-1];l+=`\n        return getChannel(\n          getT${c}(${_L(o,s,O)}),\n          vec2(${_L(v,s,O)}));`,this.userCode=`\n      float getValue(${o.map((e=>"int "+e))}) {\n        ${l}\n      }\n\n      void main() {\n        ${P} coords = getOutputCoords();\n        vec4 result = vec4(getValue(${a}), 0., 0., 0.);\n\n        ${a[n-1]} = ${a[n-1]} + 1;\n        if (${a[n-1]} < ${r[n-1]}) {\n          result.g = getValue(${a});\n        }\n\n        ${a[n-2]} = ${a[n-2]} + 1;\n        if (${a[n-2]} < ${r[n-2]}) {\n          result.a = getValue(${a});\n        }\n\n        ${a[n-1]} = ${a[n-1]} - 1;\n        if (${a[n-2]} < ${r[n-2]} &&\n            ${a[n-1]} < ${r[n-1]}) {\n          result.b = getValue(${a});\n        }\n        setOutput(result);\n      }\n    `}}function _L(e,t,r){const n=e.indexOf(t),P=e.map(((e,t)=>t===n?`${e} - ${r}`:e));return P.join()}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function $L(e){const{inputs:t,backend:r}=e,{input:n}=t;return bL({inputs:{x:r.texData.get(n.dataId).complexTensorInfos.imag},backend:r})}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function ef(e){const{inputs:t,backend:r}=e,{input:n}=t;return bL({inputs:{x:r.texData.get(n.dataId).complexTensorInfos.real},backend:r})}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function tf(e,t,r){const n=e[0].dtype;if("complex64"===n){const n=e.map((e=>ef({inputs:{input:e},backend:r}))),P=e.map((e=>$L({inputs:{input:e},backend:r}))),a=tf(n,t,r),o=tf(P,t,r),u=zL({inputs:{real:a,imag:o},backend:r});return n.forEach((e=>r.disposeIntermediateTensorInfo(e))),P.forEach((e=>r.disposeIntermediateTensorInfo(e))),r.disposeIntermediateTensorInfo(a),r.disposeIntermediateTensorInfo(o),u}let P=r.shouldExecuteOnCPU(e);if("string"===n&&(P=!0),P){const P=e.map((e=>{const n=Ee(e.shape.slice(t));return qL({inputs:{x:e},backend:r,attrs:{shape:[-1,n]}})})),a=P.map((e=>({vals:r.readSync(e.dataId),shape:e.shape}))),o=bm(P.map((e=>e.shape)),1),u=1===P[0].shape[0],s=Vy(a,o,n,u),v=bm(e.map((e=>e.shape)),t),i=r.makeTensorInfo(v,n,s);return P.forEach((e=>r.disposeIntermediateTensorInfo(e))),i}const a=mt().getNumber("WEBGL_MAX_TEXTURES_IN_SHADER");if(e.length>a){const n=[];for(let P=0;P<e.length;P+=a){const o=e.slice(P,P+a);n.push(tf(o,t,r))}const P=tf(n,t,r);for(const e of n)r.disposeIntermediateTensorInfo(e);return P}if(mt().getBool("WEBGL_PACK_ARRAY_OPERATIONS")&&e[0].shape.length>1){const P=new JL(e.map((e=>e.shape)),t);return r.runWebGLProgram(P,e,n)}const{tensors2D:o,outShape:u}=rf(e,t,r),s=new HL(o.map((e=>e.shape))),v=r.runWebGLProgram(s,o,n);o.forEach((e=>r.disposeIntermediateTensorInfo(e)));const i=qL({inputs:{x:v},attrs:{shape:u},backend:r});return r.disposeIntermediateTensorInfo(v),i}function rf(e,t,r){const n=bm(e.map((e=>e.shape)),t),P=e.map((e=>qL({inputs:{x:e},attrs:{shape:[-1,Ee(e.shape.slice(t))]},backend:r})));return{tensors2D:P,outShape:n}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function nf(e){const{inputs:t,backend:r,attrs:n}=e,{axis:P}=n,a=Ke(P,t[0].shape)[0],o=bm(t.map((e=>e.shape)),a);if(0===Ee(o))return r.makeTensorInfo(o,t[0].dtype,[]);const u=t.filter((e=>Ee(e.shape)>0));if(1===u.length)return bL({inputs:{x:u[0]},backend:r});const s=u.map((e=>e.shape));return gm(s,a),tf(u,a,r)}const Pf={kernelName:Ht,backendName:"webgl",kernelFunc:nf};
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the License);
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an AS IS BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function af(e){const{inputs:t,attrs:r,backend:n}=e,{dim:P}=r,{input:a}=t,o=a.shape.length,u=a.shape.slice();let s=P;return P<0&&(xe(-(o+1)<=P,(()=>`Axis must be in the interval [${-(o+1)}, ${o}]`)),s=o+P+1),u.splice(s,0,1),qL({inputs:{x:a},backend:n,attrs:{shape:u}})}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function of(e){const{inputs:t,backend:r,attrs:n}=e,{axis:P}=n;if(1===t.length)return af({inputs:{input:t[0]},backend:r,attrs:{dim:P}});const a=t[0].shape,o=t[0].dtype;t.forEach((e=>{Ye(a,e.shape,"All tensors passed to stack must have matching shapes"),xe(o===e.dtype,(()=>"All tensors passed to stack must have matching dtypes"))}));const u=[],s=t.map((e=>{const t=af({inputs:{input:e},backend:r,attrs:{dim:P}});return u.push(t),t})),v=nf({inputs:s,backend:r,attrs:{axis:P}});return u.forEach((e=>r.disposeIntermediateTensorInfo(e))),v}const uf={kernelName:Dn,backendName:"webgl",kernelFunc:of},sf=SL({opSnippet:"return float(a != b);",cpuKernelImpl:cw,dtype:"bool"}),vf="return float(int(x));";
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function lf(e,t){const r=new Bw(e.shape,vf),n=t.runWebGLProgram(r,[e],"int32");return{dataId:n.dataId,shape:n.shape,dtype:n.dtype}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function cf(e){const{inputs:t,backend:r,attrs:n}=e,{x:P}=t,{dtype:a}=n;if("complex64"===a){if("complex64"===P.dtype)return bL({inputs:{x:P},backend:r});const e=iO(P.shape),t=cf({inputs:{x:P},backend:r,attrs:{dtype:"float32"}}),n=zL({inputs:{real:t,imag:e},backend:r});return e.dispose(),r.disposeIntermediateTensorInfo(t),n}if("complex64"===P.dtype){const e=ef({inputs:{input:P},backend:r}),t=cf({inputs:{x:e},backend:r,attrs:{dtype:a}});return r.disposeIntermediateTensorInfo(e),t}if(!Ve(P.dtype,a)){const e=bL({inputs:{x:P},backend:r});return{dataId:e.dataId,shape:e.shape,dtype:a}}if("int32"===a)return lf(P,r);if("bool"===a){const e=r.makeTensorInfo([],"bool",Re("bool",1)),t=sf({inputs:{a:P,b:e},backend:r});return r.disposeIntermediateTensorInfo(e),t}throw new Error(`Error in Cast: failed to cast ${P.dtype} to ${a}`)}const Of={kernelName:Ft,backendName:"webgl",kernelFunc:cf},Df=IL({opSnippet:Zw+"\n  return (x < 0.0) ? 0.0 : x;\n",packedOpSnippet:"\n  vec4 result = x * vec4(greaterThanEqual(x, vec4(0.0)));\n  bvec4 isNaN = isnan(x);\n\n  result.r = isNaN.r ? x.r : result.r;\n  result.g = isNaN.g ? x.g : result.g;\n  result.b = isNaN.b ? x.b : result.b;\n  result.a = isNaN.a ? x.a : result.a;\n\n  return result;\n"}),jf={kernelName:zn,backendName:"webgl",kernelFunc:Df};
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function hf(e,t,r,n){const P=Ee(t),a=qL({inputs:{x:e},attrs:{shape:[Ee(e.shape)/P,P]},backend:n}),o=WL(a,"float32","mean",n),u=qL({inputs:{x:o},attrs:{shape:r},backend:n});return n.disposeIntermediateTensorInfo(a),n.disposeIntermediateTensorInfo(o),u}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const pf={kernelName:$r,backendName:"webgl",kernelFunc:({inputs:e,attrs:t,backend:r})=>{const{x:n}=e,{keepDims:P,axis:a}=t,o=r,u=n.shape.length,s=Ke(a,n.shape);let v=s;const i=wl(v,u),l=null!=i,c=o.shouldExecuteOnCPU([n]),O=[];let D=n;if(l){if(c){const e=o.texData.get(D.dataId).values,t=new Array(u);for(let e=0;e<t.length;e++)t[e]=n.shape[i[e]];const r=xw(e,n.shape,n.dtype,i,t);D=o.makeTensorInfo(t,n.dtype);o.texData.get(D.dataId).values=r}else D=RL(n,i,o);O.push(D),v=fl(v.length,u)}yl("sum",v,u);const[j,h]=zl(D.shape,v);let p=j;P&&(p=dl(j,s));const m=hf(D,h,p,o);for(const e of O)o.disposeIntermediateTensorInfo(e);return m}};
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function mf(e){const{inputs:t,backend:r,attrs:n}=e,{x:P}=t,{perm:a}=n,o=r,u=P.shape.length,s=new Array(u);for(let e=0;e<s.length;e++)s[e]=P.shape[a[e]];let v;if(o.shouldExecuteOnCPU([P])){const e=o.texData.get(P.dataId).values,t=xw(e,P.shape,P.dtype,a,s);v=o.makeTensorInfo(s,P.dtype);o.texData.get(v.dataId).values=t}else v=RL(P,a,o);return v}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function gf(e){const{inputs:t,backend:r,attrs:n}=e,{x:P}=t,{axis:a,keepDims:o}=n,u=P.shape.length,s=[],v=Ke(a,P.shape);let i=v;const l=wl(i,u);let c,O=P;if(null!=l&&(O=mf({inputs:{x:P},backend:r,attrs:{perm:l}}),i=fl(i.length,u),s.push(O)),yl("prod",i,u),r.shouldExecuteOnCPU([O])){const e=r.texData.get(O.dataId).values,{outVals:t,outShape:n,outDtype:P}=Ow(O.shape,O.dtype,e,i);c=r.makeTensorInfo(n,P,t)}else{const[e,t]=zl(O.shape,i),n=Ee(t),a=qL({inputs:{x:O},backend:r,attrs:{shape:[-1,n]}}),o=WL(a,fa(P.dtype),"prod",r);c=qL({inputs:{x:o},backend:r,attrs:{shape:e}}),s.push(a),s.push(o)}if(o){s.push(c);const e=dl(c.shape,v);c=qL({inputs:{x:c},backend:r,attrs:{shape:e}})}return s.forEach((e=>r.disposeIntermediateTensorInfo(e))),c}const bf={kernelName:mn,backendName:"webgl",kernelFunc:gf};
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class Tf{constructor(e,t,r){this.variableNames=["x"],this.customUniforms=[{name:"value",type:"float"}],this.outputShape=t.map(((t,r)=>t[0]+e[r]+t[1]));const n=e.length,P=sd(n),a=t.map((e=>e[0])).join(","),o=t.map(((t,r)=>t[0]+e[r])).join(","),u=["coords[0]","coords[1]","coords[2]","coords[3]"].slice(0,n);this.userCode=1!==n?`\n      ${P} start = ${P}(${a});\n      ${P} end = ${P}(${o});\n\n      void main() {\n        ${P} outC = getOutputCoords();\n        if (any(lessThan(outC, start)) || any(greaterThanEqual(outC, end))) {\n          setOutput(value);\n        } else {\n          ${P} coords = outC - start;\n          setOutput(getX(${u}));\n        }\n      }\n    `:`\n        int start = ${a};\n        int end = ${o};\n\n        void main() {\n          int outC = getOutputCoords();\n          if (outC < start || outC >= end) {\n            setOutput(value);\n          } else {\n            setOutput(getX(outC - start));\n          }\n        }\n      `}}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class zf{constructor(e,t,r){this.variableNames=["x"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:"value",type:"float"}],this.outputShape=t.map(((t,r)=>t[0]+e[r]+t[1]));const n=e.length,P=sd(n),a=t.map((e=>e[0])).join(","),o=t.map(((t,r)=>t[0]+e[r])).join(","),u=Cw("rc",n),s=Cw("source",n),v=`${u[n-1]} < ${this.outputShape[n-1]}`,i=1===n?"source":`vec2(${s.slice(-2).join()})`,l=[`${P} rc = outputLoc;`,`${u[n-1]} += 1;\n       if(${v}) {\n      `,1===n?"":`}\n       rc = outputLoc;\n       ${u[n-2]} += 1;\n       if(${u[n-2]} < ${this.outputShape[n-2]}) {`,1===n?"":`  ${u[n-1]} += 1;\n         if(${v}) {`],c=1===n?"rc < start || rc >= end":"any(lessThan(rc, start)) || any(greaterThanEqual(rc, end))";let O="";for(let e=0,t=1===n?2:4;e<t;e++)O+=`\n        ${l[e]}\n        if (${c}) {\n          result[${e}] = float(value);\n        } else {\n          ${P} source = rc - start;\n          result[${e}] = getChannel(getX(${s.join()}), ${i});\n        }\n      `;O+=1===n?"} ":"}}",this.userCode=`\n      const ${P} start = ${P}(${a});\n      const ${P} end = ${P}(${o});\n\n      void main() {\n        ${P} outputLoc = getOutputCoords();\n        vec4 result = vec4(0.);\n        ${O}\n        setOutput(result);\n      }\n    `}}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class df{constructor(e,t){this.outputShape=[],this.customUniforms=[{name:"value",type:"float"}],this.variableNames=["x"],this.outputShape=e,this.userCode="\n      void main() {\n        // Input can be obtained from uniform value.\n        setOutput(value);\n      }\n    "}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function yf(e){const{backend:t,attrs:r}=e,{shape:n,value:P}=r;let{dtype:a}=r;if(a=a||tt(P),"string"===a){const e=Fe(a,Ee(n));return e.fill(P),t.makeTensorInfo(n,a,e)}{const e=new df(n,P),r=[[P]];return t.runWebGLProgram(e,[],a,r)}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const wf=e=>{const{inputs:t,backend:r,attrs:n}=e,{x:P}=t,{paddings:a,constantValue:o}=n;if(0===Ee(P.shape)){const e=a.map(((e,t)=>e[0]+P.shape[t]+e[1]));return yf({backend:r,attrs:{shape:e,value:o,dtype:P.dtype}})}const u=mt().getBool("WEBGL_PACK_ARRAY_OPERATIONS")?new zf(P.shape,a,o):new Tf(P.shape,a,o),s=[[o]];return r.runWebGLProgram(u,[P],P.dtype,s)},Lf={kernelName:jn,backendName:"webgl",kernelFunc:wf};
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
class ff{constructor(e){this.variableNames=["source"],this.outputShape=e,this.rank=e.length;const t=sd(this.rank);this.customUniforms=[{name:"start",arrayIndex:this.rank,type:"int"}];const r=Sf(this.rank);let n;const P=e.map(((e,t)=>`sourceLoc.${If[t]} = start[${t}] + coords.${If[t]};`));n=`\n        ${t} sourceLoc;\n        ${t} coords = getOutputCoords();\n        ${P.join("\n")}\n      `,this.userCode=`\n      void main() {\n        ${n}\n        setOutput(getSource(${r}));\n      }\n    `}}const If=["x","y","z","w","u","v"];function Sf(e){if(1===e)return"sourceLoc";if(e<=6)return If.slice(0,e).map((e=>"sourceLoc."+e)).join(",");throw Error(`Slicing for rank ${e} is not yet supported`)}
/**
     * @license
     * Copyright 2019 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class Af{constructor(e){this.variableNames=["source"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=e,this.rank=e.length,this.customUniforms=[{name:"start",arrayIndex:this.rank,type:"int"}];const t=sd(this.rank),r=Cw("coords",this.rank),n=Cw("sourceLoc",this.rank),P=1===this.rank?"sourceLoc":`vec2(${n.slice(-2).join()})`,a=`getChannel(getSource(${n.join()}), ${P})`,o=`\n      result.x = ${a};\n      if (++${r[this.rank-1]} < ${e[this.rank-1]}) {\n        ++${n[this.rank-1]};\n        result.y = ${a};\n        --${n[this.rank-1]};\n      }\n    `,u=1===this.rank?"":`\n      --${r[this.rank-1]};\n      if (++${r[this.rank-2]} < ${e[this.rank-2]}) {\n        ++${n[this.rank-2]};\n        result.z = ${a};\n        if (++${r[this.rank-1]} < ${e[this.rank-1]}) {\n          ++${n[this.rank-1]};\n          result.w = ${a};\n        }\n      }\n    `,s=this.rank<=4?`sourceLoc = coords +\n            ${t}(${e.map(((e,t)=>`start[${t}]`)).join()});`:e.map(((e,t)=>`${n[t]} = ${r[t]} + start[${t}];`)).join("\n");this.userCode=`\n      void main() {\n        ${t} coords = getOutputCoords();\n        ${t} sourceLoc;\n        ${s}\n        vec4 result = vec4(0.);\n        ${o}\n        ${u}\n        setOutput(result);\n      }\n    `}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function xf(e,t,r,n){const P=n.texData.get(e.dataId),a=n.makeTensorInfo(r,e.dtype),o=n.texData.get(a.dataId);Object.assign(o,P),o.refCount=1,o.shape=r,o.dtype=e.dtype;let u=Ss(t,Pt(e.shape));P.slice&&(u+=P.slice.flatOffset),o.slice={flatOffset:u,origDataId:P.slice&&P.slice.origDataId||e.dataId};const s=n.dataRefCount.get(o.slice.origDataId)||1;return n.dataRefCount.set(o.slice.origDataId,s+1),a}function Yf(e){const{inputs:t,backend:r,attrs:n}=e,{x:P}=t,{begin:a,size:o}=n,[u,s]=As(P,a,o);if(hs(P,u,s),0===Ee(s))return r.makeTensorInfo(s,P.dtype,[]);if(r.shouldExecuteOnCPU([P])||"string"===P.dtype){const e=r.texData.get(P.dataId),t=gw(e.values,u,s,P.shape,P.dtype);return r.makeTensorInfo(s,P.dtype,t)}const{isPacked:v}=r.texData.get(P.dataId),i=Is(P.shape,u,s);if(v||!i){const e=mt().getBool("WEBGL_PACK_ARRAY_OPERATIONS")?new Af(s):new ff(s),t=[u];return r.runWebGLProgram(e,[P],P.dtype,t)}return r.uploadToGPU(P.dataId),xf(P,u,s,r)}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function kf(e){const{inputs:t,backend:r,attrs:n}=e,{value:P}=t;let{axis:a}=n;a<0&&(a+=P.shape.length);const o=P,u=o.shape.length,s=P.shape[a],v=new Array(u-1);let i=0;for(let e=0;e<u;e++)e!==a&&(v[i++]=o.shape[e]);const l=[],c=new Array(u).fill(0),O=o.shape.slice();O[a]=1;const D=new Array(s);for(let e=0;e<D.length;e++){c[a]=e;const t=Yf({inputs:{x:o},backend:r,attrs:{begin:c,size:O}}),n=qL({inputs:{x:t},backend:r,attrs:{shape:v}});D[e]=n,l.push(t)}return l.forEach((e=>r.disposeIntermediateTensorInfo(e))),D}const Cf={kernelName:vP,backendName:"webgl",kernelFunc:kf},Ef=IL({opSnippet:"return float(!isnan(x) && !isinf(x));",dtype:"bool"}),Qf={kernelName:Er,backendName:"webgl",kernelFunc:Ef};
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
class Wf{constructor(e,t,r){let n,P;if(this.variableNames=["c","a","b"],this.outputShape=t,r>4)throw Error(`Where for rank ${r} is not yet supported`);if(1===r)P="resRC",n="resRC";else{const r=["resRC.x","resRC.y","resRC.z","resRC.w"],a=[],o=[];for(let n=0;n<t.length;n++)o.push(`${r[n]}`),n<e&&a.push(`${r[n]}`);n=a.join(),P=o.join()}const a=sd(r);this.userCode=`\n      void main() {\n        ${a} resRC = getOutputCoords();\n        float cVal = getC(${n});\n        if (cVal >= 1.0) {\n          setOutput(getA(${P}));\n        } else {\n          setOutput(getB(${P}));\n        }\n      }\n    `}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Uf(e){const{inputs:t,backend:r}=e,{condition:n,t:P,e:a}=t,o=new Wf(n.shape.length,P.shape,P.shape.length);return r.runWebGLProgram(o,[n,P,a],La(P.dtype,a.dtype))}const qf={kernelName:Yn,backendName:"webgl",kernelFunc:Uf},Gf={REAL:"return areal * breal - aimag * bimag;",IMAG:"return areal * bimag + aimag * breal;"};
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class Mf{constructor(e,t,r){this.variableNames=["AReal","AImag","BReal","BImag"],this.outputShape=os(t,r),this.userCode=`\n      float binaryOpComplex(\n          float areal, float aimag, float breal, float bimag) {\n        ${e}\n      }\n\n      void main() {\n        float areal = getARealAtOutCoords();\n        float aimag = getAImagAtOutCoords();\n        float breal = getBRealAtOutCoords();\n        float bimag = getBImagAtOutCoords();\n        setOutput(binaryOpComplex(areal, aimag, breal, bimag));\n      }\n    `}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Kf="return a * b;";function Nf(e){const{inputs:t,backend:r}=e,{a:n,b:P}=t,a=La(n.dtype,P.dtype);if("complex64"===n.dtype){const e=r.texData.get(n.dataId),t=r.texData.get(P.dataId),a=new Mf(Gf.REAL,n.shape,P.shape),o=new Mf(Gf.IMAG,n.shape,P.shape),u=[{dataId:e.complexTensorInfos.real.dataId,dtype:e.complexTensorInfos.real.dtype,shape:n.shape},{dataId:e.complexTensorInfos.imag.dataId,dtype:e.complexTensorInfos.imag.dtype,shape:n.shape},{dataId:t.complexTensorInfos.real.dataId,dtype:t.complexTensorInfos.real.dtype,shape:P.shape},{dataId:t.complexTensorInfos.imag.dataId,dtype:t.complexTensorInfos.imag.dtype,shape:P.shape}],s=r.runWebGLProgram(a,u,"float32"),v=r.runWebGLProgram(o,u,"float32"),i=zL({inputs:{real:s,imag:v},backend:r});return r.disposeIntermediateTensorInfo(s),r.disposeIntermediateTensorInfo(v),i}if(r.shouldExecuteOnCPU([n,P])){const e=r.texData.get(n.dataId),t=r.texData.get(P.dataId),[o,u]=iw(n.shape,P.shape,e.values,t.values,a),s=r.makeTensorInfo(u,a);return r.texData.get(s.dataId).values=o,s}let o;return o=mt().getBool("WEBGL_PACK_BINARY_OPERATIONS")?new gL(Kf,n.shape,P.shape):new pL(Kf,n.shape,P.shape),r.runWebGLProgram(o,[n,P],a)}const Rf={kernelName:an,backendName:"webgl",kernelFunc:Nf};
/**
     * @license
     * Copyright 2018 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class Ff{constructor(e,t,r,n=!1,P=!1,a=!1,o=null,u=!1,s=!1){this.variableNames=["matrixA","matrixB"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=r,this.enableShapeUniforms=pd(this.outputShape.length);const v=n?e[1]:e[2],i=Math.ceil(v/2),l=n?"i * 2, rc.y":"rc.y, i * 2",c=P?"rc.z, i * 2":"i * 2, rc.z",O=n?["a.xxyy","a.zzww"]:["a.xxzz","a.yyww"],D=P?["b.xzxz","b.ywyw"]:["b.xyxy","b.zwzw"];let j="",h="";o&&(j=u?`vec4 activation(vec4 a) {\n          vec4 b = getPreluActivationWeightsAtOutCoords();\n          ${o}\n        }`:s?`vec4 activation(vec4 a) {\n          vec4 b = getLeakyreluAlphaAtOutCoords();\n          ${o}\n        }`:`vec4 activation(vec4 x) {\n          ${o}\n        }`,h="result = activation(result);");const p=a?"result += getBiasAtOutCoords();":"";a&&this.variableNames.push("bias"),u&&this.variableNames.push("preluActivationWeights"),s&&this.variableNames.push("leakyreluAlpha");let m="rc.x",g="rc.x";e[0]<t[0]?m=`int(min(float(rc.x), ${e[0]-1}.))`:t[0]<e[0]&&(g=`int(min(float(rc.x), ${t[0]-1}.))`),this.userCode=`\n      ${j}\n      // Don't use uniform for sharedDimensionPacked for performance.\n      const float sharedDimension = ${i}.0;\n\n      vec4 dot2x2ARowBCol(ivec3 rc) {\n        vec4 result = vec4(0);\n        for (int i = 0; i < ${i}; i++) {\n          int batchA = ${m};\n          int batchB = ${g};\n          vec4 a = getMatrixA(batchA, ${l});\n          vec4 b = getMatrixB(batchB, ${c});\n\n          // These swizzled products need to be separately added.\n          // See: https://github.com/tensorflow/tfjs/issues/1735\n          result += (${O[0]} * ${D[0]});\n          result += (${O[1]} * ${D[1]});\n        }\n        return result;\n      }\n\n      void main() {\n        ivec3 rc = getOutputCoords();\n        vec4 result = dot2x2ARowBCol(rc);\n\n        ${p}\n\n        ${h}\n\n        setOutput(result);\n      }\n    `}}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */const Bf=1e3;function Zf({a:e,b:t,transposeA:r,transposeB:n,backend:P,bias:a=null,preluActivationWeights:o=null,leakyreluAlpha:u=0,activation:s=null}){const v=e.shape.length,i=t.shape.length,l=r?e.shape[v-2]:e.shape[v-1],c=n?t.shape[i-1]:t.shape[i-2],O=r?e.shape[v-1]:e.shape[v-2],D=n?t.shape[i-2]:t.shape[i-1],j=e.shape.slice(0,-2),h=t.shape.slice(0,-2),p=Ee(j),m=Ee(h),g=os(e.shape.slice(0,-2),t.shape.slice(0,-2)).concat([O,D]);xe(l===c,(()=>`Error in matMul: inner shapes (${l}) and (${c}) of Tensors with shapes ${e.shape} and ${t.shape} and transposeA=${r} and transposeB=${n} must match.`));const b=r?[p,l,O]:[p,O,l],T=n?[m,D,c]:[m,c,D],z=qL({inputs:{x:e},backend:P,attrs:{shape:b}}),d=qL({inputs:{x:t},backend:P,attrs:{shape:T}}),y=[z,d],w=Math.max(p,m),L=r?z.shape[1]:z.shape[2],f=null!=a,I=null!=o,S="leakyrelu"===s,A=null!=s?AL(s,!0):null;let x;if((1===O||1===D)&&L>Bf&&!1===(f||I||S||null!=A)){let e=z,t=d;r&&(e=mf({inputs:{x:z},backend:P,attrs:{perm:[0,2,1]}}),y.push(e)),n&&(t=mf({inputs:{x:d},backend:P,attrs:{perm:[0,2,1]}}),y.push(t));const a=1===D;let o=e;1!==D&&(o=qL({inputs:{x:e},backend:P,attrs:{shape:[w,L,1]}}),y.push(o));const u=1===D?2:1;let s=t;a&&(s=qL({inputs:{x:t},backend:P,attrs:{shape:[w,1,L]}}),y.push(s));const v=Nf({inputs:{a:o,b:s},backend:P});x=BL({inputs:{x:v},backend:P,attrs:{axis:u,keepDims:!0}}),y.push(v)}else{const s=La(e.dtype,t.dtype),v=new Ff(b,T,[w,O,D],r,n,f,A,I,S),i=[z,d];if(null!=a&&i.push(a),I&&i.push(o),S){const e=P.makeTensorInfo([],"float32",JP(u,"float32"));i.push(e),y.push(e)}x=P.runWebGLProgram(v,i,s)}const Y=qL({inputs:{x:x},backend:P,attrs:{shape:g}});y.push(x);for(const e of y)P.disposeIntermediateTensorInfo(e);return Y}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function Vf(e){const{inputs:t,backend:r,attrs:n}=e,{a:P,b:a}=t,{transposeA:o,transposeB:u}=n;return Zf({a:P,b:a,transposeA:o,transposeB:u,backend:r})}const Xf={kernelName:Mt,backendName:"webgl",kernelFunc:Vf};
/**
     * @license
     * Copyright 2017 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */class Hf{constructor(e,t){this.variableNames=["A","indices"],this.outputShape=t,this.rank=t.length;const r=sd(this.rank),n=Jf(e);this.userCode=`\n      void main() {\n        ${r} resRC = getOutputCoords();\n        int index = int(getIndices(resRC.x, resRC.z));\n        float inBounds = (index >= 0) && (index < ${e[2]}) ? 1.0 : 0.0;\n        setOutput(inBounds * getA(${n}));\n      }\n    `}}function Jf(e,t){const r=["resRC.x","resRC.y","resRC.z","resRC.w"],n=[];for(let t=0;t<e.length;t++)2===t?n.push("index"):n.push(`${r[t]}`);return n.join()}
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */function _f(e){const{inputs:t,backend:r,attrs:n}=e,{x:P,indices:a}=t,{axis:o,batchDims:u}=n,s=Ke(o,P.shape)[0];if(mt().get("DEBUG")){const e=r.readSync(a.dataId),t=P.shape[s];for(let r=0;r<e.length;++r){const n=e[r];xe(n<=t-1&&n>=0,(()=>`GatherV2: the index value ${n} is not in [0, ${t-1}]`))}}const v=hg(P,a,s,u),i=Ee(a.shape),l=[],c=qL({inputs:{x:P},backend:r,attrs:{shape:[v.batchSize,v.outerSize,v.dimSize,v.sliceSize]}}),O=qL({inputs:{x:a},backend:r,attrs:{shape:[v.batchSize,i/v.batchSize]}});l.push(c),l.push(O);const D=[v.batchSize,v.outerSize,i/v.batchSize,v.sliceSize];if(r.shouldExecuteOnCPU([P,a])||"string"===P.dtype){const e=r.bufferSync(O),t=r.bufferSync(c),n=ew(t,e,D);return l.forEach((e=>r.disposeIntermediateTensorInfo(e))),r.makeTensorInfo(v.outputShape,n.dtype,n.values)}const j=new Hf(c.shape,D),h=r.runWebGLProgram(j,[c,O],c.dtype);l.push(h);const p=qL({inputs:{x:h},backend:r,attrs:{shape:v.outputShape}});return l.forEach((e=>r.disposeIntermediateTensorInfo(e))),p}const $f={kernelName:Ir,backendName:"webgl",kernelFunc:_f},eI=IL({opSnippet:fL+"\n  return 1.0 / (1.0 + exp(-1.0 * x));\n",packedOpSnippet:"\n  vec4 result = 1.0 / (1.0 + exp(-1.0 * x));\n  bvec4 isNaN = isnan(x);\n\n  result.r = isNaN.r ? x.r : result.r;\n  result.g = isNaN.g ? x.g : result.g;\n  result.b = isNaN.b ? x.b : result.b;\n  result.a = isNaN.a ? x.a : result.a;\n\n  return result;\n",cpuKernelImpl:pw}),tI={kernelName:Un,backendName:"webgl",kernelFunc:eI};
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the "License");
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an "AS IS" BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
/**
     * @license
     * Copyright 2020 Google LLC. All Rights Reserved.
     * Licensed under the Apache License, Version 2.0 (the License);
     * you may not use this file except in compliance with the License.
     * You may obtain a copy of the License at
     *
     * http://www.apache.org/licenses/LICENSE-2.0
     *
     * Unless required by applicable law or agreed to in writing, software
     * distributed under the License is distributed on an AS IS BASIS,
     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     * See the License for the specific language governing permissions and
     * limitations under the License.
     * =============================================================================
     */
function rI(e){const{inputs:t,backend:r,attrs:n}=e,{a:P,b:a,bias:o,preluActivationWeights:u}=t,{transposeA:s,transposeB:v,activation:i,leakyreluAlpha:l}=n;return Zf({a:P,b:a,transposeA:s,transposeB:v,backend:r,bias:o,preluActivationWeights:u,leakyreluAlpha:l,activation:i})}const nI={kernelName:jP,backendName:"webgl",kernelFunc:rI};for(let vI of[kL,ZL,XL,uf,Of,jf,pf,bf,Lf,Cf,GL,Qf,TL,qf,Rf,Xf,$f,Pf,tI,nI])wP(vI);var me=Object.freeze({__proto__:null,cast:uu,enableProdMode:Nu,eye:tc,isFinite:cc,loadGraphModel:PT,oneHot:Ku,pow:kl,stack:Dj,sum:Gl,tensor:$a,tidy:Fu,unstack:Ej,zeros:iO}),ge={format:"graph-model",generatedBy:"2.2.0",convertedBy:"TensorFlow.js Converter v3.6.0",signature:{inputs:{"adjacency:0":{name:"adjacency:0",dtype:"DT_FLOAT",tensorShape:{dim:[{size:"-1"},{size:"50"},{size:"50"}]}},"features:0":{name:"features:0",dtype:"DT_FLOAT",tensorShape:{dim:[{size:"-1"},{size:"50"},{size:"638"}]}}},outputs:{"Identity:0":{name:"Identity:0",dtype:"DT_FLOAT",tensorShape:{dim:[{size:"-1"},{size:"2"}]}}}},modelTopology:{node:[{name:"adjacency",op:"Placeholder",attr:{shape:{shape:{dim:[{size:"-1"},{size:"50"},{size:"50"}]}},dtype:{type:"DT_FLOAT"}}},{name:"features",op:"Placeholder",attr:{shape:{shape:{dim:[{size:"-1"},{size:"50"},{size:"638"}]}},dtype:{type:"DT_FLOAT"}}},{name:"Func/StatefulPartitionedCall/input_control_node/_0",op:"NoOp",input:["^adjacency","^features"]},{name:"Func/StatefulPartitionedCall/input/_17",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"64"},{size:"64"}]}}},dtype:{type:"DT_FLOAT"}}},{name:"Func/StatefulPartitionedCall/input/_18",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"64"}]}}},dtype:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/axes",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_INT32",tensorShape:{dim:[{size:"1"}]}}},dtype:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Const",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_INT32",tensorShape:{dim:[{size:"1"}]}}},dtype:{type:"DT_INT32"}}},{name:"Func/StatefulPartitionedCall/input/_15",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{dtype:{type:"DT_FLOAT"},value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"64"},{size:"64"}]}}}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_1",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{dtype:{type:"DT_FLOAT"},value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"64"},{size:"64"}]}}}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_4",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"64"},{size:"64"}]}}},dtype:{type:"DT_FLOAT"}}},{name:"Func/StatefulPartitionedCall/input/_11",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{dtype:{type:"DT_FLOAT"},value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"64"}]}}}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_7",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{dtype:{type:"DT_FLOAT"},value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"64"},{size:"64"}]}}}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape/shape",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_INT32",tensorShape:{dim:[{size:"2"}]}}},dtype:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_10",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"64"},{size:"64"}]}}},dtype:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/Reshape_1",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"638"},{size:"64"}]}}},dtype:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/Reshape_4",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"638"},{size:"64"}]}}},dtype:{type:"DT_FLOAT"}}},{name:"Func/StatefulPartitionedCall/input/_5",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"64"}]}}},dtype:{type:"DT_FLOAT"}}},{name:"Func/StatefulPartitionedCall/input/_1",op:"Identity",input:["adjacency","^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/Reshape_7",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{dtype:{type:"DT_FLOAT"},value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"638"},{size:"64"}]}}}}},{name:"StatefulPartitionedCall/model/arma_conv/Reshape/shape",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{dtype:{type:"DT_INT32"},value:{tensor:{dtype:"DT_INT32",tensorShape:{dim:[{size:"2"}]}}}}},{name:"StatefulPartitionedCall/model/arma_conv/Reshape_10",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{dtype:{type:"DT_FLOAT"},value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"638"},{size:"64"}]}}}}},{name:"StatefulPartitionedCall/model/arma_conv/Shape",op:"Shape",input:["features","^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{T:{type:"DT_FLOAT"},out_type:{type:"DT_INT32"}}},{name:"Func/StatefulPartitionedCall/input/_8",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"64"}]}}},dtype:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_2/shape/1",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{dtype:{type:"DT_INT32"},value:{tensor:{dtype:"DT_INT32",tensorShape:{}}}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_2/shape/2",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_INT32",tensorShape:{}}},dtype:{type:"DT_INT32"}}},{name:"Func/StatefulPartitionedCall/input/_14",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"64"}]}}},dtype:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/Mean/reduction_indices",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_INT32",tensorShape:{}}},dtype:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/free",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_INT32",tensorShape:{dim:[{size:"2"}]}}},dtype:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Const_2",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{dtype:{type:"DT_INT32"},value:{tensor:{dtype:"DT_INT32",tensorShape:{dim:[{size:"1"}]}}}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/concat/axis",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{dtype:{type:"DT_INT32"},value:{tensor:{dtype:"DT_INT32",tensorShape:{}}}}},{name:"Func/StatefulPartitionedCall/input/_16",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"64"}]}}},dtype:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/Sum/reduction_indices",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_INT32",tensorShape:{}}},dtype:{type:"DT_INT32"}}},{name:"Func/StatefulPartitionedCall/input/_19",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{dtype:{type:"DT_FLOAT"},value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"64"},{size:"128"}]}}}}},{name:"Func/StatefulPartitionedCall/input/_20",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"128"}]}}},dtype:{type:"DT_FLOAT"}}},{name:"Func/StatefulPartitionedCall/input/_21",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{dtype:{type:"DT_FLOAT"},value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"128"},{size:"2"}]}}}}},{name:"Func/StatefulPartitionedCall/input/_22",op:"Const",input:["^Func/StatefulPartitionedCall/input_control_node/_0"],attr:{dtype:{type:"DT_FLOAT"},value:{tensor:{dtype:"DT_FLOAT",tensorShape:{dim:[{size:"2"}]}}}}},{name:"StatefulPartitionedCall/model/arma_conv/Reshape",op:"Reshape",input:["features","StatefulPartitionedCall/model/arma_conv/Reshape/shape"],attr:{T:{type:"DT_FLOAT"},Tshape:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/arma_conv/unstack",op:"Unpack",input:["StatefulPartitionedCall/model/arma_conv/Shape"],attr:{num:{i:"3"},T:{type:"DT_INT32"},axis:{i:"0"}}},{name:"StatefulPartitionedCall/model/arma_conv/MatMul",op:"MatMul",input:["StatefulPartitionedCall/model/arma_conv/Reshape","StatefulPartitionedCall/model/arma_conv/Reshape_1"],device:"/device:CPU:0",attr:{transpose_a:{b:!1},transpose_b:{b:!1},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/MatMul_2",op:"MatMul",input:["StatefulPartitionedCall/model/arma_conv/Reshape","StatefulPartitionedCall/model/arma_conv/Reshape_4"],device:"/device:CPU:0",attr:{T:{type:"DT_FLOAT"},transpose_b:{b:!1},transpose_a:{b:!1}}},{name:"StatefulPartitionedCall/model/arma_conv/MatMul_3",op:"MatMul",input:["StatefulPartitionedCall/model/arma_conv/Reshape","StatefulPartitionedCall/model/arma_conv/Reshape_7"],device:"/device:CPU:0",attr:{transpose_b:{b:!1},transpose_a:{b:!1},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/MatMul_5",op:"MatMul",input:["StatefulPartitionedCall/model/arma_conv/Reshape","StatefulPartitionedCall/model/arma_conv/Reshape_10"],device:"/device:CPU:0",attr:{transpose_a:{b:!1},transpose_b:{b:!1},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/Reshape_2/shape",op:"Pack",input:["StatefulPartitionedCall/model/arma_conv/unstack","StatefulPartitionedCall/model/arma_conv_1/Reshape_2/shape/1","StatefulPartitionedCall/model/arma_conv_1/Reshape_2/shape/2"],attr:{T:{type:"DT_INT32"},N:{i:"3"},axis:{i:"0"}}},{name:"StatefulPartitionedCall/model/arma_conv/Reshape_2",op:"Reshape",input:["StatefulPartitionedCall/model/arma_conv/MatMul","StatefulPartitionedCall/model/arma_conv/Reshape_2/shape"],attr:{Tshape:{type:"DT_INT32"},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/Reshape_5",op:"Reshape",input:["StatefulPartitionedCall/model/arma_conv/MatMul_2","StatefulPartitionedCall/model/arma_conv/Reshape_2/shape"],attr:{T:{type:"DT_FLOAT"},Tshape:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/arma_conv/Reshape_8",op:"Reshape",input:["StatefulPartitionedCall/model/arma_conv/MatMul_3","StatefulPartitionedCall/model/arma_conv/Reshape_2/shape"],attr:{T:{type:"DT_FLOAT"},Tshape:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/arma_conv/Reshape_11",op:"Reshape",input:["StatefulPartitionedCall/model/arma_conv/MatMul_5","StatefulPartitionedCall/model/arma_conv/Reshape_2/shape"],attr:{T:{type:"DT_FLOAT"},Tshape:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/arma_conv/MatMul_1",op:"BatchMatMulV2",input:["Func/StatefulPartitionedCall/input/_1","StatefulPartitionedCall/model/arma_conv/Reshape_2"],attr:{adj_x:{b:!1},adj_y:{b:!1},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/MatMul_4",op:"BatchMatMulV2",input:["Func/StatefulPartitionedCall/input/_1","StatefulPartitionedCall/model/arma_conv/Reshape_8"],attr:{adj_x:{b:!1},adj_y:{b:!1},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/add",op:"AddV2",input:["StatefulPartitionedCall/model/arma_conv/MatMul_1","StatefulPartitionedCall/model/arma_conv/Reshape_5"],attr:{T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/add_1",op:"AddV2",input:["StatefulPartitionedCall/model/arma_conv/MatMul_4","StatefulPartitionedCall/model/arma_conv/Reshape_11"],attr:{T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/BiasAdd",op:"BiasAdd",input:["StatefulPartitionedCall/model/arma_conv/add","Func/StatefulPartitionedCall/input/_5"],attr:{T:{type:"DT_FLOAT"},data_format:{s:"TkhXQw=="}}},{name:"StatefulPartitionedCall/model/arma_conv/BiasAdd_1",op:"BiasAdd",input:["StatefulPartitionedCall/model/arma_conv/add_1","Func/StatefulPartitionedCall/input/_8"],attr:{data_format:{s:"TkhXQw=="},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/Relu",op:"Relu",input:["StatefulPartitionedCall/model/arma_conv/BiasAdd"],attr:{T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/Relu_1",op:"Relu",input:["StatefulPartitionedCall/model/arma_conv/BiasAdd_1"],attr:{T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv/stack",op:"Pack",input:["StatefulPartitionedCall/model/arma_conv/Relu","StatefulPartitionedCall/model/arma_conv/Relu_1"],attr:{T:{type:"DT_FLOAT"},N:{i:"2"},axis:{i:"-1"}}},{name:"StatefulPartitionedCall/model/arma_conv/Mean",op:"Mean",input:["StatefulPartitionedCall/model/arma_conv/stack","StatefulPartitionedCall/model/arma_conv/Mean/reduction_indices"],attr:{T:{type:"DT_FLOAT"},keep_dims:{b:!1},Tidx:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/arma_conv/Relu_2",op:"Relu",input:["StatefulPartitionedCall/model/arma_conv/Mean"],attr:{T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape",op:"Reshape",input:["StatefulPartitionedCall/model/arma_conv/Relu_2","StatefulPartitionedCall/model/arma_conv_1/Reshape/shape"],attr:{Tshape:{type:"DT_INT32"},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Shape",op:"Shape",input:["StatefulPartitionedCall/model/arma_conv/Relu_2"],attr:{T:{type:"DT_FLOAT"},out_type:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/MatMul",op:"MatMul",input:["StatefulPartitionedCall/model/arma_conv_1/Reshape","StatefulPartitionedCall/model/arma_conv_1/Reshape_1"],device:"/device:CPU:0",attr:{T:{type:"DT_FLOAT"},transpose_b:{b:!1},transpose_a:{b:!1}}},{name:"StatefulPartitionedCall/model/arma_conv_1/MatMul_2",op:"MatMul",input:["StatefulPartitionedCall/model/arma_conv_1/Reshape","StatefulPartitionedCall/model/arma_conv_1/Reshape_4"],device:"/device:CPU:0",attr:{transpose_b:{b:!1},transpose_a:{b:!1},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/MatMul_3",op:"MatMul",input:["StatefulPartitionedCall/model/arma_conv_1/Reshape","StatefulPartitionedCall/model/arma_conv_1/Reshape_7"],device:"/device:CPU:0",attr:{T:{type:"DT_FLOAT"},transpose_a:{b:!1},transpose_b:{b:!1}}},{name:"StatefulPartitionedCall/model/arma_conv_1/MatMul_5",op:"MatMul",input:["StatefulPartitionedCall/model/arma_conv_1/Reshape","StatefulPartitionedCall/model/arma_conv_1/Reshape_10"],device:"/device:CPU:0",attr:{T:{type:"DT_FLOAT"},transpose_b:{b:!1},transpose_a:{b:!1}}},{name:"StatefulPartitionedCall/model/arma_conv_1/unstack",op:"Unpack",input:["StatefulPartitionedCall/model/arma_conv_1/Shape"],attr:{T:{type:"DT_INT32"},axis:{i:"0"},num:{i:"3"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_2/shape",op:"Pack",input:["StatefulPartitionedCall/model/arma_conv_1/unstack","StatefulPartitionedCall/model/arma_conv_1/Reshape_2/shape/1","StatefulPartitionedCall/model/arma_conv_1/Reshape_2/shape/2"],attr:{axis:{i:"0"},N:{i:"3"},T:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_2",op:"Reshape",input:["StatefulPartitionedCall/model/arma_conv_1/MatMul","StatefulPartitionedCall/model/arma_conv_1/Reshape_2/shape"],attr:{T:{type:"DT_FLOAT"},Tshape:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_5",op:"Reshape",input:["StatefulPartitionedCall/model/arma_conv_1/MatMul_2","StatefulPartitionedCall/model/arma_conv_1/Reshape_2/shape"],attr:{Tshape:{type:"DT_INT32"},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_8",op:"Reshape",input:["StatefulPartitionedCall/model/arma_conv_1/MatMul_3","StatefulPartitionedCall/model/arma_conv_1/Reshape_2/shape"],attr:{T:{type:"DT_FLOAT"},Tshape:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_11",op:"Reshape",input:["StatefulPartitionedCall/model/arma_conv_1/MatMul_5","StatefulPartitionedCall/model/arma_conv_1/Reshape_2/shape"],attr:{T:{type:"DT_FLOAT"},Tshape:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/MatMul_1",op:"BatchMatMulV2",input:["Func/StatefulPartitionedCall/input/_1","StatefulPartitionedCall/model/arma_conv_1/Reshape_2"],attr:{adj_x:{b:!1},adj_y:{b:!1},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/MatMul_4",op:"BatchMatMulV2",input:["Func/StatefulPartitionedCall/input/_1","StatefulPartitionedCall/model/arma_conv_1/Reshape_8"],attr:{T:{type:"DT_FLOAT"},adj_x:{b:!1},adj_y:{b:!1}}},{name:"StatefulPartitionedCall/model/arma_conv_1/add",op:"AddV2",input:["StatefulPartitionedCall/model/arma_conv_1/MatMul_1","StatefulPartitionedCall/model/arma_conv_1/Reshape_5"],attr:{T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/add_1",op:"AddV2",input:["StatefulPartitionedCall/model/arma_conv_1/MatMul_4","StatefulPartitionedCall/model/arma_conv_1/Reshape_11"],attr:{T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/BiasAdd",op:"BiasAdd",input:["StatefulPartitionedCall/model/arma_conv_1/add","Func/StatefulPartitionedCall/input/_11"],attr:{data_format:{s:"TkhXQw=="},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/BiasAdd_1",op:"BiasAdd",input:["StatefulPartitionedCall/model/arma_conv_1/add_1","Func/StatefulPartitionedCall/input/_14"],attr:{data_format:{s:"TkhXQw=="},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Relu",op:"Relu",input:["StatefulPartitionedCall/model/arma_conv_1/BiasAdd"],attr:{T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Relu_1",op:"Relu",input:["StatefulPartitionedCall/model/arma_conv_1/BiasAdd_1"],attr:{T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/stack",op:"Pack",input:["StatefulPartitionedCall/model/arma_conv_1/Relu","StatefulPartitionedCall/model/arma_conv_1/Relu_1"],attr:{axis:{i:"-1"},N:{i:"2"},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Mean",op:"Mean",input:["StatefulPartitionedCall/model/arma_conv_1/stack","StatefulPartitionedCall/model/arma_conv/Mean/reduction_indices"],attr:{keep_dims:{b:!1},T:{type:"DT_FLOAT"},Tidx:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/arma_conv_1/Relu_2",op:"Relu",input:["StatefulPartitionedCall/model/arma_conv_1/Mean"],attr:{T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Shape",op:"Shape",input:["StatefulPartitionedCall/model/arma_conv_1/Relu_2"],attr:{T:{type:"DT_FLOAT"},out_type:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/GatherV2_1",op:"GatherV2",input:["StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Shape","StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/axes","StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/concat/axis"],attr:{Tparams:{type:"DT_INT32"},Tindices:{type:"DT_INT32"},batch_dims:{i:"0"},Taxis:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/GatherV2",op:"GatherV2",input:["StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Shape","StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/free","StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/concat/axis"],attr:{Tparams:{type:"DT_INT32"},batch_dims:{i:"0"},Taxis:{type:"DT_INT32"},Tindices:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Prod_1",op:"Prod",input:["StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/GatherV2_1","StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Const"],attr:{keep_dims:{b:!1},Tidx:{type:"DT_INT32"},T:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Prod",op:"Prod",input:["StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/GatherV2","StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Const"],attr:{T:{type:"DT_INT32"},keep_dims:{b:!1},Tidx:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/concat_1",op:"ConcatV2",input:["StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/GatherV2","StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Const_2","StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/concat/axis"],attr:{N:{i:"2"},T:{type:"DT_INT32"},Tidx:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/stack",op:"Pack",input:["StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Prod","StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Prod_1"],attr:{N:{i:"2"},axis:{i:"0"},T:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Reshape",op:"Reshape",input:["StatefulPartitionedCall/model/arma_conv_1/Relu_2","StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/stack"],attr:{Tshape:{type:"DT_INT32"},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/attn_layer/Tensordot/MatMul",op:"MatMul",input:["StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Reshape","Func/StatefulPartitionedCall/input/_17"],device:"/device:CPU:0",attr:{T:{type:"DT_FLOAT"},transpose_a:{b:!1},transpose_b:{b:!1}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/MatMul",op:"MatMul",input:["StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Reshape","Func/StatefulPartitionedCall/input/_15"],device:"/device:CPU:0",attr:{T:{type:"DT_FLOAT"},transpose_a:{b:!1},transpose_b:{b:!1}}},{name:"StatefulPartitionedCall/model/global_attention_pool/attn_layer/Tensordot",op:"Reshape",input:["StatefulPartitionedCall/model/global_attention_pool/attn_layer/Tensordot/MatMul","StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/concat_1"],attr:{T:{type:"DT_FLOAT"},Tshape:{type:"DT_INT32"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot",op:"Reshape",input:["StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/MatMul","StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/concat_1"],attr:{Tshape:{type:"DT_INT32"},T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/attn_layer/BiasAdd",op:"BiasAdd",input:["StatefulPartitionedCall/model/global_attention_pool/attn_layer/Tensordot","Func/StatefulPartitionedCall/input/_18"],attr:{T:{type:"DT_FLOAT"},data_format:{s:"TkhXQw=="}}},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/BiasAdd",op:"BiasAdd",input:["StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot","Func/StatefulPartitionedCall/input/_16"],attr:{T:{type:"DT_FLOAT"},data_format:{s:"TkhXQw=="}}},{name:"StatefulPartitionedCall/model/global_attention_pool/attn_layer/Sigmoid",op:"Sigmoid",input:["StatefulPartitionedCall/model/global_attention_pool/attn_layer/BiasAdd"],attr:{T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/mul",op:"Mul",input:["StatefulPartitionedCall/model/global_attention_pool/attn_layer/Sigmoid","StatefulPartitionedCall/model/global_attention_pool/features_layer/BiasAdd"],attr:{T:{type:"DT_FLOAT"}}},{name:"StatefulPartitionedCall/model/global_attention_pool/Sum",op:"Sum",input:["StatefulPartitionedCall/model/global_attention_pool/mul","StatefulPartitionedCall/model/global_attention_pool/Sum/reduction_indices"],attr:{T:{type:"DT_FLOAT"},Tidx:{type:"DT_INT32"},keep_dims:{b:!1}}},{name:"StatefulPartitionedCall/model/dense/Relu",op:"_FusedMatMul",input:["StatefulPartitionedCall/model/global_attention_pool/Sum","Func/StatefulPartitionedCall/input/_19","Func/StatefulPartitionedCall/input/_20"],device:"/device:CPU:0",attr:{T:{type:"DT_FLOAT"},transpose_b:{b:!1},num_args:{i:"1"},fused_ops:{list:{s:["Qmlhc0FkZA==","UmVsdQ=="]}},epsilon:{f:0},transpose_a:{b:!1}}},{name:"StatefulPartitionedCall/model/prediction/BiasAdd",op:"_FusedMatMul",input:["StatefulPartitionedCall/model/dense/Relu","Func/StatefulPartitionedCall/input/_21","Func/StatefulPartitionedCall/input/_22"],device:"/device:CPU:0",attr:{epsilon:{f:0},fused_ops:{list:{s:["Qmlhc0FkZA=="]}},transpose_b:{b:!1},T:{type:"DT_FLOAT"},num_args:{i:"1"},transpose_a:{b:!1}}},{name:"StatefulPartitionedCall/model/prediction/Sigmoid",op:"Sigmoid",input:["StatefulPartitionedCall/model/prediction/BiasAdd"],attr:{T:{type:"DT_FLOAT"}}},{name:"Identity",op:"Identity",input:["StatefulPartitionedCall/model/prediction/Sigmoid"],attr:{T:{type:"DT_FLOAT"}}}],library:{},versions:{producer:175}},weightsManifest:[{paths:["group1-shard1of1.dat"],weights:[{name:"Func/StatefulPartitionedCall/input/_17",shape:[64,64],dtype:"float32"},{name:"Func/StatefulPartitionedCall/input/_18",shape:[64],dtype:"float32"},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/axes",shape:[1],dtype:"int32"},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Const",shape:[1],dtype:"int32"},{name:"Func/StatefulPartitionedCall/input/_15",shape:[64,64],dtype:"float32"},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_1",shape:[64,64],dtype:"float32"},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_4",shape:[64,64],dtype:"float32"},{name:"Func/StatefulPartitionedCall/input/_11",shape:[64],dtype:"float32"},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_7",shape:[64,64],dtype:"float32"},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape/shape",shape:[2],dtype:"int32"},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_10",shape:[64,64],dtype:"float32"},{name:"StatefulPartitionedCall/model/arma_conv/Reshape_1",shape:[638,64],dtype:"float32"},{name:"StatefulPartitionedCall/model/arma_conv/Reshape_4",shape:[638,64],dtype:"float32"},{name:"Func/StatefulPartitionedCall/input/_5",shape:[64],dtype:"float32"},{name:"StatefulPartitionedCall/model/arma_conv/Reshape_7",shape:[638,64],dtype:"float32"},{name:"StatefulPartitionedCall/model/arma_conv/Reshape/shape",shape:[2],dtype:"int32"},{name:"StatefulPartitionedCall/model/arma_conv/Reshape_10",shape:[638,64],dtype:"float32"},{name:"Func/StatefulPartitionedCall/input/_8",shape:[64],dtype:"float32"},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_2/shape/1",shape:[],dtype:"int32"},{name:"StatefulPartitionedCall/model/arma_conv_1/Reshape_2/shape/2",shape:[],dtype:"int32"},{name:"Func/StatefulPartitionedCall/input/_14",shape:[64],dtype:"float32"},{name:"StatefulPartitionedCall/model/arma_conv/Mean/reduction_indices",shape:[],dtype:"int32"},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/free",shape:[2],dtype:"int32"},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/Const_2",shape:[1],dtype:"int32"},{name:"StatefulPartitionedCall/model/global_attention_pool/features_layer/Tensordot/concat/axis",shape:[],dtype:"int32"},{name:"Func/StatefulPartitionedCall/input/_16",shape:[64],dtype:"float32"},{name:"StatefulPartitionedCall/model/global_attention_pool/Sum/reduction_indices",shape:[],dtype:"int32"},{name:"Func/StatefulPartitionedCall/input/_19",shape:[64,128],dtype:"float32"},{name:"Func/StatefulPartitionedCall/input/_20",shape:[128],dtype:"float32"},{name:"Func/StatefulPartitionedCall/input/_21",shape:[128,2],dtype:"float32"},{name:"Func/StatefulPartitionedCall/input/_22",shape:[2],dtype:"float32"}]}]},be=Object.freeze({__proto__:null,hideIfGraphMatchesModel:ge,hideIfGraphMatchesWeights:" "});class PI{constructor(e,t=null,r={}){if(!e)throw new Error("tfjs must not be null.");this.settings={graphCutOff:50,threshold:.5,priorityNodeAttributes:["style"],displayAttributeMap:{none:1,inline:2,block:3,"inline-block":4,inherit:5},oneHotDisplayLength:5,amountCssSelectors:55,cssColorAttributes:["background-color","border-bottom-color","border-left-color","border-right-color","border-top-color","color","outline-color","text-decoration","text-decoration-color","column-rule-color","-webkit-text-emphasis-color","-webkit-text-fill-color","-webkit-text-stroke-color","caret-color"],cssDimensionAttributes:["border-bottom-width","height","min-height","min-width","padding-bottom","padding-left","padding-right","padding-top","width"],cssOriginAttributes:["perspective-origin","transform-origin"],requestTypes:["script","subdocument","image","xmlhttprequest","font","document","stylesheet","other","ping","websocket","media","object"],urlChars:" abcdefghijklmnopqrstuvwxyz1234567890:;/?!=+.,()[]-`*_|~".split(""),...r},this.tfjs=e,this.model=t,this.settings.requestTypesDict={},this.wordIndex={},this.preprocessingMap=new Map([["cast",this.tfjs.cast],["stack",this.tfjs.stack],["unstack",this.tfjs.unstack],["oneHot",this.tfjs.oneHot],["localPooling",this.localPoolingMap.bind(this)],["padAdjacency",this.padTensorAdjacency.bind(this)],["padFeatures",this.padTensorFeatures.bind(this)]]);let n=this.tfjs.eye(this.settings.requestTypes.length);for(let e in this.settings.requestTypes)this.settings.requestTypesDict[this.settings.requestTypes[e]]=n[e];let P=1;this.settings.urlChars.forEach((e=>{this.wordIndex[e]=P,P+=1}))}async inference(e){return new Promise(((t,r)=>{if(!this.initialized)return void r(new Error("Model is not initialized."));let n=this.processElement(e),P=[{data:[n.adjacencyMatrix],preprocess:[{funcName:"padAdjacency",args:this.settings.graphCutOff},{funcName:"unstack"},{funcName:"localPooling"},{funcName:"stack"}]},{data:[n.features],preprocess:[{funcName:"padFeatures",args:this.settings.graphCutOff},{funcName:"cast",args:"float32"}]}];this.predict(P).then((e=>{t(this.processPrediction(e))})).catch((e=>{r(e)}))}))}async loadModel(e){return this.tfjs.loadGraphModel(e).then((e=>{this.model&&this.model.dispose(),this.model=e}))}async loadRawModel(e,t){if(!e||!t)throw new Error("Model format not recognized.");return Array.isArray(t)||(t=[t]),this.tfjs.loadGraphModel({load:()=>{let r={modelTopology:e.modelTopology||{},signature:e.signature||{},weightsManifest:e.weightsManifest||[],weightSpecs:e.weightsManifest.map((e=>e.weights))[0]||[],weightData:this.concatWeights(t.map((e=>Uint8Array.from(atob(e),(e=>e.charCodeAt(0))))))||[]};return r}}).then((e=>{this.model&&this.model.dispose(),this.model=e}))}get initialized(){return!!this.model}concatWeights(e){let t=0;e.forEach((e=>{t+=e.byteLength}));let r=new Uint8Array(t),n=0;return e.forEach((e=>{r.set(new Uint8Array(e),n),n+=e.byteLength})),r.buffer}async predict(e){return new Promise(((t,r)=>{let n=this.preprocess(e),P=this.model.execute(n);P.data().then((e=>{t(e)})).catch((e=>{r(e)})).finally((()=>{P.dispose();for(let e of n)e.dispose()}))}))}processPrediction(e){if(!e)return;let t=Object.values(e);if(!t.some((e=>e>0)))throw new Error("Error: ML prediction results are corrupted");let r=t.reduce(((e,t)=>e+t),0);return t.map((e=>e/r)).filter(((e,t)=>t%2==1)).map((e=>e>this.settings.threshold))[0]}getNodeFeatures(e,t,r=!0,n=!1,P=!1,a=!1){let o=[];if(1==r){o.push(e.nodeId),o.push(e.parentNodeId),o.push(e.siblings),this.appendFeatures(o,this.getTagVec(e)),o.push(e.nodeLevel),o.push(e.numChildren);let t=e.hasOwnProperty("requestType")?e.requestType:null;null!==t&&(t=t.toLowerCase());let r=new Array(this.settings.requestTypes.length).fill(0);null!==t&&requestTypesDict.hasOwnProperty(t)&&(r=requestTypesDict[t]),this.appendFeatures(o,r)}if(1==n){let r=e.hasOwnProperty("attributes")?e.attributes:void 0,n="";null!=r&&r.hasOwnProperty("src")&&(n=r.src,n=n.trim().toLowerCase()),this.appendFeatures(o,this.getStringSeq(n,256)),this.appendFeatures(o,this.getMetaFeatures(e,t,"src"));let P="";null!=r&&r.hasOwnProperty("href")&&(P=r.href,P=P.trim().toLowerCase()),this.appendFeatures(o,this.getStringSeq(P,256)),this.appendFeatures(o,this.getMetaFeatures(e,t,"href"));let a="";null!=r&&r.hasOwnProperty("id")&&(a=r.id,a=a.trim().toLowerCase(),a=a.replace(/[!"'\(\)\*,\-\.\/:;\?\[\\\]\^_`\{\|\}~“” ]/g," ").replace(/\s+/g," ")),this.appendFeatures(o,this.getStringSeq(a,16));let u="";null!=r&&r.hasOwnProperty("class")&&(u=r.class,u=u.trim().toLowerCase(),u=u.replace(/[!"'\(\)\*,\-\.\/:;\?\[\\\]\^_`\{\|\}~“” ]/g," ").replace(/\s+/g," ")),this.appendFeatures(o,this.getStringSeq(u,16))}return 1==P&&this.appendFeatures(o,this.getStyleFeatures(e)),1==a&&this.appendFeatures(o,this.getCssFeatures(e)),o}appendFeatures(e,t){t.map((t=>e.push(t)))}getStringSeq(e,t){let r=[];return(e=e.split("")).forEach((e=>{r.push(this.wordIndex.hasOwnProperty(e)?this.wordIndex[e]:-1)})),r.length>t?r.slice(-t):(this.appendFeatures(r,new Array(t-r.length).fill(0)),r)}getTagVec(e,t=8){let r=e.tag.toLowerCase();return this.getStringSeq(r,t)}getMetaFeatures(e,t,r){let n=0,P=0,a=0,o=e.attributes;if(void 0!==o&&o.hasOwnProperty(r)){let e=o[r].toLowerCase();P=1,1==e.startsWith("http")&&(n=1),e.split("/")[2]!==t&&(a=1)}return[P,n,a]}getRgb(e){let t=/rgba?\((\d+), (\d+), (\d+)\)/g.exec(e);return t?[parseFloat(t[1]),parseFloat(t[2]),parseFloat(t[3])]:[0,0,0]}getPixels(e){let t=/(\d*?\.?\d*)px/g.exec(e);return t?[parseFloat(t[1])]:[0]}getOrigins(e){let t=/(\d*?\.?\d*)px (\d*?\.?\d*)px/g.exec(e);return t?[parseFloat(t[1]),parseFloat(t[2])]:[0,0]}getCssFeatures(e){let t=e.cssSelectors;if(!t)return new Array(this.settings.amountCssSelectors).fill(0);let r={},n=t.split("; ");for(let e in n){let t=n[e].split(":"),P=t[0],a=t[1];void 0!==P&&void 0!==a&&(r[P.trim()]=a.trim())}let P=[];for(let e in this.settings.cssColorAttributes){let t=r.hasOwnProperty(this.settings.cssColorAttributes[e])?this.getRgb(r[this.settings.cssColorAttributes[e]]):[0,0,0];this.appendFeatures(P,t)}for(let e in this.settings.cssDimensionAttributes){let t=r.hasOwnProperty(this.settings.cssDimensionAttributes[e])?this.getPixels(r[this.settings.cssDimensionAttributes[e]]):[0];this.appendFeatures(P,t)}for(let e in this.settings.cssOriginAttributes){let t=r.hasOwnProperty(this.settings.cssOriginAttributes[e])?this.getOrigins(r[this.settings.cssOriginAttributes[e]]):[0,0];this.appendFeatures(P,t)}return P}getStyleFeatures(e){let t=e.hasOwnProperty("attributes")?e.attributes:{},r=t.hasOwnProperty("style")?t.style:{},n=r.hasOwnProperty("offsetHeight")?r.offsetHeight:"0";n&&(n=parseFloat(n.trim()));let P=r.hasOwnProperty("offsetWidth")?r.offsetWidth:"0";P&&(P=parseFloat(P.trim()));let a=r.hasOwnProperty("display")?r.display:"-1";a&&a.trim().toLowerCase(),a=this.settings.displayAttributeMap.hasOwnProperty(a)?this.settings.displayAttributeMap[a]:0;let o=new Array(this.settings.oneHotDisplayLength).fill(0);a>0&&(o[a-1]=1);let u=[n,P];this.appendFeatures(u,o);let s=r.hasOwnProperty("font-size")?r["font-size"]:0;return s&&(s=parseFloat(s.trim().toLowerCase().replace("px",""))),u.push(s),u}processElement(e){let t=Array.from({length:this.settings.graphCutOff},(e=>new Array(this.settings.graphCutOff).fill(0))),r=[],n=0,P=(e,a)=>{if(n>=this.settings.graphCutOff)return;let o={};for(let t of e.attributes)o[t.name]=t.value;for(let t of this.settings.priorityNodeAttributes)o[t]={...e[t]};let u=new aI(e.tagName,o);u.cssSelectors=getComputedStyle(e).cssText,u.height=e.clientHeight,u.width=e.clientWidth,u.nodeId=n,n+=1,null!==a?(t[a.nodeId][u.nodeId]=1,t[u.nodeId][a.nodeId]=1,u.nodeLevel=a.nodeLevel+1,u.parentNodeId=a.nodeId,u.siblings=a.children.length):(u.nodeLevel=0,u.parentNodeId=0,u.siblings=0),u.numChildren=e.children.length,u.attributes.hasOwnProperty("src")&&void 0!==u.attributes.src?u.attributes.src_level=0:null!==a&&0!==Object.values(a.attributes).length&&a.attributes.hasOwnProperty("src")&&void 0!==a.attributes.src&&(u.attributes.src=a.attributes.src,u.attributes.src_level=a.attributes.src_level+1,u.requestType=a.requestType),u.features=this.getNodeFeatures(u,location.href,!0,!0,!0,!0),r.push(u.features);for(let t of e.children)P(t,u)};return P(e,null),{adjacencyMatrix:t,features:r}}localPooling(e){let t=e.add(this.tfjs.eye(e.shape[0])),r=this.tfjs.pow(this.tfjs.sum(t,1),-.5);r=r.where(this.tfjs.isFinite(r),this.tfjs.zeros(r.shape));let n=r.mul(this.tfjs.eye(t.shape[0]));return n.dot(t).dot(n)}localPoolingMap(e){return e.map((e=>this.localPooling(e)))}padTensorAdjacency(e,t){return e.pad([[0,0],[0,t-e.shape[1]],[0,t-e.shape[2]]])}padTensorFeatures(e,t){return e.pad([[0,0],[0,t-e.shape[1]],[0,0]])}preprocess(e){return this.tfjs.tidy((()=>e.map((e=>{let t=this.tfjs.tensor(e.data);if(e.preprocess)for(let r of e.preprocess)t=this.preprocessingMap.get(r.funcName)(t,r.args);return t}))))}}class aI{constructor(e,t){this.tag=e,this.attributes=t,this.children=[],this.elementHidden=!1,this.elementBlocked=!1,this.filter=null,this.requestType=null,this.height=0,this.width=0,this.cssSelectors=null}addChild(e){this.children.push(e)}}const oI=me,uI=be,sI=Object.freeze({__proto__:null,default:PI});oI.enableProdMode(),globalThis.graphMLUtil=new sI.default(oI),globalThis.graphMLUtil.loadRawModel(uI.hideIfGraphMatchesModel,uI.hideIfGraphMatchesWeights)}var Te}]]);
callback.get = snippet => graph.get(snippet);
callback.has = snippet => graph.has(snippet);
/* harmony default export */ const ml = (callback);
;// CONCATENATED MODULE: ./node_modules/@eyeo/snippets/webext/main.mjs
/*!
 * This file is part of eyeo's Anti-Circumvention Snippets module (@eyeo/snippets),
 * Copyright (C) 2006-present eyeo GmbH
 * 
 * @eyeo/snippets is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 * 
 * @eyeo/snippets is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with @eyeo/snippets.  If not, see <http://www.gnu.org/licenses/>.
 */

const main_callback = (environment, ...filters) => {
const e=Proxy,{apply:t,bind:r,call:n}=Function,o=n.bind(t),i=n.bind(r),s=n.bind(n),a={get:(e,t)=>i(n,e[t])},l=t=>new e(t,a),c=(t,r)=>new e(t,{apply:(e,t,n)=>o(r,t,n)}),u={get:(e,t)=>i(e[t],e)},f=t=>new e(t,u),{assign:p,defineProperties:d,freeze:h,getOwnPropertyDescriptor:w,getOwnPropertyDescriptors:g,getPrototypeOf:y}=f(Object),{hasOwnProperty:m}=l({}),{species:b}=Symbol,v={get(e,t){const r=e[t];class n extends r{}const o=g(r.prototype);delete o.constructor,h(d(n.prototype,o));const i=g(r);return delete i.length,delete i.prototype,i[b]={value:n},h(d(n,i))}},E=t=>new e(t,v),S="undefined"!=typeof environment?environment:{};"undefined"==typeof globalThis&&(window.globalThis=window);const{apply:M,ownKeys:T}=f(Reflect),x="world"in S,O=x&&"ISOLATED"===S.world,P=x&&"MAIN"===S.world,j="object"==typeof chrome&&!!chrome.runtime,N="object"==typeof browser&&!!browser.runtime,L=!P&&(O||j||N),k=e=>L?e:C(e,H(e)),{create:C,defineProperties:A,defineProperty:W,freeze:D,getOwnPropertyDescriptor:$,getOwnPropertyDescriptors:H}=f(Object),z=f(globalThis),R=L?globalThis:E(globalThis),{Map:F,RegExp:I,Set:J,WeakMap:V,WeakSet:B}=R,U=(e,t,r=null)=>{const n=T(t);for(const o of T(e)){if(n.includes(o))continue;const i=$(e,o);if(r&&"value"in i){const{value:e}=i;"function"==typeof e&&(i.value=r(e))}W(t,o,i)}},_=e=>{const t=R[e];class r extends t{}const{toString:n,valueOf:o}=t.prototype;A(r.prototype,{toString:{value:n},valueOf:{value:o}});const i=e.toLowerCase(),s=e=>function(){const t=M(e,this,arguments);return typeof t===i?new r(t):t};return U(t,r,s),U(t.prototype,r.prototype,s),r},X=D({frozen:new V,hidden:new B,iframePropertiesToAbort:{read:new J,write:new J},abortedIframes:new V}),G=new I("^[A-Z]");var q=new Proxy(new F([["chrome",L&&(j&&chrome||N&&browser)||void 0],["isExtensionContext",L],["variables",X],["console",k(console)],["document",globalThis.document],["performance",k(performance)],["JSON",k(JSON)],["Map",F],["Math",k(Math)],["Number",L?Number:_("Number")],["RegExp",I],["Set",J],["String",L?String:_("String")],["WeakMap",V],["WeakSet",B],["MouseEvent",MouseEvent]]),{get(e,t){if(e.has(t))return e.get(t);let r=globalThis[t];return"function"==typeof r&&(r=(G.test(t)?R:z)[t]),e.set(t,r),r},has:(e,t)=>e.has(t)});const K={WeakSet:WeakSet,WeakMap:WeakMap,WeakValue:class{has(){return!1}set(){}}},{apply:Y}=Reflect;const{Map:Z,WeakMap:Q,WeakSet:ee,setTimeout:te}=q;let re=!0,ne=e=>{e.clear(),re=!re};var oe=function(e){const{WeakSet:t,WeakMap:r,WeakValue:n}=this||K,o=new t,i=new r,s=new n;return function(t){if(o.has(t))return t;if(i.has(t))return i.get(t);if(s.has(t))return s.get(t);const r=Y(e,this,arguments);return o.add(r),r!==t&&("object"==typeof t&&t?i:s).set(t,r),r}}.bind({WeakMap:Q,WeakSet:ee,WeakValue:class extends Z{set(e,t){return re&&(re=!re,te(ne,0,this)),super.set(e,t)}}});const{concat:ie,includes:se,join:ae,reduce:le,unshift:ce}=l([]),ue=E(globalThis),{Map:fe,WeakMap:pe}=ue,de=new fe,he=t=>{const r=(e=>{const t=[];let r=e;for(;r;){if(de.has(r))ce(t,de.get(r));else{const e=g(r);de.set(r,e),ce(t,e)}r=y(r)}return ce(t,{}),o(p,null,t)})("function"==typeof t?t.prototype:t),n={get(e,t){if(t in r){const{value:n,get:o}=r[t];if(o)return s(o,e);if("function"==typeof n)return i(n,e)}return e[t]},set(e,t,n){if(t in r){const{set:o}=r[t];if(o)return s(o,e,n),!0}return e[t]=n,!0}};return t=>new e(t,n)},{isExtensionContext:we,Array:ge,Number:ye,String:me,Object:be}=q,{isArray:ve}=ge,{getOwnPropertyDescriptor:Ee,setPrototypeOf:Se}=be,{toString:Me}=be.prototype,{slice:Te}=me.prototype,{get:xe}=Ee(Node.prototype,"nodeType"),Oe=we?{}:{Attr:he(Attr),CanvasRenderingContext2D:he(CanvasRenderingContext2D),CSSStyleDeclaration:he(CSSStyleDeclaration),Document:he(Document),Element:he(Element),HTMLCanvasElement:he(HTMLCanvasElement),HTMLElement:he(HTMLElement),HTMLImageElement:he(HTMLImageElement),HTMLScriptElement:he(HTMLScriptElement),MutationRecord:he(MutationRecord),Node:he(Node),ShadowRoot:he(ShadowRoot),get CSS2Properties(){return Oe.CSSStyleDeclaration}},Pe=(e,t)=>{if("Element"!==t&&t in Oe)return Oe[t](e);if(ve(e))return Se(e,ge.prototype);const r=(e=>s(Te,s(Me,e),8,-1))(e);if(r in Oe)return Oe[r](e);if(r in q)return Se(e,q[r].prototype);if("nodeType"in e)switch(s(xe,e)){case 1:if(!(t in Oe))throw new Error("unknown hint "+t);return Oe[t](e);case 2:return Oe.Attr(e);case 3:return Oe.Node(e);case 9:return Oe.Document(e)}throw new Error("unknown brand "+r)};var je=we?e=>e===window||e===globalThis?q:e:oe(((e,t="Element")=>{if(e===window||e===globalThis)return q;switch(typeof e){case"object":return e&&Pe(e,t);case"string":return new me(e);case"number":return new ye(e);default:throw new Error("unsupported value")}}));const Ne={get(e,t){const r=e;for(;!m(e,t);)e=y(e);const{get:n,set:i}=w(e,t);return function(){return arguments.length?o(i,r,arguments):s(n,r)}}},Le=t=>new e(t,Ne);let ke=!1;function Ce(){return ke}const{console:Ae}=je(window),We=()=>{};function De(...e){Ce()&&je(e).unshift("%c DEBUG","font-weight: bold"),Ae.log(...e)}function $e(e){return i(Ce()?De:We,null,e)}let{Math:He,RegExp:ze}=je(window);function Re(e){let{length:t}=e;if(t>1&&"/"===e[0]){let r="/"===e[t-1];if(r||t>2&&je(e).endsWith("/i")){let t=[je(e).slice(1,r?-1:-2)];return r||t.push("i"),new ze(...t)}}return new ze(je(e).replace(/[-/\\^$*+?.()|[\]{}]/g,"\\$&"))}function Fe(){return je(He.floor(2116316160*He.random()+60466176)).toString(36)}let{parseFloat:Ie,variables:Je,Array:Ve,Error:Be,Map:Ue,Object:_e,ReferenceError:Xe,Set:Ge,WeakMap:qe}=je(window),{onerror:Ke}=Le(window),Ye=Node.prototype,Ze=Element.prototype,Qe=null;function et(e,t,r){let n=je(t),o=n.indexOf(".");if(-1==o){let n=_e.getOwnPropertyDescriptor(e,t);if(n&&!n.configurable)return;let o=_e.assign({},r,{configurable:!0});if(!n&&!o.get&&o.set){let r=e[t];o.get=()=>r}return void _e.defineProperty(e,t,o)}let i=n.slice(0,o).toString();t=n.slice(o+1).toString();let s=e[i];!s||"object"!=typeof s&&"function"!=typeof s||et(s,t,r);let a=_e.getOwnPropertyDescriptor(e,i);if(a&&!a.configurable)return;Qe||(Qe=new qe),Qe.has(e)||Qe.set(e,new Ue);let l=Qe.get(e);if(l.has(i))return void l.get(i).set(t,r);let c=new Ue([[t,r]]);l.set(i,c),_e.defineProperty(e,i,{get:()=>s,set(e){if(s=e,s&&("object"==typeof s||"function"==typeof s))for(let[e,t]of c)et(s,e,t)},configurable:!0})}function tt(e){let t=Ke();Ke(((...r)=>{let n=r.length&&r[0];return!("string"!=typeof n||!je(n).includes(e))||("function"==typeof t?o(t,this,r):void 0)}))}function rt(e,t,r){let n=$e(e);if(!r)return void n("no property to abort on read");let o=Fe();n(`aborting on ${r} access`),et(t,r,{get:function(){throw n(`${r} access aborted`),new Xe(o)},set(){}}),tt(o)}function nt(e,t,r){let n=$e(e);if(!r)return void n("no property to abort on write");let o=Fe();n(`aborting when setting ${r}`),et(t,r,{set:function(){throw n(`setting ${r} aborted`),new Xe(o)}}),tt(o)}function ot(e,t=!1,r=!1){let n=Je.abortedIframes,i=Je.iframePropertiesToAbort;for(let o of Ve.from(window.frames))if(n.has(o))for(let i of e)t&&n.get(o).read.add(i),r&&n.get(o).write.add(i);for(let n of e)t&&i.read.add(n),r&&i.write.add(n);function a(){for(let e of Ve.from(window.frames)){n.has(e)||n.set(e,{read:new Ge(i.read),write:new Ge(i.write)});let t=n.get(e).read;if(t.size>0){let r=Ve.from(t);t.clear();for(let t of r)rt("abort-on-iframe-property-read",e,t)}let r=n.get(e).write;if(r.size>0){let t=Ve.from(r);r.clear();for(let r of t)nt("abort-on-iframe-property-write",e,r)}}}a(),n.has(document)||(n.set(document,!0),function(e){let t;function r(e,t){for(let r of t){et(e,r,n(e,r))}}function n(t,r){let n=t[r];return{get:()=>function(...t){let r;return r=o(n,this,t),e&&e(),r}}}function i(t,r){let n=_e.getOwnPropertyDescriptor(t,r),{set:o}=n||{};return{set(t){let r;return r=s(o,this,t),e&&e(),r}}}r(Ye,["appendChild","insertBefore","replaceChild"]),r(Ze,["append","prepend","replaceWith","after","before","insertAdjacentElement","insertAdjacentHTML"]),t=i(Ze,"innerHTML"),et(Ze,"innerHTML",t),t=i(Ze,"outerHTML"),et(Ze,"outerHTML",t)}(a))}let{Object:it}=window;function st(e,t){if(!(e instanceof it))return;let r=e,n=je(t).split(".");if(0===n.length)return;for(let e=0;e<n.length-1;e++){let t=n[e];if(!m(r,t))return;if(r=r[t],!(r instanceof it))return}let o=n[n.length-1];return m(r,o)?[r,o]:void 0}const at=je(/^\d+$/);function lt(e){switch(e){case"false":return!1;case"true":return!0;case"null":return null;case"noopFunc":return()=>{};case"trueFunc":return()=>!0;case"falseFunc":return()=>!1;case"emptyArray":return[];case"emptyObj":return{};case"undefined":return;case"":return e;default:if(at.test(e))return Ie(e);throw new Be(`[override-property-read snippet]: Value "${e}" is not valid.`)}}let{HTMLScriptElement:ct,Object:ut,ReferenceError:ft}=je(window),pt=ut.getPrototypeOf(ct);let{Error:dt}=je(window),{cookie:ht}=Le(document);let{document:wt,getComputedStyle:gt,isExtensionContext:yt,variables:mt,Array:bt,MutationObserver:vt,Object:Et,XPathEvaluator:St,XPathExpression:Mt,XPathResult:Tt}=je(window),{querySelectorAll:xt}=wt,Ot=xt&&i(xt,wt);const{assign:Pt,setPrototypeOf:jt}=Et;class Nt extends Mt{evaluate(...e){return jt(o(super.evaluate,this,e),Tt.prototype)}}class Lt extends St{createExpression(...e){return jt(o(super.createExpression,this,e),Nt.prototype)}}function kt(e){if(mt.hidden.has(e))return;!function(e){yt&&"function"==typeof checkElement&&checkElement(e)}(e),mt.hidden.add(e);let{style:t}=je(e),r=je(t,"CSSStyleDeclaration"),n=je([]),{debugCSSProperties:o}=S;for(let[e,t]of o||[["display","none"]])r.setProperty(e,t,"important"),n.push([e,r.getPropertyValue(e)]);new vt((()=>{for(let[e,t]of n){let n=r.getPropertyValue(e),o=r.getPropertyPriority(e);n==t&&"important"==o||r.setProperty(e,t,"important")}})).observe(e,{attributes:!0,attributeFilter:["style"]})}function Ct(e){let t=e;if(t.startsWith("xpath(")&&t.endsWith(")")){let t=function(e){let t=e;if(t.startsWith("xpath(")&&t.endsWith(")")){let e=t.slice(6,-1),r=(new Lt).createExpression(e,null),n=Tt.ORDERED_NODE_SNAPSHOT_TYPE;return e=>{if(!e)return;let t=r.evaluate(wt,n,null),{snapshotLength:o}=t;for(let r=0;r<o;r++)e(t.snapshotItem(r))}}return t=>Ot(e).forEach(t)}(e);return()=>{let e=je([]);return t((t=>e.push(t))),e}}return()=>bt.from(Ot(e))}let{ELEMENT_NODE:At,TEXT_NODE:Wt,prototype:Dt}=Node,{prototype:$t}=Element,{prototype:Ht}=HTMLElement,{console:zt,variables:Rt,DOMParser:Ft,Error:It,MutationObserver:Jt,Object:Vt,ReferenceError:Bt}=je(window),{getOwnPropertyDescriptor:Ut}=Vt;je(window);const{Map:_t,MutationObserver:Xt,Object:Gt,Set:qt,WeakSet:Kt}=je(window);let Yt=Element.prototype,{attachShadow:Zt}=Yt,Qt=new Kt,er=new _t,tr=null;const{Error:rr,JSON:nr,Map:or,Object:ir}=je(window);let sr=null;let{Error:ar,JSON:lr,Map:cr,Object:ur}=je(window),fr=null;let{Error:pr}=je(window);let{Error:dr,Map:hr,Object:wr,console:gr}=je(window),{toString:yr}=Function.prototype,mr=EventTarget.prototype,{addEventListener:br}=mr,vr=null;let Er,{URL:Sr,fetch:Mr}=je(window),{delete:Tr}=l(URLSearchParams.prototype);const xr={"abort-current-inline-script":function(e,t=null){let r=t?Re(t):null,n=Fe(),o=je(document).currentScript,i=window,a=je(e).split("."),l=je(a).pop();for(let e of je(a))if(i=i[e],!i||"object"!=typeof i&&"function"!=typeof i)return;let{get:c,set:u}=ut.getOwnPropertyDescriptor(i,l)||{},f=i[l],p=()=>{let e=je(document).currentScript;if(e instanceof pt&&""==je(e,"HTMLScriptElement").src&&e!=o&&(!r||r.test(je(e).textContent)))throw new ft(n)};et(i,l,{get(){return p(),c?s(c,this):f},set(e){p(),u?s(u,this,e):f=e}}),tt(n)},"abort-on-iframe-property-read":function(...e){ot(e,!0,!1)},"abort-on-iframe-property-write":function(...e){ot(e,!1,!0)},"abort-on-property-read":function(e){rt("abort-on-property-read",window,e)},"abort-on-property-write":function(e){nt("abort-on-property-write",window,e)},"cookie-remover":function(e){if(!e)throw new dt("[cookie-remover snippet]: No cookie to remove.");let t=$e("cookie-remover"),r=Re(e);if(je(/^http|^about/).test(location.protocol)){t("Parsing cookies for matches");for(const e of je(je(ht()).split(";").filter((e=>r.test(je(e).split("=")[0]))))){let r=je(location.hostname),n=je(e).split("=")[0],o="expires=Thu, 01 Jan 1970 00:00:00 GMT",i="path=/",s="domain="+r.slice(r.indexOf(".")+1);ht(`${je(n).trim()}=;${o};${i};${s}`),t(`Set expiration date on ${n}`)}}else t("Snippet only works for http or https and about.")},debug:function(){ke=!0},"freeze-element":function(e,t="",...r){let n,i,a=!1,l=!1,c=je(r).filter((e=>!h(e))),u=je(r).filter((e=>h(e))).map(Re),f=Fe(),p=Ct(e);!function(){let r=je(t).split("+");1===r.length&&""===r[0]&&(r=[]);for(let t of r)switch(t){case"subtree":a=!0;break;case"abort":l=!0;break;default:throw new It("[freeze] Unknown option passed to the snippet. [selector]: "+e+" [option]: "+t)}}();let d={selector:e,shouldAbort:l,rid:f,exceptionSelectors:c,regexExceptions:u,changeId:0};function h(e){return e.length>=2&&"/"==e[0]&&"/"==e[e.length-1]}function w(){i=p(),g(i,!1)}function g(e,t=!0){for(let r of e)Rt.frozen.has(r)||(Rt.frozen.set(r,d),!t&&a&&new Jt((e=>{for(let t of je(e))g(je(t,"MutationRecord").addedNodes)})).observe(r,{childList:!0,subtree:!0}),a&&je(r).nodeType===At&&g(je(r).childNodes))}function y(e,...t){De(`[freeze][${e}] `,...t)}function m(e,t,r,n){let o=n.selector,i=n.changeId,s="string"==typeof e,a=n.shouldAbort?"aborting":"watching";switch(zt.groupCollapsed(`[freeze][${i}] ${a}: ${o}`),r){case"appendChild":case"append":case"prepend":case"insertBefore":case"replaceChild":case"insertAdjacentElement":case"insertAdjacentHTML":case"insertAdjacentText":case"innerHTML":case"outerHTML":y(i,s?"text: ":"node: ",e),y(i,"added to node: ",t);break;case"replaceWith":case"after":case"before":y(i,s?"text: ":"node: ",e),y(i,"added to node: ",je(t).parentNode);break;case"textContent":case"innerText":case"nodeValue":y(i,"content of node: ",t),y(i,"changed to: ",e)}y(i,`using the function "${r}"`),zt.groupEnd(),n.changeId++}function b(e,t){if(t)for(let r of t)if(r.test(e))return!0;return!1}function v(e){throw new Bt(e)}function E(e,t,r,n){let o=new Ft,{body:i}=je(o.parseFromString(e,"text/html")),s=S(je(i).childNodes,t,r,n);return je(s).map((e=>{switch(je(e).nodeType){case At:return je(e).outerHTML;case Wt:return je(e).textContent;default:return""}})).join("")}function S(e,t,r,n){let o=je([]);for(let i of e)M(i,t,r,n)&&o.push(i);return o}function M(e,t,r,n){let o=n.shouldAbort,i=n.regexExceptions,s=n.exceptionSelectors,a=n.rid;if("string"==typeof e){let s=e;return!!b(s,i)||(Ce()&&m(s,t,r,n),o&&v(a),Ce())}let l=e;switch(je(l).nodeType){case At:return!!function(e,t){if(t){let r=je(e);for(let e of t)if(r.matches(e))return!0}return!1}(l,s)||(o&&(Ce()&&m(l,t,r,n),v(a)),!!Ce()&&(kt(l),m(l,t,r,n),!0));case Wt:return!!b(je(l).textContent,i)||(Ce()&&m(l,t,r,n),o&&v(a),!1);default:return!0}}function T(e,t,r,n){let i=Ut(e,t)||{},a=i.get&&s(i.get,e)||i.value;if(a)return{get:()=>function(...e){if(r(this)){let r=n(this);if(r){let n=e[0];if(!M(n,this,t,r))return n}}return o(a,this,e)}}}function x(e,t,r,n){let i=Ut(e,t)||{},a=i.get&&s(i.get,e)||i.value;if(a)return{get:()=>function(...e){if(!r(this))return o(a,this,e);let i=n(this);if(!i)return o(a,this,e);let s=S(e,this,t,i);return s.length>0?o(a,this,s):void 0}}}function O(e,t,r,n){let i=Ut(e,t)||{},a=i.get&&s(i.get,e)||i.value;if(a)return{get:()=>function(...e){let[i,l]=e,c="afterbegin"===i||"beforeend"===i;if(r(this,c)){let e=n(this,c);if(e){let r,n=c?this:je(this).parentNode;switch(t){case"insertAdjacentElement":if(!M(l,n,t,e))return l;break;case"insertAdjacentHTML":return r=E(l,n,t,e),r?s(a,this,i,r):void 0;case"insertAdjacentText":if(!M(l,n,t,e))return}}}return o(a,this,e)}}}function P(e,t,r,n){let o=Ut(e,t)||{},{set:i}=o;if(i)return{set(e){if(!r(this))return s(i,this,e);let o=n(this);if(!o)return s(i,this,e);let a=E(e,this,t,o);return a?s(i,this,a):void 0}}}function j(e,t,r,n){let o=Ut(e,t)||{},{set:i}=o;if(i)return{set(e){if(!r(this))return s(i,this,e);let o=n(this);return o?M(e,this,t,o)?s(i,this,e):void 0:s(i,this,e)}}}Rt.frozen.has(document)||(Rt.frozen.set(document,!0),function(){let e;function t(e){return e&&Rt.frozen.has(e)}function r(e){try{return e&&(Rt.frozen.has(e)||Rt.frozen.has(je(e).parentNode))}catch(e){return!1}}function n(e,t){try{return e&&(Rt.frozen.has(e)&&t||Rt.frozen.has(je(e).parentNode)&&!t)}catch(e){return!1}}function o(e){return Rt.frozen.get(e)}function i(e){try{if(Rt.frozen.has(e))return Rt.frozen.get(e);let t=je(e).parentNode;return Rt.frozen.get(t)}catch(e){}}function s(e,t){try{if(Rt.frozen.has(e)&&t)return Rt.frozen.get(e);let r=je(e).parentNode;return Rt.frozen.get(r)}catch(e){}}e=T(Dt,"appendChild",t,o),et(Dt,"appendChild",e),e=T(Dt,"insertBefore",t,o),et(Dt,"insertBefore",e),e=T(Dt,"replaceChild",t,o),et(Dt,"replaceChild",e),e=x($t,"append",t,o),et($t,"append",e),e=x($t,"prepend",t,o),et($t,"prepend",e),e=x($t,"replaceWith",r,i),et($t,"replaceWith",e),e=x($t,"after",r,i),et($t,"after",e),e=x($t,"before",r,i),et($t,"before",e),e=O($t,"insertAdjacentElement",n,s),et($t,"insertAdjacentElement",e),e=O($t,"insertAdjacentHTML",n,s),et($t,"insertAdjacentHTML",e),e=O($t,"insertAdjacentText",n,s),et($t,"insertAdjacentText",e),e=P($t,"innerHTML",t,o),et($t,"innerHTML",e),e=P($t,"outerHTML",r,i),et($t,"outerHTML",e),e=j(Dt,"textContent",t,o),et(Dt,"textContent",e),e=j(Ht,"innerText",t,o),et(Ht,"innerText",e),e=j(Dt,"nodeValue",t,o),et(Dt,"nodeValue",e)}()),n=new Jt(w),n.observe(document,{childList:!0,subtree:!0}),w()},"hide-if-shadow-contains":function(e,t="*"){let r=`${e}\\${t}`;er.has(r)||er.set(r,[Re(e),t,We]),tr||(tr=new Xt((e=>{let t=new qt;for(let{target:r}of je(e)){let e=je(r).parentNode;for(;e;)[r,e]=[e,je(r).parentNode];if(!Qt.has(r)&&!t.has(r)){t.add(r);for(let[e,t,n]of er.values())if(e.test(je(r).textContent)){let e=je(r.host).closest(t);e&&(n(),je(r).appendChild(document.createElement("style")).textContent=":host {display: none !important}",kt(e),Qt.add(r))}}}})),Gt.defineProperty(Yt,"attachShadow",{value:c(Zt,(function(){let e=o(Zt,this,arguments);return tr.observe(e,{childList:!0,characterData:!0,subtree:!0}),e}))}))},"json-override":function(e,t,r="",n=""){if(!e)throw new rr("[json-override snippet]: Missing paths to override.");if(void 0===t)throw new rr("[json-override snippet]: No value to override with.");if(!sr){let e=$e("json-override"),{parse:t}=nr;sr=new or,ir.defineProperty(window.JSON,"parse",{value:c(t,(function(r){let n=o(t,this,arguments);for(let{prune:t,needle:o,filter:i,value:s}of sr.values())if(!i||i.test(r)){if(je(o).some((e=>!st(n,e))))return n;for(let r of t){let t=st(n,r);void 0!==t&&(e(`Found ${r} replaced it with ${s}`),t[0][t[1]]=lt(s))}}return n}))}),e("Wrapped JSON.parse for override")}sr.set(e,{prune:je(e).split(/ +/),needle:r.length?je(r).split(/ +/):[],filter:n?Re(n):null,value:t})},"json-prune":function(e,t=""){if(!e)throw new ar("Missing paths to prune");if(!fr){let e=$e("json-prune"),{parse:t}=lr;fr=new cr,ur.defineProperty(window.JSON,"parse",{value:c(t,(function(){let r=o(t,this,arguments);for(let{prune:t,needle:n}of fr.values()){if(je(n).some((e=>!st(r,e))))return r;for(let n of t){let t=st(r,n);void 0!==t&&(e(`Found ${n} and deleted`),delete t[0][t[1]])}}return r}))}),e("Wrapped JSON.parse for prune")}fr.set(e,{prune:je(e).split(/ +/),needle:t.length?je(t).split(/ +/):[]})},"override-property-read":function(e,t){if(!e)throw new pr("[override-property-read snippet]: No property to override.");if(void 0===t)throw new pr("[override-property-read snippet]: No value to override with.");let r=$e("override-property-read"),n=lt(t);r(`Overriding ${e}.`),et(window,e,{get:()=>(r(`${e} override done.`),n),set(){}})},"prevent-listener":function(e,t,r){if(!e)throw new dr("[prevent-listener snippet]: No event type.");if(!vr){vr=new hr;let e=$e("[prevent]");wr.defineProperty(mr,"addEventListener",{value:c(br,(function(t,r){for(let{evt:n,handlers:o,selectors:i}of vr.values()){if(!n.test(t))continue;let a=this instanceof Element;for(let l=0;l<o.length;l++){let c=o[l],u=i[l],f=()=>c.test(s(yr,"function"==typeof r?r:r.handleEvent));if((!c||f())&&(!u||a&&je(this).matches(u)))return void(Ce()&&(gr.groupCollapsed("DEBUG [prevent] was successful"),e(`type: ${t} matching ${n}`),e("handler:",r),c&&e(`matching ${c}`),u&&e("on element: ",this,` matching ${u}`),e("was prevented from being added"),gr.groupEnd()))}}return o(br,this,arguments)}))}),e("Wrapped addEventListener")}vr.has(e)||vr.set(e,{evt:Re(e),handlers:[],selectors:[]});let{handlers:n,selectors:i}=vr.get(e);n.push(t?Re(t):null),i.push(r)},"strip-fetch-query-parameter":function(e,t=null){Er||(Er=new Map,window.fetch=c(Mr,((...e)=>{let[t]=e;if("string"==typeof t){let r=new Sr(t);for(let[n,o]of Er)o&&!o.test(t)||(Tr(r.searchParams,n),e[0]=r.href)}return o(Mr,self,e)}))),Er.set(e,t&&Re(t))},trace:function(...e){o(De,null,e)}};
const snippets=xr;
let context;
for (const [name, ...args] of filters) {
if (snippets.hasOwnProperty(name)) {
try { context = snippets[name].apply(context, args); }
catch (error) { console.error(error); }
}
}
context = void 0;
};
const main_graph = new Map([["abort-current-inline-script",null],["abort-on-iframe-property-read",null],["abort-on-iframe-property-write",null],["abort-on-property-read",null],["abort-on-property-write",null],["cookie-remover",null],["debug",null],["freeze-element",null],["hide-if-shadow-contains",null],["json-override",null],["json-prune",null],["override-property-read",null],["prevent-listener",null],["strip-fetch-query-parameter",null],["trace",null]]);
main_callback.get = snippet => main_graph.get(snippet);
main_callback.has = snippet => main_graph.has(snippet);
/* harmony default export */ const main = (main_callback);
;// CONCATENATED MODULE: ./node_modules/@eyeo/snippets/index.mjs






;// CONCATENATED MODULE: ./adblock-betafish/alias/contentFiltering.js
/*
 * Same as the original source adblockpluschrome/lib/contentFiltering.js
 * except:
 * - updated require paths
 * - added fetch() of second snippet library
 */
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module contentFiltering */




function loadSnippets() {
  ewe_api.snippets.setLibrary({
    injectedCode: main,
    isolatedCode: ml
  });
};
loadSnippets();


/***/ }),

/***/ 1021:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "QO": () => (/* binding */ showIconBadgeCTA),
/* harmony export */   "ec": () => (/* binding */ NEW_BADGE_REASONS),
/* harmony export */   "vo": () => (/* binding */ getNewBadgeTextReason)
/* harmony export */ });
/* unused harmony exports statsInIconKey, stopIconAnimation, startIconAnimation */
/* harmony import */ var info__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(187);
/* harmony import */ var _vendor_adblockplusui_adblockpluschrome_lib_storage_tab_session_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1627);
/* harmony import */ var _vendor_adblockplusui_adblockpluschrome_lib_allowlisting__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8858);
/* harmony import */ var _vendor_adblockplusui_adblockpluschrome_lib_browserAction__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3265);
/* harmony import */ var _utilities_background_bg_functions_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2028);
/*
 * Same as the original source adblockpluschrome/lib/icon.js
 * except:
 * - updated image file names from 'abp-' to 'ab-'
 * - updated the 'import' paths
 * - use the term 'whitelisted' instead of 'allowlisted' for now
 * - call renderIcons() at the end of the module for all platforms,
 *   not just Chromium
 * - added the showIconBadgeCTA, getNewBadgeTextReason functions, and related
 *   message listeners
 */
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module icon */








const ANIMATION_LOOPS = 3;
const FRAME_IN_MS = 100;

const statsInIconKey = 'current_show_statsinicon';

let frameOpacities = calculateFrameOpacities(9, 7);
let frameOpacitiesCritical = calculateFrameOpacities(5, 3);

let stopRequested = false;
let canUpdateIcon = true;
let notRunning = Promise.resolve();
let allowlistedState = new _vendor_adblockplusui_adblockpluschrome_lib_storage_tab_session_js__WEBPACK_IMPORTED_MODULE_1__/* .TabSessionStorage */ .H("icon:allowlistedState");

let icons = [null, null];

function easeOut(progress)
{
  // This is merely an approximation to the built-in ease-out timing function
  // https://css-tricks.com/emulating-css-timing-functions-javascript/
  return 1 - Math.pow(1 - progress, 1.675);
}

function calculateFrameOpacities(keyframeFrames, transitionFrames)
{
  let opacities = [];

  // Show second half of first keyframe
  // Omit first frame because it's only shown after the first timeout
  for (let i = 0; i < keyframeFrames / 2 - 1; i++)
    opacities.push(0);
  // Transition from first to second keyframe
  for (let i = 0; i < transitionFrames; i++)
    opacities.push(easeOut((i + 1) / (transitionFrames + 1)));
  // Show second keyframe
  for (let i = 0; i < keyframeFrames; i++)
    opacities.push(1);
  // Transition from second to first keyframe
  for (let i = 0; i < transitionFrames; i++)
    opacities.push(easeOut((transitionFrames - i) / (transitionFrames + 1)));
  // Show first half of first keyframe
  // Omit last frame due to an additional timeout that resets the icon
  for (let i = 0; i < keyframeFrames / 2 - 1; i++)
    opacities.push(0);

  return opacities;
}

async function loadImage(url)
{
  let response = await fetch(url);
  let blob = await response.blob();
  return createImageBitmap(blob);
}

async function renderIcons()
{
  let paths = [
    "icons/ab-16.png", "icons/ab-16-whitelisted.png",
    "icons/ab-32.png", "icons/ab-32-whitelisted.png"
  ];

  for (let path of paths) {
    let image = await loadImage(path);
    let [, size, allowlisted] = /\/ab-(16|32)(-whitelisted)?\./.exec(path);

    let canvas = new OffscreenCanvas(size, size);
    let context = canvas.getContext("2d");
    let imageData = icons[!!allowlisted | 0] || {};

    context.globalAlpha = 1;
    context.drawImage(image, 0, 0);
    imageData[size] = context.getImageData(0, 0, size, size);

    icons[!!allowlisted | 0] = imageData;
  }
}

async function setIcon(page, opacity, frames)
{
  opacity = opacity || 0;
  let allowlisted = !!(await allowlistedState.get(page.id));

  if (!frames)
  {
    if (opacity > 0.5)
    {
      (0,_vendor_adblockplusui_adblockpluschrome_lib_browserAction__WEBPACK_IMPORTED_MODULE_3__/* .setIconPath */ .c4)(
        page.id,
        "/icons/ab-$size-notification.png"
      );
    }
    else if (icons[allowlisted | 0])
    {
      (0,_vendor_adblockplusui_adblockpluschrome_lib_browserAction__WEBPACK_IMPORTED_MODULE_3__/* .setIconImageData */ .k8)(page.id, icons[allowlisted | 0]);
    }
    else
    {
      (0,_vendor_adblockplusui_adblockpluschrome_lib_browserAction__WEBPACK_IMPORTED_MODULE_3__/* .setIconPath */ .c4)(
        page.id,
        "/icons/ab-$size" + (allowlisted ? "-allowlisted" : "") + ".png"
      );
    }
  }
  else
  {
    browser.action.setIcon({
      tabId: page.id,
      imageData: frames["" + opacity + allowlisted]
    });
  }
}

_vendor_adblockplusui_adblockpluschrome_lib_allowlisting__WEBPACK_IMPORTED_MODULE_2__/* .allowlistingState.addListener */ ._o.addListener("changed", async(page, isAllowlisted) =>
{
  await allowlistedState.set(page.id, isAllowlisted);
  if (canUpdateIcon)
    await setIcon(page);
});

async function renderFrames(opacities) {
  let images = await Promise.all([
    loadImage("icons/ab-16.png"),
    loadImage("icons/ab-16-whitelisted.png"),
    loadImage("icons/ab-16-whitelisted.png"),
    loadImage("icons/ab-20.png"),
    loadImage("icons/ab-20-whitelisted.png"),
    loadImage("icons/ab-20-whitelisted.png"),
    loadImage("icons/ab-32.png"),
    loadImage("icons/ab-32-whitelisted.png"),
    loadImage("icons/ab-32-whitelisted.png"),
    loadImage("icons/ab-40.png"),
    loadImage("icons/ab-40-whitelisted.png"),
    loadImage("icons/ab-40-whitelisted.png"),
  ]);
  opacities = new Set(opacities);
  let imageMap = {
    16: { base: [images[0], images[1]], overlay: images[2] },
    20: { base: [images[3], images[4]], overlay: images[5] },
    32: { base: [images[6], images[7]], overlay: images[8] },
    40: { base: [images[9], images[10]], overlay: images[11] }
  };

  let frames = {};
  let canvas = new OffscreenCanvas(0, 0);
  let context = canvas.getContext("2d");

  for (let allowlisted of [false, true])
  {
    for (let opacity of opacities)
    {
      let imageData = {};
      let sizes = [16, 20, 32, 40];
      for (let size of sizes)
      {
        canvas.width = size;
        canvas.height = size;
        context.globalAlpha = 1;
        context.drawImage(imageMap[size]["base"][allowlisted | 0], 0, 0);
        context.globalAlpha = opacity;
        context.drawImage(imageMap[size]["overlay"], 0, 0);
        imageData[size] = context.getImageData(0, 0, size, size);
      }
      frames["" + opacity + allowlisted] = imageData;
    }
  }

  return frames;
}

async function animateIcon(opacities, frames)
{
  let tabs = await browser.tabs.query({active: true});
  let pages = tabs.map(tab => new ext.Page(tab));

  let animationLoop = 0;
  let animationStep = 0;
  let numberOfFrames = opacities.length;
  let opacity = 0;

  let onActivated = async page =>
  {
    pages.push(page);
    await setIcon(page, opacity, frames);
    toggleBadge(page.id, true);
  };
  ext.pages.onActivated.addListener(onActivated);

  canUpdateIcon = false;
  for (let page of pages)
    toggleBadge(page.id, true);
  return new Promise((resolve, reject) =>
  {
    let interval = setInterval(async() =>
    {
      let oldOpacity = opacity;
      opacity = opacities[animationStep++];

      if (opacity != oldOpacity)
      {
        for (let page of pages)
        {
          if (await allowlistedState.has(page.id))
            await setIcon(page, opacity, frames);
        }
      }

      if (animationStep > numberOfFrames)
      {
        if (++animationLoop > ANIMATION_LOOPS - 1 || stopRequested)
        {
          clearInterval(interval);
          ext.pages.onActivated.removeListener(onActivated);
          for (let page of pages)
            toggleBadge(page.id, false);
          canUpdateIcon = true;
          resolve();
        }
        else
        {
          animationStep = 0;
        }
      }
    }, FRAME_IN_MS);
  });
}

/**
 * Stops to animate the browser action icon
 * after the current interval has been finished.
 *
 * @return {Promise} A promise that is fullfilled when
 *                   the icon animation has been stopped.
 */
async function stopIconAnimation()
{
  stopRequested = true;
  await notRunning;
  stopRequested = false;
}

/**
 * Starts to animate the browser action icon to indicate a pending notifcation.
 * If the icon is already animated, it replaces the previous
 * animation as soon as the current interval has been finished.
 *
 * @param {string} type  The notification type (i.e: "information" or
 *                       "critical".)
 */
function startIconAnimation(type)
{
  let opacities = frameOpacities;
  if (type == "critical")
    opacities = frameOpacitiesCritical;

  notRunning = Promise.all([renderFrames(opacities), stopIconAnimation()])
    .then(results =>
    {
      if (stopRequested)
        return;

      let frames = results[0];
      return animateIcon(opacities, frames);
    });
}

renderIcons();

/**
 * Returns the Object containing all of the reasons the text on the toolbar icon / badge is 'new'
 *
 */
const NEW_BADGE_REASONS = {
  SEVEN_DAY: 'seven day',
  UPDATE: 'update',
  VPN_CTA: 'vpn cta',
  FREE_DC_UPDATE: 'free dc update',
};

/**
 * Handles the display of the New badge on the toolbar icon.
 * @param {Boolean} [showBadge] true shows the badge, false removes the badge
 */

let newBadgeTextReason = "";

async function showIconBadgeCTA(showBadge, reason) {
  if (!License.shouldShowPremiumCTA()) {
    return;
  }
  if (showBadge) {
    let newBadgeText = browser.i18n.getMessage('new_badge');
    // Text that exceeds 4 characters is truncated on the toolbar badge,
    // so we default to English
    if (!newBadgeText || newBadgeText.length >= 5) {
      newBadgeText = 'New';
    }
    (0,_utilities_background_bg_functions_js__WEBPACK_IMPORTED_MODULE_4__/* .chromeStorageSetHelper */ .rJ)(statsInIconKey, Prefs.show_statsinicon);
    Prefs.show_statsinicon = false;
    // wait 10 seconds to allow any other ABP setup tasks to finish
    setTimeout(() => {
      // process all currently opened tabs
      browser.tabs.query({}).then((tabs) => {
        for (const tab of tabs) {
          if (tab.url && tab.url.startsWith('http')) {
            (0,_vendor_adblockplusui_adblockpluschrome_lib_browserAction__WEBPACK_IMPORTED_MODULE_3__/* .setBadge */ .q_)(tab.id, { color: '#03bcfc', number: newBadgeText });
            newBadgeTextReason = reason || '';
          }
        }
      });
    }, 10000); // 10 seconds
  } else {
    // Restore show_statsinicon if we previously stored its value
    const storedValue = await (0,_utilities_background_bg_functions_js__WEBPACK_IMPORTED_MODULE_4__/* .chromeStorageGetHelper */ .nX)(statsInIconKey);
    if (typeof storedValue === 'boolean') {
      Prefs.show_statsinicon = storedValue;
      (0,_utilities_background_bg_functions_js__WEBPACK_IMPORTED_MODULE_4__/* .chromeStorageSetHelper */ .rJ)(statsInIconKey); // remove the data, since we no longer need it
      browser.tabs.query({}).then((tabs) => {
        for (const tab of tabs) {
          browser.browserAction.setBadgeText({
            tabId: tab.id,
            text: '',
          });
        }
      });
      browser.browserAction.setBadgeText({ text: ' ' });
    }
  }
};

/**
 * Returns the String reason the text on the toolbar icon / badge is 'new'
 *
 */
function getNewBadgeTextReason() {
  return newBadgeTextReason;
};


/***/ }),

/***/ 5829:
/***/ ((__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3817);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__);



browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
  if (message.command !== "parseFilter" || !message.filterTextToParse) {
    return;
  }
  sendResponse(_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__.filters.validate(message.filterTextToParse));
});


/***/ }),

/***/ 8910:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";

// EXPORTS
__webpack_require__.d(__webpack_exports__, {
  "j": () => (/* binding */ initialize)
});

// UNUSED EXPORTS: isDataCorrupted

// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/prefs.js
var prefs = __webpack_require__(8710);
// EXTERNAL MODULE: ./build/templates/info.chrome.js.tmpl
var info_chrome_js = __webpack_require__(187);
// EXTERNAL MODULE: ./vendor/webext-sdk/dist/ewe-api.js
var ewe_api = __webpack_require__(3817);
;// CONCATENATED MODULE: ./node_modules/@adblockinc/rules/dist/index/adblock.json
const adblock_namespaceObject = JSON.parse('[{"id":"684A25C6-6B5D-458A-8A2B-BAC0A12B0B15","type":"ads","languages":["ar"],"title":"Liste AR+Liste FR+EasyList","homepage":"https://forums.lanik.us/viewforum.php?f=98","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","8D421590-1A68-4B68-BE50-04E17C09460E","3D60E303-1141-4775-B800-834177922876"],"url":"https://easylist-downloads.adblockplus.org/v3/full/liste_ar+liste_fr+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/liste_ar+liste_fr+easylist.txt"},{"id":"25A31255-AB36-48A4-9086-06192DE71119","type":"ads","languages":["bn","gu","hi","pa","as","mr","ml","te","kn","or","ne","si"],"title":"IndianList+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","9FAA2906-CD5C-4520-BDC4-4E098B7EA228"],"url":"https://easylist-downloads.adblockplus.org/v3/full/indianlist+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/indianlist+easylist.txt"},{"id":"E22C3B40-DC90-49D7-8BF5-E60904AB159A","type":"ads","languages":["bg"],"title":"Bulgarian list+EasyList","homepage":"https://stanev.org/abp/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","1638B159-F64A-4307-84E7-16AB08ED409E"],"url":"https://easylist-downloads.adblockplus.org/v3/full/bulgarian_list+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/bulgarian_list+easylist.txt"},{"id":"4B6CE485-30AB-4213-AD17-504B3F2D2825","type":"ads","languages":["cs","sk"],"title":"EasyList Czech and Slovak+EasyList","homepage":"https://adblock.sk/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","2D8C4D88-34A0-4259-9098-30D28BA674BC"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistczechslovak+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistczechslovak+easylist.txt"},{"id":"96932CD9-6DDF-4D97-B92F-FDF747B6FAA2","type":"ads","languages":["no","nb","nn","da","is","fo","kl","sv","fi"],"title":"Dandelion Sprout\'s Nordic Filters+EasyList","homepage":"https://github.com/DandelionSprout/adfilt","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","6D489E8D-E61C-444C-BBC5-44741773ADC2"],"url":"https://easylist-downloads.adblockplus.org/v3/full/dandelion_sprouts_nordic_filters+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/dandelion_sprouts_nordic_filters+easylist.txt"},{"id":"0CD3D105-D3B3-4652-8489-94163DE9A08F","type":"ads","languages":["de"],"title":"EasyList Germany+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","4337FB2B-A95C-44D5-B78D-11AD40F7711B"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistgermany+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistgermany+easylist.txt"},{"id":"8C13E995-8F06-4927-BEA7-6C845FB7EEBF","type":"ads","languages":["en"],"title":"EasyList","homepage":"https://easylist.to/","url":"https://easylist-downloads.adblockplus.org/v3/full/easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylist.txt"},{"id":"C3D13A19-3E8D-41F5-AD64-0F3B36DDE128","type":"ads","languages":["es"],"title":"EasyList Spanish+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","C8C1AA76-15B4-4CA3-8A9C-AD38D6AFCAEC"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistspanish+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistspanish+easylist.txt"},{"id":"2CEA1481-C29C-44F1-A084-A2A019533797","type":"ads","languages":["fr"],"title":"Liste FR+EasyList","homepage":"https://forums.lanik.us/viewforum.php?f=98","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","8D421590-1A68-4B68-BE50-04E17C09460E"],"url":"https://easylist-downloads.adblockplus.org/v3/full/liste_fr+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/liste_fr+easylist.txt"},{"id":"07549D8B-F06F-4D9D-A567-929AA59E9D1D","type":"ads","languages":["he"],"title":"EasyList Hebrew+EasyList","homepage":"https://github.com/easylist/EasyListHebrew","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","AE0D9320-665E-407D-B692-1A85AE481F34"],"url":"https://easylist-downloads.adblockplus.org/v3/full/israellist+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/israellist+easylist.txt"},{"id":"B7D76369-DD19-4602-80E8-2E32DDB490AC","type":"ads","languages":["id","ms"],"title":"ABPindo+EasyList","homepage":"http://abpindo.blogspot.com/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","A4A32212-E6BD-45F6-AD0F-E0FD18E8537B"],"url":"https://easylist-downloads.adblockplus.org/v3/full/abpindo+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/abpindo+easylist.txt"},{"id":"BBC07C05-66F1-42EC-BD4D-7AD495FAC84B","type":"ads","languages":["it"],"title":"EasyList Italy+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","2F0A4F0D-DF16-40D0-B0E0-5EB6791EC119"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistitaly+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistitaly+easylist.txt"},{"id":"2708BCB7-2E45-41BC-B517-1730CF532F89","type":"ads","languages":["ko"],"title":"KoreanList+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","BCE2062F-0D99-4861-A1F7-E3DFEA6DAB69"],"url":"https://easylist-downloads.adblockplus.org/v3/full/koreanlist+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/koreanlist+easylist.txt"},{"id":"CBE50FA2-DE3F-480C-B1D7-04289391C033","type":"ads","languages":["lt"],"title":"EasyList Lithuania+EasyList","homepage":"https://github.com/EasyList-Lithuania/easylist_lithuania","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","E89B3C08-2DED-40EA-8EE1-339B90D7B451"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistlithuania+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistlithuania+easylist.txt"},{"id":"950C88EA-2DD1-42E3-B2A2-2DF2ED15563A","type":"ads","languages":["lv"],"title":"Latvian List+EasyList","homepage":"https://forums.lanik.us/viewforum.php?f=99-latvian-list","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","51893C6C-F39E-43C5-A2EF-9545E388A2CE"],"url":"https://easylist-downloads.adblockplus.org/v3/full/latvianlist+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/latvianlist+easylist.txt"},{"id":"A4B88FB6-E5E5-417F-8A49-20B8244995FD","type":"ads","languages":["nl"],"title":"EasyList Dutch+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","CB94E27D-6CD1-4DB9-83D9-6B7F1A3555F6"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistdutch+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistdutch+easylist.txt"},{"id":"3D2C09D0-DF1C-4C8E-9947-A23DCEAF8F8B","type":"ads","languages":["pl"],"title":"EasyList Polish+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","9F743FCD-801B-41D0-830F-5A4EA995216E"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistpolish+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistpolish+easylist.txt"},{"id":"14DF7BE6-9675-4E07-987A-D8A1000F9FEF","type":"ads","languages":["pt"],"title":"EasyList Portuguese+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","A41441EE-BF7C-4A48-9A43-42CCEA2B2A1D"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistportuguese+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistportuguese+easylist.txt"},{"id":"EEEF75EC-B2B4-49F4-BC49-17B08266F334","type":"ads","languages":["ro"],"title":"ROList+EasyList","homepage":"https://zoso.ro/rolist/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","99166908-5FDA-4F9E-8C4C-70BB4DEEFC08"],"url":"https://easylist-downloads.adblockplus.org/v3/full/rolist+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/rolist+easylist.txt"},{"id":"1B5F78CA-8B30-4BDF-B0A3-451CB2202984","type":"ads","languages":["ru","uk"],"title":"RU AdList+EasyList","homepage":"https://forums.lanik.us/viewforum.php?f=102","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","879ECB9D-8935-4506-939E-5BBB7DD09402"],"url":"https://easylist-downloads.adblockplus.org/v3/full/ruadlist+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/ruadlist+easylist.txt"},{"id":"1C571EC7-6E52-47CC-B04A-4B3008D0AEBE","type":"ads","languages":["vi"],"title":"ABPVN List+EasyList","homepage":"http://abpvn.com/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","03648752-31EE-4FD0-85C1-20B07C5551C3"],"url":"https://easylist-downloads.adblockplus.org/v3/full/abpvn+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/abpvn+easylist.txt"},{"id":"9BD3EA2F-889D-4CC3-B680-CF484F2BD1B9","type":"ads","languages":["zh"],"title":"EasyList China+EasyList","homepage":"https://github.com/easylist/easylistchina/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","1D7F590C-B752-4BA0-9473-6A26DE1326B1"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistchina+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistchina+easylist.txt"},{"id":"0798B6A2-94A4-4ADF-89ED-BEC112FC4C7F","type":"allowing","title":"Allow nonintrusive advertising","homepage":"https://acceptableads.com/","url":"https://easylist-downloads.adblockplus.org/v3/full/exceptionrules.txt","mv2_url":"https://easylist-downloads.adblockplus.org/exceptionrules.txt"},{"id":"F12E0801-A00B-49DE-B1E3-52C9C4F90C8C","type":"allowing","title":"Allow nonintrusive advertising without third-party tracking","homepage":"https://acceptableads.com/","url":"https://easylist-downloads.adblockplus.org/v3/full/exceptionrules-privacy-friendly.txt","mv2_url":"https://easylist-downloads.adblockplus.org/exceptionrules-privacy-friendly.txt"},{"id":"D5561090-9ADB-4EEE-AA81-101B645D9F4F","type":"newsletters","title":"DistractionControl-Newsletter","homepage":"https://help.getadblock.com/support/home","url":"https://easylist-downloads.adblockplus.org/v3/full/distraction-control-newsletter.txt","mv2_url":"https://cdn.adblockcdn.com/filters/distraction-control-newsletter.txt"},{"id":"3B85CD3F-553A-45D1-AA38-6288E1C4C7B9","type":"notifications","title":"DistractionControl-Push","homepage":"https://help.getadblock.com/support/home","url":"https://easylist-downloads.adblockplus.org/v3/full/distraction-control-push.txt","mv2_url":"https://cdn.adblockcdn.com/filters/distraction-control-push.txt"},{"id":"1E7A240E-CD85-493D-BEEF-C68A6AEA1225","type":"surveys","title":"DistractionControl-Survey","homepage":"https://help.getadblock.com/support/home","url":"https://easylist-downloads.adblockplus.org/v3/full/distraction-control-survey.txt","mv2_url":"https://cdn.adblockcdn.com/filters/distraction-control-survey.txt"},{"id":"8E2D687A-3B44-46E1-BE68-2FE5441A788E","type":"videos","title":"DistractionControl-Video","homepage":"https://help.getadblock.com/support/home","url":"https://easylist-downloads.adblockplus.org/v3/full/distraction-control-video.txt","mv2_url":"https://cdn.adblockcdn.com/filters/distraction-control-video.txt"},{"id":"D4028CDD-3D39-4624-ACC7-8140F4EC3238","type":"circumvention","title":"ABP filters","homepage":"https://github.com/abp-filters/abp-filters-anti-cv","url":"https://easylist-downloads.adblockplus.org/v3/full/abp-filters-anti-cv.txt","mv2_url":"https://easylist-downloads.adblockplus.org/abp-filters-anti-cv.txt"},{"id":"2090F374-29D9-4202-B2CE-139D6492D95E","type":"cookies","title":"I don\'t care about cookies","homepage":"https://www.i-dont-care-about-cookies.eu/","url":"https://easylist-downloads.adblockplus.org/v3/full/i_dont_care_about_cookies.txt","mv2_url":"https://easylist-downloads.adblockplus.org/i_dont_care_about_cookies.txt"},{"id":"5BD2BB73-459D-4A74-AF9D-A10157268350","type":"notifications","title":"Fanboy\'s Notifications Blocking List","homepage":"https://easylist.to/","url":"https://easylist-downloads.adblockplus.org/v3/full/fanboy-notifications.txt","mv2_url":"https://easylist-downloads.adblockplus.org/fanboy-notifications.txt"},{"id":"D72B6F06-52B2-4FED-96A2-1BF59CDD7AEC","type":"privacy","title":"EasyPrivacy","homepage":"https://easylist.to/","requires":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easyprivacy.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easyprivacy.txt"},{"id":"0A679439-445F-4DE7-84B9-88341F6DA520","type":"social","title":"Fanboy\'s Social Blocking List","homepage":"https://easylist.to/","url":"https://easylist-downloads.adblockplus.org/v3/full/fanboy-social.txt","mv2_url":"https://easylist-downloads.adblockplus.org/fanboy-social.txt"},{"id":"0B0296EB-1CC5-49CD-AD38-8AF27420B7E4","type":"annoyances","title":"Fanboy\'s Annoyance List","homepage":"https://easylist.to/","url":"https://easylist-downloads.adblockplus.org/v3/full/fanboy-annoyance.txt","mv2_url":"https://secure.fanboy.co.nz/fanboy-annoyance.txt"},{"id":"9CC3AF4D-EB89-4100-97C6-4EEE4F8A2E82","type":"cryptomining","title":"NoCoin Filter List","homepage":"https://github.com/hoshsadiq/adblock-nocoin-list/","url":"https://easylist-downloads.adblockplus.org/v3/full/nocoin.txt","mv2_url":"https://raw.githubusercontent.com/hoshsadiq/adblock-nocoin-list/master/nocoin.txt"}]');
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/messaging/port.js
var port = __webpack_require__(4554);
// EXTERNAL MODULE: ./adblock-betafish/telemetry/background/index.js + 4 modules
var background = __webpack_require__(158);
;// CONCATENATED MODULE: ./adblock-betafish/alias/subscriptionInit.js
/** @module adblock-betafish/alias/subscriptionInit */

/** similar to adblockpluschrome\lib\subscriptionInit.js */

/** @module subscriptionInit */








let firstRun;
let reinitialized = false;
let dataCorrupted = false;

/**
 * If there aren't any filters, the default subscriptions are added.
 * However, if patterns.ini already did exist and/or any preference
 * is set to a non-default value, this indicates that this isn't the
 * first run, but something went wrong.
 *
 * This function detects the first run, and makes sure that the user
 * gets notified (on the first run page) if the data appears incomplete
 * and therefore will be reinitialized.
 */
async function detectFirstRun(foundSubscriptions, foundStorage) {
  let userFilters = await ewe_api.filters.getUserFilters();
  firstRun = !foundSubscriptions && !userFilters.length;

  if (firstRun && (foundStorage || prefs/* Prefs.currentVersion */.B.currentVersion))
    reinitialized = true;

  prefs/* Prefs.currentVersion */.B.currentVersion = info_chrome_js.addonVersion;
}

/**
 * In case of data corruption, we don't want to show users
 * any non-essential notifications so we need to instruct
 * the notification manager to ignore them.
 *
 * @param {boolean} value
 */
function setDataCorrupted(value) {
  dataCorrupted = value;
  ewe_api.notifications.ignored = value;
}

/*
 * Remove any subscriptions that a user or administrator has added to a
 * central / common configuration (such as the Windows Registry)
 *
 * @return {Promise}
 */

function removeSubscriptions() {
  return new Promise(function (resolve, reject) {
    if ("managed" in browser.storage) {
      browser.storage.managed.get(null).then(
        async (items) => {
          for (let key in items) {
            if (key === "remove_subscriptions" && Array.isArray(items[key]) && items[key].length) {
              for (let inx = 0; inx < items[key].length; inx++) {
                await ewe_api.subscriptions.remove(items[key][inx]);
              }
            }
          }
          resolve();
        },

        // Opera doesn't support browser.storage.managed, but instead of simply
        // removing the API, it gives an asynchronous error which we ignore here.
        () => {
          resolve();
        }
      );
    } else {
      resolve();
    }
  });
}


async function openInstalled() {
  const userID = await background/* TELEMETRY.untilLoaded */.C.untilLoaded();
  browser.tabs.create({
    url:
      "https://getadblock.com/installed/?u=" +
      userID +
      "&lg=" +
      browser.i18n.getUILanguage() +
      "&dc=" +
      dataCorrupted
  });
}


async function addSubscriptions() {
  if (firstRun || reinitialized) {
    await ewe_api.subscriptions.addDefaults();
  }
  // Remove "acceptable ads" if Gecko
  if (firstRun) {
    for (let url of prefs/* Prefs.additional_subscriptions */.B.additional_subscriptions) {
      try {
        await ewe_api.subscriptions.add(url);
      }
      catch (ex) {
        console.error(`Failed to add additional subscription: ${url}`);
      }
    }
    if (info_chrome_js.platform === "gecko") {
      try {
        await ewe_api.subscriptions.remove(ewe_api.subscriptions.ACCEPTABLE_ADS_URL);
      }
      catch (ex) {
        console.error(`Failed to remove AA subscription`);
      }
    }
  }

  // Show first run page or the updates page. The latter is only shown
  // on Chromium (since the current updates page announces features that
  // aren't new to Firefox users), and only if this version of the
  // updates page hasn't been shown yet.

  if (firstRun && !prefs/* Prefs.suppress_first_run_page */.B.suppress_first_run_page) {
    // Always show the first run page if a data corruption was detected
    // (either through failure of reading from or writing to storage.local).
    // The first run page could notify the user about the data corruption.
    if (firstRun || dataCorrupted) {
      openInstalled();
    }
  }
}

/**
 * We need to check whether we can safely write to/read from storage
 * before we start relying on it for storing preferences.
 */
async function testStorage() {
  let testKey = "readwrite_test";
  let testValue = Math.random();

  try {
    await browser.storage.local.set({ [testKey]: testValue });
    let result = await browser.storage.local.get(testKey);
    if (result[testKey] != testValue)
      throw new Error("Storage test: Failed to read and write value");
  } finally {
    await browser.storage.local.remove(testKey);
  }
}

const initialize = ewe_api.start({
  bundledSubscriptions: adblock_namespaceObject,
  name: info_chrome_js.addonName,
  version: info_chrome_js.addonVersion,
  bundledSubscriptionsPath: "/data/rules/abp",
}).then(async (eweFirstRun) => {
  eweFirstRun.warnings.forEach(console.warn);
  await prefs/* Prefs.untilLoaded.catch */.B.untilLoaded["catch"](() => { setDataCorrupted(true); });
  await testStorage().catch(() => { setDataCorrupted(true); })
  await detectFirstRun(
    eweFirstRun.foundSubscriptions,
    eweFirstRun.foundStorage
  );
  // adding default filter lists
  await addSubscriptions();
  await removeSubscriptions();
});


/**
 * Gets a value indicating whether a data corruption was detected.
 *
 * @return {boolean}
 */
function isDataCorrupted() {
  return dataCorrupted;
}




/**
 * @typedef {object} subscriptionsGetInitIssuesResult
 * @property {boolean} dataCorrupted
 *   true if it appears that the user's extension data was corrupted.
 * @property {boolean} reinitialized
 *   true if we have reset the user's settings due to data corruption.
 */

/**
 * Returns an Object with boolean flags for any subscription initialization
 * issues.
 *
 * @event "subscriptions.getInitIssues"
 * @returns {subscriptionsGetInitIssuesResult}
 */
port/* port.on */.N.on("subscriptions.getInitIssues", (message, sender) => ({ dataCorrupted, reinitialized }));


/***/ }),

/***/ 9192:
/***/ ((__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony import */ var _servermessages__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1546);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3817);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2028);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global */





const authorizedKeys = [
  `MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAuePfbm865kumeftXjlbt
J68DTXLTn0VeOgdSTqOcpADVqH0Kxz5hfLMaoKC/QhO3SmAu1yZwJZ1WP9Uyu3I5
EvJwEt7OHjJv54GhyYCtylMDCqSZgIIkUtB9PSXqFe3qyKAXACzwnLHmYIMMC1rx
bViqMD06+S4NKtzEh602/JsOOTHkXDJFQi5gGpd7Yn/r1YFG20JzU5lr0pf3dOEK
gNXiEwSRCuVSZ2+MHMtkFdP83/k59rTOfz5+ZThYmxECytD0JyY+bpDbso/XxQeL
fThNEEnSpbbeJRZQM5Lwf4D/f1wzSvyRrQiQz6Bo6TrA9DpL/BHqgUBv4O+DwhAu
8tFaaI+YWUmA1M6DRCL1aPQlFf3RB+aAf/TXFRU6enm8y/DFKWnwZja1YlApxTYT
MGnZ5hrsXZZImjcKBKwXi3JCtLkfV+osAHYrMAJPPAfECkch/ovrEUcdBEu4WsJ+
gKlL2C1/ZL+fTZc+H9qt38qba8my5XlQmhXmzXFKKyp+1pqNkQuYzzT0M8PUqtlh
z5aNu4gc/sOrQayusssUkkwISWm9yKc9pwOE+2Ax45iq2xNhjx0+rl9nc/chV21T
ZLfyePid/4N3Q7obmQ9a6trOBIF5ONyg16CK61RjacnG76AMKrVOoq9lzF2UufL8
Myzw9X8Wsw3VrjJyYbWhUtkCAwEAAQ==`,
  `MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAwWP4dO4iYcHpcO6lVmjC
gg/jfLM4fP+wWNaoDvMke0gQ7m9smXVtgbYXb6qzEd0aDaCRX3em+eo6bWp6ps5U
+8USRxuNH4cs6ZLjGynmZnm2TXrJScixUEw4ULq8Rdexr4ZmtT1WfUjJSFQpWWwp
e69kVR0iwwiCFRq90I/7MfJWnwgHX2tkUkVBttmXt9o0wP8th/UOIdx+0VbrqhgY
wMyo3xCUvqcSpcKsHXoLkKGlpcplE96rKg2vOqhSSQzoHMr8ZrGIn7hsPI7enVsP
D/nMiJptavVowfNZjM/rd6Iv/TYfI1JOJWUeIM+aPyhZKrvWHGdC8VO2jneNkNXj
1B6tnZy6owPt4Lgdimr0u/146WvjAL+ZK1dc4CNecOLeRINn26POCIeOpYPHGhbi
N6K1UrHpC1Oon2NW5ms9dciE242O1BrQF5j/GvNzGoV74GvnbVFZ9eyBJm9MlIOU
Sd5O2iTqWPmJ03wVSXLx+6g0fgaGHEDtKtbfhuHvDG2dIoAB7q+oKBHQJ7CIFEbI
lBnPV1v+dxDLb3DdK0Ip9wM74S2+Nf9359TCjAaWgNjiTnhBw6xpwTGn/8vzNL3p
fcEVJJt8DUfuCYV9mtKPHbj06RHnLsaXQ72x6I+ocXi8TygTjldZFx13ttJqVvju
UaTE0E4KN9Mzb/2zEYTgCzcCAwEAAQ==`,
];

_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.allowlisting.setAuthorizedKeys(authorizedKeys);

async function onAllowlisting(domain) {
  await _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.filters.add([`@@||${domain}^$document`], (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_2__/* .createFilterMetaData */ .Yv)('web'));
}
_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.allowlisting.setAllowlistingCallback(onAllowlisting);

_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.allowlisting.onUnauthorized.addListener((error) => {
  _servermessages__WEBPACK_IMPORTED_MODULE_0__/* ["default"].recordErrorMessage */ .Z.recordErrorMessage('one_click_allowlisting_error ', undefined, { errorMessage: error.toString() });
  // eslint-disable-next-line no-console
  console.error(error);
});


/***/ }),

/***/ 4590:
/***/ ((__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";

// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/prefs.js
var prefs = __webpack_require__(8710);
// EXTERNAL MODULE: ./build/templates/info.chrome.js.tmpl
var info_chrome_js = __webpack_require__(187);
// EXTERNAL MODULE: ./vendor/webext-sdk/dist/ewe-api.js
var ewe_api = __webpack_require__(3817);
// EXTERNAL MODULE: ./adblock-betafish/telemetry/background/index.js + 4 modules
var background = __webpack_require__(158);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/stats.js
var stats = __webpack_require__(9892);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/allowlisting.js
var allowlisting = __webpack_require__(8858);
// EXTERNAL MODULE: ./adblock-betafish/alias/subscriptionInit.js + 1 modules
var subscriptionInit = __webpack_require__(8910);
// EXTERNAL MODULE: ./adblock-betafish/picreplacement/sync-service.js
var sync_service = __webpack_require__(8409);
// EXTERNAL MODULE: ./adblock-betafish/subscriptionadapter.js + 1 modules
var subscriptionadapter = __webpack_require__(934);
// EXTERNAL MODULE: ./adblock-betafish/datacollection.v2.js
var datacollection_v2 = __webpack_require__(5175);
// EXTERNAL MODULE: ./adblock-betafish/ctaabmanager.js
var ctaabmanager = __webpack_require__(1064);
// EXTERNAL MODULE: ./adblock-betafish/alias/icon.js
var icon = __webpack_require__(1021);
// EXTERNAL MODULE: ./adblock-betafish/localdatacollection.js
var localdatacollection = __webpack_require__(1120);
// EXTERNAL MODULE: ./adblock-betafish/picreplacement/check.js
var check = __webpack_require__(1177);
// EXTERNAL MODULE: ./adblock-betafish/servermessages.js
var servermessages = __webpack_require__(1546);
// EXTERNAL MODULE: ./adblock-betafish/survey.js + 1 modules
var survey = __webpack_require__(7877);
;// CONCATENATED MODULE: ./adblock-betafish/alias/uninstall.js
/** @module uninstall */
/** similar to adblockpluschrome\lib\uninstall.js */





/**
 * Returns the number of currently active filters that have been added using
 * the experimental allowlisting functionality (i.e. that originated in the
 * web, and not in the extension popup).
 *
 * @returns {number} The filter count
 */
async function getWebAllowlistingFilterCount() {
  // get all allowlisting filters that are enabled
  const filters = (await ewe.filters.getUserFilters()).filter(
    filter => filter.type === "allowing" && filter.enabled
  );

  // collect their metadata
  const filtersMetadata = await Promise.all(
    filters.map(async filter => await ewe.filters.getMetadata(filter.text))
  );

  // count the ones that originated in the web
  return filtersMetadata.filter(data => data.origin === "web").length;
}

async function setUninstallURL() {
  if (browser.runtime.setUninstallURL) {
    const userID = await background/* TELEMETRY.untilLoaded */.C.untilLoaded();
    let uninstallURL = "https://getadblock.com/uninstall/?u=" + userID;
    // if the start property of blockCount exists (which is the AdBlock
    // installation timestamp)
    // use it to calculate the approximate length of time that user has
    // AdBlock installed
    if (prefs/* Prefs */.B && prefs/* Prefs.blocked_total */.B.blocked_total !== undefined) {
      let twoMinutes = 2 * 60 * 1000;
      let getLastUpdateTime = async function () {
        const userSubs = await subscriptionadapter/* default.getSubscriptionsMinusText */.Z.getSubscriptionsMinusText();
        let maxLastDownload = -1;
        for (const sub in userSubs) {
          if (userSubs[sub].lastSuccess > maxLastDownload) {
            maxLastDownload = userSubs[sub].lastSuccess;
          }
        }
        return maxLastDownload;
      };
      let updateUninstallURL = async function () {
        const data = await browser.storage.local.get("blockage_stats");
        let url = uninstallURL;
        if (data && data.blockage_stats && data.blockage_stats.start) {
          let installedDuration = Date.now() - data.blockage_stats.start;
          url = url + "&t=" + installedDuration;
        }
        let bc = prefs/* Prefs.blocked_total */.B.blocked_total;
        url = url + "&bc=" + bc;
        let lastUpdateTime = await getLastUpdateTime();
        url = url + "&lt=" + lastUpdateTime;
        url += `&wafc=${await getWebAllowlistingFilterCount()}`;
        browser.runtime.setUninstallURL(url);
      };
      // start an interval timer that will update the Uninstall URL every 2
      // minutes
      setInterval(updateUninstallURL, twoMinutes);
      updateUninstallURL();
    } else {
      browser.runtime.setUninstallURL(uninstallURL + "&t=-1");
    }
  }
};

// EXTERNAL MODULE: ./adblock-betafish/utilities/background/bg-functions.js
var bg_functions = __webpack_require__(2028);
;// CONCATENATED MODULE: ./adblock-betafish/background.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, License,
   gabQuestion, ext, getSettings, setSetting, settings
   parseFilter, channels, twitchChannelNamePages, ytChannelNamePages,
   updateButtonUIAndContextMenus,  */
























// Message verification
const trustedBaseUrl = browser.runtime.getURL('');
const gabHostnames = ['https://getadblock.com', 'https://dev.getadblock.com', 'https://dev1.getadblock.com', 'https://dev2.getadblock.com', 'https://vpn.getadblock.com', 'https://help.getadblock.com'];

const isTrustedSender = sender => sender.url.startsWith(trustedBaseUrl);

const isTrustedTarget = url => (url.startsWith(trustedBaseUrl)
  || gabHostnames.includes(new URL(url).origin));

const isTrustedSenderDomain = (sender) => {
  if (sender.origin) {
    return gabHostnames.includes(sender.origin);
  }
  if (sender.url) {
    return gabHostnames.includes(new URL(sender.url).origin);
  }
  return false;
};
const adblocBetaID = 'pljaalgmajnlogcgiohkhdmgpomjcihk';

// eslint-disable-next-line no-restricted-globals
Object.assign(self, {
  Prefs: prefs/* Prefs */.B,
  info: info_chrome_js,
  getBlockedPerPage: stats/* getBlockedPerPage */.G,
  SURVEY: survey/* default */.Z,
  SyncService: sync_service["default"],
  LocalDataCollection: localdatacollection/* default */.Z,
  ServerMessages: servermessages/* default */.Z,
  SubscriptionAdapter: subscriptionadapter/* default */.Z,
  TELEMETRY: background/* TELEMETRY */.C,
  IPM: background/* IPM */.fp,
  DataCollectionV2: datacollection_v2/* default */.Z,
  CtaABManager: ctaabmanager/* default */.Z,
  getNewBadgeTextReason: icon/* getNewBadgeTextReason */.vo,
  ewe: ewe_api,
  License: check/* License */.Cz,
  channels: check/* channels */.ZW,
  isTrustedSender,
  isTrustedTarget,
  isTrustedSenderDomain,
});

// CUSTOM FILTERS

const isSelectorFilter = function (text) {
  // This returns true for both hiding rules as hiding whitelist rules
  // This means that you'll first have to check if something is an excluded rule
  // before checking this, if the difference matters.
  return /#@?#./.test(text);
};

// custom filter countCache singleton.
const countCache = (function countCache() {
  let cache;

  // Update custom filter count stored in storage
  const updateCustomFilterCount = function () {
    (0,bg_functions/* chromeStorageSetHelper */.rJ)('custom_filter_count', cache);
  };

  return {
    // Update custom filter count cache and value stored in storage.
    // Inputs: new_count_map:count map - count map to replace existing count
    // cache
    updateCustomFilterCountMap(newCountMap) {
      cache = newCountMap || cache;
      updateCustomFilterCount();
    },

    // Remove custom filter count for host
    // Inputs: host:string - url of the host
    removeCustomFilterCount(host) {
      if (host && cache[host]) {
        delete cache[host];
        updateCustomFilterCount();
      }
    },

    // Get current custom filter count for a particular domain
    // Inputs: host:string - url of the host
    getCustomFilterCount(host) {
      let customCount = 0;
      if (cache) {
        customCount = cache[host];
      }
      return customCount || 0;
    },

    // Add 1 to custom filter count for the filters domain.
    // Inputs: filter:string - line of text to be added to custom filters.
    addCustomFilterCount(filter) {
      const host = filter.split('##')[0];
      cache[host] = this.getCustomFilterCount(host) + 1;
      updateCustomFilterCount();
    },

    init() {
      browser.storage.local.get('custom_filter_count').then((response) => {
        cache = response.custom_filter_count || {};
      });
    },
  };
}());
countCache.init();

// Add a new custom filter entry.
// Inputs: filter:string - line of text to add to custom filters.
//         origin:string - the source or trigger for the filter list entry
// Returns: null if succesfull, otherwise an exception
const addCustomFilter = async function (filterText, origin) {
  try {
    const response = ewe_api.filters.validate(filterText);
    if (response) {
      return response;
    }
    await ewe_api.filters.add([filterText], (0,bg_functions/* createFilterMetaData */.Yv)(origin));
    await ewe_api.filters.enable([filterText]);
    if (isSelectorFilter(filterText)) {
      countCache.addCustomFilterCount(filterText);
    }
    return null;
  } catch (ex) {
    // convert to a string so that Safari can pass
    // it back to content scripts
    return ex.toString();
  }
};

// Creates a custom filter entry that allowlists a given domain
// Inputs: pageUrl:string - url of the page
//         origin:string - the source or trigger for the filter list entry
// Returns: null if successful, otherwise an exception
const createDomainAllowlistFilter = async function (pageUrl, origin) {
  const theURL = new URL(pageUrl);
  const host = theURL.hostname.replace(/^www\./, '');
  const filter = `@@||${host}/*^$document`;
  return addCustomFilter(filter, origin);
};

// UNWHITELISTING

async function getUserFilters() {
  return ewe_api.filters.getUserFilters();
}

const isWhitelistFilter = function (text) {
  return /^@@/.test(text);
};

// Look for a custom filter that would whitelist the 'url' parameter
// and if any exist, remove the first one.
// Inputs: url:string - a URL that may be allowlisted by a custom filter
//         tabId: integer - tab id of the tab that may be allowlisted by a custom filter
// Returns: true if a filter was found and removed; false otherwise.
const tryToUnwhitelist = async function (pageUrl, tabId) {
  const url = pageUrl.replace(/#.*$/, ''); // Whitelist ignores anchors
  const customFilters = await getUserFilters();
  if (!customFilters || !customFilters.length === 0) {
    return false;
  }

  /* eslint-disable no-await-in-loop */
  for (let i = 0; i < customFilters.length; i++) {
    const { text } = customFilters[i];
    const whitelist = text.search(/@@\*\$document,domain=~/);
    // Blacklist site, which is whitelisted by global @@*&document,domain=~
    // filter
    if (whitelist > -1) {
      // Remove protocols
      const [finalUrl] = url.replace(/((http|https):\/\/)?(www.)?/, '').split(/[/?#]/);
      await ewe_api.filters.remove([text]);
      await ewe_api.filters.remove([`${text}|~${finalUrl}`]);
      return true;
    }
    if (isWhitelistFilter(text) && (await ewe_api.filters.getAllowingFilters(tabId)).includes(text)) {
      await ewe_api.filters.remove([text]);
      return true;
    }
  }
  return false;
};

// Removes a custom filter entry.
// Inputs: host:domain of the custom filters to be reset.
const removeCustomFilter = async function (host) {
  const customFilters = await getUserFilters();
  if (!customFilters || !customFilters.length === 0) {
    return;
  }

  const identifier = host;

  for (let i = 0; i < customFilters.length; i++) {
    const entry = customFilters[i];
    // If the identifier is at the start of the entry
    // then delete it.
    if (entry.text.indexOf(identifier) === 0) {
      ewe_api.filters.remove([entry.text]);
    }
  }
};

// Entry point for customize.js, used to update custom filter count cache.
const updateCustomFilterCountMap = function (newCountMap) {
  // Firefox passes weak references to objects, so we need a local copy
  const localCountMap = JSON.parse(JSON.stringify(newCountMap));
  countCache.updateCustomFilterCountMap(localCountMap);
};

const removeCustomFilterForHost = function (host) {
  if (countCache.getCustomFilterCount(host)) {
    removeCustomFilter(host);
    countCache.removeCustomFilterCount(host);
  }
};

// Currently, Firefox doesn't allow the background page to use alert() or confirm(),
// so some JavaScript is injected into the active tab, which does the confirmation for us.
// If the user confirms the removal of the entries, then they are removed, and the page reloaded.
const confirmRemovalOfCustomFiltersOnHost = function (host, activeTabId) {
  const customFilterCount = countCache.getCustomFilterCount(host);
  const confirmationText = browser.i18n.getMessage('confirm_undo_custom_filters', [customFilterCount, host]);
  const messageListenerFN = function (request) {
    browser.runtime.onMessage.removeListener(messageListenerFN);
    if (request === `remove_custom_filters_on_host${host}:true`) {
      removeCustomFilterForHost(host);
      browser.tabs.reload(activeTabId);
    }
  };

  browser.runtime.onMessage.addListener(messageListenerFN);
  /* eslint-disable prefer-template */
  const codeToExecute = 'var host = "' + host + '"; var confirmResponse = confirm("' + confirmationText + '"); browser.runtime.sendMessage("remove_custom_filters_on_host" + host + ":" + confirmResponse); ';
  const details = { allFrames: false, code: codeToExecute };
  browser.tabs.executeScript(activeTabId, details);
};
browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
  if (message.command !== 'confirmRemovalOfCustomFiltersOnHost' || !message.host || !message.activeTabId) {
    return;
  }
  confirmRemovalOfCustomFiltersOnHost(message.host, message.activeTabId);
  sendResponse({});
});

// Reload already opened tab
// Input:
// id: integer - id of the tab which should be reloaded
const reloadTab = function (id, callback) {
  let tabId = id;
  const localCallback = callback;
  const listener = function (updatedTabId, changeInfo, tab) {
    if (changeInfo.status === 'complete' && tab.status === 'complete') {
      setTimeout(() => {
        browser.tabs.sendMessage(updatedTabId, { command: 'reloadcomplete' });
        if (typeof localCallback === 'function') {
          localCallback(tab);
        }
        browser.tabs.onUpdated.removeListener(listener);
      }, 2000);
    }
  };

  if (typeof tabId === 'string') {
    tabId = parseInt(tabId, 10);
  }
  browser.tabs.onUpdated.addListener(listener);
  browser.tabs.reload(tabId, { bypassCache: true });
};

const isSelectorExcludeFilter = function (text) {
  return /#@#./.test(text);
};

const getAdblockUserId = function () {
  return background/* TELEMETRY.userId */.C.userId;
};

// INFO ABOUT CURRENT PAGE

// Returns true if the url cannot be blocked
const pageIsUnblockable = function (url) {
  if (!url) { // Protect against empty URLs - e.g. Safari empty/bookmarks/top sites page
    return true;
  }
  let scheme = '';
  if (!url.protocol) {
    scheme = (0,bg_functions/* parseUri */.he)(url).protocol;
  } else {
    scheme = url.protocol;
  }

  return (scheme !== 'http:' && scheme !== 'https:' && scheme !== 'feed:');
};

// Returns true if the page is whitelisted.
// Called from a content script
const pageIsWhitelisted = async function (page) {
  const whitelisted = !!await ewe_api.filters.getAllowingFilters(page.id).length;
  return (whitelisted !== undefined && whitelisted !== null);
};

const pausedKey = 'paused';
// white-list all blocking requests regardless of frame / document, but still allows element hiding
const pausedFilterText1 = '@@*';
// white-list all documents, which prevents element hiding
const pausedFilterText2 = '@@*$document';

// Get or set if AdBlock is paused
// Inputs: newValue (optional boolean): if true, AdBlock will be paused, if
// false, AdBlock will not be paused.
// Returns: undefined if newValue was specified, otherwise it returns true
// if paused, false otherwise.
const adblockIsPaused = function (newValue) {
  if (newValue === undefined) {
    return ((0,bg_functions/* sessionStorageGet */.E_)(pausedKey) === true);
  }

  if (newValue === true) {
    (0,bg_functions/* chromeStorageSetHelper */.rJ)(pausedKey, true, () => {
      ewe_api.filters.add([pausedFilterText1]);
      ewe_api.filters.add([pausedFilterText2]);
    });
  } else {
    ewe_api.filters.remove([pausedFilterText1]);
    ewe_api.filters.remove([pausedFilterText2]);
    browser.storage.local.remove(pausedKey);
  }
  (0,bg_functions/* sessionStorageSet */.bg)(pausedKey, newValue);
  return undefined;
};

const domainPausedKey = 'domainPaused';

// Helper that saves the domain pauses
// Inputs:  domainPauses (required object): domain pauses to save
// Returns: undefined
const saveDomainPauses = function (domainPauses) {
  (0,bg_functions/* chromeStorageSetHelper */.rJ)(domainPausedKey, domainPauses);
  (0,bg_functions/* sessionStorageSet */.bg)(domainPausedKey, domainPauses);
};

// Helper that removes any domain pause filter rules based on tab events
// Inputs:  tabId (required integer): identifier for the affected tab
//          newDomain (optional string): the current domain of the tab
// Returns: undefined
const domainPauseChangeHelper = function (tabId, newDomain) {
  // get stored domain pauses
  const storedDomainPauses = (0,bg_functions/* sessionStorageGet */.E_)(domainPausedKey);

  // check if any of the stored domain pauses match the affected tab
  for (const aDomain in storedDomainPauses) {
    if (storedDomainPauses[aDomain] === tabId && aDomain !== newDomain) {
      // Remove the filter that white-listed the domain
      ewe_api.filters.remove([`@@${aDomain}$document`]);
      delete storedDomainPauses[aDomain];

      // save updated domain pauses
      saveDomainPauses(storedDomainPauses);
    }
  }
  updateButtonUIAndContextMenus();
};

// Handle the effects of a tab update event on any existing domain pauses
// Inputs:  tabId (required integer): identifier for the affected tab
//          changeInfo (required object with a url property): contains the
// new url for the tab
//          tab (optional Tab object): the affected tab
// Returns: undefined
const domainPauseNavigationHandler = function (tabId, changeInfo) {
  if (changeInfo === undefined || changeInfo.url === undefined || tabId === undefined) {
    return;
  }

  const newDomain = (0,bg_functions/* parseUri */.he)(changeInfo.url).host;

  domainPauseChangeHelper(tabId, newDomain);
};

// Handle the effects of a tab remove event on any existing domain pauses
// Inputs:  tabId (required integer): identifier for the affected tab
//          changeInfo (optional object): info about the remove event
// Returns: undefined
const domainPauseClosedTabHandler = function (tabId) {
  if (tabId === undefined) {
    return;
  }

  domainPauseChangeHelper(tabId);
};

// Get or set if AdBlock is domain paused for the domain of the specified tab
// Inputs:  activeTab (optional object with url and id properties): the paused tab
//          newValue (optional boolean): if true, AdBlock will be domain paused
// on the tab's domain, if false, AdBlock will not be domain paused on that domain.
// Returns: undefined if activeTab and newValue were specified; otherwise if activeTab
// is specified it returns true if domain paused, false otherwise; finally it returns
// the complete storedDomainPauses if activeTab is not specified

const adblockIsDomainPaused = function (activeTab, newValue) {
  // get stored domain pauses
  let storedDomainPauses = (0,bg_functions/* sessionStorageGet */.E_)(domainPausedKey);

  // return the complete list of stored domain pauses if activeTab is undefined
  if (activeTab === undefined) {
    return storedDomainPauses;
  }

  // return a boolean indicating whether the domain is paused if newValue is undefined
  const activeDomain = (0,bg_functions/* parseUri */.he)(activeTab.url).host;
  if (newValue === undefined) {
    if (storedDomainPauses) {
      return Object.prototype.hasOwnProperty.call(storedDomainPauses, activeDomain);
    }
    return false;
  }

  // create storedDomainPauses object if needed
  if (!storedDomainPauses) {
    storedDomainPauses = {};
  }

  // set or delete a domain pause
  if (newValue === true) {
    // add a domain pause
    ewe_api.filters.add([`@@${activeDomain}$document`]);
    storedDomainPauses[activeDomain] = activeTab.id;
    browser.tabs.onUpdated.removeListener(domainPauseNavigationHandler);
    browser.tabs.onRemoved.removeListener(domainPauseClosedTabHandler);
    browser.tabs.onUpdated.addListener(domainPauseNavigationHandler);
    browser.tabs.onRemoved.addListener(domainPauseClosedTabHandler);
  } else {
    // remove the domain pause
    ewe_api.filters.remove([`@@${activeDomain}$document`]);
    delete storedDomainPauses[activeDomain];
  }

  // save the updated list of domain pauses
  saveDomainPauses(storedDomainPauses);
  return undefined;
};

// If AdBlock was paused on shutdown (adblock_is_paused is true), then
// unpause / remove the white-list all entry at startup.
browser.storage.local.get(pausedKey).then((response) => {
  if (response[pausedKey]) {
    subscriptionInit/* initialize.then */.j.then(() => {
      ewe_api.filters.remove([pausedFilterText1]);
      ewe_api.filters.remove([pausedFilterText2]);
      browser.storage.local.remove(pausedKey);
    });
  }
});


// If AdBlock was domain paused on shutdown, then unpause / remove
// all domain pause white-list entries at startup.
browser.storage.local.get(domainPausedKey).then((response) => {
  const storedDomainPauses = response[domainPausedKey];
  if (!(0,bg_functions/* isEmptyObject */.Qr)(storedDomainPauses)) {
    subscriptionInit/* initialize.then */.j.then(() => {
      for (const aDomain in storedDomainPauses) {
        ewe_api.filters.remove([`@@${aDomain}$document`]);
      }
      browser.storage.local.remove(domainPausedKey);
    });
  }
});

browser.commands.onCommand.addListener((command) => {
  if (command === 'toggle_pause') {
    adblockIsPaused(!adblockIsPaused());
    servermessages/* default.recordGeneralMessage */.Z.recordGeneralMessage('pause_shortcut_used');
  }
});

const getTab = function (tabId) {
  return new Promise((resolve) => {
    if (tabId) {
      let id = tabId;
      if (typeof id === 'string') {
        id = parseInt(id, 10);
      }
      browser.tabs.get(id).then((tab) => {
        resolve(tab);
      });
    } else {
      browser.tabs.query({
        active: true,
        lastFocusedWindow: true,
      }).then((tabs) => {
        if (tabs.length === 0) {
          resolve(); // For example: only the background devtools or a popup are opened
        }
        resolve(tabs[0]);
      });
    }
  });
};


// Get interesting information about the current tab.
// Inputs:
// secondTime: bool - whether this is a recursive call
// info object passed to resolve: {
// page: Page object
// tab: Tab object
// whitelisted: bool - whether the current tab's URL is whitelisted.
// disabled_site: bool - true if the url is e.g. about:blank or the
// Extension Gallery, where extensions don't run.
// settings: Settings object
// paused: bool - whether AdBlock is paused
// domainPaused: bool - whether the current tab's URL is paused
// blockCountPage: int - number of ads blocked on the current page
// blockCountTotal: int - total number of ads blocked since install
// customFilterCount: int - number of custom rules for the current tab's URL
// showMABEnrollment: bool - whether to show MAB enrollment
// popupMenuThemeCTA: string - name of current popup menu CTA theme
// lastGetStatusCode: int - status code for last GET request
// lastGetErrorResponse: error object - error response for last GET request
// lastPostStatusCode: int - status code for last POST request
// allowlistRuleText: string - allowlist rule text for use on YouTube and Twitch
// }
// Returns: Promise
const getCurrentTabInfo = function (secondTime, tabId) {
  return new Promise((resolve) => {
    getTab(tabId).then(async (tab) => {
      if (tab && !tab.url) {
        // Issue 6877: tab URL is not set directly after you opened a window
        // using window.open()
        if (!secondTime) {
          setTimeout(() => {
            getCurrentTabInfo(true);
          }, 250);
        }
        return resolve();
      }
      try {
        const page = new ext.Page(tab);
        const disabledSite = pageIsUnblockable(page.url.href);
        const customFilterCheckUrl = disabledSite ? undefined : page.url.hostname;

        const result = {
          disabledSite,
          url: String(page.url || tab.url),
          id: page.id,
          settings: getSettings(),
          paused: adblockIsPaused(),
          domainPaused: adblockIsDomainPaused({ url: page.url.href, id: page.id }),
          blockCountPage: await (0,stats/* getBlockedPerPage */.G)(tab),
          blockCountTotal: stats/* Stats.blocked_total */.j.blocked_total,
          customFilterCount: countCache.getCustomFilterCount(customFilterCheckUrl),
          showMABEnrollment: check/* License.shouldShowMyAdBlockEnrollment */.Cz.shouldShowMyAdBlockEnrollment(),
          popupMenuThemeCTA: check/* License.getCurrentPopupMenuThemeCTA */.Cz.getCurrentPopupMenuThemeCTA(),
          showDcCTA: check/* License.shouldShowPremiumDcCTA */.Cz.shouldShowPremiumDcCTA(),
          lastGetStatusCode: sync_service["default"].getLastGetStatusCode(),
          lastGetErrorResponse: sync_service["default"].getLastGetErrorResponse(),
          lastPostStatusCode: sync_service["default"].getLastPostStatusCode(),
          newBadgeTextReason: (0,icon/* getNewBadgeTextReason */.vo)(),
        };
        if (!disabledSite) {
          result.whitelisted = !!(await ewe_api.filters.getAllowingFilters(page.id)).length;
          result.whitelistedText = await ewe_api.filters.getAllowingFilters(page.id);
        }
        if (check/* License */.Cz && check/* License.isActiveLicense */.Cz.isActiveLicense()) {
          result.activeLicense = true;
          result.subscriptions = await subscriptionadapter/* default.getSubscriptionsMinusText */.Z.getSubscriptionsMinusText();
        }
        if (
          getSettings()
          && getSettings().youtube_channel_whitelist
          && (0,bg_functions/* parseUri */.he)(tab.url).hostname === 'www.youtube.com'
        ) {
          result.youTubeChannelName = ytChannelNamePages.get(page.id);
          // handle the odd occurence of when the  YT Channel Name
          // isn't available in the ytChannelNamePages map
          // obtain the channel name from the URL
          // for instance, when the forward / back button is clicked
          if (!result.youTubeChannelName && /ab_channel/.test(tab.url)) {
            result.youTubeChannelName = bg_functions/* parseUri.parseSearch */.he.parseSearch(tab.url).ab_channel;
          }
          if (result.youTubeChannelName) {
            result.allowlistRuleText = `@@||www.youtube.com/*${result.youTubeChannelName}|$document`;
          }
        }
        if (
          twitchChannelNamePages
          && getSettings()
          && getSettings().twitch_channel_allowlist
          && (0,bg_functions/* parseUri */.he)(tab.url).hostname === 'www.twitch.tv'
        ) {
          result.twitchChannelName = twitchChannelNamePages.get(page.id);
          if (result.twitchChannelName) {
            result.allowlistRuleText = `@@||twitch.tv/*${result.twitchChannelName}^$document`;
          }
        }
        return resolve(result);
      } catch (err) {
        return resolve({ errorStr: err.toString(), stack: err.stack, message: err.message });
      }
    });
  });
};

// BETA CODE
if (browser.runtime.id === adblocBetaID) {
  // Display beta page after each update for beta-users only
  browser.runtime.onInstalled.addListener((details) => {
    if (details.reason === 'update' || details.reason === 'install') {
      browser.tabs.create({ url: 'https://getadblock.com/beta' });
    }
  });
}

const updateStorageKey = 'last_known_version';
if (browser.runtime.id) {
  let updateTabRetryCount = 0;
  const getUpdatedURL = function () {
    const encodedVersion = encodeURIComponent('5.5.0');
    let updatedURL = `https://getadblock.com/update/${background/* TELEMETRY.flavor.toLowerCase */.C.flavor.toLowerCase()}/${encodedVersion}/?u=${background/* TELEMETRY.userId */.C.userId}`;
    updatedURL = `${updatedURL}&rt=${updateTabRetryCount}`;
    return updatedURL;
  };
  const waitForUserAction = function () {
    browser.tabs.onCreated.removeListener(waitForUserAction);
    setTimeout(() => {
      updateTabRetryCount += 1;
      // eslint-disable-next-line no-use-before-define
      openUpdatedPage();
    }, 10000); // 10 seconds
  };
  const openUpdatedPage = function () {
    const updatedURL = getUpdatedURL();
    browser.tabs.create({ url: updatedURL });
  };
  const shouldShowUpdate = function () {
    const checkQueryState = function () {
      browser.idle.queryState(30).then((state) => {
        if (state === 'active') {
          openUpdatedPage();
        } else {
          browser.tabs.onCreated.removeListener(waitForUserAction);
          browser.tabs.onCreated.addListener(waitForUserAction);
        }
      });
    };
    const checkLicense = function () {
      if (!check/* License.isActiveLicense */.Cz.isActiveLicense()) {
        checkQueryState();
      }
    };
    if (browser.management && browser.management.getSelf) {
      browser.management.getSelf().then((extensionInfo) => {
        if (extensionInfo && extensionInfo.installType !== 'admin') {
          check/* License.ready */.Cz.ready().then(checkLicense);
        }
      });
    } else {
      check/* License.ready */.Cz.ready().then(checkLicense);
    }
  };
  const slashUpdateReleases = ['5.5.0', '5.6.0'];
  // Display updated page after each update
  browser.runtime.onInstalled.addListener(async (details) => {
    let {
      last_known_version: lastKnownVersion,
    } = await browser.storage.local.get(updateStorageKey);
    if (!lastKnownVersion) {
      lastKnownVersion = localStorage.getItem(updateStorageKey);
    }
    const currentVersion = browser.runtime.getManifest().version;
    // don't open the /update page for Ukraine or Russian users.
    const shouldShowUpdateForLocale = function () {
      const language = (0,bg_functions/* determineUserLanguage */.pN)();
      return !(language && (language.startsWith('ru') || language.startsWith('uk')));
    };
    if (
      details.reason === 'update'
      && shouldShowUpdateForLocale()
      && slashUpdateReleases.includes(currentVersion)
      && !slashUpdateReleases.includes(lastKnownVersion)
      && browser.runtime.id !== adblocBetaID
    ) {
      settings.onload().then(async () => {
        if (!getSettings().suppress_update_page) {
          await background/* TELEMETRY.untilLoaded */.C.untilLoaded();
          prefs/* Prefs.untilLoaded.then */.B.untilLoaded.then(shouldShowUpdate);
        }
      });
    }
    // We want to move away from localStorage, so remove item if it exists.
    localStorage.removeItem(updateStorageKey);
    // Update version in browser.storage.local. We intentionally ignore the
    // returned promise.
    browser.storage.local.set({ [updateStorageKey]: browser.runtime.getManifest().version });
  });
}


const openTab = function (url) {
  browser.tabs.create({ url });
};

// These functions are usually only called by content scripts.

// DEBUG INFO

async function getCustomFilterMetaData() {
  const currentUserFilters = await getUserFilters();
  if (!currentUserFilters || currentUserFilters.length === 0) {
    return Promise.resolve({});
  }
  /* eslint-disable consistent-return */
  return Promise.all(
    currentUserFilters.map(async (rule) => {
      if (rule && rule.text) {
        try {
          const metaData = await ewe_api.filters.getMetadata(rule.text);
          return { text: rule.text, metaData };
        } catch {
          return { text: rule.text };
        }
      }
    }),
  );
}
const getDebugAlarmInfo = async () => {
  const response = {};
  const alarms = await browser.alarms.getAll();
  if (alarms && alarms.length > 0) {
    response['Alarm info'] = `length: ${alarms.length}`;
    for (let i = 0; i < alarms.length; i++) {
      const alarm = alarms[i];
      response[`${i} Alarm Name`] = alarm.name;
      response[`${i} Alarm Scheduled Time`] = new Date(alarm.scheduledTime).toLocaleString();
    }
  } else {
    response['No alarm info'] = 'No alarm info';
  }
  return response;
};// end of getDebugAlarmInfo()

const getDebugLicenseInfo = async () => {
  const response = {};
  if (check/* License.isActiveLicense */.Cz.isActiveLicense()) {
    response.licenseInfo = {};
    response.licenseInfo.extensionGUID = background/* TELEMETRY.userId */.C.userId;
    response.licenseInfo.licenseId = check/* License.get */.Cz.get().licenseId;
    if (getSettings().sync_settings) {
      const syncInfo = {};
      syncInfo.SyncCommitVersion = sync_service["default"].getCommitVersion();
      syncInfo.SyncCommitName = sync_service["default"].getCurrentExtensionName();
      syncInfo.SyncCommitLog = sync_service["default"].getSyncLog();
      response.syncInfo = syncInfo;
    }
    response['License Installation Date'] = await check/* License.getLicenseInstallationDate */.Cz.getLicenseInstallationDate();
    const customChannelId = check/* channels.getIdByName */.ZW.getIdByName('CustomChannel');
    if (check/* channels.getGuide */.ZW.getGuide()[customChannelId].enabled) {
      const customChannel = check/* channels.channelGuide */.ZW.channelGuide[customChannelId].channel;
      const result = await customChannel.getTotalBytesInUse();
      response['Custom Channel total bytes in use'] = result;
    }
  }
  return response;
};

// Get debug info as a JSON object for bug reporting and ad reporting
const getDebugInfo = function () {
  return new Promise(async (resolve) => {
    const response = {};
    response.otherInfo = {};
    const { otherInfo } = response;

    // Is this installed build of AdBlock the official one?
    if (browser.runtime.id === 'pljaalgmajnlogcgiohkhdmgpomjcihk') {
      otherInfo.buildtype = ' Beta';
    } else if (browser.runtime.id === 'gighmmpiobklfepjocnamgkkbiglidom'
      || browser.runtime.id === 'aobdicepooefnbaeokijohmhjlleamfj'
      || browser.runtime.id === 'ndcileolkflehcjpmjnfbnaibdcgglog'
      || browser.runtime.id === 'jid1-NIfFY2CA8fy1tg@jetpack') {
      otherInfo.buildtype = ' Stable';
    } else {
      otherInfo.buildtype = ' Unofficial';
    }

    // Get AdBlock version
    otherInfo.version = browser.runtime.getManifest().version;

    // Get subscribed filter lists
    const subscriptionInfo = {};
    const subscriptions = await subscriptionadapter/* default.getSubscriptionsMinusText */.Z.getSubscriptionsMinusText();
    for (const id in subscriptions) {
      if (subscriptions[id].subscribed) {
        subscriptionInfo[id] = {};
        subscriptionInfo[id].lastSuccess = new Date(subscriptions[id].lastSuccess * 1000);
        subscriptionInfo[id].lastDownload = new Date(subscriptions[id].lastDownload * 1000);
        subscriptionInfo[id].downloadStatus = subscriptions[id].downloadStatus;
      }
    }
    response.subscriptions = subscriptionInfo;

    const userFilters = await getUserFilters();
    if (userFilters && userFilters.length) {
      response.customFilters = userFilters.map(filter => filter.text).join('\n');
    }

    // Get settings
    const adblockSettings = {};
    const settings = getSettings();
    for (const setting in settings) {
      adblockSettings[setting] = JSON.stringify(settings[setting]);
    }

    response.settings = adblockSettings;
    response.prefs = JSON.stringify(prefs/* Prefs */.B);
    otherInfo.browser = background/* TELEMETRY.browser */.C.browser;
    otherInfo.browserVersion = background/* TELEMETRY.browserVersion */.C.browserVersion;
    otherInfo.osVersion = background/* TELEMETRY.osVersion */.C.osVersion;
    otherInfo.os = background/* TELEMETRY.os */.C.os;

    if (localStorage && localStorage.length) {
      otherInfo.localStorageInfo = {};
      otherInfo.localStorageInfo.length = localStorage.length;
      let inx = 1;
      for (const key in localStorage) {
        otherInfo.localStorageInfo[`key${inx}`] = key;
        inx += 1;
      }
    } else {
      otherInfo.localStorageInfo = 'no data';
    }
    otherInfo.isAdblockPaused = adblockIsPaused();
    otherInfo.licenseState = check/* License.get */.Cz.get().status;
    otherInfo.licenseVersion = check/* License.get */.Cz.get().lv;

    // Get 'Stats' size
    otherInfo.rawStatsSize = await localdatacollection/* default.getRawStatsSize */.Z.getRawStatsSize();

    // Get total pings
    const storageResponse = await browser.storage.local.get('total_pings');
    otherInfo.totalPings = storageResponse.totalPings || 0;

    // Add exclude filters (if there are any)
    const excludeFiltersKey = 'exclude_filters';
    const secondResponse = await browser.storage.local.get(excludeFiltersKey);
    if (secondResponse && secondResponse[excludeFiltersKey]) {
      response.excludedFilters = secondResponse[excludeFiltersKey];
    }

    // Add JavaScript exception error (if there is one)
    const errorKey = 'errorkey';
    const errorResponse = await browser.storage.local.get(errorKey);
    if (errorResponse && errorResponse[errorKey]) {
      otherInfo[errorKey] = errorResponse[errorKey];
    }

    // Add any migration messages (if there are any)
    const migrateLogMessageKey = 'migrateLogMessageKey';
    const migrateLogMessageResponse = await browser.storage.local.get(migrateLogMessageKey);
    if (migrateLogMessageResponse && migrateLogMessageResponse[migrateLogMessageKey]) {
      const messages = migrateLogMessageResponse[migrateLogMessageKey].split('\n');
      for (let i = 0; i < messages.length; i++) {
        const key = `migration_message_${i}`;
        otherInfo[key] = messages[i];
      }
    }

    otherInfo.alarmInfo = await getDebugAlarmInfo();
    if (browser.permissions && browser.permissions.getAll) {
      otherInfo.hostPermissions = await browser.permissions.getAll();
    } else {
      otherInfo.hostPermissions = 'no data';
    }
    otherInfo.licenseInfo = await getDebugLicenseInfo();
    otherInfo.customRuleMetaData = await getCustomFilterMetaData();
    resolve(response);
  }); // end of Promise
};

// Called when user explicitly requests filter list updates
async function updateFilterLists() {
  const subscriptions = await ewe_api.subscriptions.getDownloadable();
  subscriptions.forEach(async (subscription) => {
    await ewe_api.subscriptions.sync(subscription.url);
  });
}

// Checks if the filter lists are currently in the process of
// updating and if there were errors the last time they were
// updated
async function checkUpdateProgress() {
  let inProgress = false;
  let filterError = false;
  const subscriptions = await ewe_api.subscriptions.getDownloadable();
  subscriptions.forEach(async (subscription) => {
    if (subscription.downloading) {
      inProgress = true;
    } else if (subscription.downloadStatus && subscription.downloadStatus !== 'synchronize_ok') {
      filterError = true;
    }
  });
  return { inProgress, filterError };
}

subscriptionInit/* initialize.then */.j.then(async () => {
  await background/* TELEMETRY.untilLoaded */.C.untilLoaded();
  background/* TELEMETRY.start */.C.start();
  setUninstallURL();
  await background/* IPM.untilLoaded */.fp.untilLoaded();
  background/* IPM.start */.fp.start();
  (0,allowlisting/* revalidateAllowlistingStates */.s)();
});

// Create the "blockage stats" for the uninstall logic ...
browser.runtime.onInstalled.addListener((details) => {
  if (details.reason === 'install') {
    browser.storage.local.get('blockage_stats').then((response) => {
      const { blockage_stats } = response;
      if (!blockage_stats) {
        const data = {};
        data.start = Date.now();
        data.version = 1;
        (0,bg_functions/* chromeStorageSetHelper */.rJ)('blockage_stats', data);
      }
    });
  }
});

// Attach methods to window
// eslint-disable-next-line no-restricted-globals
Object.assign(self, {
  adblockIsPaused,
  getUserFilters,
  updateFilterLists,
  checkUpdateProgress,
  createDomainAllowlistFilter,
  getDebugInfo,
  openTab,
  saveDomainPauses,
  adblockIsDomainPaused,
  pageIsWhitelisted,
  pageIsUnblockable,
  getCurrentTabInfo,
  getAdblockUserId,
  tryToUnwhitelist,
  addCustomFilter,
  removeCustomFilter,
  countCache,
  updateCustomFilterCountMap,
  removeCustomFilterForHost,
  confirmRemovalOfCustomFiltersOnHost,
  reloadTab,
  isSelectorFilter,
  isWhitelistFilter,
  isSelectorExcludeFilter,
  pausedFilterText1,
  pausedFilterText2,
  updateStorageKey,
  getCustomFilterMetaData,
});


/***/ }),

/***/ 922:
/***/ ((__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony import */ var prefs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(8710);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3817);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _vendor_adblockplusui_adblockpluschrome_lib_browserAction__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3265);
/* harmony import */ var _servermessages__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1546);
/* harmony import */ var _messaging_messagevalidator__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9031);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, ext, adblockIsPaused, adblockIsDomainPaused
   log, License, reloadTab, getSettings */









const updateButtonUIAndContextMenus = function () {
  browser.tabs.query({}).then((tabs) => {
    for (const tab of tabs) {
      tab.url = tab.url ? tab.url : tab.pendingUrl;
      if (adblockIsPaused() || adblockIsDomainPaused({ url: tab.url.href, id: tab.id })) {
        (0,_vendor_adblockplusui_adblockpluschrome_lib_browserAction__WEBPACK_IMPORTED_MODULE_2__/* .setBadge */ .q_)(tab.id, { number: '' });
      }
      const page = new ext.Page(tab);
      // eslint-disable-next-line no-use-before-define
      updateContextMenuItems(page);
    }
  });
};

// Bounce messages back to content scripts.
const emitPageBroadcast = (function emitBroadcast() {
  const injectMap = {
    topOpenWhitelistUI:
      {
        allFrames: false,
        include: [
          'jquery-3.5.1.min.js',
          'adblock-uiscripts-load_wizard_resources.js',
          'adblock-uiscripts-top_open_whitelist_ui.js',
        ],
      },
    topOpenWhitelistCompletionUI:
      {
        allFrames: false,
        include: [
          'jquery-3.5.1.min.js',
          'adblock-uiscripts-load_wizard_resources.js',
          'adblock-uiscripts-top_open_whitelist_completion_ui.js',
        ],
      },
    topOpenBlacklistUI:
      {
        allFrames: false,
        include: [
          'jquery-3.5.1.min.js',
          'purify.min.js',
          'adblock-uiscripts-load_wizard_resources.js',
          'adblock-uiscripts-blacklisting-overlay.js',
          'adblock-uiscripts-blacklisting-clickwatcher.js',
          'adblock-uiscripts-blacklisting-elementchain.js',
          'adblock-uiscripts-blacklisting-blacklistui.js',
          'adblock-uiscripts-top_open_blacklist_ui.js',
        ],
      },
    sendContentToBack:
      {
        allFrames: true,
        include: ['adblock-uiscripts-send_content_to_back.js'],
      },
  };

  // Inject the required scripts to execute fnName(parameter) in
  // the given tab.
  // Inputs: fnName:string name of function to execute on tab.
  //         fnName must exist in injectMap above.
  //         parameter:object to pass to fnName.  Must be JSON.stringify()able.
  //         alreadyInjected?:int used to recursively inject required scripts.
  //         tabID:int representing the ID of the tab to execute in.
  //         tabID defaults to the active tab
  const executeOnTab = function (fnName, parameter, alreadyInjected, tabID) {
    const injectedSoFar = alreadyInjected || 0;
    const data = injectMap[fnName];
    const details = { allFrames: data.allFrames };

    // If there's anything to inject, inject the next item and recurse.
    if (data.include.length > injectedSoFar) {
      details.file = data.include[injectedSoFar];
      browser.tabs.executeScript(tabID, details).then(() => {
        executeOnTab(fnName, parameter, injectedSoFar + 1, tabID);
      }).catch((error) => {
        log(error);
      });
    } else {
      // Nothing left to inject, so execute the function.
      const param = JSON.stringify(parameter);
      details.code = `${fnName}(${param});`;
      browser.tabs.executeScript(tabID, details);
    }
  };

  // The emitPageBroadcast() function
  const theFunction = function (request) {
    executeOnTab(request.fn, request.options, 0, request.tabID);
  };

  return theFunction;
}());

const contextMenuItem = (() => ({
  pauseAll:
    {
      title: browser.i18n.getMessage('pause_adblock_everywhere'),
      id: 'pause_adblock_everywhere',
      contexts: ['all'],
      onclick: () => {
        _servermessages__WEBPACK_IMPORTED_MODULE_3__/* ["default"].recordGeneralMessage */ .Z.recordGeneralMessage('cm_pause_clicked');
        adblockIsPaused(true);
        updateButtonUIAndContextMenus();
      },
    },
  unpauseAll:
    {
      title: browser.i18n.getMessage('resume_blocking_ads'),
      id: 'resume_blocking_ads',
      contexts: ['all'],
      onclick: () => {
        _servermessages__WEBPACK_IMPORTED_MODULE_3__/* ["default"].recordGeneralMessage */ .Z.recordGeneralMessage('cm_unpause_clicked');
        adblockIsPaused(false);
        updateButtonUIAndContextMenus();
      },
    },
  pauseDomain:
    {
      title: browser.i18n.getMessage('domain_pause_adblock'),
      id: 'domain_pause_adblock',
      contexts: ['all'],
      onclick: (info, tab) => {
        _servermessages__WEBPACK_IMPORTED_MODULE_3__/* ["default"].recordGeneralMessage */ .Z.recordGeneralMessage('cm_domain_pause_clicked');
        adblockIsDomainPaused({ url: tab.url, id: tab.id }, true);
        updateButtonUIAndContextMenus();
      },
    },
  unpauseDomain:
    {
      title: browser.i18n.getMessage('resume_blocking_ads'),
      id: 'resume_blocking_ads_unpause',
      contexts: ['all'],
      onclick: (info, tab) => {
        _servermessages__WEBPACK_IMPORTED_MODULE_3__/* ["default"].recordGeneralMessage */ .Z.recordGeneralMessage('cm_domain_unpause_clicked');
        adblockIsDomainPaused({ url: tab.url, id: tab.id }, false);
        updateButtonUIAndContextMenus();
      },
    },
  blockThisAd:
    {
      title: browser.i18n.getMessage('block_this_ad'),
      id: 'block_this_ad',
      contexts: ['all'],
      onclick(info, tab) {
        emitPageBroadcast({
          fn: 'topOpenBlacklistUI',
          options: {
            info,
            showBlacklistCTA: License.shouldShowBlacklistCTA(),
            isActiveLicense: License.isActiveLicense(),
            settings: getSettings(),
            addCustomFilterRandomName: _messaging_messagevalidator__WEBPACK_IMPORTED_MODULE_4__/* ["default"].generateNewRandomText */ .Z.generateNewRandomText(),
          },
        }, {
          tab,
        });
      },
    },
  blockAnAd:
    {
      title: browser.i18n.getMessage('block_an_ad_on_this_page'),
      id: 'block_an_ad_on_this_page',
      contexts: ['all'],
      onclick(info, tab) {
        emitPageBroadcast({
          fn: 'topOpenBlacklistUI',
          options: {
            nothingClicked: true,
            showBlacklistCTA: License.shouldShowBlacklistCTA(),
            isActiveLicense: License.isActiveLicense(),
            settings: getSettings(),
            addCustomFilterRandomName: _messaging_messagevalidator__WEBPACK_IMPORTED_MODULE_4__/* ["default"].generateNewRandomText */ .Z.generateNewRandomText(),
          },
        }, {
          tab,
        });
      },
    },
}))();


const checkLastError = function () {
  if (browser.runtime.lastError) {
    // do nothing
  }
};

let updateContextMenuItems = async function (page) {
  // Remove the AdBlock context menu items
  await browser.contextMenus.removeAll();

  // Check if the context menu items should be added
  if (!prefs__WEBPACK_IMPORTED_MODULE_0__/* .Prefs.shouldShowBlockElementMenu */ .B.shouldShowBlockElementMenu) {
    return;
  }
  const domainIsPaused = adblockIsDomainPaused({ url: page.url.href, id: page.id });

  if (adblockIsPaused()) {
    browser.contextMenus.create(contextMenuItem.unpauseAll, checkLastError);
  } else if (domainIsPaused) {
    browser.contextMenus.create(contextMenuItem.unpauseDomain, checkLastError);
  } else if (await _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.filters.getAllowingFilters(page.id).length) {
    browser.contextMenus.create(contextMenuItem.pauseAll, checkLastError);
  } else {
    browser.contextMenus.create(contextMenuItem.blockThisAd, checkLastError);
    browser.contextMenus.create(contextMenuItem.blockAnAd, checkLastError);
    browser.contextMenus.create(contextMenuItem.pauseDomain, checkLastError);
    browser.contextMenus.create(contextMenuItem.pauseAll, checkLastError);
  }
};

const updateContextMenuItemsNoOp = function () {
  // Remove the AdBlock context menu items
  browser.contextMenus.removeAll();
};
// startup test to check if the context menu API functions correctly
// the `create` function is invoked twice, because it's the second
// and all subsequent calls that fail.
try {
  browser.contextMenus.create(contextMenuItem.blockThisAd, checkLastError);
  browser.contextMenus.create(contextMenuItem.blockThisAd, checkLastError);
} catch (e) {
  updateContextMenuItems = updateContextMenuItemsNoOp;
}
browser.contextMenus.removeAll();

browser.tabs.onUpdated.addListener((tabId, changeInfo, tab) => {
  if (changeInfo.status) {
    updateContextMenuItems(new ext.Page(tab));
  }
});

browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
  if (message.command !== 'sendContentToBack') {
    return;
  } // not for us
  emitPageBroadcast({ fn: 'sendContentToBack', options: {} });
  sendResponse({});
});

browser.runtime.onMessage.addListener((request, sender, sendResponse) => {
  if (request.command === 'reloadTabForWhitelist') {
    reloadTab(sender.tab.id, () => {
      emitPageBroadcast({
        fn: 'topOpenWhitelistCompletionUI',
        options: {
          rule: request.rule,
          isActiveLicense: License.isActiveLicense(),
          showWhitelistCTA: License.shouldShowWhitelistCTA(),
        },
        tabID: sender.tab.id,
      });
    });
    sendResponse({});
  }
});

browser.runtime.onMessage.addListener((request, sender, sendResponse) => {
  if (request.command === 'showWhitelistCompletion') {
    emitPageBroadcast({
      fn: 'topOpenWhitelistCompletionUI',
      options: {
        rule: request.rule,
        isActiveLicense: License.isActiveLicense(),
        showWhitelistCTA: License.shouldShowWhitelistCTA(),
      },
      tabID: sender.tab.id,
    });
    sendResponse({});
  }
});

browser.runtime.onMessage.addListener((request, sender, sendResponse) => {
  if (request.command === 'showBlacklist' && typeof request.nothingClicked === 'boolean') {
    emitPageBroadcast({
      fn: 'topOpenBlacklistUI',
      options: {
        nothingClicked: request.nothingClicked,
        isActiveLicense: License.isActiveLicense(),
        showBlacklistCTA: License.shouldShowBlacklistCTA(),
        settings: getSettings(),
        addCustomFilterRandomName: _messaging_messagevalidator__WEBPACK_IMPORTED_MODULE_4__/* ["default"].generateNewRandomText */ .Z.generateNewRandomText(),
      },
      tabID: request.tabId,
    });
    sendResponse({});
  }
});

browser.runtime.onMessage.addListener((request, sender, sendResponse) => {
  if (request.command === 'showWhitelist') {
    emitPageBroadcast({
      fn: 'topOpenWhitelistUI',
      options: {
        addCustomFilterRandomName: _messaging_messagevalidator__WEBPACK_IMPORTED_MODULE_4__/* ["default"].generateNewRandomText */ .Z.generateNewRandomText(),
      },
      tabID: request.tabId,
    });
    sendResponse({});
  }
});

// Update browser actions and context menus when whitelisting might have
// changed. That is now when initally loading the filters and later when
// importing backups or saving filter changes.
// Update browser actions and context menus when whitelisting might have
// changed. That is now when initally loading the filters and later when
// importing backups or saving filter changes.
_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.subscriptions.onAdded.addListener(updateButtonUIAndContextMenus);
_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.subscriptions.onChanged.addListener(updateButtonUIAndContextMenus);
_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.subscriptions.onRemoved.addListener(updateButtonUIAndContextMenus);

prefs__WEBPACK_IMPORTED_MODULE_0__/* .Prefs.on */ .B.on(prefs__WEBPACK_IMPORTED_MODULE_0__/* .Prefs.shouldShowBlockElementMenu */ .B.shouldShowBlockElementMenu, () => {
  updateButtonUIAndContextMenus();
});

updateButtonUIAndContextMenus();

// eslint-disable-next-line no-restricted-globals
Object.assign(self, {
  emitPageBroadcast,
  updateButtonUIAndContextMenus,
});


/***/ }),

/***/ 1064:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var _alias_icon__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1021);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, log, openTab, License,
 */




const CtaABManager = (function get() {
  let ctaData = {
    enrollment: false,
  };
  const ctaDataStorageKey = 'ctaData';
  // Load the CTA A/B data from persistent storage
  // Should only be called during startup / initialization
  browser.storage.local.get(ctaDataStorageKey).then((response) => {
    if (response[ctaDataStorageKey]) {
      ctaData = response[ctaDataStorageKey];
    }
  });

  // Check the response from a ping to see if it contains valid CTA A/B instructions.
  // If so, return an object containing data about the CTA A/B data.
  // Otherwise, return null.
  // Inputs:
  //   responseData: string response from a ping
  const dataFrom = function (responseData) {
    if (!responseData || responseData.length === 0 || responseData.trim().length === 0) {
      return null;
    }
    let pingData = {};
    try {
      pingData = JSON.parse(responseData);
      if (!pingData) {
        return null;
      }
    } catch (e) {
      // eslint-disable-next-line no-console
      console.log('Something went wrong with parsing data.');
      // eslint-disable-next-line no-console
      console.log('error', e);
      // eslint-disable-next-line no-console
      console.log('response data', responseData);
      return null;
    }
    return pingData;
  };

  return {
    get() {
      return ctaData;
    },
    isEnrolled() {
      return (ctaData.enrollment === true);
    },
    getVar() {
      return ctaData.var;
    },
    getExp() {
      return ctaData.exp;
    },
    maybeCtaAB(responseData) {
      if (!License.shouldShowPremiumCTA()) {
        return;
      }
      const pingData = dataFrom(responseData);
      if (!pingData) {
        return;
      }
      ctaData.enrollment = true;
      ctaData.var = pingData.var;
      ctaData.exp = pingData.exp;
      browser.storage.local.set({ ctaData });
      (0,_alias_icon__WEBPACK_IMPORTED_MODULE_0__/* .showIconBadgeCTA */ .QO)(true, _alias_icon__WEBPACK_IMPORTED_MODULE_0__/* .NEW_BADGE_REASONS.VPN_CTA */ .ec.VPN_CTA);
    }, // end of maybeCtaAB
    types() {
      // 'C' = A/B Test of CTAs
      return 'C';
    },
  };
}());

/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (CtaABManager);


/***/ }),

/***/ 5175:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var info__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(187);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3817);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _subscriptionadapter__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(934);
/* harmony import */ var _fetch_util__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2379);
/* harmony import */ var _prefs_settings__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2630);
/* harmony import */ var _utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2028);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, adblockIsPaused,
   adblockIsDomainPaused, getUserFilters, */








const DataCollectionV2 = (function getDataCollectionV2() {
  const HOUR_IN_MIN = 60;
  const TIME_LAST_PUSH_KEY = 'timeLastPush';
  const DATA_COLLECTION_ALARM_NAME = 'datacollectionalarm';
  const STORAGE_KEY = 'ab:data.collection.storage.key';
  const REPORTING_OPTIONS = {
    filterType: 'all',
    includeElementHiding: false,
  };

  // Setup memory cache
  let dataCollectionCache = {};
  dataCollectionCache.filters = {};
  dataCollectionCache.domains = {};

  const addFilterToCache = async function (details, filter) {
    const validFilterText = filter && filter.text && (typeof filter.text === 'string');
    if (validFilterText && details && details.url) {
      let domain = details.url.hostname;
      if (!domain) {
        domain = new URL(details.url).hostname;
        if (!domain) {
          return;
        }
      }
      const { text } = filter;

      if (!(text in dataCollectionCache.filters)) {
        dataCollectionCache.filters[text] = {};
        dataCollectionCache.filters[text].firstParty = {};
        dataCollectionCache.filters[text].thirdParty = {};
        dataCollectionCache.filters[text].subscriptions = [];
      }
      if (filter.thirdParty) {
        if (!dataCollectionCache.filters[text].thirdParty[domain]) {
          dataCollectionCache.filters[text].thirdParty[domain] = {};
          dataCollectionCache.filters[text].thirdParty[domain].hits = 0;
        }
        dataCollectionCache.filters[text].thirdParty[domain].hits += 1;
      } else {
        if (!dataCollectionCache.filters[text].firstParty[domain]) {
          dataCollectionCache.filters[text].firstParty[domain] = {};
          dataCollectionCache.filters[text].firstParty[domain].hits = 0;
        }
        dataCollectionCache.filters[text].firstParty[domain].hits += 1;
      }
      const subscriptions = await _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.subscriptions.getForFilter(text);
      subscriptions.forEach((sub) => {
        if (sub.enabled && sub.url && sub.downloadable) {
          const subURL = sub.url.substring(0, 256);
          if (!dataCollectionCache.filters[text].subscriptions.includes(subURL)) {
            dataCollectionCache.filters[text].subscriptions.push(subURL);
          }
        }
      });
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_4__/* .chromeStorageSetHelper */ .rJ)(STORAGE_KEY, dataCollectionCache);
    }
  };

  const webRequestListener = function (details) {
    if (details.url && details.type === 'main_frame' && !adblockIsPaused() && !adblockIsDomainPaused({ url: details.url, id: details.id })) {
      const domain = (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_4__/* .parseUri */ .he)(details.url).host;
      if (!dataCollectionCache.domains[domain]) {
        dataCollectionCache.domains[domain] = {};
        dataCollectionCache.domains[domain].pages = 0;
      }
      dataCollectionCache.domains[domain].pages += 1;
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_4__/* .chromeStorageSetHelper */ .rJ)(STORAGE_KEY, dataCollectionCache);
    }
  };

  const filterListener = function ({ request, filter }) {
    if ((0,_prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .getSettings */ .Gw)().data_collection_v2 && !adblockIsPaused()) {
      addFilterToCache(request, filter);
    } else if (!(0,_prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .getSettings */ .Gw)().data_collection_v2) {
      _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.reporting.onBlockableItem.removeListener(filterListener, REPORTING_OPTIONS);
      browser.alarms.clear(DATA_COLLECTION_ALARM_NAME);
    }
  };

  const sendToServer = async function () {
    const dataCollectionSetting = (0,_prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .getSettings */ .Gw)().data_collection_v2;
    if (!dataCollectionSetting) {
      browser.alarms.clear(DATA_COLLECTION_ALARM_NAME);
    }
    if (dataCollectionSetting && Object.keys(dataCollectionCache.filters).length > 0) {
      const subscribedSubs = [];
      const subs = await _subscriptionadapter__WEBPACK_IMPORTED_MODULE_2__/* ["default"].getSubscriptionsMinusText */ .Z.getSubscriptionsMinusText();
      for (const subscription of Object.values(subs)) {
        if (subscription && subscription.url) {
          subscribedSubs.push(subscription.url.substring(0, 256));
        }
      }
      if (await getUserFilters().length) {
        subscribedSubs.push('customlist');
      }
      const data = {
        version: '5',
        addonName: info__WEBPACK_IMPORTED_MODULE_0__.addonName,
        addonVersion: info__WEBPACK_IMPORTED_MODULE_0__.addonVersion,
        application: info__WEBPACK_IMPORTED_MODULE_0__.application,
        applicationVersion: info__WEBPACK_IMPORTED_MODULE_0__.applicationVersion,
        platform: info__WEBPACK_IMPORTED_MODULE_0__.platform,
        platformVersion: info__WEBPACK_IMPORTED_MODULE_0__.platformVersion,
        appLocale: browser.i18n.getUILanguage(),
        filterListSubscriptions: subscribedSubs,
        domains: dataCollectionCache.domains,
        filters: dataCollectionCache.filters,
      };
      browser.storage.local.get(TIME_LAST_PUSH_KEY).then((response) => {
        let timeLastPush = 'n/a';
        if (response[TIME_LAST_PUSH_KEY]) {
          const serverTimestamp = new Date(response[TIME_LAST_PUSH_KEY]);
          // Format the timeLastPush
          const yearStr = `${serverTimestamp.getUTCFullYear()}`;
          let monthStr = `${serverTimestamp.getUTCMonth() + 1}`;
          let dateStr = `${serverTimestamp.getUTCDate()}`;
          let hourStr = `${serverTimestamp.getUTCHours()}`;
          // round the minutes up to the nearest 10
          let minStr = `${Math.floor(serverTimestamp.getUTCMinutes() / 10) * 10}`;

          if (monthStr.length === 1) {
            monthStr = `0${monthStr}`;
          }
          if (dateStr.length === 1) {
            dateStr = `0${dateStr}`;
          }
          if (hourStr.length === 1) {
            hourStr = `0${hourStr}`;
          }
          if (minStr.length === 1) {
            minStr = `0${minStr}`;
          }
          if (minStr === '60') {
            minStr = '00';
          }
          timeLastPush = `${yearStr}-${monthStr}-${dateStr} ${hourStr}:${minStr}:00`;
        }
        data.timeOfLastPush = timeLastPush;
        (0,_fetch_util__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z)('https://log.getadblock.com/v2/record_log.php', data)
          .then((postResponse) => {
            if (postResponse.ok) {
              let nowTimestamp = (new Date()).toGMTString();
              try {
                if (postResponse.headers.has('date')) {
                  nowTimestamp = postResponse.headers.get('date');
                }
              } catch (e) {
                nowTimestamp = (new Date()).toGMTString();
              }
              (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_4__/* .chromeStorageSetHelper */ .rJ)(TIME_LAST_PUSH_KEY, nowTimestamp);
              // Reset memory cache
              dataCollectionCache = {};
              dataCollectionCache.filters = {};
              dataCollectionCache.domains = {};
              browser.storage.local.remove(STORAGE_KEY);
              return;
            }
            (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_4__/* .log */ .cM)('bad response from log server', postResponse);
          });
      }); // end of TIME_LAST_PUSH_KEY
    }
  };

  const loadCache = async function () {
    const response = await browser.storage.local.get(STORAGE_KEY);
    if (response[STORAGE_KEY]) {
      dataCollectionCache = response[STORAGE_KEY];
    }
  };

  const initializeAlarm = function () {
    const processAlarm = async function (alarm) {
      if (!alarm && alarm.name !== DATA_COLLECTION_ALARM_NAME) {
        return;
      }
      await _prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .settings.onload */ .Xd.onload();
      if ((0,_prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .getSettings */ .Gw)().data_collection_v2) {
        await loadCache();
        sendToServer();
      } else {
        browser.alarms.clear(DATA_COLLECTION_ALARM_NAME);
        browser.alarms.onAlarm.removeListener(processAlarm);
      }
    };
    browser.alarms.onAlarm.addListener(processAlarm);
  };

  // If enabled at startup periodic saving of memory cache &
  // sending of data to the log server
  const initialize = function () {
    initializeAlarm();
    _prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .settings.onload */ .Xd.onload().then(async () => {
      if (!(0,_prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .getSettings */ .Gw)().data_collection_v2) {
        return;
      }
      await loadCache();
      _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.reporting.onBlockableItem.addListener(filterListener, REPORTING_OPTIONS);
      browser.webRequest.onBeforeRequest.addListener(webRequestListener, {
        urls: ['http://*/*', 'https://*/*'],
        types: ['main_frame'],
      });
      browser.alarms.create(DATA_COLLECTION_ALARM_NAME, { periodInMinutes: HOUR_IN_MIN });
    });
  };
  initialize();


  const returnObj = {};
  returnObj.start = function returnObjStart() {
    dataCollectionCache.filters = {};
    dataCollectionCache.domains = {};
    (0,_prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .setSetting */ .Lt)('data_collection_v2', true, () => {
      initialize();
    });
  };
  returnObj.end = function returnObjEnd() {
    dataCollectionCache = {};
    _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.reporting.onBlockableItem.removeListener(filterListener, REPORTING_OPTIONS);
    browser.webRequest.onBeforeRequest.removeListener(webRequestListener);
    browser.storage.local.remove(TIME_LAST_PUSH_KEY);
    browser.storage.local.remove(STORAGE_KEY);
    browser.alarms.clear(DATA_COLLECTION_ALARM_NAME);
    (0,_prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .setSetting */ .Lt)('data_collection_v2', false);
  };
  returnObj.getCache = function returnObjGetCache() {
    return dataCollectionCache;
  };

  return returnObj;
}());

/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (DataCollectionV2);


/***/ }),

/***/ 2508:
/***/ ((__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony import */ var _utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2028);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser */



// Send the file name and line number of any error message. This will help us
// to trace down any frequent errors we can't confirm ourselves.
/* eslint-disable no-restricted-globals */
self.addEventListener('error', (e) => {
  if (!e.filename && !e.lineno && !e.colno && !e.error && !e.message) {
    return;
  }
  let str = `Error: ${
    (e.filename || 'anywhere').replace(browser.runtime.getURL(''), '')
  }:${e.lineno || 'anywhere'
  }:${e.colno || 'anycol'}`;
  if (e.message) {
    str += `: ${e.message}`;
  }
  const src = e.target.src || e.target.href;
  if (src) {
    str += `src: ${src}`;
  }
  if (e.error) {
    let stack = `-${e.error.message || ''
    }-${e.error.stack || ''}`;
    stack = stack.replace(/:/gi, ';').replace(/\n/gi, '');
    // only append the stack info if there isn't any URL info in the stack trace
    if (stack.indexOf('http') === -1) {
      str += stack;
    }
    // don't send large stack traces
    if (str.length > 1024) {
      str = str.substr(0, 1023);
    }
  }
  (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__/* .chromeStorageSetHelper */ .rJ)('errorkey', `Date added:${new Date()} ${str}`);
  // eslint-disable-next-line no-console
  console.log(str);
});


/***/ }),

/***/ 2379:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (/* binding */ postData)
/* harmony export */ });
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global  */

async function postData(url = '', payload = {}) {
  return fetch(url, {
    method: 'POST',
    cache: 'no-cache',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify(payload),
  });
}


/***/ }),

/***/ 4448:
/***/ (function(module, exports) {

var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*! jQuery v3.5.1 | (c) JS Foundation and other contributors | jquery.org/license */
!function(e,t){"use strict"; true&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(C,e){"use strict";var t=[],r=Object.getPrototypeOf,s=t.slice,g=t.flat?function(e){return t.flat.call(e)}:function(e){return t.concat.apply([],e)},u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},x=function(e){return null!=e&&e===e.window},E=C.document,c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.5.1",S=function(e,t){return new S.fn.init(e,t)};function p(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0<t&&t-1 in e)}S.fn=S.prototype={jquery:f,constructor:S,length:0,toArray:function(){return s.call(this)},get:function(e){return null==e?s.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=S.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return S.each(this,e)},map:function(n){return this.pushStack(S.map(this,function(e,t){return n.call(e,t,e)}))},slice:function(){return this.pushStack(s.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(S.grep(this,function(e,t){return(t+1)%2}))},odd:function(){return this.pushStack(S.grep(this,function(e,t){return t%2}))},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(0<=n&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:u,sort:t.sort,splice:t.splice},S.extend=S.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,u=arguments.length,l=!1;for("boolean"==typeof a&&(l=a,a=arguments[s]||{},s++),"object"==typeof a||m(a)||(a={}),s===u&&(a=this,s--);s<u;s++)if(null!=(e=arguments[s]))for(t in e)r=e[t],"__proto__"!==t&&a!==r&&(l&&r&&(S.isPlainObject(r)||(i=Array.isArray(r)))?(n=a[t],o=i&&!Array.isArray(n)?[]:i||S.isPlainObject(n)?n:{},i=!1,a[t]=S.extend(l,o,r)):void 0!==r&&(a[t]=r));return a},S.extend({expando:"jQuery"+(f+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isPlainObject:function(e){var t,n;return!(!e||"[object Object]"!==o.call(e))&&(!(t=r(e))||"function"==typeof(n=v.call(t,"constructor")&&t.constructor)&&a.call(n)===l)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},globalEval:function(e,t,n){b(e,{nonce:t&&t.nonce},n)},each:function(e,t){var n,r=0;if(p(e)){for(n=e.length;r<n;r++)if(!1===t.call(e[r],r,e[r]))break}else for(r in e)if(!1===t.call(e[r],r,e[r]))break;return e},makeArray:function(e,t){var n=t||[];return null!=e&&(p(Object(e))?S.merge(n,"string"==typeof e?[e]:e):u.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:i.call(t,e,n)},merge:function(e,t){for(var n=+t.length,r=0,i=e.length;r<n;r++)e[i++]=t[r];return e.length=i,e},grep:function(e,t,n){for(var r=[],i=0,o=e.length,a=!n;i<o;i++)!t(e[i],i)!==a&&r.push(e[i]);return r},map:function(e,t,n){var r,i,o=0,a=[];if(p(e))for(r=e.length;o<r;o++)null!=(i=t(e[o],o,n))&&a.push(i);else for(o in e)null!=(i=t(e[o],o,n))&&a.push(i);return g(a)},guid:1,support:y}),"function"==typeof Symbol&&(S.fn[Symbol.iterator]=t[Symbol.iterator]),S.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){n["[object "+t+"]"]=t.toLowerCase()});var d=function(n){var e,d,b,o,i,h,f,g,w,u,l,T,C,a,E,v,s,c,y,S="sizzle"+1*new Date,p=n.document,k=0,r=0,m=ue(),x=ue(),A=ue(),N=ue(),D=function(e,t){return e===t&&(l=!0),0},j={}.hasOwnProperty,t=[],q=t.pop,L=t.push,H=t.push,O=t.slice,P=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},R="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",M="[\\x20\\t\\r\\n\\f]",I="(?:\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",W="\\["+M+"*("+I+")(?:"+M+"*([*^$|!~]?=)"+M+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+I+"))|)"+M+"*\\]",F=":("+I+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+W+")*)|.*)\\)|)",B=new RegExp(M+"+","g"),$=new RegExp("^"+M+"+|((?:^|[^\\\\])(?:\\\\.)*)"+M+"+$","g"),_=new RegExp("^"+M+"*,"+M+"*"),z=new RegExp("^"+M+"*([>+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp(F),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\([^\\r\\n\\f])","g"),ne=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(p.childNodes),p.childNodes),t[p.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&(T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!N[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&(U.test(t)||z.test(t))){(f=ee.test(t)&&ye(e.parentNode)||e)===e&&d.scope||((s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=S)),o=(l=h(t)).length;while(o--)l[o]=(s?"#"+s:":scope")+" "+xe(l[o]);c=l.join(",")}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){N(t,!0)}finally{s===S&&e.removeAttribute("id")}}}return g(t.replace($,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[S]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:p;return r!=C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),p!=C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.scope=ce(function(e){return a.appendChild(e).appendChild(C.createElement("div")),"undefined"!=typeof e.querySelectorAll&&!e.querySelectorAll(":scope fieldset div").length}),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=S,!C.getElementsByName||!C.getElementsByName(S).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){var t;a.appendChild(e).innerHTML="<a id='"+S+"'></a><select id='"+S+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+S+"-]").length||v.push("~="),(t=C.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||v.push("\\["+M+"*name"+M+"*="+M+"*(?:''|\"\")"),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+S+"+*").length||v.push(".#.+[+~]"),e.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")}),ce(function(e){e.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",F)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e==C||e.ownerDocument==p&&y(p,e)?-1:t==C||t.ownerDocument==p&&y(p,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==C?-1:t==C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]==p?-1:s[r]==p?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if(T(e),d.matchesSelector&&E&&!N[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){N(t,!0)}return 0<se(t,C,null,[e]).length},se.contains=function(e,t){return(e.ownerDocument||e)!=C&&T(e),y(e,t)},se.attr=function(e,t){(e.ownerDocument||e)!=C&&T(e);var n=b.attrHandle[t.toLowerCase()],r=n&&j.call(b.attrHandle,t.toLowerCase())?n(e,t,!E):void 0;return void 0!==r?r:d.attributes||!E?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},se.escape=function(e){return(e+"").replace(re,ie)},se.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},se.uniqueSort=function(e){var t,n=[],r=0,i=0;if(l=!d.detectDuplicates,u=!d.sortStable&&e.slice(0),e.sort(D),l){while(t=e[i++])t===e[i]&&(r=n.push(i));while(r--)e.splice(n[r],1)}return u=null,e},o=se.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=o(e)}else if(3===i||4===i)return e.nodeValue}else while(t=e[r++])n+=o(t);return n},(b=se.selectors={cacheLength:50,createPseudo:le,match:G,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=m[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&m(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1<t.indexOf(i):"$="===r?i&&t.slice(-i.length)===i:"~="===r?-1<(" "+t.replace(B," ")+" ").indexOf(i):"|="===r&&(t===i||t.slice(0,i.length+1)===i+"-"))}},CHILD:function(h,e,t,g,v){var y="nth"!==h.slice(0,3),m="last"!==h.slice(-4),x="of-type"===e;return 1===g&&0===v?function(e){return!!e.parentNode}:function(e,t,n){var r,i,o,a,s,u,l=y!==m?"nextSibling":"previousSibling",c=e.parentNode,f=x&&e.nodeName.toLowerCase(),p=!n&&!x,d=!1;if(c){if(y){while(l){a=e;while(a=a[l])if(x?a.nodeName.toLowerCase()===f:1===a.nodeType)return!1;u=l="only"===h&&!u&&"nextSibling"}return!0}if(u=[m?c.firstChild:c.lastChild],m&&p){d=(s=(r=(i=(o=(a=c)[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===k&&r[1])&&r[2],a=s&&c.childNodes[s];while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if(1===a.nodeType&&++d&&a===e){i[h]=[k,s,d];break}}else if(p&&(d=s=(r=(i=(o=(a=e)[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===k&&r[1]),!1===d)while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if((x?a.nodeName.toLowerCase()===f:1===a.nodeType)&&++d&&(p&&((i=(o=a[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]=[k,d]),a===e))break;return(d-=v)===g||d%g==0&&0<=d/g}}},PSEUDO:function(e,o){var t,a=b.pseudos[e]||b.setFilters[e.toLowerCase()]||se.error("unsupported pseudo: "+e);return a[S]?a(o):1<a.length?(t=[e,e,"",o],b.setFilters.hasOwnProperty(e.toLowerCase())?le(function(e,t){var n,r=a(e,o),i=r.length;while(i--)e[n=P(e,r[i])]=!(t[n]=r[i])}):function(e){return a(e,0,t)}):a}},pseudos:{not:le(function(e){var r=[],i=[],s=f(e.replace($,"$1"));return s[S]?le(function(e,t,n,r){var i,o=s(e,null,r,[]),a=e.length;while(a--)(i=o[a])&&(e[a]=!(t[a]=i))}):function(e,t,n){return r[0]=e,s(r,null,n,i),r[0]=null,!i.pop()}}),has:le(function(t){return function(e){return 0<se(t,e).length}}),contains:le(function(t){return t=t.replace(te,ne),function(e){return-1<(e.textContent||o(e)).indexOf(t)}}),lang:le(function(n){return V.test(n||"")||se.error("unsupported lang: "+n),n=n.replace(te,ne).toLowerCase(),function(e){var t;do{if(t=E?e.lang:e.getAttribute("xml:lang")||e.getAttribute("lang"))return(t=t.toLowerCase())===n||0===t.indexOf(n+"-")}while((e=e.parentNode)&&1===e.nodeType);return!1}}),target:function(e){var t=n.location&&n.location.hash;return t&&t.slice(1)===e.id},root:function(e){return e===a},focus:function(e){return e===C.activeElement&&(!C.hasFocus||C.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:ge(!1),disabled:ge(!0),checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!b.pseudos.empty(e)},header:function(e){return J.test(e.nodeName)},input:function(e){return Q.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:ve(function(){return[0]}),last:ve(function(e,t){return[t-1]}),eq:ve(function(e,t,n){return[n<0?n+t:n]}),even:ve(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:ve(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:ve(function(e,t,n){for(var r=n<0?n+t:t<n?t:n;0<=--r;)e.push(r);return e}),gt:ve(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}}).pseudos.nth=b.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})b.pseudos[e]=de(e);for(e in{submit:!0,reset:!0})b.pseudos[e]=he(e);function me(){}function xe(e){for(var t=0,n=e.length,r="";t<n;t++)r+=e[t].value;return r}function be(s,e,t){var u=e.dir,l=e.next,c=l||u,f=t&&"parentNode"===c,p=r++;return e.first?function(e,t,n){while(e=e[u])if(1===e.nodeType||f)return s(e,t,n);return!1}:function(e,t,n){var r,i,o,a=[k,p];if(n){while(e=e[u])if((1===e.nodeType||f)&&s(e,t,n))return!0}else while(e=e[u])if(1===e.nodeType||f)if(i=(o=e[S]||(e[S]={}))[e.uniqueID]||(o[e.uniqueID]={}),l&&l===e.nodeName.toLowerCase())e=e[u]||e;else{if((r=i[c])&&r[0]===k&&r[1]===p)return a[2]=r[2];if((i[c]=a)[2]=s(e,t,n))return!0}return!1}}function we(i){return 1<i.length?function(e,t,n){var r=i.length;while(r--)if(!i[r](e,t,n))return!1;return!0}:i[0]}function Te(e,t,n,r,i){for(var o,a=[],s=0,u=e.length,l=null!=t;s<u;s++)(o=e[s])&&(n&&!n(o,r,i)||(a.push(o),l&&t.push(s)));return a}function Ce(d,h,g,v,y,e){return v&&!v[S]&&(v=Ce(v)),y&&!y[S]&&(y=Ce(y,e)),le(function(e,t,n,r){var i,o,a,s=[],u=[],l=t.length,c=e||function(e,t,n){for(var r=0,i=t.length;r<i;r++)se(e,t[r],n);return n}(h||"*",n.nodeType?[n]:n,[]),f=!d||!e&&h?c:Te(c,s,d,n,r),p=g?y||(e?d:l||v)?[]:t:f;if(g&&g(f,p,n,r),v){i=Te(p,u),v(i,[],n,r),o=i.length;while(o--)(a=i[o])&&(p[u[o]]=!(f[u[o]]=a))}if(e){if(y||d){if(y){i=[],o=p.length;while(o--)(a=p[o])&&i.push(f[o]=a);y(null,p=[],i,r)}o=p.length;while(o--)(a=p[o])&&-1<(i=y?P(e,a):s[o])&&(e[i]=!(t[i]=a))}}else p=Te(p===t?p.splice(l,p.length):p),y?y(null,t,p,r):H.apply(t,p)})}function Ee(e){for(var i,t,n,r=e.length,o=b.relative[e[0].type],a=o||b.relative[" "],s=o?1:0,u=be(function(e){return e===i},a,!0),l=be(function(e){return-1<P(i,e)},a,!0),c=[function(e,t,n){var r=!o&&(n||t!==w)||((i=t).nodeType?u(e,t,n):l(e,t,n));return i=null,r}];s<r;s++)if(t=b.relative[e[s].type])c=[be(we(c),t)];else{if((t=b.filter[e[s].type].apply(null,e[s].matches))[S]){for(n=++s;n<r;n++)if(b.relative[e[n].type])break;return Ce(1<s&&we(c),1<s&&xe(e.slice(0,s-1).concat({value:" "===e[s-2].type?"*":""})).replace($,"$1"),t,s<n&&Ee(e.slice(s,n)),n<r&&Ee(e=e.slice(n)),n<r&&xe(e))}c.push(t)}return we(c)}return me.prototype=b.filters=b.pseudos,b.setFilters=new me,h=se.tokenize=function(e,t){var n,r,i,o,a,s,u,l=x[e+" "];if(l)return t?0:l.slice(0);a=e,s=[],u=b.preFilter;while(a){for(o in n&&!(r=_.exec(a))||(r&&(a=a.slice(r[0].length)||a),s.push(i=[])),n=!1,(r=z.exec(a))&&(n=r.shift(),i.push({value:n,type:r[0].replace($," ")}),a=a.slice(n.length)),b.filter)!(r=G[o].exec(a))||u[o]&&!(r=u[o](r))||(n=r.shift(),i.push({value:n,type:o,matches:r}),a=a.slice(n.length));if(!n)break}return t?a.length:a?se.error(e):x(e,s).slice(0)},f=se.compile=function(e,t){var n,v,y,m,x,r,i=[],o=[],a=A[e+" "];if(!a){t||(t=h(e)),n=t.length;while(n--)(a=Ee(t[n]))[S]?i.push(a):o.push(a);(a=A(e,(v=o,m=0<(y=i).length,x=0<v.length,r=function(e,t,n,r,i){var o,a,s,u=0,l="0",c=e&&[],f=[],p=w,d=e||x&&b.find.TAG("*",i),h=k+=null==p?1:Math.random()||.1,g=d.length;for(i&&(w=t==C||t||i);l!==g&&null!=(o=d[l]);l++){if(x&&o){a=0,t||o.ownerDocument==C||(T(o),n=!E);while(s=v[a++])if(s(o,t||C,n)){r.push(o);break}i&&(k=h)}m&&((o=!s&&o)&&u--,e&&c.push(o))}if(u+=l,m&&l!==u){a=0;while(s=y[a++])s(c,f,t,n);if(e){if(0<u)while(l--)c[l]||f[l]||(f[l]=q.call(r));f=Te(f)}H.apply(r,f),i&&!e&&0<f.length&&1<u+y.length&&se.uniqueSort(r)}return i&&(k=h,w=p),c},m?le(r):r))).selector=e}return a},g=se.select=function(e,t,n,r){var i,o,a,s,u,l="function"==typeof e&&e,c=!r&&h(e=l.selector||e);if(n=n||[],1===c.length){if(2<(o=c[0]=c[0].slice(0)).length&&"ID"===(a=o[0]).type&&9===t.nodeType&&E&&b.relative[o[1].type]){if(!(t=(b.find.ID(a.matches[0].replace(te,ne),t)||[])[0]))return n;l&&(t=t.parentNode),e=e.slice(o.shift().value.length)}i=G.needsContext.test(e)?0:o.length;while(i--){if(a=o[i],b.relative[s=a.type])break;if((u=b.find[s])&&(r=u(a.matches[0].replace(te,ne),ee.test(o[0].type)&&ye(t.parentNode)||t))){if(o.splice(i,1),!(e=r.length&&xe(o)))return H.apply(n,r),n;break}}}return(l||f(e,c))(r,t,!E,n,!t||ee.test(e)&&ye(t.parentNode)||t),n},d.sortStable=S.split("").sort(D).join("")===S,d.detectDuplicates=!!l,T(),d.sortDetached=ce(function(e){return 1&e.compareDocumentPosition(C.createElement("fieldset"))}),ce(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||fe("type|href|height|width",function(e,t,n){if(!n)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),d.attributes&&ce(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||fe("value",function(e,t,n){if(!n&&"input"===e.nodeName.toLowerCase())return e.defaultValue}),ce(function(e){return null==e.getAttribute("disabled")})||fe(R,function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),se}(C);S.find=d,S.expr=d.selectors,S.expr[":"]=S.expr.pseudos,S.uniqueSort=S.unique=d.uniqueSort,S.text=d.getText,S.isXMLDoc=d.isXML,S.contains=d.contains,S.escapeSelector=d.escape;var h=function(e,t,n){var r=[],i=void 0!==n;while((e=e[t])&&9!==e.nodeType)if(1===e.nodeType){if(i&&S(e).is(n))break;r.push(e)}return r},T=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},k=S.expr.match.needsContext;function A(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var N=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function D(e,n,r){return m(n)?S.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?S.grep(e,function(e){return e===n!==r}):"string"!=typeof n?S.grep(e,function(e){return-1<i.call(n,e)!==r}):S.filter(n,e,r)}S.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?S.find.matchesSelector(r,e)?[r]:[]:S.find.matches(e,S.grep(t,function(e){return 1===e.nodeType}))},S.fn.extend({find:function(e){var t,n,r=this.length,i=this;if("string"!=typeof e)return this.pushStack(S(e).filter(function(){for(t=0;t<r;t++)if(S.contains(i[t],this))return!0}));for(n=this.pushStack([]),t=0;t<r;t++)S.find(e,i[t],n);return 1<r?S.uniqueSort(n):n},filter:function(e){return this.pushStack(D(this,e||[],!1))},not:function(e){return this.pushStack(D(this,e||[],!0))},is:function(e){return!!D(this,"string"==typeof e&&k.test(e)?S(e):e||[],!1).length}});var j,q=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(S.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||j,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof S?t[0]:t,S.merge(this,S.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),N.test(r[1])&&S.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(S):S.makeArray(e,this)}).prototype=S.fn,j=S(E);var L=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function O(e,t){while((e=e[t])&&1!==e.nodeType);return e}S.fn.extend({has:function(e){var t=S(e,this),n=t.length;return this.filter(function(){for(var e=0;e<n;e++)if(S.contains(this,t[e]))return!0})},closest:function(e,t){var n,r=0,i=this.length,o=[],a="string"!=typeof e&&S(e);if(!k.test(e))for(;r<i;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?-1<a.index(n):1===n.nodeType&&S.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(1<o.length?S.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?i.call(S(e),this[0]):i.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(S.uniqueSort(S.merge(this.get(),S(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),S.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return h(e,"parentNode")},parentsUntil:function(e,t,n){return h(e,"parentNode",n)},next:function(e){return O(e,"nextSibling")},prev:function(e){return O(e,"previousSibling")},nextAll:function(e){return h(e,"nextSibling")},prevAll:function(e){return h(e,"previousSibling")},nextUntil:function(e,t,n){return h(e,"nextSibling",n)},prevUntil:function(e,t,n){return h(e,"previousSibling",n)},siblings:function(e){return T((e.parentNode||{}).firstChild,e)},children:function(e){return T(e.firstChild)},contents:function(e){return null!=e.contentDocument&&r(e.contentDocument)?e.contentDocument:(A(e,"template")&&(e=e.content||e),S.merge([],e.childNodes))}},function(r,i){S.fn[r]=function(e,t){var n=S.map(this,i,e);return"Until"!==r.slice(-5)&&(t=e),t&&"string"==typeof t&&(n=S.filter(t,n)),1<this.length&&(H[r]||S.uniqueSort(n),L.test(r)&&n.reverse()),this.pushStack(n)}});var P=/[^\x20\t\r\n\f]+/g;function R(e){return e}function M(e){throw e}function I(e,t,n,r){var i;try{e&&m(i=e.promise)?i.call(e).done(t).fail(n):e&&m(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}S.Callbacks=function(r){var e,n;r="string"==typeof r?(e=r,n={},S.each(e.match(P)||[],function(e,t){n[t]=!0}),n):S.extend({},r);var i,t,o,a,s=[],u=[],l=-1,c=function(){for(a=a||r.once,o=i=!0;u.length;l=-1){t=u.shift();while(++l<s.length)!1===s[l].apply(t[0],t[1])&&r.stopOnFalse&&(l=s.length,t=!1)}r.memory||(t=!1),i=!1,a&&(s=t?[]:"")},f={add:function(){return s&&(t&&!i&&(l=s.length-1,u.push(t)),function n(e){S.each(e,function(e,t){m(t)?r.unique&&f.has(t)||s.push(t):t&&t.length&&"string"!==w(t)&&n(t)})}(arguments),t&&!i&&c()),this},remove:function(){return S.each(arguments,function(e,t){var n;while(-1<(n=S.inArray(t,s,n)))s.splice(n,1),n<=l&&l--}),this},has:function(e){return e?-1<S.inArray(e,s):0<s.length},empty:function(){return s&&(s=[]),this},disable:function(){return a=u=[],s=t="",this},disabled:function(){return!s},lock:function(){return a=u=[],t||i||(s=t=""),this},locked:function(){return!!a},fireWith:function(e,t){return a||(t=[e,(t=t||[]).slice?t.slice():t],u.push(t),i||c()),this},fire:function(){return f.fireWith(this,arguments),this},fired:function(){return!!o}};return f},S.extend({Deferred:function(e){var o=[["notify","progress",S.Callbacks("memory"),S.Callbacks("memory"),2],["resolve","done",S.Callbacks("once memory"),S.Callbacks("once memory"),0,"resolved"],["reject","fail",S.Callbacks("once memory"),S.Callbacks("once memory"),1,"rejected"]],i="pending",a={state:function(){return i},always:function(){return s.done(arguments).fail(arguments),this},"catch":function(e){return a.then(null,e)},pipe:function(){var i=arguments;return S.Deferred(function(r){S.each(o,function(e,t){var n=m(i[t[4]])&&i[t[4]];s[t[1]](function(){var e=n&&n.apply(this,arguments);e&&m(e.promise)?e.promise().progress(r.notify).done(r.resolve).fail(r.reject):r[t[0]+"With"](this,n?[e]:arguments)})}),i=null}).promise()},then:function(t,n,r){var u=0;function l(i,o,a,s){return function(){var n=this,r=arguments,e=function(){var e,t;if(!(i<u)){if((e=a.apply(n,r))===o.promise())throw new TypeError("Thenable self-resolution");t=e&&("object"==typeof e||"function"==typeof e)&&e.then,m(t)?s?t.call(e,l(u,o,R,s),l(u,o,M,s)):(u++,t.call(e,l(u,o,R,s),l(u,o,M,s),l(u,o,R,o.notifyWith))):(a!==R&&(n=void 0,r=[e]),(s||o.resolveWith)(n,r))}},t=s?e:function(){try{e()}catch(e){S.Deferred.exceptionHook&&S.Deferred.exceptionHook(e,t.stackTrace),u<=i+1&&(a!==M&&(n=void 0,r=[e]),o.rejectWith(n,r))}};i?t():(S.Deferred.getStackHook&&(t.stackTrace=S.Deferred.getStackHook()),C.setTimeout(t))}}return S.Deferred(function(e){o[0][3].add(l(0,e,m(r)?r:R,e.notifyWith)),o[1][3].add(l(0,e,m(t)?t:R)),o[2][3].add(l(0,e,m(n)?n:M))}).promise()},promise:function(e){return null!=e?S.extend(e,a):a}},s={};return S.each(o,function(e,t){var n=t[2],r=t[5];a[t[1]]=n.add,r&&n.add(function(){i=r},o[3-e][2].disable,o[3-e][3].disable,o[0][2].lock,o[0][3].lock),n.add(t[3].fire),s[t[0]]=function(){return s[t[0]+"With"](this===s?void 0:this,arguments),this},s[t[0]+"With"]=n.fireWith}),a.promise(s),e&&e.call(s,s),s},when:function(e){var n=arguments.length,t=n,r=Array(t),i=s.call(arguments),o=S.Deferred(),a=function(t){return function(e){r[t]=this,i[t]=1<arguments.length?s.call(arguments):e,--n||o.resolveWith(r,i)}};if(n<=1&&(I(e,o.done(a(t)).resolve,o.reject,!n),"pending"===o.state()||m(i[t]&&i[t].then)))return o.then();while(t--)I(i[t],a(t),o.reject);return o.promise()}});var W=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;S.Deferred.exceptionHook=function(e,t){C.console&&C.console.warn&&e&&W.test(e.name)&&C.console.warn("jQuery.Deferred exception: "+e.message,e.stack,t)},S.readyException=function(e){C.setTimeout(function(){throw e})};var F=S.Deferred();function B(){E.removeEventListener("DOMContentLoaded",B),C.removeEventListener("load",B),S.ready()}S.fn.ready=function(e){return F.then(e)["catch"](function(e){S.readyException(e)}),this},S.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--S.readyWait:S.isReady)||(S.isReady=!0)!==e&&0<--S.readyWait||F.resolveWith(E,[S])}}),S.ready.then=F.then,"complete"===E.readyState||"loading"!==E.readyState&&!E.documentElement.doScroll?C.setTimeout(S.ready):(E.addEventListener("DOMContentLoaded",B),C.addEventListener("load",B));var $=function(e,t,n,r,i,o,a){var s=0,u=e.length,l=null==n;if("object"===w(n))for(s in i=!0,n)$(e,t,s,n[s],!0,o,a);else if(void 0!==r&&(i=!0,m(r)||(a=!0),l&&(a?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(S(e),n)})),t))for(;s<u;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return i?e:l?t.call(e):u?t(e[0],n):o},_=/^-ms-/,z=/-([a-z])/g;function U(e,t){return t.toUpperCase()}function X(e){return e.replace(_,"ms-").replace(z,U)}var V=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};function G(){this.expando=S.expando+G.uid++}G.uid=1,G.prototype={cache:function(e){var t=e[this.expando];return t||(t={},V(e)&&(e.nodeType?e[this.expando]=t:Object.defineProperty(e,this.expando,{value:t,configurable:!0}))),t},set:function(e,t,n){var r,i=this.cache(e);if("string"==typeof t)i[X(t)]=n;else for(r in t)i[X(r)]=t[r];return i},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][X(t)]},access:function(e,t,n){return void 0===t||t&&"string"==typeof t&&void 0===n?this.get(e,t):(this.set(e,t,n),void 0!==n?n:t)},remove:function(e,t){var n,r=e[this.expando];if(void 0!==r){if(void 0!==t){n=(t=Array.isArray(t)?t.map(X):(t=X(t))in r?[t]:t.match(P)||[]).length;while(n--)delete r[t[n]]}(void 0===t||S.isEmptyObject(r))&&(e.nodeType?e[this.expando]=void 0:delete e[this.expando])}},hasData:function(e){var t=e[this.expando];return void 0!==t&&!S.isEmptyObject(t)}};var Y=new G,Q=new G,J=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,K=/[A-Z]/g;function Z(e,t,n){var r,i;if(void 0===n&&1===e.nodeType)if(r="data-"+t.replace(K,"-$&").toLowerCase(),"string"==typeof(n=e.getAttribute(r))){try{n="true"===(i=n)||"false"!==i&&("null"===i?null:i===+i+""?+i:J.test(i)?JSON.parse(i):i)}catch(e){}Q.set(e,t,n)}else n=void 0;return n}S.extend({hasData:function(e){return Q.hasData(e)||Y.hasData(e)},data:function(e,t,n){return Q.access(e,t,n)},removeData:function(e,t){Q.remove(e,t)},_data:function(e,t,n){return Y.access(e,t,n)},_removeData:function(e,t){Y.remove(e,t)}}),S.fn.extend({data:function(n,e){var t,r,i,o=this[0],a=o&&o.attributes;if(void 0===n){if(this.length&&(i=Q.get(o),1===o.nodeType&&!Y.get(o,"hasDataAttrs"))){t=a.length;while(t--)a[t]&&0===(r=a[t].name).indexOf("data-")&&(r=X(r.slice(5)),Z(o,r,i[r]));Y.set(o,"hasDataAttrs",!0)}return i}return"object"==typeof n?this.each(function(){Q.set(this,n)}):$(this,function(e){var t;if(o&&void 0===e)return void 0!==(t=Q.get(o,n))?t:void 0!==(t=Z(o,n))?t:void 0;this.each(function(){Q.set(this,n,e)})},null,e,1<arguments.length,null,!0)},removeData:function(e){return this.each(function(){Q.remove(this,e)})}}),S.extend({queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=Y.get(e,t),n&&(!r||Array.isArray(n)?r=Y.access(e,t,S.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||"fx";var n=S.queue(e,t),r=n.length,i=n.shift(),o=S._queueHooks(e,t);"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,function(){S.dequeue(e,t)},o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return Y.get(e,n)||Y.access(e,n,{empty:S.Callbacks("once memory").add(function(){Y.remove(e,[t+"queue",n])})})}}),S.fn.extend({queue:function(t,n){var e=2;return"string"!=typeof t&&(n=t,t="fx",e--),arguments.length<e?S.queue(this[0],t):void 0===n?this:this.each(function(){var e=S.queue(this,t,n);S._queueHooks(this,t),"fx"===t&&"inprogress"!==e[0]&&S.dequeue(this,t)})},dequeue:function(e){return this.each(function(){S.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,i=S.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};"string"!=typeof e&&(t=e,e=void 0),e=e||"fx";while(a--)(n=Y.get(o[a],e+"queueHooks"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var ee=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,te=new RegExp("^(?:([+-])=|)("+ee+")([a-z%]*)$","i"),ne=["Top","Right","Bottom","Left"],re=E.documentElement,ie=function(e){return S.contains(e.ownerDocument,e)},oe={composed:!0};re.getRootNode&&(ie=function(e){return S.contains(e.ownerDocument,e)||e.getRootNode(oe)===e.ownerDocument});var ae=function(e,t){return"none"===(e=t||e).style.display||""===e.style.display&&ie(e)&&"none"===S.css(e,"display")};function se(e,t,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return S.css(e,t,"")},u=s(),l=n&&n[3]||(S.cssNumber[t]?"":"px"),c=e.nodeType&&(S.cssNumber[t]||"px"!==l&&+u)&&te.exec(S.css(e,t));if(c&&c[3]!==l){u/=2,l=l||c[3],c=+u||1;while(a--)S.style(e,t,c+l),(1-o)*(1-(o=s()/u||.5))<=0&&(a=0),c/=o;c*=2,S.style(e,t,c+l),n=n||[]}return n&&(c=+c||+u||0,i=n[1]?c+(n[1]+1)*n[2]:+n[2],r&&(r.unit=l,r.start=c,r.end=i)),i}var ue={};function le(e,t){for(var n,r,i,o,a,s,u,l=[],c=0,f=e.length;c<f;c++)(r=e[c]).style&&(n=r.style.display,t?("none"===n&&(l[c]=Y.get(r,"display")||null,l[c]||(r.style.display="")),""===r.style.display&&ae(r)&&(l[c]=(u=a=o=void 0,a=(i=r).ownerDocument,s=i.nodeName,(u=ue[s])||(o=a.body.appendChild(a.createElement(s)),u=S.css(o,"display"),o.parentNode.removeChild(o),"none"===u&&(u="block"),ue[s]=u)))):"none"!==n&&(l[c]="none",Y.set(r,"display",n)));for(c=0;c<f;c++)null!=l[c]&&(e[c].style.display=l[c]);return e}S.fn.extend({show:function(){return le(this,!0)},hide:function(){return le(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){ae(this)?S(this).show():S(this).hide()})}});var ce,fe,pe=/^(?:checkbox|radio)$/i,de=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i;ce=E.createDocumentFragment().appendChild(E.createElement("div")),(fe=E.createElement("input")).setAttribute("type","radio"),fe.setAttribute("checked","checked"),fe.setAttribute("name","t"),ce.appendChild(fe),y.checkClone=ce.cloneNode(!0).cloneNode(!0).lastChild.checked,ce.innerHTML="<textarea>x</textarea>",y.noCloneChecked=!!ce.cloneNode(!0).lastChild.defaultValue,ce.innerHTML="<option></option>",y.option=!!ce.lastChild;var ge={thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?S.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n<r;n++)Y.set(e[n],"globalEval",!t||Y.get(t[n],"globalEval"))}ge.tbody=ge.tfoot=ge.colgroup=ge.caption=ge.thead,ge.th=ge.td,y.option||(ge.optgroup=ge.option=[1,"<select multiple='multiple'>","</select>"]);var me=/<|&#?\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d<h;d++)if((o=e[d])||0===o)if("object"===w(o))S.merge(p,o.nodeType?[o]:o);else if(me.test(o)){a=a||f.appendChild(t.createElement("div")),s=(de.exec(o)||["",""])[1].toLowerCase(),u=ge[s]||ge._default,a.innerHTML=u[1]+S.htmlPrefilter(o)+u[2],c=u[0];while(c--)a=a.lastChild;S.merge(p,a.childNodes),(a=f.firstChild).textContent=""}else p.push(t.createTextNode(o));f.textContent="",d=0;while(o=p[d++])if(r&&-1<S.inArray(o,r))i&&i.push(o);else if(l=ie(o),a=ve(f.appendChild(o),"script"),l&&ye(a),n){c=0;while(o=a[c++])he.test(o.type||"")&&n.push(o)}return f}var be=/^key/,we=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Te=/^([^.]*)(?:\.(.+)|)/;function Ce(){return!0}function Ee(){return!1}function Se(e,t){return e===function(){try{return E.activeElement}catch(e){}}()==("focus"===t)}function ke(e,t,n,r,i,o){var a,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)ke(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=Ee;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return S().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=S.guid++)),e.each(function(){S.event.add(this,t,i,r,n)})}function Ae(e,i,o){o?(Y.set(e,i,!1),S.event.add(e,i,{namespace:!1,handler:function(e){var t,n,r=Y.get(this,i);if(1&e.isTrigger&&this[i]){if(r.length)(S.event.special[i]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),Y.set(this,i,r),t=o(this,i),this[i](),r!==(n=Y.get(this,i))||t?Y.set(this,i,!1):n={},r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n.value}else r.length&&(Y.set(this,i,{value:S.event.trigger(S.extend(r[0],S.Event.prototype),r.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===Y.get(e,i)&&S.event.add(e,i,Ce)}S.event={global:{},add:function(t,e,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Y.get(t);if(V(t)){n.handler&&(n=(o=n).handler,i=o.selector),i&&S.find.matchesSelector(re,i),n.guid||(n.guid=S.guid++),(u=v.events)||(u=v.events=Object.create(null)),(a=v.handle)||(a=v.handle=function(e){return"undefined"!=typeof S&&S.event.triggered!==e.type?S.event.dispatch.apply(t,arguments):void 0}),l=(e=(e||"").match(P)||[""]).length;while(l--)d=g=(s=Te.exec(e[l])||[])[1],h=(s[2]||"").split(".").sort(),d&&(f=S.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=S.event.special[d]||{},c=S.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&S.expr.match.needsContext.test(i),namespace:h.join(".")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,h,a)||t.addEventListener&&t.addEventListener(d,a)),f.add&&(f.add.call(t,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),S.event.global[d]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Y.hasData(e)&&Y.get(e);if(v&&(u=v.events)){l=(t=(t||"").match(P)||[""]).length;while(l--)if(d=g=(s=Te.exec(t[l])||[])[1],h=(s[2]||"").split(".").sort(),d){f=S.event.special[d]||{},p=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=p.length;while(o--)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,v.handle)||S.removeEvent(e,d,v.handle),delete u[d])}else for(d in u)S.event.remove(e,d+t[l],n,r,!0);S.isEmptyObject(u)&&Y.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=new Array(arguments.length),u=S.event.fix(e),l=(Y.get(this,"events")||Object.create(null))[u.type]||[],c=S.event.special[u.type]||{};for(s[0]=u,t=1;t<arguments.length;t++)s[t]=arguments[t];if(u.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,u)){a=S.event.handlers.call(this,u,l),t=0;while((i=a[t++])&&!u.isPropagationStopped()){u.currentTarget=i.elem,n=0;while((o=i.handlers[n++])&&!u.isImmediatePropagationStopped())u.rnamespace&&!1!==o.namespace&&!u.rnamespace.test(o.namespace)||(u.handleObj=o,u.data=o.data,void 0!==(r=((S.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,s))&&!1===(u.result=r)&&(u.preventDefault(),u.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,u),u.result}},handlers:function(e,t){var n,r,i,o,a,s=[],u=t.delegateCount,l=e.target;if(u&&l.nodeType&&!("click"===e.type&&1<=e.button))for(;l!==this;l=l.parentNode||this)if(1===l.nodeType&&("click"!==e.type||!0!==l.disabled)){for(o=[],a={},n=0;n<u;n++)void 0===a[i=(r=t[n]).selector+" "]&&(a[i]=r.needsContext?-1<S(i,this).index(l):S.find(i,this,null,[l]).length),a[i]&&o.push(r);o.length&&s.push({elem:l,handlers:o})}return l=this,u<t.length&&s.push({elem:l,handlers:t.slice(u)}),s},addProp:function(t,e){Object.defineProperty(S.Event.prototype,t,{enumerable:!0,configurable:!0,get:m(e)?function(){if(this.originalEvent)return e(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[t]},set:function(e){Object.defineProperty(this,t,{enumerable:!0,configurable:!0,writable:!0,value:e})}})},fix:function(e){return e[S.expando]?e:new S.Event(e)},special:{load:{noBubble:!0},click:{setup:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,"input")&&Ae(t,"click",Ce),!1},trigger:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,"input")&&Ae(t,"click"),!0},_default:function(e){var t=e.target;return pe.test(t.type)&&t.click&&A(t,"input")&&Y.get(t,"click")||A(t,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},S.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},S.Event=function(e,t){if(!(this instanceof S.Event))return new S.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?Ce:Ee,this.target=e.target&&3===e.target.nodeType?e.target.parentNode:e.target,this.currentTarget=e.currentTarget,this.relatedTarget=e.relatedTarget):this.type=e,t&&S.extend(this,t),this.timeStamp=e&&e.timeStamp||Date.now(),this[S.expando]=!0},S.Event.prototype={constructor:S.Event,isDefaultPrevented:Ee,isPropagationStopped:Ee,isImmediatePropagationStopped:Ee,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=Ce,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=Ce,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=Ce,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},S.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,"char":!0,code:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(e){var t=e.button;return null==e.which&&be.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&we.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},S.event.addProp),S.each({focus:"focusin",blur:"focusout"},function(e,t){S.event.special[e]={setup:function(){return Ae(this,e,Se),!1},trigger:function(){return Ae(this,e),!0},delegateType:t}}),S.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,i){S.event.special[e]={delegateType:i,bindType:i,handle:function(e){var t,n=e.relatedTarget,r=e.handleObj;return n&&(n===this||S.contains(this,n))||(e.type=r.origType,t=r.handler.apply(this,arguments),e.type=i),t}}}),S.fn.extend({on:function(e,t,n,r){return ke(this,e,t,n,r)},one:function(e,t,n,r){return ke(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,S(e.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"==typeof e){for(i in e)this.off(i,t,e[i]);return this}return!1!==t&&"function"!=typeof t||(n=t,t=void 0),!1===n&&(n=Ee),this.each(function(){S.event.remove(this,e,n,t)})}});var Ne=/<script|<style|<link/i,De=/checked\s*(?:[^=]|=\s*.checked.)/i,je=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function qe(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&S(e).children("tbody")[0]||e}function Le(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function He(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Oe(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(Y.hasData(e)&&(s=Y.get(e).events))for(i in Y.remove(t,"handle events"),s)for(n=0,r=s[i].length;n<r;n++)S.event.add(t,i,s[i][n]);Q.hasData(e)&&(o=Q.access(e),a=S.extend({},o),Q.set(t,a))}}function Pe(n,r,i,o){r=g(r);var e,t,a,s,u,l,c=0,f=n.length,p=f-1,d=r[0],h=m(d);if(h||1<f&&"string"==typeof d&&!y.checkClone&&De.test(d))return n.each(function(e){var t=n.eq(e);h&&(r[0]=d.call(this,e,t.html())),Pe(t,r,i,o)});if(f&&(t=(e=xe(r,n[0].ownerDocument,!1,n,o)).firstChild,1===e.childNodes.length&&(e=t),t||o)){for(s=(a=S.map(ve(e,"script"),Le)).length;c<f;c++)u=e,c!==p&&(u=S.clone(u,!0,!0),s&&S.merge(a,ve(u,"script"))),i.call(n[c],u,c);if(s)for(l=a[a.length-1].ownerDocument,S.map(a,He),c=0;c<s;c++)u=a[c],he.test(u.type||"")&&!Y.access(u,"globalEval")&&S.contains(l,u)&&(u.src&&"module"!==(u.type||"").toLowerCase()?S._evalUrl&&!u.noModule&&S._evalUrl(u.src,{nonce:u.nonce||u.getAttribute("nonce")},l):b(u.textContent.replace(je,""),u,l))}return n}function Re(e,t,n){for(var r,i=t?S.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||S.cleanData(ve(r)),r.parentNode&&(n&&ie(r)&&ye(ve(r,"script")),r.parentNode.removeChild(r));return e}S.extend({htmlPrefilter:function(e){return e},clone:function(e,t,n){var r,i,o,a,s,u,l,c=e.cloneNode(!0),f=ie(e);if(!(y.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||S.isXMLDoc(e)))for(a=ve(c),r=0,i=(o=ve(e)).length;r<i;r++)s=o[r],u=a[r],void 0,"input"===(l=u.nodeName.toLowerCase())&&pe.test(s.type)?u.checked=s.checked:"input"!==l&&"textarea"!==l||(u.defaultValue=s.defaultValue);if(t)if(n)for(o=o||ve(e),a=a||ve(c),r=0,i=o.length;r<i;r++)Oe(o[r],a[r]);else Oe(e,c);return 0<(a=ve(c,"script")).length&&ye(a,!f&&ve(e,"script")),c},cleanData:function(e){for(var t,n,r,i=S.event.special,o=0;void 0!==(n=e[o]);o++)if(V(n)){if(t=n[Y.expando]){if(t.events)for(r in t.events)i[r]?S.event.remove(n,r):S.removeEvent(n,r,t.handle);n[Y.expando]=void 0}n[Q.expando]&&(n[Q.expando]=void 0)}}}),S.fn.extend({detach:function(e){return Re(this,e,!0)},remove:function(e){return Re(this,e)},text:function(e){return $(this,function(e){return void 0===e?S.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)})},null,e,arguments.length)},append:function(){return Pe(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||qe(this,e).appendChild(e)})},prepend:function(){return Pe(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=qe(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return Pe(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return Pe(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(S.cleanData(ve(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return S.clone(this,e,t)})},html:function(e){return $(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!Ne.test(e)&&!ge[(de.exec(e)||["",""])[1].toLowerCase()]){e=S.htmlPrefilter(e);try{for(;n<r;n++)1===(t=this[n]||{}).nodeType&&(S.cleanData(ve(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var n=[];return Pe(this,arguments,function(e){var t=this.parentNode;S.inArray(this,n)<0&&(S.cleanData(ve(this)),t&&t.replaceChild(e,this))},n)}}),S.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,a){S.fn[e]=function(e){for(var t,n=[],r=S(e),i=r.length-1,o=0;o<=i;o++)t=o===i?this:this.clone(!0),S(r[o])[a](t),u.apply(n,t.get());return this.pushStack(n)}});var Me=new RegExp("^("+ee+")(?!px)[a-z%]+$","i"),Ie=function(e){var t=e.ownerDocument.defaultView;return t&&t.opener||(t=C),t.getComputedStyle(e)},We=function(e,t,n){var r,i,o={};for(i in t)o[i]=e.style[i],e.style[i]=t[i];for(i in r=n.call(e),t)e.style[i]=o[i];return r},Fe=new RegExp(ne.join("|"),"i");function Be(e,t,n){var r,i,o,a,s=e.style;return(n=n||Ie(e))&&(""!==(a=n.getPropertyValue(t)||n[t])||ie(e)||(a=S.style(e,t)),!y.pixelBoxStyles()&&Me.test(a)&&Fe.test(t)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o)),void 0!==a?a+"":a}function $e(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}!function(){function e(){if(l){u.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",l.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",re.appendChild(u).appendChild(l);var e=C.getComputedStyle(l);n="1%"!==e.top,s=12===t(e.marginLeft),l.style.right="60%",o=36===t(e.right),r=36===t(e.width),l.style.position="absolute",i=12===t(l.offsetWidth/3),re.removeChild(u),l=null}}function t(e){return Math.round(parseFloat(e))}var n,r,i,o,a,s,u=E.createElement("div"),l=E.createElement("div");l.style&&(l.style.backgroundClip="content-box",l.cloneNode(!0).style.backgroundClip="",y.clearCloneStyle="content-box"===l.style.backgroundClip,S.extend(y,{boxSizingReliable:function(){return e(),r},pixelBoxStyles:function(){return e(),o},pixelPosition:function(){return e(),n},reliableMarginLeft:function(){return e(),s},scrollboxSize:function(){return e(),i},reliableTrDimensions:function(){var e,t,n,r;return null==a&&(e=E.createElement("table"),t=E.createElement("tr"),n=E.createElement("div"),e.style.cssText="position:absolute;left:-11111px",t.style.height="1px",n.style.height="9px",re.appendChild(e).appendChild(t).appendChild(n),r=C.getComputedStyle(t),a=3<parseInt(r.height),re.removeChild(e)),a}}))}();var _e=["Webkit","Moz","ms"],ze=E.createElement("div").style,Ue={};function Xe(e){var t=S.cssProps[e]||Ue[e];return t||(e in ze?e:Ue[e]=function(e){var t=e[0].toUpperCase()+e.slice(1),n=_e.length;while(n--)if((e=_e[n]+t)in ze)return e}(e)||e)}var Ve=/^(none|table(?!-c[ea]).+)/,Ge=/^--/,Ye={position:"absolute",visibility:"hidden",display:"block"},Qe={letterSpacing:"0",fontWeight:"400"};function Je(e,t,n){var r=te.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||"px"):t}function Ke(e,t,n,r,i,o){var a="width"===t?1:0,s=0,u=0;if(n===(r?"border":"content"))return 0;for(;a<4;a+=2)"margin"===n&&(u+=S.css(e,n+ne[a],!0,i)),r?("content"===n&&(u-=S.css(e,"padding"+ne[a],!0,i)),"margin"!==n&&(u-=S.css(e,"border"+ne[a]+"Width",!0,i))):(u+=S.css(e,"padding"+ne[a],!0,i),"padding"!==n?u+=S.css(e,"border"+ne[a]+"Width",!0,i):s+=S.css(e,"border"+ne[a]+"Width",!0,i));return!r&&0<=o&&(u+=Math.max(0,Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-o-u-s-.5))||0),u}function Ze(e,t,n){var r=Ie(e),i=(!y.boxSizingReliable()||n)&&"border-box"===S.css(e,"boxSizing",!1,r),o=i,a=Be(e,t,r),s="offset"+t[0].toUpperCase()+t.slice(1);if(Me.test(a)){if(!n)return a;a="auto"}return(!y.boxSizingReliable()&&i||!y.reliableTrDimensions()&&A(e,"tr")||"auto"===a||!parseFloat(a)&&"inline"===S.css(e,"display",!1,r))&&e.getClientRects().length&&(i="border-box"===S.css(e,"boxSizing",!1,r),(o=s in e)&&(a=e[s])),(a=parseFloat(a)||0)+Ke(e,t,n||(i?"border":"content"),o,r,a)+"px"}function et(e,t,n,r,i){return new et.prototype.init(e,t,n,r,i)}S.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Be(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,a,s=X(t),u=Ge.test(t),l=e.style;if(u||(t=Xe(s)),a=S.cssHooks[t]||S.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(i=a.get(e,!1,r))?i:l[t];"string"===(o=typeof n)&&(i=te.exec(n))&&i[1]&&(n=se(e,t,i),o="number"),null!=n&&n==n&&("number"!==o||u||(n+=i&&i[3]||(S.cssNumber[s]?"":"px")),y.clearCloneStyle||""!==n||0!==t.indexOf("background")||(l[t]="inherit"),a&&"set"in a&&void 0===(n=a.set(e,n,r))||(u?l.setProperty(t,n):l[t]=n))}},css:function(e,t,n,r){var i,o,a,s=X(t);return Ge.test(t)||(t=Xe(s)),(a=S.cssHooks[t]||S.cssHooks[s])&&"get"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=Be(e,t,r)),"normal"===i&&t in Qe&&(i=Qe[t]),""===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),S.each(["height","width"],function(e,u){S.cssHooks[u]={get:function(e,t,n){if(t)return!Ve.test(S.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?Ze(e,u,n):We(e,Ye,function(){return Ze(e,u,n)})},set:function(e,t,n){var r,i=Ie(e),o=!y.scrollboxSize()&&"absolute"===i.position,a=(o||n)&&"border-box"===S.css(e,"boxSizing",!1,i),s=n?Ke(e,u,n,a,i):0;return a&&o&&(s-=Math.ceil(e["offset"+u[0].toUpperCase()+u.slice(1)]-parseFloat(i[u])-Ke(e,u,"border",!1,i)-.5)),s&&(r=te.exec(t))&&"px"!==(r[3]||"px")&&(e.style[u]=t,t=S.css(e,u)),Je(0,t,s)}}}),S.cssHooks.marginLeft=$e(y.reliableMarginLeft,function(e,t){if(t)return(parseFloat(Be(e,"marginLeft"))||e.getBoundingClientRect().left-We(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}))+"px"}),S.each({margin:"",padding:"",border:"Width"},function(i,o){S.cssHooks[i+o]={expand:function(e){for(var t=0,n={},r="string"==typeof e?e.split(" "):[e];t<4;t++)n[i+ne[t]+o]=r[t]||r[t-2]||r[0];return n}},"margin"!==i&&(S.cssHooks[i+o].set=Je)}),S.fn.extend({css:function(e,t){return $(this,function(e,t,n){var r,i,o={},a=0;if(Array.isArray(t)){for(r=Ie(e),i=t.length;a<i;a++)o[t[a]]=S.css(e,t[a],!1,r);return o}return void 0!==n?S.style(e,t,n):S.css(e,t)},e,t,1<arguments.length)}}),((S.Tween=et).prototype={constructor:et,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||S.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(S.cssNumber[n]?"":"px")},cur:function(){var e=et.propHooks[this.prop];return e&&e.get?e.get(this):et.propHooks._default.get(this)},run:function(e){var t,n=et.propHooks[this.prop];return this.options.duration?this.pos=t=S.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):et.propHooks._default.set(this),this}}).init.prototype=et.prototype,(et.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=S.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){S.fx.step[e.prop]?S.fx.step[e.prop](e):1!==e.elem.nodeType||!S.cssHooks[e.prop]&&null==e.elem.style[Xe(e.prop)]?e.elem[e.prop]=e.now:S.style(e.elem,e.prop,e.now+e.unit)}}}).scrollTop=et.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},S.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},S.fx=et.prototype.init,S.fx.step={};var tt,nt,rt,it,ot=/^(?:toggle|show|hide)$/,at=/queueHooks$/;function st(){nt&&(!1===E.hidden&&C.requestAnimationFrame?C.requestAnimationFrame(st):C.setTimeout(st,S.fx.interval),S.fx.tick())}function ut(){return C.setTimeout(function(){tt=void 0}),tt=Date.now()}function lt(e,t){var n,r=0,i={height:e};for(t=t?1:0;r<4;r+=2-t)i["margin"+(n=ne[r])]=i["padding"+n]=e;return t&&(i.opacity=i.width=e),i}function ct(e,t,n){for(var r,i=(ft.tweeners[t]||[]).concat(ft.tweeners["*"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,t,e))return r}function ft(o,e,t){var n,a,r=0,i=ft.prefilters.length,s=S.Deferred().always(function(){delete u.elem}),u=function(){if(a)return!1;for(var e=tt||ut(),t=Math.max(0,l.startTime+l.duration-e),n=1-(t/l.duration||0),r=0,i=l.tweens.length;r<i;r++)l.tweens[r].run(n);return s.notifyWith(o,[l,n,t]),n<1&&i?t:(i||s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l]),!1)},l=s.promise({elem:o,props:S.extend({},e),opts:S.extend(!0,{specialEasing:{},easing:S.easing._default},t),originalProperties:e,originalOptions:t,startTime:tt||ut(),duration:t.duration,tweens:[],createTween:function(e,t){var n=S.Tween(o,l.opts,e,t,l.opts.specialEasing[e]||l.opts.easing);return l.tweens.push(n),n},stop:function(e){var t=0,n=e?l.tweens.length:0;if(a)return this;for(a=!0;t<n;t++)l.tweens[t].run(1);return e?(s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l,e])):s.rejectWith(o,[l,e]),this}}),c=l.props;for(!function(e,t){var n,r,i,o,a;for(n in e)if(i=t[r=X(n)],o=e[n],Array.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),(a=S.cssHooks[r])&&"expand"in a)for(n in o=a.expand(o),delete e[r],o)n in e||(e[n]=o[n],t[n]=i);else t[r]=i}(c,l.opts.specialEasing);r<i;r++)if(n=ft.prefilters[r].call(l,o,c,l.opts))return m(n.stop)&&(S._queueHooks(l.elem,l.opts.queue).stop=n.stop.bind(n)),n;return S.map(c,ct,l),m(l.opts.start)&&l.opts.start.call(o,l),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always),S.fx.timer(S.extend(u,{elem:o,anim:l,queue:l.opts.queue})),l}S.Animation=S.extend(ft,{tweeners:{"*":[function(e,t){var n=this.createTween(e,t);return se(n.elem,e,te.exec(t),n),n}]},tweener:function(e,t){m(e)?(t=e,e=["*"]):e=e.match(P);for(var n,r=0,i=e.length;r<i;r++)n=e[r],ft.tweeners[n]=ft.tweeners[n]||[],ft.tweeners[n].unshift(t)},prefilters:[function(e,t,n){var r,i,o,a,s,u,l,c,f="width"in t||"height"in t,p=this,d={},h=e.style,g=e.nodeType&&ae(e),v=Y.get(e,"fxshow");for(r in n.queue||(null==(a=S._queueHooks(e,"fx")).unqueued&&(a.unqueued=0,s=a.empty.fire,a.empty.fire=function(){a.unqueued||s()}),a.unqueued++,p.always(function(){p.always(function(){a.unqueued--,S.queue(e,"fx").length||a.empty.fire()})})),t)if(i=t[r],ot.test(i)){if(delete t[r],o=o||"toggle"===i,i===(g?"hide":"show")){if("show"!==i||!v||void 0===v[r])continue;g=!0}d[r]=v&&v[r]||S.style(e,r)}if((u=!S.isEmptyObject(t))||!S.isEmptyObject(d))for(r in f&&1===e.nodeType&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],null==(l=v&&v.display)&&(l=Y.get(e,"display")),"none"===(c=S.css(e,"display"))&&(l?c=l:(le([e],!0),l=e.style.display||l,c=S.css(e,"display"),le([e]))),("inline"===c||"inline-block"===c&&null!=l)&&"none"===S.css(e,"float")&&(u||(p.done(function(){h.display=l}),null==l&&(c=h.display,l="none"===c?"":c)),h.display="inline-block")),n.overflow&&(h.overflow="hidden",p.always(function(){h.overflow=n.overflow[0],h.overflowX=n.overflow[1],h.overflowY=n.overflow[2]})),u=!1,d)u||(v?"hidden"in v&&(g=v.hidden):v=Y.access(e,"fxshow",{display:l}),o&&(v.hidden=!g),g&&le([e],!0),p.done(function(){for(r in g||le([e]),Y.remove(e,"fxshow"),d)S.style(e,r,d[r])})),u=ct(g?v[r]:0,r,p),r in v||(v[r]=u.start,g&&(u.end=u.start,u.start=0))}],prefilter:function(e,t){t?ft.prefilters.unshift(e):ft.prefilters.push(e)}}),S.speed=function(e,t,n){var r=e&&"object"==typeof e?S.extend({},e):{complete:n||!n&&t||m(e)&&e,duration:e,easing:n&&t||t&&!m(t)&&t};return S.fx.off?r.duration=0:"number"!=typeof r.duration&&(r.duration in S.fx.speeds?r.duration=S.fx.speeds[r.duration]:r.duration=S.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue="fx"),r.old=r.complete,r.complete=function(){m(r.old)&&r.old.call(this),r.queue&&S.dequeue(this,r.queue)},r},S.fn.extend({fadeTo:function(e,t,n,r){return this.filter(ae).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(t,e,n,r){var i=S.isEmptyObject(t),o=S.speed(e,n,r),a=function(){var e=ft(this,S.extend({},t),o);(i||Y.get(this,"finish"))&&e.stop(!0)};return a.finish=a,i||!1===o.queue?this.each(a):this.queue(o.queue,a)},stop:function(i,e,o){var a=function(e){var t=e.stop;delete e.stop,t(o)};return"string"!=typeof i&&(o=e,e=i,i=void 0),e&&this.queue(i||"fx",[]),this.each(function(){var e=!0,t=null!=i&&i+"queueHooks",n=S.timers,r=Y.get(this);if(t)r[t]&&r[t].stop&&a(r[t]);else for(t in r)r[t]&&r[t].stop&&at.test(t)&&a(r[t]);for(t=n.length;t--;)n[t].elem!==this||null!=i&&n[t].queue!==i||(n[t].anim.stop(o),e=!1,n.splice(t,1));!e&&o||S.dequeue(this,i)})},finish:function(a){return!1!==a&&(a=a||"fx"),this.each(function(){var e,t=Y.get(this),n=t[a+"queue"],r=t[a+"queueHooks"],i=S.timers,o=n?n.length:0;for(t.finish=!0,S.queue(this,a,[]),r&&r.stop&&r.stop.call(this,!0),e=i.length;e--;)i[e].elem===this&&i[e].queue===a&&(i[e].anim.stop(!0),i.splice(e,1));for(e=0;e<o;e++)n[e]&&n[e].finish&&n[e].finish.call(this);delete t.finish})}}),S.each(["toggle","show","hide"],function(e,r){var i=S.fn[r];S.fn[r]=function(e,t,n){return null==e||"boolean"==typeof e?i.apply(this,arguments):this.animate(lt(r,!0),e,t,n)}}),S.each({slideDown:lt("show"),slideUp:lt("hide"),slideToggle:lt("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,r){S.fn[e]=function(e,t,n){return this.animate(r,e,t,n)}}),S.timers=[],S.fx.tick=function(){var e,t=0,n=S.timers;for(tt=Date.now();t<n.length;t++)(e=n[t])()||n[t]!==e||n.splice(t--,1);n.length||S.fx.stop(),tt=void 0},S.fx.timer=function(e){S.timers.push(e),S.fx.start()},S.fx.interval=13,S.fx.start=function(){nt||(nt=!0,st())},S.fx.stop=function(){nt=null},S.fx.speeds={slow:600,fast:200,_default:400},S.fn.delay=function(r,e){return r=S.fx&&S.fx.speeds[r]||r,e=e||"fx",this.queue(e,function(e,t){var n=C.setTimeout(e,r);t.stop=function(){C.clearTimeout(n)}})},rt=E.createElement("input"),it=E.createElement("select").appendChild(E.createElement("option")),rt.type="checkbox",y.checkOn=""!==rt.value,y.optSelected=it.selected,(rt=E.createElement("input")).value="t",rt.type="radio",y.radioValue="t"===rt.value;var pt,dt=S.expr.attrHandle;S.fn.extend({attr:function(e,t){return $(this,S.attr,e,t,1<arguments.length)},removeAttr:function(e){return this.each(function(){S.removeAttr(this,e)})}}),S.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return"undefined"==typeof e.getAttribute?S.prop(e,t,n):(1===o&&S.isXMLDoc(e)||(i=S.attrHooks[t.toLowerCase()]||(S.expr.match.bool.test(t)?pt:void 0)),void 0!==n?null===n?void S.removeAttr(e,t):i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:(e.setAttribute(t,n+""),n):i&&"get"in i&&null!==(r=i.get(e,t))?r:null==(r=S.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!y.radioValue&&"radio"===t&&A(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,r=0,i=t&&t.match(P);if(i&&1===e.nodeType)while(n=i[r++])e.removeAttribute(n)}}),pt={set:function(e,t,n){return!1===t?S.removeAttr(e,n):e.setAttribute(n,n),n}},S.each(S.expr.match.bool.source.match(/\w+/g),function(e,t){var a=dt[t]||S.find.attr;dt[t]=function(e,t,n){var r,i,o=t.toLowerCase();return n||(i=dt[o],dt[o]=r,r=null!=a(e,t,n)?o:null,dt[o]=i),r}});var ht=/^(?:input|select|textarea|button)$/i,gt=/^(?:a|area)$/i;function vt(e){return(e.match(P)||[]).join(" ")}function yt(e){return e.getAttribute&&e.getAttribute("class")||""}function mt(e){return Array.isArray(e)?e:"string"==typeof e&&e.match(P)||[]}S.fn.extend({prop:function(e,t){return $(this,S.prop,e,t,1<arguments.length)},removeProp:function(e){return this.each(function(){delete this[S.propFix[e]||e]})}}),S.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&S.isXMLDoc(e)||(t=S.propFix[t]||t,i=S.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=S.find.attr(e,"tabindex");return t?parseInt(t,10):ht.test(e.nodeName)||gt.test(e.nodeName)&&e.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),y.optSelected||(S.propHooks.selected={get:function(e){var t=e.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),S.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){S.propFix[this.toLowerCase()]=this}),S.fn.extend({addClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){S(this).addClass(t.call(this,e,yt(this)))});if((e=mt(t)).length)while(n=this[u++])if(i=yt(n),r=1===n.nodeType&&" "+vt(i)+" "){a=0;while(o=e[a++])r.indexOf(" "+o+" ")<0&&(r+=o+" ");i!==(s=vt(r))&&n.setAttribute("class",s)}return this},removeClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){S(this).removeClass(t.call(this,e,yt(this)))});if(!arguments.length)return this.attr("class","");if((e=mt(t)).length)while(n=this[u++])if(i=yt(n),r=1===n.nodeType&&" "+vt(i)+" "){a=0;while(o=e[a++])while(-1<r.indexOf(" "+o+" "))r=r.replace(" "+o+" "," ");i!==(s=vt(r))&&n.setAttribute("class",s)}return this},toggleClass:function(i,t){var o=typeof i,a="string"===o||Array.isArray(i);return"boolean"==typeof t&&a?t?this.addClass(i):this.removeClass(i):m(i)?this.each(function(e){S(this).toggleClass(i.call(this,e,yt(this),t),t)}):this.each(function(){var e,t,n,r;if(a){t=0,n=S(this),r=mt(i);while(e=r[t++])n.hasClass(e)?n.removeClass(e):n.addClass(e)}else void 0!==i&&"boolean"!==o||((e=yt(this))&&Y.set(this,"__className__",e),this.setAttribute&&this.setAttribute("class",e||!1===i?"":Y.get(this,"__className__")||""))})},hasClass:function(e){var t,n,r=0;t=" "+e+" ";while(n=this[r++])if(1===n.nodeType&&-1<(" "+vt(yt(n))+" ").indexOf(t))return!0;return!1}});var xt=/\r/g;S.fn.extend({val:function(n){var r,e,i,t=this[0];return arguments.length?(i=m(n),this.each(function(e){var t;1===this.nodeType&&(null==(t=i?n.call(this,e,S(this).val()):n)?t="":"number"==typeof t?t+="":Array.isArray(t)&&(t=S.map(t,function(e){return null==e?"":e+""})),(r=S.valHooks[this.type]||S.valHooks[this.nodeName.toLowerCase()])&&"set"in r&&void 0!==r.set(this,t,"value")||(this.value=t))})):t?(r=S.valHooks[t.type]||S.valHooks[t.nodeName.toLowerCase()])&&"get"in r&&void 0!==(e=r.get(t,"value"))?e:"string"==typeof(e=t.value)?e.replace(xt,""):null==e?"":e:void 0}}),S.extend({valHooks:{option:{get:function(e){var t=S.find.attr(e,"value");return null!=t?t:vt(S.text(e))}},select:{get:function(e){var t,n,r,i=e.options,o=e.selectedIndex,a="select-one"===e.type,s=a?null:[],u=a?o+1:i.length;for(r=o<0?u:a?o:0;r<u;r++)if(((n=i[r]).selected||r===o)&&!n.disabled&&(!n.parentNode.disabled||!A(n.parentNode,"optgroup"))){if(t=S(n).val(),a)return t;s.push(t)}return s},set:function(e,t){var n,r,i=e.options,o=S.makeArray(t),a=i.length;while(a--)((r=i[a]).selected=-1<S.inArray(S.valHooks.option.get(r),o))&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),S.each(["radio","checkbox"],function(){S.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=-1<S.inArray(S(e).val(),t)}},y.checkOn||(S.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})}),y.focusin="onfocusin"in C;var bt=/^(?:focusinfocus|focusoutblur)$/,wt=function(e){e.stopPropagation()};S.extend(S.event,{trigger:function(e,t,n,r){var i,o,a,s,u,l,c,f,p=[n||E],d=v.call(e,"type")?e.type:e,h=v.call(e,"namespace")?e.namespace.split("."):[];if(o=f=a=n=n||E,3!==n.nodeType&&8!==n.nodeType&&!bt.test(d+S.event.triggered)&&(-1<d.indexOf(".")&&(d=(h=d.split(".")).shift(),h.sort()),u=d.indexOf(":")<0&&"on"+d,(e=e[S.expando]?e:new S.Event(d,"object"==typeof e&&e)).isTrigger=r?2:3,e.namespace=h.join("."),e.rnamespace=e.namespace?new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,e.result=void 0,e.target||(e.target=n),t=null==t?[e]:S.makeArray(t,[e]),c=S.event.special[d]||{},r||!c.trigger||!1!==c.trigger.apply(n,t))){if(!r&&!c.noBubble&&!x(n)){for(s=c.delegateType||d,bt.test(s+d)||(o=o.parentNode);o;o=o.parentNode)p.push(o),a=o;a===(n.ownerDocument||E)&&p.push(a.defaultView||a.parentWindow||C)}i=0;while((o=p[i++])&&!e.isPropagationStopped())f=o,e.type=1<i?s:c.bindType||d,(l=(Y.get(o,"events")||Object.create(null))[e.type]&&Y.get(o,"handle"))&&l.apply(o,t),(l=u&&o[u])&&l.apply&&V(o)&&(e.result=l.apply(o,t),!1===e.result&&e.preventDefault());return e.type=d,r||e.isDefaultPrevented()||c._default&&!1!==c._default.apply(p.pop(),t)||!V(n)||u&&m(n[d])&&!x(n)&&((a=n[u])&&(n[u]=null),S.event.triggered=d,e.isPropagationStopped()&&f.addEventListener(d,wt),n[d](),e.isPropagationStopped()&&f.removeEventListener(d,wt),S.event.triggered=void 0,a&&(n[u]=a)),e.result}},simulate:function(e,t,n){var r=S.extend(new S.Event,n,{type:e,isSimulated:!0});S.event.trigger(r,null,t)}}),S.fn.extend({trigger:function(e,t){return this.each(function(){S.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];if(n)return S.event.trigger(e,t,n,!0)}}),y.focusin||S.each({focus:"focusin",blur:"focusout"},function(n,r){var i=function(e){S.event.simulate(r,e.target,S.event.fix(e))};S.event.special[r]={setup:function(){var e=this.ownerDocument||this.document||this,t=Y.access(e,r);t||e.addEventListener(n,i,!0),Y.access(e,r,(t||0)+1)},teardown:function(){var e=this.ownerDocument||this.document||this,t=Y.access(e,r)-1;t?Y.access(e,r,t):(e.removeEventListener(n,i,!0),Y.remove(e,r))}}});var Tt=C.location,Ct={guid:Date.now()},Et=/\?/;S.parseXML=function(e){var t;if(!e||"string"!=typeof e)return null;try{t=(new C.DOMParser).parseFromString(e,"text/xml")}catch(e){t=void 0}return t&&!t.getElementsByTagName("parsererror").length||S.error("Invalid XML: "+e),t};var St=/\[\]$/,kt=/\r?\n/g,At=/^(?:submit|button|image|reset|file)$/i,Nt=/^(?:input|select|textarea|keygen)/i;function Dt(n,e,r,i){var t;if(Array.isArray(e))S.each(e,function(e,t){r||St.test(n)?i(n,t):Dt(n+"["+("object"==typeof t&&null!=t?e:"")+"]",t,r,i)});else if(r||"object"!==w(e))i(n,e);else for(t in e)Dt(n+"["+t+"]",e[t],r,i)}S.param=function(e,t){var n,r=[],i=function(e,t){var n=m(t)?t():t;r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==n?"":n)};if(null==e)return"";if(Array.isArray(e)||e.jquery&&!S.isPlainObject(e))S.each(e,function(){i(this.name,this.value)});else for(n in e)Dt(n,e[n],t,i);return r.join("&")},S.fn.extend({serialize:function(){return S.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=S.prop(this,"elements");return e?S.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!S(this).is(":disabled")&&Nt.test(this.nodeName)&&!At.test(e)&&(this.checked||!pe.test(e))}).map(function(e,t){var n=S(this).val();return null==n?null:Array.isArray(n)?S.map(n,function(e){return{name:t.name,value:e.replace(kt,"\r\n")}}):{name:t.name,value:n.replace(kt,"\r\n")}}).get()}});var jt=/%20/g,qt=/#.*$/,Lt=/([?&])_=[^&]*/,Ht=/^(.*?):[ \t]*([^\r\n]*)$/gm,Ot=/^(?:GET|HEAD)$/,Pt=/^\/\//,Rt={},Mt={},It="*/".concat("*"),Wt=E.createElement("a");function Ft(o){return function(e,t){"string"!=typeof e&&(t=e,e="*");var n,r=0,i=e.toLowerCase().match(P)||[];if(m(t))while(n=i[r++])"+"===n[0]?(n=n.slice(1)||"*",(o[n]=o[n]||[]).unshift(t)):(o[n]=o[n]||[]).push(t)}}function Bt(t,i,o,a){var s={},u=t===Mt;function l(e){var r;return s[e]=!0,S.each(t[e]||[],function(e,t){var n=t(i,o,a);return"string"!=typeof n||u||s[n]?u?!(r=n):void 0:(i.dataTypes.unshift(n),l(n),!1)}),r}return l(i.dataTypes[0])||!s["*"]&&l("*")}function $t(e,t){var n,r,i=S.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&S.extend(!0,e,r),e}Wt.href=Tt.href,S.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Tt.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(Tt.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":It,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":S.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?$t($t(e,S.ajaxSettings),t):$t(S.ajaxSettings,e)},ajaxPrefilter:Ft(Rt),ajaxTransport:Ft(Mt),ajax:function(e,t){"object"==typeof e&&(t=e,e=void 0),t=t||{};var c,f,p,n,d,r,h,g,i,o,v=S.ajaxSetup({},t),y=v.context||v,m=v.context&&(y.nodeType||y.jquery)?S(y):S.event,x=S.Deferred(),b=S.Callbacks("once memory"),w=v.statusCode||{},a={},s={},u="canceled",T={readyState:0,getResponseHeader:function(e){var t;if(h){if(!n){n={};while(t=Ht.exec(p))n[t[1].toLowerCase()+" "]=(n[t[1].toLowerCase()+" "]||[]).concat(t[2])}t=n[e.toLowerCase()+" "]}return null==t?null:t.join(", ")},getAllResponseHeaders:function(){return h?p:null},setRequestHeader:function(e,t){return null==h&&(e=s[e.toLowerCase()]=s[e.toLowerCase()]||e,a[e]=t),this},overrideMimeType:function(e){return null==h&&(v.mimeType=e),this},statusCode:function(e){var t;if(e)if(h)T.always(e[T.status]);else for(t in e)w[t]=[w[t],e[t]];return this},abort:function(e){var t=e||u;return c&&c.abort(t),l(0,t),this}};if(x.promise(T),v.url=((e||v.url||Tt.href)+"").replace(Pt,Tt.protocol+"//"),v.type=t.method||t.type||v.method||v.type,v.dataTypes=(v.dataType||"*").toLowerCase().match(P)||[""],null==v.crossDomain){r=E.createElement("a");try{r.href=v.url,r.href=r.href,v.crossDomain=Wt.protocol+"//"+Wt.host!=r.protocol+"//"+r.host}catch(e){v.crossDomain=!0}}if(v.data&&v.processData&&"string"!=typeof v.data&&(v.data=S.param(v.data,v.traditional)),Bt(Rt,v,t,T),h)return T;for(i in(g=S.event&&v.global)&&0==S.active++&&S.event.trigger("ajaxStart"),v.type=v.type.toUpperCase(),v.hasContent=!Ot.test(v.type),f=v.url.replace(qt,""),v.hasContent?v.data&&v.processData&&0===(v.contentType||"").indexOf("application/x-www-form-urlencoded")&&(v.data=v.data.replace(jt,"+")):(o=v.url.slice(f.length),v.data&&(v.processData||"string"==typeof v.data)&&(f+=(Et.test(f)?"&":"?")+v.data,delete v.data),!1===v.cache&&(f=f.replace(Lt,"$1"),o=(Et.test(f)?"&":"?")+"_="+Ct.guid+++o),v.url=f+o),v.ifModified&&(S.lastModified[f]&&T.setRequestHeader("If-Modified-Since",S.lastModified[f]),S.etag[f]&&T.setRequestHeader("If-None-Match",S.etag[f])),(v.data&&v.hasContent&&!1!==v.contentType||t.contentType)&&T.setRequestHeader("Content-Type",v.contentType),T.setRequestHeader("Accept",v.dataTypes[0]&&v.accepts[v.dataTypes[0]]?v.accepts[v.dataTypes[0]]+("*"!==v.dataTypes[0]?", "+It+"; q=0.01":""):v.accepts["*"]),v.headers)T.setRequestHeader(i,v.headers[i]);if(v.beforeSend&&(!1===v.beforeSend.call(y,T,v)||h))return T.abort();if(u="abort",b.add(v.complete),T.done(v.success),T.fail(v.error),c=Bt(Mt,v,t,T)){if(T.readyState=1,g&&m.trigger("ajaxSend",[T,v]),h)return T;v.async&&0<v.timeout&&(d=C.setTimeout(function(){T.abort("timeout")},v.timeout));try{h=!1,c.send(a,l)}catch(e){if(h)throw e;l(-1,e)}}else l(-1,"No Transport");function l(e,t,n,r){var i,o,a,s,u,l=t;h||(h=!0,d&&C.clearTimeout(d),c=void 0,p=r||"",T.readyState=0<e?4:0,i=200<=e&&e<300||304===e,n&&(s=function(e,t,n){var r,i,o,a,s=e.contents,u=e.dataTypes;while("*"===u[0])u.shift(),void 0===r&&(r=e.mimeType||t.getResponseHeader("Content-Type"));if(r)for(i in s)if(s[i]&&s[i].test(r)){u.unshift(i);break}if(u[0]in n)o=u[0];else{for(i in n){if(!u[0]||e.converters[i+" "+u[0]]){o=i;break}a||(a=i)}o=o||a}if(o)return o!==u[0]&&u.unshift(o),n[o]}(v,T,n)),!i&&-1<S.inArray("script",v.dataTypes)&&(v.converters["text script"]=function(){}),s=function(e,t,n,r){var i,o,a,s,u,l={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)l[a.toLowerCase()]=e.converters[a];o=c.shift();while(o)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!u&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u=o,o=c.shift())if("*"===o)o=u;else if("*"!==u&&u!==o){if(!(a=l[u+" "+o]||l["* "+o]))for(i in l)if((s=i.split(" "))[1]===o&&(a=l[u+" "+s[0]]||l["* "+s[0]])){!0===a?a=l[i]:!0!==l[i]&&(o=s[0],c.unshift(s[1]));break}if(!0!==a)if(a&&e["throws"])t=a(t);else try{t=a(t)}catch(e){return{state:"parsererror",error:a?e:"No conversion from "+u+" to "+o}}}return{state:"success",data:t}}(v,s,T,i),i?(v.ifModified&&((u=T.getResponseHeader("Last-Modified"))&&(S.lastModified[f]=u),(u=T.getResponseHeader("etag"))&&(S.etag[f]=u)),204===e||"HEAD"===v.type?l="nocontent":304===e?l="notmodified":(l=s.state,o=s.data,i=!(a=s.error))):(a=l,!e&&l||(l="error",e<0&&(e=0))),T.status=e,T.statusText=(t||l)+"",i?x.resolveWith(y,[o,l,T]):x.rejectWith(y,[T,l,a]),T.statusCode(w),w=void 0,g&&m.trigger(i?"ajaxSuccess":"ajaxError",[T,v,i?o:a]),b.fireWith(y,[T,l]),g&&(m.trigger("ajaxComplete",[T,v]),--S.active||S.event.trigger("ajaxStop")))}return T},getJSON:function(e,t,n){return S.get(e,t,n,"json")},getScript:function(e,t){return S.get(e,void 0,t,"script")}}),S.each(["get","post"],function(e,i){S[i]=function(e,t,n,r){return m(t)&&(r=r||n,n=t,t=void 0),S.ajax(S.extend({url:e,type:i,dataType:r,data:t,success:n},S.isPlainObject(e)&&e))}}),S.ajaxPrefilter(function(e){var t;for(t in e.headers)"content-type"===t.toLowerCase()&&(e.contentType=e.headers[t]||"")}),S._evalUrl=function(e,t,n){return S.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(e){S.globalEval(e,t,n)}})},S.fn.extend({wrapAll:function(e){var t;return this[0]&&(m(e)&&(e=e.call(this[0])),t=S(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstElementChild)e=e.firstElementChild;return e}).append(this)),this},wrapInner:function(n){return m(n)?this.each(function(e){S(this).wrapInner(n.call(this,e))}):this.each(function(){var e=S(this),t=e.contents();t.length?t.wrapAll(n):e.append(n)})},wrap:function(t){var n=m(t);return this.each(function(e){S(this).wrapAll(n?t.call(this,e):t)})},unwrap:function(e){return this.parent(e).not("body").each(function(){S(this).replaceWith(this.childNodes)}),this}}),S.expr.pseudos.hidden=function(e){return!S.expr.pseudos.visible(e)},S.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},S.ajaxSettings.xhr=function(){try{return new C.XMLHttpRequest}catch(e){}};var _t={0:200,1223:204},zt=S.ajaxSettings.xhr();y.cors=!!zt&&"withCredentials"in zt,y.ajax=zt=!!zt,S.ajaxTransport(function(i){var o,a;if(y.cors||zt&&!i.crossDomain)return{send:function(e,t){var n,r=i.xhr();if(r.open(i.type,i.url,i.async,i.username,i.password),i.xhrFields)for(n in i.xhrFields)r[n]=i.xhrFields[n];for(n in i.mimeType&&r.overrideMimeType&&r.overrideMimeType(i.mimeType),i.crossDomain||e["X-Requested-With"]||(e["X-Requested-With"]="XMLHttpRequest"),e)r.setRequestHeader(n,e[n]);o=function(e){return function(){o&&(o=a=r.onload=r.onerror=r.onabort=r.ontimeout=r.onreadystatechange=null,"abort"===e?r.abort():"error"===e?"number"!=typeof r.status?t(0,"error"):t(r.status,r.statusText):t(_t[r.status]||r.status,r.statusText,"text"!==(r.responseType||"text")||"string"!=typeof r.responseText?{binary:r.response}:{text:r.responseText},r.getAllResponseHeaders()))}},r.onload=o(),a=r.onerror=r.ontimeout=o("error"),void 0!==r.onabort?r.onabort=a:r.onreadystatechange=function(){4===r.readyState&&C.setTimeout(function(){o&&a()})},o=o("abort");try{r.send(i.hasContent&&i.data||null)}catch(e){if(o)throw e}},abort:function(){o&&o()}}}),S.ajaxPrefilter(function(e){e.crossDomain&&(e.contents.script=!1)}),S.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return S.globalEval(e),e}}}),S.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")}),S.ajaxTransport("script",function(n){var r,i;if(n.crossDomain||n.scriptAttrs)return{send:function(e,t){r=S("<script>").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var Ut,Xt=[],Vt=/(=)\?(?=&|$)|\?\?/;S.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Xt.pop()||S.expando+"_"+Ct.guid++;return this[e]=!0,e}}),S.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Vt.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Vt.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Vt,"$1"+r):!1!==e.jsonp&&(e.url+=(Et.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||S.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?S(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Xt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((Ut=E.implementation.createHTMLDocument("").body).innerHTML="<form></form><form></form>",2===Ut.childNodes.length),S.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=N.exec(e))?[t.createElement(i[1])]:(i=xe([e],t,o),o&&o.length&&S(o).remove(),S.merge([],i.childNodes)));var r,i,o},S.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1<s&&(r=vt(e.slice(s)),e=e.slice(0,s)),m(t)?(n=t,t=void 0):t&&"object"==typeof t&&(i="POST"),0<a.length&&S.ajax({url:e,type:i||"GET",dataType:"html",data:t}).done(function(e){o=arguments,a.html(r?S("<div>").append(S.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},S.expr.pseudos.animated=function(t){return S.grep(S.timers,function(e){return t===e.elem}).length},S.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=S.css(e,"position"),c=S(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=S.css(e,"top"),u=S.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,S.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):("number"==typeof f.top&&(f.top+="px"),"number"==typeof f.left&&(f.left+="px"),c.css(f))}},S.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){S.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===S.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===S.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=S(e).offset()).top+=S.css(e,"borderTopWidth",!0),i.left+=S.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-S.css(r,"marginTop",!0),left:t.left-i.left-S.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===S.css(e,"position"))e=e.offsetParent;return e||re})}}),S.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;S.fn[t]=function(e){return $(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),S.each(["top","left"],function(e,n){S.cssHooks[n]=$e(y.pixelPosition,function(e,t){if(t)return t=Be(e,n),Me.test(t)?S(e).position()[n]+"px":t})}),S.each({Height:"height",Width:"width"},function(a,s){S.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){S.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return $(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?S.css(e,t,i):S.style(e,t,n,i)},s,n?e:void 0,n)}})}),S.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){S.fn[t]=function(e){return this.on(t,e)}}),S.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),S.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){S.fn[n]=function(e,t){return 0<arguments.length?this.on(n,null,e,t):this.trigger(n)}});var Gt=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;S.proxy=function(e,t){var n,r,i;if("string"==typeof t&&(n=e[t],t=e,e=n),m(e))return r=s.call(arguments,2),(i=function(){return e.apply(t||this,r.concat(s.call(arguments)))}).guid=e.guid=e.guid||S.guid++,i},S.holdReady=function(e){e?S.readyWait++:S.ready(!0)},S.isArray=Array.isArray,S.parseJSON=JSON.parse,S.nodeName=A,S.isFunction=m,S.isWindow=x,S.camelCase=X,S.type=w,S.now=Date.now,S.isNumeric=function(e){var t=S.type(e);return("number"===t||"string"===t)&&!isNaN(e-parseFloat(e))},S.trim=function(e){return null==e?"":(e+"").replace(Gt,"")}, true&&!(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = (function(){return S}).apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__),
		__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));var Yt=C.jQuery,Qt=C.$;return S.noConflict=function(e){return C.$===S&&(C.$=Qt),e&&C.jQuery===S&&(C.jQuery=Yt),S},"undefined"==typeof e&&(C.jQuery=C.$=S),S});


/***/ }),

/***/ 41:
/***/ ((__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";

// UNUSED EXPORTS: default

;// CONCATENATED MODULE: ./adblock-betafish/localFilesIndex.js
function getAvailableFiles() {
return {
jquery: {
"jquery-1.10.2.min.js": 93107,
"jquery-1.11.0.min.js": 96381,
"jquery-1.11.1.min.js": 95786,
"jquery-1.11.2.min.js": 95931,
"jquery-1.11.3.min.js": 95957,
"jquery-1.12.4.min.js": 97163,
"jquery-1.3.2.min.js": 57254,
"jquery-1.4.2.min.js": 72174,
"jquery-1.7.1.min.js": 93868,
"jquery-1.7.2.min.js": 94840,
"jquery-1.8.2.min.js": 93435,
"jquery-1.8.3.min.js": 93636,
"jquery-1.9.1.min.js": 92629,
"jquery-2.1.1.min.js": 84245,
"jquery-2.1.3.min.js": 84320,
"jquery-2.1.4.min.js": 84345,
"jquery-2.2.4.min.js": 85578,
"jquery-3.1.1.min.js": 86709,
"jquery-3.2.1.min.js": 86659,
},
};
}
 
/* harmony default export */ const localFilesIndex = (getAvailableFiles);
 

// EXTERNAL MODULE: ./adblock-betafish/prefs/settings.js
var settings = __webpack_require__(2630);
// EXTERNAL MODULE: ./adblock-betafish/utilities/background/bg-functions.js
var bg_functions = __webpack_require__(2028);
;// CONCATENATED MODULE: ./adblock-betafish/localcdn.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, adblockIsPaused */

// This module is conditional imported only into a Chrome build via the
// build config file in ..build\config\chrome.mjs





const LocalCDN = (function getLocalCDN() {
  const urlsMatchPattern = ['http://*/*', 'https://*/*'];
  const hostRegex = /ajax\.googleapis\.com|ajax\.aspnetcdn\.com|ajax\.microsoft\.com|cdnjs\.cloudflare\.com|code\.jquery\.com|cdn\.jsdelivr\.net|yastatic\.net|yandex\.st|libs\.baidu\.com|lib\.sinaapp\.com|upcdn\.b0\.upaiyun\.com/;
  const pathRegex = { jquery: /jquery[/-](\d*\.\d*\.\d*)/ };
  const libraryPaths = { jquery: { prefix: 'jquery-', postfix: '.min.js' } };
  const headersToRemove = ['Cookie', 'Origin', 'Referer'];
  const redirectCountKey = 'redirectCount';
  const dataCountKey = 'redirectDataCount';
  const missedVersionsKey = 'missedVersions';
  let localFiles = {};
  let libraries = [];
  let versionArray = {};

  // Gets a stored value from chrome.storage if available, and parses it. Otherwise,
  // if the value isn't currently stored or if the parse fails, returns a default
  // value.
  // Param: keyName: the key under which the value is stored
  //        defaultValue: the value to be returned if the stored value cannot be
  //                      retrieved
  const getStoredValue = function (keyName, defaultValue) {
    return new Promise((resolve) => {
      (0,bg_functions/* chromeStorageGetHelper */.nX)(keyName).then((response) => {
        let storedValue = null;
        try {
          storedValue = JSON.parse(response);
        } catch (err) {
          storedValue = defaultValue;
        } finally {
          if (!storedValue) {
            storedValue = defaultValue;
          }
        }
        resolve(storedValue);
      });
    });
  };

  // Populates the version array based on the files available locally
  // Pre: localFiles and libraries must be populated first
  const populateVersionArray = function () {
    const libraryVersions = {};
    // go through each libarary
    for (let i = 0; i < libraries.length; i++) {
      // check for path info
      if (libraryPaths[libraries[i]]) {
        // get the filenames
        const filenames = Object.getOwnPropertyNames(localFiles[libraries[i]]);
        libraryVersions[libraries[i]] = [];
        for (let j = 0; j < filenames.length; j++) {
          // extract the version from the filesname
          let version = filenames[j].replace(libraryPaths[libraries[i]].prefix, '');
          version = version.replace(libraryPaths[libraries[i]].postfix, '');
          libraryVersions[libraries[i]].push(version);
        }
      }
    }

    return libraryVersions;
  };

  // Completes necessary set up for the LocalCDN
  // Post:  localFiles, libraries, and versionArray are populated based on
  //        available local files
  const setUp = function () {
    localFiles = localFilesIndex();
    libraries = Object.getOwnPropertyNames(localFiles);
    versionArray = populateVersionArray();
  };

  // Increments the redirect count by one.
  // The redirect count is loaded from and saved to storage.
  const incrementRedirectCount = function () {
    getStoredValue(redirectCountKey, 0).then((count) => {
      // increment
      let storedRedirectCount = count;
      storedRedirectCount += 1;

      // store updated count
      (0,bg_functions/* chromeStorageSetHelper */.rJ)(redirectCountKey, JSON.stringify(storedRedirectCount));
    });
  };

  // Adds the size of the specified file to the data count for that library.
  // The data count is loaded from and saved to storage.
  // Param: targetLibrary: the library that the file belongs to
  //        fileName: the file to be added to the data count
  const addToDataCount = function (targetLibrary, fileName) {
    getStoredValue(dataCountKey, 0).then((count) => {
      // add file size to data count
      let storedDataCount = count;
      storedDataCount += localFiles[targetLibrary][fileName];

      // store updated count
      (0,bg_functions/* chromeStorageSetHelper */.rJ)(dataCountKey, JSON.stringify(storedDataCount));
    });
  };

  // Adds the specified version of the specified library to the missed versions
  // object, if it hasn't already been added. Otherwise increments the count for
  // that version.
  // The missed versions object is loaded from and saved to storage.
  // Param: targetLibrary: the library that the missing version belongs to
  //        version: the missing version to be added
  const addMissedVersion = function (targetLibrary, version) {
    getStoredValue(missedVersionsKey, {}).then((storedMissedVersions) => {
      // add new missed version
      const missedVersions = storedMissedVersions;
      if (!missedVersions[targetLibrary]) {
        missedVersions[targetLibrary] = {};
      }
      if (missedVersions[targetLibrary][version] > 0) {
        missedVersions[targetLibrary][version] += 1;
      } else {
        missedVersions[targetLibrary][version] = 1;
      }

      // store updated missed versions
      (0,bg_functions/* chromeStorageSetHelper */.rJ)(missedVersionsKey, JSON.stringify(missedVersions));
    });
  };

  // Handles a webRequest.onBeforeRequest event.
  // Redirects any requests for locally available files from a matching host,
  // if AdBlock is not paused. Otherwise allows request to continue as normal.
  // Records any redirects, bytes of data redirected, and missing versions of
  // supported libararies.
  // Param: details: holds information about the request, including the URL.
  const libRequestHandler = function (details) {
    // respect pause
    if (!adblockIsPaused()) {
      let targetLibrary = null;
      const requestUrl = (0,bg_functions/* parseUri */.he)(details.url);

      // check if the url contains a library keyword
      for (let i = 0; i < libraries.length; i++) {
        if (requestUrl.pathname.indexOf(libraries[i]) !== -1) {
          targetLibrary = libraries[i];
        }
      }

      // check the request host
      if (targetLibrary !== null && hostRegex.test(requestUrl.host)) {
        // check the path
        const matches = pathRegex[targetLibrary].exec(requestUrl.pathname);
        if (matches) {
          const version = matches[1];

          // check if we have the version locally
          if (versionArray[targetLibrary].indexOf(version) !== -1) {
            const libraryPrefix = libraryPaths[targetLibrary].prefix;
            const libraryPostfix = libraryPaths[targetLibrary].postfix;
            const fileName = libraryPrefix + version + libraryPostfix;
            const localPath = `localLib/${targetLibrary}/${fileName}`;
            incrementRedirectCount();
            addToDataCount(targetLibrary, fileName);
            return { redirectUrl: browser.runtime.getURL(localPath) };
          }
          addMissedVersion(targetLibrary, version);
        }
      }
    }

    return { cancel: false };
  };

  // Handles a webrequest.onBeforeSendHeaders event.
  // Strips the cookie, origin, and referer headers (if present) from any requests for
  // a supported libarary from a matching host, if AdBlock is not paused. Otherwise
  // allows request to continue as normal.
  // Param: details: holds information about the request, including the URL and request
  //                 headers
  const stripMetadataHandler = function (details) {
    // respect pause
    if (!adblockIsPaused()) {
      const requestUrl = (0,bg_functions/* parseUri */.he)(details.url);
      let match = false;

      // check if the url contains a library keyword
      for (let k = 0; k < libraries.length; k++) {
        if (requestUrl.pathname.indexOf(libraries[k]) !== -1) {
          match = true;
        }
      }

      // check for a matching host
      if (match && hostRegex.test(requestUrl.host)) {
        // strip the headers to remove, if present
        for (let i = 0; i < details.requestHeaders.length; i++) {
          const aHeader = details.requestHeaders[i].name;
          if (headersToRemove.includes(aHeader)) {
            details.requestHeaders.splice(i -= 1, 1);
          }
        }
      }
    }

    return { requestHeaders: details.requestHeaders };
  };

  // Sets redirect count, data count, and missed versions back to default
  // (0 for redirect count and data count, and an empty object for missed
  // versions)
  const resetCollectedData = function () {
    (0,bg_functions/* chromeStorageSetHelper */.rJ)(redirectCountKey, '0');
    (0,bg_functions/* chromeStorageSetHelper */.rJ)(dataCountKey, '0');
    (0,bg_functions/* chromeStorageSetHelper */.rJ)(missedVersionsKey, '{}');
  };

  return {
    migrateStoredData() {
      return Promise.all([(0,bg_functions/* migrateData */.ww)(redirectCountKey),
        (0,bg_functions/* migrateData */.ww)(dataCountKey),
        (0,bg_functions/* migrateData */.ww)(missedVersionsKey)]);
    },
    setUp,
    // Starts the LocalCDN listeners
    start() {
      setUp();
      browser.webRequest.onBeforeRequest.addListener(libRequestHandler, { urls: urlsMatchPattern }, ['blocking']);
      browser.webRequest.onBeforeSendHeaders.addListener(stripMetadataHandler, { urls: urlsMatchPattern }, ['blocking', 'requestHeaders']);
    },
    // Stops the LocalCDN listeners and reset data
    end() {
      browser.webRequest.onBeforeRequest.removeListener(libRequestHandler);
      browser.webRequest.onBeforeSendHeaders.removeListener(stripMetadataHandler);
      resetCollectedData();
    },
    // Gets the redirect count as a number of redirects
    getRedirectCount() {
      return getStoredValue(redirectCountKey, 0);
    },
    // Gets the data count as a number of bytes
    getDataCount() {
      return getStoredValue(dataCountKey, 0);
    },
    // Gets the missed versions object, which includes a count of how many
    // times the missed version has been requested
    getMissedVersions() {
      return getStoredValue(missedVersionsKey, undefined);
    },
  };
}());

/* harmony default export */ const localcdn = ((/* unused pure expression or super */ null && (LocalCDN)));

// eslint-disable-next-line no-restricted-globals
Object.assign(self, {
  LocalCDN,
});

settings/* settings.onload */.Xd.onload().then(() => {
  if ((0,settings/* getSettings */.Gw)().local_cdn) {
    LocalCDN.migrateStoredData().then(() => {
      LocalCDN.start();
    });
  }
});


/***/ }),

/***/ 1120:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3817);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _prefs_settings__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2630);
/* harmony import */ var _utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2028);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, ext, adblockIsPaused, adblockIsDomainPaused, settings,
   getUserFilters, Utils, replacedCounts, setSetting,  */





const LocalDataCollection = (function getLocalDataCollection() {
  const easyPrivacyURL = 'https://easylist-downloads.adblockplus.org/easyprivacy.txt';
  const FIFTEEN_MINS = 15;
  const EXT_STATS_KEY = 'ext_stats_key';
  const STATS_ALARM_NAME = 'statsalarm';
  const STATS_STORAGE_KEY = 'ab:stats.storage.key';
  const REPORTING_OPTIONS = {
    filterType: 'blocking',
    includeElementHiding: false,
  };

  // Setup memory cache
  let dataCollectionCache = {};
  dataCollectionCache.domains = {};

  const initializeDomainIfNeeded = function (domain) {
    if (!(domain in dataCollectionCache.domains)) {
      dataCollectionCache.domains[domain] = {};
      dataCollectionCache.domains[domain].ads = 0;
      dataCollectionCache.domains[domain].trackers = 0;
      dataCollectionCache.domains[domain].adsReplaced = 0;
    }
  };

  const addFilterToCache = function (details, filter) {
    const validFilterText = filter && filter.text && (typeof filter.text === 'string');
    if (details.tabId > 0 && validFilterText && validFilterText && details && details.url) {
      browser.tabs.get(details.tabId).then(async (tab) => {
        if (tab.incognito) {
          return;
        }
        const theURL = new URL(details.url);
        const domain = theURL.hostname;
        initializeDomainIfNeeded(domain);
        const { text } = filter;
        let isAd = true;
        const subscriptions = await _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__.subscriptions.getForFilter(text);
        subscriptions.forEach((sub) => {
          if (!sub.disabled && sub.url && sub.url === easyPrivacyURL) {
            isAd = false;
          }
        });
        if (isAd) {
          dataCollectionCache.domains[domain].ads += 1;
        } else {
          dataCollectionCache.domains[domain].trackers += 1;
        }
        (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_2__/* .chromeStorageSetHelper */ .rJ)(STATS_STORAGE_KEY, dataCollectionCache);
      });
    }
  };

  const filterListener = function ({ request, filter }) {
    if ((0,_prefs_settings__WEBPACK_IMPORTED_MODULE_1__/* .getSettings */ .Gw)().local_data_collection && !adblockIsPaused()) {
      addFilterToCache(request, filter);
    } else if (!(0,_prefs_settings__WEBPACK_IMPORTED_MODULE_1__/* .getSettings */ .Gw)().local_data_collection) {
      LocalDataCollection.end();
    }
  };

  const adReplacedListener = function (tabId, url) {
    if ((0,_prefs_settings__WEBPACK_IMPORTED_MODULE_1__/* .getSettings */ .Gw)().local_data_collection && !adblockIsPaused()) {
      const domain = new URL(url).hostname;
      initializeDomainIfNeeded(domain);
      dataCollectionCache.domains[domain].adsReplaced += 1;
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_2__/* .chromeStorageSetHelper */ .rJ)(STATS_STORAGE_KEY, dataCollectionCache);
    } else if (!(0,_prefs_settings__WEBPACK_IMPORTED_MODULE_1__/* .getSettings */ .Gw)().local_data_collection) {
      LocalDataCollection.end();
    }
  };


  const clearCache = function () {
    dataCollectionCache = {};
    dataCollectionCache.domains = {};
    browser.storage.local.remove(STATS_STORAGE_KEY);
  };

  const saveCacheData = function () {
    return new Promise(async (resolve) => {
      if ((0,_prefs_settings__WEBPACK_IMPORTED_MODULE_1__/* .getSettings */ .Gw)().local_data_collection && !(0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_2__/* .isEmptyObject */ .Qr)(dataCollectionCache.domains)) {
        const hourSnapShot = JSON.parse(JSON.stringify({
          v: '1',
          doms: dataCollectionCache.domains,
        }));
        browser.storage.local.get(EXT_STATS_KEY).then((hourlyResponse) => {
          const savedData = hourlyResponse[EXT_STATS_KEY] || { };
          savedData[Date.now().toString()] = hourSnapShot;
          (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_2__/* .chromeStorageSetHelper */ .rJ)(EXT_STATS_KEY, savedData, resolve);
          clearCache();
        });
      } else {
        if (!(0,_prefs_settings__WEBPACK_IMPORTED_MODULE_1__/* .getSettings */ .Gw)().local_data_collection) {
          browser.alarms.clear(STATS_ALARM_NAME);
        }
        resolve();
      }
    });
  };

  const loadCache = async function () {
    const response = await browser.storage.local.get(STATS_STORAGE_KEY);
    if (response[STATS_STORAGE_KEY]) {
      dataCollectionCache = response[STATS_STORAGE_KEY];
    }
  };

  const initialize = function () {
    browser.alarms.onAlarm.addListener(async (alarm) => {
      // Not our alarm, nothing to do
      if (!alarm && alarm.name !== STATS_ALARM_NAME) {
        return;
      }
      await settings.onload();
      // If we're collecting data and the alarm has fired, process the memory cache
      if ((0,_prefs_settings__WEBPACK_IMPORTED_MODULE_1__/* .getSettings */ .Gw)().local_data_collection) {
        await loadCache();
        saveCacheData();
      } else {
        browser.alarms.clear(STATS_ALARM_NAME);
      }
    });
    // If enabled at startup, enable periodic processing of memory cache
    settings.onload().then(async () => {
      if (!(0,_prefs_settings__WEBPACK_IMPORTED_MODULE_1__/* .getSettings */ .Gw)().local_data_collection) {
        return;
      }
      await loadCache();
      browser.alarms.create(STATS_ALARM_NAME, { periodInMinutes: FIFTEEN_MINS });
      _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__.reporting.onBlockableItem.addListener(filterListener, REPORTING_OPTIONS);
      replacedCounts.adReplacedNotifier.on('adReplaced', adReplacedListener);
    });
  };
  initialize();

  const returnObj = {};
  returnObj.EXT_STATS_KEY = EXT_STATS_KEY;

  returnObj.start = function returnObjStart() {
    return new Promise((resolve) => {
      dataCollectionCache.domains = {};
      setSetting('local_data_collection', true, () => {
        initialize();
        resolve();
      });
    });
  };

  returnObj.end = function returnObjEnd() {
    return new Promise((resolve) => {
      browser.alarms.clear(STATS_ALARM_NAME);
      clearCache();
      _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__.reporting.onBlockableItem.removeListener(filterListener, REPORTING_OPTIONS);
      replacedCounts.adReplacedNotifier.off('adReplaced', adReplacedListener);
      setSetting('local_data_collection', false, resolve);
    });
  };
  returnObj.clearCache = clearCache;
  returnObj.getCache = function returnObjGetCache() {
    return dataCollectionCache;
  };
  returnObj.saveCacheData = saveCacheData;
  returnObj.easyPrivacyURL = easyPrivacyURL;
  returnObj.exportRawStats = async function returnObjFilterStats() {
    const hourlyResponse = await browser.storage.local.get(EXT_STATS_KEY);
    return Promise.resolve(hourlyResponse[EXT_STATS_KEY] || { });
  };
  returnObj.getRawStatsSize = async function returnObjFilterStatsSize() {
    const rawStats = await LocalDataCollection.exportRawStats();
    return Promise.resolve((JSON.stringify(rawStats).length));
  };
  // Note: the following function is used for testing purposes
  // Import filter list statistics which will be converted to the format needed / used
  // by the 'stats' tab.
  // Inputs: filterStatsArray: array of stringified JSON filter list statistics data
  //         from the DataCollection V2 messages.
  // Returns: a Promise, resolved when complete
  returnObj.importFilterStats = function returnObjFilterStats(filterStatsArray) {
    return new Promise((resolve) => {
      let parsedfilterStats = {};
      try {
        parsedfilterStats = JSON.parse(filterStatsArray);
      } catch (e) {
        // eslint-disable-next-line no-console
        console.log(e);
        resolve(`error : ${e.toString()}`);
        return;
      }
      browser.storage.local.get(EXT_STATS_KEY).then((hourlyResponse) => {
        const savedData = hourlyResponse[EXT_STATS_KEY] || { };
        for (let inx = 0; inx < parsedfilterStats.length; inx++) {
          const dupDataCache = parsedfilterStats[inx];
          // only process new data
          // don't overwrite existing data
          if (!savedData[Date.parse(dupDataCache.timeOfLastPush)]) {
            const hourSnapShot = {};
            const initializeDomainDataObject = function (domain) {
              hourSnapShot[domain] = {};
              hourSnapShot[domain].ads = 0;
              hourSnapShot[domain].trackers = 0;
              hourSnapShot[domain].adsReplaced = 0;
              if (dupDataCache.domains[domain] && typeof dupDataCache.domains[domain].adsReplaced === 'number') {
                hourSnapShot[domain].adsReplaced = dupDataCache.domains[domain].adsReplaced;
              }
            };
            for (const domain in dupDataCache.domains) {
              initializeDomainDataObject(domain);
            }
            const processDomainByFilterType = function (filter, domains, filterRequestType) {
              for (const domain in domains) {
                if (!hourSnapShot[domain]) {
                  initializeDomainDataObject(domain);
                }
                if (dupDataCache.filters[filter].subscriptions
                    && dupDataCache.filters[filter].subscriptions.length
                    && dupDataCache.filters[filter].subscriptions.includes(easyPrivacyURL)) {
                  hourSnapShot[domain].trackers
                    += dupDataCache.filters[filter][filterRequestType][domain].hits;
                } else {
                  hourSnapShot[domain].ads
                    += dupDataCache.filters[filter][filterRequestType][domain].hits;
                }
              }
            };
            for (const filter in dupDataCache.filters) {
              processDomainByFilterType(filter, dupDataCache.filters[filter].firstParty, 'firstParty');
              processDomainByFilterType(filter, dupDataCache.filters[filter].thirdParty, 'thirdParty');
            }
            savedData[Date.parse(dupDataCache.timeOfLastPush)] = JSON.parse(JSON.stringify({
              v: '1',
              doms: hourSnapShot,
            }));
          }
        }// end for loop
        (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_2__/* .chromeStorageSetHelper */ .rJ)(EXT_STATS_KEY, savedData);
        resolve(' success! ');
      });
    });
  };
  return returnObj;
}());

/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (LocalDataCollection);


/***/ }),

/***/ 7641:
/***/ ((__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";

// EXTERNAL MODULE: ./vendor/webext-sdk/dist/ewe-api.js
var ewe_api = __webpack_require__(3817);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/messaging/types.js
var types = __webpack_require__(3242);
// EXTERNAL MODULE: ./adblock-betafish/prefs/settings.js
var settings = __webpack_require__(2630);
// EXTERNAL MODULE: ./adblock-betafish/subscriptionadapter.js + 1 modules
var subscriptionadapter = __webpack_require__(934);
// EXTERNAL MODULE: ./adblock-betafish/datacollection.v2.js
var datacollection_v2 = __webpack_require__(5175);
// EXTERNAL MODULE: ./adblock-betafish/servermessages.js
var servermessages = __webpack_require__(1546);
// EXTERNAL MODULE: ./adblock-betafish/localdatacollection.js
var localdatacollection = __webpack_require__(1120);
;// CONCATENATED MODULE: ./adblock-betafish/excludefilter.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, parseFilter, chromeStorageSetHelper */

// Module for removing individual filters from filter lists
// An 'advance' feature, used on the Customize tab, titled "disabled filters"



const ExcludeFilter = (function excludeFilter() {
  const excludeFiltersKey = 'exclude_filters';
  // Removes the valid filters from any / all filter lists and
  // saves the valid entries
  // Note:  any invalid filters are ignored
  // Inputs: filters:string the new filters.
  const setExcludeFilters = async function (filtersToExclude) {
    const response = await browser.storage.local.get(excludeFiltersKey);
    const currentExcludeFilters = response[excludeFiltersKey];
    let promises = [];
    if (currentExcludeFilters) {
      const currentExcludeArr = currentExcludeFilters.split('\n');
      for (let i = 0; i < currentExcludeArr.length; i++) {
        const filter = currentExcludeArr[i];
        if (filter.length > 0) {
          const result = ewe_api.filters.validate(filter);
          if (!result) {
            promises.push(ewe_api.filters.enable([filter]));
          }
        }
      }
    }
    await Promise.all(promises);
    promises = [];
    const excludeFilters = filtersToExclude.trim();
    const excludeFiltersArray = excludeFilters.split('\n');
    const validExcludeFiltersArray = [];
    for (let i = 0; i < excludeFiltersArray.length; i++) {
      let filter = excludeFiltersArray[i];
      filter = filter.trim();
      if (filter.length > 0) {
        const result = ewe_api.filters.validate(filter);
        if (!result) {
          validExcludeFiltersArray.push(filter);
          promises.push(ewe_api.filters.disable([filter]));
        }
      }
    }
    await Promise.all(promises);
    if (validExcludeFiltersArray.length) {
      chromeStorageSetHelper(excludeFiltersKey, validExcludeFiltersArray.join('\n'));
    } else {
      browser.storage.local.remove(excludeFiltersKey);
    }
  };

  function excludeFilterChangeListener() {
    browser.storage.local.get(excludeFiltersKey).then((response) => {
      if (response[excludeFiltersKey]) {
        setExcludeFilters(response[excludeFiltersKey]);
      }
    });
  }

  // At startup, add a listener to so that the exclude filters
  // can be removed if the filter lists are updated
  ewe_api.subscriptions.onAdded.addListener(excludeFilterChangeListener);
  ewe_api.subscriptions.onChanged.addListener(excludeFilterChangeListener);
  ewe_api.subscriptions.onRemoved.addListener(excludeFilterChangeListener);

  return {
    setExcludeFilters,
  };
}());
/* harmony default export */ const excludefilter = (ExcludeFilter);

// EXTERNAL MODULE: ./adblock-betafish/messaging/messagevalidator.js
var messagevalidator = __webpack_require__(9031);
// EXTERNAL MODULE: ./adblock-betafish/alias/icon.js
var icon = __webpack_require__(1021);
// EXTERNAL MODULE: ./adblock-betafish/utilities/background/bg-functions.js
var bg_functions = __webpack_require__(2028);
;// CONCATENATED MODULE: ./adblock-betafish/messaging/message-responder.js
/* For ESLint: List any global identifiers used in this file below */
/* global browser, isTrustedSender,  isTrustedTarget, tryToUnwhitelist, getUserFilters,
   createDomainAllowlistFilter, addCustomFilter, countCache, checkUpdateProgress,
   adblockIsPaused, pageIsWhitelisted, adblockIsDomainPaused, getCurrentTabInfo,
   openTab, updateFilterLists, isTrustedSenderDomain, updateButtonUIAndContextMenus,
   getDebugInfo, addYTChannelListeners, removeYTChannelListeners, openYTManagedSubPage,
   addTwitchAllowlistListeners, removeTwitchAllowlistListeners, abpPrefPropertyNames,
   pausedFilterText1, pausedFilterText2, updateCustomFilterCountMap, LocalCDN
*/















const processMessageResponse = (sendResponse, responseData) => {
  sendResponse({});
  return Promise.resolve(responseData);
};

// eslint-disable-next-line no-restricted-globals
Object.assign(self, {
  processMessageResponse,
});

const uiPorts = new Map();
const messageTypes = new Map([
  ['settings', 'settings.respond'],
]);


function sendMessage(type, action, ...args) {
  if (uiPorts.size === 0) {
    return;
  }

  for (const [uiPort, filters] of uiPorts) {
    const actions = filters.get(type);
    if (actions && actions.indexOf(action) !== -1) {
      uiPort.postMessage({
        type: messageTypes.get(type),
        action,
        args,
      });
    }
  }
}

function getListener(type, action) {
  return (...args) => {
    sendMessage(type, action, ...args);
  };
}

function listen(type, filters, newFilter) {
  switch (type) {
    case 'settings':
      filters.set('settings', newFilter);
      break;
    default:
        // do nothing
  }
}

function onConnect(uiPort) {
  if (!isTrustedSender(uiPort.sender)) {
    return;
  }

  if (uiPort.name !== 'settings') {
    return;
  }

  const filters = new Map();
  uiPorts.set(uiPort, filters);

  uiPort.onDisconnect.addListener(() => {
    uiPorts.delete(uiPort);
  });

  uiPort.onMessage.addListener((message) => {
    const [type, action] = message.type.split('.', 2);
    if (action === 'listen') {
      listen(type, filters, message.filter, message,
        uiPort.sender && uiPort.sender.tab && uiPort.sender.tab.id);
    }
  });
}
browser.runtime.onConnect.addListener(onConnect);

/**
 * Process messages and events related to the 'Settings' object
 *
 */
settings/* settings.onload */.Xd.onload().then(() => {
  /* eslint-disable consistent-return */
  browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
    if (!isTrustedSender(sender)) {
      return;
    }
    const { command } = message;
    switch (command) {
      case 'setSetting':
        (0,settings/* setSetting */.Lt)(message.name, message.isEnabled);
        sendResponse({});
        break;
      case 'isValidTheme':
        return processMessageResponse(sendResponse, (0,settings/* isValidTheme */.uR)(message.name));
      case 'getABPPrefPropertyNames':
        return processMessageResponse(sendResponse, abpPrefPropertyNames);
      default:
    }
  });
  settings/* settingsNotifier.on */.Pg.on('settings.changed', getListener('settings', 'changed'));
});

/**
 * Process messages from Popup menu and other UI components
 *
 */
/* eslint-disable consistent-return */
browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
  if (!isTrustedSender(sender)) {
    return;
  }
  const { command } = message;
  switch (command) {
    case 'pageIsWhitelisted':
      sendResponse(pageIsWhitelisted(JSON.parse(message.page)));
      break;
    case 'adblockIsPaused': {
      const isPaused = adblockIsPaused(message.newValue);
      sendResponse(isPaused);
      return Promise.resolve(isPaused);
    }
    case 'adblockIsDomainPaused': {
      const isDomainPaused = adblockIsDomainPaused(message.activeTab, message.newValue);
      sendResponse(isDomainPaused);
      return Promise.resolve(isDomainPaused);
    }
    case 'getPausedFilterText':
      return processMessageResponse(sendResponse, { pausedFilterText1, pausedFilterText2 });
    case 'getCurrentTabInfo':
      sendResponse({});
      return getCurrentTabInfo(false, message.tabId).then(results => results);
    case 'updateCustomFilterCountMap':
      updateCustomFilterCountMap(message.countMap);
      sendResponse({});
      return;
    case 'updateFilterLists':
      updateFilterLists();
      sendResponse({});
      return;
    case 'checkUpdateProgress':
      sendResponse(checkUpdateProgress());
      return;
    case 'getCustomFilterCount':
      sendResponse({ response: countCache.getCustomFilterCount(message.host) });
      return;
    case 'subscriptions.has':
      return processMessageResponse(sendResponse, ewe_api.subscriptions.has(message.url));
    case 'createDomainAllowlistFilter':
      sendResponse({});
      return createDomainAllowlistFilter(message.url, message.origin).then(results => results);
    case 'getUserFilters':
      sendResponse({ response: getUserFilters() });
      return;
    case 'tryToUnwhitelist':
      sendResponse({});
      return tryToUnwhitelist(message.url, message.id).then(results => results);
    case 'getDebugInfo':
      sendResponse({});
      return getDebugInfo();
    case 'showIconBadgeCTA':
      sendResponse({});
      (0,icon/* showIconBadgeCTA */.QO)(message.value);
      return;
    case 'getNewBadgeTextReason':
      sendResponse({ reason: (0,icon/* getNewBadgeTextReason */.vo)() });
      return;
    case 'updateButtonUIAndContextMenus':
      updateButtonUIAndContextMenus();
      sendResponse({});
      break;
    default:
  }
});

async function addCustomFilterMessageValidation(message) {
  if (await messagevalidator/* default.validateMessage */.Z.validateMessage(message)) {
    return addCustomFilter(message.filterTextToAdd, message.origin).then(results => results);
  }
}

/**
 * Process the 'addCustomFilter' message the wizards, which requires verifing the
 * `addCustomFilterRandomName` property on the message matches what is current set on the global
 * name space
 *
 */
/* eslint-disable consistent-return */
browser.runtime.onMessage.addListener((message) => {
  if (
    message.command === 'addCustomFilter'
    && message.filterTextToAdd
  ) {
    return addCustomFilterMessageValidation(message);
  }
});

/**
 * Process messages that are sent from a content script
 *
 */
//
/* eslint-disable consistent-return */
browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
  if (isTrustedSenderDomain(sender) || isTrustedSender(sender)) {
    const { command } = message;
    switch (command) {
      case 'subscribe':
        subscriptionadapter/* default.subscribe */.Z.subscribe({ id: message.id });
        sendResponse({});
        break;
      case 'unsubscribe':
        subscriptionadapter/* default.unsubscribe */.Z.unsubscribe({ adblockId: message.adblockId });
        sendResponse({});
        break;
      case 'getIdFromURL':
        sendResponse({});
        return processMessageResponse(sendResponse,
          subscriptionadapter/* default.getIdFromURL */.Z.getIdFromURL(message.url));
      case 'isLanguageSpecific':
        sendResponse({});
        return processMessageResponse(sendResponse,
          subscriptionadapter/* default.isLanguageSpecific */.Z.isLanguageSpecific(message.id));
      case 'getSubscriptionsMinusText':
        sendResponse({});
        return processMessageResponse(sendResponse,
          subscriptionadapter/* default.getSubscriptionsMinusText */.Z.getSubscriptionsMinusText());
      case 'getAllSubscriptionsMinusText':
        sendResponse({});
        return processMessageResponse(sendResponse,
          subscriptionadapter/* default.getAllSubscriptionsMinusText */.Z.getAllSubscriptionsMinusText());
      case 'recordGeneralMessage':
        servermessages/* default.recordGeneralMessage */.Z.recordGeneralMessage(message.msg, undefined, message.additionalParams);
        sendResponse({});
        break;
      default:
    }
  }
});

/**
 * Process messages that are sent from a content script & trusted senders
 *
 */
//
browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
  const { command } = message;
  switch (command) {
    case 'getSettings':
      sendResponse((0,settings/* getSettings */.Gw)());
      break;
    case 'openTab':
      openTab(message.urlToOpen);
      sendResponse({});
      break;
    default:
  }
});

/**
 * Process messages for the LocalCDN
 *
 */
/* eslint-disable consistent-return */
browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
  if (!isTrustedSender(sender)) {
    return;
  }
  const { command } = message;
  switch (command) {
    case 'LocalCDN.start':
      LocalCDN.start();
      sendResponse({});
      break;
    case 'LocalCDN.end':
      LocalCDN.end();
      sendResponse({});
      break;
    case 'LocalCDN.isAvailable':
      return processMessageResponse(sendResponse, (typeof LocalCDN === 'object'));
    default:
  }
});

/**
 * Process messages for the DataCollectionV2
 *
 */
/* eslint-disable consistent-return */
browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
  if (!isTrustedSender(sender)) {
    return;
  }
  const { command } = message;
  switch (command) {
    case 'DataCollectionV2.start':
      return processMessageResponse(sendResponse, datacollection_v2/* default.start */.Z.start());
    case 'DataCollectionV2.end':
      return processMessageResponse(sendResponse, datacollection_v2/* default.end */.Z.end());
    default:
  }
});

/**
 * Process messages for the  Exclude Filters, Local Data Collection,
 * Server Messages, YT Channel & Twitch Channel Listeners
 *
 */
/* eslint-disable consistent-return */
browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
  if (!isTrustedSender(sender)) {
    return;
  }
  const { command } = message;
  switch (command) {
    case 'addYTChannelListeners':
      addYTChannelListeners();
      sendResponse({});
      break;
    case 'removeYTChannelListeners':
      removeYTChannelListeners();
      sendResponse({});
      break;
    case 'openYTManagedSubPage':
      openYTManagedSubPage();
      sendResponse({});
      break;
    case 'addTwitchAllowlistListeners':
      addTwitchAllowlistListeners();
      sendResponse({});
      break;
    case 'removeTwitchAllowlistListeners':
      removeTwitchAllowlistListeners();
      sendResponse({});
      break;
    case 'recordAnonymousErrorMessage':
      servermessages/* default.recordAnonymousErrorMessage */.Z.recordAnonymousErrorMessage(message.msg, undefined, message.additionalParams);
      sendResponse({});
      break;
    case 'LocalDataCollection.clearCache':
      localdatacollection/* default.clearCache */.Z.clearCache();
      sendResponse({});
      break;
    case 'LocalDataCollection.end':
      return processMessageResponse(sendResponse, localdatacollection/* default.end */.Z.end());
    case 'LocalDataCollection.start':
      return processMessageResponse(sendResponse, localdatacollection/* default.start */.Z.start());
    case 'LocalDataCollection.saveCacheData':
      sendResponse({});
      return localdatacollection/* default.saveCacheData */.Z.saveCacheData();
    case 'LocalDataCollection.easyPrivacyURL':
      return processMessageResponse(sendResponse, localdatacollection/* default.easyPrivacyURL */.Z.easyPrivacyURL);
    case 'LocalDataCollection.EXT_STATS_KEY':
      return processMessageResponse(sendResponse, localdatacollection/* default.EXT_STATS_KEY */.Z.EXT_STATS_KEY);
    case 'ExcludeFilter.setExcludeFilters':
      excludefilter.setExcludeFilters(message.filters);
      sendResponse({});
      break;
    default:
  }
});

function parseFilter(text) {
  const filterText = text.trim() || null;
  let error = null;

  if (filterText) {
    if (filterText[0] === '[') {
      error = { type: 'unexpected_filter_list_header' };
    } else {
      const filterError = ewe_api.filters.validate(filterText);
      if (filterError) {
        error = (0,types/* toPlainFilterError */.U_)(filterError);
      }
    }
  }

  return [filterText, error];
}

function filtersValidate(text) {
  const filters = [];
  const errors = [];

  const lines = text.split('\n');
  for (let i = 0; i < lines.length; i++) {
    const [filter, error] = parseFilter(lines[i]);

    if (error) {
      error.filter = filter;
      // We don't treat filter headers like invalid filters,
      // instead we simply ignore them and don't show any errors
      // in order to allow pasting complete filter lists.
      // If there are no filters, we do treat it as an invalid filter
      // to inform users about it and to give them a chance to edit it.
      if (error.type === 'unexpected_filter_list_header'
          && lines.length > 1) {
        /* eslint-disable no-continue */
        continue;
      }
      errors.push(error);
    } else if (filter) {
      filters.push(filter);
    }
  }

  return [filters, errors];
}

async function filtersAdd(text, origin) {
  const filters = [];
  const lines = text.split('\n');
  for (let i = 0; i < lines.length; i++) {
    const [filter, error] = parseFilter(lines[i]);

    if (error) {
      return error;
    }

    if (filter) {
      filters.push(filter);
    }
  }
  try {
    await ewe_api.filters.add(filters, (0,bg_functions/* createFilterMetaData */.Yv)(origin));
  } catch (error) {
    return error;
  }
}


/* eslint-disable consistent-return */
browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
  if (!isTrustedSender(sender)) {
    return;
  }
  const { command } = message;
  switch (command) {
    case 'filters.validate': {
      const [, validationErrors] = filtersValidate(message.text);
      return processMessageResponse(sendResponse, validationErrors);
    }
    case 'filters.add': {
      sendResponse({});
      return filtersAdd(message.text, message.origin);
    }
    case 'filters.remove':
      ewe_api.filters.remove(message.filters);
      sendResponse({});
      break;
    default:
  }
});


/***/ }),

/***/ 9031:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var _vendor_adblockplusui_adblockpluschrome_lib_storage_session__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(735);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser */



const sessionStorageKey = 'ab:CustomFilterRandomName';
const sessionKey = 'ab:randomtext';

const sessionStorage = new _vendor_adblockplusui_adblockpluschrome_lib_storage_session__WEBPACK_IMPORTED_MODULE_0__/* .SessionStorage */ .x(sessionStorageKey);

/* eslint-disable-next-line no-unused-vars */
class MessageValidator {
  generateNewRandomText = () => {
    this.randomtext = `ab-${Math.random().toString(36).substring(2)}`;
    sessionStorage.set(sessionKey, this.randomtext);
    return this.randomtext;
  };

  validateMessage = async (message) => {
    const data = await sessionStorage.get(sessionKey);
    this.randomtext = data;
    return Promise.resolve(message && (message.addCustomFilterRandomName === this.randomtext));
  };
}
const messageValidator = new MessageValidator();
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (messageValidator);


/***/ }),

/***/ 6130:
/***/ ((__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony import */ var _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1177);
/* harmony import */ var _picreplacement_channels__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1053);
/* harmony import */ var _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8409);
/* harmony import */ var _prefs_settings__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2630);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(3817);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_4__);
/* For ESLint: List any global identifiers used in this file below */
/* global browser, isTrustedSender, openTab, isTrustedSenderDomain,
   processMessageResponse */







/**
 * Process events related to the Premium object - License, Channels, and Sync-Service
 *
 */
const uiPorts = new Map();
const messageTypes = new Map([
  ['license', 'license.respond'],
  ['channels', 'channels.respond'],
  ['sync', 'sync.respond'],
]);


function sendMessage(type, action, ...args) {
  if (uiPorts.size === 0) {
    return;
  }
  for (const [uiPort, filters] of uiPorts) {
    const actions = filters.get(type);
    if (actions && actions.indexOf(action) !== -1) {
      uiPort.postMessage({
        type: messageTypes.get(type),
        action,
        args,
      });
    }
  }
}

function getListener(type, action) {
  return (...args) => {
    sendMessage(type, action, ...args);
  };
}

function listen(type, filters, newFilter) {
  switch (type) {
    case 'license':
      filters.set('license', newFilter);
      break;
    case 'channels':
      filters.set('channels', newFilter);
      break;
    case 'sync':
      filters.set('sync', newFilter);
      break;
    default:
        // do nothing
  }
}

function onConnect(uiPort) {
  if (!isTrustedSender(uiPort.sender)) {
    return;
  }

  if (uiPort.name !== 'premium') {
    return;
  }

  const filters = new Map();
  uiPorts.set(uiPort, filters);

  uiPort.onDisconnect.addListener(() => {
    uiPorts.delete(uiPort);
  });

  uiPort.onMessage.addListener((message) => {
    const [type, action] = message.type.split('.', 2);
    if (action === 'listen') {
      listen(type, filters, message.filter, message,
        uiPort.sender && uiPort.sender.tab && uiPort.sender.tab.id);
    }
  });
}
browser.runtime.onConnect.addListener(onConnect);

/**
 * Process complex messages related to the 'License' object
 *
 */
_picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.ready */ .Cz.ready().then(() => {
  browser.runtime.onMessage.addListener((request, sender, sendResponse) => {
    if (request.message === 'load_my_adblock') {
      if (sender.url && sender.url.startsWith('http') && _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.isActiveLicense */ .Cz.isActiveLicense() && (0,_prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .getSettings */ .Gw)().picreplacement) {
        const logError = function (e) {
          // eslint-disable-next-line no-console
          console.error(e);
        };
        browser.tabs.executeScript(sender.tab.id, { file: 'adblock-picreplacement.js', frameId: sender.frameId, runAt: 'document_start' }).catch(logError);
      }
      if (
        _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.isActiveLicense */ .Cz.isActiveLicense()
          && sender.url
          && sender.url.startsWith('http')
          && _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_4__.subscriptions.has('https://cdn.adblockcdn.com/filters/distraction-control-push.txt')
          && _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_4__.filters.getAllowingFilters(sender.tab.id).length === 0
      ) {
        const logError = function (e) {
          // eslint-disable-next-line no-console
          console.error(e);
        };
        browser.tabs.executeScript(sender.tab.id, { file: 'adblock-picreplacement-push-notification-wrapper-cs.js', runAt: 'document_start' }).catch(logError);
      }
      sendResponse({});
    }
  });

  /**
   * Process general messages related to the 'License' object
   *
   */
  /* eslint-disable consistent-return */
  browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
    if (!isTrustedSender(sender)) {
      return;
    }
    const { command } = message;
    switch (command) {
      case 'setBlacklistCTAStatus':
        _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.shouldShowBlacklistCTA */ .Cz.shouldShowBlacklistCTA(message.isEnabled);
        sendResponse({});
        break;
      case 'setWhitelistCTAStatus':
        _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.shouldShowWhitelistCTA */ .Cz.shouldShowWhitelistCTA(message.isEnabled);
        sendResponse({});
        break;
      case 'cleanUpSevenDayAlarm':
        _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.cleanUpSevenDayAlarm */ .Cz.cleanUpSevenDayAlarm();
        sendResponse({});
        break;
      case 'updatePeriodically':
        _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.updatePeriodically */ .Cz.updatePeriodically();
        sendResponse({});
        break;
      case 'isActiveLicense':
        return processMessageResponse(sendResponse, _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.isActiveLicense */ .Cz.isActiveLicense());
      case 'shouldShowMyAdBlockEnrollment':
        return processMessageResponse(sendResponse, _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.shouldShowMyAdBlockEnrollment */ .Cz.shouldShowMyAdBlockEnrollment());
      default:
    }
  });

  /* eslint-disable consistent-return */
  browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
    const { command } = message;
    switch (command) {
      case 'openPremiumPayURL':
        openTab(_picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.MAB_CONFIG.payURL */ .Cz.MAB_CONFIG.payURL);
        sendResponse({});
        break;
      case 'payment_success':
        _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.activate */ .Cz.activate();
        sendResponse({ ack: true });
        break;
      default:
    }
  });

  /**
   * Process the message related to getting the 'License' object
   *
   */
  /* eslint-disable consistent-return */
  browser.runtime.onMessage.addListener((request, sender, sendResponse) => {
    if (request.command === 'getLicenseConfig') {
      sendResponse({});
      const response = {
        getFormattedActiveSinceDate: _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.getFormattedActiveSinceDate */ .Cz.getFormattedActiveSinceDate(),
        MAB_CONFIG: _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.MAB_CONFIG */ .Cz.MAB_CONFIG,
        shouldShowMyAdBlockEnrollment: _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.shouldShowMyAdBlockEnrollment */ .Cz.shouldShowMyAdBlockEnrollment(),
        shouldShowPremiumCTA: _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.shouldShowPremiumCTA */ .Cz.shouldShowPremiumCTA(),
        isActiveLicense: _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.isActiveLicense */ .Cz.isActiveLicense(),
        isLicenseCodeValid: _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.isLicenseCodeValid */ .Cz.isLicenseCodeValid(),
        pageReloadedOnSettingChangeKey: _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.pageReloadedOnSettingChangeKey */ .Cz.pageReloadedOnSettingChangeKey,
        userClosedSyncCTAKey: _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.userClosedSyncCTAKey */ .Cz.userClosedSyncCTAKey,
        userSawSyncCTAKey: _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.userSawSyncCTAKey */ .Cz.userSawSyncCTAKey,
        themesForCTA: _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.userSawSyncCTAKey */ .Cz.userSawSyncCTAKey,
      };
      Object.assign(response, _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.get */ .Cz.get());
      return Promise.resolve(response);
    }
  });

  /**
   * Process the messages related to Channels object
   *
   */
  /* eslint-disable consistent-return */
  browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
    if (!isTrustedSender(sender)) {
      return;
    }
    const { command } = message;
    switch (command) {
      case 'channels.getGuide':
        return processMessageResponse(sendResponse, _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.getGuide */ .ZW.getGuide());
      case 'channels.isAnyEnabled':
        return processMessageResponse(sendResponse, _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.isAnyEnabled */ .ZW.isAnyEnabled());
      case 'channels.isCustomChannelEnabled':
        return processMessageResponse(sendResponse, _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.isCustomChannelEnabled */ .ZW.isCustomChannelEnabled());
      case 'channels.initializeListeners':
        return processMessageResponse(sendResponse, _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.initializeListeners */ .ZW.initializeListeners());
      case 'channels.setEnabled':
        return processMessageResponse(sendResponse,
          _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.setEnabled */ .ZW.setEnabled(message.channelId, message.enabled));
      case 'channels.getIdByName':
        return processMessageResponse(sendResponse, _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.getIdByName */ .ZW.getIdByName(message.name));
      case 'channels.disableAllChannels':
        return processMessageResponse(sendResponse, _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.disableAllChannels */ .ZW.disableAllChannels());
      default:
    }
  });

  /**
   * Process the `getrandomlisting` &
   * 'channels.recordOneAdReplaced' message from the Image Swap content script
   *
   */
  browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
    if (message.command === 'channels.getrandomlisting') {
      if (!!_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_4__.filters.getAllowingFilters(sender.tab.id).length || !_picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.isActiveLicense */ .Cz.isActiveLicense()) {
        sendResponse({ disabledOnPage: true });
        return;
      }
      const result = _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.randomListing */ .ZW.randomListing(message.opts);
      if (result) {
        sendResponse(result);
        return;
      }
      sendResponse({ disabledOnPage: true });
    } else if (message.command === 'channels.recordOneAdReplaced') {
      sendResponse({});
      if (_picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.isActiveLicense */ .Cz.isActiveLicense()) {
        _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .replacedCounts.recordOneAdReplaced */ .lg.recordOneAdReplaced(sender.tab.id);
      }
    }
  });

  /**
   * Process the messages related to Custom channel object
   *
   */
  /* eslint-disable consistent-return */
  browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
    if (!isTrustedSender(sender)) {
      return;
    }
    const { command } = message;
    switch (command) {
      case 'customchannel.isMaximumAllowedImages': {
        const customChannelId = _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.getIdByName */ .ZW.getIdByName('CustomChannel');
        const customChannel = _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.channelGuide */ .ZW.channelGuide[customChannelId].channel;
        return processMessageResponse(sendResponse, customChannel.isMaximumAllowedImages());
      }
      case 'customchannel.getListings': {
        const customChannelId = _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.getIdByName */ .ZW.getIdByName('CustomChannel');
        const customChannel = _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.channelGuide */ .ZW.channelGuide[customChannelId].channel;
        return processMessageResponse(sendResponse, customChannel.getListings());
      }
      case 'customchannel.addCustomImage': {
        const customChannelId = _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.getIdByName */ .ZW.getIdByName('CustomChannel');
        const customChannel = _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.channelGuide */ .ZW.channelGuide[customChannelId].channel;
        return processMessageResponse(sendResponse,
          customChannel.addCustomImage(message.imageInfo));
      }
      case 'customchannel.removeListingByURL': {
        const customChannelId = _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.getIdByName */ .ZW.getIdByName('CustomChannel');
        const customChannel = _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .channels.channelGuide */ .ZW.channelGuide[customChannelId].channel;
        return processMessageResponse(sendResponse,
          customChannel.removeListingByURL(message.url));
      }
      default:
    }
  });

  /**
   * Process the messages related to Sync Service object
   *
   */
  /* eslint-disable consistent-return */
  browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
    if (!isTrustedSender(sender)) {
      return;
    }
    const { command } = message;
    switch (command) {
      case 'resetLastGetStatusCode':
        _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].resetLastGetStatusCode();
        sendResponse({});
        break;
      case 'resetLastGetErrorResponse':
        _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].resetLastGetErrorResponse();
        sendResponse({});
        break;
      case 'resetLastPostStatusCode':
        _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].resetLastPostStatusCode();
        sendResponse({});
        break;
      case 'resetAllSyncErrors':
        _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].resetAllSyncErrors();
        sendResponse({});
        break;
      case 'SyncService.enableSync':
        _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].enableSync(message.initialGet);
        sendResponse({});
        break;
      case 'SyncService.disableSync':
        _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].disableSync(message.removeName);
        sendResponse({});
        break;
      case 'SyncService.getLastPostStatusCode':
        return processMessageResponse(sendResponse, _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].getLastPostStatusCode());
      case 'SyncService.getLastGetStatusCode':
        return processMessageResponse(sendResponse, _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].getLastGetStatusCode());
      case 'SyncService.getAllExtensionNames':
        return processMessageResponse(sendResponse, _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].getAllExtensionNames());
      case 'SyncService.getCurrentExtensionName':
        return processMessageResponse(sendResponse, _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].getCurrentExtensionName());
      case 'SyncService.processUserSyncRequest':
        _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].processUserSyncRequest();
        sendResponse({});
        break;
      case 'SyncService.removeExtensionName':
        _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].removeExtensionName(message.dataDeviceName, message.dataExtensionGUID);
        sendResponse({});
        break;
      case 'SyncService.setCurrentExtensionName':
        _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].setCurrentExtensionName(message.name);
        sendResponse({});
        break;
      default:
    }
  });

  _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.licenseNotifier.on */ .Cz.licenseNotifier.on('license.updating', getListener('license', 'updating'));
  _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.licenseNotifier.on */ .Cz.licenseNotifier.on('license.updated', getListener('license', 'updated'));
  _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.licenseNotifier.on */ .Cz.licenseNotifier.on('license.updated.error', getListener('license', 'updated.error'));
  _picreplacement_check__WEBPACK_IMPORTED_MODULE_0__/* .License.licenseNotifier.on */ .Cz.licenseNotifier.on('license.expired', getListener('license', 'expired'));

  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('sync.data.receieved', getListener('sync', 'sync.data.receieved'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('sync.data.getting', getListener('sync', 'sync.data.getting'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('sync.data.error.initial.fail', getListener('sync', 'sync.data.error.initial.fail'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('sync.data.getting.error', getListener('sync', 'sync.data.getting.error'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('extension.names.downloading', getListener('sync', 'extension.names.downloading'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('extension.names.downloaded', getListener('sync', 'extension.names.downloaded'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('extension.names.downloading.error', getListener('sync', 'extension.names.ownloading.error'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('extension.name.updating', getListener('sync', 'extension.name.updating'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('extension.name.updated', getListener('sync', 'extension.name.updated'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('extension.name.updated.error', getListener('sync', 'extension.name.updated.error'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('extension.name.remove', getListener('sync', 'extension.name.remove'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('extension.name.removed', getListener('sync', 'extension.name.removed'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('extension.name.remove.error', getListener('sync', 'extension.name.remove.error'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('post.data.sending', getListener('sync', 'post.data.sending'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('post.data.sent', getListener('sync', 'post.data.sent'));
  _picreplacement_sync_service__WEBPACK_IMPORTED_MODULE_2__["default"].syncNotifier.on('post.data.sent.error', getListener('sync', 'post.data.sent.error'));

  _picreplacement_channels__WEBPACK_IMPORTED_MODULE_1__/* .channelsNotifier.on */ .l.on('channels.changed', getListener('channels', 'changed'));
});


/***/ }),

/***/ 1306:
/***/ ((__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony import */ var _check__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1177);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, log */



/**
 * Algorithm used to verify authenticity of sender
 */
const algorithm = {
  name: 'RSASSA-PKCS1-v1_5',
  modulusLength: 4096,
  publicExponent: new Uint8Array([0x01, 0x00, 0x01]),
  hash: { name: 'SHA-512' },
};
/**
 * Time (in milliseconds) from now for which we consider signatures to be valid
 * based on their associated timestamps
 */
const signatureExpiration = 60 * 60 * 1000;

/**
 * Converts base64 string into array buffer
 *
 * @param {string} str - base64 string
 *
 * @returns {Uint8Array} array buffer
 */
function base64ToArrayBuffer(str) {
  const decodedData = atob(str);
  return Uint8Array.from(decodedData, c => c.charCodeAt(0));
}

/**
 * Encodes request data to sign for verifying authenticity of sender
 *
 * @param {string} domain - Sender domain
 * @param {number} timestamp - Timestamp of current date and time
 *
 * @returns {Uint8Array} Encoded request data
 */
function getAllowData(domain, timestamp) {
  const str = `${domain},${timestamp}`;
  return new TextEncoder().encode(str);
}

/**
 * Generates public key from string for verifying signatures
 *
 * @param {string} key - public key string
 *
 * @returns {Promise<CryptoKey>} public key
 */
async function getKey(key) {
  const abKey = base64ToArrayBuffer(key);
  const importedKey = await crypto.subtle.importKey(
    'spki',
    abKey,
    algorithm,
    false,
    ['verify'],
  );
  return importedKey;
}

/**
 * Handles incoming "users.isPaying" messages
 *
 * @param {Object} message - "users.isPaying" message
 * @param {Object} sender - Message sender
 *
 * @returns {Promise<string|null>} requested payload
 */
async function handleUsersIsPayingMessage(message, sender) {
  // Check Premium state
  if (!_check__WEBPACK_IMPORTED_MODULE_0__/* .License.isActiveLicense */ .Cz.isActiveLicense()) {
    log('user not active');
    return null;
  }

  // Verify timestamp
  const { signature, timestamp } = message;
  /* eslint-disable-next-line no-use-before-define */
  const validTimestamp = verifyTimestamp(timestamp);
  if (!validTimestamp) {
    log('invalid Timestamp', timestamp);
    return null;
  }

  // Verify signature
  const domain = new URL(sender.url).hostname;
  /* eslint-disable-next-line no-use-before-define */
  const validSignature = await verifySignature(domain, timestamp, signature);
  if (!validSignature) {
    log('invalid signature');
    return null;
  }

  // Retrieve payload
  const payload = _check__WEBPACK_IMPORTED_MODULE_0__/* .License.getBypassPayload */ .Cz.getBypassPayload();
  if (!payload) {
    log('no bypass mode payload');
    return null;
  }

  return payload;
}

/**
 * Checks whether signature matches data and any of the known public keys
 * that are authorized to use the bypass API
 *
 * @param {string} domain - Sender domain
 * @param {number} timestamp - Timestamp of current date and time
 * @param {string} signature - Signature for provided domain and timestamp
 *
 * @returns {Promise<boolean>} whether signature matches data and any authorized public key
 */
async function verifySignature(domain, timestamp, signature) {
  if (typeof signature !== 'string') {
    return false;
  }

  const data = getAllowData(domain, timestamp);
  const abSignature = base64ToArrayBuffer(signature);

  const promisedValidations = _check__WEBPACK_IMPORTED_MODULE_0__/* .License.MAB_CONFIG.bypassAuthorizedKeys.map */ .Cz.MAB_CONFIG.bypassAuthorizedKeys.map(
    /* eslint-disable-next-line no-use-before-define */
    key => verifySignatureWithKey(data, abSignature, key),
  );
  const validations = await Promise.all(promisedValidations);
  return validations.some(isValid => isValid);
}

/**
 * Checks whether signature matches data and public key
 *
 * @param {Uint8Array} data - Encoded data
 * @param {Uint8Array} signature - Signature for encoded data
 * @param {string} pubKey - Public key
 *
 * @returns {Promise<boolean>} whether signature matches data and public key
 */
async function verifySignatureWithKey(data, signature, pubKey) {
  return crypto.subtle.verify(
    algorithm,
    await getKey(pubKey),
    signature,
    data,
  );
}

/**
 * Checks whether timestamp is valid
 *
 * @param {number} timestamp - Timestamp
 *
 * @returns {boolean} whether timestamp is valid
 */
function verifyTimestamp(timestamp) {
  if (typeof timestamp !== 'number' || Number.isNaN(timestamp)) {
    log('timestamp is not number', timestamp);
    return false;
  }

  const timeDiff = Date.now() - timestamp;
  return timeDiff < signatureExpiration;
}

/**
 * Initializes module
 */
function start() {
  /* eslint-disable consistent-return */
  browser.runtime.onMessage.addListener((message, sender) => {
    if (message.command !== 'users.isPaying') {
      return;
    }

    return handleUsersIsPayingMessage(message, sender);
  });
  /* eslint-enable consistent-return */
}

start();


/***/ }),

/***/ 1053:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";

// EXPORTS
__webpack_require__.d(__webpack_exports__, {
  "E": () => (/* binding */ Channels),
  "l": () => (/* binding */ channelsNotifier)
});

// EXTERNAL MODULE: ./node_modules/adblockpluscore/lib/contentTypes.js
var contentTypes = __webpack_require__(7610);
// EXTERNAL MODULE: ./vendor/webext-sdk/dist/ewe-api.js
var ewe_api = __webpack_require__(3817);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/events.js
var events = __webpack_require__(2901);
;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/image-sizes-map.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

const imageSizesMap = new Map([
  ['NONE', 0],
  ['wide', 1],
  ['tall', 2],
  ['skinnywide', 4],
  ['skinnytall', 8],
  ['big', 16],
  ['small', 32],
]);


const WIDE = imageSizesMap.get('wide');
const TALL = imageSizesMap.get('tall');
const BIG = imageSizesMap.get('big');
const SMALL = imageSizesMap.get('small');
const SKINNYWIDE = imageSizesMap.get('skinnywide');
const SKINNYTALL = imageSizesMap.get('skinnytall');

// EXTERNAL MODULE: ./adblock-betafish/subscriptionadapter.js + 1 modules
var subscriptionadapter = __webpack_require__(934);
;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/listing.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global  */


// Inputs: width:int, height:int, url:url, title:string, attributionUrl:url
class Listing {
  constructor(data) {
    this.width = data.width;
    this.height = data.height;
    this.url = data.url;
    this.title = data.title;
    this.attributionUrl = data.attributionUrl;
    this.channelName = data.channelName;
    if (data.name) {
      this.name = data.name;
    }
    if (data.thumbURL) {
      this.thumbURL = data.thumbURL;
    }
    if (data.userLink) {
      this.userLink = data.userLink;
    }
    if (data.anySize) {
      this.anySize = data.anySize;
    }
    if (data.type) {
      this.type = data.type;
    }
    if (data.ratio) {
      this.ratio = data.ratio;
    }
    if (data.customImage) {
      this.customImage = data.customImage;
    }
  }
}
/* harmony default export */ const listing = (Listing);

;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/channel.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global  */




// Base class representing a channel of photos.
// Concrete constructors must accept a single argument, because Channels.add()
// relies on that.
class Channel {
  constructor() {
    this.listings = [];
  }

  getListings() {
    return this.listings.slice(0); // shallow copy
  }

  static listingFactory(widthParam, heightParam, url, title, channelName) {
    let width = widthParam;
    let height = heightParam;
    const type = Channel.calculateType(width, height);

    if (typeof width === 'number') {
      width = `${width}`;
    }
    if (typeof height === 'number') {
      height = `${height}`;
    }
    return new listing({
      width,
      height,
      url,
      attributionUrl: url,
      type,
      ratio: Math.max(width, height) / Math.min(width, height),
      title,
      channelName, // message.json key for channel name
    });
  }

  // Update the channel's listings and trigger an 'updated' event.
  refresh() {
    const that = this;
    this.getLatestListings((listings) => {
      that.listings = listings;
    });
  }

  // Load all photos so that they're in the cache.
  static prefetch() {
    // current - noop, since all of the URLs are hard coded.
  }

  static getLatestListings() {
    throw new Error('Implemented by subclass. Call callback with up-to-date listings.');
  }

  static calculateType(w, h) {
    let width = w;
    let height = h;

    if (typeof width === 'string') {
      width = parseInt(width, 10);
    }
    if (typeof height === 'string') {
      height = parseInt(height, 10);
    }
    let type = '';
    const ratio = Math.max(width, height) / Math.min(width, height);
    if (ratio >= 1.5 && ratio < 7) {
      type = (width > height ? imageSizesMap.get('wide') : imageSizesMap.get('tall'));
    } else if (ratio > 7) {
      type = (width > height ? imageSizesMap.get('skinnywide') : imageSizesMap.get('skinnytall'));
    } else {
      type = ((width > 125 || height > 125) ? imageSizesMap.get('big') : imageSizesMap.get('small'));
    }
    return type;
  }
}
/* harmony default export */ const channel = (Channel);

;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/custom-channel.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser */

// Channel containing user imported images
// Subclass of Channel.




class CustomChannel extends channel {
  constructor() {
    super();
    this.listings = [];
    this.CUSTOM_META_KEY = 'customMetaData';
    const that = this;

    // load the meta data Array from storage
    browser.storage.local.get(this.CUSTOM_META_KEY).then((customImageMetaData) => {
      const savedCustomImageMetaData = customImageMetaData;
      if (!savedCustomImageMetaData[this.CUSTOM_META_KEY]) {
        savedCustomImageMetaData[this.CUSTOM_META_KEY] = [];
      }
      const customMetaData = savedCustomImageMetaData[this.CUSTOM_META_KEY];
      for (let inx = 0; inx < customMetaData.length; inx++) {
        const listingData = customMetaData[inx];
        if (
          listingData
          && listingData.url
          && listingData.width
          && listingData.height
          && listingData.title
        ) {
          const theNewListing = CustomChannel.createListing(listingData.width,
            listingData.height, listingData.url, listingData.title);
          that.listings.push(theNewListing);
        }
      }
    });
  }

  static createListing(theWidth, theHeight, theURL, theName) {
    let width = theWidth;
    let height = theHeight;
    const url = theURL;
    const type = channel.calculateType(width, height);

    if (typeof width === 'number') {
      width = `${width}`;
    }
    if (typeof height === 'number') {
      height = `${height}`;
    }
    return new listing({
      width,
      height,
      url,
      attributionUrl: url,
      type,
      ratio: Math.max(width, height) / Math.min(width, height),
      title: `This is an image from your PC! : ${theName}`,
      channelName: 'custom_channel_name', // message.json key for channel name
      customImage: true,
    });
  }

  // to run - channels.channelGuide[channels.getIdByName("CustomChannel")].channel.deleteAll()
  deleteAll() {
    const customImagesArray = this.listings;
    for (let inx = 0; inx < customImagesArray.length; inx++) {
      if (customImagesArray[inx] && customImagesArray[inx].url) {
        browser.storage.local.remove(customImagesArray[inx].url);
      }
    }
    browser.storage.local.remove(this.CUSTOM_META_KEY).then(() => {
      this.listings = [];
    });
  }

  getLatestListings(callback) {
    callback(this.listings);
  }

  isMaximumAllowedImages() {
    return (this.listings.length >= 9);
  }

  saveListings() {
    const that = this;
    return new Promise((resolve, reject) => {
      const persistedMetaImageObj = {};
      persistedMetaImageObj[that.CUSTOM_META_KEY] = that.listings;
      browser.storage.local.set(persistedMetaImageObj).then(() => {
        if (browser.runtime.lastError) {
          reject(browser.runtime.lastError);
        }
        resolve(true);
      });
    });
  }

  removeListingByURL(theURLToRemove) {
    for (let inx = 0; inx < this.listings.length; inx++) {
      const theListing = this.listings[inx];
      if (theListing && theListing.url === theURLToRemove) {
        this.listings.splice(inx, 1);
      }
    }
    const that = this;
    return new Promise((resolve, reject) => {
      that.saveListings().then((response) => {
        if (response) {
          browser.storage.local.remove(theURLToRemove).then(() => {
            if (browser.runtime.lastError) {
              reject(browser.runtime.lastError);
            }
            resolve(true);
          });
        } else {
          resolve(response);
        }
      });
    });
  }

  async addCustomImage(imageInfo) {
    const theNewListing = CustomChannel.createListing(imageInfo.width,
      imageInfo.height, imageInfo.listingURL, imageInfo.name);
    this.listings.push(theNewListing);
    const response = await this.saveListings().catch(() => Promise.reject());
    if (response) {
      return Promise.resolve(imageInfo.listingURL);
    }
    return Promise.reject();
  }

  getBytesInUseForEachImage() {
    if (typeof browser.storage.local.getBytesInUse !== 'function') {
      return Promise.resolve(0);
    }
    const customImagesArray = this.getListings();
    const promises = [];
    for (let inx = 0; inx < customImagesArray.length; inx++) {
      const thePromise = new Promise((resolve) => {
        if (customImagesArray[inx] && customImagesArray[inx].url) {
          browser.storage.local.getBytesInUse(customImagesArray[inx].url).then((biu) => {
            resolve(biu);
          });
        }
      });
      promises.push(thePromise);
    }
    return Promise.all(promises);
  }

  getTotalBytesInUse() {
    if (typeof browser.storage.local.getBytesInUse !== 'function') {
      return Promise.resolve(0);
    }
    return new Promise((resolve) => {
      this.getBytesInUseForEachImage().then((results) => {
        let sum = 0;
        let numResults = results.length;
        while (numResults > 0) {
          numResults -= 1;
          sum += results[numResults];
        }
        resolve(sum);
      });
    });
  }
}
/* harmony default export */ const custom_channel = (CustomChannel);

;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/data/cats.json
const cats_namespaceObject = JSON.parse('[{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x628/12--x628/cat-7784.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x628/12--x628/cat-animal-animal-portrait-pet.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x628/12--x628/cat-feline-cute-domestic.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x628/12--x628/cat-kitten-rozkosne-little.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x628/12--x628/domestic-cat-cat-adidas-relaxed.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x628/12--x628/eyes-cats-cat-couch.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x628/24--x1256/cat-7784.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x628/24--x1256/cat-animal-animal-portrait-pet.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x628/24--x1256/cat-feline-cute-domestic.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x628/24--x1256/cat-kitten-rozkosne-little.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x628/24--x1256/domestic-cat-cat-adidas-relaxed.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x628/24--x1256/eyes-cats-cat-couch.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-7784.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-82072.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-animal-animal-portrait-pet.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-animal-cute-pet-39500.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-balcony-surprised-look-80363.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-british-shorthair-mieze-blue-eye-162174.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-british-shorthair-thoroughbred-adidas-162064.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-close-animal-cat-face-162309.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-eyes-view-face-66292.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-feline-cute-domestic.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-feline-furry-pet-53446.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-feline-kitty-kitten-39380.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-home-animal-cat-s-eyes-46208.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-kitten-rozkosne-little.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-pet-eyes-animal-50566.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-pet-furry-face-162319.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-portrait-eyes-animal-162216.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-portrait-kitten-cute-128884.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-relax-chill-out-camacho-70844.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-tiger-getiegert-feel-at-home-160722.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/domestic-cat-cat-adidas-relaxed.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/eyes-cats-cat-couch.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-105587.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-106131.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-116835.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-135859.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-142615.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-171216.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-172420.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-173909.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-192384.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-207166.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-208845.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-208860.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-208878.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-208880.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-208906.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-208907.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-208954.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-208971.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-208998.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-209117.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-209800.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-210081.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-214657.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-220826.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-220876.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-220951.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-220970.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-220983.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-236630.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-236633.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-244848.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-247007.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-248254.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-248289.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-248304.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-257423.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-271889.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-272124.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-289345.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-289381.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-290263.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-327014.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-349388.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-372651.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-372657.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-416088.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-416138.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-416208.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-437886.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-461872.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-549237.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-576802.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-583250.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-596590.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-599492.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-605048.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-622549.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-65536.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-674568.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-674577 (1).jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-674577.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-679855.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-680437.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-683205.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-689042.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-709482.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-720684.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-731553.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-731637.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-733105.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-736528.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-745241.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-749212.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-751050.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-89951.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-92174.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-94434.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-95328.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-close-animal-cat-face-1623-9.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/cat-feline-kitty-kitten-3938-.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-1-5587.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-17242-.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-1739-9.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-2-886-.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-2-8878.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-58325-.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-6832-5.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-7-9482.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/3--x25-/pexels-photo-751-5-.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-7784.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-82072.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-animal-animal-portrait-pet.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-animal-cute-pet-39500.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-balcony-surprised-look-80363.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-british-shorthair-mieze-blue-eye-162174.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-british-shorthair-thoroughbred-adidas-162064.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-close-animal-cat-face-162309.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-eyes-view-face-66292.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-feline-cute-domestic.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-feline-furry-pet-53446.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-feline-kitty-kitten-39380.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-home-animal-cat-s-eyes-46208.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-kitten-rozkosne-little.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-pet-eyes-animal-50566.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-pet-furry-face-162319.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-portrait-eyes-animal-162216.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-portrait-kitten-cute-128884.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-relax-chill-out-camacho-70844.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/cat-tiger-getiegert-feel-at-home-160722.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/domestic-cat-cat-adidas-relaxed.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/eyes-cats-cat-couch.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-105587.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-106131.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-116835.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-135859.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-142615.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-171216.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-172420.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-173909.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-192384.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-207166.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-208845.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-208860.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-208878.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-208880.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-208906.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-208907.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-208954.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-208971.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-208998.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-209117.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-209800.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-210081.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-214657.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-220826.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-220876.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-220951.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-220970.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-220983.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-236630.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-236633.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-244848.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-247007.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-248254.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-248289.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-248304.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-257423.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-271889.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-272124.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-289345.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-289381.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-290263.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-327014.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-349388.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-372651.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-372657.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-416088.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-416138.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-416208.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-437886.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-461872.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-549237.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-576802.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-583250.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-596590.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-599492.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-605048.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-622549.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-65536.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-674568.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-674577 (1).jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-674577.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-679855.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-680437.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-683205.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-689042.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-709482.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-720684.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-731553.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-731637.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-733105.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-736528.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-745241.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-749212.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-751050.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-89951.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-92174.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-94434.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-95328.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-1-6131.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-2-89-6.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-2-9117.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-22-983.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-23663-.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-4162-8.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-5768-2.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-68-437.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/6--x5--/pexels-photo-7331-5.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/_6--x5--/pexels-photo-116835.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/_6--x5--/pexels-photo-59659-.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/_6--x5--/pexels-photo-7331-5.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x25-/_6--x5--/pexels-photo-94434.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x6--/3--x6--/cat-7784.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x6--/3--x6--/cat-animal-animal-portrait-pet.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x6--/3--x6--/cat-feline-cute-domestic.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x6--/3--x6--/cat-kitten-rozkosne-little.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x6--/3--x6--/domestic-cat-cat-adidas-relaxed.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x6--/3--x6--/eyes-cats-cat-couch.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x6--/6--x12--/cat-7784.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x6--/6--x12--/cat-animal-animal-portrait-pet.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x6--/6--x12--/cat-feline-cute-domestic.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x6--/6--x12--/cat-kitten-rozkosne-little.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x6--/6--x12--/domestic-cat-cat-adidas-relaxed.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Cats/3--x6--/6--x12--/eyes-cats-cat-couch.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Cats/336x28-/336x28-/cat-7784.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Cats/336x28-/336x28-/cat-animal-animal-portrait-pet.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Cats/336x28-/336x28-/cat-feline-cute-domestic.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Cats/336x28-/336x28-/cat-kitten-rozkosne-little.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Cats/336x28-/336x28-/domestic-cat-cat-adidas-relaxed.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Cats/336x28-/336x28-/eyes-cats-cat-couch.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Cats/336x28-/672x56-/cat-7784.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Cats/336x28-/672x56-/cat-animal-animal-portrait-pet.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Cats/336x28-/672x56-/cat-feline-cute-domestic.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Cats/336x28-/672x56-/cat-kitten-rozkosne-little.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Cats/336x28-/672x56-/domestic-cat-cat-adidas-relaxed.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Cats/336x28-/672x56-/eyes-cats-cat-couch.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/468x6-/cat_468x6-_01.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/468x6-/cat_468x6-_02.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/468x6-/cat_468x6-_03.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/468x6-/cat_468x6-_04.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/468x6-/cat_468x6-_05.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/468x6-/-2.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/468x6-/-3.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/468x6-/-4.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/468x6-/-5.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/468x6-/cat_468x6-_-3.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/936x12-/cat_936x120_01.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/936x12-/cat_936x120_02.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/936x12-/cat_936x120_03.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/936x12-/cat_936x120_04.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/936x12-/cat_936x120_05.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/936x12-/cat_936x12-_-1.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Cats/468x6-/936x12-/-4.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/12--x5-/cat_1200x50_01.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/12--x5-/cat_1200x50_02.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/12--x5-/cat_1200x50_03.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/12--x5-/cat_1200x50_04.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/12--x5-/cat_1200x50_05.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/12--x5-/-1.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/12--x5-/-2.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/12--x5-/-3.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/12--x5-/cat_12--x5-_-3.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/12--x5-/cat_12--x5-_-5.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/24--x1--/cat_2400x100_01.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/24--x1--/cat_2400x100_02.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/24--x1--/cat_2400x100_03.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/24--x1--/cat_2400x100_04.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/24--x1--/cat_2400x100_05.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/24--x1--/-1.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/24--x1--/-2.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/24--x1--/cat_24--x1--_-2.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Cats/12--x5-/24--x1--/cat_24--x1--_-4.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/1-9-x43/ad_1090x43_01.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/1-9-x43/ad_1090x43_02.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/1-9-x43/ad_1090x43_03.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/1-9-x43/ad_1090x43_04.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/1-9-x43/ad_1090x43_05.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/1-9-x43/-3.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/1-9-x43/-4.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/1-9-x43/ad_1-9-x43_-5.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/218-x86/cat_2180x86_01.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/218-x86/cat_2180x86_02.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/218-x86/cat_2180x86_03.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/218-x86/cat_2180x86_04.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/218-x86/cat_2180x86_05.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/218-x86/-2.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/218-x86/-3.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/218-x86/-4.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/218-x86/-5.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/218-x86/cat_218-x86_-1.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Cats/1-9-x43/218-x86/cat_218-x86_-3.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/45-x62/cat_450x62_01.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/45-x62/cat_450x62_02.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/45-x62/cat_450x62_03.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/45-x62/cat_450x62_04.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/45-x62/cat_450x62_05.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/45-x62/-1.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/45-x62/-2.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/cat_900x124_01.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/cat_900x124_02.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/cat_900x124_03.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/cat_900x124_04.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/cat_900x124_05.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/-1.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/-2.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/-3.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/-4.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/-5.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/cat_9--x124_-1.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/cat_9--x124_-2.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/cat_9--x124_-3.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/cat_9--x124_-4.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Cats/45-x62/9--x124/cat_9--x124_-5.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/1440x90/cat_1440x90_01.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/1440x90/cat_1440x90_02.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/1440x90/cat_1440x90_03.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/1440x90/cat_1440x90_04.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/1440x90/cat_1440x90_05.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/2880x180/cat_2880x180_01.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/2880x180/cat_2880x180_02.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/2880x180/cat_2880x180_03.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/2880x180/cat_2880x180_04.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/2880x180/cat_2880x180_05.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/144-x9-/-1.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/144-x9-/-4.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/144-x9-/-5.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/144-x9-/cat_144-x9-_-1.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/144-x9-/cat_144-x9-_-2.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/144-x9-/cat_144-x9-_-3.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/144-x9-/cat_144-x9-_-4.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/144-x9-/cat_144-x9-_-5.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/288-x18-/-1.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/288-x18-/-2.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/288-x18-/-3.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/288-x18-/-4.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/288-x18-/-5.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/288-x18-/cat_288-x18-_-1.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/288-x18-/cat_288-x18-_-2.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/288-x18-/cat_288-x18-_-3.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/288-x18-/cat_288-x18-_-4.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/144-x9-/288-x18-/cat_288-x18-_-5.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x180_01.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x180_02.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x180_03.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x180_04.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x180_05.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x18-_01.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x18-_02.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x18-_03.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x18-_04.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x18-_05.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x18-_-3.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x18-_-4.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x18-_-6.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x18-_-7.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x18-_-8.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/1456x18-/cat_1456x18-_1-.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/728x9-/cat_728x90_01.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/728x9-/cat_728x90_02.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/728x9-/cat_728x90_03.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/728x9-/cat_728x90_04.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/728x9-/cat_728x90_05.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/728x9-/cat_728x9-_01.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/728x9-/cat_728x9-_02.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/728x9-/cat_728x9-_03.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/728x9-/cat_728x9-_04.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/728x9-/cat_728x9-_05.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/728x9-/cat_728x9-_-4.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/728x9-/728x9-/cat_728x9-_-1.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/34-x9-/Cats_34-x9-_01.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/34-x9-/Cats_34-x9-_02.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/34-x9-/Cats_34-x9-_03.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/34-x9-/Cats_34-x9-_04.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/34-x9-/Cats_34-x9-_05.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/68-x18-/Cats_68-x18-_01.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/68-x18-/Cats_68-x18-_02.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/68-x18-/Cats_68-x18-_03.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/68-x18-/Cats_68-x18-_04.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/68-x18-/Cats_68-x18-_05.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/68-x18-/Cats_68-x18-_-1.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/68-x18-/Cats_68-x18-_-2.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/68-x18-/Cats_68-x18-_-4.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/68-x18-/Cats_68-x18-_-5.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/68-x18-/Cats_68-x18-_-9.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/68-x18-/Cats_68-x18-_1-.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Cats/34-x9-/68-x18-/Cats_68-x18-_11.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Cats/16-x6--/32-x12--/cat-kitten-rozkosne-little.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Cats/16-x6--/32-x12--/cat-7784.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Cats/56-x672/112-x1344/pexels-photo-437886.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Cats/56-x672/112-x1344/pexels-photo-2-8845.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Cats/56-x672/112-x1344/pexels-photo-21--81.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Cats/56-x672/112-x1344/pexels-photo-22-983.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Cats/56-x672/56-x672/pexels-photo-22-97-.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Cats/56-x672/56-x672/pexels-photo-416138.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Cats/56-x672/56-x672/pexels-photo-59659-.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Cats/56-x672/56-x672/pexels-photo-731553.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Cats/56-x672/56-x672/pexels-photo-89951.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/cat-7784.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/cat-82-72.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/cat-feline-cute-domestic.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/domestic-cat-cat-adidas-relaxed.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-1-5587.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-1-6131.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-142615.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-17242-.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-1739-9.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-2-8845.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-2-886-.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-2-888-.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-2-89-6.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-2-89-7.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-2-9117.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-2-98--.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-22-826.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-22-876.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-22-951.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-22-983.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-244848.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-2483-4.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-416138.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-549237.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-59659-.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-599492.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-6-5-48.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-622549.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-674568.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-674577.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-679855.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-689-42.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-7-9482.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-7331-5.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-736528.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-745241.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/18-x68-/pexels-photo-749212.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/cat-7784.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/cat-82-72.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/cat-feline-cute-domestic.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/domestic-cat-cat-adidas-relaxed.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-1-5587.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-1-6131.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-142615.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-17242-.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-1739-9.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-2-8845.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-2-886-.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-2-888-.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-2-89-6.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-2-89-7.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-2-9117.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-2-98--.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-22-826.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-22-876.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-22-951.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-22-983.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-244848.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-2483-4.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-416138.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-549237.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-59659-.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-599492.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-6-5-48.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-622549.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-674568.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-674577.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-679855.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-689-42.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-7-9482.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-7331-5.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-736528.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-745241.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Cats/18-x68-/36-x136-/pexels-photo-749212.jpg"}]');
;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/cat-channel.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global   */





// Channel containing hard coded cats loaded from disk.
// Subclass of Channel.
class CatsChannel extends channel {
  getLatestListings(callback) {
    for (const cat of cats_namespaceObject) {
      this.listings.push(channel.listingFactory(cat.width, cat.height, cat.url, 'This is a cat!', 'catchannelswitchlabel'));
    }
    callback(this.listings);
  }
}
/* harmony default export */ const cat_channel = (CatsChannel);

;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/data/dogs.json
const dogs_namespaceObject = JSON.parse('[{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/12--x628/animal-dog-golden-retriever-9716.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/12--x628/animal-dog-pet-brown.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/12--x628/bordeaux-mastiff-dog-animal.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/12--x628/dalmatians-dog-animal-head.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/12--x628/dog-brown-snout-fur.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/12--x628/dog-cute-pet.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/12--x628/dog-young-dog-small-dog-maltese.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/12--x628/nature-animal-dog-pet.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/12--x628/night-animal-dog-pet.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/12--x628/night-garden-yellow-animal.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/12--x628/wall-animal-dog-pet.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/24--x1256/animal-dog-golden-retriever-9716.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/24--x1256/animal-dog-pet-brown.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/24--x1256/bordeaux-mastiff-dog-animal.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/24--x1256/dalmatians-dog-animal-head.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/24--x1256/dog-brown-snout-fur.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/24--x1256/dog-cute-pet.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/24--x1256/dog-young-dog-small-dog-maltese.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/24--x1256/nature-animal-dog-pet.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/24--x1256/night-animal-dog-pet.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/24--x1256/night-garden-yellow-animal.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/24--x1256/wall-animal-dog-pet.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/3--x25-/animal-dog-golden-retriever-9716.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/3--x25-/animal-dog-pet-brown.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/3--x25-/bordeaux-mastiff-dog-animal.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/3--x25-/dalmatians-dog-animal-head.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/3--x25-/dog-brown-snout-fur.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/3--x25-/dog-cute-pet.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/3--x25-/dog-young-dog-small-dog-maltese.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/3--x25-/nature-animal-dog-pet.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/3--x25-/night-animal-dog-pet.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/3--x25-/night-garden-yellow-animal.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/3--x25-/wall-animal-dog-pet.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/6--x5--/animal-dog-golden-retriever-9716.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/6--x5--/animal-dog-pet-brown.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/6--x5--/bordeaux-mastiff-dog-animal.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/6--x5--/dalmatians-dog-animal-head.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/6--x5--/dog-brown-snout-fur.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/6--x5--/dog-cute-pet.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/6--x5--/dog-young-dog-small-dog-maltese.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/6--x5--/nature-animal-dog-pet.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/6--x5--/night-animal-dog-pet.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/6--x5--/night-garden-yellow-animal.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/6--x5--/wall-animal-dog-pet.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/3--x6--/animal-dog-golden-retriever-9716.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/3--x6--/animal-dog-pet-brown.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/3--x6--/bordeaux-mastiff-dog-animal.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/3--x6--/dalmatians-dog-animal-head.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/3--x6--/dog-brown-snout-fur.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/3--x6--/dog-cute-pet.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/3--x6--/dog-young-dog-small-dog-maltese.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/3--x6--/nature-animal-dog-pet.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/3--x6--/night-animal-dog-pet.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/3--x6--/night-garden-yellow-animal.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/3--x6--/wall-animal-dog-pet.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/6--x12--/animal-dog-golden-retriever-9716.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/6--x12--/animal-dog-pet-brown.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/6--x12--/bordeaux-mastiff-dog-animal.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/6--x12--/dalmatians-dog-animal-head.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/6--x12--/dog-brown-snout-fur.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/6--x12--/dog-cute-pet.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/6--x12--/dog-young-dog-small-dog-maltese.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/6--x12--/nature-animal-dog-pet.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/6--x12--/night-animal-dog-pet.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/6--x12--/night-garden-yellow-animal.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/6--x12--/wall-animal-dog-pet.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/336x28-/animal-dog-golden-retriever-9716.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/336x28-/animal-dog-pet-brown.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/336x28-/bordeaux-mastiff-dog-animal.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/336x28-/dalmatians-dog-animal-head.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/336x28-/dog-brown-snout-fur.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/336x28-/dog-cute-pet.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/336x28-/dog-young-dog-small-dog-maltese.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/336x28-/nature-animal-dog-pet.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/336x28-/night-animal-dog-pet.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/336x28-/night-garden-yellow-animal.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/336x28-/wall-animal-dog-pet.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/672x56-/animal-dog-golden-retriever-9716.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/672x56-/animal-dog-pet-brown.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/672x56-/bordeaux-mastiff-dog-animal.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/672x56-/dalmatians-dog-animal-head.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/672x56-/dog-brown-snout-fur.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/672x56-/dog-cute-pet.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/672x56-/dog-young-dog-small-dog-maltese.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/672x56-/nature-animal-dog-pet.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/672x56-/night-animal-dog-pet.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/672x56-/night-garden-yellow-animal.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/672x56-/wall-animal-dog-pet.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/468x6-/dog_468x6-_01.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/468x6-/dog_468x6-_02.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/468x6-/dog_468x6-_03.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/468x6-/dog_468x6-_04.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/468x6-/dog_468x6-_05.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/468x6-/-3.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/468x6-/-4.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/468x6-/dog_468x6-_-2.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/468x6-/dog_468x6-_-4.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/dog_936x120_01.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/dog_936x120_02.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/dog_936x120_03.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/dog_936x120_04.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/dog_936x120_05.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/-1.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/-2.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/-3.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/-4.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/-5.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/dog_936x12-_-1.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/dog_936x12-_-2.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/dog_936x12-_-4.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Dogs/468x6-/936x12-/dog_936x12-_-5.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/45-x62/dog_450x62_01.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/45-x62/dog_450x62_02.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/45-x62/dog_450x62_03.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/45-x62/dog_450x62_04.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/45-x62/dog_450x62_05.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/45-x62/-4.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/45-x62/-5.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/45-x62/dog_45-x62_-1.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/dog_900x124_01.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/dog_900x124_02.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/dog_900x124_03.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/dog_900x124_04.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/dog_900x124_05.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/-1.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/-3.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/-4.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/-5.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/dog_9--x124_-1.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/dog_9--x124_-2.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/dog_9--x124_-3.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/dog_9--x124_-4.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Dogs/45-x62/9--x124/dog_9--x124_-5.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/1-9-x43/dog_1090x43_01.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/1-9-x43/dog_1090x43_02.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/1-9-x43/dog_1090x43_03.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/1-9-x43/dog_1090x43_04.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/1-9-x43/dog_1090x43_05.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/1-9-x43/-2.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/1-9-x43/-3.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/1-9-x43/dog_1-9-x43_-1.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/1-9-x43/dog_1-9-x43_-2.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/1-9-x43/dog_1-9-x43_-3.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/218-x86/dog_2180x86_01.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/218-x86/dog_2180x86_02.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/218-x86/dog_2180x86_03.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/218-x86/dog_2180x86_04.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/218-x86/dog_2180x86_05.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/218-x86/-1.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/218-x86/-2.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/218-x86/-3.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/218-x86/-5.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/218-x86/dog_218-x86_-2.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/218-x86/dog_218-x86_-3.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Dogs/1-9-x43/218-x86/dog_218-x86_-4.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/12--x5-/dog_1200x50_01.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/12--x5-/dog_1200x50_02.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/12--x5-/dog_1200x50_03.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/12--x5-/dog_1200x50_04.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/12--x5-/dog_1200x50_05.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/12--x5-/-2.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/12--x5-/dog_12--x5-_-2.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/12--x5-/dog_12--x5-_-3.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/24--x1--/dog_2400x100_01.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/24--x1--/dog_2400x100_02.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/24--x1--/dog_2400x100_03.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/24--x1--/dog_2400x100_04.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/24--x1--/dog_2400x100_05.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/24--x1--/-3.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/24--x1--/-4.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/24--x1--/dog_24--x1--_-1.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x5-/24--x1--/dog_24--x1--_-4.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/144-x9-/dog_1440x90_01.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/144-x9-/dog_1440x90_02.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/144-x9-/dog_1440x90_03.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/144-x9-/dog_1440x90_04.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/144-x9-/dog_1440x90_05.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/144-x9-/-5.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/144-x9-/dog_144-x9-_-2.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/288-x18-/dog_2880x180_01.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/288-x18-/dog_2880x180_02.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/288-x18-/dog_2880x180_03.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/288-x18-/dog_2880x180_04.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/288-x18-/dog_2880x180_05.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/288-x18-/-2.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/288-x18-/dog_288-x18-_-5.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/144-x9-/288-x18-/-5.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x180_01.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x180_02.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x180_03.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x180_04.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x180_05.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_01.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_02.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_03.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_04.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_05.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_-1.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_-2.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_-3.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_-4.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_-5.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_-6.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_-7.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_-8.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_-9.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_1-.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/1456x18-/Dog_1456x18-_11.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/728x9-/Dog_728x90_01.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/728x9-/Dog_728x90_02.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/728x9-/Dog_728x90_03.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/728x9-/Dog_728x90_04.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/728x9-/Dog_728x90_05.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/728x9-/Dog_728x9-_01.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/728x9-/Dog_728x9-_02.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/728x9-/Dog_728x9-_03.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/728x9-/Dog_728x9-_04.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/728x9-/Dog_728x9-_05.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/728x9-/Dog_728x9-_-2.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/728x9-/728x9-/Dog_728x9-_-4.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/34-x9-/Dogs_34-x9-_01.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/34-x9-/Dogs_34-x9-_02.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/34-x9-/Dogs_34-x9-_03.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/34-x9-/Dogs_34-x9-_04.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/34-x9-/Dogs_34-x9-_05.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/34-x9-/Dogs_34-x9-_-1.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/34-x9-/Dogs_34-x9-_-3.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/34-x9-/Dogs_34-x9-_-4.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/34-x9-/Dogs_34-x9-_-8.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/34-x9-/Dogs_34-x9-_-9.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/34-x9-/Dogs_34-x9-_1-.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_01.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_02.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_03.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_04.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_05.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_-1.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_-2.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_-4.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_-5.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_-6.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_-7.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_-9.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_1-.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Dogs/34-x9-/68-x18-/Dogs_68-x18-_11.jpg"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/16-x6--/16-x6--/bordeaux-mastiff-dog-animal.jpg"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/16-x6--/16-x6--/dog-cute-pet.jpg"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/16-x6--/16-x6--/wall-animal-dog-pet.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/16-x6--/32-x12--/animal-dog-pet-brown.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/16-x6--/32-x12--/bordeaux-mastiff-dog-animal.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/16-x6--/32-x12--/dog-young-dog-small-dog-maltese.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/16-x6--/32-x12--/night-garden-yellow-animal.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Dogs/56-x672/56-x672/pexels-photo-97863.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Dogs/56-x672/56-x672/dog-animal-friend-pointer-16226-.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Dogs/56-x672/56-x672/pexels-photo-594687.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Dogs/56-x672/112-x1344/pexels-photo-113883.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Dogs/56-x672/112-x1344/pexels-photo-434-9-.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Dogs/56-x672/112-x1344/pexels-photo-46-186.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Dogs/56-x672/112-x1344/pexels-photo-58997.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/12--x628/pexels-photo-89249.png"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Dogs/12--x628/24--x1256/pexels-photo-89249.png"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/3--x25-/pexels-photo-89249.png"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x25-/6--x5--/pexels-photo-89249.png"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/3--x6--/pexels-photo-89249.png"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Dogs/3--x6--/6--x12--/pexels-photo-89249.png"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/336x28-/pexels-photo-89249.png"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Dogs/336x28-/672x56-/pexels-photo-89249.png"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Dogs/16-x6--/16-x6--/pexels-photo-89249.png"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/bordeaux-mastiff-dog-animal.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/dalmatians-dog-animal-head.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/dog-bernese-mountain-dog-berner-senner-dog-577-8.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/dog-bulldog-white-tongue-4-986.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/dog-cavalier-king-charles-spaniel-funny-pet-162193.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/dog-hybrid-animal-lying-162349.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/dog-young-dog-puppy-59965.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/dog-young-dog-small-dog-maltese.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/english-bulldog-bulldog-canine-dog-4-544.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/french-bulldog-summer-smile-joy-16-846.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/nature-animal-dog-pet.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/papillon-dog-animal-59969.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-13-763.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-134392.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-164446.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-169524.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-2358-5.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-247997.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-25757-.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-257577.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-271824.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-356378.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-3749-8.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-412465.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-4162-4.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-452772.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-46-132.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-46-823.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-485294.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-532423.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-58997.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-594687.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-612813.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-61372.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-66687-.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-688694.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-71-927.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-72-678.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-752383.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-8--33-.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/pexels-photo-9238-.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/tibet-terrier-cute-pet-dog-162276.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/wall-animal-dog-pet.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/weimaraner-puppy-dog-snout-97-82.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/wildlife-photography-pet-photography-dog-animal-159541.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/18-x68-/wildlife-photography-pet-photography-dog-dog-runs-159492.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/bordeaux-mastiff-dog-animal.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/dalmatians-dog-animal-head.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/dog-bernese-mountain-dog-berner-senner-dog-577-8.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/dog-bulldog-white-tongue-4-986.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/dog-cavalier-king-charles-spaniel-funny-pet-162193.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/dog-hybrid-animal-lying-162349.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/dog-young-dog-puppy-59965.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/dog-young-dog-small-dog-maltese.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/english-bulldog-bulldog-canine-dog-4-544.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/french-bulldog-summer-smile-joy-16-846.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/nature-animal-dog-pet.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/papillon-dog-animal-59969.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-13-763.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-134392.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-164446.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-169524.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-2358-5.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-247997.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-25757-.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-257577.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-271824.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-356378.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-3749-8.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-412465.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-4162-4.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-452772.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-46-132.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-46-823.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-485294.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-532423.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-58997.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-594687.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-612813.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-61372.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-66687-.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-688694.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-71-927.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-72-678.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-752383.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-8--33-.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/pexels-photo-9238-.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/tibet-terrier-cute-pet-dog-162276.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/wall-animal-dog-pet.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/weimaraner-puppy-dog-snout-97-82.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/wildlife-photography-pet-photography-dog-animal-159541.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Dogs/18-x68-/36-x136-/wildlife-photography-pet-photography-dog-dog-runs-159492.jpg"}]');
;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/dog-channel.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global */





// Channel containing hard coded dogs loaded from CDN
// Subclass of Channel.
class DogsChannel extends channel {
  getLatestListings(callback) {
    for (const dog of dogs_namespaceObject) {
      this.listings.push(channel.listingFactory(dog.width, dog.height, dog.url, 'This is a dog!', 'dogchannelswitchlabel'));
    }
    callback(this.listings);
  }
}
/* harmony default export */ const dog_channel = (DogsChannel);

;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/data/landscapes.json
const landscapes_namespaceObject = JSON.parse('[{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/12--x628/amazing-animal-beautiful-beautifull.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/12--x628/amazing-beautiful-beauty-blue.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/12--x628/antelope-canyon-lower-canyon-arizona.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/12--x628/delicate-arch-night-stars-landscape.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/12--x628/italian-landscape-mountains-nature.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/12--x628/pexels-photo (1).jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/12--x628/pexels-photo (2).jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/12--x628/pexels-photo.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/12--x628/road-sun-rays-path.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/12--x628/sunrise-phu-quoc-island-ocean.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/12--x628/sunset-field-poppy-sun-priroda.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/12--x628/switzerland-zermatt-mountains-snow.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/24--x1256/amazing-animal-beautiful-beautifull.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/24--x1256/amazing-beautiful-beauty-blue.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/24--x1256/antelope-canyon-lower-canyon-arizona.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/24--x1256/delicate-arch-night-stars-landscape.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/24--x1256/italian-landscape-mountains-nature.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/24--x1256/pexels-photo (1).jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/24--x1256/pexels-photo (2).jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/24--x1256/pexels-photo.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/24--x1256/road-sun-rays-path.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/24--x1256/sunrise-phu-quoc-island-ocean.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/24--x1256/sunset-field-poppy-sun-priroda.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x628/24--x1256/switzerland-zermatt-mountains-snow.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/3--x25-/amazing-animal-beautiful-beautifull.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/3--x25-/amazing-beautiful-beauty-blue.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/3--x25-/antelope-canyon-lower-canyon-arizona.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/3--x25-/delicate-arch-night-stars-landscape.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/3--x25-/italian-landscape-mountains-nature.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/3--x25-/pexels-photo (1).jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/3--x25-/pexels-photo (2).jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/3--x25-/pexels-photo.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/3--x25-/road-sun-rays-path.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/3--x25-/sunrise-phu-quoc-island-ocean.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/3--x25-/sunset-field-poppy-sun-priroda.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/3--x25-/switzerland-zermatt-mountains-snow.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/6--x5--/amazing-animal-beautiful-beautifull.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/6--x5--/amazing-beautiful-beauty-blue.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/6--x5--/antelope-canyon-lower-canyon-arizona.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/6--x5--/delicate-arch-night-stars-landscape.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/6--x5--/italian-landscape-mountains-nature.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/6--x5--/pexels-photo (1).jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/6--x5--/pexels-photo (2).jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/6--x5--/pexels-photo.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/6--x5--/road-sun-rays-path.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/6--x5--/sunrise-phu-quoc-island-ocean.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/6--x5--/sunset-field-poppy-sun-priroda.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x25-/6--x5--/switzerland-zermatt-mountains-snow.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/3--x6--/amazing-animal-beautiful-beautifull.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/3--x6--/amazing-beautiful-beauty-blue.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/3--x6--/antelope-canyon-lower-canyon-arizona.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/3--x6--/delicate-arch-night-stars-landscape.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/3--x6--/italian-landscape-mountains-nature.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/3--x6--/pexels-photo (1).jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/3--x6--/pexels-photo (2).jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/3--x6--/pexels-photo.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/3--x6--/road-sun-rays-path.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/3--x6--/sunrise-phu-quoc-island-ocean.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/3--x6--/sunset-field-poppy-sun-priroda.jpg"},{"width":300,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/3--x6--/switzerland-zermatt-mountains-snow.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/6--x12--/amazing-animal-beautiful-beautifull.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/6--x12--/amazing-beautiful-beauty-blue.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/6--x12--/antelope-canyon-lower-canyon-arizona.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/6--x12--/delicate-arch-night-stars-landscape.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/6--x12--/italian-landscape-mountains-nature.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/6--x12--/pexels-photo (1).jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/6--x12--/pexels-photo (2).jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/6--x12--/pexels-photo.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/6--x12--/road-sun-rays-path.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/6--x12--/sunrise-phu-quoc-island-ocean.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/6--x12--/sunset-field-poppy-sun-priroda.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/3--x6--/6--x12--/switzerland-zermatt-mountains-snow.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/336x28-/amazing-animal-beautiful-beautifull.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/336x28-/amazing-beautiful-beauty-blue.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/336x28-/antelope-canyon-lower-canyon-arizona.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/336x28-/delicate-arch-night-stars-landscape.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/336x28-/italian-landscape-mountains-nature.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/336x28-/pexels-photo (1).jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/336x28-/pexels-photo (2).jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/336x28-/pexels-photo.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/336x28-/road-sun-rays-path.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/336x28-/sunrise-phu-quoc-island-ocean.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/336x28-/sunset-field-poppy-sun-priroda.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/336x28-/switzerland-zermatt-mountains-snow.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/672x56-/amazing-animal-beautiful-beautifull.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/672x56-/amazing-beautiful-beauty-blue.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/672x56-/antelope-canyon-lower-canyon-arizona.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/672x56-/delicate-arch-night-stars-landscape.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/672x56-/italian-landscape-mountains-nature.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/672x56-/pexels-photo (1).jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/672x56-/pexels-photo (2).jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/672x56-/pexels-photo.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/672x56-/road-sun-rays-path.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/672x56-/sunrise-phu-quoc-island-ocean.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/672x56-/sunset-field-poppy-sun-priroda.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Landscapes/336x28-/672x56-/switzerland-zermatt-mountains-snow.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/1-9-x43/landscape_1090x43_01.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/1-9-x43/landscape_1090x43_02.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/1-9-x43/landscape_1090x43_03.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/1-9-x43/landscape_1090x43_04.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/1-9-x43/landscape_1090x43_05.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/1-9-x43/-2.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/1-9-x43/landscape_1-9-x43_-2.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/218-x86/landscape_2180x86_01.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/218-x86/landscape_2180x86_02.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/218-x86/landscape_2180x86_03.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/218-x86/landscape_2180x86_04.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/218-x86/landscape_2180x86_05.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/218-x86/landscape_218-x86_-1.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Landscapes/1-9-x43/218-x86/landscape_218-x86_-4.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/45-x62/landscape_450x62_01.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/45-x62/landscape_450x62_02.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/45-x62/landscape_450x62_03.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/45-x62/landscape_450x62_04.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/45-x62/landscape_450x62_05.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/45-x62/-3.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/45-x62/-4.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/45-x62/-5.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/45-x62/landscape_45-x62_-5.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/9--x124/landscape_900x124_01.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/9--x124/landscape_900x124_02.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/9--x124/landscape_900x124_03.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/9--x124/landscape_900x124_04.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/9--x124/landscape_900x124_05.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/9--x124/-1.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/9--x124/-2.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/9--x124/-3.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/9--x124/-4.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/9--x124/-5.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/9--x124/landscape_9--x124_-2.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/9--x124/landscape_9--x124_-3.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Landscapes/45-x62/9--x124/landscape_9--x124_-4.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/144-x9-/landscape_1440x90_01.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/144-x9-/landscape_1440x90_02.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/144-x9-/landscape_1440x90_03.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/144-x9-/landscape_1440x90_04.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/144-x9-/landscape_1440x90_05.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/144-x9-/-1.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/144-x9-/-2.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/144-x9-/-3.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/144-x9-/-5.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/144-x9-/landscape_144-x9-_-1.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/144-x9-/landscape_144-x9-_-3.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/288-x18-/landscape_2880x180_01.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/288-x18-/landscape_2880x180_02.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/288-x18-/landscape_2880x180_03.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/288-x18-/landscape_2880x180_04.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/288-x18-/landscape_2880x180_05.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/288-x18-/-3.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/288-x18-/landscape_288-x18-_-2.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/144-x9-/288-x18-/landscape_288-x18-_-5.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/landscape_1200x50_01.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/landscape_1200x50_02.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/landscape_1200x50_03.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/landscape_1200x50_04.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/landscape_1200x50_05.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/-1.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/-2.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/-3.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/-4.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/-5.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/landscape_12--x5-_-2.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/landscape_12--x5-_-3.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/landscape_12--x5-_-4.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/landscape_12--x5-_-5.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/12--x5-/landscape_12--x5-_-1.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/landscape_2400x100_01.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/landscape_2400x100_02.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/landscape_2400x100_03.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/landscape_2400x100_04.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/landscape_2400x100_05.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/-1.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/-2.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/-3.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/-4.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/-5.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/landscape_24--x1--_-1.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/landscape_24--x1--_-2.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/landscape_24--x1--_-3.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/landscape_24--x1--_-4.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Landscapes/12--x5-/24--x1--/landscape_24--x1--_-5.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/468x6-/landscape_468x6-_01.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/468x6-/landscape_468x6-_02.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/468x6-/landscape_468x6-_03.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/468x6-/landscape_468x6-_04.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/468x6-/landscape_468x6-_05.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/468x6-/-4.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/468x6-/landscape_468x6-_-4.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/936x12-/landscape_936x120_01.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/936x12-/landscape_936x120_02.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/936x12-/landscape_936x120_03.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/936x12-/landscape_936x120_04.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/936x12-/landscape_936x120_05.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/936x12-/-1.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Landscapes/468x6-/936x12-/landscape_936x12-_-3.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x180_01.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x180_02.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x180_03.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x180_04.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x180_05.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_01.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_02.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_03.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_04.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_05.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_-3.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_-4.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_-7.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_1-.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_11.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_12.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_15.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_17.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/1456x18-/Landscape_1456x18-_-2.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/728x9-/Landscape_728x90_01.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/728x9-/Landscape_728x90_02.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/728x9-/Landscape_728x90_03.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/728x9-/Landscape_728x90_04.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/728x9-/Landscape_728x90_05.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/728x9-/Landscape_728x9-_01.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/728x9-/Landscape_728x9-_02.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/728x9-/Landscape_728x9-_03.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/728x9-/Landscape_728x9-_04.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/728x9-/Landscape_728x9-_05.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/728x9-/Landscape_728x9-_-1.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/728x9-/Landscape_728x9-_-4.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/728x9-/728x9-/Landscape_728x9-_-5.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/34-x9-/Landscape_34-x9-_01.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/34-x9-/Landscape_34-x9-_02.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/34-x9-/Landscape_34-x9-_03.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/34-x9-/Landscape_34-x9-_04.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/34-x9-/Landscape_34-x9-_05.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/34-x9-/Landscape_34-x9-_-2.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/34-x9-/Landscape_34-x9-_-3.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/34-x9-/Landscape_34-x9-_-4.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/34-x9-/Landscape_34-x9-_1-.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/34-x9-/Landscape_34-x9-_11.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_01.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_02.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_03.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_04.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_05.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_-2.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_-3.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_-5.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_-6.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_-8.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_1-.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_11.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_12.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_14.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_15.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_16.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Landscapes/34-x9-/68-x18-/Landscape_68-x18-_17.jpg"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/16-x6--/amazing-animal-beautiful-beautifull.jpg"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/16-x6--/amazing-beautiful-beauty-blue.jpg"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/16-x6--/antelope-canyon-lower-canyon-arizona.jpg"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/16-x6--/delicate-arch-night-stars-landscape.jpg"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/16-x6--/italian-landscape-mountains-nature.jpg"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/16-x6--/pexels-photo (1).jpg"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/16-x6--/pexels-photo (2).jpg"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/16-x6--/road-sun-rays-path.jpg"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/16-x6--/sunset-field-poppy-sun-priroda.jpg"},{"width":160,"height":600,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/16-x6--/switzerland-zermatt-mountains-snow.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/32-x12--/amazing-beautiful-beauty-blue.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/32-x12--/antelope-canyon-lower-canyon-arizona.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/32-x12--/italian-landscape-mountains-nature.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/32-x12--/pexels-photo (1).jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/32-x12--/pexels-photo (2).jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/32-x12--/road-sun-rays-path.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/32-x12--/sunrise-phu-quoc-island-ocean.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Landscapes/16-x6--/32-x12--/switzerland-zermatt-mountains-snow.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Landscapes/18-x68-/18-x68-/pexels-photo-414-83.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Landscapes/18-x68-/18-x68-/pexels-photo-351448.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Landscapes/18-x68-/36-x136-/amazing-animal-beautiful-beautifull.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Landscapes/18-x68-/36-x136-/pexels-photo-164196.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Landscapes/18-x68-/36-x136-/pexels-photo-189848.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Landscapes/18-x68-/36-x136-/pexels-photo-21-186.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Landscapes/18-x68-/36-x136-/pexels-photo-221148.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Landscapes/18-x68-/36-x136-/pexels-photo-388-65.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Landscapes/18-x68-/36-x136-/pexels-photo-443446.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Landscapes/56-x672/112-x1344/pexels-photo-355241.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Landscapes/56-x672/112-x1344/pexels-photo-552791.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Landscapes/56-x672/112-x1344/switzerland-zermatt-mountains-snow.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Landscapes/56-x672/56-x672/boat-house-cottage-waters-lake-65225.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Landscapes/56-x672/56-x672/pexels-photo (1).jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Landscapes/56-x672/56-x672/pexels-photo-117843.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Landscapes/56-x672/56-x672/pexels-photo-221148.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Landscapes/56-x672/56-x672/yellowstone-national-park-sunset-twilight-dusk-158489.jpg"}]');
;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/landscape-channel.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global  */





// Channel containing hard coded Landscapes loaded from CDN.
// Subclass of Channel.
class LandscapesChannel extends channel {
  getLatestListings(callback) {
    for (const landscape of landscapes_namespaceObject) {
      this.listings.push(channel.listingFactory(landscape.width, landscape.height, landscape.url, 'This is a landscape!', 'landscapechannelswitchlabel'));
    }
    callback(this.listings);
  }
}
/* harmony default export */ const landscape_channel = (LandscapesChannel);

;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/data/birds.json
const birds_namespaceObject = JSON.parse('[{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_000.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_001.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_002.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_003.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_004.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_005.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_006.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_007.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_008.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_009.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_010.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_011.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_012.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_013.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_014.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_015.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_016.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_017.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Birds/18-x68-/file_018.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_000.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_001.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_002.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_003.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_004.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_005.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_006.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_007.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_008.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_009.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_010.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_011.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_012.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_013.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_014.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_015.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_016.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_017.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_018.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_019.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_020.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_021.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_022.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_023.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_024.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_025.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_026.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_027.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_028.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_029.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_030.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_031.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_032.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_033.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_034.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_035.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_036.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_037.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_038.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_039.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_040.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_041.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_042.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_043.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_044.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_045.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_046.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_047.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_048.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_049.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_050.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_051.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_052.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_053.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_054.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_055.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_056.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_057.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_058.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_059.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_060.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_061.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_062.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_063.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_064.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_065.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_066.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_067.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_068.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_069.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_070.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_071.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_072.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_073.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_074.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_075.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_076.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_077.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_078.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_079.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_080.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_081.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_082.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_083.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_084.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_085.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_086.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_087.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_088.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_089.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_090.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_091.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_092.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_093.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_094.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_095.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_096.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_097.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/24--x1256/file_098.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_000.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_001.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_002.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_003.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_004.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_005.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_006.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_007.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_008.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_009.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_010.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_011.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_012.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_013.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_014.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_015.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_016.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_017.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_018.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_019.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_020.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_021.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_022.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_023.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_024.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_025.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_026.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_027.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_028.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_029.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_030.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_031.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_032.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_033.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_034.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_035.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_036.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_037.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_038.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_039.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_040.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_041.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_042.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_043.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_044.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_045.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_046.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_047.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_048.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_049.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_050.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_051.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_052.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_053.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_054.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_055.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_056.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_057.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_058.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_059.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_060.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_061.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_062.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_063.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_064.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_065.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_066.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_067.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_068.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_069.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_070.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_071.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_072.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_073.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_074.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_075.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_076.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_077.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_078.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_079.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_080.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_081.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_082.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_083.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_084.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_085.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_086.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_087.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_088.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_089.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_090.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_091.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_092.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_093.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_094.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_095.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_096.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_097.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Birds/3--x25-/file_098.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_000.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_001.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_002.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_003.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_004.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_005.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_006.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_007.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_008.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_009.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_010.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_011.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_012.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_013.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_014.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_015.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_016.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_017.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_018.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_019.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_020.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_021.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_022.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_023.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_024.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_025.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_026.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_027.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_028.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_029.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_030.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_031.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_032.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_033.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_034.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_035.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_036.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_037.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_038.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_039.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_040.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_041.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_042.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_043.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_044.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_045.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_046.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_047.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_048.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_049.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_050.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_051.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_052.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_053.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_054.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_055.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_056.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_057.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_058.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_059.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_060.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_061.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_062.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_063.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_064.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_065.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_066.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_067.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_068.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_069.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_070.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_071.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_072.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_073.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_074.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_075.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_076.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_077.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_078.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_079.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_080.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_081.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_082.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_083.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_084.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_085.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_086.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_087.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_088.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_089.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_090.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_091.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_092.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_093.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_094.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_095.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_096.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_097.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Birds/336x28-/file_098.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_000.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_001.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_002.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_003.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_004.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_005.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_006.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_007.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_008.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_009.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_010.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_011.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_012.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_013.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_014.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_015.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_016.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_017.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_018.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_019.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_020.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_021.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_022.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_023.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Birds/36-x136-/file_024.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_000.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_001.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_002.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_003.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_004.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_005.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_006.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_007.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_008.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_009.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_010.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_011.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_012.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_013.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_014.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_015.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_016.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_017.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_018.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_019.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_020.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_021.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_022.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_023.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_024.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_025.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_026.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_027.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_028.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_029.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_030.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_031.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_032.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_033.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_034.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_035.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_036.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_037.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_038.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_039.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_040.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_041.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_042.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_043.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_044.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_045.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_046.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_047.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_048.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_049.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_050.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_051.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_052.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_053.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_054.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_055.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_056.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_057.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_058.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_059.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_060.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_061.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_062.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_063.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_064.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_065.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_066.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_067.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_068.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_069.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Birds/6--x5--/file_070.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Birds/random/file_000.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Birds/random/file_001.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Birds/random/file_002.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Birds/random/file_003.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Birds/random/file_004.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Birds/random/file_005.jpg"}]');
;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/birds-channel.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global  */





// Channel containing hard coded birds loaded from disk.
// Subclass of Channel.
class BirdChannel extends channel {
  getLatestListings(callback) {
    for (const bird of birds_namespaceObject) {
      this.listings.push(channel.listingFactory(bird.width, bird.height, bird.url, 'This is a bird!', 'birdchannelswitchlabel'));
    }
    callback(this.listings);
  }
}
/* harmony default export */ const birds_channel = (BirdChannel);

;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/data/food.json
const food_namespaceObject = JSON.parse('[{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_000.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_001.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_002.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_003.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_004.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_005.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_006.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_007.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_008.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_009.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_010.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_011.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_012.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_013.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_014.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_015.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_016.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_017.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_018.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_019.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_020.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_021.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_022.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_023.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_024.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_025.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_026.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_027.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_028.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_029.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_030.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_031.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_032.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_033.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_034.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_035.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_036.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_037.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_038.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_039.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_040.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_041.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_042.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_043.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_044.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_045.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_046.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_047.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_048.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_049.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_050.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_051.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_052.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_053.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_054.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_055.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_056.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_057.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_058.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_059.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_060.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_061.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_062.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_063.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_064.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_065.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_066.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_067.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_068.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_069.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_070.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_071.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_072.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_073.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_074.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_075.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_076.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_077.jpg"},{"width":"180","height":" 680","url":"https://cdn.adblockcdn.com/pix/Food/18-x68-/file_078.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_000.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_001.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_002.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_003.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_004.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_005.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_006.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_007.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_008.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_009.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_010.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_011.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_012.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_013.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_014.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_015.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_016.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_017.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_018.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_019.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_020.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_021.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_022.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_023.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_024.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_025.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_026.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_027.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_028.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_029.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_030.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_031.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_032.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_033.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_034.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_035.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_036.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_037.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_038.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_039.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_040.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_041.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_042.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_043.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_044.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_045.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_046.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_047.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_048.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_049.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_050.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_051.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_052.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_053.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_054.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_055.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_056.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_057.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_058.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_059.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_060.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_061.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_062.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_063.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_064.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_065.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_066.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_067.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_068.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_069.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_070.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_071.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_072.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_073.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_074.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_075.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_076.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_077.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_078.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_079.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_080.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_081.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_082.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_083.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_084.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_085.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_086.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_087.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_088.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_089.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_090.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_091.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_092.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_093.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_094.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_095.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_096.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_097.jpg"},{"width":"2400","height":" 1256","url":"https://cdn.adblockcdn.com/pix/Food/24--x1256/file_098.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_000.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_001.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_002.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_003.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_004.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_005.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_006.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_007.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_008.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_009.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_010.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_011.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_012.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_013.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_014.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_015.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_016.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_017.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_018.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_019.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_020.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_021.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_022.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_023.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_024.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_025.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_026.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_027.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_028.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_029.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_030.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_031.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_032.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_033.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_034.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_035.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_036.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_037.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_038.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_039.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_040.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_041.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_042.jpg"},{"width":"300","height":" 250","url":"https://cdn.adblockcdn.com/pix/Food/3--x25-/file_043.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_000.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_001.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_002.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_003.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_004.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_005.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_006.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_007.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_008.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_009.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_010.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_011.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_012.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_013.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_014.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_015.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_016.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_017.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_018.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_019.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_020.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_021.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_022.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_023.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_024.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_025.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_026.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_027.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_028.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_029.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_030.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_031.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_032.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_033.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_034.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_035.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_036.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_037.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_038.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_039.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_040.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_041.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_042.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_043.jpg"},{"width":"336","height":" 280","url":"https://cdn.adblockcdn.com/pix/Food/336x28-/file_044.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_000.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_001.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_002.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_003.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_004.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_005.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_006.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_007.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_008.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_009.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_010.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_011.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_012.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_013.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_014.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_015.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_016.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_017.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_018.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_019.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_020.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_021.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_022.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_023.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_024.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_025.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_026.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_027.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_028.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_029.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_030.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_031.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_032.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_033.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_034.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_035.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_036.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_037.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_038.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_039.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_040.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_041.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_042.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_043.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_044.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_045.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_046.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_047.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_048.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_049.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_050.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_051.jpg"},{"width":"360","height":" 1360","url":"https://cdn.adblockcdn.com/pix/Food/36-x136-/file_052.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_000.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_001.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_002.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_003.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_004.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_005.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_006.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_007.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_008.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_009.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_010.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_011.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_012.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_013.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_014.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_015.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_016.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_017.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_018.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_019.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_020.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_021.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_022.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_023.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_024.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_025.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_026.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_027.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_028.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_029.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_030.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_031.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_032.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_033.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_034.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_035.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_036.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_037.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_038.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_039.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_040.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_041.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_042.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_043.jpg"},{"width":"600","height":" 500","url":"https://cdn.adblockcdn.com/pix/Food/6--x5--/file_044.jpg"},{"width":"1120","height":" 1344","url":"https://cdn.adblockcdn.com/pix/Food/random/112-x1344.jpg"},{"width":"1200","height":" 678","url":"https://cdn.adblockcdn.com/pix/Food/random/12--x678.jpg"},{"width":"320","height":" 1200","url":"https://cdn.adblockcdn.com/pix/Food/random/32-x12--.jpg"},{"width":"570","height":" 672","url":"https://cdn.adblockcdn.com/pix/Food/random/57-x672.jpg"},{"width":"600","height":" 1200","url":"https://cdn.adblockcdn.com/pix/Food/random/6--x12--.jpg"},{"width":"672 560","height":"https://cdn.adblockcdn.com/pix/Food/random/672x56-.jpg","url":""},{"width":"680","height":" 180","url":"https://cdn.adblockcdn.com/pix/Food/random/68-x18-.jpg"}]');
;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/food-channel.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global */





// Channel containing hard coded cats loaded from disk.
// Subclass of Channel.
class FoodChannel extends channel {
  getLatestListings(callback) {
    for (const food of food_namespaceObject) {
      this.listings.push(channel.listingFactory(food.width, food.height, food.url, 'This is food!', 'foodchannelswitchlabel'));
    }
    callback(this.listings);
  }
}
/* harmony default export */ const food_channel = (FoodChannel);

;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/data/goats.json
const goats_namespaceObject = JSON.parse('[{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Goats/18-x68-/file_000.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Goats/18-x68-/file_001.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Goats/18-x68-/file_002.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Goats/18-x68-/file_003.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Goats/18-x68-/file_004.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Goats/18-x68-/file_005.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Goats/18-x68-/file_006.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Goats/18-x68-/file_007.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Goats/18-x68-/file_008.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Goats/18-x68-/file_009.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_000.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_001.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_002.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_003.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_004.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_005.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_006.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_007.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_008.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_009.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_010.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_011.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_012.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_013.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_014.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_015.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_016.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_017.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_018.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_019.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_020.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_021.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_022.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_023.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Goats/24--x1256/file_024.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_000.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_001.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_002.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_003.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_004.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_005.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_006.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_007.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_008.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_009.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_010.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_011.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_012.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_013.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_014.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_015.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_016.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_017.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_018.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_019.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_020.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_021.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_022.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_023.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Goats/3--x25-/file_024.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_000.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_001.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_002.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_003.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_004.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_005.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_006.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_007.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_008.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_009.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_010.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_011.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_012.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_013.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_014.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_015.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_016.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_017.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_018.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_019.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_020.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_021.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_022.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_023.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Goats/336x28-/file_024.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Goats/36-x136-/file_000.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Goats/36-x136-/file_001.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Goats/36-x136-/file_002.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Goats/36-x136-/file_003.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Goats/36-x136-/file_004.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Goats/36-x136-/file_005.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Goats/36-x136-/file_006.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Goats/36-x136-/file_007.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Goats/36-x136-/file_008.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Goats/36-x136-/file_009.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_000.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_001.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_002.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_003.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_004.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_005.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_006.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_007.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_008.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_009.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_010.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_011.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_012.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_013.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_014.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_015.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_016.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_017.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_018.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_019.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_020.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_021.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Goats/6--x5--/file_022.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Goats/file_000.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Goats/file_001.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Goats/file_002.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Goats/file_003.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Goats/file_004.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Goats/file_005.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Goats/file_006.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Goats/file_007.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Goats/file_008.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Goats/file_009.jpg"}]');
;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/goat-channel.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global  */





// Channel containing hard coded cats loaded from disk.
// Subclass of Channel.
class GoatsChannel extends channel {
  getLatestListings(callback) {
    for (const goat of goats_namespaceObject) {
      this.listings.push(channel.listingFactory(goat.width, goat.height, goat.url, 'This is a goat!', 'goatchannelswitchlabel'));
    }
    callback(this.listings);
  }
}
/* harmony default export */ const goat_channel = (GoatsChannel);

;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/data/ocean.json
const ocean_namespaceObject = JSON.parse('[{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_000.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_001.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_002.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_003.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_004.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_005.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_006.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_007.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_008.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_009.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_010.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_011.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_012.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_013.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_014.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_015.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_016.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_017.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_018.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_019.jpg"},{"width":180,"height":680,"url":"https://cdn.adblockcdn.com/pix/Oceans/18-x68-/file_020.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_000.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_001.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_002.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_003.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_004.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_005.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_006.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_007.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_008.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_009.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_010.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_011.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_012.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_013.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_014.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_015.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_016.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_017.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_018.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_019.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_020.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_021.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_022.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_023.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_024.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_025.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_026.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_027.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_028.jpg"},{"width":2400,"height":1256,"url":"https://cdn.adblockcdn.com/pix/Oceans/24--x1256/file_029.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_000.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_001.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_002.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_003.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_004.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_005.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_006.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_007.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_008.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_009.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_010.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_011.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_012.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_013.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_014.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_015.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_016.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_017.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_018.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_019.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_020.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_021.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_022.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_023.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_024.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_025.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_026.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_027.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_028.jpg"},{"width":300,"height":250,"url":"https://cdn.adblockcdn.com/pix/Oceans/3--x25-/file_029.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_000.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_001.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_002.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_003.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_004.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_005.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_006.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_007.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_008.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_009.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_010.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_011.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_012.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_013.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_014.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_015.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_016.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_017.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_018.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_019.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_020.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_021.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_022.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_023.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_024.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_025.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_026.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_027.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_028.jpg"},{"width":336,"height":280,"url":"https://cdn.adblockcdn.com/pix/Oceans/336x28-/file_029.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_000.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_001.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_002.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_003.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_004.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_005.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_006.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_007.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_008.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_009.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_010.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_011.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_012.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_013.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_014.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_015.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_016.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_017.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_018.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_019.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_020.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_021.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_022.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_023.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_024.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_025.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_026.jpg"},{"width":360,"height":1360,"url":"https://cdn.adblockcdn.com/pix/Oceans/36-x136-/file_027.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_000.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_001.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_002.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_003.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_004.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_005.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_006.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_007.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_008.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_009.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_010.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_011.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_012.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_013.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_014.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_015.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_016.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_017.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_018.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_019.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_020.jpg"},{"width":600,"height":500,"url":"https://cdn.adblockcdn.com/pix/Oceans/6--x5--/file_021.jpg"},{"width":1200,"height":628,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_000.jpg"},{"width":600,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_001.jpg"},{"width":672,"height":560,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_002.jpg"},{"width":468,"height":60,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_003.jpg"},{"width":936,"height":120,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_004.jpg"},{"width":1200,"height":50,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_005.jpg"},{"width":2400,"height":100,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_006.jpg"},{"width":1090,"height":43,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_007.jpg"},{"width":2180,"height":86,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_008.jpg"},{"width":450,"height":62,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_009.jpg"},{"width":900,"height":124,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_010.jpg"},{"width":1440,"height":90,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_011.jpg"},{"width":2880,"height":180,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_012.jpg"},{"width":1456,"height":180,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_013.jpg"},{"width":728,"height":90,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_014.jpg"},{"width":340,"height":90,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_015.jpg"},{"width":680,"height":180,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_016.jpg"},{"width":320,"height":1200,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_017.jpg"},{"width":1120,"height":1344,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_018.jpg"},{"width":560,"height":672,"url":"https://cdn.adblockcdn.com/pix/Oceans/random/file_019.jpg"}]');
;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/ocean-channel.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global */





// Channel containing hard coded cats loaded from disk.
// Subclass of Channel.
class OceanChannel extends channel {
  getLatestListings(callback) {
    for (const ocean of ocean_namespaceObject) {
      this.listings.push(channel.listingFactory(ocean.width, ocean.height, ocean.url, 'This is a ocean!', 'oceanchannelswitchlabel'));
    }
    callback(this.listings);
  }
}
/* harmony default export */ const ocean_channel = (OceanChannel);

;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/unknown-channel.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global  */



// Empty Channel
// Subclass of Channel.
//
// Allows the Sync process to create an new named Channel
// when the sync process recieves a request with a unknown channel name
class UnknownChannel extends channel {
  // eslint-disable-next-line class-methods-use-this
  getLatestListings(callback) {
    callback([]);
  }
}
/* harmony default export */ const unknown_channel = (UnknownChannel);

// EXTERNAL MODULE: ./adblock-betafish/utilities/background/bg-functions.js
var bg_functions = __webpack_require__(2028);
;// CONCATENATED MODULE: ./adblock-betafish/picreplacement/channels.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global settings, getSettings, setSetting, ,
   browser, , , ext */

















const resourceTypes = new Map();
for (const type in contentTypes/* contentTypes */.Tr) {
  resourceTypes.set(type.toLowerCase(), contentTypes/* contentTypes */.Tr[type]);
}
resourceTypes.set('sub_frame', contentTypes/* contentTypes.SUBDOCUMENT */.Tr.SUBDOCUMENT);
resourceTypes.set('beacon', contentTypes/* contentTypes.PING */.Tr.PING);
resourceTypes.set('imageset', contentTypes/* contentTypes.IMAGE */.Tr.IMAGE);
resourceTypes.set('object_subrequest', contentTypes/* contentTypes.OBJECT */.Tr.OBJECT);
resourceTypes.set('main_frame', contentTypes/* contentTypes.DOCUMENT */.Tr.DOCUMENT);

const typeSelectors = new Map([
  [contentTypes/* contentTypes.IMAGE */.Tr.IMAGE, 'img,input'],
  [contentTypes/* contentTypes.MEDIA */.Tr.MEDIA, 'audio,video'],
  [contentTypes/* contentTypes.SUBDOCUMENT */.Tr.SUBDOCUMENT, 'frame,iframe,object,embed'],
  [contentTypes/* contentTypes.OBJECT */.Tr.OBJECT, 'object,embed'],
]);

const REPORTING_OPTIONS = {
  filterType: 'blocking',
  includeElementHiding: false,
};

const channelsKey = 'channels';

const subscription1 = subscriptionadapter/* default.getUrlFromId */.Z.getUrlFromId('antisocial');
const subscription2 = subscriptionadapter/* default.getUrlFromId */.Z.getUrlFromId('annoyances');

const channelObjects = {
  CustomChannel: custom_channel,
  CatsChannel: cat_channel,
  DogsChannel: dog_channel,
  LandscapesChannel: landscape_channel,
  BirdChannel: birds_channel,
  FoodChannel: food_channel,
  GoatsChannel: goat_channel,
  OceanChannel: ocean_channel,
  UnknownChannel: unknown_channel,
};

const channelsNotifier = new events/* EventEmitter */.v();

// Contains and provides access to all the photo channels.
class Channels {
  constructor(license) {
    this.license = license;
    this.channelGuide = undefined; // maps channel ids to channels and metadata
    this.loadFromStorage();
    this.initializeListeners();
  }

  // Inputs:
  //   name:string - a Channel class name.
  //   param:object - the single ctor parameter to the Channel class.
  //   enabled:bool - true if this channel is to be used for pictures.
  // Returns:
  //   id of newly created channel, or undefined if the channel already existed.
  add(data) {
    let Klass = channelObjects[data.name];
    if (!Klass) {
      Klass = channelObjects.UnknownChannel;
    }
    const dataParam = JSON.stringify(data.param);
    for (const id in this.channelGuide) {
      const c = this.channelGuide[id];
      if (c.name === data.name && JSON.stringify(c.param) === dataParam) {
        return undefined;
      }
    }
    const id = Math.floor(Math.random() * Date.now());
    const channel = new Klass(data.param);
    this.channelGuide[id] = {
      name: data.name,
      param: data.param,
      enabled: data.enabled,
      channel,
    };
    this.saveToStorage();
    channel.refresh();
    return id;
  }

  remove(channelId) {
    delete this.channelGuide[channelId];
    this.saveToStorage();
  }

  // Return read-only map from each channel ID to
  // { name, param, enabled }.
  getGuide() {
    const results = {};
    for (const id in this.channelGuide) {
      const c = this.channelGuide[id];
      results[id] = {
        name: c.name,
        param: c.param,
        enabled: c.enabled,
      };
    }

    return results;
  }

  // Return id for channel name
  getIdByName(name) {
    for (const id in this.channelGuide) {
      if (this.channelGuide[id].name === name) {
        return id;
      }
    }
    return undefined;
  }

  isCustomChannel(id) {
    return (this.getIdByName('CustomChannel') === id);
  }

  isCustomChannelEnabled() {
    return (this.channelGuide[this.getIdByName('CustomChannel')].enabled);
  }

  getListings(id) {
    return this.channelGuide[id].channel.getListings();
  }

  setEnabled(id, enabled) {
    const originalValue = this.channelGuide[id].enabled;
    this.channelGuide[id].enabled = enabled;
    this.saveToStorage();
    if (originalValue !== enabled) {
      channelsNotifier.emit('channels.changed', id, enabled, originalValue);
    }
  }

  refreshAllEnabled() {
    for (const id in this.channelGuide) {
      const data = this.channelGuide[id];
      if (data.enabled) {
        data.channel.refresh();
      }
    }
  }

  isAnyEnabled() {
    for (const id in this.channelGuide) {
      const channel = this.channelGuide[id];
      if (channel.enabled) {
        return true;
      }
    }
    return false;
  }

  disableAllChannels() {
    for (const id in this.channelGuide) {
      if (this.channelGuide[id].enabled) {
        this.channelGuide[id].enabled = false;
        channelsNotifier.emit('channels.changed', id, false, true);
      }
    }
  }

  // Returns a random Listing from all enabled channels or from channel
  // |channelId| if specified, trying to match the ratio of |width| and
  // |height| decently.  Returns undefined if there are no enabled channels.
  randomListing(opts) {
    if (!getSettings().picreplacement) {
      return undefined;
    }
    // if the element to be replace is 'fixed' in position, it may make for bad pic
    // replacement element.
    if (opts.position === 'fixed') {
      for (const sub of subscriptionadapter/* default.getSubscriptionsMinusText */.Z.getSubscriptionsMinusText()) {
        if (sub.url === subscription1 || sub.url === subscription2) {
          return undefined;
        }
      }
    }

    const heightLowRange = opts.height;
    const widthLowRange = opts.width;
    const heightHighRange = (opts.height * 1.25);
    const widthHighRange = (opts.width * 1.25);
    const typeMatchListings = [];
    const rangeLimitedListings = [];
    let targetRatio = Math.max(opts.width, opts.height) / Math.min(opts.width, opts.height);

    for (const id in this.channelGuide) {
      const data = this.channelGuide[id];
      if (opts.channelId === id || (data.enabled && !opts.channelId)) {
        data.channel.getListings().forEach((element) => {
          if (
            (opts.type === WIDE || opts.type === SKINNYWIDE)
            && (element.type !== SKINNYTALL)
            && (element.width <= widthHighRange)
            && (element.height >= heightLowRange)
            && (element.height <= heightHighRange)
          ) {
            rangeLimitedListings.push(element);
          } else if (
            (opts.type === TALL || opts.type === SKINNYTALL)
            && (element.type !== SKINNYWIDE)
            && (element.width >= widthLowRange)
            && (element.width <= widthHighRange)
            && (element.height <= heightHighRange)
          ) {
            rangeLimitedListings.push(element);
          } else if (
            (opts.type !== WIDE)
            && (opts.type !== TALL)
            && (opts.type !== SKINNYTALL)
            && (opts.type !== SKINNYWIDE)
            && (element.width >= widthLowRange)
            && (element.width <= widthHighRange)
            && (element.height >= heightLowRange)
            && (element.height <= heightHighRange)
          ) {
            rangeLimitedListings.push(element);
          }
          if (
            opts.type === element.type
            && element.width >= widthLowRange
            && element.height >= heightLowRange
          ) {
            typeMatchListings.push(element);
          }
        });
      }
    }
    let exactTypeMatchListings = [];
    if (rangeLimitedListings.length > 0) {
      const randomIndex = Math.floor(Math.random() * rangeLimitedListings.length);
      const theListing = Object.assign({}, rangeLimitedListings[randomIndex]);
      theListing.listingHeight = theListing.height;
      theListing.listingWidth = theListing.width;
      if (opts.height !== theListing.height && opts.width !== theListing.width) {
        theListing.height = (theListing.height * opts.width) / theListing.width;
        theListing.width = opts.width;
      }
      return theListing;
    }
    let bestMatchRatio = 0;
    targetRatio = Math.max(opts.width, opts.height) / Math.min(opts.width, opts.height);
    typeMatchListings.forEach((listing) => {
      if (Math.abs(listing.ratio - targetRatio) < Math.abs(bestMatchRatio - targetRatio)) {
        exactTypeMatchListings = []; // remove previous matches
        exactTypeMatchListings.push(listing);
        bestMatchRatio = listing.ratio;
      } else if (listing.ratio === bestMatchRatio) {
        exactTypeMatchListings.push(listing);
      }
    });
    if (exactTypeMatchListings.length > 0) {
      const randomIndex = Math.floor(Math.random() * exactTypeMatchListings.length);
      const theListing = Object.assign({}, exactTypeMatchListings[randomIndex]);
      theListing.listingHeight = theListing.height;
      theListing.listingWidth = theListing.width;
      return theListing;
    }

    return undefined;
  }

  // adds any new or missing channels (in a disabled state) to the users channel guide
  addNewChannels() {
    const channelNames = ['DogsChannel', 'CatsChannel', 'LandscapesChannel', 'OceanChannel', 'GoatsChannel', 'BirdChannel', 'FoodChannel', 'CustomChannel'];
    for (const name of channelNames) {
      if (!this.getIdByName(name)) {
        this.add({
          name,
          param: undefined,
          enabled: false,
        });
      }
    }
  }

  loadFromStorage() {
    (0,bg_functions/* migrateData */.ww)(channelsKey, true).then(() => {
      (0,bg_functions/* chromeStorageGetHelper */.nX)(channelsKey).then((response) => {
        this.channelGuide = {};
        const savedData = response || [];
        for (let i = 0; i < savedData.length; i++) {
          this.add(savedData[i]);
        }
        this.addNewChannels();
      });
    });
  }

  saveToStorage() {
    const toStore = [];
    const guide = this.getGuide();
    for (const id in guide) {
      toStore.push(guide[id]);
    }
    (0,bg_functions/* chromeStorageSetHelper */.rJ)(channelsKey, toStore);
  }

  static getContentType(details) {
    return resourceTypes.get(details.type) || contentTypes/* contentTypes.OTHER */.Tr.OTHER;
  }

  static getFrameId(details) {
    return details.type === 'sub_frame' ? details.parentFrameId
      : details.frameId;
  }

  // Ignore EasyPrivacy rules, since they can cause issue with odd image swaps
  static async shouldUseFilter(filter) {
    if (!filter) {
      return false;
    }
    const subscriptions = await ewe_api.subscriptions.getForFilter(filter);
    const isEasyPrivacy = subscriptions.filter(subscription => subscription.title === 'EasyPrivacy');
    return (isEasyPrivacy && isEasyPrivacy.length === 0);
  }

  async filterListener({ request, filter }) {
    if (getSettings().picreplacement && this.license.isActiveLicense()) {
      const shouldUseFilter = await Channels.shouldUseFilter(filter);
      if (!shouldUseFilter) {
        return;
      }
      if (request
          && request.tabId
          && filter
          && filter.type === 'elemhide'
          && filter.selector && filter.enabled) {
        const msgDetail = { hidingSelector: filter.selector, command: 'addSelector' };
        browser.tabs.sendMessage(request.tabId, msgDetail, { frameId: request.frameId });
      } else if (request
        && request.tabId
        && filter
        && filter.type === 'blocking'
        && filter.enabled) {
        const selector = typeSelectors.get(Channels.getContentType(request));
        const frameId = Channels.getFrameId(request);
        const msg = { selector, command: 'addBlockingSelector', url: request.url };
        browser.tabs.sendMessage(request.tabId, msg, { frameId });
      }
    } else if (!getSettings().picreplacement) {
      ewe_api.reporting.onBlockableItem.removeListener(this.filterListener, REPORTING_OPTIONS);
    }
  }


  initializeListeners() {
    this.license.ready().then(() => {
      settings.onload().then(() => {
        if (getSettings().picreplacement && this.license.isActiveLicense()) {
          ewe_api.reporting.onBlockableItem.removeListener(this.filterListener, REPORTING_OPTIONS);
          ewe_api.reporting.onBlockableItem.addListener(
            this.filterListener.bind(this), REPORTING_OPTIONS,
          );
        }
      });
    });
  }
}


/***/ }),

/***/ 1177:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Cz": () => (/* binding */ License),
/* harmony export */   "ZW": () => (/* binding */ channels),
/* harmony export */   "lg": () => (/* binding */ replacedCounts)
/* harmony export */ });
/* harmony import */ var _vendor_adblockplusui_adblockpluschrome_lib_events__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(2901);
/* harmony import */ var _vendor_adblockplusui_adblockpluschrome_lib_storage_tab_session__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1627);
/* harmony import */ var _telemetry_background__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(158);
/* harmony import */ var _channels__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1053);
/* harmony import */ var _prefs_settings__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2630);
/* harmony import */ var _alias_icon__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1021);
/* harmony import */ var _alias_subscriptionInit__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(8910);
/* harmony import */ var _servermessages__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(1546);
/* harmony import */ var _subscriptionadapter__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(934);
/* harmony import */ var _fetch_util__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(2379);
/* harmony import */ var _utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(2028);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global ext, browser, translate, openTab,
   emitPageBroadcast, isTrustedSenderDomain */


// Yes, you could hack my code to not check the license.  But please don't.
// Paying for this extension supports the work on AdBlock.  Thanks very much.














const licenseNotifier = new _vendor_adblockplusui_adblockpluschrome_lib_events__WEBPACK_IMPORTED_MODULE_9__/* .EventEmitter */ .v();

const License = (function getLicense() {
  const isProd = true;
  const licenseStorageKey = 'license';
  const installTimestampStorageKey = 'install_timestamp';
  const userClosedSyncCTAKey = 'user_closed_sync_cta';
  const userSawSyncCTAKey = 'user_saw_sync_cta';
  const pageReloadedOnSettingChangeKey = 'page_reloaded_on_user_settings_change';
  const licenseAlarmName = 'licenseAlarm';
  const sevenDayAlarmName = 'sevenDayLicenseAlarm';

  let theLicense;
  const fiveMinutes = 300000;
  const initialized = false;
  let ajaxRetryCount = 0;
  let readyComplete;
  const licensePromise = new Promise(((resolve) => {
    readyComplete = resolve;
  }));
  const themesForCTA = [
    'solarized_theme', 'solarized_light_theme', 'watermelon_theme', 'sunshine_theme', 'ocean_theme',
  ];
  let currentThemeIndex = 0;
  const mabConfig = {
    prod: {
      licenseURL: 'https://myadblock-licensing.firebaseapp.com/license/',
      syncURL: 'https://myadblock.sync.getadblock.com/v1/sync',
      subscribeKey: 'sub-c-9eccffb2-8c6a-11e9-97ab-aa54ad4b08ec',
      payURL: 'https://getadblock.com/premium/enrollment/',
      subscriptionURL: 'https://getadblock.com/premium/manage-subscription/',
      bypassAuthorizedKeys: [
        // Production keys
        `MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAsCtBp9/0qCM5lp0lJVSx
      IAGgWZsX50xeJfBq6OkfsI+305Yj0igVfyVASOaC1fc2JRHD/uAOKk47SiPcBkiz
      mPHUt9ziOtAEkW7GrU6gaVOSwp26vUbSuvg9ouut5U2m8ULOyzp+WyU8nCzTPV5o
      AvCta04bK9or4UnyTRKyqADlNwz7WnH+0QiHYbgtfE/E3rowEoMEAC44C7OiawCm
      rnBXAkyBJnh1oEfUVI4LurxVl/zLo8MWfzErkaJy1FpsFR3F3L9ymKXpmxbhlDdX
      0rxjwnRD/2sCWW3SJOU26gfFgu/NI6LGxcWdPrucdkoOOOnNQjjDlhGYPTqqxugH
      /I5r+tAeUrrwKjmFcpMdxX7dfw1LoBoZCZnShZKlGKDqXf985Dc+3StbGWcxwNn9
      l9/Ho6YFA7fKpBKEED2V+SrDb4RCkScvOOiMOI1v5bwsLinUd/2yxRDrO25uwU7h
      r4LqmOguqjjLGF17d2WvG5D+LIQwgusxQd9Jk/n9PRdwtVGJhSDsDc8el2nKIqk9
      ofk3YJzAIbS9iHQ2LuHubuhzYjkxRLcdSbt1oONHCSHeecZn/OXwYeTvU7Po1KPW
      emi3XUpyjylUe9ONlw50lynwRw117bNHQDDHwKPoVW1cjoAtRsCnviFHPWTPjQKe
      A2LS9qa7eNdIonehrzG20cECAwEAAQ==`,
      ],
    },
    dev: {
      licenseURL: 'https://dev.myadblock.licensing.getadblock.com/license/',
      syncURL: 'https://dev.myadblock.sync.getadblock.com/v1/sync',
      subscribeKey: 'sub-c-9e0a7270-83e7-11e9-99de-d6d3b84c4a25',
      payURL: 'https://getadblock.com/premium/enrollment/?testmode=true',
      subscriptionURL: 'https://dev.getadblock.com/premium/manage-subscription/',
      bypassAuthorizedKeys: [
        // Development keys
        `MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAlTA+1kMAzbuPzMv/FV5B
      BcnqJRb7BTtCTE3IKox2Jd6d5kgI4JUIR9Hrsh+BPU8DACOv5dmcTIiy8Ci5Ptlu
      99t09oOPfZQLTyBEL4wFrTgbJPftURKugs8fkU9ttR/FyCCtSzhFlGNrcQvTTUvr
      NLBpBGuIpCkz/k8hux+IqDxaStVlJaJnyfcLl4kD+ogWkjmzG7Ba8btfPlVEkGvh
      xgrlVafn5w94hIhF9XzByxDxFk9KE4+Bs317HmYjYVoH3av61WMqZY5NFHoucuZz
      r4vhwt3b7yFIQ3T/eqiysUUX5OrqBVK9aQos8mCDKjGp2hWYnP1Oi1BzfPKVyTju
      IZAtZdrIeazj5NDcH+dwRmYTfB0r/35Dd7SIUrNX1uIRHcKWvLFUtpsRW+/d1XHG
      ruWBaPExutIgcIIpSCHm1cHVYpgEzu8Vs5VyOw+AfqTL5kWNAchx1VeWD91r4cVh
      ZPZQbN/TfxHyxisYLRMD4pKfjV8hlsUvmuy+Bg49Ds+rpGVEvnDdijWIbVsSD9eN
      5IO768819feXbR56PPxQtMs/JaE77Uoauuj7Lw9vGx/27V24TCWNTtbnwRkBCxJz
      m7YeUksuKYg7SQp4SMzkwhGxRRu9xlF/yKnDVXF5/J483akIuhuv0TiJI51mYvrD
      uc6lr1LW6QmZf6Vv2+ur7hcCAwEAAQ==`,
        // Testing keys
        `MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAqpV+M8A3hfi7JMut3Orr
      Sa6YEQutZ6F/FiaAmWPAlrG4IFA88HvqxRqbPz1niCWou7FqgsJ+v5+hhyrMFqM2
      JBBdaLHiDN1KNm7Ydx1j7NJJ+o/O22SN6kIU6k+VLg2B+Gj37s1qi8tIGWnrP+Ip
      jPMHDYSxLbQlIH/6CIiKVyMr7zaTej9rigGr33tqxM+RZtwo8eudEVcN3+DsUZ4j
      /jYx/hTvPze2r5xhB3faErhPSFLjZ9UIv0P9tPwO9m7PRQx9mrnh5QnS8NfEY2FY
      oFd+HiTsJS1QJi/ez9+5n1WCOTutc2lbxboCV3eJegBDObPDW1EhuVXOzGTEs5Sc
      Mb8NgE4iEoL9awIiGce+jS4Yj2olJAwGxv0rDJTycnDxx0SDvjTqEYFhuXk55vGd
      Dq7ClDvv8yiQ4CfCjZiLr9YbzO/kp2zf55wL+0SGmLKW6BLcUgGTciSHYMhPLv/N
      C5HtFlag5H7KGyimp/Q8eC9RnTskchyr1ShWyOoRMTsd45Htba5gfYjUWQxqhKiC
      SuFCooSX8/6zMynNOvD3A1p1+NhsKYzB+hnBeaFc/YKRyXVx1UJc8EZDc6jOYDoz
      1EB3nXfMQjtqmpqS5IbhzUxKDRC+kvRo7wa0TexhFMs6Vlg3+dAeemQujyljtJ7r
      PVMNXy0NnTuRNSK6V+Oz2JUCAwEAAQ==`,
        // Production keys
        `MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAsCtBp9/0qCM5lp0lJVSx
      IAGgWZsX50xeJfBq6OkfsI+305Yj0igVfyVASOaC1fc2JRHD/uAOKk47SiPcBkiz
      mPHUt9ziOtAEkW7GrU6gaVOSwp26vUbSuvg9ouut5U2m8ULOyzp+WyU8nCzTPV5o
      AvCta04bK9or4UnyTRKyqADlNwz7WnH+0QiHYbgtfE/E3rowEoMEAC44C7OiawCm
      rnBXAkyBJnh1oEfUVI4LurxVl/zLo8MWfzErkaJy1FpsFR3F3L9ymKXpmxbhlDdX
      0rxjwnRD/2sCWW3SJOU26gfFgu/NI6LGxcWdPrucdkoOOOnNQjjDlhGYPTqqxugH
      /I5r+tAeUrrwKjmFcpMdxX7dfw1LoBoZCZnShZKlGKDqXf985Dc+3StbGWcxwNn9
      l9/Ho6YFA7fKpBKEED2V+SrDb4RCkScvOOiMOI1v5bwsLinUd/2yxRDrO25uwU7h
      r4LqmOguqjjLGF17d2WvG5D+LIQwgusxQd9Jk/n9PRdwtVGJhSDsDc8el2nKIqk9
      ofk3YJzAIbS9iHQ2LuHubuhzYjkxRLcdSbt1oONHCSHeecZn/OXwYeTvU7Po1KPW
      emi3XUpyjylUe9ONlw50lynwRw117bNHQDDHwKPoVW1cjoAtRsCnviFHPWTPjQKe
      A2LS9qa7eNdIonehrzG20cECAwEAAQ==`,
      ],
    },
  };
  (async () => {
    const userID = await _telemetry_background__WEBPACK_IMPORTED_MODULE_1__/* .TELEMETRY.untilLoaded */ .C.untilLoaded();
    mabConfig.prod.payURL = `${mabConfig.prod.payURL}?u=${userID}`;
    mabConfig.dev.payURL = `${mabConfig.dev.payURL}&u=${userID}`;
  })();
  const MAB_CONFIG = isProd ? mabConfig.prod : mabConfig.dev;

  const sevenDayAlarmIdleListener = function (newState) {
    if (newState === 'active') {
      License.checkSevenDayAlarm();
    }
  };

  const removeSevenDayAlarmStateListener = function () {
    browser.idle.onStateChanged.removeListener(sevenDayAlarmIdleListener);
  };

  const addSevenDayAlarmStateListener = function () {
    removeSevenDayAlarmStateListener();
    browser.idle.onStateChanged.addListener(sevenDayAlarmIdleListener);
  };

  const cleanUpSevenDayAlarm = function () {
    removeSevenDayAlarmStateListener();
    browser.storage.local.remove(License.sevenDayAlarmName);
    browser.alarms.clear(License.sevenDayAlarmName);
  };

  const processSevenDayAlarm = function () {
    cleanUpSevenDayAlarm();
    (0,_alias_icon__WEBPACK_IMPORTED_MODULE_4__/* .showIconBadgeCTA */ .QO)(true, _alias_icon__WEBPACK_IMPORTED_MODULE_4__/* .NEW_BADGE_REASONS.SEVEN_DAY */ .ec.SEVEN_DAY);
  };

  browser.alarms.onAlarm.addListener((alarm) => {
    if (alarm && alarm.name === licenseAlarmName) {
      // At this point, no alarms exists, so
      // create an temporary alarm to avoid race condition issues
      browser.alarms.create(licenseAlarmName, { delayInMinutes: (24 * 60) });
      License.ready().then(() => {
        License.updatePeriodically();
      });
    }
    if (alarm && alarm.name === sevenDayAlarmName) {
      processSevenDayAlarm();
    }
  });

  // Check if the computer was woken up, and if there was a pending alarm
  // that should fired during the sleep, then
  // remove it, and fire the update ourselves.
  // see - https://bugs.chromium.org/p/chromium/issues/detail?id=471524
  browser.idle.onStateChanged.addListener((newState) => {
    if (newState === 'active') {
      browser.alarms.get(licenseAlarmName).then((alarm) => {
        if (alarm && Date.now() > alarm.scheduledTime) {
          browser.alarms.clear(licenseAlarmName).then(() => {
            License.updatePeriodically();
          });
        } else if (alarm) {
          // if the alarm should fire in the future,
          // re-add the license so it fires at the correct time
          const originalTime = alarm.scheduledTime;
          browser.alarms.clear(licenseAlarmName).then((wasCleared) => {
            if (wasCleared) {
              browser.alarms.create(licenseAlarmName, { when: originalTime });
            }
          });
        } else {
          License.updatePeriodically();
        }
      });
    }
  });

  // check the 7 alarm when the browser starts
  // or is woken up
  const checkSevenDayAlarm = function () {
    browser.alarms.get(License.sevenDayAlarmName).then((alarm) => {
      if (alarm && Date.now() > alarm.scheduledTime) {
        browser.alarms.clear(License.sevenDayAlarmName).then(() => {
          (0,_alias_icon__WEBPACK_IMPORTED_MODULE_4__/* .showIconBadgeCTA */ .QO)(true, _alias_icon__WEBPACK_IMPORTED_MODULE_4__/* .NEW_BADGE_REASONS.SEVEN_DAY */ .ec.SEVEN_DAY);
          removeSevenDayAlarmStateListener();
          browser.storage.local.remove(License.sevenDayAlarmName);
        });
      } else if (alarm) {
        // if the alarm should fire in the future,
        // re-add the license so it fires at the correct time
        const originalTime = alarm.scheduledTime;
        browser.alarms.clear(License.sevenDayAlarmName).then((wasCleared) => {
          if (wasCleared) {
            browser.alarms.create(License.sevenDayAlarmName, { when: originalTime });
            browser.storage.local.set({ [License.sevenDayAlarmName]: true });
            License.addSevenDayAlarmStateListener();
          }
        });
      } else {
        // since there's no alarm, we may need to show the 'new' text,
        // check if the temporary seven day alarm indicator is set, and
        // if the install date is 7 days or more than now
        browser.storage.local.get(License.sevenDayAlarmName).then((data) => {
          if (data && data[License.sevenDayAlarmName]) {
            browser.storage.local.get('blockage_stats').then((response) => {
              const { blockage_stats } = response;
              if (blockage_stats && blockage_stats.start) {
                const installDate = new Date(blockage_stats.start);
                const now = new Date();
                const oneDay = 24 * 60 * 60 * 1000; // hours*minutes*seconds*milliseconds
                const diffDays = Math.round((now - installDate) / oneDay);
                if (diffDays >= 7) {
                  (0,_alias_icon__WEBPACK_IMPORTED_MODULE_4__/* .showIconBadgeCTA */ .QO)(true, _alias_icon__WEBPACK_IMPORTED_MODULE_4__/* .NEW_BADGE_REASONS.SEVEN_DAY */ .ec.SEVEN_DAY);
                  removeSevenDayAlarmStateListener();
                  browser.storage.local.remove(License.sevenDayAlarmName);
                }
              }
            });
          }
        });
        removeSevenDayAlarmStateListener();
      }
    });
  };
  addSevenDayAlarmStateListener();

  /**
   * Provides payload to verify authenticity of Premium license data
   *
   * @returns {string} Encoded signed Premium license data
   */
  const getBypassPayload = function () {
    if (!License.isActiveLicense()) {
      return null;
    }
    return `${License.get().encodedData}.${License.get().signature}`;
  };

  // Load the license from persistent storage
  // Should only be called during startup / initialization
  const loadFromStorage = function (callback) {
    browser.storage.local.get(licenseStorageKey).then((response) => {
      theLicense = response[licenseStorageKey] || {};
      if (typeof callback === 'function') {
        callback();
      }
    });
  };
  const checkForManagedSettings = function () {
    return new Promise(((resolve) => {
      if ('managed' in browser.storage) {
        browser.storage.managed.get(null).then((items) => {
          for (const key in items) {
            if (key === 'suppress_premium_cta') {
              theLicense = License.get();
              theLicense[key] = items[key];
              License.set(theLicense);
            }
          }
          resolve();
        },
        // Opera and FF doesn't support browser.storage.managed, but instead of simply
        // removing the API, it gives an asynchronous error which we ignore here.
        () => {
          resolve();
        });
      } else {
        resolve();
      }
    }));
  };

  // Clean up / remove old, unused data in localStorage
  function cleanUpLocalStorage() {
    (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_8__/* .storageSet */ .eV)(licenseStorageKey);
  }

  return {
    licenseStorageKey,
    userClosedSyncCTAKey,
    userSawSyncCTAKey,
    themesForCTA,
    pageReloadedOnSettingChangeKey,
    initialized,
    licenseAlarmName,
    sevenDayAlarmName,
    checkSevenDayAlarm,
    addSevenDayAlarmStateListener,
    removeSevenDayAlarmStateListener,
    cleanUpSevenDayAlarm,
    licenseTimer: undefined, // the license update timer token
    licenseNotifier,
    MAB_CONFIG,
    isProd,
    getBypassPayload,
    enrollUser(enrollReason) {
      loadFromStorage(() => {
        // only enroll users if they were not previously enrolled
        if (typeof theLicense.myadblock_enrollment === 'undefined') {
          theLicense.myadblock_enrollment = true;
          License.set(theLicense);
          if (enrollReason === 'update') {
            (0,_alias_icon__WEBPACK_IMPORTED_MODULE_4__/* .showIconBadgeCTA */ .QO)(true, _alias_icon__WEBPACK_IMPORTED_MODULE_4__/* .NEW_BADGE_REASONS.UPDATE */ .ec.UPDATE);
          }
        }
      });
    },
    get() {
      return theLicense;
    },
    set(newLicense) {
      if (newLicense) {
        theLicense = newLicense;
        browser.storage.local.set({ license: theLicense });
      }
    },
    /**
     * Changes configuration to use development licensing server
     */
    setDevConfig() {
      License.MAB_CONFIG = mabConfig.dev;
    },
    initialize(callback) {
      loadFromStorage(() => {
        checkForManagedSettings().then(() => {
          if (typeof callback === 'function') {
            callback();
          }
          cleanUpLocalStorage();
          readyComplete();
        });
      });
    },
    getCurrentPopupMenuThemeCTA() {
      const theme = License.themesForCTA[currentThemeIndex];
      const lastThemeIndex = License.themesForCTA.length - 1;
      currentThemeIndex = lastThemeIndex === currentThemeIndex ? 0 : currentThemeIndex += 1;
      return theme || '';
    },
    // Get the latest license data from the server, and talk to the user if needed.
    async update() {
      const userID = await _telemetry_background__WEBPACK_IMPORTED_MODULE_1__/* .TELEMETRY.untilLoaded */ .C.untilLoaded();
      licenseNotifier.emit('license.updating');
      const postDataObj = {};
      postDataObj.u = userID;
      postDataObj.cmd = 'license_check';
      const licsenseStatusBefore = License.get().status;
      // license version
      postDataObj.v = '1';
      (0,_fetch_util__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .Z)(License.MAB_CONFIG.licenseURL, postDataObj).then(async (response) => {
        if (response.ok) {
          const responseObj = await response.json();
          ajaxRetryCount = 0;
          const updatedLicense = responseObj;
          licenseNotifier.emit('license.updated', updatedLicense);
          if (!updatedLicense) {
            return;
          }
          // merge the updated license
          theLicense = { ...theLicense, ...updatedLicense };
          theLicense.licenseId = theLicense.code;
          License.set(theLicense);
          // now check to see if we need to do anything because of a status change
          if (
            licsenseStatusBefore === 'active'
            && updatedLicense.status
            && updatedLicense.status === 'expired'
          ) {
            License.processExpiredLicense();
            _servermessages__WEBPACK_IMPORTED_MODULE_6__/* ["default"].recordGeneralMessage */ .Z.recordGeneralMessage('trial_license_expired');
          }
        } else {
          (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_8__/* .log */ .cM)('license server error response', response.status, ajaxRetryCount);
          licenseNotifier.emit('license.updated.error', ajaxRetryCount);
          ajaxRetryCount += 1;
          if (ajaxRetryCount > 3) {
            (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_8__/* .log */ .cM)('Retry Count exceeded, giving up', ajaxRetryCount);
            return;
          }
          const oneMinute = 1 * 60 * 1000;
          setTimeout(() => {
            License.updatePeriodically(`error${ajaxRetryCount}`);
          }, oneMinute);
        }
      })
        .catch((error) => {
          (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_8__/* .log */ .cM)('license server returned error: ', error);
        });
    },
    processExpiredLicense() {
      theLicense = License.get();
      theLicense.myadblock_enrollment = true;
      License.set(theLicense);
      (0,_prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .setSetting */ .Lt)('picreplacement', false);
      licenseNotifier.emit('license.expired');
      if ((0,_prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .getSettings */ .Gw)().sync_settings) {
        // We have to import the "sync-service" module on demand,
        // as the "sync-service" module in turn requires this module.
        /* eslint-disable import/no-cycle */
        (Promise.resolve(/* import() */).then(__webpack_require__.bind(__webpack_require__, 8409))).disableSync();
      }
      (0,_prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .setSetting */ .Lt)('color_themes', { popup_menu: 'default_theme', options_page: 'default_theme' });
      _subscriptionadapter__WEBPACK_IMPORTED_MODULE_7__/* ["default"].unsubscribe */ .Z.unsubscribe({ adblockId: 'distraction-control-push' });
      _subscriptionadapter__WEBPACK_IMPORTED_MODULE_7__/* ["default"].unsubscribe */ .Z.unsubscribe({ adblockId: 'distraction-control-newsletter' });
      _subscriptionadapter__WEBPACK_IMPORTED_MODULE_7__/* ["default"].unsubscribe */ .Z.unsubscribe({ adblockId: 'distraction-control-survey' });
      _subscriptionadapter__WEBPACK_IMPORTED_MODULE_7__/* ["default"].unsubscribe */ .Z.unsubscribe({ adblockId: 'distraction-control-video' });
      browser.alarms.clear(licenseAlarmName);
    },
    ready() {
      return licensePromise;
    },
    updatePeriodically() {
      if (!License.isActiveLicense()) {
        return;
      }
      License.update();
      browser.storage.local.get(installTimestampStorageKey).then((response) => {
        let installTimestamp = response[installTimestampStorageKey];
        const originalInstallTimestamp = installTimestamp || Date.now();
        // If the installation timestamp is missing from storage,
        // save an updated version
        if (!(response[installTimestampStorageKey])) {
          installTimestamp = Date.now();
          browser.storage.local.set({ install_timestamp: installTimestamp });
        }
        const originalInstallDate = new Date(originalInstallTimestamp);
        let nextLicenseCheck = new Date();
        if (originalInstallDate.getHours() <= nextLicenseCheck.getHours()) {
          nextLicenseCheck.setDate(nextLicenseCheck.getDate() + 1);
        }
        nextLicenseCheck.setHours(originalInstallDate.getHours());
        nextLicenseCheck.setMinutes(originalInstallDate.getMinutes());
        // Add 5 minutes to the 'minutes' to make sure we've allowed enought time for '1' day
        nextLicenseCheck = new Date(nextLicenseCheck.getTime() + fiveMinutes);
        browser.alarms.create(licenseAlarmName, { when: nextLicenseCheck.getTime() });
      });
    },
    async getLicenseInstallationDate() {
      const response = await browser.storage.local.get(installTimestampStorageKey);
      const originalInstallTimestamp = response[installTimestampStorageKey];
      if (originalInstallTimestamp) {
        return (new Date(originalInstallTimestamp));
      }
      return undefined;
    },
    // activate the current license and configure the extension in licensed mode.
    // Call with an optional delay parameter (in milliseconds) if the first license
    // update should be delayed by a custom delay (default is 0 minutes).
    activate(delayMs) {
      let delay = delayMs;
      const currentLicense = License.get() || {};
      currentLicense.status = 'active';
      License.set(currentLicense);
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_8__/* .reloadOptionsPageTabs */ .qo)();
      if (typeof delay !== 'number') {
        delay = 0; // 0 minutes
      }
      if (!this.licenseTimer) {
        this.licenseTimer = setTimeout(() => {
          License.updatePeriodically();
        }, delay);
      }
      (0,_prefs_settings__WEBPACK_IMPORTED_MODULE_3__/* .setSetting */ .Lt)('picreplacement', false);
    },
    getFormattedActiveSinceDate() {
      if (
        !License
        || !License.isActiveLicense()
        || !License.get()
        || !License.get().createdAtUTC
        || !Number.isInteger(License.get().createdAtUTC)
      ) {
        return null;
      }
      const dateFormat = { year: 'numeric', month: 'long' };
      let formattedDate = null;
      try {
        const createdAtUTC = parseInt(License.get().createdAtUTC, 10);
        formattedDate = new Date(createdAtUTC).toLocaleDateString(undefined, dateFormat);
      } catch (e) {
        return null;
      }
      return formattedDate;
    },
    isActiveLicense() {
      return License && License.get() && License.get().status === 'active';
    },
    isLicenseCodeValid() {
      return License && License.get().code && typeof License.get().code === 'string';
    },
    isMyAdBlockEnrolled() {
      return License && License.get() && License.get().myadblock_enrollment === true;
    },
    shouldShowMyAdBlockEnrollment() {
      return License.isMyAdBlockEnrolled()
        && !License.isActiveLicense()
        && License.shouldShowPremiumCTA();
    },
    shouldShowPremiumDcCTA() {
      return (License && License.isActiveLicense() && License.get().suppress_premium_cta !== true);
    },
    shouldShowPremiumCTA() {
      return !(License && License.get().suppress_premium_cta === true);
    },
    shouldShowBlacklistCTA(newValue) {
      if (!License.shouldShowPremiumCTA()) {
        return false;
      }
      const currentLicense = License.get() || {};
      if (typeof newValue === 'boolean') {
        currentLicense.showBlacklistCTA = newValue;
        License.set(currentLicense);
        return null;
      }

      if (typeof currentLicense.showBlacklistCTA === 'undefined') {
        currentLicense.showBlacklistCTA = true;
        License.set(currentLicense);
      }
      return License && License.get() && License.get().showBlacklistCTA === true;
    },
    shouldShowWhitelistCTA(newValue) {
      if (!License.shouldShowPremiumCTA()) {
        return false;
      }
      const currentLicense = License.get() || {};
      if (typeof newValue === 'boolean') {
        currentLicense.showWhitelistCTA = newValue;
        License.set(currentLicense);
        return null;
      }

      if (typeof currentLicense.showWhitelistCTA === 'undefined') {
        currentLicense.showWhitelistCTA = true;
        License.set(currentLicense);
      }
      return License && License.get() && License.get().showWhitelistCTA === true;
    },
    displayPopupMenuNewCTA() {
      const isNotActive = !License.isActiveLicense();
      const variant = License.get() ? License.get().var : undefined;
      return License && isNotActive && [3, 4].includes(variant) && License.shouldShowPremiumCTA();
    },
    // fetchLicenseAPI automates the common steps required to call the /license/api endpoint.
    // POST bodies will always automatically contain the command, license and userid so only
    // provide the missing fields in the body parameter. The ok callback handler receives the
    // data returned by the API and the fail handler receives any error information available.
    fetchLicenseAPI(command, requestBody, ok, requestFail) {
      const licenseCode = License.get().code;
      const userID = _telemetry_background__WEBPACK_IMPORTED_MODULE_1__/* .TELEMETRY.userId */ .C.userId;
      const body = requestBody;
      let fail = requestFail;
      body.cmd = command;
      body.userid = userID;
      if (licenseCode) {
        body.license = licenseCode;
      }
      const request = new Request('https://myadblock.licensing.getadblock.com/license/api/', {
        method: 'POST',
        body: JSON.stringify(body),
      });
      fetch(request)
        .then((response) => {
          if (response.ok) {
            return response.json();
          }
          fail(response.status);
          fail = null;
          return Promise.resolve({});
        })
        .then((data) => {
          ok(data);
        })
        .catch((err) => {
          fail(err);
        });
    },
  };
}());

const replacedPerPage = new _vendor_adblockplusui_adblockpluschrome_lib_storage_tab_session__WEBPACK_IMPORTED_MODULE_0__/* .TabSessionStorage */ .H('ab:premium:replacedPerPage');

// Records how many ads have been replaced by AdBlock.  This is used
// by the AdBlock to display statistics to the user.
const replacedCounts = (function getReplacedCount() {
  const adReplacedNotifier = new _vendor_adblockplusui_adblockpluschrome_lib_events__WEBPACK_IMPORTED_MODULE_9__/* .EventEmitter */ .v();
  const key = 'replaced_stats';
  (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_8__/* .migrateData */ .ww)(key, true).then(() => {
    (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_8__/* .chromeStorageGetHelper */ .nX)(key).then((data) => {
      let replacedCountData = data;
      if (!data) {
        replacedCountData = {};
      }
      if (replacedCountData.start === undefined) {
        replacedCountData.start = Date.now();
      }
      if (replacedCountData.total === undefined) {
        replacedCountData.total = 0;
      }
      replacedCountData.version = 1;
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_8__/* .chromeStorageSetHelper */ .rJ)(key, replacedCountData);
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_8__/* .storageSet */ .eV)(key);
    });
  });

  return {
    recordOneAdReplaced(tabId) {
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_8__/* .chromeStorageGetHelper */ .nX)(key).then((replacedCountData) => {
        const data = replacedCountData;
        data.total += 1;
        (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_8__/* .chromeStorageSetHelper */ .rJ)(key, data);
        browser.tabs.get(tabId).then(async (tab) => {
          let replaced = await replacedPerPage.get(tabId) || 0;
          await replacedPerPage.set(tabId, replaced += 1);
          adReplacedNotifier.emit('adReplaced', tabId, tab.url);
        });
      });
    },
    get() {
      return (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_8__/* .chromeStorageGetHelper */ .nX)(key);
    },
    async getTotalAdsReplaced(tabId) {
      if (tabId) {
        return replacedPerPage.get(tabId);
      }
      return this.get().then(data => data.total);
    },
    adReplacedNotifier,
  };
}());

// for use in the premium enrollment process
// de-coupled from the `License.ready().then` code below because the delay
// prevents the addListener from being fired in a timely fashion.
const onInstalledPromise = new Promise(((resolve) => {
  browser.runtime.onInstalled.addListener((details) => {
    resolve(details);
  });
}));

// the order of Promises below dictacts the order of the data in the detailsArray
Promise.all([onInstalledPromise, License.ready(), _alias_subscriptionInit__WEBPACK_IMPORTED_MODULE_5__/* .initialize */ .j]).then((detailsArray) => {
  // Enroll existing users in Premium
  if (detailsArray.length > 0 && detailsArray[0].reason) {
    License.enrollUser(detailsArray[0].reason);
    if (detailsArray[0].reason === 'install') {
      // create an alarm that will fire in ~ 7 days to show the "New" badge text
      browser.alarms.create(License.sevenDayAlarmName, { delayInMinutes: (60 * 24 * 7) });
      License.addSevenDayAlarmStateListener();
      browser.storage.local.set({ [License.sevenDayAlarmName]: true });
    }
  }
});

License.ready().then(() => {
  License.checkSevenDayAlarm();

  if (License.isActiveLicense()) {
    License.updatePeriodically();
  }
});

License.initialize(() => {
  if (!License.initialized) {
    License.initialized = true;
  }
});

// eslint-disable-next-line no-restricted-globals
Object.assign(self, {
  License,
  replacedCounts,
});

const channels = new _channels__WEBPACK_IMPORTED_MODULE_2__/* .Channels */ .E(License);


/***/ }),

/***/ 3032:
/***/ ((__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony import */ var _telemetry_background__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(158);
/* harmony import */ var _subscriptionadapter__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(934);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, log */




const sendDCReport = function (url, type, id) {
  if (!url || !type) {
    return;
  }
  const reportData = {
    url,
    type,
    platform: _telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY */ .C && `browser:${_telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.browser */ .C.browser}, browser version:${_telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.browserVersion */ .C.browserVersion}, OS:${_telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.os */ .C.os}, OS version:${_telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.osVersion */ .C.osVersion}`,
    locale: browser.i18n.getUILanguage(),
    version: browser.runtime.getManifest().version,
  };
  if (id) {
    const subs = _subscriptionadapter__WEBPACK_IMPORTED_MODULE_1__/* ["default"].getSubscriptionsMinusText */ .Z.getSubscriptionsMinusText();
    if (subs && subs[id]) {
      const lastUpdate = subs[id].lastDownload || 0;
      reportData.filterListLastUpdate = new Date(lastUpdate * 1000);
    }
  }
  const formData = new FormData();
  formData.append('bug_report', JSON.stringify(reportData));
  fetch('https://getadblock.com/freshdesk/bugReportDistractionControl.php', {
    body: formData,
    method: 'post',
  }).catch((error) => {
    log('freshdesk returned error: ', error);
  });
};

browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
  if (message.command !== 'sendDCReport' || !message.url || !message.type) {
    return;
  }
  sendDCReport(message.url, message.type, message.id);
  sendResponse({});
});


/***/ }),

/***/ 8409:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "default": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var _telemetry_background__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(158);
/* harmony import */ var _vendor_adblockplusui_adblockpluschrome_lib_events__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(2901);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3817);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _check__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1177);
/* harmony import */ var _channels__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1053);
/* harmony import */ var _subscriptionadapter__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(934);
/* harmony import */ var _prefs_settings__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2630);
/* harmony import */ var _servermessages__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(1546);
/* harmony import */ var _fetch_util__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(2379);
/* harmony import */ var _utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(2028);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, channels,
   getUserFilters, Prefs, abpPrefPropertyNames,
   adblockIsDomainPaused, PubNub, adblockIsPaused,
   pausedFilterText1, pausedFilterText2,
   isWhitelistFilter, getCustomFilterMetaData */

/** @module SyncService */




// check.js imports disableSync from here
// eslint-disable-next-line import/no-cycle








const SyncService = (function getSyncService() {
  let storedSyncDomainPauses = [];
  let syncCommitVersion = 0;
  let currentExtensionName = '';
  let pubnub;
  const syncSchemaVersion = 1;
  const syncCommitVersionKey = 'SyncCommitKey';
  const syncLogMessageKey = 'SyncLogMessageKey';
  const syncPreviousDataKey = 'SyncPreviousDataKey';
  const syncExtensionNameKey = 'SyncExtensionNameKey';
  const syncPendingPostDataKey = 'syncPendingPostDataKey';
  const syncNotifier = new _vendor_adblockplusui_adblockpluschrome_lib_events__WEBPACK_IMPORTED_MODULE_8__/* .EventEmitter */ .v();
  let lastPostStatusCode = 200;
  let pendingPostData = false;
  let lastGetStatusCode = 200;
  let lastGetErrorResponse = {};
  const debounceWaitTime = 3000; // time in ms before posting data
  // Below is a list of filter list ids that have been added since the
  // sync feature was added to AdBlock, therefore these filter lists should be sent
  // with an ID of 'url:...' instead of the id in the betafish-subscriptions.json file
  // any adds to the the betafish-subscriptions.json file should be added here as well.
  const sendFilterListByURL = ['nordic', 'annoyances',
    'fb_notifications', 'easylist_plus_romanian', 'idcac'];

  function setCommitVersion(newVersionNum) {
    syncCommitVersion = newVersionNum;
  }

  function getLastPostStatusCode() {
    return lastPostStatusCode;
  }

  function resetLastPostStatusCode() {
    lastPostStatusCode = 200;
  }

  function setLastPostStatusCode(newCode) {
    lastPostStatusCode = newCode;
  }

  function getLastGetStatusCode() {
    return lastGetStatusCode;
  }

  function resetLastGetStatusCode() {
    lastGetStatusCode = 200;
  }

  function setLastGetStatusCode(newCode) {
    lastGetStatusCode = newCode;
  }

  function getLastGetErrorResponse() {
    return lastGetErrorResponse;
  }

  function resetLastGetErrorResponse() {
    lastGetErrorResponse = {};
  }

  function setLastGetErrorResponse(newObject) {
    lastGetErrorResponse = newObject;
  }

  function resetAllErrors() {
    resetLastGetErrorResponse();
    resetLastGetStatusCode();
    resetLastPostStatusCode();
  }

  const getCurrentExtensionName = function () {
    return currentExtensionName;
  };

  const getSyncLog = function () {
    return new Promise((resolve) => {
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageGetHelper */ .nX)(syncLogMessageKey).then((logMsgs) => {
        const storedLog = JSON.parse(logMsgs || '[]');
        const theReturnObj = {};
        Object.assign(theReturnObj, storedLog);
        resolve(theReturnObj);
      });
    });
  };

  // TODO - when should we delete the log file???
  const deleteSyncLog = function () {
    (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageDeleteHelper */ .lE)(syncLogMessageKey);
  };

  const migrateSyncLog = function () {
    /* eslint-disable no-restricted-globals */
    if (typeof self.localStorage === 'undefined') {
      return;
    }
    let storedMsgs = localStorage.getItem(syncLogMessageKey);
    if (!storedMsgs) {
      return;
    }
    storedMsgs = JSON.parse(storedMsgs);
    while (storedMsgs.length > 500) { // only keep the last 500 log entries
      storedMsgs.shift();
    }
    (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageSetHelper */ .rJ)(syncLogMessageKey, JSON.stringify(storedMsgs), (error) => {
      if (!error) {
        localStorage.removeItem(syncLogMessageKey);
      }
    });
  };

  function debounced(delay, fn) {
    let timerId;
    return function debouncedAgain(...args) {
      if (timerId) {
        clearTimeout(timerId);
      }
      timerId = setTimeout(() => {
        fn(...args);
        timerId = null;
      }, delay);
    };
  }

  // return meta data about the extension installation
  const getExtensionInfo = function () {
    return {
      flavor: _telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.flavor */ .C.flavor,
      browserVersion: _telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.browserVersion */ .C.browserVersion,
      os: _telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.os */ .C.os,
      osVersion: _telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.osVersion */ .C.osVersion,
      extVersion: _telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.version */ .C.version,
      syncSchemaVersion,
    };
  };

  /*
  ** @param arrOne, arrTwo - Arrays to compare
  ** @returns {boolean} - true if a and b are the same array
  **                      has the length and same values in any order
  **                      otherwise false
  */
  function arrayComparison(arrOne, arrTwo) {
    if (!Array.isArray(arrOne) || !Array.isArray(arrTwo)) {
      return false;
    }
    if (arrOne.length !== arrTwo.length) {
      return false;
    }
    return arrOne.every(element => arrTwo.includes(element));
  }

  /*
  ** @param a, b        - values (Object, Date, etc.)
  ** @returns {boolean} - true if a and b are the same object or
  **                      same primitive value or
  **                      have the same properties with the same values
  **                      otherwise false
  */
  function objectComparison(a, b) {
    // Helper to return a value's internal object [[Class]]
    // That this returns [object Type] even for primitives
    function getClass(obj) {
      return Object.prototype.toString.call(obj);
    }

    // If a and b reference the same value, return true
    if (a === b) {
      return true;
    }

    // If a and b aren't the same type, return false
    if (typeof a !== typeof b) {
      return false;
    }

    // Already know types are the same, so if type is number
    // and both NaN, return true
    if (typeof a === 'number' && Number.isNaN(a) && Number.isNaN(b)) {
      return true;
    }

    // Get internal [[Class]]
    const aClass = getClass(a);
    const bClass = getClass(b);

    // Return false if not same class
    if (aClass !== bClass) {
      return false;
    }

    // If they're Boolean, String or Number objects, check values
    if (
      aClass === '[object Boolean]'
      || aClass === '[object String]'
      || aClass === '[object Number]'
    ) {
      if (a.valueOf() !== b.valueOf()) {
        return false;
      }
    }

    // If they're RegExps, Dates or Error objects, check stringified values
    if (aClass === '[object RegExp]' || aClass === '[object Date]' || aClass === '[object Error]') {
      if (a.toString() !== b.toString()) {
        return false;
      }
    }

    // For functions, check stringigied values are the same
    // Almost impossible to be equal if a and b aren't trivial
    // and are different functions
    if (aClass === '[object Function]' && a.toString() !== b.toString()) {
      return false;
    }

    // For all objects, (including Objects, Functions, Arrays and host objects),
    // check the properties
    const aKeys = Object.keys(a);
    const bKeys = Object.keys(b);

    // If they don't have the same number of keys, return false
    if (aKeys.length !== bKeys.length) {
      return false;
    }

    if (Array.isArray(a) && Array.isArray(b)) {
      return arrayComparison(a, b);
    }

    // Check they have the same keys
    if (!aKeys.every(key => Object.prototype.hasOwnProperty.call(b, key))) {
      return false;
    }

    // Check key values - uses ES5 Object.keys
    return aKeys.every(key => objectComparison(a[key], b[key]));
  }

  const isDomainPauseFilter = function (filterText) {
    if (isWhitelistFilter(filterText)) {
      const domains = adblockIsDomainPaused();
      for (const domain in domains) {
        if (`@@${domain}$document` === filterText) {
          return true;
        }
      }
    }
    return false;
  };

  const isPauseFilter = function (filterText) {
    return (
      isWhitelistFilter(filterText) && ((pausedFilterText1 === filterText)
        || (pausedFilterText2 === filterText))
    );
  };

  function getCommitVersion() {
    return syncCommitVersion;
  }

  // Sync log message processing

  const addSyncLogText = function (msg) {
    (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageGetHelper */ .nX)(syncLogMessageKey).then((logMsgs) => {
      const storedLog = JSON.parse(logMsgs || '[]');
      storedLog.push(`${new Date().toUTCString()} , ${msg}`);
      while (storedLog.length > 500) { // only keep the last 500 log entries
        storedLog.shift();
      }
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageSetHelper */ .rJ)(syncLogMessageKey, JSON.stringify(storedLog));
    });
  };

  const onExtensionNamesDownloadingAddLogEntry = function () {
    addSyncLogText('extension.names.downloading');
  };

  const onExtensionNamesDownloadedAddLogEntry = function () {
    addSyncLogText('extension.names.downloaded');
  };

  const onExtensionNamesDownloadingErrorAddLogEntry = function (errorCode) {
    addSyncLogText(`extension.names.downloading.error: ${errorCode}`);
  };

  const onExtensionNameUpdatingAddLogEntry = function () {
    addSyncLogText('extension.name.updating');
  };

  const onExtensionNameUpdatedAddLogEntry = function () {
    addSyncLogText('extension.name.updated');
  };

  const onExtensionNameUpdatedErrorAddLogEntry = function (errorCode) {
    addSyncLogText(`extension.names.updated.error: ${errorCode}`);
  };

  const onExtensionNameRemoveAddLogEntry = function () {
    addSyncLogText('extension.name.remove');
  };

  const onExtensionNameRemovedAddLogEntry = function () {
    addSyncLogText('extension.name.removed');
  };

  const onExtensionNamesRemoveErrorAddLogEntry = function (errorCode) {
    addSyncLogText(`extension.name.remove.error: ${errorCode}`);
  };

  const onPostDataSendingAddLogEntry = function () {
    addSyncLogText('post.data.sending');
  };

  const onPostDataSentAddLogEntry = function () {
    addSyncLogText(`post.data.sent, commit version: ${getCommitVersion()}`);
  };

  const onPostDataSentErrorAddLogEntry = function (errorCode) {
    addSyncLogText(`post.data.sent.error: ${errorCode}`);
  };

  const onSyncDataGettingAddLogEntry = function () {
    addSyncLogText('sync.data.getting');
  };

  const onSyncDataReceievedAddLogEntry = function () {
    addSyncLogText(`sync.data.receieved, commit version: ${getCommitVersion()}`);
  };

  const onSyncDataGettingErrorAddLogEntry = function (errorCode) {
    addSyncLogText(`sync.data.getting.error: ${errorCode}`);
  };

  const onSyncDataGettingErrorInitialFailAddLogEntry = function (errorCode) {
    addSyncLogText(`sync.data.getting.error.initial.fail: ${errorCode}`);
  };

  function cleanCustomFilter(filters) {
    // Remove the global pause white-list item if adblock is paused
    if (adblockIsPaused()) {
      let index = filters.indexOf(pausedFilterText1);
      if (index >= 0) {
        filters.splice(index, 1);
      }
      index = filters.indexOf(pausedFilterText2);
      if (index >= 0) {
        filters.splice(index, 1);
      }
    }

    // Remove the domain pause white-list items
    const domainPauses = adblockIsDomainPaused();
    for (const aDomain in domainPauses) {
      const index = filters.indexOf(`@@${aDomain}$document`);
      if (index >= 0) {
        filters.splice(index, 1);
      }
    }
    return filters;
  }

  const processSyncUpdate = async function (payload) {
    (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .log */ .cM)('processing sync update', payload);
    // do we need a check or comparison of payload.version vs. syncSchemaVersion ?
    if (payload.settings) {
      const keywords = Object.keys(payload.settings);
      // Use a Promise to wait until the previous 'set' is complete because
      // calling 'setSetting' several times in a row in a loop prevents some
      // settings from being saved to storage
      for (let inx = 0, p = Promise.resolve(); inx < keywords.length; inx++) {
        const id = keywords[inx];
        p = p.then(() => new Promise((resolve) => {
          let value = payload.settings[id];
          // since we receive a 'show_statsinpopup' property on the |Prefs| object
          // from older versions of AdBLock, use the incoming value from |Prefs|
          // object for backward compatability
          if (
            id === 'display_menu_stats'
            && payload.prefs
            && Object.prototype.hasOwnProperty.call(payload.prefs, 'show_statsinpopup')
          ) {
            value = payload.prefs.show_statsinpopup;
          }
          (0,_prefs_settings__WEBPACK_IMPORTED_MODULE_5__/* .setSetting */ .Lt)(id, value, () => {
            resolve();
          });
        }));
      }
    }
    if (payload.subscriptions) {
      const currentSubs = await _subscriptionadapter__WEBPACK_IMPORTED_MODULE_4__/* ["default"].getSubscriptionsMinusText */ .Z.getSubscriptionsMinusText();
      for (const id in currentSubs) {
        if (!payload.subscriptions[id] && currentSubs[id].subscribed) {
          // eslint-disable-next-line no-await-in-loop
          await _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.subscriptions.remove(currentSubs[id].url);
        }
      }
      for (const id in payload.subscriptions) {
        if (!currentSubs[id] || !currentSubs[id].subscribed) {
          let url = _subscriptionadapter__WEBPACK_IMPORTED_MODULE_4__/* ["default"].getUrlFromId */ .Z.getUrlFromId(id);
          if (!url && id.startsWith('url:')) {
            url = id.slice(4);
          }
          if (url) {
            // eslint-disable-next-line no-await-in-loop
            await _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.subscriptions.add(url);
            _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.subscriptions.sync(url);
          }
        }
      }
    }

    if (payload.customFilterRules) {
      // capture, then remove all current custom filters, account for pause filters in
      // current processing
      let currentUserFilters = await getUserFilters();
      const onlyUserFilters = currentUserFilters.map(filter => filter.text);
      let results = [];
      for (const inx in payload.customFilterRules) {
        if (
          !_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.filters.validate(payload.customFilterRules[inx])
          && !onlyUserFilters.includes(payload.customFilterRules[inx])
        ) {
          results.push(_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.filters.add([payload.customFilterRules[inx]]));
        }
      }
      await Promise.all(results);
      results = [];
      if (currentUserFilters && currentUserFilters.length) {
        currentUserFilters = cleanCustomFilter(currentUserFilters);
        // Delete / remove filters the user removed...
        if (currentUserFilters) {
          for (let i = 0; (i < currentUserFilters.length); i++) {
            const filter = currentUserFilters[i];
            if (!payload.customFilterRules.includes(filter.text)) {
              if (filter.text.length > 0) {
                if (!_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.filters.validate(filter.text)) {
                  results.push(_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.filters.remove([filter.text]));
                }
              }
            }
          }
        }
      }
      await Promise.all(results);
    }
    if (payload.customRuleMetaData) {
      let currentUserFilters = await getUserFilters();
      currentUserFilters = currentUserFilters.map(filter => filter.text);
      for (const ruleText in payload.customRuleMetaData) {
        if (currentUserFilters.includes(ruleText)) {
          _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.filters.setMetadata(ruleText, payload.customRuleMetaData[ruleText]);
        }
      }
    }
    if (payload.prefs) {
      for (const key in payload.prefs) {
        Prefs[key] = payload.prefs[key];
        // add any new Prefs to the array of Preferences we're tracking for sync
        if (abpPrefPropertyNames.indexOf(key) < 0) {
          abpPrefPropertyNames.push(key);
        }
        // since we no long use the 'show_statsinpopup' property on the |Prefs| object,
        // manually set Settings property for backward compatability
        if (key === 'show_statsinpopup') {
          (0,_prefs_settings__WEBPACK_IMPORTED_MODULE_5__/* .setSetting */ .Lt)('display_menu_stats', payload.prefs[key]);
        }
      }
    }
    if (payload.channels) {
      for (const name in payload.channels) {
        const channelId = channels.getIdByName(name);
        if (channelId) {
          channels.setEnabled(channelId, payload.channels[name]);
        } else {
          // create a new channel to save the channel name and the enabled indicator
          channels.add({ name, param: undefined, enabled: payload.channels[name] });
        }
      }
    }
  };

  const process403ErrorCode = function () {
    // eslint-disable-next-line no-use-before-define
    disableSync(false);
  };

  // Retreive or 'get' the sync data from the sync server
  // Input: initialGet:boolean - if true, and the server returns a 404 error code,
  //                             then a 'post' is invoked
  //        disableEmitMsg:boolean - if true, then no sync notifier message will be emitted
  //                                 (usually used for post error processing)
  //        callback:function - function that will be called when success or failure occurs
  //        shouldForce:boolean - optional, force a response from the server (even if the commit
  //                              versions match), defaults to false
  const getSyncData = function (initialGet, disableEmitMsg, callback, shouldForce) {
    const getSuccess = function (text, statusCode) {
      let responseObj = {};
      if (text && typeof text === 'object') {
        responseObj = text;
      } else if (text && typeof text === 'string') {
        try {
          responseObj = JSON.parse(text);
        } catch (e) {
          // eslint-disable-next-line no-console
          console.log('Something went wrong with parsing license data.');
          // eslint-disable-next-line no-console
          console.log('error', e);
          // eslint-disable-next-line no-console
          console.log(text);
          return;
        }
      }
      if (responseObj && ((responseObj.commitVersion > syncCommitVersion) || shouldForce)) {
        if (responseObj.data) {
          try {
            processSyncUpdate(JSON.parse(responseObj.data));
          } catch (e) {
            // eslint-disable-next-line no-console
            console.log('failed to parse response data from server', responseObj.data);
            // eslint-disable-next-line no-console
            console.log(e);
          }
        }
        syncCommitVersion = responseObj.commitVersion;
        (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageSetHelper */ .rJ)(syncCommitVersionKey, responseObj.commitVersion);
        (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageSetHelper */ .rJ)(syncPreviousDataKey, responseObj.data);
        pendingPostData = false; // reset in case an update is received from another extension
        (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageSetHelper */ .rJ)(syncPendingPostDataKey, pendingPostData);
      }
      if (!disableEmitMsg) {
        syncNotifier.emit('sync.data.receieved');
      }
      if (typeof callback === 'function') {
        callback(statusCode);
      }
    };

    const getFailure = function (statusCode, textStatus, responseJSON) {
      lastGetStatusCode = statusCode;
      lastGetErrorResponse = responseJSON;
      if (initialGet && statusCode === 404) {
        // eslint-disable-next-line no-use-before-define
        postDataSync(callback, initialGet);
        // now that the initial post is complete, enable Sync (add listeners, etc.)
        // with 'initialGet' now set to false
        // eslint-disable-next-line no-use-before-define
        enableSync();
        return;
      }
      if (initialGet && !disableEmitMsg) {
        syncNotifier.emit('sync.data.getting.error.initial.fail', statusCode);
      } else if (!disableEmitMsg) {
        syncNotifier.emit('sync.data.getting.error', statusCode, responseJSON);
        if (statusCode === 403) {
          process403ErrorCode();
        }
      }
      if (typeof callback === 'function') {
        callback(statusCode);
      }
    };

    if (!disableEmitMsg) {
      syncNotifier.emit('sync.data.getting');
    }
    lastGetStatusCode = 200;
    lastGetErrorResponse = {};
    // eslint-disable-next-line no-use-before-define
    requestSyncData(getSuccess, getFailure, undefined, shouldForce);
  };

  const getAllExtensionNames = function () {
    return new Promise((resolve) => {
      syncNotifier.emit('extension.names.downloading');
      fetch(`${_check__WEBPACK_IMPORTED_MODULE_2__/* .License.MAB_CONFIG.syncURL */ .Cz.MAB_CONFIG.syncURL}/devices/list`, {
        method: 'GET',
        cache: 'no-cache',
        headers: {
          'X-GABSYNC-PARAMS': JSON.stringify({
            extensionGUID: _telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.userId */ .C.userId,
            licenseId: _check__WEBPACK_IMPORTED_MODULE_2__/* .License.get */ .Cz.get().licenseId,
            extInfo: getExtensionInfo(),
          }),
        },
      })
        .then(async (response) => {
          if (response.ok) {
            const responseObj = await response.json();
            syncNotifier.emit('extension.names.downloaded', responseObj);
            resolve(responseObj);
            return;
          }
          if (response.status === 404) {
            syncNotifier.emit('extension.names.downloading.error', response.status);
            const text = await response.text();
            resolve(text);
            return;
          }
          (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .log */ .cM)('sync server error: ', response);
        })
        .catch((error) => {
          syncNotifier.emit('extension.names.downloading.error');
          (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .log */ .cM)('sync server returned error: ', error);
        });
    });
  };

  const setCurrentExtensionName = function (newName) {
    if (newName && newName.trim().length >= 1 && newName.trim().length <= 50) {
      currentExtensionName = newName.trim();
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageSetHelper */ .rJ)(syncExtensionNameKey, currentExtensionName);
      const thedata = {
        deviceName: currentExtensionName,
        extensionGUID: _telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.userId */ .C.userId,
        licenseId: _check__WEBPACK_IMPORTED_MODULE_2__/* .License.get */ .Cz.get().licenseId,
        extInfo: getExtensionInfo(),
      };
      syncNotifier.emit('extension.name.updating');
      (0,_fetch_util__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .Z)(`${_check__WEBPACK_IMPORTED_MODULE_2__/* .License.MAB_CONFIG.syncURL */ .Cz.MAB_CONFIG.syncURL}/devices/add`, thedata)
        .then((response) => {
          if (response.ok) {
            syncNotifier.emit('extension.name.updated');
          } else {
            syncNotifier.emit('extension.name.updated.error', response.status);
          }
        })
        .catch((error) => {
          syncNotifier.emit('extension.name.updated.error');
          (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .log */ .cM)('message server returned error: ', error);
        });
    }
  };
  const removeExtensionName = function (extensionName, extensionGUID) {
    const thedata = {
      deviceName: extensionName,
      extensionGUID,
      licenseId: _check__WEBPACK_IMPORTED_MODULE_2__/* .License.get */ .Cz.get().licenseId,
      extInfo: getExtensionInfo(),
    };
    syncNotifier.emit('extension.name.remove');
    (0,_fetch_util__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .Z)(`${_check__WEBPACK_IMPORTED_MODULE_2__/* .License.MAB_CONFIG.syncURL */ .Cz.MAB_CONFIG.syncURL}/devices/remove`, thedata)
      .then((response) => {
        if (response.ok) {
          if (extensionName === currentExtensionName) {
            currentExtensionName = '';
            (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageSetHelper */ .rJ)(syncExtensionNameKey, currentExtensionName);
          }
          syncNotifier.emit('extension.name.removed');
        } else {
          syncNotifier.emit('extension.name.remove.error', response.status);
        }
      })
      .catch((error) => {
        syncNotifier.emit('extension.name.remove.error');
        (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .log */ .cM)('message server returned error: ', error);
      });
  };


  const removeCurrentExtensionName = function () {
    removeExtensionName(currentExtensionName, _telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.userId */ .C.userId);
  };

  // return all of the current user configurable extension options (settings, Prefs, filter list
  // sub, custom rules, themes, etc. Since a comparison will be done in this, and other sync'd
  // extensions, the payload should only contain settings, Prefs, etc and not data that can change
  // from browser to brower, version to version, etc.
  const getSyncInformation = async function () {
    const payload = {};
    payload.settings = (0,_prefs_settings__WEBPACK_IMPORTED_MODULE_5__/* .getSettings */ .Gw)();
    payload.subscriptions = {};
    const subscriptions = await _subscriptionadapter__WEBPACK_IMPORTED_MODULE_4__/* ["default"].getSubscriptionsMinusText */ .Z.getSubscriptionsMinusText();

    for (const id in subscriptions) {
      if (subscriptions[id].subscribed) {
        const { adblockId } = subscriptions[id];
        let { mv2URL: url } = subscriptions[id];
        if (!url) {
          ({ url } = subscriptions[id]);
        }
        if (sendFilterListByURL.includes(adblockId)) {
          payload.subscriptions[`url:${url}`] = url;
        } else {
          payload.subscriptions[adblockId] = url;
        }
      }
    }
    let userFilters = await getUserFilters();
    userFilters = userFilters.map(filter => filter.text).sort();
    payload.customFilterRules = cleanCustomFilter(userFilters);

    const metaDataArr = await getCustomFilterMetaData();
    if (metaDataArr && metaDataArr.length) {
      const ruleMetaData = {};
      for (let inx = 0; inx < metaDataArr.length; inx++) {
        if (metaDataArr[inx].text && metaDataArr[inx].metaData) {
          ruleMetaData[metaDataArr[inx].text] = metaDataArr[inx].metaData;
        }
      }
      payload.customRuleMetaData = ruleMetaData;
    }
    payload.prefs = {};
    for (const inx in abpPrefPropertyNames) {
      const name = abpPrefPropertyNames[inx];
      payload.prefs[name] = Prefs[name];
    }
    // since we no long use the 'show_statsinpopup' property on the |Prefs| object,
    // manually set it using the new 'show_statsinpopup' property on the Settings object
    // for backward compatability
    payload.prefs.show_statsinpopup = (0,_prefs_settings__WEBPACK_IMPORTED_MODULE_5__/* .getSettings */ .Gw)().display_menu_stats;
    payload.channels = {};
    const guide = channels.getGuide();
    for (const id in guide) {
      payload.channels[guide[id].name] = guide[id].enabled;
    }
    return payload;
  };

  const postDataSync = async function (callback, initialGet) {
    if (!(0,_prefs_settings__WEBPACK_IMPORTED_MODULE_5__/* .getSettings */ .Gw)().sync_settings) {
      return;
    }
    const payload = await getSyncInformation();
    const thedata = {
      data: JSON.stringify(payload),
      commitVersion: syncCommitVersion,
      extensionGUID: _telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.userId */ .C.userId,
      licenseId: _check__WEBPACK_IMPORTED_MODULE_2__/* .License.get */ .Cz.get().licenseId,
      extInfo: getExtensionInfo(),
    };
    browser.storage.local.get(syncPreviousDataKey).then((response) => {
      const previousData = response[syncPreviousDataKey] || '{}';
      if (objectComparison(payload, JSON.parse(previousData))) {
        return;
      }
      syncNotifier.emit('post.data.sending');
      lastPostStatusCode = 200;
      pendingPostData = false;
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageSetHelper */ .rJ)(syncPendingPostDataKey, pendingPostData);
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .log */ .cM)('sending sync \'payload\' to server', thedata);
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .log */ .cM)('sending sync \'thedata\' to server', payload);
      (0,_fetch_util__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .Z)(_check__WEBPACK_IMPORTED_MODULE_2__/* .License.MAB_CONFIG.syncURL */ .Cz.MAB_CONFIG.syncURL, thedata).then((postResponse) => {
        lastPostStatusCode = postResponse.status;
        if (postResponse.ok) {
          postResponse.json().then((responseObj) => {
            if (responseObj && responseObj.commitVersion > syncCommitVersion) {
              syncCommitVersion = responseObj.commitVersion;
              (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageSetHelper */ .rJ)(syncCommitVersionKey, responseObj.commitVersion);
            }
            (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageSetHelper */ .rJ)(syncPreviousDataKey, responseObj.data);
            if (typeof callback === 'function') {
              callback();
            }
            syncNotifier.emit('post.data.sent');
          });
        } else {
          syncNotifier.emit('post.data.sent.error', postResponse.status, initialGet);
          lastPostStatusCode = postResponse.status;
          if (postResponse.status === 409) {
            // this extension probably had an version of the sync data
            // aka - the sync commit version was behind the sync server
            // so, undo / revert all of the user changes that were just posted
            // by doing a 'GET'
            // because we want the above error to be persisted, will set the
            // 'disableEmitMsg' to true
            getSyncData(false, true);
            return;
          }
          if (postResponse.status === 403) {
            process403ErrorCode();
          }
          // all other currently known errors (0, 401, 404, 500).
          pendingPostData = true;
          (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageSetHelper */ .rJ)(syncPendingPostDataKey, pendingPostData);
        }
      })
        .catch((error) => {
          syncNotifier.emit('extension.name.updated.error');
          // eslint-disable-next-line no-console
          console.log('message server returned error: ', error);
        });
    });
  };

  const processUserSyncRequest = function () {
    if (pendingPostData) {
      postDataSync();
    } else {
      getSyncData(false, false, undefined, true);
    }
  };

  const processEventChangeRequest = function () {
    if (pendingPostData) {
      postDataSync();
    } else {
      getSyncData();
    }
  };

  const postDataSyncHandler = debounced(debounceWaitTime, postDataSync);

  // Sync Listeners
  function onFilterAdded(filter, subscription, position, calledPreviously) {
    // a delay is added to allow the domain pause filters time to be saved to storage
    // otherwise the domain pause filter check below would always fail
    if (calledPreviously === undefined) {
      setTimeout(() => {
        onFilterAdded(filter, subscription, position, true);
      }, 500);
      return;
    }
    if (isPauseFilter(filter.text)) {
      return;
    }
    if (isDomainPauseFilter(filter.text)) {
      storedSyncDomainPauses.push(filter.text);
      return;
    }
    postDataSyncHandler();
  }

  function onFilterRemoved(filter) {
    if (isPauseFilter(filter.text)) {
      return;
    }
    if (isDomainPauseFilter(filter.text)) {
      const filterTextIndex = storedSyncDomainPauses.indexOf(filter.text);
      storedSyncDomainPauses = storedSyncDomainPauses.slice(filterTextIndex);
      return;
    }
    postDataSyncHandler();
  }

  // a delay is added to allow the domain pause filters time to be saved to storage
  // otherwise the domain pause filter check below would always fail
  const onFilterListsSubAdded = function (sub, calledPreviously) {
    (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .log */ .cM)('onFilterListsSubAdded', sub);
    if (calledPreviously === undefined) {
      setTimeout(() => {
        onFilterListsSubAdded(sub, true);
      }, 500);
      return;
    }
    let containsPauseFilter = false;
    if (sub.url && sub.url.startsWith('~user~') && sub._filterText.length) {
      const arrayLength = sub._filterText.length;
      for (let i = 0; i < arrayLength; i++) {
        const filter = sub._filterText[i];
        containsPauseFilter = isPauseFilter(filter);
        if (!containsPauseFilter && isDomainPauseFilter(filter)) {
          containsPauseFilter = true;
          storedSyncDomainPauses.push(filter.text);
        }
      }
    }
    if (containsPauseFilter) {
      return;
    }
    postDataSyncHandler();
  };

  const onFilterListsSubRemoved = function (sub) {
    let containsPauseFilter = false;
    if (sub.url && sub.url.startsWith('~user~') && sub._filterText.length) {
      const arrayLength = sub._filterText.length;
      for (let i = 0; i < arrayLength; i++) {
        const filter = sub._filterText[i];
        containsPauseFilter = isPauseFilter(filter);
        if (!containsPauseFilter && isDomainPauseFilter(filter.text)) {
          containsPauseFilter = true;
          const filterTextIndex = storedSyncDomainPauses.indexOf(filter.text);
          storedSyncDomainPauses = storedSyncDomainPauses.slice(filterTextIndex);
          return;
        }
      }
    }
    if (containsPauseFilter) {
      return;
    }
    postDataSyncHandler();
  };

  const onSettingsChanged = function (name) {
    if (name === 'sync_settings') {
      return; // don't process any sync setting changes
    }
    postDataSyncHandler();
  };

  const updateNetworkStatus = function () {
    if (navigator.onLine) {
      processEventChangeRequest();
    }
  };

  function processFetchRequest(commitVersion) {
    let fetchCommitVersion = commitVersion;
    if (!fetchCommitVersion) {
      return;
    }
    if (typeof fetchCommitVersion === 'string') {
      fetchCommitVersion = Number.parseInt(fetchCommitVersion, 10);
    }
    if (fetchCommitVersion === syncCommitVersion) {
      return;
    }
    getSyncData();
  }

  function enablePubNub() {
    pubnub = new PubNub({
      subscribeKey: _check__WEBPACK_IMPORTED_MODULE_2__/* .License.MAB_CONFIG.subscribeKey */ .Cz.MAB_CONFIG.subscribeKey,
      authKey: `${_check__WEBPACK_IMPORTED_MODULE_2__/* .License.get */ .Cz.get().licenseId}_${_telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.userId */ .C.userId}`,
      ssl: true,
    });

    pubnub.addListener({
      message(response) {
        if (response.message && response.message && response.message.commitVersion) {
          processFetchRequest(response.message.commitVersion);
        }
      },
      status(msg) {
        if (msg.category === 'PNNetworkUpCategory') {
          pubnub.subscribe({
            channels: [_check__WEBPACK_IMPORTED_MODULE_2__/* .License.get */ .Cz.get().licenseId],
          });
        }
        if (msg.error === true && msg.category && msg.operation) {
          _servermessages__WEBPACK_IMPORTED_MODULE_6__/* ["default"].recordGeneralMessage */ .Z.recordGeneralMessage('pubnub_error', undefined, { licenseId: _check__WEBPACK_IMPORTED_MODULE_2__/* .License.get */ .Cz.get().licenseId, category: msg.category, operation: msg.operation });
        }
      },
    });

    pubnub.subscribe({
      channels: [_check__WEBPACK_IMPORTED_MODULE_2__/* .License.get */ .Cz.get().licenseId],
    });
  }

  const enableSync = function (initialGet) {
    (0,_prefs_settings__WEBPACK_IMPORTED_MODULE_5__/* .setSetting */ .Lt)('sync_settings', true);
    const addListeners = function () {
      syncNotifier.on('sync.data.getting.error', onSyncDataGettingErrorAddLogEntry);
      syncNotifier.on('sync.data.getting.error.initial.fail', onSyncDataGettingErrorInitialFailAddLogEntry);
      syncNotifier.on('extension.names.downloading', onExtensionNamesDownloadingAddLogEntry);
      syncNotifier.on('sync.data.receieved', onSyncDataReceievedAddLogEntry);
      syncNotifier.on('sync.data.getting', onSyncDataGettingAddLogEntry);
      syncNotifier.on('post.data.sent.error', onPostDataSentErrorAddLogEntry);
      syncNotifier.on('post.data.sending', onPostDataSendingAddLogEntry);
      syncNotifier.on('post.data.sent', onPostDataSentAddLogEntry);
      syncNotifier.on('extension.name.remove.error', onExtensionNamesRemoveErrorAddLogEntry);
      syncNotifier.on('extension.name.removed', onExtensionNameRemovedAddLogEntry);
      syncNotifier.on('extension.name.remove', onExtensionNameRemoveAddLogEntry);
      syncNotifier.on('extension.name.updated.error', onExtensionNameUpdatedErrorAddLogEntry);
      syncNotifier.on('extension.name.updated', onExtensionNameUpdatedAddLogEntry);
      syncNotifier.on('extension.name.updating', onExtensionNameUpdatingAddLogEntry);
      syncNotifier.on('extension.names.downloaded', onExtensionNamesDownloadedAddLogEntry);
      syncNotifier.on('extension.names.downloading.error', onExtensionNamesDownloadingErrorAddLogEntry);

      // eslint-disable-next-line no-use-before-define
      _check__WEBPACK_IMPORTED_MODULE_2__/* .License.licenseNotifier.on */ .Cz.licenseNotifier.on('license.expired', processDisableSync);

      _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.subscriptions.onAdded.addListener(onFilterListsSubAdded);
      _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.subscriptions.onRemoved.addListener(onFilterListsSubRemoved);

      _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.filters.onAdded.addListener(onFilterAdded);
      _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.filters.onRemoved.addListener(onFilterRemoved);

      _prefs_settings__WEBPACK_IMPORTED_MODULE_5__/* .settingsNotifier.on */ .Pg.on('settings.changed', onSettingsChanged);
      _channels__WEBPACK_IMPORTED_MODULE_3__/* .channelsNotifier.on */ .l.on('channels.changed', postDataSyncHandler);

      for (const inx in abpPrefPropertyNames) {
        const name = abpPrefPropertyNames[inx];
        Prefs.on(name, postDataSyncHandler);
      }
      // wait a moment at start to allow all of the backgound scripts to load
      setTimeout(() => {
        enablePubNub();
      }, 1000);

      window.addEventListener('online', updateNetworkStatus);
      window.addEventListener('offline', updateNetworkStatus);
    };

    if (initialGet) {
      SyncService.getSyncData(initialGet, false, (response) => {
        if (response === 200 || response === 304) {
          addListeners();
        }
      });
      return;
    }

    addListeners();
  };

  function disablePubNub() {
    if (!pubnub) {
      return;
    }

    pubnub.removeAllListeners();
    pubnub.unsubscribeAll();
    pubnub = undefined;
  }

  const disableSync = function (removeName) {
    (0,_prefs_settings__WEBPACK_IMPORTED_MODULE_5__/* .setSetting */ .Lt)('sync_settings', false);
    syncCommitVersion = 0;
    disablePubNub();
    _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.subscriptions.onAdded.removeListener(onFilterListsSubAdded);
    _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.subscriptions.onRemoved.removeListener(onFilterListsSubRemoved);

    _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.filters.onAdded.removeListener(onFilterAdded);
    _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_1__.filters.onRemoved.removeListener(onFilterRemoved);

    _prefs_settings__WEBPACK_IMPORTED_MODULE_5__/* .settingsNotifier.off */ .Pg.off('settings.changed', onSettingsChanged);
    _channels__WEBPACK_IMPORTED_MODULE_3__/* .channelsNotifier.off */ .l.off('channels.changed', postDataSyncHandler);

    for (const inx in abpPrefPropertyNames) {
      const name = abpPrefPropertyNames[inx];
      Prefs.off(name, postDataSyncHandler);
    }

    storedSyncDomainPauses = [];
    if (removeName) {
      removeCurrentExtensionName();

      currentExtensionName = '';
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .chromeStorageSetHelper */ .rJ)(syncExtensionNameKey, currentExtensionName);
    }

    syncNotifier.off('sync.data.getting.error', onSyncDataGettingErrorAddLogEntry);
    syncNotifier.off('sync.data.getting.error.initial.fail', onSyncDataGettingErrorInitialFailAddLogEntry);
    syncNotifier.off('extension.names.downloading', onExtensionNamesDownloadingAddLogEntry);
    syncNotifier.off('sync.data.receieved', onSyncDataReceievedAddLogEntry);
    syncNotifier.off('sync.data.getting', onSyncDataGettingAddLogEntry);
    syncNotifier.off('post.data.sent.error', onPostDataSentErrorAddLogEntry);
    syncNotifier.off('post.data.sending', onPostDataSendingAddLogEntry);
    syncNotifier.off('post.data.sent', onPostDataSentAddLogEntry);
    syncNotifier.off('extension.name.remove.error', onExtensionNamesRemoveErrorAddLogEntry);
    syncNotifier.off('extension.name.removed', onExtensionNameRemovedAddLogEntry);
    syncNotifier.off('extension.name.remove', onExtensionNameRemoveAddLogEntry);
    syncNotifier.off('extension.name.updated.error', onExtensionNameUpdatedErrorAddLogEntry);
    syncNotifier.off('extension.name.updated', onExtensionNameUpdatedAddLogEntry);
    syncNotifier.off('extension.name.updating', onExtensionNameUpdatingAddLogEntry);
    syncNotifier.off('extension.names.downloaded', onExtensionNamesDownloadedAddLogEntry);
    syncNotifier.off('extension.names.downloading.error', onExtensionNamesDownloadingErrorAddLogEntry);

    // eslint-disable-next-line no-use-before-define
    _check__WEBPACK_IMPORTED_MODULE_2__/* .License.licenseNotifier.off */ .Cz.licenseNotifier.off('license.expired', processDisableSync);
    window.removeEventListener('online', updateNetworkStatus);
    window.removeEventListener('offline', updateNetworkStatus);
  };

  const processDisableSync = function () {
    disableSync(true);
  };

  // Retreive the sync data from the sync server
  // Input: successCallback:function - function that will be called when success occurs, the
  //                                   callback will be provided the response data
  //        errorCallback:function - function that will be called when  failure occurs, the
  //                                 callback will be provided the error code
  //        totalAttempts:integer - the number of 'get' attempts made (only used internally by
  //                               the retry logic)
  //        shouldForce:boolean - optional, force a response from the server (even if the commit
  //                              versions match), defaults to false
  const requestSyncData = function (successCallback, errorCallback, totalAttempts, shouldForce) {
    let attemptCount = totalAttempts;
    if (!attemptCount) {
      attemptCount = 1;
    } else {
      attemptCount += 1;
    }
    const forceParam = shouldForce || false;

    fetch(_check__WEBPACK_IMPORTED_MODULE_2__/* .License.MAB_CONFIG.syncURL */ .Cz.MAB_CONFIG.syncURL, {
      method: 'GET',
      cache: 'no-cache',
      headers: {
        'X-GABSYNC-PARAMS': JSON.stringify({
          extensionGUID: _telemetry_background__WEBPACK_IMPORTED_MODULE_0__/* .TELEMETRY.userId */ .C.userId,
          licenseId: _check__WEBPACK_IMPORTED_MODULE_2__/* .License.get */ .Cz.get().licenseId,
          commitVersion: syncCommitVersion,
          force: forceParam,
          extInfo: getExtensionInfo(),
        }),
      },
    })
      .then(async (response) => {
        if (response.ok && typeof successCallback === 'function') {
          const text = await response.text();
          successCallback(text, response.status);
        }
        if (!response.ok) {
          if ((response.status !== 404 || response.status !== 403) && attemptCount < 3) {
            setTimeout(() => {
              requestSyncData(successCallback, errorCallback, attemptCount, shouldForce);
            }, 1000); // wait 1 second for retry
            return;
          }
          if (typeof errorCallback === 'function') {
            const responseObj = await response.json();
            errorCallback(response.status, response.status, responseObj);
          }
        }
      })
      .catch((error) => {
        (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_7__/* .log */ .cM)('message server returned error: ', error);
        errorCallback(error.message);
      });
  };

  _prefs_settings__WEBPACK_IMPORTED_MODULE_5__/* .settings.onload */ .Xd.onload().then(() => {
    _check__WEBPACK_IMPORTED_MODULE_2__/* .License.ready */ .Cz.ready().then(() => {
      if ((0,_prefs_settings__WEBPACK_IMPORTED_MODULE_5__/* .getSettings */ .Gw)().sync_settings) {
        browser.storage.local.get(syncCommitVersionKey).then((response) => {
          syncCommitVersion = response[syncCommitVersionKey] || 0;
          browser.storage.local.get(syncPendingPostDataKey).then((postDataResponse) => {
            pendingPostData = postDataResponse[syncPendingPostDataKey] || false;
            processEventChangeRequest();
            enableSync();
            migrateSyncLog();
          });
        });
      }

      browser.storage.local.get(syncExtensionNameKey).then((response) => {
        currentExtensionName = response[syncExtensionNameKey] || '';
      });
    });
  });

  return {
    enableSync,
    disableSync,
    getSyncData,
    processFetchRequest,
    getCurrentExtensionName,
    getAllExtensionNames,
    setCurrentExtensionName,
    removeCurrentExtensionName,
    removeExtensionName,
    syncNotifier,
    getCommitVersion,
    setCommitVersion,
    getLastPostStatusCode,
    resetLastPostStatusCode,
    setLastPostStatusCode,
    getLastGetStatusCode,
    resetLastGetStatusCode,
    setLastGetStatusCode,
    getLastGetErrorResponse,
    resetLastGetErrorResponse,
    setLastGetErrorResponse,
    resetAllErrors,
    getSyncLog,
    deleteSyncLog,
    processUserSyncRequest,
    processEventChangeRequest,
    addSyncLogText,
  };
}());

/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (SyncService);


/***/ }),

/***/ 2630:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Gw": () => (/* binding */ getSettings),
/* harmony export */   "Lt": () => (/* binding */ setSetting),
/* harmony export */   "Pg": () => (/* binding */ settingsNotifier),
/* harmony export */   "Xd": () => (/* binding */ settings),
/* harmony export */   "uR": () => (/* binding */ isValidTheme)
/* harmony export */ });
/* harmony import */ var _vendor_adblockplusui_adblockpluschrome_lib_events__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2901);
/* harmony import */ var _utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2028);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser */





const settingsNotifier = new _vendor_adblockplusui_adblockpluschrome_lib_events__WEBPACK_IMPORTED_MODULE_1__/* .EventEmitter */ .v();
const abpPrefPropertyNames = ['show_statsinicon', 'shouldShowBlockElementMenu', 'show_devtools_panel'];
const validThemes = ['default_theme', 'dark_theme', 'watermelon_theme', 'solarized_theme', 'solarized_light_theme', 'rebecca_purple_theme', 'ocean_theme', 'sunshine_theme'];


// OPTIONAL SETTINGS
function Settings() {
  this.settingsKey = 'settings';
  this.defaults = {
    debug_logging: false,
    youtube_channel_whitelist: true,
    youtube_manage_subscribed: true,
    show_advanced_options: false,
    show_block_counts_help_link: true,
    display_menu_stats: true,
    show_survey: true,
    local_cdn: false,
    picreplacement: false,
    twitch_hiding: false,
    onpageMessages: true,
    color_themes: {
      popup_menu: 'default_theme',
      options_page: 'default_theme',
    },
  };
  const that = this;
  this.init = new Promise(((resolve) => {
    browser.storage.local.get(that.settingsKey).then((response) => {
      const settings = response.settings || {};
      that.data = (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__/* .extend */ .l7)(that.defaults, settings);
      if (settings.debug_logging) {
        (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__/* .logging */ .PW)(true);
      }
      if ('managed' in browser.storage) {
        browser.storage.managed.get(null).then((items) => {
          for (const key in items) {
            if (key === 'suppress_update_page' || key === 'suppress_surveys' || key === 'suppress_first_run_page') {
              that.data[key] = items[key];
            }
          }
          resolve();
        },
        // Opera and FF doesn't support browser.storage.managed, but instead of simply
        // removing the API, it gives an asynchronous error which we ignore here.
        () => {
          resolve();
        });
      } else {
        resolve();
      }
    });
  })).then(() => {
    (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__/* .log */ .cM)('\n===SETTINGS FINISHED LOADING===\n\n');
  });
}

Settings.prototype = {
  set(name, isEnabled, callback) {
    const originalValue = this.data[name];
    // Firefox passes weak references to objects, so in case isEnabled is an object,
    // we need to store a local copy of the object
    const localIsEnabled = JSON.parse(JSON.stringify(isEnabled));
    this.data[name] = localIsEnabled;
    const that = this;

    // Don't store defaults that the user hasn't modified
    browser.storage.local.get(this.settingsKey).then((response) => {
      const storedData = response.settings || {};

      storedData[name] = localIsEnabled;
      (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__/* .chromeStorageSetHelper */ .rJ)(that.settingsKey, storedData);
      if (originalValue !== localIsEnabled) {
        settingsNotifier.emit('settings.changed', name, localIsEnabled, originalValue);
      }
      if (callback !== undefined && typeof callback === 'function') {
        callback();
      }
    });
  },

  getAll() {
    return this.data;
  },

  onload() {
    return this.init;
  },

};

const settings = new Settings();
settings.onload();

const getSettings = function () {
  return settings.getAll();
};

const setSetting = function (name, isEnabled, callback) {
  settings.set(name, isEnabled, callback);

  if (name === 'debug_logging') {
    (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__/* .logging */ .PW)(isEnabled);
  }
};

const disableSetting = function (name) {
  settings.set(name, false);
};

const isValidTheme = themeName => validThemes.includes(themeName);

// Attach methods to window
// eslint-disable-next-line no-restricted-globals
Object.assign(self, {
  disableSetting,
  getSettings,
  setSetting,
  settings,
  settingsNotifier,
  abpPrefPropertyNames,
  isValidTheme,
});


/***/ }),

/***/ 1546:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var _utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2028);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, TELEMETRY,  */



// Log an 'error' message on GAB log server.
const ServerMessages = (function serverMessages() {
  // Log a message on GAB log server. The user's userid will be prepended to the
  // message.
  // If callback() is specified, call callback() after logging has completed
  const sendMessageToLogServer = function (payload, callback) {
    fetch('https://log.getadblock.com/v2/record_log.php', {
      method: 'POST',
      cache: 'no-cache',
      headers: { 'Content-Type': 'application/json' },
      body: JSON.stringify(payload),
    })
      .then(() => {
        if (typeof callback === 'function') {
          callback();
        }
      })
      .catch((error) => {
        (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__/* .log */ .cM)('message server returned error: ', error);
      });
  };

  // Log a message on GAB log server. The user's userid will be prepended to the
  // message.
  // If callback() is specified, call callback() after logging has completed
  const recordMessageWithUserID = function (msg, queryType, callback, additionalParams) {
    if (!msg || !queryType) {
      return;
    }
    const payload = {
      u: TELEMETRY.userId,
      f: TELEMETRY.flavor,
      o: TELEMETRY.os,
      l: (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__/* .determineUserLanguage */ .pN)(),
      t: queryType,
      v: browser.runtime.getManifest().version,
    };
    if (typeof additionalParams === 'object') {
      for (const prop in additionalParams) {
        payload[prop] = additionalParams[prop];
      }
    }
    const eventWithPayload = { event: msg, payload };
    sendMessageToLogServer(eventWithPayload, callback);
  };

  // Log a message on GAB log server.
  // If callback() is specified, call callback() after logging has completed
  const recordAnonymousMessage = function (msg, queryType, callback, additionalParams) {
    if (!msg || !queryType) {
      return;
    }
    const payload = {
      f: TELEMETRY.flavor,
      o: TELEMETRY.os,
      l: (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__/* .determineUserLanguage */ .pN)(),
      t: queryType,
    };
    if (typeof additionalParams === 'object') {
      for (const prop in additionalParams) {
        payload[prop] = additionalParams[prop];
      }
    }
    const eventWithPayload = { event: msg, payload };
    sendMessageToLogServer(eventWithPayload, callback);
  };

  // Log a error message on GAB log server.
  // If callback() is specified, call callback() after logging has completed
  const recordAnonymousErrorMessage = function (msg, callback, additionalParams) {
    if (!msg) {
      return;
    }
    const payload = {
      f: TELEMETRY.flavor,
      o: TELEMETRY.os,
      l: (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__/* .determineUserLanguage */ .pN)(),
      t: 'error',
    };
    if (typeof additionalParams === 'object') {
      for (const prop in additionalParams) {
        payload[prop] = additionalParams[prop];
      }
    }
    const eventWithPayload = { event: msg, payload };
    sendMessageToLogServer(eventWithPayload, callback);
  };

  const recordErrorMessage = function (msg, callback, additionalParams) {
    recordMessageWithUserID(msg, 'error', callback, additionalParams);
  };

  // Log an 'status' related message on GAB log server.
  const recordStatusMessage = function (msg, callback, additionalParams) {
    recordMessageWithUserID(msg, 'stats', callback, additionalParams);
  };

  // Log a 'general' message on GAB log server.
  const recordGeneralMessage = function (msg, callback, additionalParams) {
    recordMessageWithUserID(msg, 'general', callback, additionalParams);
  };

  // Log a 'adreport' message on GAB log server.
  const recordAdreportMessage = function (msg, callback, additionalParams) {
    recordMessageWithUserID(msg, 'adreport', callback, additionalParams);
  };

  // Send an error message to the backup log server. This is to be used when
  // there's fetch failure.  It may fail as well depending on the failure,
  // and state of the local computer & network
  const sendMessageToBackupLogServer = function (msg, errorMsg, queryType = 'error') {
    const payload = {
      u: TELEMETRY.userId,
      f: TELEMETRY.flavor,
      o: TELEMETRY.os,
      l: (0,_utilities_background_bg_functions__WEBPACK_IMPORTED_MODULE_0__/* .determineUserLanguage */ .pN)(),
      t: queryType,
      v: browser.runtime.getManifest().version,
      error: errorMsg,
    };
    const eventWithPayload = { event: msg, payload };
    fetch('https://192.241.161.10/v2/record_log.php', {
      method: 'POST',
      cache: 'no-cache',
      headers: { 'Content-Type': 'application/json' },
      body: JSON.stringify(eventWithPayload),
    });
  };

  return {
    recordErrorMessage,
    recordAnonymousMessage,
    recordAnonymousErrorMessage,
    recordStatusMessage,
    recordGeneralMessage,
    recordAdreportMessage,
    sendMessageToBackupLogServer,
  };
}());

/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (ServerMessages);


/***/ }),

/***/ 934:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";

// EXPORTS
__webpack_require__.d(__webpack_exports__, {
  "Z": () => (/* binding */ subscriptionadapter)
});

// EXTERNAL MODULE: ./vendor/webext-sdk/dist/ewe-api.js
var ewe_api = __webpack_require__(3817);
;// CONCATENATED MODULE: ./adblock-betafish/data/betafish-subscriptions.json
const betafish_subscriptions_namespaceObject = JSON.parse('{"https://easylist-downloads.adblockplus.org/exceptionrules.txt":{"id":"0798B6A2-94A4-4ADF-89ED-BEC112FC4C7F","mv2URL":"https://easylist-downloads.adblockplus.org/exceptionrules.txt","adblockId":"acceptable_ads","index":1},"https://easylist-downloads.adblockplus.org/v3/full/exceptionrules.txt":{"id":"0798B6A2-94A4-4ADF-89ED-BEC112FC4C7F","mv2URL":"https://easylist-downloads.adblockplus.org/exceptionrules.txt","adblockId":"acceptable_ads","index":1},"https://easylist-downloads.adblockplus.org/exceptionrules-privacy-friendly.txt":{"id":"F12E0801-A00B-49DE-B1E3-52C9C4F90C8C","mv2URL":"https://easylist-downloads.adblockplus.org/exceptionrules-privacy-friendly.txt","adblockId":"acceptable_ads_privacy","index":2},"https://easylist-downloads.adblockplus.org/v3/full/exceptionrules-privacy-friendly.txt":{"id":"F12E0801-A00B-49DE-B1E3-52C9C4F90C8C","mv2URL":"https://easylist-downloads.adblockplus.org/exceptionrules-privacy-friendly.txt","adblockId":"acceptable_ads_privacy","index":2},"https://easylist-downloads.adblockplus.org/v3/full/distraction-control-video.txt":{"id":"8E2D687A-3B44-46E1-BE68-2FE5441A788E","mv2URL":"https://cdn.adblockcdn.com/filters/distraction-control-video.txt","adblockId":"distraction-control-video","index":4},"https://cdn.adblockcdn.com/filters/distraction-control-video.txt":{"id":"8E2D687A-3B44-46E1-BE68-2FE5441A788E","mv2URL":"https://cdn.adblockcdn.com/filters/distraction-control-video.txt","adblockId":"distraction-control-video","index":4},"https://easylist-downloads.adblockplus.org/v3/full/distraction-control-survey.txt":{"id":"1E7A240E-CD85-493D-BEEF-C68A6AEA1225","mv2URL":"https://cdn.adblockcdn.com/filters/distraction-control-survey.txt","adblockId":"distraction-control-survey","index":5},"https://cdn.adblockcdn.com/filters/distraction-control-survey.txt":{"id":"1E7A240E-CD85-493D-BEEF-C68A6AEA1225","mv2URL":"https://cdn.adblockcdn.com/filters/distraction-control-survey.txt","adblockId":"distraction-control-survey","index":5},"https://easylist-downloads.adblockplus.org/v3/full/distraction-control-newsletter.txt":{"id":"D5561090-9ADB-4EEE-AA81-101B645D9F4F","mv2URL":"https://cdn.adblockcdn.com/filters/distraction-control-newsletter.txt","adblockId":"distraction-control-newsletter","index":6},"https://cdn.adblockcdn.com/filters/distraction-control-newsletter.txt":{"id":"D5561090-9ADB-4EEE-AA81-101B645D9F4F","mv2URL":"https://cdn.adblockcdn.com/filters/distraction-control-newsletter.txt","adblockId":"distraction-control-newsletter","index":6},"https://easylist-downloads.adblockplus.org/v3/full/distraction-control-push.txt":{"id":"3B85CD3F-553A-45D1-AA38-6288E1C4C7B9","mv2URL":"https://cdn.adblockcdn.com/filters/distraction-control-push.txt","adblockId":"distraction-control-push","index":7},"https://cdn.adblockcdn.com/filters/distraction-control-push.txt":{"id":"3B85CD3F-553A-45D1-AA38-6288E1C4C7B9","mv2URL":"https://cdn.adblockcdn.com/filters/distraction-control-push.txt","adblockId":"distraction-control-push","index":7},"https://easylist-downloads.adblockplus.org/v3/full/nocoin.txt":{"url":"https://raw.githubusercontent.com/hoshsadiq/adblock-nocoin-list/master/nocoin.txt","adblockId":"bitcoin_mining_protection","id":"9CC3AF4D-EB89-4100-97C6-4EEE4F8A2E82","index":8},"https://raw.githubusercontent.com/hoshsadiq/adblock-nocoin-list/master/nocoin.txt":{"url":"https://raw.githubusercontent.com/hoshsadiq/adblock-nocoin-list/master/nocoin.txt","adblockId":"bitcoin_mining_protection","id":"9CC3AF4D-EB89-4100-97C6-4EEE4F8A2E82","index":8},"https://easylist-downloads.adblockplus.org/antiadblockfilters.txt":{"url":"https://easylist-downloads.adblockplus.org/antiadblockfilters.txt","adblockId":"warning_removal","index":9},"https://easylist-downloads.adblockplus.org/v3/full/abpindo+easylist.txt":{"id":"B7D76369-DD19-4602-80E8-2E32DDB490AC","mv2URL":"https://easylist-downloads.adblockplus.org/abpindo+easylist.txt","adblockId":"easylist_plus_indonesian","index":13},"https://easylist-downloads.adblockplus.org/abpindo+easylist.txt":{"id":"B7D76369-DD19-4602-80E8-2E32DDB490AC","mv2URL":"https://easylist-downloads.adblockplus.org/abpindo+easylist.txt","adblockId":"easylist_plus_indonesian","index":13},"https://easylist-downloads.adblockplus.org/v3/full/abpvn+easylist.txt":{"id":"1C571EC7-6E52-47CC-B04A-4B3008D0AEBE","mv2URL":"https://easylist-downloads.adblockplus.org/abpvn+easylist.txt","adblockId":"easylist_plus_vietnamese","index":14},"https://easylist-downloads.adblockplus.org/abpvn+easylist.txt":{"id":"1C571EC7-6E52-47CC-B04A-4B3008D0AEBE","mv2URL":"https://easylist-downloads.adblockplus.org/abpvn+easylist.txt","adblockId":"easylist_plus_vietnamese","index":14},"https://easylist-downloads.adblockplus.org/v3/full/bulgarian_list+easylist.txt":{"id":"E22C3B40-DC90-49D7-8BF5-E60904AB159A","mv2URL":"https://easylist-downloads.adblockplus.org/bulgarian_list+easylist.txt","adblockId":"easylist_plus_bulgarian","index":15},"https://easylist-downloads.adblockplus.org/bulgarian_list+easylist.txt":{"id":"E22C3B40-DC90-49D7-8BF5-E60904AB159A","mv2URL":"https://easylist-downloads.adblockplus.org/bulgarian_list+easylist.txt","adblockId":"easylist_plus_bulgarian","index":15},"https://easylist-downloads.adblockplus.org/easylist.txt":{"id":"8C13E995-8F06-4927-BEA7-6C845FB7EEBF","mv2URL":"https://easylist-downloads.adblockplus.org/easylist.txt","adblockId":"easylist","index":16},"https://easylist-downloads.adblockplus.org/v3/full/easylist.txt":{"id":"8C13E995-8F06-4927-BEA7-6C845FB7EEBF","mv2URL":"https://easylist-downloads.adblockplus.org/easylist.txt","adblockId":"easylist","index":16},"https://easylist-downloads.adblockplus.org/v3/full/easylistchina+easylist.txt":{"id":"9BD3EA2F-889D-4CC3-B680-CF484F2BD1B9","mv2URL":"https://easylist-downloads.adblockplus.org/easylistchina+easylist.txt","adblockId":"chinese","index":17},"https://easylist-downloads.adblockplus.org/easylistchina+easylist.txt":{"id":"9BD3EA2F-889D-4CC3-B680-CF484F2BD1B9","mv2URL":"https://easylist-downloads.adblockplus.org/easylistchina+easylist.txt","adblockId":"chinese","index":17},"https://easylist-downloads.adblockplus.org/v3/full/easylistczechslovak+easylist.txt":{"id":"4B6CE485-30AB-4213-AD17-504B3F2D2825","mv2URL":"https://easylist-downloads.adblockplus.org/easylistczechslovak+easylist.txt","adblockId":"czech","index":18},"https://easylist-downloads.adblockplus.org/easylistczechslovak+easylist.txt":{"id":"4B6CE485-30AB-4213-AD17-504B3F2D2825","mv2URL":"https://easylist-downloads.adblockplus.org/easylistczechslovak+easylist.txt","adblockId":"czech","index":18},"https://easylist-downloads.adblockplus.org/v3/full/easylistdutch+easylist.txt":{"id":"A4B88FB6-E5E5-417F-8A49-20B8244995FD","mv2URL":"https://easylist-downloads.adblockplus.org/easylistdutch+easylist.txt","adblockId":"dutch","index":19},"https://easylist-downloads.adblockplus.org/easylistdutch+easylist.txt":{"id":"A4B88FB6-E5E5-417F-8A49-20B8244995FD","mv2URL":"https://easylist-downloads.adblockplus.org/easylistdutch+easylist.txt","adblockId":"dutch","index":19},"https://easylist-downloads.adblockplus.org/v3/full/easylistgermany+easylist.txt":{"id":"0CD3D105-D3B3-4652-8489-94163DE9A08F","mv2URL":"https://easylist-downloads.adblockplus.org/easylistgermany+easylist.txt","adblockId":"easylist_plus_german","index":20},"https://easylist-downloads.adblockplus.org/easylistgermany+easylist.txt":{"id":"0CD3D105-D3B3-4652-8489-94163DE9A08F","mv2URL":"https://easylist-downloads.adblockplus.org/easylistgermany+easylist.txt","adblockId":"easylist_plus_german","index":20},"https://easylist-downloads.adblockplus.org/v3/full/israellist+easylist.txt":{"id":"07549D8B-F06F-4D9D-A567-929AA59E9D1D","mv2URL":"https://easylist-downloads.adblockplus.org/israellist+easylist.txt","adblockId":"israeli","index":21},"https://easylist-downloads.adblockplus.org/israellist+easylist.txt":{"id":"07549D8B-F06F-4D9D-A567-929AA59E9D1D","mv2URL":"https://easylist-downloads.adblockplus.org/israellist+easylist.txt","adblockId":"israeli","index":21},"https://easylist-downloads.adblockplus.org/v3/full/easylistitaly+easylist.txt":{"id":"BBC07C05-66F1-42EC-BD4D-7AD495FAC84B","mv2URL":"https://easylist-downloads.adblockplus.org/easylistitaly+easylist.txt","adblockId":"italian","index":22},"https://easylist-downloads.adblockplus.org/easylistitaly+easylist.txt":{"id":"BBC07C05-66F1-42EC-BD4D-7AD495FAC84B","mv2URL":"https://easylist-downloads.adblockplus.org/easylistitaly+easylist.txt","adblockId":"italian","index":22},"https://easylist-downloads.adblockplus.org/v3/full/easylistlithuania+easylist.txt":{"id":"CBE50FA2-DE3F-480C-B1D7-04289391C033","mv2URL":"https://easylist-downloads.adblockplus.org/easylistlithuania+easylist.txt","adblockId":"easylist_plus_lithuania","index":23},"https://easylist-downloads.adblockplus.org/easylistlithuania+easylist.txt":{"id":"CBE50FA2-DE3F-480C-B1D7-04289391C033","mv2URL":"https://easylist-downloads.adblockplus.org/easylistlithuania+easylist.txt","adblockId":"easylist_plus_lithuania","index":23},"https://easylist-downloads.adblockplus.org/v3/full/easylistpolish+easylist.txt":{"id":"3D2C09D0-DF1C-4C8E-9947-A23DCEAF8F8B","mv2URL":"https://easylist-downloads.adblockplus.org/easylistpolish+easylist.txt","adblockId":"easylist_plus_polish","index":24},"https://easylist-downloads.adblockplus.org/easylistpolish+easylist.txt":{"id":"3D2C09D0-DF1C-4C8E-9947-A23DCEAF8F8B","mv2URL":"https://easylist-downloads.adblockplus.org/easylistpolish+easylist.txt","adblockId":"easylist_plus_polish","index":24},"https://easylist-downloads.adblockplus.org/v3/full/easylistportuguese+easylist.txt":{"id":"14DF7BE6-9675-4E07-987A-D8A1000F9FEF","mv2URL":"https://easylist-downloads.adblockplus.org/easylistportuguese+easylist.txt","adblockId":"easylist_plus_portuguese","index":25},"https://easylist-downloads.adblockplus.org/easylistportuguese+easylist.txt":{"id":"14DF7BE6-9675-4E07-987A-D8A1000F9FEF","mv2URL":"https://easylist-downloads.adblockplus.org/easylistportuguese+easylist.txt","adblockId":"easylist_plus_portuguese","index":25},"https://easylist-downloads.adblockplus.org/v3/full/easylistspanish+easylist.txt":{"id":"C3D13A19-3E8D-41F5-AD64-0F3B36DDE128","mv2URL":"https://easylist-downloads.adblockplus.org/easylistspanish+easylist.txt","adblockId":"easylist_plus_spanish","index":26},"https://easylist-downloads.adblockplus.org/easylistspanish+easylist.txt":{"id":"C3D13A19-3E8D-41F5-AD64-0F3B36DDE128","mv2URL":"https://easylist-downloads.adblockplus.org/easylistspanish+easylist.txt","adblockId":"easylist_plus_spanish","index":26},"https://easylist-downloads.adblockplus.org/v3/full/indianlist+easylist.txt":{"id":"25A31255-AB36-48A4-9086-06192DE71119","mv2URL":"https://easylist-downloads.adblockplus.org/indianlist+easylist.txt","adblockId":"easylist_plus_indian","index":27},"https://easylist-downloads.adblockplus.org/indianlist+easylist.txt":{"id":"25A31255-AB36-48A4-9086-06192DE71119","mv2URL":"https://easylist-downloads.adblockplus.org/indianlist+easylist.txt","adblockId":"easylist_plus_indian","index":27},"https://easylist-downloads.adblockplus.org/v3/full/koreanlist+easylist.txt":{"id":"2708BCB7-2E45-41BC-B517-1730CF532F89","mv2URL":"https://easylist-downloads.adblockplus.org/koreanlist+easylist.txt","adblockId":"easylist_plun_korean","index":28},"https://easylist-downloads.adblockplus.org/koreanlist+easylist.txt":{"id":"2708BCB7-2E45-41BC-B517-1730CF532F89","mv2URL":"https://easylist-downloads.adblockplus.org/koreanlist+easylist.txt","adblockId":"easylist_plun_korean","index":28},"https://easylist-downloads.adblockplus.org/v3/full/latvianlist+easylist.txt":{"id":"950C88EA-2DD1-42E3-B2A2-2DF2ED15563A","mv2URL":"https://easylist-downloads.adblockplus.org/latvianlist+easylist.txt","adblockId":"latvian","index":29},"https://easylist-downloads.adblockplus.org/latvianlist+easylist.txt":{"id":"950C88EA-2DD1-42E3-B2A2-2DF2ED15563A","mv2URL":"https://easylist-downloads.adblockplus.org/latvianlist+easylist.txt","adblockId":"latvian","index":29},"https://easylist-downloads.adblockplus.org/v3/full/liste_ar+liste_fr+easylist.txt":{"id":"684A25C6-6B5D-458A-8A2B-BAC0A12B0B15","mv2URL":"https://easylist-downloads.adblockplus.org/liste_ar+liste_fr+easylist.txt","adblockId":"easylist_plus_arabic_plus_french","index":30},"https://easylist-downloads.adblockplus.org/liste_ar+liste_fr+easylist.txt":{"id":"684A25C6-6B5D-458A-8A2B-BAC0A12B0B15","mv2URL":"https://easylist-downloads.adblockplus.org/liste_ar+liste_fr+easylist.txt","adblockId":"easylist_plus_arabic_plus_french","index":30},"https://easylist-downloads.adblockplus.org/v3/full/liste_fr+easylist.txt":{"id":"2CEA1481-C29C-44F1-A084-A2A019533797","mv2URL":"https://easylist-downloads.adblockplus.org/liste_fr+easylist.txt","adblockId":"easylist_plus_french","index":31},"https://easylist-downloads.adblockplus.org/liste_fr+easylist.txt":{"id":"2CEA1481-C29C-44F1-A084-A2A019533797","mv2URL":"https://easylist-downloads.adblockplus.org/liste_fr+easylist.txt","adblockId":"easylist_plus_french","index":31},"https://easylist-downloads.adblockplus.org/v3/full/ruadlist+easylist.txt":{"id":"1B5F78CA-8B30-4BDF-B0A3-451CB2202984","mv2URL":"https://easylist-downloads.adblockplus.org/ruadlist+easylist.txt","adblockId":"russian","index":32},"https://easylist-downloads.adblockplus.org/ruadlist+easylist.txt":{"id":"1B5F78CA-8B30-4BDF-B0A3-451CB2202984","mv2URL":"https://easylist-downloads.adblockplus.org/ruadlist+easylist.txt","adblockId":"russian","index":32},"https://easylist-downloads.adblockplus.org/v3/full/rolist+easylist.txt":{"id":"EEEF75EC-B2B4-49F4-BC49-17B08266F334","mv2URL":"https://easylist-downloads.adblockplus.org/rolist+easylist.txt","adblockId":"easylist_plus_romanian","index":33},"https://easylist-downloads.adblockplus.org/rolist+easylist.txt":{"id":"EEEF75EC-B2B4-49F4-BC49-17B08266F334","mv2URL":"https://easylist-downloads.adblockplus.org/rolist+easylist.txt","adblockId":"easylist_plus_romanian","index":33},"https://easylist-downloads.adblockplus.org/v3/full/abp-filters-anti-cv.txt":{"id":"D4028CDD-3D39-4624-ACC7-8140F4EC3238","mv2URL":"https://easylist-downloads.adblockplus.org/abp-filters-anti-cv.txt","adblockId":"anticircumvent","index":34},"https://easylist-downloads.adblockplus.org/abp-filters-anti-cv.txt":{"id":"D4028CDD-3D39-4624-ACC7-8140F4EC3238","mv2URL":"https://easylist-downloads.adblockplus.org/abp-filters-anti-cv.txt","adblockId":"anticircumvent","index":34},"https://easylist-downloads.adblockplus.org/v3/full/easyprivacy.txt":{"id":"D72B6F06-52B2-4FED-96A2-1BF59CDD7AEC","mv2URL":"https://easylist-downloads.adblockplus.org/easyprivacy.txt","adblockId":"easyprivacy","index":35},"https://easylist-downloads.adblockplus.org/easyprivacy.txt":{"id":"D72B6F06-52B2-4FED-96A2-1BF59CDD7AEC","mv2URL":"https://easylist-downloads.adblockplus.org/easyprivacy.txt","adblockId":"easyprivacy","index":35},"https://easylist-downloads.adblockplus.org/v3/full/i_dont_care_about_cookies.txt":{"id":"2090F374-29D9-4202-B2CE-139D6492D95E","mv2URL":"https://easylist-downloads.adblockplus.org/i_dont_care_about_cookies.txt","adblockId":"idcac","index":36},"https://easylist-downloads.adblockplus.org/i_dont_care_about_cookies.txt":{"id":"2090F374-29D9-4202-B2CE-139D6492D95E","mv2URL":"https://easylist-downloads.adblockplus.org/i_dont_care_about_cookies.txt","adblockId":"idcac","index":36},"https://easylist-downloads.adblockplus.org/v3/full/fanboy-social.txt":{"id":"0A679439-445F-4DE7-84B9-88341F6DA520","mv2URL":"https://easylist-downloads.adblockplus.org/fanboy-social.txt","adblockId":"antisocial","index":37},"https://easylist-downloads.adblockplus.org/fanboy-social.txt":{"id":"0A679439-445F-4DE7-84B9-88341F6DA520","mv2URL":"https://easylist-downloads.adblockplus.org/fanboy-social.txt","adblockId":"antisocial","index":37},"https://secure.fanboy.co.nz/fanboy-annoyance.txt":{"id":"0B0296EB-1CC5-49CD-AD38-8AF27420B7E4","mv2URL":"https://fanboy.co.nz/fanboy-annoyance.txt","adblockId":"annoyances","index":38},"https://fanboy.co.nz/fanboy-annoyance.txt":{"id":"0B0296EB-1CC5-49CD-AD38-8AF27420B7E4","mv2URL":"https://fanboy.co.nz/fanboy-annoyance.txt","adblockId":"annoyances","index":38},"https://easylist-downloads.adblockplus.org/v3/full/fanboy-annoyance.txt":{"id":"0B0296EB-1CC5-49CD-AD38-8AF27420B7E4","mv2URL":"https://fanboy.co.nz/fanboy-annoyance.txt","adblockId":"annoyances","index":38},"https://easylist-downloads.adblockplus.org/v3/full/fanboy-notifications.txt":{"id":"5BD2BB73-459D-4A74-AF9D-A10157268350","mv2URL":"https://easylist-downloads.adblockplus.org/fanboy-notifications.txt","adblockId":"fb_notifications","index":39},"https://easylist-downloads.adblockplus.org/fanboy-notifications.txt":{"id":"5BD2BB73-459D-4A74-AF9D-A10157268350","mv2URL":"https://easylist-downloads.adblockplus.org/fanboy-notifications.txt","adblockId":"fb_notifications","index":39},"https://easylist-downloads.adblockplus.org/v3/full/dandelion_sprouts_nordic_filters+easylist.txt":{"id":"96932CD9-6DDF-4D97-B92F-FDF747B6FAA2","mv2URL":"https://easylist-downloads.adblockplus.org/dandelion_sprouts_nordic_filters+easylist.txt","adblockId":"nordic","index":55},"https://easylist-downloads.adblockplus.org/dandelion_sprouts_nordic_filters+easylist.txt":{"id":"96932CD9-6DDF-4D97-B92F-FDF747B6FAA2","mv2URL":"https://easylist-downloads.adblockplus.org/dandelion_sprouts_nordic_filters+easylist.txt","adblockId":"nordic","index":55}}');
;// CONCATENATED MODULE: ./adblock-betafish/subscriptionadapter.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */


/* For ESLint: List any global identifiers used in this file below */
/* global browser */




// Adapters & helpers to add the legacy AB 'id' to the ABP subscriptions
// Also adds the 'language' and 'hidden' properties
const SubscriptionAdapter = (function getSubscriptionAdapter() {
  const addAdBlockProperties = function (sub) {
    let subscription = Object.assign({}, sub);
    const url = subscription.url || subscription.mv2URL;
    if (betafish_subscriptions_namespaceObject[url]) {
      subscription = Object.assign(subscription, betafish_subscriptions_namespaceObject[url]);
      if (Object.prototype.hasOwnProperty.call(sub, 'languages')) {
        subscription.languages = [].concat(sub.languages);
      }
      if (!Object.prototype.hasOwnProperty.call(subscription, 'language')) {
        subscription.language = (subscription.languages && subscription.languages.length > 0);
      }
    }
    subscription.correctedURL = subscription.url;
    if (browser.runtime.getManifest().manifest_version === 2) {
      subscription.correctedURL = subscription.mv2URL || subscription.url;
    }
    return subscription;
  };

  // Get the URL for the corresponding ID
  const getUrlFromId = function (searchID) {
    for (const url in betafish_subscriptions_namespaceObject) {
      const subscription = betafish_subscriptions_namespaceObject[url];
      const { adblockId } = subscription;
      if (searchID === adblockId) {
        return url;
      }
    }
    return '';
  };

  // Get the ID for the corresponding URL
  const getIdFromURL = function (searchURL) {
    for (const url in betafish_subscriptions_namespaceObject) {
      const subscription = betafish_subscriptions_namespaceObject[url];
      const { adblockId } = subscription;
      if (searchURL === url) {
        return adblockId;
      }
    }
    return null;
  };

  // determine if the specified filter list is language specific
  // returns the boolean language attribue (if found)
  //         false otherwise
  const isLanguageSpecific = function (searchID) {
    // check for EasyList, as it is a language-specific list (en), but
    // shouldn't be treated as such by the AdBlock code
    if (searchID === 'easylist') {
      return false;
    }

    for (let subscription of ewe_api.subscriptions.getRecommendations()) {
      subscription = addAdBlockProperties(subscription);
      const { adblockId } = subscription;
      if (adblockId === searchID) {
        return subscription.language;
      }
    }
    return false;
  };

  // Get the ID for the corresponding URL
  const getSubscriptionInfoFromURL = function (searchURL) {
    for (let subscription of ewe_api.subscriptions.getRecommendations()) {
      subscription = addAdBlockProperties(subscription);
      const { url } = subscription;
      if (searchURL === url) {
        return subscription;
      }
    }
    return null;
  };

  // Unsubcribe the user from the subscription specified in the argument
  const unsubscribe = async function (options) {
    const subscriptionUrl = getUrlFromId(options.adblockId);
    if (subscriptionUrl !== '') {
      try {
        await ewe_api.subscriptions.remove(subscriptionUrl);
      } catch (e) {
        // do nothing
      }
    }
  };

  // Get only the user's subscriptions with in the AB format
  // without the filter contents (text)
  const getSubscriptionsMinusText = async function () {
    const result = {};
    const subscriptions = await ewe_api.subscriptions.getDownloadable();
    subscriptions.forEach(async (subscription) => {
      const tempSub = addAdBlockProperties(subscription);
      // if the subscription doesn't have a 'adblockId' property, use the 'URL' as an
      // 'adblockId' property
      if (!tempSub.adblockId || tempSub.adblockId === undefined) {
        tempSub.adblockId = `url:${subscription.url}`;
      }
      // add the 'subscribed' property
      tempSub.subscribed = true;
      result[tempSub.adblockId] = tempSub;
    });
    return result;
  };

  const rareFilterLists = {
    'http://fanboy.co.nz/fanboy-turkish.txt': 56,
    'https://pgl.yoyo.org/adservers/serverlist.php?hostformat=adblockplus&mimetype=plaintext': 57,
    'https://adblock.gardar.net/is.abp.txt': 58,
    'https://github.com/SlashArash/adblockfa': 59,
    'https://adblock.ee/list.php': 60,
  };

  // Get a binary string representation of the users subscriptions
  const getSubscriptionsChecksum = async function () {
    let resultA = 0;
    let resultB = 0;
    const subscriptions = await ewe_api.subscriptions.getDownloadable();
    subscriptions.forEach(async (subscription) => {
      const sub = addAdBlockProperties(subscription);
      let index = sub.index || 0; // 0 is the 'unkown' index
      // if URL wasn't found in our subscription file, check the rareFilterLists to get the index
      if (index === 0 && rareFilterLists[sub.url]) {
        index = rareFilterLists[sub.url];
      }
      index = parseInt(index, 10);
      if (index < 32) {
        resultA |= (2 ** index); // eslint-disable-line no-bitwise
      } else {
        resultB |= (2 ** (index - 32)); // eslint-disable-line no-bitwise
      }
    });
    return resultB.toString(2).padStart(32, '0') + resultA.toString(2).padStart(32, '0');
  };

  // Get all subscriptions in the AB format
  // without the filter contents (text)
  const getAllSubscriptionsMinusText = async function () {
    const userSubs = await getSubscriptionsMinusText();
    for (const subscription of ewe_api.subscriptions.getRecommendations()) {
      const sub = addAdBlockProperties(subscription);
      const { adblockId } = sub;
      if (!(adblockId in userSubs)) {
        userSubs[adblockId] = sub;
      } else {
        Object.assign(userSubs[adblockId], sub);
      }
    }
    for (const url in betafish_subscriptions_namespaceObject) {
      let sub = Object.assign({}, betafish_subscriptions_namespaceObject[url]);
      sub.url = url;
      sub = addAdBlockProperties(sub);
      const { adblockId } = sub;
      if (!(adblockId in userSubs)) {
        userSubs[adblockId] = sub;
      }
    }
    return userSubs;
  };
  // Get all distraction control subscriptions
  // without the filter contents (text)
  const getDCSubscriptionsMinusText = async function () {
    const userSubs = await getAllSubscriptionsMinusText();
    const result = {};
    for (const adblockId in userSubs) {
      const {
        url, type, title, homepage, hidden, subscribed, index,
      } = userSubs[adblockId];
      if (type === 'distraction-control') {
        result[adblockId] = {};
        result[adblockId].subscribed = subscribed;
        result[adblockId].adblockId = adblockId;
        result[adblockId].url = url;
        result[adblockId].userSubmitted = false;
        result[adblockId].hidden = hidden;
        result[adblockId].type = type;
        result[adblockId].title = title;
        result[adblockId].homepage = homepage;
        result[adblockId].index = index;
      }
    }
    return result;
  };


  // Subcribe the user to the subscription specified in the argument
  const subscribe = function (options) {
    if (options && options.adblockId) {
      const subscriptionUrl = getUrlFromId(options.adblockId);
      if (subscriptionUrl) {
        ewe_api.subscriptions.add(subscriptionUrl);
      }
    }
  };

  return {
    getSubscriptionInfoFromURL,
    getUrlFromId,
    unsubscribe,
    subscribe,
    getSubscriptionsMinusText,
    getSubscriptionsChecksum,
    getAllSubscriptionsMinusText,
    getDCSubscriptionsMinusText,
    getIdFromURL,
    isLanguageSpecific,
  };
}());

/* harmony default export */ const subscriptionadapter = (SubscriptionAdapter);


/***/ }),

/***/ 7877:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";

// EXPORTS
__webpack_require__.d(__webpack_exports__, {
  "Z": () => (/* binding */ survey)
});

// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/prefs.js
var prefs = __webpack_require__(8710);
// EXTERNAL MODULE: ./node_modules/adblockpluscore/lib/url.js
var url = __webpack_require__(9491);
// EXTERNAL MODULE: ./adblock-betafish/prefs/settings.js
var settings = __webpack_require__(2630);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/stats.js
var stats = __webpack_require__(9892);
// EXTERNAL MODULE: ./adblock-betafish/utilities/background/bg-functions.js
var bg_functions = __webpack_require__(2028);
;// CONCATENATED MODULE: ./adblock-betafish/onpageIcon/onpage-icon-bg.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, log,
 */




const OnPageIconManager = (function initialize() {
  const MAX_MSG_TEXT_LENGTH = 280;

  const isIconDataValid = function (iconData) {
    if (!iconData) {
      return false;
    }
    if (!iconData.msgText || !iconData.titleText || !iconData.titlePrefixText) {
      return false;
    }
    if (!iconData.buttonText && iconData.buttonURL) {
      return false;
    }
    if (iconData.buttonText && !iconData.buttonURL) {
      return false;
    }
    if (typeof iconData.buttonText !== 'string') {
      return false;
    }
    if (typeof iconData.msgText !== 'string') {
      return false;
    }
    if (typeof iconData.titlePrefixText !== 'string') {
      return false;
    }
    if (typeof iconData.titleText !== 'string') {
      return false;
    }
    if (iconData.buttonURL && typeof iconData.buttonURL !== 'string') {
      return false;
    }
    if (iconData.buttonURL && !iconData.buttonURL.startsWith('/')) {
      return false;
    }
    if (iconData.ctaIconURL && typeof iconData.ctaIconURL !== 'string') {
      return false;
    }
    return true;
  };


  return {
    // shows / display the AdBlock annimated icon on the specified tab
    // Inputs: tabId : integer - the id of the tab
    //         tabUrl : string - the top level URL of the tab, used for confirmation purposes
    //         iconData : object - with the following:
    //             surveyId: string - unique survey id from ping server
    //             msgText : string - The text of the message (will truncate after 280 characters)
    //             titlePrefixText : string - The prefix title text in the speech bubble
    //             titleText : string - The title text in the speech bubble
    //             ctaIconURL : string (optional) - The hero image in SVG format
    //             buttonText : string (optional) - The text in the button
    //             buttonURL : string (optional) - only the path part of the URL,
    //                         required to start with a '/' character
    //                         the '/' indicates that a new tab should be opened on gab.com
    //                         (the extension will add the 'gab.com' prefix for security reasons)
    showOnPageIcon(tabId, tabUrl, iconData) {
      if (!(0,settings/* getSettings */.Gw)().onpageMessages) {
        (0,bg_functions/* log */.cM)('OnPageIconManager:: settings.onpageMessages is false');
        return;
      }
      if (!isIconDataValid(iconData)) {
        (0,bg_functions/* log */.cM)('OnPageIconManager:showOnPageIcon::isIconDataValid: false', iconData);
        return;
      }
      let { msgText } = iconData;
      if (msgText && msgText.length > MAX_MSG_TEXT_LENGTH) {
        msgText = msgText.slice(0, MAX_MSG_TEXT_LENGTH);
      }
      (0,bg_functions/* log */.cM)('showOnPageIcon::iconData:', iconData);
      browser.tabs.insertCSS(tabId, {
        file: 'adblock-onpage-icon-user.css',
        allFrames: false,
        runAt: 'document_start',
      }).then(() => {
        browser.tabs.executeScript(tabId, {
          file: 'purify.min.js',
          allFrames: false,
        }).then(() => {
          const data = {
            command: 'showonpageicon',
            tabURL: tabUrl,
            titleText: iconData.titleText,
            titlePrefixText: iconData.titlePrefixText,
            msgText,
            surveyId: iconData.surveyId,
            buttonText: iconData.buttonText,
            buttonURL: iconData.buttonURL,
            ctaIconURL: iconData.ctaIconURL,
          };
          browser.tabs.sendMessage(tabId, data).catch((error) => {
            (0,bg_functions/* log */.cM)('error', error);
          });
        }).catch((error) => {
          (0,bg_functions/* log */.cM)('Injection of DOM Purify failed');
          (0,bg_functions/* log */.cM)(error);
        });
      }).catch((error) => {
        (0,bg_functions/* log */.cM)('Injection of adblock-onpage-icon-user.css failed');
        (0,bg_functions/* log */.cM)(error);
      });
    }, // end of showOnPageIcon
  };
}());

/* harmony default export */ const onpage_icon_bg = (OnPageIconManager);

// EXTERNAL MODULE: ./adblock-betafish/fetch-util.js
var fetch_util = __webpack_require__(2379);
;// CONCATENATED MODULE: ./adblock-betafish/survey.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, TELEMETRY, License, log, openTab,
 */

// if the ping response indicates a survey (tab or overlay)
// gracefully processes the request










const SURVEY = (function getSurvey() {
  // Only allow one survey per browser startup, to make sure users don't get
  // spammed due to bugs in AdBlock / the ping server / the browser.
  let surveyAllowed = true;
  const SURVEY_DATA_KEY = 'ab.survey.data';

  // True if we are willing to show an overlay on this tab.
  const validTab = function (tab) {
    if (tab.incognito || tab.status !== 'complete') {
      return false;
    }
    return /^http/.test(tab.url);
  };

  /**
   * Checks whether the tab URL is a match to the domain(s)
   * @param {?string} [tabDomain]
   * @return {boolean}
   */
  const isActiveOnDomain = function (tabDomain, domains) {
    // If no domains are set the rule matches everywhere
    if (!domains) {
      return true;
    }
    let docDomain = tabDomain;
    if (docDomain === null) {
      docDomain = '';
    } else if (docDomain[docDomain.length - 1] === '.') {
      docDomain = docDomain.substring(0, docDomain.length - 1);
    }

    // If the document has no host name, match only if the filter
    // isn't restricted to specific domains
    if (!docDomain) {
      return domains.get('');
    }

    for (docDomain of (0,url/* domainSuffixes */.$e)(docDomain)) {
      const isDomainIncluded = domains.get(docDomain);
      if (typeof isDomainIncluded !== 'undefined') {
        return isDomainIncluded;
      }
    }

    return domains.get('');
  };

  // Domains and paths that we don't want to show the On Page icon on
  // hostname : required and is an exact match
  // pathname : optional and is an startsWith match
  const excludedSites = [
    {
      hostname: 'www.google.com',
      pathname: '/maps',
    },
    {
      hostname: 'meet.google.com',
    },
  ];

  /**
   * Checks whether the URL is restricted
   *
   * @param {URL} [theURL]
   * @return {boolean}
   */
  const isRestricted = function (theURL) {
    return excludedSites.some((element) => {
      let response = !!(element.hostname && element.hostname === theURL.hostname);
      if (response && element.pathname && theURL.pathname) {
        response = response && theURL.pathname.startsWith(element.pathname);
      }
      return response;
    });
  };

  // functions below are used by both Tab Surveys

  // Double check that the survey should be shown
  // Inputs:
  //   surveyData: JSON survey information from ping server
  //   callback(): called with no arguments if the survey should be shown
  const shouldShowSurvey = async function (surveyData) {
    // Check if we should show survey only if it can actually be shown
    // based on surveyAllowed.
    (0,bg_functions/* log */.cM)('shouldShowSurvey::surveyAllowed: ', surveyAllowed);
    if (!surveyAllowed) {
      return null;
    }
    const data = { cmd: 'survey', u: TELEMETRY.userId, sid: surveyData.survey_id };
    if (TELEMETRY.flavor === 'E' && prefs/* Prefs.blocked_total */.B.blocked_total) {
      data.b = prefs/* Prefs.blocked_total */.B.blocked_total;
    }
    const response = await (0,fetch_util/* default */.Z)(TELEMETRY.statsUrl, data);
    if (response.ok) {
      const dataObj = await response.json();
      if (dataObj && dataObj.should_survey === 'true' && surveyAllowed) {
        // for icon surveys, the surveyAllowed is set to false when
        // the user engages / mouse's over the icon
        if (surveyData.type !== 'icon') {
          surveyAllowed = false;
        }
        return dataObj;
      }
    }
    (0,bg_functions/* log */.cM)('bad response from ping', response);
    return null;
  };

  const validateIconSurveyData = function (surveyData) {
    if (!surveyData) {
      return false;
    }
    if (surveyData.type !== 'icon') {
      return false;
    }
    if (!surveyData.survey_id) {
      return false;
    }
    if (!surveyData.domains || typeof surveyData.domains !== 'string') {
      return false;
    }
    if (surveyData.block_count && typeof surveyData.block_count !== 'number') {
      return false;
    }
    if (!Object.prototype.hasOwnProperty.call(surveyData, 'block_count')) {
      return false;
    }
    if (!surveyData.user_state || typeof surveyData.user_state !== 'string') {
      return false;
    }
    return true;
  };

  const doesLicenseMatch = function (surveyData) {
    if (surveyData.user_state === 'all') {
      return true;
    }
    const license = License && License.get();
    if (license && license.status === 'active' && surveyData.user_state === 'active') {
      return true;
    }
    if (license && !license.status && surveyData.user_state === 'free') {
      return true;
    }
    return false;
  };

  const tabListener = async function (updatedTabId, changeInfo, tab) {
    const shouldShowOnPageIcon = async function (surveyData) {
      const responseData = await shouldShowSurvey(surveyData);
      (0,bg_functions/* log */.cM)('shouldShowSurvey:: responseData', responseData);
      if (
        responseData
        && responseData.survey_id === surveyData.survey_id
        && responseData.should_survey === 'true'
        && responseData.type === 'icon'
        && responseData.icon_options
      ) {
        onpage_icon_bg.showOnPageIcon(tab.id, tab.url, {
          titlePrefixText: responseData.icon_options.title_prefix_text,
          titleText: responseData.icon_options.title_text,
          msgText: responseData.icon_options.msg_text,
          buttonText: responseData.icon_options.button_text,
          ctaIconURL: responseData.icon_options.cta_icon_url,
          buttonURL: responseData.icon_options.button_url,
          surveyId: responseData.survey_id,
        });
      } else {
        // clean up, if we were told to not show the survey
        browser.storage.local.remove(SURVEY_DATA_KEY);
      }
    };

    const surveyData = await (0,bg_functions/* chromeStorageGetHelper */.nX)(SURVEY_DATA_KEY);
    if (!surveyData || !validateIconSurveyData(surveyData)) {
      browser.tabs.onUpdated.removeListener(tabListener);
      return;
    }
    const parsedDomains = (0,url/* parseDomains */.bV)(surveyData.domains, ',');
    if (changeInfo.status === 'complete' && tab.status === 'complete' && validTab(tab)) {
      const myURL = new URL(tab.url);
      const cleanDomain = myURL.hostname;
      (0,bg_functions/* log */.cM)('processIcon:: surveyData', surveyData);
      (0,bg_functions/* log */.cM)('processIcon:: parsedDomains', parsedDomains);
      (0,bg_functions/* log */.cM)('processIcon:: checking if isActiveOnDomain', cleanDomain, isActiveOnDomain(cleanDomain, parsedDomains));
      (0,bg_functions/* log */.cM)('processIcon:: checking if isRestricted', isRestricted(myURL));
      if (isActiveOnDomain(cleanDomain, parsedDomains) && !isRestricted(myURL)) {
        (0,bg_functions/* log */.cM)('processIcon:: block count check', await (0,stats/* getBlockedPerPage */.G)(tab), surveyData.block_count);
        if (surveyData.block_count <= await (0,stats/* getBlockedPerPage */.G)(tab)) {
          shouldShowOnPageIcon(surveyData);
        }
      }
    }
  };

  const surveyMsgListener = async function (message, sender, sendResponse) {
    const surveyData = await (0,bg_functions/* chromeStorageGetHelper */.nX)(SURVEY_DATA_KEY);
    if (!surveyData || !validateIconSurveyData(surveyData)) {
      browser.runtime.onMessage.removeListener(surveyMsgListener);
      return;
    }
    if (message.onpageiconevent === 'mouseenter') {
      surveyAllowed = false;
      browser.runtime.onMessage.removeListener(surveyMsgListener);
      browser.tabs.onUpdated.removeListener(tabListener);
      browser.storage.local.remove(SURVEY_DATA_KEY);
      const tabs = await browser.tabs.query({ url: '*://*/*' });
      for (const theTab of tabs) {
        if (theTab.id !== sender.tab.id && theTab.url && theTab.url.startsWith('http')) {
          browser.tabs.sendMessage(theTab.id, { command: 'removeIcon' }).catch(() => {
            // ignore error
          });
        }
      }
      sendResponse({});
    }
  };

  // Process a request to show the 'on page / tab AdBlock icon'
  // Inputs:
  //         surveyData : object - with the following:
  //             survey_id : string - A unique string
  //             domains : string - A separate list of domains, and subdomain to show the icon on
  //             block_count : integer - The minimum block count to show the icon (can be zero)
  //             user_state : string - one of the three values: 'all', 'free', 'active'
  // step 1 verify the user allows on page messages
  // step 2 verify the initial survey data (ping response)
  // step 3 verify license type is a match
  // step 4 add a onTab update listener to watch for user navigation
  // step 5 when a tab/site is done loading, check the tab's domain to the survey's list of domains
  // step 6 compare the current block count on the tab to survey's minimum block count
  // step 7 if the tab meets all of the survey critieria, then check with the ping server again
  // step 8 validate shouldShow response data
  // step 9 show the adblock icon on the tab
  // step 10 when the user interacts with the icon, remove tab listener
  const processIcon = function (surveyData) {
    (0,bg_functions/* log */.cM)('processIcon:: surveyData', surveyData);
    (0,bg_functions/* log */.cM)('processIcon:: is survey data valid? ', validateIconSurveyData(surveyData));
    (0,bg_functions/* log */.cM)('processIcon:: is license status match? ', doesLicenseMatch(surveyData));
    (0,bg_functions/* log */.cM)('processIcon:: is settting enabled? ', (0,settings/* getSettings */.Gw)().onpageMessages);
    if (
      (0,settings/* getSettings */.Gw)().onpageMessages
      && validateIconSurveyData(surveyData)
      && doesLicenseMatch(surveyData)
    ) {
      (0,bg_functions/* chromeStorageSetHelper */.rJ)(SURVEY_DATA_KEY, surveyData);
      browser.runtime.onMessage.removeListener(surveyMsgListener);
      browser.runtime.onMessage.addListener(surveyMsgListener);
      browser.tabs.onUpdated.removeListener(tabListener);
      browser.tabs.onUpdated.addListener(tabListener);
    }
  };

  // Check the response from a ping to see if it contains valid survey instructions.
  // If so, return an object containing data about the survey to show.
  // Otherwise, return null.
  // Inputs:
  //   responseData: string response from a ping
  const surveyDataFrom = function (responseData) {
    let surveyData;

    if (responseData.length === 0 || responseData.trim().length === 0) {
      return null;
    }
    try {
      surveyData = JSON.parse(responseData);
      if (!surveyData) {
        return null;
      }
    } catch (e) {
      // eslint-disable-next-line no-console
      console.log('Something went wrong with parsing survey data.');
      // eslint-disable-next-line no-console
      console.log('error', e);
      // eslint-disable-next-line no-console
      console.log('response data', responseData);
      return null;
    }
    return surveyData;
  };

  const openTabIfAllowed = async function (surveyData) {
    if (surveyData && surveyData.type === 'tab') {
      const responseData = await shouldShowSurvey(surveyData);
      browser.storage.local.remove(SURVEY_DATA_KEY);
      if (responseData && responseData.open_this_url) {
        browser.tabs.create({ url: `https://getadblock.com/${responseData.open_this_url}` });
      }
    }
  };

  const waitForUserAction = async function () {
    const surveyData = await (0,bg_functions/* chromeStorageGetHelper */.nX)(SURVEY_DATA_KEY);
    if (!surveyData) {
      browser.tabs.onCreated.removeListener(waitForUserAction);
      return;
    }
    openTabIfAllowed(surveyData);
  };

  // open a Tab for a full page survey
  const processTab = async function (surveyData) {
    if ((0,settings/* getSettings */.Gw)().onpageMessages) {
      (0,bg_functions/* chromeStorageSetHelper */.rJ)(SURVEY_DATA_KEY, surveyData);
      const state = await browser.idle.queryState(60);
      if (state === 'active') {
        openTabIfAllowed(surveyData);
      } else {
        browser.tabs.onCreated.removeListener(waitForUserAction);
        browser.tabs.onCreated.addListener(waitForUserAction);
      }
    }
  }; // end of processTab()

  browser.runtime.onMessage.removeListener(surveyMsgListener);
  browser.runtime.onMessage.addListener(surveyMsgListener);
  browser.tabs.onUpdated.addListener(tabListener);
  browser.tabs.onCreated.removeListener(waitForUserAction);
  browser.tabs.onCreated.addListener(waitForUserAction);

  return {
    maybeSurvey(responseData) {
      if ((0,settings/* getSettings */.Gw)().show_survey === false) {
        (0,bg_functions/* log */.cM)('maybeSurvey::show_survey === false, returning');
        return;
      }
      if ((0,settings/* getSettings */.Gw)().suppress_surveys) {
        (0,bg_functions/* log */.cM)('maybeSurvey::suppress_surveys === true, returning');
        return;
      }

      const surveyData = surveyDataFrom(responseData);
      if (!surveyData) {
        return;
      }
      if (surveyData.type === 'tab') {
        processTab(surveyData);
      } else if (surveyData.type === 'icon') {
        processIcon(surveyData);
      }
    }, // end of maybeSurvey
    types() {
      // 'T' = Tab Surveys
      // 'I' = On Page Icon
      return 'TI';
    },
  };
}());

/* harmony default export */ const survey = (SURVEY);


/***/ }),

/***/ 158:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";

// EXPORTS
__webpack_require__.d(__webpack_exports__, {
  "fp": () => (/* reexport */ IPM),
  "C": () => (/* reexport */ TELEMETRY)
});

// UNUSED EXPORTS: telemetryNotifier

// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/events.js
var events = __webpack_require__(2901);
// EXTERNAL MODULE: ./adblock-betafish/servermessages.js
var servermessages = __webpack_require__(1546);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/prefs.js
var prefs = __webpack_require__(8710);
// EXTERNAL MODULE: ./vendor/webext-sdk/dist/ewe-api.js
var ewe_api = __webpack_require__(3817);
// EXTERNAL MODULE: ./adblock-betafish/ctaabmanager.js
var ctaabmanager = __webpack_require__(1064);
// EXTERNAL MODULE: ./adblock-betafish/survey.js + 1 modules
var survey = __webpack_require__(7877);
// EXTERNAL MODULE: ./adblock-betafish/subscriptionadapter.js + 1 modules
var subscriptionadapter = __webpack_require__(934);
// EXTERNAL MODULE: ./adblock-betafish/utilities/background/bg-functions.js
var bg_functions = __webpack_require__(2028);
;// CONCATENATED MODULE: ./adblock-betafish/telemetry/background/telemetry-base.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, channels, replacedCounts, getSettings
   recordAnonymousErrorMessage, BigInt, LocalCDN,  */










const userIdStorageKey = 'userid';
const FiftyFiveMinutes = 3300000;

class TelemetryBase {
  constructor(totalRequestsStorageKeyArg, nextRequestTimeStorageKeyArg, alarmNameArg, hostURLArg) {
    this.totalRequestsStorageKey = totalRequestsStorageKeyArg;
    this.nextRequestTimeStorageKey = nextRequestTimeStorageKeyArg;
    this.alarmName = alarmNameArg;
    this.hostURL = hostURLArg;
    this.dataCorrupt = false;
    // Get some information about the version, os, and browser
    this.version = browser.runtime.getManifest().version;
    let match = navigator.userAgent.match(/(CrOS \w+|Windows NT|Mac OS X|Linux) ([\d._]+)?/);
    this.os = (match || [])[1] || 'Unknown';
    this.osVersion = (match || [])[2] || 'Unknown';
    this.flavor = 'E'; // Chrome
    match = navigator.userAgent.match(/(?:Chrome|Version)\/([\d.]+)/);
    const edgeMatch = navigator.userAgent.match(/(?:Edg|Version)\/([\d.]+)/);
    const firefoxMatch = navigator.userAgent.match(/(?:Firefox)\/([\d.]+)/);
    if (edgeMatch) {
      this.flavor = 'CM'; // MS - Chromium Edge
      match = edgeMatch;
    } else if (firefoxMatch) {
      this.flavor = 'F'; // Firefox
      match = firefoxMatch;
    }
    this.browserVersion = (match || [])[1] || 'Unknown';
    this.firstRun = false;
    this.userId = '';
    // added calls to these two methods because the need to be
    // called in the first turn of the event loop
    this.addAlarmListener();
    this.checkIdleState();
  }

  // Check if the computer was woken up, and if there was a pending alarm
  // that should fired during the sleep, then
  // remove it, and fire the update ourselves.
  // see - https://bugs.chromium.org/p/chromium/issues/detail?id=471524
  checkIdleState() {
    browser.idle.onStateChanged.addListener(async (newState) => {
      if (newState === 'active') {
        const alarm = await browser.alarms.get(this.alarmName);
        if (alarm && Date.now() > alarm.scheduledTime) {
          await browser.alarms.clear(this.alarmName);
          await this.pingNow();
          await this.scheduleNextPing();
          await this.sleepThenPing();
        } else if (alarm) {
          // if the alarm should fire in the future,
          // re-add the alarm so it fires at the correct time
          const originalTime = alarm.scheduledTime;
          const wasCleared = await browser.alarms.clear(this.alarmName);
          if (wasCleared) {
            browser.alarms.create(this.alarmName, { when: originalTime });
          }
        }
      }
    });
  }

  addAlarmListener = () => {
    browser.alarms.onAlarm.addListener(async (alarm) => {
      if (alarm && alarm.name === this.alarmName) {
        await this.pingNow();
        await this.scheduleNextPing();
        await this.sleepThenPing();
      }
    });
  };

  // Give the user a userid if they don't have one yet.
  async loadUserID() {
    const response = await browser.storage.local.get(userIdStorageKey);
    if (!response[userIdStorageKey]) {
      const timeSuffix = (Date.now()) % 1e8; // 8 digits from end of
      // timestamp
      const alphabet = 'abcdefghijklmnopqrstuvwxyz0123456789';
      const result = [];
      for (let i = 0; i < 8; i++) {
        const choice = Math.floor(Math.random() * alphabet.length);
        result.push(alphabet[choice]);
      }
      this.userId = result.join('') + timeSuffix;
      (0,bg_functions/* chromeStorageSetHelper */.rJ)(userIdStorageKey, this.userId);
    } else {
      this.userId = response[userIdStorageKey];
    }
    return this.userId;
  }

  // Clean up / remove old, unused data in localStorage
  cleanUpLocalStorage() {
    (0,bg_functions/* storageSet */.eV)(userIdStorageKey);
    (0,bg_functions/* storageSet */.eV)(this.totalRequestsStorageKey);
    (0,bg_functions/* storageSet */.eV)(this.nextRequestTimeStorageKey);
  }

  async getTelemetryData() {
    const response = await browser.storage.local.get(this.totalRequestsStorageKey);
    let data = {};
    const settingsObj = getSettings();
    const totalPings = response[this.totalRequestsStorageKey] || 0;
    const themeOptionsPage = settingsObj.color_themes.options_page.replace('_theme', '');
    const themePopupMenu = settingsObj.color_themes.popup_menu.replace('_theme', '');
    let subsStr = '-1';
    if (typeof BigInt === 'function') {
      subsStr = BigInt(`0b${await subscriptionadapter/* default.getSubscriptionsChecksum */.Z.getSubscriptionsChecksum()}`).toString();
    }

    data = {
      u: this.userId,
      v: this.version,
      f: this.flavor,
      o: this.os,
      bv: this.browserVersion,
      ov: this.osVersion,
      ad: settingsObj.show_advanced_options ? '1' : '0',
      yt: settingsObj.youtube_channel_whitelist ? '1' : '0',
      l: (0,bg_functions/* determineUserLanguage */.pN)(),
      pc: totalPings,
      dcv2: settingsObj.data_collection_v2 ? '1' : '0',
      ldc: settingsObj.local_data_collection ? '1' : '0',
      cdn: settingsObj.local_cdn ? '1' : '0',
      rc: await replacedCounts.getTotalAdsReplaced(),
      to: themeOptionsPage,
      tm: themePopupMenu,
      sy: settingsObj.sync_settings ? '1' : '0',
      ir: channels.isAnyEnabled() ? '1' : '0',
      cir: channels.channelGuide[channels.getIdByName('CustomChannel')].enabled ? '1' : '0',
      tca: settingsObj.twitch_channel_allowlist ? '1' : '0',
      sup: settingsObj.suppress_update_page ? '1' : '0',
      ss: settingsObj.suppress_surveys ? '1' : '0',
      sfrp: settingsObj.suppress_first_run_page ? '1' : '0',
      opm: settingsObj.onpageMessages ? '1' : '0',
      subs: subsStr,
    };

    if (typeof LocalCDN !== 'undefined') {
      data.cdnr = await LocalCDN.getRedirectCount();
      data.cdnd = await LocalCDN.getDataCount();
    } else {
      data.cdnr = 0;
      data.cdnd = 0;
    }

    // only on Chrome, Edge, or Firefox
    if ((this.flavor === 'E' || this.flavor === 'CM' || this.flavor === 'F') && prefs/* Prefs.blocked_total */.B.blocked_total) {
      data.b = prefs/* Prefs.blocked_total */.B.blocked_total;
    }
    if (browser.runtime.id) {
      data.extid = browser.runtime.id;
    }
    const subs = await subscriptionadapter/* default.getAllSubscriptionsMinusText */.Z.getAllSubscriptionsMinusText();
    if (subs) {
      const aa = subs.acceptable_ads;
      const aaPrivacy = subs.acceptable_ads_privacy;

      if (!aa && !aaPrivacy) {
        data.aa = 'u'; // Both filter lists unavailable
      } else if (aa.subscribed) {
        data.aa = '1';
      } else if (aaPrivacy.subscribed) {
        data.aa = '2';
      } else if (!aa.subscribed && !aaPrivacy.subscribed) {
        data.aa = '0'; // Both filter lists unsubscribed
      }
    }

    data.crctotal = 0;
    data.crcsnippet = 0;
    data.crcelemhideemulation = 0;
    data.crcelemhideexception = 0;
    data.crcelemhide = 0;
    data.crcallowing = 0;
    data.crcblocking = 0;
    data.crccomment = 0;
    data.crcinvalid = 0;

    const userFilters = await ewe_api.filters.getUserFilters();
    for (let j = 0; j < userFilters.length; j++) {
      const filter = userFilters[j];
      data[`crc${filter.type}`] += 1;
      data.crctotal += 1;
    }

    data.dc = this.dataCorrupt ? '1' : '0';
    data.st = survey/* default.types */.Z.types() + ctaabmanager/* default.types */.Z.types();
    if (browser.permissions && browser.permissions.getAll) {
      const allPermissions = await browser.permissions.getAll();
      data.dhp = allPermissions.origins && allPermissions.origins.includes('<all_urls>') ? '1' : '0';
    } else {
      data.dhp = '1';
    }
    return data;
  }

  // Return the number of milliseconds until the next scheduled ping.
  async millisTillNextPing() {
    // If we've detected data corruption issues,
    // then default to a 55 minute ping interval
    if (this.dataCorrupt) {
      return FiftyFiveMinutes;
    }
    const response = await browser.storage.local.get(this.nextRequestTimeStorageKey);
    if (!response[this.nextRequestTimeStorageKey]) {
      this.firstRun = true;
    }
    let nextPingTime = response[this.nextRequestTimeStorageKey];
    if (typeof nextPingTime !== 'number' || Number.isNaN(nextPingTime)) {
      nextPingTime = 0;
    }
    if (nextPingTime === 0 && this.firstRun) {
      return (1000 * 60);
    }
    // if we don't have a 'next ping time', or it's not a valid number,
    // default to 55 minute ping interval
    if (
      typeof nextPingTime !== 'number'
      || nextPingTime === 0
      || Number.isNaN(nextPingTime)
    ) {
      return FiftyFiveMinutes;
    }
    return (nextPingTime - Date.now());
  }

  async sleepThenPing() {
    const delay = await this.millisTillNextPing();
    browser.alarms.create(this.alarmName, { delayInMinutes: (delay / 1000 / 60) });
  }


  async start() {
    await this.loadUserID();
    // Do 'stuff' when we're first installed...
    // - send a message
    const response = await browser.storage.local.get(this.totalRequestsStorageKey);
    if (!response[this.totalRequestsStorageKey]) {
      if (browser.management && browser.management.getSelf) {
        const info = await browser.management.getSelf();
        if (info) {
          servermessages/* default.recordGeneralMessage */.Z.recordGeneralMessage(`new_install_${info.installType}`);
        } else {
          servermessages/* default.recordGeneralMessage */.Z.recordGeneralMessage('new_install');
        }
      } else {
        servermessages/* default.recordGeneralMessage */.Z.recordGeneralMessage('new_install');
      }
    }
    // This will sleep, then ping, then schedule a new ping, then
    // call itself to start the process over again.
    await this.sleepThenPing();
    this.cleanUpLocalStorage();
  }

  async untilLoaded() {
    await this.loadUserID();
    return this.userId;
  }

  get browser() {
    return ({
      E: 'Chrome',
      CM: 'Edge',
      F: 'Firefox',
    })[this.flavor];
  }
}

/* harmony default export */ const telemetry_base = (TelemetryBase);

// EXTERNAL MODULE: ./adblock-betafish/fetch-util.js
var fetch_util = __webpack_require__(2379);
;// CONCATENATED MODULE: ./adblock-betafish/telemetry/background/telemetry-ping.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, LocalCDN */







const telemetryNotifier = new events/* EventEmitter */.v();

class Telemetry extends telemetry_base {
  // Called just after we ping the server, to schedule our next ping.
  scheduleNextPing() {
    return new Promise(async (resolve) => {
      const response = await browser.storage.local.get(this.totalRequestsStorageKey);
      let totalPings = response[this.totalRequestsStorageKey];
      if (typeof totalPings !== 'number' || Number.isNaN(totalPings)) {
        totalPings = 0;
      }
      totalPings += 1;
      (0,bg_functions/* chromeStorageSetHelper */.rJ)(this.totalRequestsStorageKey, totalPings);

      let delayHours;
      if (totalPings === 1) { // Ping one hour after install
        delayHours = 1;
      } else if (totalPings < 9) { // Then every day for a week
        delayHours = 24;
      } else { // Then weekly forever
        delayHours = 24 * 7;
      }
      const millis = 1000 * 60 * 60 * delayHours;
      const nextPingTime = Date.now() + millis;
      (0,bg_functions/* chromeStorageSetHelper */.rJ)(this.nextRequestTimeStorageKey, nextPingTime, (error) => {
        this.dataCorrupt = !!error;
        resolve();
      });
    });
  }

  sendPingData(pingData) {
    return new Promise(async (resolve) => {
      const response = await (0,fetch_util/* default */.Z)(this.hostURL, pingData)
        // Send any network errors during the ping fetch to a dedicated log server
        // to help us determine why there's been a drop in ping requests
        // See https://gitlab.com/adblockinc/ext/adblock/adblock/-/issues/136
        .catch((error) => {
          servermessages/* default.sendMessageToBackupLogServer */.Z.sendMessageToBackupLogServer('fetch_error', error.toString());
          (0,bg_functions/* log */.cM)('ping server returned error: ', error);
        });
      if (response && response.ok) {
        telemetryNotifier.emit('ping.complete');
      } else {
        (0,bg_functions/* log */.cM)('Ping server returned error: ', (response && response.statusText));
      }
      resolve(pingData);
    });
  }

  // Tell the server we exist.
  async pingNow() {
    const pingData = await this.getTelemetryData();
    if (!pingData.u) {
      return pingData;
    }
    // attempt to stop users that are pinging us 'a lot'
    // by checking the current ping count,
    // if the ping count is above a theshold,
    // then only ping 'occasionally'
    if (pingData.pc > 5000) {
      if (pingData.pc > 5000 && pingData.pc < 100000 && ((pingData.pc % 5000) !== 0)) {
        return pingData;
      }
      if (pingData.pc >= 100000 && ((pingData.pc % 50000) !== 0)) {
        return pingData;
      }
    }
    pingData.cmd = 'ping';
    if (browser.management && browser.management.getSelf) {
      const info = await browser.management.getSelf();
      pingData.it = info.installType.charAt(0);
    }
    if (typeof LocalCDN !== 'undefined') {
      const missedVersions = LocalCDN.getMissedVersions();
      if (missedVersions) {
        servermessages/* default.recordGeneralMessage */.Z.recordGeneralMessage('cdn_miss_stats', undefined, { cdnm: missedVersions });
      }
    }
    return this.sendPingData(pingData);
  }
}

/* harmony default export */ const telemetry_ping = (Telemetry);

;// CONCATENATED MODULE: ./adblock-betafish/telemetry/background/telemetry-ipm.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser */









class IPMTelemetry extends telemetry_base {
  // Called just after we ping the server, to schedule our next ping.
  scheduleNextPing() {
    return new Promise(async (resolve) => {
      const response = await browser.storage.local.get(this.totalRequestsStorageKey);
      let totalPings = response[this.totalRequestsStorageKey];
      if (typeof totalPings !== 'number' || Number.isNaN(totalPings)) {
        totalPings = 0;
      }
      totalPings += 1;
      (0,bg_functions/* chromeStorageSetHelper */.rJ)(this.totalRequestsStorageKey, totalPings);

      let delayHours;
      if (totalPings === 1) { // Ping one hour after install
        delayHours = 1;
      } else { // Then every day
        delayHours = 24;
      }
      const millis = 1000 * 60 * 60 * delayHours;
      const nextPingTime = Date.now() + millis;
      (0,bg_functions/* chromeStorageSetHelper */.rJ)(this.nextRequestTimeStorageKey, nextPingTime, (error) => {
        this.dataCorrupt = !!error;
        resolve();
      });
    });
  }

  sendPingData(pingData) {
    return new Promise(async (resolve) => {
      const response = await (0,fetch_util/* default */.Z)(this.hostURL, pingData).catch((error) => {
        (0,bg_functions/* log */.cM)('ipm ping error', error);
        resolve(pingData);
      });
      if (response && response.ok) {
        telemetryNotifier.emit('ipm.ping.complete');
        const text = await response.text();
        survey/* default.maybeSurvey */.Z.maybeSurvey(text);
        ctaabmanager/* default.maybeCtaAB */.Z.maybeCtaAB(text);
      } else {
        (0,bg_functions/* log */.cM)('IPM server returned error: ', (response && response.statusText));
      }
      resolve(pingData);
    });
  }

  async pingNow() {
    const pingData = await this.getTelemetryData();
    if (!pingData.u) {
      return pingData;
    }
    // attempt to stop users that are pinging us 'a lot'
    // by checking the current ping count,
    // if the ping count is above a theshold,
    // then only ping 'occasionally'
    if (pingData.pc > 5000) {
      if (pingData.pc > 5000 && pingData.pc < 100000 && ((pingData.pc % 5000) !== 0)) {
        return pingData;
      }
      if (pingData.pc >= 100000 && ((pingData.pc % 50000) !== 0)) {
        return pingData;
      }
    }
    pingData.cmd = 'ping';
    if (browser.management && browser.management.getSelf) {
      const info = await browser.management.getSelf();
      pingData.it = info.installType.charAt(0);
    }
    return this.sendPingData(pingData);
  }
}

/* harmony default export */ const telemetry_ipm = (IPMTelemetry);

;// CONCATENATED MODULE: ./adblock-betafish/telemetry/background/telemetry.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */




const IPM = new telemetry_ipm('total_ipm_pings', 'next_ipm_ping_time', 'ipm_pingalarm', 'https://ipm.adblock.dev/api/stats');
const TELEMETRY = new telemetry_ping('total_pings', 'next_ping_time', 'pingalarm', 'https://ping.getadblock.com/stats/');

;// CONCATENATED MODULE: ./adblock-betafish/telemetry/background/index.js
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */





/***/ }),

/***/ 1483:
/***/ ((__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3817);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _vendor_adblockplusui_adblockpluschrome_lib_browserAction__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3265);
/* harmony import */ var _prefs_settings__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2630);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, ext,
   addCustomFilter, */





const twitchChannelNamePages = new Map();

// On single page sites, such as Twitch, that update the URL using the History API pushState(),
// they don't actually load a new page, we need to get notified when this happens
// and update the URLs in the Page and Frame objects
const twitchHistoryStateUpdateHandler = async function (details) {
  if (details
      && Object.prototype.hasOwnProperty.call(details, 'frameId')
      && Object.prototype.hasOwnProperty.call(details, 'tabId')
      && Object.prototype.hasOwnProperty.call(details, 'url')
      && details.transitionType === 'link') {
    const myURL = new URL(details.url);
    if (myURL.hostname === 'www.twitch.tv') {
      const myFrame = ext.getFrame(details.tabId, details.frameId);
      const myPage = ext.getPage(details.tabId);
      myPage._url = myURL;
      myFrame.url = myURL;
      myFrame._url = myURL;
      if (await _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__.filters.getAllowingFilters(myPage.id).length) {
        (0,_vendor_adblockplusui_adblockpluschrome_lib_browserAction__WEBPACK_IMPORTED_MODULE_1__/* .setBadge */ .q_)(details.tabId, { number: '' });
      }
    }
  }
};

// Creates a custom filter entry that whitelists a YouTube channel
// Inputs: url:string url of the page
// Returns: null if successful, otherwise an exception
const createWhitelistFilterForTwitchChannel = function (url, origin) {
  let twitchChannel;
  if (/ab_channel=/.test(url)) {
    [, twitchChannel] = url.match(/ab_channel=([^]*)/);
  } else {
    twitchChannel = url.split('/').pop();
  }
  if (twitchChannel) {
    const filter = `@@||twitch.tv/*${twitchChannel}^$document`;
    return addCustomFilter(filter, origin);
  }
  return undefined;
};

const twitchMessageHandler = function (message, sender, sendResponse) {
  if (message.command === 'createWhitelistFilterForTwitchChannel' && message.url) {
    sendResponse(createWhitelistFilterForTwitchChannel(message.url, message.origin));
    return;
  }
  if (message.command === 'updateTwitchChannelName' && message.channelName) {
    twitchChannelNamePages.set(sender.tab.id, message.channelName);
    sendResponse({});
  }
};

const addTwitchAllowlistListeners = function () {
  twitchChannelNamePages.clear();
  browser.runtime.onMessage.addListener(twitchMessageHandler);
  browser.webNavigation.onHistoryStateUpdated.addListener(twitchHistoryStateUpdateHandler);
};

const removeTwitchAllowlistListeners = function () {
  twitchChannelNamePages.clear();
  browser.runtime.onMessage.removeListener(twitchMessageHandler);
  browser.webNavigation.onHistoryStateUpdated.removeListener(twitchHistoryStateUpdateHandler);
};

_prefs_settings__WEBPACK_IMPORTED_MODULE_2__/* .settings.onload */ .Xd.onload().then(() => {
  if ((0,_prefs_settings__WEBPACK_IMPORTED_MODULE_2__/* .getSettings */ .Gw)().twitch_channel_allowlist) {
    addTwitchAllowlistListeners();
  }
});

// eslint-disable-next-line no-restricted-globals
Object.assign(self, {
  addTwitchAllowlistListeners,
  removeTwitchAllowlistListeners,
  twitchChannelNamePages,
});


/***/ }),

/***/ 2028:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "E_": () => (/* binding */ sessionStorageGet),
/* harmony export */   "PW": () => (/* binding */ logging),
/* harmony export */   "Qr": () => (/* binding */ isEmptyObject),
/* harmony export */   "Yv": () => (/* binding */ createFilterMetaData),
/* harmony export */   "bg": () => (/* binding */ sessionStorageSet),
/* harmony export */   "cM": () => (/* binding */ log),
/* harmony export */   "eV": () => (/* binding */ storageSet),
/* harmony export */   "he": () => (/* binding */ parseUri),
/* harmony export */   "l7": () => (/* binding */ extend),
/* harmony export */   "lE": () => (/* binding */ chromeStorageDeleteHelper),
/* harmony export */   "nX": () => (/* binding */ chromeStorageGetHelper),
/* harmony export */   "pN": () => (/* binding */ determineUserLanguage),
/* harmony export */   "qo": () => (/* binding */ reloadOptionsPageTabs),
/* harmony export */   "rJ": () => (/* binding */ chromeStorageSetHelper),
/* harmony export */   "ww": () => (/* binding */ migrateData)
/* harmony export */ });
/* unused harmony export storageGet */
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, log, License, runBandaids, openTab */

// Set to true to get noisier console.log statements
const VERBOSE_DEBUG = false;
/* eslint-disable import/no-mutable-exports */
let log = function log() {
};
// Enabled in adblock_start_common.js and background.js if the user wants
const logging = function (enabled) {
  if (enabled) {
    /* eslint-disable no-shadow */
    log = function log(...args) {
      if (VERBOSE_DEBUG || args[0] !== '[DEBUG]') { // comment out for verbosity
        // eslint-disable-next-line no-console
        console.log(...args);
      }
    };
  } else {
    /* eslint-disable no-shadow */
    log = function log() {
    };
  }
};
logging(false); // disabled by default


// Determine what language the user's browser is set to use
const determineUserLanguage = function () {
  return browser.i18n.getUILanguage();
};

// Parse a URL. Based upon http://blog.stevenlevithan.com/archives/parseuri
// parseUri 1.2.2, (c) Steven Levithan <stevenlevithan.com>, MIT License
// Inputs: url: the URL you want to parse
// Outputs: object containing all parts of |url| as attributes
const parseUriRegEx = /^(([^:]+(?::|$))(?:(?:\w+:)?\/\/)?(?:[^:@/]*(?::[^:@/]*)?@)?(([^:/?#]*)(?::(\d*))?))((?:[^?#/]*\/)*[^?#]*)(\?[^#]*)?(#.*)?/;
const parseUri = function (url) {
  const matches = parseUriRegEx.exec(url);

  // The key values are identical to the JS location object values for that key
  const keys = ['href', 'origin', 'protocol', 'host', 'hostname', 'port',
    'pathname', 'search', 'hash'];
  const uri = {};
  for (let i = 0; (matches && i < keys.length); i++) {
    uri[keys[i]] = matches[i] || '';
  }
  return uri;
};

// Parses the search part of a URL into a key: value object.
// e.g., ?hello=world&ext=adblock would become {hello:"world", ext:"adblock"}
// Inputs: search: the search query of a URL. Must have &-separated values.
parseUri.parseSearch = function parseSearch(searchQuery) {
  const params = {};
  let search = searchQuery;
  let pair;

  // Fails if a key exists twice (e.g., ?a=foo&a=bar would return {a:"bar"}
  search = search.substring(search.indexOf('?') + 1).split('&');

  for (let i = 0; i < search.length; i++) {
    pair = search[i].split('=');
    if (pair[0] && !pair[1]) {
      pair[1] = '';
    }
    const pairKey = decodeURIComponent(pair[0]);
    const pairValue = decodeURIComponent(pair[1]);
    if (pairKey && pairValue !== 'undefined') {
      params[pairKey] = pairValue;
    }
  }
  return params;
};

// Strip third+ level domain names from the domain and return the result.
// Inputs: domain: the domain that should be parsed
// keepDot: true if trailing dots should be preserved in the domain
// Returns: the parsed domain
parseUri.secondLevelDomainOnly = function stripThirdPlusLevelDomain(domain, keepDot) {
  if (domain) {
    const match = domain.match(/([^.]+\.(?:co\.)?[^.]+)\.?$/) || [domain, domain];
    return match[keepDot ? 0 : 1].toLowerCase();
  }

  return domain;
};

const sessionStorageMap = new Map();
//
// Inputs: key:string.
// Returns value if key exists, else undefined.
/**
 * @deprecated consider using SessionStorage
 */
const sessionStorageGet = function (key) {
  return sessionStorageMap.get(key);
};

// Inputs: key:string, value:object.
// If value === undefined, removes key from storage.
// Returns undefined.
/**
 * @deprecated consider using SessionStorage
 */
const sessionStorageSet = function (key, value) {
  if (value === undefined) {
    sessionStorageMap.delete(key);
    return;
  }
  sessionStorageMap.set(key, value);
};


// Inputs: key:string.
// Returns object from localStorage.
// The following two functions should only be used when
// multiple 'sets' & 'gets' may occur in immediately preceding each other
// browser.storage.local.get & set instead
// deprecated on background / service worker pages
/**
 * @deprecated consider using browser.storage.local
 */
const storageGet = function (key) {
  if (typeof localStorage === 'undefined') {
    return undefined;
  }
  const store = localStorage;
  const json = store.getItem(key);
  if (json == null) {
    return undefined;
  }
  try {
    return JSON.parse(json);
  } catch (e) {
    log(`Couldn't parse json for ${key}`, e);
    return undefined;
  }
};

// Inputs: key:string, value:object.
// If value === undefined, removes key from storage.
// Returns undefined.
/**
 * @deprecated consider using browser.storage.local
 */
const storageSet = function (key, value) {
  if (typeof localStorage === 'undefined') {
    return;
  }
  const store = localStorage;
  if (value === undefined) {
    store.removeItem(key);
    return;
  }
  try {
    store.setItem(key, JSON.stringify(value));
  } catch (ex) {
    // eslint-disable-next-line no-console
    console.log(ex);
  }
};

const chromeStorageSetHelper = function (key, value, callback) {
  const items = {};
  items[key] = value;
  browser.storage.local.set(items).then(() => {
    if (typeof callback === 'function') {
      callback();
    }
  }).catch((error) => {
    if (typeof callback === 'function') {
      callback(error);
    }
  });
};

const chromeStorageGetHelper = function (storageKey) {
  return new Promise(((resolve, reject) => {
    browser.storage.local.get(storageKey).then((items) => {
      resolve(items[storageKey]);
    }).catch((error) => {
      // eslint-disable-next-line no-console
      console.error(error);
      reject(error);
    });
  }));
};

const chromeStorageDeleteHelper = function (key) {
  return browser.storage.local.remove(key);
};

// Migrate any stored data from localStorage to
// chrome.storage.local
// if the data is successfully migrated to chrome.storage,
// then the original data in localStorage is removed
// Inputs:
//   key: string - the data storage key
//   parseData: Boolean - indicates if the stored data should be parse prior to being saved
//                        in chrome.storage
const migrateData = function (key, parseData) {
  return new Promise((resolve, reject) => {
    /* eslint-disable no-restricted-globals */
    if (typeof self.localStorage === 'undefined') {
      resolve();
    }
    let data = localStorage.getItem(key);
    if (data) {
      if (parseData) {
        data = JSON.parse(data);
      }

      chromeStorageSetHelper(key, data, (error) => {
        if (!error) {
          if (typeof localStorage !== 'undefined') {
            localStorage.removeItem(key);
          }
          resolve();
        } else {
          reject(error);
        }
      });
    } else {
      resolve();
    }
  });
};

const reloadOptionsPageTabs = function () {
  const optionTabQuery = {
    url: `chrome-extension://${browser.runtime.id}/options.html*`,
  };
  browser.tabs.query(optionTabQuery).then((tabs) => {
    for (const i in tabs) {
      browser.tabs.reload(tabs[i].id);
    }
  });
};

// eslint-disable-next-line max-len
const isEmptyObject = obj => !!(obj && Object.keys(obj).length === 0 && obj.constructor === Object);

// mimics jQuery's functionality
function extend(primaryArg, ...args) {
  const obj = primaryArg;
  for (let i = 0; i < args.length; i++) {
    for (const key in args[i]) {
      if (Object.prototype.hasOwnProperty.call(args[i], key)) {
        obj[key] = args[i][key];
      }
    }
  }
  return obj;
}

// Creates the meta data to be saved with a users custom filter rules
// Return a new object that the following structure:
// created - a Integer representing the number of milliseconds elapsed
//           since January 1, 1970 00:00:00 UTC.
// origin - a String representing the method that user added the filter rule
//
// Inputs: origin? - optional value
const createFilterMetaData = (origin) => {
  const data = { created: Date.now() };
  if (origin) {
    data.origin = origin;
  }
  return data;
};


/***/ }),

/***/ 8762:
/***/ ((__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3817);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__);
/*
 * This file is part of AdBlock  <https://getadblock.com/>,
 * Copyright (C) 2013-present  Adblock, Inc.
 *
 * AdBlock is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * AdBlock is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with AdBlock.  If not, see <http://www.gnu.org/licenses/>.
 */

/* For ESLint: List any global identifiers used in this file below */
/* global browser, getSettings, settings, ext, setSetting,
   addCustomFilter, getUserFilters,
   isWhitelistFilter */



const ytChannelNamePages = new Map();

const webRequestFilter = {
  url:
  [
    { hostEquals: 'www.youtube.com' },
  ],
};

let lastInjectedTimestamp = 10000;

// Creates a custom filter entry that whitelists a YouTube channel
// Inputs: channelName:string parsed channel name
// Returns:  null if successful, otherwise an exception
const createAllowlistFilterForYoutubeChannelName = function (channelName, origin) {
  if (channelName) {
    const filterText = `@@||www.youtube.com/*${channelName}|$document`;
    return addCustomFilter(filterText, origin);
  }
  return undefined;
};

// Creates a custom filter entry that whitelists a YouTube channel
// Inputs: url:string url of the page
// Returns: null if successful, otherwise an exception
const createWhitelistFilterForYoutubeChannel = function (url, origin) {
  let ytChannel;
  if (/ab_channel=/.test(url)) {
    [, ytChannel] = url.match(/ab_channel=([^]*)/);
  } else {
    ytChannel = url.split('/').pop();
  }
  if (ytChannel) {
    return createAllowlistFilterForYoutubeChannelName(ytChannel, origin);
  }
  return undefined;
};

const removeAllowlistFilterForYoutubeChannel = function (text) {
  if (isWhitelistFilter(text)) {
    _vendor_webext_sdk_dist_ewe_api__WEBPACK_IMPORTED_MODULE_0__.filters.remove([text]);
  }
};

// inject the manage YT subscription
const injectManagedContentScript = function (details, historyUpdated) {
  const { tabId } = details;
  browser.tabs.sendMessage(tabId, { command: 'ping_yt_manage_cs' }).then((pingResponse) => {
    // Since the onHistoryStateUpdated may get called more than once with the exact same data,
    // check the timestamps, and only inject the content script once
    const diff = details.timeStamp - lastInjectedTimestamp;
    if (pingResponse && pingResponse.status === 'yes') {
      lastInjectedTimestamp = details.timeStamp;
      browser.tabs.sendMessage(tabId, { command: 'addYouTubeOnPageIcons', historyUpdated });
    } else if (diff > 100) { // check if the timestamp difference is more than 100 ms
      lastInjectedTimestamp = details.timeStamp;
      browser.tabs.executeScript(tabId, {
        file: 'purify.min.js',
        allFrames: false,
        runAt: 'document_start',
      }).then(() => {
        browser.tabs.executeScript(tabId, {
          file: 'adblock-yt-manage-cs.js',
          allFrames: false,
          runAt: 'document_start',
        }).then(() => {
          browser.tabs.sendMessage(tabId, { command: 'addYouTubeOnPageIcons', historyUpdated });
        });
      });
    }
  });
};

const managedSubPageCompleted = function (details) {
  const theURL = new URL(details.url);
  if (theURL.pathname === '/feed/channels') {
    injectManagedContentScript(details);
  }
};

// On single page sites, such as YouTube, that update the URL using the History API pushState(),
// they don't actually load a new page, we need to get notified when this happens
// and update the URLs in the Page and Frame objects
const ytHistoryHandler = function (details) {
  if (details
      && Object.prototype.hasOwnProperty.call(details, 'tabId')
      && Object.prototype.hasOwnProperty.call(details, 'url')
      && details.transitionType === 'link') {
    const myURL = new URL(details.url);
    if (getSettings().youtube_manage_subscribed && myURL.pathname === '/feed/channels') {
      // check if the user clicked the back / forward buttons, if so,
      // the data on the page is already loaded,
      // so the content script does not have to wait for it to load.
      injectManagedContentScript(details, !(details.transitionQualifiers && details.transitionQualifiers.includes('forward_back')));
    }
  }
};

const addYTChannelListeners = function () {
  browser.webNavigation.onHistoryStateUpdated.addListener(ytHistoryHandler, webRequestFilter);
  if (getSettings().youtube_manage_subscribed) {
    browser.webNavigation.onCompleted.addListener(managedSubPageCompleted, webRequestFilter);
  }
};

const removeYTChannelListeners = function () {
  browser.webNavigation.onHistoryStateUpdated.removeListener(ytHistoryHandler, webRequestFilter);
  browser.webNavigation.onCompleted.removeListener(managedSubPageCompleted, webRequestFilter);
};

settings.onload().then(() => {
  if (getSettings().youtube_channel_whitelist) {
    addYTChannelListeners();
  }
});

const openYTManagedSubPage = function () {
  browser.tabs.create({ url: 'https://www.youtube.com/feed/channels' });
};

const getAllAdsAllowedUserFilters = async function () {
  const userFilters = await getUserFilters();
  const adsAllowedUserFilters = [];
  for (let inx = 0; inx < userFilters.length; inx++) {
    const filter = userFilters[inx];
    if (isWhitelistFilter(filter.text) && filter.text && filter.text.includes('youtube.com')) {
      adsAllowedUserFilters.push(filter.text);
    }
  }
  return adsAllowedUserFilters;
};

let previousYTchannelId = '';
let previousYTuserId = '';

// Listen for the message from the content scripts
browser.runtime.onMessage.addListener((message, sender, sendResponse) => {
  if (message.command === 'updateYouTubeChannelName' && message.channelName) {
    ytChannelNamePages.set(sender.tab.id, message.channelName);
    sendResponse({});
    return;
  }
  if (message.command === 'get_channel_name_by_channel_id' && message.channelId) {
    if (previousYTchannelId !== message.channelId) {
      previousYTchannelId = message.channelId;
      const xhr = new XMLHttpRequest();
      const { channelId } = message;
      const key = atob('QUl6YVN5QzJKMG5lbkhJZ083amZaUUYwaVdaN3BKd3dsMFczdUlz');
      const url = 'https://www.googleapis.com/youtube/v3/channels';
      xhr.open('GET', `${url}?part=snippet&id=${channelId}&key=${key}`);
      xhr.onload = function xhrOnload() {
        if (xhr.readyState === 4 && xhr.status === 200) {
          const json = JSON.parse(xhr.response);
          // Got name of the channel
          if (json && json.items && json.items[0]) {
            const channelName = json.items[0].snippet.title;
            ytChannelNamePages.set(sender.tab.id, channelName);
            browser.tabs.sendMessage(sender.tab.id, {
              command: 'updateURLWithYouTubeChannelName',
              channelName,
            });
          }
        }
      };
      xhr.send();
      sendResponse({});
      return;
    }
    browser.tabs.sendMessage(sender.tab.id, {
      command: 'updateURLWithYouTubeChannelName',
      channelName: ytChannelNamePages.get(sender.tab.id),
    });
    sendResponse({});
    return;
  }
  if (message.command === 'get_channel_name_by_user_id' && message.userId) {
    if (previousYTuserId !== message.userId) {
      previousYTuserId = message.userId;
      const xhr = new XMLHttpRequest();
      const { userId } = message;
      const key = atob('QUl6YVN5QzJKMG5lbkhJZ083amZaUUYwaVdaN3BKd3dsMFczdUlz');
      const url = 'https://www.googleapis.com/youtube/v3/channels';
      xhr.open('GET', `${url}?part=snippet&forUsername=${userId}&key=${key}`);
      xhr.onload = function xhrOnload() {
        if (xhr.readyState === 4 && xhr.status === 200) {
          const json = JSON.parse(xhr.response);
          // Got name of the channel
          if (json && json.items && json.items[0]) {
            const channelName = json.items[0].snippet.title;
            ytChannelNamePages.set(sender.tab.id, channelName);
            browser.tabs.sendMessage(sender.tab.id, {
              command: 'updateURLWithYouTubeChannelName',
              channelName,
            });
          }
        }
      };
      xhr.send();
      sendResponse({});
    } else {
      browser.tabs.sendMessage(sender.tab.id, {
        command: 'updateURLWithYouTubeChannelName',
        channelName: ytChannelNamePages.get(sender.tab.id),
      });
      sendResponse({});
    }
  }
  if (message.command === 'getAllAdsAllowedUserFilters') {
    /* eslint-disable consistent-return */
    return getAllAdsAllowedUserFilters();
  }
  if (message.command === 'removeAllowlistFilterForYoutubeChannel' && message.text) {
    removeAllowlistFilterForYoutubeChannel(message.text);
    sendResponse({});
  }
  if (message.command === 'createWhitelistFilterForYoutubeChannel' && message.url) {
    sendResponse(createWhitelistFilterForYoutubeChannel(message.url, message.origin));
  }
  if (message.command === 'createAllowlistFilterForYoutubeChannelName' && message.channelName) {
    sendResponse(createAllowlistFilterForYoutubeChannelName(message.channelName, message.origin));
  }
  if (message.command === 'blockAllSubscribedChannel' && message.channelNames) {
    const { channelNames } = message;
    const parsedChannelNames = [];
    const userFilters = getAllAdsAllowedUserFilters();
    for (const [channelName] of Object.entries(channelNames)) {
      const name = channelNames[channelName].parsedChannelName;
      parsedChannelNames.push(name);
      for (let inx = 0; inx < userFilters.length; inx++) {
        const filterText = userFilters[inx];
        if (filterText.indexOf(name) > 1) {
          removeAllowlistFilterForYoutubeChannel(filterText);
        }
      }
    }
    sendResponse({});
  }
  if (message.command === 'allowAllSubscribedChannel' && message.channelNames) {
    const { channelNames } = message;
    for (const [channelName] of Object.entries(channelNames)) {
      const name = channelNames[channelName].parsedChannelName;
      createAllowlistFilterForYoutubeChannelName(name);
    }
    sendResponse({});
  }
});

// eslint-disable-next-line no-restricted-globals
Object.assign(self, {
  addYTChannelListeners,
  removeYTChannelListeners,
  ytChannelNamePages,
  openYTManagedSubPage,
});


/***/ }),

/***/ 187:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "addonName": () => (/* binding */ addonName),
/* harmony export */   "addonVersion": () => (/* binding */ addonVersion),
/* harmony export */   "application": () => (/* binding */ application),
/* harmony export */   "applicationVersion": () => (/* binding */ applicationVersion),
/* harmony export */   "platform": () => (/* binding */ platform),
/* harmony export */   "platformVersion": () => (/* binding */ platformVersion)
/* harmony export */ });
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

let addonName = "adblockchrome";
let addonVersion = "5.6.0";
let application = null;
let applicationVersion;
let platform = "chromium";
let platformVersion = null;

let regexp = /(\S+)\/(\S+)(?:\s*\(.*?\))?/g;
let match;

while (match = regexp.exec(navigator.userAgent))
{
  let app = match[1];
  let ver = match[2];

  if (app == "Chrome")
  {
    platformVersion = ver;
  }
  else if (app != "Mozilla" && app != "AppleWebKit" && app != "Safari")
  {
    // For compatibility with legacy websites, Chrome's UA
    // also includes a Mozilla, AppleWebKit and Safari token.
    // Any further name/version pair indicates a fork.
    application = app == "OPR" ? "opera" : app.toLowerCase();
    applicationVersion = ver;
  }
}

// not a Chromium-based UA, probably modifed by the user
if (!platformVersion)
{
  application = "unknown";
  applicationVersion = platformVersion = "0";
}

// no additional name/version, so this is upstream Chrome
if (!application)
{
  application = "chrome";
  applicationVersion = platformVersion;
}


/***/ }),

/***/ 4043:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "addonName": () => (/* binding */ addonName),
/* harmony export */   "addonVersion": () => (/* binding */ addonVersion),
/* harmony export */   "application": () => (/* binding */ application),
/* harmony export */   "applicationVersion": () => (/* binding */ applicationVersion),
/* harmony export */   "platform": () => (/* binding */ platform),
/* harmony export */   "platformVersion": () => (/* binding */ platformVersion)
/* harmony export */ });
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

let addonName = "adblockchrome";
let addonVersion = "5.6.0";
let application = null;
let applicationVersion;
let platform = "chromium";
let platformVersion = null;

let regexp = /(\S+)\/(\S+)(?:\s*\(.*?\))?/g;
let match;

while (match = regexp.exec(navigator.userAgent))
{
  let app = match[1];
  let ver = match[2];

  if (app == "Chrome")
  {
    platformVersion = ver;
  }
  // For compatibility with legacy websites, Chrome's UA
  // also includes a Mozilla, AppleWebKit and Safari token.
  // Any further name/version pair indicates a fork.
  else if (app != "Mozilla" && app != "AppleWebKit" && app != "Safari")
  {
    if (app == "Edg")
      application = "edge";
    else if (app == "OPR")
      application = "opera";
    else
      application = app.toLowerCase();

    applicationVersion = ver;
  }
}

// not a Chromium-based UA, probably modifed by the user
if (!platformVersion)
{
  application = "unknown";
  applicationVersion = platformVersion = "0";
}

// no additional name/version, so this is upstream Chrome
if (!application)
{
  application = "chrome";
  applicationVersion = platformVersion;
}


/***/ }),

/***/ 808:
/***/ ((__unused_webpack_module, exports) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * A `Cache` object represents a cache of arbitrary data.
 * @package
 */
exports.Cache = class Cache extends Map {
  /**
   * Creates a cache.
   * @param {number} capacity The maximum number of entries that can exist in
   *   the cache.
   */
  constructor(capacity) {
    // Note: This check works for non-number values.
    if (!(capacity >= 1))
      throw new Error("capacity must be a positive number.");

    super();
    this._capacity = capacity;
  }

  /**
   * Writes an entry to the cache.
   *
   * If the cache has reached the specified maximum number of entries, all the
   * old entries are cleared first.
   *
   * @param {?*} key The key for the entry.
   * @param {?*} value The value of the entry.
   */
  set(key, value) {
    // To prevent logical errors, neither key nor value is allowed to be
    // undefined.
    if (typeof key == "undefined")
      throw new Error("key must not be undefined.");

    if (typeof value == "undefined")
      throw new Error("value must not be undefined.");

    if (this.size == this._capacity && !this.has(key))
      this.clear();

    super.set(key, value);
  }
};


/***/ }),

/***/ 7610:
/***/ ((__unused_webpack_module, exports) => {

"use strict";
var __webpack_unused_export__;
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



let contentTypes =
/**
 * Content types for request blocking and allowing (allowlisting).
 *
 * There are two kinds of content types: resource types, and special
 * (non-resource) types.
 *
 * Resource types include web resources like scripts, images, and so on.
 *
 * Special types include filter options for popup blocking and CSP header
 * injection as well as flags for allowing documents.
 *
 * By default a filter matches any resource type, but if a filter has an
 * explicit resource type, special option, or allowing flag, like
 * `$script`, `$popup`, or `$elemhide`, then it matches only the given type,
 * option, or flag.
 *
 * @type {object}
 *
 * @public
 */
exports.Tr = {
  // Types of web resources.
  OTHER: 1,
  SCRIPT: 2,
  IMAGE: 4,
  STYLESHEET: 8,
  OBJECT: 16,
  SUBDOCUMENT: 32,
  WEBSOCKET: 128,
  WEBRTC: 256,
  PING: 1024,
  XMLHTTPREQUEST: 2048, // 1 << 11

  MEDIA: 16384,
  FONT: 32768, // 1 << 15

  // Special filter options.
  POPUP: 1 << 24,
  CSP: 1 << 25,
  HEADER: 1 << 26,

  // Allowing flags.
  DOCUMENT: 1 << 27,
  GENERICBLOCK: 1 << 28,
  ELEMHIDE: 1 << 29,
  GENERICHIDE: 1 << 30
};

// Backwards compatibility.
contentTypes.BACKGROUND = contentTypes.IMAGE;
contentTypes.XBL = contentTypes.OTHER;
contentTypes.DTD = contentTypes.OTHER;

const RESOURCE_TYPES =
/**
 * Bitmask for resource types like `$script`, `$image`, `$stylesheet`, and so
 * on.
 *
 * If a filter has no explicit content type, it applies to all resource types
 * (but not to any {@link module:contentTypes.SPECIAL_TYPES special types}).
 *
 * @const {number}
 *
 * @package
 */
// The first 24 bits are reserved for resource types like "script", "image",
// and so on.
// https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/webRequest/ResourceType
__webpack_unused_export__ = (1 << 24) - 1;

const SPECIAL_TYPES = ~RESOURCE_TYPES & (1 << 31) - 1;
/**
 * Bitmask for special "types" (options and flags) like `$csp`, `$elemhide`,
 * and so on.
 *
 * @const {number}
 *
 * @package
 */
__webpack_unused_export__ = SPECIAL_TYPES;

/**
 * Bitmask for "types" (flags) that are for exception rules only, like
 * `$document`, `$elemhide`, and so on.
 *
 * @const {number}
 *
 * @package
 */
__webpack_unused_export__ = contentTypes.DOCUMENT |
                         contentTypes.GENERICBLOCK |
                         contentTypes.ELEMHIDE |
                         contentTypes.GENERICHIDE;

/**
 * Yields individual types from a filter's type mask.
 *
 * @param {number} contentType A filter's type mask.
 * @param {number} [selection] Which types to yield.
 *
 * @generator
 * @yields {number}
 *
 * @package
 */
__webpack_unused_export__ = function* enumerateTypes(contentType, selection = ~0) {
  for (let mask = contentType & selection, bitIndex = 0;
    mask != 0; mask >>>= 1, bitIndex++) {
    if ((mask & 1) != 0) {
      // Note: The zero-fill right shift by zero is necessary for dropping the
      // sign.
      yield 1 << bitIndex >>> 0;
    }
  }
};


/***/ }),

/***/ 9491:
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {

"use strict";
var __webpack_unused_export__;
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



const {Cache} = __webpack_require__(808);

const publicSuffixes = __webpack_require__(3950);

// ensure no conflict ever happens with inherited properties
Object.setPrototypeOf(publicSuffixes, null);

/**
 * Cache of domain maps.
 *
 * The domains part of filter text (e.g. `example.com,~mail.example.com`) is
 * often repeated across filters. This cache enables deduplication of the
 * `Map` objects that specify on which domains the filter does and does not
 * apply, which reduces memory usage and improves performance.
 *
 * @type {Map.<string, Map.<string, boolean>>}
 */
let domainsCache = new Cache(1000);

/**
 * A `URLInfo` object represents information about a URL.
 *
 * It is returned by `{@link module:url.parseURL parseURL()}`.
 */
class URLInfo {
  /**
   * Creates a `URLInfo` object.
   *
   * @param {string} href The entire URL.
   * @param {string} protocol The protocol scheme of the URL, including the
   *   final `:`.
   * @param {string} [hostname] The hostname of the URL.
   *
   * @private
   */
  constructor(href, protocol, hostname = "") {
    this._href = href;
    this._protocol = protocol;
    this._hostname = hostname;
  }

  /**
   * The entire URL.
   * @type {string}
   */
  get href() {
    return this._href;
  }

  /**
   * The protocol scheme of the URL, including the final `:`.
   * @type {string}
   */
  get protocol() {
    return this._protocol;
  }

  /**
   * The hostname of the URL.
   * @type {string}
   */
  get hostname() {
    return this._hostname;
  }

  /**
   * Returns the entire URL.
   * @returns {string} The entire URL.
   */
  toString() {
    return this._href;
  }
}

let parseURL =
/**
 * Parses a URL to extract the protocol and the hostname.
 *
 * __This is a lightweight alternative to the native `URL` object intended for
 * use primarily within Adblock Plus. Unlike the `URL` object, the `parseURL()`
 * function is not robust and will give incorrect results for invalid URLs. Use
 * this function with valid,
 * [normalized](https://url.spec.whatwg.org/#concept-basic-url-parser),
 * properly encoded (IDNA, etc.) URLs only.__
 *
 * @param {string} url The URL.
 *
 * @returns {module:url~URLInfo} Information about the URL.
 *
 * @public
 */
__webpack_unused_export__ = function parseURL(url) {
  let match = /^([^:]+:)(?:\/\/(?:[^/]*@)?(\[[^\]]*\]|[^:/]+))?/.exec(url);
  return new URLInfo(url, match[1], match[2]);
};

let domainSuffixes =
/**
 * Yields all suffixes for a domain.
 *
 * For example, given the domain `www.example.com`, this function yields
 * `www.example.com`, `example.com`, and `com`, in that order.
 *
 * If the domain ends with a dot, the dot is ignored.
 *
 * @param {string} domain The domain.
 * @param {boolean} [includeBlank] Whether to include the blank suffix at the
 *   end.
 *
 * @generator
 * @yields {string} The next suffix for the domain.
 *
 * @package
 */
exports.$e = function* domainSuffixes(
  domain, includeBlank = false
) {
  // Since any IP address is already expected to be normalized, there's no need
  // to validate it.
  if (isIPAddress(domain)) {
    yield domain;
  }
  else {
    if (domain[domain.length - 1] == ".")
      domain = domain.substring(0, domain.length - 1);

    while (domain != "") {
      yield domain;

      let dotIndex = domain.indexOf(".");
      domain = dotIndex == -1 ? "" : domain.substr(dotIndex + 1);
    }
  }

  if (includeBlank)
    yield "";
};

/**
 * Checks whether the given hostname refers to
 * {@link https://en.wikipedia.org/wiki/Localhost localhost}.
 *
 * If the hostname is `localhost`, `127.0.0.1`, or `[::1]`, the function
 * returns `true`; otherwise, it returns `false`.
 *
 * @param {string} hostname The hostname.
 *
 * @returns {boolean} Whether the hostname refers to localhost.
 *
 * @package
 */
__webpack_unused_export__ = function isLocalhost(hostname) {
  return hostname == "localhost" || hostname == "127.0.0.1" ||
         hostname == "[::1]";
};

/**
 * Checks whether the given hostname is an IP address.
 *
 * Unlike `{@link module:url~isValidIPv4Address isValidIPv4Address()}`, this
 * function only checks whether the hostname _looks like_ an IP address. Use
 * this function with valid, normalized, properly encoded (IDNA) hostnames
 * only.
 *
 * @param {string} hostname An IDNA-encoded hostname.
 *
 * @returns {boolean} Whether the hostname is an IP address.
 */
function isIPAddress(hostname) {
  // Does it look like an IPv6 address?
  if (hostname[0] == "[" && hostname[hostname.length - 1] == "]")
    return true;

  // Note: The first condition helps us avoid the more expensive regular
  // expression match for most hostnames.
  return hostname[hostname.length - 1] >= 0 &&
         /^\d+\.\d+\.\d+\.\d+$/.test(hostname);
}

/**
 * Checks whether a given address is a valid IPv4 address.
 *
 * Only a normalized IPv4 address is considered valid. e.g. `0x7f.0x0.0x0.0x1`
 * is invalid, whereas `127.0.0.1` is valid.
 *
 * @param {string} address The address to check.
 *
 * @returns {boolean} Whether the address is a valid IPv4 address.
 */
function isValidIPv4Address(address) {
  return /^(((2[0-4]|1[0-9]|[1-9])?[0-9]|25[0-5])\.){4}$/.test(address + ".");
}

/**
 * Checks whether a given hostname is valid.
 *
 * This function is used for filter validation.
 *
 * A hostname occurring in a filter must be normalized. For example,
 * <code>&#x1f642;</code> (slightly smiling face) should be normalized to
 * `xn--938h`; otherwise this function returns `false` for such a hostname.
 * Similarly, IP addresses should be normalized.
 *
 * @param {string} hostname The hostname to check.
 *
 * @returns {boolean} Whether the hostname is valid.
 */
__webpack_unused_export__ = function isValidHostname(hostname) {
  if (isValidIPv4Address(hostname))
    return true;

  // This does not in fact validate the IPv6 address but it's alright for now.
  if (hostname[0] == "[" && hostname[hostname.length - 1] == "]")
    return true;

  // Based on
  // https://en.wikipedia.org/wiki/Hostname#Restrictions_on_valid_hostnames
  if (hostname[hostname.length - 1] == ".")
    hostname = hostname.substring(0, hostname.length - 1);

  if (hostname.length > 253)
    return false;

  let labels = hostname.split(".");

  for (let label of labels) {
    if (!/^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$/i.test(label))
      return false;
  }

  // Based on https://tools.ietf.org/html/rfc3696#section-2
  if (!/\D/.test(labels[labels.length - 1]))
    return false;

  return true;
};

let getBaseDomain =
/**
 * Gets the base domain for the given hostname.
 *
 * @param {string} hostname
 *
 * @returns {string}
 *
 * @package
 */
__webpack_unused_export__ = function getBaseDomain(hostname) {
  let slices = [];
  let cutoff = NaN;

  for (let suffix of domainSuffixes(hostname)) {
    slices.push(suffix);

    let offset = publicSuffixes[suffix];

    if (typeof offset == "number") {
      cutoff = slices.length - 1 - offset;
      break;
    }
  }

  if (isNaN(cutoff))
    return slices.length > 2 ? slices[slices.length - 2] : hostname;

  if (cutoff <= 0)
    return hostname;

  return slices[cutoff];
};

/**
 * Checks whether a request's origin is different from its document's origin.
 *
 * @param {string} requestHostname The IDNA-encoded hostname of the request.
 * @param {string} documentHostname The IDNA-encoded hostname of the document.
 *
 * @returns {boolean}
 */
function isThirdParty(requestHostname, documentHostname) {
  if (requestHostname[requestHostname.length - 1] == ".")
    requestHostname = requestHostname.substring(0, requestHostname.length - 1);

  if (documentHostname[documentHostname.length - 1] == ".") {
    documentHostname =
      documentHostname.substring(0, documentHostname.length - 1);
  }

  if (requestHostname == documentHostname)
    return false;

  if (!requestHostname || !documentHostname)
    return true;

  if (isIPAddress(requestHostname) || isIPAddress(documentHostname))
    return true;

  return getBaseDomain(requestHostname) != getBaseDomain(documentHostname);
}

let URLRequest =
/**
 * The `URLRequest` class represents a URL request.
 */
__webpack_unused_export__ = class URLRequest {
  /**
   * @private
   */
  constructor() {}

  /**
   * The URL of the request.
   * @type {string}
   */
  get href() {
    return this._href;
  }

  /**
   * Information about the URL of the request.
   * @type {module:url~URLInfo}
   * @package
   */
  get urlInfo() {
    if (!this._urlInfo)
      this._urlInfo = parseURL(this._href);

    return this._urlInfo;
  }

  /**
   * The hostname of the document making the request.
   * @type {?string}
   */
  get documentHostname() {
    return this._documentHostname == null ? null : this._documentHostname;
  }

  /**
   * Whether this is a third-party request.
   * @type {boolean}
   */
  get thirdParty() {
    if (typeof this._thirdParty == "undefined") {
      this._thirdParty = this._documentHostname == null ? false :
        isThirdParty(this.urlInfo.hostname,
          this._documentHostname);
    }

    return this._thirdParty;
  }

  /**
   * Returns the URL of the request.
   * @returns {string}
   */
  toString() {
    return this._href;
  }

  /**
   * The lower-case version of the URL of the request.
   * @type {string}
   * @package
   */
  get lowerCaseHref() {
    if (this._lowerCaseHref == null)
      this._lowerCaseHref = this._href.toLowerCase();

    return this._lowerCaseHref;
  }
};

/**
 * Returns a `{@link module:url.URLRequest URLRequest}` object for the given
 * URL.
 *
 * @param {string|module:url~URLInfo|URL} url The URL. If this is a `string`,
 *   it must be a canonicalized URL (see
 *   `{@link module:url.parseURL parseURL()}`).
 * @param {?string} [documentHostname] The IDNA-encoded hostname of the
 *   document making the request.
 *
 * @returns {module:url.URLRequest}
 */
__webpack_unused_export__ = function(url, documentHostname = null) {
  let request = new URLRequest();

  if (typeof url == "string") {
    request._href = url;
  }
  else {
    request._urlInfo = url instanceof URLInfo ? url :
      new URLInfo(url.href, url.protocol, url.hostname);
    request._href = url.href;
  }

  if (documentHostname != null)
    request._documentHostname = documentHostname;

  return request;
};

/**
 * Parses the domains part of a filter text
 * (e.g. `example.com,~mail.example.com`) into a `Map` object.
 *
 * @param {string} source The domains part of a filter text.
 * @param {string} separator The string used to separate two or more domains in
 *   the domains part of a filter text.
 *
 * @returns {?Map.<string, boolean>}
 *
 * @package
 */
exports.bV = function parseDomains(source, separator) {
  let domains = domainsCache.get(source);
  if (typeof domains != "undefined")
    return domains;

  if (source[0] != "~" && !source.includes(separator)) {
    // Fast track for the common one-domain scenario.
    domains = new Map([["", false], [source, true]]);
  }
  else {
    domains = null;

    let hasIncludes = false;
    for (let domain of source.split(separator)) {
      if (domain == "")
        continue;

      let include;
      if (domain[0] == "~") {
        include = false;
        domain = domain.substring(1);
      }
      else {
        include = true;
        hasIncludes = true;
      }

      if (!domains)
        domains = new Map();

      domains.set(domain, include);
    }

    if (domains)
      domains.set("", !hasIncludes);
  }

  domainsCache.set(source, domains);

  return domains;
};


/***/ }),

/***/ 6650:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "MU": () => (/* binding */ setListener),
/* harmony export */   "U3": () => (/* binding */ setSchedule)
/* harmony export */ });
/* unused harmony exports removeSchedule, removeListener */
/* harmony import */ var _scheduled_event_emitter_types__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1173);
/* harmony import */ var _adblockpluschrome_lib_storage_session__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(735);
var __awaiter = (undefined && undefined.__awaiter) || function (thisArg, _arguments, P, generator) {
    function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
    return new (P || (P = Promise))(function (resolve, reject) {
        function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
        function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
        function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
        step((generator = generator.apply(thisArg, _arguments || [])).next());
    });
};


const global = typeof window !== "undefined" ? window : self;
const storageKey = "schedules";
const storage = new _adblockpluschrome_lib_storage_session__WEBPACK_IMPORTED_MODULE_1__/* .SessionStorage */ .x("ScheduledEventEmitter.storage");
const initialization = initialize();
let schedules = Object.create(null);
const listeners = new Map();
function setListener(name, listener) {
    return __awaiter(this, void 0, void 0, function* () {
        yield initialization;
        if (listeners.has(name)) {
            warn(`Overwriting already registered listener for event "${name}".`);
        }
        listeners.set(name, listener);
        activateSchedules();
    });
}
function setSchedule(name, time, scheduleType = _scheduled_event_emitter_types__WEBPACK_IMPORTED_MODULE_0__/* .ScheduleType.once */ .I.once) {
    return __awaiter(this, void 0, void 0, function* () {
        yield initialization;
        if (name in schedules) {
            warn(`Overwriting already registered schedule for name "${name}".`);
        }
        schedules[name] = {
            period: time,
            next: time + Date.now(),
            runOnce: scheduleType === _scheduled_event_emitter_types__WEBPACK_IMPORTED_MODULE_0__/* .ScheduleType.once */ .I.once,
            count: 0
        };
        yield persistSchedules();
        activateSchedules();
    });
}
function removeSchedule(name) {
    return __awaiter(this, void 0, void 0, function* () {
        yield initialization;
        const schedule = schedules[name];
        if (!schedule) {
            return;
        }
        if (schedule.runOnce) {
            global.clearTimeout(schedule.activationId);
        }
        else {
            global.clearInterval(schedule.activationId);
        }
        delete schedules[name];
        yield persistSchedules();
    });
}
function removeListener(name) {
    return __awaiter(this, void 0, void 0, function* () {
        yield initialization;
        listeners.delete(name);
    });
}
function initialize() {
    return __awaiter(this, void 0, void 0, function* () {
        yield reviveSchedules();
    });
}
function persistSchedules() {
    return __awaiter(this, void 0, void 0, function* () {
        yield storage.set(storageKey, schedules);
    });
}
function reviveSchedules() {
    return __awaiter(this, void 0, void 0, function* () {
        const storedSchedules = yield storage.get(storageKey);
        if (Object.prototype.toString.call(storedSchedules) !== "[object Object]") {
            warn("Could not restore stored schedules.");
            return;
        }
        schedules = storedSchedules;
        Object.keys(schedules).forEach((name) => {
            delete schedules[name].activationId;
        });
    });
}
function activateSchedules() {
    const now = Date.now();
    Object.entries(schedules).forEach(([name, schedule]) => {
        const delta = schedule.next - now;
        const isDue = delta <= 0;
        const activationKey = "activationId";
        if (activationKey in schedule) {
            return;
        }
        if (!schedule.runOnce) {
            schedule.activationId = global.setInterval(() => emitEvent(name), schedule.period);
            return;
        }
        if (!isDue) {
            schedule.activationId = global.setTimeout(() => emitEvent(name), delta);
            return;
        }
        emitEvent(name);
    });
}
function emitEvent(name) {
    return __awaiter(this, void 0, void 0, function* () {
        const schedule = schedules[name];
        const listener = listeners.get(name);
        if (!schedule || !listener) {
            return;
        }
        schedule.count += 1;
        const now = Date.now();
        const callCount = schedule.count;
        listener({ callCount });
        if (schedule.runOnce) {
            yield removeSchedule(name);
        }
        else {
            schedule.next = now + schedule.period;
            yield persistSchedules();
        }
    });
}
function warn(message) {
    console.warn(`[ScheduledEventEmitter]: ${message}`);
}


/***/ }),

/***/ 1173:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "I": () => (/* binding */ ScheduleType)
/* harmony export */ });
var ScheduleType;
(function (ScheduleType) {
    ScheduleType["once"] = "once";
    ScheduleType["interval"] = "interval";
})(ScheduleType || (ScheduleType = {}));


/***/ }),

/***/ 3817:
/***/ ((module) => {

(function webpackUniversalModuleDefinition(root, factory) {
	if(true)
		module.exports = factory();
	else {}
})(self, function() {
return /******/ (() => { // webpackBootstrap
/******/ 	var __webpack_modules__ = ({

/***/ "./node_modules/adblockpluscore/data/subscriptions.json":
/*!**************************************************************!*\
  !*** ./node_modules/adblockpluscore/data/subscriptions.json ***!
  \**************************************************************/
/***/ ((module) => {

"use strict";
module.exports = JSON.parse('[{"id":"B7D76369-DD19-4602-80E8-2E32DDB490AC","type":"ads","languages":["id","ms"],"title":"ABPindo+EasyList","homepage":"http://abpindo.blogspot.com/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","A4A32212-E6BD-45F6-AD0F-E0FD18E8537B"],"url":"https://easylist-downloads.adblockplus.org/v3/full/abpindo+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/abpindo+easylist.txt"},{"id":"1C571EC7-6E52-47CC-B04A-4B3008D0AEBE","type":"ads","languages":["vi"],"title":"ABPVN List+EasyList","homepage":"http://abpvn.com/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","03648752-31EE-4FD0-85C1-20B07C5551C3"],"url":"https://easylist-downloads.adblockplus.org/v3/full/abpvn+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/abpvn+easylist.txt"},{"id":"E22C3B40-DC90-49D7-8BF5-E60904AB159A","type":"ads","languages":["bg"],"title":"Bulgarian list+EasyList","homepage":"https://stanev.org/abp/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","1638B159-F64A-4307-84E7-16AB08ED409E"],"url":"https://easylist-downloads.adblockplus.org/v3/full/bulgarian_list+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/bulgarian_list+easylist.txt"},{"id":"96932CD9-6DDF-4D97-B92F-FDF747B6FAA2","type":"ads","languages":["no","nb","nn","da","is","fo","kl","sv","fi"],"title":"Dandelion Sprout\'s Nordic Filters+EasyList","homepage":"https://github.com/DandelionSprout/adfilt","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","6D489E8D-E61C-444C-BBC5-44741773ADC2"],"url":"https://easylist-downloads.adblockplus.org/v3/full/dandelion_sprouts_nordic_filters+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/dandelion_sprouts_nordic_filters+easylist.txt"},{"id":"8C13E995-8F06-4927-BEA7-6C845FB7EEBF","type":"ads","languages":["en"],"title":"EasyList","homepage":"https://easylist.to/","url":"https://easylist-downloads.adblockplus.org/v3/full/easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylist.txt"},{"id":"9BD3EA2F-889D-4CC3-B680-CF484F2BD1B9","type":"ads","languages":["zh"],"title":"EasyList China+EasyList","homepage":"https://github.com/easylist/easylistchina/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","1D7F590C-B752-4BA0-9473-6A26DE1326B1"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistchina+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistchina+easylist.txt"},{"id":"4B6CE485-30AB-4213-AD17-504B3F2D2825","type":"ads","languages":["cs","sk"],"title":"EasyList Czech and Slovak+EasyList","homepage":"https://adblock.sk/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","2D8C4D88-34A0-4259-9098-30D28BA674BC"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistczechslovak+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistczechslovak+easylist.txt"},{"id":"A4B88FB6-E5E5-417F-8A49-20B8244995FD","type":"ads","languages":["nl"],"title":"EasyList Dutch+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","CB94E27D-6CD1-4DB9-83D9-6B7F1A3555F6"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistdutch+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistdutch+easylist.txt"},{"id":"0CD3D105-D3B3-4652-8489-94163DE9A08F","type":"ads","languages":["de"],"title":"EasyList Germany+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","4337FB2B-A95C-44D5-B78D-11AD40F7711B"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistgermany+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistgermany+easylist.txt"},{"id":"07549D8B-F06F-4D9D-A567-929AA59E9D1D","type":"ads","languages":["he"],"title":"EasyList Hebrew+EasyList","homepage":"https://github.com/easylist/EasyListHebrew","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","AE0D9320-665E-407D-B692-1A85AE481F34"],"url":"https://easylist-downloads.adblockplus.org/v3/full/israellist+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/israellist+easylist.txt"},{"id":"BBC07C05-66F1-42EC-BD4D-7AD495FAC84B","type":"ads","languages":["it"],"title":"EasyList Italy+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","2F0A4F0D-DF16-40D0-B0E0-5EB6791EC119"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistitaly+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistitaly+easylist.txt"},{"id":"CBE50FA2-DE3F-480C-B1D7-04289391C033","type":"ads","languages":["lt"],"title":"EasyList Lithuania+EasyList","homepage":"https://github.com/EasyList-Lithuania/easylist_lithuania","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","E89B3C08-2DED-40EA-8EE1-339B90D7B451"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistlithuania+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistlithuania+easylist.txt"},{"id":"3D2C09D0-DF1C-4C8E-9947-A23DCEAF8F8B","type":"ads","languages":["pl"],"title":"EasyList Polish+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","9F743FCD-801B-41D0-830F-5A4EA995216E"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistpolish+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistpolish+easylist.txt"},{"id":"14DF7BE6-9675-4E07-987A-D8A1000F9FEF","type":"ads","languages":["pt"],"title":"EasyList Portuguese+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","A41441EE-BF7C-4A48-9A43-42CCEA2B2A1D"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistportuguese+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistportuguese+easylist.txt"},{"id":"C3D13A19-3E8D-41F5-AD64-0F3B36DDE128","type":"ads","languages":["es"],"title":"EasyList Spanish+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","C8C1AA76-15B4-4CA3-8A9C-AD38D6AFCAEC"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easylistspanish+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easylistspanish+easylist.txt"},{"id":"25A31255-AB36-48A4-9086-06192DE71119","type":"ads","languages":["bn","gu","hi","pa","as","mr","ml","te","kn","or","ne","si"],"title":"IndianList+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","9FAA2906-CD5C-4520-BDC4-4E098B7EA228"],"url":"https://easylist-downloads.adblockplus.org/v3/full/indianlist+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/indianlist+easylist.txt"},{"id":"2708BCB7-2E45-41BC-B517-1730CF532F89","type":"ads","languages":["ko"],"title":"KoreanList+EasyList","homepage":"https://easylist.to/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","BCE2062F-0D99-4861-A1F7-E3DFEA6DAB69"],"url":"https://easylist-downloads.adblockplus.org/v3/full/koreanlist+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/koreanlist+easylist.txt"},{"id":"950C88EA-2DD1-42E3-B2A2-2DF2ED15563A","type":"ads","languages":["lv"],"title":"Latvian List+EasyList","homepage":"https://forums.lanik.us/viewforum.php?f=99-latvian-list","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","51893C6C-F39E-43C5-A2EF-9545E388A2CE"],"url":"https://easylist-downloads.adblockplus.org/v3/full/latvianlist+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/latvianlist+easylist.txt"},{"id":"684A25C6-6B5D-458A-8A2B-BAC0A12B0B15","type":"ads","languages":["ar"],"title":"Liste AR+Liste FR+EasyList","homepage":"https://forums.lanik.us/viewforum.php?f=98","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","8D421590-1A68-4B68-BE50-04E17C09460E","3D60E303-1141-4775-B800-834177922876"],"url":"https://easylist-downloads.adblockplus.org/v3/full/liste_ar+liste_fr+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/liste_ar+liste_fr+easylist.txt"},{"id":"2CEA1481-C29C-44F1-A084-A2A019533797","type":"ads","languages":["fr"],"title":"Liste FR+EasyList","homepage":"https://forums.lanik.us/viewforum.php?f=98","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","8D421590-1A68-4B68-BE50-04E17C09460E"],"url":"https://easylist-downloads.adblockplus.org/v3/full/liste_fr+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/liste_fr+easylist.txt"},{"id":"EEEF75EC-B2B4-49F4-BC49-17B08266F334","type":"ads","languages":["ro"],"title":"ROList+EasyList","homepage":"https://zoso.ro/rolist/","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","99166908-5FDA-4F9E-8C4C-70BB4DEEFC08"],"url":"https://easylist-downloads.adblockplus.org/v3/full/rolist+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/rolist+easylist.txt"},{"id":"1B5F78CA-8B30-4BDF-B0A3-451CB2202984","type":"ads","languages":["ru","uk"],"title":"RuAdList+EasyList","homepage":"https://forums.lanik.us/viewforum.php?f=102","includes":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF","879ECB9D-8935-4506-939E-5BBB7DD09402"],"url":"https://easylist-downloads.adblockplus.org/v3/full/ruadlist+easylist.txt","mv2_url":"https://easylist-downloads.adblockplus.org/ruadlist+easylist.txt"},{"id":"0798B6A2-94A4-4ADF-89ED-BEC112FC4C7F","type":"allowing","title":"Allow nonintrusive advertising","homepage":"https://acceptableads.com/","url":"https://easylist-downloads.adblockplus.org/v3/full/exceptionrules.txt","mv2_url":"https://easylist-downloads.adblockplus.org/exceptionrules.txt"},{"id":"D4028CDD-3D39-4624-ACC7-8140F4EC3238","type":"circumvention","title":"ABP filters","homepage":"https://github.com/abp-filters/abp-filters-anti-cv","url":"https://easylist-downloads.adblockplus.org/v3/full/abp-filters-anti-cv.txt","mv2_url":"https://easylist-downloads.adblockplus.org/abp-filters-anti-cv.txt"},{"id":"2090F374-29D9-4202-B2CE-139D6492D95E","type":"cookies","title":"I don\'t care about cookies","homepage":"https://www.i-dont-care-about-cookies.eu/","url":"https://easylist-downloads.adblockplus.org/v3/full/i_dont_care_about_cookies.txt","mv2_url":"https://easylist-downloads.adblockplus.org/i_dont_care_about_cookies.txt"},{"id":"5BD2BB73-459D-4A74-AF9D-A10157268350","type":"notifications","title":"Fanboy\'s Notifications Blocking List","homepage":"https://easylist.to/","url":"https://easylist-downloads.adblockplus.org/v3/full/fanboy-notifications.txt","mv2_url":"https://easylist-downloads.adblockplus.org/fanboy-notifications.txt"},{"id":"D72B6F06-52B2-4FED-96A2-1BF59CDD7AEC","type":"privacy","title":"EasyPrivacy","homepage":"https://easylist.to/","requires":["8C13E995-8F06-4927-BEA7-6C845FB7EEBF"],"url":"https://easylist-downloads.adblockplus.org/v3/full/easyprivacy.txt","mv2_url":"https://easylist-downloads.adblockplus.org/easyprivacy.txt"},{"id":"0A679439-445F-4DE7-84B9-88341F6DA520","type":"social","title":"Fanboy\'s Social Blocking List","homepage":"https://easylist.to/","url":"https://easylist-downloads.adblockplus.org/v3/full/fanboy-social.txt","mv2_url":"https://easylist-downloads.adblockplus.org/fanboy-social.txt"}]');

/***/ }),

/***/ "./node_modules/adblockpluscore/data/publicSuffixList.js":
/*!***************************************************************!*\
  !*** ./node_modules/adblockpluscore/data/publicSuffixList.js ***!
  \***************************************************************/
/***/ ((__unused_webpack_module, exports) => {

exports.publicSuffixes = {
  "0.bg": 1,
  "001www.com": 1,
  "0e.vc": 1,
  "0emm.com": 2,
  "1.azurestaticapps.net": 1,
  "1.bg": 1,
  "12hp.at": 1,
  "12hp.ch": 1,
  "12hp.de": 1,
  "1337.pictures": 1,
  "16-b.it": 1,
  "1kapp.com": 1,
  "2.azurestaticapps.net": 1,
  "2.bg": 1,
  "2000.hu": 1,
  "2038.io": 1,
  "2ix.at": 1,
  "2ix.ch": 1,
  "2ix.de": 1,
  "3.bg": 1,
  "32-b.it": 1,
  "3utilities.com": 1,
  "4.bg": 1,
  "4lima.at": 1,
  "4lima.ch": 1,
  "4lima.de": 1,
  "4u.com": 1,
  "5.bg": 1,
  "5g.in": 1,
  "6.bg": 1,
  "611.to": 1,
  "64-b.it": 1,
  "6g.in": 1,
  "7.bg": 1,
  "8.bg": 1,
  "9.bg": 1,
  "9guacu.br": 1,
  "a.bg": 1,
  "a.prod.fastly.net": 1,
  "a.run.app": 1,
  "a.se": 1,
  "a.ssl.fastly.net": 1,
  "aa.no": 1,
  "aaa.pro": 1,
  "aarborte.no": 1,
  "ab.ca": 1,
  "abashiri.hokkaido.jp": 1,
  "abc.br": 1,
  "abeno.osaka.jp": 1,
  "abiko.chiba.jp": 1,
  "abira.hokkaido.jp": 1,
  "abkhazia.su": 1,
  "abo.pa": 1,
  "abr.it": 1,
  "abruzzo.it": 1,
  "abu.yamaguchi.jp": 1,
  "ac.ae": 1,
  "ac.at": 1,
  "ac.be": 1,
  "ac.ci": 1,
  "ac.cn": 1,
  "ac.cr": 1,
  "ac.cy": 1,
  "ac.fj": 1,
  "ac.gn": 1,
  "ac.gov.br": 1,
  "ac.id": 1,
  "ac.il": 1,
  "ac.im": 1,
  "ac.in": 1,
  "ac.ir": 1,
  "ac.jp": 1,
  "ac.ke": 1,
  "ac.kr": 1,
  "ac.leg.br": 1,
  "ac.lk": 1,
  "ac.ls": 1,
  "ac.ma": 1,
  "ac.me": 1,
  "ac.mu": 1,
  "ac.mw": 1,
  "ac.mz": 1,
  "ac.ni": 1,
  "ac.nz": 1,
  "ac.pa": 1,
  "ac.pr": 1,
  "ac.rs": 1,
  "ac.ru": 1,
  "ac.rw": 1,
  "ac.se": 1,
  "ac.sz": 1,
  "ac.th": 1,
  "ac.tj": 1,
  "ac.tz": 1,
  "ac.ug": 1,
  "ac.uk": 1,
  "ac.vn": 1,
  "ac.za": 1,
  "ac.zm": 1,
  "ac.zw": 1,
  "aca.pro": 1,
  "academia.bo": 1,
  "academy.museum": 1,
  "accesscam.org": 1,
  "accident-investigation.aero": 1,
  "accident-prevention.aero": 1,
  "acct.pro": 1,
  "achi.nagano.jp": 1,
  "act.au": 1,
  "act.edu.au": 1,
  "ad.jp": 1,
  "adachi.tokyo.jp": 1,
  "adimo.co.uk": 1,
  "adm.br": 1,
  "adobeaemcloud.com": 1,
  "adobeaemcloud.net": 1,
  "adult.ht": 1,
  "adv.br": 1,
  "adv.mz": 1,
  "advisor.ws": 2,
  "adygeya.ru": 1,
  "adygeya.su": 1,
  "ae.org": 1,
  "aejrie.no": 1,
  "aero.mv": 1,
  "aero.tt": 1,
  "aerobatic.aero": 1,
  "aeroclub.aero": 1,
  "aerodrome.aero": 1,
  "aeroport.fr": 1,
  "affinitylottery.org.uk": 1,
  "afjord.no": 1,
  "africa.com": 1,
  "ag.it": 1,
  "aga.niigata.jp": 1,
  "agano.niigata.jp": 1,
  "agdenes.no": 1,
  "agematsu.nagano.jp": 1,
  "agents.aero": 1,
  "agr.br": 1,
  "agrar.hu": 1,
  "agric.za": 1,
  "agriculture.museum": 1,
  "agrigento.it": 1,
  "agro.bo": 1,
  "agro.pl": 1,
  "aguni.okinawa.jp": 1,
  "ah.cn": 1,
  "ah.no": 1,
  "ai.in": 1,
  "aibetsu.hokkaido.jp": 1,
  "aichi.jp": 1,
  "aid.pl": 1,
  "aikawa.kanagawa.jp": 1,
  "ainan.ehime.jp": 1,
  "aioi.hyogo.jp": 1,
  "aip.ee": 1,
  "air-surveillance.aero": 1,
  "air-traffic-control.aero": 1,
  "air.museum": 1,
  "aircraft.aero": 1,
  "airguard.museum": 1,
  "airkitapps-au.com": 1,
  "airkitapps.com": 1,
  "airkitapps.eu": 1,
  "airline.aero": 1,
  "airport.aero": 1,
  "airtraffic.aero": 1,
  "aisai.aichi.jp": 1,
  "aisho.shiga.jp": 1,
  "aivencloud.com": 1,
  "aizubange.fukushima.jp": 1,
  "aizumi.tokushima.jp": 1,
  "aizumisato.fukushima.jp": 1,
  "aizuwakamatsu.fukushima.jp": 1,
  "aju.br": 1,
  "ak.us": 1,
  "akabira.hokkaido.jp": 1,
  "akagi.shimane.jp": 1,
  "akaiwa.okayama.jp": 1,
  "akashi.hyogo.jp": 1,
  "aki.kochi.jp": 1,
  "akiruno.tokyo.jp": 1,
  "akishima.tokyo.jp": 1,
  "akita.akita.jp": 1,
  "akita.jp": 1,
  "akkeshi.hokkaido.jp": 1,
  "aknoluokta.no": 1,
  "ako.hyogo.jp": 1,
  "akrehamn.no": 1,
  "aktyubinsk.su": 1,
  "akune.kagoshima.jp": 1,
  "al.eu.org": 1,
  "al.gov.br": 1,
  "al.it": 1,
  "al.leg.br": 1,
  "al.no": 1,
  "al.us": 1,
  "alabama.museum": 1,
  "alaheadju.no": 1,
  "aland.fi": 1,
  "alaska.museum": 1,
  "alces.network": 2,
  "alessandria.it": 1,
  "alesund.no": 1,
  "algard.no": 1,
  "alp1.ae.flow.ch": 1,
  "alpha-myqnapcloud.com": 1,
  "alpha.bounty-full.com": 1,
  "alstahaug.no": 1,
  "alt.za": 1,
  "alta.no": 1,
  "altervista.org": 1,
  "alto-adige.it": 1,
  "altoadige.it": 1,
  "alvdal.no": 1,
  "alwaysdata.net": 1,
  "am.br": 1,
  "am.gov.br": 1,
  "am.in": 1,
  "am.leg.br": 1,
  "ama.aichi.jp": 1,
  "ama.shimane.jp": 1,
  "amagasaki.hyogo.jp": 1,
  "amakusa.kumamoto.jp": 1,
  "amami.kagoshima.jp": 1,
  "amber.museum": 1,
  "ambulance.aero": 1,
  "ambulance.museum": 1,
  "american.museum": 1,
  "americana.museum": 1,
  "americanantiques.museum": 1,
  "americanart.museum": 1,
  "ami.ibaraki.jp": 1,
  "amli.no": 1,
  "amot.no": 1,
  "amscompute.com": 1,
  "amsterdam.museum": 1,
  "amusement.aero": 1,
  "an.it": 1,
  "anamizu.ishikawa.jp": 1,
  "anan.nagano.jp": 1,
  "anan.tokushima.jp": 1,
  "anani.br": 1,
  "ancona.it": 1,
  "and.mom": 1,
  "and.museum": 1,
  "andasuolo.no": 1,
  "andebu.no": 1,
  "ando.nara.jp": 1,
  "andoy.no": 1,
  "andria-barletta-trani.it": 1,
  "andria-trani-barletta.it": 1,
  "andriabarlettatrani.it": 1,
  "andriatranibarletta.it": 1,
  "angry.jp": 1,
  "anjo.aichi.jp": 1,
  "ann-arbor.mi.us": 1,
  "annaka.gunma.jp": 1,
  "annefrank.museum": 1,
  "anpachi.gifu.jp": 1,
  "anthro.museum": 1,
  "anthropology.museum": 1,
  "antiques.museum": 1,
  "ao.it": 1,
  "aogaki.hyogo.jp": 1,
  "aogashima.tokyo.jp": 1,
  "aoki.nagano.jp": 1,
  "aomori.aomori.jp": 1,
  "aomori.jp": 1,
  "aosta-valley.it": 1,
  "aosta.it": 1,
  "aostavalley.it": 1,
  "aoste.it": 1,
  "ap-northeast-1.elasticbeanstalk.com": 1,
  "ap-northeast-2.elasticbeanstalk.com": 1,
  "ap-northeast-3.elasticbeanstalk.com": 1,
  "ap-south-1.elasticbeanstalk.com": 1,
  "ap-southeast-1.elasticbeanstalk.com": 1,
  "ap-southeast-2.elasticbeanstalk.com": 1,
  "ap.gov.br": 1,
  "ap.gov.pl": 1,
  "ap.it": 1,
  "ap.leg.br": 1,
  "aparecida.br": 1,
  "api.gov.uk": 1,
  "api.stdlib.com": 1,
  "apigee.io": 1,
  "app.banzaicloud.io": 1,
  "app.br": 1,
  "app.gp": 1,
  "app.lmpm.com": 1,
  "app.os.fedoraproject.org": 1,
  "app.os.stg.fedoraproject.org": 1,
  "app.render.com": 1,
  "appchizi.com": 1,
  "appengine.flow.ch": 1,
  "applinzi.com": 1,
  "apps.fbsbx.com": 1,
  "apps.lair.io": 1,
  "appspacehosted.com": 1,
  "appspaceusercontent.com": 1,
  "appspot.com": 1,
  "appudo.net": 1,
  "aq.it": 1,
  "aquarium.museum": 1,
  "aquila.it": 1,
  "ar.com": 1,
  "ar.it": 1,
  "ar.us": 1,
  "arai.shizuoka.jp": 1,
  "arakawa.saitama.jp": 1,
  "arakawa.tokyo.jp": 1,
  "arao.kumamoto.jp": 1,
  "arboretum.museum": 1,
  "archaeological.museum": 1,
  "archaeology.museum": 1,
  "architecture.museum": 1,
  "ardal.no": 1,
  "aremark.no": 1,
  "arendal.no": 1,
  "arezzo.it": 1,
  "ariake.saga.jp": 1,
  "arida.wakayama.jp": 1,
  "aridagawa.wakayama.jp": 1,
  "arita.saga.jp": 1,
  "arkhangelsk.su": 1,
  "armenia.su": 1,
  "arna.no": 1,
  "arq.br": 1,
  "art.br": 1,
  "art.do": 1,
  "art.dz": 1,
  "art.ht": 1,
  "art.museum": 1,
  "art.pl": 1,
  "art.sn": 1,
  "artanddesign.museum": 1,
  "artcenter.museum": 1,
  "artdeco.museum": 1,
  "arte.bo": 1,
  "arteducation.museum": 1,
  "artgallery.museum": 1,
  "arts.co": 1,
  "arts.museum": 1,
  "arts.nf": 1,
  "arts.ro": 1,
  "arts.ve": 1,
  "artsandcrafts.museum": 1,
  "arvo.network": 1,
  "as.us": 1,
  "asago.hyogo.jp": 1,
  "asahi.chiba.jp": 1,
  "asahi.ibaraki.jp": 1,
  "asahi.mie.jp": 1,
  "asahi.nagano.jp": 1,
  "asahi.toyama.jp": 1,
  "asahi.yamagata.jp": 1,
  "asahikawa.hokkaido.jp": 1,
  "asaka.saitama.jp": 1,
  "asakawa.fukushima.jp": 1,
  "asakuchi.okayama.jp": 1,
  "asaminami.hiroshima.jp": 1,
  "ascoli-piceno.it": 1,
  "ascolipiceno.it": 1,
  "aseral.no": 1,
  "ashgabad.su": 1,
  "ashibetsu.hokkaido.jp": 1,
  "ashikaga.tochigi.jp": 1,
  "ashiya.fukuoka.jp": 1,
  "ashiya.hyogo.jp": 1,
  "ashoro.hokkaido.jp": 1,
  "asker.no": 1,
  "askim.no": 1,
  "askoy.no": 1,
  "askvoll.no": 1,
  "asmatart.museum": 1,
  "asn.au": 1,
  "asn.lv": 1,
  "asnes.no": 1,
  "aso.kumamoto.jp": 1,
  "ass.km": 1,
  "assabu.hokkaido.jp": 1,
  "assassination.museum": 1,
  "assisi.museum": 1,
  "assn.lk": 1,
  "asso.bj": 1,
  "asso.ci": 1,
  "asso.dz": 1,
  "asso.eu.org": 1,
  "asso.fr": 1,
  "asso.gp": 1,
  "asso.ht": 1,
  "asso.km": 1,
  "asso.mc": 1,
  "asso.nc": 1,
  "asso.re": 1,
  "association.aero": 1,
  "association.museum": 1,
  "asti.it": 1,
  "astronomy.museum": 1,
  "asuke.aichi.jp": 1,
  "at-band-camp.net": 1,
  "at.eu.org": 1,
  "at.it": 1,
  "at.md": 1,
  "at.vg": 1,
  "atami.shizuoka.jp": 1,
  "ath.cx": 1,
  "atl.jelastic.vps-host.net": 1,
  "atlanta.museum": 1,
  "atm.pl": 1,
  "ato.br": 1,
  "atsugi.kanagawa.jp": 1,
  "atsuma.hokkaido.jp": 1,
  "au.eu.org": 1,
  "audnedaln.no": 1,
  "augustow.pl": 1,
  "aukra.no": 1,
  "aure.no": 1,
  "aurland.no": 1,
  "aurskog-holand.no": 1,
  "aus.basketball": 1,
  "austevoll.no": 1,
  "austin.museum": 1,
  "australia.museum": 1,
  "austrheim.no": 1,
  "authgear-staging.com": 1,
  "authgearapps.com": 1,
  "author.aero": 1,
  "auto.pl": 1,
  "automotive.museum": 1,
  "av.it": 1,
  "av.tr": 1,
  "avellino.it": 1,
  "averoy.no": 1,
  "aviation.museum": 1,
  "avocat.fr": 1,
  "avocat.pro": 1,
  "avoues.fr": 1,
  "awaji.hyogo.jp": 1,
  "awdev.ca": 2,
  "awsglobalaccelerator.com": 1,
  "awsmppl.com": 1,
  "axis.museum": 1,
  "aya.miyazaki.jp": 1,
  "ayabe.kyoto.jp": 1,
  "ayagawa.kagawa.jp": 1,
  "ayase.kanagawa.jp": 1,
  "az.us": 1,
  "azerbaijan.su": 1,
  "azimuth.network": 1,
  "azumino.nagano.jp": 1,
  "azure-mobile.net": 1,
  "azurecontainer.io": 2,
  "azurestaticapps.net": 1,
  "azurewebsites.net": 1,
  "b-data.io": 1,
  "b.bg": 1,
  "b.br": 1,
  "b.se": 1,
  "b.ssl.fastly.net": 1,
  "ba.gov.br": 1,
  "ba.it": 1,
  "ba.leg.br": 1,
  "babia-gora.pl": 1,
  "babyblue.jp": 1,
  "babymilk.jp": 1,
  "backdrop.jp": 1,
  "backplaneapp.io": 1,
  "backyards.banzaicloud.io": 2,
  "badaddja.no": 1,
  "badajoz.museum": 1,
  "baghdad.museum": 1,
  "bahcavuotna.no": 1,
  "bahccavuotna.no": 1,
  "bahn.museum": 1,
  "baidar.no": 1,
  "bajddar.no": 1,
  "balashov.su": 1,
  "balat.no": 1,
  "bale.museum": 1,
  "balena-devices.com": 1,
  "balestrand.no": 1,
  "ballangen.no": 1,
  "ballooning.aero": 1,
  "balsan-sudtirol.it": 1,
  "balsan-suedtirol.it": 1,
  "balsan.it": 1,
  "balsfjord.no": 1,
  "baltimore.museum": 1,
  "bambina.jp": 1,
  "bamble.no": 1,
  "bandai.fukushima.jp": 1,
  "bando.ibaraki.jp": 1,
  "banzai.cloud": 2,
  "bar.pro": 1,
  "bar0.net": 1,
  "bar1.net": 1,
  "bar2.net": 1,
  "barcelona.museum": 1,
  "bardu.no": 1,
  "bari.it": 1,
  "barletta-trani-andria.it": 1,
  "barlettatraniandria.it": 1,
  "barreau.bj": 1,
  "barrel-of-knowledge.info": 1,
  "barrell-of-knowledge.info": 1,
  "barsy.bg": 1,
  "barsy.ca": 1,
  "barsy.club": 1,
  "barsy.co.uk": 1,
  "barsy.de": 1,
  "barsy.eu": 1,
  "barsy.in": 1,
  "barsy.info": 1,
  "barsy.io": 1,
  "barsy.me": 1,
  "barsy.menu": 1,
  "barsy.mobi": 1,
  "barsy.net": 1,
  "barsy.online": 1,
  "barsy.org": 1,
  "barsy.pro": 1,
  "barsy.pub": 1,
  "barsy.ro": 1,
  "barsy.shop": 1,
  "barsy.site": 1,
  "barsy.support": 1,
  "barsy.uk": 1,
  "barsycenter.com": 1,
  "barsyonline.co.uk": 1,
  "barsyonline.com": 1,
  "barueri.br": 1,
  "barum.no": 1,
  "bas.it": 1,
  "base.ec": 1,
  "base.shop": 1,
  "baseball.museum": 1,
  "basel.museum": 1,
  "bashkiria.ru": 1,
  "bashkiria.su": 1,
  "basicserver.io": 1,
  "basilicata.it": 1,
  "baths.museum": 1,
  "bato.tochigi.jp": 1,
  "batsfjord.no": 1,
  "bauern.museum": 1,
  "bbs.tr": 1,
  "bc.ca": 1,
  "bc.platform.sh": 1,
  "bci.dnstrace.pro": 1,
  "bd": 2,
  "bd.se": 1,
  "be.ax": 1,
  "be.eu.org": 1,
  "be.gy": 1,
  "beagleboard.io": 1,
  "bearalvahki.no": 1,
  "beardu.no": 1,
  "beauxarts.museum": 1,
  "bedzin.pl": 1,
  "beeldengeluid.museum": 1,
  "beep.pl": 1,
  "beget.app": 2,
  "beiarn.no": 1,
  "bel.tr": 1,
  "belau.pw": 1,
  "belem.br": 1,
  "bellevue.museum": 1,
  "belluno.it": 1,
  "benevento.it": 1,
  "beppu.oita.jp": 1,
  "berg.no": 1,
  "bergamo.it": 1,
  "bergbau.museum": 1,
  "bergen.no": 1,
  "berkeley.museum": 1,
  "berlevag.no": 1,
  "berlin.museum": 1,
  "bern.museum": 1,
  "beskidy.pl": 1,
  "bet.ar": 1,
  "beta.bounty-full.com": 1,
  "beta.tailscale.net": 1,
  "betainabox.com": 1,
  "better-than.tv": 1,
  "bg.eu.org": 1,
  "bg.it": 1,
  "bhz.br": 1,
  "bi.it": 1,
  "bialowieza.pl": 1,
  "bialystok.pl": 1,
  "bib.br": 1,
  "bib.ve": 1,
  "bibai.hokkaido.jp": 1,
  "bible.museum": 1,
  "biei.hokkaido.jp": 1,
  "bielawa.pl": 1,
  "biella.it": 1,
  "bieszczady.pl": 1,
  "bievat.no": 1,
  "bifuka.hokkaido.jp": 1,
  "bihar.in": 1,
  "bihoro.hokkaido.jp": 1,
  "bilbao.museum": 1,
  "bill.museum": 1,
  "bindal.no": 1,
  "bio.br": 1,
  "bip.sh": 1,
  "bir.ru": 1,
  "biratori.hokkaido.jp": 1,
  "birdart.museum": 1,
  "birkenes.no": 1,
  "birthplace.museum": 1,
  "bitbridge.net": 1,
  "bitbucket.io": 1,
  "bitter.jp": 1,
  "biz.at": 1,
  "biz.az": 1,
  "biz.bb": 1,
  "biz.cy": 1,
  "biz.dk": 1,
  "biz.et": 1,
  "biz.fj": 1,
  "biz.gl": 1,
  "biz.id": 1,
  "biz.in": 1,
  "biz.ki": 1,
  "biz.ls": 1,
  "biz.mv": 1,
  "biz.mw": 1,
  "biz.my": 1,
  "biz.ni": 1,
  "biz.nr": 1,
  "biz.pk": 1,
  "biz.pl": 1,
  "biz.pr": 1,
  "biz.ss": 1,
  "biz.tj": 1,
  "biz.tr": 1,
  "biz.tt": 1,
  "biz.ua": 1,
  "biz.vn": 1,
  "biz.wf": 1,
  "biz.zm": 1,
  "bizen.okayama.jp": 1,
  "bj.cn": 1,
  "bjarkoy.no": 1,
  "bjerkreim.no": 1,
  "bjugn.no": 1,
  "bl.it": 1,
  "blackbaudcdn.net": 1,
  "blog.bo": 1,
  "blog.br": 1,
  "blog.gt": 1,
  "blog.kg": 1,
  "blog.vu": 1,
  "blogdns.com": 1,
  "blogdns.net": 1,
  "blogdns.org": 1,
  "blogsite.org": 1,
  "blogsite.xyz": 1,
  "blogspot.ae": 1,
  "blogspot.al": 1,
  "blogspot.am": 1,
  "blogspot.ba": 1,
  "blogspot.be": 1,
  "blogspot.bg": 1,
  "blogspot.bj": 1,
  "blogspot.ca": 1,
  "blogspot.cf": 1,
  "blogspot.ch": 1,
  "blogspot.cl": 1,
  "blogspot.co.at": 1,
  "blogspot.co.id": 1,
  "blogspot.co.il": 1,
  "blogspot.co.ke": 1,
  "blogspot.co.nz": 1,
  "blogspot.co.uk": 1,
  "blogspot.co.za": 1,
  "blogspot.com": 1,
  "blogspot.com.ar": 1,
  "blogspot.com.au": 1,
  "blogspot.com.br": 1,
  "blogspot.com.by": 1,
  "blogspot.com.co": 1,
  "blogspot.com.cy": 1,
  "blogspot.com.ee": 1,
  "blogspot.com.eg": 1,
  "blogspot.com.es": 1,
  "blogspot.com.mt": 1,
  "blogspot.com.ng": 1,
  "blogspot.com.tr": 1,
  "blogspot.com.uy": 1,
  "blogspot.cv": 1,
  "blogspot.cz": 1,
  "blogspot.de": 1,
  "blogspot.dk": 1,
  "blogspot.fi": 1,
  "blogspot.fr": 1,
  "blogspot.gr": 1,
  "blogspot.hk": 1,
  "blogspot.hr": 1,
  "blogspot.hu": 1,
  "blogspot.ie": 1,
  "blogspot.in": 1,
  "blogspot.is": 1,
  "blogspot.it": 1,
  "blogspot.jp": 1,
  "blogspot.kr": 1,
  "blogspot.li": 1,
  "blogspot.lt": 1,
  "blogspot.lu": 1,
  "blogspot.md": 1,
  "blogspot.mk": 1,
  "blogspot.mr": 1,
  "blogspot.mx": 1,
  "blogspot.my": 1,
  "blogspot.nl": 1,
  "blogspot.no": 1,
  "blogspot.pe": 1,
  "blogspot.pt": 1,
  "blogspot.qa": 1,
  "blogspot.re": 1,
  "blogspot.ro": 1,
  "blogspot.rs": 1,
  "blogspot.ru": 1,
  "blogspot.se": 1,
  "blogspot.sg": 1,
  "blogspot.si": 1,
  "blogspot.sk": 1,
  "blogspot.sn": 1,
  "blogspot.td": 1,
  "blogspot.tw": 1,
  "blogspot.ug": 1,
  "blogspot.vn": 1,
  "blogsyte.com": 1,
  "bloxcms.com": 1,
  "bluebite.io": 1,
  "blush.jp": 1,
  "bmd.br": 1,
  "bmoattachments.org": 1,
  "bn.it": 1,
  "bnr.la": 1,
  "bo.it": 1,
  "bo.nordland.no": 1,
  "bo.telemark.no": 1,
  "boavista.br": 1,
  "bodo.no": 1,
  "bokn.no": 1,
  "boldlygoingnowhere.org": 1,
  "boleslawiec.pl": 1,
  "bolivia.bo": 1,
  "bologna.it": 1,
  "bolt.hu": 1,
  "bolzano-altoadige.it": 1,
  "bolzano.it": 1,
  "bomlo.no": 1,
  "bonn.museum": 1,
  "boo.jp": 1,
  "bookonline.app": 1,
  "boomla.net": 1,
  "boston.museum": 1,
  "botanical.museum": 1,
  "botanicalgarden.museum": 1,
  "botanicgarden.museum": 1,
  "botany.museum": 1,
  "bounceme.net": 1,
  "bounty-full.com": 1,
  "boutir.com": 1,
  "boxfuse.io": 1,
  "boy.jp": 1,
  "boyfriend.jp": 1,
  "bozen-sudtirol.it": 1,
  "bozen-suedtirol.it": 1,
  "bozen.it": 1,
  "bplaced.com": 1,
  "bplaced.de": 1,
  "bplaced.net": 1,
  "br.com": 1,
  "br.it": 1,
  "brand.se": 1,
  "brandywinevalley.museum": 1,
  "brasil.museum": 1,
  "brasilia.me": 1,
  "bremanger.no": 1,
  "brescia.it": 1,
  "brindisi.it": 1,
  "bristol.museum": 1,
  "british.museum": 1,
  "britishcolumbia.museum": 1,
  "broadcast.museum": 1,
  "broke-it.net": 1,
  "broker.aero": 1,
  "bronnoy.no": 1,
  "bronnoysund.no": 1,
  "browsersafetymark.io": 1,
  "brumunddal.no": 1,
  "brunel.museum": 1,
  "brussel.museum": 1,
  "brussels.museum": 1,
  "bruxelles.museum": 1,
  "bryansk.su": 1,
  "bryne.no": 1,
  "bs.it": 1,
  "bsb.br": 1,
  "bss.design": 1,
  "bt.it": 1,
  "bu.no": 1,
  "budejju.no": 1,
  "build.run": 2,
  "builder.code.com": 2,
  "building.museum": 1,
  "builtwithdark.com": 1,
  "bukhara.su": 1,
  "bulsan-sudtirol.it": 1,
  "bulsan-suedtirol.it": 1,
  "bulsan.it": 1,
  "bungoono.oita.jp": 1,
  "bungotakada.oita.jp": 1,
  "bunkyo.tokyo.jp": 1,
  "burghof.museum": 1,
  "bus.museum": 1,
  "busan.kr": 1,
  "bushey.museum": 1,
  "business.in": 1,
  "but.jp": 1,
  "buyshop.jp": 1,
  "buyshouses.net": 1,
  "buzen.fukuoka.jp": 1,
  "bydgoszcz.pl": 1,
  "byen.site": 1,
  "bygland.no": 1,
  "bykle.no": 1,
  "bytom.pl": 1,
  "bz.it": 1,
  "bzz.dapps.earth": 2,
  "c.bg": 1,
  "c.cdn77.org": 1,
  "c.la": 1,
  "c.se": 1,
  "c66.me": 1,
  "ca-central-1.elasticbeanstalk.com": 1,
  "ca.eu.org": 1,
  "ca.in": 1,
  "ca.it": 1,
  "ca.na": 1,
  "ca.reclaim.cloud": 1,
  "ca.us": 1,
  "caa.aero": 1,
  "caa.li": 1,
  "cable-modem.org": 1,
  "cadaques.museum": 1,
  "cafjs.com": 1,
  "cagliari.it": 1,
  "cahcesuolo.no": 1,
  "cal.it": 1,
  "calabria.it": 1,
  "california.museum": 1,
  "caltanissetta.it": 1,
  "cam.it": 1,
  "cambridge.museum": 1,
  "camdvr.org": 1,
  "campaign.gov.uk": 1,
  "campania.it": 1,
  "campidano-medio.it": 1,
  "campidanomedio.it": 1,
  "campinagrande.br": 1,
  "campinas.br": 1,
  "campobasso.it": 1,
  "can.museum": 1,
  "canada.museum": 1,
  "candypop.jp": 1,
  "capebreton.museum": 1,
  "capoo.jp": 1,
  "caracal.mythic-beasts.com": 1,
  "carbonia-iglesias.it": 1,
  "carboniaiglesias.it": 1,
  "cargo.aero": 1,
  "carrara-massa.it": 1,
  "carraramassa.it": 1,
  "carrd.co": 1,
  "carrier.museum": 1,
  "cartoonart.museum": 1,
  "casacam.net": 1,
  "casadelamoneda.museum": 1,
  "caserta.it": 1,
  "casino.hu": 1,
  "castle.museum": 1,
  "castres.museum": 1,
  "cat.ax": 1,
  "catania.it": 1,
  "catanzaro.it": 1,
  "catering.aero": 1,
  "catfood.jp": 1,
  "catholic.edu.au": 1,
  "caxias.br": 1,
  "cb.it": 1,
  "cbg.ru": 1,
  "cc.ak.us": 1,
  "cc.al.us": 1,
  "cc.ar.us": 1,
  "cc.as.us": 1,
  "cc.az.us": 1,
  "cc.ca.us": 1,
  "cc.co.us": 1,
  "cc.ct.us": 1,
  "cc.dc.us": 1,
  "cc.de.us": 1,
  "cc.fl.us": 1,
  "cc.ga.us": 1,
  "cc.gu.us": 1,
  "cc.hi.us": 1,
  "cc.hn": 1,
  "cc.ia.us": 1,
  "cc.id.us": 1,
  "cc.il.us": 1,
  "cc.in.us": 1,
  "cc.ks.us": 1,
  "cc.ky.us": 1,
  "cc.la.us": 1,
  "cc.ma.us": 1,
  "cc.md.us": 1,
  "cc.me.us": 1,
  "cc.mi.us": 1,
  "cc.mn.us": 1,
  "cc.mo.us": 1,
  "cc.ms.us": 1,
  "cc.mt.us": 1,
  "cc.na": 1,
  "cc.nc.us": 1,
  "cc.nd.us": 1,
  "cc.ne.us": 1,
  "cc.nh.us": 1,
  "cc.nj.us": 1,
  "cc.nm.us": 1,
  "cc.nv.us": 1,
  "cc.ny.us": 1,
  "cc.oh.us": 1,
  "cc.ok.us": 1,
  "cc.or.us": 1,
  "cc.pa.us": 1,
  "cc.pr.us": 1,
  "cc.ri.us": 1,
  "cc.sc.us": 1,
  "cc.sd.us": 1,
  "cc.tn.us": 1,
  "cc.tx.us": 1,
  "cc.ua": 1,
  "cc.ut.us": 1,
  "cc.va.us": 1,
  "cc.vi.us": 1,
  "cc.vt.us": 1,
  "cc.wa.us": 1,
  "cc.wi.us": 1,
  "cc.wv.us": 1,
  "cc.wy.us": 1,
  "cci.fr": 1,
  "cd.eu.org": 1,
  "cdn-edges.net": 1,
  "cdn.prod.atlassian-dev.net": 1,
  "cdn77-ssl.net": 1,
  "ce.gov.br": 1,
  "ce.it": 1,
  "ce.leg.br": 1,
  "cechire.com": 1,
  "celtic.museum": 1,
  "center.museum": 1,
  "centralus.azurestaticapps.net": 1,
  "certification.aero": 1,
  "certmgr.org": 1,
  "cesena-forli.it": 1,
  "cesenaforli.it": 1,
  "ch.eu.org": 1,
  "ch.it": 1,
  "ch.tc": 1,
  "ch.trendhosting.cloud": 1,
  "chambagri.fr": 1,
  "championship.aero": 1,
  "channelsdvr.net": 1,
  "charter.aero": 1,
  "chattanooga.museum": 1,
  "cheap.jp": 1,
  "cheltenham.museum": 1,
  "cherkassy.ua": 1,
  "cherkasy.ua": 1,
  "chernigov.ua": 1,
  "chernihiv.ua": 1,
  "chernivtsi.ua": 1,
  "chernovtsy.ua": 1,
  "chesapeakebay.museum": 1,
  "chiba.jp": 1,
  "chicago.museum": 1,
  "chicappa.jp": 1,
  "chichibu.saitama.jp": 1,
  "chieti.it": 1,
  "chigasaki.kanagawa.jp": 1,
  "chihayaakasaka.osaka.jp": 1,
  "chijiwa.nagasaki.jp": 1,
  "chikugo.fukuoka.jp": 1,
  "chikuho.fukuoka.jp": 1,
  "chikuhoku.nagano.jp": 1,
  "chikujo.fukuoka.jp": 1,
  "chikuma.nagano.jp": 1,
  "chikusei.ibaraki.jp": 1,
  "chikushino.fukuoka.jp": 1,
  "chikuzen.fukuoka.jp": 1,
  "children.museum": 1,
  "childrens.museum": 1,
  "childrensgarden.museum": 1,
  "chillout.jp": 1,
  "chimkent.su": 1,
  "chino.nagano.jp": 1,
  "chippubetsu.hokkaido.jp": 1,
  "chips.jp": 1,
  "chiropractic.museum": 1,
  "chirurgiens-dentistes-en-france.fr": 1,
  "chirurgiens-dentistes.fr": 1,
  "chiryu.aichi.jp": 1,
  "chita.aichi.jp": 1,
  "chitose.hokkaido.jp": 1,
  "chiyoda.gunma.jp": 1,
  "chiyoda.tokyo.jp": 1,
  "chizu.tottori.jp": 1,
  "chocolate.museum": 1,
  "chofu.tokyo.jp": 1,
  "chonan.chiba.jp": 1,
  "chosei.chiba.jp": 1,
  "choshi.chiba.jp": 1,
  "chowder.jp": 1,
  "choyo.kumamoto.jp": 1,
  "christiansburg.museum": 1,
  "chtr.k12.ma.us": 1,
  "chu.jp": 1,
  "chungbuk.kr": 1,
  "chungnam.kr": 1,
  "chuo.chiba.jp": 1,
  "chuo.fukuoka.jp": 1,
  "chuo.osaka.jp": 1,
  "chuo.tokyo.jp": 1,
  "chuo.yamanashi.jp": 1,
  "ci.it": 1,
  "ciao.jp": 1,
  "ciencia.bo": 1,
  "cieszyn.pl": 1,
  "cim.br": 1,
  "cincinnati.museum": 1,
  "cinema.museum": 1,
  "circus.museum": 1,
  "ciscofreak.com": 1,
  "cistron.nl": 1,
  "city.hu": 1,
  "city.kawasaki.jp": 0,
  "city.kitakyushu.jp": 0,
  "city.kobe.jp": 0,
  "city.nagoya.jp": 0,
  "city.sapporo.jp": 0,
  "city.sendai.jp": 0,
  "city.yokohama.jp": 0,
  "civilaviation.aero": 1,
  "civilisation.museum": 1,
  "civilization.museum": 1,
  "civilwar.museum": 1,
  "ck": 2,
  "ck.ua": 1,
  "cl.it": 1,
  "clan.rip": 1,
  "clerk.app": 1,
  "clerkstage.app": 1,
  "cleverapps.io": 1,
  "clicketcloud.com": 1,
  "clickrising.net": 1,
  "clinton.museum": 1,
  "clock.museum": 1,
  "cloud-fr1.unispace.io": 1,
  "cloud.fedoraproject.org": 1,
  "cloud.goog": 1,
  "cloud.interhostsolutions.be": 1,
  "cloud.jelastic.open.tim.it": 1,
  "cloud.metacentrum.cz": 2,
  "cloud.nospamproxy.com": 1,
  "cloud66.ws": 1,
  "cloud66.zone": 1,
  "cloudaccess.host": 1,
  "cloudaccess.net": 1,
  "cloudapp.net": 1,
  "cloudapps.digital": 1,
  "cloudcontrolapp.com": 1,
  "cloudcontrolled.com": 1,
  "cloudera.site": 2,
  "cloudfront.net": 1,
  "cloudfunctions.net": 1,
  "cloudjiffy.net": 1,
  "cloudns.asia": 1,
  "cloudns.biz": 1,
  "cloudns.cc": 1,
  "cloudns.club": 1,
  "cloudns.eu": 1,
  "cloudns.in": 1,
  "cloudns.info": 1,
  "cloudns.org": 1,
  "cloudns.pro": 1,
  "cloudns.pw": 1,
  "cloudns.us": 1,
  "cloudsite.builders": 1,
  "cloudycluster.net": 1,
  "club.aero": 1,
  "club.tw": 1,
  "cn-north-1.eb.amazonaws.com.cn": 1,
  "cn-northwest-1.eb.amazonaws.com.cn": 1,
  "cn.com": 1,
  "cn.eu.org": 1,
  "cn.in": 1,
  "cn.it": 1,
  "cn.ua": 1,
  "cn.vu": 1,
  "cng.br": 1,
  "cnpy.gdn": 1,
  "cns.joyent.com": 2,
  "cnt.br": 1,
  "co.ae": 1,
  "co.ag": 1,
  "co.am": 1,
  "co.ao": 1,
  "co.at": 1,
  "co.bb": 1,
  "co.bi": 1,
  "co.bn": 1,
  "co.business": 1,
  "co.bw": 1,
  "co.ca": 1,
  "co.ci": 1,
  "co.cl": 1,
  "co.cm": 1,
  "co.com": 1,
  "co.cr": 1,
  "co.cz": 1,
  "co.dk": 1,
  "co.education": 1,
  "co.events": 1,
  "co.financial": 1,
  "co.gg": 1,
  "co.gl": 1,
  "co.gy": 1,
  "co.hu": 1,
  "co.id": 1,
  "co.il": 1,
  "co.im": 1,
  "co.in": 1,
  "co.ir": 1,
  "co.it": 1,
  "co.je": 1,
  "co.jp": 1,
  "co.ke": 1,
  "co.kr": 1,
  "co.krd": 1,
  "co.lc": 1,
  "co.ls": 1,
  "co.ma": 1,
  "co.me": 1,
  "co.mg": 1,
  "co.mu": 1,
  "co.mw": 1,
  "co.mz": 1,
  "co.na": 1,
  "co.network": 1,
  "co.ni": 1,
  "co.nl": 1,
  "co.no": 1,
  "co.nz": 1,
  "co.om": 1,
  "co.pl": 1,
  "co.place": 1,
  "co.pn": 1,
  "co.pw": 1,
  "co.ro": 1,
  "co.rs": 1,
  "co.rw": 1,
  "co.st": 1,
  "co.sz": 1,
  "co.technology": 1,
  "co.th": 1,
  "co.tj": 1,
  "co.tm": 1,
  "co.tt": 1,
  "co.tz": 1,
  "co.ua": 1,
  "co.ug": 1,
  "co.uk": 1,
  "co.us": 1,
  "co.uz": 1,
  "co.ve": 1,
  "co.vi": 1,
  "co.za": 1,
  "co.zm": 1,
  "co.zw": 1,
  "coal.museum": 1,
  "coastaldefence.museum": 1,
  "cocotte.jp": 1,
  "code.run": 2,
  "codeberg.page": 1,
  "codespot.com": 1,
  "cody.museum": 1,
  "cog.mi.us": 1,
  "col.ng": 1,
  "coldwar.museum": 1,
  "collection.museum": 1,
  "collegefan.org": 1,
  "colonialwilliamsburg.museum": 1,
  "coloradoplateau.museum": 1,
  "columbia.museum": 1,
  "columbus.museum": 1,
  "com.ac": 1,
  "com.af": 1,
  "com.ag": 1,
  "com.ai": 1,
  "com.al": 1,
  "com.am": 1,
  "com.ar": 1,
  "com.au": 1,
  "com.aw": 1,
  "com.az": 1,
  "com.ba": 1,
  "com.bb": 1,
  "com.bh": 1,
  "com.bi": 1,
  "com.bm": 1,
  "com.bn": 1,
  "com.bo": 1,
  "com.br": 1,
  "com.bs": 1,
  "com.bt": 1,
  "com.by": 1,
  "com.bz": 1,
  "com.ci": 1,
  "com.cm": 1,
  "com.cn": 1,
  "com.co": 1,
  "com.cu": 1,
  "com.cv": 1,
  "com.cw": 1,
  "com.cy": 1,
  "com.de": 1,
  "com.dm": 1,
  "com.do": 1,
  "com.dz": 1,
  "com.ec": 1,
  "com.ee": 1,
  "com.eg": 1,
  "com.es": 1,
  "com.et": 1,
  "com.fj": 1,
  "com.fm": 1,
  "com.fr": 1,
  "com.ge": 1,
  "com.gh": 1,
  "com.gi": 1,
  "com.gl": 1,
  "com.gn": 1,
  "com.gp": 1,
  "com.gr": 1,
  "com.gt": 1,
  "com.gu": 1,
  "com.gy": 1,
  "com.hk": 1,
  "com.hn": 1,
  "com.hr": 1,
  "com.ht": 1,
  "com.im": 1,
  "com.in": 1,
  "com.io": 1,
  "com.iq": 1,
  "com.is": 1,
  "com.jo": 1,
  "com.kg": 1,
  "com.ki": 1,
  "com.km": 1,
  "com.kp": 1,
  "com.kw": 1,
  "com.ky": 1,
  "com.kz": 1,
  "com.la": 1,
  "com.lb": 1,
  "com.lc": 1,
  "com.lk": 1,
  "com.lr": 1,
  "com.lv": 1,
  "com.ly": 1,
  "com.mg": 1,
  "com.mk": 1,
  "com.ml": 1,
  "com.mo": 1,
  "com.ms": 1,
  "com.mt": 1,
  "com.mu": 1,
  "com.mv": 1,
  "com.mw": 1,
  "com.mx": 1,
  "com.my": 1,
  "com.na": 1,
  "com.nf": 1,
  "com.ng": 1,
  "com.ni": 1,
  "com.nr": 1,
  "com.om": 1,
  "com.pa": 1,
  "com.pe": 1,
  "com.pf": 1,
  "com.ph": 1,
  "com.pk": 1,
  "com.pl": 1,
  "com.pr": 1,
  "com.ps": 1,
  "com.pt": 1,
  "com.py": 1,
  "com.qa": 1,
  "com.re": 1,
  "com.ro": 1,
  "com.ru": 1,
  "com.sa": 1,
  "com.sb": 1,
  "com.sc": 1,
  "com.sd": 1,
  "com.se": 1,
  "com.sg": 1,
  "com.sh": 1,
  "com.sl": 1,
  "com.sn": 1,
  "com.so": 1,
  "com.ss": 1,
  "com.st": 1,
  "com.sv": 1,
  "com.sy": 1,
  "com.tj": 1,
  "com.tm": 1,
  "com.tn": 1,
  "com.to": 1,
  "com.tr": 1,
  "com.tt": 1,
  "com.tw": 1,
  "com.ua": 1,
  "com.ug": 1,
  "com.uy": 1,
  "com.uz": 1,
  "com.vc": 1,
  "com.ve": 1,
  "com.vi": 1,
  "com.vn": 1,
  "com.vu": 1,
  "com.ws": 1,
  "com.ye": 1,
  "com.zm": 1,
  "commune.am": 1,
  "communication.museum": 1,
  "communications.museum": 1,
  "community-pro.de": 1,
  "community-pro.net": 1,
  "community.museum": 1,
  "como.it": 1,
  "compute-1.amazonaws.com": 2,
  "compute.amazonaws.com": 2,
  "compute.amazonaws.com.cn": 2,
  "compute.estate": 2,
  "computer.museum": 1,
  "computerhistory.museum": 1,
  "conf.au": 1,
  "conf.lv": 1,
  "conf.se": 1,
  "conference.aero": 1,
  "conn.uk": 1,
  "consulado.st": 1,
  "consultant.aero": 1,
  "consulting.aero": 1,
  "contagem.br": 1,
  "contemporary.museum": 1,
  "contemporaryart.museum": 1,
  "control.aero": 1,
  "convent.museum": 1,
  "coolblog.jp": 1,
  "coop.ar": 1,
  "coop.br": 1,
  "coop.ht": 1,
  "coop.in": 1,
  "coop.km": 1,
  "coop.mv": 1,
  "coop.mw": 1,
  "coop.py": 1,
  "coop.rw": 1,
  "coop.tt": 1,
  "cooperativa.bo": 1,
  "copenhagen.museum": 1,
  "copro.uk": 1,
  "corporation.museum": 1,
  "corvette.museum": 1,
  "cosenza.it": 1,
  "costume.museum": 1,
  "couchpotatofries.org": 1,
  "council.aero": 1,
  "countryestate.museum": 1,
  "county.museum": 1,
  "coz.br": 1,
  "cpa.pro": 1,
  "cq.cn": 1,
  "cr.it": 1,
  "cr.ua": 1,
  "crafting.xyz": 1,
  "crafts.museum": 1,
  "cranbrook.museum": 1,
  "cranky.jp": 1,
  "crd.co": 1,
  "creation.museum": 1,
  "cremona.it": 1,
  "crew.aero": 1,
  "cri.br": 1,
  "cri.nz": 1,
  "crimea.ua": 1,
  "crotone.it": 1,
  "cryptonomic.net": 2,
  "cs.in": 1,
  "cs.it": 1,
  "cs.keliweb.cloud": 1,
  "csx.cc": 1,
  "ct.it": 1,
  "ct.us": 1,
  "cuiaba.br": 1,
  "cultural.museum": 1,
  "culturalcenter.museum": 1,
  "culture.museum": 1,
  "cuneo.it": 1,
  "cupcake.is": 1,
  "curitiba.br": 1,
  "curv.dev": 1,
  "cust.dev.thingdust.io": 1,
  "cust.disrec.thingdust.io": 1,
  "cust.prod.thingdust.io": 1,
  "cust.retrosnub.co.uk": 1,
  "cust.testing.thingdust.io": 1,
  "custom.metacentrum.cz": 1,
  "customer-oci.com": 2,
  "customer.mythic-beasts.com": 1,
  "customer.speedpartner.de": 1,
  "cutegirl.jp": 1,
  "cv.ua": 1,
  "cx.ua": 1,
  "cy.eu.org": 1,
  "cya.gg": 1,
  "cyber.museum": 1,
  "cymru.museum": 1,
  "cyon.link": 1,
  "cyon.site": 1,
  "cz.eu.org": 1,
  "cz.it": 1,
  "czeladz.pl": 1,
  "czest.pl": 1,
  "d.bg": 1,
  "d.gv.vc": 1,
  "d.se": 1,
  "daa.jp": 1,
  "daegu.kr": 1,
  "daejeon.kr": 1,
  "daemon.panel.gg": 1,
  "dagestan.ru": 1,
  "dagestan.su": 1,
  "daigo.ibaraki.jp": 1,
  "daisen.akita.jp": 1,
  "daito.osaka.jp": 1,
  "daiwa.hiroshima.jp": 1,
  "dali.museum": 1,
  "dallas.museum": 1,
  "damnserver.com": 1,
  "daplie.me": 1,
  "dapps.earth": 2,
  "database.museum": 1,
  "database.run": 2,
  "date.fukushima.jp": 1,
  "date.hokkaido.jp": 1,
  "dattolocal.com": 1,
  "dattolocal.net": 1,
  "dattorelay.com": 1,
  "dattoweb.com": 1,
  "davvenjarga.no": 1,
  "davvesiida.no": 1,
  "dazaifu.fukuoka.jp": 1,
  "dc.us": 1,
  "dd-dns.de": 1,
  "ddns.me": 1,
  "ddns.net": 1,
  "ddns5.com": 1,
  "ddnsfree.com": 1,
  "ddnsgeek.com": 1,
  "ddnsking.com": 1,
  "ddnslive.com": 1,
  "ddnss.de": 1,
  "ddnss.org": 1,
  "ddr.museum": 1,
  "de.com": 1,
  "de.cool": 1,
  "de.eu.org": 1,
  "de.gt": 1,
  "de.ls": 1,
  "de.md": 1,
  "de.trendhosting.cloud": 1,
  "de.us": 1,
  "deatnu.no": 1,
  "debian.net": 1,
  "deca.jp": 1,
  "deci.jp": 1,
  "decorativearts.museum": 1,
  "dedibox.fr": 1,
  "dedyn.io": 1,
  "def.br": 1,
  "definima.io": 1,
  "definima.net": 1,
  "delaware.museum": 1,
  "delhi.in": 1,
  "dell-ogliastra.it": 1,
  "dellogliastra.it": 1,
  "delmenhorst.museum": 1,
  "demo.datacenter.fi": 1,
  "demo.datadetect.com": 1,
  "demo.jelastic.com": 1,
  "democracia.bo": 1,
  "demon.nl": 1,
  "denmark.museum": 1,
  "deno-staging.dev": 1,
  "deno.dev": 1,
  "dep.no": 1,
  "deporte.bo": 1,
  "depot.museum": 1,
  "des.br": 1,
  "desa.id": 1,
  "design.aero": 1,
  "design.museum": 1,
  "det.br": 1,
  "deta.app": 1,
  "deta.dev": 1,
  "detroit.museum": 1,
  "dev-builder.code.com": 2,
  "dev-myqnapcloud.com": 1,
  "dev.adobeaemcloud.com": 2,
  "dev.br": 1,
  "dev.static.land": 1,
  "dev.vu": 1,
  "devcdnaccesso.com": 2,
  "developer.app": 2,
  "development.run": 1,
  "devices.resinstaging.io": 1,
  "df.gov.br": 1,
  "df.leg.br": 1,
  "dgca.aero": 1,
  "dh.bytemark.co.uk": 1,
  "diadem.cloud": 1,
  "dielddanuorri.no": 1,
  "digick.jp": 1,
  "digitaloceanspaces.com": 2,
  "diher.solutions": 2,
  "dinosaur.museum": 1,
  "direct.quickconnect.cn": 1,
  "direct.quickconnect.to": 1,
  "discordsays.com": 1,
  "discordsez.com": 1,
  "discourse.group": 1,
  "discourse.team": 1,
  "discovery.museum": 1,
  "diskstation.eu": 1,
  "diskstation.me": 1,
  "diskstation.org": 1,
  "diskussionsbereich.de": 1,
  "ditchyourip.com": 1,
  "divtasvuodna.no": 1,
  "divttasvuotna.no": 1,
  "dk.eu.org": 1,
  "dlugoleka.pl": 1,
  "dn.ua": 1,
  "dnepropetrovsk.ua": 1,
  "dni.us": 1,
  "dnipropetrovsk.ua": 1,
  "dnsalias.com": 1,
  "dnsalias.net": 1,
  "dnsalias.org": 1,
  "dnsdojo.com": 1,
  "dnsdojo.net": 1,
  "dnsdojo.org": 1,
  "dnsfor.me": 1,
  "dnshome.de": 1,
  "dnsiskinky.com": 1,
  "dnsking.ch": 1,
  "dnsup.net": 1,
  "dnsupdate.info": 1,
  "dnsupdater.de": 1,
  "does-it.net": 1,
  "doesntexist.com": 1,
  "doesntexist.org": 1,
  "dolls.museum": 1,
  "donetsk.ua": 1,
  "donna.no": 1,
  "donostia.museum": 1,
  "dontexist.com": 1,
  "dontexist.net": 1,
  "dontexist.org": 1,
  "doomdns.com": 1,
  "doomdns.org": 1,
  "dopaas.com": 1,
  "doshi.yamanashi.jp": 1,
  "dovre.no": 1,
  "dp.ua": 1,
  "dr.in": 1,
  "dr.na": 1,
  "dr.tr": 1,
  "drammen.no": 1,
  "drangedal.no": 1,
  "dray-dns.de": 1,
  "drayddns.com": 1,
  "draydns.de": 1,
  "dreamhosters.com": 1,
  "drobak.no": 1,
  "drr.ac": 1,
  "drud.io": 1,
  "drud.us": 1,
  "dscloud.biz": 1,
  "dscloud.me": 1,
  "dscloud.mobi": 1,
  "dsmynas.com": 1,
  "dsmynas.net": 1,
  "dsmynas.org": 1,
  "dst.mi.us": 1,
  "duckdns.org": 1,
  "durham.museum": 1,
  "dvrcam.info": 1,
  "dvrdns.org": 1,
  "dweb.link": 2,
  "dy.fi": 1,
  "dyn-berlin.de": 1,
  "dyn-ip24.de": 1,
  "dyn-o-saur.com": 1,
  "dyn-vpn.de": 1,
  "dyn.cosidns.de": 1,
  "dyn.ddnss.de": 1,
  "dyn.home-webserver.de": 1,
  "dyn53.io": 1,
  "dynalias.com": 1,
  "dynalias.net": 1,
  "dynalias.org": 1,
  "dynamic-dns.info": 1,
  "dynamisches-dns.de": 1,
  "dynathome.net": 1,
  "dyndns-at-home.com": 1,
  "dyndns-at-work.com": 1,
  "dyndns-blog.com": 1,
  "dyndns-free.com": 1,
  "dyndns-home.com": 1,
  "dyndns-ip.com": 1,
  "dyndns-mail.com": 1,
  "dyndns-office.com": 1,
  "dyndns-pics.com": 1,
  "dyndns-remote.com": 1,
  "dyndns-server.com": 1,
  "dyndns-web.com": 1,
  "dyndns-wiki.com": 1,
  "dyndns-work.com": 1,
  "dyndns.biz": 1,
  "dyndns.dappnode.io": 1,
  "dyndns.ddnss.de": 1,
  "dyndns.info": 1,
  "dyndns.org": 1,
  "dyndns.tv": 1,
  "dyndns.ws": 1,
  "dyndns1.de": 1,
  "dynns.com": 1,
  "dynserv.org": 1,
  "dynu.net": 1,
  "dynv6.net": 1,
  "dynvpn.de": 1,
  "dyroy.no": 1,
  "e.bg": 1,
  "e.se": 1,
  "e12.ve": 1,
  "e164.arpa": 1,
  "e4.cz": 1,
  "east-kazakhstan.su": 1,
  "eastafrica.museum": 1,
  "eastasia.azurestaticapps.net": 1,
  "eastcoast.museum": 1,
  "eastus2.azurestaticapps.net": 1,
  "easypanel.app": 1,
  "easypanel.host": 1,
  "eating-organic.net": 1,
  "eaton.mi.us": 1,
  "ebetsu.hokkaido.jp": 1,
  "ebina.kanagawa.jp": 1,
  "ebino.miyazaki.jp": 1,
  "ebiz.tw": 1,
  "echizen.fukui.jp": 1,
  "ecn.br": 1,
  "eco.br": 1,
  "ecologia.bo": 1,
  "ecommerce-shop.pl": 1,
  "economia.bo": 1,
  "ed.ao": 1,
  "ed.ci": 1,
  "ed.cr": 1,
  "ed.jp": 1,
  "ed.pw": 1,
  "edgeapp.net": 1,
  "edgecompute.app": 1,
  "edgestack.me": 1,
  "editorx.io": 1,
  "edogawa.tokyo.jp": 1,
  "edu.ac": 1,
  "edu.af": 1,
  "edu.al": 1,
  "edu.ar": 1,
  "edu.au": 1,
  "edu.az": 1,
  "edu.ba": 1,
  "edu.bb": 1,
  "edu.bh": 1,
  "edu.bi": 1,
  "edu.bm": 1,
  "edu.bn": 1,
  "edu.bo": 1,
  "edu.br": 1,
  "edu.bs": 1,
  "edu.bt": 1,
  "edu.bz": 1,
  "edu.ci": 1,
  "edu.cn": 1,
  "edu.co": 1,
  "edu.cu": 1,
  "edu.cv": 1,
  "edu.cw": 1,
  "edu.dm": 1,
  "edu.do": 1,
  "edu.dz": 1,
  "edu.ec": 1,
  "edu.ee": 1,
  "edu.eg": 1,
  "edu.es": 1,
  "edu.et": 1,
  "edu.eu.org": 1,
  "edu.fm": 1,
  "edu.gd": 1,
  "edu.ge": 1,
  "edu.gh": 1,
  "edu.gi": 1,
  "edu.gl": 1,
  "edu.gn": 1,
  "edu.gp": 1,
  "edu.gr": 1,
  "edu.gt": 1,
  "edu.gu": 1,
  "edu.gy": 1,
  "edu.hk": 1,
  "edu.hn": 1,
  "edu.ht": 1,
  "edu.in": 1,
  "edu.iq": 1,
  "edu.is": 1,
  "edu.it": 1,
  "edu.jo": 1,
  "edu.kg": 1,
  "edu.ki": 1,
  "edu.km": 1,
  "edu.kn": 1,
  "edu.kp": 1,
  "edu.krd": 1,
  "edu.kw": 1,
  "edu.ky": 1,
  "edu.kz": 1,
  "edu.la": 1,
  "edu.lb": 1,
  "edu.lc": 1,
  "edu.lk": 1,
  "edu.lr": 1,
  "edu.ls": 1,
  "edu.lv": 1,
  "edu.ly": 1,
  "edu.me": 1,
  "edu.mg": 1,
  "edu.mk": 1,
  "edu.ml": 1,
  "edu.mn": 1,
  "edu.mo": 1,
  "edu.ms": 1,
  "edu.mt": 1,
  "edu.mv": 1,
  "edu.mw": 1,
  "edu.mx": 1,
  "edu.my": 1,
  "edu.mz": 1,
  "edu.ng": 1,
  "edu.ni": 1,
  "edu.nr": 1,
  "edu.om": 1,
  "edu.pa": 1,
  "edu.pe": 1,
  "edu.pf": 1,
  "edu.ph": 1,
  "edu.pk": 1,
  "edu.pl": 1,
  "edu.pn": 1,
  "edu.pr": 1,
  "edu.ps": 1,
  "edu.pt": 1,
  "edu.py": 1,
  "edu.qa": 1,
  "edu.rs": 1,
  "edu.ru": 1,
  "edu.sa": 1,
  "edu.sb": 1,
  "edu.sc": 1,
  "edu.scot": 1,
  "edu.sd": 1,
  "edu.sg": 1,
  "edu.sl": 1,
  "edu.sn": 1,
  "edu.so": 1,
  "edu.ss": 1,
  "edu.st": 1,
  "edu.sv": 1,
  "edu.sy": 1,
  "edu.tj": 1,
  "edu.tm": 1,
  "edu.to": 1,
  "edu.tr": 1,
  "edu.tt": 1,
  "edu.tw": 1,
  "edu.ua": 1,
  "edu.uy": 1,
  "edu.vc": 1,
  "edu.ve": 1,
  "edu.vn": 1,
  "edu.vu": 1,
  "edu.ws": 1,
  "edu.ye": 1,
  "edu.za": 1,
  "edu.zm": 1,
  "education.museum": 1,
  "educational.museum": 1,
  "educator.aero": 1,
  "edugit.io": 1,
  "ee.eu.org": 1,
  "eero-stage.online": 1,
  "eero.online": 1,
  "egersund.no": 1,
  "egoism.jp": 1,
  "egyptian.museum": 1,
  "ehime.jp": 1,
  "eid.no": 1,
  "eidfjord.no": 1,
  "eidsberg.no": 1,
  "eidskog.no": 1,
  "eidsvoll.no": 1,
  "eigersund.no": 1,
  "eiheiji.fukui.jp": 1,
  "eisenbahn.museum": 1,
  "ekloges.cy": 1,
  "elasticbeanstalk.com": 1,
  "elb.amazonaws.com": 2,
  "elb.amazonaws.com.cn": 2,
  "elblag.pl": 1,
  "elburg.museum": 1,
  "elementor.cloud": 1,
  "elementor.cool": 1,
  "elk.pl": 1,
  "elvendrell.museum": 1,
  "elverum.no": 1,
  "emb.kw": 1,
  "embaixada.st": 1,
  "embetsu.hokkaido.jp": 1,
  "embroidery.museum": 1,
  "emergency.aero": 1,
  "emilia-romagna.it": 1,
  "emiliaromagna.it": 1,
  "emp.br": 1,
  "empresa.bo": 1,
  "emr.it": 1,
  "en-root.fr": 1,
  "en.it": 1,
  "ena.gifu.jp": 1,
  "encoreapi.com": 1,
  "encr.app": 1,
  "encyclopedic.museum": 1,
  "endofinternet.net": 1,
  "endofinternet.org": 1,
  "endoftheinternet.org": 1,
  "enebakk.no": 1,
  "enf.br": 1,
  "eng.br": 1,
  "eng.pro": 1,
  "engerdal.no": 1,
  "engine.aero": 1,
  "engineer.aero": 1,
  "england.museum": 1,
  "eniwa.hokkaido.jp": 1,
  "enna.it": 1,
  "ens.tn": 1,
  "enscaled.sg": 1,
  "ent.platform.sh": 1,
  "enterprisecloud.nu": 1,
  "entertainment.aero": 1,
  "entomology.museum": 1,
  "environment.museum": 1,
  "environmentalconservation.museum": 1,
  "epilepsy.museum": 1,
  "equipment.aero": 1,
  "er": 2,
  "er.in": 1,
  "erimo.hokkaido.jp": 1,
  "erotica.hu": 1,
  "erotika.hu": 1,
  "es-1.axarnet.cloud": 1,
  "es.ax": 1,
  "es.eu.org": 1,
  "es.gov.br": 1,
  "es.kr": 1,
  "es.leg.br": 1,
  "esan.hokkaido.jp": 1,
  "esashi.hokkaido.jp": 1,
  "esp.br": 1,
  "essex.museum": 1,
  "est-a-la-maison.com": 1,
  "est-a-la-masion.com": 1,
  "est-le-patron.com": 1,
  "est-mon-blogueur.com": 1,
  "est.pr": 1,
  "estate.museum": 1,
  "etajima.hiroshima.jp": 1,
  "etc.br": 1,
  "ethnology.museum": 1,
  "eti.br": 1,
  "etne.no": 1,
  "etnedal.no": 1,
  "eu-1.evennode.com": 1,
  "eu-2.evennode.com": 1,
  "eu-3.evennode.com": 1,
  "eu-4.evennode.com": 1,
  "eu-central-1.elasticbeanstalk.com": 1,
  "eu-west-1.elasticbeanstalk.com": 1,
  "eu-west-2.elasticbeanstalk.com": 1,
  "eu-west-3.elasticbeanstalk.com": 1,
  "eu.ax": 1,
  "eu.com": 1,
  "eu.encoway.cloud": 1,
  "eu.int": 1,
  "eu.meteorapp.com": 1,
  "eu.org": 1,
  "eu.platform.sh": 1,
  "eu.pythonanywhere.com": 1,
  "eun.eg": 1,
  "eurodir.ru": 1,
  "evenassi.no": 1,
  "evenes.no": 1,
  "evje-og-hornnes.no": 1,
  "ex.futurecms.at": 2,
  "ex.ortsinfo.at": 2,
  "exchange.aero": 1,
  "exeter.museum": 1,
  "exhibition.museum": 1,
  "exnet.su": 1,
  "experts-comptables.fr": 1,
  "express.aero": 1,
  "ezproxy.kuleuven.be": 1,
  "f.bg": 1,
  "f.se": 1,
  "fakefur.jp": 1,
  "fam.pk": 1,
  "family.museum": 1,
  "familyds.com": 1,
  "familyds.net": 1,
  "familyds.org": 1,
  "fantasyleague.cc": 1,
  "far.br": 1,
  "farm.museum": 1,
  "farmequipment.museum": 1,
  "farmers.museum": 1,
  "farmstead.museum": 1,
  "farsund.no": 1,
  "fashionstore.jp": 1,
  "fastly-terrarium.com": 1,
  "fastlylb.net": 1,
  "faststacks.net": 1,
  "fastvps-server.com": 1,
  "fastvps.host": 1,
  "fastvps.site": 1,
  "fauske.no": 1,
  "fbx-os.fr": 1,
  "fbxos.fr": 1,
  "fc.it": 1,
  "fe.it": 1,
  "fed.us": 1,
  "federation.aero": 1,
  "fedje.no": 1,
  "fedorainfracloud.org": 1,
  "fedorapeople.org": 1,
  "feira.br": 1,
  "fem.jp": 1,
  "fentiger.mythic-beasts.com": 1,
  "fermo.it": 1,
  "ferrara.it": 1,
  "feste-ip.net": 1,
  "fet.no": 1,
  "fetsund.no": 1,
  "fg.it": 1,
  "fh-muenster.io": 1,
  "fh.se": 1,
  "fhs.no": 1,
  "fhsk.se": 1,
  "fhv.se": 1,
  "fi.cloudplatform.fi": 1,
  "fi.cr": 1,
  "fi.eu.org": 1,
  "fi.it": 1,
  "fie.ee": 1,
  "field.museum": 1,
  "figueres.museum": 1,
  "filatelia.museum": 1,
  "filegear-au.me": 1,
  "filegear-de.me": 1,
  "filegear-gb.me": 1,
  "filegear-ie.me": 1,
  "filegear-jp.me": 1,
  "filegear-sg.me": 1,
  "filegear.me": 1,
  "film.hu": 1,
  "film.museum": 1,
  "fin.ci": 1,
  "fin.ec": 1,
  "fin.tn": 1,
  "fineart.museum": 1,
  "finearts.museum": 1,
  "finland.museum": 1,
  "finnoy.no": 1,
  "firebaseapp.com": 1,
  "firenet.ch": 2,
  "firenze.it": 1,
  "firewall-gateway.com": 1,
  "firewall-gateway.de": 1,
  "firewall-gateway.net": 1,
  "firewalledreplit.co": 1,
  "fireweb.app": 1,
  "firm.co": 1,
  "firm.dk": 1,
  "firm.ht": 1,
  "firm.in": 1,
  "firm.nf": 1,
  "firm.ng": 1,
  "firm.ro": 1,
  "firm.ve": 1,
  "fitjar.no": 1,
  "fj.cn": 1,
  "fjaler.no": 1,
  "fjell.no": 1,
  "fk": 2,
  "fl.us": 1,
  "fla.no": 1,
  "flakstad.no": 1,
  "flanders.museum": 1,
  "flap.id": 1,
  "flatanger.no": 1,
  "fldrv.com": 1,
  "flekkefjord.no": 1,
  "flesberg.no": 1,
  "flier.jp": 1,
  "flight.aero": 1,
  "flog.br": 1,
  "floppy.jp": 1,
  "flora.no": 1,
  "florence.it": 1,
  "florida.museum": 1,
  "floripa.br": 1,
  "floro.no": 1,
  "flt.cloud.muni.cz": 1,
  "fly.dev": 1,
  "flynnhosting.net": 1,
  "fm.br": 1,
  "fm.it": 1,
  "fm.no": 1,
  "fnc.fr-par.scw.cloud": 1,
  "fnd.br": 1,
  "fnwk.site": 1,
  "foggia.it": 1,
  "folionetwork.site": 1,
  "folkebibl.no": 1,
  "folldal.no": 1,
  "fool.jp": 1,
  "for-better.biz": 1,
  "for-more.biz": 1,
  "for-our.info": 1,
  "for-some.biz": 1,
  "for-the.biz": 1,
  "for.men": 1,
  "for.mom": 1,
  "for.one": 1,
  "for.sale": 1,
  "force.museum": 1,
  "forde.no": 1,
  "forgeblocks.com": 1,
  "forgot.her.name": 1,
  "forgot.his.name": 1,
  "forli-cesena.it": 1,
  "forlicesena.it": 1,
  "forsand.no": 1,
  "fortal.br": 1,
  "forte.id": 1,
  "fortmissoula.museum": 1,
  "fortworth.museum": 1,
  "forum.hu": 1,
  "forumz.info": 1,
  "fosnes.no": 1,
  "fot.br": 1,
  "foundation.museum": 1,
  "foz.br": 1,
  "fr-1.paas.massivegrid.net": 1,
  "fr-par-1.baremetal.scw.cloud": 1,
  "fr-par-2.baremetal.scw.cloud": 1,
  "fr.eu.org": 1,
  "fr.it": 1,
  "fra1-de.cloudjiffy.net": 1,
  "framer.app": 1,
  "framer.media": 1,
  "framer.photos": 1,
  "framer.website": 1,
  "framer.wiki": 1,
  "framercanvas.com": 1,
  "frana.no": 1,
  "francaise.museum": 1,
  "frankfurt.museum": 1,
  "franziskaner.museum": 1,
  "fredrikstad.no": 1,
  "free.hr": 1,
  "freebox-os.com": 1,
  "freebox-os.fr": 1,
  "freeboxos.com": 1,
  "freeboxos.fr": 1,
  "freeddns.org": 1,
  "freeddns.us": 1,
  "freedesktop.org": 1,
  "freemasonry.museum": 1,
  "freemyip.com": 1,
  "freesite.host": 1,
  "freetls.fastly.net": 1,
  "frei.no": 1,
  "freiburg.museum": 1,
  "frenchkiss.jp": 1,
  "fribourg.museum": 1,
  "friuli-v-giulia.it": 1,
  "friuli-ve-giulia.it": 1,
  "friuli-vegiulia.it": 1,
  "friuli-venezia-giulia.it": 1,
  "friuli-veneziagiulia.it": 1,
  "friuli-vgiulia.it": 1,
  "friuliv-giulia.it": 1,
  "friulive-giulia.it": 1,
  "friulivegiulia.it": 1,
  "friulivenezia-giulia.it": 1,
  "friuliveneziagiulia.it": 1,
  "friulivgiulia.it": 1,
  "frog.museum": 1,
  "frogn.no": 1,
  "froland.no": 1,
  "from-ak.com": 1,
  "from-al.com": 1,
  "from-ar.com": 1,
  "from-az.net": 1,
  "from-ca.com": 1,
  "from-co.net": 1,
  "from-ct.com": 1,
  "from-dc.com": 1,
  "from-de.com": 1,
  "from-fl.com": 1,
  "from-ga.com": 1,
  "from-hi.com": 1,
  "from-ia.com": 1,
  "from-id.com": 1,
  "from-il.com": 1,
  "from-in.com": 1,
  "from-ks.com": 1,
  "from-ky.com": 1,
  "from-la.net": 1,
  "from-ma.com": 1,
  "from-md.com": 1,
  "from-me.org": 1,
  "from-mi.com": 1,
  "from-mn.com": 1,
  "from-mo.com": 1,
  "from-ms.com": 1,
  "from-mt.com": 1,
  "from-nc.com": 1,
  "from-nd.com": 1,
  "from-ne.com": 1,
  "from-nh.com": 1,
  "from-nj.com": 1,
  "from-nm.com": 1,
  "from-nv.com": 1,
  "from-ny.net": 1,
  "from-oh.com": 1,
  "from-ok.com": 1,
  "from-or.com": 1,
  "from-pa.com": 1,
  "from-pr.com": 1,
  "from-ri.com": 1,
  "from-sc.com": 1,
  "from-sd.com": 1,
  "from-tn.com": 1,
  "from-tx.com": 1,
  "from-ut.com": 1,
  "from-va.com": 1,
  "from-vt.com": 1,
  "from-wa.com": 1,
  "from-wi.com": 1,
  "from-wv.com": 1,
  "from-wy.com": 1,
  "from.hr": 1,
  "from.marketing": 1,
  "from.work": 1,
  "frosinone.it": 1,
  "frosta.no": 1,
  "froya.no": 1,
  "frusky.de": 2,
  "fst.br": 1,
  "ftpaccess.cc": 1,
  "fuchu.hiroshima.jp": 1,
  "fuchu.tokyo.jp": 1,
  "fuchu.toyama.jp": 1,
  "fudai.iwate.jp": 1,
  "fuefuki.yamanashi.jp": 1,
  "fuel.aero": 1,
  "fuettertdasnetz.de": 1,
  "fuji.shizuoka.jp": 1,
  "fujieda.shizuoka.jp": 1,
  "fujiidera.osaka.jp": 1,
  "fujikawa.shizuoka.jp": 1,
  "fujikawa.yamanashi.jp": 1,
  "fujikawaguchiko.yamanashi.jp": 1,
  "fujimi.nagano.jp": 1,
  "fujimi.saitama.jp": 1,
  "fujimino.saitama.jp": 1,
  "fujinomiya.shizuoka.jp": 1,
  "fujioka.gunma.jp": 1,
  "fujisato.akita.jp": 1,
  "fujisawa.iwate.jp": 1,
  "fujisawa.kanagawa.jp": 1,
  "fujishiro.ibaraki.jp": 1,
  "fujiyoshida.yamanashi.jp": 1,
  "fukagawa.hokkaido.jp": 1,
  "fukaya.saitama.jp": 1,
  "fukuchi.fukuoka.jp": 1,
  "fukuchiyama.kyoto.jp": 1,
  "fukudomi.saga.jp": 1,
  "fukui.fukui.jp": 1,
  "fukui.jp": 1,
  "fukumitsu.toyama.jp": 1,
  "fukuoka.jp": 1,
  "fukuroi.shizuoka.jp": 1,
  "fukusaki.hyogo.jp": 1,
  "fukushima.fukushima.jp": 1,
  "fukushima.hokkaido.jp": 1,
  "fukushima.jp": 1,
  "fukuyama.hiroshima.jp": 1,
  "funabashi.chiba.jp": 1,
  "funagata.yamagata.jp": 1,
  "funahashi.toyama.jp": 1,
  "functions.fnc.fr-par.scw.cloud": 1,
  "fundacio.museum": 1,
  "fuoisku.no": 1,
  "fuossko.no": 1,
  "furano.hokkaido.jp": 1,
  "furniture.museum": 1,
  "furubira.hokkaido.jp": 1,
  "furudono.fukushima.jp": 1,
  "furukawa.miyagi.jp": 1,
  "fusa.no": 1,
  "fuso.aichi.jp": 1,
  "fussa.tokyo.jp": 1,
  "futaba.fukushima.jp": 1,
  "futsu.nagasaki.jp": 1,
  "futtsu.chiba.jp": 1,
  "futurecms.at": 2,
  "futurehosting.at": 1,
  "futuremailing.at": 1,
  "fvg.it": 1,
  "fylkesbibl.no": 1,
  "fyresdal.no": 1,
  "g.bg": 1,
  "g.se": 1,
  "g.vbrplsbx.io": 1,
  "g12.br": 1,
  "ga.us": 1,
  "gaivuotna.no": 1,
  "gallery.museum": 1,
  "galsa.no": 1,
  "gamagori.aichi.jp": 1,
  "game-host.org": 1,
  "game-server.cc": 1,
  "game.tw": 1,
  "games.hu": 1,
  "gamo.shiga.jp": 1,
  "gamvik.no": 1,
  "gangaviika.no": 1,
  "gangwon.kr": 1,
  "garden.museum": 1,
  "gateway.dev": 2,
  "gateway.museum": 1,
  "gaular.no": 1,
  "gausdal.no": 1,
  "gb.net": 1,
  "gc.ca": 1,
  "gd.cn": 1,
  "gda.pl": 1,
  "gdansk.pl": 1,
  "gdynia.pl": 1,
  "ge.it": 1,
  "geek.nz": 1,
  "geekgalaxy.com": 1,
  "geelvinck.museum": 1,
  "gehirn.ne.jp": 1,
  "geisei.kochi.jp": 1,
  "gemological.museum": 1,
  "gen.in": 1,
  "gen.mi.us": 1,
  "gen.ng": 1,
  "gen.nz": 1,
  "gen.tr": 1,
  "genkai.saga.jp": 1,
  "genoa.it": 1,
  "genova.it": 1,
  "gentapps.com": 1,
  "gentlentapis.com": 1,
  "geo.br": 1,
  "geology.museum": 1,
  "geometre-expert.fr": 1,
  "georgia.museum": 1,
  "georgia.su": 1,
  "getmyip.com": 1,
  "gets-it.net": 1,
  "gg.ax": 1,
  "ggf.br": 1,
  "ghost.io": 1,
  "giehtavuoatna.no": 1,
  "giessen.museum": 1,
  "gifu.gifu.jp": 1,
  "gifu.jp": 1,
  "giize.com": 1,
  "gildeskal.no": 1,
  "ginan.gifu.jp": 1,
  "ginowan.okinawa.jp": 1,
  "ginoza.okinawa.jp": 1,
  "girlfriend.jp": 1,
  "girly.jp": 1,
  "giske.no": 1,
  "git-pages.rit.edu": 1,
  "git-repos.de": 1,
  "gitapp.si": 1,
  "github.io": 1,
  "githubpreview.dev": 1,
  "githubusercontent.com": 1,
  "gitlab.io": 1,
  "gitpage.si": 1,
  "gjemnes.no": 1,
  "gjerdrum.no": 1,
  "gjerstad.no": 1,
  "gjesdal.no": 1,
  "gjovik.no": 1,
  "glas.museum": 1,
  "glass.museum": 1,
  "gleeze.com": 1,
  "gliding.aero": 1,
  "glitch.me": 1,
  "gliwice.pl": 1,
  "global.prod.fastly.net": 1,
  "global.ssl.fastly.net": 1,
  "glogow.pl": 1,
  "gloomy.jp": 1,
  "gloppen.no": 1,
  "glug.org.uk": 1,
  "gmina.pl": 1,
  "gniezno.pl": 1,
  "go.ci": 1,
  "go.cr": 1,
  "go.dyndns.org": 1,
  "go.gov.br": 1,
  "go.id": 1,
  "go.it": 1,
  "go.jp": 1,
  "go.ke": 1,
  "go.kr": 1,
  "go.leg.br": 1,
  "go.pw": 1,
  "go.th": 1,
  "go.tj": 1,
  "go.tz": 1,
  "go.ug": 1,
  "gob.ar": 1,
  "gob.bo": 1,
  "gob.cl": 1,
  "gob.do": 1,
  "gob.ec": 1,
  "gob.es": 1,
  "gob.gt": 1,
  "gob.hn": 1,
  "gob.mx": 1,
  "gob.ni": 1,
  "gob.pa": 1,
  "gob.pe": 1,
  "gob.pk": 1,
  "gob.sv": 1,
  "gob.ve": 1,
  "gobo.wakayama.jp": 1,
  "godo.gifu.jp": 1,
  "goiania.br": 1,
  "goip.de": 1,
  "gojome.akita.jp": 1,
  "gok.pk": 1,
  "gokase.miyazaki.jp": 1,
  "gol.no": 1,
  "golffan.us": 1,
  "gon.pk": 1,
  "gonna.jp": 1,
  "gonohe.aomori.jp": 1,
  "googleapis.com": 1,
  "googlecode.com": 1,
  "gop.pk": 1,
  "gorge.museum": 1,
  "gorizia.it": 1,
  "gorlice.pl": 1,
  "gos.pk": 1,
  "gose.nara.jp": 1,
  "gosen.niigata.jp": 1,
  "goshiki.hyogo.jp": 1,
  "gotdns.ch": 1,
  "gotdns.com": 1,
  "gotdns.org": 1,
  "gotemba.shizuoka.jp": 1,
  "goto.nagasaki.jp": 1,
  "gotpantheon.com": 1,
  "gotsu.shimane.jp": 1,
  "goupile.fr": 1,
  "gouv.bj": 1,
  "gouv.ci": 1,
  "gouv.fr": 1,
  "gouv.ht": 1,
  "gouv.km": 1,
  "gouv.ml": 1,
  "gouv.sn": 1,
  "gov.ac": 1,
  "gov.ae": 1,
  "gov.af": 1,
  "gov.al": 1,
  "gov.ar": 1,
  "gov.as": 1,
  "gov.au": 1,
  "gov.az": 1,
  "gov.ba": 1,
  "gov.bb": 1,
  "gov.bf": 1,
  "gov.bh": 1,
  "gov.bm": 1,
  "gov.bn": 1,
  "gov.br": 1,
  "gov.bs": 1,
  "gov.bt": 1,
  "gov.by": 1,
  "gov.bz": 1,
  "gov.cd": 1,
  "gov.cl": 1,
  "gov.cm": 1,
  "gov.cn": 1,
  "gov.co": 1,
  "gov.cu": 1,
  "gov.cx": 1,
  "gov.cy": 1,
  "gov.dm": 1,
  "gov.do": 1,
  "gov.dz": 1,
  "gov.ec": 1,
  "gov.ee": 1,
  "gov.eg": 1,
  "gov.et": 1,
  "gov.fj": 1,
  "gov.gd": 1,
  "gov.ge": 1,
  "gov.gh": 1,
  "gov.gi": 1,
  "gov.gn": 1,
  "gov.gr": 1,
  "gov.gu": 1,
  "gov.gy": 1,
  "gov.hk": 1,
  "gov.ie": 1,
  "gov.il": 1,
  "gov.in": 1,
  "gov.iq": 1,
  "gov.ir": 1,
  "gov.is": 1,
  "gov.it": 1,
  "gov.jo": 1,
  "gov.kg": 1,
  "gov.ki": 1,
  "gov.km": 1,
  "gov.kn": 1,
  "gov.kp": 1,
  "gov.kw": 1,
  "gov.kz": 1,
  "gov.la": 1,
  "gov.lb": 1,
  "gov.lc": 1,
  "gov.lk": 1,
  "gov.lr": 1,
  "gov.ls": 1,
  "gov.lt": 1,
  "gov.lv": 1,
  "gov.ly": 1,
  "gov.ma": 1,
  "gov.me": 1,
  "gov.mg": 1,
  "gov.mk": 1,
  "gov.ml": 1,
  "gov.mn": 1,
  "gov.mo": 1,
  "gov.mr": 1,
  "gov.ms": 1,
  "gov.mu": 1,
  "gov.mv": 1,
  "gov.mw": 1,
  "gov.my": 1,
  "gov.mz": 1,
  "gov.nc.tr": 1,
  "gov.ng": 1,
  "gov.nl": 1,
  "gov.nr": 1,
  "gov.om": 1,
  "gov.ph": 1,
  "gov.pk": 1,
  "gov.pl": 1,
  "gov.pn": 1,
  "gov.pr": 1,
  "gov.ps": 1,
  "gov.pt": 1,
  "gov.py": 1,
  "gov.qa": 1,
  "gov.rs": 1,
  "gov.ru": 1,
  "gov.rw": 1,
  "gov.sa": 1,
  "gov.sb": 1,
  "gov.sc": 1,
  "gov.scot": 1,
  "gov.sd": 1,
  "gov.sg": 1,
  "gov.sh": 1,
  "gov.sl": 1,
  "gov.so": 1,
  "gov.ss": 1,
  "gov.sx": 1,
  "gov.sy": 1,
  "gov.tj": 1,
  "gov.tl": 1,
  "gov.tm": 1,
  "gov.tn": 1,
  "gov.to": 1,
  "gov.tr": 1,
  "gov.tt": 1,
  "gov.tw": 1,
  "gov.ua": 1,
  "gov.uk": 1,
  "gov.vc": 1,
  "gov.ve": 1,
  "gov.vn": 1,
  "gov.ws": 1,
  "gov.ye": 1,
  "gov.za": 1,
  "gov.zm": 1,
  "gov.zw": 1,
  "government.aero": 1,
  "govt.nz": 1,
  "gr.com": 1,
  "gr.eu.org": 1,
  "gr.it": 1,
  "gr.jp": 1,
  "grajewo.pl": 1,
  "gran.no": 1,
  "grandrapids.museum": 1,
  "grane.no": 1,
  "granvin.no": 1,
  "graphox.us": 1,
  "gratangen.no": 1,
  "graz.museum": 1,
  "greater.jp": 1,
  "greta.fr": 1,
  "grimstad.no": 1,
  "griw.gov.pl": 1,
  "groks-the.info": 1,
  "groks-this.info": 1,
  "grondar.za": 1,
  "grong.no": 1,
  "grosseto.it": 1,
  "groundhandling.aero": 1,
  "group.aero": 1,
  "grozny.ru": 1,
  "grozny.su": 1,
  "grp.lk": 1,
  "gru.br": 1,
  "grue.no": 1,
  "gs.aa.no": 1,
  "gs.ah.no": 1,
  "gs.bu.no": 1,
  "gs.cn": 1,
  "gs.fm.no": 1,
  "gs.hl.no": 1,
  "gs.hm.no": 1,
  "gs.jan-mayen.no": 1,
  "gs.mr.no": 1,
  "gs.nl.no": 1,
  "gs.nt.no": 1,
  "gs.of.no": 1,
  "gs.ol.no": 1,
  "gs.oslo.no": 1,
  "gs.rl.no": 1,
  "gs.sf.no": 1,
  "gs.st.no": 1,
  "gs.svalbard.no": 1,
  "gs.tm.no": 1,
  "gs.tr.no": 1,
  "gs.va.no": 1,
  "gs.vf.no": 1,
  "gsj.bz": 1,
  "gsm.pl": 1,
  "gu.us": 1,
  "guam.gu": 1,
  "gub.uy": 1,
  "guernsey.museum": 1,
  "gujarat.in": 1,
  "gujo.gifu.jp": 1,
  "gulen.no": 1,
  "gunma.jp": 1,
  "guovdageaidnu.no": 1,
  "gushikami.okinawa.jp": 1,
  "gv.ao": 1,
  "gv.at": 1,
  "gv.vc": 1,
  "gwangju.kr": 1,
  "gwiddle.co.uk": 1,
  "gx.cn": 1,
  "gyeongbuk.kr": 1,
  "gyeonggi.kr": 1,
  "gyeongnam.kr": 1,
  "gyokuto.kumamoto.jp": 1,
  "gz.cn": 1,
  "h.bg": 1,
  "h.se": 1,
  "ha.cn": 1,
  "ha.no": 1,
  "habikino.osaka.jp": 1,
  "habmer.no": 1,
  "haboro.hokkaido.jp": 1,
  "hacca.jp": 1,
  "hachijo.tokyo.jp": 1,
  "hachinohe.aomori.jp": 1,
  "hachioji.tokyo.jp": 1,
  "hachirogata.akita.jp": 1,
  "hadano.kanagawa.jp": 1,
  "hadsel.no": 1,
  "haebaru.okinawa.jp": 1,
  "haga.tochigi.jp": 1,
  "hagebostad.no": 1,
  "hagi.yamaguchi.jp": 1,
  "haibara.shizuoka.jp": 1,
  "hakata.fukuoka.jp": 1,
  "hakodate.hokkaido.jp": 1,
  "hakone.kanagawa.jp": 1,
  "hakuba.nagano.jp": 1,
  "hakui.ishikawa.jp": 1,
  "hakusan.ishikawa.jp": 1,
  "halden.no": 1,
  "half.host": 1,
  "halloffame.museum": 1,
  "halsa.no": 1,
  "ham-radio-op.net": 1,
  "hamada.shimane.jp": 1,
  "hamamatsu.shizuoka.jp": 1,
  "hamar.no": 1,
  "hamaroy.no": 1,
  "hamatama.saga.jp": 1,
  "hamatonbetsu.hokkaido.jp": 1,
  "hamburg.museum": 1,
  "hammarfeasta.no": 1,
  "hammerfest.no": 1,
  "hamura.tokyo.jp": 1,
  "hanamaki.iwate.jp": 1,
  "hanamigawa.chiba.jp": 1,
  "hanawa.fukushima.jp": 1,
  "handa.aichi.jp": 1,
  "handcrafted.jp": 1,
  "handson.museum": 1,
  "hanggliding.aero": 1,
  "hannan.osaka.jp": 1,
  "hanno.saitama.jp": 1,
  "hanyu.saitama.jp": 1,
  "hapmir.no": 1,
  "happou.akita.jp": 1,
  "hara.nagano.jp": 1,
  "haram.no": 1,
  "hareid.no": 1,
  "harima.hyogo.jp": 1,
  "harstad.no": 1,
  "harvestcelebration.museum": 1,
  "hasama.oita.jp": 1,
  "hasami.nagasaki.jp": 1,
  "hashbang.sh": 1,
  "hashikami.aomori.jp": 1,
  "hashima.gifu.jp": 1,
  "hashimoto.wakayama.jp": 1,
  "hasuda.saitama.jp": 1,
  "hasura-app.io": 1,
  "hasura.app": 1,
  "hasvik.no": 1,
  "hatogaya.saitama.jp": 1,
  "hatoyama.saitama.jp": 1,
  "hatsukaichi.hiroshima.jp": 1,
  "hattfjelldal.no": 1,
  "haugesund.no": 1,
  "hawaii.museum": 1,
  "hayakawa.yamanashi.jp": 1,
  "hayashima.okayama.jp": 1,
  "hazu.aichi.jp": 1,
  "hb.cldmail.ru": 1,
  "hb.cn": 1,
  "he.cn": 1,
  "health-carereform.com": 1,
  "health.museum": 1,
  "health.nz": 1,
  "health.vn": 1,
  "heavy.jp": 1,
  "heguri.nara.jp": 1,
  "heimatunduhren.museum": 1,
  "hekinan.aichi.jp": 1,
  "hellas.museum": 1,
  "helsinki.museum": 1,
  "hembygdsforbund.museum": 1,
  "hemne.no": 1,
  "hemnes.no": 1,
  "hemsedal.no": 1,
  "hepforge.org": 1,
  "her.jp": 1,
  "herad.no": 1,
  "here-for-more.info": 1,
  "heritage.museum": 1,
  "herokuapp.com": 1,
  "herokussl.com": 1,
  "heroy.more-og-romsdal.no": 1,
  "heroy.nordland.no": 1,
  "heteml.net": 1,
  "hi.cn": 1,
  "hi.us": 1,
  "hicam.net": 1,
  "hichiso.gifu.jp": 1,
  "hida.gifu.jp": 1,
  "hidaka.hokkaido.jp": 1,
  "hidaka.kochi.jp": 1,
  "hidaka.saitama.jp": 1,
  "hidaka.wakayama.jp": 1,
  "hidora.com": 1,
  "higashi.fukuoka.jp": 1,
  "higashi.fukushima.jp": 1,
  "higashi.okinawa.jp": 1,
  "higashiagatsuma.gunma.jp": 1,
  "higashichichibu.saitama.jp": 1,
  "higashihiroshima.hiroshima.jp": 1,
  "higashiizu.shizuoka.jp": 1,
  "higashiizumo.shimane.jp": 1,
  "higashikagawa.kagawa.jp": 1,
  "higashikagura.hokkaido.jp": 1,
  "higashikawa.hokkaido.jp": 1,
  "higashikurume.tokyo.jp": 1,
  "higashimatsushima.miyagi.jp": 1,
  "higashimatsuyama.saitama.jp": 1,
  "higashimurayama.tokyo.jp": 1,
  "higashinaruse.akita.jp": 1,
  "higashine.yamagata.jp": 1,
  "higashiomi.shiga.jp": 1,
  "higashiosaka.osaka.jp": 1,
  "higashishirakawa.gifu.jp": 1,
  "higashisumiyoshi.osaka.jp": 1,
  "higashitsuno.kochi.jp": 1,
  "higashiura.aichi.jp": 1,
  "higashiyama.kyoto.jp": 1,
  "higashiyamato.tokyo.jp": 1,
  "higashiyodogawa.osaka.jp": 1,
  "higashiyoshino.nara.jp": 1,
  "hiho.jp": 1,
  "hiji.oita.jp": 1,
  "hikari.yamaguchi.jp": 1,
  "hikawa.shimane.jp": 1,
  "hikimi.shimane.jp": 1,
  "hikone.shiga.jp": 1,
  "himeji.hyogo.jp": 1,
  "himeshima.oita.jp": 1,
  "himi.toyama.jp": 1,
  "hino.tokyo.jp": 1,
  "hino.tottori.jp": 1,
  "hinode.tokyo.jp": 1,
  "hinohara.tokyo.jp": 1,
  "hioki.kagoshima.jp": 1,
  "hippy.jp": 1,
  "hirado.nagasaki.jp": 1,
  "hiraizumi.iwate.jp": 1,
  "hirakata.osaka.jp": 1,
  "hiranai.aomori.jp": 1,
  "hirara.okinawa.jp": 1,
  "hirata.fukushima.jp": 1,
  "hiratsuka.kanagawa.jp": 1,
  "hiraya.nagano.jp": 1,
  "hirogawa.wakayama.jp": 1,
  "hirokawa.fukuoka.jp": 1,
  "hirono.fukushima.jp": 1,
  "hirono.iwate.jp": 1,
  "hiroo.hokkaido.jp": 1,
  "hirosaki.aomori.jp": 1,
  "hiroshima.jp": 1,
  "hisayama.fukuoka.jp": 1,
  "histoire.museum": 1,
  "historical.museum": 1,
  "historicalsociety.museum": 1,
  "historichouses.museum": 1,
  "historisch.museum": 1,
  "historisches.museum": 1,
  "history.museum": 1,
  "historyofscience.museum": 1,
  "hita.oita.jp": 1,
  "hitachi.ibaraki.jp": 1,
  "hitachinaka.ibaraki.jp": 1,
  "hitachiomiya.ibaraki.jp": 1,
  "hitachiota.ibaraki.jp": 1,
  "hitra.no": 1,
  "hizen.saga.jp": 1,
  "hjartdal.no": 1,
  "hjelmeland.no": 1,
  "hk.cn": 1,
  "hk.com": 1,
  "hk.org": 1,
  "hl.cn": 1,
  "hl.no": 1,
  "hlx.live": 1,
  "hlx.page": 1,
  "hlx3.page": 1,
  "hm.no": 1,
  "hn.cn": 1,
  "hobby-site.com": 1,
  "hobby-site.org": 1,
  "hobol.no": 1,
  "hof.no": 1,
  "hofu.yamaguchi.jp": 1,
  "hokkaido.jp": 1,
  "hokksund.no": 1,
  "hokuryu.hokkaido.jp": 1,
  "hokuto.hokkaido.jp": 1,
  "hokuto.yamanashi.jp": 1,
  "hol.no": 1,
  "hole.no": 1,
  "holmestrand.no": 1,
  "holtalen.no": 1,
  "holy.jp": 1,
  "home-webserver.de": 1,
  "home.dyndns.org": 1,
  "homebuilt.aero": 1,
  "homedns.org": 1,
  "homeftp.net": 1,
  "homeftp.org": 1,
  "homeip.net": 1,
  "homelink.one": 1,
  "homelinux.com": 1,
  "homelinux.net": 1,
  "homelinux.org": 1,
  "homeoffice.gov.uk": 1,
  "homesecuritymac.com": 1,
  "homesecuritypc.com": 1,
  "homesklep.pl": 1,
  "homeunix.com": 1,
  "homeunix.net": 1,
  "homeunix.org": 1,
  "honai.ehime.jp": 1,
  "honbetsu.hokkaido.jp": 1,
  "honefoss.no": 1,
  "hongo.hiroshima.jp": 1,
  "honjo.akita.jp": 1,
  "honjo.saitama.jp": 1,
  "honjyo.akita.jp": 1,
  "hoplix.shop": 1,
  "hopto.me": 1,
  "hopto.org": 1,
  "hornindal.no": 1,
  "horokanai.hokkaido.jp": 1,
  "horology.museum": 1,
  "horonobe.hokkaido.jp": 1,
  "horten.no": 1,
  "hosp.uk": 1,
  "hostedpi.com": 1,
  "hosting-cluster.nl": 1,
  "hosting.myjino.ru": 2,
  "hosting.ovh.net": 2,
  "hostyhosting.io": 1,
  "hotel.hu": 1,
  "hotel.lk": 1,
  "hotel.tz": 1,
  "hotelwithflight.com": 1,
  "house.museum": 1,
  "hoyanger.no": 1,
  "hoylandet.no": 1,
  "hr.eu.org": 1,
  "hra.health": 1,
  "hs.kr": 1,
  "hs.run": 1,
  "hs.zone": 1,
  "httpbin.org": 1,
  "hu.com": 1,
  "hu.eu.org": 1,
  "hu.net": 1,
  "huissier-justice.fr": 1,
  "humanities.museum": 1,
  "hungry.jp": 1,
  "hurdal.no": 1,
  "hurum.no": 1,
  "hvaler.no": 1,
  "hyllestad.no": 1,
  "hyogo.jp": 1,
  "hyuga.miyazaki.jp": 1,
  "hzc.io": 1,
  "i.bg": 1,
  "i.ng": 1,
  "i.ph": 1,
  "i.se": 1,
  "i234.me": 1,
  "ia.us": 1,
  "iamallama.com": 1,
  "ibara.okayama.jp": 1,
  "ibaraki.ibaraki.jp": 1,
  "ibaraki.jp": 1,
  "ibaraki.osaka.jp": 1,
  "ibestad.no": 1,
  "ibigawa.gifu.jp": 1,
  "ibxos.it": 1,
  "ic.gov.pl": 1,
  "ichiba.tokushima.jp": 1,
  "ichihara.chiba.jp": 1,
  "ichikai.tochigi.jp": 1,
  "ichikawa.chiba.jp": 1,
  "ichikawa.hyogo.jp": 1,
  "ichikawamisato.yamanashi.jp": 1,
  "ichinohe.iwate.jp": 1,
  "ichinomiya.aichi.jp": 1,
  "ichinomiya.chiba.jp": 1,
  "ichinoseki.iwate.jp": 1,
  "icurus.jp": 1,
  "id.au": 1,
  "id.firewalledreplit.co": 1,
  "id.forgerock.io": 1,
  "id.ir": 1,
  "id.lv": 1,
  "id.ly": 1,
  "id.repl.co": 1,
  "id.us": 1,
  "ide.kyoto.jp": 1,
  "idf.il": 1,
  "idrett.no": 1,
  "idv.hk": 1,
  "idv.tw": 1,
  "ie.eu.org": 1,
  "if.ua": 1,
  "iglesias-carbonia.it": 1,
  "iglesiascarbonia.it": 1,
  "iheya.okinawa.jp": 1,
  "iida.nagano.jp": 1,
  "iide.yamagata.jp": 1,
  "iijima.nagano.jp": 1,
  "iitate.fukushima.jp": 1,
  "iiyama.nagano.jp": 1,
  "iizuka.fukuoka.jp": 1,
  "iizuna.nagano.jp": 1,
  "ikaruga.nara.jp": 1,
  "ikata.ehime.jp": 1,
  "ikawa.akita.jp": 1,
  "ikeda.fukui.jp": 1,
  "ikeda.gifu.jp": 1,
  "ikeda.hokkaido.jp": 1,
  "ikeda.nagano.jp": 1,
  "ikeda.osaka.jp": 1,
  "iki.fi": 1,
  "iki.nagasaki.jp": 1,
  "ikoma.nara.jp": 1,
  "ikusaka.nagano.jp": 1,
  "il.eu.org": 1,
  "il.us": 1,
  "ilawa.pl": 1,
  "iliadboxos.it": 1,
  "illustration.museum": 1,
  "ilovecollege.info": 1,
  "im.it": 1,
  "imabari.ehime.jp": 1,
  "imageandsound.museum": 1,
  "imakane.hokkaido.jp": 1,
  "imari.saga.jp": 1,
  "imb.br": 1,
  "imizu.toyama.jp": 1,
  "imperia.it": 1,
  "impertrix.com": 1,
  "impertrixcdn.com": 1,
  "in-addr.arpa": 1,
  "in-berlin.de": 1,
  "in-brb.de": 1,
  "in-butter.de": 1,
  "in-dsl.de": 1,
  "in-dsl.net": 1,
  "in-dsl.org": 1,
  "in-the-band.net": 1,
  "in-vpn.de": 1,
  "in-vpn.net": 1,
  "in-vpn.org": 1,
  "in.eu.org": 1,
  "in.futurecms.at": 2,
  "in.london": 1,
  "in.na": 1,
  "in.net": 1,
  "in.ni": 1,
  "in.rs": 1,
  "in.th": 1,
  "in.ua": 1,
  "in.us": 1,
  "ina.ibaraki.jp": 1,
  "ina.nagano.jp": 1,
  "ina.saitama.jp": 1,
  "inabe.mie.jp": 1,
  "inagawa.hyogo.jp": 1,
  "inagi.tokyo.jp": 1,
  "inami.toyama.jp": 1,
  "inami.wakayama.jp": 1,
  "inashiki.ibaraki.jp": 1,
  "inatsuki.fukuoka.jp": 1,
  "inawashiro.fukushima.jp": 1,
  "inazawa.aichi.jp": 1,
  "inc.hk": 1,
  "incheon.kr": 1,
  "ind.br": 1,
  "ind.gt": 1,
  "ind.in": 1,
  "ind.kw": 1,
  "ind.tn": 1,
  "independent-commission.uk": 1,
  "independent-inquest.uk": 1,
  "independent-inquiry.uk": 1,
  "independent-panel.uk": 1,
  "independent-review.uk": 1,
  "inderoy.no": 1,
  "indian.museum": 1,
  "indiana.museum": 1,
  "indianapolis.museum": 1,
  "indianmarket.museum": 1,
  "indie.porn": 1,
  "indigena.bo": 1,
  "industria.bo": 1,
  "ine.kyoto.jp": 1,
  "inf.br": 1,
  "inf.cu": 1,
  "inf.mk": 1,
  "inf.ua": 1,
  "info.at": 1,
  "info.au": 1,
  "info.az": 1,
  "info.bb": 1,
  "info.bo": 1,
  "info.co": 1,
  "info.cx": 1,
  "info.ec": 1,
  "info.et": 1,
  "info.fj": 1,
  "info.gu": 1,
  "info.ht": 1,
  "info.hu": 1,
  "info.in": 1,
  "info.ke": 1,
  "info.ki": 1,
  "info.la": 1,
  "info.ls": 1,
  "info.mv": 1,
  "info.na": 1,
  "info.nf": 1,
  "info.ni": 1,
  "info.nr": 1,
  "info.pk": 1,
  "info.pl": 1,
  "info.pr": 1,
  "info.ro": 1,
  "info.sd": 1,
  "info.tn": 1,
  "info.tr": 1,
  "info.tt": 1,
  "info.tz": 1,
  "info.ve": 1,
  "info.vn": 1,
  "info.zm": 1,
  "ing.pa": 1,
  "ingatlan.hu": 1,
  "ino.kochi.jp": 1,
  "instance.datadetect.com": 1,
  "instances.spawn.cc": 1,
  "instantcloud.cn": 1,
  "insurance.aero": 1,
  "int.ar": 1,
  "int.az": 1,
  "int.bo": 1,
  "int.ci": 1,
  "int.co": 1,
  "int.cv": 1,
  "int.eu.org": 1,
  "int.in": 1,
  "int.is": 1,
  "int.la": 1,
  "int.lk": 1,
  "int.mv": 1,
  "int.mw": 1,
  "int.ni": 1,
  "int.pt": 1,
  "int.ru": 1,
  "int.tj": 1,
  "int.tt": 1,
  "int.ve": 1,
  "int.vn": 1,
  "intelligence.museum": 1,
  "interactive.museum": 1,
  "internet-dns.de": 1,
  "internet.in": 1,
  "intl.tn": 1,
  "inuyama.aichi.jp": 1,
  "inzai.chiba.jp": 1,
  "io.in": 1,
  "io.kg": 1,
  "iobb.net": 1,
  "iopsys.se": 1,
  "ip.linodeusercontent.com": 1,
  "ip6.arpa": 1,
  "ipifony.net": 1,
  "iraq.museum": 1,
  "iris.arpa": 1,
  "iron.museum": 1,
  "iruma.saitama.jp": 1,
  "is-a-anarchist.com": 1,
  "is-a-blogger.com": 1,
  "is-a-bookkeeper.com": 1,
  "is-a-bruinsfan.org": 1,
  "is-a-bulls-fan.com": 1,
  "is-a-candidate.org": 1,
  "is-a-caterer.com": 1,
  "is-a-celticsfan.org": 1,
  "is-a-chef.com": 1,
  "is-a-chef.net": 1,
  "is-a-chef.org": 1,
  "is-a-conservative.com": 1,
  "is-a-cpa.com": 1,
  "is-a-cubicle-slave.com": 1,
  "is-a-democrat.com": 1,
  "is-a-designer.com": 1,
  "is-a-doctor.com": 1,
  "is-a-financialadvisor.com": 1,
  "is-a-geek.com": 1,
  "is-a-geek.net": 1,
  "is-a-geek.org": 1,
  "is-a-green.com": 1,
  "is-a-guru.com": 1,
  "is-a-hard-worker.com": 1,
  "is-a-hunter.com": 1,
  "is-a-knight.org": 1,
  "is-a-landscaper.com": 1,
  "is-a-lawyer.com": 1,
  "is-a-liberal.com": 1,
  "is-a-libertarian.com": 1,
  "is-a-linux-user.org": 1,
  "is-a-llama.com": 1,
  "is-a-musician.com": 1,
  "is-a-nascarfan.com": 1,
  "is-a-nurse.com": 1,
  "is-a-painter.com": 1,
  "is-a-patsfan.org": 1,
  "is-a-personaltrainer.com": 1,
  "is-a-photographer.com": 1,
  "is-a-player.com": 1,
  "is-a-republican.com": 1,
  "is-a-rockstar.com": 1,
  "is-a-socialist.com": 1,
  "is-a-soxfan.org": 1,
  "is-a-student.com": 1,
  "is-a-teacher.com": 1,
  "is-a-techie.com": 1,
  "is-a-therapist.com": 1,
  "is-an-accountant.com": 1,
  "is-an-actor.com": 1,
  "is-an-actress.com": 1,
  "is-an-anarchist.com": 1,
  "is-an-artist.com": 1,
  "is-an-engineer.com": 1,
  "is-an-entertainer.com": 1,
  "is-by.us": 1,
  "is-certified.com": 1,
  "is-found.org": 1,
  "is-gone.com": 1,
  "is-into-anime.com": 1,
  "is-into-cars.com": 1,
  "is-into-cartoons.com": 1,
  "is-into-games.com": 1,
  "is-leet.com": 1,
  "is-lost.org": 1,
  "is-not-certified.com": 1,
  "is-saved.org": 1,
  "is-slick.com": 1,
  "is-uberleet.com": 1,
  "is-very-bad.org": 1,
  "is-very-evil.org": 1,
  "is-very-good.org": 1,
  "is-very-nice.org": 1,
  "is-very-sweet.org": 1,
  "is-with-theband.com": 1,
  "is.eu.org": 1,
  "is.gov.pl": 1,
  "is.it": 1,
  "isa-geek.com": 1,
  "isa-geek.net": 1,
  "isa-geek.org": 1,
  "isa-hockeynut.com": 1,
  "isa.kagoshima.jp": 1,
  "isa.us": 1,
  "isahaya.nagasaki.jp": 1,
  "ise.mie.jp": 1,
  "isehara.kanagawa.jp": 1,
  "isen.kagoshima.jp": 1,
  "isernia.it": 1,
  "iserv.dev": 1,
  "iservschule.de": 1,
  "isesaki.gunma.jp": 1,
  "ishigaki.okinawa.jp": 1,
  "ishikari.hokkaido.jp": 1,
  "ishikawa.fukushima.jp": 1,
  "ishikawa.jp": 1,
  "ishikawa.okinawa.jp": 1,
  "ishinomaki.miyagi.jp": 1,
  "isla.pr": 1,
  "isleofman.museum": 1,
  "isshiki.aichi.jp": 1,
  "issmarterthanyou.com": 1,
  "isteingeek.de": 1,
  "istmein.de": 1,
  "isumi.chiba.jp": 1,
  "it.ao": 1,
  "it.eu.org": 1,
  "it1.eur.aruba.jenv-aruba.cloud": 1,
  "it1.jenv-aruba.cloud": 1,
  "itabashi.tokyo.jp": 1,
  "itako.ibaraki.jp": 1,
  "itakura.gunma.jp": 1,
  "itami.hyogo.jp": 1,
  "itano.tokushima.jp": 1,
  "itayanagi.aomori.jp": 1,
  "itcouldbewor.se": 1,
  "itigo.jp": 1,
  "ito.shizuoka.jp": 1,
  "itoigawa.niigata.jp": 1,
  "itoman.okinawa.jp": 1,
  "its.me": 1,
  "ivano-frankivsk.ua": 1,
  "ivanovo.su": 1,
  "iveland.no": 1,
  "ivgu.no": 1,
  "iwade.wakayama.jp": 1,
  "iwafune.tochigi.jp": 1,
  "iwaizumi.iwate.jp": 1,
  "iwaki.fukushima.jp": 1,
  "iwakuni.yamaguchi.jp": 1,
  "iwakura.aichi.jp": 1,
  "iwama.ibaraki.jp": 1,
  "iwamizawa.hokkaido.jp": 1,
  "iwanai.hokkaido.jp": 1,
  "iwanuma.miyagi.jp": 1,
  "iwata.shizuoka.jp": 1,
  "iwate.iwate.jp": 1,
  "iwate.jp": 1,
  "iwatsuki.saitama.jp": 1,
  "iwi.nz": 1,
  "iyo.ehime.jp": 1,
  "iz.hr": 1,
  "izena.okinawa.jp": 1,
  "izu.shizuoka.jp": 1,
  "izumi.kagoshima.jp": 1,
  "izumi.osaka.jp": 1,
  "izumiotsu.osaka.jp": 1,
  "izumisano.osaka.jp": 1,
  "izumizaki.fukushima.jp": 1,
  "izumo.shimane.jp": 1,
  "izumozaki.niigata.jp": 1,
  "izunokuni.shizuoka.jp": 1,
  "j.bg": 1,
  "j.layershift.co.uk": 1,
  "j.scaleforce.com.cy": 1,
  "j.scaleforce.net": 1,
  "jab.br": 1,
  "jambyl.su": 1,
  "jamison.museum": 1,
  "jampa.br": 1,
  "jan-mayen.no": 1,
  "jaworzno.pl": 1,
  "jc.neen.it": 1,
  "jcloud-ver-jpc.ik-server.com": 1,
  "jcloud.ik-server.com": 1,
  "jcloud.kz": 1,
  "jdevcloud.com": 1,
  "jdf.br": 1,
  "jed.wafaicloud.com": 1,
  "jefferson.museum": 1,
  "jeju.kr": 1,
  "jelastic.dogado.eu": 1,
  "jelastic.regruhosting.ru": 1,
  "jelastic.saveincloud.net": 1,
  "jelastic.team": 1,
  "jelastic.tsukaeru.net": 1,
  "jele.cloud": 1,
  "jele.club": 1,
  "jele.host": 1,
  "jele.io": 1,
  "jele.site": 1,
  "jelenia-gora.pl": 1,
  "jellybean.jp": 1,
  "jeonbuk.kr": 1,
  "jeonnam.kr": 1,
  "jerusalem.museum": 1,
  "jessheim.no": 1,
  "jevnaker.no": 1,
  "jewelry.museum": 1,
  "jewish.museum": 1,
  "jewishart.museum": 1,
  "jfk.museum": 1,
  "jgora.pl": 1,
  "jinsekikogen.hiroshima.jp": 1,
  "jl.cn": 1,
  "jls-sto1.elastx.net": 1,
  "jls-sto2.elastx.net": 1,
  "jls-sto3.elastx.net": 1,
  "jm": 2,
  "joboji.iwate.jp": 1,
  "jobs.tt": 1,
  "joetsu.niigata.jp": 1,
  "jogasz.hu": 1,
  "johana.toyama.jp": 1,
  "joinville.br": 1,
  "jolster.no": 1,
  "jondal.no": 1,
  "jor.br": 1,
  "jorpeland.no": 1,
  "joso.ibaraki.jp": 1,
  "jotelulu.cloud": 1,
  "journal.aero": 1,
  "journalism.museum": 1,
  "journalist.aero": 1,
  "joyo.kyoto.jp": 1,
  "jozi.biz": 1,
  "jp.eu.org": 1,
  "jp.kg": 1,
  "jp.md": 1,
  "jp.net": 1,
  "jpn.com": 1,
  "js.cn": 1,
  "js.org": 1,
  "js.wpenginepowered.com": 1,
  "ju.mp": 1,
  "judaica.museum": 1,
  "judygarland.museum": 1,
  "juedisches.museum": 1,
  "juif.museum": 1,
  "jur.pro": 1,
  "jus.br": 1,
  "jx.cn": 1,
  "k.bg": 1,
  "k.se": 1,
  "k12.ak.us": 1,
  "k12.al.us": 1,
  "k12.ar.us": 1,
  "k12.as.us": 1,
  "k12.az.us": 1,
  "k12.ca.us": 1,
  "k12.co.us": 1,
  "k12.ct.us": 1,
  "k12.dc.us": 1,
  "k12.de.us": 1,
  "k12.ec": 1,
  "k12.fl.us": 1,
  "k12.ga.us": 1,
  "k12.gu.us": 1,
  "k12.ia.us": 1,
  "k12.id.us": 1,
  "k12.il": 1,
  "k12.il.us": 1,
  "k12.in.us": 1,
  "k12.ks.us": 1,
  "k12.ky.us": 1,
  "k12.la.us": 1,
  "k12.ma.us": 1,
  "k12.md.us": 1,
  "k12.me.us": 1,
  "k12.mi.us": 1,
  "k12.mn.us": 1,
  "k12.mo.us": 1,
  "k12.ms.us": 1,
  "k12.mt.us": 1,
  "k12.nc.us": 1,
  "k12.ne.us": 1,
  "k12.nh.us": 1,
  "k12.nj.us": 1,
  "k12.nm.us": 1,
  "k12.nv.us": 1,
  "k12.ny.us": 1,
  "k12.oh.us": 1,
  "k12.ok.us": 1,
  "k12.or.us": 1,
  "k12.pa.us": 1,
  "k12.pr.us": 1,
  "k12.sc.us": 1,
  "k12.tn.us": 1,
  "k12.tr": 1,
  "k12.tx.us": 1,
  "k12.ut.us": 1,
  "k12.va.us": 1,
  "k12.vi": 1,
  "k12.vi.us": 1,
  "k12.vt.us": 1,
  "k12.wa.us": 1,
  "k12.wi.us": 1,
  "k12.wy.us": 1,
  "k8s.fr-par.scw.cloud": 1,
  "k8s.nl-ams.scw.cloud": 1,
  "k8s.pl-waw.scw.cloud": 1,
  "k8s.scw.cloud": 1,
  "kaas.gg": 1,
  "kadena.okinawa.jp": 1,
  "kadogawa.miyazaki.jp": 1,
  "kadoma.osaka.jp": 1,
  "kafjord.no": 1,
  "kaga.ishikawa.jp": 1,
  "kagami.kochi.jp": 1,
  "kagamiishi.fukushima.jp": 1,
  "kagamino.okayama.jp": 1,
  "kagawa.jp": 1,
  "kagoshima.jp": 1,
  "kagoshima.kagoshima.jp": 1,
  "kaho.fukuoka.jp": 1,
  "kahoku.ishikawa.jp": 1,
  "kahoku.yamagata.jp": 1,
  "kai.yamanashi.jp": 1,
  "kainan.tokushima.jp": 1,
  "kainan.wakayama.jp": 1,
  "kaisei.kanagawa.jp": 1,
  "kaita.hiroshima.jp": 1,
  "kaizuka.osaka.jp": 1,
  "kakamigahara.gifu.jp": 1,
  "kakegawa.shizuoka.jp": 1,
  "kakinoki.shimane.jp": 1,
  "kakogawa.hyogo.jp": 1,
  "kakuda.miyagi.jp": 1,
  "kalisz.pl": 1,
  "kalmykia.ru": 1,
  "kalmykia.su": 1,
  "kaluga.su": 1,
  "kamagaya.chiba.jp": 1,
  "kamaishi.iwate.jp": 1,
  "kamakura.kanagawa.jp": 1,
  "kameoka.kyoto.jp": 1,
  "kameyama.mie.jp": 1,
  "kami.kochi.jp": 1,
  "kami.miyagi.jp": 1,
  "kamiamakusa.kumamoto.jp": 1,
  "kamifurano.hokkaido.jp": 1,
  "kamigori.hyogo.jp": 1,
  "kamiichi.toyama.jp": 1,
  "kamiizumi.saitama.jp": 1,
  "kamijima.ehime.jp": 1,
  "kamikawa.hokkaido.jp": 1,
  "kamikawa.hyogo.jp": 1,
  "kamikawa.saitama.jp": 1,
  "kamikitayama.nara.jp": 1,
  "kamikoani.akita.jp": 1,
  "kamimine.saga.jp": 1,
  "kaminokawa.tochigi.jp": 1,
  "kaminoyama.yamagata.jp": 1,
  "kamioka.akita.jp": 1,
  "kamisato.saitama.jp": 1,
  "kamishihoro.hokkaido.jp": 1,
  "kamisu.ibaraki.jp": 1,
  "kamisunagawa.hokkaido.jp": 1,
  "kamitonda.wakayama.jp": 1,
  "kamitsue.oita.jp": 1,
  "kamo.kyoto.jp": 1,
  "kamo.niigata.jp": 1,
  "kamoenai.hokkaido.jp": 1,
  "kamogawa.chiba.jp": 1,
  "kanagawa.jp": 1,
  "kanan.osaka.jp": 1,
  "kanazawa.ishikawa.jp": 1,
  "kanegasaki.iwate.jp": 1,
  "kaneyama.fukushima.jp": 1,
  "kaneyama.yamagata.jp": 1,
  "kani.gifu.jp": 1,
  "kanie.aichi.jp": 1,
  "kanmaki.nara.jp": 1,
  "kanna.gunma.jp": 1,
  "kannami.shizuoka.jp": 1,
  "kanonji.kagawa.jp": 1,
  "kanoya.kagoshima.jp": 1,
  "kanra.gunma.jp": 1,
  "kanuma.tochigi.jp": 1,
  "kanzaki.saga.jp": 1,
  "kapsi.fi": 1,
  "karacol.su": 1,
  "karaganda.su": 1,
  "karasjohka.no": 1,
  "karasjok.no": 1,
  "karasuyama.tochigi.jp": 1,
  "karate.museum": 1,
  "karatsu.saga.jp": 1,
  "karelia.su": 1,
  "karikatur.museum": 1,
  "kariwa.niigata.jp": 1,
  "kariya.aichi.jp": 1,
  "karlsoy.no": 1,
  "karmoy.no": 1,
  "karpacz.pl": 1,
  "kartuzy.pl": 1,
  "karuizawa.nagano.jp": 1,
  "karumai.iwate.jp": 1,
  "kasahara.gifu.jp": 1,
  "kasai.hyogo.jp": 1,
  "kasama.ibaraki.jp": 1,
  "kasamatsu.gifu.jp": 1,
  "kasaoka.okayama.jp": 1,
  "kashiba.nara.jp": 1,
  "kashihara.nara.jp": 1,
  "kashima.ibaraki.jp": 1,
  "kashima.saga.jp": 1,
  "kashiwa.chiba.jp": 1,
  "kashiwara.osaka.jp": 1,
  "kashiwazaki.niigata.jp": 1,
  "kasserver.com": 1,
  "kasuga.fukuoka.jp": 1,
  "kasuga.hyogo.jp": 1,
  "kasugai.aichi.jp": 1,
  "kasukabe.saitama.jp": 1,
  "kasumigaura.ibaraki.jp": 1,
  "kasuya.fukuoka.jp": 1,
  "kaszuby.pl": 1,
  "katagami.akita.jp": 1,
  "katano.osaka.jp": 1,
  "katashina.gunma.jp": 1,
  "katori.chiba.jp": 1,
  "katowice.pl": 1,
  "katsuragi.nara.jp": 1,
  "katsuragi.wakayama.jp": 1,
  "katsushika.tokyo.jp": 1,
  "katsuura.chiba.jp": 1,
  "katsuyama.fukui.jp": 1,
  "kautokeino.no": 1,
  "kawaba.gunma.jp": 1,
  "kawachinagano.osaka.jp": 1,
  "kawagoe.mie.jp": 1,
  "kawagoe.saitama.jp": 1,
  "kawaguchi.saitama.jp": 1,
  "kawahara.tottori.jp": 1,
  "kawai.iwate.jp": 1,
  "kawai.nara.jp": 1,
  "kawaiishop.jp": 1,
  "kawajima.saitama.jp": 1,
  "kawakami.nagano.jp": 1,
  "kawakami.nara.jp": 1,
  "kawakita.ishikawa.jp": 1,
  "kawamata.fukushima.jp": 1,
  "kawaminami.miyazaki.jp": 1,
  "kawanabe.kagoshima.jp": 1,
  "kawanehon.shizuoka.jp": 1,
  "kawanishi.hyogo.jp": 1,
  "kawanishi.nara.jp": 1,
  "kawanishi.yamagata.jp": 1,
  "kawara.fukuoka.jp": 1,
  "kawasaki.jp": 2,
  "kawasaki.miyagi.jp": 1,
  "kawatana.nagasaki.jp": 1,
  "kawaue.gifu.jp": 1,
  "kawazu.shizuoka.jp": 1,
  "kayabe.hokkaido.jp": 1,
  "kazimierz-dolny.pl": 1,
  "kazo.saitama.jp": 1,
  "kazuno.akita.jp": 1,
  "keisen.fukuoka.jp": 1,
  "keliweb.cloud": 1,
  "kembuchi.hokkaido.jp": 1,
  "kep.tr": 1,
  "kepno.pl": 1,
  "ketrzyn.pl": 1,
  "keymachine.de": 1,
  "kg.kr": 1,
  "kh": 2,
  "kh.ua": 1,
  "khakassia.su": 1,
  "kharkiv.ua": 1,
  "kharkov.ua": 1,
  "kherson.ua": 1,
  "khmelnitskiy.ua": 1,
  "khmelnytskyi.ua": 1,
  "khplay.nl": 1,
  "kibichuo.okayama.jp": 1,
  "kicks-ass.net": 1,
  "kicks-ass.org": 1,
  "kids.museum": 1,
  "kids.us": 1,
  "kiev.ua": 1,
  "kiho.mie.jp": 1,
  "kihoku.ehime.jp": 1,
  "kijo.miyazaki.jp": 1,
  "kikirara.jp": 1,
  "kikonai.hokkaido.jp": 1,
  "kikuchi.kumamoto.jp": 1,
  "kikugawa.shizuoka.jp": 1,
  "kilatiron.com": 1,
  "kill.jp": 1,
  "kilo.jp": 1,
  "kimino.wakayama.jp": 1,
  "kimitsu.chiba.jp": 1,
  "kimobetsu.hokkaido.jp": 1,
  "kin.okinawa.jp": 1,
  "kinghost.net": 1,
  "kinko.kagoshima.jp": 1,
  "kinokawa.wakayama.jp": 1,
  "kira.aichi.jp": 1,
  "kirkenes.no": 1,
  "kirovograd.ua": 1,
  "kiryu.gunma.jp": 1,
  "kisarazu.chiba.jp": 1,
  "kishiwada.osaka.jp": 1,
  "kiso.nagano.jp": 1,
  "kisofukushima.nagano.jp": 1,
  "kisosaki.mie.jp": 1,
  "kita.kyoto.jp": 1,
  "kita.osaka.jp": 1,
  "kita.tokyo.jp": 1,
  "kitaaiki.nagano.jp": 1,
  "kitaakita.akita.jp": 1,
  "kitadaito.okinawa.jp": 1,
  "kitagata.gifu.jp": 1,
  "kitagata.saga.jp": 1,
  "kitagawa.kochi.jp": 1,
  "kitagawa.miyazaki.jp": 1,
  "kitahata.saga.jp": 1,
  "kitahiroshima.hokkaido.jp": 1,
  "kitakami.iwate.jp": 1,
  "kitakata.fukushima.jp": 1,
  "kitakata.miyazaki.jp": 1,
  "kitakyushu.jp": 2,
  "kitami.hokkaido.jp": 1,
  "kitamoto.saitama.jp": 1,
  "kitanakagusuku.okinawa.jp": 1,
  "kitashiobara.fukushima.jp": 1,
  "kitaura.miyazaki.jp": 1,
  "kitayama.wakayama.jp": 1,
  "kiwa.mie.jp": 1,
  "kiwi.nz": 1,
  "kiyama.saga.jp": 1,
  "kiyokawa.kanagawa.jp": 1,
  "kiyosato.hokkaido.jp": 1,
  "kiyose.tokyo.jp": 1,
  "kiyosu.aichi.jp": 1,
  "kizu.kyoto.jp": 1,
  "klabu.no": 1,
  "klepp.no": 1,
  "klodzko.pl": 1,
  "km.ua": 1,
  "kmpsp.gov.pl": 1,
  "knightpoint.systems": 1,
  "knowsitall.info": 1,
  "knx-server.net": 1,
  "kobayashi.miyazaki.jp": 1,
  "kobe.jp": 2,
  "kobierzyce.pl": 1,
  "kochi.jp": 1,
  "kochi.kochi.jp": 1,
  "kodaira.tokyo.jp": 1,
  "koebenhavn.museum": 1,
  "koeln.museum": 1,
  "kofu.yamanashi.jp": 1,
  "koga.fukuoka.jp": 1,
  "koga.ibaraki.jp": 1,
  "koganei.tokyo.jp": 1,
  "koge.tottori.jp": 1,
  "koka.shiga.jp": 1,
  "kokonoe.oita.jp": 1,
  "kokubunji.tokyo.jp": 1,
  "kolobrzeg.pl": 1,
  "komae.tokyo.jp": 1,
  "komagane.nagano.jp": 1,
  "komaki.aichi.jp": 1,
  "komatsu.ishikawa.jp": 1,
  "komatsushima.tokushima.jp": 1,
  "komforb.se": 1,
  "kommunalforbund.se": 1,
  "kommune.no": 1,
  "komono.mie.jp": 1,
  "komoro.nagano.jp": 1,
  "komvux.se": 1,
  "konan.aichi.jp": 1,
  "konan.shiga.jp": 1,
  "kongsberg.no": 1,
  "kongsvinger.no": 1,
  "konin.pl": 1,
  "konskowola.pl": 1,
  "konsulat.gov.pl": 1,
  "konyvelo.hu": 1,
  "koobin.events": 1,
  "koori.fukushima.jp": 1,
  "kopervik.no": 1,
  "koriyama.fukushima.jp": 1,
  "koryo.nara.jp": 1,
  "kosai.shizuoka.jp": 1,
  "kosaka.akita.jp": 1,
  "kosei.shiga.jp": 1,
  "koshigaya.saitama.jp": 1,
  "koshimizu.hokkaido.jp": 1,
  "koshu.yamanashi.jp": 1,
  "kosuge.yamanashi.jp": 1,
  "kota.aichi.jp": 1,
  "koto.shiga.jp": 1,
  "koto.tokyo.jp": 1,
  "kotohira.kagawa.jp": 1,
  "kotoura.tottori.jp": 1,
  "kouhoku.saga.jp": 1,
  "kounosu.saitama.jp": 1,
  "kouyama.kagoshima.jp": 1,
  "kouzushima.tokyo.jp": 1,
  "koya.wakayama.jp": 1,
  "koza.wakayama.jp": 1,
  "kozagawa.wakayama.jp": 1,
  "kozaki.chiba.jp": 1,
  "kozow.com": 1,
  "kppsp.gov.pl": 1,
  "kr.com": 1,
  "kr.eu.org": 1,
  "kr.it": 1,
  "kr.ua": 1,
  "kraanghke.no": 1,
  "kragero.no": 1,
  "krakow.pl": 1,
  "krasnik.pl": 1,
  "krasnodar.su": 1,
  "krellian.net": 1,
  "kristiansand.no": 1,
  "kristiansund.no": 1,
  "krodsherad.no": 1,
  "krokstadelva.no": 1,
  "krym.ua": 1,
  "ks.ua": 1,
  "ks.us": 1,
  "ktistory.com": 1,
  "kuchinotsu.nagasaki.jp": 1,
  "kudamatsu.yamaguchi.jp": 1,
  "kudoyama.wakayama.jp": 1,
  "kui.hiroshima.jp": 1,
  "kuji.iwate.jp": 1,
  "kuju.oita.jp": 1,
  "kujukuri.chiba.jp": 1,
  "kuki.saitama.jp": 1,
  "kuleuven.cloud": 1,
  "kumagaya.saitama.jp": 1,
  "kumakogen.ehime.jp": 1,
  "kumamoto.jp": 1,
  "kumamoto.kumamoto.jp": 1,
  "kumano.hiroshima.jp": 1,
  "kumano.mie.jp": 1,
  "kumatori.osaka.jp": 1,
  "kumejima.okinawa.jp": 1,
  "kumenan.okayama.jp": 1,
  "kumiyama.kyoto.jp": 1,
  "kunden.ortsinfo.at": 2,
  "kunigami.okinawa.jp": 1,
  "kunimi.fukushima.jp": 1,
  "kunisaki.oita.jp": 1,
  "kunitachi.tokyo.jp": 1,
  "kunitomi.miyazaki.jp": 1,
  "kunneppu.hokkaido.jp": 1,
  "kunohe.iwate.jp": 1,
  "kunst.museum": 1,
  "kunstsammlung.museum": 1,
  "kunstunddesign.museum": 1,
  "kurashiki.okayama.jp": 1,
  "kurate.fukuoka.jp": 1,
  "kure.hiroshima.jp": 1,
  "kurgan.su": 1,
  "kuriyama.hokkaido.jp": 1,
  "kurobe.toyama.jp": 1,
  "kurogi.fukuoka.jp": 1,
  "kuroishi.aomori.jp": 1,
  "kuroiso.tochigi.jp": 1,
  "kuromatsunai.hokkaido.jp": 1,
  "kuron.jp": 1,
  "kurotaki.nara.jp": 1,
  "kurume.fukuoka.jp": 1,
  "kusatsu.gunma.jp": 1,
  "kusatsu.shiga.jp": 1,
  "kushima.miyazaki.jp": 1,
  "kushimoto.wakayama.jp": 1,
  "kushiro.hokkaido.jp": 1,
  "kustanai.ru": 1,
  "kustanai.su": 1,
  "kusu.oita.jp": 1,
  "kutchan.hokkaido.jp": 1,
  "kutno.pl": 1,
  "kuwana.mie.jp": 1,
  "kuzumaki.iwate.jp": 1,
  "kv.ua": 1,
  "kvafjord.no": 1,
  "kvalsund.no": 1,
  "kvam.no": 1,
  "kvanangen.no": 1,
  "kvinesdal.no": 1,
  "kvinnherad.no": 1,
  "kviteseid.no": 1,
  "kvitsoy.no": 1,
  "kwp.gov.pl": 1,
  "kwpsp.gov.pl": 1,
  "ky.us": 1,
  "kyiv.ua": 1,
  "kyonan.chiba.jp": 1,
  "kyotamba.kyoto.jp": 1,
  "kyotanabe.kyoto.jp": 1,
  "kyotango.kyoto.jp": 1,
  "kyoto.jp": 1,
  "kyowa.akita.jp": 1,
  "kyowa.hokkaido.jp": 1,
  "kyuragi.saga.jp": 1,
  "l-o-g-i-n.de": 1,
  "l.bg": 1,
  "l.se": 1,
  "la-spezia.it": 1,
  "la.us": 1,
  "laakesvuemie.no": 1,
  "lab.ms": 1,
  "labor.museum": 1,
  "labour.museum": 1,
  "lahppi.no": 1,
  "lajolla.museum": 1,
  "lakas.hu": 1,
  "lanbib.se": 1,
  "lancashire.museum": 1,
  "land-4-sale.us": 1,
  "landes.museum": 1,
  "landing.myjino.ru": 2,
  "langevag.no": 1,
  "lans.museum": 1,
  "lapy.pl": 1,
  "laquila.it": 1,
  "lardal.no": 1,
  "larsson.museum": 1,
  "larvik.no": 1,
  "laspezia.it": 1,
  "latina.it": 1,
  "lavagis.no": 1,
  "lavangen.no": 1,
  "law.pro": 1,
  "law.za": 1,
  "laz.it": 1,
  "lazio.it": 1,
  "lc.it": 1,
  "lcl.dev": 2,
  "lclstage.dev": 2,
  "lcube-server.de": 1,
  "le.it": 1,
  "leadpages.co": 1,
  "leangaviika.no": 1,
  "leasing.aero": 1,
  "lebesby.no": 1,
  "lebork.pl": 1,
  "lebtimnetz.de": 1,
  "lecce.it": 1,
  "lecco.it": 1,
  "leczna.pl": 1,
  "leg.br": 1,
  "legnica.pl": 1,
  "leikanger.no": 1,
  "leirfjord.no": 1,
  "leirvik.no": 1,
  "leitungsen.de": 1,
  "leka.no": 1,
  "leksvik.no": 1,
  "lel.br": 1,
  "lelux.site": 1,
  "lenug.su": 1,
  "lenvik.no": 1,
  "lerdal.no": 1,
  "lesja.no": 1,
  "levanger.no": 1,
  "lewismiller.museum": 1,
  "lezajsk.pl": 1,
  "lg.jp": 1,
  "lg.ua": 1,
  "li.it": 1,
  "lib.ak.us": 1,
  "lib.al.us": 1,
  "lib.ar.us": 1,
  "lib.as.us": 1,
  "lib.az.us": 1,
  "lib.ca.us": 1,
  "lib.co.us": 1,
  "lib.ct.us": 1,
  "lib.dc.us": 1,
  "lib.de.us": 1,
  "lib.ee": 1,
  "lib.fl.us": 1,
  "lib.ga.us": 1,
  "lib.gu.us": 1,
  "lib.hi.us": 1,
  "lib.ia.us": 1,
  "lib.id.us": 1,
  "lib.il.us": 1,
  "lib.in.us": 1,
  "lib.ks.us": 1,
  "lib.ky.us": 1,
  "lib.la.us": 1,
  "lib.ma.us": 1,
  "lib.md.us": 1,
  "lib.me.us": 1,
  "lib.mi.us": 1,
  "lib.mn.us": 1,
  "lib.mo.us": 1,
  "lib.ms.us": 1,
  "lib.mt.us": 1,
  "lib.nc.us": 1,
  "lib.nd.us": 1,
  "lib.ne.us": 1,
  "lib.nh.us": 1,
  "lib.nj.us": 1,
  "lib.nm.us": 1,
  "lib.nv.us": 1,
  "lib.ny.us": 1,
  "lib.oh.us": 1,
  "lib.ok.us": 1,
  "lib.or.us": 1,
  "lib.pa.us": 1,
  "lib.pr.us": 1,
  "lib.ri.us": 1,
  "lib.sc.us": 1,
  "lib.sd.us": 1,
  "lib.tn.us": 1,
  "lib.tx.us": 1,
  "lib.ut.us": 1,
  "lib.va.us": 1,
  "lib.vi.us": 1,
  "lib.vt.us": 1,
  "lib.wa.us": 1,
  "lib.wi.us": 1,
  "lib.wy.us": 1,
  "lier.no": 1,
  "lierne.no": 1,
  "lig.it": 1,
  "liguria.it": 1,
  "likes-pie.com": 1,
  "likescandy.com": 1,
  "lillehammer.no": 1,
  "lillesand.no": 1,
  "lima-city.at": 1,
  "lima-city.ch": 1,
  "lima-city.de": 1,
  "lima-city.rocks": 1,
  "lima.zone": 1,
  "limanowa.pl": 1,
  "lincoln.museum": 1,
  "lindas.no": 1,
  "lindesnes.no": 1,
  "linkyard-cloud.ch": 1,
  "linkyard.cloud": 1,
  "linodeobjects.com": 2,
  "linz.museum": 1,
  "littlestar.jp": 1,
  "living.museum": 1,
  "livinghistory.museum": 1,
  "livorno.it": 1,
  "lk3.ru": 1,
  "ln.cn": 1,
  "lo.it": 1,
  "loabat.no": 1,
  "localhistory.museum": 1,
  "localhost.daplie.me": 1,
  "localzone.xyz": 1,
  "lodi.it": 1,
  "lodingen.no": 1,
  "log.br": 1,
  "loginline.app": 1,
  "loginline.dev": 1,
  "loginline.io": 1,
  "loginline.services": 1,
  "loginline.site": 1,
  "loginto.me": 1,
  "logistics.aero": 1,
  "logoip.com": 1,
  "logoip.de": 1,
  "lohmus.me": 1,
  "lolipop.io": 1,
  "lolipopmc.jp": 1,
  "lolitapunk.jp": 1,
  "lom.it": 1,
  "lom.no": 1,
  "lombardia.it": 1,
  "lombardy.it": 1,
  "lomo.jp": 1,
  "lomza.pl": 1,
  "lon-1.paas.massivegrid.net": 1,
  "lon-2.paas.massivegrid.net": 1,
  "lon.wafaicloud.com": 1,
  "london.cloudapps.digital": 1,
  "london.museum": 1,
  "londrina.br": 1,
  "loppa.no": 1,
  "lorenskog.no": 1,
  "losangeles.museum": 1,
  "loseyourip.com": 1,
  "loten.no": 1,
  "louvre.museum": 1,
  "lovepop.jp": 1,
  "lovesick.jp": 1,
  "lowicz.pl": 1,
  "loyalist.museum": 1,
  "lpages.co": 1,
  "lpusercontent.com": 1,
  "lt.eu.org": 1,
  "lt.it": 1,
  "lt.ua": 1,
  "ltd.co.im": 1,
  "ltd.cy": 1,
  "ltd.gi": 1,
  "ltd.hk": 1,
  "ltd.lk": 1,
  "ltd.ng": 1,
  "ltd.ua": 1,
  "ltd.uk": 1,
  "lu.eu.org": 1,
  "lu.it": 1,
  "lubartow.pl": 1,
  "lubin.pl": 1,
  "lublin.pl": 1,
  "lucania.it": 1,
  "lucca.it": 1,
  "lucerne.museum": 1,
  "lug.org.uk": 1,
  "lugansk.ua": 1,
  "lugs.org.uk": 1,
  "lukow.pl": 1,
  "lund.no": 1,
  "lunner.no": 1,
  "luroy.no": 1,
  "luster.no": 1,
  "lutsk.ua": 1,
  "luxembourg.museum": 1,
  "luzern.museum": 1,
  "lv.eu.org": 1,
  "lv.ua": 1,
  "lviv.ua": 1,
  "lyngdal.no": 1,
  "lyngen.no": 1,
  "lynx.mythic-beasts.com": 1,
  "m.bg": 1,
  "m.se": 1,
  "ma.gov.br": 1,
  "ma.leg.br": 1,
  "ma.us": 1,
  "macapa.br": 1,
  "maceio.br": 1,
  "macerata.it": 1,
  "machida.tokyo.jp": 1,
  "mad.museum": 1,
  "madrid.museum": 1,
  "maebashi.gunma.jp": 1,
  "magazine.aero": 1,
  "magentosite.cloud": 2,
  "magnet.page": 1,
  "maibara.shiga.jp": 1,
  "mail.pl": 1,
  "main.jp": 1,
  "maintenance.aero": 1,
  "maizuru.kyoto.jp": 1,
  "makinohara.shizuoka.jp": 1,
  "makurazaki.kagoshima.jp": 1,
  "malatvuopmi.no": 1,
  "malbork.pl": 1,
  "mallorca.museum": 1,
  "malopolska.pl": 1,
  "malselv.no": 1,
  "malvik.no": 1,
  "mamurogawa.yamagata.jp": 1,
  "manaus.br": 1,
  "manchester.museum": 1,
  "mandal.no": 1,
  "mangyshlak.su": 1,
  "maniwa.okayama.jp": 1,
  "manno.kagawa.jp": 1,
  "mansion.museum": 1,
  "mansions.museum": 1,
  "mantova.it": 1,
  "manx.museum": 1,
  "maori.nz": 1,
  "map.fastly.net": 1,
  "map.fastlylb.net": 1,
  "mar.it": 1,
  "marburg.museum": 1,
  "marche.it": 1,
  "marine.ru": 1,
  "maringa.br": 1,
  "maritime.museum": 1,
  "maritimo.museum": 1,
  "marker.no": 1,
  "marnardal.no": 1,
  "marugame.kagawa.jp": 1,
  "marumori.miyagi.jp": 1,
  "maryland.museum": 1,
  "marylhurst.museum": 1,
  "masaki.ehime.jp": 1,
  "masfjorden.no": 1,
  "mashike.hokkaido.jp": 1,
  "mashiki.kumamoto.jp": 1,
  "mashiko.tochigi.jp": 1,
  "masoy.no": 1,
  "massa-carrara.it": 1,
  "massacarrara.it": 1,
  "masuda.shimane.jp": 1,
  "mat.br": 1,
  "matera.it": 1,
  "matsubara.osaka.jp": 1,
  "matsubushi.saitama.jp": 1,
  "matsuda.kanagawa.jp": 1,
  "matsudo.chiba.jp": 1,
  "matsue.shimane.jp": 1,
  "matsukawa.nagano.jp": 1,
  "matsumae.hokkaido.jp": 1,
  "matsumoto.kagoshima.jp": 1,
  "matsumoto.nagano.jp": 1,
  "matsuno.ehime.jp": 1,
  "matsusaka.mie.jp": 1,
  "matsushige.tokushima.jp": 1,
  "matsushima.miyagi.jp": 1,
  "matsuura.nagasaki.jp": 1,
  "matsuyama.ehime.jp": 1,
  "matsuzaki.shizuoka.jp": 1,
  "matta-varjjat.no": 1,
  "mayfirst.info": 1,
  "mayfirst.org": 1,
  "mazeplay.com": 1,
  "mazowsze.pl": 1,
  "mazury.pl": 1,
  "mb.ca": 1,
  "mb.it": 1,
  "mc.ax": 1,
  "mc.eu.org": 1,
  "mc.it": 1,
  "mcdir.me": 1,
  "mcdir.ru": 1,
  "mcpe.me": 1,
  "mcpre.ru": 1,
  "md.ci": 1,
  "md.us": 1,
  "me.eu.org": 1,
  "me.in": 1,
  "me.it": 1,
  "me.ke": 1,
  "me.so": 1,
  "me.ss": 1,
  "me.tc": 1,
  "me.tz": 1,
  "me.uk": 1,
  "me.us": 1,
  "me.vu": 1,
  "med.br": 1,
  "med.ec": 1,
  "med.ee": 1,
  "med.ht": 1,
  "med.ly": 1,
  "med.om": 1,
  "med.pa": 1,
  "med.pl": 1,
  "med.pro": 1,
  "med.sa": 1,
  "med.sd": 1,
  "medecin.fr": 1,
  "medecin.km": 1,
  "media.aero": 1,
  "media.hu": 1,
  "media.museum": 1,
  "media.pl": 1,
  "mediatech.by": 1,
  "mediatech.dev": 1,
  "medical.museum": 1,
  "medicina.bo": 1,
  "medio-campidano.it": 1,
  "mediocampidano.it": 1,
  "medizinhistorisches.museum": 1,
  "meeres.museum": 1,
  "meguro.tokyo.jp": 1,
  "mein-iserv.de": 1,
  "mein-vigor.de": 1,
  "meinforum.net": 1,
  "meiwa.gunma.jp": 1,
  "meiwa.mie.jp": 1,
  "mel.cloudlets.com.au": 1,
  "meland.no": 1,
  "meldal.no": 1,
  "melhus.no": 1,
  "meloy.no": 1,
  "members.linode.com": 1,
  "memorial.museum": 1,
  "memset.net": 1,
  "meraker.no": 1,
  "merseine.nu": 1,
  "mesaverde.museum": 1,
  "messerli.app": 1,
  "messina.it": 1,
  "messwithdns.com": 1,
  "meteorapp.com": 1,
  "mex.com": 1,
  "mg.gov.br": 1,
  "mg.leg.br": 1,
  "mi.it": 1,
  "mi.th": 1,
  "mi.us": 1,
  "miasa.nagano.jp": 1,
  "miasta.pl": 1,
  "mibu.tochigi.jp": 1,
  "michigan.museum": 1,
  "microlight.aero": 1,
  "midatlantic.museum": 1,
  "midori.chiba.jp": 1,
  "midori.gunma.jp": 1,
  "midsund.no": 1,
  "midtre-gauldal.no": 1,
  "mie.jp": 1,
  "mielec.pl": 1,
  "mielno.pl": 1,
  "mifune.kumamoto.jp": 1,
  "migration.run": 2,
  "mihama.aichi.jp": 1,
  "mihama.chiba.jp": 1,
  "mihama.fukui.jp": 1,
  "mihama.mie.jp": 1,
  "mihama.wakayama.jp": 1,
  "mihara.hiroshima.jp": 1,
  "mihara.kochi.jp": 1,
  "miharu.fukushima.jp": 1,
  "miho.ibaraki.jp": 1,
  "mikasa.hokkaido.jp": 1,
  "mikawa.yamagata.jp": 1,
  "miki.hyogo.jp": 1,
  "mil.ac": 1,
  "mil.ae": 1,
  "mil.al": 1,
  "mil.ar": 1,
  "mil.az": 1,
  "mil.ba": 1,
  "mil.bo": 1,
  "mil.br": 1,
  "mil.by": 1,
  "mil.cl": 1,
  "mil.cn": 1,
  "mil.co": 1,
  "mil.cy": 1,
  "mil.do": 1,
  "mil.ec": 1,
  "mil.eg": 1,
  "mil.fj": 1,
  "mil.ge": 1,
  "mil.gh": 1,
  "mil.gt": 1,
  "mil.hn": 1,
  "mil.id": 1,
  "mil.in": 1,
  "mil.iq": 1,
  "mil.jo": 1,
  "mil.kg": 1,
  "mil.km": 1,
  "mil.kr": 1,
  "mil.kz": 1,
  "mil.lv": 1,
  "mil.mg": 1,
  "mil.mv": 1,
  "mil.my": 1,
  "mil.mz": 1,
  "mil.ng": 1,
  "mil.ni": 1,
  "mil.no": 1,
  "mil.nz": 1,
  "mil.pe": 1,
  "mil.ph": 1,
  "mil.pl": 1,
  "mil.py": 1,
  "mil.qa": 1,
  "mil.ru": 1,
  "mil.rw": 1,
  "mil.sh": 1,
  "mil.st": 1,
  "mil.sy": 1,
  "mil.tj": 1,
  "mil.tm": 1,
  "mil.to": 1,
  "mil.tr": 1,
  "mil.tw": 1,
  "mil.tz": 1,
  "mil.uy": 1,
  "mil.vc": 1,
  "mil.ve": 1,
  "mil.ye": 1,
  "mil.za": 1,
  "mil.zm": 1,
  "mil.zw": 1,
  "milan.it": 1,
  "milano.it": 1,
  "military.museum": 1,
  "mill.museum": 1,
  "mima.tokushima.jp": 1,
  "mimata.miyazaki.jp": 1,
  "minakami.gunma.jp": 1,
  "minamata.kumamoto.jp": 1,
  "minami-alps.yamanashi.jp": 1,
  "minami.fukuoka.jp": 1,
  "minami.kyoto.jp": 1,
  "minami.tokushima.jp": 1,
  "minamiaiki.nagano.jp": 1,
  "minamiashigara.kanagawa.jp": 1,
  "minamiawaji.hyogo.jp": 1,
  "minamiboso.chiba.jp": 1,
  "minamidaito.okinawa.jp": 1,
  "minamiechizen.fukui.jp": 1,
  "minamifurano.hokkaido.jp": 1,
  "minamiise.mie.jp": 1,
  "minamiizu.shizuoka.jp": 1,
  "minamimaki.nagano.jp": 1,
  "minamiminowa.nagano.jp": 1,
  "minamioguni.kumamoto.jp": 1,
  "minamisanriku.miyagi.jp": 1,
  "minamitane.kagoshima.jp": 1,
  "minamiuonuma.niigata.jp": 1,
  "minamiyamashiro.kyoto.jp": 1,
  "minano.saitama.jp": 1,
  "minato.osaka.jp": 1,
  "minato.tokyo.jp": 1,
  "mincom.tn": 1,
  "mine.nu": 1,
  "miners.museum": 1,
  "mining.museum": 1,
  "miniserver.com": 1,
  "minisite.ms": 1,
  "minnesota.museum": 1,
  "mino.gifu.jp": 1,
  "minobu.yamanashi.jp": 1,
  "minoh.osaka.jp": 1,
  "minokamo.gifu.jp": 1,
  "minowa.nagano.jp": 1,
  "mintere.site": 1,
  "mircloud.host": 1,
  "mircloud.ru": 1,
  "mircloud.us": 1,
  "misaki.okayama.jp": 1,
  "misaki.osaka.jp": 1,
  "misasa.tottori.jp": 1,
  "misato.akita.jp": 1,
  "misato.miyagi.jp": 1,
  "misato.saitama.jp": 1,
  "misato.shimane.jp": 1,
  "misato.wakayama.jp": 1,
  "misawa.aomori.jp": 1,
  "misconfused.org": 1,
  "mishima.fukushima.jp": 1,
  "mishima.shizuoka.jp": 1,
  "missile.museum": 1,
  "missoula.museum": 1,
  "misugi.mie.jp": 1,
  "mitaka.tokyo.jp": 1,
  "mitake.gifu.jp": 1,
  "mitane.akita.jp": 1,
  "mito.ibaraki.jp": 1,
  "mitou.yamaguchi.jp": 1,
  "mitoyo.kagawa.jp": 1,
  "mitsue.nara.jp": 1,
  "mitsuke.niigata.jp": 1,
  "miura.kanagawa.jp": 1,
  "miyada.nagano.jp": 1,
  "miyagi.jp": 1,
  "miyake.nara.jp": 1,
  "miyako.fukuoka.jp": 1,
  "miyako.iwate.jp": 1,
  "miyakonojo.miyazaki.jp": 1,
  "miyama.fukuoka.jp": 1,
  "miyama.mie.jp": 1,
  "miyashiro.saitama.jp": 1,
  "miyawaka.fukuoka.jp": 1,
  "miyazaki.jp": 1,
  "miyazaki.miyazaki.jp": 1,
  "miyazu.kyoto.jp": 1,
  "miyoshi.aichi.jp": 1,
  "miyoshi.hiroshima.jp": 1,
  "miyoshi.saitama.jp": 1,
  "miyoshi.tokushima.jp": 1,
  "miyota.nagano.jp": 1,
  "mizuho.tokyo.jp": 1,
  "mizumaki.fukuoka.jp": 1,
  "mizunami.gifu.jp": 1,
  "mizusawa.iwate.jp": 1,
  "mjondalen.no": 1,
  "mk.eu.org": 1,
  "mk.ua": 1,
  "mlbfan.org": 1,
  "mm": 2,
  "mmafan.biz": 1,
  "mn.it": 1,
  "mn.us": 1,
  "mo-i-rana.no": 1,
  "mo-siemens.io": 1,
  "mo.cn": 1,
  "mo.it": 1,
  "mo.us": 1,
  "moareke.no": 1,
  "mobara.chiba.jp": 1,
  "mobi.gp": 1,
  "mobi.ke": 1,
  "mobi.na": 1,
  "mobi.ng": 1,
  "mobi.tt": 1,
  "mobi.tz": 1,
  "mochizuki.nagano.jp": 1,
  "mock.pstmn.io": 1,
  "mod.gi": 1,
  "modalen.no": 1,
  "modelling.aero": 1,
  "modena.it": 1,
  "modern.museum": 1,
  "mods.jp": 1,
  "modum.no": 1,
  "moka.tochigi.jp": 1,
  "mol.it": 1,
  "molde.no": 1,
  "molise.it": 1,
  "moma.museum": 1,
  "mombetsu.hokkaido.jp": 1,
  "mond.jp": 1,
  "money.museum": 1,
  "mongolian.jp": 1,
  "monmouth.museum": 1,
  "monticello.museum": 1,
  "montreal.museum": 1,
  "monza-brianza.it": 1,
  "monza-e-della-brianza.it": 1,
  "monza.it": 1,
  "monzabrianza.it": 1,
  "monzaebrianza.it": 1,
  "monzaedellabrianza.it": 1,
  "moo.jp": 1,
  "moonscale.io": 2,
  "moonscale.net": 1,
  "mordovia.ru": 1,
  "mordovia.su": 1,
  "morena.br": 1,
  "moriguchi.osaka.jp": 1,
  "morimachi.shizuoka.jp": 1,
  "morioka.iwate.jp": 1,
  "moriya.ibaraki.jp": 1,
  "moriyama.shiga.jp": 1,
  "moriyoshi.akita.jp": 1,
  "morotsuka.miyazaki.jp": 1,
  "moroyama.saitama.jp": 1,
  "moscow.museum": 1,
  "moseushi.hokkaido.jp": 1,
  "mosjoen.no": 1,
  "moskenes.no": 1,
  "moss.no": 1,
  "mosvik.no": 1,
  "motegi.tochigi.jp": 1,
  "motobu.okinawa.jp": 1,
  "motorcycle.museum": 1,
  "motosu.gifu.jp": 1,
  "motoyama.kochi.jp": 1,
  "movimiento.bo": 1,
  "mozilla-iot.org": 1,
  "mp.br": 1,
  "mr.no": 1,
  "mragowo.pl": 1,
  "ms.gov.br": 1,
  "ms.it": 1,
  "ms.kr": 1,
  "ms.leg.br": 1,
  "ms.us": 1,
  "msk.ru": 1,
  "msk.su": 1,
  "mt.eu.org": 1,
  "mt.gov.br": 1,
  "mt.it": 1,
  "mt.leg.br": 1,
  "mt.us": 1,
  "muenchen.museum": 1,
  "muenster.museum": 1,
  "mugi.tokushima.jp": 1,
  "muika.niigata.jp": 1,
  "mukawa.hokkaido.jp": 1,
  "muko.kyoto.jp": 1,
  "mulhouse.museum": 1,
  "munakata.fukuoka.jp": 1,
  "muncie.museum": 1,
  "muni.il": 1,
  "muosat.no": 1,
  "mup.gov.pl": 1,
  "murakami.niigata.jp": 1,
  "murata.miyagi.jp": 1,
  "murayama.yamagata.jp": 1,
  "murmansk.su": 1,
  "muroran.hokkaido.jp": 1,
  "muroto.kochi.jp": 1,
  "mus.br": 1,
  "mus.mi.us": 1,
  "musashimurayama.tokyo.jp": 1,
  "musashino.tokyo.jp": 1,
  "museet.museum": 1,
  "museum.mv": 1,
  "museum.mw": 1,
  "museum.no": 1,
  "museum.om": 1,
  "museum.tt": 1,
  "museumcenter.museum": 1,
  "museumvereniging.museum": 1,
  "music.museum": 1,
  "musica.ar": 1,
  "musica.bo": 1,
  "musician.io": 1,
  "mutsu.aomori.jp": 1,
  "mutsuzawa.chiba.jp": 1,
  "mutual.ar": 1,
  "mw.gov.pl": 1,
  "mx.na": 1,
  "my-firewall.org": 1,
  "my-gateway.de": 1,
  "my-router.de": 1,
  "my-vigor.de": 1,
  "my-wan.de": 1,
  "my.eu.org": 1,
  "my.id": 1,
  "myactivedirectory.com": 1,
  "myasustor.com": 1,
  "mycd.eu": 1,
  "mycloud.by": 1,
  "mydatto.com": 1,
  "mydatto.net": 1,
  "myddns.rocks": 1,
  "mydissent.net": 1,
  "mydobiss.com": 1,
  "mydrobo.com": 1,
  "myds.me": 1,
  "myeffect.net": 1,
  "myfast.host": 1,
  "myfast.space": 1,
  "myfirewall.org": 1,
  "myforum.community": 1,
  "myfritz.net": 1,
  "myftp.biz": 1,
  "myftp.org": 1,
  "myhome-server.de": 1,
  "myiphost.com": 1,
  "myjino.ru": 1,
  "mykolaiv.ua": 1,
  "mymailer.com.tw": 1,
  "mymediapc.net": 1,
  "myoko.niigata.jp": 1,
  "mypep.link": 1,
  "mypets.ws": 1,
  "myphotos.cc": 1,
  "mypi.co": 1,
  "mypsx.net": 1,
  "myqnapcloud.com": 1,
  "myravendb.com": 1,
  "mysecuritycamera.com": 1,
  "mysecuritycamera.net": 1,
  "mysecuritycamera.org": 1,
  "myshopblocks.com": 1,
  "myshopify.com": 1,
  "myspreadshop.at": 1,
  "myspreadshop.be": 1,
  "myspreadshop.ca": 1,
  "myspreadshop.ch": 1,
  "myspreadshop.co.uk": 1,
  "myspreadshop.com": 1,
  "myspreadshop.com.au": 1,
  "myspreadshop.de": 1,
  "myspreadshop.dk": 1,
  "myspreadshop.es": 1,
  "myspreadshop.fi": 1,
  "myspreadshop.fr": 1,
  "myspreadshop.ie": 1,
  "myspreadshop.it": 1,
  "myspreadshop.net": 1,
  "myspreadshop.nl": 1,
  "myspreadshop.no": 1,
  "myspreadshop.pl": 1,
  "myspreadshop.se": 1,
  "mytis.ru": 1,
  "mytuleap.com": 1,
  "myvnc.com": 1,
  "mywire.org": 1,
  "n.bg": 1,
  "n.se": 1,
  "n4t.co": 1,
  "na.it": 1,
  "na4u.ru": 1,
  "naamesjevuemie.no": 1,
  "nabari.mie.jp": 1,
  "nachikatsuura.wakayama.jp": 1,
  "nagahama.shiga.jp": 1,
  "nagai.yamagata.jp": 1,
  "nagano.jp": 1,
  "nagano.nagano.jp": 1,
  "naganohara.gunma.jp": 1,
  "nagaoka.niigata.jp": 1,
  "nagaokakyo.kyoto.jp": 1,
  "nagara.chiba.jp": 1,
  "nagareyama.chiba.jp": 1,
  "nagasaki.jp": 1,
  "nagasaki.nagasaki.jp": 1,
  "nagasu.kumamoto.jp": 1,
  "nagato.yamaguchi.jp": 1,
  "nagatoro.saitama.jp": 1,
  "nagawa.nagano.jp": 1,
  "nagi.okayama.jp": 1,
  "nagiso.nagano.jp": 1,
  "nago.okinawa.jp": 1,
  "nagoya.jp": 2,
  "naha.okinawa.jp": 1,
  "nahari.kochi.jp": 1,
  "naie.hokkaido.jp": 1,
  "naka.hiroshima.jp": 1,
  "naka.ibaraki.jp": 1,
  "nakadomari.aomori.jp": 1,
  "nakagawa.fukuoka.jp": 1,
  "nakagawa.hokkaido.jp": 1,
  "nakagawa.nagano.jp": 1,
  "nakagawa.tokushima.jp": 1,
  "nakagusuku.okinawa.jp": 1,
  "nakagyo.kyoto.jp": 1,
  "nakai.kanagawa.jp": 1,
  "nakama.fukuoka.jp": 1,
  "nakamichi.yamanashi.jp": 1,
  "nakamura.kochi.jp": 1,
  "nakaniikawa.toyama.jp": 1,
  "nakano.nagano.jp": 1,
  "nakano.tokyo.jp": 1,
  "nakanojo.gunma.jp": 1,
  "nakanoto.ishikawa.jp": 1,
  "nakasatsunai.hokkaido.jp": 1,
  "nakatane.kagoshima.jp": 1,
  "nakatombetsu.hokkaido.jp": 1,
  "nakatsugawa.gifu.jp": 1,
  "nakayama.yamagata.jp": 1,
  "nakijin.okinawa.jp": 1,
  "naklo.pl": 1,
  "nalchik.ru": 1,
  "nalchik.su": 1,
  "namaste.jp": 1,
  "namdalseid.no": 1,
  "name.az": 1,
  "name.eg": 1,
  "name.et": 1,
  "name.fj": 1,
  "name.hr": 1,
  "name.jo": 1,
  "name.mk": 1,
  "name.mv": 1,
  "name.my": 1,
  "name.na": 1,
  "name.ng": 1,
  "name.pm": 1,
  "name.pr": 1,
  "name.qa": 1,
  "name.tj": 1,
  "name.tr": 1,
  "name.tt": 1,
  "name.vn": 1,
  "namegata.ibaraki.jp": 1,
  "namegawa.saitama.jp": 1,
  "namerikawa.toyama.jp": 1,
  "namie.fukushima.jp": 1,
  "namikata.ehime.jp": 1,
  "namsos.no": 1,
  "namsskogan.no": 1,
  "nanae.hokkaido.jp": 1,
  "nanao.ishikawa.jp": 1,
  "nanbu.tottori.jp": 1,
  "nanbu.yamanashi.jp": 1,
  "nango.fukushima.jp": 1,
  "nanjo.okinawa.jp": 1,
  "nankoku.kochi.jp": 1,
  "nanmoku.gunma.jp": 1,
  "nannestad.no": 1,
  "nanporo.hokkaido.jp": 1,
  "nantan.kyoto.jp": 1,
  "nanto.toyama.jp": 1,
  "nanyo.yamagata.jp": 1,
  "naoshima.kagawa.jp": 1,
  "naples.it": 1,
  "napoli.it": 1,
  "nara.jp": 1,
  "nara.nara.jp": 1,
  "narashino.chiba.jp": 1,
  "narita.chiba.jp": 1,
  "naroy.no": 1,
  "narusawa.yamanashi.jp": 1,
  "naruto.tokushima.jp": 1,
  "narviika.no": 1,
  "narvik.no": 1,
  "nasu.tochigi.jp": 1,
  "nasushiobara.tochigi.jp": 1,
  "nat.tn": 1,
  "natal.br": 1,
  "national.museum": 1,
  "nationalfirearms.museum": 1,
  "nationalheritage.museum": 1,
  "nativeamerican.museum": 1,
  "natori.miyagi.jp": 1,
  "natural.bo": 1,
  "naturalhistory.museum": 1,
  "naturalhistorymuseum.museum": 1,
  "naturalsciences.museum": 1,
  "naturbruksgymn.se": 1,
  "nature.museum": 1,
  "naturhistorisches.museum": 1,
  "natuurwetenschappen.museum": 1,
  "naumburg.museum": 1,
  "naustdal.no": 1,
  "naval.museum": 1,
  "navigation.aero": 1,
  "navoi.su": 1,
  "navuotna.no": 1,
  "nayoro.hokkaido.jp": 1,
  "nb.ca": 1,
  "nc.tr": 1,
  "nc.us": 1,
  "nd.us": 1,
  "ne.jp": 1,
  "ne.ke": 1,
  "ne.kr": 1,
  "ne.pw": 1,
  "ne.tz": 1,
  "ne.ug": 1,
  "ne.us": 1,
  "neat-url.com": 1,
  "nebraska.museum": 1,
  "nedre-eiker.no": 1,
  "neko.am": 1,
  "nemuro.hokkaido.jp": 1,
  "nerdpol.ovh": 1,
  "nerima.tokyo.jp": 1,
  "nes.akershus.no": 1,
  "nes.buskerud.no": 1,
  "nesna.no": 1,
  "nesodden.no": 1,
  "nesoddtangen.no": 1,
  "nesseby.no": 1,
  "nesset.no": 1,
  "net-freaks.com": 1,
  "net.ac": 1,
  "net.ae": 1,
  "net.af": 1,
  "net.ag": 1,
  "net.ai": 1,
  "net.al": 1,
  "net.am": 1,
  "net.ar": 1,
  "net.au": 1,
  "net.az": 1,
  "net.ba": 1,
  "net.bb": 1,
  "net.bh": 1,
  "net.bm": 1,
  "net.bn": 1,
  "net.bo": 1,
  "net.br": 1,
  "net.bs": 1,
  "net.bt": 1,
  "net.bz": 1,
  "net.ci": 1,
  "net.cm": 1,
  "net.cn": 1,
  "net.co": 1,
  "net.cu": 1,
  "net.cw": 1,
  "net.cy": 1,
  "net.dm": 1,
  "net.do": 1,
  "net.dz": 1,
  "net.ec": 1,
  "net.eg": 1,
  "net.et": 1,
  "net.eu.org": 1,
  "net.fj": 1,
  "net.fm": 1,
  "net.ge": 1,
  "net.gg": 1,
  "net.gl": 1,
  "net.gn": 1,
  "net.gp": 1,
  "net.gr": 1,
  "net.gt": 1,
  "net.gu": 1,
  "net.gy": 1,
  "net.hk": 1,
  "net.hn": 1,
  "net.ht": 1,
  "net.id": 1,
  "net.il": 1,
  "net.im": 1,
  "net.in": 1,
  "net.iq": 1,
  "net.ir": 1,
  "net.is": 1,
  "net.je": 1,
  "net.jo": 1,
  "net.kg": 1,
  "net.ki": 1,
  "net.kn": 1,
  "net.kw": 1,
  "net.ky": 1,
  "net.kz": 1,
  "net.la": 1,
  "net.lb": 1,
  "net.lc": 1,
  "net.lk": 1,
  "net.lr": 1,
  "net.ls": 1,
  "net.lv": 1,
  "net.ly": 1,
  "net.ma": 1,
  "net.me": 1,
  "net.mk": 1,
  "net.ml": 1,
  "net.mo": 1,
  "net.ms": 1,
  "net.mt": 1,
  "net.mu": 1,
  "net.mv": 1,
  "net.mw": 1,
  "net.mx": 1,
  "net.my": 1,
  "net.mz": 1,
  "net.nf": 1,
  "net.ng": 1,
  "net.ni": 1,
  "net.nr": 1,
  "net.nz": 1,
  "net.om": 1,
  "net.pa": 1,
  "net.pe": 1,
  "net.ph": 1,
  "net.pk": 1,
  "net.pl": 1,
  "net.pn": 1,
  "net.pr": 1,
  "net.ps": 1,
  "net.pt": 1,
  "net.py": 1,
  "net.qa": 1,
  "net.ru": 1,
  "net.rw": 1,
  "net.sa": 1,
  "net.sb": 1,
  "net.sc": 1,
  "net.sd": 1,
  "net.sg": 1,
  "net.sh": 1,
  "net.sl": 1,
  "net.so": 1,
  "net.ss": 1,
  "net.st": 1,
  "net.sy": 1,
  "net.th": 1,
  "net.tj": 1,
  "net.tm": 1,
  "net.tn": 1,
  "net.to": 1,
  "net.tr": 1,
  "net.tt": 1,
  "net.tw": 1,
  "net.ua": 1,
  "net.uk": 1,
  "net.uy": 1,
  "net.uz": 1,
  "net.vc": 1,
  "net.ve": 1,
  "net.vi": 1,
  "net.vn": 1,
  "net.vu": 1,
  "net.ws": 1,
  "net.ye": 1,
  "net.za": 1,
  "net.zm": 1,
  "netlify.app": 1,
  "neues.museum": 1,
  "newhampshire.museum": 1,
  "newjersey.museum": 1,
  "newmexico.museum": 1,
  "newport.museum": 1,
  "news.hu": 1,
  "newspaper.museum": 1,
  "newyork.museum": 1,
  "neyagawa.osaka.jp": 1,
  "nf.ca": 1,
  "nflfan.org": 1,
  "nfshost.com": 1,
  "ng.eu.org": 1,
  "ngo.lk": 1,
  "ngo.ng": 1,
  "ngo.ph": 1,
  "ngo.za": 1,
  "ngrok.io": 1,
  "nh-serv.co.uk": 1,
  "nh.us": 1,
  "nhlfan.net": 1,
  "nhs.uk": 1,
  "nic.in": 1,
  "nic.tj": 1,
  "nic.za": 1,
  "nichinan.miyazaki.jp": 1,
  "nichinan.tottori.jp": 1,
  "nid.io": 1,
  "niepce.museum": 1,
  "nieruchomosci.pl": 1,
  "niigata.jp": 1,
  "niigata.niigata.jp": 1,
  "niihama.ehime.jp": 1,
  "niikappu.hokkaido.jp": 1,
  "niimi.okayama.jp": 1,
  "niiza.saitama.jp": 1,
  "nikaho.akita.jp": 1,
  "niki.hokkaido.jp": 1,
  "nikita.jp": 1,
  "nikko.tochigi.jp": 1,
  "nikolaev.ua": 1,
  "ninohe.iwate.jp": 1,
  "ninomiya.kanagawa.jp": 1,
  "nirasaki.yamanashi.jp": 1,
  "nis.za": 1,
  "nishi.fukuoka.jp": 1,
  "nishi.osaka.jp": 1,
  "nishiaizu.fukushima.jp": 1,
  "nishiarita.saga.jp": 1,
  "nishiawakura.okayama.jp": 1,
  "nishiazai.shiga.jp": 1,
  "nishigo.fukushima.jp": 1,
  "nishihara.kumamoto.jp": 1,
  "nishihara.okinawa.jp": 1,
  "nishiizu.shizuoka.jp": 1,
  "nishikata.tochigi.jp": 1,
  "nishikatsura.yamanashi.jp": 1,
  "nishikawa.yamagata.jp": 1,
  "nishimera.miyazaki.jp": 1,
  "nishinomiya.hyogo.jp": 1,
  "nishinoomote.kagoshima.jp": 1,
  "nishinoshima.shimane.jp": 1,
  "nishio.aichi.jp": 1,
  "nishiokoppe.hokkaido.jp": 1,
  "nishitosa.kochi.jp": 1,
  "nishiwaki.hyogo.jp": 1,
  "nissedal.no": 1,
  "nisshin.aichi.jp": 1,
  "niteroi.br": 1,
  "nittedal.no": 1,
  "niyodogawa.kochi.jp": 1,
  "nj.us": 1,
  "njs.jelastic.vps-host.net": 1,
  "nl-ams-1.baremetal.scw.cloud": 1,
  "nl.ca": 1,
  "nl.ci": 1,
  "nl.eu.org": 1,
  "nl.no": 1,
  "nm.cn": 1,
  "nm.us": 1,
  "no-ip.biz": 1,
  "no-ip.ca": 1,
  "no-ip.co.uk": 1,
  "no-ip.info": 1,
  "no-ip.net": 1,
  "no-ip.org": 1,
  "no.com": 1,
  "no.eu.org": 1,
  "no.it": 1,
  "nobeoka.miyazaki.jp": 1,
  "noboribetsu.hokkaido.jp": 1,
  "nobushi.jp": 1,
  "noda.chiba.jp": 1,
  "noda.iwate.jp": 1,
  "nodebalancer.linode.com": 2,
  "nodes.k8s.fr-par.scw.cloud": 1,
  "nodes.k8s.nl-ams.scw.cloud": 1,
  "nodes.k8s.pl-waw.scw.cloud": 1,
  "nog.community": 1,
  "nogata.fukuoka.jp": 1,
  "nogi.tochigi.jp": 1,
  "noheji.aomori.jp": 1,
  "noho.st": 1,
  "nohost.me": 1,
  "noip.me": 1,
  "noip.us": 1,
  "nom.ad": 1,
  "nom.ag": 1,
  "nom.br": 2,
  "nom.co": 1,
  "nom.es": 1,
  "nom.fr": 1,
  "nom.km": 1,
  "nom.mg": 1,
  "nom.nc": 1,
  "nom.ni": 1,
  "nom.pa": 1,
  "nom.pe": 1,
  "nom.pl": 1,
  "nom.re": 1,
  "nom.ro": 1,
  "nom.tm": 1,
  "nom.ve": 1,
  "nom.za": 1,
  "nombre.bo": 1,
  "nome.cv": 1,
  "nome.pt": 1,
  "nomi.ishikawa.jp": 1,
  "nonoichi.ishikawa.jp": 1,
  "noop.app": 1,
  "noor.jp": 1,
  "nord-aurdal.no": 1,
  "nord-fron.no": 1,
  "nord-odal.no": 1,
  "norddal.no": 1,
  "nordeste-idc.saveincloud.net": 1,
  "nordkapp.no": 1,
  "nordre-land.no": 1,
  "nordreisa.no": 1,
  "nore-og-uvdal.no": 1,
  "norfolk.museum": 1,
  "north-kazakhstan.su": 1,
  "north.museum": 1,
  "northflank.app": 2,
  "nose.osaka.jp": 1,
  "nosegawa.nara.jp": 1,
  "noshiro.akita.jp": 1,
  "not.br": 1,
  "notaires.fr": 1,
  "notaires.km": 1,
  "noticeable.news": 1,
  "noticias.bo": 1,
  "noto.ishikawa.jp": 1,
  "notodden.no": 1,
  "notogawa.shiga.jp": 1,
  "notteroy.no": 1,
  "nov.ru": 1,
  "nov.su": 1,
  "novara.it": 1,
  "novecore.site": 1,
  "now-dns.net": 1,
  "now-dns.org": 1,
  "now-dns.top": 1,
  "now.sh": 1,
  "nowaruda.pl": 1,
  "nozawaonsen.nagano.jp": 1,
  "np": 2,
  "nrw.museum": 1,
  "ns.ca": 1,
  "nsn.us": 1,
  "nsupdate.info": 1,
  "nsw.au": 1,
  "nsw.edu.au": 1,
  "nt.au": 1,
  "nt.ca": 1,
  "nt.edu.au": 1,
  "nt.no": 1,
  "nt.ro": 1,
  "ntdll.top": 1,
  "ntr.br": 1,
  "nu.ca": 1,
  "nu.it": 1,
  "numata.gunma.jp": 1,
  "numata.hokkaido.jp": 1,
  "numazu.shizuoka.jp": 1,
  "nuoro.it": 1,
  "nv.us": 1,
  "nx.cn": 1,
  "ny-1.paas.massivegrid.net": 1,
  "ny-2.paas.massivegrid.net": 1,
  "ny.us": 1,
  "nyaa.am": 1,
  "nyan.to": 1,
  "nyc.mn": 1,
  "nyc.museum": 1,
  "nyny.museum": 1,
  "nysa.pl": 1,
  "nyuzen.toyama.jp": 1,
  "nz.basketball": 1,
  "nz.eu.org": 1,
  "o.bg": 1,
  "o.se": 1,
  "oamishirasato.chiba.jp": 1,
  "oarai.ibaraki.jp": 1,
  "obama.fukui.jp": 1,
  "obama.nagasaki.jp": 1,
  "obanazawa.yamagata.jp": 1,
  "obihiro.hokkaido.jp": 1,
  "obira.hokkaido.jp": 1,
  "obninsk.su": 1,
  "obu.aichi.jp": 1,
  "obuse.nagano.jp": 1,
  "oceanographic.museum": 1,
  "oceanographique.museum": 1,
  "ocelot.mythic-beasts.com": 1,
  "ochi.kochi.jp": 1,
  "oci.customer-oci.com": 2,
  "ocp.customer-oci.com": 2,
  "ocs.customer-oci.com": 2,
  "od.ua": 1,
  "odate.akita.jp": 1,
  "odawara.kanagawa.jp": 1,
  "odda.no": 1,
  "odesa.ua": 1,
  "odessa.ua": 1,
  "odo.br": 1,
  "oe.yamagata.jp": 1,
  "of.by": 1,
  "of.fashion": 1,
  "of.je": 1,
  "of.london": 1,
  "of.no": 1,
  "off.ai": 1,
  "office-on-the.net": 1,
  "official.academy": 1,
  "official.ec": 1,
  "ofunato.iwate.jp": 1,
  "og.ao": 1,
  "og.it": 1,
  "oga.akita.jp": 1,
  "ogaki.gifu.jp": 1,
  "ogano.saitama.jp": 1,
  "ogasawara.tokyo.jp": 1,
  "ogata.akita.jp": 1,
  "ogawa.ibaraki.jp": 1,
  "ogawa.nagano.jp": 1,
  "ogawa.saitama.jp": 1,
  "ogawara.miyagi.jp": 1,
  "ogi.saga.jp": 1,
  "ogimi.okinawa.jp": 1,
  "ogliastra.it": 1,
  "ogori.fukuoka.jp": 1,
  "ogose.saitama.jp": 1,
  "oguchi.aichi.jp": 1,
  "oguni.kumamoto.jp": 1,
  "oguni.yamagata.jp": 1,
  "oh.us": 1,
  "oharu.aichi.jp": 1,
  "ohda.shimane.jp": 1,
  "ohi.fukui.jp": 1,
  "ohira.miyagi.jp": 1,
  "ohira.tochigi.jp": 1,
  "ohkura.yamagata.jp": 1,
  "ohtawara.tochigi.jp": 1,
  "oi.kanagawa.jp": 1,
  "oirase.aomori.jp": 1,
  "oirm.gov.pl": 1,
  "oishida.yamagata.jp": 1,
  "oiso.kanagawa.jp": 1,
  "oita.jp": 1,
  "oita.oita.jp": 1,
  "oizumi.gunma.jp": 1,
  "oji.nara.jp": 1,
  "ojiya.niigata.jp": 1,
  "ok.us": 1,
  "okagaki.fukuoka.jp": 1,
  "okawa.fukuoka.jp": 1,
  "okawa.kochi.jp": 1,
  "okaya.nagano.jp": 1,
  "okayama.jp": 1,
  "okayama.okayama.jp": 1,
  "okazaki.aichi.jp": 1,
  "okegawa.saitama.jp": 1,
  "oketo.hokkaido.jp": 1,
  "oki.fukuoka.jp": 1,
  "okinawa.jp": 1,
  "okinawa.okinawa.jp": 1,
  "okinoshima.shimane.jp": 1,
  "okoppe.hokkaido.jp": 1,
  "oksnes.no": 1,
  "okuizumo.shimane.jp": 1,
  "okuma.fukushima.jp": 1,
  "okutama.tokyo.jp": 1,
  "ol.no": 1,
  "olawa.pl": 1,
  "olbia-tempio.it": 1,
  "olbiatempio.it": 1,
  "olecko.pl": 1,
  "olkusz.pl": 1,
  "olsztyn.pl": 1,
  "omachi.nagano.jp": 1,
  "omachi.saga.jp": 1,
  "omaezaki.shizuoka.jp": 1,
  "omaha.museum": 1,
  "omasvuotna.no": 1,
  "ome.tokyo.jp": 1,
  "omg.lol": 1,
  "omi.nagano.jp": 1,
  "omi.niigata.jp": 1,
  "omigawa.chiba.jp": 1,
  "omihachiman.shiga.jp": 1,
  "omitama.ibaraki.jp": 1,
  "omiya.saitama.jp": 1,
  "omniwe.site": 1,
  "omotego.fukushima.jp": 1,
  "omura.nagasaki.jp": 1,
  "omuta.fukuoka.jp": 1,
  "on-acorn.io": 2,
  "on-aptible.com": 1,
  "on-k3s.io": 2,
  "on-rancher.cloud": 2,
  "on-rio.io": 2,
  "on-the-web.tv": 1,
  "on-web.fr": 1,
  "on.ca": 1,
  "onagawa.miyagi.jp": 1,
  "onavstack.net": 1,
  "oncilla.mythic-beasts.com": 1,
  "ondigitalocean.app": 1,
  "onfabrica.com": 1,
  "onflashdrive.app": 1,
  "ong.br": 1,
  "onga.fukuoka.jp": 1,
  "onjuku.chiba.jp": 1,
  "online.museum": 1,
  "online.th": 1,
  "onna.okinawa.jp": 1,
  "ono.fukui.jp": 1,
  "ono.fukushima.jp": 1,
  "ono.hyogo.jp": 1,
  "onojo.fukuoka.jp": 1,
  "onomichi.hiroshima.jp": 1,
  "onporter.run": 1,
  "onred.one": 1,
  "onrender.com": 1,
  "ontario.museum": 1,
  "onthewifi.com": 1,
  "onza.mythic-beasts.com": 1,
  "ooguy.com": 1,
  "ookuwa.nagano.jp": 1,
  "oops.jp": 1,
  "ooshika.nagano.jp": 1,
  "openair.museum": 1,
  "opencraft.hosting": 1,
  "opensocial.site": 1,
  "operaunite.com": 1,
  "opoczno.pl": 1,
  "opole.pl": 1,
  "oppdal.no": 1,
  "oppegard.no": 1,
  "or.at": 1,
  "or.bi": 1,
  "or.ci": 1,
  "or.cr": 1,
  "or.id": 1,
  "or.it": 1,
  "or.jp": 1,
  "or.ke": 1,
  "or.kr": 1,
  "or.mu": 1,
  "or.na": 1,
  "or.pw": 1,
  "or.th": 1,
  "or.tz": 1,
  "or.ug": 1,
  "or.us": 1,
  "ora.gunma.jp": 1,
  "orangecloud.tn": 1,
  "oregon.museum": 1,
  "oregontrail.museum": 1,
  "org.ac": 1,
  "org.ae": 1,
  "org.af": 1,
  "org.ag": 1,
  "org.ai": 1,
  "org.al": 1,
  "org.am": 1,
  "org.ar": 1,
  "org.au": 1,
  "org.az": 1,
  "org.ba": 1,
  "org.bb": 1,
  "org.bh": 1,
  "org.bi": 1,
  "org.bm": 1,
  "org.bn": 1,
  "org.bo": 1,
  "org.br": 1,
  "org.bs": 1,
  "org.bt": 1,
  "org.bw": 1,
  "org.bz": 1,
  "org.ci": 1,
  "org.cn": 1,
  "org.co": 1,
  "org.cu": 1,
  "org.cv": 1,
  "org.cw": 1,
  "org.cy": 1,
  "org.dm": 1,
  "org.do": 1,
  "org.dz": 1,
  "org.ec": 1,
  "org.ee": 1,
  "org.eg": 1,
  "org.es": 1,
  "org.et": 1,
  "org.fj": 1,
  "org.fm": 1,
  "org.ge": 1,
  "org.gg": 1,
  "org.gh": 1,
  "org.gi": 1,
  "org.gl": 1,
  "org.gn": 1,
  "org.gp": 1,
  "org.gr": 1,
  "org.gt": 1,
  "org.gu": 1,
  "org.gy": 1,
  "org.hk": 1,
  "org.hn": 1,
  "org.ht": 1,
  "org.hu": 1,
  "org.il": 1,
  "org.im": 1,
  "org.in": 1,
  "org.iq": 1,
  "org.ir": 1,
  "org.is": 1,
  "org.je": 1,
  "org.jo": 1,
  "org.kg": 1,
  "org.ki": 1,
  "org.km": 1,
  "org.kn": 1,
  "org.kp": 1,
  "org.kw": 1,
  "org.ky": 1,
  "org.kz": 1,
  "org.la": 1,
  "org.lb": 1,
  "org.lc": 1,
  "org.lk": 1,
  "org.lr": 1,
  "org.ls": 1,
  "org.lv": 1,
  "org.ly": 1,
  "org.ma": 1,
  "org.me": 1,
  "org.mg": 1,
  "org.mk": 1,
  "org.ml": 1,
  "org.mn": 1,
  "org.mo": 1,
  "org.ms": 1,
  "org.mt": 1,
  "org.mu": 1,
  "org.mv": 1,
  "org.mw": 1,
  "org.mx": 1,
  "org.my": 1,
  "org.mz": 1,
  "org.na": 1,
  "org.ng": 1,
  "org.ni": 1,
  "org.nr": 1,
  "org.nz": 1,
  "org.om": 1,
  "org.pa": 1,
  "org.pe": 1,
  "org.pf": 1,
  "org.ph": 1,
  "org.pk": 1,
  "org.pl": 1,
  "org.pn": 1,
  "org.pr": 1,
  "org.ps": 1,
  "org.pt": 1,
  "org.py": 1,
  "org.qa": 1,
  "org.ro": 1,
  "org.rs": 1,
  "org.ru": 1,
  "org.rw": 1,
  "org.sa": 1,
  "org.sb": 1,
  "org.sc": 1,
  "org.sd": 1,
  "org.se": 1,
  "org.sg": 1,
  "org.sh": 1,
  "org.sl": 1,
  "org.sn": 1,
  "org.so": 1,
  "org.ss": 1,
  "org.st": 1,
  "org.sv": 1,
  "org.sy": 1,
  "org.sz": 1,
  "org.tj": 1,
  "org.tm": 1,
  "org.tn": 1,
  "org.to": 1,
  "org.tr": 1,
  "org.tt": 1,
  "org.tw": 1,
  "org.ua": 1,
  "org.ug": 1,
  "org.uk": 1,
  "org.uy": 1,
  "org.uz": 1,
  "org.vc": 1,
  "org.ve": 1,
  "org.vi": 1,
  "org.vn": 1,
  "org.vu": 1,
  "org.ws": 1,
  "org.ye": 1,
  "org.yt": 1,
  "org.za": 1,
  "org.zm": 1,
  "org.zw": 1,
  "oristano.it": 1,
  "orkanger.no": 1,
  "orkdal.no": 1,
  "orland.no": 1,
  "orsites.com": 1,
  "orskog.no": 1,
  "orsta.no": 1,
  "orx.biz": 1,
  "os.hedmark.no": 1,
  "os.hordaland.no": 1,
  "osaka.jp": 1,
  "osakasayama.osaka.jp": 1,
  "osaki.miyagi.jp": 1,
  "osakikamijima.hiroshima.jp": 1,
  "osasco.br": 1,
  "osen.no": 1,
  "oseto.nagasaki.jp": 1,
  "oshima.tokyo.jp": 1,
  "oshima.yamaguchi.jp": 1,
  "oshino.yamanashi.jp": 1,
  "oshu.iwate.jp": 1,
  "oslo.no": 1,
  "osoyro.no": 1,
  "osteroy.no": 1,
  "ostre-toten.no": 1,
  "ostroda.pl": 1,
  "ostroleka.pl": 1,
  "ostrowiec.pl": 1,
  "ostrowwlkp.pl": 1,
  "ot.it": 1,
  "ota.gunma.jp": 1,
  "ota.tokyo.jp": 1,
  "otago.museum": 1,
  "otake.hiroshima.jp": 1,
  "otaki.chiba.jp": 1,
  "otaki.nagano.jp": 1,
  "otaki.saitama.jp": 1,
  "otama.fukushima.jp": 1,
  "otap.co": 2,
  "otari.nagano.jp": 1,
  "otaru.hokkaido.jp": 1,
  "other.nf": 1,
  "oto.fukuoka.jp": 1,
  "otobe.hokkaido.jp": 1,
  "otofuke.hokkaido.jp": 1,
  "otoineppu.hokkaido.jp": 1,
  "otoyo.kochi.jp": 1,
  "otsu.shiga.jp": 1,
  "otsuchi.iwate.jp": 1,
  "otsuki.kochi.jp": 1,
  "otsuki.yamanashi.jp": 1,
  "ouchi.saga.jp": 1,
  "ouda.nara.jp": 1,
  "oum.gov.pl": 1,
  "oumu.hokkaido.jp": 1,
  "outsystemscloud.com": 1,
  "overhalla.no": 1,
  "ovre-eiker.no": 1,
  "owani.aomori.jp": 1,
  "owariasahi.aichi.jp": 1,
  "own.pm": 1,
  "ownip.net": 1,
  "ownprovider.com": 1,
  "owo.codes": 2,
  "ox.rs": 1,
  "oxa.cloud": 1,
  "oxford.museum": 1,
  "oy.lc": 1,
  "oya.to": 1,
  "oyabe.toyama.jp": 1,
  "oyama.tochigi.jp": 1,
  "oyamazaki.kyoto.jp": 1,
  "oyer.no": 1,
  "oygarden.no": 1,
  "oyodo.nara.jp": 1,
  "oystre-slidre.no": 1,
  "oz.au": 1,
  "ozora.hokkaido.jp": 1,
  "ozu.ehime.jp": 1,
  "ozu.kumamoto.jp": 1,
  "p.bg": 1,
  "p.se": 1,
  "pa.gov.br": 1,
  "pa.gov.pl": 1,
  "pa.it": 1,
  "pa.leg.br": 1,
  "pa.us": 1,
  "paas.beebyte.io": 1,
  "paas.datacenter.fi": 1,
  "paas.hosted-by-previder.com": 1,
  "paas.massivegrid.com": 1,
  "pacific.museum": 1,
  "paderborn.museum": 1,
  "padova.it": 1,
  "padua.it": 1,
  "pagefrontapp.com": 1,
  "pages.dev": 1,
  "pages.it.hs-heilbronn.de": 1,
  "pages.torproject.net": 1,
  "pages.wiardweb.com": 1,
  "pagespeedmobilizer.com": 1,
  "pagexl.com": 1,
  "palace.museum": 1,
  "paleo.museum": 1,
  "palermo.it": 1,
  "palmas.br": 1,
  "palmsprings.museum": 1,
  "panama.museum": 1,
  "panel.gg": 1,
  "pantheonsite.io": 1,
  "parachuting.aero": 1,
  "paragliding.aero": 1,
  "parallel.jp": 1,
  "parasite.jp": 1,
  "paris.eu.org": 1,
  "paris.museum": 1,
  "parliament.nz": 1,
  "parma.it": 1,
  "paroch.k12.ma.us": 1,
  "parti.se": 1,
  "pasadena.museum": 1,
  "passenger-association.aero": 1,
  "patria.bo": 1,
  "pavia.it": 1,
  "paywhirl.com": 2,
  "pb.ao": 1,
  "pb.gov.br": 1,
  "pb.leg.br": 1,
  "pc.it": 1,
  "pc.pl": 1,
  "pcloud.host": 1,
  "pd.it": 1,
  "pdns.page": 1,
  "pe.ca": 1,
  "pe.gov.br": 1,
  "pe.it": 1,
  "pe.kr": 1,
  "pe.leg.br": 1,
  "pecori.jp": 1,
  "peewee.jp": 1,
  "penne.jp": 1,
  "penza.su": 1,
  "pepper.jp": 1,
  "per.la": 1,
  "per.nf": 1,
  "per.sg": 1,
  "perma.jp": 1,
  "perso.ht": 1,
  "perso.sn": 1,
  "perso.tn": 1,
  "perspecta.cloud": 1,
  "perugia.it": 1,
  "pesaro-urbino.it": 1,
  "pesarourbino.it": 1,
  "pescara.it": 1,
  "pg": 2,
  "pg.in": 1,
  "pg.it": 1,
  "pgafan.net": 1,
  "pgfog.com": 1,
  "pharmacien.fr": 1,
  "pharmaciens.km": 1,
  "pharmacy.museum": 1,
  "philadelphia.museum": 1,
  "philadelphiaarea.museum": 1,
  "philately.museum": 1,
  "phoenix.museum": 1,
  "photography.museum": 1,
  "phx.enscaled.us": 1,
  "pi.gov.br": 1,
  "pi.it": 1,
  "pi.leg.br": 1,
  "piacenza.it": 1,
  "piedmont.it": 1,
  "piemonte.it": 1,
  "pigboat.jp": 1,
  "pila.pl": 1,
  "pilot.aero": 1,
  "pilots.museum": 1,
  "pimienta.org": 1,
  "pinb.gov.pl": 1,
  "pinoko.jp": 1,
  "pippu.hokkaido.jp": 1,
  "pisa.it": 1,
  "pistoia.it": 1,
  "pisz.pl": 1,
  "pittsburgh.museum": 1,
  "piw.gov.pl": 1,
  "pixolino.com": 1,
  "pl.eu.org": 1,
  "pl.ua": 1,
  "planetarium.museum": 1,
  "plantation.museum": 1,
  "plants.museum": 1,
  "platform0.app": 1,
  "platformsh.site": 2,
  "platter-app.com": 1,
  "platter-app.dev": 1,
  "platterp.us": 1,
  "playstation-cloud.com": 1,
  "plaza.museum": 1,
  "plc.co.im": 1,
  "plc.ly": 1,
  "plc.uk": 1,
  "plesk.page": 1,
  "pleskns.com": 1,
  "plo.ps": 1,
  "plurinacional.bo": 1,
  "pmn.it": 1,
  "pn.it": 1,
  "po.gov.pl": 1,
  "po.it": 1,
  "poa.br": 1,
  "podhale.pl": 1,
  "podlasie.pl": 1,
  "podzone.net": 1,
  "podzone.org": 1,
  "point2this.com": 1,
  "pointto.us": 1,
  "poivron.org": 1,
  "pokrovsk.su": 1,
  "pol.dz": 1,
  "pol.ht": 1,
  "pol.tr": 1,
  "police.uk": 1,
  "politica.bo": 1,
  "polkowice.pl": 1,
  "poltava.ua": 1,
  "pomorskie.pl": 1,
  "pomorze.pl": 1,
  "poniatowa.pl": 1,
  "ponpes.id": 1,
  "pony.club": 1,
  "pordenone.it": 1,
  "porsanger.no": 1,
  "porsangu.no": 1,
  "porsgrunn.no": 1,
  "port.fr": 1,
  "portal.museum": 1,
  "portland.museum": 1,
  "portlligat.museum": 1,
  "post.in": 1,
  "postman-echo.com": 1,
  "posts-and-telecommunications.museum": 1,
  "potager.org": 1,
  "potenza.it": 1,
  "powiat.pl": 1,
  "poznan.pl": 1,
  "pp.az": 1,
  "pp.ru": 1,
  "pp.se": 1,
  "pp.ua": 1,
  "ppg.br": 1,
  "pr.gov.br": 1,
  "pr.it": 1,
  "pr.leg.br": 1,
  "pr.us": 1,
  "prato.it": 1,
  "prd.fr": 1,
  "prd.km": 1,
  "prd.mg": 1,
  "prequalifyme.today": 1,
  "preservation.museum": 1,
  "presidio.museum": 1,
  "press.aero": 1,
  "press.cy": 1,
  "press.ma": 1,
  "press.museum": 1,
  "press.se": 1,
  "presse.ci": 1,
  "presse.km": 1,
  "presse.ml": 1,
  "pri.ee": 1,
  "primetel.cloud": 1,
  "principe.st": 1,
  "priv.at": 1,
  "priv.hu": 1,
  "priv.instances.scw.cloud": 1,
  "priv.me": 1,
  "priv.no": 1,
  "priv.pl": 1,
  "privatizehealthinsurance.net": 1,
  "pro.az": 1,
  "pro.br": 1,
  "pro.cy": 1,
  "pro.ec": 1,
  "pro.fj": 1,
  "pro.ht": 1,
  "pro.in": 1,
  "pro.mv": 1,
  "pro.na": 1,
  "pro.om": 1,
  "pro.pr": 1,
  "pro.tt": 1,
  "pro.typeform.com": 1,
  "pro.vn": 1,
  "prochowice.pl": 1,
  "production.aero": 1,
  "prof.pr": 1,
  "profesional.bo": 1,
  "project.museum": 1,
  "protonet.io": 1,
  "pruszkow.pl": 1,
  "prvcy.page": 1,
  "przeworsk.pl": 1,
  "psc.br": 1,
  "psi.br": 1,
  "psp.gov.pl": 1,
  "psse.gov.pl": 1,
  "pstmn.io": 1,
  "pt.eu.org": 1,
  "pt.it": 1,
  "pu.it": 1,
  "pub.instances.scw.cloud": 1,
  "pub.sa": 1,
  "publ.pt": 1,
  "public-inquiry.uk": 1,
  "public.museum": 1,
  "publishproxy.com": 1,
  "pubol.museum": 1,
  "pubtls.org": 1,
  "pueblo.bo": 1,
  "pug.it": 1,
  "puglia.it": 1,
  "pulawy.pl": 1,
  "punyu.jp": 1,
  "pup.gov.pl": 1,
  "pupu.jp": 1,
  "pussycat.jp": 1,
  "pv.it": 1,
  "pvh.br": 1,
  "pvt.ge": 1,
  "pvt.k12.ma.us": 1,
  "pya.jp": 1,
  "pyatigorsk.ru": 1,
  "pymnt.uk": 1,
  "pythonanywhere.com": 1,
  "pz.it": 1,
  "q-a.eu.org": 1,
  "q.bg": 1,
  "qa2.com": 1,
  "qbuser.com": 1,
  "qc.ca": 1,
  "qc.com": 1,
  "qcx.io": 1,
  "qh.cn": 1,
  "qld.au": 1,
  "qld.edu.au": 1,
  "qld.gov.au": 1,
  "qoto.io": 1,
  "qsl.br": 1,
  "qualifioapp.com": 1,
  "quebec.museum": 1,
  "quicksytes.com": 1,
  "quipelements.com": 2,
  "r.appspot.com": 2,
  "r.bg": 1,
  "r.cdn77.net": 1,
  "r.se": 1,
  "ra.it": 1,
  "rackmaze.com": 1,
  "rackmaze.net": 1,
  "rade.no": 1,
  "radio.am": 1,
  "radio.br": 1,
  "radio.fm": 1,
  "radom.pl": 1,
  "radoy.no": 1,
  "raffleentry.org.uk": 1,
  "rag-cloud-ch.hosteur.com": 1,
  "rag-cloud.hosteur.com": 1,
  "ragusa.it": 1,
  "rahkkeravju.no": 1,
  "raholt.no": 1,
  "railroad.museum": 1,
  "railway.museum": 1,
  "raindrop.jp": 1,
  "raisa.no": 1,
  "rakkestad.no": 1,
  "ralingen.no": 1,
  "rana.no": 1,
  "randaberg.no": 1,
  "rankoshi.hokkaido.jp": 1,
  "ranzan.saitama.jp": 1,
  "rar.ve": 1,
  "ras.ru": 1,
  "rauma.no": 1,
  "ravendb.cloud": 1,
  "ravendb.community": 1,
  "ravendb.me": 1,
  "ravendb.run": 1,
  "ravenna.it": 1,
  "ravpage.co.il": 1,
  "rawa-maz.pl": 1,
  "rc.it": 1,
  "rdv.to": 1,
  "re.it": 1,
  "re.kr": 1,
  "read-books.org": 1,
  "readmyblog.org": 1,
  "readthedocs.io": 1,
  "readymade.jp": 1,
  "realestate.pl": 1,
  "realm.cz": 1,
  "rebun.hokkaido.jp": 1,
  "rec.br": 1,
  "rec.co": 1,
  "rec.nf": 1,
  "rec.ro": 1,
  "rec.ve": 1,
  "recht.pro": 1,
  "recife.br": 1,
  "recreation.aero": 1,
  "red.sv": 1,
  "redirectme.net": 1,
  "reg.dk": 1,
  "reggio-calabria.it": 1,
  "reggio-emilia.it": 1,
  "reggiocalabria.it": 1,
  "reggioemilia.it": 1,
  "reklam.hu": 1,
  "rel.ht": 1,
  "rel.pl": 1,
  "remotewd.com": 1,
  "rendalen.no": 1,
  "rennebu.no": 1,
  "rennesoy.no": 1,
  "rep.br": 1,
  "rep.kp": 1,
  "repair.men": 1,
  "repbody.aero": 1,
  "repl.co": 1,
  "repl.run": 1,
  "res.aero": 1,
  "res.in": 1,
  "research.aero": 1,
  "research.museum": 1,
  "reservd.com": 1,
  "reservd.dev.thingdust.io": 1,
  "reservd.disrec.thingdust.io": 1,
  "reservd.testing.thingdust.io": 1,
  "reserve-online.com": 1,
  "reserve-online.net": 1,
  "resindevice.io": 1,
  "resistance.museum": 1,
  "revista.bo": 1,
  "rg.it": 1,
  "rhcloud.com": 1,
  "ri.it": 1,
  "ri.us": 1,
  "ribeirao.br": 1,
  "ric.jelastic.vps-host.net": 1,
  "rieti.it": 1,
  "rifu.miyagi.jp": 1,
  "riik.ee": 1,
  "rikubetsu.hokkaido.jp": 1,
  "rikuzentakata.iwate.jp": 1,
  "rimini.it": 1,
  "rindal.no": 1,
  "ringebu.no": 1,
  "ringerike.no": 1,
  "ringsaker.no": 1,
  "rio.br": 1,
  "riobranco.br": 1,
  "riodejaneiro.museum": 1,
  "riopreto.br": 1,
  "rishiri.hokkaido.jp": 1,
  "rishirifuji.hokkaido.jp": 1,
  "risor.no": 1,
  "rissa.no": 1,
  "ritto.shiga.jp": 1,
  "rivne.ua": 1,
  "rj.gov.br": 1,
  "rj.leg.br": 1,
  "rl.no": 1,
  "rm.it": 1,
  "rn.gov.br": 1,
  "rn.it": 1,
  "rn.leg.br": 1,
  "ro.eu.org": 1,
  "ro.gov.br": 1,
  "ro.im": 1,
  "ro.it": 1,
  "ro.leg.br": 1,
  "roan.no": 1,
  "rochester.museum": 1,
  "rockart.museum": 1,
  "rocky.page": 1,
  "rodoy.no": 1,
  "rokunohe.aomori.jp": 1,
  "rollag.no": 1,
  "roma.it": 1,
  "roma.museum": 1,
  "rome.it": 1,
  "romsa.no": 1,
  "romskog.no": 1,
  "roros.no": 1,
  "rost.no": 1,
  "rotorcraft.aero": 1,
  "router.management": 1,
  "rovigo.it": 1,
  "rovno.ua": 1,
  "royal-commission.uk": 1,
  "royken.no": 1,
  "royrvik.no": 1,
  "rr.gov.br": 1,
  "rr.leg.br": 1,
  "rs.ba": 1,
  "rs.gov.br": 1,
  "rs.leg.br": 1,
  "rsc.cdn77.org": 1,
  "rss.my.id": 2,
  "ru.com": 1,
  "ru.eu.org": 1,
  "ru.net": 1,
  "run.app": 1,
  "ruovat.no": 1,
  "russia.museum": 1,
  "rv.ua": 1,
  "rybnik.pl": 1,
  "ryd.wafaicloud.com": 1,
  "rygge.no": 1,
  "ryokami.saitama.jp": 1,
  "ryugasaki.ibaraki.jp": 1,
  "ryuoh.shiga.jp": 1,
  "rzeszow.pl": 1,
  "rzgw.gov.pl": 1,
  "s.bg": 1,
  "s.se": 1,
  "s3-ap-northeast-1.amazonaws.com": 1,
  "s3-ap-northeast-2.amazonaws.com": 1,
  "s3-ap-south-1.amazonaws.com": 1,
  "s3-ap-southeast-1.amazonaws.com": 1,
  "s3-ap-southeast-2.amazonaws.com": 1,
  "s3-ca-central-1.amazonaws.com": 1,
  "s3-eu-central-1.amazonaws.com": 1,
  "s3-eu-west-1.amazonaws.com": 1,
  "s3-eu-west-2.amazonaws.com": 1,
  "s3-eu-west-3.amazonaws.com": 1,
  "s3-external-1.amazonaws.com": 1,
  "s3-fips-us-gov-west-1.amazonaws.com": 1,
  "s3-sa-east-1.amazonaws.com": 1,
  "s3-us-east-2.amazonaws.com": 1,
  "s3-us-gov-west-1.amazonaws.com": 1,
  "s3-us-west-1.amazonaws.com": 1,
  "s3-us-west-2.amazonaws.com": 1,
  "s3-website-ap-northeast-1.amazonaws.com": 1,
  "s3-website-ap-southeast-1.amazonaws.com": 1,
  "s3-website-ap-southeast-2.amazonaws.com": 1,
  "s3-website-eu-west-1.amazonaws.com": 1,
  "s3-website-sa-east-1.amazonaws.com": 1,
  "s3-website-us-east-1.amazonaws.com": 1,
  "s3-website-us-west-1.amazonaws.com": 1,
  "s3-website-us-west-2.amazonaws.com": 1,
  "s3-website.ap-northeast-2.amazonaws.com": 1,
  "s3-website.ap-south-1.amazonaws.com": 1,
  "s3-website.ca-central-1.amazonaws.com": 1,
  "s3-website.eu-central-1.amazonaws.com": 1,
  "s3-website.eu-west-2.amazonaws.com": 1,
  "s3-website.eu-west-3.amazonaws.com": 1,
  "s3-website.fr-par.scw.cloud": 1,
  "s3-website.nl-ams.scw.cloud": 1,
  "s3-website.pl-waw.scw.cloud": 1,
  "s3-website.us-east-2.amazonaws.com": 1,
  "s3.amazonaws.com": 1,
  "s3.ap-northeast-2.amazonaws.com": 1,
  "s3.ap-south-1.amazonaws.com": 1,
  "s3.ca-central-1.amazonaws.com": 1,
  "s3.cn-north-1.amazonaws.com.cn": 1,
  "s3.dualstack.ap-northeast-1.amazonaws.com": 1,
  "s3.dualstack.ap-northeast-2.amazonaws.com": 1,
  "s3.dualstack.ap-south-1.amazonaws.com": 1,
  "s3.dualstack.ap-southeast-1.amazonaws.com": 1,
  "s3.dualstack.ap-southeast-2.amazonaws.com": 1,
  "s3.dualstack.ca-central-1.amazonaws.com": 1,
  "s3.dualstack.eu-central-1.amazonaws.com": 1,
  "s3.dualstack.eu-west-1.amazonaws.com": 1,
  "s3.dualstack.eu-west-2.amazonaws.com": 1,
  "s3.dualstack.eu-west-3.amazonaws.com": 1,
  "s3.dualstack.sa-east-1.amazonaws.com": 1,
  "s3.dualstack.us-east-1.amazonaws.com": 1,
  "s3.dualstack.us-east-2.amazonaws.com": 1,
  "s3.eu-central-1.amazonaws.com": 1,
  "s3.eu-west-2.amazonaws.com": 1,
  "s3.eu-west-3.amazonaws.com": 1,
  "s3.fr-par.scw.cloud": 1,
  "s3.nl-ams.scw.cloud": 1,
  "s3.pl-waw.scw.cloud": 1,
  "s3.teckids.org": 1,
  "s3.us-east-2.amazonaws.com": 1,
  "s5y.io": 2,
  "sa-east-1.elasticbeanstalk.com": 1,
  "sa.au": 1,
  "sa.com": 1,
  "sa.cr": 1,
  "sa.edu.au": 1,
  "sa.gov.au": 1,
  "sa.gov.pl": 1,
  "sa.it": 1,
  "sabae.fukui.jp": 1,
  "sadist.jp": 1,
  "sado.niigata.jp": 1,
  "safety.aero": 1,
  "saga.jp": 1,
  "saga.saga.jp": 1,
  "sagae.yamagata.jp": 1,
  "sagamihara.kanagawa.jp": 1,
  "saigawa.fukuoka.jp": 1,
  "saijo.ehime.jp": 1,
  "saikai.nagasaki.jp": 1,
  "saiki.oita.jp": 1,
  "saintlouis.museum": 1,
  "saitama.jp": 1,
  "saitama.saitama.jp": 1,
  "saito.miyazaki.jp": 1,
  "saka.hiroshima.jp": 1,
  "sakado.saitama.jp": 1,
  "sakae.chiba.jp": 1,
  "sakae.nagano.jp": 1,
  "sakahogi.gifu.jp": 1,
  "sakai.fukui.jp": 1,
  "sakai.ibaraki.jp": 1,
  "sakai.osaka.jp": 1,
  "sakaiminato.tottori.jp": 1,
  "sakaki.nagano.jp": 1,
  "sakata.yamagata.jp": 1,
  "sakawa.kochi.jp": 1,
  "sakegawa.yamagata.jp": 1,
  "saku.nagano.jp": 1,
  "sakuho.nagano.jp": 1,
  "sakura.chiba.jp": 1,
  "sakura.tochigi.jp": 1,
  "sakuragawa.ibaraki.jp": 1,
  "sakurai.nara.jp": 1,
  "sakyo.kyoto.jp": 1,
  "salangen.no": 1,
  "salat.no": 1,
  "salem.museum": 1,
  "salerno.it": 1,
  "saltdal.no": 1,
  "salud.bo": 1,
  "salvador.br": 1,
  "salvadordali.museum": 1,
  "salzburg.museum": 1,
  "samegawa.fukushima.jp": 1,
  "samnanger.no": 1,
  "sampa.br": 1,
  "samukawa.kanagawa.jp": 1,
  "sanagochi.tokushima.jp": 1,
  "sanda.hyogo.jp": 1,
  "sandcats.io": 1,
  "sande.more-og-romsdal.no": 1,
  "sande.vestfold.no": 1,
  "sande.xn--mre-og-romsdal-qqb.no": 1,
  "sandefjord.no": 1,
  "sandiego.museum": 1,
  "sandnes.no": 1,
  "sandnessjoen.no": 1,
  "sandoy.no": 1,
  "sanfrancisco.museum": 1,
  "sango.nara.jp": 1,
  "sanjo.niigata.jp": 1,
  "sannan.hyogo.jp": 1,
  "sannohe.aomori.jp": 1,
  "sano.tochigi.jp": 1,
  "sanok.pl": 1,
  "santabarbara.museum": 1,
  "santacruz.museum": 1,
  "santafe.museum": 1,
  "santamaria.br": 1,
  "santoandre.br": 1,
  "sanuki.kagawa.jp": 1,
  "saobernardo.br": 1,
  "saogonca.br": 1,
  "saotome.st": 1,
  "sapporo.jp": 2,
  "sar.it": 1,
  "sardegna.it": 1,
  "sardinia.it": 1,
  "saroma.hokkaido.jp": 1,
  "sarpsborg.no": 1,
  "sarufutsu.hokkaido.jp": 1,
  "sasaguri.fukuoka.jp": 1,
  "sasayama.hyogo.jp": 1,
  "sasebo.nagasaki.jp": 1,
  "saskatchewan.museum": 1,
  "sassari.it": 1,
  "satosho.okayama.jp": 1,
  "satsumasendai.kagoshima.jp": 1,
  "satte.saitama.jp": 1,
  "satx.museum": 1,
  "sauda.no": 1,
  "sauherad.no": 1,
  "savannahga.museum": 1,
  "saves-the-whales.com": 1,
  "savona.it": 1,
  "sayama.osaka.jp": 1,
  "sayama.saitama.jp": 1,
  "sayo.hyogo.jp": 1,
  "sb.ua": 1,
  "sc.cn": 1,
  "sc.gov.br": 1,
  "sc.ke": 1,
  "sc.kr": 1,
  "sc.leg.br": 1,
  "sc.ls": 1,
  "sc.tz": 1,
  "sc.ug": 1,
  "sc.us": 1,
  "scalebook.scw.cloud": 1,
  "sch.ae": 1,
  "sch.id": 1,
  "sch.ir": 1,
  "sch.jo": 1,
  "sch.lk": 1,
  "sch.ly": 1,
  "sch.ng": 1,
  "sch.qa": 1,
  "sch.sa": 1,
  "sch.so": 1,
  "sch.ss": 1,
  "sch.tf": 1,
  "sch.uk": 2,
  "sch.wf": 1,
  "sch.zm": 1,
  "schlesisches.museum": 1,
  "schoenbrunn.museum": 1,
  "schokokeks.net": 1,
  "schokoladen.museum": 1,
  "school.museum": 1,
  "school.na": 1,
  "school.nz": 1,
  "school.za": 1,
  "schoolbus.jp": 1,
  "schools.nsw.edu.au": 1,
  "schulplattform.de": 1,
  "schulserver.de": 1,
  "schweiz.museum": 1,
  "sci.eg": 1,
  "science-fiction.museum": 1,
  "science.museum": 1,
  "scienceandhistory.museum": 1,
  "scienceandindustry.museum": 1,
  "sciencecenter.museum": 1,
  "sciencecenters.museum": 1,
  "sciencehistory.museum": 1,
  "sciences.museum": 1,
  "sciencesnaturelles.museum": 1,
  "scientist.aero": 1,
  "scotland.museum": 1,
  "scrapper-site.net": 1,
  "scrapping.cc": 1,
  "scrysec.com": 1,
  "sd.cn": 1,
  "sd.us": 1,
  "sdn.gov.pl": 1,
  "sdscloud.pl": 1,
  "se.eu.org": 1,
  "se.gov.br": 1,
  "se.leg.br": 1,
  "se.net": 1,
  "seaport.museum": 1,
  "sebastopol.ua": 1,
  "sec.ps": 1,
  "secaas.hk": 1,
  "secret.jp": 1,
  "securitytactics.com": 1,
  "seg.br": 1,
  "seidat.net": 1,
  "seihi.nagasaki.jp": 1,
  "seika.kyoto.jp": 1,
  "seiro.niigata.jp": 1,
  "seirou.niigata.jp": 1,
  "seiyo.ehime.jp": 1,
  "sejny.pl": 1,
  "sekd1.beebyteapp.io": 1,
  "seki.gifu.jp": 1,
  "sekigahara.gifu.jp": 1,
  "sekikawa.niigata.jp": 1,
  "sel.no": 1,
  "selbu.no": 1,
  "selfip.biz": 1,
  "selfip.com": 1,
  "selfip.info": 1,
  "selfip.net": 1,
  "selfip.org": 1,
  "selje.no": 1,
  "seljord.no": 1,
  "sellfy.store": 1,
  "sells-for-less.com": 1,
  "sells-for-u.com": 1,
  "sells-it.net": 1,
  "sellsyourhome.org": 1,
  "semboku.akita.jp": 1,
  "semine.miyagi.jp": 1,
  "senasa.ar": 1,
  "sendai.jp": 2,
  "sennan.osaka.jp": 1,
  "senseering.net": 1,
  "sensiosite.cloud": 2,
  "seoul.kr": 1,
  "sera.hiroshima.jp": 1,
  "seranishi.hiroshima.jp": 1,
  "servebbs.com": 1,
  "servebbs.net": 1,
  "servebbs.org": 1,
  "servebeer.com": 1,
  "serveblog.net": 1,
  "servecounterstrike.com": 1,
  "serveexchange.com": 1,
  "serveftp.com": 1,
  "serveftp.net": 1,
  "serveftp.org": 1,
  "servegame.com": 1,
  "servegame.org": 1,
  "servehalflife.com": 1,
  "servehttp.com": 1,
  "servehumour.com": 1,
  "serveirc.com": 1,
  "serveminecraft.net": 1,
  "servemp3.com": 1,
  "servep2p.com": 1,
  "servepics.com": 1,
  "servequake.com": 1,
  "servers.run": 1,
  "servesarcasm.com": 1,
  "service.gov.scot": 1,
  "service.gov.uk": 1,
  "service.one": 1,
  "services.aero": 1,
  "setagaya.tokyo.jp": 1,
  "seto.aichi.jp": 1,
  "setouchi.okayama.jp": 1,
  "settlement.museum": 1,
  "settlers.museum": 1,
  "settsu.osaka.jp": 1,
  "sevastopol.ua": 1,
  "sex.hu": 1,
  "sex.pl": 1,
  "sf.no": 1,
  "sg-1.paas.massivegrid.net": 1,
  "sh.cn": 1,
  "shacknet.nu": 1,
  "shakotan.hokkaido.jp": 1,
  "shari.hokkaido.jp": 1,
  "shell.museum": 1,
  "sherbrooke.museum": 1,
  "shibata.miyagi.jp": 1,
  "shibata.niigata.jp": 1,
  "shibecha.hokkaido.jp": 1,
  "shibetsu.hokkaido.jp": 1,
  "shibukawa.gunma.jp": 1,
  "shibuya.tokyo.jp": 1,
  "shichikashuku.miyagi.jp": 1,
  "shichinohe.aomori.jp": 1,
  "shiftcrypto.dev": 1,
  "shiftcrypto.io": 1,
  "shiftedit.io": 1,
  "shiga.jp": 1,
  "shiiba.miyazaki.jp": 1,
  "shijonawate.osaka.jp": 1,
  "shika.ishikawa.jp": 1,
  "shikabe.hokkaido.jp": 1,
  "shikama.miyagi.jp": 1,
  "shikaoi.hokkaido.jp": 1,
  "shikatsu.aichi.jp": 1,
  "shiki.saitama.jp": 1,
  "shikokuchuo.ehime.jp": 1,
  "shima.mie.jp": 1,
  "shimabara.nagasaki.jp": 1,
  "shimada.shizuoka.jp": 1,
  "shimamaki.hokkaido.jp": 1,
  "shimamoto.osaka.jp": 1,
  "shimane.jp": 1,
  "shimane.shimane.jp": 1,
  "shimizu.hokkaido.jp": 1,
  "shimizu.shizuoka.jp": 1,
  "shimoda.shizuoka.jp": 1,
  "shimodate.ibaraki.jp": 1,
  "shimofusa.chiba.jp": 1,
  "shimogo.fukushima.jp": 1,
  "shimoichi.nara.jp": 1,
  "shimoji.okinawa.jp": 1,
  "shimokawa.hokkaido.jp": 1,
  "shimokitayama.nara.jp": 1,
  "shimonita.gunma.jp": 1,
  "shimonoseki.yamaguchi.jp": 1,
  "shimosuwa.nagano.jp": 1,
  "shimotsuke.tochigi.jp": 1,
  "shimotsuma.ibaraki.jp": 1,
  "shinagawa.tokyo.jp": 1,
  "shinanomachi.nagano.jp": 1,
  "shingo.aomori.jp": 1,
  "shingu.fukuoka.jp": 1,
  "shingu.hyogo.jp": 1,
  "shingu.wakayama.jp": 1,
  "shinichi.hiroshima.jp": 1,
  "shinjo.nara.jp": 1,
  "shinjo.okayama.jp": 1,
  "shinjo.yamagata.jp": 1,
  "shinjuku.tokyo.jp": 1,
  "shinkamigoto.nagasaki.jp": 1,
  "shinonsen.hyogo.jp": 1,
  "shinshinotsu.hokkaido.jp": 1,
  "shinshiro.aichi.jp": 1,
  "shinto.gunma.jp": 1,
  "shintoku.hokkaido.jp": 1,
  "shintomi.miyazaki.jp": 1,
  "shinyoshitomi.fukuoka.jp": 1,
  "shiogama.miyagi.jp": 1,
  "shiojiri.nagano.jp": 1,
  "shioya.tochigi.jp": 1,
  "shirahama.wakayama.jp": 1,
  "shirakawa.fukushima.jp": 1,
  "shirakawa.gifu.jp": 1,
  "shirako.chiba.jp": 1,
  "shiranuka.hokkaido.jp": 1,
  "shiraoi.hokkaido.jp": 1,
  "shiraoka.saitama.jp": 1,
  "shirataka.yamagata.jp": 1,
  "shiriuchi.hokkaido.jp": 1,
  "shiroi.chiba.jp": 1,
  "shiroishi.miyagi.jp": 1,
  "shiroishi.saga.jp": 1,
  "shirosato.ibaraki.jp": 1,
  "shishikui.tokushima.jp": 1,
  "shiso.hyogo.jp": 1,
  "shisui.chiba.jp": 1,
  "shitara.aichi.jp": 1,
  "shiwa.iwate.jp": 1,
  "shizukuishi.iwate.jp": 1,
  "shizuoka.jp": 1,
  "shizuoka.shizuoka.jp": 1,
  "shobara.hiroshima.jp": 1,
  "shonai.fukuoka.jp": 1,
  "shonai.yamagata.jp": 1,
  "shoo.okayama.jp": 1,
  "shop.brendly.rs": 1,
  "shop.ht": 1,
  "shop.hu": 1,
  "shop.pl": 1,
  "shop.ro": 1,
  "shop.th": 1,
  "shoparena.pl": 1,
  "shopitsite.com": 1,
  "shopselect.net": 1,
  "shopware.store": 1,
  "show.aero": 1,
  "showa.fukushima.jp": 1,
  "showa.gunma.jp": 1,
  "showa.yamanashi.jp": 1,
  "shunan.yamaguchi.jp": 1,
  "shw.io": 1,
  "si.eu.org": 1,
  "si.it": 1,
  "sibenik.museum": 1,
  "sic.it": 1,
  "sicilia.it": 1,
  "sicily.it": 1,
  "siellak.no": 1,
  "siena.it": 1,
  "sigdal.no": 1,
  "siiites.com": 1,
  "siljan.no": 1,
  "silk.museum": 1,
  "simple-url.com": 1,
  "sinaapp.com": 1,
  "siracusa.it": 1,
  "sirdal.no": 1,
  "site.tb-hosting.com": 1,
  "site.transip.me": 1,
  "siteleaf.net": 1,
  "sites.static.land": 1,
  "sjc.br": 1,
  "sk.ca": 1,
  "sk.eu.org": 1,
  "skanit.no": 1,
  "skanland.no": 1,
  "skaun.no": 1,
  "skedsmo.no": 1,
  "skedsmokorset.no": 1,
  "ski.museum": 1,
  "ski.no": 1,
  "skien.no": 1,
  "skierva.no": 1,
  "skiptvet.no": 1,
  "skjak.no": 1,
  "skjervoy.no": 1,
  "sklep.pl": 1,
  "sko.gov.pl": 1,
  "skoczow.pl": 1,
  "skodje.no": 1,
  "skole.museum": 1,
  "skydiving.aero": 1,
  "skygearapp.com": 1,
  "slask.pl": 1,
  "slattum.no": 1,
  "sld.do": 1,
  "sld.pa": 1,
  "slg.br": 1,
  "slupsk.pl": 1,
  "slz.br": 1,
  "sm.ua": 1,
  "small-web.org": 1,
  "smartlabeling.scw.cloud": 1,
  "smola.no": 1,
  "smushcdn.com": 1,
  "sn.cn": 1,
  "snaase.no": 1,
  "snasa.no": 1,
  "snillfjord.no": 1,
  "snoasa.no": 1,
  "so.gov.pl": 1,
  "so.it": 1,
  "sobetsu.hokkaido.jp": 1,
  "soc.dz": 1,
  "soc.lk": 1,
  "soc.srcf.net": 1,
  "sochi.su": 1,
  "society.museum": 1,
  "sodegaura.chiba.jp": 1,
  "soeda.fukuoka.jp": 1,
  "software.aero": 1,
  "sogndal.no": 1,
  "sogne.no": 1,
  "soja.okayama.jp": 1,
  "soka.saitama.jp": 1,
  "sokndal.no": 1,
  "sola.no": 1,
  "sologne.museum": 1,
  "solund.no": 1,
  "soma.fukushima.jp": 1,
  "somna.no": 1,
  "sondre-land.no": 1,
  "sondrio.it": 1,
  "songdalen.no": 1,
  "soni.nara.jp": 1,
  "soo.kagoshima.jp": 1,
  "sopot.pl": 1,
  "sor-aurdal.no": 1,
  "sor-fron.no": 1,
  "sor-odal.no": 1,
  "sor-varanger.no": 1,
  "sorfold.no": 1,
  "sorocaba.br": 1,
  "sorreisa.no": 1,
  "sortland.no": 1,
  "sorum.no": 1,
  "sos.pl": 1,
  "sosa.chiba.jp": 1,
  "sosnowiec.pl": 1,
  "soundandvision.museum": 1,
  "soundcast.me": 1,
  "southcarolina.museum": 1,
  "southwest.museum": 1,
  "sowa.ibaraki.jp": 1,
  "sp.gov.br": 1,
  "sp.it": 1,
  "sp.leg.br": 1,
  "space-to-rent.com": 1,
  "space.museum": 1,
  "spacekit.io": 1,
  "spb.ru": 1,
  "spb.su": 1,
  "spdns.de": 1,
  "spdns.eu": 1,
  "spdns.org": 1,
  "spectrum.myjino.ru": 2,
  "sphinx.mythic-beasts.com": 1,
  "spjelkavik.no": 1,
  "sport.hu": 1,
  "spy.museum": 1,
  "spydeberg.no": 1,
  "square.museum": 1,
  "square7.ch": 1,
  "square7.de": 1,
  "square7.net": 1,
  "sr.gov.pl": 1,
  "sr.it": 1,
  "srht.site": 1,
  "srv.br": 1,
  "ss.it": 1,
  "ssl.origin.cdn77-secure.org": 1,
  "st.no": 1,
  "staba.jp": 1,
  "stackhero-network.com": 1,
  "stadt.museum": 1,
  "stage.nodeart.io": 1,
  "staging.onred.one": 1,
  "stalbans.museum": 1,
  "stalowa-wola.pl": 1,
  "stange.no": 1,
  "starachowice.pl": 1,
  "stargard.pl": 1,
  "starnberg.museum": 1,
  "starostwo.gov.pl": 1,
  "stat.no": 1,
  "state.museum": 1,
  "stateofdelaware.museum": 1,
  "stathelle.no": 1,
  "static-access.net": 1,
  "static.land": 1,
  "static.observableusercontent.com": 1,
  "statics.cloud": 2,
  "station.museum": 1,
  "stavanger.no": 1,
  "stavern.no": 1,
  "steam.museum": 1,
  "steiermark.museum": 1,
  "steigen.no": 1,
  "steinkjer.no": 1,
  "stg-builder.code.com": 2,
  "stg.dev": 2,
  "stgstage.dev": 2,
  "sth.ac.at": 1,
  "stjohn.museum": 1,
  "stjordal.no": 1,
  "stjordalshalsen.no": 1,
  "stockholm.museum": 1,
  "stokke.no": 1,
  "stolos.io": 2,
  "stor-elvdal.no": 1,
  "storage.yandexcloud.net": 1,
  "stord.no": 1,
  "stordal.no": 1,
  "store.bb": 1,
  "store.dk": 1,
  "store.nf": 1,
  "store.ro": 1,
  "store.st": 1,
  "store.ve": 1,
  "storebase.store": 1,
  "storfjord.no": 1,
  "storj.farm": 1,
  "stpetersburg.museum": 1,
  "strand.no": 1,
  "stranda.no": 1,
  "streamlitapp.com": 1,
  "stripper.jp": 1,
  "stryn.no": 1,
  "student.aero": 1,
  "stuff-4-sale.org": 1,
  "stuff-4-sale.us": 1,
  "stufftoread.com": 1,
  "stuttgart.museum": 1,
  "su.paba.se": 1,
  "sub.jp": 1,
  "sue.fukuoka.jp": 1,
  "suedtirol.it": 1,
  "suginami.tokyo.jp": 1,
  "sugito.saitama.jp": 1,
  "suifu.ibaraki.jp": 1,
  "suisse.museum": 1,
  "suita.osaka.jp": 1,
  "sukagawa.fukushima.jp": 1,
  "sukumo.kochi.jp": 1,
  "sula.no": 1,
  "suldal.no": 1,
  "suli.hu": 1,
  "sumida.tokyo.jp": 1,
  "sumita.iwate.jp": 1,
  "sumoto.hyogo.jp": 1,
  "sumoto.kumamoto.jp": 1,
  "sumy.ua": 1,
  "sunagawa.hokkaido.jp": 1,
  "sund.no": 1,
  "sunndal.no": 1,
  "sunnyday.jp": 1,
  "supabase.co": 1,
  "supabase.in": 1,
  "supabase.net": 1,
  "supersale.jp": 1,
  "surgeonshall.museum": 1,
  "surnadal.no": 1,
  "surrey.museum": 1,
  "susaki.kochi.jp": 1,
  "susono.shizuoka.jp": 1,
  "suwa.nagano.jp": 1,
  "suwalki.pl": 1,
  "suzaka.nagano.jp": 1,
  "suzu.ishikawa.jp": 1,
  "suzuka.mie.jp": 1,
  "sv.it": 1,
  "svalbard.no": 1,
  "svc.firenet.ch": 2,
  "sveio.no": 1,
  "svelvik.no": 1,
  "svizzera.museum": 1,
  "svn-repos.de": 1,
  "sweden.museum": 1,
  "sweetpepper.org": 1,
  "swidnica.pl": 1,
  "swidnik.pl": 1,
  "swiebodzin.pl": 1,
  "swinoujscie.pl": 1,
  "sx.cn": 1,
  "sydney.museum": 1,
  "sykkylven.no": 1,
  "syncloud.it": 1,
  "syno-ds.de": 1,
  "synology-diskstation.de": 1,
  "synology-ds.de": 1,
  "synology.me": 1,
  "sys.qcx.io": 2,
  "sytes.net": 1,
  "szczecin.pl": 1,
  "szczytno.pl": 1,
  "szex.hu": 1,
  "szkola.pl": 1,
  "t.bg": 1,
  "t.se": 1,
  "t3l3p0rt.net": 1,
  "ta.it": 1,
  "taa.it": 1,
  "tabayama.yamanashi.jp": 1,
  "tabitorder.co.il": 1,
  "tabuse.yamaguchi.jp": 1,
  "tachiarai.fukuoka.jp": 1,
  "tachikawa.tokyo.jp": 1,
  "tadaoka.osaka.jp": 1,
  "tado.mie.jp": 1,
  "tadotsu.kagawa.jp": 1,
  "tagajo.miyagi.jp": 1,
  "tagami.niigata.jp": 1,
  "tagawa.fukuoka.jp": 1,
  "tahara.aichi.jp": 1,
  "taifun-dns.de": 1,
  "taiji.wakayama.jp": 1,
  "taiki.hokkaido.jp": 1,
  "taiki.mie.jp": 1,
  "tainai.niigata.jp": 1,
  "taira.toyama.jp": 1,
  "taishi.hyogo.jp": 1,
  "taishi.osaka.jp": 1,
  "taishin.fukushima.jp": 1,
  "taito.tokyo.jp": 1,
  "taiwa.miyagi.jp": 1,
  "tajimi.gifu.jp": 1,
  "tajiri.osaka.jp": 1,
  "taka.hyogo.jp": 1,
  "takagi.nagano.jp": 1,
  "takahagi.ibaraki.jp": 1,
  "takahama.aichi.jp": 1,
  "takahama.fukui.jp": 1,
  "takaharu.miyazaki.jp": 1,
  "takahashi.okayama.jp": 1,
  "takahata.yamagata.jp": 1,
  "takaishi.osaka.jp": 1,
  "takamatsu.kagawa.jp": 1,
  "takamori.kumamoto.jp": 1,
  "takamori.nagano.jp": 1,
  "takanabe.miyazaki.jp": 1,
  "takanezawa.tochigi.jp": 1,
  "takaoka.toyama.jp": 1,
  "takarazuka.hyogo.jp": 1,
  "takasago.hyogo.jp": 1,
  "takasaki.gunma.jp": 1,
  "takashima.shiga.jp": 1,
  "takasu.hokkaido.jp": 1,
  "takata.fukuoka.jp": 1,
  "takatori.nara.jp": 1,
  "takatsuki.osaka.jp": 1,
  "takatsuki.shiga.jp": 1,
  "takayama.gifu.jp": 1,
  "takayama.gunma.jp": 1,
  "takayama.nagano.jp": 1,
  "takazaki.miyazaki.jp": 1,
  "takehara.hiroshima.jp": 1,
  "taketa.oita.jp": 1,
  "taketomi.okinawa.jp": 1,
  "taki.mie.jp": 1,
  "takikawa.hokkaido.jp": 1,
  "takino.hyogo.jp": 1,
  "takinoue.hokkaido.jp": 1,
  "takko.aomori.jp": 1,
  "tako.chiba.jp": 1,
  "taku.saga.jp": 1,
  "tama.tokyo.jp": 1,
  "tamakawa.fukushima.jp": 1,
  "tamaki.mie.jp": 1,
  "tamamura.gunma.jp": 1,
  "tamano.okayama.jp": 1,
  "tamatsukuri.ibaraki.jp": 1,
  "tamayu.shimane.jp": 1,
  "tamba.hyogo.jp": 1,
  "tana.no": 1,
  "tanabe.kyoto.jp": 1,
  "tanabe.wakayama.jp": 1,
  "tanagura.fukushima.jp": 1,
  "tananger.no": 1,
  "tank.museum": 1,
  "tanohata.iwate.jp": 1,
  "tara.saga.jp": 1,
  "tarama.okinawa.jp": 1,
  "taranto.it": 1,
  "targi.pl": 1,
  "tarnobrzeg.pl": 1,
  "tarui.gifu.jp": 1,
  "tarumizu.kagoshima.jp": 1,
  "tas.au": 1,
  "tas.edu.au": 1,
  "tas.gov.au": 1,
  "tashkent.su": 1,
  "tatebayashi.gunma.jp": 1,
  "tateshina.nagano.jp": 1,
  "tateyama.chiba.jp": 1,
  "tateyama.toyama.jp": 1,
  "tatsuno.hyogo.jp": 1,
  "tatsuno.nagano.jp": 1,
  "tawaramoto.nara.jp": 1,
  "taxi.br": 1,
  "tbits.me": 1,
  "tc.br": 1,
  "tcm.museum": 1,
  "tcp4.me": 1,
  "te.it": 1,
  "te.ua": 1,
  "teaches-yoga.com": 1,
  "tec.br": 1,
  "tec.mi.us": 1,
  "tec.ve": 1,
  "tech.orange": 1,
  "technology.museum": 1,
  "tecnologia.bo": 1,
  "tel.tr": 1,
  "tele.amune.org": 1,
  "telebit.app": 1,
  "telebit.io": 1,
  "telebit.xyz": 2,
  "telekommunikation.museum": 1,
  "television.museum": 1,
  "temp-dns.com": 1,
  "tempio-olbia.it": 1,
  "tempioolbia.it": 1,
  "tempurl.host": 1,
  "tendo.yamagata.jp": 1,
  "tenei.fukushima.jp": 1,
  "tenkawa.nara.jp": 1,
  "tenri.nara.jp": 1,
  "teo.br": 1,
  "teramo.it": 1,
  "termez.su": 1,
  "terni.it": 1,
  "ternopil.ua": 1,
  "teshikaga.hokkaido.jp": 1,
  "test-iserv.de": 1,
  "test.ru": 1,
  "test.tj": 1,
  "texas.museum": 1,
  "textile.museum": 1,
  "tgory.pl": 1,
  "that.win": 1,
  "the.br": 1,
  "theater.museum": 1,
  "theshop.jp": 1,
  "theworkpc.com": 1,
  "thick.jp": 1,
  "thingdustdata.com": 1,
  "thruhere.net": 1,
  "tickets.io": 1,
  "time.museum": 1,
  "time.no": 1,
  "timekeeping.museum": 1,
  "tingvoll.no": 1,
  "tinn.no": 1,
  "tj.cn": 1,
  "tjeldsund.no": 1,
  "tjome.no": 1,
  "tksat.bo": 1,
  "tlon.network": 1,
  "tm.cy": 1,
  "tm.dz": 1,
  "tm.fr": 1,
  "tm.hu": 1,
  "tm.km": 1,
  "tm.mc": 1,
  "tm.mg": 1,
  "tm.no": 1,
  "tm.pl": 1,
  "tm.ro": 1,
  "tm.se": 1,
  "tm.za": 1,
  "tmp.br": 1,
  "tn.it": 1,
  "tn.oxa.cloud": 1,
  "tn.us": 1,
  "to.gov.br": 1,
  "to.gt": 1,
  "to.it": 1,
  "to.leg.br": 1,
  "to.md": 1,
  "to.work": 1,
  "toba.mie.jp": 1,
  "tobe.ehime.jp": 1,
  "tobetsu.hokkaido.jp": 1,
  "tobishima.aichi.jp": 1,
  "tochigi.jp": 1,
  "tochigi.tochigi.jp": 1,
  "tochio.niigata.jp": 1,
  "toda.saitama.jp": 1,
  "toei.aichi.jp": 1,
  "toga.toyama.jp": 1,
  "togakushi.nagano.jp": 1,
  "togane.chiba.jp": 1,
  "togitsu.nagasaki.jp": 1,
  "togliatti.su": 1,
  "togo.aichi.jp": 1,
  "togura.nagano.jp": 1,
  "tohma.hokkaido.jp": 1,
  "tohnosho.chiba.jp": 1,
  "toho.fukuoka.jp": 1,
  "tokai.aichi.jp": 1,
  "tokai.ibaraki.jp": 1,
  "tokamachi.niigata.jp": 1,
  "tokashiki.okinawa.jp": 1,
  "toki.gifu.jp": 1,
  "tokigawa.saitama.jp": 1,
  "tokke.no": 1,
  "tokoname.aichi.jp": 1,
  "tokorozawa.saitama.jp": 1,
  "tokushima.jp": 1,
  "tokushima.tokushima.jp": 1,
  "tokuyama.yamaguchi.jp": 1,
  "tokyo.jp": 1,
  "tolga.no": 1,
  "tomakomai.hokkaido.jp": 1,
  "tomari.hokkaido.jp": 1,
  "tome.miyagi.jp": 1,
  "tomi.nagano.jp": 1,
  "tomigusuku.okinawa.jp": 1,
  "tomika.gifu.jp": 1,
  "tomioka.gunma.jp": 1,
  "tomisato.chiba.jp": 1,
  "tomiya.miyagi.jp": 1,
  "tomobe.ibaraki.jp": 1,
  "tonaki.okinawa.jp": 1,
  "tonami.toyama.jp": 1,
  "tondabayashi.osaka.jp": 1,
  "tone.ibaraki.jp": 1,
  "tonkotsu.jp": 1,
  "tono.iwate.jp": 1,
  "tonosho.kagawa.jp": 1,
  "tonsberg.no": 1,
  "toolforge.org": 1,
  "toon.ehime.jp": 1,
  "topology.museum": 1,
  "torahime.shiga.jp": 1,
  "toride.ibaraki.jp": 1,
  "torino.it": 1,
  "torino.museum": 1,
  "torproject.net": 1,
  "torsken.no": 1,
  "tos.it": 1,
  "tosa.kochi.jp": 1,
  "tosashimizu.kochi.jp": 1,
  "toscana.it": 1,
  "toshima.tokyo.jp": 1,
  "tosu.saga.jp": 1,
  "tottori.jp": 1,
  "tottori.tottori.jp": 1,
  "touch.museum": 1,
  "tourism.pl": 1,
  "tourism.tn": 1,
  "towada.aomori.jp": 1,
  "town.museum": 1,
  "townnews-staging.com": 1,
  "toya.hokkaido.jp": 1,
  "toyako.hokkaido.jp": 1,
  "toyama.jp": 1,
  "toyama.toyama.jp": 1,
  "toyo.kochi.jp": 1,
  "toyoake.aichi.jp": 1,
  "toyohashi.aichi.jp": 1,
  "toyokawa.aichi.jp": 1,
  "toyonaka.osaka.jp": 1,
  "toyone.aichi.jp": 1,
  "toyono.osaka.jp": 1,
  "toyooka.hyogo.jp": 1,
  "toyosato.shiga.jp": 1,
  "toyota.aichi.jp": 1,
  "toyota.yamaguchi.jp": 1,
  "toyotomi.hokkaido.jp": 1,
  "toyotsu.fukuoka.jp": 1,
  "toyoura.hokkaido.jp": 1,
  "tozawa.yamagata.jp": 1,
  "tozsde.hu": 1,
  "tp.it": 1,
  "tr.eu.org": 1,
  "tr.it": 1,
  "tr.no": 1,
  "tra.kp": 1,
  "trader.aero": 1,
  "trading.aero": 1,
  "traeumtgerade.de": 1,
  "trafficplex.cloud": 1,
  "trainer.aero": 1,
  "trana.no": 1,
  "tranby.no": 1,
  "trani-andria-barletta.it": 1,
  "trani-barletta-andria.it": 1,
  "traniandriabarletta.it": 1,
  "tranibarlettaandria.it": 1,
  "tranoy.no": 1,
  "translate.goog": 1,
  "translated.page": 1,
  "transport.museum": 1,
  "transporte.bo": 1,
  "transurl.be": 2,
  "transurl.eu": 2,
  "transurl.nl": 2,
  "trapani.it": 1,
  "travel.in": 1,
  "travel.pl": 1,
  "travel.tt": 1,
  "trd.br": 1,
  "tree.museum": 1,
  "trentin-sud-tirol.it": 1,
  "trentin-sudtirol.it": 1,
  "trentin-sued-tirol.it": 1,
  "trentin-suedtirol.it": 1,
  "trentino-a-adige.it": 1,
  "trentino-aadige.it": 1,
  "trentino-alto-adige.it": 1,
  "trentino-altoadige.it": 1,
  "trentino-s-tirol.it": 1,
  "trentino-stirol.it": 1,
  "trentino-sud-tirol.it": 1,
  "trentino-sudtirol.it": 1,
  "trentino-sued-tirol.it": 1,
  "trentino-suedtirol.it": 1,
  "trentino.it": 1,
  "trentinoa-adige.it": 1,
  "trentinoaadige.it": 1,
  "trentinoalto-adige.it": 1,
  "trentinoaltoadige.it": 1,
  "trentinos-tirol.it": 1,
  "trentinostirol.it": 1,
  "trentinosud-tirol.it": 1,
  "trentinosudtirol.it": 1,
  "trentinosued-tirol.it": 1,
  "trentinosuedtirol.it": 1,
  "trentinsud-tirol.it": 1,
  "trentinsudtirol.it": 1,
  "trentinsued-tirol.it": 1,
  "trentinsuedtirol.it": 1,
  "trento.it": 1,
  "treviso.it": 1,
  "trieste.it": 1,
  "triton.zone": 2,
  "troandin.no": 1,
  "trogstad.no": 1,
  "troitsk.su": 1,
  "trolley.museum": 1,
  "tromsa.no": 1,
  "tromso.no": 1,
  "trondheim.no": 1,
  "trust.museum": 1,
  "trustee.museum": 1,
  "try-snowplow.com": 1,
  "trycloudflare.com": 1,
  "trysil.no": 1,
  "ts.it": 1,
  "ts.net": 1,
  "tselinograd.su": 1,
  "tsk.tr": 1,
  "tst.site": 2,
  "tsu.mie.jp": 1,
  "tsubame.niigata.jp": 1,
  "tsubata.ishikawa.jp": 1,
  "tsubetsu.hokkaido.jp": 1,
  "tsuchiura.ibaraki.jp": 1,
  "tsuga.tochigi.jp": 1,
  "tsugaru.aomori.jp": 1,
  "tsuiki.fukuoka.jp": 1,
  "tsukigata.hokkaido.jp": 1,
  "tsukiyono.gunma.jp": 1,
  "tsukuba.ibaraki.jp": 1,
  "tsukui.kanagawa.jp": 1,
  "tsukumi.oita.jp": 1,
  "tsumagoi.gunma.jp": 1,
  "tsunan.niigata.jp": 1,
  "tsuno.kochi.jp": 1,
  "tsuno.miyazaki.jp": 1,
  "tsuru.yamanashi.jp": 1,
  "tsuruga.fukui.jp": 1,
  "tsurugashima.saitama.jp": 1,
  "tsurugi.ishikawa.jp": 1,
  "tsuruoka.yamagata.jp": 1,
  "tsuruta.aomori.jp": 1,
  "tsushima.aichi.jp": 1,
  "tsushima.nagasaki.jp": 1,
  "tsuwano.shimane.jp": 1,
  "tsuyama.okayama.jp": 1,
  "tt.im": 1,
  "tula.su": 1,
  "tuleap-partners.com": 1,
  "tunk.org": 1,
  "tur.ar": 1,
  "tur.br": 1,
  "turek.pl": 1,
  "turin.it": 1,
  "turystyka.pl": 1,
  "tuscany.it": 1,
  "tuva.su": 1,
  "tuxfamily.org": 1,
  "tv.bb": 1,
  "tv.bo": 1,
  "tv.br": 1,
  "tv.im": 1,
  "tv.in": 1,
  "tv.it": 1,
  "tv.kg": 1,
  "tv.na": 1,
  "tv.sd": 1,
  "tv.tr": 1,
  "tv.tz": 1,
  "tvedestrand.no": 1,
  "tw.cn": 1,
  "twmail.cc": 1,
  "twmail.net": 1,
  "twmail.org": 1,
  "tx.us": 1,
  "tychy.pl": 1,
  "tydal.no": 1,
  "tynset.no": 1,
  "typedream.app": 1,
  "tysfjord.no": 1,
  "tysnes.no": 1,
  "tysvar.no": 1,
  "u.bg": 1,
  "u.channelsdvr.net": 1,
  "u.se": 1,
  "u2-local.xnbay.com": 1,
  "u2.xnbay.com": 1,
  "ua.rs": 1,
  "ube.yamaguchi.jp": 1,
  "uber.space": 1,
  "uberspace.de": 2,
  "uchihara.ibaraki.jp": 1,
  "uchiko.ehime.jp": 1,
  "uchinada.ishikawa.jp": 1,
  "uchinomi.kagawa.jp": 1,
  "ud.it": 1,
  "uda.nara.jp": 1,
  "udi.br": 1,
  "udine.it": 1,
  "udono.mie.jp": 1,
  "ueda.nagano.jp": 1,
  "ueno.gunma.jp": 1,
  "uenohara.yamanashi.jp": 1,
  "ufcfan.org": 1,
  "ug.gov.pl": 1,
  "ugim.gov.pl": 1,
  "uhren.museum": 1,
  "ui.nabu.casa": 1,
  "uji.kyoto.jp": 1,
  "ujiie.tochigi.jp": 1,
  "ujitawara.kyoto.jp": 1,
  "uk.com": 1,
  "uk.eu.org": 1,
  "uk.in": 1,
  "uk.kg": 1,
  "uk.net": 1,
  "uk.oxa.cloud": 1,
  "uk.primetel.cloud": 1,
  "uk.reclaim.cloud": 1,
  "uk0.bigv.io": 1,
  "uki.kumamoto.jp": 1,
  "ukiha.fukuoka.jp": 1,
  "ullensaker.no": 1,
  "ullensvang.no": 1,
  "ulm.museum": 1,
  "ulsan.kr": 1,
  "ulvik.no": 1,
  "um.gov.pl": 1,
  "umaji.kochi.jp": 1,
  "umb.it": 1,
  "umbria.it": 1,
  "umi.fukuoka.jp": 1,
  "umig.gov.pl": 1,
  "unazuki.toyama.jp": 1,
  "under.jp": 1,
  "under.one": 1,
  "undersea.museum": 1,
  "uni5.net": 1,
  "unicloud.pl": 1,
  "union.aero": 1,
  "univ.sn": 1,
  "university.museum": 1,
  "unjarga.no": 1,
  "unnan.shimane.jp": 1,
  "unusualperson.com": 1,
  "unzen.nagasaki.jp": 1,
  "uonuma.niigata.jp": 1,
  "uozu.toyama.jp": 1,
  "up.in": 1,
  "upaas.kazteleport.kz": 1,
  "upli.io": 1,
  "upow.gov.pl": 1,
  "upper.jp": 1,
  "uppo.gov.pl": 1,
  "urakawa.hokkaido.jp": 1,
  "urasoe.okinawa.jp": 1,
  "urausu.hokkaido.jp": 1,
  "urawa.saitama.jp": 1,
  "urayasu.chiba.jp": 1,
  "urbino-pesaro.it": 1,
  "urbinopesaro.it": 1,
  "ureshino.mie.jp": 1,
  "uri.arpa": 1,
  "url.tw": 1,
  "urn.arpa": 1,
  "urown.cloud": 1,
  "uruma.okinawa.jp": 1,
  "uryu.hokkaido.jp": 1,
  "us-1.evennode.com": 1,
  "us-2.evennode.com": 1,
  "us-3.evennode.com": 1,
  "us-4.evennode.com": 1,
  "us-east-1.amazonaws.com": 1,
  "us-east-1.elasticbeanstalk.com": 1,
  "us-east-2.elasticbeanstalk.com": 1,
  "us-gov-west-1.elasticbeanstalk.com": 1,
  "us-west-1.elasticbeanstalk.com": 1,
  "us-west-2.elasticbeanstalk.com": 1,
  "us.ax": 1,
  "us.com": 1,
  "us.eu.org": 1,
  "us.gov.pl": 1,
  "us.in": 1,
  "us.kg": 1,
  "us.na": 1,
  "us.org": 1,
  "us.platform.sh": 1,
  "us.reclaim.cloud": 1,
  "usa.museum": 1,
  "usa.oita.jp": 1,
  "usantiques.museum": 1,
  "usarts.museum": 1,
  "uscountryestate.museum": 1,
  "usculture.museum": 1,
  "usdecorativearts.museum": 1,
  "user.aseinet.ne.jp": 1,
  "user.localcert.dev": 2,
  "user.party.eus": 1,
  "user.srcf.net": 1,
  "usercontent.goog": 2,
  "usercontent.jp": 1,
  "users.scale.virtualcloud.com.br": 1,
  "usgarden.museum": 1,
  "ushiku.ibaraki.jp": 1,
  "ushistory.museum": 1,
  "ushuaia.museum": 1,
  "uslivinghistory.museum": 1,
  "usr.cloud.muni.cz": 1,
  "ustka.pl": 1,
  "usui.fukuoka.jp": 1,
  "usuki.oita.jp": 1,
  "ut.us": 1,
  "utah.museum": 1,
  "utashinai.hokkaido.jp": 1,
  "utazas.hu": 1,
  "utazu.kagawa.jp": 1,
  "uto.kumamoto.jp": 1,
  "utsira.no": 1,
  "utsunomiya.tochigi.jp": 1,
  "utwente.io": 1,
  "uvic.museum": 1,
  "uw.gov.pl": 1,
  "uwajima.ehime.jp": 1,
  "uwu.ai": 1,
  "uy.com": 1,
  "uz.ua": 1,
  "uzhgorod.ua": 1,
  "uzs.gov.pl": 1,
  "v-info.info": 1,
  "v.bg": 1,
  "v.ua": 1,
  "va.it": 1,
  "va.no": 1,
  "va.us": 1,
  "vaapste.no": 1,
  "vadso.no": 1,
  "vaga.no": 1,
  "vagan.no": 1,
  "vagsoy.no": 1,
  "vaksdal.no": 1,
  "val-d-aosta.it": 1,
  "val-daosta.it": 1,
  "vald-aosta.it": 1,
  "valdaosta.it": 1,
  "valer.hedmark.no": 1,
  "valer.ostfold.no": 1,
  "valle-aosta.it": 1,
  "valle-d-aosta.it": 1,
  "valle-daosta.it": 1,
  "valle.no": 1,
  "valleaosta.it": 1,
  "valled-aosta.it": 1,
  "valledaosta.it": 1,
  "vallee-aoste.it": 1,
  "vallee-d-aoste.it": 1,
  "valleeaoste.it": 1,
  "valleedaoste.it": 1,
  "valley.museum": 1,
  "vang.no": 1,
  "vantaa.museum": 1,
  "vanylven.no": 1,
  "vao.it": 1,
  "vapor.cloud": 1,
  "vaporcloud.io": 1,
  "vardo.no": 1,
  "varese.it": 1,
  "varggat.no": 1,
  "varoy.no": 1,
  "vb.it": 1,
  "vc.it": 1,
  "vda.it": 1,
  "ve.it": 1,
  "vefsn.no": 1,
  "vega.no": 1,
  "vegarshei.no": 1,
  "velvet.jp": 1,
  "ven.it": 1,
  "veneto.it": 1,
  "venezia.it": 1,
  "venice.it": 1,
  "vennesla.no": 1,
  "verbania.it": 1,
  "vercel.app": 1,
  "vercel.dev": 1,
  "vercelli.it": 1,
  "verdal.no": 1,
  "verona.it": 1,
  "verran.no": 1,
  "versailles.museum": 1,
  "verse.jp": 1,
  "versus.jp": 1,
  "vestby.no": 1,
  "vestnes.no": 1,
  "vestre-slidre.no": 1,
  "vestre-toten.no": 1,
  "vestvagoy.no": 1,
  "vet.br": 1,
  "veterinaire.fr": 1,
  "veterinaire.km": 1,
  "vevelstad.no": 1,
  "vf.no": 1,
  "vfs.cloud9.af-south-1.amazonaws.com": 1,
  "vfs.cloud9.ap-east-1.amazonaws.com": 1,
  "vfs.cloud9.ap-northeast-1.amazonaws.com": 1,
  "vfs.cloud9.ap-northeast-2.amazonaws.com": 1,
  "vfs.cloud9.ap-northeast-3.amazonaws.com": 1,
  "vfs.cloud9.ap-south-1.amazonaws.com": 1,
  "vfs.cloud9.ap-southeast-1.amazonaws.com": 1,
  "vfs.cloud9.ap-southeast-2.amazonaws.com": 1,
  "vfs.cloud9.ca-central-1.amazonaws.com": 1,
  "vfs.cloud9.eu-central-1.amazonaws.com": 1,
  "vfs.cloud9.eu-north-1.amazonaws.com": 1,
  "vfs.cloud9.eu-south-1.amazonaws.com": 1,
  "vfs.cloud9.eu-west-1.amazonaws.com": 1,
  "vfs.cloud9.eu-west-2.amazonaws.com": 1,
  "vfs.cloud9.eu-west-3.amazonaws.com": 1,
  "vfs.cloud9.me-south-1.amazonaws.com": 1,
  "vfs.cloud9.sa-east-1.amazonaws.com": 1,
  "vfs.cloud9.us-east-1.amazonaws.com": 1,
  "vfs.cloud9.us-east-2.amazonaws.com": 1,
  "vfs.cloud9.us-west-1.amazonaws.com": 1,
  "vfs.cloud9.us-west-2.amazonaws.com": 1,
  "vgs.no": 1,
  "vi.it": 1,
  "vi.us": 1,
  "vibo-valentia.it": 1,
  "vibovalentia.it": 1,
  "vic.au": 1,
  "vic.edu.au": 1,
  "vic.gov.au": 1,
  "vicenza.it": 1,
  "video.hu": 1,
  "vik.no": 1,
  "viking.museum": 1,
  "vikna.no": 1,
  "village.museum": 1,
  "vindafjord.no": 1,
  "vinnica.ua": 1,
  "vinnytsia.ua": 1,
  "vip.jelastic.cloud": 1,
  "vipsinaapp.com": 1,
  "virginia.museum": 1,
  "virtual-user.de": 1,
  "virtual.museum": 1,
  "virtualserver.io": 1,
  "virtualuser.de": 1,
  "virtuel.museum": 1,
  "viterbo.it": 1,
  "vivian.jp": 1,
  "vix.br": 1,
  "vlaanderen.museum": 1,
  "vladikavkaz.ru": 1,
  "vladikavkaz.su": 1,
  "vladimir.ru": 1,
  "vladimir.su": 1,
  "vlog.br": 1,
  "vm.bytemark.co.uk": 1,
  "vn.ua": 1,
  "voagat.no": 1,
  "volda.no": 1,
  "volkenkunde.museum": 1,
  "vologda.su": 1,
  "volyn.ua": 1,
  "voorloper.cloud": 1,
  "voss.no": 1,
  "vossevangen.no": 1,
  "vp4.me": 1,
  "vpndns.net": 1,
  "vpnplus.to": 1,
  "vps-host.net": 1,
  "vps.mcdir.ru": 1,
  "vps.myjino.ru": 2,
  "vr.it": 1,
  "vs.it": 1,
  "vs.mythic-beasts.com": 1,
  "vt.it": 1,
  "vt.us": 1,
  "vultrobjects.com": 2,
  "vv.it": 1,
  "vxl.sh": 1,
  "w.bg": 1,
  "w.se": 1,
  "wa.au": 1,
  "wa.edu.au": 1,
  "wa.gov.au": 1,
  "wa.us": 1,
  "wada.nagano.jp": 1,
  "wafflecell.com": 1,
  "wajiki.tokushima.jp": 1,
  "wajima.ishikawa.jp": 1,
  "wakasa.fukui.jp": 1,
  "wakasa.tottori.jp": 1,
  "wakayama.jp": 1,
  "wakayama.wakayama.jp": 1,
  "wake.okayama.jp": 1,
  "wakkanai.hokkaido.jp": 1,
  "wakuya.miyagi.jp": 1,
  "walbrzych.pl": 1,
  "wales.museum": 1,
  "wallonie.museum": 1,
  "wanouchi.gifu.jp": 1,
  "war.museum": 1,
  "warabi.saitama.jp": 1,
  "warmia.pl": 1,
  "warszawa.pl": 1,
  "washingtondc.museum": 1,
  "washtenaw.mi.us": 1,
  "wassamu.hokkaido.jp": 1,
  "watarai.mie.jp": 1,
  "watari.miyagi.jp": 1,
  "watch-and-clock.museum": 1,
  "watchandclock.museum": 1,
  "watson.jp": 1,
  "waw.pl": 1,
  "wazuka.kyoto.jp": 1,
  "we.bs": 1,
  "we.tc": 1,
  "web.app": 1,
  "web.bo": 1,
  "web.co": 1,
  "web.do": 1,
  "web.gu": 1,
  "web.id": 1,
  "web.in": 1,
  "web.lk": 1,
  "web.nf": 1,
  "web.ni": 1,
  "web.pk": 1,
  "web.tj": 1,
  "web.tr": 1,
  "web.ve": 1,
  "web.za": 1,
  "webhare.dev": 2,
  "webhop.biz": 1,
  "webhop.info": 1,
  "webhop.me": 1,
  "webhop.net": 1,
  "webhop.org": 1,
  "webhosting.be": 1,
  "weblike.jp": 1,
  "webpaas.ovh.net": 2,
  "webredirect.org": 1,
  "website.yandexcloud.net": 1,
  "webspace.rocks": 1,
  "webthings.io": 1,
  "webview-assets.cloud9.af-south-1.amazonaws.com": 1,
  "webview-assets.cloud9.ap-east-1.amazonaws.com": 1,
  "webview-assets.cloud9.ap-northeast-1.amazonaws.com": 1,
  "webview-assets.cloud9.ap-northeast-2.amazonaws.com": 1,
  "webview-assets.cloud9.ap-northeast-3.amazonaws.com": 1,
  "webview-assets.cloud9.ap-south-1.amazonaws.com": 1,
  "webview-assets.cloud9.ap-southeast-1.amazonaws.com": 1,
  "webview-assets.cloud9.ap-southeast-2.amazonaws.com": 1,
  "webview-assets.cloud9.ca-central-1.amazonaws.com": 1,
  "webview-assets.cloud9.eu-central-1.amazonaws.com": 1,
  "webview-assets.cloud9.eu-north-1.amazonaws.com": 1,
  "webview-assets.cloud9.eu-south-1.amazonaws.com": 1,
  "webview-assets.cloud9.eu-west-1.amazonaws.com": 1,
  "webview-assets.cloud9.eu-west-2.amazonaws.com": 1,
  "webview-assets.cloud9.eu-west-3.amazonaws.com": 1,
  "webview-assets.cloud9.me-south-1.amazonaws.com": 1,
  "webview-assets.cloud9.sa-east-1.amazonaws.com": 1,
  "webview-assets.cloud9.us-east-1.amazonaws.com": 1,
  "webview-assets.cloud9.us-east-2.amazonaws.com": 1,
  "webview-assets.cloud9.us-west-1.amazonaws.com": 1,
  "webview-assets.cloud9.us-west-2.amazonaws.com": 1,
  "wedeploy.io": 1,
  "wedeploy.me": 1,
  "wedeploy.sh": 1,
  "weeklylottery.org.uk": 1,
  "wegrow.pl": 1,
  "wellbeingzone.co.uk": 1,
  "wellbeingzone.eu": 1,
  "west1-us.cloudjiffy.net": 1,
  "western.museum": 1,
  "westeurope.azurestaticapps.net": 1,
  "westfalen.museum": 1,
  "westus2.azurestaticapps.net": 1,
  "whaling.museum": 1,
  "whitesnow.jp": 1,
  "whm.fr-par.scw.cloud": 1,
  "whm.nl-ams.scw.cloud": 1,
  "wi.us": 1,
  "wielun.pl": 1,
  "wien.funkfeuer.at": 1,
  "wif.gov.pl": 1,
  "wiih.gov.pl": 1,
  "wiki.bo": 1,
  "wiki.br": 1,
  "wildlife.museum": 1,
  "williamsburg.museum": 1,
  "winb.gov.pl": 1,
  "windmill.museum": 1,
  "wios.gov.pl": 1,
  "witd.gov.pl": 1,
  "with.marketing": 1,
  "withgoogle.com": 1,
  "withyoutube.com": 1,
  "wiw.gov.pl": 1,
  "wixsite.com": 1,
  "wlocl.pl": 1,
  "wloclawek.pl": 1,
  "wmcloud.org": 1,
  "wmflabs.org": 1,
  "wnext.app": 1,
  "wodzislaw.pl": 1,
  "wolomin.pl": 1,
  "woltlab-demo.com": 1,
  "workers.dev": 1,
  "workinggroup.aero": 1,
  "workisboring.com": 1,
  "works.aero": 1,
  "workshop.museum": 1,
  "worse-than.tv": 1,
  "wpdevcloud.com": 1,
  "wpenginepowered.com": 1,
  "wphostedmail.com": 1,
  "wpmucdn.com": 1,
  "wpmudev.host": 1,
  "writesthisblog.com": 1,
  "wroc.pl": 1,
  "wroclaw.pl": 1,
  "ws.na": 1,
  "wsa.gov.pl": 1,
  "wskr.gov.pl": 1,
  "wuoz.gov.pl": 1,
  "wv.us": 1,
  "www.ck": 0,
  "www.ro": 1,
  "wy.us": 1,
  "wzmiuw.gov.pl": 1,
  "x.bg": 1,
  "x.mythic-beasts.com": 1,
  "x.se": 1,
  "x443.pw": 1,
  "xen.prgmr.com": 1,
  "xj.cn": 1,
  "xn--0trq7p7nn.jp": 1,
  "xn--12c1fe0br.xn--o3cw4h": 1,
  "xn--12cfi8ixb8l.xn--o3cw4h": 1,
  "xn--12co0c3b4eva.xn--o3cw4h": 1,
  "xn--1ctwo.jp": 1,
  "xn--1lqs03n.jp": 1,
  "xn--1lqs71d.jp": 1,
  "xn--2m4a15e.jp": 1,
  "xn--32vp30h.jp": 1,
  "xn--41a.xn--p1acf": 1,
  "xn--4dbgdty6c.xn--4dbrk0ce": 1,
  "xn--4it168d.jp": 1,
  "xn--4it797k.jp": 1,
  "xn--4pvxs.jp": 1,
  "xn--55qx5d.cn": 1,
  "xn--55qx5d.hk": 1,
  "xn--55qx5d.xn--j6w193g": 1,
  "xn--5dbhl8d.xn--4dbrk0ce": 1,
  "xn--5js045d.jp": 1,
  "xn--5rtp49c.jp": 1,
  "xn--5rtq34k.jp": 1,
  "xn--6btw5a.jp": 1,
  "xn--6orx2r.jp": 1,
  "xn--7t0a264c.jp": 1,
  "xn--80aaa0cvac.xn--p1acf": 1,
  "xn--80au.xn--90a3ac": 1,
  "xn--8dbq2a.xn--4dbrk0ce": 1,
  "xn--8ltr62k.jp": 1,
  "xn--8pvr4u.jp": 1,
  "xn--90a1af.xn--p1acf": 1,
  "xn--90amc.xn--p1acf": 1,
  "xn--90azh.xn--90a3ac": 1,
  "xn--9dbhblg6di.museum": 1,
  "xn--andy-ira.no": 1,
  "xn--aroport-bya.ci": 1,
  "xn--asky-ira.no": 1,
  "xn--aurskog-hland-jnb.no": 1,
  "xn--avery-yua.no": 1,
  "xn--b-5ga.nordland.no": 1,
  "xn--b-5ga.telemark.no": 1,
  "xn--balsan-sdtirol-nsb.it": 1,
  "xn--bdddj-mrabd.no": 1,
  "xn--bearalvhki-y4a.no": 1,
  "xn--berlevg-jxa.no": 1,
  "xn--bhcavuotna-s4a.no": 1,
  "xn--bhccavuotna-k7a.no": 1,
  "xn--bidr-5nac.no": 1,
  "xn--bievt-0qa.no": 1,
  "xn--bjarky-fya.no": 1,
  "xn--bjddar-pta.no": 1,
  "xn--blt-elab.no": 1,
  "xn--bmlo-gra.no": 1,
  "xn--bod-2na.no": 1,
  "xn--bozen-sdtirol-2ob.it": 1,
  "xn--brnny-wuac.no": 1,
  "xn--brnnysund-m8ac.no": 1,
  "xn--brum-voa.no": 1,
  "xn--btsfjord-9za.no": 1,
  "xn--bulsan-sdtirol-nsb.it": 1,
  "xn--c1avg.xn--90a3ac": 1,
  "xn--c1avg.xn--p1acf": 1,
  "xn--c3s14m.jp": 1,
  "xn--cesena-forl-mcb.it": 1,
  "xn--cesenaforl-i8a.it": 1,
  "xn--ciqpn.hk": 1,
  "xn--comunicaes-v6a2o.museum": 1,
  "xn--correios-e-telecomunicaes-ghc29a.museum": 1,
  "xn--czrw28b.tw": 1,
  "xn--d1at.xn--90a3ac": 1,
  "xn--d5qv7z876c.jp": 1,
  "xn--davvenjrga-y4a.no": 1,
  "xn--djrs72d6uy.jp": 1,
  "xn--djty4k.jp": 1,
  "xn--dnna-gra.no": 1,
  "xn--drbak-wua.no": 1,
  "xn--dyry-ira.no": 1,
  "xn--efvn9s.jp": 1,
  "xn--ehqz56n.jp": 1,
  "xn--elqq16h.jp": 1,
  "xn--eveni-0qa01ga.no": 1,
  "xn--f6qx53a.jp": 1,
  "xn--finny-yua.no": 1,
  "xn--fjord-lra.no": 1,
  "xn--fl-zia.no": 1,
  "xn--flor-jra.no": 1,
  "xn--forl-cesena-fcb.it": 1,
  "xn--forlcesena-c8a.it": 1,
  "xn--frde-gra.no": 1,
  "xn--frna-woa.no": 1,
  "xn--frya-hra.no": 1,
  "xn--ggaviika-8ya47h.no": 1,
  "xn--gildeskl-g0a.no": 1,
  "xn--givuotna-8ya.no": 1,
  "xn--gjvik-wua.no": 1,
  "xn--gls-elac.no": 1,
  "xn--gmq050i.hk": 1,
  "xn--gmqw5a.hk": 1,
  "xn--gmqw5a.xn--j6w193g": 1,
  "xn--gnstigbestellen-zvb.de": 1,
  "xn--gnstigliefern-wob.de": 1,
  "xn--h-2fa.no": 1,
  "xn--h1aegh.museum": 1,
  "xn--h1ahn.xn--p1acf": 1,
  "xn--h1aliz.xn--p1acf": 1,
  "xn--h3cuzk1di.xn--o3cw4h": 1,
  "xn--hbmer-xqa.no": 1,
  "xn--hcesuolo-7ya35b.no": 1,
  "xn--hebda8b.xn--4dbrk0ce": 1,
  "xn--hery-ira.nordland.no": 1,
  "xn--hery-ira.xn--mre-og-romsdal-qqb.no": 1,
  "xn--hgebostad-g3a.no": 1,
  "xn--hkkinen-5wa.fi": 1,
  "xn--hmmrfeasta-s4ac.no": 1,
  "xn--hnefoss-q1a.no": 1,
  "xn--hobl-ira.no": 1,
  "xn--holtlen-hxa.no": 1,
  "xn--hpmir-xqa.no": 1,
  "xn--hyanger-q1a.no": 1,
  "xn--hylandet-54a.no": 1,
  "xn--indery-fya.no": 1,
  "xn--io0a7i.cn": 1,
  "xn--io0a7i.hk": 1,
  "xn--j1adp.xn--p1acf": 1,
  "xn--j1aef.xn--p1acf": 1,
  "xn--j1ael8b.xn--p1acf": 1,
  "xn--jlster-bya.no": 1,
  "xn--jrpeland-54a.no": 1,
  "xn--k7yn95e.jp": 1,
  "xn--karmy-yua.no": 1,
  "xn--kbrq7o.jp": 1,
  "xn--kfjord-iua.no": 1,
  "xn--klbu-woa.no": 1,
  "xn--klt787d.jp": 1,
  "xn--kltp7d.jp": 1,
  "xn--kltx9a.jp": 1,
  "xn--klty5x.jp": 1,
  "xn--koluokta-7ya57h.no": 1,
  "xn--krager-gya.no": 1,
  "xn--kranghke-b0a.no": 1,
  "xn--krdsherad-m8a.no": 1,
  "xn--krehamn-dxa.no": 1,
  "xn--krjohka-hwab49j.no": 1,
  "xn--ksnes-uua.no": 1,
  "xn--kvfjord-nxa.no": 1,
  "xn--kvitsy-fya.no": 1,
  "xn--kvnangen-k0a.no": 1,
  "xn--l-1fa.no": 1,
  "xn--laheadju-7ya.no": 1,
  "xn--langevg-jxa.no": 1,
  "xn--lcvr32d.hk": 1,
  "xn--ldingen-q1a.no": 1,
  "xn--leagaviika-52b.no": 1,
  "xn--lesund-hua.no": 1,
  "xn--lgrd-poac.no": 1,
  "xn--lhppi-xqa.no": 1,
  "xn--linds-pra.no": 1,
  "xn--lns-qla.museum": 1,
  "xn--loabt-0qa.no": 1,
  "xn--lrdal-sra.no": 1,
  "xn--lrenskog-54a.no": 1,
  "xn--lt-liac.no": 1,
  "xn--lten-gra.no": 1,
  "xn--lury-ira.no": 1,
  "xn--m3ch0j3a.xn--o3cw4h": 1,
  "xn--mely-ira.no": 1,
  "xn--merker-kua.no": 1,
  "xn--mgba3a4f16a.ir": 1,
  "xn--mgba3a4fra.ir": 1,
  "xn--mjndalen-64a.no": 1,
  "xn--mk0axi.hk": 1,
  "xn--mkru45i.jp": 1,
  "xn--mlatvuopmi-s4a.no": 1,
  "xn--mli-tla.no": 1,
  "xn--mlselv-iua.no": 1,
  "xn--moreke-jua.no": 1,
  "xn--mori-qsa.nz": 1,
  "xn--mosjen-eya.no": 1,
  "xn--mot-tla.no": 1,
  "xn--msy-ula0h.no": 1,
  "xn--mtta-vrjjat-k7af.no": 1,
  "xn--muost-0qa.no": 1,
  "xn--mxtq1m.hk": 1,
  "xn--mxtq1m.xn--j6w193g": 1,
  "xn--nit225k.jp": 1,
  "xn--nmesjevuemie-tcba.no": 1,
  "xn--nry-yla5g.no": 1,
  "xn--ntso0iqx3a.jp": 1,
  "xn--ntsq17g.jp": 1,
  "xn--nttery-byae.no": 1,
  "xn--nvuotna-hwa.no": 1,
  "xn--o1ac.xn--90a3ac": 1,
  "xn--o1ach.xn--90a3ac": 1,
  "xn--o3cyx2a.xn--o3cw4h": 1,
  "xn--od0alg.cn": 1,
  "xn--od0alg.hk": 1,
  "xn--od0alg.xn--j6w193g": 1,
  "xn--od0aq3b.hk": 1,
  "xn--oppegrd-ixa.no": 1,
  "xn--ostery-fya.no": 1,
  "xn--osyro-wua.no": 1,
  "xn--porsgu-sta26f.no": 1,
  "xn--pssu33l.jp": 1,
  "xn--qqqt11m.jp": 1,
  "xn--rady-ira.no": 1,
  "xn--rdal-poa.no": 1,
  "xn--rde-ula.no": 1,
  "xn--rdy-0nab.no": 1,
  "xn--rennesy-v1a.no": 1,
  "xn--rhkkervju-01af.no": 1,
  "xn--rholt-mra.no": 1,
  "xn--rht27z.jp": 1,
  "xn--rht3d.jp": 1,
  "xn--rht61e.jp": 1,
  "xn--risa-5na.no": 1,
  "xn--risr-ira.no": 1,
  "xn--rland-uua.no": 1,
  "xn--rlingen-mxa.no": 1,
  "xn--rmskog-bya.no": 1,
  "xn--rny31h.jp": 1,
  "xn--rros-gra.no": 1,
  "xn--rskog-uua.no": 1,
  "xn--rst-0na.no": 1,
  "xn--rsta-fra.no": 1,
  "xn--ryken-vua.no": 1,
  "xn--ryrvik-bya.no": 1,
  "xn--s-1fa.no": 1,
  "xn--sandnessjen-ogb.no": 1,
  "xn--sandy-yua.no": 1,
  "xn--sdtirol-n2a.it": 1,
  "xn--seral-lra.no": 1,
  "xn--sgne-gra.no": 1,
  "xn--skierv-uta.no": 1,
  "xn--skjervy-v1a.no": 1,
  "xn--skjk-soa.no": 1,
  "xn--sknit-yqa.no": 1,
  "xn--sknland-fxa.no": 1,
  "xn--slat-5na.no": 1,
  "xn--slt-elab.no": 1,
  "xn--smla-hra.no": 1,
  "xn--smna-gra.no": 1,
  "xn--snase-nra.no": 1,
  "xn--sndre-land-0cb.no": 1,
  "xn--snes-poa.no": 1,
  "xn--snsa-roa.no": 1,
  "xn--sr-aurdal-l8a.no": 1,
  "xn--sr-fron-q1a.no": 1,
  "xn--sr-odal-q1a.no": 1,
  "xn--sr-varanger-ggb.no": 1,
  "xn--srfold-bya.no": 1,
  "xn--srreisa-q1a.no": 1,
  "xn--srum-gra.no": 1,
  "xn--stjrdal-s1a.no": 1,
  "xn--stjrdalshalsen-sqb.no": 1,
  "xn--stre-toten-zcb.no": 1,
  "xn--tjme-hra.no": 1,
  "xn--tn0ag.hk": 1,
  "xn--tnsberg-q1a.no": 1,
  "xn--tor131o.jp": 1,
  "xn--trany-yua.no": 1,
  "xn--trentin-sd-tirol-rzb.it": 1,
  "xn--trentin-sdtirol-7vb.it": 1,
  "xn--trentino-sd-tirol-c3b.it": 1,
  "xn--trentino-sdtirol-szb.it": 1,
  "xn--trentinosd-tirol-rzb.it": 1,
  "xn--trentinosdtirol-7vb.it": 1,
  "xn--trentinsd-tirol-6vb.it": 1,
  "xn--trentinsdtirol-nsb.it": 1,
  "xn--trgstad-r1a.no": 1,
  "xn--trna-woa.no": 1,
  "xn--troms-zua.no": 1,
  "xn--tysvr-vra.no": 1,
  "xn--uc0atv.hk": 1,
  "xn--uc0atv.tw": 1,
  "xn--uc0atv.xn--j6w193g": 1,
  "xn--uc0ay4a.hk": 1,
  "xn--uist22h.jp": 1,
  "xn--uisz3g.jp": 1,
  "xn--unjrga-rta.no": 1,
  "xn--uuwu58a.jp": 1,
  "xn--vads-jra.no": 1,
  "xn--valle-aoste-ebb.it": 1,
  "xn--valle-d-aoste-ehb.it": 1,
  "xn--valleaoste-e7a.it": 1,
  "xn--valledaoste-ebb.it": 1,
  "xn--vard-jra.no": 1,
  "xn--vegrshei-c0a.no": 1,
  "xn--vestvgy-ixa6o.no": 1,
  "xn--vg-yiab.no": 1,
  "xn--vgan-qoa.no": 1,
  "xn--vgsy-qoa0j.no": 1,
  "xn--vgu402c.jp": 1,
  "xn--vler-qoa.hedmark.no": 1,
  "xn--vler-qoa.xn--stfold-9xa.no": 1,
  "xn--vre-eiker-k8a.no": 1,
  "xn--vrggt-xqad.no": 1,
  "xn--vry-yla5g.no": 1,
  "xn--wcvs22d.hk": 1,
  "xn--wcvs22d.xn--j6w193g": 1,
  "xn--yer-zna.no": 1,
  "xn--ygarden-p1a.no": 1,
  "xn--ystre-slidre-ujb.no": 1,
  "xn--zbx025d.jp": 1,
  "xn--zf0ao64a.tw": 1,
  "xn--zf0avx.hk": 1,
  "xnbay.com": 1,
  "xs4all.space": 1,
  "xx.gl": 1,
  "xy.ax": 1,
  "xz.cn": 1,
  "y.bg": 1,
  "y.se": 1,
  "yabu.hyogo.jp": 1,
  "yabuki.fukushima.jp": 1,
  "yachimata.chiba.jp": 1,
  "yachiyo.chiba.jp": 1,
  "yachiyo.ibaraki.jp": 1,
  "yaese.okinawa.jp": 1,
  "yahaba.iwate.jp": 1,
  "yahiko.niigata.jp": 1,
  "yaita.tochigi.jp": 1,
  "yaizu.shizuoka.jp": 1,
  "yakage.okayama.jp": 1,
  "yakumo.hokkaido.jp": 1,
  "yakumo.shimane.jp": 1,
  "yali.mythic-beasts.com": 1,
  "yalta.ua": 1,
  "yamada.fukuoka.jp": 1,
  "yamada.iwate.jp": 1,
  "yamada.toyama.jp": 1,
  "yamaga.kumamoto.jp": 1,
  "yamagata.gifu.jp": 1,
  "yamagata.ibaraki.jp": 1,
  "yamagata.jp": 1,
  "yamagata.nagano.jp": 1,
  "yamagata.yamagata.jp": 1,
  "yamaguchi.jp": 1,
  "yamakita.kanagawa.jp": 1,
  "yamamoto.miyagi.jp": 1,
  "yamanakako.yamanashi.jp": 1,
  "yamanashi.jp": 1,
  "yamanashi.yamanashi.jp": 1,
  "yamanobe.yamagata.jp": 1,
  "yamanouchi.nagano.jp": 1,
  "yamashina.kyoto.jp": 1,
  "yamato.fukushima.jp": 1,
  "yamato.kanagawa.jp": 1,
  "yamato.kumamoto.jp": 1,
  "yamatokoriyama.nara.jp": 1,
  "yamatotakada.nara.jp": 1,
  "yamatsuri.fukushima.jp": 1,
  "yamazoe.nara.jp": 1,
  "yame.fukuoka.jp": 1,
  "yanagawa.fukuoka.jp": 1,
  "yanaizu.fukushima.jp": 1,
  "yandexcloud.net": 1,
  "yao.osaka.jp": 1,
  "yaotsu.gifu.jp": 1,
  "yasaka.nagano.jp": 1,
  "yashio.saitama.jp": 1,
  "yashiro.hyogo.jp": 1,
  "yasu.shiga.jp": 1,
  "yasuda.kochi.jp": 1,
  "yasugi.shimane.jp": 1,
  "yasuoka.nagano.jp": 1,
  "yatomi.aichi.jp": 1,
  "yatsuka.shimane.jp": 1,
  "yatsushiro.kumamoto.jp": 1,
  "yawara.ibaraki.jp": 1,
  "yawata.kyoto.jp": 1,
  "yawatahama.ehime.jp": 1,
  "yazu.tottori.jp": 1,
  "ybo.faith": 1,
  "ybo.party": 1,
  "ybo.review": 1,
  "ybo.science": 1,
  "ybo.trade": 1,
  "yk.ca": 1,
  "yn.cn": 1,
  "ynh.fr": 1,
  "yoichi.hokkaido.jp": 1,
  "yoita.niigata.jp": 1,
  "yoka.hyogo.jp": 1,
  "yokaichiba.chiba.jp": 1,
  "yokawa.hyogo.jp": 1,
  "yokkaichi.mie.jp": 1,
  "yokohama.jp": 2,
  "yokoshibahikari.chiba.jp": 1,
  "yokosuka.kanagawa.jp": 1,
  "yokote.akita.jp": 1,
  "yokoze.saitama.jp": 1,
  "yolasite.com": 1,
  "yombo.me": 1,
  "yomitan.okinawa.jp": 1,
  "yonabaru.okinawa.jp": 1,
  "yonago.tottori.jp": 1,
  "yonaguni.okinawa.jp": 1,
  "yonezawa.yamagata.jp": 1,
  "yono.saitama.jp": 1,
  "yorii.saitama.jp": 1,
  "york.museum": 1,
  "yorkshire.museum": 1,
  "yoro.gifu.jp": 1,
  "yosemite.museum": 1,
  "yoshida.saitama.jp": 1,
  "yoshida.shizuoka.jp": 1,
  "yoshikawa.saitama.jp": 1,
  "yoshimi.saitama.jp": 1,
  "yoshino.nara.jp": 1,
  "yoshinogari.saga.jp": 1,
  "yoshioka.gunma.jp": 1,
  "yotsukaido.chiba.jp": 1,
  "youth.museum": 1,
  "yuasa.wakayama.jp": 1,
  "yufu.oita.jp": 1,
  "yugawa.fukushima.jp": 1,
  "yugawara.kanagawa.jp": 1,
  "yuki.ibaraki.jp": 1,
  "yukuhashi.fukuoka.jp": 1,
  "yura.wakayama.jp": 1,
  "yurihonjo.akita.jp": 1,
  "yusuhara.kochi.jp": 1,
  "yusui.kagoshima.jp": 1,
  "yuu.yamaguchi.jp": 1,
  "yuza.yamagata.jp": 1,
  "yuzawa.niigata.jp": 1,
  "z.bg": 1,
  "z.se": 1,
  "za.bz": 1,
  "za.com": 1,
  "za.net": 1,
  "za.org": 1,
  "zachpomor.pl": 1,
  "zagan.pl": 1,
  "zakopane.pl": 1,
  "zama.kanagawa.jp": 1,
  "zamami.okinawa.jp": 1,
  "zao.miyagi.jp": 1,
  "zaporizhzhe.ua": 1,
  "zaporizhzhia.ua": 1,
  "zapto.org": 1,
  "zapto.xyz": 1,
  "zarow.pl": 1,
  "zentsuji.kagawa.jp": 1,
  "zgora.pl": 1,
  "zgorzelec.pl": 1,
  "zhitomir.ua": 1,
  "zhytomyr.ua": 1,
  "zj.cn": 1,
  "zlg.br": 1,
  "zombie.jp": 1,
  "zoological.museum": 1,
  "zoology.museum": 1,
  "zp.gov.pl": 1,
  "zp.ua": 1,
  "zt.ua": 1,
  "zushi.kanagawa.jp": 1
}

/***/ }),

/***/ "./node_modules/adblockpluscore/data/resources.js":
/*!********************************************************!*\
  !*** ./node_modules/adblockpluscore/data/resources.js ***!
  \********************************************************/
/***/ ((__unused_webpack_module, exports) => {

exports.resources = {
  "blank-text": "data:text/plain,",
  "blank-css": "data:text/css,",
  "blank-js": "data:application/javascript,",
  "blank-html": "data:text/html,<!DOCTYPE html><html><head></head><body></body></html>",
  "blank-mp3": "data:audio/mpeg;base64,SUQzBAAAAAAAI1RTU0UAAAAPAAADTGF2ZjU4LjIwLjEwMAAAAAAAAAAAAAAA//tUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAASW5mbwAAAA8AAAAGAAADAABgYGBgYGBgYGBgYGBgYGBggICAgICAgICAgICAgICAgICgoKCgoKCgoKCgoKCgoKCgwMDAwMDAwMDAwMDAwMDAwMDg4ODg4ODg4ODg4ODg4ODg4P////////////////////8AAAAATGF2YzU4LjM1AAAAAAAAAAAAAAAAJAYAAAAAAAAAAwDVxttG//sUZAAP8AAAaQAAAAgAAA0gAAABAAABpAAAACAAADSAAAAETEFNRTMuMTAwVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV//sUZB4P8AAAaQAAAAgAAA0gAAABAAABpAAAACAAADSAAAAEVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV//sUZDwP8AAAaQAAAAgAAA0gAAABAAABpAAAACAAADSAAAAEVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV//sUZFoP8AAAaQAAAAgAAA0gAAABAAABpAAAACAAADSAAAAEVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV//sUZHgP8AAAaQAAAAgAAA0gAAABAAABpAAAACAAADSAAAAEVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV//sUZJYP8AAAaQAAAAgAAA0gAAABAAABpAAAACAAADSAAAAEVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV",
  "blank-mp4": "data:video/mp4;base64,AAAAIGZ0eXBpc29tAAACAGlzb21pc28yYXZjMW1wNDEAAAAIZnJlZQAAAuJtZGF0AAACrwYF//+r3EXpvebZSLeWLNgg2SPu73gyNjQgLSBjb3JlIDE2MCByMzAxMU0gY2RlOWE5MyAtIEguMjY0L01QRUctNCBBVkMgY29kZWMgLSBDb3B5bGVmdCAyMDAzLTIwMjAgLSBodHRwOi8vd3d3LnZpZGVvbGFuLm9yZy94MjY0Lmh0bWwgLSBvcHRpb25zOiBjYWJhYz0xIHJlZj0zIGRlYmxvY2s9MTowOjAgYW5hbHlzZT0weDM6MHgxMTMgbWU9aGV4IHN1Ym1lPTcgcHN5PTEgcHN5X3JkPTEuMDA6MC4wMCBtaXhlZF9yZWY9MSBtZV9yYW5nZT0xNiBjaHJvbWFfbWU9MCB0cmVsbGlzPTEgOHg4ZGN0PTEgY3FtPTAgZGVhZHpvbmU9MjEsMTEgZmFzdF9wc2tpcD0xIGNocm9tYV9xcF9vZmZzZXQ9LTIgdGhyZWFkcz0yIGxvb2thaGVhZF90aHJlYWRzPTEgc2xpY2VkX3RocmVhZHM9MCBucj0wIGRlY2ltYXRlPTEgaW50ZXJsYWNlZD0wIGJsdXJheV9jb21wYXQ9MCBjb25zdHJhaW5lZF9pbnRyYT0wIGJmcmFtZXM9MyBiX3B5cmFtaWQ9MiBiX2FkYXB0PTEgYl9iaWFzPTAgZGlyZWN0PTEgd2VpZ2h0Yj0xIG9wZW5fZ29wPTAgd2VpZ2h0cD0yIGtleWludD0yNTAga2V5aW50X21pbj0yNSBzY2VuZWN1dD00MCBpbnRyYV9yZWZyZXNoPTAgcmNfbG9va2FoZWFkPTQwIHJjPWNyZiBtYnRyZWU9MSBjcmY9MjMuMCBxY29tcD0wLjYwIHFwbWluPTAgcXBtYXg9NjkgcXBzdGVwPTQgaXBfcmF0aW89MS40MCBhcT0xOjEuMDAAgAAAACNliIQAK//+9dvzLK5umjbe9jc2CT9EPcfnoOYC2tjtP+go4QAAAwRtb292AAAAbG12aGQAAAAAAAAAAAAAAAAAAAPoAAAAKAABAAABAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACAAACLnRyYWsAAABcdGtoZAAAAAMAAAAAAAAAAAAAAAEAAAAAAAAAKAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAEAAAAAAZAAAADgAAAAAACRlZHRzAAAAHGVsc3QAAAAAAAAAAQAAACgAAAAAAAEAAAAAAaZtZGlhAAAAIG1kaGQAAAAAAAAAAAAAAAAAADIAAAACAFXEAAAAAAAtaGRscgAAAAAAAAAAdmlkZQAAAAAAAAAAAAAAAFZpZGVvSGFuZGxlcgAAAAFRbWluZgAAABR2bWhkAAAAAQAAAAAAAAAAAAAAJGRpbmYAAAAcZHJlZgAAAAAAAAABAAAADHVybCAAAAABAAABEXN0YmwAAACtc3RzZAAAAAAAAAABAAAAnWF2YzEAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAZAA4AEgAAABIAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAY//8AAAA3YXZjQwFkAAr/4QAaZ2QACvNlHJ42JwEQAAADABAAAAMDIPEiWWABAAZo6+PLIsD8+PgAAAAAEHBhc3AAAAABAAAAAQAAABhzdHRzAAAAAAAAAAEAAAABAAACAAAAABxzdHNjAAAAAAAAAAEAAAABAAAAAQAAAAEAAAAUc3RzegAAAAAAAALaAAAAAQAAABRzdGNvAAAAAAAAAAEAAAAwAAAAYnVkdGEAAABabWV0YQAAAAAAAAAhaGRscgAAAAAAAAAAbWRpcmFwcGwAAAAAAAAAAAAAAAAtaWxzdAAAACWpdG9vAAAAHWRhdGEAAAABAAAAAExhdmY1OC40NS4xMDA=",
  "1x1-transparent-gif": "data:image/gif;base64,R0lGODlhAQABAIABAAAAAP///yH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",
  "2x2-transparent-png": "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAIAAAACCAYAAABytg0kAAAAC0lEQVQI12NgQAcAABIAAe+JVKQAAAAASUVORK5CYII=",
  "3x2-transparent-png": "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAACCAYAAACddGYaAAAAC0lEQVQI12NgwAUAABoAASRETuUAAAAASUVORK5CYII=",
  "32x32-transparent-png": "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAGklEQVRYw+3BAQEAAACCIP+vbkhAAQAAAO8GECAAAZf3V9cAAAAASUVORK5CYII="
}

/***/ }),

/***/ "./node_modules/adblockpluscore/lib/analytics.js":
/*!*******************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/analytics.js ***!
  \*******************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_186810__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



const {Prefs} = __nested_webpack_require_186810__(/*! prefs */ "./sdk/api/prefs.js");

const {MILLIS_IN_DAY} = __nested_webpack_require_186810__(/*! ./time */ "./node_modules/adblockpluscore/lib/time.js");

/**
 * Converts a version string into a `Date` object with minute-level precision.
 *
 * @param {string} version The version string in `YYYYMMDD[HH[MM]]` format or
 *   just the value `"0"`.
 *
 * @returns {Date} A `Date` object. If the value of `version` is `"0"`, the
 *   returned value represents the Unix epoch.
 */
function versionToDate(version) {
  if (version == "0")
    return new Date(0);

  let year = version.substring(0, 4);
  let month = version.substring(4, 6);
  let date = version.substring(6, 8);

  let hours = version.substring(8, 10) || "00";
  let minutes = version.substring(10, 12) || "00";

  // The input is nearly a valid ISO 8601 timestamp, except for the hyphens,
  // the colon, and the special characters T and Z. We can use the timestamp
  // string version of the Date constructor directly. Alternatively, we could
  // use Date.UTC(), but that would require some adjustment to the values
  // (e.g. the month must be 0-based).
  return new Date(`${year}-${month}-${date}T${hours}:${minutes}Z`);
}

/**
 * Strips the value of the `firstVersion` parameter down to either `YYYYMMDD`,
 * `YYYYMM`, or `YYYY` depending on its distance from the value of the
 * `currentVersion` parameter.
 *
 * @param {string} firstVersion A version string in `YYYYMMDD[HH[MM]]` format
 *   with an optional `"-E"` suffix or just `"0"` or `"0-E"`.
 * @param {string} currentVersion A version string in `YYYYMMDD[HH[MM]]` format
 *   or just `"0"`.
 *
 * @returns {?string}
 */
function stripFirstVersion(firstVersion, currentVersion) {
  let eFlag = firstVersion.endsWith("-E");
  if (eFlag)
    firstVersion = firstVersion.slice(0, -2);

  try {
    let firstDate = versionToDate(firstVersion);
    let currentDate = versionToDate(currentVersion);

    if (currentDate - firstDate > 365 * MILLIS_IN_DAY)
      firstVersion = firstVersion.substring(0, 4);
    else if (currentDate - firstDate > 30 * MILLIS_IN_DAY)
      firstVersion = firstVersion.substring(0, 6);
    else
      firstVersion = firstVersion.substring(0, 8);
  }
  catch (error) {
    return null;
  }

  if (eFlag)
    firstVersion += "-E";

  return firstVersion;
}

/**
 * Checks whether this is a fresh installation.
 * @returns {boolean}
 */
function isFreshInstall() {
  return !("data" in Prefs.notificationdata);
}

/**
 * `{@link module:analytics.analytics analytics}` implementation.
 */
class Analytics {
  /**
   * @hideconstructor
   */
  constructor() {
  }

  /**
   * Checks whether the given URL is trusted for analytics purposes based on
   * the value of the `analytics.trustedHosts` preference.
   *
   * @param {string} url The URL.
   *
   * @returns {boolean} Whether the URL is trusted.
   */
  isTrusted(url) {
    let {trustedHosts} = Prefs.analytics || {};
    if (Array.isArray(trustedHosts)) {
      try {
        return trustedHosts.includes(new URL(url).host);
      }
      catch (error) {
      }
    }

    return false;
  }

  /**
   * Returns a string indicating the version of the first ever downloaded
   * resource (as recorded by
   * `{@link module:analytics~Analytics#recordVersion recordVersion()}`), for
   * the purpose of cohort analysis.
   *
   * For privacy reasons, the original value is stripped down to either
   * `YYYYMMDD`, `YYYYMM`, or `YYYY` depending on its age. An `-E` suffix is
   * appended to the original value if it was recorded on an existing
   * installation.
   *
   * @returns {?string} A string indicating the version of the first ever
   *   downloaded resource, or `"0"` or `"0-E"` if there is no data, or `null`
   *   in case of a parsing error.
   */
  getFirstVersion() {
    let {analytics} = Prefs;
    if (analytics) {
      let {firstVersion = "0", currentVersion = "0"} = analytics.data || {};
      let strippedFirstVersion = stripFirstVersion(firstVersion,
                                                   currentVersion);
      if (strippedFirstVersion) {
        if (strippedFirstVersion == "0" && !isFreshInstall())
          strippedFirstVersion = "0-E";

        return strippedFirstVersion;
      }
    }

    return null;
  }

  /**
   * Records the version of a downloaded resource for the purpose of cohort
   * analysis.
   *
   * The value of the `analytics` preference must be set at least to an
   * empty object, otherwise nothing is ever recorded and
   * `{@link module:analytics~Analytics#getFirstVersion getFirstVersion()}`
   * always returns `null`.
   *
   * @param {string} version The version, in `YYYYMMDD[HH[MM]]` format.
   */
  recordVersion(version) {
    if (!/^(\d{8}|\d{10}|\d{12})$/.test(version))
      return;

    let {analytics} = Prefs;
    if (analytics) {
      if (!analytics.data)
        analytics.data = {};

      let {data} = analytics;

      data.currentVersion = version;

      if (typeof data.firstVersion == "undefined") {
        // If this is not a new installation, set the -E flag.
        if (!isFreshInstall())
          version += "-E";

        data.firstVersion = version;
      }

      // JSON values aren't saved unless they are assigned a different object.
      Prefs.analytics = JSON.parse(JSON.stringify(analytics));
    }
  }
}

/**
 * Implements data analytics functions.
 * @type {module:analytics~Analytics}
 */
exports.analytics = new Analytics();


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/caching.js":
/*!*****************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/caching.js ***!
  \*****************************************************/
/***/ ((__unused_webpack_module, exports) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * A `Cache` object represents a cache of arbitrary data.
 * @package
 */
exports.Cache = class Cache extends Map {
  /**
   * Creates a cache.
   * @param {number} capacity The maximum number of entries that can exist in
   *   the cache.
   */
  constructor(capacity) {
    // Note: This check works for non-number values.
    if (!(capacity >= 1))
      throw new Error("capacity must be a positive number.");

    super();
    this._capacity = capacity;
  }

  /**
   * Writes an entry to the cache.
   *
   * If the cache has reached the specified maximum number of entries, all the
   * old entries are cleared first.
   *
   * @param {?*} key The key for the entry.
   * @param {?*} value The value of the entry.
   */
  set(key, value) {
    // To prevent logical errors, neither key nor value is allowed to be
    // undefined.
    if (typeof key == "undefined")
      throw new Error("key must not be undefined.");

    if (typeof value == "undefined")
      throw new Error("value must not be undefined.");

    if (this.size == this._capacity && !this.has(key))
      this.clear();

    super.set(key, value);
  }
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/contentTypes.js":
/*!**********************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/contentTypes.js ***!
  \**********************************************************/
/***/ ((__unused_webpack_module, exports) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



let contentTypes =
/**
 * Content types for request blocking and allowing (allowlisting).
 *
 * There are two kinds of content types: resource types, and special
 * (non-resource) types.
 *
 * Resource types include web resources like scripts, images, and so on.
 *
 * Special types include filter options for popup blocking and CSP header
 * injection as well as flags for allowing documents.
 *
 * By default a filter matches any resource type, but if a filter has an
 * explicit resource type, special option, or allowing flag, like
 * `$script`, `$popup`, or `$elemhide`, then it matches only the given type,
 * option, or flag.
 *
 * @type {Object}
 *
 * @public
 */
exports.contentTypes = {
  // Types of web resources.
  OTHER: 1,
  SCRIPT: 2,
  IMAGE: 4,
  STYLESHEET: 8,
  OBJECT: 16,
  SUBDOCUMENT: 32,
  WEBSOCKET: 128,
  WEBRTC: 256,
  PING: 1024,
  XMLHTTPREQUEST: 2048, // 1 << 11

  MEDIA: 16384,
  FONT: 32768, // 1 << 15

  // Special filter options.
  POPUP: 1 << 24,
  CSP: 1 << 25,
  HEADER: 1 << 26,

  // Allowing flags.
  DOCUMENT: 1 << 27,
  GENERICBLOCK: 1 << 28,
  ELEMHIDE: 1 << 29,
  GENERICHIDE: 1 << 30
};

// Backwards compatibility.
contentTypes.BACKGROUND = contentTypes.IMAGE;
contentTypes.XBL = contentTypes.OTHER;
contentTypes.DTD = contentTypes.OTHER;

const RESOURCE_TYPES =
/**
 * Bitmask for resource types like `$script`, `$image`, `$stylesheet`, and so
 * on.
 *
 * If a filter has no explicit content type, it applies to all resource types
 * (but not to any {@link module:contentTypes.SPECIAL_TYPES special types}).
 *
 * @const {number}
 *
 * @package
 */
// The first 24 bits are reserved for resource types like "script", "image",
// and so on.
// https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/webRequest/ResourceType
exports.RESOURCE_TYPES = (1 << 24) - 1;

const SPECIAL_TYPES = ~RESOURCE_TYPES & (1 << 31) - 1;
/**
 * Bitmask for special "types" (options and flags) like `$csp`, `$elemhide`,
 * and so on.
 *
 * @const {number}
 *
 * @package
 */
exports.SPECIAL_TYPES = SPECIAL_TYPES;

/**
 * Bitmask for "types" that match against request context more than
 * actual content type. When matching against context types, you
 * should also include the request's resource type.
 *
 * @const {number}
 *
 * @package
 */
const CONTEXT_TYPES = contentTypes.HEADER | contentTypes.CSP;
exports.CONTEXT_TYPES = CONTEXT_TYPES;

/**
 * Bitmask for "types" (flags) that are for exception rules only, like
 * `$document`, `$elemhide`, and so on.
 *
 * @const {number}
 *
 * @package
 */
exports.ALLOWING_TYPES = contentTypes.DOCUMENT |
                         contentTypes.GENERICBLOCK |
                         contentTypes.ELEMHIDE |
                         contentTypes.GENERICHIDE;

/**
 * Yields individual types from a filter's type mask.
 *
 * @param {number} contentType A filter's type mask.
 * @param {number} [selection] Which types to yield.
 *
 * @generator
 * @yields {number}
 *
 * @package
 */
exports.enumerateTypes = function* enumerateTypes(contentType, selection = ~0) {
  for (let mask = contentType & selection, bitIndex = 0;
    mask != 0; mask >>>= 1, bitIndex++) {
    if ((mask & 1) != 0) {
      // Note: The zero-fill right shift by zero is necessary for dropping the
      // sign.
      yield 1 << bitIndex >>> 0;
    }
  }
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/dnr/index.js":
/*!*******************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/dnr/index.js ***!
  \*******************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_199848__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */



/** @module */

const {Pattern} = __nested_webpack_require_199848__(/*! ../patterns */ "./node_modules/adblockpluscore/lib/patterns.js");
const {parseDomains} = __nested_webpack_require_199848__(/*! ../url */ "./node_modules/adblockpluscore/lib/url.js");
const {contentTypes, RESOURCE_TYPES} = __nested_webpack_require_199848__(/*! ../contentTypes */ "./node_modules/adblockpluscore/lib/contentTypes.js");
const {
  generateCSPRules,
  generateAllowingRules,
  generateRedirectRules,
  generateBlockingRules,
  validateRule
} = __nested_webpack_require_199848__(/*! ./rules */ "./node_modules/adblockpluscore/lib/dnr/rules.js");
const {parse, FilterParsingError} = __nested_webpack_require_199848__(/*! ../filters */ "./node_modules/adblockpluscore/lib/filters/index.js");

/**
 * @typedef {Object} ConverterOptions
 * @property {function} isRegexSupported a sync/async method to check if a
 *  generic regular expression is compatible with the engine.
 * @property {function} modifyRule a sync method to modify a DNR rule if needed.
 */

/**
 * Returns a callback bound to the given options.
 * @param {ConverterOptions} options in Mv3 Web extensions this would be
 *  `chrome.declarativeNetRequest.isRegexSupported`, so that it's possible to
 *  pass `chrome.declarativeNetRequest` directly as option.
 * @returns {function}
 */
exports.createConverter = options => convert.bind({
  ...options,
  // ensure a callback to verify RegExp when needed
  // By default regex are not supported.
  isRegexSupported: options.isRegexSupported || (() => false),
  // ensure a callback to modify a DNR rule when needed
  modifyRule: options.modifyRule || (o => o)
});

/**
 * @typedef {Object} Rule see https://developer.chrome.com/docs/extensions/reference/declarativeNetRequest/#type-Rule
 * @property {object} action see https://developer.chrome.com/docs/extensions/reference/declarativeNetRequest/#type-RuleAction
 * @property {object} condition see https://developer.chrome.com/docs/extensions/reference/declarativeNetRequest/#type-RuleCondition
 * @property {number} id a unique identifier for this rule
 * @property {number?} priority optional priority of the filter
 */

/**
 * Returns an array with DNR Rules if the text is network related, or an Error
 * if no suitable rule can be created.
 * @param {string} text the filter text to convert or the generated error.
 * @returns {Rule[]|FilterParsingError}
 */
function convert(text) {
  const result = parse(text);

  if (result instanceof FilterParsingError)
    return result;

  return asDNR.call(this, result);
}

/** Convert a parsed filter to a DeclarativeNetRequest
 *
 * To work properly this function must be bound to an object that
 * has a method `isRegexSupported` that will return whether the RegExp
 * passed as argument is valid or not for DNR. This is necessary as
 * they have to be RE2 expection and this syntax isn't supported by native
 * JavaScript. There is a (native) node module or the Chrome WebExtension
 * API. `createConverter` will provide a default function that always
 * return true.
 *
 * @param {module:filters/index~ParsedFilter} parsedFilter The parsed filter
 *   object.
 * @return {Rule[]|Error}
 */
function asDNR(parsedFilter) {
  let {
    blocking,
    text,
    regexpSource,
    contentType,
    matchCase,
    domains,
    thirdParty,
    sitekeys,
    header,
    rewrite,
    csp
  } = parsedFilter;

  // Sitekey aren't currently handled with DeclarativeNetRequest
  if (sitekeys || header) {
    return new FilterParsingError("filter_unknown_option",
                                  {
                                    option: sitekeys ? "sitekey" : "header",
                                    text
                                  });
  }

  try {
    const urlPattern = new Pattern(regexpSource, matchCase);
    let {pattern: urlFilter} = urlPattern;
    let checkValidRegExp = true;
    let hostname;

    matchCase = urlPattern.matchCase;

    if (urlFilter) {
      // We need to split out the hostname part (if any) of the filter, then
      // decide if it can be matched as lowercase or not.
      let match = /^(\|\||[a-zA-Z]*:\/\/)([^*^?/|]*)(.*)$/.exec(urlFilter);
      if (match) {
        hostname = match[2].toLowerCase();

        urlFilter = match[1] + hostname + match[3];
        matchCase = matchCase ||
                    match[3].length < 2 ||
                    !/[a-zA-Z]/.test(match[3]);
      }

      // The declarativeNetRequest API does not like the urlFilter to have a
      // redundant ||* prefix, so let's strip that now.
      if (urlFilter.startsWith("||*"))
        // A pattern beginning with `||*` isn't allowed, and `*`
        // should be used instead. So let's remove the `||`
        // See https://developer.chrome.com/docs/extensions/reference/declarativeNetRequest/#type-RuleCondition
        urlFilter = urlFilter.substr(2);
    }
    else if (urlPattern.regexp) {
      checkValidRegExp = this.isRegexSupported({
        regex: urlPattern.regexp.source,
        isCaseSensitive: matchCase
      });
    }

    if (!checkValidRegExp) {
      return new FilterParsingError("filter_invalid_regexp",
                                    {
                                      regexp: urlPattern.regexp.source,
                                      text
                                    });
    }

    const filter = {
      blocking,
      regexp: urlPattern.regexp,
      contentType: contentType || RESOURCE_TYPES,
      thirdParty,
      rewrite,
      csp,
      domains: domains === null ? null : parseDomains(
        domains.toLowerCase(), "|")
    };

    let result;
    if (contentType & contentTypes.CSP)
      result = generateCSPRules(filter, urlFilter, matchCase);
    else if (!blocking)
      result = generateAllowingRules(filter, urlFilter, matchCase);
    else if (rewrite)
      result = generateRedirectRules(filter, urlFilter, matchCase);
    else
      result = generateBlockingRules(filter, urlFilter, matchCase);

    return result
      .map(this.modifyRule)
      .map(validateRule);
  }
  catch (error) {
    return new FilterParsingError("filter_invalid_regexp",
                                  {regexp: regexpSource, text});
  }
}

exports.asDNR = asDNR;


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/dnr/rules.js":
/*!*******************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/dnr/rules.js ***!
  \*******************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_207055__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */



/** @module */

const {contentTypes} = __nested_webpack_require_207055__(/*! ../contentTypes */ "./node_modules/adblockpluscore/lib/contentTypes.js");
const {resources} = __nested_webpack_require_207055__(/*! ../../data/resources.js */ "./node_modules/adblockpluscore/data/resources.js");

// We differentiate generic rules from specific ones in order to support the
// conversion of $genericblock exception filters. Since with the
// declarativeNetRequest API "allow" rules take priority over "allowAllRequest"
// rules, we also need to take care to give "allowAllRequest" rules a slighlty
// higher priority.
const GENERIC_PRIORITY = 1000;
exports.GENERIC_PRIORITY = GENERIC_PRIORITY;
const GENERIC_ALLOW_ALL_PRIORITY = 1001;
exports.GENERIC_ALLOW_ALL_PRIORITY = GENERIC_ALLOW_ALL_PRIORITY;
const SPECIFIC_PRIORITY = 2000;
exports.SPECIFIC_PRIORITY = SPECIFIC_PRIORITY;
const SPECIFIC_ALLOW_ALL_PRIORITY = 2001;
exports.SPECIFIC_ALLOW_ALL_PRIORITY = SPECIFIC_ALLOW_ALL_PRIORITY;


const requestTypes = new Map([
  [contentTypes.OTHER, ["other", "csp_report"]],
  [contentTypes.SCRIPT, ["script"]],
  [contentTypes.IMAGE, ["image"]],
  [contentTypes.STYLESHEET, ["stylesheet"]],
  [contentTypes.OBJECT, ["object"]],
  [contentTypes.SUBDOCUMENT, ["sub_frame"]],
  [contentTypes.WEBSOCKET, ["websocket"]],
  [contentTypes.PING, ["ping"]],
  [contentTypes.XMLHTTPREQUEST, ["xmlhttprequest"]],
  [contentTypes.MEDIA, ["media"]],
  [contentTypes.FONT, ["font"]]
]);
exports.requestTypes = requestTypes;

const supportedRequestTypes = Array.from(requestTypes.keys())
                                   .reduce(((srt, t) => srt | t));
exports.supportedRequestTypes = supportedRequestTypes;

function getResourceTypes(filterContentType) {
  // The default is to match everything except "main_frame", which is fine.
  if ((filterContentType & supportedRequestTypes) == supportedRequestTypes)
    return;

  let result = [];

  for (let [mask, types] of requestTypes) {
    if (filterContentType & mask)
      result = result.concat(types);
  }

  return result;
}

function getDomains(filterDomains) {
  let domains = [];
  let excludedDomains = [];
  let isGenericFilter = true;

  if (filterDomains) {
    for (let [domain, enabled] of filterDomains) {
      if (domain == "")
        isGenericFilter = enabled;
      else
        (enabled ? domains : excludedDomains).push(domain);
    }
  }

  return {domains, excludedDomains, isGenericFilter};
}

function getCondition(filter, urlFilter, resourceTypes, matchCase) {
  let condition = {};

  if (urlFilter)
    condition.urlFilter = urlFilter;
  else if (filter.regexp)
    condition.regexFilter = filter.regexp.source;

  if (resourceTypes)
    condition.resourceTypes = resourceTypes;

  if (!matchCase)
    condition.isUrlFilterCaseSensitive = false;

  if (filter.thirdParty != null)
    condition.domainType = filter.thirdParty ? "thirdParty" : "firstParty";

  let {domains, excludedDomains, isGenericFilter} = getDomains(filter.domains);

  if (domains.length)
    condition.domains = domains;
  if (excludedDomains.length)
    condition.excludedDomains = excludedDomains;

  return [condition, isGenericFilter];
}

exports.generateRedirectRules = function(filter, urlFilter, matchCase) {
  let url = resources[filter.rewrite];

  // We can't generate rules for unknown abp-resources...
  if (!url)
    return [];

  let resourceTypes = getResourceTypes(filter.contentType);

  // We can't generate rules for filters which don't include any supported
  // resource types.
  if (resourceTypes && resourceTypes.length == 0)
    return [];

  let [condition, isGenericFilter] = getCondition(
    filter, urlFilter, resourceTypes, matchCase
  );

  return [{
    priority: isGenericFilter ? GENERIC_PRIORITY : SPECIFIC_PRIORITY,
    condition,
    action: {
      type: "redirect",
      redirect: {url}
    }
  }];
};

exports.generateCSPRules = function(filter, urlFilter, matchCase) {
  let [condition, isGenericFilter] = getCondition(
    filter, urlFilter, ["main_frame", "sub_frame"], matchCase
  );

  let rule;

  if (!filter.blocking) {
    // The DNR makes no distinction between CSP rules and main_frame/sub_frame
    // rules. Ideally, we would give CSP rules a different priority therefore,
    // to ensure that a $csp exception filter would not accidentally allowlist
    // the whole website. Unfortunately, I don't think that's possible if we are
    // to also support the distinction between specific and generic rules.
    //   Luckily, we are adding an "allow" rule (not "allowAllRequest") here and
    // there is no such thing as a blocking filter which applies to the
    // $document (main_frame), so we don't have to worry about that. There is
    // such a thing as a $subdocument blocking filter though, which a $csp
    // exception filter should not usually affect.
    //   As a compromise in order to support both $csp and $genericblock, we
    // accept that $csp exception filters might wrongly prevent frame-blocking
    // filters from matching. If this compromise proves problematic, we might
    // need to reconsider this in the future.
    rule = {
      action: {
        type: "allow"
      },
      condition,
      priority: filter.contentType & contentTypes.GENERICBLOCK ?
                  GENERIC_PRIORITY : SPECIFIC_PRIORITY
    };
  }
  else {
    rule = {
      action: {
        type: "modifyHeaders",
        responseHeaders: [{
          header: "Content-Security-Policy",
          operation: "append",
          value: filter.csp
        }]
      },
      condition,
      priority: isGenericFilter ? GENERIC_PRIORITY : SPECIFIC_PRIORITY
    };
  }

  // Chromium doesn't consider main_frame requests to have initiated from their
  // URL, so the domains/excludedDomains rule conditions won't work as expected
  // for main_frame requests. This is a problem for $csp filters which also use
  // the $domain option. As a partial workaround, we generate a separate
  // urlFilter rule for each domain. But note, we can't support excludedDomains
  // ($csp=...$~domain=...) or urlFilter conditions (||...$csp=...,domain=...).
  // See https://bugs.chromium.org/p/chromium/issues/detail?id=1207326
  //
  // Note: Hopefully, this workaround won't be necessary for long, but if we
  // need it long-term, then perhaps we should generate one rule with a longer
  // regexFilter condition instead. But if we do that, we will need to be
  // careful not to hit the memory limit for regular expression rule conditions
  // and also to match subdomains correctly.
  if (rule.condition.excludedDomains)
    return [];
  if (rule.condition.domains) {
    if (condition.urlFilter)
      return [];

    let {domains} = condition;
    delete condition.domains;

    let rules = [];
    for (let domain of domains) {
      let domainRule = JSON.parse(JSON.stringify(rule));
      domainRule.condition.urlFilter = "||" + domain + "^";
      rules.push(domainRule);
    }

    return rules;
  }

  return [rule];
};

exports.generateBlockingRules = function(filter, urlFilter, matchCase) {
  let resourceTypes = getResourceTypes(filter.contentType);

  // We can't generate rules for filters which don't include any supported
  // resource types.
  if (resourceTypes && resourceTypes.length == 0)
    return [];

  let [condition, isGenericFilter] = getCondition(
    filter, urlFilter, resourceTypes, matchCase
  );

  return [{
    priority: isGenericFilter ? GENERIC_PRIORITY : SPECIFIC_PRIORITY,
    condition,
    action: {
      type: "block"
    }
  }];
};

exports.generateAllowingRules = function(filter, urlFilter, matchCase) {
  let rules = [];
  let {contentType} = filter;

  let genericBlock = contentType & contentTypes.GENERICBLOCK;

  if (contentType & contentTypes.DOCUMENT || genericBlock) {
    contentType &= ~contentTypes.SUBDOCUMENT;

    rules.push({
      priority: genericBlock ?
                  GENERIC_ALLOW_ALL_PRIORITY : SPECIFIC_ALLOW_ALL_PRIORITY,
      condition: getCondition(
        filter, urlFilter, ["main_frame", "sub_frame"], matchCase)[0],
      action: {
        type: "allowAllRequests"
      }
    });
  }

  let resourceTypes = getResourceTypes(contentType);
  if (!resourceTypes || resourceTypes.length) {
    rules.push({
      priority: genericBlock ? GENERIC_PRIORITY : SPECIFIC_PRIORITY,
      condition: getCondition(filter, urlFilter, resourceTypes, matchCase)[0],
      action: {
        type: "allow"
      }
    });
  }

  return rules;
};

function validateIsAsciiOnly(str) {
  // [0-127] range is considered to be allowed ASCII characters
  if (!/^[\x00-\x7F]*$/.test(str))
    throw new Error(`Invalid ASCII characters found in: "${str}"`);
}
exports.validateIsAsciiOnly = validateIsAsciiOnly;

function validateDomains(domains) {
  if (domains) {
    for (let domain of domains)
      validateIsAsciiOnly(domain);
  }
}

function validateCondition(condition) {
  if (condition.urlFilter)
    validateIsAsciiOnly(condition.urlFilter);
  if (condition.regexFilter)
    validateIsAsciiOnly(condition.regexFilter);

  validateDomains(condition.initiatorDomains);
  validateDomains(condition.requestDomains);

  // deprecated starting Chrome 101
  validateDomains(condition.domains);
  validateDomains(condition.excludedDomains);

  // starting Chrome 101
  validateDomains(condition.excludedInitiatorDomains);
  validateDomains(condition.excludedRequestDomains);
}

exports.validateRule = function(rule) {
  try {
    validateCondition(rule.condition);
    return rule;
  }
  catch (e) {
    return e;
  }
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/downloader.js":
/*!********************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/downloader.js ***!
  \********************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_217620__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * @file Downloads a set of URLs in regular time intervals.
 */

const {MILLIS_IN_DAY} = __nested_webpack_require_217620__(/*! ./time */ "./node_modules/adblockpluscore/lib/time.js");
const {isLocalhost} = __nested_webpack_require_217620__(/*! ./url */ "./node_modules/adblockpluscore/lib/url.js");

/**
 * A type of function that yields `{@link module:downloader.Downloadable}`
 * objects to a `{@link module:downloader.Downloader}`.
 *
 * **Note**: The implementation must yield a new
 * `{@link module:downloader.Downloadable}` instance on each call with
 * up-to-date values for properties like
 * `{@link module:downloader.Downloadable#lastCheck}`,
 * `{@link module:downloader.Downloadable#lastVersion}`,
 * `{@link module:downloader.Downloadable#downloadCount}`, and others. If a
 * value is outdated, it may result in unexpected behavior.
 *
 * @callback DataSource
 *
 * @yields {module:downloader.Downloadable}
 * @generator
 *
 * @see module:downloader.Downloader
 * @see module:downloader.Downloader#dataSource
 */

/**
 * Use a `Downloader` object to download a set of URLs at regular time
 * intervals.
 *
 * This class is used by `{@link module:synchronizer.synchronizer}` and
 * `{@link module:notifications.notifications}`.
 *
 * @example
 *
 * function* dataSource()
 * {
 *   yield new Downloadable("https://example.com/filters.txt");
 * }
 *
 * let initialDelay = 1000;
 * let checkInterval = 60000;
 *
 * let downloader = new Downloader(dataSource);
 * downloader.scheduleChecks(checkInterval, initialDelay);
 *
 * downloader.onDownloadStarted = function(downloadable)
 * {
 *   console.log(`Downloading ${downloadable.url} ...`);
 * }
 *
 * @package
 */
exports.Downloader = class Downloader {
  /**
   * Creates a new downloader instance.
   * @param {module:downloader~DataSource} dataSource
   *   A function that yields `{@link module:downloader.Downloadable}` objects
   *   on each {@link module:downloader.Downloader#scheduleChecks check}.
   */
  constructor(dataSource) {
    /**
     * Maximal time interval that the checks can be left out until the soft
     * expiration interval increases.
     * @type {number}
     */
    this.maxAbsenceInterval = 1 * MILLIS_IN_DAY;

    /**
     * Minimal time interval before retrying a download after an error.
     * @type {number}
     */
    this.minRetryInterval = 1 * MILLIS_IN_DAY;

    /**
     * Maximal allowed expiration interval; larger expiration
     * intervals will be corrected.
     * @type {number}
     */
    this.maxExpirationInterval = 14 * MILLIS_IN_DAY;

    /**
     * Maximal number of redirects before the download is considered as failed.
     * @type {number}
     */
    this.maxRedirects = 5;

    /**
     * Called whenever expiration intervals for an object need to be adapted.
     * @type {function?}
     */
    this.onExpirationChange = null;

    /**
     * Callback to be triggered whenever a download starts.
     * @type {function?}
     */
    this.onDownloadStarted = null;

    /**
     * Callback to be triggered whenever a download finishes successfully.
     *
     * The callback can return an error code to indicate that the data is
     * wrong.
     *
     * @type {function?}
     */
    this.onDownloadSuccess = null;

    /**
     * Callback to be triggered whenever a download fails.
     * @type {function?}
     */
    this.onDownloadError = null;

    /**
     * A function that yields `{@link module:downloader.Downloadable}` objects
     * on each {@link module:downloader.Downloader#scheduleChecks check}.
     * @type {module:downloader~DataSource}
     */
    this.dataSource = dataSource;

    /**
     * Set containing the URLs of objects currently being downloaded.
     * @type {Set.<string>}
     */
    this._downloading = new Set();

    /**
     * Store the timeout ID for scheduled checks.
     * @type {number}
     */
    this._timeout = 0;
  }

  /**
   * Schedules checks at regular time intervals.
   *
   * @param {number} interval The interval between checks in milliseconds.
   * @param {number} delay The delay before the initial check in milliseconds.
   */
  scheduleChecks(interval, delay) {
    // clear previous timeouts if called too many times
    this.unscheduleChecks();

    let check = () => {
      try {
        this._doCheck();
      }
      finally {
        // Schedule the next check only after the callback has finished with
        // the current check.
        this._timeout =
          setTimeout(check, interval); // eslint-disable-line no-undef
      }
    };

    // Note: test/_common.js overrides setTimeout() for the tests; if this
    // global function is used anywhere else, it may give incorrect results.
    // This is why we disable ESLint's no-undef rule locally.
    // https://gitlab.com/eyeo/adblockplus/abc/adblockpluscore/issues/43
    this._timeout = setTimeout(check, delay); // eslint-disable-line no-undef
  }

  /**
   * Clear previously scheduled checks, if any.
   */
  unscheduleChecks() {
    if (this._timeout) {
      clearTimeout(this._timeout); // eslint-disable-line no-undef
      this._timeout = 0;
    }
  }

  /**
   * Checks whether anything needs downloading.
   */
  _doCheck() {
    let now = Date.now();
    for (let downloadable of this.dataSource()) {
      if (downloadable.lastCheck &&
          now - downloadable.lastCheck > this.maxAbsenceInterval) {
        // No checks for a long time interval - user must have been offline,
        // e.g.  during a weekend. Increase soft expiration to prevent load
        // peaks on the server.
        downloadable.softExpiration += now - downloadable.lastCheck;
      }
      downloadable.lastCheck = now;

      // Sanity check: do expiration times make sense? Make sure people changing
      // system clock don't get stuck with outdated subscriptions.
      if (downloadable.hardExpiration - now > this.maxExpirationInterval)
        downloadable.hardExpiration = now + this.maxExpirationInterval;
      if (downloadable.softExpiration - now > this.maxExpirationInterval)
        downloadable.softExpiration = now + this.maxExpirationInterval;

      // Notify the caller about changes to expiration parameters
      if (this.onExpirationChange)
        this.onExpirationChange(downloadable);

      // Does that object need downloading?
      if (downloadable.softExpiration > now &&
          downloadable.hardExpiration > now)
        continue;

      // Do not retry downloads too often
      if (downloadable.lastError &&
          now - downloadable.lastError < this.minRetryInterval)
        continue;

      this._download(downloadable, 0);
    }
  }

  /**
   * Checks whether an address is currently being downloaded.
   * @param {string} url
   * @returns {boolean}
   */
  isDownloading(url) {
    return this._downloading.has(url);
  }

  /**
   * Starts downloading for an object.
   * @param {Downloadable} downloadable
   */
  download(downloadable) {
    this._download(downloadable, 0);
  }

  /**
   * Generates the real download URL for an object by appending various
   * parameters.
   * @param {Downloadable} downloadable
   * @returns {string}
   */
  getDownloadUrl(downloadable) {
    const {addonName, addonVersion, application, applicationVersion,
           platform, platformVersion, manifestVersion} = __nested_webpack_require_217620__(/*! info */ "./sdk/api/info.js");

    let url = downloadable.redirectURL || downloadable.url;
    if (url.includes("?"))
      url += "&";
    else
      url += "?";

    // We limit the download count to 4+ to keep the request anonymized.
    let {downloadCount, disabled} = downloadable;
    if (downloadCount > 4)
      downloadCount = "4+";
    if (typeof disabled == "undefined")
      disabled = false;

    url += "addonName=" + encodeURIComponent(addonName) +
           "&addonVersion=" + encodeURIComponent(addonVersion) +
           "&application=" + encodeURIComponent(application) +
           "&applicationVersion=" + encodeURIComponent(applicationVersion) +
           "&platform=" + encodeURIComponent(platform) +
           "&platformVersion=" + encodeURIComponent(platformVersion) +
           "&lastVersion=" + encodeURIComponent(downloadable.lastVersion) +
           "&downloadCount=" + encodeURIComponent(downloadCount) +
           "&disabled=" + String(disabled) +
           "&manifestVersion=" + encodeURIComponent(manifestVersion);

    if (downloadable.firstVersion && !downloadable.redirectURL)
      url += "&firstVersion=" + encodeURIComponent(downloadable.firstVersion);

    return url;
  }

  _download(downloadable, redirects) {
    if (this.isDownloading(downloadable.url))
      return;

    let downloadUrl = this.getDownloadUrl(downloadable);
    let responseStatus = 0;

    let errorCallback = error => {
      console.warn("Adblock Plus: Downloading URL " + downloadable.url +
                   " failed (" + error + ")\n" +
                   "Download address: " + downloadUrl + "\n" +
                   "Server response: " + responseStatus);

      if (this.onDownloadError) {
        // Allow one extra redirect if the error handler gives us a redirect URL
        let redirectCallback = null;
        if (redirects <= this.maxRedirects) {
          redirectCallback = url => {
            downloadable.redirectURL = url;
            this._download(downloadable, redirects + 1);
          };
        }

        this.onDownloadError(
          downloadable, downloadUrl, error, responseStatus, redirectCallback
        );
      }
    };

    if (!Downloader.isValidURL(downloadUrl)) {
      errorCallback("synchronize_invalid_url");
      return;
    }

    let requestURL = new URL(downloadUrl);

    let initObj = {
      cache: "no-store",
      credentials: "omit",
      referrer: "no-referrer",
      method: downloadable.method
    };

    let handleError = () => {
      this._downloading.delete(downloadable.url);
      errorCallback("synchronize_connection_error");
    };

    let handleResponse = response => {
      this._downloading.delete(downloadable.url);

      // If the Response.url property is available [1], disallow redirection
      // from HTTPS to any other protocol.
      // [1]: https://developer.mozilla.org/en-US/docs/Web/API/Response/url#Browser_compatibility
      if (typeof response.url == "string" && requestURL.protocol == "https:" &&
          new URL(response.url).protocol != requestURL.protocol) {
        errorCallback("synchronize_connection_error");
        return;
      }

      responseStatus = response.status;

      if (responseStatus != 200) {
        errorCallback("synchronize_connection_error");
        return;
      }

      // We need to keep updated the subscription version even via HEAD.
      if (downloadable.method === "HEAD") {
        // However, as we don't know if the server would respond with such
        // detail, we need to be sure there is such `Date` or `date` field.
        let date = response.headers.get("Date") || response.headers.get("date");
        if (date) {
          // if that's the case, we want it to be formatted as YYYYMMDDHHMM.
          downloadable.lastVersion =
            new Date(date).toISOString().replace(/\D/g, "").slice(0, 12);
        }
      }

      if (!downloadable.disabled)
        downloadable.downloadCount++;

      response.text().then(
        responseText => {
          this.onDownloadSuccess(
            downloadable, responseText, errorCallback, url => {
              if (redirects >= this.maxRedirects) {
                errorCallback("synchronize_connection_error");
                return;
              }

              downloadable.redirectURL = url;
              this._download(downloadable, redirects + 1);
            }
          );
        },
        () => {
          errorCallback("synchronize_connection_error");
        }
      );
    };

    fetch(requestURL.href, initObj).then(handleResponse, handleError);

    this._downloading.add(downloadable.url);

    if (this.onDownloadStarted)
      this.onDownloadStarted(downloadable);
  }

  /**
   * Produces a soft and a hard expiration time for a given supplied
   * expiration interval.
   *
   * Downloadable things, like Subscription, have a certain time after
   * which they expire and you need to download a new, updated version.
   *
   * To spread the load on our download servers, we'd rather that all
   * users not download updates at exactly the same time, so on
   * download we calculate a soft expiration time, which is randomly
   * chosen between 80% and 120% of the original time. When we pass
   * the soft expiration, we start trying to download updates.
   *
   * However, there are other events that could cause downloads to all
   * happen at the same time. If many people leave their computer off
   * over the weekend and sign in at the beginning of business hours
   * on Monday, we could still see a spike in downloads at the same
   * time. To combat this, the soft expiration time may be delayed to
   * accomodate these periods of inactivity.
   *
   * There are limits to how far we want to delay our download due to
   * inactivity. This is why we also calculate a hard expiration time,
   * which is 200% of the original time. When we pass the hard
   * expiration, we should try to download an update whether there was
   * inactivity or not.
   *
   * This function must be called to calculate the new expiration
   * times as soon as a new version is downloaded.
   *
   * @param {number} interval how often in milliseconds the
   * downloadable should be updated
   * @returns {Array.<number>} soft and hard expiration times in
   * milliseconds since the Unix epoch
   */
  processExpirationInterval(interval) {
    interval = Math.min(Math.max(interval, 0), this.maxExpirationInterval);
    let soft = Math.round(interval * (Math.random() * 0.4 + 0.8));
    let hard = interval * 2;
    let now = Date.now();
    return [now + soft, now + hard];
  }
};

/**
 * Checks whether a URL is a valid download URL.
 *
 * For a URL to be a valid download URL, its scheme must be `https` or `data`.
 * If the host component of the URL is `localhost`, `127.0.0.1`, or `[::1]`,
 * however, but its scheme is not `https` or `data`, the URL is still
 * considered to be a valid download URL.
 *
 * `https://example.com/`, `data:,Hello%2C%20World!`, and
 * `http://127.0.0.1/example.txt` are all examples of valid download URLs.
 *
 * @param {string} url The URL.
 *
 * @returns {boolean} Whether the URL is a valid download URL.
 *
 * @package
 */
exports.Downloader.isValidURL = function isValidURL(url) {
  try {
    url = new URL(url);
  }
  catch (error) {
    return false;
  }

  if (!["https:", "data:"].includes(url.protocol) &&
      !isLocalhost(url.hostname))
    return false;

  return true;
};

/**
 * A `Downloadable` object represents a downloadable resource.
 * @package
 */
exports.Downloadable = class Downloadable {
  /**
   * Creates an object that can be downloaded by the downloader.
   * @param {string} url  URL that has to be requested for the object
   */
  constructor(url) {
    /**
     * URL that the download was redirected to if any.
     * @type {string?}
     */
    this.redirectURL = null;

    /**
     * Time of last download error or 0 if the last download was successful.
     * @type {number}
     */
    this.lastError = 0;

    /**
     * Time of last check whether the object needs downloading.
     * @type {number}
     */
    this.lastCheck = 0;

    /**
     * Object version corresponding to the last successful download.
     * @type {number}
     */
    this.lastVersion = 0;

    /**
     * A string indicating the version of the first ever downloaded resource,
     * in `YYYY[MM[DD]][-E]` format or just `"0"` or `"0-E"`.
     *
     * Note that unlike `{@link module:downloader.Downloadable#lastVersion}`
     * this property is related to analytics and its value is common across all
     * downloadable resources.
     *
     * If `{@link module:downloader.Downloadable#url}` is not a trusted URL,
     * the value of this property should be set to `null`.
     *
     * @see module:analytics~Analytics#getFirstVersion
     * @see module:analytics~Analytics#isTrusted
     *
     * @type {?string}
     *
     * @package
     */
    this.firstVersion = null;

    /**
     * Soft expiration time in milliseconds since the Unix epoch. This
     * will increase if no checks are performed for a while.
     *
     * Updates should be downloaded if `softExpiration` or
     * `{@link module:downloader.Downloadable#hardExpiration}` are in the past.
     * @type {number}
     */
    this.softExpiration = 0;

    /**
     * Hard expiration time in milliseconds since the Unix epoch. This
     * is fixed.
     *
     * Updates should be downloaded if
     * `{@link module:downloader.Downloadable#softExpiration}` or
     * `hardExpiration` are in the past.
     * @type {number}
     */
    this.hardExpiration = 0;

    /**
     * Number indicating how often the object was downloaded.
     * @type {number}
     */
    this.downloadCount = 0;

    /**
     * Request method to use, which is either "GET" or "HEAD".
     * @type {string}
     */
    this.method = "GET";

    /**
     * URL that has to be requested for the object.
     * @type {string}
     */
    this.url = url;
  }
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/elemHide.js":
/*!******************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/elemHide.js ***!
  \******************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_235971__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * @file Element hiding implementation.
 */

const {domainSuffixes} = __nested_webpack_require_235971__(/*! ./url */ "./node_modules/adblockpluscore/lib/url.js");
const {FiltersByDomain, FilterMap} = __nested_webpack_require_235971__(/*! ./filtersByDomain */ "./node_modules/adblockpluscore/lib/filtersByDomain.js");
const {Cache} = __nested_webpack_require_235971__(/*! ./caching */ "./node_modules/adblockpluscore/lib/caching.js");
const {ElemHideExceptions} = __nested_webpack_require_235971__(/*! ./elemHideExceptions */ "./node_modules/adblockpluscore/lib/elemHideExceptions.js");

class ElemHide {
  /**
   * @param {ElemHideExceptions} elemHideExceptions The associated element
   *   hiding exceptions.
   */
  constructor(elemHideExceptions) {
    if (!(elemHideExceptions instanceof ElemHideExceptions))
      throw new Error("elemHideExceptions must be an ElemHideExceptions");

    /** @type {ElemHideExceptions} */
    this.elemHideExceptions = elemHideExceptions;

    /**
     * Lookup table, active flag, by filter by domain.
     *
     * (Only contains filters that aren't unconditionally matched for all
     * domains.)
     *
     * @type {FiltersByDomain}
     *
     * @private
     */
    this._filtersByDomain = new FiltersByDomain();

    /**
     * Lookup table, filter by selector.
     *
     * (Only used for selectors that are unconditionally matched for all
     * domains.)
     *
     * @type {Map.<string, Filter>}
     *
     * @private
     */
    this._filterBySelector = new Map();

    /**
     * This array caches the keys of
     * `{@link module:elemHide~ElemHide#_filterBySelector _filterBySelector}`
     * (selectors which unconditionally apply on all domains).
     *
     * It will be `null` if the cache needs to be rebuilt.
     *
     * @type {?Array.<string>}
     *
     * @private
     */
    this._unconditionalSelectors = null;

    /**
     * The default style sheet that applies on all domains.
     *
     * This is based on the value of
     * `{@link module:elemHide~ElemHide#_unconditionalSelectors
     *         _unconditionalSelectors}`.
     *
     * @type {?string}
     *
     * @private
     */
    this._defaultStyleSheet = null;

    /**
     * The common style sheet that applies on all unknown domains.
     *
     * This is a concatenation of the default style sheet and an additional
     * style sheet based on selectors from all generic filters that are not in
     * the `{@link module:elemHide~ElemHide#_unconditionalSelectors
     *             _unconditionalSelectors}` list.
     *
     * @type {?string}
     *
     * @private
     */
    this._commonStyleSheet = null;

    /**
     * Cache of generated domain-specific style sheets.
     *
     * This contains entries for only known domains. If a domain is unknown, it
     * gets `{@link module:elemHide~ElemHide#_commonStyleSheet
     *              _commonStyleSheet}`.
     *
     * @type {Cache.<string, string>}
     *
     * @private
     */
    this._styleSheetCache = new Cache(100);

    /**
     * Set containing known element hiding filters
     * @type {Set.<module:filterClasses.ElemHideFilter>}
     * @private
     */
    this._filters = new Set();

    /**
     * All domains known to occur in exceptions
     * @type {Set.<string>}
     * @private
     */
    this._exceptionDomains = new Set();

    this.elemHideExceptions.on("added", this._onExceptionAdded.bind(this));
  }

  /**
   * Removes all known element hiding filters.
   */
  clear() {
    this._commonStyleSheet = null;

    for (let collection of [this._styleSheetCache, this._filtersByDomain,
                            this._filterBySelector, this._filters,
                            this._exceptionDomains])
      collection.clear();

    this._unconditionalSelectors = null;
    this._defaultStyleSheet = null;
  }

  /**
   * Add a new element hiding filter.
   * @param {module:filterClasses.ElemHideFilter} filter
   */
  add(filter) {
    if (this._filters.has(filter))
      return;

    this._styleSheetCache.clear();
    this._commonStyleSheet = null;

    let {domains, selector} = filter;

    if (!(domains || this.elemHideExceptions.hasExceptions(selector))) {
      // The new filter's selector is unconditionally applied to all domains
      this._filterBySelector.set(selector, filter);
      this._unconditionalSelectors = null;
      this._defaultStyleSheet = null;
    }
    else {
      // The new filter's selector only applies to some domains
      this._filtersByDomain.add(filter, domains);
    }

    this._filters.add(filter);
  }

  /**
   * Removes an existing element hiding filter.
   * @param {module:filterClasses.ElemHideFilter} filter
   */
  remove(filter) {
    if (!this._filters.has(filter))
      return;

    this._styleSheetCache.clear();
    this._commonStyleSheet = null;

    let {selector} = filter;

    // Unconditially applied element hiding filters
    if (this._filterBySelector.get(selector) == filter) {
      this._filterBySelector.delete(selector);
      this._unconditionalSelectors = null;
      this._defaultStyleSheet = null;
    }
    // Conditionally applied element hiding filters
    else {
      this._filtersByDomain.remove(filter);
    }

    this._filters.delete(filter);
  }

  /**
   * Checks whether an element hiding filter exists.
   * @param {module:filterClasses.ElemHideFilter} filter
   * @returns {boolean}
   */
  has(filter) {
    return this._filters.has(filter);
  }

  /**
   * @typedef {Object} ElemHideStyleSheet
   * @property {string} code CSS code.
   * @property {?Array.<string>} selectors List of selectors.
   * @property {?Array.<string>} exceptions List of exceptions.
   */

  /**
   * Returns a style sheet for a given domain based on the current set of
   * filters.
   *
   * @param {string} domain The domain.
   * @param {boolean} [specificOnly=false] Whether selectors from generic
   *   filters should be included.
   * @param {boolean} [includeSelectors=false] Whether the return value should
   *   include a separate list of selectors.
   * @param {boolean} [includeExceptions=false] Whether the return value should
   *   include a separate list of exceptions.
   *
   * @returns {module:elemHide~ElemHideStyleSheet} An object containing the CSS
   *   code and the list of selectors.
   */
  getStyleSheet(domain, specificOnly = false, includeSelectors = false,
                includeExceptions = false) {
    let code = null;
    let selectors = null;
    let exceptions = null;

    if (specificOnly) {
      if (includeExceptions) {
        let selectorsAndExceptions =
          this._getConditionalSelectorsWithExceptions(domain, true);

        selectors = selectorsAndExceptions.selectors;
        exceptions = selectorsAndExceptions.exceptions;
      }
      else {
        selectors = this._getConditionalSelectors(domain, true);
      }

      code = createStyleSheet(selectors);
    }
    else {
      let knownSuffix = this._getKnownSuffix(domain);

      if (includeSelectors || includeExceptions) {
        let selectorsAndExceptions =
          this._getConditionalSelectorsWithExceptions(knownSuffix, false);

        selectors = selectorsAndExceptions.selectors;
        exceptions = selectorsAndExceptions.exceptions;
        code = knownSuffix == "" ? this._getCommonStyleSheet() :
          this._getDefaultStyleSheet() + createStyleSheet(selectors);

        selectors = this._getUnconditionalSelectors().concat(selectors);
      }
      else {
        code = knownSuffix == "" ? this._getCommonStyleSheet() :
          this._getDefaultStyleSheet() +
                 this._getDomainSpecificStyleSheet(knownSuffix);
      }
    }

    return {
      code,
      selectors: includeSelectors ? selectors : null,
      exceptions: includeExceptions ? exceptions : null
    };
  }

  /**
   * Returns a style sheet for a given domain based on the current set of
   * filters.
   *
   * @param {string} domain The domain.
   * @param {boolean} [specificOnly=false] Whether selectors from generic
   *   filters should be included.
   * @param {boolean} [includeSelectors=false] Whether the return value should
   *   include a separate list of selectors.
   * @param {boolean} [includeExceptions=false] Whether the return value should
   *   include a separate list of exceptions.
   *
   * @returns {module:elemHide~ElemHideStyleSheet} An object containing the CSS
   *   code and the list of selectors.
   *
   * @deprecated Use
   *   <code>{@link module:elemHide~ElemHide#getStyleSheet}</code> instead.
   * @see module:elemHide~ElemHide#getStyleSheet
   */
  generateStyleSheetForDomain(domain, specificOnly = false,
                              includeSelectors = false,
                              includeExceptions = false) {
    return this.getStyleSheet(
      domain, specificOnly, includeSelectors, includeExceptions
    );
  }

  /**
   * Returns the suffix of the given domain that is known.
   *
   * If no suffix is known, an empty string is returned.
   *
   * @param {?string} domain
   *
   * @returns {string}
   *
   * @private
   */
  _getKnownSuffix(domain) {
    for (let suffix of domainSuffixes(domain)) {
      if (this._filtersByDomain.has(suffix) ||
          this._exceptionDomains.has(suffix))
        return suffix;
    }

    return "";
  }

  /**
   * Returns a list of selectors that apply on each website unconditionally.
   * @returns {string[]}
   * @private
   */
  _getUnconditionalSelectors() {
    if (!this._unconditionalSelectors)
      this._unconditionalSelectors = [...this._filterBySelector.keys()];

    return this._unconditionalSelectors;
  }

  /**
   * Returns the list of selectors that apply on a given domain from the subset
   * of filters that do not apply unconditionally on all domains.
   *
   * @param {string} domain The domain.
   * @param {boolean} specificOnly Whether selectors from generic filters should
   *   be included.
   *
   * @returns {Array.<string>} The list of selectors.
   *
   * @private
   */
  _getConditionalSelectors(domain, specificOnly) {
    let selectors = [];

    let excluded = new Set();

    for (let currentDomain of domainSuffixes(domain, !specificOnly)) {
      let map = this._filtersByDomain.get(currentDomain);
      if (map) {
        for (let [filter, include] of (map instanceof FilterMap ?
          map.entries() : [[map, true]])) {
          if (!include) {
            excluded.add(filter);
          }
          else {
            let {selector} = filter;
            if ((excluded.size == 0 || !excluded.has(filter)) &&
                !this.elemHideExceptions.getException(selector, domain))
              selectors.push(selector);
          }
        }
      }
    }

    return selectors;
  }

  /**
   * Returns the list of selectors and the list of exceptions that apply on a
   * given domain from the subset of filters that do not apply unconditionally
   * on all domains.
   *
   * @param {string} domain The domain.
   * @param {boolean} specificOnly Whether selectors from generic filters should
   *   be included.
   *
   * @returns {{selectors: Array.<string>,
   *            exceptions: Array.<module:filterClasses.ElemHideException>}}
   *   An object containing the lists of selectors and exceptions.
   *
   * @private
   */
  _getConditionalSelectorsWithExceptions(domain, specificOnly) {
    let selectors = [];
    let exceptions = [];

    let excluded = new Set();

    for (let currentDomain of domainSuffixes(domain, !specificOnly)) {
      let map = this._filtersByDomain.get(currentDomain);
      if (map) {
        for (let [filter, include] of (map instanceof FilterMap ?
          map.entries() : [[map, true]])) {
          if (!include) {
            excluded.add(filter);
          }
          else if (excluded.size == 0 || !excluded.has(filter)) {
            let {selector} = filter;
            let exception =
                this.elemHideExceptions.getException(selector, domain);

            if (exception)
              exceptions.push(exception);
            else
              selectors.push(selector);
          }
        }
      }
    }

    return {selectors, exceptions};
  }

  /**
   * Returns the default style sheet that applies on all domains.
   * @returns {string}
   * @private
   */
  _getDefaultStyleSheet() {
    if (!this._defaultStyleSheet) {
      this._defaultStyleSheet =
        createStyleSheet(this._getUnconditionalSelectors());
    }

    return this._defaultStyleSheet;
  }

  /**
   * Returns the common style sheet that applies on all unknown domains.
   * @returns {string}
   * @private
   */
  _getCommonStyleSheet() {
    if (!this._commonStyleSheet) {
      this._commonStyleSheet =
        this._getDefaultStyleSheet() +
        createStyleSheet(this._getConditionalSelectors("", false));
    }

    return this._commonStyleSheet;
  }

  /**
   * Returns the domain-specific style sheet that applies on a given domain.
   * @param {string} domain
   * @returns {string}
   * @private
   */
  _getDomainSpecificStyleSheet(domain) {
    let styleSheet = this._styleSheetCache.get(domain);

    if (typeof styleSheet == "undefined") {
      styleSheet =
        createStyleSheet(this._getConditionalSelectors(domain, false));
      this._styleSheetCache.set(domain, styleSheet);
    }

    return styleSheet;
  }

  _onExceptionAdded(exception) {
    let {domains, selector} = exception;

    this._styleSheetCache.clear();
    this._commonStyleSheet = null;

    if (domains) {
      for (let domain of domains.keys()) {
        // Note: Once an exception domain is known it never becomes unknown,
        // even when all the exceptions containing that domain are removed.
        // This is a best-case optimization.
        if (domain != "")
          this._exceptionDomains.add(domain);
      }
    }

    // If this is the first exception for a previously unconditionally applied
    // element hiding selector we need to take care to update the lookups.
    let unconditionalFilterForSelector = this._filterBySelector.get(selector);
    if (unconditionalFilterForSelector) {
      this._filtersByDomain.add(unconditionalFilterForSelector);
      this._filterBySelector.delete(selector);
      this._unconditionalSelectors = null;
      this._defaultStyleSheet = null;
    }
  }
}

/**
 * Container for element hiding filters.
 */
exports.ElemHide = ElemHide;

/**
 * Yields rules from a style sheet returned by
 * `{@link module:elemHide.createStyleSheet createStyleSheet()}`.
 *
 * @param {string} styleSheet A style sheet returned by
 *   `{@link module:elemHide.createStyleSheet createStyleSheet()}`. If the
 *   given style sheet is *not* a value previously returned by a call to
 *   `{@link module:elemHide.createStyleSheet createStyleSheet()}`, the
 *   behavior is undefined.
 *
 * @generator
 * @yields {string} A rule from the given style sheet.
 */
exports.rulesFromStyleSheet = function* rulesFromStyleSheet(styleSheet) {
  let startIndex = 0;
  while (startIndex < styleSheet.length) {
    let ruleTerminatorIndex = styleSheet.indexOf("\n", startIndex);
    yield styleSheet.substring(startIndex, ruleTerminatorIndex);
    startIndex = ruleTerminatorIndex + 1;
  }
};

/**
 * Escapes curly braces to prevent CSS rule injection.
 *
 * @param {string} selector
 *
 * @returns {string}
 */
function escapeSelector(selector) {
  return selector.replace(/[{}]/g, c => `\\${c.charCodeAt().toString(16)} `);
}

/**
 * Creates an element hiding CSS rule for a given list of selectors.
 *
 * @param {string} selector The CSS selector for the rule.
 * @param {string} [declarationBlock] Optional CSS code to use as the
 *   declaration block. By default, the code `{display: none !important;}` is
 *   used. If specified, the value is injected as-is into the rule.
 *
 * @returns {string} A CSS rule.
 */
function createRule(
  selector,
  declarationBlock = "{display: none !important;}"
) {
  return `${escapeSelector(selector)} ${declarationBlock}\n`;
}

let createStyleSheet =
/**
 * Creates an element hiding CSS style sheet from a given list of selectors.
 *
 * @param {Array.<string>} selectors The list of selectors.
 * @param {string} [declarationBlock] Optional CSS code to use as the
 *   declaration block. By default, the code `{display: none !important;}` is
 *   used. If specified, the value is injected as-is into the style sheet.
 *
 * @returns {string} A CSS style sheet.
 */
exports.createStyleSheet = function createStyleSheet(selectors,
                                                     declarationBlock) {
  let styleSheet = "";

  for (let selector of selectors)
    styleSheet += createRule(selector, declarationBlock);

  return styleSheet;
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/elemHideEmulation.js":
/*!***************************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/elemHideEmulation.js ***!
  \***************************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_253721__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



const {ElemHideExceptions} = __nested_webpack_require_253721__(/*! ./elemHideExceptions */ "./node_modules/adblockpluscore/lib/elemHideExceptions.js");

/**
 * @file Element hiding emulation implementation.
 */

class ElemHideEmulation extends Set {
  /**
   * Construct an ElemHideEmulation object
   * @param {ElemHideExceptions} elemHideExceptions The associated element
   *  hiding exceptions.
   */
  constructor(elemHideExceptions) {
    super();
    if (!(elemHideExceptions instanceof ElemHideExceptions))
      throw new Error("elemHideExceptions must be an ElemHideExceptions");

    /** @type {ElemHideExceptions} */
    this.elemHideExceptions = elemHideExceptions;
  }

  /**
   * Removes an existing element hiding emulation filter.
   * @param {module:filterClasses.ElemHideEmulationFilter} filter
   *
   * @deprecated Use
   *   <code>ElemHideEmulation#delete</code>
   *   instead.
   */
  remove(filter) {
    this.delete(filter);
  }

  /**
   * Returns a list of all element hiding emulation filters active on the given
   * domain.
   * @param {string} domain The domain.
   * @returns {Array.<module:filterClasses.ElemHideEmulationFilter>} A list of
   *   element hiding emulation filters.
   */
  getFilters(domain) {
    let result = [];

    for (let filter of this) {
      if (filter.isActiveOnDomain(domain) &&
          !this.elemHideExceptions.getException(filter.selector, domain))
        result.push(filter);
    }

    return result;
  }

  /**
   * Returns a list of all element hiding emulation filters active on the given
   * domain.
   * @param {string} domain The domain.
   * @returns {Array.<module:filterClasses.ElemHideEmulationFilter>} A list of
   *   element hiding emulation filters.
   *
   * @deprecated Use
   *   <code>{@link
   *          module:elemHideEmulation~ElemHideEmulation#getFilters}</code>
   *   instead.
   * @see module:elemHideEmulation~ElemHideEmulation#getFilters
   */
  getRulesForDomain(domain) {
    return this.getFilters(domain);
  }
}

/**
 * Container for element hiding emulation filters.
 */
exports.ElemHideEmulation = ElemHideEmulation;


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/elemHideExceptions.js":
/*!****************************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/elemHideExceptions.js ***!
  \****************************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_256915__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * @file Element hiding exceptions implementation.
 */

const {EventEmitter} = __nested_webpack_require_256915__(/*! ./events */ "./node_modules/adblockpluscore/lib/events.js");

class ElemHideExceptions extends EventEmitter {
  /**
   * @hideconstructor
   */
  constructor() {
    super();

    /**
     * Lookup table, lists of element hiding exceptions by selector
     * @type {Map.<string, Set.<module:filterClasses.ElemHideException>>}
     * @private
     */
    this._exceptionsBySelector = new Map();

    /**
     * Set containing known element hiding exceptions
     * @type {Set.<module:filterClasses.ElemHideException>}
     * @private
     */
    this._exceptions = new Set();
  }

  /**
   * Removes all known element hiding exceptions.
   */
  clear() {
    this._exceptionsBySelector.clear();
    this._exceptions.clear();
  }

  /**
   * Adds a new element hiding exception.
   * @param {module:filterClasses.ElemHideException} exception
   */
  add(exception) {
    if (this._exceptions.has(exception))
      return;

    let {selector} = exception;
    let set = this._exceptionsBySelector.get(selector);
    if (set)
      set.add(exception);
    else
      this._exceptionsBySelector.set(selector, new Set([exception]));

    this._exceptions.add(exception);

    this.emit("added", exception);
  }

  /**
   * Removes an existing element hiding exception.
   * @param {module:filterClasses.ElemHideException} exception
   */
  remove(exception) {
    if (!this._exceptions.has(exception))
      return;

    let {selector} = exception;
    let set = this._exceptionsBySelector.get(selector);
    set.delete(exception);
    if (set.size == 0)
      this._exceptionsBySelector.delete(selector);

    this._exceptions.delete(exception);

    this.emit("removed", exception);
  }

  /**
   * Checks whether an element hiding exception exists.
   * @param {module:filterClasses.ElemHideException} exception
   * @returns {boolean}
   */
  has(exception) {
    return this._exceptions.has(exception);
  }

  /**
   * Checks whether any exception rules are registered for a selector.
   * @param {string} selector
   * @returns {boolean}
   */
  hasExceptions(selector) {
    return this._exceptionsBySelector.has(selector);
  }

  /**
   * Checks whether an exception rule is registered for a selector on a
   * particular domain.
   * @param {string} selector
   * @param {?string} [domain]
   * @returns {?module:filterClasses.ElemHideException}
   */
  getException(selector, domain) {
    let exceptions = this._exceptionsBySelector.get(selector);
    if (exceptions) {
      for (let exception of exceptions) {
        if (exception.isActiveOnDomain(domain))
          return exception;
      }
    }

    return null;
  }
}

/**
 * Container for element hiding exceptions.
 */
exports.ElemHideExceptions = ElemHideExceptions;


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/events.js":
/*!****************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/events.js ***!
  \****************************************************/
/***/ ((__unused_webpack_module, exports) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * Registers and emits named events.
 */
exports.EventEmitter = class EventEmitter {
  constructor() {
    this._listeners = new Map();
  }

  /**
   * Adds a listener for the specified event name.
   *
   * @param {string}   name
   * @param {function} listener
   */
  on(name, listener) {
    let listeners = this._listeners.get(name);
    if (listeners)
      listeners.push(listener);
    else
      this._listeners.set(name, [listener]);
  }

  /**
   * Removes a listener for the specified event name.
   *
   * @param {string}   name
   * @param {function} listener
   */
  off(name, listener) {
    let listeners = this._listeners.get(name);
    if (listeners) {
      if (listeners.length > 1) {
        let idx = listeners.indexOf(listener);
        if (idx != -1)
          listeners.splice(idx, 1);
      }
      else if (listeners[0] === listener) {
        // We must use strict equality above for compatibility with
        // Array.prototype.indexOf
        this._listeners.delete(name);
      }
    }
  }

  /**
   * Returns a copy of the array of listeners for the specified event.
   *
   * @param {string} name
   *
   * @returns {Array.<function>}
   */
  listeners(name) {
    let listeners = this._listeners.size > 0 ? this._listeners.get(name) : null;
    return listeners ? listeners.slice() : [];
  }

  /**
   * Checks whether there are any listeners for the specified event.
   *
   * @param {string} [name] The name of the event. If omitted, checks whether
   *   there are any listeners for any event.
   *
   * @returns {boolean}
   */
  hasListeners(name) {
    return this._listeners.size > 0 &&
           (typeof name == "undefined" || this._listeners.has(name));
  }

  /**
   * Calls all previously added listeners for the given event name.
   *
   * @param {string} name
   * @param {...*}   [args]
   */
  emit(name, ...args) {
    let listeners = this._listeners.size > 0 ? this._listeners.get(name) : null;
    if (listeners) {
      for (let listener of listeners.slice())
        listener(...args);
    }
  }
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/features.js":
/*!******************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/features.js ***!
  \******************************************************/
/***/ ((__unused_webpack_module, exports) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * Feature flags for the filterEngine.
 *
 * @type {Object}
 *
 * @public
 */
exports.Features = {
  // Default features: Manifest v2.
  DEFAULT: 0,
  // We have DeclarativeNetRequest
  DNR: 1
};



/***/ }),

/***/ "./node_modules/adblockpluscore/lib/filterClasses.js":
/*!***********************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/filterClasses.js ***!
  \***********************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_265124__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * @file Definition of Filter class and its subclasses.
 */

const {
  contentTypes, RESOURCE_TYPES, CONTEXT_TYPES
} = __nested_webpack_require_265124__(/*! ./contentTypes */ "./node_modules/adblockpluscore/lib/contentTypes.js");
const {CONTENT_FILTER} = __nested_webpack_require_265124__(/*! ./filters */ "./node_modules/adblockpluscore/lib/filters/index.js");
const {Pattern} = __nested_webpack_require_265124__(/*! ./patterns */ "./node_modules/adblockpluscore/lib/patterns.js");
const {parseDomains, domainSuffixes} = __nested_webpack_require_265124__(/*! ./url */ "./node_modules/adblockpluscore/lib/url.js");
const {parse, FilterParsingError} = __nested_webpack_require_265124__(/*! ./filters */ "./node_modules/adblockpluscore/lib/filters/index.js");

const {resources} = __nested_webpack_require_265124__(/*! ../data/resources.js */ "./node_modules/adblockpluscore/data/resources.js");

const MIN_GENERIC_CONTENT_FILTER_BODY_LENGTH = 3;

/** The filter state
 * @type {module:filterState.FilterState}
 */
let filterState = null;

/**
 * @typedef {Object} HttpHeader
 * @property {string} name
 * @property {?string} value
 */

/**
 * Map of internal resources for URL rewriting.
 * @type {Map.<string,string>}
 */
let resourceMap = new Map(
  Object.keys(resources).map(key => [key, resources[key]])
);

let isActiveFilter =
/**
 * Checks whether the given filter is an active filter.
 *
 * Filters of type `blocking`, `allowing`, `elemhide`, `elemhideexception`,
 * `elemhideemulation`, and `snippet` are considered active; filters of type
 * `invalid` and `comment` are not considered active.
 *
 * @param {?Filter} filter The filter.
 *
 * @returns {boolean} Whether the filter is active.
 */
exports.isActiveFilter = function isActiveFilter(filter) {
  return filter instanceof ActiveFilter;
};

let Filter =
/**
 * Abstract base class for filters
 */
exports.Filter = class Filter {
  /**
   * @param {string} text   string representation of the filter
   */
  constructor(text) {
    this.text = text;
  }

  static useFilterState(reference) {
    filterState = reference;
  }

  /**
   * Filter type as a string, e.g. "blocking".
   *
   * Can be `blocking`, `allowing`, `elemhide`, `elemhideexception`,
   * `elemhideemulation`, `snippet`, `comment` or `invalid`.
   *
   * @type {string}
   */
  get type() {
    throw new Error("Please define filter type in the subclass");
  }

  /**
   * True if filter should only be loaded if it comes from a
   * privileged subscription (circumvention subscriptions or special
   * subscriptions).
   * @type {bool}
   */
  get requiresPrivilegedSubscription() {
    return false;
  }

  /**
   * Serializes the filter for writing out on disk.
   * @yields {string}
   */
  *serialize() {
    let {text} = this;

    yield "[Filter]";
    yield "text=" + text;
  }

  toString() {
    return this.text;
  }
};

/**
 * Cache for known filters, maps string representation to filter objects.
 * @type {Map.<string, module:filterClasses.Filter>}
 */
let knownFilters = new Map();

/**
 * Creates a filter of correct type from its text representation - does the
 * basic parsing and calls the right constructor then.
 *
 * @param {string} text   as in Filter()\
 * @return {module:filterClasses.Filter}
 */
exports.Filter.fromText = function(text) {
  let filter = knownFilters.get(text);
  if (filter)
    return filter;

  if (text.length === 0) {
    filter = new InvalidFilter(text, "filter_empty");
  }
  else if (text[0] == "!") {
    filter = new CommentFilter(text);
  }
  else {
    let match = text.includes("#") ? CONTENT_FILTER.exec(text) : null;
    if (match)
      filter = ContentFilter.fromText(text, match[1], match[2], match[3]);
    else
      filter = URLFilter.fromText(text);
  }

  if (filter.type !== "invalid")
    knownFilters.set(filter.text, filter);

  return filter;
};

/**
 * Deserializes a filter
 *
 * @param {Object}  obj map of serialized properties and their values
 * @return {module:filterClasses.Filter} filter or null if the filter couldn't
 *   be created
 */
exports.Filter.fromObject = function(obj) {
  let filter = Filter.fromText(obj.text);
  if (isActiveFilter(filter) && filterState)
    filterState.fromObject(filter.text, obj);
  return filter;
};

let {normalize} = __nested_webpack_require_265124__(/*! ./filters/index.js */ "./node_modules/adblockpluscore/lib/filters/index.js");
exports.Filter.normalize = normalize;

let InvalidFilter =
/**
 * Class for invalid filters
 * @extends module:filterClasses.Filter
 */
exports.InvalidFilter = class InvalidFilter extends Filter {
  /**
   * @param {string} text see {@link module:filterClasses.Filter Filter()}
   * @param {string} reason Reason why this filter is invalid
   * @param {string?} option The optional option passed to the filter
   * @private
   */
  constructor(text, reason, option = null) {
    super(text);

    this.reason = reason;
    this.option = option;
  }

  get type() {
    return "invalid";
  }

  *serialize() {}
};

let CommentFilter =
/**
 * Class for comments
 * @extends module:filterClasses.Filter
 */
exports.CommentFilter = class CommentFilter extends Filter {
  /**
   * @param {string} text see {@link module:filterClasses.Filter Filter()}
   * @private
   */
  constructor(text) {
    super(text);
  }

  get type() {
    return "comment";
  }

  *serialize() {}
};

let ActiveFilter =
/**
 * Abstract base class for filters that can get hits
 * @extends module:filterClasses.Filter
 */
exports.ActiveFilter = class ActiveFilter extends Filter {
  /**
   * @param {string} text
   *   see {@link module:filterClasses.Filter Filter()}
   * @param {string} [domains]
   *   Domains that the filter is restricted to separated by domainSeparator
   *   e.g. "foo.com|bar.com|~baz.com"
   * @private
   */
  constructor(text, domains) {
    super(text);

    /**
     * String that the domains property should be generated from
     * @type {?string}
     */
    this.domainSource = domains || null;

    this._domains = domains ? void 0 : null;
  }

  /**
   * Number of filters contained, will always be 1 (required to
   * optimize {@link module:matcher.Matcher Matcher}).
   * @type {number}
   */
  get size() {
    return 1;
  }

  /**
   * See Filter.serialize()
   * @inheritdoc
   */
  *serialize() {
    if (filterState)
      yield* filterState.serialize(this.text);
  }

  /**
   * Defines whether the filter is disabled globally.
   * @type {boolean}
   * @deprecated use
   * {@link module:filterClasses.ActiveFilter#isDisabledForSubscription} and
   * {@link module:filterClasses.ActiveFilter#setDisabledForSubscription} for
   * disabling and enabling filters for specific subscriptions.
   */
  get disabled() {
    return filterState && !filterState.isEnabled(this.text);
  }
  set disabled(value) {
    if (filterState)
      filterState.setEnabled(this.text, !value);
  }

  /**
   * Defines which subscriptions the filter is disabled for.
   * See {@link module:filterClasses.ActiveFilter#isDisabledForSubscription} and
   * {@link module:filterClasses.ActiveFilter#setDisabledForSubscription} for
   * disabling and enabling filters.
   * @type {Set<string>}
   */
  get disabledSubscriptions() {
    if (!filterState)
      return new Set();
    return filterState.disabledSubscriptions(this.text);
  }

  /**
   * Checks whether this filter is disabled.
   * @param {string} subscriptionUrl The subscription to check for
   * enabled / disabled state.
   * @return {boolean} true if the filter is disabled
   */
  isDisabledForSubscription(subscriptionUrl) {
    return filterState &&
      filterState.isDisabledForSubscription(this.text, subscriptionUrl);
  }
  /**
   * Disables or enables the filter.
   * @param {string} [subscriptionUrl] The subscription on which to
   * disable / enable the filter.
   * @param {boolean} [value] new disabled value, true for disabled
   * and false for enabled
   */
  setDisabledForSubscription(subscriptionUrl, value) {
    if (filterState)
      filterState.setDisabledForSubscription(this.text, subscriptionUrl, value);
  }

  /**
   * Separator character used in domainSource property
   * @type {string}
   */
  get domainSeparator() {
    return ",";
  }

  /**
   * Number of hits on the filter since the last reset
   * @type {number}
   */
  get hitCount() {
    return filterState ? filterState.getHitCount(this.text) : 0;
  }
  set hitCount(value) {
    if (filterState)
      filterState.setHitCount(this.text, value);
  }

  /**
   * Last time the filter had a hit (in milliseconds since the beginning of the
   * epoch)
   * @type {number}
   */
  get lastHit() {
    return filterState ? filterState.getLastHit(this.text) : 0;
  }
  set lastHit(value) {
    if (filterState)
      filterState.setLastHit(this.text, value);
  }

  /**
   * Map containing domains that this filter should match on/not match
   * on or null if the filter should match on all domains
   * @type {?Map.<string,boolean>}
   */
  get domains() {
    if (typeof this._domains == "undefined") {
      let {domainSource: source, domainSeparator: sep} = this;
      this._domains = parseDomains(source.toLowerCase(), sep);
    }
    return this._domains;
  }

  /**
   * Array containing public keys of websites that this filter should apply to
   * @type {?Array.<string>}
   */
  get sitekeys() {
    return null;
  }

  /**
   * String that the sitekey property should be generated from
   * @type {?string}
   */
  get sitekeySource() {
    return null;
  }

  /**
   * Checks whether this filter is active on a domain.
   * @param {?string} [docDomain] domain name of the document that loads the URL
   * @param {string} [sitekey] public key provided by the document
   * @return {boolean} true in case of the filter being active
   */
  isActiveOnDomain(docDomain, sitekey) {
    // Sitekeys are case-sensitive so we shouldn't convert them to
    // upper-case to avoid false positives here. Instead we need to
    // change the way filter options are parsed.
    if (this.sitekeys &&
        (!sitekey || !this.sitekeys.includes(sitekey)))
      return false;

    let {domains} = this;

    // If no domains are set the rule matches everywhere
    if (!domains)
      return true;

    if (docDomain == null)
      docDomain = "";
    else if (docDomain[docDomain.length - 1] == ".")
      docDomain = docDomain.substring(0, docDomain.length - 1);

    // If the document has no host name, match only if the filter
    // isn't restricted to specific domains
    if (!docDomain)
      return domains.get("");

    for (docDomain of domainSuffixes(docDomain)) {
      let isDomainIncluded = domains.get(docDomain);
      if (typeof isDomainIncluded != "undefined")
        return isDomainIncluded;
    }

    return domains.get("");
  }

  /**
   * Checks whether this filter is active only on a domain and its subdomains.
   * @param {?string} [docDomain]
   * @return {boolean}
   */
  isActiveOnlyOnDomain(docDomain) {
    let {domains} = this;

    if (!domains || domains.get(""))
      return false;

    if (docDomain == null)
      docDomain = "";
    else if (docDomain[docDomain.length - 1] == ".")
      docDomain = docDomain.substring(0, docDomain.length - 1);

    if (!docDomain)
      return false;

    for (let [domain, isIncluded] of domains) {
      if (isIncluded && domain != docDomain) {
        if (domain.length <= docDomain.length)
          return false;

        if (!domain.endsWith("." + docDomain))
          return false;
      }
    }

    return true;
  }

  /**
   * Checks whether this filter is generic or specific
   * @return {boolean}
   */
  isGeneric() {
    let {sitekeys, domains} = this;

    return !(sitekeys && sitekeys.length) && (!domains || domains.get(""));
  }

  /**
   * Yields the filter itself (required to optimize
   *   {@link module:matcher.Matcher Matcher}).
   * @yields {module:filterClasses.ActiveFilter}
   * @package
   */
  *[Symbol.iterator]() {
    yield this;
  }
};

let URLFilter =
/**
 * Abstract base class for URL filters
 * @extends module:filterClasses.ActiveFilter
 */
exports.URLFilter = class URLFilter extends ActiveFilter {
  /**
   * @param {string} text see {@link module:filterClasses.Filter Filter()}
   * @param {string} regexpSource
   *   filter part that the regular expression should be build from
   * @param {number} [contentType]
   *   Content types the filter applies to, combination of values from
   *   `{@link module:contentTypes.contentTypes}`
   * @param {boolean} [matchCase]
   *   Defines whether the filter should distinguish between lower and upper
   *   case letters
   * @param {string} [domains]
   *   Domains that the filter is restricted to, e.g. "foo.com|bar.com|~baz.com"
   * @param {boolean} [thirdParty]
   *   Defines whether the filter should apply to third-party or first-party
   *   content only
   * @param {string} [sitekeys]
   *   Public keys of websites that this filter should apply to
   * @param {?HttpHeader} [header]
   *   Header-based filtering.
   * @param {?string} [rewrite]
   *   The name of the internal resource to which to rewrite the
   *   URL. e.g. if the value of the `$rewrite` option is
   *   `abp-resource:blank-html`, this should be `blank-html`.
   *
   * @private
   */
  constructor(text, regexpSource, contentType, matchCase, domains, thirdParty,
              sitekeys, header, rewrite) {
    super(text, domains);

    this._sitekeySource = sitekeys == null ? null : sitekeys;
    this._sitekeys = sitekeys == null ? null : void 0;

    /**
     * Content types the filter applies to, combination of values from
     * `{@link module:contentTypes.contentTypes}`
     * @type {number}
     */
    this.contentType = contentType != null ? contentType : RESOURCE_TYPES;

    /**
     * Defines whether the filter should apply to third-party or
     * first-party content only. Can be null (apply to all content).
     * @type {?boolean}
     */
    this.thirdParty = thirdParty != null ? thirdParty : null;

    /**
     * Header-based filtering expression. Refer to the filter
     * documentation reference for the syntax, or
     * `{@link BlockingFilter.filterHeaders}` for the reference
     * implementation.
     * @type {?HttpHeader}
     */
    this.header = header != null ? header : null;

    /**
     * The name of the internal resource to which to rewrite the
     * URL. e.g. if the value of the `$rewrite` option is
     * `abp-resource:blank-html`, this should be `blank-html`.
     * @type {?string}
     */
    this.rewrite = rewrite != null ? rewrite : null;

    /**
     * Pattern for matching request URLs
     * @type {Pattern}
     */
    this.urlPattern = new Pattern(regexpSource, matchCase);
  }

  /**
   * Expression from which a regular expression should be generated -
   * for delayed creation of the regexp property.
   *
   * Undefined if the filter uses a regex literal pattern.
   * @type {?string}
   * @deprecated Use <code>filter.urlPattern.pattern</code>, or other
   * functions available on <code>{@link module:patterns.Pattern}</code>.
   */
  get pattern() {
    return this.urlPattern.pattern;
  }

  /**
   * Regular expression to be used when testing against this pattern
   * @type {RegExp}
   * @deprecated Use <code>filter.urlPattern.regexp</code>, or other
   * functions available on <code>{@link module:patterns.Pattern}</code>.
   */
  get regexp() {
    return this.urlPattern.regexp;
  }

  /**
   * Defines whether the filter should distinguish between lower and
   * upper case letters
   * @type {boolean}
   */
  get matchCase() {
    return this.urlPattern.matchCase;
  }

  /**
   * @see ActiveFilter.domainSeparator
   */
  get domainSeparator() {
    return "|";
  }

  /**
   * @see ActiveFilter.sitekeys
   */
  get sitekeys() {
    if (typeof this._sitekeys == "undefined")
      this._sitekeys = this._sitekeySource.split("|");

    return this._sitekeys;
  }

  /**
   * @see ActiveFilter.sitekeySource
   */
  get sitekeySource() {
    return this._sitekeySource;
  }

  /**
   * Tests whether the URL request matches this filter
   * @param {module:url.URLRequest} request URL request to be tested
   * @param {number} typeMask bitmask of content / request types to match
   * @param {?string} [sitekey] public key provided by the document
   * @return {boolean} true in case of a match
   */
  matches(request, typeMask, sitekey) {
    let contextMask = typeMask & CONTEXT_TYPES;
    let resourceMask = typeMask & ~CONTEXT_TYPES;
    return (this.contentType & resourceMask) != 0 &&
      (contextMask == 0 ?
       (this.contentType & CONTEXT_TYPES) == 0 :
       (this.contentType & contextMask) != 0
      ) &&
      (this.thirdParty == null || this.thirdParty == request.thirdParty) &&
      (this.urlPattern.regexp ?
       this.isActiveOnDomain(request.documentHostname, sitekey) &&
       this.urlPattern.matchesLocation(request) :
       this.urlPattern.matchesLocation(request) &&
       this.isActiveOnDomain(request.documentHostname, sitekey));
  }
};

/**
 * Creates a URL filter from its text representation
 *
 * @param {string} filterText   same as in Filter()
 * @return {module:filterClasses.Filter}
 */
exports.URLFilter.fromText = function(filterText) {
  let result = parse(filterText);

  if (result instanceof FilterParsingError) {
    let option = null;
    if (result.message == "filter_unknown_option" && result.detail)
      option = result.detail.option;
    return new InvalidFilter(filterText, result.message, option);
  }

  let {
    blocking,
    text,
    regexpSource,
    contentType,
    matchCase,
    domains,
    thirdParty,
    sitekeys,
    header,
    rewrite,
    csp
  } = result;

  try {
    if (blocking) {
      return new BlockingFilter(
        text,
        regexpSource,
        contentType,
        matchCase,
        domains,
        thirdParty,
        sitekeys,
        header,
        rewrite,
        csp
      );
    }
    return new AllowingFilter(
      text,
      regexpSource,
      contentType,
      matchCase,
      domains,
      thirdParty,
      sitekeys,
      header
    );
  }
  catch (e) {
    return new InvalidFilter(filterText, "filter_invalid_regexp");
  }
};

/**
 * @deprecated Use <code>{@link contentTypes}</code> instead.
 * @see contentTypes
 */
// For backwards compatibility.
URLFilter.typeMap = contentTypes;

let BlockingFilter =
/**
 * Class for blocking filters
 * @extends module:filterClasses.URLFilter
 */
exports.BlockingFilter = class BlockingFilter extends URLFilter {
  /**
   * @param {string} text see {@link module:filterClasses.Filter Filter()}
   * @param {string} regexpSource see
   *   {@link module:filterClasses.URLFilter URLFilter()}
   * @param {number} [contentType] see
   *   {@link module:filterClasses.URLFilter URLFilter()}
   * @param {boolean} [matchCase] see
   *   {@link module:filterClasses.URLFilter URLFilter()}
   * @param {string} [domains] see
   *   {@link module:filterClasses.URLFilter URLFilter()}
   * @param {boolean} [thirdParty] see
   *   {@link module:filterClasses.URLFilter URLFilter()}
   * @param {string} [sitekeys] see
   *   {@link module:filterClasses.URLFilter URLFilter()}
   * @param {?HttpHeader} [header] see
   *   {@link module:filterClasses.URLFilter URLFilter()}
   * @param {?string} [rewrite]
   *   The name of the internal resource to which to rewrite the
   *   URL. e.g. if the value of the `$rewrite` option is
   *   `abp-resource:blank-html`, this should be `blank-html`.
   * @param {?string} [csp]
   *   Content Security Policy to inject when the filter matches
   *
   * @private
   */
  constructor(text, regexpSource, contentType, matchCase, domains, thirdParty,
              sitekeys, header, rewrite, csp) {
    super(
      text,
      regexpSource,
      contentType,
      matchCase,
      domains,
      thirdParty,
      sitekeys,
      header,
      rewrite
    );

    /**
     * Content Security Policy to inject for matching requests.
     * @type {?string}
     */
    this.csp = csp != null ? csp : null;
  }

  get type() {
    return "blocking";
  }

  get requiresPrivilegedSubscription() {
    return (this.contentType & contentTypes.HEADER) != 0;
  }

  /**
   * Rewrites an URL.
   * @param {string} url the URL to rewrite
   * @return {string} the rewritten URL, or the original in case of failure
   */
  rewriteUrl(url) {
    return resourceMap.get(this.rewrite) || url;
  }

  /**
   * Filter headers.
   *
   * This function would be called by the request blocker code after
   * matching the request.
   *
   * @param {webRequest.HttpHeaders} headers the HTTP response headers
   *   to match, as they are returned by the request blocker. They
   *   follow the {@link webRequest API
   *   https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/webRequest/HttpHeaders}.
   * @return {boolean} Whether the headers match. Will return true if
   *   there is nothing to match against, or if the header is present
   *   but no value.
   */
  filterHeaders(headers) {
    if (!this.header)
      return true;

    for (let header of headers) {
      if (header.name.toLowerCase() == this.header.name) {
        if (this.header.value) {
          if (header.value.includes(this.header.value))
            return true;
        }
        else {
          return true;
        }
      }
    }

    return false;
  }
};

let AllowingFilter =
/**
 * Class for allowing (allowlisting) filters
 * @extends module:filterClasses.URLFilter
 */
exports.AllowingFilter = class AllowingFilter extends URLFilter {
  get type() {
    return "allowing";
  }
};

let ContentFilter =
/**
 * Base class for content filters
 * @extends module:filterClasses.ActiveFilter
 */
exports.ContentFilter = class ContentFilter extends ActiveFilter {
  /**
   * @param {string} text see {@link module:filterClasses.Filter Filter()}
   * @param {string} [domains] Host names or domains the filter should be
   *                           restricted to
   * @param {string} body      The body of the filter or the script that should
   *                           be executed or the CSS selector for the HTML
   *                           elements that should be hidden
   *
   * @private
   */
  constructor(text, domains, body) {
    super(text, domains || null);

    this.body = body;
  }
};

/**
 * Creates a content filter from a pre-parsed text representation
 *
 * @param {string} text         same as in Filter()
 * @param {string} [domains]
 *   domains part of the text representation
 * @param {string} [type]
 *   rule type, either:
 *     * "" for an element hiding filter
 *     * "@" for an element hiding exception filter
 *     * "?" for an element hiding emulation filter
 *     * "$" for a snippet filter
 * @param {string} body
 *   body part of the text representation, either a CSS selector or a snippet
 *   script
 * @return {module:filterClasses.ElemHideFilter|
 *          module:filterClasses.ElemHideException|
 *          module:filterClasses.ElemHideEmulationFilter|
 *          module:filterClasses.SnippetFilter|
 *          module:filterClasses.InvalidFilter}
 */
exports.ContentFilter.fromText = function(text, domains, type, body) {
  // We don't allow content filters which have any empty domains.
  // Note: The ContentFilter.prototype.domainSeparator is duplicated here, if
  // that changes this must be changed too.
  if (domains && /(^|,)~?(,|$)/.test(domains))
    return new InvalidFilter(text, "filter_invalid_domain");

  let restrictedByDomain = /,[^~][^,.]*\.[^,]/.test("," + domains) ||
      ("," + domains + ",").includes(",localhost,");

  if (type == "?" || type == "$") {
    // Element hiding emulation and snippet filters are inefficient so we need
    // to make sure that they're only applied if they specify active domains
    if (!restrictedByDomain) {
      return new InvalidFilter(text, type == "?" ?
        "filter_elemhideemulation_nodomain" :
        "filter_snippet_nodomain");
    }

    if (type == "?")
      return new ElemHideEmulationFilter(text, domains, body);

    return new SnippetFilter(text, domains, body);
  }

  if (!restrictedByDomain &&
      body.length < MIN_GENERIC_CONTENT_FILTER_BODY_LENGTH)
    return new InvalidFilter(text, "filter_elemhide_not_specific_enough");

  if (type == "@")
    return new ElemHideException(text, domains, body);

  return new ElemHideFilter(text, domains, body);
};

let ElemHideBase =
/**
 * Base class for element hiding filters
 * @extends module:filterClasses.ContentFilter
 */
exports.ElemHideBase = class ElemHideBase extends ContentFilter {
  /**
   * CSS selector for the HTML elements that should be hidden
   * @type {string}
   */
  get selector() {
    return this.body;
  }
};

let ElemHideFilter =
/**
 * Class for element hiding filters
 * @extends module:filterClasses.ElemHideBase
 */
exports.ElemHideFilter = class ElemHideFilter extends ElemHideBase {
  /**
   * @param {string} text see {@link module:filterClasses.Filter Filter()}
   * @param {string} [domains]  see
   *   {@link module:filterClasses.ElemHideBase ElemHideBase()}
   * @param {string} selector see
   *   {@link module:filterClasses.ElemHideBase ElemHideBase()}
   *
   * @private
   */
  constructor(text, domains, selector) {
    super(text, domains, selector);
  }

  get type() {
    return "elemhide";
  }
};

let ElemHideException =
/**
 * Class for element hiding exceptions
 * @extends module:filterClasses.ElemHideBase
 */
exports.ElemHideException = class ElemHideException extends ElemHideBase {
  /**
   * @param {string} text see {@link module:filterClasses.Filter Filter()}
   * @param {string} [domains]  see
   *   {@link module:filterClasses.ElemHideBase ElemHideBase()}
   * @param {string} selector see
   *   {@link module:filterClasses.ElemHideBase ElemHideBase()}
   *
   * @private
   */
  constructor(text, domains, selector) {
    super(text, domains, selector);
  }

  get type() {
    return "elemhideexception";
  }
};

let ElemHideEmulationFilter =
/**
 * Class for element hiding emulation filters
 */
exports.ElemHideEmulationFilter =
class ElemHideEmulationFilter extends ElemHideBase {
  /**
   * @param {string} text    see {@link module:filterClasses.Filter Filter()}
   * @param {string} domains see
   *   {@link module:filterClasses.ElemHideBase ElemHideBase()}
   * @param {string} selector see
   *   {@link module:filterClasses.ElemHideBase ElemHideBase()}
   * @constructor
   * @extends module:filterClasses.ElemHideBase
   *
   * @private
   */
  constructor(text, domains, selector) {
    super(text, domains, selector);
  }

  get type() {
    return "elemhideemulation";
  }
};

let SnippetFilter =
/**
 * Class for snippet filters
 * @extends module:filterClasses.ContentFilter
 */
exports.SnippetFilter = class SnippetFilter extends ContentFilter {
  get type() {
    return "snippet";
  }
  get requiresPrivilegedSubscription() {
    return true;
  }

  /**
   * Script that should be executed
   * @type {string}
   */
  get script() {
    return this.body;
  }
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/filterEngine.js":
/*!**********************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/filterEngine.js ***!
  \**********************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_293173__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



__nested_webpack_require_293173__(/*! ./polyfill */ "./node_modules/adblockpluscore/lib/polyfill.js");
const {parseURL} = __nested_webpack_require_293173__(/*! ./url */ "./node_modules/adblockpluscore/lib/url.js");
const {Filter} = __nested_webpack_require_293173__(/*! ./filterClasses */ "./node_modules/adblockpluscore/lib/filterClasses.js");
const {newDefaultMatcher} = __nested_webpack_require_293173__(/*! ./matcher */ "./node_modules/adblockpluscore/lib/matcher.js");
const {ElemHide} = __nested_webpack_require_293173__(/*! ./elemHide */ "./node_modules/adblockpluscore/lib/elemHide.js");
const {ElemHideEmulation} = __nested_webpack_require_293173__(/*! ./elemHideEmulation */ "./node_modules/adblockpluscore/lib/elemHideEmulation.js");
const {ElemHideExceptions} = __nested_webpack_require_293173__(/*! ./elemHideExceptions */ "./node_modules/adblockpluscore/lib/elemHideExceptions.js");
const {setRecommendations} = __nested_webpack_require_293173__(/*! ./recommendations */ "./node_modules/adblockpluscore/lib/recommendations.js");
const {Snippets} = __nested_webpack_require_293173__(/*! ./snippets */ "./node_modules/adblockpluscore/lib/snippets.js");
const {profiler} = __nested_webpack_require_293173__(/*! ./profiler */ "./node_modules/adblockpluscore/lib/profiler.js");
const {Features} = __nested_webpack_require_293173__(/*! ./features */ "./node_modules/adblockpluscore/lib/features.js");

/**
 * Filter engine.
 */
class FilterEngine {
  /**
   * @typedef FilterEngineOptions
   * @type {object}
   * @property {?Array.<object>} recommendations The index of known downloadable
   *   subscriptions.
   * @property {?module:features.Features} features Enable specific features
   */
  /**
   * Creates a `{@link module:filterEngine.FilterEngine FilterEngine}`
   * object.
   *
   * @param {?FilterEngineOptions} options The options to create the engine.
   */
  constructor(options) {
    this.p = profiler("FilterEngine");

    this.p.start();

    /** Activated features
     * @type {Features}
     */
    this.features = options ? options.features : Features.DEFAULT;

    if (options && options.recommendations)
      setRecommendations(options.recommendations);

    /** The `{@link module:elemHideExceptions.ElemHideExceptions}` for
     *    the engine.
     * @type {module:elemHideExceptions.ElemHideExceptions}
     */
    this.elemHideExceptions = new ElemHideExceptions();
    /** The `{@link module:elemHide.ElemHide}` for the engine.
     * @type {module:elemHide.ElemHide}
     */
    this.elemHide = new ElemHide(this.elemHideExceptions);
    /** The `{@link module:elemHideEmulation.ElemHideEmulation}` for
     *    the engine.
     * @type {module:elemHideEmulation.ElemHideEmulation}
     */
    this.elemHideEmulation = new ElemHideEmulation(this.elemHideExceptions);
    /** The `{@link module:snippets.Snippets}` for the engine.
     * @type {module:snippets.Snippets}
     */
    this.snippets = new Snippets();
    /** The `{@link module:matcher.CombinedMatcher}` to use with the engine.
     * @type {module:matcher.CombinedMatcher}
     */
    this.defaultMatcher = newDefaultMatcher();

    /** The `{@link module:filterListener.FilterListener}` to use.
     * @type {?module:filterListener.FilterListener}
     */
    this._filterListener = null;
    /** The `{@link module:filterStorage.FilterStorage}` to use.
     * @type {?module:filterStorage.FilterStorage}
     */
    this._filterStorage = null;

    /**
     * The promise returned by
     * `{@link module:filterEngine.FilterEngine#initialize}`.
     * @type {?Promise}
     * @private
     */
    this._initializationPromise = null;
  }

  /**
   * Initializes a `{@link module:filterEngine.FilterEngine FilterEngine}`
   * object with the given filters or filters loaded from disk.
   *
   * @param {Iterable.<string>} [filterSource] An iterable object that yields
   *   the text of the filters with which to initialize the
   *   `{@link module:filterEngine.FilterEngine FilterEngine}` object. If
   *   omitted, filters are loaded from disk.
   *
   * @returns {Promise} A promise that is fulfilled when the initialization is
   *   complete.
   *
   * @public
   */
  initialize(filterSource) {
    this.p.mark("initialize");
    if (!this._initializationPromise) {
      if (typeof filterSource == "undefined") {
        // Note: filterListener.js and filterStorage.js must be loaded
        // conditionally here in local scope in order for the engine
        // to be able to work in standalone mode with no disk and
        // network I/O.
        const {FilterStorage} = __nested_webpack_require_293173__(/*! ./filterStorage */ "./node_modules/adblockpluscore/lib/filterStorage.js");
        const {FilterListener} = __nested_webpack_require_293173__(/*! ./filterListener */ "./node_modules/adblockpluscore/lib/filterListener.js");
        this._filterStorage = new FilterStorage({features: this.features});
        this._filterListener = new FilterListener();
        this._initializationPromise = this._filterListener.initialize(
          this, this._filterStorage
        );
      }
      else {
        this._initializationPromise = Promise.resolve().then(() => {
          for (let text of filterSource) {
            text = Filter.normalize(text, true);
            if (text) {
              let filter = Filter.fromText(text);
              if (filter.type !== "invalid")
                this.add(filter);
            }
          }
        }).finally(() => {
          this.p.mark("download_done");
        });
      }
    }

    return this._initializationPromise;
  }

  get filterStorage() {
    return this._filterStorage;
  }

  /**
   * Selects the appropriate module for the given filter type.
   *
   * @param {string} type The type of a filter. This must be one of
   *   `"blocking"`, `"allowing"`, `"elemhide"`, `"elemhideemulation"`,
   *   `"elemhideexception"`, and `"snippet"`; otherwise the function returns
   *   `null`.
   *
   * @returns {?object} The appropriate module for the given filter type.
   */
  selectModule(type) {
    switch (type) {
      case "blocking":
      case "allowing":
        return this.defaultMatcher;
      case "elemhide":
        return this.elemHide;
      case "elemhideemulation":
        return this.elemHideEmulation;
      case "elemhideexception":
        return this.elemHideExceptions;
      case "snippet":
        return this.snippets;
    }

    return null;
  }

  /**
   * Adds a new filter.
   * @param {module:filterClasses.ActiveFilter} filter
   * @package
   */
  add(filter) {
    let module = this.selectModule(filter.type);
    if (module)
      module.add(filter);
  }

  /**
   * Removes an existing filter.
   * @param {module:filterClasses.ActiveFilter} filter
   * @package
   */
  remove(filter) {
    let module = this.selectModule(filter.type);
    if (module)
      module.remove(filter);
  }

  /**
   * Checks whether a filter exists.
   * @param {module:filterClasses.ActiveFilter} filter
   * @returns {boolean}
   * @package
   */
  has(filter) {
    let module = this.selectModule(filter.type);
    if (module)
      return module.has(filter);
    return false;
  }

  /**
   * Clears all filters.
   * @package
   */
  clear() {
    this.defaultMatcher.clear();
    this.elemHide.clear();
    this.elemHideEmulation.clear();
    this.elemHideExceptions.clear();
    this.snippets.clear();
  }

  /**
   * Matches existing URL filters against a web resource
   * (HTML document, CSS style sheet, PNG image, etc.) and returns the matching
   * filter if there's a match.
   *
   * @param {string|URL|module:url~URLInfo} url The URL of the resource.
   * @param {number} typeMask The
   *   {@link module:contentTypes.contentTypes content types} associated with
   *   the resource.
   * @param {string} documentHostname The hostname of the document of the
   *   resource.
   * @param {?string} [sitekey] An optional public key associated with the
   *   document of the resource.
   * @param {boolean} [specificOnly] Whether to ignore any generic filters.
   *
   * @returns {?string} A URL filter if there's a match; otherwise `null`.
   *
   * @public
   */
  match(url, typeMask, documentHostname, sitekey = null, specificOnly = false) {
    if (typeof url == "string")
      url = parseURL(url);

    let filter = this.defaultMatcher.match(
      url, typeMask, documentHostname, sitekey, specificOnly
    );
    return filter ? filter.text : null;
  }
}

/**
 * The `FilterEngine` class maintains filters for request blocking, element
 * hiding, and snippets.
 *
 * @public
 *
 * @example
 *
 * let {contentTypes, FilterEngine} = require("adblockpluscore");
 *
 * let filterEnginer = new FilterEngine();
 * await filterEngine.initialize(
 *   [
 *     "/annoying-ad^$image",
 *     "||example.com/social-widget.html^"
 *   ]
 * );
 *
 * let resource = {
 *   url: "https://ad-server.example.net/annoying-ad.png",
 *   documentURL: "https://news.example.com/world.html"
 * };
 *
 * let filter = filterEngine.match(resource.url, contentTypes.IMAGE,
 *                                 new URL(resource.documentURL).hostname);
 * console.log(filter); // prints "/annoying-ad^$image"
 */
exports.FilterEngine = FilterEngine;


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/filterListener.js":
/*!************************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/filterListener.js ***!
  \************************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_303302__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * @file Synchronization between filter storage and the filter engine.
 */

const {filterNotifier} = __nested_webpack_require_303302__(/*! ./filterNotifier */ "./node_modules/adblockpluscore/lib/filterNotifier.js");
const {isActiveFilter, Filter} = __nested_webpack_require_303302__(/*! ./filterClasses */ "./node_modules/adblockpluscore/lib/filterClasses.js");

/**
 * Checks whether filters from a given subscription should be deployed to the
 * filter engine.
 *
 * If the subscription is both valid and enabled, the function returns `true`;
 * otherwise, it returns `false`.
 *
 * @param {module:subscriptionClasses.Subscription} subscription
 *   The subscription.
 *
 * @returns {boolean} Whether filters from the subscription should be deployed
 *   to the filter engine.
 */
function shouldDeployFilters(subscription) {
  return subscription.valid && !subscription.disabled;
}

/**
 * Deploys a filter to the filter engine.
 *
 * The filter is deployed only if it belongs to at least one subscription that
 * is both valid and enabled.
 *
 * If the filter is a snippet filter, or a block filter with the `$header`
 * options, it is deployed only if it belongs to at
 * least one subscription that is valid, enabled, and of
 * {@link module:subscriptionClasses.Subscription#type type}
 * `circumvention` or a
 * {@link module:subscriptionClasses.SpecialSubscription special subscription}
 * that keeps user-defined filters.
 *
 * @param {module:filterEngine.FilterEngine} engine A reference to the
 *   filter engine.
 * @param {module:filterStorage.FilterStorage} storage A reference to
 *   the filter storage.
 * @param {Filter} filter The filter.
 * @param {?Array.<module:subscriptionClasses.Subscription>} [subscriptions]
 *   A list of subscriptions to which the filter belongs. If omitted or `null`,
 *   the information is looked up from
 *   {@link module:filterStorage.filterStorage filter storage}.
 */
function deployFilter(engine, storage, filter, subscriptions = null) {
  if (!isActiveFilter(filter))
    return;

  let deploy = false;
  let allowPrivileged = false;
  let requiresPrivilegedSubscription = filter.requiresPrivilegedSubscription;

  for (let subscription of subscriptions ||
                           storage.subscriptions(filter.text)) {
    if (shouldDeployFilters(subscription) &&
        !filter.isDisabledForSubscription(subscription.url)) {
      deploy = true;
      if (!requiresPrivilegedSubscription)
        break;

      // Allow snippets to be executed only by the circumvention lists or the
      // user's own filters.
      if (subscription.privileged) {
        allowPrivileged = true;
        break;
      }
    }
  }

  if (!deploy)
    return;

  if (requiresPrivilegedSubscription && !allowPrivileged)
    return;

  engine.add(filter);
}

/**
 * Undeploys a filter from the filter engine.
 *
 * The filter is undeployed only if it does not belong to at least one
 * subscription that is both valid and enabled.
 *
 * @param {module:filterEngine.FilterEngine} engine A reference to the
 *   filter engine.
 * @param {module:filterStorage.FilterStorage} storage A reference to the
 *   filter storage.
 * @param {module:filterClasses.Filter} filter The filter.
 */
function undeployFilter(engine, storage, filter) {
  if (!isActiveFilter(filter))
    return;

  let requiresPrivilegedSubscription = filter.requiresPrivilegedSubscription;

  for (let subscription of storage.subscriptions(filter.text)) {
    if (shouldDeployFilters(subscription) &&
        !filter.isDisabledForSubscription(subscription.url)) {
      if (!requiresPrivilegedSubscription ||
          (requiresPrivilegedSubscription && subscription.privileged))
        return;
    }
  }

  engine.remove(filter);
}

/**
 * `{@link module:filterListener.filterListener filterListener}`
 * implementation.
 */
class FilterListener {
  /**
   * Initializes filter listener on startup, registers the necessary hooks.
   *
   * Initialization is asynchronous; once complete,
   * `{@link module:filterNotifier.filterNotifier filterNotifier}` emits the
   * `ready` event.
   *
   * @hideconstructor
   */
  constructor() {
    /**
     * A reference to the filter engine.
     * @type {?module:filterEngine.FilterEngine}
     * @private
     */
    this._engine = null;

    /**
     * A reference to the filter storage
     * @type {?module:filterStorage.FilterStorage}
     * @private
     */
    this._storage = null;

    /**
     * Increases on filter changes, filters will be saved if it exceeds 1.
     * @type {number}
     * @private
     */
    this._isDirty = 0;
  }

  /**
   * Initializes filter listener.
   * @param {module:filterEngine.FilterEngine} engine A reference to the
   *   filter engine.
   * @param {module:filterStorage.FilterStorage} storage A reference to the
   *   filter storage.
   * @returns {Promise} A promise that is fulfilled when the initialization is
   *   complete.
   * @package
   */
  async initialize(engine, storage) {
    if (engine == null || typeof engine != "object")
      throw new Error("engine must be a non-null object.");
    if (storage == null || typeof storage != "object")
      throw new Error("filterStorage must be a non-null object.");

    if (this._engine != null || this._storage != null)
      throw new Error("Filter listener already initialized.");

    this._engine = engine;
    this._storage = storage;

    await storage.loadFromDisk();

    let promise = Promise.resolve();

    // Initialize filters from each subscription asynchronously on startup by
    // setting up a chain of promises.
    for (let subscription of storage.subscriptions()) {
      if (shouldDeployFilters(subscription)) {
        await promise.then(() => {
          for (let text of subscription.filterText()) {
            deployFilter(
              this._engine, storage, Filter.fromText(text), [subscription]
            );
          }
        });
      }
    }

    filterNotifier.on("filter.added", this._onFilterAdded.bind(this));
    filterNotifier.on("filter.removed", this._onFilterRemoved.bind(this));
    filterNotifier.on("filter.moved", this._onGenericChange.bind(this));

    filterNotifier.on("filterState.enabled",
                      this._onFilterStateEnabled.bind(this));
    filterNotifier.on("filterState.disabledSubscriptions",
                      this._onFilterStateEnabled.bind(this));
    filterNotifier.on("filterState.hitCount",
                      this._onFilterStateHitCount.bind(this));
    filterNotifier.on("filterState.lastHit",
                      this._onFilterStateLastHit.bind(this));

    filterNotifier.on("subscription.added",
                      this._onSubscriptionAdded.bind(this));
    filterNotifier.on("subscription.removed",
                      this._onSubscriptionRemoved.bind(this));
    filterNotifier.on("subscription.disabled",
                      this._onSubscriptionDisabled.bind(this));
    filterNotifier.on("subscription.updated",
                      this._onSubscriptionUpdated.bind(this));
    filterNotifier.on("subscription.title", this._onGenericChange.bind(this));
    filterNotifier.on("subscription.fixedTitle",
                      this._onGenericChange.bind(this));
    filterNotifier.on("subscription.homepage",
                      this._onGenericChange.bind(this));
    filterNotifier.on("subscription.downloadStatus",
                      this._onGenericChange.bind(this));
    filterNotifier.on("subscription.lastCheck",
                      this._onGenericChange.bind(this));
    filterNotifier.on("subscription.errors",
                      this._onGenericChange.bind(this));

    filterNotifier.on("load", this._onLoad.bind(this));
    filterNotifier.on("save", this._onSave.bind(this));

    // Indicate that all filters are ready for use.
    filterNotifier.emit("ready");
  }

  /**
   * Increases "dirty factor" of the filters and calls
   * filterStorage.saveToDisk() if it becomes 1 or more.
   *
   * Save is executed delayed to prevent multiple subsequent calls. If the
   * parameter is 0 it forces saving filters if any changes were recorded after
   * the previous save.
   *
   * @param {number} factor
   *
   * @private
   */
  _setDirty(factor) {
    if (factor == 0 && this._isDirty > 0)
      this._isDirty = 1;
    else
      this._isDirty += factor;
    if (this._isDirty >= 1) {
      this._isDirty = 0;
      this._storage.saveToDisk();
    }
  }

  _onSubscriptionAdded(subscription) {
    this._setDirty(1);

    if (shouldDeployFilters(subscription)) {
      for (let text of subscription.filterText()) {
        deployFilter(
          this._engine, this._storage, Filter.fromText(text), [subscription]
        );
      }
    }
  }

  _onSubscriptionRemoved(subscription) {
    this._setDirty(1);

    if (shouldDeployFilters(subscription)) {
      for (let text of subscription.filterText())
        undeployFilter(this._engine, this._storage, Filter.fromText(text));
    }
  }

  _onSubscriptionDisabled(subscription, newValue) {
    this._setDirty(1);

    if (this._storage.hasSubscription(subscription)) {
      if (newValue == false) {
        for (let text of subscription.filterText()) {
          deployFilter(
            this._engine, this._storage, Filter.fromText(text), [subscription]
          );
        }
      }
      else {
        for (let text of subscription.filterText())
          undeployFilter(this._engine, this._storage, Filter.fromText(text));
      }
    }
  }

  _onSubscriptionUpdated(subscription, textDelta) {
    this._setDirty(1);

    if (textDelta && shouldDeployFilters(subscription) &&
        this._storage.hasSubscription(subscription)) {
      for (let text of textDelta.removed) {
        undeployFilter(
          this._engine, this._storage, Filter.fromText(text)
        );
      }

      for (let text of textDelta.added) {
        deployFilter(
          this._engine, this._storage, Filter.fromText(text), [subscription]
        );
      }
    }
  }

  _onFilterAdded(filter) {
    this._setDirty(1);
    deployFilter(this._engine, this._storage, filter);
  }

  _onFilterRemoved(filter) {
    this._setDirty(1);
    undeployFilter(this._engine, this._storage, filter);
  }

  _onFilterStateEnabled(text, newValue) {
    this._setDirty(1);

    // it's difficult to tell from newValue alone if we need to add or
    // remove the filter. Luckily, deployFilter and undeployFilter do
    // full checks that the filter should be added / removed.
    let filter = Filter.fromText(text);
    if (this._engine.has(filter))
      undeployFilter(this._engine, this._storage, filter);
    else
      deployFilter(this._engine, this._storage, filter);
  }

  _onFilterStateHitCount(text, newValue) {
    if (newValue == 0)
      this._setDirty(0);
    else
      this._setDirty(0.002);
  }

  _onFilterStateLastHit() {
    this._setDirty(0.002);
  }

  _onGenericChange() {
    this._setDirty(1);
  }

  _onLoad() {
    this._isDirty = 0;

    this._engine.clear();

    for (let subscription of this._storage.subscriptions()) {
      if (shouldDeployFilters(subscription)) {
        for (let text of subscription.filterText()) {
          deployFilter(
            this._engine, this._storage, Filter.fromText(text), [subscription]
          );
        }
      }
    }
  }

  _onSave() {
    this._isDirty = 0;
  }
}

/**
 * Component synchronizing filter storage with the filter engine.
 * @package
 */
exports.FilterListener = FilterListener;


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/filterNotifier.js":
/*!************************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/filterNotifier.js ***!
  \************************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_315829__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * @file This component manages listeners and calls them to distribute
 * messages about filter changes.
 */

const {EventEmitter} = __nested_webpack_require_315829__(/*! ./events */ "./node_modules/adblockpluscore/lib/events.js");

/**
 * This object allows registering and triggering listeners for filter events.
 * @type {module:events.EventEmitter}
 */
exports.filterNotifier = new EventEmitter();


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/filterState.js":
/*!*********************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/filterState.js ***!
  \*********************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_317279__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



const {filterNotifier} = __nested_webpack_require_317279__(/*! ./filterNotifier */ "./node_modules/adblockpluscore/lib/filterNotifier.js");
const {Filter} = __nested_webpack_require_317279__(/*! ./filterClasses */ "./node_modules/adblockpluscore/lib/filterClasses.js");

class FilterState {
  /**
   * Construct a new FilterState.
   * As a side effect this will set the global FilterState used
   * by Filter. Avoid constructing it more than once.
   */
  constructor() {
    /**
     * Internal map containing filter state.
     * @type {Map.<string, FilterStateEntry>}
     */
    this.map = new Map();

    // For now we'll assume that this is the filter state
    Filter.useFilterState(this);
  }

  /**
   * Gets which subscriptions this filters has been disabled for.
   * @param {string} filterText The text of the filter.
   * @returns {Set<string>} Set of subscription urls that this filter
   * has been disabled for.
   */
  disabledSubscriptions(filterText) {
    let state = this.map.get(filterText);
    if (!state || typeof state.disabledSubscriptions !== "object")
      return new Set();
    return state.disabledSubscriptions;
  }

  /**
   * Reset the disabled status of this filter to the default of
   * enabled for all subscriptions.
   * @param {string} filterText The text of the filter.
   */
  resetEnabled(filterText) {
    this._updateStateObject(filterText, state => {
      state.resetEnabled();
    });
  }

  /**
   * Checks whether a filter is disabled for a subscription.
   * @param {string} filterText The text of the filter.
   * @param {string} subscriptionUrl The subscription to check for
   * enabled / disabled state.
   * @returns {boolean} Whether the filter is disabled.
   */
  isDisabledForSubscription(filterText, subscriptionUrl) {
    let state = this.map.get(filterText);
    if (state)
      return state.isDisabledForSubscription(subscriptionUrl);
    return false;
  }

  /**
   * Sets the disabled state of a filter for a subscription.
   * @param {string} filterText The text of the filter.
   * @param {string} subscriptionUrl The subscription to enable /
   * disable the filter in.
   * @param {boolean} disabled The new disabled state of the filter.
   */
  setDisabledForSubscription(filterText, subscriptionUrl, disabled) {
    this._updateStateObject(filterText, state => {
      state.setDisabledForSubscription(subscriptionUrl, disabled);
    });
  }

  /**
   * Checks whether a filter is enabled.
   * @param {string} filterText The text of the filter.
   * @returns {boolean} Whether the filter is enabled.
   * @deprecated Use
   * {@link module:filterState.FilterState#isDisabledForSubscription} instead
   */
  isEnabled(filterText) {
    let state = this.map.get(filterText);
    if (state)
      return state.enabled;
    return true;
  }

  /**
   * Sets the enabled state of a filter.
   * @param {string} filterText The text of the filter.
   * @param {boolean} enabled The new enabled state of the filter.
   * @deprecated Use
   * {@link module:filterState.FilterState#setDisabledForSubscription} instead
   */
  setEnabled(filterText, enabled) {
    this._updateStateObject(filterText, state => {
      state.enabled = enabled;
    });
  }

  /**
   * Toggles the enabled state of a filter.
   * @param {string} filterText The text of the filter.
   * @deprecated Use
   * {@link module:filterState.FilterState#setDisabledForSubscription} instead
   */
  toggleEnabled(filterText) {
    let newValue = !this.isEnabled(filterText);
    this.setEnabled(filterText, newValue);
  }

  /**
   * Returns the hit count of a filter.
   * @param {string} filterText The text of the filter.
   * @returns {number} The hit count of the filter.
   */
  getHitCount(filterText) {
    let state = this.map.get(filterText);
    if (state)
      return state.hitCount;

    return 0;
  }

  /**
   * Sets the hit count of a filter.
   * @param {string} filterText The text of the filter.
   * @param {number} hitCount The new hit count of the filter.
   */
  setHitCount(filterText, hitCount) {
    this._updateStateObject(filterText, state => {
      state.hitCount = hitCount;
    });
  }

  /**
   * Resets the hit count of a filter.
   * @param {string} filterText The text of the filter.
   */
  resetHitCount(filterText) {
    this.setHitCount(filterText, 0);
  }

  /**
   * Returns the last hit time of a filter.
   * @param {string} filterText The text of the filter.
   * @returns {number} The last hit time of the filter in milliseconds since
   *   the Unix epoch.
   */
  getLastHit(filterText) {
    let state = this.map.get(filterText);
    if (state)
      return state.lastHit;

    return 0;
  }

  /**
   * Sets the last hit time of a filter.
   * @param {string} filterText The text of the filter.
   * @param {number} lastHit The new last hit time of the filter in
   *   milliseconds since the Unix epoch.
   */
  setLastHit(filterText, lastHit) {
    this._updateStateObject(filterText, state => {
      state.lastHit = lastHit;
    });
  }

  /**
   * Resets the last hit time of a filter.
   * @param {string} filterText The text of the filter.
   */
  resetLastHit(filterText) {
    this.setLastHit(filterText, 0);
  }

  /**
   * Registers a filter hit by incrementing the hit count of the filter and
   * setting the last hit time of the filter to the current time.
   * @param {string} filterText The text of the filter.
   */
  registerHit(filterText) {
    let now = Date.now();
    this._updateStateObject(filterText, state => {
      state.hitCount++;
      state.lastHit = now;
    });
  }

  /**
   * Resets the hit count and last hit time of a filter.
   * @param {string} filterText The text of the filter.
   */
  resetHits(filterText) {
    this._updateStateObject(filterText, state => {
      state.hitCount = 0;
      state.lastHit = 0;
    });
  }

  /**
   * Resets the enabled state, hit count, and last hit time of a filter.
   * @param {string} filterText The text of the filter.
   */
  reset(filterText) {
    let state = this.map.get(filterText);
    if (!state)
      return;

    this.map.delete(filterText);

    if (state.enabled !== true) {
      filterNotifier.emit("filterState.enabled",
                          filterText,
                          true,
                          state.enabled);
    }

    if (state.disabledSubscriptions && state.disabledSubscriptions.size > 0) {
      filterNotifier.emit("filterState.disabledSubscriptions",
                          filterText,
                          new Set(),
                          state.disabledSubscriptions);
    }

    if (state.hitCount != 0) {
      filterNotifier.emit("filterState.hitCount",
                          filterText,
                          0,
                          state.hitCount);
    }

    if (state.lastHit != 0)
      filterNotifier.emit("filterState.lastHit", filterText, 0, state.lastHit);
  }

  /**
   * Serializes the state of a filter.
   * @param {string} filterText The text of the filter.
   * @yields {string} The next line in the serialized representation of the
   *   state of the filter.
   * @see module:filterState.FilterState#fromObject
   * @package
   */
  *serialize(filterText) {
    let state = this.map.get(filterText);
    if (!state)
      return;

    yield "[Filter]";
    yield "text=" + filterText;

    if (state.disabled) {
      yield "disabled=true";
    }
    else if (typeof state.disabledSubscriptions === "object") {
      for (let disabledSubscription of state.disabledSubscriptions)
        yield "disabledSubscriptions[]=" + disabledSubscription;
    }

    if (state.hitCount != 0)
      yield "hitCount=" + state.hitCount;
    if (state.lastHit != 0)
      yield "lastHit=" + state.lastHit;
  }

  /**
   * Reads the state of a filter from an object representation.
   * @param {string} filterText The text of the filter.
   * @param {Object} object An object containing at least one of `disabled`,
   *   `hitCount`, and `lastHit` properties and their appropriate values.
   * @see module:filterState.FilterState#serialize
   * @package
   */
  fromObject(filterText, object) {
    if (!("disabled" in object ||
          "disabledSubscriptions" in object ||
          "hitCount" in object ||
          "lastHit" in object))
      return;

    let state = new FilterStateEntry();
    if (String(object.disabled) == "true")
      state.disabled = true;
    else if (typeof object.disabledSubscriptions === "object")
      state.disabledSubscriptions = new Set(object.disabledSubscriptions);

    state.hitCount = parseInt(object.hitCount, 10) || 0;
    state.lastHit = parseInt(object.lastHit, 10) || 0;
    if (!state.isEmpty())
      this.map.set(filterText, state);
  }

  _updateStateObject(filterText, doUpdate) {
    let state = this.map.get(filterText);
    if (!state) {
      state = new FilterStateEntry();
      this.map.set(filterText, state);
    }

    let oldHitCount = state.hitCount;
    let oldLastHit = state.lastHit;
    let oldEnabled = state.enabled;
    let oldDisabledSubscriptions = new Set(state.disabledSubscriptions);

    doUpdate(state);

    let newHitCount = state.hitCount;
    let newLastHit = state.lastHit;
    let newEnabled = state.enabled;
    let newDisabledSubscriptions = new Set(state.disabledSubscriptions);

    if (state.isEmpty())
      this.map.delete(filterText);

    if (oldHitCount !== newHitCount) {
      filterNotifier.emit("filterState.hitCount",
                          filterText,
                          newHitCount,
                          oldHitCount);
    }

    if (oldLastHit !== newLastHit) {
      filterNotifier.emit("filterState.lastHit",
                          filterText,
                          newLastHit,
                          oldLastHit);
    }

    if (oldEnabled !== newEnabled) {
      filterNotifier.emit("filterState.enabled",
                          filterText,
                          newEnabled,
                          oldEnabled);
    }

    if (!disabledSubscriptionsEquals(oldDisabledSubscriptions,
                                     newDisabledSubscriptions)) {
      filterNotifier.emit("filterState.disabledSubscriptions",
                          filterText,
                          newDisabledSubscriptions,
                          oldDisabledSubscriptions);
    }
  }
}

/**
 * Represents the state for a single filter.
 * See {@link module:filterState.FilterState}
 */
class FilterStateEntry {
  constructor() {
    /**
     * The hit count of the filter.
     * @type {number}
     */
    this.hitCount = 0;

    /**
     * The last hit time of the filter in milliseconds since the Unix epoch.
     * @type {number}
     */
    this.lastHit = 0;
  }

  /**
   * Check if the state is empty, so we know if we can clean it up.
   * @returns {boolean}
   */
  isEmpty() {
    return this.hitCount === 0 &&
      this.lastHit === 0 &&
      !this.disabled &&
      !this.disabledSubscriptions;
  }

  /**
   * Check if a filter is disabled for a specified subscription.
   * @param {string} subscriptionUrl The subscription to check for
   * enabled / disabled state.
   * @returns {boolean}
   */
  isDisabledForSubscription(subscriptionUrl) {
    if (this.disabled === true)
      return true;
    return this.disabledSubscriptions &&
      this.disabledSubscriptions.has(subscriptionUrl);
  }

  /**
   * Sets the disabled state of a filter.
   * @param {string} subscriptionUrl The subscription to enable /
   * disable the filter in.
   * @param {boolean} disabled The new disabled state of the filter.
   */
  setDisabledForSubscription(subscriptionUrl, disabled) {
    delete this.disabled;

    if (!this.disabledSubscriptions && !disabled)
      return;

    if (!this.disabledSubscriptions)
      this.disabledSubscriptions = new Set();

    if (disabled) {
      this.disabledSubscriptions.add(subscriptionUrl);
    }
    else {
      this.disabledSubscriptions.delete(subscriptionUrl);
      if (this.disabledSubscriptions.size === 0)
        delete this.disabledSubscriptions;
    }
  }

  /**
   * Reset the disabled status of this filter to the default of
   * enabled for all subscriptions.
   */
  resetEnabled() {
    delete this.disabled;
    delete this.disabledSubscriptions;
  }

  /**
   * Representation of filter state for the deprecated global enabling
   * and disabling of filters, as well as the `filterState.enabled`
   * events.
   * @type {boolean}
   * @deprecated Prefer {@link isDisabledForSubscription}
   */
  get enabled() {
    return !this.disabled;
  }
  set enabled(value) {
    delete this.disabledSubscriptions;
    this.disabled = !value;
  }
}

/**
 * Checks if two sets of disabled subscription urls contain exactly
 * the same subscription urls.
 * @param {Set<string>} oldDisabledSubscriptions
 * @param {Set<string>} newDisabledSubscriptions
 * @returns {boolean}
 */
function disabledSubscriptionsEquals(oldDisabledSubscriptions,
                                     newDisabledSubscriptions) {
  if (oldDisabledSubscriptions.size !== newDisabledSubscriptions.size)
    return false;

  for (let old of oldDisabledSubscriptions) {
    if (!newDisabledSubscriptions.has(old))
      return false;
  }
  return true;
}

/**
 * Maintains filter state.
 */
exports.FilterState = FilterState;


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/filterStorage.js":
/*!***********************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/filterStorage.js ***!
  \***********************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_331636__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * @file `filterStorage` object responsible for managing the user's
 * subscriptions and filters.
 */

const {IO} = __nested_webpack_require_331636__(/*! io */ "./sdk/api/io.js");
const {Prefs} = __nested_webpack_require_331636__(/*! prefs */ "./sdk/api/prefs.js");
const {isActiveFilter} = __nested_webpack_require_331636__(/*! ./filterClasses */ "./node_modules/adblockpluscore/lib/filterClasses.js");
const {Subscription, SpecialSubscription} = __nested_webpack_require_331636__(/*! ./subscriptionClasses */ "./node_modules/adblockpluscore/lib/subscriptionClasses.js");
const {filterNotifier} = __nested_webpack_require_331636__(/*! ./filterNotifier */ "./node_modules/adblockpluscore/lib/filterNotifier.js");
const {INIParser} = __nested_webpack_require_331636__(/*! ./iniParser */ "./node_modules/adblockpluscore/lib/iniParser.js");
const {FilterState} = __nested_webpack_require_331636__(/*! ./filterState */ "./node_modules/adblockpluscore/lib/filterState.js");
const {Synchronizer} = __nested_webpack_require_331636__(/*! ./synchronizer */ "./node_modules/adblockpluscore/lib/synchronizer.js");
const {Features} = __nested_webpack_require_331636__(/*! ./features */ "./node_modules/adblockpluscore/lib/features.js");

/**
 * The Error type returned by filter storage.
 *
 * @property {Object} detail Contains information about the error.
 * @property {string} [detail.text] The text of the filter for
     `filter_not_found`.
 * @property {Array.<string>} [detail.exist] The list of duplicate
 *   filters.
 */
class FilterStorageError extends Error {
  /** Construct a FilterParsingError
   * @constructor
   * @param {string} message The error message.
   * @param {Object} detail The `FilterStorageError` detail.
   */
  constructor(message, detail) {
    super(message);
    this.detail = detail;
  }
}

exports.FilterStorageError = FilterStorageError;

/**
 * @typedef {Object} Stats
 * @property {boolean} exists
 * @property {number} lastModified
 */

/**
 * A cache for all source files and backup stats.
 * @type {Map<string, Stats>}
 * @private
 */
let stats = new Map();

/**
 * An asynchronous guard for multiple backups renmaing operations. It gets
 * reassigned to a new Promise that rename all backups one more time.
 * @type {Promise<void>}
 * @private
 */
let backupQueue = Promise.resolve();

/**
 * Version number of the filter storage file format.
 * @type {number}
 */
const FORMAT_VERSION = 5;

/**
 * Reads the user's filters from disk, manages them in memory, and writes them
 * back to disk.
 */
class FilterStorage {
  /**
   * @typedef FilterStorageOptions
   * @type {object}
   * @property {?module:features.Features} features Enable specific features
   */
  /**
   * Construct a FilterStorage
   *
   * @param {?FilterStorageOptions} options The options to create the storage.
   */
  constructor(options) {
    /**
     * Will be set to `true` after the initial
     * `{@link module:filterStorage.FilterStorage#loadFromDisk loadFromDisk()}`
     * call completes.
     * @type {boolean}
     */
    this.initialized = false;

    /**
     * Will be set to `true` if no `patterns.ini` file exists.
     * @type {boolean}
     */
    this.firstRun = false;

    /** Activated features
     * @type {Features}
     */
    this.features = options ? options.features : Features.DEFAULT;
    Subscription.dnr = (this.features & Features.DNR) != 0;

    /**
     * Map of properties listed in the filter storage file before the sections
     * start. Right now this should be only the format version.
     * @type {Object}
     */
    this.fileProperties = Object.create(null);

    /**
     * Map of subscriptions already on the list, by their URL/identifier.
     * @type {Map.<string,module:subscriptionClasses.Subscription>}
     * @private
     */
    this._knownSubscriptions = new Map();

    /**
     * Map of subscriptions with metadata, by their URL/identifier.
     *
     * It can be used to answer "which subscriptions have metadata?".
     * @type {Map.<string,module:subscriptionClasses.Subscription>}
     * @private
     */
    this._metadataSubscriptions = new Map();

    /**
     * Will be set to `true` if
     * `{@link module:filterStorage.FilterStorage#saveToDisk saveToDisk()}`
     * is running (reentrance protection).
     * @type {boolean}
     * @private
     */
    this._saving = false;

    /**
     * Will be set to `true` if a
     * `{@link module:filterStorage.FilterStorage#saveToDisk saveToDisk()}`
     * call arrives while
     * `{@link module:filterStorage.FilterStorage#saveToDisk saveToDisk()}`
     * is already running (delayed execution).
     * @type {boolean}
     * @private
     */
    this._needsSave = false;

    /**
     * This property is for testing purpose only and it should never be used
     * directly via code.
     * @type {Map<string, Stats>}
     * @private
     */
    this._stats = stats;

    this.synchronizer = new Synchronizer(this);
    this.filterState = new FilterState();
  }

  /**
   * The version number of the `patterns.ini` format used.
   * @type {number}
   */
  get formatVersion() {
    return FORMAT_VERSION;
  }

  /**
   * The file containing the subscriptions.
   * @type {string}
   */
  static get sourceFile() {
    return "patterns.ini";
  }

  /**
   * Yields subscriptions in the storage.
   * @param {?string} [filterText] The filter text for which to look. If
   *   specified, the function yields only those subscriptions that contain the
   *   given filter text. By default the function yields all subscriptions.
   * @yields {module:subscriptionClasses.Subscription}
   */
  *subscriptions(filterText = null) {
    if (filterText == null) {
      yield* this._knownSubscriptions.values();
    }
    else {
      for (let subscription of this._knownSubscriptions.values()) {
        if (subscription.hasFilterText(filterText))
          yield subscription;
      }
    }
  }

  /**
   * Returns the number of subscriptions in the storage.
   * @param {?string} [filterText] The filter text for which to look. If
   *   specified, the function counts only those subscriptions that contain the
   *   given filter text. By default the function counts all subscriptions.
   * @returns {number}
   */
  getSubscriptionCount(filterText = null) {
    if (filterText == null)
      return this._knownSubscriptions.size;

    let count = 0;
    for (let subscription of this._knownSubscriptions.values()) {
      if (subscription.hasFilterText(filterText))
        count++;
    }
    return count;
  }

  /**
   * Finds the filter group that a filter should be added to by default. Will
   * return `null` if this group doesn't exist yet.
   * @param {Filter} filter
   * @returns {?module:subscriptionClasses.SpecialSubscription}
   */
  getGroupForFilter(filter) {
    let generalSubscription = null;
    for (let subscription of this._knownSubscriptions.values()) {
      // We ignore disabled subscriptions and subscriptions
      // without metadata
      if (
        subscription instanceof SpecialSubscription &&
        !subscription.disabled && !subscription.metadata
      ) {
        // Always prefer specialized subscriptions
        if (subscription.isDefaultFor(filter))
          return subscription;

        // If this is a general subscription - store it as fallback
        if (!generalSubscription &&
            (!subscription.defaults || !subscription.defaults.length))
          generalSubscription = subscription;
      }
    }
    return generalSubscription;
  }

  /**
   * Checks whether a given subscription is in the storage.
   * @param {module:subscriptionClasses.Subscription|string} subscription
   *   or the URL of the subscription.
   * @returns {boolean}
   */
  hasSubscription(subscription) {
    if (typeof subscription == "string")
      return this._knownSubscriptions.has(subscription);

    return this._knownSubscriptions.has(subscription.url);
  }

  /**
   * Get the the subscription from the storage.
   * @param {string} subscription The URL of the subscription.
   * @returns {module:subscriptionClasses.Subscription}
   */
  getSubscription(subscription) {
    return this._knownSubscriptions.get(subscription);
  }

  /**
   * Adds a subscription to the storage.
   * @param {module:subscriptionClasses.Subscription} subscription The
   *   subscription to be added.
   */
  addSubscription(subscription) {
    if (this._knownSubscriptions.has(subscription.url))
      return;

    this._knownSubscriptions.set(subscription.url, subscription);

    filterNotifier.emit("subscription.added", subscription);
  }

  /**
   * Removes a subscription from the storage.
   * @param {module:subscriptionClasses.Subscription} subscription The
   *   subscription to be removed.
   */
  removeSubscription(subscription) {
    if (!this._knownSubscriptions.has(subscription.url))
      return;

    this._knownSubscriptions.delete(subscription.url);
    this._metadataSubscriptions.delete(subscription.url);

    // This should be the last remaining reference to the Subscription
    // object.
    Subscription.knownSubscriptions.delete(subscription.url);

    filterNotifier.emit("subscription.removed", subscription);
  }

  /**
   * Replaces the list of filters in a subscription with a new list.
   * @param {module:subscriptionClasses.Subscription} subscription The
   *   subscription to be updated.
   * @param {Array.<string>} filterText The new filter text.
   */
  updateSubscriptionFilters(subscription, filterText) {
    filterNotifier.emit(
      "subscription.updated",
      subscription,
      subscription.updateFilterText(filterText)
    );
  }

  /**
   * Check the filters pass and return the list of the filters that exist.
   *
   * @param {Array.<Filter>} filters The filters to check.
   * @return {Array.<Filter>} The list of filters that exists. An empty
   *   list mean that none do exist.
   */
  filtersExist(filters) {
    let exist = [];

    for (let filter of filters) {
      for (let currentSubscription of this._knownSubscriptions.values()) {
        if (currentSubscription instanceof SpecialSubscription &&
            !currentSubscription.disabled &&
            currentSubscription.hasFilterText(filter.text))
          exist.push(filter);
      }
    }

    return exist;
  }

  /**
   * Adds user-defined filters to the storage with metadata.
   *
   * @async
   * @param {Filter|Array<Filter>} filters Filter(s) to add. If the list
   *   contains duplicate entries, they'll be skipped.
   * @param {Object} metadata The metadata block.
   *
   * @return {Promise<module:subscriptionClasses.SpecialSubscription>} the
   *   subscription the filter is in, or throw an error if any of the filter
   *   is already present in a `SpecialSubscription`.
   */
  async addFiltersWithMetadata(filters, metadata) {
    let list = Array.isArray(filters) ? filters : [filters];

    let exist = this.filtersExist(list);
    if (exist.length != 0)
      throw new FilterStorageError("storage_duplicate_filters", {exist});

    let subscription = null;

    for (let filter of list) {
      if (!subscription)
        subscription = SpecialSubscription.createForFilter(filter);
      // We make sure we don't have a duplicate already from `filters`.
      else if (!subscription.hasFilterText(filter.text))
        subscription.addFilter(filter);
    }

    this._metadataSubscriptions.set(subscription.url, subscription);
    this.addSubscription(subscription);

    subscription.metadata = metadata;

    return subscription;
  }

  /**
   * Get the metadata for a filter.
   *
   * @async
   * @param {string} text The filter text.
   * @return {Promise<Object>} The metadata if any found.
   *
   * This function will iterate through all the subscriptions with metadata
   * to find a `SpecialSubscription` that contains the filter text.
   */
  async getMetadataForFilter(text) {
    for (let currentSubscription of this._metadataSubscriptions.values()) {
      if (currentSubscription.hasFilterText(text))
        return currentSubscription.metadata;
    }

    throw new FilterStorageError("filter_not_found", {text});
  }

  /**
   * Set the metadata for a filter that already has metadata.
   *
   * A filter can have metadata only if it was added using
   * `addFiltersWithMetadata()`. It is currently not possible to add metadata
   * to an existing custom filter that was added with `addFilter()`. In that
   * case, the function will return a `filter_not_found` error.
   *
   * @async
   * @param {string} text The filter text.
   * @param {Object} metadata The metadata.
   *
   * @return {Promise<module:subscriptionClasses.SpecialSubscription>} The
   *   subscription whose metadata was changed.
   */
  async setMetadataForFilter(text, metadata) {
    for (let currentSubscription of this._metadataSubscriptions.values()) {
      if (currentSubscription.hasFilterText(text)) {
        currentSubscription.metadata = metadata;
        return currentSubscription;
      }
    }

    throw new FilterStorageError("filter_not_found", {text});
  }

  /**
   * Adds a user-defined filter to the storage.
   *
   * @async
   * @param {Filter} filter
   * @param {?module:subscriptionClasses.SpecialSubscription} [subscription]
   *   The subscription that the filter should be added to.
   * @param {number} [position] The position within the subscription at which
   *   the filter should be added. If not specified, the filter is added at the
   *   end of the subscription.
   *
   * @return {Promise<module:subscriptionClasses.SpecialSubscription>} The
   *   subscription the filter is in. Either existing or added.
   */
  async addFilter(filter, subscription, position) {
    if (!subscription) {
      for (let currentSubscription of this._knownSubscriptions.values()) {
        if (currentSubscription instanceof SpecialSubscription &&
            !currentSubscription.disabled &&
            currentSubscription.hasFilterText(filter.text)) {
          throw new FilterStorageError("storage_duplicate_filters",
                                       {exist: [filter]});  // No need to add
        }
      }
      subscription = this.getGroupForFilter(filter);
    }
    if (!subscription) {
      // No group for this filter exists, create one
      subscription = SpecialSubscription.createForFilter(filter);
      this.addSubscription(subscription);
      return subscription;
    }

    if (typeof position == "undefined")
      position = subscription.filterCount;

    subscription.insertFilterAt(filter, position);
    filterNotifier.emit("filter.added", filter, subscription, position);
    return subscription;
  }

  /**
   * Removes a user-defined filter from the storage.
   * @param {module:filterClasses.Filter} filter
   * @param {?module:subscriptionClasses.SpecialSubscription} [subscription]
   *   The subscription that the filter should be removed from. If not
   *   specified, the filter will be removed from all subscriptions.
   * @param {number} [position] The position within the subscription at which
   *   the filter should be removed. If not specified, all instances of the
   *   filter will be removed.
   */
  removeFilter(filter, subscription, position) {
    let subscriptions = (
      subscription ? [subscription] : this._knownSubscriptions.values()
    );
    for (let currentSubscription of subscriptions) {
      if (currentSubscription instanceof SpecialSubscription &&
          (currentSubscription == subscription ||
           currentSubscription.hasFilterText(filter.text))) {
        let positions = [];
        if (typeof position == "undefined") {
          let index = -1;
          do {
            index = currentSubscription.findFilterIndex(filter, index + 1);
            if (index >= 0)
              positions.push(index);
          } while (index >= 0);
        }
        else {
          positions.push(position);
        }

        for (let j = positions.length - 1; j >= 0; j--) {
          let currentPosition = positions[j];
          let currentFilterText =
            currentSubscription.filterTextAt(currentPosition);
          if (currentFilterText && currentFilterText == filter.text) {
            currentSubscription.deleteFilterAt(currentPosition);
            filterNotifier.emit(
              "filter.removed", filter, currentSubscription, currentPosition
            );
          }
        }
      }
    }
  }

  /**
   * Moves a user-defined filter to a new position.
   * @param {module:filterClasses.Filter} filter
   * @param {module:subscriptionClasses.SpecialSubscription} subscription The
   *   subscription where the filter is located.
   * @param {number} oldPosition The current position of the filter.
   * @param {number} newPosition The new position of the filter.
   */
  moveFilter(filter, subscription, oldPosition, newPosition) {
    if (!(subscription instanceof SpecialSubscription))
      return;

    let currentFilterText = subscription.filterTextAt(oldPosition);
    if (!currentFilterText || currentFilterText != filter.text)
      return;

    newPosition = Math.min(Math.max(newPosition, 0),
                           subscription.filterCount - 1);
    if (oldPosition == newPosition)
      return;

    subscription.deleteFilterAt(oldPosition);
    subscription.insertFilterAt(filter, newPosition);
    filterNotifier.emit(
      "filter.moved", filter, subscription, oldPosition, newPosition
    );
  }

  /**
   * Increases the hit count for a filter by one.
   * @param {Filter} filter
   */
  increaseHitCount(filter) {
    if (!Prefs.savestats || !isActiveFilter(filter))
      return;

    this.filterState.registerHit(filter.text);
  }

  /**
   * Resets hit count for some filters.
   * @param {?Array.<Filter>} [filters] The filters to be reset. If not
   *   specified, all filters will be reset.
   */
  resetHitCounts(filters) {
    if (filters) {
      for (let filter of filters)
        this.filterState.resetHits(filter.text);
    }
    else {
      for (let text of this.filterState.map.keys())
        this.filterState.resetHits(text);
    }
  }

  /**
   * @callback TextSink
   * @param {string?} line
   */

  /**
   * Allows importing previously serialized filter data.
   * @param {boolean} silent If `true`, no "load" notification will be sent
   *   out.
   * @returns {TextSink} The function to be called for each line of data.
   *   Calling it with `null` as the argument finalizes the import and replaces
   *   existing data. No changes will be applied before finalization, so import
   *   can be "aborted" by forgetting this callback.
   * @package
   */
  importData(silent) {
    let parser = new INIParser(this.filterState);
    return line => {
      parser.process(line);
      if (line === null) {
        let knownSubscriptions = new Map();
        let metadataSubscriptions = new Map();
        for (let subscription of parser.subscriptions) {
          // Convert to the new terminology when loading.
          if (Array.isArray(subscription.defaults)) {
            subscription.defaults.forEach((type, i, arr) => {
              if (type == "whitelist")
                arr[i] = "allowing";
            });
          }
          knownSubscriptions.set(subscription.url, subscription);
          if (subscription.metadata)
            metadataSubscriptions.set(subscription.url, subscription);
        }

        this.fileProperties = parser.fileProperties;
        this._knownSubscriptions = knownSubscriptions;
        this._metadataSubscriptions = metadataSubscriptions;

        if (!silent)
          filterNotifier.emit("load");
      }
    };
  }

  /**
   * Loads all subscriptions from disk.
   * @returns {Promise} A promise resolved or rejected when loading is complete.
   * @package
   */
  async loadFromDisk() {
    let tryBackup = async backupIndex => {
      try {
        await this.restoreBackup(backupIndex, true);

        if (this._knownSubscriptions.size == 0)
          return tryBackup(backupIndex + 1);
      }
      catch (error) {
        // Give up
      }
    };

    try {
      let statData = await statFile(FilterStorage.sourceFile);

      if (!statData.exists) {
        this.firstRun = true;
        return;
      }

      let parser = this.importData(true);
      await IO.readFromFile(FilterStorage.sourceFile, parser);
      parser(null);

      if (this._knownSubscriptions.size == 0) {
        // No filter subscriptions in the file, this isn't right.
        throw new Error("No data in the file");
      }
    }
    catch (error) {
      console.warn(error);
      await tryBackup(1);
    }

    this.initialized = true;
    filterNotifier.emit("load");
  }

  /**
   * Constructs the file name for a `patterns.ini` backup.
   * @param {number} backupIndex Number of the backup file (1 being the most
   *   recent).
   * @returns {string} Backup file name.
   * @package
   */
  static getBackupName(backupIndex) {
    let [name, extension] = FilterStorage.sourceFile.split(".", 2);
    return (name + "-backup" + backupIndex + "." + extension);
  }

  /**
   * Restores an automatically created backup.
   * @param {number} backupIndex Number of the backup to restore (1 being the
   *   most recent).
   * @param {boolean} silent If `true`, no "load" notification will be sent
   *   out.
   * @returns {Promise} A promise resolved or rejected when restoration is
   *   complete.
   * @package
   */
  async restoreBackup(backupIndex, silent) {
    let backupFile = FilterStorage.getBackupName(backupIndex);
    let parser = this.importData(silent);
    await IO.readFromFile(backupFile, parser);
    parser(null);
    return this.saveToDisk();
  }

  /**
   * Generator serializing filter data and yielding it line by line.
   * @yields {string}
   */
  *exportData() {
    // Do not persist external subscriptions
    let subscriptions = [];
    for (let subscription of this._knownSubscriptions.values()) {
      if (!(subscription instanceof SpecialSubscription &&
            subscription.filterCount == 0))
        subscriptions.push(subscription);
    }

    yield "# Adblock Plus preferences";
    yield "version=" + this.formatVersion;

    let saved = new Set();

    // Save subscriptions
    for (let subscription of subscriptions) {
      yield* subscription.serialize();
      yield* subscription.serializeFilters();
    }

    // Save filter data
    for (let subscription of subscriptions) {
      for (let text of subscription.filterText()) {
        if (!saved.has(text)) {
          yield* this.filterState.serialize(text);
          saved.add(text);
        }
      }
    }
  }

  /**
   * Saves all subscriptions back to disk.
   * @returns {Promise} A promise resolved or rejected when saving is complete.
   * @package
   */
  async saveToDisk() {
    if (this._saving) {
      this._needsSave = true;
      return;
    }

    this._saving = true;

    try {
      let {patternsbackups} = Prefs;
      let isBackupRequired = async() => {
        // First check whether we need to create a backup
        if (patternsbackups <= 0)
          return false;

        let statData = await statFile(FilterStorage.sourceFile);
        if (!statData.exists)
          return false;

        let backupStatData = await statFile(FilterStorage.getBackupName(1));
        if (backupStatData.exists &&
            (Date.now() - backupStatData.lastModified) / 3600000 <
              Prefs.patternsbackupinterval)
          return false;

        return true;
      };

      if (await isBackupRequired()) {
        try {
          // if patternsbackups is 1 just create it, otherwise create a
          // backup-0 that will be shifted among others later on
          let i = patternsbackups > 1 ? 0 : 1;
          await renameFile(
            FilterStorage.sourceFile, FilterStorage.getBackupName(i)
          );

          // if there is more than a backup, backup-0 up to backup-X need to be
          // renamed but without blocking this callback
          if (patternsbackups > 1) {
            // keep queueing backups as these come, considering backup1 and
            // backup 0 are always safe thanks to the this._saving flag
            backupQueue = backupQueue.then(() => new Promise(resolve => {
              let renameAll = async index => {
                if (index > 0) {
                  try {
                    let source = FilterStorage.getBackupName(index - 1);
                    let dest = FilterStorage.getBackupName(index);
                    await renameFile(source, dest);
                  }
                  catch (error) {
                    // Expected error, backup file doesn't exist.
                  }
                  renameAll(index - 1);
                }
                else {
                  resolve();
                }
              };
              renameAll(patternsbackups);
            }));
          }
        }
        catch (error) {
          // This is actually an unexpected error that could happen only if
          // the disk had issues in renaming the source file.
          console.warn(error);
        }
      }
    }
    catch (error) {
      // Errors during backup creation shouldn't prevent writing filters.
      console.warn(error);
    }

    try {
      await IO.writeToFile(FilterStorage.sourceFile, this.exportData());
      stats.set(
        FilterStorage.sourceFile, {exists: true, lastModified: Date.now()}
      );
      filterNotifier.emit("save");
    }
    catch (error) {
      // If saving failed, report error but continue - we still have to process
      // flags.
      console.warn(error);
      stats.delete(FilterStorage.sourceFile);
    }

    this._saving = false;
    if (this._needsSave) {
      this._needsSave = false;
      this.saveToDisk();
    }
  }

  /**
   * @typedef {Object} FileInfo
   * @property {number} index
   * @property {number} lastModified
   */

  /**
   * Returns a promise resolving in a list of existing backup files.
   * @returns {Promise.<Array.<FileInfo>>}
   * @package
   */
  async getBackupFiles() {
    let backups = [];

    let checkBackupFile = async index => {
      try {
        let statData = await statFile(FilterStorage.getBackupName(index));
        if (!statData.exists)
          return backups;

        backups.push({
          index,
          lastModified: statData.lastModified
        });

        return checkBackupFile(index + 1);
      }
      catch (error) {
        // Something went wrong, return whatever data we got so far.
        console.warn(error);
        return backups;
      }
    };

    return checkBackupFile(1);
  }
}

exports.FilterStorage = FilterStorage;

/**
 * Given a path, return its stats, if known, or a Stats object with properties
 * exists = false and lastModified = 0.
 * @param {string} path
 * @returns {Stats}
 */
async function statFile(path) {
  let known = stats.get(path);
  if (known)
    return known;

  try {
    known = await IO.statFile(path);
  }
  catch (error) {
    known = {exists: false, lastModified: 0};
  }
  stats.set(path, known);
  return known;
}

/**
 * Given a source path and a destination path, tries to rename the source and,
 * if it succeed, remove the source from the stats and set stats for dest.
 * @param {string} source
 * @param {string} dest
 */
async function renameFile(source, dest) {
  await IO.renameFile(source, dest);
  stats.delete(source);
  stats.set(dest, {exists: true, lastModified: Date.now()});
}


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/filters/index.js":
/*!***********************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/filters/index.js ***!
  \***********************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_360045__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */



/** @module */

const {contentTypes, RESOURCE_TYPES} = __nested_webpack_require_360045__(/*! ../contentTypes */ "./node_modules/adblockpluscore/lib/contentTypes.js");

/**
 * Regular expression that content filters should match
 * @type {RegExp}
 */
const CONTENT_FILTER = /^([^/|@"!]*?)#([@?$])?#(.+)$/;
exports.CONTENT_FILTER = CONTENT_FILTER;

/**
 * Regular expression that options on a RegExp filter should match
 * @type {RegExp}
 */
const FILTER_OPTIONS = /\$(~?[\w-]+(?:=[^,]*)?(?:,~?[\w-]+(?:=[^,]*)?)*)$/;
exports.FILTER_OPTIONS = FILTER_OPTIONS;

// used to reduce possible short filters damage
const MIN_GENERIC_URL_FILTER_PATTERN_LENGTH = 4;

/**
 * Regular expression that matches an invalid Content Security Policy
 * @type {RegExp}
 */
const INVALID_CSP = /(;|^) ?(base-uri|referrer|report-to|report-uri|upgrade-insecure-requests)\b/i;
exports.INVALID_CSP = INVALID_CSP;

/**
 * The Error type returned by parse.
 *
 * For example `filter_unknown_option` will have `option`.
 * @property {Object} detail Contains information about the error.
 * @property {string} [detail.option] The option for `filter_unknown_option`.
 * @property {string} [detail.regexp] The regexp for `filter_invalid_regexp`.
 * @property {string} detail.text The text of the rejected filter.
 */
class FilterParsingError extends Error {
  /** Construct a FilterParsingError
   * @constructor
   * @param {string} message The error message.
   * @param {Object} detail The FilterParsingError detail. Contains at
   *   least `text`.
   */
  constructor(message, detail) {
    super(message);
    this.detail = detail;
  }
}

exports.FilterParsingError = FilterParsingError;

/**
 * @typedef {Object} ParsedFilter
 * @property {bool} blocking Whether it's a blocking filter or not.
 * @property {string} text The filter text.
 * @property {string} regexpSource The source of the matching RegExp.
 * @property {number} contentType The
 *   {@link module:contentTypes.contentTypes content types} for the filter.
 * @property {bool?} matchCase If the filter is case sensitive.
 * @property {Array<string>?} domains The domains to match
 *   (`$domains` option).
 * @property {Array<string>?} sitekeys The sitekeys to match.
 * @property {object?} headers The headers filtering.
 * @property {string?} rewrite The URL for to rewrite to.
 * @property {string?} csp The CSP directive.
 */

/**
 * Parse the filter text representation into a structure.
 *
 * This is meant to be called by
 * {module:filterClasses.URLFilter.fromText}
 *
 * @param {string} text the filter normalized text. Call normalize()
 *   on the text prior to this, unless it is already normalized.
 * @return {ParsedFilter|FilterParsingError}
 *   The parsed filter, or a FilterParsingError.
 */
exports.parse = function parse(text) {
  // exclude empty text, comments, and content filters
  if (text.length < 1)
    return new FilterParsingError("filter_empty", {text});

  if (text[0] === "!" || CONTENT_FILTER.test(text))
    return new FilterParsingError("invalid", {text});

  // parse like an ABP URLFilter
  let blocking = true;
  let origText = text;
  if (text.startsWith("@@")) {
    blocking = false;
    text = text.substring(2);
  }

  let contentType = null;
  let matchCase = null;
  let domains = null;
  let sitekeys = null;
  let thirdParty = null;
  let csp = null;
  let rewrite = null;
  let header = null;
  let options;
  let match = text.includes("$") ? FILTER_OPTIONS.exec(text) : null;
  if (match) {
    text = match.input.substring(0, match.index);

    options = match[1].split(",");
    let cspSet = false;
    let headerSet = false;

    for (let option of options) {
      let value = null;
      let separatorIndex = option.indexOf("=");
      if (separatorIndex >= 0) {
        value = option.substring(separatorIndex + 1);
        option = option.substring(0, separatorIndex);
      }

      let inverse = option[0] == "~";
      if (inverse)
        option = option.substring(1);

      let optionUpperCase = option.toUpperCase();
      let type = contentTypes[optionUpperCase.replace(/-/, "_")];
      if (type) {
        if (inverse) {
          if (contentType == null)
            contentType = RESOURCE_TYPES;
          contentType &= ~type;
        }
        else if (type === contentTypes.CSP) {
          if (blocking && !value) {
            return new FilterParsingError("filter_invalid_csp",
                                          {text: origText});
          }
          cspSet = true;
          csp = value;
        }
        else if (type === contentTypes.HEADER) {
          if (blocking && !value) {
            return new FilterParsingError("filter_invalid_header",
                                          {text: origText});
          }
          headerSet = true;
          if (value) {
            let headerRaw = value.replace(/([^\\])\\x2c/g, "$1,")
                .replace(/\\\\x2c/g, "\\x2c");
            let equal = headerRaw.indexOf("=");
            if (equal == headerRaw.length - 1) {
              // This case is "key=" with no value
              header = {
                name: headerRaw.substring(0, equal).toLowerCase()
              };
            }
            else if (equal >= 0) {
              header = {
                name: headerRaw.substring(0, equal).toLowerCase(),
                value: headerRaw.substring(equal + 1)
              };
            }
            else {
              header = {
                name: headerRaw.toLowerCase()
              };
            }

            if (header.name.length == 0) {
              return new FilterParsingError("filter_invalid_header",
                                            {text: origText});
            }
            if (/^\/[\s\S]*\/$/.test(header.value)) {
              return new FilterParsingError("filter_invalid_header",
                                            {text: origText});
            }
          }
        }
        else {
          contentType |= type;
        }
      }
      else {
        switch (optionUpperCase) {
          case "MATCH-CASE":
            matchCase = !inverse;
            break;
          case "DOMAIN":
            if (!value) {
              return new FilterParsingError("filter_unknown_option",
                                            {option, text: origText});
            }
            domains = value;
            break;
          case "THIRD-PARTY":
            thirdParty = !inverse;
            break;
          case "SITEKEY":
            if (!value) {
              return new FilterParsingError("filter_unknown_option",
                                            {option, text: origText});
            }
            // Sitekeys are case-sensitive, they shouldn't be uppercased.
            sitekeys = value;
            break;
          case "REWRITE":
            if (value == null) {
              return new FilterParsingError("filter_unknown_option",
                                            {option, text: origText});
            }
            if (!value.startsWith("abp-resource:")) {
              return new FilterParsingError("filter_invalid_rewrite",
                                            {text: origText});
            }
            rewrite = value.substring("abp-resource:".length);
            break;
          default:
            return new FilterParsingError("filter_unknown_option",
                                          {option, text: origText});
        }
      }
    }
    if (cspSet || headerSet) {
      if (contentType == null)
        contentType = RESOURCE_TYPES;
      if (cspSet)
        contentType |= contentTypes.CSP;
      if (headerSet)
        contentType |= contentTypes.HEADER;
    }
  }

  let isGeneric = !sitekeys && !domains;
  if (isGeneric) {
    let minTextLength = MIN_GENERIC_URL_FILTER_PATTERN_LENGTH;
    let {length} = text;
    if (length > 0 && text[0] === "|") {
      minTextLength++;
      if (length > 1 && text[1] === "|")
        minTextLength++;
    }
    if (length < minTextLength && !text.includes("*")) {
      return new FilterParsingError("filter_url_not_specific_enough",
                                    {text: origText});
    }
  }
  // We expect filters to use Punycode for domains these days, so let's just
  // skip filters which don't. See #6647.
  else if (domains && /[^\x00-\x7F]/.test(domains)) {
    return new FilterParsingError("filter_invalid_domain", {text: origText});
  }

  if (blocking) {
    if (csp && INVALID_CSP.test(csp))
      return new FilterParsingError("filter_invalid_csp", {text: origText});

    if (rewrite) {
      if (text.startsWith("||")) {
        if (!domains && thirdParty != false) {
          return new FilterParsingError("filter_invalid_rewrite",
                                        {text: origText});
        }
      }
      else if (text.startsWith("*")) {
        if (!domains) {
          return new FilterParsingError("filter_invalid_rewrite",
                                        {text: origText});
        }
      }
      else {
        return new FilterParsingError("filter_invalid_rewrite",
                                      {text: origText});
      }
    }
  }

  return {
    blocking,
    text: origText,
    regexpSource: text,
    contentType,
    matchCase,
    domains,
    thirdParty,
    sitekeys,
    header,
    rewrite,
    csp
  };
};

/**
 * Removes unnecessary whitespaces from filter text, will only return null if
 * the input parameter is null.
 *
 * @param {string} text
 * @param {boolean?} dontSanitize avoid expensive operations on text.
 * @return {string}
 */
exports.normalize = function(text, dontSanitize = false) {
  if (text === "")
    return text;

  // Remove line breaks, tabs etc
  text = text.replace(/[^\S ]+/g, "");

  if (dontSanitize)
    return text.trim();

  if (!text.includes(" "))
    return text;

  // Don't remove spaces inside comments
  if (/^ *!/.test(text))
    return text.trim();

  // Special treatment for content filters, right side is allowed to contain
  // spaces
  if (CONTENT_FILTER.test(text)) {
    let [, domains, separator, body] = /^(.*?)(#[@?$]?#?)(.*)$/.exec(text);
    return domains.replace(/ +/g, "") + separator + body.trim();
  }

  // For most regexp filters we strip all spaces, but $csp filter options
  // are allowed to contain single (non trailing) spaces.
  let strippedText = text.replace(/ +/g, "");
  if (!strippedText.includes("$") || !/\b(csp|header)=/i.test(strippedText))
    return strippedText;

  let optionsMatch = FILTER_OPTIONS.exec(strippedText);
  if (!optionsMatch)
    return strippedText;

  // For $csp filters we must first separate out the options part of the
  // text, being careful to preserve its spaces.
  let beforeOptions = strippedText.substring(0, optionsMatch.index);
  let strippedDollarIndex = -1;
  let dollarIndex = -1;
  do {
    strippedDollarIndex = beforeOptions.indexOf("$", strippedDollarIndex + 1);
    dollarIndex = text.indexOf("$", dollarIndex + 1);
  }
  while (strippedDollarIndex != -1);
  let optionsText = text.substring(dollarIndex + 1);

  // Then we can normalize spaces in the options part safely
  let options = optionsText.split(",");
  for (let i = 0; i < options.length; i++) {
    let option = options[i];
    let optionMatch = /^ *(c *s *p|h *e *a *d *e *r) *=/i.exec(option);
    if (optionMatch) {
      options[i] = optionMatch[0].replace(/ +/g, "") +
                   option.substring(optionMatch[0].length).trim().replace(/ +/g, " ");
    }
    else {
      options[i] = option.replace(/ +/g, "");
    }
  }

  return beforeOptions + "$" + options.join();
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/filters/lists.js":
/*!***********************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/filters/lists.js ***!
  \***********************************************************/
/***/ ((__unused_webpack_module, exports) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */



/** @module */

/**
 * Given some text containing a filter list, parse each line and return all
 * details.
 * @param {string} filters The filter list file/text to parse.
 * @returns {Object.<error?, lines?, params?, minVersion?>} All parsed details,
 *  if available. `lines` will contain the header in the first line.
 */
function parseFilterList(filters) {
  let lines = filters.split(/[\r\n]+/);
  // The filter list always start with a header, at minimum `[Adblock]`.
  let headerMatch = /\[Adblock(?:\s*Plus\s*([\d.]+)?)?\]/i.exec(lines[0]);

  if (!headerMatch)
    return {error: "synchronize_invalid_data"};

  let minVersion = headerMatch[1];

  let params = {
    redirect: null,
    homepage: null,
    title: null,
    version: null,
    expires: null,
    abtest: null
  };

  for (let {hasOwnProperty} = Object.prototype, i = 1; i < lines.length; i++) {
    let match = /^\s*!\s*(.*?)\s*:\s*(.*)/.exec(lines[i]);
    if (!match)
      break;

    let keyword = match[1].toLowerCase();
    if (hasOwnProperty.call(params, keyword)) {
      params[keyword] = match[2];
      lines.splice(i--, 1);
    }
  }

  return {lines, params, minVersion};
}

exports.parseFilterList = parseFilterList;


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/filtersByDomain.js":
/*!*************************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/filtersByDomain.js ***!
  \*************************************************************/
/***/ ((__unused_webpack_module, exports) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * Map to be used instead when a filter has a blank `domains` property.
 * @type {Map.<string, boolean>}
 */
let defaultDomains = new Map([["", true]]);

let FilterMap =
/**
 * A `FilterMap` object contains a set of filters, each mapped to a boolean
 * value indicating whether the filter should be applied.
 *
 * It is used by
 * `{@link module:filtersByDomain.FiltersByDomain FiltersByDomain}`.
 *
 * @package
 */
exports.FilterMap = class FilterMap extends Map {};

/**
 * A `FiltersByDomain` object contains a set of domains, each mapped to a set
 * of filters along with a boolean value for each filter indicating whether the
 * filter should be applied to the domain.
 *
 * @package
 */
exports.FiltersByDomain = class FiltersByDomain extends Map {
  /**
   * Adds a filter and all of its domains to the object.
   *
   * @param {module:filterClasses.ActiveFilter} filter The filter.
   * @param {Map.<string, boolean>} [domains] The filter's domains. If not
   *   given, the `{@link module:filterClasses.ActiveFilter#domains domains}`
   *   property of `filter` is used.
   */
  add(filter, domains = filter.domains) {
    for (let [domain, include] of domains || defaultDomains) {
      if (!include && domain == "")
        continue;

      let map = this.get(domain);
      if (!map) {
        this.set(domain, include ? filter : new FilterMap([[filter, false]]));
      }
      else if (map.size == 1 && !(map instanceof FilterMap)) {
        if (filter != map)
          this.set(domain, new FilterMap([[map, true], [filter, include]]));
      }
      else {
        map.set(filter, include);
      }
    }
  }

  /**
   * Removes a filter and all of its domains from the object.
   *
   * @param {module:filterClasses.ActiveFilter} filter The filter.
   * @param {Map.<string, boolean>} [domains] The filter's domains. If not
   *   given, the `{@link module:filterClasses.ActiveFilter#domains domains}`
   *   property of `filter` is used.
   */
  remove(filter, domains = filter.domains) {
    for (let domain of (domains || defaultDomains).keys()) {
      let map = this.get(domain);
      if (map) {
        if (map.size > 1 || map instanceof FilterMap) {
          map.delete(filter);

          if (map.size == 0) {
            this.delete(domain);
          }
          else if (map.size == 1) {
            for (let [lastFilter, include] of map.entries()) {
              // Reduce Map { "example.com" => Map { filter => true } } to
              // Map { "example.com" => filter }
              if (include)
                this.set(domain, lastFilter);

              break;
            }
          }
        }
        else if (filter == map) {
          this.delete(domain);
        }
      }
    }
  }
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/index.js":
/*!***************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/index.js ***!
  \***************************************************/
/***/ ((module, __unused_webpack_exports, __nested_webpack_require_378682__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/**
 * @module
 *
 * @borrows module:contentTypes.contentTypes as contentTypes
 * @borrows module:features.Features as Features
 * @borrows module:filterEngine.FilterEngine as FilterEngine
 * @borrows module:synchronizer.Synchronizer as Synchronizer
 * @borrows module:url.parseURL as parseURL
 */



const {contentTypes} = __nested_webpack_require_378682__(/*! ./contentTypes */ "./node_modules/adblockpluscore/lib/contentTypes.js");
const {Features} = __nested_webpack_require_378682__(/*! ./features */ "./node_modules/adblockpluscore/lib/features.js");
const {FilterEngine} = __nested_webpack_require_378682__(/*! ./filterEngine */ "./node_modules/adblockpluscore/lib/filterEngine.js");
const {Synchronizer} = __nested_webpack_require_378682__(/*! ./synchronizer */ "./node_modules/adblockpluscore/lib/synchronizer.js");
const {parseURL} = __nested_webpack_require_378682__(/*! ./url */ "./node_modules/adblockpluscore/lib/url.js");

module.exports = {
  contentTypes,
  Features,
  FilterEngine,
  Synchronizer,
  parseURL
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/iniParser.js":
/*!*******************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/iniParser.js ***!
  \*******************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_380675__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * @file INI parsing.
 */

const {isActiveFilter, Filter} = __nested_webpack_require_380675__(/*! ./filterClasses */ "./node_modules/adblockpluscore/lib/filterClasses.js");
const {FilterState} = __nested_webpack_require_380675__(/*! ./filterState */ "./node_modules/adblockpluscore/lib/filterState.js");
const {Subscription} = __nested_webpack_require_380675__(/*! ./subscriptionClasses */ "./node_modules/adblockpluscore/lib/subscriptionClasses.js");

/**
 * Parses filter data.
 * @package
 */
exports.INIParser = class INIParser {
  /** @param {FilterState} filterState the filter state */
  constructor(filterState) {
    if (!(filterState instanceof FilterState))
      throw new Error("filterState must be a FilterState object");

    /**
     * Properties of the filter data.
     * @type {Object}
     */
    this.fileProperties = {};

    /**
     * The list of subscriptions in the filter data.
     * @type {Array.<module:subscriptionClasses.Subscription>}
     */
    this.subscriptions = [];

    /** @type {module:filterState.FilterState} */
    this.filterState = filterState;

    this._wantObj = true;
    this._curObj = this.fileProperties;
    this._curSection = null;
  }

  /**
   * Processes a line of filter data.
   *
   * @param {string?} line The line of filter data to process. This may be
   *   `null`, which indicates the end of the filter data.
   */
  process(line) {
    let match = null;
    if (this._wantObj === true && (match = /^(\w+)=(.*)$/.exec(line))) {
      this._curObj[match[1]] = match[2];
    }
    else if (this._wantObj === true && (match = /^(\w+)\[]=(.*)$/.exec(line))) {
      if (!this._curObj[match[1]])
        this._curObj[match[1]] = [];
      this._curObj[match[1]].push(match[2]);
    }
    else if (line === null || (match = /^\s*\[(.+)\]\s*$/.exec(line))) {
      if (this._curObj) {
        // Process current object before going to next section
        switch (this._curSection) {
          case "filter":
            if ("text" in this._curObj) {
              let {text} = this._curObj;
              if (isActiveFilter(Filter.fromText(text)))
                this.filterState.fromObject(text, this._curObj);
            }
            break;

          case "subscription":
            let subscription = Subscription.fromObject(this._curObj);
            if (subscription)
              this.subscriptions.push(subscription);
            break;

          case "subscription filters":
            if (this.subscriptions.length) {
              let currentSubscription = this.subscriptions[
              this.subscriptions.length - 1
              ];
              currentSubscription.updateFilterText(this._curObj);
            }
            break;
        }
      }

      if (line === null)
        return;

      this._curSection = match[1].toLowerCase();
      switch (this._curSection) {
        case "filter":
        case "subscription":
          this._wantObj = true;
          this._curObj = {};
          break;
        case "subscription filters":
          this._wantObj = false;
          this._curObj = [];
          break;
        default:
          this._wantObj = null;
          this._curObj = null;
      }
    }
    else if (this._wantObj === false && line) {
      this._curObj.push(line.replace(/\\\[/g, "["));
    }
  }
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/jsbn.js":
/*!**************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/jsbn.js ***!
  \**************************************************/
/***/ ((__unused_webpack_module, exports) => {

/*
 * Copyright (c) 2003-2005  Tom Wu
 * All Rights Reserved.
 *
 * Permission is hereby granted, free of charge, to any person obtaining
 * a copy of this software and associated documentation files (the
 * "Software"), to deal in the Software without restriction, including
 * without limitation the rights to use, copy, modify, merge, publish,
 * distribute, sublicense, and/or sell copies of the Software, and to
 * permit persons to whom the Software is furnished to do so, subject to
 * the following conditions:
 *
 * The above copyright notice and this permission notice shall be
 * included in all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
 * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
 * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
 *
 * IN NO EVENT SHALL TOM WU BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
 * INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER
 * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER OR NOT ADVISED OF
 * THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF LIABILITY, ARISING OUT
 * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
 *
 * In addition, the following condition applies:
 *
 * All redistributions must retain an intact copy of this copyright notice
 * and disclaimer.
 */

// Basic JavaScript BN library - subset useful for RSA encryption.

// Modified by eyeo GmbH to better support going to and from JS binary
// strings (base 256) and our particular use case.

// Bits per digit
var dbits;

// JavaScript engine analysis
var canary = 0xdeadbeefcafe;
var j_lm = ((canary&0xffffff)==0xefcafe);

// (public) Constructor
let BigInteger = exports.BigInteger = function BigInteger(a,b,c) {
  if(a != null)
    if("number" == typeof a) this.fromNumber(a,b,c);
    else if(b == null && "string" != typeof a) this.fromString(a,256);
    else this.fromString(a,b);
};

// return new, unset BigInteger
function nbi() { return new BigInteger(null); }

// am: Compute w_j += (x*this_i), propagate carries,
// c is initial carry, returns final carry.
// c < 3*dvalue, x < 2*dvalue, this_i < dvalue
// We need to select the fastest one that works in this environment.

// am1: use a single mult and divide to get the high bits,
// max digit bits should be 26 because
// max internal value = 2*dvalue^2-2*dvalue (< 2^53)
function am1(i,x,w,j,c,n) {
  while(--n >= 0) {
    var v = x*this[i++]+w[j]+c;
    c = Math.floor(v/0x4000000);
    w[j++] = v&0x3ffffff;
  }
  return c;
}
// am2 avoids a big mult-and-extract completely.
// Max digit bits should be <= 30 because we do bitwise ops
// on values up to 2*hdvalue^2-hdvalue-1 (< 2^31)
function am2(i,x,w,j,c,n) {
  var xl = x&0x7fff, xh = x>>15;
  while(--n >= 0) {
    var l = this[i]&0x7fff;
    var h = this[i++]>>15;
    var m = xh*l+h*xl;
    l = xl*l+((m&0x7fff)<<15)+w[j]+(c&0x3fffffff);
    c = (l>>>30)+(m>>>15)+xh*h+(c>>>30);
    w[j++] = l&0x3fffffff;
  }
  return c;
}
// Alternately, set max digit bits to 28 since some
// browsers slow down when dealing with 32-bit numbers.
function am3(i,x,w,j,c,n) {
  var xl = x&0x3fff, xh = x>>14;
  while(--n >= 0) {
    var l = this[i]&0x3fff;
    var h = this[i++]>>14;
    var m = xh*l+h*xl;
    l = xl*l+((m&0x3fff)<<14)+w[j]+c;
    c = (l>>28)+(m>>14)+xh*h;
    w[j++] = l&0xfffffff;
  }
  return c;
}
if(j_lm && (typeof navigator != "undefined" && navigator.appName == "Microsoft Internet Explorer")) { /** MODIFIED **/
  BigInteger.prototype.am = am2;
  dbits = 30;
}
else if(j_lm && (typeof navigator != "undefined" && navigator.appName != "Netscape")) { /** MODIFIED **/
  BigInteger.prototype.am = am1;
  dbits = 26;
}
else { // Mozilla/Netscape seems to prefer am3
  BigInteger.prototype.am = am3;
  dbits = 28;
}

BigInteger.prototype.DB = dbits;
BigInteger.prototype.DM = ((1<<dbits)-1);
BigInteger.prototype.DV = (1<<dbits);

var BI_FP = 52;
BigInteger.prototype.FV = Math.pow(2,BI_FP);
BigInteger.prototype.F1 = BI_FP-dbits;
BigInteger.prototype.F2 = 2*dbits-BI_FP;

// Digit conversions
var BI_RM = "0123456789abcdefghijklmnopqrstuvwxyz";
var BI_RC = new Array();
var rr,vv;
rr = "0".charCodeAt(0);
for(vv = 0; vv <= 9; ++vv) BI_RC[rr++] = vv;
rr = "a".charCodeAt(0);
for(vv = 10; vv < 36; ++vv) BI_RC[rr++] = vv;
rr = "A".charCodeAt(0);
for(vv = 10; vv < 36; ++vv) BI_RC[rr++] = vv;

function int2char(n) { return BI_RM.charAt(n); }
function intAt(s,i) {
  var c = BI_RC[s.charCodeAt(i)];
  return (c==null)?-1:c;
}

// (protected) copy this to r
function bnpCopyTo(r) {
  for(var i = this.t-1; i >= 0; --i) r[i] = this[i];
  r.t = this.t;
  r.s = this.s;
}

// (protected) set from integer value x, -DV <= x < DV
function bnpFromInt(x) {
  this.t = 1;
  this.s = (x<0)?-1:0;
  if(x > 0) this[0] = x;
  else if(x < -1) this[0] = x+DV;
  else this.t = 0;
}

// return bigint initialized to value
function nbv(i) { var r = nbi(); r.fromInt(i); return r; }

// (protected) set from string and radix
function bnpFromString(s,b) {
  var k;
  if(b == 16) k = 4;
  else if(b == 8) k = 3;
  else if(b == 256) k = 8; // byte array
  else if(b == 2) k = 1;
  else if(b == 32) k = 5;
  else if(b == 4) k = 2;
  else { this.fromRadix(s,b); return; }
  this.t = 0;
  this.s = 0;
  var i = s.length, mi = false, sh = 0;
  while(--i >= 0) {
    var x = (k==8)?s.charCodeAt(i)&0xff:intAt(s,i);   /** MODIFIED **/
    if(x < 0) {
      if(s.charAt(i) == "-") mi = true;
      continue;
    }
    mi = false;
    if(sh == 0)
      this[this.t++] = x;
    else if(sh+k > this.DB) {
      this[this.t-1] |= (x&((1<<(this.DB-sh))-1))<<sh;
      this[this.t++] = (x>>(this.DB-sh));
    }
    else
      this[this.t-1] |= x<<sh;
    sh += k;
    if(sh >= this.DB) sh -= this.DB;
  }
  if(k == 8 && (s[0]&0x80) != 0) {
    this.s = -1;
    if(sh > 0) this[this.t-1] |= ((1<<(this.DB-sh))-1)<<sh;
  }
  this.clamp();
  if(mi) BigInteger.ZERO.subTo(this,this);
}

// (protected) clamp off excess high words
function bnpClamp() {
  var c = this.s&this.DM;
  while(this.t > 0 && this[this.t-1] == c) --this.t;
}

// (public) return string representation in given radix
function bnToString(b) {
  if(this.s < 0) return "-"+this.negate().toString(b);
  var k;
  if(b == 16) k = 4;
  else if(b == 8) k = 3;
  else if(b == 256) k = 8; // byte array      /** MODIFIED **/
  else if(b == 2) k = 1;
  else if(b == 32) k = 5;
  else if(b == 4) k = 2;
  else return this.toRadix(b);
  var km = (1<<k)-1, d, m = false, r = "", i = this.t;
  var p = this.DB-(i*this.DB)%k;
  if(i-- > 0) {
    if(p < this.DB && (d = this[i]>>p) > 0) { m = true; r = (k==8)?String.fromCharCode(d):int2char(d); }   /** MODIFIED **/
    while(i >= 0) {
      if(p < k) {
        d = (this[i]&((1<<p)-1))<<(k-p);
        d |= this[--i]>>(p+=this.DB-k);
      }
      else {
        d = (this[i]>>(p-=k))&km;
        if(p <= 0) { p += this.DB; --i; }
      }
      if(d > 0) m = true;
      if(m) r += (k==8)?String.fromCharCode(d):int2char(d);    /** MODIFIED **/
    }
  }
  return m?r:"0";
}

// (public) -this
function bnNegate() { var r = nbi(); BigInteger.ZERO.subTo(this,r); return r; }

// (public) |this|
function bnAbs() { return (this.s<0)?this.negate():this; }

// (public) return + if this > a, - if this < a, 0 if equal
function bnCompareTo(a) {
  var r = this.s-a.s;
  if(r != 0) return r;
  var i = this.t;
  r = i-a.t;
  if(r != 0) return r;
  while(--i >= 0) if((r=this[i]-a[i]) != 0) return r;
  return 0;
}

// returns bit length of the integer x
function nbits(x) {
  var r = 1, t;
  if((t=x>>>16) != 0) { x = t; r += 16; }
  if((t=x>>8) != 0) { x = t; r += 8; }
  if((t=x>>4) != 0) { x = t; r += 4; }
  if((t=x>>2) != 0) { x = t; r += 2; }
  if((t=x>>1) != 0) { x = t; r += 1; }
  return r;
}

// (public) return the number of bits in "this"
function bnBitLength() {
  if(this.t <= 0) return 0;
  return this.DB*(this.t-1)+nbits(this[this.t-1]^(this.s&this.DM));
}

// (protected) r = this << n*DB
function bnpDLShiftTo(n,r) {
  var i;
  for(i = this.t-1; i >= 0; --i) r[i+n] = this[i];
  for(i = n-1; i >= 0; --i) r[i] = 0;
  r.t = this.t+n;
  r.s = this.s;
}

// (protected) r = this >> n*DB
function bnpDRShiftTo(n,r) {
  for(var i = n; i < this.t; ++i) r[i-n] = this[i];
  r.t = Math.max(this.t-n,0);
  r.s = this.s;
}

// (protected) r = this << n
function bnpLShiftTo(n,r) {
  var bs = n%this.DB;
  var cbs = this.DB-bs;
  var bm = (1<<cbs)-1;
  var ds = Math.floor(n/this.DB), c = (this.s<<bs)&this.DM, i;
  for(i = this.t-1; i >= 0; --i) {
    r[i+ds+1] = (this[i]>>cbs)|c;
    c = (this[i]&bm)<<bs;
  }
  for(i = ds-1; i >= 0; --i) r[i] = 0;
  r[ds] = c;
  r.t = this.t+ds+1;
  r.s = this.s;
  r.clamp();
}

// (protected) r = this >> n
function bnpRShiftTo(n,r) {
  r.s = this.s;
  var ds = Math.floor(n/this.DB);
  if(ds >= this.t) { r.t = 0; return; }
  var bs = n%this.DB;
  var cbs = this.DB-bs;
  var bm = (1<<bs)-1;
  r[0] = this[ds]>>bs;
  for(var i = ds+1; i < this.t; ++i) {
    r[i-ds-1] |= (this[i]&bm)<<cbs;
    r[i-ds] = this[i]>>bs;
  }
  if(bs > 0) r[this.t-ds-1] |= (this.s&bm)<<cbs;
  r.t = this.t-ds;
  r.clamp();
}

// (protected) r = this - a
function bnpSubTo(a,r) {
  var i = 0, c = 0, m = Math.min(a.t,this.t);
  while(i < m) {
    c += this[i]-a[i];
    r[i++] = c&this.DM;
    c >>= this.DB;
  }
  if(a.t < this.t) {
    c -= a.s;
    while(i < this.t) {
      c += this[i];
      r[i++] = c&this.DM;
      c >>= this.DB;
    }
    c += this.s;
  }
  else {
    c += this.s;
    while(i < a.t) {
      c -= a[i];
      r[i++] = c&this.DM;
      c >>= this.DB;
    }
    c -= a.s;
  }
  r.s = (c<0)?-1:0;
  if(c < -1) r[i++] = this.DV+c;
  else if(c > 0) r[i++] = c;
  r.t = i;
  r.clamp();
}

// (protected) r = this * a, r != this,a (HAC 14.12)
// "this" should be the larger one if appropriate.
function bnpMultiplyTo(a,r) {
  var x = this.abs(), y = a.abs();
  var i = x.t;
  r.t = i+y.t;
  while(--i >= 0) r[i] = 0;
  for(i = 0; i < y.t; ++i) r[i+x.t] = x.am(0,y[i],r,i,0,x.t);
  r.s = 0;
  r.clamp();
  if(this.s != a.s) BigInteger.ZERO.subTo(r,r);
}

// (protected) r = this^2, r != this (HAC 14.16)
function bnpSquareTo(r) {
  var x = this.abs();
  var i = r.t = 2*x.t;
  while(--i >= 0) r[i] = 0;
  for(i = 0; i < x.t-1; ++i) {
    var c = x.am(i,x[i],r,2*i,0,1);
    if((r[i+x.t]+=x.am(i+1,2*x[i],r,2*i+1,c,x.t-i-1)) >= x.DV) {
      r[i+x.t] -= x.DV;
      r[i+x.t+1] = 1;
    }
  }
  if(r.t > 0) r[r.t-1] += x.am(i,x[i],r,2*i,0,1);
  r.s = 0;
  r.clamp();
}

// (protected) divide this by m, quotient and remainder to q, r (HAC 14.20)
// r != q, this != m.  q or r may be null.
function bnpDivRemTo(m,q,r) {
  var pm = m.abs();
  if(pm.t <= 0) return;
  var pt = this.abs();
  if(pt.t < pm.t) {
    if(q != null) q.fromInt(0);
    if(r != null) this.copyTo(r);
    return;
  }
  if(r == null) r = nbi();
  var y = nbi(), ts = this.s, ms = m.s;
  var nsh = this.DB-nbits(pm[pm.t-1]);	// normalize modulus
  if(nsh > 0) { pm.lShiftTo(nsh,y); pt.lShiftTo(nsh,r); }
  else { pm.copyTo(y); pt.copyTo(r); }
  var ys = y.t;
  var y0 = y[ys-1];
  if(y0 == 0) return;
  var yt = y0*(1<<this.F1)+((ys>1)?y[ys-2]>>this.F2:0);
  var d1 = this.FV/yt, d2 = (1<<this.F1)/yt, e = 1<<this.F2;
  var i = r.t, j = i-ys, t = (q==null)?nbi():q;
  y.dlShiftTo(j,t);
  if(r.compareTo(t) >= 0) {
    r[r.t++] = 1;
    r.subTo(t,r);
  }
  BigInteger.ONE.dlShiftTo(ys,t);
  t.subTo(y,y);	// "negative" y so we can replace sub with am later
  while(y.t < ys) y[y.t++] = 0;
  while(--j >= 0) {
    // Estimate quotient digit
    var qd = (r[--i]==y0)?this.DM:Math.floor(r[i]*d1+(r[i-1]+e)*d2);
    if((r[i]+=y.am(0,qd,r,j,0,ys)) < qd) {	// Try it out
      y.dlShiftTo(j,t);
      r.subTo(t,r);
      while(r[i] < --qd) r.subTo(t,r);
    }
  }
  if(q != null) {
    r.drShiftTo(ys,q);
    if(ts != ms) BigInteger.ZERO.subTo(q,q);
  }
  r.t = ys;
  r.clamp();
  if(nsh > 0) r.rShiftTo(nsh,r);	// Denormalize remainder
  if(ts < 0) BigInteger.ZERO.subTo(r,r);
}

// (public) this mod a
function bnMod(a) {
  var r = nbi();
  this.abs().divRemTo(a,null,r);
  if(this.s < 0 && r.compareTo(BigInteger.ZERO) > 0) a.subTo(r,r);
  return r;
}

// Modular reduction using "classic" algorithm
function Classic(m) { this.m = m; }
function cConvert(x) {
  if(x.s < 0 || x.compareTo(this.m) >= 0) return x.mod(this.m);
  else return x;
}
function cRevert(x) { return x; }
function cReduce(x) { x.divRemTo(this.m,null,x); }
function cMulTo(x,y,r) { x.multiplyTo(y,r); this.reduce(r); }
function cSqrTo(x,r) { x.squareTo(r); this.reduce(r); }

Classic.prototype.convert = cConvert;
Classic.prototype.revert = cRevert;
Classic.prototype.reduce = cReduce;
Classic.prototype.mulTo = cMulTo;
Classic.prototype.sqrTo = cSqrTo;

// (protected) return "-1/this % 2^DB"; useful for Mont. reduction
// justification:
//         xy == 1 (mod m)
//         xy =  1+km
//   xy(2-xy) = (1+km)(1-km)
// x[y(2-xy)] = 1-k^2m^2
// x[y(2-xy)] == 1 (mod m^2)
// if y is 1/x mod m, then y(2-xy) is 1/x mod m^2
// should reduce x and y(2-xy) by m^2 at each step to keep size bounded.
// JS multiply "overflows" differently from C/C++, so care is needed here.
function bnpInvDigit() {
  if(this.t < 1) return 0;
  var x = this[0];
  if((x&1) == 0) return 0;
  var y = x&3;		// y == 1/x mod 2^2
  y = (y*(2-(x&0xf)*y))&0xf;	// y == 1/x mod 2^4
  y = (y*(2-(x&0xff)*y))&0xff;	// y == 1/x mod 2^8
  y = (y*(2-(((x&0xffff)*y)&0xffff)))&0xffff;	// y == 1/x mod 2^16
  // last step - calculate inverse mod DV directly;
  // assumes 16 < DB <= 32 and assumes ability to handle 48-bit ints
  y = (y*(2-x*y%this.DV))%this.DV;		// y == 1/x mod 2^dbits
  // we really want the negative inverse, and -DV < y < DV
  return (y>0)?this.DV-y:-y;
}

// Montgomery reduction
function Montgomery(m) {
  this.m = m;
  this.mp = m.invDigit();
  this.mpl = this.mp&0x7fff;
  this.mph = this.mp>>15;
  this.um = (1<<(m.DB-15))-1;
  this.mt2 = 2*m.t;
}

// xR mod m
function montConvert(x) {
  var r = nbi();
  x.abs().dlShiftTo(this.m.t,r);
  r.divRemTo(this.m,null,r);
  if(x.s < 0 && r.compareTo(BigInteger.ZERO) > 0) this.m.subTo(r,r);
  return r;
}

// x/R mod m
function montRevert(x) {
  var r = nbi();
  x.copyTo(r);
  this.reduce(r);
  return r;
}

// x = x/R mod m (HAC 14.32)
function montReduce(x) {
  while(x.t <= this.mt2)	// pad x so am has enough room later
    x[x.t++] = 0;
  for(var i = 0; i < this.m.t; ++i) {
    // faster way of calculating u0 = x[i]*mp mod DV
    var j = x[i]&0x7fff;
    var u0 = (j*this.mpl+(((j*this.mph+(x[i]>>15)*this.mpl)&this.um)<<15))&x.DM;
    // use am to combine the multiply-shift-add into one call
    j = i+this.m.t;
    x[j] += this.m.am(0,u0,x,i,0,this.m.t);
    // propagate carry
    while(x[j] >= x.DV) { x[j] -= x.DV; x[++j]++; }
  }
  x.clamp();
  x.drShiftTo(this.m.t,x);
  if(x.compareTo(this.m) >= 0) x.subTo(this.m,x);
}

// r = "x^2/R mod m"; x != r
function montSqrTo(x,r) { x.squareTo(r); this.reduce(r); }

// r = "xy/R mod m"; x,y != r
function montMulTo(x,y,r) { x.multiplyTo(y,r); this.reduce(r); }

Montgomery.prototype.convert = montConvert;
Montgomery.prototype.revert = montRevert;
Montgomery.prototype.reduce = montReduce;
Montgomery.prototype.mulTo = montMulTo;
Montgomery.prototype.sqrTo = montSqrTo;

// (protected) true iff this is even
function bnpIsEven() { return ((this.t>0)?(this[0]&1):this.s) == 0; }

// (protected) this^e, e < 2^32, doing sqr and mul with "r" (HAC 14.79)
function bnpExp(e,z) {
  if(e > 0xffffffff || e < 1) return BigInteger.ONE;
  var r = nbi(), r2 = nbi(), g = z.convert(this), i = nbits(e)-1;
  g.copyTo(r);
  while(--i >= 0) {
    z.sqrTo(r,r2);
    if((e&(1<<i)) > 0) z.mulTo(r2,g,r);
    else { var t = r; r = r2; r2 = t; }
  }
  return z.revert(r);
}

// (public) this^e % m, 0 <= e < 2^32
function bnModPowInt(e,m) {
  var z;
  if(e < 256 || m.isEven()) z = new Classic(m); else z = new Montgomery(m);
  return this.exp(e,z);
}

// protected
BigInteger.prototype.copyTo = bnpCopyTo;
BigInteger.prototype.fromInt = bnpFromInt;
BigInteger.prototype.fromString = bnpFromString;
BigInteger.prototype.clamp = bnpClamp;
BigInteger.prototype.dlShiftTo = bnpDLShiftTo;
BigInteger.prototype.drShiftTo = bnpDRShiftTo;
BigInteger.prototype.lShiftTo = bnpLShiftTo;
BigInteger.prototype.rShiftTo = bnpRShiftTo;
BigInteger.prototype.subTo = bnpSubTo;
BigInteger.prototype.multiplyTo = bnpMultiplyTo;
BigInteger.prototype.squareTo = bnpSquareTo;
BigInteger.prototype.divRemTo = bnpDivRemTo;
BigInteger.prototype.invDigit = bnpInvDigit;
BigInteger.prototype.isEven = bnpIsEven;
BigInteger.prototype.exp = bnpExp;

// public
BigInteger.prototype.toString = bnToString;
BigInteger.prototype.negate = bnNegate;
BigInteger.prototype.abs = bnAbs;
BigInteger.prototype.compareTo = bnCompareTo;
BigInteger.prototype.bitLength = bnBitLength;
BigInteger.prototype.mod = bnMod;
BigInteger.prototype.modPowInt = bnModPowInt;

// "constants"
BigInteger.ZERO = nbv(0);
BigInteger.ONE = nbv(1);


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/matcher.js":
/*!*****************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/matcher.js ***!
  \*****************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_402188__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * @file Matcher class implementing matching addresses against
 *               a list of filters.
 */

const {RESOURCE_TYPES, SPECIAL_TYPES, ALLOWING_TYPES,
       enumerateTypes} = __nested_webpack_require_402188__(/*! ./contentTypes */ "./node_modules/adblockpluscore/lib/contentTypes.js");
const {compilePatterns} = __nested_webpack_require_402188__(/*! ./patterns */ "./node_modules/adblockpluscore/lib/patterns.js");
const {domainSuffixes, URLRequest} = __nested_webpack_require_402188__(/*! ./url */ "./node_modules/adblockpluscore/lib/url.js");
const {Filter} = __nested_webpack_require_402188__(/*! ./filterClasses */ "./node_modules/adblockpluscore/lib/filterClasses.js");
const {FiltersByDomain, FilterMap} = __nested_webpack_require_402188__(/*! ./filtersByDomain */ "./node_modules/adblockpluscore/lib/filtersByDomain.js");
const {Cache} = __nested_webpack_require_402188__(/*! ./caching */ "./node_modules/adblockpluscore/lib/caching.js");

/**
 * Returns the amount of filters per map.
 * @param {Map} map
 * @param {string} keyword
 * @returns {number}
 */
let countFilters = (map, keyword) => {
  let list = map.get(keyword);
  if (!list)
    return 0;
  if (list instanceof Filter)
    return 1;
  return list.length;
};

/**
 * Returns a list of filters, if any, or an empty list.
 * @param {Map} map
 * @param {string} keyword
 * @returns {Array.<module:filterClasses.URLFilter>}
 */
let getFilters = (map, keyword) => {
  let list = map.get(keyword);
  if (!list)
    return Array.prototype;
  if (list instanceof Filter)
    return [list];
  return list;
};

/**
 * Checks if the keyword is bad for use.
 * @param {string} keyword
 * @returns {boolean}
 */
function isBadKeyword(keyword) {
  return keyword == "https" || keyword == "http" || keyword == "com" ||
         keyword == "js";
}

/**
 * Adds a filter by a given keyword to a map.
 * @param {module:filterClasses.URLFilter} filter
 * @param {string} keyword
 * @param {Map.<string,(module:filterClasses.URLFilter|
 *                      Array.<module:filterClasses.URLFilter>)>} map
 */
function addFilterByKeyword(filter, keyword, map) {
  // this dance is to avoid storing arrays for single filters
  let list = map.get(keyword);
  // when the keyword is known, promote as array if needed
  if (list) {
    if (list instanceof Filter)
      map.set(keyword, [list, filter]);
    else
      list.push(filter);
  }
  else {
    // store just the filter without the Array
    map.set(keyword, filter);
  }
}

/**
 * Removes a filter by a given keyword from a map.
 * @param {module:filterClasses.URLFilter} filter
 * @param {string} keyword
 * @param {Map.<string,(module:filterClasses.URLFilter|
 *                      Array.<module:filterClasses.URLFilter>)>} map
 */
function removeFilterByKeyword(filter, keyword, map) {
  // this dance is to normalize back the keyword entry, if any
  let list = map.get(keyword);
  if (list) {
    // when the value is a filter, remove the keyword if filter matches
    if (list instanceof Filter) {
      if (list == filter)
        map.delete(keyword);
    }
    // otherwise find the index and drop the array if the list has 1 item
    else {
      let i = list.findIndex(item => item === filter);
      if (i >= 0) {
        list.splice(i, 1);
        if (list.length === 1)
          map.set(keyword, list[0]);
      }
    }
  }
}

/**
 * Checks whether a filter matches a given URL request.
 *
 * @param {module:filterClasses.URLFilter} filter The filter.
 * @param {module:url.URLRequest} request The URL request.
 * @param {number} typeMask A mask specifying the content type of the URL
 *   request.
 * @param {?string} [sitekey] An optional public key associated with the
 *   URL request.
 * @param {?Array} [collection] An optional list to which to append the filter
 *   if it matches. If omitted, the function directly returns the filter if it
 *   matches.
 *
 * @returns {?module:filterClasses.URLFilter} The filter if it matches and
 *   `collection` is omitted; otherwise `null`.
 */
function matchFilter(filter, request, typeMask, sitekey, collection) {
  if (filter.matches(request, typeMask, sitekey)) {
    if (!collection)
      return filter;

    collection.push(filter);
  }

  return null;
}

/**
 * Checks whether a particular filter is slow.
 * @param {module:filterClasses.URLFilter} filter
 * @returns {boolean}
 */
exports.isSlowFilter = function isSlowFilter(filter) {
  return !filter.urlPattern.hasKeywords();
};

let Matcher =
/**
 * Blocking/allowing filter matching
 */
exports.Matcher = class Matcher {
  constructor() {
    /**
     * Lookup table for keywords by their associated filter
     * @type {Map.<module:filterClasses.URLFilter,string>}
     * @private
     */
    this._keywordByFilter = new Map();

    /**
     * Lookup table for simple filters by their associated keyword
     * @type {Map.<string,(module:filterClasses.URLFilter|
     *                     Array.<module:filterClasses.URLFilter>)>}
     * @private
     */
    this._simpleFiltersByKeyword = new Map();

    /**
     * Lookup table for complex filters by their associated keyword
     * @type {Map.<string,(module:filterClasses.URLFilter|
     *                     Array.<module:filterClasses.URLFilter>)>}
     * @private
     */
    this._complexFiltersByKeyword = new Map();

    /**
     * Lookup table of compiled patterns for simple filters by their associated
     * keyword
     * @type {Map.<string,?module:patterns~CompiledPatterns>}
     * @private
     */
    this._compiledPatternsByKeyword = new Map();

    /**
     * Compiled patterns for generic complex filters with no associated
     * keyword.
     * @type {?module:patterns~CompiledPatterns|boolean}
     * @private
     */
    this._keywordlessCompiledPatterns = false;

    /**
     * Lookup table of domain maps for complex filters by their associated
     * keyword
     * @type {Map.<string,
     *             Map.<string,
     *                  (module:filterClasses.URLFilter|
     *                   Map.<module:filterClasses.URLFilter,boolean>)>>}
     * @private
     */
    this._filterDomainMapsByKeyword = new Map();

    /**
     * Lookup table of type-specific lookup tables for complex filters by their
     * associated keyword
     * @type {Map.<string,
     *             Map.<string,
     *                  (module:filterClasses.URLFilter|
     *                   Array.<module:filterClasses.URLFilter>)>>}
     * @private
     */
    this._filterMapsByType = new Map();
  }

  /**
   * Removes all known filters
   */
  clear() {
    this._keywordByFilter.clear();
    this._simpleFiltersByKeyword.clear();
    this._complexFiltersByKeyword.clear();
    this._compiledPatternsByKeyword.clear();
    this._keywordlessCompiledPatterns = false;
    this._filterDomainMapsByKeyword.clear();
    this._filterMapsByType.clear();
  }

  /**
   * Adds a filter to the matcher
   * @param {module:filterClasses.URLFilter} filter
   */
  add(filter) {
    if (this._keywordByFilter.has(filter))
      return;

    // Look for a suitable keyword
    let keyword = this.findKeyword(filter);
    let simple = filter.contentType == RESOURCE_TYPES && filter.isGeneric();

    addFilterByKeyword(filter, keyword, simple ? this._simpleFiltersByKeyword :
        this._complexFiltersByKeyword);

    this._keywordByFilter.set(filter, keyword);

    if (simple) {
      if (this._compiledPatternsByKeyword.size > 0)
        this._compiledPatternsByKeyword.delete(keyword);

      return;
    }

    if (keyword == "")
      this._keywordlessCompiledPatterns = false;

    for (let type of enumerateTypes(filter.contentType, SPECIAL_TYPES)) {
      let map = this._filterMapsByType.get(type);
      if (!map)
        this._filterMapsByType.set(type, map = new Map());

      addFilterByKeyword(filter, keyword, map);
    }

    let {domains} = filter;

    let filtersByDomain = this._filterDomainMapsByKeyword.get(keyword);
    if (!filtersByDomain) {
      // In most cases, there is only one pure generic filter to a keyword.
      // Instead of Map { "foo" => Map { "" => Map { filter => true } } }, we
      // can just reduce it to Map { "foo" => filter } and save a lot of
      // memory.
      if (!domains) {
        this._filterDomainMapsByKeyword.set(keyword, filter);
        return;
      }

      filtersByDomain = new FiltersByDomain();
      this._filterDomainMapsByKeyword.set(keyword, filtersByDomain);
    }
    else if (!(filtersByDomain instanceof FiltersByDomain)) {
      filtersByDomain = new FiltersByDomain([["", filtersByDomain]]);
      this._filterDomainMapsByKeyword.set(keyword, filtersByDomain);
    }

    filtersByDomain.add(filter, domains);
  }

  /**
   * Removes a filter from the matcher
   * @param {module:filterClasses.URLFilter} filter
   */
  remove(filter) {
    let keyword = this._keywordByFilter.get(filter);
    if (typeof keyword == "undefined")
      return;

    let simple = filter.contentType == RESOURCE_TYPES && filter.isGeneric();

    removeFilterByKeyword(
      filter,
      keyword,
      simple ?
        this._simpleFiltersByKeyword :
        this._complexFiltersByKeyword
    );

    this._keywordByFilter.delete(filter);

    if (simple) {
      if (this._compiledPatternsByKeyword.size > 0)
        this._compiledPatternsByKeyword.delete(keyword);

      return;
    }

    if (keyword == "")
      this._keywordlessCompiledPatterns = false;

    for (let type of enumerateTypes(filter.contentType, SPECIAL_TYPES)) {
      let map = this._filterMapsByType.get(type);
      if (map)
        removeFilterByKeyword(filter, keyword, map);
    }

    let filtersByDomain = this._filterDomainMapsByKeyword.get(keyword);
    if (filtersByDomain) {
      // Because of the memory optimization in the add function, most of the
      // time this will be a filter rather than a map.
      if (!(filtersByDomain instanceof FiltersByDomain)) {
        this._filterDomainMapsByKeyword.delete(keyword);
        return;
      }

      filtersByDomain.remove(filter);

      if (filtersByDomain.size == 0) {
        this._filterDomainMapsByKeyword.delete(keyword);
      }
      else if (filtersByDomain.size == 1) {
        for (let [lastDomain, map] of filtersByDomain.entries()) {
          // Reduce Map { "foo" => Map { "" => filter } } to
          // Map { "foo" => filter }
          if (lastDomain == "" && !(map instanceof FilterMap))
            this._filterDomainMapsByKeyword.set(keyword, map);

          break;
        }
      }
    }
  }

  /**
   * Checks whether a filter exists in the matcher
   * @param {module:filterClasses.URLFilter} filter
   * @returns {boolean}
   */
  has(filter) {
    return this._keywordByFilter.has(filter);
  }

  /**
   * Chooses a keyword to be associated with the filter.
   *
   * Because it will perform some internal optimizations, there is no
   * guarantee that this function will always return the same result when
   * called with the same filter.
   *
   * @param {module:filterClasses.Filter} filter
   * @returns {string} keyword or an empty string if no keyword could be found
   * @protected
   */
  findKeyword(filter) {
    let result = "";

    let candidates = filter.urlPattern.keywordCandidates();
    if (!candidates)
      return result;

    let resultCount = 0xFFFFFF;
    let resultLength = 0;

    for (let i = 0, l = candidates.length; i < l; i++) {
      let candidate = candidates[i].substring(1);

      if (isBadKeyword(candidate))
        continue;

      let simpleCount = countFilters(this._simpleFiltersByKeyword, candidate);
      let complexCount = countFilters(this._complexFiltersByKeyword,
                                      candidate);

      let count = simpleCount + complexCount;

      if (count < resultCount ||
          (count == resultCount && candidate.length > resultLength)) {
        result = candidate;
        resultCount = count;
        resultLength = candidate.length;
      }
    }

    return result;
  }

  _matchFiltersByDomain(filtersByDomain, request, typeMask, sitekey,
                        specificOnly, collection) {
    let excluded = null;

    let domain = request.documentHostname || "";
    for (let suffix of domainSuffixes(domain, !specificOnly)) {
      let map = filtersByDomain.get(suffix);
      if (map) {
        if (map instanceof FilterMap) {
          for (let [filter, include] of map.entries()) {
            if (!include) {
              if (excluded)
                excluded.add(filter);
              else
                excluded = new Set([filter]);
            }
            else if (
              (!excluded || !excluded.has(filter)) &&
              matchFilter(filter, request, typeMask, sitekey, collection)
            ) {
              return filter;
            }
          }
        }
        else if ((!excluded || !excluded.has(map)) &&
                 matchFilter(map, request, typeMask, sitekey, collection)) {
          return map;
        }
      }
    }

    return null;
  }

  _checkEntryMatchSimpleQuickCheck(keyword, request, filters) {
    let compiled = this._compiledPatternsByKeyword.get(keyword);
    if (typeof compiled == "undefined") {
      compiled = compilePatterns(filters);
      this._compiledPatternsByKeyword.set(keyword, compiled);
    }

    // If compilation failed (e.g. too many filters), return true because this
    // is only a pre-check.
    return !compiled || compiled.test(request);
  }

  _checkEntryMatchSimple(keyword, request, collection) {
    let filters = getFilters(this._simpleFiltersByKeyword, keyword);
    let {length} = filters;
    if (length) {
      // For simple filters where there's more than one filter to the keyword,
      // we do a quick check using a single compiled pattern that combines all
      // the patterns. This is a lot faster for requests that are not going to
      // be blocked (i.e. most requests).
      if (length === 1 ||
          this._checkEntryMatchSimpleQuickCheck(keyword, request, filters)) {
        for (let filter of filters) {
          // Simple filters match any resource type.
          if (matchFilter(filter, request, RESOURCE_TYPES, null, collection))
            return filter;
        }
      }
    }

    return null;
  }

  _checkEntryMatchForType(keyword, request, typeMask, sitekey, specificOnly,
                          collection) {
    let filtersForType = this._filterMapsByType.get(typeMask);
    if (filtersForType) {
      for (let filter of getFilters(filtersForType, keyword)) {
        if (specificOnly && filter.isGeneric())
          continue;

        if (matchFilter(filter, request, typeMask, sitekey, collection))
          return filter;
      }
    }

    return null;
  }

  _checkEntryMatchByDomain(keyword, request, typeMask, sitekey, specificOnly,
                           collection) {
    let filtersByDomain = this._filterDomainMapsByKeyword.get(keyword);
    if (filtersByDomain) {
      if (filtersByDomain instanceof FiltersByDomain) {
        if (keyword == "" && !specificOnly) {
          let compiled = this._keywordlessCompiledPatterns;

          // If the value is false, it indicates that we need to initialize it
          // to either a CompiledPatterns object or null.
          if (compiled == false) {
            // Compile all the patterns from the generic filters into a single
            // object. It is worth doing this for the keywordless generic
            // complex filters because they must be checked against every
            // single URL request that has not already been blocked by one of
            // the simple filters (i.e. most URL requests).
            let map = filtersByDomain.get("");
            if (map instanceof FilterMap)
              compiled = compilePatterns([...map.keys()]);

            this._keywordlessCompiledPatterns = compiled || null;
          }

          // We can skip the generic filters if none of them pass the test.
          if (compiled && !compiled.test(request))
            specificOnly = true;
        }

        return this._matchFiltersByDomain(
          filtersByDomain, request, typeMask, sitekey, specificOnly, collection
        );
      }

      // Because of the memory optimization in the add function, most of the
      // time this will be a filter rather than a map.

      // Also see #7312: If it's a single filter, it's always the equivalent of
      // Map { "" => Map { filter => true } } (i.e. applies to any domain). If
      // the specific-only flag is set, we skip it.
      if (!specificOnly) {
        return matchFilter(
          filtersByDomain, request, typeMask, sitekey, collection
        );
      }
    }

    return null;
  }

  /**
   * Checks whether the entries for a particular keyword match a URL
   * @param {string} keyword
   * @param {module:url.URLRequest} request
   * @param {number} typeMask
   * @param {?string} [sitekey]
   * @param {boolean} [specificOnly]
   * @param {?Array.<module:filterClasses.Filter>} [collection] An optional
   *   list of filters to which to append any results. If specified, the
   *   function adds *all* matching filters to the list; if omitted,
   *   the function directly returns the first matching filter.
   * @returns {?module:filterClasses.Filter}
   * @protected
   */
  checkEntryMatch(keyword, request, typeMask, sitekey, specificOnly,
                  collection) {
    // We need to skip the simple (location-only) filters if the type mask does
    // not contain any resource types.
    if (!specificOnly && (typeMask & RESOURCE_TYPES) != 0) {
      let filter = this._checkEntryMatchSimple(keyword, request, collection);
      if (filter)
        return filter;
    }

    // If the type mask contains a special type (first condition) and it is
    // the only type in the mask (second condition), we can use the
    // type-specific map, which typically contains a lot fewer filters. This
    // enables faster lookups for allowing types like $document, $elemhide,
    // and so on, as well as other special types like $csp.
    if ((typeMask & SPECIAL_TYPES) != 0 && (typeMask & typeMask - 1) == 0) {
      return this._checkEntryMatchForType(
        keyword, request, typeMask, sitekey, specificOnly, collection
      );
    }


    return this._checkEntryMatchByDomain(
      keyword, request, typeMask, sitekey, specificOnly, collection
    );
  }

  /**
   * @see #match
   * @deprecated
   * @inheritdoc
   */
  matchesAny(url, typeMask, docDomain, sitekey, specificOnly) {
    return this.match(url, typeMask, docDomain, sitekey, specificOnly);
  }

  /**
   * Tests whether the URL matches any of the known filters
   * @param {URL|module:url~URLInfo|string} url
   *   URL to be tested
   * @param {number} typeMask
   *   bitmask of content / request types to match
   * @param {?string} [docDomain]
   *   domain name of the document that loads the URL
   * @param {?string} [sitekey]
   *   public key provided by the document
   * @param {boolean} [specificOnly]
   *   should be `true` if generic matches should be ignored
   * @returns {?module:filterClasses.URLFilter}
   *   matching filter or `null`
   */
  match(url, typeMask, docDomain, sitekey, specificOnly) {
    let request = URLRequest.from(url, docDomain);
    let candidates = request.lowerCaseHref.match(/[a-z0-9%]{2,}|$/g);

    for (let i = 0, l = candidates.length; i < l; i++) {
      if (isBadKeyword(candidates[i]))
        continue;

      let result = this.checkEntryMatch(
        candidates[i], request, typeMask, sitekey, specificOnly
      );
      if (result)
        return result;
    }

    return null;
  }
};

class CombinedMatcher {
  constructor() {
    /**
     * Matcher for blocking rules.
     * @type {module:matcher.Matcher}
     * @private
     */
    this._blocking = new Matcher();

    /**
     * Matcher for exception rules.
     * @type {module:matcher.Matcher}
     * @private
     */
    this._allowing = new Matcher();

    /**
     * Lookup table of previous match results
     * @type {module:caching.Cache.<string, ?(module:filterClasses.URLFilter|
     *                                        MatcherSearchResults)>}
     * @private
     */
    this._resultCache = new Cache(10000);
  }

  /**
   * @see module:matcher.Matcher#clear
   */
  clear() {
    this._blocking.clear();
    this._allowing.clear();
    this._resultCache.clear();
  }

  /**
   * @see module:matcher.Matcher#add
   * @param {module:filterClasses.Filter} filter
   */
  add(filter) {
    if (filter.type == "allowing")
      this._allowing.add(filter);
    else
      this._blocking.add(filter);

    this._resultCache.clear();
  }

  /**
   * @see module:matcher.Matcher#remove
   * @param {module:filterClasses.Filter} filter
   */
  remove(filter) {
    if (filter.type == "allowing")
      this._allowing.remove(filter);
    else
      this._blocking.remove(filter);

    this._resultCache.clear();
  }

  /**
   * @see module:matcher.Matcher#has
   * @param {module:filterClasses.Filter} filter
   * @returns {boolean}
   */
  has(filter) {
    if (filter.type == "allowing")
      return this._allowing.has(filter);
    return this._blocking.has(filter);
  }

  /**
   * @see module:matcher.Matcher#findKeyword
   * @param {module:filterClasses.Filter} filter
   * @returns {string} keyword
   * @protected
   */
  findKeyword(filter) {
    if (filter.type == "allowing")
      return this._allowing.findKeyword(filter);
    return this._blocking.findKeyword(filter);
  }

  _matchInternal(url, typeMask, docDomain, sitekey, specificOnly,
                 exhaustiveSearch) {
    let request = URLRequest.from(url, docDomain);
    let candidates = request.lowerCaseHref.match(/[a-z0-9%]{2,}|$/g)
        .filter(candidate => !isBadKeyword(candidate));
    let typeIsOnlyAllowing = (typeMask & ~ALLOWING_TYPES) == 0;

    let allowingHit = null;
    let blockingHit = null;

    let findAllowing = () => {
      for (let i = 0, l = candidates.length; !allowingHit && i < l; i++) {
        allowingHit = this._allowing.checkEntryMatch(
          candidates[i], request, typeMask, sitekey
        );
      }
    };

    let findBlocking = () => {
      for (let i = 0, l = candidates.length; !blockingHit && i < l; i++) {
        blockingHit = this._blocking.checkEntryMatch(
          candidates[i], request, typeMask, sitekey, specificOnly
        );
      }
    };

    if (exhaustiveSearch) {
      findAllowing();
      if (!allowingHit && !typeIsOnlyAllowing)
        findBlocking();
    }
    else if (typeIsOnlyAllowing) {
      findAllowing();
    }
    else {
      findBlocking();
      if (blockingHit)
        findAllowing();
    }

    return allowingHit || blockingHit;
  }

  _searchInternal(url, typeMask, docDomain, sitekey, specificOnly, filterType) {
    let hits = {};

    let searchBlocking = filterType == "blocking" || filterType == "all";
    let searchAllowing = filterType == "allowing" || filterType == "all";

    if (searchBlocking)
      hits.blocking = [];

    if (searchAllowing)
      hits.allowing = [];

    // If the type mask includes no types other than allowing types, we
    // can skip the blocking filters.
    if ((typeMask & ~ALLOWING_TYPES) == 0)
      searchBlocking = false;

    let request = URLRequest.from(url, docDomain);
    let candidates = request.lowerCaseHref.match(/[a-z0-9%]{2,}|$/g);

    for (let i = 0, l = candidates.length; i < l; i++) {
      if (isBadKeyword(candidates[i]))
        continue;

      if (searchBlocking) {
        this._blocking.checkEntryMatch(
          candidates[i],
          request,
          typeMask,
          sitekey,
          specificOnly,
          hits.blocking
        );
      }


      if (searchAllowing) {
        this._allowing.checkEntryMatch(
          candidates[i], request, typeMask, sitekey, false, hits.allowing
        );
      }
    }

    return hits;
  }

  /**
   * @see #match
   * @deprecated
   * @inheritdoc
   */
  matchesAny(url, typeMask, docDomain, sitekey, specificOnly) {
    return this.match(url, typeMask, docDomain, sitekey, specificOnly);
  }

  /**
   * Tests whether the URL matches any of the known filters
   *
   * If both a blocking and an allowing filter matches, the allowing filter is
   * prioritized.
   *
   * If only an allowing filter matches, then the allowing filter will not be
   * returned unless it is one of the `{@link module:contentTypes.ALLOWING_TYPES
   * ALLOWING_TYPES}` used for exception rules only, or if `exhaustiveSearch` is
   * true. In other words, the allowing filter is only returned if it is
   * expected to change blocking behaviour.
   *
   * @param {URL|module:url~URLInfo|string} url
   *   URL to be tested
   * @param {number} typeMask
   *   bitmask of content / request types to match
   * @param {?string} [docDomain]
   *   domain name of the document that loads the URL
   * @param {?string} [sitekey]
   *   public key provided by the document
   * @param {boolean} [specificOnly]
   *   should be `true` if generic matches should be ignored
   * @param {boolean} [exhaustiveSearch=false]
   *   should return a matched allowing filter, even if the filter will have no
   *   effect on blocking behaviour
   * @returns {?module:filterClasses.URLFilter}
   *   matching filter or `null`
   */
  match(url, typeMask, docDomain, sitekey, specificOnly,
        exhaustiveSearch = false) {
    let key = `${url} ${typeMask} ${docDomain} ${sitekey} ${specificOnly} ${exhaustiveSearch}`;
    let result = this._resultCache.get(key);
    if (typeof result != "undefined")
      return result;

    result = this._matchInternal(
      url, typeMask, docDomain, sitekey, specificOnly, exhaustiveSearch
    );

    this._resultCache.set(key, result);

    return result;
  }

  /**
   * @typedef {Object} MatcherSearchResults
   * @property {Array.<module:filterClasses.BlockingFilter>} [blocking] List of
   *   blocking filters found.
   * @property {Array.<module:filterClasses.AllowingFilter>} [allowing] List
   *   of allowing filters found.
   */

  /**
   * Searches all blocking and allowing filters and returns results matching
   * the given parameters.
   *
   * @param {URL|module:url~URLInfo|string} url
   * @param {number} typeMask
   * @param {?string} [docDomain]
   * @param {?string} [sitekey]
   * @param {boolean} [specificOnly]
   * @param {string} [filterType] The types of filters to look for. This can be
   *   `"blocking"`, `"allowing"`, or `"all"` (default).
   *
   * @returns {MatcherSearchResults}
   */
  search(url, typeMask, docDomain, sitekey, specificOnly, filterType = "all") {
    let key = `* ${url} ${typeMask} ${docDomain} ${sitekey} ` +
              `${specificOnly} ${filterType}`;

    let result = this._resultCache.get(key);
    if (typeof result != "undefined")
      return result;

    result = this._searchInternal(
      url, typeMask, docDomain, sitekey, specificOnly, filterType
    );

    this._resultCache.set(key, result);

    return result;
  }

  /**
   * Tests whether the URL is allowlisted
   * @see module:matcher.Matcher#match
   * @inheritdoc
   * @returns {boolean}
   */
  isAllowlisted(url, typeMask, docDomain, sitekey) {
    return !!this._allowing.match(url, typeMask, docDomain, sitekey);
  }
}

/**
 * Combines a matcher for blocking and exception rules, automatically sorts
 * rules into two `{@link module:matcher.Matcher Matcher}` instances.
 */
exports.CombinedMatcher = CombinedMatcher;

/**
 * Create the `{@link module:matcher~CombinedMatcher CombinedMatcher}`
 * instance that should usually be used.
 * @returns {module:matcher.CombinedMatcher}
 */
exports.newDefaultMatcher = function() {
  return new CombinedMatcher();
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/notifications.js":
/*!***********************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/notifications.js ***!
  \***********************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_430891__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * @file Handles notifications.
 */

const {Prefs} = __nested_webpack_require_430891__(/*! prefs */ "./sdk/api/prefs.js");

const {MILLIS_IN_MINUTE, MILLIS_IN_HOUR, MILLIS_IN_DAY} = __nested_webpack_require_430891__(/*! ./time */ "./node_modules/adblockpluscore/lib/time.js");
const {Downloader, Downloadable} = __nested_webpack_require_430891__(/*! ./downloader */ "./node_modules/adblockpluscore/lib/downloader.js");
const {compareVersions} = __nested_webpack_require_430891__(/*! ./versions */ "./node_modules/adblockpluscore/lib/versions.js");
const {analytics} = __nested_webpack_require_430891__(/*! ./analytics */ "./node_modules/adblockpluscore/lib/analytics.js");
const {EventEmitter} = __nested_webpack_require_430891__(/*! ./events */ "./node_modules/adblockpluscore/lib/events.js");

const INITIAL_DELAY = 1 * MILLIS_IN_MINUTE;
const CHECK_INTERVAL = 1 * MILLIS_IN_HOUR;
const EXPIRATION_INTERVAL = 1 * MILLIS_IN_DAY;

/**
 * The default locale for the localization of notification texts.
 * @type {string}
 * @default
 */
const DEFAULT_LOCALE = "en-US";

/**
 * Returns the numerical severity of a notification.
 * @param {Object} notification The notification.
 * @returns {number} The numerical severity of the notification.
 */
function getNumericalSeverity(notification) {
  switch (notification.type) {
    case "information":
      return 0;
    case "newtab":
    case "relentless":
      return 1;
    case "critical":
      return 2;
  }

  return 0;
}

/**
 * Saves notification data to preferences.
 * @param {string} [key] The key to save.
 */
function saveNotificationData(key = "notificationdata") {
  // JSON values aren't saved unless they are assigned a different object.
  Prefs[key] = JSON.parse(JSON.stringify(Prefs[key]));
}

/**
 * Localizes a notification text.
 *
 * @param {Object} translations The set of translations from which to select
 *   the localization.
 * @param {string} locale The locale string to use for the selection. If no
 *   localized version is found in the `translations` object for the given
 *   locale, the
 *   {@link module:notifications~DEFAULT_LOCALE default locale} is used.
 *
 * @returns {*} The localized text; `undefined` if no localized version is
 *   found in the `translations` object.
 */
function localize(translations, locale) {
  if (locale in translations)
    return translations[locale];

  let languagePart = locale.substring(0, locale.indexOf("-"));
  if (languagePart && languagePart in translations)
    return translations[languagePart];

  return translations[DEFAULT_LOCALE];
}

function isValidNotification(notification) {
  // Only notifications that are meant to be opened in a new tab must
  // contain at least one URL to open.
  if (notification.type == "newtab" &&
      !(notification.links && notification.links.length > 0))
    return false;

  return true;
}

/**
 * `{@link module:notifications.notifications}` implementation.
 *
 * It also emits the named events `downloaded`, `ignored-category-added` and
 * `ignored-category-removed` built with `{@link module:events.EventEmitter
 *                                               EventEmitter}`
 */
class Notifications extends EventEmitter {
  /**
   * @hideconstructor
   */
  constructor() {
    super();

    /**
     * Whether the fetching of notifications has been started.
     * @private
     */
    this._started = false;

    /**
     * Whether all ignorable notifications should be ignored.
     * @type {boolean}
     */
    this.ignored = false;

    /**
     * The locale for the localization of notification texts.
     * @type {string}
     * @default {@link module:notifications~DEFAULT_LOCALE}
     */
    this.locale = DEFAULT_LOCALE;

    /**
     * The number to consider when performing the blockedTotalMin and
     * blockedTotalMax target checks.
     *
     * This property needs to be initialized at startup and updated
     * whenever a blocking filter matches. If set to null (default),
     * notifications using these target checks are ignored.
     *
     * If the deprecated preferences Prefs.show_statsinpopup and
     * Prefs.blocked_total exist they take precedence over this property.
     * @type {?number}
     */
    this.numBlocked = null;

    /**
     * Listeners for notifications to be shown.
     * @type {Set.<function>}
     * @private
     */
    this._showListeners = new Set();

    /**
     * Local notifications added via
     * `{@link module:notifications~Notifications#addNotification
     *         addNotification()}`.
     * @type {Set.<Object>}
     * @private
     */
    this._localNotifications = new Set();

    /**
     * The object providing actual downloading functionality.
     * @type {module:downloader.Downloader}
     * @private
     */
    this._downloader = new Downloader(this._getDownloadables.bind(this));

    this._downloader.onExpirationChange = this._onExpirationChange.bind(this);
    this._downloader.onDownloadSuccess = this._onDownloadSuccess.bind(this);
    this._downloader.onDownloadError = this._onDownloadError.bind(this);
    this._onBlockedTotal = this._onBlockedTotal.bind(this);
  }

  /**
   * Starts fetching notifications.
   *
   * No notifications are fetched until this function has been called at least
   * once.
   */
  start() {
    if (this._started)
      return;

    Prefs.on("blocked_total", this._onBlockedTotal);

    this._downloader.scheduleChecks(CHECK_INTERVAL, INITIAL_DELAY);
    this._started = true;
  }

  /**
   * Stops fetching notifications.
   */
  stop() {
    this._started = false;
    this._downloader.unscheduleChecks();

    Prefs.off("blocked_total", this._onBlockedTotal);
  }

  /**
   * Yields a `{@link module:downloader.Downloadable Downloadable}` instance
   * for the notifications download.
   * @yields {module:downloader.Downloadable}
   * @private
   */
  *_getDownloadables() {
    let {notificationurl: url, notificationdata} = Prefs;

    let downloadable = new Downloadable(url);

    if (analytics.isTrusted(url))
      downloadable.firstVersion = analytics.getFirstVersion();

    if (typeof notificationdata.lastError == "number")
      downloadable.lastError = notificationdata.lastError;
    if (typeof notificationdata.lastCheck == "number")
      downloadable.lastCheck = notificationdata.lastCheck;

    if (typeof notificationdata.data == "object" &&
        "version" in notificationdata.data)
      downloadable.lastVersion = notificationdata.data.version;

    if (typeof notificationdata.softExpiration == "number")
      downloadable.softExpiration = notificationdata.softExpiration;
    if (typeof notificationdata.hardExpiration == "number")
      downloadable.hardExpiration = notificationdata.hardExpiration;
    if (typeof notificationdata.downloadCount == "number")
      downloadable.downloadCount = notificationdata.downloadCount;

    yield downloadable;
  }

  _onExpirationChange(downloadable) {
    Prefs.notificationdata.lastCheck = downloadable.lastCheck;
    Prefs.notificationdata.softExpiration = downloadable.softExpiration;
    Prefs.notificationdata.hardExpiration = downloadable.hardExpiration;

    saveNotificationData();
  }

  _onDownloadSuccess(downloadable, responseText, errorCallback,
                     redirectCallback) {
    try {
      let data = JSON.parse(responseText);

      if (typeof data.version == "string" &&
          analytics.isTrusted(downloadable.redirectURL || downloadable.url))
        analytics.recordVersion(data.version);

      let notifications = [];
      for (let notification of data.notifications) {
        if (!isValidNotification(notification)) {
          console.warn(`Invalid notification with ID "${notification.id}"`);
          continue;
        }

        if ("severity" in notification) {
          if (!("type" in notification))
            notification.type = notification.severity;
          delete notification.severity;
        }

        notifications.push(notification);
      }
      data.notifications = notifications;

      Prefs.notificationdata.data = data;
    }
    catch (error) {
      console.warn(error);
      errorCallback("synchronize_invalid_data");
      return;
    }

    Prefs.notificationdata.lastError = 0;
    Prefs.notificationdata.downloadStatus = "synchronize_ok";
    [
      Prefs.notificationdata.softExpiration,
      Prefs.notificationdata.hardExpiration
    ] = this._downloader.processExpirationInterval(EXPIRATION_INTERVAL);
    Prefs.notificationdata.downloadCount = downloadable.downloadCount;

    saveNotificationData();

    this.emit("downloaded");
    this.showNext();
  }

  _onDownloadError(downloadable, downloadURL, error, responseStatus,
                   redirectCallback) {
    Prefs.notificationdata.lastError = Date.now();
    Prefs.notificationdata.downloadStatus = error;

    saveNotificationData();
  }

  _onBlockedTotal() {
    this.showNext();
  }

  /**
   * Adds a listener for notifications to be shown.
   * @param {function} listener Listener to be invoked when a notification is
   *   to be shown.
   */
  addShowListener(listener) {
    this._showListeners.add(listener);
  }

  /**
   * Removes the supplied listener.
   * @param {function} listener Listener that was added via
   *   `{@link module:notifications~Notifications#addShowListener
   *           addShowListener()}`.
   */
  removeShowListener(listener) {
    this._showListeners.delete(listener);
  }

  /**
   * Returns whether user preferences indicate that notifications
   * should be ignored.
   * @return {boolean}
   */
  shouldIgnoreNotifications() {
    return this.ignored ||
      Prefs.notifications_ignoredcategories.includes("*");
  }

  /**
   * Returns all local and remote notifications.
   * @returns {Array.<Object>} All local and remote notifications.
   * @private
   */
  _getNotifications() {
    let remoteNotifications = [];
    if (typeof Prefs.notificationdata.data == "object" &&
        Prefs.notificationdata.data.notifications instanceof Array)
      remoteNotifications = Prefs.notificationdata.data.notifications;

    return [...this._localNotifications, ...remoteNotifications];
  }

  /**
   * Determines which notification is to be shown next.
   * @returns {?object} The notification to be shown, or `null` if there is
   *   none.
   * @private
   */
  _getNextToShow() {
    let notifications = this._getNotifications();
    if (notifications.length == 0)
      return null;

    const {addonName, addonVersion, application, applicationVersion,
           platform, platformVersion} = __nested_webpack_require_430891__(/*! info */ "./sdk/api/info.js");

    let {numBlocked} = this;
    // Compatibility for legacy adblockpluschrome
    if ("blocked_total" in Prefs)
      numBlocked = Prefs.blocked_total;
    if (Prefs.show_statsinpopup === false)
      numBlocked = null;

    let targetChecks = {
      extension: v => v == addonName,
      extensionMinVersion:
        v => compareVersions(addonVersion, v) >= 0,
      extensionMaxVersion:
        v => compareVersions(addonVersion, v) <= 0,
      application: v => v == application,
      applicationMinVersion:
        v => compareVersions(applicationVersion, v) >= 0,
      applicationMaxVersion:
        v => compareVersions(applicationVersion, v) <= 0,
      platform: v => v == platform,
      platformMinVersion:
        v => compareVersions(platformVersion, v) >= 0,
      platformMaxVersion:
        v => compareVersions(platformVersion, v) <= 0,
      blockedTotalMin: v => numBlocked != null && numBlocked >= v,
      blockedTotalMax: v => numBlocked != null && numBlocked <= v,
      locales: v => v.includes(this.locale)
    };

    let notificationToShow = null;
    for (let notification of notifications) {
      if (notification.type != "critical") {
        let shown;
        if (typeof Prefs.notificationdata.shown == "object")
          shown = Prefs.notificationdata.shown[notification.id];

        if (typeof shown != "undefined") {
          if (typeof notification.interval == "number") {
            if (shown + notification.interval > Date.now())
              continue;
          }
          else if (shown) {
            continue;
          }
        }

        if (notification.type != "relentless" &&
            this.shouldIgnoreNotifications())
          continue;
      }

      if (notification.targets instanceof Array) {
        let match = false;

        for (let target of notification.targets) {
          let keys = Object.keys(target);
          if (keys.every(
            key => Object.prototype.hasOwnProperty.call(targetChecks, key) &&
                   targetChecks[key](target[key]))
          ) {
            match = true;
            break;
          }
        }

        if (!match)
          continue;
      }

      if (!notificationToShow || getNumericalSeverity(notification) >
                                 getNumericalSeverity(notificationToShow))
        notificationToShow = notification;
    }

    return notificationToShow;
  }

  /**
   * Shows a notification once.
   * @param {Object} notification The notification to show.
   * @param {Object} [options]
   * @param {boolean} [options.ignorable=false] If true, user preference will
   *   be considered to determine whether notification should be shown.
   */
  showNotification(notification, options = {}) {
    if (options.ignorable && this.shouldIgnoreNotifications())
      return;

    for (let showListener of this._showListeners)
      showListener(notification);
  }

  /**
   * Invokes the listeners added via
   * `{@link module:notifications~Notifications#addShowListener
   *         addShowListener()}` with the next notification to be shown.
   *
   * This method should be called whenever a page loads.
   */
  showNext() {
    let notification = this._getNextToShow();
    if (notification) {
      for (let showListener of this._showListeners)
        showListener(notification);
    }
  }

  /**
   * Marks a notification as shown.
   * @param {string} id The ID of the notification to be marked as shown.
   */
  markAsShown(id) {
    let notifications = this._getNotifications();

    // Ignore if there's no notification with the given ID.
    if (!notifications.some(notification => notification.id == id))
      return;

    let now = Date.now();
    let data = Prefs.notificationdata;

    if (data.shown instanceof Array) {
      let newShown = {};
      for (let oldId of data.shown)
        newShown[oldId] = now;
      data.shown = newShown;
    }

    if (typeof data.shown != "object")
      data.shown = {};

    data.shown[id] = now;

    saveNotificationData();
  }

  /**
   * Localizes the texts of the given notification based on the
   * {@link module:notifications~Notifications#locale locale}.
   * @param {Object} notification The notification.
   * @returns {Object} The localized texts.
   */
  getLocalizedTexts(notification) {
    let textKeys = ["title", "message"];
    let localizedTexts = {};

    for (let key of textKeys) {
      if (key in notification) {
        if (typeof notification[key] == "string")
          localizedTexts[key] = notification[key];
        else
          localizedTexts[key] = localize(notification[key], this.locale);
      }
    }

    return localizedTexts;
  }

  /**
   * Adds a local notification.
   * @param {Object} notification The notification to add.
   */
  addNotification(notification) {
    if (!isValidNotification(notification))
      throw new Error(`Invalid notification with ID "${notification.id}"`);

    this._localNotifications.add(notification);
  }

  /**
   * Removes an existing local notification.
   * @param {Object} notification The notification to remove.
   */
  removeNotification(notification) {
    this._localNotifications.delete(notification);
  }

  /**
   * Toggles whether notifications of a specific category should be ignored.
   * @param {string} category The notification category identifier.
   * @param {boolean} [forceValue] Whether to force the specified value.
   */
  toggleIgnoreCategory(category, forceValue) {
    let categories = Prefs.notifications_ignoredcategories;
    let index = categories.indexOf(category);
    if (index == -1 && forceValue != false) {
      categories.push(category);
      this.emit("ignored-category-added", category);
    }
    else if (index != -1 && forceValue != true) {
      categories.splice(index, 1);
      this.emit("ignored-category-removed", category);
    }

    saveNotificationData("notifications_ignoredcategories");
  }

  /**
   * Returns the number of times the notifications data have been downloaded.
   * @returns {number}
   */
  getDownloadCount() {
    return Prefs.notificationdata.downloadCount || 0;
  }

  /**
   * Returns the list of ignored categories.
   * @returns {Array.<string>}
   */
  getIgnoredCategories() {
    return Prefs.notifications_ignoredcategories;
  }
}

/**
 * Regularly fetches notifications and decides which notification to show.
 * @type {module:notifications~Notifications}
 */
exports.notifications = new Notifications();


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/patterns.js":
/*!******************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/patterns.js ***!
  \******************************************************/
/***/ ((__unused_webpack_module, exports) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * The maximum number of patterns that
 * `{@link module:patterns.compilePatterns compilePatterns()}` will compile
 * into regular expressions.
 * @type {number}
 */
const COMPILE_PATTERNS_MAX = 100;

/**
 * Regular expression used to match the `^` suffix in an otherwise literal
 * pattern.
 * @type {RegExp}
 */
let separatorRegExp = /[\x00-\x24\x26-\x2C\x2F\x3A-\x40\x5B-\x5E\x60\x7B-\x7F]/;

let filterToRegExp =
/**
 * Converts filter text into regular expression string
 * @param {string} text as in Filter()
 * @return {string} regular expression representation of filter text
 * @package
 */
exports.filterToRegExp = function filterToRegExp(text) {
  // remove multiple wildcards
  text = text.replace(/\*+/g, "*");

  // remove leading wildcard
  if (text[0] == "*")
    text = text.substring(1);

  // remove trailing wildcard
  if (text[text.length - 1] == "*")
    text = text.substring(0, text.length - 1);

  return text
    // remove anchors following separator placeholder
    .replace(/\^\|$/, "^")
    // escape special symbols
    .replace(/\W/g, "\\$&")
    // replace wildcards by .*
    .replace(/\\\*/g, ".*")
    // process separator placeholders (all ANSI characters but alphanumeric
    // characters and _%.-)
    .replace(/\\\^/g, `(?:${separatorRegExp.source}|$)`)
    // process extended anchor at expression start
    .replace(/^\\\|\\\|/, "^[\\w\\-]+:\\/+(?:[^\\/]+\\.)?")
    // process anchor at expression start
    .replace(/^\\\|/, "^")
    // process anchor at expression end
    .replace(/\\\|$/, "$");
};

/**
 * Regular expression used to match the `||` prefix in an otherwise literal
 * pattern.
 * @type {RegExp}
 */
let extendedAnchorRegExp = new RegExp(filterToRegExp("||") + "$");

/**
 * Regular expression for matching a keyword in a filter.
 * @type {RegExp}
 */
let keywordRegExp = /[^a-z0-9%*][a-z0-9%]{2,}(?=[^a-z0-9%*])/;

/**
 * Regular expression for matching all keywords in a filter.
 * @type {RegExp}
 */
let allKeywordsRegExp = new RegExp(keywordRegExp, "g");

/**
 * A `CompiledPatterns` object represents the compiled version of multiple URL
 * request patterns. It is returned by
 * `{@link module:patterns.compilePatterns compilePatterns()}`.
 */
class CompiledPatterns {
  /**
   * Creates an object with the given regular expressions for case-sensitive
   * and case-insensitive matching respectively.
   * @param {?RegExp} [caseSensitive]
   * @param {?RegExp} [caseInsensitive]
   * @private
   */
  constructor(caseSensitive, caseInsensitive) {
    this._caseSensitive = caseSensitive;
    this._caseInsensitive = caseInsensitive;
  }

  /**
   * Tests whether the given URL request matches the patterns used to create
   * this object.
   * @param {module:url.URLRequest} request
   * @returns {boolean}
   */
  test(request) {
    return ((this._caseSensitive &&
             this._caseSensitive.test(request.href)) ||
            (this._caseInsensitive &&
             this._caseInsensitive.test(request.lowerCaseHref)));
  }
}

/**
 * Compiles patterns from the given filters into a single
 * `{@link module:patterns~CompiledPatterns CompiledPatterns}` object.
 *
 * @param {module:filterClasses.URLFilter|
 *         Set.<module:filterClasses.URLFilter>} filters
 *   The filters. If the number of filters exceeds
 *   `{@link module:patterns~COMPILE_PATTERNS_MAX COMPILE_PATTERNS_MAX}`, the
 *   function returns `null`.
 *
 * @returns {?module:patterns~CompiledPatterns}
 *
 * @package
 */
exports.compilePatterns = function compilePatterns(filters) {
  let list = Array.isArray(filters) ? filters : [filters];

  // If the number of filters is too large, it may choke especially on low-end
  // platforms. As a precaution, we refuse to compile. Ideally we would check
  // the length of the regular expression source rather than the number of
  // filters, but this is far more straightforward and practical.
  if (list.length > COMPILE_PATTERNS_MAX)
    return null;

  let caseSensitive = "";
  let caseInsensitive = "";

  for (let filter of filters) {
    let source = filter.urlPattern.regexpSource;

    if (filter.matchCase)
      caseSensitive += source + "|";
    else
      caseInsensitive += source + "|";
  }

  let caseSensitiveRegExp = null;
  let caseInsensitiveRegExp = null;

  try {
    if (caseSensitive)
      caseSensitiveRegExp = new RegExp(caseSensitive.slice(0, -1));

    if (caseInsensitive)
      caseInsensitiveRegExp = new RegExp(caseInsensitive.slice(0, -1));
  }
  catch (error) {
    // It is possible in theory for the regular expression to be too large
    // despite COMPILE_PATTERNS_MAX
    return null;
  }

  return new CompiledPatterns(caseSensitiveRegExp, caseInsensitiveRegExp);
};

/**
 * Patterns for matching against URLs.
 *
 * Internally, this may be a RegExp or match directly against the
 * pattern for simple literal patterns.
 */
exports.Pattern = class Pattern {
  /**
   * @param {string} pattern pattern that requests URLs should be
   * matched against in filter text notation
   * @param {bool} matchCase `true` if comparisons must be case
   * sensitive
   */
  constructor(pattern, matchCase) {
    this.matchCase = matchCase || false;

    if (!this.matchCase)
      pattern = pattern.toLowerCase();

    if (pattern.length >= 2 &&
        pattern[0] == "/" &&
        pattern[pattern.length - 1] == "/") {
      // The filter is a regular expression - convert it immediately to
      // catch syntax errors
      pattern = pattern.substring(1, pattern.length - 1);
      this._regexp = new RegExp(pattern);
    }
    else {
      // Patterns like /foo/bar/* exist so that they are not treated as regular
      // expressions. We drop any superfluous wildcards here so our
      // optimizations can kick in.
      pattern = pattern.replace(/^\*+/, "").replace(/\*+$/, "");

      // No need to convert this filter to regular expression yet, do it on
      // demand
      this.pattern = pattern;
    }
  }

  /**
   * Checks whether the pattern is a string of literal characters with
   * no wildcards or any other special characters.
   *
   * If the pattern is prefixed with a `||` or suffixed with a `^` but otherwise
   * contains no special characters, it is still considered to be a literal
   * pattern.
   *
   * @returns {boolean}
   */
  isLiteralPattern() {
    return typeof this.pattern !== "undefined" &&
      !/[*^|]/.test(this.pattern.replace(/^\|{1,2}/, "").replace(/[|^]$/, ""));
  }

  /**
   * Regular expression to be used when testing against this pattern.
   *
   * null if the pattern is matched without using regular expressions.
   * @type {RegExp}
   */
  get regexp() {
    if (typeof this._regexp == "undefined") {
      this._regexp = this.isLiteralPattern() ?
        null : new RegExp(filterToRegExp(this.pattern));
    }
    return this._regexp;
  }

  /**
   * Pattern in regular expression notation. This will have a value
   * even if `regexp` returns null.
   * @type {string}
   */
  get regexpSource() {
    return this._regexp ? this._regexp.source : filterToRegExp(this.pattern);
  }

  /**
   * Checks whether the given URL request matches this filter's pattern.
   * @param {module:url.URLRequest} request The URL request to check.
   * @returns {boolean} `true` if the URL request matches.
   */
  matchesLocation(request) {
    let location = this.matchCase ? request.href : request.lowerCaseHref;
    let regexp = this.regexp;
    if (regexp)
      return regexp.test(location);

    let pattern = this.pattern;
    let startsWithAnchor = pattern[0] == "|";
    let startsWithExtendedAnchor = startsWithAnchor && pattern[1] == "|";
    let endsWithSeparator = pattern[pattern.length - 1] == "^";
    let endsWithAnchor = !endsWithSeparator &&
        pattern[pattern.length - 1] == "|";

    if (startsWithExtendedAnchor)
      pattern = pattern.substr(2);
    else if (startsWithAnchor)
      pattern = pattern.substr(1);

    if (endsWithSeparator || endsWithAnchor)
      pattern = pattern.slice(0, -1);

    let index = location.indexOf(pattern);

    while (index != -1) {
      // The "||" prefix requires that the text that follows does not start
      // with a forward slash.
      if ((startsWithExtendedAnchor ?
           location[index] != "/" &&
           extendedAnchorRegExp.test(location.substring(0, index)) :
           startsWithAnchor ?
           index == 0 :
           true) &&
          (endsWithSeparator ?
           !location[index + pattern.length] ||
           separatorRegExp.test(location[index + pattern.length]) :
           endsWithAnchor ?
           index == location.length - pattern.length :
           true))
        return true;

      if (pattern == "")
        return true;

      index = location.indexOf(pattern, index + 1);
    }

    return false;
  }

  /**
   * Checks whether the pattern has keywords
   * @returns {boolean}
   */
  hasKeywords() {
    return this.pattern && keywordRegExp.test(this.pattern);
  }

  /**
   * Finds all keywords that could be associated with this pattern
   * @returns {string[]}
   */
  keywordCandidates() {
    if (!this.pattern)
      return null;
    return this.pattern.toLowerCase().match(allKeywordsRegExp);
  }
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/polyfill.js":
/*!******************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/polyfill.js ***!
  \******************************************************/
/***/ (() => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */



// Promise.prototype.finally is not supported in Firefox < 58
if (!Promise.prototype.finally) {
  Promise.prototype.finally = function(fn) {
    return this.then(fn, fn);
  };
}


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/profiler.js":
/*!******************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/profiler.js ***!
  \******************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_460297__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/* eslint no-console: "off" */
/* global self */

/** @module */



const {performance, PerformanceObserver} = __nested_webpack_require_460297__(/*! perf_hooks */ "perf_hooks");

/**
 * Default profiler("...") returned object when profile mode is disabled.
 * @type {Profiler}
 * @private
 */
let noopProfiler = {
  start() {},
  mark() {},
  end() {},
  toString() {
    return "{start(){},mark(){},end(){}}";
  }
};

let inactiveProfiling = true;
let obs = null;

/** Enable or disable profiling
 *
 * @param {bool} enable the profiling is enabled. If true it will
 * create a PerformanceObserver and start observing, profiler() will then
 * create a proper profiler object. If false, observing is cancelled and
 * the profiler object will be a noop.
 * @param {?Function} reporter The reporter function called by the observer.
 * If falsy, the default reporter will be used.
 */
function enableProfiling(enable, reporter) {
  inactiveProfiling = !enable;
  if (enable) {
    performance.mark("start_profile");
    if (!reporter) {
      reporter = list => {
        for (let entry of list.getEntriesByType("measure"))
          console.log(`${entry.name}: ${entry.duration}ms`);
      };
    }
    obs = new PerformanceObserver(reporter);

    obs.observe({entryTypes: ["measure"]});
  }
  else if (obs) {
    obs.disconnect();
    obs = null;
  }
}

/**
 * Create a profiler object with `start()` `mark()` and `end()` methods to
 * either start, keep marking a specific profiled name, or ending it.
 *
 * @example
 * let {mark, end} = profiler('console.log');
 * mark();
 * console.log(1, 2, 3);
 * end();
 *
 * @param {string} id the unique ID to profile.
 * @returns {Profiler} The profiler with `start()`, `mark()` and
 * `end(clear = false)` methods.
 * @private
 */
function profiler(id) {
  if (inactiveProfiling)
    return noopProfiler;

  return {
    id,
    start() {
      performance.mark(`${id}:start`);
      performance.measure(`${id}:startup`, "start_profile", `${id}:start`);
    },
    mark(event) {
      performance.mark(`${id}:${event}`);
      performance.measure(
        `${id}:${event}_measure`, "start_profile", `${id}:${event}`
      );
    },
    end() {
      performance.mark(`${id}:end`);
      performance.measure(id, "start_profile", `${id}:end`);
    }
  };
}

function isProfilingEnabled() {
  return !inactiveProfiling;
}

exports.profiler = profiler;
exports.enable = enableProfiling;
exports.isEnabled = isProfilingEnabled;


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/recommendations.js":
/*!*************************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/recommendations.js ***!
  \*************************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_463806__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * A `Recommendation` object represents a recommended filter subscription.
 */
class Recommendation {
  /**
   * Creates a `Recommendation` object from the given source object.
   * @param {object} source The source object.
   * @private
   */
  constructor(source) {
    this._source = source;
  }

  /**
   * The id (UUID) of the subscription.
   * If the id is not null, there is a 1:1 relationship with `id` : `url`.
   * @type {?string}
   */
  get id() {
    return this._source.id;
  }

  /**
   * The required subscription ids.
   * @type {?Array.<string>}
   */
  get requires() {
    return this._source.requires;
  }

  /**
   * The type of the recommended filter subscription.
   * @type {string}
   */
  get type() {
    return this._source.type;
  }

  /**
   * The languages of the recommended filter subscription.
   * @type {Array.<string>}
   */
  get languages() {
    return this._source.languages ? [...this._source.languages] : [];
  }

  /**
   * The title of the recommended filter subscription.
   * @type {string}
   */
  get title() {
    return this._source.title;
  }

  /**
   * The URL of the recommended filter subscription.
   * @type {string}
   */
  get url() {
    return this._source.url;
  }

  /**
   * The home page of the recommended filter subscription.
   * @type {string}
   */
  get homepage() {
    return this._source.homepage;
  }

  /**
   * The manifest v2 URL
   * @type {?string}
   */
  get mv2URL() {
    return this._source.mv2_url;
  }
}

let _recommendations = null;

/**
 * Set the recommendations. This is required. It should be done before
 * any other operation on subscriptions, and shouldn't be called more
 * than once.
 *
 * @param {object} recommendations The available recommended subscriptions.
 */
exports.setRecommendations = function(recommendations) {
  _recommendations = recommendations;
};

/**
 * Yields `{@link module:recommendations~Recommendation Recommendation}` objects
 * representing recommended filter subscriptions.
 *
 * @generator
 * @yields {module:recommendations~Recommendation} An object representing a
 *   recommended filter subscription.
 */
exports.recommendations = function* recommendations() {
  if (!_recommendations)
    _recommendations = __nested_webpack_require_463806__(/*! ../data/subscriptions.json */ "./node_modules/adblockpluscore/data/subscriptions.json");

  for (let source of _recommendations)
    yield new Recommendation(source);
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/rsa.js":
/*!*************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/rsa.js ***!
  \*************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_467270__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/* global crypto, TextEncoder */

/** @module */



const Rusha = __nested_webpack_require_467270__(/*! ./rusha.js */ "./node_modules/adblockpluscore/lib/rusha.js");
const {BigInteger} = __nested_webpack_require_467270__(/*! ./jsbn.js */ "./node_modules/adblockpluscore/lib/jsbn.js");

/**
 * @file Provides ASN.1 sitekeys verifications.
 */

let base64ToArrayBuffer =
/**
 * Converts a base64 string to an array buffer byte array.
 * @param {string} base64 Base64 encoded string.
 * @return {Uint8Array} The same data, encoded as an array buffer.
 */
exports.base64ToArrayBuffer = function base64ToArrayBuffer(base64) {
  let binaryString = atob(base64);
  return Uint8Array.from(binaryString, c => c.charCodeAt(0));
};

/**
 * Converts an array buffer byte array into a base64 string.
 * @param {Uint8Array} buffer Byte array of any data.
 * @return {string} The same data, encoded as a base64 string.
 */
exports.arrayBufferToBase64 = function arrayBufferToBase64(buffer) {
  let binary = "";
  let bytes = new Uint8Array(buffer);
  for (let i = 0; i < bytes.byteLength; i++)
    binary += String.fromCharCode(bytes[i]);

  return btoa(binary);
};

/**
 * Checks whether the signature is valid for the given public key and data.
 * The verification is based on ASN.1 over SHA-1. This procedure is known as
 * RSA_PKCS1_SHA1 and it is the default kind of procedure, in OpenSSL, when
 * SEC_OID_ISO_SHA_WITH_RSA_SIGNATURE is used to create the key/signature pair.
 * @param {string} key a base 64 public key used to verify.
 * @param {string} signature a base 64 signature used to verify.
 * @param {string} data a unique identifier of the resource to verify.
 * @returns {Promise<boolean>} resolves with true if the signature is valid
 */
exports.verifySignature = async function verifySignature(key, signature, data) {
  let signAlgorithm = {
    name: "RSASSA-PKCS1-v1_5",
    hash: {name: "SHA-1"}
  };
  try {
    return await crypto.subtle.verify(
      signAlgorithm,
      await crypto.subtle.importKey(
        "spki",
        base64ToArrayBuffer(key),
        signAlgorithm,
        true,
        ["verify"]
      ),
      base64ToArrayBuffer(signature),
      new TextEncoder().encode(data)
    );
  }
  catch ({message}) {
    console.warn("Invalid encrypted signature: " + message);
    return false;
  }
};

// Define ASN.1 templates for the data structures used
function seq(...args) {
  return {type: 0x30, children: args};
}
function obj(id) {
  return {type: 0x06, content: id};
}
function bitStr(contents) {
  return {type: 0x03, encapsulates: contents};
}
function intResult(id) {
  return {type: 0x02, out: id};
}
function octetResult(id) {
  return {type: 0x04, out: id};
}

// See http://www.cryptopp.com/wiki/Keys_and_Formats#RSA_PublicKey
// 2A 86 48 86 F7 0D 01 01 01 means 1.2.840.113549.1.1.1
let publicKeyTemplate = seq(
  seq(obj("\x2A\x86\x48\x86\xF7\x0D\x01\x01\x01"), {}),
  bitStr(seq(intResult("n"), intResult("e")))
);

// See http://tools.ietf.org/html/rfc3447#section-9.2 step 2
// 2B 0E 03 02 1A means 1.3.14.3.2.26
let signatureTemplate = seq(
  seq(obj("\x2B\x0E\x03\x02\x1A"), {}),
  octetResult("sha1")
);

/**
 * Reads ASN.1 data matching the template passed in. This will throw an
 * exception if the data format doesn't match the template. On success an
 * object containing result properties is returned.
 * @see http://luca.ntop.org/Teaching/Appunti/asn1.html for info on the format.
 * @param {string} data
 * @param {Object} templ
 * @returns {Object}
 */
function readASN1(data, templ) {
  let pos = 0;
  function next() {
    return data.charCodeAt(pos++);
  }

  function readLength() {
    let len = next();
    if (len & 0x80) {
      let cnt = len & 0x7F;
      if (cnt > 2 || cnt == 0)
        throw "Unsupported length";

      len = 0;
      for (let i = 0; i < cnt; i++)
        len += next() << (cnt - 1 - i) * 8;
      return len;
    }
    return len;
  }

  function readNode(curTempl) {
    let type = next();
    let len = readLength();
    if ("type" in curTempl && curTempl.type != type)
      throw "Unexpected type";
    if ("content" in curTempl &&
        curTempl.content != data.substring(pos, pos + len))
      throw "Unexpected content";
    if ("out" in curTempl)
      out[curTempl.out] = new BigInteger(data.substring(pos, pos + len), 256);
    if ("children" in curTempl) {
      let i;
      let end;
      for (i = 0, end = pos + len; pos < end; i++) {
        if (i >= curTempl.children.length)
          throw "Too many children";
        readNode(curTempl.children[i]);
      }
      if (i < curTempl.children.length)
        throw "Too few children";
      if (pos > end)
        throw "Children too large";
    }
    else if ("encapsulates" in curTempl) {
      if (next() != 0)
        throw "Encapsulation expected";
      readNode(curTempl.encapsulates);
    }
    else {
      pos += len;
    }
  }

  let out = {};
  readNode(templ);
  if (pos != data.length)
    throw "Too much data";
  return out;
}

/**
 * Reads a BER-encoded RSA public key. On success returns an object with the
 * properties n and e (the components of the key), otherwise null.
 * @param {string} key
 * @return {?Object}
 */
function readPublicKey(key) {
  try {
    return readASN1(atob(key), publicKeyTemplate);
  }
  catch (e) {
    console.warn("Invalid RSA public key: " + e);
    return null;
  }
}

let rusha;

/**
 * Checks whether the signature is valid for the given public key and data.
 * The verification is based on ASN.1 over SHA-1. This procedure is known as
 * RSA_PKCS1_SHA1 and it is the default kind of procedure, in OpenSSL, when
 * SEC_OID_ISO_SHA_WITH_RSA_SIGNATURE is used to create the key/signature pair.
 *
 * This function is synchronous, and so does not return a
 * promise. It's recommended to use the asynchronous version,
 * `{@link module:rsa.verifySignature verifySignature}`, if possible.
 * @param {string} key a base 64 public key used to verify.
 * @param {string} signature a base 64 signature used to verify.
 * @param {string} data a unique identifier of the resource to verify.
 * @returns {boolean} true if the signature is valid.
 */
exports.verifySignatureSync =
function verifySignatureSync(key, signature, data) {
  if (typeof rusha == "undefined")
    rusha = new Rusha();

  let keyData = readPublicKey(key);
  if (!keyData)
    return false;

  // We need the exponent as regular number
  keyData.e = parseInt(keyData.e.toString(16), 16);

  // Decrypt signature data using RSA algorithm
  let sigInt = new BigInteger(atob(signature), 256);
  let digest = sigInt.modPowInt(keyData.e, keyData.n).toString(256);

  try {
    let pos = 0;
    let next = () => digest.charCodeAt(pos++);

    // Skip padding, see http://tools.ietf.org/html/rfc3447#section-9.2 step 5
    if (next() != 1)
      throw "Wrong padding in signature digest";
    while (next() == 255) {}
    if (digest.charCodeAt(pos - 1) != 0)
      throw "Wrong padding in signature digest";

    // Rest is an ASN.1 structure, get the SHA1 hash from it and compare to
    // the real one
    let {sha1} = readASN1(digest.substring(pos), signatureTemplate);
    let expected = new BigInteger(rusha.digest(data), 16);
    return (sha1.compareTo(expected) == 0);
  }
  catch (e) {
    console.warn("Invalid encrypted signature: " + e);
    return false;
  }
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/rusha.js":
/*!***************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/rusha.js ***!
  \***************************************************/
/***/ ((module, exports, __nested_webpack_require_475578__) => {

(function () {
    var /*
 * Rusha, a JavaScript implementation of the Secure Hash Algorithm, SHA-1,
 * as defined in FIPS PUB 180-1, tuned for high performance with large inputs.
 * (http://github.com/srijs/rusha)
 *
 * Inspired by Paul Johnstons implementation (http://pajhome.org.uk/crypt/md5).
 *
 * Copyright (c) 2013 Sam Rijs (http://awesam.de).
 * Released under the terms of the MIT license as follows:
 *
 * Permission is hereby granted, free of charge, to any person obtaining a
 * copy of this software and associated documentation files (the "Software"),
 * to deal in the Software without restriction, including without limitation
 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
 * and/or sell copies of the Software, and to permit persons to whom the
 * Software is furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
 * IN THE SOFTWARE.
 */
    util = {
        getDataType: function (data) {
            if (typeof data === 'string') {
                return 'string';
            }
            if (data instanceof Array) {
                return 'array';
            }
            if (typeof __nested_webpack_require_475578__.g !== 'undefined' && __nested_webpack_require_475578__.g.Buffer && __nested_webpack_require_475578__.g.Buffer.isBuffer(data)) {
                return 'buffer';
            }
            if (data instanceof ArrayBuffer) {
                return 'arraybuffer';
            }
            if (data.buffer instanceof ArrayBuffer) {
                return 'view';
            }
            if (data instanceof Blob) {
                return 'blob';
            }
            throw new Error('Unsupported data type.');
        }
    };
    function Rusha(chunkSize) {
        'use strict';
        var // Private object structure.
        self$2 = { fill: 0 };
        var // Calculate the length of buffer that the sha1 routine uses
        // including the padding.
        padlen = function (len) {
            for (len += 9; len % 64 > 0; len += 1);
            return len;
        };
        var padZeroes = function (bin, len) {
            for (var i$2 = len >> 2; i$2 < bin.length; i$2++)
                bin[i$2] = 0;
        };
        var padData = function (bin, chunkLen, msgLen) {
            bin[chunkLen >> 2] |= 128 << 24 - (chunkLen % 4 << 3);
            // To support msgLen >= 2 GiB, use a float division when computing the
            // high 32-bits of the big-endian message length in bits.
            bin[((chunkLen >> 2) + 2 & ~15) + 14] = msgLen / (1 << 29) | 0;
            bin[((chunkLen >> 2) + 2 & ~15) + 15] = msgLen << 3;
        };
        var // Convert a binary string and write it to the heap.
        // A binary string is expected to only contain char codes < 256.
        convStr = function (H8, H32, start, len, off) {
            var str = this, i$2, om = off % 4, lm = len % 4, j = len - lm;
            if (j > 0) {
                switch (om) {
                case 0:
                    H8[off + 3 | 0] = str.charCodeAt(start);
                case 1:
                    H8[off + 2 | 0] = str.charCodeAt(start + 1);
                case 2:
                    H8[off + 1 | 0] = str.charCodeAt(start + 2);
                case 3:
                    H8[off | 0] = str.charCodeAt(start + 3);
                }
            }
            for (i$2 = om; i$2 < j; i$2 = i$2 + 4 | 0) {
                H32[off + i$2 >> 2] = str.charCodeAt(start + i$2) << 24 | str.charCodeAt(start + i$2 + 1) << 16 | str.charCodeAt(start + i$2 + 2) << 8 | str.charCodeAt(start + i$2 + 3);
            }
            switch (lm) {
            case 3:
                H8[off + j + 1 | 0] = str.charCodeAt(start + j + 2);
            case 2:
                H8[off + j + 2 | 0] = str.charCodeAt(start + j + 1);
            case 1:
                H8[off + j + 3 | 0] = str.charCodeAt(start + j);
            }
        };
        var // Convert a buffer or array and write it to the heap.
        // The buffer or array is expected to only contain elements < 256.
        convBuf = function (H8, H32, start, len, off) {
            var buf = this, i$2, om = off % 4, lm = len % 4, j = len - lm;
            if (j > 0) {
                switch (om) {
                case 0:
                    H8[off + 3 | 0] = buf[start];
                case 1:
                    H8[off + 2 | 0] = buf[start + 1];
                case 2:
                    H8[off + 1 | 0] = buf[start + 2];
                case 3:
                    H8[off | 0] = buf[start + 3];
                }
            }
            for (i$2 = 4 - om; i$2 < j; i$2 = i$2 += 4 | 0) {
                H32[off + i$2 >> 2] = buf[start + i$2] << 24 | buf[start + i$2 + 1] << 16 | buf[start + i$2 + 2] << 8 | buf[start + i$2 + 3];
            }
            switch (lm) {
            case 3:
                H8[off + j + 1 | 0] = buf[start + j + 2];
            case 2:
                H8[off + j + 2 | 0] = buf[start + j + 1];
            case 1:
                H8[off + j + 3 | 0] = buf[start + j];
            }
        };
        var convBlob = function (H8, H32, start, len, off) {
            var blob = this, i$2, om = off % 4, lm = len % 4, j = len - lm;
            var buf = new Uint8Array(reader.readAsArrayBuffer(blob.slice(start, start + len)));
            if (j > 0) {
                switch (om) {
                case 0:
                    H8[off + 3 | 0] = buf[0];
                case 1:
                    H8[off + 2 | 0] = buf[1];
                case 2:
                    H8[off + 1 | 0] = buf[2];
                case 3:
                    H8[off | 0] = buf[3];
                }
            }
            for (i$2 = 4 - om; i$2 < j; i$2 = i$2 += 4 | 0) {
                H32[off + i$2 >> 2] = buf[i$2] << 24 | buf[i$2 + 1] << 16 | buf[i$2 + 2] << 8 | buf[i$2 + 3];
            }
            switch (lm) {
            case 3:
                H8[off + j + 1 | 0] = buf[j + 2];
            case 2:
                H8[off + j + 2 | 0] = buf[j + 1];
            case 1:
                H8[off + j + 3 | 0] = buf[j];
            }
        };
        var convFn = function (data) {
            switch (util.getDataType(data)) {
            case 'string':
                return convStr.bind(data);
            case 'array':
                return convBuf.bind(data);
            case 'buffer':
                return convBuf.bind(data);
            case 'arraybuffer':
                return convBuf.bind(new Uint8Array(data));
            case 'view':
                return convBuf.bind(new Uint8Array(data.buffer, data.byteOffset, data.byteLength));
            case 'blob':
                return convBlob.bind(data);
            }
        };
        var slice = function (data, offset) {
            switch (util.getDataType(data)) {
            case 'string':
                return data.slice(offset);
            case 'array':
                return data.slice(offset);
            case 'buffer':
                return data.slice(offset);
            case 'arraybuffer':
                return data.slice(offset);
            case 'view':
                return data.buffer.slice(offset);
            }
        };
        var // Precompute 00 - ff strings
        precomputedHex = new Array(256);
        for (var i = 0; i < 256; i++) {
            precomputedHex[i] = (i < 16 ? '0' : '') + i.toString(16);
        }
        var // Convert an ArrayBuffer into its hexadecimal string representation.
        hex = function (arrayBuffer) {
            var binarray = new Uint8Array(arrayBuffer);
            var res = new Array(arrayBuffer.byteLength);
            for (var i$2 = 0; i$2 < res.length; i$2++) {
                res[i$2] = precomputedHex[binarray[i$2]];
            }
            return res.join('');
        };
        var ceilHeapSize = function (v) {
            // The asm.js spec says:
            // The heap object's byteLength must be either
            // 2^n for n in [12, 24) or 2^24 * n for n ≥ 1.
            // Also, byteLengths smaller than 2^16 are deprecated.
            var p;
            if (// If v is smaller than 2^16, the smallest possible solution
                // is 2^16.
                v <= 65536)
                return 65536;
            if (// If v < 2^24, we round up to 2^n,
                // otherwise we round up to 2^24 * n.
                v < 16777216) {
                for (p = 1; p < v; p = p << 1);
            } else {
                for (p = 16777216; p < v; p += 16777216);
            }
            return p;
        };
        var // Initialize the internal data structures to a new capacity.
        init = function (size) {
            if (size % 64 > 0) {
                throw new Error('Chunk size must be a multiple of 128 bit');
            }
            self$2.maxChunkLen = size;
            self$2.padMaxChunkLen = padlen(size);
            // The size of the heap is the sum of:
            // 1. The padded input message size
            // 2. The extended space the algorithm needs (320 byte)
            // 3. The 160 bit state the algoritm uses
            self$2.heap = new ArrayBuffer(ceilHeapSize(self$2.padMaxChunkLen + 320 + 20));
            self$2.h32 = new Int32Array(self$2.heap);
            self$2.h8 = new Int8Array(self$2.heap);
            self$2.core = new Rusha._core({
                Int32Array: Int32Array,
                DataView: DataView
            }, {}, self$2.heap);
            self$2.buffer = null;
        };
        // Initialize the data structures according
        // to a chunk size.
        init(chunkSize || 64 * 1024);
        var initState = function (heap, padMsgLen) {
            var io = new Int32Array(heap, padMsgLen + 320, 5);
            io[0] = 1732584193;
            io[1] = -271733879;
            io[2] = -1732584194;
            io[3] = 271733878;
            io[4] = -1009589776;
        };
        var padChunk = function (chunkLen, msgLen) {
            var padChunkLen = padlen(chunkLen);
            var view = new Int32Array(self$2.heap, 0, padChunkLen >> 2);
            padZeroes(view, chunkLen);
            padData(view, chunkLen, msgLen);
            return padChunkLen;
        };
        var // Write data to the heap.
        write = function (data, chunkOffset, chunkLen) {
            convFn(data)(self$2.h8, self$2.h32, chunkOffset, chunkLen, 0);
        };
        var // Initialize and call the RushaCore,
        // assuming an input buffer of length len * 4.
        coreCall = function (data, chunkOffset, chunkLen, msgLen, finalize) {
            var padChunkLen = chunkLen;
            if (finalize) {
                padChunkLen = padChunk(chunkLen, msgLen);
            }
            write(data, chunkOffset, chunkLen);
            self$2.core.hash(padChunkLen, self$2.padMaxChunkLen);
        };
        var getRawDigest = function (heap, padMaxChunkLen) {
            var io = new Int32Array(heap, padMaxChunkLen + 320, 5);
            var out = new Int32Array(5);
            var arr = new DataView(out.buffer);
            arr.setInt32(0, io[0], false);
            arr.setInt32(4, io[1], false);
            arr.setInt32(8, io[2], false);
            arr.setInt32(12, io[3], false);
            arr.setInt32(16, io[4], false);
            return out;
        };
        var // Calculate the hash digest as an array of 5 32bit integers.
        rawDigest = this.rawDigest = function (str) {
            var msgLen = str.byteLength || str.length || str.size || 0;
            initState(self$2.heap, self$2.padMaxChunkLen);
            var chunkOffset = 0, chunkLen = self$2.maxChunkLen, last;
            for (chunkOffset = 0; msgLen > chunkOffset + chunkLen; chunkOffset += chunkLen) {
                coreCall(str, chunkOffset, chunkLen, msgLen, false);
            }
            coreCall(str, chunkOffset, msgLen - chunkOffset, msgLen, true);
            return getRawDigest(self$2.heap, self$2.padMaxChunkLen);
        };
        // The digest and digestFrom* interface returns the hash digest
        // as a hex string.
        this.digest = this.digestFromString = this.digestFromBuffer = this.digestFromArrayBuffer = function (str) {
            return hex(rawDigest(str).buffer);
        };
    }
    ;
    // The low-level RushCore module provides the heart of Rusha,
    // a high-speed sha1 implementation working on an Int32Array heap.
    // At first glance, the implementation seems complicated, however
    // with the SHA1 spec at hand, it is obvious this almost a textbook
    // implementation that has a few functions hand-inlined and a few loops
    // hand-unrolled.
    Rusha._core = function RushaCore(stdlib, foreign, heap) {
        'use asm';
        var H = new stdlib.Int32Array(heap);
        function hash(k, x) {
            // k in bytes
            k = k | 0;
            x = x | 0;
            var i = 0, j = 0, y0 = 0, z0 = 0, y1 = 0, z1 = 0, y2 = 0, z2 = 0, y3 = 0, z3 = 0, y4 = 0, z4 = 0, t0 = 0, t1 = 0;
            y0 = H[x + 320 >> 2] | 0;
            y1 = H[x + 324 >> 2] | 0;
            y2 = H[x + 328 >> 2] | 0;
            y3 = H[x + 332 >> 2] | 0;
            y4 = H[x + 336 >> 2] | 0;
            for (i = 0; (i | 0) < (k | 0); i = i + 64 | 0) {
                z0 = y0;
                z1 = y1;
                z2 = y2;
                z3 = y3;
                z4 = y4;
                for (j = 0; (j | 0) < 64; j = j + 4 | 0) {
                    t1 = H[i + j >> 2] | 0;
                    t0 = ((y0 << 5 | y0 >>> 27) + (y1 & y2 | ~y1 & y3) | 0) + ((t1 + y4 | 0) + 1518500249 | 0) | 0;
                    y4 = y3;
                    y3 = y2;
                    y2 = y1 << 30 | y1 >>> 2;
                    y1 = y0;
                    y0 = t0;
                    H[k + j >> 2] = t1;
                }
                for (j = k + 64 | 0; (j | 0) < (k + 80 | 0); j = j + 4 | 0) {
                    t1 = (H[j - 12 >> 2] ^ H[j - 32 >> 2] ^ H[j - 56 >> 2] ^ H[j - 64 >> 2]) << 1 | (H[j - 12 >> 2] ^ H[j - 32 >> 2] ^ H[j - 56 >> 2] ^ H[j - 64 >> 2]) >>> 31;
                    t0 = ((y0 << 5 | y0 >>> 27) + (y1 & y2 | ~y1 & y3) | 0) + ((t1 + y4 | 0) + 1518500249 | 0) | 0;
                    y4 = y3;
                    y3 = y2;
                    y2 = y1 << 30 | y1 >>> 2;
                    y1 = y0;
                    y0 = t0;
                    H[j >> 2] = t1;
                }
                for (j = k + 80 | 0; (j | 0) < (k + 160 | 0); j = j + 4 | 0) {
                    t1 = (H[j - 12 >> 2] ^ H[j - 32 >> 2] ^ H[j - 56 >> 2] ^ H[j - 64 >> 2]) << 1 | (H[j - 12 >> 2] ^ H[j - 32 >> 2] ^ H[j - 56 >> 2] ^ H[j - 64 >> 2]) >>> 31;
                    t0 = ((y0 << 5 | y0 >>> 27) + (y1 ^ y2 ^ y3) | 0) + ((t1 + y4 | 0) + 1859775393 | 0) | 0;
                    y4 = y3;
                    y3 = y2;
                    y2 = y1 << 30 | y1 >>> 2;
                    y1 = y0;
                    y0 = t0;
                    H[j >> 2] = t1;
                }
                for (j = k + 160 | 0; (j | 0) < (k + 240 | 0); j = j + 4 | 0) {
                    t1 = (H[j - 12 >> 2] ^ H[j - 32 >> 2] ^ H[j - 56 >> 2] ^ H[j - 64 >> 2]) << 1 | (H[j - 12 >> 2] ^ H[j - 32 >> 2] ^ H[j - 56 >> 2] ^ H[j - 64 >> 2]) >>> 31;
                    t0 = ((y0 << 5 | y0 >>> 27) + (y1 & y2 | y1 & y3 | y2 & y3) | 0) + ((t1 + y4 | 0) - 1894007588 | 0) | 0;
                    y4 = y3;
                    y3 = y2;
                    y2 = y1 << 30 | y1 >>> 2;
                    y1 = y0;
                    y0 = t0;
                    H[j >> 2] = t1;
                }
                for (j = k + 240 | 0; (j | 0) < (k + 320 | 0); j = j + 4 | 0) {
                    t1 = (H[j - 12 >> 2] ^ H[j - 32 >> 2] ^ H[j - 56 >> 2] ^ H[j - 64 >> 2]) << 1 | (H[j - 12 >> 2] ^ H[j - 32 >> 2] ^ H[j - 56 >> 2] ^ H[j - 64 >> 2]) >>> 31;
                    t0 = ((y0 << 5 | y0 >>> 27) + (y1 ^ y2 ^ y3) | 0) + ((t1 + y4 | 0) - 899497514 | 0) | 0;
                    y4 = y3;
                    y3 = y2;
                    y2 = y1 << 30 | y1 >>> 2;
                    y1 = y0;
                    y0 = t0;
                    H[j >> 2] = t1;
                }
                y0 = y0 + z0 | 0;
                y1 = y1 + z1 | 0;
                y2 = y2 + z2 | 0;
                y3 = y3 + z3 | 0;
                y4 = y4 + z4 | 0;
            }
            H[x + 320 >> 2] = y0;
            H[x + 324 >> 2] = y1;
            H[x + 328 >> 2] = y2;
            H[x + 332 >> 2] = y3;
            H[x + 336 >> 2] = y4;
        }
        return { hash: hash };
    };
    exports = Rusha;
    if (// If we'e running in Node.JS, export a module.
        true) {
        module.exports = Rusha;
    } else {}
    if (// If we're running in a webworker, accept
        // messages containing a jobid and a buffer
        // or blob object, and return the hash result.
        typeof FileReaderSync !== 'undefined') {
        var reader = new FileReaderSync(), hasher = new Rusha(4 * 1024 * 1024);
        self.onmessage = function onMessage(event) {
            var hash, data = event.data.data;
            try {
                hash = hasher.digest(data);
                self.postMessage({
                    id: event.data.id,
                    hash: hash
                });
            } catch (e) {
                self.postMessage({
                    id: event.data.id,
                    error: e.name
                });
            }
        };
    }
}());


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/snippets.js":
/*!******************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/snippets.js ***!
  \******************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_493903__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * @file Snippets implementation.
 */

const {EventEmitter} = __nested_webpack_require_493903__(/*! ./events */ "./node_modules/adblockpluscore/lib/events.js");

let singleCharacterEscapes = new Map([
  ["n", "\n"], ["r", "\r"], ["t", "\t"]
]);

/**
 * `{@link module:snippets.snippets snippets}` implementation.
 */
class Snippets extends EventEmitter {
  /**
   * @hideconstructor
   */
  constructor() {
    super();

    /**
     * All known snippet filters.
     * @type {Set.<module:filterClasses.SnippetFilter>}
     * @private
     */
    this._filters = new Set();
  }

  /**
   * Removes all known snippet filters.
   */
  clear() {
    let {_filters} = this;

    if (_filters.size == 0)
      return;

    _filters.clear();

    this.emit("snippets.filtersCleared");
  }

  /**
   * Adds a new snippet filter.
   * @param {module:filterClasses.SnippetFilter} filter
   */
  add(filter) {
    let {_filters} = this;
    let {size} = _filters;

    _filters.add(filter);

    if (size != _filters.size)
      this.emit("snippets.filterAdded", filter);
  }

  /**
   * Removes an existing snippet filter.
   * @param {module:filterClasses.SnippetFilter} filter
   */
  remove(filter) {
    let {_filters} = this;
    let {size} = _filters;

    _filters.delete(filter);

    if (size != _filters.size)
      this.emit("snippets.filterRemoved", filter);
  }

  /**
   * Checks whether a snippet filter exists.
   * @param {module:filterClasses.SnippetFilter} filter
   * @returns {boolean}
   */
  has(filter) {
    return this._filters.has(filter);
  }

  /**
   * Returns a list of all snippet filters active on the given domain.
   * @param {string} domain The domain.
   * @returns {Array.<module:filterClasses.SnippetFilter>} A list of snippet
   *   filters.
   */
  getFilters(domain) {
    let result = [];

    for (let filter of this._filters) {
      if (filter.isActiveOnDomain(domain))
        result.push(filter);
    }

    return result;
  }

  /**
   * Returns a list of all snippet filters active on the given domain.
   * @param {string} domain The domain.
   * @returns {Array.<module:filterClasses.SnippetFilter>} A list of snippet
   *   filters.
   *
   * @deprecated Use <code>{@link module:snippets~Snippets#getFilters}</code>
   *   instead.
   * @see module:snippets~Snippets#getFilters
   */
  getFiltersForDomain(domain) {
    return this.getFilters(domain);
  }
}

/**
 * Container for snippet filters.
 */
exports.Snippets = Snippets;

let parseScript =
/**
 * Parses a script and returns a list of all its commands and their arguments.
 * @param {string} script The script.
 * @returns {Array.<string[]>} A list of commands and their arguments.
 * @package
 */
exports.parseScript = function parseScript(script) {
  let tree = [];

  let escape = false;
  let withinQuotes = false;

  let unicodeEscape = null;

  let quotesClosed = false;

  let call = [];
  let argument = "";

  for (let character of script.trim() + ";") {
    let afterQuotesClosed = quotesClosed;
    quotesClosed = false;

    if (unicodeEscape != null) {
      unicodeEscape += character;

      if (unicodeEscape.length == 4) {
        let codePoint = parseInt(unicodeEscape, 16);
        if (!isNaN(codePoint))
          argument += String.fromCodePoint(codePoint);

        unicodeEscape = null;
      }
    }
    else if (escape) {
      escape = false;

      if (character == "u")
        unicodeEscape = "";
      else
        argument += singleCharacterEscapes.get(character) || character;
    }
    else if (character == "\\") {
      escape = true;
    }
    else if (character == "'") {
      withinQuotes = !withinQuotes;

      if (!withinQuotes)
        quotesClosed = true;
    }
    else if (withinQuotes || character != ";" && !/\s/.test(character)) {
      argument += character;
    }
    else {
      if (argument || afterQuotesClosed) {
        call.push(argument);
        argument = "";
      }

      if (character == ";" && call.length > 0) {
        tree.push(call);
        call = [];
      }
    }
  }

  return tree;
};

/**
 * Compiles a script against a given list of libraries, passed as JSON
 * serialized string, or a an array of strings, into executable code.
 * @param {string|Array.<string>} scripts One or more scripts to convert into
 *  executable code.
 * @param {string} isolatedSnippetsLibrary The stringified bundle to be executed
 * in the isolated content script context.
 * @param {string} injectedSnippetsLibrary The stringified bundle to be injected
 * and executed in the main context.
 * @param {string|Array.<string>} injectedSnippetsList An array containing the
 * available injectable snippets.
 * @param {object} [environment] An object containing environment variables.
 * @returns {string} Executable code.
 */
exports.compileScript = function compileScript(scripts,
                                               isolatedSnippetsLibrary,
                                               injectedSnippetsLibrary,
                                               injectedSnippetsList,
                                               environment = {}) {
  let isolatedLib = JSON.stringify(isolatedSnippetsLibrary);
  let injectedLib = JSON.stringify(injectedSnippetsLibrary);
  let jsonEnv = JSON.stringify(environment);
  return `
    "use strict";
    (() => 
    {
      let scripts = ${JSON.stringify([].concat(scripts).map(parseScript))};

      let isolatedLib = ${isolatedLib};
      let imports = Object.create(null);
      let injectedSnippetsCount = 0;
      let loadLibrary = new Function("exports", "environment", isolatedLib);
      loadLibrary(imports, ${jsonEnv});
      const isolatedSnippets = imports.snippets;

      let injectedLib = ${injectedLib};
      let injectedSnippetsList = ${JSON.stringify(injectedSnippetsList)};
      let executable = "(() => {";
      executable += "let environment = ${jsonEnv.replace(/[\\"]/g, "\\$&")};";
      executable += injectedLib;

      let {hasOwnProperty} = Object.prototype;
      for (let script of scripts)
      {
        for (let [name, ...args] of script)
        {
          if (hasOwnProperty.call(isolatedSnippets, name))
          {
            let value = isolatedSnippets[name];
            if (typeof value == "function")
              value(...args);
          }
          if (injectedSnippetsList.includes(name))
          {
            executable += stringifyFunctionCall(name, ...args);
            injectedSnippetsCount++;
          }
        }
      }

      executable += "})();";

      if (injectedSnippetsCount > 0)
        injectSnippetsInMainContext(executable);

      function stringifyFunctionCall(func, ...params)
      {
        // Call JSON.stringify on the arguments to avoid any arbitrary code
        // execution.
        const f = "snippets['" + func + "']";
        const parameters = params.map(JSON.stringify).join(",");
        return f + "(" + parameters + ");";
      }

      function injectSnippetsInMainContext(exec)
      {
        // injecting phase
        let script = document.createElement("script");
        script.type = "application/javascript";
        script.async = false;

        // Firefox 58 only bypasses site CSPs when assigning to 'src',
        // while Chrome 67 and Microsoft Edge (tested on 44.17763.1.0)
        // only bypass site CSPs when using 'textContent'.
        if (typeof netscape != "undefined" && typeof browser != "undefined")
        {
          let url = URL.createObjectURL(new Blob([exec]));
          script.src = url;
          document.documentElement.appendChild(script);
          URL.revokeObjectURL(url);
        }
        else
        {
          script.textContent = exec;
          document.documentElement.appendChild(script);
        }

        document.documentElement.removeChild(script);
      }
    })();
  `;
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/subscriptionClasses.js":
/*!*****************************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/subscriptionClasses.js ***!
  \*****************************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_502825__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * @file Definition of Subscription class and its subclasses.
 */

const {recommendations} = __nested_webpack_require_502825__(/*! ./recommendations */ "./node_modules/adblockpluscore/lib/recommendations.js");
const {isActiveFilter, Filter} = __nested_webpack_require_502825__(/*! ./filterClasses */ "./node_modules/adblockpluscore/lib/filterClasses.js");
const {filterNotifier} = __nested_webpack_require_502825__(/*! ./filterNotifier */ "./node_modules/adblockpluscore/lib/filterNotifier.js");
const {Downloader} = __nested_webpack_require_502825__(/*! ./downloader */ "./node_modules/adblockpluscore/lib/downloader.js");
const {profiler} = __nested_webpack_require_502825__(/*! ./profiler */ "./node_modules/adblockpluscore/lib/profiler.js");

let _recommendationsByURL = null;

/**
 * Subscription recommendation by URL.
 *
 * If `Subscription.dnr` is falsey then the mv2URL is the actual URL
 * as we would have with manifest v2.
 *
 * @returns {Map.<string, Recommendation>}
 */
function recommendationsByURL() {
  if (!_recommendationsByURL) {
    if (Subscription.dnr) {
      _recommendationsByURL = new Map(
        (function*() {
          for (let recommendation of recommendations())
            yield [recommendation.url, recommendation];
        })()
      );
    }
    else {
      _recommendationsByURL = new Map(
        (function*() {
          for (let recommendation of recommendations()) {
            if (recommendation.mv2URL)
              yield [recommendation.mv2URL, recommendation];
          }
        })()
      );
    }
  }
  return _recommendationsByURL;
}

let _urlByMv2URL = null;

/**
 * Subscription URL by mv2_url.
 *
 * @returns {Map.<string, string>}
 */
function urlByMv2URL() {
  if (!_urlByMv2URL) {
    _urlByMv2URL = new Map(
      (function*() {
        for (let {mv2URL, url} of recommendations()) {
          if (mv2URL)
            yield [mv2URL, url];
        }
      })()
    );
  }
  return _urlByMv2URL;
}

let Subscription =
/**
 * The `Subscription` class represents a filter subscription.
 * @abstract
 */
exports.Subscription = class Subscription {
  /**
   * Creates a `Subscription` object.
   * @param {string} url The URL of the subscription.
   * @param {string} [title] The title of the subscription.
   * @private
   */
  constructor(url, title) {
    /**
     * The URL of the subscription.
     * @type {string}
     * @see module:subscriptionClasses.Subscription#url
     * @private
     */
    this._url = url;

    /**
     * Whether the URL of the subscription is a valid subscription URL.
     * @type {boolean}
     * @private
     * @see module:subscriptionClasses.Subscription#valid
     */
    this._urlValid = Subscription.isValidURL(url);

    let recommendation = recommendationsByURL().get(url);
    /**
     * The type of the subscription.
     * @type {?string}
     * @default <code>null</code>
     * @private
     * @see module:subscriptionClasses.Subscription#type
     */
    this._type = recommendation ? recommendation.type : null;

    /**
     * The id (UUID) of the subscription.
     * @type {?string}
     * @default <code>null</code>
     * @private
     */
    this._id = recommendation ? recommendation.id : null;

    /**
     * Filter text contained in the subscription.
     * @type {Array.<string>}
     * @private
     */
    this._filterText = [];

    /**
     * A searchable index of filter text in the subscription.
     * @type {Set.<string>}
     * @private
     */
    this._filterTextIndex = new Set();

    /**
     * The title of the subscription.
     * @type {?string}
     * @default <code>null</code>
     * @private
     * @see module:subscriptionClasses.Subscription#title
     */
    this._title = null;

    if (title)
      this._title = title;

    /**
     * Whether the title of the subscription is non-editable.
     * @type {boolean}
     * @default <code>false</code>
     * @private
     * @see module:subscriptionClasses.Subscription#fixedTitle
     */
    this._fixedTitle = false;

    /**
     * Whether the subscription is disabled.
     * @type {boolean}
     * @default <code>false</code>
     * @private
     * @see module:subscriptionClasses.Subscription#disabled
     */
    this._disabled = false;

    Subscription.knownSubscriptions.set(url, this);
  }

  /**
   * The id (UUID) of the subscription.
   * @type {string}
   */
  get id() {
    return this._id;
  }

  /**
   * The URL of the subscription.
   * @type {string}
   */
  get url() {
    return this._url;
  }

  /**
   * Whether the subscription is valid.
   * @type {boolean}
   * @package
   */
  get valid() {
    // This should return a value based on Subscription#_urlValid after
    // https://gitlab.com/eyeo/adblockplus/abpui/adblockplusui/-/issues/753
    return true;
  }

  /**
   * The type of the subscription.
   * @type {?string}
   * @default <code>null</code>
   */
  get type() {
    return this._type;
  }

  /**
   * True if this subscription can load filters that require
   * privileged access, like snippets.
   * @type {bool}
   */
  get privileged() {
    return this.type === "circumvention";
  }

  /**
   * The title of the subscription.
   * @type {string}
   */
  get title() {
    return this._title;
  }

  set title(value) {
    if (value != this._title) {
      let oldValue = this._title;
      this._title = value;
      filterNotifier.emit("subscription.title", this, value, oldValue);
    }
  }

  /**
   * Whether the title of the subscription is non-editable.
   * @type {boolean}
   * @default <code>false</code>
   */
  get fixedTitle() {
    return this._fixedTitle;
  }

  set fixedTitle(value) {
    if (value != this._fixedTitle) {
      let oldValue = this._fixedTitle;
      this._fixedTitle = value;
      filterNotifier.emit("subscription.fixedTitle", this, value, oldValue);
    }
  }

  /**
   * Whether the subscription is downloadable.
   * @type {boolean}
   * @default <code>false</code>
   */
  get downloadable() {
    return false;
  }

  /**
   * Whether the subscription is disabled.
   * @type {boolean}
   * @default <code>false</code>
   */
  get disabled() {
    return this._disabled;
  }

  set disabled(value) {
    if (value != this._disabled) {
      let oldValue = this._disabled;
      this._disabled = value;
      filterNotifier.emit("subscription.disabled", this, value, oldValue);
    }
  }

  /**
   * The number of filters in the subscription.
   * @type {number}
   * @default <code>0</code>
   */
  get filterCount() {
    return this._filterText.length;
  }

  /**
   * Returns an iterator that yields the text for each filter in the
   * subscription.
   * @returns {Iterator.<string>}
   */
  filterText() {
    return this._filterText[Symbol.iterator]();
  }

  // Lots of this fromSynchronizer._onDownloadSuccess()
  /**
   * Set parameters for Countable subscriptions.
   *
   * @param {object} params The params from the filter list. `params` is
   *   the `params` field as returned by
   *   `{@link module:filters/lists.parseFilterList parseFilterList()}`.
   */
  setParams(params) {
    if (params.homepage) {
      let url;
      try {
        url = new URL(params.homepage);
      }
      catch (e) {
        url = null;
      }

      if (url && (url.protocol == "http:" || url.protocol == "https:"))
        this.homepage = url.href;
    }

    if (params.title) {
      this.title = params.title;
      this.fixedTitle = true;
    }
    else {
      this.fixedTitle = false;
    }

    if (params.version)
      this.version = parseInt(params.version, 10);

    if (this.type)
      this.abtest = params.abtest;
  }

  /**
   * Set the filter text, and reset the index. Call this before adding
   * to the storage.
   *
   * The filter texts will be normalized with `{@link
   * module:filterClasses.Filter#normalize Filter.normalize()}` like
   * if they were loaded from a filter list.
   *
   * It is important to not call this beside the initialisation of the
   * subscription as it doesn't notify of changes
   *
   * @param {Array.<string>} text The text strings.
   * @param {object?} params The filter list params if any. `params` is
   *   the `params` field as returned by
   *   `{@link module:filters/lists.parseFilterList parseFilterList()}`.
   *
   * An error will be thrown if `text` isn't an array.
   */
  setFilterText(text, params = null) {
    if (!Array.isArray(text))
      throw new Error("setFilterText() must be called with an Array");

    this._filterText = text.map(t => Filter.normalize(t));
    this._filterTextIndex = new Set(this._filterText);

    if (params)
      this.setParams(params);
  }

  /**
   * Checks whether the subscription has the given filter text.
   * @param {string} filterText The filter text.
   * @returns {boolean} Whether the subscription has the filter text.
   * @package
   */
  hasFilterText(filterText) {
    return this._filterTextIndex.has(filterText);
  }

  /**
   * Returns the filter text at the given `0`-based index.
   * @param {number} index The `0`-based index. If the index is out of bounds,
   *   the return value is `null`.
   * @returns {?module:filterClasses.Filter} The filter text.
   */
  filterTextAt(index) {
    return this._filterText[index] || null;
  }

  /**
   * Returns the `0`-based index of the given filter.
   *
   * @param {module:filterClasses.Filter} filter The filter.
   * @param {number} [fromIndex] The `0`-based index from which to start the
   *   search.
   *
   * @returns {number} The `0`-based index at which the filter is found. If the
   *   filter is not found in the subscription, the return value is `-1`.
   */
  findFilterIndex(filter, fromIndex = 0) {
    return this._filterText.indexOf(filter.text, fromIndex);
  }

  /**
   * Removes all filters from the subscription.
   */
  clearFilters() {
    this._filterText = [];
    this._filterTextIndex.clear();
  }

  /**
   * Adds a filter to the subscription.
   * @param {Filter} filter The filter.
   */
  addFilter(filter) {
    this._filterText.push(filter.text);
    this._filterTextIndex.add(filter.text);
  }

  /**
   * Inserts a filter into the subscription at the given `0`-based index.
   *
   * @param {module:filterClasses.Filter} filter The filter.
   * @param {number} index The `0`-based index. If the index is out of bounds,
   *   the filter is inserted at the beginning or at the end accordingly.
   */
  insertFilterAt(filter, index) {
    this._filterText.splice(index, 0, filter.text);
    this._filterTextIndex.add(filter.text);
  }

  /**
   * Deletes a filter from the subscription at the given `0`-based index.
   * @param {number} index The `0`-based index. If the index is out of bounds,
   *   no filter is deleted.
   */
  deleteFilterAt(index) {
    // Ignore index if out of bounds on the negative side, for consistency.
    if (index < 0)
      return;

    let [filterText] = this._filterText.splice(index, 1);
    if (!this._filterText.includes(filterText))
      this._filterTextIndex.delete(filterText);
  }

  /**
   * Updates the filter text of the subscription.
   * @param {Array.<string>} filterText The new filter text.
   * @returns {{added: Array.<string>, removed: Array.<string>}} An object
   *   containing two lists of the text of added and removed filters
   *   respectively.
   * @package
   */
  updateFilterText(filterText) {
    let added = [];
    let removed = [];

    if (this._filterText.length == 0) {
      added = [...filterText];
    }
    else if (filterText.length > 0) {
      for (let text of filterText) {
        if (!this._filterTextIndex.has(text))
          added.push(text);
      }
    }

    this._filterTextIndex = new Set(filterText);

    if (filterText.length == 0) {
      removed = [...this._filterText];
    }
    else if (this._filterText.length > 0) {
      for (let text of this._filterText) {
        if (!this._filterTextIndex.has(text))
          removed.push(text);
      }
    }

    this._filterText = [...filterText];

    return {added, removed};
  }

  /**
   * Serializes the subscription for writing out on disk.
   * @yields {string}
   * @package
   */
  *serialize() {
    let {url, _title, _fixedTitle, _disabled, _id} = this;

    yield "[Subscription]";
    yield "url=" + url;

    if (_title)
      yield "title=" + _title;
    if (_fixedTitle)
      yield "fixedTitle=true";
    if (_disabled)
      yield "disabled=true";
    if (_id)
      yield "id=" + _id;
  }

  /**
   * Serializes the subscription's filter text for writing out on disk.
   * @yields {string}
   * @package
   */
  *serializeFilters() {
    let {_filterText} = this;

    yield "[Subscription filters]";

    for (let text of _filterText)
      yield text.replace(/\[/g, "\\[");
  }

  /**
   * Returns a string representing the subscription.
   * @returns {string}
   */
  toString() {
    return [...this.serialize()].join("\n");
  }
};

/**
 * Cache for known filter subscriptions that maps subscription URLs to
 * subscription objects.
 * @type {Map.<string, module:subscriptionClasses.Subscription>}
 * @package
 */
exports.Subscription.knownSubscriptions = new Map();
/**
 * We operate in DNR mode. Default is false.
 * @type {bool}
 * @package
 */
exports.Subscription.dnr = false;

/**
 * Returns the subscription object for a subscription URL.
 *
 * Every subscription URL maps to its own unique object. If no such object
 * exists, a new one is created internally; otherwise the existing object is
 * used.
 *
 * If `Subscription.dnr` is true, it will remap `mv2_url` to the canonical
 * `url` if necessary.
 *
 * @param {string} url The subscription URL.
 *
 * @returns {module:subscriptionClasses.Subscription} A subscription
 * object (can be any subclass thereof.
 */
exports.Subscription.fromURL = function(url) {
  let subscription = Subscription.knownSubscriptions.get(url);
  if (subscription)
    return subscription;

  if (url[0] != "~") {
    let downloadable = true;
    let title = null;
    if (Subscription.dnr) {
      // In DNR we check if we got a mv2 URL and remap.
      let actualUrl = urlByMv2URL().get(url);
      if (actualUrl) {
        subscription = Subscription.knownSubscriptions.get(actualUrl);
        if (subscription)
          return subscription;

        url = actualUrl;
      }

      let recommendation = recommendationsByURL().get(url);
      if (recommendation) {
        // In DNR currently "circumvention" list is downloadable.
        // This until we can tag subscription to be downloadable.
        downloadable = recommendation.type == "circumvention";
        // In DNR we use the recommendation title.
        title = recommendation.title;
      }
    }

    if (downloadable)
      subscription = new DownloadableSubscription(url, title);
    else
      subscription = new CountableSubscription(url, title);

    return subscription;
  }

  return new SpecialSubscription(url);
};

/**
 * Deserializes a subscription.
 * @param {Object} obj A map of serialized properties and their values.
 * @returns {module:subscriptionClasses.Subscription} A subscription object.
 * @package
 */
exports.Subscription.fromObject = function(obj) {
  let result;
  if (obj.url[0] != "~") {
    // URL is valid - this is a regular subscription
    // Unless indicated otherwise it is downloadable.
    if (("downloadable" in obj) && (obj.downloadable == "false"))
      result = new CountableSubscription(obj.url, obj.title);
    else
      result = new DownloadableSubscription(obj.url, obj.title);

    if (result.type)
      result.abtest = obj.abtest;

    if ("downloadStatus" in obj)
      result._downloadStatus = obj.downloadStatus;
    if ("lastSuccess" in obj)
      result.lastSuccess = parseInt(obj.lastSuccess, 10) || 0;
    if ("lastCheck" in obj)
      result._lastCheck = parseInt(obj.lastCheck, 10) || 0;
    if ("expires" in obj)
      result.expires = parseInt(obj.expires, 10) || 0;
    if ("softExpiration" in obj)
      result.softExpiration = parseInt(obj.softExpiration, 10) || 0;
    if ("errors" in obj)
      result._errors = parseInt(obj.errors, 10) || 0;
    if ("version" in obj)
      result.version = parseInt(obj.version, 10) || 0;
    if ("requiredVersion" in obj)
      result.requiredVersion = obj.requiredVersion;
    if ("homepage" in obj)
      result._homepage = obj.homepage;
    if ("lastDownload" in obj)
      result._lastDownload = parseInt(obj.lastDownload, 10) || 0;
    if ("downloadCount" in obj)
      result.downloadCount = parseInt(obj.downloadCount, 10) || 0;
  }
  else {
    result = new SpecialSubscription(obj.url, obj.title);
    if ("defaults" in obj)
      result.defaults = obj.defaults.split(" ");
    if ("metadata" in obj)
      result._metadata = JSON.parse(obj.metadata);
  }
  if ("id" in obj)
    result._id = obj.id;
  if ("fixedTitle" in obj)
    result._fixedTitle = (obj.fixedTitle == "true");
  if ("disabled" in obj)
    result._disabled = (obj.disabled == "true");

  return result;
};

/**
 * Checks whether a URL is a valid subscription URL.
 * @param {string} url The URL.
 * @returns {boolean} Whether the URL is a valid subscription URL.
 */
exports.Subscription.isValidURL = function isValidURL(url) {
  return url.startsWith("~user~") || Downloader.isValidURL(url);
};

let SpecialSubscription =
/**
 * The `SpecialSubscription` class represents a special filter subscription.
 *
 * This type of subscription is used for keeping user-defined filters.
 * @extends module:subscriptionClasses.Subscription
 */
exports.SpecialSubscription = class SpecialSubscription extends Subscription {
  /**
   * Creates a `SpecialSubscription` object.
   * @param {string} url The URL of the subscription.
   * @param {string} [title] The title of the subscription.
   * @private
   */
  constructor(url, title) {
    super(url, title);

    /**
     * Filter types that should be added to this subscription by default.
     *
     * Entries should correspond to keys in
     * `{@link module:subscriptionClasses.SpecialSubscription.defaultsMap}`.
     *
     * @type {?Array.<string>}
     *
     * @package
     */
    this.defaults = null;

    this._metadata = null;
  }

  get privileged() {
    return true;
  }

  /**
   * Checks whether the given filter should be added to this subscription by
   * default.
   * @param {Filter} filter The filter.
   * @returns {boolean} Whether the filter should be added to this subscription
   *   by default.
   * @package
   */
  isDefaultFor(filter) {
    if (this.defaults && this.defaults.length) {
      for (let type of this.defaults) {
        if (SpecialSubscription.defaultsMap.get(type).includes(filter.type))
          return true;
        if (!isActiveFilter(filter) && type == "blocking")
          return true;
      }
    }

    return false;
  }

  /**
   * Set the metadata block for the special subscription
   *
   * @param {object} [value] The metadata
   */
  set metadata(value) {
    let oldValue = this._metadata;
    this._metadata = value;
    filterNotifier.emit("subscription.metadata", this, value, oldValue);
  }

  /**
   * Get the metadata block.
   * @return {?object} the metadata object or null
   */
  get metadata() {
    return this._metadata;
  }

  /**
   * Serializes the subscription for writing out on disk.
   * @yields {string}
   * @package
   */
  *serialize() {
    let {defaults, _lastDownload, _metadata} = this;

    yield* super.serialize();

    if (defaults) {
      yield "defaults=" +
            defaults.map(
              // remap for the stored format.
              type => type == "allowing" ? "whitelist" : type
            ).filter(
              type => SpecialSubscription.defaultsMap.has(type)
            ).join(" ");
    }
    // Metadata is encoded as a JSON on a single line.
    // This should be safe.
    if (_metadata)
      yield "metadata=" + JSON.stringify(_metadata);

    if (_lastDownload)
      yield "lastDownload=" + _lastDownload;
  }
};

/**
 * A map of filter types.
 * @type {Map.<string, Array.<string>>}
 * @package
 */
exports.SpecialSubscription.defaultsMap = new Map([
  ["allowing", ["allowing"]],
  // deprecated terminology
  ["whitelist", ["allowing"]],
  ["blocking", ["blocking"]],
  ["elemhide", ["elemhide", "elemhideexception", "elemhideemulation"]]
]);

/**
 * Creates a new special subscription.
 * @param {string} [title] The title of the subscription.
 * @returns {module:subscriptionClasses.SpecialSubscription} A new special
 *   subscription.
 * @package
 */
exports.SpecialSubscription.create = function(title) {
  let url;
  do
    url = "~user~" + Math.round(Math.random() * 1000000);
  while (Subscription.knownSubscriptions.has(url));
  return new SpecialSubscription(url, title);
};

/**
 * Creates a new special subscription and adds the given filter to it.
 *
 * Once created, the subscription acts as the default for all filters of the
 * {@link module:filterClasses.Filter#type type}.
 *
 * @param {module:filterClasses.Filter} filter The filter.
 *
 * @returns {module:subscriptionClasses.SpecialSubscription} A new special
 *   subscription.
 *
 * @package
 */
exports.SpecialSubscription.createForFilter = function(filter) {
  let subscription = SpecialSubscription.create();
  subscription.addFilter(filter);
  for (let [type, mappedTypes] of SpecialSubscription.defaultsMap) {
    if (mappedTypes.includes(filter.type))
      subscription.defaults = [type];
  }
  if (!subscription.defaults)
    subscription.defaults = ["blocking"];
  return subscription;
};

let RegularSubscription =
/**
 * The `RegularSubscription` class represents a regular filter subscription
 * that is not by default downloaded off the internet.
 * `CountableSubscription` is a subclass of this.
 *
 * In a manifest v2 context it shouldn't be encountered. In manifest v3, it's
 * the default.
 *
 * @extends module:subscriptionClasses.Subscription
 */
exports.RegularSubscription = class RegularSubscription extends Subscription {
  /**
   * Creates a `RegularSubscription` object.
   * @param {string} url The URL of the subscription.
   * @param {string} [title] The title of the subscription.
   * @private
   */
  constructor(url, title) {
    super(url, title || url);

    /**
     * The homepage of the subscription.
     * @type {?string}
     * @default <code>null</code>
     * @private
     * @see module:subscriptionClasses.RegularSubscription#homepage
     */
    this._homepage = null;

    /**
     * The last time the subscription was downloaded, in seconds since the
     * beginning of the Unix epoch.
     * @type {number}
     * @default <code>0</code>
     * @private
     * @see module:subscriptionClasses.RegularSubscription#lastDownload
     */
    this._lastDownload = 0;

    let recommendation = recommendationsByURL().get(url);
    /**
     * The languages that apply for this subscription.
     * @type {?Array.<string>}
     */
    this._languages = recommendation ? recommendation.languages : null;
  }

  /**
   * The homepage of the subscription.
   * @type {?string}
   * @default <code>null</code>
   */
  get homepage() {
    return this._homepage;
  }

  set homepage(value) {
    if (value != this._homepage) {
      let oldValue = this._homepage;
      this._homepage = value;
      filterNotifier.emit("subscription.homepage", this, value, oldValue);
    }
  }

  /**
   * The languages that apply for this subscription.
   * @type {?Array.<string>}
   * @default <code>null</code>
   */
  get languages() {
    return this._languages;
  }

  /**
   * The last time the subscription was downloaded, in seconds since the
   * beginning of the Unix epoch.
   * @type {number}
   * @default <code>0</code>
   */
  get lastDownload() {
    return this._lastDownload;
  }

  set lastDownload(value) {
    if (value != this._lastDownload) {
      let oldValue = this._lastDownload;
      this._lastDownload = value;
      filterNotifier.emit("subscription.lastDownload", this, value, oldValue);
    }
  }

  /**
   * Serializes the subscription for writing out on disk.
   * @yields {string}
   * @package
   */
  *serialize() {
    let {_homepage, _lastDownload} = this;

    yield* super.serialize();

    // To keep compatibility dowloadable is true if missing
    if (!this.downloadable)
      yield "downloadable=false";
    if (_homepage)
      yield "homepage=" + _homepage;
    if (_lastDownload)
      yield "lastDownload=" + _lastDownload;
  }
};

/**
 * Once initialized, the shared Synchronizer singleton will be stored in here.
 * @type {module:synchronizer.Synchronizer}
 */
let synchronizer = null;

let CountableSubscription =
/**
 * The `CountableSubscription` class represents a regular filter
 * subscription which will indicate it to the remote `url` it is in
 * use by issuing a `HEAD` http request instead of a `GET`.
 *
 * However it will have its property `downloadable` still set to
 * `false`.
 *
 * @extends module:subscriptionClasses.RegularSubscription
 */
exports.CountableSubscription =
class CountableSubscription extends RegularSubscription {
  /**
   * Allows downloadable subscriptions to update themselves once re-enabled,
   * via receiving the Synchronizer singleton.
   * @param {module:synchronizer~Synchronizer} reference the Synchronizer
   */
  static useSynchronizer(reference) {
    synchronizer = reference;
  }

  /**
   * Creates a `CountableSubscription` object.
   *
   * @param {string} url The URL of the subscription.
   * @param {string} [title] The title of the subscription.
   * @private
   */
  constructor(url, title) {
    super(url, title);

    /**
     * The status of the last download.
     * @type {?string}
     * @default <code>null</code>
     * @private
     * @see module:subscriptionClasses.CountableSubscription#downloadStatus
     */
    this._downloadStatus = null;

    /**
     * The last time the subscription was considered for an update, in seconds
     * since the beginning of the Unix epoch.
     * @type {number}
     * @default <code>0</code>
     * @private
     * @see module:subscriptionClasses.CountableSubscription#lastCheck
     */
    this._lastCheck = 0;

    /**
     * The number of download failures since the last successful download.
     * @type {number}
     * @default <code>0</code>
     * @private
     * @see module:subscriptionClasses.CountableSubscription#errors
     */
    this._errors = 0;

    /**
     * The last time the subscription was successfully downloaded, in seconds
     * since the beginning of the Unix epoch.
     * @type {number}
     * @default <code>0</code>
     */
    this.lastSuccess = 0;

    /**
     * The hard expiration time of the subscription, in seconds since the
     * beginning of the Unix epoch.
     *
     * Updates should be downloaded if `{@link
     * module:subscriptionClasses.CountableSubscription#softExpiration}`
     * or `expires` are in the past.
     * @type {number}
     * @default <code>0</code>
     */
    this.expires = 0;

    /**
     * The soft expiration time of the subscription, in seconds since the
     * beginning of the Unix epoch.
     *
     * Updates should be downloaded if `softExpiration` or
     * `{@link module:subscriptionClasses.CountableSubscription#expires}`
     * are in the past.
     * @type {number}
     * @default <code>0</code>
     */
    this.softExpiration = 0;

    /**
     * The version of the subscription data that was retrieved on last
     * successful download.
     * @type {number}
     * @default <code>0</code>
     */
    this.version = 0;

    /**
     * The minimal Adblock Plus version required for the subscription.
     * @type {?string}
     * @default <code>null</code>
     */
    this.requiredVersion = null;

    /**
     * The number of times the subscription has been downloaded.
     * @type {number}
     * @default <code>0</code>
     */
    this.downloadCount = 0;

    this._p = profiler(`CountableSubscription@${url}`);
    this._p.start();
  }

  /**
   * Whether this is a countable subscription, i.e. a subscription that
   * will connect to the URL. A downloadable subscription is countable,
   * but not the other way around.
   *
   * @type {boolean}
   * @default <code>true</code>
   */
  get countable() {
    return true;
  }

  /**
   * Whether the subscription is disabled. Once re-enabled, it ensures the
   * synchronizer downloads latest version of this subscription.
   * @type {boolean}
   * @default <code>false</code>
   */
  get disabled() {
    return super.disabled;
  }

  set disabled(value) {
    let {_disabled} = this;
    super.disabled = value;
    if (synchronizer && _disabled && !value)
      synchronizer.execute(this);
  }

  /**
   * The status of the last download.
   *
   * A message ID which can have the following values: `synchronize_ok`,
   * `synchronize_connection_error` or `synchronize_invalid_url`. If the
   * initial download is not completed yet, then it is null.
   *
   * @type {?string}
   * @default <code>null</code>
   */
  get downloadStatus() {
    return this._downloadStatus;
  }

  set downloadStatus(value) {
    let oldValue = this._downloadStatus;
    this._downloadStatus = value;
    filterNotifier.emit("subscription.downloadStatus", this, value, oldValue);
  }

  /**
   * The last time the subscription was considered for an update, in seconds
   * since the beginning of the Unix epoch.
   *
   * This is used to increase the soft expiration time if the user doesn't use
   * Adblock Plus for some time.
   *
   * @type {number}
   * @default <code>0</code>
   */
  get lastCheck() {
    return this._lastCheck;
  }

  set lastCheck(value) {
    if (value != this._lastCheck) {
      let oldValue = this._lastCheck;
      this._lastCheck = value;
      filterNotifier.emit("subscription.lastCheck", this, value, oldValue);
    }
  }

  /**
   * The number of download failures since the last successful download.
   * @type {number}
   * @default <code>0</code>
   */
  get errors() {
    return this._errors;
  }

  set errors(value) {
    if (value != this._errors) {
      let oldValue = this._errors;
      this._errors = value;
      filterNotifier.emit("subscription.errors", this, value, oldValue);
    }
  }

  /**
   * Serializes the subscription for writing out on disk.
   * @yields {string}
   * @package
   */
  *serialize() {
    let {downloadStatus, lastSuccess, lastCheck, expires,
         softExpiration, errors, version, requiredVersion,
         downloadCount} = this;

    yield* super.serialize();

    if (downloadStatus)
      yield "downloadStatus=" + downloadStatus;
    if (lastSuccess)
      yield "lastSuccess=" + lastSuccess;
    if (lastCheck)
      yield "lastCheck=" + lastCheck;
    if (expires)
      yield "expires=" + expires;
    if (softExpiration)
      yield "softExpiration=" + softExpiration;
    if (errors)
      yield "errors=" + errors;
    if (version)
      yield "version=" + version;
    if (requiredVersion)
      yield "requiredVersion=" + requiredVersion;
    if (downloadCount)
      yield "downloadCount=" + downloadCount;
  }

  /**
   * Put a benchmarking event
   * @param {string} event benchmarking event
   */
  mark(event) {
    this._p.mark(event);
  }
};

let DownloadableSubscription =
/**
 * The `DownloadableSubscription` class represents a regular filter
 * subscription whose content (filter text) is downloaded from a filter list
 * off the internet from `url`.
 *
 * It will have its property `downloadable` set to `true`.
 *
 * @extends module:subscriptionClasses.CountableSubscription
 */
exports.DownloadableSubscription =
class DownloadableSubscription extends CountableSubscription {
  /** Construct a new DownloadableSubscription
   *
   * @param {string} url The URL of the subscription.
   * @param {string} [title] The title of the subscription.
   *
   * @private
   */
  constructor(url, title) {
    super(url, title);
  }

  /**
   * Whether the subscription is downloadable.
   * @type {boolean}
   * @default <code>true</code>
   */
  get downloadable() {
    return true;
  }
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/synchronizer.js":
/*!**********************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/synchronizer.js ***!
  \**********************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_535823__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * @file Manages synchronization of filter subscriptions.
 */

const {Prefs} = __nested_webpack_require_535823__(/*! prefs */ "./sdk/api/prefs.js");

const {MILLIS_IN_SECOND, MILLIS_IN_MINUTE, MILLIS_IN_HOUR,
       MILLIS_IN_DAY} = __nested_webpack_require_535823__(/*! ./time */ "./node_modules/adblockpluscore/lib/time.js");
const {Downloader, Downloadable} = __nested_webpack_require_535823__(/*! ./downloader */ "./node_modules/adblockpluscore/lib/downloader.js");
const {Filter} = __nested_webpack_require_535823__(/*! ./filterClasses */ "./node_modules/adblockpluscore/lib/filterClasses.js");
const {filterNotifier} = __nested_webpack_require_535823__(/*! ./filterNotifier */ "./node_modules/adblockpluscore/lib/filterNotifier.js");
const {Subscription,
       CountableSubscription} = __nested_webpack_require_535823__(/*! ./subscriptionClasses */ "./node_modules/adblockpluscore/lib/subscriptionClasses.js");
const {analytics} = __nested_webpack_require_535823__(/*! ./analytics */ "./node_modules/adblockpluscore/lib/analytics.js");
const {parseFilterList} = __nested_webpack_require_535823__(/*! ./filters/lists.js */ "./node_modules/adblockpluscore/lib/filters/lists.js");

const INITIAL_DELAY = 1 * MILLIS_IN_MINUTE;
const CHECK_INTERVAL = 1 * MILLIS_IN_HOUR;
const DEFAULT_EXPIRATION_INTERVAL = 5 * MILLIS_IN_DAY;

let getPreferredMillis = (field, fallback) =>
                          field in Prefs ? Prefs[field] : fallback;

/**
 * Downloads filter subscriptions whenever necessary.
 */
class Synchronizer {
  /**
   * Construct a new synchronizer.
   * @param {FilterStorage} [filterStorage] The associated filter storage.
   */
  constructor(filterStorage) {
    if (filterStorage == null || typeof filterStorage != "object")
      throw Error("filterStorage must be a valid object");

    /**
     * Whether the downloading of subscriptions has been started.
     * @private
     */
    this._started = false;

    /**
     * The object providing actual downloading functionality.
     * @type {module:downloader.Downloader}
     */
    this._downloader = new Downloader(this._getDownloadables.bind(this));

    this._downloader.onExpirationChange = this._onExpirationChange.bind(this);
    this._downloader.onDownloadStarted = this._onDownloadStarted.bind(this);
    this._downloader.onDownloadSuccess = this._onDownloadSuccess.bind(this);
    this._downloader.onDownloadError = this._onDownloadError.bind(this);

    this._filterStorage = filterStorage;

    // allow subscription to update themselves once re-enabled if needed.
    CountableSubscription.useSynchronizer(this);
  }

  /**
   * Starts downloading subscriptions.
   *
   * No subscriptions are downloaded until this function has been called at
   * least once.
   */
  start() {
    if (this._started)
      return;

    this._downloader.scheduleChecks(
      getPreferredMillis("subscriptions_check_interval", CHECK_INTERVAL),
      getPreferredMillis("subscriptions_initial_delay", INITIAL_DELAY)
    );
    this._started = true;
  }

  /**
   * Clear any further downloader scheduled check and set its internal state
   * as not started.
   */
  stop() {
    this._started = false;
    this._downloader.unscheduleChecks();
  }

  /**
   * Checks whether a subscription is currently being downloaded.
   * @param {string} url  URL of the subscription
   * @returns {boolean}
   */
  isExecuting(url) {
    return this._downloader.isDownloading(url);
  }

  /**
   * Starts the download of a subscription if it is downloadable.
   *
   * @param {module:subscriptionClasses.CountableSubscription} subscription
   *   Subscription to be downloaded
   * @param {boolean} manual
   *   `true` for a manually started download (should not trigger fallback
   *   requests)
   */
  execute(subscription, manual) {
    this._downloader.download(this._getDownloadable(subscription, manual));
  }

  /**
   * Yields `{@link module:downloader.Downloadable Downloadable}` instances for
   * all subscriptions that can be downloaded.
   * @yields {module:downloader.Downloadable}
   */
  *_getDownloadables() {
    if (!Prefs.subscriptions_autoupdate)
      return;

    for (let subscription of this._filterStorage.subscriptions()) {
      if (subscription instanceof CountableSubscription)
        yield this._getDownloadable(subscription, false);
    }
  }

  /**
   * Creates a `{@link module:downloader.Downloadable Downloadable}` instance
   * for a subscription.
   * @param {module:subscriptionClasses.Subscription} subscription
   * @param {boolean} manual
   * @returns {module:downloader.Downloadable}
   */
  _getDownloadable(subscription, manual) {
    let {url, lastDownload, lastSuccess, lastCheck, version, softExpiration,
         expires, downloadCount, disabled, downloadable,
         countable} = subscription;

    let result = new Downloadable(url);

    if (analytics.isTrusted(url))
      result.firstVersion = analytics.getFirstVersion();

    if (lastDownload != lastSuccess)
      result.lastError = lastDownload * MILLIS_IN_SECOND;

    result.lastCheck = lastCheck * MILLIS_IN_SECOND;
    result.lastVersion = version;
    result.softExpiration = softExpiration * MILLIS_IN_SECOND;
    result.hardExpiration = expires * MILLIS_IN_SECOND;
    result.manual = manual;
    result.downloadCount = downloadCount;
    result.disabled = disabled;
    if (disabled || (countable && !downloadable))
      result.method = "HEAD";

    return result;
  }

  _onExpirationChange(downloadable) {
    let subscription = Subscription.fromURL(downloadable.url);
    subscription.lastCheck = Math.round(
      downloadable.lastCheck / MILLIS_IN_SECOND
    );
    subscription.softExpiration = Math.round(
      downloadable.softExpiration / MILLIS_IN_SECOND
    );
    subscription.expires = Math.round(
      downloadable.hardExpiration / MILLIS_IN_SECOND
    );
  }

  _onDownloadStarted(downloadable) {
    let subscription = Subscription.fromURL(downloadable.url);
    filterNotifier.emit("subscription.downloading", subscription);
    subscription.mark("downloading.started");
  }

  _onDownloadSuccess(downloadable, responseText, errorCallback,
                     redirectCallback) {
    let subscription = Subscription.fromURL(downloadable.redirectURL ||
                                            downloadable.url);
    subscription.mark("downloading.finished");
    subscription.mark("parsing.started");

    let isHEAD = downloadable.method === "HEAD";

    let {error, lines, params,
         minVersion} = isHEAD ? {params: {}} : parseFilterList(responseText);

    if (error)
      return errorCallback(error);

    if (params.redirect)
      return redirectCallback(params.redirect);

    subscription.mark("parsing.finished");

    // Handle redirects
    if (downloadable.redirectURL &&
        downloadable.redirectURL != downloadable.url) {
      let oldSubscription = Subscription.fromURL(downloadable.url);
      subscription.title = oldSubscription.title;
      subscription.disabled = oldSubscription.disabled;
      subscription.lastCheck = oldSubscription.lastCheck;

      let listed = this._filterStorage.hasSubscription(oldSubscription);
      if (listed)
        this._filterStorage.removeSubscription(oldSubscription);

      Subscription.knownSubscriptions.delete(oldSubscription.url);

      if (listed)
        this._filterStorage.addSubscription(subscription);
    }

    // The download actually succeeded
    subscription.lastSuccess = subscription.lastDownload = Math.round(
      Date.now() / MILLIS_IN_SECOND
    );
    subscription.downloadStatus = "synchronize_ok";
    subscription.downloadCount = downloadable.downloadCount;
    subscription.errors = 0;

    // Process parameters
    if (params.homepage) {
      let url;
      try {
        url = new URL(params.homepage);
      }
      catch (e) {
        url = null;
      }

      if (url && (url.protocol == "http:" || url.protocol == "https:"))
        subscription.homepage = url.href;
    }

    if (params.title) {
      subscription.title = params.title;
      subscription.fixedTitle = true;
    }
    else {
      subscription.fixedTitle = false;
    }

    if (params.version) {
      subscription.version = parseInt(params.version, 10);

      if (analytics.isTrusted(downloadable.redirectURL || downloadable.url))
        analytics.recordVersion(params.version);
    }
    else {
      subscription.version = isHEAD ? downloadable.lastVersion : 0;
    }

    if (subscription.type)
      subscription.abtest = params.abtest;

    let headExpInterval = getPreferredMillis(
      "subscriptions_head_expiration_interval",
      MILLIS_IN_DAY
    );

    let defaultExpInterval = getPreferredMillis(
      "subscriptions_default_expiration_interval",
      DEFAULT_EXPIRATION_INTERVAL
    );

    let expirationInterval = isHEAD ? headExpInterval : defaultExpInterval;

    if (params.expires) {
      let match = /^(\d+)\s*(h)?/.exec(params.expires);
      if (match) {
        let interval = parseInt(match[1], 10);
        if (match[2])
          expirationInterval = interval * MILLIS_IN_HOUR;
        else
          expirationInterval = interval * MILLIS_IN_DAY;
      }
    }

    let [
      softExpiration,
      hardExpiration
    ] = this._downloader.processExpirationInterval(expirationInterval);
    subscription.softExpiration = Math.round(softExpiration / MILLIS_IN_SECOND);
    subscription.expires = Math.round(hardExpiration / MILLIS_IN_SECOND);

    if (minVersion)
      subscription.requiredVersion = minVersion;
    else
      delete subscription.requiredVersion;

    // In case of HEAD request (disabled subscription) notify an update so that
    // the last version of the subscription will be stored for the next time.
    if (isHEAD)
      filterNotifier.emit("subscription.updated", subscription);
    else
      this._processFilters(subscription, lines);
  }

  _onDownloadError(downloadable, downloadURL, error, responseStatus,
                   redirectCallback) {
    let subscription = Subscription.fromURL(downloadable.url);
    subscription.mark("downloading.finished");
    subscription.lastDownload = Math.round(Date.now() / MILLIS_IN_SECOND);
    subscription.downloadStatus = error;

    // Request fallback URL if necessary - for automatic updates only
    if (!downloadable.manual) {
      subscription.errors++;

      if (redirectCallback &&
          subscription.errors >= Prefs.subscriptions_fallbackerrors &&
          /^https?:\/\//i.test(subscription.url)) {
        subscription.errors = 0;

        let fallbackURL = Prefs.subscriptions_fallbackurl;
        const {addonVersion} = __nested_webpack_require_535823__(/*! info */ "./sdk/api/info.js");
        fallbackURL = fallbackURL.replace(/%VERSION%/g,
                                          encodeURIComponent(addonVersion));
        fallbackURL = fallbackURL.replace(/%SUBSCRIPTION%/g,
                                          encodeURIComponent(subscription.url));
        fallbackURL = fallbackURL.replace(/%URL%/g,
                                          encodeURIComponent(downloadURL));
        fallbackURL = fallbackURL.replace(/%ERROR%/g,
                                          encodeURIComponent(error));
        fallbackURL = fallbackURL.replace(/%RESPONSESTATUS%/g,
                                          encodeURIComponent(responseStatus));

        let initObj = {
          cache: "no-store",
          credentials: "omit",
          referrer: "no-referrer",
          method: downloadable.method
        };

        fetch(fallbackURL, initObj).then(response => response.text())
          .then(responseText => {
            if (!this._filterStorage.hasSubscription(subscription))
              return;

            let match = /^(\d+)(?:\s+(\S+))?$/.exec(responseText);
            if (match && match[1] == "301" &&    // Moved permanently
              match[2] && /^https?:\/\//i.test(match[2])) {
              redirectCallback(match[2]);
            }
            // Gone
            else if (match && match[1] == "410") {
              let data = "[Adblock]\n" +
              [...subscription.filterText()].join("\n");
              redirectCallback("data:text/plain," + encodeURIComponent(data));
            }
          });
      }
    }
  }

  /**
   * Given a valid subscription and some text, it parses all filters and add
   * these in bulk to the specified subscription.
   * @param {module:subscriptionClasses.Subscription} subscription The
   *  Subscription to use as reference for manually added filters.
   * @param {string} filters The filters file/text to add.
   * @param {function} errorCallback A callback invoked if errors occur.
   */
  addSubscriptionFilters(
    subscription, filters, errorCallback
  ) {
    let {error, lines} = parseFilterList(filters);
    if (error)
      errorCallback(error);
    else
      this._processFilters(subscription, lines);
  }

  /**
   * Given a list of parsed filters, normalize each line and update the
   * subscription.
   * @private
   * @param {module:subscriptionClasses.Subscription} subscription The
   *  Subscription to use as reference for manually added filters.
   * @param {string[]} lines The parsed filters lines. The first line
   will be skipped over as it is supposed to contain the header.
  */
  _processFilters(subscription, lines) {
    subscription.mark("processing.started");

    lines.shift();
    let filterText = [];
    for (let line of lines) {
      line = Filter.normalize(line);
      if (line)
        filterText.push(line);
    }

    this._filterStorage.updateSubscriptionFilters(subscription, filterText);

    subscription.mark("processing.finished");
  }
}

exports.Synchronizer = Synchronizer;


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/time.js":
/*!**************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/time.js ***!
  \**************************************************/
/***/ ((__unused_webpack_module, exports) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



/**
 * Number of milliseconds in a second.
 * @const {number}
 * @default 1000
 * @package
 */
exports.MILLIS_IN_SECOND = 1000;

/**
 * Number of milliseconds in a minute.
 * @const {number}
 * @default 60000
 * @package
 */
exports.MILLIS_IN_MINUTE = 60000;

/**
 * Number of milliseconds in an hour.
 * @const {number}
 * @default 3600000
 * @package
 */
exports.MILLIS_IN_HOUR = 3600000;

/**
 * Number of milliseconds in a day.
 * @const {number}
 * @default 86400000
 * @package
 */
exports.MILLIS_IN_DAY = 86400000;


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/url.js":
/*!*************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/url.js ***!
  \*************************************************/
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_551986__) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



const {Cache} = __nested_webpack_require_551986__(/*! ./caching */ "./node_modules/adblockpluscore/lib/caching.js");

const {publicSuffixes} = __nested_webpack_require_551986__(/*! ../data/publicSuffixList.js */ "./node_modules/adblockpluscore/data/publicSuffixList.js");

// ensure no conflict ever happens with inherited properties
Object.setPrototypeOf(publicSuffixes, null);

/**
 * Cache of domain maps.
 *
 * The domains part of filter text (e.g. `example.com,~mail.example.com`) is
 * often repeated across filters. This cache enables deduplication of the
 * `Map` objects that specify on which domains the filter does and does not
 * apply, which reduces memory usage and improves performance.
 *
 * @type {Map.<string, Map.<string, boolean>>}
 */
let domainsCache = new Cache(1000);

/**
 * A `URLInfo` object represents information about a URL.
 *
 * It is returned by `{@link module:url.parseURL parseURL()}`.
 */
class URLInfo {
  /**
   * Creates a `URLInfo` object.
   *
   * @param {string} href The entire URL.
   * @param {string} protocol The protocol scheme of the URL, including the
   *   final `:`.
   * @param {string} [hostname] The hostname of the URL.
   *
   * @private
   */
  constructor(href, protocol, hostname = "") {
    this._href = href;
    this._protocol = protocol;
    this._hostname = hostname;
  }

  /**
   * The entire URL.
   * @type {string}
   */
  get href() {
    return this._href;
  }

  /**
   * The protocol scheme of the URL, including the final `:`.
   * @type {string}
   */
  get protocol() {
    return this._protocol;
  }

  /**
   * The hostname of the URL.
   * @type {string}
   */
  get hostname() {
    return this._hostname;
  }

  /**
   * Returns the entire URL.
   * @returns {string} The entire URL.
   */
  toString() {
    return this._href;
  }
}

let parseURL =
/**
 * Parses a URL to extract the protocol and the hostname.
 *
 * __This is a lightweight alternative to the native `URL` object intended for
 * use primarily within Adblock Plus. Unlike the `URL` object, the `parseURL()`
 * function is not robust and will give incorrect results for invalid URLs. Use
 * this function with valid,
 * [normalized](https://url.spec.whatwg.org/#concept-basic-url-parser),
 * properly encoded (IDNA, etc.) URLs only.__
 *
 * @param {string} url The URL.
 *
 * @returns {module:url~URLInfo} Information about the URL.
 *
 * @public
 */
exports.parseURL = function parseURL(url) {
  let match = /^([^:]+:)(?:\/\/(?:[^/]*@)?(\[[^\]]*\]|[^:/]+))?/.exec(url);
  return new URLInfo(url, match[1], match[2]);
};

let domainSuffixes =
/**
 * Yields all suffixes for a domain.
 *
 * For example, given the domain `www.example.com`, this function yields
 * `www.example.com`, `example.com`, and `com`, in that order.
 *
 * If the domain ends with a dot, the dot is ignored.
 *
 * @param {string} domain The domain.
 * @param {boolean} [includeBlank] Whether to include the blank suffix at the
 *   end.
 *
 * @generator
 * @yields {string} The next suffix for the domain.
 *
 * @package
 */
exports.domainSuffixes = function* domainSuffixes(
  domain, includeBlank = false
) {
  // Since any IP address is already expected to be normalized, there's no need
  // to validate it.
  if (isIPAddress(domain)) {
    yield domain;
  }
  else {
    if (domain[domain.length - 1] == ".")
      domain = domain.substring(0, domain.length - 1);

    while (domain != "") {
      yield domain;

      let dotIndex = domain.indexOf(".");
      domain = dotIndex == -1 ? "" : domain.substr(dotIndex + 1);
    }
  }

  if (includeBlank)
    yield "";
};

/**
 * Checks whether the given hostname refers to
 * {@link https://en.wikipedia.org/wiki/Localhost localhost}.
 *
 * If the hostname is `localhost`, `127.0.0.1`, or `[::1]`, the function
 * returns `true`; otherwise, it returns `false`.
 *
 * @param {string} hostname The hostname.
 *
 * @returns {boolean} Whether the hostname refers to localhost.
 *
 * @package
 */
exports.isLocalhost = function isLocalhost(hostname) {
  return hostname == "localhost" || hostname == "127.0.0.1" ||
         hostname == "[::1]";
};

/**
 * Checks whether the given hostname is an IP address.
 *
 * Unlike `{@link module:url~isValidIPv4Address isValidIPv4Address()}`, this
 * function only checks whether the hostname _looks like_ an IP address. Use
 * this function with valid, normalized, properly encoded (IDNA) hostnames
 * only.
 *
 * @param {string} hostname An IDNA-encoded hostname.
 *
 * @returns {boolean} Whether the hostname is an IP address.
 */
function isIPAddress(hostname) {
  // Does it look like an IPv6 address?
  if (hostname[0] == "[" && hostname[hostname.length - 1] == "]")
    return true;

  // Note: The first condition helps us avoid the more expensive regular
  // expression match for most hostnames.
  return hostname[hostname.length - 1] >= 0 &&
         /^\d+\.\d+\.\d+\.\d+$/.test(hostname);
}

/**
 * Checks whether a given address is a valid IPv4 address.
 *
 * Only a normalized IPv4 address is considered valid. e.g. `0x7f.0x0.0x0.0x1`
 * is invalid, whereas `127.0.0.1` is valid.
 *
 * @param {string} address The address to check.
 *
 * @returns {boolean} Whether the address is a valid IPv4 address.
 */
function isValidIPv4Address(address) {
  return /^(((2[0-4]|1[0-9]|[1-9])?[0-9]|25[0-5])\.){4}$/.test(address + ".");
}

/**
 * Checks whether a given hostname is valid.
 *
 * This function is used for filter validation.
 *
 * A hostname occurring in a filter must be normalized. For example,
 * <code>&#x1f642;</code> (slightly smiling face) should be normalized to
 * `xn--938h`; otherwise this function returns `false` for such a hostname.
 * Similarly, IP addresses should be normalized.
 *
 * @param {string} hostname The hostname to check.
 *
 * @returns {boolean} Whether the hostname is valid.
 */
exports.isValidHostname = function isValidHostname(hostname) {
  if (isValidIPv4Address(hostname))
    return true;

  // This does not in fact validate the IPv6 address but it's alright for now.
  if (hostname[0] == "[" && hostname[hostname.length - 1] == "]")
    return true;

  // Based on
  // https://en.wikipedia.org/wiki/Hostname#Restrictions_on_valid_hostnames
  if (hostname[hostname.length - 1] == ".")
    hostname = hostname.substring(0, hostname.length - 1);

  if (hostname.length > 253)
    return false;

  let labels = hostname.split(".");

  for (let label of labels) {
    if (!/^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$/i.test(label))
      return false;
  }

  // Based on https://tools.ietf.org/html/rfc3696#section-2
  if (!/\D/.test(labels[labels.length - 1]))
    return false;

  return true;
};

let getBaseDomain =
/**
 * Gets the base domain for the given hostname.
 *
 * @param {string} hostname
 *
 * @returns {string}
 *
 * @package
 */
exports.getBaseDomain = function getBaseDomain(hostname) {
  let slices = [];
  let cutoff = NaN;

  for (let suffix of domainSuffixes(hostname)) {
    slices.push(suffix);

    let offset = publicSuffixes[suffix];

    if (typeof offset == "number") {
      cutoff = slices.length - 1 - offset;
      break;
    }
  }

  if (isNaN(cutoff))
    return slices.length > 2 ? slices[slices.length - 2] : hostname;

  if (cutoff <= 0)
    return hostname;

  return slices[cutoff];
};

/**
 * Checks whether a request's origin is different from its document's origin.
 *
 * @param {string} requestHostname The IDNA-encoded hostname of the request.
 * @param {string} documentHostname The IDNA-encoded hostname of the document.
 *
 * @returns {boolean}
 */
function isThirdParty(requestHostname, documentHostname) {
  if (requestHostname[requestHostname.length - 1] == ".")
    requestHostname = requestHostname.substring(0, requestHostname.length - 1);

  if (documentHostname[documentHostname.length - 1] == ".") {
    documentHostname =
      documentHostname.substring(0, documentHostname.length - 1);
  }

  if (requestHostname == documentHostname)
    return false;

  if (!requestHostname || !documentHostname)
    return true;

  if (isIPAddress(requestHostname) || isIPAddress(documentHostname))
    return true;

  return getBaseDomain(requestHostname) != getBaseDomain(documentHostname);
}

let URLRequest =
/**
 * The `URLRequest` class represents a URL request.
 */
exports.URLRequest = class URLRequest {
  /**
   * @private
   */
  constructor() {}

  /**
   * The URL of the request.
   * @type {string}
   */
  get href() {
    return this._href;
  }

  /**
   * Information about the URL of the request.
   * @type {module:url~URLInfo}
   * @package
   */
  get urlInfo() {
    if (!this._urlInfo)
      this._urlInfo = parseURL(this._href);

    return this._urlInfo;
  }

  /**
   * The hostname of the document making the request.
   * @type {?string}
   */
  get documentHostname() {
    return this._documentHostname == null ? null : this._documentHostname;
  }

  /**
   * Whether this is a third-party request.
   * @type {boolean}
   */
  get thirdParty() {
    if (typeof this._thirdParty == "undefined") {
      this._thirdParty = this._documentHostname == null ? false :
        isThirdParty(this.urlInfo.hostname,
          this._documentHostname);
    }

    return this._thirdParty;
  }

  /**
   * Returns the URL of the request.
   * @returns {string}
   */
  toString() {
    return this._href;
  }

  /**
   * The lower-case version of the URL of the request.
   * @type {string}
   * @package
   */
  get lowerCaseHref() {
    if (this._lowerCaseHref == null)
      this._lowerCaseHref = this._href.toLowerCase();

    return this._lowerCaseHref;
  }
};

/**
 * Returns a `{@link module:url.URLRequest URLRequest}` object for the given
 * URL.
 *
 * @param {string|module:url~URLInfo|URL} url The URL. If this is a `string`,
 *   it must be a canonicalized URL (see
 *   `{@link module:url.parseURL parseURL()}`).
 * @param {?string} [documentHostname] The IDNA-encoded hostname of the
 *   document making the request.
 *
 * @returns {module:url.URLRequest}
 */
exports.URLRequest.from = function(url, documentHostname = null) {
  let request = new URLRequest();

  if (typeof url == "string") {
    request._href = url;
  }
  else {
    request._urlInfo = url instanceof URLInfo ? url :
      new URLInfo(url.href, url.protocol, url.hostname);
    request._href = url.href;
  }

  if (documentHostname != null)
    request._documentHostname = documentHostname;

  return request;
};

/**
 * Parses the domains part of a filter text
 * (e.g. `example.com,~mail.example.com`) into a `Map` object.
 *
 * @param {string} source The domains part of a filter text.
 * @param {string} separator The string used to separate two or more domains in
 *   the domains part of a filter text.
 *
 * @returns {?Map.<string, boolean>}
 *
 * @package
 */
exports.parseDomains = function parseDomains(source, separator) {
  let domains = domainsCache.get(source);
  if (typeof domains != "undefined")
    return domains;

  if (source[0] != "~" && !source.includes(separator)) {
    // Fast track for the common one-domain scenario.
    domains = new Map([["", false], [source, true]]);
  }
  else {
    domains = null;

    let hasIncludes = false;
    for (let domain of source.split(separator)) {
      if (domain == "")
        continue;

      let include;
      if (domain[0] == "~") {
        include = false;
        domain = domain.substring(1);
      }
      else {
        include = true;
        hasIncludes = true;
      }

      if (!domains)
        domains = new Map();

      domains.set(domain, include);
    }

    if (domains)
      domains.set("", !hasIncludes);
  }

  domainsCache.set(source, domains);

  return domains;
};


/***/ }),

/***/ "./node_modules/adblockpluscore/lib/versions.js":
/*!******************************************************!*\
  !*** ./node_modules/adblockpluscore/lib/versions.js ***!
  \******************************************************/
/***/ ((__unused_webpack_module, exports) => {

"use strict";
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */



function parseVersionComponent(comp) {
  if (comp == "*")
    return Infinity;
  return parseInt(comp, 10) || 0;
}

/**
 * Compares two versions.
 *
 * @param {string} v1 The first version.
 * @param {string} v2 The second version.
 *
 * @returns {number} `-1` if `v1` is older than `v2`; `1` if `v1` is newer than
 *   `v2`; otherwise `0`.
 *
 * @package
 */
exports.compareVersions = function compareVersions(v1, v2) {
  let regexp = /^(.*?)([a-z].*)?$/i;
  let [, head1, tail1] = regexp.exec(v1);
  let [, head2, tail2] = regexp.exec(v2);
  let components1 = head1.split(".");
  let components2 = head2.split(".");

  for (let i = 0; i < components1.length ||
                  i < components2.length; i++) {
    let result = parseVersionComponent(components1[i]) -
                 parseVersionComponent(components2[i]) || 0;

    if (result < 0)
      return -1;
    else if (result > 0)
      return 1;
  }

  // Compare version suffix (e.g. 0.1alpha < 0.1b1 < 01.b2 < 0.1).
  // However, note that this is a simple string comparision, meaning: b10 < b2
  if (tail1 == tail2)
    return 0;
  if (!tail1 || tail2 && tail1 > tail2)
    return 1;
  return -1;
};


/***/ }),

/***/ "./node_modules/webextension-polyfill/dist/browser-polyfill.js":
/*!*********************************************************************!*\
  !*** ./node_modules/webextension-polyfill/dist/browser-polyfill.js ***!
  \*********************************************************************/
/***/ (function(module, exports) {

var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (global, factory) {
  if (true) {
    !(__WEBPACK_AMD_DEFINE_ARRAY__ = [module], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),
		__WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ?
		(__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__),
		__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
  } else { var mod; }
})(typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : this, function (module) {
  /* webextension-polyfill - v0.8.0 - Tue Apr 20 2021 11:27:38 */

  /* -*- Mode: indent-tabs-mode: nil; js-indent-level: 2 -*- */

  /* vim: set sts=2 sw=2 et tw=80: */

  /* This Source Code Form is subject to the terms of the Mozilla Public
   * License, v. 2.0. If a copy of the MPL was not distributed with this
   * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  "use strict";

  if (typeof browser === "undefined" || Object.getPrototypeOf(browser) !== Object.prototype) {
    const CHROME_SEND_MESSAGE_CALLBACK_NO_RESPONSE_MESSAGE = "The message port closed before a response was received.";
    const SEND_RESPONSE_DEPRECATION_WARNING = "Returning a Promise is the preferred way to send a reply from an onMessage/onMessageExternal listener, as the sendResponse will be removed from the specs (See https://developer.mozilla.org/docs/Mozilla/Add-ons/WebExtensions/API/runtime/onMessage)"; // Wrapping the bulk of this polyfill in a one-time-use function is a minor
    // optimization for Firefox. Since Spidermonkey does not fully parse the
    // contents of a function until the first time it's called, and since it will
    // never actually need to be called, this allows the polyfill to be included
    // in Firefox nearly for free.

    const wrapAPIs = extensionAPIs => {
      // NOTE: apiMetadata is associated to the content of the api-metadata.json file
      // at build time by replacing the following "include" with the content of the
      // JSON file.
      const apiMetadata = {
        "alarms": {
          "clear": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "clearAll": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "get": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "getAll": {
            "minArgs": 0,
            "maxArgs": 0
          }
        },
        "bookmarks": {
          "create": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "get": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getChildren": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getRecent": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getSubTree": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getTree": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "move": {
            "minArgs": 2,
            "maxArgs": 2
          },
          "remove": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "removeTree": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "search": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "update": {
            "minArgs": 2,
            "maxArgs": 2
          }
        },
        "browserAction": {
          "disable": {
            "minArgs": 0,
            "maxArgs": 1,
            "fallbackToNoCallback": true
          },
          "enable": {
            "minArgs": 0,
            "maxArgs": 1,
            "fallbackToNoCallback": true
          },
          "getBadgeBackgroundColor": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getBadgeText": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getPopup": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getTitle": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "openPopup": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "setBadgeBackgroundColor": {
            "minArgs": 1,
            "maxArgs": 1,
            "fallbackToNoCallback": true
          },
          "setBadgeText": {
            "minArgs": 1,
            "maxArgs": 1,
            "fallbackToNoCallback": true
          },
          "setIcon": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "setPopup": {
            "minArgs": 1,
            "maxArgs": 1,
            "fallbackToNoCallback": true
          },
          "setTitle": {
            "minArgs": 1,
            "maxArgs": 1,
            "fallbackToNoCallback": true
          }
        },
        "browsingData": {
          "remove": {
            "minArgs": 2,
            "maxArgs": 2
          },
          "removeCache": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "removeCookies": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "removeDownloads": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "removeFormData": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "removeHistory": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "removeLocalStorage": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "removePasswords": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "removePluginData": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "settings": {
            "minArgs": 0,
            "maxArgs": 0
          }
        },
        "commands": {
          "getAll": {
            "minArgs": 0,
            "maxArgs": 0
          }
        },
        "contextMenus": {
          "remove": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "removeAll": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "update": {
            "minArgs": 2,
            "maxArgs": 2
          }
        },
        "cookies": {
          "get": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getAll": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getAllCookieStores": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "remove": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "set": {
            "minArgs": 1,
            "maxArgs": 1
          }
        },
        "devtools": {
          "inspectedWindow": {
            "eval": {
              "minArgs": 1,
              "maxArgs": 2,
              "singleCallbackArg": false
            }
          },
          "panels": {
            "create": {
              "minArgs": 3,
              "maxArgs": 3,
              "singleCallbackArg": true
            },
            "elements": {
              "createSidebarPane": {
                "minArgs": 1,
                "maxArgs": 1
              }
            }
          }
        },
        "downloads": {
          "cancel": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "download": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "erase": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getFileIcon": {
            "minArgs": 1,
            "maxArgs": 2
          },
          "open": {
            "minArgs": 1,
            "maxArgs": 1,
            "fallbackToNoCallback": true
          },
          "pause": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "removeFile": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "resume": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "search": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "show": {
            "minArgs": 1,
            "maxArgs": 1,
            "fallbackToNoCallback": true
          }
        },
        "extension": {
          "isAllowedFileSchemeAccess": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "isAllowedIncognitoAccess": {
            "minArgs": 0,
            "maxArgs": 0
          }
        },
        "history": {
          "addUrl": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "deleteAll": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "deleteRange": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "deleteUrl": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getVisits": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "search": {
            "minArgs": 1,
            "maxArgs": 1
          }
        },
        "i18n": {
          "detectLanguage": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getAcceptLanguages": {
            "minArgs": 0,
            "maxArgs": 0
          }
        },
        "identity": {
          "launchWebAuthFlow": {
            "minArgs": 1,
            "maxArgs": 1
          }
        },
        "idle": {
          "queryState": {
            "minArgs": 1,
            "maxArgs": 1
          }
        },
        "management": {
          "get": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getAll": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "getSelf": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "setEnabled": {
            "minArgs": 2,
            "maxArgs": 2
          },
          "uninstallSelf": {
            "minArgs": 0,
            "maxArgs": 1
          }
        },
        "notifications": {
          "clear": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "create": {
            "minArgs": 1,
            "maxArgs": 2
          },
          "getAll": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "getPermissionLevel": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "update": {
            "minArgs": 2,
            "maxArgs": 2
          }
        },
        "pageAction": {
          "getPopup": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getTitle": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "hide": {
            "minArgs": 1,
            "maxArgs": 1,
            "fallbackToNoCallback": true
          },
          "setIcon": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "setPopup": {
            "minArgs": 1,
            "maxArgs": 1,
            "fallbackToNoCallback": true
          },
          "setTitle": {
            "minArgs": 1,
            "maxArgs": 1,
            "fallbackToNoCallback": true
          },
          "show": {
            "minArgs": 1,
            "maxArgs": 1,
            "fallbackToNoCallback": true
          }
        },
        "permissions": {
          "contains": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getAll": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "remove": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "request": {
            "minArgs": 1,
            "maxArgs": 1
          }
        },
        "runtime": {
          "getBackgroundPage": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "getPlatformInfo": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "openOptionsPage": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "requestUpdateCheck": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "sendMessage": {
            "minArgs": 1,
            "maxArgs": 3
          },
          "sendNativeMessage": {
            "minArgs": 2,
            "maxArgs": 2
          },
          "setUninstallURL": {
            "minArgs": 1,
            "maxArgs": 1
          }
        },
        "sessions": {
          "getDevices": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "getRecentlyClosed": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "restore": {
            "minArgs": 0,
            "maxArgs": 1
          }
        },
        "storage": {
          "local": {
            "clear": {
              "minArgs": 0,
              "maxArgs": 0
            },
            "get": {
              "minArgs": 0,
              "maxArgs": 1
            },
            "getBytesInUse": {
              "minArgs": 0,
              "maxArgs": 1
            },
            "remove": {
              "minArgs": 1,
              "maxArgs": 1
            },
            "set": {
              "minArgs": 1,
              "maxArgs": 1
            }
          },
          "managed": {
            "get": {
              "minArgs": 0,
              "maxArgs": 1
            },
            "getBytesInUse": {
              "minArgs": 0,
              "maxArgs": 1
            }
          },
          "sync": {
            "clear": {
              "minArgs": 0,
              "maxArgs": 0
            },
            "get": {
              "minArgs": 0,
              "maxArgs": 1
            },
            "getBytesInUse": {
              "minArgs": 0,
              "maxArgs": 1
            },
            "remove": {
              "minArgs": 1,
              "maxArgs": 1
            },
            "set": {
              "minArgs": 1,
              "maxArgs": 1
            }
          }
        },
        "tabs": {
          "captureVisibleTab": {
            "minArgs": 0,
            "maxArgs": 2
          },
          "create": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "detectLanguage": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "discard": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "duplicate": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "executeScript": {
            "minArgs": 1,
            "maxArgs": 2
          },
          "get": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getCurrent": {
            "minArgs": 0,
            "maxArgs": 0
          },
          "getZoom": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "getZoomSettings": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "goBack": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "goForward": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "highlight": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "insertCSS": {
            "minArgs": 1,
            "maxArgs": 2
          },
          "move": {
            "minArgs": 2,
            "maxArgs": 2
          },
          "query": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "reload": {
            "minArgs": 0,
            "maxArgs": 2
          },
          "remove": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "removeCSS": {
            "minArgs": 1,
            "maxArgs": 2
          },
          "sendMessage": {
            "minArgs": 2,
            "maxArgs": 3
          },
          "setZoom": {
            "minArgs": 1,
            "maxArgs": 2
          },
          "setZoomSettings": {
            "minArgs": 1,
            "maxArgs": 2
          },
          "update": {
            "minArgs": 1,
            "maxArgs": 2
          }
        },
        "topSites": {
          "get": {
            "minArgs": 0,
            "maxArgs": 0
          }
        },
        "webNavigation": {
          "getAllFrames": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "getFrame": {
            "minArgs": 1,
            "maxArgs": 1
          }
        },
        "webRequest": {
          "handlerBehaviorChanged": {
            "minArgs": 0,
            "maxArgs": 0
          }
        },
        "windows": {
          "create": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "get": {
            "minArgs": 1,
            "maxArgs": 2
          },
          "getAll": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "getCurrent": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "getLastFocused": {
            "minArgs": 0,
            "maxArgs": 1
          },
          "remove": {
            "minArgs": 1,
            "maxArgs": 1
          },
          "update": {
            "minArgs": 2,
            "maxArgs": 2
          }
        }
      };

      if (Object.keys(apiMetadata).length === 0) {
        throw new Error("api-metadata.json has not been included in browser-polyfill");
      }
      /**
       * A WeakMap subclass which creates and stores a value for any key which does
       * not exist when accessed, but behaves exactly as an ordinary WeakMap
       * otherwise.
       *
       * @param {function} createItem
       *        A function which will be called in order to create the value for any
       *        key which does not exist, the first time it is accessed. The
       *        function receives, as its only argument, the key being created.
       */


      class DefaultWeakMap extends WeakMap {
        constructor(createItem, items = undefined) {
          super(items);
          this.createItem = createItem;
        }

        get(key) {
          if (!this.has(key)) {
            this.set(key, this.createItem(key));
          }

          return super.get(key);
        }

      }
      /**
       * Returns true if the given object is an object with a `then` method, and can
       * therefore be assumed to behave as a Promise.
       *
       * @param {*} value The value to test.
       * @returns {boolean} True if the value is thenable.
       */


      const isThenable = value => {
        return value && typeof value === "object" && typeof value.then === "function";
      };
      /**
       * Creates and returns a function which, when called, will resolve or reject
       * the given promise based on how it is called:
       *
       * - If, when called, `chrome.runtime.lastError` contains a non-null object,
       *   the promise is rejected with that value.
       * - If the function is called with exactly one argument, the promise is
       *   resolved to that value.
       * - Otherwise, the promise is resolved to an array containing all of the
       *   function's arguments.
       *
       * @param {object} promise
       *        An object containing the resolution and rejection functions of a
       *        promise.
       * @param {function} promise.resolve
       *        The promise's resolution function.
       * @param {function} promise.reject
       *        The promise's rejection function.
       * @param {object} metadata
       *        Metadata about the wrapped method which has created the callback.
       * @param {boolean} metadata.singleCallbackArg
       *        Whether or not the promise is resolved with only the first
       *        argument of the callback, alternatively an array of all the
       *        callback arguments is resolved. By default, if the callback
       *        function is invoked with only a single argument, that will be
       *        resolved to the promise, while all arguments will be resolved as
       *        an array if multiple are given.
       *
       * @returns {function}
       *        The generated callback function.
       */


      const makeCallback = (promise, metadata) => {
        return (...callbackArgs) => {
          if (extensionAPIs.runtime.lastError) {
            promise.reject(new Error(extensionAPIs.runtime.lastError.message));
          } else if (metadata.singleCallbackArg || callbackArgs.length <= 1 && metadata.singleCallbackArg !== false) {
            promise.resolve(callbackArgs[0]);
          } else {
            promise.resolve(callbackArgs);
          }
        };
      };

      const pluralizeArguments = numArgs => numArgs == 1 ? "argument" : "arguments";
      /**
       * Creates a wrapper function for a method with the given name and metadata.
       *
       * @param {string} name
       *        The name of the method which is being wrapped.
       * @param {object} metadata
       *        Metadata about the method being wrapped.
       * @param {integer} metadata.minArgs
       *        The minimum number of arguments which must be passed to the
       *        function. If called with fewer than this number of arguments, the
       *        wrapper will raise an exception.
       * @param {integer} metadata.maxArgs
       *        The maximum number of arguments which may be passed to the
       *        function. If called with more than this number of arguments, the
       *        wrapper will raise an exception.
       * @param {boolean} metadata.singleCallbackArg
       *        Whether or not the promise is resolved with only the first
       *        argument of the callback, alternatively an array of all the
       *        callback arguments is resolved. By default, if the callback
       *        function is invoked with only a single argument, that will be
       *        resolved to the promise, while all arguments will be resolved as
       *        an array if multiple are given.
       *
       * @returns {function(object, ...*)}
       *       The generated wrapper function.
       */


      const wrapAsyncFunction = (name, metadata) => {
        return function asyncFunctionWrapper(target, ...args) {
          if (args.length < metadata.minArgs) {
            throw new Error(`Expected at least ${metadata.minArgs} ${pluralizeArguments(metadata.minArgs)} for ${name}(), got ${args.length}`);
          }

          if (args.length > metadata.maxArgs) {
            throw new Error(`Expected at most ${metadata.maxArgs} ${pluralizeArguments(metadata.maxArgs)} for ${name}(), got ${args.length}`);
          }

          return new Promise((resolve, reject) => {
            if (metadata.fallbackToNoCallback) {
              // This API method has currently no callback on Chrome, but it return a promise on Firefox,
              // and so the polyfill will try to call it with a callback first, and it will fallback
              // to not passing the callback if the first call fails.
              try {
                target[name](...args, makeCallback({
                  resolve,
                  reject
                }, metadata));
              } catch (cbError) {
                console.warn(`${name} API method doesn't seem to support the callback parameter, ` + "falling back to call it without a callback: ", cbError);
                target[name](...args); // Update the API method metadata, so that the next API calls will not try to
                // use the unsupported callback anymore.

                metadata.fallbackToNoCallback = false;
                metadata.noCallback = true;
                resolve();
              }
            } else if (metadata.noCallback) {
              target[name](...args);
              resolve();
            } else {
              target[name](...args, makeCallback({
                resolve,
                reject
              }, metadata));
            }
          });
        };
      };
      /**
       * Wraps an existing method of the target object, so that calls to it are
       * intercepted by the given wrapper function. The wrapper function receives,
       * as its first argument, the original `target` object, followed by each of
       * the arguments passed to the original method.
       *
       * @param {object} target
       *        The original target object that the wrapped method belongs to.
       * @param {function} method
       *        The method being wrapped. This is used as the target of the Proxy
       *        object which is created to wrap the method.
       * @param {function} wrapper
       *        The wrapper function which is called in place of a direct invocation
       *        of the wrapped method.
       *
       * @returns {Proxy<function>}
       *        A Proxy object for the given method, which invokes the given wrapper
       *        method in its place.
       */


      const wrapMethod = (target, method, wrapper) => {
        return new Proxy(method, {
          apply(targetMethod, thisObj, args) {
            return wrapper.call(thisObj, target, ...args);
          }

        });
      };

      let hasOwnProperty = Function.call.bind(Object.prototype.hasOwnProperty);
      /**
       * Wraps an object in a Proxy which intercepts and wraps certain methods
       * based on the given `wrappers` and `metadata` objects.
       *
       * @param {object} target
       *        The target object to wrap.
       *
       * @param {object} [wrappers = {}]
       *        An object tree containing wrapper functions for special cases. Any
       *        function present in this object tree is called in place of the
       *        method in the same location in the `target` object tree. These
       *        wrapper methods are invoked as described in {@see wrapMethod}.
       *
       * @param {object} [metadata = {}]
       *        An object tree containing metadata used to automatically generate
       *        Promise-based wrapper functions for asynchronous. Any function in
       *        the `target` object tree which has a corresponding metadata object
       *        in the same location in the `metadata` tree is replaced with an
       *        automatically-generated wrapper function, as described in
       *        {@see wrapAsyncFunction}
       *
       * @returns {Proxy<object>}
       */

      const wrapObject = (target, wrappers = {}, metadata = {}) => {
        let cache = Object.create(null);
        let handlers = {
          has(proxyTarget, prop) {
            return prop in target || prop in cache;
          },

          get(proxyTarget, prop, receiver) {
            if (prop in cache) {
              return cache[prop];
            }

            if (!(prop in target)) {
              return undefined;
            }

            let value = target[prop];

            if (typeof value === "function") {
              // This is a method on the underlying object. Check if we need to do
              // any wrapping.
              if (typeof wrappers[prop] === "function") {
                // We have a special-case wrapper for this method.
                value = wrapMethod(target, target[prop], wrappers[prop]);
              } else if (hasOwnProperty(metadata, prop)) {
                // This is an async method that we have metadata for. Create a
                // Promise wrapper for it.
                let wrapper = wrapAsyncFunction(prop, metadata[prop]);
                value = wrapMethod(target, target[prop], wrapper);
              } else {
                // This is a method that we don't know or care about. Return the
                // original method, bound to the underlying object.
                value = value.bind(target);
              }
            } else if (typeof value === "object" && value !== null && (hasOwnProperty(wrappers, prop) || hasOwnProperty(metadata, prop))) {
              // This is an object that we need to do some wrapping for the children
              // of. Create a sub-object wrapper for it with the appropriate child
              // metadata.
              value = wrapObject(value, wrappers[prop], metadata[prop]);
            } else if (hasOwnProperty(metadata, "*")) {
              // Wrap all properties in * namespace.
              value = wrapObject(value, wrappers[prop], metadata["*"]);
            } else {
              // We don't need to do any wrapping for this property,
              // so just forward all access to the underlying object.
              Object.defineProperty(cache, prop, {
                configurable: true,
                enumerable: true,

                get() {
                  return target[prop];
                },

                set(value) {
                  target[prop] = value;
                }

              });
              return value;
            }

            cache[prop] = value;
            return value;
          },

          set(proxyTarget, prop, value, receiver) {
            if (prop in cache) {
              cache[prop] = value;
            } else {
              target[prop] = value;
            }

            return true;
          },

          defineProperty(proxyTarget, prop, desc) {
            return Reflect.defineProperty(cache, prop, desc);
          },

          deleteProperty(proxyTarget, prop) {
            return Reflect.deleteProperty(cache, prop);
          }

        }; // Per contract of the Proxy API, the "get" proxy handler must return the
        // original value of the target if that value is declared read-only and
        // non-configurable. For this reason, we create an object with the
        // prototype set to `target` instead of using `target` directly.
        // Otherwise we cannot return a custom object for APIs that
        // are declared read-only and non-configurable, such as `chrome.devtools`.
        //
        // The proxy handlers themselves will still use the original `target`
        // instead of the `proxyTarget`, so that the methods and properties are
        // dereferenced via the original targets.

        let proxyTarget = Object.create(target);
        return new Proxy(proxyTarget, handlers);
      };
      /**
       * Creates a set of wrapper functions for an event object, which handles
       * wrapping of listener functions that those messages are passed.
       *
       * A single wrapper is created for each listener function, and stored in a
       * map. Subsequent calls to `addListener`, `hasListener`, or `removeListener`
       * retrieve the original wrapper, so that  attempts to remove a
       * previously-added listener work as expected.
       *
       * @param {DefaultWeakMap<function, function>} wrapperMap
       *        A DefaultWeakMap object which will create the appropriate wrapper
       *        for a given listener function when one does not exist, and retrieve
       *        an existing one when it does.
       *
       * @returns {object}
       */


      const wrapEvent = wrapperMap => ({
        addListener(target, listener, ...args) {
          target.addListener(wrapperMap.get(listener), ...args);
        },

        hasListener(target, listener) {
          return target.hasListener(wrapperMap.get(listener));
        },

        removeListener(target, listener) {
          target.removeListener(wrapperMap.get(listener));
        }

      });

      const onRequestFinishedWrappers = new DefaultWeakMap(listener => {
        if (typeof listener !== "function") {
          return listener;
        }
        /**
         * Wraps an onRequestFinished listener function so that it will return a
         * `getContent()` property which returns a `Promise` rather than using a
         * callback API.
         *
         * @param {object} req
         *        The HAR entry object representing the network request.
         */


        return function onRequestFinished(req) {
          const wrappedReq = wrapObject(req, {}
          /* wrappers */
          , {
            getContent: {
              minArgs: 0,
              maxArgs: 0
            }
          });
          listener(wrappedReq);
        };
      }); // Keep track if the deprecation warning has been logged at least once.

      let loggedSendResponseDeprecationWarning = false;
      const onMessageWrappers = new DefaultWeakMap(listener => {
        if (typeof listener !== "function") {
          return listener;
        }
        /**
         * Wraps a message listener function so that it may send responses based on
         * its return value, rather than by returning a sentinel value and calling a
         * callback. If the listener function returns a Promise, the response is
         * sent when the promise either resolves or rejects.
         *
         * @param {*} message
         *        The message sent by the other end of the channel.
         * @param {object} sender
         *        Details about the sender of the message.
         * @param {function(*)} sendResponse
         *        A callback which, when called with an arbitrary argument, sends
         *        that value as a response.
         * @returns {boolean}
         *        True if the wrapped listener returned a Promise, which will later
         *        yield a response. False otherwise.
         */


        return function onMessage(message, sender, sendResponse) {
          let didCallSendResponse = false;
          let wrappedSendResponse;
          let sendResponsePromise = new Promise(resolve => {
            wrappedSendResponse = function (response) {
              if (!loggedSendResponseDeprecationWarning) {
                console.warn(SEND_RESPONSE_DEPRECATION_WARNING, new Error().stack);
                loggedSendResponseDeprecationWarning = true;
              }

              didCallSendResponse = true;
              resolve(response);
            };
          });
          let result;

          try {
            result = listener(message, sender, wrappedSendResponse);
          } catch (err) {
            result = Promise.reject(err);
          }

          const isResultThenable = result !== true && isThenable(result); // If the listener didn't returned true or a Promise, or called
          // wrappedSendResponse synchronously, we can exit earlier
          // because there will be no response sent from this listener.

          if (result !== true && !isResultThenable && !didCallSendResponse) {
            return false;
          } // A small helper to send the message if the promise resolves
          // and an error if the promise rejects (a wrapped sendMessage has
          // to translate the message into a resolved promise or a rejected
          // promise).


          const sendPromisedResult = promise => {
            promise.then(msg => {
              // send the message value.
              sendResponse(msg);
            }, error => {
              // Send a JSON representation of the error if the rejected value
              // is an instance of error, or the object itself otherwise.
              let message;

              if (error && (error instanceof Error || typeof error.message === "string")) {
                message = error.message;
              } else {
                message = "An unexpected error occurred";
              }

              sendResponse({
                __mozWebExtensionPolyfillReject__: true,
                message
              });
            }).catch(err => {
              // Print an error on the console if unable to send the response.
              console.error("Failed to send onMessage rejected reply", err);
            });
          }; // If the listener returned a Promise, send the resolved value as a
          // result, otherwise wait the promise related to the wrappedSendResponse
          // callback to resolve and send it as a response.


          if (isResultThenable) {
            sendPromisedResult(result);
          } else {
            sendPromisedResult(sendResponsePromise);
          } // Let Chrome know that the listener is replying.


          return true;
        };
      });

      const wrappedSendMessageCallback = ({
        reject,
        resolve
      }, reply) => {
        if (extensionAPIs.runtime.lastError) {
          // Detect when none of the listeners replied to the sendMessage call and resolve
          // the promise to undefined as in Firefox.
          // See https://github.com/mozilla/webextension-polyfill/issues/130
          if (extensionAPIs.runtime.lastError.message === CHROME_SEND_MESSAGE_CALLBACK_NO_RESPONSE_MESSAGE) {
            resolve();
          } else {
            reject(new Error(extensionAPIs.runtime.lastError.message));
          }
        } else if (reply && reply.__mozWebExtensionPolyfillReject__) {
          // Convert back the JSON representation of the error into
          // an Error instance.
          reject(new Error(reply.message));
        } else {
          resolve(reply);
        }
      };

      const wrappedSendMessage = (name, metadata, apiNamespaceObj, ...args) => {
        if (args.length < metadata.minArgs) {
          throw new Error(`Expected at least ${metadata.minArgs} ${pluralizeArguments(metadata.minArgs)} for ${name}(), got ${args.length}`);
        }

        if (args.length > metadata.maxArgs) {
          throw new Error(`Expected at most ${metadata.maxArgs} ${pluralizeArguments(metadata.maxArgs)} for ${name}(), got ${args.length}`);
        }

        return new Promise((resolve, reject) => {
          const wrappedCb = wrappedSendMessageCallback.bind(null, {
            resolve,
            reject
          });
          args.push(wrappedCb);
          apiNamespaceObj.sendMessage(...args);
        });
      };

      const staticWrappers = {
        devtools: {
          network: {
            onRequestFinished: wrapEvent(onRequestFinishedWrappers)
          }
        },
        runtime: {
          onMessage: wrapEvent(onMessageWrappers),
          onMessageExternal: wrapEvent(onMessageWrappers),
          sendMessage: wrappedSendMessage.bind(null, "sendMessage", {
            minArgs: 1,
            maxArgs: 3
          })
        },
        tabs: {
          sendMessage: wrappedSendMessage.bind(null, "sendMessage", {
            minArgs: 2,
            maxArgs: 3
          })
        }
      };
      const settingMetadata = {
        clear: {
          minArgs: 1,
          maxArgs: 1
        },
        get: {
          minArgs: 1,
          maxArgs: 1
        },
        set: {
          minArgs: 1,
          maxArgs: 1
        }
      };
      apiMetadata.privacy = {
        network: {
          "*": settingMetadata
        },
        services: {
          "*": settingMetadata
        },
        websites: {
          "*": settingMetadata
        }
      };
      return wrapObject(extensionAPIs, staticWrappers, apiMetadata);
    };

    if (typeof chrome != "object" || !chrome || !chrome.runtime || !chrome.runtime.id) {
      throw new Error("This script should only be loaded in a browser extension.");
    } // The build process adds a UMD wrapper around this file, which makes the
    // `module` variable available.


    module.exports = wrapAPIs(chrome);
  } else {
    module.exports = browser;
  }
});


/***/ }),

/***/ "./sdk/api/allowlisting.js":
/*!*********************************!*\
  !*** ./sdk/api/allowlisting.js ***!
  \*********************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_606416__) => {

"use strict";
__nested_webpack_require_606416__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_606416__.d(__webpack_exports__, {
/* harmony export */   "allowlistPage": () => (/* binding */ allowlistPage),
/* harmony export */   "default": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_606416__(/*! adblockpluscore/lib/contentTypes.js */ "./node_modules/adblockpluscore/lib/contentTypes.js");
/* harmony import */ var adblockpluscore_lib_url_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_606416__(/*! adblockpluscore/lib/url.js */ "./node_modules/adblockpluscore/lib/url.js");
/* harmony import */ var adblockpluscore_lib_time_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_606416__(/*! adblockpluscore/lib/time.js */ "./node_modules/adblockpluscore/lib/time.js");
/* harmony import */ var adblockpluscore_lib_rsa_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_606416__(/*! adblockpluscore/lib/rsa.js */ "./node_modules/adblockpluscore/lib/rsa.js");
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_606416__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var _frame_state_js__WEBPACK_IMPORTED_MODULE_5__ = __nested_webpack_require_606416__(/*! ./frame-state.js */ "./sdk/api/frame-state.js");
/* harmony import */ var _filters_js__WEBPACK_IMPORTED_MODULE_6__ = __nested_webpack_require_606416__(/*! ./filters.js */ "./sdk/api/filters.js");
/* harmony import */ var _types_js__WEBPACK_IMPORTED_MODULE_7__ = __nested_webpack_require_606416__(/*! ./types.js */ "./sdk/api/types.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */











// Note that this is a default implementation, but it might be
// replaced using `setAllowlistingCallback`. Don't rely on this
// behaviour.
let allowlistingCallback = function(domain) {
  return _filters_js__WEBPACK_IMPORTED_MODULE_6__.default.add([`@@||${domain}^$document`]);
};
let dispatchUnauthorized = () => {};

let authorizedPublicKeys = [];
let publicKeysUpdated = Promise.resolve();

let algorithm = {
  name: "RSASSA-PKCS1-v1_5",
  modulusLength: 4096,
  publicExponent: new Uint8Array([0x01, 0x00, 0x01]),
  hash: {name: "SHA-512"}
};

function getAllowData(domain, timestamp) {
  let str = `${domain},${timestamp}`;
  return (new TextEncoder()).encode(str);
}

async function verifySignature(data, signature, pubKey) {
  return crypto.subtle.verify(
    algorithm,
    pubKey,
    signature,
    data
  );
}

function verifyTimestamp(timestamp) {
  if (typeof timestamp != "number" || isNaN(timestamp))
    return false;

  let msSinceSigning = Date.now() - timestamp;
  return msSinceSigning >= 0 && msSinceSigning < adblockpluscore_lib_time_js__WEBPACK_IMPORTED_MODULE_2__.MILLIS_IN_HOUR;
}

async function verifyAnySignatures(domain, timestamp, signature) {
  if (typeof signature != "string")
    return false;

  await publicKeysUpdated;

  let data = getAllowData(domain, timestamp);
  let abSignature = (0,adblockpluscore_lib_rsa_js__WEBPACK_IMPORTED_MODULE_3__.base64ToArrayBuffer)(signature);
  for (let key of authorizedPublicKeys) {
    if (await verifySignature(data, abSignature, key))
      return true;
  }
  return false;
}

async function succeedAllowlisting(domain) {
  await allowlistingCallback(domain);
  return true;
}

function failAllowlisting(error) {
  dispatchUnauthorized(error);
  return false;
}

async function allowlistPage(tabId, frameId, timestamp, signature) {
  let frame = (0,_frame_state_js__WEBPACK_IMPORTED_MODULE_5__.getFrameInfo)(tabId, frameId);
  if (!frame) {
    return failAllowlisting({
      reason: "invalid_frame",
      request: {domain: null, timestamp, signature}
    });
  }

  let domain = frame.hostname;
  let request = {domain, timestamp, signature};

  if (frameId != 0) {
    return failAllowlisting({
      reason: "invalid_frame",
      request
    });
  }

  let urlInfo = (0,adblockpluscore_lib_url_js__WEBPACK_IMPORTED_MODULE_1__.parseURL)(frame.url);
  let alreadyAllowlistedDomain = _core_js__WEBPACK_IMPORTED_MODULE_4__.filterEngine.defaultMatcher.isAllowlisted(
    `${urlInfo.protocol}//${domain}`,
    adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_0__.contentTypes.DOCUMENT,
    domain,
    frame.sitekey
  );
  if (alreadyAllowlistedDomain) {
    return failAllowlisting({
      reason: "already_allowlisted",
      request
    });
  }

  let validTimestamp = verifyTimestamp(timestamp);
  if (!validTimestamp) {
    return failAllowlisting({
      reason: "invalid_timestamp",
      request
    });
  }

  let validSignature = await verifyAnySignatures(domain, timestamp, signature);
  if (!validSignature) {
    return failAllowlisting({
      reason: "invalid_signature",
      request
    });
  }

  return await succeedAllowlisting(domain);
}

async function setAuthorizedKeys(keys) {
  let newAuthorizedPublicKeys = [];
  for (let key of keys) {
    let abKey = (0,adblockpluscore_lib_rsa_js__WEBPACK_IMPORTED_MODULE_3__.base64ToArrayBuffer)(key);
    let importedKey = await crypto.subtle.importKey(
      "spki",
      abKey,
      algorithm,
      false,
      ["verify"]
    );
    newAuthorizedPublicKeys.push(importedKey);
  }
  authorizedPublicKeys = newAuthorizedPublicKeys;
}

/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({
  /**
   * Updates the list of public keys used to verify allowlisting
   * requests. If there are any invalid keys, the list of authorized
   * keys keeps its previous value.
   *
   * Any allowlisting requests that come in while this function is in
   * progress will wait for it to finish before verifying any
   * signatures.
   *
   * @param {[string]} keys The new set of public keys. The keys
   *   should be base64 encoded strings, in SPKI format. The keys must
   *   additionally use the RSASSA-PKCS1-v1_5 algorithm, SHA512 hash
   *   and 4096 bit long modulus.
   * @return {Promise} Promise that resolves when the keys have been
   *   updated, or rejects if any of the keys are invalid.
   */
  async setAuthorizedKeys(keys) {
    let resultPromise = setAuthorizedKeys(keys);
    publicKeysUpdated = resultPromise.catch(() => {});
    return await resultPromise;
  },

  /**
   * @callback allowlistingCallback
   * @param {string} domain The domain to allowlist.
   */

  /**
   * Set the function called when allowlisting succeeds.
   *
   * If the callback is not set, it has a default implementation that
   * adds an allowlisting filter for the allowlisted domain.
   *
   * @param {allowlistingCallback} callback The user defined function
   *   that will be called. This function should return a promise that
   *   resolves after adding the appropriate allowlisting filters.
   */
  setAllowlistingCallback(callback) {
    allowlistingCallback = callback;
  },

  /**
   * @typedef {Object} AllowlistingAuthorizationError
   * @property {string} reason The reason a request to allowlist was
   *   rejected. Can be "invalid_frame", "already_allowlisted",
   *   "invalid_timestamp", or "invalid_signature".
   * @property {Object} request The rejected request.
   * @property {string} [request.domain] The domain of the page that
   *   the request came from. This is also the domain that the request
   *   would have allowlisted if it was valid. If this is null, it
   *   means that the frame's domain could not be determined.
   * @property {*} request.timestamp The timestamp in the
   *   request. For a valid request this is a number, but the request
   *   may have been invalid so it might not be a number.
   * @property {*} request.signature The signature in the
   *   request. For a valid request, this is string, but the request
   *   may have been invalid so it might not be a string.
   */

  /**
   * Emitted when an allowlisting request is rejected.
   * @event
   * @type {EventDispatcher<AllowlistingAuthorizationError>}
   */
  onUnauthorized: new _types_js__WEBPACK_IMPORTED_MODULE_7__.EventDispatcher(
    dispatch => {
      dispatchUnauthorized = dispatch;
    },
    () => {
      dispatchUnauthorized = () => {};
    }
  )
});


/***/ }),

/***/ "./sdk/api/browser-features.js":
/*!*************************************!*\
  !*** ./sdk/api/browser-features.js ***!
  \*************************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_615401__) => {

"use strict";
__nested_webpack_require_615401__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_615401__.d(__webpack_exports__, {
/* harmony export */   "isRunningInServiceWorker": () => (/* binding */ isRunningInServiceWorker)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_615401__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */



let manifest = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.runtime.getManifest();

function isRunningInServiceWorker() {
  return !!(manifest.background && manifest.background.service_worker);
}


/***/ }),

/***/ "./sdk/api/content-filter.js":
/*!***********************************!*\
  !*** ./sdk/api/content-filter.js ***!
  \***********************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_616987__) => {

"use strict";
__nested_webpack_require_616987__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_616987__.d(__webpack_exports__, {
/* harmony export */   "setSnippetLibrary": () => (/* binding */ setSnippetLibrary),
/* harmony export */   "applyContentFilters": () => (/* binding */ applyContentFilters),
/* harmony export */   "injectCSS": () => (/* binding */ injectCSS)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_616987__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var adblockpluscore_lib_elemHide_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_616987__(/*! adblockpluscore/lib/elemHide.js */ "./node_modules/adblockpluscore/lib/elemHide.js");
/* harmony import */ var adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_616987__(/*! adblockpluscore/lib/contentTypes.js */ "./node_modules/adblockpluscore/lib/contentTypes.js");
/* harmony import */ var adblockpluscore_lib_snippets_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_616987__(/*! adblockpluscore/lib/snippets.js */ "./node_modules/adblockpluscore/lib/snippets.js");
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_616987__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var _frame_state_js__WEBPACK_IMPORTED_MODULE_5__ = __nested_webpack_require_616987__(/*! ./frame-state.js */ "./sdk/api/frame-state.js");
/* harmony import */ var _diagnostics_js__WEBPACK_IMPORTED_MODULE_6__ = __nested_webpack_require_616987__(/*! ./diagnostics.js */ "./sdk/api/diagnostics.js");
/* harmony import */ var _debugging_js__WEBPACK_IMPORTED_MODULE_7__ = __nested_webpack_require_616987__(/*! ./debugging.js */ "./sdk/api/debugging.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */












let isolatedLib;
let injectedLib;

function setSnippetLibrary({isolatedCode, injectedCode}) {
  isolatedLib = isolatedCode;
  injectedLib = injectedCode;
}

async function applyContentFilters(tabId, frameId) {
  let frame = (0,_frame_state_js__WEBPACK_IMPORTED_MODULE_5__.getFrameInfo)(tabId, frameId);
  let details = {tabId, frameIds: [frameId]};
  let emulatedPatterns = [];
  let tracedSelectors;

  if (!(frame.allowlisted & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.DOCUMENT)) {
    let filters = _core_js__WEBPACK_IMPORTED_MODULE_4__.filterEngine.snippets.getFilters(frame.hostname);

    if (filters.length > 0) {
      let scripts = filters.map(({script}) => script);
      let environment = {};
      if (_debugging_js__WEBPACK_IMPORTED_MODULE_7__.debugOptions.elemHide)
        environment.debugCSSProperties = _debugging_js__WEBPACK_IMPORTED_MODULE_7__.debugOptions.snippetsCssProperties;

      let isolatedDependencies = [];
      let isolated = [];
      let main = [];

      for (let script of scripts) {
        for (let [snippet, ...args] of (0,adblockpluscore_lib_snippets_js__WEBPACK_IMPORTED_MODULE_3__.parseScript)(script)) {
          if (isolatedLib.has(snippet)) {
            let dependency = isolatedLib.get(snippet);
            if (dependency)
              isolatedDependencies.push(dependency);
            isolated.push([snippet, ...args]);
          }
          if (injectedLib.has(snippet))
            main.push([snippet, ...args]);
        }
      }

      let execute = [];
      if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.scripting && webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.scripting.executeScript) {
        if (isolated.length > 0) {
          if (isolatedDependencies.length) {
            let isolatedDepsPromises = [];
            for (let dependency of isolatedDependencies) {
              isolatedDepsPromises.push(webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.scripting.executeScript({
                target: details,
                world: "ISOLATED",
                func: dependency
              }));
            }
            await Promise.all(isolatedDepsPromises);
          }

          execute.push(
            webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.scripting.executeScript({
              target: details,
              world: "ISOLATED",
              func: isolatedLib,
              args: [environment, ...isolated]
            })
          );
        }

        if (main.length > 0) {
          execute.push(
            webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.scripting.executeScript({
              target: details,
              world: "MAIN",
              func: injectedLib,
              args: [environment, ...main]
            })
          );
        }
      }
      else {
        if (isolated.length > 0) {
          const args = JSON.stringify([environment, ...isolated]);
          let code = "";
          // prepend all dependencies before the snippets
          if (isolatedDependencies.length) {
            for (const cb of isolatedDependencies)
              code += `(${cb})();`;
          }
          code += `(${isolatedLib}).apply(null,${args})`;
          execute.push(
            webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.tabs.executeScript(
              tabId,
              {
                frameId,
                code,
                matchAboutBlank: true,
                runAt: "document_start"
              }));
        }

        if (main.length > 0) {
          const args = JSON.stringify([environment, ...main]);
          // stringify injectedLib to escape backticks
          let code = JSON.stringify(injectedLib.toString());
          code = `"(${code.slice(1, -1)}).apply(null,${JSON.stringify(args).slice(1, -1)});"`;
          let executable =
          `function injectSnippetsInMainContext(executable)
          {
            // injecting phases
            let script = document.createElement("script");
            script.type = "application/javascript";
            script.async = false;

            // Firefox 58 only bypasses site CSPs when assigning to 'src',
            // while Chrome 67 and Microsoft Edge (tested on 44.17763.1.0)
            // only bypass site CSPs when using 'textContent'.
            if (typeof netscape != "undefined" && typeof browser != "undefined")
            {
              let url = URL.createObjectURL(new Blob([executable]));
              script.src = url;
              document.documentElement.appendChild(script);
              URL.revokeObjectURL(url);
            }
            else
            {
              script.textContent = executable;
              document.documentElement.appendChild(script);
            }

            document.documentElement.removeChild(script);
          };
          const executable = ${code};
          injectSnippetsInMainContext(executable);`;
          execute.push(
            webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.tabs.executeScript(
              tabId,
              {
                frameId,
                code: executable,
                matchAboutBlank: true,
                runAt: "document_start"
              }));
        }
      }

      let request = {tabId, frameId, url: frame.url};
      Promise.all(execute).then(() => filters.forEach(filter => {
        (0,_diagnostics_js__WEBPACK_IMPORTED_MODULE_6__.logItem)(request, filter, {
          docDomain: frame.hostname,
          method: "snippet"
        });
      }), () => {});
    }

    if (!(frame.allowlisted & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.ELEMHIDE)) {
      let specificOnly = (frame.allowlisted & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.GENERICHIDE) != 0;
      let trace = (0,_diagnostics_js__WEBPACK_IMPORTED_MODULE_6__.tracingEnabled)(tabId);
      let styleSheet = _core_js__WEBPACK_IMPORTED_MODULE_4__.filterEngine.elemHide.getStyleSheet(
        frame.hostname,
        specificOnly, trace || _debugging_js__WEBPACK_IMPORTED_MODULE_7__.debugOptions.elemHide,
        trace
      );

      if (_debugging_js__WEBPACK_IMPORTED_MODULE_7__.debugOptions.elemHide) {
        let declarationBlock = "{";
        for (let [property, value] of _debugging_js__WEBPACK_IMPORTED_MODULE_7__.debugOptions.cssProperties)
          declarationBlock += `${property}: ${value} !important;`;
        declarationBlock += "}";

        styleSheet.code = (0,adblockpluscore_lib_elemHide_js__WEBPACK_IMPORTED_MODULE_1__.createStyleSheet)(styleSheet.selectors,
                                           declarationBlock);
      }

      injectCSS(tabId, frameId, styleSheet.code);

      for (let {selector, text} of _core_js__WEBPACK_IMPORTED_MODULE_4__.filterEngine.elemHideEmulation.getFilters(
        frame.hostname))
        emulatedPatterns.push({selector, text});

      if (trace) {
        tracedSelectors = [];
        for (let selector of styleSheet.selectors)
          tracedSelectors.push([selector, null]);
        for (let exception of styleSheet.exceptions)
          tracedSelectors.push([exception.selector, exception.text]);
      }
    }
  }

  let cssProperties;
  if (_debugging_js__WEBPACK_IMPORTED_MODULE_7__.debugOptions.elemHide)
    cssProperties = _debugging_js__WEBPACK_IMPORTED_MODULE_7__.debugOptions.cssProperties;
  return {emulatedPatterns, cssProperties, tracedSelectors};
}

function injectCSS(tabId, frameId, code) {
  let result;

  if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.scripting && webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.scripting.insertCSS) {
    result = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.scripting.insertCSS({
      target: {tabId, frameIds: [frameId]},
      css: code,
      origin: "USER"
    });
  }
  else {
    result = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.tabs.insertCSS(
      tabId,
      {
        code,
        cssOrigin: "user",
        frameId,
        matchAboutBlank: true,
        runAt: "document_start"
      }
    );
  }

  result.catch(() => {}); // Fails if tab or frame no longer exists
}


/***/ }),

/***/ "./sdk/api/core.js":
/*!*************************!*\
  !*** ./sdk/api/core.js ***!
  \*************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_627820__) => {

"use strict";
__nested_webpack_require_627820__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_627820__.d(__webpack_exports__, {
/* harmony export */   "filterEngine": () => (/* binding */ filterEngine)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_627820__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var adblockpluscore__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_627820__(/*! adblockpluscore */ "./node_modules/adblockpluscore/lib/index.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */





let filterEngine = new adblockpluscore__WEBPACK_IMPORTED_MODULE_1__.FilterEngine((function() {
  let features;

  if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest)
    features = adblockpluscore__WEBPACK_IMPORTED_MODULE_1__.Features.DNR;

  return {features};
})());


/***/ }),

/***/ "./sdk/api/debugging.js":
/*!******************************!*\
  !*** ./sdk/api/debugging.js ***!
  \******************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_629620__) => {

"use strict";
__nested_webpack_require_629620__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_629620__.d(__webpack_exports__, {
/* harmony export */   "debugOptions": () => (/* binding */ debugOptions),
/* harmony export */   "default": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var adblockpluscore_lib_filterStorage_js__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_629620__(/*! adblockpluscore/lib/filterStorage.js */ "./node_modules/adblockpluscore/lib/filterStorage.js");
/* harmony import */ var _io_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_629620__(/*! ./io.js */ "./sdk/api/io.js");
/* harmony import */ var _info_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_629620__(/*! ./info.js */ "./sdk/api/info.js");
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_629620__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var _prefs_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_629620__(/*! ./prefs.js */ "./sdk/api/prefs.js");
/* harmony import */ var _subscriptions_js__WEBPACK_IMPORTED_MODULE_5__ = __nested_webpack_require_629620__(/*! ./subscriptions.js */ "./sdk/api/subscriptions.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */









let debugOptions = {
  elemHide: false,
  cssProperties: [["background", "#e67370"], ["outline", "solid red"]],
  snippetsCssProperties: [
    ["background", "repeating-linear-gradient(to bottom, #e67370 0," +
     "#e67370 9px, white 9px, white 10px)"],
    ["outline", "solid red"]]
};

/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({
  /**
   * AddonInfo assigned during start.
   * @type {Object}
   * @property {string} name
   * @property {string} version
   */
  get addonInfo() {
    return {
      name: _info_js__WEBPACK_IMPORTED_MODULE_2__.addonName,
      version: _info_js__WEBPACK_IMPORTED_MODULE_2__.addonVersion,
      bundledSubscriptions: _info_js__WEBPACK_IMPORTED_MODULE_2__.addonBundledSubscriptions,
      bundledSubscriptionsPath: _info_js__WEBPACK_IMPORTED_MODULE_2__.addonBundledSubscriptionsPath,
      manifestVersion: _info_js__WEBPACK_IMPORTED_MODULE_2__.manifestVersion
    };
  },

  /**
   * Causes elements targeted by element hiding, element hiding emulation,
   * or snippets to be highlighted instead of hidden.
   * @param {boolean} enabled Enables or disables debug mode.
   */
  setElementHidingDebugMode(enabled) {
    debugOptions.elemHide = enabled;
  },

  /*
   * Updates the element hiding debug style.
   * @param {Object} cssProperties The css properties for
   *                               the debug element.
   * @param {Object} snippetsCssProperties The css properties for
   *                                       the debug snippet element.
   */
  setElementHidingDebugStyle(cssProperties, snippetsCssProperties) {
    if (cssProperties)
      debugOptions.cssProperties = cssProperties;

    if (snippetsCssProperties)
      debugOptions.snippetsCssProperties = snippetsCssProperties;
  },

  /**
   * @ignore
   * @param {string} text
   */
  async isInFilterStorage(text) {
    let contents = [];
    await _io_js__WEBPACK_IMPORTED_MODULE_1__.IO.readFromFile(adblockpluscore_lib_filterStorage_js__WEBPACK_IMPORTED_MODULE_0__.FilterStorage.sourceFile,
                          line => contents.push(line));
    return contents.some(line => line.includes(text));
  },

  /**
   * @ignore
   * Used internally. Returns a list of warnings in the context of validating
   * that a user has provided the appropriate files to the extension.
   * @param {Array<Recommendation>} [addonInfo.bundledSubscriptions]
   *   A list of subscriptions provided by the integrator.
   * @param {string} [addonInfo.bundledSubscriptionsPath]
   *   A path to subscription files provided by the integrator.
   * @return {Array<String>}
   */
  validateSubscriptions: _subscriptions_js__WEBPACK_IMPORTED_MODULE_5__.validate,

  /**
   * @ignore
   * Used internally. Waits for any pending save actions to complete.
   * @return {Promise}
   */
  async ensureEverythingHasSaved() {
    let {filterStorage} = _core_js__WEBPACK_IMPORTED_MODULE_3__.filterEngine;
    if (filterStorage) {
      // It would be better if filterStorage gave a promise to await for this.
      // https://gitlab.com/eyeo/adblockplus/abc/adblockpluscore/-/issues/464
      while (filterStorage._saving)
        await new Promise(r => setTimeout(r, 10));
    }

    await (0,_prefs_js__WEBPACK_IMPORTED_MODULE_4__.awaitSavingComplete)();
  }
});


/***/ }),

/***/ "./sdk/api/diagnostics.js":
/*!********************************!*\
  !*** ./sdk/api/diagnostics.js ***!
  \********************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_634982__) => {

"use strict";
__nested_webpack_require_634982__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_634982__.d(__webpack_exports__, {
/* harmony export */   "BlockableEventDispatcher": () => (/* binding */ BlockableEventDispatcher),
/* harmony export */   "logItem": () => (/* binding */ logItem),
/* harmony export */   "logHiddenElements": () => (/* binding */ logHiddenElements),
/* harmony export */   "tracingEnabled": () => (/* binding */ tracingEnabled)
/* harmony export */ });
/* harmony import */ var adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_634982__(/*! adblockpluscore/lib/filterClasses.js */ "./node_modules/adblockpluscore/lib/filterClasses.js");
/* harmony import */ var adblockpluscore_lib_url_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_634982__(/*! adblockpluscore/lib/url.js */ "./node_modules/adblockpluscore/lib/url.js");
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_634982__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var _filters_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_634982__(/*! ./filters.js */ "./sdk/api/filters.js");
/* harmony import */ var _frame_state_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_634982__(/*! ./frame-state.js */ "./sdk/api/frame-state.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */







let listeners = [];
let defaultOptions = {includeElementHiding: false,
                      includeUnmatched: false,
                      filterType: "blocking",
                      tabId: null};

/**
 * The BlockableEventDispatcher class allows users to listen to
 * filters and requests.
 * @hideconstructor
 */
class BlockableEventDispatcher {
  /**
  * @typedef {Object} BlockableEventOptions
  * @param {boolean} [includeElementHiding=false]
  *   Whether or not element hiding filters accounting for dynamic DOM changes
  *   should also be emitted. This event is emitted after the page has been
  *   fully loaded, and the element hiding filters have been applied. The
  *   expected delay between the filter being applied and the event being
  *   emitted is around two seconds.
  *   Note that this will enable element hiding tracing, which degrades
  *   performance and should only be used to enable ad-hoc diagnostics.
  * @param {boolean} [includeUnmatched=false] Whether or not unmatched requests
  *   should also be emitted. This event is generally emitted after a request is
  *   fully completed. Note that blockable item events may refer to either
  *   requests or documents. Unmatched events only refer to requests. This has
  *   the potentially confusing implication that there may be allowing document
  *   events (eg a $genericblock allowing filter being activated for a document)
  *   as well as an unmatched event for the request that actually loaded the
  *   HTML of the document.
  * @param {string} [filterType="blocking"]
  *   The type of filters to emit. Can be "blocking", "allowing", or "all".
  * @param {Number} [tabId=null]
  *   The tab to filter events for. Element hiding tracing will be limited to
  *   this tab (if `includeElementHiding` is set). If set to `null` events for
  *   all tabs will be considered, and are subject to element hiding tracing
  *   (if `includeElementHiding` is set) which will degrade performance.
  */

  /**
   * Attaches a listener function to an event. This listener will be called
   * when the Blockable event is emitted.
   * @param {function} listener The user defined function that will be called
   *                            once the specified event is emitted.
   * @param {BlockableEventOptions} options The filtering conditions to apply
   *                                        when the event is emitted.
   * @example
   * // Logs all blocked requests
   * EWE.reporting.onBlockableItem.addListener(console.log);
   * @example
   * // Log all blockable items of a specific tab for debugging purposes
   * EWE.reporting.onBlockableItem.addListener(
   *   console.log,
   *   {includeElementHiding: true,
   *    includeUnmatched: true,
   *    filterType: "all", tabId}
   * );
   */
  addListener(listener, options) {
    listeners.push({listener, options: {...defaultOptions, ...options}});
  }

  /**
   * Removes the added function. This means the listener will no
   * longer be called by the emitted event.
   * @param {function} listener The user defined function to be removed.
   * @param {Object} options The filtering conditions to apply when
   *                         the event is emitted.
   */
  removeListener(listener, options) {
    let {includeElementHiding, includeUnmatched,
         filterType, tabId} = {...defaultOptions, ...options};

    let index = listeners.findIndex(obj =>
      obj.listener == listener &&
      obj.options.includeElementHiding == includeElementHiding &&
      obj.options.includeUnmatched == includeUnmatched &&
      obj.options.filterType == filterType &&
      obj.options.tabId == tabId
    );

    if (index != -1)
      listeners.splice(index, 1);
  }
}

function logItem(request, filter, matchInfo = {}) {
  for (let {listener, options} of listeners) {
    let {includeElementHiding, includeUnmatched, filterType, tabId} = options;

    if (tabId != null && tabId != request.tabId)
      continue;

    if (filter) {
      if (!includeElementHiding && (filter.type == "elemhide" ||
                                    filter.type == "elemhideexception" ||
                                    filter.type == "elemhideemulation"))
        continue;

      if (filterType != "all" &&
          filterType == "allowing" != (filter.type == "allowing" ||
                                       filter.type == "elemhideexception"))
        continue;
    }

    if (!includeUnmatched && !filter)
      continue;

    listener({request, filter: filter && (0,_filters_js__WEBPACK_IMPORTED_MODULE_3__.convertFilter)(filter), matchInfo});
  }
}

function logHiddenElements(selectors, filters, sender) {
  let request = {
    tabId: sender.tab.id,
    frameId: sender.frameId,
    url: sender.url || _frame_state_js__WEBPACK_IMPORTED_MODULE_4__.BLANK_PAGE_URL
  };
  let {hostname} = (0,adblockpluscore_lib_url_js__WEBPACK_IMPORTED_MODULE_1__.parseURL)(request.url);
  let matchInfo = {
    docDomain: hostname,
    method: "elemhide"
  };

  if (selectors.length > 0) {
    for (let subscription of _core_js__WEBPACK_IMPORTED_MODULE_2__.filterEngine.filterStorage.subscriptions()) {
      if (subscription.disabled)
        continue;

      for (let text of subscription.filterText()) {
        let filter = adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_0__.Filter.fromText(text);

        if (filter instanceof adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_0__.ElemHideFilter &&
            selectors.includes(filter.selector) &&
            filter.isActiveOnDomain(hostname))
          logItem(request, filter, matchInfo);
      }
    }
  }

  for (let text of filters)
    logItem(request, adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_0__.Filter.fromText(text), matchInfo);
}

function tracingEnabled(tabId) {
  return listeners.some(({options}) =>
    options.includeElementHiding &&
    (options.tabId == null || options.tabId == tabId)
  );
}


/***/ }),

/***/ "./sdk/api/dnr-filters.js":
/*!********************************!*\
  !*** ./sdk/api/dnr-filters.js ***!
  \********************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_643134__) => {

"use strict";
__nested_webpack_require_643134__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_643134__.d(__webpack_exports__, {
/* harmony export */   "validateFilter": () => (/* binding */ validateFilter),
/* harmony export */   "removeDynamicFilters": () => (/* binding */ removeDynamicFilters),
/* harmony export */   "init": () => (/* binding */ init),
/* harmony export */   "addFilters": () => (/* binding */ addFilters),
/* harmony export */   "setMetadataForFilter": () => (/* binding */ setMetadataForFilter),
/* harmony export */   "getMetadataForFilter": () => (/* binding */ getMetadataForFilter),
/* harmony export */   "removeOrDisableFilters": () => (/* binding */ removeOrDisableFilters),
/* harmony export */   "enableFilters": () => (/* binding */ enableFilters),
/* harmony export */   "getDynamicFilters": () => (/* binding */ getDynamicFilters),
/* harmony export */   "migrateCustomFilters": () => (/* binding */ migrateCustomFilters)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_643134__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_643134__(/*! adblockpluscore/lib/filterClasses.js */ "./node_modules/adblockpluscore/lib/filterClasses.js");
/* harmony import */ var adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_643134__(/*! adblockpluscore/lib/filterNotifier.js */ "./node_modules/adblockpluscore/lib/filterNotifier.js");
/* harmony import */ var adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_643134__(/*! adblockpluscore/lib/subscriptionClasses.js */ "./node_modules/adblockpluscore/lib/subscriptionClasses.js");
/* harmony import */ var adblockpluscore_lib_url_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_643134__(/*! adblockpluscore/lib/url.js */ "./node_modules/adblockpluscore/lib/url.js");
/* harmony import */ var adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_5__ = __nested_webpack_require_643134__(/*! adblockpluscore/lib/contentTypes.js */ "./node_modules/adblockpluscore/lib/contentTypes.js");
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_6__ = __nested_webpack_require_643134__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var adblockpluscore_lib_dnr_index_js__WEBPACK_IMPORTED_MODULE_7__ = __nested_webpack_require_643134__(/*! adblockpluscore/lib/dnr/index.js */ "./node_modules/adblockpluscore/lib/dnr/index.js");
/* harmony import */ var _errors_js__WEBPACK_IMPORTED_MODULE_8__ = __nested_webpack_require_643134__(/*! ../errors.js */ "./sdk/errors.js");
/* harmony import */ var _types_js__WEBPACK_IMPORTED_MODULE_9__ = __nested_webpack_require_643134__(/*! ./types.js */ "./sdk/api/types.js");
/* harmony import */ var _prefs_js__WEBPACK_IMPORTED_MODULE_10__ = __nested_webpack_require_643134__(/*! ./prefs.js */ "./sdk/api/prefs.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */















let highestRuleId = 1;
let dynamicFilters = new Map();
let initializationPromise;

let getRulesFromFilter = () => {};
if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest) {
  getRulesFromFilter = (0,adblockpluscore_lib_dnr_index_js__WEBPACK_IMPORTED_MODULE_7__.createConverter)({
    isRegexSupported: webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest.isRegexSupported
  });
}

function validateFilter(filter) {
  if (filter instanceof adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.InvalidFilter)
    return new _types_js__WEBPACK_IMPORTED_MODULE_9__.FilterError("invalid_filter", filter.reason, filter.option);

  if ((0,adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.isActiveFilter)(filter) && filter.domains) {
    for (let domain of filter.domains.keys()) {
      if (domain && !(0,adblockpluscore_lib_url_js__WEBPACK_IMPORTED_MODULE_4__.isValidHostname)(domain))
        return new _types_js__WEBPACK_IMPORTED_MODULE_9__.FilterError("invalid_domain", domain);
    }
  }

  return null;
}

async function removeDynamicFilters() {
  if (!webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest)
    return;

  dynamicFilters = new Map();
  _prefs_js__WEBPACK_IMPORTED_MODULE_10__.Prefs.dynamic_filters = [];

  let rules = await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest.getDynamicRules();
  if (rules.length == 0)
    return;

  await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest.updateDynamicRules({
    removeRuleIds: rules.map(r => r.id)
  });

  return rules;
}

function setHighestRuleId(ruleIds) {
  if (!ruleIds)
    return;

  for (let id of ruleIds) {
    if (highestRuleId < id)
      highestRuleId = id;
  }
}

function storeDynamicFilters() {
  let storageArray = [];
  storageArray.push(...dynamicFilters);
  _prefs_js__WEBPACK_IMPORTED_MODULE_10__.Prefs.dynamic_filters = storageArray;
}

function init() {
  if (!initializationPromise) {
    initializationPromise = (async() => {
      if (!webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest)
        return;

      let result = _prefs_js__WEBPACK_IMPORTED_MODULE_10__.Prefs.dynamic_filters;
      if (Array.isArray(result) && result.length > 0)
        dynamicFilters = new Map(result);
      else
        // DNR rules persist after the extension is uninstalled. The same cannot
        // be said for storage. To be safe, if we have no record of dynamic
        // filters let's clear any DNR rules too.
        await removeDynamicFilters();

      for (let {ruleIds} of dynamicFilters.values())
        setHighestRuleId(ruleIds);
    })();
  }

  return initializationPromise;
}

async function getRules(filter, useFilterEngine) {
  let ruleIds = [];
  let filterRules = [];

  // "sitekey" option is not supported in DNR
  if (filter instanceof adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.URLFilter && !filter.sitekeys) {
    let result = await getRulesFromFilter(filter.text);
    if (result.name == "Error") {
      let {option} = result.detail;
      throw new _types_js__WEBPACK_IMPORTED_MODULE_9__.FilterError(result.message, result.detail.text, option);
    }

    for (let rule of result) {
      let id = ++highestRuleId;
      rule.id = id;
      ruleIds.push(id);
      filterRules.push(rule);
    }

    if (result.length == 0 && !useFilterEngine)
      throw new Error(`Filter unsupported by DNR: ${filter.text}`);
  }

  return {filterRules, ruleIds};
}

async function processFilterTexts(texts) {
  let details = [];
  let add = [];
  let exist = [];
  let seenFilterTexts = new Set();

  texts = texts.map(adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.normalize);
  for (let text of texts) {
    if (dynamicFilters.has(text)) {
      exist.push(text);
      continue;
    }

    if (seenFilterTexts.has(text))
      continue;

    let filter = adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.fromText(text);
    let error = validateFilter(filter);
    if (error)
      throw error;

    let useFilterEngine = filter instanceof adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.ContentFilter ||
                          filter instanceof adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.AllowingFilter ||
                          (filter.contentType & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_5__.contentTypes.WEBRTC ||
                           filter.contentType & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_5__.contentTypes.POPUP) &&
                          filter.contentType != adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_5__.RESOURCE_TYPES;

    if (!_core_js__WEBPACK_IMPORTED_MODULE_6__.filterEngine.filterStorage.filterState.isEnabled(text)) {
      details.push({filter, useFilterEngine, ruleIds: [], enabled: false});
    }
    else {
      let {filterRules, ruleIds} = await getRules(filter, useFilterEngine);
      add.push(...filterRules);
      details.push({filter, useFilterEngine, ruleIds, enabled: true});
    }

    seenFilterTexts.add(text);
  }

  return {add, exist, details};
}

async function dynamicRulesAvailable() {
  let {declarativeNetRequest} = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__;
  if (!declarativeNetRequest)
    return Infinity;

  const {MAX_NUMBER_OF_DYNAMIC_AND_SESSION_RULES} = declarativeNetRequest;
  let used = (await declarativeNetRequest.getDynamicRules()).length +
               (await declarativeNetRequest.getSessionRules()).length;
  return MAX_NUMBER_OF_DYNAMIC_AND_SESSION_RULES - used;
}

async function addFilters(texts, metadata) {
  await init();
  let filters = await processFilterTexts(texts);
  if (filters.exist.length > 0)
    throw new _types_js__WEBPACK_IMPORTED_MODULE_9__.FilterError(_errors_js__WEBPACK_IMPORTED_MODULE_8__.ERROR_DUPLICATE_FILTERS);

  let {length} = filters.add;
  if (length > 0) {
    // always false when !browser.declarativeNetRequest
    if (length >= await dynamicRulesAvailable())
      throw new _types_js__WEBPACK_IMPORTED_MODULE_9__.FilterError(_errors_js__WEBPACK_IMPORTED_MODULE_8__.ERROR_TOO_MANY_FILTERS);

    // so that this would throw the right error in case
    // browser.declarativeNetRequest doesn't exist or if
    // the API returned a different error instead
    await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest.updateDynamicRules({
      addRules: filters.add
    });
  }

  for (let filterDetails of filters.details) {
    let {filter, useFilterEngine, ruleIds, enabled} = filterDetails;

    if (useFilterEngine)
      await _core_js__WEBPACK_IMPORTED_MODULE_6__.filterEngine.filterStorage.addFilter(filter);
    else
      adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_2__.filterNotifier.emit("filter.added", filter, null);

    setHighestRuleId(ruleIds);
    dynamicFilters.set(filter.text,
                       {ruleIds, useFilterEngine, enabled, metadata});
  }

  storeDynamicFilters();
}

function setMetadataForFilter(text, metadata) {
  let details = dynamicFilters.get(text);
  if (!details)
    throw new _types_js__WEBPACK_IMPORTED_MODULE_9__.FilterError(_errors_js__WEBPACK_IMPORTED_MODULE_8__.ERROR_FILTER_NOT_FOUND);

  details.metadata = metadata;

  storeDynamicFilters();
}

function getMetadataForFilter(text) {
  let details = dynamicFilters.get(text);
  if (!details)
    return null;

  let metadata = details.metadata;
  return (typeof metadata != "undefined") ? metadata : null;
}

async function removeOrDisableFilters(texts, remove = true) {
  await init();

  let filtersToRemove = texts.map(adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.normalize);
  let ruleIdsToRemove = [];
  for (let text of filtersToRemove) {
    if (!dynamicFilters.has(text))
      continue;

    for (let ruleId of dynamicFilters.get(text).ruleIds)
      ruleIdsToRemove.push(ruleId);

    let details = dynamicFilters.get(text);

    if (remove) {
      if (details.useFilterEngine)
        _core_js__WEBPACK_IMPORTED_MODULE_6__.filterEngine.filterStorage.removeFilter(adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.fromText(text));
      else
        adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_2__.filterNotifier.emit("filter.removed", adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.fromText(text), null);

      dynamicFilters.delete(text);
    }
    else {
      if (details.useFilterEngine)
        _core_js__WEBPACK_IMPORTED_MODULE_6__.filterEngine.filterStorage.filterState.setEnabled(text, false);
      else
        adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_2__.filterNotifier.emit("filterState.enabled", text, false, true);

      details.enabled = false;
      details.ruleIds = [];
      dynamicFilters.set(text, details);
    }
  }

  if (ruleIdsToRemove.length > 0) {
    await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest.updateDynamicRules({
      removeRuleIds: ruleIdsToRemove
    });
  }

  storeDynamicFilters();
}

async function enableFilters(texts) {
  await init();

  let rules = [];

  for (let text of texts) {
    let normalized = adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.normalize(text);
    let details = dynamicFilters.get(normalized);

    if (!details || details.enabled)
      continue;

    let {useFilterEngine} = details;
    let filter = adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.fromText(normalized);

    if (useFilterEngine)
      _core_js__WEBPACK_IMPORTED_MODULE_6__.filterEngine.filterStorage.filterState.setEnabled(filter.text, true);
    else
      adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_2__.filterNotifier.emit("filterState.enabled", normalized, true, false);

    let {filterRules, ruleIds} = await getRules(filter, useFilterEngine);
    rules.push(...filterRules);

    setHighestRuleId(ruleIds);
    dynamicFilters.set(filter.text,
                       {ruleIds, useFilterEngine, enabled: true});
  }

  if (rules.length == 0)
    return;

  await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest.updateDynamicRules({
    addRules: rules
  });

  storeDynamicFilters();
}

async function getDynamicFilters() {
  await init();
  return dynamicFilters;
}

async function migrateCustomFilters() {
  let data = [];

  for (let subscription of _core_js__WEBPACK_IMPORTED_MODULE_6__.filterEngine.filterStorage.subscriptions()) {
    if (!(subscription instanceof adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_3__.SpecialSubscription))
      continue;

    for (let text of subscription.filterText())
      data.push({text, metadata: subscription.metadata});
  }

  for (let entry of data) {
    try {
      _core_js__WEBPACK_IMPORTED_MODULE_6__.filterEngine.filterStorage.removeFilter(adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.fromText(entry.text));
      await addFilters([entry.text], entry.metadata);
    }
    catch (e) {
      _prefs_js__WEBPACK_IMPORTED_MODULE_10__.Prefs.migration_errors.push({
        error: e.message,
        text: entry.text
      });
    }
  }
}


/***/ }),

/***/ "./sdk/api/filters.js":
/*!****************************!*\
  !*** ./sdk/api/filters.js ***!
  \****************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_658341__) => {

"use strict";
__nested_webpack_require_658341__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_658341__.d(__webpack_exports__, {
/* harmony export */   "convertFilter": () => (/* binding */ convertFilter),
/* harmony export */   "default": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_658341__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_658341__(/*! adblockpluscore/lib/filterClasses.js */ "./node_modules/adblockpluscore/lib/filterClasses.js");
/* harmony import */ var adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_658341__(/*! adblockpluscore/lib/subscriptionClasses.js */ "./node_modules/adblockpluscore/lib/subscriptionClasses.js");
/* harmony import */ var adblockpluscore_lib_matcher_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_658341__(/*! adblockpluscore/lib/matcher.js */ "./node_modules/adblockpluscore/lib/matcher.js");
/* harmony import */ var adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_658341__(/*! adblockpluscore/lib/filterNotifier.js */ "./node_modules/adblockpluscore/lib/filterNotifier.js");
/* harmony import */ var adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_5__ = __nested_webpack_require_658341__(/*! adblockpluscore/lib/contentTypes.js */ "./node_modules/adblockpluscore/lib/contentTypes.js");
/* harmony import */ var _initializer_js__WEBPACK_IMPORTED_MODULE_6__ = __nested_webpack_require_658341__(/*! ./initializer.js */ "./sdk/api/initializer.js");
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_7__ = __nested_webpack_require_658341__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var _types_js__WEBPACK_IMPORTED_MODULE_8__ = __nested_webpack_require_658341__(/*! ./types.js */ "./sdk/api/types.js");
/* harmony import */ var _frame_state_js__WEBPACK_IMPORTED_MODULE_9__ = __nested_webpack_require_658341__(/*! ./frame-state.js */ "./sdk/api/frame-state.js");
/* harmony import */ var _dnr_filters_js__WEBPACK_IMPORTED_MODULE_10__ = __nested_webpack_require_658341__(/*! ./dnr-filters.js */ "./sdk/api/dnr-filters.js");
/* harmony import */ var _errors_js__WEBPACK_IMPORTED_MODULE_11__ = __nested_webpack_require_658341__(/*! ../errors.js */ "./sdk/errors.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */
















function convertFilter(filter) {
  return {
    text: filter.text,
    enabled: typeof filter.disabled == "undefined" ? null : !filter.disabled,
    slow: filter instanceof adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.URLFilter && (0,adblockpluscore_lib_matcher_js__WEBPACK_IMPORTED_MODULE_3__.isSlowFilter)(filter),
    type: filter.type,
    thirdParty: filter.thirdParty || null,
    selector: filter.selector || null,
    csp: filter.csp || null
  };
}

function makeFilterListener(dispatch) {
  return filter => dispatch(convertFilter(filter));
}

function makeSubListener(dispatch) {
  return subscription => {
    if (subscription instanceof adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_2__.SpecialSubscription) {
      for (let text of subscription.filterText())
        dispatch(convertFilter(adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.fromText(text)));
    }
  };
}

/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({
  /**
   * Represents a single filter rule and its state.
   * @typedef {Object} Filter
   * @property {string} text A {@link https://help.eyeo.com/adblockplus/how-to-write-filters|filter}
   *                         rule that specifies what content
   *                         to block or to allow. Used to identify a filter.
   * @property {boolean|null} enabled Indicates whether this filter would
   *                                  be applied. Filters are enabled by
   *                                  default. For comment filters returned
   *                                  value is null.
   * @property {boolean} slow Indicates that this filter is not subject to an
   *                          internal optimization. Filters that are
   *                          considered slow should be avoided. Only URLFilters
   *                          can be slow.
   * @property {string} type The filter {@link https://gitlab.com/eyeo/adblockplus/abc/adblockpluscore/-/jobs/artifacts/0.6.0/file/build/docs/module-filterClasses.Filter.html?job=docs#type|type}
   * @property {boolean|null} thirdParty True when the filter applies to
   *                          third-party, false to first-party, null otherwise.
   * @property {string|null} selector CSS selector for the HTML elements that
   *                                  will be hidden.
   * @property {string|null} csp Content Security Policy to be injected.
   */

  /**
   * Adds multiple filters from texts.
   * @param {[string]} texts The filter rules to be added.
   * @param {?Object} metadata Extra data to associate with a filter.
   * @return {Promise}
   * @throws {FilterError|Error} The first filter to add that either failed
   *   validation (FilterError) or that is not supported by the DNR (Error).
   *   An error will be thrown for duplicated filters.
   */
  async add(texts, metadata) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_6__.default.start();
    if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest) {
      await (0,_dnr_filters_js__WEBPACK_IMPORTED_MODULE_10__.addFilters)(texts, metadata);
      return;
    }

    let filters = [];
    for (let text of texts) {
      let normalized = adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.normalize(text);
      let filter = adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.fromText(normalized);
      let error = (0,_dnr_filters_js__WEBPACK_IMPORTED_MODULE_10__.validateFilter)(filter);

      if (error)
        throw error;

      filters.push(filter);
    }

    let {filterStorage} = _core_js__WEBPACK_IMPORTED_MODULE_7__.filterEngine;

    if (!metadata) {
      if (filterStorage.filtersExist(filters).length > 0)
        throw new _types_js__WEBPACK_IMPORTED_MODULE_8__.FilterError(_errors_js__WEBPACK_IMPORTED_MODULE_11__.ERROR_DUPLICATE_FILTERS);

      for (let filter of filters)
        await filterStorage.addFilter(filter);
    }
    else {
      try {
        await filterStorage.addFiltersWithMetadata(filters, metadata);
      }
      catch (e) {
        throw new _types_js__WEBPACK_IMPORTED_MODULE_8__.FilterError(e.message);
      }
    }
  },

  /**
   * Set an extra data associated with an added filter.
   * @param {string} text filter text to set metadata for.
   * @param {Object} metadata Extra data to associate with a filter.
   * @returns {Promise<void>} Nothing is done for not added filter.
   * @throws {FilterError} An error will be thrown for not added filter.
   */
  async setMetadata(text, metadata) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_6__.default.start();
    if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest) {
      (0,_dnr_filters_js__WEBPACK_IMPORTED_MODULE_10__.setMetadataForFilter)(text, metadata);
      return;
    }

    let {filterStorage} = _core_js__WEBPACK_IMPORTED_MODULE_7__.filterEngine;

    try {
      await filterStorage.setMetadataForFilter(text, metadata);
    }
    catch (e) {
      if (e.message == _errors_js__WEBPACK_IMPORTED_MODULE_11__.ERROR_FILTER_NOT_FOUND) {
        // filter might be added without a metadata first,
        // so we're trying to make it working in a non-surprising way:
        // by removing the existing filter and readding it with a metadata.
        let filter = adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.fromText(adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.normalize(text));
        if (filterStorage.filtersExist([filter]).length > 0) {
          await filterStorage.removeFilter(filter);
          await this.add([text], metadata);
          return;
        }
      }
      throw new _types_js__WEBPACK_IMPORTED_MODULE_8__.FilterError(e.message);
    }
  },

  /**
   * Returns an extra data associated with a filter.
   * @param {string} text The filter text to get metadata for.
   * @return {Promise<?Object>}
   */
  async getMetadata(text) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_6__.default.start();
    if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest)
      return (0,_dnr_filters_js__WEBPACK_IMPORTED_MODULE_10__.getMetadataForFilter)(text);

    return await _core_js__WEBPACK_IMPORTED_MODULE_7__.filterEngine.filterStorage.getMetadataForFilter(text);
  },

  /**
   * Returns an array of user filter objects.
   * @return {Promise<Array<Filter>>}
   */
  async getUserFilters() {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_6__.default.start();
    let result = [];

    for (let subscription of _core_js__WEBPACK_IMPORTED_MODULE_7__.filterEngine.filterStorage.subscriptions()) {
      if (subscription instanceof adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_2__.SpecialSubscription) {
        for (let text of subscription.filterText())
          result.push(convertFilter(adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.fromText(text)));
      }
    }

    if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest) {
      for (let [text, details] of (await (0,_dnr_filters_js__WEBPACK_IMPORTED_MODULE_10__.getDynamicFilters)()).entries()) {
        if (!result.find(filter => filter.text == text)) {
          let filter = convertFilter(adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.fromText(text));
          filter.enabled = filter.type == "comment" ? null : details.enabled;

          result.push(filter);
        }
      }
    }

    return result;
  },

  /**
   * Returns the allowing filters that will be effective
   * when the given document will be reloaded.
   * @param {number} tabId The id of the tab to lookup.
   * @param {Object} [options]
   * @param {number} [options.frameId=0] The id of the frame to lookup.
   * @param {Array<string>} [options.types=["document"]] The types of filters
   *   to consider. These can be any of "document", "elemhide", "genericblock",
   *   and "generichide".
   * @return {Promise<Array<string>>}
   */
  async getAllowingFilters(tabId, options = {}) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_6__.default.start();

    let {frameId, types} = {frameId: 0, types: ["document"], ...options};
    let filters = new Set();
    let mask = types.reduce((a, b) => a | adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_5__.contentTypes[b.toUpperCase()], 0);

    for (let frame = (0,_frame_state_js__WEBPACK_IMPORTED_MODULE_9__.getFrameInfo)(tabId, frameId); frame;
         frame = frame.parent) {
      let parentHostname = frame.parent && frame.parent.hostname;
      let docDomain = parentHostname || frame.hostname;
      let matches = _core_js__WEBPACK_IMPORTED_MODULE_7__.filterEngine.defaultMatcher.search(
        frame.url, mask, docDomain, frame.sitekey, false, "allowing");

      for (let filter of matches.allowing)
        filters.add(filter.text);
    }

    return Array.from(filters);
  },

  /**
   * Returns whether a particular resource is allowlisted.
   * @param {string} url The resource's url.
   * @param {string} type The resource's content type. Can be one of
   *   "background", "csp", "document", "dtd", "elemhide", "font",
   *   "genericblock", "generichide", "header", "image", "media", "object",
   *   "other", "ping", "popup", "script", "stylesheet", "subdocument",
   *   "webrtc", "websocket", "xbl", "xmlhttprequest".
   * @param {number} tabId The id of resource's tab.
   * @param {number} frameId=0 The id of the resource's frame.
   * @return {Promise<bool>}
   */
  async isResourceAllowlisted(url, type, tabId, frameId = 0) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_6__.default.start();

    let mask = adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_5__.contentTypes[type.toUpperCase()];
    let frame = (0,_frame_state_js__WEBPACK_IMPORTED_MODULE_9__.getFrameInfo)(tabId, frameId) || {};
    let matcher = _core_js__WEBPACK_IMPORTED_MODULE_7__.filterEngine.defaultMatcher;

    if (matcher.isAllowlisted(url, mask, frame.hostname, frame.sitekey))
      return true;

    for (; frame; frame = frame.parent) {
      if (!frame.url)
        break;

      let parentHostname = frame.parent && frame.parent.hostname;
      if (matcher.isAllowlisted(frame.url, adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_5__.contentTypes.DOCUMENT,
                                parentHostname, frame.sitekey))
        return true;
    }

    return false;
  },

  /**
   * Enables multiple filters. The filters effects will again be applied.
   * @param {[string]} texts The filter rules to be enabled.
   * @return {Promise}
   */
  async enable(texts) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_6__.default.start();

    if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest) {
      await (0,_dnr_filters_js__WEBPACK_IMPORTED_MODULE_10__.enableFilters)(texts);
      return;
    }

    for (let text of texts) {
      let normalized = adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.normalize(text);
      _core_js__WEBPACK_IMPORTED_MODULE_7__.filterEngine.filterStorage.filterState.setEnabled(normalized, true);
    }
  },

  /**
   * Disables multiple filters. The filters will no longer have any effect
   * but will be returned by `filters.getUserFilters()`.
   * @param {[string]} texts The filter rules to be disabled.
   * @return {Promise}
   */
  async disable(texts) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_6__.default.start();

    if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest) {
      await (0,_dnr_filters_js__WEBPACK_IMPORTED_MODULE_10__.removeOrDisableFilters)(texts, false);
      return;
    }

    for (let text of texts) {
      let normalized = adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.normalize(text);
      _core_js__WEBPACK_IMPORTED_MODULE_7__.filterEngine.filterStorage.filterState.setEnabled(normalized, false);
    }
  },

  /**
   * Removes multiple filters. The filters will no longer have any effect
   * and won't be returned by `filters.getUserFilters()`.
   * @param {[string]} texts The filter rules to be removed.
   * @return {Promise}
   */
  async remove(texts) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_6__.default.start();

    if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest) {
      await (0,_dnr_filters_js__WEBPACK_IMPORTED_MODULE_10__.removeOrDisableFilters)(texts, true);
      return;
    }

    for (let text of texts) {
      let normalized = adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.normalize(text);
      _core_js__WEBPACK_IMPORTED_MODULE_7__.filterEngine.filterStorage.removeFilter(adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.fromText(normalized));
    }
  },

  /**
   * Validates a list of filters.
   * @param {string} text Filter to be validated
   * @return {null|FilterError}
   */
  validate(text) {
    return (0,_dnr_filters_js__WEBPACK_IMPORTED_MODULE_10__.validateFilter)(adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.fromText(text));
  },

  /**
   * Emitted when a new filter is added.
   * @event
   * @type {EventDispatcher<Filter>}
   */
  onAdded: new _types_js__WEBPACK_IMPORTED_MODULE_8__.EventDispatcher(dispatch => {
    adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_4__.filterNotifier.on("filter.added", makeFilterListener(dispatch));
    adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_4__.filterNotifier.on("subscription.added", makeSubListener(dispatch));
  }),

  /**
   * Emitted when a filter is either enabled or disabled.
   * The property name "enabled" is provided.
   * @event
   * @type {EventDispatcher<Filter, string>}
   */
  onChanged: new _types_js__WEBPACK_IMPORTED_MODULE_8__.EventDispatcher(dispatch => {
    adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_4__.filterNotifier.on("filterState.enabled", (text, enabled) => {
      dispatch({...convertFilter(adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.Filter.fromText(text)), enabled}, "enabled");
    });
  }),

  /**
   * Emitted when a filter is removed.
   * @event
   * @type {EventDispatcher<Filter>}
   */
  onRemoved: new _types_js__WEBPACK_IMPORTED_MODULE_8__.EventDispatcher(dispatch => {
    adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_4__.filterNotifier.on("filter.removed", makeFilterListener(dispatch));
    adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_4__.filterNotifier.on("subscription.removed", makeSubListener(dispatch));
  })
});


/***/ }),

/***/ "./sdk/api/frame-state.js":
/*!********************************!*\
  !*** ./sdk/api/frame-state.js ***!
  \********************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_676364__) => {

"use strict";
__nested_webpack_require_676364__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_676364__.d(__webpack_exports__, {
/* harmony export */   "BLANK_PAGE_URL": () => (/* binding */ BLANK_PAGE_URL),
/* harmony export */   "TOP_LEVEL_FRAME_ID": () => (/* binding */ TOP_LEVEL_FRAME_ID),
/* harmony export */   "isTopLevelFrameId": () => (/* binding */ isTopLevelFrameId),
/* harmony export */   "isValidFrameId": () => (/* binding */ isValidFrameId),
/* harmony export */   "isValidChildFrameId": () => (/* binding */ isValidChildFrameId),
/* harmony export */   "getFrameInfo": () => (/* binding */ getFrameInfo),
/* harmony export */   "start": () => (/* binding */ start)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_676364__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var adblockpluscore_lib_url_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_676364__(/*! adblockpluscore/lib/url.js */ "./node_modules/adblockpluscore/lib/url.js");
/* harmony import */ var adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_676364__(/*! adblockpluscore/lib/contentTypes.js */ "./node_modules/adblockpluscore/lib/contentTypes.js");
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_676364__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var _diagnostics_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_676364__(/*! ./diagnostics.js */ "./sdk/api/diagnostics.js");
/* harmony import */ var _sitekey_js__WEBPACK_IMPORTED_MODULE_5__ = __nested_webpack_require_676364__(/*! ./sitekey.js */ "./sdk/api/sitekey.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */










/**
 * The URL that browsers use to represent an empty page, about:blank.
 */
const BLANK_PAGE_URL = "about:blank";

/**
 * The frameId of the top level frame on each tab.
 */
const TOP_LEVEL_FRAME_ID = 0;

/**
 * Checks if a frameId corresponds to the top level frame on a tab.
 * @param {number} frameId
 * @return {boolean}
 */
function isTopLevelFrameId(frameId) {
  return frameId == TOP_LEVEL_FRAME_ID;
}

/**
 * Checks if a frameId corresponds to a frame on a tab.
 * @param {number} frameId
 * @return {boolean}
 */
function isValidFrameId(frameId) {
  return frameId >= TOP_LEVEL_FRAME_ID;
}

/**
 * Checks if a frameId corresponds to an iframe.
 * @param {number} frameId
 * @return {boolean}
 */
function isValidChildFrameId(frameId) {
  return frameId > TOP_LEVEL_FRAME_ID;
}

/**
 * All known currently active frames, that can be looked up by
 * `tabId`, and then by `frameId` (`[tabId, [frameId, FrameInfo]]`).
 *
 * Maintaining this state is the central reason for the code in this
 * file. When we start up EWE, we scan all existing tabs for their
 * frames. After that, we hook into various browser events to try to
 * keep it up to date as things change.
 *
 * @type {Map<number, Map<number, FrameInfo>>}
 */
let state = new Map();
let startupPromise;

/**
 * Manages tracking state that is tied to a single specific frame.
 *
 * A simple webpage will have a single frame in a tab. However, when
 * we look at sites with advertising and embedded trackers, they often
 * have many <iframe> elements. Each iframe may have slightly
 * different state, but generally a frame will inherit settings from
 * the frame that it's on (its parent frame).
 *
 * This state is mostly used in applying frame-level allowing filters
 * (eg `$document` filters), but is also used to hold parameters like
 * what hostname to use when checking if filters match a request, and
 * whether or not a sitekey is involved. This needs to be done
 * statefully because we inherit some state from parent frames.
 *
 * We sometimes need access to this data synchronously (for example to
 * do request filtering), but the functions to fetch this data from
 * the browser on demand are asynchronous. The events where we need to
 * make decisions based on the frame usually have some of the frame's
 * state, like the URL of the frame, but don't have the sitekey and
 * don't have all of the information about the parents of the frame.
 *
 * @property {number} tabId The id of the tab.
 * @property {string} url The url of the frame.
 * @property {string} hostname The hostname part of the frame's
 *   URL. If the URL isn't a normal HTTP URL (for example if it's
 *   about:blank) then this will be the parent frame's hostname. If
 *   that also doesn't have a normal HTTP hostname, then this will
 *   default to an empty string.
 * @property {?string} sitekey The sitekey associated with a frame, if
 *   there is one. These sitekeys are read from the
 *   `onHeadersReceived` event. This is inherited from the parent
 *   frame if this frame doesn't have a sitekey of its own.
 * @property {boolean} headersReceived True if we've received an
 *   `onHeadersReceived` event for this frame and have checked it for
 *   sitekeys. If this is false, it could mean that we don't have
 *   enough information yet to make blocking decisions, because a
 *   sitekey might still arrive with the headers.
 * @property {?FrameInfo} parent The frame that this from is on. Null
 *   if this is the top-level frame on a tab.
 * @property {number} allowlisted Bitfield where each set bit is the
 *   content type of an allowlisting filter applied to the frame. This
 *   includes filters that turn of ad filtering entirely, like
 *   `$document` filters, but also includes filters that modify how we
 *   look up request filters like `$genericblock`.
 * @property {?Filter} allowingDocumentFilter The `$document` filter
 *   that is being applied to this frame, if any. This is useful for
 *   logging, for example if a request is allowed because of this
 *   filter. If you just need to check if there is a `$document` filter
 *   applied to the frame or not, you can also check
 *   `frame.allowlisted`.
 *
 * @param {number} tabId The tabId of the tab that the this frame is on.
 * @param {number} frameId The frameId of this frame.
 * @param {?FrameInfo} parent The frame that this from is on. Null
 *   if this is the top-level frame on a tab.
 * @param {string} url The url of the frame.
 * @hideconstructor
 */
class FrameInfo {
  constructor(tabId, frameId, parent, url) {
    let {
      allowlisted: parentAllowlisted,
      sitekey: parentSitekey,
      allowingDocumentFilter: parentAllowingDocumentFilter
    } = parent || {};

    let urlInfo = (0,adblockpluscore_lib_url_js__WEBPACK_IMPORTED_MODULE_1__.parseURL)(url);

    this.tabId = tabId;
    this.url = url;
    this.hostname = urlInfo.hostname || (parent ? parent.hostname : "");
    let sitekey = (0,_sitekey_js__WEBPACK_IMPORTED_MODULE_5__.getSitekey)(tabId, frameId, url);
    this.sitekey = sitekey || parentSitekey;
    this.headersReceived = (!!sitekey) || sitekey === null;
    this.parent = parent;

    // allowlisted and allowingDocumentFilter start with their parent
    // value, but may have extra allowing filters added when we call
    // findAllowlistingFilters
    this.allowlisted = parentAllowlisted || 0;
    this.allowingDocumentFilter = parentAllowingDocumentFilter;

    findAllowlistingFilters(this, tabId, frameId);
  }
}

/**
 * Get a text description of the allowing filter added.
 * @param {number} typeMask Bitset to filter types you want to name.
 * @param {Filter} filter The filter with the allowing reason you want
 *   to name.
 * @return {string} Content type name of the allowing filter just
 *   added.
 */
function getAllowingReason(typeMask, filter) {
  for (let type in adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes) {
    if (typeMask & filter.contentType & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes[type])
      return type.toLowerCase();
  }
}

/**
 * Checks if the matcher has any allowing filters that should be
 * applied to this frame, and updates `frame.allowlisted` and
 * `frame.allowingDocumentFilter` accordingly.
 *
 * This can only ever add extra allowing filters. It's also safe to
 * call multiple times on the same frame. This would normally be
 * called on a new frame to find its allowing filters, but should also
 * be called whenever a frame is updated in such a way that there
 * could be new allowing filters, for example when a sitekey is added
 * to an existing frame.
 *
 * @param {FrameInfo} frame The frame that will be checked for new
 *   filters, and will be updated.
 * @param {number} tabId The tabId of the tab the frame is on. Used for
 *   logging.
 * @param {number} frameId The frameId of the frame. Used for logging.
 */
function findAllowlistingFilters(frame, tabId, frameId) {
  let details = {tabId, frameId, url: frame.url};
  // The docDomain for a frame is the hostname of the parent frame
  // (the loader). For top-level frames we use the current URL's hostname.
  let parentHostname = frame.parent && frame.parent.hostname;
  let matchInfo = {docDomain: parentHostname || frame.hostname,
                   method: "allowing"};

  // This loop will keep trying to find new types of allowing filters
  // for the frame until the matcher doesn't return any more.
  while (true) {
    let typeMask = ~frame.allowlisted & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.ALLOWING_TYPES;
    let filter = _core_js__WEBPACK_IMPORTED_MODULE_3__.filterEngine.defaultMatcher.match(
      frame.url, typeMask, matchInfo.docDomain, frame.sitekey
    );

    if (!filter)
      break;

    frame.allowlisted |= filter.contentType & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.ALLOWING_TYPES;
    // We need to hold onto document allowing filters because we might
    // need it for logging blockable requests later.
    if (filter.contentType & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.DOCUMENT)
      frame.allowingDocumentFilter = filter;

    let allowingReason = getAllowingReason(typeMask, filter);
    (0,_diagnostics_js__WEBPACK_IMPORTED_MODULE_4__.logItem)(details, filter, {...matchInfo, allowingReason});
  }
}

/**
 * Builds the frame state from scratch using the tabs API.
 *
 * This is called on startup, and in MV3 whenever the service worker
 * starts up. The only shortcoming is that this can't find sitekeys
 * for existing frames, since those are read from headers.
 * @async
 * @return {Promise} Resolves when all frames have been scanned.
 */
async function discoverExistingFrames() {
  let tabs = await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.tabs.query({});
  await Promise.all(tabs.map(({id: tabId}) =>
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.getAllFrames({tabId}).then(rawFrames => {
      if (!rawFrames)
        return;

      // Sort the frames so that we'll add parent frames before the
      // child frames.
      rawFrames.sort((a, b) => a.frameId - b.frameId);

      let frames = new Map();
      state.set(tabId, frames);

      for (let {frameId, parentFrameId, url} of rawFrames) {
        let parent = isValidFrameId(parentFrameId) ?
            frames.get(parentFrameId) :
            null;

        // Chrome unfortunately has a bug where getAllFrames doesn't
        // always return all parent frames
        // (https://bugs.chromium.org/p/chromium/issues/detail?id=725917).
        // Not much we can do about it, but if we can't see the
        // required parent frame we can fall back to the root frame.
        if (isValidChildFrameId(parentFrameId) && !parent)
          parent = frames.get(TOP_LEVEL_FRAME_ID);

        // Yandex gives undefined or an empty string here sometimes,
        // for example when browsing to pages that Yandex treats
        // specially like their own website.
        if (!url)
          url = BLANK_PAGE_URL;

        frames.set(frameId, new FrameInfo(tabId, frameId, parent, url));
      }
    })
  ));
}

function onSitekeyReceived(tabId, frameId, url, sitekey) {
  let frame = getFrameInfo(tabId, frameId);
  let isSameFrame = frame && frame.url == url;
  if (isSameFrame)
    frame.headersReceived = true;

  if (sitekey) {
    // Sometimes the onHeadersReceived event comes after the
    // onCommitted event. This seems to be common when loading
    // iframes: the browser will show the iframe and then start
    // loading its contents. When this happens, we may get a sitekey
    // for a frame that's already being shown, and that may mean we
    // need to add some new allowlisting filters based on that
    // sitekey.
    if (isSameFrame && frame.sitekey != sitekey) {
      frame.sitekey = sitekey;
      findAllowlistingFilters(frame, tabId, frameId);
    }
  }
}


/**
 * Updates the frame state to reflect that a new frame is being shown.
 *
 * This can broadly be thought of in two categories:
 *
 * 1. The browser has navigated to the new page. Specifically, this is
 *    on the `webNavigation.onCommitted` event, which fires when the
 *    browser has decided to switch to the new document. We will
 *    usually have received headers for the document already by this
 *    point, but not always.
 * 2. The site is a single page application, and has updated its
 *    contents using Javascript and updated its URL with the history
 *    API.
 *
 * @param {Object} details Details object as provided by the
 *   webNavigation API events.
 * @param {number} details.tabId The tabId of the tab that the updated
 *   frame is on.
 * @param {number} details.frameId The frameId of the updated frame.
 * @param {number} [details.parentFrameId=-1] The frameId of the frame
 *   that the updated frame is on. -1 if the updated frame is the
 *   top-level frame.
 * @param {string} details.url The new url of the frame.
 * @param {Object} [options={}]
 * @param {boolean} [options.historyStateUpdated=false] True if this
 *   was triggered by a history state update, rather than by a full
 *   page navigation.
 * @param {boolean} [options.errorOccurred=false] True if this was
 *   triggered by a `webNavigation.onErrorOccurred` event rather than
 *   a `webNavigation.onCommitted` event.
 * @return {FrameInfo} The newly created frame state.
 */
function recordFrameFromNavigationEvent(
  {tabId, frameId, parentFrameId = -1, url},
  {historyStateUpdated = false, errorOccurred = false} = {}) {
  // Yandex gives undefined or an empty string here sometimes,
  // for example when browsing to pages that Yandex treats
  // specially like their own website.
  if (!url)
    url = BLANK_PAGE_URL;

  let frames = state.get(tabId);

  // We generally need to throw away any existing frame state for the
  // whole tab when a new top-level frame is committed to the
  // tab. This is because all previous frame state was on the old
  // top-level frame. However, if this was a history API update, those
  // frames could still be there on the page so we can't clear them out.
  if (!frames || (isTopLevelFrameId(frameId) && !historyStateUpdated)) {
    frames = new Map();
    state.set(tabId, frames);
  }
  let frame = frames.get(frameId);
  let parent = isValidFrameId(parentFrameId) ? frames.get(parentFrameId) : null;

  // Same as discoverExistingFrames, if we expect a parent but our
  // frame state doesn't seem to have that parent, falling back to the
  // root frame is better than nothing. This might happen due to this
  // bug: https://bugs.chromium.org/p/chromium/issues/detail?id=725917.
  if (isValidChildFrameId(parentFrameId) && !parent)
    parent = frames.get(TOP_LEVEL_FRAME_ID);

  // If the frame had an error instead of loading, we don't want to
  // use the URL from the error. Otherwise unscrupulous websites could
  // embed their advert in an iframe that has an allowlisted URL, but
  // doesn't actually contain the contents of that URL.
  if (errorOccurred) {
    if (frame)
      url = frame.url;
    else if (parent)
      url = parent.url;
  }

  // We might get multiple calls to `recordFrameFromNavigationEvent`
  // for iframes. This is because we need to listen to several
  // different events to hear about all frames, including onCommitted
  // and onBeforeNavigate and onErrorOccurred. To avoid duplicate
  // onBlockableItem events, we check if the frame we already have is
  // the same.
  if (!frame || isTopLevelFrameId(frameId) ||
      frame.url != url || frame.parent != parent) {
    frame = new FrameInfo(tabId, frameId, parent, url);
    frames.set(frameId, frame);
  }
  return frame;
}

function onBeforeNavigate(details) {
  // If an iframe's URL is "about:srcdoc", that means its contents is
  // actually specified using the srcdoc attribute. Some browsers
  // don't actually emit the webNavigation.onCommitted event for these
  // frames, so we need to use a different event to get them into our
  // frame state.
  if (details.url == "about:srcdoc")
    recordFrameFromNavigationEvent(details);
}

function onCommitted(details) {
  recordFrameFromNavigationEvent(details);
}

function onErrorOccurred(details) {
  // On Chrome, errored iframes are never committed, but they are
  // still on the page and their contents can still be manipulated
  // with Javascript so we need them in our frame state.
  // See https://bugs.chromium.org/p/chromium/issues/detail?id=725917
  //
  // Firefox's docs don't mention parentFrameId on this event, but
  // Chrome's do, and it does appear to be there in practice. Check
  // for it before proceeding in case some browsers don't, since it's
  // very important to have the parent frame to record frame state
  // changes.
  if (isValidChildFrameId(details.frameId) &&
      typeof details.parentFrameId == "number")
    recordFrameFromNavigationEvent(details, {errorOccurred: true});
}

function onHistoryStateUpdated(details) {
  recordFrameFromNavigationEvent(details, {historyStateUpdated: true});
}

function onRemoved(tabId) {
  state.delete(tabId);
  (0,_sitekey_js__WEBPACK_IMPORTED_MODULE_5__.clearTabSitekeys)(tabId);
}

function onReplaced(addedTabId, removedTabId) {
  state.delete(removedTabId);
  (0,_sitekey_js__WEBPACK_IMPORTED_MODULE_5__.clearTabSitekeys)(removedTabId);
}

/**
 * Gets the state for a frame if we have it. If parentFrameId and
 * initiator are also provided, this function may also construct the
 * frame and add it to the frame state.
 *
 * @param {number} tabId The tabId of the tab the frame is on.
 * @param {number} frameId The frameId of the frame.
 * @param {?Object} [metadata] Additional metadata about the web
 *   request context that lead to asking for frame info, which might
 *   be used to create a FrameInfo if one doesn't exist already.
 * @param {?number} metadata.parentFrameId The frameId of the parent of the
 *   frame being requested. If this is set, it could be used to
 *   create the frame if it isn't already in the frame state.
 * @param {?string} metadata.initiator If getting the frame info is
 *   triggered by a web request, this should be the URL that initiated
 *   the request. If this is set, it can be used to provide a
 *   temporary frame state for use with service workers. In Firefox
 *   APIs, there is not an initiator but there is a documentUrl which
 *   can fulfil the same purpose.
 * @param {?string} metadata.documentUrl If getting the frame info is
 *   triggered by a web request, this should be the URL of the frame
 *   that initiated the request. If this is set, it could be used to
 *   create the frame if it isn't already in the frame state. This may
 *   not be available in Chrome. In Chrome, if initiator is provided,
 *   it can also be used to construct a FrameInfo, but this is not
 *   ideal since the initiator only contains the domain part of the
 *   URL.
 * @returns {?FrameInfo}
 */
function getFrameInfo(tabId, frameId,
                             {parentFrameId, initiator, documentUrl} = {}) {
  // tabId is -1 if the request came from a service worker, so we
  // construct a temporary frame state for it to use. We don't store
  // a tabId of -1 in our frame state, so we don't even need to check
  // it before returning.
  if (initiator && tabId == -1)
    return new FrameInfo(tabId, frameId, null, initiator);

  let frames = state.get(tabId);
  if (frames) {
    let frame = frames.get(frameId);
    if (frame)
      return frame;
  }

  // Sometimes the webRequest API can trigger for resources in a frame
  // before the onCommitted event for the frame. In this case, it
  // should be safe to construct the frame state early.
  if (documentUrl && typeof parentFrameId == "number") {
    return recordFrameFromNavigationEvent({
      tabId,
      frameId,
      parentFrameId,
      url: documentUrl
    });
  }
}

async function start() {
  if (!startupPromise) {
    (0,_sitekey_js__WEBPACK_IMPORTED_MODULE_5__.addListener)(onSitekeyReceived);

    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onBeforeNavigate.addListener(onBeforeNavigate);
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onCommitted.addListener(onCommitted);
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onErrorOccurred.addListener(onErrorOccurred);
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onHistoryStateUpdated.addListener(
      onHistoryStateUpdated);
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.tabs.onRemoved.addListener(onRemoved);
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.tabs.onReplaced.addListener(onReplaced);

    startupPromise = discoverExistingFrames();
  }

  await startupPromise;
}


/***/ }),

/***/ "./sdk/api/idb.js":
/*!************************!*\
  !*** ./sdk/api/idb.js ***!
  \************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_698762__) => {

"use strict";
__nested_webpack_require_698762__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_698762__.d(__webpack_exports__, {
/* harmony export */   "openDatabase": () => (/* binding */ openDatabase)
/* harmony export */ });
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */

const DB_NAME = "EWE";
const DB_VERSION = 1;

function openDatabase() {
  return new Promise((resolve, reject) => {
    let request = indexedDB.open(DB_NAME, DB_VERSION);

    request.onupgradeneeded = event => {
      let db = event.target.result;
      db.createObjectStore("file-entries");
      db.createObjectStore("file-contents", {autoIncrement: true});
    };

    request.onsuccess = event => resolve(event.target.result);
    request.onerror = event => reject(event.target.error);
  });
}


/***/ }),

/***/ "./sdk/api/info.js":
/*!*************************!*\
  !*** ./sdk/api/info.js ***!
  \*************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_700386__) => {

"use strict";
__nested_webpack_require_700386__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_700386__.d(__webpack_exports__, {
/* harmony export */   "addonName": () => (/* binding */ addonName),
/* harmony export */   "addonVersion": () => (/* binding */ addonVersion),
/* harmony export */   "addonBundledSubscriptions": () => (/* binding */ addonBundledSubscriptions),
/* harmony export */   "addonBundledSubscriptionsPath": () => (/* binding */ addonBundledSubscriptionsPath),
/* harmony export */   "application": () => (/* binding */ application),
/* harmony export */   "applicationVersion": () => (/* binding */ applicationVersion),
/* harmony export */   "platform": () => (/* binding */ platform),
/* harmony export */   "platformVersion": () => (/* binding */ platformVersion),
/* harmony export */   "manifestVersion": () => (/* binding */ manifestVersion),
/* harmony export */   "setAddonInfo": () => (/* binding */ setAddonInfo)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_700386__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var adblockpluscore_lib_recommendations_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_700386__(/*! adblockpluscore/lib/recommendations.js */ "./node_modules/adblockpluscore/lib/recommendations.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */





let manifest = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.runtime.getManifest();

let addonName = manifest.short_name || manifest.name;
let addonVersion = manifest.version;
let addonBundledSubscriptions;
let addonBundledSubscriptionsPath;
let application = "unknown";
let applicationVersion = "0";
let platform;
let platformVersion = "0";
let manifestVersion = String(manifest.manifest_version);

function parseChromiumUserAgent() {
  let regexp = /(\S+)\/(\S+)(?:\s*\(.*?\))?/g;
  let match;

  while (match = regexp.exec(navigator.userAgent)) {
    let [, app, version] = match;

    // For compatibility with legacy websites, Chrome's UA
    // also includes a Mozilla, AppleWebKit and Safari tokens.
    // Any further name/version pair indicates a fork.
    if (app == "Mozilla" || app == "AppleWebKit" || app == "Safari")
      continue;

    if (app == "Chrome") {
      platformVersion = version;
      if (application != "unknown")
        continue;
    }

    application = app == "OPR" ? "opera" : app.toLowerCase();
    applicationVersion = version;
  }
}

if (typeof netscape != "undefined") {
  platform = "gecko";

  let match = /\brv:([^;)]+)/.exec(navigator.userAgent);
  if (match)
    platformVersion = match[1];

  webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.runtime.getBrowserInfo().then(browserInfo => {
    application = browserInfo.name.toLowerCase();
    applicationVersion = browserInfo.version;
  });
}
else {
  platform = "chromium";
  parseChromiumUserAgent();
}

function setAddonInfo(addonInfo) {
  if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest) {
    if (!addonInfo)
      throw new Error("No addonInfo provided to EWE.start");

    if (!addonInfo.bundledSubscriptions)
      throw new Error("No `bundledSubscriptions` provided");

    if (!addonInfo.bundledSubscriptionsPath)
      throw new Error("No `bundledSubscriptionsPath` provided");
  }

  if (!addonInfo)
    return;

  if (addonInfo.name)
    addonName = addonInfo.name;
  if (addonInfo.version)
    addonVersion = addonInfo.version;
  if (addonInfo.manifestVersion)
    manifestVersion = addonInfo.manifestVersion;

  addonBundledSubscriptions = addonInfo.bundledSubscriptions;
  addonBundledSubscriptionsPath = addonInfo.bundledSubscriptionsPath;

  if (addonBundledSubscriptions &&
      addonBundledSubscriptions.length > 0)
    (0,adblockpluscore_lib_recommendations_js__WEBPACK_IMPORTED_MODULE_1__.setRecommendations)(addonBundledSubscriptions);
}


/***/ }),

/***/ "./sdk/api/initializer.js":
/*!********************************!*\
  !*** ./sdk/api/initializer.js ***!
  \********************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_705191__) => {

"use strict";
__nested_webpack_require_705191__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_705191__.d(__webpack_exports__, {
/* harmony export */   "default": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_705191__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var _frame_state_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_705191__(/*! ./frame-state.js */ "./sdk/api/frame-state.js");
/* harmony import */ var _io_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_705191__(/*! ./io.js */ "./sdk/api/io.js");
/* harmony import */ var _dnr_filters_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_705191__(/*! ./dnr-filters.js */ "./sdk/api/dnr-filters.js");
/* harmony import */ var _prefs_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_705191__(/*! ./prefs.js */ "./sdk/api/prefs.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */







let startupPromise;

/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({
  /**
   * Initializes stateful modules that may be used in filtering requests.
   *
   * This function is idempotent. If you call it after initialization
   * has already been launched elsewhere, then it will return the same
   * promise as the original initialization. This allows this function
   * to be called anywhere that you need to ensure that initialization
   * has completed before continuing.
   *
   * Calling this function is required for the other API calls to
   * work, except for API event listener calls, which could also be
   * done before `start()`.
   * @return {Promise} Resolves when initialization is complete
   */
  start() {
    if (!startupPromise) {
      startupPromise = (async() => {
        await _io_js__WEBPACK_IMPORTED_MODULE_2__.IO.initialize();
        await (0,_prefs_js__WEBPACK_IMPORTED_MODULE_4__.init)();
        await _core_js__WEBPACK_IMPORTED_MODULE_0__.filterEngine.initialize();
        await _frame_state_js__WEBPACK_IMPORTED_MODULE_1__.start();
        await (0,_dnr_filters_js__WEBPACK_IMPORTED_MODULE_3__.init)();
      })();
    }
    return startupPromise;
  }
});


/***/ }),

/***/ "./sdk/api/io-bsl.js":
/*!***************************!*\
  !*** ./sdk/api/io-bsl.js ***!
  \***************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_708194__) => {

"use strict";
__nested_webpack_require_708194__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_708194__.d(__webpack_exports__, {
/* harmony export */   "IO": () => (/* binding */ IO)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_708194__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */



const KEY_PREFIX = "ewe:file:";

function fileToKey(fileName) {
  return KEY_PREFIX + fileName;
}

async function loadFile(fileName) {
  let key = fileToKey(fileName);
  let items = await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.local.get(key);
  let entry = items[key];
  if (entry)
    return entry;
  throw {type: "NoSuchFile"};
}

function saveFile(fileName, data) {
  return webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.local.set({
    [fileToKey(fileName)]: {
      content: Array.from(data),
      lastModified: Date.now()
    }
  });
}

// IO implementation that is using `browser.storage.local` API
let IO = {
  /**
   * Reads text lines from a file.
   * @param {string} filename
   *    Name of the file to be read
   * @param {TextSink} listener
   *    Function that will be called for each line in the file
   * @return {Promise}
   *    Promise to be resolved or rejected once the operation is completed
   */
  async readFromFile(filename, listener) {
    let entry = await loadFile(filename);
    for (let line of entry.content)
      listener(line);
  },

  /**
   * Writes text lines to a file.
   * @param {string} filename
   *    Name of the file to be written
   * @param {Iterable.<string>} data
   *    An array-like or iterable object containing the lines (without line
   *    endings)
   * @return {Promise}
   *    Promise to be resolved or rejected once the operation is completed
   */
  writeToFile(filename, data) {
    return saveFile(filename, data);
  },

  /**
   * Renames a file.
   * @param {string} fromFile
   *    Name of the file to be renamed
   * @param {string} newName
   *    New file name, will be overwritten if exists
   * @return {Promise}
   *    Promise to be resolved or rejected once the operation is completed
   */
  async renameFile(fromFile, newName) {
    let entry = await loadFile(fromFile);
    await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.local.set({[fileToKey(newName)]: entry});
    await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.local.remove(fileToKey(fromFile));
  },

  /**
   * Retrieves file metadata.
   * @param {string} filename
   *    Name of the file to be looked up
   * @return {Promise.<StatData>}
   *    Promise to be resolved with file metadata once the operation is
   *    completed
   */
  async statFile(filename) {
    try {
      let entry = await loadFile(filename);
      return {
        exists: true,
        lastModified: entry.lastModified
      };
    }
    catch (error) {
      if (error.type == "NoSuchFile")
        return Promise.resolve({exists: false});
      throw error;
    }
  },

  async fixPrefixes() {
    let data = await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.local.get();
    for (let key in data) {
      let value = data[key];

      // The order of prefixes matters:
      // the most important should be the last
      // to override the existing values jic.
      for (let eachPrefix of ["abp:file:", "file:"]) {
        if (key.startsWith(eachPrefix)) {
          let obj = {};
          obj[KEY_PREFIX + key.substring(eachPrefix.length)] = value;
          await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.local.set(obj);
          await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.local.remove(key);
        }
      }
    }
  },

  /**
   * Initialize the storage
   * @return {Promise} initialization promise
   */
  async initialize() {
    // Migrating the files with 'file:' and `abp:file:` prefixes
    // to 'ewe:file:' stored in `browser.storage.local` in Firefox private mode.
    // See https://gitlab.com/eyeo/adblockplus/abc/webext-sdk/-/issues/369
    await this.fixPrefixes();
  }
};



/***/ }),

/***/ "./sdk/api/io-idb.js":
/*!***************************!*\
  !*** ./sdk/api/io-idb.js ***!
  \***************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_713244__) => {

"use strict";
__nested_webpack_require_713244__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_713244__.d(__webpack_exports__, {
/* harmony export */   "getDatabase": () => (/* binding */ getDatabase),
/* harmony export */   "IO": () => (/* binding */ IO)
/* harmony export */ });
/* harmony import */ var _idb_js__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_713244__(/*! ./idb.js */ "./sdk/api/idb.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */



let database;

function clearContent(filename, entryStore, contentStore) {
  entryStore.get(filename).onsuccess = event => {
    let entry = event.target.result;
    if (entry)
      contentStore.delete(entry.content);
  };
}

function saveFile(db, filename, lines, lastModified) {
  return new Promise((resolve, reject) => {
    let data = new TextEncoder().encode(Array.from(lines).join("\n"));
    let tx = db.transaction(["file-entries", "file-contents"], "readwrite");
    let entryStore = tx.objectStore("file-entries");
    let contentStore = tx.objectStore("file-contents");

    clearContent(filename, entryStore, contentStore);
    contentStore.add(data).onsuccess = event => {
      let content = event.target.result;
      entryStore.put({lastModified, content}, filename);
    };

    tx.oncomplete = () => resolve();
    tx.onerror = tx.onabort = event => reject(event.target.error);
  });
}

async function initIO(db) {
  database = db;
}

function getDatabase() {
  if (!database)
    throw new Error("Database hasn't been opened. Did you call start()?");
  return database;
}

// IO implementation that is using `IndexedDB`
let IO = {
  /**
   * Reads text lines from a file.
   * @param {string} filename
   *    Name of the file to be read
   * @param {TextSink} listener
   *    Function that will be called for each line in the file
   * @return {Promise}
   *    Promise to be resolved or rejected once the operation is completed
   */
  async readFromFile(filename, listener) {
    let data = await new Promise((resolve, reject) => {
      let db = getDatabase();
      let tx = db.transaction(["file-entries", "file-contents"], "readonly");
      let entryStore = tx.objectStore("file-entries");
      let contentStore = tx.objectStore("file-contents");

      entryStore.get(filename).onsuccess = entryEvent => {
        let entry = entryEvent.target.result;
        if (!entry) {
          reject(new Error("File does not exist"));
          return;
        }

        contentStore.get(entry.content).onsuccess = contentEvent => {
          resolve(contentEvent.target.result);
        };
      };

      tx.onerror = tx.onabort = event => reject(event.target.error);
    });

    let decoder = new TextDecoder();
    let start = 0;

    while (true) {
      let index = data.indexOf(10 /* newline character */, start + 1000);
      let end = index != -1 ? index : data.length;
      let text = decoder.decode(data.subarray(start, end));

      for (let line of text.split("\n"))
        listener(line);

      if (index == -1)
        break;

      start = index + 1;
    }
  },

  /**
   * Writes text lines to a file.
   * @param {string} filename
   *    Name of the file to be written
   * @param {Iterable<string>} lines
   *    An array-like or iterable object containing the lines (without line
   *    endings)
   * @return {Promise}
   *    Promise to be resolved or rejected once the operation is completed
   */
  async writeToFile(filename, lines) {
    await saveFile(getDatabase(), filename, lines, Date.now());
  },

  /**
   * Renames a file.
   * @param {string} oldName
   *    Name of the file to be renamed
   * @param {string} newName
   *    New file name, will be overwritten if exists
   * @return {Promise}
   *    Promise to be resolved or rejected once the operation is completed
   */
  renameFile(oldName, newName) {
    return new Promise((resolve, reject) => {
      let db = getDatabase();
      let tx = db.transaction(["file-entries", "file-contents"], "readwrite");
      let entryStore = tx.objectStore("file-entries");
      let contentStore = tx.objectStore("file-contents");

      entryStore.get(oldName).onsuccess = event => {
        let entry = event.target.result;
        if (!entry) {
          reject(new Error("File does not exist"));
          return;
        }

        clearContent(newName, entryStore, contentStore);
        entryStore.put(entry, newName);
        entryStore.delete(oldName);
      };

      tx.oncomplete = () => resolve();
      tx.onerror = tx.onabort = event => reject(event.target.error);
    });
  },

  /**
   * Retrieves file metadata.
   * @param {string} filename
   *    Name of the file to be looked up
   * @return {Promise<StatData>}
   *    Promise to be resolved with file metadata once the operation is
   *    completed
   */
  statFile(filename) {
    return new Promise((resolve, reject) => {
      let db = getDatabase();
      let tx = db.transaction(["file-entries"], "readonly");
      let store = tx.objectStore("file-entries");

      store.get(filename).onsuccess = event => {
        let entry = event.target.result;
        let exists = false;
        let lastModified;

        if (entry) {
          exists = true;
          lastModified = entry.lastModified;
        }

        resolve({exists, lastModified});
      };

      tx.onerror = tx.onabort = event => reject(event.target.error);
    });
  },

  /**
   * Initialize the storage
   * @return {Promise} initialization promise
   */
  async initialize() {
    let db = await (0,_idb_js__WEBPACK_IMPORTED_MODULE_0__.openDatabase)();
    await initIO(db);
  }
};


/***/ }),

/***/ "./sdk/api/io.js":
/*!***********************!*\
  !*** ./sdk/api/io.js ***!
  \***********************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_719683__) => {

"use strict";
__nested_webpack_require_719683__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_719683__.d(__webpack_exports__, {
/* harmony export */   "readFileContent": () => (/* binding */ readFileContent),
/* harmony export */   "IO": () => (/* binding */ IO)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_719683__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var _io_idb_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_719683__(/*! ./io-idb.js */ "./sdk/api/io-idb.js");
/* harmony import */ var _io_bsl_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_719683__(/*! ./io-bsl.js */ "./sdk/api/io-bsl.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */






let io;
let initializationPromise;

function readFileContent(path) {
  const url = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.runtime.getURL(path);
  return fetch(url).then(content => content.text());
}

// This is a facade implementation that forwards to the current concrete
// implementation of IO. By default IndexedDB is used but if it's unavailable
// a fallback to `browser.storage.local` is used.
let IO = {
  /**
   * Reads text lines from a file.
   * @param {string} filename
   *    Name of the file to be read
   * @param {TextSink} listener
   *    Function that will be called for each line in the file
   * @return {Promise}
   *    Promise to be resolved or rejected once the operation is completed
   */
  async readFromFile(filename, listener) {
    return io.readFromFile(filename, listener);
  },

  /**
   * Writes text lines to a file.
   * @param {string} filename
   *    Name of the file to be written
   * @param {Iterable<string>} lines
   *    An array-like or iterable object containing the lines (without line
   *    endings)
   * @return {Promise}
   *    Promise to be resolved or rejected once the operation is completed
   */
  async writeToFile(filename, lines) {
    return io.writeToFile(filename, lines);
  },

  /**
   * Renames a file.
   * @param {string} oldName
   *    Name of the file to be renamed
   * @param {string} newName
   *    New file name, will be overwritten if exists
   * @return {Promise}
   *    Promise to be resolved or rejected once the operation is completed
   */
  renameFile(oldName, newName) {
    return io.renameFile(oldName, newName);
  },

  /**
   * Retrieves file metadata.
   * @param {string} filename
   *    Name of the file to be looked up
   * @return {Promise<StatData>}
   *    Promise to be resolved with file metadata once the operation is
   *    completed
   */
  statFile(filename) {
    return io.statFile(filename);
  },

  /**
   * Initialize the storage
   * @return {Promise} initialization promise
   */
  initialize() {
    if (!initializationPromise) {
      initializationPromise = (async() => {
        io = _io_idb_js__WEBPACK_IMPORTED_MODULE_1__.IO;
        try {
          await io.initialize();
        }
        catch (e) {
          if (e instanceof DOMException &&
              e.name == "InvalidStateError") {
            // fall back to `browser.storage.local` API if IndexedDb
            // is unavailable, eg. in Firefox in private mode. See
            // https://gitlab.com/eyeo/adblockplus/abc/webext-sdk/-/issues/231
            io = _io_bsl_js__WEBPACK_IMPORTED_MODULE_2__.IO;
            try {
              await io.initialize();
            }
            catch {
              initializationPromise = null;
              throw e;
            }
          }
          else {
            initializationPromise = null;
            throw e;
          }
        }
      })();
    }

    return initializationPromise;
  }
};


/***/ }),

/***/ "./sdk/api/message-responder.js":
/*!**************************************!*\
  !*** ./sdk/api/message-responder.js ***!
  \**************************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_724326__) => {

"use strict";
__nested_webpack_require_724326__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_724326__.d(__webpack_exports__, {
/* harmony export */   "start": () => (/* binding */ start)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_724326__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var _initializer_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_724326__(/*! ./initializer.js */ "./sdk/api/initializer.js");
/* harmony import */ var _content_filter_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_724326__(/*! ./content-filter.js */ "./sdk/api/content-filter.js");
/* harmony import */ var adblockpluscore_lib_elemHide_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_724326__(/*! adblockpluscore/lib/elemHide.js */ "./node_modules/adblockpluscore/lib/elemHide.js");
/* harmony import */ var _subscribe_links_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_724326__(/*! ./subscribe-links.js */ "./sdk/api/subscribe-links.js");
/* harmony import */ var _diagnostics_js__WEBPACK_IMPORTED_MODULE_5__ = __nested_webpack_require_724326__(/*! ./diagnostics.js */ "./sdk/api/diagnostics.js");
/* harmony import */ var _allowlisting_js__WEBPACK_IMPORTED_MODULE_6__ = __nested_webpack_require_724326__(/*! ./allowlisting.js */ "./sdk/api/allowlisting.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */










async function handleMessage(message, sender) {
  await _initializer_js__WEBPACK_IMPORTED_MODULE_1__.default.start();
  switch (message.type) {
    case "ewe:content-hello":
      // Firefox mistakenly runs content scripts in non-web page context,
      // it does not happen in Chrome.
      // https://gitlab.com/eyeo/adblockplus/abc/webext-sdk/-/issues/174.
      // Messages sent from a non-web page context do not have an
      // associated tab and can be ignored.
      if (!sender.tab)
        return;

      let filterData = await (0,_content_filter_js__WEBPACK_IMPORTED_MODULE_2__.applyContentFilters)(sender.tab.id, sender.frameId);
      return {
        ...filterData,
        subscribeLinks: (0,_subscribe_links_js__WEBPACK_IMPORTED_MODULE_4__.subscribeLinksEnabled)(sender.url)
      };
    case "ewe:subscribe-link-clicked":
      (0,_subscribe_links_js__WEBPACK_IMPORTED_MODULE_4__.subscribeLinkClicked)(message.url, message.title);
      break;
    case "ewe:trace-elem-hide":
      (0,_diagnostics_js__WEBPACK_IMPORTED_MODULE_5__.logHiddenElements)(message.selectors, message.filters, sender);
      break;
    case "ewe:inject-css":
      let styleSheet = (0,adblockpluscore_lib_elemHide_js__WEBPACK_IMPORTED_MODULE_3__.createStyleSheet)([message.selector]);
      (0,_content_filter_js__WEBPACK_IMPORTED_MODULE_2__.injectCSS)(sender.tab.id, sender.frameId, styleSheet);
      break;
    case "ewe:allowlist-page":
      return (0,_allowlisting_js__WEBPACK_IMPORTED_MODULE_6__.allowlistPage)(
        sender.tab.id, sender.frameId, message.timestamp, message.signature
      );
  }
}

function onMessage(message, sender) {
  if (typeof message == "object" && message != null &&
      message.type && message.type.startsWith("ewe:"))
    return handleMessage(message, sender);
  return false;
}

/**
 * Start the message responder module. In MV3, this must be called in
 * the first turn of the event loop.
 */
function start() {
  webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.runtime.onMessage.addListener(onMessage);
}


/***/ }),

/***/ "./sdk/api/popup-blocker-background-page.js":
/*!**************************************************!*\
  !*** ./sdk/api/popup-blocker-background-page.js ***!
  \**************************************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_728732__) => {

"use strict";
__nested_webpack_require_728732__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_728732__.d(__webpack_exports__, {
/* harmony export */   "start": () => (/* binding */ start)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_728732__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_728732__(/*! adblockpluscore/lib/filterClasses.js */ "./node_modules/adblockpluscore/lib/filterClasses.js");
/* harmony import */ var adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_728732__(/*! adblockpluscore/lib/contentTypes.js */ "./node_modules/adblockpluscore/lib/contentTypes.js");
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_728732__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var _diagnostics_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_728732__(/*! ./diagnostics.js */ "./sdk/api/diagnostics.js");
/* harmony import */ var _frame_state_js__WEBPACK_IMPORTED_MODULE_5__ = __nested_webpack_require_728732__(/*! ./frame-state.js */ "./sdk/api/frame-state.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */










let loadingPopups = new Map();

function forgetPopup(tabId) {
  loadingPopups.delete(tabId);

  if (loadingPopups.size == 0) {
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webRequest.onBeforeRequest.removeListener(onPopupURLChanged);
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onBeforeNavigate.removeListener(onPopupURLChanged);
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onCompleted.removeListener(onCompleted);
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.tabs.onRemoved.removeListener(onTabRemoved);
  }
}

function checkPotentialPopup(sourceTabId, popupTabId, url, frame) {
  let specificOnly = (frame.allowlisted & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.GENERICBLOCK) != 0;
  let filter = _core_js__WEBPACK_IMPORTED_MODULE_3__.filterEngine.defaultMatcher.match(
    url || _frame_state_js__WEBPACK_IMPORTED_MODULE_5__.BLANK_PAGE_URL, adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.POPUP,
    frame.hostname, frame.sitekey, specificOnly
  );

  if (filter) {
    (0,_diagnostics_js__WEBPACK_IMPORTED_MODULE_4__.logItem)({tabId: sourceTabId, frameId: 0, url}, filter,
            {docDomain: frame.hostname, specificOnly, method: "popup"});

    if (filter instanceof adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.BlockingFilter)
      webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.tabs.remove(popupTabId).catch(() => {});

    forgetPopup(popupTabId);
  }
}

function onPopupURLChanged({frameId, tabId, url}) {
  if (!(0,_frame_state_js__WEBPACK_IMPORTED_MODULE_5__.isTopLevelFrameId)(frameId))
    return;

  let frame = loadingPopups.get(tabId);
  if (frame)
    checkPotentialPopup(frame.tabId, tabId, url, frame);
}

function onCompleted({frameId, url, tabId}) {
  if ((0,_frame_state_js__WEBPACK_IMPORTED_MODULE_5__.isTopLevelFrameId)(frameId) && url != _frame_state_js__WEBPACK_IMPORTED_MODULE_5__.BLANK_PAGE_URL)
    forgetPopup(tabId);
}

function onTabRemoved({tabId}) {
  forgetPopup(tabId);
}

function onPopup({tabId, url, sourceTabId, sourceFrameId}) {
  let frame = (0,_frame_state_js__WEBPACK_IMPORTED_MODULE_5__.getFrameInfo)(sourceTabId, sourceFrameId);

  if (frame.allowlisted & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.DOCUMENT)
    return;

  if (loadingPopups.size == 0) {
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webRequest.onBeforeRequest.addListener(
      onPopupURLChanged,
      {
        urls: ["http://*/*", "https://*/*"],
        types: ["main_frame"]
      }
    );
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onBeforeNavigate.addListener(onPopupURLChanged);
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onCompleted.addListener(onCompleted);
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.tabs.onRemoved.addListener(onTabRemoved);
  }

  loadingPopups.set(tabId, frame);
  checkPotentialPopup(sourceTabId, tabId, url, frame);
}

function onTabCreated({id, url, openerTabId}) {
  if (openerTabId)
    onPopup({tabId: id, url, sourceTabId: openerTabId, sourceFrameId: 0});
}

/**
 * Starts blocking popups. Must only be called after filter engine and
 * frame state are initialized.
 */
function start() {
  webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onCreatedNavigationTarget.addListener(onPopup);

  // On Firefox, clicking on a <a target="_blank" rel="noopener"> link doesn't
  // emit the webNavigation.onCreatedNavigationTarget event (and Firefox >=79,
  // implies "noopener" by default). But on Chrome, opening a new empty tab
  // emits the tabs.onCreated event with openerTabId set. So this would
  // cause new tabs created by the user to be considered popups too, on Chrome.
  if (typeof netscape != "undefined")
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.tabs.onCreated.addListener(onTabCreated);
}


/***/ }),

/***/ "./sdk/api/popup-blocker-service-worker.js":
/*!*************************************************!*\
  !*** ./sdk/api/popup-blocker-service-worker.js ***!
  \*************************************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_734933__) => {

"use strict";
__nested_webpack_require_734933__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_734933__.d(__webpack_exports__, {
/* harmony export */   "start": () => (/* binding */ start)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_734933__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_734933__(/*! adblockpluscore/lib/filterClasses.js */ "./node_modules/adblockpluscore/lib/filterClasses.js");
/* harmony import */ var adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_734933__(/*! adblockpluscore/lib/contentTypes.js */ "./node_modules/adblockpluscore/lib/contentTypes.js");
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_734933__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var _initializer_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_734933__(/*! ./initializer.js */ "./sdk/api/initializer.js");
/* harmony import */ var _diagnostics_js__WEBPACK_IMPORTED_MODULE_5__ = __nested_webpack_require_734933__(/*! ./diagnostics.js */ "./sdk/api/diagnostics.js");
/* harmony import */ var _frame_state_js__WEBPACK_IMPORTED_MODULE_6__ = __nested_webpack_require_734933__(/*! ./frame-state.js */ "./sdk/api/frame-state.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */











const SESSION_STORAGE_KEY = "ewe:popupBlocker:loadingPopups";

class PotentialPopupMap {
  constructor() {
    this.openerPromiseMap = {};
    this.loaded = (async() => {
      let result = await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.session.get([SESSION_STORAGE_KEY]);
      this.openerMap = result[SESSION_STORAGE_KEY] || {};
    })();
  }

  async saveMap() {
    await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.session.set({
      [SESSION_STORAGE_KEY]: this.openerMap
    });
  }

  set(tabId, openerPromise) {
    if (this.openerPromiseMap[tabId] || this.openerMap[tabId])
      return;

    this.openerPromiseMap[tabId] = openerPromise;
    openerPromise.then(async opener => {
      await this.loaded;

      delete this.openerPromiseMap[tabId];
      if (opener) {
        this.openerMap[tabId] = opener;
        await this.saveMap();
      }
    });
  }

  async get(tabId) {
    let openerPromise = this.openerPromiseMap[tabId];
    if (openerPromise)
      return await openerPromise;

    await this.loaded;
    let opener = this.openerMap[tabId];
    return opener;
  }

  async remove(tabId) {
    if (this.openerPromiseMap[tabId])
      delete this.openerPromiseMap[tabId];

    if (this.openerMap[tabId]) {
      delete this.openerMap[tabId];
      await this.saveMap();
    }
  }
}

let potentialPopups;

async function checkPotentialPopup(popupTabId, url, opener) {
  await _initializer_js__WEBPACK_IMPORTED_MODULE_4__.default.start();
  let {docDomain, sitekey, specificOnly} = opener;

  let filter = _core_js__WEBPACK_IMPORTED_MODULE_3__.filterEngine.defaultMatcher.match(
    url || _frame_state_js__WEBPACK_IMPORTED_MODULE_6__.BLANK_PAGE_URL, adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.POPUP, docDomain, sitekey, specificOnly
  );

  if (filter) {
    (0,_diagnostics_js__WEBPACK_IMPORTED_MODULE_5__.logItem)({tabId: opener.tabId, frameId: 0, url}, filter,
            {docDomain, specificOnly, method: "popup"});

    if (filter instanceof adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.BlockingFilter)
      webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.tabs.remove(popupTabId).catch(() => {});

    await potentialPopups.remove(popupTabId);
  }
}

async function onPopupURLChanged({frameId, tabId, url}) {
  if (!(0,_frame_state_js__WEBPACK_IMPORTED_MODULE_6__.isTopLevelFrameId)(frameId))
    return;

  let opener = await potentialPopups.get(tabId);
  if (opener)
    await checkPotentialPopup(tabId, url, opener);
}

async function onCompleted({frameId, tabId, url}) {
  if (!(0,_frame_state_js__WEBPACK_IMPORTED_MODULE_6__.isTopLevelFrameId)(frameId) || url == _frame_state_js__WEBPACK_IMPORTED_MODULE_6__.BLANK_PAGE_URL)
    return;

  let opener = await potentialPopups.get(tabId);
  if (opener) {
    await checkPotentialPopup(tabId, url, opener);
    await potentialPopups.remove(tabId);
  }
}

async function onTabRemoved({tabId}) {
  await potentialPopups.remove(tabId);
}

async function onPopup({tabId, url, sourceTabId, sourceFrameId}) {
  let openerPromise = (async() => {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_4__.default.start();
    let frame = (0,_frame_state_js__WEBPACK_IMPORTED_MODULE_6__.getFrameInfo)(sourceTabId, sourceFrameId);

    if (frame.allowlisted & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.DOCUMENT)
      return;

    let opener = {
      tabId: sourceTabId,
      specificOnly: frame.allowlisted & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.GENERICBLOCK,
      docDomain: frame.hostname,
      sitekey: frame.sitekey
    };
    return opener;
  })();

  potentialPopups.set(tabId, openerPromise);

  let opener = await openerPromise;
  if (opener)
    await checkPotentialPopup(tabId, url, opener);
}

/**
 * Starts blocking popups. Must be called in the first turn of the
 * event loop.
 */
function start() {
  potentialPopups = new PotentialPopupMap();

  webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onCreatedNavigationTarget.addListener(onPopup);
  webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webRequest.onBeforeRequest.addListener(
    onPopupURLChanged,
    {
      urls: ["http://*/*", "https://*/*"],
      types: ["main_frame"]
    }
  );
  webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onBeforeNavigate.addListener(onPopupURLChanged);
  webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onCommitted.addListener(onPopupURLChanged);
  webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onCompleted.addListener(onCompleted);
  webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.tabs.onRemoved.addListener(onTabRemoved);
}


/***/ }),

/***/ "./sdk/api/prefs.js":
/*!**************************!*\
  !*** ./sdk/api/prefs.js ***!
  \**************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_741982__) => {

"use strict";
__nested_webpack_require_741982__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_741982__.d(__webpack_exports__, {
/* harmony export */   "MIGRATED_TO_MV2": () => (/* binding */ MIGRATED_TO_MV2),
/* harmony export */   "MIGRATED_TO_MV3": () => (/* binding */ MIGRATED_TO_MV3),
/* harmony export */   "defaults": () => (/* binding */ defaults),
/* harmony export */   "Prefs": () => (/* binding */ Prefs),
/* harmony export */   "awaitSavingComplete": () => (/* binding */ awaitSavingComplete),
/* harmony export */   "migratePrefs": () => (/* binding */ migratePrefs),
/* harmony export */   "init": () => (/* binding */ init)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_741982__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var adblockpluscore_lib_events_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_741982__(/*! adblockpluscore/lib/events.js */ "./node_modules/adblockpluscore/lib/events.js");
/* harmony import */ var _io_idb_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_741982__(/*! ./io-idb.js */ "./sdk/api/io-idb.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */





const MIGRATED_TO_MV2 = 0;
const MIGRATED_TO_MV3 = 1;

const defaults = Object.create({
  analytics: {trustedHosts: ["adblockplus.org",
                             "notification.adblockplus.org",
                             "easylist-downloads.adblockplus.org"]},
  dynamic_filters: {},
  notificationdata: {},
  notifications_ignoredcategories: [],
  notificationurl: "https://notification.adblockplus.org/notification.json",
  patternsbackupinterval: 24,
  patternsbackups: 0,
  savestats: false,
  show_statsinpopup: true,
  subscriptions_autoupdate: true,
  subscriptions_fallbackerrors: 5,
  subscriptions_fallbackurl: "https://adblockplus.org/getSubscription?version=%VERSION%&url=%SUBSCRIPTION%&downloadURL=%URL%&error=%ERROR%&responseStatus=%RESPONSESTATUS%",
  subscriptions_initial_delay: 1000, // 1 s
  migration_errors: [],
  migration_state: MIGRATED_TO_MV2
});

let Prefs = {
  on(preference, callback) {
    eventEmitter.on(preference, callback);
  },
  off(preference, callback) {
    eventEmitter.off(preference, callback);
  }
};

const KEY_PREFIX = "abp:pref:";

let eventEmitter = new adblockpluscore_lib_events_js__WEBPACK_IMPORTED_MODULE_1__.EventEmitter();
let overrides = new Map();
let initializationPromise;

function keyToPref(key) {
  return key.startsWith(KEY_PREFIX) ? key.substr(KEY_PREFIX.length) : null;
}

function prefToKey(pref) {
  return `${KEY_PREFIX}${pref}`;
}

let activeSaveActions = new Set();

function trackSaving(savePromise) {
  activeSaveActions.add(savePromise);
  savePromise.finally(() => activeSaveActions.delete(savePromise));
  return savePromise;
}

async function awaitSavingComplete() {
  if (Promise.allSettled) {
    await Promise.allSettled(activeSaveActions);
    return;
  }

  // Promise.allSettled isn't supported in oldest Firefox.
  // It was added in Firefox 71.
  for (let saveAction of activeSaveActions) {
    try {
      await saveAction;
    }
    catch (e) {
    }
  }
}

function addPreference(preference) {
  Object.defineProperty(Prefs, preference, {
    get() {
      return (overrides.has(preference) ?
        overrides.get(preference) :
        defaults[preference]);
    },
    set(value) {
      let key = prefToKey(preference);
      if (value === defaults[preference]) {
        overrides.delete(preference);
        trackSaving(webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.local.remove(key));
        return;
      }

      overrides.set(preference, value);
      trackSaving(webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.local.set({[key]: value}));
    },
    enumerable: true
  });
}

async function migratePrefs(db) {
  return new Promise((resolve, reject) => {
    let tx = db.transaction(["prefs"], "readwrite");
    tx.oncomplete = () => resolve();
    tx.onerror = tx.onabort = event => reject(event.target.error);

    let prefsStore;
    try {
      prefsStore = tx.objectStore("prefs");
    }
    catch (e) {
      // no "prefs" object store
      return;
    }
    prefsStore.getAll().onsuccess = event => {
      for (let {name, value} of event.target.result)
        savePreference(name, value);
      prefsStore.clear();
    };
  });
}

function savePreference(name, value) {
  let key = prefToKey(name);
  overrides.set(name, value);
  trackSaving(webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.local.set({[key]: value}));
}

function onChanged(changes, areaName) {
  if (areaName != "local")
    return;

  for (let key in changes) {
    let pref = keyToPref(key);
    if (pref && defaults[pref]) {
      let change = changes[key];
      if ("newValue" in change && change.newValue != defaults[pref])
        overrides.set(pref, change.newValue);
      else
        overrides.delete(pref);

      eventEmitter.emit(pref);
    }
  }
}

async function loadPreferences() {
  let prefs = Object.keys(Object.getPrototypeOf(defaults));
  prefs.forEach(addPreference);

  let items = await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.local.get(prefs.map(prefToKey));
  for (let key in items)
    overrides.set(keyToPref(key), items[key]);
}

async function init() {
  if (!initializationPromise) {
    initializationPromise = (async() => {
      try {
        let db = (0,_io_idb_js__WEBPACK_IMPORTED_MODULE_2__.getDatabase)();
        await migratePrefs(db);
      }
      catch (e) {
        // db might be unavailable
      }

      await loadPreferences();
      webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.storage.onChanged.addListener(onChanged);
    })();
  }

  return initializationPromise;
}


/***/ }),

/***/ "./sdk/api/reporting.js":
/*!******************************!*\
  !*** ./sdk/api/reporting.js ***!
  \******************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_748644__) => {

"use strict";
__nested_webpack_require_748644__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_748644__.d(__webpack_exports__, {
/* harmony export */   "default": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var adblockpluscore_lib_analytics_js__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_748644__(/*! adblockpluscore/lib/analytics.js */ "./node_modules/adblockpluscore/lib/analytics.js");
/* harmony import */ var adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_748644__(/*! adblockpluscore/lib/contentTypes.js */ "./node_modules/adblockpluscore/lib/contentTypes.js");
/* harmony import */ var _diagnostics_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_748644__(/*! ./diagnostics.js */ "./sdk/api/diagnostics.js");
/* harmony import */ var _request_filter_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_748644__(/*! ./request-filter.js */ "./sdk/api/request-filter.js");
/* harmony import */ var _subscribe_links_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_748644__(/*! ./subscribe-links.js */ "./sdk/api/subscribe-links.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */








let contentTypesMap = new Map();

for (let item of _request_filter_js__WEBPACK_IMPORTED_MODULE_3__.resourceTypes) {
  let contentTypeObject = Object.keys(adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_1__.contentTypes).find(key =>
    adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_1__.contentTypes[key] === item[1]
  );

  contentTypesMap.set(item[0].toLowerCase(), contentTypeObject.toLowerCase());
}

/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({
  /**
   * Returns the version of the first ever downloaded resource.
   * @return {string}
   * @see {@link https://gitlab.com/eyeo/adblockplus/abc/adblockpluscore/-/jobs/artifacts/0.6.0/file/build/docs/module-analytics-Analytics.html?job=docs#getFirstVersion|Adblock Plus core analytics documentation}
   * @external
   */
  getFirstVersion: adblockpluscore_lib_analytics_js__WEBPACK_IMPORTED_MODULE_0__.analytics.getFirstVersion,

  /**
  * @typedef {Object} FilterMatchInfo
  * @property {string|null} docDomain The hostname of the document that caused
  *   the request. This will be null for "main_frame" requests since those
  *   create the top-level document in the first place.
  * @property {?string} rewrittenUrl The name of the internal resource to which
  *   to rewrite the URL.
  * @property {?boolean} specificOnly Whether selectors from generic filters
  *   should be included.
  * @property {string} method The method used to match this filter. This can be
  *   the string "request", "header", "csp", "popup", "elemhide", "snippet",
  *   "allowing", or "unmatched".
  * @property {?string} allowingReason When the type in request details is
  *   undefined, this contains the reason why the request/frame got
  *   allowlisted. That is either "document", "elemhide", "genericblock",
  *   "generichide", or "extensionInitiated". "extensionInitiated" refers to any
  *   web requests initiated by a browser extension rather than a web page
  *   (those requests are not blockable).
  */

  /**
   * Emitted when any blockable item is matched.
   *
   * This includes both filters being applied on a document level and web
   * requests. Multiple events may be emitted for a document, one for each
   * filter being applied to the document. There will generally only be one
   * event emitted for each web request. The exception to this is CSP filters,
   * where multiple CSP filters may be applied to a request at the same time,
   * and an event will be emitted for each filter applied.
   * @event
   * @param {object|{frameId: number, tabId: number, url: string}} request
   *   Either
   *   the {@link https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/webRequest/onBeforeRequest#details|onBeforeRequest details}
   *   object or the {@link https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/webRequest/onHeadersReceived#details|onHeadersReceived details}
   *   object from the web extensions API, or an object with the properties
   *   `frameId`, `tabId` and `url`.
   * @param {?Filter} filter The filter that matched, if any.
   * @param {FilterMatchInfo} matchInfo Extra information that might be
   *                                    relevant depending on the context.
   * @type {BlockableEventDispatcher<{request: object,
   *                                   filter: Filter,
   *                                   matchInfo: FilterMatchInfo}>}
   */
  onBlockableItem: new _diagnostics_js__WEBPACK_IMPORTED_MODULE_2__.BlockableEventDispatcher(),

  /**
   * Returns a mapping between resourceTypes and contentTypes.
   * @return {Map<string, string>}
   */
  contentTypesMap,

  /**
   * Emitted when a subscribe link is clicked on a web page.
   *
   * A subscribe link has a URL pointing to `https://subscribe.adblockplus.org/`
   * or starting with `abp:subscribe` (deprecated), followed by a query string
   * with a `location` parameter, and optionally a `title` parameter. Subscribe
   * links can only be used on certain trusted domains (including `localhost`).
   * @example
   * <a href="https://subscribe.adblockplus.org?location=http%3A%2F%2Flocalhost%2Flist.txt&title=Example">Example</a>
   * <a href="abp:subscribe?location=location=http%3A%2F%2Flocalhost%2Flist.txt&title=Example">Example (deprecated)</a>
   * @event
   * @param {string} url The subscription URL from the subscribe link
   *                     `location`'s parameter.
   * @param {string} title The subscription title from the subscribe link
   *                       `title`'s parameter.
   * @type {EventDispatcher<{url: string, title: string}>}
   */
  onSubscribeLinkClicked: _subscribe_links_js__WEBPACK_IMPORTED_MODULE_4__.onSubscribeLinkClicked
});


/***/ }),

/***/ "./sdk/api/request-filter.js":
/*!***********************************!*\
  !*** ./sdk/api/request-filter.js ***!
  \***********************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_755406__) => {

"use strict";
__nested_webpack_require_755406__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_755406__.d(__webpack_exports__, {
/* harmony export */   "resourceTypes": () => (/* binding */ resourceTypes),
/* harmony export */   "start": () => (/* binding */ start)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_755406__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_755406__(/*! adblockpluscore/lib/filterClasses.js */ "./node_modules/adblockpluscore/lib/filterClasses.js");
/* harmony import */ var adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_755406__(/*! adblockpluscore/lib/contentTypes.js */ "./node_modules/adblockpluscore/lib/contentTypes.js");
/* harmony import */ var adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_755406__(/*! adblockpluscore/lib/filterNotifier.js */ "./node_modules/adblockpluscore/lib/filterNotifier.js");
/* harmony import */ var adblockpluscore_lib_url_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_755406__(/*! adblockpluscore/lib/url.js */ "./node_modules/adblockpluscore/lib/url.js");
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_5__ = __nested_webpack_require_755406__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var _frame_state_js__WEBPACK_IMPORTED_MODULE_6__ = __nested_webpack_require_755406__(/*! ./frame-state.js */ "./sdk/api/frame-state.js");
/* harmony import */ var _errors_js__WEBPACK_IMPORTED_MODULE_7__ = __nested_webpack_require_755406__(/*! ../errors.js */ "./sdk/errors.js");
/* harmony import */ var _diagnostics_js__WEBPACK_IMPORTED_MODULE_8__ = __nested_webpack_require_755406__(/*! ./diagnostics.js */ "./sdk/api/diagnostics.js");
/* harmony import */ var _sitekey_js__WEBPACK_IMPORTED_MODULE_9__ = __nested_webpack_require_755406__(/*! ./sitekey.js */ "./sdk/api/sitekey.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */














const EXTENSION_PROTOCOL = new URL(webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.runtime.getURL("")).protocol;

let resourceTypes = new Map();
for (let type in adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes)
  resourceTypes.set(type.toLowerCase(), adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes[type]);
resourceTypes.set("sub_frame", adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.SUBDOCUMENT);
resourceTypes.set("beacon", adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.PING);
resourceTypes.set("imageset", adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.IMAGE);
resourceTypes.set("object_subrequest", adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.OBJECT);
resourceTypes.set("main_frame", adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.DOCUMENT);

let typeSelectors = new Map([
  [adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.IMAGE, "img,input"],
  [adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.MEDIA, "audio,video"],
  [adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.SUBDOCUMENT, "frame,iframe,object,embed"],
  [adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.OBJECT, "object,embed"]
]);

let pendingAllowlistedRequests = new Set();
let pendingCspRequests = new Set();

class BaseFilter {
  register() {
    if (!this.listener) {
      this.listener = this.filter.bind(this);
      this.event.addListener(this.listener, ...this.eventArgs);
    }
  }

  unregister() {
    if (this.listener) {
      this.event.removeListener(this.listener);
      this.listener = null;
    }
  }

  getFrameId(details) {
    // sub_frame requests are loading the iframe document itself, so
    // from our point of view the initiating frame is actually the
    // parent of the iframe.
    return details.type == "sub_frame" ? details.parentFrameId :
                                         details.frameId;
  }

  getParentFrameId(details) {
    if (details.type == "sub_frame") {
      // frameAncestors is exactly what we need, but it's only
      // available in Firefox so sometimes we just don't have what we
      // need :(
      if (!details.frameAncestors)
        return null;

      return details.frameAncestors.length > 1 ?
        details.frameAncestors[1].frameId : -1;
    }
    return details.parentFrameId;
  }

  getDocDomain(type, hostname) {
    return type == "main_frame" ? null : hostname;
  }

  getInitiator(details) {
    // Chrome calls it initiator, Firefox calls it documentUrl
    return details.initiator || details.documentUrl;
  }

  getDocumentUrl(details) {
    return details.documentUrl || details.initiator;
  }

  getFrameInfo(details) {
    let tabId = details.tabId;
    let frameId = this.getFrameId(details);
    let parentFrameId = this.getParentFrameId(details);
    let initiator = this.getInitiator(details);
    let documentUrl = this.getDocumentUrl(details);

    return (0,_frame_state_js__WEBPACK_IMPORTED_MODULE_6__.getFrameInfo)(tabId, frameId, {
      initiator,
      parentFrameId,
      documentUrl
    });
  }

  getContentType(details) {
    let contentType = resourceTypes.get(details.type) || adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.OTHER;
    if (contentType == adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.DOCUMENT)
      return adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.OTHER;
    return contentType;
  }

  collapse(details) {
    let selector = typeSelectors.get(this.getContentType(details));
    let frameId = this.getFrameId(details);

    let sendCollapseMessage = () => {
      return webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.tabs.sendMessage(
        details.tabId,
        {type: "ewe:collapse", selector, url: details.url}, {frameId}
      );
    };

    if (selector && frameId != -1) {
      // Retrying to fix a connection error on Chromium 90
      sendCollapseMessage()
        .catch(() => (0,_errors_js__WEBPACK_IMPORTED_MODULE_7__.ignoreNoConnectionError)(sendCollapseMessage()));
    }
  }

  block(details, filter, matchInfo) {
    let value = (() => {
      if (typeof filter.rewrite == "string") {
        let rewrittenUrl = filter.rewriteUrl(details.url);
        // If no rewrite happened (error, different origin), we'll
        // return undefined in order to avoid an "infinite" loop.
        if (rewrittenUrl != details.url) {
          matchInfo.rewrittenUrl = rewrittenUrl;
          return {redirectUrl: rewrittenUrl};
        }
      }
      else {
        this.collapse(details);
        return {cancel: true};
      }
    })();
    (0,_diagnostics_js__WEBPACK_IMPORTED_MODULE_8__.logItem)(details, filter, matchInfo);
    return value;
  }

  allow(details, filter, matchInfo) {
    pendingAllowlistedRequests.add(details.requestId);
    (0,_diagnostics_js__WEBPACK_IMPORTED_MODULE_8__.logItem)(details, filter, matchInfo);
  }

  match(details, frame, specificOnly, contentType, docDomain) {
    // This does nothing in BaseFilter, but should be overridden in
    // any child class that uses the default implementation of
    // BaseFilter.filter.
  }

  filter(details) {
    if (pendingAllowlistedRequests.has(details.requestId))
      return;

    let initiator = this.getInitiator(details);
    if (initiator && initiator.startsWith(EXTENSION_PROTOCOL)) {
      // These are requests sent by an extension, so if we block these
      // we could block our own ability to update subscriptions etc.
      return this.allow(details, null, {
        method: "allowing", allowingReason: "extensionInitiated"
      });
    }

    let frame = this.getFrameInfo(details);
    if (!frame)
      return;

    let specificOnly = (frame.allowlisted & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.GENERICBLOCK) != 0;
    let docDomain = this.getDocDomain(details.type, frame.hostname);
    if (frame.allowlisted & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.DOCUMENT) {
      return this.allow(details, frame.allowingDocumentFilter, {
        docDomain,
        method: "allowing",
        specificOnly
      });
    }

    let contentType = this.getContentType(details);

    return this.match(details, frame, specificOnly, contentType, docDomain);
  }
}

class RequestFilter extends BaseFilter {
  getDocumentUrl(details) {
    // We can be more idealistic here since we are doing this check
    // again later if we don't have enough info. documentUrl SHOULD
    // only ever be documentUrl (not initiator).
    return details.documentUrl;
  }

  getFrameInfo(details) {
    let frame = super.getFrameInfo(details);

    // Chromium-based browsers sometimes emit onBeforeRequest events
    // for resources on a frame before we get the onCommitted event
    // for the frame itself. This could mean that we're missing some
    // frame-level allowlisting filters, and can't actually make a
    // blocking decision yet. We only do this wait in the
    // onBeforeRequest filter because we can still do the blocking /
    // allowing when we have all the necessary info later in the
    // onHeadersReceived event.
    //
    // As an aside, if in the future we only needed to support Firefox
    // here, Firefox supports asynchronous blocking responses in the
    // webRequest API.
    if (frame) {
      // We might be missing sitekeys if we haven't received headers yet.
      if (!frame.headersReceived)
        return null;

      // A wrong URL likely means that we've navigated to a new page
      // and frame-state hasn't caught up yet.
      let {documentUrl, initiator} = details;
      if ((documentUrl && frame.url != documentUrl) ||
         (initiator && frame.hostname != (0,adblockpluscore_lib_url_js__WEBPACK_IMPORTED_MODULE_4__.parseURL)(initiator).hostname))
        return null;
    }

    return frame;
  }

  match(details, frame, specificOnly, contentType, docDomain) {
    let filter = _core_js__WEBPACK_IMPORTED_MODULE_5__.filterEngine.defaultMatcher.match(
      details.url, contentType, docDomain, frame.sitekey, specificOnly, true
    );
    if (filter) {
      let matchInfo = {docDomain, specificOnly, method: "request"};
      if (filter instanceof adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.BlockingFilter)
        return this.block(details, filter, matchInfo);
      return this.allow(details, filter, matchInfo);
    }
  }
}

RequestFilter.prototype.event = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webRequest.onBeforeRequest;
RequestFilter.prototype.eventArgs = [
  {
    types: Object.values(webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webRequest.ResourceType)
                 .filter(type => type != "main_frame"),
    urls: ["http://*/*", "https://*/*", "ws://*/*", "wss://*/*"]
  },
  ["blocking"]
];

class HeaderFilter extends BaseFilter {
  match(details, frame, specificOnly, contentType, docDomain) {
    let matcher = _core_js__WEBPACK_IMPORTED_MODULE_5__.filterEngine.defaultMatcher;

    // This is a repeat of the RequestFilter check, in case it was
    // skipped due to not having enough frame information at the time.
    let requestFilter = matcher.match(
      details.url, contentType, docDomain, frame.sitekey, specificOnly, true
    );
    if (requestFilter) {
      let requestMatchInfo = {docDomain, specificOnly, method: "request"};
      if (requestFilter instanceof adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.BlockingFilter)
        return this.block(details, requestFilter, requestMatchInfo);
      return this.allow(details, requestFilter, requestMatchInfo);
    }

    let matchInfo = {docDomain, specificOnly, method: "header"};
    let typeMask = adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.HEADER | contentType;
    let allowingFilter = matcher.match(details.url, typeMask, docDomain,
                                       frame.sitekey, specificOnly, true);

    if (allowingFilter && allowingFilter instanceof adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.AllowingFilter)
      return this.allow(details, allowingFilter, matchInfo);

    let matches = matcher.search(details.url, typeMask, docDomain,
                                 frame.sitekey, specificOnly, "blocking");

    let filter = matches.blocking.find(blockingFilter => {
      return blockingFilter.filterHeaders(details.responseHeaders);
    });

    if (filter)
      return this.block(details, filter, matchInfo);
  }
}

HeaderFilter.prototype.event = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webRequest.onHeadersReceived;
HeaderFilter.prototype.eventArgs = [
  {
    types: Object.values(webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webRequest.ResourceType)
                 .filter(type => type != "main_frame"),
    urls: ["http://*/*", "https://*/*"]
  },
  ["blocking", "responseHeaders"]
];

class CSPFilter extends BaseFilter {
  filter(details) {
    let {requestId, tabId, frameId, parentFrameId, responseHeaders, url, type} =
        details;

    if (pendingAllowlistedRequests.has(requestId))
      return;

    let initiator = this.getInitiator(details);
    if (initiator && initiator.startsWith(EXTENSION_PROTOCOL)) {
      // These are requests sent by an extension, so if we block these
      // we could block our own ability to update subscriptions etc.
      return this.allow(details, null, {
        method: "allowing", allowingReason: "extensionInitiated"
      });
    }

    let parentFrame = (0,_frame_state_js__WEBPACK_IMPORTED_MODULE_6__.getFrameInfo)(tabId, parentFrameId);
    let {hostname: parentHostname, sitekey: parentSitekey} = parentFrame || {};
    let matcher = _core_js__WEBPACK_IMPORTED_MODULE_5__.filterEngine.defaultMatcher;

    let urlInfo = (0,adblockpluscore_lib_url_js__WEBPACK_IMPORTED_MODULE_4__.parseURL)(url);
    let hostname = parentHostname || urlInfo.hostname;
    let sitekey = (0,_sitekey_js__WEBPACK_IMPORTED_MODULE_9__.setSitekeyFromHeaders)(
      tabId, frameId, url, responseHeaders
    ) || parentSitekey;

    let specificOnlyFilter = matcher.match(
      url, adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.GENERICBLOCK, hostname, sitekey
    );
    let documentFilter = matcher.match(
      url, adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.DOCUMENT, hostname, sitekey
    );
    let specificOnly = !!specificOnlyFilter;

    if (documentFilter) {
      return this.allow(details, documentFilter, {
        docDomain: this.getDocDomain(type, urlInfo.hostname),
        method: "allowing",
        specificOnly
      });
    }

    let docDomain =
      this.getDocDomain(type, parentHostname);
    let typeMask = adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.CSP | this.getContentType(details);
    let matchInfo = {docDomain: docDomain || urlInfo.hostname,
                     specificOnly, method: "csp"};

    let allowingFilter = matcher.match(url, typeMask, docDomain,
                                       sitekey, specificOnly, true);
    if (allowingFilter && allowingFilter instanceof adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_1__.AllowingFilter)
      return this.allow(details, allowingFilter, matchInfo);

    let matches = matcher.search(url, typeMask, docDomain,
                                 sitekey, specificOnly, "blocking");

    if (matches.blocking.length > 0) {
      pendingCspRequests.add(requestId);
      for (let filter of matches.blocking) {
        (0,_diagnostics_js__WEBPACK_IMPORTED_MODULE_8__.logItem)(details, filter, matchInfo);
        responseHeaders.push(
          {name: "Content-Security-Policy", value: filter.csp}
        );
      }
    }

    return {responseHeaders};
  }
}

CSPFilter.prototype.event = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webRequest.onHeadersReceived;
CSPFilter.prototype.eventArgs = [
  {
    types: ["main_frame", "sub_frame"],
    urls: ["http://*/*", "https://*/*"]
  },
  ["blocking", "responseHeaders"]
];

class RequestCompletionFilter extends BaseFilter {
  filter(details) {
    let {requestId, tabId, frameId, parentFrameId, url, type} = details;
    let wasAllowlisted = pendingAllowlistedRequests.delete(requestId);
    let wasCsp = pendingCspRequests.delete(requestId);
    if (wasAllowlisted || wasCsp)
      return;

    if (type == "main_frame" || type == "sub_frame") {
      // for these two types, it's unreliable if frame is there or not
      // yet. The request could be completed before or after the new
      // frame is committed.
      let parentFrame = (0,_frame_state_js__WEBPACK_IMPORTED_MODULE_6__.getFrameInfo)(tabId, parentFrameId);
      let {hostname: parentHostname, sitekey: parentSitekey} =
          parentFrame || {};

      let hostname = parentHostname || (0,adblockpluscore_lib_url_js__WEBPACK_IMPORTED_MODULE_4__.parseURL)(url).hostname;
      let sitekey = (0,_sitekey_js__WEBPACK_IMPORTED_MODULE_9__.getSitekey)(tabId, frameId, url) || parentSitekey;
      let matcher = _core_js__WEBPACK_IMPORTED_MODULE_5__.filterEngine.defaultMatcher;
      let specificOnlyFilter = matcher.match(
        url, adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.GENERICBLOCK, hostname, sitekey
      );
      let specificOnly = !!specificOnlyFilter;

      if ((0,_frame_state_js__WEBPACK_IMPORTED_MODULE_6__.isTopLevelFrameId)(frameId)) {
        let popupFilter = matcher.match(
          url, adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.POPUP, hostname, sitekey, specificOnly
        );
        if (popupFilter)
          return;
      }
      let matchInfo = {
        docDomain: this.getDocDomain(type, hostname),
        method: "unmatched",
        specificOnly
      };
      (0,_diagnostics_js__WEBPACK_IMPORTED_MODULE_8__.logItem)(details, null, matchInfo);
    }
    else {
      let frame = this.getFrameInfo(details);
      if (!frame)
        return;

      let specificOnly = (frame.allowlisted & adblockpluscore_lib_contentTypes_js__WEBPACK_IMPORTED_MODULE_2__.contentTypes.GENERICBLOCK) != 0;
      let matchInfo = {
        docDomain: this.getDocDomain(type, frame.hostname),
        method: "unmatched",
        specificOnly
      };
      (0,_diagnostics_js__WEBPACK_IMPORTED_MODULE_8__.logItem)(details, null, matchInfo);
    }
  }
}

RequestCompletionFilter.prototype.event = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webRequest.onCompleted;
RequestCompletionFilter.prototype.eventArgs = [
  {
    types: Object.values(webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webRequest.ResourceType),
    urls: ["http://*/*", "https://*/*", "ws://*/*", "wss://*/*"]
  }
];

class RequestErrorFilter extends BaseFilter {
  filter(details) {
    pendingAllowlistedRequests.delete(details.requestId);
    pendingCspRequests.delete(details.requestId);
  }
}

RequestErrorFilter.prototype.event = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webRequest.onErrorOccurred;
RequestErrorFilter.prototype.eventArgs = [
  {
    types: Object.values(webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webRequest.ResourceType),
    urls: ["http://*/*", "https://*/*", "ws://*/*", "wss://*/*"]
  }
];

let filters = [
  new RequestFilter(),
  new HeaderFilter(),
  new CSPFilter(),
  new RequestCompletionFilter(),
  new RequestErrorFilter()
];

function onBeforeNavigate() {
  webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onBeforeNavigate.removeListener(onBeforeNavigate);
  webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webRequest.handlerBehaviorChanged();
}

function onFilterChange() {
  webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.webNavigation.onBeforeNavigate.addListener(onBeforeNavigate);
}

const FILTER_EVENTS = ["subscription.added",
                       "subscription.removed",
                       "subscription.updated",
                       "subscription.disabled",
                       "filter.added",
                       "filter.removed",
                       "filterState.enabled"];

/**
 * Starts filtering requests. Must only be called after filter engine and
 * frame state are initialized.
 */
function start() {
  if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest)
    return;

  for (let filter of filters)
    filter.register();

  for (let event of FILTER_EVENTS) {
    if (!adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_3__.filterNotifier.listeners(event).includes(onFilterChange))
      adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_3__.filterNotifier.on(event, onFilterChange);
  }
}


/***/ }),

/***/ "./sdk/api/sitekey.js":
/*!****************************!*\
  !*** ./sdk/api/sitekey.js ***!
  \****************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_777290__) => {

"use strict";
__nested_webpack_require_777290__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_777290__.d(__webpack_exports__, {
/* harmony export */   "addListener": () => (/* binding */ addListener),
/* harmony export */   "getSitekey": () => (/* binding */ getSitekey),
/* harmony export */   "_getSitekeySignature": () => (/* binding */ _getSitekeySignature),
/* harmony export */   "_setSitekey": () => (/* binding */ _setSitekey),
/* harmony export */   "clearAllSitekeys": () => (/* binding */ clearAllSitekeys),
/* harmony export */   "clearTabSitekeys": () => (/* binding */ clearTabSitekeys),
/* harmony export */   "setSitekeyFromHeaders": () => (/* binding */ setSitekeyFromHeaders),
/* harmony export */   "merge": () => (/* binding */ merge),
/* harmony export */   "_loadSitekeys": () => (/* binding */ _loadSitekeys),
/* harmony export */   "_doSaveSitekeys": () => (/* binding */ _doSaveSitekeys),
/* harmony export */   "_saveSitekeys": () => (/* binding */ _saveSitekeys),
/* harmony export */   "_awaitSavingComplete": () => (/* binding */ _awaitSavingComplete),
/* harmony export */   "start": () => (/* binding */ start)
/* harmony export */ });
/* harmony import */ var adblockpluscore_lib_rsa_js__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_777290__(/*! adblockpluscore/lib/rsa.js */ "./node_modules/adblockpluscore/lib/rsa.js");
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_777290__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var _browser_features_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_777290__(/*! ./browser-features.js */ "./sdk/api/browser-features.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */





/**
 * All known sitekeys, that can be looked up by
 * `tabId`, and then by `frameId`, and then by `url`
 *  (`[tabId, [frameId, [url, {sitekey, signature}]]]]`).
 *
 * @type {Object}
 */
let sitekeys = {};
let startupPromise;
let listeners = [];

function notifySitekey(tabId, frameId, url, sitekey) {
  for (let listener of listeners)
    listener(tabId, frameId, url, sitekey);
}

function notifyAllSitekeys() {
  for (let [tabId, framesMap] of Object.entries(sitekeys)) {
    for (let [frameId, sitekeysMap] of Object.entries(framesMap)) {
      for (let [url, sitekeyInfo] of Object.entries(sitekeysMap))
        notifySitekey(tabId, frameId, url, sitekeyInfo.sitekey);
    }
  }
}

function onHeadersReceived({tabId, frameId, url, responseHeaders}) {
  let sitekey = setSitekeyFromHeaders(tabId, frameId, url, responseHeaders);
  if (sitekey)
    notifySitekey(tabId, frameId, url, sitekey);
}

function addListener(listener) {
  listeners.push(listener);
}

/**
 * Gets the stored sitekey for a given frame. Sitekeys are retrieved
 * from the headers of main_frame and sub_frame requests (the html
 * documents in tabs and iframes).
 * @param {number} tabId Id of the tab the frame is on.
 * @param {number} frameId Id of the frame on the tab.
 * @param {string} url Url for the frame.
 * @return {string|null|undefined} The sitekey if we have it, null if
 *   we've processed headers for this frame but it didn't have a
 *   sitekey, undefined if we haven't seen any headers for this frame.
 */
function getSitekey(tabId, frameId, url) {
  let sitekeysForTab = sitekeys[tabId];
  if (!sitekeysForTab)
    return null;
  let sitekeysForFrame = sitekeysForTab[frameId];
  if (!sitekeysForFrame)
    return null;
  let sitekeyInfo = sitekeysForFrame[url];
  return sitekeyInfo ? sitekeyInfo.sitekey : null;
}

function _getSitekeySignature(tabId, frameId, url) {
  return sitekeys[tabId][frameId][url].signature;
}

function _setSitekey(tabId, frameId, url, sitekey, signature) {
  let sitekeysForTab = sitekeys[tabId];
  if (!sitekeysForTab) {
    sitekeysForTab = {};
    sitekeys[tabId] = sitekeysForTab;
  }

  let sitekeysForFrame = sitekeysForTab[frameId];
  if (!sitekeysForFrame) {
    sitekeysForFrame = {};
    sitekeysForTab[frameId] = sitekeysForFrame;
  }

  sitekeysForFrame[url] = {sitekey, signature};
}

function clearAllSitekeys(save = true) {
  sitekeys = {};
  if (save)
    _saveSitekeys();
}

function clearTabSitekeys(tabId) {
  delete sitekeys[tabId];
  _saveSitekeys();
}

/**
 * Use the headers from an onHeadersReceived event for an main_frame
 * and sub_frame request to update our sitekey map. This also
 * validates the sitekey before storing.
 *
 * If there is no sitekey, this inserts a null entry in the sitekey
 * map so you can differentiate between not having a sitekey because
 * there wasn't one in the headers and because the headers haven't
 * been received yet.
 * @param {number} tabId Id of the tab the frame is on.
 * @param {number} frameId Id of the frame on the tab.
 * @param {string} url Url for the frame.
 * @param {webRequest.HttpHeaders} headers the HTTP response headers
 *   to check for a sitekey. See {@link webRequest API
 *   https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/webRequest/HttpHeaders}.
 * @return {string|null} The sitekey if it was found and is
 *   valid. Null if there was no valid sitekey.
 */
function setSitekeyFromHeaders(tabId, frameId, url, headers) {
  let sitekeyHeader = getSitekeyHeader(headers);
  let newSitekey = sitekeyHeader ? sitekeyHeader.sitekey : null;

  // If this sitekey is the same as the one we already have, we can
  // just leave the existing one. No need to do signature verification
  // since we've already checked this sitekey on this site.
  let existingSitekeyInfo = getSitekey(tabId, frameId, url);
  if (existingSitekeyInfo &&
      existingSitekeyInfo.sitekey &&
      newSitekey == existingSitekeyInfo.sitekey)
    return existingSitekeyInfo.sitekey;

  if (newSitekey && verifySitekey(newSitekey, sitekeyHeader.signature, url)) {
    _setSitekey(tabId, frameId, url, newSitekey, sitekeyHeader.signature);
    _saveSitekeys();
    return newSitekey;
  }

  // Inserting null here indicates that we've received headers for a
  // URL and it didn't have sitekeys (as opposed to not receiving
  // filters yet).
  _setSitekey(tabId, frameId, url, null, null);
  _saveSitekeys();
  return null;
}

function getSitekeyHeader(headers) {
  for (let header of headers) {
    if (header.name.toLowerCase() == "x-adblock-key" && header.value) {
      let parts = header.value.split("_");
      if (parts.length < 2)
        return null;

      return {
        sitekey: parts[0].replace(/=/g, ""),
        signature: parts[1]
      };
    }
  }
  return null;
}

function verifySitekey(sitekey, signature, url) {
  let urlObj = new URL(url);
  let data = [
    urlObj.pathname + urlObj.search,
    urlObj.host,
    self.navigator.userAgent
  ].join("\0");
  return (0,adblockpluscore_lib_rsa_js__WEBPACK_IMPORTED_MODULE_0__.verifySignatureSync)(sitekey, signature, data);
}

const STORAGE_KEY = "ewe:sitekeys";

function verifySitekeys(_sitekeys) {
  for (let [tabId, framesMap] of Object.entries(_sitekeys)) {
    for (let [frameId, sitekeysMap] of Object.entries(framesMap)) {
      for (let [url, sitekeyInfo] of Object.entries(sitekeysMap)) {
        try {
          if (!verifySitekey(sitekeyInfo.sitekey, sitekeyInfo.signature, url))
            delete sitekeysMap[url];
        }
        catch (e) {
          delete sitekeysMap[url];
        }
      }
      if (Object.keys(sitekeysMap).length == 0)
        delete framesMap[frameId];
    }
    if (Object.keys(framesMap).length == 0)
      delete _sitekeys[tabId];
  }
}

function merge(obj1, obj2) {
  if (obj1 instanceof Array)
    return [...obj1, ...obj2];

  if (!(obj1 instanceof Object))
    return obj2;

  let resultObj = {};

  for (let [key, obj1Values] of Object.entries(obj1))
    resultObj[key] = obj1Values;

  for (let [key, obj2Values] of Object.entries(obj2)) {
    let map1Values = resultObj[key];
    resultObj[key] = map1Values ? merge(map1Values, obj2Values) : obj2Values;
  }

  return resultObj;
}

async function _loadSitekeys(verify = true) {
  let persistObj = await webextension_polyfill__WEBPACK_IMPORTED_MODULE_1__.storage.session.get(STORAGE_KEY);
  if (!persistObj || !persistObj[STORAGE_KEY])
    return;

  let savedSitekeys = persistObj[STORAGE_KEY];

  if (verify)
    verifySitekeys(savedSitekeys);

  // We might have `onHeadersReceived` triggered earlier than Filter Engine
  // loading is finished. Thus we might need to merge the saved and new
  // sitekey maps.
  sitekeys = merge(savedSitekeys, sitekeys);

  notifyAllSitekeys();
}

function _doSaveSitekeys() {
  let obj = {};
  obj[STORAGE_KEY] = sitekeys;
  trackSaving(webextension_polyfill__WEBPACK_IMPORTED_MODULE_1__.storage.session.set(obj));
}

function _saveSitekeys() {
  if (!(0,_browser_features_js__WEBPACK_IMPORTED_MODULE_2__.isRunningInServiceWorker)())
    return;

  _doSaveSitekeys();
}

let activeSaveActions = new Set();

function trackSaving(savePromise) {
  activeSaveActions.add(savePromise);
  savePromise.finally(() => activeSaveActions.delete(savePromise));
  return savePromise;
}

async function _awaitSavingComplete() {
  if (Promise.allSettled) {
    await Promise.allSettled(activeSaveActions);
    return;
  }

  // Promise.allSettled isn't supported in oldest Firefox.
  // It was added in Firefox 71.
  for (let saveAction of activeSaveActions) {
    try {
      await saveAction;
    }
    catch (e) {
    }
  }
}

async function start() {
  if (!startupPromise) {
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_1__.webRequest.onHeadersReceived.addListener(
      onHeadersReceived,
      {
        urls: ["http://*/*", "https://*/*"],
        types: ["main_frame", "sub_frame"]
      },
      ["responseHeaders"]
    );

    startupPromise = ((0,_browser_features_js__WEBPACK_IMPORTED_MODULE_2__.isRunningInServiceWorker)() ?
      _loadSitekeys() : Promise.resolve(null));
  }

  await startupPromise;
}


/***/ }),

/***/ "./sdk/api/subscribe-links.js":
/*!************************************!*\
  !*** ./sdk/api/subscribe-links.js ***!
  \************************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_788071__) => {

"use strict";
__nested_webpack_require_788071__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_788071__.d(__webpack_exports__, {
/* harmony export */   "subscribeLinksEnabled": () => (/* binding */ subscribeLinksEnabled),
/* harmony export */   "subscribeLinkClicked": () => (/* binding */ subscribeLinkClicked),
/* harmony export */   "onSubscribeLinkClicked": () => (/* binding */ onSubscribeLinkClicked)
/* harmony export */ });
/* harmony import */ var _types_js__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_788071__(/*! ./types.js */ "./sdk/api/types.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */



const ALLOWED_DOMAINS = new Set([
  "abpchina.org",
  "abpindo.blogspot.com",
  "abpvn.com",
  "adblock.ee",
  "adblock.gardar.net",
  "adblockplus.me",
  "adblockplus.org",
  "commentcamarche.net",
  "droit-finances.commentcamarche.com",
  "easylist.to",
  "eyeo.com",
  "fanboy.co.nz",
  "filterlists.com",
  "forums.lanik.us",
  "gitee.com",
  "gitee.io",
  "github.com",
  "github.io",
  "gitlab.com",
  "gitlab.io",
  "gurud.ee",
  "hugolescargot.com",
  "i-dont-care-about-cookies.eu",
  "journaldesfemmes.fr",
  "journaldunet.com",
  "linternaute.com",
  "spam404.com",
  "stanev.org",
  "void.gr",
  "xfiles.noads.it",
  "zoso.ro"
]);

let dispatchFunction;

function isDomainAllowed(domain) {
  if (domain.endsWith("."))
    domain = domain.substring(0, domain.length - 1);

  while (true) {
    if (ALLOWED_DOMAINS.has(domain))
      return true;
    let index = domain.indexOf(".");
    if (index == -1)
      return false;
    domain = domain.substr(index + 1);
  }
}

function subscribeLinksEnabled(url) {
  if (!dispatchFunction || !url)
    return false;

  let {protocol, hostname} = new URL(url);
  return hostname == "localhost" ||
         protocol == "https:" && isDomainAllowed(hostname);
}

function subscribeLinkClicked(url, title) {
  if (dispatchFunction)
    dispatchFunction({url, title});
}

let onSubscribeLinkClicked = new _types_js__WEBPACK_IMPORTED_MODULE_0__.EventDispatcher(
  dispatch => {
    dispatchFunction = dispatch;
  },
  () => {
    dispatchFunction = null;
  }
);


/***/ }),

/***/ "./sdk/api/subscriptions.js":
/*!**********************************!*\
  !*** ./sdk/api/subscriptions.js ***!
  \**********************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_791074__) => {

"use strict";
__nested_webpack_require_791074__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_791074__.d(__webpack_exports__, {
/* harmony export */   "getDefaultSubscriptions": () => (/* binding */ getDefaultSubscriptions),
/* harmony export */   "validate": () => (/* binding */ validate),
/* harmony export */   "updateFilterText": () => (/* binding */ updateFilterText),
/* harmony export */   "migrate": () => (/* binding */ migrate),
/* harmony export */   "ensureDNRRulesetsEnabled": () => (/* binding */ ensureDNRRulesetsEnabled),
/* harmony export */   "default": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_791074__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_791074__(/*! adblockpluscore/lib/subscriptionClasses.js */ "./node_modules/adblockpluscore/lib/subscriptionClasses.js");
/* harmony import */ var adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_791074__(/*! adblockpluscore/lib/filterNotifier.js */ "./node_modules/adblockpluscore/lib/filterNotifier.js");
/* harmony import */ var adblockpluscore_lib_recommendations_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_791074__(/*! adblockpluscore/lib/recommendations.js */ "./node_modules/adblockpluscore/lib/recommendations.js");
/* harmony import */ var adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_791074__(/*! adblockpluscore/lib/filterClasses.js */ "./node_modules/adblockpluscore/lib/filterClasses.js");
/* harmony import */ var adblockpluscore_lib_filters_lists_js__WEBPACK_IMPORTED_MODULE_5__ = __nested_webpack_require_791074__(/*! adblockpluscore/lib/filters/lists.js */ "./node_modules/adblockpluscore/lib/filters/lists.js");
/* harmony import */ var _info_js__WEBPACK_IMPORTED_MODULE_6__ = __nested_webpack_require_791074__(/*! ./info.js */ "./sdk/api/info.js");
/* harmony import */ var _initializer_js__WEBPACK_IMPORTED_MODULE_7__ = __nested_webpack_require_791074__(/*! ./initializer.js */ "./sdk/api/initializer.js");
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_8__ = __nested_webpack_require_791074__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var _types_js__WEBPACK_IMPORTED_MODULE_9__ = __nested_webpack_require_791074__(/*! ./types.js */ "./sdk/api/types.js");
/* harmony import */ var _filters_js__WEBPACK_IMPORTED_MODULE_10__ = __nested_webpack_require_791074__(/*! ./filters.js */ "./sdk/api/filters.js");
/* harmony import */ var _dnr_filters_js__WEBPACK_IMPORTED_MODULE_11__ = __nested_webpack_require_791074__(/*! ./dnr-filters.js */ "./sdk/api/dnr-filters.js");
/* harmony import */ var _io_js__WEBPACK_IMPORTED_MODULE_12__ = __nested_webpack_require_791074__(/*! ./io.js */ "./sdk/api/io.js");
/* harmony import */ var _prefs_js__WEBPACK_IMPORTED_MODULE_13__ = __nested_webpack_require_791074__(/*! ./prefs.js */ "./sdk/api/prefs.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */



















const ACCEPTABLE_ADS_ID = "0798B6A2-94A4-4ADF-89ED-BEC112FC4C7F";
const ACCEPTABLE_ADS_MV2_URL = "https://easylist-downloads.adblockplus.org/exceptionrules.txt";
const ACCEPTABLE_ADS_MV3_URL = "https://easylist-downloads.adblockplus.org/v3/full/exceptionrules.txt";

const ACCEPTABLE_ADS_PRIVACY_ID = "F12E0801-A00B-49DE-B1E3-52C9C4F90C8C";
const ACCEPTABLE_ADS_PRIVACY_MV2_URL = "https://easylist-downloads.adblockplus.org/exceptionrules-privacy-friendly.txt";
const ACCEPTABLE_ADS_PRIVACY_MV3_URL = "https://easylist-downloads.adblockplus.org/v3/full/exceptionrules-privacy-friendly.txt";

function convertSubscription(subscription) {
  let {id, disabled, downloadStatus, homepage,
       version, lastDownload, lastSuccess,
       softExpiration, expires, title, url,
       downloadable, downloadCount} = subscription;
  let {synchronizer} = _core_js__WEBPACK_IMPORTED_MODULE_8__.filterEngine.filterStorage;

  return {
    id, enabled: !disabled,
    downloading: synchronizer.isExecuting(url),
    downloadStatus, homepage, version, lastDownload, lastSuccess,
    softExpiration, expires, title, url, downloadable, downloadCount
  };
}

function convertRecommendation({id, languages, title, requires, type, url,
                                // eslint-disable-next-line camelcase
                                mv2URL}) {
  return {id, languages, title, requires, type, url, mv2URL};
}

function getSubscription(url) {
  let subscription = adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_1__.Subscription.fromURL(url);

  if (_core_js__WEBPACK_IMPORTED_MODULE_8__.filterEngine.filterStorage.hasSubscription(subscription) &&
      subscription instanceof adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_1__.RegularSubscription)
    return subscription;

  return null;
}

function makeListener(dispatch) {
  return subscription => {
    if (subscription instanceof adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_1__.RegularSubscription)
      dispatch(convertSubscription(subscription));
  };
}

function getDefaultSubscriptions(uiLanguage) {
  let hasCurrentLang = false;
  let hasDefaultLang = false;
  let hasAA = false;
  let hasAntiCV = false;

  if (!uiLanguage) {
    // https://bugs.chromium.org/p/chromium/issues/detail?id=1159438
    if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.i18n.getUILanguage)
      uiLanguage = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.i18n.getUILanguage();
    else
      uiLanguage = navigator.language;
  }

  let currentLang = uiLanguage.split("-")[0];
  let defaultLang = (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.runtime.getManifest()
                                    .default_locale || "en").split("_")[0];

  let adSubscriptions = [];
  let adSubscriptionsDefaultLang = [];
  let aaSubscriptions = [];
  let chosenSubscriptions = [];

  for (let subscription of (0,adblockpluscore_lib_recommendations_js__WEBPACK_IMPORTED_MODULE_3__.recommendations)()) {
    switch (subscription.type) {
      case "ads":
        if (subscription.languages.includes(currentLang)){
          hasCurrentLang = true;
          adSubscriptions.push(subscription);
        }

        if (subscription.languages.includes(defaultLang)) {
          hasDefaultLang = true;
          adSubscriptionsDefaultLang.push(subscription);
        }
        break;

      case "circumvention":
        chosenSubscriptions.push(subscription);
        hasAntiCV = true;
        break;

      case "allowing":
        aaSubscriptions.push(subscription);
        hasAA = true;
        break;
    }
  }

  if (adSubscriptions.length == 0)
    adSubscriptions = adSubscriptionsDefaultLang;

  // if we have the preferred AA in the list - use it only,
  // otherwise use all listed AA subscriptions
  let preferredAASubscription = aaSubscriptions.find(
    it => it.id == ACCEPTABLE_ADS_ID);
  if (preferredAASubscription)
    aaSubscriptions = [preferredAASubscription];
  chosenSubscriptions.unshift(...aaSubscriptions);

  chosenSubscriptions.unshift(...adSubscriptions);

  return {chosenSubscriptions, hasAA, hasAntiCV,
          hasCurrentLang, hasDefaultLang};
}

function shouldAddDefaultSubscriptions() {
  let {filterStorage} = _core_js__WEBPACK_IMPORTED_MODULE_8__.filterEngine;
  for (let subscription of filterStorage.subscriptions()) {
    if (subscription instanceof adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_1__.DownloadableSubscription &&
        subscription.url != ACCEPTABLE_ADS_MV2_URL &&
        subscription.type != "circumvention")
      return false;

    if (subscription instanceof adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_1__.SpecialSubscription &&
        subscription.filterCount > 0)
      return false;
  }

  return true;
}

async function enableRuleset(rulesetId) {
  if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest && rulesetExistsInManifest(rulesetId)) {
    await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest.updateEnabledRulesets({
      enableRulesetIds: [rulesetId]
    });
  }
}

async function disableRuleset(rulesetId) {
  if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest && rulesetExistsInManifest(rulesetId)) {
    await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest.updateEnabledRulesets({
      disableRulesetIds: [rulesetId]
    });
  }
}

async function getFilterText(subscription, path) {
  let subscriptionPath = `${path}/${subscription.id}`;
  let rawLines = (await (0,_io_js__WEBPACK_IMPORTED_MODULE_12__.readFileContent)(subscriptionPath));
  let {lines, error} = (0,adblockpluscore_lib_filters_lists_js__WEBPACK_IMPORTED_MODULE_5__.parseFilterList)(rawLines);
  if (error)
    throw new Error(error);
  if (!lines)
    throw new Error("invalid filter list");
  lines.shift();
  return lines;
}

async function subscriptionFileExists(subscription, path) {
  let subscriptionPath = `${path}/${subscription.id}`;
  const url = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.runtime.getURL(subscriptionPath);
  try {
    const fetchResult = await fetch(url, {method: "HEAD"});
    return fetchResult.ok;
  }
  catch (error) {
    return false;
  }
}

function rulesetExistsInManifest(rulesetId) {
  let manifest = webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.runtime.getManifest();

  return manifest.declarative_net_request &&
    manifest.declarative_net_request.rule_resources &&
    manifest.declarative_net_request.rule_resources.find(
      ruleset => ruleset.id == rulesetId
    );
}

async function validate(bundledSubscriptions,
                               bundledSubscriptionsPath) {
  let warnings = [];

  for (let subscription of bundledSubscriptions) {
    let fileExists = await subscriptionFileExists(subscription,
                                                  bundledSubscriptionsPath);
    if (!fileExists)
      warnings.push(`No subscription content file for ID=${subscription.id}`);

    if (!rulesetExistsInManifest(subscription.id))
      warnings.push(`No ruleset with ID=${subscription.id} declared in the manifest`);
  }

  return warnings;
}

async function remove(url) {
  await _initializer_js__WEBPACK_IMPORTED_MODULE_7__.default.start();

  let subscription = getSubscription(url);

  if (!subscription)
    throw new Error(`Subscription does not exist: ${url}`);

  _core_js__WEBPACK_IMPORTED_MODULE_8__.filterEngine.filterStorage.removeSubscription(subscription);

  await disableRuleset(subscription.id);
}

async function updateFilterText() {
  let removeUrls = [];

  for (let subscription of _core_js__WEBPACK_IMPORTED_MODULE_8__.filterEngine.filterStorage.subscriptions()) {
    if (subscription instanceof adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_1__.RegularSubscription) {
      let subscriptionInfo = _info_js__WEBPACK_IMPORTED_MODULE_6__.addonBundledSubscriptions.find(
        x => x.url == subscription.url);

      if (subscriptionInfo) {
        let filterText = await getFilterText(
          subscriptionInfo, _info_js__WEBPACK_IMPORTED_MODULE_6__.addonBundledSubscriptionsPath);
        subscription.setFilterText(filterText);
      }
      else {
        removeUrls.push(subscription.url);
      }
    }
  }

  for (let url of removeUrls)
    await remove(url);
}

async function getDownloadable() {
  await _initializer_js__WEBPACK_IMPORTED_MODULE_7__.default.start();

  let result = [];

  for (let subscription of _core_js__WEBPACK_IMPORTED_MODULE_8__.filterEngine.filterStorage.subscriptions()) {
    if (subscription instanceof adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_1__.RegularSubscription)
      result.push(convertSubscription(subscription));
  }

  return result;
}

async function add(url, properties = {}) {
  await _initializer_js__WEBPACK_IMPORTED_MODULE_7__.default.start();

  if (!adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_1__.Subscription.isValidURL(url))
    throw new Error(`Invalid subscription URL provided: ${url}`);

  let {filterStorage} = _core_js__WEBPACK_IMPORTED_MODULE_8__.filterEngine;

  let subscription = adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_1__.Subscription.fromURL(url);

  if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest) {
    let subscriptionInfo = _info_js__WEBPACK_IMPORTED_MODULE_6__.addonBundledSubscriptions.find(x => x.url == url);
    if (!subscriptionInfo)
      throw new Error(`Failed to find the subscription with URL=${url}`);

    if (!subscription.downloadable) {
      let filterText;
      try {
        filterText = await getFilterText(
          subscriptionInfo, _info_js__WEBPACK_IMPORTED_MODULE_6__.addonBundledSubscriptionsPath);
      }
      catch (e) {
        // We already warn if the file doesn't exist on startup, so
        // we can ignore an error loading the bundled file here.
      }

      if (filterText)
        subscription.setFilterText(filterText);
    }
  }
  await enableRuleset(subscription.id);

  if ("title" in properties)
    subscription.title = properties.title;
  if ("homepage" in properties)
    subscription.homepage = properties.homepage;
  if ("downloadCount" in properties)
    subscription.downloadCount = properties.downloadCount;
  if ("version" in properties)
    subscription.version = properties.version;
  if ("lastDownload" in properties)
    subscription.lastDownload = properties.lastDownload;

  filterStorage.addSubscription(subscription);

  if (!subscription.lastDownload)
    filterStorage.synchronizer.execute(subscription);
}

async function disable(url) {
  await _initializer_js__WEBPACK_IMPORTED_MODULE_7__.default.start();

  let subscription = getSubscription(url);

  if (!subscription)
    throw new Error(`Subscription does not exist: ${url}`);

  subscription.disabled = true;

  await disableRuleset(subscription.id);
}

function migrationNeeded() {
  if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.runtime.getManifest().manifest_version == 2)
    return false;

  for (let subscription of _core_js__WEBPACK_IMPORTED_MODULE_8__.filterEngine.filterStorage.subscriptions()) {
    // anti-cv subscriptions stay `DownloadableSubscriptions` even in MV3
    if (subscription.downloadable && subscription.type != "circumvention")
      return true;
  }

  return false;
}

function saveMigrationError(url, error) {
  _prefs_js__WEBPACK_IMPORTED_MODULE_13__.Prefs.migration_errors.push({url, error});
}

async function migrate() {
  if (!migrationNeeded())
    return;

  let downloadables = await getDownloadable();
  for (let downloadable of downloadables) {
    await remove(downloadable.url); // MV2 URL
    let subscriptionInfo = _info_js__WEBPACK_IMPORTED_MODULE_6__.addonBundledSubscriptions.find(
      it => it.mv2_url == downloadable.url);
    if (subscriptionInfo) {
      try {
        await add(subscriptionInfo.url, {
          downloadCount: downloadable.downloadCount,
          version: downloadable.version,
          lastDownload: downloadable.lastDownload
        });
        if (!downloadable.enabled)
          await disable(subscriptionInfo.url);
      }
      catch (e) {
        saveMigrationError(downloadable.url, e.message);
      }
    }
    else {
      saveMigrationError(
        downloadable.url,
        `Failed to find the subscription with URL=${downloadable.url}`);
    }
  }
}

async function ensureDNRRulesetsEnabled() {
  if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest) {
    let enabledItems = await webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest.getEnabledRulesets();

    for (let subscription of _core_js__WEBPACK_IMPORTED_MODULE_8__.filterEngine.filterStorage.subscriptions()) {
      if (!enabledItems.includes(subscription.id) && !subscription.disabled)
        enableRuleset(subscription.id);
    }
  }
}

/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({
  /**
   * The URL of the Acceptable Ads subscription.
   * @type {string}
   */
  get ACCEPTABLE_ADS_URL() {
    return webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest ?
      ACCEPTABLE_ADS_MV3_URL :
      ACCEPTABLE_ADS_MV2_URL;
  },

  /**
   * The UUID of the Acceptable Ads subscription.
   * @type {string}
   */
  ACCEPTABLE_ADS_ID,

  /**
   * The URL of the Acceptable Ads
   * without third-party tracking subscription.
   * @type {string}
   */
  get ACCEPTABLE_ADS_PRIVACY_URL() {
    return webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest ?
      ACCEPTABLE_ADS_PRIVACY_MV3_URL :
      ACCEPTABLE_ADS_PRIVACY_MV2_URL;
  },

  /**
   * The UUID of the Acceptable Ads without third-party tracking subscription.
   * @type {string}
   */
  ACCEPTABLE_ADS_PRIVACY_ID,

  /**
   * A resource that provides a list of filters that decide what to block.
   * @typedef {Object} Subscription
   * @property {boolean} downloadable Indicates whether this subscription is
   *                                  downloaded and updated over the network.
   *                                  If `false` the subscription is merely
   *                                  a container for user-defined filters.
   * @property {boolean} downloading Indicates whether the subscription is
   *                                 currently downloading.
   * @property {string|null} downloadStatus The {@link https://gitlab.com/eyeo/adblockplus/abc/adblockpluscore/-/jobs/artifacts/0.6.0/file/build/docs/module-subscriptionClasses.DownloadableSubscription.html?job=docs#downloadStatus|status}
   *                                        of the most recent download attempt.
   * @property {boolean} enabled Indicates whether this subscription will
   *                             be applied.
   * @property {number} expires
   * @property {?string} homepage Website of the project that manages
   *                              this filter list.
   * @property {number} lastDownload Epoch time when the subscription
   *                                 was last downloaded to your machine.
   * @property {number} lastSuccess Epoch time when this subscription was last
   *                                successfully downloaded.
   * @property {number} softExpiration
   * @property {string} title The display name of the subscription.
   *                          If not provided, falls back to the URL.
   * @property {string} url Where the subscription can be found in plain text.
   *                        Used a the identifier.
   * @property {string} version The version provided by the subscription's
   *                            metadata. Defaults to '0' if not provided.
   */

  /**
   * Creates a new subscription from a given URL. The subscription also gets
   * synchronised if it had not been previously downloaded.
   * @param {string} url The URL of the subscription to be added.
   * @param {object} [properties] An object containing properties to be
   *                              set on the new subscription.
   * @param {string} [properties.title] The display name of the subscription.
   *                                    If not provided, falls back to the URL.
   * @param {string} [properties.homepage] Website of the project that
   *                                       manages this filter list.
   * @return {Promise}
   * @throws {Error} Invalid subscription URL provided.
   */
  add,

  /**
   * Adds a list of default subscriptions based on the provided bundled
   * subscriptions from the EWE.start() call.
   * Subscriptions are selected based on relevant language, type of
   * circumvention, and type of allowing.
   * @param {string} [uiLanguage] The relevant language used for
   * determining which subscriptions to add. If omitted,
   * browser.i18n.getUILanguage will be used. If
   * browser.i18n.getUILanguage is unavailable, navigator.language is
   * used.
   * @throws {Error} No default language subscription
   * @throws {Error} No current language subscription
   * @throws {Error} No anti-circumvention subscription
   * @throws {Error} No allowing subscription
   * @see {@link #start|start()}
   * @return {Promise}
   */
  async addDefaults(uiLanguage) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_7__.default.start();

    let subscriptions = [];

    if (shouldAddDefaultSubscriptions()) {
      let defaultSubscriptions = getDefaultSubscriptions(uiLanguage);
      if (!defaultSubscriptions.hasDefaultLang)
        throw Error("No default language subscription");

      if (!defaultSubscriptions.hasCurrentLang)
        throw Error("No current language subscription");

      if (!defaultSubscriptions.hasAntiCV)
        throw Error("No anti-circumvention subscription");

      if (!defaultSubscriptions.hasAA)
        throw Error("No allowing subscription");

      subscriptions.push(...defaultSubscriptions.chosenSubscriptions);
    }

    for (let subscription of subscriptions) {
      await this.add(webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest ?
        subscription.url : subscription.mv2URL);
    }
  },

  /**
   * Returns an array of subscription objects for all subscriptions that are
   * downloaded and updated over the network.
   * @return {Promise<Array<Subscription>>}
   */
  getDownloadable,

  /**
   * Returns an array of subscription objects for a given filter.
   * @param {string} text The filter rule for which to look.
   * @return {Promise<Array<Subscription>>}
   */
  async getForFilter(text) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_7__.default.start();

    return text ? Array.from(_core_js__WEBPACK_IMPORTED_MODULE_8__.filterEngine.filterStorage.subscriptions(text),
                             convertSubscription) : [];
  },

  /**
   * Returns the filter list of a given subscription URL.
   * @param {string} url The URL of the subscription.
   * @return {Promise<Array<Filter>>} Filters from the subscription.
   */
  async getFilters(url) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_7__.default.start();

    let subscription = getSubscription(url);
    if (subscription) {
      return Array.from(subscription.filterText(),
                        text => (0,_filters_js__WEBPACK_IMPORTED_MODULE_10__.convertFilter)(adblockpluscore_lib_filterClasses_js__WEBPACK_IMPORTED_MODULE_4__.Filter.fromText(text)));
    }

    return [];
  },

  /**
   * Checks if a subscription has been added.
   * @param {string} url The URL of the subscription to be checked.
   * @return {Promise<boolean>} True if a subscription has been added.
   * @throws {TypeError} Invalid URL provided.
   */
  async has(url) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_7__.default.start();

    return getSubscription(new URL(url).href) != null;
  },

  /**
   * Enables a previously disabled subscription. Has no effect otherwise.
   * @param {string} url The URL of the subscription to be enabled.
   * @return {Promise}
   * @throws {Error} Subscription does not exist.
   */
  async enable(url) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_7__.default.start();

    let subscription = getSubscription(url);

    if (!subscription)
      throw new Error(`Subscription does not exist: ${url}`);

    subscription.disabled = false;

    await enableRuleset(subscription.id);
  },

  /**
   * Disables a subscription so that it doesn't have any
   * effect until it gets enabled again.
   * @param {string} url The URL of the subscription to be disabled.
   * @return {Promise}
   * @throws {Error} Subscription does not exist.
   */
  disable,

  /**
   * Removes the subscription for the given URL.
   * It will no longer have any effect.
   * @param {string} url The URL of the subscription to be removed.
   * @return {Promise}
   * @throws {Error} Subscription does not exist.
   */
  remove,

  /**
   * Forces a new version of a subscription with the
   * given URL to be downloaded immediately.
   * @param {string} [url] The URL of the subscription to be synchronized.
   *   If omitted, all subscriptions will be synchronized.
   * @return {Promise} Resolves when syncing has been successfully
   *   triggered. Syncing may not be completed when this promise
   *   resolves.
   * @throws {Error} Subscription does not exist.
   */
  async sync(url) {
    await _initializer_js__WEBPACK_IMPORTED_MODULE_7__.default.start();

    let subscriptions = [];
    let {filterStorage} = _core_js__WEBPACK_IMPORTED_MODULE_8__.filterEngine;

    if (url) {
      let subscription = getSubscription(url);

      if (!subscription)
        throw new Error(`Subscription does not exist: ${url}`);

      subscriptions.push(subscription);
    }
    else {
      for (let subscription of filterStorage.subscriptions()) {
        if (subscription instanceof adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_1__.RegularSubscription)
          subscriptions.push(subscription);
      }
    }
    for (let subscription of subscriptions)
      filterStorage.synchronizer.execute(subscription, true);
  },

  /**
   * Defines the recommended filter subscriptions per language.
   * @typedef {Object} Recommendation
   * @property {string} id The identifier for this subscription.
   * @property {Array<string>} languages The languages that this recommendation
   *                                      would match to.
   * @property {string} title The display name of the recommended subscription.
   * @property {Array<string>} requires A list of subscriptions that this
   *                                    one depends on.
   * @property {Array<string>} includes A list of subscriptions that this
   *                                    one also contains.
   * @property {string} type The kind of content targeted by this
   *                         recommended subscription.
   * @property {string} url Where the recommended subscription can be found
   *                        in plain text.
   * @property {string} mv2URL Where the recommended subscription can be found
   *                            for MV2 in plain text.
   */

  /**
   * Returns an array of all recommended subscriptions.
   * @return {Array<Recommendation>}
   */
  getRecommendations() {
    return Array.from((0,adblockpluscore_lib_recommendations_js__WEBPACK_IMPORTED_MODULE_3__.recommendations)(), convertRecommendation);
  },

  /**
   * Clears all subscriptions and filters.
   * @return {Promise} A function that can be called to
   *                    restore the removed subscriptions and filters.
   * @private
   */
  async removeAll() {
    for (let subscription of await this.getDownloadable())
      await this.remove(subscription.url);

    await (0,_dnr_filters_js__WEBPACK_IMPORTED_MODULE_11__.removeDynamicFilters)();

    const {filterStorage} = _core_js__WEBPACK_IMPORTED_MODULE_8__.filterEngine;
    for (let subscription of filterStorage.subscriptions())
      filterStorage.removeSubscription(subscription);
  },

  /**
   * Returns an array of MV2 to MV3 migration errors.
   * @return {array<string, string>} The migration errors.
   */
  getMigrationErrors() {
    return _prefs_js__WEBPACK_IMPORTED_MODULE_13__.Prefs.migration_errors;
  },

  /**
   * Clears the migration errors.
   */
  clearMigrationErrors() {
    _prefs_js__WEBPACK_IMPORTED_MODULE_13__.Prefs.migration_errors = [];
  },

  /**
   * Emitted when a new subscription is added.
   * @event
   * @type {EventDispatcher<Subscription>}
   */
  onAdded: new _types_js__WEBPACK_IMPORTED_MODULE_9__.EventDispatcher(dispatch => {
    adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_2__.filterNotifier.on("subscription.added", makeListener(dispatch));
  }),

  /**
   * Emitted when any property of the subscription has changed.
   * The name of the specific property is provided as a string, except
   * when the subscription has been updated, where it will be null.
   *
   * @event
   * @type {EventDispatcher<Subscription, string>}
   */
  onChanged: new _types_js__WEBPACK_IMPORTED_MODULE_9__.EventDispatcher(dispatch => {
    function makeChangeListener(property) {
      // This name differs between EWE and adblockpluscore.
      if (property == "disabled")
        property = "enabled";

      return subscription => {
        if (subscription instanceof adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_1__.RegularSubscription)
          dispatch(convertSubscription(subscription), property);
      };
    }

    let properties = ["disabled", "title", "homepage", "lastDownload",
                      "downloadStatus", "downloading"];
    for (let property of properties) {
      adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_2__.filterNotifier.on(`subscription.${property}`,
                        makeChangeListener(property));
    }

    adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_2__.filterNotifier.on("subscription.updated", makeChangeListener(null));
  }),

  /**
   * Emitted when a subscription is removed.
   * @event
   * @type {EventDispatcher<Subscription>}
   */
  onRemoved: new _types_js__WEBPACK_IMPORTED_MODULE_9__.EventDispatcher(dispatch => {
    adblockpluscore_lib_filterNotifier_js__WEBPACK_IMPORTED_MODULE_2__.filterNotifier.on("subscription.removed", makeListener(dispatch));
  })
});


/***/ }),

/***/ "./sdk/api/testing.js":
/*!****************************!*\
  !*** ./sdk/api/testing.js ***!
  \****************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_821358__) => {

"use strict";
__nested_webpack_require_821358__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_821358__.d(__webpack_exports__, {
/* harmony export */   "default": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_821358__(/*! adblockpluscore/lib/subscriptionClasses.js */ "./node_modules/adblockpluscore/lib/subscriptionClasses.js");
/* harmony import */ var adblockpluscore_lib_recommendations_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_821358__(/*! adblockpluscore/lib/recommendations.js */ "./node_modules/adblockpluscore/lib/recommendations.js");
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_821358__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var _prefs_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_821358__(/*! ./prefs.js */ "./sdk/api/prefs.js");
/* harmony import */ var _debugging_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_821358__(/*! ./debugging.js */ "./sdk/api/debugging.js");
/* harmony import */ var _info_js__WEBPACK_IMPORTED_MODULE_5__ = __nested_webpack_require_821358__(/*! ./info.js */ "./sdk/api/info.js");
/* harmony import */ var _sitekey_js__WEBPACK_IMPORTED_MODULE_6__ = __nested_webpack_require_821358__(/*! ./sitekey.js */ "./sdk/api/sitekey.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */











/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({
  ..._sitekey_js__WEBPACK_IMPORTED_MODULE_6__, // everything exported from "sitekey.js"

  /**
   * @ignore
   * Used internally. Sets the preference value.
   * @param {string} [key] Preference key
   * @param {Object} [value] Preference value
   */
  _setPrefs(key, value) {
    _prefs_js__WEBPACK_IMPORTED_MODULE_3__.Prefs[key] = value;
  },

  /**
   * @ignore
   * Used internally. Gets the preference value.
   * @param {string} [key] Preference key
   * @returns {Object} Preference value
   */
  _getPrefs(key) {
    return _prefs_js__WEBPACK_IMPORTED_MODULE_3__.Prefs[key];
  },

  /**
   * @ignore
   * Used internally. Restart the Synchronizer.
   */
  _restartSynchronizer() {
    let {filterStorage} = _core_js__WEBPACK_IMPORTED_MODULE_2__.filterEngine;
    filterStorage.synchronizer.stop();
    filterStorage.synchronizer.start();
  },

  /**
   * @ignore
   * Used internally. Sets the subscription property.
   * @param {string} [url] Subscription URL
   * @param {Object} [prototype] Object to set the subscription properties from.
   */
  async _setSubscriptionProperties(url, prototype) {
    let subscription = adblockpluscore_lib_subscriptionClasses_js__WEBPACK_IMPORTED_MODULE_0__.Subscription.fromURL(url);
    for (let property in prototype)
      subscription[property] = prototype[property];

    await _core_js__WEBPACK_IMPORTED_MODULE_2__.filterEngine.filterStorage.saveToDisk();
    await _debugging_js__WEBPACK_IMPORTED_MODULE_4__.default.ensureEverythingHasSaved();
  },

  /**
   * @ignore
   * @param {Recommendation} subscriptions
   */
  _setSubscriptions(subscriptions) {
    (0,_info_js__WEBPACK_IMPORTED_MODULE_5__.setAddonInfo)({bundledSubscriptions: subscriptions,
                  bundledSubscriptionsPath: _info_js__WEBPACK_IMPORTED_MODULE_5__.addonBundledSubscriptionsPath});
    (0,adblockpluscore_lib_recommendations_js__WEBPACK_IMPORTED_MODULE_1__.setRecommendations)(subscriptions);
  },

  _setAddonInfo: _info_js__WEBPACK_IMPORTED_MODULE_5__.setAddonInfo
});


/***/ }),

/***/ "./sdk/api/types.js":
/*!**************************!*\
  !*** ./sdk/api/types.js ***!
  \**************************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_825666__) => {

"use strict";
__nested_webpack_require_825666__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_825666__.d(__webpack_exports__, {
/* harmony export */   "BlockableEventDispatcher": () => (/* reexport safe */ _diagnostics_js__WEBPACK_IMPORTED_MODULE_0__.BlockableEventDispatcher),
/* harmony export */   "EventDispatcher": () => (/* binding */ EventDispatcher),
/* harmony export */   "FilterError": () => (/* binding */ FilterError)
/* harmony export */ });
/* harmony import */ var _diagnostics_js__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_825666__(/*! ./diagnostics.js */ "./sdk/api/diagnostics.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */



/**
 * The EventDispatcher class allows users to listen to
 * certain events that are emitted.
 * @hideconstructor
 * @param {function} initializer
 * @param {function} [finalizer]
 */
class EventDispatcher {
  constructor(initializer, finalizer) {
    this._listeners = new Set();
    this._initialized = false;

    let dispatch = (...args) => {
      for (let listener of this._listeners)
        listener(...args);
    };

    this._initialize = initializer.bind(null, dispatch);
    this._finalize = finalizer && finalizer.bind(null, dispatch);
  }

  /**
    * Attaches a listener function to an event. This listener will be called
    * when the event is emitted. Please note that in an MV3 context this has
    * to happen in the first turn of the event loop. This should happen when
    * your service worker starts.
    * @param {function} listener The user defined function that will be called
    *                            once the specified event is emitted.
    */
  addListener(listener) {
    if (!this._initialized) {
      this._initialize();
      this._initialized = true;
    }

    this._listeners.add(listener);
  }

  /**
    * Removes the added function. The listener will no longer be called
    * by the event.
    * @param {function} listener The user defined function to be removed.
    */
  removeListener(listener) {
    this._listeners.delete(listener);

    if (this._initialized && this._finalize && this._listeners.size == 0) {
      this._finalize();
      this._initialized = false;
    }
  }
}

/**
 * The result of parsing an invalid filter.
 * @property {string} type Either `invalid_filter` or `invalid_domain`.
 * @property {string} reason The reason why the filter is invalid.
 * @property {string?} option The filter option that made the filter invalid.
 * @param {string} type
 * @param {string} reason
 * @param {string?} option
 * @hideconstructor
 */
class FilterError extends Error {
  constructor(type, reason, option = null) {
    super(JSON.stringify({type, reason, option}));
    this.name = "FilterError";
    this.type = type;
    this.reason = reason;
    this.option = option;
  }
}


/***/ }),

/***/ "./sdk/errors.js":
/*!***********************!*\
  !*** ./sdk/errors.js ***!
  \***********************/
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nested_webpack_require_829302__) => {

"use strict";
__nested_webpack_require_829302__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_829302__.d(__webpack_exports__, {
/* harmony export */   "ERROR_DUPLICATE_FILTERS": () => (/* binding */ ERROR_DUPLICATE_FILTERS),
/* harmony export */   "ERROR_FILTER_NOT_FOUND": () => (/* binding */ ERROR_FILTER_NOT_FOUND),
/* harmony export */   "ERROR_TOO_MANY_FILTERS": () => (/* binding */ ERROR_TOO_MANY_FILTERS),
/* harmony export */   "ignoreNoConnectionError": () => (/* binding */ ignoreNoConnectionError)
/* harmony export */ });
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */

const ERROR_NO_CONNECTION = "Could not establish connection. " +
      "Receiving end does not exist.";
const ERROR_CLOSED_CONNECTION = "A listener indicated an asynchronous " +
      "response by returning true, but the message channel closed before a " +
      "response was received";

const ERROR_DUPLICATE_FILTERS = "storage_duplicate_filters";
const ERROR_FILTER_NOT_FOUND = "filter_not_found";
const ERROR_TOO_MANY_FILTERS = "too_many_filters";

function ignoreNoConnectionError(promise) {
  return promise.catch(error => {
    if (typeof error == "object" &&
        (error.message == ERROR_NO_CONNECTION ||
         error.message == ERROR_CLOSED_CONNECTION))
      return;

    throw error;
  });
}


/***/ }),

/***/ "perf_hooks":
/*!***********************!*\
  !*** external "self" ***!
  \***********************/
/***/ ((module) => {

"use strict";
module.exports = self;

/***/ })

/******/ 	});
/************************************************************************/
/******/ 	// The module cache
/******/ 	var __webpack_module_cache__ = {};
/******/ 	
/******/ 	// The require function
/******/ 	function __nested_webpack_require_831654__(moduleId) {
/******/ 		// Check if module is in cache
/******/ 		var cachedModule = __webpack_module_cache__[moduleId];
/******/ 		if (cachedModule !== undefined) {
/******/ 			return cachedModule.exports;
/******/ 		}
/******/ 		// Create a new module (and put it into the cache)
/******/ 		var module = __webpack_module_cache__[moduleId] = {
/******/ 			// no module.id needed
/******/ 			// no module.loaded needed
/******/ 			exports: {}
/******/ 		};
/******/ 	
/******/ 		// Execute the module function
/******/ 		__webpack_modules__[moduleId].call(module.exports, module, module.exports, __nested_webpack_require_831654__);
/******/ 	
/******/ 		// Return the exports of the module
/******/ 		return module.exports;
/******/ 	}
/******/ 	
/************************************************************************/
/******/ 	/* webpack/runtime/define property getters */
/******/ 	(() => {
/******/ 		// define getter functions for harmony exports
/******/ 		__nested_webpack_require_831654__.d = (exports, definition) => {
/******/ 			for(var key in definition) {
/******/ 				if(__nested_webpack_require_831654__.o(definition, key) && !__nested_webpack_require_831654__.o(exports, key)) {
/******/ 					Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
/******/ 				}
/******/ 			}
/******/ 		};
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/global */
/******/ 	(() => {
/******/ 		__nested_webpack_require_831654__.g = (function() {
/******/ 			if (typeof globalThis === 'object') return globalThis;
/******/ 			try {
/******/ 				return this || new Function('return this')();
/******/ 			} catch (e) {
/******/ 				if (typeof window === 'object') return window;
/******/ 			}
/******/ 		})();
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/hasOwnProperty shorthand */
/******/ 	(() => {
/******/ 		__nested_webpack_require_831654__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/make namespace object */
/******/ 	(() => {
/******/ 		// define __esModule on exports
/******/ 		__nested_webpack_require_831654__.r = (exports) => {
/******/ 			if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
/******/ 				Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
/******/ 			}
/******/ 			Object.defineProperty(exports, '__esModule', { value: true });
/******/ 		};
/******/ 	})();
/******/ 	
/************************************************************************/
var __webpack_exports__ = {};
// This entry need to be wrapped in an IIFE because it need to be in strict mode.
(() => {
"use strict";
/*!**************************!*\
  !*** ./sdk/api/index.js ***!
  \**************************/
__nested_webpack_require_831654__.r(__webpack_exports__);
/* harmony export */ __nested_webpack_require_831654__.d(__webpack_exports__, {
/* harmony export */   "subscriptions": () => (/* reexport safe */ _subscriptions_js__WEBPACK_IMPORTED_MODULE_11__.default),
/* harmony export */   "filters": () => (/* reexport safe */ _filters_js__WEBPACK_IMPORTED_MODULE_15__.default),
/* harmony export */   "reporting": () => (/* reexport safe */ _reporting_js__WEBPACK_IMPORTED_MODULE_16__.default),
/* harmony export */   "debugging": () => (/* reexport safe */ _debugging_js__WEBPACK_IMPORTED_MODULE_17__.default),
/* harmony export */   "allowlisting": () => (/* reexport safe */ _allowlisting_js__WEBPACK_IMPORTED_MODULE_18__.default),
/* harmony export */   "testing": () => (/* reexport safe */ _testing_js__WEBPACK_IMPORTED_MODULE_19__.default),
/* harmony export */   "notifications": () => (/* binding */ notifications),
/* harmony export */   "snippets": () => (/* binding */ snippets),
/* harmony export */   "start": () => (/* binding */ start)
/* harmony export */ });
/* harmony import */ var webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__ = __nested_webpack_require_831654__(/*! webextension-polyfill */ "./node_modules/webextension-polyfill/dist/browser-polyfill.js");
/* harmony import */ var adblockpluscore_lib_notifications_js__WEBPACK_IMPORTED_MODULE_1__ = __nested_webpack_require_831654__(/*! adblockpluscore/lib/notifications.js */ "./node_modules/adblockpluscore/lib/notifications.js");
/* harmony import */ var _initializer_js__WEBPACK_IMPORTED_MODULE_2__ = __nested_webpack_require_831654__(/*! ./initializer.js */ "./sdk/api/initializer.js");
/* harmony import */ var _message_responder_js__WEBPACK_IMPORTED_MODULE_3__ = __nested_webpack_require_831654__(/*! ./message-responder.js */ "./sdk/api/message-responder.js");
/* harmony import */ var _popup_blocker_background_page_js__WEBPACK_IMPORTED_MODULE_4__ = __nested_webpack_require_831654__(/*! ./popup-blocker-background-page.js */ "./sdk/api/popup-blocker-background-page.js");
/* harmony import */ var _popup_blocker_service_worker_js__WEBPACK_IMPORTED_MODULE_5__ = __nested_webpack_require_831654__(/*! ./popup-blocker-service-worker.js */ "./sdk/api/popup-blocker-service-worker.js");
/* harmony import */ var _request_filter_js__WEBPACK_IMPORTED_MODULE_6__ = __nested_webpack_require_831654__(/*! ./request-filter.js */ "./sdk/api/request-filter.js");
/* harmony import */ var _sitekey_js__WEBPACK_IMPORTED_MODULE_7__ = __nested_webpack_require_831654__(/*! ./sitekey.js */ "./sdk/api/sitekey.js");
/* harmony import */ var _content_filter_js__WEBPACK_IMPORTED_MODULE_8__ = __nested_webpack_require_831654__(/*! ./content-filter.js */ "./sdk/api/content-filter.js");
/* harmony import */ var _info_js__WEBPACK_IMPORTED_MODULE_9__ = __nested_webpack_require_831654__(/*! ./info.js */ "./sdk/api/info.js");
/* harmony import */ var _core_js__WEBPACK_IMPORTED_MODULE_10__ = __nested_webpack_require_831654__(/*! ./core.js */ "./sdk/api/core.js");
/* harmony import */ var _subscriptions_js__WEBPACK_IMPORTED_MODULE_11__ = __nested_webpack_require_831654__(/*! ./subscriptions.js */ "./sdk/api/subscriptions.js");
/* harmony import */ var _dnr_filters_js__WEBPACK_IMPORTED_MODULE_12__ = __nested_webpack_require_831654__(/*! ./dnr-filters.js */ "./sdk/api/dnr-filters.js");
/* harmony import */ var _prefs_js__WEBPACK_IMPORTED_MODULE_13__ = __nested_webpack_require_831654__(/*! ./prefs.js */ "./sdk/api/prefs.js");
/* harmony import */ var _browser_features_js__WEBPACK_IMPORTED_MODULE_14__ = __nested_webpack_require_831654__(/*! ./browser-features.js */ "./sdk/api/browser-features.js");
/* harmony import */ var _filters_js__WEBPACK_IMPORTED_MODULE_15__ = __nested_webpack_require_831654__(/*! ./filters.js */ "./sdk/api/filters.js");
/* harmony import */ var _reporting_js__WEBPACK_IMPORTED_MODULE_16__ = __nested_webpack_require_831654__(/*! ./reporting.js */ "./sdk/api/reporting.js");
/* harmony import */ var _debugging_js__WEBPACK_IMPORTED_MODULE_17__ = __nested_webpack_require_831654__(/*! ./debugging.js */ "./sdk/api/debugging.js");
/* harmony import */ var _allowlisting_js__WEBPACK_IMPORTED_MODULE_18__ = __nested_webpack_require_831654__(/*! ./allowlisting.js */ "./sdk/api/allowlisting.js");
/* harmony import */ var _testing_js__WEBPACK_IMPORTED_MODULE_19__ = __nested_webpack_require_831654__(/*! ./testing.js */ "./sdk/api/testing.js");
/*
 * This file is part of eyeo's Web Extension Ad Blocking Toolkit (EWE),
 * Copyright (C) 2006-present eyeo GmbH
 *
 * EWE is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * EWE is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with EWE.  If not, see <http://www.gnu.org/licenses/>.
 */


























/**
 * The notifications API (optional usage).
 *
 * To start using this module, calling `notifications.start()` is required.
 * Please also notice that notification events are **not** using the
 * {@link #eventdispatcher|EventDispatcher} interface.
 * @see {@link https://gitlab.com/eyeo/adblockplus/abc/adblockpluscore/-/jobs/artifacts/0.6.0/file/build/docs/module-notifications-Notifications.html?job=docs|Adblock Plus core notifications documentation}
 * @external
 */
// Workaround for documentation.js to parse the JSDocs above
// https://github.com/documentationjs/documentation/issues/1363
let notifications = adblockpluscore_lib_notifications_js__WEBPACK_IMPORTED_MODULE_1__.notifications;

let snippets = {
  /**
   * Snippet callback.
   * @callback SnippetCallback
   * @param {Object} environment
   *   The environment variables
   * @param {...Array.<Array.<string>>} _
   *   The snippets names and arguments.
   */

  /**
   * Enables support for snippet filters.
   * @param {Object} [snippetInfo]
   * @param {SnippetCallback} [snippetInfo.isolatedCode]
   *   The code defining the available snippets to be executed in the isolated
   *   content script context.
   * @param {SnippetCallback} [snippetInfo.injectedCode]
   *   The code defining the available snippets to be injected and executed in
   *   the main context.
   */
  setLibrary: _content_filter_js__WEBPACK_IMPORTED_MODULE_8__.setSnippetLibrary
};

async function onInstalled(details) {
  await _initializer_js__WEBPACK_IMPORTED_MODULE_2__.default.start();

  if (_prefs_js__WEBPACK_IMPORTED_MODULE_13__.Prefs.migration_state === _prefs_js__WEBPACK_IMPORTED_MODULE_13__.MIGRATED_TO_MV2) {
    await (0,_subscriptions_js__WEBPACK_IMPORTED_MODULE_11__.migrate)();
    await (0,_dnr_filters_js__WEBPACK_IMPORTED_MODULE_12__.migrateCustomFilters)();
    _prefs_js__WEBPACK_IMPORTED_MODULE_13__.Prefs.migration_state = _prefs_js__WEBPACK_IMPORTED_MODULE_13__.MIGRATED_TO_MV3;
  }

  await (0,_subscriptions_js__WEBPACK_IMPORTED_MODULE_11__.updateFilterText)();
  await (0,_subscriptions_js__WEBPACK_IMPORTED_MODULE_11__.ensureDNRRulesetsEnabled)();
}

/**
* @typedef {Object} FirstRunInfo
* @property {boolean} foundStorage Whether the subscriptions storage was
*                                  initialized or not.
* @property {boolean} foundSubscriptions True when pre-existing subscriptions
*                                        were found, false otherwise.
*                                        Considers also whether custom filters
*                                        exist.
* @property {Array.<string>?} [warnings] An array of warnings.
*/

/**
 * Initializes the filter engine and starts blocking content.
 *
 * Calling this function is required for the other API calls to work, except for
 * API event listener calls, which could also be done before `start()`.
 * @param {Object?} [addonInfo] An object containing addon
 *   information belonging to sdk consumer, that can be accessed via
 *   `debugging` module. (It is usually used as an identifier in
 *   network requests, etc.). This object can be undefined for MV2. If it is,
 *   name and version will default to the extension's name and version.
 * @param {string} [addonInfo.name] Name of the addon/extension.
 * @param {string} [addonInfo.version] Version of the addon/extension.
 * @param {Array<Recommendation>?} [addonInfo.bundledSubscriptions]
 *   A list of subscriptions provided by the integrator. Cannot be undefined
 *   for MV3.
 * @param {string?} [addonInfo.bundledSubscriptionsPath]
 *   A path to subscription files provided by the integrator. Cannot be
 *   undefined for MV3.
 * @return {Promise<FirstRunInfo>} Promise that is resolved after starting up
 *                                 is completed.
 */
async function start(addonInfo) {
  (0,_info_js__WEBPACK_IMPORTED_MODULE_9__.setAddonInfo)(addonInfo);
  startSubmodulesWithListeners();

  let warnings = [];

  if (webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.declarativeNetRequest) {
    webextension_polyfill__WEBPACK_IMPORTED_MODULE_0__.runtime.onInstalled.addListener(onInstalled);
    warnings = await (0,_subscriptions_js__WEBPACK_IMPORTED_MODULE_11__.validate)(
      addonInfo.bundledSubscriptions, addonInfo.bundledSubscriptionsPath);
  }

  await startSubmodules();

  let {filterStorage} = _core_js__WEBPACK_IMPORTED_MODULE_10__.filterEngine;
  let firstRun = {
    foundSubscriptions: filterStorage.getSubscriptionCount() != 0,
    foundStorage: !filterStorage.firstRun,
    warnings
  };

  return firstRun;
}

function startSubmodulesWithListeners() {
  // for MV3, submodules that register event listeners generally need
  // to register their events in the first turn of the event loop to
  // register their event listeners.
  _message_responder_js__WEBPACK_IMPORTED_MODULE_3__.start();
  if ((0,_browser_features_js__WEBPACK_IMPORTED_MODULE_14__.isRunningInServiceWorker)())
    _popup_blocker_service_worker_js__WEBPACK_IMPORTED_MODULE_5__.start();

  _sitekey_js__WEBPACK_IMPORTED_MODULE_7__.start();
}

async function startSubmodules() {
  await _initializer_js__WEBPACK_IMPORTED_MODULE_2__.default.start();

  // MV2-style popup and request blocking assume that initializer is
  // started first.
  if (!(0,_browser_features_js__WEBPACK_IMPORTED_MODULE_14__.isRunningInServiceWorker)())
    _popup_blocker_background_page_js__WEBPACK_IMPORTED_MODULE_4__.start();

  _request_filter_js__WEBPACK_IMPORTED_MODULE_6__.start();
  _core_js__WEBPACK_IMPORTED_MODULE_10__.filterEngine.filterStorage.synchronizer.start();
}

})();

/******/ 	return __webpack_exports__;
/******/ })()
;
});

/***/ }),

/***/ 8858:
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "_o": () => (/* binding */ allowlistingState),
/* harmony export */   "s": () => (/* binding */ revalidateAllowlistingStates)
/* harmony export */ });
/* unused harmony export allowlist */
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3817);
/* harmony import */ var _messaging_port_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4554);
/* harmony import */ var _events_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2901);
/* harmony import */ var _filterConfiguration_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2413);
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module allowlisting */






let allowlistedDomainRegexp = /^@@\|\|([^/:]+)\^\$document$/;
let eventEmitter = new _events_js__WEBPACK_IMPORTED_MODULE_3__/* .EventEmitter */ .v();

/**
 * @typedef {object} filtersIsAllowlistedResult
 * @property {boolean} hostname
 *   True if an allowing filter for an entire domain matches the given page.
 * @property {boolean} page
 *   True if an allowing filter _not_ for an entire domain matches the given
 *   page.
 */

/**
 * Checks if the given page is allowlisted.
 *
 * @event "filters.isAllowlisted"
 * @returns {filtersIsAllowlistedResult}
 */
_messaging_port_js__WEBPACK_IMPORTED_MODULE_1__/* .port.on */ .N.on("filters.isAllowlisted", async message =>
{
  let pageAllowlisted = false;
  let hostnameAllowlisted = false;

  for (let filterText of await _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.filters.getAllowingFilters(message.tab.id))
  {
    if (allowlistedDomainRegexp.test(filterText))
      hostnameAllowlisted = true;
    else
      pageAllowlisted = true;

    if (pageAllowlisted && hostnameAllowlisted)
      break;
  }

  return {hostname: hostnameAllowlisted, page: pageAllowlisted};
});

async function allowlist({hostname, origin, singlePage = false, url})
{
  let filterText;

  if (!hostname && !url)
    throw new Error("Hostname or URL required");

  if (url)
  {
    if (!(url instanceof URL))
      throw new Error("Invalid URL");

    if (singlePage)
    {
      // We generate a filter which only applies to the same protocol and
      // subdomain, but one which doesn't consider the exact query string or
      // fragment.
      // Our logic here is taken from the legacy Firefox extension.
      // See https://hg.adblockplus.org/adblockplus/file/tip/lib/ui.js#l1517
      let ending = "|";
      url.hash = "";
      if (url.search && url.search.includes("&"))
      {
        url.search = "";
        ending = "?";
      }
      filterText = `@@|${url.href}${ending}$document`;
    }
    else
    {
      hostname = url.hostname;
    }
  }

  if (!filterText)
  {
    let host = hostname.replace(/^www\./, "");
    filterText = `@@||${host}^$document`;
  }

  await _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.filters.enable([filterText]);

  const filterSubscriptions = await _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.subscriptions.getForFilter(filterText);
  if (filterSubscriptions.length == 0)
    await (0,_filterConfiguration_js__WEBPACK_IMPORTED_MODULE_2__/* .addFilter */ .KJ)(filterText, origin);
}

/**
 * Adds an allowing filter for the given page's hostname, if it is not
 * already allowlisted. Note: If a disabled allowing filter exists, we
 * enable that instead.
 *
 * @event "filters.allowlist"
 * @proper {string} [origin]
 *   String indicating where the filter originated from.
 * @property {boolean} [singlePage=false]
 *   If true we add an allowing filter for the given page's URL instead.
 * @property {object} tab
 *   Tab that contains the page to allowlist.
 */
_messaging_port_js__WEBPACK_IMPORTED_MODULE_1__/* .port.on */ .N.on("filters.allowlist", async message =>
{
  let page = new ext.Page(message.tab);
  await allowlist({
    origin: message.origin,
    singlePage: message.singlePage,
    url: page.url
  });
});

/**
 * Remove any allowing filters which apply to the given page's URL.
 *
 * @event "filters.unallowlist"
 * @property {boolean} [singlePage=false]
 *   If true we only remove allowing filters which are not for an entire
 *   domain.
 */
_messaging_port_js__WEBPACK_IMPORTED_MODULE_1__/* .port.on */ .N.on("filters.unallowlist", async message =>
{
  for (let filterText of await _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.filters.getAllowingFilters(message.tab.id))
  {
    if (message.singlePage && allowlistedDomainRegexp.test(filterText))
      continue;

    await _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.filters.remove([filterText]);

    const filterSubscriptions = await _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.subscriptions.getForFilter(filterText);
    if (filterSubscriptions.length != 0)
      await _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.filters.disable([filterText]);
  }
});

/**
 * @namespace
 * @static
 */
let allowlistingState = {
  /**
   * Adds a listener for the given event name.
   *
   * @param {string} name
   * @param {function} listener
   */
  addListener: eventEmitter.on.bind(eventEmitter),

  /**
   * Removes a listener for the given event name.
   *
   * @param {string} name
   * @param {function} listener
   */
  removeListener: eventEmitter.off.bind(eventEmitter)
};

async function revalidateAllowlistingState(page)
{
  eventEmitter.emit(
    "changed",
    page,
    await _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.filters.isResourceAllowlisted(page.url, "document", page.id)
  );
}

async function revalidateAllowlistingStates()
{
  let tabs = await browser.tabs.query({});
  for (let tab of tabs)
    revalidateAllowlistingState(new ext.Page(tab));
}

ext.pages.onLoaded.addListener(revalidateAllowlistingState);
_vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.filters.onAdded.addListener(revalidateAllowlistingStates);
_vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.filters.onChanged.addListener(async(filter, property) =>
{
  if (property !== "enabled")
    return;

  await revalidateAllowlistingStates();
});
_vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.filters.onRemoved.addListener(revalidateAllowlistingStates);
_vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.subscriptions.onAdded.addListener(revalidateAllowlistingStates);
_vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.subscriptions.onChanged.addListener(async(subscription, property) =>
{
  if (property !== null && property !== "enabled")
    return;

  await revalidateAllowlistingStates();
});
_vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.subscriptions.onRemoved.addListener(revalidateAllowlistingStates);


/***/ }),

/***/ 3265:
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "c4": () => (/* binding */ setIconPath),
/* harmony export */   "k8": () => (/* binding */ setIconImageData),
/* harmony export */   "q_": () => (/* binding */ setBadge)
/* harmony export */ });
/* unused harmony export toggleBadge */
/* harmony import */ var _storage_tab_session_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1627);
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module browserAction */



let badgeStateByPage = new _storage_tab_session_js__WEBPACK_IMPORTED_MODULE_0__/* .TabSessionStorage */ .H("browserAction:blockedState");
let changesByPage = new _storage_tab_session_js__WEBPACK_IMPORTED_MODULE_0__/* .TabSessionStorage */ .H("browserAction:changes");

async function setBadgeState(tabId, key, value)
{
  let badgeState = await badgeStateByPage.get(tabId);

  if (!badgeState)
  {
    badgeState = {
      hiddenState: "visible",
      text: ""
    };
  }

  // We need to ignore any text changes while we're hiding the badge
  if (!(badgeState.hiddenState == "hiding" && key == "text"))
    badgeState[key] = value;

  await badgeStateByPage.set(tabId, badgeState);

  return badgeState;
}

function applyChanges(tabId, changes)
{
  return Promise.all(Object.keys(changes).map(async change =>
  {
    // Firefox for Android displays the browser action not as an icon but
    // as a menu item. There is no icon, but such an option may be added
    // in the future.
    // https://bugzilla.mozilla.org/show_bug.cgi?id=1331746
    if (change == "iconPath" && "setIcon" in browser.action)
    {
      return browser.action.setIcon({
        tabId,
        path: {
          16: changes.iconPath.replace("$size", "16"),
          20: changes.iconPath.replace("$size", "20"),
          32: changes.iconPath.replace("$size", "32"),
          40: changes.iconPath.replace("$size", "40")
        }
      });
    }

    if (change == "iconImageData" && "setIcon" in browser.action)
    {
      return browser.action.setIcon({
        tabId,
        imageData: changes.iconImageData
      });
    }

    // There is no badge on Firefox for Android; the browser action is
    // simply a menu item.
    if (change == "badgeText" && "setBadgeText" in browser.action)
    {
      // Remember changes to the badge text but don't apply them yet
      // as long as the badge is hidden.
      let badgeState = await setBadgeState(tabId, "text", changes.badgeText);
      if (badgeState.hiddenState == "hidden")
        return;

      return browser.action.setBadgeText({
        tabId,
        text: changes.badgeText
      });
    }

    // There is no badge on Firefox for Android; the browser action is
    // simply a menu item.
    if (change == "badgeColor" &&
        "setBadgeBackgroundColor" in browser.action)
    {
      return browser.action.setBadgeBackgroundColor({
        tabId,
        color: changes.badgeColor
      });
    }
  }));
}

async function addChange(tabId, name, value)
{
  const changes = (await changesByPage.get(tabId)) || {};
  changes[name] = value;
  await changesByPage.set(tabId, changes);

  try
  {
    await applyChanges(tabId, changes);
    await changesByPage.delete(tabId);
  }
  catch (e)
  {
    // If the tab is prerendered, browser.action.set* fails
    // and we have to delay our changes until the currently visible tab
    // is replaced with the prerendered tab.
  }
}

async function onReplaced(addedTabId)
{
  const changes = await changesByPage.get(addedTabId);
  if (!changes)
    return;

  try
  {
    await applyChanges(addedTabId, changes);
  }
  catch (e)
  {
    // Ignore if we fail to apply the changes
  }

  await changesByPage.delete(addedTabId);
}
// If the tab is prerendered, browser.action.set* fails
// and we have to delay our changes until the currently visible tab
// is replaced with the prerendered tab.
browser.tabs.onReplaced.addListener(onReplaced);

/**
 * Sets icon badge for given tab.
 *
 * @param {number} tabId
 * @param {object} badge
 * @param {string} badge.color
 * @param {string} badge.number
 */
function setBadge(tabId, badge)
{
  if (!badge)
  {
    addChange(tabId, "badgeText", "");
  }
  else
  {
    if ("number" in badge)
      addChange(tabId, "badgeText", badge.number.toString());

    if ("color" in badge)
      addChange(tabId, "badgeColor", badge.color);
  }
}

/**
 * Sets icon image for given tab using image data.
 *
 * @param  {number} tabId
 * @param  {object} imageData
 */
function setIconImageData(tabId, imageData)
{
  addChange(tabId, "iconImageData", imageData);
}

/**
 * Sets icon image for given tab using file path.
 *
 * @param  {number} tabId
 * @param  {string} path - expected to include "$size" placeholder
 */
function setIconPath(tabId, path)
{
  addChange(tabId, "iconPath", path);
}

/**
 * Toggles icon badge for given tab.
 *
 * @param  {number} tabId
 * @param  {boolean} shouldHide
 */
async function toggleBadge(tabId, shouldHide)
{
  if (shouldHide)
  {
    await setBadgeState(tabId, "hiddenState", "hiding");
    addChange(tabId, "badgeText", "");
    await setBadgeState(tabId, "hiddenState", "hidden");
  }
  else
  {
    let badgeState = await setBadgeState(tabId, "hiddenState", "visible");
    addChange(tabId, "badgeText", badgeState.text);
  }
}


/***/ }),

/***/ 2019:
/***/ ((__unused_webpack___webpack_module__, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony import */ var _messaging_port_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4554);
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */



let lastError = null;

function safeToString(value)
{
  try
  {
    return String(value);
  }
  catch (e)
  {
    return "<string conversion error>";
  }
}

self.addEventListener("error", event =>
{
  lastError = safeToString(event.error);
});

self.addEventListener("unhandledrejection", event =>
{
  lastError = safeToString(event.reason);
});

let consoleError = console.error;
console.error = function error(...args)
{
  lastError = args.map(safeToString).join(" ");
  consoleError.apply(this, args);
};

_messaging_port_js__WEBPACK_IMPORTED_MODULE_0__/* .port.on */ .N.on("debug.getLastError", () =>
{
  let error = lastError;
  lastError = null;
  return error;
});


/***/ }),

/***/ 4047:
/***/ ((__unused_webpack___webpack_module__, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";

// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/build/templates/info.chrome.js.tmpl
var info_chrome_js = __webpack_require__(4043);
// EXTERNAL MODULE: ./vendor/webext-sdk/dist/ewe-api.js
var ewe_api = __webpack_require__(3817);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/messaging/events.js
var events = __webpack_require__(2325);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/messaging/port.js
var port = __webpack_require__(4554);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/messaging/types.js
var types = __webpack_require__(3242);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/storage/tab-session.js
var tab_session = __webpack_require__(1627);
;// CONCATENATED MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/versions.js
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */

function parseVersionComponent(comp)
{
  if (comp == "*")
    return Infinity;
  return parseInt(comp, 10) || 0;
}

/**
 * Compares two versions.
 *
 * @param {string} v1 The first version.
 * @param {string} v2 The second version.
 *
 * @returns {number} `-1` if `v1` is older than `v2`; `1` if `v1` is newer than
 *   `v2`; otherwise `0`.
 *
 * @package
 */
function compareVersions(v1, v2)
{
  let regexp = /^(.*?)([a-z].*)?$/i;
  let [, head1, tail1] = regexp.exec(v1);
  let [, head2, tail2] = regexp.exec(v2);
  let components1 = head1.split(".");
  let components2 = head2.split(".");

  for (let i = 0; i < components1.length ||
                  i < components2.length; i++)
  {
    let result = parseVersionComponent(components1[i]) -
                 parseVersionComponent(components2[i]) || 0;

    if (result < 0)
      return -1;
    else if (result > 0)
      return 1;
  }

  // Compare version suffix (e.g. 0.1alpha < 0.1b1 < 01.b2 < 0.1).
  // However, note that this is a simple string comparision, meaning: b10 < b2
  if (tail1 == tail2)
    return 0;
  if (!tail1 || tail2 && tail1 > tail2)
    return 1;
  return -1;
}

;// CONCATENATED MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/devtools.js
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module devtools */










const reloadStateByPage = new tab_session/* TabSessionStorage */.H("devtools:reloadState");

async function onBlockableItem(emit, blockableItem)
{
  const {filter} = blockableItem;

  let subscriptions = [];
  if (filter)
  {
    subscriptions = await ewe_api.subscriptions.getForFilter(filter.text);
    subscriptions = subscriptions
      .filter(subscription => subscription.enabled)
      .map(types/* toPlainSubscription */.LC);
  }

  emit(
    (0,types/* toPlainBlockableItem */.Q1)(blockableItem),
    (filter) ? (0,types/* toPlainFilter */.ot)(filter) : null,
    subscriptions
  );
}

async function onPageFrame(emit, details)
{
  const {tabId} = details;
  const reloadState = await reloadStateByPage.get(tabId);

  // Clear the devtools panel and reload the inspected tab without caching
  // when a new request is issued. However, make sure that we don't end up
  // in an infinite recursion if we already triggered a reload.
  if (reloadState === "reloading")
  {
    await reloadStateByPage.delete(tabId);
    return;
  }

  emit("requests", "reset");

  // We can't repeat the request if it isn't a GET request. The browser would
  // prompt the user to confirm reloading the page, and POST requests are
  // known to cause issues on many websites if repeated.
  if (details.method === "GET")
    await reloadStateByPage.set(tabId, "needsReload");
}

async function onPageLoad(page)
{
  const reloadState = await reloadStateByPage.get(page.id);

  // Reloading the tab is the only way that allows bypassing all caches, in
  // order to see all requests in the devtools panel. Reloading must not be
  // performed before the tab changes to "loading", otherwise it will load the
  // previous URL.
  if (reloadState === "needsReload")
  {
    await reloadStateByPage.set(page.id, "reloading");
    browser.tabs.reload(page.id, {bypassCache: true});
  }
}

/**
 * Returns true if our devtools panel is supported by the browser.
 *
 * @event "devtools.supported"
 * @returns {boolean}
 */
port/* port.on */.N.on("devtools.supported", (message, sender) =>
  info_chrome_js.platform == "chromium" ||
  info_chrome_js.application == "firefox" &&
  compareVersions(info_chrome_js.applicationVersion, "54") >= 0
);

(0,events/* installHandler */.a)("requests", null, (emit, action, targetTabId) =>
{
  switch (action)
  {
    case "hits":
      const blockableItemsOptions = {
        filterType: "all",
        includeElementHiding: true,
        includeUnmatched: true,
        tabId: targetTabId
      };
      const localOnBlockableItem = onBlockableItem.bind(null, emit);

      ewe_api.reporting.onBlockableItem.addListener(
        localOnBlockableItem,
        blockableItemsOptions
      );
      return () =>
      {
        ewe_api.reporting.onBlockableItem.removeListener(
          localOnBlockableItem,
          blockableItemsOptions
        );
      };
    case "reset":
      const localOnPageFrame = onPageFrame.bind(null, emit);
      const localOnPageLoad = onPageLoad.bind(null, emit);

      browser.webRequest.onBeforeRequest.addListener(
        localOnPageFrame,
        {
          urls: ["http://*/*", "https://*/*"],
          types: ["main_frame"],
          tabId: targetTabId
        }
      );
      ext.pages.onLoading.addListener(localOnPageLoad);

      return () =>
      {
        browser.webRequest.onBeforeRequest.removeListener(localOnPageFrame);
        ext.pages.onLoading.removeListener(localOnPageLoad);
      };
  }
});


/***/ }),

/***/ 2901:
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "v": () => (/* binding */ EventEmitter)
/* harmony export */ });
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module */

/**
 * Registers and emits named events.
 */
class EventEmitter
{
  constructor()
  {
    this._listeners = new Map();
  }

  /**
   * Adds a listener for the specified event name.
   *
   * @param {string}   name
   * @param {function} listener
   */
  on(name, listener)
  {
    let listeners = this._listeners.get(name);
    if (listeners)
      listeners.push(listener);
    else
      this._listeners.set(name, [listener]);
  }

  /**
   * Removes a listener for the specified event name.
   *
   * @param {string}   name
   * @param {function} listener
   */
  off(name, listener)
  {
    let listeners = this._listeners.get(name);
    if (listeners)
    {
      if (listeners.length > 1)
      {
        let idx = listeners.indexOf(listener);
        if (idx != -1)
          listeners.splice(idx, 1);
      }
      else if (listeners[0] === listener)
      {
        // We must use strict equality above for compatibility with
        // Array.prototype.indexOf
        this._listeners.delete(name);
      }
    }
  }

  /**
   * Returns a copy of the array of listeners for the specified event.
   *
   * @param {string} name
   *
   * @returns {Array.<function>}
   */
  listeners(name)
  {
    let listeners = this._listeners.size > 0 ? this._listeners.get(name) : null;
    return listeners ? listeners.slice() : [];
  }

  /**
   * Checks whether there are any listeners for the specified event.
   *
   * @param {string} [name] The name of the event. If omitted, checks whether
   *   there are any listeners for any event.
   *
   * @returns {boolean}
   */
  hasListeners(name)
  {
    return this._listeners.size > 0 &&
           (typeof name == "undefined" || this._listeners.has(name));
  }

  /**
   * Calls all previously added listeners for the given event name.
   *
   * @param {string} name
   * @param {...*}   [args]
   */
  emit(name, ...args)
  {
    let listeners = this._listeners.size > 0 ? this._listeners.get(name) : null;
    if (listeners)
    {
      for (let listener of listeners.slice())
        listener(...args);
    }
  }
}


/***/ }),

/***/ 2413:
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {

"use strict";

// EXPORTS
__webpack_require__.d(__webpack_exports__, {
  "KJ": () => (/* binding */ addFilter)
});

// UNUSED EXPORTS: askConfirmSubscription, initDisabledFilterCounters

// EXTERNAL MODULE: ./vendor/webext-sdk/dist/ewe-api.js
var ewe_api = __webpack_require__(3817);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/messaging/events.js
var events = __webpack_require__(2325);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/messaging/port.js
var messaging_port = __webpack_require__(4554);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/events.js
var lib_events = __webpack_require__(2901);
// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/prefs.js
var prefs = __webpack_require__(8710);
// EXTERNAL MODULE: ./vendor/adblockplusui/src/core/scheduled-event-emitter/background/scheduled-event-emitter.ts
var scheduled_event_emitter = __webpack_require__(6650);
// EXTERNAL MODULE: ./vendor/adblockplusui/src/core/scheduled-event-emitter/background/scheduled-event-emitter.types.ts
var scheduled_event_emitter_types = __webpack_require__(1173);
;// CONCATENATED MODULE: ./vendor/adblockplusui/src/premium/background/license.ts
var __awaiter = (undefined && undefined.__awaiter) || function (thisArg, _arguments, P, generator) {
    function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
    return new (P || (P = Promise))(function (resolve, reject) {
        function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
        function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
        function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
        step((generator = generator.apply(thisArg, _arguments || [])).next());
    });
};






const global = typeof window !== "undefined" ? window : self;
class TemporaryLicenseCheckError extends Error {
}
const emitter = new lib_events/* EventEmitter */.v();
const licenseCheckPeriod = (/* unused pure expression or super */ null && (24 * 60 * 60 * 1000));
let licenseCheckTimeoutId = null;
const licenseCheckRetryDelay = (/* unused pure expression or super */ null && (60 * 1000));
const licenseCheckRetryEventName = "premium.license.check.retry";
function activateLicense(oldLicense, newLicense) {
    Prefs.set("premium_license", newLicense);
    scheduledEmitter.removeSchedule(licenseCheckRetryEventName);
    if (oldLicense.status === "active") {
        emitter.emit("updated");
    }
    else {
        scheduleNextLicenseCheck(null);
        emitter.emit("activated");
    }
}
function checkLicense(retryCount = 0) {
    return __awaiter(this, void 0, void 0, function* () {
        if (retryCount >= 3) {
            scheduledEmitter.removeSchedule(licenseCheckRetryEventName);
            if (retryCount > 3) {
                return;
            }
        }
        const userId = Prefs.get("premium_user_id");
        if (!userId) {
            return;
        }
        try {
            if (!navigator.onLine) {
                throw new TemporaryLicenseCheckError("No network connection");
            }
            const requestData = {
                cmd: "license_check",
                u: userId,
                v: "1"
            };
            const requestUrl = Prefs.get("premium_license_check_url");
            const response = yield fetch(requestUrl, {
                method: "POST",
                cache: "no-cache",
                headers: {
                    "Content-Type": "application/json"
                },
                body: JSON.stringify(requestData)
            });
            if (!response.ok) {
                const { status } = response;
                if (status >= 400 && status <= 499) {
                    throw new Error(`Request failed (code: ${status})`);
                }
                if (status >= 500 && status <= 599) {
                    throw new TemporaryLicenseCheckError(`Received error response (code: ${status})`);
                }
                console.error(`Received unexpected response (code: ${status})`);
                return;
            }
            const oldLicense = Prefs.get("premium_license");
            const newLicense = (yield response.json());
            if (newLicense.lv !== 1) {
                throw new Error(`Invalid license version: ${newLicense.lv}`);
            }
            if (oldLicense.status === "active" && newLicense.status === "expired") {
                throw new Error("Expired license");
            }
            if (newLicense.status !== "active") {
                throw new Error(`Unknown license status: ${newLicense.status}`);
            }
            if (!newLicense.code) {
                if (!oldLicense.code) {
                    throw new Error("Undefined license code");
                }
                newLicense.code = oldLicense.code;
            }
            activateLicense(oldLicense, newLicense);
        }
        catch (ex) {
            if (ex instanceof TemporaryLicenseCheckError) {
                console.warn(`Premium license check failed (retries: ${retryCount})`, ex);
                if (retryCount > 0) {
                    return;
                }
                scheduledEmitter.setSchedule(licenseCheckRetryEventName, licenseCheckRetryDelay, ScheduleType.interval);
                return;
            }
            console.error("Premium license check failed", ex);
            deactivateLicense();
        }
    });
}
function deactivateLicense() {
    Prefs.reset("premium_license");
    Prefs.reset("premium_license_nextcheck");
    Prefs.reset("premium_user_id");
    scheduledEmitter.removeSchedule(licenseCheckRetryEventName);
    if (licenseCheckTimeoutId !== null) {
        global.clearTimeout(licenseCheckTimeoutId);
    }
    emitter.emit("deactivated");
}
function getPremiumState() {
    return { isActive: hasActiveLicense() };
}
function hasActiveLicense() {
    const license = Prefs.get("premium_license");
    return license.status === "active";
}
function initialize() {
    initializeMessaging();
    initializeLicenseChecks();
}
function scheduleNextLicenseCheck(nextTimestamp) {
    if (!nextTimestamp) {
        nextTimestamp = Date.now() + licenseCheckPeriod;
        Prefs.set("premium_license_nextcheck", nextTimestamp);
    }
    licenseCheckTimeoutId = global.setTimeout(() => {
        checkLicense();
        scheduleNextLicenseCheck(null);
    }, nextTimestamp - Date.now());
}
function initializeLicenseChecks() {
    scheduledEmitter.setListener(licenseCheckRetryEventName, (info) => {
        checkLicense(info.callCount);
    });
    const nextCheckTimestamp = Prefs.get("premium_license_nextcheck");
    if (!nextCheckTimestamp) {
        return;
    }
    scheduleNextLicenseCheck(nextCheckTimestamp);
}
function initializeMessaging() {
    port.on("premium.activate", (msg) => __awaiter(this, void 0, void 0, function* () {
        if (!msg.userId) {
            return false;
        }
        Prefs.set("premium_user_id", msg.userId);
        yield checkLicense();
        return true;
    }));
    port.on("premium.get", () => getPremiumState());
    installHandler("premium", "changed", (emit) => {
        const onChanged = () => emit(getPremiumState());
        emitter.on("activated", onChanged);
        emitter.on("deactivated", onChanged);
        return () => {
            emitter.off("activated", onChanged);
            emitter.off("deactivated", onChanged);
        };
    });
    ext.addTrustedMessageTypes(Prefs.get("premium_license_activation_origin"), [
        "premium.activate"
    ]);
}

;// CONCATENATED MODULE: ./vendor/adblockplusui/src/premium/background/index.ts



// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/storage/session.js
var session = __webpack_require__(735);
;// CONCATENATED MODULE: ./adblock-betafish/alias/options.js
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */
/*
 * Same as the original source vendor\adblockplusui\lib\pages\options.js
 * except:
 *  - updated the paths to imported modules
 *  - the 'findOptionsPage' function will correctly find the AdBlock Options page
 *    when a hash is present in the URL.
 *  - use import / export instead of require
 * /

/** @module options */







/**
 * Key to store/retrieve an optional message to send to the options page after
 * it opens.
 */
const optionsMessageKey = "optionsMessage";

let optionsPort = null;

// Firefox won't let us query for moz-extension:// pages, though
// starting with Firefox 56 an extension can query for its own URLs:
// https://bugzilla.mozilla.org/show_bug.cgi?id=1271354
const optionsUrl = browser.runtime.getURL(
  browser.runtime.getManifest().options_ui.page
);

const options_session = new session/* SessionStorage */.x("options");

async function onMessage(message, port)
{
  if (message.type != "app.listen")
    return;

  const optionsMessage = await options_session.get(optionsMessageKey);

  if (!optionsMessage)
    return;

  await options_session.delete(optionsMessageKey);

  port.postMessage(optionsMessage);
}

async function onConnect(port)
{
  if (!ext.isTrustedSender(port.sender)){
    return;
  }

  if (port.name != "ui"){
    return;
  }

  if (!port.sender.tab || !port.sender.tab.url.startsWith(optionsUrl)) {
    return;
  }

  optionsPort = port;
  optionsPort.onDisconnect.addListener(() =>
  {
    optionsPort = null;
  });
  optionsPort.onMessage.addListener(onMessage);
}
browser.runtime.onConnect.addListener(onConnect);

/**
 * Opens the options page, or switches to its existing tab.
 * @param {Object} [message] - Message to send to options page
 */
async function showOptions(message)
{
  await options_session.delete(optionsMessageKey);

  // If the options page is already open, focus its tab manually to avoid
  // potentially opening it again, due to browser.runtime.openOptionsPage()
  // behaving differently across browsers
  if (optionsPort)
  {
    // Firefox for Android doesn't support browser.windows
    if ("windows" in browser)
    {
      await browser.windows.update(
        optionsPort.sender.tab.windowId,
        {focused: true}
      );
    }

    await browser.tabs.update(optionsPort.sender.tab.id, {active: true});

    // Send message after focusing options page
    if (message)
    {
      optionsPort.postMessage(message);
    }
  }
  else
  {
    // Send message after initializing options page
    if (message)
    {
      await options_session.set(optionsMessageKey, message);
    }

    await browser.runtime.openOptionsPage();
  }
}


// We need to clear the popup URL on Firefox for Android in order for the
// options page to open instead of the bubble. Unfortunately there's a bug[1]
// which prevents us from doing that, so we must avoid setting the URL on
// Firefox from the manifest at all, instead setting it here only for
// non-mobile.
// [1] - https://bugzilla.mozilla.org/show_bug.cgi?id=1414613
Promise.all([browser.action.getPopup({}),
             browser.runtime.getPlatformInfo()]).then(
  ([popup, platformInfo]) =>
  {
    if (!popup && platformInfo.os != "android")
      browser.action.setPopup({popup: "popup.html"});
  }
);

// On Firefox for Android, open the options page directly when the browser
// action is clicked.
browser.action.onClicked.addListener(async() =>
{
  const [tab] = await browser.tabs.query({active: true});
  const currentPage = new ext.Page(tab);

  let message = null;
  if (/^https?:$/.test(currentPage.url.protocol))
  {
    const isAllowlisted = await ewe_api.filters.isResourceAllowlisted(
      currentPage.url,
      "document",
      currentPage.id
    );
    message = {
      type: "app.respond",
      action: "showPageOptions",
      args: [
        {
          host: currentPage.url.hostname.replace(/^www\./, ""),
          allowlisted: isAllowlisted
        }
      ]
    };
  }

  await showOptions(message);
});

/**
 * Opens the options page in a new tab and waits for it to load, or switches to
 * the existing tab if the options page is already open.
 *
 * @event "options.open"
 */
messaging_port/* port.on */.N.on("options.open", async(message, sender) =>
{
  await showOptions();
});

// EXTERNAL MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/messaging/types.js
var types = __webpack_require__(3242);
;// CONCATENATED MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/requestBlocker.js
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module requestBlocker */



let filterTypes = new Set(function*()
{
  for (let type of ewe_api.reporting.contentTypesMap.values())
    yield type.toUpperCase();

  yield "SNIPPET";
}());

;// CONCATENATED MODULE: ./vendor/adblockplusui/adblockpluschrome/lib/filterConfiguration.js
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */










const disabledFilterCounters = new Map();
const eventEmitter = new lib_events/* EventEmitter */.v();

async function addFilter(filterText, origin)
{
  const data = {created: Date.now()};
  if (origin)
    data.origin = origin;

  try
  {
    await ewe_api.filters.add([filterText], data);
    await ewe_api.filters.enable([filterText]);
  }
  catch (ex)
  {
    // If we add an existing filter again, we ignore the resulting error to
    // avoid showing unnecessary error messages to the user
    if (ex.type !== "storage_duplicate_filters")
      return ex;
  }

  return null;
}

async function addSubscription(details)
{
  try
  {
    await ewe_api.subscriptions.add(details.url, details);
    await ewe_api.subscriptions.sync(details.url);
  }
  catch (ex)
  {
    return false;
  }

  return true;
}

/**
 * Asks user to confirm the subscription details before it is added.
 * @param {Object} details
 */
async function askConfirmSubscription(details)
{
  await showOptions({
    type: "app.respond",
    action: "addSubscription",
    args: [{
      homepage: details.homepage || null,
      title: details.title || null,
      url: details.url
    }]
  });
}

function parseFilter(text)
{
  let filterText = text.trim() || null;
  let error = null;

  if (filterText)
  {
    if (filterText[0] == "[")
    {
      error = {type: "unexpected_filter_list_header"};
    }
    else
    {
      let filterError = ewe_api.filters.validate(filterText);
      if (filterError)
        error = (0,types/* toPlainFilterError */.U_)(filterError);
    }
  }

  return [filterText, error];
}

/**
 * Attempts to add the given filter, or returns an error.
 *
 * @event "filters.add"
 * @property {string} [origin] - Where the filter originated from
 * @property {string} text - The filter text to add
 * @returns {FilterError[]}
 */
messaging_port/* port.on */.N.on("filters.add", (message, sender) =>
{
  return filtersAdd(message.text, message.origin);
});

/**
 * Returns a serialized version of all filters in special subscriptions.
 *
 * @event "filters.get"
 * @returns {object[]}
 */
messaging_port/* port.on */.N.on("filters.get", async(message, sender) =>
{
  let filters = await ewe_api.filters.getUserFilters();
  return filters.map(types/* toPlainFilter */.ot);
});

/**
 * Returns the available filter types, e.g. "FONT", "WEBSOCKET", etc.
 *
 * @event "filters.getTypes"
 * @returns {string[]}
 */
messaging_port/* port.on */.N.on("filters.getTypes", (message, sender) => Array.from(filterTypes));

/**
 * Import the given block of filter text as custom user filters.
 *
 * @event "filters.importRaw"
 * @property {string} [origin]
 *   Where the filter originated from.
 * @property {string} text
 *   The filters to add.
 * @returns {string[]} errors
 */
messaging_port/* port.on */.N.on("filters.importRaw", async(message, sender) =>
{
  let [filterTexts, errors] = filtersValidate(message.text);

  if (errors.length == 0)
  {
    for (const filterText of filterTexts)
    {
      const error = await addFilter(filterText, message.origin);
      if (error)
        errors.push(error);
    }
  }

  return errors;
});

/**
 * Remove the given filter.
 *
 * @event "filters.remove"
 * @property {string} text
 *   The text of the filter to remove.
 * @property {string} [subscriptionUrl]
 *   The URL of the subscription to remove the filter from, defaults to all
 *   subscriptions.
 * @property {number} [index]
 *   The index of the filter in the given subscription to remove, defaults to
 *   all instances and ignored if subscriptionUrl isn't given.
 * @returns {string[]} errors
 */
messaging_port/* port.on */.N.on("filters.remove", (message, sender) => filtersRemove(message));

/**
 * Replaces one custom user filter with another.
 *
 * @event "filters.replace"
 * @property {string} new - The new filter text to add.
 * @property {string} old - The old filter text to remove.
 * @property {string} [origin] - Where the filter originated from.
 * @returns {string[]} errors
 */
messaging_port/* port.on */.N.on("filters.replace", async(message, sender) =>
{
  let errors = await filtersAdd(message.new, message.origin);
  if (errors.length)
    return errors;
  await filtersRemove({text: message.old});
  return [];
});

/**
 * Enabled or disables the given filter.
 *
 * @event "filters.toggle"
 * @property {string} text - The filter text.
 * @property {boolean} disabled - True to disable the filter, false to enable.
 */
messaging_port/* port.on */.N.on("filters.toggle", async(message, sender) =>
{
  if (message.disabled)
    await ewe_api.filters.disable([message.text]);
  else
    await ewe_api.filters.enable([message.text]);
});

/**
 * Validates the filters inside the given block of filter text.
 *
 * @event "filters.validate"
 * @property {string} text - The filters to validate
 * @returns {string[]} errors
 */
messaging_port/* port.on */.N.on("filters.validate", (message, sender) =>
{
  let [, errors] = filtersValidate(message.text);
  return errors;
});

/**
 * Adds a subscription, either in the background or with the user's
 * confirmation.
 *
 * @event "subscriptions.add"
 * @property {string} url
 *   The subscription's URL.
 * @property {boolean} confirm
 *   If true the user will first be asked to confirm the subscription's details
 *   before it is added.
 * @property {string} [title]
 *   The subscription's title.
 * @property {string} [homepage]
 *   The subscription's homepage.
 * @returns {?boolean}
 *   true if the subscription was added, false if the URL is invalid,
 *   null if the "confirm" property was set
 */
messaging_port/* port.on */.N.on("subscriptions.add", async(message, sender) =>
{
  if (message.confirm)
  {
    askConfirmSubscription({
      homepage: message.homepage,
      title: message.title,
      url: message.url
    });
    return null;
  }

  return addSubscription(message);
});

ewe_api.reporting.onSubscribeLinkClicked.addListener(message =>
{
  askConfirmSubscription({
    title: message.title,
    url: message.url
  });
});

/**
 * Enables all filters from the given subscription.
 *
 * @event "subscriptions.enableAllFilters"
 * @property {string} url
 *   The subscription's URL.
 */
messaging_port/* port.on */.N.on("subscriptions.enableAllFilters", async(message, sender) =>
{
  const filters = await ewe_api.subscriptions.getFilters(message.url);
  const filterTexts = filters.map(filter => filter.text);
  await ewe_api.filters.enable(filterTexts);
});

/**
 * Returns a serialized version of all downloadable subscriptions which meet
 * the given criteria. Optionally include the disabled filters for those
 * subscriptions.
 *
 * @event "subscriptions.get"
 * @property {boolean} ignoreDisabled
 *   Skip disabled subscriptions if true.
 * @property {boolean} disabledFilters
 *   Include a subscription's disabled filters if true.
 * @returns {object[]} subscriptions
 */
messaging_port/* port.on */.N.on("subscriptions.get", async(message, sender) =>
{
  let subscriptions = [];
  for (let s of await ewe_api.subscriptions.getDownloadable())
  {
    if (message.ignoreDisabled && !s.enabled)
      continue;

    let subscription = (0,types/* toPlainSubscription */.LC)(s);
    if (message.disabledFilters)
    {
      let filters = await ewe_api.subscriptions.getFilters(s.url) || [];
      subscription.disabledFilters = filters
        .filter(f => f.enabled === false)
        .map(f => f.text);
    }
    subscriptions.push(subscription);
  }
  return subscriptions;
});

/**
 * Returns the amount of disabled filters contained in a subscription.
 *
 * @event "subscriptions.getDisabledFilterCount"
 * @property {string} url - The subscription's URL.
 */
messaging_port/* port.on */.N.on("subscriptions.getDisabledFilterCount", (message, sender) =>
{
  return disabledFilterCounters.get(message.url) || 0;
});

/**
 * Returns a list of serialised recommended subscriptions for the user.
 *
 * @event "subscriptions.getRecommendations"
 * @returns {object[]} recommendedSubscriptions
 */
messaging_port/* port.on */.N.on("subscriptions.getRecommendations", async(message, sender) =>
{
  const recommendations = await ewe_api.subscriptions.getRecommendations();
  return Array.from(recommendations, types/* toPlainRecommendation */.N);
});

/**
 * Remove the given subscription if it exists.
 *
 * @event "subscriptions.remove"
 * @property {string} url - The subscription's URL.
 */
messaging_port/* port.on */.N.on("subscriptions.remove", async(message, sender) =>
{
  await ewe_api.subscriptions.remove(message.url);
});

/**
 * Toggles a subscription by either enabling/disabling, or by adding/removing
 * it.
 *
 * @event "subscriptions.toggle"
 * @property {string} url
 *   The subscription's URL.
 * @property {boolean} keepInstalled
 *   If true enable/disable the subscription, otherwise add/remove.
 * @returns {boolean}
 *   true if the subscription was toggled successfully,
 *   false if it's a new subscription with an invalid URL
 */
messaging_port/* port.on */.N.on("subscriptions.toggle", async(message, sender) =>
{
  if (await ewe_api.subscriptions.has(message.url))
  {
    let subscription;
    for (let s of await ewe_api.subscriptions.getDownloadable())
    {
      if (s.url == message.url)
      {
        subscription = s;
        break;
      }
    }

    if (subscription)
    {
      if (!subscription.enabled || message.keepInstalled)
      {
        if (subscription.enabled)
          await ewe_api.subscriptions.disable(message.url);
        else
          await ewe_api.subscriptions.enable(message.url);
      }
      else
      {
        await ewe_api.subscriptions.remove(subscription.url);
      }
      return true;
    }
  }

  return addSubscription(message);
});

/**
 * Trigger either the given subscription, or all subscriptions, to update.
 *
 * @event "subscriptions.update"
 * @property {string} [url]
 *   The subscription to update, if not specified all subscriptions will be
 *   updated.
 */
messaging_port/* port.on */.N.on("subscriptions.update", async(message, sender) =>
{
  await ewe_api.subscriptions.sync(message.url);
});

async function filtersAdd(text, origin)
{
  let [filterText, error] = parseFilter(text);

  if (!error && filterText)
    error = await addFilter(filterText, origin);

  return (error) ? [error] : [];
}

function filtersValidate(text)
{
  let filterTexts = [];
  let errors = [];

  let lines = text.split("\n");
  for (let i = 0; i < lines.length; i++)
  {
    let [filterText, error] = parseFilter(lines[i]);

    if (error)
    {
      // We don't treat filter headers like invalid filters,
      // instead we simply ignore them and don't show any errors
      // in order to allow pasting complete filter lists.
      // If there are no filters, we do treat it as an invalid filter
      // to inform users about it and to give them a chance to edit it.
      if (error.type === "unexpected_filter_list_header" &&
          lines.length > 1)
        continue;

      if (lines.length > 1)
        error.lineno = i + 1;

      errors.push(error);
    }
    else if (filterText)
    {
      filterTexts.push(filterText);
    }
  }

  return [filterTexts, errors];
}

async function filtersRemove(message)
{
  await ewe_api.filters.remove([message.text]);
  // in order to behave, from consumer perspective, like any other
  // method that could produce errors, return an Array, even if empty
  return [];
}

async function initDisabledFilterCounters()
{
  for (const subscription of await ewe.subscriptions.getDownloadable())
  {
    let count = 0;

    for (const filter of await ewe.subscriptions.getFilters(subscription.url))
    {
      if (filter.enabled === false)
        count++;
    }

    if (count > 0)
    {
      disabledFilterCounters.set(subscription.url, count);
      // Core doesn't expose the subscription's disabled filters state
      // and to avoid adding new "loaded" events and behavior around it,
      // we emit a "filtersDisabled" event to trigger UI changes
      eventEmitter.emit(
        "filtersDisabled",
        subscription,
        true,
        true
      );
    }
  }
}

async function updateCounters(filterText, enabled)
{
  for (const subscription of await ewe_api.subscriptions.getForFilter(filterText))
  {
    const oldCount = disabledFilterCounters.get(subscription.url) || 0;
    const newCount = (enabled) ? oldCount - 1 : oldCount + 1;

    if (newCount === 0)
      disabledFilterCounters.delete(subscription.url);
    else
      disabledFilterCounters.set(subscription.url, newCount);

    if (oldCount === 0 || newCount === 0)
    {
      eventEmitter.emit(
        "filtersDisabled",
        subscription,
        newCount > 0,
        oldCount > 0
      );
    }
  }
}

ewe_api.filters.onChanged.addListener(async(filter, property) =>
{
  if (property !== "enabled")
    return;

  await updateCounters(filter.text, filter.enabled);
});

ewe_api.subscriptions.onRemoved.addListener(subscription =>
{
  disabledFilterCounters.delete(subscription.url);
});

emitter.on("deactivated", async() =>
{
  const recommendations = await ewe_api.subscriptions.getRecommendations();
  for (const recommendation of recommendations)
  {
    if (recommendation.type !== "annoyances")
      continue;

    if (!(await ewe_api.subscriptions.has(recommendation.url)))
      break;

    await ewe_api.subscriptions.remove(recommendation.url);
    break;
  }
});

(0,events/* installHandler */.a)("filters", "added", emit =>
{
  const onAdded = filter => emit((0,types/* toPlainFilter */.ot)(filter));
  ewe_api.filters.onAdded.addListener(onAdded);
  return () => ewe_api.filters.onAdded.removeListener(onAdded);
});

(0,events/* installHandler */.a)("filters", "changed", emit =>
{
  const onChanged = (filter, property) => emit((0,types/* toPlainFilter */.ot)(filter), property);
  ewe_api.filters.onChanged.addListener(onChanged);
  return () => ewe_api.filters.onChanged.removeListener(onChanged);
});

(0,events/* installHandler */.a)("filters", "removed", emit =>
{
  const onRemoved = filter => emit((0,types/* toPlainFilter */.ot)(filter));
  ewe_api.filters.onRemoved.addListener(onRemoved);
  return () => ewe_api.filters.onRemoved.removeListener(onRemoved);
});

(0,events/* installHandler */.a)("subscriptions", "added", emit =>
{
  const onAdded = subscription => emit((0,types/* toPlainSubscription */.LC)(subscription));
  ewe_api.subscriptions.onAdded.addListener(onAdded);
  return () => ewe_api.subscriptions.onAdded.removeListener(onAdded);
});

(0,events/* installHandler */.a)("subscriptions", "changed", emit =>
{
  const onChanged = (subscription, property) =>
  {
    emit((0,types/* toPlainSubscription */.LC)(subscription), property);
  };
  ewe_api.subscriptions.onChanged.addListener(onChanged);
  return () => ewe_api.subscriptions.onChanged.removeListener(onChanged);
});

(0,events/* installHandler */.a)("subscriptions", "filtersDisabled", emit =>
{
  const onFiltersDisabled = (subscription, hadFilters, hasFilters) =>
  {
    emit((0,types/* toPlainSubscription */.LC)(subscription), hadFilters, hasFilters);
  };
  eventEmitter.on("filtersDisabled", onFiltersDisabled);
  return () => eventEmitter.off("filtersDisabled", onFiltersDisabled);
});

(0,events/* installHandler */.a)("subscriptions", "removed", emit =>
{
  const onRemoved = subscription => emit((0,types/* toPlainSubscription */.LC)(subscription));
  ewe_api.subscriptions.onRemoved.addListener(onRemoved);
  return () => ewe_api.subscriptions.onRemoved.removeListener(onRemoved);
});


/***/ }),

/***/ 7434:
/***/ ((__unused_webpack___webpack_module__, __unused_webpack___webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony import */ var info__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4043);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3817);
/* harmony import */ var _messaging_port_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4554);
/* harmony import */ var _prefs_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8710);
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module messageResponder */







function forward(type, message, sender)
{
  return _messaging_port_js__WEBPACK_IMPORTED_MODULE_2__/* .port._onMessage */ .N._onMessage(Object.assign({}, message, {type}), sender);
}

/**
 * @deprecated Please send the "filters.getTypes" message instead.
 *
 * @event "types.get"
 */
_messaging_port_js__WEBPACK_IMPORTED_MODULE_2__/* .port.on */ .N.on("types.get",
        (message, sender) => forward("filters.getTypes", message, sender));

/**
 * @deprecated Please send the "options.open" message instead.
 *
 * @event "app.open"
 */
_messaging_port_js__WEBPACK_IMPORTED_MODULE_2__/* .port.on */ .N.on("app.open", (message, sender) =>
{
  if (message.what == "options")
    return forward("options.open", message, sender);
});

/**
 * @deprecated Please send the "subscriptions.getInitIssues",
 *             "prefs.getDocLink", "subscriptions.getRecommendations",
 *             "devtools.supported" or "info.get" messages, or call the
 *             browser.tabs.getCurrent(), browser.i18n.getUILanguage(),
 *             browser.i18n.getMessage("@@bidi_dir") APIs instead.
 *
 * @event "app.get"
 */
_messaging_port_js__WEBPACK_IMPORTED_MODULE_2__/* .port.on */ .N.on("app.get", async(message, sender) =>
{
  if (message.what == "localeInfo")
  {
    return {
      locale: browser.i18n.getUILanguage(),
      bidiDir: browser.i18n.getMessage("@@bidi_dir")
    };
  }

  if (message.what == "acceptableAdsUrl")
    return _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_1__.subscriptions.ACCEPTABLE_ADS_URL;

  if (message.what == "acceptableAdsPrivacyUrl")
    return _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_1__.subscriptions.ACCEPTABLE_ADS_PRIVACY_URL;

  if (message.what == "senderId")
    return sender.page.id;

  if (message.what == "ctalink")
  {
    const ctaLinkNameToPrefsMap = new Map([
      ["premium-manage", "premium_manage_page_url"],
      ["premium-upgrade", "premium_upgrade_page_url"]
    ]);

    const {link: ctaLinkName, queryParams} = message;
    const prefsUrlKey = ctaLinkNameToPrefsMap.get(ctaLinkName);
    let url = _prefs_js__WEBPACK_IMPORTED_MODULE_3__/* .Prefs */ .B[prefsUrlKey];

    const linkPlaceholders = [
      ["LANG", () => browser.i18n.getUILanguage().replace("-", "_")],
      ["ADDON_NAME", () => info__WEBPACK_IMPORTED_MODULE_0__.addonName],
      ["ADDON_VERSION", () => info__WEBPACK_IMPORTED_MODULE_0__.addonVersion],
      ["APPLICATION_NAME", () => info__WEBPACK_IMPORTED_MODULE_0__.application],
      ["APPLICATION_VERSION", () => info__WEBPACK_IMPORTED_MODULE_0__.applicationVersion],
      ["PLATFORM_NAME", () => info__WEBPACK_IMPORTED_MODULE_0__.platform],
      ["PLATFORM_VERSION", () => info__WEBPACK_IMPORTED_MODULE_0__.platformVersion],
      ["LICENSE_CODE", () => _prefs_js__WEBPACK_IMPORTED_MODULE_3__/* .Prefs.get */ .B.get("premium_license").code],
      ["SOURCE", () => queryParams.source]
    ];

    for (const [key, getValue] of linkPlaceholders)
      url = url.replace(`%${key}%`, encodeURIComponent(getValue()));

    return url;
  }

  if (message.what == "doclink")
    return forward("prefs.getDocLink", message, sender);

  if (message.what == "recommendations")
    return forward("subscriptions.getRecommendations", message, sender);

  if (message.what == "features")
  {
    let devToolsPanel = await forward("devtools.supported", message, sender);
    return {devToolsPanel};
  }

  if (message.what == "os")
  {
    let platformInfo = await browser.runtime.getPlatformInfo();
    return platformInfo.os;
  }

  return info__WEBPACK_IMPORTED_MODULE_0__[message.what];
});

/**
 * @typedef {object} infoGetResult
 * @property {string} addonName
 *   The extension's name, e.g. "adblockpluschrome".
 * @property {string} addonVersion
 *   The extension's version, e.g. "3.6.3".
 * @property {string} application
 *   The browser's name, e.g. "chrome".
 * @property {string} applicationVersion
 *   The browser's version, e.g. "77.0.3865.90".
 * @property {string} platform
 *   The browser platform, e.g. "chromium".
 * @property {string} platformVersion
 *   The browser platform's version, e.g. "77.0.3865.90".
 */

/**
 * Returns the browser platform information.
 *
 * @event "info.get"
 * @returns {infoGetResult}
 */
_messaging_port_js__WEBPACK_IMPORTED_MODULE_2__/* .port.on */ .N.on("info.get", (message, sender) => info__WEBPACK_IMPORTED_MODULE_0__);


/***/ }),

/***/ 2325:
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "a": () => (/* binding */ installHandler)
/* harmony export */ });
/* harmony import */ var _events_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2901);
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */



const cleanupByTabId = new Map();
const eventEmitter = new _events_js__WEBPACK_IMPORTED_MODULE_0__/* .EventEmitter */ .v();
const handlerByName = new Map();
const handlerTemplateByType = new Map();

/**
 * Installs a handler for lazily adding/removing event listeners depending on
 * whether someone is actively listening via the Messaging API.
 *
 * @param {string} type
 *   type of events to allow listening to
 * @param {string} [action]
 *   specific event to allow listening to
 *   null if handler applies to all events for the given type
 * @param {Function} install
 *   callback function for adding event listeners
 *   will receive emit, action, targetTabId as arguments
 *   expected to return callback function for removing event listeners
 */
function installHandler(type, action, install)
{
  const handler = {install, uninstall: null};

  // Handlers that can be used for arbitrary actions should be used as
  // templates, from which we can create handlers later
  if (!action)
  {
    handlerTemplateByType.set(type, handler);
    return;
  }

  handlerByName.set(`${type}.${action}`, handler);
}

function listen(type, actions, uiPort, targetTabId = null)
{
  const cleanups = [];

  for (const action of actions)
  {
    let name = `${type}.${action}`;
    if (targetTabId !== null)
      name = `${name}:${targetTabId}`;

    // Add message response listener
    const onResponse = (...args) =>
    {
      uiPort.postMessage({type: `${type}.respond`, action, args});
    };
    eventEmitter.on(name, onResponse);

    // Install event handler
    let handler = handlerByName.get(name);
    // If there's no handler for the given action, we should check
    // whether there's a generic handler for the type and create one from that
    if (!handler)
    {
      const template = handlerTemplateByType.get(type);
      if (template)
      {
        handler = Object.assign({}, template);
        handlerByName.set(name, handler);
      }
    }
    if (handler && !handler.uninstall)
    {
      const emit = eventEmitter.emit.bind(eventEmitter, name);
      handler.uninstall = handler.install(emit, action, targetTabId);
    }

    cleanups.push(() =>
    {
      eventEmitter.off(name, onResponse);

      // Uninstall event handler, if it's no longer needed
      if (!eventEmitter.hasListeners(name))
      {
        const actionHandler = handlerByName.get(name);
        if (actionHandler && actionHandler.uninstall)
        {
          actionHandler.uninstall();
          handler.uninstall = null;
        }
      }
    });
  }

  const cleanupAll = () =>
  {
    for (const cleanup of cleanups)
      cleanup();
  };

  // Stop listening when port disconnects (e.g. page is closed),
  // or when target tab is closed
  uiPort.onDisconnect.addListener(cleanupAll);
  if (targetTabId !== null)
    cleanupByTabId.set(targetTabId, cleanupAll);
}

function onTabRemoved(tabId)
{
  const cleanup = cleanupByTabId.get(tabId);
  if (!cleanup)
    return;

  cleanup();
  cleanupByTabId.delete(tabId);
}
browser.tabs.onRemoved.addListener(onTabRemoved);

function onConnect(uiPort)
{
  if (!ext.isTrustedSender(uiPort.sender))
    return;

  if (uiPort.name !== "ui")
    return;

  uiPort.onMessage.addListener(message =>
  {
    const [type, action] = message.type.split(".", 2);

    // For now we're only using long-lived connections
    // for handling "*.listen" messages
    // https://issues.adblockplus.org/ticket/6440/
    if (action !== "listen")
      return;

    listen(type, message.filter, uiPort, message.tabId);
  });
}
browser.runtime.onConnect.addListener(onConnect);


/***/ }),

/***/ 4554:
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "N": () => (/* binding */ port)
/* harmony export */ });
/* harmony import */ var _events_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2901);
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */



/**
 * Communication port wrapping ext.onMessage to receive messages.
 *
 * @constructor
 */
class Port
{
  constructor()
  {
    this._eventEmitter = new _events_js__WEBPACK_IMPORTED_MODULE_0__/* .EventEmitter */ .v();
    this._onMessage = this._onMessage.bind(this);
    ext.onMessage.addListener(this._onMessage);
  }

  async _onMessage(message, sender)
  {
    let callbacks = this._eventEmitter.listeners(message.type);

    try
    {
      let responses = callbacks.map(callback => callback(message, sender));
      return ext.getMessageResponse(responses);
    }
    catch (err)
    {
      console.error(err);
    }
  }

  /**
   * Function to be called when a particular message is received.
   *
   * @callback Port~messageCallback
   * @param {object} message
   * @param {object} sender
   * @return The callback can return undefined (no response),
   *         a value (response to be sent to sender immediately)
   *         or a promise (asynchronous response).
   */

  /**
   * Adds a callback for the specified message.
   *
   * The return value of the callback (if not undefined) is sent as response.
   * @param {string}   name
   * @param {Port~messageCallback} callback
   */
  on(name, callback)
  {
    this._eventEmitter.on(name, callback);
  }

  /**
   * Removes a callback for the specified message.
   *
   * @param {string}   name
   * @param {Port~messageCallback} callback
   */
  off(name, callback)
  {
    this._eventEmitter.off(name, callback);
  }

  /**
   * Disables the port and makes it stop listening to incoming messages.
   */
  disconnect()
  {
    ext.onMessage.removeListener(this._onMessage);
  }
}

/**
 * The default port to receive messages.
 *
 * @type {Port}
 */
let port = new Port();


/***/ }),

/***/ 3242:
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "LC": () => (/* binding */ toPlainSubscription),
/* harmony export */   "N": () => (/* binding */ toPlainRecommendation),
/* harmony export */   "Q1": () => (/* binding */ toPlainBlockableItem),
/* harmony export */   "U_": () => (/* binding */ toPlainFilterError),
/* harmony export */   "ot": () => (/* binding */ toPlainFilter)
/* harmony export */ });
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3817);
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */



const requestMethods = new Set([
  "allowing",
  "header",
  "request"
]);

function toPlainBlockableItem({filter, matchInfo, request})
{
  let isFrame = !requestMethods.has(matchInfo.method);

  let type;
  if (matchInfo.method == "request")
    type = _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.reporting.contentTypesMap.get(request.type);
  else if (matchInfo.method == "allowing")
    type = matchInfo.allowingReason;
  // Show matching method when it had an effect on the request
  else if (filter)
    type = matchInfo.method;
  else
    type = _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.reporting.contentTypesMap.get(request.type);

  if (!type)
    type = "other";

  return {
    docDomain: matchInfo.docDomain,
    isFrame,
    rewrittenUrl: matchInfo.rewrittenUrl,
    type: type.toUpperCase(),
    url: request.url
  };
}

function toPlainFilter(filter)
{
  let obj = toPlainObject(
    ["csp", "enabled", "selector", "slow", "text", "type"],
    filter
  );

  // For the time being, we are renaming the enabled property to
  // make the UI compatible with EWE without having to rename it
  // in the UI code itself just yet
  // For the same reason, we're not adding the property for comment filters
  if (obj.enabled !== null)
    obj.disabled = !obj.enabled;
  delete obj.enabled;

  return obj;
}

let toPlainFilterError = toPlainObject.bind(null, [
  "lineno", "option", "reason", "type"
]);

function toPlainObject(keys, obj)
{
  let result = {};
  for (let key of keys)
  {
    if (key in obj)
      result[key] = obj[key];
  }
  return result;
}

function toPlainRecommendation(recommendation)
{
  // The recommendation URL always refers to the one for Manifest v3,
  // so we need to overwrite it for Manifest v2
  if (browser.runtime.getManifest().manifest_version === 2)
    recommendation.url = recommendation.mv2URL;

  return toPlainObject(
    ["languages", "title", "type", "url"],
    recommendation
  );
}

function toPlainSubscription(subscription)
{
  let obj = toPlainObject(
    [
      "downloadable", "downloadStatus", "enabled", "homepage", "version",
      "lastDownload", "lastSuccess", "softExpiration", "expires", "title",
      "url", "downloading"
    ],
    subscription
  );

  // For the time being, we are renaming the enabled property to
  // make the UI compatible with EWE without having to rename it
  // in the UI code itself just yet
  obj.disabled = !obj.enabled;
  delete obj.enabled;

  return obj;
}


/***/ }),

/***/ 8710:
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "B": () => (/* binding */ Prefs)
/* harmony export */ });
/* harmony import */ var info__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4043);
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3817);
/* harmony import */ var _messaging_events_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2325);
/* harmony import */ var _messaging_port_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4554);
/* harmony import */ var _events_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2901);
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module prefs */








const keyPrefix = "pref:";

let eventEmitter = new _events_js__WEBPACK_IMPORTED_MODULE_4__/* .EventEmitter */ .v();
let overrides = Object.create(null);

/** @lends module:prefs.Prefs */
let defaults = Object.create(null);

/**
 * The application version as set during initialization. Used to detect updates.
 *
 * @type {string}
 */
defaults.currentVersion = "";
/**
 * @see https://adblockplus.org/en/preferences#documentation_link
 * @type {string}
 */
defaults.documentation_link = "https://adblockplus.org/redirect?link=%LINK%&lang=%LANG%";
/**
 * The total number of requests blocked by the extension.
 *
 * @type {number}
 */
defaults.blocked_total = 0;
/**
 * Whether to show a badge in the toolbar icon indicating the number
 * of blocked ads.
 *
 * @type {boolean}
 */
defaults.show_statsinicon = true;
/**
 * Whether to show the "Block element" context menu entry.
 *
 * @type {boolean}
 */
defaults.shouldShowBlockElementMenu = true;

/**
 * Whether to show tracking warning in options page when both
 * Acceptable Ads and subscription of type "Privacy" are enabled.
 *
 * @type {boolean}
 */
defaults.ui_warn_tracking = true;

/**
 * Whether to show the developer tools panel.
 *
 * @type {boolean}
 */
defaults.show_devtools_panel = true;

/**
 * Prevents unsolicited UI elements from showing up after installation. This
 * preference isn't set by the extension but can be pre-configured externally.
 *
 * @see https://adblockplus.org/development-builds/suppressing-the-first-run-page-on-chrome
 * @type {boolean}
 */
defaults.suppress_first_run_page = false;

/**
 * Additonal subscriptions to be automatically added when the extension is
 * loaded. This preference isn't set by the extension but can be pre-configured
 * externally.
 *
 * @type {string[]}
 */
defaults.additional_subscriptions = [];

/**
 * The version of major updates that the user is aware of. If it's too low,
 * the updates page will be shown to inform the user about intermediate changes.
 *
 * @type {number}
 */
defaults.last_updates_page_displayed = 0;

/**
 * Causes elements targeted by element hiding (and element hiding emulation)
 * to be highlighted instead of hidden.
 *
 * @type {boolean}
 */
defaults.elemhide_debug = false;

/**
 * Address of page to open on first run.
 *
 * @type {string}
 */
defaults.remote_first_run_page_url = "https://welcome.adblockplus.org/%LANG%/installed?an=%ADDON_NAME%&av=%ADDON_VERSION%&ap=%APPLICATION_NAME%&apv=%APPLICATION_VERSION%&p=%PLATFORM_NAME%&pv=%PLATFORM_VERSION%";

/**
 * Whether to recommend language filter lists to user.
 *
 * @type {boolean}
 */
defaults.recommend_language_subscriptions = false;

/**
 * Premium license
 *
 * @type {object}
 */
defaults.premium_license = {
  lv: 1,
  code: "",
  status: "expired"
};

/**
 * Origin of page to activate Premium license.
 *
 * @type {string}
 */
defaults.premium_license_activation_origin = "https://accounts.adblockplus.org";

/**
 * Timestamp indicating when to attempt the next Premium license check.
 *
 * @type {number}
 */
defaults.premium_license_nextcheck = 0;

/**
 * Premium license check API endpoint
 *
 * @type {string}
 */
defaults.premium_license_check_url = "https://myadblock.licensing.adblockplus.dev/license";

/**
 * Address of page to manage Premium account.
 *
 * @type {string}
 */
defaults.premium_manage_page_url = "https://accounts.adblockplus.org/%LANG%/manage?lic=%LICENSE_CODE%&s=%SOURCE%";

/**
 * Address of page to upgrade to Premium.
 *
 * @type {string}
 */
defaults.premium_upgrade_page_url = "https://accounts.adblockplus.org/%LANG%/premium?an=%ADDON_NAME%&av=%ADDON_VERSION%&ap=%APPLICATION_NAME%&apv=%APPLICATION_VERSION%&p=%PLATFORM_NAME%&pv=%PLATFORM_VERSION%&s=%SOURCE%";

/**
 * Premium user ID
 *
 * @type {string}
 */
defaults.premium_user_id = "";

/**
  * @namespace
  * @static
  */
let Prefs = {
  /**
   * Retrieves the given preference.
   *
   * @param {string} preference
   * @return {any}
   */
  get(preference)
  {
    return (preference in overrides ? overrides : defaults)[preference];
  },

  /**
   * Resets the given preference to its default value.
   *
   * @param {string} preference
   * @return {Promise} A promise that resolves when the underlying
                       browser.storage.local.set/remove() operation completes
   */
  reset(preference)
  {
    return Prefs.set(preference, defaults[preference]);
  },

  /**
   * Sets the given preference.
   *
   * @param {string} preference
   * @param {any}    value
   * @return {Promise} A promise that resolves when the underlying
                       browser.storage.local.set/remove() operation completes
   */
  set(preference, value)
  {
    let defaultValue = defaults[preference];

    if (typeof value != typeof defaultValue)
      throw new Error("Attempt to change preference type");

    if (value == defaultValue)
    {
      let oldValue = overrides[preference];
      delete overrides[preference];

      // Firefox 66 fails to emit storage.local.onChanged events for falsey
      // values. https://bugzilla.mozilla.org/show_bug.cgi?id=1541449
      if (!oldValue &&
          info__WEBPACK_IMPORTED_MODULE_0__.platform == "gecko" && parseInt(info__WEBPACK_IMPORTED_MODULE_0__.platformVersion, 10) == 66)
        onStorageChanged({[prefToKey(preference)]: {oldValue}}, "local");

      return browser.storage.local.remove(prefToKey(preference));
    }

    overrides[preference] = value;
    return (customSave.get(preference) || savePref)(preference);
  },

  /**
   * Adds a callback that is called when the
   * value of a specified preference changed.
   *
   * @param {string}   preference
   * @param {function} callback
   */
  on(preference, callback)
  {
    eventEmitter.on(preference, callback);
  },

  /**
   * Removes a callback for the specified preference.
   *
   * @param {string}   preference
   * @param {function} callback
   */
  off(preference, callback)
  {
    eventEmitter.off(preference, callback);
  },

  /**
   * Reads the documentation_link preference and substitutes placeholders.
   *
   * @param {string} linkID
   * @return {string}
   */
  getDocLink(linkID)
  {
    return this.documentation_link
      .replace(/%LINK%/g, linkID)
      .replace(/%LANG%/g, browser.i18n.getUILanguage());
  },

  /**
   * A promise that is fullfilled when all preferences have been loaded.
   * Wait for this promise to be fulfilled before using preferences during
   * extension initialization.
   *
   * @type {Promise}
   */
  untilLoaded: null
};

function keyToPref(key)
{
  if (key.indexOf(keyPrefix) != 0)
    return null;

  return key.substr(keyPrefix.length);
}

function prefToKey(pref)
{
  return keyPrefix + pref;
}

function savePref(pref)
{
  return browser.storage.local.set({[prefToKey(pref)]: overrides[pref]});
}

let customSave = new Map();
if (info__WEBPACK_IMPORTED_MODULE_0__.platform == "gecko" && parseInt(info__WEBPACK_IMPORTED_MODULE_0__.platformVersion, 10) < 66)
{
  // Saving one storage value causes all others to be saved as well for
  // Firefox versions <66. Make sure that updating ad counter doesn't cause
  // the filters data to be saved frequently as a side-effect.
  let promise = null;
  customSave.set("blocked_total", pref =>
  {
    if (!promise)
    {
      promise = new Promise((resolve, reject) =>
      {
        setTimeout(
          () =>
          {
            promise = null;
            savePref(pref).then(resolve, reject);
          },
          60 * 1000
        );
      });
    }
    return promise;
  });
}

function addPreference(pref)
{
  Object.defineProperty(Prefs, pref, {
    get()
    {
      return Prefs.get(pref);
    },
    set(value)
    {
      Prefs.set(pref, value);
    },
    enumerable: true
  });
}

function onStorageChanged(changes)
{
  for (let key in changes)
  {
    let pref = keyToPref(key);
    if (pref && pref in defaults)
    {
      let change = changes[key];
      if ("newValue" in change && change.newValue != defaults[pref])
        overrides[pref] = change.newValue;
      else
        delete overrides[pref];

      eventEmitter.emit(pref);
    }
  }
}

async function init()
{
  let prefs = Object.keys(defaults);
  prefs.forEach(addPreference);

  let isEdgeChromium = info__WEBPACK_IMPORTED_MODULE_0__.application == "edge" &&
                       info__WEBPACK_IMPORTED_MODULE_0__.platform == "chromium";

  // When upgrading from EdgeHTML to Edge Chromium (v79) data stored in
  // browser.storage.local gets corrupted.
  // To fix it, we have to call JSON.parse twice.
  // See: https://gitlab.com/eyeo/adblockplus/adblockpluschrome/issues/152
  if (isEdgeChromium)
  {
    let items = await browser.storage.local.get(null);

    let fixedItems = {};
    for (let key in items)
    {
      if (typeof items[key] == "string")
      {
        try
        {
          fixedItems[key] = JSON.parse(JSON.parse(items[key]));
        }
        catch (e) {}
      }
    }

    await browser.storage.local.set(fixedItems);
  }

  {
    let items = await browser.storage.local.get(prefs.map(prefToKey));
    for (let key in items)
      overrides[keyToPref(key)] = items[key];
  }

  if ("managed" in browser.storage)
  {
    try
    {
      let items = await browser.storage.managed.get(null);
      for (let key in items)
        defaults[key] = items[key];
    }
    catch (e)
    {
      // Opera doesn't support browser.storage.managed, but instead of simply
      // removing the API, it gives an asynchronous error which we ignore here.
    }
  }

  browser.storage.onChanged.addListener(onStorageChanged);

  // Initialize notifications_ignoredcategories pseudo preference
  Object.defineProperty(Prefs, "notifications_ignoredcategories", {
    get()
    {
      return _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_1__.notifications.getIgnoredCategories();
    },
    set(value)
    {
      _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_1__.notifications.toggleIgnoreCategory("*", !!value);
    },
    enumerable: true
  });

  _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_1__.notifications.on(
    "ignored-category-added",
    () => eventEmitter.emit("notifications_ignoredcategories")
  );
  _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_1__.notifications.on(
    "ignored-category-removed",
    () => eventEmitter.emit("notifications_ignoredcategories")
  );
}

Prefs.untilLoaded = init();

/**
 * Returns the value of the given preference key.
 *
 * @event "prefs.get"
 * @property {string} key - The preference key.
 * @returns {string|string[]|number|boolean}
 */
_messaging_port_js__WEBPACK_IMPORTED_MODULE_3__/* .port.on */ .N.on("prefs.get", (message, sender) => Prefs[message.key]);

/**
 * Sets the value of the given preference key to the given value.
 *
 * @event "prefs.set"
 * @property {string} key - The preference key.
 * @property {string} value - The value to set.
 * @returns {string|string[]|number|boolean|undefined}
 */
_messaging_port_js__WEBPACK_IMPORTED_MODULE_3__/* .port.on */ .N.on(
  "prefs.set",
  async(message, sender) => Prefs[message.key] = message.value
);

/**
 * Toggles the value of the given preference key.
 *
 * @event "prefs.toggle"
 * @property {string} key - The preference key
 * @returns {?boolean}
 */
_messaging_port_js__WEBPACK_IMPORTED_MODULE_3__/* .port.on */ .N.on("prefs.toggle", async(message, sender) =>
{
  if (message.key == "notifications_ignoredcategories")
    return _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_1__.notifications.toggleIgnoreCategory("*");

  return Prefs[message.key] = !Prefs[message.key];
});

/**
 * Returns a link to a page on our website, in the user's locale if possible.
 *
 * @event "prefs.getDocLink"
 * @property {string} link
 *   The link ID to generate the doc link for.
 * @returns {string}
 */
_messaging_port_js__WEBPACK_IMPORTED_MODULE_3__/* .port.on */ .N.on("prefs.getDocLink", (message, sender) =>
{
  let {application, platform} = info__WEBPACK_IMPORTED_MODULE_0__;
  if (platform == "chromium" && application != "opera" && application != "edge")
    application = "chrome";
  else if (platform == "gecko")
    application = "firefox";

  return Prefs.getDocLink(message.link.replace("{browser}", application));
});

(0,_messaging_events_js__WEBPACK_IMPORTED_MODULE_2__/* .installHandler */ .a)("prefs", null, (emit, action) =>
{
  const onChanged = () => emit(Prefs[action]);
  Prefs.on(action, onChanged);
  return () => Prefs.off(action, onChanged);
});


/***/ }),

/***/ 9892:
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "G": () => (/* binding */ getBlockedPerPage),
/* harmony export */   "j": () => (/* binding */ Stats)
/* harmony export */ });
/* harmony import */ var _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3817);
/* harmony import */ var _messaging_events_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2325);
/* harmony import */ var _messaging_port_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4554);
/* harmony import */ var _storage_tab_session_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1627);
/* harmony import */ var _browserAction_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(3265);
/* harmony import */ var _events_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(2901);
/* harmony import */ var _prefs_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(8710);
/* harmony import */ var _src_core_scheduled_event_emitter_background_scheduled_event_emitter_ts__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(6650);
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/** @module stats */










const badgeColor = "#646464";
const badgeRefreshRate = 4;
const badgeUpdateTopic = "stats.badgeUpdate";

let eventEmitter = new _events_js__WEBPACK_IMPORTED_MODULE_7__/* .EventEmitter */ .v();
let blockedPerPage = new _storage_tab_session_js__WEBPACK_IMPORTED_MODULE_3__/* .TabSessionStorage */ .H("stats:blocked");

/**
 * Gets the number of requests blocked on the given page.
 *
 * @param  {Page} page
 * @return {Number}
 */
async function getBlockedPerPage(page)
{
  return (await blockedPerPage.get(page.id)) || 0;
}

let activeTabIds = new Set();
let activeTabIdByWindowId = new Map();

let badgeUpdateScheduled = false;

async function updateBadge(tabId)
{
  if (!_prefs_js__WEBPACK_IMPORTED_MODULE_5__/* .Prefs.show_statsinicon */ .B.show_statsinicon)
    return;

  for (let id of (typeof tabId == "undefined" ? activeTabIds : [tabId]))
  {
    let blockedCount = await blockedPerPage.get(id);

    (0,_browserAction_js__WEBPACK_IMPORTED_MODULE_4__/* .setBadge */ .q_)(id, blockedCount && {
      color: badgeColor,
      number: blockedCount
    });
  }
}

function scheduleBadgeUpdate(tabId)
{
  if (!badgeUpdateScheduled && _prefs_js__WEBPACK_IMPORTED_MODULE_5__/* .Prefs.show_statsinicon */ .B.show_statsinicon &&
      (typeof tabId == "undefined" || activeTabIds.has(tabId)))
  {
    _src_core_scheduled_event_emitter_background_scheduled_event_emitter_ts__WEBPACK_IMPORTED_MODULE_6__/* .setSchedule */ .U3(
      badgeUpdateTopic,
      1000 / badgeRefreshRate
    );
    badgeUpdateScheduled = true;
  }
}

_src_core_scheduled_event_emitter_background_scheduled_event_emitter_ts__WEBPACK_IMPORTED_MODULE_6__/* .setListener */ .MU(badgeUpdateTopic, async() =>
{
  badgeUpdateScheduled = false;
  await updateBadge();
});

// Once nagivation for the tab has been committed to (e.g. it's no longer
// being prerendered) we clear its badge, or if some requests were already
// blocked beforehand we display those on the badge now.
browser.webNavigation.onCommitted.addListener(async details =>
{
  if (details.frameId == 0)
    await updateBadge(details.tabId);
});

async function onBlockableItem({filter, request})
{
  if (!filter || filter.type != "blocking")
    return;

  let {tabId} = request;

  let blocked = await blockedPerPage.get(tabId) || 0;
  ++blocked;

  await blockedPerPage.set(tabId, blocked);
  scheduleBadgeUpdate(tabId);

  eventEmitter.emit("blocked_per_page", {tabId, blocked});

  // Don't update the total for incognito tabs.
  let tab = await browser.tabs.get(tabId);
  if (tab.incognito)
    return;

  // Make sure blocked_total is only read after the storage was loaded.
  await _prefs_js__WEBPACK_IMPORTED_MODULE_5__/* .Prefs.untilLoaded */ .B.untilLoaded;

  _prefs_js__WEBPACK_IMPORTED_MODULE_5__/* .Prefs.blocked_total */ .B.blocked_total++;
  eventEmitter.emit("blocked_total", _prefs_js__WEBPACK_IMPORTED_MODULE_5__/* .Prefs.blocked_total */ .B.blocked_total);
}

/**
 * Checks request errors for requests blocked by client and, if appropriate,
 * calls the function to update the block counter.
 *
 * Note that we cannot distinguish whether the request was blocked by us or
 * another extension.
 *
 * This is only here as a temporary workaround until
 * ewe.reporting.onBlockableItem works properly in MV3.
 *
 * See https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/webRequest/onErrorOccurred#details_2
 * for a type definition of the `details` object.
 *
 * @param {object} details The network error details
 */
async function handleRequestError({error, frameId, tabId, type, url})
{
  // Only check request errors inside of browser tabs, and only of
  // the `net::ERR_BLOCKED_BY_CLIENT` type.
  // NOTE: The error name "net::ERR_BLOCKED_BY_CLIENT" exists only in Chromium!
  if (
    tabId === browser.tabs.TAB_ID_NONE ||
    error !== "net::ERR_BLOCKED_BY_CLIENT"
  )
    return;

  // Ignore if request is allowlisted.
  const isAllowlisted = await _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.filters.isResourceAllowlisted(
    url,
    _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.reporting.contentTypesMap.get(type),
    tabId,
    frameId
  );
  if (isAllowlisted)
    return;

  // Call `onBlockableItem` and feed it data in a structure it can consume.
  void onBlockableItem({
    filter: {
      type: "blocking"
    },
    request: {
      tabId
    }
  });
}

// In the MV3 version, ewe.reporting.onBlockableItem doesn't yet report
// blocked items.
// Until ewe.reporting.onBlockableItem works correctly with MV3, we count
// every request that was blocked. However, we cannot distinguish whether the
// request was blocked by us or another extension.
if (browser.runtime.getManifest().manifest_version === 3)
{
  browser.webRequest.onErrorOccurred.addListener(
    handleRequestError,
    {urls: ["<all_urls>"]}
  );
}
else
{
  _vendor_webext_sdk_dist_ewe_api_js__WEBPACK_IMPORTED_MODULE_0__.reporting.onBlockableItem.addListener(onBlockableItem);
}

/**
  * @namespace
  * @static
  */
let Stats = {
  /**
   * Adds a callback that is called when the
   * value of a specified stat changed.
   *
   * @param {string}   stat
   * @param {function} callback
   */
  on(stat, callback)
  {
    eventEmitter.on(stat, callback);
  },

  /**
   * Removes a callback for the specified stat.
   *
   * @param {string}   stat
   * @param {function} callback
   */
  off(stat, callback)
  {
    eventEmitter.off(stat, callback);
  },

  /**
   * The total number of blocked requests on non-incognito pages.
   *
   * @type {number}
   */
  get blocked_total()
  {
    return _prefs_js__WEBPACK_IMPORTED_MODULE_5__/* .Prefs.blocked_total */ .B.blocked_total;
  }
};

_prefs_js__WEBPACK_IMPORTED_MODULE_5__/* .Prefs.on */ .B.on("show_statsinicon", async() =>
{
  let tabs = await browser.tabs.query({});
  for (let tab of tabs)
  {
    if (_prefs_js__WEBPACK_IMPORTED_MODULE_5__/* .Prefs.show_statsinicon */ .B.show_statsinicon)
      await updateBadge(tab.id);
    else
      (0,_browserAction_js__WEBPACK_IMPORTED_MODULE_4__/* .setBadge */ .q_)(tab.id, null);
  }
});

/**
 * Returns the number of blocked requests for the sender's page.
 *
 * @event "stats.getBlockedPerPage"
 * @returns {number}
 */
_messaging_port_js__WEBPACK_IMPORTED_MODULE_2__/* .port.on */ .N.on("stats.getBlockedPerPage",
        message => getBlockedPerPage(new ext.Page(message.tab)));

/**
 * Returns the total number of blocked requests on non-incognito pages.
 *
 * @event "stats.getBlockedTotal"
 * @returns {number}
 */
_messaging_port_js__WEBPACK_IMPORTED_MODULE_2__/* .port.on */ .N.on("stats.getBlockedTotal", () => Stats.blocked_total);

browser.tabs.query({active: true}).then(tabs =>
{
  for (let tab of tabs)
  {
    activeTabIds.add(tab.id);
    activeTabIdByWindowId.set(tab.windowId, tab.id);
  }

  scheduleBadgeUpdate();
});

(0,_messaging_events_js__WEBPACK_IMPORTED_MODULE_1__/* .installHandler */ .a)("stats", null, (emit, action) =>
{
  const onChanged = info => emit(info);
  Stats.on(action, onChanged);
  return () => Stats.off(action, onChanged);
});

browser.tabs.onActivated.addListener(tab =>
{
  let lastActiveTabId = activeTabIdByWindowId.get(tab.windowId);
  if (typeof lastActiveTabId != "undefined")
    activeTabIds.delete(lastActiveTabId);

  activeTabIds.add(tab.tabId);
  activeTabIdByWindowId.set(tab.windowId, tab.tabId);

  scheduleBadgeUpdate();
});

if ("windows" in browser)
{
  browser.windows.onRemoved.addListener(windowId =>
  {
    activeTabIds.delete(activeTabIdByWindowId.get(windowId));
    activeTabIdByWindowId.delete(windowId);
  });
}


/***/ }),

/***/ 735:
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "x": () => (/* binding */ SessionStorage)
/* harmony export */ });
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */

/**
 * In-memory storage for use outside of service worker context.
 * @type {Map<string,any>}
 */
const memoryStorage = new Map();

/**
 * Indicates whether we need to store in-memory data using a dedicated browser
 * API. When we're running in the context of a service worker, we can no longer
 * rely on in-memory storage.
 * @type {boolean}
 */
const useMemoryStorage = !("session" in browser.storage);

/**
 * Session storage for storing in-memory data in a way that's safe to use in
 * a service worker context.
 */
class SessionStorage
{
  /**
   * Initializes session storage.
   * @param {string} namespace
   */
  constructor(namespace)
  {
    this._namespace = namespace;
  }

  /**
   * Generates unique storage key for storing values globally for given key.
   * @param {string} key
   * @return {string}
   */
  _getGlobalKey(key)
  {
    return `session:${this._namespace}:${key}`;
  }

  /**
   * Deletes session storage entry for given key.
   * @param {string} key
   * @return {Promise}
   */
  async delete(key)
  {
    const globalKey = this._getGlobalKey(key);
    if (useMemoryStorage)
      return memoryStorage.delete(globalKey);

    return browser.storage.session.remove(globalKey);
  }

  /**
   * Retrieves session storage entry for given key.
   * @param {string} key
   * @return {Promise<any>}
   */
  async get(key)
  {
    const globalKey = this._getGlobalKey(key);
    if (useMemoryStorage)
      return memoryStorage.get(globalKey);

    const storage = await browser.storage.session.get(globalKey);
    return storage[globalKey];
  }

  /**
   * Sets session storage entry for given key.
   * @param {string} key
   * @param {any} value
   * @return {Promise}
   */
  async set(key, value)
  {
    const globalKey = this._getGlobalKey(key);
    if (useMemoryStorage)
    {
      memoryStorage.set(globalKey, value);
      return;
    }

    browser.storage.session.set({[globalKey]: value});
  }
}


/***/ }),

/***/ 1627:
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "H": () => (/* binding */ TabSessionStorage)
/* harmony export */ });
/* harmony import */ var _session_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(735);
/*
 * This file is part of Adblock Plus <https://adblockplus.org/>,
 * Copyright (C) 2006-present eyeo GmbH
 *
 * Adblock Plus is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 3 as
 * published by the Free Software Foundation.
 *
 * Adblock Plus is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Adblock Plus.  If not, see <http://www.gnu.org/licenses/>.
 */



/**
 * Session storage instance for storing tab-specific data.
 * @type {SessionStorage<number,any>}
 */
const sessionByTabId = new _session_js__WEBPACK_IMPORTED_MODULE_0__/* .SessionStorage */ .x("_tabs");

/**
 * Session storage for storing tab-specific in-memory data in a way that's safe
 * to use in a service worker context.
 */
class TabSessionStorage
{
  /**
   * Initializes session storage.
   * @param {string} namespace
   */
  constructor(namespace)
  {
    this._namespace = namespace;
  }

  /**
   * Deletes session storage content specific to given tab ID.
   * @param {number} tabId
   * @return {Promise}
   */
  async delete(tabId)
  {
    const session = await sessionByTabId.get(tabId);
    if (!session)
      return;

    delete session[this._namespace];

    if (Object.keys(session).length)
      await sessionByTabId.set(tabId, session);
    else
      await sessionByTabId.delete(tabId);
  }

  /**
   * Retrieves session storage content specific to given tab ID.
   * @param {number} tabId
   * @return {Promise<any>}
   */
  async get(tabId)
  {
    const session = await sessionByTabId.get(tabId);
    if (!session)
      return;

    return session[this._namespace];
  }

  /**
   * Indicates whether session storage content exists specific to given tab ID.
   * @param {number} tabId
   * @return {Promise<boolean>}
   */
  async has(tabId)
  {
    const session = await sessionByTabId.get(tabId);
    return session && this._namespace in session;
  }

  /**
   * Sets session storage content specific to given tab ID.
   * @param {number} tabId
   * @param {any} value
   * @return {Promise}
   */
  async set(tabId, value)
  {
    const session = (await sessionByTabId.get(tabId)) || {};
    session[this._namespace] = value;
    await sessionByTabId.set(tabId, session);
  }
}

/**
 * Initializes tab-specific session storage.
 */
function init()
{
  // Clear tab-specific data when the tab's content changes
  ext.pages.onLoading.addListener(async page =>
  {
    await sessionByTabId.delete(page.id);
  });

  // Clear tab-specific data when the tab gets removed
  ext.pages.onRemoved.addListener(async tabId =>
  {
    await sessionByTabId.delete(tabId);
  });
}
init();


/***/ }),

/***/ 3950:
/***/ ((module) => {

"use strict";
module.exports = JSON.parse('{"0.bg":1,"001www.com":1,"0e.vc":1,"0emm.com":2,"1.bg":1,"12hp.at":1,"12hp.ch":1,"12hp.de":1,"1337.pictures":1,"16-b.it":1,"1kapp.com":1,"2.bg":1,"2000.hu":1,"2038.io":1,"2ix.at":1,"2ix.ch":1,"2ix.de":1,"3.bg":1,"32-b.it":1,"3utilities.com":1,"4.bg":1,"4lima.at":1,"4lima.ch":1,"4lima.de":1,"4u.com":1,"5.bg":1,"6.bg":1,"611.to":1,"64-b.it":1,"7.bg":1,"8.bg":1,"9.bg":1,"9guacu.br":1,"a.bg":1,"a.prod.fastly.net":1,"a.run.app":1,"a.se":1,"a.ssl.fastly.net":1,"aa.no":1,"aaa.pro":1,"aarborte.no":1,"ab.ca":1,"abashiri.hokkaido.jp":1,"abc.br":1,"abeno.osaka.jp":1,"abiko.chiba.jp":1,"abira.hokkaido.jp":1,"abkhazia.su":1,"abo.pa":1,"abr.it":1,"abruzzo.it":1,"abu.yamaguchi.jp":1,"ac.ae":1,"ac.at":1,"ac.be":1,"ac.ci":1,"ac.cn":1,"ac.cr":1,"ac.cy":1,"ac.fj":1,"ac.gn":1,"ac.gov.br":1,"ac.id":1,"ac.il":1,"ac.im":1,"ac.in":1,"ac.ir":1,"ac.jp":1,"ac.ke":1,"ac.kr":1,"ac.leg.br":1,"ac.lk":1,"ac.ls":1,"ac.ma":1,"ac.me":1,"ac.mu":1,"ac.mw":1,"ac.mz":1,"ac.ni":1,"ac.nz":1,"ac.pa":1,"ac.pr":1,"ac.rs":1,"ac.ru":1,"ac.rw":1,"ac.se":1,"ac.sz":1,"ac.th":1,"ac.tj":1,"ac.tz":1,"ac.ug":1,"ac.uk":1,"ac.vn":1,"ac.za":1,"ac.zm":1,"ac.zw":1,"aca.pro":1,"academia.bo":1,"academy.museum":1,"accesscam.org":1,"accident-investigation.aero":1,"accident-prevention.aero":1,"acct.pro":1,"achi.nagano.jp":1,"act.au":1,"act.edu.au":1,"ad.jp":1,"adachi.tokyo.jp":1,"adm.br":1,"adobeaemcloud.com":1,"adobeaemcloud.net":1,"adult.ht":1,"adv.br":1,"adv.mz":1,"advisor.ws":2,"adygeya.ru":1,"adygeya.su":1,"ae.org":1,"aejrie.no":1,"aero.mv":1,"aero.tt":1,"aerobatic.aero":1,"aeroclub.aero":1,"aerodrome.aero":1,"aeroport.fr":1,"afjord.no":1,"africa.com":1,"ag.it":1,"aga.niigata.jp":1,"agano.niigata.jp":1,"agdenes.no":1,"agematsu.nagano.jp":1,"agents.aero":1,"agr.br":1,"agrar.hu":1,"agric.za":1,"agriculture.museum":1,"agrigento.it":1,"agrinet.tn":1,"agro.bo":1,"agro.pl":1,"aguni.okinawa.jp":1,"ah.cn":1,"ah.no":1,"aibetsu.hokkaido.jp":1,"aichi.jp":1,"aid.pl":1,"aikawa.kanagawa.jp":1,"ainan.ehime.jp":1,"aioi.hyogo.jp":1,"aip.ee":1,"air-surveillance.aero":1,"air-traffic-control.aero":1,"air.museum":1,"aircraft.aero":1,"airguard.museum":1,"airline.aero":1,"airport.aero":1,"airtraffic.aero":1,"aisai.aichi.jp":1,"aisho.shiga.jp":1,"aizubange.fukushima.jp":1,"aizumi.tokushima.jp":1,"aizumisato.fukushima.jp":1,"aizuwakamatsu.fukushima.jp":1,"aju.br":1,"ak.us":1,"akabira.hokkaido.jp":1,"akagi.shimane.jp":1,"akaiwa.okayama.jp":1,"akashi.hyogo.jp":1,"aki.kochi.jp":1,"akiruno.tokyo.jp":1,"akishima.tokyo.jp":1,"akita.akita.jp":1,"akita.jp":1,"akkeshi.hokkaido.jp":1,"aknoluokta.no":1,"ako.hyogo.jp":1,"akrehamn.no":1,"aktyubinsk.su":1,"akune.kagoshima.jp":1,"al.eu.org":1,"al.gov.br":1,"al.it":1,"al.leg.br":1,"al.no":1,"al.us":1,"alabama.museum":1,"alaheadju.no":1,"aland.fi":1,"alaska.museum":1,"alces.network":2,"alessandria.it":1,"alesund.no":1,"algard.no":1,"algorithmia.com":2,"alpha-myqnapcloud.com":1,"alpha.bounty-full.com":1,"alstahaug.no":1,"alt.za":1,"alta.no":1,"altervista.org":1,"alto-adige.it":1,"altoadige.it":1,"alvdal.no":1,"alwaysdata.net":1,"am.br":1,"am.gov.br":1,"am.leg.br":1,"ama.aichi.jp":1,"ama.shimane.jp":1,"amagasaki.hyogo.jp":1,"amakusa.kumamoto.jp":1,"amami.kagoshima.jp":1,"amber.museum":1,"ambulance.aero":1,"ambulance.museum":1,"american.museum":1,"americana.museum":1,"americanantiques.museum":1,"americanart.museum":1,"ami.ibaraki.jp":1,"amli.no":1,"amot.no":1,"amsterdam.museum":1,"amsw.nl":1,"amusement.aero":1,"an.it":1,"anamizu.ishikawa.jp":1,"anan.nagano.jp":1,"anan.tokushima.jp":1,"anani.br":1,"ancona.it":1,"and.mom":1,"and.museum":1,"andasuolo.no":1,"andebu.no":1,"ando.nara.jp":1,"andoy.no":1,"andria-barletta-trani.it":1,"andria-trani-barletta.it":1,"andriabarlettatrani.it":1,"andriatranibarletta.it":1,"anjo.aichi.jp":1,"ann-arbor.mi.us":1,"annaka.gunma.jp":1,"annefrank.museum":1,"anpachi.gifu.jp":1,"anthro.museum":1,"anthropology.museum":1,"antiques.museum":1,"ao.it":1,"aogaki.hyogo.jp":1,"aogashima.tokyo.jp":1,"aoki.nagano.jp":1,"aomori.aomori.jp":1,"aomori.jp":1,"aosta-valley.it":1,"aosta.it":1,"aostavalley.it":1,"aoste.it":1,"ap-northeast-1.elasticbeanstalk.com":1,"ap-northeast-2.elasticbeanstalk.com":1,"ap-northeast-3.elasticbeanstalk.com":1,"ap-south-1.elasticbeanstalk.com":1,"ap-southeast-1.elasticbeanstalk.com":1,"ap-southeast-2.elasticbeanstalk.com":1,"ap.gov.br":1,"ap.gov.pl":1,"ap.it":1,"ap.leg.br":1,"aparecida.br":1,"api.stdlib.com":1,"apigee.io":1,"app.banzaicloud.io":1,"app.br":1,"app.gp":1,"app.lmpm.com":1,"app.os.fedoraproject.org":1,"app.os.stg.fedoraproject.org":1,"app.render.com":1,"appchizi.com":1,"appengine.flow.ch":1,"applicationcloud.io":1,"applinzi.com":1,"apps.fbsbx.com":1,"apps.lair.io":1,"appspot.com":1,"aprendemas.cl":1,"aq.it":1,"aquarium.museum":1,"aquila.it":1,"ar.com":1,"ar.it":1,"ar.us":1,"arai.shizuoka.jp":1,"arakawa.saitama.jp":1,"arakawa.tokyo.jp":1,"arao.kumamoto.jp":1,"arboretum.museum":1,"archaeological.museum":1,"archaeology.museum":1,"architecture.museum":1,"ardal.no":1,"aremark.no":1,"arendal.no":1,"arezzo.it":1,"ariake.saga.jp":1,"arida.wakayama.jp":1,"aridagawa.wakayama.jp":1,"arita.saga.jp":1,"arkhangelsk.su":1,"armenia.su":1,"arna.no":1,"arq.br":1,"art.br":1,"art.do":1,"art.dz":1,"art.ht":1,"art.museum":1,"art.pl":1,"art.sn":1,"artanddesign.museum":1,"artcenter.museum":1,"artdeco.museum":1,"arte.bo":1,"arteducation.museum":1,"artgallery.museum":1,"arts.co":1,"arts.museum":1,"arts.nf":1,"arts.ro":1,"arts.ve":1,"artsandcrafts.museum":1,"arvo.network":1,"as.us":1,"asago.hyogo.jp":1,"asahi.chiba.jp":1,"asahi.ibaraki.jp":1,"asahi.mie.jp":1,"asahi.nagano.jp":1,"asahi.toyama.jp":1,"asahi.yamagata.jp":1,"asahikawa.hokkaido.jp":1,"asaka.saitama.jp":1,"asakawa.fukushima.jp":1,"asakuchi.okayama.jp":1,"asaminami.hiroshima.jp":1,"ascoli-piceno.it":1,"ascolipiceno.it":1,"aseral.no":1,"ashgabad.su":1,"ashibetsu.hokkaido.jp":1,"ashikaga.tochigi.jp":1,"ashiya.fukuoka.jp":1,"ashiya.hyogo.jp":1,"ashoro.hokkaido.jp":1,"asker.no":1,"askim.no":1,"askoy.no":1,"askvoll.no":1,"asmatart.museum":1,"asn.au":1,"asn.lv":1,"asnes.no":1,"aso.kumamoto.jp":1,"ass.km":1,"assabu.hokkaido.jp":1,"assassination.museum":1,"assisi.museum":1,"assn.lk":1,"asso.bj":1,"asso.ci":1,"asso.dz":1,"asso.eu.org":1,"asso.fr":1,"asso.gp":1,"asso.ht":1,"asso.km":1,"asso.mc":1,"asso.nc":1,"asso.re":1,"association.aero":1,"association.museum":1,"asti.it":1,"astronomy.museum":1,"asuke.aichi.jp":1,"at-band-camp.net":1,"at.eu.org":1,"at.it":1,"at.md":1,"at.vg":1,"atami.shizuoka.jp":1,"ath.cx":1,"atlanta.museum":1,"atm.pl":1,"ato.br":1,"atsugi.kanagawa.jp":1,"atsuma.hokkaido.jp":1,"au.eu.org":1,"audnedaln.no":1,"augustow.pl":1,"aukra.no":1,"aure.no":1,"aurland.no":1,"aurskog-holand.no":1,"aus.basketball":1,"austevoll.no":1,"austin.museum":1,"australia.museum":1,"austrheim.no":1,"author.aero":1,"auto.pl":1,"automotive.museum":1,"av.it":1,"av.tr":1,"avellino.it":1,"averoy.no":1,"aviation.museum":1,"avocat.fr":1,"avocat.pro":1,"avoues.fr":1,"awaji.hyogo.jp":1,"awdev.ca":2,"awsmppl.com":1,"axis.museum":1,"aya.miyazaki.jp":1,"ayabe.kyoto.jp":1,"ayagawa.kagawa.jp":1,"ayase.kanagawa.jp":1,"az.us":1,"azerbaijan.su":1,"azimuth.network":1,"azumino.nagano.jp":1,"azure-mobile.net":1,"azurecontainer.io":2,"azurewebsites.net":1,"b-data.io":1,"b.bg":1,"b.br":1,"b.se":1,"b.ssl.fastly.net":1,"ba.gov.br":1,"ba.it":1,"ba.leg.br":1,"babia-gora.pl":1,"backplaneapp.io":1,"backyards.banzaicloud.io":2,"badaddja.no":1,"badajoz.museum":1,"baghdad.museum":1,"bahcavuotna.no":1,"bahccavuotna.no":1,"bahn.museum":1,"baidar.no":1,"bajddar.no":1,"balashov.su":1,"balat.no":1,"bale.museum":1,"balena-devices.com":1,"balestrand.no":1,"ballangen.no":1,"ballooning.aero":1,"balsan-sudtirol.it":1,"balsan-suedtirol.it":1,"balsan.it":1,"balsfjord.no":1,"baltimore.museum":1,"bamble.no":1,"bandai.fukushima.jp":1,"bando.ibaraki.jp":1,"banzai.cloud":2,"bar.pro":1,"bar0.net":1,"bar1.net":1,"bar2.net":1,"barcelona.museum":1,"bardu.no":1,"bari.it":1,"barletta-trani-andria.it":1,"barlettatraniandria.it":1,"barreau.bj":1,"barrel-of-knowledge.info":1,"barrell-of-knowledge.info":1,"barsy.bg":1,"barsy.ca":1,"barsy.club":1,"barsy.co.uk":1,"barsy.de":1,"barsy.eu":1,"barsy.in":1,"barsy.info":1,"barsy.io":1,"barsy.me":1,"barsy.menu":1,"barsy.mobi":1,"barsy.net":1,"barsy.online":1,"barsy.org":1,"barsy.pro":1,"barsy.pub":1,"barsy.shop":1,"barsy.site":1,"barsy.support":1,"barsy.uk":1,"barsycenter.com":1,"barsyonline.co.uk":1,"barsyonline.com":1,"barueri.br":1,"barum.no":1,"bas.it":1,"baseball.museum":1,"basel.museum":1,"bashkiria.ru":1,"bashkiria.su":1,"basicserver.io":1,"basilicata.it":1,"baths.museum":1,"bato.tochigi.jp":1,"batsfjord.no":1,"bauern.museum":1,"bbs.tr":1,"bc.ca":1,"bc.platform.sh":1,"bci.dnstrace.pro":1,"bd":2,"bd.se":1,"be.ax":1,"be.eu.org":1,"be.gy":1,"bearalvahki.no":1,"beardu.no":1,"beauxarts.museum":1,"bedzin.pl":1,"beeldengeluid.museum":1,"beep.pl":1,"beiarn.no":1,"bel.tr":1,"belau.pw":1,"belem.br":1,"bellevue.museum":1,"belluno.it":1,"benevento.it":1,"beppu.oita.jp":1,"berg.no":1,"bergamo.it":1,"bergbau.museum":1,"bergen.no":1,"berkeley.museum":1,"berlevag.no":1,"berlin.museum":1,"bern.museum":1,"beskidy.pl":1,"beta.bounty-full.com":1,"betainabox.com":1,"better-than.tv":1,"bg.eu.org":1,"bg.it":1,"bhz.br":1,"bi.it":1,"bialowieza.pl":1,"bialystok.pl":1,"bib.br":1,"bibai.hokkaido.jp":1,"bible.museum":1,"biei.hokkaido.jp":1,"bielawa.pl":1,"biella.it":1,"bieszczady.pl":1,"bievat.no":1,"bifuka.hokkaido.jp":1,"bihoro.hokkaido.jp":1,"bilbao.museum":1,"bill.museum":1,"bindal.no":1,"bio.br":1,"bir.ru":1,"biratori.hokkaido.jp":1,"birdart.museum":1,"birkenes.no":1,"birthplace.museum":1,"bitbridge.net":1,"biz.at":1,"biz.az":1,"biz.bb":1,"biz.cy":1,"biz.dk":1,"biz.et":1,"biz.fj":1,"biz.gl":1,"biz.id":1,"biz.ki":1,"biz.ls":1,"biz.mv":1,"biz.mw":1,"biz.ni":1,"biz.nr":1,"biz.pk":1,"biz.pl":1,"biz.pr":1,"biz.ss":1,"biz.tj":1,"biz.tr":1,"biz.tt":1,"biz.ua":1,"biz.vn":1,"biz.zm":1,"bizen.okayama.jp":1,"bj.cn":1,"bjarkoy.no":1,"bjerkreim.no":1,"bjugn.no":1,"bl.it":1,"blackbaudcdn.net":1,"blog.bo":1,"blog.br":1,"blog.gt":1,"blog.kg":1,"blog.vu":1,"blogdns.com":1,"blogdns.net":1,"blogdns.org":1,"blogsite.org":1,"blogsite.xyz":1,"blogspot.ae":1,"blogspot.al":1,"blogspot.am":1,"blogspot.ba":1,"blogspot.be":1,"blogspot.bg":1,"blogspot.bj":1,"blogspot.ca":1,"blogspot.cf":1,"blogspot.ch":1,"blogspot.cl":1,"blogspot.co.at":1,"blogspot.co.id":1,"blogspot.co.il":1,"blogspot.co.ke":1,"blogspot.co.nz":1,"blogspot.co.uk":1,"blogspot.co.za":1,"blogspot.com":1,"blogspot.com.ar":1,"blogspot.com.au":1,"blogspot.com.br":1,"blogspot.com.by":1,"blogspot.com.co":1,"blogspot.com.cy":1,"blogspot.com.ee":1,"blogspot.com.eg":1,"blogspot.com.es":1,"blogspot.com.mt":1,"blogspot.com.ng":1,"blogspot.com.tr":1,"blogspot.com.uy":1,"blogspot.cv":1,"blogspot.cz":1,"blogspot.de":1,"blogspot.dk":1,"blogspot.fi":1,"blogspot.fr":1,"blogspot.gr":1,"blogspot.hk":1,"blogspot.hr":1,"blogspot.hu":1,"blogspot.ie":1,"blogspot.in":1,"blogspot.is":1,"blogspot.it":1,"blogspot.jp":1,"blogspot.kr":1,"blogspot.li":1,"blogspot.lt":1,"blogspot.lu":1,"blogspot.md":1,"blogspot.mk":1,"blogspot.mr":1,"blogspot.mx":1,"blogspot.my":1,"blogspot.nl":1,"blogspot.no":1,"blogspot.pe":1,"blogspot.pt":1,"blogspot.qa":1,"blogspot.re":1,"blogspot.ro":1,"blogspot.rs":1,"blogspot.ru":1,"blogspot.se":1,"blogspot.sg":1,"blogspot.si":1,"blogspot.sk":1,"blogspot.sn":1,"blogspot.td":1,"blogspot.tw":1,"blogspot.ug":1,"blogspot.vn":1,"blogsyte.com":1,"bloxcms.com":1,"bmd.br":1,"bmoattachments.org":1,"bn.it":1,"bnr.la":1,"bo.it":1,"bo.nordland.no":1,"bo.telemark.no":1,"boavista.br":1,"bodo.no":1,"bokn.no":1,"boldlygoingnowhere.org":1,"boleslawiec.pl":1,"bolivia.bo":1,"bologna.it":1,"bolt.hu":1,"bolzano-altoadige.it":1,"bolzano.it":1,"bomlo.no":1,"bonn.museum":1,"boomla.net":1,"boston.museum":1,"botanical.museum":1,"botanicalgarden.museum":1,"botanicgarden.museum":1,"botany.museum":1,"bounceme.net":1,"bounty-full.com":1,"boxfuse.io":1,"bozen-sudtirol.it":1,"bozen-suedtirol.it":1,"bozen.it":1,"bpl.biz":1,"bplaced.com":1,"bplaced.de":1,"bplaced.net":1,"br.com":1,"br.it":1,"brand.se":1,"brandywinevalley.museum":1,"brasil.museum":1,"brasilia.me":1,"bremanger.no":1,"brescia.it":1,"brindisi.it":1,"bristol.museum":1,"british.museum":1,"britishcolumbia.museum":1,"broadcast.museum":1,"broke-it.net":1,"broker.aero":1,"bronnoy.no":1,"bronnoysund.no":1,"browsersafetymark.io":1,"brumunddal.no":1,"brunel.museum":1,"brussel.museum":1,"brussels.museum":1,"bruxelles.museum":1,"bryansk.su":1,"bryne.no":1,"bs.it":1,"bsb.br":1,"bss.design":1,"bt.it":1,"bu.no":1,"budejju.no":1,"building.museum":1,"builtwithdark.com":1,"bukhara.su":1,"bulsan-sudtirol.it":1,"bulsan-suedtirol.it":1,"bulsan.it":1,"bungoono.oita.jp":1,"bungotakada.oita.jp":1,"bunkyo.tokyo.jp":1,"burghof.museum":1,"bus.museum":1,"busan.kr":1,"bushey.museum":1,"buyshouses.net":1,"buzen.fukuoka.jp":1,"bydgoszcz.pl":1,"byen.site":1,"bygland.no":1,"bykle.no":1,"bytom.pl":1,"bz.it":1,"bzz.dapps.earth":2,"c.bg":1,"c.cdn77.org":1,"c.la":1,"c.se":1,"c66.me":1,"ca-central-1.elasticbeanstalk.com":1,"ca.eu.org":1,"ca.it":1,"ca.na":1,"ca.us":1,"caa.aero":1,"caa.li":1,"cable-modem.org":1,"cadaques.museum":1,"cagliari.it":1,"cahcesuolo.no":1,"cal.it":1,"calabria.it":1,"california.museum":1,"caltanissetta.it":1,"cam.it":1,"cambridge.museum":1,"camdvr.org":1,"campania.it":1,"campidano-medio.it":1,"campidanomedio.it":1,"campinagrande.br":1,"campinas.br":1,"campobasso.it":1,"can.museum":1,"canada.museum":1,"capebreton.museum":1,"carbonia-iglesias.it":1,"carboniaiglesias.it":1,"cargo.aero":1,"carrara-massa.it":1,"carraramassa.it":1,"carrd.co":1,"carrier.museum":1,"cartoonart.museum":1,"casacam.net":1,"casadelamoneda.museum":1,"caserta.it":1,"casino.hu":1,"castle.museum":1,"castres.museum":1,"cat.ax":1,"catania.it":1,"catanzaro.it":1,"catering.aero":1,"catholic.edu.au":1,"caxias.br":1,"cb.it":1,"cbg.ru":1,"cc.ak.us":1,"cc.al.us":1,"cc.ar.us":1,"cc.as.us":1,"cc.az.us":1,"cc.ca.us":1,"cc.co.us":1,"cc.ct.us":1,"cc.dc.us":1,"cc.de.us":1,"cc.fl.us":1,"cc.ga.us":1,"cc.gu.us":1,"cc.hi.us":1,"cc.hn":1,"cc.ia.us":1,"cc.id.us":1,"cc.il.us":1,"cc.in.us":1,"cc.ks.us":1,"cc.ky.us":1,"cc.la.us":1,"cc.ma.us":1,"cc.md.us":1,"cc.me.us":1,"cc.mi.us":1,"cc.mn.us":1,"cc.mo.us":1,"cc.ms.us":1,"cc.mt.us":1,"cc.na":1,"cc.nc.us":1,"cc.nd.us":1,"cc.ne.us":1,"cc.nh.us":1,"cc.nj.us":1,"cc.nm.us":1,"cc.nv.us":1,"cc.ny.us":1,"cc.oh.us":1,"cc.ok.us":1,"cc.or.us":1,"cc.pa.us":1,"cc.pr.us":1,"cc.ri.us":1,"cc.sc.us":1,"cc.sd.us":1,"cc.tn.us":1,"cc.tx.us":1,"cc.ua":1,"cc.ut.us":1,"cc.va.us":1,"cc.vi.us":1,"cc.vt.us":1,"cc.wa.us":1,"cc.wi.us":1,"cc.wv.us":1,"cc.wy.us":1,"cci.fr":1,"cd.eu.org":1,"cdn77-ssl.net":1,"ce.gov.br":1,"ce.it":1,"ce.leg.br":1,"cechire.com":1,"celtic.museum":1,"center.museum":1,"certification.aero":1,"certmgr.org":1,"cesena-forli.it":1,"cesenaforli.it":1,"ch.eu.org":1,"ch.it":1,"ch.tc":1,"chambagri.fr":1,"championship.aero":1,"channelsdvr.net":1,"charter.aero":1,"chattanooga.museum":1,"cheltenham.museum":1,"cherkassy.ua":1,"cherkasy.ua":1,"chernigov.ua":1,"chernihiv.ua":1,"chernivtsi.ua":1,"chernovtsy.ua":1,"chesapeakebay.museum":1,"chiba.jp":1,"chicago.museum":1,"chichibu.saitama.jp":1,"chieti.it":1,"chigasaki.kanagawa.jp":1,"chihayaakasaka.osaka.jp":1,"chijiwa.nagasaki.jp":1,"chikugo.fukuoka.jp":1,"chikuho.fukuoka.jp":1,"chikuhoku.nagano.jp":1,"chikujo.fukuoka.jp":1,"chikuma.nagano.jp":1,"chikusei.ibaraki.jp":1,"chikushino.fukuoka.jp":1,"chikuzen.fukuoka.jp":1,"children.museum":1,"childrens.museum":1,"childrensgarden.museum":1,"chimkent.su":1,"chino.nagano.jp":1,"chippubetsu.hokkaido.jp":1,"chiropractic.museum":1,"chirurgiens-dentistes-en-france.fr":1,"chirurgiens-dentistes.fr":1,"chiryu.aichi.jp":1,"chita.aichi.jp":1,"chitose.hokkaido.jp":1,"chiyoda.gunma.jp":1,"chiyoda.tokyo.jp":1,"chizu.tottori.jp":1,"chocolate.museum":1,"chofu.tokyo.jp":1,"chonan.chiba.jp":1,"chosei.chiba.jp":1,"choshi.chiba.jp":1,"choyo.kumamoto.jp":1,"christiansburg.museum":1,"chtr.k12.ma.us":1,"chungbuk.kr":1,"chungnam.kr":1,"chuo.chiba.jp":1,"chuo.fukuoka.jp":1,"chuo.osaka.jp":1,"chuo.tokyo.jp":1,"chuo.yamanashi.jp":1,"ci.it":1,"ciencia.bo":1,"cieszyn.pl":1,"cim.br":1,"cincinnati.museum":1,"cinema.museum":1,"circus.museum":1,"ciscofreak.com":1,"cistron.nl":1,"city.hu":1,"city.kawasaki.jp":0,"city.kitakyushu.jp":0,"city.kobe.jp":0,"city.nagoya.jp":0,"city.sapporo.jp":0,"city.sendai.jp":0,"city.yokohama.jp":0,"civilaviation.aero":1,"civilisation.museum":1,"civilization.museum":1,"civilwar.museum":1,"ck":2,"ck.ua":1,"cl.it":1,"clan.rip":1,"cleverapps.io":1,"clic2000.net":1,"clinton.museum":1,"clock.museum":1,"cloud.fedoraproject.org":1,"cloud.goog":1,"cloud.metacentrum.cz":2,"cloud66.ws":1,"cloud66.zone":1,"cloudaccess.host":1,"cloudaccess.net":1,"cloudapp.net":1,"cloudapps.digital":1,"cloudcontrolapp.com":1,"cloudcontrolled.com":1,"cloudeity.net":1,"cloudera.site":1,"cloudfront.net":1,"cloudfunctions.net":1,"cloudjiffy.net":1,"cloudns.asia":1,"cloudns.biz":1,"cloudns.cc":1,"cloudns.club":1,"cloudns.eu":1,"cloudns.in":1,"cloudns.info":1,"cloudns.org":1,"cloudns.pro":1,"cloudns.pw":1,"cloudns.us":1,"cloudycluster.net":1,"club.aero":1,"club.tw":1,"cn-north-1.eb.amazonaws.com.cn":1,"cn-northwest-1.eb.amazonaws.com.cn":1,"cn.com":1,"cn.eu.org":1,"cn.it":1,"cn.ua":1,"cn.vu":1,"cng.br":1,"cnpy.gdn":1,"cns.joyent.com":2,"cnt.br":1,"co.ae":1,"co.ag":1,"co.am":1,"co.ao":1,"co.at":1,"co.bb":1,"co.bi":1,"co.bn":1,"co.business":1,"co.bw":1,"co.ca":1,"co.ci":1,"co.cl":1,"co.cm":1,"co.com":1,"co.cr":1,"co.cz":1,"co.dk":1,"co.education":1,"co.events":1,"co.financial":1,"co.gg":1,"co.gl":1,"co.gy":1,"co.hu":1,"co.id":1,"co.il":1,"co.im":1,"co.in":1,"co.ir":1,"co.it":1,"co.je":1,"co.jp":1,"co.ke":1,"co.kr":1,"co.krd":1,"co.lc":1,"co.ls":1,"co.ma":1,"co.me":1,"co.mg":1,"co.mu":1,"co.mw":1,"co.mz":1,"co.na":1,"co.network":1,"co.ni":1,"co.nl":1,"co.no":1,"co.nz":1,"co.om":1,"co.pl":1,"co.place":1,"co.pn":1,"co.pw":1,"co.ro":1,"co.rs":1,"co.rw":1,"co.st":1,"co.sz":1,"co.technology":1,"co.th":1,"co.tj":1,"co.tm":1,"co.tt":1,"co.tz":1,"co.ua":1,"co.ug":1,"co.uk":1,"co.us":1,"co.uz":1,"co.ve":1,"co.vi":1,"co.za":1,"co.zm":1,"co.zw":1,"coal.museum":1,"coastaldefence.museum":1,"codespot.com":1,"cody.museum":1,"cog.mi.us":1,"col.ng":1,"coldwar.museum":1,"collection.museum":1,"collegefan.org":1,"colonialwilliamsburg.museum":1,"coloradoplateau.museum":1,"columbia.museum":1,"columbus.museum":1,"com.ac":1,"com.af":1,"com.ag":1,"com.ai":1,"com.al":1,"com.am":1,"com.ar":1,"com.au":1,"com.aw":1,"com.az":1,"com.ba":1,"com.bb":1,"com.bh":1,"com.bi":1,"com.bm":1,"com.bn":1,"com.bo":1,"com.br":1,"com.bs":1,"com.bt":1,"com.by":1,"com.bz":1,"com.ci":1,"com.cm":1,"com.cn":1,"com.co":1,"com.cu":1,"com.cw":1,"com.cy":1,"com.de":1,"com.dm":1,"com.do":1,"com.dz":1,"com.ec":1,"com.ee":1,"com.eg":1,"com.es":1,"com.et":1,"com.fj":1,"com.fm":1,"com.fr":1,"com.ge":1,"com.gh":1,"com.gi":1,"com.gl":1,"com.gn":1,"com.gp":1,"com.gr":1,"com.gt":1,"com.gu":1,"com.gy":1,"com.hk":1,"com.hn":1,"com.hr":1,"com.ht":1,"com.im":1,"com.io":1,"com.iq":1,"com.is":1,"com.jo":1,"com.kg":1,"com.ki":1,"com.km":1,"com.kp":1,"com.kw":1,"com.ky":1,"com.kz":1,"com.la":1,"com.lb":1,"com.lc":1,"com.lk":1,"com.lr":1,"com.lv":1,"com.ly":1,"com.mg":1,"com.mk":1,"com.ml":1,"com.mo":1,"com.ms":1,"com.mt":1,"com.mu":1,"com.mv":1,"com.mw":1,"com.mx":1,"com.my":1,"com.na":1,"com.nf":1,"com.ng":1,"com.ni":1,"com.nr":1,"com.om":1,"com.pa":1,"com.pe":1,"com.pf":1,"com.ph":1,"com.pk":1,"com.pl":1,"com.pr":1,"com.ps":1,"com.pt":1,"com.py":1,"com.qa":1,"com.re":1,"com.ro":1,"com.ru":1,"com.sa":1,"com.sb":1,"com.sc":1,"com.sd":1,"com.se":1,"com.sg":1,"com.sh":1,"com.sl":1,"com.sn":1,"com.so":1,"com.ss":1,"com.st":1,"com.sv":1,"com.sy":1,"com.tj":1,"com.tm":1,"com.tn":1,"com.to":1,"com.tr":1,"com.tt":1,"com.tw":1,"com.ua":1,"com.ug":1,"com.uy":1,"com.uz":1,"com.vc":1,"com.ve":1,"com.vi":1,"com.vn":1,"com.vu":1,"com.ws":1,"com.zm":1,"commune.am":1,"communication.museum":1,"communications.museum":1,"community-pro.de":1,"community-pro.net":1,"community.museum":1,"como.it":1,"compute-1.amazonaws.com":2,"compute.amazonaws.com":2,"compute.amazonaws.com.cn":2,"compute.estate":2,"computer.museum":1,"computerhistory.museum":1,"conf.au":1,"conf.lv":1,"conf.se":1,"conference.aero":1,"conn.uk":1,"consulado.st":1,"consultant.aero":1,"consulting.aero":1,"contagem.br":1,"contemporary.museum":1,"contemporaryart.museum":1,"control.aero":1,"convent.museum":1,"coop.br":1,"coop.ht":1,"coop.km":1,"coop.mv":1,"coop.mw":1,"coop.py":1,"coop.rw":1,"coop.tt":1,"cooperativa.bo":1,"copenhagen.museum":1,"copro.uk":1,"corporation.museum":1,"corvette.museum":1,"cosenza.it":1,"costume.museum":1,"couchpotatofries.org":1,"couk.me":1,"council.aero":1,"countryestate.museum":1,"county.museum":1,"coz.br":1,"cpa.pro":1,"cq.cn":1,"cr.it":1,"cr.ua":1,"crafting.xyz":1,"crafts.museum":1,"cranbrook.museum":1,"crd.co":1,"creation.museum":1,"cremona.it":1,"crew.aero":1,"cri.br":1,"cri.nz":1,"crimea.ua":1,"crotone.it":1,"cryptonomic.net":2,"cs.it":1,"csx.cc":1,"ct.it":1,"ct.us":1,"cuiaba.br":1,"cultural.museum":1,"culturalcenter.museum":1,"culture.museum":1,"cuneo.it":1,"cupcake.is":1,"curitiba.br":1,"curv.dev":1,"cust.dev.thingdust.io":1,"cust.disrec.thingdust.io":1,"cust.prod.thingdust.io":1,"cust.retrosnub.co.uk":1,"cust.testing.thingdust.io":1,"custom.metacentrum.cz":1,"customer-oci.com":2,"customer.enonic.io":1,"customer.mythic-beasts.com":1,"customer.speedpartner.de":1,"cv.ua":1,"cx.ua":1,"cy.eu.org":1,"cya.gg":1,"cyber.museum":1,"cymru.museum":1,"cyon.link":1,"cyon.site":1,"cz.eu.org":1,"cz.it":1,"czeladz.pl":1,"czest.pl":1,"d.bg":1,"d.gv.vc":1,"d.se":1,"daegu.kr":1,"daejeon.kr":1,"daemon.panel.gg":1,"dagestan.ru":1,"dagestan.su":1,"daigo.ibaraki.jp":1,"daisen.akita.jp":1,"daito.osaka.jp":1,"daiwa.hiroshima.jp":1,"dali.museum":1,"dallas.museum":1,"damnserver.com":1,"daplie.me":1,"dapps.earth":2,"database.museum":1,"date.fukushima.jp":1,"date.hokkaido.jp":1,"dattolocal.com":1,"dattolocal.net":1,"dattorelay.com":1,"dattoweb.com":1,"davvenjarga.no":1,"davvesiida.no":1,"dazaifu.fukuoka.jp":1,"dc.us":1,"dd-dns.de":1,"ddns.me":1,"ddns.net":1,"ddnsfree.com":1,"ddnsgeek.com":1,"ddnsking.com":1,"ddnslive.com":1,"ddnss.de":1,"ddnss.org":1,"ddr.museum":1,"de.com":1,"de.cool":1,"de.eu.org":1,"de.gt":1,"de.ls":1,"de.md":1,"de.us":1,"deatnu.no":1,"debian.net":1,"decorativearts.museum":1,"dedyn.io":1,"def.br":1,"defense.tn":1,"definima.io":1,"definima.net":1,"delaware.museum":1,"dell-ogliastra.it":1,"dellogliastra.it":1,"delmenhorst.museum":1,"demo.jelastic.com":1,"democracia.bo":1,"demon.nl":1,"denmark.museum":1,"dep.no":1,"deporte.bo":1,"depot.museum":1,"des.br":1,"desa.id":1,"design.aero":1,"design.museum":1,"det.br":1,"detroit.museum":1,"dev-myqnapcloud.com":1,"dev.adobeaemcloud.com":2,"dev.br":1,"dev.static.land":1,"dev.vu":1,"development.run":1,"devices.resinstaging.io":1,"df.gov.br":1,"df.leg.br":1,"dgca.aero":1,"dh.bytemark.co.uk":1,"dielddanuorri.no":1,"dinosaur.museum":1,"direct.quickconnect.to":1,"discourse.group":1,"discourse.team":1,"discovery.museum":1,"diskstation.eu":1,"diskstation.me":1,"diskstation.org":1,"diskussionsbereich.de":1,"ditchyourip.com":1,"divtasvuodna.no":1,"divttasvuotna.no":1,"dk.eu.org":1,"dlugoleka.pl":1,"dn.ua":1,"dnepropetrovsk.ua":1,"dni.us":1,"dnipropetrovsk.ua":1,"dnsalias.com":1,"dnsalias.net":1,"dnsalias.org":1,"dnsdojo.com":1,"dnsdojo.net":1,"dnsdojo.org":1,"dnsfor.me":1,"dnshome.de":1,"dnsiskinky.com":1,"dnsking.ch":1,"dnsup.net":1,"dnsupdate.info":1,"dnsupdater.de":1,"does-it.net":1,"doesntexist.com":1,"doesntexist.org":1,"dolls.museum":1,"donetsk.ua":1,"donna.no":1,"donostia.museum":1,"dontexist.com":1,"dontexist.net":1,"dontexist.org":1,"doomdns.com":1,"doomdns.org":1,"dopaas.com":1,"doshi.yamanashi.jp":1,"dovre.no":1,"dp.ua":1,"dr.na":1,"dr.tr":1,"drammen.no":1,"drangedal.no":1,"dray-dns.de":1,"drayddns.com":1,"draydns.de":1,"dreamhosters.com":1,"drobak.no":1,"drud.io":1,"drud.us":1,"dscloud.biz":1,"dscloud.me":1,"dscloud.mobi":1,"dsmynas.com":1,"dsmynas.net":1,"dsmynas.org":1,"dst.mi.us":1,"duckdns.org":1,"durham.museum":1,"dvrcam.info":1,"dvrdns.org":1,"dweb.link":2,"dy.fi":1,"dyn-berlin.de":1,"dyn-ip24.de":1,"dyn-o-saur.com":1,"dyn-vpn.de":1,"dyn.cosidns.de":1,"dyn.ddnss.de":1,"dyn.home-webserver.de":1,"dyn53.io":1,"dynalias.com":1,"dynalias.net":1,"dynalias.org":1,"dynamic-dns.info":1,"dynamisches-dns.de":1,"dynathome.net":1,"dyndns-at-home.com":1,"dyndns-at-work.com":1,"dyndns-blog.com":1,"dyndns-free.com":1,"dyndns-home.com":1,"dyndns-ip.com":1,"dyndns-mail.com":1,"dyndns-office.com":1,"dyndns-pics.com":1,"dyndns-remote.com":1,"dyndns-server.com":1,"dyndns-web.com":1,"dyndns-wiki.com":1,"dyndns-work.com":1,"dyndns.biz":1,"dyndns.dappnode.io":1,"dyndns.ddnss.de":1,"dyndns.info":1,"dyndns.org":1,"dyndns.tv":1,"dyndns.ws":1,"dyndns1.de":1,"dynns.com":1,"dynserv.org":1,"dynu.net":1,"dynv6.net":1,"dynvpn.de":1,"dyroy.no":1,"e.bg":1,"e.se":1,"e12.ve":1,"e164.arpa":1,"e4.cz":1,"east-kazakhstan.su":1,"eastafrica.museum":1,"eastcoast.museum":1,"eating-organic.net":1,"eaton.mi.us":1,"ebetsu.hokkaido.jp":1,"ebina.kanagawa.jp":1,"ebino.miyazaki.jp":1,"ebiz.tw":1,"echizen.fukui.jp":1,"ecn.br":1,"eco.br":1,"ecologia.bo":1,"economia.bo":1,"ed.ao":1,"ed.ci":1,"ed.cr":1,"ed.jp":1,"ed.pw":1,"edgeapp.net":1,"edgestack.me":1,"edogawa.tokyo.jp":1,"edu.ac":1,"edu.af":1,"edu.al":1,"edu.ar":1,"edu.au":1,"edu.az":1,"edu.ba":1,"edu.bb":1,"edu.bh":1,"edu.bi":1,"edu.bm":1,"edu.bn":1,"edu.bo":1,"edu.br":1,"edu.bs":1,"edu.bt":1,"edu.bz":1,"edu.ci":1,"edu.cn":1,"edu.co":1,"edu.cu":1,"edu.cw":1,"edu.dm":1,"edu.do":1,"edu.dz":1,"edu.ec":1,"edu.ee":1,"edu.eg":1,"edu.es":1,"edu.et":1,"edu.eu.org":1,"edu.fm":1,"edu.gd":1,"edu.ge":1,"edu.gh":1,"edu.gi":1,"edu.gl":1,"edu.gn":1,"edu.gp":1,"edu.gr":1,"edu.gt":1,"edu.gu":1,"edu.gy":1,"edu.hk":1,"edu.hn":1,"edu.ht":1,"edu.in":1,"edu.iq":1,"edu.is":1,"edu.it":1,"edu.jo":1,"edu.kg":1,"edu.ki":1,"edu.km":1,"edu.kn":1,"edu.kp":1,"edu.krd":1,"edu.kw":1,"edu.ky":1,"edu.kz":1,"edu.la":1,"edu.lb":1,"edu.lc":1,"edu.lk":1,"edu.lr":1,"edu.ls":1,"edu.lv":1,"edu.ly":1,"edu.me":1,"edu.mg":1,"edu.mk":1,"edu.ml":1,"edu.mn":1,"edu.mo":1,"edu.ms":1,"edu.mt":1,"edu.mv":1,"edu.mw":1,"edu.mx":1,"edu.my":1,"edu.mz":1,"edu.ng":1,"edu.ni":1,"edu.nr":1,"edu.om":1,"edu.pa":1,"edu.pe":1,"edu.pf":1,"edu.ph":1,"edu.pk":1,"edu.pl":1,"edu.pn":1,"edu.pr":1,"edu.ps":1,"edu.pt":1,"edu.py":1,"edu.qa":1,"edu.rs":1,"edu.ru":1,"edu.sa":1,"edu.sb":1,"edu.sc":1,"edu.sd":1,"edu.sg":1,"edu.sl":1,"edu.sn":1,"edu.so":1,"edu.ss":1,"edu.st":1,"edu.sv":1,"edu.sy":1,"edu.tj":1,"edu.tm":1,"edu.to":1,"edu.tr":1,"edu.tt":1,"edu.tw":1,"edu.ua":1,"edu.uy":1,"edu.vc":1,"edu.ve":1,"edu.vn":1,"edu.vu":1,"edu.ws":1,"edu.za":1,"edu.zm":1,"education.museum":1,"educational.museum":1,"educator.aero":1,"edugit.org":1,"edunet.tn":1,"ee.eu.org":1,"egersund.no":1,"egyptian.museum":1,"ehime.jp":1,"eid.no":1,"eidfjord.no":1,"eidsberg.no":1,"eidskog.no":1,"eidsvoll.no":1,"eigersund.no":1,"eiheiji.fukui.jp":1,"eisenbahn.museum":1,"ekloges.cy":1,"elasticbeanstalk.com":1,"elb.amazonaws.com":2,"elb.amazonaws.com.cn":2,"elblag.pl":1,"elburg.museum":1,"elk.pl":1,"elvendrell.museum":1,"elverum.no":1,"emb.kw":1,"embaixada.st":1,"embetsu.hokkaido.jp":1,"embroidery.museum":1,"emergency.aero":1,"emilia-romagna.it":1,"emiliaromagna.it":1,"emp.br":1,"empresa.bo":1,"emr.it":1,"en-root.fr":1,"en.it":1,"ena.gifu.jp":1,"encyclopedic.museum":1,"endofinternet.net":1,"endofinternet.org":1,"endoftheinternet.org":1,"enebakk.no":1,"enf.br":1,"eng.br":1,"eng.pro":1,"engerdal.no":1,"engine.aero":1,"engineer.aero":1,"england.museum":1,"eniwa.hokkaido.jp":1,"enna.it":1,"enonic.io":1,"ens.tn":1,"ent.platform.sh":1,"enterprisecloud.nu":1,"entertainment.aero":1,"entomology.museum":1,"environment.museum":1,"environmentalconservation.museum":1,"epilepsy.museum":1,"equipment.aero":1,"er":2,"erimo.hokkaido.jp":1,"erotica.hu":1,"erotika.hu":1,"es.ax":1,"es.eu.org":1,"es.gov.br":1,"es.kr":1,"es.leg.br":1,"esan.hokkaido.jp":1,"esashi.hokkaido.jp":1,"esp.br":1,"essex.museum":1,"est-a-la-maison.com":1,"est-a-la-masion.com":1,"est-le-patron.com":1,"est-mon-blogueur.com":1,"est.pr":1,"estate.museum":1,"etajima.hiroshima.jp":1,"etc.br":1,"ethnology.museum":1,"eti.br":1,"etne.no":1,"etnedal.no":1,"eu-1.evennode.com":1,"eu-2.evennode.com":1,"eu-3.evennode.com":1,"eu-4.evennode.com":1,"eu-central-1.elasticbeanstalk.com":1,"eu-west-1.elasticbeanstalk.com":1,"eu-west-2.elasticbeanstalk.com":1,"eu-west-3.elasticbeanstalk.com":1,"eu.ax":1,"eu.com":1,"eu.int":1,"eu.meteorapp.com":1,"eu.org":1,"eu.platform.sh":1,"eun.eg":1,"evenassi.no":1,"evenes.no":1,"evje-og-hornnes.no":1,"ex.futurecms.at":2,"ex.ortsinfo.at":2,"exchange.aero":1,"exeter.museum":1,"exhibition.museum":1,"exnet.su":1,"experts-comptables.fr":1,"express.aero":1,"f.bg":1,"f.se":1,"fam.pk":1,"family.museum":1,"familyds.com":1,"familyds.net":1,"familyds.org":1,"fantasyleague.cc":1,"far.br":1,"farm.museum":1,"farmequipment.museum":1,"farmers.museum":1,"farmstead.museum":1,"farsund.no":1,"fastly-terrarium.com":1,"fastlylb.net":1,"fastvps-server.com":1,"fastvps.host":1,"fastvps.site":1,"fauske.no":1,"fbx-os.fr":1,"fbxos.fr":1,"fc.it":1,"fe.it":1,"fed.us":1,"federation.aero":1,"fedje.no":1,"fedorainfracloud.org":1,"fedorapeople.org":1,"feira.br":1,"fermo.it":1,"ferrara.it":1,"feste-ip.net":1,"fet.no":1,"fetsund.no":1,"fg.it":1,"fh.se":1,"fhapp.xyz":1,"fhs.no":1,"fhsk.se":1,"fhv.se":1,"fi.cloudplatform.fi":1,"fi.cr":1,"fi.eu.org":1,"fi.it":1,"fie.ee":1,"field.museum":1,"figueres.museum":1,"filatelia.museum":1,"filegear-au.me":1,"filegear-de.me":1,"filegear-gb.me":1,"filegear-ie.me":1,"filegear-jp.me":1,"filegear-sg.me":1,"filegear.me":1,"film.hu":1,"film.museum":1,"fin.ci":1,"fin.ec":1,"fin.tn":1,"fineart.museum":1,"finearts.museum":1,"finland.museum":1,"finnoy.no":1,"firebaseapp.com":1,"firenet.ch":2,"firenze.it":1,"firewall-gateway.com":1,"firewall-gateway.de":1,"firewall-gateway.net":1,"firm.co":1,"firm.dk":1,"firm.ht":1,"firm.in":1,"firm.nf":1,"firm.ng":1,"firm.ro":1,"firm.ve":1,"fitjar.no":1,"fj.cn":1,"fjaler.no":1,"fjell.no":1,"fk":2,"fl.us":1,"fla.no":1,"flakstad.no":1,"flanders.museum":1,"flatanger.no":1,"flekkefjord.no":1,"flesberg.no":1,"flight.aero":1,"flog.br":1,"flora.no":1,"florence.it":1,"florida.museum":1,"floripa.br":1,"floro.no":1,"flt.cloud.muni.cz":1,"fly.dev":1,"flynnhosting.net":1,"fm.br":1,"fm.it":1,"fm.no":1,"fnd.br":1,"fnwk.site":1,"foggia.it":1,"folionetwork.site":1,"folkebibl.no":1,"folldal.no":1,"for-better.biz":1,"for-more.biz":1,"for-our.info":1,"for-some.biz":1,"for-the.biz":1,"for.men":1,"for.mom":1,"for.one":1,"for.sale":1,"force.museum":1,"forde.no":1,"forgot.her.name":1,"forgot.his.name":1,"forli-cesena.it":1,"forlicesena.it":1,"forsand.no":1,"fortal.br":1,"forte.id":1,"fortmissoula.museum":1,"fortworth.museum":1,"forum.hu":1,"forumz.info":1,"fosnes.no":1,"fot.br":1,"foundation.museum":1,"foz.br":1,"fr.eu.org":1,"fr.it":1,"frana.no":1,"francaise.museum":1,"frankfurt.museum":1,"franziskaner.museum":1,"fredrikstad.no":1,"free.hr":1,"freebox-os.com":1,"freebox-os.fr":1,"freeboxos.com":1,"freeboxos.fr":1,"freeddns.org":1,"freeddns.us":1,"freedesktop.org":1,"freemasonry.museum":1,"freesite.host":1,"freetls.fastly.net":1,"frei.no":1,"freiburg.museum":1,"fribourg.museum":1,"friuli-v-giulia.it":1,"friuli-ve-giulia.it":1,"friuli-vegiulia.it":1,"friuli-venezia-giulia.it":1,"friuli-veneziagiulia.it":1,"friuli-vgiulia.it":1,"friuliv-giulia.it":1,"friulive-giulia.it":1,"friulivegiulia.it":1,"friulivenezia-giulia.it":1,"friuliveneziagiulia.it":1,"friulivgiulia.it":1,"frog.museum":1,"frogn.no":1,"froland.no":1,"from-ak.com":1,"from-al.com":1,"from-ar.com":1,"from-az.net":1,"from-ca.com":1,"from-co.net":1,"from-ct.com":1,"from-dc.com":1,"from-de.com":1,"from-fl.com":1,"from-ga.com":1,"from-hi.com":1,"from-ia.com":1,"from-id.com":1,"from-il.com":1,"from-in.com":1,"from-ks.com":1,"from-ky.com":1,"from-la.net":1,"from-ma.com":1,"from-md.com":1,"from-me.org":1,"from-mi.com":1,"from-mn.com":1,"from-mo.com":1,"from-ms.com":1,"from-mt.com":1,"from-nc.com":1,"from-nd.com":1,"from-ne.com":1,"from-nh.com":1,"from-nj.com":1,"from-nm.com":1,"from-nv.com":1,"from-ny.net":1,"from-oh.com":1,"from-ok.com":1,"from-or.com":1,"from-pa.com":1,"from-pr.com":1,"from-ri.com":1,"from-sc.com":1,"from-sd.com":1,"from-tn.com":1,"from-tx.com":1,"from-ut.com":1,"from-va.com":1,"from-vt.com":1,"from-wa.com":1,"from-wi.com":1,"from-wv.com":1,"from-wy.com":1,"from.hr":1,"frosinone.it":1,"frosta.no":1,"froya.no":1,"fst.br":1,"ftpaccess.cc":1,"fuchu.hiroshima.jp":1,"fuchu.tokyo.jp":1,"fuchu.toyama.jp":1,"fudai.iwate.jp":1,"fuefuki.yamanashi.jp":1,"fuel.aero":1,"fuettertdasnetz.de":1,"fuji.shizuoka.jp":1,"fujieda.shizuoka.jp":1,"fujiidera.osaka.jp":1,"fujikawa.shizuoka.jp":1,"fujikawa.yamanashi.jp":1,"fujikawaguchiko.yamanashi.jp":1,"fujimi.nagano.jp":1,"fujimi.saitama.jp":1,"fujimino.saitama.jp":1,"fujinomiya.shizuoka.jp":1,"fujioka.gunma.jp":1,"fujisato.akita.jp":1,"fujisawa.iwate.jp":1,"fujisawa.kanagawa.jp":1,"fujishiro.ibaraki.jp":1,"fujiyoshida.yamanashi.jp":1,"fukagawa.hokkaido.jp":1,"fukaya.saitama.jp":1,"fukuchi.fukuoka.jp":1,"fukuchiyama.kyoto.jp":1,"fukudomi.saga.jp":1,"fukui.fukui.jp":1,"fukui.jp":1,"fukumitsu.toyama.jp":1,"fukuoka.jp":1,"fukuroi.shizuoka.jp":1,"fukusaki.hyogo.jp":1,"fukushima.fukushima.jp":1,"fukushima.hokkaido.jp":1,"fukushima.jp":1,"fukuyama.hiroshima.jp":1,"funabashi.chiba.jp":1,"funagata.yamagata.jp":1,"funahashi.toyama.jp":1,"fundacio.museum":1,"fuoisku.no":1,"fuossko.no":1,"furano.hokkaido.jp":1,"furniture.museum":1,"furubira.hokkaido.jp":1,"furudono.fukushima.jp":1,"furukawa.miyagi.jp":1,"fusa.no":1,"fuso.aichi.jp":1,"fussa.tokyo.jp":1,"futaba.fukushima.jp":1,"futsu.nagasaki.jp":1,"futtsu.chiba.jp":1,"futurecms.at":2,"futurehosting.at":1,"futuremailing.at":1,"fvg.it":1,"fylkesbibl.no":1,"fyresdal.no":1,"g.bg":1,"g.se":1,"g.vbrplsbx.io":1,"g12.br":1,"ga.us":1,"gaivuotna.no":1,"gallery.museum":1,"galsa.no":1,"gamagori.aichi.jp":1,"game-host.org":1,"game-server.cc":1,"game.tw":1,"games.hu":1,"gamo.shiga.jp":1,"gamvik.no":1,"gangaviika.no":1,"gangwon.kr":1,"garden.museum":1,"gateway.museum":1,"gaular.no":1,"gausdal.no":1,"gb.com":1,"gb.net":1,"gc.ca":1,"gd.cn":1,"gda.pl":1,"gdansk.pl":1,"gdynia.pl":1,"ge.it":1,"geek.nz":1,"geekgalaxy.com":1,"geelvinck.museum":1,"gehirn.ne.jp":1,"geisei.kochi.jp":1,"gemological.museum":1,"gen.in":1,"gen.mi.us":1,"gen.ng":1,"gen.nz":1,"gen.tr":1,"genkai.saga.jp":1,"genoa.it":1,"genova.it":1,"gentapps.com":1,"gentlentapis.com":1,"geo.br":1,"geology.museum":1,"geometre-expert.fr":1,"georgia.museum":1,"georgia.su":1,"getmyip.com":1,"gets-it.net":1,"gg.ax":1,"ggf.br":1,"giehtavuoatna.no":1,"giessen.museum":1,"gifu.gifu.jp":1,"gifu.jp":1,"giize.com":1,"gildeskal.no":1,"ginan.gifu.jp":1,"ginowan.okinawa.jp":1,"ginoza.okinawa.jp":1,"giske.no":1,"git-pages.rit.edu":1,"git-repos.de":1,"gitapp.si":1,"github.io":1,"githubusercontent.com":1,"gitlab.io":1,"gitpage.si":1,"gjemnes.no":1,"gjerdrum.no":1,"gjerstad.no":1,"gjesdal.no":1,"gjovik.no":1,"glas.museum":1,"glass.museum":1,"gleeze.com":1,"gliding.aero":1,"glitch.me":1,"gliwice.pl":1,"global.prod.fastly.net":1,"global.ssl.fastly.net":1,"glogow.pl":1,"gloppen.no":1,"glug.org.uk":1,"gmina.pl":1,"gniezno.pl":1,"go.ci":1,"go.cr":1,"go.dyndns.org":1,"go.gov.br":1,"go.id":1,"go.it":1,"go.jp":1,"go.ke":1,"go.kr":1,"go.leg.br":1,"go.pw":1,"go.th":1,"go.tj":1,"go.tz":1,"go.ug":1,"gob.ar":1,"gob.bo":1,"gob.cl":1,"gob.do":1,"gob.ec":1,"gob.es":1,"gob.gt":1,"gob.hn":1,"gob.mx":1,"gob.ni":1,"gob.pa":1,"gob.pe":1,"gob.pk":1,"gob.sv":1,"gob.ve":1,"gobo.wakayama.jp":1,"godo.gifu.jp":1,"goiania.br":1,"goip.de":1,"gojome.akita.jp":1,"gok.pk":1,"gokase.miyazaki.jp":1,"gol.no":1,"golffan.us":1,"gon.pk":1,"gonohe.aomori.jp":1,"googleapis.com":1,"googlecode.com":1,"gop.pk":1,"gorge.museum":1,"gorizia.it":1,"gorlice.pl":1,"gos.pk":1,"gose.nara.jp":1,"gosen.niigata.jp":1,"goshiki.hyogo.jp":1,"gotdns.ch":1,"gotdns.com":1,"gotdns.org":1,"gotemba.shizuoka.jp":1,"goto.nagasaki.jp":1,"gotpantheon.com":1,"gotsu.shimane.jp":1,"gouv.bj":1,"gouv.ci":1,"gouv.fr":1,"gouv.ht":1,"gouv.km":1,"gouv.ml":1,"gouv.sn":1,"gov.ac":1,"gov.ae":1,"gov.af":1,"gov.al":1,"gov.ar":1,"gov.as":1,"gov.au":1,"gov.az":1,"gov.ba":1,"gov.bb":1,"gov.bf":1,"gov.bh":1,"gov.bm":1,"gov.bn":1,"gov.br":1,"gov.bs":1,"gov.bt":1,"gov.by":1,"gov.bz":1,"gov.cd":1,"gov.cl":1,"gov.cm":1,"gov.cn":1,"gov.co":1,"gov.cu":1,"gov.cx":1,"gov.cy":1,"gov.dm":1,"gov.do":1,"gov.dz":1,"gov.ec":1,"gov.ee":1,"gov.eg":1,"gov.et":1,"gov.fj":1,"gov.gd":1,"gov.ge":1,"gov.gh":1,"gov.gi":1,"gov.gn":1,"gov.gr":1,"gov.gu":1,"gov.gy":1,"gov.hk":1,"gov.ie":1,"gov.il":1,"gov.in":1,"gov.iq":1,"gov.ir":1,"gov.is":1,"gov.it":1,"gov.jo":1,"gov.kg":1,"gov.ki":1,"gov.km":1,"gov.kn":1,"gov.kp":1,"gov.kw":1,"gov.ky":1,"gov.kz":1,"gov.la":1,"gov.lb":1,"gov.lc":1,"gov.lk":1,"gov.lr":1,"gov.ls":1,"gov.lt":1,"gov.lv":1,"gov.ly":1,"gov.ma":1,"gov.me":1,"gov.mg":1,"gov.mk":1,"gov.ml":1,"gov.mn":1,"gov.mo":1,"gov.mr":1,"gov.ms":1,"gov.mu":1,"gov.mv":1,"gov.mw":1,"gov.my":1,"gov.mz":1,"gov.nc.tr":1,"gov.ng":1,"gov.nr":1,"gov.om":1,"gov.ph":1,"gov.pk":1,"gov.pl":1,"gov.pn":1,"gov.pr":1,"gov.ps":1,"gov.pt":1,"gov.py":1,"gov.qa":1,"gov.rs":1,"gov.ru":1,"gov.rw":1,"gov.sa":1,"gov.sb":1,"gov.sc":1,"gov.scot":1,"gov.sd":1,"gov.sg":1,"gov.sh":1,"gov.sl":1,"gov.so":1,"gov.ss":1,"gov.st":1,"gov.sx":1,"gov.sy":1,"gov.tj":1,"gov.tl":1,"gov.tm":1,"gov.tn":1,"gov.to":1,"gov.tr":1,"gov.tt":1,"gov.tw":1,"gov.ua":1,"gov.uk":1,"gov.vc":1,"gov.ve":1,"gov.vn":1,"gov.ws":1,"gov.za":1,"gov.zm":1,"gov.zw":1,"government.aero":1,"govt.nz":1,"gr.com":1,"gr.eu.org":1,"gr.it":1,"gr.jp":1,"grajewo.pl":1,"gran.no":1,"grandrapids.museum":1,"grane.no":1,"granvin.no":1,"graphox.us":1,"gratangen.no":1,"graz.museum":1,"greta.fr":1,"grimstad.no":1,"griw.gov.pl":1,"groks-the.info":1,"groks-this.info":1,"grondar.za":1,"grong.no":1,"grosseto.it":1,"groundhandling.aero":1,"group.aero":1,"grozny.ru":1,"grozny.su":1,"grp.lk":1,"gru.br":1,"grue.no":1,"gs.aa.no":1,"gs.ah.no":1,"gs.bu.no":1,"gs.cn":1,"gs.fm.no":1,"gs.hl.no":1,"gs.hm.no":1,"gs.jan-mayen.no":1,"gs.mr.no":1,"gs.nl.no":1,"gs.nt.no":1,"gs.of.no":1,"gs.ol.no":1,"gs.oslo.no":1,"gs.rl.no":1,"gs.sf.no":1,"gs.st.no":1,"gs.svalbard.no":1,"gs.tm.no":1,"gs.tr.no":1,"gs.va.no":1,"gs.vf.no":1,"gsj.bz":1,"gsm.pl":1,"gu.us":1,"guam.gu":1,"gub.uy":1,"guernsey.museum":1,"gujo.gifu.jp":1,"gulen.no":1,"gunma.jp":1,"guovdageaidnu.no":1,"gushikami.okinawa.jp":1,"gv.ao":1,"gv.at":1,"gv.vc":1,"gwangju.kr":1,"gwiddle.co.uk":1,"gx.cn":1,"gyeongbuk.kr":1,"gyeonggi.kr":1,"gyeongnam.kr":1,"gyokuto.kumamoto.jp":1,"gz.cn":1,"h.bg":1,"h.se":1,"ha.cn":1,"ha.no":1,"habikino.osaka.jp":1,"habmer.no":1,"haboro.hokkaido.jp":1,"hachijo.tokyo.jp":1,"hachinohe.aomori.jp":1,"hachioji.tokyo.jp":1,"hachirogata.akita.jp":1,"hadano.kanagawa.jp":1,"hadsel.no":1,"haebaru.okinawa.jp":1,"haga.tochigi.jp":1,"hagebostad.no":1,"hagi.yamaguchi.jp":1,"haibara.shizuoka.jp":1,"hakata.fukuoka.jp":1,"hakodate.hokkaido.jp":1,"hakone.kanagawa.jp":1,"hakuba.nagano.jp":1,"hakui.ishikawa.jp":1,"hakusan.ishikawa.jp":1,"halden.no":1,"half.host":1,"halloffame.museum":1,"halsa.no":1,"ham-radio-op.net":1,"hamada.shimane.jp":1,"hamamatsu.shizuoka.jp":1,"hamar.no":1,"hamaroy.no":1,"hamatama.saga.jp":1,"hamatonbetsu.hokkaido.jp":1,"hamburg.museum":1,"hammarfeasta.no":1,"hammerfest.no":1,"hamura.tokyo.jp":1,"hanamaki.iwate.jp":1,"hanamigawa.chiba.jp":1,"hanawa.fukushima.jp":1,"handa.aichi.jp":1,"handson.museum":1,"hanggliding.aero":1,"hannan.osaka.jp":1,"hanno.saitama.jp":1,"hanyu.saitama.jp":1,"hapmir.no":1,"happou.akita.jp":1,"hara.nagano.jp":1,"haram.no":1,"hareid.no":1,"harima.hyogo.jp":1,"harstad.no":1,"harvestcelebration.museum":1,"hasama.oita.jp":1,"hasami.nagasaki.jp":1,"hashbang.sh":1,"hashikami.aomori.jp":1,"hashima.gifu.jp":1,"hashimoto.wakayama.jp":1,"hasuda.saitama.jp":1,"hasura-app.io":1,"hasura.app":1,"hasvik.no":1,"hatogaya.saitama.jp":1,"hatoyama.saitama.jp":1,"hatsukaichi.hiroshima.jp":1,"hattfjelldal.no":1,"haugesund.no":1,"hawaii.museum":1,"hayakawa.yamanashi.jp":1,"hayashima.okayama.jp":1,"hazu.aichi.jp":1,"hb.cldmail.ru":1,"hb.cn":1,"he.cn":1,"health-carereform.com":1,"health.museum":1,"health.nz":1,"health.vn":1,"heguri.nara.jp":1,"heimatunduhren.museum":1,"hekinan.aichi.jp":1,"hellas.museum":1,"helsinki.museum":1,"hembygdsforbund.museum":1,"hemne.no":1,"hemnes.no":1,"hemsedal.no":1,"hepforge.org":1,"herad.no":1,"here-for-more.info":1,"heritage.museum":1,"herokuapp.com":1,"herokussl.com":1,"heroy.more-og-romsdal.no":1,"heroy.nordland.no":1,"hi.cn":1,"hi.us":1,"hicam.net":1,"hichiso.gifu.jp":1,"hida.gifu.jp":1,"hidaka.hokkaido.jp":1,"hidaka.kochi.jp":1,"hidaka.saitama.jp":1,"hidaka.wakayama.jp":1,"hidora.com":1,"higashi.fukuoka.jp":1,"higashi.fukushima.jp":1,"higashi.okinawa.jp":1,"higashiagatsuma.gunma.jp":1,"higashichichibu.saitama.jp":1,"higashihiroshima.hiroshima.jp":1,"higashiizu.shizuoka.jp":1,"higashiizumo.shimane.jp":1,"higashikagawa.kagawa.jp":1,"higashikagura.hokkaido.jp":1,"higashikawa.hokkaido.jp":1,"higashikurume.tokyo.jp":1,"higashimatsushima.miyagi.jp":1,"higashimatsuyama.saitama.jp":1,"higashimurayama.tokyo.jp":1,"higashinaruse.akita.jp":1,"higashine.yamagata.jp":1,"higashiomi.shiga.jp":1,"higashiosaka.osaka.jp":1,"higashishirakawa.gifu.jp":1,"higashisumiyoshi.osaka.jp":1,"higashitsuno.kochi.jp":1,"higashiura.aichi.jp":1,"higashiyama.kyoto.jp":1,"higashiyamato.tokyo.jp":1,"higashiyodogawa.osaka.jp":1,"higashiyoshino.nara.jp":1,"hiji.oita.jp":1,"hikari.yamaguchi.jp":1,"hikawa.shimane.jp":1,"hikimi.shimane.jp":1,"hikone.shiga.jp":1,"himeji.hyogo.jp":1,"himeshima.oita.jp":1,"himi.toyama.jp":1,"hino.tokyo.jp":1,"hino.tottori.jp":1,"hinode.tokyo.jp":1,"hinohara.tokyo.jp":1,"hioki.kagoshima.jp":1,"hirado.nagasaki.jp":1,"hiraizumi.iwate.jp":1,"hirakata.osaka.jp":1,"hiranai.aomori.jp":1,"hirara.okinawa.jp":1,"hirata.fukushima.jp":1,"hiratsuka.kanagawa.jp":1,"hiraya.nagano.jp":1,"hirogawa.wakayama.jp":1,"hirokawa.fukuoka.jp":1,"hirono.fukushima.jp":1,"hirono.iwate.jp":1,"hiroo.hokkaido.jp":1,"hirosaki.aomori.jp":1,"hiroshima.jp":1,"hisayama.fukuoka.jp":1,"histoire.museum":1,"historical.museum":1,"historicalsociety.museum":1,"historichouses.museum":1,"historisch.museum":1,"historisches.museum":1,"history.museum":1,"historyofscience.museum":1,"hita.oita.jp":1,"hitachi.ibaraki.jp":1,"hitachinaka.ibaraki.jp":1,"hitachiomiya.ibaraki.jp":1,"hitachiota.ibaraki.jp":1,"hitra.no":1,"hizen.saga.jp":1,"hjartdal.no":1,"hjelmeland.no":1,"hk.cn":1,"hk.com":1,"hk.org":1,"hl.cn":1,"hl.no":1,"hm.no":1,"hn.cn":1,"hobby-site.com":1,"hobby-site.org":1,"hobol.no":1,"hof.no":1,"hofu.yamaguchi.jp":1,"hokkaido.jp":1,"hokksund.no":1,"hokuryu.hokkaido.jp":1,"hokuto.hokkaido.jp":1,"hokuto.yamanashi.jp":1,"hol.no":1,"hole.no":1,"holmestrand.no":1,"holtalen.no":1,"home-webserver.de":1,"home.dyndns.org":1,"homebuilt.aero":1,"homedns.org":1,"homeftp.net":1,"homeftp.org":1,"homeip.net":1,"homelink.one":1,"homelinux.com":1,"homelinux.net":1,"homelinux.org":1,"homeoffice.gov.uk":1,"homesecuritymac.com":1,"homesecuritypc.com":1,"homeunix.com":1,"homeunix.net":1,"homeunix.org":1,"honai.ehime.jp":1,"honbetsu.hokkaido.jp":1,"honefoss.no":1,"hongo.hiroshima.jp":1,"honjo.akita.jp":1,"honjo.saitama.jp":1,"honjyo.akita.jp":1,"hopto.me":1,"hopto.org":1,"hornindal.no":1,"horokanai.hokkaido.jp":1,"horology.museum":1,"horonobe.hokkaido.jp":1,"horten.no":1,"hostedpi.com":1,"hosting-cluster.nl":1,"hosting.myjino.ru":2,"hostyhosting.io":1,"hotel.hu":1,"hotel.lk":1,"hotel.tz":1,"house.museum":1,"hoyanger.no":1,"hoylandet.no":1,"hr.eu.org":1,"hs.kr":1,"hs.run":1,"hs.zone":1,"hu.com":1,"hu.eu.org":1,"hu.net":1,"huissier-justice.fr":1,"humanities.museum":1,"hurdal.no":1,"hurum.no":1,"hvaler.no":1,"hyllestad.no":1,"hyogo.jp":1,"hyuga.miyazaki.jp":1,"hzc.io":1,"i.bg":1,"i.ng":1,"i.ph":1,"i.se":1,"i234.me":1,"ia.us":1,"iamallama.com":1,"ibara.okayama.jp":1,"ibaraki.ibaraki.jp":1,"ibaraki.jp":1,"ibaraki.osaka.jp":1,"ibestad.no":1,"ibigawa.gifu.jp":1,"ic.gov.pl":1,"ichiba.tokushima.jp":1,"ichihara.chiba.jp":1,"ichikai.tochigi.jp":1,"ichikawa.chiba.jp":1,"ichikawa.hyogo.jp":1,"ichikawamisato.yamanashi.jp":1,"ichinohe.iwate.jp":1,"ichinomiya.aichi.jp":1,"ichinomiya.chiba.jp":1,"ichinoseki.iwate.jp":1,"id.au":1,"id.ir":1,"id.lv":1,"id.ly":1,"id.us":1,"ide.kyoto.jp":1,"idf.il":1,"idrett.no":1,"idv.hk":1,"idv.tw":1,"ie.eu.org":1,"if.ua":1,"iglesias-carbonia.it":1,"iglesiascarbonia.it":1,"iheya.okinawa.jp":1,"iida.nagano.jp":1,"iide.yamagata.jp":1,"iijima.nagano.jp":1,"iitate.fukushima.jp":1,"iiyama.nagano.jp":1,"iizuka.fukuoka.jp":1,"iizuna.nagano.jp":1,"ikaruga.nara.jp":1,"ikata.ehime.jp":1,"ikawa.akita.jp":1,"ikeda.fukui.jp":1,"ikeda.gifu.jp":1,"ikeda.hokkaido.jp":1,"ikeda.nagano.jp":1,"ikeda.osaka.jp":1,"iki.fi":1,"iki.nagasaki.jp":1,"ikoma.nara.jp":1,"ikusaka.nagano.jp":1,"il.eu.org":1,"il.us":1,"ilawa.pl":1,"illustration.museum":1,"ilovecollege.info":1,"im.it":1,"imabari.ehime.jp":1,"imageandsound.museum":1,"imakane.hokkaido.jp":1,"imari.saga.jp":1,"imb.br":1,"imizu.toyama.jp":1,"imperia.it":1,"impertrix.com":1,"impertrixcdn.com":1,"in-addr.arpa":1,"in-berlin.de":1,"in-brb.de":1,"in-butter.de":1,"in-dsl.de":1,"in-dsl.net":1,"in-dsl.org":1,"in-the-band.net":1,"in-vpn.de":1,"in-vpn.net":1,"in-vpn.org":1,"in.eu.org":1,"in.futurecms.at":2,"in.london":1,"in.na":1,"in.net":1,"in.ni":1,"in.rs":1,"in.th":1,"in.ua":1,"in.us":1,"ina.ibaraki.jp":1,"ina.nagano.jp":1,"ina.saitama.jp":1,"inabe.mie.jp":1,"inagawa.hyogo.jp":1,"inagi.tokyo.jp":1,"inami.toyama.jp":1,"inami.wakayama.jp":1,"inashiki.ibaraki.jp":1,"inatsuki.fukuoka.jp":1,"inawashiro.fukushima.jp":1,"inazawa.aichi.jp":1,"inc.hk":1,"incheon.kr":1,"ind.br":1,"ind.gt":1,"ind.in":1,"ind.kw":1,"ind.tn":1,"inderoy.no":1,"indian.museum":1,"indiana.museum":1,"indianapolis.museum":1,"indianmarket.museum":1,"indie.porn":1,"indigena.bo":1,"industria.bo":1,"ine.kyoto.jp":1,"inf.br":1,"inf.cu":1,"inf.mk":1,"inf.ua":1,"info.at":1,"info.au":1,"info.az":1,"info.bb":1,"info.bo":1,"info.co":1,"info.cx":1,"info.ec":1,"info.et":1,"info.fj":1,"info.gu":1,"info.ht":1,"info.hu":1,"info.ke":1,"info.ki":1,"info.la":1,"info.ls":1,"info.mv":1,"info.na":1,"info.nf":1,"info.ni":1,"info.nr":1,"info.pk":1,"info.pl":1,"info.pr":1,"info.ro":1,"info.sd":1,"info.tn":1,"info.tr":1,"info.tt":1,"info.tz":1,"info.ve":1,"info.vn":1,"info.zm":1,"ing.pa":1,"ingatlan.hu":1,"ino.kochi.jp":1,"instantcloud.cn":1,"insurance.aero":1,"int.ar":1,"int.az":1,"int.bo":1,"int.ci":1,"int.co":1,"int.eu.org":1,"int.is":1,"int.la":1,"int.lk":1,"int.mv":1,"int.mw":1,"int.ni":1,"int.pt":1,"int.ru":1,"int.tj":1,"int.tt":1,"int.ve":1,"int.vn":1,"intelligence.museum":1,"interactive.museum":1,"internet-dns.de":1,"intl.tn":1,"inuyama.aichi.jp":1,"inzai.chiba.jp":1,"io.kg":1,"iobb.net":1,"ip6.arpa":1,"ipifony.net":1,"iraq.museum":1,"iris.arpa":1,"iron.museum":1,"iruma.saitama.jp":1,"is-a-anarchist.com":1,"is-a-blogger.com":1,"is-a-bookkeeper.com":1,"is-a-bruinsfan.org":1,"is-a-bulls-fan.com":1,"is-a-candidate.org":1,"is-a-caterer.com":1,"is-a-celticsfan.org":1,"is-a-chef.com":1,"is-a-chef.net":1,"is-a-chef.org":1,"is-a-conservative.com":1,"is-a-cpa.com":1,"is-a-cubicle-slave.com":1,"is-a-democrat.com":1,"is-a-designer.com":1,"is-a-doctor.com":1,"is-a-financialadvisor.com":1,"is-a-geek.com":1,"is-a-geek.net":1,"is-a-geek.org":1,"is-a-green.com":1,"is-a-guru.com":1,"is-a-hard-worker.com":1,"is-a-hunter.com":1,"is-a-knight.org":1,"is-a-landscaper.com":1,"is-a-lawyer.com":1,"is-a-liberal.com":1,"is-a-libertarian.com":1,"is-a-linux-user.org":1,"is-a-llama.com":1,"is-a-musician.com":1,"is-a-nascarfan.com":1,"is-a-nurse.com":1,"is-a-painter.com":1,"is-a-patsfan.org":1,"is-a-personaltrainer.com":1,"is-a-photographer.com":1,"is-a-player.com":1,"is-a-republican.com":1,"is-a-rockstar.com":1,"is-a-socialist.com":1,"is-a-soxfan.org":1,"is-a-student.com":1,"is-a-teacher.com":1,"is-a-techie.com":1,"is-a-therapist.com":1,"is-an-accountant.com":1,"is-an-actor.com":1,"is-an-actress.com":1,"is-an-anarchist.com":1,"is-an-artist.com":1,"is-an-engineer.com":1,"is-an-entertainer.com":1,"is-by.us":1,"is-certified.com":1,"is-found.org":1,"is-gone.com":1,"is-into-anime.com":1,"is-into-cars.com":1,"is-into-cartoons.com":1,"is-into-games.com":1,"is-leet.com":1,"is-lost.org":1,"is-not-certified.com":1,"is-saved.org":1,"is-slick.com":1,"is-uberleet.com":1,"is-very-bad.org":1,"is-very-evil.org":1,"is-very-good.org":1,"is-very-nice.org":1,"is-very-sweet.org":1,"is-with-theband.com":1,"is.eu.org":1,"is.gov.pl":1,"is.it":1,"isa-geek.com":1,"isa-geek.net":1,"isa-geek.org":1,"isa-hockeynut.com":1,"isa.kagoshima.jp":1,"isa.us":1,"isahaya.nagasaki.jp":1,"ise.mie.jp":1,"isehara.kanagawa.jp":1,"isen.kagoshima.jp":1,"isernia.it":1,"iserv.dev":1,"isesaki.gunma.jp":1,"ishigaki.okinawa.jp":1,"ishikari.hokkaido.jp":1,"ishikawa.fukushima.jp":1,"ishikawa.jp":1,"ishikawa.okinawa.jp":1,"ishinomaki.miyagi.jp":1,"isla.pr":1,"isleofman.museum":1,"isshiki.aichi.jp":1,"issmarterthanyou.com":1,"isteingeek.de":1,"istmein.de":1,"isumi.chiba.jp":1,"it.ao":1,"it.eu.org":1,"itabashi.tokyo.jp":1,"itako.ibaraki.jp":1,"itakura.gunma.jp":1,"itami.hyogo.jp":1,"itano.tokushima.jp":1,"itayanagi.aomori.jp":1,"ito.shizuoka.jp":1,"itoigawa.niigata.jp":1,"itoman.okinawa.jp":1,"its.me":1,"ivano-frankivsk.ua":1,"ivanovo.su":1,"iveland.no":1,"ivgu.no":1,"iwade.wakayama.jp":1,"iwafune.tochigi.jp":1,"iwaizumi.iwate.jp":1,"iwaki.fukushima.jp":1,"iwakuni.yamaguchi.jp":1,"iwakura.aichi.jp":1,"iwama.ibaraki.jp":1,"iwamizawa.hokkaido.jp":1,"iwanai.hokkaido.jp":1,"iwanuma.miyagi.jp":1,"iwata.shizuoka.jp":1,"iwate.iwate.jp":1,"iwate.jp":1,"iwatsuki.saitama.jp":1,"iwi.nz":1,"iyo.ehime.jp":1,"iz.hr":1,"izena.okinawa.jp":1,"izu.shizuoka.jp":1,"izumi.kagoshima.jp":1,"izumi.osaka.jp":1,"izumiotsu.osaka.jp":1,"izumisano.osaka.jp":1,"izumizaki.fukushima.jp":1,"izumo.shimane.jp":1,"izumozaki.niigata.jp":1,"izunokuni.shizuoka.jp":1,"j.bg":1,"j.layershift.co.uk":1,"j.scaleforce.com.cy":1,"jab.br":1,"jambyl.su":1,"jamison.museum":1,"jampa.br":1,"jan-mayen.no":1,"jaworzno.pl":1,"jcloud.ik-server.com":1,"jdevcloud.com":1,"jdf.br":1,"jefferson.museum":1,"jeju.kr":1,"jelastic.dogado.eu":1,"jelastic.regruhosting.ru":1,"jelastic.saveincloud.net":1,"jelastic.team":1,"jele.cloud":1,"jele.club":1,"jele.host":1,"jele.io":1,"jele.site":1,"jelenia-gora.pl":1,"jeonbuk.kr":1,"jeonnam.kr":1,"jerusalem.museum":1,"jessheim.no":1,"jevnaker.no":1,"jewelry.museum":1,"jewish.museum":1,"jewishart.museum":1,"jfk.museum":1,"jgora.pl":1,"jinsekikogen.hiroshima.jp":1,"jl.cn":1,"jls-sto1.elastx.net":1,"jm":2,"joboji.iwate.jp":1,"jobs.tt":1,"joetsu.niigata.jp":1,"jogasz.hu":1,"johana.toyama.jp":1,"joinville.br":1,"jolster.no":1,"jondal.no":1,"jor.br":1,"jorpeland.no":1,"joso.ibaraki.jp":1,"journal.aero":1,"journalism.museum":1,"journalist.aero":1,"joyo.kyoto.jp":1,"jozi.biz":1,"jp.eu.org":1,"jp.kg":1,"jp.md":1,"jp.net":1,"jpn.com":1,"js.cn":1,"js.org":1,"judaica.museum":1,"judygarland.museum":1,"juedisches.museum":1,"juif.museum":1,"jur.pro":1,"jus.br":1,"jx.cn":1,"k.bg":1,"k.se":1,"k12.ak.us":1,"k12.al.us":1,"k12.ar.us":1,"k12.as.us":1,"k12.az.us":1,"k12.ca.us":1,"k12.co.us":1,"k12.ct.us":1,"k12.dc.us":1,"k12.de.us":1,"k12.ec":1,"k12.fl.us":1,"k12.ga.us":1,"k12.gu.us":1,"k12.ia.us":1,"k12.id.us":1,"k12.il":1,"k12.il.us":1,"k12.in.us":1,"k12.ks.us":1,"k12.ky.us":1,"k12.la.us":1,"k12.ma.us":1,"k12.md.us":1,"k12.me.us":1,"k12.mi.us":1,"k12.mn.us":1,"k12.mo.us":1,"k12.ms.us":1,"k12.mt.us":1,"k12.nc.us":1,"k12.ne.us":1,"k12.nh.us":1,"k12.nj.us":1,"k12.nm.us":1,"k12.nv.us":1,"k12.ny.us":1,"k12.oh.us":1,"k12.ok.us":1,"k12.or.us":1,"k12.pa.us":1,"k12.pr.us":1,"k12.sc.us":1,"k12.tn.us":1,"k12.tr":1,"k12.tx.us":1,"k12.ut.us":1,"k12.va.us":1,"k12.vi":1,"k12.vi.us":1,"k12.vt.us":1,"k12.wa.us":1,"k12.wi.us":1,"k12.wy.us":1,"kaas.gg":1,"kadena.okinawa.jp":1,"kadogawa.miyazaki.jp":1,"kadoma.osaka.jp":1,"kafjord.no":1,"kaga.ishikawa.jp":1,"kagami.kochi.jp":1,"kagamiishi.fukushima.jp":1,"kagamino.okayama.jp":1,"kagawa.jp":1,"kagoshima.jp":1,"kagoshima.kagoshima.jp":1,"kaho.fukuoka.jp":1,"kahoku.ishikawa.jp":1,"kahoku.yamagata.jp":1,"kai.yamanashi.jp":1,"kainan.tokushima.jp":1,"kainan.wakayama.jp":1,"kaisei.kanagawa.jp":1,"kaita.hiroshima.jp":1,"kaizuka.osaka.jp":1,"kakamigahara.gifu.jp":1,"kakegawa.shizuoka.jp":1,"kakinoki.shimane.jp":1,"kakogawa.hyogo.jp":1,"kakuda.miyagi.jp":1,"kalisz.pl":1,"kalmykia.ru":1,"kalmykia.su":1,"kaluga.su":1,"kamagaya.chiba.jp":1,"kamaishi.iwate.jp":1,"kamakura.kanagawa.jp":1,"kameoka.kyoto.jp":1,"kameyama.mie.jp":1,"kami.kochi.jp":1,"kami.miyagi.jp":1,"kamiamakusa.kumamoto.jp":1,"kamifurano.hokkaido.jp":1,"kamigori.hyogo.jp":1,"kamiichi.toyama.jp":1,"kamiizumi.saitama.jp":1,"kamijima.ehime.jp":1,"kamikawa.hokkaido.jp":1,"kamikawa.hyogo.jp":1,"kamikawa.saitama.jp":1,"kamikitayama.nara.jp":1,"kamikoani.akita.jp":1,"kamimine.saga.jp":1,"kaminokawa.tochigi.jp":1,"kaminoyama.yamagata.jp":1,"kamioka.akita.jp":1,"kamisato.saitama.jp":1,"kamishihoro.hokkaido.jp":1,"kamisu.ibaraki.jp":1,"kamisunagawa.hokkaido.jp":1,"kamitonda.wakayama.jp":1,"kamitsue.oita.jp":1,"kamo.kyoto.jp":1,"kamo.niigata.jp":1,"kamoenai.hokkaido.jp":1,"kamogawa.chiba.jp":1,"kanagawa.jp":1,"kanan.osaka.jp":1,"kanazawa.ishikawa.jp":1,"kanegasaki.iwate.jp":1,"kaneyama.fukushima.jp":1,"kaneyama.yamagata.jp":1,"kani.gifu.jp":1,"kanie.aichi.jp":1,"kanmaki.nara.jp":1,"kanna.gunma.jp":1,"kannami.shizuoka.jp":1,"kanonji.kagawa.jp":1,"kanoya.kagoshima.jp":1,"kanra.gunma.jp":1,"kanuma.tochigi.jp":1,"kanzaki.saga.jp":1,"karacol.su":1,"karaganda.su":1,"karasjohka.no":1,"karasjok.no":1,"karasuyama.tochigi.jp":1,"karate.museum":1,"karatsu.saga.jp":1,"karelia.su":1,"karikatur.museum":1,"kariwa.niigata.jp":1,"kariya.aichi.jp":1,"karlsoy.no":1,"karmoy.no":1,"karpacz.pl":1,"kartuzy.pl":1,"karuizawa.nagano.jp":1,"karumai.iwate.jp":1,"kasahara.gifu.jp":1,"kasai.hyogo.jp":1,"kasama.ibaraki.jp":1,"kasamatsu.gifu.jp":1,"kasaoka.okayama.jp":1,"kashiba.nara.jp":1,"kashihara.nara.jp":1,"kashima.ibaraki.jp":1,"kashima.saga.jp":1,"kashiwa.chiba.jp":1,"kashiwara.osaka.jp":1,"kashiwazaki.niigata.jp":1,"kasserver.com":1,"kasuga.fukuoka.jp":1,"kasuga.hyogo.jp":1,"kasugai.aichi.jp":1,"kasukabe.saitama.jp":1,"kasumigaura.ibaraki.jp":1,"kasuya.fukuoka.jp":1,"kaszuby.pl":1,"katagami.akita.jp":1,"katano.osaka.jp":1,"katashina.gunma.jp":1,"katori.chiba.jp":1,"katowice.pl":1,"katsuragi.nara.jp":1,"katsuragi.wakayama.jp":1,"katsushika.tokyo.jp":1,"katsuura.chiba.jp":1,"katsuyama.fukui.jp":1,"kautokeino.no":1,"kawaba.gunma.jp":1,"kawachinagano.osaka.jp":1,"kawagoe.mie.jp":1,"kawagoe.saitama.jp":1,"kawaguchi.saitama.jp":1,"kawahara.tottori.jp":1,"kawai.iwate.jp":1,"kawai.nara.jp":1,"kawajima.saitama.jp":1,"kawakami.nagano.jp":1,"kawakami.nara.jp":1,"kawakita.ishikawa.jp":1,"kawamata.fukushima.jp":1,"kawaminami.miyazaki.jp":1,"kawanabe.kagoshima.jp":1,"kawanehon.shizuoka.jp":1,"kawanishi.hyogo.jp":1,"kawanishi.nara.jp":1,"kawanishi.yamagata.jp":1,"kawara.fukuoka.jp":1,"kawasaki.jp":2,"kawasaki.miyagi.jp":1,"kawatana.nagasaki.jp":1,"kawaue.gifu.jp":1,"kawazu.shizuoka.jp":1,"kayabe.hokkaido.jp":1,"kazimierz-dolny.pl":1,"kazo.saitama.jp":1,"kazuno.akita.jp":1,"keisen.fukuoka.jp":1,"kembuchi.hokkaido.jp":1,"kep.tr":1,"kepno.pl":1,"ketrzyn.pl":1,"keymachine.de":1,"kg.kr":1,"kh":2,"kh.ua":1,"khakassia.su":1,"kharkiv.ua":1,"kharkov.ua":1,"kherson.ua":1,"khmelnitskiy.ua":1,"khmelnytskyi.ua":1,"khplay.nl":1,"kibichuo.okayama.jp":1,"kicks-ass.net":1,"kicks-ass.org":1,"kids.museum":1,"kids.us":1,"kiev.ua":1,"kiho.mie.jp":1,"kihoku.ehime.jp":1,"kijo.miyazaki.jp":1,"kikonai.hokkaido.jp":1,"kikuchi.kumamoto.jp":1,"kikugawa.shizuoka.jp":1,"kimino.wakayama.jp":1,"kimitsu.chiba.jp":1,"kimobetsu.hokkaido.jp":1,"kin.okinawa.jp":1,"kinghost.net":1,"kinko.kagoshima.jp":1,"kinokawa.wakayama.jp":1,"kira.aichi.jp":1,"kirkenes.no":1,"kirovograd.ua":1,"kiryu.gunma.jp":1,"kisarazu.chiba.jp":1,"kishiwada.osaka.jp":1,"kiso.nagano.jp":1,"kisofukushima.nagano.jp":1,"kisosaki.mie.jp":1,"kita.kyoto.jp":1,"kita.osaka.jp":1,"kita.tokyo.jp":1,"kitaaiki.nagano.jp":1,"kitaakita.akita.jp":1,"kitadaito.okinawa.jp":1,"kitagata.gifu.jp":1,"kitagata.saga.jp":1,"kitagawa.kochi.jp":1,"kitagawa.miyazaki.jp":1,"kitahata.saga.jp":1,"kitahiroshima.hokkaido.jp":1,"kitakami.iwate.jp":1,"kitakata.fukushima.jp":1,"kitakata.miyazaki.jp":1,"kitakyushu.jp":2,"kitami.hokkaido.jp":1,"kitamoto.saitama.jp":1,"kitanakagusuku.okinawa.jp":1,"kitashiobara.fukushima.jp":1,"kitaura.miyazaki.jp":1,"kitayama.wakayama.jp":1,"kiwa.mie.jp":1,"kiwi.nz":1,"kiyama.saga.jp":1,"kiyokawa.kanagawa.jp":1,"kiyosato.hokkaido.jp":1,"kiyose.tokyo.jp":1,"kiyosu.aichi.jp":1,"kizu.kyoto.jp":1,"klabu.no":1,"klepp.no":1,"klodzko.pl":1,"km.ua":1,"kmpsp.gov.pl":1,"knightpoint.systems":1,"knowsitall.info":1,"knx-server.net":1,"kobayashi.miyazaki.jp":1,"kobe.jp":2,"kobierzyce.pl":1,"kochi.jp":1,"kochi.kochi.jp":1,"kodaira.tokyo.jp":1,"koebenhavn.museum":1,"koeln.museum":1,"kofu.yamanashi.jp":1,"koga.fukuoka.jp":1,"koga.ibaraki.jp":1,"koganei.tokyo.jp":1,"koge.tottori.jp":1,"koka.shiga.jp":1,"kokonoe.oita.jp":1,"kokubunji.tokyo.jp":1,"kolobrzeg.pl":1,"komae.tokyo.jp":1,"komagane.nagano.jp":1,"komaki.aichi.jp":1,"komatsu.ishikawa.jp":1,"komatsushima.tokushima.jp":1,"komforb.se":1,"kommunalforbund.se":1,"kommune.no":1,"komono.mie.jp":1,"komoro.nagano.jp":1,"komvux.se":1,"konan.aichi.jp":1,"konan.shiga.jp":1,"kongsberg.no":1,"kongsvinger.no":1,"konin.pl":1,"konskowola.pl":1,"konsulat.gov.pl":1,"konyvelo.hu":1,"koori.fukushima.jp":1,"kopervik.no":1,"koriyama.fukushima.jp":1,"koryo.nara.jp":1,"kosai.shizuoka.jp":1,"kosaka.akita.jp":1,"kosei.shiga.jp":1,"koshigaya.saitama.jp":1,"koshimizu.hokkaido.jp":1,"koshu.yamanashi.jp":1,"kosuge.yamanashi.jp":1,"kota.aichi.jp":1,"koto.shiga.jp":1,"koto.tokyo.jp":1,"kotohira.kagawa.jp":1,"kotoura.tottori.jp":1,"kouhoku.saga.jp":1,"kounosu.saitama.jp":1,"kouyama.kagoshima.jp":1,"kouzushima.tokyo.jp":1,"koya.wakayama.jp":1,"koza.wakayama.jp":1,"kozagawa.wakayama.jp":1,"kozaki.chiba.jp":1,"kozow.com":1,"kppsp.gov.pl":1,"kr.com":1,"kr.eu.org":1,"kr.it":1,"kr.ua":1,"kraanghke.no":1,"kragero.no":1,"krakow.pl":1,"krasnik.pl":1,"krasnodar.su":1,"kristiansand.no":1,"kristiansund.no":1,"krodsherad.no":1,"krokstadelva.no":1,"krym.ua":1,"ks.ua":1,"ks.us":1,"kuchinotsu.nagasaki.jp":1,"kudamatsu.yamaguchi.jp":1,"kudoyama.wakayama.jp":1,"kui.hiroshima.jp":1,"kuji.iwate.jp":1,"kuju.oita.jp":1,"kujukuri.chiba.jp":1,"kuki.saitama.jp":1,"kumagaya.saitama.jp":1,"kumakogen.ehime.jp":1,"kumamoto.jp":1,"kumamoto.kumamoto.jp":1,"kumano.hiroshima.jp":1,"kumano.mie.jp":1,"kumatori.osaka.jp":1,"kumejima.okinawa.jp":1,"kumenan.okayama.jp":1,"kumiyama.kyoto.jp":1,"kunden.ortsinfo.at":2,"kunigami.okinawa.jp":1,"kunimi.fukushima.jp":1,"kunisaki.oita.jp":1,"kunitachi.tokyo.jp":1,"kunitomi.miyazaki.jp":1,"kunneppu.hokkaido.jp":1,"kunohe.iwate.jp":1,"kunst.museum":1,"kunstsammlung.museum":1,"kunstunddesign.museum":1,"kurashiki.okayama.jp":1,"kurate.fukuoka.jp":1,"kure.hiroshima.jp":1,"kurgan.su":1,"kuriyama.hokkaido.jp":1,"kurobe.toyama.jp":1,"kurogi.fukuoka.jp":1,"kuroishi.aomori.jp":1,"kuroiso.tochigi.jp":1,"kuromatsunai.hokkaido.jp":1,"kurotaki.nara.jp":1,"kurume.fukuoka.jp":1,"kusatsu.gunma.jp":1,"kusatsu.shiga.jp":1,"kushima.miyazaki.jp":1,"kushimoto.wakayama.jp":1,"kushiro.hokkaido.jp":1,"kustanai.ru":1,"kustanai.su":1,"kusu.oita.jp":1,"kutchan.hokkaido.jp":1,"kutno.pl":1,"kuwana.mie.jp":1,"kuzumaki.iwate.jp":1,"kv.ua":1,"kvafjord.no":1,"kvalsund.no":1,"kvam.no":1,"kvanangen.no":1,"kvinesdal.no":1,"kvinnherad.no":1,"kviteseid.no":1,"kvitsoy.no":1,"kwp.gov.pl":1,"kwpsp.gov.pl":1,"ky.us":1,"kyiv.ua":1,"kyonan.chiba.jp":1,"kyotamba.kyoto.jp":1,"kyotanabe.kyoto.jp":1,"kyotango.kyoto.jp":1,"kyoto.jp":1,"kyowa.akita.jp":1,"kyowa.hokkaido.jp":1,"kyuragi.saga.jp":1,"l-o-g-i-n.de":1,"l.bg":1,"l.se":1,"la-spezia.it":1,"la.us":1,"laakesvuemie.no":1,"lab.ms":1,"labor.museum":1,"labour.museum":1,"lahppi.no":1,"lajolla.museum":1,"lakas.hu":1,"lanbib.se":1,"lancashire.museum":1,"land-4-sale.us":1,"landes.museum":1,"landing.myjino.ru":2,"langevag.no":1,"lans.museum":1,"lapy.pl":1,"laquila.it":1,"lardal.no":1,"larsson.museum":1,"larvik.no":1,"laspezia.it":1,"latina.it":1,"lavagis.no":1,"lavangen.no":1,"law.pro":1,"law.za":1,"laz.it":1,"lazio.it":1,"lc.it":1,"lcl.dev":2,"lcube-server.de":1,"le.it":1,"leadpages.co":1,"leangaviika.no":1,"leasing.aero":1,"lebesby.no":1,"lebork.pl":1,"lebtimnetz.de":1,"lecce.it":1,"lecco.it":1,"leczna.pl":1,"leg.br":1,"legnica.pl":1,"leikanger.no":1,"leirfjord.no":1,"leirvik.no":1,"leitungsen.de":1,"leka.no":1,"leksvik.no":1,"lel.br":1,"lelux.site":1,"lenug.su":1,"lenvik.no":1,"lerdal.no":1,"lesja.no":1,"levanger.no":1,"lewismiller.museum":1,"lezajsk.pl":1,"lg.jp":1,"lg.ua":1,"li.it":1,"lib.ak.us":1,"lib.al.us":1,"lib.ar.us":1,"lib.as.us":1,"lib.az.us":1,"lib.ca.us":1,"lib.co.us":1,"lib.ct.us":1,"lib.dc.us":1,"lib.de.us":1,"lib.ee":1,"lib.fl.us":1,"lib.ga.us":1,"lib.gu.us":1,"lib.hi.us":1,"lib.ia.us":1,"lib.id.us":1,"lib.il.us":1,"lib.in.us":1,"lib.ks.us":1,"lib.ky.us":1,"lib.la.us":1,"lib.ma.us":1,"lib.md.us":1,"lib.me.us":1,"lib.mi.us":1,"lib.mn.us":1,"lib.mo.us":1,"lib.ms.us":1,"lib.mt.us":1,"lib.nc.us":1,"lib.nd.us":1,"lib.ne.us":1,"lib.nh.us":1,"lib.nj.us":1,"lib.nm.us":1,"lib.nv.us":1,"lib.ny.us":1,"lib.oh.us":1,"lib.ok.us":1,"lib.or.us":1,"lib.pa.us":1,"lib.pr.us":1,"lib.ri.us":1,"lib.sc.us":1,"lib.sd.us":1,"lib.tn.us":1,"lib.tx.us":1,"lib.ut.us":1,"lib.va.us":1,"lib.vi.us":1,"lib.vt.us":1,"lib.wa.us":1,"lib.wi.us":1,"lib.wy.us":1,"lier.no":1,"lierne.no":1,"lig.it":1,"liguria.it":1,"likes-pie.com":1,"likescandy.com":1,"lillehammer.no":1,"lillesand.no":1,"lima-city.at":1,"lima-city.ch":1,"lima-city.de":1,"lima-city.rocks":1,"lima.zone":1,"limanowa.pl":1,"lincoln.museum":1,"lindas.no":1,"lindesnes.no":1,"linkitools.space":1,"linkyard-cloud.ch":1,"linkyard.cloud":1,"linodeobjects.com":2,"linz.museum":1,"living.museum":1,"livinghistory.museum":1,"livorno.it":1,"ln.cn":1,"lo.it":1,"loabat.no":1,"localhistory.museum":1,"localhost.daplie.me":1,"lodi.it":1,"lodingen.no":1,"log.br":1,"loginline.app":1,"loginline.dev":1,"loginline.io":1,"loginline.services":1,"loginline.site":1,"loginto.me":1,"logistics.aero":1,"logoip.com":1,"logoip.de":1,"lolipop.io":1,"lom.it":1,"lom.no":1,"lombardia.it":1,"lombardy.it":1,"lomza.pl":1,"london.cloudapps.digital":1,"london.museum":1,"londrina.br":1,"loppa.no":1,"lorenskog.no":1,"losangeles.museum":1,"loseyourip.com":1,"loten.no":1,"louvre.museum":1,"lowicz.pl":1,"loyalist.museum":1,"lpages.co":1,"lpusercontent.com":1,"lt.eu.org":1,"lt.it":1,"lt.ua":1,"ltd.co.im":1,"ltd.cy":1,"ltd.gi":1,"ltd.hk":1,"ltd.lk":1,"ltd.ng":1,"ltd.ua":1,"ltd.uk":1,"lu.eu.org":1,"lu.it":1,"lubartow.pl":1,"lubin.pl":1,"lublin.pl":1,"lucania.it":1,"lucca.it":1,"lucerne.museum":1,"lug.org.uk":1,"lugansk.ua":1,"lugs.org.uk":1,"lukow.pl":1,"lund.no":1,"lunner.no":1,"luroy.no":1,"luster.no":1,"lutsk.ua":1,"luxembourg.museum":1,"luzern.museum":1,"lv.eu.org":1,"lv.ua":1,"lviv.ua":1,"lyngdal.no":1,"lyngen.no":1,"lynx.mythic-beasts.com":1,"m.bg":1,"m.se":1,"ma.gov.br":1,"ma.leg.br":1,"ma.us":1,"macapa.br":1,"maceio.br":1,"macerata.it":1,"machida.tokyo.jp":1,"mad.museum":1,"madrid.museum":1,"maebashi.gunma.jp":1,"magazine.aero":1,"magentosite.cloud":2,"maibara.shiga.jp":1,"mail.pl":1,"maintenance.aero":1,"maizuru.kyoto.jp":1,"makinohara.shizuoka.jp":1,"makurazaki.kagoshima.jp":1,"malatvuopmi.no":1,"malbork.pl":1,"mallorca.museum":1,"malopolska.pl":1,"malselv.no":1,"malvik.no":1,"mamurogawa.yamagata.jp":1,"manaus.br":1,"manchester.museum":1,"mandal.no":1,"mangyshlak.su":1,"maniwa.okayama.jp":1,"manno.kagawa.jp":1,"mansion.museum":1,"mansions.museum":1,"mantova.it":1,"manx.museum":1,"maori.nz":1,"map.fastly.net":1,"map.fastlylb.net":1,"mar.it":1,"marburg.museum":1,"marche.it":1,"marine.ru":1,"maringa.br":1,"maritime.museum":1,"maritimo.museum":1,"marker.no":1,"marnardal.no":1,"marugame.kagawa.jp":1,"marumori.miyagi.jp":1,"maryland.museum":1,"marylhurst.museum":1,"masaki.ehime.jp":1,"masfjorden.no":1,"mashike.hokkaido.jp":1,"mashiki.kumamoto.jp":1,"mashiko.tochigi.jp":1,"masoy.no":1,"massa-carrara.it":1,"massacarrara.it":1,"masuda.shimane.jp":1,"mat.br":1,"matera.it":1,"matsubara.osaka.jp":1,"matsubushi.saitama.jp":1,"matsuda.kanagawa.jp":1,"matsudo.chiba.jp":1,"matsue.shimane.jp":1,"matsukawa.nagano.jp":1,"matsumae.hokkaido.jp":1,"matsumoto.kagoshima.jp":1,"matsumoto.nagano.jp":1,"matsuno.ehime.jp":1,"matsusaka.mie.jp":1,"matsushige.tokushima.jp":1,"matsushima.miyagi.jp":1,"matsuura.nagasaki.jp":1,"matsuyama.ehime.jp":1,"matsuzaki.shizuoka.jp":1,"matta-varjjat.no":1,"mayfirst.info":1,"mayfirst.org":1,"mazowsze.pl":1,"mazury.pl":1,"mb.ca":1,"mb.it":1,"mc.ax":1,"mc.eu.org":1,"mc.it":1,"mcdir.ru":1,"mcpe.me":1,"md.ci":1,"md.us":1,"me.eu.org":1,"me.it":1,"me.ke":1,"me.so":1,"me.tc":1,"me.tz":1,"me.uk":1,"me.us":1,"me.vu":1,"med.br":1,"med.ec":1,"med.ee":1,"med.ht":1,"med.ly":1,"med.om":1,"med.pa":1,"med.pl":1,"med.pro":1,"med.sa":1,"med.sd":1,"medecin.fr":1,"medecin.km":1,"media.aero":1,"media.hu":1,"media.museum":1,"media.pl":1,"medical.museum":1,"medicina.bo":1,"medio-campidano.it":1,"mediocampidano.it":1,"medizinhistorisches.museum":1,"meeres.museum":1,"meguro.tokyo.jp":1,"mein-iserv.de":1,"mein-vigor.de":1,"meinforum.net":1,"meiwa.gunma.jp":1,"meiwa.mie.jp":1,"meland.no":1,"meldal.no":1,"melhus.no":1,"meloy.no":1,"members.linode.com":1,"memorial.museum":1,"memset.net":1,"meraker.no":1,"merseine.nu":1,"mesaverde.museum":1,"messina.it":1,"meteorapp.com":1,"mex.com":1,"mg.gov.br":1,"mg.leg.br":1,"mi.it":1,"mi.th":1,"mi.us":1,"miasa.nagano.jp":1,"miasta.pl":1,"mibu.tochigi.jp":1,"michigan.museum":1,"microlight.aero":1,"midatlantic.museum":1,"midori.chiba.jp":1,"midori.gunma.jp":1,"midsund.no":1,"midtre-gauldal.no":1,"mie.jp":1,"mielec.pl":1,"mielno.pl":1,"mifune.kumamoto.jp":1,"mihama.aichi.jp":1,"mihama.chiba.jp":1,"mihama.fukui.jp":1,"mihama.mie.jp":1,"mihama.wakayama.jp":1,"mihara.hiroshima.jp":1,"mihara.kochi.jp":1,"miharu.fukushima.jp":1,"miho.ibaraki.jp":1,"mikasa.hokkaido.jp":1,"mikawa.yamagata.jp":1,"miki.hyogo.jp":1,"mil.ac":1,"mil.ae":1,"mil.al":1,"mil.ar":1,"mil.az":1,"mil.ba":1,"mil.bo":1,"mil.br":1,"mil.by":1,"mil.cl":1,"mil.cn":1,"mil.co":1,"mil.do":1,"mil.ec":1,"mil.eg":1,"mil.fj":1,"mil.ge":1,"mil.gh":1,"mil.gt":1,"mil.hn":1,"mil.id":1,"mil.in":1,"mil.iq":1,"mil.jo":1,"mil.kg":1,"mil.km":1,"mil.kr":1,"mil.kz":1,"mil.lv":1,"mil.mg":1,"mil.mv":1,"mil.my":1,"mil.mz":1,"mil.ng":1,"mil.ni":1,"mil.no":1,"mil.nz":1,"mil.pe":1,"mil.ph":1,"mil.pl":1,"mil.py":1,"mil.qa":1,"mil.ru":1,"mil.rw":1,"mil.sh":1,"mil.st":1,"mil.sy":1,"mil.tj":1,"mil.tm":1,"mil.to":1,"mil.tr":1,"mil.tw":1,"mil.tz":1,"mil.uy":1,"mil.vc":1,"mil.ve":1,"mil.za":1,"mil.zm":1,"mil.zw":1,"milan.it":1,"milano.it":1,"military.museum":1,"mill.museum":1,"mima.tokushima.jp":1,"mimata.miyazaki.jp":1,"minakami.gunma.jp":1,"minamata.kumamoto.jp":1,"minami-alps.yamanashi.jp":1,"minami.fukuoka.jp":1,"minami.kyoto.jp":1,"minami.tokushima.jp":1,"minamiaiki.nagano.jp":1,"minamiashigara.kanagawa.jp":1,"minamiawaji.hyogo.jp":1,"minamiboso.chiba.jp":1,"minamidaito.okinawa.jp":1,"minamiechizen.fukui.jp":1,"minamifurano.hokkaido.jp":1,"minamiise.mie.jp":1,"minamiizu.shizuoka.jp":1,"minamimaki.nagano.jp":1,"minamiminowa.nagano.jp":1,"minamioguni.kumamoto.jp":1,"minamisanriku.miyagi.jp":1,"minamitane.kagoshima.jp":1,"minamiuonuma.niigata.jp":1,"minamiyamashiro.kyoto.jp":1,"minano.saitama.jp":1,"minato.osaka.jp":1,"minato.tokyo.jp":1,"mincom.tn":1,"mine.nu":1,"miners.museum":1,"mining.museum":1,"miniserver.com":1,"minnesota.museum":1,"mino.gifu.jp":1,"minobu.yamanashi.jp":1,"minoh.osaka.jp":1,"minokamo.gifu.jp":1,"minowa.nagano.jp":1,"mintere.site":1,"mircloud.host":1,"misaki.okayama.jp":1,"misaki.osaka.jp":1,"misasa.tottori.jp":1,"misato.akita.jp":1,"misato.miyagi.jp":1,"misato.saitama.jp":1,"misato.shimane.jp":1,"misato.wakayama.jp":1,"misawa.aomori.jp":1,"misconfused.org":1,"mishima.fukushima.jp":1,"mishima.shizuoka.jp":1,"missile.museum":1,"missoula.museum":1,"misugi.mie.jp":1,"mitaka.tokyo.jp":1,"mitake.gifu.jp":1,"mitane.akita.jp":1,"mito.ibaraki.jp":1,"mitou.yamaguchi.jp":1,"mitoyo.kagawa.jp":1,"mitsue.nara.jp":1,"mitsuke.niigata.jp":1,"miura.kanagawa.jp":1,"miyada.nagano.jp":1,"miyagi.jp":1,"miyake.nara.jp":1,"miyako.fukuoka.jp":1,"miyako.iwate.jp":1,"miyakonojo.miyazaki.jp":1,"miyama.fukuoka.jp":1,"miyama.mie.jp":1,"miyashiro.saitama.jp":1,"miyawaka.fukuoka.jp":1,"miyazaki.jp":1,"miyazaki.miyazaki.jp":1,"miyazu.kyoto.jp":1,"miyoshi.aichi.jp":1,"miyoshi.hiroshima.jp":1,"miyoshi.saitama.jp":1,"miyoshi.tokushima.jp":1,"miyota.nagano.jp":1,"mizuho.tokyo.jp":1,"mizumaki.fukuoka.jp":1,"mizunami.gifu.jp":1,"mizusawa.iwate.jp":1,"mjondalen.no":1,"mk.eu.org":1,"mk.ua":1,"mlbfan.org":1,"mm":2,"mmafan.biz":1,"mn.it":1,"mn.us":1,"mo-i-rana.no":1,"mo-siemens.io":1,"mo.cn":1,"mo.it":1,"mo.us":1,"moareke.no":1,"mobara.chiba.jp":1,"mobi.gp":1,"mobi.ke":1,"mobi.na":1,"mobi.ng":1,"mobi.tt":1,"mobi.tz":1,"mochizuki.nagano.jp":1,"mod.gi":1,"modalen.no":1,"modelling.aero":1,"modena.it":1,"modern.museum":1,"modum.no":1,"moka.tochigi.jp":1,"mol.it":1,"molde.no":1,"molise.it":1,"moma.museum":1,"mombetsu.hokkaido.jp":1,"money.museum":1,"monmouth.museum":1,"monticello.museum":1,"montreal.museum":1,"monza-brianza.it":1,"monza-e-della-brianza.it":1,"monza.it":1,"monzabrianza.it":1,"monzaebrianza.it":1,"monzaedellabrianza.it":1,"moonscale.io":2,"moonscale.net":1,"mordovia.ru":1,"mordovia.su":1,"morena.br":1,"moriguchi.osaka.jp":1,"morimachi.shizuoka.jp":1,"morioka.iwate.jp":1,"moriya.ibaraki.jp":1,"moriyama.shiga.jp":1,"moriyoshi.akita.jp":1,"morotsuka.miyazaki.jp":1,"moroyama.saitama.jp":1,"moscow.museum":1,"moseushi.hokkaido.jp":1,"mosjoen.no":1,"moskenes.no":1,"moss.no":1,"mosvik.no":1,"motegi.tochigi.jp":1,"motobu.okinawa.jp":1,"motorcycle.museum":1,"motosu.gifu.jp":1,"motoyama.kochi.jp":1,"movimiento.bo":1,"mozilla-iot.org":1,"mp.br":1,"mr.no":1,"mragowo.pl":1,"ms.gov.br":1,"ms.it":1,"ms.kr":1,"ms.leg.br":1,"ms.us":1,"msk.ru":1,"msk.su":1,"mt.eu.org":1,"mt.gov.br":1,"mt.it":1,"mt.leg.br":1,"mt.us":1,"muenchen.museum":1,"muenster.museum":1,"mugi.tokushima.jp":1,"muika.niigata.jp":1,"mukawa.hokkaido.jp":1,"muko.kyoto.jp":1,"mulhouse.museum":1,"munakata.fukuoka.jp":1,"muncie.museum":1,"muni.il":1,"muosat.no":1,"mup.gov.pl":1,"murakami.niigata.jp":1,"murata.miyagi.jp":1,"murayama.yamagata.jp":1,"murmansk.su":1,"muroran.hokkaido.jp":1,"muroto.kochi.jp":1,"mus.br":1,"mus.mi.us":1,"musashimurayama.tokyo.jp":1,"musashino.tokyo.jp":1,"museet.museum":1,"museum.mv":1,"museum.mw":1,"museum.no":1,"museum.om":1,"museum.tt":1,"museumcenter.museum":1,"museumvereniging.museum":1,"music.museum":1,"musica.ar":1,"musica.bo":1,"mutsu.aomori.jp":1,"mutsuzawa.chiba.jp":1,"mw.gov.pl":1,"mx.na":1,"my-firewall.org":1,"my-gateway.de":1,"my-router.de":1,"my-vigor.de":1,"my-wan.de":1,"my.eu.org":1,"my.id":1,"myactivedirectory.com":1,"myasustor.com":1,"mycd.eu":1,"mydatto.com":1,"mydatto.net":1,"myddns.rocks":1,"mydissent.net":1,"mydobiss.com":1,"mydrobo.com":1,"myds.me":1,"myeffect.net":1,"myfast.host":1,"myfast.space":1,"myfirewall.org":1,"myforum.community":1,"myfritz.net":1,"myftp.biz":1,"myftp.org":1,"myhome-server.de":1,"myiphost.com":1,"myjino.ru":1,"mykolaiv.ua":1,"mymailer.com.tw":1,"mymediapc.net":1,"myoko.niigata.jp":1,"mypep.link":1,"mypets.ws":1,"myphotos.cc":1,"mypi.co":1,"mypsx.net":1,"myqnapcloud.com":1,"myravendb.com":1,"mysecuritycamera.com":1,"mysecuritycamera.net":1,"mysecuritycamera.org":1,"myshopblocks.com":1,"mytis.ru":1,"mytuleap.com":1,"myvnc.com":1,"mywire.org":1,"n.bg":1,"n.se":1,"n4t.co":1,"na.it":1,"na4u.ru":1,"naamesjevuemie.no":1,"nabari.mie.jp":1,"nachikatsuura.wakayama.jp":1,"nagahama.shiga.jp":1,"nagai.yamagata.jp":1,"nagano.jp":1,"nagano.nagano.jp":1,"naganohara.gunma.jp":1,"nagaoka.niigata.jp":1,"nagaokakyo.kyoto.jp":1,"nagara.chiba.jp":1,"nagareyama.chiba.jp":1,"nagasaki.jp":1,"nagasaki.nagasaki.jp":1,"nagasu.kumamoto.jp":1,"nagato.yamaguchi.jp":1,"nagatoro.saitama.jp":1,"nagawa.nagano.jp":1,"nagi.okayama.jp":1,"nagiso.nagano.jp":1,"nago.okinawa.jp":1,"nagoya.jp":2,"naha.okinawa.jp":1,"nahari.kochi.jp":1,"naie.hokkaido.jp":1,"naka.hiroshima.jp":1,"naka.ibaraki.jp":1,"nakadomari.aomori.jp":1,"nakagawa.fukuoka.jp":1,"nakagawa.hokkaido.jp":1,"nakagawa.nagano.jp":1,"nakagawa.tokushima.jp":1,"nakagusuku.okinawa.jp":1,"nakagyo.kyoto.jp":1,"nakai.kanagawa.jp":1,"nakama.fukuoka.jp":1,"nakamichi.yamanashi.jp":1,"nakamura.kochi.jp":1,"nakaniikawa.toyama.jp":1,"nakano.nagano.jp":1,"nakano.tokyo.jp":1,"nakanojo.gunma.jp":1,"nakanoto.ishikawa.jp":1,"nakasatsunai.hokkaido.jp":1,"nakatane.kagoshima.jp":1,"nakatombetsu.hokkaido.jp":1,"nakatsugawa.gifu.jp":1,"nakayama.yamagata.jp":1,"nakijin.okinawa.jp":1,"naklo.pl":1,"nalchik.ru":1,"nalchik.su":1,"namdalseid.no":1,"name.az":1,"name.cy":1,"name.eg":1,"name.et":1,"name.fj":1,"name.hr":1,"name.jo":1,"name.mk":1,"name.mv":1,"name.my":1,"name.na":1,"name.ng":1,"name.pr":1,"name.qa":1,"name.tj":1,"name.tr":1,"name.tt":1,"name.vn":1,"namegata.ibaraki.jp":1,"namegawa.saitama.jp":1,"namerikawa.toyama.jp":1,"namie.fukushima.jp":1,"namikata.ehime.jp":1,"namsos.no":1,"namsskogan.no":1,"nanae.hokkaido.jp":1,"nanao.ishikawa.jp":1,"nanbu.tottori.jp":1,"nanbu.yamanashi.jp":1,"nango.fukushima.jp":1,"nanjo.okinawa.jp":1,"nankoku.kochi.jp":1,"nanmoku.gunma.jp":1,"nannestad.no":1,"nanporo.hokkaido.jp":1,"nantan.kyoto.jp":1,"nanto.toyama.jp":1,"nanyo.yamagata.jp":1,"naoshima.kagawa.jp":1,"naples.it":1,"napoli.it":1,"nara.jp":1,"nara.nara.jp":1,"narashino.chiba.jp":1,"narita.chiba.jp":1,"naroy.no":1,"narusawa.yamanashi.jp":1,"naruto.tokushima.jp":1,"narviika.no":1,"narvik.no":1,"nasu.tochigi.jp":1,"nasushiobara.tochigi.jp":1,"nat.tn":1,"natal.br":1,"national.museum":1,"nationalfirearms.museum":1,"nationalheritage.museum":1,"nativeamerican.museum":1,"natori.miyagi.jp":1,"natural.bo":1,"naturalhistory.museum":1,"naturalhistorymuseum.museum":1,"naturalsciences.museum":1,"naturbruksgymn.se":1,"nature.museum":1,"naturhistorisches.museum":1,"natuurwetenschappen.museum":1,"naumburg.museum":1,"naustdal.no":1,"naval.museum":1,"navigation.aero":1,"navoi.su":1,"navuotna.no":1,"nayoro.hokkaido.jp":1,"nb.ca":1,"nc.tr":1,"nc.us":1,"nctu.me":1,"nd.us":1,"ne.jp":1,"ne.ke":1,"ne.kr":1,"ne.pw":1,"ne.tz":1,"ne.ug":1,"ne.us":1,"neat-url.com":1,"nebraska.museum":1,"nedre-eiker.no":1,"neko.am":1,"nemuro.hokkaido.jp":1,"nerdpol.ovh":1,"nerima.tokyo.jp":1,"nes.akershus.no":1,"nes.buskerud.no":1,"nesna.no":1,"nesodden.no":1,"nesoddtangen.no":1,"nesseby.no":1,"nesset.no":1,"net-freaks.com":1,"net.ac":1,"net.ae":1,"net.af":1,"net.ag":1,"net.ai":1,"net.al":1,"net.am":1,"net.ar":1,"net.au":1,"net.az":1,"net.ba":1,"net.bb":1,"net.bh":1,"net.bm":1,"net.bn":1,"net.bo":1,"net.br":1,"net.bs":1,"net.bt":1,"net.bz":1,"net.ci":1,"net.cm":1,"net.cn":1,"net.co":1,"net.cu":1,"net.cw":1,"net.cy":1,"net.dm":1,"net.do":1,"net.dz":1,"net.ec":1,"net.eg":1,"net.et":1,"net.eu.org":1,"net.fj":1,"net.fm":1,"net.ge":1,"net.gg":1,"net.gl":1,"net.gn":1,"net.gp":1,"net.gr":1,"net.gt":1,"net.gu":1,"net.gy":1,"net.hk":1,"net.hn":1,"net.ht":1,"net.id":1,"net.il":1,"net.im":1,"net.in":1,"net.iq":1,"net.ir":1,"net.is":1,"net.je":1,"net.jo":1,"net.kg":1,"net.ki":1,"net.kn":1,"net.kw":1,"net.ky":1,"net.kz":1,"net.la":1,"net.lb":1,"net.lc":1,"net.lk":1,"net.lr":1,"net.ls":1,"net.lv":1,"net.ly":1,"net.ma":1,"net.me":1,"net.mk":1,"net.ml":1,"net.mo":1,"net.ms":1,"net.mt":1,"net.mu":1,"net.mv":1,"net.mw":1,"net.mx":1,"net.my":1,"net.mz":1,"net.nf":1,"net.ng":1,"net.ni":1,"net.nr":1,"net.nz":1,"net.om":1,"net.pa":1,"net.pe":1,"net.ph":1,"net.pk":1,"net.pl":1,"net.pn":1,"net.pr":1,"net.ps":1,"net.pt":1,"net.py":1,"net.qa":1,"net.ru":1,"net.rw":1,"net.sa":1,"net.sb":1,"net.sc":1,"net.sd":1,"net.sg":1,"net.sh":1,"net.sl":1,"net.so":1,"net.ss":1,"net.st":1,"net.sy":1,"net.th":1,"net.tj":1,"net.tm":1,"net.tn":1,"net.to":1,"net.tr":1,"net.tt":1,"net.tw":1,"net.ua":1,"net.uk":1,"net.uy":1,"net.uz":1,"net.vc":1,"net.ve":1,"net.vi":1,"net.vn":1,"net.vu":1,"net.ws":1,"net.za":1,"net.zm":1,"netlify.app":1,"neues.museum":1,"newhampshire.museum":1,"newjersey.museum":1,"newmexico.museum":1,"newport.museum":1,"news.hu":1,"newspaper.museum":1,"newyork.museum":1,"neyagawa.osaka.jp":1,"nf.ca":1,"nflfan.org":1,"nfshost.com":1,"ng.city":1,"ng.eu.org":1,"ng.ink":1,"ng.school":1,"ngo.lk":1,"ngo.ng":1,"ngo.ph":1,"ngo.za":1,"ngrok.io":1,"nh-serv.co.uk":1,"nh.us":1,"nhlfan.net":1,"nhs.uk":1,"nic.in":1,"nic.tj":1,"nic.za":1,"nichinan.miyazaki.jp":1,"nichinan.tottori.jp":1,"nid.io":1,"niepce.museum":1,"nieruchomosci.pl":1,"niigata.jp":1,"niigata.niigata.jp":1,"niihama.ehime.jp":1,"niikappu.hokkaido.jp":1,"niimi.okayama.jp":1,"niiza.saitama.jp":1,"nikaho.akita.jp":1,"niki.hokkaido.jp":1,"nikko.tochigi.jp":1,"nikolaev.ua":1,"ninohe.iwate.jp":1,"ninomiya.kanagawa.jp":1,"nirasaki.yamanashi.jp":1,"nis.za":1,"nishi.fukuoka.jp":1,"nishi.osaka.jp":1,"nishiaizu.fukushima.jp":1,"nishiarita.saga.jp":1,"nishiawakura.okayama.jp":1,"nishiazai.shiga.jp":1,"nishigo.fukushima.jp":1,"nishihara.kumamoto.jp":1,"nishihara.okinawa.jp":1,"nishiizu.shizuoka.jp":1,"nishikata.tochigi.jp":1,"nishikatsura.yamanashi.jp":1,"nishikawa.yamagata.jp":1,"nishimera.miyazaki.jp":1,"nishinomiya.hyogo.jp":1,"nishinoomote.kagoshima.jp":1,"nishinoshima.shimane.jp":1,"nishio.aichi.jp":1,"nishiokoppe.hokkaido.jp":1,"nishitosa.kochi.jp":1,"nishiwaki.hyogo.jp":1,"nissedal.no":1,"nisshin.aichi.jp":1,"niteroi.br":1,"nittedal.no":1,"niyodogawa.kochi.jp":1,"nj.us":1,"nl.ca":1,"nl.ci":1,"nl.eu.org":1,"nl.no":1,"nm.cn":1,"nm.us":1,"no-ip.biz":1,"no-ip.ca":1,"no-ip.co.uk":1,"no-ip.info":1,"no-ip.net":1,"no-ip.org":1,"no.com":1,"no.eu.org":1,"no.it":1,"nobeoka.miyazaki.jp":1,"noboribetsu.hokkaido.jp":1,"noda.chiba.jp":1,"noda.iwate.jp":1,"nodebalancer.linode.com":2,"nodum.co":1,"nodum.io":1,"nogata.fukuoka.jp":1,"nogi.tochigi.jp":1,"noheji.aomori.jp":1,"noho.st":1,"nohost.me":1,"noip.me":1,"noip.us":1,"nom.ad":1,"nom.ae":1,"nom.af":1,"nom.ag":1,"nom.ai":1,"nom.al":1,"nom.br":2,"nom.bz":1,"nom.cl":1,"nom.co":1,"nom.es":1,"nom.fr":1,"nom.gd":1,"nom.ge":1,"nom.gl":1,"nom.gt":1,"nom.hn":1,"nom.im":1,"nom.ke":1,"nom.km":1,"nom.li":1,"nom.lv":1,"nom.mg":1,"nom.mk":1,"nom.nc":1,"nom.ni":1,"nom.nu":1,"nom.pa":1,"nom.pe":1,"nom.pl":1,"nom.pw":1,"nom.qa":1,"nom.re":1,"nom.ro":1,"nom.rs":1,"nom.si":1,"nom.st":1,"nom.tj":1,"nom.tm":1,"nom.ug":1,"nom.uy":1,"nom.vc":1,"nom.vg":1,"nom.za":1,"nombre.bo":1,"nome.pt":1,"nomi.ishikawa.jp":1,"nonoichi.ishikawa.jp":1,"nord-aurdal.no":1,"nord-fron.no":1,"nord-odal.no":1,"norddal.no":1,"nordkapp.no":1,"nordre-land.no":1,"nordreisa.no":1,"nore-og-uvdal.no":1,"norfolk.museum":1,"north-kazakhstan.su":1,"north.museum":1,"nose.osaka.jp":1,"nosegawa.nara.jp":1,"noshiro.akita.jp":1,"not.br":1,"notaires.fr":1,"notaires.km":1,"noticias.bo":1,"noto.ishikawa.jp":1,"notodden.no":1,"notogawa.shiga.jp":1,"notteroy.no":1,"nov.ru":1,"nov.su":1,"novara.it":1,"now-dns.net":1,"now-dns.org":1,"now-dns.top":1,"now.sh":1,"nowaruda.pl":1,"nozawaonsen.nagano.jp":1,"np":2,"nrw.museum":1,"ns.ca":1,"nsn.us":1,"nsupdate.info":1,"nsw.au":1,"nsw.edu.au":1,"nt.au":1,"nt.ca":1,"nt.edu.au":1,"nt.no":1,"nt.ro":1,"ntdll.top":1,"ntr.br":1,"nu.ca":1,"nu.it":1,"numata.gunma.jp":1,"numata.hokkaido.jp":1,"numazu.shizuoka.jp":1,"nuoro.it":1,"nv.us":1,"nx.cn":1,"ny.us":1,"nyaa.am":1,"nyan.to":1,"nyc.mn":1,"nyc.museum":1,"nym.by":1,"nym.bz":1,"nym.ec":1,"nym.gr":1,"nym.gy":1,"nym.hk":1,"nym.ie":1,"nym.kz":1,"nym.la":1,"nym.lc":1,"nym.li":1,"nym.lt":1,"nym.lu":1,"nym.me":1,"nym.mn":1,"nym.mx":1,"nym.nz":1,"nym.pe":1,"nym.pt":1,"nym.ro":1,"nym.sk":1,"nym.su":1,"nym.sx":1,"nym.tw":1,"nyny.museum":1,"nysa.pl":1,"nyuzen.toyama.jp":1,"nz.basketball":1,"nz.eu.org":1,"o.bg":1,"o.se":1,"oamishirasato.chiba.jp":1,"oarai.ibaraki.jp":1,"obama.fukui.jp":1,"obama.nagasaki.jp":1,"obanazawa.yamagata.jp":1,"obihiro.hokkaido.jp":1,"obira.hokkaido.jp":1,"obninsk.su":1,"obu.aichi.jp":1,"obuse.nagano.jp":1,"oceanographic.museum":1,"oceanographique.museum":1,"ocelot.mythic-beasts.com":1,"ochi.kochi.jp":1,"oci.customer-oci.com":2,"ocp.customer-oci.com":2,"ocs.customer-oci.com":2,"od.ua":1,"odate.akita.jp":1,"odawara.kanagawa.jp":1,"odda.no":1,"odesa.ua":1,"odessa.ua":1,"odo.br":1,"oe.yamagata.jp":1,"of.by":1,"of.fashion":1,"of.football":1,"of.london":1,"of.no":1,"of.work":1,"off.ai":1,"office-on-the.net":1,"official.academy":1,"ofunato.iwate.jp":1,"og.ao":1,"og.it":1,"oga.akita.jp":1,"ogaki.gifu.jp":1,"ogano.saitama.jp":1,"ogasawara.tokyo.jp":1,"ogata.akita.jp":1,"ogawa.ibaraki.jp":1,"ogawa.nagano.jp":1,"ogawa.saitama.jp":1,"ogawara.miyagi.jp":1,"ogi.saga.jp":1,"ogimi.okinawa.jp":1,"ogliastra.it":1,"ogori.fukuoka.jp":1,"ogose.saitama.jp":1,"oguchi.aichi.jp":1,"oguni.kumamoto.jp":1,"oguni.yamagata.jp":1,"oh.us":1,"oharu.aichi.jp":1,"ohda.shimane.jp":1,"ohi.fukui.jp":1,"ohira.miyagi.jp":1,"ohira.tochigi.jp":1,"ohkura.yamagata.jp":1,"ohtawara.tochigi.jp":1,"oi.kanagawa.jp":1,"oirase.aomori.jp":1,"oirm.gov.pl":1,"oishida.yamagata.jp":1,"oiso.kanagawa.jp":1,"oita.jp":1,"oita.oita.jp":1,"oizumi.gunma.jp":1,"oji.nara.jp":1,"ojiya.niigata.jp":1,"ok.us":1,"okagaki.fukuoka.jp":1,"okawa.fukuoka.jp":1,"okawa.kochi.jp":1,"okaya.nagano.jp":1,"okayama.jp":1,"okayama.okayama.jp":1,"okazaki.aichi.jp":1,"okegawa.saitama.jp":1,"oketo.hokkaido.jp":1,"oki.fukuoka.jp":1,"okinawa.jp":1,"okinawa.okinawa.jp":1,"okinoshima.shimane.jp":1,"okoppe.hokkaido.jp":1,"oksnes.no":1,"okuizumo.shimane.jp":1,"okuma.fukushima.jp":1,"okutama.tokyo.jp":1,"ol.no":1,"olawa.pl":1,"olbia-tempio.it":1,"olbiatempio.it":1,"olecko.pl":1,"olkusz.pl":1,"olsztyn.pl":1,"omachi.nagano.jp":1,"omachi.saga.jp":1,"omaezaki.shizuoka.jp":1,"omaha.museum":1,"omasvuotna.no":1,"ome.tokyo.jp":1,"omg.lol":1,"omi.nagano.jp":1,"omi.niigata.jp":1,"omigawa.chiba.jp":1,"omihachiman.shiga.jp":1,"omitama.ibaraki.jp":1,"omiya.saitama.jp":1,"omniwe.site":1,"omotego.fukushima.jp":1,"omura.nagasaki.jp":1,"omuta.fukuoka.jp":1,"on-aptible.com":1,"on-k3s.io":2,"on-rancher.cloud":2,"on-rio.io":2,"on-the-web.tv":1,"on-web.fr":1,"on.ca":1,"on.fashion":1,"onagawa.miyagi.jp":1,"onfabrica.com":1,"ong.br":1,"onga.fukuoka.jp":1,"onjuku.chiba.jp":1,"online.museum":1,"online.th":1,"onna.okinawa.jp":1,"ono.fukui.jp":1,"ono.fukushima.jp":1,"ono.hyogo.jp":1,"onojo.fukuoka.jp":1,"onomichi.hiroshima.jp":1,"onred.one":1,"onrender.com":1,"ontario.museum":1,"onthewifi.com":1,"onza.mythic-beasts.com":1,"ooguy.com":1,"ookuwa.nagano.jp":1,"ooshika.nagano.jp":1,"openair.museum":1,"opencraft.hosting":1,"opensocial.site":1,"operaunite.com":1,"opoczno.pl":1,"opole.pl":1,"oppdal.no":1,"oppegard.no":1,"or.at":1,"or.bi":1,"or.ci":1,"or.cr":1,"or.id":1,"or.it":1,"or.jp":1,"or.ke":1,"or.kr":1,"or.mu":1,"or.na":1,"or.pw":1,"or.th":1,"or.tz":1,"or.ug":1,"or.us":1,"ora.gunma.jp":1,"oregon.museum":1,"oregontrail.museum":1,"org.ac":1,"org.ae":1,"org.af":1,"org.ag":1,"org.ai":1,"org.al":1,"org.am":1,"org.ar":1,"org.au":1,"org.az":1,"org.ba":1,"org.bb":1,"org.bh":1,"org.bi":1,"org.bm":1,"org.bn":1,"org.bo":1,"org.br":1,"org.bs":1,"org.bt":1,"org.bw":1,"org.bz":1,"org.ci":1,"org.cn":1,"org.co":1,"org.cu":1,"org.cw":1,"org.cy":1,"org.dm":1,"org.do":1,"org.dz":1,"org.ec":1,"org.ee":1,"org.eg":1,"org.es":1,"org.et":1,"org.fj":1,"org.fm":1,"org.ge":1,"org.gg":1,"org.gh":1,"org.gi":1,"org.gl":1,"org.gn":1,"org.gp":1,"org.gr":1,"org.gt":1,"org.gu":1,"org.gy":1,"org.hk":1,"org.hn":1,"org.ht":1,"org.hu":1,"org.il":1,"org.im":1,"org.in":1,"org.iq":1,"org.ir":1,"org.is":1,"org.je":1,"org.jo":1,"org.kg":1,"org.ki":1,"org.km":1,"org.kn":1,"org.kp":1,"org.kw":1,"org.ky":1,"org.kz":1,"org.la":1,"org.lb":1,"org.lc":1,"org.lk":1,"org.lr":1,"org.ls":1,"org.lv":1,"org.ly":1,"org.ma":1,"org.me":1,"org.mg":1,"org.mk":1,"org.ml":1,"org.mn":1,"org.mo":1,"org.ms":1,"org.mt":1,"org.mu":1,"org.mv":1,"org.mw":1,"org.mx":1,"org.my":1,"org.mz":1,"org.na":1,"org.ng":1,"org.ni":1,"org.nr":1,"org.nz":1,"org.om":1,"org.pa":1,"org.pe":1,"org.pf":1,"org.ph":1,"org.pk":1,"org.pl":1,"org.pn":1,"org.pr":1,"org.ps":1,"org.pt":1,"org.py":1,"org.qa":1,"org.ro":1,"org.rs":1,"org.ru":1,"org.rw":1,"org.sa":1,"org.sb":1,"org.sc":1,"org.sd":1,"org.se":1,"org.sg":1,"org.sh":1,"org.sl":1,"org.sn":1,"org.so":1,"org.ss":1,"org.st":1,"org.sv":1,"org.sy":1,"org.sz":1,"org.tj":1,"org.tm":1,"org.tn":1,"org.to":1,"org.tr":1,"org.tt":1,"org.tw":1,"org.ua":1,"org.ug":1,"org.uk":1,"org.uy":1,"org.uz":1,"org.vc":1,"org.ve":1,"org.vi":1,"org.vn":1,"org.vu":1,"org.ws":1,"org.za":1,"org.zm":1,"org.zw":1,"oristano.it":1,"orkanger.no":1,"orkdal.no":1,"orland.no":1,"orskog.no":1,"orsta.no":1,"orx.biz":1,"os.hedmark.no":1,"os.hordaland.no":1,"osaka.jp":1,"osakasayama.osaka.jp":1,"osaki.miyagi.jp":1,"osakikamijima.hiroshima.jp":1,"osasco.br":1,"osen.no":1,"oseto.nagasaki.jp":1,"oshima.tokyo.jp":1,"oshima.yamaguchi.jp":1,"oshino.yamanashi.jp":1,"oshu.iwate.jp":1,"oslo.no":1,"osoyro.no":1,"osteroy.no":1,"ostre-toten.no":1,"ostroda.pl":1,"ostroleka.pl":1,"ostrowiec.pl":1,"ostrowwlkp.pl":1,"ot.it":1,"ota.gunma.jp":1,"ota.tokyo.jp":1,"otago.museum":1,"otake.hiroshima.jp":1,"otaki.chiba.jp":1,"otaki.nagano.jp":1,"otaki.saitama.jp":1,"otama.fukushima.jp":1,"otap.co":2,"otari.nagano.jp":1,"otaru.hokkaido.jp":1,"other.nf":1,"oto.fukuoka.jp":1,"otobe.hokkaido.jp":1,"otofuke.hokkaido.jp":1,"otoineppu.hokkaido.jp":1,"otoyo.kochi.jp":1,"otsu.shiga.jp":1,"otsuchi.iwate.jp":1,"otsuki.kochi.jp":1,"otsuki.yamanashi.jp":1,"ouchi.saga.jp":1,"ouda.nara.jp":1,"oum.gov.pl":1,"oumu.hokkaido.jp":1,"outsystemscloud.com":1,"overhalla.no":1,"ovre-eiker.no":1,"owani.aomori.jp":1,"owariasahi.aichi.jp":1,"own.pm":1,"ownip.net":1,"ownprovider.com":1,"owo.codes":2,"ox.rs":1,"oxford.museum":1,"oy.lc":1,"oya.to":1,"oyabe.toyama.jp":1,"oyama.tochigi.jp":1,"oyamazaki.kyoto.jp":1,"oyer.no":1,"oygarden.no":1,"oyodo.nara.jp":1,"oystre-slidre.no":1,"oz.au":1,"ozora.hokkaido.jp":1,"ozu.ehime.jp":1,"ozu.kumamoto.jp":1,"p.bg":1,"p.se":1,"pa.gov.br":1,"pa.gov.pl":1,"pa.it":1,"pa.leg.br":1,"pa.us":1,"paas.datacenter.fi":1,"paas.massivegrid.com":1,"pacific.museum":1,"paderborn.museum":1,"padova.it":1,"padua.it":1,"pagefrontapp.com":1,"pages.dev":1,"pages.wiardweb.com":1,"pagespeedmobilizer.com":1,"pagexl.com":1,"palace.museum":1,"paleo.museum":1,"palermo.it":1,"palmas.br":1,"palmsprings.museum":1,"panama.museum":1,"panel.gg":1,"pantheonsite.io":1,"parachuting.aero":1,"paragliding.aero":1,"paris.eu.org":1,"paris.museum":1,"parliament.cy":1,"parliament.nz":1,"parma.it":1,"paroch.k12.ma.us":1,"parti.se":1,"pasadena.museum":1,"passenger-association.aero":1,"patria.bo":1,"pavia.it":1,"pb.ao":1,"pb.gov.br":1,"pb.leg.br":1,"pc.it":1,"pc.pl":1,"pcloud.host":1,"pd.it":1,"pdns.page":1,"pe.ca":1,"pe.gov.br":1,"pe.it":1,"pe.kr":1,"pe.leg.br":1,"penza.su":1,"per.la":1,"per.nf":1,"per.sg":1,"perso.ht":1,"perso.sn":1,"perso.tn":1,"perspecta.cloud":1,"perugia.it":1,"pesaro-urbino.it":1,"pesarourbino.it":1,"pescara.it":1,"pg":2,"pg.it":1,"pgafan.net":1,"pgfog.com":1,"pharmacien.fr":1,"pharmaciens.km":1,"pharmacy.museum":1,"philadelphia.museum":1,"philadelphiaarea.museum":1,"philately.museum":1,"phoenix.museum":1,"photography.museum":1,"pi.gov.br":1,"pi.it":1,"pi.leg.br":1,"piacenza.it":1,"piedmont.it":1,"piemonte.it":1,"pila.pl":1,"pilot.aero":1,"pilots.museum":1,"pimienta.org":1,"pinb.gov.pl":1,"pippu.hokkaido.jp":1,"pisa.it":1,"pistoia.it":1,"pisz.pl":1,"pittsburgh.museum":1,"piw.gov.pl":1,"pixolino.com":1,"pl.eu.org":1,"pl.ua":1,"planetarium.museum":1,"plantation.museum":1,"plants.museum":1,"platform0.app":1,"platformsh.site":2,"platter-app.com":1,"platter-app.dev":1,"platterp.us":1,"playstation-cloud.com":1,"plaza.museum":1,"plc.co.im":1,"plc.ly":1,"plc.uk":1,"plesk.page":1,"pleskns.com":1,"plo.ps":1,"plurinacional.bo":1,"pmn.it":1,"pn.it":1,"po.gov.pl":1,"po.it":1,"poa.br":1,"podhale.pl":1,"podlasie.pl":1,"podzone.net":1,"podzone.org":1,"point2this.com":1,"pointto.us":1,"poivron.org":1,"pokrovsk.su":1,"pol.dz":1,"pol.ht":1,"pol.tr":1,"police.uk":1,"politica.bo":1,"polkowice.pl":1,"poltava.ua":1,"pomorskie.pl":1,"pomorze.pl":1,"poniatowa.pl":1,"ponpes.id":1,"pony.club":1,"pordenone.it":1,"porsanger.no":1,"porsangu.no":1,"porsgrunn.no":1,"port.fr":1,"portal.museum":1,"portland.museum":1,"portlligat.museum":1,"posts-and-telecommunications.museum":1,"potager.org":1,"potenza.it":1,"powiat.pl":1,"poznan.pl":1,"pp.az":1,"pp.ru":1,"pp.se":1,"pp.ua":1,"ppg.br":1,"pr.gov.br":1,"pr.it":1,"pr.leg.br":1,"pr.us":1,"prato.it":1,"prd.fr":1,"prd.km":1,"prd.mg":1,"preservation.museum":1,"presidio.museum":1,"press.aero":1,"press.cy":1,"press.ma":1,"press.museum":1,"press.se":1,"presse.ci":1,"presse.km":1,"presse.ml":1,"pri.ee":1,"principe.st":1,"priv.at":1,"priv.hu":1,"priv.me":1,"priv.no":1,"priv.pl":1,"privatizehealthinsurance.net":1,"pro.az":1,"pro.br":1,"pro.cy":1,"pro.ec":1,"pro.fj":1,"pro.ht":1,"pro.mv":1,"pro.na":1,"pro.om":1,"pro.pr":1,"pro.tt":1,"pro.vn":1,"prochowice.pl":1,"production.aero":1,"prof.pr":1,"profesional.bo":1,"project.museum":1,"protonet.io":1,"pruszkow.pl":1,"prvcy.page":1,"przeworsk.pl":1,"psc.br":1,"psi.br":1,"psp.gov.pl":1,"psse.gov.pl":1,"pt.eu.org":1,"pt.it":1,"ptplus.fit":1,"pu.it":1,"pub.sa":1,"publ.pt":1,"public.museum":1,"publishproxy.com":1,"pubol.museum":1,"pubtls.org":1,"pueblo.bo":1,"pug.it":1,"puglia.it":1,"pulawy.pl":1,"pup.gov.pl":1,"pv.it":1,"pvh.br":1,"pvt.ge":1,"pvt.k12.ma.us":1,"pyatigorsk.ru":1,"pymnt.uk":1,"pz.it":1,"q-a.eu.org":1,"q.bg":1,"qa2.com":1,"qbuser.com":1,"qc.ca":1,"qc.com":1,"qcx.io":1,"qh.cn":1,"qld.au":1,"qld.edu.au":1,"qld.gov.au":1,"qsl.br":1,"qualifioapp.com":1,"quebec.museum":1,"quicksytes.com":1,"quipelements.com":2,"r.appspot.com":2,"r.bg":1,"r.cdn77.net":1,"r.se":1,"ra.it":1,"rackmaze.com":1,"rackmaze.net":1,"rade.no":1,"radio.am":1,"radio.br":1,"radio.fm":1,"radom.pl":1,"radoy.no":1,"ragusa.it":1,"rahkkeravju.no":1,"raholt.no":1,"railroad.museum":1,"railway.museum":1,"raisa.no":1,"rakkestad.no":1,"ralingen.no":1,"rana.no":1,"randaberg.no":1,"rankoshi.hokkaido.jp":1,"ranzan.saitama.jp":1,"ras.ru":1,"rauma.no":1,"ravendb.community":1,"ravendb.me":1,"ravendb.run":1,"ravenna.it":1,"rawa-maz.pl":1,"rc.it":1,"rdv.to":1,"re.it":1,"re.kr":1,"read-books.org":1,"readmyblog.org":1,"readthedocs.io":1,"realestate.pl":1,"realm.cz":1,"rebun.hokkaido.jp":1,"rec.br":1,"rec.co":1,"rec.nf":1,"rec.ro":1,"rec.ve":1,"recht.pro":1,"recife.br":1,"recreation.aero":1,"red.sv":1,"redirectme.net":1,"reg.dk":1,"reggio-calabria.it":1,"reggio-emilia.it":1,"reggiocalabria.it":1,"reggioemilia.it":1,"reklam.hu":1,"rel.ht":1,"rel.pl":1,"remotewd.com":1,"rendalen.no":1,"rennebu.no":1,"rennesoy.no":1,"rep.br":1,"rep.kp":1,"repbody.aero":1,"repl.co":1,"repl.run":1,"res.aero":1,"res.in":1,"research.aero":1,"research.museum":1,"resindevice.io":1,"resistance.museum":1,"revista.bo":1,"rg.it":1,"rhcloud.com":1,"ri.it":1,"ri.us":1,"ribeirao.br":1,"rieti.it":1,"rifu.miyagi.jp":1,"riik.ee":1,"rikubetsu.hokkaido.jp":1,"rikuzentakata.iwate.jp":1,"rimini.it":1,"rindal.no":1,"ringebu.no":1,"ringerike.no":1,"ringsaker.no":1,"rio.br":1,"riobranco.br":1,"riodejaneiro.museum":1,"riopreto.br":1,"rishiri.hokkaido.jp":1,"rishirifuji.hokkaido.jp":1,"risor.no":1,"rissa.no":1,"ritto.shiga.jp":1,"rivne.ua":1,"rj.gov.br":1,"rj.leg.br":1,"rl.no":1,"rm.it":1,"rn.gov.br":1,"rn.it":1,"rn.leg.br":1,"rnrt.tn":1,"rns.tn":1,"rnu.tn":1,"ro.eu.org":1,"ro.gov.br":1,"ro.im":1,"ro.it":1,"ro.leg.br":1,"roan.no":1,"rochester.museum":1,"rockart.museum":1,"rodoy.no":1,"rokunohe.aomori.jp":1,"rollag.no":1,"roma.it":1,"roma.museum":1,"rome.it":1,"romsa.no":1,"romskog.no":1,"roros.no":1,"rost.no":1,"rotorcraft.aero":1,"router.management":1,"rovigo.it":1,"rovno.ua":1,"royken.no":1,"royrvik.no":1,"rr.gov.br":1,"rr.leg.br":1,"rs.gov.br":1,"rs.leg.br":1,"rsc.cdn77.org":1,"ru.com":1,"ru.eu.org":1,"ru.net":1,"run.app":1,"ruovat.no":1,"russia.museum":1,"rv.ua":1,"rybnik.pl":1,"rygge.no":1,"ryokami.saitama.jp":1,"ryugasaki.ibaraki.jp":1,"ryuoh.shiga.jp":1,"rzeszow.pl":1,"rzgw.gov.pl":1,"s.bg":1,"s.se":1,"s3-ap-northeast-1.amazonaws.com":1,"s3-ap-northeast-2.amazonaws.com":1,"s3-ap-south-1.amazonaws.com":1,"s3-ap-southeast-1.amazonaws.com":1,"s3-ap-southeast-2.amazonaws.com":1,"s3-ca-central-1.amazonaws.com":1,"s3-eu-central-1.amazonaws.com":1,"s3-eu-west-1.amazonaws.com":1,"s3-eu-west-2.amazonaws.com":1,"s3-eu-west-3.amazonaws.com":1,"s3-external-1.amazonaws.com":1,"s3-fips-us-gov-west-1.amazonaws.com":1,"s3-sa-east-1.amazonaws.com":1,"s3-us-east-2.amazonaws.com":1,"s3-us-gov-west-1.amazonaws.com":1,"s3-us-west-1.amazonaws.com":1,"s3-us-west-2.amazonaws.com":1,"s3-website-ap-northeast-1.amazonaws.com":1,"s3-website-ap-southeast-1.amazonaws.com":1,"s3-website-ap-southeast-2.amazonaws.com":1,"s3-website-eu-west-1.amazonaws.com":1,"s3-website-sa-east-1.amazonaws.com":1,"s3-website-us-east-1.amazonaws.com":1,"s3-website-us-west-1.amazonaws.com":1,"s3-website-us-west-2.amazonaws.com":1,"s3-website.ap-northeast-2.amazonaws.com":1,"s3-website.ap-south-1.amazonaws.com":1,"s3-website.ca-central-1.amazonaws.com":1,"s3-website.eu-central-1.amazonaws.com":1,"s3-website.eu-west-2.amazonaws.com":1,"s3-website.eu-west-3.amazonaws.com":1,"s3-website.us-east-2.amazonaws.com":1,"s3.amazonaws.com":1,"s3.ap-northeast-2.amazonaws.com":1,"s3.ap-south-1.amazonaws.com":1,"s3.ca-central-1.amazonaws.com":1,"s3.cn-north-1.amazonaws.com.cn":1,"s3.dualstack.ap-northeast-1.amazonaws.com":1,"s3.dualstack.ap-northeast-2.amazonaws.com":1,"s3.dualstack.ap-south-1.amazonaws.com":1,"s3.dualstack.ap-southeast-1.amazonaws.com":1,"s3.dualstack.ap-southeast-2.amazonaws.com":1,"s3.dualstack.ca-central-1.amazonaws.com":1,"s3.dualstack.eu-central-1.amazonaws.com":1,"s3.dualstack.eu-west-1.amazonaws.com":1,"s3.dualstack.eu-west-2.amazonaws.com":1,"s3.dualstack.eu-west-3.amazonaws.com":1,"s3.dualstack.sa-east-1.amazonaws.com":1,"s3.dualstack.us-east-1.amazonaws.com":1,"s3.dualstack.us-east-2.amazonaws.com":1,"s3.eu-central-1.amazonaws.com":1,"s3.eu-west-2.amazonaws.com":1,"s3.eu-west-3.amazonaws.com":1,"s3.us-east-2.amazonaws.com":1,"s5y.io":2,"sa-east-1.elasticbeanstalk.com":1,"sa.au":1,"sa.com":1,"sa.cr":1,"sa.edu.au":1,"sa.gov.au":1,"sa.gov.pl":1,"sa.it":1,"sabae.fukui.jp":1,"sado.niigata.jp":1,"safety.aero":1,"saga.jp":1,"saga.saga.jp":1,"sagae.yamagata.jp":1,"sagamihara.kanagawa.jp":1,"saigawa.fukuoka.jp":1,"saijo.ehime.jp":1,"saikai.nagasaki.jp":1,"saiki.oita.jp":1,"saintlouis.museum":1,"saitama.jp":1,"saitama.saitama.jp":1,"saito.miyazaki.jp":1,"saka.hiroshima.jp":1,"sakado.saitama.jp":1,"sakae.chiba.jp":1,"sakae.nagano.jp":1,"sakahogi.gifu.jp":1,"sakai.fukui.jp":1,"sakai.ibaraki.jp":1,"sakai.osaka.jp":1,"sakaiminato.tottori.jp":1,"sakaki.nagano.jp":1,"sakata.yamagata.jp":1,"sakawa.kochi.jp":1,"sakegawa.yamagata.jp":1,"saku.nagano.jp":1,"sakuho.nagano.jp":1,"sakura.chiba.jp":1,"sakura.tochigi.jp":1,"sakuragawa.ibaraki.jp":1,"sakurai.nara.jp":1,"sakyo.kyoto.jp":1,"salangen.no":1,"salat.no":1,"salem.museum":1,"salerno.it":1,"saltdal.no":1,"salud.bo":1,"salvador.br":1,"salvadordali.museum":1,"salzburg.museum":1,"samegawa.fukushima.jp":1,"samnanger.no":1,"sampa.br":1,"samukawa.kanagawa.jp":1,"sanagochi.tokushima.jp":1,"sanda.hyogo.jp":1,"sandcats.io":1,"sande.more-og-romsdal.no":1,"sande.vestfold.no":1,"sande.xn--mre-og-romsdal-qqb.no":1,"sandefjord.no":1,"sandiego.museum":1,"sandnes.no":1,"sandnessjoen.no":1,"sandoy.no":1,"sanfrancisco.museum":1,"sango.nara.jp":1,"sanjo.niigata.jp":1,"sannan.hyogo.jp":1,"sannohe.aomori.jp":1,"sano.tochigi.jp":1,"sanok.pl":1,"santabarbara.museum":1,"santacruz.museum":1,"santafe.museum":1,"santamaria.br":1,"santoandre.br":1,"sanuki.kagawa.jp":1,"saobernardo.br":1,"saogonca.br":1,"saotome.st":1,"sapporo.jp":2,"sar.it":1,"sardegna.it":1,"sardinia.it":1,"saroma.hokkaido.jp":1,"sarpsborg.no":1,"sarufutsu.hokkaido.jp":1,"sasaguri.fukuoka.jp":1,"sasayama.hyogo.jp":1,"sasebo.nagasaki.jp":1,"saskatchewan.museum":1,"sassari.it":1,"satosho.okayama.jp":1,"satsumasendai.kagoshima.jp":1,"satte.saitama.jp":1,"satx.museum":1,"sauda.no":1,"sauherad.no":1,"savannahga.museum":1,"saves-the-whales.com":1,"savona.it":1,"sayama.osaka.jp":1,"sayama.saitama.jp":1,"sayo.hyogo.jp":1,"sb.ua":1,"sc.cn":1,"sc.gov.br":1,"sc.ke":1,"sc.kr":1,"sc.leg.br":1,"sc.ls":1,"sc.tz":1,"sc.ug":1,"sc.us":1,"scapp.io":1,"sch.ae":1,"sch.id":1,"sch.ir":1,"sch.jo":1,"sch.lk":1,"sch.ly":1,"sch.ng":1,"sch.qa":1,"sch.sa":1,"sch.so":1,"sch.uk":2,"sch.zm":1,"schlesisches.museum":1,"schoenbrunn.museum":1,"schokokeks.net":1,"schokoladen.museum":1,"school.museum":1,"school.na":1,"school.nz":1,"school.za":1,"schools.nsw.edu.au":1,"schulserver.de":1,"schweiz.museum":1,"sci.eg":1,"science-fiction.museum":1,"science.museum":1,"scienceandhistory.museum":1,"scienceandindustry.museum":1,"sciencecenter.museum":1,"sciencecenters.museum":1,"sciencehistory.museum":1,"sciences.museum":1,"sciencesnaturelles.museum":1,"scientist.aero":1,"scotland.museum":1,"scrapper-site.net":1,"scrapping.cc":1,"scrysec.com":1,"sd.cn":1,"sd.us":1,"sdn.gov.pl":1,"se.eu.org":1,"se.gov.br":1,"se.leg.br":1,"se.net":1,"seaport.museum":1,"sebastopol.ua":1,"sec.ps":1,"securitytactics.com":1,"seg.br":1,"seidat.net":1,"seihi.nagasaki.jp":1,"seika.kyoto.jp":1,"seiro.niigata.jp":1,"seirou.niigata.jp":1,"seiyo.ehime.jp":1,"sejny.pl":1,"seki.gifu.jp":1,"sekigahara.gifu.jp":1,"sekikawa.niigata.jp":1,"sel.no":1,"selbu.no":1,"selfip.biz":1,"selfip.com":1,"selfip.info":1,"selfip.net":1,"selfip.org":1,"selje.no":1,"seljord.no":1,"sells-for-less.com":1,"sells-for-u.com":1,"sells-it.net":1,"sellsyourhome.org":1,"semboku.akita.jp":1,"semine.miyagi.jp":1,"sendai.jp":2,"sennan.osaka.jp":1,"senseering.net":1,"sensiosite.cloud":2,"seoul.kr":1,"sera.hiroshima.jp":1,"seranishi.hiroshima.jp":1,"servebbs.com":1,"servebbs.net":1,"servebbs.org":1,"servebeer.com":1,"serveblog.net":1,"servecounterstrike.com":1,"serveexchange.com":1,"serveftp.com":1,"serveftp.net":1,"serveftp.org":1,"servegame.com":1,"servegame.org":1,"servehalflife.com":1,"servehttp.com":1,"servehumour.com":1,"serveirc.com":1,"serveminecraft.net":1,"servemp3.com":1,"servep2p.com":1,"servepics.com":1,"servequake.com":1,"servesarcasm.com":1,"service.gov.uk":1,"services.aero":1,"setagaya.tokyo.jp":1,"seto.aichi.jp":1,"setouchi.okayama.jp":1,"settlement.museum":1,"settlers.museum":1,"settsu.osaka.jp":1,"sevastopol.ua":1,"sex.hu":1,"sex.pl":1,"sf.no":1,"sh.cn":1,"shacknet.nu":1,"shakotan.hokkaido.jp":1,"shari.hokkaido.jp":1,"shell.museum":1,"sherbrooke.museum":1,"shibata.miyagi.jp":1,"shibata.niigata.jp":1,"shibecha.hokkaido.jp":1,"shibetsu.hokkaido.jp":1,"shibukawa.gunma.jp":1,"shibuya.tokyo.jp":1,"shichikashuku.miyagi.jp":1,"shichinohe.aomori.jp":1,"shiftedit.io":1,"shiga.jp":1,"shiiba.miyazaki.jp":1,"shijonawate.osaka.jp":1,"shika.ishikawa.jp":1,"shikabe.hokkaido.jp":1,"shikama.miyagi.jp":1,"shikaoi.hokkaido.jp":1,"shikatsu.aichi.jp":1,"shiki.saitama.jp":1,"shikokuchuo.ehime.jp":1,"shima.mie.jp":1,"shimabara.nagasaki.jp":1,"shimada.shizuoka.jp":1,"shimamaki.hokkaido.jp":1,"shimamoto.osaka.jp":1,"shimane.jp":1,"shimane.shimane.jp":1,"shimizu.hokkaido.jp":1,"shimizu.shizuoka.jp":1,"shimoda.shizuoka.jp":1,"shimodate.ibaraki.jp":1,"shimofusa.chiba.jp":1,"shimogo.fukushima.jp":1,"shimoichi.nara.jp":1,"shimoji.okinawa.jp":1,"shimokawa.hokkaido.jp":1,"shimokitayama.nara.jp":1,"shimonita.gunma.jp":1,"shimonoseki.yamaguchi.jp":1,"shimosuwa.nagano.jp":1,"shimotsuke.tochigi.jp":1,"shimotsuma.ibaraki.jp":1,"shinagawa.tokyo.jp":1,"shinanomachi.nagano.jp":1,"shingo.aomori.jp":1,"shingu.fukuoka.jp":1,"shingu.hyogo.jp":1,"shingu.wakayama.jp":1,"shinichi.hiroshima.jp":1,"shinjo.nara.jp":1,"shinjo.okayama.jp":1,"shinjo.yamagata.jp":1,"shinjuku.tokyo.jp":1,"shinkamigoto.nagasaki.jp":1,"shinonsen.hyogo.jp":1,"shinshinotsu.hokkaido.jp":1,"shinshiro.aichi.jp":1,"shinto.gunma.jp":1,"shintoku.hokkaido.jp":1,"shintomi.miyazaki.jp":1,"shinyoshitomi.fukuoka.jp":1,"shiogama.miyagi.jp":1,"shiojiri.nagano.jp":1,"shioya.tochigi.jp":1,"shirahama.wakayama.jp":1,"shirakawa.fukushima.jp":1,"shirakawa.gifu.jp":1,"shirako.chiba.jp":1,"shiranuka.hokkaido.jp":1,"shiraoi.hokkaido.jp":1,"shiraoka.saitama.jp":1,"shirataka.yamagata.jp":1,"shiriuchi.hokkaido.jp":1,"shiroi.chiba.jp":1,"shiroishi.miyagi.jp":1,"shiroishi.saga.jp":1,"shirosato.ibaraki.jp":1,"shishikui.tokushima.jp":1,"shiso.hyogo.jp":1,"shisui.chiba.jp":1,"shitara.aichi.jp":1,"shiwa.iwate.jp":1,"shizukuishi.iwate.jp":1,"shizuoka.jp":1,"shizuoka.shizuoka.jp":1,"shobara.hiroshima.jp":1,"shonai.fukuoka.jp":1,"shonai.yamagata.jp":1,"shoo.okayama.jp":1,"shop.ht":1,"shop.hu":1,"shop.pl":1,"shop.ro":1,"shop.th":1,"shopitsite.com":1,"shopware.store":1,"show.aero":1,"showa.fukushima.jp":1,"showa.gunma.jp":1,"showa.yamanashi.jp":1,"shunan.yamaguchi.jp":1,"shw.io":1,"si.eu.org":1,"si.it":1,"sibenik.museum":1,"sic.it":1,"sicilia.it":1,"sicily.it":1,"siellak.no":1,"siena.it":1,"sigdal.no":1,"siljan.no":1,"silk.museum":1,"simple-url.com":1,"sinaapp.com":1,"siracusa.it":1,"sirdal.no":1,"siteleaf.net":1,"sites.static.land":1,"sjc.br":1,"sk.ca":1,"sk.eu.org":1,"skanit.no":1,"skanland.no":1,"skaun.no":1,"skedsmo.no":1,"skedsmokorset.no":1,"ski.museum":1,"ski.no":1,"skien.no":1,"skierva.no":1,"skiptvet.no":1,"skjak.no":1,"skjervoy.no":1,"sklep.pl":1,"sko.gov.pl":1,"skoczow.pl":1,"skodje.no":1,"skole.museum":1,"skydiving.aero":1,"skygearapp.com":1,"slask.pl":1,"slattum.no":1,"sld.do":1,"sld.pa":1,"slg.br":1,"slupsk.pl":1,"slz.br":1,"sm.ua":1,"small-web.org":1,"smola.no":1,"sn.cn":1,"snaase.no":1,"snasa.no":1,"snillfjord.no":1,"snoasa.no":1,"so.gov.pl":1,"so.it":1,"sobetsu.hokkaido.jp":1,"soc.lk":1,"soc.srcf.net":1,"sochi.su":1,"society.museum":1,"sodegaura.chiba.jp":1,"soeda.fukuoka.jp":1,"software.aero":1,"sogndal.no":1,"sogne.no":1,"soja.okayama.jp":1,"soka.saitama.jp":1,"sokndal.no":1,"sola.no":1,"sologne.museum":1,"solund.no":1,"soma.fukushima.jp":1,"somna.no":1,"sondre-land.no":1,"sondrio.it":1,"songdalen.no":1,"soni.nara.jp":1,"soo.kagoshima.jp":1,"sopot.pl":1,"sor-aurdal.no":1,"sor-fron.no":1,"sor-odal.no":1,"sor-varanger.no":1,"sorfold.no":1,"sorocaba.br":1,"sorreisa.no":1,"sortland.no":1,"sorum.no":1,"sos.pl":1,"sosa.chiba.jp":1,"sosnowiec.pl":1,"soundandvision.museum":1,"soundcast.me":1,"southcarolina.museum":1,"southwest.museum":1,"sowa.ibaraki.jp":1,"sp.gov.br":1,"sp.it":1,"sp.leg.br":1,"space-to-rent.com":1,"space.museum":1,"spacekit.io":1,"spb.ru":1,"spb.su":1,"spdns.de":1,"spdns.eu":1,"spdns.org":1,"spectrum.myjino.ru":2,"sphinx.mythic-beasts.com":1,"spjelkavik.no":1,"sport.hu":1,"spy.museum":1,"spydeberg.no":1,"square.museum":1,"square7.ch":1,"square7.de":1,"square7.net":1,"sr.gov.pl":1,"sr.it":1,"srv.br":1,"ss.it":1,"ssl.origin.cdn77-secure.org":1,"st.no":1,"stackhero-network.com":1,"stadt.museum":1,"stage.nodeart.io":1,"staging.onred.one":1,"stalbans.museum":1,"stalowa-wola.pl":1,"stange.no":1,"starachowice.pl":1,"stargard.pl":1,"starnberg.museum":1,"starostwo.gov.pl":1,"stat.no":1,"state.museum":1,"stateofdelaware.museum":1,"stathelle.no":1,"static-access.net":1,"static.land":1,"static.observableusercontent.com":1,"statics.cloud":2,"station.museum":1,"stavanger.no":1,"stavern.no":1,"steam.museum":1,"steiermark.museum":1,"steigen.no":1,"steinkjer.no":1,"stg.dev":2,"sth.ac.at":1,"stjohn.museum":1,"stjordal.no":1,"stjordalshalsen.no":1,"stockholm.museum":1,"stokke.no":1,"stolos.io":2,"stor-elvdal.no":1,"storage.yandexcloud.net":1,"stord.no":1,"stordal.no":1,"store.bb":1,"store.dk":1,"store.nf":1,"store.ro":1,"store.st":1,"store.ve":1,"storfjord.no":1,"storj.farm":1,"stpetersburg.museum":1,"strand.no":1,"stranda.no":1,"stryn.no":1,"student.aero":1,"stuff-4-sale.org":1,"stuff-4-sale.us":1,"stufftoread.com":1,"stuttgart.museum":1,"sue.fukuoka.jp":1,"suedtirol.it":1,"suginami.tokyo.jp":1,"sugito.saitama.jp":1,"suifu.ibaraki.jp":1,"suisse.museum":1,"suita.osaka.jp":1,"sukagawa.fukushima.jp":1,"sukumo.kochi.jp":1,"sula.no":1,"suldal.no":1,"suli.hu":1,"sumida.tokyo.jp":1,"sumita.iwate.jp":1,"sumoto.hyogo.jp":1,"sumoto.kumamoto.jp":1,"sumy.ua":1,"sunagawa.hokkaido.jp":1,"sund.no":1,"sunndal.no":1,"surgeonshall.museum":1,"surnadal.no":1,"surrey.museum":1,"susaki.kochi.jp":1,"susono.shizuoka.jp":1,"suwa.nagano.jp":1,"suwalki.pl":1,"suzaka.nagano.jp":1,"suzu.ishikawa.jp":1,"suzuka.mie.jp":1,"sv.it":1,"svalbard.no":1,"svc.firenet.ch":2,"sveio.no":1,"svelvik.no":1,"svizzera.museum":1,"svn-repos.de":1,"sweden.museum":1,"sweetpepper.org":1,"swidnica.pl":1,"swidnik.pl":1,"swiebodzin.pl":1,"swinoujscie.pl":1,"sx.cn":1,"sydney.museum":1,"sykkylven.no":1,"syncloud.it":1,"syno-ds.de":1,"synology-diskstation.de":1,"synology-ds.de":1,"synology.me":1,"sys.qcx.io":2,"sytes.net":1,"szczecin.pl":1,"szczytno.pl":1,"szex.hu":1,"szkola.pl":1,"t.bg":1,"t.se":1,"t3l3p0rt.net":1,"ta.it":1,"taa.it":1,"tabayama.yamanashi.jp":1,"tabuse.yamaguchi.jp":1,"tachiarai.fukuoka.jp":1,"tachikawa.tokyo.jp":1,"tadaoka.osaka.jp":1,"tado.mie.jp":1,"tadotsu.kagawa.jp":1,"tagajo.miyagi.jp":1,"tagami.niigata.jp":1,"tagawa.fukuoka.jp":1,"tahara.aichi.jp":1,"taifun-dns.de":1,"taiji.wakayama.jp":1,"taiki.hokkaido.jp":1,"taiki.mie.jp":1,"tainai.niigata.jp":1,"taira.toyama.jp":1,"taishi.hyogo.jp":1,"taishi.osaka.jp":1,"taishin.fukushima.jp":1,"taito.tokyo.jp":1,"taiwa.miyagi.jp":1,"tajimi.gifu.jp":1,"tajiri.osaka.jp":1,"taka.hyogo.jp":1,"takagi.nagano.jp":1,"takahagi.ibaraki.jp":1,"takahama.aichi.jp":1,"takahama.fukui.jp":1,"takaharu.miyazaki.jp":1,"takahashi.okayama.jp":1,"takahata.yamagata.jp":1,"takaishi.osaka.jp":1,"takamatsu.kagawa.jp":1,"takamori.kumamoto.jp":1,"takamori.nagano.jp":1,"takanabe.miyazaki.jp":1,"takanezawa.tochigi.jp":1,"takaoka.toyama.jp":1,"takarazuka.hyogo.jp":1,"takasago.hyogo.jp":1,"takasaki.gunma.jp":1,"takashima.shiga.jp":1,"takasu.hokkaido.jp":1,"takata.fukuoka.jp":1,"takatori.nara.jp":1,"takatsuki.osaka.jp":1,"takatsuki.shiga.jp":1,"takayama.gifu.jp":1,"takayama.gunma.jp":1,"takayama.nagano.jp":1,"takazaki.miyazaki.jp":1,"takehara.hiroshima.jp":1,"taketa.oita.jp":1,"taketomi.okinawa.jp":1,"taki.mie.jp":1,"takikawa.hokkaido.jp":1,"takino.hyogo.jp":1,"takinoue.hokkaido.jp":1,"takko.aomori.jp":1,"tako.chiba.jp":1,"taku.saga.jp":1,"tama.tokyo.jp":1,"tamakawa.fukushima.jp":1,"tamaki.mie.jp":1,"tamamura.gunma.jp":1,"tamano.okayama.jp":1,"tamatsukuri.ibaraki.jp":1,"tamayu.shimane.jp":1,"tamba.hyogo.jp":1,"tana.no":1,"tanabe.kyoto.jp":1,"tanabe.wakayama.jp":1,"tanagura.fukushima.jp":1,"tananger.no":1,"tank.museum":1,"tanohata.iwate.jp":1,"tara.saga.jp":1,"tarama.okinawa.jp":1,"taranto.it":1,"targi.pl":1,"tarnobrzeg.pl":1,"tarui.gifu.jp":1,"tarumizu.kagoshima.jp":1,"tas.au":1,"tas.edu.au":1,"tas.gov.au":1,"tashkent.su":1,"tatebayashi.gunma.jp":1,"tateshina.nagano.jp":1,"tateyama.chiba.jp":1,"tateyama.toyama.jp":1,"tatsuno.hyogo.jp":1,"tatsuno.nagano.jp":1,"tawaramoto.nara.jp":1,"taxi.br":1,"tc.br":1,"tcm.museum":1,"tcp4.me":1,"te.it":1,"te.ua":1,"teaches-yoga.com":1,"teams.algorithmia.com":0,"tec.br":1,"tec.mi.us":1,"tec.ve":1,"technology.museum":1,"tecnologia.bo":1,"tel.tr":1,"tele.amune.org":1,"telebit.app":1,"telebit.io":1,"telebit.xyz":2,"telekommunikation.museum":1,"television.museum":1,"temp-dns.com":1,"tempio-olbia.it":1,"tempioolbia.it":1,"tendo.yamagata.jp":1,"tenei.fukushima.jp":1,"tenkawa.nara.jp":1,"tenri.nara.jp":1,"teo.br":1,"teramo.it":1,"termez.su":1,"terni.it":1,"ternopil.ua":1,"teshikaga.hokkaido.jp":1,"test-iserv.de":1,"test.algorithmia.com":0,"test.ru":1,"test.tj":1,"texas.museum":1,"textile.museum":1,"tgory.pl":1,"the.br":1,"theater.museum":1,"theworkpc.com":1,"thingdustdata.com":1,"thruhere.net":1,"time.museum":1,"time.no":1,"timekeeping.museum":1,"tingvoll.no":1,"tinn.no":1,"tj.cn":1,"tjeldsund.no":1,"tjome.no":1,"tksat.bo":1,"tm.cy":1,"tm.fr":1,"tm.hu":1,"tm.km":1,"tm.mc":1,"tm.mg":1,"tm.no":1,"tm.pl":1,"tm.ro":1,"tm.se":1,"tm.za":1,"tmp.br":1,"tn.it":1,"tn.us":1,"to.gov.br":1,"to.gt":1,"to.it":1,"to.leg.br":1,"to.md":1,"to.work":1,"toba.mie.jp":1,"tobe.ehime.jp":1,"tobetsu.hokkaido.jp":1,"tobishima.aichi.jp":1,"tochigi.jp":1,"tochigi.tochigi.jp":1,"tochio.niigata.jp":1,"toda.saitama.jp":1,"toei.aichi.jp":1,"toga.toyama.jp":1,"togakushi.nagano.jp":1,"togane.chiba.jp":1,"togitsu.nagasaki.jp":1,"togliatti.su":1,"togo.aichi.jp":1,"togura.nagano.jp":1,"tohma.hokkaido.jp":1,"tohnosho.chiba.jp":1,"toho.fukuoka.jp":1,"tokai.aichi.jp":1,"tokai.ibaraki.jp":1,"tokamachi.niigata.jp":1,"tokashiki.okinawa.jp":1,"toki.gifu.jp":1,"tokigawa.saitama.jp":1,"tokke.no":1,"tokoname.aichi.jp":1,"tokorozawa.saitama.jp":1,"tokushima.jp":1,"tokushima.tokushima.jp":1,"tokuyama.yamaguchi.jp":1,"tokyo.jp":1,"tolga.no":1,"tomakomai.hokkaido.jp":1,"tomari.hokkaido.jp":1,"tome.miyagi.jp":1,"tomi.nagano.jp":1,"tomigusuku.okinawa.jp":1,"tomika.gifu.jp":1,"tomioka.gunma.jp":1,"tomisato.chiba.jp":1,"tomiya.miyagi.jp":1,"tomobe.ibaraki.jp":1,"tonaki.okinawa.jp":1,"tonami.toyama.jp":1,"tondabayashi.osaka.jp":1,"tone.ibaraki.jp":1,"tono.iwate.jp":1,"tonosho.kagawa.jp":1,"tonsberg.no":1,"toolforge.org":1,"toon.ehime.jp":1,"topology.museum":1,"torahime.shiga.jp":1,"toride.ibaraki.jp":1,"torino.it":1,"torino.museum":1,"torsken.no":1,"tos.it":1,"tosa.kochi.jp":1,"tosashimizu.kochi.jp":1,"toscana.it":1,"toshima.tokyo.jp":1,"tosu.saga.jp":1,"tottori.jp":1,"tottori.tottori.jp":1,"touch.museum":1,"tourism.pl":1,"tourism.tn":1,"towada.aomori.jp":1,"town.museum":1,"townnews-staging.com":1,"toya.hokkaido.jp":1,"toyako.hokkaido.jp":1,"toyama.jp":1,"toyama.toyama.jp":1,"toyo.kochi.jp":1,"toyoake.aichi.jp":1,"toyohashi.aichi.jp":1,"toyokawa.aichi.jp":1,"toyonaka.osaka.jp":1,"toyone.aichi.jp":1,"toyono.osaka.jp":1,"toyooka.hyogo.jp":1,"toyosato.shiga.jp":1,"toyota.aichi.jp":1,"toyota.yamaguchi.jp":1,"toyotomi.hokkaido.jp":1,"toyotsu.fukuoka.jp":1,"toyoura.hokkaido.jp":1,"tozawa.yamagata.jp":1,"tozsde.hu":1,"tp.it":1,"tr.eu.org":1,"tr.it":1,"tr.no":1,"tra.kp":1,"trader.aero":1,"trading.aero":1,"traeumtgerade.de":1,"trafficplex.cloud":1,"trainer.aero":1,"trana.no":1,"tranby.no":1,"trani-andria-barletta.it":1,"trani-barletta-andria.it":1,"traniandriabarletta.it":1,"tranibarlettaandria.it":1,"tranoy.no":1,"transport.museum":1,"transporte.bo":1,"transurl.be":2,"transurl.eu":2,"transurl.nl":2,"trapani.it":1,"travel.pl":1,"travel.tt":1,"trd.br":1,"tree.museum":1,"trentin-sud-tirol.it":1,"trentin-sudtirol.it":1,"trentin-sued-tirol.it":1,"trentin-suedtirol.it":1,"trentino-a-adige.it":1,"trentino-aadige.it":1,"trentino-alto-adige.it":1,"trentino-altoadige.it":1,"trentino-s-tirol.it":1,"trentino-stirol.it":1,"trentino-sud-tirol.it":1,"trentino-sudtirol.it":1,"trentino-sued-tirol.it":1,"trentino-suedtirol.it":1,"trentino.it":1,"trentinoa-adige.it":1,"trentinoaadige.it":1,"trentinoalto-adige.it":1,"trentinoaltoadige.it":1,"trentinos-tirol.it":1,"trentinostirol.it":1,"trentinosud-tirol.it":1,"trentinosudtirol.it":1,"trentinosued-tirol.it":1,"trentinosuedtirol.it":1,"trentinsud-tirol.it":1,"trentinsudtirol.it":1,"trentinsued-tirol.it":1,"trentinsuedtirol.it":1,"trento.it":1,"treviso.it":1,"trieste.it":1,"triton.zone":2,"troandin.no":1,"trogstad.no":1,"troitsk.su":1,"trolley.museum":1,"tromsa.no":1,"tromso.no":1,"trondheim.no":1,"trust.museum":1,"trustee.museum":1,"trycloudflare.com":1,"trysil.no":1,"ts.it":1,"tselinograd.su":1,"tsk.tr":1,"tsu.mie.jp":1,"tsubame.niigata.jp":1,"tsubata.ishikawa.jp":1,"tsubetsu.hokkaido.jp":1,"tsuchiura.ibaraki.jp":1,"tsuga.tochigi.jp":1,"tsugaru.aomori.jp":1,"tsuiki.fukuoka.jp":1,"tsukigata.hokkaido.jp":1,"tsukiyono.gunma.jp":1,"tsukuba.ibaraki.jp":1,"tsukui.kanagawa.jp":1,"tsukumi.oita.jp":1,"tsumagoi.gunma.jp":1,"tsunan.niigata.jp":1,"tsuno.kochi.jp":1,"tsuno.miyazaki.jp":1,"tsuru.yamanashi.jp":1,"tsuruga.fukui.jp":1,"tsurugashima.saitama.jp":1,"tsurugi.ishikawa.jp":1,"tsuruoka.yamagata.jp":1,"tsuruta.aomori.jp":1,"tsushima.aichi.jp":1,"tsushima.nagasaki.jp":1,"tsuwano.shimane.jp":1,"tsuyama.okayama.jp":1,"tt.im":1,"tula.su":1,"tunk.org":1,"tur.ar":1,"tur.br":1,"turek.pl":1,"turen.tn":1,"turin.it":1,"turystyka.pl":1,"tuscany.it":1,"tuva.su":1,"tuxfamily.org":1,"tv.bb":1,"tv.bo":1,"tv.br":1,"tv.im":1,"tv.it":1,"tv.kg":1,"tv.na":1,"tv.sd":1,"tv.tr":1,"tv.tz":1,"tvedestrand.no":1,"tw.cn":1,"twmail.cc":1,"twmail.net":1,"twmail.org":1,"tx.us":1,"tychy.pl":1,"tydal.no":1,"tynset.no":1,"tysfjord.no":1,"tysnes.no":1,"tysvar.no":1,"u.bg":1,"u.channelsdvr.net":1,"u.se":1,"u2-local.xnbay.com":1,"u2.xnbay.com":1,"ua.rs":1,"ube.yamaguchi.jp":1,"uber.space":1,"uberspace.de":2,"uchihara.ibaraki.jp":1,"uchiko.ehime.jp":1,"uchinada.ishikawa.jp":1,"uchinomi.kagawa.jp":1,"ud.it":1,"uda.nara.jp":1,"udi.br":1,"udine.it":1,"udono.mie.jp":1,"ueda.nagano.jp":1,"ueno.gunma.jp":1,"uenohara.yamanashi.jp":1,"ufcfan.org":1,"ug.gov.pl":1,"ugim.gov.pl":1,"uhren.museum":1,"ui.nabu.casa":1,"uji.kyoto.jp":1,"ujiie.tochigi.jp":1,"ujitawara.kyoto.jp":1,"uk.com":1,"uk.eu.org":1,"uk.kg":1,"uk.net":1,"uk0.bigv.io":1,"ukco.me":1,"uki.kumamoto.jp":1,"ukiha.fukuoka.jp":1,"uklugs.org":1,"ullensaker.no":1,"ullensvang.no":1,"ulm.museum":1,"ulsan.kr":1,"ulvik.no":1,"um.gov.pl":1,"umaji.kochi.jp":1,"umb.it":1,"umbria.it":1,"umi.fukuoka.jp":1,"umig.gov.pl":1,"unazuki.toyama.jp":1,"undersea.museum":1,"uni5.net":1,"union.aero":1,"univ.sn":1,"university.museum":1,"unjarga.no":1,"unnan.shimane.jp":1,"unusualperson.com":1,"unzen.nagasaki.jp":1,"uonuma.niigata.jp":1,"uozu.toyama.jp":1,"upow.gov.pl":1,"uppo.gov.pl":1,"urakawa.hokkaido.jp":1,"urasoe.okinawa.jp":1,"urausu.hokkaido.jp":1,"urawa.saitama.jp":1,"urayasu.chiba.jp":1,"urbino-pesaro.it":1,"urbinopesaro.it":1,"ureshino.mie.jp":1,"uri.arpa":1,"url.tw":1,"urn.arpa":1,"urown.cloud":1,"uruma.okinawa.jp":1,"uryu.hokkaido.jp":1,"us-1.evennode.com":1,"us-2.evennode.com":1,"us-3.evennode.com":1,"us-4.evennode.com":1,"us-east-1.amazonaws.com":1,"us-east-1.elasticbeanstalk.com":1,"us-east-2.elasticbeanstalk.com":1,"us-gov-west-1.elasticbeanstalk.com":1,"us-west-1.elasticbeanstalk.com":1,"us-west-2.elasticbeanstalk.com":1,"us.ax":1,"us.com":1,"us.eu.org":1,"us.gov.pl":1,"us.kg":1,"us.na":1,"us.org":1,"us.platform.sh":1,"usa.museum":1,"usa.oita.jp":1,"usantiques.museum":1,"usarts.museum":1,"uscountryestate.museum":1,"usculture.museum":1,"usdecorativearts.museum":1,"user.aseinet.ne.jp":1,"user.party.eus":1,"user.srcf.net":1,"usercontent.jp":1,"usgarden.museum":1,"ushiku.ibaraki.jp":1,"ushistory.museum":1,"ushuaia.museum":1,"uslivinghistory.museum":1,"usr.cloud.muni.cz":1,"ustka.pl":1,"usui.fukuoka.jp":1,"usuki.oita.jp":1,"ut.us":1,"utah.museum":1,"utashinai.hokkaido.jp":1,"utazas.hu":1,"utazu.kagawa.jp":1,"uto.kumamoto.jp":1,"utsira.no":1,"utsunomiya.tochigi.jp":1,"utwente.io":1,"uvic.museum":1,"uw.gov.pl":1,"uwajima.ehime.jp":1,"uwu.ai":1,"uwu.nu":1,"uy.com":1,"uz.ua":1,"uzhgorod.ua":1,"uzs.gov.pl":1,"v-info.info":1,"v.bg":1,"v.ua":1,"va.it":1,"va.no":1,"va.us":1,"vaapste.no":1,"vadso.no":1,"vaga.no":1,"vagan.no":1,"vagsoy.no":1,"vaksdal.no":1,"val-d-aosta.it":1,"val-daosta.it":1,"vald-aosta.it":1,"valdaosta.it":1,"valer.hedmark.no":1,"valer.ostfold.no":1,"valle-aosta.it":1,"valle-d-aosta.it":1,"valle-daosta.it":1,"valle.no":1,"valleaosta.it":1,"valled-aosta.it":1,"valledaosta.it":1,"vallee-aoste.it":1,"vallee-d-aoste.it":1,"valleeaoste.it":1,"valleedaoste.it":1,"valley.museum":1,"vang.no":1,"vantaa.museum":1,"vanylven.no":1,"vao.it":1,"vapor.cloud":1,"vaporcloud.io":1,"vardo.no":1,"varese.it":1,"varggat.no":1,"varoy.no":1,"vb.it":1,"vc.it":1,"vda.it":1,"ve.it":1,"vefsn.no":1,"vega.no":1,"vegarshei.no":1,"ven.it":1,"veneto.it":1,"venezia.it":1,"venice.it":1,"vennesla.no":1,"verbania.it":1,"vercel.app":1,"vercel.dev":1,"vercelli.it":1,"verdal.no":1,"verona.it":1,"verran.no":1,"versailles.museum":1,"vestby.no":1,"vestnes.no":1,"vestre-slidre.no":1,"vestre-toten.no":1,"vestvagoy.no":1,"vet.br":1,"veterinaire.fr":1,"veterinaire.km":1,"vevelstad.no":1,"vf.no":1,"vgs.no":1,"vi.it":1,"vi.us":1,"vibo-valentia.it":1,"vibovalentia.it":1,"vic.au":1,"vic.edu.au":1,"vic.gov.au":1,"vicenza.it":1,"video.hu":1,"vik.no":1,"viking.museum":1,"vikna.no":1,"village.museum":1,"vindafjord.no":1,"vinnica.ua":1,"vinnytsia.ua":1,"vip.jelastic.cloud":1,"vipsinaapp.com":1,"virginia.museum":1,"virtual-user.de":1,"virtual.museum":1,"virtualserver.io":1,"virtualuser.de":1,"virtueeldomein.nl":1,"virtuel.museum":1,"viterbo.it":1,"vix.br":1,"vlaanderen.museum":1,"vladikavkaz.ru":1,"vladikavkaz.su":1,"vladimir.ru":1,"vladimir.su":1,"vlog.br":1,"vm.bytemark.co.uk":1,"vn.ua":1,"voagat.no":1,"volda.no":1,"volkenkunde.museum":1,"vologda.su":1,"volyn.ua":1,"voorloper.cloud":1,"voss.no":1,"vossevangen.no":1,"vpndns.net":1,"vpnplus.to":1,"vps.mcdir.ru":1,"vps.myjino.ru":2,"vr.it":1,"vs.it":1,"vs.mythic-beasts.com":1,"vt.it":1,"vt.us":1,"vv.it":1,"vxl.sh":1,"w.bg":1,"w.se":1,"wa.au":1,"wa.edu.au":1,"wa.gov.au":1,"wa.us":1,"wada.nagano.jp":1,"wafflecell.com":1,"wajiki.tokushima.jp":1,"wajima.ishikawa.jp":1,"wakasa.fukui.jp":1,"wakasa.tottori.jp":1,"wakayama.jp":1,"wakayama.wakayama.jp":1,"wake.okayama.jp":1,"wakkanai.hokkaido.jp":1,"wakuya.miyagi.jp":1,"walbrzych.pl":1,"wales.museum":1,"wallonie.museum":1,"wanouchi.gifu.jp":1,"war.museum":1,"warabi.saitama.jp":1,"warmia.pl":1,"warszawa.pl":1,"washingtondc.museum":1,"washtenaw.mi.us":1,"wassamu.hokkaido.jp":1,"watarai.mie.jp":1,"watari.miyagi.jp":1,"watch-and-clock.museum":1,"watchandclock.museum":1,"waw.pl":1,"wazuka.kyoto.jp":1,"we.bs":1,"we.tc":1,"web.app":1,"web.bo":1,"web.co":1,"web.do":1,"web.gu":1,"web.id":1,"web.in":1,"web.lk":1,"web.nf":1,"web.ni":1,"web.pk":1,"web.tj":1,"web.tr":1,"web.ve":1,"web.za":1,"webhare.dev":2,"webhop.biz":1,"webhop.info":1,"webhop.me":1,"webhop.net":1,"webhop.org":1,"webhosting.be":1,"webredirect.org":1,"website.yandexcloud.net":1,"webspace.rocks":1,"wedeploy.io":1,"wedeploy.me":1,"wedeploy.sh":1,"wegrow.pl":1,"wellbeingzone.co.uk":1,"wellbeingzone.eu":1,"western.museum":1,"westfalen.museum":1,"whaling.museum":1,"wi.us":1,"wielun.pl":1,"wien.funkfeuer.at":1,"wif.gov.pl":1,"wiih.gov.pl":1,"wiki.bo":1,"wiki.br":1,"wildlife.museum":1,"williamsburg.museum":1,"winb.gov.pl":1,"windmill.museum":1,"wios.gov.pl":1,"witd.gov.pl":1,"withgoogle.com":1,"withyoutube.com":1,"wiw.gov.pl":1,"wlocl.pl":1,"wloclawek.pl":1,"wmcloud.org":1,"wmflabs.org":1,"wnext.app":1,"wodzislaw.pl":1,"wolomin.pl":1,"workers.dev":1,"workinggroup.aero":1,"workisboring.com":1,"works.aero":1,"workshop.museum":1,"worse-than.tv":1,"wpdevcloud.com":1,"wpenginepowered.com":1,"writesthisblog.com":1,"wroc.pl":1,"wroclaw.pl":1,"ws.na":1,"wsa.gov.pl":1,"wskr.gov.pl":1,"wuoz.gov.pl":1,"wv.us":1,"www.ck":0,"www.ro":1,"wy.us":1,"wzmiuw.gov.pl":1,"x.bg":1,"x.mythic-beasts.com":1,"x.se":1,"x443.pw":1,"xen.prgmr.com":1,"xenapponazure.com":1,"xj.cn":1,"xn--0trq7p7nn.jp":1,"xn--12c1fe0br.xn--o3cw4h":1,"xn--12cfi8ixb8l.xn--o3cw4h":1,"xn--12co0c3b4eva.xn--o3cw4h":1,"xn--1ctwo.jp":1,"xn--1lqs03n.jp":1,"xn--1lqs71d.jp":1,"xn--2m4a15e.jp":1,"xn--32vp30h.jp":1,"xn--4it168d.jp":1,"xn--4it797k.jp":1,"xn--4pvxs.jp":1,"xn--55qx5d.cn":1,"xn--55qx5d.hk":1,"xn--55qx5d.xn--j6w193g":1,"xn--5js045d.jp":1,"xn--5rtp49c.jp":1,"xn--5rtq34k.jp":1,"xn--6btw5a.jp":1,"xn--6orx2r.jp":1,"xn--7t0a264c.jp":1,"xn--80au.xn--90a3ac":1,"xn--8ltr62k.jp":1,"xn--8pvr4u.jp":1,"xn--90azh.xn--90a3ac":1,"xn--9dbhblg6di.museum":1,"xn--andy-ira.no":1,"xn--aroport-bya.ci":1,"xn--asky-ira.no":1,"xn--aurskog-hland-jnb.no":1,"xn--avery-yua.no":1,"xn--b-5ga.nordland.no":1,"xn--b-5ga.telemark.no":1,"xn--balsan-sdtirol-nsb.it":1,"xn--bdddj-mrabd.no":1,"xn--bearalvhki-y4a.no":1,"xn--berlevg-jxa.no":1,"xn--bhcavuotna-s4a.no":1,"xn--bhccavuotna-k7a.no":1,"xn--bidr-5nac.no":1,"xn--bievt-0qa.no":1,"xn--bjarky-fya.no":1,"xn--bjddar-pta.no":1,"xn--blt-elab.no":1,"xn--bmlo-gra.no":1,"xn--bod-2na.no":1,"xn--bozen-sdtirol-2ob.it":1,"xn--brnny-wuac.no":1,"xn--brnnysund-m8ac.no":1,"xn--brum-voa.no":1,"xn--btsfjord-9za.no":1,"xn--bulsan-sdtirol-nsb.it":1,"xn--c1avg.xn--90a3ac":1,"xn--c3s14m.jp":1,"xn--cesena-forl-mcb.it":1,"xn--cesenaforl-i8a.it":1,"xn--ciqpn.hk":1,"xn--comunicaes-v6a2o.museum":1,"xn--correios-e-telecomunicaes-ghc29a.museum":1,"xn--czrw28b.tw":1,"xn--d1at.xn--90a3ac":1,"xn--d5qv7z876c.jp":1,"xn--davvenjrga-y4a.no":1,"xn--djrs72d6uy.jp":1,"xn--djty4k.jp":1,"xn--dnna-gra.no":1,"xn--drbak-wua.no":1,"xn--dyry-ira.no":1,"xn--efvn9s.jp":1,"xn--ehqz56n.jp":1,"xn--elqq16h.jp":1,"xn--eveni-0qa01ga.no":1,"xn--f6qx53a.jp":1,"xn--finny-yua.no":1,"xn--fjord-lra.no":1,"xn--fl-zia.no":1,"xn--flor-jra.no":1,"xn--forl-cesena-fcb.it":1,"xn--forlcesena-c8a.it":1,"xn--frde-gra.no":1,"xn--frna-woa.no":1,"xn--frya-hra.no":1,"xn--ggaviika-8ya47h.no":1,"xn--gildeskl-g0a.no":1,"xn--givuotna-8ya.no":1,"xn--gjvik-wua.no":1,"xn--gls-elac.no":1,"xn--gmq050i.hk":1,"xn--gmqw5a.hk":1,"xn--gmqw5a.xn--j6w193g":1,"xn--h-2fa.no":1,"xn--h1aegh.museum":1,"xn--h3cuzk1di.xn--o3cw4h":1,"xn--hbmer-xqa.no":1,"xn--hcesuolo-7ya35b.no":1,"xn--hery-ira.nordland.no":1,"xn--hery-ira.xn--mre-og-romsdal-qqb.no":1,"xn--hgebostad-g3a.no":1,"xn--hkkinen-5wa.fi":1,"xn--hmmrfeasta-s4ac.no":1,"xn--hnefoss-q1a.no":1,"xn--hobl-ira.no":1,"xn--holtlen-hxa.no":1,"xn--hpmir-xqa.no":1,"xn--hyanger-q1a.no":1,"xn--hylandet-54a.no":1,"xn--indery-fya.no":1,"xn--io0a7i.cn":1,"xn--io0a7i.hk":1,"xn--jlster-bya.no":1,"xn--jrpeland-54a.no":1,"xn--k7yn95e.jp":1,"xn--karmy-yua.no":1,"xn--kbrq7o.jp":1,"xn--kfjord-iua.no":1,"xn--klbu-woa.no":1,"xn--klt787d.jp":1,"xn--kltp7d.jp":1,"xn--kltx9a.jp":1,"xn--klty5x.jp":1,"xn--koluokta-7ya57h.no":1,"xn--krager-gya.no":1,"xn--kranghke-b0a.no":1,"xn--krdsherad-m8a.no":1,"xn--krehamn-dxa.no":1,"xn--krjohka-hwab49j.no":1,"xn--ksnes-uua.no":1,"xn--kvfjord-nxa.no":1,"xn--kvitsy-fya.no":1,"xn--kvnangen-k0a.no":1,"xn--l-1fa.no":1,"xn--laheadju-7ya.no":1,"xn--langevg-jxa.no":1,"xn--lcvr32d.hk":1,"xn--ldingen-q1a.no":1,"xn--leagaviika-52b.no":1,"xn--lesund-hua.no":1,"xn--lgrd-poac.no":1,"xn--lhppi-xqa.no":1,"xn--linds-pra.no":1,"xn--lns-qla.museum":1,"xn--loabt-0qa.no":1,"xn--lrdal-sra.no":1,"xn--lrenskog-54a.no":1,"xn--lt-liac.no":1,"xn--lten-gra.no":1,"xn--lury-ira.no":1,"xn--m3ch0j3a.xn--o3cw4h":1,"xn--mely-ira.no":1,"xn--merker-kua.no":1,"xn--mgba3a4f16a.ir":1,"xn--mgba3a4fra.ir":1,"xn--mjndalen-64a.no":1,"xn--mk0axi.hk":1,"xn--mkru45i.jp":1,"xn--mlatvuopmi-s4a.no":1,"xn--mli-tla.no":1,"xn--mlselv-iua.no":1,"xn--moreke-jua.no":1,"xn--mori-qsa.nz":1,"xn--mosjen-eya.no":1,"xn--mot-tla.no":1,"xn--msy-ula0h.no":1,"xn--mtta-vrjjat-k7af.no":1,"xn--muost-0qa.no":1,"xn--mxtq1m.hk":1,"xn--mxtq1m.xn--j6w193g":1,"xn--nit225k.jp":1,"xn--nmesjevuemie-tcba.no":1,"xn--nry-yla5g.no":1,"xn--ntso0iqx3a.jp":1,"xn--ntsq17g.jp":1,"xn--nttery-byae.no":1,"xn--nvuotna-hwa.no":1,"xn--o1ac.xn--90a3ac":1,"xn--o1ach.xn--90a3ac":1,"xn--o3cyx2a.xn--o3cw4h":1,"xn--od0alg.cn":1,"xn--od0alg.hk":1,"xn--od0alg.xn--j6w193g":1,"xn--od0aq3b.hk":1,"xn--oppegrd-ixa.no":1,"xn--ostery-fya.no":1,"xn--osyro-wua.no":1,"xn--porsgu-sta26f.no":1,"xn--pssu33l.jp":1,"xn--qqqt11m.jp":1,"xn--rady-ira.no":1,"xn--rdal-poa.no":1,"xn--rde-ula.no":1,"xn--rdy-0nab.no":1,"xn--rennesy-v1a.no":1,"xn--rhkkervju-01af.no":1,"xn--rholt-mra.no":1,"xn--rht27z.jp":1,"xn--rht3d.jp":1,"xn--rht61e.jp":1,"xn--risa-5na.no":1,"xn--risr-ira.no":1,"xn--rland-uua.no":1,"xn--rlingen-mxa.no":1,"xn--rmskog-bya.no":1,"xn--rny31h.jp":1,"xn--rros-gra.no":1,"xn--rskog-uua.no":1,"xn--rst-0na.no":1,"xn--rsta-fra.no":1,"xn--ryken-vua.no":1,"xn--ryrvik-bya.no":1,"xn--s-1fa.no":1,"xn--sandnessjen-ogb.no":1,"xn--sandy-yua.no":1,"xn--sdtirol-n2a.it":1,"xn--seral-lra.no":1,"xn--sgne-gra.no":1,"xn--skierv-uta.no":1,"xn--skjervy-v1a.no":1,"xn--skjk-soa.no":1,"xn--sknit-yqa.no":1,"xn--sknland-fxa.no":1,"xn--slat-5na.no":1,"xn--slt-elab.no":1,"xn--smla-hra.no":1,"xn--smna-gra.no":1,"xn--snase-nra.no":1,"xn--sndre-land-0cb.no":1,"xn--snes-poa.no":1,"xn--snsa-roa.no":1,"xn--sr-aurdal-l8a.no":1,"xn--sr-fron-q1a.no":1,"xn--sr-odal-q1a.no":1,"xn--sr-varanger-ggb.no":1,"xn--srfold-bya.no":1,"xn--srreisa-q1a.no":1,"xn--srum-gra.no":1,"xn--stjrdal-s1a.no":1,"xn--stjrdalshalsen-sqb.no":1,"xn--stre-toten-zcb.no":1,"xn--tjme-hra.no":1,"xn--tn0ag.hk":1,"xn--tnsberg-q1a.no":1,"xn--tor131o.jp":1,"xn--trany-yua.no":1,"xn--trentin-sd-tirol-rzb.it":1,"xn--trentin-sdtirol-7vb.it":1,"xn--trentino-sd-tirol-c3b.it":1,"xn--trentino-sdtirol-szb.it":1,"xn--trentinosd-tirol-rzb.it":1,"xn--trentinosdtirol-7vb.it":1,"xn--trentinsd-tirol-6vb.it":1,"xn--trentinsdtirol-nsb.it":1,"xn--trgstad-r1a.no":1,"xn--trna-woa.no":1,"xn--troms-zua.no":1,"xn--tysvr-vra.no":1,"xn--uc0atv.hk":1,"xn--uc0atv.tw":1,"xn--uc0atv.xn--j6w193g":1,"xn--uc0ay4a.hk":1,"xn--uist22h.jp":1,"xn--uisz3g.jp":1,"xn--unjrga-rta.no":1,"xn--uuwu58a.jp":1,"xn--vads-jra.no":1,"xn--valle-aoste-ebb.it":1,"xn--valle-d-aoste-ehb.it":1,"xn--valleaoste-e7a.it":1,"xn--valledaoste-ebb.it":1,"xn--vard-jra.no":1,"xn--vegrshei-c0a.no":1,"xn--vestvgy-ixa6o.no":1,"xn--vg-yiab.no":1,"xn--vgan-qoa.no":1,"xn--vgsy-qoa0j.no":1,"xn--vgu402c.jp":1,"xn--vler-qoa.hedmark.no":1,"xn--vler-qoa.xn--stfold-9xa.no":1,"xn--vre-eiker-k8a.no":1,"xn--vrggt-xqad.no":1,"xn--vry-yla5g.no":1,"xn--wcvs22d.hk":1,"xn--wcvs22d.xn--j6w193g":1,"xn--yer-zna.no":1,"xn--ygarden-p1a.no":1,"xn--ystre-slidre-ujb.no":1,"xn--zbx025d.jp":1,"xn--zf0ao64a.tw":1,"xn--zf0avx.hk":1,"xnbay.com":1,"xs4all.space":1,"xx.gl":1,"xy.ax":1,"xz.cn":1,"y.bg":1,"y.se":1,"yabu.hyogo.jp":1,"yabuki.fukushima.jp":1,"yachimata.chiba.jp":1,"yachiyo.chiba.jp":1,"yachiyo.ibaraki.jp":1,"yaese.okinawa.jp":1,"yahaba.iwate.jp":1,"yahiko.niigata.jp":1,"yaita.tochigi.jp":1,"yaizu.shizuoka.jp":1,"yakage.okayama.jp":1,"yakumo.hokkaido.jp":1,"yakumo.shimane.jp":1,"yali.mythic-beasts.com":1,"yalta.ua":1,"yamada.fukuoka.jp":1,"yamada.iwate.jp":1,"yamada.toyama.jp":1,"yamaga.kumamoto.jp":1,"yamagata.gifu.jp":1,"yamagata.ibaraki.jp":1,"yamagata.jp":1,"yamagata.nagano.jp":1,"yamagata.yamagata.jp":1,"yamaguchi.jp":1,"yamakita.kanagawa.jp":1,"yamamoto.miyagi.jp":1,"yamanakako.yamanashi.jp":1,"yamanashi.jp":1,"yamanashi.yamanashi.jp":1,"yamanobe.yamagata.jp":1,"yamanouchi.nagano.jp":1,"yamashina.kyoto.jp":1,"yamato.fukushima.jp":1,"yamato.kanagawa.jp":1,"yamato.kumamoto.jp":1,"yamatokoriyama.nara.jp":1,"yamatotakada.nara.jp":1,"yamatsuri.fukushima.jp":1,"yamazoe.nara.jp":1,"yame.fukuoka.jp":1,"yanagawa.fukuoka.jp":1,"yanaizu.fukushima.jp":1,"yandexcloud.net":1,"yao.osaka.jp":1,"yaotsu.gifu.jp":1,"yasaka.nagano.jp":1,"yashio.saitama.jp":1,"yashiro.hyogo.jp":1,"yasu.shiga.jp":1,"yasuda.kochi.jp":1,"yasugi.shimane.jp":1,"yasuoka.nagano.jp":1,"yatomi.aichi.jp":1,"yatsuka.shimane.jp":1,"yatsushiro.kumamoto.jp":1,"yawara.ibaraki.jp":1,"yawata.kyoto.jp":1,"yawatahama.ehime.jp":1,"yazu.tottori.jp":1,"ybo.faith":1,"ybo.party":1,"ybo.review":1,"ybo.science":1,"ybo.trade":1,"ye":2,"yk.ca":1,"yn.cn":1,"yoichi.hokkaido.jp":1,"yoita.niigata.jp":1,"yoka.hyogo.jp":1,"yokaichiba.chiba.jp":1,"yokawa.hyogo.jp":1,"yokkaichi.mie.jp":1,"yokohama.jp":2,"yokoshibahikari.chiba.jp":1,"yokosuka.kanagawa.jp":1,"yokote.akita.jp":1,"yokoze.saitama.jp":1,"yolasite.com":1,"yombo.me":1,"yomitan.okinawa.jp":1,"yonabaru.okinawa.jp":1,"yonago.tottori.jp":1,"yonaguni.okinawa.jp":1,"yonezawa.yamagata.jp":1,"yono.saitama.jp":1,"yorii.saitama.jp":1,"york.museum":1,"yorkshire.museum":1,"yoro.gifu.jp":1,"yosemite.museum":1,"yoshida.saitama.jp":1,"yoshida.shizuoka.jp":1,"yoshikawa.saitama.jp":1,"yoshimi.saitama.jp":1,"yoshino.nara.jp":1,"yoshinogari.saga.jp":1,"yoshioka.gunma.jp":1,"yotsukaido.chiba.jp":1,"youth.museum":1,"yuasa.wakayama.jp":1,"yufu.oita.jp":1,"yugawa.fukushima.jp":1,"yugawara.kanagawa.jp":1,"yuki.ibaraki.jp":1,"yukuhashi.fukuoka.jp":1,"yura.wakayama.jp":1,"yurihonjo.akita.jp":1,"yusuhara.kochi.jp":1,"yusui.kagoshima.jp":1,"yuu.yamaguchi.jp":1,"yuza.yamagata.jp":1,"yuzawa.niigata.jp":1,"z.bg":1,"z.se":1,"za.bz":1,"za.com":1,"za.net":1,"za.org":1,"zachpomor.pl":1,"zagan.pl":1,"zakopane.pl":1,"zama.kanagawa.jp":1,"zamami.okinawa.jp":1,"zao.miyagi.jp":1,"zaporizhzhe.ua":1,"zaporizhzhia.ua":1,"zapto.org":1,"zapto.xyz":1,"zarow.pl":1,"zentsuji.kagawa.jp":1,"zgora.pl":1,"zgorzelec.pl":1,"zhitomir.ua":1,"zhytomyr.ua":1,"zj.cn":1,"zlg.br":1,"zoological.museum":1,"zoology.museum":1,"zp.gov.pl":1,"zp.ua":1,"zt.ua":1,"zushi.kanagawa.jp":1}');

/***/ })

/******/ 	});
/************************************************************************/
/******/ 	// The module cache
/******/ 	var __webpack_module_cache__ = {};
/******/ 	
/******/ 	// The require function
/******/ 	function __webpack_require__(moduleId) {
/******/ 		// Check if module is in cache
/******/ 		var cachedModule = __webpack_module_cache__[moduleId];
/******/ 		if (cachedModule !== undefined) {
/******/ 			return cachedModule.exports;
/******/ 		}
/******/ 		// Create a new module (and put it into the cache)
/******/ 		var module = __webpack_module_cache__[moduleId] = {
/******/ 			// no module.id needed
/******/ 			// no module.loaded needed
/******/ 			exports: {}
/******/ 		};
/******/ 	
/******/ 		// Execute the module function
/******/ 		__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/ 	
/******/ 		// Return the exports of the module
/******/ 		return module.exports;
/******/ 	}
/******/ 	
/************************************************************************/
/******/ 	/* webpack/runtime/compat get default export */
/******/ 	(() => {
/******/ 		// getDefaultExport function for compatibility with non-harmony modules
/******/ 		__webpack_require__.n = (module) => {
/******/ 			var getter = module && module.__esModule ?
/******/ 				() => (module['default']) :
/******/ 				() => (module);
/******/ 			__webpack_require__.d(getter, { a: getter });
/******/ 			return getter;
/******/ 		};
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/define property getters */
/******/ 	(() => {
/******/ 		// define getter functions for harmony exports
/******/ 		__webpack_require__.d = (exports, definition) => {
/******/ 			for(var key in definition) {
/******/ 				if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
/******/ 					Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
/******/ 				}
/******/ 			}
/******/ 		};
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/hasOwnProperty shorthand */
/******/ 	(() => {
/******/ 		__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/make namespace object */
/******/ 	(() => {
/******/ 		// define __esModule on exports
/******/ 		__webpack_require__.r = (exports) => {
/******/ 			if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
/******/ 				Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
/******/ 			}
/******/ 			Object.defineProperty(exports, '__esModule', { value: true });
/******/ 		};
/******/ 	})();
/******/ 	
/************************************************************************/
/******/ 	
/******/ 	// startup
/******/ 	// Load entry module and return exports
/******/ 	// This entry module is referenced by other modules so it can't be inlined
/******/ 	__webpack_require__(2630);
/******/ 	__webpack_require__(4047);
/******/ 	__webpack_require__(2019);
/******/ 	__webpack_require__(8910);
/******/ 	__webpack_require__(6907);
/******/ 	__webpack_require__(7434);
/******/ 	__webpack_require__(2413);
/******/ 	__webpack_require__(4448);
/******/ 	__webpack_require__(2508);
/******/ 	__webpack_require__(7877);
/******/ 	__webpack_require__(5829);
/******/ 	__webpack_require__(4590);
/******/ 	__webpack_require__(9192);
/******/ 	__webpack_require__(922);
/******/ 	__webpack_require__(1021);
/******/ 	__webpack_require__(1483);
/******/ 	__webpack_require__(8762);
/******/ 	__webpack_require__(1306);
/******/ 	__webpack_require__(3032);
/******/ 	__webpack_require__(6130);
/******/ 	__webpack_require__(7641);
/******/ 	var __webpack_exports__ = __webpack_require__(41);
/******/ 	
/******/ })()
;