@banou/stub 0.0.50 → 0.0.51
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +105 -7
- package/build/assets/index-qhMrnlXc.js +2453 -0
- package/build/assets/{lib-worker-B4bhXBRt.js → lib-worker-CvSIFpg3.js} +1 -1
- package/build/assets/{lib-worker-ClrG_6Et.js → lib-worker-fbrqP6pm.js} +1 -1
- package/build/assets/{lib-worker-index-CoM3SF4K.js → lib-worker-index-CQP5MZBp.js} +278 -278
- package/build/assets/{main-D5AZX5ak.js → main-CAdIiP_g.js} +7 -7
- package/build/assets/{worker-NHcxxJEX.js → worker-CpMTiYu3.js} +1 -1
- package/build/assets/{worker-BqPITUlQ.js → worker-CrS-zxdF.js} +1 -1
- package/build/index.html +2 -2
- package/build/index.js +12 -7
- package/fkn.json +1 -1
- package/package.json +1 -1
- package/build/assets/index-oKTwCBqt.js +0 -2453
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./worker-
|
|
2
|
-
import{$ as e,A as t,B as n,C as r,D as i,E as a,F as o,G as s,I as c,J as l,L as u,M as d,N as f,O as p,P as m,Q as h,R as g,S as _,St as v,T as y,U as b,V as x,X as S,Y as C,Z as w,_ as T,_t as E,a as D,at as O,b as k,c as A,ct as j,d as M,et as N,f as P,ft as ee,g as te,gt as ne,h as re,ht as ie,i as F,it as ae,j as oe,k as I,lt as L,m as se,mt as ce,n as le,nt as R,o as ue,ot as z,p as de,pt as fe,q as pe,r as me,rt as he,s as ge,st as B,tt as _e,u as ve,ut as V,v as H,vt as ye,w as be,xt as xe,y as U,z as Se}from"./embed-title-MMtofoQC.js";import{r as Ce}from"./account-B2ETje0Z.js";import{_ as we,a as Te,b as Ee,d as De,f as Oe,i as ke,l as Ae,m as je,n as Me,p as Ne,r as Pe,s as Fe,t as Ie,v as Le,x as Re,y as ze}from"./site-status--bPTCMnf.js";import{A as Be,C as Ve,D as He,E as Ue,O as We,S as Ge,T as Ke,_ as qe,a as Je,b as Ye,c as Xe,f as Ze,g as Qe,h as $e,i as et,j as tt,k as nt,l as rt,m as it,n as at,o as ot,p as st,r as ct,s as lt,t as ut,v as dt,w as ft,x as pt,y as mt}from"./worker-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./worker-CrS-zxdF.js","./worker-CpMTiYu3.js","./build-mcPaLDi_.js","./site-status--bPTCMnf.js","./embed-title-MMtofoQC.js","./account-B2ETje0Z.js","./api-DIgTslNb-Cs0uqWX1.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{$ as e,A as t,B as n,C as r,D as i,E as a,F as o,G as s,I as c,J as l,L as u,M as d,N as f,O as p,P as m,Q as h,R as g,S as _,St as v,T as y,U as b,V as x,X as S,Y as C,Z as w,_ as T,_t as E,a as D,at as O,b as k,c as A,ct as j,d as M,et as N,f as P,ft as ee,g as te,gt as ne,h as re,ht as ie,i as F,it as ae,j as oe,k as I,lt as L,m as se,mt as ce,n as le,nt as R,o as ue,ot as z,p as de,pt as fe,q as pe,r as me,rt as he,s as ge,st as B,tt as _e,u as ve,ut as V,v as H,vt as ye,w as be,xt as xe,y as U,z as Se}from"./embed-title-MMtofoQC.js";import{r as Ce}from"./account-B2ETje0Z.js";import{_ as we,a as Te,b as Ee,d as De,f as Oe,i as ke,l as Ae,m as je,n as Me,p as Ne,r as Pe,s as Fe,t as Ie,v as Le,x as Re,y as ze}from"./site-status--bPTCMnf.js";import{A as Be,C as Ve,D as He,E as Ue,O as We,S as Ge,T as Ke,_ as qe,a as Je,b as Ye,c as Xe,f as Ze,g as Qe,h as $e,i as et,j as tt,k as nt,l as rt,m as it,n as at,o as ot,p as st,r as ct,s as lt,t as ut,v as dt,w as ft,x as pt,y as mt}from"./worker-CpMTiYu3.js";import{t as ht}from"./remote-CAlKhZLk.js";ie();var gt={NAME:`Name`,DOCUMENT:`Document`,OPERATION_DEFINITION:`OperationDefinition`,VARIABLE_DEFINITION:`VariableDefinition`,SELECTION_SET:`SelectionSet`,FIELD:`Field`,ARGUMENT:`Argument`,FRAGMENT_SPREAD:`FragmentSpread`,INLINE_FRAGMENT:`InlineFragment`,FRAGMENT_DEFINITION:`FragmentDefinition`,VARIABLE:`Variable`,INT:`IntValue`,FLOAT:`FloatValue`,STRING:`StringValue`,BOOLEAN:`BooleanValue`,NULL:`NullValue`,ENUM:`EnumValue`,LIST:`ListValue`,OBJECT:`ObjectValue`,OBJECT_FIELD:`ObjectField`,DIRECTIVE:`Directive`,NAMED_TYPE:`NamedType`,LIST_TYPE:`ListType`,NON_NULL_TYPE:`NonNullType`},_t=class extends Error{constructor(e,t,n,r,i,a,o){super(e),this.name=`GraphQLError`,this.message=e,i&&(this.path=i),t&&(this.nodes=Array.isArray(t)?t:[t]),n&&(this.source=n),r&&(this.positions=r),a&&(this.originalError=a);var s=o;if(!s&&a){var c=a.extensions;c&&typeof c==`object`&&(s=c)}this.extensions=s||{}}toJSON(){return{...this,message:this.message}}toString(){return this.message}get[Symbol.toStringTag](){return`GraphQLError`}},W,G;function vt(e){return new _t(`Syntax Error: Unexpected token at ${G} in ${e}`)}function yt(e){if(e.lastIndex=G,e.test(W))return W.slice(G,G=e.lastIndex)}var bt=/ +(?=[^\s])/y;function xt(e){for(var t=e.split(`
|
|
3
3
|
`),n=``,r=0,i=0,a=t.length-1,o=0;o<t.length;o++)bt.lastIndex=0,bt.test(t[o])&&(o&&(!r||bt.lastIndex<r)&&(r=bt.lastIndex),i||=o,a=o);for(var s=i;s<=a;s++)s!==i&&(n+=`
|
|
4
4
|
`),n+=t[s].slice(r).replace(/\\"""/g,`"""`);return n}function K(){for(var e=0|W.charCodeAt(G++);e===9||e===10||e===13||e===32||e===35||e===44||e===65279;e=0|W.charCodeAt(G++))if(e===35)for(;(e=0|W.charCodeAt(G++))&&e!==10&&e!==13;);G--}function St(){for(var e=G,t=0|W.charCodeAt(G++);t>=48&&t<=57||t>=65&&t<=90||t===95||t>=97&&t<=122;t=0|W.charCodeAt(G++));if(e===G-1)throw vt(`Name`);var n=W.slice(e,--G);return K(),n}function Ct(){return{kind:`Name`,value:St()}}var wt=/(?:"""|(?:[\s\S]*?[^\\])""")/y,Tt=/(?:(?:\.\d+)?[eE][+-]?\d+|\.\d+)/y;function Et(e){var t;switch(W.charCodeAt(G)){case 91:G++,K();for(var n=[];W.charCodeAt(G)!==93;)n.push(Et(e));return G++,K(),{kind:`ListValue`,values:n};case 123:G++,K();for(var r=[];W.charCodeAt(G)!==125;){var i=Ct();if(W.charCodeAt(G++)!==58)throw vt(`ObjectField`);K(),r.push({kind:`ObjectField`,name:i,value:Et(e)})}return G++,K(),{kind:`ObjectValue`,fields:r};case 36:if(e)throw vt(`Variable`);return G++,{kind:`Variable`,name:Ct()};case 34:if(W.charCodeAt(G+1)===34&&W.charCodeAt(G+2)===34){if(G+=3,(t=yt(wt))==null)throw vt(`StringValue`);return K(),{kind:`StringValue`,value:xt(t.slice(0,-3)),block:!0}}var a=G,o;G++;var s=!1;for(o=0|W.charCodeAt(G++);o===92&&(G++,s=!0)||o!==10&&o!==13&&o!==34&&o;o=0|W.charCodeAt(G++));if(o!==34)throw vt(`StringValue`);return t=W.slice(a,G),K(),{kind:`StringValue`,value:s?JSON.parse(t):t.slice(1,-1),block:!1};case 45:case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:for(var c=G++,l;(l=0|W.charCodeAt(G++))>=48&&l<=57;);var u=W.slice(c,--G);if((l=W.charCodeAt(G))===46||l===69||l===101){if((t=yt(Tt))==null)throw vt(`FloatValue`);return K(),{kind:`FloatValue`,value:u+t}}return K(),{kind:`IntValue`,value:u};case 110:if(W.charCodeAt(G+1)===117&&W.charCodeAt(G+2)===108&&W.charCodeAt(G+3)===108)return G+=4,K(),{kind:`NullValue`};break;case 116:if(W.charCodeAt(G+1)===114&&W.charCodeAt(G+2)===117&&W.charCodeAt(G+3)===101)return G+=4,K(),{kind:`BooleanValue`,value:!0};break;case 102:if(W.charCodeAt(G+1)===97&&W.charCodeAt(G+2)===108&&W.charCodeAt(G+3)===115&&W.charCodeAt(G+4)===101)return G+=5,K(),{kind:`BooleanValue`,value:!1}}return{kind:`EnumValue`,value:St()}}function Dt(e){if(W.charCodeAt(G)===40){var t=[];G++,K();do{var n=Ct();if(W.charCodeAt(G++)!==58)throw vt(`Argument`);K(),t.push({kind:`Argument`,name:n,value:Et(e)})}while(W.charCodeAt(G)!==41);return G++,K(),t}}function Ot(e){if(W.charCodeAt(G)===64){var t=[];do G++,t.push({kind:`Directive`,name:Ct(),arguments:Dt(e)});while(W.charCodeAt(G)===64);return t}}function kt(){for(var e=0;W.charCodeAt(G)===91;)e++,G++,K();var t={kind:`NamedType`,name:Ct()};do if(W.charCodeAt(G)===33&&(G++,K(),t={kind:`NonNullType`,type:t}),e){if(W.charCodeAt(G++)!==93)throw vt(`NamedType`);K(),t={kind:`ListType`,type:t}}while(e--);return t}function At(){if(W.charCodeAt(G++)!==123)throw vt(`SelectionSet`);return K(),jt()}function jt(){var e=[];do if(W.charCodeAt(G)===46){if(W.charCodeAt(++G)!==46||W.charCodeAt(++G)!==46)throw vt(`SelectionSet`);switch(G++,K(),W.charCodeAt(G)){case 64:e.push({kind:`InlineFragment`,typeCondition:void 0,directives:Ot(!1),selectionSet:At()});break;case 111:W.charCodeAt(G+1)===110?(G+=2,K(),e.push({kind:`InlineFragment`,typeCondition:{kind:`NamedType`,name:Ct()},directives:Ot(!1),selectionSet:At()})):e.push({kind:`FragmentSpread`,name:Ct(),directives:Ot(!1)});break;case 123:G++,K(),e.push({kind:`InlineFragment`,typeCondition:void 0,directives:void 0,selectionSet:jt()});break;default:e.push({kind:`FragmentSpread`,name:Ct(),directives:Ot(!1)})}}else{var t=Ct(),n=void 0;W.charCodeAt(G)===58&&(G++,K(),n=t,t=Ct());var r=Dt(!1),i=Ot(!1),a=void 0;W.charCodeAt(G)===123&&(G++,K(),a=jt()),e.push({kind:`Field`,alias:n,name:t,arguments:r,directives:i,selectionSet:a})}while(W.charCodeAt(G)!==125);return G++,K(),{kind:`SelectionSet`,selections:e}}function Mt(){if(K(),W.charCodeAt(G)===40){var e=[];G++,K();do{var t=void 0;if(W.charCodeAt(G)===34&&(t=Et(!0)),W.charCodeAt(G++)!==36)throw vt(`Variable`);var n=Ct();if(W.charCodeAt(G++)!==58)throw vt(`VariableDefinition`);K();var r=kt(),i=void 0;W.charCodeAt(G)===61&&(G++,K(),i=Et(!0)),K();var a={kind:`VariableDefinition`,variable:{kind:`Variable`,name:n},type:r,defaultValue:i,directives:Ot(!0)};t&&(a.description=t),e.push(a)}while(W.charCodeAt(G)!==41);return G++,K(),e}}function Nt(e){var t=Ct();if(W.charCodeAt(G++)!==111||W.charCodeAt(G++)!==110)throw vt(`FragmentDefinition`);K();var n={kind:`FragmentDefinition`,name:t,typeCondition:{kind:`NamedType`,name:Ct()},directives:Ot(!1),selectionSet:At()};return e&&(n.description=e),n}function Pt(){var e=[];do{var t=void 0;if(W.charCodeAt(G)===34&&(t=Et(!0)),W.charCodeAt(G)===123){if(t)throw vt(`Document`);G++,K(),e.push({kind:`OperationDefinition`,operation:`query`,name:void 0,variableDefinitions:void 0,directives:void 0,selectionSet:jt()})}else{var n=St();switch(n){case`fragment`:e.push(Nt(t));break;case`query`:case`mutation`:case`subscription`:var r,i=void 0;(r=W.charCodeAt(G))!==40&&r!==64&&r!==123&&(i=Ct());var a={kind:`OperationDefinition`,operation:n,name:i,variableDefinitions:Mt(),directives:Ot(!1),selectionSet:At()};t&&(a.description=t),e.push(a);break;default:throw vt(`Document`)}}}while(G<W.length);return e}function Ft(e,t){return W=e.body?e.body:e,G=0,K(),t&&t.noLocation?{kind:`Document`,definitions:Pt()}:{kind:`Document`,definitions:Pt(),loc:{start:0,end:W.length,startToken:void 0,endToken:void 0,source:{body:W,name:`graphql.web`,locationOffset:{line:1,column:1}}}}}function It(e,t,n){for(var r=``,i=0;i<e.length;i++)i&&(r+=t),r+=n(e[i]);return r}function Lt(e){return JSON.stringify(e)}function Rt(e){return`"""
|
|
5
5
|
`+e.replace(/"""/g,`\\"""`)+`
|
|
@@ -424,7 +424,7 @@ https://bit.ly/2XbVrpR#`;function ji(e,t,n){if(!e){var r=t||`Minfied Error #`+n+
|
|
|
424
424
|
gap: 1.2rem;
|
|
425
425
|
padding: 2rem 1.5rem;
|
|
426
426
|
}
|
|
427
|
-
`,Bp=()=>{let[e]=ts(fs(J.WATCH)),[t]=ts(fs(J.LOGIN_CALLBACK));return e||t?null:k(`footer`,{css:zp,children:[U(os,{to:ps(J.HOME),className:`wordmark`,onClick:Ol,children:`stub`}),U(os,{to:ps(J.LEGAL),className:`nav-link`,children:`Legal`}),U(os,{to:ps(J.PRIVACY),className:`nav-link`,children:`Privacy`}),k(`span`,{className:`version`,title:`stub v0.0.
|
|
427
|
+
`,Bp=()=>{let[e]=ts(fs(J.WATCH)),[t]=ts(fs(J.LOGIN_CALLBACK));return e||t?null:k(`footer`,{css:zp,children:[U(os,{to:ps(J.HOME),className:`wordmark`,onClick:Ol,children:`stub`}),U(os,{to:ps(J.LEGAL),className:`nav-link`,children:`Legal`}),U(os,{to:ps(J.PRIVACY),className:`nav-link`,children:`Privacy`}),k(`span`,{className:`version`,title:`stub v0.0.51, commit 4aec3f2`,children:[`v`,`0.0.51`,` `,U(`span`,{className:`commit`,children:`4aec3f2`})]})]})};j();var Vp=x`
|
|
428
428
|
position: fixed;
|
|
429
429
|
inset: 0;
|
|
430
430
|
/* a sibling of the modal's portal rather than a child of it, so it competes at the root and 200
|
|
@@ -1020,7 +1020,7 @@ transition: max-height 0.3s ease-in-out;
|
|
|
1020
1020
|
width: 100%;
|
|
1021
1021
|
background-color: rgb(35, 35, 35);
|
|
1022
1022
|
}
|
|
1023
|
-
`,Zm=({children:e,collapsedHeight:t=200,...n})=>{let[r,i]=B(!1),[a,o]=B(!1),s=R(null),[c,l]=B(0);O(()=>{if(!s.current)return;let e=new ResizeObserver(()=>{if(s.current){let e=s.current.scrollHeight;l(e),o(e>t)}});return e.observe(s.current),()=>e.disconnect()},[t]);let u=()=>i(!r);return k(`div`,{...n,ref:s,css:Xm,className:`${n.className||``} ${!r&&a?`collapsed`:`expanded`}`,children:[U(`div`,{className:`content`,children:e}),a&&!r?U(`div`,{className:`fade-overlay`}):void 0,a?U(`button`,{className:`toggle-button`,onClick:u,children:r?`Collapse`:`Expand`}):void 0]})},Qm=`this build of the worker exposes no traceGraph, so there is nothing to read a trace from`,$m=async()=>await Ne(()=>import(`./worker-
|
|
1023
|
+
`,Zm=({children:e,collapsedHeight:t=200,...n})=>{let[r,i]=B(!1),[a,o]=B(!1),s=R(null),[c,l]=B(0);O(()=>{if(!s.current)return;let e=new ResizeObserver(()=>{if(s.current){let e=s.current.scrollHeight;l(e),o(e>t)}});return e.observe(s.current),()=>e.disconnect()},[t]);let u=()=>i(!r);return k(`div`,{...n,ref:s,css:Xm,className:`${n.className||``} ${!r&&a?`collapsed`:`expanded`}`,children:[U(`div`,{className:`content`,children:e}),a&&!r?U(`div`,{className:`fade-overlay`}):void 0,a?U(`button`,{className:`toggle-button`,onClick:u,children:r?`Collapse`:`Expand`}):void 0]})},Qm=`this build of the worker exposes no traceGraph, so there is nothing to read a trace from`,$m=async()=>await Ne(()=>import(`./worker-CrS-zxdF.js`),__vite__mapDeps([0,1,2,3,4,5,6]),import.meta.url),eh=async e=>{let t=await $m();if(typeof t.traceGraph!=`function`)throw Error(Qm);return t.traceGraph(e)},th=async e=>{let t=await $m();if(typeof t.traceAnswer!=`function`)throw Error(Qm);return t.traceAnswer(e)},nh=[`graph`,`store`],rh=({uri:e,search:t}={})=>{let n=ps(J.DEBUG_TRACE),r=new URLSearchParams;e&&r.set(`uri`,e);let i=sh(t??``);for(let e of nh)for(let t of i.getAll(e))r.append(e,t);let a=r.toString();return a?`${n}?${a}`:n},ih=e=>{let t=sh(lh(e)),n=new URLSearchParams;for(let e of nh)for(let r of t.getAll(e))n.append(e,r);let r=n.toString();return r?`?${r}`:``},ah=(e,t=`graph`)=>{let n=sh(e);return n.set(t,`1`),`${ps(J.DEBUG_TRACE)}?${n.toString()}`},oh=e=>{let t=sh(e);t.delete(`store`);let n=t.toString();return`${ps(J.DEBUG_TRACE)}${n?`?${n}`:``}`},sh=e=>new URLSearchParams(e.startsWith(`?`)?e.slice(1):e),ch=typeof location>`u`?``:location.search,lh=(e=``)=>{let t=sh(ch);for(let[n,r]of sh(e))t.set(n,r);return t.toString()},uh=e=>new URLSearchParams(e.startsWith(`?`)?e.slice(1):e).get(`uri`)??``,dh={PREQUEL:`SEQUEL`,ADAPTATION:`SOURCE`,COMPILATION:`CONTAINS`,SIDE_STORY:`PARENT`},fh=e=>{let t=new Set,n=[];for(let r of e){if(!r?.from||!r?.to||r.from===r.to)continue;let e=dh[r.relation],i=e?{from:r.to,to:r.from,relation:e}:r,a=`${i.from}\u0000${i.to}\u0000${i.relation}`;t.has(a)||(t.add(a),n.push(i))}return n},ph=new Set([`TV`,`TV_SHORT`,`MOVIE`,`SPECIAL`,`OVA`,`ONA`,`MUSIC`]),mh=e=>!e||ph.has(e),hh=e=>[...new Set((e.nodes??[]).map(e=>e.format??``).filter(Boolean))].sort(),gh=(e,t)=>{let n=(e.nodes??[]).filter(t),r=new Set(n.map(e=>e.uri));return{nodes:n,edges:(e.edges??[]).filter(e=>r.has(e.from)&&r.has(e.to))}},_h=e=>`${e.from}\u0000${e.to}\u0000${e.relation}`,vh=(e,t)=>{if(!e)return{nodes:new Set,edges:new Set};if(e.kind===`node`){let n=t.filter(t=>t.from===e.uri||t.to===e.uri);return{nodes:new Set([e.uri]),edges:new Set(n.map(_h))}}let n=t.find(t=>_h(t)===e.key);return n?{nodes:new Set([n.from,n.to]),edges:new Set([e.key])}:{nodes:new Set,edges:new Set}},yh=e=>e.titles?.[0]?.title||e.uri,bh=e=>[...e].sort((e,t)=>(e.startDate??`9999`).localeCompare(t.startDate??`9999`)||yh(e).localeCompare(yh(t))),xh=(e,t)=>{let n=new Map(e.map(e=>[e.uri,0]));for(let r=0;r<e.length;r++){let e=!1;for(let r of t){let t=n.get(r.from),i=n.get(r.to);t!==void 0&&i!==void 0&&i<t+1&&(n.set(r.to,t+1),e=!0)}if(!e)break}let r=[...new Set(n.values())].sort((e,t)=>e-t),i=new Map(r.map((e,t)=>[e,t]));for(let[e,t]of n)n.set(e,i.get(t)??0);return n},Sh=(e,t=`story`)=>{let n=fh(e.edges??[]),r=new Set((e.nodes??[]).map(e=>e.uri)),i=n.filter(e=>r.has(e.from)&&r.has(e.to)),a=bh(e.nodes??[]),o=t===`graph`?xh(a,i):void 0,s=[...new Set(a.map(e=>e.startDate??``))],c=new Map(s.map((e,t)=>[e,t])),l=new Map,u=a.map(e=>{let t=o?o.get(e.uri)??0:c.get(e.startDate??``)??0,n=l.get(t)??0;return l.set(t,n+1),{...e,column:t,row:n}}),d=[];if(t===`story`)for(let e=0;e<u.length-1;e++){let t=u[e],n=u[e+1];n.column>t.column&&d.push({from:t.uri,to:n.uri})}return{nodes:u,edges:i,chain:d,columns:Math.max(0,...u.map(e=>e.column+1)),rows:Math.max(0,...l.values())}},Ch={ADAPTATION:`Adaptation`,PREQUEL:`Prequel`,SEQUEL:`Sequel`,PARENT:`Parent story`,SIDE_STORY:`Side story`,CHARACTER:`Character`,SUMMARY:`Summary`,ALTERNATIVE:`Alternative`,SPIN_OFF:`Spin off`,SOURCE:`Source`,COMPILATION:`Compilation`,CONTAINS:`Contains`,OTHER:`Related`},wh=[`SOURCE`,`PREQUEL`,`SEQUEL`,`PARENT`,`SIDE_STORY`,`SPIN_OFF`,`ALTERNATIVE`,`ADAPTATION`,`SUMMARY`,`COMPILATION`,`CONTAINS`,`CHARACTER`,`OTHER`],Th=e=>{let t=wh.indexOf(e);return t===-1?wh.length:t},Eh=e=>e&&Ch[e]||Ch.OTHER,Dh={TV:`TV`,TV_SHORT:`TV Short`,MOVIE:`Movie`,SPECIAL:`Special`,OVA:`OVA`,ONA:`ONA`,MUSIC:`Music`,MANGA:`Manga`,NOVEL:`Light Novel`,ONE_SHOT:`One Shot`},Oh=e=>e?Dh[e]||e.split(`_`).filter(Boolean).map(e=>e.charAt(0).toUpperCase()+e.slice(1).toLowerCase()).join(` `):void 0,kh=e=>[...e].sort((e,t)=>Th(e.relation)-Th(t.relation)),Ah=e=>e.filter(e=>mh(e.format)),jh=e=>{let t=kh(e);return{before:t.filter(e=>e.relation===`PREQUEL`),middle:t.filter(e=>e.relation!==`PREQUEL`&&e.relation!==`SEQUEL`),after:t.filter(e=>e.relation===`SEQUEL`)}},Mh=x`
|
|
1024
1024
|
margin-top: 4rem;
|
|
1025
1025
|
|
|
1026
1026
|
& > .heading {
|
|
@@ -3035,7 +3035,7 @@ animation: overlayShow 150ms cubic-bezier(0.16, 1, 0.3, 1);
|
|
|
3035
3035
|
|
|
3036
3036
|
strong { color: #fff; }
|
|
3037
3037
|
.facts { color: rgba(255, 255, 255, 0.55); }
|
|
3038
|
-
`,Rj=e=>e.endsWith(`.`)?e:`${e}.`,zj=()=>k(Mj,{children:[U(`h1`,{children:`Privacy`}),U(`div`,{className:`updated`,children:`Last updated 10 October 2026`}),U(`p`,{children:`stub is an independent, non-commercial personal project. In short: it has no accounts and no server of its own, runs no analytics, and keeps your settings and your watch list in your browser, or in your own FKN account when you choose to.`}),U(`h2`,{children:`What stub keeps`}),k(`p`,{children:[`stub sets no advertising or tracking cookies and runs no analytics or telemetry. This is everything it keeps, where, and for how long. You sign out of a site in`,` `,U(os,{to:`/settings#accounts`,children:`Settings, under Accounts`}),`, and remove a source you added in`,` `,U(os,{to:`/settings#sources`,children:`Settings, under Sources`}),`. Clearing this site's data in your browser removes everything stub keeps in this browser.`]}),U(`ul`,{css:Lj,children:Ij.map(e=>k(`li`,{children:[k(`strong`,{children:[e.title,`.`]}),` `,e.what,` `,k(`span`,{className:`facts`,children:[`Where: `,Rj(e.where),` How long: `,Rj(e.lasts)]})]},e.id))}),U(`p`,{children:`About stub's list: signed out, it is saved in your browser's storage for stub, on this device only. Signed in to an FKN account, stub uses that account's list instead: your changes are saved on the device and in the account's storage, encrypted in your browser before they leave the device, so every device signed in to the same account shows them. A list you kept before signing in is added to the account only if you choose to. When you sign out, the account's list is removed from the device. Removing an entry keeps a record that it was removed, with the entry's title and last values, so that every device using the list removes it too. There is no way to clear these records yet.`}),U(`h2`,{children:`Sign-ins to other sites`}),k(`p`,{children:[`stub plays Crunchyroll and tracks your AniList and MyAnimeList lists with your own accounts on those sites. Without the FKN browser extension, you sign in on each site's own page, in an FKN window, and the cookies that sign-in sets are kept by FKN, in a cookie jar every fkn.app app shares, and not by stub. Signing out in `,U(os,{to:`/settings#accounts`,children:`Settings, under Accounts`}),`, removes that site's cookies from FKN. The site itself is not told, so its session stays valid there until it expires, held by nobody.`]}),U(`p`,{children:`With the extension, stub uses your browser's own sessions for these sites and for Netflix. Those stay in your browser, and you sign in and out of them on the sites themselves.`}),U(`h2`,{children:`Network requests & third parties`}),k(`p`,{children:[`To fetch titles, artwork, and streams, stub sends requests through the FKN platform proxy, which then reaches third-party services such as AniList, MyAnimeList, Crunchyroll, JustWatch, and Netflix. The proxy requires no account. It uses your IP address to rate-limit requests, and it keeps a copy of each answer for a while, under a key made from the whole request (its address, headers and body), so only an identical request is answered from that copy. How the FKN platform handles that data is described in the`,` `,U(`a`,{href:`https://fkn.app/privacy`,target:`_blank`,rel:`noreferrer noopener`,children:`FKN platform privacy policy`}),`. Each third-party service receives the requests made to it and applies its own privacy policy, especially when you sign in to one (for example Crunchyroll) to watch.`]}),U(`h2`,{children:`The optional browser extension`}),U(`p`,{children:`If you install the FKN browser extension, it works with your own already-logged-in sessions locally on your device so you can play content you have access to. Those credentials stay in your browser; stub never receives them.`}),U(`h2`,{children:`Your control`}),U(`p`,{children:`Disconnecting from FKN, in the account menu at the top right, takes your account's list off the device. Your party name and the party you are in go when you close the tab. If you use the browser extension, you can review and revoke its access at any time from the extension itself.`}),U(`h2`,{children:`Contact`}),k(`p`,{children:[`Questions about privacy can be raised through the project repository at`,` `,U(`a`,{href:`https://github.com/banou26/stub`,target:`_blank`,rel:`noreferrer noopener`,children:`github.com/banou26/stub`}),`.`]})]});j();var Bj=({label:e,name:t=e,confirmLabel:n,busyLabel:r,question:i,onConfirm:a,home:o})=>{let[s,c]=B(!1),[l,u]=B(!1),d=R(null),f=R(null),p=R(null),m=R(!1),h=R(!0),g=he(),_=()=>{let e=document.activeElement;return!e||e===document.body||!!p.current?.contains(e)};return O(()=>()=>{h.current=!1,p.current&&_()&&o?.current?.focus()},[]),_e(()=>{s?f.current?.focus():m.current&&d.current?.focus(),m.current=!1},[s]),s?k(`div`,{ref:p,className:`confirm`,role:`group`,"aria-label":t,children:[U(`p`,{id:g,children:i}),k(`div`,{className:`actions`,children:[U(`button`,{type:`button`,className:`danger`,"aria-describedby":g,disabled:l,onClick:()=>{u(!0),Promise.resolve().then(a).catch(()=>{}).finally(()=>{if(!h.current)return;let e=_();u(!1),c(!1),e&&(o?.current?o.current.focus():m.current=!0)})},children:l?r:n}),U(`button`,{ref:f,type:`button`,className:`secondary`,"aria-describedby":g,disabled:l,onClick:()=>{m.current=!0,c(!1)},children:`Cancel`})]})]}):U(`button`,{ref:d,type:`button`,className:`secondary`,"aria-label":t===e?void 0:t,onClick:()=>c(!0),children:e})};j();var Vj=e=>e instanceof Error?e.message:String(e),Hj=(e,t)=>{switch(t){case`authed`:return{text:`Signed in to ${e}.`};case`closed`:return{text:`The sign-in window closed. If you finished signing in there, stub reads it from now on.`};case`blocked`:return{text:`The browser blocked the sign-in window. Allow pop-ups for this page and try again.`,error:!0};case`unsupported`:return{text:`Connected to your browser's own ${e} session.`}}},Uj={"signed-in":`Signed in`,"signed-out":`Signed out`},Wj=(e,t)=>{let n=XA(t-e.checkedAt,1);return`${Uj[e.state]}, checked ${n?`${n} ago`:`just now`}`},Gj=(e,t)=>{let[,n]=B(0);return O(()=>e.watch(t,()=>n(e=>e+1)),[e,t]),e.read(t)},Kj=({site:e,name:t,backend:n,status:r,onNote:i})=>{let[a,o]=B(!1),s=Yj();return U(`button`,{type:`button`,className:`secondary`,disabled:a,"aria-label":`Check whether you are signed in to ${t}`,onClick:()=>{o(!0),i(void 0),r.check(e,n).catch(e=>{s.current&&i({text:`stub could not tell whether you are signed in to ${t}: ${Vj(e)}`,error:!0})}).finally(()=>{s.current&&o(!1)})},children:a?`Checking...`:`Check now`})},qj=({id:e,title:t,state:n,on:r,heading:i,children:a})=>k(`div`,{className:`row account`,"data-account":e,children:[k(`div`,{className:`head`,children:[U(`h3`,{ref:i,tabIndex:-1,children:t}),n?U(`span`,{className:`state${r?` on`:``}`,children:n}):void 0]}),a]}),Jj=({note:e})=>U(`p`,{className:`note${e?.error?` error`:``}`,role:`status`,children:e?.text}),Yj=()=>{let e=R(!0);return O(()=>()=>{e.current=!1},[]),e},Xj=`Without the FKN extension, the session is kept by FKN, in the cookie jar every fkn.app app shares, and not by stub.`,Zj=e=>`${e} itself is not told, so the session stays valid there until it expires, held by nobody.`,Qj=({backend:e,crunchyroll:t,status:n,now:r})=>{let[i,a]=B(!1),[o,s]=B(),c=Yj(),l=R(null),u=Gj(n,`crunchyroll`),d=e?U(Kj,{site:`crunchyroll`,name:`Crunchyroll`,backend:e,status:n,onNote:s}):void 0;return k(qj,{id:`crunchyroll`,title:`Crunchyroll`,state:u?Wj(u,r()):`Not checked yet`,on:u?.state===`signed-in`,heading:l,children:[U(`p`,{children:`Plays Crunchyroll episodes on your own Crunchyroll account.`}),e===`cloud`?k(H,{children:[k(`p`,{children:[Xj,` Check now asks Crunchyroll whether that session is signed in, without loading a Crunchyroll page.`]}),k(`div`,{className:`actions`,children:[u?.state===`signed-in`?void 0:U(`button`,{type:`button`,disabled:i,onClick:()=>{let e=t.signIn();a(!0),s(void 0),e.then(e=>{c.current&&s(Hj(`Crunchyroll`,e))}).catch(e=>{c.current&&s({text:Vj(e),error:!0})}).finally(()=>{c.current&&a(!1)})},children:i?`Signing in...`:`Sign in`}),u?.state===`signed-out`?void 0:U(Bj,{label:`Sign out`,name:`Sign out of Crunchyroll`,home:l,confirmLabel:`Yes, sign out`,busyLabel:`Signing out...`,question:`Sign out of Crunchyroll? This removes its cookies from FKN's jar, which signs every fkn.app app out of Crunchyroll. ${Zj(`Crunchyroll`)}`,onConfirm:()=>t.signOut().then(()=>{c.current&&s({text:`Signed out. FKN no longer holds a Crunchyroll session for fkn.app apps.`})},e=>{c.current&&s({text:`FKN could not remove the Crunchyroll cookies: ${Vj(e)}. Try again.`,error:!0})})}),d]})]}):e===`extension`?k(H,{children:[U(`p`,{children:`With the FKN extension, stub plays it on your browser's own crunchyroll.com session and keeps nothing of it. Sign in and out on crunchyroll.com.`}),k(`div`,{className:`actions`,children:[U(`a`,{className:`link`,href:`https://www.crunchyroll.com`,target:`_blank`,rel:`noreferrer`,children:`Open crunchyroll.com`}),d]})]}):U(`p`,{children:`Checking whether the FKN extension runs here...`}),U(Jj,{note:o})]})},$j=[{site:`anilist`,name:`AniList`,host:`anilist.co`},{site:`mal`,name:`MyAnimeList`,host:`myanimelist.net`}],eM=({site:e,name:t,host:n,backend:r,sites:i,status:a,now:o})=>{let[s,c]=B(()=>i.isConnected(e)),[l,u]=B(!1),[d,f]=B(),p=Yj(),m=R(null),h=Gj(a,e);O(()=>(c(i.isConnected(e)),i.watch(e,()=>{p.current&&c(i.isConnected(e))})),[i,e]);let g=()=>{p.current&&c(i.isConnected(e))},_=()=>{let n=i.signIn(e);u(!0),f(void 0),n.then(e=>{p.current&&f(Hj(t,e))}).catch(e=>{p.current&&f({text:Vj(e),error:!0})}).finally(()=>{p.current&&u(!1),g()})},v=r=>i.signOut(e,r).then(()=>{p.current&&f({text:r===`cloud`?`Signed out. stub no longer uses ${t} on this device, and FKN no longer holds its session.`:`Disconnected. To sign out of ${t} itself, sign out on ${n}.`}),g()},e=>{p.current&&f({text:`Disconnected on this device, but FKN could not remove the ${t} cookies: ${Vj(e)}. Sign in and out again to retry.`,error:!0}),g()});return k(qj,{id:e,title:t,state:s?h?Wj(h,o()):`Connected on this device`:`Not connected`,on:s&&h?.state!==`signed-out`,heading:m,children:[k(`p`,{children:[`Tracks your `,t,` list with your own `,n,` session.`,` `,r===`cloud`?Xj:r===`extension`?`With the FKN extension, stub uses your browser's own ${n} session.`:``]}),r?k(`div`,{className:`actions`,children:[s?U(Bj,{label:r===`cloud`?`Sign out`:`Disconnect`,name:r===`cloud`?`Sign out of ${t}`:`Disconnect ${t}`,home:m,confirmLabel:r===`cloud`?`Yes, sign out`:`Yes, disconnect`,busyLabel:r===`cloud`?`Signing out...`:`Disconnecting...`,question:r===`cloud`?`Sign out of ${t}? stub stops using it on this device, and its cookies leave FKN's jar, which signs every fkn.app app out of ${t}. ${Zj(t)}`:`Disconnect ${t}? stub stops using your ${n} session on this device. You stay signed in on ${n}.`,onConfirm:()=>v(r)}):U(`button`,{type:`button`,disabled:l,onClick:_,children:l?`Signing in...`:r===`cloud`?`Sign in`:`Connect`}),s?U(Kj,{site:e,name:t,backend:r,status:a,onNote:f}):void 0]}):void 0,U(Jj,{note:d})]})},tM=({backend:e})=>U(qj,{id:`netflix`,title:`Netflix`,children:e===`extension`?k(H,{children:[U(`p`,{children:`stub plays Netflix on your browser's own netflix.com session, through the FKN extension, and keeps nothing of it. Sign in and out on netflix.com.`}),U(`div`,{className:`actions`,children:U(`a`,{className:`link`,href:`https://www.netflix.com`,target:`_blank`,rel:`noreferrer`,children:`Open netflix.com`})})]}):U(`p`,{children:`Netflix needs the FKN browser extension: stub plays it on your browser's own netflix.com session, and keeps nothing of it.`})}),nM=({backend:e,crunchyroll:t,sites:n,status:r,now:i=Date.now})=>k(`div`,{className:`rows`,children:[U(Qj,{backend:e,crunchyroll:t,status:r,now:i}),$j.map(t=>U(eM,{...t,backend:e,sites:n,status:r,now:i},t.site)),U(tM,{backend:e})]}),rM=[{id:`accounts`,title:`Accounts`,intro:`The sites where stub uses your own account, what each one is for, and how to sign out.`},{id:`sources`,title:`Sources`,intro:`Where stub gets titles, artwork and streams: the sources it ships with, and the ones you add.`}],iM=e=>rM.find(t=>`#${t.id}`===e)?.id??`accounts`,aM=[{origin:`mal`,name:`MyAnimeList`,url:`https://myanimelist.net`},{origin:`anilist`,name:`AniList`,url:`https://anilist.co`},{origin:`anizip`,name:`AniZip`,url:`https://api.ani.zip/`},{origin:`cr`,name:`Crunchyroll`,url:`https://www.crunchyroll.com`},{origin:`nf`,name:`Netflix`,url:`https://www.netflix.com`},{origin:`jw`,name:`JustWatch`,url:`https://www.justwatch.com`},{origin:`appletv`,name:`Apple TV+`,url:`https://tv.apple.com`},{origin:`paramount`,name:`Paramount+`,url:`https://www.paramountplus.com`},{origin:`disney`,name:`Disney+`,url:`https://www.disneyplus.com`},{origin:`amazon`,name:`Prime Video`,url:`https://www.primevideo.com`},{origin:`hulu`,name:`Hulu`,url:`https://www.hulu.com`},{origin:`peacock`,name:`Peacock`,url:`https://www.peacocktv.com`},{origin:`hbo`,name:`Max`,url:`https://www.max.com`},{origin:`fubo`,name:`Fubo`,url:`https://www.fubo.tv`},{origin:`tmdb`,name:`TMDB`,url:`https://www.themoviedb.org`},{origin:`tvmaze`,name:`TVmaze`,url:`https://www.tvmaze.com`},{origin:`kitsu`,name:`Kitsu`,url:`https://kitsu.io`},{origin:`omdb`,name:`IMDb`,url:`https://www.imdb.com`},{origin:`trakt`,name:`Trakt`,url:`https://trakt.tv`},{origin:`simkl`,name:`Simkl`,url:`https://simkl.com`},{origin:`tvdb`,name:`TheTVDB`,url:`https://www.thetvdb.com`},{origin:`offline`,name:`Offline database`,url:`https://github.com/manami-project/anime-offline-database`},{origin:`watchmode`,name:`Watchmode`,url:`https://www.watchmode.com`}];j();var oM=x`
|
|
3038
|
+
`,Rj=e=>e.endsWith(`.`)?e:`${e}.`,zj=()=>k(Mj,{children:[U(`h1`,{children:`Privacy`}),U(`div`,{className:`updated`,children:`Last updated 10 October 2026`}),U(`p`,{children:`stub is an independent, non-commercial personal project. In short: it has no accounts and no server of its own, runs no analytics, and keeps your settings and your watch list in your browser, or in your own FKN account when you choose to.`}),U(`h2`,{children:`What stub keeps`}),k(`p`,{children:[`stub sets no advertising or tracking cookies and runs no analytics or telemetry. This is everything it keeps, where, and for how long. You sign out of a site in`,` `,U(os,{to:`/settings#accounts`,children:`Settings, under Accounts`}),`, and remove a source you added in`,` `,U(os,{to:`/settings#sources`,children:`Settings, under Sources`}),`. Clearing this site's data in your browser removes everything stub keeps in this browser.`]}),U(`ul`,{css:Lj,children:Ij.map(e=>k(`li`,{children:[k(`strong`,{children:[e.title,`.`]}),` `,e.what,` `,k(`span`,{className:`facts`,children:[`Where: `,Rj(e.where),` How long: `,Rj(e.lasts)]})]},e.id))}),U(`p`,{children:`About stub's list: signed out, it is saved in your browser's storage for stub, on this device only. Signed in to an FKN account, stub uses that account's list instead: your changes are saved on the device and in the account's storage, encrypted in your browser before they leave the device, so every device signed in to the same account shows them. A list you kept before signing in is added to the account only if you choose to. When you sign out, the account's list is removed from the device. Removing an entry keeps a record that it was removed, with the entry's title and last values, so that every device using the list removes it too. There is no way to clear these records yet.`}),U(`h2`,{children:`Sign-ins to other sites`}),k(`p`,{children:[`stub plays Crunchyroll and tracks your AniList and MyAnimeList lists with your own accounts on those sites. Without the FKN browser extension, you sign in on each site's own page, in an FKN window, and the cookies that sign-in sets are kept by FKN, in a cookie jar every fkn.app app shares, and not by stub. Signing out in `,U(os,{to:`/settings#accounts`,children:`Settings, under Accounts`}),`, removes that site's cookies from FKN. The site itself is not told, so its session stays valid there until it expires, held by nobody.`]}),U(`p`,{children:`With the extension, stub uses your browser's own sessions for these sites and for Netflix. Those stay in your browser, and you sign in and out of them on the sites themselves.`}),U(`h2`,{children:`Network requests & third parties`}),k(`p`,{children:[`To fetch titles, artwork, and streams, stub sends requests through the FKN platform proxy, which then reaches third-party services such as AniList, MyAnimeList, Crunchyroll, JustWatch, and Netflix. The proxy requires no account. It uses your IP address to rate-limit requests, and it keeps a copy of each answer for a while, under a key made from the whole request (its address, headers and body), so only an identical request is answered from that copy. How the FKN platform handles that data is described in the`,` `,U(`a`,{href:`https://fkn.app/privacy`,target:`_blank`,rel:`noreferrer noopener`,children:`FKN platform privacy policy`}),`. Each third-party service receives the requests made to it and applies its own privacy policy, especially when you sign in to one (for example Crunchyroll) to watch.`]}),U(`h2`,{children:`The optional browser extension`}),U(`p`,{children:`If you install the FKN browser extension, it works with your own already-logged-in sessions locally on your device so you can play content you have access to. Those credentials stay in your browser; stub never receives them.`}),U(`h2`,{children:`Your control`}),U(`p`,{children:`Disconnecting from FKN, in the account menu at the top right, takes your account's list off the device. Your party name and the party you are in go when you close the tab. If you use the browser extension, you can review and revoke its access at any time from the extension itself.`}),U(`h2`,{children:`Contact`}),k(`p`,{children:[`Questions about privacy can be raised through the project repository at`,` `,U(`a`,{href:`https://github.com/banou26/stub`,target:`_blank`,rel:`noreferrer noopener`,children:`github.com/banou26/stub`}),`.`]})]});j();var Bj=({label:e,name:t=e,confirmLabel:n,busyLabel:r,question:i,onConfirm:a,home:o})=>{let[s,c]=B(!1),[l,u]=B(!1),d=R(null),f=R(null),p=R(null),m=R(!1),h=R(!0),g=he(),_=()=>{let e=document.activeElement;return!e||e===document.body||!!p.current?.contains(e)};return O(()=>()=>{h.current=!1,p.current&&_()&&o?.current?.focus()},[]),_e(()=>{s?f.current?.focus():m.current&&d.current?.focus(),m.current=!1},[s]),s?k(`div`,{ref:p,className:`confirm`,role:`group`,"aria-label":t,children:[U(`p`,{id:g,children:i}),k(`div`,{className:`actions`,children:[U(`button`,{type:`button`,className:`danger`,"aria-describedby":g,disabled:l,onClick:()=>{u(!0),Promise.resolve().then(a).catch(()=>{}).finally(()=>{if(!h.current)return;let e=_();u(!1),c(!1),e&&(o?.current?o.current.focus():m.current=!0)})},children:l?r:n}),U(`button`,{ref:f,type:`button`,className:`secondary`,"aria-describedby":g,disabled:l,onClick:()=>{m.current=!0,c(!1)},children:`Cancel`})]})]}):U(`button`,{ref:d,type:`button`,className:`secondary`,"aria-label":t===e?void 0:t,onClick:()=>c(!0),children:e})};j();var Vj=e=>e instanceof Error?e.message:String(e),Hj=(e,t)=>{switch(t){case`authed`:return{text:`Signed in to ${e}.`};case`closed`:return{text:`The sign-in window closed. If you finished signing in there, stub reads it from now on.`};case`blocked`:return{text:`The browser blocked the sign-in window. Allow pop-ups for this page and try again.`,error:!0};case`unsupported`:return{text:`Connected to your browser's own ${e} session.`}}},Uj={"signed-in":`Signed in`,"signed-out":`Signed out`},Wj=(e,t)=>{let n=XA(t-e.checkedAt,1);return`${Uj[e.state]}, checked ${n?`${n} ago`:`just now`}`},Gj=(e,t)=>{let[,n]=B(0);return O(()=>e.watch(t,()=>n(e=>e+1)),[e,t]),e.read(t)},Kj=({site:e,name:t,backend:n,status:r,onNote:i})=>{let[a,o]=B(!1),s=Yj();return U(`button`,{type:`button`,className:`secondary`,disabled:a,"aria-label":`Check whether you are signed in to ${t}`,onClick:()=>{o(!0),i(void 0),r.check(e,n).catch(e=>{s.current&&i({text:`stub could not tell whether you are signed in to ${t}: ${Vj(e)}`,error:!0})}).finally(()=>{s.current&&o(!1)})},children:a?`Checking...`:`Check now`})},qj=({id:e,title:t,state:n,on:r,heading:i,children:a})=>k(`div`,{className:`row account`,"data-account":e,children:[k(`div`,{className:`head`,children:[U(`h3`,{ref:i,tabIndex:-1,children:t}),n?U(`span`,{className:`state${r?` on`:``}`,children:n}):void 0]}),a]}),Jj=({note:e})=>U(`p`,{className:`note${e?.error?` error`:``}`,role:`status`,children:e?.text}),Yj=()=>{let e=R(!0);return O(()=>()=>{e.current=!1},[]),e},Xj=`Without the FKN extension, the session is kept by FKN, in the cookie jar every fkn.app app shares, and not by stub.`,Zj=e=>`${e} itself is not told, so the session stays valid there until it expires, held by nobody.`,Qj=({backend:e,crunchyroll:t,status:n,now:r})=>{let[i,a]=B(!1),[o,s]=B(),c=Yj(),l=R(null),u=Gj(n,`crunchyroll`),d=e?U(Kj,{site:`crunchyroll`,name:`Crunchyroll`,backend:e,status:n,onNote:s}):void 0;return k(qj,{id:`crunchyroll`,title:`Crunchyroll`,state:u?Wj(u,r()):`Not checked yet`,on:u?.state===`signed-in`,heading:l,children:[U(`p`,{children:`Plays Crunchyroll episodes on your own Crunchyroll account.`}),e===`cloud`?k(H,{children:[k(`p`,{children:[Xj,` Check now asks Crunchyroll whether that session is signed in, without loading a Crunchyroll page.`]}),k(`div`,{className:`actions`,children:[u?.state===`signed-in`?void 0:U(`button`,{type:`button`,disabled:i,onClick:()=>{let e=t.signIn();a(!0),s(void 0),e.then(e=>{c.current&&s(Hj(`Crunchyroll`,e))}).catch(e=>{c.current&&s({text:Vj(e),error:!0})}).finally(()=>{c.current&&a(!1)})},children:i?`Signing in...`:`Sign in`}),u?.state===`signed-out`?void 0:U(Bj,{label:`Sign out`,name:`Sign out of Crunchyroll`,home:l,confirmLabel:`Yes, sign out`,busyLabel:`Signing out...`,question:`Sign out of Crunchyroll? This removes its cookies from FKN's jar, which signs every fkn.app app out of Crunchyroll. ${Zj(`Crunchyroll`)}`,onConfirm:()=>t.signOut().then(()=>{c.current&&s({text:`Signed out. FKN no longer holds a Crunchyroll session for fkn.app apps.`})},e=>{c.current&&s({text:`FKN could not remove the Crunchyroll cookies: ${Vj(e)}. Try again.`,error:!0})})}),d]})]}):e===`extension`?k(H,{children:[U(`p`,{children:`With the FKN extension, stub plays it on your browser's own crunchyroll.com session and keeps nothing of it. Sign in and out on crunchyroll.com.`}),k(`div`,{className:`actions`,children:[U(`a`,{className:`link`,href:`https://www.crunchyroll.com`,target:`_blank`,rel:`noreferrer`,children:`Open crunchyroll.com`}),d]})]}):U(`p`,{children:`Checking whether the FKN extension runs here...`}),U(Jj,{note:o})]})},$j=[{site:`anilist`,name:`AniList`,host:`anilist.co`},{site:`mal`,name:`MyAnimeList`,host:`myanimelist.net`}],eM=({site:e,name:t,host:n,backend:r,sites:i,status:a,now:o})=>{let[s,c]=B(()=>i.isConnected(e)),[l,u]=B(!1),[d,f]=B(),p=Yj(),m=R(null),h=Gj(a,e);O(()=>(c(i.isConnected(e)),i.watch(e,()=>{p.current&&c(i.isConnected(e))})),[i,e]);let g=()=>{p.current&&c(i.isConnected(e))},_=()=>{let n=i.signIn(e);u(!0),f(void 0),n.then(e=>{p.current&&f(Hj(t,e))}).catch(e=>{p.current&&f({text:Vj(e),error:!0})}).finally(()=>{p.current&&u(!1),g()})},v=r=>i.signOut(e,r).then(()=>{p.current&&f({text:r===`cloud`?`Signed out. stub no longer uses ${t} on this device, and FKN no longer holds its session.`:`Disconnected. To sign out of ${t} itself, sign out on ${n}.`}),g()},e=>{p.current&&f({text:`Disconnected on this device, but FKN could not remove the ${t} cookies: ${Vj(e)}. Sign in and out again to retry.`,error:!0}),g()});return k(qj,{id:e,title:t,state:s?h?Wj(h,o()):`Connected on this device`:`Not connected`,on:s&&h?.state!==`signed-out`,heading:m,children:[k(`p`,{children:[`Tracks your `,t,` list with your own `,n,` session.`,` `,r===`cloud`?Xj:r===`extension`?`With the FKN extension, stub uses your browser's own ${n} session.`:``]}),r?k(`div`,{className:`actions`,children:[s?U(Bj,{label:r===`cloud`?`Sign out`:`Disconnect`,name:r===`cloud`?`Sign out of ${t}`:`Disconnect ${t}`,home:m,confirmLabel:r===`cloud`?`Yes, sign out`:`Yes, disconnect`,busyLabel:r===`cloud`?`Signing out...`:`Disconnecting...`,question:r===`cloud`?`Sign out of ${t}? stub stops using it on this device, and its cookies leave FKN's jar, which signs every fkn.app app out of ${t}. ${Zj(t)}`:`Disconnect ${t}? stub stops using your ${n} session on this device. You stay signed in on ${n}.`,onConfirm:()=>v(r)}):U(`button`,{type:`button`,disabled:l,onClick:_,children:l?`Signing in...`:r===`cloud`?`Sign in`:`Connect`}),s?U(Kj,{site:e,name:t,backend:r,status:a,onNote:f}):void 0]}):void 0,U(Jj,{note:d})]})},tM=({backend:e})=>U(qj,{id:`netflix`,title:`Netflix`,children:e===`extension`?k(H,{children:[U(`p`,{children:`stub plays Netflix on your browser's own netflix.com session, through the FKN extension, and keeps nothing of it. Sign in and out on netflix.com.`}),U(`div`,{className:`actions`,children:U(`a`,{className:`link`,href:`https://www.netflix.com`,target:`_blank`,rel:`noreferrer`,children:`Open netflix.com`})})]}):U(`p`,{children:`Netflix needs the FKN browser extension: stub plays it on your browser's own netflix.com session, and keeps nothing of it.`})}),nM=({backend:e,crunchyroll:t,sites:n,status:r,now:i=Date.now})=>k(`div`,{className:`rows`,children:[U(Qj,{backend:e,crunchyroll:t,status:r,now:i}),$j.map(t=>U(eM,{...t,backend:e,sites:n,status:r,now:i},t.site)),U(tM,{backend:e})]}),rM=[{id:`accounts`,title:`Accounts`,intro:`The sites where stub uses your own account, what each one is for, and how to sign out.`},{id:`sources`,title:`Sources`,intro:`Where stub gets titles, artwork and streams: the sources it ships with, and the ones you add.`}],iM=e=>rM.find(t=>`#${t.id}`===e)?.id??`accounts`,aM=[{origin:`mal`,name:`MyAnimeList`,url:`https://myanimelist.net`},{origin:`anilist`,name:`AniList`,url:`https://anilist.co`},{origin:`anizip`,name:`AniZip`,url:`https://api.ani.zip/`},{origin:`cr`,name:`Crunchyroll`,url:`https://www.crunchyroll.com`},{origin:`nf`,name:`Netflix`,url:`https://www.netflix.com`},{origin:`jw`,name:`JustWatch`,url:`https://www.justwatch.com`},{origin:`appletv`,name:`Apple TV+`,url:`https://tv.apple.com`},{origin:`paramount`,name:`Paramount+`,url:`https://www.paramountplus.com`},{origin:`disney`,name:`Disney+`,url:`https://www.disneyplus.com`},{origin:`amazon`,name:`Prime Video`,url:`https://www.primevideo.com`},{origin:`hulu`,name:`Hulu`,url:`https://www.hulu.com`},{origin:`peacock`,name:`Peacock`,url:`https://www.peacocktv.com`},{origin:`hbo`,name:`Max`,url:`https://www.max.com`},{origin:`fubo`,name:`Fubo`,url:`https://www.fubo.tv`},{origin:`tmdb`,name:`TMDB`,url:`https://www.themoviedb.org`},{origin:`tvmaze`,name:`TVmaze`,url:`https://www.tvmaze.com`},{origin:`kitsu`,name:`Kitsu`,url:`https://kitsu.io`},{origin:`livechart`,name:`LiveChart`,url:`https://www.livechart.me`},{origin:`omdb`,name:`IMDb`,url:`https://www.imdb.com`},{origin:`trakt`,name:`Trakt`,url:`https://trakt.tv`},{origin:`simkl`,name:`Simkl`,url:`https://simkl.com`},{origin:`tvdb`,name:`TheTVDB`,url:`https://www.thetvdb.com`},{origin:`offline`,name:`Offline database`,url:`https://github.com/manami-project/anime-offline-database`},{origin:`watchmode`,name:`Watchmode`,url:`https://www.watchmode.com`}];j();var oM=x`
|
|
3039
3039
|
h3.part {
|
|
3040
3040
|
font-size: 1.3rem;
|
|
3041
3041
|
font-weight: 700;
|
|
@@ -3791,7 +3791,7 @@ animation: overlayShow 150ms cubic-bezier(0.16, 1, 0.3, 1);
|
|
|
3791
3791
|
}
|
|
3792
3792
|
}
|
|
3793
3793
|
}
|
|
3794
|
-
`,iN=(e,t)=>{let n=e?.data?.media;return{payloads:t,uri:typeof n?.uri==`string`?n.uri:null,handles:Array.isArray(n?.handles)?n.handles.length:0,episodes:Array.isArray(n?.episodes)?n.episodes.length:0}},aN=async(e,{onProgress:t,settleMs:n=25e3}={})=>{let r={payloads:0,uri:null,handles:0,episodes:0};if(!e)return r;try{let i=await Ne(()=>import(`./worker-
|
|
3794
|
+
`,iN=(e,t)=>{let n=e?.data?.media;return{payloads:t,uri:typeof n?.uri==`string`?n.uri:null,handles:Array.isArray(n?.handles)?n.handles.length:0,episodes:Array.isArray(n?.episodes)?n.episodes.length:0}},aN=async(e,{onProgress:t,settleMs:n=25e3}={})=>{let r={payloads:0,uri:null,handles:0,episodes:0};if(!e)return r;try{let i=await Ne(()=>import(`./worker-CrS-zxdF.js`),__vite__mapDeps([0,1,2,3,4,5,6]),import.meta.url);if(typeof i.handleRequest!=`function`)return r;await nN(i.handleRequest,rN,{input:{uri:e}},{settleMs:n,onPayload:(e,n)=>{r=iN(e,n),t?.(r)}})}catch(e){console.error(Error(`graph trace: the warm could not ask the sources`,{cause:e}))}return r},oN=x`
|
|
3795
3795
|
&.nothing {
|
|
3796
3796
|
color: rgb(250, 204, 21);
|
|
3797
3797
|
font-style: italic;
|
|
@@ -4164,7 +4164,7 @@ animation: overlayShow 150ms cubic-bezier(0.16, 1, 0.3, 1);
|
|
|
4164
4164
|
|
|
4165
4165
|
.columns { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
|
|
4166
4166
|
@media (max-width: 900px) { .columns { grid-template-columns: 1fr; } }
|
|
4167
|
-
`,IN=1500,LN=({label:e,value:t})=>k(`div`,{children:[U(`span`,{className:`label`,children:e}),U(`code`,{children:U(sN,{value:t})})]}),RN=({reason:e})=>e===`null`?U(`code`,{className:`token`,"data-token-reason":!0,children:`"null"`}):U(sN,{value:e}),zN=({load:e=eh,loadAnswerBytes:t=th,warm:n=aN})=>{let r=$o(),[,i]=Qo(),a=uh(r),[o,s]=B(a),[c,l]=B({kind:`idle`}),[u,d]=B(0),[f,p]=B({kind:`off`}),[m,h]=B([]),g=R(``),_=R(void 0);O(()=>{s(a),h([]),p({kind:`off`}),g.current=``,_.current!==void 0&&clearTimeout(_.current),_.current=void 0},[a]),O(()=>{if(!a){l({kind:`idle`});return}let t=!0;return l(e=>e.kind===`done`?e:{kind:`loading`}),e(a).then(e=>{t&&l({kind:`done`,bundle:e})}).catch(e=>{t&&l({kind:`failed`,error:e instanceof Error?e.message:String(e)})}),()=>{t=!1}},[a,u]);let v=c.kind===`done`?c.bundle:void 0,y=V(()=>v?JM(v):new Map,[v]),b=m[m.length-1],x=!(!v||v.resolved||v.reason===`not-enabled`);return O(()=>{if(!a||!x||g.current===a)return;g.current=a;let e=a,t=()=>g.current===e,r=()=>{_.current===void 0&&(_.current=setTimeout(()=>{_.current=void 0,t()&&d(e=>e+1)},IN))};p({kind:`asking`,progress:{payloads:0,uri:null,handles:0,episodes:0}}),n(a,{onProgress:e=>{t()&&(p({kind:`asking`,progress:e}),r())}}).then(e=>{t()&&(p({kind:`done`,progress:e}),d(e=>e+1))}).catch(()=>{t()&&p({kind:`off`})})},[a,x]),O(()=>()=>{g.current=``,_.current!==void 0&&clearTimeout(_.current)},[]),k(`div`,{css:FN,"data-debug-trace":!0,children:[U(`h1`,{children:`Graph trace`}),U(`p`,{className:`intro`,children:`Everything the graph holds for one cluster: its members, every link between them including the refused ones, the episodes it resolved to, and the answer each edge came from. Nothing here is derived, and a value the graph does not carry shows as null. The graph is built inside this tab, so a uri nothing has asked about yet is asked about here first, which is what makes this url worth pasting into a bug report.`}),k(`form`,{className:`ask`,onSubmit:e=>{e.preventDefault();let t=o.trim();t&&(d(e=>e+1),i(rh({uri:t})))},children:[U(`input`,{type:`text`,autoComplete:`off`,spellcheck:!1,placeholder:`ag:(mal:39535,anilist:101280), or a member uri like mal:39535, or a cluster id like cl:...`,value:o,onInput:e=>s(e.target.value)}),U(`button`,{type:`submit`,children:`Trace`})]}),c.kind===`idle`&&U(`p`,{className:`empty`,children:`Give it a uri. It rides in the url, so this page can be linked into a bug report.`}),f.kind!==`off`&&U(`p`,{className:f.kind===`asking`?`warming`:`warming done`,"data-warming":f.kind,"data-answered":f.progress.payloads,children:f.kind===`asking`?`asking the sources about ${a}: ${f.progress.payloads} answer(s) so far, ${f.progress.handles} handle(s), ${f.progress.episodes} episode(s). All 24 sources are asked, so a cold graph takes tens of seconds. The panel fills as they answer and stops waiting on its own.`:f.progress.payloads===0?`nothing answered about ${a}. All 24 sources were asked and none returned a row, so the graph stayed empty: either no source recognises that uri, or every one of them refused it. Nothing is still loading.`:`the sources have stopped answering about ${a}: ${f.progress.payloads} answer(s), ${f.progress.handles} handle(s), ${f.progress.episodes} episode(s). What is below is what that produced.`}),c.kind===`loading`&&k(`p`,{className:`empty`,"data-loading":!0,children:[`tracing `,a,`…`]}),c.kind===`failed`&&U(`p`,{className:`failed`,"data-failed":!0,children:c.error}),v&&k(H,{children:[v.resolved?k(`div`,{className:`resolved`,"data-resolved":!0,children:[k(`div`,{className:`pairs`,children:[U(LN,{label:`asked`,value:v.asked}),U(LN,{label:`cluster`,value:v.resolved.clusterId}),U(LN,{label:`aggregate`,value:v.resolved.aggUri}),U(LN,{label:`scope`,value:v.resolved.scope}),U(LN,{label:`kind`,value:v.resolved.kind})]}),(v.resolved.otherClusters??[]).length>0&&k(`div`,{className:`split`,"data-other-clusters":!0,children:[`This address also reaches`,` `,v.resolved.otherClusters.length,` other cluster(s), whose members are not below:`,` `,v.resolved.otherClusters.map(e=>U(`a`,{href:rh({uri:e,search:r}),children:U(`code`,{children:e})},e))]})]}):k(`div`,{className:`unresolved`,"data-unresolved":!0,"data-reason":v.reason??`none`,children:[U(`div`,{className:`why`,children:eN(v.reason)}),v.reason===`not-enabled`&&k(`div`,{className:`advice`,children:[U(`a`,{"data-reload-graph":!0,href:ah(r),children:`Reload with ?graph=1`}),` or `,U(`a`,{"data-reload-store":!0,href:oh(r),children:`drop ?store=legacy`}),`, keeping this uri.`]}),k(`div`,{className:`pairs`,children:[U(LN,{label:`asked`,value:v.asked}),U(LN,{label:`reason`,value:v.reason??null})]})]}),k(`div`,{className:`pairs`,"data-run-length":!0,children:[U(LN,{label:`run length`,value:v.runLength?.value??null}),U(LN,{label:`from`,value:v.runLength?.from??null}),U(LN,{label:`tier`,value:v.runLength?.tier??null}),U(LN,{label:`witnesses`,value:v.runLength?.witnesses??null})]}),k(`div`,{className:`pairs`,"data-cost":!0,children:[U(LN,{label:`statements`,value:v.cost?.statements??null}),U(LN,{label:`ms to build`,value:v.cost?.ms??null})]}),U(`h3`,{children:`Graph counts`}),U(`div`,{className:`chips`,"data-counts":!0,children:Object.entries(v.counts??{}).length===0?U(`span`,{className:`empty`,children:`the bundle carries no counts`}):Object.entries(v.counts).map(([e,t])=>U(`span`,{className:`chip`,children:`${e} ${t}`},e))}),k(`div`,{className:`columns`,children:[k(`div`,{children:[U(`h3`,{children:`Anomalies`}),(v.anomalies??[]).length===0?U(`p`,{className:`empty`,children:`no rule complained`}):U(`table`,{"data-anomalies":!0,children:U(`tbody`,{children:v.anomalies.map((e,t)=>k(`tr`,{children:[U(`td`,{children:e.rule}),U(`td`,{children:e.detail})]},`${e.rule} ${e.detail} ${t}`))})})]}),k(`div`,{children:[U(`h3`,{children:`Asks`}),(v.asks??[]).length===0?U(`p`,{className:`empty`,children:`nothing was asked of any origin`}):k(`table`,{"data-asks":!0,children:[U(`thead`,{children:k(`tr`,{children:[U(`th`,{children:`seq`}),U(`th`,{children:`origin`}),U(`th`,{children:`outcome`}),U(`th`,{children:`reason`})]})}),U(`tbody`,{children:v.asks.map((e,t)=>k(`tr`,{"data-ask":e.origin,children:[U(`td`,{children:U(sN,{value:e.seq??null})}),U(`td`,{children:e.origin}),U(`td`,{children:e.outcome}),U(`td`,{children:U(RN,{reason:e.reason})})]},`${e.origin} ${e.seq??t}`))})]})]})]}),U(`h2`,{children:`Media graph`}),U(wN,{bundle:v,selected:b,onSelect:e=>h([e])}),U(`h3`,{children:`Links`}),(v.links??[]).length===0?U(`p`,{className:`empty`,children:`no links, refused or otherwise`}):k(`table`,{"data-links":!0,children:[U(`thead`,{children:k(`tr`,{children:[U(`th`,{children:`from`}),U(`th`,{children:`to`}),U(`th`,{children:`kind`}),U(`th`,{children:`status`}),U(`th`,{children:`by`}),U(`th`,{children:`rule`}),U(`th`,{children:`confidence`}),U(`th`,{})]})}),U(`tbody`,{children:v.links.map(e=>k(`tr`,{"data-link":e.key,"data-status":e.status,className:b===e.key?`selected`:void 0,children:[U(`td`,{className:`uri`,children:e.fromUri}),U(`td`,{className:`uri`,children:e.toUri}),U(`td`,{children:e.kind}),U(`td`,{children:U(`span`,{className:`status ${tN(e.status)?`active`:`refused`}`,children:e.status})}),U(`td`,{children:e.by}),U(`td`,{children:e.reason}),U(`td`,{children:U(sN,{value:e.confidence})}),U(`td`,{children:U(`button`,{type:`button`,className:`inspect`,onClick:()=>h([e.key]),children:`Inspect`})})]},e.key))})]}),U(`h3`,{children:`Claims`}),(v.claims??[]).length===0?U(`p`,{className:`empty`,children:`no claims between the uris this bundle names`}):k(`table`,{"data-claims":!0,children:[U(`thead`,{children:k(`tr`,{children:[U(`th`,{children:`from`}),U(`th`,{children:`to`}),U(`th`,{children:`kind`}),U(`th`,{children:`claimer`}),U(`th`,{children:`provenance`}),U(`th`,{children:`answer`}),U(`th`,{children:`target scope`}),U(`th`,{})]})}),U(`tbody`,{children:v.claims.map(e=>k(`tr`,{"data-claim":e.key,className:b===e.key?`selected`:void 0,children:[U(`td`,{className:`uri`,children:e.fromUri}),U(`td`,{className:`uri`,children:e.toUri}),U(`td`,{children:e.kind}),U(`td`,{children:e.claimer}),U(`td`,{children:e.provenance}),U(`td`,{children:e.answerSeq}),U(`td`,{children:U(sN,{value:e.targetScope})}),U(`td`,{children:U(`button`,{type:`button`,className:`inspect`,onClick:()=>h([e.key]),children:`Inspect`})})]},e.key))})]}),U(`h3`,{children:`Attachments`}),(v.attachments??[]).length===0?U(`p`,{className:`empty`,children:`no run is attached to a container here`}):k(`table`,{"data-attachments":!0,children:[U(`thead`,{children:k(`tr`,{children:[U(`th`,{children:`run`}),U(`th`,{children:`container`}),U(`th`,{children:`via`}),U(`th`,{children:`by`}),U(`th`,{children:`evidence`}),U(`th`,{children:`supports`})]})}),U(`tbody`,{children:v.attachments.map(e=>k(`tr`,{children:[U(`td`,{className:`uri`,children:e.runUri}),U(`td`,{className:`uri`,children:e.containerUri}),U(`td`,{children:e.via}),U(`td`,{children:e.by}),U(`td`,{className:`uri`,children:U(sN,{value:e.evidence})}),U(`td`,{children:(e.supports??[]).length===0?U(sN,{value:null}):e.supports.map(e=>U(`button`,{type:`button`,className:`inspect`,"data-attachment-support":e,onClick:()=>h([e]),children:e},e))})]},`${e.runUri} ${e.containerUri} ${e.via} ${e.by}`))})]}),U(`h2`,{children:`Episodes`}),U(PN,{bundle:v,index:y,selected:b,onSelect:e=>h([e])}),U(`h2`,{children:`Inspector`}),U(jN,{bundle:v,index:y,trail:m,onFollow:e=>h(t=>[...t,e]),onTrailTo:e=>h(t=>t.slice(0,e+1)),loadAnswerBytes:t})]})]})},BN=`[data-party-scroll]`,VN=()=>{let e=document.querySelectorAll(BN);for(let t=e.length-1;t>=0;t--){let n=e[t];if(n.scrollHeight-n.clientHeight>0)return n}},HN=(e,t)=>t>0?Math.min(1,Math.max(0,e/t)):0,UN=()=>{let e=VN();return e?Math.max(0,e.scrollHeight-e.clientHeight):Math.max(0,document.documentElement.scrollHeight-window.innerHeight)},WN=()=>{let e=VN();return e?HN(e.scrollTop,e.scrollHeight-e.clientHeight):HN(window.scrollY,document.documentElement.scrollHeight-window.innerHeight)},GN=()=>{try{return window.matchMedia?.(`(prefers-reduced-motion: reduce)`)?.matches===!0}catch{return!1}},KN=(e,t,n)=>!e||GN()?`instant`:t<=n*2?`smooth`:`instant`,qN=(e,{smooth:t}={})=>{let n=VN();if(n){let r=n.scrollHeight-n.clientHeight,i=r>0?e*r:0;n.scrollTo({top:i,behavior:KN(t,Math.abs(i-n.scrollTop),n.clientHeight)});return}let r=document.documentElement.scrollHeight-window.innerHeight,i=r>0?e*r:0;window.scrollTo({top:i,behavior:KN(t,Math.abs(i-window.scrollY),window.innerHeight)})};j();var JN=2,YN=8e3,XN=[`wheel`,`touchstart`,`keydown`,`pointerdown`],ZN=60,QN=()=>{let e=Ap(),[t,n]=Qo(),r=$o(),i=r?`${t}?${r}`:t,a=e.status===`active`?e.role:void 0,o=t===Sp;O(()=>{a!==`host`||o||(X.setLocation(i,WN()),X.send({t:`nav`,path:i}))},[a,i,o]),O(()=>{if(a!==`host`||o)return;let e=0,t,n=()=>{t=void 0,e=Date.now();let n=WN();X.setLocation(i,n),X.send({t:`scroll`,y:n})},r=()=>{if(t)return;let r=Math.max(0,1e3/JN-(Date.now()-e));t=setTimeout(n,r)};return document.addEventListener(`scroll`,r,{passive:!0,capture:!0}),()=>{document.removeEventListener(`scroll`,r,{capture:!0}),t&&clearTimeout(t)}},[a,i]);let s=R(void 0),c=R(0);O(()=>{if(s.current===void 0)return;let e=s.current;s.current=void 0;let t=0,n=-1,r=0,i=!1,a=c.current,o=Date.now()+YN,l=()=>{i=!0};for(let e of XN)document.addEventListener(e,l,{passive:!0});let u=()=>{cancelAnimationFrame(t);for(let e of XN)document.removeEventListener(e,l)};if(El(),e===0)return qN(0),u;let d=()=>{let s=UN();s===n?r+=1:(r=0,n=s);let l=s>0&&r>=ZN;if(i||c.current!==a||l||Date.now()>o)return u();qN(e),t=requestAnimationFrame(d)};return t=requestAnimationFrame(d),u},[i]);let l=R(!1),u=e.status===`active`?e.invite:void 0;O(()=>{l.current=!1},[u]);let d=(e,t)=>{l.current=!0,e===i?(El(),c.current+=1,qN(t,{smooth:!0})):(s.current=t,n(e))};return jp((e,{replayed:t})=>{if(a===`guest`)switch(e.t){case`nav`:l.current=!0,e.path!==i&&n(e.path);return;case`scroll`:X.hostPath()===i&&(El(),c.current+=1,qN(e.y,{smooth:!0}));return;case`state`:(!l.current||t)&&d(e.path,e.y);return}}),null};j();var $N=4,eP=2500,tP=x`
|
|
4167
|
+
`,IN=1500,LN=({label:e,value:t})=>k(`div`,{children:[U(`span`,{className:`label`,children:e}),U(`code`,{children:U(sN,{value:t})})]}),RN=({reason:e})=>e===`null`?U(`code`,{className:`token`,"data-token-reason":!0,children:`"null"`}):U(sN,{value:e}),zN=({load:e=eh,loadAnswerBytes:t=th,warm:n=aN})=>{let r=$o(),[,i]=Qo(),a=uh(r),[o,s]=B(a),[c,l]=B({kind:`idle`}),[u,d]=B(0),[f,p]=B({kind:`off`}),[m,h]=B([]),g=R(``),_=R(void 0);O(()=>{s(a),h([]),p({kind:`off`}),g.current=``,_.current!==void 0&&clearTimeout(_.current),_.current=void 0},[a]),O(()=>{if(!a){l({kind:`idle`});return}let t=!0;return l(e=>e.kind===`done`?e:{kind:`loading`}),e(a).then(e=>{t&&l({kind:`done`,bundle:e})}).catch(e=>{t&&l({kind:`failed`,error:e instanceof Error?e.message:String(e)})}),()=>{t=!1}},[a,u]);let v=c.kind===`done`?c.bundle:void 0,y=V(()=>v?JM(v):new Map,[v]),b=m[m.length-1],x=!(!v||v.resolved||v.reason===`not-enabled`);return O(()=>{if(!a||!x||g.current===a)return;g.current=a;let e=a,t=()=>g.current===e,r=()=>{_.current===void 0&&(_.current=setTimeout(()=>{_.current=void 0,t()&&d(e=>e+1)},IN))};p({kind:`asking`,progress:{payloads:0,uri:null,handles:0,episodes:0}}),n(a,{onProgress:e=>{t()&&(p({kind:`asking`,progress:e}),r())}}).then(e=>{t()&&(p({kind:`done`,progress:e}),d(e=>e+1))}).catch(()=>{t()&&p({kind:`off`})})},[a,x]),O(()=>()=>{g.current=``,_.current!==void 0&&clearTimeout(_.current)},[]),k(`div`,{css:FN,"data-debug-trace":!0,children:[U(`h1`,{children:`Graph trace`}),U(`p`,{className:`intro`,children:`Everything the graph holds for one cluster: its members, every link between them including the refused ones, the episodes it resolved to, and the answer each edge came from. Nothing here is derived, and a value the graph does not carry shows as null. The graph is built inside this tab, so a uri nothing has asked about yet is asked about here first, which is what makes this url worth pasting into a bug report.`}),k(`form`,{className:`ask`,onSubmit:e=>{e.preventDefault();let t=o.trim();t&&(d(e=>e+1),i(rh({uri:t})))},children:[U(`input`,{type:`text`,autoComplete:`off`,spellcheck:!1,placeholder:`ag:(mal:39535,anilist:101280), or a member uri like mal:39535, or a cluster id like cl:...`,value:o,onInput:e=>s(e.target.value)}),U(`button`,{type:`submit`,children:`Trace`})]}),c.kind===`idle`&&U(`p`,{className:`empty`,children:`Give it a uri. It rides in the url, so this page can be linked into a bug report.`}),f.kind!==`off`&&U(`p`,{className:f.kind===`asking`?`warming`:`warming done`,"data-warming":f.kind,"data-answered":f.progress.payloads,children:f.kind===`asking`?`asking the sources about ${a}: ${f.progress.payloads} answer(s) so far, ${f.progress.handles} handle(s), ${f.progress.episodes} episode(s). Every source is asked, so a cold graph takes tens of seconds. The panel fills as they answer and stops waiting on its own.`:f.progress.payloads===0?`nothing answered about ${a}. Every source was asked and none returned a row, so the graph stayed empty: either no source recognises that uri, or every one of them refused it. Nothing is still loading.`:`the sources have stopped answering about ${a}: ${f.progress.payloads} answer(s), ${f.progress.handles} handle(s), ${f.progress.episodes} episode(s). What is below is what that produced.`}),c.kind===`loading`&&k(`p`,{className:`empty`,"data-loading":!0,children:[`tracing `,a,`…`]}),c.kind===`failed`&&U(`p`,{className:`failed`,"data-failed":!0,children:c.error}),v&&k(H,{children:[v.resolved?k(`div`,{className:`resolved`,"data-resolved":!0,children:[k(`div`,{className:`pairs`,children:[U(LN,{label:`asked`,value:v.asked}),U(LN,{label:`cluster`,value:v.resolved.clusterId}),U(LN,{label:`aggregate`,value:v.resolved.aggUri}),U(LN,{label:`scope`,value:v.resolved.scope}),U(LN,{label:`kind`,value:v.resolved.kind})]}),(v.resolved.otherClusters??[]).length>0&&k(`div`,{className:`split`,"data-other-clusters":!0,children:[`This address also reaches`,` `,v.resolved.otherClusters.length,` other cluster(s), whose members are not below:`,` `,v.resolved.otherClusters.map(e=>U(`a`,{href:rh({uri:e,search:r}),children:U(`code`,{children:e})},e))]})]}):k(`div`,{className:`unresolved`,"data-unresolved":!0,"data-reason":v.reason??`none`,children:[U(`div`,{className:`why`,children:eN(v.reason)}),v.reason===`not-enabled`&&k(`div`,{className:`advice`,children:[U(`a`,{"data-reload-graph":!0,href:ah(r),children:`Reload with ?graph=1`}),` or `,U(`a`,{"data-reload-store":!0,href:oh(r),children:`drop ?store=legacy`}),`, keeping this uri.`]}),k(`div`,{className:`pairs`,children:[U(LN,{label:`asked`,value:v.asked}),U(LN,{label:`reason`,value:v.reason??null})]})]}),k(`div`,{className:`pairs`,"data-run-length":!0,children:[U(LN,{label:`run length`,value:v.runLength?.value??null}),U(LN,{label:`from`,value:v.runLength?.from??null}),U(LN,{label:`tier`,value:v.runLength?.tier??null}),U(LN,{label:`witnesses`,value:v.runLength?.witnesses??null})]}),k(`div`,{className:`pairs`,"data-cost":!0,children:[U(LN,{label:`statements`,value:v.cost?.statements??null}),U(LN,{label:`ms to build`,value:v.cost?.ms??null})]}),U(`h3`,{children:`Graph counts`}),U(`div`,{className:`chips`,"data-counts":!0,children:Object.entries(v.counts??{}).length===0?U(`span`,{className:`empty`,children:`the bundle carries no counts`}):Object.entries(v.counts).map(([e,t])=>U(`span`,{className:`chip`,children:`${e} ${t}`},e))}),k(`div`,{className:`columns`,children:[k(`div`,{children:[U(`h3`,{children:`Anomalies`}),(v.anomalies??[]).length===0?U(`p`,{className:`empty`,children:`no rule complained`}):U(`table`,{"data-anomalies":!0,children:U(`tbody`,{children:v.anomalies.map((e,t)=>k(`tr`,{children:[U(`td`,{children:e.rule}),U(`td`,{children:e.detail})]},`${e.rule} ${e.detail} ${t}`))})})]}),k(`div`,{children:[U(`h3`,{children:`Asks`}),(v.asks??[]).length===0?U(`p`,{className:`empty`,children:`nothing was asked of any origin`}):k(`table`,{"data-asks":!0,children:[U(`thead`,{children:k(`tr`,{children:[U(`th`,{children:`seq`}),U(`th`,{children:`origin`}),U(`th`,{children:`outcome`}),U(`th`,{children:`reason`})]})}),U(`tbody`,{children:v.asks.map((e,t)=>k(`tr`,{"data-ask":e.origin,children:[U(`td`,{children:U(sN,{value:e.seq??null})}),U(`td`,{children:e.origin}),U(`td`,{children:e.outcome}),U(`td`,{children:U(RN,{reason:e.reason})})]},`${e.origin} ${e.seq??t}`))})]})]})]}),U(`h2`,{children:`Media graph`}),U(wN,{bundle:v,selected:b,onSelect:e=>h([e])}),U(`h3`,{children:`Links`}),(v.links??[]).length===0?U(`p`,{className:`empty`,children:`no links, refused or otherwise`}):k(`table`,{"data-links":!0,children:[U(`thead`,{children:k(`tr`,{children:[U(`th`,{children:`from`}),U(`th`,{children:`to`}),U(`th`,{children:`kind`}),U(`th`,{children:`status`}),U(`th`,{children:`by`}),U(`th`,{children:`rule`}),U(`th`,{children:`confidence`}),U(`th`,{})]})}),U(`tbody`,{children:v.links.map(e=>k(`tr`,{"data-link":e.key,"data-status":e.status,className:b===e.key?`selected`:void 0,children:[U(`td`,{className:`uri`,children:e.fromUri}),U(`td`,{className:`uri`,children:e.toUri}),U(`td`,{children:e.kind}),U(`td`,{children:U(`span`,{className:`status ${tN(e.status)?`active`:`refused`}`,children:e.status})}),U(`td`,{children:e.by}),U(`td`,{children:e.reason}),U(`td`,{children:U(sN,{value:e.confidence})}),U(`td`,{children:U(`button`,{type:`button`,className:`inspect`,onClick:()=>h([e.key]),children:`Inspect`})})]},e.key))})]}),U(`h3`,{children:`Claims`}),(v.claims??[]).length===0?U(`p`,{className:`empty`,children:`no claims between the uris this bundle names`}):k(`table`,{"data-claims":!0,children:[U(`thead`,{children:k(`tr`,{children:[U(`th`,{children:`from`}),U(`th`,{children:`to`}),U(`th`,{children:`kind`}),U(`th`,{children:`claimer`}),U(`th`,{children:`provenance`}),U(`th`,{children:`answer`}),U(`th`,{children:`target scope`}),U(`th`,{})]})}),U(`tbody`,{children:v.claims.map(e=>k(`tr`,{"data-claim":e.key,className:b===e.key?`selected`:void 0,children:[U(`td`,{className:`uri`,children:e.fromUri}),U(`td`,{className:`uri`,children:e.toUri}),U(`td`,{children:e.kind}),U(`td`,{children:e.claimer}),U(`td`,{children:e.provenance}),U(`td`,{children:e.answerSeq}),U(`td`,{children:U(sN,{value:e.targetScope})}),U(`td`,{children:U(`button`,{type:`button`,className:`inspect`,onClick:()=>h([e.key]),children:`Inspect`})})]},e.key))})]}),U(`h3`,{children:`Attachments`}),(v.attachments??[]).length===0?U(`p`,{className:`empty`,children:`no run is attached to a container here`}):k(`table`,{"data-attachments":!0,children:[U(`thead`,{children:k(`tr`,{children:[U(`th`,{children:`run`}),U(`th`,{children:`container`}),U(`th`,{children:`via`}),U(`th`,{children:`by`}),U(`th`,{children:`evidence`}),U(`th`,{children:`supports`})]})}),U(`tbody`,{children:v.attachments.map(e=>k(`tr`,{children:[U(`td`,{className:`uri`,children:e.runUri}),U(`td`,{className:`uri`,children:e.containerUri}),U(`td`,{children:e.via}),U(`td`,{children:e.by}),U(`td`,{className:`uri`,children:U(sN,{value:e.evidence})}),U(`td`,{children:(e.supports??[]).length===0?U(sN,{value:null}):e.supports.map(e=>U(`button`,{type:`button`,className:`inspect`,"data-attachment-support":e,onClick:()=>h([e]),children:e},e))})]},`${e.runUri} ${e.containerUri} ${e.via} ${e.by}`))})]}),U(`h2`,{children:`Episodes`}),U(PN,{bundle:v,index:y,selected:b,onSelect:e=>h([e])}),U(`h2`,{children:`Inspector`}),U(jN,{bundle:v,index:y,trail:m,onFollow:e=>h(t=>[...t,e]),onTrailTo:e=>h(t=>t.slice(0,e+1)),loadAnswerBytes:t})]})]})},BN=`[data-party-scroll]`,VN=()=>{let e=document.querySelectorAll(BN);for(let t=e.length-1;t>=0;t--){let n=e[t];if(n.scrollHeight-n.clientHeight>0)return n}},HN=(e,t)=>t>0?Math.min(1,Math.max(0,e/t)):0,UN=()=>{let e=VN();return e?Math.max(0,e.scrollHeight-e.clientHeight):Math.max(0,document.documentElement.scrollHeight-window.innerHeight)},WN=()=>{let e=VN();return e?HN(e.scrollTop,e.scrollHeight-e.clientHeight):HN(window.scrollY,document.documentElement.scrollHeight-window.innerHeight)},GN=()=>{try{return window.matchMedia?.(`(prefers-reduced-motion: reduce)`)?.matches===!0}catch{return!1}},KN=(e,t,n)=>!e||GN()?`instant`:t<=n*2?`smooth`:`instant`,qN=(e,{smooth:t}={})=>{let n=VN();if(n){let r=n.scrollHeight-n.clientHeight,i=r>0?e*r:0;n.scrollTo({top:i,behavior:KN(t,Math.abs(i-n.scrollTop),n.clientHeight)});return}let r=document.documentElement.scrollHeight-window.innerHeight,i=r>0?e*r:0;window.scrollTo({top:i,behavior:KN(t,Math.abs(i-window.scrollY),window.innerHeight)})};j();var JN=2,YN=8e3,XN=[`wheel`,`touchstart`,`keydown`,`pointerdown`],ZN=60,QN=()=>{let e=Ap(),[t,n]=Qo(),r=$o(),i=r?`${t}?${r}`:t,a=e.status===`active`?e.role:void 0,o=t===Sp;O(()=>{a!==`host`||o||(X.setLocation(i,WN()),X.send({t:`nav`,path:i}))},[a,i,o]),O(()=>{if(a!==`host`||o)return;let e=0,t,n=()=>{t=void 0,e=Date.now();let n=WN();X.setLocation(i,n),X.send({t:`scroll`,y:n})},r=()=>{if(t)return;let r=Math.max(0,1e3/JN-(Date.now()-e));t=setTimeout(n,r)};return document.addEventListener(`scroll`,r,{passive:!0,capture:!0}),()=>{document.removeEventListener(`scroll`,r,{capture:!0}),t&&clearTimeout(t)}},[a,i]);let s=R(void 0),c=R(0);O(()=>{if(s.current===void 0)return;let e=s.current;s.current=void 0;let t=0,n=-1,r=0,i=!1,a=c.current,o=Date.now()+YN,l=()=>{i=!0};for(let e of XN)document.addEventListener(e,l,{passive:!0});let u=()=>{cancelAnimationFrame(t);for(let e of XN)document.removeEventListener(e,l)};if(El(),e===0)return qN(0),u;let d=()=>{let s=UN();s===n?r+=1:(r=0,n=s);let l=s>0&&r>=ZN;if(i||c.current!==a||l||Date.now()>o)return u();qN(e),t=requestAnimationFrame(d)};return t=requestAnimationFrame(d),u},[i]);let l=R(!1),u=e.status===`active`?e.invite:void 0;O(()=>{l.current=!1},[u]);let d=(e,t)=>{l.current=!0,e===i?(El(),c.current+=1,qN(t,{smooth:!0})):(s.current=t,n(e))};return jp((e,{replayed:t})=>{if(a===`guest`)switch(e.t){case`nav`:l.current=!0,e.path!==i&&n(e.path);return;case`scroll`:X.hostPath()===i&&(El(),c.current+=1,qN(e.y,{smooth:!0}));return;case`state`:(!l.current||t)&&d(e.path,e.y);return}}),null};j();var $N=4,eP=2500,tP=x`
|
|
4168
4168
|
position: fixed;
|
|
4169
4169
|
left: 0;
|
|
4170
4170
|
top: 0;
|