@nuxt/devtools 1.3.14 → 1.4.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 (110) hide show
  1. package/dist/chunks/module-main.mjs +6 -6
  2. package/dist/chunks/vscode.mjs +2 -2
  3. package/dist/chunks/vue-devtools.mjs +1 -1
  4. package/dist/client/200.html +21 -21
  5. package/dist/client/404.html +21 -21
  6. package/dist/client/_nuxt/{DoQHeYxB.js → 32IlS-eL.js} +3 -3
  7. package/dist/client/_nuxt/{DVZAdofw.js → 6ngNN4Yp.js} +1 -1
  8. package/dist/client/_nuxt/{BHBvn5Xs.js → 7oK7PdYH.js} +1 -1
  9. package/dist/client/_nuxt/{zLQhdF7m.js → B1veJI6T.js} +1 -1
  10. package/dist/client/_nuxt/{BMUgLter.js → B3uNdhXb.js} +1 -1
  11. package/dist/client/_nuxt/{D8XE2BC8.js → BECRlsCL.js} +1 -1
  12. package/dist/client/_nuxt/{D4Ks82zD.js → BHh_UM9T.js} +1 -1
  13. package/dist/client/_nuxt/{zjxoDR5L.js → BI3hykgO.js} +1 -1
  14. package/dist/client/_nuxt/{BWPbreBU.js → BKeomq25.js} +1 -1
  15. package/dist/client/_nuxt/{rLudNEh9.js → BKukfVLl.js} +1 -1
  16. package/dist/client/_nuxt/BMbUeBqv.js +1 -1
  17. package/dist/client/_nuxt/{BcJweaq3.js → BMmGYe_n.js} +1 -1
  18. package/dist/client/_nuxt/{CLVHkiJk.js → BOV_C5BD.js} +1 -1
  19. package/dist/client/_nuxt/{CjFkCrIW.js → BiRcA7Ly.js} +1 -1
  20. package/dist/client/_nuxt/{Di9lD2rK.js → BiWf_U1D.js} +1 -1
  21. package/dist/client/_nuxt/{B-wfK0SS.js → BkwfBuTq.js} +1 -1
  22. package/dist/client/_nuxt/{DN0HCnq5.js → BopA0WYG.js} +1 -1
  23. package/dist/client/_nuxt/{z0xAc3RC.js → BsEGx9wN.js} +1 -1
  24. package/dist/client/_nuxt/{BZZpaKJQ.js → Bu2gNcUf.js} +1 -1
  25. package/dist/client/_nuxt/{C4OO6w_e.js → ByTwm2ax.js} +1 -1
  26. package/dist/client/_nuxt/{awWHqjli.js → C1fpCDlE.js} +1 -1
  27. package/dist/client/_nuxt/{Bl8OBrwH.js → C2HmjCtb.js} +1 -1
  28. package/dist/client/_nuxt/C8RrL2-P.js +1 -1
  29. package/dist/client/_nuxt/{BF_UD7ZT.js → C9bF3W-8.js} +1 -1
  30. package/dist/client/_nuxt/{DYx1ZwvQ.js → CCJYS4Qc.js} +1 -1
  31. package/dist/client/_nuxt/{ewAh1ZiX.js → CCXTpRMt.js} +1 -1
  32. package/dist/client/_nuxt/{BrzmMRQX.js → CCfUy938.js} +2 -2
  33. package/dist/client/_nuxt/{CVW-sDYN.js → CEL3Rl_8.js} +1 -1
  34. package/dist/client/_nuxt/{BZvh3yot.js → CIvuwNIv.js} +1 -1
  35. package/dist/client/_nuxt/{DwVKZd3-.js → CNzQK24q.js} +1 -1
  36. package/dist/client/_nuxt/{yFeWtr-M.js → CO7Eo6nF.js} +1 -1
  37. package/dist/client/_nuxt/CTKqK4eG.js +1 -1
  38. package/dist/client/_nuxt/{B2TuRHFi.js → CUZJ8tqD.js} +1 -1
  39. package/dist/client/_nuxt/{CsgBhI1g.js → C_n3_iyW.js} +1 -1
  40. package/dist/client/_nuxt/C_tLznPO.js +43 -0
  41. package/dist/client/_nuxt/CbViG2Xw.js +1 -1
  42. package/dist/client/_nuxt/{CxLTb5RC.js → CoNBQO3e.js} +1 -1
  43. package/dist/client/_nuxt/D4C_EO1O.js +9 -0
  44. package/dist/client/_nuxt/{CPWqrNrA.js → D4FLysGE.js} +1 -1
  45. package/dist/client/_nuxt/{Bi99gj7u.js → D4V9JMY9.js} +1 -1
  46. package/dist/client/_nuxt/{CA5wVMK1.js → D5Dg5B9b.js} +1 -1
  47. package/dist/client/_nuxt/{BEKXAodE.js → D86udNSS.js} +1 -1
  48. package/dist/client/_nuxt/{gXK6hV6W.js → DAg81ukK.js} +1 -1
  49. package/dist/client/_nuxt/{CcKfWHXB.js → DDDCUP5E.js} +1 -1
  50. package/dist/client/_nuxt/DDMtKJxh.js +1 -1
  51. package/dist/client/_nuxt/{Cb_ad2sg.js → DHZqFavZ.js} +1 -1
  52. package/dist/client/_nuxt/{JMx2uAI6.js → DHsLiygU.js} +1 -1
  53. package/dist/client/_nuxt/{Dv0NFAnW.js → DJg41Obz.js} +1 -1
  54. package/dist/client/_nuxt/DJn5wykB.js +1 -0
  55. package/dist/client/_nuxt/{BkmSFWMo.js → DMjsYTya.js} +1 -1
  56. package/dist/client/_nuxt/{CWyKSuRn.js → DajZvwFy.js} +1 -1
  57. package/dist/client/_nuxt/Di-fSNio.js +1 -0
  58. package/dist/client/_nuxt/{D-a-w6CR.js → DiyNht5f.js} +1 -1
  59. package/dist/client/_nuxt/{CE84j0J9.js → Dm9RYIcI.js} +1 -1
  60. package/dist/client/_nuxt/{VNvxalkE.js → DockxStG.js} +1 -1
  61. package/dist/client/_nuxt/DpYuRYxj.js +1 -1
  62. package/dist/client/_nuxt/{DwdKwQHN.js → DqpvVAaa.js} +1 -1
  63. package/dist/client/_nuxt/{DKlNNSWk.js → DrswlxM3.js} +1 -1
  64. package/dist/client/_nuxt/{viHXAOJs.js → DtfHoqTV.js} +1 -1
  65. package/dist/client/_nuxt/{CPr4CZHz.js → J0gvLlTF.js} +1 -1
  66. package/dist/client/_nuxt/{CyS6YlEb.js → L3q7etZW.js} +1 -1
  67. package/dist/client/_nuxt/{BO314c-_.js → QxrU7fRC.js} +1 -1
  68. package/dist/client/_nuxt/{CmbkPMjd.js → RBAD4-dW.js} +1 -1
  69. package/dist/client/_nuxt/{CyvuMq07.js → T8d8zkkH.js} +1 -1
  70. package/dist/client/_nuxt/{2tJW9cKr.js → U0su7k1z.js} +1 -1
  71. package/dist/client/_nuxt/{CfVBzxeB.js → UI0GwUC_.js} +1 -1
  72. package/dist/client/_nuxt/{Cic6Ln_D.js → YWCqik9X.js} +1 -1
  73. package/dist/client/_nuxt/builds/latest.json +1 -1
  74. package/dist/client/_nuxt/builds/meta/1766755b-b307-4775-82c4-edb6a4a7e185.json +1 -0
  75. package/dist/client/_nuxt/{entry.Gpl6Gx6M.css → entry.eFSfOpqI.css} +1 -1
  76. package/dist/client/_nuxt/error-404.HYsbWGh9.css +1 -0
  77. package/dist/client/_nuxt/error-500.BwPFg8q2.css +1 -0
  78. package/dist/client/_nuxt/{CnW1WPg6.js → nhLZZe93.js} +1 -1
  79. package/dist/client/index.html +21 -21
  80. package/dist/module.d.mts +1 -1
  81. package/dist/module.d.ts +1 -1
  82. package/dist/module.json +2 -2
  83. package/dist/runtime/function-metrics-helpers.d.ts +1 -1
  84. package/dist/runtime/{function-metrics-helpers.mjs → function-metrics-helpers.js} +1 -1
  85. package/dist/runtime/plugins/{devtools.client.mjs → devtools.client.js} +2 -2
  86. package/dist/runtime/plugins/view/FrameBox.vue +5 -49
  87. package/dist/runtime/plugins/view/Main.vue +1 -147
  88. package/dist/runtime/plugins/view/client.d.ts +1 -1
  89. package/dist/runtime/plugins/view/{client.mjs → client.js} +2 -2
  90. package/dist/runtime/plugins/view/state.d.ts +1 -1
  91. package/dist/runtime/plugins/view/{state.mjs → state.js} +1 -1
  92. package/dist/runtime/settings.d.ts +1 -1
  93. package/dist/runtime/shared/hooks.d.ts +1 -1
  94. package/dist/runtime/use-nuxt-devtools.d.ts +1 -1
  95. package/package.json +18 -18
  96. package/dist/client/_nuxt/Cvo3JE8Q.js +0 -1
  97. package/dist/client/_nuxt/W2Tyz6z1.js +0 -9
  98. package/dist/client/_nuxt/builds/meta/a69820c2-31c2-48f6-8161-842a62467079.json +0 -1
  99. package/dist/client/_nuxt/ciodjZaS.js +0 -43
  100. package/dist/client/_nuxt/error-404.Bssqox27.css +0 -1
  101. package/dist/client/_nuxt/error-500.D3oXMFZl.css +0 -1
  102. package/dist/client/_nuxt/pl_4MfI2.js +0 -1
  103. /package/dist/runtime/nitro/{inline.mjs → inline.js} +0 -0
  104. /package/dist/runtime/plugins/{devtools.server.mjs → devtools.server.js} +0 -0
  105. /package/dist/runtime/plugins/view/{utils.mjs → utils.js} +0 -0
  106. /package/dist/runtime/{settings.mjs → settings.js} +0 -0
  107. /package/dist/runtime/shared/{hooks.mjs → hooks.js} +0 -0
  108. /package/dist/runtime/{use-nuxt-devtools.mjs → use-nuxt-devtools.js} +0 -0
  109. /package/dist/runtime/vue-devtools/{overlay.d.mts → overlay.d.ts} +0 -0
  110. /package/dist/runtime/vue-devtools/{overlay.mjs → overlay.js} +0 -0
@@ -1,4 +1,4 @@
1
- import t from"./CHuuZgn4.js";import e from"./CbYhyuC0.js";const n=Object.freeze({displayName:"HTML",injections:{"R:text.html - (comment.block, text.html meta.embedded, meta.tag.*.*.html, meta.tag.*.*.*.html, meta.tag.*.*.*.*.html)":{comment:"Uses R: to ensure this matches after any other injections.",patterns:[{match:"<",name:"invalid.illegal.bad-angle-bracket.html"}]}},name:"html",patterns:[{include:"#xml-processing"},{include:"#comment"},{include:"#doctype"},{include:"#cdata"},{include:"#tags-valid"},{include:"#tags-invalid"},{include:"#entities"}],repository:{attribute:{patterns:[{begin:"(s(hape|cope|t(ep|art)|ize(s)?|p(ellcheck|an)|elected|lot|andbox|rc(set|doc|lang)?)|h(ttp-equiv|i(dden|gh)|e(ight|aders)|ref(lang)?)|n(o(nce|validate|module)|ame)|c(h(ecked|arset)|ite|o(nt(ent(editable)?|rols)|ords|l(s(pan)?|or))|lass|rossorigin)|t(ype(mustmatch)?|itle|a(rget|bindex)|ranslate)|i(s(map)?|n(tegrity|putmode)|tem(scope|type|id|prop|ref)|d)|op(timum|en)|d(i(sabled|r(name)?)|ownload|e(coding|f(er|ault))|at(etime|a)|raggable)|usemap|p(ing|oster|la(ysinline|ceholder)|attern|reload)|enctype|value|kind|for(m(novalidate|target|enctype|action|method)?)?|w(idth|rap)|l(ist|o(op|w)|a(ng|bel))|a(s(ync)?|c(ce(sskey|pt(-charset)?)|tion)|uto(c(omplete|apitalize)|play|focus)|l(t|low(usermedia|paymentrequest|fullscreen))|bbr)|r(ows(pan)?|e(versed|quired|ferrerpolicy|l|adonly))|m(in(length)?|u(ted|ltiple)|e(thod|dia)|a(nifest|x(length)?)))(?![\\w:-])",beginCaptures:{0:{name:"entity.other.attribute-name.html"}},comment:"HTML5 attributes, not event handlers",end:"(?=\\s*+[^=\\s])",name:"meta.attribute.$1.html",patterns:[{include:"#attribute-interior"}]},{begin:"style(?![\\w:-])",beginCaptures:{0:{name:"entity.other.attribute-name.html"}},comment:"HTML5 style attribute",end:"(?=\\s*+[^=\\s])",name:"meta.attribute.style.html",patterns:[{begin:"=",beginCaptures:{0:{name:"punctuation.separator.key-value.html"}},end:"(?<=[^\\s=])(?!\\s*=)|(?=/?>)",patterns:[{begin:"(?=[^\\s=<>`/]|/(?!>))",end:"(?!\\G)",name:"meta.embedded.line.css",patterns:[{captures:{0:{name:"source.css"}},match:"([^\\s\"'=<>`/]|/(?!>))+",name:"string.unquoted.html"},{begin:'"',beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},contentName:"source.css",end:'(")',endCaptures:{0:{name:"punctuation.definition.string.end.html"},1:{name:"source.css"}},name:"string.quoted.double.html",patterns:[{include:"#entities"}]},{begin:"'",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},contentName:"source.css",end:"(')",endCaptures:{0:{name:"punctuation.definition.string.end.html"},1:{name:"source.css"}},name:"string.quoted.single.html",patterns:[{include:"#entities"}]}]},{match:"=",name:"invalid.illegal.unexpected-equals-sign.html"}]}]},{begin:"on(s(croll|t(orage|alled)|u(spend|bmit)|e(curitypolicyviolation|ek(ing|ed)|lect))|hashchange|c(hange|o(ntextmenu|py)|u(t|echange)|l(ick|ose)|an(cel|play(through)?))|t(imeupdate|oggle)|in(put|valid)|o(nline|ffline)|d(urationchange|r(op|ag(start|over|e(n(ter|d)|xit)|leave)?)|blclick)|un(handledrejection|load)|p(opstate|lay(ing)?|a(ste|use|ge(show|hide))|rogress)|e(nded|rror|mptied)|volumechange|key(down|up|press)|focus|w(heel|aiting)|l(oad(start|e(nd|d(data|metadata)))?|anguagechange)|a(uxclick|fterprint|bort)|r(e(s(ize|et)|jectionhandled)|atechange)|m(ouse(o(ut|ver)|down|up|enter|leave|move)|essage(error)?)|b(efore(unload|print)|lur))(?![\\w:-])",beginCaptures:{0:{name:"entity.other.attribute-name.html"}},comment:"HTML5 attributes, event handlers",end:"(?=\\s*+[^=\\s])",name:"meta.attribute.event-handler.$1.html",patterns:[{begin:"=",beginCaptures:{0:{name:"punctuation.separator.key-value.html"}},end:"(?<=[^\\s=])(?!\\s*=)|(?=/?>)",patterns:[{begin:"(?=[^\\s=<>`/]|/(?!>))",end:"(?!\\G)",name:"meta.embedded.line.js",patterns:[{captures:{0:{name:"source.js"},1:{patterns:[{include:"source.js"}]}},match:"(([^\\s\"'=<>`/]|/(?!>))+)",name:"string.unquoted.html"},{begin:'"',beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},contentName:"source.js",end:'(")',endCaptures:{0:{name:"punctuation.definition.string.end.html"},1:{name:"source.js"}},name:"string.quoted.double.html",patterns:[{captures:{0:{patterns:[{include:"source.js"}]}},match:'([^\\n"/]|/(?![/*]))+'},{begin:"//",beginCaptures:{0:{name:"punctuation.definition.comment.js"}},end:'(?=")|\\n',name:"comment.line.double-slash.js"},{begin:"/\\*",beginCaptures:{0:{name:"punctuation.definition.comment.begin.js"}},end:'(?=")|\\*/',endCaptures:{0:{name:"punctuation.definition.comment.end.js"}},name:"comment.block.js"}]},{begin:"'",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},contentName:"source.js",end:"(')",endCaptures:{0:{name:"punctuation.definition.string.end.html"},1:{name:"source.js"}},name:"string.quoted.single.html",patterns:[{captures:{0:{patterns:[{include:"source.js"}]}},match:"([^\\n'/]|/(?![/*]))+"},{begin:"//",beginCaptures:{0:{name:"punctuation.definition.comment.js"}},end:"(?=')|\\n",name:"comment.line.double-slash.js"},{begin:"/\\*",beginCaptures:{0:{name:"punctuation.definition.comment.begin.js"}},end:"(?=')|\\*/",endCaptures:{0:{name:"punctuation.definition.comment.end.js"}},name:"comment.block.js"}]}]},{match:"=",name:"invalid.illegal.unexpected-equals-sign.html"}]}]},{begin:"(data-[a-z\\-]+)(?![\\w:-])",beginCaptures:{0:{name:"entity.other.attribute-name.html"}},comment:"HTML5 attributes, data-*",end:"(?=\\s*+[^=\\s])",name:"meta.attribute.data-x.$1.html",patterns:[{include:"#attribute-interior"}]},{begin:"(align|bgcolor|border)(?![\\w:-])",beginCaptures:{0:{name:"invalid.deprecated.entity.other.attribute-name.html"}},comment:"HTML attributes, deprecated",end:"(?=\\s*+[^=\\s])",name:"meta.attribute.$1.html",patterns:[{include:"#attribute-interior"}]},{begin:`([^\\x{0020}"'<>/=\\x{0000}-\\x{001F}\\x{007F}-\\x{009F}\\x{FDD0}-\\x{FDEF}\\x{FFFE}\\x{FFFF}\\x{1FFFE}\\x{1FFFF}\\x{2FFFE}\\x{2FFFF}\\x{3FFFE}\\x{3FFFF}\\x{4FFFE}\\x{4FFFF}\\x{5FFFE}\\x{5FFFF}\\x{6FFFE}\\x{6FFFF}\\x{7FFFE}\\x{7FFFF}\\x{8FFFE}\\x{8FFFF}\\x{9FFFE}\\x{9FFFF}\\x{AFFFE}\\x{AFFFF}\\x{BFFFE}\\x{BFFFF}\\x{CFFFE}\\x{CFFFF}\\x{DFFFE}\\x{DFFFF}\\x{EFFFE}\\x{EFFFF}\\x{FFFFE}\\x{FFFFF}\\x{10FFFE}\\x{10FFFF}]+)`,beginCaptures:{0:{name:"entity.other.attribute-name.html"}},comment:"Anything else that is valid",end:"(?=\\s*+[^=\\s])",name:"meta.attribute.unrecognized.$1.html",patterns:[{include:"#attribute-interior"}]},{match:"[^\\s>]+",name:"invalid.illegal.character-not-allowed-here.html"}]},"attribute-interior":{patterns:[{begin:"=",beginCaptures:{0:{name:"punctuation.separator.key-value.html"}},end:"(?<=[^\\s=])(?!\\s*=)|(?=/?>)",patterns:[{match:"([^\\s\"'=<>`/]|/(?!>))+",name:"string.unquoted.html"},{begin:'"',beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:'"',endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"string.quoted.double.html",patterns:[{include:"#entities"}]},{begin:"'",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:"'",endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"string.quoted.single.html",patterns:[{include:"#entities"}]},{match:"=",name:"invalid.illegal.unexpected-equals-sign.html"}]}]},cdata:{begin:"<!\\[CDATA\\[",beginCaptures:{0:{name:"punctuation.definition.tag.begin.html"}},contentName:"string.other.inline-data.html",end:"]]>",endCaptures:{0:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.metadata.cdata.html"},comment:{begin:"<!--",captures:{0:{name:"punctuation.definition.comment.html"}},end:"-->",name:"comment.block.html",patterns:[{match:"\\G-?>",name:"invalid.illegal.characters-not-allowed-here.html"},{match:"<!--(?!>)|<!-(?=-->)",name:"invalid.illegal.characters-not-allowed-here.html"},{match:"--!>",name:"invalid.illegal.characters-not-allowed-here.html"}]},"core-minus-invalid":{comment:"This should be the root pattern array includes minus #tags-invalid",patterns:[{include:"#xml-processing"},{include:"#comment"},{include:"#doctype"},{include:"#cdata"},{include:"#tags-valid"},{include:"#entities"}]},doctype:{begin:"<!(?=(?i:DOCTYPE\\s))",beginCaptures:{0:{name:"punctuation.definition.tag.begin.html"}},end:">",endCaptures:{0:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.metadata.doctype.html",patterns:[{match:"\\G(?i:DOCTYPE)",name:"entity.name.tag.html"},{begin:'"',end:'"',name:"string.quoted.double.html"},{match:"[^\\s>]+",name:"entity.other.attribute-name.html"}]},entities:{patterns:[{captures:{1:{name:"punctuation.definition.entity.html"},912:{name:"punctuation.definition.entity.html"}},comment:"Yes this is a bit ridiculous, there are quite a lot of these",match:`(?x)
1
+ import t from"./Dch3xQiY.js";import e from"./CbYhyuC0.js";const n=Object.freeze({displayName:"HTML",injections:{"R:text.html - (comment.block, text.html meta.embedded, meta.tag.*.*.html, meta.tag.*.*.*.html, meta.tag.*.*.*.*.html)":{comment:"Uses R: to ensure this matches after any other injections.",patterns:[{match:"<",name:"invalid.illegal.bad-angle-bracket.html"}]}},name:"html",patterns:[{include:"#xml-processing"},{include:"#comment"},{include:"#doctype"},{include:"#cdata"},{include:"#tags-valid"},{include:"#tags-invalid"},{include:"#entities"}],repository:{attribute:{patterns:[{begin:"(s(hape|cope|t(ep|art)|ize(s)?|p(ellcheck|an)|elected|lot|andbox|rc(set|doc|lang)?)|h(ttp-equiv|i(dden|gh)|e(ight|aders)|ref(lang)?)|n(o(nce|validate|module)|ame)|c(h(ecked|arset)|ite|o(nt(ent(editable)?|rols)|ords|l(s(pan)?|or))|lass|rossorigin)|t(ype(mustmatch)?|itle|a(rget|bindex)|ranslate)|i(s(map)?|n(tegrity|putmode)|tem(scope|type|id|prop|ref)|d)|op(timum|en)|d(i(sabled|r(name)?)|ownload|e(coding|f(er|ault))|at(etime|a)|raggable)|usemap|p(ing|oster|la(ysinline|ceholder)|attern|reload)|enctype|value|kind|for(m(novalidate|target|enctype|action|method)?)?|w(idth|rap)|l(ist|o(op|w)|a(ng|bel))|a(s(ync)?|c(ce(sskey|pt(-charset)?)|tion)|uto(c(omplete|apitalize)|play|focus)|l(t|low(usermedia|paymentrequest|fullscreen))|bbr)|r(ows(pan)?|e(versed|quired|ferrerpolicy|l|adonly))|m(in(length)?|u(ted|ltiple)|e(thod|dia)|a(nifest|x(length)?)))(?![\\w:-])",beginCaptures:{0:{name:"entity.other.attribute-name.html"}},comment:"HTML5 attributes, not event handlers",end:"(?=\\s*+[^=\\s])",name:"meta.attribute.$1.html",patterns:[{include:"#attribute-interior"}]},{begin:"style(?![\\w:-])",beginCaptures:{0:{name:"entity.other.attribute-name.html"}},comment:"HTML5 style attribute",end:"(?=\\s*+[^=\\s])",name:"meta.attribute.style.html",patterns:[{begin:"=",beginCaptures:{0:{name:"punctuation.separator.key-value.html"}},end:"(?<=[^\\s=])(?!\\s*=)|(?=/?>)",patterns:[{begin:"(?=[^\\s=<>`/]|/(?!>))",end:"(?!\\G)",name:"meta.embedded.line.css",patterns:[{captures:{0:{name:"source.css"}},match:"([^\\s\"'=<>`/]|/(?!>))+",name:"string.unquoted.html"},{begin:'"',beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},contentName:"source.css",end:'(")',endCaptures:{0:{name:"punctuation.definition.string.end.html"},1:{name:"source.css"}},name:"string.quoted.double.html",patterns:[{include:"#entities"}]},{begin:"'",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},contentName:"source.css",end:"(')",endCaptures:{0:{name:"punctuation.definition.string.end.html"},1:{name:"source.css"}},name:"string.quoted.single.html",patterns:[{include:"#entities"}]}]},{match:"=",name:"invalid.illegal.unexpected-equals-sign.html"}]}]},{begin:"on(s(croll|t(orage|alled)|u(spend|bmit)|e(curitypolicyviolation|ek(ing|ed)|lect))|hashchange|c(hange|o(ntextmenu|py)|u(t|echange)|l(ick|ose)|an(cel|play(through)?))|t(imeupdate|oggle)|in(put|valid)|o(nline|ffline)|d(urationchange|r(op|ag(start|over|e(n(ter|d)|xit)|leave)?)|blclick)|un(handledrejection|load)|p(opstate|lay(ing)?|a(ste|use|ge(show|hide))|rogress)|e(nded|rror|mptied)|volumechange|key(down|up|press)|focus|w(heel|aiting)|l(oad(start|e(nd|d(data|metadata)))?|anguagechange)|a(uxclick|fterprint|bort)|r(e(s(ize|et)|jectionhandled)|atechange)|m(ouse(o(ut|ver)|down|up|enter|leave|move)|essage(error)?)|b(efore(unload|print)|lur))(?![\\w:-])",beginCaptures:{0:{name:"entity.other.attribute-name.html"}},comment:"HTML5 attributes, event handlers",end:"(?=\\s*+[^=\\s])",name:"meta.attribute.event-handler.$1.html",patterns:[{begin:"=",beginCaptures:{0:{name:"punctuation.separator.key-value.html"}},end:"(?<=[^\\s=])(?!\\s*=)|(?=/?>)",patterns:[{begin:"(?=[^\\s=<>`/]|/(?!>))",end:"(?!\\G)",name:"meta.embedded.line.js",patterns:[{captures:{0:{name:"source.js"},1:{patterns:[{include:"source.js"}]}},match:"(([^\\s\"'=<>`/]|/(?!>))+)",name:"string.unquoted.html"},{begin:'"',beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},contentName:"source.js",end:'(")',endCaptures:{0:{name:"punctuation.definition.string.end.html"},1:{name:"source.js"}},name:"string.quoted.double.html",patterns:[{captures:{0:{patterns:[{include:"source.js"}]}},match:'([^\\n"/]|/(?![/*]))+'},{begin:"//",beginCaptures:{0:{name:"punctuation.definition.comment.js"}},end:'(?=")|\\n',name:"comment.line.double-slash.js"},{begin:"/\\*",beginCaptures:{0:{name:"punctuation.definition.comment.begin.js"}},end:'(?=")|\\*/',endCaptures:{0:{name:"punctuation.definition.comment.end.js"}},name:"comment.block.js"}]},{begin:"'",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},contentName:"source.js",end:"(')",endCaptures:{0:{name:"punctuation.definition.string.end.html"},1:{name:"source.js"}},name:"string.quoted.single.html",patterns:[{captures:{0:{patterns:[{include:"source.js"}]}},match:"([^\\n'/]|/(?![/*]))+"},{begin:"//",beginCaptures:{0:{name:"punctuation.definition.comment.js"}},end:"(?=')|\\n",name:"comment.line.double-slash.js"},{begin:"/\\*",beginCaptures:{0:{name:"punctuation.definition.comment.begin.js"}},end:"(?=')|\\*/",endCaptures:{0:{name:"punctuation.definition.comment.end.js"}},name:"comment.block.js"}]}]},{match:"=",name:"invalid.illegal.unexpected-equals-sign.html"}]}]},{begin:"(data-[a-z\\-]+)(?![\\w:-])",beginCaptures:{0:{name:"entity.other.attribute-name.html"}},comment:"HTML5 attributes, data-*",end:"(?=\\s*+[^=\\s])",name:"meta.attribute.data-x.$1.html",patterns:[{include:"#attribute-interior"}]},{begin:"(align|bgcolor|border)(?![\\w:-])",beginCaptures:{0:{name:"invalid.deprecated.entity.other.attribute-name.html"}},comment:"HTML attributes, deprecated",end:"(?=\\s*+[^=\\s])",name:"meta.attribute.$1.html",patterns:[{include:"#attribute-interior"}]},{begin:`([^\\x{0020}"'<>/=\\x{0000}-\\x{001F}\\x{007F}-\\x{009F}\\x{FDD0}-\\x{FDEF}\\x{FFFE}\\x{FFFF}\\x{1FFFE}\\x{1FFFF}\\x{2FFFE}\\x{2FFFF}\\x{3FFFE}\\x{3FFFF}\\x{4FFFE}\\x{4FFFF}\\x{5FFFE}\\x{5FFFF}\\x{6FFFE}\\x{6FFFF}\\x{7FFFE}\\x{7FFFF}\\x{8FFFE}\\x{8FFFF}\\x{9FFFE}\\x{9FFFF}\\x{AFFFE}\\x{AFFFF}\\x{BFFFE}\\x{BFFFF}\\x{CFFFE}\\x{CFFFF}\\x{DFFFE}\\x{DFFFF}\\x{EFFFE}\\x{EFFFF}\\x{FFFFE}\\x{FFFFF}\\x{10FFFE}\\x{10FFFF}]+)`,beginCaptures:{0:{name:"entity.other.attribute-name.html"}},comment:"Anything else that is valid",end:"(?=\\s*+[^=\\s])",name:"meta.attribute.unrecognized.$1.html",patterns:[{include:"#attribute-interior"}]},{match:"[^\\s>]+",name:"invalid.illegal.character-not-allowed-here.html"}]},"attribute-interior":{patterns:[{begin:"=",beginCaptures:{0:{name:"punctuation.separator.key-value.html"}},end:"(?<=[^\\s=])(?!\\s*=)|(?=/?>)",patterns:[{match:"([^\\s\"'=<>`/]|/(?!>))+",name:"string.unquoted.html"},{begin:'"',beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:'"',endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"string.quoted.double.html",patterns:[{include:"#entities"}]},{begin:"'",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:"'",endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"string.quoted.single.html",patterns:[{include:"#entities"}]},{match:"=",name:"invalid.illegal.unexpected-equals-sign.html"}]}]},cdata:{begin:"<!\\[CDATA\\[",beginCaptures:{0:{name:"punctuation.definition.tag.begin.html"}},contentName:"string.other.inline-data.html",end:"]]>",endCaptures:{0:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.metadata.cdata.html"},comment:{begin:"<!--",captures:{0:{name:"punctuation.definition.comment.html"}},end:"-->",name:"comment.block.html",patterns:[{match:"\\G-?>",name:"invalid.illegal.characters-not-allowed-here.html"},{match:"<!--(?!>)|<!-(?=-->)",name:"invalid.illegal.characters-not-allowed-here.html"},{match:"--!>",name:"invalid.illegal.characters-not-allowed-here.html"}]},"core-minus-invalid":{comment:"This should be the root pattern array includes minus #tags-invalid",patterns:[{include:"#xml-processing"},{include:"#comment"},{include:"#doctype"},{include:"#cdata"},{include:"#tags-valid"},{include:"#entities"}]},doctype:{begin:"<!(?=(?i:DOCTYPE\\s))",beginCaptures:{0:{name:"punctuation.definition.tag.begin.html"}},end:">",endCaptures:{0:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.metadata.doctype.html",patterns:[{match:"\\G(?i:DOCTYPE)",name:"entity.name.tag.html"},{begin:'"',end:'"',name:"string.quoted.double.html"},{match:"[^\\s>]+",name:"entity.other.attribute-name.html"}]},entities:{patterns:[{captures:{1:{name:"punctuation.definition.entity.html"},912:{name:"punctuation.definition.entity.html"}},comment:"Yes this is a bit ridiculous, there are quite a lot of these",match:`(?x)
2
2
  (&) (?=[a-zA-Z])
3
3
  (
4
4
  (a(s(ymp(eq)?|cr|t)|n(d(slope|d|v|and)?|g(s(t|ph)|zarr|e|le|rt(vb(d)?)?|msd(a(h|c|d|e|f|a|g|b))?)?)|c(y|irc|d|ute|E)?|tilde|o(pf|gon)|uml|p(id|os|prox(eq)?|e|E|acir)?|elig|f(r)?|w(conint|int)|l(pha|e(ph|fsym))|acute|ring|grave|m(p|a(cr|lg))|breve)|A(s(sign|cr)|nd|MP|c(y|irc)|tilde|o(pf|gon)|uml|pplyFunction|fr|Elig|lpha|acute|ring|grave|macr|breve))
@@ -1 +1 @@
1
- import{d as s,a as u,o as d,m as f,v as p,t as o,f as n,k as c,G as m}from"./ciodjZaS.js";const x={"ml-1":"","text-xs":"",op50:""},g=s({__name:"DurationDisplay",props:{duration:{},factor:{default:1},color:{type:Boolean,default:!0}},setup(a){const t=a;function i(r){return t.color?r?(r=r*t.factor,r<.5?"text-gray:50":r>1e3?"text-red-400":r>500?"text-orange-400":r>200?"text-yellow-400":""):"text-gray-400":""}const e=u(()=>!t.duration||t.duration<1?["<1","ms"]:t.duration<1e3?[t.duration.toFixed(0),"ms"]:t.duration<1e3*60?[(t.duration/1e3).toFixed(1),"s"]:[(t.duration/1e3/60).toFixed(1),"min"]);return(r,l)=>(d(),f("div",{class:m(i(r.duration))},[p(o(n(e)[0]),1),c("span",x,o(n(e)[1]),1)],2))}});export{g as _};
1
+ import{d as s,a as u,o as d,m as f,v as p,t as o,f as n,k as c,G as m}from"./C_tLznPO.js";const x={"ml-1":"","text-xs":"",op50:""},g=s({__name:"DurationDisplay",props:{duration:{},factor:{default:1},color:{type:Boolean,default:!0}},setup(a){const t=a;function i(r){return t.color?r?(r=r*t.factor,r<.5?"text-gray:50":r>1e3?"text-red-400":r>500?"text-orange-400":r>200?"text-yellow-400":""):"text-gray-400":""}const e=u(()=>!t.duration||t.duration<1?["<1","ms"]:t.duration<1e3?[t.duration.toFixed(0),"ms"]:t.duration<1e3*60?[(t.duration/1e3).toFixed(1),"s"]:[(t.duration/1e3/60).toFixed(1),"min"]);return(r,l)=>(d(),f("div",{class:m(i(r.duration))},[p(o(n(e)[0]),1),c("span",x,o(n(e)[1]),1)],2))}});export{g as _};
@@ -0,0 +1,9 @@
1
+ import{d as ye,r as A,bH as Re,o as i,m as b,k as c,G as B,h as $,f as e,bI as ie,t as U,p as O,v as Q,a9 as Qe,aa as Xe,F as L,n as G,a6 as Ee,bz as he,w as De,by as je,bx as Ye,bJ as Ze,bK as et,aC as tt,bL as ot,ao as nt,ab as st,am as at,aA as ve,a as D,ac as rt,ak as Ve,aD as lt,b2 as it,bM as ut,e as ct,a2 as Ie,j as S,l as Z,i as v,I as ee,ay as dt,V as pt,_ as Ue,X as ft,A as Oe,an as mt,bN as vt,ah as ht,U as yt,bO as _t,at as gt}from"./C_tLznPO.js";import{_ as bt}from"./BHh_UM9T.js";import{_ as Ne}from"./D4V9JMY9.js";import{_ as kt}from"./BiRcA7Ly.js";import{_ as Le}from"./7oK7PdYH.js";import{_ as wt}from"./BopA0WYG.js";import{_ as Ct}from"./BkwfBuTq.js";import{_ as xt}from"./CIvuwNIv.js";import{C as xe,S as Ae}from"./BcJws1i5.js";import{e as St}from"./B3uNdhXb.js";import{_ as Tt}from"./DqpvVAaa.js";import{_ as $t}from"./DrswlxM3.js";import"./BKeomq25.js";import"./CO7Eo6nF.js";import"./B1veJI6T.js";function Rt(t,a){if(typeof t!="string")throw new TypeError("argument str must be a string");const n={},o=a||{},_=o.decode||Et;let m=0;for(;m<t.length;){const d=t.indexOf("=",m);if(d===-1)break;let h=t.indexOf(";",m);if(h===-1)h=t.length;else if(h<d){m=t.lastIndexOf(";",d-1)+1;continue}const y=t.slice(m,d).trim();if(o?.filter&&!o?.filter(y)){m=h+1;continue}if(n[y]===void 0){let u=t.slice(d+1,h).trim();u.codePointAt(0)===34&&(u=u.slice(1,-1)),n[y]=Dt(u,_)}m=h+1}return n}function Et(t){return t.includes("%")?decodeURIComponent(t):t}function Dt(t,a){try{return a(t)}catch{return t}}const re=/^[\u0009\u0020-\u007E\u0080-\u00FF]+$/;function Se(t,a,n){const o=n||{},_=o.encode||encodeURIComponent;if(typeof _!="function")throw new TypeError("option encode is invalid");if(!re.test(t))throw new TypeError("argument name is invalid");const m=_(a);if(m&&!re.test(m))throw new TypeError("argument val is invalid");let d=t+"="+m;if(o.maxAge!==void 0&&o.maxAge!==null){const h=o.maxAge-0;if(Number.isNaN(h)||!Number.isFinite(h))throw new TypeError("option maxAge is invalid");d+="; Max-Age="+Math.floor(h)}if(o.domain){if(!re.test(o.domain))throw new TypeError("option domain is invalid");d+="; Domain="+o.domain}if(o.path){if(!re.test(o.path))throw new TypeError("option path is invalid");d+="; Path="+o.path}if(o.expires){if(!jt(o.expires)||Number.isNaN(o.expires.valueOf()))throw new TypeError("option expires is invalid");d+="; Expires="+o.expires.toUTCString()}if(o.httpOnly&&(d+="; HttpOnly"),o.secure&&(d+="; Secure"),o.priority)switch(typeof o.priority=="string"?o.priority.toLowerCase():o.priority){case"low":{d+="; Priority=Low";break}case"medium":{d+="; Priority=Medium";break}case"high":{d+="; 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:{d+="; SameSite=Strict";break}case"lax":{d+="; SameSite=Lax";break}case"strict":{d+="; SameSite=Strict";break}case"none":{d+="; SameSite=None";break}default:throw new TypeError("option sameSite is invalid")}return o.partitioned&&(d+="; Partitioned"),d}function jt(t){return Object.prototype.toString.call(t)==="[object Date]"||t instanceof Date}const Vt=c("div",{"x-divider":""},null,-1),Pe=ye({__name:"ServerRouteListItem",props:{item:{},index:{default:0}},setup(t){const a=A(!0),n=Re();return(o,_)=>{const m=Ee,d=Ne,h=Pe;return i(),b("div",null,[c("button",{flex:"~ gap-2","w-full":"","items-start":"","items-center":"","hover-bg-active":"",px2:"",py1:"",class:B([{"bg-active":e(n)===o.item.filepath}]),style:Qe({paddingLeft:`calc(0.5rem + ${o.index*1.5}em)`}),onClick:_[0]||(_[0]=y=>{a.value=!e(a),n.value=o.item.filepath})},[c("div",{class:B({"w-12":!o.item.routes}),"flex-none":"","text-left":""},[o.item.type==="collection"?(i(),$(m,{key:0,icon:"carbon:chevron-right","mb0.5":"","transform-rotate":e(a)?90:0,transition:""},null,8,["transform-rotate"])):(i(),$(d,{key:1,class:B(("getRequestMethodClass"in o?o.getRequestMethodClass:e(ie))(o.item.method||"*")),textContent:U((o.item.method||"*").toUpperCase())},null,8,["class","textContent"]))],2),c("span",{class:B({"flex items-center":o.item.routes}),"text-sm":"","font-mono":""},[o.item.type==="collection"?(i(),$(m,{key:0,title:`${o.item.routes?.length} routes`,icon:"carbon:folder",mr1:""},null,8,["title"])):O("",!0),Q(" "+U(o.item.route),1)],2)],6),Vt,e(a)?Xe(o.$slots,"default",{key:0},()=>[(i(!0),b(L,null,G(o.item.routes,y=>(i(),$(h,{key:y.filepath,item:y,index:o.index+1},null,8,["item","index"]))),128))]):O("",!0)])}}});function q(t){if(typeof t!="object")return t;var a,n,o=Object.prototype.toString.call(t);if(o==="[object Object]"){if(t.constructor!==Object&&typeof t.constructor=="function"){n=new t.constructor;for(a in t)t.hasOwnProperty(a)&&n[a]!==t[a]&&(n[a]=q(t[a]))}else{n={};for(a in t)a==="__proto__"?Object.defineProperty(n,a,{value:q(t[a]),configurable:!0,enumerable:!0,writable:!0}):n[a]=q(t[a])}return n}if(o==="[object Array]"){for(a=t.length,n=Array(a);a--;)n[a]=q(t[a]);return n}return o==="[object Set]"?(n=new Set,t.forEach(function(_){n.add(q(_))}),n):o==="[object Map]"?(n=new Map,t.forEach(function(_,m){n.set(q(m),q(_))}),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(q(t.buffer)):o==="[object ArrayBuffer]"?t.slice(0):o.slice(-6)==="Array]"?new t.constructor(t):t}const It={path:"/",watch:!0,decode:t=>Ze(decodeURIComponent(t)),encode:t=>encodeURIComponent(typeof t=="string"?t:JSON.stringify(t))},le=window.cookieStore;function Ut(t,a){const n={...It,...a};n.filter??=y=>y===t;const o=Te(n)||{};let _;n.maxAge!==void 0?_=n.maxAge*1e3:n.expires&&(_=n.expires.getTime()-Date.now());const m=_!==void 0&&_<=0,d=q(m?void 0:o[t]??n.default?.()),h=_&&!m?Lt(d,_,n.watch&&n.watch!=="shallow"):A(d);{let y=null;try{!le&&typeof BroadcastChannel<"u"&&(y=new BroadcastChannel(`nuxt:cookies:${t}`))}catch{}const u=()=>{n.readonly||et(h.value,o[t])||(Nt(t,h.value,n),o[t]=q(h.value),y?.postMessage({value:n.encode(h.value)}))},j=P=>{const x=P.refresh?Te(n)?.[t]:n.decode(P.value);I=!0,h.value=x,o[t]=q(x),tt(()=>{I=!1})};let I=!1;const F=!!je();if(F&&he(()=>{I=!0,u(),y?.close()}),le){const P=x=>{const w=x.changed.find(N=>N.name===t);w&&j({value:w.value})};le.addEventListener("change",P),F&&he(()=>le.removeEventListener("change",P))}else y&&(y.onmessage=({data:P})=>j(P));n.watch?De(h,()=>{I||u()},{deep:n.watch!=="shallow"}):u()}return h}function Te(t={}){return Rt(document.cookie,t)}function Ot(t,a,n={}){return a==null?Se(t,a,{...n,maxAge:-1}):Se(t,a,n)}function Nt(t,a,n={}){document.cookie=Ot(t,a,n)}const $e=2147483647;function Lt(t,a,n){let o,_,m=0;const d=n?A(t):{value:t};return je()&&he(()=>{_?.(),clearTimeout(o)}),Ye((h,y)=>{n&&(_=De(d,y));function u(){m=0,clearTimeout(o);const j=a-m,I=j<$e?j:$e;o=setTimeout(()=>{if(m+=I,m<a)return u();d.value=void 0,y()},I)}return{get(){return h(),d.value},set(j){u(),d.value=j,y()}}})}const At={"h-full":"","w-full":"",flex:"~ col"},Pt={flex:"~ col gap-2","flex-none":"",p4:"","n-navbar-glass":""},qt={flex:"~ gap2 items-center"},Mt={relative:"","w-full":""},Bt={absolute:"","right-2":"","top-1.5":"",flex:"~ gap-1"},Ft={flex:"~ gap2 wrap","w-full":"","items-center":"",px4:"",pb2:"","text-center":"","text-sm":"",border:"b base"},Ht={class:"hidden md:block"},zt=c("div",{"flex-auto":""},null,-1),Gt=c("div",{"text-xs":"",op50:""}," Send from ",-1),Jt=c("option",{value:"app"}," App ",-1),Wt=c("option",{value:"devtools"}," DevTools ",-1),Kt={key:0,border:"b base","items-center":"",px4:"",py2:"",grid:"~ cols-[max-content_1fr] gap-2"},Qt={"text-right":"","font-mono":""},Xt={key:1,border:"b base",p4:"",flex:"~ col gap-4","font-mono":""},Yt={flex:"~ gap-4"},Zt={flex:"~ gap2","mb--2":"","items-center":"",op50:""},eo=c("div",{"w-5":"","x-divider":""},null,-1),to=c("div",{"flex-none":""}," Default Inputs ",-1),oo=c("div",{"x-divider":""},null,-1),no={key:2},so={key:3,border:"b base",relative:"","n-code-block":""},ao={flex:"~ wrap","w-full":""},ro=["onClick"],lo=c("div",{border:"b base","flex-auto":""},null,-1),io={border:"b base",flex:"~ gap2","items-center":"",px4:"",py2:""},uo=c("div",null,"Response",-1),co={key:1,"text-xs":"",op50:""},po=c("div",{"flex-auto":""},null,-1),fo=c("div",{op50:""}," Request finished in ",-1),mo={key:0,"flex-auto":"","overflow-auto":""},vo={border:"~ base","h-full":"","w-full":"",rounded:""},ho=["data"],yo={key:2,"flex-auto":"","overflow-auto":"",p4:""},_o={border:"~ base",rounded:""},go=["src"],bo={key:1,controls:"",rounded:""},ko=["src"],wo=ye({__name:"ServerRouteDetails",props:{route:{}},emits:["open-default-input"],setup(t,{emit:a}){const n=t,o=a,[_,m]=ot(),d=nt(),h=st(),y=at(),u=ve({contentType:"text/plain",data:"",statusCode:200,error:void 0,fetchTime:0}),j=D(()=>u.contentType.includes("application/json")?"json":u.contentType.includes("text/html")?"html":u.contentType.includes("text/css")?"css":u.contentType.includes("text/javascript")?"javascript":u.contentType.includes("image")||u.contentType.includes("video")?"media":u.contentType.includes("text/xml")||u.contentType.includes("application/xml")?"xml":u.contentType.includes("application/pdf")?"pdf":"text"),I=D(()=>{if(j.value==="json")return JSON.stringify(u.data,null,2);if(j.value==="media"||j.value==="pdf"){const s=new Blob([u.data],{type:u.contentType});return URL.createObjectURL(s)}return u.data}),F=A(!1),P=A(!1),x=rt(),w=D(()=>n.route.route?.split(/((?:\*\*)?:\w+)/g)),N=D(()=>w.value?.filter(s=>s.startsWith(":")||s.startsWith("**:"))||[]),g=A(n.route.method||"GET"),R=A({}),k=ve({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"}]}),V=A({}),{inputDefaults:C,sendFrom:H}=Ve("serverRoutes"),J=D(()=>y?.value?.app?.$fetch?H.value:"devtools"),ue=["GET","POST","PUT","PATCH","DELETE","HEAD"],ce=["PATCH","POST","PUT","DELETE"],te=D(()=>ce.includes(g.value.toUpperCase())),p=A(),oe=["input","json"],W=A(oe[0]),ne=D({get:()=>k[p.value],set:s=>{k[p.value]=s}}),_e=D(()=>({...K(C.value.query),...K(k.query)})),ge=D(()=>({...K(C.value.headers),...K(k.headers)})),de=D(()=>te.value?W.value==="json"?{...K(C.value.body),...V.value}:{...K(C.value.body),...K(k.body)}:void 0),qe=D(()=>{let s=window?.location.origin;return s.charAt(s.length-1)==="/"&&(s=s.slice(0,-1)),s}),se=D(()=>{let s=new URLSearchParams(_e.value).toString();s&&(s=`?${s}`);const l=(w.value?.map(E=>(E.startsWith(":")||E.startsWith("**:"))&&R.value[E]||E).join("")||"")+s;let f=h.value?.app.baseURL||"";return(f==="./"||f===".")&&(f=""),f.endsWith("/")&&(f=f.slice(0,-1)),f+l}),be=D(()=>qe.value+se.value);function K(s){const l=Object.fromEntries(s.filter(({active:f,key:E,value:T})=>f&&E&&T!==void 0).map(({key:f,value:E})=>[f,E]));return Object.entries(l).length?l:void 0}async function ke(){P.value=!0,F.value=!0;const s=Date.now(),l=J.value==="app"?y.value.app.$fetch:$fetch;pt("server-routes:fetch",{method:g.value,sendFrom:J.value});try{u.data=await l(be.value,{method:g.value.toUpperCase(),headers:ge.value,query:_e.value,body:de.value,onResponse({response:f}){u.contentType=(f.headers.get("content-type")||"").toString().toLowerCase().trim(),u.statusCode=f.status,u.error=void 0},onResponseError(f){u.error=f.response._data,u.data=f.response._data}})}catch{}F.value=!1,u.fetchTime=Date.now()-s}const we=D(()=>{const s=[],l=[],f=Object.entries(ge.value).filter(([T,M])=>T&&M&&!(T==="Content-Type"&&M==="application/json")).map(([T,M])=>` '${T}': '${M}'`).join(`,
2
+ `);g.value.toUpperCase()!=="GET"&&l.push(`method: '${g.value.toUpperCase()}'`),f&&l.push(`headers: {
3
+ ${f}
4
+ }`),de.value&&l.push(`body: ${JSON.stringify(de.value,null,2)}`);const E=l.length?`, {
5
+ ${l.join(`,
6
+ `).split(`
7
+ `).map(T=>` ${T}`).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=A(Be()),z=ve({key:"",value:""}),Me=D(()=>{const s=[];return N.value.length&&s.push({name:"Params",slug:"params",length:N.value.length}),s.push({name:"Query",slug:"query",length:k.query.length}),te.value&&s.push({name:"Body",slug:"body",length:k.body.length}),s.push({name:"Headers",slug:"headers",length:k.headers.length}),s.push({name:"Cookies",slug:"cookies",length:X.value.length}),s.push({name:"Snippets",slug:"snippet"}),s});function Be(){return document.cookie.split("; ").map(s=>{const[l,f]=s.split("=");return{key:l,value:f}}).filter(s=>s.key)}function pe(s,l){if(!s)return;const f=X.value.find(T=>T.key===s),E=Ut(s);f!==void 0?l===void 0&&(X.value=X.value.filter(T=>T.key!==s)):(X.value.push({key:s,value:l}),z.key="",z.value=""),E.value=l}lt(()=>{W.value==="json"&&typeof V.value=="string"&&(V.value=JSON.parse(V.value))});const fe=it("nuxt-devtools:server-routes:inputs",()=>[],{window:window.parent});ut([k,p],()=>{const s=fe.value?.find(l=>l.path===n.route.filepath);if(s){p.value||(p.value=s.tab),s.tab!==p.value&&(s.tab=p.value);const{body:l,query:f,headers:E,params:T}=s.inputs;Object.assign(k,{body:l,query:f,headers:E}),R.value=T}else{const l={path:n.route.filepath,tab:N.value.length?"params":"query",inputs:{...k,...N.value.length?{params:R.value}:{}}};fe.value.push(l),p.value||(p.value=l.tab)}},{immediate:!0,deep:!0,debounce:500});function Fe(){fe.value=[],k.body=[],k.query=[],k.headers=[],R.value={},p.value=N.value.length?"params":"query"}const He=ct();return(s,l)=>{const f=Ue,E=kt,T=ft,M=Ee,Ce=Le,ze=wt,Ge=Oe,Je=mt,me=Ne,We=Ct,Ke=xt,ae=Ie("tooltip");return i(),b("div",At,[c("div",Pt,[c("div",qt,[s.route.method?(i(),$(f,{key:0,class:B(["n-badge-base n-sm",("getRequestMethodClass"in s?s.getRequestMethodClass:e(ie))(e(g))]),"pointer-events-none":"","font-mono":"",tabindex:"-1"},{default:S(()=>[Q(U(e(g).toUpperCase()),1)]),_:1},8,["class"])):(i(),$(E,{key:1,modelValue:e(g),"onUpdate:modelValue":l[0]||(l[0]=r=>Z(g)?g.value=r:null),class:B(["n-badge-base n-sm",("getRequestMethodClass"in s?s.getRequestMethodClass:e(ie))(e(g))])},{default:S(()=>[(i(),b(L,null,G(ue,r=>c("option",{key:r,class:B(("getRequestMethodClass"in s?s.getRequestMethodClass:e(ie))(r))},U(r.toUpperCase()),3)),64))]),_:1},8,["modelValue","class"])),c("div",Mt,[v(T,{"model-value":e(se),readonly:"","flex-auto":"","font-mono":"",p:"x5 y2",n:"sm"},null,8,["model-value"]),c("div",Bt,[ee(v(f,{title:"Copy URL",n:"xs blue",icon:"carbon:copy",border:!1,onClick:l[1]||(l[1]=r=>e(He)(e(be),"server-route-url"))},null,512),[[ae,"Copy URL"]]),ee(v(f,{title:"Open in Editor",icon:"carbon-launch",n:"xs blue",border:!1,onClick:l[2]||(l[2]=r=>e(x)(s.route.filepath))},null,512),[[ae,"Open in Editor"]])])]),v(f,{"h-full":"",n:"primary solid",onClick:ke},{default:S(()=>[v(M,{icon:"carbon:send"})]),_:1})])]),c("div",Ft,[(i(!0),b(L,null,G(e(Me),r=>ee((i(),$(f,{key:r.slug,class:B(e(p)===r.slug?"text-primary n-primary":"border-transparent shadow-none"),onClick:Y=>p.value=r.slug},{default:S(()=>[v(M,{icon:("ServerRouteTabIcons"in s?s.ServerRouteTabIcons:e(Ae))[r.slug]},null,8,["icon"]),c("div",Ht,[Q(U(r.name)+" "+U(r?.length?`(${r.length})`:"")+" ",1),c("span",null,U(e(C)[r.slug]?.length?`(${e(C)[r.slug].length})`:""),1)])]),_:2},1032,["class","onClick"])),[[ae,r.name]])),128)),zt,Gt,v(E,{modelValue:e(J),"onUpdate:modelValue":l[3]||(l[3]=r=>Z(J)?J.value=r:null),class:"n-xs",disabled:!e(y)?.app?.$fetch},{default:S(()=>[Jt,Wt]),_:1},8,["modelValue","disabled"]),ee(v(f,{n:"orange",class:"p-3",icon:"i-carbon-clean",onClick:Fe},null,512),[[ae,"Clear Inputs Saved Cache"]])]),e(p)==="params"?(i(),b("div",Kt,[(i(!0),b(L,null,G(e(N),r=>(i(),b(L,{key:r},[c("div",Qt,U(r),1),v(T,{modelValue:e(R)[r],"onUpdate:modelValue":Y=>e(R)[r]=Y,placeholder:r,"flex-1":""},null,8,["modelValue","onUpdate:modelValue","placeholder"])],64))),128))])):O("",!0),e(p)==="cookies"?(i(),b("div",Xt,[(i(!0),b(L,null,G(e(X),r=>(i(),b("div",{key:r.key,flex:"~ gap-4 items-center"},[v(T,{placeholder:"Key...","model-value":r.key,disabled:"","op-70":""},null,8,["model-value"]),v(T,{placeholder:"Value...","model-value":r.value,"flex-1":"",n:"primary",onInput:Y=>pe(r.key,Y.target?.value)},null,8,["model-value","onInput"]),v(f,{title:"Delete",n:"red",onClick:Y=>pe(r.key,void 0)},{default:S(()=>[v(M,{icon:"i-carbon-trash-can"})]),_:2},1032,["onClick"])]))),128)),c("div",Yt,[v(T,{modelValue:e(z).key,"onUpdate:modelValue":l[4]||(l[4]=r=>e(z).key=r),placeholder:"Key",n:"primary","flex-1":""},null,8,["modelValue"]),v(T,{modelValue:e(z).value,"onUpdate:modelValue":l[5]||(l[5]=r=>e(z).value=r),placeholder:"Value",n:"primary","flex-1":""},null,8,["modelValue"]),v(f,{title:"Add",n:"primary",onClick:l[6]||(l[6]=r=>pe(e(z).key,e(z).value))},{default:S(()=>[v(M,{icon:"i-carbon-save"})]),_:1})])])):O("",!0),v(e(_),null,{default:S(()=>[v(Ce,{modelValue:e(ne),"onUpdate:modelValue":l[9]||(l[9]=r=>Z(ne)?ne.value=r:null),default:{active:!0,type:"string"},"max-h-xs":"","of-auto":""},{default:S(()=>[e(C)[e(p)]?.length?(i(),b(L,{key:0},[c("div",Zt,[eo,to,v(f,{icon:"i-carbon-edit",border:!1,onClick:l[7]||(l[7]=r=>o("open-default-input"))}),oo]),v(Ce,{modelValue:e(C)[e(p)],"onUpdate:modelValue":l[8]||(l[8]=r=>e(C)[e(p)]=r),disabled:"",p0:""},null,8,["modelValue"])],64)):O("",!0)]),_:1},8,["modelValue"])]),_:1}),e(p)==="snippet"?(i(),b("div",no,[e(we).length?(i(),$(ze,{key:0,"code-snippets":e(we)},null,8,["code-snippets"])):O("",!0)])):e(ne)?(i(),b("div",so,[e(p)==="body"?(i(),b(L,{key:0},[c("div",ao,[(i(),b(L,null,G(oe,r=>c("button",{key:r,px4:"",py2:"",border:"r base",hover:"bg-active",class:B({"border-b":r!==e(W)}),onClick:Y=>W.value=r},[c("div",{class:B({op30:r!==e(W)}),"font-mono":""},U(r),3)],10,ro)),64)),lo]),e(W)==="input"?(i(),$(e(m),{key:0})):e(W)==="json"?(i(),$(e(St),dt({key:1,modelValue:e(V),"onUpdate:modelValue":l[10]||(l[10]=r=>Z(V)?V.value=r:null),class:[e(d)==="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"])):O("",!0)],64)):(i(),$(e(m),{key:1}))])):O("",!0),e(P)?e(F)?(i(),$(Je,{key:5,"z-10":"","flex-auto":"","backdrop-blur":""},{default:S(()=>[Q(" Fetching... ")]),_:1})):(i(),b(L,{key:6},[c("div",io,[uo,e(u).error?(i(),$(me,{key:0,n:"red"},{default:S(()=>[Q(" Error ")]),_:1})):O("",!0),v(me,{n:e(u).error?"orange":"green",textContent:U(e(u).statusCode)},null,8,["n","textContent"]),e(u).contentType?(i(),b("code",co,U(e(u).contentType),1)):O("",!0),e(u).contentType==="application/json"?(i(),$(We,{key:2,getter:()=>({input:e(I)})},null,8,["getter"])):O("",!0),po,fo,v(me,{n:"green"},{default:S(()=>[Q(U(e(u).fetchTime)+" ms ",1)]),_:1})]),e(j)==="pdf"?(i(),b("div",mo,[c("div",vo,[c("object",{data:e(I),type:"application/pdf","flex-auto":"",width:"100%",height:"100%",rounded:""},null,8,ho)])])):e(j)!=="media"?(i(),$(Ke,{key:1,"flex-auto":"","overflow-auto":"","py-2":"",code:e(I),lang:e(j)},null,8,["code","lang"])):(i(),b("div",yo,[c("div",_o,[e(u).contentType.includes("image")?(i(),b("img",{key:0,rounded:"",src:e(I)},null,8,go)):(i(),b("video",bo,[c("source",{src:e(I),type:"video/mp4"},null,8,ko)]))])]))],64)):(i(),$(Ge,{key:4},{default:S(()=>[v(f,{n:"primary",onClick:ke},{default:S(()=>[v(M,{icon:"carbon:send"}),Q(" Send request ")]),_:1})]),_:1}))])}}}),Co={flex:"~ gap1","text-sm":""},xo={key:0,op50:""},So={op50:""},To=c("span",{op75:""},"Select a route to start",-1),$o=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),Fo=ye({__name:"server-routes",setup(t){const a=A(!1),n=vt(),o=Re(),{selectedRoute:_,view:m,inputDefaults:d}=Ve("serverRoutes"),h=D(()=>{!o.value&&_.value&&(o.value=_.value.filepath);const x=n.value?.find(w=>w.filepath===o.value);return o.value!==_.value?.filepath&&x&&(_.value=x),x}),y=A(""),u=D(()=>new ht(n.value||[],{keys:["method","route"],shouldSort:!0})),j=D(()=>n.value?y.value?u.value.search(y.value).map(w=>w.item):n.value:[]),I=D(()=>{const x=[],w=(g,R)=>{g.routes=g.routes||[],g.routes.push(R)},N=(g,R)=>{const k=R?R.routes?.find(C=>C.route===g):x.find(C=>C.route===g);if(k)return k;const V={route:g,filepath:g.replace(/\W/g,"-").toLowerCase(),type:"collection",routes:[]};return R?w(R,V):x.push(V),V};return j.value.forEach(g=>{let R,k;const V=g.filepath.split("/"),C=V.slice(V.indexOf("server")+1);if(g.type==="runtime"){C[0]="runtime";const H=V.indexOf("dist");H!==-1&&(R=V[H-1],R&&C.splice(1,0,R))}C.length>0&&C[C.length-1].includes(".")&&C.pop(),C.forEach(H=>{k=N(H,k)}),k?w(k,g):x.push(g)}),x});function F(){m.value=m.value==="tree"?"list":"tree"}function P(x){return x.charAt(0).toUpperCase()+x.slice(1)}return(x,w)=>{const N=Ue,g=bt,R=Pe,k=wo,V=gt,C=Oe,H=yt,J=Le,ue=Tt,ce=$t,te=Ie("tooltip");return i(),b(L,null,[v(H,{"storage-key":"tab-server-routes"},{left:S(()=>[v(g,{search:e(y),"onUpdate:search":w[1]||(w[1]=p=>Z(y)?y.value=p:null),pb2:""},{actions:S(()=>[ee(v(N,{"text-lg":"",icon:e(m)==="list"?"i-carbon-list":"i-carbon-tree-view-alt",title:"Toggle view",border:!1,onClick:F},null,8,["icon"]),[[te,"Toggle View"]]),ee(v(N,{"text-lg":"",icon:"i-carbon-cics-sit-overrides",title:"Default Inputs",border:!1,onClick:w[0]||(w[0]=p=>a.value=!e(a))},null,512),[[te,"Default Inputs"]])]),default:S(()=>[c("div",Co,[e(y)?(i(),b("span",xo,U(e(j).length)+" matched · ",1)):O("",!0),c("span",So,U(e(n)?.length)+" routes in total",1)])]),_:1},8,["search"]),(i(!0),b(L,null,G(e(m)==="tree"?e(I):e(j),p=>(i(),$(R,{key:p.filepath,item:p},null,8,["item"]))),128))]),right:S(()=>[(i(),$(_t,{max:10},[e(h)?(i(),$(k,{key:e(h).filepath,route:e(h),onOpenDefaultInput:w[2]||(w[2]=p=>a.value=!0)},null,8,["route"])):O("",!0)],1024)),e(h)?O("",!0):(i(),$(C,{key:0},{default:S(()=>[v(V,{px6:"",py2:""},{default:S(()=>[To]),_:1})]),_:1}))]),_:1}),v(ce,{modelValue:e(a),"onUpdate:modelValue":w[3]||(w[3]=p=>Z(a)?a.value=p:null),"auto-close":"","max-w-xl":"","min-w-xl":"",onClose:w[4]||(w[4]=p=>a.value=!1)},{default:S(()=>[c("div",null,[$o,(i(!0),b(L,null,G(Object.keys(e(d)),p=>(i(),$(ue,{key:p,text:`${P(p)} ${e(d)[p].length?`(${e(d)[p].length})`:""}`,padding:!1,icon:("ServerRouteTabIcons"in x?x.ServerRouteTabIcons:e(Ae))[p]},{default:S(()=>[v(J,{modelValue:e(d)[p],"onUpdate:modelValue":oe=>e(d)[p]=oe,py0:"",default:{active:!0,type:"string"}},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1032,["text","icon"]))),128))])]),_:1},8,["modelValue"])],64)}}});export{Fo as default};
@@ -1 +1 @@
1
- import{am as m,be as n,a as s,L as o}from"./ciodjZaS.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
+ import{am as m,be as n,a as s,L as o}from"./C_tLznPO.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 +1 @@
1
- import{q as n,o,m as s,aa as t}from"./ciodjZaS.js";const a={},c={class:"n-badge"};function _(e,r){return o(),s("span",c,[t(e.$slots,"default")])}const d=n(a,[["render",_]]);export{d as _};
1
+ import{q as n,o,m as s,aa as t}from"./C_tLznPO.js";const a={},c={class:"n-badge"};function _(e,r){return o(),s("span",c,[t(e.$slots,"default")])}const d=n(a,[["render",_]]);export{d as _};
@@ -1 +1 @@
1
- import{_ as w}from"./D4Ks82zD.js";import{_ as B}from"./BZvh3yot.js";import{o as c,m as _,k as s,d as S,r as h,b$ as j,c0 as P,aD as U,a as p,ah as E,i as l,j as u,F as f,U as G,f as i,l as I,n as R,t as v,G as W,h as z,at as A,A as H}from"./ciodjZaS.js";import{_ as L}from"./CLVHkiJk.js";import"./yFeWtr-M.js";const q={class:"markdown-body"},J=s("h1",null,"Virtual Files",-1),K=s("p",null,"Virtual files are generated on the fly to support the conventions of the framework, and to provide a better developer experience.",-1),M=[J,K],O={__name:"virtual-files",setup(x,{expose:o}){return o({frontmatter:{}}),(d,a)=>(c(),_("div",q,M))}},Q=O,T=["onClick"],X=s("div",{"x-divider":""},null,-1),Y={key:0,"h-full":"","of-hidden":"",flex:"~ col"},Z={border:"b base","flex-none":"",px4:"",py2:"","text-sm":"",op75:""},ee=s("span",{op75:""},"Select a file to start",-1),le=S({__name:"virtual-files",setup(x){const o=h(""),n=j(),d=P(),a=h();U(()=>{if(!d.value)return;const e=`/_vfs.json/${encodeURIComponent(d.value)}`;fetch(e,{headers:{accept:"application/json"}}).then(t=>t.json()).then(t=>a.value=t.current)});function k(e){if(n.value?.rootDir)return e.startsWith(n.value?.rootDir)?e.slice(n.value.rootDir.length):e}const m=p(()=>n.value?n.value.entries.filter(e=>!e.id.startsWith(`${n.value?.rootDir||""}/.nuxt/`)).sort((e,t)=>e.id.localeCompare(t.id)):[]),y=p(()=>new E(m.value,{keys:["id","path"]})),b=p(()=>o.value?y.value.search(o.value).map(e=>e.item):m.value);return(e,t)=>{const $=w,g=B,C=A,F=H,N=G,D=Q,V=L;return c(),_(f,null,[l(N,{class:"virtual-files","storage-key":"tab-virtual-files"},{left:u(()=>[l($,{search:i(o),"onUpdate:search":t[0]||(t[0]=r=>I(o)?o.value=r:null),"no-padding":"",p3:""},null,8,["search"]),(c(!0),_(f,null,R(i(b),r=>(c(),_(f,{key:r.id},[s("button",{block:"","w-full":"","select-none":"",truncate:"",px2:"",py1:"","text-start":"","text-sm":"","font-mono":"",class:W(r.id===i(a)?.id?"text-primary n-bg-active":"text-secondary hover:n-bg-hover"),onClick:te=>d.value=r.id},v(k(r.id)),11,T),X],64))),128))]),right:u(()=>[i(a)?.content?(c(),_("div",Y,[s("div",Z,[s("code",null,v(i(a).id),1)]),l(g,{"h-full":"","of-auto":"","text-sm":"",code:i(a).content,lang:"typescript"},null,8,["code"])])):(c(),z(F,{key:1},{default:u(()=>[l(C,{px6:"",py2:""},{default:u(()=>[ee]),_:1})]),_:1}))]),_:1}),l(V,null,{default:u(()=>[l(D)]),_:1})],64)}}});export{le as default};
1
+ import{_ as w}from"./BHh_UM9T.js";import{_ as B}from"./CIvuwNIv.js";import{o as c,m as _,k as s,d as S,r as h,b$ as j,c0 as P,aD as U,a as p,ah as E,i as l,j as u,F as f,U as G,f as i,l as I,n as R,t as v,G as W,h as z,at as A,A as H}from"./C_tLznPO.js";import{_ as L}from"./BOV_C5BD.js";import"./CO7Eo6nF.js";const q={class:"markdown-body"},J=s("h1",null,"Virtual Files",-1),K=s("p",null,"Virtual files are generated on the fly to support the conventions of the framework, and to provide a better developer experience.",-1),M=[J,K],O={__name:"virtual-files",setup(x,{expose:o}){return o({frontmatter:{}}),(d,a)=>(c(),_("div",q,M))}},Q=O,T=["onClick"],X=s("div",{"x-divider":""},null,-1),Y={key:0,"h-full":"","of-hidden":"",flex:"~ col"},Z={border:"b base","flex-none":"",px4:"",py2:"","text-sm":"",op75:""},ee=s("span",{op75:""},"Select a file to start",-1),le=S({__name:"virtual-files",setup(x){const o=h(""),n=j(),d=P(),a=h();U(()=>{if(!d.value)return;const e=`/_vfs.json/${encodeURIComponent(d.value)}`;fetch(e,{headers:{accept:"application/json"}}).then(t=>t.json()).then(t=>a.value=t.current)});function k(e){if(n.value?.rootDir)return e.startsWith(n.value?.rootDir)?e.slice(n.value.rootDir.length):e}const m=p(()=>n.value?n.value.entries.filter(e=>!e.id.startsWith(`${n.value?.rootDir||""}/.nuxt/`)).sort((e,t)=>e.id.localeCompare(t.id)):[]),y=p(()=>new E(m.value,{keys:["id","path"]})),b=p(()=>o.value?y.value.search(o.value).map(e=>e.item):m.value);return(e,t)=>{const $=w,g=B,C=A,F=H,N=G,D=Q,V=L;return c(),_(f,null,[l(N,{class:"virtual-files","storage-key":"tab-virtual-files"},{left:u(()=>[l($,{search:i(o),"onUpdate:search":t[0]||(t[0]=r=>I(o)?o.value=r:null),"no-padding":"",p3:""},null,8,["search"]),(c(!0),_(f,null,R(i(b),r=>(c(),_(f,{key:r.id},[s("button",{block:"","w-full":"","select-none":"",truncate:"",px2:"",py1:"","text-start":"","text-sm":"","font-mono":"",class:W(r.id===i(a)?.id?"text-primary n-bg-active":"text-secondary hover:n-bg-hover"),onClick:te=>d.value=r.id},v(k(r.id)),11,T),X],64))),128))]),right:u(()=>[i(a)?.content?(c(),_("div",Y,[s("div",Z,[s("code",null,v(i(a).id),1)]),l(g,{"h-full":"","of-auto":"","text-sm":"",code:i(a).content,lang:"typescript"},null,8,["code"])])):(c(),z(F,{key:1},{default:u(()=>[l(C,{px6:"",py2:""},{default:u(()=>[ee]),_:1})]),_:1}))]),_:1}),l(V,null,{default:u(()=>[l(D)]),_:1})],64)}}});export{le as default};
@@ -1 +1 @@
1
- import{d as P,a as I,r as V,o,m as s,k as e,F as _,n as j,G as S,f as t,t as p,p as b,H as U,i as u,j as r,v as f,I as A,J as D,K as X,L as F,M as E,_ as G,N as q,O as ee,P as ne,Q as te,R as oe,S as le,U as ie,V as se,W as C,h as z,l as R,X as ae,Y as re,Z as ue,A as de}from"./ciodjZaS.js";import{_ as ce}from"./zjxoDR5L.js";import{_ as me}from"./BZvh3yot.js";import{_ as _e}from"./BWPbreBU.js";import{_ as pe}from"./CLVHkiJk.js";import"./yFeWtr-M.js";const fe={"h-full":"",grid:"~ rows-[max-content_1fr]"},ve={flex:"~ wrap","w-full":""},he=["onClick"],ye=e("div",{border:"b base","flex-auto":""},null,-1),be={key:0,flex:"~ col gap-4 items-center justify-center",p4:""},$e=e("div",{"flex-auto":""},null,-1),xe={grid:"~ cols-[30px_1fr] gap-x-2 gap-y-3 items-center justify-center","w-100":""},ge=e("div",{"i-carbon-commit":"","text-xl":""},null,-1),we=e("div",{"text-sm":"",op50:""}," Name ",-1),ze=e("div",{"i-carbon-time":"","text-xl":""},null,-1),Be=e("div",{"text-sm":"",op50:""}," Build duration ",-1),Ce=e("div",{"i-carbon-cics-program":"","text-xl":""},null,-1),ke=e("div",{"text-sm":"",op50:""}," Client bundle size ",-1),Ne=e("div",{"i-carbon-bare-metal-server":"","text-xl":""},null,-1),Te=e("div",{"text-sm":"",op50:""}," Nitro bundle size ",-1),Ae=e("div",{"i-carbon-edge-node":"","text-xl":""},null,-1),De=e("div",{"text-sm":"",op50:""}," Built ",-1),Ie=e("div",{"i-carbon:folder-parent":"","text-xl":""},null,-1),Ve=e("div",{"text-sm":"",op50:""}," Report Path ",-1),Se=e("div",{"flex-auto":""},null,-1),Fe=P({__name:"BuildAnalyzeDetails",props:{current:{},prev:{}},setup(k){const v=k,x=`${X().app.baseURL}/__nuxt_devtools__/analyze/`.replace(/\/+/g,"/"),g=I(()=>{const n=[{name:"Overview",id:"overview"}];return v.current.features.bundleClient&&n.push({name:"Client Bundle",id:"bundle-client"}),v.current.features.bundleNitro&&n.push({name:"Nitro Bundle",id:"bundle-nitro"}),v.current.features.viteInspect&&n.push({name:"Vite Inspect",id:"vite-inspect"}),n}),i=V(g.value[0]);function h(n){return n<1024?`${n}B`:n<1024*1024?`${(n/1024).toFixed(1)}KB`:n<1024*1024*1024?`${(n/1024/1024).toFixed(1)}MB`:`${(n/1024/1024/1024).toFixed(1)}GB`}function d(n){return`${((n.endTime-n.startTime)/1e3).toFixed(1)}s`}async function N(n){return F.clearAnalyzeBuilds(await E(),[n])}return(n,c)=>{const B=ce,T=G;return o(),s("div",fe,[e("div",ve,[(o(!0),s(_,null,j(t(g),(l,m)=>(o(),s("button",{key:m,px4:"",py2:"",border:"r base",hover:"bg-active",class:S(l.id===t(i).id?"":"border-b"),onClick:w=>i.value=l},[e("div",{class:S(l.id===t(i).id?"":"op30")},p(l.name),3)],10,he))),128)),ye]),t(i).id==="overview"?(o(),s("div",be,[$e,e("div",xe,[ge,e("div",null,[we,e("div",null,p(n.current.name),1)]),ze,e("div",null,[Be,e("div",null,p(d(n.current)),1)]),n.current.size?.clientBundle?(o(),s(_,{key:0},[Ce,e("div",null,[ke,e("div",null,p(h(n.current.size.clientBundle)),1)])],64)):b("",!0),n.current.size.nitroBundle?(o(),s(_,{key:1},[Ne,e("div",null,[Te,e("div",null,p(h(n.current.size.nitroBundle)),1)])],64)):b("",!0),Ae,e("div",null,[De,e("div",null,p(t(U)(new Date(n.current.endTime))),1)]),Ie,e("div",null,[Ve,u(B,{filepath:n.current.analyzeDir},null,8,["filepath"])])]),Se,u(T,{n:"rose",icon:"carbon-delete",onClick:c[0]||(c[0]=l=>N(n.current.name))},{default:r(()=>[f(" Delete this report ")]),_:1})])):b("",!0),c._lazyshow1||t(i).id==="bundle-client"?(c._lazyshow1=!0,o(),s(_,null,[A(e("iframe",{src:`${t(x)}${n.current.slug}/client.html`,"h-full":"","w-full":""},null,8,["src"]),[[D,t(i).id==="bundle-client"]])],64)):b("v-show-if",!0),c._lazyshow2||t(i).id==="bundle-nitro"?(c._lazyshow2=!0,o(),s(_,null,[A(e("iframe",{src:`${t(x)}${n.current.slug}/nitro.html`,"h-full":"","w-full":""},null,8,["src"]),[[D,t(i).id==="bundle-nitro"]])],64)):b("v-show-if",!0),c._lazyshow3||t(i).id==="vite-inspect"?(c._lazyshow3=!0,o(),s(_,null,[A(e("iframe",{src:`${t(x)}${n.current.slug}/.vite-inspect/`,"h-full":"","w-full":""},null,8,["src"]),[[D,t(i).id==="vite-inspect"]])],64)):b("v-show-if",!0)])}}}),Re={class:"markdown-body"},Pe=e("h1",null,"Build Analyze",-1),je=e("p",null,[f("DevTools provides a build analyze tool to help you understand the size of your app in production. Whenever you start a new build, it runs the command "),e("code",null,"nuxt build --analyze"),f(" and present the output data directly in DevTools for easy browsing and comparing.")],-1),Ue=[Pe,je],Ee={__name:"analyze-build",setup(k,{expose:v}){return v({frontmatter:{}}),(x,g)=>(o(),s("div",Re,Ue))}},Ge=Ee,Le={flex:"~ col"},Oe=["onClick"],He={flex:"~ gap-1 items-center wrap","w-full":"","text-sm":"",op60:""},Ke=e("div",{"i-carbon-time":""},null,-1),Me=e("div",{"flex-auto":""},null,-1),We=e("div",{"x-divider":""},null,-1),Ye={flex:"~ items-center justify-center wrap",p4:""},Ze={flex:"~ col gap-1","w-250":"",p4:""},Je=e("h3",{class:"text-lg font-medium leading-6",mb2:""}," Start analyze build? ",-1),Qe=e("p",{op50:""}," Enter the name of the build: ",-1),Xe=e("div",{my3:"","x-divider":""},null,-1),qe=e("p",{op50:""}," The following command will be executed in your terminal: ",-1),en={flex:"~ gap-3",mt2:"","justify-end":""},rn=P({__name:"analyze-build",setup(k){const v=q(),$=ee(),x=ne(),g=te("analyze-build:slug",""),i=I(()=>$.value?.builds.find(l=>l.slug===g.value)??$.value?.builds[0]),h=V(!1),d=V(""),N=I(()=>$.value?.builds.some(l=>l.name===d.value.trim()));async function n(){d.value=await F.generateAnalyzeBuildName(),await v.start()&&(se("analyze-build:start"),C.value={name:d.value,processId:await F.startAnalyzeBuild(await E(),d.value)},h.value&&B())}const c=oe();function B(){C.value?.processId&&(c.value=C.value.processId,x.push("/modules/terminals"))}function T(l){return`${((l.endTime-l.startTime)/1e3).toFixed(1)}s`}return le(()=>[{id:"action:analyze-build: start",title:"Start a new analyze build",icon:"i-carbon-edge-node",action:n}]),(l,m)=>{const w=G,L=Fe,O=de,H=ie,K=ae,M=re,W=me,Y=_e,Z=ue,J=Ge,Q=pe;return o(),s(_,null,[u(H,{"left-size":30},{left:r(()=>[e("div",Le,[(o(!0),s(_,null,j(t($)?.builds,a=>(o(),s(_,{key:a.slug},[e("button",{flex:"~ col gap1","hover:bg-active":"",p3:"",class:S(a.slug===t(i)?.slug?"text-primary bg-active":""),onClick:y=>g.value=a.slug},[e("code",null,p(a.name),1),e("div",He,[Ke,e("span",null,p(T(a)),1),Me,e("span",null,p(t(U)(new Date(a.endTime))),1)])],10,Oe),We],64))),128)),e("div",Ye,[("processAnalyzeBuildInfo"in l?l.processAnalyzeBuildInfo:t(C))?(o(),z(w,{key:1,n:"primary",icon:"carbon-circle-dash animate-spin",onClick:m[1]||(m[1]=a=>B())},{default:r(()=>[f(" Building... ")]),_:1})):(o(),z(w,{key:0,n:"primary",icon:"carbon-edge-node",onClick:m[0]||(m[0]=a=>n())},{default:r(()=>[f(" Start a new build ")]),_:1}))])])]),right:r(()=>[t(i)?(o(),z(L,{key:0,current:t(i)},null,8,["current"])):(o(),z(O,{key:1}))]),_:1}),u(t(v),null,{default:r(({resolve:a})=>[u(Z,{"model-value":!0,onClose:y=>a(!1)},{default:r(()=>[e("div",Ze,[Je,Qe,u(K,{modelValue:t(d),"onUpdate:modelValue":m[2]||(m[2]=y=>R(d)?d.value=y:null),placeholder:"Build name"},null,8,["modelValue"]),t(N)?(o(),z(M,{key:0,"n-orange":""},{default:r(()=>[f(" A build with the same name already exists, continue would overrides the previous build result. ")]),_:1})):b("",!0),Xe,qe,u(W,{code:`npx nuxi analyze --no-serve --name=${t(d)}`,lang:"bash",px4:"",py2:"",border:"~ base rounded",lines:!1},null,8,["code"]),u(Y,{modelValue:t(h),"onUpdate:modelValue":m[3]||(m[3]=y=>R(h)?h.value=y:null),mt2:"",n:"primary"},{default:r(()=>[f(" Navigate to terminal ")]),_:1},8,["modelValue"]),e("div",en,[u(w,{onClick:y=>a(!1)},{default:r(()=>[f(" Cancel ")]),_:2},1032,["onClick"]),u(w,{n:"solid primary",onClick:y=>a(!0)},{default:r(()=>[f(" Start ")]),_:2},1032,["onClick"])])])]),_:2},1032,["onClose"])]),_:1}),u(Q,null,{default:r(()=>[u(J)]),_:1})],64)}}});export{rn as default};
1
+ import{d as P,a as I,r as V,o,m as s,k as e,F as _,n as j,G as S,f as t,t as p,p as b,H as U,i as u,j as r,v as f,I as A,J as D,K as X,L as F,M as E,_ as G,N as q,O as ee,P as ne,Q as te,R as oe,S as le,U as ie,V as se,W as C,h as z,l as R,X as ae,Y as re,Z as ue,A as de}from"./C_tLznPO.js";import{_ as ce}from"./BI3hykgO.js";import{_ as me}from"./CIvuwNIv.js";import{_ as _e}from"./BKeomq25.js";import{_ as pe}from"./BOV_C5BD.js";import"./CO7Eo6nF.js";const fe={"h-full":"",grid:"~ rows-[max-content_1fr]"},ve={flex:"~ wrap","w-full":""},he=["onClick"],ye=e("div",{border:"b base","flex-auto":""},null,-1),be={key:0,flex:"~ col gap-4 items-center justify-center",p4:""},$e=e("div",{"flex-auto":""},null,-1),xe={grid:"~ cols-[30px_1fr] gap-x-2 gap-y-3 items-center justify-center","w-100":""},ge=e("div",{"i-carbon-commit":"","text-xl":""},null,-1),we=e("div",{"text-sm":"",op50:""}," Name ",-1),ze=e("div",{"i-carbon-time":"","text-xl":""},null,-1),Be=e("div",{"text-sm":"",op50:""}," Build duration ",-1),Ce=e("div",{"i-carbon-cics-program":"","text-xl":""},null,-1),ke=e("div",{"text-sm":"",op50:""}," Client bundle size ",-1),Ne=e("div",{"i-carbon-bare-metal-server":"","text-xl":""},null,-1),Te=e("div",{"text-sm":"",op50:""}," Nitro bundle size ",-1),Ae=e("div",{"i-carbon-edge-node":"","text-xl":""},null,-1),De=e("div",{"text-sm":"",op50:""}," Built ",-1),Ie=e("div",{"i-carbon:folder-parent":"","text-xl":""},null,-1),Ve=e("div",{"text-sm":"",op50:""}," Report Path ",-1),Se=e("div",{"flex-auto":""},null,-1),Fe=P({__name:"BuildAnalyzeDetails",props:{current:{},prev:{}},setup(k){const v=k,x=`${X().app.baseURL}/__nuxt_devtools__/analyze/`.replace(/\/+/g,"/"),g=I(()=>{const n=[{name:"Overview",id:"overview"}];return v.current.features.bundleClient&&n.push({name:"Client Bundle",id:"bundle-client"}),v.current.features.bundleNitro&&n.push({name:"Nitro Bundle",id:"bundle-nitro"}),v.current.features.viteInspect&&n.push({name:"Vite Inspect",id:"vite-inspect"}),n}),i=V(g.value[0]);function h(n){return n<1024?`${n}B`:n<1024*1024?`${(n/1024).toFixed(1)}KB`:n<1024*1024*1024?`${(n/1024/1024).toFixed(1)}MB`:`${(n/1024/1024/1024).toFixed(1)}GB`}function d(n){return`${((n.endTime-n.startTime)/1e3).toFixed(1)}s`}async function N(n){return F.clearAnalyzeBuilds(await E(),[n])}return(n,c)=>{const B=ce,T=G;return o(),s("div",fe,[e("div",ve,[(o(!0),s(_,null,j(t(g),(l,m)=>(o(),s("button",{key:m,px4:"",py2:"",border:"r base",hover:"bg-active",class:S(l.id===t(i).id?"":"border-b"),onClick:w=>i.value=l},[e("div",{class:S(l.id===t(i).id?"":"op30")},p(l.name),3)],10,he))),128)),ye]),t(i).id==="overview"?(o(),s("div",be,[$e,e("div",xe,[ge,e("div",null,[we,e("div",null,p(n.current.name),1)]),ze,e("div",null,[Be,e("div",null,p(d(n.current)),1)]),n.current.size?.clientBundle?(o(),s(_,{key:0},[Ce,e("div",null,[ke,e("div",null,p(h(n.current.size.clientBundle)),1)])],64)):b("",!0),n.current.size.nitroBundle?(o(),s(_,{key:1},[Ne,e("div",null,[Te,e("div",null,p(h(n.current.size.nitroBundle)),1)])],64)):b("",!0),Ae,e("div",null,[De,e("div",null,p(t(U)(new Date(n.current.endTime))),1)]),Ie,e("div",null,[Ve,u(B,{filepath:n.current.analyzeDir},null,8,["filepath"])])]),Se,u(T,{n:"rose",icon:"carbon-delete",onClick:c[0]||(c[0]=l=>N(n.current.name))},{default:r(()=>[f(" Delete this report ")]),_:1})])):b("",!0),c._lazyshow1||t(i).id==="bundle-client"?(c._lazyshow1=!0,o(),s(_,null,[A(e("iframe",{src:`${t(x)}${n.current.slug}/client.html`,"h-full":"","w-full":""},null,8,["src"]),[[D,t(i).id==="bundle-client"]])],64)):b("v-show-if",!0),c._lazyshow2||t(i).id==="bundle-nitro"?(c._lazyshow2=!0,o(),s(_,null,[A(e("iframe",{src:`${t(x)}${n.current.slug}/nitro.html`,"h-full":"","w-full":""},null,8,["src"]),[[D,t(i).id==="bundle-nitro"]])],64)):b("v-show-if",!0),c._lazyshow3||t(i).id==="vite-inspect"?(c._lazyshow3=!0,o(),s(_,null,[A(e("iframe",{src:`${t(x)}${n.current.slug}/.vite-inspect/`,"h-full":"","w-full":""},null,8,["src"]),[[D,t(i).id==="vite-inspect"]])],64)):b("v-show-if",!0)])}}}),Re={class:"markdown-body"},Pe=e("h1",null,"Build Analyze",-1),je=e("p",null,[f("DevTools provides a build analyze tool to help you understand the size of your app in production. Whenever you start a new build, it runs the command "),e("code",null,"nuxt build --analyze"),f(" and present the output data directly in DevTools for easy browsing and comparing.")],-1),Ue=[Pe,je],Ee={__name:"analyze-build",setup(k,{expose:v}){return v({frontmatter:{}}),(x,g)=>(o(),s("div",Re,Ue))}},Ge=Ee,Le={flex:"~ col"},Oe=["onClick"],He={flex:"~ gap-1 items-center wrap","w-full":"","text-sm":"",op60:""},Ke=e("div",{"i-carbon-time":""},null,-1),Me=e("div",{"flex-auto":""},null,-1),We=e("div",{"x-divider":""},null,-1),Ye={flex:"~ items-center justify-center wrap",p4:""},Ze={flex:"~ col gap-1","w-250":"",p4:""},Je=e("h3",{class:"text-lg font-medium leading-6",mb2:""}," Start analyze build? ",-1),Qe=e("p",{op50:""}," Enter the name of the build: ",-1),Xe=e("div",{my3:"","x-divider":""},null,-1),qe=e("p",{op50:""}," The following command will be executed in your terminal: ",-1),en={flex:"~ gap-3",mt2:"","justify-end":""},rn=P({__name:"analyze-build",setup(k){const v=q(),$=ee(),x=ne(),g=te("analyze-build:slug",""),i=I(()=>$.value?.builds.find(l=>l.slug===g.value)??$.value?.builds[0]),h=V(!1),d=V(""),N=I(()=>$.value?.builds.some(l=>l.name===d.value.trim()));async function n(){d.value=await F.generateAnalyzeBuildName(),await v.start()&&(se("analyze-build:start"),C.value={name:d.value,processId:await F.startAnalyzeBuild(await E(),d.value)},h.value&&B())}const c=oe();function B(){C.value?.processId&&(c.value=C.value.processId,x.push("/modules/terminals"))}function T(l){return`${((l.endTime-l.startTime)/1e3).toFixed(1)}s`}return le(()=>[{id:"action:analyze-build: start",title:"Start a new analyze build",icon:"i-carbon-edge-node",action:n}]),(l,m)=>{const w=G,L=Fe,O=de,H=ie,K=ae,M=re,W=me,Y=_e,Z=ue,J=Ge,Q=pe;return o(),s(_,null,[u(H,{"left-size":30},{left:r(()=>[e("div",Le,[(o(!0),s(_,null,j(t($)?.builds,a=>(o(),s(_,{key:a.slug},[e("button",{flex:"~ col gap1","hover:bg-active":"",p3:"",class:S(a.slug===t(i)?.slug?"text-primary bg-active":""),onClick:y=>g.value=a.slug},[e("code",null,p(a.name),1),e("div",He,[Ke,e("span",null,p(T(a)),1),Me,e("span",null,p(t(U)(new Date(a.endTime))),1)])],10,Oe),We],64))),128)),e("div",Ye,[("processAnalyzeBuildInfo"in l?l.processAnalyzeBuildInfo:t(C))?(o(),z(w,{key:1,n:"primary",icon:"carbon-circle-dash animate-spin",onClick:m[1]||(m[1]=a=>B())},{default:r(()=>[f(" Building... ")]),_:1})):(o(),z(w,{key:0,n:"primary",icon:"carbon-edge-node",onClick:m[0]||(m[0]=a=>n())},{default:r(()=>[f(" Start a new build ")]),_:1}))])])]),right:r(()=>[t(i)?(o(),z(L,{key:0,current:t(i)},null,8,["current"])):(o(),z(O,{key:1}))]),_:1}),u(t(v),null,{default:r(({resolve:a})=>[u(Z,{"model-value":!0,onClose:y=>a(!1)},{default:r(()=>[e("div",Ze,[Je,Qe,u(K,{modelValue:t(d),"onUpdate:modelValue":m[2]||(m[2]=y=>R(d)?d.value=y:null),placeholder:"Build name"},null,8,["modelValue"]),t(N)?(o(),z(M,{key:0,"n-orange":""},{default:r(()=>[f(" A build with the same name already exists, continue would overrides the previous build result. ")]),_:1})):b("",!0),Xe,qe,u(W,{code:`npx nuxi analyze --no-serve --name=${t(d)}`,lang:"bash",px4:"",py2:"",border:"~ base rounded",lines:!1},null,8,["code"]),u(Y,{modelValue:t(h),"onUpdate:modelValue":m[3]||(m[3]=y=>R(h)?h.value=y:null),mt2:"",n:"primary"},{default:r(()=>[f(" Navigate to terminal ")]),_:1},8,["modelValue"]),e("div",en,[u(w,{onClick:y=>a(!1)},{default:r(()=>[f(" Cancel ")]),_:2},1032,["onClick"]),u(w,{n:"solid primary",onClick:y=>a(!0)},{default:r(()=>[f(" Start ")]),_:2},1032,["onClick"])])])]),_:2},1032,["onClose"])]),_:1}),u(Q,null,{default:r(()=>[u(J)]),_:1})],64)}}});export{rn as default};
@@ -1,4 +1,4 @@
1
- import{d as B,a as w,aL as M,o as n,m as r,k as t,a9 as T,f as l,t as k,ad as O,F as f,n as E,h as y,r as C,w as Y,aC as q,a1 as j,bW as U,p as x,i as m,G as z,q as X,ao as Z,e as K,au as P,j as v,ay as Q,v as F,_ as G,aN as ee,am as se,b3 as te,bX as ne,ab as oe,N as ae,ac as le,A as ie,L as R,a5 as re,Z as ce}from"./ciodjZaS.js";import{_ as V}from"./CxLTb5RC.js";import{_ as H}from"./Bi99gj7u.js";import{_ as pe}from"./rLudNEh9.js";import{e as de}from"./BMUgLter.js";import{_ as ue}from"./2tJW9cKr.js";import{_ as me}from"./DKlNNSWk.js";import{_ as ke}from"./CnW1WPg6.js";import{_ as he}from"./CE84j0J9.js";import{_ as _e}from"./DYx1ZwvQ.js";import{_ as fe}from"./CLVHkiJk.js";import"./DwVKZd3-.js";import"./yFeWtr-M.js";import"./zjxoDR5L.js";import"./BcJws1i5.js";import"./BZvh3yot.js";const ye=B({__name:"TimelineItemFunction",props:{item:{}},setup(_){const p=_,c=w(()=>M(p.item.name,50,60,"_op_")),e=w(()=>c.value.replace(/_op_/,"1")),a=w(()=>M(p.item.name,50,40)),i=w(()=>c.value.replace(/_op_/,"0.2"));return(o,d)=>(n(),r("button",{class:"group",style:T({color:l(e),borderLeft:`2px solid ${l(e)}`}),relative:"","text-sm":"",transition:"","hover:z-1000":"","bg-base":""},[t("div",{style:T({backgroundColor:l(i)}),absolute:"","bottom-0":"","left--1px":"","top-0":"","w-full":"","text-sm":"","transition-all":"","duration-300":""},null,4),t("div",{style:T({color:l(a),"--c":l(e)}),border:"r-2 t-2 y-2 transparent","min-w-max":"",px1:"","text-left":"","group-hover":"border-$c"},k(o.item.name),5)],4))}}),ve={relative:"","h-full":""},be={absolute:"","left-2":"","top-2.3em":"","text-xs":"",op50:""},ge=B({__name:"TimelineSegment",props:{segment:{}},emits:["select"],setup(_,{emit:p}){const c=_,e=p,a=O(()=>c.segment.start,{updateInterval:1e3,showSecond:!0,controls:!1,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,o)=>{const d=ye;return n(),r("div",ve,[t("button",{absolute:"","left-0":"","right-0":"","top-0":"","bg-green:5":"",px2:"",py1:"","text-left":"","text-xs":"","text-green6":"","font-mono":"",onClick:o[0]||(o[0]=s=>i.segment.route?e("select",i.segment.route):void 0)},k(i.segment.route?.event.to),1),t("div",be,k(l(a))+" ago ",1),t("div",null,[(n(!0),r(f,null,E(i.segment.functions,(s,u)=>(n(),y(d,{key:u,item:s.event,style:T({position:"absolute",minWidth:`${s.relativeWidth*100}%`,maxWidth:`${s.relativeWidth*100}%`,top:`${4+s.layer*1.6}em`,left:`${s.relativeStart*100}%`}),onClick:h=>e("select",s)},null,8,["item","style","onClick"]))),128))])])}}}),xe=3e3,$e=50;function Ae(_){const p=[];let c={start:0,end:0,events:[],functions:[],duration:0};for(const e of _){const a=e.end||e.start;(e.start-c.end>xe||e.type==="route")&&(c={start:e.start,end:a,events:[],functions:[],duration:0},p.push(c)),c.events.push(e),c.end=a+$e}return p.forEach((e,a)=>{const i=e.end-e.start,o=[];e.duration=i,e.previousGap=a>0?e.start-p[a-1].end:0,e.events.forEach(d=>{const s=d.end||d.start;let u=0;d.type!=="route"&&(u=o.findIndex($=>$<=d.start),u===-1?(u=o.length,o.push(s+1e3)):o[u]=s+1e3);const h={event:d,segment:e,relativeStart:(d.start-e.start)/i,relativeWidth:(s-d.start)/i,layer:u};d.type==="function"?e.functions.push(h):e.route=h})}),p}const De={relative:""},Ce={key:0,border:"x base","h-full":"","flex-inline":"","bg-true-gray-1":"",py15:"","text-xs":"","write-vertical-left":"",op50:"","dark:bg-true-gray-9":""},Be=B({__name:"TimelineTable",props:{data:{}},emits:["select"],setup(_,{emit:p}){const c=_,e=p,a=C(),i=C(),o=C(),d=C(),s=C(!0),u=C(1.5),h=w(()=>Ae(c.data.events)),$=w(()=>(c.data.events.length,a.value?.scrollWidth||window.innerWidth));function A(){d.value&&(d.value.style.width=`${$.value}px`)}function S(){s.value&&a.value&&(a.value.scrollTo({left:a.value.scrollWidth-a.value.clientWidth,behavior:"smooth"}),o.value.scrollTo({left:a.value.scrollWidth-a.value.clientWidth,behavior:"smooth"}))}return Y(()=>c.data.events.length,async()=>{await q(),A(),S()},{flush:"post"}),j(a,"scroll",()=>{o.value.scrollLeft!==a.value.scrollLeft&&(A(),o.value.scrollLeft=a.value.scrollLeft,s.value=a.value.scrollLeft>=a.value.scrollWidth-a.value.clientWidth)}),j(o,"scroll",()=>{o.value.scrollLeft!==a.value.scrollLeft&&(A(),a.value.scrollLeft=o.value.scrollLeft)}),j(a,"wheel",b=>{b.altKey?(u.value=U(u.value+b.deltaY/200,.5,3),A()):a.value.scrollLeft+=b.deltaY}),(b,L)=>{const D=V,W=ge;return n(),r(f,null,[t("div",De,[t("div",{ref_key:"minimap",ref:i,border:"t b base",relative:"","h-50px":"","ws-nowrap":"","border-base":""},[(n(!0),r(f,null,E(l(h),(g,N)=>(n(),r("div",{key:N,relative:"","h-full":"","flex-inline":"",style:T({width:`${Math.max(100,g.duration/10)/l($)*100}%`})},[(n(!0),r(f,null,E(g.functions,(I,J)=>(n(),r("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(M))(I.event.name,50,60)})},null,4))),128)),g.route?(n(),r("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),t("div",{ref_key:"minimapScroller",ref:o,class:"timeline-scroller",absolute:"","inset-0":"","h-full":"","w-full":"","of-x-scroll":""},[t("div",{ref_key:"minimapScrollerInner",ref:d,"h-1px":""},null,512)],512)]),t("div",{ref_key:"scroller",ref:a,relative:"","h-full":"","w-full":"","of-x-scroll":"","of-y-hidden":"","ws-nowrap":"","n-panel-grids":""},[(n(!0),r(f,null,E(l(h),(g,N)=>(n(),r(f,{key:N},[g.previousGap&&g.previousGap>=200?(n(),r("div",Ce,[m(D,{op50:"",duration:g.previousGap,color:!1},null,8,["duration"])])):x("",!0),m(W,{"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)}}}),we=X(Be,[["__scopeId","data-v-357f5ced"]]),Te={border:"t base",flex:"~ col","h-full":"","of-y-auto":"","text-sm":""},Se=["onClick"],Ne=t("div",{"i-carbon-function":"",op50:""},null,-1),Fe={flex:"~","ml--1":"","font-mono":""},Ee=t("div",{op30:""}," ( ",-1),Le={key:0,mr2:"",op30:""},Ie={op75:""},We=t("div",{op30:""}," ) ",-1),Me=t("div",{"mr-1":"","h-7":"","w-7":"",flex:"","rounded-lg":"","bg-primary:5":"",p1:"","text-green6":""},[t("div",{"i-carbon-direction-rotary-right":"",ma:"","text-lg":""})],-1),Ve={flex:"~ col items-start"},je={"text-xs":"","font-mono":"",op30:""},Oe={"text-green":"","font-bold":"","font-mono":""},ze=t("div",{"flex-auto":""},null,-1),Ge=t("div",{"min-h-100":""},null,-1),Re=B({__name:"TimelineList",props:{data:{}},emits:["select"],setup(_,{emit:p}){const c=p;return(e,a)=>{const i=V;return n(),r("div",Te,[(n(!0),r(f,null,E(e.data.events,(o,d)=>(n(),r("button",{key:d,border:"b base",px3:"",py2:"",flex:"~ items-center gap-2",hover:"bg-active",onClick:s=>c("select",o)},[o.type==="function"?(n(),r(f,{key:0},[Ne,t("div",{"font-mono":"",style:T({color:o.type==="function"?("getHashColorFromString"in e?e.getHashColorFromString:l(M))(o.name,50,60):""})},k(o.name),5),t("div",Fe,[Ee,(n(!0),r(f,null,E(o.args,(s,u)=>(n(),r(f,{key:u},[u?(n(),r("div",Le," , ")):x("",!0),t("div",Ie,k(s===null?"null":s===void 0?"undefined":typeof s=="function"?"[function]":Array.isArray(s)?"[Array]":typeof s=="object"?"[object]":JSON.stringify(s)),1)],64))),128)),We])],64)):(n(),r(f,{key:1},[Me,t("div",Ve,[t("div",je,k(o.from),1),t("div",Oe,k(o.to),1)])],64)),ze,o.end?(n(),y(i,{key:2,duration:o.end-o.start,color:o.type==="function"},null,8,["duration","color"])):x("",!0)],8,Se))),128)),Ge])}}}),Pe={key:0,"text-blue":""},He={key:1,"text-purple":""},Je={key:2,"text-green":""},Ye={key:3,"text-gray":""},qe={key:4,"text-gray":""},Ue={key:5,"text-gray":""},Xe={key:0,"bg-red:10":"",px2:"",py1:"","text-red":""},Ze={key:1},Ke={p2:"","text-sm":"",border:"t base"},Qe=B({__name:"TimelineArgumentView",props:{value:{}},setup(_){const p=_,c=C(),e=C();function a(){try{c.value=JSON.parse(JSON.stringify(p.value))}catch(s){console.error(s),e.value=s}}const i=B({emits:["setup"],setup(s,{emit:u}){return u("setup"),()=>null}}),o=Z(),d=K();return(s,u)=>{const h=G,$=P("VMenu");return typeof s.value=="string"?(n(),r("div",Pe,k(JSON.stringify(s.value)),1)):typeof s.value=="number"?(n(),r("div",He,k(s.value),1)):typeof s.value=="boolean"?(n(),r("div",Je,k(s.value),1)):typeof s.value>"u"?(n(),r("div",Ye," undefined ")):typeof s.value=="function"?(n(),r("div",qe," [Function"+k(s.value.name?`: ${s.value.name}`:"")+"] ",1)):s.value===null?(n(),r("div",Ue," null ")):(n(),y($,{key:6,placement:"top"},{popper:v(()=>[m(l(i),{onSetup:a}),l(e)?(n(),r("div",Xe," Failed to display object: "+k(l(e)),1)):l(c)?(n(),r("div",Ze,[m(l(de),Q({"model-value":l(c)},s.$attrs,{class:["json-editor-vue",[l(o)==="dark"?"jse-theme-dark":""]],"main-menu-bar":!1,"navigation-bar":!1,"status-bar":!1,"read-only":!0,indentation:2,"tab-size":2}),null,16,["model-value","class"]),t("div",Ke,[m(h,{title:"Copy to clipboard",icon:"carbon-copy",onClick:u[0]||(u[0]=A=>l(d)(JSON.stringify(l(c),null,2),"timeline-argument"))},{default:v(()=>[F(" Copy ")]),_:1})])])):x("",!0)]),default:v(()=>[t("span",{"rounded-sm":"",px1:"","py0.5":"","text-sm":"",class:z([Array.isArray(s.value)?"text-amber bg-amber:10":"text-orange bg-orange:10"])},k(Array.isArray(s.value)?`[Array(${s.value.length})]`:"[Object]"),3)]),_:1}))}}}),es={key:0,"p-4":"",flex:"~ col gap-2","text-base":""},ss={"mx--1":""},ts={flex:"~ gap-1","font-mono":""},ns={key:1},os=t("span",{ml1:"",op30:""},"(",-1),as={key:0,op30:""},ls=t("span",{op30:""},")",-1),is={flex:"~ gap-1","text-sm":""},rs=t("span",{mx1:"",op50:""},"·",-1),cs={class:"text-sm text-gray-400"},ps=B({__name:"TimelineDetailsFunction",props:{record:{}},setup(_){const p=_,c=O(()=>p.record.start,{showSecond:!0}),e=ee(),a=w(()=>e.value?.metadata),i=w(()=>e.value?.imports.find(o=>o.as===p.record.name));return(o,d)=>{const s=H,u=pe,h=Qe,$=V,A=ue;return o.record?(n(),r("div",es,[t("div",ss,[m(s,{n:"yellow",textContent:"Function call"})]),t("div",ts,[l(i)?(n(),y(u,{key:0,item:l(i),metadata:l(a),counter:!1,classes:"px2 py1","mx--2":""},null,8,["item","metadata"])):(n(),r("span",ns,k(o.record.name),1)),os,(n(!0),r(f,null,E(o.record.args,(S,b)=>(n(),r(f,{key:b},[b?(n(),r("span",as,", ")):x("",!0),m(h,{value:S},null,8,["value"])],64))),128)),ls]),t("div",is,[o.record.end?(n(),y($,{key:0,duration:o.record.end-o.record.start},null,8,["duration"])):x("",!0),rs,t("div",cs,k(l(c)),1)]),o.record.stacktrace?(n(),y(A,{key:0,stacktrace:o.record.stacktrace,class:"text-xs text-gray-400"},null,8,["stacktrace"])):x("",!0)])):x("",!0)}}}),ds={key:0,"p-4":"",flex:"~ col gap-2"},us={"mx--1":""},ms={flex:"~ gap-1 items-center","font-mono":""},ks={op50:""},hs=t("span",{"i-carbon-arrow-right":"",op50:""},null,-1),_s={flex:"~ gap-1","text-sm":""},fs=t("span",{mx1:"",op50:""},"·",-1),ys={class:"text-sm text-gray-400"},vs=B({__name:"TimelineDetailsRoute",props:{record:{}},setup(_){const p=_,c=O(()=>p.record.start,{showSecond:!0});return(e,a)=>{const i=H,o=V;return e.record?(n(),r("div",ds,[t("div",us,[m(i,{n:"green",textContent:"Route Change"})]),t("div",ms,[t("span",ks,k(e.record.from),1),hs,t("span",null,k(e.record.to),1)]),t("div",_s,[e.record.end?(n(),y(o,{key:0,duration:e.record.end-e.record.start},null,8,["duration"])):x("",!0),fs,t("div",ys,k(l(c)),1)])])):x("",!0)}}}),bs={key:0,"h-screen":"","of-hidden":""},gs={"h-screen":"","w-full":"",flex:"","flex-col":""},xs={"h-10":"",flex:"~ gap-2 items-center justify-end",p2:"",px3:""},$s={"text-sm":""},As=t("div",{"flex-auto":""},null,-1),Ds={"min-h-50":"",px3:"",py2:""},Cs=B({__name:"TimelineView",setup(_){const p=se(),c=C("table"),e=C(),a=w(()=>p.value?.metrics.clientTimeline());function i(){a.value&&(a.value.events=[])}function o(){c.value=c.value==="table"?"list":"table"}return(d,s)=>{const u=P("VTooltip"),h=G,$=we,A=Re,S=ps,b=vs,L=me;return l(a)?(n(),r("div",bs,[t("div",gs,[t("div",xs,[m(u,{flex:""},{popper:v(()=>[t("div",$s,k(l(a).options.enabled?"Recording...":"Paused"),1)]),default:v(()=>[t("div",{"text-lg":"",class:z(l(a).options.enabled?"i-carbon-radio-button-checked text-primary animate-pulse":"i-carbon-pause-outline op30")},null,2)]),_:1}),l(a).options.enabled?(n(),y(h,{key:1,size:"small",ml1:"","text-sm":"",n:"orange",icon:"i-carbon-stop",onClick:s[1]||(s[1]=D=>l(a).options.enabled=!1)},{default:v(()=>[F(" Stop Tracking ")]),_:1})):(n(),y(h,{key:0,size:"small",ml1:"","text-sm":"",n:"primary",icon:"i-carbon-play",onClick:s[0]||(s[0]=D=>l(a).options.enabled=!0)},{default:v(()=>[F(" Start Tracking ")]),_:1})),As,m(h,{icon:l(c)==="table"?"i-carbon-roadmap":"i-carbon-list",class:"ml-2",title:"Toggle View",border:!1,onClick:o},null,8,["icon"]),m(h,{icon:"i-carbon-trash-can","hover-text-red":"",class:"ml-2",border:!1,onClick:i})]),l(c)==="table"?(n(),y($,{key:0,data:{...l(a)},onSelect:s[2]||(s[2]=D=>e.value=D.event)},null,8,["data"])):(n(),y(A,{key:1,data:{...l(a)},onSelect:s[3]||(s[3]=D=>e.value=D)},null,8,["data"]))]),m(L,{"model-value":!!l(e),"auto-close":"",transition:"bottom",left:"#nuxt-devtools-side-nav",onClose:s[4]||(s[4]=D=>e.value=void 0)},{default:v(()=>[t("div",Ds,[l(e)?.type==="function"?(n(),y(S,{key:0,record:l(e)},null,8,["record"])):l(e)?.type==="route"?(n(),y(b,{key:1,record:l(e)},null,8,["record"])):x("",!0)])]),_:1},8,["model-value"])])):x("",!0)}}}),Bs={class:"markdown-body"},ws=t("h1",null,"Timeline",-1),Ts=t("p",null,[t("blockquote",{"text-orange":"","bg-orange:10":"",py1:""}," This is an experimental feature ")],-1),Ss=te(`<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>
1
+ import{d as B,a as w,aL as M,o as n,m as r,k as t,a9 as T,f as l,t as k,ad as O,F as f,n as E,h as y,r as C,w as Y,aC as q,a1 as j,bW as U,p as x,i as m,G as z,q as X,ao as Z,e as K,au as P,j as v,ay as Q,v as F,_ as G,aN as ee,am as se,b3 as te,bX as ne,ab as oe,N as ae,ac as le,A as ie,L as R,a5 as re,Z as ce}from"./C_tLznPO.js";import{_ as V}from"./CoNBQO3e.js";import{_ as H}from"./D4V9JMY9.js";import{_ as pe}from"./BKukfVLl.js";import{e as de}from"./B3uNdhXb.js";import{_ as ue}from"./U0su7k1z.js";import{_ as me}from"./DrswlxM3.js";import{_ as ke}from"./nhLZZe93.js";import{_ as he}from"./Dm9RYIcI.js";import{_ as _e}from"./CCJYS4Qc.js";import{_ as fe}from"./BOV_C5BD.js";import"./CNzQK24q.js";import"./CO7Eo6nF.js";import"./BI3hykgO.js";import"./BcJws1i5.js";import"./CIvuwNIv.js";const ye=B({__name:"TimelineItemFunction",props:{item:{}},setup(_){const p=_,c=w(()=>M(p.item.name,50,60,"_op_")),e=w(()=>c.value.replace(/_op_/,"1")),a=w(()=>M(p.item.name,50,40)),i=w(()=>c.value.replace(/_op_/,"0.2"));return(o,d)=>(n(),r("button",{class:"group",style:T({color:l(e),borderLeft:`2px solid ${l(e)}`}),relative:"","text-sm":"",transition:"","hover:z-1000":"","bg-base":""},[t("div",{style:T({backgroundColor:l(i)}),absolute:"","bottom-0":"","left--1px":"","top-0":"","w-full":"","text-sm":"","transition-all":"","duration-300":""},null,4),t("div",{style:T({color:l(a),"--c":l(e)}),border:"r-2 t-2 y-2 transparent","min-w-max":"",px1:"","text-left":"","group-hover":"border-$c"},k(o.item.name),5)],4))}}),ve={relative:"","h-full":""},be={absolute:"","left-2":"","top-2.3em":"","text-xs":"",op50:""},ge=B({__name:"TimelineSegment",props:{segment:{}},emits:["select"],setup(_,{emit:p}){const c=_,e=p,a=O(()=>c.segment.start,{updateInterval:1e3,showSecond:!0,controls:!1,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,o)=>{const d=ye;return n(),r("div",ve,[t("button",{absolute:"","left-0":"","right-0":"","top-0":"","bg-green:5":"",px2:"",py1:"","text-left":"","text-xs":"","text-green6":"","font-mono":"",onClick:o[0]||(o[0]=s=>i.segment.route?e("select",i.segment.route):void 0)},k(i.segment.route?.event.to),1),t("div",be,k(l(a))+" ago ",1),t("div",null,[(n(!0),r(f,null,E(i.segment.functions,(s,u)=>(n(),y(d,{key:u,item:s.event,style:T({position:"absolute",minWidth:`${s.relativeWidth*100}%`,maxWidth:`${s.relativeWidth*100}%`,top:`${4+s.layer*1.6}em`,left:`${s.relativeStart*100}%`}),onClick:h=>e("select",s)},null,8,["item","style","onClick"]))),128))])])}}}),xe=3e3,$e=50;function Ae(_){const p=[];let c={start:0,end:0,events:[],functions:[],duration:0};for(const e of _){const a=e.end||e.start;(e.start-c.end>xe||e.type==="route")&&(c={start:e.start,end:a,events:[],functions:[],duration:0},p.push(c)),c.events.push(e),c.end=a+$e}return p.forEach((e,a)=>{const i=e.end-e.start,o=[];e.duration=i,e.previousGap=a>0?e.start-p[a-1].end:0,e.events.forEach(d=>{const s=d.end||d.start;let u=0;d.type!=="route"&&(u=o.findIndex($=>$<=d.start),u===-1?(u=o.length,o.push(s+1e3)):o[u]=s+1e3);const h={event:d,segment:e,relativeStart:(d.start-e.start)/i,relativeWidth:(s-d.start)/i,layer:u};d.type==="function"?e.functions.push(h):e.route=h})}),p}const De={relative:""},Ce={key:0,border:"x base","h-full":"","flex-inline":"","bg-true-gray-1":"",py15:"","text-xs":"","write-vertical-left":"",op50:"","dark:bg-true-gray-9":""},Be=B({__name:"TimelineTable",props:{data:{}},emits:["select"],setup(_,{emit:p}){const c=_,e=p,a=C(),i=C(),o=C(),d=C(),s=C(!0),u=C(1.5),h=w(()=>Ae(c.data.events)),$=w(()=>(c.data.events.length,a.value?.scrollWidth||window.innerWidth));function A(){d.value&&(d.value.style.width=`${$.value}px`)}function S(){s.value&&a.value&&(a.value.scrollTo({left:a.value.scrollWidth-a.value.clientWidth,behavior:"smooth"}),o.value.scrollTo({left:a.value.scrollWidth-a.value.clientWidth,behavior:"smooth"}))}return Y(()=>c.data.events.length,async()=>{await q(),A(),S()},{flush:"post"}),j(a,"scroll",()=>{o.value.scrollLeft!==a.value.scrollLeft&&(A(),o.value.scrollLeft=a.value.scrollLeft,s.value=a.value.scrollLeft>=a.value.scrollWidth-a.value.clientWidth)}),j(o,"scroll",()=>{o.value.scrollLeft!==a.value.scrollLeft&&(A(),a.value.scrollLeft=o.value.scrollLeft)}),j(a,"wheel",b=>{b.altKey?(u.value=U(u.value+b.deltaY/200,.5,3),A()):a.value.scrollLeft+=b.deltaY}),(b,L)=>{const D=V,W=ge;return n(),r(f,null,[t("div",De,[t("div",{ref_key:"minimap",ref:i,border:"t b base",relative:"","h-50px":"","ws-nowrap":"","border-base":""},[(n(!0),r(f,null,E(l(h),(g,N)=>(n(),r("div",{key:N,relative:"","h-full":"","flex-inline":"",style:T({width:`${Math.max(100,g.duration/10)/l($)*100}%`})},[(n(!0),r(f,null,E(g.functions,(I,J)=>(n(),r("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(M))(I.event.name,50,60)})},null,4))),128)),g.route?(n(),r("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),t("div",{ref_key:"minimapScroller",ref:o,class:"timeline-scroller",absolute:"","inset-0":"","h-full":"","w-full":"","of-x-scroll":""},[t("div",{ref_key:"minimapScrollerInner",ref:d,"h-1px":""},null,512)],512)]),t("div",{ref_key:"scroller",ref:a,relative:"","h-full":"","w-full":"","of-x-scroll":"","of-y-hidden":"","ws-nowrap":"","n-panel-grids":""},[(n(!0),r(f,null,E(l(h),(g,N)=>(n(),r(f,{key:N},[g.previousGap&&g.previousGap>=200?(n(),r("div",Ce,[m(D,{op50:"",duration:g.previousGap,color:!1},null,8,["duration"])])):x("",!0),m(W,{"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)}}}),we=X(Be,[["__scopeId","data-v-357f5ced"]]),Te={border:"t base",flex:"~ col","h-full":"","of-y-auto":"","text-sm":""},Se=["onClick"],Ne=t("div",{"i-carbon-function":"",op50:""},null,-1),Fe={flex:"~","ml--1":"","font-mono":""},Ee=t("div",{op30:""}," ( ",-1),Le={key:0,mr2:"",op30:""},Ie={op75:""},We=t("div",{op30:""}," ) ",-1),Me=t("div",{"mr-1":"","h-7":"","w-7":"",flex:"","rounded-lg":"","bg-primary:5":"",p1:"","text-green6":""},[t("div",{"i-carbon-direction-rotary-right":"",ma:"","text-lg":""})],-1),Ve={flex:"~ col items-start"},je={"text-xs":"","font-mono":"",op30:""},Oe={"text-green":"","font-bold":"","font-mono":""},ze=t("div",{"flex-auto":""},null,-1),Ge=t("div",{"min-h-100":""},null,-1),Re=B({__name:"TimelineList",props:{data:{}},emits:["select"],setup(_,{emit:p}){const c=p;return(e,a)=>{const i=V;return n(),r("div",Te,[(n(!0),r(f,null,E(e.data.events,(o,d)=>(n(),r("button",{key:d,border:"b base",px3:"",py2:"",flex:"~ items-center gap-2",hover:"bg-active",onClick:s=>c("select",o)},[o.type==="function"?(n(),r(f,{key:0},[Ne,t("div",{"font-mono":"",style:T({color:o.type==="function"?("getHashColorFromString"in e?e.getHashColorFromString:l(M))(o.name,50,60):""})},k(o.name),5),t("div",Fe,[Ee,(n(!0),r(f,null,E(o.args,(s,u)=>(n(),r(f,{key:u},[u?(n(),r("div",Le," , ")):x("",!0),t("div",Ie,k(s===null?"null":s===void 0?"undefined":typeof s=="function"?"[function]":Array.isArray(s)?"[Array]":typeof s=="object"?"[object]":JSON.stringify(s)),1)],64))),128)),We])],64)):(n(),r(f,{key:1},[Me,t("div",Ve,[t("div",je,k(o.from),1),t("div",Oe,k(o.to),1)])],64)),ze,o.end?(n(),y(i,{key:2,duration:o.end-o.start,color:o.type==="function"},null,8,["duration","color"])):x("",!0)],8,Se))),128)),Ge])}}}),Pe={key:0,"text-blue":""},He={key:1,"text-purple":""},Je={key:2,"text-green":""},Ye={key:3,"text-gray":""},qe={key:4,"text-gray":""},Ue={key:5,"text-gray":""},Xe={key:0,"bg-red:10":"",px2:"",py1:"","text-red":""},Ze={key:1},Ke={p2:"","text-sm":"",border:"t base"},Qe=B({__name:"TimelineArgumentView",props:{value:{}},setup(_){const p=_,c=C(),e=C();function a(){try{c.value=JSON.parse(JSON.stringify(p.value))}catch(s){console.error(s),e.value=s}}const i=B({emits:["setup"],setup(s,{emit:u}){return u("setup"),()=>null}}),o=Z(),d=K();return(s,u)=>{const h=G,$=P("VMenu");return typeof s.value=="string"?(n(),r("div",Pe,k(JSON.stringify(s.value)),1)):typeof s.value=="number"?(n(),r("div",He,k(s.value),1)):typeof s.value=="boolean"?(n(),r("div",Je,k(s.value),1)):typeof s.value>"u"?(n(),r("div",Ye," undefined ")):typeof s.value=="function"?(n(),r("div",qe," [Function"+k(s.value.name?`: ${s.value.name}`:"")+"] ",1)):s.value===null?(n(),r("div",Ue," null ")):(n(),y($,{key:6,placement:"top"},{popper:v(()=>[m(l(i),{onSetup:a}),l(e)?(n(),r("div",Xe," Failed to display object: "+k(l(e)),1)):l(c)?(n(),r("div",Ze,[m(l(de),Q({"model-value":l(c)},s.$attrs,{class:["json-editor-vue",[l(o)==="dark"?"jse-theme-dark":""]],"main-menu-bar":!1,"navigation-bar":!1,"status-bar":!1,"read-only":!0,indentation:2,"tab-size":2}),null,16,["model-value","class"]),t("div",Ke,[m(h,{title:"Copy to clipboard",icon:"carbon-copy",onClick:u[0]||(u[0]=A=>l(d)(JSON.stringify(l(c),null,2),"timeline-argument"))},{default:v(()=>[F(" Copy ")]),_:1})])])):x("",!0)]),default:v(()=>[t("span",{"rounded-sm":"",px1:"","py0.5":"","text-sm":"",class:z([Array.isArray(s.value)?"text-amber bg-amber:10":"text-orange bg-orange:10"])},k(Array.isArray(s.value)?`[Array(${s.value.length})]`:"[Object]"),3)]),_:1}))}}}),es={key:0,"p-4":"",flex:"~ col gap-2","text-base":""},ss={"mx--1":""},ts={flex:"~ gap-1","font-mono":""},ns={key:1},os=t("span",{ml1:"",op30:""},"(",-1),as={key:0,op30:""},ls=t("span",{op30:""},")",-1),is={flex:"~ gap-1","text-sm":""},rs=t("span",{mx1:"",op50:""},"·",-1),cs={class:"text-sm text-gray-400"},ps=B({__name:"TimelineDetailsFunction",props:{record:{}},setup(_){const p=_,c=O(()=>p.record.start,{showSecond:!0}),e=ee(),a=w(()=>e.value?.metadata),i=w(()=>e.value?.imports.find(o=>o.as===p.record.name));return(o,d)=>{const s=H,u=pe,h=Qe,$=V,A=ue;return o.record?(n(),r("div",es,[t("div",ss,[m(s,{n:"yellow",textContent:"Function call"})]),t("div",ts,[l(i)?(n(),y(u,{key:0,item:l(i),metadata:l(a),counter:!1,classes:"px2 py1","mx--2":""},null,8,["item","metadata"])):(n(),r("span",ns,k(o.record.name),1)),os,(n(!0),r(f,null,E(o.record.args,(S,b)=>(n(),r(f,{key:b},[b?(n(),r("span",as,", ")):x("",!0),m(h,{value:S},null,8,["value"])],64))),128)),ls]),t("div",is,[o.record.end?(n(),y($,{key:0,duration:o.record.end-o.record.start},null,8,["duration"])):x("",!0),rs,t("div",cs,k(l(c)),1)]),o.record.stacktrace?(n(),y(A,{key:0,stacktrace:o.record.stacktrace,class:"text-xs text-gray-400"},null,8,["stacktrace"])):x("",!0)])):x("",!0)}}}),ds={key:0,"p-4":"",flex:"~ col gap-2"},us={"mx--1":""},ms={flex:"~ gap-1 items-center","font-mono":""},ks={op50:""},hs=t("span",{"i-carbon-arrow-right":"",op50:""},null,-1),_s={flex:"~ gap-1","text-sm":""},fs=t("span",{mx1:"",op50:""},"·",-1),ys={class:"text-sm text-gray-400"},vs=B({__name:"TimelineDetailsRoute",props:{record:{}},setup(_){const p=_,c=O(()=>p.record.start,{showSecond:!0});return(e,a)=>{const i=H,o=V;return e.record?(n(),r("div",ds,[t("div",us,[m(i,{n:"green",textContent:"Route Change"})]),t("div",ms,[t("span",ks,k(e.record.from),1),hs,t("span",null,k(e.record.to),1)]),t("div",_s,[e.record.end?(n(),y(o,{key:0,duration:e.record.end-e.record.start},null,8,["duration"])):x("",!0),fs,t("div",ys,k(l(c)),1)])])):x("",!0)}}}),bs={key:0,"h-screen":"","of-hidden":""},gs={"h-screen":"","w-full":"",flex:"","flex-col":""},xs={"h-10":"",flex:"~ gap-2 items-center justify-end",p2:"",px3:""},$s={"text-sm":""},As=t("div",{"flex-auto":""},null,-1),Ds={"min-h-50":"",px3:"",py2:""},Cs=B({__name:"TimelineView",setup(_){const p=se(),c=C("table"),e=C(),a=w(()=>p.value?.metrics.clientTimeline());function i(){a.value&&(a.value.events=[])}function o(){c.value=c.value==="table"?"list":"table"}return(d,s)=>{const u=P("VTooltip"),h=G,$=we,A=Re,S=ps,b=vs,L=me;return l(a)?(n(),r("div",bs,[t("div",gs,[t("div",xs,[m(u,{flex:""},{popper:v(()=>[t("div",$s,k(l(a).options.enabled?"Recording...":"Paused"),1)]),default:v(()=>[t("div",{"text-lg":"",class:z(l(a).options.enabled?"i-carbon-radio-button-checked text-primary animate-pulse":"i-carbon-pause-outline op30")},null,2)]),_:1}),l(a).options.enabled?(n(),y(h,{key:1,size:"small",ml1:"","text-sm":"",n:"orange",icon:"i-carbon-stop",onClick:s[1]||(s[1]=D=>l(a).options.enabled=!1)},{default:v(()=>[F(" Stop Tracking ")]),_:1})):(n(),y(h,{key:0,size:"small",ml1:"","text-sm":"",n:"primary",icon:"i-carbon-play",onClick:s[0]||(s[0]=D=>l(a).options.enabled=!0)},{default:v(()=>[F(" Start Tracking ")]),_:1})),As,m(h,{icon:l(c)==="table"?"i-carbon-roadmap":"i-carbon-list",class:"ml-2",title:"Toggle View",border:!1,onClick:o},null,8,["icon"]),m(h,{icon:"i-carbon-trash-can","hover-text-red":"",class:"ml-2",border:!1,onClick:i})]),l(c)==="table"?(n(),y($,{key:0,data:{...l(a)},onSelect:s[2]||(s[2]=D=>e.value=D.event)},null,8,["data"])):(n(),y(A,{key:1,data:{...l(a)},onSelect:s[3]||(s[3]=D=>e.value=D)},null,8,["data"]))]),m(L,{"model-value":!!l(e),"auto-close":"",transition:"bottom",left:"#nuxt-devtools-side-nav",onClose:s[4]||(s[4]=D=>e.value=void 0)},{default:v(()=>[t("div",Ds,[l(e)?.type==="function"?(n(),y(S,{key:0,record:l(e)},null,8,["record"])):l(e)?.type==="route"?(n(),y(b,{key:1,record:l(e)},null,8,["record"])):x("",!0)])]),_:1},8,["model-value"])])):x("",!0)}}}),Bs={class:"markdown-body"},ws=t("h1",null,"Timeline",-1),Ts=t("p",null,[t("blockquote",{"text-orange":"","bg-orange:10":"",py1:""}," This is an experimental feature ")],-1),Ss=te(`<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
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:#B5695977;--shiki-dark:#C98A7D77;"> &#39;</span><span style="color:#B56959;--shiki-dark:#C98A7D;">@vueuse/core</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;">&#39;</span></span>
3
3
  <span class="line"><span style="color:#1E754F;--shiki-dark:#4D9375;">import</span><span style="color:#999999;--shiki-dark:#666666;"> {</span><span style="color:#B07D48;--shiki-dark:#BD976A;"> useNuxtApp</span><span style="color:#999999;--shiki-dark:#666666;"> }</span><span style="color:#1E754F;--shiki-dark:#4D9375;"> from</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;"> &#39;</span><span style="color:#B56959;--shiki-dark:#C98A7D;">#imports</span><span style="color:#B5695977;--shiki-dark:#C98A7D77;">&#39;</span></span>
4
4
  <span class="line"></span>
@@ -1,3 +1,3 @@
1
- import{d as N,a as C,aZ as oe,e as ne,ac as H,r as A,f as t,h as I,j as _,p as x,o,k as e,m as s,n as B,G as O,t as p,F as T,i as d,v as $,at as V,_ as J,a9 as R,a_ as P,a$ as se,b0 as ae,b1 as re,y as ie,z as ce,q as le,b2 as de,b3 as pe,b4 as me,b as ue,b5 as ge,b6 as he,b7 as _e,b8 as G,aC as fe,a2 as ve,l as be,ae as we,I as z,X as xe}from"./ciodjZaS.js";import{_ as ye}from"./D4Ks82zD.js";import{_ as U}from"./CE84j0J9.js";import{_ as q}from"./DwdKwQHN.js";import{_ as ke}from"./BZvh3yot.js";import{_ as $e}from"./CLVHkiJk.js";import"./zLQhdF7m.js";import"./yFeWtr-M.js";const K=[{name:"title",suggestion:"required",head:{title:"[title]"},seoMeta:{title:"[title]"},docs:"https://developer.mozilla.org/en-US/docs/Web/HTML/Element/title",description:"A concise and descriptive title for the browser that accurately summarizes the content of the page."},{name:"description",suggestion:"required",head:{meta:[{name:"description",content:"[description]"}]},seoMeta:{description:"[description]"},description:"A one to two sentence summary for search engines that includes relevant keywords to improve visibility in search results."},{name:"icon",suggestion:"recommended",head:{link:[{rel:"icon",type:"image/png",href:"/favicon.png"}]},description:"A small image that appears in the browser tab and bookmark menu to help users easily identify the page."},{name:"lang",suggestion:"recommended",head:{htmlAttrs:{lang:"en"}},description:"The primary language of the page to help search engines and browsers understand the content."},{name:"og:title",suggestion:"recommended",head:{meta:[{property:"og:title",content:"[og:title]"}]},seoMeta:{ogTitle:"[og:title]"},docs:"https://ogp.me/#metadata",description:"A title for the link preview used by social media platforms."},{name:"og:description",suggestion:"recommended",head:{meta:[{property:"og:description",content:"[og:description]"}]},seoMeta:{ogDescription:"[og:description]"},docs:"https://ogp.me/#metadata",description:"A description for the link preview used by social media platforms."},{name:"og:image",suggestion:"recommended",head:{meta:[{property:"og:image",content:"[og:image]"}]},seoMeta:{ogImage:"[og:image]"},docs:"https://ogp.me/#metadata",description:"An image for the link preview used by social media platforms."},{name:"og:url",suggestion:"recommended",head:{meta:[{property:"og:url",content:"[og:url]"}]},seoMeta:{ogUrl:"[og:url]"},docs:"https://ogp.me/#metadata",description:"A canonical URL for the link preview used to specify the preferred URL to display in search engine results and social media previews when multiple URLs may point to the same page."},{name:"twitter:title",suggestion:"optional",head:{meta:[{name:"twitter:title",content:"[twitter:title]"}]},seoMeta:{twitterTitle:"[twitter:title]"},docs:"https://developer.twitter.com/en/docs/twitter-for-websites/cards/overview/abouts-cards",description:"A title for the Twitter card used to provide a preview of the content shared on the page."},{name:"twitter:description",suggestion:"optional",head:{meta:[{name:"twitter:description",content:"[twitter:description]"}]},seoMeta:{twitterDescription:"[twitter:description]"},docs:"https://developer.twitter.com/en/docs/twitter-for-websites/cards/overview/abouts-cards",description:"A description for the Twitter card used to provide a preview of the content shared on the page."},{name:"twitter:image",suggestion:"optional",head:{meta:[{name:"twitter:image",content:"[twitter:image]"}]},seoMeta:{twitterImage:"[twitter:image]"},docs:"https://developer.twitter.com/en/docs/twitter-for-websites/cards/overview/abouts-cards",description:"An image for the Twitter card used to provide a preview of the content shared on the page."},{name:"twitter:card",suggestion:"optional",head:{meta:[{name:"twitter:card",content:"summary"}]},seoMeta:{twitterCard:"summary"},docs:"https://developer.twitter.com/en/docs/twitter-for-websites/cards/overview/abouts-cards",description:"The type of Twitter card to use, which determines the type of card to display in link previews on Twitter."}],Se={flex:"~ wrap","mt--2":"","w-full":"","flex-none":""},Te=["onClick"],Ce=e("div",{border:"b base","flex-auto":""},null,-1),Ne={key:0,"x-divider":""},Me={key:1,"x-divider":""},Oe={flex:"~ gap-1 items-center",class:"px2 pt2",lg:"px4 py2"},Ie=e("div",{"i-carbon-warning":"","text-orange":""},null,-1),Ae={"w-full":"",p2:"",op75:""},Be={key:1,m4:"",flex:"~ col gap-2"},Re={flex:"~ gap-1 wrap items-center"},Le={key:1},je={flex:"~ gap-2",n:"sm primary",absolute:"","right-2":"","top-2":""},Fe=N({__name:"OpenGraphMissingTabs",props:{tags:{},matchedRouteFilepath:{}},setup(h){const a=h,l=C(()=>K.filter(r=>!a.tags?.some(g=>g.name===r.name))),n=C(()=>{let r={};const g={};l.value.forEach(u=>{u.seoMeta?Object.assign(g,u.seoMeta):r=oe(r,u.head)});const b=[];if(Object.keys(g).length){const u=JSON.stringify(g,null,2).replace(/"([^"]+)":/g,"$1:").replace(/"/g,"'");b.push(`useSeoMeta(${u})`)}if(Object.keys(r).length){const u=JSON.stringify(r,null,2).replace(/"([^"]+)":/g,"$1:").replace(/"/g,"'");b.push(`useHead(${u})`)}return b.join(`
1
+ import{d as N,a as C,aZ as oe,e as ne,ac as H,r as A,f as t,h as I,j as _,p as x,o,k as e,m as s,n as B,G as O,t as p,F as T,i as d,v as $,at as V,_ as J,a9 as R,a_ as P,a$ as se,b0 as ae,b1 as re,y as ie,z as ce,q as le,b2 as de,b3 as pe,b4 as me,b as ue,b5 as ge,b6 as he,b7 as _e,b8 as G,aC as fe,a2 as ve,l as be,ae as we,I as z,X as xe}from"./C_tLznPO.js";import{_ as ye}from"./BHh_UM9T.js";import{_ as U}from"./Dm9RYIcI.js";import{_ as q}from"./DqpvVAaa.js";import{_ as ke}from"./CIvuwNIv.js";import{_ as $e}from"./BOV_C5BD.js";import"./B1veJI6T.js";import"./CO7Eo6nF.js";const K=[{name:"title",suggestion:"required",head:{title:"[title]"},seoMeta:{title:"[title]"},docs:"https://developer.mozilla.org/en-US/docs/Web/HTML/Element/title",description:"A concise and descriptive title for the browser that accurately summarizes the content of the page."},{name:"description",suggestion:"required",head:{meta:[{name:"description",content:"[description]"}]},seoMeta:{description:"[description]"},description:"A one to two sentence summary for search engines that includes relevant keywords to improve visibility in search results."},{name:"icon",suggestion:"recommended",head:{link:[{rel:"icon",type:"image/png",href:"/favicon.png"}]},description:"A small image that appears in the browser tab and bookmark menu to help users easily identify the page."},{name:"lang",suggestion:"recommended",head:{htmlAttrs:{lang:"en"}},description:"The primary language of the page to help search engines and browsers understand the content."},{name:"og:title",suggestion:"recommended",head:{meta:[{property:"og:title",content:"[og:title]"}]},seoMeta:{ogTitle:"[og:title]"},docs:"https://ogp.me/#metadata",description:"A title for the link preview used by social media platforms."},{name:"og:description",suggestion:"recommended",head:{meta:[{property:"og:description",content:"[og:description]"}]},seoMeta:{ogDescription:"[og:description]"},docs:"https://ogp.me/#metadata",description:"A description for the link preview used by social media platforms."},{name:"og:image",suggestion:"recommended",head:{meta:[{property:"og:image",content:"[og:image]"}]},seoMeta:{ogImage:"[og:image]"},docs:"https://ogp.me/#metadata",description:"An image for the link preview used by social media platforms."},{name:"og:url",suggestion:"recommended",head:{meta:[{property:"og:url",content:"[og:url]"}]},seoMeta:{ogUrl:"[og:url]"},docs:"https://ogp.me/#metadata",description:"A canonical URL for the link preview used to specify the preferred URL to display in search engine results and social media previews when multiple URLs may point to the same page."},{name:"twitter:title",suggestion:"optional",head:{meta:[{name:"twitter:title",content:"[twitter:title]"}]},seoMeta:{twitterTitle:"[twitter:title]"},docs:"https://developer.twitter.com/en/docs/twitter-for-websites/cards/overview/abouts-cards",description:"A title for the Twitter card used to provide a preview of the content shared on the page."},{name:"twitter:description",suggestion:"optional",head:{meta:[{name:"twitter:description",content:"[twitter:description]"}]},seoMeta:{twitterDescription:"[twitter:description]"},docs:"https://developer.twitter.com/en/docs/twitter-for-websites/cards/overview/abouts-cards",description:"A description for the Twitter card used to provide a preview of the content shared on the page."},{name:"twitter:image",suggestion:"optional",head:{meta:[{name:"twitter:image",content:"[twitter:image]"}]},seoMeta:{twitterImage:"[twitter:image]"},docs:"https://developer.twitter.com/en/docs/twitter-for-websites/cards/overview/abouts-cards",description:"An image for the Twitter card used to provide a preview of the content shared on the page."},{name:"twitter:card",suggestion:"optional",head:{meta:[{name:"twitter:card",content:"summary"}]},seoMeta:{twitterCard:"summary"},docs:"https://developer.twitter.com/en/docs/twitter-for-websites/cards/overview/abouts-cards",description:"The type of Twitter card to use, which determines the type of card to display in link previews on Twitter."}],Se={flex:"~ wrap","mt--2":"","w-full":"","flex-none":""},Te=["onClick"],Ce=e("div",{border:"b base","flex-auto":""},null,-1),Ne={key:0,"x-divider":""},Me={key:1,"x-divider":""},Oe={flex:"~ gap-1 items-center",class:"px2 pt2",lg:"px4 py2"},Ie=e("div",{"i-carbon-warning":"","text-orange":""},null,-1),Ae={"w-full":"",p2:"",op75:""},Be={key:1,m4:"",flex:"~ col gap-2"},Re={flex:"~ gap-1 wrap items-center"},Le={key:1},je={flex:"~ gap-2",n:"sm primary",absolute:"","right-2":"","top-2":""},Fe=N({__name:"OpenGraphMissingTabs",props:{tags:{},matchedRouteFilepath:{}},setup(h){const a=h,l=C(()=>K.filter(r=>!a.tags?.some(g=>g.name===r.name))),n=C(()=>{let r={};const g={};l.value.forEach(u=>{u.seoMeta?Object.assign(g,u.seoMeta):r=oe(r,u.head)});const b=[];if(Object.keys(g).length){const u=JSON.stringify(g,null,2).replace(/"([^"]+)":/g,"$1:").replace(/"/g,"'");b.push(`useSeoMeta(${u})`)}if(Object.keys(r).length){const u=JSON.stringify(r,null,2).replace(/"([^"]+)":/g,"$1:").replace(/"/g,"'");b.push(`useHead(${u})`)}return b.join(`
2
2
 
3
3
  `)}),m=ne(),y=H(),k=["Missing Tags","Code Snippet"],f=A(k[0]);return(r,g)=>{const b=U,u=V,S=J,M=ke,L=q;return t(l).length?(o(),I(L,{key:0,text:"Missing Tags",description:`${t(l).length} missing tags`,icon:"carbon:warning-other","header-class":"text-orange op100! [[open]_&]:text-inherit",padding:!1},{default:_(()=>[e("div",Se,[(o(),s(T,null,B(k,(i,c)=>e("button",{key:c,px4:"",py2:"",border:"r t base",hover:"bg-active",class:O(i===t(f)?"":"border-b"),onClick:v=>f.value=i},[e("div",{class:O(i===t(f)?"":"op30"),capitalize:""},p(i),3)],10,Te)),64)),Ce]),t(f)===k[0]?(o(),I(u,{key:0,grid:"~ cols-[1fr] lg:cols-[max-content_1fr]",m4:"","items-center":"","justify-between":"","of-hidden":""},{default:_(()=>[(o(!0),s(T,null,B(t(l),(i,c)=>(o(),s(T,{key:c},[c?(o(),s("div",Ne)):x("",!0),c?(o(),s("div",Me)):x("",!0),e("div",Oe,[Ie,d(b,{"op-50":"",href:i.docs,target:"_blank",n:"orange"},{default:_(()=>[$(p(i.name),1)]),_:2},1032,["href"])]),e("div",Ae,p(i.description),1)],64))),128))]),_:1})):(o(),s("div",Be,[e("p",Re,[d(S,{icon:"carbon-copy",n:"xs","px-2":"",onClick:g[0]||(g[0]=i=>t(m)(t(n),"open-graph-suggestion"))},{default:_(()=>[$(" Copy ")]),_:1}),$(" the following code snippet and paste it into your "),r.matchedRouteFilepath?(o(),I(S,{key:0,icon:"carbon-launch",n:"xs","px-2":"",onClick:g[1]||(g[1]=i=>t(y)(r.matchedRouteFilepath))},{default:_(()=>[$(" page component ")]),_:1})):(o(),s("span",Le,"page component")),$(" to full fill the missing tags. ")]),d(u,{relative:"","n-code-block":""},{default:_(()=>[d(M,{code:t(n),lang:"ts",lines:!1,"w-full":"","of-auto":"",p3:""},null,8,["code"]),e("div",je,[d(S,{icon:"carbon-copy",onClick:g[2]||(g[2]=i=>t(m)(t(n),"open-graph-suggestion"))},{default:_(()=>[$(" Copy ")]),_:1})])]),_:1})]))]),_:1},8,["description"])):x("",!0)}}}),De={class:"max-w-[524px] min-w-[524px] cursor-pointer bg-base"},ze={class:"break-words border border-base px-[12px] py-[10px] antialiased"},Ee={class:"overflow-hidden truncate whitespace-nowrap text-[12px] leading-[11px] uppercase op50"},Ge={class:"block h-[46px] max-h-[46px] border-separate select-none overflow-hidden break-words text-left",style:{"border-spacing":"0px"}},He={class:"mt-[3px] truncate pt-[2px] text-[16px] font-semibold leading-[20px]"},Ve={class:"mt-[3px] block h-[18px] max-h-[80px] border-separate select-none overflow-hidden truncate whitespace-nowrap break-words text-left text-[14px] leading-[20px] op50",style:{"-webkit-line-clamp":"1","border-spacing":"0px","-webkit-box-orient":"vertical"}},Je=N({__name:"SocialFacebook",props:{card:{}},setup(h){return(a,l)=>(o(),s("div",De,[e("div",{class:"h-[274px] border border-b-0 border-base bg-cover bg-center bg-no-repeat",style:R({backgroundImage:`url(${JSON.stringify(a.card.image)})`})},null,4),e("div",ze,[e("div",Ee,p(a.card.url),1),e("div",Ge,[e("div",He,p(a.card.title),1),e("div",Ve,p(a.card.description),1)])])]))}}),Pe={class:"max-w-[438px] min-w-[438px] of-hidden border border-base rounded-[16px] bg-base -outline-offset-1",style:{"font-family":"TwitterChirp, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif"}},Ue={class:"break-words border-base p-[0.75em] antialiased",flex:"~ col justify-center gap-[2px]"},qe={class:"overflow-hidden truncate whitespace-nowrap text-[15px] leading-[20px] lowercase op50"},Ke={class:"m-0 truncate text-[15px] font-semibold leading-[20px]"},We={class:"line-clamp-2 select-none overflow-hidden break-words text-left text-[15px] leading-[20px] op50"},Xe=N({__name:"SocialTwitter",props:{tags:{}},setup(h){const a=h,l=C(()=>P(a.tags,{title:[{tag:"title"}],image:[{tag:"meta",name:"twitter:image"},{tag:"meta",name:"og:image"}],imageAlt:[{tag:"meta",name:"twitter:image:alt"}],description:[{tag:"meta",name:"twitter:description"},{tag:"meta",name:"description"}],favicon:[{tag:"link",name:"icon"}]})),n=C(()=>l.value.image?a.tags.find(m=>m.tag==="meta"&&m.name==="twitter:card")?.value||"summary_large_image":"summary");return(m,y)=>(o(),s("div",Pe,[e("div",{class:O(["cursor-pointer overflow-hidden leading-[1.3em]",t(n)==="summary_large_image"?"":"flex"]),hover:"bg-[#88888805]"},[t(n)==="summary_large_image"?(o(),s("div",{key:0,class:"h-[220px] border-b border-base bg-cover bg-center bg-no-repeat",style:R({backgroundImage:`url(${JSON.stringify(t(l).image)})`})},null,4)):(o(),s("div",{key:1,class:"h-[129px] w-[129px] flex-none border-r border-base bg-cover bg-center bg-no-repeat",style:R({backgroundImage:`url(${JSON.stringify(t(l).image)})`})},null,4)),e("div",Ue,[e("div",qe,p(t(l).url),1),e("div",Ke,p(t(l).title),1),e("div",We,p(t(l).description),1)])],2)]))}}),Ye={class:"max-w-[520px] min-w-[520px] cursor-pointer overflow-hidden border border-base rounded-[2px] shadow-md bg-base"},Ze={class:"break-words p-[10px] antialiased"},Qe={class:"block h-auto max-h-[50px] border-separate select-none break-words text-left",style:{"border-spacing":"0px"}},et={class:"pb-[2px] text-[16px] font-semibold leading-[24px]"},tt={class:"overflow-hidden truncate whitespace-nowrap text-xs font-normal uppercase op85"},ot=N({__name:"SocialLinkedin",props:{card:{}},setup(h){return(a,l)=>(o(),s("div",Ye,[e("div",{class:"h-[270px] border-b border-base bg-cover bg-center bg-no-repeat",style:R({backgroundImage:`url(${JSON.stringify(a.card.image)})`})},null,4),e("div",Ze,[e("div",Qe,[e("div",et,p(a.card.title),1),e("div",tt,p(a.card.url),1)])])]))}}),nt=h=>(ie("data-v-6d584478"),h=h(),ce(),h),st={class:"relative max-w-[420px] min-w-[420px] rounded-[16px] rounded-bl-0 py-[6px] leading-[18px] drop-shadow-sm drop-shadow-color-[#10232f26] bg-base"},at={class:"pl-[10px] pr-[8px]"},rt={class:"text-[#3390ec] leading-normal underline"},it={class:"quote w-full flex"},ct={class:"flex flex-col gap-1"},lt={key:0,class:"my-[3px] overflow-hidden rounded"},dt=["src"],pt={class:"cursor-pointer text-sm text-[#3390ec]"},mt={class:"cursor-pointer text-sm"},ut={class:"cursor-pointer text-sm"},gt={class:"flex justify-end text-xs text-[#707579]"},ht=nt(()=>e("svg",{width:"11",height:"20",viewBox:"0 0 11 20",xmlns:"http://www.w3.org/2000/svg",class:"absolute bottom-0 ml-[-8.4px] translate-y-px text-white"},[e("g",{transform:"translate(9 -14)","fill-rule":"evenodd"},[e("path",{id:"corner-fill",d:"M-6 16h6v17c-.193-2.84-.876-5.767-2.05-8.782-.904-2.325-2.446-4.485-4.625-6.48A1 1 0 01-6 16z",transform:"matrix(1 0 0 -1 0 49)",fill:"currentColor"})])],-1)),_t=N({__name:"SocialTelegram",props:{card:{}},setup(h){const a=se(),l=ae(re(),"HH:mm");return(n,m)=>(o(),s("div",st,[e("div",at,[e("div",rt,p(n.card.url),1),e("div",it,[e("div",ct,[n.card.image?(o(),s("div",lt,[e("img",{class:"h-full max-w-full w-full rounded object-cover",src:n.card.image},null,8,dt)])):x("",!0),e("div",pt,[e("strong",null,p(t(a).hostname),1)]),e("div",mt,[e("strong",null,p(n.card.title),1)]),e("div",ut,p(n.card.description),1)])]),e("div",gt,[e("span",null,p(t(l)),1)])]),ht]))}}),ft=le(_t,[["__scopeId","data-v-6d584478"]]),vt={flex:"~ col","w-full":""},bt={flex:"~ wrap","w-full":"","flex-none":""},wt=["onClick"],xt=e("div",{border:"b base","flex-auto":""},null,-1),yt={flex:"~ items-center justify-center","flex-auto":"",p4:"","n-panel-grids":""},kt={key:0},$t={key:1},St={key:2},Tt={key:3},Ct=N({__name:"SocialPreviewGroup",props:{tags:{}},setup(h){const a=h,l=["twitter","facebook","linkedin","telegram"],n=de("nuxt-devtools-social-preview-tab",l[0]),m=C(()=>P(a.tags,{title:[{tag:"title"}],image:[{tag:"meta",name:"og:image"}],imageAlt:[{tag:"meta",name:"og:image:alt"}],description:[{tag:"meta",name:"og:description"},{tag:"meta",name:"description"}],favicon:[{tag:"link",name:"icon"}]}));return(y,k)=>{const f=Je,r=Xe,g=ot,b=ft;return o(),s("div",vt,[e("div",bt,[(o(),s(T,null,B(l,(u,S)=>e("button",{key:S,px4:"",py2:"",border:"r base",hover:"bg-active",class:O(u===t(n)?"":"border-b"),onClick:M=>n.value=u},[e("div",{class:O(u===t(n)?"":"op30"),capitalize:""},p(u),3)],10,wt)),64)),xt]),e("div",yt,[t(n)==="facebook"?(o(),s("div",kt,[d(f,{card:t(m)},null,8,["card"])])):t(n)==="twitter"?(o(),s("div",$t,[d(r,{tags:y.tags},null,8,["tags"])])):t(n)==="linkedin"?(o(),s("div",St,[d(g,{card:t(m)},null,8,["card"])])):t(n)==="telegram"?(o(),s("div",Tt,[d(b,{card:t(m)},null,8,["card"])])):x("",!0)])])}}}),Nt={class:"markdown-body"},Mt=pe('<h1>Open Graph</h1><p>Nuxt provides several different ways to manage your meta tags using <a href="https://unhead.harlanzw.com/" target="_blank" rel="noopener"><code>unhead</code></a>. Improve your Nuxt app’s SEO with powerful head config, composables and components.</p><p><a href="https://nuxt.com/docs/getting-started/seo-meta" target="_blank" rel="noopener">Learn more on the documentation</a></p><hr><p>You can also find how open graph specs are defined in:</p><ul><li><a href="https://ogp.me/" target="_blank" rel="noopener">The Open Graph protocol</a></li><li><a href="https://developer.twitter.com/en/docs/twitter-for-websites/cards/guides/getting-started" target="_blank" rel="noopener">Twitter Cards</a></li></ul>',6),Ot=[Mt],It={__name:"open-graph",setup(h,{expose:a}){return a({frontmatter:{}}),(n,m)=>(o(),s("div",Nt,Ot))}},At=It,Bt={grid:"~ lg:cols-2","h-full":"","w-full":"","of-hidden":""},Rt={"flex-auto":"","of-auto":""},Lt={"flex-none":"",flex:"~ gap2 items-center"},jt={flex:"~ col"},Ft={key:0,"x-divider":""},Dt={key:1,"x-divider":""},zt={mr2:"",px4:"",py2:""},Kt=N({__name:"open-graph",setup(h){const a=A(0),l=me(),n=ue(async()=>(a.value,(await l.value?.resolveTags()).map(c=>{const v=c.props||{};return c.tag==="htmlAttrs"&&v.lang?{tag:"html",name:"lang",value:v.lang}:v.charset?{tag:"meta",name:"charset",value:v.charset}:{tag:c.tag,name:v.property??v.name??v.rel??c.tag,value:v.content??v.href??c.textContent??JSON.stringify(v)}})),[]),m=A(!0);function y(){a.value+=1}const k=ge(),f=he(),r=A(""),g=_e(),b=H();async function u(){r.value!==f.value.path&&k.value.push(r.value||"/")}const S=C(()=>r.value===f.value.path?[]:k.value.resolve(r.value||"/").matched),M=C(()=>{const i=g.value.find(c=>c.path===f.value?.matched?.[0]?.path);return i?.file||i?.meta?.file});function L(i){return K.find(c=>c.name===i.name)?.docs}return G(f).toBeTruthy().then(i=>{r.value=i.path}),G(k).toBeTruthy().then(i=>{i.afterEach(()=>{fe(()=>{r.value=f.value.path,setTimeout(y,200),setTimeout(y,800)})})}),(i,c)=>{const v=xe,j=J,W=ye,E=U,X=V,Y=q,Z=Fe,Q=Ct,ee=At,te=$e,F=ve("tooltip");return o(),s(T,null,[e("div",Bt,[e("div",Rt,[d(W,null,{search:_(()=>[d(v,{modelValue:t(r),"onUpdate:modelValue":c[0]||(c[0]=w=>be(r)?r.value=w:null),placeholder:"Route",icon:"carbon-direction-right-01 scale-y--100",n:"primary","flex-auto":"","font-mono":"",class:O(["px-5 py-2",t(f)?.path===t(r)?"":t(S).length?"text-green":"text-orange"]),onKeydown:we(u,["enter"])},null,8,["modelValue","class"])]),actions:_(()=>[e("div",Lt,[t(M)?z((o(),I(j,{key:0,"text-lg":"",border:!1,icon:"carbon:launch",title:"Open file in editor",onClick:c[1]||(c[1]=w=>t(b)(t(M)))},null,512)),[[F,"Open file in editor"]]):x("",!0),z(d(j,{"text-lg":"",border:!1,icon:"carbon:reset",title:"Refresh Data",onClick:y},null,512),[[F,"Refresh Data"]]),z(d(j,{"text-lg":"",border:!1,icon:t(m)?"carbon:side-panel-open":"carbon:open-panel-right",title:"Toggle Preview",onClick:c[2]||(c[2]=w=>m.value=!t(m))},null,8,["icon"]),[[F,"Toggle Preview"]])])]),_:1}),e("div",jt,[d(Y,{text:"Tags",icon:"carbon:tag-group"},{default:_(()=>[d(X,{grid:"~ cols-[max-content_1fr]","items-center":"","justify-between":"","of-hidden":""},{default:_(()=>[(o(!0),s(T,null,B(t(n),(w,D)=>(o(),s(T,{key:D},[D?(o(),s("div",Ft)):x("",!0),D?(o(),s("div",Dt)):x("",!0),e("div",zt,[d(E,{op50:"",href:L(w),target:"_blank",n:"primary"},{default:_(()=>[$(p(w.name),1)]),_:2},1032,["href"])]),d(E,{href:String(w.value).match(/^https?:\/\//)?w.value:void 0,target:"_blank","w-full":"",p2:"","font-mono":"",n:"primary"},{default:_(()=>[$(p(w.value),1)]),_:2},1032,["href"])],64))),128))]),_:1})]),_:1}),d(Z,{tags:t(n),"matched-route-filepath":t(M)},null,8,["tags","matched-route-filepath"])])]),t(m)&&t(n)?.length?(o(),I(Q,{key:0,tags:t(n),"flex-none":"","border-base":"","lt-lg":"border-t",lg:"h-full w-140 border-l"},null,8,["tags"])):x("",!0)]),d(te,null,{default:_(()=>[d(ee)]),_:1})],64)}}});export{Kt as default};
@@ -1 +1 @@
1
- import t from"./CTKqK4eG.js";import e from"./Dch3xQiY.js";import"./BMbUeBqv.js";import"./BiWblMbN.js";import"./DC8MraHL.js";import"./Q9LIRUci.js";import"./DHFOa8tC.js";const n=Object.freeze({displayName:"Vue HTML",fileTypes:[],name:"vue-html",patterns:[{include:"source.vue#vue-interpolations"},{begin:"(<)([A-Z][a-zA-Z0-9:-]*)(?=[^>]*></\\2>)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"support.class.component.html"}},end:"(>)(<)(/)(\\2)(>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"},2:{name:"punctuation.definition.tag.begin.html meta.scope.between-tag-pair.html"},3:{name:"punctuation.definition.tag.begin.html"},4:{name:"support.class.component.html"},5:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(<)([a-z][a-zA-Z0-9:-]*)(?=[^>]*></\\2>)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"entity.name.tag.html"}},end:"(>)(<)(/)(\\2)(>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"},2:{name:"punctuation.definition.tag.begin.html meta.scope.between-tag-pair.html"},3:{name:"punctuation.definition.tag.begin.html"},4:{name:"entity.name.tag.html"},5:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(<\\?)(xml)",captures:{1:{name:"punctuation.definition.tag.html"},2:{name:"entity.name.tag.xml.html"}},end:"(\\?>)",name:"meta.tag.preprocessor.xml.html",patterns:[{include:"#tag-generic-attribute"},{include:"#string-double-quoted"},{include:"#string-single-quoted"}]},{begin:"<!--",captures:{0:{name:"punctuation.definition.comment.html"}},end:"-->",name:"comment.block.html"},{begin:"<!",captures:{0:{name:"punctuation.definition.tag.html"}},end:">",name:"meta.tag.sgml.html",patterns:[{begin:"(?i:DOCTYPE)",captures:{1:{name:"entity.name.tag.doctype.html"}},end:"(?=>)",name:"meta.tag.sgml.doctype.html",patterns:[{match:'"[^">]*"',name:"string.quoted.double.doctype.identifiers-and-DTDs.html"}]},{begin:"\\[CDATA\\[",end:"]](?=>)",name:"constant.other.inline-data.html"},{match:"(\\s*)(?!--|>)\\S(\\s*)",name:"invalid.illegal.bad-comments-or-CDATA.html"}]},{begin:"(</?)([A-Z][a-zA-Z0-9:-]*\\b)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"support.class.component.html"}},end:"(>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.block.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(</?)([a-z][a-zA-Z0-9:-]*\\b)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"entity.name.tag.block.any.html"}},end:"(>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.block.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(</?)((?i:body|head|html)\\b)",captures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"entity.name.tag.structure.any.html"}},end:"(>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.structure.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(</?)((?i:address|blockquote|dd|div|dl|dt|fieldset|form|frame|frameset|h1|h2|h3|h4|h5|h6|iframe|noframes|object|ol|p|ul|applet|center|dir|hr|menu|pre)(?!-)\\b)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"entity.name.tag.block.any.html"}},end:"(>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.block.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(</?)((?i:a|abbr|acronym|area|b|base|basefont|bdo|big|br|button|caption|cite|code|col|colgroup|del|dfn|em|font|head|html|i|img|input|ins|isindex|kbd|label|legend|li|link|map|meta|noscript|optgroup|option|param|q|s|samp|script|select|small|span|strike|strong|style|sub|sup|table|tbody|td|textarea|tfoot|th|thead|title|tr|tt|u|var)(?!-)\\b)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"entity.name.tag.inline.any.html"}},end:"(/?>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.inline.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(</?)([a-zA-Z0-9:-]+)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"entity.name.tag.other.html"}},end:"(/?>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.other.html",patterns:[{include:"#tag-stuff"}]},{include:"#entities"},{match:"<>",name:"invalid.illegal.incomplete.html"},{match:"<",name:"invalid.illegal.bad-angle-bracket.html"}],repository:{entities:{patterns:[{captures:{1:{name:"punctuation.definition.entity.html"},3:{name:"punctuation.definition.entity.html"}},match:"(&)([a-zA-Z0-9]+|#[0-9]+|#x[0-9a-fA-F]+)(;)",name:"constant.character.entity.html"},{match:"&",name:"invalid.illegal.bad-ampersand.html"}]},"string-double-quoted":{begin:'"',beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:'"',endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"string.quoted.double.html",patterns:[{include:"source.vue#vue-interpolations"},{include:"#entities"}]},"string-single-quoted":{begin:"'",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:"'",endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"string.quoted.single.html",patterns:[{include:"source.vue#vue-interpolations"},{include:"#entities"}]},"tag-generic-attribute":{match:"(?<=[^=])\\b([a-zA-Z0-9:\\-_]+)",name:"entity.other.attribute-name.html"},"tag-id-attribute":{begin:"\\b(id)\\b\\s*(=)",captures:{1:{name:"entity.other.attribute-name.id.html"},2:{name:"punctuation.separator.key-value.html"}},end:`(?!\\G)(?<='|"|[^\\s<>/])`,name:"meta.attribute-with-value.id.html",patterns:[{begin:'"',beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},contentName:"meta.toc-list.id.html",end:'"',endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"string.quoted.double.html",patterns:[{include:"source.vue#vue-interpolations"},{include:"#entities"}]},{begin:"'",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},contentName:"meta.toc-list.id.html",end:"'",endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"string.quoted.single.html",patterns:[{include:"source.vue#vue-interpolations"},{include:"#entities"}]},{captures:{0:{name:"meta.toc-list.id.html"}},match:`(?<==)(?:[^\\s<>/'"]|/(?!>))+`,name:"string.unquoted.html"}]},"tag-stuff":{patterns:[{include:"#vue-directives"},{include:"#tag-id-attribute"},{include:"#tag-generic-attribute"},{include:"#string-double-quoted"},{include:"#string-single-quoted"},{include:"#unquoted-attribute"}]},"unquoted-attribute":{match:`(?<==)(?:[^\\s<>/'"]|/(?!>))+`,name:"string.unquoted.html"},"vue-directives":{begin:"(?:\\b(v-)|(:|@|#))([a-zA-Z0-9\\-_]+)(?:\\:([a-zA-Z\\-_]+))?(?:\\.([a-zA-Z\\-_]+))*\\s*(=)",captures:{1:{name:"entity.other.attribute-name.html"},2:{name:"punctuation.separator.key-value.html"},3:{name:"entity.other.attribute-name.html"},4:{name:"entity.other.attribute-name.html"},5:{name:"entity.other.attribute-name.html"},6:{name:"punctuation.separator.key-value.html"}},end:"(?<='|\")|(?=[\\s<>`])",name:"meta.directive.vue",patterns:[{begin:"`",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:"`",endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"source.directive.vue",patterns:[{include:"source.js#expression"}]},{begin:'"',beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:'"',endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"source.directive.vue",patterns:[{include:"source.js#expression"}]},{begin:"'",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:"'",endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"source.directive.vue",patterns:[{include:"source.js#expression"}]}]}},scopeName:"text.html.vue-html",embeddedLangs:["vue","javascript"]});var d=[...t,...e,n];export{d as default};
1
+ import t from"./CTKqK4eG.js";import e from"./CHuuZgn4.js";import"./BMbUeBqv.js";import"./BiWblMbN.js";import"./_ECCzcZq.js";import"./Q9LIRUci.js";import"./DHFOa8tC.js";const n=Object.freeze({displayName:"Vue HTML",fileTypes:[],name:"vue-html",patterns:[{include:"source.vue#vue-interpolations"},{begin:"(<)([A-Z][a-zA-Z0-9:-]*)(?=[^>]*></\\2>)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"support.class.component.html"}},end:"(>)(<)(/)(\\2)(>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"},2:{name:"punctuation.definition.tag.begin.html meta.scope.between-tag-pair.html"},3:{name:"punctuation.definition.tag.begin.html"},4:{name:"support.class.component.html"},5:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(<)([a-z][a-zA-Z0-9:-]*)(?=[^>]*></\\2>)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"entity.name.tag.html"}},end:"(>)(<)(/)(\\2)(>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"},2:{name:"punctuation.definition.tag.begin.html meta.scope.between-tag-pair.html"},3:{name:"punctuation.definition.tag.begin.html"},4:{name:"entity.name.tag.html"},5:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(<\\?)(xml)",captures:{1:{name:"punctuation.definition.tag.html"},2:{name:"entity.name.tag.xml.html"}},end:"(\\?>)",name:"meta.tag.preprocessor.xml.html",patterns:[{include:"#tag-generic-attribute"},{include:"#string-double-quoted"},{include:"#string-single-quoted"}]},{begin:"<!--",captures:{0:{name:"punctuation.definition.comment.html"}},end:"-->",name:"comment.block.html"},{begin:"<!",captures:{0:{name:"punctuation.definition.tag.html"}},end:">",name:"meta.tag.sgml.html",patterns:[{begin:"(?i:DOCTYPE)",captures:{1:{name:"entity.name.tag.doctype.html"}},end:"(?=>)",name:"meta.tag.sgml.doctype.html",patterns:[{match:'"[^">]*"',name:"string.quoted.double.doctype.identifiers-and-DTDs.html"}]},{begin:"\\[CDATA\\[",end:"]](?=>)",name:"constant.other.inline-data.html"},{match:"(\\s*)(?!--|>)\\S(\\s*)",name:"invalid.illegal.bad-comments-or-CDATA.html"}]},{begin:"(</?)([A-Z][a-zA-Z0-9:-]*\\b)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"support.class.component.html"}},end:"(>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.block.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(</?)([a-z][a-zA-Z0-9:-]*\\b)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"entity.name.tag.block.any.html"}},end:"(>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.block.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(</?)((?i:body|head|html)\\b)",captures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"entity.name.tag.structure.any.html"}},end:"(>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.structure.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(</?)((?i:address|blockquote|dd|div|dl|dt|fieldset|form|frame|frameset|h1|h2|h3|h4|h5|h6|iframe|noframes|object|ol|p|ul|applet|center|dir|hr|menu|pre)(?!-)\\b)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"entity.name.tag.block.any.html"}},end:"(>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.block.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(</?)((?i:a|abbr|acronym|area|b|base|basefont|bdo|big|br|button|caption|cite|code|col|colgroup|del|dfn|em|font|head|html|i|img|input|ins|isindex|kbd|label|legend|li|link|map|meta|noscript|optgroup|option|param|q|s|samp|script|select|small|span|strike|strong|style|sub|sup|table|tbody|td|textarea|tfoot|th|thead|title|tr|tt|u|var)(?!-)\\b)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"entity.name.tag.inline.any.html"}},end:"(/?>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.inline.any.html",patterns:[{include:"#tag-stuff"}]},{begin:"(</?)([a-zA-Z0-9:-]+)",beginCaptures:{1:{name:"punctuation.definition.tag.begin.html"},2:{name:"entity.name.tag.other.html"}},end:"(/?>)",endCaptures:{1:{name:"punctuation.definition.tag.end.html"}},name:"meta.tag.other.html",patterns:[{include:"#tag-stuff"}]},{include:"#entities"},{match:"<>",name:"invalid.illegal.incomplete.html"},{match:"<",name:"invalid.illegal.bad-angle-bracket.html"}],repository:{entities:{patterns:[{captures:{1:{name:"punctuation.definition.entity.html"},3:{name:"punctuation.definition.entity.html"}},match:"(&)([a-zA-Z0-9]+|#[0-9]+|#x[0-9a-fA-F]+)(;)",name:"constant.character.entity.html"},{match:"&",name:"invalid.illegal.bad-ampersand.html"}]},"string-double-quoted":{begin:'"',beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:'"',endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"string.quoted.double.html",patterns:[{include:"source.vue#vue-interpolations"},{include:"#entities"}]},"string-single-quoted":{begin:"'",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:"'",endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"string.quoted.single.html",patterns:[{include:"source.vue#vue-interpolations"},{include:"#entities"}]},"tag-generic-attribute":{match:"(?<=[^=])\\b([a-zA-Z0-9:\\-_]+)",name:"entity.other.attribute-name.html"},"tag-id-attribute":{begin:"\\b(id)\\b\\s*(=)",captures:{1:{name:"entity.other.attribute-name.id.html"},2:{name:"punctuation.separator.key-value.html"}},end:`(?!\\G)(?<='|"|[^\\s<>/])`,name:"meta.attribute-with-value.id.html",patterns:[{begin:'"',beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},contentName:"meta.toc-list.id.html",end:'"',endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"string.quoted.double.html",patterns:[{include:"source.vue#vue-interpolations"},{include:"#entities"}]},{begin:"'",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},contentName:"meta.toc-list.id.html",end:"'",endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"string.quoted.single.html",patterns:[{include:"source.vue#vue-interpolations"},{include:"#entities"}]},{captures:{0:{name:"meta.toc-list.id.html"}},match:`(?<==)(?:[^\\s<>/'"]|/(?!>))+`,name:"string.unquoted.html"}]},"tag-stuff":{patterns:[{include:"#vue-directives"},{include:"#tag-id-attribute"},{include:"#tag-generic-attribute"},{include:"#string-double-quoted"},{include:"#string-single-quoted"},{include:"#unquoted-attribute"}]},"unquoted-attribute":{match:`(?<==)(?:[^\\s<>/'"]|/(?!>))+`,name:"string.unquoted.html"},"vue-directives":{begin:"(?:\\b(v-)|(:|@|#))([a-zA-Z0-9\\-_]+)(?:\\:([a-zA-Z\\-_]+))?(?:\\.([a-zA-Z\\-_]+))*\\s*(=)",captures:{1:{name:"entity.other.attribute-name.html"},2:{name:"punctuation.separator.key-value.html"},3:{name:"entity.other.attribute-name.html"},4:{name:"entity.other.attribute-name.html"},5:{name:"entity.other.attribute-name.html"},6:{name:"punctuation.separator.key-value.html"}},end:"(?<='|\")|(?=[\\s<>`])",name:"meta.directive.vue",patterns:[{begin:"`",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:"`",endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"source.directive.vue",patterns:[{include:"source.js#expression"}]},{begin:'"',beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:'"',endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"source.directive.vue",patterns:[{include:"source.js#expression"}]},{begin:"'",beginCaptures:{0:{name:"punctuation.definition.string.begin.html"}},end:"'",endCaptures:{0:{name:"punctuation.definition.string.end.html"}},name:"source.directive.vue",patterns:[{include:"source.js#expression"}]}]}},scopeName:"text.html.vue-html",embeddedLangs:["vue","javascript"]});var d=[...t,...e,n];export{d as default};
@@ -1,2 +1,2 @@
1
- import{_ as Me}from"./zjxoDR5L.js";import{d as U,a as B,ac as he,o as u,h as T,j as y,k as s,aa as E,f as c,v as z,t as C,m as w,G as F,p as S,i as _,F as L,n as H,x as ie,a6 as _e,at as ve,R as ge,aQ as Ce,L as ce,M as de,V as Te,aR as ye,aS as be,_ as X,y as Oe,z as Ne,aC as xe,aT as Ve,aU as Ae,aV as Pe,au as Be,a2 as Le,I as je,az as ue,ay as Re,aW as Ee,a9 as De,r as K,ah as He,l as Fe,ab as Ue,Y as qe,Z as We,S as Ke,aX as me}from"./ciodjZaS.js";import{_ as Ye,u as $e,a as Ge}from"./Di9lD2rK.js";import{_ as Xe}from"./DwdKwQHN.js";import{_ as Qe}from"./zLQhdF7m.js";import{_ as we}from"./Dv0NFAnW.js";import{_ as Ze}from"./D4Ks82zD.js";import{_ as Je}from"./Bi99gj7u.js";import{_ as et}from"./BZvh3yot.js";import{_ as tt}from"./CE84j0J9.js";import{_ as nt}from"./DYx1ZwvQ.js";import{_ as it}from"./CLVHkiJk.js";import"./BWPbreBU.js";import"./yFeWtr-M.js";const ot={flex:"~ col gap2","flex-auto":"","of-hidden":"",px1:""},st={"gap-1t":"",flex:"","items-center":"","text-ellipsis":"","ws-nowrap":"","text-lg":""},rt={key:2},lt=s("div",{"flex-auto":""},null,-1),at={key:1,flex:"~ gap-2",title:"Documentation"},ct=s("span",{"i-carbon-link":"","text-lg":"",op50:""},null,-1),dt={key:2,flex:"~ gap-2"},ut=s("span",{"i-carbon-logo-github":"","text-lg":"",op50:""},null,-1),mt={key:0,flex:"~ gap-4 items-center"},ft={flex:"~ gap-1 items-center",op50:""},pt={flex:"~ gap-1 items-center",op50:""},ht={flex:"~ col","items-end":""},_t={key:0,"h-20":"","w-20":"",flex:"","flex-none":"",rounded:"","bg-gray:3":"",p4:""},vt=["src","alt"],gt=s("div",{"i-carbon-cube":"",ma:"","text-4xl":"",op30:""},null,-1),yt={key:1,flex:"~",mt2:"","flex-auto":"","items-end":"","justify-end":""},bt=["src"],xt=s("div",{"flex-auto":""},null,-1),$t={flex:"","justify-end":""},wt="https://api.nuxtjs.org/api/ipx/s_80,f_webp/gh/nuxt/modules/main/icons/",kt="https://api.nuxtjs.org/api/ipx/s_44,f_webp/gh_avatar/",It="https://github.com/",St="https://www.npmjs.com/package/",oe=U({__name:"ModuleItemBase",props:{mod:{},info:{},compact:{type:Boolean},maintainers:{type:Boolean,default:!0}},setup(e){const t=e,n=B(()=>({...t.mod?.meta,...t.mod,...t.info})),o=he();return(i,r)=>{const l=ie,d=_e,a=ve;return u(),T(a,{p4:"",flex:"~ gap2"},{default:y(()=>[s("div",ot,[E(i.$slots,"main",{},()=>[s("div",st,[i.mod.isPackageModule?(u(),T(l,{key:0,to:St+(c(n).npm||c(n).name),target:"_blank",hover:"underline text-primary"},{default:y(()=>[z(C(c(n).name),1)]),_:1},8,["to"])):i.mod.entryPath?(u(),w("button",{key:1,role:"button",hover:"underline text-primary",onClick:r[0]||(r[0]=m=>c(o)(i.mod.entryPath))},C(c(n).name),1)):(u(),w("span",rt,C(c(n).name),1)),E(i.$slots,"badge")]),c(n).description?(u(),w("div",{key:0,class:F(i.compact?"ws-nowrap of-hidden truncate":"line-clamp-2"),"mt--1":"","text-sm":"",op50:""},C(c(n).description),3)):S("",!0),lt,c(n).website?(u(),w("div",at,[ct,_(l,{to:c(n).website,target:"_blank","of-hidden":"",truncate:"","ws-nowrap":"","text-sm":"",op50:"",hover:"op100 underline text-primary"},{default:y(()=>[z(C(c(n).website.replace(/^https?:\/\//,"")),1)]),_:1},8,["to"])])):S("",!0),c(n).github?(u(),w("div",dt,[ut,_(l,{to:c(n).github,target:"_blank","of-hidden":"",truncate:"","ws-nowrap":"","text-sm":"",op50:"",hover:"op100 underline text-primary"},{default:y(()=>[z(C(c(n).github.replace(/^https?:\/\/github.com\//,"")),1)]),_:1},8,["to"])])):S("",!0)]),E(i.$slots,"items"),c(n).stats?(u(),w("div",mt,[s("div",ft,[_(d,{icon:"carbon-star","text-lg":""}),s("span",null,C(c(n).stats.stars),1)]),s("div",pt,[_(d,{icon:"carbon-download","text-lg":""}),s("span",null,C(c(n).stats.downloads),1)])])):S("",!0)]),s("div",ht,[c(n).icon||i.mod.isPackageModule?(u(),w("div",_t,[c(n).icon?(u(),w("img",{key:0,src:wt+c(n).icon,alt:i.mod.name,ma:""},null,8,vt)):S("",!0),gt])):S("",!0),c(n).maintainers?.length&&i.maintainers?(u(),w("div",yt,[(u(!0),w(L,null,H(c(n).maintainers,m=>(u(),T(l,{key:m.name,target:"_blank",to:It+m.github,title:m.name},{default:y(()=>[s("img",{src:kt+m.github,"h-6":"","w-6":"","rounded-full":""},null,8,bt)]),_:2},1032,["to","title"]))),128))])):S("",!0),i.$slots.actions?(u(),w(L,{key:2},[xt,s("div",$t,[E(i.$slots,"actions")])],64)):S("",!0)])]),_:3})}}}),zt={key:0,flex:"~ gap-2",title:"Open on filesystem"},Mt=s("span",{"i-carbon-folder-move-to":"","text-lg":"",op50:""},null,-1),Ct=s("span",{"i-carbon-circle-dash":"","animate-spin":"","text-lg":"",op50:""},null,-1),Tt=s("code",{"text-sm":"",op50:""},"Upgrading...",-1),Ot={key:1,"mx--2":""},Nt=["onClick"],Vt=s("span",{"i-carbon-intent-request-active":"","text-lg":"","text-primary":""},null,-1),At=s("code",{"text-xs":""},"Update installed, click to restart",-1),Pt=[Vt,At],Bt={key:2,"mx--2":""},Lt=["onClick"],jt=s("span",{"i-carbon-intent-request-upgrade":"","text-lg":"",op50:""},null,-1),Rt={op50:""},Et=s("div",{"i-carbon-arrow-right":"",op50:""},null,-1),Dt={"text-green":""},Ht={key:3,flex:"~ gap-2","items-center":"",title:"NPM"},Ft=s("span",{"i-carbon-cube":"","text-lg":"",op50:""},null,-1),Ut={"text-sm":"",op50:""},qt=U({__name:"ModuleItem",props:{mod:{}},setup(e){const t=e,n=B(()=>t.mod.info),o=B(()=>({...t.mod?.meta,...t.mod,...n.value})),i=ge();return(r,l)=>{const d=Me,a=ie,m=Ye,h=oe;return u(),T(h,{mod:r.mod,info:c(n)},{items:y(()=>[r.mod.entryPath?(u(),w("div",zt,[Mt,_(d,{filepath:r.mod.entryPath,"text-sm":"",op50:"",hover:"text-primary op100"},null,8,["filepath"])])):S("",!0),c(o).npm?(u(),T(m,{key:c(o).npm,"package-name":c(o).npm,options:{dev:!0}},{default:y(({info:g,update:v,state:p,id:I,restart:b})=>[p==="running"?(u(),T(a,{key:0,flex:"~ gap-2","animate-pulse":"","items-center":"",to:I?"/modules/terminals":void 0,onClick:$=>I?i.value=I:void 0},{default:y(()=>[Ct,Tt]),_:2},1032,["to","onClick"])):p==="updated"?(u(),w("div",Ot,[s("button",{flex:"~ gap-2",hover:"bg-primary/20","items-center":"",rounded:"","bg-primary:10":"",px2:"","text-sm":"","text-primary":"",onClick:b},Pt,8,Nt)])):g?.needsUpdate?(u(),w("div",Bt,[s("button",{flex:"~ gap-2",title:"Click to upgrade","items-center":"",rounded:"",px2:"","text-sm":"",hover:"bg-active",onClick:$=>v()},[jt,s("code",Rt,"v"+C(g.current),1),Et,s("code",Dt,"v"+C(g.latest),1)],8,Lt)])):g?.latest?(u(),w("div",Ht,[Ft,s("code",Ut,"v"+C(g.current),1)])):S("",!0)]),_:1},8,["package-name"])):S("",!0)]),_:1},8,["mod","info"])}}}),Wt=U({__name:"ModuleItemInstall",props:{item:{}},emits:["start"],setup(e,{emit:t}){const n=e,o=t,i=$e(),r=B(()=>i.value.find(h=>h.name===n.item.npm)),l=B(()=>r.value&&r.value.isPackageModule),d=B(()=>r.value&&r.value.isPackageModule&&r.value.isUninstallable);async function a(h,g){const v=g==="install"?ce.installNuxtModule:ce.uninstallNuxtModule,p=await v(await de(),h.npm,!0);Te(`modules:${g}`,{moduleName:h.npm}),p.commands&&await ye.start(h,p,g)&&(be.value.push({name:h.npm,info:h,processId:p.processId}),o("start"),await v(await de(),h.npm,!1))}const m={};return(h,g)=>{const v=Je,p=X,I=we,b=oe;return u(),T(b,{mod:m,role:c(l)?"":"button",info:h.item,mb2:"","h-full":"",class:F(c(l)?"border-dashed op75":"hover:bg-active!"),compact:!0,onClick:g[1]||(g[1]=$=>c(l)?null:a(h.item,"install"))},Ce({_:2},[c(l)?{name:"badge",fn:y(()=>[_(v,{n:"green",textContent:"Installed"}),c(d)?(u(),T(I,{key:0,n:"sm green"},{trigger:y(({click:$})=>[_(p,{icon:"carbon-overflow-menu-vertical",border:!1,onClick:k=>$()},null,8,["onClick"])]),default:y(()=>[_(p,{icon:"carbon-trash-can",n:"red",onClick:g[0]||(g[0]=$=>a(h.item,"uninstall"))},{default:y(()=>[z(" Uninstall ")]),_:1})]),_:1})):S("",!0)]),key:"0"}:void 0]),1032,["role","info","class"])}}});function Kt(){var e=window.navigator.userAgent,t=e.indexOf("MSIE ");if(t>0)return parseInt(e.substring(t+5,e.indexOf(".",t)),10);var n=e.indexOf("Trident/");if(n>0){var o=e.indexOf("rv:");return parseInt(e.substring(o+3,e.indexOf(".",o)),10)}var i=e.indexOf("Edge/");return i>0?parseInt(e.substring(i+5,e.indexOf(".",i)),10):-1}let Y;function J(){J.init||(J.init=!0,Y=Kt()!==-1)}var Q={name:"ResizeObserver",props:{emitOnMount:{type:Boolean,default:!1},ignoreWidth:{type:Boolean,default:!1},ignoreHeight:{type:Boolean,default:!1}},emits:["notify"],mounted(){J(),xe(()=>{this._w=this.$el.offsetWidth,this._h=this.$el.offsetHeight,this.emitOnMount&&this.emitSize()});const e=document.createElement("object");this._resizeObject=e,e.setAttribute("aria-hidden","true"),e.setAttribute("tabindex",-1),e.onload=this.addResizeHandlers,e.type="text/html",Y&&this.$el.appendChild(e),e.data="about:blank",Y||this.$el.appendChild(e)},beforeUnmount(){this.removeResizeHandlers()},methods:{compareAndNotify(){(!this.ignoreWidth&&this._w!==this.$el.offsetWidth||!this.ignoreHeight&&this._h!==this.$el.offsetHeight)&&(this._w=this.$el.offsetWidth,this._h=this.$el.offsetHeight,this.emitSize())},emitSize(){this.$emit("notify",{width:this._w,height:this._h})},addResizeHandlers(){this._resizeObject.contentDocument.defaultView.addEventListener("resize",this.compareAndNotify),this.compareAndNotify()},removeResizeHandlers(){this._resizeObject&&this._resizeObject.onload&&(!Y&&this._resizeObject.contentDocument&&this._resizeObject.contentDocument.defaultView.removeEventListener("resize",this.compareAndNotify),this.$el.removeChild(this._resizeObject),this._resizeObject.onload=null,this._resizeObject=null)}}};const Yt=Ve();Oe("data-v-b329ee4c");const Gt={class:"resize-observer",tabindex:"-1"};Ne();const Xt=Yt((e,t,n,o,i,r)=>(u(),T("div",Gt)));Q.render=Xt;Q.__scopeId="data-v-b329ee4c";Q.__file="src/components/ResizeObserver.vue";function G(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?G=function(t){return typeof t}:G=function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},G(e)}function Qt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Zt(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}function Jt(e,t,n){return t&&Zt(e.prototype,t),e}function fe(e){return en(e)||tn(e)||nn(e)||on()}function en(e){if(Array.isArray(e))return ee(e)}function tn(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function nn(e,t){if(e){if(typeof e=="string")return ee(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ee(e,t)}}function ee(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,o=new Array(t);n<t;n++)o[n]=e[n];return o}function on(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
1
+ import{_ as Me}from"./BI3hykgO.js";import{d as U,a as B,ac as he,o as u,h as T,j as y,k as s,aa as E,f as c,v as z,t as C,m as w,G as F,p as S,i as _,F as L,n as H,x as ie,a6 as _e,at as ve,R as ge,aQ as Ce,L as ce,M as de,V as Te,aR as ye,aS as be,_ as X,y as Oe,z as Ne,aC as xe,aT as Ve,aU as Ae,aV as Pe,au as Be,a2 as Le,I as je,az as ue,ay as Re,aW as Ee,a9 as De,r as K,ah as He,l as Fe,ab as Ue,Y as qe,Z as We,S as Ke,aX as me}from"./C_tLznPO.js";import{_ as Ye,u as $e,a as Ge}from"./BiWf_U1D.js";import{_ as Xe}from"./DqpvVAaa.js";import{_ as Qe}from"./B1veJI6T.js";import{_ as we}from"./DJg41Obz.js";import{_ as Ze}from"./BHh_UM9T.js";import{_ as Je}from"./D4V9JMY9.js";import{_ as et}from"./CIvuwNIv.js";import{_ as tt}from"./Dm9RYIcI.js";import{_ as nt}from"./CCJYS4Qc.js";import{_ as it}from"./BOV_C5BD.js";import"./BKeomq25.js";import"./CO7Eo6nF.js";const ot={flex:"~ col gap2","flex-auto":"","of-hidden":"",px1:""},st={"gap-1t":"",flex:"","items-center":"","text-ellipsis":"","ws-nowrap":"","text-lg":""},rt={key:2},lt=s("div",{"flex-auto":""},null,-1),at={key:1,flex:"~ gap-2",title:"Documentation"},ct=s("span",{"i-carbon-link":"","text-lg":"",op50:""},null,-1),dt={key:2,flex:"~ gap-2"},ut=s("span",{"i-carbon-logo-github":"","text-lg":"",op50:""},null,-1),mt={key:0,flex:"~ gap-4 items-center"},ft={flex:"~ gap-1 items-center",op50:""},pt={flex:"~ gap-1 items-center",op50:""},ht={flex:"~ col","items-end":""},_t={key:0,"h-20":"","w-20":"",flex:"","flex-none":"",rounded:"","bg-gray:3":"",p4:""},vt=["src","alt"],gt=s("div",{"i-carbon-cube":"",ma:"","text-4xl":"",op30:""},null,-1),yt={key:1,flex:"~",mt2:"","flex-auto":"","items-end":"","justify-end":""},bt=["src"],xt=s("div",{"flex-auto":""},null,-1),$t={flex:"","justify-end":""},wt="https://api.nuxtjs.org/api/ipx/s_80,f_webp/gh/nuxt/modules/main/icons/",kt="https://api.nuxtjs.org/api/ipx/s_44,f_webp/gh_avatar/",It="https://github.com/",St="https://www.npmjs.com/package/",oe=U({__name:"ModuleItemBase",props:{mod:{},info:{},compact:{type:Boolean},maintainers:{type:Boolean,default:!0}},setup(e){const t=e,n=B(()=>({...t.mod?.meta,...t.mod,...t.info})),o=he();return(i,r)=>{const l=ie,d=_e,a=ve;return u(),T(a,{p4:"",flex:"~ gap2"},{default:y(()=>[s("div",ot,[E(i.$slots,"main",{},()=>[s("div",st,[i.mod.isPackageModule?(u(),T(l,{key:0,to:St+(c(n).npm||c(n).name),target:"_blank",hover:"underline text-primary"},{default:y(()=>[z(C(c(n).name),1)]),_:1},8,["to"])):i.mod.entryPath?(u(),w("button",{key:1,role:"button",hover:"underline text-primary",onClick:r[0]||(r[0]=m=>c(o)(i.mod.entryPath))},C(c(n).name),1)):(u(),w("span",rt,C(c(n).name),1)),E(i.$slots,"badge")]),c(n).description?(u(),w("div",{key:0,class:F(i.compact?"ws-nowrap of-hidden truncate":"line-clamp-2"),"mt--1":"","text-sm":"",op50:""},C(c(n).description),3)):S("",!0),lt,c(n).website?(u(),w("div",at,[ct,_(l,{to:c(n).website,target:"_blank","of-hidden":"",truncate:"","ws-nowrap":"","text-sm":"",op50:"",hover:"op100 underline text-primary"},{default:y(()=>[z(C(c(n).website.replace(/^https?:\/\//,"")),1)]),_:1},8,["to"])])):S("",!0),c(n).github?(u(),w("div",dt,[ut,_(l,{to:c(n).github,target:"_blank","of-hidden":"",truncate:"","ws-nowrap":"","text-sm":"",op50:"",hover:"op100 underline text-primary"},{default:y(()=>[z(C(c(n).github.replace(/^https?:\/\/github.com\//,"")),1)]),_:1},8,["to"])])):S("",!0)]),E(i.$slots,"items"),c(n).stats?(u(),w("div",mt,[s("div",ft,[_(d,{icon:"carbon-star","text-lg":""}),s("span",null,C(c(n).stats.stars),1)]),s("div",pt,[_(d,{icon:"carbon-download","text-lg":""}),s("span",null,C(c(n).stats.downloads),1)])])):S("",!0)]),s("div",ht,[c(n).icon||i.mod.isPackageModule?(u(),w("div",_t,[c(n).icon?(u(),w("img",{key:0,src:wt+c(n).icon,alt:i.mod.name,ma:""},null,8,vt)):S("",!0),gt])):S("",!0),c(n).maintainers?.length&&i.maintainers?(u(),w("div",yt,[(u(!0),w(L,null,H(c(n).maintainers,m=>(u(),T(l,{key:m.name,target:"_blank",to:It+m.github,title:m.name},{default:y(()=>[s("img",{src:kt+m.github,"h-6":"","w-6":"","rounded-full":""},null,8,bt)]),_:2},1032,["to","title"]))),128))])):S("",!0),i.$slots.actions?(u(),w(L,{key:2},[xt,s("div",$t,[E(i.$slots,"actions")])],64)):S("",!0)])]),_:3})}}}),zt={key:0,flex:"~ gap-2",title:"Open on filesystem"},Mt=s("span",{"i-carbon-folder-move-to":"","text-lg":"",op50:""},null,-1),Ct=s("span",{"i-carbon-circle-dash":"","animate-spin":"","text-lg":"",op50:""},null,-1),Tt=s("code",{"text-sm":"",op50:""},"Upgrading...",-1),Ot={key:1,"mx--2":""},Nt=["onClick"],Vt=s("span",{"i-carbon-intent-request-active":"","text-lg":"","text-primary":""},null,-1),At=s("code",{"text-xs":""},"Update installed, click to restart",-1),Pt=[Vt,At],Bt={key:2,"mx--2":""},Lt=["onClick"],jt=s("span",{"i-carbon-intent-request-upgrade":"","text-lg":"",op50:""},null,-1),Rt={op50:""},Et=s("div",{"i-carbon-arrow-right":"",op50:""},null,-1),Dt={"text-green":""},Ht={key:3,flex:"~ gap-2","items-center":"",title:"NPM"},Ft=s("span",{"i-carbon-cube":"","text-lg":"",op50:""},null,-1),Ut={"text-sm":"",op50:""},qt=U({__name:"ModuleItem",props:{mod:{}},setup(e){const t=e,n=B(()=>t.mod.info),o=B(()=>({...t.mod?.meta,...t.mod,...n.value})),i=ge();return(r,l)=>{const d=Me,a=ie,m=Ye,h=oe;return u(),T(h,{mod:r.mod,info:c(n)},{items:y(()=>[r.mod.entryPath?(u(),w("div",zt,[Mt,_(d,{filepath:r.mod.entryPath,"text-sm":"",op50:"",hover:"text-primary op100"},null,8,["filepath"])])):S("",!0),c(o).npm?(u(),T(m,{key:c(o).npm,"package-name":c(o).npm,options:{dev:!0}},{default:y(({info:g,update:v,state:p,id:I,restart:b})=>[p==="running"?(u(),T(a,{key:0,flex:"~ gap-2","animate-pulse":"","items-center":"",to:I?"/modules/terminals":void 0,onClick:$=>I?i.value=I:void 0},{default:y(()=>[Ct,Tt]),_:2},1032,["to","onClick"])):p==="updated"?(u(),w("div",Ot,[s("button",{flex:"~ gap-2",hover:"bg-primary/20","items-center":"",rounded:"","bg-primary:10":"",px2:"","text-sm":"","text-primary":"",onClick:b},Pt,8,Nt)])):g?.needsUpdate?(u(),w("div",Bt,[s("button",{flex:"~ gap-2",title:"Click to upgrade","items-center":"",rounded:"",px2:"","text-sm":"",hover:"bg-active",onClick:$=>v()},[jt,s("code",Rt,"v"+C(g.current),1),Et,s("code",Dt,"v"+C(g.latest),1)],8,Lt)])):g?.latest?(u(),w("div",Ht,[Ft,s("code",Ut,"v"+C(g.current),1)])):S("",!0)]),_:1},8,["package-name"])):S("",!0)]),_:1},8,["mod","info"])}}}),Wt=U({__name:"ModuleItemInstall",props:{item:{}},emits:["start"],setup(e,{emit:t}){const n=e,o=t,i=$e(),r=B(()=>i.value.find(h=>h.name===n.item.npm)),l=B(()=>r.value&&r.value.isPackageModule),d=B(()=>r.value&&r.value.isPackageModule&&r.value.isUninstallable);async function a(h,g){const v=g==="install"?ce.installNuxtModule:ce.uninstallNuxtModule,p=await v(await de(),h.npm,!0);Te(`modules:${g}`,{moduleName:h.npm}),p.commands&&await ye.start(h,p,g)&&(be.value.push({name:h.npm,info:h,processId:p.processId}),o("start"),await v(await de(),h.npm,!1))}const m={};return(h,g)=>{const v=Je,p=X,I=we,b=oe;return u(),T(b,{mod:m,role:c(l)?"":"button",info:h.item,mb2:"","h-full":"",class:F(c(l)?"border-dashed op75":"hover:bg-active!"),compact:!0,onClick:g[1]||(g[1]=$=>c(l)?null:a(h.item,"install"))},Ce({_:2},[c(l)?{name:"badge",fn:y(()=>[_(v,{n:"green",textContent:"Installed"}),c(d)?(u(),T(I,{key:0,n:"sm green"},{trigger:y(({click:$})=>[_(p,{icon:"carbon-overflow-menu-vertical",border:!1,onClick:k=>$()},null,8,["onClick"])]),default:y(()=>[_(p,{icon:"carbon-trash-can",n:"red",onClick:g[0]||(g[0]=$=>a(h.item,"uninstall"))},{default:y(()=>[z(" Uninstall ")]),_:1})]),_:1})):S("",!0)]),key:"0"}:void 0]),1032,["role","info","class"])}}});function Kt(){var e=window.navigator.userAgent,t=e.indexOf("MSIE ");if(t>0)return parseInt(e.substring(t+5,e.indexOf(".",t)),10);var n=e.indexOf("Trident/");if(n>0){var o=e.indexOf("rv:");return parseInt(e.substring(o+3,e.indexOf(".",o)),10)}var i=e.indexOf("Edge/");return i>0?parseInt(e.substring(i+5,e.indexOf(".",i)),10):-1}let Y;function J(){J.init||(J.init=!0,Y=Kt()!==-1)}var Q={name:"ResizeObserver",props:{emitOnMount:{type:Boolean,default:!1},ignoreWidth:{type:Boolean,default:!1},ignoreHeight:{type:Boolean,default:!1}},emits:["notify"],mounted(){J(),xe(()=>{this._w=this.$el.offsetWidth,this._h=this.$el.offsetHeight,this.emitOnMount&&this.emitSize()});const e=document.createElement("object");this._resizeObject=e,e.setAttribute("aria-hidden","true"),e.setAttribute("tabindex",-1),e.onload=this.addResizeHandlers,e.type="text/html",Y&&this.$el.appendChild(e),e.data="about:blank",Y||this.$el.appendChild(e)},beforeUnmount(){this.removeResizeHandlers()},methods:{compareAndNotify(){(!this.ignoreWidth&&this._w!==this.$el.offsetWidth||!this.ignoreHeight&&this._h!==this.$el.offsetHeight)&&(this._w=this.$el.offsetWidth,this._h=this.$el.offsetHeight,this.emitSize())},emitSize(){this.$emit("notify",{width:this._w,height:this._h})},addResizeHandlers(){this._resizeObject.contentDocument.defaultView.addEventListener("resize",this.compareAndNotify),this.compareAndNotify()},removeResizeHandlers(){this._resizeObject&&this._resizeObject.onload&&(!Y&&this._resizeObject.contentDocument&&this._resizeObject.contentDocument.defaultView.removeEventListener("resize",this.compareAndNotify),this.$el.removeChild(this._resizeObject),this._resizeObject.onload=null,this._resizeObject=null)}}};const Yt=Ve();Oe("data-v-b329ee4c");const Gt={class:"resize-observer",tabindex:"-1"};Ne();const Xt=Yt((e,t,n,o,i,r)=>(u(),T("div",Gt)));Q.render=Xt;Q.__scopeId="data-v-b329ee4c";Q.__file="src/components/ResizeObserver.vue";function G(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?G=function(t){return typeof t}:G=function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},G(e)}function Qt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Zt(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}function Jt(e,t,n){return t&&Zt(e.prototype,t),e}function fe(e){return en(e)||tn(e)||nn(e)||on()}function en(e){if(Array.isArray(e))return ee(e)}function tn(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function nn(e,t){if(e){if(typeof e=="string")return ee(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ee(e,t)}}function ee(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,o=new Array(t);n<t;n++)o[n]=e[n];return o}function on(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
2
2
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function sn(e){var t;return typeof e=="function"?t={callback:e}:t=e,t}function rn(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o,i,r,l=function(a){for(var m=arguments.length,h=new Array(m>1?m-1:0),g=1;g<m;g++)h[g-1]=arguments[g];if(r=h,!(o&&a===i)){var v=n.leading;typeof v=="function"&&(v=v(a,i)),(!o||a!==i)&&v&&e.apply(void 0,[a].concat(fe(r))),i=a,clearTimeout(o),o=setTimeout(function(){e.apply(void 0,[a].concat(fe(r))),o=0},t)}};return l._clear=function(){clearTimeout(o),o=null},l}function ke(e,t){if(e===t)return!0;if(G(e)==="object"){for(var n in e)if(!ke(e[n],t[n]))return!1;return!0}return!1}var ln=function(){function e(t,n,o){Qt(this,e),this.el=t,this.observer=null,this.frozen=!1,this.createObserver(n,o)}return Jt(e,[{key:"createObserver",value:function(n,o){var i=this;if(this.observer&&this.destroyObserver(),!this.frozen){if(this.options=sn(n),this.callback=function(d,a){i.options.callback(d,a),d&&i.options.once&&(i.frozen=!0,i.destroyObserver())},this.callback&&this.options.throttle){var r=this.options.throttleOptions||{},l=r.leading;this.callback=rn(this.callback,this.options.throttle,{leading:function(a){return l==="both"||l==="visible"&&a||l==="hidden"&&!a}})}this.oldResult=void 0,this.observer=new IntersectionObserver(function(d){var a=d[0];if(d.length>1){var m=d.find(function(g){return g.isIntersecting});m&&(a=m)}if(i.callback){var h=a.isIntersecting&&a.intersectionRatio>=i.threshold;if(h===i.oldResult)return;i.oldResult=h,i.callback(h,a)}},this.options.intersection),xe(function(){i.observer&&i.observer.observe(i.el)})}}},{key:"destroyObserver",value:function(){this.observer&&(this.observer.disconnect(),this.observer=null),this.callback&&this.callback._clear&&(this.callback._clear(),this.callback=null)}},{key:"threshold",get:function(){return this.options.intersection&&typeof this.options.intersection.threshold=="number"?this.options.intersection.threshold:0}}]),e}();function Ie(e,t,n){var o=t.value;if(o)if(typeof IntersectionObserver>"u")console.warn("[vue-observe-visibility] IntersectionObserver API is not available in your browser. Please install this polyfill: https://github.com/w3c/IntersectionObserver/tree/master/polyfill");else{var i=new ln(e,o,n);e._vue_visibilityState=i}}function an(e,t,n){var o=t.value,i=t.oldValue;if(!ke(o,i)){var r=e._vue_visibilityState;if(!o){Se(e);return}r?r.createObserver(o,n):Ie(e,{value:o},n)}}function Se(e){var t=e._vue_visibilityState;t&&(t.destroyObserver(),delete e._vue_visibilityState)}var cn={beforeMount:Ie,updated:an,unmounted:Se},dn={itemsLimit:1e3},un=/(auto|scroll)/;function ze(e,t){return e.parentNode===null?t:ze(e.parentNode,t.concat([e]))}var Z=function(t,n){return getComputedStyle(t,null).getPropertyValue(n)},mn=function(t){return Z(t,"overflow")+Z(t,"overflow-y")+Z(t,"overflow-x")},fn=function(t){return un.test(mn(t))};function pe(e){if(e instanceof HTMLElement||e instanceof SVGElement){for(var t=ze(e.parentNode,[]),n=0;n<t.length;n+=1)if(fn(t[n]))return t[n];return document.scrollingElement||document.documentElement}}function te(e){"@babel/helpers - typeof";return te=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},te(e)}var pn={items:{type:Array,required:!0},keyField:{type:String,default:"id"},direction:{type:String,default:"vertical",validator:function(t){return["vertical","horizontal"].includes(t)}},listTag:{type:String,default:"div"},itemTag:{type:String,default:"div"}};function hn(){return this.items.length&&te(this.items[0])!=="object"}var ne=!1;if(typeof window<"u"){ne=!1;try{var _n=Object.defineProperty({},"passive",{get:function(){ne=!0}});window.addEventListener("test",null,_n)}catch{}}let vn=0;var se={name:"RecycleScroller",components:{ResizeObserver:Q},directives:{ObserveVisibility:cn},props:{...pn,itemSize:{type:Number,default:null},gridItems:{type:Number,default:void 0},itemSecondarySize:{type:Number,default:void 0},minItemSize:{type:[Number,String],default:null},sizeField:{type:String,default:"size"},typeField:{type:String,default:"type"},buffer:{type:Number,default:200},pageMode:{type:Boolean,default:!1},prerender:{type:Number,default:0},emitUpdate:{type:Boolean,default:!1},updateInterval:{type:Number,default:0},skipHover:{type:Boolean,default:!1},listTag:{type:String,default:"div"},itemTag:{type:String,default:"div"},listClass:{type:[String,Object,Array],default:""},itemClass:{type:[String,Object,Array],default:""}},emits:["resize","visible","hidden","update","scroll-start","scroll-end"],data(){return{pool:[],totalSize:0,ready:!1,hoverKey:null}},computed:{sizes(){if(this.itemSize===null){const e={"-1":{accumulator:0}},t=this.items,n=this.sizeField,o=this.minItemSize;let i=1e4,r=0,l;for(let d=0,a=t.length;d<a;d++)l=t[d][n]||o,l<i&&(i=l),r+=l,e[d]={accumulator:r,size:l};return this.$_computedMinItemSize=i,e}return[]},simpleArray:hn,itemIndexByKey(){const{keyField:e,items:t}=this,n={};for(let o=0,i=t.length;o<i;o++)n[t[o][e]]=o;return n}},watch:{items(){this.updateVisibleItems(!0)},pageMode(){this.applyPageMode(),this.updateVisibleItems(!1)},sizes:{handler(){this.updateVisibleItems(!1)},deep:!0},gridItems(){this.updateVisibleItems(!0)},itemSecondarySize(){this.updateVisibleItems(!0)}},created(){this.$_startIndex=0,this.$_endIndex=0,this.$_views=new Map,this.$_unusedViews=new Map,this.$_scrollDirty=!1,this.$_lastUpdateScrollPosition=0,this.prerender&&(this.$_prerender=!0,this.updateVisibleItems(!1)),this.gridItems&&!this.itemSize&&console.error("[vue-recycle-scroller] You must provide an itemSize when using gridItems")},mounted(){this.applyPageMode(),this.$nextTick(()=>{this.$_prerender=!1,this.updateVisibleItems(!0),this.ready=!0})},activated(){const e=this.$_lastUpdateScrollPosition;typeof e=="number"&&this.$nextTick(()=>{this.scrollToPosition(e)})},beforeUnmount(){this.removeListeners()},methods:{addView(e,t,n,o,i){const r=Ae({id:vn++,index:t,used:!0,key:o,type:i}),l=Pe({item:n,position:0,nr:r});return e.push(l),l},unuseView(e,t=!1){const n=this.$_unusedViews,o=e.nr.type;let i=n.get(o);i||(i=[],n.set(o,i)),i.push(e),t||(e.nr.used=!1,e.position=-9999)},handleResize(){this.$emit("resize"),this.ready&&this.updateVisibleItems(!1)},handleScroll(e){if(!this.$_scrollDirty){if(this.$_scrollDirty=!0,this.$_updateTimeout)return;const t=()=>requestAnimationFrame(()=>{this.$_scrollDirty=!1;const{continuous:n}=this.updateVisibleItems(!1,!0);n||(clearTimeout(this.$_refreshTimout),this.$_refreshTimout=setTimeout(this.handleScroll,this.updateInterval+100))});t(),this.updateInterval&&(this.$_updateTimeout=setTimeout(()=>{this.$_updateTimeout=0,this.$_scrollDirty&&t()},this.updateInterval))}},handleVisibilityChange(e,t){this.ready&&(e||t.boundingClientRect.width!==0||t.boundingClientRect.height!==0?(this.$emit("visible"),requestAnimationFrame(()=>{this.updateVisibleItems(!1)})):this.$emit("hidden"))},updateVisibleItems(e,t=!1){const n=this.itemSize,o=this.gridItems||1,i=this.itemSecondarySize||n,r=this.$_computedMinItemSize,l=this.typeField,d=this.simpleArray?null:this.keyField,a=this.items,m=a.length,h=this.sizes,g=this.$_views,v=this.$_unusedViews,p=this.pool,I=this.itemIndexByKey;let b,$,k,N,V;if(!m)b=$=N=V=k=0;else if(this.$_prerender)b=N=0,$=V=Math.min(this.prerender,a.length),k=null;else{const x=this.getScroll();if(t){let O=x.start-this.$_lastUpdateScrollPosition;if(O<0&&(O=-O),n===null&&O<r||O<n)return{continuous:!0}}this.$_lastUpdateScrollPosition=x.start;const A=this.buffer;x.start-=A,x.end+=A;let M=0;if(this.$refs.before&&(M=this.$refs.before.scrollHeight,x.start-=M),this.$refs.after){const O=this.$refs.after.scrollHeight;x.end+=O}if(n===null){let O,q=0,le=m-1,P=~~(m/2),ae;do ae=P,O=h[P].accumulator,O<x.start?q=P:P<m-1&&h[P+1].accumulator>x.start&&(le=P),P=~~((q+le)/2);while(P!==ae);for(P<0&&(P=0),b=P,k=h[m-1].accumulator,$=P;$<m&&h[$].accumulator<x.end;$++);for($===-1?$=a.length-1:($++,$>m&&($=m)),N=b;N<m&&M+h[N].accumulator<x.start;N++);for(V=N;V<m&&M+h[V].accumulator<x.end;V++);}else{b=~~(x.start/n*o);const O=b%o;b-=O,$=Math.ceil(x.end/n*o),N=Math.max(0,Math.floor((x.start-M)/n*o)),V=Math.floor((x.end-M)/n*o),b<0&&(b=0),$>m&&($=m),N<0&&(N=0),V>m&&(V=m),k=Math.ceil(m/o)*n}}$-b>dn.itemsLimit&&this.itemsLimitError(),this.totalSize=k;let f;const j=b<=this.$_endIndex&&$>=this.$_startIndex;if(j)for(let x=0,A=p.length;x<A;x++)f=p[x],f.nr.used&&(e&&(f.nr.index=I[f.item[d]]),(f.nr.index==null||f.nr.index<b||f.nr.index>=$)&&this.unuseView(f));const re=j?null:new Map;let D,R,W;for(let x=b;x<$;x++){D=a[x];const A=d?D[d]:D;if(A==null)throw new Error(`Key is ${A} on item (keyField is '${d}')`);if(f=g.get(A),!n&&!h[x].size){f&&this.unuseView(f);continue}R=D[l];let M=v.get(R),O=!1;if(!f)j?M&&M.length?f=M.pop():f=this.addView(p,x,D,A,R):(W=re.get(R)||0,(!M||W>=M.length)&&(f=this.addView(p,x,D,A,R),this.unuseView(f,!0),M=v.get(R)),f=M[W],re.set(R,W+1)),g.delete(f.nr.key),f.nr.used=!0,f.nr.index=x,f.nr.key=A,f.nr.type=R,g.set(A,f),O=!0;else if(!f.nr.used&&(f.nr.used=!0,O=!0,M)){const q=M.indexOf(f);q!==-1&&M.splice(q,1)}f.item=D,O&&(x===a.length-1&&this.$emit("scroll-end"),x===0&&this.$emit("scroll-start")),n===null?(f.position=h[x-1].accumulator,f.offset=0):(f.position=Math.floor(x/o)*n,f.offset=x%o*i)}return this.$_startIndex=b,this.$_endIndex=$,this.emitUpdate&&this.$emit("update",b,$,N,V),clearTimeout(this.$_sortTimer),this.$_sortTimer=setTimeout(this.sortViews,this.updateInterval+300),{continuous:j}},getListenerTarget(){let e=pe(this.$el);return window.document&&(e===window.document.documentElement||e===window.document.body)&&(e=window),e},getScroll(){const{$el:e,direction:t}=this,n=t==="vertical";let o;if(this.pageMode){const i=e.getBoundingClientRect(),r=n?i.height:i.width;let l=-(n?i.top:i.left),d=n?window.innerHeight:window.innerWidth;l<0&&(d+=l,l=0),l+d>r&&(d=r-l),o={start:l,end:l+d}}else n?o={start:e.scrollTop,end:e.scrollTop+e.clientHeight}:o={start:e.scrollLeft,end:e.scrollLeft+e.clientWidth};return o},applyPageMode(){this.pageMode?this.addListeners():this.removeListeners()},addListeners(){this.listenerTarget=this.getListenerTarget(),this.listenerTarget.addEventListener("scroll",this.handleScroll,ne?{passive:!0}:!1),this.listenerTarget.addEventListener("resize",this.handleResize)},removeListeners(){this.listenerTarget&&(this.listenerTarget.removeEventListener("scroll",this.handleScroll),this.listenerTarget.removeEventListener("resize",this.handleResize),this.listenerTarget=null)},scrollToItem(e){let t;const n=this.gridItems||1;this.itemSize===null?t=e>0?this.sizes[e-1].accumulator:0:t=Math.floor(e/n)*this.itemSize,this.scrollToPosition(t)},scrollToPosition(e){const t=this.direction==="vertical"?{scroll:"scrollTop",start:"top"}:{scroll:"scrollLeft",start:"left"};let n,o,i;if(this.pageMode){const r=pe(this.$el),l=r.tagName==="HTML"?0:r[t.scroll],d=r.getBoundingClientRect(),m=this.$el.getBoundingClientRect()[t.start]-d[t.start];n=r,o=t.scroll,i=e+l+m}else n=this.$el,o=t.scroll,i=e;n[o]=i},itemsLimitError(){throw setTimeout(()=>{console.log("It seems the scroller element isn't scrolling, so it tries to render all the items at once.","Scroller:",this.$el),console.log("Make sure the scroller has a fixed height (or width) and 'overflow-y' (or 'overflow-x') set to 'auto' so it can scroll correctly and only render the items visible in the scroll viewport.")}),new Error("Rendered items limit reached")},sortViews(){this.pool.sort((e,t)=>e.nr.index-t.nr.index)}}};const gn={key:0,ref:"before",class:"vue-recycle-scroller__slot"},yn={key:1,ref:"after",class:"vue-recycle-scroller__slot"};function bn(e,t,n,o,i,r){const l=Be("ResizeObserver"),d=Le("observe-visibility");return je((u(),w("div",{class:F(["vue-recycle-scroller",{ready:i.ready,"page-mode":n.pageMode,[`direction-${e.direction}`]:!0}]),onScrollPassive:t[0]||(t[0]=(...a)=>r.handleScroll&&r.handleScroll(...a))},[e.$slots.before?(u(),w("div",gn,[E(e.$slots,"before")],512)):S("v-if",!0),(u(),T(ue(n.listTag),{ref:"wrapper",style:De({[e.direction==="vertical"?"minHeight":"minWidth"]:i.totalSize+"px"}),class:F(["vue-recycle-scroller__item-wrapper",n.listClass])},{default:y(()=>[(u(!0),w(L,null,H(i.pool,a=>(u(),T(ue(n.itemTag),Re({key:a.nr.id,style:i.ready?{transform:`translate${e.direction==="vertical"?"Y":"X"}(${a.position}px) translate${e.direction==="vertical"?"X":"Y"}(${a.offset}px)`,width:n.gridItems?`${e.direction==="vertical"&&n.itemSecondarySize||n.itemSize}px`:void 0,height:n.gridItems?`${e.direction==="horizontal"&&n.itemSecondarySize||n.itemSize}px`:void 0}:null,class:["vue-recycle-scroller__item-view",[n.itemClass,{hover:!n.skipHover&&i.hoverKey===a.nr.key}]]},Ee(n.skipHover?{}:{mouseenter:()=>{i.hoverKey=a.nr.key},mouseleave:()=>{i.hoverKey=null}})),{default:y(()=>[E(e.$slots,"default",{item:a.item,index:a.nr.index,active:a.nr.used})]),_:2},1040,["style","class"]))),128)),E(e.$slots,"empty")]),_:3},8,["style","class"])),e.$slots.after?(u(),w("div",yn,[E(e.$slots,"after")],512)):S("v-if",!0),_(l,{onNotify:r.handleResize},null,8,["onNotify"])],34)),[[d,r.handleVisibilityChange]])}se.render=bn;se.__file="src/components/RecycleScroller.vue";const xn={"h-full":"",flex:"~ col gap-4"},$n={flex:"~ items-center"},wn={flex:"~ col","w-30":"","of-auto":""},kn={flex:"~ justify-between","w-full":"","text-xs":"",capitalize:"",op75:""},In={"flex-auto":"","of-auto":"",flex:"~ col gap-2",pl6:"",pr4:""},Sn=U({__name:"ModuleInstallList",emits:["close"],setup(e,{emit:t}){const n=t,o=Ge(),i=["downloads","stars","updated","created"],r=K(!1),l=K(i[0]),d={downloads:(v,p)=>v.stats.downloads-p.stats.downloads,stars:(v,p)=>v.stats.stars-p.stats.stars,created:(v,p)=>v.stats.createdAt-p.stats.createdAt,updated:(v,p)=>v.stats.publishedAt-p.stats.publishedAt},a=B(()=>o.value?.toSorted((v,p)=>d[l.value](v,p)*(r.value?1:-1))),m=K(""),h=B(()=>new He(o.value||[],{keys:["name","description","npm","category"],sortFn:(v,p)=>{const I=o.value?.[v.idx],b=o.value?.[p.idx];return I&&b?d[l.value](I,b)*(r.value?1:-1):v.score-p.score},threshold:.2})),g=B(()=>m.value?h.value.search(m.value).map(v=>v.item):a.value);return(v,p)=>{const I=Qe,b=X,$=_e,k=we,N=Ze,V=Wt;return u(),w("div",xn,[_(I,{mx6:"",mt6:"","text-xl":"",op75:"",icon:"i-carbon-intent-request-create",text:"Install Module"}),_(N,{search:c(m),"onUpdate:search":p[1]||(p[1]=f=>Fe(m)?m.value=f:null),"no-padding":"","px-6":"","pb-5":"","pt-2":""},{actions:y(()=>[_(k,{direction:"end",n:"sm primary"},{trigger:y(({click:f})=>[s("div",$n,[_(b,{icon:c(r)?"tabler:sort-ascending":"tabler:sort-descending","h-full":"","rounded-r-none":"",onClick:p[0]||(p[0]=j=>r.value=!c(r))},null,8,["icon"]),_(b,{flex:"~ justify-between","min-w-30":"","border-l-0":"","rounded-l-none":"","px-2":"",capitalize:"",hover:"border-l-1",onClick:j=>f()},{default:y(()=>[z(C(c(l))+" ",1),_($,{icon:"carbon:chevron-down"})]),_:2},1032,["onClick"])])]),default:y(()=>[s("div",wn,[(u(),w(L,null,H(i,f=>_(b,{key:f,border:!1,p2:"",hover:"n-checkbox-hover text-green",onClick:j=>l.value=f},{default:y(()=>[s("span",kn,[z(C(f)+" ",1),c(l)===f?(u(),T($,{key:0,icon:"carbon:checkmark"})):S("",!0)])]),_:2},1032,["onClick"])),64))])]),_:1})]),_:1},8,["search"]),s("div",In,[_(c(se),{class:"scroller",items:c(g),"item-size":200,"key-field":"name"},{default:y(({item:f})=>[_(V,{item:f,onStart:p[2]||(p[2]=j=>n("close"))},null,8,["item"])]),_:1},8,["items"])])])}}}),zn={flex:"~ col gap-2","w-150":"",p4:"",border:"t base"},Mn={capitalize:""},Cn=s("p",{op50:""}," The following command will be executed in your terminal: ",-1),Tn={op50:""},On=s("p",null,[s("span",{op50:""},"After that, Nuxt will "),s("span",{"text-orange":""},"restart automatically"),z(". ")],-1),Nn={flex:"~ gap-3",mt2:"","justify-end":""},Vn=U({__name:"ModuleActionDialog",setup(e){const t=Ue(),n=he(),o={};return(i,r)=>{const l=oe,d=et,a=tt,m=nt,h=qe,g=X,v=We;return u(),T(c(ye),null,{default:y(({resolve:p,args:I})=>[_(v,{"model-value":!0,onClose:b=>p(!1)},{default:y(()=>[_(l,{mod:o,info:I[0],border:"none","w-150":"","n-panel-grids":""},null,8,["info"]),s("div",zn,[s("h2",{"text-xl":"",class:F(I[2]==="install"?"text-primary":"text-red")},[s("span",Mn,C(I[2]),1),z(),s("code",null,C(I[0].name),1),z("? ")],2),Cn,_(d,{code:I[1].commands.join(" "),lang:"bash",px4:"",py2:"",border:"~ base rounded",lines:!1},null,8,["code"]),s("p",Tn,[z(" Then your "),_(a,{role:"button",n:"primary",underline:"",onClick:r[0]||(r[0]=b=>c(n)(c(t)?._nuxtConfigFile)),textContent:"Nuxt config"}),z(" will be updated as: ")]),_(m,{from:I[1].configOriginal,to:I[1].configGenerated,"max-h-80":"","of-auto":"",py2:"",border:"~ base rounded",lang:"ts"},null,8,["from","to"]),On,s("div",Nn,[_(h,{n:"sm amber","flex-auto":"",icon:"i-carbon-data-backup"},{default:y(()=>[z(" Please make sure to backup your project first. ")]),_:1}),_(g,{onClick:b=>p(!1)},{default:y(()=>[z(" Cancel ")]),_:2},1032,["onClick"]),_(g,{n:"solid",capitalize:"",class:F(I[2]==="install"?"n-primary":"n-red"),onClick:b=>p(!0)},{default:y(()=>[z(C(I[2]),1)]),_:2},1032,["class","onClick"])])])]),_:2},1032,["onClose"])]),_:1})}}}),An={class:"markdown-body"},Pn=s("h1",null,"Modules",-1),Bn=s("p",null,[z("Nuxt provides a module system to extend the framework core and simplify integrations. You don’t need to develop everything from scratch or maintain boilerplate if there is already a Nuxt module for it. Adding Nuxt modules is possible using "),s("code",null,"nuxt.config"),z(".")],-1),Ln=s("p",null,[z("You can explore the list of modules on "),s("a",{href:"https://nuxt.com/modules",target:"_blank",rel:"noopener"},"nuxt.com/modules"),z(" or install them directly inside the DevTools.")],-1),jn=s("p",null,[s("a",{href:"https://nuxt.com/docs/guide/concepts/modules",target:"_blank",rel:"noopener"},"Learn more in the documentation")],-1),Rn=[Pn,Bn,Ln,jn],En={__name:"modules",setup(e,{expose:t}){return t({frontmatter:{}}),(o,i)=>(u(),w("div",An,Rn))}},Dn=En,Hn={"h-full":"","w-full":"","of-auto":""},Fn={relative:"","h-20":"","w-20":"",flex:"","flex-none":"",rounded:"","bg-gray:3":"",p3:""},Un=["src","alt"],qn=s("div",{"i-carbon-cube":"",ma:"","text-4xl":"",op30:""},null,-1),Wn={"text-lg":"","group-hover":"text-primary",transition:"",flex:"~ gap-2 items-center"},Kn=s("div",{"i-carbon-circle-dash":"","animate-spin":"","text-xl":"",op75:""},null,-1),Yn={op75:""},Gn=s("div",{"i-carbon-intent-request-create":"","text-4xl":"",op40:"","group-hover":"op75 text-primary",transition:""},null,-1),Xn=s("div",{"text-lg":"",op40:"","group-hover":"op75 text-primary",transition:""}," Install New Module ",-1),Qn={key:0,border:"l base",pos:"fixed bottom-0 right-0 top-0","z-200":"","w-150":"","bg-base":""},Zn="https://api.nuxtjs.org/api/ipx/s_80,f_webp/gh/nuxt/modules/main/icons/",fi=U({__name:"modules",setup(e){const t=K(!1),n=$e(),o=ge(),i=B(()=>n.value.filter(l=>l.isPackageModule)),r=B(()=>n.value.filter(l=>!l.isPackageModule));return Ke(()=>[{id:"action:modules:install",title:"Install a new module",icon:"i-carbon-intent-request-create ",action:()=>{t.value=!0}}]),(l,d)=>{const a=qt,m=ve,h=ie,g=Xe,v=X,p=Sn,I=Vn,b=Dn,$=it;return u(),w(L,null,[s("div",Hn,[_(g,{icon:"carbon-3d-mpr-toggle",text:"Installed Modules","container-class":"grid grid-cols-minmax-400px gap3 px4",padding:!1,description:`Total modules: ${c(i).length}`},{default:y(()=>[(u(!0),w(L,null,H(c(i),k=>(u(),T(a,{key:k.name,mod:k},null,8,["mod"]))),128)),(u(!0),w(L,null,H("processInstallingModules"in l?l.processInstallingModules:c(be),k=>(u(),T(h,{key:k.processId,block:"","min-h-30":"",to:"/modules/terminals",onClick:N=>o.value=k.processId},{default:y(()=>[_(m,{border:"1.5 dashed","h-full":"","animate-pulse":"",p4:"",transition:"",hover:"border-primary",flex:"~ col gap-1 items-center justify-center",role:"button",class:"group"},{default:y(()=>[s("div",Fn,[s("img",{src:Zn+k.info.icon,alt:k.info.name,ma:""},null,8,Un),qn]),s("div",Wn,[Kn,s("span",Yn,"Installing "+C(k.name)+"...",1)])]),_:2},1024)]),_:2},1032,["onClick"]))),128)),_(m,{border:"1.5 dashed","min-h-30":"",p4:"",transition:"",hover:"border-primary",flex:"~ col gap-2 items-center justify-center",role:"button",class:"group",onClick:d[0]||(d[0]=k=>t.value=!0)},{default:y(()=>[Gn,Xn]),_:1})]),_:1},8,["description"]),c(r).length?(u(),T(g,{key:0,icon:"carbon-3d-mpr-toggle",text:"User Modules","container-class":"grid grid-cols-minmax-400px gap3 px4",padding:!1,description:`Total modules: ${c(r).length}`},{default:y(()=>[(u(!0),w(L,null,H(c(r),k=>(u(),w(L,{key:k.meta?.name||k.entryPath},[k.meta?.name||k.entryPath?(u(),T(a,{key:0,mod:k},null,8,["mod"])):S("",!0)],64))),128))]),_:1},8,["description"])):S("",!0),_(me,{name:"fade-in"},{default:y(()=>[c(t)?(u(),w("div",{key:0,class:"fixed bottom-0 left-0 right-0 top-0 z-100","bg-black:20":"","backdrop-blur-2":"",onClick:d[1]||(d[1]=k=>t.value=!1)})):S("",!0)]),_:1}),_(me,{name:"slide-in"},{default:y(()=>[c(t)?(u(),w("div",Qn,[_(v,{icon:"carbon-close",pos:"absolute top-3 right-3 z-10","rounded-full":"","text-xl":"",border:!1,onClick:d[2]||(d[2]=k=>t.value=!1)}),_(p,{onClose:d[3]||(d[3]=k=>t.value=!1)})])):S("",!0)]),_:1}),_(I)]),_($,null,{default:y(()=>[_(b)]),_:1})],64)}}});export{fi as default};