@nuxt/devtools 0.5.1 → 0.5.2

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.
Files changed (87) hide show
  1. package/README.md +1 -1
  2. package/dist/chunks/module-main.mjs +1 -1
  3. package/dist/client/200.html +2 -2
  4. package/dist/client/404.html +2 -2
  5. package/dist/client/__inspecting/index.html +2 -2
  6. package/dist/client/_nuxt/{Badge.bd9688d4.js → Badge.83906623.js} +1 -1
  7. package/dist/client/_nuxt/{CodeSnippets.vue.c6839222.js → CodeSnippets.vue.189d2c05.js} +1 -1
  8. package/dist/client/_nuxt/{DrawerRight.vue.d8660e34.js → DrawerRight.vue.e303d503.js} +1 -1
  9. package/dist/client/_nuxt/{DurationDisplay.vue.f895ca51.js → DurationDisplay.vue.b44ca7b3.js} +1 -1
  10. package/dist/client/_nuxt/{FilepathItem.vue.1c96e6cc.js → FilepathItem.vue.5b5ced5d.js} +1 -1
  11. package/dist/client/_nuxt/{HelpFab.vue.748cc95d.js → HelpFab.vue.c263b505.js} +1 -1
  12. package/dist/client/_nuxt/{LaunchPage.vue.b71fffc3.js → LaunchPage.vue.10a18c7c.js} +1 -1
  13. package/dist/client/_nuxt/{NCheckbox.vue.96f7ae1a.js → NCheckbox.vue.fc55451a.js} +1 -1
  14. package/dist/client/_nuxt/{NCodeBlock.vue.d5603a1f.js → NCodeBlock.vue.5e846b10.js} +1 -1
  15. package/dist/client/_nuxt/{NIconButton.vue.d0a9a760.js → NIconButton.vue.87d44e1b.js} +1 -1
  16. package/dist/client/_nuxt/{NIconTitle.vue.c8b7e265.js → NIconTitle.vue.44afa7ff.js} +1 -1
  17. package/dist/client/_nuxt/{NLink.vue.404a4f6c.js → NLink.vue.7642253a.js} +1 -1
  18. package/dist/client/_nuxt/{NMarkdown.vue.4d74a5d5.js → NMarkdown.vue.b43fcab0.js} +1 -1
  19. package/dist/client/_nuxt/{NPanelGrids.7b5efdc5.js → NPanelGrids.3011caf9.js} +1 -1
  20. package/dist/client/_nuxt/{NSectionBlock.5d6e9b8e.js → NSectionBlock.9d37fd4b.js} +1 -1
  21. package/dist/client/_nuxt/{NSelect.vue.e5de3a65.js → NSelect.vue.53616e18.js} +1 -1
  22. package/dist/client/_nuxt/{NSwitch.vue.25cba5a5.js → NSwitch.vue.0fe4aa67.js} +1 -1
  23. package/dist/client/_nuxt/{NTextInput.vue.fc99730b.js → NTextInput.vue.0f5840ce.js} +1 -1
  24. package/dist/client/_nuxt/{NTip.vue.3c4f8e2d.js → NTip.vue.42848f36.js} +1 -1
  25. package/dist/client/_nuxt/{Navbar.vue.f2b7b652.js → Navbar.vue.1156f86c.js} +1 -1
  26. package/dist/client/_nuxt/{NpmVersionCheck.vue.06d8aff2.js → NpmVersionCheck.vue.01d3cdf4.js} +1 -1
  27. package/dist/client/_nuxt/{PanelLeftRight.vue.8eda640c.js → PanelLeftRight.vue.fed8984a.js} +1 -1
  28. package/dist/client/_nuxt/{StateEditor.vue.544a7d41.js → StateEditor.vue.a4934d8c.js} +1 -1
  29. package/dist/client/_nuxt/{__inspecting.fb15a5b2.js → __inspecting.fbaf226d.js} +1 -1
  30. package/dist/client/_nuxt/{analyze-build.1984767c.js → analyze-build.1e11d4c2.js} +1 -1
  31. package/dist/client/_nuxt/{assets.fe704899.js → assets.4e286b98.js} +1 -1
  32. package/dist/client/_nuxt/{client.b1955e54.js → client.a6478274.js} +1 -1
  33. package/dist/client/_nuxt/{components.31fd2c9a.js → components.f00116c7.js} +1 -1
  34. package/dist/client/_nuxt/{custom-_name_.424ca200.js → custom-_name_.4698ded9.js} +1 -1
  35. package/dist/client/_nuxt/{default.4fda98d6.js → default.e408d64e.js} +1 -1
  36. package/dist/client/_nuxt/{editor.02d33c7f.js → editor.60cc6e07.js} +1 -1
  37. package/dist/client/_nuxt/entry.33b4ceee.js +19 -0
  38. package/dist/client/_nuxt/{entry.f90d2a3f.css → entry.5cc961cc.css} +1 -1
  39. package/dist/client/_nuxt/{error-404.39541df6.js → error-404.e559d2f7.js} +1 -1
  40. package/dist/client/_nuxt/{error-500.6d8c1090.js → error-500.0eef607d.js} +1 -1
  41. package/dist/client/_nuxt/{error-component.d86d2bc0.js → error-component.83c76a45.js} +2 -2
  42. package/dist/client/_nuxt/{full.e465e0f9.js → full.872180c4.js} +1 -1
  43. package/dist/client/_nuxt/hooks.f607bdd3.js +1 -0
  44. package/dist/client/_nuxt/{imports.6c4842e1.js → imports.af078df6.js} +1 -1
  45. package/dist/client/_nuxt/{index.8ae957ed.js → index.0676e898.js} +1 -1
  46. package/dist/client/_nuxt/{index.6feef59a.js → index.ed5657ea.js} +1 -1
  47. package/dist/client/_nuxt/{json-editor-vue.2379a5ec.js → json-editor-vue.3247103b.js} +47 -47
  48. package/dist/client/_nuxt/{middleware.4b7f7a54.js → middleware.f8f2ddc7.js} +1 -1
  49. package/dist/client/_nuxt/modules.1cb9572d.js +4 -0
  50. package/dist/client/_nuxt/{none.94eb9e94.js → none.2ff7cc7a.js} +1 -1
  51. package/dist/client/_nuxt/{open-graph.9ad8c33f.js → open-graph.22edbc56.js} +1 -1
  52. package/dist/client/_nuxt/{overview.88b9ee1d.js → overview.12716b2d.js} +1 -1
  53. package/dist/client/_nuxt/{pages.196c3253.js → pages.56e34b91.js} +1 -1
  54. package/dist/client/_nuxt/{payload.b786d84c.js → payload.98eee0c8.js} +1 -1
  55. package/dist/client/_nuxt/{plugins.06f4e6ce.js → plugins.33f32b58.js} +1 -1
  56. package/dist/client/_nuxt/{runtime-configs.bfbdafdb.js → runtime-configs.12858433.js} +1 -1
  57. package/dist/client/_nuxt/{server-routes.477b8c10.js → server-routes.bde5bee5.js} +1 -1
  58. package/dist/client/_nuxt/settings.e641de98.js +1 -0
  59. package/dist/client/_nuxt/{storage.20802247.js → storage.b8b29d67.js} +1 -1
  60. package/dist/client/_nuxt/{terminals.ab54a064.js → terminals.a3a9bc56.js} +1 -1
  61. package/dist/client/_nuxt/{unocss-runtime.83acba48.js → unocss-runtime.2f120d48.js} +1 -1
  62. package/dist/client/_nuxt/{virtual-files.35133aa6.js → virtual-files.c0c7f5bc.js} +1 -1
  63. package/dist/client/index.html +2 -2
  64. package/dist/client/modules/analyze-build/index.html +2 -2
  65. package/dist/client/modules/assets/index.html +2 -2
  66. package/dist/client/modules/components/index.html +2 -2
  67. package/dist/client/modules/hooks/index.html +2 -2
  68. package/dist/client/modules/imports/index.html +2 -2
  69. package/dist/client/modules/middleware/index.html +2 -2
  70. package/dist/client/modules/modules/index.html +2 -2
  71. package/dist/client/modules/open-graph/index.html +2 -2
  72. package/dist/client/modules/overview/index.html +2 -2
  73. package/dist/client/modules/pages/index.html +2 -2
  74. package/dist/client/modules/payload/index.html +2 -2
  75. package/dist/client/modules/plugins/index.html +2 -2
  76. package/dist/client/modules/runtime-configs/index.html +2 -2
  77. package/dist/client/modules/server-routes/index.html +2 -2
  78. package/dist/client/modules/storage/index.html +2 -2
  79. package/dist/client/modules/terminals/index.html +2 -2
  80. package/dist/client/modules/virtual-files/index.html +2 -2
  81. package/dist/client/settings/index.html +2 -2
  82. package/dist/module.json +1 -1
  83. package/package.json +21 -21
  84. package/dist/client/_nuxt/entry.5024288d.js +0 -19
  85. package/dist/client/_nuxt/hooks.700e3ecc.js +0 -1
  86. package/dist/client/_nuxt/modules.0c194e4b.js +0 -4
  87. package/dist/client/_nuxt/settings.ffb64330.js +0 -1
@@ -1 +0,0 @@
1
- import{_ as S}from"./DurationDisplay.vue.f895ca51.js";import{a as H,r as C,p as v,o as d,h as m,f as o,l,s as _,u as s,F as N,q as T,t as h,P as B,i,ak as F,b as D,c as I,w as g,v as V}from"./entry.5024288d.js";import{_ as j}from"./NSectionBlock.5d6e9b8e.js";import{_ as L}from"./HelpFab.vue.748cc95d.js";import"./NIconTitle.vue.c8b7e265.js";import"./NIconButton.vue.d0a9a760.js";const P={"w-full":""},z={border:"b base"},A={"select-none":"","ws-nowrap":"",p1:"","text-right":"","font-bold":""},E={colspan:"2",p1:"",pl5:"","text-left":"","font-bold":""},O={"ws-nowrap":"",p1:"","text-center":"","font-bold":""},q={"ws-nowrap":"",p1:"","text-center":"","font-bold":""},M={"ws-nowrap":"",p1:"","text-right":"","font-bold":""},R={"w-0":"","ws-nowrap":"","text-center":"","text-sm":"",op25:""},G={"text-sm":""},J={"ws-nowrap":""},K={"text-sm":""},Q={"w-0":"","text-center":"","text-sm":""},U={"w-0":"","text-center":"","text-sm":""},W={"w-0":"","text-right":"","text-sm":""},X=H({__name:"HooksTable",props:{hooks:null},setup(k){const c=k,a=C("duration"),r=C("asc"),b={duration:(e,t)=>(t.duration??1/0)-(e.duration??1/0),name:(e,t)=>e.name.localeCompare(t.name),listener:(e,t)=>t.listeners-e.listeners,start:(e,t)=>t.start-e.start,executions:(e,t)=>t.executions.length-e.executions.length},$=v(()=>c.hooks.map(e=>e.start).sort((e,t)=>e-t)),x=v(()=>{const e=b[a.value],t=[...c.hooks].sort(e);return r.value==="desc"&&t.reverse(),t});function u(e){const t=e.split(":");return t.length===1?"":`${t[0]}:`}function f(e){const t=e.split(":");return t.length===1?e:t.slice(1).join(":")}function w(e){let t=0;for(let n=0;n<e.length;n++)t=e.charCodeAt(n)+((t<<5)-t);return`hsl(${t%360}, 65%, 50%)`}function p(e){a.value===e?r.value=r.value==="asc"?"desc":"asc":a.value=e}return(e,t)=>{const y=S;return d(),m("table",P,[o("thead",z,[o("tr",null,[o("th",A,[o("button",{onClick:t[0]||(t[0]=n=>p("start"))},[l(" Order "),o("div",{"ml--1":"","text-xs":"",class:_([s(a)==="start"?"op50":"op0",s(r)==="asc"?"carbon-arrow-down":"carbon-arrow-up"])},null,2)])]),o("th",E,[o("button",{onClick:t[1]||(t[1]=n=>p("name"))},[l(" Hook name "),o("div",{"ml--1":"","text-xs":"",class:_([s(a)==="name"?"op50":"op0",s(r)==="asc"?"carbon-arrow-down":"carbon-arrow-up"])},null,2)])]),o("th",O,[o("button",{onClick:t[2]||(t[2]=n=>p("listener"))},[l(" Listeners "),o("div",{"ml--1":"","text-xs":"",class:_([s(a)==="listener"?"op50":"op0",s(r)==="asc"?"carbon-arrow-down":"carbon-arrow-up"])},null,2)])]),o("th",q,[o("button",{onClick:t[3]||(t[3]=n=>p("executions"))},[l(" Executions "),o("div",{"ml--1":"","text-xs":"",class:_([s(a)==="executions"?"op50":"op0",s(r)==="asc"?"carbon-arrow-down":"carbon-arrow-up"])},null,2)])]),o("th",M,[o("button",{onClick:t[4]||(t[4]=n=>p("duration"))},[l(" Duration "),o("div",{"ml--1":"","text-xs":"",class:_([s(a)==="duration"?"op50":"op0",s(r)==="asc"?"carbon-arrow-down":"carbon-arrow-up"])},null,2)])])])]),o("tbody",null,[(d(!0),m(N,null,T(s(x),n=>(d(),m("tr",{key:n.name,border:"b dashed transparent hover:base"},[o("td",R,h(s($).indexOf(n.start)),1),o("td",{"w-0":"","ws-nowrap":"","text-right":"",style:B({color:w(u(n.name))})},[o("code",G,h(u(n.name)),1)],4),o("td",J,[o("code",K,h(f(n.name)),1)]),o("td",Q,h(n.listeners),1),o("td",U,h(n.executions.length+1),1),o("td",W,[i(y,{duration:n.duration},null,8,["duration"])])]))),128))])])}}}),Y={class:"markdown-body"},Z=o("h1",null,"Hooks",-1),tt=o("p",null,[l("Hooks are an advanced API mainly for module authors or advanced use cases. The hooking system to expand almost every aspect of Nuxt. It’s powered by "),o("a",{href:"https://github.com/unjs/hookable",target:"_blank",rel:"noopener"},"unjs/hookable"),l(".")],-1),ot=o("p",null,[o("a",{href:"https://nuxt.com/docs/guide/going-further/hooks",target:"_blank",rel:"noopener"},"Learn more about hooks"),l(".")],-1),et=[Z,tt,ot],nt={__name:"hooks",setup(k,{expose:c}){return c({frontmatter:{}}),(r,b)=>(d(),m("div",Y,et))}},dt=H({__name:"hooks",setup(k){const c=F(),a=D(),r=v(()=>a.value?.getClientHooksMetrics());return(b,$)=>{const x=X,u=j,f=nt,w=L;return d(),m(N,null,[o("div",null,[s(r)?.length?(d(),I(u,{key:0,icon:"carbon-ibm-cloud-direct-link-1-dedicated-hosting",text:"Client Hooks",description:`Total hooks: ${s(r).length}`,padding:"pl4 pr6"},{default:g(()=>[i(x,{hooks:s(r)},null,8,["hooks"])]),_:1},8,["description"])):V("",!0),i(u,{icon:"carbon-ibm-cloud-direct-link-2-dedicated",text:"Server Hooks",description:`Total hooks: ${s(c).length}`,padding:"pl4 pr6"},{default:g(()=>[i(x,{hooks:s(c)},null,8,["hooks"])]),_:1},8,["description"])]),i(w,null,{default:g(()=>[i(f)]),_:1})],64)}}});export{dt as default};
@@ -1,4 +0,0 @@
1
- import{_ as Le}from"./FilepathItem.vue.1c96e6cc.js";import{a as R,p as A,o as m,c as T,w as $,f as p,u as d,l as M,t as L,h as w,V as B,s as j,v as S,i as x,F as U,q as X,H as $e,a3 as we,an as Ee,r as Z,aa as Ae,k as le,ao as ke,ap as Be,aq as pe,ar as De,as as Re,af as Ie,at as Pe,au as Fe,av as He,a4 as Ue,aw as je,z as qe,a8 as he,ac as We,ax as Ke,P as Ye,ay as Ge,G as Je,a0 as Xe,az as Ze,R as Qe,aA as et,I as tt,ab as _e}from"./entry.5024288d.js";import{_ as nt}from"./NpmVersionCheck.vue.06d8aff2.js";import{u as ze}from"./editor.02d33c7f.js";import{_ as it}from"./NSectionBlock.5d6e9b8e.js";import{_ as Se}from"./NIconButton.vue.d0a9a760.js";import{_ as ot}from"./NIconTitle.vue.c8b7e265.js";import{_ as st}from"./NTextInput.vue.fc99730b.js";import{_ as rt}from"./Badge.bd9688d4.js";import{F as lt}from"./fuse.esm.88e2763d.js";import{_ as Ce}from"./NCodeBlock.vue.d5603a1f.js";import{_ as at}from"./NLink.vue.404a4f6c.js";import{_ as ut}from"./NTip.vue.3c4f8e2d.js";import{_ as ct}from"./HelpFab.vue.748cc95d.js";import"./NCheckbox.vue.96f7ae1a.js";import"./client.b1955e54.js";const dt={flex:"~ col gap2","flex-auto":"","of-hidden":"",px1:""},ft={"gap-1t":"",flex:"","items-center":"","text-ellipsis":"","ws-nowrap":"","text-lg":""},mt={key:2},pt=p("div",{"flex-auto":""},null,-1),ht={key:1,flex:"~ gap-2",title:"Documentation"},_t=p("span",{"i-carbon-link":"","text-lg":"",op50:""},null,-1),vt={key:2,flex:"~ gap-2"},yt=p("span",{"i-carbon-logo-github":"","text-lg":"",op50:""},null,-1),gt={flex:"~ col","items-end":""},bt={key:0,"h-20":"","w-20":"",flex:"","flex-none":"",rounded:"","bg-gray:3":"",p4:""},xt=["src","alt"],$t=p("div",{"i-carbon-circle-dash":"",ma:"","text-4xl":"",op50:""},null,-1),wt={key:1,flex:"~",mt2:"","flex-auto":"","items-end":"","justify-end":""},kt=["src"],It=p("div",{"flex-auto":""},null,-1),zt={flex:"","justify-end":""},St="https://api.nuxtjs.org/api/ipx/s_80,f_webp/gh/nuxt/modules/main/icons/",Ct="https://api.nuxtjs.org/api/ipx/s_44,f_webp/gh_avatar/",Mt="https://github.com/",Tt="https://www.npmjs.com/package/",ae=R({__name:"ModuleItemBase",props:{mod:null,info:null,compact:{type:Boolean}},setup(e){const t=e,n=A(()=>({...t.mod?.meta,...t.mod,...t.info})),i=ze();return(o,s)=>{const r=$e,a=we;return m(),T(a,{p4:"",flex:"~ gap2"},{default:$(()=>[p("div",dt,[p("div",ft,[e.mod.isPackageModule?(m(),T(r,{key:0,to:Tt+(d(n).npm||d(n).name),target:"_blank",hover:"underline text-primary"},{default:$(()=>[M(L(d(n).name),1)]),_:1},8,["to"])):e.mod.entryPath?(m(),w("button",{key:1,role:"button",hover:"underline text-primary",onClick:s[0]||(s[0]=l=>d(i)(e.mod.entryPath))},L(d(n).name),1)):(m(),w("span",mt,L(d(n).name),1)),B(o.$slots,"badge")]),d(n).description?(m(),w("div",{key:0,class:j(e.compact?"ws-nowrap of-hidden truncate":"line-clamp-2"),"mt--1":"","text-sm":"",op50:""},L(d(n).description),3)):S("",!0),pt,d(n).website?(m(),w("div",ht,[_t,x(r,{to:d(n).website,target:"_blank","of-hidden":"",truncate:"","ws-nowrap":"","text-sm":"",op50:"",hover:"op100 underline text-primary"},{default:$(()=>[M(L(d(n).website.replace(/^https?:\/\//,"")),1)]),_:1},8,["to"])])):S("",!0),d(n).github?(m(),w("div",vt,[yt,x(r,{to:d(n).github,target:"_blank","of-hidden":"",truncate:"","ws-nowrap":"","text-sm":"",op50:"",hover:"op100 underline text-primary"},{default:$(()=>[M(L(d(n).github.replace(/^https?:\/\/github.com\//,"")),1)]),_:1},8,["to"])])):S("",!0),B(o.$slots,"items")]),p("div",gt,[d(n).icon||e.mod.isPackageModule?(m(),w("div",bt,[d(n).icon?(m(),w("img",{key:0,src:St+d(n).icon,alt:e.mod.name,ma:""},null,8,xt)):S("",!0),$t])):S("",!0),d(n).maintainers?.length?(m(),w("div",wt,[(m(!0),w(U,null,X(d(n).maintainers,l=>(m(),T(r,{key:l.name,target:"_blank",to:Mt+l.github,title:l.name},{default:$(()=>[p("img",{src:Ct+l.github,"h-6":"","w-6":"","rounded-full":""},null,8,kt)]),_:2},1032,["to","title"]))),128))])):S("",!0),o.$slots.actions?(m(),w(U,{key:2},[It,p("div",zt,[B(o.$slots,"actions")])],64)):S("",!0)])]),_:3})}}}),Ot={key:0,flex:"~ gap-2",title:"Open on filesystem"},Vt=p("span",{"i-carbon-folder-move-to":"","text-lg":"",op50:""},null,-1),Nt=p("span",{"i-carbon-circle-dash":"","animate-spin":"","text-lg":"",op50:""},null,-1),Lt=p("code",{"text-sm":"",op50:""},"Upgrading...",-1),Et={key:1,"mx--2":""},At=["onClick"],Bt=p("span",{"i-carbon-intent-request-active":"","text-lg":"","text-primary":""},null,-1),Dt=p("code",{"text-xs":""},"Update installed, click to restart",-1),Rt=[Bt,Dt],Pt={key:2,"mx--2":""},Ft=["onClick"],Ht=p("span",{"i-carbon-intent-request-upgrade":"","text-lg":"",op50:""},null,-1),Ut={op50:""},jt=p("div",{"i-carbon-arrow-right":"",op50:""},null,-1),qt={"text-green":""},Wt={key:3,flex:"~ gap-2","items-center":"",title:"NPM"},Kt=p("span",{"i-carbon-cube":"","text-lg":"",op50:""},null,-1),Yt={"text-sm":"",op50:""},Gt=R({__name:"ModuleItem",props:{mod:null},setup(e){const t=e,n=A(()=>t.mod.info),i=A(()=>({...t.mod?.meta,...t.mod,...n.value}));return(o,s)=>{const r=Le,a=$e,l=nt,u=ae;return m(),T(u,{mod:e.mod,info:d(n)},{items:$(()=>[e.mod.entryPath?(m(),w("div",Ot,[Vt,x(r,{filepath:e.mod.entryPath,"text-sm":"",op50:"",hover:"text-primary op100"},null,8,["filepath"])])):S("",!0),d(i).npm?(m(),T(l,{key:d(i).npm,"package-name":d(i).npm,options:{dev:!0}},{default:$(({info:f,update:g,state:_,id:v,restart:k})=>[_==="running"?(m(),T(a,{key:0,flex:"~ gap-2","animate-pulse":"","items-center":"",to:v?`/modules/terminals?id=${encodeURIComponent(v)}`:void 0},{default:$(()=>[Nt,Lt]),_:2},1032,["to"])):_==="updated"?(m(),w("div",Et,[p("button",{flex:"~ gap-2",hover:"bg-primary/20","items-center":"",rounded:"","bg-primary:10":"",px2:"","text-sm":"","text-primary":"",onClick:k},Rt,8,At)])):f?.needsUpdate?(m(),w("div",Pt,[p("button",{flex:"~ gap-2",title:"Click to upgrade","items-center":"",rounded:"",px2:"","text-sm":"",hover:"bg-active",onClick:c=>g()},[Ht,p("code",Ut,"v"+L(f.current),1),jt,p("code",qt,"v"+L(f.latest),1)],8,Ft)])):f?.latest?(m(),w("div",Wt,[Kt,p("code",Yt,"v"+L(f.current),1)])):S("",!0)]),_:1},8,["package-name"])):S("",!0)]),_:1},8,["mod","info"])}}}),Jt=R({__name:"NDropdown",props:{modelValue:{type:Boolean}},emits:[],setup(e,{emit:t}){const i=Ee(e,"modelValue",t,{passive:!0}),o=Z();return Ae(o,()=>{i.value=!1}),(s,r)=>{const a=le;return m(),w("div",{ref_key:"el",ref:o,class:"relative"},[B(s.$slots,"trigger",{enabled:d(i),click:()=>i.value=!d(i)},()=>[x(a,{onClick:r[0]||(r[0]=l=>i.value=!d(i))},{default:$(()=>[M(" Dropdown ")]),_:1})]),p("div",{class:j(["absolute z-10 border n-border-base rounded shadow n-transition n-bg-base",[d(i)?"op-100":"op0 pointer-events-none -translate-y-1"]])},[B(s.$slots,"default")],2)],512)}}}),Xt=R({__name:"ModuleItemInstall",props:{item:null},setup(e){const t=e,n=ke(),i=A(()=>n.value.find(r=>r.name===t.item.npm)),o=A(()=>i.value&&i.value.isPackageModule),s=A(()=>i.value&&i.value.isPackageModule&&i.value.isUninstallable);return(r,a)=>{const l=rt,u=Se,f=le,g=Jt,_=ae;return m(),T(_,{mod:{},role:d(o)?"":"button",info:e.item,mb2:"","h-full":"",class:j(d(o)?"border-dashed op75":"hover:bg-active!"),compact:!0,onClick:a[1]||(a[1]=v=>d(o)?null:("useModuleAction"in r?r.useModuleAction:d(pe))(e.item,"install"))},Be({_:2},[d(o)?{name:"badge",fn:$(()=>[x(l,{"bg-green-400:10":"","text-green-400":""},{default:$(()=>[M(" Installed ")]),_:1}),d(s)?(m(),T(g,{key:0,n:"sm green"},{trigger:$(({click:v})=>[x(u,{icon:"carbon-overflow-menu-vertical",onClick:k=>v()},null,8,["onClick"])]),default:$(()=>[x(f,{icon:"carbon-trash-can",n:"red",onClick:a[0]||(a[0]=v=>("useModuleAction"in r?r.useModuleAction:d(pe))(e.item,"uninstall"))},{default:$(()=>[M(" Uninstall ")]),_:1})]),_:1})):S("",!0)]),key:"0"}:void 0]),1032,["role","info","class"])}}});function Zt(){var e=window.navigator.userAgent,t=e.indexOf("MSIE ");if(t>0)return parseInt(e.substring(t+5,e.indexOf(".",t)),10);var n=e.indexOf("Trident/");if(n>0){var i=e.indexOf("rv:");return parseInt(e.substring(i+3,e.indexOf(".",i)),10)}var o=e.indexOf("Edge/");return o>0?parseInt(e.substring(o+5,e.indexOf(".",o)),10):-1}let Y;function te(){te.init||(te.init=!0,Y=Zt()!==-1)}var Q={name:"ResizeObserver",props:{emitOnMount:{type:Boolean,default:!1},ignoreWidth:{type:Boolean,default:!1},ignoreHeight:{type:Boolean,default:!1}},emits:["notify"],mounted(){te(),Ie(()=>{this._w=this.$el.offsetWidth,this._h=this.$el.offsetHeight,this.emitOnMount&&this.emitSize()});const e=document.createElement("object");this._resizeObject=e,e.setAttribute("aria-hidden","true"),e.setAttribute("tabindex",-1),e.onload=this.addResizeHandlers,e.type="text/html",Y&&this.$el.appendChild(e),e.data="about:blank",Y||this.$el.appendChild(e)},beforeUnmount(){this.removeResizeHandlers()},methods:{compareAndNotify(){(!this.ignoreWidth&&this._w!==this.$el.offsetWidth||!this.ignoreHeight&&this._h!==this.$el.offsetHeight)&&(this._w=this.$el.offsetWidth,this._h=this.$el.offsetHeight,this.emitSize())},emitSize(){this.$emit("notify",{width:this._w,height:this._h})},addResizeHandlers(){this._resizeObject.contentDocument.defaultView.addEventListener("resize",this.compareAndNotify),this.compareAndNotify()},removeResizeHandlers(){this._resizeObject&&this._resizeObject.onload&&(!Y&&this._resizeObject.contentDocument&&this._resizeObject.contentDocument.defaultView.removeEventListener("resize",this.compareAndNotify),this.$el.removeChild(this._resizeObject),this._resizeObject.onload=null,this._resizeObject=null)}}};const Qt=Pe();De("data-v-b329ee4c");const en={class:"resize-observer",tabindex:"-1"};Re();const tn=Qt((e,t,n,i,o,s)=>(m(),T("div",en)));Q.render=tn;Q.__scopeId="data-v-b329ee4c";Q.__file="src/components/ResizeObserver.vue";function G(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?G=function(t){return typeof t}:G=function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},G(e)}function nn(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ve(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function on(e,t,n){return t&&ve(e.prototype,t),n&&ve(e,n),e}function ye(e){return sn(e)||rn(e)||ln(e)||an()}function sn(e){if(Array.isArray(e))return ne(e)}function rn(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function ln(e,t){if(e){if(typeof e=="string")return ne(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ne(e,t)}}function ne(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function an(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
2
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function un(e){var t;return typeof e=="function"?t={callback:e}:t=e,t}function cn(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i,o,s,r=function(l){for(var u=arguments.length,f=new Array(u>1?u-1:0),g=1;g<u;g++)f[g-1]=arguments[g];if(s=f,!(i&&l===o)){var _=n.leading;typeof _=="function"&&(_=_(l,o)),(!i||l!==o)&&_&&e.apply(void 0,[l].concat(ye(s))),o=l,clearTimeout(i),i=setTimeout(function(){e.apply(void 0,[l].concat(ye(s))),i=0},t)}};return r._clear=function(){clearTimeout(i),i=null},r}function Me(e,t){if(e===t)return!0;if(G(e)==="object"){for(var n in e)if(!Me(e[n],t[n]))return!1;return!0}return!1}var dn=function(){function e(t,n,i){nn(this,e),this.el=t,this.observer=null,this.frozen=!1,this.createObserver(n,i)}return on(e,[{key:"createObserver",value:function(n,i){var o=this;if(this.observer&&this.destroyObserver(),!this.frozen){if(this.options=un(n),this.callback=function(a,l){o.options.callback(a,l),a&&o.options.once&&(o.frozen=!0,o.destroyObserver())},this.callback&&this.options.throttle){var s=this.options.throttleOptions||{},r=s.leading;this.callback=cn(this.callback,this.options.throttle,{leading:function(l){return r==="both"||r==="visible"&&l||r==="hidden"&&!l}})}this.oldResult=void 0,this.observer=new IntersectionObserver(function(a){var l=a[0];if(a.length>1){var u=a.find(function(g){return g.isIntersecting});u&&(l=u)}if(o.callback){var f=l.isIntersecting&&l.intersectionRatio>=o.threshold;if(f===o.oldResult)return;o.oldResult=f,o.callback(f,l)}},this.options.intersection),Ie(function(){o.observer&&o.observer.observe(o.el)})}}},{key:"destroyObserver",value:function(){this.observer&&(this.observer.disconnect(),this.observer=null),this.callback&&this.callback._clear&&(this.callback._clear(),this.callback=null)}},{key:"threshold",get:function(){return this.options.intersection&&typeof this.options.intersection.threshold=="number"?this.options.intersection.threshold:0}}]),e}();function Te(e,t,n){var i=t.value;if(i)if(typeof IntersectionObserver>"u")console.warn("[vue-observe-visibility] IntersectionObserver API is not available in your browser. Please install this polyfill: https://github.com/w3c/IntersectionObserver/tree/master/polyfill");else{var o=new dn(e,i,n);e._vue_visibilityState=o}}function fn(e,t,n){var i=t.value,o=t.oldValue;if(!Me(i,o)){var s=e._vue_visibilityState;if(!i){Oe(e);return}s?s.createObserver(i,n):Te(e,{value:i},n)}}function Oe(e){var t=e._vue_visibilityState;t&&(t.destroyObserver(),delete e._vue_visibilityState)}var mn={beforeMount:Te,updated:fn,unmounted:Oe},pn={itemsLimit:1e3},hn=/(auto|scroll)/;function Ve(e,t){return e.parentNode===null?t:Ve(e.parentNode,t.concat([e]))}var ee=function(t,n){return getComputedStyle(t,null).getPropertyValue(n)},_n=function(t){return ee(t,"overflow")+ee(t,"overflow-y")+ee(t,"overflow-x")},vn=function(t){return hn.test(_n(t))};function ge(e){if(e instanceof HTMLElement||e instanceof SVGElement){for(var t=Ve(e.parentNode,[]),n=0;n<t.length;n+=1)if(vn(t[n]))return t[n];return document.scrollingElement||document.documentElement}}function ie(e){"@babel/helpers - typeof";return ie=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ie(e)}var yn={items:{type:Array,required:!0},keyField:{type:String,default:"id"},direction:{type:String,default:"vertical",validator:function(t){return["vertical","horizontal"].includes(t)}},listTag:{type:String,default:"div"},itemTag:{type:String,default:"div"}};function gn(){return this.items.length&&ie(this.items[0])!=="object"}var oe=!1;if(typeof window<"u"){oe=!1;try{var bn=Object.defineProperty({},"passive",{get:function(){oe=!0}});window.addEventListener("test",null,bn)}catch{}}let xn=0;var ue={name:"RecycleScroller",components:{ResizeObserver:Q},directives:{ObserveVisibility:mn},props:{...yn,itemSize:{type:Number,default:null},gridItems:{type:Number,default:void 0},itemSecondarySize:{type:Number,default:void 0},minItemSize:{type:[Number,String],default:null},sizeField:{type:String,default:"size"},typeField:{type:String,default:"type"},buffer:{type:Number,default:200},pageMode:{type:Boolean,default:!1},prerender:{type:Number,default:0},emitUpdate:{type:Boolean,default:!1},updateInterval:{type:Number,default:0},skipHover:{type:Boolean,default:!1},listTag:{type:String,default:"div"},itemTag:{type:String,default:"div"},listClass:{type:[String,Object,Array],default:""},itemClass:{type:[String,Object,Array],default:""}},emits:["resize","visible","hidden","update","scroll-start","scroll-end"],data(){return{pool:[],totalSize:0,ready:!1,hoverKey:null}},computed:{sizes(){if(this.itemSize===null){const e={"-1":{accumulator:0}},t=this.items,n=this.sizeField,i=this.minItemSize;let o=1e4,s=0,r;for(let a=0,l=t.length;a<l;a++)r=t[a][n]||i,r<o&&(o=r),s+=r,e[a]={accumulator:s,size:r};return this.$_computedMinItemSize=o,e}return[]},simpleArray:gn,itemIndexByKey(){const{keyField:e,items:t}=this,n={};for(let i=0,o=t.length;i<o;i++)n[t[i][e]]=i;return n}},watch:{items(){this.updateVisibleItems(!0)},pageMode(){this.applyPageMode(),this.updateVisibleItems(!1)},sizes:{handler(){this.updateVisibleItems(!1)},deep:!0},gridItems(){this.updateVisibleItems(!0)},itemSecondarySize(){this.updateVisibleItems(!0)}},created(){this.$_startIndex=0,this.$_endIndex=0,this.$_views=new Map,this.$_unusedViews=new Map,this.$_scrollDirty=!1,this.$_lastUpdateScrollPosition=0,this.prerender&&(this.$_prerender=!0,this.updateVisibleItems(!1)),this.gridItems&&!this.itemSize&&console.error("[vue-recycle-scroller] You must provide an itemSize when using gridItems")},mounted(){this.applyPageMode(),this.$nextTick(()=>{this.$_prerender=!1,this.updateVisibleItems(!0),this.ready=!0})},activated(){const e=this.$_lastUpdateScrollPosition;typeof e=="number"&&this.$nextTick(()=>{this.scrollToPosition(e)})},beforeUnmount(){this.removeListeners()},methods:{addView(e,t,n,i,o){const s=Fe({id:xn++,index:t,used:!0,key:i,type:o}),r=He({item:n,position:0,nr:s});return e.push(r),r},unuseView(e,t=!1){const n=this.$_unusedViews,i=e.nr.type;let o=n.get(i);o||(o=[],n.set(i,o)),o.push(e),t||(e.nr.used=!1,e.position=-9999)},handleResize(){this.$emit("resize"),this.ready&&this.updateVisibleItems(!1)},handleScroll(e){if(!this.$_scrollDirty){if(this.$_scrollDirty=!0,this.$_updateTimeout)return;const t=()=>requestAnimationFrame(()=>{this.$_scrollDirty=!1;const{continuous:n}=this.updateVisibleItems(!1,!0);n||(clearTimeout(this.$_refreshTimout),this.$_refreshTimout=setTimeout(this.handleScroll,this.updateInterval+100))});t(),this.updateInterval&&(this.$_updateTimeout=setTimeout(()=>{this.$_updateTimeout=0,this.$_scrollDirty&&t()},this.updateInterval))}},handleVisibilityChange(e,t){this.ready&&(e||t.boundingClientRect.width!==0||t.boundingClientRect.height!==0?(this.$emit("visible"),requestAnimationFrame(()=>{this.updateVisibleItems(!1)})):this.$emit("hidden"))},updateVisibleItems(e,t=!1){const n=this.itemSize,i=this.gridItems||1,o=this.itemSecondarySize||n,s=this.$_computedMinItemSize,r=this.typeField,a=this.simpleArray?null:this.keyField,l=this.items,u=l.length,f=this.sizes,g=this.$_views,_=this.$_unusedViews,v=this.pool,k=this.itemIndexByKey;let c,b,E,I,O;if(!u)c=b=I=O=E=0;else if(this.$_prerender)c=I=0,b=O=Math.min(this.prerender,l.length),E=null;else{const y=this.getScroll();if(t){let C=y.start-this.$_lastUpdateScrollPosition;if(C<0&&(C=-C),n===null&&C<s||C<n)return{continuous:!0}}this.$_lastUpdateScrollPosition=y.start;const V=this.buffer;y.start-=V,y.end+=V;let z=0;if(this.$refs.before&&(z=this.$refs.before.scrollHeight,y.start-=z),this.$refs.after){const C=this.$refs.after.scrollHeight;y.end+=C}if(n===null){let C,q=0,fe=u-1,N=~~(u/2),me;do me=N,C=f[N].accumulator,C<y.start?q=N:N<u-1&&f[N+1].accumulator>y.start&&(fe=N),N=~~((q+fe)/2);while(N!==me);for(N<0&&(N=0),c=N,E=f[u-1].accumulator,b=N;b<u&&f[b].accumulator<y.end;b++);for(b===-1?b=l.length-1:(b++,b>u&&(b=u)),I=c;I<u&&z+f[I].accumulator<y.start;I++);for(O=I;O<u&&z+f[O].accumulator<y.end;O++);}else{c=~~(y.start/n*i);const C=c%i;c-=C,b=Math.ceil(y.end/n*i),I=Math.max(0,Math.floor((y.start-z)/n*i)),O=Math.floor((y.end-z)/n*i),c<0&&(c=0),b>u&&(b=u),I<0&&(I=0),O>u&&(O=u),E=Math.ceil(u/i)*n}}b-c>pn.itemsLimit&&this.itemsLimitError(),this.totalSize=E;let h;const F=c<=this.$_endIndex&&b>=this.$_startIndex;if(F)for(let y=0,V=v.length;y<V;y++)h=v[y],h.nr.used&&(e&&(h.nr.index=k[h.item[a]]),(h.nr.index==null||h.nr.index<c||h.nr.index>=b)&&this.unuseView(h));const de=F?null:new Map;let H,D,K;for(let y=c;y<b;y++){H=l[y];const V=a?H[a]:H;if(V==null)throw new Error(`Key is ${V} on item (keyField is '${a}')`);if(h=g.get(V),!n&&!f[y].size){h&&this.unuseView(h);continue}D=H[r];let z=_.get(D),C=!1;if(!h)F?z&&z.length?h=z.pop():h=this.addView(v,y,H,V,D):(K=de.get(D)||0,(!z||K>=z.length)&&(h=this.addView(v,y,H,V,D),this.unuseView(h,!0),z=_.get(D)),h=z[K],de.set(D,K+1)),g.delete(h.nr.key),h.nr.used=!0,h.nr.index=y,h.nr.key=V,h.nr.type=D,g.set(V,h),C=!0;else if(!h.nr.used&&(h.nr.used=!0,C=!0,z)){const q=z.indexOf(h);q!==-1&&z.splice(q,1)}h.item=H,C&&(y===l.length-1&&this.$emit("scroll-end"),y===0&&this.$emit("scroll-start")),n===null?(h.position=f[y-1].accumulator,h.offset=0):(h.position=Math.floor(y/i)*n,h.offset=y%i*o)}return this.$_startIndex=c,this.$_endIndex=b,this.emitUpdate&&this.$emit("update",c,b,I,O),clearTimeout(this.$_sortTimer),this.$_sortTimer=setTimeout(this.sortViews,this.updateInterval+300),{continuous:F}},getListenerTarget(){let e=ge(this.$el);return window.document&&(e===window.document.documentElement||e===window.document.body)&&(e=window),e},getScroll(){const{$el:e,direction:t}=this,n=t==="vertical";let i;if(this.pageMode){const o=e.getBoundingClientRect(),s=n?o.height:o.width;let r=-(n?o.top:o.left),a=n?window.innerHeight:window.innerWidth;r<0&&(a+=r,r=0),r+a>s&&(a=s-r),i={start:r,end:r+a}}else n?i={start:e.scrollTop,end:e.scrollTop+e.clientHeight}:i={start:e.scrollLeft,end:e.scrollLeft+e.clientWidth};return i},applyPageMode(){this.pageMode?this.addListeners():this.removeListeners()},addListeners(){this.listenerTarget=this.getListenerTarget(),this.listenerTarget.addEventListener("scroll",this.handleScroll,oe?{passive:!0}:!1),this.listenerTarget.addEventListener("resize",this.handleResize)},removeListeners(){this.listenerTarget&&(this.listenerTarget.removeEventListener("scroll",this.handleScroll),this.listenerTarget.removeEventListener("resize",this.handleResize),this.listenerTarget=null)},scrollToItem(e){let t;const n=this.gridItems||1;this.itemSize===null?t=e>0?this.sizes[e-1].accumulator:0:t=Math.floor(e/n)*this.itemSize,this.scrollToPosition(t)},scrollToPosition(e){const t=this.direction==="vertical"?{scroll:"scrollTop",start:"top"}:{scroll:"scrollLeft",start:"left"};let n,i,o;if(this.pageMode){const s=ge(this.$el),r=s.tagName==="HTML"?0:s[t.scroll],a=s.getBoundingClientRect(),u=this.$el.getBoundingClientRect()[t.start]-a[t.start];n=s,i=t.scroll,o=e+r+u}else n=this.$el,i=t.scroll,o=e;n[i]=o},itemsLimitError(){throw setTimeout(()=>{console.log("It seems the scroller element isn't scrolling, so it tries to render all the items at once.","Scroller:",this.$el),console.log("Make sure the scroller has a fixed height (or width) and 'overflow-y' (or 'overflow-x') set to 'auto' so it can scroll correctly and only render the items visible in the scroll viewport.")}),new Error("Rendered items limit reached")},sortViews(){this.pool.sort((e,t)=>e.nr.index-t.nr.index)}}};const $n={key:0,ref:"before",class:"vue-recycle-scroller__slot"},wn={key:1,ref:"after",class:"vue-recycle-scroller__slot"};function kn(e,t,n,i,o,s){const r=Ue("ResizeObserver"),a=je("observe-visibility");return qe((m(),w("div",{class:j(["vue-recycle-scroller",{ready:o.ready,"page-mode":n.pageMode,[`direction-${e.direction}`]:!0}]),onScrollPassive:t[0]||(t[0]=(...l)=>s.handleScroll&&s.handleScroll(...l))},[e.$slots.before?(m(),w("div",$n,[B(e.$slots,"before")],512)):S("v-if",!0),(m(),T(he(n.listTag),{ref:"wrapper",style:Ye({[e.direction==="vertical"?"minHeight":"minWidth"]:o.totalSize+"px"}),class:j(["vue-recycle-scroller__item-wrapper",n.listClass])},{default:$(()=>[(m(!0),w(U,null,X(o.pool,l=>(m(),T(he(n.itemTag),We({key:l.nr.id,style:o.ready?{transform:`translate${e.direction==="vertical"?"Y":"X"}(${l.position}px) translate${e.direction==="vertical"?"X":"Y"}(${l.offset}px)`,width:n.gridItems?`${e.direction==="vertical"&&n.itemSecondarySize||n.itemSize}px`:void 0,height:n.gridItems?`${e.direction==="horizontal"&&n.itemSecondarySize||n.itemSize}px`:void 0}:null,class:["vue-recycle-scroller__item-view",[n.itemClass,{hover:!n.skipHover&&o.hoverKey===l.nr.key}]]},Ke(n.skipHover?{}:{mouseenter:()=>{o.hoverKey=l.nr.key},mouseleave:()=>{o.hoverKey=null}})),{default:$(()=>[B(e.$slots,"default",{item:l.item,index:l.nr.index,active:l.nr.used})]),_:2},1040,["style","class"]))),128)),B(e.$slots,"empty")]),_:3},8,["style","class"])),e.$slots.after?(m(),w("div",wn,[B(e.$slots,"after")],512)):S("v-if",!0),x(r,{onNotify:s.handleResize},null,8,["onNotify"])],34)),[[a,s.handleVisibilityChange]])}ue.render=kn;ue.__file="src/components/RecycleScroller.vue";const In={"h-full":"",flex:"~ col gap-4"},zn={"flex-auto":"","of-auto":"",flex:"~ col gap-2",pl6:"",pr4:""},Sn=R({__name:"ModuleInstallList",setup(e){const t=Ge(),n=Z(""),i=A(()=>new lt(t.value||[],{keys:["name","description","npm","category"]})),o=A(()=>n.value?i.value.search(n.value).map(s=>s.item):t.value);return(s,r)=>{const a=ot,l=st,u=Xt;return m(),w("div",In,[x(a,{mx6:"",mt6:"","text-xl":"",op75:"",icon:"i-carbon-intent-request-create",text:"Install Module"}),x(l,{modelValue:d(n),"onUpdate:modelValue":r[0]||(r[0]=f=>Je(n)?n.value=f:null),placeholder:"Search...",icon:"carbon-search",n:"primary",mx6:"","px-5":"","py-2":""},null,8,["modelValue"]),p("div",zn,[x(d(ue),{class:"scroller",items:d(o),"item-size":160,"key-field":"name"},{default:$(({item:f})=>[x(u,{item:f},null,8,["item"])]),_:1},8,["items"])])])}}});function P(){}P.prototype={diff:function(t,n){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=i.callback;typeof i=="function"&&(o=i,i={}),this.options=i;var s=this;function r(c){return o?(setTimeout(function(){o(void 0,c)},0),!0):c}t=this.castInput(t),n=this.castInput(n),t=this.removeEmpty(this.tokenize(t)),n=this.removeEmpty(this.tokenize(n));var a=n.length,l=t.length,u=1,f=a+l;i.maxEditLength&&(f=Math.min(f,i.maxEditLength));var g=[{newPos:-1,components:[]}],_=this.extractCommon(g[0],n,t,0);if(g[0].newPos+1>=a&&_+1>=l)return r([{value:this.join(n),count:n.length}]);function v(){for(var c=-1*u;c<=u;c+=2){var b=void 0,E=g[c-1],I=g[c+1],O=(I?I.newPos:0)-c;E&&(g[c-1]=void 0);var h=E&&E.newPos+1<a,F=I&&0<=O&&O<l;if(!h&&!F){g[c]=void 0;continue}if(!h||F&&E.newPos<I.newPos?(b=Mn(I),s.pushComponent(b.components,void 0,!0)):(b=E,b.newPos++,s.pushComponent(b.components,!0,void 0)),O=s.extractCommon(b,n,t,c),b.newPos+1>=a&&O+1>=l)return r(Cn(s,b.components,n,t,s.useLongestToken));g[c]=b}u++}if(o)(function c(){setTimeout(function(){if(u>f)return o();v()||c()},0)})();else for(;u<=f;){var k=v();if(k)return k}},pushComponent:function(t,n,i){var o=t[t.length-1];o&&o.added===n&&o.removed===i?t[t.length-1]={count:o.count+1,added:n,removed:i}:t.push({count:1,added:n,removed:i})},extractCommon:function(t,n,i,o){for(var s=n.length,r=i.length,a=t.newPos,l=a-o,u=0;a+1<s&&l+1<r&&this.equals(n[a+1],i[l+1]);)a++,l++,u++;return u&&t.components.push({count:u}),t.newPos=a,l},equals:function(t,n){return this.options.comparator?this.options.comparator(t,n):t===n||this.options.ignoreCase&&t.toLowerCase()===n.toLowerCase()},removeEmpty:function(t){for(var n=[],i=0;i<t.length;i++)t[i]&&n.push(t[i]);return n},castInput:function(t){return t},tokenize:function(t){return t.split("")},join:function(t){return t.join("")}};function Cn(e,t,n,i,o){for(var s=0,r=t.length,a=0,l=0;s<r;s++){var u=t[s];if(u.removed){if(u.value=e.join(i.slice(l,l+u.count)),l+=u.count,s&&t[s-1].added){var g=t[s-1];t[s-1]=t[s],t[s]=g}}else{if(!u.added&&o){var f=n.slice(a,a+u.count);f=f.map(function(v,k){var c=i[l+k];return c.length>v.length?c:v}),u.value=e.join(f)}else u.value=e.join(n.slice(a,a+u.count));a+=u.count,u.added||(l+=u.count)}}var _=t[r-1];return r>1&&typeof _.value=="string"&&(_.added||_.removed)&&e.equals("",_.value)&&(t[r-2].value+=_.value,t.pop()),t}function Mn(e){return{newPos:e.newPos,components:e.components.slice(0)}}var be=/^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/,xe=/\S/,Ne=new P;Ne.equals=function(e,t){return this.options.ignoreCase&&(e=e.toLowerCase(),t=t.toLowerCase()),e===t||this.options.ignoreWhitespace&&!xe.test(e)&&!xe.test(t)};Ne.tokenize=function(e){for(var t=e.split(/([^\S\r\n]+|[()[\]{}'"\r\n]|\b)/),n=0;n<t.length-1;n++)!t[n+1]&&t[n+2]&&be.test(t[n])&&be.test(t[n+2])&&(t[n]+=t[n+2],t.splice(n+1,2),n--);return t};var ce=new P;ce.tokenize=function(e){var t=[],n=e.split(/(\n|\r\n)/);n[n.length-1]||n.pop();for(var i=0;i<n.length;i++){var o=n[i];i%2&&!this.options.newlineIsToken?t[t.length-1]+=o:(this.options.ignoreWhitespace&&(o=o.trim()),t.push(o))}return t};function Tn(e,t,n){return ce.diff(e,t,n)}var On=new P;On.tokenize=function(e){return e.split(/(\S.+?[.!?])(?=\s+|$)/)};var Vn=new P;Vn.tokenize=function(e){return e.split(/([{}:;,]|\s+)/)};function J(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?J=function(t){return typeof t}:J=function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},J(e)}var Nn=Object.prototype.toString,W=new P;W.useLongestToken=!0;W.tokenize=ce.tokenize;W.castInput=function(e){var t=this.options,n=t.undefinedReplacement,i=t.stringifyReplacer,o=i===void 0?function(s,r){return typeof r>"u"?n:r}:i;return typeof e=="string"?e:JSON.stringify(se(e,null,null,o),o," ")};W.equals=function(e,t){return P.prototype.equals.call(W,e.replace(/,([\r\n])/g,"$1"),t.replace(/,([\r\n])/g,"$1"))};function se(e,t,n,i,o){t=t||[],n=n||[],i&&(e=i(o,e));var s;for(s=0;s<t.length;s+=1)if(t[s]===e)return n[s];var r;if(Nn.call(e)==="[object Array]"){for(t.push(e),r=new Array(e.length),n.push(r),s=0;s<e.length;s+=1)r[s]=se(e[s],t,n,i,o);return t.pop(),n.pop(),r}if(e&&e.toJSON&&(e=e.toJSON()),J(e)==="object"&&e!==null){t.push(e),r={},n.push(r);var a=[],l;for(l in e)e.hasOwnProperty(l)&&a.push(l);for(a.sort(),s=0;s<a.length;s+=1)l=a[s],r[l]=se(e[l],t,n,i,l);t.pop(),n.pop()}else r=e;return r}var re=new P;re.tokenize=function(e){return e.slice()};re.join=re.removeEmpty=function(e){return e};const Ln=R({__name:"CodeDiff",props:{from:null,to:null,lang:null},setup(e){const t=e;function n(a,l){const u=Tn(a.trim(),l.trim()),f=[],g=[],_=[];for(const v of u){const k=v.value.trimEnd().split(`
3
- `);for(const c of k)v.added?(f.push(_.length),_.push(c)):(v.removed&&g.push(_.length),_.push(c))}return{added:f,removed:g,result:_.join(`
4
- `)}}const i=A(()=>n(t.from,t.to));function o(a){let l=0;return a.replace(/class="shiki/,'class="shiki diff').replace(/class="line"/g,u=>(l++,i.value.added.includes(l-1)?'class="line line-added"':i.value.removed.includes(l-1)?'class="line line-removed"':u))}const s=Z();Xe(r);function r(){const a=Ze(s);a&&a.querySelector(".line-added,.line-removed")?.scrollIntoView()}return(a,l)=>{const u=Ce;return m(),T(u,{ref_key:"elRef",ref:s,code:d(i).result,lang:e.lang,"transform-rendered":o,onLoaded:r},null,8,["code","lang"])}}}),En={flex:"~ col gap-2","w-150":"",p4:"",border:"t base"},An={capitalize:""},Bn=p("p",{op50:""}," Following command will be executed in your terminal: ",-1),Dn={op50:""},Rn=p("p",null,[p("span",{op50:""},"After that, Nuxt will "),p("span",{"text-orange":""},"restart automatically"),M(". ")],-1),Pn={flex:"~ gap-3",mt2:"","justify-end":""},Fn=R({__name:"ModuleActionDialog",setup(e){const t=Qe(),n=ze();return(i,o)=>{const s=ae,r=Ce,a=at,l=Ln,u=ut,f=le,g=tt;return m(),T(d(et),null,{default:$(({resolve:_,args:v})=>[x(g,{"model-value":!0,onClose:k=>_(!1)},{default:$(()=>[x(s,{mod:{},info:v[0],border:"none","w-150":"","n-panel-grids":""},null,8,["info"]),p("div",En,[p("h2",{"text-xl":"",class:j(v[2]==="install"?"text-primary":"text-red")},[p("span",An,L(v[2]),1),M(),p("code",null,L(v[0].name),1),M("? ")],2),Bn,x(r,{code:v[1].commands.join(" "),lang:"bash",px4:"",py2:"",border:"~ base rounded",lines:!1},null,8,["code"]),p("p",Dn,[M(" Then your "),x(a,{role:"button",n:"primary",onClick:o[0]||(o[0]=k=>d(n)(d(t)?._nuxtConfigFile)),textContent:"Nuxt config"}),M(" will be updated as: ")]),x(l,{from:v[1].configOriginal,to:v[1].configGenerated,"max-h-80":"","of-auto":"",py2:"",border:"~ base rounded",lang:"ts"},null,8,["from","to"]),Rn,p("div",Pn,[x(u,{n:"sm purple","flex-auto":"",icon:"carbon-chemistry"},{default:$(()=>[M(" Experimental. Backup your project first. ")]),_:1}),x(f,{onClick:k=>_(!1)},{default:$(()=>[M(" Cancel ")]),_:2},1032,["onClick"]),x(f,{n:"solid",capitalize:"",class:j(v[2]==="install"?"n-primary":"n-red"),onClick:k=>_(!0)},{default:$(()=>[M(L(v[2]),1)]),_:2},1032,["class","onClick"])])])]),_:2},1032,["onClose"])]),_:1})}}}),Hn={class:"markdown-body"},Un=p("h1",null,"Modules",-1),jn=p("p",null,[M("Nuxt provides a module system to extend the framework core and simplify integrations. You don’t need to develop everything from scratch or maintain boilerplate if there is already a Nuxt module for it. Adding Nuxt modules is possible using "),p("code",null,"nuxt.config"),M(".")],-1),qn=p("p",null,[p("a",{href:"https://nuxt.com/docs/guide/concepts/modules",target:"_blank",rel:"noopener"},"Learn more on the documentation")],-1),Wn=[Un,jn,qn],Kn={__name:"modules",setup(e,{expose:t}){return t({frontmatter:{}}),(i,o)=>(m(),w("div",Hn,Wn))}},Yn={"h-full":"","w-full":"","of-auto":""},Gn=p("div",{"i-carbon-intent-request-create":"","text-4xl":"",op40:"","group-hover":"op75 text-primary",transition:""},null,-1),Jn=p("div",{"text-lg":"",op40:"","group-hover":"op75 text-primary",transition:""}," Install New Module ",-1),Xn={key:0,border:"l base",pos:"fixed bottom-0 right-0 top-0","z-200":"","w-150":"","bg-base":""},pi=R({__name:"modules",setup(e){const t=Z(!1),n=ke(),i=A(()=>n.value.filter(s=>s.isPackageModule)),o=A(()=>n.value.filter(s=>!s.isPackageModule));return(s,r)=>{const a=Gt,l=we,u=it,f=Se,g=Sn,_=Fn,v=Kn,k=ct;return m(),w(U,null,[p("div",Yn,[x(u,{icon:"carbon-3d-mpr-toggle",text:"Installed Modules","container-class":"grid grid-cols-minmax-400px gap3 px4",padding:!1,description:`Total modules: ${d(i).length}`},{default:$(()=>[(m(!0),w(U,null,X(d(i),c=>(m(),T(a,{key:c.name,mod:c},null,8,["mod"]))),128)),x(l,{border:"1.5 dashed","min-h-30":"",p4:"",transition:"",hover:"border-primary",flex:"~ col gap-2 items-center justify-center",role:"button",class:"group",onClick:r[0]||(r[0]=c=>t.value=!0)},{default:$(()=>[Gn,Jn]),_:1})]),_:1},8,["description"]),d(o).length?(m(),T(u,{key:0,icon:"carbon-3d-mpr-toggle",text:"User Modules","container-class":"grid grid-cols-minmax-400px gap3 px4",padding:!1,description:`Total modules: ${d(o).length}`},{default:$(()=>[(m(!0),w(U,null,X(d(o),c=>(m(),w(U,{key:c.meta?.name||c.entryPath},[c.meta?.name||c.entryPath?(m(),T(a,{key:0,mod:c},null,8,["mod"])):S("",!0)],64))),128))]),_:1},8,["description"])):S("",!0),x(_e,{name:"fade-in"},{default:$(()=>[d(t)?(m(),w("div",{key:0,class:"fixed bottom-0 left-0 right-0 top-0 z-100","bg-black:20":"","backdrop-blur-2":"",onClick:r[1]||(r[1]=c=>t.value=!1)})):S("",!0)]),_:1}),x(_e,{name:"slide-in"},{default:$(()=>[d(t)?(m(),w("div",Xn,[x(f,{icon:"carbon-close",pos:"absolute top-3 right-3","rounded-full":"","text-xl":"",onClick:r[2]||(r[2]=c=>t.value=!1)}),x(g)])):S("",!0)]),_:1}),x(_)]),x(k,null,{default:$(()=>[x(v)]),_:1})],64)}}});export{pi as default};
@@ -1 +0,0 @@
1
- import{_ as F}from"./NIconTitle.vue.c8b7e265.js";import{_ as O}from"./NSwitch.vue.25cba5a5.js";import{a as j,bb as z,h as d,i as s,f as e,F as m,q as h,u as a,w as n,G as y,a2 as I,bc as L,o as i,s as k,t as f,c as E,v as H,l as q,aS as A,k as G}from"./entry.5024288d.js";import{_ as R}from"./NSelect.vue.e5de3a65.js";import{_ as J}from"./NCheckbox.vue.96f7ae1a.js";const K={px6:"",py6:""},M={grid:"~ md:cols-2 gap-x-10 gap-y-3","max-w-300":""},P={flex:"~ col gap-1",py3:""},Q=e("h3",{mb1:"","text-lg":""}," Tabs ",-1),W={flex:"~ gap-2","flex-auto":"","items-center":"","justify-start":""},X={capitalize:"",op75:""},Y={flex:"~ col gap-1",border:"~ base rounded",py3:"",pl4:"",pr2:""},Z={py3:"",flex:"~ col gap-1",border:"b base"},ee=e("h3",{mb1:"","text-lg":""}," Appearance ",-1),oe=e("div",{"carbon-sun":"","dark:carbon-moon":"","translate-y--1px":""},null,-1),te={py3:"",flex:"~ col gap-1",border:"b base"},le=e("h3",{mb1:"","text-lg":""}," UI Scale ",-1),se=["value"],ae={py3:"",flex:"~ col gap-1"},ne=e("h3",{mb1:"","text-lg":""}," Features ",-1),ie=e("span",null,"Close DevTools when clicking outside",-1),ce=e("span",null,"Show help buttons",-1),ge=j({__name:"settings",setup(de){const{interactionCloseOnOutsideClick:g,showExperimentalFeatures:re,showHelpButtons:v,scale:x,hiddenTabs:r,hiddenTabCategories:u}=I(),T=[["Tiny",12/15],["Small",14/15],["Normal",1],["Large",16/15],["Huge",18/15]],C=z(!1);function N(c,t){t?r.value=r.value.filter(p=>p!==c):r.value.push(c)}function w(c,t){t?u.value=u.value.filter(p=>p!==c):u.value.push(c)}return(c,t)=>{const p=F,b=O,S=A,U=G,$=L,B=R,V=J;return i(),d("div",K,[s(p,{class:"mb-5 text-xl op75",icon:"i-carbon-settings-adjust",text:"DevTools Settings"}),e("div",M,[e("div",P,[Q,(i(!0),d(m,null,h(a(C),([o,_])=>(i(),d(m,{key:o},[_.length?(i(),d("div",{key:0,flex:"~ col gap-1","mx--1":"",class:k(a(u).includes(o)?"op50 grayscale":""),"pt-2":""},[s(b,{flex:"~ row-reverse",px2:"",py1:"","n-lime":"","model-value":!a(u).includes(o),"onUpdate:modelValue":l=>w(o,l)},{default:n(()=>[e("div",W,[e("span",X,f(o),1)])]),_:2},1032,["model-value","onUpdate:modelValue"]),e("div",Y,[(i(!0),d(m,null,h(_,l=>(i(),E(b,{key:l.name,flex:"~ row-reverse",py1:"",pl2:"",pr1:"","n-primary":"","model-value":!a(r).includes(l.name),"onUpdate:modelValue":D=>N(l.name,D)},{default:n(()=>[e("div",{flex:"~ gap-2","flex-auto":"","items-center":"","justify-start":"",class:k(a(r).includes(l.name)?"op25":"")},[s(S,{"text-xl":"",icon:l.icon,title:l.title},null,8,["icon","title"]),e("span",null,f(l.title),1)],2)]),_:2},1032,["model-value","onUpdate:modelValue"]))),128))])],2)):H("",!0)],64))),128))]),e("div",null,[e("div",Z,[ee,e("div",null,[s($,null,{default:n(({toggle:o,isDark:_})=>[s(U,{n:"primary",onClick:o},{default:n(()=>[oe,q(" "+f(_.value?"Dark":"Light"),1)]),_:2},1032,["onClick"])]),_:1})])]),e("div",te,[le,s(B,{modelValue:a(x),"onUpdate:modelValue":t[0]||(t[0]=o=>y(x)?x.value=o:null),n:"primary"},{default:n(()=>[(i(),d(m,null,h(T,o=>e("option",{key:o[0],value:o[1]},f(o[0]),9,se)),64))]),_:1},8,["modelValue"])]),e("div",ae,[ne,s(V,{modelValue:a(g),"onUpdate:modelValue":t[1]||(t[1]=o=>y(g)?g.value=o:null),"n-primary":""},{default:n(()=>[ie]),_:1},8,["modelValue"]),s(V,{modelValue:a(v),"onUpdate:modelValue":t[2]||(t[2]=o=>y(v)?v.value=o:null),"n-primary":""},{default:n(()=>[ce]),_:1},8,["modelValue"])])])])])}}});export{ge as default};