@nuxt/devtools 2.0.0-beta.7 → 2.1.0
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/chunks/module-main.mjs +3 -2
- package/dist/chunks/vue-devtools.mjs +3 -3
- package/dist/client/200.html +23 -23
- package/dist/client/404.html +23 -23
- package/dist/client/_nuxt/__blank-j47419ao.js +1 -0
- package/dist/client/_nuxt/{analyze-build-hln29g2i.js → analyze-build-bugaz9us.js} +1 -1
- package/dist/client/_nuxt/{assets-b6uq8g4q.js → assets-osp8hkm5.js} +1 -1
- package/dist/client/_nuxt/builds/latest.json +1 -1
- package/dist/client/_nuxt/builds/meta/5f994163-fc52-4e71-a78a-98b64f1fb08f.json +1 -0
- package/dist/client/_nuxt/{client-kpmlv67d.js → client-edufhzwa.js} +1 -1
- package/dist/client/_nuxt/{code-diff.vue-l6vwnnx9.js → code-diff.vue-gy1k04x9.js} +1 -1
- package/dist/client/_nuxt/{code-snippets.vue-itd505en.js → code-snippets.vue-ofmkxw4b.js} +1 -1
- package/dist/client/_nuxt/components-hzbrj322.js +1 -0
- package/dist/client/_nuxt/composable-item.vue-o29ru8an.js +1 -0
- package/dist/client/_nuxt/{custom-_name_-dvf8mod6.js → custom-_name_-m1v3gtb3.js} +1 -1
- package/dist/client/_nuxt/{data-schema-button.vue-chmssum7.js → data-schema-button.vue-m1rfzflw.js} +1 -1
- package/dist/client/_nuxt/data-schema-drawer-jmqcuxpo.js +2 -0
- package/dist/client/_nuxt/{default-fhkw3irs.js → default-jt337kpj.js} +1 -1
- package/dist/client/_nuxt/{duration-display.vue-dzttyi5n.js → duration-display.vue-gu7el5x3.js} +1 -1
- package/dist/client/_nuxt/entry.css-jfo9gib8.css +1 -0
- package/dist/client/_nuxt/{error-404-eboai2a4.js → error-404-f20h7euk.js} +1 -1
- package/dist/client/_nuxt/error-404.css-fsdpg4tp.css +1 -0
- package/dist/client/_nuxt/{error-500-kvham2jx.js → error-500-kln77uik.js} +1 -1
- package/dist/client/_nuxt/error-500.css-bernuda7.css +1 -0
- package/dist/client/_nuxt/{error-emnwkrjd.js → error-o3wydv8q.js} +1 -1
- package/dist/client/_nuxt/{filepath-item.vue-bisii3l4.js → filepath-item.vue-i51hnv27.js} +1 -1
- package/dist/client/_nuxt/full-hllxflb0.js +1 -0
- package/dist/client/_nuxt/g3h63aw5.js +17 -0
- package/dist/client/_nuxt/{help-fab.vue-jkf9agm3.js → help-fab.vue-lv824f8h.js} +1 -1
- package/dist/client/_nuxt/{hooks-dwvu2u7q.js → hooks-lylmzd7n.js} +1 -1
- package/dist/client/_nuxt/imports-b9yuvomv.js +1 -0
- package/dist/client/_nuxt/index-obsucz0g.js +1 -0
- package/dist/client/_nuxt/{index-codugfas.js → index-pa2alw8p.js} +1 -1
- package/dist/client/_nuxt/launch-page.vue-c4udrikr.js +1 -0
- package/dist/client/_nuxt/modules-jbbzhk6s.js +1 -0
- package/dist/client/_nuxt/nbadge-inu2cbym.js +1 -0
- package/dist/client/_nuxt/{ncheckbox.vue-gfdtqnpm.js → ncheckbox.vue-ebn9fsvc.js} +1 -1
- package/dist/client/_nuxt/{ncode-block.vue-dt6krs6h.js → ncode-block.vue-msaaoy71.js} +1 -1
- package/dist/client/_nuxt/{ndrawer.vue-c5d7jii6.js → ndrawer.vue-nv73yu3i.js} +1 -1
- package/dist/client/_nuxt/ndropdown.vue-f8fjs48r.js +1 -0
- package/dist/client/_nuxt/{nicon-title.vue-hzhi6u0u.js → nicon-title.vue-j1ceohu1.js} +1 -1
- package/dist/client/_nuxt/{nlink.vue-jqcqrruu.js → nlink.vue-ncsjb1ly.js} +1 -1
- package/dist/client/_nuxt/{nmarkdown.vue-jpbjhala.js → nmarkdown.vue-oxfi26vk.js} +1 -1
- package/dist/client/_nuxt/{nnavbar.vue-dbvriqjm.js → nnavbar.vue-c3um92xe.js} +1 -1
- package/dist/client/_nuxt/none-hokh1e0y.js +1 -0
- package/dist/client/_nuxt/{nsection-block-padrvv1c.js → nsection-block-jrje44xx.js} +1 -1
- package/dist/client/_nuxt/{nselect-tabs.vue-el7lub08.js → nselect-tabs.vue-kmg7oqpq.js} +1 -1
- package/dist/client/_nuxt/{nselect.vue-dxksqbxz.js → nselect.vue-otkv89hb.js} +1 -1
- package/dist/client/_nuxt/{nswitch.vue-iu20lc9i.js → nswitch.vue-l8xqfho0.js} +1 -1
- package/dist/client/_nuxt/{open-graph-mfgex6v6.js → open-graph-g14cvh6u.js} +1 -1
- package/dist/client/_nuxt/overview-h8wty1mg.js +1 -0
- package/dist/client/_nuxt/{pages-gkjutz4r.js → pages-bkcg7jdi.js} +1 -1
- package/dist/client/_nuxt/{payload-ea8d0krx.js → payload-oxquqq8k.js} +1 -1
- package/dist/client/_nuxt/pinia-d8u1ilag.js +1 -0
- package/dist/client/_nuxt/{plugins-h6j0tuq2.js → plugins-im2207tt.js} +1 -1
- package/dist/client/_nuxt/render-tree-e9fjta20.js +1 -0
- package/dist/client/_nuxt/{runtime-configs-cs4asm90.js → runtime-configs-dy1sicee.js} +1 -1
- package/dist/client/_nuxt/{server-discovery-bl7z7nb1.js → server-discovery-o8cr9llt.js} +1 -1
- package/dist/client/_nuxt/{server-route-inputs.vue-mu2fane3.js → server-route-inputs.vue-bpkh6jhv.js} +1 -1
- package/dist/client/_nuxt/{server-routes-mxasuxos.js → server-routes-ml9qzq4f.js} +2 -2
- package/dist/client/_nuxt/{server-tasks-f00daaf8.js → server-tasks-jtcxge81.js} +1 -1
- package/dist/client/_nuxt/{settings-kwdictg4.js → settings-k4hm6nna.js} +1 -1
- package/dist/client/_nuxt/{stacktrace-list.vue-f9r30ugc.js → stacktrace-list.vue-b1n0lhud.js} +1 -1
- package/dist/client/_nuxt/{state-components-d4iulvg3.js → state-components-hvnej0jk.js} +1 -1
- package/dist/client/_nuxt/state-editor.vue-o71oq72z.js +1 -0
- package/dist/client/_nuxt/{state-modules-h52b8di8.js → state-modules-d3vu3o41.js} +1 -1
- package/dist/client/_nuxt/{storage-eynssv88.js → storage-d5jfpe6j.js} +1 -1
- package/dist/client/_nuxt/{terminals-5bmriywh.js → terminals-jlz6zkmv.js} +1 -1
- package/dist/client/_nuxt/timeline-cnxzcq07.js +31 -0
- package/dist/client/_nuxt/{unocss-runtime-cb61k1ql.js → unocss-runtime-gc1hqonm.js} +1 -1
- package/dist/client/_nuxt/vendor/json-editor-vue-npezbdce.js +3818 -0
- package/dist/client/_nuxt/vendor/{quicktype-core-lnbp3n5r.js → quicktype-core-i8ym98gu.js} +1 -1
- package/dist/client/_nuxt/vendor/{shiki-ja073547.js → shiki-ian6uf3s.js} +26 -26
- package/dist/client/_nuxt/vendor/{unocss-mstcul8h.js → unocss-hjqyvvq7.js} +2 -2
- package/dist/client/_nuxt/{virtual-files-nnwwbhtv.js → virtual-files-jh7t3cfd.js} +1 -1
- package/dist/client/_nuxt/vue-devtools-dzipubfc.js +2 -0
- package/dist/client/_nuxt/{vue-virtual-scroller.esm-ryb7s73q.js → vue-virtual-scroller.esm-guzt9iin.js} +1 -1
- package/dist/client/index.html +23 -23
- package/dist/module.d.mts +1 -1
- package/dist/module.d.ts +1 -1
- package/dist/module.json +1 -1
- package/dist/runtime/plugins/view/Main.vue +1 -1
- package/dist/runtime/plugins/view/client.js +8 -5
- package/dist/shared/{devtools.2a48a9e5.d.mts → devtools.2e078e30.d.mts} +4 -0
- package/dist/shared/{devtools.2a48a9e5.d.ts → devtools.2e078e30.d.ts} +4 -0
- package/dist/types.d.mts +1 -1
- package/dist/types.d.ts +1 -1
- package/package.json +27 -27
- package/dist/client/_nuxt/__blank-fuqjhiyy.js +0 -1
- package/dist/client/_nuxt/builds/meta/a2070649-1b94-4b72-833e-c8b7aebeedfd.json +0 -1
- package/dist/client/_nuxt/components-ex1azxgr.js +0 -1
- package/dist/client/_nuxt/composable-item.vue-g0zoeh4b.js +0 -1
- package/dist/client/_nuxt/data-schema-drawer-ae0s9izl.js +0 -2
- package/dist/client/_nuxt/entry.css-gcfkqtar.css +0 -1
- package/dist/client/_nuxt/error-404.css-fwe7gpvk.css +0 -1
- package/dist/client/_nuxt/error-500.css-djemplc9.css +0 -1
- package/dist/client/_nuxt/full-lzp51slp.js +0 -1
- package/dist/client/_nuxt/hjpmj1xu.js +0 -17
- package/dist/client/_nuxt/imports-n2wrqcb0.js +0 -1
- package/dist/client/_nuxt/index-o0lbgjvm.js +0 -2
- package/dist/client/_nuxt/launch-page.vue-6pn8vnpe.js +0 -1
- package/dist/client/_nuxt/modules-hxnj5jth.js +0 -1
- package/dist/client/_nuxt/nbadge-pfavq5ao.js +0 -1
- package/dist/client/_nuxt/ndropdown.vue-o80xuhl9.js +0 -1
- package/dist/client/_nuxt/none-by6k7p34.js +0 -1
- package/dist/client/_nuxt/overview-mb2zzitf.js +0 -1
- package/dist/client/_nuxt/pinia-nqtom0ao.js +0 -1
- package/dist/client/_nuxt/render-tree-jy6tezjo.js +0 -1
- package/dist/client/_nuxt/state-editor.vue-o88ak5ml.js +0 -1
- package/dist/client/_nuxt/timeline-iaxiq1nj.js +0 -31
- package/dist/client/_nuxt/vendor/json-editor-vue-kcahofzr.js +0 -3818
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{h as w,x as y,bk as C,H as B,_ as V,V as $}from"./hjpmj1xu.js";import{_ as P}from"./nmarkdown.vue-jpbjhala.js";import{p as v,P as a,a2 as o,U as t,a3 as c,X as i,a8 as m,Z as l,W as F,ae as I,a4 as L,a9 as T,F as D}from"./vendor/json-editor-vue-kcahofzr.js";const E={"text-xl":""},G={flex:"~ gap2 wrap"},W=v({__name:"LaunchPage",props:{name:{},icon:{},title:{},description:{},actions:{}},emits:["action"],setup(_,{emit:p}){const d=_,u=p;function f(e,s){y("launch-page",{pageName:d.name}),e.handle?.(),u("action",s)}return(e,s)=>{const k=C,g=P,h=B,b=V,N=$,x=w;return t(),a(x,null,{default:o(()=>[c(N,{flex:"~ col gap2",mxa:"","min-w-100":"","items-center":"",p6:""},{default:o(()=>[c(k,{mb2:"","text-5xl":"",icon:e.icon||e.icon,title:e.title},null,8,["icon","title"]),i("h1",E,m(e.title),1),e.description?(t(),a(g,{key:0,mb2:"","mt--1":"","text-center":"","text-base":"",op50:"",markdown:e.description},null,8,["markdown"])):l("",!0),i("div",G,[(t(!0),F(D,null,I(e.actions,(n,r)=>(t(),a(b,L({key:r,n:"solid primary",disabled:n.pending,to:n.src,target:n.src?"_blank":void 0,ref_for:!0},n.attrs,{onClick:H=>f(n,r)}),{default:o(()=>[n.pending?(t(),a(h,{key:0,icon:"carbon-circle-dash","animate-spin":""})):l("",!0),T(" "+m(n.label),1)]),_:2},1040,["disabled","to","target","onClick"]))),128))])]),_:1})]),_:1})}}});export{W as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{_ as R}from"./filepath-item.vue-bisii3l4.js";import{L as Y,e as S,H,V as G,s as K,r as q,m as V,x as ee,a9 as W,aa as X,_ as O,O as te,K as oe,A as ne,B as se,v as le}from"./hjpmj1xu.js";import{_ as ae,u as Z,a as ie}from"./state-modules-h52b8di8.js";import{_ as re}from"./duration-display.vue-dzttyi5n.js";import{p as P,q as C,U as o,P as $,a2 as i,X as e,Y as A,a9 as x,a8 as k,W as m,u as j,a0 as L,Z as g,a3 as s,F as B,ae as D,ak as ue,f as T,M as E}from"./vendor/json-editor-vue-kcahofzr.js";import{_ as de}from"./nsection-block-padrvv1c.js";import{_ as pe}from"./nicon-title.vue-hzhi6u0u.js";import{_ as J}from"./ndropdown.vue-o80xuhl9.js";import{_ as me}from"./nnavbar.vue-dbvriqjm.js";import{_ as ce}from"./nbadge-pfavq5ao.js";import{s as _e}from"./vue-virtual-scroller.esm-ryb7s73q.js";import{_ as fe}from"./ncode-block.vue-dt6krs6h.js";import{_ as ve}from"./nlink.vue-jqcqrruu.js";import{_ as ge}from"./code-diff.vue-l6vwnnx9.js";import{_ as xe}from"./help-fab.vue-jkf9agm3.js";import"./vendor/unocss-mstcul8h.js";import"./vendor/shiki-ja073547.js";import"./ncheckbox.vue-gfdtqnpm.js";import"./client-kpmlv67d.js";const be={flex:"~ col gap2","flex-auto":"","of-hidden":"",px1:""},ke={"gap-1t":"",flex:"","items-center":"","text-ellipsis":"","ws-nowrap":"","text-lg":""},he={key:2},ye={key:1,flex:"~ gap-2",title:"Documentation"},$e={key:2,flex:"~ gap-2"},we={key:0,flex:"~ gap-4 items-center"},Ce={flex:"~ gap-2 items-center",op50:""},Me={flex:"~ gap-2 items-center",op50:""},Ie={key:1},Ne={flex:"~ col","items-end":""},Be={key:0,"h-20":"","w-20":"",flex:"","flex-none":"",rounded:"","bg-gray:3":"",p4:""},je=["src","alt"],Pe={key:1,flex:"~",mt2:"","flex-auto":"","items-end":"","justify-end":""},De=["src"],Ae={flex:"","justify-end":""},Te="https://api.nuxtjs.org/api/ipx/s_80,f_webp/gh/nuxt/modules/main/icons/",Le="https://api.nuxtjs.org/api/ipx/s_44,f_webp/gh_avatar/",Oe="https://github.com/",ze="https://www.npmjs.com/package/",U=P({__name:"ModuleItemBase",props:{mod:{},info:{},compact:{type:Boolean},maintainers:{type:Boolean,default:!0}},setup(N){const _=N,a=C(()=>({..._.mod?.meta,..._.mod,..._.info})),b=Y();return(r,t)=>{const n=S,u=H,w=re,y=G;return o(),$(y,{p4:"",flex:"~ gap2"},{default:i(()=>[e("div",be,[A(r.$slots,"main",{},()=>[e("div",ke,[r.mod.isPackageModule?(o(),$(n,{key:0,to:ze+(a.value.npm||a.value.name),target:"_blank",hover:"underline text-primary"},{default:i(()=>[x(k(a.value.name),1)]),_:1},8,["to"])):r.mod.entryPath?(o(),m("button",{key:1,role:"button",hover:"underline text-primary",onClick:t[0]||(t[0]=d=>j(b)(r.mod.entryPath))},k(a.value.name),1)):(o(),m("span",he,k(a.value.name),1)),A(r.$slots,"badge")]),a.value.description?(o(),m("div",{key:0,class:L(r.compact?"ws-nowrap of-hidden truncate":"line-clamp-2"),"mt--1":"","text-sm":"",op50:""},k(a.value.description),3)):g("",!0),t[3]||(t[3]=e("div",{"flex-auto":""},null,-1)),a.value.website?(o(),m("div",ye,[t[1]||(t[1]=e("span",{"i-carbon-link":"","text-lg":"",op50:""},null,-1)),s(n,{to:a.value.website,target:"_blank","of-hidden":"",truncate:"","ws-nowrap":"","text-sm":"",op50:"",hover:"op100 underline text-primary"},{default:i(()=>[x(k(a.value.website.replace(/^https?:\/\//,"")),1)]),_:1},8,["to"])])):g("",!0),a.value.github?(o(),m("div",$e,[t[2]||(t[2]=e("span",{"i-carbon-logo-github":"","text-lg":"",op50:""},null,-1)),s(n,{to:a.value.github,target:"_blank","of-hidden":"",truncate:"","ws-nowrap":"","text-sm":"",op50:"",hover:"op100 underline text-primary"},{default:i(()=>[x(k(a.value.github.replace(/^https?:\/\/github.com\//,"")),1)]),_:1},8,["to"])])):g("",!0)]),A(r.$slots,"items"),a.value.stats?(o(),m("div",we,[e("div",Ce,[s(u,{icon:"carbon-star","text-lg":""}),e("span",null,k(a.value.stats.stars),1)]),e("div",Me,[s(u,{icon:"carbon-download","text-lg":""}),e("span",null,k(a.value.stats.downloads),1)])])):g("",!0),r.mod.timings?.setup?(o(),m("div",Ie,[s(w,{title:"Module Setup Time",flex:"~ items-center",duration:r.mod.timings.setup*1e3,factor:.5},{before:i(()=>[s(u,{icon:"carbon-time",mr2:"","text-lg":"",op50:""})]),_:1},8,["duration"])])):g("",!0)]),e("div",Ne,[a.value.icon||r.mod.isPackageModule?(o(),m("div",Be,[a.value.icon?(o(),m("img",{key:0,src:Te+a.value.icon,alt:r.mod.name,ma:""},null,8,je)):g("",!0),t[4]||(t[4]=e("div",{"i-carbon-cube":"",ma:"","text-4xl":"",op30:""},null,-1))])):g("",!0),a.value.maintainers?.length&&r.maintainers?(o(),m("div",Pe,[(o(!0),m(B,null,D(a.value.maintainers,d=>(o(),$(n,{key:d.name,target:"_blank",to:Oe+d.github,title:d.name},{default:i(()=>[e("img",{src:Le+d.github,"h-6":"","w-6":"","rounded-full":""},null,8,De)]),_:2},1032,["to","title"]))),128))])):g("",!0),r.$slots.actions?(o(),m(B,{key:2},[t[5]||(t[5]=e("div",{"flex-auto":""},null,-1)),e("div",Ae,[A(r.$slots,"actions")])],64)):g("",!0)])]),_:3})}}}),Se={key:0,flex:"~ gap-2",title:"Open on filesystem"},Ue={key:1,"mx--2":""},Fe=["onClick"],qe={key:2,"mx--2":""},Ve=["onClick"],Ee={op50:""},Ye={"text-green":""},He={key:3,flex:"~ gap-2","items-center":"",title:"NPM"},Ge={"text-sm":"",op50:""},Ke=P({__name:"ModuleItem",props:{mod:{}},setup(N){const _=N,a=C(()=>_.mod.info),b=C(()=>({..._.mod?.meta,..._.mod,...a.value})),r=K();return(t,n)=>{const u=R,w=S,y=ae,d=U;return o(),$(d,{mod:t.mod,info:a.value},{items:i(()=>[t.mod.entryPath?(o(),m("div",Se,[n[0]||(n[0]=e("span",{"i-carbon-folder-move-to":"","text-lg":"",op50:""},null,-1)),s(u,{filepath:t.mod.entryPath,"text-sm":"",op50:"",hover:"text-primary op100"},null,8,["filepath"])])):g("",!0),b.value.npm?(o(),$(y,{key:b.value.npm,"package-name":b.value.npm,options:{dev:!0}},{default:i(({info:c,update:p,state:l,id:f,restart:h})=>[l==="running"?(o(),$(w,{key:0,flex:"~ gap-2","animate-pulse":"","items-center":"",to:f?"/modules/terminals":void 0,onClick:M=>f?r.value=f:void 0},{default:i(()=>n[1]||(n[1]=[e("span",{"i-carbon-circle-dash":"","animate-spin":"","text-lg":"",op50:""},null,-1),e("code",{"text-sm":"",op50:""},"Upgrading...",-1)])),_:2},1032,["to","onClick"])):l==="updated"?(o(),m("div",Ue,[e("button",{flex:"~ gap-2",hover:"bg-primary/20","items-center":"",rounded:"","bg-primary:10":"",px2:"","text-sm":"","text-primary":"",onClick:h},n[2]||(n[2]=[e("span",{"i-carbon-intent-request-active":"","text-lg":"","text-primary":""},null,-1),e("code",{"text-xs":""},"Update installed, click to restart",-1)]),8,Fe)])):c?.needsUpdate?(o(),m("div",qe,[e("button",{flex:"~ gap-2",title:"Click to upgrade","items-center":"",rounded:"",px2:"","text-sm":"",hover:"bg-active",onClick:M=>p()},[n[3]||(n[3]=e("span",{"i-carbon-intent-request-upgrade":"","text-lg":"",op50:""},null,-1)),e("code",Ee,"v"+k(c.current),1),n[4]||(n[4]=e("div",{"i-carbon-arrow-right":"",op50:""},null,-1)),e("code",Ye,"v"+k(c.latest),1)],8,Ve)])):c?.latest?(o(),m("div",He,[n[5]||(n[5]=e("span",{"i-carbon-cube":"","text-lg":"",op50:""},null,-1)),e("code",Ge,"v"+k(c.current),1)])):g("",!0)]),_:1},8,["package-name"])):g("",!0)]),_:1},8,["mod","info"])}}}),We=P({__name:"ModuleItemInstall",props:{item:{}},emits:["start"],setup(N,{emit:_}){const a=N,b=_,r=Z(),t=C(()=>r.value.find(d=>d.name===a.item.npm)),n=C(()=>t.value&&t.value.isPackageModule),u=C(()=>t.value&&t.value.isPackageModule&&t.value.isUninstallable);async function w(d,c){const p=c==="install"?q.installNuxtModule:q.uninstallNuxtModule,l=await p(await V(),d.npm,!0);ee(`modules:${c}`,{moduleName:d.npm}),l.commands&&await W.start(d,l,c)&&(X.value.push({name:d.npm,info:d,processId:l.processId}),b("start"),await p(await V(),d.npm,!1))}const y={};return(d,c)=>{const p=ce,l=O,f=J,h=U;return o(),$(h,{mod:y,role:n.value?"":"button",info:d.item,mb2:"","h-full":"",class:L(n.value?"border-dashed op75":"hover:bg-active!"),compact:!0,onClick:c[1]||(c[1]=M=>n.value?null:w(d.item,"install"))},ue({_:2},[n.value?{name:"badge",fn:i(()=>[s(p,{n:"green",textContent:"Installed"}),u.value?(o(),$(f,{key:0,n:"sm green"},{trigger:i(({click:M})=>[s(l,{icon:"carbon-overflow-menu-vertical",border:!1,onClick:v=>M()},null,8,["onClick"])]),default:i(()=>[s(l,{icon:"carbon-trash-can",n:"red",onClick:c[0]||(c[0]=M=>w(d.item,"uninstall"))},{default:i(()=>c[2]||(c[2]=[x(" Uninstall ")])),_:1})]),_:1})):g("",!0)]),key:"0"}:void 0]),1032,["role","info","class"])}}}),Xe={"h-full":"",flex:"~ col gap-4"},Ze={flex:"~ items-center"},Je={flex:"~ col","w-30":"","of-auto":""},Qe={flex:"~ justify-between","w-full":"","text-xs":"",capitalize:"",op75:""},Re={"flex-auto":"","of-auto":"",flex:"~ col gap-2",pl6:"",pr4:""},et=P({__name:"ModuleInstallList",emits:["close"],setup(N,{emit:_}){const a=_,b=ie(),r=["downloads","stars","updated","created"],t=T(!1),n=T(r[0]),u={downloads:(p,l)=>p.stats.downloads-l.stats.downloads,stars:(p,l)=>p.stats.stars-l.stats.stars,created:(p,l)=>p.stats.createdAt-l.stats.createdAt,updated:(p,l)=>p.stats.publishedAt-l.stats.publishedAt},w=C(()=>b.value?.toSorted((p,l)=>u[n.value](p,l)*(t.value?1:-1))),y=T(""),d=C(()=>new te(b.value||[],{keys:["name","description","npm","category"],sortFn:(p,l)=>{const f=b.value?.[p.idx],h=b.value?.[l.idx];return f&&h?u[n.value](f,h)*(t.value?1:-1):p.score-l.score},threshold:.2})),c=C(()=>y.value?d.value.search(y.value).map(p=>p.item):w.value);return(p,l)=>{const f=pe,h=O,M=H,v=J,F=me,Q=We;return o(),m("div",Xe,[s(f,{mx6:"",mt6:"","text-xl":"",op75:"",icon:"i-carbon-intent-request-create",text:"Install Module"}),s(F,{search:y.value,"onUpdate:search":l[1]||(l[1]=I=>y.value=I),"no-padding":"","px-6":"","pb-5":"","pt-2":""},{actions:i(()=>[s(v,{direction:"end",n:"sm primary"},{trigger:i(({click:I})=>[e("div",Ze,[s(h,{icon:t.value?"tabler:sort-ascending":"tabler:sort-descending","h-full":"","rounded-r-none":"",onClick:l[0]||(l[0]=z=>t.value=!t.value)},null,8,["icon"]),s(h,{flex:"~ justify-between","min-w-30":"","border-l-0":"","rounded-l-none":"","px-2":"",capitalize:"",hover:"border-l-1",onClick:z=>I()},{default:i(()=>[x(k(n.value)+" ",1),s(M,{icon:"carbon:chevron-down"})]),_:2},1032,["onClick"])])]),default:i(()=>[e("div",Je,[(o(),m(B,null,D(r,I=>s(h,{key:I,border:!1,p2:"",hover:"n-checkbox-hover text-green",onClick:z=>n.value=I},{default:i(()=>[e("span",Qe,[x(k(I)+" ",1),n.value===I?(o(),$(M,{key:0,icon:"carbon:checkmark"})):g("",!0)])]),_:2},1032,["onClick"])),64))])]),_:1})]),_:1},8,["search"]),e("div",Re,[s(j(_e),{class:"scroller",items:c.value,"item-size":200,"key-field":"name"},{default:i(({item:I})=>[s(Q,{item:I,onStart:l[2]||(l[2]=z=>a("close"))},null,8,["item"])]),_:1},8,["items"])])])}}}),tt={flex:"~ col gap-2","w-150":"",p4:"",border:"t base"},ot={capitalize:""},nt={op50:""},st={flex:"~ gap-3",mt2:"","justify-end":""},lt=P({__name:"ModuleActionDialog",setup(N){const _=oe(),a=Y(),b={};return(r,t)=>{const n=U,u=fe,w=ve,y=ge,d=ne,c=O,p=se;return o(),$(j(W),null,{default:i(({resolve:l,args:f})=>[s(p,{"model-value":!0,onClose:h=>l(!1)},{default:i(()=>[s(n,{mod:b,info:f[0],border:"none","w-150":"","n-panel-grids":""},null,8,["info"]),e("div",tt,[e("h2",{"text-xl":"",class:L(f[2]==="install"?"text-primary":"text-red")},[e("span",ot,k(f[2]),1),t[1]||(t[1]=x()),e("code",null,k(f[0].name),1),t[2]||(t[2]=x("? "))],2),t[7]||(t[7]=e("p",{op50:""}," The following command will be executed in your terminal: ",-1)),s(u,{code:f[1].commands.join(" "),lang:"bash",px4:"",py2:"",border:"~ base rounded",lines:!1},null,8,["code"]),e("p",nt,[t[3]||(t[3]=x(" Then your ")),s(w,{role:"button",n:"primary",underline:"",onClick:t[0]||(t[0]=h=>j(a)(j(_)?._nuxtConfigFile)),textContent:"Nuxt config"}),t[4]||(t[4]=x(" will be updated as: "))]),s(y,{from:f[1].configOriginal,to:f[1].configGenerated,"max-h-80":"","of-auto":"",py2:"",border:"~ base rounded",lang:"ts"},null,8,["from","to"]),t[8]||(t[8]=e("p",null,[e("span",{op50:""},"After that, Nuxt will "),e("span",{"text-orange":""},"restart automatically"),x(". ")],-1)),e("div",st,[s(d,{n:"sm amber","flex-auto":"",icon:"i-carbon-data-backup"},{default:i(()=>t[5]||(t[5]=[x(" Please make sure to backup your project first. ")])),_:1}),s(c,{onClick:h=>l(!1)},{default:i(()=>t[6]||(t[6]=[x(" Cancel ")])),_:2},1032,["onClick"]),s(c,{n:"solid",capitalize:"",class:L(f[2]==="install"?"n-primary":"n-red"),onClick:h=>l(!0)},{default:i(()=>[x(k(f[2]),1)]),_:2},1032,["class","onClick"])])])]),_:2},1032,["onClose"])]),_:1})}}}),at={class:"markdown-body"},it={__name:"modules",setup(N,{expose:_}){return _({frontmatter:{}}),(b,r)=>(o(),m("div",at,r[0]||(r[0]=[e("h1",null,"Modules",-1),e("p",null,[x("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 "),e("code",null,"nuxt.config"),x(".")],-1),e("p",null,[x("You can explore the list of modules on "),e("a",{href:"https://nuxt.com/modules",target:"_blank",rel:"noopener"},"nuxt.com/modules"),x(" or install them directly inside the DevTools.")],-1),e("p",null,[e("a",{href:"https://nuxt.com/docs/guide/concepts/modules",target:"_blank",rel:"noopener"},"Learn more in the documentation")],-1)])))}},rt={"h-full":"","w-full":"","of-auto":""},ut={relative:"","h-20":"","w-20":"",flex:"","flex-none":"",rounded:"","bg-gray:3":"",p3:""},dt=["src","alt"],pt={"text-lg":"","group-hover":"text-primary",transition:"",flex:"~ gap-2 items-center"},mt={op75:""},ct={key:0,border:"l base",pos:"fixed bottom-0 right-0 top-0","z-200":"","w-150":"","bg-base":""},_t="https://api.nuxtjs.org/api/ipx/s_80,f_webp/gh/nuxt/modules/main/icons/",Tt=P({__name:"modules",setup(N){const _=T(!1),a=Z(),b=K(),r=C(()=>a.value.filter(n=>n.isPackageModule)),t=C(()=>a.value.filter(n=>!n.isPackageModule));return le(()=>[{id:"action:modules:install",title:"Install a new module",icon:"i-carbon-intent-request-create ",action:()=>{_.value=!0}}]),(n,u)=>{const w=Ke,y=G,d=S,c=de,p=O,l=et,f=lt,h=it,M=xe;return o(),m(B,null,[e("div",rt,[s(c,{icon:"carbon-3d-mpr-toggle",text:"Installed Modules","container-class":"grid grid-cols-minmax-400px gap3 px4",padding:!1,description:`Total modules: ${r.value.length}`},{default:i(()=>[(o(!0),m(B,null,D(r.value,v=>(o(),$(w,{key:v.name,mod:v},null,8,["mod"]))),128)),(o(!0),m(B,null,D("processInstallingModules"in n?n.processInstallingModules:j(X),v=>(o(),$(d,{key:v.processId,block:"","min-h-30":"",to:"/modules/terminals",onClick:F=>b.value=v.processId},{default:i(()=>[s(y,{border:"1.5 dashed","h-full":"","animate-pulse":"",p4:"",transition:"",hover:"border-primary",flex:"~ col gap-1 items-center justify-center",role:"button",class:"group"},{default:i(()=>[e("div",ut,[e("img",{src:_t+v.info.icon,alt:v.info.name,ma:""},null,8,dt),u[4]||(u[4]=e("div",{"i-carbon-cube":"",ma:"","text-4xl":"",op30:""},null,-1))]),e("div",pt,[u[5]||(u[5]=e("div",{"i-carbon-circle-dash":"","animate-spin":"","text-xl":"",op75:""},null,-1)),e("span",mt,"Installing "+k(v.name)+"...",1)])]),_:2},1024)]),_:2},1032,["onClick"]))),128)),s(y,{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:u[0]||(u[0]=v=>_.value=!0)},{default:i(()=>u[6]||(u[6]=[e("div",{"i-carbon-intent-request-create":"","text-4xl":"",op40:"","group-hover":"op75 text-primary",transition:""},null,-1),e("div",{"text-lg":"",op40:"","group-hover":"op75 text-primary",transition:""}," Install New Module ",-1)])),_:1})]),_:1},8,["description"]),t.value.length?(o(),$(c,{key:0,icon:"carbon-3d-mpr-toggle",text:"User Modules","container-class":"grid grid-cols-minmax-400px gap3 px4",padding:!1,description:`Total modules: ${t.value.length}`},{default:i(()=>[(o(!0),m(B,null,D(t.value,v=>(o(),m(B,{key:v.meta?.name||v.entryPath},[v.meta?.name||v.entryPath?(o(),$(w,{key:0,mod:v},null,8,["mod"])):g("",!0)],64))),128))]),_:1},8,["description"])):g("",!0),s(E,{name:"fade-in"},{default:i(()=>[_.value?(o(),m("div",{key:0,class:"fixed bottom-0 left-0 right-0 top-0 z-100","bg-black:20":"","backdrop-blur-2":"",onClick:u[1]||(u[1]=v=>_.value=!1)})):g("",!0)]),_:1}),s(E,{name:"slide-in"},{default:i(()=>[_.value?(o(),m("div",ct,[s(p,{icon:"carbon-close",pos:"absolute top-3 right-3 z-10","rounded-full":"","text-xl":"",border:!1,onClick:u[2]||(u[2]=v=>_.value=!1)}),s(l,{onClose:u[3]||(u[3]=v=>_.value=!1)})])):g("",!0)]),_:1}),s(f)]),s(M,null,{default:i(()=>[s(h)]),_:1})],64)}}});export{Tt as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as o}from"./hjpmj1xu.js";import{U as n,W as s,Y as t}from"./vendor/json-editor-vue-kcahofzr.js";const r={},c={class:"n-badge"};function _(e,a){return n(),s("span",c,[t(e.$slots,"default")])}const m=o(r,[["render",_]]);export{m as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{C as d,ab as p,_ as u}from"./hjpmj1xu.js";import{p as m,f as c,U as f,W as b,Y as n,a3 as v,a2 as _,a9 as k,u as a,X as C,a0 as V}from"./vendor/json-editor-vue-kcahofzr.js";const y=m({__name:"NDropdown",props:{modelValue:{type:Boolean},direction:{default:"start"}},setup(r,{emit:l}){const e=d(r,"modelValue",l,{passive:!0}),t=c();return p(t,()=>{e.value=!1}),(s,o)=>{const i=u;return f(),b("div",{ref_key:"el",ref:t,class:"relative"},[n(s.$slots,"trigger",{enabled:a(e),click:()=>e.value=!a(e)},()=>[v(i,{onClick:o[0]||(o[0]=g=>e.value=!a(e))},{default:_(()=>o[1]||(o[1]=[k(" Dropdown ")])),_:1})]),C("div",{class:V(["absolute z-10 border n-border-base rounded shadow n-transition n-bg-base",[a(e)?"op-100":"op0 pointer-events-none -translate-y-1",s.direction==="end"?"right-0":"left-0"]])},[n(s.$slots,"default")],2)],512)}}});export{y as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as o}from"./hjpmj1xu.js";import{U as t,W as r,Y as n}from"./vendor/json-editor-vue-kcahofzr.js";import"./vendor/unocss-mstcul8h.js";import"./vendor/shiki-ja073547.js";const s={},c={relative:"","w-full":""};function a(e,l){return t(),r("div",c,[n(e.$slots,"default")])}const d=o(s,[["render",a]]);export{d as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{f as M,K as P,a7 as z,an as O,ao as $,p as E,h as F,ap as g,aq as k,ar as K,a2 as q,i as G,m as H,j as U,e as W,A as X,_ as Z}from"./hjpmj1xu.js";import{u as J,_ as Q}from"./state-modules-h52b8di8.js";import{u as Y}from"./state-components-d4iulvg3.js";import{p as h,q as A,P as v,a2 as n,U as s,u as o,W as p,X as e,a3 as i,a8 as a,Z as u,F as f,a9 as l}from"./vendor/json-editor-vue-kcahofzr.js";import"./vendor/unocss-mstcul8h.js";import"./vendor/shiki-ja073547.js";import"./nbadge-pfavq5ao.js";import"./ncode-block.vue-dt6krs6h.js";import"./client-kpmlv67d.js";import"./ncheckbox.vue-gfdtqnpm.js";const c="2.0.0-beta.7",tt={key:0},et={key:1,flex:"~ col gap2",ma:"","h-full":"","max-w-300":"","w-full":"",p5:"",px5:"","md:px20":""},ot={flex:"~ col","mt-5":"","items-center":"","md:mt-20":""},nt={op40:""},st={flex:"~ gap2 wrap"},lt={key:5,"pointer-events-none":"","min-w-40":"",p4:"","theme-card-lime":"",flex:"~ auto gap-6"},it={grid:"~ cols-[auto_auto] gap-x-5 items-center"},ut={"text-right":""},rt={"text-right":""},at={"text-right":""},dt={"text-right":""},pt={flex:"~ col gap2"},mt={flex:"~ gap-6 wrap","mt-5":"","items-center":"","justify-center":""},xt={flex:"col gap-2",mxa:"",hidden:"","w-100":"","text-sm":"",op50:"","md:flex":""},vt={flex:"~ gap-1","items-center":""},ft={flex:"~ gap-1","items-center":""},jt=h({__name:"overview",setup(gt){const b=M(),m=P(),D=Y(),y=z(),j=J(),B=O(),w=$(),I=E();function V(){G.value=!0,I.push("/")}const S=A(()=>b.value?.nuxt.vueApp.version),r=A(()=>b.value?.metrics.loading());function L(){H()}return(_,t)=>{const R=U,x=W,C=Q,N=X,d=Z,T=F;return s(),v(T,{"h-screen":"","w-full":"",flex:""},{default:n(()=>[o(m)?(s(),p("div",et,[t[40]||(t[40]=e("div",{"flex-auto":""},null,-1)),e("div",ot,[i(x,{flex:"~","mt--10":"","items-center":"","justify-center":"",to:"https://devtools.nuxt.com/",target:"_blank"},{default:n(()=>[i(R,{"h-10":""})]),_:1}),e("button",{mb6:"",mt3:"","text-center":"","text-sm":"",flex:"~ gap-1 wrap",onClick:V},[t[0]||(t[0]=e("span",{op40:""}," Nuxt DevTools ",-1)),e("code",nt,"v"+a(o(c)),1),i(C,{"package-name":"@nuxt/devtools",options:{dev:!0},"show-version":!1})])]),e("div",st,[i(x,{to:"https://nuxt.com",target:"_blank",p4:"","theme-card-green":"",flex:"~ col auto"},{default:n(()=>[t[1]||(t[1]=e("div",{"logos-nuxt-icon":"","text-3xl":""},null,-1)),i(C,{"package-name":"nuxt",options:{dev:!0}})]),_:1}),S.value?(s(),v(x,{key:0,to:"https://vuejs.org",target:"_blank",p4:"","theme-card-green":"",flex:"~ col auto"},{default:n(()=>[t[2]||(t[2]=e("div",{"logos-vue":"","text-3xl":""},null,-1)),e("code",null,"v"+a(S.value),1)]),_:1})):u("",!0),o(m)?(s(),p(f,{key:1},[o(m)&&o(m).pages&&o(b)?(s(),v(x,{key:0,"min-w-40":"",p4:"","theme-card-lime":"",flex:"~ col auto",to:"/modules/pages"},{default:n(()=>[t[3]||(t[3]=e("div",{"carbon-tree-view-alt":"","text-3xl":""},null,-1)),e("div",null,a(o(g)(o(B).length,"page")),1)]),_:1})):u("",!0),o(m)?(s(),v(x,{key:1,"min-w-40":"",p4:"","theme-card-lime":"",flex:"~ col auto",to:"/modules/components"},{default:n(()=>[t[4]||(t[4]=e("div",{"i-carbon-assembly-cluster":"","text-3xl":""},null,-1)),e("div",null,a(o(g)(o(D).length,"component")),1)]),_:1})):u("",!0),o(m)&&o(y)?(s(),v(x,{key:2,"min-w-40":"",p4:"","theme-card-yellow":"",flex:"~ col auto",to:"/modules/imports"},{default:n(()=>[t[5]||(t[5]=e("div",{"carbon-function":"","text-3xl":""},null,-1)),e("div",null,a(o(g)(o(y).imports.length,"import")),1)]),_:1})):u("",!0),o(m)?(s(),v(x,{key:3,"min-w-40":"",p4:"","theme-card-purple":"",flex:"~ col auto",to:"/modules/modules"},{default:n(()=>[t[6]||(t[6]=e("div",{"carbon-3d-mpr-toggle":"","text-3xl":""},null,-1)),e("div",null,a(o(g)(o(j).length,"module")),1)]),_:1})):u("",!0),o(m)?(s(),v(x,{key:4,"min-w-40":"",p4:"","theme-card-teal":"",flex:"~ col auto",to:"/modules/plugins"},{default:n(()=>[t[7]||(t[7]=e("div",{"carbon-plug":"","text-3xl":""},null,-1)),e("div",null,a(o(g)(o(m).plugins.length,"plugin")),1)]),_:1})):u("",!0),r.value?(s(),p("div",lt,[t[12]||(t[12]=e("div",{"i-carbon-time-plot":"","flex-none":"","text-3xl":""},null,-1)),e("div",it,[r.value.ssrStart?(s(),p(f,{key:0},[t[8]||(t[8]=e("div",{"text-sm":""}," SSR to full load ",-1)),e("div",ut,a(o(k)(r.value.appLoad-r.value.ssrStart)),1)],64)):u("",!0),t[10]||(t[10]=e("div",{"text-sm":""}," Page load ",-1)),e("div",rt,a(o(k)(r.value.appLoad-r.value.appInit)),1),t[11]||(t[11]=e("div",{"text-sm":""}," Navigation ",-1)),e("div",at,a(o(k)(r.value.pageEnd-r.value.pageStart)),1),r.value.hmrStart?(s(),p(f,{key:1},[t[9]||(t[9]=e("div",{"text-sm":""}," HMR ",-1)),e("div",dt,a(o(k)(r.value.hmrEnd-r.value.hmrStart)),1)],64)):u("",!0)])])):u("",!0)],64)):u("",!0)]),e("div",pt,[o(K)?(s(),v(N,{key:0,n:"yellow5",icon:"carbon-unlink","justify-center":""},{default:n(()=>t[13]||(t[13]=[l(" Not connected to the client app, showing server-side data only. Use the embedded mode for full features. ")])),_:1})):u("",!0),e("button",{title:"Authorize",onClick:L},[("isDevAuthed"in _?_.isDevAuthed:o(q))?u("",!0):(s(),v(N,{key:0,n:"orange5",icon:"i-carbon-locked","justify-center":""},{default:n(()=>t[14]||(t[14]=[l(" Access from an untrusted browser, some features are limited. Click to authorize now. ")])),_:1}))])]),e("div",mt,[t[16]||(t[16]=e("a",{href:"https://github.com/nuxt/devtools",target:"_blank",flex:"~ gap1","items-center":"",op50:"",hover:"op100 text-blue",transition:""},[e("div",{"i-carbon-star":""}),l(" Star on GitHub ")],-1)),t[17]||(t[17]=e("a",{href:"https://github.com/nuxt/devtools/discussions/29",target:"_blank",flex:"~ gap1","items-center":"",op50:"",hover:"op100 text-yellow",transition:""},[e("div",{"i-carbon-data-enrichment":""}),l(" Ideas & Suggestions ")],-1)),t[18]||(t[18]=e("a",{href:"https://github.com/nuxt/devtools/discussions/31",target:"_blank",flex:"~ gap1","items-center":"",op50:"",hover:"op100 text-lime",transition:""},[e("div",{"i-carbon-plan":""}),l(" Project Roadmap ")],-1)),t[19]||(t[19]=e("a",{href:"https://github.com/nuxt/devtools/issues",target:"_blank",flex:"~ gap1","items-center":"",op50:"",hover:"op100 text-rose",transition:""},[e("div",{"i-carbon-debug":""}),l(" Bug Reports ")],-1)),i(x,{to:"/settings",flex:"~ gap1","inline-block":"","items-center":"",op50:"","hover:op80":""},{default:n(()=>t[15]||(t[15]=[e("div",{"i-carbon-settings-adjust":""},null,-1),l(" Settings ")])),_:1})]),t[41]||(t[41]=e("div",{"flex-auto":""},null,-1)),e("div",xt,[e("div",vt,[o(w)?(s(),p(f,{key:0},[i(d,{n:"xs",class:"px2"},{default:n(()=>t[20]||(t[20]=[l(" ⌘ Cmd ")])),_:1}),t[22]||(t[22]=e("span",null,"+",-1)),i(d,{n:"xs",class:"px2"},{default:n(()=>t[21]||(t[21]=[l(" K ")])),_:1})],64)):(s(),p(f,{key:1},[i(d,{n:"xs",class:"px2"},{default:n(()=>t[23]||(t[23]=[l(" Ctrl ")])),_:1}),t[25]||(t[25]=e("span",null,"+",-1)),i(d,{n:"xs",class:"px2"},{default:n(()=>t[24]||(t[24]=[l(" K ")])),_:1})],64)),t[26]||(t[26]=e("div",{"flex-auto":""},null,-1)),t[27]||(t[27]=l(" Open Command Palette "))]),e("div",ft,[o(w)?(s(),p(f,{key:0},[i(d,{n:"xs",class:"px2"},{default:n(()=>t[28]||(t[28]=[l(" ⇧ Shift ")])),_:1}),t[31]||(t[31]=e("span",null,"+",-1)),i(d,{n:"xs",class:"px2"},{default:n(()=>t[29]||(t[29]=[l(" ⌥ Option ")])),_:1}),t[32]||(t[32]=e("span",null,"+",-1)),i(d,{n:"xs",class:"px2"},{default:n(()=>t[30]||(t[30]=[l(" D ")])),_:1})],64)):(s(),p(f,{key:1},[i(d,{n:"xs",class:"px2"},{default:n(()=>t[33]||(t[33]=[l(" Shift ")])),_:1}),t[36]||(t[36]=e("span",null,"+",-1)),i(d,{n:"xs",class:"px2"},{default:n(()=>t[34]||(t[34]=[l(" Alt ")])),_:1}),t[37]||(t[37]=e("span",null,"+",-1)),i(d,{n:"xs",class:"px2"},{default:n(()=>t[35]||(t[35]=[l(" D ")])),_:1})],64)),t[38]||(t[38]=e("div",{"flex-auto":""},null,-1)),t[39]||(t[39]=e("div",null,"Toggle DevTools",-1))])])])):(s(),p("div",tt," Loading... "))]),_:1})}}});export{jt as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{az as r,aA as c}from"./hjpmj1xu.js";import{v as p}from"./index-o0lbgjvm.js";import{p as i,W as m,u as o,P as n,a2 as _,U as t,a9 as l}from"./vendor/json-editor-vue-kcahofzr.js";import"./vendor/unocss-mstcul8h.js";import"./vendor/shiki-ja073547.js";import"./vue-virtual-scroller.esm-ryb7s73q.js";const u={class:"h-full w-full"},h=i({__name:"pinia",setup(f){const{connected:a}=r();return(d,e)=>{const s=c;return t(),m("div",u,[o(a)?(t(),n(o(p),{key:0})):(t(),n(s,{key:1},{default:_(()=>e[0]||(e[0]=[l(" Connecting.... ")])),_:1}))])}}});export{h as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{az as m,f as d,L as c,aA as f}from"./hjpmj1xu.js";import{p as _}from"./index-o0lbgjvm.js";import{p as v,W as C,u as n,P as a,a2 as E,U as o,a9 as I}from"./vendor/json-editor-vue-kcahofzr.js";import"./vendor/unocss-mstcul8h.js";import"./vendor/shiki-ja073547.js";import"./vue-virtual-scroller.esm-ryb7s73q.js";const k={class:"h-full w-full"},N=v({__name:"render-tree",setup(x){const{connected:p}=m(),t=d(),l=c();function s(r){r?t.value.devtools.open():t.value.devtools.close()}return(r,e)=>{const i=f;return o(),C("div",k,[n(p)?(o(),a(n(_),{key:0,onOnInspectComponentStart:e[0]||(e[0]=u=>s(!1)),onOnInspectComponentEnd:e[1]||(e[1]=u=>s(!0)),onOpenInEditor:n(l)},null,8,["onOpenInEditor"])):(o(),a(i,{key:1},{default:E(()=>e[2]||(e[2]=[I(" Connecting.... ")])),_:1}))])}}});export{N as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{C,R as N,_ as O}from"./hjpmj1xu.js";import{_ as R}from"./data-schema-button.vue-chmssum7.js";import{p as $,m as g,z as j,j as z,ag as D,U as l,W as c,X as m,a0 as d,u as o,a8 as b,Z as p,Y as M,a5 as P,a6 as E,F as k,ab as J,a3 as A,P as h,a4 as F,ax as U,n as x}from"./vendor/json-editor-vue-kcahofzr.js";const T=["open"],W={flex:"~ gap2","select-none":"","items-center":"",px4:""},X={key:0,class:"bg-red:10 px5 py3 text-red"},H=$({__name:"StateEditor",props:{name:{},open:{type:Boolean},revision:{},state:{},readonly:{type:Boolean}},emits:["update:open"],setup(_,{emit:V}){const t=_,s=C(t,"open",V,{passive:!0}),B=N(),i=g(),u=g();function f(){u.value=void 0;try{t.state?i.value=JSON.parse(JSON.stringify(t.state||{})):(typeof t.state=="number"||typeof t.state!="string")&&(i.value=t.state)}catch(e){console.error(e),u.value=e}}j(()=>{f(),z(()=>[t.revision,t.state],e=>{typeof e!="number"&&typeof e!="string"?v(e,t.state):i.value=t.state},{deep:!0})});function v(e,r){const n=e[1];for(const a in n)Array.isArray(n[a])?r[a]=n[a].slice():typeof n[a]=="object"&&n[a]!==null?v(n[a],r[a]):r[a]=n[a]}async function S(){f(),await x()}return(e,r)=>{const n=O,a=R,w=D("tooltip");return l(),c("div",{class:"state-editor-details",open:e.name?o(s):!0},[m("div",W,[e.name?(l(),c("button",{key:0,flex:"~","cursor-pointer":"","items-center":"",class:d(o(s)?"":"op50"),onClick:r[0]||(r[0]=y=>s.value=!o(s))},[m("div",{"i-carbon-chevron-right":"",transition:"",class:d(o(s)?"rotate-90 op0":"")},null,2),m("code",{px3:"",py1:"","font-mono":"",class:d(o(s)?"bg-[#8881] rounded-t":"rounded hover:bg-active")},b(e.name),3)],2)):p("",!0),M(e.$slots,"actions",P(E({isOpen:o(s),name:e.name,state:e.state}))),o(s)?(l(),c(k,{key:1},[J(A(n,{title:"Refresh View",icon:"carbon-renew",border:!1,onClick:S},null,512),[[w,"Refresh View",void 0,{bottom:!0}]]),i.value&&!u.value?(l(),h(a,{key:0,getter:()=>({name:e.name,input:JSON.stringify(i.value)})},null,8,["getter"])):p("",!0)],64)):p("",!0)]),o(s)||!e.name?(l(),c(k,{key:0},[u.value?(l(),c("div",X," Error: "+b(u.value),1)):(l(),h(o(U),F({key:1,modelValue:i.value,"onUpdate:modelValue":r[1]||(r[1]=y=>i.value=y)},e.$attrs,{class:["json-editor-vue",[o(B)==="dark"?"jse-theme-dark":"",(e.name,"")]],"main-menu-bar":!1,"navigation-bar":!1,"status-bar":!1,"read-only":t.readonly,indentation:2,"tab-size":2}),null,16,["modelValue","class","read-only"]))],64)):p("",!0)],8,T)}}});export{H as _};
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import{a5 as V,M as O,D as j,bh as Y,b as U,R as q,a as K,_ as z,a7 as X,f as Z,bi as Q,K as ee,n as se,L as ne,h as te,r as G,G as oe,B as ae}from"./hjpmj1xu.js";import{_ as W}from"./duration-display.vue-dzttyi5n.js";import{p as B,q as w,U as o,W as i,X as t,$ as T,a8 as m,u as g,F as y,ae as E,P as h,f as C,j as le,n as re,Z as x,a3 as u,a0 as R,V as P,a2 as v,ax as ie,a4 as pe,a9 as F,aj as ce}from"./vendor/json-editor-vue-kcahofzr.js";import{_ as H}from"./nbadge-pfavq5ao.js";import{_ as de}from"./composable-item.vue-g0zoeh4b.js";import{_ as ue}from"./stacktrace-list.vue-f9r30ugc.js";import{_ as me}from"./ndrawer.vue-c5d7jii6.js";import{_ as ke}from"./launch-page.vue-6pn8vnpe.js";import{_ as fe}from"./nlink.vue-jqcqrruu.js";import{_ as ye}from"./code-diff.vue-l6vwnnx9.js";import{_ as he}from"./help-fab.vue-jkf9agm3.js";import"./vendor/unocss-mstcul8h.js";import"./vendor/shiki-ja073547.js";import"./nmarkdown.vue-jpbjhala.js";import"./client-kpmlv67d.js";import"./filepath-item.vue-bisii3l4.js";import"./constants-b32h69zq.js";import"./ncode-block.vue-dt6krs6h.js";const ve=B({__name:"TimelineItemFunction",props:{item:{}},setup(f){const d=f,p=w(()=>V(d.item.name,50,60,"_op_")),n=w(()=>p.value.replace(/_op_/,"1")),e=w(()=>V(d.item.name,50,40)),l=w(()=>p.value.replace(/_op_/,"0.2"));return(a,r)=>(o(),i("button",{class:"group",style:T({color:n.value,borderLeft:`2px solid ${n.value}`}),relative:"","text-sm":"",transition:"","hover:z-1000":"","bg-base":""},[t("div",{style:T({backgroundColor:l.value}),absolute:"","bottom-0":"","left--1px":"","top-0":"","w-full":"","text-sm":"","transition-all":"","duration-300":""},null,4),t("div",{style:T({color:e.value,"--c":n.value}),border:"r-2 t-2 y-2 transparent","min-w-max":"",px1:"","text-left":"","group-hover":"border-$c"},m(a.item.name),5)],4))}}),_e={relative:"","h-full":""},be={absolute:"","left-2":"","top-2.3em":"","text-xs":"",op50:""},ge=B({__name:"TimelineSegment",props:{segment:{}},emits:["select"],setup(f,{emit:d}){const p=f,n=d,e=O(()=>p.segment.start,{updateInterval:1e3,showSecond:!0,controls:!1,messages:{justNow:"",past:l=>l,future:l=>l,invalid:"-",second:l=>l?`${l}s`:"",minute:l=>`${l}m`,hour:l=>`${l}h`,week:l=>`${l}w`,day:l=>`${l}d`,month:l=>`${l}mo`,year:l=>`${l}y`}});return(l,a)=>{const r=ve;return o(),i("div",_e,[t("button",{absolute:"","left-0":"","right-0":"","top-0":"","bg-green:5":"",px2:"",py1:"","text-left":"","text-xs":"","text-green6":"","font-mono":"",onClick:a[0]||(a[0]=s=>l.segment.route?n("select",l.segment.route):void 0)},m(l.segment.route?.event.to),1),t("div",be,m(g(e))+" ago ",1),t("div",null,[(o(!0),i(y,null,E(l.segment.functions,(s,c)=>(o(),h(r,{key:c,item:s.event,style:T({position:"absolute",minWidth:`${s.relativeWidth*100}%`,maxWidth:`${s.relativeWidth*100}%`,top:`${4+s.layer*1.6}em`,left:`${s.relativeStart*100}%`}),onClick:k=>n("select",s)},null,8,["item","style","onClick"]))),128))])])}}}),xe=3e3,De=50;function Ae(f){const d=[];let p={start:0,end:0,events:[],functions:[],duration:0};for(const n of f){const e=n.end||n.start;(n.start-p.end>xe||n.type==="route")&&(p={start:n.start,end:e,events:[],functions:[],duration:0},d.push(p)),p.events.push(n),p.end=e+De}return d.forEach((n,e)=>{const l=n.end-n.start,a=[];n.duration=l,n.previousGap=e>0?n.start-d[e-1].end:0,n.events.forEach(r=>{const s=r.end||r.start;let c=0;r.type!=="route"&&(c=a.findIndex(D=>D<=r.start),c===-1?(c=a.length,a.push(s+1e3)):a[c]=s+1e3);const k={event:r,segment:n,relativeStart:(r.start-n.start)/l,relativeWidth:(s-r.start)/l,layer:c};r.type==="function"?n.functions.push(k):n.route=k})}),d}const $e={relative:""},Ce={key:0,border:"x base","h-full":"","flex-inline":"","bg-true-gray-1":"",py15:"","text-xs":"","write-vertical-left":"",op50:"","dark:bg-true-gray-9":""},Be=B({__name:"TimelineTable",props:{data:{}},emits:["select"],setup(f,{emit:d}){const p=f,n=d,e=C(),l=C(),a=C(),r=C(),s=C(!0),c=C(1.5),k=w(()=>Ae(p.data.events)),D=w(()=>(p.data.events.length,e.value?.scrollWidth||window.innerWidth));function A(){r.value&&(r.value.style.width=`${D.value}px`)}function S(){s.value&&e.value&&(e.value.scrollTo({left:e.value.scrollWidth-e.value.clientWidth,behavior:"smooth"}),a.value.scrollTo({left:e.value.scrollWidth-e.value.clientWidth,behavior:"smooth"}))}return le(()=>p.data.events.length,async()=>{await re(),A(),S()},{flush:"post"}),j(e,"scroll",()=>{a.value.scrollLeft!==e.value.scrollLeft&&(A(),a.value.scrollLeft=e.value.scrollLeft,s.value=e.value.scrollLeft>=e.value.scrollWidth-e.value.clientWidth)}),j(a,"scroll",()=>{a.value.scrollLeft!==e.value.scrollLeft&&(A(),e.value.scrollLeft=a.value.scrollLeft)}),j(e,"wheel",_=>{_.altKey?(c.value=Y(c.value+_.deltaY/200,.5,3),A()):e.value.scrollLeft+=_.deltaY}),(_,L)=>{const $=W,M=ge;return o(),i(y,null,[t("div",$e,[t("div",{ref_key:"minimap",ref:l,border:"t b base",relative:"","h-50px":"","ws-nowrap":"","border-base":""},[(o(!0),i(y,null,E(k.value,(b,N)=>(o(),i("div",{key:N,relative:"","h-full":"","flex-inline":"",style:T({width:`${Math.max(100,b.duration/10)/D.value*100}%`})},[(o(!0),i(y,null,E(b.functions,(I,J)=>(o(),i("div",{key:J,"h-3px":"",rounded:"",style:T({width:`max(${I.relativeWidth*100}%, 10px)`,position:"absolute",top:`${I.layer*4}px`,left:`${I.relativeStart*100}%`,backgroundColor:("getHashColorFromString"in _?_.getHashColorFromString:g(V))(I.event.name,50,60)})},null,4))),128)),b.route?(o(),i("div",{key:0,absolute:"","top-0":"","h-full":"","w-px":"","border-l":"","border-green6":"",op10:"",style:T({left:`${b.route.relativeStart*100}%`})},null,4)):x("",!0)],4))),128))],512),t("div",{ref_key:"minimapScroller",ref:a,class:"timeline-scroller",absolute:"","inset-0":"","h-full":"","w-full":"","of-x-scroll":""},[t("div",{ref_key:"minimapScrollerInner",ref:r,"h-1px":""},null,512)],512)]),t("div",{ref_key:"scroller",ref:e,relative:"","h-full":"","w-full":"","of-x-scroll":"","of-y-hidden":"","ws-nowrap":"","n-panel-grids":""},[(o(!0),i(y,null,E(k.value,(b,N)=>(o(),i(y,{key:N},[b.previousGap&&b.previousGap>=200?(o(),i("div",Ce,[u($,{op50:"",duration:b.previousGap,color:!1},null,8,["duration"])])):x("",!0),u(M,{"flex-inline":"","of-x-hidden":"","hover:of-x-visible":"","bg-base":"",class:R(N===k.value.length-1?"border-r border-base":""),segment:b,style:T({width:`${Math.max(50,b.duration/10)*c.value}px`}),onSelect:L[0]||(L[0]=I=>n("select",I))},null,8,["class","segment","style"])],64))),128))],512)],64)}}}),we=U(Be,[["__scopeId","data-v-18afc15e"]]),Te={border:"t base",flex:"~ col","h-full":"","of-y-auto":"","text-sm":""},Se=["onClick"],Ne={flex:"~","ml--1":"","font-mono":""},Fe={key:0,mr2:"",op30:""},Ee={op75:""},Le={flex:"~ col items-start"},Ie={"text-xs":"","font-mono":"",op30:""},Me={"text-green":"","font-bold":"","font-mono":""},Ve=B({__name:"TimelineList",props:{data:{}},emits:["select"],setup(f,{emit:d}){const p=d;return(n,e)=>{const l=W;return o(),i("div",Te,[(o(!0),i(y,null,E(n.data.events,(a,r)=>(o(),i("button",{key:r,border:"b base",px3:"",py2:"",flex:"~ items-center gap-2",hover:"bg-active",onClick:s=>p("select",a)},[a.type==="function"?(o(),i(y,{key:0},[e[2]||(e[2]=t("div",{"i-carbon-function":"",op50:""},null,-1)),t("div",{"font-mono":"",style:T({color:a.type==="function"?("getHashColorFromString"in n?n.getHashColorFromString:g(V))(a.name,50,60):""})},m(a.name),5),t("div",Ne,[e[0]||(e[0]=t("div",{op30:""}," ( ",-1)),(o(!0),i(y,null,E(a.args,(s,c)=>(o(),i(y,{key:c},[c?(o(),i("div",Fe," , ")):x("",!0),t("div",Ee,m(s===null?"null":s===void 0?"undefined":typeof s=="function"?"[function]":Array.isArray(s)?"[Array]":typeof s=="object"?"[object]":JSON.stringify(s)),1)],64))),128)),e[1]||(e[1]=t("div",{op30:""}," ) ",-1))])],64)):(o(),i(y,{key:1},[e[3]||(e[3]=t("div",{"mr-1":"","h-7":"","w-7":"",flex:"","rounded-lg":"","bg-primary:5":"",p1:"","text-green6":""},[t("div",{"i-carbon-direction-rotary-right":"",ma:"","text-lg":""})],-1)),t("div",Le,[t("div",Ie,m(a.from),1),t("div",Me,m(a.to),1)])],64)),e[4]||(e[4]=t("div",{"flex-auto":""},null,-1)),a.end?(o(),h(l,{key:2,duration:a.end-a.start,color:a.type==="function"},null,8,["duration","color"])):x("",!0)],8,Se))),128)),e[5]||(e[5]=t("div",{"min-h-100":""},null,-1))])}}}),We={key:0,"text-blue":""},je={key:1,"text-purple":""},Oe={key:2,"text-green":""},ze={key:3,"text-gray":""},Re={key:4,"text-gray":""},Ge={key:5,"text-gray":""},Pe={key:0,"bg-red:10":"",px2:"",py1:"","text-red":""},He={key:1},Je={p2:"","text-sm":"",border:"t base"},Ye=B({__name:"TimelineArgumentView",props:{value:{}},setup(f){const d=f,p=C(),n=C();function e(){try{p.value=JSON.parse(JSON.stringify(d.value))}catch(s){console.error(s),n.value=s}}const l=B({emits:["setup"],setup(s,{emit:c}){return c("setup"),()=>null}}),a=q(),r=K();return(s,c)=>{const k=z,D=P("VMenu");return typeof s.value=="string"?(o(),i("div",We,m(JSON.stringify(s.value)),1)):typeof s.value=="number"?(o(),i("div",je,m(s.value),1)):typeof s.value=="boolean"?(o(),i("div",Oe,m(s.value),1)):typeof s.value>"u"?(o(),i("div",ze," undefined ")):typeof s.value=="function"?(o(),i("div",Re," [Function"+m(s.value.name?`: ${s.value.name}`:"")+"] ",1)):s.value===null?(o(),i("div",Ge," null ")):(o(),h(D,{key:6,placement:"top"},{popper:v(()=>[u(g(l),{onSetup:e}),n.value?(o(),i("div",Pe," Failed to display object: "+m(n.value),1)):p.value?(o(),i("div",He,[u(g(ie),pe({"model-value":p.value},s.$attrs,{class:["json-editor-vue",[g(a)==="dark"?"jse-theme-dark":""]],"main-menu-bar":!1,"navigation-bar":!1,"status-bar":!1,"read-only":!0,indentation:2,"tab-size":2}),null,16,["model-value","class"]),t("div",Je,[u(k,{title:"Copy to clipboard",icon:"carbon-copy",onClick:c[0]||(c[0]=A=>g(r)(JSON.stringify(p.value,null,2),"timeline-argument"))},{default:v(()=>c[1]||(c[1]=[F(" Copy ")])),_:1})])])):x("",!0)]),default:v(()=>[t("span",{"rounded-sm":"",px1:"","py0.5":"","text-sm":"",class:R([Array.isArray(s.value)?"text-amber bg-amber:10":"text-orange bg-orange:10"])},m(Array.isArray(s.value)?`[Array(${s.value.length})]`:"[Object]"),3)]),_:1}))}}}),Ue={key:0,"p-4":"",flex:"~ col gap-2","text-base":""},qe={"mx--1":""},Ke={flex:"~ gap-1","font-mono":""},Xe={key:1},Ze={key:0,op30:""},Qe={flex:"~ gap-1","text-sm":""},es={class:"text-sm text-gray-400"},ss=B({__name:"TimelineDetailsFunction",props:{record:{}},setup(f){const d=f,p=O(()=>d.record.start,{showSecond:!0}),n=X(),e=w(()=>n.value?.metadata),l=w(()=>n.value?.imports.find(a=>a.as===d.record.name));return(a,r)=>{const s=H,c=de,k=Ye,D=W,A=ue;return a.record?(o(),i("div",Ue,[t("div",qe,[u(s,{n:"yellow",textContent:"Function call"})]),t("div",Ke,[l.value?(o(),h(c,{key:0,item:l.value,metadata:e.value,counter:!1,classes:"px2 py1","mx--2":""},null,8,["item","metadata"])):(o(),i("span",Xe,m(a.record.name),1)),r[0]||(r[0]=t("span",{ml1:"",op30:""},"(",-1)),(o(!0),i(y,null,E(a.record.args,(S,_)=>(o(),i(y,{key:_},[_?(o(),i("span",Ze,", ")):x("",!0),u(k,{value:S},null,8,["value"])],64))),128)),r[1]||(r[1]=t("span",{op30:""},")",-1))]),t("div",Qe,[a.record.end?(o(),h(D,{key:0,duration:a.record.end-a.record.start},null,8,["duration"])):x("",!0),r[2]||(r[2]=t("span",{mx1:"",op50:""},"·",-1)),t("div",es,m(g(p)),1)]),a.record.stacktrace?(o(),h(A,{key:0,stacktrace:a.record.stacktrace,class:"text-xs text-gray-400"},null,8,["stacktrace"])):x("",!0)])):x("",!0)}}}),ns={key:0,"p-4":"",flex:"~ col gap-2"},ts={"mx--1":""},os={flex:"~ gap-1 items-center","font-mono":""},as={op50:""},ls={flex:"~ gap-1","text-sm":""},rs={class:"text-sm text-gray-400"},is=B({__name:"TimelineDetailsRoute",props:{record:{}},setup(f){const d=f,p=O(()=>d.record.start,{showSecond:!0});return(n,e)=>{const l=H,a=W;return n.record?(o(),i("div",ns,[t("div",ts,[u(l,{n:"green",textContent:"Route Change"})]),t("div",os,[t("span",as,m(n.record.from),1),e[0]||(e[0]=t("span",{"i-carbon-arrow-right":"",op50:""},null,-1)),t("span",null,m(n.record.to),1)]),t("div",ls,[n.record.end?(o(),h(a,{key:0,duration:n.record.end-n.record.start},null,8,["duration"])):x("",!0),e[1]||(e[1]=t("span",{mx1:"",op50:""},"·",-1)),t("div",rs,m(g(p)),1)])])):x("",!0)}}}),ps={key:0,"h-screen":"","of-hidden":""},cs={"h-screen":"","w-full":"",flex:"","flex-col":""},ds={"h-10":"",flex:"~ gap-2 items-center justify-end",p2:"",px3:""},us={"text-sm":""},ms={"min-h-50":"",px3:"",py2:""},ks=B({__name:"TimelineView",setup(f){const d=Z(),p=C("table"),n=C(),e=w(()=>d.value?.metrics.clientTimeline());function l(){e.value&&(e.value.events=[])}function a(){p.value=p.value==="table"?"list":"table"}return(r,s)=>{const c=P("VTooltip"),k=z,D=we,A=Ve,S=ss,_=is,L=me;return e.value?(o(),i("div",ps,[t("div",cs,[t("div",ds,[u(c,{flex:""},{popper:v(()=>[t("div",us,m(e.value.options.enabled?"Recording...":"Paused"),1)]),default:v(()=>[t("div",{"text-lg":"",class:R(e.value.options.enabled?"i-carbon-radio-button-checked text-primary animate-pulse":"i-carbon-pause-outline op30")},null,2)]),_:1}),e.value.options.enabled?(o(),h(k,{key:1,size:"small",ml1:"","text-sm":"",n:"orange",icon:"i-carbon-stop",onClick:s[1]||(s[1]=$=>e.value.options.enabled=!1)},{default:v(()=>s[6]||(s[6]=[F(" Stop Tracking ")])),_:1})):(o(),h(k,{key:0,size:"small",ml1:"","text-sm":"",n:"primary",icon:"i-carbon-play",onClick:s[0]||(s[0]=$=>e.value.options.enabled=!0)},{default:v(()=>s[5]||(s[5]=[F(" Start Tracking ")])),_:1})),s[7]||(s[7]=t("div",{"flex-auto":""},null,-1)),u(k,{icon:p.value==="table"?"i-carbon-roadmap":"i-carbon-list",class:"ml-2",title:"Toggle View",border:!1,onClick:a},null,8,["icon"]),u(k,{icon:"i-carbon-trash-can","hover-text-red":"",class:"ml-2",border:!1,onClick:l})]),p.value==="table"?(o(),h(D,{key:0,data:{...e.value},onSelect:s[2]||(s[2]=$=>n.value=$.event)},null,8,["data"])):(o(),h(A,{key:1,data:{...e.value},onSelect:s[3]||(s[3]=$=>n.value=$)},null,8,["data"]))]),u(L,{"model-value":!!n.value,"auto-close":"",transition:"bottom",left:"#nuxt-devtools-side-nav",onClose:s[4]||(s[4]=$=>n.value=void 0)},{default:v(()=>[t("div",ms,[n.value?.type==="function"?(o(),h(S,{key:0,record:n.value},null,8,["record"])):n.value?.type==="route"?(o(),h(_,{key:1,record:n.value},null,8,["record"])):x("",!0)])]),_:1},8,["model-value"])])):x("",!0)}}}),fs={class:"markdown-body"},ys={__name:"timeline",setup(f,{expose:d}){return d({frontmatter:{}}),(n,e)=>(o(),i("div",fs,e[0]||(e[0]=[t("h1",null,"Timeline",-1),t("blockquote",{"text-orange":"","bg-orange:10":"",py1:""}," This is an experimental feature ",-1),ce(`<p>Timeline tracks your route navigations and functions calls in your Nuxt application. It can be used to debug performance issues and to understand how your application works.</p><h2>Function calls</h2><p>Nuxt DevTools tracks function calls by wrapping them in the build time. It works for functions referenced by auto-imports, or explicit imports through <code>import {} from '#imports'</code>.</p><pre class="shiki shiki-themes vitesse-light vitesse-dark" style="background-color:#ffffff;--shiki-dark-bg:#121212;color:#393a34;--shiki-dark:#dbd7caee;" tabindex="0"><code><span class="line"><span style="color:#999999;--shiki-dark:#666666;"><</span><span style="color:#1E754F;--shiki-dark:#4D9375;">script</span><span style="color:#B07D48;--shiki-dark:#BD976A;"> setup</span><span style="color:#999999;--shiki-dark:#666666;">></span></span>
|
|
2
|
-
<span class="line"><span style="color:#1E754F;--shiki-dark:#4D9375;">import</span><span style="color:#999999;--shiki-dark:#666666;"> {</span><span style="color:#B07D48;--shiki-dark:#BD976A;"> useRoute</span><span style="color:#999999;--shiki-dark:#666666;"> }</span><span style="color:#1E754F;--shiki-dark:#4D9375;"> from</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;"> '</span><span style="color:#B56959;--shiki-dark:#C98A7D;">#app/composables/router</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;">'</span></span>
|
|
3
|
-
<span class="line"><span style="color:#1E754F;--shiki-dark:#4D9375;">import</span><span style="color:#999999;--shiki-dark:#666666;"> {</span><span style="color:#B07D48;--shiki-dark:#BD976A;"> useNuxtApp</span><span style="color:#999999;--shiki-dark:#666666;"> }</span><span style="color:#1E754F;--shiki-dark:#4D9375;"> from</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;"> '</span><span style="color:#B56959;--shiki-dark:#C98A7D;">#imports</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;">'</span></span>
|
|
4
|
-
<span class="line"><span style="color:#1E754F;--shiki-dark:#4D9375;">import</span><span style="color:#999999;--shiki-dark:#666666;"> {</span><span style="color:#B07D48;--shiki-dark:#BD976A;"> useMouse</span><span style="color:#999999;--shiki-dark:#666666;"> }</span><span style="color:#1E754F;--shiki-dark:#4D9375;"> from</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;"> '</span><span style="color:#B56959;--shiki-dark:#C98A7D;">@vueuse/core</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;">'</span></span>
|
|
5
|
-
<span class="line"></span>
|
|
6
|
-
<span class="line"><span style="color:#AB5959;--shiki-dark:#CB7676;">const</span><span style="color:#B07D48;--shiki-dark:#BD976A;"> route</span><span style="color:#999999;--shiki-dark:#666666;"> =</span><span style="color:#59873A;--shiki-dark:#80A665;"> useRoute</span><span style="color:#999999;--shiki-dark:#666666;">()</span><span style="color:#A0ADA0;--shiki-dark:#758575DD;"> // tracked</span></span>
|
|
7
|
-
<span class="line"><span style="color:#AB5959;--shiki-dark:#CB7676;">const</span><span style="color:#B07D48;--shiki-dark:#BD976A;"> app</span><span style="color:#999999;--shiki-dark:#666666;"> =</span><span style="color:#59873A;--shiki-dark:#80A665;"> useNuxtApp</span><span style="color:#999999;--shiki-dark:#666666;">()</span><span style="color:#A0ADA0;--shiki-dark:#758575DD;"> // tracked</span></span>
|
|
8
|
-
<span class="line"></span>
|
|
9
|
-
<span class="line"><span style="color:#A0ADA0;--shiki-dark:#758575DD;">// NOT tracked because it's directly imported</span></span>
|
|
10
|
-
<span class="line"><span style="color:#AB5959;--shiki-dark:#CB7676;">const</span><span style="color:#B07D48;--shiki-dark:#BD976A;"> mouse</span><span style="color:#999999;--shiki-dark:#666666;"> =</span><span style="color:#59873A;--shiki-dark:#80A665;"> useMouse</span><span style="color:#999999;--shiki-dark:#666666;">()</span></span>
|
|
11
|
-
<span class="line"><span style="color:#999999;--shiki-dark:#666666;"></</span><span style="color:#1E754F;--shiki-dark:#4D9375;">script</span><span style="color:#999999;--shiki-dark:#666666;">></span></span>
|
|
12
|
-
<span class="line"></span></code></pre><p>By default, it tracks Nuxt provided composables as well as user defined functions. You can include/exclude functions by using the <code>include</code> and <code>exclude</code> options in the <code>nuxt.config.js</code> file.</p><pre class="shiki shiki-themes vitesse-light vitesse-dark" style="background-color:#ffffff;--shiki-dark-bg:#121212;color:#393a34;--shiki-dark:#dbd7caee;" tabindex="0"><code><span class="line"><span style="color:#1E754F;--shiki-dark:#4D9375;">export</span><span style="color:#1E754F;--shiki-dark:#4D9375;"> default</span><span style="color:#59873A;--shiki-dark:#80A665;"> defineNuxtConfig</span><span style="color:#999999;--shiki-dark:#666666;">({</span></span>
|
|
13
|
-
<span class="line"><span style="color:#998418;--shiki-dark:#B8A965;"> devtools</span><span style="color:#999999;--shiki-dark:#666666;">:</span><span style="color:#999999;--shiki-dark:#666666;"> {</span></span>
|
|
14
|
-
<span class="line"><span style="color:#998418;--shiki-dark:#B8A965;"> timeline</span><span style="color:#999999;--shiki-dark:#666666;">:</span><span style="color:#999999;--shiki-dark:#666666;"> {</span></span>
|
|
15
|
-
<span class="line"><span style="color:#998418;--shiki-dark:#B8A965;"> functions</span><span style="color:#999999;--shiki-dark:#666666;">:</span><span style="color:#999999;--shiki-dark:#666666;"> {</span></span>
|
|
16
|
-
<span class="line"><span style="color:#998418;--shiki-dark:#B8A965;"> include</span><span style="color:#999999;--shiki-dark:#666666;">:</span><span style="color:#999999;--shiki-dark:#666666;"> [</span></span>
|
|
17
|
-
<span class="line"><span style="color:#A0ADA0;--shiki-dark:#758575DD;"> // track \`useMouse\`</span></span>
|
|
18
|
-
<span class="line"><span style="color:#B5695977;--shiki-dark:#C98A7D77;"> '</span><span style="color:#B56959;--shiki-dark:#C98A7D;">useMouse</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;">'</span><span style="color:#999999;--shiki-dark:#666666;">,</span></span>
|
|
19
|
-
<span class="line"><span style="color:#A0ADA0;--shiki-dark:#758575DD;"> // track all functions starting with \`use\`</span></span>
|
|
20
|
-
<span class="line"><span style="color:#B5695977;--shiki-dark:#C98A7D77;"> /</span><span style="color:#1E754F;--shiki-dark:#4D9375;">^</span><span style="color:#AB5E3F;--shiki-dark:#C4704F;">use</span><span style="color:#999999;--shiki-dark:#666666;">[</span><span style="color:#A65E2B;--shiki-dark:#C99076;">A-Z</span><span style="color:#999999;--shiki-dark:#666666;">]</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;">/</span><span style="color:#999999;--shiki-dark:#666666;">,</span></span>
|
|
21
|
-
<span class="line"><span style="color:#A0ADA0;--shiki-dark:#758575DD;"> // track all functions from @vueuse/core</span></span>
|
|
22
|
-
<span class="line"><span style="color:#B07D48;--shiki-dark:#BD976A;"> entry</span><span style="color:#999999;--shiki-dark:#666666;"> =></span><span style="color:#B07D48;--shiki-dark:#BD976A;"> entry</span><span style="color:#999999;--shiki-dark:#666666;">.</span><span style="color:#B07D48;--shiki-dark:#BD976A;">from</span><span style="color:#AB5959;--shiki-dark:#CB7676;"> ===</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;"> '</span><span style="color:#B56959;--shiki-dark:#C98A7D;">@vueuse/core</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;">'</span><span style="color:#999999;--shiki-dark:#666666;">,</span></span>
|
|
23
|
-
<span class="line"><span style="color:#999999;--shiki-dark:#666666;"> ],</span></span>
|
|
24
|
-
<span class="line"><span style="color:#998418;--shiki-dark:#B8A965;"> exclude</span><span style="color:#999999;--shiki-dark:#666666;">:</span><span style="color:#999999;--shiki-dark:#666666;"> [</span></span>
|
|
25
|
-
<span class="line"><span style="color:#B5695977;--shiki-dark:#C98A7D77;"> '</span><span style="color:#B56959;--shiki-dark:#C98A7D;">useRouter</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;">'</span></span>
|
|
26
|
-
<span class="line"><span style="color:#999999;--shiki-dark:#666666;"> ]</span></span>
|
|
27
|
-
<span class="line"><span style="color:#999999;--shiki-dark:#666666;"> }</span></span>
|
|
28
|
-
<span class="line"><span style="color:#999999;--shiki-dark:#666666;"> }</span></span>
|
|
29
|
-
<span class="line"><span style="color:#999999;--shiki-dark:#666666;"> }</span></span>
|
|
30
|
-
<span class="line"><span style="color:#999999;--shiki-dark:#666666;">})</span></span>
|
|
31
|
-
<span class="line"></span></code></pre>`,6)])))}},hs={flex:"~ col gap-2","w-150":"",p4:"",border:"t base"},vs={op50:""},_s={flex:"~ gap-3",mt2:"","justify-end":""},Ws=B({__name:"timeline",setup(f){const d=Q(),p=ee(),n=se(),e=ne();async function l(){try{const[a,r]=await G.enableTimeline(!0);if(!await n.start(a,r))return;await G.enableTimeline(!1)}catch{oe({message:"Failed to enable timeline automatically. Check the terminal for more details.",icon:"i-carbon-warning",classes:"text-red"})}}return(a,r)=>{const s=ks,c=ke,k=te,D=fe,A=ye,S=z,_=ae,L=ys,$=he;return o(),i(y,null,[g(d)?.timeline?.enabled?(o(),h(s,{key:0})):(o(),i(y,{key:1},[u(k,null,{default:v(()=>[u(c,{icon:"i-carbon-roadmap",name:"feature-timeline",title:"Timeline",description:"Timeline enables the inspection of when composable being executed and the route changes.",actions:[{label:"Enable"}],onAction:l})]),_:1}),u(g(n),null,{default:v(({resolve:M,args:b})=>[u(_,{"model-value":!0,onClose:N=>M(!1)},{default:v(()=>[t("div",hs,[r[5]||(r[5]=t("h2",{"text-xl":""},[t("span",{capitalize:""},"Enable Timeline?")],-1)),t("p",vs,[r[1]||(r[1]=F(" Your ")),u(D,{role:"button",n:"primary",underline:"",onClick:r[0]||(r[0]=N=>g(e)(g(p)?._nuxtConfigFile)),textContent:"Nuxt config"}),r[2]||(r[2]=F(" will be updated as: "))]),u(A,{from:b[0],to:b[1],"max-h-80":"","of-auto":"",py2:"",border:"~ base rounded",lang:"ts"},null,8,["from","to"]),r[6]||(r[6]=t("p",null,[t("span",{op50:""},"Then Nuxt will "),t("span",{"text-orange":""},"restart automatically"),F(". ")],-1)),t("div",_s,[u(S,{onClick:N=>M(!1)},{default:v(()=>r[3]||(r[3]=[F(" Cancel ")])),_:2},1032,["onClick"]),u(S,{n:"solid primary",capitalize:"",onClick:N=>M(!0)},{default:v(()=>r[4]||(r[4]=[F(" Enable ")])),_:2},1032,["onClick"])])])]),_:2},1032,["onClose"])]),_:1})],64)),u($,null,{default:v(()=>[u(L)]),_:1})],64)}}});export{Ws as default};
|