@nuxt/devtools 0.5.4 → 0.6.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 +134 -29
- package/dist/chunks/vscode.mjs +5 -2
- package/dist/client/200.html +2 -2
- package/dist/client/404.html +2 -2
- package/dist/client/__blank/index.html +7 -0
- package/dist/client/_nuxt/{Badge.ade65c69.js → Badge.bb04dbdf.js} +1 -1
- package/dist/client/_nuxt/CodeSnippets.vue.b3f0f3dc.js +1 -0
- package/dist/client/_nuxt/DrawerRight.vue.48c2c3d6.js +1 -0
- package/dist/client/_nuxt/DurationDisplay.vue.1f2b63ce.js +1 -0
- package/dist/client/_nuxt/FilepathItem.vue.67a3bac2.js +1 -0
- package/dist/client/_nuxt/{HelpFab.vue.1ab4e4f1.js → HelpFab.vue.e0c5b3b9.js} +1 -1
- package/dist/client/_nuxt/LaunchPage.vue.a3f71c42.js +1 -0
- package/dist/client/_nuxt/NCheckbox.vue.56878d59.js +1 -0
- package/dist/client/_nuxt/NCodeBlock.vue.2f00c5a7.js +2 -0
- package/dist/client/_nuxt/NIconButton.vue.afd698ce.js +1 -0
- package/dist/client/_nuxt/NIconTitle.vue.025b1812.js +1 -0
- package/dist/client/_nuxt/NLink.vue.efbf2660.js +1 -0
- package/dist/client/_nuxt/NMarkdown.vue.4a55718e.js +1 -0
- package/dist/client/_nuxt/{NPanelGrids.24e40025.js → NPanelGrids.e209861e.js} +1 -1
- package/dist/client/_nuxt/NSectionBlock.012f83f1.css +1 -0
- package/dist/client/_nuxt/NSectionBlock.a9d6a8bd.js +1 -0
- package/dist/client/_nuxt/NSelect.vue.0258c4d8.js +1 -0
- package/dist/client/_nuxt/NSwitch.vue.774134ee.js +1 -0
- package/dist/client/_nuxt/NTip.vue.b7996913.js +1 -0
- package/dist/client/_nuxt/{Navbar.vue.12ff05d9.js → Navbar.vue.97a344a8.js} +1 -1
- package/dist/client/_nuxt/NpmVersionCheck.vue.5857e84f.js +1 -0
- package/dist/client/_nuxt/{PanelLeftRight.vue.0d3c5a22.js → PanelLeftRight.vue.4252eb45.js} +1 -1
- package/dist/client/_nuxt/StateEditor.vue.a6af1a3f.js +1 -0
- package/dist/client/_nuxt/__blank.f74f0354.js +1 -0
- package/dist/client/_nuxt/analyze-build.d8530c6c.js +1 -0
- package/dist/client/_nuxt/assets.e5e05d1f.js +16 -0
- package/dist/client/_nuxt/{client.d93a636c.js → client.c658398a.js} +1 -1
- package/dist/client/_nuxt/{components.060d9fd5.js → components.c29053f6.js} +27 -27
- package/dist/client/_nuxt/custom-_name_.85ea5a6a.js +1 -0
- package/dist/client/_nuxt/{default.6eda7699.js → default.a568b6bd.js} +1 -1
- package/dist/client/_nuxt/editor.beb173d9.js +1 -0
- package/dist/client/_nuxt/entry.ea777320.css +1 -0
- package/dist/client/_nuxt/entry.eb90118b.js +19 -0
- package/dist/client/_nuxt/{error-404.7bcf1a44.js → error-404.47f56ae7.js} +1 -1
- package/dist/client/_nuxt/{error-500.b67f8091.js → error-500.3d8abd19.js} +1 -1
- package/dist/client/_nuxt/{error-component.5479d89e.js → error-component.97bd3af7.js} +2 -2
- package/dist/client/_nuxt/{full.89a525fd.js → full.039e8e59.js} +1 -1
- package/dist/client/_nuxt/hooks.4df47b77.js +1 -0
- package/dist/client/_nuxt/imports.dd38df5c.js +1 -0
- package/dist/client/_nuxt/{index.b8d7fad0.js → index.2d500b42.js} +1 -1
- package/dist/client/_nuxt/{index.a348e979.js → index.ee7015bb.js} +1 -1
- package/dist/client/_nuxt/json-editor-vue.6b7715bf.js +137 -0
- package/dist/client/_nuxt/{middleware.61ccc755.js → middleware.a6f1dc81.js} +1 -1
- package/dist/client/_nuxt/modules.8de52693.js +4 -0
- package/dist/client/_nuxt/{none.566b9a55.js → none.7a55d586.js} +1 -1
- package/dist/client/_nuxt/nuxt-docs.100caa70.js +1 -0
- package/dist/client/_nuxt/open-graph.ba654e1e.js +3 -0
- package/dist/client/_nuxt/overview.4725a261.js +1 -0
- package/dist/client/_nuxt/pages.46157a67.js +1 -0
- package/dist/client/_nuxt/payload.b59c0588.js +1 -0
- package/dist/client/_nuxt/plugins.6a2cae7a.js +1 -0
- package/dist/client/_nuxt/runtime-configs.4a7ef849.js +1 -0
- package/dist/client/_nuxt/server-routes.2d06f2c7.js +9 -0
- package/dist/client/_nuxt/settings.1b865c96.js +1 -0
- package/dist/client/_nuxt/state-components.ed0b4287.js +1 -0
- package/dist/client/_nuxt/storage.b18c38a9.js +1 -0
- package/dist/client/_nuxt/terminals.195d8588.js +9 -0
- package/dist/client/_nuxt/{terminals.d1dcf297.css → terminals.ae8c3544.css} +1 -1
- package/dist/client/_nuxt/{unocss-runtime.a821baa9.js → unocss-runtime.032bcb78.js} +2 -2
- package/dist/client/_nuxt/{virtual-files.2fc42163.js → virtual-files.5f7c5d81.js} +1 -1
- package/dist/client/index.html +2 -2
- package/dist/client/modules/analyze-build/index.html +2 -2
- package/dist/client/modules/assets/index.html +2 -2
- package/dist/client/modules/components/index.html +2 -2
- package/dist/client/modules/hooks/index.html +2 -2
- package/dist/client/modules/imports/index.html +2 -2
- package/dist/client/modules/middleware/index.html +2 -2
- package/dist/client/modules/modules/index.html +2 -2
- package/dist/client/modules/open-graph/index.html +2 -2
- package/dist/client/modules/overview/index.html +2 -2
- package/dist/client/modules/pages/index.html +2 -2
- package/dist/client/modules/payload/index.html +2 -2
- package/dist/client/modules/plugins/index.html +2 -2
- package/dist/client/modules/runtime-configs/index.html +2 -2
- package/dist/client/modules/server-routes/index.html +2 -2
- package/dist/client/modules/storage/index.html +2 -2
- package/dist/client/modules/terminals/index.html +2 -2
- package/dist/client/modules/virtual-files/index.html +2 -2
- package/dist/client/settings/index.html +2 -2
- package/dist/module.json +1 -1
- package/dist/module.mjs +1 -1
- package/dist/runtime/auth/index.html +71 -0
- package/dist/runtime/nitro/inline.d.ts +3 -0
- package/dist/runtime/nitro/inline.mjs +6 -0
- package/dist/runtime/plugins/devtools.client.d.ts +8 -0
- package/dist/runtime/plugins/devtools.client.mjs +73 -8
- package/dist/runtime/plugins/devtools.server.d.ts +2 -0
- package/dist/runtime/plugins/devtools.server.mjs +8 -0
- package/dist/runtime/plugins/view/Frame.vue +31 -228
- package/dist/runtime/plugins/view/FrameBox.vue +167 -0
- package/dist/runtime/plugins/view/Main.vue +360 -0
- package/dist/runtime/plugins/view/client.d.ts +3 -0
- package/dist/runtime/plugins/view/client.mjs +45 -0
- package/dist/runtime/plugins/view/state.d.ts +2 -3
- package/dist/runtime/plugins/view/state.mjs +12 -9
- package/dist/runtime/plugins/view/utils.d.ts +1 -0
- package/dist/runtime/plugins/view/utils.mjs +9 -0
- package/dist/shared/{devtools.345c630c.mjs → devtools.7ab40af4.mjs} +3 -1
- package/dist/types.d.ts +1 -1
- package/package.json +30 -29
- package/dist/client/__inspecting/index.html +0 -7
- package/dist/client/_nuxt/CodeSnippets.vue.0933ada7.js +0 -1
- package/dist/client/_nuxt/DrawerRight.vue.7bc0ac9b.js +0 -1
- package/dist/client/_nuxt/DurationDisplay.vue.d2a5c09b.js +0 -1
- package/dist/client/_nuxt/FilepathItem.vue.a3a55bfd.js +0 -1
- package/dist/client/_nuxt/LaunchPage.vue.dff3dd39.js +0 -1
- package/dist/client/_nuxt/NCheckbox.vue.cd1637b2.js +0 -1
- package/dist/client/_nuxt/NCodeBlock.vue.d5b2e85d.js +0 -2
- package/dist/client/_nuxt/NIconButton.vue.3defcade.js +0 -1
- package/dist/client/_nuxt/NIconTitle.vue.62b2ff0a.js +0 -1
- package/dist/client/_nuxt/NLink.vue.be635eca.js +0 -1
- package/dist/client/_nuxt/NMarkdown.vue.00fc3014.js +0 -1
- package/dist/client/_nuxt/NSectionBlock.63c19da9.css +0 -1
- package/dist/client/_nuxt/NSectionBlock.eb96beb4.js +0 -1
- package/dist/client/_nuxt/NSelect.vue.7652516b.js +0 -1
- package/dist/client/_nuxt/NSwitch.vue.c07ff0b7.js +0 -1
- package/dist/client/_nuxt/NTip.vue.3fd9b115.js +0 -1
- package/dist/client/_nuxt/NpmVersionCheck.vue.7bc4775a.js +0 -1
- package/dist/client/_nuxt/StateEditor.vue.6e8c107a.js +0 -1
- package/dist/client/_nuxt/__inspecting.137e909d.js +0 -1
- package/dist/client/_nuxt/analyze-build.790e4c36.js +0 -1
- package/dist/client/_nuxt/assets.1c0d54b4.js +0 -16
- package/dist/client/_nuxt/custom-_name_.e88f914e.js +0 -1
- package/dist/client/_nuxt/editor.4380b623.js +0 -1
- package/dist/client/_nuxt/entry.34446c1f.js +0 -19
- package/dist/client/_nuxt/entry.bf8a0e33.css +0 -1
- package/dist/client/_nuxt/hooks.99ea2107.js +0 -1
- package/dist/client/_nuxt/imports.29e62250.js +0 -1
- package/dist/client/_nuxt/json-editor-vue.62f947e8.js +0 -137
- package/dist/client/_nuxt/modules.f8953fab.js +0 -4
- package/dist/client/_nuxt/open-graph.26d327ec.js +0 -3
- package/dist/client/_nuxt/overview.4326006b.js +0 -1
- package/dist/client/_nuxt/pages.b234eacb.js +0 -1
- package/dist/client/_nuxt/payload.fbf9b90d.js +0 -1
- package/dist/client/_nuxt/plugins.9c9f9450.js +0 -1
- package/dist/client/_nuxt/runtime-configs.cf5a4a0c.js +0 -1
- package/dist/client/_nuxt/server-routes.7185e439.js +0 -9
- package/dist/client/_nuxt/settings.8603972f.js +0 -1
- package/dist/client/_nuxt/state-components.f564bfa7.js +0 -1
- package/dist/client/_nuxt/storage.4b5872ff.js +0 -1
- package/dist/client/_nuxt/terminals.d263a781.js +0 -9
- package/dist/runtime/plugins/view/Container.vue +0 -97
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as x,c as a,w as o,o as n,i as s,f as i,t as l,v as r,h as g,q as b,ae as h,l as N,F as w,aV as C,P as y,k as B,a6 as V}from"./entry.34446c1f.js";import{_ as $}from"./NMarkdown.vue.00fc3014.js";import{_ as P}from"./NPanelGrids.24e40025.js";const v={"text-xl":""},F={flex:"~ gap2 wrap"},D=x({__name:"LaunchPage",props:{icon:null,title:null,description:null,actions:null},emits:["action"],setup(e){return(m,I)=>{const _=C,d=$,u=y,p=B,f=V,k=P;return n(),a(k,null,{default:o(()=>[s(f,{flex:"~ col gap2",mxa:"","min-w-100":"","items-center":"",p6:""},{default:o(()=>[s(_,{mb2:"","text-5xl":"",icon:e.icon||e.icon,title:e.title},null,8,["icon","title"]),i("h1",v,l(e.title),1),e.description?(n(),a(d,{key:0,mb2:"","mt--1":"","text-center":"","text-base":"",op50:"",markdown:e.description},null,8,["markdown"])):r("",!0),i("div",F,[(n(!0),g(w,null,b(e.actions,(t,c)=>(n(),a(p,h({key:c,n:"solid primary",disabled:t.pending,to:t.src,target:t.src?"_blank":void 0},t.attrs,{onClick:()=>{t.handle?.(),m.$emit("action",c)}}),{default:o(()=>[t.pending?(n(),a(u,{key:0,icon:"carbon-circle-dash","animate-spin":""})):r("",!0),N(" "+l(t.label),1)]),_:2},1040,["disabled","to","target","onClick"]))),128))])]),_:1})]),_:1})}}});export{D as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as i,ap as r,h as b,z as p,be as u,u as a,f as n,I as h,aM as k,i as f,Z as m,s as v,o as x,P as _}from"./entry.34446c1f.js";const V=["checked","disabled"],y=["disabled"],B={class:"n-checkbox-box n-checked:n-checkbox-box-checked peer-active:n-active-base peer-focus-visible:n-focus-base n-transition"},M=i({__name:"NCheckbox",props:{modelValue:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},emits:[],setup(o,{emit:l}){const e=r(o,"modelValue",l,{passive:!0});return(t,s)=>{const d=_;return x(),b("label",{class:"n-checkbox hover:n-checkbox-hover select-none items-center n-disabled:n-disabled",checked:a(e)||null,disabled:o.disabled||null},[p(n("input",{"onUpdate:modelValue":s[0]||(s[0]=c=>h(e)?e.value=c:null),type:"checkbox",class:"peer absolute op0",disabled:o.disabled,onKeypress:s[1]||(s[1]=k(c=>e.value=!a(e),["enter"]))},null,40,y),[[u,a(e)]]),n("span",B,[f(d,{class:"n-checkbox-icon scale-0 transform op0 n-transition n-checked:scale-100 n-checked:op100"})]),n("span",{class:v([a(e)?"":"op50","n-transition"])},[m(t.$slots,"default")],2)],8,V)}}});export{M as _};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{d as p}from"./client.d93a636c.js";import{a as m,p as _,ah as k,o as t,h as s,s as a,f as l,F as r,q as f,t as h}from"./entry.34446c1f.js";const g=["innerHTML"],y={class:"shiki"},C=["textContent"],v=l("br",null,null,-1),T=m({__name:"NCodeBlock",props:{code:null,lang:null,lines:{type:Boolean,default:!0},transformRendered:{type:Function}},emits:["loaded"],setup(n,{emit:c}){const o=n,d=_(()=>{const e=p.value?.devtools.renderCodeHighlight(o.code,o.lang)||{code:o.code,supported:!1};return e.supported&&o.transformRendered&&(e.code=o.transformRendered(e.code)),e.supported&&k(()=>c("loaded")),e});return(e,x)=>n.lang&&d.value.supported?(t(),s("pre",{key:0,class:a(["n-code-block",n.lines?"n-code-block-lines":""]),innerHTML:d.value.code},null,10,g)):(t(),s("pre",{key:1,class:a(["n-code-block",n.lines?"n-code-block-lines":""])},[l("pre",y,[l("code",null,[(t(!0),s(r,null,f(n.code.split(`
|
|
2
|
-
`),(i,u)=>(t(),s(r,{key:u},[l("span",{class:"line",textContent:h(i)},null,8,C),v],64))),128))])])],2))}});export{T as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as e,o as c,c as s,w as r,i,ae as u,aa as l,u as m,J as _,P as p}from"./entry.34446c1f.js";const x=e({__name:"NIconButton",props:{to:null,icon:null},setup(n){const o=n;return(t,f)=>{const a=p;return c(),s(l(n.to?m(_):"button"),u({to:n.to},t.$attrs,{class:"n-transition n-icon-button"}),{default:r(()=>[i(a,{icon:o.icon},null,8,["icon"])]),_:1},16,["to"])}}});export{x as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as s,o as t,h as n,s as o,v as l,Z as c,f as i,t as r}from"./entry.34446c1f.js";const m={flex:"~ gap-3","items-center":""},f=s({__name:"NIconTitle",props:{icon:null,text:null},setup(e){return(a,d)=>(t(),n("div",m,[e.icon?(t(),n("div",{key:0,class:o(e.icon)},null,2)):l("",!0),c(a.$slots,"default",{},()=>[i("div",null,r(e.text),1)])]))}});export{f as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a,o,c as t,w as r,Z as s,ae as l,aa as i,u,J as c}from"./entry.34446c1f.js";const f=a({__name:"NLink",props:{to:null,href:null,target:null},setup(e){return(n,p)=>(o(),t(i(e.href||e.target?"a":u(c)),l(n.$props,{class:"n-link n-transition hover:n-link-hover n-link-base"}),{default:r(()=>[s(n.$slots,"default")]),_:3},16))}});export{f as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{d as a}from"./client.d93a636c.js";import{a as s,u as e,o,c as t,aa as r,t as l}from"./entry.34446c1f.js";const i=s({__name:"NMarkdown",props:{markdown:null,tag:null},setup(n){return(d,m)=>n.markdown&&e(a)?.devtools?.renderMarkdown?(o(),t(r(n.tag||"span"),{key:0,class:"n-markdown",innerHTML:e(a).devtools.renderMarkdown(n.markdown)},null,8,["innerHTML"])):(o(),t(r(n.tag||"span"),{key:1,class:"n-markdown",textContent:l(n.markdown)},null,8,["textContent"]))}});export{i as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
details[data-v-2c2fc4e1]{border-style:none}summary[data-v-2c2fc4e1]{border-style:none;list-style:none}details[open] summary[data-v-2c2fc4e1]{border-style:none}details summary[data-v-2c2fc4e1]::-webkit-details-marker{display:none}details[open] .chevron[data-v-2c2fc4e1]{opacity:.75;transform:rotate(180deg)}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as g,ap as _,h as c,f as o,s as a,i as y,w,u as l,F as u,z as B,A as S,Z as s,v as d,o as i,l as p,t as v,c as $,aw as C,ax as N,P as k,aW as I}from"./entry.34446c1f.js";import{_ as b}from"./NIconTitle.vue.62b2ff0a.js";const f=e=>(C("data-v-2c2fc4e1"),e=e(),N(),e),V=["open"],z={"text-base":""},T={key:0,"text-sm":"",op50:""},D=f(()=>o("div",{class:"flex-auto"},null,-1)),F=f(()=>o("div",{class:"x-divider"},null,-1)),A=g({__name:"NSectionBlock",props:{icon:null,text:null,description:null,containerClass:{default:""},headerClass:null,collapse:{type:Boolean,default:!0},open:{type:Boolean,default:!0},padding:{type:[Boolean,String],default:!0}},setup(e){const n=_(e,"open",void 0,{passive:!0});function m(t){n.value=t.target.open}return(t,r)=>{const h=k,x=b;return i(),c(u,null,[o("details",{open:l(n),onToggle:m},[o("summary",{class:a(["cursor-pointer select-none hover:bg-active p4",e.collapse?"":"pointer-events-none"])},[y(x,{icon:e.icon,text:e.text,"text-xl":"",transition:"",class:a([l(n)?"op100":"op60",e.headerClass])},{default:w(()=>[o("div",null,[o("div",z,[s(t.$slots,"text",{},()=>[p(v(e.text),1)],!0)]),e.description||t.$slots.description?(i(),c("div",T,[s(t.$slots,"description",{},()=>[p(v(e.description),1)],!0)])):d("",!0)]),D,s(t.$slots,"actions",{},void 0,!0),e.collapse?(i(),$(h,{key:0,icon:"carbon-chevron-down",class:"chevron","cursor-pointer":"","place-self-start":"","text-base":"",op75:"",transition:"","duration-500":""})):d("",!0)]),_:3},8,["icon","text","class"])],2),r._lazyshow1||l(n)?(r._lazyshow1=!0,i(),c(u,null,[B(o("div",{class:a(["flex flex-col flex-gap2 pb6 pt2",typeof e.padding=="string"?e.padding:e.padding?"px4":""])},[s(t.$slots,"details",{},void 0,!0),o("div",{class:a([e.containerClass,"mt1"])},[s(t.$slots,"default",{},void 0,!0)],2),s(t.$slots,"footer",{},void 0,!0)],2),[[S,l(n)]])],64)):d("v-show-if",!0)],40,V),F],64)}}});const W=I(A,[["__scopeId","data-v-2c2fc4e1"]]);export{W as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as r,ap as f,h as l,Z as n,z as m,bf as p,u as b,f as h,t as v,v as d,I as x,o as s,c as V,P as k}from"./entry.34446c1f.js";const y={class:"n-text-input flex flex items-center border n-border-base rounded px-2 py-1 focus-within:n-focus-base focus-within:border-context n-bg-base"},B=["disabled"],w={key:0,value:"",disabled:"",hidden:""},g=r({__name:"NSelect",props:{modelValue:{default:void 0},placeholder:{default:""},icon:{default:""},disabled:{type:Boolean,default:!1}},emits:[],setup(e,{emit:i}){const o=f(e,"modelValue",i,{passive:!0});return(t,a)=>{const c=k;return s(),l("div",y,[n(t.$slots,"icon",{},()=>[e.icon?(s(),V(c,{key:0,icon:e.icon,class:"mr-0.4em text-1.1em op50"},null,8,["icon"])):d("",!0)]),m(h("select",{"onUpdate:modelValue":a[0]||(a[0]=u=>x(o)?o.value=u:null),disabled:e.disabled,class:"w-full flex-auto n-bg-base !outline-none"},[e.placeholder?(s(),l("option",w,v(e.placeholder),1)):d("",!0),n(t.$slots,"default")],8,B),[[p,b(o)]])])}}});export{g as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as o,ap as c,o as r,h as u,z as h,be as b,u as t,f as l,I as p,aM as f,Z as v}from"./entry.34446c1f.js";const m=["checked","disabled"],k=["disabled"],w=l("div",{class:"n-switch-slider n-checked:n-switch-slider-checked peer-active:n-active-base peer-focus-visible:n-focus-base n-transition"},[l("div",{class:"n-checked:n-switch-thumb-checked n-switch-thumb n-transition"})],-1),V=o({__name:"NSwitch",props:{modelValue:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},emits:[],setup(a,{emit:d}){const e=c(a,"modelValue",d,{passive:!0});return(i,s)=>(r(),u("label",{class:"n-switch n-switch-base hover:n-switch-hover n-disabled:n-disabled",checked:t(e)||null,disabled:a.disabled||null},[h(l("input",{"onUpdate:modelValue":s[0]||(s[0]=n=>p(e)?e.value=n:null),type:"checkbox",class:"peer absolute op0",disabled:a.disabled,onKeypress:s[1]||(s[1]=f(n=>e.value=!t(e),["enter"]))},null,40,k),[[b,t(e)]]),w,v(i.$slots,"default")],8,m))}});export{V as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as t,o,h as a,Z as s,c as i,v as l,f as r,P as m}from"./entry.34446c1f.js";const p={class:"n-tip n-tip-base"},u=t({__name:"NTip",props:{icon:null},setup(e){return(n,_)=>{const c=m;return o(),a("div",p,[s(n.$slots,"icon",{},()=>[e.icon?(o(),i(c,{key:0,icon:e.icon,class:"n-tip-icon"},null,8,["icon"])):l("",!0)]),r("div",null,[s(n.$slots,"default")])])}}});export{u as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{_ as j}from"./Badge.ade65c69.js";import{_ as E}from"./NCodeBlock.vue.d5b2e85d.js";import{_ as F}from"./NCheckbox.vue.cd1637b2.js";import{_ as G}from"./NTip.vue.3fd9b115.js";import{a as L,D as Q,aQ as W,r as x,aR as Z,B as q,o as r,h as p,Z as z,u as e,t as h,v as N,F as b,i as t,c as A,w as o,f as _,I as V,l as u,k as H,L as J}from"./entry.34446c1f.js";const K={key:0},M={p4:"",flex:"~ col gap-1"},O={class:"text-lg font-medium leading-6"},X=_("p",{op50:""}," The following command will be executed in your terminal: ",-1),Y={flex:"~ gap-3",mt2:"","justify-end":""},se=L({__name:"NpmVersionCheck",props:{packageName:null,options:null,showVersion:{type:Boolean,default:!0}},setup(f){const i=f,$=Q(),{info:l,update:w,state:B,processId:R,restart:U}=W(i.packageName,i.options),c=x(!0),d=x(!0),D=Z(),g=q();async function k(){const n=await w(async a=>g.start(a));n&&d.value&&D.value.push({id:n,message:`${i.packageName} has been updated. Do you want to restart the Nuxt server now?`}),n&&c.value&&$.push(`/modules/terminals?id=${encodeURIComponent(n)}`)}return(n,a)=>{const y=j,T=E,C=F,I=G,v=H,P=J;return r(),p(b,null,[z(n.$slots,"default",{id:e(R),info:e(l),update:k,state:e(B),restart:e(U)},()=>[e(l)&&f.showVersion?(r(),p("code",K,h(`v${e(l).current}`),1)):N("",!0),e(l)?.latest?(r(),p(b,{key:1},[e(l).needsUpdate?(r(),p("button",{key:0,onClick:a[0]||(a[0]=m=>k())},[t(y,{"bg-green-400:10":"","text-green-400":"",title:"updates available",textContent:"updates available"})])):(r(),A(y,{key:1,"bg-gray-400:10":"","text-gray-400":"",title:"latest",textContent:"latest"}))],64)):N("",!0)]),t(e(g),null,{default:o(({resolve:m,args:S})=>[t(P,{"model-value":!0,onClose:s=>m(!1)},{default:o(()=>[_("div",M,[_("h3",O," Update "+h(i.packageName)+"? ",1),X,t(T,{code:S[0],lang:"bash",my3:"",px4:"",py2:"",border:"~ base rounded",lines:!1},null,8,["code"]),t(C,{modelValue:e(c),"onUpdate:modelValue":a[1]||(a[1]=s=>V(c)?c.value=s:null),n:"primary"},{default:o(()=>[u(" Navigate to terminal ")]),_:1},8,["modelValue"]),t(C,{modelValue:e(d),"onUpdate:modelValue":a[2]||(a[2]=s=>V(d)?d.value=s:null),n:"primary"},{default:o(()=>[u(" Restart Nuxt server after update ")]),_:1},8,["modelValue"]),_("div",Y,[t(I,{n:"sm purple","flex-auto":"",icon:"carbon-chemistry"},{default:o(()=>[u(" Experimental feature. Please make sure to backup your project first. ")]),_:1}),t(v,{onClick:s=>m(!1)},{default:o(()=>[u(" Cancel ")]),_:2},1032,["onClick"]),t(v,{n:"solid primary",onClick:s=>m(!0)},{default:o(()=>[u(" Update ")]),_:2},1032,["onClick"])])])]),_:2},1032,["onClose"])]),_:1})],64)}}});export{se as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{_ as h}from"./NIconButton.vue.3defcade.js";import{a as N,ap as S,a0 as B,r as O,aX as V,o as i,h as c,f as u,s as d,u as s,t as x,v as m,Z as C,n as w,g as j,c as v,F as J,ae as P,I as $,ah as z}from"./entry.34446c1f.js";import{U as M}from"./json-editor-vue.62f947e8.js";const R=["open"],U={flex:"~ gap2","select-none":"","items-center":"",px4:""},A={key:1,"bg-active":"",p5:"",italic:""},E=u("span",{op50:""},"No data",-1),F=[E],X=N({__name:"StateEditor",props:{name:null,open:{type:Boolean},state:null,readonly:{type:Boolean}},emits:["update:open"],setup(t,{emit:k}){const r=t,n=S(r,"open",k,{passive:!0}),g=B(),l=O();l.value=JSON.parse(JSON.stringify(r.state));const p=V(l,e=>{y(e,r.state)},{deep:!0});function y(e,o){for(const a in e)e[a]===null?o[a]=null:Array.isArray(e[a])?o[a]=e[a].slice():typeof e[a]=="object"?y(e[a],o[a]):o[a]=e[a]}async function b(){p.pause(),l.value=JSON.parse(JSON.stringify(r.state)),await z(),p.resume()}return(e,o)=>{const a=h;return i(),c("div",{class:"state-editor-details",open:t.name?s(n):!0},[u("div",U,[t.name?(i(),c("button",{key:0,flex:"~","cursor-pointer":"","items-center":"",class:d(s(n)?"":"op50"),onClick:o[0]||(o[0]=f=>n.value=!s(n))},[u("div",{"i-carbon-chevron-right":"",transition:"",class:d(s(n)?"rotate-90 op0":"")},null,2),u("code",{px3:"",py1:"","font-mono":"",class:d(s(n)?"bg-[#8881] rounded-t":"rounded hover:bg-active")},x(t.name),3)],2)):m("",!0),C(e.$slots,"actions",w(j({isOpen:s(n),name:t.name,state:t.state}))),s(n)?(i(),v(a,{key:1,title:"Refresh View",icon:"carbon-renew",onClick:b})):m("",!0)]),s(n)||!t.name?(i(),c(J,{key:0},[t.state&&Object.keys(t.state).length>0?(i(),v(s(M),P({key:0,modelValue:s(l),"onUpdate:modelValue":o[1]||(o[1]=f=>$(l)?l.value=f:null)},e.$attrs,{class:["json-editor-vue",[s(g).value==="dark"?"jse-theme-dark":"",(t.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"])):(i(),c("div",A,F))],64)):m("",!0)],8,R)}}});export{X as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{_ as c}from"./NPanelGrids.24e40025.js";import{a,b as i,e as p,c as r,w as _,o as l,f as e}from"./entry.34446c1f.js";const u=e("div",null," Inspecting Vue components ",-1),h=a({__name:"__inspecting",setup(m){const o=i();p("keydown",t=>{t.key==="Escape"&&n()});function n(){o.value?.inspector?.disable()}return(t,d)=>{const s=c;return l(),r(s,{"h-screen":"","w-screen":"",px5:""},{default:_(()=>[e("div",{absolute:"","right-0":"","top-0":"",p2:""},[e("button",{"carbon-close":"",ma:"","text-xl":"",op50:"","hover:op100":"",onClick:n})]),u]),_:1})}}});export{h as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as E,p as I,r as V,o,h as u,f as e,F as _,q as L,s as F,u as n,t as f,v as y,x as P,i as r,w as a,l as p,y as R,z as T,A,k as U,B as Q,C as X,D as ee,E as te,G as ne,H as k,c as w,I as S,J as oe,K as le,L as ie}from"./entry.34446c1f.js";import{_ as se}from"./FilepathItem.vue.a3a55bfd.js";import{_ as ae}from"./NPanelGrids.24e40025.js";import{_ as re}from"./PanelLeftRight.vue.0d3c5a22.js";import{_ as ue}from"./NTip.vue.3fd9b115.js";import{_ as de}from"./NCodeBlock.vue.d5b2e85d.js";import{_ as ce}from"./NCheckbox.vue.cd1637b2.js";import{_ as me}from"./HelpFab.vue.1ab4e4f1.js";import"./editor.4380b623.js";import"./client.d93a636c.js";import"./NIconButton.vue.3defcade.js";const _e={"h-full":"",grid:"~ rows-[max-content_1fr]"},fe={flex:"~ wrap","w-full":""},pe=["onClick"],ve=e("div",{border:"b base","flex-auto":""},null,-1),he={key:0,flex:"~ col gap-4 items-center justify-center",p4:""},xe=e("div",{"flex-auto":""},null,-1),ye={grid:"~ cols-[30px_1fr] gap-x-2 gap-y-3 items-center justify-center","w-100":""},$e=e("div",{"i-carbon-commit":"","text-xl":""},null,-1),be=e("div",{"text-sm":"",op50:""}," Name ",-1),ge=e("div",{"i-carbon-time":"","text-xl":""},null,-1),we=e("div",{"text-sm":"",op50:""}," Build duration ",-1),ze=e("div",{"i-carbon-cics-program":"","text-xl":""},null,-1),Be=e("div",{"text-sm":"",op50:""}," Client bundle size ",-1),ke=e("div",{"i-carbon-bare-metal-server":"","text-xl":""},null,-1),Ce=e("div",{"text-sm":"",op50:""}," Nitro bundle size ",-1),Ne=e("div",{"i-carbon-edge-node":"","text-xl":""},null,-1),Te=e("div",{"text-sm":"",op50:""}," Built ",-1),Ae=e("div",{"i-carbon:folder-parent":"","text-xl":""},null,-1),De=e("div",{"text-sm":"",op50:""}," Report Path ",-1),Ie=e("div",{"flex-auto":""},null,-1),D="/__nuxt_devtools__/analyze/",Ve=E({__name:"BuildAnalyzeDetails",props:{current:null,prev:null},setup(i){const v=i,h=I(()=>{const t=[{name:"Overview",id:"overview"}];return v.current.features.bundleClient&&t.push({name:"Client Bundle",id:"bundle-client"}),v.current.features.bundleNitro&&t.push({name:"Nitro Bundle",id:"bundle-nitro"}),v.current.features.viteInspect&&t.push({name:"Vite Inspect",id:"vite-inspect"}),t}),s=V(h.value[0]);function b(t){return t<1024?`${t}B`:t<1024*1024?`${(t/1024).toFixed(1)}KB`:t<1024*1024*1024?`${(t/1024/1024).toFixed(1)}MB`:`${(t/1024/1024/1024).toFixed(1)}GB`}function g(t){return`${((t.endTime-t.startTime)/1e3).toFixed(1)}s`}return(t,l)=>{const C=se,z=U;return o(),u("div",_e,[e("div",fe,[(o(!0),u(_,null,L(n(h),(x,N)=>(o(),u("button",{key:N,px4:"",py2:"",border:"r base",hover:"bg-active",class:F(x.id===n(s).id?"":"border-b"),onClick:c=>s.value=x},[e("div",{class:F(x.id===n(s).id?"":"op30")},f(x.name),3)],10,pe))),128)),ve]),n(s).id==="overview"?(o(),u("div",he,[xe,e("div",ye,[$e,e("div",null,[be,e("div",null,f(i.current.name),1)]),ge,e("div",null,[we,e("div",null,f(g(i.current)),1)]),i.current.size?.clientBundle?(o(),u(_,{key:0},[ze,e("div",null,[Be,e("div",null,f(b(i.current.size.clientBundle)),1)])],64)):y("",!0),i.current.size.nitroBundle?(o(),u(_,{key:1},[ke,e("div",null,[Ce,e("div",null,f(b(i.current.size.nitroBundle)),1)])],64)):y("",!0),Ne,e("div",null,[Te,e("div",null,f(n(P)(new Date(i.current.endTime))),1)]),Ae,e("div",null,[De,r(C,{filepath:i.current.analyzeDir},null,8,["filepath"])])]),Ie,r(z,{n:"rose",icon:"carbon-delete",onClick:l[0]||(l[0]=x=>("rpc"in t?t.rpc:n(R)).clearAnalyzeBuilds([i.current.name]))},{default:a(()=>[p(" Delete this report ")]),_:1})])):y("",!0),l._lazyshow1||n(s).id==="bundle-client"?(l._lazyshow1=!0,o(),u(_,null,[T(e("iframe",{src:`${D}${i.current.slug}/client.html`,"h-full":"","w-full":""},null,8,["src"]),[[A,n(s).id==="bundle-client"]])],64)):y("v-show-if",!0),l._lazyshow2||n(s).id==="bundle-nitro"?(l._lazyshow2=!0,o(),u(_,null,[T(e("iframe",{src:`${D}${i.current.slug}/nitro.html`,"h-full":"","w-full":""},null,8,["src"]),[[A,n(s).id==="bundle-nitro"]])],64)):y("v-show-if",!0),l._lazyshow3||n(s).id==="vite-inspect"?(l._lazyshow3=!0,o(),u(_,null,[T(e("iframe",{src:`${D}${i.current.slug}/.vite-inspect/`,"h-full":"","w-full":""},null,8,["src"]),[[A,n(s).id==="vite-inspect"]])],64)):y("v-show-if",!0)])}}}),Fe={class:"markdown-body"},Re=e("h1",null,"Build Analyze",-1),Se=e("p",null,[p("DevTools provides a build analyze tool to help you understand the size of your app in production. Whenever you start a new build, it runs the command "),e("code",null,"nuxt build --analyze"),p(" and present the output data directly in DevTools for easy browsing and comparing.")],-1),Ee=[Re,Se],Le={__name:"analyze-build",setup(i,{expose:v}){return v({frontmatter:{}}),(s,b)=>(o(),u("div",Fe,Ee))}},Pe={flex:"~ col"},Ue={flex:"~ gap-1 items-center","text-sm":"",op60:""},je=e("div",{"i-carbon-time":""},null,-1),Ge=e("div",{"flex-auto":""},null,-1),qe=e("div",{"x-divider":""},null,-1),He={flex:"~ items-center justify-center",p4:""},Ke={flex:"~ col gap-1","w-250":"",p4:""},Oe=e("h3",{class:"text-lg font-medium leading-6",mb2:""}," Start analyze build? ",-1),Je=e("p",{op50:""}," Enter the name of the build: ",-1),Me=e("div",{my3:"","x-divider":""},null,-1),We=e("p",{op50:""}," The following command will be executed in your terminal: ",-1),Ye={flex:"~ gap-3",mt2:"","justify-end":""},rt=E({__name:"analyze-build",setup(i){const v=Q(),h=X(),s=ee(),b=te(),g=I(()=>{const c=b.query.slug;return h.value?.builds.find(m=>m.slug===c)??h.value?.builds[0]}),t=V(!1),l=V(""),C=I(()=>h.value?.builds.some(c=>c.name===l.value.trim()));async function z(){l.value=await R.generateAnalyzeBuildName(),await v.start()&&(k.value={name:l.value,processId:await R.startAnalyzeBuild(l.value)},t.value&&x())}function x(){k.value?.processId&&s.push(`/modules/terminals?id=${encodeURIComponent(k.value.processId)}`)}function N(c){return`${((c.endTime-c.startTime)/1e3).toFixed(1)}s`}return ne(()=>[{id:"analyze-build: start",title:"Start a new analyze build",icon:"i-carbon-edge-node",action:z}]),(c,m)=>{const j=oe,B=U,G=Ve,q=ae,H=re,K=le,O=ue,J=de,M=ce,W=ie,Y=Le,Z=me;return o(),u(_,null,[r(H,{"left-size":20},{left:a(()=>[e("div",Pe,[(o(!0),u(_,null,L(n(h)?.builds,d=>(o(),u(_,{key:d.slug},[r(j,{flex:"~ col gap1","hover:bg-active":"",p3:"",class:F(d.slug===n(g)?.slug?"text-primary bg-active":""),to:`?slug=${encodeURIComponent(d.slug)}`},{default:a(()=>[e("code",null,f(d.name),1),e("div",Ue,[je,e("span",null,f(N(d)),1),Ge,e("span",null,f(n(P)(new Date(d.endTime))),1)])]),_:2},1032,["class","to"]),qe],64))),128)),e("div",He,[("processAnalyzeBuildInfo"in c?c.processAnalyzeBuildInfo:n(k))?(o(),w(B,{key:1,n:"primary",icon:"carbon-circle-dash animate-spin",onClick:m[1]||(m[1]=d=>x())},{default:a(()=>[p(" Building... ")]),_:1})):(o(),w(B,{key:0,n:"primary",icon:"carbon-edge-node",onClick:m[0]||(m[0]=d=>z())},{default:a(()=>[p(" Start a new build ")]),_:1}))])])]),right:a(()=>[n(g)?(o(),w(G,{key:0,current:n(g)},null,8,["current"])):(o(),w(q,{key:1}))]),_:1}),r(n(v),null,{default:a(({resolve:d})=>[r(W,{"model-value":!0,onClose:$=>d(!1)},{default:a(()=>[e("div",Ke,[Oe,Je,r(K,{modelValue:n(l),"onUpdate:modelValue":m[2]||(m[2]=$=>S(l)?l.value=$:null),placeholder:"Build name"},null,8,["modelValue"]),n(C)?(o(),w(O,{key:0,"n-orange":""},{default:a(()=>[p(" A build with the same name already exists, continue would overrides the previous build result. ")]),_:1})):y("",!0),Me,We,r(J,{code:`npx nuxi analyze --no-serve --name=${n(l)}`,lang:"bash",px4:"",py2:"",border:"~ base rounded",lines:!1},null,8,["code"]),r(M,{modelValue:n(t),"onUpdate:modelValue":m[3]||(m[3]=$=>S(t)?t.value=$:null),mt2:"",n:"primary"},{default:a(()=>[p(" Navigate to terminal ")]),_:1},8,["modelValue"]),e("div",Ye,[r(B,{onClick:$=>d(!1)},{default:a(()=>[p(" Cancel ")]),_:2},1032,["onClick"]),r(B,{n:"solid primary",onClick:$=>d(!0)},{default:a(()=>[p(" Start ")]),_:2},1032,["onClick"])])])]),_:2},1032,["onClose"])]),_:1}),r(Z,null,{default:a(()=>[r(Y)]),_:1})],64)}}});export{rt as default};
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import{_ as K}from"./NIconButton.vue.3defcade.js";import{_ as H}from"./Navbar.vue.12ff05d9.js";import{a as j,M as J,r as T,e as V,o as s,h as c,i as f,u as n,f as e,l as E,F as N,q as O,c as F,w as z,v as S,s as G,N as ee,O as te,y as X,P as ne,K as se,k as W,p as y,Q as oe,R as ae,S as ie,t as w,T as q,U as le,V as re,W as ce,X as ue,Y as de,I as pe}from"./entry.34446c1f.js";import{_ as me}from"./NSectionBlock.eb96beb4.js";import{_ as fe}from"./FilepathItem.vue.a3a55bfd.js";import{_ as he}from"./CodeSnippets.vue.0933ada7.js";import{u as _e,a as ve}from"./editor.4380b623.js";import{_ as ge}from"./DrawerRight.vue.7bc0ac9b.js";import{D as xe}from"./constants.d7bcda3c.js";import"./NIconTitle.vue.62b2ff0a.js";import"./NCodeBlock.vue.d5b2e85d.js";import"./client.d93a636c.js";const be={key:0,"h-full":"","w-full":"",flex:"","items-center":"","justify-center":""},we={for:"drop-zone-input","text-3xl":""},ye={key:1,relative:"","h-full":"","w-full":"",grid:"~ rows-[max-content_1fr_max-content]"},$e=e("div",{px6:"",py6:""},[e("h1",{"text-2xl":""}," Upload "),e("p",{"text-sm":"",op50:""}," Drag and drop files to upload ")],-1),ke={grid:"~ cols-minmax-8rem","overflow-auto":"",p6:""},Ce={flex:"","items-center":"","justify-center":"","of-hidden":"",rounded:"","rounded-t-lg":"","bg-active":"","object-cover":"",class:"aspect-1/1",border:"~ base"},Pe=["src"],Fe={flex:"~ gap1","items-center":""},Ae={flex:"~ gap-2","items-center":"","justify-center":"",p8:""},De=j({__name:"DropZone",props:{folder:{type:String,required:!0}},emits:["uploaded"],setup(o,{emit:t}){const m=o,l=J(),g=T(!1),k=T(),u=T([]),C=["image","video"];function L(a){k.value=a.target,g.value=!0}function B(a){a.target===k.value&&(g.value=!1)}function M(a){a.preventDefault()}function x(a){a.preventDefault(),h(a.dataTransfer.files)}function h(a){const _=Array.from(a||[]);if(_.length){const i=[],v=u.value.map(d=>d.name);for(const d of _)if(v.includes(d.name)){let b=1;const[P,R]=d.name.split(".");for(;v.includes(`${P} (${b}).${R}`);)b++;const U=`${P}-${b}.${R}`,Q=new Blob([d],{type:d.type}),Y=new File([Q],U,{lastModified:Date.now()});i.push(Y),v.push(U)}else d.type===""?l("Folders are not supported yet","carbon:face-dissatisfied"):C.some(b=>d.type.includes(b))?i.push(d):l(`"${d.type}" file type is not allowed`,"carbon:face-dizzy");u.value=[...u.value,...i]}}async function r(){if(ee.value||te.value)return;const a=[];for(const _ of u.value){const i=new FileReader;i.readAsDataURL(_);const d=(await new Promise(b=>{i.onload=()=>b(i.result)})).split(";base64,").pop();a.push({name:_.name,data:d})}await X.writeStaticAssets([...a],m.folder).then(()=>{t("uploaded"),I(),l("Files uploaded successfully!","carbon:face-cool")}).catch(_=>{console.error(_),I(),l("Upload failed!","carbon:face-dizzy")}),g.value=!1}function p(a){u.value?.splice(a,1)}function A(a){return URL.createObjectURL(a)}function $(a,_){const[i,v]=a.name.split("."),d=_.replace(/\.\w+$/,""),b=`${d}.${v}`;return d.length===0?(alert("File name must be at least 1 characters long"),i):(Object.defineProperty(a,"name",{value:b,writable:!1}),u.value.splice(u.value.indexOf(a),1,a),a)}function D(){u.value=[]}function I(){g.value=!1,D()}return V("dragenter",L),V("dragleave",B),V("dragover",M),V("drop",x),(a,_)=>{const i=K,v=ne,d=se,b=W;return s(),c("div",{fixed:"","bottom-0":"","left-13":"","right-0":"","top-0":"","z-10":"","backdrop-blur-20":"","transition-all":"",class:G(n(g)?"opacity-100 visible":"opacity-0 invisible")},[f(i,{icon:"carbon-close",absolute:"","right-5":"","top-5":"","z-20":"","text-xl":"",onClick:I}),n(u)?.length?(s(),c("div",ye,[$e,e("div",ke,[(s(!0),c(N,null,O(n(u),(P,R)=>(s(),c("div",{key:P.name,flex:"~ col gap-2",relative:"","h-50":"","w-40":"","items-center":""},[e("div",Ce,[e("img",{"h-full":"","w-full":"","rounded-t-lg":"","object-cover":"",src:A(P)},null,8,Pe)]),e("div",Fe,[f(d,{n:"xs","flex-auto":"","model-value":P.name,"onUpdate:modelValue":U=>$(P,U.target.value)},null,8,["model-value","onUpdate:modelValue"]),f(i,{icon:"carbon-delete","flex-none":"",title:"Remove file",onClick:U=>p(R)},null,8,["onClick"])])]))),128))]),e("div",Ae,[n(u).length?(s(),F(b,{key:0,n:"red",onClick:D},{default:z(()=>[f(v,{icon:"carbon-clean"}),E(" Clear ")]),_:1})):S("",!0),f(b,{disabled:!n(u).length,n:"primary solid",onClick:r},{default:z(()=>[f(v,{icon:"carbon-cloud-upload"}),E(" Upload ")]),_:1},8,["disabled"])])])):(s(),c("div",be,[e("label",we,[f(v,{icon:"carbon-cloud-upload","mr-2":""}),E(" Drop files here or click to select ")]),e("input",{id:"drop-zone-input",type:"file",multiple:"",hidden:"",onChange:_[0]||(_[0]=P=>h(P.target.files))},null,32)]))],2)}}}),Ie=j({__name:"AssetFontPreview",props:{asset:null},setup(o){const t=o,m=y(()=>`devtools-assets-${oe(t.asset)}`);return ae(y(()=>`
|
|
2
|
-
@font-face {
|
|
3
|
-
font-family: '${m.value}';
|
|
4
|
-
src: url('${t.asset.publicPath}');
|
|
5
|
-
}
|
|
6
|
-
`)),(l,g)=>(s(),c("div",{"of-hidden":"",style:ie({fontFamily:`'${n(m)}'`})}," Aa Bb Cc Dd Ee Ff Gg Hh Ii Jj Kk Ll Mm Nn Oo Pp Qq Rr Ss Tt Uu Vv Ww Xx Yy Zz ",4))}}),Ne={flex:"","items-center":"","justify-center":"","of-hidden":"","bg-active":"","object-cover":"",p1:""},Se=["src"],ze={key:2,"i-carbon-document":"","text-3xl":"",op20:""},Te={key:3,"w-full":"","self-start":"",p4:""},je=["textContent"],Be={key:4,"i-carbon-help":"","text-3xl":"",op20:""},Z=j({__name:"AssetPreview",props:{asset:null,textContent:null},setup(o){return(t,m)=>{const l=Ie;return s(),c("div",Ne,[o.asset.type==="image"?(s(),c("img",{key:0,src:o.asset.publicPath},null,8,Se)):o.asset.type==="font"?(s(),F(l,{key:o.asset.publicPath,asset:o.asset,"self-stretch":"",p2:"","text-2xl":""},null,8,["asset"])):o.asset.type==="text"&&!o.textContent?(s(),c("div",ze)):o.asset.type==="text"&&o.textContent?(s(),c("div",Te,[e("pre",{"max-h-10rem":"","of-hidden":"","font-mono":"","text-xs":"",textContent:w(o.textContent)},null,8,je)])):(s(),c("div",Be))])}}}),Ee={flex:"~ col gap-1",hover:"bg-active","items-center":"","of-hidden":"",rounded:"",p2:""},Le={"w-full":"","of-hidden":"",truncate:"","ws-nowrap":"","text-center":"","text-xs":""},Me=j({__name:"AssetGridItem",props:{asset:{},folder:{}},setup(o){const t=o,m=y(()=>t.folder&&t.asset.path.startsWith(t.folder)?t.asset.path.slice(t.folder.length):t.asset.path);return(l,g)=>{const k=Z;return s(),c("button",Ee,[f(k,{"h-30":"","w-30":"",rounded:"",border:"~ base",asset:l.asset},null,8,["asset"]),e("div",Le,w(n(m)),1)])}}}),Ue={flex:"~ gap-1","w-full":"","items-center":"",hover:"bg-active",rounded:"",px4:"",py2:""},Oe={"of-hidden":"",truncate:"","ws-nowrap":"","text-center":""},Re=j({__name:"AssetListItem",props:{asset:{}},setup(o){const t=o,m=y(()=>t.asset.type==="image"?"i-carbon-image":t.asset.type==="video"?"i-carbon-video":t.asset.type==="audio"?"i-carbon-volume-up":t.asset.type==="font"?"i-carbon-text-small-caps":t.asset.type==="text"?"i-carbon-document":t.asset.type==="json"?"i-carbon-json":"i-carbon-document-blank");return(l,g)=>(s(),c("button",Ue,[e("div",{class:G(n(m))},null,2),e("div",Oe,w(l.asset.path),1)]))}}),Ve={flex:"~ col gap-4","min-h-full":"","w-full":"","of-hidden":"",p4:""},Xe=e("div",{flex:"~ gap2","mb--2":"","items-center":"",op50:""},[e("div",{"x-divider":""}),e("div",{"flex-none":""}," Preview "),e("div",{"x-divider":""})],-1),Ke={flex:"~","items-center":"","justify-center":""},qe=e("div",{flex:"~ gap2","mb--2":"","items-center":"",op50:""},[e("div",{"x-divider":""}),e("div",{"flex-none":""}," Details "),e("div",{"x-divider":""})],-1),Ge={"max-w-full":"","w-full":"","table-fixed":""},We=e("td",{"w-30":"","ws-nowrap":"",pr5:"","text-right":"",op50:""}," Filepath ",-1),Ze={flex:"~ gap-1","w-full":"","items-center":""},Qe=e("td",{"w-30":"","ws-nowrap":"",pr5:"","text-right":"",op50:""}," Public Path ",-1),Ye={flex:"~ gap-1","w-full":"","items-center":"","of-hidden":""},He={"flex-auto":"","of-hidden":"",truncate:"","ws-pre":"","font-mono":""},Je=e("td",{"w-30":"","ws-nowrap":"",pr5:"","text-right":"",op50:""}," Type ",-1),et={capitalize:""},tt=e("td",{"w-30":"","ws-nowrap":"",pr5:"","text-right":"",op50:""}," Image Size ",-1),nt={key:0},st=e("td",{"w-30":"","ws-nowrap":"",pr5:"","text-right":"",op50:""}," Aspect Ratio ",-1),ot=e("td",{"w-30":"","ws-nowrap":"",pr5:"","text-right":"",op50:""}," File size ",-1),at=e("td",{"w-30":"","ws-nowrap":"",pr5:"","text-right":"",op50:""}," Last modified ",-1),it={op70:""},lt=e("div",{flex:"~ gap2","mb--2":"","items-center":"",op50:""},[e("div",{"x-divider":""}),e("div",{"flex-none":""}," Actions "),e("div",{"x-divider":""})],-1),rt={flex:"~ gap2 wrap"},ct=e("div",{"flex-auto":""},null,-1),ut=j({__name:"AssetDetails",props:{asset:null},setup(o){const t=o,m=_e(),l=q(()=>{if(t.asset.type==="image")return X.getImageMeta(t.asset.filePath)}),g=q(()=>{if(t.asset.type==="text")return X.getTextAssetContent(t.asset.filePath)}),k=le(),u=y(()=>(k.value?._installedModules||[]).some(p=>p.meta?.name==="@nuxt/image"||p.meta?.name==="@nuxt/image-edge")),C=y(()=>{const r=[];if(t.asset.type==="image"){const p=l.value?.width?`
|
|
7
|
-
width="${l.value.width}"
|
|
8
|
-
height="${l.value.height}" `:" ";return r.push({lang:"vue-html",code:`<img${p}
|
|
9
|
-
src="${t.asset.publicPath}"
|
|
10
|
-
/>`,name:"Plain Image"}),u.value&&r.push({lang:"vue-html",code:`<NuxtImage${p}
|
|
11
|
-
src="${t.asset.publicPath}"
|
|
12
|
-
/>`,name:"Nuxt Image",docs:"https://image.nuxtjs.org/components/nuxt-img"},{lang:"vue-html",code:`<NuxtPicture${p}
|
|
13
|
-
src="${t.asset.publicPath}"
|
|
14
|
-
/>`,name:"Nuxt Picture",docs:"https://image.nuxtjs.org/components/nuxt-picture"}),r}return r.push({lang:"html",code:`<a download href="${t.asset.publicPath}">
|
|
15
|
-
Download ${t.asset.path.split("/").slice(-1)[0]}
|
|
16
|
-
</a>`,name:"Download link"}),r}),L=ve(),B=re(()=>t.asset.mtime),M=y(()=>{const r=t.asset.size;return r<1024?`${r} B`:r<1024*1024?`${(r/1024).toFixed(2)} KB`:`${(r/1024/1024).toFixed(2)} MB`}),x=y(()=>{if(!l.value?.width||!l.value?.height)return"";const r=(A,$)=>$?r($,A%$):A,p=r(l.value.width,l.value.height);return p>3?`${l.value.width/p}:${l.value.height/p}`:""}),h=y(()=>["image","text","video","font"].includes(t.asset.type));return(r,p)=>{const A=Z,$=fe,D=K,I=W,a=he;return s(),c("div",Ve,[n(h)?(s(),c(N,{key:0},[Xe,e("div",Ke,[f(A,{"max-h-80":"","min-h-20":"","min-w-20":"","w-auto":"",rounded:"",border:"~ base",asset:o.asset,"text-content":n(g)},null,8,["asset","text-content"])])],64)):S("",!0),qe,e("table",Ge,[e("tbody",null,[e("tr",null,[We,e("td",null,[e("div",Ze,[f($,{filepath:o.asset.filePath,"text-left":""},null,8,["filepath"]),f(D,{"flex-none":"",title:"Open in Editor",icon:"carbon-launch",onClick:p[0]||(p[0]=_=>n(m)(o.asset.filePath))})])])]),e("tr",null,[Qe,e("td",null,[e("div",Ye,[e("div",He,w(o.asset.publicPath),1),f(D,{"flex-none":"",title:"Copy public path",icon:"carbon-copy",onClick:p[1]||(p[1]=_=>n(L)(o.asset.publicPath))}),f(D,{"flex-none":"",to:o.asset.publicPath,icon:"carbon-launch",target:"_blank",title:"Open in browser"},null,8,["to"])])])]),e("tr",null,[Je,e("td",et,w(o.asset.type),1)]),n(l)?.width?(s(),c(N,{key:0},[e("tr",null,[tt,e("td",null,w(n(l).width)+" x "+w(n(l).height),1)]),n(x)?(s(),c("tr",nt,[st,e("td",null,w(n(x)),1)])):S("",!0)],64)):S("",!0),e("tr",null,[ot,e("td",null,w(n(M)),1)]),e("tr",null,[at,e("td",null,[E(w(new Date(o.asset.mtime).toLocaleString())+" ",1),e("span",it,"("+w(n(B))+")",1)])])])]),lt,e("div",rt,[f(I,{to:o.asset.publicPath,download:"",target:"_blank",icon:"carbon-download"},{default:z(()=>[E(" Download ")]),_:1},8,["to"]),o.asset.type==="image"?(s(),F(I,{key:0,disabled:"",icon:"carbon-image-service"},{default:z(()=>[E(" Optimize image (Coming soon) ")]),_:1})):S("",!0)]),ct,n(C).length?(s(),F(a,{key:1,border:"t base","mx--4":"","mb--4":"","code-snippets":n(C)},null,8,["code-snippets"])):S("",!0)])}}}),dt={"h-full":"","of-auto":""},pt={"flex-none":"",flex:"~ gap2 items-center"},mt={op50:""},ft={key:0},ht={"mt--4":"",px2:"",grid:"~ cols-minmax-8rem"},_t={key:1,p2:"",grid:"~ cols-minmax-8rem"},vt={key:1},It=j({__name:"assets",setup(o){const t=ce(),m=T(""),l=y(()=>new ue(t.value||[],{keys:["path"]})),g=y(()=>m.value?l.value.search(m.value).map(h=>h.item):t.value||[]),k=y(()=>{const x={};for(const h of g.value){const r=`${h.path.split("/").slice(0,-1).join("/")}/`;x[r]||(x[r]=[]),x[r].push(h)}return Object.entries(x).sort(([h],[r])=>h.localeCompare(r))}),u=T(),C=T("grid");function L(){C.value=C.value==="list"?"grid":"list"}de("Escape",()=>{u.value=void 0});const B=T();function M(){}return(x,h)=>{const r=K,p=H,A=De,$=Me,D=me,I=Re,a=ut,_=ge;return s(),c("div",dt,[f(p,{ref_key:"navbar",ref:B,search:n(m),"onUpdate:search":h[0]||(h[0]=i=>pe(m)?m.value=i:null),pb2:""},{actions:z(()=>[e("div",pt,[f(r,{"text-lg":"",icon:n(C)==="grid"?"i-carbon-list":"i-carbon-grid",title:"Toggle view",onClick:L},null,8,["icon"])])]),default:z(()=>[e("div",mt,[n(m)?(s(),c("span",ft,w(n(g).length)+" matched · ",1)):S("",!0),e("span",null,w(n(t)?.length)+" assets in total",1)])]),_:1},8,["search"]),f(A,{folder:"/",onUploaded:M}),n(C)==="grid"?(s(),c(N,{key:0},[n(k).length>1?(s(!0),c(N,{key:0},O(n(k),([i,v])=>(s(),F(D,{key:i,text:i,description:`${v.length} items`,open:v.length<=("DETAILS_MAX_ITEMS"in x?x.DETAILS_MAX_ITEMS:n(xe)),padding:!1},{default:z(()=>[e("div",ht,[(s(!0),c(N,null,O(v,d=>(s(),F($,{key:d.path,asset:d,folder:i,onClick:b=>u.value=d},null,8,["asset","folder","onClick"]))),128))])]),_:2},1032,["text","description","open"]))),128)):(s(),c("div",_t,[(s(!0),c(N,null,O(n(g),i=>(s(),F($,{key:i.path,asset:i,onClick:v=>u.value=i},null,8,["asset","onClick"]))),128))]))],64)):(s(),c("div",vt,[(s(!0),c(N,null,O(n(g),i=>(s(),F(I,{key:i.path,asset:i,onClick:v=>u.value=i},null,8,["asset","onClick"]))),128))])),f(_,{"model-value":!!n(u),"auto-close":"","w-120":"",navbar:n(B),onClose:h[1]||(h[1]=i=>u.value=void 0)},{default:z(()=>[n(u)?(s(),F(a,{key:0,asset:n(u)},null,8,["asset"])):S("",!0)]),_:1},8,["model-value","navbar"])])}}});export{It as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{_ as E}from"./NPanelGrids.24e40025.js";import{a as C,a0 as M,r as g,p as w,af as B,ag as N,a3 as T,ah as V,ai as f,aj as $,ak as I,h as L,o as s,E as W,D as A,al as D,u as t,c as d,w as h,aa as O,f as c,l as y,t as k,y as P,i as S,a6 as q}from"./entry.34446c1f.js";import{_ as R}from"./LaunchPage.vue.dff3dd39.js";import"./NMarkdown.vue.00fc3014.js";import"./client.d93a636c.js";const b=new Map,U=C({__name:"IframeView",props:{tab:{}},setup(x){const p=x,l=M(),r=g(),u=w(()=>p.tab.name),e=g(),n=B(N(r));T(()=>{const o=p.tab.view,i=o.persistent!==!1,j=["clipboard-write","clipboard-read"];if(b.get(u.value)&&i)e.value=b.get(u.value),e.value.style.visibility="visible";else{e.value=document.createElement("iframe"),e.value.setAttribute("allow",j.join("; ")),i&&b.set(u.value,e.value),e.value.src=o.src;try{e.value.style.opacity="0.01",e.value.onload=()=>{v(),a(),e.value.style.opacity="1"}}catch{e.value.style.opacity="1"}document.body.appendChild(e.value),V(_)}setTimeout(a,100)}),f(_),f(a),f(v),$(()=>{e.value&&(e.value.style.visibility="hidden")});function a(){if(!(!e.value||!e.value.contentWindow))try{const o=e.value.contentWindow.document.querySelector("html");o?.classList.toggle("dark",l.value==="dark"),o?.classList.toggle("light",l.value==="dark"),new MutationObserver(()=>{l.value=e.value?.contentWindow?.document.querySelector("html")?.classList.contains("dark")?"dark":"light"}).observe(o,{attributes:!0,attributeFilter:["class"]})}catch{}}const m=I();function v(){if(!(!e.value||!e.value.contentWindow))try{e.value.contentWindow.__NUXT_DEVTOOLS__=m.value}catch{}}function _(){e.value&&Object.assign(e.value.style,{position:"fixed",left:`${n.left}px`,top:`${n.top}px`,width:`${n.width}px`,height:`${n.height}px`,outline:"none"})}return(o,i)=>(s(),L("div",{ref_key:"anchor",ref:r,"h-full":"","w-full":""},null,512))}}),F={flex:"~ col gap2",mxa:"","items-center":""},G=c("div",{"i-carbon-queued":"",mb2:"","text-5xl":"",op50:""},null,-1),X={"text-xl":""},z={"text-rose":""},H=c("p",{op50:""}," It might because the module contributing this tab is not installed or enabled ",-1),J=c("p",{mt8:"","animate-pulse":""}," Redirecting to overview page... ",-1),oe=C({__name:"custom-[name]",setup(x){const p=W(),l=A(),r=w(()=>p.params.name),u=D(),e=w(()=>u.value.find(n=>n.name===r.value));return T(()=>{e.value||setTimeout(()=>{e.value||l.push("/modules/overview")},2e3)}),(n,a)=>{const m=E,v=U,_=R,o=q;return t(e)?t(e).view.type==="iframe"?(s(),d(v,{key:1,tab:t(e)},null,8,["tab"])):t(e).view.type==="vnode"?(s(),d(O(t(e).view.vnode),{key:2})):t(e).view.type==="launch"?(s(),d(_,{key:3,icon:t(e).view.icon||t(e).icon,title:t(e).view.title||t(e).title,description:t(e).view.description,actions:t(e).view.actions,onAction:a[0]||(a[0]=i=>("rpc"in n?n.rpc:t(P)).customTabAction(t(e).name,i))},null,8,["icon","title","description","actions"])):(s(),d(m,{key:4},{default:h(()=>[S(o,{flex:"~ col","h-full":"","items-center":"","justify-center":""},{default:h(()=>[y(" Unknown tab type "+k(t(e).view),1)]),_:1})]),_:1})):(s(),d(m,{key:0},{default:h(()=>[c("div",F,[G,c("p",X,[y(" Tab "),c("code",z,k(t(r)),1),y(" not found ")]),H,J])]),_:1}))}}});export{oe as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{U as u,b7 as c,D as d,y as l,b8 as p,M as b}from"./entry.34446c1f.js";function v(){const i=u(),e=c(),n=d();return async o=>{const t=i.value?.buildDir,r=t&&o.startsWith(t)?`#build${o.slice(t.length).replace(/\.\w+$/,"")}`:o,a=e.value?.entries.find(s=>s.path===r||s.id===r)||e.value?.entries.find(s=>s.path===o||s.id===o);a?n.push(`/modules/virtual-files?id=${encodeURIComponent(a.id)}`):await l.openInEditor(o)}}function m(){const i=p(),e=b();return n=>{i.copy(n),e("Copied to clipboard","carbon-checkmark")}}export{m as a,v as u};
|