PageSourceSearch

https://bingeread.app/reading/assets/index-CtEGXUJt.js

js bingeread.app collected 2026-10-02 01:12:47 UTC 184,505 bytes, 38 lines download raw bytes

1(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))i(r);new MutationObserver(r=>{for(const o of r)if(o.type==="childList")for(const s of o.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&i(s)}).observe(document,{childList:!0,subtree:!0});function n(r){const o={};return r.integrity&&(o.integrity=r.integrity),r.referrerPolicy&&(o.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?o.credentials="include":r.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function i(r){if(r.ep)return;r.ep=!0;const o=n(r);fetch(r.href,o)}})();const ln={};function Wr(e){let t=ln[e];if(t)return t;t=ln[e]=[];for(let n=0;n<128;n++){const i=String.fromCharCode(n);t.push(i)}for(let n=0;n<e.length;n++){const i=e.charCodeAt(n);t[i]="%"+("0"+i.toString(16).toUpperCase()).slice(-2)}return t}function Ee(e,t){typeof t!="string"&&(t=Ee.defaultChars);const n=Wr(t);return e.replace(/(%[a-f0-9]{2})+/gi,function(i){let r="";for(let o=0,s=i.length;o<s;o+=3){const A=parseInt(i.slice(o+1,o+3),16);if(A<128){r+=n[A];continue}if((A&224)===192&&o+3<s){const a=parseInt(i.slice(o+4,o+6),16);if((a&192)===128){const l=A<<6&1984|a&63;l<128?r+="��":r+=String.fromCharCode(l),o+=3;continue}}if((A&240)===224&&o+6<s){const a=parseInt(i.slice(o+4,o+6),16),l=parseInt(i.slice(o+7,o+9),16);if((a&192)===128&&(l&192)===128){const u=A<<12&61440|a<<6&4032|l&63;u<2048||u>=55296&&u<=57343?r+="���":r+=String.fromCharCode(u),o+=6;continue}}if((A&248)===240&&o+9<s){const a=parseInt(i.slice(o+4,o+6),16),l=parseInt(i.slice(o+7,o+9),16),u=parseInt(i.slice(o+10,o+12),16);if((a&192)===128&&(l&192)===128&&(u&192)===128){let d=A<<18&1835008|a<<12&258048|l<<6&4032|u&63;d<65536||d>1114111?r+="����":(d-=65536,r+=String.fromCharCode(55296+(d>>10),56320+(d&1023))),o+=9;continue}}r+="�"}return r})}Ee.defaultChars=";/?:@&=+$,#";Ee.componentChars="";const cn={};function Mr(e){let t=cn[e];if(t)return t;t=cn[e]=[];for(let n=0;n<128;n++){const i=String.fromCharCode(n);/^[0-9a-z]$/i.test(i)?t.push(i):t.push("%"+("0"+n.toString(16).toUpperCase()).slice(-2))}for(let n=0;n<e.length;n++)t[e.charCodeAt(n)]=e[n];return t}function $e(e,t,n){typeof t!="string"&&(n=t,t=$e.defaultChars),typeof n>"u"&&(n=!0);const i=Mr(t);let r="";for(let o=0,s=e.length;o<s;o++){const A=e.charCodeAt(o);if(n&&A===37&&o+2<s&&/^[0-9a-f]{2}$/i.test(e.slice(o+1,o+3))){r+=e.slice(o,o+3),o+=2;continue}if(A<128){r+=i[A];continue}if(A>=55296&&A<=57343){if(A>=55296&&A<=56319&&o+1<s){const a=e.charCodeAt(o+1);if(a>=56320&&a<=57343){r+=encodeURIComponent(e[o]+e[o+1]),o++;continue}}r+="%EF%BF%BD";continue}r+=encodeURIComponent(e[o])}return r}$e.defaultChars=";/?:@&=+$,-_.!~*'()#";$e.componentChars="-_.!~*'()";function Zt(e){let t="";return t+=e.protocol||"",t+=e.slashes?"//":"",t+=e.auth?e.auth+"@":"",e.hostname&&e.hostname.indexOf(":")!==-1?t+="["+e.hostname+"]":t+=e.hostname||"",t+=e.port?":"+e.port:"",t+=e.pathname||"",t+=e.search||"",t+=e.hash||"",t}function at(){this.protocol=null,this.slashes=null,this.auth=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.pathname=null}const Jr=/^([a-z0-9.+-]+:)/i,Zr=/:[0-9]*$/,Hr=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,Nr=["<",">",'"',"`"," ","\r",`
2`,"	"],Ur=["{","}","|","\\","^","`"].concat(Nr),Lr=["'"].concat(Ur),un=["%","/","?",";","#"].concat(Lr),dn=["/","?","#"],Or=255,hn=/^[+a-z0-9A-Z_-]{0,63}$/,$r=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,gn={javascript:!0,"javascript:":!0},fn={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};function Ht(e,t){if(e&&e instanceof at)return e;const n=new at;return n.parse(e,t),n}at.prototype.parse=function(e,t){let n,i,r,o=e;if(o=o.trim(),!t&&e.split("#").length===1){const l=Hr.exec(o);if(l)return this.pathname=l[1],l[2]&&(this.search=l[2]),this}let s=Jr.exec(o);if(s&&(s=s[0],n=s.toLowerCase(),this.protocol=s,o=o.substr(s.length)),(t||s||o.match(/^\/\/[^@\/]+@[^@\/]+/))&&(r=o.substr(0,2)==="//",r&&!(s&&gn[s])&&(o=o.substr(2),this.slashes=!0)),!gn[s]&&(r||s&&!fn[s])){let l=-1;for(let c=0;c<dn.length;c++)i=o.indexOf(dn[c]),i!==-1&&(l===-1||i<l)&&(l=i);let u,d;l===-1?d=o.lastIndexOf("@"):d=o.lastIndexOf("@",l),d!==-1&&(u=o.slice(0,d),o=o.slice(d+1),this.auth=u),l=-1;for(let c=0;c<un.length;c++)i=o.indexOf(un[c]),i!==-1&&(l===-1||i<l)&&(l=i);l===-1&&(l=o.length),o[l-1]===":"&&l--;const g=o.slice(0,l);o=o.slice(l),this.parseHost(g),this.hostname=this.hostname||"";const h=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!h){const c=this.hostname.split(/\./);for(let b=0,m=c.length;b<m;b++){const D=c[b];if(D&&!D.match(hn)){let C="";for(let k=0,p=D.length;k<p;
2k++)D.charCodeAt(k)>127?C+="x":C+=D[k];if(!C.match(hn)){const k=c.slice(0,b),p=c.slice(b+1),f=D.match($r);f&&(k.push(f[1]),p.unshift(f[2])),p.length&&(o=p.join(".")+o),this.hostname=k.join(".");break}}}}this.hostname.length>Or&&(this.hostname=""),h&&(this.hostname=this.hostname.substr(1,this.hostname.length-2))}const A=o.indexOf("#");A!==-1&&(this.hash=o.substr(A),o=o.slice(0,A));const a=o.indexOf("?");return a!==-1&&(this.search=o.substr(a),o=o.slice(0,a)),o&&(this.pathname=o),fn[n]&&this.hostname&&!this.pathname&&(this.pathname=""),this};at.prototype.parseHost=function(e){let t=Zr.exec(e);t&&(t=t[0],t!==":"&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)};const Tr=Object.freeze(Object.defineProperty({__proto__:null,decode:Ee,encode:$e,format:Zt,parse:Ht},Symbol.toStringTag,{value:"Module"})),Zn=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,Hn=/[\0-\x1F\x7F-\x9F]/,Pr=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u0890\u0891\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD80D[\uDC30-\uDC3F]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/,$t=/[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B4E\u1B4F\u1B5A-\u1B60\u1B7D-\u1B7F\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDD6E\uDEAD\uDED0\uDF55-\uDF59\uDF86-\uDF89]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9\uDFD4\uDFD5\uDFD7\uDFD8]|\uD805[\uDC4B-\uDC4F\uDC5A\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDEB9\uDF3C-\uDF3E]|\uD806[\uDC3B\uDD44-\uDD46\uDDE2\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2\uDF00-\uDF09\uDFE1]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8\uDF43-\uDF4F\uDFFF]|\uD809[\uDC70-\uDC74]|\uD80B[\uDFF1\uDFF2]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDD6D-\uDD6F\uDE97-\uDE9A\uDFE2]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD839\uDDFF|\uD83A[\uDD5E\uDD5F]/,Nn=/[\$\+<->\^`\|~\xA2-\xA6\xA8\xA9\xAC\xAE-\xB1\xB4\xB8\xD7\xF7\u02C2-\u02C5\u02D2-\u02DF\u02E5-\u02EB\u02ED\u02EF-\u02FF\u0375\u0384\u0385\u03F6\u0482\u058D-\u058F\u0606-\u0608\u060B\u060E\u060F\u06DE\u06E9\u06FD\u06FE\u07F6\u07FE\u07FF\u0888\u09F2\u09F3\u09FA\u09FB\u0AF1\u0B70\u0BF3-\u0BFA\u0C7F\u0D4F\u0D79\u0E3F\u0F01-\u0F03\u0F13\u0F15-\u0F17\u0F1A-\u0F1F\u0F34\u0F36\u0F38\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE\u0FCF\u0FD5-\u0FD8\u109E\u109F\u1390-\u1399\u166D\u17DB\u1940\u19DE-\u19FF\u1B61-\u1B6A\u1B74-\u1B7C\u1FBD\u1FBF-\u1FC1\u1FCD-\u1FCF\u1FDD-\u1FDF\u1FED-\u1FEF\u1FFD\u1FFE\u2044\u2052\u207A-\u207C\u208A-\u208C\u20A0-\u20C1\u2100\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211E-\u2123\u2125\u2127\u2129\u212E\u213A\u213B\u2140-\u2144\u214A-\u214D\u214F\u218A\u218B\u2190-\u2307\u230C-\u2328\u232B-\u2429\u2440-\u244A\u249C-\u24E9\u2500-\u2767\u2794-\u27C4\u27C7-\u27E5\u27F0-\u2982\u2999-\u29D7\u29DC-\u29FB\u29FE-\u2B73\u2B76-\u2BFF\u2CE5-\u2CEA\u2E50\u2E51\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3004\u3012\u3013\u3020\u3036\u3037\u303E\u303F\u309B\u309C\u3190\u3191\u3196-\u319F\u31C0-\u31E5\u31EF\u3200-\u321E\u322A-\u3247\u3250\u3260-\u327F\u328A-\u32B0\u32C0-\u33FF\u4DC0-\u4DFF\uA490-\uA4C6\uA700-\uA716\uA720\uA721\uA789\uA78A\uA828-\uA82B\uA836-\uA839\uAA77-\uAA79\uAB5B\uAB6A\uAB6B\uFB29\uFBB2-\uFBD2\uFD40-\uFD4F\uFD90\uFD91\uFDC8-\uFDCF\uFDFC-\uFDFF\uFE62\uFE64-\uFE66\uFE69\uFF04\uFF0B\uFF1C-\uFF1E\uFF3E\uFF40\uFF5C\uFF5E\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFFC\uFFFD]|\uD800[\uDD37-\uDD3F\uDD79-\uDD89\uDD8C-\uDD8E\uDD90-\uDD9C\uDDA0\uDDD0-\uDDFC]|\uD802[\uDC77\uDC78\uDEC8]|\uD803[\uDD8E\uDD8F\uDED1-\uDED8]|\uD805\uD
2F3F|\uD807[\uDFD5-\uDFF1]|\uD81A[\uDF3C-\uDF3F\uDF45]|\uD82F\uDC9C|\uD833[\uDC00-\uDCEF\uDCFA-\uDCFC\uDD00-\uDEB3\uDEBA-\uDED0\uDEE0-\uDEF0\uDF50-\uDFC3]|\uD834[\uDC00-\uDCF5\uDD00-\uDD26\uDD29-\uDD64\uDD6A-\uDD6C\uDD83\uDD84\uDD8C-\uDDA9\uDDAE-\uDDEA\uDE00-\uDE41\uDE45\uDF00-\uDF56]|\uD835[\uDEC1\uDEDB\uDEFB\uDF15\uDF35\uDF4F\uDF6F\uDF89\uDFA9\uDFC3]|\uD836[\uDC00-\uDDFF\uDE37-\uDE3A\uDE6D-\uDE74\uDE76-\uDE83\uDE85\uDE86]|\uD838[\uDD4F\uDEFF]|\uD83B[\uDCAC\uDCB0\uDD2E\uDEF0\uDEF1]|\uD83C[\uDC00-\uDC2B\uDC30-\uDC93\uDCA0-\uDCAE\uDCB1-\uDCBF\uDCC1-\uDCCF\uDCD1-\uDCF5\uDD0D-\uDDAD\uDDE6-\uDE02\uDE10-\uDE3B\uDE40-\uDE48\uDE50\uDE51\uDE60-\uDE65\uDF00-\uDFFF]|\uD83D[\uDC00-\uDED8\uDEDC-\uDEEC\uDEF0-\uDEFC\uDF00-\uDFD9\uDFE0-\uDFEB\uDFF0]|\uD83E[\uDC00-\uDC0B\uDC10-\uDC47\uDC50-\uDC59\uDC60-\uDC87\uDC90-\uDCAD\uDCB0-\uDCBB\uDCC0\uDCC1\uDCD0-\uDCD8\uDD00-\uDE57\uDE60-\uDE6D\uDE70-\uDE7C\uDE80-\uDE8A\uDE8E-\uDEC6\uDEC8\uDECD-\uDEDC\uDEDF-\uDEEA\uDEEF-\uDEF8\uDF00-\uDF92\uDF94-\uDFEF\uDFFA]/,Un=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/,zr=Object.freeze(Object.defineProperty({__proto__:null,Any:Zn,Cc:Hn,Cf:Pr,P:$t,S:Nn,Z:Un},Symbol.toStringTag,{value:"Module"})),jr=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]);function Xr(e){return e>=55296&&e<=57343||e>1114111?65533:jr.get(e)??e}function qr(e){const t=atob(e),n=t.length&-2,i=new Uint16Array(n/2);for(let r=0,o=0;r<n;r+=2){const s=t.charCodeAt(r),A=t.charCodeAt(r+1);i[o++]=s|A<<8}return i}const Vr=qr
vendor: 32,205 bytes, line 2
2("QR08ALkAAgH6AYsDNQR2BO0EPgXZBQEGLAbdBxMISQrvCmQLfQurDKQNLw4fD4YPpA+6D/IPAAAAAAAAAAAAAAAAKhBMEY8TmxUWF2EYLBkxGuAa3RsJHDscWR8YIC8jSCSIJcMl6ie3Ku8rEC0CLjoupS7kLgAIRU1hYmNmZ2xtbm9wcnN0dVQAWgBeAGUAaQBzAHcAfgCBAIQAhwCSAJoAoACsALMAbABpAGcAO4DGAMZAUAA7gCYAJkBjAHUAdABlADuAwQDBQHIiZXZlAAJhAAFpeW0AcgByAGMAO4DCAMJAEGRyAADgNdgE3XIAYQB2AGUAO4DAAMBA8CFoYZFj4SFjcgBhZAAAoFMqAAFncIsAjgBvAG4ABGFmAADgNdg43fAlbHlGdW5jdGlvbgCgYSBpAG4AZwA7gMUAxUAAAWNzpACoAHIAAOA12Jzc6SFnbgCgVCJpAGwAZABlADuAwwDDQG0AbAA7gMQAxEAABGFjZWZvcnN1xQDYANoA7QDxAPYA+QD8AAABY3LJAM8AayNzbGFzaAAAoBYidgHTANUAAKDnKmUAZAAAoAYjeQARZIABY3J0AOAA5QDrAGEidXNlAACgNSLuI291bGxpcwCgLCFhAJJjcgAA4DXYBd1wAGYAAOA12Dnd5SF2ZdhiYwDyAOoAbSJwZXEAAKBOIgAHSE9hY2RlZmhpbG9yc3UXARoBHwE6AVIBVQFiAWQBZgGCAakB6QHtAfIBYwB5ACdkUABZADuAqQCpQIABY3B5ACUBKAE1AfUhdGUGYWmg0iJ0KGFsRGlmZmVyZW50aWFsRAAAoEUhbCJleXMAAKAt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GTH",e[e.FLAG13=8192]="FLAG13",e[e.BRANCH_LENGTH=8064]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(J||(J={}));var K;
2(function(e){e[e.NUM=35]="NUM",e[e.SEMI=59]="SEMI",e[e.EQUALS=61]="EQUALS",e[e.ZERO=48]="ZERO",e[e.NINE=57]="NINE",e[e.LOWER_A=97]="LOWER_A",e[e.LOWER_F=102]="LOWER_F",e[e.LOWER_X=120]="LOWER_X",e[e.LOWER_Z=122]="LOWER_Z",e[e.UPPER_A=65]="UPPER_A",e[e.UPPER_F=70]="UPPER_F",e[e.UPPER_Z=90]="UPPER_Z"})(K||(K={}));const pn=32;function Nt(e){return e>=K.ZERO&&e<=K.NINE}function ei(e){return e>=K.UPPER_A&&e<=K.UPPER_F||e>=K.LOWER_A&&e<=K.LOWER_F}function ti(e){return e>=K.UPPER_A&&e<=K.UPPER_Z||e>=K.LOWER_A&&e<=K.LOWER_Z||Nt(e)}function ni(e){return e===K.EQUALS||ti(e)}var G;(function(e){e[e.EntityStart=0]="EntityStart",e[e.NumericStart=1]="NumericStart",e[e.NumericDecimal=2]="NumericDecimal",e[e.NumericHex=3]="NumericHex",e[e.NamedEntity=4]="NamedEntity"})(G||(G={}));var pe;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(pe||(pe={}));class ri{decodeTree;emitCodePoint;errors;constructor(t,n,i){this.decodeTree=t,this.emitCodePoint=n,this.errors=i}state=G.EntityStart;consumed=1;result=0;treeIndex=0;excess=1;decodeMode=pe.Strict;runConsumed=0;startEntity(t){this.decodeMode=t,this.state=G.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1,this.runConsumed=0}write(t,n){switch(this.state){case G.EntityStart:return t.charCodeAt(n)===K.NUM?(this.state=G.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=G.NamedEntity,this.stateNamedEntity(t,n));case G.NumericStart:return this.stateNumericStart(t,n);case G.NumericDecimal:return this.stateNumericDecimal(t,n);case G.NumericHex:return this.stateNumericHex(t,n);case G.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|pn)===K.LOWER_X?(this.state=G.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=G.NumericDecimal,this.stateNumericDecimal(t,n))}stateNumericHex(t,n){for(;n<t.length;){const i=t.charCodeAt(n);if(Nt(i)||ei(i)){const r=i<=K.NINE?i-K.ZERO:(i|pn)-K.LOWER_A+10;this.result=this.result*16+r,this.consumed++,n++}else return this.emitNumericEntity(i,3)}return-1}stateNumericDecimal(t,n){for(;n<t.length;){const i=t.charCodeAt(n);if(Nt(i))this.result=this.result*10+(i-K.ZERO),this.consumed++,n++;else return this.emitNumericEntity(i,2)}return-1}emitNumericEntity(t,n){if(this.consumed<=n)return this.errors?.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(t===K.SEMI)this.consumed+=1;else if(this.decodeMode===pe.Strict)return 0;return this.emitCodePoint(Xr(this.result),this.consumed),this.errors&&(t!==K.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:i}=this;let r=i[this.treeIndex],o=(r&J.VALUE_LENGTH)>>14;for(;n<t.length;){if(o===0&&(r&J.FLAG13)!==0){const A=(r&J.BRANCH_LENGTH)>>7;if(this.runConsumed===0){const a=r&J.JUMP_TABLE;if(t.charCodeAt(n)!==a)return this.result===0?0:this.emitNotTerminatedNamedEntity();n++,this.excess++,this.runConsumed++}for(;this.runConsumed<A;){if(n>=t.length)return-1;const a=this.runConsumed-1,l=i[this.treeIndex+1+(a>>1)],u=a%2===0?l&255:l>>8&255;if(t.charCodeAt(n)!==u)return this.runConsumed=0,this.result===0?0:this.emitNotTerminatedNamedEntity();n++,this.excess++,this.runConsumed++}this.runConsumed=0,this.treeIndex+=1+(A>>1),r=i[this.treeIndex],o=(r&J.VALUE_LENGTH)>>14}if(n>=t.length)break;const s=t.charCodeAt(n);if(s===K.SEMI&&o!==0&&(r&J.FLAG13)!==0)return this.emitNamedEntityData(this.treeIndex,o,this.consumed+this.excess);if(this.treeIndex=oi(i,r,this.treeIndex+Math.max(1,o),s),this.treeIndex<0)return this.result===0||this.decodeMode===pe.Attribute&&(o===0||ni(s))?0:this.emitNotTerminatedNamedEntity();if(r=i[this.treeIndex],o=(r&J.VALUE_LENGTH)>>14,o!==0){if(s===K.SEMI)return this.emitNamedEntityData(this.treeIndex,o,this.consumed+this.excess);this.decodeMode!==pe.Strict&&(r&J.FLAG13)===0&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}n++,this.excess++}return-1}emitNotTerminatedNamedEntity(){const{result:t,decodeTree:n}=this,i=(n[t]&J.VALUE_LENGTH)>>14;return this.emitNamedEntityData(t,i,this.consumed),this.errors?.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,i){const{decodeTree:r}=this;return this.emitCodePoint(n===1?r[t]&~(J.VALUE_LENGTH|J.FLAG13):r[t+1],i),n===3&&this.emitCodePoint(r[t+2],i),i}end(){switch(this.state){case G.NamedEntity:return this.result!==0&&(this.decodeMode!==pe.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case G.NumericDecimal:return this.emitNumericEntity(0,2);case G.NumericHex:return this.emitNumericEntity(0,3);case G.NumericStart:return this.errors?.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case G.EntityStart:return 0}}}function ii(e){let t="";const n=new ri(e,i=>t+=String.fromCodePoint(i));return function(r,o){let s=0,A=0;for(;(A=r.indexOf("&",A))>=0;){t+=r.slice(s,A),n.startEntity(o);const l=n.write(r,A+1);if(l<0){s=A+n.end();break}s=A+l,A=l===0?s+1:s}const a=t+r.slice(s);return t="",a}}function oi(e,t,n,i){const r=(t&J.BRANCH_LENGTH)>>7,o=t&J.JUMP_TABLE;if(r===0)return o!==0&&i===o?n:-1;if(o){const l=i-o;return l<0||l>=r?-1:e[n+l]-1}const s=r+1>>1;let A=0,a=r-1;for(;A<=a;){const l=A+a>>>1,u=l>>
21,g=e[n+u]>>(l&1)*8&255;if(g<i)A=l+1;else if(g>i)a=l-1;else return e[n+s+l]}return-1}const si=ii(Vr);function Ln(e){return si(e,pe.Strict)}var Ai=class{src_Any=Zn.source;src_Cc=Hn.source;src_Z=Un.source;src_P=$t.source;src_ZPCc=[this.src_Z,this.src_P,this.src_Cc].join("|");src_ZCc=[this.src_Z,this.src_Cc].join("|");cache={};opts={maxLength:1e4,urlAuth:!1,schema_names:[]};constructor(e={}){this.opts={...this.opts,...e}}set(e={}){return this.opts={...this.opts,...e},this.cache={},this}escapeRE(e){return e.replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")}nestedPairRE(e,t,n=4){const i=this.escapeRE(e),r=this.escapeRE(t),o=`(?:(?!${this.src_ZCc}|${i}|${r}).)`;let s=`${i}${o}{0,1000}${r}`;for(let A=2;A<=n;A++)s=`${i}(?:${o}|${s}){0,1000}${r}`;return s}get_text_separators(){return this.cache.text_separators??=/[><\uff5c]/}get_pseudo_letter(){return this.cache.src_pseudo_letter??=new RegExp(`(?:(?!${this.get_text_separators().source}|${this.src_ZPCc})${this.src_Any})`)}get_ipv4_addr(){return this.cache.src_ip4??=new RegExp("(?:(?:25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])[.]){3}(?:25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])")}get_ipv6_addr(){const e="[0-9A-Fa-f]{1,4}",t=`(?:(?:${e}:${e})|${this.get_ipv4_addr().source})`;return this.cache.src_ip6_addr??=new RegExp(`(?:(?:${e}:){6}${t}|::(?:${e}:){5}${t}|(?:${e})?::(?:${e}:){4}${t}|(?:(?:${e}:){0,1}${e})?::(?:${e}:){3}${t}|(?:(?:${e}:){0,2}${e})?::(?:${e}:){2}${t}|(?:(?:${e}:){0,3}${e})?::${e}:${t}|(?:(?:${e}:){0,4}${e})?::${t}|(?:(?:${e}:){0,5}${e})?::${e}|(?:(?:${e}:){0,6}${e})?::)`)}get_ipv6_url_host(){return this.cache.src_ip6_host??=new RegExp(`\\[${this.get_ipv6_addr().source}\\]`)}get_ipv6_mail_host(){return this.cache.src_ipv6_mail_host??=new RegExp(`\\[IPv6:${this.get_ipv6_addr().source}\\]`)}get_auth(){return this.cache.src_auth??=new RegExp(`(?:(?:(?!${this.src_ZCc}|[@/\\[\\]()]).){1,50}@)?`)}get_port(){return this.cache.src_port??=new RegExp("(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?")}get_host_terminator(){return this.cache.src_host_terminator??=new RegExp(`(?=$|${this.get_text_separators().source}|${this.src_ZPCc})(?!${this.opts["---"]?"-(?!--)|":"-|"}_|:\\d|\\.-|\\.(?!$|${this.src_ZPCc}))`)}get_path_terminator(){return this.cache.src_path_terminator??=new RegExp(`${this.src_ZPCc}|${this.get_text_separators().source}`)}get_path(){return this.cache.src_path??=new RegExp(`(?:[/?#](?:${this.nestedPairRE("[","]")}|${this.nestedPairRE("(",")")}|${this.nestedPairRE("{","}")}|\\"(?:(?!${this.src_ZCc}|["]).){1,100}\\"|\\'(?:(?!${this.src_ZCc}|[']).){1,100}\\'|\\'(?=${this.get_pseudo_letter().source}|[-])|\\.{2,20}[:]?[a-zA-Z0-9%/&]|\\.(?!${this.src_ZCc}|[.]|$)|`+(this.opts["---"]?"\\-(?!--(?:[^-]|$))(?:-{0,19})|":"\\-{1,20}|")+`,(?!${this.src_ZCc}|$)|;(?!${this.src_ZCc}|$)|\\!{1,20}(?!${this.src_ZCc}|[!]|$)|\\?(?!${this.src_ZCc}|[?]|$)|`+this.get_path_extra().source+`[\\\\/:%@#&=_~*]|(?!${this.get_path_terminator().source}).){1,${this.opts.maxLength}}|\\/)?`)}get_mail_name(){return this.cache.src_mail_name??=new RegExp("[-!#$%&'*+/=?^_`{|}~a-zA-Z0-9](?:[-!#$%&'*+/=?^_`{|}~a-zA-Z0-9]|[.](?=[-!#$%&'*+/=?^_`{|}~a-zA-Z0-9])){0,63}")}get_xn(){return this.cache.src_xn??=new RegExp("xn--[a-z0-9\\-]{1,59}")}get_tld(){if(this.cache.tld)return this.cache.tld;const e=[...new Set(this.opts.tlds||[])].sort().reverse().join("|");return this.cache.tld=new RegExp(`${e||"$#none#$"}|${this.get_xn().source}`),this.cache.tld}get_domain_root(){return this.cache.src_domain_root??=new RegExp("(?:"+this.get_xn().source+`|${this.get_pseudo_letter().source}{1,63})`)}get_domain(){return this.cache.src_domain??=new RegExp("(?:"+this.get_xn().source+`|(?:${this.get_pseudo_letter().source})|(?:${this.get_pseudo_letter().source}(?:-|${this.get_pseudo_letter().source}){0,61}${this.get_pseudo_letter().source}))`)}get_url_host_port(){return this.cache.url_host_port??=new RegExp("(?:"+this.get_ipv6_url_host().source+`|(?:(?:(?:${this.get_domain().source})\\.){0,10}${this.get_domain().source}))`+this.get_port().source+this.get_host_terminator().source)}get_fuzzy_url_host_port(){return this.cache.fuzzy_url_host_port??=new RegExp("(?:"+(this.opts.fuzzyIP?this.get_ipv4_addr().source+"|":"")+`(?:(?:(?
2:${this.get_domain().source})\\.){1,10}(?:${this.get_tld().source})))`+this.get_host_terminator().source)}get_mail_host(){return this.cache.src_mail_host??=new RegExp("(?:"+this.get_ipv6_mail_host().source+`|(?:(?:(?:${this.get_domain().source})\\.){0,4}${this.get_domain().source}))`+this.get_host_terminator().source)}get_fuzzy_mail_host(){return this.cache.src_fuzzy_mail_host??=new RegExp("(?:"+this.get_ipv6_mail_host().source+`|(?:(?:(?:${this.get_domain().source})[.]){1,4}${this.get_domain_root().source}))`+this.get_host_terminator().source)}get_path_extra(){return this.cache.src_path_extra??=new RegExp("")}get_fuzzy_mail_host_search(){return this.cache.mail_fuzzy_host_search??=new RegExp(`@${this.get_fuzzy_mail_host().source}`,"ig")}get_fuzzy_link_search(){return this.cache.link_fuzzy_search??=new RegExp(`(^|(?![.:/\\-_@])(?:[$+<=>^\`||]|${this.src_ZPCc}))(?:(?![$+<=>^\`||])${this.get_fuzzy_url_host_port().source}${this.get_path().source})`,"ig")}get_http_validator(){return this.cache.http_validator??=new RegExp("\\/\\/"+(this.opts.urlAuth?this.get_auth().source:"")+this.get_url_host_port().source+this.get_path().source,"iy")}get_relative_proto_validator(){return this.cache.relative_proto_validator??=new RegExp((this.opts.urlAuth?this.get_auth().source:"")+`(?:localhost|${this.get_ipv6_url_host().source}|(?:(?:${this.get_domain().source})[.]){1,10}${this.get_domain_root().source})`+this.get_port().source+this.get_host_terminator().source+this.get_path().source,"iy")}get_mail_name_validator(){return this.cache.mail_name_validator??=new RegExp(`(?:^|${this.get_text_separators().source}|"|\\(|${this.src_ZCc})(${this.get_mail_name().source})$`)}get_mailto_validator(){return this.cache.mailto_validator??=new RegExp(`${this.get_mail_name().source}@${this.get_mail_host().source}`,"iy")}get_schema_names(){return this.cache.schema_names??=new RegExp((this.opts.schema_names||[]).map(e=>this.escapeRE(e)).join("|"))}get_schema_search(){return this.cache.schema_search??=new RegExp(`(^|(?!_)(?:[><|]|${this.src_ZPCc}))(${this.get_schema_names().source})`,"ig")}get_schema_at_start(){return this.cache.schema_at_start??=new RegExp(`^${this.get_schema_search().source}`,"i")}},xt={validate:(e,t,n)=>{const i=n.re.get_http_validator();i.lastIndex=t;const r=i.exec(e);return r?r[0].length:0},normalize:(e,t)=>t.normalize(e)},ai={"http:":xt,"https:":xt,"ftp:":xt,"//":{validate:function(e,t,n){const i=n.re.get_relative_proto_validator();i.lastIndex=t;const r=i.exec(e);return r?t>=3&&e[t-3]===":"||t>=3&&e[t-3]==="/"?0:r[0].length:0},normalize:(e,t)=>t.normalize(e)},"mailto:":{validate:function(e,t,n){const i=n.re.get_mailto_validator();i.lastIndex=t;const r=i.exec(e);return r?r[0].length:0},normalize:(e,t)=>t.normalize(e)}},li="a:cdefgilmnoqrstuwxz|b:abdefghijmnorstvwyz|c:acdfghiklmnoruvwxyz|d:ejkmoz|e:cegrstu|f:ijkmor|g:abdefghilmnpqrstuwy|h:kmnrtu|i:delmnoqrst|j:emop|k:eghimnprwyz|l:abcikrstuvy|m:acdeghklmnopqrstuvwxyz|n:acefgilopruz|o:m|p:aefghklmnrstwy|q:a|r:eosuw|s:abcdeghijklmnortuvxyz|t:cdfghjklmnortvwz|u:agksyz|v:aceginu|w:fs|y:et|z:amw",ci="biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|рф";function ui(){const e=ci.split("|");return li.split("|").forEach(t=>{const n=t.indexOf(":"),i=t.slice(0,n);for(const r of t.slice(n+1))e.push(i+r)}),e}var di={fuzzyLink:!1,fuzzyEmail:!0,fuzzyIP:!1,"---":!1,tlds:ui(),urlAuth:!1,maxLength:1e4},mn=class{schema;index;lastIndex;raw;text;url;constructor(e,t,n,i){const r=e.slice(n,i);this.schema=t.toLowerCase(),this.index=n,this.lastIndex=i,this.raw=r,this.text=r,this.url=r}},hi=class{__opts__;__schemas__;re;constructor(e={}){const{rebuilder:t,...n}=e;this.__opts__={...di,...n},this.__schemas__={...ai},this.re=t||new Ai,this.re.set({...this.__opts__,schema_names:Object.keys(this.__schemas__)})}add(e,t=null){if(!t)delete this.__schemas__[e];else{const n={normalize:(i,r)=>r.normalize(i),...t};this.__schemas__[e]=n}return this.re.set({...this.__opts__,schema_names:Object.keys(this.__schemas__)}),this}set(e={}){return this.__opts__={...this.__opts__,...e},this.re.set({...this.__opts__,schema_names:Object.keys(this.__schemas__)}),this}test(e){if(!e.length)return!1;let t,n;for(n=this.re.get_schema_search(),n.lastIndex=0;(t=n.exec(e))!==null;)if(this.testSchemaAt(e,t[2],n.lastIndex))return!0;
2if(this.__opts__.fuzzyLink&&this.__schemas__["http:"]&&(n=this.re.get_fuzzy_link_search(),n.lastIndex=0,n.exec(e)!==null))return!0;if(this.__opts__.fuzzyEmail&&this.__schemas__["mailto:"]&&e.indexOf("@")>=0){const i=this.re.get_fuzzy_mail_host_search(),r=this.re.get_mail_name_validator();for(i.lastIndex=0;(t=i.exec(e))!==null;){const o=e.slice(Math.max(0,t.index-65),t.index);if(r.test(o))return!0}}return!1}testSchemaAt(e,t,n){return this.__schemas__[t.toLowerCase()]?this.__schemas__[t.toLowerCase()].validate(e.slice(0,n+this.__opts__.maxLength),n,this):0}match(e){const t=[],n=this.re.get_schema_search();let i,r,o,s,A,a,l=!1,u=!1,d=!1,g=0;if(!e.length)return null;for(n.lastIndex=0,this.__opts__.fuzzyLink&&this.__schemas__["http:"]&&(i=this.re.get_fuzzy_link_search(),i.lastIndex=0),this.__opts__.fuzzyEmail&&this.__schemas__["mailto:"]&&(r=this.re.get_fuzzy_mail_host_search(),r.lastIndex=0,o=this.re.get_mail_name_validator());;){const h=Math.max(g-1,0);if(r&&o&&!d&&(!A||A.index<g))for(r.lastIndex<h&&(r.lastIndex=h);;){const C=r.exec(e);if(!C){d=!0,A=void 0;break}const k=o.exec(e.slice(Math.max(0,C.index-65),C.index));if(k){if(A={schema:"mailto:",index:C.index-k[1].length,lastIndex:C.index+C[0].length},A.index>=g)break;r.lastIndex<h&&(r.lastIndex=h)}}if(i&&!u&&(!s||s.index<g))for(i.lastIndex<h&&(i.lastIndex=h);;){const C=i.exec(e);if(!C){u=!0,s=void 0;break}if(s={schema:"",index:C.index+C[1].length,lastIndex:C.index+C[0].length},s.index>=g)break;i.lastIndex<h&&(i.lastIndex=h)}let c=A;(!c||s&&(s.index<c.index||s.index===c.index&&s.lastIndex>c.lastIndex))&&(c=s);let b;if(!l)for(;;){if(!a){n.lastIndex<h&&(n.lastIndex=h);const p=n.exec(e);if(!p){l=!0;break}a={schema:p[2],index:p.index+p[1].length,lastIndex:p.index+p[0].length}}if(a.index<g){a=void 0;continue}if(c&&a.index>c.index)break;const C=a;a=void 0;const k=this.testSchemaAt(e,C.schema,C.lastIndex);if(k){b={schema:C.schema,index:C.index,lastIndex:C.lastIndex+k};break}}let m=b;if((!m||A&&(A.index<m.index||A.index===m.index&&A.lastIndex>m.lastIndex))&&(m=A),(!m||s&&(s.index<m.index||s.index===m.index&&s.lastIndex>m.lastIndex))&&(m=s),!m)break;m===A?A=void 0:m===s&&(s=void 0);const D=new mn(e,m.schema,m.index,m.lastIndex);D.schema?this.__schemas__[D.schema].normalize(D,this):this.normalize(D),t.push(D),g=m.lastIndex}return t.length?t:null}matchAtStart(e){if(!e.length)return null;const t=this.re.get_schema_at_start().exec(e);if(!t)return null;const n=this.testSchemaAt(e,t[2],t[0].length);if(!n)return null;const i=new mn(e,t[2],t.index+t[1].length,t.index+t[0].length+n);return this.__schemas__[i.schema].normalize(i,this),i}tlds(e,t=!1){return e=Array.isArray(e)?e:[e],t?this.__opts__.tlds=this.__opts__.tlds.concat(e):this.__opts__.tlds=e,this.re.set({...this.__opts__,schema_names:Object.keys(this.__schemas__)}),this}normalize(e){e.schema||(e.url=`http://${e.url}`),e.schema==="mailto:"&&!/^mailto:/i.test(e.url)&&(e.url=`mailto:${e.url}`)}};const Be=2147483647,re=36,Tt=1,Ge=26,gi=38,fi=700,On=72,$n=128,Tn="-",pi=/^xn--/,mi=/[^\0-\x7F]/,Ci=/[\x2E\u3002\uFF0E\uFF61]/g,bi={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},St=re-Tt,ie=Math.floor,Qt=String.fromCharCode;function fe(e){throw new RangeError(bi[e])}function wi(e,t){const n=[];let i=e.length;for(;i--;)n[i]=t(e[i]);return n}function Pn(e,t){const n=e.split("@");let i="";n.length>1&&(i=n[0]+"@",e=n[1]),e=e.replace(Ci,".");const r=e.split("."),o=wi(r,t).join(".");return i+o}function zn(e){const t=[];let n=0;const i=e.length;for(;n<i;){const r=e.charCodeAt(n++);if(r>=55296&&r<=56319&&n<i){const o=e.charCodeAt(n++);(o&64512)==56320?t.push(((r&1023)<<10)+(o&1023)+65536):(t.push(r),n--)}else t.push(r)}return t}const ki=e=>String.fromCodePoint(...e),yi=function(e){return e>=48&&e<58?26+(e-48):e>=65&&e<91?e-65:e>=97&&e<123?e-97:re},Cn=function(e,t){return e+22+75*(e<26)-((t!=0)<<5)},jn=function(e,t,n){let i=0;for(e=n?ie(e/fi):e>>1,e+=ie(e/t);e>St*Ge>>1;i+=re)e=ie(e/St);return ie(i+(St+1)*e/(e+gi))},Xn=function(e){const t=[],n=e.length;let i=0,r=$n,o=On,s=e.lastIndexOf(Tn);s<0&&(s=0);for(let A=0;A<s;++A)e.charCodeAt(A)>=128&&fe("not-basic"),t.push(e.charCodeAt(A));for(let A=s>0?s+1:0;A<n;){const a=i;for(let u=1,d=re;;d+=re){A>=n&&fe("invalid-input");const g=yi(e.charCodeAt(A++));g>=re&&fe("invalid-input"),g>ie((Be-i)/u)&&fe("overflow"),i+=g*u;const h=d<=o?Tt:d>=o+Ge?Ge:d-o;if(g<h)break;const c=re-h;u>ie(Be/c)&&fe("overflow"),u*=c}const l=t.length+1;o=jn(i-a,l,a==0),ie(i/l)>Be-r&&fe("overflow"),r+=ie(i/l),i%=l,t.splice(i++,0,r)}return String.fromCodePoint(...t)},qn=function(e){const t=[];e=zn(e);const n=e.length;let i=$n,r=0,o=On;for(const a of e)a<128&&t.push(Qt(a));const s=t.length;let A=s;for(s&&t.push(Tn);A<n;){let a=Be;for(const u of e)u>=i&&u<a&&(a=u);const l=A+1;a-i>ie((Be-r)/l)&&fe("overflow"),r+=(a-i)*l,i=a;for(const u of e)if(u<i&&++r>Be&&fe("overflow"),u===i){let d=r;for(let g=re;;g+=re){const h=g<=o?Tt:g>=o+Ge?Ge:g-o;if(d<h)break;const c=d-h,b=re-h;t.push(Qt(Cn(h+c%b,0))),d=ie(c/b)}t.push(Qt(Cn(d,0))),o=jn(r,l,A===s),r=0,++A}++r,++i}return t.join("")},Ii=function(e){return Pn(e,function(t){return pi.test(t)?Xn(t.slice(4).toLowerCase()):t})},Di=function(e){return Pn(e,function(t){return mi.test(t)?"xn--"+qn(t):t})},bn={version:"2.3.1",ucs2:{decode:zn,encode:ki},decode:Xn,encode:qn,toASCII:Di,toUnicode:Ii};var wn=Object.defineProperty,Vn=(e,t)=>{let n={};for(var i in e)wn(n,i,{get:e[i],enumerable:!0});return wn(n,Symbol.toStringTag,{value:"Module"}),n},Fi=Vn({arrayReplaceAt:()=>tr,asciiTrim:()=>bt,callable:()=>er,escapeHtml:()=>be,escapeRE:()=>Yi,fromCodePoint:()=>We,isMdAsciiPunct:()=>
2Ze,isPunctChar:()=>rr,isPunctCharCode:()=>Je,isSpace:()=>S,isValidEntityCode:()=>Pt,isWhiteSpace:()=>Me,lib:()=>Gi,normalizeReference:()=>Ct,unescapeAll:()=>_e,unescapeMd:()=>_i});function er(e){const t=function(...n){return Reflect.construct(e,n,new.target&&new.target!==t?new.target:e)};return Object.defineProperty(t,"name",{value:e.name}),Object.setPrototypeOf(t,e),t.prototype=e.prototype,t}function tr(e,t,n){return[].concat(e.slice(0,t),n,e.slice(t+1))}function Pt(e){return!(e>=55296&&e<=57343||e>=64976&&e<=65007||(e&65535)===65535||(e&65535)===65534||e>=0&&e<=8||e===11||e>=14&&e<=31||e>=127&&e<=159||e>1114111)}function We(e){if(e>65535){e-=65536;const t=55296+(e>>10),n=56320+(e&1023);return String.fromCharCode(t,n)}return String.fromCharCode(e)}var nr=/\\([!"#$%&'()*+,\-./:;<=>?@[\\\]^_`{|}~])/g,Bi=new RegExp(`${nr.source}|${/&([a-z#][a-z0-9]{1,31});/gi.source}`,"gi"),vi=/^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))$/i;function Ei(e,t){if(t.charCodeAt(0)===35&&vi.test(t)){const i=t[1].toLowerCase()==="x"?parseInt(t.slice(2),16):parseInt(t.slice(1),10);return Pt(i)?We(i):e}const n=Ln(e);return n!==e?n:e}function _i(e){return e.indexOf("\\")<0?e:e.replace(nr,"$1")}function _e(e){return e.indexOf("\\")<0&&e.indexOf("&")<0?e:e.replace(Bi,function(t,n,i){return n||Ei(t,i)})}var xi=/[&<>"]/,Si=/[&<>"]/g,Qi={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;"};function Ki(e){return Qi[e]}function be(e){return xi.test(e)?e.replace(Si,Ki):e}var Ri=/[.?*+^$[\]\\(){}|-]/g;function Yi(e){return e.replace(Ri,"\\$&")}function S(e){switch(e){case 9:case 32:return!0}return!1}function Me(e){if(e>=8192&&e<=8202)return!0;switch(e){case 9:case 10:case 11:case 12:case 13:case 32:case 160:case 5760:case 8239:case 8287:case 12288:return!0}return!1}function rr(e){return $t.test(e)||Nn.test(e)}function Je(e){return rr(We(e))}function Ze(e){switch(e){case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:case 58:case 59:case 60:case 61:case 62:case 63:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 124:case 125:case 126:return!0;default:return!1}}function Ct(e){return e=e.trim().replace(/\s+/g," "),e.toLowerCase().toUpperCase()}function kn(e){return e===32||e===9||e===10||e===13}function bt(e){let t=0;for(;t<e.length&&kn(e.charCodeAt(t));t++);let n=e.length-1;for(;n>=t&&kn(e.charCodeAt(n));n--);return e.slice(t,n+1)}var Gi={mdurl:Tr,ucmicro:zr};function Wi(e,t,n){let i,r,o,s;const A=e.posMax,a=e.pos;for(e.pos=t+1,i=1;e.pos<A;){if(o=e.src.charCodeAt(e.pos),o===93&&(i--,i===0)){r=!0;break}if(s=e.pos,e.md.inline.skipToken(e),o===91){if(s===e.pos-1)i++;else if(n)return e.pos=a,-1}}let l=-1;return r&&(l=e.pos),e.pos=a,l}function Mi(e,t,n){let i,r=t;const o={ok:!1,pos:0,str:""};if(e.charCodeAt(r)===60){for(r++;r<n;){if(i=e.charCodeAt(r),i===10||i===60)return o;if(i===62)return o.pos=r+1,o.str=_e(e.slice(t+1,r)),o.ok=!0,o;if(i===92&&r+1<n){r+=2;continue}r++}return o}let s=0;for(;r<n&&(i=e.charCodeAt(r),!(i===32||i<32||i===127));){if(i===92&&r+1<n){if(e.charCodeAt(r+1)===32){r++;continue}r+=2;continue}if(i===40&&(s++,s>32))return o;if(i===41){if(s===0)break;s--}r++}return t===r||s!==0||(o.str=_e(e.slice(t,r)),o.pos=r,o.ok=!0),o}function Ji(e,t,n,i){let r,o=t;const s={ok:!1,can_continue:!1,pos:0,str:"",marker:0};if(i)s.str=i.str,s.marker=i.marker;else{if(o>=n)return s;let A=e.charCodeAt(o);if(A!==34&&A!==39&&A!==40)return s;t++,o++,A===40&&(A=41),s.marker=A}for(;o<n;){if(r=e.charCodeAt(o),r===s.marker)return s.pos=o+1,s.str+=_e(e.slice(t,o)),s.ok=!0,s;if(r===40&&s.marker===41)return s;r===92&&o+1<n&&o++,o++}return s.can_continue=!0,s.str+=_e(e.slice(t,o)),s}var Zi=Vn({parseLinkDestination:()=>Mi,parseLinkLabel:()=>Wi,parseLinkTitle:()=>Ji});function He(e){"@babel/helpers - typeof";return He=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},He(e)}function Hi(e,t){if(He(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var i=n.call(e,t);if(He(i)!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Ni(e){var t=Hi(e,"string");return He(t)=="symbol"?t:t+""}function F(e,t,n){return(t=Ni(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ie=class{constructor(e,t,n){F(this,"map",null),F(this,"level",0),F(this,"children",null),F(this,"content",""),F(this,"markup",""),F(this,"info",""),F(this,"block",!1),F(this,"hidden",!1),this.type=e,this.tag=t,this.attrs=null,this.nesting=n,this.meta=null}attrIndex(e){if(!this.attrs)return-1;const t=this.attrs;for(let n=0,i=t.length;n<i;n++)if(t[n][0]===e)return n;return-1}attrPush(e){this.attrs?this.attrs.push(e):this.attrs=[e]}attrSet(e,t){const n=this.attrIndex(e),i=[e,t];n<0?this.attrPush(i):this.attrs[n]=i}attrGet(e){const t=this.attrIndex(e);let n=null;return t>=0&&(n=this.attrs[t][1]),n}attrJoin(e,t){const n=this.attrIndex(e);n<0?this.attrPush([e,t]):this.attrs[n][1]=`${this.attrs[n][1]} ${t}`}},Ne=class{constructor(){F(this,"__rules__",[]),F(this,"__cache__",null)}__find__(e){for(let t=0;t<this.__rules__.length;t++)if(this.__rules__[t].name===e)return t;return-1}__compile__(){const e=new Set;this.__rules__.forEach(t=>{t.enabled&&t.alt.forEach(n=>
2{n&&e.add(n)})}),this.__cache__=Object.create(null),this.__cache__[""]=[],this.__rules__.forEach(t=>{t.enabled&&this.__cache__[""].push(t.fn)}),e.forEach(t=>{this.__cache__[t]=[],this.__rules__.forEach(n=>{n.enabled&&n.alt.indexOf(t)>=0&&this.__cache__[t].push(n.fn)})})}at(e,t,n={}){const i=this.__find__(e);if(i===-1)throw new Error(`Parser rule not found: ${e}`);this.__rules__[i].fn=t,this.__rules__[i].alt=n.alt||[],this.__cache__=null}before(e,t,n,i={}){const r=this.__find__(e);if(r===-1)throw new Error(`Parser rule not found: ${e}`);this.__rules__.splice(r,0,{name:t,enabled:!0,fn:n,alt:i.alt||[]}),this.__cache__=null}after(e,t,n,i={}){const r=this.__find__(e);if(r===-1)throw new Error(`Parser rule not found: ${e}`);this.__rules__.splice(r+1,0,{name:t,enabled:!0,fn:n,alt:i.alt||[]}),this.__cache__=null}push(e,t,n={}){this.__rules__.push({name:e,enabled:!0,fn:t,alt:n.alt||[]}),this.__cache__=null}enable(e,t=!1){Array.isArray(e)||(e=[e]);const n=[];return e.forEach(i=>{const r=this.__find__(i);if(r<0){if(t)return;throw new Error(`Rules manager: invalid rule name ${i}`)}this.__rules__[r].enabled=!0,n.push(i)}),this.__cache__=null,n}enableOnly(e,t=!1){Array.isArray(e)||(e=[e]),this.__rules__.forEach(n=>{n.enabled=!1}),this.enable(e,t)}disable(e,t=!1){Array.isArray(e)||(e=[e]);const n=[];return e.forEach(i=>{const r=this.__find__(i);if(r<0){if(t)return;throw new Error(`Rules manager: invalid rule name ${i}`)}this.__rules__[r].enabled=!1,n.push(i)}),this.__cache__=null,n}getRules(e){return this.__cache__||this.__compile__(),this.__cache__[e]||[]}},Ae={};Ae.code_inline=function(e,t,n,i,r){const o=e[t];return`<code${r.renderAttrs(o)}>${be(o.content)}</code>`};Ae.code_block=function(e,t,n,i,r){const o=e[t];return`<pre${r.renderAttrs(o)}><code>${be(e[t].content)}</code></pre>
3`};Ae.fence=function(e,t,n,i,r){const o=e[t],s=o.info?_e(o.info).trim():"";let A="",a="";if(s){const u=s.split(/(\s+)/g);A=u[0],a=u.slice(2).join("")}let l;if(n.highlight?l=n.highlight(o.content,A,a)||be(o.content):l=be(o.content),l.indexOf("<pre")===0)return l+`
4`;if(s){const u=o.attrIndex("class"),d=o.attrs?o.attrs.slice():[];u<0?d.push(["class",`${n.langPrefix}${A}`]):(d[u]=[d[u][0],d[u][1]],d[u][1]+=` ${n.langPrefix}${A}`);const g={attrs:d};return`<pre><code${r.renderAttrs(g)}>${l}</code></pre>
5`}return`<pre><code${r.renderAttrs(o)}>${l}</code></pre>
6`};Ae.image=function(e,t,n,i,r){const o=e[t];return o.attrs[o.attrIndex("alt")][1]=r.renderInlineAsText(o.children,n,i),r.renderToken(e,t,n)};Ae.hardbreak=function(e,t,n){return n.xhtmlOut?`<br />
7`:`<br>
8`};Ae.softbreak=function(e,t,n){return n.breaks?n.xhtmlOut?`<br />
9`:`<br>
10`:`
11`};Ae.text=function(e,t){return be(e[t].content)};Ae.html_block=function(e,t){return e[t].content};Ae.html_inline=function(e,t){return e[t].content};var ir=class{constructor(){F(this,"rules",Object.assign({},Ae))}renderAttrs(e){let t,n,i;if(!e.attrs)return"";for(i="",t=0,n=e.attrs.length;t<n;t++)i+=` ${be(e.attrs[t][0])}="${be(String(e.attrs[t][1]))}"`;return i}renderToken(e,t,n){const i=e[t];let r="";if(i.hidden)return"";let o=t-1;for(;o>=0&&e[o].hidden&&e[o].nesting===0;)o--;i.block&&i.nesting!==-1&&o>=0&&e[o].hidden&&e[o].nesting===-1&&(r+=`
12`),r+=(i.nesting===-1?"</":"<")+i.tag,r+=this.renderAttrs(i),i.nesting===0&&n.xhtmlOut&&(r+=" /");let s=!1;if(i.block&&(s=!0,i.nesting===1)){let A=t+1;for(;A<e.length&&e[A].hidden&&e[A].nesting===0;)A++;if(A<e.length){const a=e[A];(a.type==="inline"||a.hidden||a.nesting===-1&&a.tag===i.tag)&&(s=!1)}}return r+=s?`>
13`:">",r}renderInline(e,t,n){let i="";const r=this.rules;for(let o=0,s=e.length;o<s;o++){const A=e[o].type;typeof r[A]<"u"?i+=r[A](e,o,t,n,this):i+=this.renderToken(e,o,t)}return i}renderInlineAsText(e,t,n){let i="";for(let r=0,o=e.length;r<o;r++)switch(e[r].type){case"text":case"code_inline":i+=e[r].content;break;case"image":i+=this.renderInlineAsText(e[r].children,t,n);break;case"html_inline":case"html_block":i+=e[r].content;break;case"softbreak":case"hardbreak":i+=`
14`}return i}render(e,t,n){let i="";const r=this.rules;for(let o=0,s=e.length;o<s;o++){const A=e[o].type;A==="inline"?i+=this.renderInline(e[o].children,t,n):typeof r[A]<"u"?i+=r[A](e,o,t,n,this):i+=this.renderToken(e,o,t)}return i}},or=class{constructor(e,t,n){F(this,"tokens",[]),F(this,"inlineMode",!1),F(this,"Token",Ie),this.src=e,this.env=n,this.md=t}},Ui=/\r\n?|\n/g,Li=/\0/g;function Oi(e){let t;t=e.src.replace(Ui,`
15`),t=t.replace(Li,"�"),e.src=t}function $i(e){let t;e.inlineMode?(t=new e.Token("inline","",0),t.content=e.src,t.map=[0,1],t.children=[],e.tokens.push(t)):e.md.block.parse(e.src,e.md,e.env,e.tokens)}function Ti(e){const t=e.tokens;let n=0;for(let i=0;i<t.length;i++)t[i].type!=="reference_definition"&&(i!==n&&(t[n]=t[i]),n++);t.length!==n&&(t.length=n)}function Pi(e){const t=e.tokens;for(let n=0,i=t.length;n<i;n++){const r=t[n];r.type==="inline"&&e.md.inline.parse(r.content,e.md,e.env,r.children)}}function zi(e){return/^<a[>\s]/i.test(e)}function ji(e){return/^<\/a\s*>/i.test(e)}function Xi(e){const t=e.tokens;if(e.md.options.linkify)for(let n=0,i=t.length;n<i;n++){if(t[n].type!=="inline"||!e.md.linkify.test(t[n].content))continue;let r=t[n].children,o=0;for(let s=r.length-1;s>=0;s--){const A=r[s];if(A.type==="link_close"){for(s--;r[s].level!==A.level&&r[s].type!=="link_open";)s--;continue}if(A.type==="html_inline"&&(zi(A.content)&&o>0&&o--,ji(A.content)&&o++),!(o>0)&&A.type==="text"&&e.md.linkify.test(A.content)){const a=A.content;let l=e.md.linkify.match(a);const u=[];let d=A.level,g=0;l.length>0&&l[0].index===0&&s>0&&r[s-1].type==="text_special"&&(l=l.slice(1));for(let h=0;h<l.length;h++){const c=l[h].url,b=e.md.normalizeLink(c);if(!e.md.validateLink(b))continue;let m=l[h].text;l[h].schema?l[h].schema==="mailto:"&&!/^mailto:/i.test(m)?m=e.md.normalizeLinkText(`mailto:${m}`).replace(/^mailto:/,""):m=e.md.normalizeLinkText(m):m=e.md.normalizeLinkText(`http://${m}`).replace(/^http:\/\//,"");const D=l[h].index;if(D>g){const f=new e.Token("text","",0);f.content=a.slice(g,D),f.level=d,u.push(f)}const C=new e.Token("link_open","a",1);C.attrs=[["href",b]],C.level=d++,C.markup="linkify",C.info="auto",u.push(C);const k=new e.Token("text","",0);k.content=m,k.level=d,u.push(k);const p=new e.Token("link_close","a",-1);p.level=--d,p.markup="linkify",p.info="auto",u.push(p),g=l[h].lastIndex}if(g<a.length){const h=new e.Token("text","",0);h.content=a.slice(g),h.level=d,u.push(h)}t[n].children=r=tr(r,s,u)}}}}var sr=/\+-|\.\.|\?\?\?\?|!!!!|,,|--/,qi=/\((c|tm|r)\)/i,Vi=/\((c|tm|r)\)/gi,eo={c:"©",r:"®",tm:"™"};function to(e,t){return eo[t.toLowerCase()]}function no(e){let t=0;for(let n=e.length-1;n>=0;n--){const i=e[n];i.type==="text"&&!t&&(i.content=i.content.replace(Vi,to)),i.type==="link_open"&&i.info==="auto"&&t--,i.type==="link_close"&&i.info==="auto"&&t++}}function ro(e){let t=0;for(let n=e.length-1;n>=0;n--){const i=e[n];i.type==="text"&&!t&&sr.test(i.content)&&(i.content=i.content.replace(/\+-/g,"±").replace(/\.{2,}/g,"…").replace(/([?!])…/g,"$1..").replace(/([?!]){4,}/g,"$1$1$1").replace(/,{2,}/g,",").replace(/(^|[^-])---(?=[^-]|$)/gm,"$1—").replace(/(^|\s)--(?=\s|$)/gm,"$1–").replace(/(^|[^-\s])--(?=[^-\s]|$)/gm,"$1–")),i.type==="link_open"&&i.info==="auto"&&t--,i.type==="link_close"&&i.info==="auto"&&t++}}function io(e){let t;if(e.md.options.typographer)for(t=e.tokens.length-1;t>=0;t--)e.tokens[t].type==="inline"&&(qi.test(e.tokens[t].content)&&no(e.tokens[t].children),sr.test(e.tokens[t].content)&&ro(e.tokens[t].children))}var oo=/['"]/,yn=/['"]/g,In="’";function rt(e,t,n,i){e[t]||(e[t]=[]),e[t].push({pos:n,ch:i})}function so(e,t){let n="",i=0;t.sort((r,o)=>r.pos-o.pos);for(let r=0;r<t.length;r++){const o=t[r];n+=e.slice(i,o.pos)+o.ch,i=o.pos+1}return n+e.slice(i)}function Ao(e,t){let n;const i=[],r={};for(let o=0;o<e.length;o++){const s=e[o],A=e[o].level;for(n=i.length-1;n>=0&&!(i[n].level<=A);n--);if(i.length=n+1,s.type!=="text")continue;const a=s.content;let l=0;const u=a.length;e:for(;l<u;){yn.lastIndex=l;const d=yn.exec(a);if(!d)break;let g=!0,h=!0;l=d.index+1;const c=d[0]==="'";let b=32;if(d.index-1>
15=0)b=a.charCodeAt(d.index-1);else for(n=o-1;n>=0&&!(e[n].type==="softbreak"||e[n].type==="hardbreak");n--)if(e[n].content){b=e[n].content.charCodeAt(e[n].content.length-1);break}let m=32;if(l<u)m=a.charCodeAt(l);else for(n=o+1;n<e.length&&!(e[n].type==="softbreak"||e[n].type==="hardbreak");n++)if(e[n].content){m=e[n].content.charCodeAt(0);break}const D=Ze(b)||Je(b),C=Ze(m)||Je(m),k=Me(b),p=Me(m);if(p?g=!1:C&&(k||D||(g=!1)),k?h=!1:D&&(p||C||(h=!1)),m===34&&d[0]==='"'&&b>=48&&b<=57&&(h=g=!1),g&&h&&(g=D,h=C),!g&&!h){c&&rt(r,o,d.index,In);continue}if(h)for(n=i.length-1;n>=0;n--){let f=i[n];if(i[n].level<A)break;if(f.single===c&&i[n].level===A){f=i[n];let I,E;c?(I=t.md.options.quotes[2],E=t.md.options.quotes[3]):(I=t.md.options.quotes[0],E=t.md.options.quotes[1]),rt(r,o,d.index,E),rt(r,f.token,f.pos,I),i.length=n;continue e}}g?i.push({token:o,pos:d.index,single:c,level:A}):h&&c&&rt(r,o,d.index,In)}}Object.keys(r).forEach(function(o){const s=Number(o);e[s].content=so(e[s].content,r[o])})}function ao(e){if(e.md.options.typographer)for(let t=e.tokens.length-1;t>=0;t--)e.tokens[t].type!=="inline"||!oo.test(e.tokens[t].content)||Ao(e.tokens[t].children,e)}function lo(e){let t,n;const i=e.length;for(t=0;t<i;t++)e[t].type==="text_special"&&(e[t].type="text");for(t=n=0;t<i;t++)e[t].type==="text"&&t+1<i&&e[t+1].type==="text"?e[t+1].content=e[t].content+e[t+1].content:(t!==n&&(e[n]=e[t]),n++);t!==n&&(e.length=n)}function co(e){let t,n;const i=e.tokens,r=i.length;for(let o=0;o<r;o++){if(i[o].type!=="inline")continue;const s=i[o].children,A=s.length;for(t=0;t<A;t++)s[t].type==="text_special"&&(s[t].type="text"),s[t].children&&lo(s[t].children);for(t=n=0;t<A;t++)s[t].type==="text"&&t+1<A&&s[t+1].type==="text"?s[t+1].content=s[t].content+s[t+1].content:(t!==n&&(s[n]=s[t]),n++);t!==n&&(s.length=n)}}var Kt=[["normalize",Oi],["block",$i],["strip_references",Ti],["inline",Pi],["linkify",Xi],["replacements",io],["smartquotes",ao],["text_join",co]],Ar=class{constructor(){F(this,"ruler",new Ne),F(this,"State",or);for(let e=0;e<Kt.length;e++)this.ruler.push(Kt[e][0],Kt[e][1])}process(e){const t=this.ruler.getRules("");for(let n=0,i=t.length;n<i;n++)t[n](e)}},ar=class{constructor(e,t,n,i){F(this,"bMarks",[]),F(this,"eMarks",[]),F(this,"tShift",[]),F(this,"sCount",[]),F(this,"bsCount",[]),F(this,"blkIndent",0),F(this,"line",0),F(this,"lineMax",0),F(this,"tight",!1),F(this,"listIndent",-1),F(this,"parentType","root"),F(this,"level",0),F(this,"Token",Ie),this.src=e,this.md=t,this.env=n,this.tokens=i;const r=this.src;for(let o=0,s=0,A=0,a=0,l=r.length,u=!1;s<l;s++){const d=r.charCodeAt(s);if(!u)if(S(d)){A++,d===9?a+=4-a%4:a++;continue}else u=!0;(d===10||s===l-1)&&(d!==10&&s++,this.bMarks.push(o),this.eMarks.push(s),this.tShift.push(A),this.sCount.push(a),this.bsCount.push(0),u=!1,A=0,a=0,o=s+1)}this.bMarks.push(r.length),this.eMarks.push(r.length),this.tShift.push(0),this.sCount.push(0),this.bsCount.push(0),this.lineMax=this.bMarks.length-1}push(e,t,n){const i=new Ie(e,t,n);return i.block=!0,n<0&&this.level--,i.level=this.level,n>0&&this.level++,this.tokens.push(i),i}isEmpty(e){return this.bMarks[e]+this.tShift[e]>=this.eMarks[e]}skipEmptyLines(e){for(let t=this.lineMax;e<t&&!(this.bMarks[e]+this.tShift[e]<this.eMarks[e]);e++);return e}skipSpaces(e){for(let t=this.src.length;e<t&&S(this.src.charCodeAt(e));e++);return e}skipSpacesBack(e,t){if(e<=t)return e;for(;e>t;)if(!S(this.src.charCodeAt(--e)))return e+1;return e}skipChars(e,t){for(let n=this.src.length;e<n&&this.src.charCodeAt(e)===t;e++);return e}skipCharsBack(e,t,n){if(e<=n)return e;for(;e>n;)if(t!==this.src.charCodeAt(--e))return e+1;return e}getLines(e,t,n,i){if(e>=t)return"";const r=new Array(t-e);for(let o=0,s=e;s<t;s++,o++){let A=0;const a=this.bMarks[s];let l=a,u;for(s+1<t||i?u=this.eMarks[s]+1:u=this.eMarks[s];l<u&&A<n;){const d=this.src.charCodeAt(l);if(S(d))d===9?A+=4-(A+this.bsCount[s])%4:A++;else if(l-a<this.tShift[s])A++;else break;l++}A>n?r[o]=new Array(A-n+1).join(" ")+this.src.slice(l,u):r[o]=this.src.slice(l,u)}return r.join("")}},uo=65536;function Rt(e,t){const n=e.bMarks[t]+e.tShift[t],i=e.eMarks[t];return e.src.slice(n,i)}function Dn(e){const t=[],n=e.length;let i=0,r=e.charCodeAt(i),o=!1,s=0,A="";for(;i<n;)r===124&&(o?(A+=e.substring(s,i-1),s=i):(t.push(A+e.substring(s,i)),A="",s=i+1)),o=r===92,i++,r=e.charCodeAt(i);return t.push(A+e.substring(s)),t}function ho(e,t,n,i){if(t+2>n)return!1;let r=t+1;if(e.sCount[r]<e.blkIndent||e.sCount[r]-e.blkIndent>=4)return!1;let o=e.bMarks[r]+e.tShift[r];if(o>=e.eMarks[r])return!1;
15const s=e.src.charCodeAt(o++);if(s!==124&&s!==45&&s!==58||o>=e.eMarks[r])return!1;const A=e.src.charCodeAt(o++);if(A!==124&&A!==45&&A!==58&&!S(A)||s===45&&S(A))return!1;for(;o<e.eMarks[r];){const p=e.src.charCodeAt(o);if(p!==124&&p!==45&&p!==58&&!S(p))return!1;o++}let a=Rt(e,t+1),l=a.split("|");const u=[];for(let p=0;p<l.length;p++){const f=l[p].trim();if(!f){if(p===0||p===l.length-1)continue;return!1}if(!/^:?-+:?$/.test(f))return!1;f.charCodeAt(f.length-1)===58?u.push(f.charCodeAt(0)===58?"center":"right"):f.charCodeAt(0)===58?u.push("left"):u.push("")}if(a=Rt(e,t).trim(),a.indexOf("|")===-1||e.sCount[t]-e.blkIndent>=4)return!1;l=Dn(a),l.length&&l[0]===""&&l.shift(),l.length&&l[l.length-1]===""&&l.pop();const d=l.length;if(d===0||d!==u.length)return!1;if(i)return!0;const g=e.parentType;e.parentType="table";const h=e.md.block.ruler.getRules("blockquote"),c=e.push("table_open","table",1),b=[t,0];c.map=b;const m=e.push("thead_open","thead",1);m.map=[t,t+1];const D=e.push("tr_open","tr",1);D.map=[t,t+1];for(let p=0;p<l.length;p++){const f=e.push("th_open","th",1);u[p]&&(f.attrs=[["style",`text-align:${u[p]}`]]);const I=e.push("inline","",0);I.content=l[p].trim(),I.children=[],e.push("th_close","th",-1)}e.push("tr_close","tr",-1),e.push("thead_close","thead",-1);let C,k=0;for(r=t+2;r<n&&!(e.sCount[r]<e.blkIndent);r++){let p=!1;for(let I=0,E=h.length;I<E;I++)if(h[I](e,r,n,!0)){p=!0;break}if(p||(a=Rt(e,r).trim(),!a)||e.sCount[r]-e.blkIndent>=4||(l=Dn(a),l.length&&l[0]===""&&l.shift(),l.length&&l[l.length-1]===""&&l.pop(),k+=d-l.length,k>uo))break;if(r===t+2){const I=e.push("tbody_open","tbody",1);I.map=C=[t+2,0]}const f=e.push("tr_open","tr",1);f.map=[r,r+1];for(let I=0;I<d;I++){const E=e.push("td_open","td",1);u[I]&&(E.attrs=[["style",`text-align:${u[I]}`]]);const B=e.push("inline","",0);B.content=l[I]?l[I].trim():"",B.children=[],e.push("td_close","td",-1)}e.push("tr_close","tr",-1)}return C&&(e.push("tbody_close","tbody",-1),C[1]=r),e.push("table_close","table",-1),b[1]=r,e.parentType=g,e.line=r,!0}function go(e,t,n){if(e.sCount[t]-e.blkIndent<4)return!1;let i=t+1,r=i;for(;i<n;){if(e.isEmpty(i)){i++;continue}if(e.sCount[i]-e.blkIndent>=4){i++,r=i;continue}break}e.line=r;const o=e.push("code_block","code",0);return o.content=e.getLines(t,r,4+e.blkIndent,!1)+`
16`,o.map=[t,e.line],!0}function fo(e,t,n,i){let r=e.bMarks[t]+e.tShift[t],o=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4||r+3>o)return!1;const s=e.src.charCodeAt(r);if(s!==126&&s!==96)return!1;let A=r;r=e.skipChars(r,s);let a=r-A;if(a<3)return!1;const l=e.src.slice(A,r),u=e.src.slice(r,o);if(s===96&&u.indexOf(String.fromCharCode(s))>=0)return!1;if(i)return!0;let d=t,g=!1;for(;d++,!(d>=n||(r=A=e.bMarks[d]+e.tShift[d],o=e.eMarks[d],r<o&&e.sCount[d]<e.blkIndent));)if(e.src.charCodeAt(r)===s&&!(e.sCount[d]-e.blkIndent>=4)&&(r=e.skipChars(r,s),!(r-A<a)&&(r=e.skipSpaces(r),!(r<o)))){g=!0;break}a=e.sCount[t],e.line=d+(g?1:0);const h=e.push("fence","code",0);return h.info=u,h.content=e.getLines(t+1,d,a,!0),h.markup=l,h.map=[t,e.line],!0}function po(e,t,n,i){let r=e.bMarks[t]+e.tShift[t],o=e.eMarks[t];const s=e.lineMax;if(e.sCount[t]-e.blkIndent>=4||e.src.charCodeAt(r)!==62)return!1;if(i)return!0;const A=[],a=[],l=[],u=[],d=e.md.block.ruler.getRules("blockquote"),g=e.parentType;e.parentType="blockquote";let h=!1,c;for(c=t;c<n;c++){const k=e.sCount[c]<e.blkIndent;if(r=e.bMarks[c]+e.tShift[c],o=e.eMarks[c],r>=o)break;if(e.src.charCodeAt(r++)===62&&!k){let f=e.sCount[c]+1,I,E;e.src.charCodeAt(r)===32?(r++,f++,E=!1,I=!0):e.src.charCodeAt(r)===9?(I=!0,(e.bsCount[c]+f)%4===3?(r++,f++,E=!1):E=!0):I=!1;let B=f;for(A.push(e.bMarks[c]),e.bMarks[c]=r;r<o;){const _=e.src.charCodeAt(r);if(S(_))_===9?B+=4-(B+e.bsCount[c]+(E?1:0))%4:B++;else break;r++}h=r>=o,a.push(e.bsCount[c]),e.bsCount[c]=e.sCount[c]+1+(I?1:0),l.push(e.sCount[c]),e.sCount[c]=B-f,u.push(e.tShift[c]),e.tShift[c]=r-e.bMarks[c];continue}if(h)break;let p=!1;for(let f=0,I=d.length;f<I;f++)if(d[f](e,c,n,!0)){p=!0;break}if(p){e.lineMax=c,e.blkIndent!==0&&(A.push(e.bMarks[c]),a.push(e.bsCount[c]),u.push(e.tShift[c]),l.push(e.sCount[c]),e.sCount[c]-=e.blkIndent);break}
16A.push(e.bMarks[c]),a.push(e.bsCount[c]),u.push(e.tShift[c]),l.push(e.sCount[c]),e.sCount[c]=-1}const b=e.blkIndent;e.blkIndent=0;const m=e.push("blockquote_open","blockquote",1);m.markup=">";const D=[t,0];m.map=D,e.md.block.tokenize(e,t,c);const C=e.push("blockquote_close","blockquote",-1);C.markup=">",e.lineMax=s,e.parentType=g,D[1]=e.line;for(let k=0;k<u.length;k++)e.bMarks[k+t]=A[k],e.tShift[k+t]=u[k],e.sCount[k+t]=l[k],e.bsCount[k+t]=a[k];return e.blkIndent=b,!0}function mo(e,t,n,i){const r=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;let o=e.bMarks[t]+e.tShift[t];const s=e.src.charCodeAt(o++);if(s!==42&&s!==45&&s!==95)return!1;let A=1;for(;o<r;){const l=e.src.charCodeAt(o++);if(l!==s&&!S(l))return!1;l===s&&A++}if(A<3)return!1;if(i)return!0;e.line=t+1;const a=e.push("hr","hr",0);return a.map=[t,e.line],a.markup=Array(A+1).join(String.fromCharCode(s)),!0}function Fn(e,t){const n=e.eMarks[t];let i=e.bMarks[t]+e.tShift[t];const r=e.src.charCodeAt(i++);return r!==42&&r!==45&&r!==43||i<n&&!S(e.src.charCodeAt(i))?-1:i}function Bn(e,t){const n=e.bMarks[t]+e.tShift[t],i=e.eMarks[t];let r=n;if(r+1>=i)return-1;let o=e.src.charCodeAt(r++);if(o<48||o>57)return-1;for(;;){if(r>=i)return-1;if(o=e.src.charCodeAt(r++),o>=48&&o<=57){if(r-n>=10)return-1;continue}if(o===41||o===46)break;return-1}return r<i&&(o=e.src.charCodeAt(r),!S(o))?-1:r}function Co(e,t){const n=e.level+2;for(let i=t+2,r=e.tokens.length-2;i<r;i++)e.tokens[i].level===n&&e.tokens[i].type==="paragraph_open"&&(e.tokens[i+2].hidden=!0,e.tokens[i].hidden=!0,i+=2)}function bo(e,t,n,i){let r,o,s,A,a=t,l=!0;if(e.sCount[a]-e.blkIndent>=4||e.listIndent>=0&&e.sCount[a]-e.listIndent>=4&&e.sCount[a]<e.blkIndent)return!1;let u=!1;i&&e.parentType==="paragraph"&&e.sCount[a]>=e.blkIndent&&(u=!0);let d,g,h;if((h=Bn(e,a))>=0){if(d=!0,s=e.bMarks[a]+e.tShift[a],g=Number(e.src.slice(s,h-1)),u&&g!==1)return!1}else if((h=Fn(e,a))>=0)d=!1;else return!1;if(u&&e.skipSpaces(h)>=e.eMarks[a])return!1;if(i)return!0;const c=e.src.charCodeAt(h-1),b=e.tokens.length;d?(A=e.push("ordered_list_open","ol",1),g!==1&&(A.attrs=[["start",g]])):A=e.push("bullet_list_open","ul",1);const m=[a,0];A.map=m,A.markup=String.fromCharCode(c);let D=!1;const C=e.md.block.ruler.getRules("list"),k=e.parentType;for(e.parentType="list";a<n;){o=h,r=e.eMarks[a];const p=e.sCount[a]+h-(e.bMarks[a]+e.tShift[a]);let f=p;for(;o<r;){const j=e.src.charCodeAt(o);if(j===9)f+=4-(f+e.bsCount[a])%4;else if(j===32)f++;else break;o++}const I=o;let E;I>=r?E=1:E=f-p,E>4&&(E=1);const B=p+E;A=e.push("list_item_open","li",1),A.markup=String.fromCharCode(c);const _=[a,0];A.map=_,d&&(A.info=e.src.slice(s,h-1));const Y=e.tight,Z=e.tShift[a],v=e.sCount[a],R=e.listIndent;if(e.listIndent=e.blkIndent,e.blkIndent=B,e.tight=!0,e.tShift[a]=I-e.bMarks[a],e.sCount[a]=f,I>=r&&e.isEmpty(a+1)?e.line=Math.min(e.line+2,n):e.md.block.tokenize(e,a,n),(!e.tight||D)&&(l=!1),D=e.line-a>1&&e.isEmpty(e.line-1),e.blkIndent=e.listIndent,e.listIndent=R,e.tShift[a]=Z,e.sCount[a]=v,e.tight=Y,A=e.push("list_item_close","li",-1),A.markup=String.fromCharCode(c),a=e.line,_[1]=a,a>=n||e.sCount[a]<e.blkIndent||e.sCount[a]-e.blkIndent>=4)break;let V=!1;for(let j=0,Te=C.length;j<Te;j++)if(C[j](e,a,n,!0)){V=!0;break}if(V)break;if(d){if(h=Bn(e,a),h<0)break;s=e.bMarks[a]+e.tShift[a]}else if(h=Fn(e,a),h<0)break;if(c!==e.src.charCodeAt(h-1))break}return d?A=e.push("ordered_list_close","ol",-1):A=e.push("bullet_list_close","ul",-1),A.markup=String.fromCharCode(c),m[1]=a,e.line=a,e.parentType=k,l&&Co(e,b),!0}function wo(e,t,n,i){let r=e.bMarks[t]+e.tShift[t],o=e.eMarks[t],s=t+1;if(e.sCount[t]-e.blkIndent>=4||e.src.charCodeAt(r)!==91)return!1;function A(p){const f=e.lineMax;if(p>=f||e.isEmpty(p))return null;let I=!1;if(e.sCount[p]-e.blkIndent>3&&(I=!0),e.sCount[p]<0&&(I=!0),!I){const _=e.md.block.ruler.getRules("reference"),Y=e.parentType;e.parentType="reference";let Z=!1;for(let v=0,R=_.length;v<R;v++)if(_[v](e,p,f,!0)){Z=!0;break}if(e.parentType=Y,Z)return null}const E=e.bMarks[p]+e.tShift[p],B=e.eMarks[p];return e.src.slice(E,B+1)}let a=e.src.slice(r,o+1);o=a.length;let l=-1;for(r=1;r<o;
16r++){const p=a.charCodeAt(r);if(p===91)return!1;if(p===93){l=r;break}else if(p===10){const f=A(s);f!==null&&(a+=f,o=a.length,s++)}else if(p===92&&(r++,r<o&&a.charCodeAt(r)===10)){const f=A(s);f!==null&&(a+=f,o=a.length,s++)}}if(l<0||a.charCodeAt(l+1)!==58)return!1;for(r=l+2;r<o;r++){const p=a.charCodeAt(r);if(p===10){const f=A(s);f!==null&&(a+=f,o=a.length,s++)}else if(!S(p))break}const u=e.md.helpers.parseLinkDestination(a,r,o);if(!u.ok)return!1;const d=e.md.normalizeLink(u.str);if(!e.md.validateLink(d))return!1;r=u.pos;const g=r,h=s,c=r;for(;r<o;r++){const p=a.charCodeAt(r);if(p===10){const f=A(s);f!==null&&(a+=f,o=a.length,s++)}else if(!S(p))break}let b=e.md.helpers.parseLinkTitle(a,r,o);for(;b.can_continue;){const p=A(s);if(p===null)break;a+=p,r=o,o=a.length,s++,b=e.md.helpers.parseLinkTitle(a,r,o,b)}let m;for(r<o&&c!==r&&b.ok?(m=b.str,r=b.pos):(m="",r=g,s=h);r<o&&S(a.charCodeAt(r));)r++;if(r<o&&a.charCodeAt(r)!==10&&m)for(m="",r=g,s=h;r<o&&S(a.charCodeAt(r));)r++;if(r<o&&a.charCodeAt(r)!==10)return!1;const D=Ct(a.slice(1,l));if(!D)return!1;if(i)return!0;typeof e.env.references>"u"&&(e.env.references={}),typeof e.env.references[D]>"u"&&(e.env.references[D]={title:m,href:d});const C=e.push("reference_definition","",0);C.map=[t,s],C.hidden=!0;const k=Object.create(null);return k.label=D,C.meta=k,e.line=s,!0}var ko=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],lr=`<[A-Za-z][A-Za-z0-9\\-]*(?:\\s+[a-zA-Z_:][a-zA-Z0-9:._-]*(?:\\s*=\\s*(?:[^"'=<>\`\\x00-\\x20]+|'[^']*'|"[^"]*"))?)*\\s*\\/?>`,cr="<\\/[A-Za-z][A-Za-z0-9\\-]*\\s*>",yo=new RegExp(`^(?:${lr}|${cr}|<!---?>|<!--(?:[^-]|-[^-]|--[^>])*-->|<[?][\\s\\S]*?[?]>|<![A-Za-z][^>]*>|<!\\[CDATA\\[[\\s\\S]*?\\]\\]>)`),Io=new RegExp(`^(?:${lr}|${cr})`),we=[[/^<(script|pre|style|textarea)(?=(\s|>|$))/i,/<\/(script|pre|style|textarea)>/i,!0],[/^<!--/,/-->/,!0],[/^<\?/,/\?>/,!0],[/^<![A-Za-z]/,/>/,!0],[/^<!\[CDATA\[/,/\]\]>/,!0],[new RegExp(`^</?(${ko.join("|")})(?=(\\s|/?>|$))`,"i"),/^$/,!0],[new RegExp(`${Io.source}\\s*$`),/^$/,!1]];function Do(e,t,n,i){let r=e.bMarks[t]+e.tShift[t],o=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4||!e.md.options.html||e.src.charCodeAt(r)!==60)return!1;let s=e.src.slice(r,o),A=0;for(;A<we.length&&!we[A][0].test(s);A++);if(A===we.length)return!1;if(i)return we[A][2];let a=t+1;const l=we[A][1].test("");if(!we[A][1].test(s)){for(;a<n&&!(e.sCount[a]<e.blkIndent&&(l||!e.isEmpty(a)));a++)if(r=e.bMarks[a]+e.tShift[a],o=e.eMarks[a],s=e.src.slice(r,o),we[A][1].test(s)){s.length!==0&&a++;break}}e.line=a;const u=e.push("html_block","",0);return u.map=[t,a],u.content=e.getLines(t,a,e.blkIndent,!0),!0}function Fo(e,t,n,i){let r=e.bMarks[t]+e.tShift[t],o=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;let s=e.src.charCodeAt(r);if(s!==35||r>=o)return!1;let A=1;for(s=e.src.charCodeAt(++r);s===35&&r<o&&A<=6;)A++,s=e.src.charCodeAt(++r);if(A>6||r<o&&!S(s))return!1;if(i)return!0;o=e.skipSpacesBack(o,r);const a=e.skipCharsBack(o,35,r);a>r&&S(e.src.charCodeAt(a-1))&&(o=a),e.line=t+1;const l=e.push("heading_open",`h${A}`,1);l.markup="########".slice(0,A),l.map=[t,e.line];const u=e.push("inline","",0);u.content=bt(e.src.slice(r,o)),u.map=[t,e.line],u.children=[];const d=e.push("heading_close",`h${A}`,-1);return d.markup="########".slice(0,A),!0}function Bo(e,t,n){const i=e.md.block.ruler.getRules("paragraph");if(e.sCount[t]-e.blkIndent>=4)return!1;const r=e.parentType;e.parentType="paragraph";let o=0,s,A=t+1;for(;A<n&&!e.isEmpty(A);A++){if(e.sCount[A]-e.blkIndent>3)continue;if(e.sCount[A]>=e.blkIndent){let h=e.bMarks[A]+e.tShift[A];const c=e.eMarks[A];if(h<c&&(s=e.src.charCodeAt(h),(s===45||s===61)&&(h=e.skipChars(h,s),h=e.skipSpaces(h),h>=c))){o=s===61?1:2;break}}if(e.sCount[A]<0)continue;let g=!1;for(let h=0,c=i.length;h<c;h++)if(i[h](e,A,n,!0)){g=!0;break}if(g)break}if(!o)return e.parentType=r,!1;const a=bt(e.getLines(t,A,e.blkIndent,!1));e.line=A+1;const l=e.push("heading_open",`h${o}
16`,1);l.markup=String.fromCharCode(s),l.map=[t,e.line];const u=e.push("inline","",0);u.content=a,u.map=[t,e.line-1],u.children=[];const d=e.push("heading_close",`h${o}`,-1);return d.markup=String.fromCharCode(s),e.parentType=r,!0}function vo(e,t,n){const i=e.md.block.ruler.getRules("paragraph"),r=e.parentType;let o=t+1;for(e.parentType="paragraph";o<n&&!e.isEmpty(o);o++){if(e.sCount[o]-e.blkIndent>3||e.sCount[o]<0)continue;let l=!1;for(let u=0,d=i.length;u<d;u++)if(i[u](e,o,n,!0)){l=!0;break}if(l)break}const s=bt(e.getLines(t,o,e.blkIndent,!1));e.line=o;const A=e.push("paragraph_open","p",1);A.map=[t,e.line];const a=e.push("inline","",0);return a.content=s,a.map=[t,e.line],a.children=[],e.push("paragraph_close","p",-1),e.parentType=r,!0}var it=[["table",ho,["paragraph","reference"]],["code",go],["fence",fo,["paragraph","reference","blockquote","list"]],["blockquote",po,["paragraph","reference","blockquote","list"]],["hr",mo,["paragraph","reference","blockquote","list"]],["list",bo,["paragraph","reference","blockquote"]],["reference",wo],["html_block",Do,["paragraph","reference","blockquote"]],["heading",Fo,["paragraph","reference","blockquote"]],["lheading",Bo],["paragraph",vo]],ur=class{constructor(){F(this,"ruler",new Ne),F(this,"State",ar);for(let e=0;e<it.length;e++)this.ruler.push(it[e][0],it[e][1],{alt:(it[e][2]||[]).slice()})}tokenize(e,t,n){const i=this.ruler.getRules(""),r=i.length,o=e.md.options.maxNesting;let s=t,A=!1;for(;s<n&&(e.line=s=e.skipEmptyLines(s),!(s>=n||e.sCount[s]<e.blkIndent));){if(e.level>=o){e.line=n;break}const a=e.line;let l=!1;for(let u=0;u<r;u++)if(l=i[u](e,s,n,!1),l){if(a>=e.line)throw new Error("block rule didn't increment state.line");break}if(!l)throw new Error("none of the block rules matched");e.tight=!A,e.isEmpty(e.line-1)&&(A=!0),s=e.line,s<n&&e.isEmpty(s)&&(A=!0,s++,e.line=s)}}parse(e,t,n,i){if(!e)return;const r=new this.State(e,t,n,i);this.tokenize(r,r.line,r.lineMax)}},dr=class{constructor(e,t,n,i){F(this,"pos",0),F(this,"level",0),F(this,"pending",""),F(this,"pendingLevel",0),F(this,"cache",{}),F(this,"backticks",{}),F(this,"backticksScanned",!1),F(this,"linkLevel",0),F(this,"delimiters",[]),F(this,"_prev_delimiters",[]),F(this,"Token",Ie),this.src=e,this.env=n,this.md=t,this.tokens=i,this.tokens_meta=Array(i.length),this.posMax=this.src.length}pushPending(){const e=new Ie("text","",0);return e.content=this.pending,e.level=this.pendingLevel,this.tokens.push(e),this.pending="",e}push(e,t,n){this.pending&&this.pushPending();const i=new Ie(e,t,n);let r;return n<0&&(this.level--,this.delimiters=this._prev_delimiters.pop()),i.level=this.level,n>0&&(this.level++,this._prev_delimiters.push(this.delimiters),this.delimiters=[],r={delimiters:this.delimiters}),this.pendingLevel=this.level,this.tokens.push(i),this.tokens_meta.push(r),i}scanDelims(e,t){const n=this.posMax,i=this.src.charCodeAt(e);let r;if(e===0)r=32;else if(e===1)r=this.src.charCodeAt(0),(r&63488)===55296&&(r=65533);else if(r=this.src.charCodeAt(e-1),(r&64512)===56320){const c=this.src.charCodeAt(e-2);r=(c&64512)===55296?65536+(c-55296<<10)+(r-56320):65533}else(r&64512)===55296&&(r=65533);let o=e;for(;o<n&&this.src.charCodeAt(o)===i;)o++;const s=o-e;let A=o<n?this.src.charCodeAt(o):32;if((A&64512)===55296){const c=this.src.charCodeAt(o+1);A=(c&64512)===56320?65536+(A-55296<<10)+(c-56320):65533}else(A&64512)===56320&&(A=65533);const a=Ze(r)||Je(r),l=Ze(A)||Je(A),u=Me(r),d=Me(A),g=!d&&(!l||u||a),h=!u&&(!a||d||l);return{can_open:g&&(t||!h||a),can_close:h&&(t||!g||l),length:s}}};function Eo(e){switch(e){case 10:case 33:case 35:case 36:case 37:case 38:case 42:case 43:case 45:case 58:case 60:case 61:case 62:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 125:case 126:return!0;default:return!1}}function _o(e,t){let n=e.pos;for(;n<e.posMax&&!Eo(e.src.charCodeAt(n));)n++;return n===e.pos?!1:(t||(e.pending+=e.src.slice(e.pos,n)),e.pos=n,!0)}var xo=/(?:^|[^a-z0-9.+-])([a-z][a-z0-9.+-]*)$/i;function So(e,t){if(!e.md.options.linkify||e.linkLevel>0)return!1;const n=e.pos,i=e.posMax;if(n+3>
16i||e.src.charCodeAt(n)!==58||e.src.charCodeAt(n+1)!==47||e.src.charCodeAt(n+2)!==47)return!1;const r=e.pending.match(xo);if(!r)return!1;const o=r[1],s=e.md.linkify.matchAtStart(e.src.slice(n-o.length));if(!s)return!1;let A=s.url;if(A.length<=o.length)return!1;let a=A.length;for(;a>0&&A.charCodeAt(a-1)===42;)a--;a!==A.length&&(A=A.slice(0,a));const l=e.md.normalizeLink(A);if(!e.md.validateLink(l))return!1;if(!t){e.pending=e.pending.slice(0,-o.length);const u=e.push("link_open","a",1);u.attrs=[["href",l]],u.markup="linkify",u.info="auto";const d=e.push("text","",0);d.content=e.md.normalizeLinkText(A);const g=e.push("link_close","a",-1);g.markup="linkify",g.info="auto"}return e.pos+=A.length-o.length,!0}function Qo(e,t){let n=e.pos;if(e.src.charCodeAt(n)!==10)return!1;const i=e.pending.length-1,r=e.posMax;if(!t)if(i>=0&&e.pending.charCodeAt(i)===32)if(i>=1&&e.pending.charCodeAt(i-1)===32){let o=i-1;for(;o>=1&&e.pending.charCodeAt(o-1)===32;)o--;e.pending=e.pending.slice(0,o),e.push("hardbreak","br",0)}else e.pending=e.pending.slice(0,-1),e.push("softbreak","br",0);else e.push("softbreak","br",0);for(n++;n<r&&S(e.src.charCodeAt(n));)n++;return e.pos=n,!0}var zt=[];for(let e=0;e<256;e++)zt.push(0);"\\!\"#$%&'()*+,./:;<=>?@[]^_`{|}~-".split("").forEach(function(e){zt[e.charCodeAt(0)]=1});function Ko(e,t){let n=e.pos;const i=e.posMax;if(e.src.charCodeAt(n)!==92||(n++,n>=i))return!1;let r=e.src.charCodeAt(n);if(r===10){for(t||e.push("hardbreak","br",0),n++;n<i&&(r=e.src.charCodeAt(n),!!S(r));)n++;return e.pos=n,!0}if(r===32){if(!t){const A=e.push("text_special","",0);A.content="\\",A.markup="\\",A.info="escape"}return e.pos=n,!0}let o=e.src[n];if(r>=55296&&r<=56319&&n+1<i){const A=e.src.charCodeAt(n+1);A>=56320&&A<=57343&&(o+=e.src[n+1],n++)}const s="\\"+o;if(!t){const A=e.push("text_special","",0);r<256&&zt[r]!==0?A.content=o:A.content=s,A.markup=s,A.info="escape"}return e.pos=n+1,!0}function Ro(e,t){let n=e.pos;if(e.src.charCodeAt(n)!==96)return!1;const i=n;n++;const r=e.posMax;for(;n<r&&e.src.charCodeAt(n)===96;)n++;const o=e.src.slice(i,n),s=o.length;if(e.backticksScanned&&(e.backticks[s]||0)<=i)return t||(e.pending+=o),e.pos+=s,!0;let A=n,a;for(;(a=e.src.indexOf("`",A))!==-1;){for(A=a+1;A<r&&e.src.charCodeAt(A)===96;)A++;const l=A-a;if(l===s){if(!t){const u=e.push("code_inline","code",0);u.markup=o,u.content=e.src.slice(n,a).replace(/\n/g," ").replace(/^ (.+) $/,"$1")}return e.pos=A,!0}e.backticks[l]=a}return e.backticksScanned=!0,t||(e.pending+=o),e.pos+=s,!0}function Yo(e,t){const n=e.pos,i=e.src.charCodeAt(n);if(t||i!==126)return!1;const r=e.scanDelims(e.pos,!0);let o=r.length;const s=String.fromCharCode(i);if(o<2)return!1;let A;o%2&&(A=e.push("text","",0),A.content=s,o--);for(let a=0;a<o;a+=2)A=e.push("text","",0),A.content=s+s,e.delimiters.push({marker:i,length:0,token:e.tokens.length-1,end:-1,open:r.can_open,close:r.can_close});return e.pos+=r.length,!0}function vn(e,t){let n;const i=[],r=t.length;for(let o=0;o<r;o++){const s=t[o];if(s.marker!==126||s.end===-1)continue;const A=t[s.end];n=e.tokens[s.token],n.type="s_open",n.tag="s",n.nesting=1,n.markup="~~",n.content="",n=e.tokens[A.token],n.type="s_close",n.tag="s",n.nesting=-1,n.markup="~~",n.content="",e.tokens[A.token-1].type==="text"&&e.tokens[A.token-1].content==="~"&&i.push(A.token-1)}for(;i.length;){const o=i.pop();let s=o+1;for(;s<e.tokens.length&&e.tokens[s].type==="s_close";)s++;s--,o!==s&&(n=e.tokens[s],e.tokens[s]=e.tokens[o],e.tokens[o]=n)}}function Go(e){const t=e.tokens_meta,n=e.tokens_meta.length;vn(e,e.delimiters);for(let r=0;r<n;r++){var i;const o=(i=t[r])===null||i===void 0?void 0:i.delimiters;o&&vn(e,o)}}var hr={tokenize:Yo,postProcess:Go};function Wo(e,t){const n=e.pos,i=e.src.charCodeAt(n);if(t||i!==95&&i!==42)return!1;const r=e.scanDelims(e.pos,i===42);for(let o=0;o<r.length;o++){const s=e.push("text","",0);s.content=String.fromCharCode(i),e.delimiters.push({marker:i,length:r.length,token:e.tokens.length-1,end:-1,open:r.can_open,close:r.can_close})}return e.pos+=r.length,!0}function En(e,t){const n=t.length;for(let i=n-1;i>=0;i--){const r=t[i];if(r.marker!==95&&r.marker!==42||r.end===-1)continue;const o=t[r.end],s=i>0&&t[i-1].end===r.end+1&&t[i-1].marker===r.marker&&t[i-1].token===r.token-1&&t[r.end+1].token===o.token+1,A=String.fromCharCode(r.marker),a=e.tokens[r.token];a.type=s?"strong_open":"em_open",a.tag=s?"strong":"em",a.nesting=1,a.markup=s?A+A:A,a.
16content="";const l=e.tokens[o.token];l.type=s?"strong_close":"em_close",l.tag=s?"strong":"em",l.nesting=-1,l.markup=s?A+A:A,l.content="",s&&(e.tokens[t[i-1].token].content="",e.tokens[t[r.end+1].token].content="",i--)}}function Mo(e){const t=e.tokens_meta,n=e.tokens_meta.length;En(e,e.delimiters);for(let r=0;r<n;r++){var i;const o=(i=t[r])===null||i===void 0?void 0:i.delimiters;o&&En(e,o)}}var gr={tokenize:Wo,postProcess:Mo};function Jo(e,t){let n,i,r,o,s="",A="",a=e.pos,l=!0;if(e.src.charCodeAt(e.pos)!==91)return!1;const u=e.pos,d=e.posMax,g=e.pos+1,h=e.md.helpers.parseLinkLabel(e,e.pos,!0);if(h<0)return!1;let c=h+1;if(c<d&&e.src.charCodeAt(c)===40){for(l=!1,c++;c<d&&(n=e.src.charCodeAt(c),!(!S(n)&&n!==10));c++);if(c>=d)return!1;if(a=c,r=e.md.helpers.parseLinkDestination(e.src,c,e.posMax),r.ok){for(s=e.md.normalizeLink(r.str),e.md.validateLink(s)?c=r.pos:s="",a=c;c<d&&(n=e.src.charCodeAt(c),!(!S(n)&&n!==10));c++);if(r=e.md.helpers.parseLinkTitle(e.src,c,e.posMax),c<d&&a!==c&&r.ok)for(A=r.str,c=r.pos;c<d&&(n=e.src.charCodeAt(c),!(!S(n)&&n!==10));c++);}(c>=d||e.src.charCodeAt(c)!==41)&&(l=!0),c++}if(l){if(typeof e.env.references>"u")return!1;if(c<d&&e.src.charCodeAt(c)===91?(a=c+1,c=e.md.helpers.parseLinkLabel(e,c),c>=0?i=e.src.slice(a,c++):c=h+1):c=h+1,i||(i=e.src.slice(g,h)),i=Ct(i),o=e.env.references[i],!o)return e.pos=u,!1;s=o.href,A=o.title}if(!t){e.pos=g,e.posMax=h;const b=e.push("link_open","a",1),m=[["href",s]];if(b.attrs=m,A&&m.push(["title",A]),i){const D=Object.create(null);D.label=i,b.meta=D}e.linkLevel++,e.md.inline.tokenize(e),e.linkLevel--,e.push("link_close","a",-1)}return e.pos=c,e.posMax=d,!0}function Zo(e,t){let n,i,r,o,s,A,a,l,u="";const d=e.pos,g=e.posMax;if(e.src.charCodeAt(e.pos)!==33||e.src.charCodeAt(e.pos+1)!==91)return!1;const h=e.pos+2,c=e.md.helpers.parseLinkLabel(e,e.pos+1,!1);if(c<0)return!1;if(o=c+1,o<g&&e.src.charCodeAt(o)===40){for(o++;o<g&&(n=e.src.charCodeAt(o),!(!S(n)&&n!==10));o++);if(o>=g)return!1;for(l=o,A=e.md.helpers.parseLinkDestination(e.src,o,e.posMax),A.ok&&(u=e.md.normalizeLink(A.str),e.md.validateLink(u)?o=A.pos:u=""),l=o;o<g&&(n=e.src.charCodeAt(o),!(!S(n)&&n!==10));o++);if(A=e.md.helpers.parseLinkTitle(e.src,o,e.posMax),o<g&&l!==o&&A.ok)for(a=A.str,o=A.pos;o<g&&(n=e.src.charCodeAt(o),!(!S(n)&&n!==10));o++);else a="";if(o>=g||e.src.charCodeAt(o)!==41)return e.pos=d,!1;o++}else{if(typeof e.env.references>"u")return!1;if(o<g&&e.src.charCodeAt(o)===91?(l=o+1,o=e.md.helpers.parseLinkLabel(e,o),o>=0?r=e.src.slice(l,o++):o=c+1):o=c+1,r||(r=e.src.slice(h,c)),r=Ct(r),s=e.env.references[r],!s)return e.pos=d,!1;u=s.href,a=s.title}if(!t){i=e.src.slice(h,c);const b=[];e.md.inline.parse(i,e.md,e.env,b);const m=e.push("image","img",0),D=[["src",u],["alt",""]];if(m.attrs=D,m.children=b,m.content=i,a&&D.push(["title",a]),r){const C=Object.create(null);C.label=r,m.meta=C}}return e.pos=o,e.posMax=g,!0}var Ho=/^([a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*)$/,No=/^([a-zA-Z][a-zA-Z0-9+.-]{1,31}):([^<>\x00-\x20]*)$/;function Uo(e,t){let n=e.pos;if(e.src.charCodeAt(n)!==60)return!1;const i=e.pos,r=e.posMax;for(;;){if(++n>=r)return!1;const s=e.src.charCodeAt(n);if(s===60)return!1;if(s===62)break}const o=e.src.slice(i+1,n);if(No.test(o)){const s=e.md.normalizeLink(o);if(!e.md.validateLink(s))return!1;if(!t){const A=e.push("link_open","a",1);A.attrs=[["href",s]],A.markup="autolink",A.info="auto";const a=e.push("text","",0);a.content=e.md.normalizeLinkText(o);const l=e.push("link_close","a",-1);l.markup="autolink",l.info="auto"}return e.pos+=o.length+2,!0}if(Ho.test(o)){const s=e.md.normalizeLink(`mailto:${o}`);if(!e.md.validateLink(s))return!1;if(!t){const A=e.push("link_open","a",1);A.attrs=[["href",s]],A.markup="autolink",A.info="auto";const a=e.push("text","",0);a.content=e.md.normalizeLinkText(o);const l=e.push("link_close","a",-1);l.markup="autolink",l.info="auto"}return e.pos+=o.length+2,!0}return!1}function Lo(e){return/^<a[>\s]/i.test(e)}function Oo(e){return/^<\/a\s*>/i.test(e)}function $o(e){const t=e|32;return t>=97&&t<=122}function To(e,t){if(!e.md.options.html)return!1;const n=e.posMax,i=e.pos;
16if(e.src.charCodeAt(i)!==60||i+2>=n)return!1;const r=e.src.charCodeAt(i+1);if(r!==33&&r!==63&&r!==47&&!$o(r))return!1;const o=e.src.slice(i).match(yo);if(!o)return!1;if(!t){const s=e.push("html_inline","",0);s.content=o[0],Lo(s.content)&&e.linkLevel++,Oo(s.content)&&e.linkLevel--}return e.pos+=o[0].length,!0}var Po=/^&#((?:x[a-f0-9]{1,6}|[0-9]{1,7}));/i,zo=/^&([a-z][a-z0-9]{1,31});/i;function jo(e,t){const n=e.pos,i=e.posMax;if(e.src.charCodeAt(n)!==38||n+1>=i)return!1;if(e.src.charCodeAt(n+1)===35){const r=e.src.slice(n).match(Po);if(r){if(!t){const o=r[1][0].toLowerCase()==="x"?parseInt(r[1].slice(1),16):parseInt(r[1],10),s=e.push("text_special","",0);s.content=Pt(o)?We(o):We(65533),s.markup=r[0],s.info="entity"}return e.pos+=r[0].length,!0}}else{const r=e.src.slice(n).match(zo);if(r){const o=Ln(r[0]);if(o!==r[0]){if(!t){const s=e.push("text_special","",0);s.content=o,s.markup=r[0],s.info="entity"}return e.pos+=r[0].length,!0}}}return!1}function _n(e){const t={},n=e.length;if(!n)return;let i=0,r=-2;const o=[];for(let s=0;s<n;s++){const A=e[s];if(o.push(0),(e[i].marker!==A.marker||r!==A.token-1)&&(i=s),r=A.token,A.length=A.length||0,!A.close)continue;t.hasOwnProperty(A.marker)||(t[A.marker]=[-1,-1,-1,-1,-1,-1]);const a=t[A.marker][(A.open?3:0)+A.length%3];let l=i-o[i]-1,u=l;for(;l>a;l-=o[l]+1){const d=e[l];if(d.marker===A.marker&&d.open&&d.end<0){let g=!1;if((d.close||A.open)&&(d.length+A.length)%3===0&&(d.length%3!==0||A.length%3!==0)&&(g=!0),!g){const h=l>0&&!e[l-1].open?o[l-1]+1:0;o[s]=s-l+h,o[l]=h,A.open=!1,d.end=s,d.close=!1,u=-1,r=-2;break}}}u!==-1&&(t[A.marker][(A.open?3:0)+(A.length||0)%3]=u)}}function Xo(e){const t=e.tokens_meta,n=e.tokens_meta.length;_n(e.delimiters);for(let r=0;r<n;r++){var i;const o=(i=t[r])===null||i===void 0?void 0:i.delimiters;o&&_n(o)}}function qo(e){let t,n,i=0;const r=e.tokens,o=e.tokens.length;for(t=n=0;t<o;t++)r[t].nesting<0&&i--,r[t].level=i,r[t].nesting>0&&i++,r[t].type==="text"&&t+1<o&&r[t+1].type==="text"?r[t+1].content=r[t].content+r[t+1].content:(t!==n&&(r[n]=r[t]),n++);t!==n&&(r.length=n)}var Yt=[["text",_o],["linkify",So],["newline",Qo],["escape",Ko],["backticks",Ro],["strikethrough",hr.tokenize],["emphasis",gr.tokenize],["link",Jo],["image",Zo],["autolink",Uo],["html_inline",To],["entity",jo]],Gt=[["balance_pairs",Xo],["strikethrough",hr.postProcess],["emphasis",gr.postProcess],["fragments_join",qo]],fr=class{constructor(){F(this,"ruler",new Ne),F(this,"ruler2",new Ne),F(this,"State",dr);for(let e=0;e<Yt.length;e++)this.ruler.push(Yt[e][0],Yt[e][1]);for(let e=0;e<Gt.length;e++)this.ruler2.push(Gt[e][0],Gt[e][1])}skipToken(e){const t=e.pos,n=this.ruler.getRules(""),i=n.length,r=e.md.options.maxNesting,o=e.cache;if(typeof o[t]<"u"){e.pos=o[t];return}let s=!1;if(e.level<r){for(let A=0;A<i;
16A++)if(e.level++,s=n[A](e,!0),e.level--,s){if(t>=e.pos)throw new Error("inline rule didn't increment state.pos");break}}else e.pos=e.posMax;s||e.pos++,o[t]=e.pos}tokenize(e){const t=this.ruler.getRules(""),n=t.length,i=e.posMax,r=e.md.options.maxNesting;for(;e.pos<i;){const o=e.pos;let s=!1;if(e.level<r){for(let A=0;A<n;A++)if(s=t[A](e,!1),s){if(o>=e.pos)throw new Error("inline rule didn't increment state.pos");break}}if(s){if(e.pos>=i)break;continue}e.pending+=e.src[e.pos++]}e.pending&&e.pushPending()}parse(e,t,n,i){const r=new this.State(e,t,n,i);this.tokenize(r);const o=this.ruler2.getRules(""),s=o.length;for(let A=0;A<s;A++)o[A](r)}},Vo={default:{options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:100},components:{core:{},block:{},inline:{}}},zero:{options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","strip_references","inline","text_join"]},block:{rules:["paragraph"]},inline:{rules:["text"],rules2:["balance_pairs","fragments_join"]}}},commonmark:{options:{html:!0,xhtmlOut:!0,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","strip_references","inline","text_join"]},block:{rules:["blockquote","code","fence","heading","hr","html_block","lheading","list","reference","paragraph"]},inline:{rules:["autolink","backticks","emphasis","entity","escape","html_inline","image","link","newline","text"],rules2:["balance_pairs","emphasis","fragments_join"]}}}},es=/^(vbscript|javascript|file|data):/,ts=/^data:image\/(gif|png|jpeg|webp);/,xn=["http:","https:","mailto:"],ae=class{validateLink(e){const t=e.trim().toLowerCase();return es.test(t)?ts.test(t):!0}normalizeLink(e){const t=Ht(e,!0);if(t.hostname&&(!t.protocol||xn.indexOf(t.protocol)>=0))try{t.hostname=bn.toASCII(t.hostname)}catch{}return $e(Zt(t))}normalizeLinkText(e){const t=Ht(e,!0);if(t.hostname&&(!t.protocol||xn.indexOf(t.protocol)>=0))try{t.hostname=bn.toUnicode(t.hostname)}catch{}return Ee(Zt(t),Ee.defaultChars+"%")}constructor(...e){F(this,"inline",new fr),F(this,"block",new ur),F(this,"core",new Ar),F(this,"renderer",new ir),F(this,"linkify",new hi),F(this,"utils",Fi),F(this,"helpers",Object.assign({},Zi));const[t,n]=e;typeof t=="string"?(this.configure(t),n&&this.set(n)):(this.configure("default"),this.set(t||{}))}set(e){return Object.assign(this.options,e),this}configure(e){let t;if(typeof e=="string"){const r=e;if(t=Vo[r],!t)throw new Error(`Wrong 'markdown-it' preset "${r}", check name`)}else t=e;if(!t)throw new Error("Wrong `markdown-it` preset, can't be empty");t.options&&(this.options={...t.options});const n=t.components;if(n){var i;["core","block","inline"].forEach(o=>{var s;const A=(s=n[o])===null||s===void 0?void 0:s.rules;A&&this[o].ruler.enableOnly(A)});const r=(i=n.inline)===null||i===void 0?void 0:i.rules2;
16r&&this.inline.ruler2.enableOnly(r)}return this}enable(e,t=!1){let n=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(r=>{n=n.concat(this[r].ruler.enable(e,!0))}),n=n.concat(this.inline.ruler2.enable(e,!0));const i=e.filter(r=>n.indexOf(r)<0);if(i.length&&!t)throw new Error(`MarkdownIt. Failed to enable unknown rule(s): ${i}`);return this}disable(e,t=!1){let n=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(r=>{n=n.concat(this[r].ruler.disable(e,!0))}),n=n.concat(this.inline.ruler2.disable(e,!0));const i=e.filter(r=>n.indexOf(r)<0);if(i.length&&!t)throw new Error(`MarkdownIt. Failed to disable unknown rule(s): ${i}`);return this}use(e,...t){return e.apply(e,[this,...t]),this}parse(e,t){if(typeof e!="string")throw new Error("Input data should be a String");const n=new this.core.State(e,this,t);return this.core.process(n),n.tokens}render(e,t={}){return this.renderer.render(this.parse(e,t),this.options,t)}parseInline(e,t){const n=new this.core.State(e,this,t);return n.inlineMode=!0,this.core.process(n),n.tokens}renderInline(e,t={}){return this.renderer.render(this.parseInline(e,t),this.options,t)}};F(ae,"Token",Ie);F(ae,"Ruler",Ne);F(ae,"Renderer",ir);F(ae,"ParserCore",Ar);F(ae,"StateCore",or);F(ae,"ParserBlock",ur);F(ae,"StateBlock",ar);F(ae,"ParserInline",fr);F(ae,"StateInline",dr);var ns=er(ae);const rs=new ns({html:!1,breaks:!0,linkify:!1,typographer:!1}),is=new Set(["http:","https:","mailto:"]);function os(e){for(const t of Array.from(e.querySelectorAll("*"))){for(const n of Array.from(t.attributes))n.name.toLowerCase().startsWith("on")&&t.removeAttribute(n.name);if(t instanceof HTMLAnchorElement){const i=(t.getAttribute("href")??"").trim();if(!i)t.removeAttribute("href");else try{const r=new URL(i,"https://example.invalid");is.has(r.protocol)?(t.setAttribute("target","_blank"),t.setAttribute("rel","noreferrer noopener")):t.removeAttribute("href")}catch{t.removeAttribute("href")}}}}function ss(e){const t=document.createElement("template");return t.innerHTML=rs.render(String(e??"")),os(t.content),t.content}function As(e,t){e.replaceChildren(ss(t))}function as({fetchImpl:e=fetch,storage:t=sessionStorage}={}){const n="bsv:web-auth-session";let i=null,r=null;const o=()=>{try{return JSON.parse(t.getItem(n)??"null")}catch{return null}};async function s(){return r||(r=(async()=>{const a=o()?.accessToken??o()?.access_token,l=await e("/v1/auth/reading-session",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json",...a?{Authorization:`Bearer ${a}`}:{}},body:"{}"});if(l.status!==404&&!l.ok)throw new Error("reading_session_unavailable")})()),r}async function A(){if(i)return i;const a=o();return i=(async()=>{const l=!a?.refreshToken&&!a?.refresh_token,u=await e(l?"/v1/auth/reading-session":"/v1/auth/refresh",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify(a?.refreshToken||a?.refresh_token?{refreshToken:a.refreshToken??a.refresh_token}:{})});if(!u.ok)throw t.removeItem(n),new Error("sign_in_required");const d=await u.json();if(l&&!d.user?.signedIn)throw new Error("sign_in_required");a&&d.session?t.setItem(n,JSON.stringify(d.session)):t.removeItem(n)})().finally(()=>{i=null}),i}return async function a(l,u="GET",d,g=!0){l==="/config"&&await s();const h=o(),c=Number(h?.expiresAt??h?.expires_at??0);g&&c&&(c<1e10?c*1e3:c)<=Date.now()+6e4&&await A();const b=o()?.accessToken??o()?.access_token,m={"Content-Type":"application/json"};b&&(m.Authorization=`Bearer ${b}`),l==="/membership/checkout"&&typeof d?.clientOperationId=="string"&&(m["Idempotency-Key"]=d.clientOperationId);const D=await e(l==="/membership/portal"?"/v1/creem/portal":`/v2/reading${l}`,{method:u,credentials:"include",headers:m,body:d===void 0?void 0:JSON.stringify(d)});if(D.status===401&&g)return await A(),a(l,u,d,!1);const C=await D.json().catch(()=>({code:"reading_service_unavailable"}));if(!D.ok)throw new Error(C.code??"reading_service_unavailable");return C}}const Sn=e=>e.replace(/[&<>"']/g,t=>({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"})[t]);function pr(e,t){let n="";
16try{const r=new URL(t??"");r.protocol==="https:"&&!r.username&&!r.password&&!r.port&&["yt3.ggpht.com","yt3.googleusercontent.com"].includes(r.hostname)&&(n=r.href.replace(/=s\d+(?=-|$)/,"=s96"))}catch{}const i=e.trim().split(/\s+/).slice(0,2).map(r=>[...r][0]??"").join("");return`<span class="creator-avatar creator-initials" aria-hidden="true">${Sn(i)}${n?`<img src="${Sn(n)}" alt="" loading="lazy" referrerpolicy="no-referrer">`:""}</span>`}function mr(e){const t=e.target;t instanceof HTMLImageElement&&t.parentElement?.classList.contains("creator-avatar")&&t.remove()}const ot=e=>String(e??"").replace(/[&<>"']/g,t=>({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"})[t]);function Qn(e){const t=e.message;return["invalid_creator_query","invalid_channel_handle","invalid_creator_link"].includes(t)?"Enter a channel name or a YouTube link.":t==="membership_required"?"Membership is needed to add a new channel.":t==="sign_in_required"?"Sign in to follow this channel.":["channel_search_busy","source_rate_limited"].includes(t)?"YouTube search is busy. Try again in a minute.":"Couldn’t reach YouTube. Try again, or choose an available channel."}function ls(e){if(e.parent.querySelector(".creator-finder"))return;const t=document.activeElement,n=document.createElement("dialog");n.className="creator-finder",n.setAttribute("aria-labelledby","creator-finder-title");const i=e.member&&e.available;n.innerHTML=`<button class="close icon-button" type="button" aria-label="Close channel search">×</button>
17    <h2 id="creator-finder-title">Who to follow</h2>
18    <p class="creator-sharing">Follow together. Split new-video generation time with other members.</p>
19    <form class="creator-search"><label for="creator-query">${i?"Name or YouTube link":"Search available channels"}</label>
20    <div class="creator-search-field"><input id="creator-query" name="query" type="search" placeholder="${i?"Search YouTube or paste a video link":"Channel name"}" maxlength="600" required autocomplete="off"><button class="button primary" type="submit">Search</button></div></form>
21    ${i?"":`<p class="creator-access">${e.available?'Find more channels with <a href="/pricing">Membership ↗</a>':"YouTube search is temporarily unavailable."}</p>`}
22    <p class="creator-status" role="status" aria-live="polite"></p>
23    <div class="creator-result-heading"><h3>In BingeRead</h3><button class="text-link creator-reset" type="button" hidden>Browse channels</button></div>
24    <div class="creator-results"></div>`,e.parent.append(n);const r=n.querySelector("form"),o=n.querySelector("input"),s=r.querySelector("button"),A=n.querySelector(".creator-status"),a=n.querySelector(".creator-results"),l=n.querySelector(".creator-result-heading h3"),u=n.querySelector(".creator-reset");let d=0,g=!1,h=[];const c=C=>e.channels().find(k=>k.platform_id===C.platformId),b=()=>e.channels().map(C=>({platformId:C.platform_id,title:C.title,avatar:C.avatar_url,url:`https://www.youtube.com/channel/${C.platform_id}`}));function m(C){h=C,a.innerHTML=C.map((k,p)=>{const f=c(k),I=f||i;return`<section class="creator-result">${pr(k.title,k.avatar||f?.avatar_url)}
25        <div class="creator-identity"><h4>${ot(k.title)}</h4><a href="${ot(k.url)}" target="_blank" rel="noopener noreferrer">${ot(k.handle??"YouTube channel")} ↗</a></div>
26        ${I?`<button class="button creator-follow" data-index="${p}" type="button" aria-pressed="${!!f?.following}" aria-label="${f?.following?"Unfollow":"Follow"} ${ot(k.title)}" title="${f?.following?"Unfollow":"Follow"}"><span class="follow-label">${f?.following?"Following ✓":"Follow +"}</span>${f?.following?'<span class="unfollow-label" aria-hidden="true">Unfollow</span>':""}</button>`:'<a class="text-link" href="/pricing">Membership ↗</a>'}</section>`}).join("")}function D(){d++,s.disabled=!1,a.removeAttribute("aria-busy"),o.value="",l.textContent="In BingeRead",u.hidden=!0,A.textContent="",m(b().slice(0,8)),h.length||(A.textContent="Search for a channel you enjoy.")}o.addEventListener("input",()=>{if(!g){if(!o.value.trim()){D();return}d++,s.disabled=!1,a.removeAttribute("aria-busy"),m([]),l.textContent="",A.textContent="",u.hidden=!1}}),r.addEventListener("submit",async C=>
26{if(C.preventDefault(),C.stopPropagation(),g)return;const k=o.value.trim();if(k.length<2){A.textContent="Enter at least two characters.";return}const p=++d;s.disabled=!0,a.setAttribute("aria-busy","true"),m([]),l.textContent="",A.textContent=i?"Searching YouTube…":"Searching…",u.hidden=!1;try{const f=i?await e.api(`/channels/find?q=${encodeURIComponent(k)}`):b().filter(I=>I.title.toLowerCase().includes(k.toLowerCase()));if(!n.open||p!==d)return;m(f),l.textContent=i?"On YouTube":"In BingeRead",A.textContent=f.length?"":"No channels found. Try another name."}catch(f){n.open&&p===d&&(l.textContent="Available channels",m(b()),A.textContent=Qn(f))}finally{p===d&&(s.disabled=!1,a.removeAttribute("aria-busy"))}}),n.addEventListener("click",async C=>{C.stopPropagation();const k=C.target.closest("button");if(!k||k.disabled)return;if(k.classList.contains("close")){n.close();return}if(k===u){D(),o.focus();return}if(!k.classList.contains("creator-follow")||g)return;const p=h[Number(k.dataset.index)];if(!p)return;if(!e.signedIn){location.href=`/account?returnTo=${encodeURIComponent(location.pathname+location.search)}`;return}g=!0,n.querySelectorAll(".creator-follow").forEach(I=>{I.disabled=!0}),s.disabled=!0,u.disabled=!0;const f=!!c(p)?.following;A.textContent=`${f?"Unfollowing":"Following"} ${p.title}…`;try{const I=c(p)??await e.api("/channels","POST",{handle:p.platformId});if(e.added({...I,platform_id:p.platformId,title:p.title,avatar_url:I.avatar_url||p.avatar||null,article_count:I.article_c
26ount??0,following:!!I.following}),!await(f?e.unfollow(I.id):e.follow(I.id))){A.textContent="",m(h);return}if(!n.open||(m(h),A.textContent=`${f?"Unfollowed":"Following"} ${p.title}.`,a.querySelector(`[data-index="${k.dataset.index}"]`)?.focus(),f))return;const B=document.createElement("a");B.className="text-link",B.href="/reading/?view=feed",B.textContent="View My reading →",A.append(document.createTextNode(" "),B)}catch(I){n.open&&(m(h),A.textContent=f?"Couldn’t unfollow. Try again.":Qn(I),a.querySelector(`[data-index="${k.dataset.index}"]`)?.focus())}finally{g=!1,s.disabled=!1,u.disabled=!1}}),n.addEventListener("error",mr,!0),n.addEventListener("close",()=>{d++,n.remove(),t?.isConnected&&t.focus()},{once:!0}),D(),n.showModal(),o.focus()}function cs(e,t=Date.now){const n=new Map,i=new Map;let r=0;return{clear(){r++,n.clear(),i.clear()},invalidate(o){r++;for(const s of n.keys())s.startsWith(o)&&n.delete(s);for(const s of i.keys())s.startsWith(o)&&i.delete(s)},async get(o){const s=n.get(o);if(s&&s.until>t())return s.value;if(i.has(o))return i.get(o);const A=r,a=e(o).then(l=>(A===r&&(n.size>=30&&n.delete(n.keys().next().value),n.set(o,{until:t()+3e4,value:l})),l)).finally(()=>{i.get(o)===a&&i.delete(o)});return i.set(o,a),a}}}const Cr=[{code:"en",english:"English",native:"English",aliases:["英语"]},{code:"zh-Hans",english:"Chinese (Simplified)",native:"简体中文",aliases:["中文","简中","simplified chinese"]},{code:"zh-Hant",english:"Chinese (Traditional)",native:"繁體中文",aliases:["繁中","traditional chinese"]},{code:"ja",english:"Japanese",native:"日本語",aliases:["日语"]},{code:"ko",english:"Korean",native:"한국어",aliases:["韩语"]},{code:"de",english:"German",native:"Deutsch",aliases:["德语"]},{code:"fr",english:"French",native:"Français",aliases:["法语"]},{code:"es",english:"Spanish",native:"Español",aliases:["西班牙语"]},{code:"it",english:"Italian",native:"Italiano",aliases:["意大利语"]},{code:"pt-BR",english:"Portuguese (Brazil)",native:"Português (Brasil)",aliases:["葡萄牙语","巴西葡语"]},{code:"nl",english:"Dutch",native:"Nederlands",aliases:["荷兰语"]},{code:"pl",english:"Polish",native:"Polski",aliases:["波兰语"]},{code:"tr",english:"Turkish",native:"Türkçe",aliases:["土耳其语"]},{code:"ru",english:"Russian",native:"Русский",aliases:["俄语"]},{code:"ar",english:"Arabic",native:"العربية",aliases:["阿拉伯语"]},{code:"hi",english:"Hindi",native:"हिन्दी",aliases:["印地语"]},{code:"vi",english:"Vietnamese",native:"Tiếng Việt",aliases:["越南语"]},{code:"id",english:"Indonesian",native:"Bahasa Indonesia",aliases:["印尼语"]},{code:"th",english:"Thai",native:"ไทย",aliases:["泰语"]}],jt=Cr.map(e=>({code:e.code.toLowerCase(),label:e.native})),br=e=>jt.find(t=>t.code===e.toLowerCase())?.label??e,wr=e=>jt.map(t=>`<option value="${t.code}" ${t.code===e?"selected":""}>${t.label}</option>`).join("");function kr(e,t,n="Follow"){return new Promise(i=>{const r=document.createElement("dialog");r.className="reading-language-dialog",r.setAttribute("aria-labelledby","first-language-title");const o=navigator.language.toLowerCase(),s=o.startsWith("zh")?/hant|-(tw|hk|mo)$/.test(o)?"zh-hant":"zh-hans":jt.find(A=>A.code===o||A.code===o.split("-")[0])?.code??"en";r.innerHTML=`<form method="dialog"><h2 id="first-language-title">Read in your language.</h2><label for="first-reading-language">Reading language</label><select id="first-reading-language" name="language">${wr(s)}</select><p>You can change this in Settings.</p>${t?'<p class="small">New videos from channels you follow use your processing allowance.</p>':""}<div class="dialog-actions"><button value="cancel">Cancel</button><button class="primary" value="follow">${n}</button></div></form>`,e.append(r),r.addEventListener("close",()=>{const A=r.returnValue==="follow"?r.querySelector("select").value:null;r.remove(),i(A)},{once:!0}),r.showModal()})}const yr="bsv:reading:language:v1",st="bsv:reading:pending-save:v1",us=1800*1e3;function Ir(e,t,n){if(n)return e.find(r=>r.id===n);let i=null;try{i=t.getItem(yr)}catch{}return e.find(r=>r.language===i)??e.find(r=>r.language==="en")??e[0]}function Ue(e,t){if(Cr.some(n=>n.code.toLowerCase()===t.toLowerCase()))try{e.setItem(yr,t)}catch{}}function ds(e,t,n,i,r=Date.now()){e.setItem(st,JSON.stringify({article:t,ver
26sion:n,token:i,expires:r+us}))}function hs(e,t,n,i,r=Date.now()){try{const o=JSON.parse(e.getItem(st)??"null");return o?typeof o.expires!="number"||o.expires<=r?(e.removeItem(st),!1):!i||o.token!==i||o.article!==t||o.version!==n?!1:(e.removeItem(st),!0):!1}catch{return!1}}function gs(e){const t=Array.from(String(e??"").normalize("NFC")).filter(r=>r.codePointAt(0)>=32&&r.codePointAt(0)!==127).join("").replace(/[<>:"/\\|?*]/g,"-").replace(/\s+/g," ").trim(),n=new TextEncoder;let i="";for(const r of t){if(n.encode(i+r).length>180)break;i+=r}return i=i.replace(/[. ]+$/,"")||"Manuscript",/^(con|prn|aux|nul|com[1-9]|lpt[1-9])(?:\.|$)/i.test(i)&&(i="_"+i),`${i}.md`}function Dr(e){return e==="manuscript"?"manuscript":"video"}function Kn(e){const t=Number(e);return Number.isFinite(t)&&t>=640&&t<=1040?Math.round(t):800}function lt(e){try{return localStorage.getItem(e)}catch{return null}}function ne(e,t){try{localStorage.setItem(e,t)}catch{}}function fs(e){if(!e)return null;const t=new Date(e);return Number.isFinite(t.getTime())?{iso:t.toISOString(),label:t.toLocaleDateString("en-US",{year:"numeric",month:"short",day:"numeric",timeZone:"UTC"}),full:t.toLocaleString("en-GB",{timeZone:"UTC",timeZoneName:"short"})}:null}function ps(e){const t="bsv:quick-start:v1";let n={read:!1,width:!1,disabled:!1};try{const r=e.getItem(t);if(r){const o=JSON.parse(r);n={read:o?.read===!0,width:o?.width===!0,disabled:o?.disabled===!0}}else n.read=!!(e.getItem("bsv:reader-type")||e.getItem("bsv:reader-width")),n.width=!!e.getItem("bsv:reader-width")}catch{}const i=()=>{try{e.setItem(t,JSON.stringify(n))}catch{}};return i(),{shouldShow:r=>!n.disabled&&!n[r],enabled:()=>!n.disabled,complete(r){n[r]||(n[r]=!0,i())},disable(){n.disabled=!0,i()},restart(){n={read:!1,width:!1,disabled:!1},i()}}}const Fr="https://chromewebstore.google.com/detail/aojajnblmihceacbekkfgflkkenblakk",ce=ps({getItem:lt,setItem:ne});function ms(e){if(!ce.shouldShow("read"))return"";const t=e&&/^[0-9a-f-]{36}$/i.test(e)?e:null;return`<section class="first-read" aria-label="Getting started"><button class="guide-dismiss" data-dismiss-intro aria-label="Dismiss getting started">×</button><div><h2>${t?"Try your first read.":"Find your first channel."}</h2><button class="text-link" ${t?`data-article="${t}"`:"data-find-creators"}>${t?"Open a manuscript →":"Find channels →"}</button></div><div><h3>Have a video in mind?</h3><a class="text-link" href="${Fr}" target="_blank" rel="noopener noreferrer">Get the extension ↗</a></div></section>`}function Xt(e="read"){if(document.querySelector(".quick-start-dialog"))return;const t=document.activeElement,n=document.createElement("dialog");n.className="quick-start-dialog",n.setAttribute("aria-labelledby","quick-start-title");const i=[["read","Read your first manuscript","Open any available manuscript in Discover. You can start reading before signing in. Save adds it to My reading; sign in when you want to keep it."],["follow","Follow a channel","Choose a channel in Who to follow, or search by name or YouTube link. Pick your reading language the first time. Available reads appear in My reading. Members also get new videos turned into manuscripts automatically."],["extension","Read a video you found",`Use the extension on a YouTube or Bilibili video. Refresh a video tab that was already open when you installed it. Open an available manuscript or choose Generate, then Reader. <a href="${Fr}" target="_blank" rel="noopener noreferrer">Get the extension ↗</a>`],["reader","Make Reader yours","Use Aa for text size, spacing and themes. On a wide screen, drag either paper edge to resize; double-click the edge to reset. Scroll down to hide the toolbar; scroll up or choose Tools to bring it back. The magnifier searches this manuscript. Focus mode clears the surrounding navigation; Esc brings it back."],["library","Find your reading again","My reading brings together saved manuscripts, reads you opened while signed in, and channels you follow. Sign in with the same account in the extension and website. Once an extension manuscript has synced, Open on web takes you straight to it. Your personal imports stay private."],["allowance","When processing time is used",'Reading an existing manuscript does not use processing time. Generating a new one does; members’ followed channels can do this automatically for new videos. 
26Choose your language and per-video limit in Settings. <a href="/pricing">Membership and reading limits ↗</a>']];n.innerHTML=`<button class="guide-close" aria-label="Close quick start">×</button><p class="guide-kicker">BingeRead</p><h2 id="quick-start-title">Quick start.</h2><div class="guide-topics">${i.map(([r,o,s])=>`<details ${r===e?"open":""}><summary>${o}</summary><p>${s}</p></details>`).join("")}</div><div class="guide-footer"><button class="text-link" data-replay-tips>Show tips again</button><button class="text-link" data-hide-tips ${ce.enabled()?"":"disabled"}>${ce.enabled()?"Hide tips":"Tips are hidden"}</button></div>`,document.body.append(n),n.querySelector(".guide-close").addEventListener("click",()=>n.close()),n.querySelector("[data-replay-tips]").addEventListener("click",()=>{ce.restart(),document.dispatchEvent(new Event("bsv:guidance-change")),n.close()}),n.querySelector("[data-hide-tips]").addEventListener("click",()=>{ce.disable(),document.dispatchEvent(new Event("bsv:guidance-change")),n.close()}),n.addEventListener("close",()=>{n.remove();const r=t?.isConnected&&t.getClientRects().length?t:document.querySelector(".reader-appearance summary, #menu");r?.getClientRects().length&&r.focus({preventScroll:!0})},{once:!0}),n.showModal()}const Cs={size:20,spacing:1.85,font:"book",contents:!0};function Wt(e){const t=e&&typeof e=="object"?e:{};return{size:typeof t.size=="number"&&Number.isFinite(t.size)?Math.min(32,Math.max(16,Math.round(t.size))):20,spacing:[1.6,1.85,2.1].includes(Number(t.spacing))?Number(t.spacing):1.85,font:t.font==="modern"?"modern":"book",contents:t.contents!==!1}}function bs(e){const t=e.match(/[\p{Script=Han}\p{Script=Hiragana}\p{Script=Katakana}\p{Script=Hangul}]/gu)?.length??0,n=e.replace(/[\p{Script=Han}\p{Script=Hiragana}\p{Script=Katakana}\p{Script=Hangul}]/gu," ").match(/[\p{L}\p{N}]+/gu)?.length??0;return Math.max(1,Math.ceil(t/350+n/220))}function ws(e,t,n=1e3){const i=t.trim().slice(0,120);if(!i)return[];const r=i.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),o=new RegExp(r,"giu"),s=[];for(const A of e.matchAll(o))if(s.push({start:A.index,end:A.index+A[0].length}),s.length>=n)break;return s}function ks(e,t,n=!1){if(t=Math.max(0,t),n||t<160)return{y:t,direction:0,distance:0,hidden:!1};const i=t-e.y;if(Math.abs(i)<2)return e;const r=Math.sign(i),o=r===e.direction?e.distance+Math.abs(i):Math.abs(i);return{y:t,direction:r,distance:o,hidden:r>0&&o>=48?!0:r<0&&o>=16?!1:e.hidden}}function Rn(e,t,n,i){const r=Math.max(640,Math.min(1040,Math.floor(i)));return Math.round(Math.max(640,Math.min(r,e+t*(n==="right"?2:-2))))}function ys(e,t){const n=matchMedia("(max-width: 820px)"),i=e.querySelector("#reader-tools"),r=e.querySelector(".reader-aside"),o=e.querySelector("#toc"),s=i.querySelector("#reader-toggle-contents"),A=i.querySelector(".reader-appearance"),a=A.querySelector(".appearance-popover"),l=e.querySelector(".reader-toolbar > .actions"),u=i.querySelector("#reader-find-toggle"),d=i.querySelector("#reader-focus"),g=e.querySelector(".reader-toolbar > .text-link");g.setAttribute("aria-label","Back to reading"),g.innerHTML='<span class="reader-back-full">← Back to reading</span><span class="reader-back-short">← Library</span>';const h=document.createElement("button");h.className="reader-tool reader-more",h.textContent="•••",h.setAttribute("aria-label","More reading tools"),h.setAttribute("aria-haspopup","dialog"),i.append(h);const c=document.createElement("dialog");c.className="reader-sheet",c.setAttribute("aria-labelledby","reader-sheet-title"),c.innerHTML='<div class="reader-sheet-heading"><h2 id="reader-sheet-title"></h2><button type="button" aria-label="Close reading panel">×</button></div><div class="reader-sheet-body"></div>',e.append(c);const b=c.querySelector(".reader-sheet-body"),m=r.querySelector("details");let D=n.matches?!0:m.open;const C=[];let k="",p="";const f=new AbortController,I={signal:f.signal};function E(v){const R=document.createComment("reader-control");v.before(R),C.push({node:v,marker:R}),b.append(v)}function B(){for(const{node:v,marker:R}of C)R.replaceWith(v);C.length=0,document.documentElement.style.overflow=p,k="",s.setAttribute("aria-pressed","fal
26se"),h.setAttribute("aria-expanded","false")}function _(){c.open&&(c.close(),B())}function Y(v){_(),t(),A.open=!1,k=v,c.dataset.panel=v,c.querySelector("h2").textContent={contents:"Contents",appearance:"Appearance",more:"Reading tools"}[v],v==="contents"&&E(o),v==="appearance"&&E(a),v==="more"&&(E(l),E(u),E(d)),s.setAttribute("aria-pressed",String(v==="contents")),h.setAttribute("aria-expanded",String(v==="more")),p=document.documentElement.style.overflow,document.documentElement.style.overflow="hidden",c.showModal()}e.addEventListener("click",v=>{if(!n.matches)return;const R=v.target;R.closest("#reader-toggle-contents")?(v.preventDefault(),v.stopImmediatePropagation(),Y("contents")):R.closest(".reader-appearance > summary")?(v.preventDefault(),v.stopImmediatePropagation(),Y("appearance")):R.closest(".reader-more")?(v.preventDefault(),v.stopImmediatePropagation(),Y("more")):R.closest(".reader-sheet-heading button")||R===c&&(()=>{const V=c.getBoundingClientRect();return v.clientX<V.left||v.clientX>V.right||v.clientY<V.top||v.clientY>V.bottom})()?(v.preventDefault(),v.stopImmediatePropagation(),_()):c.open&&R.closest("[data-anchor],#reader-find-toggle,#reader-focus,#reader-quick-start,#export")&&_()},{...I,capture:!0}),c.addEventListener("cancel",v=>{v.preventDefault(),_()},I);const Z=()=>{_(),n.matches?(D=m.open||D,m.open=!1,s.setAttribute("aria-pressed","false")):(m.open=D,s.setAttribute("aria-pressed",String(!r.hidden)))};return n.addEventListener("change",Z,I),n.matches&&Z(),{get open(){return c.open},get compact(){return n.matches},get contentsOpen(){return k==="contents"},dispose(){_(),f.abort(),c.remove(),h.remove()}}}function Is(e,t,n){const i=e.querySelector("#reader-tools"),r=e.querySelector(".reader-toolbar"),o=e.querySelector(".reader-aside"),s=e.querySelector(".reader-document"),A=!!o.querySelector(".toc button");let a=Wt(null);try{a=Wt(JSON.parse(lt("bsv:reader-type")??"null"))}catch{}let l=Kn(lt("bsv:reader-width")),u=!1,d=!1,g=0,h=0,c={y:window.scrollY,direction:0,distance:0,hidden:!1},b=!1,m=!1,D,C=null;const k=document.documentElement.style.overflowAnchor;document.documentElement.style.overflowAnchor="none";let p,f=[],I=-1;const E=new AbortController,B={signal:E.signal};i.innerHTML=`<button class="reader-tool" id="reader-toggle-contents" aria-label="Toggle contents" title="Contents" aria-pressed="true">☷</button>
27    <button class="reader-tool" id="reader-find-toggle" aria-label="Find in manuscript" title="Find in manuscript (/)" aria-expanded="false" aria-controls="reader-find">⌕</button>
28    <details class="reader-appearance"><summary aria-label="Reading appearance" title="Reading appearance">Aa</summary><div class="appearance-popover">
29      <div class="appearance-row"><span>Text size</span><div class="size-control"><button id="reader-smaller" aria-label="Smaller text">A−</button><output id="reader-size" aria-live="polite"></output><button id="reader-larger" aria-label="Larger text">A+</button></div></div>
30      <label class="appearance-row">Typeface<select id="reader-font" aria-label="Typeface"><option value="book">Book</option><option value="modern">Modern</option></select></label>
31      <label class="appearance-row">Line spacing<select id="reader-spacing" aria-label="Line spacing"><option value="1.6">Compact</option><option value="1.85">Comfortable</option><option value="2.1">Spacious</option></select></label>
32      <div class="appearance-width"><label for="reader-width">Page width</label><input id="reader-width" type="range" min="640" max="1040" step="1" value="${l}"></div>
33      <div class="reader-themes" role="group" aria-label="Reading theme"><button data-reader-theme="light" class="theme-paper">Paper</button><button data-reader-theme="sepia" class="theme-sepia">Sepia</button><button data-reader-theme="dark" class="theme-dark">Night</button></div>
34      <button class="text-link appearance-reset" id="reset-reader-style">Reset appearance</button>
35      <button class="text-link appearance-reset" id="reader-quick-start">Reading tips →</button>
36    </div></details>
37    <button class="reader-tool" id="reader-focus" aria-label="Focus mode" title="Focus mode (F)" aria-pressed="false">⛶</button>`,r.insertAdjacentHTML("beforeend",'<div class="reader-find" id="reader-find" hidden>
37<input type="search" id="reader-query" aria-label="Find in manuscript" placeholder="Find in manuscript…" maxlength="120"><output id="reader-find-count" role="status"></output><button id="reader-find-prev" aria-label="Previous match">↑</button><button id="reader-find-next" aria-label="Next match">↓</button><button id="reader-find-close" aria-label="Close find">×</button></div><div class="reader-meter"><span id="reader-position"></span><button class="text-link" id="reader-top" aria-label="Back to article top">↑ Top</button></div><div class="reader-progress" role="progressbar" aria-label="Reading progress" aria-valuemin="0" aria-valuemax="100" aria-valuenow="0"><span></span></div>');const _=i.querySelector("details"),Y=r.querySelector("#reader-find"),Z=Y.querySelector("input"),v=Y.querySelector("output"),R=i.querySelector("#reader-find-toggle"),V=i.querySelector("#reader-toggle-contents"),j=i.querySelector("#reader-focus"),Te=r.querySelector(".reader-progress"),Rr=r.querySelector("#reader-position"),tn=bs(t.innerText);r.id="reader-toolbar",r.tabIndex=-1;const ee=document.createElement("button");ee.className="reader-show-tools",ee.textContent="Tools ↓",ee.setAttribute("aria-label","Show reading tools"),ee.setAttribute("aria-controls",r.id),ee.hidden=!0,e.append(ee);const Pe=["left","right"].map(y=>{const w=document.createElement("div");return w.className=`reader-resize-edge is-${y}`,w.dataset.side=y,w.innerHTML=`<button class="reader-resize-handle" role="separator" aria-orientation="vertical" aria-label="Resize reading width from ${y} edge" aria-valuemin="640" aria-valuemax="1040" aria-valuenow="${l}" title="Drag to resize · Double-click to reset"><span aria-hidden="true"></span></button>`,s.append(w),w});V.hidden=!A;function It(){if(s.querySelectorAll(".reader-edge-tip").forEach(w=>w.remove()),!ce.shouldShow("width"))return;const y=document.createElement("span");y.className="reader-edge-tip",y.textContent="Drag to resize",y.setAttribute("aria-hidden","true"),Pe[1].querySelector("button").append(y)}function Dt(){ce.complete("width"),It()}It(),document.addEventListener("bsv:guidance-change",It,B);function Fe(){c={y:window.scrollY,direction:0,distance:0,hidden:!1},e.classList.remove("reader-controls-hidden"),r.inert=!1,ee.hidden=!0,n(),X()}function Yr(){if(m||C){c.y=window.scrollY,X();return}const y=_.open||!Y.hidden||!!D?.open||b&&r.contains(document.activeElement);c=ks(c,window.scrollY,y),e.classList.toggle("reader-controls-hidden",c.hidden),r.inert=c.hidden,ee.hidden=!c.hidden,X()}function ze(){const y=s.parentElement,w=parseFloat(getComputedStyle(y).columnGap)||0;return y.clientWidth-(o.hidden?0:o.getBoundingClientRect().width+w)}function nn(){ne("bsv:reader-type",JSON.stringify(a))}function Ft(){e.style.setProperty("--reader-width",l+"px"),e.style.setProperty("--reader-font-size",a.size+"px"),e.style.setProperty("--reader-line-height",String(a.spacing)),e.dataset.readerFont=a.font,o.hidden=!A||!a.contents||u,V.setAttribute("aria-pressed",String(D?.compact?D.contentsOpen:!o.hidden)),e.querySelector("#reader-size").textContent=String(a.size),e.querySelector("#reader-smaller").disabled=a.size<=16,e.querySelector("#reader-larger").disabled=a.size>=32,e.querySelector("#reader-font").value=a.font,e.querySelector("#reader-spacing").value=String(a.spacing),e.querySelector("#reader-width").value=String(l);for(const w of Pe){const W=w.querySelector("button");W.setAttribute("aria-valuenow",String(l)),W.setAttribute("aria-valuetext",`${l} pixels`)}const y=document.documentElement.dataset.theme??"light";e.querySelectorAll("[data-reader-theme]").forEach(w=>w.setAttribute("aria-pressed",String(w.dataset.readerTheme===y)))}function Gr(){if(d)return;const y=t.getBoundingClientRect(),w=r.getBoundingClientRect().bottom+20,W=Math.max(100,innerHeight-w),H=Math.min(100,Math.max(0,Math.round((w-y.top)/Math.max(1,y.height-W)*100)));Te.setAttribute("aria-valuenow",String(H)),Te.style.setProperty("--read-progress",H+"%"),Rr.textContent=H>=100?"100% · Finished":H===0?`~${tn} min read`:`${H}% · ~${Math.max(1,Math.ceil(tn*(1-H/100)))} min left`,r.querySelector("#reader-top").hidden=H===0}function X(){cancelAnimationFrame(g),g=requestAnimationFrame(Gr)}function he(y){m=!0;const w=r.getBoundingClientRect().bottom+20,W=[...t.querySelectorAll("[id]")].find(te=>!te.hidden&&te.getClientRects().length&&te.getBoundingClientRect().bottom>w),H=W?W.getBoundingClientRect().top-w:0,Ve=t.getBoundingClientRect().top<w;y(),Ft();const N=()=>{d||(Ve&&W&&window.scrollBy({top:W.getBoundingClientRect().top-(r.getBoundingClientRect().bottom+20)-H,behavior:"instant"}),n(),X())};N(),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{N(),c.y=window.scrollY,m=!1})}function je(){he(()=>{u=!u,document.documentElement.classList.toggle("reader-focused",u),j.setAttribute("aria-pressed",String(u)),j.setAttribute("aria-label",u?"Exit focus mode":"Focus mode"),j.title=u?"Exit focus mode (Esc)":"Focus mode (F)",j.textContent=u?"↙":"⛶"})}function Bt(){t.querySelectorAll("mark[data-reader-match]").forEach(y=>{const w=y.parentNode;y.replaceWith(document.createTextNode(y.textContent??"")),w?.normalize()}),f=[],I=-1}function Xe(){v.textContent=Z.value.trim()?f.length?`${I+1} / ${f.length}${f.length===1e3?"+":""}`:"No matches":"";for(const y of["#reader-find-prev","#reader-find-next"])Y.querySelector(y).disabled=!f.length}function qe(y){f[I]?.forEach(w=>w.classList.remove("current-match")),I=f.length?(y+f.length)%f.length:-1,f[I]?.forEach(w=>w.classList.add("current-match")),f[I]?.[0]?.scrollIntoView({block:"center",behavior:"instant"}),Xe(),X()}function rn(){if(clearTimeout(p),p=void 0,Bt(),!Z.value.trim()){Xe();return}const y=document.createTreeWalker(t,NodeFilter.SHOW_TEXT,{acceptNode(N){return N.parentElement?.closest("[hidden],script,style")?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT}});let w="",W=null;const H=[];for(;y.nextNode();){const N=y.currentNode,te=N.parentElement?.closest("p,li,h1,h2,h3,h4,h5,h6,pre,td,th,blockquote")??null;W!==te&&(w+=`
38`),W=te;const Et=w.length;w+=N.data,H.push({node:N,start:Et,end:w.length})}const Ve=ws(w,Z.value);f=Ve.map(()=>[]);for(const{node:N,start:te,end:Et}of H){const An=Ve.map((le,tt)=>({...le,index:tt})).filter(le=>le.start<Et&&le.end>te);if(!An.length)continue;const et=document.createDocumentFragment();let _t=0;for(const le of An){const tt=Math.max(0,le.start-te),an=Math.min(N.length,le.end-te);et.append(document.createTextNode(N.data.slice(_t,tt)));const nt=document.createElement("mark");nt.dataset.readerMatch=String(le.index),nt.textContent=N.data.slice(tt,an),et.append(nt),f[le.index].push(nt),_t=an}et.append(document.createTextNode(N.data.slice(_t))),N.replaceWith(et)}qe(0)}function vt(){clearTimeout(p),Bt(),Z.value="",Y.hidden=!0,R.setAttribute("aria-expanded","fal
38se"),Xe(),X()}function on(){Fe(),_.open=!1,Y.hidden=!1,R.setAttribute("aria-expanded","true"),Z.focus(),Z.select(),Xe(),X()}e.addEventListener("click",y=>{const w=y.target.closest("button");if(w&&!(!i.contains(w)&&!w.closest(".appearance-popover"))){if(w.id==="reader-quick-start"){_.open=!1,Xt("reader");return}if(w.id==="reader-find-toggle"){Y.hidden?on():vt();return}if(w.id==="reader-focus"){je();return}he(()=>{w.id==="reader-toggle-contents"&&(u?(je(),a.contents=!0):a.contents=!a.contents,a.contents&&(o.querySelector("details").open=!0)),w.id==="reader-smaller"&&(a.size=Math.max(16,a.size-2)),w.id==="reader-larger"&&(a.size=Math.min(32,a.size+2)),w.id==="reset-reader-style"&&(a={...Cs},l=800,document.documentElement.dataset.theme="light",ne("bsv:reading:theme","light"),ne("bsv:reader-width","800")),w.dataset.readerTheme&&(document.documentElement.dataset.theme=w.dataset.readerTheme,ne("bsv:reading:theme",w.dataset.readerTheme)),nn()})}},B),e.addEventListener("change",y=>{const w=y.target;(w.id==="reader-font"||w.id==="reader-spacing")&&he(()=>{w.id==="reader-font"?a.font=w.value==="modern"?"modern":"book":a.spacing=Wt({...a,spacing:Number(w.value)}).spacing,nn()})},B),e.addEventListener("input",y=>{const w=y.target;w.id==="reader-width"&&(Dt(),he(()=>{l=Kn(w.value),ne("bsv:reader-width",String(l))}))},B),Y.addEventListener("input",()=>{clearTimeout(p),p=setTimeout(rn,120)},B),Y.addEventListener("click",y=>{const w=y.target.closest("button")?.id;w==="reader-find-close"&&(vt(),R.focus()),w==="reader-find-next"&&qe(I+1),w==="reader-find-prev"&&qe(I-1)},B),Y.addEventListener("keydown",y=>{y.key==="Enter"&&(y.preventDefault(),p?(rn(),p=void 0):qe(I+(y.shiftKey?-1:1)))},B),r.querySelector("#reader-top").addEventListener("click",()=>{window.scrollTo({top:0,behavior:"instant"})},B),ee.addEventListener("click",()=>{Fe(),r.focus({preventScroll:!0})},B),_.addEventListener("toggle",()=>{_.open&&Fe()},B),r.addEventListener("focusin",Fe,B),r.addEventListener("transitionend",()=>{n(),X()},B);function Ke(y=!1){if(!C)return;const w=C;C=null,y&&he(()=>{l=w.savedWidth}),ne("bsv:reader-width",String(l)),document.documentElement.classList.remove("reader-resizing"),w.target.hasPointerCapture(w.pointer)&&w.target.releasePointerCapture(w.pointer),c.y=window.scrollY}for(const y of Pe)y.addEventListener("pointerdown",w=>{w.button!==0||C||ze()<640||(w.preventDefault(),y.setPointerCapture(w.pointerId),C={pointer:w.pointerId,x:w.clientX,width:s.getBoundingClientRect().width,savedWidth:l,side:y.dataset.side,target:y},document.documentElement.classList.add("reader-resizing"))},B),y.addEventListener("pointermove",w=>{if(!C||C.pointer!==w.pointerId)return;const W=Rn(C.width,w.clientX-C.x,C.side,ze());W!==l&&(Dt(),he(()=>{l=W}))},B),y.addEventListener("pointerup",()=>Ke(),B),y.addEventListener("pointercancel",()=>Ke(!0),B),y.addEventListener("lostpointercapture",()=>Ke(),B),y.addEventListener("dblclick",w=>{w.preventDefault(),he(()=>{l=800,ne("bsv:reader-width","800")})},B),y.addEventListener("keydown",w=>{const W=y.dataset.side;if(!["ArrowLeft","ArrowRight","Home","End"].includes(w.key))return;Dt(),w.preventDefault();const H=(w.key==="ArrowRight"?1:-1)*(w.shiftKey?40:10);he(()=>{l=w.key==="Home"?640:w.key==="End"?Math.min(1040,Math.max(640,ze())):Rn(s.getBoundingClientRect().width,H,W,ze()),ne("bsv:reader-width",String(l))})},B);document.addEventListener("pointerdown",()=>{b=!1},B),document.addEventListener("click",y=>{_.contains(y.target)||(_.open=!1)},B),document.addEventListener("keydown",y=>{if(!document.querySelector("dialog[open]")&&(b=!0,y.key==="Tab"&&c.hidden&&Fe(),!y.defaultPrevented)){if(y.key==="Escape"){if(C){Ke(!0);return}Y.hidden?_.open?(_.open=!1,_.querySelector("summary").focus()):u&&je():(vt(),R.focus());return}y.ctrlKey||y.metaKey||y.altKey||y.target?.closest("input,textarea,select,button,summary,[contenteditable=true]")||(y.key==="/"&&(y.preventDefault(),on()),y.key.toLowerCase()==="f"&&(y.preventDefault(),je()))}},B),document.querySelector("#theme")?.addEventListener("click",()=>requestAnimationFrame(Ft),B),window.addEventListener("scroll",Yr,{...B,passive:!0}),window.addEventListener("resize",X,{...B,passive:!0});const sn=new ResizeObserver(X);return sn.observe(t),D=ys(e,Fe),Ft(),X(),()=>{Ke(),D.dispose(),d=!0,E.abort(),sn.disconnect(),clearTimeout(p),cancelAnimationFrame(g),cancelAnimationFrame(h),Bt(),document.documentElement.classList.remove("reader-focused"),e.classList.remove("reader-control
38s-hidden"),ee.remove(),Pe.forEach(y=>y.remove()),document.documentElement.style.overflowAnchor=k,delete e.dataset.readerFont}}let Re;const se=document.querySelector("#app");se.addEventListener("error",mr,!0);let wt=!1,P=!1,kt="",$="discover",ct=!1,ut={channelDiscovery:!0,newProcessing:!0},q=[],T=null,ue="",dt=0,Le=0,me=!1,ht,L=0,xe=!1,ye=null,Ut="",ke=[],Br=[],gt=0;function ft(){if(!xe||!ke.length)return;const e=Math.max((document.querySelector(".reader-toolbar")?.getBoundingClientRect().bottom??0)+24,parseFloat(getComputedStyle(ke[0]).scrollMarginTop)||0)+2;let t=ke[0].id;for(const n of ke){if(n.getBoundingClientRect().top>e)break;t=n.id}window.scrollY>0&&window.scrollY+window.innerHeight>=document.documentElement.scrollHeight-4&&(t=ke[ke.length-1].id);for(const n of Br)n.dataset.anchor===t?n.setAttribute("aria-current","location"):n.removeAttribute("aria-current")}window.addEventListener("resize",()=>{cancelAnimationFrame(gt),gt=requestAnimationFrame(ft)},{passive:!0});const pt=new Map;let Lt=!0;function vr(e){Lt||location.pathname+location.search===e?history.replaceState(null,"",e):history.pushState(null,"",e)}const Q=e=>String(e??"").replace(/[&<>"']/g,t=>({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"})[t]);function M(e){const t=document.querySelector("#notice");t&&(t.textContent=e)}function qt(e){const t=document.querySelector("#notice");if(!t)return;const n=document.createElement("button");n.className="text-link",n.dataset.view="feed",n.textContent="View My reading →",t.replaceChildren(document.createTextNode(e+" "),n)}function Vt(){const e=document.querySelector("#getting-started");e&&(e.innerHTML=ms(q[0]?.id))}document.addEventListener("bsv:guidance-change",Vt);const Er=as(),Oe=cs(e=>Er(e)),x=async(e,t="GET",n)=>{if(t==="GET"&&/^\/(channels|feed|library|articles)(\?|$)/.test(e))return Oe.get(e);const i=await Er(e,t,n);return t!=="GET"&&!e.startsWith("/progress/")&&!e.endsWith("/open")&&Oe.clear(),i};let O={language:null,maxShareMs:72e5};const De=new Set;let Yn=!1;async function Gn(e){if(De.has(e))return null;De.add(e);try{const t=O.language??await kr(se,wt);if(!t)return null;const n=await x(`/channels/${e}/subscribe`,"PUT",{language:t,consentVersion:kt});O=n.preferences,Ue(localStorage,t);const i=U.find(o=>o.id===e);i&&Object.assign(i,{following:!0,auto_enabled:n.auto_enabled}),_r(e,!0);const r=document.querySelector(".sidebar");return r&&(r.outerHTML=en()),$==="feed"&&await oe("feed"),qt("Following."),n}finally{De.delete(e)}}async function Wn(e){if(De.has(e))return null;De.add(e);try{const t=await x(`/channels/${e}/follow`,"DELETE"),n=U.find(r=>r.id===e);n&&Object.assign(n,{following:!1,auto_enabled:!1}),_r(e,!1);const i=document.querySelector(".sidebar");return i&&(i.outerHTML=en()),$==="feed"&&await oe("feed"),M("Unfollowed."),t}finally{De.delete(e)}}function _r(e,t){document.querySelectorAll(`[data-follow="${CSS.escape(e)}"]`).forEach(n=>{n.classList.toggle("following",t),n.setAttribute("aria-pressed",String(t)),n.textContent=t?"Following ✓":"Follow +"})}const Ds={billing_disabled:"Membership payments aren't open yet. You can use your free reading and generation trial.",active_subscription_exists:"You already have active membership. Manage it from Account.",billing_worker_unavailable:"Checkout is temporarily unavailable. Please try again shortly.",processing_access_restricted:"New processing is currently available to invited accounts. You can still read and save available manuscripts.",sign_in_required:"Sign in to continue. Your saved library will be waiting for you.",channel_discovery_unavailable:"Adding channels is unavailable right now. You can still follow the channels already in the library.",reading_service_unavailable:"The reading service is temporarily unavailable. Please try again shortly.",new_processing_paused:"New processing is temporarily paused. Existing manuscripts remain readable.",processing_budget_paused:"New processing is temporarily paused by the service. Your existing manuscripts are still available, and no processing allowance was reserved.",task_already_started:"This job has started and will finish under its original processing allowance.",reading_allowance_used:"You’ve used your free reads for this reading window. Your saved articles are still yours to read.",membership_required:"Membership is required to add a YouTube channel or enable automatic processing. You can still follow existing channels for free.",verified_account_required:"Sign in to save and continue reading across devices.",article_unavailable:"This version is no longer available.",revision_conflict:"A newer reading position was saved on another device. Reopen the article to continue there."},Qe=e=>M(Ds[e.message]??e.message);let U=[],ve=Dr(lt("bsv:reading-sort")),Ce="all",z="",de="",At="",Mt=!1;const Mn=e=>
38new Date(e).toLocaleString("en-GB",{timeZoneName:"short"}),Jt=e=>{try{const t=new URL(e.source_url),n=t.searchParams.get("v");return["www.youtube.com","youtube.com"].includes(t.hostname)&&/^[A-Za-z0-9_-]{11}$/.test(n??"")?`https://i.ytimg.com/vi/${n}/hqdefault.jpg`:""}catch{return""}};function Jn(){se.innerHTML=`<a class="skip" href="#main">Skip to reading</a><header class="site-header"><a class="wordmark" href="/">BingeRead<span>.</span></a><nav aria-label="Main navigation"><button data-view="discover">Discover</button><button data-view="feed">My reading</button><a href="/pricing">Membership</a><button data-quick-start>Quick start</button></nav><div class="header-end"><a class="desktop-extension" href="https://chromewebstore.google.com/detail/aojajnblmihceacbekkfgflkkenblakk" target="_blank" rel="noopener noreferrer">Get the extension ↗</a><button class="account-link" data-view="account">${P?"Settings ↗":"Sign in ↗"}</button><button id="theme" class="icon-button" aria-label="Toggle reading theme">◐</button><button id="menu" class="mobile-menu icon-button" aria-expanded="false" aria-controls="mobile-nav" aria-label="Open navigation">☰</button></div></header><nav id="mobile-nav" aria-label="Mobile navigation" hidden><a href="/">Home</a><button data-quick-start>Quick start</button><button data-view="discover">Discover</button><button data-view="feed">My reading</button><a href="/pricing">Membership</a><button data-view="account">Settings</button></nav><div id="notice" role="status" aria-live="polite"></div><main id="main" tabindex="-1"></main><footer class="site-footer"><button class="text-link" data-quick-start>Quick start</button><a class="wordmark" href="/">BingeRead.</a><p>Cleaner than captions. Richer than summaries.</p><a href="/pricing" class="small">Membership</a><span>${ct?"Local preview · Test accounts":"Made for the way you read."}</span></footer>`;try{document.documentElement.dataset.theme=localStorage.getItem("bsv:reading:theme")??"light"}catch{}}const mt=e=>Number(e.duration_ms)>0?`${Math.round(Number(e.duration_ms)/6e4)} min video`:"",xr=e=>e.channel_title||(e.platform==="bilibili"?"Bilibili":"YouTube"),ge=e=>{const t=Math.max(0,Math.round(Number(e))),n=Math.floor(t/6e4),i=t%6e4/1e3;return`${n} min${i?` ${i} sec`:""}`};function Fs(e,t){const n=br(t.language),i=e.filter(o=>o.language===t.language);if(i.length===1)return n;const r=i.findIndex(o=>o.id===t.id);return r===0?`${n} · newest available`:`${n} · ${t.saved?"saved earlier copy":"earlier version"}${i.length>2?` ${r}`:""}`}function Ot(e,t,n=!1){const i=fs(e);return i?'<time datetime="'+i.iso+'" title="'+t+": "+Q(i.full)+'" aria-label="'+t+": "+Q(i.label)+'">'+(n?t+" · ":"")+Q(i.label)+"</time>":""}function Sr(e=q,t=0){return e.map((n,i)=>`<article class="article-row ${Jt(n)?"":"no-thumb"}" data-row-id="${Q(n.id)}"><span class="ordinal">${String(i+t+1).padStart(2,"0")}</span><div><p class="eyebrow">${Q(xr(n))}</p><h2><button class="title-button" data-article="${Q(n.id)}">${Q(n.title)}</button></h2><div class="meta">${Ot(n.published_at,"Video")}${mt(n)?`<span>${mt(n)}</span>`:""}<span>${Q(br(Ir(n.versions,localStorage)?.language??"en"))}</span><a href="${Q(n.source_url)}" target="_blank" rel="noopener noreferrer">Original video ↗</a></div>${$!=="discover"&&n.versions.some(r=>r.saved)?'<p class="small">Saved</p>':""}<button class="text-link" data-article="${Q(n.id)}">Read ↗</button></div>${Jt(n)?`<img src="${Jt(n)}" alt="${Q(n.channel_title??n.title)} video thumbnail" width="480" height="360" loading="lazy">`:""}</article>`).join("")}function Bs(){return ut.newProcessing?"":'<details class="context-help"><summary>Processing paused</summary><p>Existing shared reads remain available. Previously reserved jobs may still finish.</p></details>'}function Qr(e){return`<div class="actions"><button class="button follow ${e.following?"following":""}" data-follow="${e.id}" aria-pressed="${e.following}">${e.following?"Following ✓":"Follow +"}</button></div>`}function en(){const e=U.filter(i=>i.following),t=U.filter(i=>!i.following).slice(0,5),n=$==="feed"?e:t;return`<aside class="sidebar"><div class="creators-heading"><h2>${$==="feed"?"Following":"Who to follow"}</h2><button class="text-link" data-find-creators>Find channels +</button></div>${n.map(i=>`<section class="channel-mini"><h3><button class="title-button" data-channel="${i.id}">${pr(i.title,i.avatar_url)}<span>${Q(i.title)}</span></button></h3>
38${i.article_count?`<p>${i.article_count} reads</p>`:""}${Qr(i)}</section>`).join("")}${n.length?"":"<p>Find a channel you enjoy.</p>"}</aside>`}function Se(){let e=0;document.querySelectorAll("[data-row-id]").forEach(i=>{const r=q.find(o=>o.id===i.dataset.rowId);i.hidden=!r||!`${r.title} ${r.channel_title??""}`.toLowerCase().includes(de.toLowerCase()),i.hidden||e++});const t=document.querySelector("#results-count");t&&(t.textContent=`${e} ${e===1?"manuscript":"manuscripts"}`);const n=document.querySelector("#no-results");n&&(n.hidden=e!==0||!de)}async function oe(e,t=""){const n=!!T,i=yt();Re?.(),Re=void 0,M(""),clearTimeout(ht),xe=!1,T=null,$=e==="library"?"feed":["discover","feed","account"].includes(e)?e:"discover",e=$,z=e==="discover"?t:"",de="";const r=++L;if(e==="account"&&!P){location.href=`/account?returnTo=${encodeURIComponent("/reading/?view=account")}`;return}vr(`/reading/?view=${e}${z?`&channel=${encodeURIComponent(z)}`:""}${e==="feed"&&Ce==="following"?"&scope=following":""}`),document.title=`${e==="feed"?"My reading":e==="library"?"Saved":e==="account"?"Settings":"Discover"} — BingeRead`,window.scrollTo({top:0,behavior:"instant"}),document.querySelectorAll("nav [data-view]").forEach(s=>{s.classList.toggle("active",s.dataset.view===e),s.dataset.view===e?s.setAttribute("aria-current","page"):s.removeAttribute("aria-current")}),document.querySelector("#mobile-nav").hidden=!0,document.querySelector("#menu")?.setAttribute("aria-expanded","false");const o=document.querySelector("#main");if(o.classList.remove("reading-page"),o.innerHTML='<p class="loading">Opening your reading room…</p>',!P&&["feed","library"].includes(e)){o.innerHTML=`<section class="empty"><p class="eyebrow">${e==="library"?"SAVED":"MY READING"}</p><h1>${e==="library"?"A shelf of your own.":"Start with a voice you like."}</h1><p>Follow channels and keep your reading in one place.</p><div class="actions"><a class="button primary" href="/account?returnTo=${encodeURIComponent(`/reading/?view=${e}`)}">${ct?"Choose a test account":"Sign in to continue"}</a><button class="text-link" data-view="discover">Explore manuscripts →</button></div></section>`;return}try{if(e==="account"){const[g,h]=await Promise.all([x("/usage"),x("/jobs")]);if(r!==L)return;const c=g.buckets.filter(f=>new Date(f.expires_at).getTime()>Date.now()),b=f=>c.reduce((I,E)=>I+Number(E[f]),0),m=b("granted_ms"),D=b("used_ms"),C=b("reserved_ms"),k=Math.max(0,m-D-C),p={ready:"Ready to read",partial:"Translation incomplete",failed:"Couldn’t finish",cancelled:"Cancelled",queued:"Waiting to start",running:"Generating",processing:"Generating"};o.innerHTML=`<section class="page-intro"><h1>Settings.</h1>${g.member?"":`<p>${g.readingAllowance.remaining} / ${g.readingAllowance.limit} reads left</p>`}${g.member?"":`<p class="small">Next reset: ${Q(Mn(g.readingAllowance.resetsAt))}</p>`}</section><div class="account-layout"><section><div class="balance"><h2>Processing allowance</h2><div class="balance-numbers"><div><strong>${ge(k)}</strong><span>Available</span></div><div><strong>${ge(C)}</strong><span>Reserved</span></div><div><strong>${ge(D)}</strong><span>Used</span></div></div><div class="allowance-bar" role="img" aria-label="${ge(k)} available, ${ge(C)} reserved, ${ge(D)} used"><span class="available" style="width:${m?k/m*100:100}%"></span><span class="reserved" style="width:${m?C/m*100:0}%"></span><span class="used" style="width:${m?D/m*100:0}%"></span></div>${c.map(f=>`<p class="small">${f.kind==="trial"?"Generation trial":f.kind==="recovery"?"Returned allowance":"Membership allowance"}: ${ge(f.granted_ms)} · ${f.period_key==="welcome-60min-v1"?"One-time · No expiry":`Expires ${Q(Mn(f.expires_at))}`}</p>`).join("")||'<p class="small">No processing allowance on this account.</p>'}</div><section class="recent-jobs"><div class="section-rule"><h2>RECENT PROCESSING</h2><span>${h.length} jobs</span></div>${h.map(f=>`<details class="job"><summary><span><span class="job-title">${Q(f.title)}</span><span class="small">Your share: ${ge(f.share_ms)} · ${f.outcome==="settled"?"Allowance used":f.outcome==="released"?"Allowance returned":"Allowance reserved"}</span></span><span class="status">${Q(p[f.state]??"In progress")}</span></summary><p>${f.state==="partial"?"Some requested language output could not be completed. Existing completed manuscripts remain readable. ":""}${f.outcome==="released"?"Your reserved share was returned, without increasing another supporter’s share.":f.outcome==="settled"?"Your required manuscript was completed. Your original share was used; later readers pay no processing allowance.":"This share is reserved for work in progress. There is no confirmed completion time."}</p>${["ready","partial"].includes(f.state)?`<button class="text-link" data-open-id="${f.article_id}">Read available manuscript ↗</button>`:""}${f.state==="queued"&&!f.automatic?`<button class="button" data-cancel-job="${f.id}">Cancel queued job</button>`:""}</details>`).join("")||'<p class="small">No processing yet.</p>'}</section></section><aside><div class="setting"><label for="reading-preference">Reading language</label><select id="reading-preference">${wr(O.language??"en")}</select><p class="small">For new videos from channels you follow.</p>
38<details class="context-help"><summary>Processing limit</summary><label for="reading-limit">Your allowance per video</label><select id="reading-limit">${[[18e5,"30 minutes"],[36e5,"1 hour"],[72e5,"2 hours"],[144e5,"4 hours"]].map(([f,I])=>`<option value="${f}" ${Number(f)===O.maxShareMs?"selected":""}>${I}</option>`).join("")}</select></details></div><div class="setting"><p class="eyebrow">YOUR MEMBERSHIP</p><h3>${g.member?"Member":"Free reader"}</h3>${g.billing?'<button class="text-link" id="manage-reading-billing">Manage subscription ↗</button><br>':""}<a class="text-link" href="/pricing">Membership ↗</a><br><a class="text-link" href="/account?returnTo=%2Freading%2F%3Fview%3Daccount">${ct?"Switch test account ↗":"Manage account ↗"}</a></div>${Bs()}<details class="context-help"><summary>How your allowance works</summary><p>Members can generate new videos automatically from followed channels. The free trial is for manual generation. Existing shared reads use no processing time; unlocked manuscripts stay readable.</p><a href="/pricing">More questions ↗</a></details></aside></div>`;return}if(e==="feed"){if(await Promise.all([i,ye]),r!==L)return;n&&Oe.invalidate("/feed")}const s=e==="library"?"/library":e==="feed"?`/feed?scope=${Ce}`:`/articles${z?`?channel=${encodeURIComponent(z)}`:""}`,[A,a]=await Promise.all([x(`${s}${s.includes("?")?"&":"?"}sort=${ve}`),x("/channels")]);if(r!==L)return;q=A,At=A.at(-1)?.cursor??"",Mt=A.length===40,U=a;const l=U.filter(g=>g.following).length,u=e==="feed"&&Ce==="following"&&l>0,d=U.find(g=>g.id===z);if(z&&!d)throw new Error("This channel is not available. Open Discover to choose another.");if(o.innerHTML=`${d?`<section class="page-intro compact"><button class="text-link" data-view="discover">← All manuscripts</button><h1>${Q(d.title)}</h1><p>${q.length}${Mt?"+":""} reads</p>${Qr(d)}</section>`:`<section class="page-intro compact"><h1>${e==="library"?"Saved.":e==="feed"?"Your reading.":"Find your next read."}</h1></section>`}${e==="discover"&&!z?'<div id="getting-started"></div>':""}<div class="filter-bar"><label class="search"><span aria-hidden="true">⌕</span><input type="search" id="search" placeholder="Search your reads" aria-label="Search reads by title or channel"></label>${e==="discover"&&U.length?`<label class="channel-filter">Channel<select id="channel-filter"><option value="">All channels</option>${U.map(g=>`<option value="${g.id}" ${z===g.id?"selected":""}>${Q(g.title)}</option>`).join("")}</select></label>`:""}${e==="feed"?`<label class="channel-filter">Show<select id="feed-scope" aria-label="My reading filter"><option value="all" ${Ce==="all"?"selected":""}>All reads</option><option value="following" ${Ce==="following"?"selected":""}>Following only</option></select></label>`:""}<label class="sort-filter">Sort<select id="reading-sort" aria-label="Sort reads"><option value="video" ${ve==="video"?"selected":""}>Newest videos</option><option value="manuscript" ${ve==="manuscript"?"selected":""}>Newest manuscripts</option></select></label></div><div class="library-layout"><section class="article-list"><div class="section-rule"><h2>${e==="library"?"SAVED READS":"READY TO READ"}</h2><span id="results-count" role="status">${q.length} manuscripts</span></div>${Sr()}<div id="no-results" class="empty" hidden><span class="empty-symbol" aria-hidden="true">∅</span><h2>No reads found.</h2><p>Try another title or channel.</p><button class="button" id="clear-search">Clear search</button></div>${q.length?"":`<div class="empty"><h2>${e==="discover"?"No reads yet.":e==="library"?"A shelf of your own.":u?`You’re following ${l} ${l===1?"channel":"channels"}.`:"Your reading starts here."}</h2><p>${e==="discover"?"Shared reads from these channels will appear here.":e==="library"?"Save a manuscript to keep it here.":u?"New manuscripts will appear here.":"Your generated manuscripts, saved reads and followed channels appear here."}</p>${e==="discover"?"":e==="feed"?'<button class="button" data-find-creators>Find channels +</button>':'<button class="button" data-view="discover">Explore the reading room ↗</button>'}</div>`}${Mt?'<button id="more-articles" class="text-link">More manuscripts ↓</button>':""}</section>${en()}</div>`,Vt(),Se(),P&&wt&&!O.language&&!Yn&&U.some(g=>g.following)){Yn=!0;const g=await kr(se,!0,"Start reading");g&&(O=await x("/preferences","PUT",{language:g,consentVersion:kt}),Ue(localStorage,g),U.filter(h=>h.following).forEach(h=>{h.auto_enabled=!0}))}}catch(s){if(r!==L)return;o.innerHTML='<section class="empty"><h1>Let’s reconnect.</h1><p>The reading room could not load this page.</p><button class="button" data-view="discover">Try again →</button></section>',Qe(s)}}async function Ye(e,t){document.querySelectorAll("#save, #export, #language").forEach(i=>
38{i.disabled=!0}),yt(),clearTimeout(ht),xe=!1,M("");const n=++L;document.querySelectorAll("#save, #export, #language").forEach(i=>{i.disabled=!0});try{const i=e.versions.filter(b=>b.saved),r=Ir(!t&&$==="library"&&i.length?i:e.versions,localStorage,t);if(!r)throw new Error("article_unavailable");$==="library"&&(e=await x(`/articles/${encodeURIComponent(e.id)}`));const o=await x(`/versions/${r.id}/open`,"POST");if(P&&Oe.invalidate("/feed"),n!==L)return;T=e,ue=o.id,dt=0,Ut="",Le=o.savedRevision,me=o.saved,vr(`/reading/?article=${encodeURIComponent(e.id)}&version=${encodeURIComponent(o.id)}`);const s=document.querySelector("#main");s.classList.add("reading-page"),document.title=e.title+" — BingeRead",document.querySelector("#mobile-nav").hidden=!0,document.querySelector("#menu")?.setAttribute("aria-expanded","false"),Re?.(),Re=void 0,s.innerHTML=`<div class="reader-toolbar"><button class="text-link" data-view="${$}">← Back to reading</button><div id="reader-tools"></div><div class="actions"><select id="language" aria-label="Manuscript language">${e.versions.map(b=>`<option value="${b.id}" ${b.id===o.id?"selected":""}>${Q(Fs(e.versions,b))}</option>`).join("")}</select><button class="button" id="save" aria-pressed="${o.saved}">${o.saved?"Saved ✓":"Save"}</button><button class="text-link" id="export" aria-label="Export manuscript as Markdown">Export ↓</button></div></div><section class="reader-heading"><p class="eyebrow">${Q(xr(e))}</p><h1>${Q(e.title)}</h1><div class="meta">${Ot(e.published_at,"Video",!0)}${Ot(o.created_at,"Manuscript",!0)}${mt(e)?`<span>${mt(e)}</span>`:""}<a href="${Q(e.source_url)}" target="_blank" rel="noopener noreferrer">Original video ↗</a></div><details class="source-details"><summary>About this read</summary><p>AI edited from source captions. ${Q(o.model)} · ${o.language==="zh-hans"?"Translated and edited from the original captions.":"Edited from the original captions."} Names, numbers and phrasing can contain errors. Check the original video when precision matters. No creator endorsement or affiliation is implied.</p></details></section><div class="reader-layout"><aside class="reader-aside"><details id="reader-contents" ${matchMedia("(min-width: 821px)").matches?"open":""}><summary>Contents</summary><nav id="toc" class="toc" aria-label="Article contents"></nav></details></aside><article id="body" class="manuscript" lang="${Q(o.language)}" dir="${o.language==="ar"?"rtl":"ltr"}"></article></div>`;const A=document.querySelector("#body"),a=document.createElement("div");a.className="reader-document",A.before(a),a.append(document.querySelector(".reader-heading"),A),a.querySelector(".meta").append(a.querySelector(".source-details"));const l=e.versions.find(b=>b.language===o.language);l&&l.id!==o.id&&document.querySelector(".reader-heading").insertAdjacentHTML("beforeend",`<div class="notice-inline edition-note"><strong>${o.saved?"You’re reading a saved earlier copy.":"You’re reading an earlier version."}</strong>A newer version in this language is available. Switching keeps each version’s saved copy and reading position.<br><button class="text-link" data-version="${l.id}">Open newer version →</button></div>`),o.canWithdraw&&a.insertAdjacentHTML("beforeend",'<footer class="reader-contribution-actions"><button id="withdraw" class="reader-contribution-button" title="Withdraw my shared contribution" aria-label="Withdraw my shared contribution"><svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M9 14 4 9l5-5M4 9h10a6 6 0 0 1 0 12h-3"/></svg></button></footer>'),As(A,o.body_md),A.querySelectorAll("h1,h2,h3,p,li").forEach((b,m)=>b.id=`p-${m}`);const u=A.firstElementChild,d=b=>(b??"").trim().replace(/\s+/g," ");u?.tagName==="H1"&&d(u.textContent)&&(document.querySelector(".reader-heading h1").textContent=u.textContent,u.hidden=!0);const g=u?.hidden?u.nextElementSibling:u,h=new Set([...A.querySelectorAll("h2,h3")].map(b=>d(b.textContent)));if(g instanceof HTMLElement&&["UL","OL"].includes(g.tagName)){const b=[...g.querySelectorAll("li")].map(m=>{const D=m.cloneNode(!0);return D.querySelectorAll("ul,ol").forEach(C=>C.remove()),d(D.textContent)});b.length>=2&&b.every(m=>h.has(m))&&(g.hidden=!0)}const c=[...A.querySelectorAll("h1,h2,h3")].filter(b=>!b.hidden);if(document.querySelector("#toc").innerHTML=c.map(b=>`<button data-anchor="${b.id}" data-level="${b.tagName.slice(1)}">${Q(b.textContent)}</button>`).join(""),ke=c,Br=[...document.querySelectorAll("#toc button")],document.querySelector(".reader-aside").hidden=!c.length,Re=Is(s,A,ft),window.scrollTo({top:0,behavior:"instant"}),P){ye&&await ye;const b=o.progress&&(pt.get(o.id)??0)<=o.progress.revision?o.progress:await x(`/progress/${o.id}`);b&&n===L&&(dt=b.revision,pt.set(o.id,b.revision),document.getElementById(b.anchor)?.scrollIntoView(),window.scrollBy(0,b.offset_value))}n===L&&(ce.complete("read"),xe=!0,ft())}catch(i){Qe(i)}finally{n===L&&document.querySelectorAll("#save, #export, #language").forEach(i=>
38{i.disabled=!1})}}se.addEventListener("click",async e=>{const t=e.target.closest("button");if(t&&!(t instanceof HTMLButtonElement&&t.disabled))try{if(t.hasAttribute("data-quick-start")){if(t.closest("#mobile-nav")){document.querySelector("#mobile-nav").hidden=!0;const n=document.querySelector("#menu");n.setAttribute("aria-expanded","false"),n.focus({preventScroll:!0})}Xt(t.dataset.quickStart||"read");return}if(t.hasAttribute("data-dismiss-intro")){ce.complete("read"),Vt();return}if(t.hasAttribute("data-find-creators")){ls({parent:se,member:wt,signedIn:P,available:ut.channelDiscovery,channels:()=>U,api:x,follow:Gn,unfollow:Wn,added:n=>{U.some(i=>i.id===n.id)||U.push(n)}});return}if(!P&&(t.id==="save"||t.dataset.follow||t.dataset.auto)){const n=new URL(location.href);if(t.id==="save"&&T){const i=crypto.randomUUID();ds(sessionStorage,T.id,ue,i),n.searchParams.set("saveIntent",i)}location.href=`/account?returnTo=${encodeURIComponent(n.pathname+n.search)}`;return}if(t.id==="menu"){const n=document.querySelector("#mobile-nav");n.hidden=!n.hidden,t.setAttribute("aria-expanded",String(!n.hidden));return}if(t.id==="manage-reading-billing"){const n=await x("/membership/portal","POST",{}),i=new URL(n.url);if(i.protocol!=="https:"||i.username||i.password||i.port||!["creem.io","www.creem.io","checkout.creem.io"].includes(i.hostname))throw new Error("Billing portal could not be verified.");location.href=i.href;return}if(t.id==="clear-search"){de="";const n=document.querySelector("#search");n.value="",Se(),n.focus();return}if(t.hasAttribute("data-channel")){await oe("discover",t.dataset.channel);return}if(t.dataset.openId){await Ye(await x(`/articles/${encodeURIComponent(t.dataset.openId)}`));return}if(t.id==="more-articles"){t.setAttribute("disabled","");const n=L,i=$==="library"?"/library":$==="feed"?"/feed":"/articles";try{const r=await x(`${i}?sort=${ve}&before=${encodeURIComponent(At)}${$==="feed"?`&scope=${Ce}`:""}${z?`&channel=${encodeURIComponent(z)}`:""}`);if(n!==L)return;At=r.at(-1)?.cursor??At;const o=r.filter(s=>!q.some(A=>A.id===s.id));t.insertAdjacentHTML("beforebegin",Sr(o,q.length)),q.push(...o),Se(),r.length<40&&t.remove()}finally{t.removeAttribute("disabled")}return}if(t.dataset.cancelJob){await x(`/jobs/${t.dataset.cancelJob}/cancel`,"POST"),await oe("account"),M("Queued job cancelled. Its processing allowance was released.");return}if(t.id==="withdraw"){if(!window.confirm("Stop new public access to this contribution? Readers who already saved this version keep their saved copy. This does not remove independent versions."))return;await x(`/versions/${ue}/withdraw`,"POST",{confirmed:!0}),t.remove(),M("Contribution withdrawn. Existing saved copies remain available.");return}if(t.dataset.version&&T)await Ye(T,t.dataset.version);else if(t.dataset.view)await oe(t.dataset.view);else if(t.dataset.article){const n=q.find(i=>i.id===t.dataset.article);n&&await Ye(n)}else if(t.dataset.anchor)document.getElementById(t.dataset.anchor)?.scrollIntoView({behavior:"smooth",block:"start"});else if(t.dataset.follow){const n=t.dataset.follow;if(De.has(n))return;t.setAttribute("disabled","");const i=t.classList.contains("following");t.textContent=i?"Unfollowing…":"Following…";try{t.classList.contains("following")?await Wn(n):await Gn(n)}finally{t.removeAttribute("disabled"),t.textContent=t.classList.contains("following")?"Following ✓":"Follow +"}}else if(t.dataset.invite)await navigator.clipboard.writeText(`${location.origin}/reading/?channel=${t.dataset.invite}`),M("Channel invitation copied.");else if(t.id==="save"){const n=await x(`/saved/${ue}`,"PUT",{revision:Le,deleted:me});Le=n.revision,me=!n.deleted,t.textContent=me?"Saved ✓":"Save",t.setAttribute("aria-pressed",String(me)),me?qt("Saved to My reading."):M("Removed from saved reads.")}else if(t.id==="theme"){const n=document.documentElement.dataset.theme==="dark"?"light":"dark";document.documentElement.dataset.theme=n;try{localStorage.setItem("bsv:reading:theme",n)}catch{}}else if(t.id==="export"){const n=gs(T?.title),i=await x(`/versions/${ue}/open`,"POST"),r=URL.createObjectURL(new Blob([i.body_md],{type:"text/markdown"})),o=document.createElement("a");o.href=r,o.download=n,o.click(),URL.revokeObjectURL(r),M("Markdown download started.")}}catch(n){Qe(n)}});se.addEventListener("input",e=>{const t=e.target;t.id==="search"&&(de=t.value,Se())});se.addEventListener("keydown",e=>{if(e.key==="Escape"){const t=document.querySelector(".reader-appearance[open]");t&&(t.open=!1,t.querySelector("summary")?.focus()),document.querySelector("#mobile-nav").hidden=!0,document.querySelector("#menu")?.setAttribute("aria-expanded","fal
38se")}});se.addEventListener("change",async e=>{const t=e.target;if(t.id==="feed-scope"){Ce=t.value==="following"?"following":"all";const n=de;await oe("feed"),de=n;const i=document.querySelector("#search");i&&(i.value=n,Se()),document.querySelector("#feed-scope")?.focus();return}if(t.id==="reading-sort"){ve=Dr(t.value),ne("bsv:reading-sort",ve);const n=de;await oe($,z),de=n;const i=document.querySelector("#search");i&&(i.value=n,Se()),document.querySelector("#reading-sort")?.focus();return}if(t.id==="channel-filter"){await oe("discover",t.value);return}if(t.id==="reading-preference"||t.id==="reading-limit"){t.disabled=!0;const n=t.id==="reading-preference"?t.value:O.language??"en",i=t.id==="reading-limit"?Number(t.value):O.maxShareMs;try{O=await x("/preferences","PUT",{language:n,maxShareMs:i,consentVersion:kt}),Ue(localStorage,n),M("Settings saved.")}catch(r){t.value=t.id==="reading-limit"?String(O.maxShareMs):O.language??"en",Qe(r)}finally{t.disabled=!1}return}if(t.id==="language"&&T){const n=T.versions.find(i=>i.id===t.value);n&&Ue(localStorage,n.language),await Ye(T,t.value)}});async function yt(){if(!T||!P||!xe)return;const e=ue,t=[...document.querySelectorAll("#body [id]")],n=Math.max(100,document.querySelector(".reader-toolbar")?.getBoundingClientRect().bottom??0),i=t.find(u=>!u.hidden&&u.getClientRects().length&&u.getBoundingClientRect().bottom>n);if(!i)return;const r=Math.max(0,Math.round(-i.getBoundingClientRect().top)),o=`${e}:${i.id}:${r}`;if(o===Ut)return;const s=ye,A=dt,a=i.id,l=(async()=>{try{s&&await s;const u=await x(`/progress/${e}`,"PUT",{anchor:a,offset:r,revision:pt.get(e)??A});pt.set(e,u.revision),ue===e&&(dt=u.revision,Ut=o)}catch(u){Qe(u)}})();ye=l,await l,ye===l&&(ye=null)}window.addEventListener("scroll",()=>{xe&&(cancelAnimationFrame(gt),gt=requestAnimationFrame(ft),clearTimeout(ht),ht=setTimeout(()=>{yt()},900))},{passive:!0});async function Kr(){yt(),Lt=!0,Oe.clear();try{const e=new URLSearchParams(location.search);e.has("article")||(Ce=e.get("scope")==="following"?"following":"all");const t=await x("/config");if(P=!!t.user,ct=!!t.preview,ut=t.features??ut,wt=!!t.readerSettings?.member,O=t.readerSettings??{language:null,maxShareMs:72e5},O.language&&Ue(localStorage,O.language),kt=t.policy.version,Jn(),e.get("checkout")==="membership"){if(!P){location.href="/account?returnTo=%2Freading%2F%3Fcheckout%3Dmembership";return}const n="bsv:reading-checkout-intent";let i=sessionStorage.getItem(n);i||(i=crypto.randomUUID(),sessionStorage.setItem(n,i)),M("Opening secure checkout…");let r;try{r=await x("/membership/checkout","POST",{clientOperationId:i})}catch(s){if(s.message!=="checkout_intent_terminal")throw s;i=crypto.randomUUID(),sessionStorage.setItem(n,i),r=await x("/membership/checkout","POST",{clientOperationId:i})}const o=new URL(r.url);if(o.protocol!=="https:"||o.username||o.password||o.port||!["creem.io","www.creem.io","checkout.creem.io"].includes(o.hostname))throw new Error("Checkout could not be verified.");location.href=o.href;return}if(t.preview&&se.querySelector("header").insertAdjacentHTML("beforebegin",'<div class="preview-bar"><span>Preview · Test account</span><a href="/account">Switch account ↗</a></div>'),e.has("article")){const n=await x(`/articles/${encodeURIComponent(e.get("article"))}`);await Ye(n,e.get("version")??void 0);const i=e.get("saveIntent");if(P&&T?.id===n.id&&i){if(!hs(sessionStorage,n.id,ue,i)){M("You’re back at your article. Select Save to save this version; the earlier save request is unavailable in this tab or has expired.");return}if(me)M("This version is already in My reading.");else try{const o=await x(`/saved/${ue}`,"PUT",{revision:Le,deleted:!1});Le=o.revision,me=!o.deleted,document.querySelector("#save").textContent="Saved ✓",document.querySelector("#save").setAttribute("aria-pressed","true"),qt("Saved to My reading.")}catch{M("We couldn’t confirm your save. Select Save to try again.")}}}else await oe(e.get("view")??"discover",e.get("channel")??"");if(e.has("help")&&Xt(e.get("help")||"read"),e.get("checkout")==="success"&&P){M("Confirming membership…");const n=L;for(let i=0;i<10&&n===L;i++){if((await x("/usage")).member){sessionStorage.removeItem("bsv:reading-checkout-intent"),await oe("account"),M("Membership is active.");break}
38if(i===9){M("Payment confirmation is taking longer. Check back shortly; there is no need to pay again.");break}await new Promise(o=>setTimeout(o,3e3))}}}catch(e){Jn(),Qe(e)}finally{Lt=!1}}window.addEventListener("popstate",()=>{Kr()});Kr();

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