@nuxt/devtools 1.0.8 → 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (170) hide show
  1. package/README.md +2 -2
  2. package/dist/chunks/module-main.mjs +99 -34
  3. package/dist/chunks/vite-inspect.mjs +1 -1
  4. package/dist/chunks/vscode.mjs +1 -1
  5. package/dist/chunks/vue-devtools.mjs +30 -0
  6. package/dist/client/200.html +35 -35
  7. package/dist/client/404.html +35 -35
  8. package/dist/client/_nuxt/2bKi2e5w.js +1 -0
  9. package/dist/client/_nuxt/8EggbMwu.js +1 -0
  10. package/dist/client/_nuxt/9xk-6Ftp.js +1 -0
  11. package/dist/client/_nuxt/A1WiD9SJ.js +1 -0
  12. package/dist/client/_nuxt/B9hwBRIe.js +1 -0
  13. package/dist/client/_nuxt/BDWyeyq_.js +30 -0
  14. package/dist/client/_nuxt/BEjaWloH.js +1 -0
  15. package/dist/client/_nuxt/BIG-xU8F.js +1 -0
  16. package/dist/client/_nuxt/BMDCUlkj.js +1 -0
  17. package/dist/client/_nuxt/BOnTdqFq.js +1 -0
  18. package/dist/client/_nuxt/BVYSsK7b.js +1 -0
  19. package/dist/client/_nuxt/BZ4OC5-6.js +1 -0
  20. package/dist/client/_nuxt/BZ5b_UHE.js +1 -0
  21. package/dist/client/_nuxt/Ba4DdyWR.js +1 -0
  22. package/dist/client/_nuxt/Bdtkoq5_.js +1 -0
  23. package/dist/client/_nuxt/BgkphNq2.js +1 -0
  24. package/dist/client/_nuxt/{open-graph.ibydGna7.js → BkuzPiAP.js} +2 -2
  25. package/dist/client/_nuxt/Blr6EMNg.js +16 -0
  26. package/dist/client/_nuxt/BnqTDRTQ.js +1 -0
  27. package/dist/client/_nuxt/{components.bafJJWkk.js → Buf8bEqg.js} +1 -1
  28. package/dist/client/_nuxt/{terminals.WAexfEk0.js → C3QlK_7B.js} +1 -1
  29. package/dist/client/_nuxt/C54XRc8l.js +2 -0
  30. package/dist/client/_nuxt/C5gCGmDW.js +200 -0
  31. package/dist/client/_nuxt/C6khTLBN.js +2 -0
  32. package/dist/client/_nuxt/{modules.7QVx6VBW.js → C9nlvRuE.js} +2 -2
  33. package/dist/client/_nuxt/CB59kvvk.js +1 -0
  34. package/dist/client/_nuxt/CD_YezWg.js +1 -0
  35. package/dist/client/_nuxt/CMLG2-wm.js +1 -0
  36. package/dist/client/_nuxt/CXHl10-y.js +1 -0
  37. package/dist/client/_nuxt/CXNvZAmn.js +1 -0
  38. package/dist/client/_nuxt/CXiebJPP.js +1 -0
  39. package/dist/client/_nuxt/CY8m9THH.js +1 -0
  40. package/dist/client/_nuxt/C_MnmfmV.js +1 -0
  41. package/dist/client/_nuxt/CbViG2Xw.js +74 -0
  42. package/dist/client/_nuxt/{css.a-KJtBLB.js → CbYhyuC0.js} +347 -347
  43. package/dist/client/_nuxt/{vue.c6DnC5ch.js → Cd6DbZRp.js} +1518 -1518
  44. package/dist/client/_nuxt/ChqQx1p4.js +1 -0
  45. package/dist/client/_nuxt/CrUxNsPP.js +1 -0
  46. package/dist/client/_nuxt/{onig.mBJmD8D5.js → CsTmP73Z.js} +1 -1
  47. package/dist/client/_nuxt/CtILACI6.js +48 -0
  48. package/dist/client/_nuxt/CtdhE1f3.js +1 -0
  49. package/dist/client/_nuxt/CupVZNk8.js +25 -0
  50. package/dist/client/_nuxt/CwIrUz6t.js +9 -0
  51. package/dist/client/_nuxt/CyGasit_.js +1 -0
  52. package/dist/client/_nuxt/D4f0f7UU.js +1 -0
  53. package/dist/client/_nuxt/D89IPr06.js +1 -0
  54. package/dist/client/_nuxt/DBpZLuBg.js +1 -0
  55. package/dist/client/_nuxt/{typescript.b1Nw_bQe.js → DC8MraHL.js} +489 -489
  56. package/dist/client/_nuxt/DDNphti6.js +16 -0
  57. package/dist/client/_nuxt/DDu9F5dm.js +1 -0
  58. package/dist/client/_nuxt/DE14FQNr.js +2 -0
  59. package/dist/client/_nuxt/DEHAvi9d.js +982 -0
  60. package/dist/client/_nuxt/DN9uS3r9.js +1 -0
  61. package/dist/client/_nuxt/DRyh6x-M.js +1 -0
  62. package/dist/client/_nuxt/DW-UQrvA.js +4 -0
  63. package/dist/client/_nuxt/DZNF9_Ts.js +1 -0
  64. package/dist/client/_nuxt/D_qxg9CZ.js +1 -0
  65. package/dist/client/_nuxt/{javascript.Of8SnKfU.js → Dch3xQiY.js} +509 -509
  66. package/dist/client/_nuxt/DdbkFw3c.js +1 -0
  67. package/dist/client/_nuxt/DfFJQbG4.js +8 -0
  68. package/dist/client/_nuxt/DggdVF2v.js +1 -0
  69. package/dist/client/_nuxt/DnNA5yXt.js +1 -0
  70. package/dist/client/_nuxt/DnXIYXpO.js +1 -0
  71. package/dist/client/_nuxt/DwPRkQcZ.js +1 -0
  72. package/dist/client/_nuxt/Elk39DYk.js +1 -0
  73. package/dist/client/_nuxt/LysmJLvR.js +1 -0
  74. package/dist/client/_nuxt/QRQ0ln8W.js +1 -0
  75. package/dist/client/_nuxt/Z8_3SdCx.js +1 -0
  76. package/dist/client/_nuxt/builds/latest.json +1 -1
  77. package/dist/client/_nuxt/builds/meta/ca0a12b4-0fff-4e13-ae05-41075030e4de.json +1 -0
  78. package/dist/client/_nuxt/{error.U9HBYLgA.js → e8Aij11V.js} +1 -1
  79. package/dist/client/_nuxt/entry.C4Fmc-BV.css +1 -0
  80. package/dist/client/_nuxt/hRYdrzP_.js +1 -0
  81. package/dist/client/_nuxt/pinia.uD6MMfzP.css +1 -0
  82. package/dist/client/_nuxt/tH7Oq52e.js +1 -0
  83. package/dist/client/_nuxt/ud_P3M-F.js +1 -0
  84. package/dist/client/_nuxt/vzR1DB7b.js +105 -0
  85. package/dist/client/_nuxt/z8NVlzAs.js +1 -0
  86. package/dist/client/index.html +35 -35
  87. package/dist/module.json +1 -1
  88. package/dist/module.mjs +1 -1
  89. package/dist/runtime/plugins/view/FrameBox.vue +26 -25
  90. package/dist/runtime/plugins/view/client.mjs +1 -5
  91. package/dist/runtime/vue-devtools/overlay.d.mts +1 -0
  92. package/dist/runtime/vue-devtools/overlay.mjs +6 -0
  93. package/dist/shared/{devtools.fc176ede.mjs → devtools.68e43ed6.mjs} +10 -0
  94. package/package.json +45 -41
  95. package/dist/client/_nuxt/CodeDiff.vue.yvGsYwMX.js +0 -3
  96. package/dist/client/_nuxt/ComposableItem.vue.T22_QMe3.js +0 -1
  97. package/dist/client/_nuxt/DataSchemaButton.vue.kfghTUAM.js +0 -1
  98. package/dist/client/_nuxt/DataSchemaDrawer.pFnTVL_R.js +0 -1000
  99. package/dist/client/_nuxt/DurationDisplay.vue.zHxKl3h_.js +0 -1
  100. package/dist/client/_nuxt/FilepathItem.vue.e1n0RyHZ.js +0 -1
  101. package/dist/client/_nuxt/HelpFab.vue.9P-8iMDH.js +0 -1
  102. package/dist/client/_nuxt/LaunchPage.vue.Mrnd5FUf.js +0 -1
  103. package/dist/client/_nuxt/NBadge.02P0N0hm.js +0 -1
  104. package/dist/client/_nuxt/NCheckbox.vue.m1__cenQ.js +0 -1
  105. package/dist/client/_nuxt/NCodeBlock.vue.D7jhLEjr.js +0 -2
  106. package/dist/client/_nuxt/NDrawer.vue.biTr62KW.js +0 -1
  107. package/dist/client/_nuxt/NDropdown.vue.sigVLPdp.js +0 -1
  108. package/dist/client/_nuxt/NIconTitle.vue.B_Ui7cce.js +0 -1
  109. package/dist/client/_nuxt/NLink.vue.Bj0qXc3J.js +0 -1
  110. package/dist/client/_nuxt/NMarkdown.vue.Ej8wmZFm.js +0 -1
  111. package/dist/client/_nuxt/NNavbar.vue.VnwEajb6.js +0 -1
  112. package/dist/client/_nuxt/NSectionBlock.vAf-kGVD.js +0 -1
  113. package/dist/client/_nuxt/NSelect.vue.zI1gfDpy.js +0 -1
  114. package/dist/client/_nuxt/NSelectTabs.vue.AydEyuDp.js +0 -1
  115. package/dist/client/_nuxt/NSwitch.vue.b9xL28U5.js +0 -1
  116. package/dist/client/_nuxt/StacktraceList.vue.K3UX7GrW.js +0 -1
  117. package/dist/client/_nuxt/StateEditor.vue.XC13TBO8.js +0 -1
  118. package/dist/client/_nuxt/__blank.4nEfHodO.js +0 -1
  119. package/dist/client/_nuxt/analyze-build.PnmanOmc.js +0 -1
  120. package/dist/client/_nuxt/assets.4NpI16LC.js +0 -16
  121. package/dist/client/_nuxt/builds/meta/6a0559dc-da71-46a5-8a3c-8d631ecd5320.json +0 -1
  122. package/dist/client/_nuxt/client.UdRQ7dYn.js +0 -1
  123. package/dist/client/_nuxt/custom-_name_.i-QCiHcq.js +0 -1
  124. package/dist/client/_nuxt/default.64CCr6pQ.js +0 -1
  125. package/dist/client/_nuxt/entry.AC_HBPW1.css +0 -1
  126. package/dist/client/_nuxt/entry.Li7bMdxw.js +0 -48
  127. package/dist/client/_nuxt/error-404.uYSk40lm.js +0 -1
  128. package/dist/client/_nuxt/error-500._o_7fJYd.js +0 -1
  129. package/dist/client/_nuxt/full.WnKVk-q6.js +0 -1
  130. package/dist/client/_nuxt/hooks.5KumR8Qp.js +0 -1
  131. package/dist/client/_nuxt/html.0DSFJ4KV.js +0 -74
  132. package/dist/client/_nuxt/imports.-jRZwNS0.js +0 -1
  133. package/dist/client/_nuxt/index.9SQHhWq3.js +0 -16
  134. package/dist/client/_nuxt/index._ARgFaAV.js +0 -1
  135. package/dist/client/_nuxt/json-editor-vue.qZEps2wJ.js +0 -105
  136. package/dist/client/_nuxt/json.t1qiHl76.js +0 -25
  137. package/dist/client/_nuxt/none.du_ft3bP.js +0 -1
  138. package/dist/client/_nuxt/overview.Vfo3spsD.js +0 -1
  139. package/dist/client/_nuxt/pages.OsyANSwf.js +0 -1
  140. package/dist/client/_nuxt/payload.LvslHyQ-.js +0 -1
  141. package/dist/client/_nuxt/plugins.-waaP_qB.js +0 -1
  142. package/dist/client/_nuxt/runtime-configs.6C1y42GJ.js +0 -1
  143. package/dist/client/_nuxt/server-routes.8nS5VL6V.js +0 -9
  144. package/dist/client/_nuxt/settings.Aj2LNb0U.js +0 -1
  145. package/dist/client/_nuxt/shellscript.h1L64xId.js +0 -4
  146. package/dist/client/_nuxt/state-components.PdQ1tKRe.js +0 -1
  147. package/dist/client/_nuxt/state-modules.ZsAhN2-A.js +0 -1
  148. package/dist/client/_nuxt/storage-options.-PhoDnIp.js +0 -1
  149. package/dist/client/_nuxt/storage.4TsT27Mw.js +0 -1
  150. package/dist/client/_nuxt/timeline.M76ZIEAr.js +0 -30
  151. package/dist/client/_nuxt/unocss-runtime.PEXBUXPL.js +0 -2
  152. package/dist/client/_nuxt/vanilla-picker-NKbIFE8h.vtyeXros.js +0 -8
  153. package/dist/client/_nuxt/virtual-files.NKByCwiv.js +0 -1
  154. package/dist/client/_nuxt/vitesse-dark.5VceXvs6.js +0 -1
  155. package/dist/client/_nuxt/vitesse-light.HOMMxGxw.js +0 -1
  156. package/dist/client/_nuxt/vue-html.KfgsLQjp.js +0 -1
  157. package/dist/client/_nuxt/yaml.FtfhlYqU.js +0 -200
  158. /package/dist/client/_nuxt/{constants.jFgWOlQV.js → BcJws1i5.js} +0 -0
  159. /package/dist/client/_nuxt/{nuxt-docs.83FO1Cbd.js → D5r6TWiw.js} +0 -0
  160. /package/dist/client/_nuxt/{diff.-l9-nN5b.js → DvyTQcux.js} +0 -0
  161. /package/dist/client/_nuxt/{HelpFab.x07F_IqA.css → HelpFab.DHTsX8io.css} +0 -0
  162. /package/dist/client/_nuxt/{NCodeBlock.XH4dGkTz.css → NCodeBlock.Bcfh0aRP.css} +0 -0
  163. /package/dist/client/_nuxt/{NSectionBlock.a3MwpCxg.css → NSectionBlock.BrczCkLG.css} +0 -0
  164. /package/dist/client/_nuxt/{assets.xk970LH3.css → assets.DGT3vQsf.css} +0 -0
  165. /package/dist/client/_nuxt/{error-404.m36D2jj-.css → error-404.CbfoPaOP.css} +0 -0
  166. /package/dist/client/_nuxt/{error-500.oAiyMzGs.css → error-500.CgCLIzMa.css} +0 -0
  167. /package/dist/client/_nuxt/{open-graph.PgUMoob_.css → open-graph.-BQyihv8.css} +0 -0
  168. /package/dist/client/_nuxt/{terminals.GzwV8rXv.css → terminals.bPBXyte9.css} +0 -0
  169. /package/dist/client/_nuxt/{timeline.7wyW2pbe.css → timeline.DvDJbalt.css} +0 -0
  170. /package/dist/client/_nuxt/{virtual-files.lmRDNyeH.css → virtual-files.CWZEM3J4.css} +0 -0
@@ -1,25 +0,0 @@
1
- const n=Object.freeze({displayName:"JSON",name:"json",patterns:[{include:"#value"}],repository:{array:{begin:"\\[",beginCaptures:{0:{name:"punctuation.definition.array.begin.json"}},end:"\\]",endCaptures:{0:{name:"punctuation.definition.array.end.json"}},name:"meta.structure.array.json",patterns:[{include:"#value"},{match:",",name:"punctuation.separator.array.json"},{match:"[^\\s\\]]",name:"invalid.illegal.expected-array-separator.json"}]},comments:{patterns:[{begin:"/\\*\\*(?!/)",captures:{0:{name:"punctuation.definition.comment.json"}},end:"\\*/",name:"comment.block.documentation.json"},{begin:"/\\*",captures:{0:{name:"punctuation.definition.comment.json"}},end:"\\*/",name:"comment.block.json"},{captures:{1:{name:"punctuation.definition.comment.json"}},match:"(//).*$\\n?",name:"comment.line.double-slash.js"}]},constant:{match:"\\b(?:true|false|null)\\b",name:"constant.language.json"},number:{match:`(?x) # turn on extended mode
2
- -? # an optional minus
3
- (?:
4
- 0 # a zero
5
- | # ...or...
6
- [1-9] # a 1-9 character
7
- \\d* # followed by zero or more digits
8
- )
9
- (?:
10
- (?:
11
- \\. # a period
12
- \\d+ # followed by one or more digits
13
- )?
14
- (?:
15
- [eE] # an e character
16
- [+-]? # followed by an option +/-
17
- \\d+ # followed by one or more digits
18
- )? # make exponent optional
19
- )? # make decimal portion optional`,name:"constant.numeric.json"},object:{begin:"\\{",beginCaptures:{0:{name:"punctuation.definition.dictionary.begin.json"}},end:"\\}",endCaptures:{0:{name:"punctuation.definition.dictionary.end.json"}},name:"meta.structure.dictionary.json",patterns:[{comment:"the JSON object key",include:"#objectkey"},{include:"#comments"},{begin:":",beginCaptures:{0:{name:"punctuation.separator.dictionary.key-value.json"}},end:"(,)|(?=\\})",endCaptures:{1:{name:"punctuation.separator.dictionary.pair.json"}},name:"meta.structure.dictionary.value.json",patterns:[{comment:"the JSON object value",include:"#value"},{match:"[^\\s,]",name:"invalid.illegal.expected-dictionary-separator.json"}]},{match:"[^\\s\\}]",name:"invalid.illegal.expected-dictionary-separator.json"}]},objectkey:{begin:'"',beginCaptures:{0:{name:"punctuation.support.type.property-name.begin.json"}},end:'"',endCaptures:{0:{name:"punctuation.support.type.property-name.end.json"}},name:"string.json support.type.property-name.json",patterns:[{include:"#stringcontent"}]},string:{begin:'"',beginCaptures:{0:{name:"punctuation.definition.string.begin.json"}},end:'"',endCaptures:{0:{name:"punctuation.definition.string.end.json"}},name:"string.quoted.double.json",patterns:[{include:"#stringcontent"}]},stringcontent:{patterns:[{match:`(?x) # turn on extended mode
20
- \\\\ # a literal backslash
21
- (?: # ...followed by...
22
- ["\\\\/bfnrt] # one of these characters
23
- | # ...or...
24
- u # a u
25
- [0-9a-fA-F]{4}) # and four hex digits`,name:"constant.character.escape.json"},{match:"\\\\.",name:"invalid.illegal.unrecognized-string-escape.json"}]},value:{patterns:[{include:"#constant"},{include:"#number"},{include:"#string"},{include:"#array"},{include:"#object"},{include:"#comments"}]}},scopeName:"source.json"});var e=[n];export{e as default};
@@ -1 +0,0 @@
1
- import{q as r,aa as n}from"./entry.Li7bMdxw.js";const t={};function o(e,s){return n(e.$slots,"default")}const c=r(t,[["render",o]]);export{c as default};
@@ -1 +0,0 @@
1
- import{d as V,au as L,ab as M,aJ as R,b5 as T,b6 as E,P,a as w,h as m,j as n,A as O,o as s,f as e,l as c,p as t,i,t as r,n as l,F as h,b7 as f,b8 as x,b9 as $,v as a,aE as F,D as W,M as G,E as H,x as K,Y as J,_ as U}from"./entry.Li7bMdxw.js";import{u as Y,_ as q}from"./state-modules.ZsAhN2-A.js";import{u as Q}from"./state-components.PdQ1tKRe.js";import"./NBadge.02P0N0hm.js";import"./NCodeBlock.vue.D7jhLEjr.js";import"./client.UdRQ7dYn.js";import"./NCheckbox.vue.m1__cenQ.js";const X="1.0.8",Z={key:0},tt={key:1,flex:"~ col gap2",ma:"","h-full":"","max-w-300":"","w-full":"",p5:"",px5:"","md:px20":""},et=t("div",{"flex-auto":""},null,-1),ot={flex:"~ col","mt-5":"","items-center":"","md:mt-20":""},nt=t("span",{op40:""}," Nuxt DevTools ",-1),st={op40:""},at={flex:"~ gap2 wrap"},it=t("div",{"logos-nuxt-icon":"","text-3xl":""},null,-1),lt=t("div",{"logos-vue":"","text-3xl":""},null,-1),ut=t("div",{"carbon-tree-view-alt":"","text-3xl":""},null,-1),rt=t("div",{"i-carbon-assembly-cluster":"","text-3xl":""},null,-1),dt=t("div",{"carbon-function":"","text-3xl":""},null,-1),ct=t("div",{"carbon-3d-mpr-toggle":"","text-3xl":""},null,-1),pt=t("div",{"carbon-plug":"","text-3xl":""},null,-1),_t={key:5,"pointer-events-none":"","min-w-40":"",p4:"","theme-card-lime":"",flex:"~ auto gap-6"},mt=t("div",{"i-carbon-time-plot":"","flex-none":"","text-3xl":""},null,-1),ht={grid:"~ cols-[auto_auto] gap-x-5 items-center"},ft=t("div",{"text-sm":""}," SSR to full load ",-1),xt={"text-right":""},vt=t("div",{"text-sm":""}," Page load ",-1),gt={"text-right":""},bt=t("div",{"text-sm":""}," Navigation ",-1),kt={"text-right":""},yt=t("div",{"text-sm":""}," HMR ",-1),Ct={"text-right":""},wt={flex:"~ col gap2"},Dt={flex:"~ gap-6 wrap","mt-5":"","items-center":"","justify-center":""},Bt=t("a",{href:"https://github.com/nuxt/devtools",target:"_blank",flex:"~ gap1","items-center":"",op50:"",hover:"op100 text-blue",transition:""},[t("div",{"i-carbon-star":""}),a(" Star on GitHub ")],-1),St=t("a",{href:"https://github.com/nuxt/devtools/discussions/29",target:"_blank",flex:"~ gap1","items-center":"",op50:"",hover:"op100 text-yellow",transition:""},[t("div",{"i-carbon-data-enrichment":""}),a(" Ideas & Suggestions ")],-1),zt=t("a",{href:"https://github.com/nuxt/devtools/discussions/31",target:"_blank",flex:"~ gap1","items-center":"",op50:"",hover:"op100 text-lime",transition:""},[t("div",{"i-carbon-plan":""}),a(" Project Roadmap ")],-1),Nt=t("a",{href:"https://github.com/nuxt/devtools/issues",target:"_blank",flex:"~ gap1","items-center":"",op50:"",hover:"op100 text-rose",transition:""},[t("div",{"i-carbon-debug":""}),a(" Bug Reports ")],-1),At=t("div",{"i-carbon-settings-adjust":""},null,-1),jt=t("div",{"flex-auto":""},null,-1),It={flex:"col gap-2",mxa:"",hidden:"","w-100":"","text-sm":"",op50:"","md:flex":""},Vt={flex:"~ gap-1","items-center":""},Lt=t("span",null,"+",-1),Mt=t("span",null,"+",-1),Rt=t("div",{"flex-auto":""},null,-1),Tt={flex:"~ gap-1","items-center":""},Et=t("span",null,"+",-1),Pt=t("span",null,"+",-1),Ot=t("span",null,"+",-1),$t=t("span",null,"+",-1),Ft=t("div",{"flex-auto":""},null,-1),Wt=t("div",null,"Toggle DevTools",-1),Zt=V({__name:"overview",setup(Gt){const v=L(),p=M(),D=Q(),g=R(),B=Y(),S=T(),b=E(),z=P();function N(){W.value=!0,z.push("/")}const k=w(()=>v.value?.nuxt.vueApp.version),u=w(()=>v.value?.metrics.loading());function A(){G()}return(o,Ht)=>{const j=H,_=K,y=q,C=J,d=U,I=O;return s(),m(I,{"h-screen":"","w-full":"",flex:""},{default:n(()=>[e(p)?(s(),c("div",tt,[et,t("div",ot,[i(_,{flex:"~","mt--10":"","items-center":"","justify-center":"",to:"https://devtools.nuxt.com/",target:"_blank"},{default:n(()=>[i(j,{"h-10":""})]),_:1}),t("button",{mb6:"",mt3:"","text-center":"","text-sm":"",flex:"~ gap-1 wrap",onClick:N},[nt,t("code",st,"v"+r(e(X)),1),i(y,{"package-name":"@nuxt/devtools",options:{dev:!0},"show-version":!1})])]),t("div",at,[i(_,{to:"https://nuxt.com",target:"_blank",p4:"","theme-card-green":"",flex:"~ col auto"},{default:n(()=>[it,i(y,{"package-name":"nuxt",options:{dev:!0}})]),_:1}),e(k)?(s(),m(_,{key:0,to:"https://vuejs.org",target:"_blank",p4:"","theme-card-green":"",flex:"~ col auto"},{default:n(()=>[lt,t("code",null,"v"+r(e(k)),1)]),_:1})):l("",!0),e(p)?(s(),c(h,{key:1},[e(p)&&e(p).pages&&e(v)?(s(),m(_,{key:0,"min-w-40":"",p4:"","theme-card-lime":"",flex:"~ col auto",to:"/modules/pages"},{default:n(()=>[ut,t("div",null,r(("pluralizeByCount"in o?o.pluralizeByCount:e(f))(e(S).length,"page")),1)]),_:1})):l("",!0),e(p)?(s(),m(_,{key:1,"min-w-40":"",p4:"","theme-card-lime":"",flex:"~ col auto",to:"/modules/components"},{default:n(()=>[rt,t("div",null,r(("pluralizeByCount"in o?o.pluralizeByCount:e(f))(e(D).length,"component")),1)]),_:1})):l("",!0),e(p)&&e(g)?(s(),m(_,{key:2,"min-w-40":"",p4:"","theme-card-yellow":"",flex:"~ col auto",to:"/modules/imports"},{default:n(()=>[dt,t("div",null,r(("pluralizeByCount"in o?o.pluralizeByCount:e(f))(e(g).imports.length,"import")),1)]),_:1})):l("",!0),e(p)?(s(),m(_,{key:3,"min-w-40":"",p4:"","theme-card-purple":"",flex:"~ col auto",to:"/modules/modules"},{default:n(()=>[ct,t("div",null,r(("pluralizeByCount"in o?o.pluralizeByCount:e(f))(e(B).length,"module")),1)]),_:1})):l("",!0),e(p)?(s(),m(_,{key:4,"min-w-40":"",p4:"","theme-card-teal":"",flex:"~ col auto",to:"/modules/plugins"},{default:n(()=>[pt,t("div",null,r(("pluralizeByCount"in o?o.pluralizeByCount:e(f))(e(p).plugins.length,"plugin")),1)]),_:1})):l("",!0),e(u)?(s(),c("div",_t,[mt,t("div",ht,[e(u).ssrStart?(s(),c(h,{key:0},[ft,t("div",xt,r(("formatDuration"in o?o.formatDuration:e(x))(e(u).appLoad-e(u).ssrStart)),1)],64)):l("",!0),vt,t("div",gt,r(("formatDuration"in o?o.formatDuration:e(x))(e(u).appLoad-e(u).appInit)),1),bt,t("div",kt,r(("formatDuration"in o?o.formatDuration:e(x))(e(u).pageEnd-e(u).pageStart)),1),e(u).hmrStart?(s(),c(h,{key:1},[yt,t("div",Ct,r(("formatDuration"in o?o.formatDuration:e(x))(e(u).hmrEnd-e(u).hmrStart)),1)],64)):l("",!0)])])):l("",!0)],64)):l("",!0)]),t("div",wt,[("showConnectionWarning"in o?o.showConnectionWarning:e($))?(s(),m(C,{key:0,n:"yellow5",icon:"carbon-unlink","justify-center":""},{default:n(()=>[a(" Not connected to the client app, showing server-side data only. Use the embedded mode for full features. ")]),_:1})):l("",!0),t("button",{title:"Authorize",onClick:A},[("isDevAuthed"in o?o.isDevAuthed:e(F))?l("",!0):(s(),m(C,{key:0,n:"orange5",icon:"i-carbon-locked","justify-center":""},{default:n(()=>[a(" Access from an untrusted browser, some features are limited. Click to authorize now. ")]),_:1}))])]),t("div",Dt,[Bt,St,zt,Nt,i(_,{to:"/settings",flex:"~ gap1","inline-block":"","items-center":"",op50:"","hover:op80":""},{default:n(()=>[At,a(" Settings ")]),_:1})]),jt,t("div",It,[t("div",Vt,[e(b)?(s(),c(h,{key:0},[i(d,{n:"xs",class:"px2"},{default:n(()=>[a(" ⌘ Cmd ")]),_:1}),Lt,i(d,{n:"xs",class:"px2"},{default:n(()=>[a(" K ")]),_:1})],64)):(s(),c(h,{key:1},[i(d,{n:"xs",class:"px2"},{default:n(()=>[a(" Ctrl ")]),_:1}),Mt,i(d,{n:"xs",class:"px2"},{default:n(()=>[a(" K ")]),_:1})],64)),Rt,a(" Open Command Palette ")]),t("div",Tt,[e(b)?(s(),c(h,{key:0},[i(d,{n:"xs",class:"px2"},{default:n(()=>[a(" ⇧ Shift ")]),_:1}),Et,i(d,{n:"xs",class:"px2"},{default:n(()=>[a(" ⌥ Option ")]),_:1}),Pt,i(d,{n:"xs",class:"px2"},{default:n(()=>[a(" D ")]),_:1})],64)):(s(),c(h,{key:1},[i(d,{n:"xs",class:"px2"},{default:n(()=>[a(" Shift ")]),_:1}),Ot,i(d,{n:"xs",class:"px2"},{default:n(()=>[a(" Alt ")]),_:1}),$t,i(d,{n:"xs",class:"px2"},{default:n(()=>[a(" D ")]),_:1})],64)),Ft,Wt])])])):(s(),c("div",Z," Loading... "))]),_:1})}}});export{Zt as default};
@@ -1 +0,0 @@
1
- import{d as B,r as T,a as k,ap as W,f as t,o,l as s,p as e,t as $,h as y,j as x,bf as G,F as v,m as M,n as P,v as L,i as h,G as E,X as A,_ as H,ac as X,bg as D,b1 as q,b2 as J,ab as Q,am as Y,b3 as Z,an as ee,k as te,ae as oe,L as ne,M as ae}from"./entry.Li7bMdxw.js";import{_ as j}from"./NBadge.02P0N0hm.js";import{_ as F}from"./FilepathItem.vue.e1n0RyHZ.js";import{_ as se}from"./NSectionBlock.vAf-kGVD.js";import{_ as re}from"./LaunchPage.vue.Mrnd5FUf.js";import{_ as le}from"./HelpFab.vue.9P-8iMDH.js";import"./NIconTitle.vue.B_Ui7cce.js";import"./NMarkdown.vue.Ej8wmZFm.js";import"./client.UdRQ7dYn.js";const ie={block:"","cursor-pointer":""},ue={p2:""},ce=["onSubmit"],de=e("div",{px2:"","text-sm":"",op50:""}," Fill params and navigate: ",-1),pe={flex:"~","items-center":"",p2:"","text-sm":"","font-mono":""},_e={key:1},he=B({__name:"RoutePathItem",props:{route:{}},emits:["navigate"],setup(V,{emit:i}){const d=V,w=i,m=T([]),p=k(()=>{const u=N(d.route.path);return m.value=Array.from({length:u.length},()=>""),u});function N(u){return u.split(/(:\w+[\?\*]?(?:\(\))?)/).filter(Boolean).map(_=>_[0]===":"?_.replace(/\(\)$/,"?"):_)}const r=k(()=>p.value.map((u,_)=>u[0]===":"?m.value[_]:u).join("").replace(/\/+/g,"/")),n=k(()=>d.route.path.includes(":"));function f(){w("navigate",r.value)}return(u,_)=>{const a=A,l=H,c=W("VDropdown");return t(n)?(o(),y(c,{key:1},{popper:x(({hide:g})=>[e("div",ue,[e("form",{flex:"~ col",onSubmit:G(()=>{f(),g()},["prevent"])},[t(n)?(o(),s(v,{key:0},[de,e("div",pe,[(o(!0),s(v,null,M(t(p),(b,R)=>(o(),s(v,{key:R},[b[0]===":"?(o(),y(a,{key:0,modelValue:t(m)[R],"onUpdate:modelValue":I=>t(m)[R]=I,"w-20":"","n-sm":"",placeholder:b.slice(1)},null,8,["modelValue","onUpdate:modelValue","placeholder"])):(o(),s("span",_e,$(b),1))],64))),128))])],64)):P("",!0),h(l,{block:"",n:"primary"},{default:x(()=>[L(" Navigate ")]),_:1})],40,ce)])]),default:x(()=>[e("code",ie,[(o(!0),s(v,null,M(t(p),(g,b)=>(o(),s("span",{key:b,class:E(g[0]===":"?"text-gray border border-dashed rounded border-gray:50 px1":"")},$(g[0]===":"?g.slice(1):g),3))),128))])]),_:1})):(o(),s("button",{key:0,onClick:f},[e("code",null,$(u.route.path),1)]))}}}),me={"w-full":""},fe=e("thead",{border:"b base"},[e("tr",null,[e("th",{"text-left":""}),e("th",{"text-left":""}," Route Path "),e("th",{"text-left":""}," Name "),e("th",{"text-left":""}," Middleware "),e("th",null," Layout ")])],-1),ge={"w-20":"","pr-1":""},ve={flex:"","items-center":"","justify-end":""},ye={"text-sm":""},be={flex:"inline gap3","items-center":""},xe={op0:"","group-hover:op100":"",flex:"~ gap1"},ke=["onClick"],$e=e("div",{"i-carbon-script-reference":""},null,-1),we=[$e],Ne={"w-0":"","ws-nowrap":"","pr-1":"","text-left":"","text-sm":"","font-mono":"",op50:""},Re={"w-0":"","ws-nowrap":"","pr-1":"","text-center":"","text-sm":"","font-mono":"",op50:""},Ce={"w-0":"","ws-nowrap":"","text-center":"","text-sm":"","font-mono":""},Pe={key:0},Ve=["onClick"],Ie=B({__name:"RoutesTable",props:{pages:{},layouts:{},matched:{},matchedPending:{}},emits:["navigate"],setup(V){const i=V,d=X(),w=D(),m=k(()=>[...i.pages].sort((r,n)=>r.path.localeCompare(n.path)));function p(r){const n=i.layouts.find(f=>f.name===r);n&&d(n.file)}function N(r){if(typeof r=="string")return w.value?.middleware.find(n=>n.name===r)?.path}return(r,n)=>{const f=j,u=he,_=F;return o(),s("div",null,[e("table",me,[fe,e("tbody",null,[(o(!0),s(v,null,M(t(m),a=>(o(),s("tr",{key:a.name,class:"group","h-7":"",border:"b dashed transparent hover:base"},[e("td",ge,[e("div",ve,[r.matched.find(l=>l.name===a.name)?(o(),y(f,{key:0,n:"green",title:"active",textContent:"active"})):r.matchedPending.find(l=>l.name===a.name)?(o(),y(f,{key:1,n:"teal",title:"next",textContent:"next"})):P("",!0)])]),e("td",ye,[e("div",be,[h(u,{route:a,class:E(r.matched.find(l=>l.name===a.name)?"text-primary":r.matchedPending.find(l=>l.name===a.name)?"text-teal":""),onNavigate:n[0]||(n[0]=l=>r.$emit("navigate",l))},null,8,["route","class"]),e("div",xe,[a.file||a.meta?.file?(o(),s("button",{key:0,"text-sm":"",op40:"",hover:"op100 text-primary",title:"Open in editor",onClick:l=>t(d)(a.file||a.meta?.file)},we,8,ke)):P("",!0)])])]),e("td",Ne,$(a.name),1),e("td",Re,[h(_,{filepath:N(a.meta.middleware),override:`${a.meta.middleware||"-"}`},null,8,["filepath","override"])]),e("td",Ce,[a.meta.layout===!1?(o(),s("span",Pe,"-")):a.meta.layout?(o(),s("button",{key:1,onClick:l=>p(a.meta.layout)},$(a.meta.layout),9,Ve)):(o(),s("button",{key:2,"text-sm":"",op15:"",onClick:n[1]||(n[1]=l=>p("default"))}," (default) "))])]))),128))])])])}}}),Le={class:"markdown-body"},Me=e("h1",null,"Pages",-1),Te=e("p",null,[L("Nuxt provides a file-based routing to create routes within your web application using Vue Router under the hood. Pages are Vue components and can have any valid extension that Nuxt supports (by default .vue, .js, .jsx, .mjs, .ts or .tsx). Nuxt will automatically create a route for every page in your "),e("code",null,"~/pages/"),L(" directory.")],-1),Be=e("p",null,[e("a",{href:"https://nuxt.com/docs/getting-started/routing",target:"_blank",rel:"noopener"},"Learn more in the documentation")],-1),Ee=e("hr",null,null,-1),Ae=e("h1",null,"Middlewares",-1),De=e("p",null,"Nuxt provides a customizable route middleware framework that can be used throughout the application. This is ideal for extracting code that needs to run before navigating to a particular route.",-1),je=e("p",null,[e("a",{href:"https://nuxt.com/docs/guide/directory-structure/middleware",target:"_blank",rel:"noopener"},"Learn more in the documentation")],-1),Fe=[Me,Te,Be,Ee,Ae,De,je],Se={__name:"pages",setup(V,{expose:i}){return i({frontmatter:{}}),(w,m)=>(o(),s("div",Le,Fe))}},ze={key:0,"h-full":"","of-auto":""},Ue={border:"b base",flex:"~ col gap1",px4:"",py3:"","n-navbar-glass":""},Ke=e("span",{op50:""},"Navigate from ",-1),Oe={"font-mono":""},We=e("span",{op50:""}," to ",-1),Ge={key:1,op50:""},He=e("span",null,[L("Press "),e("b",{"font-bold":""},"Enter"),L(" to navigate")],-1),Xe={key:0,"text-orange":"",op75:""},qe={key:1,op50:""},Je={"min-h-14":""},Qe={key:1,class:"py-4 text-center"},Ye=e("span",{op50:""},"No routes matched",-1),Ze=[Ye],et={"w-full":""},tt=e("thead",{border:"b base","h-7":""},[e("tr",null,[e("th",{"text-left":""}," Name "),e("th",{"text-left":""}," Path ")])],-1),ot={mr1:""},pt=B({__name:"pages",setup(V){const i=q(),d=J(),w=Q(),m=D(),p=Y(),N=Z(),r=k(()=>m.value?.middleware||[]),n=T(""),f=T(0),u=k(()=>(r.value,n.value,p.value,f.value,i.value?.currentRoute?.value?.path));ee(()=>{d.value&&(n.value=i.value?.currentRoute?.value?.path),i.value?.beforeEach(c=>{n.value=c.fullPath}),i.value?.afterEach(c=>{n.value=c.fullPath})});async function _(){n.value!==i.value?.currentRoute?.value?.path&&i.value.push(n.value||"/")}const a=k(()=>i.value.resolve(n.value||"/").matched);function l(c){i.value.push(c),n.value=c}return(c,g)=>{const b=A,R=Ie,I=se,S=j,z=F,U=re,K=Se,O=le;return o(),s(v,null,[t(w)?.pages&&t(i)?(o(),s("div",ze,[e("div",Ue,[e("div",null,[t(u)!==t(n)?(o(),s(v,{key:0},[Ke,e("span",Oe,$(t(u)),1),We],64)):(o(),s("span",Ge,"Current route"))]),h(b,{modelValue:t(n),"onUpdate:modelValue":g[0]||(g[0]=C=>te(n)?n.value=C:null),"font-mono":"",icon:"carbon-direction-right-01 scale-y--100",class:E(t(u)===t(n)?"":t(a).length?"text-green":"text-orange"),onKeydown:oe(_,["enter"])},null,8,["modelValue","class"]),e("div",null,[t(u)!==t(n)?(o(),s(v,{key:0},[He,t(a).length?P("",!0):(o(),s("span",Xe," (no match)"))],64)):(o(),s("span",qe,"Edit path above to navigate"))])]),h(I,{icon:"carbon-tree-view",text:"Matched Routes",padding:!1},{default:x(()=>[e("div",Je,[t(a).length?(o(),y(R,{key:0,pages:t(a),layouts:t(p)||[],matched:t(d).matched,"matched-pending":t(a),onNavigate:l},null,8,["pages","layouts","matched","matched-pending"])):(o(),s("div",Qe,Ze))])]),_:1}),h(I,{icon:"carbon-tree-view-alt",text:"All Routes",description:`${t(N).length} routes registered in your application`,padding:"pr5"},{default:x(()=>[h(R,{pages:t(N),layouts:t(p)||[],matched:t(d).matched,"matched-pending":t(a),onNavigate:l},null,8,["pages","layouts","matched","matched-pending"])]),_:1},8,["description"]),t(r).length?(o(),y(I,{key:0,icon:"carbon:ibm-watson-studio",text:"Middleware",description:`${t(r).length} middleware registered in your application`,padding:"px13"},{default:x(()=>[e("table",et,[tt,(o(!0),s(v,null,M(t(r),C=>(o(),s("tr",{key:C.path,"h-7":""},[e("td",null,[e("span",ot,$(C.name),1),C.global?(o(),y(S,{key:0,n:"green",title:"Registered at runtime as a global component",textContent:"global"})):P("",!0)]),e("td",null,[h(z,{filepath:C.path},null,8,["filepath"])])]))),128))])]),_:1},8,["description"])):P("",!0)])):(o(),y(U,{key:1,icon:"carbon-tree-view-alt",name:"wizard-pages",title:"Nuxt Routing",description:"Create `./pages/index.vue` to enable routing",actions:[{label:"Learn more",src:"https://nuxt.com/docs/getting-started/routing",attrs:{n:"primary"}},{label:"Enable Routing",async handle(){return("rpc"in c?c.rpc:t(ne)).runWizard(await("ensureDevAuthToken"in c?c.ensureDevAuthToken:t(ae))(),"enablePages")}}]},null,8,["actions"])),h(O,null,{default:x(()=>[h(K)]),_:1})],64)}}});export{pt as default};
@@ -1 +0,0 @@
1
- import{_ as v}from"./StateEditor.vue.XC13TBO8.js";import{d as b,o as e,l as c,F as k,m as C,h as f,j as o,bh as N,bi as B,aa as w,p as x,au as F,a as O,a2 as P,f as r,i as a,n as u,v as R,I as V,_ as j}from"./entry.Li7bMdxw.js";import{_ as E}from"./NSectionBlock.vAf-kGVD.js";import{_ as A}from"./HelpFab.vue.9P-8iMDH.js";import"./DataSchemaButton.vue.kfghTUAM.js";import"./json-editor-vue.qZEps2wJ.js";import"./NIconTitle.vue.B_Ui7cce.js";const G={key:0,flex:"~ col gap-1"},H={key:1,mt2:"",px4:"",italic:"",op35:""},K=b({__name:"StateGroup",props:{state:{},prefix:{default:""}},setup(m){return(t,n)=>{const i=v;return e(),c("div",null,[t.state&&Object.keys(t.state).length>0?(e(),c("div",G,[(e(!0),c(k,null,C(t.state,(l,s)=>(e(),f(i,{key:s,state:l,name:s.startsWith(t.prefix)?s.slice(t.prefix.length):s},{actions:o(_=>[w(t.$slots,"actions",B(N(_)))]),_:2},1032,["state","name"]))),128))])):(e(),c("div",H," No data "))])}}}),T={class:"markdown-body"},z=x("h1",null,"State & Async Data",-1),I=x("p",null,"// TODO",-1),L=[z,I],W={__name:"payload",setup(m,{expose:t}){return t({frontmatter:{}}),(i,l)=>(e(),c("div",T,L))}},q={key:0},et=b({__name:"payload",setup(m){const t=F(),n=O(()=>t.value?.nuxt.payload);async function i(l){await t.value?.nuxt.hooks.callHookParallel("app:data:refresh",l)}return(l,s)=>{const _=K,d=E,h=j,$=v,S=W,g=A,D=P("tooltip");return e(),c(k,null,[r(t)?(e(),c("div",q,[a(d,{icon:"carbon-data-set",text:"State",description:"Keyed state from `useState`",padding:!1},{default:o(()=>[a(_,{state:r(n).state,prefix:"$s"},null,8,["state"])]),_:1}),a(d,{icon:"carbon-data-blob",text:"Data",description:"Keyed state from `useAsyncData`",padding:!1},{actions:o(()=>[a(h,{n:"xs primary","self-start":"",icon:"i-carbon-recycle",onClick:s[0]||(s[0]=y=>i())},{default:o(()=>[R(" Re-fetch all data ")]),_:1})]),default:o(()=>[a(_,{state:r(n).data},{actions:o(({isOpen:y,name:p})=>[y&&p?V((e(),f(h,{key:0,title:`Re-fetch '${p}'`,icon:"carbon-recycle",border:!1,onClick:J=>i([p])},null,8,["title","onClick"])),[[D,`Re-fetch '${p}'`,void 0,{bottom:!0}]]):u("",!0)]),_:1},8,["state"])]),_:1}),r(n).functions&&Object.keys(r(n).functions).length?(e(),f(d,{key:0,icon:"carbon-function",text:"Functions",description:"State for functions"},{default:o(()=>[a($,{"ml--6":"",state:r(n).functions},null,8,["state"])]),_:1})):u("",!0)])):u("",!0),a(g,null,{default:o(()=>[a(S)]),_:1})],64)}}});export{et as default};
@@ -1 +0,0 @@
1
- import{_ as S}from"./FilepathItem.vue.e1n0RyHZ.js";import{_ as D}from"./NBadge.02P0N0hm.js";import{_ as C}from"./DurationDisplay.vue.zHxKl3h_.js";import{d as v,ab as B,a as x,be as V,o as n,l as m,p as t,t as P,i as l,f,h as u,n as d,ap as F,aa as N,a6 as H,q as I,j as g,v as y,bg as E,au as W,F as k,m as j,G as L}from"./entry.Li7bMdxw.js";import{_ as M}from"./NSectionBlock.vAf-kGVD.js";import{_ as q}from"./HelpFab.vue.9P-8iMDH.js";import"./NIconTitle.vue.B_Ui7cce.js";const z={flex:"~ gap2","items-center":""},A={w8:"","text-right":"","text-sm":"",op25:""},G={key:0,"flex-auto":"","text-right":""},R=v({__name:"PluginItem",props:{plugin:{},index:{}},setup(p){const e=p,a=B(),r=x(()=>V(e.plugin.src,a.value?.rootDir||"").path);return(i,c)=>{const _=S,o=D,s=C;return n(),m("div",z,[t("div",A,P(i.index),1),l(_,{filepath:e.plugin.src,subpath:!0},null,8,["filepath"]),t("div",null,[f(r).startsWith("#")?(n(),u(o,{key:0,n:"rose",textContent:"virtual"})):f(r).startsWith(".")?d("",!0):(n(),u(o,{key:1,n:"gray",textContent:"module"})),i.plugin.mode==="server"?(n(),u(o,{key:2,n:"teal",textContent:"server"})):d("",!0),i.plugin.mode==="client"?(n(),u(o,{key:3,n:"orange",textContent:"client"})):d("",!0)]),i.plugin.metric?.duration!=null?(n(),m("div",G,[l(s,{duration:i.plugin.metric?.duration,factor:10},null,8,["duration"])])):d("",!0)])}}}),Y={class:"n-tip n-tip-base",flex:"~ col items-start","mx--4":"",px4:"",py4:""},J={flex:"~ items-center gap-1","font-bold":""},K=v({__name:"HelpTip",props:{title:{},icon:{}},setup(p){return(e,a)=>{const r=H,i=F("ContentSlot");return n(),m("div",Y,[t("div",J,[e.icon?(n(),u(r,{key:0,icon:e.icon,class:"n-tip-icon"},null,8,["icon"])):d("",!0),t("div",null,P(e.title),1)]),t("div",null,[N(e.$slots,"default",{},()=>[l(i,{use:e.$slots.default,unwrap:"p"},null,8,["use"])])])])}}}),O={};function Q(p,e){const a=K;return n(),u(a,{title:"Performance Tip",icon:"carbon-meter",n:"lime6 dark:lime5"},{default:g(()=>[N(p.$slots,"default")]),_:3})}const U=I(O,[["render",Q]]),X={class:"markdown-body"},Z=t("h1",null,"Plugins",-1),tt=t("p",null,[y("Nuxt plugins allow you to extend the functionality of the Nuxt runtime and the Vue instance. You can add plugins to the "),t("code",null,"plugins/"),y(" directory and they will be automatically imported and registered.")],-1),et=t("p",null,[t("a",{href:"https://nuxt.com/docs/guide/directory-structure/plugins",target:"_blank",rel:"noopener"},"Learn more in the documentation")],-1),nt={__name:"plugins",setup(p,{expose:e}){return e({frontmatter:{}}),(r,i)=>{const c=U;return n(),m("div",X,[Z,tt,l(c,null,{default:g(()=>[y(" Plugins always run before your application's runtime. The loading time of each plugin will directly impact your application's initial loading time. ")]),_:1}),et])}}},ot={pt4:""},st={class:"text-sm",flex:"~ gap-1 items-center justify-start","mt-3":""},it=t("div",{"i-carbon-timer":"","text-lg":"",op75:""},null,-1),at=t("span",{op50:""},"Total execution time:",-1),dt=v({__name:"plugins",setup(p){const e=E(),a=W(),r=x(()=>{const c=e.value?.plugins||[],_=a.value?.metrics.clientPlugins()||[];return c.map(o=>{const s=typeof o=="string"?{src:o}:o;return{...s,metric:_.find(h=>h.src===s.src||h.src.startsWith(s.src))}})}),i=x(()=>{const c=a.value?.metrics.clientPlugins()||[],_=Math.min(...c.map(s=>s.start));return Math.max(...c.map(s=>s.end))-_});return(c,_)=>{const o=R,s=C,h=M,T=nt,w=q;return n(),m(k,null,[l(h,{icon:"carbon-plug",text:"Plugins",description:`Total plugins: ${f(r).length}`},{default:g(()=>[t("div",ot,[(n(!0),m(k,null,j(f(r),($,b)=>(n(),u(o,{key:$.src,plugin:$,index:b+1,"ml--4":"","border-base":"",py2:"",class:L(b?"border-t":"")},null,8,["plugin","index","class"]))),128)),t("div",st,[it,at,l(s,{duration:f(i),factor:10},null,8,["duration"])])])]),_:1},8,["description"]),l(w,null,{default:g(()=>[l(T)]),_:1})],64)}}});export{dt as default};
@@ -1 +0,0 @@
1
- import{_ as v}from"./StateEditor.vue.XC13TBO8.js";import{_ as x}from"./NSectionBlock.vAf-kGVD.js";import{o as r,l as u,p as e,v as d,d as y,au as b,bj as C,a as m,f as i,i as t,j as a,n as k,F as w}from"./entry.Li7bMdxw.js";import{_ as N}from"./HelpFab.vue.9P-8iMDH.js";import"./DataSchemaButton.vue.kfghTUAM.js";import"./json-editor-vue.qZEps2wJ.js";import"./NIconTitle.vue.B_Ui7cce.js";const R={class:"markdown-body"},T=e("h1",null,"Runtime Configs",-1),B=e("p",null,"Nuxt provides a runtime config API to expose configuration within your application and server routes, with the ability to update it at runtime by setting environment variables.",-1),V=e("p",null,[d("In Nuxt DevTools, the editor allows you to edit the runtime config temporarily to see how the changes affect your application. To update them, you might want to update your "),e("code",null,"nuxt.config.js"),d(" file, or check more details in the documentation.")],-1),$=e("p",null,[e("a",{href:"https://nuxt.com/docs/guide/going-further/runtime-config",target:"_blank",rel:"noopener"},"Learn more in the documentation")],-1),j=[T,B,V,$],D={__name:"runtime-configs",setup(f,{expose:o}){return o({frontmatter:{}}),(p,_)=>(r(),u("div",R,j))}},F={key:0},z=y({__name:"runtime-configs",setup(f){const o=b(),l=C(),p=m(()=>o.value?.nuxt.payload),_=m(()=>{const n={...l.value};return delete n.public,delete n.app,n});return(n,P)=>{const s=v,c=x,g=D,h=N;return r(),u(w,null,[i(o)?(r(),u("div",F,[t(c,{icon:"carbon-settings-services",text:"App Config",padding:!1},{default:a(()=>[t(s,{state:i(o).app.appConfig},null,8,["state"])]),_:1}),t(c,{icon:"carbon-settings",text:"Public Runtime Config",padding:!1},{default:a(()=>[t(s,{state:i(p).config?.public},null,8,["state"])]),_:1}),t(c,{icon:"i-carbon-code-signing-service",text:"Private Runtime Config",open:!1,padding:!1,description:"These values are not exposed to the client. Readonly in the DevTools."},{default:a(()=>[t(s,{state:i(_),readonly:""},null,8,["state"])]),_:1})])):k("",!0),t(h,null,{default:a(()=>[t(g)]),_:1})],64)}}});export{z as default};
@@ -1,9 +0,0 @@
1
- import{d as ie,r as B,bm as Te,o as a,l as _,p as c,G as L,h as x,f as e,bn as re,t as A,n as I,v as J,a9 as Qe,aa as te,F as N,m as M,a6 as he,a0 as Xe,a as R,w as Ve,i as b,j as $,X as Re,_ as ye,bo as Ue,bp as je,ay as Ye,bq as Ze,br as et,bs as tt,bt as ot,ab as nt,au as st,aw as me,ac as at,az as lt,a_ as rt,bu as it,e as ut,a2 as De,k as Z,I as ee,at as dt,V as ct,A as Ee,bv as pt,bw as ft,ah as vt,U as mt,bx as ht,ao as yt}from"./entry.Li7bMdxw.js";import{_ as bt}from"./NNavbar.vue.VnwEajb6.js";import{_ as Ie}from"./NBadge.02P0N0hm.js";import{_ as Ne}from"./NSelect.vue.zI1gfDpy.js";import{_ as gt}from"./NCheckbox.vue.m1__cenQ.js";import{u as Oe,_ as _t}from"./storage-options.-PhoDnIp.js";import{_ as kt}from"./DataSchemaButton.vue.kfghTUAM.js";import{_ as wt}from"./NCodeBlock.vue.D7jhLEjr.js";import{C as xe,S as qe}from"./constants.jFgWOlQV.js";import{q as Ct}from"./json-editor-vue.qZEps2wJ.js";import{_ as xt}from"./NSectionBlock.vAf-kGVD.js";import{_ as St}from"./NDrawer.vue.biTr62KW.js";import"./client.UdRQ7dYn.js";import"./NIconTitle.vue.B_Ui7cce.js";const le=/^[\u0009\u0020-\u007E\u0080-\u00FF]+$/;function $t(t,l){if(typeof t!="string")throw new TypeError("argument str must be a string");const n={},h=(l||{}).decode||Rt;let w=0;for(;w<t.length;){const v=t.indexOf("=",w);if(v===-1)break;let y=t.indexOf(";",w);if(y===-1)y=t.length;else if(y<v){w=t.lastIndexOf(";",v-1)+1;continue}const r=t.slice(w,v).trim();if(n[r]===void 0){let p=t.slice(v+1,y).trim();p.codePointAt(0)===34&&(p=p.slice(1,-1)),n[r]=Vt(p,h)}w=y+1}return n}function Se(t,l,n){const o=n||{},h=o.encode||Ut;if(typeof h!="function")throw new TypeError("option encode is invalid");if(!le.test(t))throw new TypeError("argument name is invalid");const w=h(l);if(w&&!le.test(w))throw new TypeError("argument val is invalid");let v=t+"="+w;if(o.maxAge!==void 0&&o.maxAge!==null){const y=o.maxAge-0;if(Number.isNaN(y)||!Number.isFinite(y))throw new TypeError("option maxAge is invalid");v+="; Max-Age="+Math.floor(y)}if(o.domain){if(!le.test(o.domain))throw new TypeError("option domain is invalid");v+="; Domain="+o.domain}if(o.path){if(!le.test(o.path))throw new TypeError("option path is invalid");v+="; Path="+o.path}if(o.expires){if(!Tt(o.expires)||Number.isNaN(o.expires.valueOf()))throw new TypeError("option expires is invalid");v+="; Expires="+o.expires.toUTCString()}if(o.httpOnly&&(v+="; HttpOnly"),o.secure&&(v+="; Secure"),o.priority)switch(typeof o.priority=="string"?o.priority.toLowerCase():o.priority){case"low":v+="; Priority=Low";break;case"medium":v+="; Priority=Medium";break;case"high":v+="; Priority=High";break;default:throw new TypeError("option priority is invalid")}if(o.sameSite)switch(typeof o.sameSite=="string"?o.sameSite.toLowerCase():o.sameSite){case!0:v+="; SameSite=Strict";break;case"lax":v+="; SameSite=Lax";break;case"strict":v+="; SameSite=Strict";break;case"none":v+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return v}function Tt(t){return Object.prototype.toString.call(t)==="[object Date]"||t instanceof Date}function Vt(t,l){try{return l(t)}catch{return t}}function Rt(t){return t.includes("%")?decodeURIComponent(t):t}function Ut(t){return encodeURIComponent(t)}function W(t){if(typeof t!="object")return t;var l,n,o=Object.prototype.toString.call(t);if(o==="[object Object]"){if(t.constructor!==Object&&typeof t.constructor=="function"){n=new t.constructor;for(l in t)t.hasOwnProperty(l)&&n[l]!==t[l]&&(n[l]=W(t[l]))}else{n={};for(l in t)l==="__proto__"?Object.defineProperty(n,l,{value:W(t[l]),configurable:!0,enumerable:!0,writable:!0}):n[l]=W(t[l])}return n}if(o==="[object Array]"){for(l=t.length,n=Array(l);l--;)n[l]=W(t[l]);return n}return o==="[object Set]"?(n=new Set,t.forEach(function(h){n.add(W(h))}),n):o==="[object Map]"?(n=new Map,t.forEach(function(h,w){n.set(W(w),W(h))}),n):o==="[object Date]"?new Date(+t):o==="[object RegExp]"?(n=new RegExp(t.source,t.flags),n.lastIndex=t.lastIndex,n):o==="[object DataView]"?new t.constructor(W(t.buffer)):o==="[object ArrayBuffer]"?t.slice(0):o.slice(-6)==="Array]"?new t.constructor(t):t}const jt=c("div",{"x-divider":""},null,-1),Ae=ie({__name:"ServerRouteListItem",props:{item:{},index:{default:0}},setup(t){const l=B(!0),n=Te();return(o,h)=>{const w=he,v=Ie,y=Ae;return a(),_("div",null,[c("button",{flex:"~ gap-2","w-full":"","items-start":"","items-center":"","hover-bg-active":"",px2:"",py1:"",class:L([{"bg-active":e(n)===o.item.filepath}]),style:Qe({paddingLeft:`calc(0.5rem + ${o.index*1.5}em)`}),onClick:h[0]||(h[0]=r=>{l.value=!e(l),n.value=o.item.filepath})},[c("div",{class:L({"w-12":!o.item.routes}),"flex-none":"","text-left":""},[o.item.type==="collection"?(a(),x(w,{key:0,icon:"carbon:chevron-right","mb0.5":"","transform-rotate":e(l)?90:0,transition:""},null,8,["transform-rotate"])):(a(),x(v,{key:1,class:L(("getRequestMethodClass"in o?o.getRequestMethodClass:e(re))(o.item.method||"*")),textContent:A((o.item.method||"*").toUpperCase())},null,8,["class","textContent"]))],2),c("span",{class:L({"flex items-center":o.item.routes}),"text-sm":"","font-mono":""},[o.item.type==="collection"?(a(),x(w,{key:0,title:`${o.item.routes?.length} routes`,icon:"carbon:folder",mr1:""},null,8,["title"])):I("",!0),J(" "+A(o.item.route),1)],2)],6),jt,e(l)?te(o.$slots,"default",{key:0},()=>[(a(!0),_(N,null,M(o.item.routes,r=>(a(),x(y,{key:r.filepath,item:r,index:o.index+1},null,8,["item","index"]))),128))]):I("",!0)])}}}),Dt={p4:"",flex:"~ col gap-4"},Et={key:1,ml2:"",flex:""},It=["value"],Nt={key:0,flex:"","gap-4":""},Ot=c("div",{"flex-auto":""},null,-1),Le=ie({__name:"ServerRouteInputs",props:{modelValue:{},keys:{default:()=>[]},default:{default:()=>({})},disabled:{type:Boolean,default:!1}},setup(t,{emit:l}){const n=t,h=Xe(n,"modelValue",l,{passive:!0}),w=R(()=>[...n.keys,"active","key","value","type"]),v=R(()=>{const p={};for(const i of w.value)p[i]=n.default[i]||"";return p}),y=["string","number","boolean","file","date","time","datetime-local"];function r(p,i){const O=i.target;if(O.files&&O.files[0]){const F=O.files[0],H=new FileReader;H.readAsDataURL(F),H.onload=()=>{h.value[p].value=H.result}}}return Ve(()=>h,p=>{p.value.forEach(i=>{if(i.type==="number"&&typeof i.value!="number"){const O=Number.parseFloat(i.value);i.value=Number.isNaN(O)?0:O}else i.type==="boolean"&&typeof i.value!="boolean"?i.value=!0:i.type==="file"&&typeof i.value!="object"?i.value="":i.type==="date"&&typeof i.value=="string"&&!i.value.match(/^\d{4}-\d{2}-\d{2}$/)?i.value=new Date().toISOString().slice(0,10):i.type==="time"&&typeof i.value=="string"&&!i.value.match(/^\d{2}:\d{2}$/)?i.value=new Date().toISOString().slice(11,16):i.type==="datetime-local"&&typeof i.value=="string"&&!i.value.match(/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}$/)?i.value=new Date().toISOString().slice(0,16):i.type==="string"&&(i.value=i.value.toString())})},{deep:!0,immediate:!0,flush:"sync"}),(p,i)=>{const O=gt,F=Re,H=Ne,U=he,C=ye;return a(),_("div",Dt,[(a(!0),_(N,null,M(e(h),(g,S)=>(a(),_("div",{key:S,flex:"~ gap-2","justify-around":""},[te(p.$slots,"input",{item:g}),(a(!0),_(N,null,M(e(w),f=>(a(),_(N,{key:f},[g.type!==null&&f==="active"?(a(),x(O,{key:0,modelValue:g[f],"onUpdate:modelValue":k=>g[f]=k,n:"sm primary",disabled:p.disabled},null,8,["modelValue","onUpdate:modelValue","disabled"])):I("",!0),g.type!==null&&f==="key"?(a(),x(F,{key:1,modelValue:g[f],"onUpdate:modelValue":k=>g[f]=k,placeholder:f,"flex-1":"","font-mono":"",n:"sm primary",disabled:p.disabled,class:L(p.disabled?"op50":"")},null,8,["modelValue","onUpdate:modelValue","placeholder","disabled","class"])):f==="value"?(a(),_(N,{key:2},[g.type==="file"?(a(),x(F,{key:0,type:"file",disabled:p.disabled,class:L(p.disabled?"op75":""),onChange:k=>r(S,k)},null,8,["disabled","class","onChange"])):g.type==="boolean"?(a(),_("div",Et,[b(O,{modelValue:g.value,"onUpdate:modelValue":k=>g.value=k,placeholder:"Value",n:"green lg",disabled:p.disabled},null,8,["modelValue","onUpdate:modelValue","disabled"])])):(a(),x(F,{key:2,modelValue:g.value,"onUpdate:modelValue":k=>g.value=k,type:g.type,placeholder:"Value","flex-1":"","font-mono":"",n:"sm primary",disabled:p.disabled,class:L(p.disabled?"op75":"")},null,8,["modelValue","onUpdate:modelValue","type","disabled","class"]))],64)):f==="type"?(a(),x(H,{key:3,modelValue:g.type,"onUpdate:modelValue":k=>g.type=k,n:"sm green",class:L(p.disabled?"op75":""),disabled:p.disabled},{default:$(()=>[(a(),_(N,null,M(y,k=>c("option",{key:k,value:k},A(k),9,It)),64))]),_:2},1032,["modelValue","onUpdate:modelValue","class","disabled"])):I("",!0)],64))),128)),te(p.$slots,"input-actions",{},()=>[b(C,{n:"red",disabled:p.disabled,class:L(p.disabled?"op0!":""),onClick:f=>e(h).splice(S,1)},{default:$(()=>[b(U,{icon:"carbon:trash-can"})]),_:2},1032,["disabled","class","onClick"])])]))),128)),p.disabled?I("",!0):(a(),_("div",Nt,[te(p.$slots,"actions",{params:e(h)},()=>[b(C,{icon:"carbon-add",n:"sm primary",my1:"","px-3":"",onClick:i[0]||(i[0]=g=>e(h).push({...e(v)}))},{default:$(()=>[J(" Add ")]),_:1}),Ot,e(h).length?(a(),x(C,{key:0,icon:"carbon-trash-can",n:"sm red",my1:"","px-3":"",onClick:i[1]||(i[1]=g=>h.value=[])},{default:$(()=>[J(" Remove All ")]),_:1})):I("",!0)])])),te(p.$slots,"default")])}}}),qt={path:"/",watch:!0,decode:t=>et(decodeURIComponent(t)),encode:t=>encodeURIComponent(typeof t=="string"?t:JSON.stringify(t))};function At(t,l){const n={...qt,...l},o=Lt(n)||{};let h;n.maxAge!==void 0?h=n.maxAge*1e3:n.expires&&(h=n.expires.getTime()-Date.now());const w=h!==void 0&&h<=0,v=W(w?void 0:o[t]??n.default?.()),y=h&&!w?Mt(v,h):B(v);{const r=typeof BroadcastChannel>"u"?null:new BroadcastChannel(`nuxt:cookies:${t}`),p=()=>{n.readonly||tt(y.value,o[t])||(Bt(t,y.value,n),r?.postMessage(n.encode(y.value)))};let i=!1;Ue()&&je(()=>{i=!0,p(),r?.close()}),r&&(r.onmessage=O=>{i=!0,o[t]=y.value=n.decode(O.data),Ye(()=>{i=!1})}),n.watch?Ve(y,()=>{i||p()},{deep:n.watch!=="shallow"}):p()}return y}function Lt(t={}){return $t(document.cookie,t)}function Pt(t,l,n={}){return l==null?Se(t,l,{...n,maxAge:-1}):Se(t,l,n)}function Bt(t,l,n={}){document.cookie=Pt(t,l,n)}const $e=2147483647;function Mt(t,l){let n,o=0;return Ue()&&je(()=>{clearTimeout(n)}),Ze((h,w)=>{function v(){clearTimeout(n);const y=l-o,r=y<$e?y:$e;n=setTimeout(()=>{if(o+=r,o<l)return v();t=void 0,w()},r)}return{get(){return h(),t},set(y){v(),t=y,w()}}})}const Ft={"h-full":"","w-full":"",flex:"~ col"},zt={flex:"~ col gap-2","flex-none":"",p4:"","n-navbar-glass":""},Ht={flex:"~ gap2 items-center"},Gt={relative:"","w-full":""},Wt={absolute:"","right-2":"","top-1.5":"",flex:"~ gap-1"},Jt={flex:"~ gap2 wrap","w-full":"","items-center":"",px4:"",pb2:"","text-center":"","text-sm":"",border:"b base"},Kt={class:"hidden md:block"},Qt=c("div",{"flex-auto":""},null,-1),Xt=c("div",{"text-xs":"",op50:""}," Send from ",-1),Yt=c("option",{value:"app"}," App ",-1),Zt=c("option",{value:"devtools"}," DevTools ",-1),eo={key:0,border:"b base","items-center":"",px4:"",py2:"",grid:"~ cols-[max-content_1fr] gap-2"},to={"text-right":"","font-mono":""},oo={key:1,border:"b base",p4:"",flex:"~ col gap-4","font-mono":""},no={flex:"~ gap-4"},so={flex:"~ gap2","mb--2":"","items-center":"",op50:""},ao=c("div",{"w-5":"","x-divider":""},null,-1),lo=c("div",{"flex-none":""}," Default Inputs ",-1),ro=c("div",{"x-divider":""},null,-1),io={key:2},uo={key:3,border:"b base",relative:"","n-code-block":""},co={flex:"~ wrap","w-full":""},po=["onClick"],fo=c("div",{border:"b base","flex-auto":""},null,-1),vo={border:"b base",flex:"~ gap2","items-center":"",px4:"",py2:""},mo=c("div",null,"Response",-1),ho={key:1,"text-xs":"",op50:""},yo=c("div",{"flex-auto":""},null,-1),bo=c("div",{op50:""}," Request finished in ",-1),go={key:0,"flex-auto":"","overflow-auto":""},_o={border:"~ base","h-full":"","w-full":"",rounded:""},ko=["data"],wo={key:2,"flex-auto":"","overflow-auto":"",p4:""},Co={border:"~ base",rounded:""},xo=["src"],So={key:1,controls:"",rounded:""},$o=["src"],To=ie({__name:"ServerRouteDetails",props:{route:{}},emits:["open-default-input"],setup(t,{emit:l}){const n=t,o=l,[h,w]=ot(),v=nt(),y=st(),r=me({contentType:"text/plain",data:"",statusCode:200,error:void 0,fetchTime:0}),p=R(()=>r.contentType.includes("application/json")?"json":r.contentType.includes("text/html")?"html":r.contentType.includes("text/css")?"css":r.contentType.includes("text/javascript")?"javascript":r.contentType.includes("image")||r.contentType.includes("video")?"media":r.contentType.includes("text/xml")||r.contentType.includes("application/xml")?"xml":r.contentType.includes("application/pdf")?"pdf":"text"),i=R(()=>{if(p.value==="json")return JSON.stringify(r.data,null,2);if(p.value==="media"||p.value==="pdf"){const s=new Blob([r.data],{type:r.contentType});return URL.createObjectURL(s)}return r.data}),O=B(!1),F=B(!1),H=at(),U=R(()=>n.route.route?.split(/((?:\*\*)?:[\w_]+)/g)),C=R(()=>U.value?.filter(s=>s.startsWith(":")||s.startsWith("**:"))||[]),g=B(n.route.method||"GET"),S=B({}),f=me({query:[{active:!0,key:"",value:"",type:"string"}],body:[{active:!0,key:"",value:"",type:"string"}],headers:[{active:!0,key:"Content-Type",value:"application/json",type:"string"}]}),k=B({}),{inputDefaults:j,sendFrom:q}=Oe("serverRoutes"),P=R(()=>y?.value?.app?.$fetch?q.value:"devtools"),ue=["GET","POST","PUT","PATCH","DELETE","HEAD"],de=["PATCH","POST","PUT","DELETE"],oe=R(()=>de.includes(g.value.toUpperCase())),T=B(),D=["input","json"],G=B(D[0]),ne=R({get:()=>f[T.value],set:s=>{f[T.value]=s}}),be=R(()=>({...Q(j.value.query),...Q(f.query)})),ge=R(()=>({...Q(j.value.headers),...Q(f.headers)})),ce=R(()=>oe.value?G.value==="json"?{...Q(j.value.body),...k.value}:{...Q(j.value.body),...Q(f.body)}:void 0),Pe=R(()=>{let s=window?.location.origin;return s.charAt(s.length-1)==="/"&&(s=s.slice(0,-1)),s}),se=R(()=>{let s=new URLSearchParams(be.value).toString();s&&(s=`?${s}`);const d=(U.value?.map(E=>(E.startsWith(":")||E.startsWith("**:"))&&S.value[E]||E).join("")||"")+s;let m=v.value?.app.baseURL||"";return(m==="./"||m===".")&&(m=""),m.endsWith("/")&&(m=m.slice(0,-1)),m+d}),_e=R(()=>Pe.value+se.value);function Q(s){const d=Object.fromEntries(s.filter(({active:m,key:E,value:V})=>m&&E&&V!==void 0).map(({key:m,value:E})=>[m,E]));return Object.entries(d).length?d:void 0}async function ke(){F.value=!0,O.value=!0;const s=Date.now(),d=P.value==="app"?y.value.app.$fetch:$fetch;ct("server-routes:fetch",{method:g.value,sendFrom:P.value});try{r.data=await d(_e.value,{method:g.value.toUpperCase(),headers:ge.value,query:be.value,body:ce.value,onResponse({response:m}){r.contentType=(m.headers.get("content-type")||"").toString().toLowerCase().trim(),r.statusCode=m.status,r.error=void 0},onResponseError(m){r.error=m.response._data,r.data=m.response._data}})}catch{}O.value=!1,r.fetchTime=Date.now()-s}const we=R(()=>{const s=[],d=[],m=Object.entries(ge.value).filter(([V,z])=>V&&z&&!(V==="Content-Type"&&z==="application/json")).map(([V,z])=>` '${V}': '${z}'`).join(`,
2
- `);g.value.toUpperCase()!=="GET"&&d.push(`method: '${g.value.toUpperCase()}'`),m&&d.push(`headers: {
3
- ${m}
4
- }`),ce.value&&d.push(`body: ${JSON.stringify(ce.value,null,2)}`);const E=d.length?`, {
5
- ${d.join(`,
6
- `).split(`
7
- `).map(V=>` ${V}`).join(`
8
- `)}
9
- }`:"";return s.push({name:"useFetch",lang:"javascript",docs:xe.nuxt.useFetch,code:`const { data, pending, error, refresh } = useFetch('${se.value}'${E})`}),s.push({name:"$fetch",lang:"javascript",docs:xe.nuxt.$fetch,code:`await $fetch('${se.value}'${E})`}),s}),X=B(Me()),K=me({key:"",value:""}),Be=R(()=>{const s=[];return C.value.length&&s.push({name:"Params",slug:"params",length:C.value.length}),s.push({name:"Query",slug:"query",length:f.query.length}),oe.value&&s.push({name:"Body",slug:"body",length:f.body.length}),s.push({name:"Headers",slug:"headers",length:f.headers.length}),s.push({name:"Cookies",slug:"cookies",length:X.value.length}),s.push({name:"Snippets",slug:"snippet"}),s});function Me(){return document.cookie.split("; ").map(s=>{const[d,m]=s.split("=");return{key:d,value:m}}).filter(s=>s.key)}function pe(s,d){if(!s)return;const m=X.value.find(V=>V.key===s),E=At(s);m!==void 0?d===void 0&&(X.value=X.value.filter(V=>V.key!==s)):(X.value.push({key:s,value:d}),K.key="",K.value=""),E.value=d}lt(()=>{G.value==="json"&&typeof k.value=="string"&&(k.value=JSON.parse(k.value))});const fe=rt("nuxt-devtools:server-routes:inputs",()=>[],{window:window.parent});it([f,T],()=>{const s=fe.value?.find(d=>d.path===n.route.filepath);if(s){T.value||(T.value=s.tab),s.tab!==T.value&&(s.tab=T.value);const{body:d,query:m,headers:E,params:V}=s.inputs;Object.assign(f,{body:d,query:m,headers:E}),S.value=V}else{const d={path:n.route.filepath,tab:C.value.length?"params":"query",inputs:{...f,...C.value.length?{params:S.value}:{}}};fe.value.push(d),T.value||(T.value=d.tab)}},{immediate:!0,deep:!0,debounce:500});function Fe(){fe.value=[],f.body=[],f.query=[],f.headers=[],S.value={},T.value=C.value.length?"params":"query"}const ze=ut();return(s,d)=>{const m=ye,E=Ne,V=Re,z=he,Ce=Le,He=_t,Ge=Ee,We=pt,ve=Ie,Je=kt,Ke=wt,ae=De("tooltip");return a(),_("div",Ft,[c("div",zt,[c("div",Ht,[s.route.method?(a(),x(m,{key:0,class:L(["n-badge-base n-sm",("getRequestMethodClass"in s?s.getRequestMethodClass:e(re))(e(g))]),"pointer-events-none":"","font-mono":"",tabindex:"-1"},{default:$(()=>[J(A(e(g).toUpperCase()),1)]),_:1},8,["class"])):(a(),x(E,{key:1,modelValue:e(g),"onUpdate:modelValue":d[0]||(d[0]=u=>Z(g)?g.value=u:null),class:L(["n-badge-base n-sm",("getRequestMethodClass"in s?s.getRequestMethodClass:e(re))(e(g))])},{default:$(()=>[(a(),_(N,null,M(ue,u=>c("option",{key:u,class:L(("getRequestMethodClass"in s?s.getRequestMethodClass:e(re))(u))},A(u.toUpperCase()),3)),64))]),_:1},8,["modelValue","class"])),c("div",Gt,[b(V,{"model-value":e(se),readonly:"","flex-auto":"","font-mono":"",p:"x5 y2",n:"sm"},null,8,["model-value"]),c("div",Wt,[ee(b(m,{title:"Copy URL",n:"xs blue",icon:"carbon:copy",border:!1,onClick:d[1]||(d[1]=u=>e(ze)(e(_e),"server-route-url"))},null,512),[[ae,"Copy URL"]]),ee(b(m,{title:"Open in Editor",icon:"carbon-launch",n:"xs blue",border:!1,onClick:d[2]||(d[2]=u=>e(H)(s.route.filepath))},null,512),[[ae,"Open in Editor"]])])]),b(m,{"h-full":"",n:"primary solid",onClick:ke},{default:$(()=>[b(z,{icon:"carbon:send"})]),_:1})])]),c("div",Jt,[(a(!0),_(N,null,M(e(Be),u=>ee((a(),x(m,{key:u.slug,class:L(e(T)===u.slug?"text-primary n-primary":"border-transparent shadow-none"),onClick:Y=>T.value=u.slug},{default:$(()=>[b(z,{icon:("ServerRouteTabIcons"in s?s.ServerRouteTabIcons:e(qe))[u.slug]},null,8,["icon"]),c("div",Kt,[J(A(u.name)+" "+A(u?.length?`(${u.length})`:"")+" ",1),c("span",null,A(e(j)[u.slug]?.length?`(${e(j)[u.slug].length})`:""),1)])]),_:2},1032,["class","onClick"])),[[ae,u.name]])),128)),Qt,Xt,b(E,{modelValue:e(P),"onUpdate:modelValue":d[3]||(d[3]=u=>Z(P)?P.value=u:null),class:"n-xs",disabled:!e(y)?.app?.$fetch},{default:$(()=>[Yt,Zt]),_:1},8,["modelValue","disabled"]),ee(b(m,{n:"orange",class:"p-3",icon:"i-carbon-clean",onClick:Fe},null,512),[[ae,"Clear Inputs Saved Cache"]])]),e(T)==="params"?(a(),_("div",eo,[(a(!0),_(N,null,M(e(C),u=>(a(),_(N,{key:u},[c("div",to,A(u),1),b(V,{modelValue:e(S)[u],"onUpdate:modelValue":Y=>e(S)[u]=Y,placeholder:u,"flex-1":""},null,8,["modelValue","onUpdate:modelValue","placeholder"])],64))),128))])):I("",!0),e(T)==="cookies"?(a(),_("div",oo,[(a(!0),_(N,null,M(e(X),u=>(a(),_("div",{key:u.key,flex:"~ gap-4 items-center"},[b(V,{placeholder:"Key...","model-value":u.key,disabled:"","op-70":""},null,8,["model-value"]),b(V,{placeholder:"Value...","model-value":u.value,"flex-1":"",n:"primary",onInput:Y=>pe(u.key,Y.target?.value)},null,8,["model-value","onInput"]),b(m,{title:"Delete",n:"red",onClick:Y=>pe(u.key,void 0)},{default:$(()=>[b(z,{icon:"i-carbon-trash-can"})]),_:2},1032,["onClick"])]))),128)),c("div",no,[b(V,{modelValue:e(K).key,"onUpdate:modelValue":d[4]||(d[4]=u=>e(K).key=u),placeholder:"Key",n:"primary","flex-1":""},null,8,["modelValue"]),b(V,{modelValue:e(K).value,"onUpdate:modelValue":d[5]||(d[5]=u=>e(K).value=u),placeholder:"Value",n:"primary","flex-1":""},null,8,["modelValue"]),b(m,{title:"Add",n:"primary",onClick:d[6]||(d[6]=u=>pe(e(K).key,e(K).value))},{default:$(()=>[b(z,{icon:"i-carbon-save"})]),_:1})])])):I("",!0),b(e(h),null,{default:$(()=>[b(Ce,{modelValue:e(ne),"onUpdate:modelValue":d[9]||(d[9]=u=>Z(ne)?ne.value=u:null),default:{active:!0,type:"string"},"max-h-xs":"","of-auto":""},{default:$(()=>[e(j)[e(T)]?.length?(a(),_(N,{key:0},[c("div",so,[ao,lo,b(m,{icon:"i-carbon-edit",border:!1,onClick:d[7]||(d[7]=u=>o("open-default-input"))}),ro]),b(Ce,{modelValue:e(j)[e(T)],"onUpdate:modelValue":d[8]||(d[8]=u=>e(j)[e(T)]=u),disabled:"",p0:""},null,8,["modelValue"])],64)):I("",!0)]),_:1},8,["modelValue"])]),_:1}),e(T)==="snippet"?(a(),_("div",io,[e(we).length?(a(),x(He,{key:0,"code-snippets":e(we)},null,8,["code-snippets"])):I("",!0)])):e(ne)?(a(),_("div",uo,[e(T)==="body"?(a(),_(N,{key:0},[c("div",co,[(a(),_(N,null,M(D,u=>c("button",{key:u,px4:"",py2:"",border:"r base",hover:"bg-active",class:L({"border-b":u!==e(G)}),onClick:Y=>G.value=u},[c("div",{class:L({op30:u!==e(G)}),"font-mono":""},A(u),3)],10,po)),64)),fo]),e(G)==="input"?(a(),x(e(w),{key:0})):e(G)==="json"?(a(),x(e(Ct),dt({key:1,modelValue:e(k),"onUpdate:modelValue":d[10]||(d[10]=u=>Z(k)?k.value=u:null),class:[[s.$colorMode.value==="dark"?"jse-theme-dark":"light"],"json-editor-vue of-auto text-sm outline-none"]},s.$attrs,{mode:"text","navigation-bar":!1,indentation:2,"tab-size":2}),null,16,["modelValue","class"])):I("",!0)],64)):(a(),x(e(w),{key:1}))])):I("",!0),e(F)?e(O)?(a(),x(We,{key:5,"z-10":"","flex-auto":"","backdrop-blur":""},{default:$(()=>[J(" Fetching... ")]),_:1})):(a(),_(N,{key:6},[c("div",vo,[mo,e(r).error?(a(),x(ve,{key:0,n:"red"},{default:$(()=>[J(" Error ")]),_:1})):I("",!0),b(ve,{n:e(r).error?"orange":"green",textContent:A(e(r).statusCode)},null,8,["n","textContent"]),e(r).contentType?(a(),_("code",ho,A(e(r).contentType),1)):I("",!0),e(r).contentType==="application/json"?(a(),x(Je,{key:2,getter:()=>({input:e(i)})},null,8,["getter"])):I("",!0),yo,bo,b(ve,{n:"green"},{default:$(()=>[J(A(e(r).fetchTime)+" ms ",1)]),_:1})]),e(p)==="pdf"?(a(),_("div",go,[c("div",_o,[c("object",{data:e(i),type:"application/pdf","flex-auto":"",width:"100%",height:"100%",rounded:""},null,8,ko)])])):e(p)!=="media"?(a(),x(Ke,{key:1,"flex-auto":"","overflow-auto":"","py-2":"",code:e(i),lang:e(p)},null,8,["code","lang"])):(a(),_("div",wo,[c("div",Co,[e(r).contentType.includes("image")?(a(),_("img",{key:0,rounded:"",src:e(i)},null,8,xo)):(a(),_("video",So,[c("source",{src:e(i),type:"video/mp4"},null,8,$o)]))])]))],64)):(a(),x(Ge,{key:4},{default:$(()=>[b(m,{n:"primary",onClick:ke},{default:$(()=>[b(z,{icon:"carbon:send"}),J(" Send request ")]),_:1})]),_:1}))])}}}),Vo={flex:"~ gap1","text-sm":""},Ro={key:0,op50:""},Uo={op50:""},jo=c("span",{op75:""},"Select a route to start",-1),Do=c("div",{p4:"",border:"b base"},[c("span",{"text-lg":""},"Default Inputs"),c("br"),c("span",{"text-white":"",op50:""},"Merged as default for every request in DevTools")],-1),Wo=ie({__name:"server-routes",setup(t){const l=B(!1),n=ft(),o=Te(),{selectedRoute:h,view:w,inputDefaults:v}=Oe("serverRoutes"),y=R(()=>{!o.value&&h.value&&(o.value=h.value.filepath);const U=n.value?.find(C=>C.filepath===o.value);return o.value!==h.value?.filepath&&U&&(h.value=U),U}),r=B(""),p=R(()=>new vt(n.value||[],{keys:["method","route"],shouldSort:!0})),i=R(()=>n.value?r.value?p.value.search(r.value).map(C=>C.item):n.value:[]),O=R(()=>{const U=[],C=(S,f)=>{S.routes=S.routes||[],S.routes.push(f)},g=(S,f)=>{const k=f?f.routes?.find(q=>q.route===S):U.find(q=>q.route===S);if(k)return k;const j={route:S,filepath:S.replace(/\W/g,"-").toLowerCase(),type:"collection",routes:[]};return f?C(f,j):U.push(j),j};return i.value.forEach(S=>{let f,k;const j=S.filepath.split("/"),q=j.slice(j.indexOf("server")+1);if(S.type==="runtime"){q[0]="runtime";const P=j.indexOf("dist");P!==-1&&(f=j[P-1],f&&q.splice(1,0,f))}q.length>0&&q[q.length-1].includes(".")&&q.pop(),q.forEach(P=>{k=g(P,k)}),k?C(k,S):U.push(S)}),U});function F(){w.value=w.value==="tree"?"list":"tree"}function H(U){return U.charAt(0).toUpperCase()+U.slice(1)}return(U,C)=>{const g=ye,S=bt,f=Ae,k=To,j=yt,q=Ee,P=mt,ue=Le,de=xt,oe=St,T=De("tooltip");return a(),_(N,null,[b(P,{"storage-key":"tab-server-routes"},{left:$(()=>[b(S,{search:e(r),"onUpdate:search":C[1]||(C[1]=D=>Z(r)?r.value=D:null),pb2:""},{actions:$(()=>[ee(b(g,{"text-lg":"",icon:e(w)==="list"?"i-carbon-list":"i-carbon-tree-view-alt",title:"Toggle view",border:!1,onClick:F},null,8,["icon"]),[[T,"Toggle View"]]),ee(b(g,{"text-lg":"",icon:"i-carbon-cics-sit-overrides",title:"Default Inputs",border:!1,onClick:C[0]||(C[0]=D=>l.value=!e(l))},null,512),[[T,"Default Inputs"]])]),default:$(()=>[c("div",Vo,[e(r)?(a(),_("span",Ro,A(e(i).length)+" matched · ",1)):I("",!0),c("span",Uo,A(e(n)?.length)+" routes in total",1)])]),_:1},8,["search"]),(a(!0),_(N,null,M(e(w)==="tree"?e(O):e(i),D=>(a(),x(f,{key:D.filepath,item:D},null,8,["item"]))),128))]),right:$(()=>[(a(),x(ht,{max:10},[e(y)?(a(),x(k,{key:e(y).filepath,route:e(y),onOpenDefaultInput:C[2]||(C[2]=D=>l.value=!0)},null,8,["route"])):I("",!0)],1024)),e(y)?I("",!0):(a(),x(q,{key:0},{default:$(()=>[b(j,{px6:"",py2:""},{default:$(()=>[jo]),_:1})]),_:1}))]),_:1}),b(oe,{modelValue:e(l),"onUpdate:modelValue":C[3]||(C[3]=D=>Z(l)?l.value=D:null),"auto-close":"","max-w-xl":"","min-w-xl":"",onClose:C[4]||(C[4]=D=>l.value=!1)},{default:$(()=>[c("div",null,[Do,(a(!0),_(N,null,M(Object.keys(e(v)),D=>(a(),x(de,{key:D,text:`${H(D)} ${e(v)[D].length?`(${e(v)[D].length})`:""}`,padding:!1,icon:("ServerRouteTabIcons"in U?U.ServerRouteTabIcons:e(qe))[D]},{default:$(()=>[b(ue,{modelValue:e(v)[D],"onUpdate:modelValue":G=>e(v)[D]=G,py0:"",default:{active:!0,type:"string"}},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1032,["text","icon"]))),128))])]),_:1},8,["modelValue"])],64)}}});export{Wo as default};
@@ -1 +0,0 @@
1
- import{_ as K}from"./NIconTitle.vue.B_Ui7cce.js";import{_ as X}from"./NSwitch.vue.b9xL28U5.js";import{d as Y,au as Z,bP as ee,aD as le,az as E,l as m,i as n,p as e,F as v,m as N,f as t,j as a,L as oe,_ as ne,ao as te,o as r,h as P,t as y,G as j,n as A,v as U,k as c,C as z,B as ae,bH as se,bQ as ie}from"./entry.Li7bMdxw.js";import{_ as ue}from"./NSelect.vue.zI1gfDpy.js";import{_ as de}from"./NCheckbox.vue.m1__cenQ.js";import{_ as re}from"./NLink.vue.Bj0qXc3J.js";const ce={px8:"",py6:""},pe={grid:"~ md:cols-2 gap-x-10 gap-y-3","max-w-300":""},me={flex:"~ col gap-2"},_e=e("h3",{"text-lg":""}," Tabs ",-1),fe={flex:"~ gap-2","flex-auto":"","items-center":"","justify-start":""},ve={capitalize:"",op75:""},ge=e("div",{"mx--1":"",my1:"","h-1px":"",border:"b base",op75:""},null,-1),he=e("div",{"flex-auto":""},null,-1),be={flex:"~ col gap-2"},xe=e("h3",{"text-lg":""}," Appearance ",-1),ye=e("div",{"i-carbon-sun":"","dark:i-carbon-moon":"","translate-y--1px":""},null,-1),ke=e("div",{"mx--2":"",my1:"","h-1px":"",border:"b base",op75:""},null,-1),Ve=e("p",null,"UI Scale",-1),Ce=["value"],we=e("div",{"mx--2":"",my1:"","h-1px":"",border:"b base",op75:""},null,-1),Te=e("span",null," Expand Sidebar ",-1),Se=e("span",null," Scrollable Sidebar ",-1),Ne=e("h3",{mt2:"","text-lg":""}," Features ",-1),Ue=e("span",null,"Close DevTools when clicking outside",-1),Oe=e("span",null,"Show help buttons",-1),$e=e("span",null,"Always show the floating panel",-1),Ie=e("div",{"mx--2":"",my1:"","h-1px":"",border:"b base",op75:""},null,-1),De=e("p",null,"Minimize floating panel on inactive",-1),ze=["value"],Be=e("h3",{mt2:"","text-lg":""}," Feedback ",-1),Le=e("span",null,"Send anonymous statistics, help us improving DevTools",-1),Ee=e("div",{"mx--2":"",my1:"","h-1px":"",border:"b base",op75:""},null,-1),Pe={flex:"~ gap-2"},je=e("div",{"i-carbon-data-enrichment":""},null,-1),Ae=e("div",{"i-carbon-debug":""},null,-1),Fe=e("h3",{mt2:"","text-lg":""}," Debug ",-1),Me={flex:"~ gap-2"},He=e("div",{"i-carbon-breaking-change":""},null,-1),Xe=Y({__name:"settings",setup(Re){const{interactionCloseOnOutsideClick:k,showPanel:O,showHelpButtons:$,scale:I,hiddenTabs:g,pinnedTabs:u,hiddenTabCategories:h,minimizePanelInactive:V,sidebarExpanded:C,sidebarScrollable:D}=ae(),b=Z(),F=[["Tiny",12/15],["Small",14/15],["Normal",1],["Large",16/15],["Huge",18/15]],M=[["Always",0],["1s",1e3],["2s",2e3],["5s",5e3],["10s",1e4],["Never",-1]],H=ee(le());function R(s,o){o?g.value=g.value.filter(d=>d!==s):g.value.push(s)}function G(s,o){o?h.value=h.value.filter(d=>d!==s):h.value.push(s)}function Q(s){u.value.includes(s)?u.value=u.value.filter(o=>o!==s):u.value.push(s)}function B(s,o){const d=u.value.indexOf(s);if(d===-1)return;const _=d+o;if(_<0||_>=u.value.length)return;const x=[...u.value];x.splice(d,1),x.splice(_,0,s),u.value=x}async function W(){confirm("Are you sure you to reset all local settings & state? The app will reload.")&&(Object.keys(localStorage).forEach(s=>{s.startsWith("nuxt-devtools-")&&localStorage.removeItem(s)}),await oe.clearOptions(),b.value?.app?.reload?.(),window.location.reload())}return E(()=>{b.value&&(b.value.app.frameState.value.closeOnOutsideClick=k.value)}),E(()=>{b.value&&(b.value.app.frameState.value.minimizePanelInactive=V.value)}),(s,o)=>{const d=K,_=X,x=se,p=ne,w=te,q=ie,L=ue,f=de,J=re;return r(),m("div",ce,[n(d,{class:"mb-5 text-xl op75",icon:"i-carbon-settings-adjust",text:"DevTools Settings"}),e("div",pe,[e("div",me,[_e,(r(!0),m(v,null,N(t(H),([l,T])=>(r(),m(v,{key:l},[T.length?(r(),P(w,{key:0,p3:"",flex:"~ col gap-1",class:j(t(h).includes(l)?"op50 grayscale":"")},{default:a(()=>[n(_,{flex:"~ row-reverse",py1:"",pl2:"",pr1:"","n-lime":"","model-value":!t(h).includes(l),"onUpdate:modelValue":i=>G(l,i)},{default:a(()=>[e("div",fe,[e("span",ve,y(l),1)])]),_:2},1032,["model-value","onUpdate:modelValue"]),ge,(r(!0),m(v,null,N(T,i=>(r(),P(_,{key:i.name,flex:"~ row-reverse",py1:"",pl2:"",pr1:"","n-primary":"","model-value":!t(g).includes(i.name),"onUpdate:modelValue":S=>R(i.name,S)},{default:a(()=>[e("div",{flex:"~ gap-2","flex-auto":"","items-center":"","justify-start":"","pr-4":"",class:j(t(g).includes(i.name)?"op25":"")},[n(x,{"text-xl":"",icon:i.icon,title:i.title},null,8,["icon","title"]),e("span",null,y(i.title),1),he,t(u).includes(i.name)?(r(),m(v,{key:0},[n(p,{icon:"i-carbon-caret-up",disabled:t(u).indexOf(i.name)===0,border:!1,onClick:S=>B(i.name,-1)},null,8,["disabled","onClick"]),n(p,{icon:"i-carbon-caret-down",disabled:t(u).indexOf(i.name)===t(u).length-1,border:!1,onClick:S=>B(i.name,1)},null,8,["disabled","onClick"])],64)):A("",!0),n(p,{icon:t(u).includes(i.name)?" i-carbon-pin-filled rotate--45":" i-carbon-pin op50",border:!1,onClick:S=>Q(i.name)},null,8,["icon","onClick"])],2)]),_:2},1032,["model-value","onUpdate:modelValue"]))),128))]),_:2},1032,["class"])):A("",!0)],64))),128))]),e("div",be,[xe,n(w,{p4:"",flex:"~ col gap-2"},{default:a(()=>[e("div",null,[n(q,null,{default:a(({toggle:l,isDark:T})=>[n(p,{n:"primary",onClick:l},{default:a(()=>[ye,U(" "+y(T.value?"Dark":"Light"),1)]),_:2},1032,["onClick"])]),_:1})]),ke,Ve,n(L,{modelValue:t(I),"onUpdate:modelValue":o[0]||(o[0]=l=>c(I)?I.value=l:null),n:"primary"},{default:a(()=>[(r(),m(v,null,N(F,l=>e("option",{key:l[0],value:l[1]},y(l[0]),9,Ce)),64))]),_:1},8,["modelValue"]),we,n(f,{modelValue:t(C),"onUpdate:modelValue":o[1]||(o[1]=l=>c(C)?C.value=l:null),"n-primary":""},{default:a(()=>[Te]),_:1},8,["modelValue"]),n(f,{modelValue:t(D),"onUpdate:modelValue":o[2]||(o[2]=l=>c(D)?D.value=l:null),disabled:t(C),"n-primary":""},{default:a(()=>[Se]),_:1},8,["modelValue","disabled"])]),_:1}),Ne,n(w,{p4:"",flex:"~ col gap-2"},{default:a(()=>[n(f,{modelValue:t(k),"onUpdate:modelValue":o[3]||(o[3]=l=>c(k)?k.value=l:null),"n-primary":""},{default:a(()=>[Ue]),_:1},8,["modelValue"]),n(f,{modelValue:t($),"onUpdate:modelValue":o[4]||(o[4]=l=>c($)?$.value=l:null),"n-primary":""},{default:a(()=>[Oe]),_:1},8,["modelValue"]),n(f,{modelValue:t(O),"onUpdate:modelValue":o[5]||(o[5]=l=>c(O)?O.value=l:null),"n-primary":""},{default:a(()=>[$e]),_:1},8,["modelValue"]),Ie,De,n(L,{modelValue:t(V),"onUpdate:modelValue":o[6]||(o[6]=l=>c(V)?V.value=l:null),modelModifiers:{number:!0},"n-primary":""},{default:a(()=>[(r(),m(v,null,N(M,l=>e("option",{key:l[0],value:l[1]},y(l[0]),9,ze)),64))]),_:1},8,["modelValue"])]),_:1}),Be,n(w,{p4:"",flex:"~ col gap-2"},{default:a(()=>[n(f,{modelValue:t(z),"onUpdate:modelValue":o[7]||(o[7]=l=>c(z)?z.value=l:null),"n-primary":""},{default:a(()=>[Le,n(J,{href:"https://github.com/nuxt/devtools#anonymous-usage-analytics",target:"_blank",ml1:"",op50:"",textContent:"Learn more"})]),_:1},8,["modelValue"]),Ee,e("div",Pe,[n(p,{n:"blue",to:"https://github.com/nuxt/devtools/discussions/29",target:"_blank"},{default:a(()=>[je,U(" Ideas & Suggestions ")]),_:1}),n(p,{n:"orange",to:"https://github.com/nuxt/devtools/issues",target:"_blank"},{default:a(()=>[Ae,U(" Bug Reports ")]),_:1})])]),_:1}),Fe,e("div",Me,[n(p,{n:"orange",onClick:W},{default:a(()=>[He,U(" Reset Local Settings & State ")]),_:1})])])])])}}});export{Xe as default};
@@ -1,4 +0,0 @@
1
- const e=Object.freeze({displayName:"Shell",name:"shellscript",patterns:[{include:"#initial_context"}],repository:{alias_statement:{begin:"(alias)[ \\t]*+[ \\t]*+(?:((?<=^|;|&|[ \\t])(?:readonly|declare|typeset|export|local)(?=[ \\t]|;|&|$))[ \\t]*+)?((?<!\\w)[a-zA-Z_0-9-]+(?!\\w))(?:(\\[)((?:(?:(?:\\$)?(?<!\\w)[a-zA-Z_0-9-]+(?!\\w)|@)|\\*))(\\]))?(?:(?:(\\=)|(\\+\\=))|(\\-\\=))",beginCaptures:{1:{name:"storage.type.alias.shell"},2:{name:"storage.modifier.$2.shell"},3:{name:"variable.other.assignment.shell"},4:{name:"punctuation.definition.array.access.shell"},5:{name:"variable.other.assignment.shell"},6:{name:"punctuation.definition.array.access.shell"},7:{name:"keyword.operator.assignment.shell"},8:{name:"keyword.operator.assignment.compound.shell"},9:{name:"keyword.operator.assignment.compound.shell"}},end:"(?:(?= |\\t|$)|(?:(?:(?:(?:(;)|(&&))|(\\|\\|))|(&))|\\n))",endCaptures:{1:{name:"punctuation.terminator.statement.semicolon.shell"},2:{name:"punctuation.separator.statement.and.shell"},3:{name:"punctuation.separator.statement.or.shell"},4:{name:"punctuation.separator.statement.background.shell"}},name:"meta.expression.assignment.shell",patterns:[{include:"#normal_statement_context"}]},argument:{begin:"[ \\t]++(?!(?:&|\\||\\(|\\[|#|\\n|$|;))",beginCaptures:{},end:"(?= |\\t|;|\\||&|$|\\n|\\)|\\`)",endCaptures:{},name:"meta.argument.shell",patterns:[{include:"#argument_context"},{include:"#line_continuation"}]},argument_context:{patterns:[{captures:{1:{name:"string.unquoted.argument.shell",patterns:[{match:"\\*",name:"variable.language.special.wildcard.shell"},{include:"#variable"},{include:"#numeric_literal"},{captures:{1:{name:"constant.language.$1.shell"}},match:"(?<!\\w)(\\b(?:true|false)\\b)(?!\\w)"}]}},match:`[ \\t]*+([^
2
- '&;<>\\(\\)\\$\`\\\\"\\|]+(?!>))`},{include:"#normal_statement_context"}]},assignment:{patterns:[{begin:"[ \\t]*+(?:((?<=^|;|&|[ \\t])(?:readonly|declare|typeset|export|local)(?=[ \\t]|;|&|$))[ \\t]*+)?((?<!\\w)[a-zA-Z_0-9-]+(?!\\w))(?:(\\[)((?:(?:(?:\\$)?(?<!\\w)[a-zA-Z_0-9-]+(?!\\w)|@)|\\*))(\\]))?(?:(?:(\\=)|(\\+\\=))|(\\-\\=))[ \\t]*+(\\()",beginCaptures:{1:{name:"storage.modifier.$1.shell"},2:{name:"variable.other.assignment.shell"},3:{name:"punctuation.definition.array.access.shell"},4:{name:"variable.other.assignment.shell"},5:{name:"punctuation.definition.array.access.shell"},6:{name:"keyword.operator.assignment.shell"},7:{name:"keyword.operator.assignment.compound.shell"},8:{name:"keyword.operator.assignment.compound.shell"},9:{name:"punctuation.shell"}},end:"\\)",endCaptures:{0:{name:"punctuation.shell"}},name:"meta.expression.assignment.shell",patterns:[{include:"#comment"},{include:"#argument_context"}]},{begin:"[ \\t]*+(?:((?<=^|;|&|[ \\t])(?:readonly|declare|typeset|export|local)(?=[ \\t]|;|&|$))[ \\t]*+)?((?<!\\w)[a-zA-Z_0-9-]+(?!\\w))(?:(\\[)((?:(?:(?:\\$)?(?<!\\w)[a-zA-Z_0-9-]+(?!\\w)|@)|\\*))(\\]))?(?:(?:(\\=)|(\\+\\=))|(\\-\\=))",beginCaptures:{1:{name:"storage.modifier.$1.shell"},2:{name:"variable.other.assignment.shell"},3:{name:"punctuation.definition.array.access.shell"},4:{name:"variable.other.assignment.shell"},5:{name:"punctuation.definition.array.access.shell"},6:{name:"keyword.operator.assignment.shell"},7:{name:"keyword.operator.assignment.compound.shell"},8:{name:"keyword.operator.assignment.compound.shell"}},end:"(?:(?= |\\t|$)|(?:(?:(?:(?:(;)|(&&))|(\\|\\|))|(&))|\\n))",endCaptures:{1:{name:"punctuation.terminator.statement.semicolon.shell"},2:{name:"punctuation.separator.statement.and.shell"},3:{name:"punctuation.separator.statement.or.shell"},4:{name:"punctuation.separator.statement.background.shell"}},name:"meta.expression.assignment.shell",patterns:[{include:"#comment"},{include:"#argument_context"}]}]},basic_command_name:{captures:{1:{name:"storage.modifier.$1.shell"},2:{name:"entity.name.function.call.shell entity.name.command.shell",patterns:[{match:"(?<!\\w)(?:continue|return|break)(?!\\w)",name:"keyword.control.$0.shell"},{match:"(?<!\\w)(?:unfunction|continue|autoload|unsetopt|bindkey|builtin|getopts|command|declare|unalias|history|unlimit|typeset|suspend|source|printf|unhash|disown|ulimit|return|which|alias|break|false|print|shift|times|umask|umask|unset|read|type|exec|eval|wait|echo|dirs|jobs|kill|hash|stat|exit|test|trap|true|let|set|pwd|cd|fg|bg|fc|:|\\.)(?!\\/)(?!\\w)",name:"support.function.builtin.shell"},{include:"#variable"}]}},match:`(?!(?:!|&|\\||\\(|\\)|\\{|\\[|<|>|#|\\n|$|;|[ \\t]))(?!foreach\\b(?!\\/)|select\\b(?!\\/)|repeat\\b(?!\\/)|until\\b(?!\\/)|while\\b(?!\\/)|case\\b(?!\\/)|done\\b(?!\\/)|elif\\b(?!\\/)|else\\b(?!\\/)|esac\\b(?!\\/)|then\\b(?!\\/)|for\\b(?!\\/)|end\\b(?!\\/)|in\\b(?!\\/)|fi\\b(?!\\/)|do\\b(?!\\/)|if\\b(?!\\/))(?:((?<=^|;|&|[ \\t])(?:readonly|declare|typeset|export|local)(?=[ \\t]|;|&|$))|((?!"|'|\\\\\\n?$)[^!'" \\t\\n\\r]+?))(?:(?= |\\t)|(?=;|\\||&|\\n|\\)|\\\`|\\{|\\}|[ \\t]*#|\\])(?<!\\\\))`,name:"meta.statement.command.name.basic.shell"},block_comment:{begin:"\\s*+(\\/\\*)",beginCaptures:{1:{name:"punctuation.definition.comment.begin.shell"}},end:"\\*\\/",endCaptures:{0:{name:"punctuation.definition.comment.end.shell"}},name:"comment.block.shell"},boolean:{match:"\\b(?:true|false)\\b",name:"constant.language.$0.shell"},"case-clause":{patterns:[{begin:"(?=\\S)",end:";;&?|;&",endCaptures:{0:{name:"punctuation.terminator.case-clause.shell"}},name:"meta.scope.case-clause.shell",patterns:[{begin:"\\(|(?=\\S)",beginCaptures:{0:{name:"punctuation.definition.case-pattern.shell"}},end:"\\)",endCaptures:{0:{name:"punctuation.definition.case-pattern.shell"}},name:"meta.scope.case-pattern.shell",patterns:[{match:"\\|",name:"punctuation.separator.pipe-sign.shell"},{include:"#string"},{include:"#variable"},{include:"#interpolation"},{include:"#pathname"}]},{begin:"(?<=\\))",end:"(?=;;&?|;&)",name:"meta.scope.case-clause-body.shell",patterns:[{include:"#initial_context"}]}]}]},comment:{captures:{1:{name:"comment.line.number-sign.shell meta.shebang.shell"},2:{name:"punctuation.definition.comment.shebang.shell"},3:{name:"comment.line.number-sign.shell"},4:{name:"punctuation.definition.comment.shell"}},match:"(?:^|[ \\t]++)(?:((#!).*)|((#).*))"},comments:{patterns:[{include:"#block_comment"},{include:"#line_comment"}]},"compound-command":{patterns:[{begin:"\\[{1,2}",beginCaptures:{0:{name:"punctuation.definition.logical-expression.shell"}},end:"\\]{1,2}",endCaptures:{0:{name:"punctuation.definition.logical-expression.shell"}},name:"meta.scope.logical-expression.shell",patterns:[{include:"#logical-expression"},{include:"#initial_context"}]},{begin:"\\({2}",beginCaptures:{0:{name:"punctuation.definition.string.begin.shell"}},end:"\\){2}",endCaptures:{0:{name:"punctuation.definition.string.end.shell"}},name:"string.other.math.shell",patterns:[{include:"#math"}]},{begin:"\\(",beginCaptures:{0:{name:"punctuation.definition.subshell.shell"}},end:"\\)",endCaptures:{0:{name:"punctuation.definition.subshell.shell"}},name:"meta.scope.subshell.shell",patterns:[{include:"#initial_context"}]},{begin:"(?<=\\s|^){(?=\\s|$)",beginCaptures:{0:{name:"punctuation.definition.group.shell"}},end:"(?<=^|;)\\s*(})",endCaptures:{1:{name:"punctuation.definition.group.shell"}},name:"meta.scope.group.shell",patterns:[{include:"#initial_context"}]}]},continuation_of_double_quoted_command_name:{begin:'\\G(?<=")',beginCaptures:{},contentName:"meta.statement.command.name.continuation string.quoted.double entity.name.function.call entity.name.command",end:'"',endCaptures:{0:{name:"string.quoted.double.shell punctuation.definition.string.end.shell entity.name.function.call.shell entity.name.command.shell"}},patterns:[{match:'\\\\[\\$\\n`"\\\\]',name:"constant.character.escape.shell"},{include:"#variable"},{include:"#interpolation"}]},continuation_of_single_quoted_command_name:{begin:"\\G(?<=')",beginCaptures:{},contentName:"meta.statement.command.name.continuation string.quoted.single entity.name.function.call entity.name.command",end:"'",endCaptures:{0:{name:"string.quoted.single.shell punctuation.definition.string.end.shell entity.name.function.call.shell entity.name.command.shell"}}},custom_command_names:{patterns:[]},custom_commands:{patterns:[]},double_quote_context:{patterns:[{match:'\\\\[\\$`"\\\\\\n]',name:"constant.character.escape.shell"},{include:"#variable"},{include:"#interpolation"}]},double_quote_escape_char:{match:'\\\\[\\$`"\\\\\\n]',name:"constant.character.escape.shell"},function_definition:{applyEndPatternLast:1,begin:"[ \\t]*+(?:(\\bfunction\\b)[ \\t]*+([^ \\t\\n\\r\\(\\)=]+)(?:(\\()[ \\t]*+(\\)))?|([^ \\t\\n\\r\\(\\)=]+)[ \\t]*+(\\()[ \\t]*+(\\)))",beginCaptures:{1:{name:"storage.type.function.shell"},2:{name:"entity.name.function.shell"},3:{name:"punctuation.definition.arguments.shell"},4:{name:"punctuation.definition.arguments.shell"},5:{name:"entity.name.function.shell"},6:{name:"punctuation.definition.arguments.shell"},7:{name:"punctuation.definition.arguments.shell"}},end:"(?<=\\}|\\))",endCaptures:{},name:"meta.function.shell",patterns:[{match:"\\G(?:\\t| |\\n)"},{begin:"\\{",beginCaptures:{0:{name:"punctuation.definition.group.shell punctuation.section.function.definition.shell"}},end:"\\}",endCaptures:{0:{name:"punctuation.definition.group.shell punctuation.section.function.definition.shell"}},name:"meta.function.body.shell",patterns:[{include:"#initial_context"}]},{begin:"\\(",beginCaptures:{0:{name:"punctuation.definition.group.shell punctuation.section.function.definition.shell"}},end:"\\)",endCaptures:{0:{name:"punctuation.definition.group.shell punctuation.section.function.definition.shell"}},name:"meta.function.body.shell",patterns:[{include:"#initial_context"}]}]},heredoc:{patterns:[{begin:`((?<!<)<<-)[ \\t]*+("|')[ \\t]*+((?<!\\w)[a-zA-Z_0-9-]+(?!\\w))(?=\\s|;|&|<|"|')(?:\\2)(.*)`,beginCaptures:{1:{name:"keyword.operator.heredoc.shell"},2:{},3:{name:"punctuation.definition.string.heredoc.shell"},4:{patterns:[{include:"#normal_statement_context"}]}},contentName:"string.quoted.heredoc.indent",end:"^\\t*(?:\\3)(?=\\s|;|&|$)",endCaptures:{0:{name:"punctuation.definition.string.heredoc.shell"}},patterns:[]},{begin:`((?<!<)<<(?!<))[ \\t]*+("|')[ \\t]*+((?<!\\w)[a-zA-Z_0-9-]+(?!\\w))(?=\\s|;|&|<|"|')(?:\\2)(.*)`,beginCaptures:{1:{name:"keyword.operator.heredoc.shell"},2:{},3:{name:"punctuation.definition.string.heredoc.shell"},4:{patterns:[{include:"#normal_statement_context"}]}},contentName:"string.quoted.heredoc.no-indent",end:"^(?:\\3)(?=\\s|;|&|$)",endCaptures:{0:{name:"punctuation.definition.string.heredoc.shell"}},patterns:[]},{begin:`((?<!<)<<-)[ \\t]*+((?<!\\w)[a-zA-Z_0-9-]+(?!\\w))(?=\\s|;|&|<|"|')(.*)`,beginCaptures:{1:{name:"keyword.operator.heredoc.shell"},2:{name:"punctuation.definition.string.heredoc.shell"},3:{patterns:[{include:"#normal_statement_context"}]}},contentName:"string.unquoted.heredoc.indent",end:"^\\t*(?:\\2)(?=\\s|;|&|$)",endCaptures:{0:{name:"punctuation.definition.string.heredoc.shell"}},patterns:[{include:"#double_quote_escape_char"},{include:"#variable"},{include:"#interpolation"}]},{begin:`((?<!<)<<(?!<))[ \\t]*+((?<!\\w)[a-zA-Z_0-9-]+(?!\\w))(?=\\s|;|&|<|"|')(.*)`,beginCaptures:{1:{name:"keyword.operator.heredoc.shell"},2:{name:"punctuation.definition.string.heredoc.shell"},3:{patterns:[{include:"#normal_statement_context"}]}},contentName:"string.unquoted.heredoc.no-indent",end:"^(?:\\2)(?=\\s|;|&|$)",endCaptures:{0:{name:"punctuation.definition.string.heredoc.shell"}},patterns:[{include:"#double_quote_escape_char"},{include:"#variable"},{include:"#interpolation"}]}]},herestring:{patterns:[{begin:"(<<<)\\s*(('))",beginCaptures:{1:{name:"keyword.operator.herestring.shell"},2:{name:"string.quoted.single.shell"},3:{name:"punctuation.definition.string.begin.shell"}},contentName:"string.quoted.single.shell",end:"(')",endCaptures:{0:{name:"string.quoted.single.shell"},1:{name:"punctuation.definition.string.end.shell"}},name:"meta.herestring.shell"},{begin:'(<<<)\\s*(("))',beginCaptures:{1:{name:"keyword.operator.herestring.shell"},2:{name:"string.quoted.double.shell"},3:{name:"punctuation.definition.string.begin.shell"}},contentName:"string.quoted.double.shell",end:'(")',endCaptures:{0:{name:"string.quoted.double.shell"},1:{name:"punctuation.definition.string.end.shell"}},name:"meta.herestring.shell",patterns:[{include:"#double_quote_context"}]},{captures:{1:{name:"keyword.operator.herestring.shell"},2:{name:"string.unquoted.herestring.shell",patterns:[{include:"#initial_context"}]}},match:"(<<<)\\s*(([^\\s)\\\\]|\\\\.)+)",name:"meta.herestring.shell"}]},initial_context:{patterns:[{include:"#comment"},{include:"#pipeline"},{include:"#normal_statement_seperator"},{include:"#logical_expression_double"},{include:"#logical_expression_single"},{include:"#misc_ranges"},{include:"#loop"},{include:"#function_definition"},{include:"#variable"},{include:"#interpolation"},{include:"#heredoc"},{include:"#herestring"},{include:"#redirection"},{include:"#pathname"},{include:"#keyword"},{include:"#alias_statement"},{include:"#normal_statement"},{include:"#string"},{include:"#support"}]},inline_comment:{captures:{1:{name:"comment.block.shell punctuation.definition.comment.begin.shell"},2:{name:"comment.block.shell"},3:{patterns:[{match:"\\*\\/",name:"comment.block.shell punctuation.definition.comment.end.shell"},{match:"\\*",name:"comment.block.shell"}]}},match:"(\\/\\*)((?:[^\\*]|(?:\\*)++[^\\/])*+((?:\\*)++\\/))"},interpolation:{patterns:[{begin:"\\$\\({2}",beginCaptures:{0:{name:"punctuation.definition.evaluation.arithmetic.begin.shell"}},end:"\\)\\s*\\)",endCaptures:{0:{name:"punctuation.definition.evaluation.arithmetic.end.shell"}},name:"string.other.math.shell",patterns:[{include:"#math"}]},{begin:"`",beginCaptures:{0:{name:"punctuation.definition.evaluation.backticks.shell"}},end:"`",endCaptures:{0:{name:"punctuation.definition.evaluation.backticks.shell"}},name:"string.interpolated.backtick.shell",patterns:[{match:"\\\\[`\\\\$]",name:"constant.character.escape.shell"},{begin:"(?<=\\W)(?=#)(?!#{)",beginCaptures:{1:{name:"punctuation.whitespace.comment.leading.shell"}},end:"(?!\\G)",patterns:[{begin:"#",beginCaptures:{0:{name:"punctuation.definition.comment.shell"}},end:"(?=`)",name:"comment.line.number-sign.shell"}]},{include:"#initial_context"}]},{begin:"\\$\\(",beginCaptures:{0:{name:"punctuation.definition.evaluation.parens.begin.shell"}},end:"\\)",endCaptures:{0:{name:"punctuation.definition.evaluation.parens.end.shell"}},name:"string.interpolated.dollar.shell",patterns:[{include:"#initial_context"}]}]},keyword:{patterns:[{match:"(?<=^|;|&| |\\t)(?:continue|foreach|return|select|repeat|break|until|while|case|done|elif|else|esac|then|for|end|do|if|fi|in)(?= |\\t|;|&|$)",name:"keyword.control.$0.shell"}]},line_comment:{begin:"\\s*+(\\/\\/)",beginCaptures:{1:{name:"punctuation.definition.comment.shell"}},end:"(?<=\\n)(?<!\\\\\\n)",endCaptures:{},name:"comment.line.double-slash.shell",patterns:[{include:"#line_continuation_character"}]},line_continuation:{match:"\\\\(?=\\n)",name:"constant.character.escape.line-continuation.shell"},"logical-expression":{patterns:[{comment:"do we want a special rule for ( expr )?",match:"=[=~]?|!=?|<|>|&&|\\|\\|",name:"keyword.operator.logical.shell"},{match:"(?<!\\S)-(nt|ot|ef|eq|ne|l[te]|g[te]|[a-hknoprstuwxzOGLSN])\\b",name:"keyword.operator.logical.shell"}]},logical_expression_context:{patterns:[{include:"#regex_comparison"},{include:"#logical-expression"},{include:"#logical_expression_single"},{include:"#logical_expression_double"},{include:"#comment"},{include:"#boolean"},{include:"#redirect_number"},{include:"#numeric_literal"},{include:"#pipeline"},{include:"#normal_statement_seperator"},{include:"#string"},{include:"#variable"},{include:"#interpolation"},{include:"#heredoc"},{include:"#herestring"},{include:"#pathname"},{include:"#keyword"},{include:"#support"}]},logical_expression_double:{begin:"\\[\\[",beginCaptures:{0:{name:"punctuation.definition.logical-expression.shell"}},end:"\\]\\]",endCaptures:{0:{name:"punctuation.definition.logical-expression.shell"}},name:"meta.scope.logical-expression.shell",patterns:[{include:"#logical_expression_context"}]},logical_expression_single:{begin:"\\[",beginCaptures:{0:{name:"punctuation.definition.logical-expression.shell"}},end:"\\]",endCaptures:{0:{name:"punctuation.definition.logical-expression.shell"}},name:"meta.scope.logical-expression.shell",patterns:[{include:"#logical_expression_context"}]},loop:{patterns:[{begin:"(?<=^|;|&|\\s)(for)\\s+(?=\\({2})",beginCaptures:{1:{name:"keyword.control.shell"}},end:"(?<=^|;|&|\\s)done(?=\\s|;|&|$|\\))",endCaptures:{0:{name:"keyword.control.shell"}},name:"meta.scope.for-loop.shell",patterns:[{include:"#initial_context"}]},{begin:"(?<=^|;|&|\\s)(for)\\s+(.+?)\\s+(in)(?=\\s|;|&|$)",beginCaptures:{1:{name:"keyword.control.shell"},2:{name:"variable.other.loop.shell",patterns:[{include:"#string"}]},3:{name:"keyword.control.shell"}},end:"(?<=^|;|&|\\s)done(?=\\s|;|&|$|\\))",endCaptures:{0:{name:"keyword.control.shell"}},name:"meta.scope.for-in-loop.shell",patterns:[{include:"#initial_context"}]},{begin:"(?<=^|;|&|\\s)(while|until)(?=\\s|;|&|$)",beginCaptures:{1:{name:"keyword.control.shell"}},end:"(?<=^|;|&|\\s)done(?=\\s|;|&|$|\\))",endCaptures:{0:{name:"keyword.control.shell"}},name:"meta.scope.while-loop.shell",patterns:[{include:"#initial_context"}]},{begin:"(?<=^|;|&|\\s)(select)\\s+((?:[^\\s\\\\]|\\\\.)+)(?=\\s|;|&|$)",beginCaptures:{1:{name:"keyword.control.shell"},2:{name:"variable.other.loop.shell"}},end:"(?<=^|;|&|\\s)(done)(?=\\s|;|&|$|\\))",endCaptures:{1:{name:"keyword.control.shell"}},name:"meta.scope.select-block.shell",patterns:[{include:"#initial_context"}]},{begin:"(?<=^|;|&|\\s)case(?=\\s|;|&|$)",beginCaptures:{0:{name:"keyword.control.shell"}},end:"(?<=^|;|&|\\s)esac(?=\\s|;|&|$)",endCaptures:{0:{name:"keyword.control.shell"}},name:"meta.scope.case-block.shell",patterns:[{begin:"(?<=^|;|&|\\s)in(?=\\s|;|&|$)",beginCaptures:{0:{name:"keyword.control.shell"}},end:"(?<=^|;|&|\\s)(?=esac(\\s|;|&|$))",name:"meta.scope.case-body.shell",patterns:[{include:"#comment"},{include:"#case-clause"}]},{include:"#initial_context"}]},{begin:"(?<=^|;|&|\\s)if(?=\\s|;|&|$)",beginCaptures:{0:{name:"keyword.control.shell"}},end:"(?<=^|;|&|\\s)fi(?=\\s|;|&|$)",endCaptures:{0:{name:"keyword.control.shell"}},name:"meta.scope.if-block.shell",patterns:[{include:"#initial_context"}]}]},math:{patterns:[{include:"#variable"},{match:"\\+{1,2}|-{1,2}|!|~|\\*{1,2}|/|%|<[<=]?|>[>=]?|==|!=|^|\\|{1,2}|&{1,2}|\\?|\\:|,|=|[*/%+\\-&^|]=|<<=|>>=",name:"keyword.operator.arithmetic.shell"},{match:"0[xX][0-9A-Fa-f]+",name:"constant.numeric.hex.shell"},{match:"0\\d+",name:"constant.numeric.octal.shell"},{match:"\\d{1,2}#[0-9a-zA-Z@_]+",name:"constant.numeric.other.shell"},{match:"\\d+",name:"constant.numeric.integer.shell"}]},misc_ranges:{patterns:[{include:"#logical_expression_single"},{include:"#logical_expression_double"},{begin:"\\(\\(",beginCaptures:{0:{name:"punctuation.section.arithmetic.shell"}},end:"\\)\\)",endCaptures:{0:{name:"punctuation.section.arithmetic.shell"}},name:"meta.arithmetic.shell",patterns:[{include:"#math"}]},{begin:"(?<!=)\\(",beginCaptures:{0:{name:"punctuation.definition.subshell"}},end:"\\)",endCaptures:{0:{name:"punctuation.definition.subshell"}},name:"meta.scope.subshell",patterns:[{include:"#initial_context"}]},{begin:"(?<![^ \\t])({)",beginCaptures:{1:{name:"punctuation.definition.group.shell"}},end:"}",endCaptures:{0:{name:"punctuation.definition.group.shell"}},name:"meta.scope.group.shell",patterns:[{include:"#initial_context"}]}]},modifiers:{match:"(?<=^|;|&|[ \\t])(?:readonly|declare|typeset|export|local)(?=[ \\t]|;|&|$)",name:"storage.modifier.$0.shell"},normal_statement:{begin:"(?!^[ \\t]*+$)(?:(?<=^until | until |\\tuntil |^while | while |\\twhile |^elif | elif |\\telif |^else | else |\\telse |^then | then |\\tthen |^do | do |\\tdo |^if | if |\\tif )|(?<=(?:^|;|\\||&|!|\\(|\\{|\\`)))[ \\t]*+(?!nocorrect\\W|nocorrect\\$|function\\W|function\\$|foreach\\W|foreach\\$|repeat\\W|repeat\\$|logout\\W|logout\\$|coproc\\W|coproc\\$|select\\W|select\\$|while\\W|while\\$|pushd\\W|pushd\\$|until\\W|until\\$|case\\W|case\\$|done\\W|done\\$|elif\\W|elif\\$|else\\W|else\\$|esac\\W|esac\\$|popd\\W|popd\\$|then\\W|then\\$|time\\W|time\\$|for\\W|for\\$|end\\W|end\\$|fi\\W|fi\\$|do\\W|do\\$|in\\W|in\\$|if\\W|if\\$)",beginCaptures:{},end:"(?=;|\\||&|\\n|\\)|\\`|\\{|\\}|[ \\t]*#|\\])(?<!\\\\)",endCaptures:{},name:"meta.statement.shell",patterns:[{include:"#function_definition"},{include:"#assignment"},{begin:"[ \\t]*+(?!(?:!|&|\\||\\(|\\)|\\{|\\[|<|>|#|\\n|$|;|[ \\t]))(?!foreach\\b(?!\\/)|select\\b(?!\\/)|repeat\\b(?!\\/)|until\\b(?!\\/)|while\\b(?!\\/)|case\\b(?!\\/)|done\\b(?!\\/)|elif\\b(?!\\/)|else\\b(?!\\/)|esac\\b(?!\\/)|then\\b(?!\\/)|for\\b(?!\\/)|end\\b(?!\\/)|in\\b(?!\\/)|fi\\b(?!\\/)|do\\b(?!\\/)|if\\b(?!\\/))(?!\\\\\\n?$)",beginCaptures:{},end:"(?=;|\\||&|\\n|\\)|\\`|\\{|\\}|[ \\t]*#|\\])(?<!\\\\)",endCaptures:{},name:"meta.statement.command.shell",patterns:[{begin:"\\G",beginCaptures:{},end:"(?= |\\t|;|\\||&|$|\\n|\\)|\\`)",endCaptures:{},name:"meta.statement.command.name.shell",patterns:[{include:"#modifiers"},{match:"(?<!\\w)(?:continue|return|break)(?!\\w)",name:"entity.name.function.call.shell entity.name.command.shell keyword.control.$0.shell"},{match:"(?<!\\w)(?:unfunction|continue|autoload|unsetopt|bindkey|builtin|getopts|command|declare|unalias|history|unlimit|typeset|suspend|source|printf|unhash|disown|ulimit|return|which|alias|break|false|print|shift|times|umask|umask|unset|read|type|exec|eval|wait|echo|dirs|jobs|kill|hash|stat|exit|test|trap|true|let|set|pwd|cd|fg|bg|fc|:|\\.)(?!\\/)(?!\\w)",name:"entity.name.function.call.shell entity.name.command.shell support.function.builtin.shell"},{include:"#variable"},{captures:{1:{name:"entity.name.function.call.shell entity.name.command.shell"}},match:`(?<=\\G|'|"|\\}|\\))([^ \\n\\t\\r"'=;&\\|\`\\)\\{]+)`},{begin:`(?:\\G|(?<! |\\t|;|\\||&|\\n|\\{|#))((?:\\$)?)((?:(")|(')))`,beginCaptures:{1:{name:"meta.statement.command.name.quoted.shell punctuation.definition.string.shell entity.name.function.call.shell entity.name.command.shell"},2:{},3:{name:"meta.statement.command.name.quoted.shell string.quoted.double.shell punctuation.definition.string.begin.shell entity.name.function.call.shell entity.name.command.shell"},4:{name:"meta.statement.command.name.quoted.shell string.quoted.single.shell punctuation.definition.string.begin.shell entity.name.function.call.shell entity.name.command.shell"}},end:"(?<!\\G)(?<=(?:\\2))",endCaptures:{},patterns:[{include:"#continuation_of_single_quoted_command_name"},{include:"#continuation_of_double_quoted_command_name"}]},{include:"#line_continuation"}]},{include:"#line_continuation"},{include:"#option"},{include:"#argument"},{include:"#statement_context"},{include:"#string"}]},{include:"#line_continuation"},{include:"#normal_statement_context"}]},normal_statement_context:{patterns:[{include:"#comment"},{include:"#pipeline"},{include:"#normal_statement_seperator"},{include:"#misc_ranges"},{include:"#boolean"},{include:"#redirect_number"},{include:"#numeric_literal"},{include:"#string"},{include:"#variable"},{include:"#interpolation"},{include:"#heredoc"},{include:"#herestring"},{include:"#redirection"},{include:"#pathname"},{include:"#keyword"},{include:"#support"}]},normal_statement_seperator:{captures:{1:{name:"punctuation.terminator.statement.semicolon.shell"},2:{name:"punctuation.separator.statement.and.shell"},3:{name:"punctuation.separator.statement.or.shell"},4:{name:"punctuation.separator.statement.background.shell"}},match:"(?:(?:(?:(?:(;)|(&&))|(\\|\\|))|(&))|\\n)"},numeric_literal:{captures:{1:{name:"constant.numeric.shell constant.numeric.hex.shell"},2:{name:"constant.numeric.shell constant.numeric.octal.shell"},3:{name:"constant.numeric.shell constant.numeric.other.shell"},4:{name:"constant.numeric.shell constant.numeric.integer.shell"},5:{name:"constant.numeric.shell constant.numeric.integer.shell"}},match:"[ \\t]*+(?<==| |\\t|^|\\{|\\(|\\[)(?:(?:(?:(?:(0[xX][0-9A-Fa-f]+)|(0\\d+))|(\\d{1,2}#[0-9a-zA-Z@_]+))|(-?\\d+\\.\\d+))|(-?\\d+))(?!>)"},option:{begin:"[ \\t]++(-)((?!(?:!|&|\\||\\(|\\)|\\{|\\[|<|>|#|\\n|$|;|[ \\t])))",beginCaptures:{1:{name:"string.unquoted.argument.shell constant.other.option.dash.shell"},2:{name:"string.unquoted.argument.shell constant.other.option.shell"}},contentName:"string.unquoted.argument constant.other.option",end:"(?:(?=[ \\t])|(?=;|\\||&|\\n|\\)|\\`|\\{|\\}|[ \\t]*#|\\])(?<!\\\\))",endCaptures:{},patterns:[{include:"#option_context"}]},option_context:{patterns:[{include:"#misc_ranges"},{include:"#string"},{include:"#variable"},{include:"#interpolation"},{include:"#heredoc"},{include:"#herestring"},{include:"#redirection"},{include:"#pathname"},{include:"#keyword"},{include:"#support"}]},pathname:{patterns:[{match:"(?<=\\s|:|=|^)~",name:"keyword.operator.tilde.shell"},{match:"\\*|\\?",name:"keyword.operator.glob.shell"},{begin:"([?*+@!])(\\()",beginCaptures:{1:{name:"keyword.operator.extglob.shell"},2:{name:"punctuation.definition.extglob.shell"}},end:"\\)",endCaptures:{0:{name:"punctuation.definition.extglob.shell"}},name:"meta.structure.extglob.shell",patterns:[{include:"#initial_context"}]}]},pipeline:{patterns:[{match:"(?<=^|;|&|\\s)(time)(?=\\s|;|&|$)",name:"keyword.other.shell"},{match:"[|!]",name:"keyword.operator.pipe.shell"}]},redirect_number:{captures:{1:{name:"keyword.operator.redirect.stdout.shell"},2:{name:"keyword.operator.redirect.stderr.shell"},3:{name:"keyword.operator.redirect.$3.shell"}},match:"(?<=[ \\t])(?:(1)|(2)|(\\d+))(?=>)"},redirection:{patterns:[{begin:"[><]\\(",beginCaptures:{0:{name:"punctuation.definition.string.begin.shell"}},end:"\\)",endCaptures:{0:{name:"punctuation.definition.string.end.shell"}},name:"string.interpolated.process-substitution.shell",patterns:[{include:"#initial_context"}]},{match:"(?<![<>])(&>|\\d*>&\\d*|\\d*(>>|>|<)|\\d*<&|\\d*<>)(?![<>])",name:"keyword.operator.redirect.shell"}]},regex_comparison:{match:"\\=~",name:"keyword.operator.logical.regex.shell"},regexp:{patterns:[{match:".+"}]},simple_options:{captures:{0:{patterns:[{captures:{1:{name:"string.unquoted.argument.shell constant.other.option.dash.shell"},2:{name:"string.unquoted.argument.shell constant.other.option.shell"}},match:"[ \\t]++(\\-)(\\w+)"}]}},match:"(?:[ \\t]++\\-\\w+)*"},start_of_command:{match:"[ \\t]*+(?!(?:!|&|\\||\\(|\\)|\\{|\\[|<|>|#|\\n|$|;|[ \\t]))(?!foreach\\b(?!\\/)|select\\b(?!\\/)|repeat\\b(?!\\/)|until\\b(?!\\/)|while\\b(?!\\/)|case\\b(?!\\/)|done\\b(?!\\/)|elif\\b(?!\\/)|else\\b(?!\\/)|esac\\b(?!\\/)|then\\b(?!\\/)|for\\b(?!\\/)|end\\b(?!\\/)|in\\b(?!\\/)|fi\\b(?!\\/)|do\\b(?!\\/)|if\\b(?!\\/))(?!\\\\\\n?$)"},start_of_double_quoted_command_name:{captures:{1:{name:"entity.name.function.call.shell entity.name.command.shell",patterns:[{match:"\\*",name:"variable.language.special.wildcard.shell"},{include:"#variable"},{include:"#numeric_literal"},{captures:{1:{name:"constant.language.$1.shell"}},match:"(?<!\\w)(\\b(?:true|false)\\b)(?!\\w)"}]}},match:`(?!(?:!|&|\\||\\(|\\)|\\{|\\[|<|>|#|\\n|$|;|[ \\t]))(?:[ \\t]*+([^
3
- '&;<>\\(\\)\\$\`\\\\"\\|]+(?!>)))?(?:(?:\\$")|")`,name:"meta.statement.command.name.quoted.shell string.quoted.double.shell punctuation.definition.string.begin.shell entity.name.function.call.shell entity.name.command.shell"},start_of_single_quoted_command_name:{captures:{1:{name:"entity.name.function.call.shell entity.name.command.shell",patterns:[{match:"\\*",name:"variable.language.special.wildcard.shell"},{include:"#variable"},{include:"#numeric_literal"},{captures:{1:{name:"constant.language.$1.shell"}},match:"(?<!\\w)(\\b(?:true|false)\\b)(?!\\w)"}]}},match:`(?!(?:!|&|\\||\\(|\\)|\\{|\\[|<|>|#|\\n|$|;|[ \\t]))(?:[ \\t]*+([^
4
- '&;<>\\(\\)\\$\`\\\\"\\|]+(?!>)))?(?:(?:\\$')|')`,name:"meta.statement.command.name.quoted.shell string.quoted.single.shell punctuation.definition.string.begin.shell entity.name.function.call.shell entity.name.command.shell"},string:{patterns:[{match:"\\\\.",name:"constant.character.escape.shell"},{begin:"'",beginCaptures:{0:{name:"punctuation.definition.string.begin.shell"}},end:"'",endCaptures:{0:{name:"punctuation.definition.string.end.shell"}},name:"string.quoted.single.shell"},{begin:'\\$?"',beginCaptures:{0:{name:"punctuation.definition.string.begin.shell"}},end:'"',endCaptures:{0:{name:"punctuation.definition.string.end.shell"}},name:"string.quoted.double.shell",patterns:[{match:'\\\\[\\$\\n`"\\\\]',name:"constant.character.escape.shell"},{include:"#variable"},{include:"#interpolation"}]},{begin:"\\$'",beginCaptures:{0:{name:"punctuation.definition.string.begin.shell"}},end:"'",endCaptures:{0:{name:"punctuation.definition.string.end.shell"}},name:"string.quoted.single.dollar.shell",patterns:[{match:"\\\\(?:a|b|e|f|n|r|t|v|\\\\|')",name:"constant.character.escape.ansi-c.shell"},{match:'\\\\[0-9]{3}"',name:"constant.character.escape.octal.shell"},{match:'\\\\x[0-9a-fA-F]{2}"',name:"constant.character.escape.hex.shell"},{match:'\\\\c."',name:"constant.character.escape.control-char.shell"}]}]},support:{patterns:[{match:"(?<=^|;|&|\\s)(?::|\\.)(?=\\s|;|&|$)",name:"support.function.builtin.shell"}]},variable:{patterns:[{captures:{1:{name:"punctuation.definition.variable.shell variable.parameter.positional.all.shell"},2:{name:"variable.parameter.positional.all.shell"}},match:"(\\$)(\\@(?!\\w))"},{captures:{1:{name:"punctuation.definition.variable.shell variable.parameter.positional.shell"},2:{name:"variable.parameter.positional.shell"}},match:"(\\$)([0-9](?!\\w))"},{captures:{1:{name:"punctuation.definition.variable.shell variable.language.special.shell"},2:{name:"variable.language.special.shell"}},match:"(\\$)([-*#?$!0_](?!\\w))"},{begin:"(\\$)(\\{)[ \\t]*+(?=\\d)",beginCaptures:{1:{name:"punctuation.definition.variable.shell variable.parameter.positional.shell"},2:{name:"punctuation.section.bracket.curly.variable.begin.shell punctuation.definition.variable.shell variable.parameter.positional.shell"}},contentName:"meta.parameter-expansion",end:"\\}",endCaptures:{0:{name:"punctuation.section.bracket.curly.variable.end.shell punctuation.definition.variable.shell variable.parameter.positional.shell"}},patterns:[{match:"!|:[-=?]?|\\*|@|##|#|%%|%|\\/",name:"keyword.operator.expansion.shell"},{captures:{1:{name:"punctuation.section.array.shell"},2:{name:"punctuation.section.array.shell"}},match:"(\\[)[^\\]]+(\\])"},{match:"[0-9]+",name:"variable.parameter.positional.shell"},{match:"(?<!\\w)[a-zA-Z_0-9-]+(?!\\w)",name:"variable.other.normal.shell"},{include:"#variable"},{include:"#string"}]},{begin:"(\\$)(\\{)",beginCaptures:{1:{name:"punctuation.definition.variable.shell"},2:{name:"punctuation.section.bracket.curly.variable.begin.shell punctuation.definition.variable.shell"}},contentName:"meta.parameter-expansion",end:"\\}",endCaptures:{0:{name:"punctuation.section.bracket.curly.variable.end.shell punctuation.definition.variable.shell"}},patterns:[{match:"!|:[-=?]?|\\*|@|##|#|%%|%|\\/",name:"keyword.operator.expansion.shell"},{captures:{1:{name:"punctuation.section.array.shell"},2:{name:"punctuation.section.array.shell"}},match:"(\\[)[^\\]]+(\\])"},{match:"(?<!\\w)[a-zA-Z_0-9-]+(?!\\w)",name:"variable.other.normal.shell"},{include:"#variable"},{include:"#string"}]},{captures:{1:{name:"punctuation.definition.variable.shell variable.other.normal.shell"},2:{name:"variable.other.normal.shell"}},match:"(\\$)(\\w+(?!\\w))"}]}},scopeName:"source.shell",aliases:["bash","sh","shell","zsh"]});var n=[e];export{n as default};
@@ -1 +0,0 @@
1
- import{au as m,ba as n,a as s,L as o}from"./entry.Li7bMdxw.js";function u(){const p=m(),t=n("getComponents",()=>o.getComponents()),l=s(()=>Object.entries(p.value?.nuxt?.vueApp._context.components||{}).map(([e])=>({pascalName:e,global:!0})).filter(e=>!/^Lazy[A-Z]/.test(e.pascalName)).filter(e=>!(t.value||[]).find(a=>a.pascalName===e.pascalName)));return s(()=>[...l.value,...t.value||[]].sort((e,a)=>e.pascalName.localeCompare(a.pascalName)))}function r(){return n("getComponentsRelationships",()=>o.getComponentsRelationships())}export{r as a,u};
@@ -1 +0,0 @@
1
- import{_ as F}from"./NBadge.02P0N0hm.js";import{_ as L}from"./NCodeBlock.vue.D7jhLEjr.js";import{_ as A}from"./NCheckbox.vue.m1__cenQ.js";import{d as E,P as G,bb as W,r as V,bc as Y,N as Z,R as q,o as m,l as g,aa as z,f as a,t as $,n as w,F as B,i as s,h as H,j as u,p as h,k as M,v as p,V as J,Y as K,_ as O,Z as Q,bd as X,ab as ee,a as te,ar as ae,as as ne,be as se,ba as oe}from"./entry.Li7bMdxw.js";const le={key:0},re={p4:"",flex:"~ col gap-1"},ue={class:"text-lg font-medium leading-6"},ie=h("p",{op50:""}," The following command will be executed in your terminal: ",-1),ce={flex:"~ gap-3",mt2:"","justify-end":""},ve=E({__name:"NpmVersionCheck",props:{packageName:{},options:{},showVersion:{type:Boolean,default:!0}},setup(l){const t=l,e=G(),{info:n,update:i,state:y,processId:k,restart:d}=W(t.packageName,t.options),f=V(!0),_=V(!0),R=Y(),b=Z(),U=q();async function N(){const r=await i(async o=>b.start(o));J("npm:update",{packageName:t.packageName,oldVersion:n.value?.current}),r&&_.value&&R.value.push({id:r,message:`${t.packageName} has been updated. Do you want to restart the Nuxt server now?`}),r&&f.value&&(U.value=r,e.push("/modules/terminals"))}return(r,o)=>{const C=F,S=L,x=A,T=K,P=O,I=Q;return m(),g(B,null,[z(r.$slots,"default",{id:a(k),info:a(n),update:N,state:a(y),restart:a(d)},()=>[a(n)&&r.showVersion?(m(),g("code",le,$(`v${a(n).current}`),1)):w("",!0),a(n)?.latest?(m(),g(B,{key:1},[a(n).needsUpdate?(m(),g("button",{key:0,onClick:o[0]||(o[0]=v=>N())},[s(C,{n:"green",title:"updates available",textContent:"updates available"})])):(m(),H(C,{key:1,n:"gray",title:"latest",textContent:"latest"}))],64)):w("",!0)]),s(a(b),null,{default:u(({resolve:v,args:j})=>[s(I,{"model-value":!0,onClose:c=>v(!1)},{default:u(()=>[h("div",re,[h("h3",ue," Update "+$(t.packageName)+"? ",1),ie,s(S,{code:j[0],lang:"bash",my3:"",px4:"",py2:"",border:"~ base rounded",lines:!1},null,8,["code"]),s(x,{modelValue:a(f),"onUpdate:modelValue":o[1]||(o[1]=c=>M(f)?f.value=c:null),n:"primary"},{default:u(()=>[p(" Navigate to terminal ")]),_:1},8,["modelValue"]),s(x,{modelValue:a(_),"onUpdate:modelValue":o[2]||(o[2]=c=>M(_)?_.value=c:null),n:"primary"},{default:u(()=>[p(" Restart Nuxt server after update ")]),_:1},8,["modelValue"]),h("div",ce,[s(T,{n:"sm amber","flex-auto":"",icon:"i-carbon-data-backup"},{default:u(()=>[p(" Please make sure to backup your project first. ")]),_:1}),s(P,{onClick:c=>v(!1)},{default:u(()=>[p(" Cancel ")]),_:2},1032,["onClick"]),s(P,{n:"solid primary",onClick:c=>v(!0)},{default:u(()=>[p(" Update ")]),_:2},1032,["onClick"])])])]),_:2},1032,["onClose"])]),_:1})],64)}}}),D=["pages","meta","components","imports","nuxt-config-schema","@nuxt/devtools","@nuxt/telemetry"];function de(){return oe("getModulesList",async()=>(await $fetch("https://api.nuxt.com/modules?version=3")).modules.filter(t=>!D.includes(t.npm)&&t.compatibility.nuxt.includes("^3")))}function ge(){return X("installed-modules",()=>{const l=ee(),t=de();return te(()=>(l.value?._installedModules||[]).map(e=>{if(!e.entryPath)return;const n=e.entryPath&&ae(e.entryPath),i=e.meta?.name?e.meta?.name:e.entryPath?n?ne(e.entryPath):l.value?.rootDir?se(e.entryPath,l.value?.rootDir).path:void 0:void 0,y=l.value?.modules?.includes(i),k=t.value?.find(d=>d.npm===i)||t.value?.find(d=>d.name===i);return{name:i,isPackageModule:n,isUninstallable:y,info:k,...e}}).filter(e=>e&&(!e.name||!D.includes(e.name))))})}export{ve as _,de as a,ge as u};
@@ -1 +0,0 @@
1
- import{_ as B}from"./NCodeBlock.vue.D7jhLEjr.js";import{d as N,by as R,e as $,a as D,az as T,o as n,l as a,p as c,F as f,m as V,G as m,f as t,t as z,i as _,j as v,v as b,h as L,n as l,_ as E,r as y,L as p,bz as g,bu as h}from"./entry.Li7bMdxw.js";const F={key:0,relative:"","n-code-block":""},W={flex:"~ wrap","w-full":""},j=["onClick"],G=c("div",{border:"b base","flex-auto":""},null,-1),q={flex:"~ gap-2",px3:"",pb3:"",n:"sm primary"},P=N({__name:"CodeSnippets",props:{codeSnippets:{},eventType:{}},setup(s){const r=s,e=R(r.codeSnippets[0]),w=$(),x=D(()=>e.value?.lang||"text");return T(()=>{r.codeSnippets.includes(e.value)||(e.value=r.codeSnippets[0])}),(i,d)=>{const S=B,u=E;return i.codeSnippets.length?(n(),a("div",F,[c("div",W,[(n(!0),a(f,null,V(i.codeSnippets,(o,O)=>(n(),a("button",{key:O,px4:"",py2:"",border:"r base",hover:"bg-active",class:m(o===t(e)?"":"border-b"),onClick:J=>e.value=o},[c("div",{class:m(o===t(e)?"":"op30"),"font-mono":""},z(o.name),3)],10,j))),128)),G]),t(e)?(n(),a(f,{key:0},[_(S,{code:t(e).code,lang:t(x),lines:!1,"w-full":"","of-auto":"",p3:""},null,8,["code","lang"]),c("div",q,[_(u,{icon:"carbon-copy",onClick:d[0]||(d[0]=o=>t(w)(t(e).code,i.eventType||`code-snippet-${t(e).name}`))},{default:v(()=>[b(" Copy ")]),_:1}),t(e)?.docs?(n(),L(u,{key:0,to:t(e).docs,target:"_blank",icon:"carbon-catalog"},{default:v(()=>[b(" Docs ")]),_:1},8,["to"])):l("",!0)])],64)):l("",!0)])):l("",!0)}}}),k=y(await p.getOptions("assets")),A=g(k);h(k,async s=>{p.updateOptions("assets",s)},{deep:!0,flush:"post",debounce:500,maxWait:1e3});const C=y(await p.getOptions("serverRoutes")),H=g(C);h(C,async s=>{p.updateOptions("serverRoutes",s)},{deep:!0,flush:"post",debounce:500,maxWait:1e3});const I={serverRoutes:H,assets:A};function Q(s){return I[s]}export{P as _,Q as u};
@@ -1 +0,0 @@
1
- import{d as R,P as ne,r as A,Q as T,bA as z,aA as ae,w as oe,az as se,a1 as le,a as re,L as f,M as k,f as t,o as l,h as m,j as u,i as c,k as D,F as w,t as b,l as i,m as U,p as r,G as E,ae as M,v as d,n as F,at as ue,bf as ie,af as de,I as ce,bB as pe,bC as G,_ as me,X as _e,a6 as fe,ao as ve,A as ye,U as ge,aG as he}from"./entry.Li7bMdxw.js";import{_ as ke}from"./NSelect.vue.zI1gfDpy.js";import{_ as be}from"./NLink.vue.Bj0qXc3J.js";import{_ as xe}from"./FilepathItem.vue.e1n0RyHZ.js";import{q as we}from"./json-editor-vue.qZEps2wJ.js";const Ce={class:"h-[48px] flex items-center justify-between gap1 px-3"},Ke={class:"w-full text-sm"},Se=["value"],Ve=["onClick"],$e=r("div",{"x-divider":""},null,-1),Ne={key:0,"h-full":"","of-hidden":"",flex:"~ col"},Ie={border:"b base",class:"h-[49px] flex flex-none items-center justify-between px-4 text-sm"},je={class:"flex items-center gap-4"},Ae={key:1},De=["onKeyup"],Ue=r("br",null,null,-1),Me={key:0,op50:""},qe={key:1},Be=r("code",null,"nitro.storage",-1),Le=r("br",null,null,-1),Pe={"font-bold":""},Te=r("br",null,null,-1),ze={"text-sm":""},Ee=r("br",null,null,-1),Fe=R({__name:"StorageDetails",async setup(O){let p,g;const C=pe(),h=ne(),x=A(""),v=A(""),s=T("storage:current",""),e=A(),y=T("storage:file:state",""),{data:K}=([p,g]=z(()=>G("storageMounts",()=>f.getStorageMounts())),p=await p,g(),p),{data:S,refresh:q}=([p,g]=z(async()=>G("storageKeys",async()=>s.value?await f.getStorageKeys(s.value):[])),p=await p,g(),p),Q=C.hook("storage:key:update",async(n,a)=>{if(!(!s.value||n.split(":")[0]!==s.value)&&(await q(),y.value===n)){if(a==="remove")return h.replace({query:{storage:s.value}});await $(y.value)}});ae(Q),oe(s,()=>{q(),y.value=""}),se(async()=>{if(!y.value){e.value=null;return}$(y.value)}),le("keydown",n=>{n.key==="s"&&(n.ctrlKey||n.metaKey)&&(N(),n.preventDefault())});function V(n){return n.replace(`${s.value}:`,"")}const W=re(()=>S.value?S.value.filter(n=>n.includes(x.value)):[]);async function $(n){const a=await f.getStorageItem(await k(),n);e.value={key:n,updatedKey:V(n),editingKey:!1,content:a,updatedContent:a}}async function X(){if(!v.value||!s.value)return;const n=`${s.value}:${v.value}`;S.value?.includes(n)||await f.setStorageItem(await k(),n,""),h.replace({query:{storage:s.value,key:n}}),v.value=""}async function N(){e.value&&(await f.setStorageItem(await k(),e.value.key,e.value.updatedContent),await $(e.value.key))}async function H(){!e.value||!s.value||(await f.removeStorageItem(await k(),e.value.key),e.value=null)}async function J(){if(!e.value||!s.value)return;const n=`${s.value}:${e.value.updatedKey}`,a=await k();await f.setStorageItem(a,n,e.value.updatedContent),await f.removeStorageItem(a,e.value.key),h.replace({query:{storage:s.value,key:n}})}return(n,a)=>{const I=me,Y=ke,j=_e,Z=fe,B=be,L=ve,P=ye,ee=ge,te=xe;return t(s)?(l(),m(ee,{key:0,"storage-key":"tab-storage"},{left:u(()=>[r("div",Ce,[c(I,{icon:"carbon-chevron-left","ml--1":"",border:!1,onClick:a[0]||(a[0]=o=>s.value="")}),r("div",Ke,[c(Y,{modelValue:t(s),"onUpdate:modelValue":a[1]||(a[1]=o=>D(s)?s.value=o:null),n:"primary",icon:"carbon-data-base"},{default:u(()=>[(l(!0),i(w,null,U(t(K),(o,_)=>(l(),i("option",{key:_,value:_},b(_),9,Se))),128))]),_:1},8,["modelValue"])])]),c(j,{modelValue:t(x),"onUpdate:modelValue":a[2]||(a[2]=o=>D(x)?x.value=o:null),icon:"carbon-search",placeholder:"Search...",n:"primary sm",border:"y x-none base! rounded-0",class:"w-full py2 ring-0!"},null,8,["modelValue"]),(l(!0),i(w,null,U(t(W),o=>(l(),i(w,{key:o},[r("button",{block:"","w-full":"",truncate:"",px2:"",py1:"","text-start":"","text-sm":"","font-mono":"",class:E(o===t(e)?.key?"text-primary n-bg-active":"text-secondary hover:n-bg-hover"),onClick:_=>y.value=o},b(V(o)),11,Ve),$e],64))),128)),c(j,{modelValue:t(v),"onUpdate:modelValue":a[3]||(a[3]=o=>D(v)?v.value=o:null),icon:"carbon-add",placeholder:"key",n:"sm",border:"t-none x-none base! rounded-0",class:"w-full py2 font-mono ring-0!",onKeyup:M(X,["enter"])},null,8,["modelValue"])]),right:u(()=>[t(e)?.key?(l(),i("div",Ne,[r("div",Ie,[r("div",je,[t(e).editingKey?(l(),m(j,{key:0,modelValue:t(e).updatedKey,"onUpdate:modelValue":a[4]||(a[4]=o=>t(e).updatedKey=o),onKeyup:M(J,["enter"])},null,8,["modelValue"])):(l(),i("code",Ae,[d(b(V(t(e).key))+" ",1),c(Z,{icon:"carbon-edit",class:"cursor-pointer op50 hover:op100",onClick:a[5]||(a[5]=o=>t(e).editingKey=!0)})])),t(e).editingKey?F("",!0):(l(),m(I,{key:2,n:"green xs",disabled:t(e).content===t(e).updatedContent,class:E({"border-green":t(e).content!==t(e).updatedContent}),onClick:N},{default:u(()=>[d(" Save ")]),_:1},8,["disabled","class"]))]),r("div",null,[c(I,{n:"red xs",onClick:H},{default:u(()=>[d(" Delete ")]),_:1})])]),typeof t(e).content=="object"?(l(),m(t(we),ue({key:0,modelValue:t(e).updatedContent,"onUpdate:modelValue":a[6]||(a[6]=o=>t(e).updatedContent=o),class:[[n.$colorMode.value==="dark"?"jse-theme-dark":"light"],"json-editor-vue h-full of-auto text-sm outline-none"]},n.$attrs,{mode:"text","navigation-bar":!1,indentation:2,"tab-size":2}),null,16,["modelValue","class"])):ce((l(),i("textarea",{key:1,"onUpdate:modelValue":a[7]||(a[7]=o=>t(e).updatedContent=o),placeholder:"Item value...",class:"h-full of-auto p-4 text-sm font-mono outline-none",onKeyup:M(ie(N,["ctrl"]),["enter"])},null,40,De)),[[de,t(e).updatedContent]])])):(l(),m(P,{key:1},{default:u(()=>[c(L,{px6:"",py4:""},{default:u(()=>[d(" Select one key to start."),Ue,d("Learn more about "),c(B,{href:"https://nitro.unjs.io/guide/storage",n:"orange",target:"_blank"},{default:u(()=>[d(" Nitro storage ")]),_:1})]),_:1})]),_:1}))]),_:1})):(l(),m(P,{key:1},{default:u(()=>[Object.keys(t(K)).length?(l(),i("p",Me," Select one storage to start: ")):(l(),i("p",qe,[d(" No custom storage defined in "),Be,d("."),Le,d(" Learn more about "),c(B,{href:"https://nitro.unjs.io/guide/storage",n:"orange",target:"_blank"},{default:u(()=>[d(" Nitro storage ")]),_:1})])),(l(!0),i(w,null,U(t(K),(o,_)=>(l(),m(L,{key:_,"min-w-80":"","cursor-pointer":"","p-4":"","text-left":"",hover:"border-green",onClick:Ge=>s.value=_},{default:u(()=>[r("span",Pe,b(_),1),Te,r("span",ze,b(o.driver)+" driver",1),Ee,o.base?(l(),m(te,{key:0,"text-xs":"",filepath:o.base},null,8,["filepath"])):F("",!0)]),_:2},1032,["onClick"]))),128))]),_:1}))}}}),He=R({__name:"storage",setup(O){return(p,g)=>{const C=Fe,h=he;return l(),m(h,null,{default:u(()=>[c(C)]),_:1})}}});export{He as default};
@@ -1,30 +0,0 @@
1
- import{d as B,a as w,aH as W,o as t,l as c,p as s,a9 as T,f as l,t as k,ad as O,F as f,m as E,h as y,r as C,w as q,ay as Y,a1 as j,bE as U,n as x,i as m,G as z,q as Z,e as K,ap as H,j as v,at as X,v as F,_ as G,aJ as Q,au as ee,a$ as se,bF as te,ab as ne,N as oe,ac as ae,A as le,L as R,a5 as ie,Z as re}from"./entry.Li7bMdxw.js";import{_ as M}from"./DurationDisplay.vue.zHxKl3h_.js";import{_ as P}from"./NBadge.02P0N0hm.js";import{_ as ce}from"./ComposableItem.vue.T22_QMe3.js";import{q as pe}from"./json-editor-vue.qZEps2wJ.js";import{_ as de}from"./StacktraceList.vue.K3UX7GrW.js";import{_ as ue}from"./NDrawer.vue.biTr62KW.js";import{_ as me}from"./LaunchPage.vue.Mrnd5FUf.js";import{_ as ke}from"./NLink.vue.Bj0qXc3J.js";import{_ as he}from"./CodeDiff.vue.yvGsYwMX.js";import{_ as _e}from"./HelpFab.vue.9P-8iMDH.js";import"./NMarkdown.vue.Ej8wmZFm.js";import"./client.UdRQ7dYn.js";import"./FilepathItem.vue.e1n0RyHZ.js";import"./constants.jFgWOlQV.js";import"./NCodeBlock.vue.D7jhLEjr.js";const fe=B({__name:"TimelineItemFunction",props:{item:{}},setup(_){const d=_,p=w(()=>W(d.item.name,50,60,"_op_")),e=w(()=>p.value.replace(/_op_/,"1")),o=w(()=>W(d.item.name,50,40)),i=w(()=>p.value.replace(/_op_/,"0.2"));return(n,a)=>(t(),c("button",{class:"group",style:T({color:l(e),borderLeft:`2px solid ${l(e)}`}),relative:"","text-sm":"",transition:"","hover:z-1000":"","bg-base":""},[s("div",{style:T({backgroundColor:l(i)}),absolute:"","bottom-0":"","left--1px":"","top-0":"","w-full":"","text-sm":"","transition-all":"","duration-300":""},null,4),s("div",{style:T({color:l(o),"--c":l(e)}),border:"r-2 t-2 y-2 transparent","min-w-max":"",px1:"","text-left":"","group-hover":"border-$c"},k(n.item.name),5)],4))}}),ye={relative:"","h-full":""},ve={absolute:"","left-2":"","top-2.3em":"","text-xs":"",op50:""},be=B({__name:"TimelineSegment",props:{segment:{}},emits:["select"],setup(_,{emit:d}){const p=_,e=d,o=O(()=>p.segment.start,{updateInterval:1e3,showSecond:!0,messages:{justNow:"",past:i=>i,future:i=>i,invalid:"-",second:i=>i?`${i}s`:"",minute:i=>`${i}m`,hour:i=>`${i}h`,week:i=>`${i}w`,day:i=>`${i}d`,month:i=>`${i}mo`,year:i=>`${i}y`}});return(i,n)=>{const a=fe;return t(),c("div",ye,[s("button",{absolute:"","left-0":"","right-0":"","top-0":"","bg-green:5":"",px2:"",py1:"","text-left":"","text-xs":"","text-green6":"","font-mono":"",onClick:n[0]||(n[0]=r=>i.segment.route?e("select",i.segment.route):void 0)},k(i.segment.route?.event.to),1),s("div",ve,k(l(o))+" ago ",1),s("div",null,[(t(!0),c(f,null,E(i.segment.functions,(r,u)=>(t(),y(a,{key:u,item:r.event,style:T({position:"absolute",minWidth:`${r.relativeWidth*100}%`,maxWidth:`${r.relativeWidth*100}%`,top:`${4+r.layer*1.6}em`,left:`${r.relativeStart*100}%`}),onClick:h=>e("select",r)},null,8,["item","style","onClick"]))),128))])])}}}),ge=3e3,xe=50;function $e(_){const d=[];let p={start:0,end:0,events:[],functions:[],duration:0};for(const e of _){const o=e.end||e.start;(e.start-p.end>ge||e.type==="route")&&(p={start:e.start,end:o,events:[],functions:[],duration:0},d.push(p)),p.events.push(e),p.end=o+xe}return d.forEach((e,o)=>{const i=e.end-e.start,n=[];e.duration=i,e.previousGap=o>0?e.start-d[o-1].end:0,e.events.forEach(a=>{const r=a.end||a.start;let u=0;a.type!=="route"&&(u=n.findIndex($=>$<=a.start),u===-1?(u=n.length,n.push(r+1e3)):n[u]=r+1e3);const h={event:a,segment:e,relativeStart:(a.start-e.start)/i,relativeWidth:(r-a.start)/i,layer:u};a.type==="function"?e.functions.push(h):e.route=h})}),d}const Ae={relative:""},De={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":""},Ce=B({__name:"TimelineTable",props:{data:{}},emits:["select"],setup(_,{emit:d}){const p=_,e=d,o=C(),i=C(),n=C(),a=C(),r=C(!0),u=C(1.5),h=w(()=>$e(p.data.events)),$=w(()=>(p.data.events.length,o.value?.scrollWidth||window.innerWidth));function A(){a.value&&(a.value.style.width=`${$.value}px`)}function S(){r.value&&o.value&&(o.value.scrollTo({left:o.value.scrollWidth-o.value.clientWidth,behavior:"smooth"}),n.value.scrollTo({left:o.value.scrollWidth-o.value.clientWidth,behavior:"smooth"}))}return q(()=>p.data.events.length,async()=>{await Y(),A(),S()},{flush:"post"}),j(o,"scroll",()=>{n.value.scrollLeft!==o.value.scrollLeft&&(A(),n.value.scrollLeft=o.value.scrollLeft,r.value=o.value.scrollLeft>=o.value.scrollWidth-o.value.clientWidth)}),j(n,"scroll",()=>{n.value.scrollLeft!==o.value.scrollLeft&&(A(),o.value.scrollLeft=n.value.scrollLeft)}),j(o,"wheel",b=>{b.altKey?(u.value=U(u.value+b.deltaY/200,.5,3),A()):o.value.scrollLeft+=b.deltaY}),(b,L)=>{const D=M,V=be;return t(),c(f,null,[s("div",Ae,[s("div",{ref_key:"minimap",ref:i,border:"t b base",relative:"","h-50px":"","ws-nowrap":"","border-base":""},[(t(!0),c(f,null,E(l(h),(g,N)=>(t(),c("div",{key:N,relative:"","h-full":"","flex-inline":"",style:T({width:`${Math.max(100,g.duration/10)/l($)*100}%`})},[(t(!0),c(f,null,E(g.functions,(I,J)=>(t(),c("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 b?b.getHashColorFromString:l(W))(I.event.name,50,60)})},null,4))),128)),g.route?(t(),c("div",{key:0,absolute:"","top-0":"","h-full":"","w-px":"","border-l":"","border-green6":"",op10:"",style:T({left:`${g.route.relativeStart*100}%`})},null,4)):x("",!0)],4))),128))],512),s("div",{ref_key:"minimapScroller",ref:n,class:"timeline-scroller",absolute:"","inset-0":"","h-full":"","w-full":"","of-x-scroll":""},[s("div",{ref_key:"minimapScrollerInner",ref:a,"h-1px":""},null,512)],512)]),s("div",{ref_key:"scroller",ref:o,relative:"","h-full":"","w-full":"","of-x-scroll":"","of-y-hidden":"","ws-nowrap":"","n-panel-grids":""},[(t(!0),c(f,null,E(l(h),(g,N)=>(t(),c(f,{key:N},[g.previousGap&&g.previousGap>=200?(t(),c("div",De,[m(D,{op50:"",duration:g.previousGap,color:!1},null,8,["duration"])])):x("",!0),m(V,{"flex-inline":"","of-x-hidden":"","hover:of-x-visible":"","bg-base":"",class:z(N===l(h).length-1?"border-r border-base":""),segment:g,style:T({width:`${Math.max(50,g.duration/10)*l(u)}px`}),onSelect:L[0]||(L[0]=I=>e("select",I))},null,8,["class","segment","style"])],64))),128))],512)],64)}}}),Be=Z(Ce,[["__scopeId","data-v-27e8fb2d"]]),we={border:"t base",flex:"~ col","h-full":"","of-y-auto":"","text-sm":""},Te=["onClick"],Se=s("div",{"i-carbon-function":"",op50:""},null,-1),Ne={flex:"~","ml--1":"","font-mono":""},Fe=s("div",{op30:""}," ( ",-1),Ee={key:0,mr2:"",op30:""},Le={op75:""},Ie=s("div",{op30:""}," ) ",-1),Ve=s("div",{"mr-1":"","h-7":"","w-7":"",flex:"","rounded-lg":"","bg-primary:5":"",p1:"","text-green6":""},[s("div",{"i-carbon-direction-rotary-right":"",ma:"","text-lg":""})],-1),We={flex:"~ col items-start"},Me={"text-xs":"","font-mono":"",op30:""},je={"text-green":"","font-bold":"","font-mono":""},Oe=s("div",{"flex-auto":""},null,-1),ze=s("div",{"min-h-100":""},null,-1),Ge=B({__name:"TimelineList",props:{data:{}},emits:["select"],setup(_,{emit:d}){const p=d;return(e,o)=>{const i=M;return t(),c("div",we,[(t(!0),c(f,null,E(e.data.events,(n,a)=>(t(),c("button",{key:a,border:"b base",px3:"",py2:"",flex:"~ items-center gap-2",hover:"bg-active",onClick:r=>p("select",n)},[n.type==="function"?(t(),c(f,{key:0},[Se,s("div",{"font-mono":"",style:T({color:n.type==="function"?("getHashColorFromString"in e?e.getHashColorFromString:l(W))(n.name,50,60):""})},k(n.name),5),s("div",Ne,[Fe,(t(!0),c(f,null,E(n.args,(r,u)=>(t(),c(f,{key:u},[u?(t(),c("div",Ee," , ")):x("",!0),s("div",Le,k(r===null?"null":r===void 0?"undefined":typeof r=="function"?"[function]":Array.isArray(r)?"[Array]":typeof r=="object"?"[object]":JSON.stringify(r)),1)],64))),128)),Ie])],64)):(t(),c(f,{key:1},[Ve,s("div",We,[s("div",Me,k(n.from),1),s("div",je,k(n.to),1)])],64)),Oe,n.end?(t(),y(i,{key:2,duration:n.end-n.start,color:n.type==="function"},null,8,["duration","color"])):x("",!0)],8,Te))),128)),ze])}}}),Re={key:0,"text-blue":""},He={key:1,"text-purple":""},Pe={key:2,"text-green":""},Je={key:3,"text-gray":""},qe={key:4,"text-gray":""},Ye={key:5,"text-gray":""},Ue={key:0,"bg-red:10":"",px2:"",py1:"","text-red":""},Ze={key:1},Ke={p2:"","text-sm":"",border:"t base"},Xe=B({__name:"TimelineArgumentView",props:{value:{}},setup(_){const d=_,p=C(),e=C();function o(){try{p.value=JSON.parse(JSON.stringify(d.value))}catch(a){console.error(a),e.value=a}}const i=B({emits:["setup"],setup(a,{emit:r}){return r("setup"),()=>null}}),n=K();return(a,r)=>{const u=G,h=H("VMenu");return typeof a.value=="string"?(t(),c("div",Re,k(JSON.stringify(a.value)),1)):typeof a.value=="number"?(t(),c("div",He,k(a.value),1)):typeof a.value=="boolean"?(t(),c("div",Pe,k(a.value),1)):typeof a.value>"u"?(t(),c("div",Je," undefined ")):typeof a.value=="function"?(t(),c("div",qe," [Function"+k(a.value.name?`: ${a.value.name}`:"")+"] ",1)):a.value===null?(t(),c("div",Ye," null ")):(t(),y(h,{key:6,placement:"top"},{popper:v(()=>[m(l(i),{onSetup:o}),l(e)?(t(),c("div",Ue," Failed to display object: "+k(l(e)),1)):l(p)?(t(),c("div",Ze,[m(l(pe),X({"model-value":l(p)},a.$attrs,{class:["json-editor-vue",[a.$colorMode.value==="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"]),s("div",Ke,[m(u,{title:"Copy to clipboard",icon:"carbon-copy",onClick:r[0]||(r[0]=$=>l(n)(JSON.stringify(l(p),null,2),"timeline-argument"))},{default:v(()=>[F(" Copy ")]),_:1})])])):x("",!0)]),default:v(()=>[s("span",{"rounded-sm":"",px1:"","py0.5":"","text-sm":"",class:z([Array.isArray(a.value)?"text-amber bg-amber:10":"text-orange bg-orange:10"])},k(Array.isArray(a.value)?`[Array(${a.value.length})]`:"[Object]"),3)]),_:1}))}}}),Qe={key:0,"p-4":"",flex:"~ col gap-2","text-base":""},es={"mx--1":""},ss={flex:"~ gap-1","font-mono":""},ts={key:1},ns=s("span",{ml1:"",op30:""},"(",-1),os={key:0,op30:""},as=s("span",{op30:""},")",-1),ls={flex:"~ gap-1","text-sm":""},is=s("span",{mx1:"",op50:""},"·",-1),rs={class:"text-sm text-gray-400"},cs=B({__name:"TimelineDetailsFunction",props:{record:{}},setup(_){const d=_,p=O(()=>d.record.start,{showSecond:!0}),e=Q(),o=w(()=>e.value?.metadata),i=w(()=>e.value?.imports.find(n=>n.as===d.record.name));return(n,a)=>{const r=P,u=ce,h=Xe,$=M,A=de;return n.record?(t(),c("div",Qe,[s("div",es,[m(r,{n:"yellow",textContent:"Function call"})]),s("div",ss,[l(i)?(t(),y(u,{key:0,item:l(i),metadata:l(o),counter:!1,classes:"px2 py1","mx--2":""},null,8,["item","metadata"])):(t(),c("span",ts,k(n.record.name),1)),ns,(t(!0),c(f,null,E(n.record.args,(S,b)=>(t(),c(f,{key:b},[b?(t(),c("span",os,", ")):x("",!0),m(h,{value:S},null,8,["value"])],64))),128)),as]),s("div",ls,[n.record.end?(t(),y($,{key:0,duration:n.record.end-n.record.start},null,8,["duration"])):x("",!0),is,s("div",rs,k(l(p)),1)]),n.record.stacktrace?(t(),y(A,{key:0,stacktrace:n.record.stacktrace,class:"text-xs text-gray-400"},null,8,["stacktrace"])):x("",!0)])):x("",!0)}}}),ps={key:0,"p-4":"",flex:"~ col gap-2"},ds={"mx--1":""},us={flex:"~ gap-1 items-center","font-mono":""},ms={op50:""},ks=s("span",{"i-carbon-arrow-right":"",op50:""},null,-1),hs={flex:"~ gap-1","text-sm":""},_s=s("span",{mx1:"",op50:""},"·",-1),fs={class:"text-sm text-gray-400"},ys=B({__name:"TimelineDetailsRoute",props:{record:{}},setup(_){const d=_,p=O(()=>d.record.start,{showSecond:!0});return(e,o)=>{const i=P,n=M;return e.record?(t(),c("div",ps,[s("div",ds,[m(i,{n:"green",textContent:"Route Change"})]),s("div",us,[s("span",ms,k(e.record.from),1),ks,s("span",null,k(e.record.to),1)]),s("div",hs,[e.record.end?(t(),y(n,{key:0,duration:e.record.end-e.record.start},null,8,["duration"])):x("",!0),_s,s("div",fs,k(l(p)),1)])])):x("",!0)}}}),vs={key:0,"h-screen":"","of-hidden":""},bs={"h-screen":"","w-full":"",flex:"","flex-col":""},gs={"h-10":"",flex:"~ gap-2 items-center justify-end",p2:"",px3:""},xs={"text-sm":""},$s=s("div",{"flex-auto":""},null,-1),As={"min-h-50":"",px3:"",py2:""},Ds=B({__name:"TimelineView",setup(_){const d=ee(),p=C("table"),e=C(),o=w(()=>d.value?.metrics.clientTimeline());function i(){o.value&&(o.value.events=[])}function n(){p.value=p.value==="table"?"list":"table"}return(a,r)=>{const u=H("VTooltip"),h=G,$=Be,A=Ge,S=cs,b=ys,L=ue;return l(o)?(t(),c("div",vs,[s("div",bs,[s("div",gs,[m(u,{flex:""},{popper:v(()=>[s("div",xs,k(l(o).options.enabled?"Recording...":"Paused"),1)]),default:v(()=>[s("div",{"text-lg":"",class:z(l(o).options.enabled?"i-carbon-radio-button-checked text-primary animate-pulse":"i-carbon-pause-outline op30")},null,2)]),_:1}),l(o).options.enabled?(t(),y(h,{key:1,size:"small",ml1:"","text-sm":"",n:"orange",icon:"i-carbon-stop",onClick:r[1]||(r[1]=D=>l(o).options.enabled=!1)},{default:v(()=>[F(" Stop Tracking ")]),_:1})):(t(),y(h,{key:0,size:"small",ml1:"","text-sm":"",n:"primary",icon:"i-carbon-play",onClick:r[0]||(r[0]=D=>l(o).options.enabled=!0)},{default:v(()=>[F(" Start Tracking ")]),_:1})),$s,m(h,{icon:l(p)==="table"?"i-carbon-roadmap":"i-carbon-list",class:"ml-2",title:"Toggle View",border:!1,onClick:n},null,8,["icon"]),m(h,{icon:"i-carbon-trash-can","hover-text-red":"",class:"ml-2",border:!1,onClick:i})]),l(p)==="table"?(t(),y($,{key:0,data:{...l(o)},onSelect:r[2]||(r[2]=D=>e.value=D.event)},null,8,["data"])):(t(),y(A,{key:1,data:{...l(o)},onSelect:r[3]||(r[3]=D=>e.value=D)},null,8,["data"]))]),m(L,{"model-value":!!l(e),"auto-close":"",transition:"bottom",left:"#nuxt-devtools-side-nav",onClose:r[4]||(r[4]=D=>e.value=void 0)},{default:v(()=>[s("div",As,[l(e)?.type==="function"?(t(),y(S,{key:0,record:l(e)},null,8,["record"])):l(e)?.type==="route"?(t(),y(b,{key:1,record:l(e)},null,8,["record"])):x("",!0)])]),_:1},8,["model-value"])])):x("",!0)}}}),Cs={class:"markdown-body"},Bs=s("h1",null,"Timeline",-1),ws=s("p",null,[s("blockquote",{"text-orange":"","bg-orange:10":"",py1:""}," This is an experimental feature ")],-1),Ts=se(`<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 &#39;#imports&#39;</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;">&lt;</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;">&gt;</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;"> useMouse</span><span style="color:#999999;--shiki-dark:#666666;"> }</span><span style="color:#1E754F;--shiki-dark:#4D9375;"> from</span><span style="color:#B5695999;--shiki-dark:#C98A7D99;"> &#39;</span><span style="color:#B56959;--shiki-dark:#C98A7D;">@vueuse/core</span><span style="color:#B5695999;--shiki-dark:#C98A7D99;">&#39;</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:#B5695999;--shiki-dark:#C98A7D99;"> &#39;</span><span style="color:#B56959;--shiki-dark:#C98A7D;">#imports</span><span style="color:#B5695999;--shiki-dark:#C98A7D99;">&#39;</span></span>
4
- <span class="line"></span>
5
- <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>
6
- <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>
7
- <span class="line"></span>
8
- <span class="line"><span style="color:#A0ADA0;--shiki-dark:#758575DD;">// NOT tracked because it&#39;s directly imported</span></span>
9
- <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>
10
- <span class="line"><span style="color:#999999;--shiki-dark:#666666;">&lt;/</span><span style="color:#1E754F;--shiki-dark:#4D9375;">script</span><span style="color:#999999;--shiki-dark:#666666;">&gt;</span></span>
11
- <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>
12
- <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>
13
- <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>
14
- <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>
15
- <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>
16
- <span class="line"><span style="color:#A0ADA0;--shiki-dark:#758575DD;"> // track \`useMouse\`</span></span>
17
- <span class="line"><span style="color:#B5695999;--shiki-dark:#C98A7D99;"> &#39;</span><span style="color:#B56959;--shiki-dark:#C98A7D;">useMouse</span><span style="color:#B5695999;--shiki-dark:#C98A7D99;">&#39;</span><span style="color:#999999;--shiki-dark:#666666;">,</span></span>
18
- <span class="line"><span style="color:#A0ADA0;--shiki-dark:#758575DD;"> // track all functions starting with \`use\`</span></span>
19
- <span class="line"><span style="color:#B5695999;--shiki-dark:#C98A7D99;"> /</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:#B5695999;--shiki-dark:#C98A7D99;">/</span><span style="color:#999999;--shiki-dark:#666666;">,</span></span>
20
- <span class="line"><span style="color:#A0ADA0;--shiki-dark:#758575DD;"> // track all functions from @vueuse/core</span></span>
21
- <span class="line"><span style="color:#B07D48;--shiki-dark:#BD976A;"> entry</span><span style="color:#999999;--shiki-dark:#666666;"> =&gt;</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:#B5695999;--shiki-dark:#C98A7D99;"> &#39;</span><span style="color:#B56959;--shiki-dark:#C98A7D;">@vueuse/core</span><span style="color:#B5695999;--shiki-dark:#C98A7D99;">&#39;</span><span style="color:#999999;--shiki-dark:#666666;">,</span></span>
22
- <span class="line"><span style="color:#999999;--shiki-dark:#666666;"> ],</span></span>
23
- <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>
24
- <span class="line"><span style="color:#B5695999;--shiki-dark:#C98A7D99;"> &#39;</span><span style="color:#B56959;--shiki-dark:#C98A7D;">useRouter</span><span style="color:#B5695999;--shiki-dark:#C98A7D99;">&#39;</span></span>
25
- <span class="line"><span style="color:#999999;--shiki-dark:#666666;"> ]</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></code></pre>`,6),Ss=[Bs,ws,Ts],Ns={__name:"timeline",setup(_,{expose:d}){return d({frontmatter:{}}),(e,o)=>(t(),c("div",Cs,Ss))}},Fs={flex:"~ col gap-2","w-150":"",p4:"",border:"t base"},Es=s("h2",{"text-xl":""},[s("span",{capitalize:""},"Enable Timeline?")],-1),Ls={op50:""},Is=s("p",null,[s("span",{op50:""},"Then Nuxt will "),s("span",{"text-orange":""},"restart automatically"),F(". ")],-1),Vs={flex:"~ gap-3",mt2:"","justify-end":""},Qs=B({__name:"timeline",setup(_){const d=te(),p=ne(),e=oe(),o=ae();async function i(){try{const[n,a]=await R.enableTimeline(!0);if(!await e.start(n,a))return;await R.enableTimeline(!1)}catch{ie({message:"Failed to enable timeline automatically. Check the terminal for more details.",icon:"i-carbon-warning",classes:"text-red"})}}return(n,a)=>{const r=Ds,u=me,h=le,$=ke,A=he,S=G,b=re,L=Ns,D=_e;return t(),c(f,null,[l(d)?.timeline?.enabled?(t(),y(r,{key:0})):(t(),c(f,{key:1},[m(h,null,{default:v(()=>[m(u,{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:i})]),_:1}),m(l(e),null,{default:v(({resolve:V,args:g})=>[m(b,{"model-value":!0,onClose:N=>V(!1)},{default:v(()=>[s("div",Fs,[Es,s("p",Ls,[F(" Your "),m($,{role:"button",n:"primary",underline:"",onClick:a[0]||(a[0]=N=>l(o)(l(p)?._nuxtConfigFile)),textContent:"Nuxt config"}),F(" will be updated as: ")]),m(A,{from:g[0],to:g[1],"max-h-80":"","of-auto":"",py2:"",border:"~ base rounded",lang:"ts"},null,8,["from","to"]),Is,s("div",Vs,[m(S,{onClick:N=>V(!1)},{default:v(()=>[F(" Cancel ")]),_:2},1032,["onClick"]),m(S,{n:"solid primary",capitalize:"",onClick:N=>V(!0)},{default:v(()=>[F(" Enable ")]),_:2},1032,["onClick"])])])]),_:2},1032,["onClose"])]),_:1})],64)),m(D,null,{default:v(()=>[m(L)]),_:1})],64)}}});export{Qs as default};
@@ -1,2 +0,0 @@
1
- import{$ as $e}from"./entry.Li7bMdxw.js";function _e(t){const e=t.length;let n=-1,s,r="";const i=t.charCodeAt(0);for(;++n<e;){if(s=t.charCodeAt(n),s===0){r+="�";continue}if(s===37){r+="\\%";continue}if(s===44){r+="\\,";continue}if(s>=1&&s<=31||s===127||n===0&&s>=48&&s<=57||n===1&&s>=48&&s<=57&&i===45){r+=`\\${s.toString(16)} `;continue}if(n===0&&e===1&&s===45){r+=`\\${t.charAt(n)}`;continue}if(s>=128||s===45||s===95||s>=48&&s<=57||s>=65&&s<=90||s>=97&&s<=122){r+=t.charAt(n);continue}r+=`\\${t.charAt(n)}`}return r}const G=_e;function P(t=[]){return Array.isArray(t)?t:[t]}function U(t){return Array.from(new Set(t))}function Ce(t,e){return t.reduce((n,s)=>(n.findIndex(i=>e(s,i))===-1&&n.push(s),n),[])}function O(t){return typeof t=="string"}function R(t){return O(t)?t:(Array.isArray(t)?t:Object.entries(t)).filter(e=>e[1]!=null)}function Ae(t){return Array.isArray(t)?t.find(e=>!Array.isArray(e)||Array.isArray(e[0]))?t.map(e=>R(e)):[t]:[R(t)]}function Oe(t){return t.filter(([e,n],s)=>{if(e.startsWith("$$"))return!1;for(let r=s-1;r>=0;r--)if(t[r][0]===e&&t[r][1]===n)return!1;return!0})}function W(t){return t==null?"":Oe(t).map(([e,n])=>n!=null?`${e}:${n};`:void 0).filter(Boolean).join("")}function D(t){return t&&typeof t=="object"&&!Array.isArray(t)}function ue(t,e,n=!1){const s=t,r=e;if(Array.isArray(r))return n&&Array.isArray(r)?[...s,...r]:[...r];const i={...s};return D(s)&&D(r)&&Object.keys(r).forEach(o=>{D(s[o])&&D(r[o])||Array.isArray(s[o])&&Array.isArray(r[o])?i[o]=ue(s[o],r[o],n):Object.assign(i,{[o]:r[o]})}),i}function B(t){let e,n,s;if(Array.isArray(t)){for(n=Array(e=t.length);e--;)n[e]=(s=t[e])&&typeof s=="object"?B(s):s;return n}if(Object.prototype.toString.call(t)==="[object Object]"){n={};for(e in t)e==="__proto__"?Object.defineProperty(n,e,{value:B(t[e]),configurable:!0,enumerable:!0,writable:!0}):n[e]=(s=t[e])&&typeof s=="object"?B(s):s;return n}return t}function Me(t){return O(t[0])}function Ee(t){return O(t[0])}const J="$$shortcut-no-merge";function je(t){return typeof t=="function"?{match:t}:t}function Q(t){return t.length===3}function ke(t){return t!=null}function Pe(){}var Le=Object.defineProperty,ze=(t,e,n)=>e in t?Le(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,Te=(t,e,n)=>(ze(t,typeof e!="symbol"?e+"":e,n),n);class Fe{constructor(){Te(this,"_map",new Map)}get(e,n){const s=this._map.get(e);if(s)return s.get(n)}getFallback(e,n,s){let r=this._map.get(e);return r||(r=new Map,this._map.set(e,r)),r.has(n)||r.set(n,s),r.get(n)}set(e,n,s){let r=this._map.get(e);return r||(r=new Map,this._map.set(e,r)),r.set(n,s),this}has(e,n){return this._map.get(e)?.has(n)}delete(e,n){return this._map.get(e)?.delete(n)||!1}deleteTop(e){return this._map.delete(e)}map(e){return Array.from(this._map.entries()).flatMap(([n,s])=>Array.from(s.entries()).map(([r,i])=>e(i,n,r)))}}var Ie=Object.defineProperty,Re=(t,e,n)=>e in t?Ie(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,Ne=(t,e,n)=>(Re(t,typeof e!="symbol"?e+"":e,n),n);class he extends Set{constructor(e){super(e),Ne(this,"_map"),this._map??(this._map=new Map)}add(e){return this._map??(this._map=new Map),this._map.set(e,(this._map.get(e)??0)+1),super.add(e)}delete(e){return this._map.delete(e),super.delete(e)}clear(){this._map.clear(),super.clear()}getCount(e){return this._map.get(e)??0}setCount(e,n){return this._map.set(e,n),super.add(e)}}function Y(t){return t instanceof he}const V={};function De(t=["-",":"]){const e=t.join("|");return V[e]||(V[e]=new RegExp(`((?:[!@<~\\w+:_/-]|\\[&?>?:?\\S*\\])+?)(${e})\\(((?:[~!<>\\w\\s:/\\\\,%#.$?-]|\\[.*?\\])+?)\\)(?!\\s*?=>)`,"gm")),V[e].lastIndex=0,V[e]}function Ve(t,e=["-",":"],n=5){const s=De(e);let r,i=t.toString();const o=new Set,a=new Map;do r=!1,i=i.replace(s,(u,c,h,g,y)=>{if(!e.includes(h))return u;r=!0,o.add(c+h);const x=y+c.length+h.length+1,m={length:u.length,items:[]};a.set(y,m);for(const d of[...g.matchAll(/\S+/g)]){const $=x+d.index;let w=a.get($)?.items;w?a.delete($):w=[{offset:$,length:d[0].length,className:d[0]}];for(const b of w)b.className=b.className==="~"?c:b.className.replace(/^(!?)(.*)/,`$1${c}${h}$2`),m.items.push(b)}return"$".repeat(u.length)}),n-=1;while(r&&n);let f;if(typeof t=="string"){f="";let u=0;for(const[c,h]of a)f+=t.slice(u,c),f+=h.items.map(g=>g.className).join(" "),u=c+h.length;f+=t.slice(u)}else{f=t;for(const[u,c]of a)f.overwrite(u,u+c.length,c.items.map(h=>h.className).join(" "))}return{prefixes:Array.from(o),hasChanged:r,groupsByOffset:a,get expanded(){return f.toString()}}}function Be(t,e=["-",":"],n=5){const s=Ve(t,e,n);return typeof t=="string"?s.expanded:t}const ee=new Set;function de(t){ee.has(t)||(console.warn("[unocss]",t),ee.add(t))}const Ue=/[\\:]?[\s'"`;{}]+/g;function He(t){return t.split(Ue)}const Ge={name:"@unocss/core/extractor-split",order:0,extract({code:t}){return He(t)}};function We(){return{events:{},emit(t,...e){(this.events[t]||[]).forEach(n=>n(...e))},on(t,e){return(this.events[t]=this.events[t]||[]).push(e),()=>this.events[t]=(this.events[t]||[]).filter(n=>n!==e)}}}const K="default",X="preflights",Ye="shortcuts",qe="imports",Ke={[qe]:-200,[X]:-100,[Ye]:-10,[K]:0};function pe(t){return P(t).flatMap(e=>Array.isArray(e)?[e]:Object.entries(e))}const te="_uno_resolved";function Xe(t){let e=typeof t=="function"?t():t;if(te in e)return e;e={...e},Object.defineProperty(e,te,{value:!0,enumerable:!1});const n=e.shortcuts?pe(e.shortcuts):void 0;if(e.shortcuts=n,e.prefix||e.layer){const s=r=>{r[2]||(r[2]={});const i=r[2];i.prefix==null&&e.prefix&&(i.prefix=P(e.prefix)),i.layer==null&&e.layer&&(i.layer=e.layer)};n?.forEach(s),e.rules?.forEach(s)}return e}function me(t){const e=Xe(t);if(!e.presets)return[e];const n=(e.presets||[]).flatMap(P).flatMap(me);return[e,...n]}function ne(t={},e={}){const n=Object.assign({},e,t),s=Ce((n.presets||[]).flatMap(P).flatMap(me),(l,v)=>l.name===v.name),r=[...s.filter(l=>l.enforce==="pre"),...s.filter(l=>!l.enforce),...s.filter(l=>l.enforce==="post")],i=[...r,n],o=[...i].reverse(),a=Object.assign({},Ke,...i.map(l=>l.layers));function f(l){return U(i.flatMap(v=>P(v[l]||[])))}const u=f("extractors");let c=o.find(l=>l.extractorDefault!==void 0)?.extractorDefault;c===void 0&&(c=Ge),c&&!u.includes(c)&&u.unshift(c),u.sort((l,v)=>(l.order||0)-(v.order||0));const h=f("rules"),g={},y=h.length,x=h.map((l,v)=>{if(Me(l)){P(l[2]?.prefix||"").forEach(A=>{g[A+l[0]]=[v,l[1],l[2],l]});return}return[v,...l]}).filter(Boolean).reverse();let m=Ze(i.map(l=>l.theme));const d=f("extendTheme");for(const l of d)m=l(m)||m;const $={templates:U(i.flatMap(l=>P(l.autocomplete?.templates))),extractors:i.flatMap(l=>P(l.autocomplete?.extractors)).sort((l,v)=>(l.order||0)-(v.order||0)),shorthands:Je(i.map(l=>l.autocomplete?.shorthands||{}))};let w=f("separators");w.length||(w=[":","-"]);const b={mergeSelectors:!0,warn:!0,sortLayers:l=>l,...n,blocklist:f("blocklist"),presets:r,envMode:n.envMode||"build",shortcutsLayer:n.shortcutsLayer||"shortcuts",layers:a,theme:m,rulesSize:y,rulesDynamic:x,rulesStaticMap:g,preprocess:f("preprocess"),postprocess:f("postprocess"),preflights:f("preflights"),autocomplete:$,variants:f("variants").map(je).sort((l,v)=>(l.order||0)-(v.order||0)),shortcuts:pe(f("shortcuts")).reverse(),extractors:u,safelist:f("safelist"),separators:w,details:n.details??n.envMode==="dev"};for(const l of i)l?.configResolved?.(b);return b}function Ze(t){return t.map(e=>e?B(e):{}).reduce((e,n)=>ue(e,n),{})}function Je(t){return t.reduce((e,n)=>{const s={};for(const r in n){const i=n[r];Array.isArray(i)?s[r]=`(${i.join("|")})`:s[r]=i}return{...e,...s}},{})}const Qe="0.58.3";var et=Object.defineProperty,tt=(t,e,n)=>e in t?et(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,F=(t,e,n)=>(tt(t,typeof e!="symbol"?e+"":e,n),n);class nt{constructor(e={},n={}){this.userConfig=e,this.defaults=n,F(this,"version",Qe),F(this,"_cache",new Map),F(this,"config"),F(this,"blocked",new Set),F(this,"parentOrders",new Map),F(this,"events",We()),this.config=ne(e,n),this.events.emit("config",this.config)}setConfig(e,n){e&&(n&&(this.defaults=n),this.userConfig=e,this.blocked.clear(),this.parentOrders.clear(),this._cache.clear(),this.config=ne(e,this.defaults),this.events.emit("config",this.config))}async applyExtractors(e,n,s=new Set){const r={original:e,code:e,id:n,extracted:s,envMode:this.config.envMode};for(const i of this.config.extractors){const o=await i.extract?.(r);if(o)if(Y(o)&&Y(s))for(const a of o)s.setCount(a,s.getCount(a)+o.getCount(a));else for(const a of o)s.add(a)}return s}makeContext(e,n){const s={rawSelector:e,currentSelector:n[1],theme:this.config.theme,generator:this,variantHandlers:n[2],constructCSS:(...r)=>this.constructCustomCSS(s,...r),variantMatch:n};return s}async parseToken(e,n){if(this.blocked.has(e))return;const s=`${e}${n?` ${n}`:""}`;if(this._cache.has(s))return this._cache.get(s);let r=e;for(const u of this.config.preprocess)r=u(e);if(this.isBlocked(r)){this.blocked.add(e),this._cache.set(s,null);return}const i=await this.matchVariants(e,r);if(!i||this.isBlocked(i[1])){this.blocked.add(e),this._cache.set(s,null);return}const o=this.makeContext(e,[n||i[0],i[1],i[2],i[3]]);this.config.details&&(o.variants=[...i[3]]);const a=await this.expandShortcut(o.currentSelector,o),f=a?await this.stringifyShortcuts(o.variantMatch,o,a[0],a[1]):(await this.parseUtil(o.variantMatch,o))?.map(u=>this.stringifyUtil(u,o)).filter(ke);if(f?.length)return this._cache.set(s,f),f;this._cache.set(s,null)}async generate(e,n={}){const{id:s,scope:r,preflights:i=!0,safelist:o=!0,minify:a=!1,extendedInfo:f=!1}=n,u=O(e)?await this.applyExtractors(e,s,f?new he:new Set):Array.isArray(e)?new Set(e):e;o&&this.config.safelist.forEach(l=>{u.has(l)||u.add(l)});const c=a?"":`
2
- `,h=new Set([K]),g=f?new Map:new Set,y=new Map;let x={};const m=Array.from(u).map(async l=>{if(g.has(l))return;const v=await this.parseToken(l);if(v!=null){g instanceof Map?g.set(l,{data:v,count:Y(u)?u.getCount(l):-1}):g.add(l);for(const C of v){const A=C[3]||"",M=C[4]?.layer;y.has(A)||y.set(A,[]),y.get(A).push(C),M&&h.add(M)}}});await Promise.all(m),await(async()=>{if(!i)return;const l={generator:this,theme:this.config.theme},v=new Set([]);this.config.preflights.forEach(({layer:C=X})=>{h.add(C),v.add(C)}),x=Object.fromEntries(await Promise.all(Array.from(v).map(async C=>{const M=(await Promise.all(this.config.preflights.filter(z=>(z.layer||X)===C).map(async z=>await z.getCSS(l)))).filter(Boolean).join(c);return[C,M]})))})();const d=this.config.sortLayers(Array.from(h).sort((l,v)=>(this.config.layers[l]??0)-(this.config.layers[v]??0)||l.localeCompare(v))),$={},w=l=>{if($[l])return $[l];let v=Array.from(y).sort((A,M)=>(this.parentOrders.get(A[0])??0)-(this.parentOrders.get(M[0])??0)||A[0]?.localeCompare(M[0]||"")||0).map(([A,M])=>{const z=M.length,T=M.filter(p=>(p[4]?.layer||K)===l).sort((p,S)=>p[0]-S[0]||(p[4]?.sort||0)-(S[4]?.sort||0)||p[5]?.currentSelector?.localeCompare(S[5]?.currentSelector??"")||p[1]?.localeCompare(S[1]||"")||p[2]?.localeCompare(S[2]||"")||0).map(([,p,S,,_,,E])=>[[[(p&&it(p,r))??"",_?.sort??0]],S,!!(E??_?.noMerge)]);if(!T.length)return;const I=T.reverse().map(([p,S,_],E)=>{if(!_&&this.config.mergeSelectors)for(let j=E+1;j<z;j++){const L=T[j];if(L&&!L[2]&&(p&&L[0]||p==null&&L[0]==null)&&L[1]===S)return p&&L[0]&&L[0].push(...p),null}const k=p?U(p.sort((j,L)=>j[1]-L[1]||j[0]?.localeCompare(L[0]||"")||0).map(j=>j[0]).filter(Boolean)):[];return k.length?`${k.join(`,${c}`)}{${S}}`:S}).filter(Boolean).reverse().join(c);if(!A)return I;const N=A.split(" $$ ");return`${N.join("{")}{${c}${I}${c}${"}".repeat(N.length)}`}).filter(Boolean).join(c);i&&(v=[x[l],v].filter(Boolean).join(c));const C=a?"":`/* layer: ${l} */${c}`;return $[l]=v?C+v:""},b=(l=d,v)=>l.filter(C=>!v?.includes(C)).map(C=>w(C)||"").filter(Boolean).join(c);return{get css(){return b()},layers:d,matched:g,getLayers:b,getLayer:w}}async matchVariants(e,n){const s=new Set,r=[];let i=n||e,o=!0;const a={rawSelector:e,theme:this.config.theme,generator:this};for(;o;){o=!1;for(const f of this.config.variants){if(!f.multiPass&&s.has(f))continue;let u=await f.match(i,a);if(u){if(O(u)){if(u===i)continue;u={matcher:u}}i=u.matcher,r.unshift(u),s.add(f),o=!0;break}}if(!o)break;if(r.length>500)throw new Error(`Too many variants applied to "${e}"`)}return[e,i,r,s]}applyVariants(e,n=e[4],s=e[1]){const i=n.slice().sort((u,c)=>(u.order||0)-(c.order||0)).reduceRight((u,c)=>h=>{const g=c.body?.(h.entries)||h.entries,y=Array.isArray(c.parent)?c.parent:[c.parent,void 0];return(c.handle??at)({...h,entries:g,selector:c.selector?.(h.selector,g)||h.selector,parent:y[0]||h.parent,parentOrder:y[1]||h.parentOrder,layer:c.layer||h.layer,sort:c.sort||h.sort},u)},u=>u)({prefix:"",selector:ot(s),pseudo:"",entries:e[2]}),{parent:o,parentOrder:a}=i;o!=null&&a!=null&&this.parentOrders.set(o,a);const f={selector:[i.prefix,i.selector,i.pseudo].join(""),entries:i.entries,parent:o,layer:i.layer,sort:i.sort,noMerge:i.noMerge};for(const u of this.config.postprocess)u(f);return f}constructCustomCSS(e,n,s){const r=R(n);if(O(r))return r;const{selector:i,entries:o,parent:a}=this.applyVariants([0,s||e.rawSelector,r,void 0,e.variantHandlers]),f=`${i}{${W(o)}}`;return a?`${a}{${f}}`:f}async parseUtil(e,n,s=!1,r){const[i,o,a]=O(e)?await this.matchVariants(e):e;this.config.details&&(n.rules=n.rules??[]);const f=this.config.rulesStaticMap[o];if(f&&f[1]&&(s||!f[2]?.internal)){this.config.details&&n.rules.push(f[3]);const c=f[0],h=R(f[1]),g=f[2];return O(h)?[[c,h,g]]:[[c,i,h,g,a]]}n.variantHandlers=a;const{rulesDynamic:u}=this.config;for(const[c,h,g,y]of u){if(y?.internal&&!s)continue;let x=o;if(y?.prefix){const w=P(y.prefix);if(r){const b=P(r);if(!w.some(l=>b.includes(l)))continue}else{const b=w.find(l=>o.startsWith(l));if(b==null)continue;x=o.slice(b.length)}}const m=x.match(h);if(!m)continue;const d=await g(m,n);if(!d)continue;this.config.details&&n.rules.push([h,g,y]);const $=Ae(d).filter(w=>w.length);if($.length)return $.map(w=>O(w)?[c,w,y]:[c,i,w,y,a])}}stringifyUtil(e,n){if(!e)return;if(Q(e))return[e[0],void 0,e[1],void 0,e[2],this.config.details?n:void 0,void 0];const{selector:s,entries:r,parent:i,layer:o,sort:a,noMerge:f}=this.applyVariants(e),u=W(r);if(!u)return;const{layer:c,sort:h,...g}=e[3]??{},y={...g,layer:o??c,sort:a??h};return[e[0],s,u,i,y,this.config.details?n:void 0,f]}async expandShortcut(e,n,s=5){if(s===0)return;const r=this.config.details?a=>{n.shortcuts=n.shortcuts??[],n.shortcuts.push(a)}:Pe;let i,o;for(const a of this.config.shortcuts){let f=e;if(a[2]?.prefix){const c=P(a[2].prefix).find(h=>e.startsWith(h));if(c==null)continue;f=e.slice(c.length)}if(Ee(a)){if(a[0]===f){i=i||a[2],o=a[1],r(a);break}}else{const u=f.match(a[0]);if(u&&(o=a[1](u,n)),o){i=i||a[2],r(a);break}}}if(O(o)&&(o=Be(o.trim()).split(/\s+/g)),!o){const[a,f]=O(e)?await this.matchVariants(e):e;if(a!==f){const u=await this.expandShortcut(f,n,s-1);u&&(o=u[0].map(c=>O(c)?a.replace(f,c):c))}}if(o)return[(await Promise.all(o.map(async a=>(O(a)?(await this.expandShortcut(a,n,s-1))?.[0]:void 0)||[a]))).flat(1).filter(Boolean),i]}async stringifyShortcuts(e,n,s,r={layer:this.config.shortcutsLayer}){const i=new Fe,o=(await Promise.all(U(s).map(async c=>{const h=O(c)?await this.parseUtil(c,n,!0,r.prefix):[[Number.POSITIVE_INFINITY,"{inline}",R(c),void 0,[]]];return!h&&this.config.warn&&de(`unmatched utility "${c}" in shortcut "${e[1]}"`),h||[]}))).flat(1).filter(Boolean).sort((c,h)=>c[0]-h[0]),[a,,f]=e,u=[];for(const c of o){if(Q(c)){u.push([c[0],void 0,c[1],void 0,c[2],n,void 0]);continue}const{selector:h,entries:g,parent:y,sort:x,noMerge:m}=this.applyVariants(c,[...c[4],...f],a);i.getFallback(h,y,[[],c[0]])[0].push([g,!!(m??c[3]?.noMerge),x??0])}return u.concat(i.map(([c,h],g,y)=>{const x=(d,$,w)=>{const b=Math.max(...w.map(v=>v[1])),l=w.map(v=>v[0]);return(d?[l.flat(1)]:l).map(v=>{const C=W(v);if(C)return[h,g,C,y,{...r,noMerge:$,sort:b},n,void 0]})};return[[c.filter(([,d])=>d).map(([d,,$])=>[d,$]),!0],[c.filter(([,d])=>!d).map(([d,,$])=>[d,$]),!1]].map(([d,$])=>[...x(!1,$,d.filter(([w])=>w.some(b=>b[0]===J))),...x(!0,$,d.filter(([w])=>w.every(b=>b[0]!==J)))])}).flat(2).filter(Boolean))}isBlocked(e){return!e||this.config.blocklist.some(n=>typeof n=="function"?n(e):O(n)?n===e:n.test(e))}}function rt(t,e){return new nt(t,e)}const ge=/\s\$\$\s+/g;function st(t){return ge.test(t)}function it(t,e){return st(t)?t.replace(ge,e?` ${e} `:" "):e?`${e} ${t}`:t}const re=/^\[(.+?)(~?=)"(.*)"\]$/;function ot(t){return re.test(t)?t.replace(re,(e,n,s,r)=>`[${G(n)}${s}"${G(r)}"]`):`.${G(t)}`}function at(t,e){return e(t)}const ct=Object.freeze({left:0,top:0,width:16,height:16}),H=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),ye=Object.freeze({...ct,...H}),lt=Object.freeze({...ye,body:"",hidden:!1}),ft=Object.freeze({width:null,height:null}),we=Object.freeze({...ft,...H});function ut(t,e){const n={};!t.hFlip!=!e.hFlip&&(n.hFlip=!0),!t.vFlip!=!e.vFlip&&(n.vFlip=!0);const s=((t.rotate||0)+(e.rotate||0))%4;return s&&(n.rotate=s),n}function se(t,e){const n=ut(t,e);for(const s in lt)s in H?s in t&&!(s in n)&&(n[s]=H[s]):s in e?n[s]=e[s]:s in t&&(n[s]=t[s]);return n}function ht(t,e){const n=t.icons,s=t.aliases||Object.create(null),r=Object.create(null);function i(o){if(n[o])return r[o]=[];if(!(o in r)){r[o]=null;const a=s[o]&&s[o].parent,f=a&&i(a);f&&(r[o]=[a].concat(f))}return r[o]}return(e||Object.keys(n).concat(Object.keys(s))).forEach(i),r}function ie(t,e,n){const s=t.icons,r=t.aliases||Object.create(null);let i={};function o(a){i=se(s[a]||r[a],i)}return o(e),n.forEach(o),se(t,i)}function dt(t,e){if(t.icons[e])return ie(t,e,[]);const n=ht(t,[e])[e];return n?ie(t,e,n):null}const pt=/(-?[0-9.]*[0-9]+[0-9.]*)/g,mt=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function oe(t,e,n){if(e===1)return t;if(n=n||100,typeof t=="number")return Math.ceil(t*e*n)/n;if(typeof t!="string")return t;const s=t.split(pt);if(s===null||!s.length)return t;const r=[];let i=s.shift(),o=mt.test(i);for(;;){if(o){const a=parseFloat(i);isNaN(a)?r.push(i):r.push(Math.ceil(a*e*n)/n)}else r.push(i);if(i=s.shift(),i===void 0)return r.join("");o=!o}}function gt(t,e="defs"){let n="";const s=t.indexOf("<"+e);for(;s>=0;){const r=t.indexOf(">",s),i=t.indexOf("</"+e);if(r===-1||i===-1)break;const o=t.indexOf(">",i);if(o===-1)break;n+=t.slice(r+1,i).trim(),t=t.slice(0,s).trim()+t.slice(o+1)}return{defs:n,content:t}}function yt(t,e){return t?"<defs>"+t+"</defs>"+e:e}function wt(t,e,n){const s=gt(t);return yt(s.defs,e+s.content+n)}const Z=t=>t==="unset"||t==="undefined"||t==="none";function vt(t,e){const n={...ye,...t},s={...we,...e},r={left:n.left,top:n.top,width:n.width,height:n.height};let i=n.body;[n,s].forEach(m=>{const d=[],$=m.hFlip,w=m.vFlip;let b=m.rotate;$?w?b+=2:(d.push("translate("+(r.width+r.left).toString()+" "+(0-r.top).toString()+")"),d.push("scale(-1 1)"),r.top=r.left=0):w&&(d.push("translate("+(0-r.left).toString()+" "+(r.height+r.top).toString()+")"),d.push("scale(1 -1)"),r.top=r.left=0);let l;switch(b<0&&(b-=Math.floor(b/4)*4),b=b%4,b){case 1:l=r.height/2+r.top,d.unshift("rotate(90 "+l.toString()+" "+l.toString()+")");break;case 2:d.unshift("rotate(180 "+(r.width/2+r.left).toString()+" "+(r.height/2+r.top).toString()+")");break;case 3:l=r.width/2+r.left,d.unshift("rotate(-90 "+l.toString()+" "+l.toString()+")");break}b%2===1&&(r.left!==r.top&&(l=r.left,r.left=r.top,r.top=l),r.width!==r.height&&(l=r.width,r.width=r.height,r.height=l)),d.length&&(i=wt(i,'<g transform="'+d.join(" ")+'">',"</g>"))});const o=s.width,a=s.height,f=r.width,u=r.height;let c,h;o===null?(h=a===null?"1em":a==="auto"?u:a,c=oe(h,f/u)):(c=o==="auto"?f:o,h=a===null?oe(c,u/f):a==="auto"?u:a);const g={},y=(m,d)=>{Z(d)||(g[m]=d.toString())};y("width",c),y("height",h);const x=[r.left,r.top,f,u];return g.viewBox=x.join(" "),{attributes:g,viewBox:x,body:i}}function bt(t){return t.replace(/"/g,"'").replace(/%/g,"%25").replace(/#/g,"%23").replace(/</g,"%3C").replace(/>/g,"%3E").replace(/\s+/g," ")}function St(t){let e=t.startsWith("<svg>")?t.replace("<svg>","<svg >"):t;return!e.includes(" xmlns:xlink=")&&e.includes(" xlink:")&&(e=e.replace("<svg ",'<svg xmlns:xlink="http://www.w3.org/1999/xlink" ')),e.includes(" xmlns=")||(e=e.replace("<svg ",'<svg xmlns="http://www.w3.org/2000/svg" ')),bt(e)}function xt(t){return t.replace(/(['"])\s*\n\s*([^>\\/\s])/g,"$1 $2").replace(/(["';{}><])\s*\n\s*/g,"$1").replace(/\s*\n\s*/g," ").replace(/\s+"/g,'"').replace(/="\s+/g,'="').trim()}const $t=/\swidth\s*=\s*["'](\w+)["']/,_t=/\sheight\s*=\s*["'](\w+)["']/,q=/<svg\s+/;function Ct(t,e,n){const s=t.slice(0,t.indexOf(">")),r=(i,o)=>{const a=o.exec(s),f=a!=null,u=e[i];return!u&&!Z(u)&&(typeof n=="number"?n>0&&(e[i]=`${n}em`):a&&(e[i]=a[1])),f};return[r("width",$t),r("height",_t)]}async function ve(t,e,n,s,r,i){const{scale:o,addXmlNs:a=!1}=s??{},{additionalProps:f={},iconCustomizer:u}=s?.customizations??{},c=await r?.()??{};await u?.(e,n,c),Object.keys(f).forEach(m=>{const d=f[m];d!=null&&(c[m]=d)}),i?.(c);const[h,g]=Ct(t,c,o);a&&(!t.includes("xmlns=")&&!c.xmlns&&(c.xmlns="http://www.w3.org/2000/svg"),!t.includes("xmlns:xlink=")&&t.includes("xlink:")&&!c["xmlns:xlink"]&&(c["xmlns:xlink"]="http://www.w3.org/1999/xlink"));const y=Object.keys(c).map(m=>m==="width"&&h||m==="height"&&g?null:`${m}="${c[m]}"`).filter(m=>m!=null);if(y.length&&(t=t.replace(q,`<svg ${y.join(" ")} `)),s){const{defaultStyle:m,defaultClass:d}=s;d&&!t.includes("class=")&&(t=t.replace(q,`<svg class="${d}" `)),m&&!t.includes("style=")&&(t=t.replace(q,`<svg style="${m}" `))}const x=s?.usedProps;return x&&(Object.keys(f).forEach(m=>{const d=c[m];d!=null&&(x[m]=d)}),typeof c.width<"u"&&c.width!==null&&(x.width=c.width),typeof c.height<"u"&&c.height!==null&&(x.height=c.height)),t}async function ae(t,e,n,s){let r;try{if(typeof t=="function")r=await t(n);else{const i=t[n];r=typeof i=="function"?await i():i}}catch(i){console.warn(`Failed to load custom icon "${n}" in "${e}":`,i);return}if(r){const i=r.indexOf("<svg");i>0&&(r=r.slice(i));const{transform:o}=s?.customizations??{};return r=typeof o=="function"?await o(r,e,n):r,r.startsWith("<svg")?await ve(s?.customizations?.trimCustomSvg===!0?xt(r):r,e,n,s,void 0):(console.warn(`Custom icon "${n}" in "${e}" is not a valid SVG`),r)}}async function be(t,e,n,s){let r;const{customize:i}=s?.customizations??{};for(const o of n)if(r=dt(t,o),r){let a={...we};typeof i=="function"&&(a=i(a));const{attributes:{width:f,height:u,...c},body:h}=vt(r,a),g=s?.scale;return await ve(`<svg >${h}</svg>`,e,o,s,()=>({...c}),y=>{const x=(m,d)=>{const $=y[m];let w;if(!Z($)){if($)return;typeof g=="number"?g&&(w=`${g}em`):w=d}w?y[m]=w:delete y[m]};x("width",f),x("height",u)})}}const Se=async(t,e,n)=>{const s=n?.customCollections?.[t];if(s)if(typeof s=="function"){let r;try{r=await s(e)}catch(i){console.warn(`Failed to load custom icon "${e}" in "${t}":`,i);return}if(r){if(typeof r=="string")return await ae(()=>r,t,e,n);if("icons"in r){const i=[e,e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),e.replace(/([a-z])(\d+)/g,"$1-$2")];return await be(r,t,i,n)}}}else return await ae(s,t,e,n)};function At(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Ot=["academicons","akar-icons","ant-design","arcticons","basil","bi","bpmn","brandico","bx","bxl","bxs","bytesize","carbon","charm","ci","cib","cif","cil","circle-flags","circum","clarity","codicon","covid","cryptocurrency-color","cryptocurrency","dashicons","devicon-line","devicon-original","devicon-plain","devicon","ei","el","emblemicons","emojione-monotone","emojione-v1","emojione","entypo-social","entypo","eos-icons","ep","et","eva","fa-brands","fa-regular","fa-solid","fa","fa6-brands","fa6-regular","fa6-solid","fad","fe","feather","file-icons","flag","flagpack","flat-color-icons","flat-ui","fluent-emoji-flat","fluent-emoji-high-contrast","fluent-emoji","fluent-mdl2","fluent","fontelico","fontisto","formkit","foundation","fxemoji","gala","game-icons","geo","gg","gis","gravity-ui","gridicons","grommet-icons","guidance","healthicons","heroicons-outline","heroicons-solid","heroicons","humbleicons","ic","icomoon-free","icon-park-outline","icon-park-solid","icon-park-twotone","icon-park","iconamoon","iconoir","icons8","il","ion","iwwa","jam","la","lets-icons","line-md","logos","ls","lucide","majesticons","maki","map","material-symbols-light","material-symbols","mdi-light","mdi","medical-icon","memory","meteocons","mi","mingcute","mono-icons","mynaui","nimbus","nonicons","noto-v1","noto","octicon","oi","ooui","openmoji","pajamas","pepicons-pencil","pepicons-pop","pepicons-print","pepicons","ph","pixelarticons","prime","ps","quill","radix-icons","raphael","ri","si-glyph","simple-icons","simple-line-icons","skill-icons","solar","streamline-emojis","streamline","subway","svg-spinners","system-uicons","tabler","tdesign","teenyicons","topcoat","twemoji","typcn","uil","uim","uis","uit","uiw","vaadin","vs","vscode-icons","websymbol","whh","wi","wpf","zmdi","zondicons"];const Mt=At(Ot),Et=3;function jt(t){return(e={})=>{const{scale:n=1,mode:s="auto",prefix:r="i-",warn:i=!1,collections:o,extraProperties:a={},customizations:f={},autoInstall:u=!1,layer:c="icons",unit:h}=e,g={addXmlNs:!0,scale:n,customCollections:o,autoInstall:u,warn:void 0,customizations:{...f,additionalProps:{...a},trimCustomSvg:!0,async iconCustomizer(x,m,d){await f.iconCustomizer?.(x,m,d),h&&(d.width||(d.width=`${n}${h}`),d.height||(d.height=`${n}${h}`))}}};let y;return{name:"@unocss/preset-icons",enforce:"pre",options:e,layers:{icons:-30},rules:[[/^([a-z0-9:_-]+)(?:\?(mask|bg|auto))?$/,async([x,m,d=s])=>{let $="",w="",b;y=y||await t(e);const l={};if(m.includes(":"))[$,w]=m.split(":"),b=await y($,w,{...g,usedProps:l});else{const C=m.split(/-/g);for(let A=Et;A>=1&&($=C.slice(0,A).join("-"),w=C.slice(A).join("-"),b=await y($,w,{...g,usedProps:l}),!b);A--);}if(!b){i&&de(`failed to load icon "${x}"`);return}const v=`url("data:image/svg+xml;utf8,${St(b)}")`;return d==="auto"&&(d=b.includes("currentColor")?"mask":"bg"),d==="mask"?{"--un-icon":v,"-webkit-mask":"var(--un-icon) no-repeat",mask:"var(--un-icon) no-repeat","-webkit-mask-size":"100% 100%","mask-size":"100% 100%","background-color":"currentColor",color:"inherit",...l}:{background:`${v} no-repeat`,"background-size":"100% 100%","background-color":"transparent",...l}},{layer:c,prefix:r}]]}}}function xe(t,e){const n=new Map;function s(r){if(Mt.includes(r))return n.has(r)||n.set(r,t(`${e}@iconify-json/${r}/icons.json`)),n.get(r)}return async(r,i,o)=>{let a=await Se(r,i,o);if(a)return a;const f=await s(r);if(f){const u=[i,i.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),i.replace(/([a-z])(\d+)/g,"$1-$2")];a=await be(f,r,u,o)}return a}}function kt(t){return xe($e,t)}const Pt=jt(async t=>{const e=t?.customFetch,n=t?.cdn;return e&&n?xe(e,n):n?kt(n):Se});function Lt(t){return t.replace(/-(\w)/g,(e,n)=>n?n.toUpperCase():"")}function ce(t){return t.charAt(0).toUpperCase()+t.slice(1)}function le(t){return t.replace(/(?:^|\B)([A-Z])/g,"-$1").toLowerCase()}var fe=["Webkit","Moz","ms"];function zt(t){const e={};function n(s){const r=e[s];if(r)return r;let i=Lt(s);if(i!=="filter"&&i in t)return e[s]=le(i);i=ce(i);for(let o=0;o<fe.length;o++){const a=`${fe[o]}${i}`;if(a in t)return e[s]=le(ce(a))}return s}return({entries:s})=>s.forEach(r=>{r[0].startsWith("--")||(r[0]=n(r[0]))})}function Tt(t){return t.replace(/&amp;/g,"&").replace(/&gt;/g,">").replace(/&lt;/g,"<")}function Ft(t={}){if(typeof window>"u"){console.warn("@unocss/runtime been used in non-browser environment, skipped.");return}const e=window,n=window.document,s=()=>n.documentElement,r=e.__unocss||{},i=Object.assign({},t,r.runtime),o=i.defaults||{},a=i.cloakAttribute??"un-cloak";i.autoPrefix&&(o.postprocess=P(o.postprocess)).unshift(zt(n.createElement("div").style)),i.configResolved?.(r,o);const f=rt(r,o),u=p=>i.inject?i.inject(p):s().prepend(p),c=()=>i.rootElement?i.rootElement():n.body,h=new Map;let g=!0,y=new Set,x,m,d=[];const $=()=>new Promise(p=>{d.push(p),m!=null&&clearTimeout(m),m=setTimeout(()=>l().then(()=>{const S=d;d=[],S.forEach(_=>_())}),0)});function w(p){if(p.nodeType!==1)return;const S=p;S.hasAttribute(a)&&S.removeAttribute(a),S.querySelectorAll(`[${a}]`).forEach(_=>{_.removeAttribute(a)})}function b(p,S){let _=h.get(p);if(!_)if(_=n.createElement("style"),_.setAttribute("data-unocss-runtime-layer",p),h.set(p,_),S==null)u(_);else{const E=b(S),k=E.parentNode;k?k.insertBefore(_,E.nextSibling):u(_)}return _}async function l(){const p=await f.generate(y);return p.layers.reduce((S,_)=>(b(_,S).innerHTML=p.getLayer(_)??"",_),void 0),y=p.matched,{...p,getStyleElement:S=>h.get(S),getStyleElements:()=>h}}async function v(p){const S=y.size;await f.applyExtractors(p,void 0,y),S!==y.size&&await $()}async function C(p=c()){const S=p&&p.outerHTML;S&&(await v(`${S} ${Tt(S)}`),w(s()),w(p))}const A=new MutationObserver(p=>{g||p.forEach(async S=>{if(S.target.nodeType!==1)return;const _=S.target;for(const E of h)if(_===E[1])return;if(S.type==="childList")S.addedNodes.forEach(async E=>{if(E.nodeType!==1)return;const k=E;x&&!x(k)||(await v(k.outerHTML),w(k))});else{if(x&&!x(_))return;if(S.attributeName!==a){const E=Array.from(_.attributes).map(j=>j.value?`${j.name}="${j.value}"`:j.name).join(" "),k=`<${_.tagName.toLowerCase()} ${E}>`;await v(k)}_.hasAttribute(a)&&_.removeAttribute(a)}})});let M=!1;function z(){if(M)return;const p=i.observer?.target?i.observer.target():c();p&&(A.observe(p,{childList:!0,subtree:!0,attributes:!0,attributeFilter:i.observer?.attributeFilter}),M=!0)}function T(){i.bypassDefined&&It(f.blocked),C(),z()}function I(){n.readyState==="loading"?e.addEventListener("DOMContentLoaded",T):T()}const N=e.__unocss_runtime=e.__unocss_runtime={version:f.version,uno:f,async extract(p){O(p)||(p.forEach(S=>y.add(S)),p=""),await v(p)},extractAll:C,inspect(p){x=p},toggleObserver(p){p===void 0?g=!g:g=!!p,!M&&!g&&I()},update:l,presets:e.__unocss_runtime?.presets??{}};i.ready?.(N)!==!1&&(g=!1,I())}function It(t=new Set){for(let e=0;e<document.styleSheets.length;e++){const n=document.styleSheets[e];let s;try{if(s=n.cssRules||n.rules,!s)continue;Array.from(s).flatMap(r=>r.selectorText?.split(/,/g)||[]).forEach(r=>{r&&(r=r.trim(),r.startsWith(".")&&(r=r.slice(1)),t.add(r))})}catch{continue}}return t}Ft({defaults:{presets:[Pt({prefix:["i-",""],collections:{},cdn:"https://esm.sh/",scale:1.2,extraProperties:{display:"inline-block","vertical-align":"middle"}})]},bypassDefined:!0});