@vitejs/devtools-rolldown 0.1.3 → 0.1.4
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/dist/index.mjs +0 -6
- package/dist/nitro.json +1 -1
- package/dist/public/200.html +1 -1
- package/dist/public/404.html +1 -1
- package/dist/public/_nuxt/B93mbFaw.js +1 -0
- package/dist/public/_nuxt/BK_evZhr2.js +1 -0
- package/dist/public/_nuxt/BMB5NJph.js +1 -0
- package/dist/public/_nuxt/{CNhzLIej.js → BN7ehjOp.js} +1 -1
- package/dist/public/_nuxt/{DGePBXlZ.js → BWMtL8wB.js} +1 -1
- package/dist/public/_nuxt/{B8Pee7C0.js → BdJ_JF0w.js} +1 -1
- package/dist/public/_nuxt/BgoIwvw3.js +1 -0
- package/dist/public/_nuxt/BsPeO-X9.js +1 -0
- package/dist/public/_nuxt/BvWn17I_.js +12 -0
- package/dist/public/_nuxt/{C2GH2ak5.js → Bw1q8I0g.js} +1 -1
- package/dist/public/_nuxt/{EJd6K-J0.js → C7OoXhk0.js} +1 -1
- package/dist/public/_nuxt/C7WGk_rq.js +2 -0
- package/dist/public/_nuxt/{CyUS7GqK.js → CEtF9LWU.js} +2 -2
- package/dist/public/_nuxt/{D4Y_zfdP.js → CSK2QzqY.js} +1 -1
- package/dist/public/_nuxt/CUsyfwWC.js +1 -0
- package/dist/public/_nuxt/CZg4aoum.js +1 -0
- package/dist/public/_nuxt/{Bc8dubgH.js → Cb77vzCb.js} +1 -1
- package/dist/public/_nuxt/ChFn95N-.js +1 -0
- package/dist/public/_nuxt/{Cy7pLEz3.js → CvnmAwQf.js} +1 -1
- package/dist/public/_nuxt/DDvY2cLx.js +1 -0
- package/dist/public/_nuxt/DHvQIQw5.js +1 -0
- package/dist/public/_nuxt/DJTkDKGN.js +1 -0
- package/dist/public/_nuxt/DLTtVSvg2.js +1 -0
- package/dist/public/_nuxt/DQ45Xu1f.js +1 -0
- package/dist/public/_nuxt/DataVirtualList.CjCVip5P.css +1 -0
- package/dist/public/_nuxt/DbSMFLvz.js +1 -0
- package/dist/public/_nuxt/{DE4LYGEQ.js → DlCwyx2g.js} +1 -1
- package/dist/public/_nuxt/Dm4CqiyV.js +1 -0
- package/dist/public/_nuxt/Dsy9hcD72.js +1 -0
- package/dist/public/_nuxt/{BWso7RtX.js → Dv3_npnh.js} +1 -1
- package/dist/public/_nuxt/JqdhbCkY.js +1 -0
- package/dist/public/_nuxt/{CslYnwdN.js → KgssGmNv.js} +1 -1
- package/dist/public/_nuxt/Opwc7YtP2.js +1 -0
- package/dist/public/_nuxt/XDMGgUv8.js +1 -0
- package/dist/public/_nuxt/Xmh1ayIL2.js +1 -0
- package/dist/public/_nuxt/builds/latest.json +1 -1
- package/dist/public/_nuxt/builds/meta/35ace98d-68a0-4b96-9871-0cefcb64bde5.json +1 -0
- package/dist/public/_nuxt/dIDzU19U.js +1 -0
- package/dist/public/_nuxt/{entry.AACt9kjR.css → entry.C3w9SVWr.css} +1 -1
- package/dist/public/_nuxt/error-404.CvDm6pT4.css +1 -0
- package/dist/public/_nuxt/error-500.B6RqN-C_.css +1 -0
- package/dist/public/_nuxt/lSJeop7v.js +1 -0
- package/dist/public/_nuxt/okblV2iS.js +1 -0
- package/dist/public/_nuxt/ouc94uM32.js +1 -0
- package/dist/public/index.html +1 -1
- package/package.json +38 -38
- package/dist/public/_nuxt/6dmQ5yi9.js +0 -1
- package/dist/public/_nuxt/BGo3TQDe2.js +0 -1
- package/dist/public/_nuxt/BfyZ1e0k.js +0 -12
- package/dist/public/_nuxt/Bp4eI3o72.js +0 -1
- package/dist/public/_nuxt/Bqcxb-Bh2.js +0 -1
- package/dist/public/_nuxt/ByPScZnZ.js +0 -1
- package/dist/public/_nuxt/CNF2WI0B.js +0 -1
- package/dist/public/_nuxt/CYHE6NHg.js +0 -1
- package/dist/public/_nuxt/CeUdh6JR.js +0 -1
- package/dist/public/_nuxt/CoGMAm3u.js +0 -1
- package/dist/public/_nuxt/Csgp_tbz2.js +0 -1
- package/dist/public/_nuxt/D-3DnbGi2.js +0 -1
- package/dist/public/_nuxt/D-_8YzYd.js +0 -2
- package/dist/public/_nuxt/D0PBHtPK.js +0 -1
- package/dist/public/_nuxt/D9y1gK-U.js +0 -2
- package/dist/public/_nuxt/DSjaPvg5.js +0 -1
- package/dist/public/_nuxt/DataVirtualList.lGV_3v2U.css +0 -1
- package/dist/public/_nuxt/DjwOaWuE.js +0 -1
- package/dist/public/_nuxt/GNBXjCbD.js +0 -1
- package/dist/public/_nuxt/L1-1zWht.js +0 -1
- package/dist/public/_nuxt/LlZteMOS.js +0 -1
- package/dist/public/_nuxt/PxFTarMZ.js +0 -1
- package/dist/public/_nuxt/TJfS2wQy2.js +0 -1
- package/dist/public/_nuxt/VSGDfpIu.js +0 -1
- package/dist/public/_nuxt/builds/meta/bfa9031a-4738-4e26-b1b6-6a294a22c480.json +0 -1
- package/dist/public/_nuxt/error-404.DCvw7d8G.css +0 -1
- package/dist/public/_nuxt/error-500.DMS_OhD_.css +0 -1
- package/dist/public/_nuxt/jJjSdHHs.js +0 -1
- package/dist/public/_nuxt/njczzgS1.js +0 -1
- package/dist/public/_nuxt/pNZCMUGD.js +0 -1
- /package/dist/public/_nuxt/{BrE3R8vW.js → 5tvbNeKa.js} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.grid[data-v-5bb471dc]{display:grid}.mb-2[data-v-5bb471dc]{margin-bottom:.5rem}.mb-4[data-v-5bb471dc]{margin-bottom:1rem}.max-w-520px[data-v-5bb471dc]{max-width:520px}.min-h-screen[data-v-5bb471dc]{min-height:100vh}.w-full[data-v-5bb471dc]{width:100%}.flex[data-v-5bb471dc]{display:flex}.place-content-center[data-v-5bb471dc]{place-content:center}.items-center[data-v-5bb471dc]{align-items:center}.justify-center[data-v-5bb471dc]{justify-content:center}.overflow-hidden[data-v-5bb471dc]{overflow:hidden}.bg-white[data-v-5bb471dc]{--un-bg-opacity:1;background-color:rgb(255 255 255/var(--un-bg-opacity))}.px-2[data-v-5bb471dc]{padding-left:.5rem;padding-right:.5rem}.text-center[data-v-5bb471dc]{text-align:center}.text-\[80px\][data-v-5bb471dc]{font-size:80px}.text-2xl[data-v-5bb471dc]{font-size:1.5rem;line-height:2rem}.text-sm[data-v-5bb471dc]{font-size:.875rem;line-height:1.25rem}.text-\[\#020420\][data-v-5bb471dc]{--un-text-opacity:1;color:rgb(2 4 32/var(--un-text-opacity))}.text-\[\#64748B\][data-v-5bb471dc]{--un-text-opacity:1;color:rgb(100 116 139/var(--un-text-opacity))}.hover\:text-\[\#00DC82\][data-v-5bb471dc]:hover{--un-text-opacity:1;color:rgb(0 220 130/var(--un-text-opacity))}.font-medium[data-v-5bb471dc]{font-weight:500}.font-semibold[data-v-5bb471dc]{font-weight:600}.leading-none[data-v-5bb471dc]{line-height:1}.tracking-wide[data-v-5bb471dc]{letter-spacing:.025em}.font-sans[data-v-5bb471dc]{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji}.tabular-nums[data-v-5bb471dc]{--un-numeric-spacing:tabular-nums;font-variant-numeric:var(--un-ordinal) var(--un-slashed-zero) var(--un-numeric-figure) var(--un-numeric-spacing) var(--un-numeric-fraction)}.underline[data-v-5bb471dc]{text-decoration-line:underline}.underline-offset-3[data-v-5bb471dc]{text-underline-offset:3px}.antialiased[data-v-5bb471dc]{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}@media(prefers-color-scheme:dark){.dark\:bg-\[\#020420\][data-v-5bb471dc]{--un-bg-opacity:1;background-color:rgb(2 4 32/var(--un-bg-opacity))}.dark\:text-white[data-v-5bb471dc]{--un-text-opacity:1;color:rgb(255 255 255/var(--un-text-opacity))}}@media(min-width:640px){.sm\:text-\[110px\][data-v-5bb471dc]{font-size:110px}.sm\:text-3xl[data-v-5bb471dc]{font-size:1.875rem;line-height:2.25rem}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.grid[data-v-283b1c88]{display:grid}.mb-2[data-v-283b1c88]{margin-bottom:.5rem}.mb-4[data-v-283b1c88]{margin-bottom:1rem}.max-w-520px[data-v-283b1c88]{max-width:520px}.min-h-screen[data-v-283b1c88]{min-height:100vh}.place-content-center[data-v-283b1c88]{place-content:center}.overflow-hidden[data-v-283b1c88]{overflow:hidden}.bg-white[data-v-283b1c88]{--un-bg-opacity:1;background-color:rgb(255 255 255/var(--un-bg-opacity))}.px-2[data-v-283b1c88]{padding-left:.5rem;padding-right:.5rem}.text-center[data-v-283b1c88]{text-align:center}.text-\[80px\][data-v-283b1c88]{font-size:80px}.text-2xl[data-v-283b1c88]{font-size:1.5rem;line-height:2rem}.text-\[\#020420\][data-v-283b1c88]{--un-text-opacity:1;color:rgb(2 4 32/var(--un-text-opacity))}.text-\[\#64748B\][data-v-283b1c88]{--un-text-opacity:1;color:rgb(100 116 139/var(--un-text-opacity))}.font-semibold[data-v-283b1c88]{font-weight:600}.leading-none[data-v-283b1c88]{line-height:1}.tracking-wide[data-v-283b1c88]{letter-spacing:.025em}.font-sans[data-v-283b1c88]{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji}.tabular-nums[data-v-283b1c88]{--un-numeric-spacing:tabular-nums;font-variant-numeric:var(--un-ordinal) var(--un-slashed-zero) var(--un-numeric-figure) var(--un-numeric-spacing) var(--un-numeric-fraction)}.antialiased[data-v-283b1c88]{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}@media(prefers-color-scheme:dark){.dark\:bg-\[\#020420\][data-v-283b1c88]{--un-bg-opacity:1;background-color:rgb(2 4 32/var(--un-bg-opacity))}.dark\:text-white[data-v-283b1c88]{--un-text-opacity:1;color:rgb(255 255 255/var(--un-text-opacity))}}@media(min-width:640px){.sm\:text-\[110px\][data-v-283b1c88]{font-size:110px}.sm\:text-3xl[data-v-283b1c88]{font-size:1.875rem;line-height:2.25rem}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e}from"./BMB5NJph.js";import{A as t,C as n,Et as r,Gt as i,M as a,Q as o,R as s,S as c,Z as l,b as u,h as d,k as f,lt as p,q as m,rt as h,tt as g,w as _,x as v}from"./CEtF9LWU.js";import{C as y}from"./Cb77vzCb.js";import{c as b}from"./DJTkDKGN.js";import{n as x}from"#entry";import{t as S}from"./BdJ_JF0w.js";import{r as C,t as w}from"./CvnmAwQf.js";import{r as T}from"./DbSMFLvz.js";import{t as E}from"./Bw1q8I0g.js";var D=[`title`],O={key:0,flex:`~ items-center gap-2`},k={op50:``,"font-mono":``},A=[`title`],j=[`title`],M=Object.assign(a({__name:`BaseInfo`,props:{chunk:{},link:{type:Boolean,default:!1},basic:{type:Boolean,default:!1}},setup(e){let a=e,s=y(),l=u(()=>Array.isArray(a.chunk.imports)?a.chunk.imports.length:a.chunk.imports),d=u(()=>Array.isArray(a.chunk.modules)?a.chunk.modules.length:a.chunk.modules);return(a,u)=>(m(),c(g(e.link?r(S):`div`),{to:e.link?typeof e.link==`string`?e.link:{path:r(s).path,query:{chunk:e.chunk.chunk_id}}:void 0,flex:`~ gap-3 items-center`},{default:p(()=>[v(`div`,{flex:`~ gap-2 items-center`,title:`Chunk #${e.chunk.chunk_id}`},[o(a.$slots,`icon`,{},()=>[u[0]||=v(`div`,{"i-ph-shapes-duotone":``},null,-1)]),v(`div`,null,i(e.chunk.name||`[unnamed]`),1),t(C,{text:e.chunk.reason},null,8,[`text`]),o(a.$slots,`left-after`)],8,D),u[3]||=v(`div`,{"flex-auto":``},null,-1),e.basic?n(``,!0):(m(),_(`div`,O,[v(`span`,k,`#`+i(e.chunk.chunk_id),1),v(`div`,{flex:`~ gap-1 items-center`,title:`${l.value} imports`},[u[1]||=v(`div`,{"i-ph-file-arrow-up-duotone":``},null,-1),f(` `+i(l.value),1)],8,A),v(`div`,{flex:`~ gap-1 items-center`,title:`${d.value} modules`},[u[2]||=v(`div`,{"i-ph-package-duotone":``},null,-1),f(` `+i(d.value),1)],8,j)])),o(a.$slots,`default`)]),_:3},8,[`to`]))}}),{__name:`ChunksBaseInfo`}),N={flex:`~ gap-2 items-center`},P=Object.assign(a({__name:`BaseInfo`,props:{asset:{}},setup(e){return(n,r)=>{let a=T;return m(),_(`div`,N,[r[0]||=v(`div`,{"i-catppuccin-java-class-abstract":``},null,-1),v(`div`,null,i(e.asset.filename),1),t(a,{bytes:e.asset.size,"text-sm":``},null,8,[`bytes`]),t(C,{text:e.asset.type},null,8,[`text`])])}}}),{__name:`AssetsBaseInfo`}),F={relative:``},I={key:0,"pointer-events-none":``,absolute:``,"left-0":``,"right-0":``,"bottom-0":``,"bg-gradient-more":``,"h-30":``,flex:`~ justify-center`},L=Object.assign(a({__name:`ExpandableContainer`,props:s({list:{}},{count:{default:20},countModifiers:{}}),emits:[`update:count`],setup(e){let i=e,a=h(e,`count`),s=a.value,c=u(()=>i.list.slice(0,a.value));return(l,u)=>(m(),_(`div`,F,[o(l.$slots,`default`,{items:c.value}),e.list.length>a.value?(m(),_(`div`,I,[v(`button`,{op35:``,p2:``,pt4:``,mta:``,"pointer-events-auto":``,"hover:op100":``,flex:`~ items-center gap-1 justify-center`,onClick:u[0]||=e=>a.value=Math.round(a.value+r(s))},[u[2]||=v(`div`,{"i-ri:arrow-down-double-line":``},null,-1),u[3]||=v(`span`,null,`More`,-1),t(E,{prefix:`+`,number:Math.min(Math.round(r(s)),i.list.length-a.value),"rounded-full":``,"text-sm":``},null,8,[`number`])]),v(`button`,{op35:``,p2:``,pt4:``,mta:``,"pointer-events-auto":``,"hover:op100":``,flex:`~ items-center gap-1 justify-center`,onClick:u[1]||=e=>a.value=i.list.length},[u[4]||=v(`div`,{"i-ph-arrows-out-line-vertical-duotone":``},null,-1),u[5]||=v(`span`,null,`All`,-1),t(E,{number:i.list.length,"rounded-full":``,"text-sm":``},null,8,[`number`])])])):n(``,!0)]))}}),{__name:`DisplayExpandableContainer`}),R={key:0,"i-ph-file-duotone":``},z={key:1,"i-ph-lightning-duotone":``},B=Object.assign(a({__name:`Imports`,props:{imports:{}},setup(e){return(r,i)=>{let a=M,o=L;return m(),c(o,{flex:`~ col gap-1`,mt2:``,"ws-nowrap":``,list:e.imports},{default:p(({items:e})=>[(m(!0),_(d,null,l(e,(e,r)=>(m(),_(d,{key:r},[e?(m(),c(a,{key:0,chunk:e,link:``,hover:`bg-active`,border:`~ base rounded`,px2:``,py1:``,"w-full":``},{icon:p(()=>[e.kind===`import-statement`?(m(),_(`div`,R)):n(``,!0),e.kind===`dynamic-import`?(m(),_(`div`,z)):n(``,!0)]),"left-after":p(()=>[t(C,{text:e.kind},null,8,[`text`])]),_:2},1032,[`chunk`])):n(``,!0)],64))),128))]),_:1},8,[`list`])}}}),{__name:`ChunksImports`}),V={flex:`~ col gap-3`},H={key:1,"text-sm":``,op50:``,flex:`~ items-center`,title:`Total size of imports`},U={open:`true`},W={open:`true`},G={op50:``},K={key:0,open:`true`},q={op50:``},J={key:1,open:`true`},Y={op50:``},X=Object.assign(a({__name:`ChunkDetails`,props:{chunk:{},session:{},showDetails:{type:Boolean,default:!0},chunks:{}},setup(a){let s=a,h=u(()=>{let e=new Map;for(let t of s.session.modulesList)e.set(t.id,t);return e});function g(e){return e.reduce((e,t)=>{let n=h.value.get(t);return!n||!n.buildMetrics?.transforms?.length?e:e+n.buildMetrics.transforms.at(-1).transformed_code_size},0)}let E=u(()=>g(s.chunk.modules)),D=y(),O=e(),{state:k,isLoading:A}=b(async()=>{if(!s.chunks)return await O.value.call(`vite:rolldown:get-chunks-graph`,{session:s.session.id})},null),j=u(()=>s.chunks||k.value),N=u(()=>s.chunk.imports.map(e=>{let t=j.value?.find(t=>t.chunk_id===e.chunk_id);return{...e,name:t?.name||`[unnamed]`,reason:t?.reason||`common`,imports:t?.imports.length||0,modules:t?.modules.length||0,size:g(t?.modules||[])}})),F=u(()=>j.value?.filter(e=>e.imports.some(e=>e.chunk_id===s.chunk.chunk_id)).map(e=>({...e.imports.find(e=>e.chunk_id===s.chunk.chunk_id),chunk_id:e.chunk_id,name:e.name||`[unnamed]`,reason:e.reason||`common`,imports:e.imports.length||0,modules:e.modules.length||0}))||[]);return(e,s)=>{let u=T,h=M,g=P,y=S,b=w,O=L,k=x,j=B;return m(),_(`div`,V,[t(h,{chunk:a.chunk},{"left-after":p(()=>[a.chunk.is_initial?(m(),c(C,{key:0,text:`initial`})):n(``,!0),t(u,{bytes:E.value,"text-sm":``,title:`Chunk size`},null,8,[`bytes`]),N.value.length?(m(),_(`div`,H,[s[0]||=f(` (`,-1),t(u,{bytes:N.value.reduce((e,t)=>e+t.size,0)},null,8,[`bytes`]),s[1]||=f(`) `,-1)])):n(``,!0)]),default:p(()=>[o(e.$slots,`default`)]),_:3},8,[`chunk`]),a.showDetails?(m(),_(d,{key:0},[v(`details`,U,[s[2]||=v(`summary`,{op50:``},` Assets `,-1),t(y,{border:`~ base rounded-lg`,px2:``,mt2:``,py1:``,"min-w-fit":``,flex:`~`,to:{path:r(D).path,query:{asset:a.chunk.asset?.filename}}},{default:p(()=>[t(g,{asset:{...a.chunk.asset,type:`asset`}},null,8,[`asset`])]),_:1},8,[`to`])]),v(`details`,W,[v(`summary`,G,[v(`span`,null,`Modules (`+i(a.chunk.modules.length)+`)`,1)]),t(O,{flex:`~ col gap-1`,mt2:``,"ws-nowrap":``,list:a.chunk.modules},{default:p(({items:e})=>[(m(!0),_(d,null,l(e,e=>(m(),c(b,{id:e,key:e,session:a.session,link:!0,minimal:!0,hover:`bg-active`,border:`~ base rounded`,px2:``,py1:``,"w-full":``},null,8,[`id`,`session`]))),128))]),_:1},8,[`list`])]),r(A)?(m(),c(k,{key:0})):(m(),_(d,{key:1},[a.chunk.imports.length?(m(),_(`details`,K,[v(`summary`,q,[v(`span`,null,`Imports (`+i(a.chunk.imports.length)+`)`,1)]),t(j,{imports:N.value},null,8,[`imports`])])):n(``,!0),F.value.length?(m(),_(`details`,J,[v(`summary`,Y,[v(`span`,null,`Importers (`+i(F.value.length)+`)`,1)]),t(j,{imports:F.value},null,8,[`imports`])])):n(``,!0)],64))],64)):n(``,!0)])}}}),{__name:`DataChunkDetails`});export{M as i,L as n,P as r,X as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{B as e,C as t,Et as n,Gt as r,K as i,M as a,Q as o,S as s,St as c,Wt as l,Z as u,at as d,b as f,bt as p,h as m,ot as h,q as g,v as _,w as v,wt as y,x as b}from"./CEtF9LWU.js";import{a as x,c as S,d as C,f as w,i as ee,l as T,o as te,r as ne,u as re}from"./5tvbNeKa.js";import{t as E}from"./DJTkDKGN.js";import{t as D}from"./D04G8HHr.js";import{t as ie}from"./DbSMFLvz.js";function O(){return typeof window<`u`}function k(e){return ae(e)?(e.nodeName||``).toLowerCase():`#document`}function A(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function j(e){return((ae(e)?e.ownerDocument:e.document)||window.document)?.documentElement}function ae(e){return O()?e instanceof Node||e instanceof A(e).Node:!1}function M(e){return O()?e instanceof Element||e instanceof A(e).Element:!1}function N(e){return O()?e instanceof HTMLElement||e instanceof A(e).HTMLElement:!1}function oe(e){return!O()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof A(e).ShadowRoot}function P(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=R(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!==`inline`&&i!==`contents`}function se(e){return/^(table|td|th)$/.test(k(e))}function F(e){try{if(e.matches(`:popover-open`))return!0}catch{}try{return e.matches(`:modal`)}catch{return!1}}var ce=/transform|translate|scale|rotate|perspective|filter/,le=/paint|layout|strict|content/,I=e=>!!e&&e!==`none`,ue;function de(e){let t=M(e)?R(e):e;return I(t.transform)||I(t.translate)||I(t.scale)||I(t.rotate)||I(t.perspective)||!pe()&&(I(t.backdropFilter)||I(t.filter))||ce.test(t.willChange||``)||le.test(t.contain||``)}function fe(e){let t=B(e);for(;N(t)&&!L(t);){if(de(t))return t;if(F(t))return null;t=B(t)}return null}function pe(){return ue??=typeof CSS<`u`&&CSS.supports&&CSS.supports(`-webkit-backdrop-filter`,`none`),ue}function L(e){return/^(html|body|#document)$/.test(k(e))}function R(e){return A(e).getComputedStyle(e)}function z(e){return M(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function B(e){if(k(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||oe(e)&&e.host||j(e);return oe(t)?t.host:t}function me(e){let t=B(e);return L(t)?e.ownerDocument?e.ownerDocument.body:e.body:N(t)&&P(t)?t:me(t)}function he(e,t,n){t===void 0&&(t=[]),n===void 0&&(n=!0);let r=me(e),i=r===e.ownerDocument?.body,a=A(r);if(i){let e=ge(a);return t.concat(a,a.visualViewport||[],P(r)?r:[],e&&n?he(e):[])}else return t.concat(r,he(r,[],n))}function ge(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function _e(e){let t=R(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=N(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=w(n)!==a||w(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function ve(e){return M(e)?e:e.contextElement}function V(e){let t=ve(e);if(!N(t))return S(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=_e(t),o=(a?w(n.width):n.width)/r,s=(a?w(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var ye=S(0);function be(e){let t=A(e);return!pe()||!t.visualViewport?ye:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function xe(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==A(e)?!1:t}function H(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=ve(e),o=S(1);t&&(r?M(r)&&(o=V(r)):o=V(e));let s=xe(a,n,r)?be(a):S(0),c=(i.left+s.x)/o.x,l=(i.top+s.y)/o.y,u=i.width/o.x,d=i.height/o.y;if(a){let e=A(a),t=r&&M(r)?A(r):r,n=e,i=ge(n);for(;i&&r&&t!==n;){let e=V(i),t=i.getBoundingClientRect(),r=R(i),a=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,o=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,l*=e.y,u*=e.x,d*=e.y,c+=a,l+=o,n=A(i),i=ge(n)}}return C({width:u,height:d,x:c,y:l})}function U(e,t){let n=z(e).scrollLeft;return t?t.left+n:H(j(e)).left+n}function Se(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-U(e,n),y:n.top+t.scrollTop}}function Ce(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=j(r),s=t?F(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=S(1),u=S(0),d=N(r);if((d||!d&&!a)&&((k(r)!==`body`||P(o))&&(c=z(r)),d)){let e=H(r);l=V(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?Se(o,c):S(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+u.x+f.x,y:n.y*l.y-c.scrollTop*l.y+u.y+f.y}}function we(e){return Array.from(e.getClientRects())}function Te(e){let t=j(e),n=z(e),r=e.ownerDocument.body,i=T(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=T(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),o=-n.scrollLeft+U(e),s=-n.scrollTop;return R(r).direction===`rtl`&&(o+=T(t.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:s}}var Ee=25;function De(e,t){let n=A(e),r=j(e),i=n.visualViewport,a=r.clientWidth,o=r.clientHeight,s=0,c=0;if(i){a=i.width,o=i.height;let e=pe();(!e||e&&t===`fixed`)&&(s=i.offsetLeft,c=i.offsetTop)}let l=U(r);if(l<=0){let e=r.ownerDocument,t=e.body,n=getComputedStyle(t),i=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,o=Math.abs(r.clientWidth-t.clientWidth-i);o<=Ee&&(a-=o)}else l<=Ee&&(a+=l);return{width:a,height:o,x:s,y:c}}function Oe(e,t){let n=H(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=N(e)?V(e):S(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function ke(e,t,n){let r;if(t===`viewport`)r=De(e,n);else if(t===`document`)r=Te(j(e));else if(M(t))r=Oe(t,n);else{let n=be(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return C(r)}function Ae(e,t){let n=B(e);return n===t||!M(n)||L(n)?!1:R(n).position===`fixed`||Ae(n,t)}function je(e,t){let n=t.get(e);if(n)return n;let r=he(e,[],!1).filter(e=>M(e)&&k(e)!==`body`),i=null,a=R(e).position===`fixed`,o=a?B(e):e;for(;M(o)&&!L(o);){let t=R(o),n=de(o);!n&&t.position===`fixed`&&(i=null),(a?!n&&!i:!n&&t.position===`static`&&i&&(i.position===`absolute`||i.position===`fixed`)||P(o)&&!n&&Ae(e,o))?r=r.filter(e=>e!==o):i=t,o=B(o)}return t.set(e,r),r}function Me(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?F(t)?[]:je(t,this._c):[].concat(n),r],o=ke(t,a[0],i),s=o.top,c=o.right,l=o.bottom,u=o.left;for(let e=1;e<a.length;e++){let n=ke(t,a[e],i);s=T(n.top,s),c=re(n.right,c),l=re(n.bottom,l),u=T(n.left,u)}return{width:c-u,height:l-s,x:u,y:s}}function Ne(e){let{width:t,height:n}=_e(e);return{width:t,height:n}}function Pe(e,t,n){let r=N(t),i=j(t),a=n===`fixed`,o=H(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=S(0);function l(){c.x=U(i)}if(r||!r&&!a)if((k(t)!==`body`||P(i))&&(s=z(t)),r){let e=H(t,!0,a,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}else i&&l();a&&!r&&i&&l();let u=i&&!r&&!a?Se(i,s):S(0);return{x:o.left+s.scrollLeft-c.x-u.x,y:o.top+s.scrollTop-c.y-u.y,width:o.width,height:o.height}}function Fe(e){return R(e).position===`static`}function Ie(e,t){if(!N(e)||R(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return j(e)===n&&(n=n.ownerDocument.body),n}function Le(e,t){let n=A(e);if(F(e))return n;if(!N(e)){let t=B(e);for(;t&&!L(t);){if(M(t)&&!Fe(t))return t;t=B(t)}return n}let r=Ie(e,t);for(;r&&se(r)&&Fe(r);)r=Ie(r,t);return r&&L(r)&&Fe(r)&&!de(r)?n:r||fe(e)||n}var Re=async function(e){let t=this.getOffsetParent||Le,n=this.getDimensions,r=await n(e.floating);return{reference:Pe(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function ze(e){return R(e).direction===`rtl`}var Be={convertOffsetParentRelativeRectToViewportRelativeRect:Ce,getDocumentElement:j,getClippingRect:Me,getOffsetParent:Le,getElementRects:Re,getClientRects:we,getDimensions:Ne,getScale:V,isElement:M,isRTL:ze},Ve=x,He=te,Ue=ee,We=(e,t,n)=>{let r=new Map,i={platform:Be,...n},a={...i.platform,_c:r};return ne(e,t,{...i,platform:a})},Ge=Object.assign(a({__name:`GraphHoverView`,props:{hoverX:{},hoverY:{}},setup(e){let{hoverX:t,hoverY:n}=y(e),r=d(`hoverElement`),i=p(0),a=p(0);return h([t,n],([e,t])=>{We({getBoundingClientRect(){return{width:0,height:0,x:e,y:t,left:e,right:e,top:t,bottom:t}}},r.value,{placement:`right-start`,middleware:[Ue(),He(),Ve({mainAxis:8,alignmentAxis:8})]}).then(({x:e,y:t})=>{i.value=e,a.value=t})}),(e,t)=>(g(),s(_,{to:`body`},[b(`div`,{ref_key:`hoverElement`,ref:r,fixed:``,"z-panel-content":``,"pointer-events-none":``,style:l({left:`${i.value}px`,top:`${a.value}px`})},[o(e.$slots,`default`)],4)]))}}),{__name:`DisplayGraphHoverView`});function Ke(e,t=1,n=1){let r=(.6+.4*Math.max(0,Math.cos(e)))*t,i=(.5+.2*Math.max(0,Math.cos(e+Math.PI*2/3)))*n;return`hsl(${e*180/Math.PI}deg, ${Math.round(100*r)}%, ${Math.round(100*i)}%)`}var qe,Je,Ye,W,G,K=1,Xe;function Ze(e,t,n,r,i){if(!Array.isArray(e))return e;let a=window.devicePixelRatio||1;if(qe!==t||Je!==a||Ye!==i){let n=Math.round(64*a)/64;K=i,K=Math.log2(K),K-=Math.floor(K);let r=K,o=Math.min(1,8*r);K=2**K;let s=8*Math.SQRT2/K;qe=t,Je=a,Ye=i,W||=document.createElement(`canvas`),G||=W.getContext(`2d`),W.width=W.height=Math.round(64*n),G.scale(n,n),G.fillStyle=e[0],G.fillRect(0,0,64,64),G.globalAlpha=.25,G.fillStyle=e[1],G.fillRect(0,0,64,64),G.globalAlpha=.67,G.strokeStyle=e[1],G.beginPath();for(let e=0;e<=64;e+=16)G.moveTo(e-32,e+32),G.lineTo(e+32,e-32);if(G.lineWidth=s*(1-(o-r)/2),G.stroke(),o+r>0){G.beginPath();for(let e=8;e<64;e+=16)G.moveTo(e-32,e+32),G.lineTo(e+32,e-32);G.lineWidth=s*(o+r)/2,G.stroke()}Xe=t.createPattern(W,`repeat`),K/=n}return n/=64*K*a,n-=Math.floor(n),n*=64*K*a,Xe.setTransform(new DOMMatrix([K,0,0,K,n,r])),Xe}function Qe(e){return Array.isArray(e)?`url('data:image/svg+xml,<svg width="26" height="26" xmlns="http://www.w3.org/2000/svg"><rect width="26" height="26" fill="${e[0]}"/><rect width="26" height="26" fill="${e[1]}" fill-opacity="25%"/><path d="M22.5 -3.5L-3.5 22.5M35.5 9.5L9.5 35.5" stroke="${e[1]}" stroke-opacity="67%" stroke-width="9.19239"/></svg>')`:e}function $e(e){return t=>t.id&&e[t.id]||t.color}function et(e,t=1,n=1){let r={};return tt(r,e,0,Math.PI*2,t,n),$e(r)}function tt(e,t,n,r,i=1,a=1){let o=t.size;e[t.id]=Ke(n+r/2,i,a);for(let s of t.children){let t=s.size/o*r;tt(e,s,n,t,i,a),n+=t}}var nt=`useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict`;function rt(e=16,t=nt){let n=``,r=e,i=t.length;for(;r--;)n+=t[Math.random()*i|0];return n}function it(e,t,n=(e,t)=>t.size-e.size){if(e.__nanovis)return e;let r={...e};return r.id||=rt(),r.parent||=t,r.children||=[],r.sizeSelf==null&&r.size!=null&&r.children.length===0?r.sizeSelf=r.size:r.sizeSelf||=0,r.children=(r.children||[]).map(e=>it(e,r,n)),r.size||=r.children.reduce((e,t)=>e+t.size,0)+r.sizeSelf,n&&r.children.sort(n),Object.defineProperty(r,`__nanovis`,{enumerable:!1,value:!0}),r}function at(e){return e.children.length===0?1:Math.max(...e.children.map(e=>at(e)))+1}var ot=/\bFirefox\//.test(navigator.userAgent),st;function ct(e){return st?st.format(e):`${e}`}function q(){return(window.performance||Date).now()}function lt(e){let t=e.toFixed(1).split(`.`,2);return`${ct(+t[0])}.${t[1]}`}function ut(e){return e===1?`1 byte`:e<1024?`${ct(e)} bytes`:e<1024*1024?`${lt(e/1024)} kb`:e<1024*1024*1024?`${lt(e/(1024*1024))} mb`:`${lt(e/(1024*1024*1024))} gb`}function dt(e,t,n,r,i,a){if(ot){let o=e.lineWidth,s=o/2;e.fillStyle=t,e.fillRect(n-s,r-s,i+o,o),e.fillRect(n-s,r+s,o,a-o),e.fillRect(n-s,r+a-s,i+o,o),e.fillRect(n+i-s,r+s,o,a-o);return}e.strokeStyle=t,e.strokeRect(n,r,i,a)}function ft(e){return window.addEventListener(`wheel`,e,{passive:!1}),()=>window.removeEventListener(`wheel`,e)}function pt(e){return window.addEventListener(`resize`,e),()=>window.removeEventListener(`resize`,e)}try{st=new Intl.NumberFormat}catch{}var mt=()=>({emit(e,...t){for(let n=this.events[e]||[],r=0,i=n.length;r<i;r++)n[r](...t)},events:{},on(e,t){return(this.events[e]||=[]).push(t),()=>{this.events[e]=this.events[e]?.filter(e=>t!==e)}}}),J={getText:e=>e.text,getSubtext:e=>e.subtext,animate:!0,animateDuration:350},ht={fallback:`#CCC`,stroke:`#0008`,text:`#222`,hover:`#fff5`,shadow:`#0008`,fg:`#fff`,bg:`#222`},gt=46,_t=`14px sans-serif`,vt=`bold ${_t}`,yt=class{el;canvas;c;width=0;height=0;ratio=1;root;maxDepth;events;options;palette;disposables;getColor;getText;getSubtext;_animationFrame=null;constructor(e,t){this.options={...J,...t};let{getColor:n=et(e),getText:r=()=>void 0,getSubtext:i=()=>void 0}=this.options;this.palette={...ht,...t.palette},this.el=document.createElement(`div`),this.canvas=document.createElement(`canvas`),this.c=this.canvas.getContext(`2d`),this.root=e,this.maxDepth=at(e),this.disposables=[],this.events=mt(),this.getColor=n,this.getText=r,this.getSubtext=i,this.setFont(_t),t.onClick&&this.events.on(`click`,t.onClick),t.onHover&&this.events.on(`hover`,t.onHover),t.onLeave&&this.events.on(`leave`,t.onLeave),t.onSelect&&this.events.on(`select`,t.onSelect),this.el.addEventListener(`mouseleave`,()=>{this.events.emit(`leave`)})}invalidate(){this._animationFrame===null&&(this._animationFrame=requestAnimationFrame(()=>{this._animationFrame=null,this.tick()}))}tick(){this.draw()}draw(){}resize(){this.ratio=window.devicePixelRatio||1,this.canvas.style.width=`${this.width}px`,this.canvas.style.height=`${this.height}px`,this.canvas.width=Math.round(this.width*this.ratio),this.canvas.height=Math.round(this.height*this.ratio),this.c.scale(this.ratio,this.ratio),this.draw()}select(e,t){this.events.emit(`select`,e)}dispose(){this.disposables.forEach(e=>e()),this.disposables.length=0,this.el.remove()}[Symbol.dispose](){this.dispose()}_font=`14px sans-serif`;_fontWidthCache=new Map;ellipsisWidth=0;getFontCache(){return this._fontWidthCache.has(this._font)||this._fontWidthCache.set(this._font,{}),this._fontWidthCache.get(this._font)}setFont(e){this._font=e,this.c.font=e,this.c.textBaseline=`middle`,this.ellipsisWidth=3*this.charCodeWidth(gt)}charCodeWidth(e){let t=this.getFontCache(),n=t[e];return n===void 0&&(n=this.c.measureText(String.fromCharCode(e)).width,t[e]=n),n}textOverflowEllipsis(e,t){if(t<this.ellipsisWidth)return[``,0];let n=0,r=e.length,i=0;for(;i<r;){let r=this.charCodeWidth(e.charCodeAt(i));if(t<n+this.ellipsisWidth+r)return[`${e.slice(0,i)}...`,n+this.ellipsisWidth];n+=r,i++}return[e,n]}},Y=24,bt=5,xt=.01,St=1e3,Ct=class extends yt{mainEl=document.createElement(`div`);totalBytes;viewportMin;viewportMax;zoomedOutMin=0;zoomedOutWidth=0;prevWheelTime=0;prevWheelWasZoom=!1;stripeScaleAdjust=1;hoveredNode=null;selectedNode=null;nodeStartBytes=new Map;animationFromMin=0;animationFromMax=0;animationToMin=0;animationToMax=0;animationStart=0;constructor(e,t={}){super(e,t),this.totalBytes=e.size,this.viewportMin=this.animationFromMin=this.animationToMin=0,this.viewportMax=this.animationFromMax=this.animationToMax=this.totalBytes,Object.assign(this.mainEl.style,{position:`relative`}),Object.assign(this.canvas.style,{position:`absolute`,left:`0`,top:`0`});let n=!1;this.canvas.onmousedown=e=>{if(n=!1,e.button!==2){let t=e.pageX,r=e=>{let r=e.pageX-t;!n&&Math.abs(r)<3||(n=!0,this.modifyViewport(-r,0,null),t=e.pageX)},i=()=>{document.removeEventListener(`mousemove`,r),document.removeEventListener(`mouseup`,i)};e.preventDefault(),document.addEventListener(`mousemove`,r),document.addEventListener(`mouseup`,i)}},this.canvas.onmousemove=e=>{this.updateHover(e)},this.canvas.onmouseout=()=>{this.changeHoveredNode(null)},this.canvas.onclick=e=>{if(n)return;let t=this.hitTestNode(e);this.changeHoveredNode(t),this.changeSelectedNode(t),t&&this.events.emit(`click`,t,e)},this.disposables.push(ft(e=>{let t=e.deltaX,n=e.deltaY,r=q(),i=r-this.prevWheelTime<50?this.prevWheelWasZoom:e.ctrlKey||e.metaKey;this.prevWheelTime=r,this.prevWheelWasZoom=i,(i||Math.abs(t)>=Math.abs(n))&&e.preventDefault(),this.modifyViewport(t,n,i?e.pageX:null),this.updateHover(e)})),this.resize(),Promise.resolve().then(()=>this.resize()),this.disposables.push(pt(()=>this.resize())),this.mainEl.append(this.canvas),this.el.append(this.mainEl)}tick(){let e=(q()-this.animationStart)/(this.options.animateDuration??J.animateDuration);e<0||e>1?(e=1,this.viewportMin=this.animationToMin,this.viewportMax=this.animationToMax):(e<.5?e*=4*e*e:(e=1-e,e*=4*e*e,e=1-e),this.viewportMin=this.animationFromMin+(this.animationToMin-this.animationFromMin)*e,this.viewportMax=this.animationFromMax+(this.animationToMax-this.animationFromMax)*e,this.invalidate()),this.draw()}draw(){this.c.clearRect(0,0,this.width,this.height),this.drawNode(this.root,0,0,-1/0,1)}changeSelectedNode(e,t=this.options.animate??J.animate){if(this.selectedNode!==e&&(this.selectedNode=e,this.events.emit(`select`,e),e&&this.nodeStartBytes.has(e.id))){let n=this.nodeStartBytes.get(e.id),r=n+e.size;n=Math.max(0,n-e.size*xt),r=Math.min(this.totalBytes,r+e.size*xt),this.setViewport(n,r,t)}}select(e,t=this.options.animate??J.animate){this.changeSelectedNode(e,t)}resize(){this.width=this.el.clientWidth,this.height=this.maxDepth*Y+1,this.zoomedOutMin=this.width-St>>1,this.zoomedOutWidth=this.zoomedOutMin+St,this.zoomedOutMin<0&&(this.zoomedOutMin=0),this.zoomedOutWidth>this.width&&(this.zoomedOutWidth=this.width),this.zoomedOutWidth-=this.zoomedOutMin,this.stripeScaleAdjust=this.totalBytes/this.zoomedOutWidth,this.mainEl.style.height=`${this.height}px`,super.resize()}drawNode(e,t,n,r,i){this.nodeStartBytes.set(e.id,n);let a=this.zoomedOutWidth/(this.viewportMax-this.viewportMin),o=this.zoomedOutMin+(n-this.viewportMin)*a,s=e.size*a,c=o+s;if(c<r+1.5)return r;if(o+s<0||o>this.width)return c;let l=s<2?2:s,u=(o>0?o:0)+bt,d=t+Y/2,f=this.getText(e)||``,p=this.getSubtext(e)||``,m,h=0,g=s+o-u,_=Ze(this.getColor(e)||this.palette.fallback,this.c,this.zoomedOutMin-this.viewportMin*a,Y,a*this.stripeScaleAdjust),v=this.palette.text,y=-1/0;i&1?(v=this.palette.fg,this.setFont(vt)):(this.c.fillStyle=_,this.c.fillRect(o,t,l,Y),(i&2||this.hoveredNode&&e.id===this.hoveredNode.id)&&(this.c.fillStyle=this.palette.hover,this.c.fillRect(o,t,l,Y),i|=2)),this.ellipsisWidth<g&&(m=this.c.measureText(f).width,m<=g?h+=m:(f=this.textOverflowEllipsis(f,g)[0],h=g),this.c.fillStyle=v,this.c.fillText(f,u,d)),i&1&&this.setFont(_t),h+this.ellipsisWidth<g&&(p&&f&&(p=` - ${p}`),m=this.c.measureText(p).width,h+m>g&&(p=this.textOverflowEllipsis(p,g-h)[0]),this.c.globalAlpha=.5,this.c.fillText(p,u+h,d),this.c.globalAlpha=1);for(let r of e.children)y=this.drawNode(r,t+Y,n,y,i&-2),n+=r.size;return i&1||dt(this.c,this.palette.stroke,o+.5,t+.5,l,Y),c}changeHoveredNode(e){this.hoveredNode!==e&&(this.hoveredNode=e,this.canvas.style.cursor=e&&!e.children.length?`pointer`:`auto`,this.invalidate())}hitTestNode(e){let t=this.canvas.getBoundingClientRect(),n=e.clientX-t.left,r=e.clientY-t.top,i=this.viewportMin+(this.viewportMax-this.viewportMin)/this.zoomedOutWidth*(n-this.zoomedOutMin),a=(e,t,n)=>{if(i>=n&&i<n+e.size){if(r>=t&&r<t+Y&&e.id)return e;if(r>=t+Y)for(let r of e.children){let e=a(r,t+Y,n);if(e)return e;n+=r.size}}return null};return a(this.root,0,0)}modifyViewport(e,t,n){let r=this.viewportMin,i=this.viewportMax,a=0;if(n!==null){let e=r+(i-r)/this.zoomedOutWidth*(n-this.zoomedOutMin),a=1.01**t;r=e+(r-e)*a,i=e+(i-e)*a}else a=e*(i-r)/this.zoomedOutWidth;r+a<0?a=-r:i+a>this.totalBytes&&(a=this.totalBytes-i),r+=a,i+=a,r<0&&(r=0),i>this.totalBytes&&(i=this.totalBytes),this.setViewport(r,i,!1)}setViewport(e,t,n){this.animationFromMin=this.viewportMin,this.animationFromMax=this.viewportMax,this.animationToMin=e,this.animationToMax=t,n?this.animationStart=q():this.animationStart=0,this.invalidate()}updateHover(e){let t=this.hitTestNode(e);this.changeHoveredNode(t),this.events.emit(`hover`,t,e)}};function wt(e,t){for(;t;){if(t===e)return!0;t=t.parent}return!1}function Tt(e,t,n){if(e===t)return;let r=t.parent,i=r.size||1,a=0;Tt(e,r,n);for(let e of r.children){if(e===t){n.startAngle_+=n.sweepAngle_*a/i,n.sweepAngle_=e.size/i*n.sweepAngle_;break}a+=e.size}n.depth_+=1}var Et={};function Dt(e){return Et[e]||(Et[e]=400*Math.log(1+Math.log(1+e/8))),Et[e]}var X=-Math.PI/2,Ot=class extends yt{currentNode;hoveredNode;centerX=0;centerY=0;animationStart=0;radiusScale=1;sourceDepth=0;sourceStartAngle=X;sourceSweepAngle=Math.PI*2;targetNode;targetDepth=this.sourceDepth;targetStartAngle=this.sourceStartAngle;targetSweepAngle=this.sourceSweepAngle;animatedNode;animatedDepth=this.sourceDepth;animatedStartAngle=this.sourceStartAngle;animatedSweepAngle=this.sourceSweepAngle;previousHoveredNode;historyStack=[];constructor(e,t={}){for(;e.children.length===1;)e=e.children[0];super(e,t),this.currentNode=e,this.targetNode=this.currentNode,this.animatedNode=this.currentNode,this.canvas.onmousemove=e=>{this.handleMouseMove(e)},this.canvas.onmouseout=e=>{this.changeHoveredNode(void 0),this.events.emit(`hover`,null,e)},this.canvas.onclick=e=>{let t=this.hitTestNode(e);if(!t)return;this.events.emit(`click`,t,e);let n=[];t===this.animatedNode.parent?this.historyStack.length>0&&(t=this.historyStack.pop(),n=this.historyStack.slice()):n=this.historyStack.concat(this.currentNode),this.events.emit(`click`,t,e),t.children.length>0?(this.select(t),this.historyStack=n):e.preventDefault()},this.el.append(this.canvas),this.resize(),Promise.resolve().then(()=>this.resize()),this.disposables.push(pt(()=>this.resize())),this.disposables.push(ft(e=>this.handleMouseMove(e)))}select(e,t){(this.currentNode!==e||this.root)&&(this.currentNode=e||this.root,this.updateSunburst(t),this.events.emit(`select`,e))}resize(){this.width=this.el.clientWidth,this.height=this.width,this.centerX=this.width>>1,this.centerY=this.height>>1;let e=2*Math.ceil(Dt(this.maxDepth));this.radiusScale=this.width/e,super.resize()}draw(){this.c.clearRect(0,0,this.width,this.height),this.drawNode(this.animatedNode,this.animatedDepth,this.computeRadius(this.animatedDepth),this.animatedStartAngle,this.animatedSweepAngle,3,-1/0),this.c.strokeStyle=this.palette.stroke,this.c.beginPath(),this.drawNode(this.animatedNode,this.animatedDepth,this.computeRadius(this.animatedDepth),this.animatedStartAngle,this.animatedSweepAngle,1,-1/0),this.c.stroke(),this.animatedDepth===0&&(this.c.fillStyle=this.palette.stroke,this.setFont(vt),this.c.textAlign=`center`,this.c.fillText(this.getSubtext(this.targetNode)??ut(this.targetNode.size),this.centerX,this.centerY))}drawNode(e,t,n,r,i,a,o){let s=this.computeRadius(t+1);if(s>this.centerY)return o;e===this.hoveredNode&&(a|=8);let c=(n+s)/2,l=r+i;if(l-o<1.5/c)return o;let u=2/c;if(i>u&&(u=i),a&2)this.c.fillStyle=Ze(this.getColor(e)||this.palette.fallback,this.c,this.centerX,this.centerY,1),this.c.beginPath(),this.c.arc(this.centerX,this.centerY,n,r,r+u,!1),this.c.arc(this.centerX,this.centerY,s,r+u,r,!0),this.c.fill(),this.hoveredNode&&(a&8||e.parent===this.hoveredNode)&&(this.c.fillStyle=this.palette.hover,this.c.fill());else{let e=u===Math.PI*2,t=a&4||e?s:n;a&1&&n>0&&this.c.arc(this.centerX,this.centerY,n,r+u,r,!0),this.c.moveTo(this.centerX+t*Math.cos(r),this.centerY+t*Math.sin(r)),this.c.arc(this.centerX,this.centerY,s,r,r+u,!1),e||this.c.lineTo(this.centerX+n*Math.cos(r+u),this.centerY+n*Math.sin(r+u))}let d=e.size,f=a&10,p=0,m=-1/0;for(let n of e.children)m=this.drawNode(n,t+1,s,r+i*p/d,n.size/d*i,f,m),p+=n.size,f|=4;return l}changeHoveredNode(e,t){this.hoveredNode!==e&&(this.hoveredNode=e,this.updateSunburst(t))}hitTestNode(e){let t=this.canvas.getBoundingClientRect(),n=e.clientX-t.left-this.centerX,r=e.clientY-t.top-this.centerY,i=Math.sqrt(n*n+r*r),a=Math.atan2(r,n),o=(e,t,n,r,s)=>{let c=this.computeRadius(t+1);if(c>this.centerY)return;if(i>=n&&i<c){let t=a-r;if(t/=Math.PI*2,t-=Math.floor(t),t*=Math.PI*2,t<s)return e===this.animatedNode?e.parent:e}let l=e.size,u=0;for(let n of e.children){let e=o(n,t+1,c,r+s*u/l,n.size/l*s);if(e)return e;u+=n.size}};return o(this.animatedNode,this.animatedDepth,this.computeRadius(this.animatedDepth),this.animatedStartAngle,this.animatedSweepAngle)}tick(){let e=(q()-this.animationStart)/(this.options.animateDuration??J.animateDuration);e<0||e>1?(e=1,this.animatedNode=this.targetNode,this.targetDepth=0,this.targetStartAngle=X,this.targetSweepAngle=Math.PI*2):(e<.5?e*=4*e*e:(e=1-e,e*=4*e*e,e=1-e),this.invalidate()),this.animatedDepth=this.sourceDepth+(this.targetDepth-this.sourceDepth)*e,this.animatedStartAngle=this.sourceStartAngle+(this.targetStartAngle-this.sourceStartAngle)*e,this.animatedSweepAngle=this.sourceSweepAngle+(this.targetSweepAngle-this.sourceSweepAngle)*e,this.draw()}handleMouseMove(e){let t=this.hitTestNode(e);this.changeHoveredNode(t),t&&t!==this.animatedNode.parent?(this.events.emit(`hover`,t,e),this.canvas.style.cursor=`pointer`):this.events.emit(`hover`,null,e)}computeRadius(e){return Dt(e)*this.radiusScale}updateSunburst(e=this.options.animate??!0){if(this.previousHoveredNode!==this.hoveredNode&&(this.previousHoveredNode=this.hoveredNode,this.hoveredNode||(this.canvas.style.cursor=`auto`,this.events.emit(`hover`,null)),this.invalidate()),this.targetNode!==this.currentNode){if(this.historyStack.length=0,this.invalidate(),e&&(this.animationStart=q()),wt(this.animatedNode,this.currentNode)){let e={depth_:this.animatedDepth,startAngle_:this.animatedStartAngle,sweepAngle_:this.animatedSweepAngle};Tt(this.animatedNode,this.currentNode,e),this.animatedDepth=e.depth_,this.animatedStartAngle=e.startAngle_,this.animatedSweepAngle=e.sweepAngle_,this.targetDepth=0,this.targetStartAngle=X,this.targetSweepAngle=Math.PI*2,this.animatedNode=this.currentNode}else if(wt(this.currentNode,this.animatedNode)){let e={depth_:0,startAngle_:X,sweepAngle_:Math.PI*2};Tt(this.currentNode,this.animatedNode,e),this.targetDepth=e.depth_,this.targetStartAngle=e.startAngle_,this.targetSweepAngle=e.sweepAngle_}else this.animationStart=-1/0,this.animatedNode=this.currentNode;this.sourceDepth=this.animatedDepth,this.sourceStartAngle=this.animatedStartAngle,this.sourceSweepAngle=this.animatedSweepAngle,this.targetNode=this.currentNode,this.events.emit(`select`,this.currentNode)}}},Z=4,Q=20,kt=2*Z,$=Q+Z;function At(e,t,n,r,i){let a=[],o=(t,n,r,i,a)=>{let o=e[t].size*a,s=e[n].size*a;return Math.max(r*r*o/(i*i),i*i/(r*r*s))};return((t,n,r,i,s)=>{for(;t<e.length;){let c=0;for(let n=t;n<e.length;n++)c+=e[n].size;let l=Math.min(i,s),u=i*s/c,d=t,f=0,p=0;for(;d<e.length;){let n=e[d].size*u,r=o(t,d,l,f+n,u);if(d>t&&p<r)break;f+=n,p=r,d++}let m=Math.round(f/l),h=0;for(let o=t;o<d;o++){let t=e[o],c=t.size*u,d=Math.round(l*h/f),p=Math.round(l*(h+c)/f),[g,_,v,y]=i>=s?[n,r+d,m,p-d]:[n+d,r,p-d,m];a.push({node:t,box:[g,_,v,y],children:v>kt&&y>$?At(t.children,g+Z,_+Q,v-kt,y-$):[]}),h+=c}t=d,i>=s?(n+=m,i-=m):(r+=m,s-=m)}})(0,t,n,r,i),a}var jt=class extends yt{hoveredNode=null;currentNode=null;bgOriginX=0;bgOriginY=0;layers={base:null};baseLayoutCache;currentOriginX=0;currentOriginY=0;animationStart=0;animationBlend=1;animationSource=null;animationTarget=null;constructor(e,t={}){super(e,t),this.canvas.addEventListener(`mousemove`,e=>{this.updateHover(e)}),this.canvas.addEventListener(`mouseout`,e=>{this.changeHoveredNode(null),this.events.emit(`hover`,null,e)}),this.el.addEventListener(`click`,e=>{let t=this.hitTestNode(e);if(t){let n=t.node;this.events.emit(`click`,n,e),n.children.length?t===this.layers.current?this.updateHover(e):(this.changeCurrentLayout(t),this.changeHoveredNode(null)):this.updateHover(e)}else this.currentNode&&(this.changeCurrentLayout(null),this.updateHover(e))}),this.el.append(this.canvas),this.resize(),Promise.resolve().then(()=>this.resize()),this.disposables.push(ft(e=>this.updateHover(e))),this.disposables.push(pt(()=>this.resize()))}select(e,t){let n=null;e===this.root&&(e=null),n=e?this.searchFor([this.layers.current,this.layers.base],e):null,this.changeCurrentLayout(n,t)}drawBaseLayout(){!this.width||!this.height||(this.c.clearRect(0,0,this.width,this.height),this.bgOriginX=this.bgOriginY=0,this.baseLayoutCache?this.c.putImageData(this.baseLayoutCache,0,0):(this.drawLayout(this.layers.base,0,[]),this.baseLayoutCache=this.c.getImageData(0,0,this.width*this.ratio,this.height*this.ratio)))}draw(){this.drawBaseLayout(),this.layers.current||this.drawHoverHighlight(this.layers.base);let e=this.layers.current?this.animationSource?this.animationTarget?1:1-this.animationBlend:this.animationBlend:0;if(this.layers.current){let[t,n,r,i]=this.layers.base.box;this.c.globalAlpha=.6*(!this.layers.current||!this.animationSource?1:e),this.c.fillStyle=this.palette.bg,this.c.fillRect(t,n,r,i),this.c.globalAlpha=1}if(this.layers.previous&&this.drawLayout(this.layers.previous,1,[this.layers.current]),this.layers.current){let[t,n,r,i]=this.layers.current.box,a=this.c.getTransform(),o=Math.sqrt(a.a*a.d);this.c.save(),this.c.shadowColor=this.palette.shadow,this.c.shadowBlur=30*e*o,this.c.shadowOffsetX=o*(2*this.width),this.c.shadowOffsetY=o*(2*this.height+15*e),this.c.fillRect(t-2*this.width,n-2*this.height,r,i),this.c.restore(),this.bgOriginX=this.currentOriginX,this.bgOriginY=this.currentOriginY,this.drawLayout(this.layers.current,0,[]),this.drawHoverHighlight(this.layers.current)}}tick(){let e=this.animationBlend,t=this.currentNode;this.animationBlend=(q()-this.animationStart)/(this.options.animateDuration??J.animateDuration),this.animationBlend<0||this.animationBlend>1?(this.currentNode=this.animationTarget,this.layers.previous=void 0,this.animationBlend=1):(this.animationBlend=1-this.animationBlend,this.animationBlend*=this.animationBlend*this.animationBlend,this.animationBlend=1-this.animationBlend,this.invalidate()),(this.animationBlend!==e||this.currentNode!==t)&&this.updateCurrentLayout(),this.draw()}resize(){this.baseLayoutCache=void 0;let e=this.width,t=this.height;this.width=Math.min(this.el.clientWidth,1600),this.height=Math.max(Math.round(this.width/2),innerHeight-200),(this.width!==e||this.height!==t||!this.layers.base)&&(this.layers.base=At([this.root],0,0,this.width-1,this.height-1)[0],this.updateCurrentLayout()),super.resize()}*iterateNodeToDraw(e,t,n){let r=e.node,[i,a,o,s]=e.box,c=(r===this.hoveredNode?1:0)|(e===this.animationTarget?2:0);if(t===1)for(let e of n){if(!e)continue;let[n,r,c,l]=e.box;if(i>=n&&a>=r&&i+o<=n+c&&a+s<=r+l){t=2;break}}for(let r of e.children)c|=yield*this.iterateNodeToDraw(r,t,n);return t!==2&&(yield e),c}drawHoverHighlight(e){let t=this.iterateNodeToDraw(e,0,[]),n=this.c.globalCompositeOperation;for(;;){let e=t.next();if(e.done){this.c.globalCompositeOperation=n;return}let r=e.value.node;if(this.hoveredNode===r){this.c.globalCompositeOperation=`overlay`;let[t,n,r,i]=e.value.box;this.c.fillStyle=this.palette.hover,this.c.fillRect(t,n,r,i)}}}drawNodeBackground(e,t,n){let r=this.iterateNodeToDraw(e,t,n);for(;;){let e=r.next();if(e.done)return e.value;let[t,n,i,a]=e.value.box;this.c.fillStyle=Ze(this.getColor(e.value.node)||this.palette.fallback,this.c,this.bgOriginX,this.bgOriginY,1),e.value.children.length?(this.c.fillRect(t,n,i,Q),this.c.fillRect(t,n+a-Z,i,Z),this.c.fillRect(t,n+Q,Z,a-$),this.c.fillRect(t+i-Z,n+Q,Z,a-$)):this.c.fillRect(t,n,i,a)}}drawLayout(e,t,n){this.drawNodeBackground(e,t,n),this.drawNodeForeground(e,t,n)}drawNodeForeground(e,t,n){let r=this.iterateNodeToDraw(e,t,n);for(;;){let e=r.next();if(e.done)return;let t=e.value.node,[n,i,a,o]=e.value.box;if(dt(this.c,this.palette.stroke,n+.5,i+.5,a,o),o>=Q){this.c.fillStyle=this.palette.text;let e=a-kt,r=i+Math.round($/2),[s,c]=this.textOverflowEllipsis(this.getText(t)||``,e),l=n+Math.round((a-c)/2),u=this.getText(t),d=this.getSubtext(t);if(s===u&&t.children.length){let t=d||``;t&&u&&(t=` - ${t}`);let[i,o]=this.textOverflowEllipsis(t,e-c);l=n+Math.round((a-c-o)/2),this.c.globalAlpha=.5,this.c.fillText(i,l+c,r),this.c.globalAlpha=1}if(this.c.fillText(s,l,r),o>$+16&&!t.children.length){let[t,r]=this.textOverflowEllipsis(d||``,e);this.c.globalAlpha=.5;let s=u?Q:Q/2+Z;this.c.fillText(t,n+Math.round((a-r)/2),i+s+Math.round(o-$)/2),this.c.globalAlpha=1}}}}updateCurrentLayout(){let e=this.options.selectedPaddingRatio??.2;if(this.currentNode){let[t,n,r,i]=this.currentNode.box,a=t+r,o=n+i,s=Math.round(this.width*e/2),c=Math.round(this.height*e/2),l=this.width-s-1,u=this.height-c-1,d=this.animationTarget?this.animationBlend:1-this.animationBlend,f=Math.round(t+(s-t)*d),p=Math.round(n+(c-n)*d),m=Math.round(a+(l-a)*d),h=Math.round(o+(u-o)*d),g=e=>e-Math.floor(e/64-.5)*64;this.layers.current=At([this.currentNode.node],f,p,m-f,h-p)[0],this.currentOriginX=g(-(t+a)/2)*(1-d)+(f+m)/2,this.currentOriginY=g(-(n+o)/2)*(1-d)+(p+h)/2}else this.layers.current=void 0,this.currentOriginX=0,this.currentOriginY=0}hitTestNode(e){let t=this.canvas.getBoundingClientRect(),n=e.clientX-t.left,r=e.clientY-t.top,i=(e,t)=>{for(let a of e){let[e,o,s,c]=a.box;if(n>=e&&r>=o&&n<e+s&&r<o+c)return i(a.children,!1)||(t?null:a)}return null};return this.layers.current?i([this.layers.current],!1):i([this.layers.base],!0)}updateHover(e){let t=this.hitTestNode(e);this.changeHoveredNode(t&&t.node),this.events.emit(`hover`,t?.node||null,e)}changeHoveredNode(e){this.hoveredNode!==e&&(this.hoveredNode=e,this.canvas.style.cursor=e&&!e.children.length?`pointer`:`auto`,this.invalidate())}searchFor(e,t){for(let n of e){if(!n)continue;let e=n.node===t?n:this.searchFor(n.children,t);if(e)return e}return null}changeCurrentLayout(e,t=this.options.animate){this.animationTarget!==e&&(this.events.emit(`select`,e?.node||null),this.layers.previous=e?this.layers.current:void 0,t&&(this.animationBlend=0,this.animationStart=q(),this.animationSource=this.currentNode),this.animationTarget=e,this.currentNode=e||this.searchFor([this.layers.base],this.currentNode.node),this.updateCurrentLayout(),this.invalidate())}},Mt={flex:`~ gap-1 items-center wrap`},Nt={key:0,"i-ph-arrow-right-bold":``,"text-sm":``,"op-fade":``},Pt=[`onClick`],Ft=Object.assign(a({__name:`NavBreadcrumb`,props:{selected:{},options:{}},emits:[`select`],setup(e,{emit:n}){let i=e,a=n,o=f(()=>{let e=[],t=i.selected;for(;t;)e.unshift(t),t=t.parent;return e});return(e,n)=>(g(),v(`div`,Mt,[(g(!0),v(m,null,u(o.value,(e,n)=>(g(),v(m,{key:e.id},[n>0?(g(),v(`div`,Nt)):t(``,!0),b(`button`,{hover:`bg-active`,rounded:``,px1:``,onClick:t=>a(`select`,e)},[b(`span`,null,r(e.text||e.id),1)],8,Pt)],64))),128))]))}}),{__name:`ChartNavBreadcrumb`});function It(t){let{data:r,nameKey:a,sizeKey:o,rootText:s,nodeType:l,graphOptions:u,onUpdate:d}=t,m=c(void 0),g=c(void 0),_=p(void 0),v=c(void 0),y,b=f(()=>{if(t.tree)return t.tree.value;let e=n(r),i=new Map,c=0,u={id:`~root`,text:s,size:0,sizeSelf:0,children:[]};if(!e?.length)return{map:i,root:u,maxDepth:c};let d=[];d.unshift(()=>{u.size+=u.children.reduce((e,t)=>e+t.size,0),u.subtext=D(u.size).join(` `),u.children.sort((e,t)=>t.size-e.size||e.id.localeCompare(t.id))});function f(e,t,n,r,a){if(i.has(t))return i.get(t);a>c&&(c=a);let o={id:t,text:n,size:0,sizeSelf:0,children:[],meta:{...e,path:n,type:`folder`},parent:r};return i.set(t,o),r.children.push(o),d.unshift(()=>{let t=o.sizeSelf;o.size+=o.children.reduce((e,t)=>e+t.size,0),o.subtext=D(o.size).join(` `),o.children.length&&t/o.size>.1&&o.children.push({id:`${o.id}-self`,text:``,size:t,sizeSelf:t,subtext:D(t).join(` `),children:[],meta:{...e,path:``,type:l},parent:o}),o.children.sort((e,t)=>t.size-e.size||e.id.localeCompare(t.id))}),o}function p(e){let t=e[a].split(`/`).filter(Boolean),n=u,r=``,s=0;t.forEach((c,u)=>{if(r+=(r?`/`:``)+c,s++,u===t.length-1){let t={id:e[a],text:c,size:e[o],sizeSelf:e[o],subtext:D(e[o]).join(` `),children:[],meta:{...e,path:c,type:l}};n.children.push(t),i.set(e[a],t)}else n=f(e,r,c,n,s)})}return e.forEach(p),d.forEach(e=>e()),{map:i,root:u,maxDepth:c}}),x=f(()=>({animate:ie.value.chartAnimation,palette:{stroke:E.value?`#222`:`#555`,fg:E.value?`#fff`:`#000`,bg:E.value?`#111`:`#fff`},getColor:et(b.value.root,E.value?.8:.9,E.value?1:1.1),getSubtext:e=>e.subtext,...u}));function S(e,t){_.value=e?.meta,e?.children.length||(e=e?.parent),v.value?.select(e,t)}function C(){y?.(),g.value=b.value.root,d?.(),e(()=>{let e=_.value&&b.value.map.get(_.value[a])||null;e&&S(e,!1)}),y=()=>{v.value?.dispose(),v.value=void 0,_.value=void 0}}return e(()=>{h(()=>[b.value,x.value],()=>{C()},{deep:!0,immediate:!1}),C()}),i(()=>{y?.()}),{tree:b,graph:v,chartOptions:x,nodeHover:m,nodeSelected:g,selectedNode:_,selectNode:S,buildGraph:C}}export{jt as a,Ge as c,Ot as i,Ft as n,Qe as o,Ct as r,it as s,It as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{A as e,Et as t,Gt as n,M as r,b as i,bt as a,lt as o,q as s,w as c,x as l}from"./CEtF9LWU.js";import{C as u,w as d}from"./Cb77vzCb.js";import{g as f,v as p}from"./DJTkDKGN.js";import{t as m}from"./BdJ_JF0w.js";import{i as h,l as g,o as _}from"./ChFn95N-.js";import{n as v,r as y,t as b}from"./BgoIwvw3.js";import{t as x}from"./CUsyfwWC.js";import{n as S,t as C}from"./qIAw3Eg02.js";var w={flex:`~ col gap-2`,p4:``},T={flex:``,pb2:``},E={"w-8":``,"text-right":``,"text-xs":``,op50:``},D={"overflow-hidden":``,"text-ellipsis":``,"break-all":``,"line-clamp-2":``},O=Object.assign(r({__name:`FlatList`,props:{plugins:{}},setup(r){let i=u();return(a,u)=>{let d=x,f=m;return s(),c(`div`,w,[e(b,{items:r.plugins,"key-prop":`plugin_id`},{default:o(({item:r})=>[l(`div`,T,[e(f,{to:{path:t(i).path,query:{plugin:r.plugin_id}},"font-mono":``,border:`~ rounded base`,"w-full":``,px2:``,py1:``,"text-sm":``,hover:`bg-active`,flex:`~ gap-4 items-center`},{default:o(()=>[l(`div`,E,` #`+n(r.plugin_id),1),l(`span`,D,[e(d,{name:r.name},null,8,[`name`])])]),_:2},1032,[`to`])])]),_:1},8,[`items`])])}}}),{__name:`PluginsFlatList`}),k={relative:``,"min-h-screen":``},A={sticky:``,"left-4":``,"right-4":``,"top-4":``,"z-panel-nav":``,"p-4":``},j={fixed:``,"bottom-4":``,"py-1":``,"px-2":``,"bg-glass":``,left:`1/2`,"translate-x":`-1/2`,border:`~ base rounded-full`,text:`center xs`},M={op50:``},N=r({__name:`plugins`,props:{session:{}},setup(t){let r=t,o=u(),m=d(),b=a({search:o.query.search||``,selected:o.query.plugin_types?S(o.query.plugin_types):null}),x=i(()=>[..._.filter(e=>r.session?.meta?.plugins?.some(t=>e.match.test(t.name))),h]),w=i(()=>{let e=r.session?.meta?.plugins;return b.value.selected&&(e=e.filter(e=>{let t=g(e.name);return b.value.selected.includes(t.name)})),e}),T=f(()=>w.value,()=>new y(w.value,{includeScore:!0,keys:[`name`],ignoreLocation:!0,threshold:.4})),E=i(()=>b.value.search?T.value.search(b.value.search).map(e=>e.item):w.value);return p(b.value,e=>{let t={...o.query,search:e.search||void 0,plugin_types:e.selected||void 0};m.replace({query:C(t)})},{debounce:500}),(r,i)=>{let a=v,o=O;return s(),c(`div`,k,[l(`div`,A,[e(a,{modelValue:b.value,"onUpdate:modelValue":i[0]||=e=>b.value=e,rules:x.value},null,8,[`modelValue`,`rules`])]),e(o,{plugins:E.value??[]},null,8,[`plugins`]),l(`div`,j,[l(`span`,M,n(E.value.length)+` of `+n(t.session?.meta?.plugins?.length||0),1)])])}}});export{N as default};
|
package/dist/public/index.html
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
<!DOCTYPE html><html lang="en" class="bg-dots"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1"><script type="importmap">{"imports":{"#entry":"/.devtools-rolldown/_nuxt/
|
|
1
|
+
<!DOCTYPE html><html lang="en" class="bg-dots"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1"><script type="importmap">{"imports":{"#entry":"/.devtools-rolldown/_nuxt/C7WGk_rq.js"}}</script><title>Rolldown DevTools</title><link rel="stylesheet" href="/.devtools-rolldown/_nuxt/entry.C3w9SVWr.css" crossorigin><link rel="modulepreload" as="script" crossorigin href="/.devtools-rolldown/_nuxt/C7WGk_rq.js"><link rel="modulepreload" as="script" crossorigin href="/.devtools-rolldown/_nuxt/BMB5NJph.js"><link rel="modulepreload" as="script" crossorigin href="/.devtools-rolldown/_nuxt/CEtF9LWU.js"><link rel="modulepreload" as="script" crossorigin href="/.devtools-rolldown/_nuxt/DJTkDKGN.js"><link rel="modulepreload" as="script" crossorigin href="/.devtools-rolldown/_nuxt/5tvbNeKa.js"><link rel="modulepreload" as="script" crossorigin href="/.devtools-rolldown/_nuxt/Cb77vzCb.js"><script type="module" src="/.devtools-rolldown/_nuxt/C7WGk_rq.js" crossorigin></script><meta name="description" content="DevTools for Rolldown"><meta property="og:title" content="Rolldown DevTools"><meta property="og:description" content="DevTools for Rolldown"><link rel="icon" type="image/svg+xml" href="/favicon.svg"><script id="unhead:payload" type="application/json">{"title":"Rolldown DevTools"}</script></head><body><div id="__nuxt"></div><div id="teleports"></div><script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/.devtools-rolldown/",buildId:"35ace98d-68a0-4b96-9871-0cefcb64bde5",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script><script type="application/json" data-nuxt-data="nuxt-app" data-ssr="false" id="__NUXT_DATA__">[{"prerenderedAt":1,"serverRendered":2},1774231868073,false]</script></body></html>
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vitejs/devtools-rolldown",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.1.
|
|
5
|
-
"description": "DevTools for Rolldown
|
|
4
|
+
"version": "0.1.4",
|
|
5
|
+
"description": "DevTools for Rolldown",
|
|
6
6
|
"author": "VoidZero Inc.",
|
|
7
7
|
"license": "MIT",
|
|
8
8
|
"homepage": "https://github.com/vitejs/devtools#readme",
|
|
@@ -29,15 +29,15 @@
|
|
|
29
29
|
"dependencies": {
|
|
30
30
|
"@floating-ui/dom": "^1.7.6",
|
|
31
31
|
"@pnpm/read-project-manifest": "^1001.2.5",
|
|
32
|
-
"@rolldown/debug": "^1.0.0-rc.
|
|
32
|
+
"@rolldown/debug": "^1.0.0-rc.10",
|
|
33
33
|
"ansis": "^4.2.0",
|
|
34
34
|
"birpc": "^4.0.0",
|
|
35
35
|
"cac": "^7.0.0",
|
|
36
36
|
"d3-shape": "^3.2.0",
|
|
37
37
|
"diff": "^8.0.3",
|
|
38
38
|
"get-port-please": "^3.2.0",
|
|
39
|
-
"h3": "^1.15.
|
|
40
|
-
"mlly": "^1.8.
|
|
39
|
+
"h3": "^1.15.9",
|
|
40
|
+
"mlly": "^1.8.2",
|
|
41
41
|
"mrmime": "^2.0.1",
|
|
42
42
|
"ohash": "^2.0.11",
|
|
43
43
|
"p-limit": "^7.3.0",
|
|
@@ -45,21 +45,21 @@
|
|
|
45
45
|
"publint": "^0.3.18",
|
|
46
46
|
"sirv": "^3.0.2",
|
|
47
47
|
"split2": "^4.2.0",
|
|
48
|
-
"structured-clone-es": "^
|
|
48
|
+
"structured-clone-es": "^2.0.0",
|
|
49
49
|
"tinyglobby": "^0.2.15",
|
|
50
50
|
"unconfig": "^7.5.0",
|
|
51
51
|
"unstorage": "^1.17.4",
|
|
52
|
-
"vue-virtual-scroller": "^2.0.0-beta.
|
|
52
|
+
"vue-virtual-scroller": "^2.0.0-beta.10",
|
|
53
53
|
"ws": "^8.19.0",
|
|
54
|
-
"@vitejs/devtools-kit": "0.1.
|
|
55
|
-
"@vitejs/devtools-rpc": "0.1.
|
|
54
|
+
"@vitejs/devtools-kit": "0.1.4",
|
|
55
|
+
"@vitejs/devtools-rpc": "0.1.4"
|
|
56
56
|
},
|
|
57
57
|
"devDependencies": {
|
|
58
58
|
"@types/diff": "^8.0.0",
|
|
59
59
|
"@types/split2": "^4.2.3",
|
|
60
60
|
"@types/splitpanes": "^2.2.6",
|
|
61
61
|
"@types/stream-json": "^1.7.8",
|
|
62
|
-
"@unocss/nuxt": "^66.6.
|
|
62
|
+
"@unocss/nuxt": "^66.6.7",
|
|
63
63
|
"@vueuse/components": "^14.2.1",
|
|
64
64
|
"@vueuse/core": "^14.2.1",
|
|
65
65
|
"@vueuse/nuxt": "^14.2.1",
|
|
@@ -76,49 +76,49 @@
|
|
|
76
76
|
"splitpanes": "^4.0.4",
|
|
77
77
|
"stream-json": "^1.9.1",
|
|
78
78
|
"theme-vitesse": "^1.0.0",
|
|
79
|
-
"tsdown": "^0.21.
|
|
80
|
-
"unocss": "^66.6.
|
|
79
|
+
"tsdown": "^0.21.4",
|
|
80
|
+
"unocss": "^66.6.7",
|
|
81
81
|
"vite-hot-client": "^2.1.0"
|
|
82
82
|
},
|
|
83
83
|
"inlinedDependencies": {
|
|
84
|
-
"
|
|
84
|
+
"@babel/code-frame": "7.29.0",
|
|
85
|
+
"@babel/helper-validator-identifier": "7.28.5",
|
|
86
|
+
"@gwhitney/detect-indent": "7.0.1",
|
|
85
87
|
"@pnpm/constants": "1001.3.1",
|
|
88
|
+
"@pnpm/core-loggers": "1001.0.9",
|
|
86
89
|
"@pnpm/error": "1000.0.5",
|
|
87
|
-
"@pnpm/
|
|
88
|
-
"fast-safe-stringify": "2.1.1",
|
|
89
|
-
"individual": "3.0.0",
|
|
90
|
-
"bole": "5.0.25",
|
|
90
|
+
"@pnpm/graceful-fs": "1000.1.0",
|
|
91
91
|
"@pnpm/logger": "1001.0.1",
|
|
92
|
-
"@pnpm/
|
|
93
|
-
"
|
|
92
|
+
"@pnpm/manifest-utils": "1002.0.4",
|
|
93
|
+
"@pnpm/read-project-manifest": "1001.2.5",
|
|
94
94
|
"@pnpm/semver.peer-range": "1000.0.0",
|
|
95
|
-
"@pnpm/types": "1001.3.0",
|
|
96
|
-
"strip-comments-strings": "1.2.0",
|
|
97
95
|
"@pnpm/text.comments-parser": "1000.0.0",
|
|
98
|
-
"
|
|
99
|
-
"imurmurhash": "0.1.4",
|
|
100
|
-
"signal-exit": "4.1.0",
|
|
101
|
-
"write-file-atomic": "5.0.1",
|
|
102
|
-
"js-yaml": "4.1.1",
|
|
103
|
-
"write-yaml-file": "5.0.0",
|
|
96
|
+
"@pnpm/types": "1001.3.0",
|
|
104
97
|
"@pnpm/write-project-manifest": "1000.0.16",
|
|
105
|
-
"
|
|
106
|
-
"
|
|
107
|
-
"@gwhitney/detect-indent": "7.0.1",
|
|
98
|
+
"bole": "5.0.25",
|
|
99
|
+
"error-ex": "1.3.4",
|
|
108
100
|
"fast-deep-equal": "3.1.3",
|
|
109
|
-
"
|
|
101
|
+
"fast-safe-stringify": "2.1.1",
|
|
110
102
|
"graceful-fs": "4.2.11",
|
|
111
|
-
"
|
|
103
|
+
"imurmurhash": "0.1.4",
|
|
104
|
+
"individual": "3.0.0",
|
|
112
105
|
"is-arrayish": "0.2.1",
|
|
113
|
-
"
|
|
106
|
+
"is-windows": "1.0.2",
|
|
107
|
+
"js-tokens": "4.0.0",
|
|
108
|
+
"js-yaml": "4.1.1",
|
|
114
109
|
"json-parse-even-better-errors": "2.3.1",
|
|
110
|
+
"json5": "2.2.3",
|
|
115
111
|
"lines-and-columns": "1.2.4",
|
|
116
|
-
"picocolors": "1.1.1",
|
|
117
|
-
"js-tokens": "4.0.0",
|
|
118
|
-
"@babel/helper-validator-identifier": "7.28.5",
|
|
119
|
-
"@babel/code-frame": "7.29.0",
|
|
120
112
|
"parse-json": "5.2.0",
|
|
121
|
-
"
|
|
113
|
+
"picocolors": "1.1.1",
|
|
114
|
+
"read-yaml-file": "2.1.0",
|
|
115
|
+
"semver": "7.7.4",
|
|
116
|
+
"signal-exit": "4.1.0",
|
|
117
|
+
"stream-json": "1.9.1",
|
|
118
|
+
"strip-bom": "4.0.0",
|
|
119
|
+
"strip-comments-strings": "1.2.0",
|
|
120
|
+
"write-file-atomic": "5.0.1",
|
|
121
|
+
"write-yaml-file": "5.0.0"
|
|
122
122
|
},
|
|
123
123
|
"scripts": {
|
|
124
124
|
"build": "pnpm dev:prepare && ROLLDOWN_OPTIONS_VALIDATION=loose nuxi build src && tsdown",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{A as e,C as t,Et as n,Gt as r,Ht as i,M as a,S as o,Wt as s,Z as c,at as l,b as u,bt as d,et as f,h as p,k as m,lt as h,ot as g,q as _,st as v,ut as y,vt as b,w as x,x as S}from"./CyUS7GqK.js";import{C,w}from"./Bc8dubgH.js";import{c as T,g as E,p as D}from"./D0PBHtPK.js";import{r as O}from"./CeUdh6JR.js";import{n as k}from"#entry";import{t as A}from"./B8Pee7C0.js";import{r as j}from"./D04G8HHr.js";import{n as M}from"./CYHE6NHg.js";import{r as N,t as P}from"./jJjSdHHs.js";import{n as ee,r as F,t as I}from"./D9y1gK-U.js";import{a as L,c as R,i as z,n as B,o as V,r as H,t as te}from"./VSGDfpIu.js";import{t as U}from"./njczzgS1.js";import{t as ne}from"./DjwOaWuE.js";var W={flex:`~ gap-1`},G={"overflow-hidden":``,"text-ellipsis":``,"break-all":``,"line-clamp-2":``},K={op50:``},q=a({__name:`ListItem`,props:{asset:{}},setup(t){return(n,i)=>{let a=M,s=A;return _(),o(s,{to:{query:{asset:t.asset.filename}},"w-full":``,"font-mono":``,border:`~ rounded base`,px2:``,py1:``,"text-sm":``,hover:`bg-active`},{default:h(()=>[S(`div`,W,[e(a,{filename:t.asset.filename},null,8,[`filename`]),S(`span`,G,[m(r(t.asset.filename)+` `,1),S(`span`,K,` (`+r(t.asset.chunk?.name?.replace(/[\[\]]/g,``))+`) `,1)])])]),_:1},8,[`to`])}}}),J=Object.assign(q,{__name:`AssetsListItem`}),Y={p4:``},X={flex:``,pb2:``},Z=a({__name:`List`,props:{assets:{}},setup(t){return(n,r)=>{let i=J;return _(),x(`div`,Y,[e(I,{items:t.assets,"key-prop":`filename`},{default:h(({item:t})=>[S(`div`,X,[e(i,{asset:t},null,8,[`asset`])])]),_:1},8,[`items`])])}}}),re=Object.assign(Z,{__name:`AssetsList`}),Q={flex:`~ gap-2`,p4:``},ie={op50:``},ae=a({__name:`Folder`,props:{assets:{},session:{}},setup(e){let n=e,i=u(()=>{let e=[];return n.assets.forEach(t=>{e.push({full:t.filename,path:t.filename})}),j(e,`Project`)}),a=u(()=>new Map(n.assets.map(e=>[e.filename,e])));return(n,s)=>{let c=U;return _(),x(`div`,Q,[e.assets?.length?(_(),o(c,{key:0,"flex-1":``,node:i.value,icon:`i-catppuccin:folder-dist catppuccin`,"icon-open":`i-catppuccin:folder-dist-open catppuccin`,link:!0,"link-query-key":`asset`},{extra:h(({node:e})=>[S(`span`,ie,` (`+r(a.value.get(e.full)?.chunk?.name?.replace(/[\[\]]/g,``))+`) `,1)]),_:1},8,[`node`])):t(``,!0)])}}}),oe=Object.assign(ae,{__name:`AssetsFolder`}),se={grid:`~ cols-[max-content_1fr] gap-2`,p4:``},ce={flex:`~ col gap-4`},le={key:0,grid:`~ cols-[250px_1fr] gap-1`},ue=[`onClick`],de={key:0,"text-primary":``},fe={key:1},pe=[`onClick`],me=[`title`],he=a({__name:`Sunburst`,props:{graph:{},selected:{}},emits:[`select`],setup(i,{emit:a}){let o=i,u=a,d=l(`el`);return v(()=>d.value?.append(o.graph.el)),(a,o)=>{let l=B,h=N,g=f(`tooltip`);return _(),x(`div`,se,[S(`div`,{ref_key:`el`,ref:d,"w-500px":``},null,512),S(`div`,ce,[e(l,{border:`b base`,py2:``,selected:i.selected,options:i.graph.options,onSelect:o[0]||=e=>u(`select`,e)},null,8,[`selected`,`options`]),i.selected?(_(),x(`div`,le,[(_(!0),x(p,null,c(i.selected.children,a=>(_(),x(p,{key:a.id},[S(`button`,{"ws-nowrap":``,"text-nowrap":``,"text-left":``,"overflow-hidden":``,"text-ellipsis":``,"text-sm":``,hover:`bg-active`,rounded:``,px2:``,onClick:e=>u(`select`,a)},[a.meta&&a.meta===i.selected?.meta?(_(),x(`span`,de,`(self)`)):(_(),x(`span`,fe,r(a.id),1))],8,ue),S(`button`,{relative:``,flex:`~ gap-1 items-center`,hover:`bg-active`,rounded:``,onClick:e=>u(`select`,a)},[S(`div`,{"h-5":``,rounded:``,shadow:``,border:`~ base`,style:s({background:n(V)(i.graph.options.getColor?.(a)||`#000`),width:`${a.size/i.selected.size*100}%`})},null,4),e(h,{"text-xs":``,bytes:a.size,total:i.selected.size,"percent-ratio":3},null,8,[`bytes`,`total`]),a.children.length>0?y((_(),x(`div`,{key:0,title:`${a.children.length} dependencies`,"text-xs":``,"op-fade":``},[m(` (`+r(a.children.length)+`) `,1)],8,me)),[[g,`${a.children.length} dependencies`]]):t(``,!0)],8,pe)],64))),128))])):t(``,!0)])])}}}),ge=Object.assign(he,{__name:`AssetsSunburst`}),_e=a({__name:`Flamegraph`,props:{graph:{}},setup(e){let t=e,n=l(`el`);return v(()=>n.value?.append(t.graph.el)),(e,t)=>(_(),x(`div`,{ref_key:`el`,ref:n},null,512))}}),ve=Object.assign(_e,{__name:`AssetsFlamegraph`}),ye={key:1,relative:``,"max-h-screen":``,"of-hidden":``},be={absolute:``,"left-4":``,"top-4":``,"z-panel-nav":``},$={flex:`~ gap-2 items-center`,p2:``,border:`t base`},xe=[`onClick`],Se={"of-auto":``,"h-screen":``,flex:`~ col gap-2`,pt32:``},Ce={absolute:``,"bottom-4":``,"py-1":``,"px-2":``,"bg-glass":``,left:`1/2`,"translate-x":`-1/2`,border:`~ base rounded-full`,text:`center xs`},we={op50:``},Te={key:0,"bg-glass":``,border:`~ base rounded`,p2:``,"text-sm":``,flex:`~ col gap-2`},Ee={flex:`~ gap-1 items-center`},De={flex:`~ gap-1 items-center`},Oe=a({__name:`assets`,props:{session:{}},setup(a){let s=a,l=b(D()),f=d({search:``}),v=w(),y=C(),A=[{label:`List`,value:`list`,icon:`i-ph-list-duotone`},{label:`Folder`,value:`folder`,icon:`i-ph-folder-duotone`},{label:`Treemap`,value:`treemap`,icon:`i-ph-checkerboard-duotone`},{label:`Sunburst`,value:`sunburst`,icon:`i-ph-chart-donut-duotone`},{label:`Flamegraph`,value:`flamegraph`,icon:`i-ph-chart-bar-horizontal-duotone`}],j=O(),{state:M,isLoading:I}=T(async()=>await j.value.call(`vite:rolldown:get-assets-list`,{session:s.session.id}),null),V=E(()=>M.value,()=>new F(M.value,{includeScore:!0,keys:[`filename`],ignoreLocation:!0,threshold:.4})),U=u(()=>f.value.search?V.value.search(f.value.search).map(e=>e.item):M.value);function W(e){P.value.assetViewType=e}let{tree:G,chartOptions:K,graph:q,nodeHover:J,nodeSelected:Y,selectedNode:X,selectNode:Z,buildGraph:Q}=te({data:U,nameKey:`filename`,sizeKey:`size`,rootText:`Project`,nodeType:`file`,graphOptions:{onClick(e){e&&(J.value=e),e.meta?.type===`file`&&(X.value=e.meta,v.replace({query:{asset:e.meta.filename}}))},onHover(e){e&&!y.query.asset&&(J.value=e),e===null&&(J.value=void 0)},onLeave(){J.value=void 0},onSelect(e){Y.value=e||G.value.root,X.value=e?.meta}},onUpdate(){switch(P.value.assetViewType){case`sunburst`:q.value=new z(G.value.root,K.value);break;case`treemap`:q.value=new L(G.value.root,{...K.value,selectedPaddingRatio:0});break;default:q.value=new H(G.value.root,K.value)}}});return g(()=>P.value.assetViewType,()=>{Q()}),(s,u)=>{let d=k,g=ee,v=re,y=oe,b=B,C=ge,w=ve,T=N,E=R;return n(I)?(_(),o(d,{key:0})):(_(),x(`div`,ye,[S(`div`,be,[e(g,{modelValue:f.value,"onUpdate:modelValue":u[0]||=e=>f.value=e,rules:[]},{default:h(()=>[S(`div`,$,[u[3]||=S(`span`,{op50:``,pl2:``,"text-sm":``},`View as`,-1),(_(),x(p,null,c(A,e=>S(`button`,{key:e.value,"btn-action":``,class:i(n(P).assetViewType===e.value?`bg-active`:`grayscale op50`),onClick:t=>W(e.value)},[S(`div`,{class:i(e.icon)},null,2),m(` `+r(e.label),1)],10,xe)),64))])]),_:1},8,[`modelValue`])]),S(`div`,Se,[n(P).assetViewType===`list`?(_(),x(p,{key:0},[U.value?.length?(_(),o(v,{key:0,assets:U.value,session:a.session},null,8,[`assets`,`session`])):t(``,!0),S(`div`,Ce,[S(`span`,we,r(U.value.length)+` of `+r(n(M)?.length||0),1)])],64)):n(P).assetViewType===`folder`?(_(),x(p,{key:1},[U.value?.length?(_(),o(y,{key:0,assets:U.value,session:a.session},null,8,[`assets`,`session`])):t(``,!0)],64)):n(P).assetViewType===`treemap`?(_(),x(p,{key:2},[n(q)?(_(),o(ne,{key:0,graph:n(q),selected:n(Y),onSelect:u[1]||=e=>n(Z)(e)},{default:h(({selected:t,options:n,onSelect:r})=>[e(b,{border:`b base`,py2:``,"min-h-10":``,selected:t,options:n,onSelect:r},null,8,[`selected`,`options`,`onSelect`])]),_:1},8,[`graph`,`selected`])):t(``,!0)],64)):n(P).assetViewType===`sunburst`?(_(),x(p,{key:3},[n(q)?(_(),o(C,{key:0,graph:n(q),selected:n(Y),onSelect:u[2]||=e=>n(Z)(e)},null,8,[`graph`,`selected`])):t(``,!0)],64)):n(P).assetViewType===`flamegraph`?(_(),x(p,{key:4},[n(q)?(_(),o(w,{key:0,graph:n(q)},null,8,[`graph`])):t(``,!0)],64)):t(``,!0)]),e(E,{"hover-x":l.x,"hover-y":l.y},{default:h(()=>[n(J)?.meta?(_(),x(`div`,Te,[S(`div`,Ee,r(n(J).text),1),S(`div`,De,[e(T,{bytes:n(J).size,percent:!1},null,8,[`bytes`])])])):t(``,!0)]),_:1},8,[`hover-x`,`hover-y`])]))}}});export{Oe as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{A as e,Et as t,Gt as n,M as r,b as i,bt as a,lt as o,q as s,w as c,x as l}from"./CyUS7GqK.js";import{C as u,w as d}from"./Bc8dubgH.js";import{g as f,v as p}from"./D0PBHtPK.js";import{t as m}from"./B8Pee7C0.js";import{i as h,l as g,o as _}from"./GNBXjCbD.js";import{n as v,r as y,t as b}from"./D9y1gK-U.js";import{t as x}from"./pNZCMUGD.js";import{n as S,t as C}from"./qIAw3Eg02.js";var w={flex:`~ col gap-2`,p4:``},T={flex:``,pb2:``},E={"w-8":``,"text-right":``,"text-xs":``,op50:``},D={"overflow-hidden":``,"text-ellipsis":``,"break-all":``,"line-clamp-2":``},O=r({__name:`FlatList`,props:{plugins:{}},setup(r){let i=u();return(a,u)=>{let d=x,f=m;return s(),c(`div`,w,[e(b,{items:r.plugins,"key-prop":`plugin_id`},{default:o(({item:r})=>[l(`div`,T,[e(f,{to:{path:t(i).path,query:{plugin:r.plugin_id}},"font-mono":``,border:`~ rounded base`,"w-full":``,px2:``,py1:``,"text-sm":``,hover:`bg-active`,flex:`~ gap-4 items-center`},{default:o(()=>[l(`div`,E,` #`+n(r.plugin_id),1),l(`span`,D,[e(d,{name:r.name},null,8,[`name`])])]),_:2},1032,[`to`])])]),_:1},8,[`items`])])}}}),k=Object.assign(O,{__name:`PluginsFlatList`}),A={relative:``,"max-h-screen":``,"of-hidden":``},j={absolute:``,"left-4":``,"top-4":``,"z-panel-nav":``},M={"of-auto":``,"h-screen":``,flex:`~ col gap-2`,pt32:``},N={absolute:``,"bottom-4":``,"py-1":``,"px-2":``,"bg-glass":``,left:`1/2`,"translate-x":`-1/2`,border:`~ base rounded-full`,text:`center xs`},P={op50:``},F=r({__name:`plugins`,props:{session:{}},setup(t){let r=t,o=u(),m=d(),b=a({search:o.query.search||``,selected:o.query.plugin_types?S(o.query.plugin_types):null}),x=i(()=>[..._.filter(e=>r.session?.meta?.plugins?.some(t=>e.match.test(t.name))),h]),w=i(()=>{let e=r.session?.meta?.plugins;return b.value.selected&&(e=e.filter(e=>{let t=g(e.name);return b.value.selected.includes(t.name)})),e}),T=f(()=>w.value,()=>new y(w.value,{includeScore:!0,keys:[`name`],ignoreLocation:!0,threshold:.4})),E=i(()=>b.value.search?T.value.search(b.value.search).map(e=>e.item):w.value);return p(b.value,e=>{let t={...o.query,search:e.search||void 0,plugin_types:e.selected||void 0};m.replace({query:C(t)})},{debounce:500}),(r,i)=>{let a=v,o=k;return s(),c(`div`,A,[l(`div`,j,[e(a,{modelValue:b.value,"onUpdate:modelValue":i[0]||=e=>b.value=e,rules:x.value},null,8,[`modelValue`,`rules`])]),l(`div`,M,[e(o,{plugins:E.value??[]},null,8,[`plugins`]),l(`div`,N,[l(`span`,P,n(E.value.length)+` of `+n(t.session?.meta?.plugins?.length||0),1)])])])}}});export{F as default};
|