@uptimizr/dashboard 0.3.1 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. package/out/404.html +1 -1
  2. package/out/__next.__PAGE__.txt +2 -2
  3. package/out/__next._full.txt +3 -3
  4. package/out/__next._head.txt +1 -1
  5. package/out/__next._index.txt +2 -2
  6. package/out/__next._tree.txt +2 -2
  7. package/out/_next/static/chunks/06m_64ysu9kn0.js +1 -0
  8. package/out/_next/static/chunks/1fruncg3k-3pu.js +3 -0
  9. package/out/_next/static/chunks/224_scesvd739.js +1 -0
  10. package/out/_next/static/chunks/2_hgfg-cjqw1-.js +1 -0
  11. package/out/_next/static/chunks/2ktxjmx03u9l3.js +1 -0
  12. package/out/_next/static/chunks/2kw33jl_i9o5j.css +3 -0
  13. package/out/_next/static/chunks/30363ptka3vzy.js +1 -0
  14. package/out/_next/static/chunks/39ojyykom0z2r.js +1 -0
  15. package/out/_next/static/chunks/3jha6wlqw8459.js +1 -0
  16. package/out/_not-found/__next._full.txt +2 -2
  17. package/out/_not-found/__next._head.txt +1 -1
  18. package/out/_not-found/__next._index.txt +2 -2
  19. package/out/_not-found/__next._not-found.__PAGE__.txt +1 -1
  20. package/out/_not-found/__next._not-found.txt +1 -1
  21. package/out/_not-found/__next._tree.txt +2 -2
  22. package/out/_not-found.html +1 -1
  23. package/out/_not-found.txt +2 -2
  24. package/out/index.html +1 -1
  25. package/out/index.txt +3 -3
  26. package/package.json +2 -2
  27. package/out/_next/static/chunks/0g_v2zswo4l6f.js +0 -1
  28. package/out/_next/static/chunks/1my2rhysaxjw4.js +0 -3
  29. package/out/_next/static/chunks/1vuq3dos1406d.css +0 -3
  30. package/out/_next/static/chunks/31nbg0n1q43p2.js +0 -1
  31. package/out/_next/static/chunks/3qw6q7d74g5wp.js +0 -1
  32. package/out/_next/static/chunks/3s2d9ymcd0l4e.js +0 -1
  33. /package/out/_next/static/{-UlF345C3V4TG3ZtvR-5_ → 2AsIePMYsPfJoAl46w-g4}/_buildManifest.js +0 -0
  34. /package/out/_next/static/{-UlF345C3V4TG3ZtvR-5_ → 2AsIePMYsPfJoAl46w-g4}/_clientMiddlewareManifest.js +0 -0
  35. /package/out/_next/static/{-UlF345C3V4TG3ZtvR-5_ → 2AsIePMYsPfJoAl46w-g4}/_ssgManifest.js +0 -0
package/out/404.html CHANGED
@@ -1 +1 @@
1
- <!DOCTYPE html><html lang="en" class="space_grotesk_59d6dcf5-module__z_Ctiq__variable jetbrains_mono_38c99671-module__5Dhsuq__variable"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/_next/static/chunks/1vuq3dos1406d.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/1g3z43o3h-024.js"/><script src="/_next/static/chunks/1evp209qbr4cr.js" async=""></script><script src="/_next/static/chunks/28f1onw3nywbz.js" async=""></script><script src="/_next/static/chunks/turbopack-16ab30_1p4vhq.js" async=""></script><script src="/_next/static/chunks/1ek5rtpo6rxev.js" async=""></script><meta name="robots" content="noindex"/><meta name="next-size-adjust" content=""/><title>404: This page could not be found.</title><title>Uptimizr — 3D Scene Analytics</title><meta name="description" content="Open-source analytics dashboard for 3D scenes."/><link rel="icon" href="/icon.svg?icon.08h29dad3pcxg.svg" sizes="any" type="image/svg+xml"/><script src="/_next/static/chunks/0cz1d0mv5g_q7.js" noModule=""></script></head><body><div hidden=""><!--$--><!--/$--></div><div style="font-family:system-ui,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif,&quot;Apple Color Emoji&quot;,&quot;Segoe UI Emoji&quot;;height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding:0 23px 0 0;font-size:24px;font-weight:500;vertical-align:top;line-height:49px">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:49px;margin:0">This page could not be found.</h2></div></div></div><!--$--><!--/$--><script src="/_next/static/chunks/1g3z43o3h-024.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n2:I[16190,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"default\"]\n3:I[62242,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"default\"]\n4:I[1750,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"OutletBoundary\"]\n5:\"$Sreact.suspense\"\n8:I[1750,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"ViewportBoundary\"]\na:I[1750,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"MetadataBoundary\"]\nc:I[19606,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"default\",1]\n:HL[\"/_next/static/chunks/1vuq3dos1406d.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"c\":[\"\",\"_not-found\"],\"q\":\"\",\"i\":false,\"f\":[[[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",16],[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/chunks/1vuq3dos1406d.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-0\",{\"src\":\"/_next/static/chunks/1ek5rtpo6rxev.js\",\"async\":true,\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"en\",\"className\":\"space_grotesk_59d6dcf5-module__z_Ctiq__variable jetbrains_mono_38c99671-module__5Dhsuq__variable\",\"children\":[\"$\",\"body\",null,{\"children\":[\"$\",\"$L2\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L3\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":404}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],[]],\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]}]}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L2\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L3\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:notFound:0:1:props:style\",\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:notFound:0:1:props:children:props:children:1:props:style\",\"children\":404}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:notFound:0:1:props:children:props:children:2:props:style\",\"children\":[\"$\",\"h2\",null,{\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:notFound:0:1:props:children:props:children:2:props:children:props:style\",\"children\":\"This page could not be found.\"}]}]]}]}]],null,[\"$\",\"$L4\",null,{\"children\":[\"$\",\"$5\",null,{\"name\":\"Next.MetadataOutlet\",\"children\":\"$@6\"}]}]]}],{},null,false,null]},null,false,\"$@7\"]},null,false,null],[\"$\",\"$1\",\"h\",{\"children\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],[\"$\",\"$L8\",null,{\"children\":\"$L9\"}],[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$La\",null,{\"children\":[\"$\",\"$5\",null,{\"name\":\"Next.Metadata\",\"children\":\"$Lb\"}]}]}],[\"$\",\"meta\",null,{\"name\":\"next-size-adjust\",\"content\":\"\"}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$c\",[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/chunks/1vuq3dos1406d.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}]]],\"S\":true,\"h\":null,\"s\":\"$undefined\",\"l\":\"$undefined\",\"p\":\"$undefined\",\"d\":\"$undefined\",\"b\":\"-UlF345C3V4TG3ZtvR-5_\"}\n"])</script><script>self.__next_f.push([1,"d:[]\n7:\"$Wd\"\n"])</script><script>self.__next_f.push([1,"9:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\n"])</script><script>self.__next_f.push([1,"e:I[11936,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"IconMark\"]\n6:null\nb:[[\"$\",\"title\",\"0\",{\"children\":\"Uptimizr — 3D Scene Analytics\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"Open-source analytics dashboard for 3D scenes.\"}],[\"$\",\"link\",\"2\",{\"rel\":\"icon\",\"href\":\"/icon.svg?icon.08h29dad3pcxg.svg\",\"sizes\":\"any\",\"type\":\"image/svg+xml\"}],[\"$\",\"$Le\",\"3\",{}]]\n"])</script></body></html>
1
+ <!DOCTYPE html><html lang="en" class="space_grotesk_59d6dcf5-module__z_Ctiq__variable jetbrains_mono_38c99671-module__5Dhsuq__variable"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/_next/static/chunks/2kw33jl_i9o5j.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/1g3z43o3h-024.js"/><script src="/_next/static/chunks/1evp209qbr4cr.js" async=""></script><script src="/_next/static/chunks/28f1onw3nywbz.js" async=""></script><script src="/_next/static/chunks/turbopack-16ab30_1p4vhq.js" async=""></script><script src="/_next/static/chunks/1ek5rtpo6rxev.js" async=""></script><meta name="robots" content="noindex"/><meta name="next-size-adjust" content=""/><title>404: This page could not be found.</title><title>Uptimizr — 3D Scene Analytics</title><meta name="description" content="Open-source analytics dashboard for 3D scenes."/><link rel="icon" href="/icon.svg?icon.08h29dad3pcxg.svg" sizes="any" type="image/svg+xml"/><script src="/_next/static/chunks/0cz1d0mv5g_q7.js" noModule=""></script></head><body><div hidden=""><!--$--><!--/$--></div><div style="font-family:system-ui,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif,&quot;Apple Color Emoji&quot;,&quot;Segoe UI Emoji&quot;;height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding:0 23px 0 0;font-size:24px;font-weight:500;vertical-align:top;line-height:49px">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:49px;margin:0">This page could not be found.</h2></div></div></div><!--$--><!--/$--><script src="/_next/static/chunks/1g3z43o3h-024.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n2:I[16190,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"default\"]\n3:I[62242,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"default\"]\n4:I[1750,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"OutletBoundary\"]\n5:\"$Sreact.suspense\"\n8:I[1750,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"ViewportBoundary\"]\na:I[1750,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"MetadataBoundary\"]\nc:I[19606,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"default\",1]\n:HL[\"/_next/static/chunks/2kw33jl_i9o5j.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"c\":[\"\",\"_not-found\"],\"q\":\"\",\"i\":false,\"f\":[[[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",16],[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/chunks/2kw33jl_i9o5j.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-0\",{\"src\":\"/_next/static/chunks/1ek5rtpo6rxev.js\",\"async\":true,\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"en\",\"className\":\"space_grotesk_59d6dcf5-module__z_Ctiq__variable jetbrains_mono_38c99671-module__5Dhsuq__variable\",\"children\":[\"$\",\"body\",null,{\"children\":[\"$\",\"$L2\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L3\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":404}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],[]],\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]}]}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L2\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L3\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:notFound:0:1:props:style\",\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:notFound:0:1:props:children:props:children:1:props:style\",\"children\":404}],[\"$\",\"div\",null,{\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:notFound:0:1:props:children:props:children:2:props:style\",\"children\":[\"$\",\"h2\",null,{\"style\":\"$0:f:0:1:0:props:children:1:props:children:props:children:props:notFound:0:1:props:children:props:children:2:props:children:props:style\",\"children\":\"This page could not be found.\"}]}]]}]}]],null,[\"$\",\"$L4\",null,{\"children\":[\"$\",\"$5\",null,{\"name\":\"Next.MetadataOutlet\",\"children\":\"$@6\"}]}]]}],{},null,false,null]},null,false,\"$@7\"]},null,false,null],[\"$\",\"$1\",\"h\",{\"children\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],[\"$\",\"$L8\",null,{\"children\":\"$L9\"}],[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$La\",null,{\"children\":[\"$\",\"$5\",null,{\"name\":\"Next.Metadata\",\"children\":\"$Lb\"}]}]}],[\"$\",\"meta\",null,{\"name\":\"next-size-adjust\",\"content\":\"\"}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$c\",[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/chunks/2kw33jl_i9o5j.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}]]],\"S\":true,\"h\":null,\"s\":\"$undefined\",\"l\":\"$undefined\",\"p\":\"$undefined\",\"d\":\"$undefined\",\"b\":\"2AsIePMYsPfJoAl46w-g4\"}\n"])</script><script>self.__next_f.push([1,"d:[]\n7:\"$Wd\"\n"])</script><script>self.__next_f.push([1,"9:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\n"])</script><script>self.__next_f.push([1,"e:I[11936,[\"/_next/static/chunks/1ek5rtpo6rxev.js\"],\"IconMark\"]\n6:null\nb:[[\"$\",\"title\",\"0\",{\"children\":\"Uptimizr — 3D Scene Analytics\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"Open-source analytics dashboard for 3D scenes.\"}],[\"$\",\"link\",\"2\",{\"rel\":\"icon\",\"href\":\"/icon.svg?icon.08h29dad3pcxg.svg\",\"sizes\":\"any\",\"type\":\"image/svg+xml\"}],[\"$\",\"$Le\",\"3\",{}]]\n"])</script></body></html>
@@ -1,9 +1,9 @@
1
1
  1:"$Sreact.fragment"
2
2
  2:I[85960,["/_next/static/chunks/1ek5rtpo6rxev.js"],"ClientPageRoot"]
3
- 3:I[14936,["/_next/static/chunks/1ek5rtpo6rxev.js","/_next/static/chunks/31nbg0n1q43p2.js","/_next/static/chunks/2mleh3pbge181.js","/_next/static/chunks/1my2rhysaxjw4.js"],"default"]
3
+ 3:I[14936,["/_next/static/chunks/1ek5rtpo6rxev.js","/_next/static/chunks/224_scesvd739.js","/_next/static/chunks/2mleh3pbge181.js","/_next/static/chunks/1fruncg3k-3pu.js"],"default"]
4
4
  6:I[1750,["/_next/static/chunks/1ek5rtpo6rxev.js"],"OutletBoundary"]
5
5
  7:"$Sreact.suspense"
6
- 0:{"rsc":["$","$1","c",{"children":[["$","$L2",null,{"Component":"$3","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@4","$@5"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/31nbg0n1q43p2.js","async":true}],["$","script","script-1",{"src":"/_next/static/chunks/2mleh3pbge181.js","async":true}],["$","script","script-2",{"src":"/_next/static/chunks/1my2rhysaxjw4.js","async":true}]],["$","$L6",null,{"children":["$","$7",null,{"name":"Next.MetadataOutlet","children":"$@8"}]}]]}],"isPartial":false,"staleTime":300,"varyParams":null,"buildId":"-UlF345C3V4TG3ZtvR-5_"}
6
+ 0:{"rsc":["$","$1","c",{"children":[["$","$L2",null,{"Component":"$3","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@4","$@5"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/224_scesvd739.js","async":true}],["$","script","script-1",{"src":"/_next/static/chunks/2mleh3pbge181.js","async":true}],["$","script","script-2",{"src":"/_next/static/chunks/1fruncg3k-3pu.js","async":true}]],["$","$L6",null,{"children":["$","$7",null,{"name":"Next.MetadataOutlet","children":"$@8"}]}]]}],"isPartial":false,"staleTime":300,"varyParams":null,"buildId":"2AsIePMYsPfJoAl46w-g4"}
7
7
  4:{}
8
8
  5:"$0:rsc:props:children:0:props:serverProvidedParams:params"
9
9
  8:null
@@ -2,16 +2,16 @@
2
2
  2:I[16190,["/_next/static/chunks/1ek5rtpo6rxev.js"],"default"]
3
3
  3:I[62242,["/_next/static/chunks/1ek5rtpo6rxev.js"],"default"]
4
4
  4:I[85960,["/_next/static/chunks/1ek5rtpo6rxev.js"],"ClientPageRoot"]
5
- 5:I[14936,["/_next/static/chunks/1ek5rtpo6rxev.js","/_next/static/chunks/31nbg0n1q43p2.js","/_next/static/chunks/2mleh3pbge181.js","/_next/static/chunks/1my2rhysaxjw4.js"],"default"]
5
+ 5:I[14936,["/_next/static/chunks/1ek5rtpo6rxev.js","/_next/static/chunks/224_scesvd739.js","/_next/static/chunks/2mleh3pbge181.js","/_next/static/chunks/1fruncg3k-3pu.js"],"default"]
6
6
  8:I[1750,["/_next/static/chunks/1ek5rtpo6rxev.js"],"OutletBoundary"]
7
7
  9:"$Sreact.suspense"
8
8
  b:I[1750,["/_next/static/chunks/1ek5rtpo6rxev.js"],"ViewportBoundary"]
9
9
  d:I[1750,["/_next/static/chunks/1ek5rtpo6rxev.js"],"MetadataBoundary"]
10
10
  f:I[19606,["/_next/static/chunks/1ek5rtpo6rxev.js"],"default",1]
11
- :HL["/_next/static/chunks/1vuq3dos1406d.css","style"]
11
+ :HL["/_next/static/chunks/2kw33jl_i9o5j.css","style"]
12
12
  :HL["/_next/static/media/0c89a48fa5027cee-s.p.2cyn07wtgehh0.woff2","font",{"crossOrigin":"","type":"font/woff2"}]
13
13
  :HL["/_next/static/media/70bc3e132a0a741e-s.p.3t6q91iet4nsy.woff2","font",{"crossOrigin":"","type":"font/woff2"}]
14
- 0:{"P":null,"c":["",""],"q":"","i":false,"f":[[["",{"children":["__PAGE__",{}]},"$undefined","$undefined",16],[["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/1vuq3dos1406d.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","script","script-0",{"src":"/_next/static/chunks/1ek5rtpo6rxev.js","async":true,"nonce":"$undefined"}]],["$","html",null,{"lang":"en","className":"space_grotesk_59d6dcf5-module__z_Ctiq__variable jetbrains_mono_38c99671-module__5Dhsuq__variable","children":["$","body",null,{"children":["$","$L2",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L3",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]]}],{"children":[["$","$1","c",{"children":[["$","$L4",null,{"Component":"$5","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@6","$@7"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/31nbg0n1q43p2.js","async":true,"nonce":"$undefined"}],["$","script","script-1",{"src":"/_next/static/chunks/2mleh3pbge181.js","async":true,"nonce":"$undefined"}],["$","script","script-2",{"src":"/_next/static/chunks/1my2rhysaxjw4.js","async":true,"nonce":"$undefined"}]],["$","$L8",null,{"children":["$","$9",null,{"name":"Next.MetadataOutlet","children":"$@a"}]}]]}],{},null,false,null]},null,false,null],["$","$1","h",{"children":[null,["$","$Lb",null,{"children":"$Lc"}],["$","div",null,{"hidden":true,"children":["$","$Ld",null,{"children":["$","$9",null,{"name":"Next.Metadata","children":"$Le"}]}]}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],false]],"m":"$undefined","G":["$f",[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/1vuq3dos1406d.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]]],"S":true,"h":null,"s":"$undefined","l":"$undefined","p":"$undefined","d":"$undefined","b":"-UlF345C3V4TG3ZtvR-5_"}
14
+ 0:{"P":null,"c":["",""],"q":"","i":false,"f":[[["",{"children":["__PAGE__",{}]},"$undefined","$undefined",16],[["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/2kw33jl_i9o5j.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}],["$","script","script-0",{"src":"/_next/static/chunks/1ek5rtpo6rxev.js","async":true,"nonce":"$undefined"}]],["$","html",null,{"lang":"en","className":"space_grotesk_59d6dcf5-module__z_Ctiq__variable jetbrains_mono_38c99671-module__5Dhsuq__variable","children":["$","body",null,{"children":["$","$L2",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L3",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]]}],{"children":[["$","$1","c",{"children":[["$","$L4",null,{"Component":"$5","serverProvidedParams":{"searchParams":{},"params":{},"promises":["$@6","$@7"]}}],[["$","script","script-0",{"src":"/_next/static/chunks/224_scesvd739.js","async":true,"nonce":"$undefined"}],["$","script","script-1",{"src":"/_next/static/chunks/2mleh3pbge181.js","async":true,"nonce":"$undefined"}],["$","script","script-2",{"src":"/_next/static/chunks/1fruncg3k-3pu.js","async":true,"nonce":"$undefined"}]],["$","$L8",null,{"children":["$","$9",null,{"name":"Next.MetadataOutlet","children":"$@a"}]}]]}],{},null,false,null]},null,false,null],["$","$1","h",{"children":[null,["$","$Lb",null,{"children":"$Lc"}],["$","div",null,{"hidden":true,"children":["$","$Ld",null,{"children":["$","$9",null,{"name":"Next.Metadata","children":"$Le"}]}]}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],false]],"m":"$undefined","G":["$f",[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/2kw33jl_i9o5j.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]]],"S":true,"h":null,"s":"$undefined","l":"$undefined","p":"$undefined","d":"$undefined","b":"2AsIePMYsPfJoAl46w-g4"}
15
15
  6:{}
16
16
  7:"$0:f:0:1:1:children:0:props:children:0:props:serverProvidedParams:params"
17
17
  c:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]]
@@ -3,4 +3,4 @@
3
3
  3:I[1750,["/_next/static/chunks/1ek5rtpo6rxev.js"],"MetadataBoundary"]
4
4
  4:"$Sreact.suspense"
5
5
  5:I[11936,["/_next/static/chunks/1ek5rtpo6rxev.js"],"IconMark"]
6
- 0:{"rsc":["$","$1","h",{"children":[null,["$","$L2",null,{"children":[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]]}],["$","div",null,{"hidden":true,"children":["$","$L3",null,{"children":["$","$4",null,{"name":"Next.Metadata","children":[["$","title","0",{"children":"Uptimizr — 3D Scene Analytics"}],["$","meta","1",{"name":"description","content":"Open-source analytics dashboard for 3D scenes."}],["$","link","2",{"rel":"icon","href":"/icon.svg?icon.08h29dad3pcxg.svg","sizes":"any","type":"image/svg+xml"}],["$","$L5","3",{}]]}]}]}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],"isPartial":false,"staleTime":300,"varyParams":null,"buildId":"-UlF345C3V4TG3ZtvR-5_"}
6
+ 0:{"rsc":["$","$1","h",{"children":[null,["$","$L2",null,{"children":[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]]}],["$","div",null,{"hidden":true,"children":["$","$L3",null,{"children":["$","$4",null,{"name":"Next.Metadata","children":[["$","title","0",{"children":"Uptimizr — 3D Scene Analytics"}],["$","meta","1",{"name":"description","content":"Open-source analytics dashboard for 3D scenes."}],["$","link","2",{"rel":"icon","href":"/icon.svg?icon.08h29dad3pcxg.svg","sizes":"any","type":"image/svg+xml"}],["$","$L5","3",{}]]}]}]}],["$","meta",null,{"name":"next-size-adjust","content":""}]]}],"isPartial":false,"staleTime":300,"varyParams":null,"buildId":"2AsIePMYsPfJoAl46w-g4"}
@@ -1,5 +1,5 @@
1
1
  1:"$Sreact.fragment"
2
2
  2:I[16190,["/_next/static/chunks/1ek5rtpo6rxev.js"],"default"]
3
3
  3:I[62242,["/_next/static/chunks/1ek5rtpo6rxev.js"],"default"]
4
- :HL["/_next/static/chunks/1vuq3dos1406d.css","style"]
5
- 0:{"rsc":["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/1vuq3dos1406d.css","precedence":"next"}],["$","script","script-0",{"src":"/_next/static/chunks/1ek5rtpo6rxev.js","async":true}]],["$","html",null,{"lang":"en","className":"space_grotesk_59d6dcf5-module__z_Ctiq__variable jetbrains_mono_38c99671-module__5Dhsuq__variable","children":["$","body",null,{"children":["$","$L2",null,{"parallelRouterKey":"children","template":["$","$L3",null,{}],"notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]]}]}]}]]}],"isPartial":false,"staleTime":300,"varyParams":null,"buildId":"-UlF345C3V4TG3ZtvR-5_"}
4
+ :HL["/_next/static/chunks/2kw33jl_i9o5j.css","style"]
5
+ 0:{"rsc":["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/chunks/2kw33jl_i9o5j.css","precedence":"next"}],["$","script","script-0",{"src":"/_next/static/chunks/1ek5rtpo6rxev.js","async":true}]],["$","html",null,{"lang":"en","className":"space_grotesk_59d6dcf5-module__z_Ctiq__variable jetbrains_mono_38c99671-module__5Dhsuq__variable","children":["$","body",null,{"children":["$","$L2",null,{"parallelRouterKey":"children","template":["$","$L3",null,{}],"notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]]}]}]}]]}],"isPartial":false,"staleTime":300,"varyParams":null,"buildId":"2AsIePMYsPfJoAl46w-g4"}
@@ -1,4 +1,4 @@
1
- :HL["/_next/static/chunks/1vuq3dos1406d.css","style"]
1
+ :HL["/_next/static/chunks/2kw33jl_i9o5j.css","style"]
2
2
  :HL["/_next/static/media/0c89a48fa5027cee-s.p.2cyn07wtgehh0.woff2","font",{"crossOrigin":"","type":"font/woff2"}]
3
3
  :HL["/_next/static/media/70bc3e132a0a741e-s.p.3t6q91iet4nsy.woff2","font",{"crossOrigin":"","type":"font/woff2"}]
4
- 0:{"tree":{"name":"","param":null,"prefetchHints":16,"slots":{"children":{"name":"__PAGE__","param":null,"prefetchHints":0,"slots":null}}},"staleTime":300,"buildId":"-UlF345C3V4TG3ZtvR-5_"}
4
+ 0:{"tree":{"name":"","param":null,"prefetchHints":16,"slots":{"children":{"name":"__PAGE__","param":null,"prefetchHints":0,"slots":null}}},"staleTime":300,"buildId":"2AsIePMYsPfJoAl46w-g4"}
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,2348,2413,e=>{"use strict";let t=1/1.2;e.s(["ZOOM_IN_FACTOR",0,t,"ZOOM_OUT_FACTOR",0,1.2,"attachDoubleClickFocus",0,function(e,t,s){let n=()=>{let t=e.pick(e.pointerX,e.pointerY);t?.hit&&t.pickedPoint&&s.setTarget(t.pickedPoint)};return t.addEventListener("dblclick",n),()=>t.removeEventListener("dblclick",n)},"disableWheelZoom",0,function(e){e.inputs.removeByType("ArcRotateCameraMouseWheelInput")},"resetFocus",0,function(e,t){e.setTarget(t.target),e.alpha=t.alpha,e.beta=t.beta,e.radius=t.radius},"stepZoom",0,function(e,t){let s=e.lowerRadiusLimit??.01,n=e.upperRadiusLimit??1/0;e.radius=Math.min(n,Math.max(s,e.radius*t))}],2348);var s=e.i(28100);e.s(["ZoomButtons",0,function({onZoom:e,onReset:n}){let i="grid h-8 w-8 place-items-center rounded-md border border-edge bg-ink/80 text-lg leading-none text-fg backdrop-blur transition hover:bg-ink hover:text-white";return(0,s.jsxs)("div",{className:"absolute right-3 top-3 flex flex-col gap-1",children:[(0,s.jsx)("button",{type:"button","aria-label":"Zoom in",className:i,onClick:()=>e(t),children:"+"}),(0,s.jsx)("button",{type:"button","aria-label":"Zoom out",className:i,onClick:()=>e(1.2),children:"−"}),n?(0,s.jsx)("button",{type:"button","aria-label":"Reset camera focus to center",title:"Reset focus to center",className:i,onClick:n,children:(0,s.jsxs)("svg",{viewBox:"0 0 16 16",width:"16",height:"16",fill:"none",stroke:"currentColor",strokeWidth:"1.4",strokeLinecap:"round","aria-hidden":"true",children:[(0,s.jsx)("circle",{cx:"8",cy:"8",r:"3"}),(0,s.jsx)("path",{d:"M8 1v2.5M8 12.5V15M1 8h2.5M12.5 8H15"})]})}):null]})}],2413)},28538,e=>{"use strict";var t=e.i(28100),s=e.i(11623);e.i(82665);var n=e.i(20880),i=e.i(88725),r=e.i(60614),a=e.i(2348),l=e.i(2413),o=e.i(93425);let c=new Set,u=[{key:"interaction",label:"Clicks & picks",color:"#fb923c",types:new Set(["pointer_click","mesh_interaction"])},{key:"actors",label:"Scene actors",color:"#e879f9",types:new Set(["node_transform"])},{key:"custom",label:"Custom",color:"#34d399",types:new Set(["custom"])},{key:"camera",label:"Camera",color:"#38bdf8",types:new Set(["camera_sample"])},{key:"pointer",label:"Pointer",color:"#94a3b8",types:new Set(["pointer_move","pointer_down","pointer_up"])},{key:"perf",label:"Perf",color:"#a78bfa",types:new Set(["frame_perf"])},{key:"lifecycle",label:"Lifecycle",color:"#f472b6",types:new Set(["session_start","session_end","scene_change","focus_change","visibility_change","viewport_resize","context_lost","context_restored","runtime_error","capability_change","input_action","resource_sample","compile_stall","mesh_visibility","hover_dwell"])}];function h(e,t,s){let n=Math.max(1,s),i=new Map;u.forEach((e,t)=>{for(let s of e.types)i.set(s,t)});let r=u.map(()=>new Set);for(let s of e){let e=i.get(s.type);if(void 0===e)continue;let a=Math.min(1,Math.max(0,(s.ts-t)/n));r[e].add(Math.round(600*a))}return u.map((e,t)=>({key:e.key,label:e.label,color:e.color,marks:[...r[t]].sort((e,t)=>e-t).map(e=>e/600)})).filter(e=>e.marks.length>0)}function d(e){let t=Math.max(0,Math.round(e/1e3)),s=Math.floor(t/60);return`${s}:${(t%60).toString().padStart(2,"0")}`}function p(e){let t=e.slice(e.lastIndexOf("/")+1);return t.length>20?`${t.slice(0,19)}\u2026`:t}function m({lanes:e,duration:s,progress:n,onSeek:i,hiddenTypes:r}){let a=e.filter(e=>{let t=u.find(t=>t.key===e.key);if(!t)return!0;for(let e of t.types)if(!r.has(e))return!0;return!1});if(0===a.length)return null;let l=`${Math.min(100,Math.max(0,n/Math.max(1,s)*100))}%`;return(0,t.jsxs)("div",{className:"mt-4",children:[(0,t.jsx)("div",{className:"mb-1.5 flex flex-wrap items-center gap-x-3 gap-y-1 text-[10px] text-fg-muted",children:a.map(e=>(0,t.jsxs)("span",{className:"inline-flex items-center gap-1",children:[(0,t.jsx)("span",{"aria-hidden":!0,className:"inline-block h-2 w-2 rounded-sm",style:{backgroundColor:e.color}}),e.label,(0,t.jsxs)("span",{className:"tabular-nums text-fg-muted",children:["(",e.marks.length,")"]})]},e.key))}),(0,t.jsxs)("button",{type:"button","aria-label":"Event timeline — click to seek",className:"relative block w-full cursor-pointer select-none rounded-md border border-edge bg-ink/60 p-1.5 text-left",onClick:e=>{var t;let n;return t=e.clientX,void i(Math.min(1,Math.max(0,(t-(n=e.currentTarget.getBoundingClientRect()).left)/(n.width||1)))*s)},children:[(0,t.jsx)("div",{className:"flex flex-col gap-1",children:a.map(e=>(0,t.jsx)("div",{className:"relative h-2.5 rounded-sm bg-white/5",children:e.marks.map((s,n)=>(0,t.jsx)("span",{"aria-hidden":!0,className:"pointer-events-none absolute top-0 h-full w-px",style:{left:`${100*s}%`,backgroundColor:e.color,opacity:.85}},n))},e.key))}),(0,t.jsx)("div",{"aria-hidden":!0,className:"pointer-events-none absolute inset-y-1 w-px bg-saffron",style:{left:l}})]})]})}e.s(["SessionReplay",0,function({baseUrl:u,apiKey:f,sessionId:g,hiddenTypes:b,isLive:k=!1}){let x=(0,s.useRef)(null),y=(0,s.useRef)(null),j=(0,s.useRef)(0),v=(0,s.useRef)(b??c),w=(0,s.useRef)(!1),_=(0,s.useRef)(null),M=(0,s.useRef)(!1),C=(0,s.useRef)(!1),P=(0,s.useRef)(null),z=(0,s.useRef)(0),N=(0,s.useRef)([]),S=(0,s.useRef)([]),q=(0,s.useRef)([]),R=(0,s.useRef)(!0),$=(0,s.useRef)("birdview"),L=(0,s.useRef)(null),I=(0,s.useRef)(null),A=(0,s.useRef)([]),V=(0,s.useRef)(null),T=(0,s.useRef)(null),[E,Z]=(0,s.useState)("idle"),[F,O]=(0,s.useState)(null),[W,B]=(0,s.useState)(0),[H,K]=(0,s.useState)(0),[U,X]=(0,s.useState)(!1),[D,G]=(0,s.useState)([]),[Y,J]=(0,s.useState)([]),[Q,ee]=(0,s.useState)([]),[et,es]=(0,s.useState)(!0),[en,ei]=(0,s.useState)(!1),[er,ea]=(0,s.useState)("birdview"),[el,eo]=(0,s.useState)(null),[ec,eu]=(0,s.useState)(!1),[eh,ed]=(0,s.useState)(!1),[ep,em]=(0,s.useState)(null);(0,s.useEffect)(()=>{R.current=et},[et]),(0,s.useEffect)(()=>{C.current=U},[U]),(0,s.useEffect)(()=>{M.current=en},[en]),(0,s.useEffect)(()=>{$.current=er,w.current=!0},[er]),(0,s.useEffect)(()=>{v.current=b??c,w.current=!0},[b]),(0,s.useEffect)(()=>{let t=x.current;if(!t)return;let s=!1,i=null;return Z("loading"),O(null),X(!1),B(0),K(0),G([]),J([]),ee([]),eo(null),L.current=null,N.current=[],S.current=[],q.current=[],j.current=0,V.current=null,A.current=[],I.current=null,eu(!1),ed(!1),em(null),(async()=>{try{let[{Engine:l},{Scene:o},{ArcRotateCamera:c},{UniversalCamera:d},{HemisphericLight:p},{Vector3:m,Color3:b,Color4:x,Matrix:T},{MeshBuilder:E},{StandardMaterial:F},{fetchSessionEvents:O,ReplayPlayer:W}]=await Promise.all([e.A(3905),e.A(94432),e.A(59694),e.A(68480),e.A(88004),e.A(27940),e.A(27124),e.A(14074),e.A(85461),e.A(18561)]),H=await O({endpoint:u,apiKey:f,sessionId:g});if(s)return;if(0===H.length)return void Z("empty");let U=H[0].ts,D=H[0].ts;for(let e of H)e.ts<U&&(U=e.ts),e.ts>D&&(D=e.ts);let Y=new n.CollectorApi(u,f),Q=await (0,r.mergeSceneProxies)(Y,{since:U-1,until:D+1});if(s)return;let et=[...H].sort((e,t)=>e.ts-t.ts),es=et[0].ts,en=[],er=[],ea=new Map,el=null;for(let e of et){let t=e.ts-es;if("camera_sample"===e.type){el=[e.position[0],e.position[1],e.position[2]],en.push({at:t,position:el,direction:[e.direction[0],e.direction[1],e.direction[2]],..."number"==typeof e.fov?{fov:e.fov}:{}});continue}if("node_transform"===e.type){if(e.boneId)continue;let s=e.childPath?`${e.nodeId}/${e.childPath}`:e.nodeId,n=ea.get(s);n||(n=[],ea.set(s,n)),n.push({at:t,position:[e.position[0],e.position[1],e.position[2]]});continue}if("pointer_click"===e.type&&e.hitPoint){let s=e.ray?.origin??el;if(!s)continue;er.push({at:t,type:"pointer_click",origin:[s[0],s[1],s[2]],hit:[e.hitPoint[0],e.hitPoint[1],e.hitPoint[2]],...e.hitMesh?{mesh:e.hitMesh}:{}});continue}if("mesh_interaction"===e.type&&e.point){if(!el)continue;er.push({at:t,type:"mesh_interaction",origin:[el[0],el[1],el[2]],hit:[e.point[0],e.point[1],e.point[2]],...e.mesh?{mesh:e.mesh}:{}})}}if(0===en.length&&0===er.length&&0===ea.size)return void Z("empty");let ec=new l(t,!0,{preserveDrawingBuffer:!1}),eu=new o(ec);eu.clearColor=new x(.04,.05,.07,1),I.current=eu;let eh=new c("birdview-cam",-Math.PI/2,.22,12,m.Zero(),eu);eh.attachControl(t,!0),(0,a.disableWheelZoom)(eh),y.current=eh,new p("replay-light",new m(0,1,0),eu);let ed=new d("replay-follow-cam",m.Zero(),eu);ed.minZ=.05,ed.fov=Math.PI/3,eu.activeCamera=eh;let ep="birdview",em=E.CreateGround("replay-ground",{width:20,height:20,subdivisions:20},eu),ef=new F("replay-ground-mat",eu);ef.diffuseColor=new b(.12,.14,.18),ef.wireframe=!0,em.material=ef;let eg=new Set(ea.keys()),eb=new Set(Array.from(eg,e=>e.slice(e.lastIndexOf("/")+1))),ek=[],ex=[],ey=new Set,ej=e=>{if(ey.has(e.name)||(e=>{if(e.path){for(let t of eg)if(e.path===t||e.path.endsWith(`/${t}`))return!0}return eb.has(e.name)})(e))return!1;ey.add(e.name);let t=e.aabb,s=Math.max(t[3]-t[0],.001),n=Math.max(t[4]-t[1],.001),i=Math.max(t[5]-t[2],.001),r=E.CreateBox(`replay-proxy-${e.name}`,{width:s,height:n,depth:i},eu);r.position=new m((t[0]+t[3])/2,(t[1]+t[4])/2,(t[2]+t[5])/2);let a=new F(`replay-proxy-mat-${e.name}`,eu);return a.wireframe=!0,a.disableLighting=!0,a.emissiveColor=new b(.32,.4,.52),a.alpha=.35,r.material=a,r.isPickable=!1,V.current&&r.setEnabled(!1),ex.push(r),ek.push({name:e.name,center:new m((t[0]+t[3])/2,t[4],(t[2]+t[5])/2)}),!0};for(let e of Q)ej(e);N.current=ek,S.current=ek.map(()=>null),J(ek.map(e=>e.name)),A.current=ex;let ev=async()=>{let e=await (0,r.mergeSceneProxies)(Y,{since:U-1}).catch(()=>null);if(s||!e)return;let t=!1;for(let s of e)ej(s)&&(t=!0);t&&(N.current=ek,S.current=ek.map((e,t)=>S.current[t]??null),J(ek.map(e=>e.name)),w.current=!0)},ew=[[.91,.47,.98],[.4,.95,.6],[.98,.8,.3],[.45,.85,1]],e_=e=>{let t=e.indexOf("/");return -1===t?e:e.slice(0,t)},eM=[],eC=new Map,eP=0,ez=(e,t,s)=>{let n=E.CreateSphere(`replay-actor-${e}`,{diameter:.5,segments:12},eu),i=new F(`replay-actor-mat-${e}`,eu);i.disableLighting=!0;let r=ew[eP%ew.length];i.emissiveColor=new b(r[0],r[1],r[2]),n.material=i,n.isPickable=!1,n.isVisible=!1,eP++;let a={key:e,mesh:n,samples:s,driveKey:t};return eM.push(a),eC.set(e,a),a},eN=new Map,eS=new Map;for(let[e,t]of ea){if(0===t.length)continue;let s=e_(e);if(e===s)eN.set(s,t);else{let n=eS.get(s);(!n||t.length>n.samples.length)&&eS.set(s,{key:e,samples:t})}}for(let e of new Set([...eN.keys(),...eS.keys()])){let t=eN.get(e);if(t)ez(e,e,t);else{let t=eS.get(e);ez(e,t.key,t.samples)}}q.current=eM.map(()=>null),ee(eM.map(e=>e.key));let eq=(e,t)=>{if(0===e.length||t<e[0].at)return null;let s=0,n=e.length-1,i=-1;for(;s<=n;){let r=s+n>>1;e[r].at<=t?(i=r,s=r+1):n=r-1}if(i<0)return null;let r=e[i],a=e[i+1];if(!a)return r.position;let l=a.at-r.at;if(l<=0)return r.position;let o=Math.max(0,Math.min(1,(t-r.at)/l));return[r.position[0]+(a.position[0]-r.position[0])*o,r.position[1]+(a.position[1]-r.position[1])*o,r.position[2]+(a.position[2]-r.position[2])*o]},eR=1,e$=1.4,eL=E.CreateSphere("replay-camera-origin",{diameter:.35,segments:12},eu),eI=new F("replay-camera-origin-mat",eu);eI.disableLighting=!0,eI.emissiveColor=new b(.6,.9,1),eL.material=eI;let eA=E.CreateLines("replay-camera-frustum",{points:[m.Zero(),new m(0,0,1)]},eu);eA.color=new b(.7,.95,1),eA.isPickable=!1;let eV=E.CreateCylinder("replay-camera-cone",{height:1,diameterTop:0,diameterBottom:1,tessellation:24},eu);eV.bakeTransformIntoVertices(T.RotationX(-Math.PI/2).multiply(T.Translation(0,0,.5)));let eT=new F("replay-camera-cone-mat",eu);eT.disableLighting=!0,eT.emissiveColor=new b(.4,.78,1),eT.alpha=.16,eT.backFaceCulling=!1,eV.material=eT,eV.isPickable=!1,eV.isVisible=!1;let eE=(e,t,s,n)=>{if(e?.dispose(),0===s.length)return null;let i=E.CreateLineSystem(t,{lines:s,...n?{colors:n,useVertexAlpha:!0}:{}},eu);return i.isPickable=!1,i},eZ=null,eF=null,eO=null,eW=()=>{let e=v.current,t=[],s=[];for(let n of er){if(e.has(n.type))continue;let[i,r,a]=n.hit,l="mesh_interaction"===n.type?new x(.45,.85,1,.32):new x(1,.7,.35,.32);t.push([new m(i-.1,r,a),new m(i+.1,r,a)]),t.push([new m(i,r-.1,a),new m(i,r+.1,a)]),t.push([new m(i,r,a-.1),new m(i,r,a+.1)]),s.push([l,l],[l,l],[l,l])}eO=eE(eO,"replay-persistent-marks",t,s)};eW();let eB=E.CreateSphere("replay-glow",{diameter:1,segments:12},eu),eH=new F("replay-glow-mat",eu);eH.disableLighting=!0,eH.emissiveColor=new b(1,.62,.2),eH.alpha=0,eB.material=eH,eB.isPickable=!1,eB.isVisible=!1;let eK=1/0,eU=1/0,eX=1/0,eD=-1/0,eG=-1/0,eY=-1/0,eJ=!1,eQ=e=>{eK=Math.min(eK,e[0]),eU=Math.min(eU,e[1]),eX=Math.min(eX,e[2]),eD=Math.max(eD,e[0]),eG=Math.max(eG,e[1]),eY=Math.max(eY,e[2])},e0=()=>{let e;if(eJ||!Number.isFinite(eK))return;let t=(eK+eD)/2,s=(eU+eG)/2,n=(eX+eY)/2,i=eD-eK,r=eG-eU,a=eY-eX,l=Math.sqrt(i*i+r*r+a*a);eh.setTarget(new m(t,s,n)),e=1.3*l,eh.radius=Number.isFinite(e)?Math.max(8,e):12,eJ=!0};for(let e of en)eQ(e.position);for(let e of er)eQ(e.origin),eQ(e.hit);for(let e of ea.values())for(let t of e)eQ(t.position);for(let e of Q)eQ(e.aabb.slice(0,3)),eQ(e.aabb.slice(3,6));e0();{let e=eD-eK,t=eG-eU,s=eY-eX,n=Number.isFinite(e)?Math.sqrt(e*e+t*t+s*s):0,i=Math.min(Math.max(.035*n,.45),Math.max(.45,.18*n));eR=i/.35,e$=Math.max(.16*n,3.2*i,1.4),eL.scaling.setAll(eR)}let e1=-1,e2=e=>{var n;let i=w.current;if(!i&&e===e1)return;w.current=!1,e1=e,i&&eW();let r=v.current;(n=$.current)!==ep&&(ep=n,"follow"===n?(eh.detachControl(),eu.activeCamera=ed):(eu.activeCamera=eh,eh.attachControl(t,!0)));let a="follow"===$.current,l=r.has("camera_sample")?null:(e=>{if(0===en.length)return null;let t=0,s=en.length-1,n=-1;for(;t<=s;){let i=t+s>>1;en[i].at<=e?(n=i,t=i+1):s=i-1}return n>=0?en[n]:null})(e);if(l){eL.position.set(l.position[0],l.position[1],l.position[2]);let e=l.direction,t=Math.sqrt(e[0]*e[0]+e[1]*e[1]+e[2]*e[2])||1,s=e$,n=new m(l.position[0]+e[0]/t*s,l.position[1]+e[1]/t*s,l.position[2]+e[2]/t*s);if(a)eL.isVisible=!1,eA.isVisible=!1,eV.isVisible=!1,ed.position.set(l.position[0],l.position[1],l.position[2]),ed.setTarget(n),l.fov&&l.fov>0&&(ed.fov=l.fov);else{eL.isVisible=!0,eA.isVisible=!0,eA=E.CreateLines("replay-camera-frustum",{points:[eL.position.clone(),n],instance:eA},eu);let e=(l.fov&&l.fov>0?l.fov:Math.PI/3)/2,t=s*Math.tan(e);eV.isVisible=!0,eV.position.copyFrom(eL.position),eV.lookAt(n),eV.scaling.set(2*t,2*t,s)}}else eL.isVisible=!1,eA.isVisible=!1,eV.isVisible=!1;let o=r.has("node_transform");for(let t of eM){let s=o?null:eq(t.samples,e);if(!s){t.mesh.isVisible=!1;continue}t.mesh.isVisible=!0,t.mesh.position.set(s[0],s[1],s[2])}let c=er.filter(t=>!r.has(t.type)&&t.at<=e&&t.at>=e-2200),u=[],h=[],d=[],p=[],f=null;for(let t of c){let s=e-t.at,n=Math.max(0,Math.min(1,1-s/2200)),i=new x(1,.62,.2,.18+.72*n),r=new m(t.origin[0],t.origin[1],t.origin[2]),a=new m(t.hit[0],t.hit[1],t.hit[2]);u.push([r,a]),h.push([i,i]);let l=.12+.08*n;d.push([new m(a.x-l,a.y,a.z),new m(a.x+l,a.y,a.z)]),d.push([new m(a.x,a.y-l,a.z),new m(a.x,a.y+l,a.z)]),d.push([new m(a.x,a.y,a.z-l),new m(a.x,a.y,a.z+l)]);let o=new x(1,.78,.42,.22+.72*n);if(p.push([o,o],[o,o],[o,o]),s<=900){let e=1-s/900;(!f||e>f.t)&&(f={hit:t.hit,t:e})}}if(f){let e=.25+.9*f.t;eB.isVisible=!0,eB.scaling.set(e,e,e),eB.position.set(f.hit[0],f.hit[1],f.hit[2]),eH.alpha=.12+.5*f.t}else eB.isVisible=!1;let g=null,b=-1/0;for(let e of c)e.mesh&&e.at>b&&(b=e.at,g=e.mesh);g!==L.current&&(L.current=g,s||eo(g)),eZ=eE(eZ,"replay-trail-lines",u,h),eF=eE(eF,"replay-trail-hits",d,p)},e3=et.length>0?et[et.length-1].ts-es:0,e5=e3,e4=et.length>0?et[et.length-1].ts:-1/0,e8=et.map(e=>({type:e.type,ts:e.ts})),e6=0,e7=null;if(k)_.current=null,P.current=e=>{if(s)return;let t="number"==typeof e.ts?e.ts:NaN;if(!Number.isFinite(t)||t<=e4)return;e4=t;let n=t-es;if(n>e5&&(e5=n),n>e3&&(e3=n),e8.push({type:e.type,ts:t}),"camera_sample"===e.type){let t=e.position,s=e.direction;if(t&&s){let i=[t[0],t[1],t[2]];el=i;let r="number"==typeof e.fov?e.fov:void 0;en.push({at:n,position:i,direction:[s[0],s[1],s[2]],...void 0!==r?{fov:r}:{}}),eQ(i),e0()}}else if("pointer_click"===e.type){let t=e.hitPoint,s=e.ray,i=s?.origin??el;if(t&&i){let s="string"==typeof e.hitMesh?e.hitMesh:void 0;er.push({at:n,type:"pointer_click",origin:[i[0],i[1],i[2]],hit:[t[0],t[1],t[2]],...s?{mesh:s}:{}}),eQ(t),w.current=!0}}else if("mesh_interaction"===e.type){let t=e.point;if(t&&el){let s="string"==typeof e.mesh?e.mesh:void 0;er.push({at:n,type:"mesh_interaction",origin:[el[0],el[1],el[2]],hit:[t[0],t[1],t[2]],...s?{mesh:s}:{}}),eQ(t),w.current=!0}}else if("node_transform"===e.type){let t=e.position;if(e.boneId||"string"!=typeof e.nodeId||!t)return;let s="string"==typeof e.childPath?e.childPath:void 0,i=s?`${e.nodeId}/${s}`:e.nodeId;((e,t)=>{let s=e_(e),n=eC.get(s);if(!n){n=ez(s,e,[]);let t=q.current;q.current=eM.map((e,s)=>t[s]??null),ee(eM.map(e=>e.key))}e===n.driveKey?n.samples.push(t):e===s&&n.driveKey!==s&&(n.driveKey=s,n.samples.length=0,n.samples.push(t))})(i,{at:n,position:[t[0],t[1],t[2]]}),eQ(t)}let i=performance.now();i-e6>250&&(e6=i,G(h(e8,es,Math.max(1,e3)))),M.current&&n>j.current&&(j.current=n)},z.current=e3,j.current=e3,M.current=!0,ei(!0),X(!1),B(e3),K(e3),G(h(e8,es,Math.max(1,e3))),e2(e3),e7=setInterval(()=>void ev(),4e3);else{let e=new W(H,{reset(){},apply(){}},{onProgress:e=>{s||(j.current=e,K(e))},onComplete:()=>{s||X(!1)}});_.current=e,B(e.durationMs),G(h(et,es,e.durationMs)),e.update(0),e2(0)}let e9=T.Identity(),te=new Map,tt=e=>{let t=te.get(e);if(t)return t;let s={w:e.offsetWidth||60,h:e.offsetHeight||16};return e.offsetWidth>0&&te.set(e,s),s},ts=performance.now(),tn=0;ec.runRenderLoop(()=>{if(k){let e=performance.now(),t=e-ts;if(ts=e,M.current)j.current+=t,j.current>e3&&(e3=j.current),z.current=e3,K(j.current),e-tn>250&&(tn=e,B(e3));else if(C.current){let e=j.current+t;e>=e3&&(e=e3),j.current=e,K(e)}}e2(j.current),eu.render(),(()=>{if(!R.current)return;let e=t.clientWidth||ec.getRenderWidth(),s=t.clientHeight||ec.getRenderHeight(),n=eh.viewport.toGlobal(e,s),i=eu.getTransformMatrix(),r=L.current,a=e=>e.slice(e.lastIndexOf("/")+1),l=e=>!!r&&(r===e||a(r)===a(e)||e.endsWith(`/${r}`)||r.endsWith(`/${e}`)),o=[],c=N.current,u=S.current;for(let e=0;e<c.length;e++){let t=u[e];if(!t)continue;let s=m.Project(c[e].center,e9,i,n);if(s.z<0||s.z>1){t.style.opacity="0";continue}o.push({el:t,x:s.x,y:s.y,liftPct:140,highlighted:l(c[e].name)})}let h=q.current;for(let e=0;e<eM.length;e++){let t=h[e];if(!t)continue;let s=eM[e].mesh;if(!s.isVisible){t.style.opacity="0";continue}let r=m.Project(s.position,e9,i,n);if(r.z<0||r.z>1){t.style.opacity="0";continue}o.push({el:t,x:r.x,y:r.y,liftPct:180,highlighted:l(eM[e].key)})}o.sort((e,t)=>e.highlighted!==t.highlighted?e.highlighted?-1:1:e.y-t.y||e.x-t.x);let d=[];for(let e of o){let{w:t,h:s}=tt(e.el),n=e.x-t/2,i=e.x+t/2,r=e.y-e.liftPct/100*s,a=r,l=!0,o=0;for(;l&&o++<256;)for(let e of(l=!1,d))n<e.right&&i>e.left&&a<e.bottom&&a+s>e.top&&(a=e.bottom+1,l=!0);d.push({left:n,right:i,top:a,bottom:a+s});let c=a-r;e.el.style.opacity="1",e.el.style.zIndex=e.highlighted?"10":"",e.el.style.transform=`translate(${e.x}px, ${e.y+c}px) translate(-50%, -${e.liftPct}%)`}})()});let ti=()=>ec.resize();window.addEventListener("resize",ti),Z("ready"),i=()=>{window.removeEventListener("resize",ti),e7&&clearInterval(e7),P.current=null,_.current?.pause(),eA.dispose(),eV.dispose(),eZ?.dispose(),eF?.dispose(),eO?.dispose(),eB.dispose(),V.current?.dispose(),V.current=null,A.current=[],I.current=null,eu.dispose(),ec.dispose(),y.current=null,_.current=null}}catch(e){if(s)return;Z("error"),O(e instanceof Error?e.message:"Failed to load replay.")}})(),()=>{s=!0,i?.()}},[u,f,g,k]);let ef=(0,s.useCallback)(()=>{if(k){ei(!1),M.current=!1,X(e=>{let t=!e;return C.current=t,t});return}let e=_.current;e&&X(t=>(t?e.pause():e.play(),!t))},[k]),eg=(0,s.useCallback)(e=>{if(k){ei(!1),M.current=!1,X(!1),C.current=!1,j.current=e,K(e);return}let t=_.current;t&&(t.pause(),t.seek(e),X(!1),j.current=e,K(e))},[k]),eb=(0,s.useCallback)(()=>{ei(!0),M.current=!0,X(!1),C.current=!1,j.current=z.current,K(z.current)},[]),{gated:ek}=(0,i.useLiveSession)(u,f,g,k&&"ready"===E,e=>P.current?.(e),()=>{}),ex=(0,s.useCallback)(e=>{if(!el)return!1;if(el===e)return!0;let t=e=>e.slice(e.lastIndexOf("/")+1);return t(el)===t(e)||e.endsWith(`/${el}`)||el.endsWith(`/${e}`)},[el]),ey=(0,s.useCallback)(async t=>{let s=I.current;if(s){ed(!0),em(`Loading ${t.name}…`);try{let[{loadSceneBackdrop:n}]=await Promise.all([e.A(3633),e.A(91064)]);if(I.current!==s)return;V.current?.dispose();let i=await n(s,t);if(I.current!==s)return void i.dispose();for(let e of(V.current=i,A.current))e.setEnabled(!1);w.current=!0,eu(!0),em(`Loaded ${t.name} (${i.meshes.length} meshes).`)}catch(e){em(e instanceof Error?e.message:"Could not load model.")}finally{ed(!1)}}},[]),ej=(0,s.useCallback)(e=>{let t=e.target.files?.[0];e.target.value="",t&&ey(t)},[ey]),ev=(0,s.useCallback)(()=>{for(let e of(V.current?.dispose(),V.current=null,A.current))e.setEnabled(!0);w.current=!0,eu(!1),em(null)},[]);return(0,t.jsxs)(o.Panel,{title:k?"Session replay · live":"Session replay (birdview timeline)",subtitle:k?"Following this session live — new camera moves and interactions stream in and the timeline grows. Scrub back to review, then press ● LIVE to return to the edge.":"Scrub the camera path and interaction rays; every click stays marked and glows as the playhead passes it. The color-coded strip marks when each event fired (click to seek).",children:[(0,t.jsxs)("div",{className:"relative",children:[(0,t.jsx)("canvas",{ref:x,className:"aspect-video w-full rounded-lg border border-edge bg-ink"}),(0,t.jsxs)("div",{className:`pointer-events-none absolute inset-0 overflow-hidden ${et?"":"hidden"}`,children:[Y.map((e,s)=>(0,t.jsx)("div",{title:e,ref:e=>{e&&(S.current[s]=e)},className:`absolute left-0 top-0 whitespace-nowrap rounded px-1.5 py-0.5 text-[10px] font-medium opacity-0 transition-colors ${ex(e)?"bg-amber/30 text-white ring-2 ring-amber shadow-lg shadow-amber/30":"bg-ink/80 text-saffron ring-1 ring-amber/30"}`,children:p(e)},e)),Q.map((e,s)=>(0,t.jsx)("div",{title:e,ref:e=>{e&&(q.current[s]=e)},className:`absolute left-0 top-0 whitespace-nowrap rounded px-1.5 py-0.5 text-[10px] font-medium opacity-0 transition-colors ${ex(e)?"bg-fuchsia-400/30 text-white ring-2 ring-fuchsia-300 shadow-lg shadow-fuchsia-500/30":"bg-ink/80 text-fuchsia-300 ring-1 ring-fuchsia-400/30"}`,children:p(e)},`actor-${e}`))]}),"ready"===E&&(Y.length>0||Q.length>0)?(0,t.jsx)("button",{type:"button",onClick:()=>es(e=>!e),className:"absolute left-3 top-3 rounded-md border border-edge bg-ink/80 px-2 py-1 text-xs font-medium text-fg transition hover:bg-ink hover:text-white","aria-pressed":et?"true":"false",children:et?"Hide labels":"Show labels"}):null,"ready"===E&&"birdview"===er?(0,t.jsx)(l.ZoomButtons,{onZoom:e=>y.current&&(0,a.stepZoom)(y.current,e)}):null,"ready"!==E?(0,t.jsx)("div",{className:"pointer-events-none absolute inset-0 grid place-items-center text-sm text-fg-muted",children:"loading"===E?"Loading replay…":"empty"===E?"No replayable events (raw retention may be disabled).":"error"===E?F??"Replay unavailable.":null}):null]}),(0,t.jsxs)("div",{className:"mt-3 flex items-center gap-3",children:[(0,t.jsx)("button",{type:"button",onClick:ef,disabled:"ready"!==E,className:"rounded-md bg-amber px-3 py-1.5 text-sm font-medium text-ink transition hover:bg-ember disabled:opacity-40",children:U?"Pause":"Play"}),k?(0,t.jsxs)("button",{type:"button",onClick:eb,disabled:"ready"!==E,"aria-pressed":en?"true":"false",className:`flex items-center gap-1.5 rounded-md px-2.5 py-1.5 text-sm font-medium transition disabled:opacity-40 ${en?"bg-rose-500/20 text-rose-300 ring-1 ring-rose-400/40":"border border-edge text-fg hover:bg-ink hover:text-white"}`,children:[(0,t.jsx)("span",{className:`inline-block h-2 w-2 rounded-full ${en?"animate-pulse bg-rose-400":"bg-fg-muted"}`}),en?"LIVE":"Resume live"]}):null,(0,t.jsxs)("div",{role:"group","aria-label":"Camera view",className:"flex items-center rounded-md border border-edge p-0.5 text-xs font-medium",children:[(0,t.jsx)("button",{type:"button",onClick:()=>ea("birdview"),disabled:"ready"!==E,"aria-pressed":"birdview"===er?"true":"false",className:`rounded px-2 py-1 transition disabled:opacity-40 ${"birdview"===er?"bg-amber text-ink":"text-fg hover:text-white"}`,children:"Birdview"}),(0,t.jsx)("button",{type:"button",onClick:()=>ea("follow"),disabled:"ready"!==E,"aria-pressed":"follow"===er?"true":"false",className:`rounded px-2 py-1 transition disabled:opacity-40 ${"follow"===er?"bg-amber text-ink":"text-fg hover:text-white"}`,children:"Follow camera"})]}),(0,t.jsx)("span",{className:"w-12 text-right font-mono text-xs tabular-nums text-fg-muted",children:d(H)}),(0,t.jsx)("input",{type:"range",min:0,max:Math.max(1,W),step:50,value:Math.min(H,W),onChange:e=>eg(Number(e.target.value)),disabled:"ready"!==E,className:"flex-1 accent-amber"}),(0,t.jsx)("span",{className:"w-12 font-mono text-xs tabular-nums text-fg-muted",children:d(W)})]}),"ready"===E?(0,t.jsxs)("div",{className:"mt-3 flex flex-wrap items-center gap-3",children:[(0,t.jsx)("input",{ref:T,type:"file",accept:".glb,.gltf,model/gltf-binary,model/gltf+json",onChange:ej,className:"hidden"}),(0,t.jsx)("button",{type:"button",onClick:()=>T.current?.click(),disabled:eh,className:"rounded-md border border-edge bg-ink/80 px-2.5 py-1.5 text-xs font-medium text-fg transition hover:bg-ink hover:text-white disabled:opacity-40",children:eh?"Loading model…":ec?"Replace model (.glb)":"Load model (.glb)"}),ec?(0,t.jsx)("button",{type:"button",onClick:ev,disabled:eh,className:"rounded-md border border-edge px-2.5 py-1.5 text-xs font-medium text-fg transition hover:bg-ink hover:text-white disabled:opacity-40",children:"Remove model"}):null,ep?(0,t.jsx)("span",{className:"text-xs text-fg-muted",role:"status",children:ep}):(0,t.jsx)("span",{className:"text-xs text-fg-muted",children:"Load a glTF model to replace the wireframe boxes with your real scene."})]}):null,"ready"===E?(0,t.jsx)(m,{lanes:D,duration:W,progress:H,onSeek:eg,hiddenTypes:b??c}):null,k&&ek&&"ready"===E?(0,t.jsx)("p",{className:"mt-2 text-xs text-fg-muted",children:"Live follow is unavailable — raw session retention is disabled on the collector."}):null]})}])},12449,e=>{e.n(e.i(28538))},3905,e=>{e.v(t=>Promise.all(["static/chunks/3pdpaqzwhhijn.js","static/chunks/08bm3ye5govev.js","static/chunks/0g6u34xkzrpjn.js","static/chunks/25ctnyh7njp-d.js","static/chunks/2gh4z57fem0_v.js","static/chunks/3vaho-xrtuchd.js","static/chunks/0g7p8zp2kxve5.js"].map(t=>e.l(t))).then(()=>t(66232)))},94432,e=>{e.v(t=>Promise.all(["static/chunks/2kje_jvmwsvwo.js","static/chunks/1j--a56ji33_x.js","static/chunks/3pdpaqzwhhijn.js","static/chunks/2npk7tr63h7rl.js","static/chunks/3vaho-xrtuchd.js","static/chunks/3g_h_00xs9u59.js","static/chunks/1vzmzrjhlm1q5.js","static/chunks/25ctnyh7njp-d.js","static/chunks/1vpcaaf-0dn7q.js"].map(t=>e.l(t))).then(()=>t(92494)))},59694,e=>{e.v(t=>Promise.all(["static/chunks/1j--a56ji33_x.js","static/chunks/0oap0o8a8a_cl.js","static/chunks/0f_nv15a8q415.js","static/chunks/1vzmzrjhlm1q5.js","static/chunks/3pdpaqzwhhijn.js","static/chunks/245h82k-g1nxr.js","static/chunks/3ovd8o_usay7j.js","static/chunks/3vaho-xrtuchd.js","static/chunks/1vpcaaf-0dn7q.js","static/chunks/25ctnyh7njp-d.js","static/chunks/2npk7tr63h7rl.js","static/chunks/3pyggl13glbdc.js"].map(t=>e.l(t))).then(()=>t(67186)))},68480,e=>{e.v(t=>Promise.all(["static/chunks/1--kelnig7pxx.js","static/chunks/1j--a56ji33_x.js","static/chunks/1vkww9l6lgqag.js","static/chunks/3pdpaqzwhhijn.js","static/chunks/2vaoftqgc44cg.js","static/chunks/3vaho-xrtuchd.js","static/chunks/3rl45k759wfi1.js","static/chunks/25ctnyh7njp-d.js"].map(t=>e.l(t))).then(()=>t(25062)))},88004,e=>{e.v(t=>Promise.all(["static/chunks/2p8dbh81chhon.js","static/chunks/1oara6fkfvgs3.js","static/chunks/1vzmzrjhlm1q5.js","static/chunks/25ctnyh7njp-d.js","static/chunks/3pdpaqzwhhijn.js"].map(t=>e.l(t))).then(()=>t(15768)))},27940,e=>{e.v(t=>Promise.all(["static/chunks/0w0sx062qmcsh.js","static/chunks/25ctnyh7njp-d.js","static/chunks/3pdpaqzwhhijn.js"].map(t=>e.l(t))).then(()=>t(23235)))},27124,e=>{e.v(t=>Promise.all(["static/chunks/1par9m038tiov.js","static/chunks/1j--a56ji33_x.js","static/chunks/2j-sax2xfdv7l.js","static/chunks/340pg0qkv5tqq.js","static/chunks/3pdpaqzwhhijn.js","static/chunks/0gwa154w_0wuh.js","static/chunks/0oap0o8a8a_cl.js","static/chunks/0f_nv15a8q415.js","static/chunks/3vaho-xrtuchd.js","static/chunks/3pyggl13glbdc.js","static/chunks/1vzmzrjhlm1q5.js","static/chunks/3g_h_00xs9u59.js","static/chunks/1vpcaaf-0dn7q.js","static/chunks/25ctnyh7njp-d.js","static/chunks/2npk7tr63h7rl.js","static/chunks/01aeari2x_tlz.js"].map(t=>e.l(t))).then(()=>t(70928)))},14074,e=>{e.v(t=>Promise.all(["static/chunks/1zcrrq1fx8g2y.js","static/chunks/1tdg_eolxlcdl.js","static/chunks/1j--a56ji33_x.js","static/chunks/1vzmzrjhlm1q5.js","static/chunks/0vddljjnmozzx.js","static/chunks/3pdpaqzwhhijn.js","static/chunks/1vpcaaf-0dn7q.js","static/chunks/3vaho-xrtuchd.js","static/chunks/0f_nv15a8q415.js","static/chunks/3g_h_00xs9u59.js","static/chunks/2npk7tr63h7rl.js","static/chunks/25ctnyh7njp-d.js"].map(t=>e.l(t))).then(()=>t(87566)))},85461,e=>{e.v(t=>Promise.all(["static/chunks/0n8n481szj90g.js"].map(t=>e.l(t))).then(()=>t(57092)))},18561,e=>{e.v(t=>Promise.all(["static/chunks/1j--a56ji33_x.js","static/chunks/1vkww9l6lgqag.js","static/chunks/3pdpaqzwhhijn.js","static/chunks/2npk7tr63h7rl.js","static/chunks/117ys3lltfmcu.js","static/chunks/25ctnyh7njp-d.js","static/chunks/1vzmzrjhlm1q5.js","static/chunks/3g_h_00xs9u59.js","static/chunks/1vpcaaf-0dn7q.js","static/chunks/3vaho-xrtuchd.js"].map(t=>e.l(t))).then(()=>t(85106)))},3633,e=>{e.v(t=>Promise.all(["static/chunks/2l_oqx9idxcs8.js","static/chunks/25ctnyh7njp-d.js"].map(t=>e.l(t))).then(()=>t(97900)))},91064,e=>{e.v(t=>Promise.all(["static/chunks/17v12p4sfraa0.js","static/chunks/1j--a56ji33_x.js","static/chunks/340pg0qkv5tqq.js","static/chunks/0oap0o8a8a_cl.js","static/chunks/17dmbt396_tyq.js","static/chunks/0vddljjnmozzx.js","static/chunks/17d1isrw8gtnb.js","static/chunks/0gwa154w_0wuh.js","static/chunks/3g4e2txsrb2p2.js","static/chunks/3urd7r018nel4.js","static/chunks/2zljunurdji0q.js","static/chunks/3pdpaqzwhhijn.js","static/chunks/2h1uw3cluvmmo.js","static/chunks/3vaho-xrtuchd.js","static/chunks/2npk7tr63h7rl.js","static/chunks/3g_h_00xs9u59.js","static/chunks/0f_nv15a8q415.js","static/chunks/1vpcaaf-0dn7q.js","static/chunks/40acif2eh_unv.js","static/chunks/3bsvp8qhjqdu0.js","static/chunks/25ctnyh7njp-d.js","static/chunks/3pyggl13glbdc.js","static/chunks/3rl45k759wfi1.js","static/chunks/0fxfsshoxnnh6.js"].map(t=>e.l(t))).then(()=>t(83572)))}]);
@@ -0,0 +1,3 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,13329,(e,t,s)=>{"use strict";Object.defineProperty(s,"__esModule",{value:!0}),Object.defineProperty(s,"BailoutToCSR",{enumerable:!0,get:function(){return l}});let n=e.r(65711);function l({reason:e,children:t}){if("u"<typeof window)throw Object.defineProperty(new n.BailoutToCSRError(e),"__NEXT_ERROR_CODE",{value:"E394",enumerable:!1,configurable:!0});return t}},18316,(e,t,s)=>{"use strict";function n(e){return e.split("/").map(e=>encodeURIComponent(e)).join("/")}Object.defineProperty(s,"__esModule",{value:!0}),Object.defineProperty(s,"encodeURIPath",{enumerable:!0,get:function(){return n}})},18480,(e,t,s)=>{"use strict";Object.defineProperty(s,"__esModule",{value:!0}),Object.defineProperty(s,"PreloadChunks",{enumerable:!0,get:function(){return o}});let n=e.r(28100),l=e.r(49698),r=e.r(75126),a=e.r(18316),i=e.r(60177);function o({moduleIds:e}){if("u">typeof window)return null;let t=r.workAsyncStorage.getStore();if(void 0===t)return null;let s=[];if(t.reactLoadableManifest&&e){let n=t.reactLoadableManifest;for(let t of e){if(!n[t])continue;let e=n[t].files;s.push(...e)}}if(0===s.length)return null;let c=(0,i.getAssetTokenQuery)();return(0,n.jsx)(n.Fragment,{children:s.map(e=>{let s=`${t.assetPrefix}/_next/${(0,a.encodeURIPath)(e)}${c}`;return e.endsWith(".css")?(0,n.jsx)("link",{precedence:"dynamic",href:s,rel:"stylesheet",as:"style",nonce:t.nonce},e):((0,l.preload)(s,{as:"script",fetchPriority:"low",nonce:t.nonce}),null)})})}},61401,(e,t,s)=>{"use strict";Object.defineProperty(s,"__esModule",{value:!0}),Object.defineProperty(s,"default",{enumerable:!0,get:function(){return c}});let n=e.r(28100),l=e.r(11623),r=e.r(13329),a=e.r(18480);function i(e){return{default:e&&"default"in e?e.default:e}}let o={loader:()=>Promise.resolve(i(()=>null)),loading:null,ssr:!0},c=function(e){let t={...o,...e},s=(0,l.lazy)(()=>t.loader().then(i)),c=t.loading;function d(e){let i=c?(0,n.jsx)(c,{isLoading:!0,pastDelay:!0,error:null}):null,o=!t.ssr||!!t.loading,d=o?l.Suspense:l.Fragment,u=t.ssr?(0,n.jsxs)(n.Fragment,{children:["u"<typeof window?(0,n.jsx)(a.PreloadChunks,{moduleIds:t.modules}):null,(0,n.jsx)(s,{...e})]}):(0,n.jsx)(r.BailoutToCSR,{reason:"next/dynamic",children:(0,n.jsx)(s,{...e})});return(0,n.jsx)(d,{...o?{fallback:i}:{},children:u})}return d.displayName="LoadableComponent",d}},61776,(e,t,s)=>{"use strict";Object.defineProperty(s,"__esModule",{value:!0}),Object.defineProperty(s,"default",{enumerable:!0,get:function(){return l}});let n=e.r(81258)._(e.r(61401));function l(e,t){let s={};"function"==typeof e&&(s.loader=e);let l={...s,...t};return(0,n.default)({...l,modules:l.loadableGenerated?.modules})}("function"==typeof s.default||"object"==typeof s.default&&null!==s.default)&&void 0===s.default.__esModule&&(Object.defineProperty(s.default,"__esModule",{value:!0}),Object.assign(s.default,s),t.exports=s.default)},14936,e=>{"use strict";var t=e.i(37998),s=e.i(28100),n=e.i(61776),l=e.i(11623),r=e.i(82665),a=e.i(20880);let i={window:"1h"},o=[{id:"1h",label:"Last hour"},{id:"24h",label:"Last 24h"},{id:"7d",label:"Last 7 days"},{id:"all",label:"All time"}],c={"1h":36e5,"24h":864e5,"7d":6048e5};function d(e,t=Date.now()){return"all"===e.window?{}:"custom"===e.window?{since:e.since,until:e.until}:{since:t-c[e.window],until:t}}function u(e,t=Date.now()){return{...d(e,t),scene:e.scene&&e.scene.length>0?e.scene:void 0,source:e.source,cameraMode:e.cameraMode}}let m=[60,300,900,1800,3600,10800,21600,43200,86400,604800];function x(e,t=80){let s=Math.max(60,Math.round(e/t/1e3));return m.find(e=>e>=s)??604800}function p(e){return"xr-controller"===e?"XR controller":e.charAt(0).toUpperCase()+e.slice(1)}let h=["mouse","touch","stylus","pen","xr-controller","hand","gaze","transient","other"];var g=e.i(56054);function f(e,t=1){let[s,n,l]=(0,g.heatRgb)(e);return`rgba(${Math.round(255*s)}, ${Math.round(255*n)}, ${Math.round(255*l)}, ${t})`}function b(e,t=0){return Number.isFinite(e)?e.toLocaleString(void 0,{maximumFractionDigits:t}):"—"}var v=e.i(60614),j=e.i(88725);let y=e=>import(e);async function w(e,t={}){var s;let n,l=t.fetchImpl??fetch;try{let s=await l(e,{signal:t.signal});if(!s.ok)return{source:e,code:"manifest-fetch",message:`HTTP ${s.status}`};n=await s.json()}catch(t){return{source:e,code:"manifest-fetch",message:S(t)}}return"object"==typeof(s=n)&&null!==s&&"number"==typeof s.version&&Array.isArray(s.panels)&&s.panels.every(e=>"object"==typeof e&&null!==e&&"string"==typeof e.url&&e.url.length>0&&"number"==typeof e.contract&&(void 0===e.export||"string"==typeof e.export)&&(void 0===e.id||"string"==typeof e.id))?n:{source:e,code:"manifest-invalid",message:"Manifest shape is invalid"}}async function N(e,t={}){let s=t.importModule??y,n=[],l=[];for(let r of(await Promise.all(e.panels.map(e=>k(e,s,t.allowOrigins)))))"panel"in r?n.push(r.panel):l.push(r.error);return{panels:n,errors:l}}async function k(e,t,s){var n;let l,r,a=e.url;if(1!==e.contract)return{error:{source:a,code:"incompatible",message:`Panel declares contract ${e.contract}; host requires 1`}};if(!function(e,t){let s;if(!t||0===t.length)return!0;try{s=new URL(e).origin}catch{return!1}return t.includes(s)}(e.url,s))return{error:{source:a,code:"origin-blocked",message:"Module origin is not in the allowlist"}};try{l=await t(e.url)}catch(e){return{error:{source:a,code:"import-failed",message:S(e)}}}let i=e.export??"default",o=void 0!==(r=(n=l)[i])?r:"default"===i&&void 0!==n.panel?n.panel:void 0;return void 0===o?{error:{source:a,code:"export-missing",message:`No "${i}" export found`}}:"object"==typeof o&&null!==o&&"string"==typeof o.id&&0!==o.id.length&&"string"==typeof o.title&&"function"==typeof o.render&&(void 0===o.load||"function"==typeof o.load)&&(void 0===o.enabled||"function"==typeof o.enabled)&&(void 0===o.span||1===o.span||2===o.span)&&(void 0===o.surfaces||Array.isArray(o.surfaces))&&1?{panel:o}:{error:{source:a,code:"invalid-panel",message:"Export is not a valid PanelDefinition"}}}function S(e){return e instanceof Error?e.message:String(e)}var M=l;let P={hidden:[],settings:{}},C={load:()=>P,save:()=>{}};var _=e.i(93425);function z({panelId:e,spec:t,values:n,onChange:r,onReset:a,showReset:i=!0}){let o=(0,l.useId)(),c=Object.keys(t);return 0===c.length?null:(0,s.jsxs)("div",{className:"space-y-3","data-panel-settings":e,children:[c.map(e=>{let l=t[e];if(!l)return null;let a=`${o}-${e}`,i=l.label??e;return(0,s.jsxs)("div",{className:"space-y-1",children:[(0,s.jsxs)("div",{className:"flex items-center justify-between gap-3",children:[(0,s.jsx)("label",{htmlFor:a,className:"text-xs font-medium text-fg",children:i}),"number"===l.type?(0,s.jsxs)("span",{className:"text-xs tabular-nums text-fg-muted",children:[String(n[e]),l.unit?` ${l.unit}`:""]}):null]}),"number"===l.type?(0,s.jsx)("input",{id:a,type:"range",className:"w-full accent-amber",min:l.min,max:l.max,step:l.step??1,value:Number(n[e]),onChange:t=>r(e,Number(t.target.value))}):null,"boolean"===l.type?(0,s.jsxs)("label",{htmlFor:a,className:"flex items-center gap-2 text-xs text-fg-muted",children:[(0,s.jsx)("input",{id:a,type:"checkbox",className:"accent-amber",checked:!!n[e],onChange:t=>r(e,t.target.checked)}),l.help??"Enabled"]}):null,"select"===l.type?(0,s.jsx)("select",{id:a,className:"w-full rounded-md border border-edge bg-ink px-2 py-1 text-xs text-fg",value:String(n[e]),onChange:t=>r(e,t.target.value),children:l.options.map(e=>(0,s.jsx)("option",{value:e.value,children:e.label??e.value},e.value))}):null,"boolean"!==l.type&&l.help?(0,s.jsx)("p",{className:"text-[11px] leading-tight text-fg-muted",children:l.help}):null]},e)}),i?(0,s.jsx)("button",{type:"button",onClick:a,className:"text-[11px] text-fg-muted underline-offset-2 transition hover:text-amber hover:underline",children:"Reset to defaults"}):null]})}function R({panels:e,ctx:t,surface:n,revision:r=0}){let a=function(e,t){let s=(0,l.useMemo)(()=>{var t;let s;return(void 0)??(t=`uptimizr:dashboard:panels:${e}`,(s=window.localStorage?window.localStorage:null)?{load(){try{let e=s.getItem(t);return e?function(e){if(!e||"object"!=typeof e)return P;let t=Array.isArray(e.hidden)?e.hidden.filter(e=>"string"==typeof e):[],s={};if(e.settings&&"object"==typeof e.settings)for(let[t,n]of Object.entries(e.settings)){if(!n||"object"!=typeof n)continue;let e={};for(let[t,s]of Object.entries(n))("number"==typeof s||"boolean"==typeof s||"string"==typeof s)&&(e[t]=s);Object.keys(e).length>0&&(s[t]=e)}return{hidden:t,settings:s}}(JSON.parse(e)):P}catch{return P}},save(e){try{0===e.hidden.length&&0===Object.keys(e.settings).length?s.removeItem(t):s.setItem(t,JSON.stringify(e))}catch{}}}:C)},[void 0,e]),[n,r]=(0,l.useState)(P),[a,i]=(0,l.useState)(!1),o=(0,l.useRef)(t);o.current=t,(0,l.useEffect)(()=>{r(s.load()),i(!0)},[s]);let c=(0,l.useCallback)(e=>{r(e),s.save(e)},[s]),d=(0,l.useCallback)(e=>{r(t=>{if(t.hidden.includes(e))return t;let n={...t,hidden:[...t.hidden,e]};return s.save(n),n})},[s]),u=(0,l.useCallback)(e=>{r(t=>{if(!t.hidden.includes(e))return t;let n={...t,hidden:t.hidden.filter(t=>t!==e)};return s.save(n),n})},[s]),m=(0,l.useCallback)(()=>{r(e=>{if(0===e.hidden.length)return e;let t={...e,hidden:[]};return s.save(t),t})},[s]),x=(0,l.useCallback)((e,t,n)=>{r(l=>{let r={...l.settings[e]??{},[t]:n},a=function(e,t){let s={};if(!e)return s;for(let n of Object.keys(t)){let l=e[n];l&&t[n]!==l.default&&(s[n]=t[n])}return s}(o.current(e),r),i={...l.settings};Object.keys(a).length>0?i[e]=a:delete i[e];let c={...l,settings:i};return s.save(c),c})},[s]),p=(0,l.useCallback)(e=>{r(t=>{if(!t.settings[e])return t;let n={...t.settings};delete n[e];let l={...t,settings:n};return s.save(l),l})},[s]),h=(0,l.useCallback)(e=>n.settings[e]??{},[n]),g=(0,l.useCallback)(e=>n.hidden.includes(e),[n]);return{hydrated:a,hidden:n.hidden,isHidden:g,hide:d,show:u,showAll:m,overridesFor:h,setSetting:x,resetSettings:p,replace:c}}(n,(0,M.useCallback)(t=>e.find(e=>e.id===t)?.settings,[e])),i=(0,M.useMemo)(()=>e.filter(e=>(e.surfaces??["overview"]).includes(n)).map(e=>{let s=function(e,t){let s={};if(!e)return s;for(let n of Object.keys(e))s[n]=function(e,t){switch(e.type){case"number":var s,n;let l;if("number"!=typeof t||!Number.isFinite(t))return e.default;return s=e.min,n=e.max,l=t,"number"==typeof s&&l<s&&(l=s),"number"==typeof n&&l>n&&(l=n),l;case"boolean":return"boolean"==typeof t?t:e.default;case"select":if("string"!=typeof t)return e.default;return e.options.some(e=>e.value===t)?t:e.default}}(e[n],t?.[n]);return s}(e.settings,a.overridesFor(e.id));return{panel:e,panelCtx:{...t,settings:s}}}).filter(({panel:e,panelCtx:t})=>{if(!e.enabled)return!0;try{return e.enabled(t)}catch(t){return console.error(`Panel "${e.id}" enabled() threw; hiding it`,t),!1}}),[e,n,t,a]),o=a.hydrated?i.filter(({panel:e})=>!a.isHidden(e.id)):i,c=a.hydrated?i.filter(({panel:e})=>a.isHidden(e.id)):[];return(0,s.jsxs)(s.Fragment,{children:[c.length>0?(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(T,{hidden:c.map(({panel:e})=>({id:e.id,title:e.title})),onRestore:a.show,onRestoreAll:a.showAll})}):null,o.map(({panel:e,panelCtx:t})=>(0,s.jsx)("div",{className:2===e.span?"lg:col-span-2":void 0,children:(0,s.jsx)(A,{panel:e,ctx:t,revision:r,onHide:()=>a.hide(e.id),settingsForm:e.settings?(0,s.jsx)(z,{panelId:e.id,spec:e.settings,values:t.settings,onChange:(t,s)=>a.setSetting(e.id,t,s),onReset:()=>a.resetSettings(e.id)}):void 0})},e.id))]})}function T({hidden:e,onRestore:t,onRestoreAll:n}){return(0,s.jsxs)("section",{className:"flex flex-wrap items-center gap-2 rounded-xl border border-dashed border-edge bg-panel/60 px-4 py-2.5 text-xs text-fg-muted",children:[(0,s.jsxs)("span",{className:"font-medium uppercase tracking-wide",children:["Hidden panels (",e.length,")"]}),e.map(e=>(0,s.jsxs)("button",{type:"button",onClick:()=>t(e.id),className:"rounded-md border border-edge px-2 py-1 text-fg transition hover:border-amber hover:text-fg-hi",children:["+ ",e.title]},e.id)),(0,s.jsx)("button",{type:"button",onClick:n,className:"ml-auto text-fg-muted underline-offset-2 transition hover:text-amber hover:underline",children:"Show all"})]})}function A({panel:e,ctx:t,revision:n,onHide:r,settingsForm:a}){let{data:i,loading:o,error:c}=function(e,t,s=0){let[n,r]=(0,l.useState)({data:null,loading:!!e.load,error:null}),a=JSON.stringify({params:t.params,settings:t.settings});return(0,l.useEffect)(()=>{if(!e.load)return void r({data:null,loading:!1,error:null});let s=!0,n=new AbortController;return r(e=>({...e,loading:!0,error:null})),e.load({...t,signal:n.signal}).then(e=>{s&&r({data:e,loading:!1,error:null})},e=>{s&&!n.signal.aborted&&r({data:null,loading:!1,error:e instanceof Error?e:Error(String(e))})}),()=>{s=!1,n.abort()}},[e,a,t.surface,t.sessionId,s]),n}(e,t,n),d="function"==typeof e.subtitle?e.subtitle(t):e.subtitle,u=o&&!!e.load&&null==i,m=function(){let[e,t]=(0,M.useState)(!1);return(0,M.useEffect)(()=>t(!0),[]),e}(),x=!e.clientOnly||m;return(0,s.jsx)(_.Panel,{title:e.title,subtitle:d,help:e.help,collapsible:e.collapsible,onHide:r,settings:a,children:x?c?(0,s.jsxs)("p",{className:"text-sm text-fg-muted",children:["Could not load: ",c.message]}):u?(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"Loading…"}):(0,s.jsx)(E,{panelId:e.id,children:e.render({data:i,ctx:t})}):null})}class E extends M.Component{state={error:null};static getDerivedStateFromError(e){return{error:e}}componentDidCatch(e){console.error(`Panel "${this.props.panelId}" failed to render`,e)}componentDidUpdate(e){e.panelId!==this.props.panelId&&this.state.error&&this.setState({error:null})}render(){return this.state.error?(0,s.jsxs)("p",{className:"text-sm text-fg-muted",children:["Could not render: ",this.state.error.message]}):this.props.children}}var I=e.i(18637);function $({bins:e,cellSize:t}){let n=(0,l.useRef)(null);return(0,l.useEffect)(()=>{let t=n.current;if(!t)return;let s=t.getContext("2d");if(!s||(s.clearRect(0,0,360,360),s.fillStyle="#0b0e14",s.fillRect(0,0,360,360),0===e.length))return;let l=1/0,r=-1/0,a=1/0,i=-1/0,o=0;for(let t of e)t.gx<l&&(l=t.gx),t.gx>r&&(r=t.gx),t.gz<a&&(a=t.gz),t.gz>i&&(i=t.gz),t.count>o&&(o=t.count);let c=344/Math.max(r-l+1,i-a+1);for(let t of e){s.fillStyle=f(o>0?t.count/o:0,.9);let e=8+(t.gx-l)*c,n=8+(i-t.gz)*c;s.fillRect(e,n,Math.ceil(c),Math.ceil(c))}},[e,t]),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{className:"flex justify-center",children:(0,s.jsxs)("div",{className:"relative inline-block",children:[(0,s.jsx)("canvas",{ref:n,width:360,height:360,className:"rounded-lg border border-edge","aria-label":"Floor-plan position heatmap"}),e.length>0?(0,s.jsx)(I.HeatLegend,{title:"Dwell density",lowLabel:"rarely",highLabel:"most",note:`${t} m cells`}):null]})}),0===e.length?(0,s.jsx)("p",{className:"mt-2 text-center text-xs text-fg-muted",children:"No camera-position data in range. Capture a first-person session to populate the plan."}):null]})}function D({points:e}){let t=(0,l.useRef)(null);return(0,l.useEffect)(()=>{let s=t.current;if(!s)return;let n=s.getContext("2d");if(!n||(n.clearRect(0,0,360,360),n.fillStyle="#0b0e14",n.fillRect(0,0,360,360),0===e.length))return;let l=1/0,r=-1/0,a=1/0,i=-1/0;for(let t of e)t.gx<l&&(l=t.gx),t.gx>r&&(r=t.gx),t.gz<a&&(a=t.gz),t.gz>i&&(i=t.gz);let o=344/Math.max(r-l+1,i-a+1),c=(e,t)=>[8+(e-l+.5)*o,8+(i-t+.5)*o],d=function(e){let t=new Map;for(let s of e){let e=t.get(s.session_id);e||(e=[],t.set(s.session_id,e));let n=e[e.length-1];n&&n.gx===s.gx&&n.gz===s.gz||e.push({gx:s.gx,gz:s.gz})}return[...t.values()].map(e=>({cells:e}))}(e);for(let e of(n.lineWidth=2,n.lineJoin="round",n.lineCap="round",n.globalCompositeOperation="lighter",n.strokeStyle="rgba(251, 191, 36, 0.18)",d)){if(e.cells.length<2)continue;n.beginPath();let[t,s]=c(e.cells[0].gx,e.cells[0].gz);n.moveTo(t,s);for(let t=1;t<e.cells.length;t++){let[s,l]=c(e.cells[t].gx,e.cells[t].gz);n.lineTo(s,l)}n.stroke()}n.globalCompositeOperation="source-over"},[e]),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{className:"flex justify-center",children:(0,s.jsx)("canvas",{ref:t,width:360,height:360,className:"rounded-lg border border-edge","aria-label":"Aggregate desire-line paths"})}),0===e.length?(0,s.jsx)("p",{className:"mt-2 text-center text-xs text-fg-muted",children:"No camera-path data in range. Capture first-person sessions to populate the desire lines."}):null]})}let F={hover:"#60a5fa",pick:"#34d399",click:"#fbbf24",drag:"#f472b6",select:"#a78bfa",squeeze:"#fb7185",grab:"#22d3ee",release:"#94a3b8",teleport:"#f59e0b"};function L(e){return F[e]??"#64748b"}function O({rows:e,topN:t=8}){let n=function(e,t){let s=new Map;for(let t of e){let e=s.get(t.mesh);e||(e={mesh:t.mesh,total:0,kinds:[]},s.set(t.mesh,e)),e.kinds.push({kind:t.kind,count:t.count}),e.total+=t.count}let n=[...s.values()].sort((e,t)=>t.total-e.total).slice(0,t);for(let e of n)e.kinds.sort((e,t)=>t.count-e.count);return n}(e,t);if(0===n.length)return(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No mesh interactions in range."});let l=[...new Set(e.map(e=>e.kind))];return(0,s.jsxs)("div",{className:"space-y-3",children:[(0,s.jsx)("ul",{className:"space-y-2",children:n.map(e=>(0,s.jsxs)("li",{className:"text-sm",children:[(0,s.jsxs)("div",{className:"flex items-center justify-between gap-3",children:[(0,s.jsx)("span",{className:"truncate font-mono text-xs text-fg",children:e.mesh}),(0,s.jsx)("span",{className:"tabular-nums text-fg-muted",children:b(e.total)})]}),(0,s.jsx)("div",{className:"mt-1 flex h-2 w-full overflow-hidden rounded bg-ink/60",children:e.kinds.map(t=>(0,s.jsx)("div",{className:"h-full",style:{width:`${e.total>0?t.count/e.total*100:0}%`,backgroundColor:L(t.kind)},title:`${t.kind}: ${b(t.count)}`},t.kind))})]},e.mesh))}),(0,s.jsx)("ul",{className:"flex flex-wrap gap-x-3 gap-y-1",children:l.map(e=>(0,s.jsxs)("li",{className:"flex items-center gap-1.5 text-xs text-fg-muted",children:[(0,s.jsx)("span",{className:"inline-block h-2 w-2 rounded-sm",style:{backgroundColor:L(e)}}),e]},e))})]})}let U={mouse:"#60a5fa",touch:"#34d399",stylus:"#a78bfa",pen:"#a78bfa","xr-controller":"#fbbf24",hand:"#f472b6",gaze:"#22d3ee",transient:"#fb7185",keyboard:"#f59e0b",gamepad:"#c084fc",other:"#94a3b8"};function B(e){return U[e]??"#64748b"}function H({buckets:e}){if(e.length<2)return(0,s.jsx)("span",{className:"text-[10px] text-fg-muted",children:"—"});let t=e.reduce((e,t)=>Math.max(e,t),0)||1;return(0,s.jsx)("div",{className:"flex h-5 items-end gap-px","aria-hidden":!0,children:e.map((e,n)=>(0,s.jsx)("div",{className:"w-1 rounded-sm bg-sky-400/70",style:{height:`${Math.max(8,e/t*100)}%`}},n))})}function G({delta:e}){return e>0?(0,s.jsxs)("span",{className:"tabular-nums text-xs text-emerald-400",children:["▲ ",b(e)]}):e<0?(0,s.jsxs)("span",{className:"tabular-nums text-xs text-rose-400",children:["▼ ",b(-e)]}):(0,s.jsx)("span",{className:"text-xs text-fg-muted",children:"—"})}function K({sources:e,trend:t,topN:n=8}){let l=function(e,t,s){let n=new Map;for(let t of e){let e=n.get(t.mesh);e||(e={total:0,sources:new Map},n.set(t.mesh,e)),e.total+=t.count,e.sources.set(t.source,(e.sources.get(t.source)??0)+t.count)}let l=new Map;for(let e of t){let t=l.get(e.mesh);t?t.push(e):l.set(e.mesh,[e])}return[...n.entries()].map(([e,t])=>{let s=(l.get(e)??[]).slice().sort((e,t)=>e.bucket-t.bucket).map(e=>e.count),n=Math.floor(s.length/2),r=s.slice(0,n).reduce((e,t)=>e+t,0),a=s.slice(n).reduce((e,t)=>e+t,0);return{mesh:e,total:t.total,sources:[...t.sources.entries()].map(([e,t])=>({source:e,count:t})).sort((e,t)=>t.count-e.count),buckets:s,delta:a-r}}).sort((e,t)=>t.total-e.total).slice(0,s)}(e,t,n);return 0===l.length?(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No mesh interactions in range."}):(0,s.jsx)("ol",{className:"space-y-2",children:l.map((e,t)=>(0,s.jsx)("li",{className:"text-sm",children:(0,s.jsxs)("details",{className:"group",children:[(0,s.jsxs)("summary",{className:"flex cursor-pointer list-none items-center gap-3",children:[(0,s.jsx)("span",{className:"w-5 shrink-0 text-right tabular-nums text-xs text-fg-muted",children:t+1}),(0,s.jsx)("span",{className:"min-w-0 flex-1 truncate font-mono text-xs text-fg",children:e.mesh}),(0,s.jsx)(H,{buckets:e.buckets}),(0,s.jsx)(G,{delta:e.delta}),(0,s.jsx)("span",{className:"w-12 shrink-0 text-right tabular-nums text-fg-muted",children:b(e.total)})]}),(0,s.jsx)("ul",{className:"mt-1.5 space-y-1 pl-8",children:e.sources.map(t=>(0,s.jsxs)("li",{className:"flex items-center gap-2 text-xs",children:[(0,s.jsx)("span",{className:"inline-block h-2 w-2 shrink-0 rounded-sm",style:{backgroundColor:B(t.source)}}),(0,s.jsx)("span",{className:"w-24 shrink-0 truncate text-fg-muted",children:t.source}),(0,s.jsx)("div",{className:"h-1.5 flex-1 overflow-hidden rounded bg-ink/60",children:(0,s.jsx)("div",{className:"h-full rounded",style:{width:`${e.total>0?t.count/e.total*100:0}%`,backgroundColor:B(t.source)}})}),(0,s.jsx)("span",{className:"w-10 shrink-0 text-right tabular-nums text-fg-muted",children:b(t.count)})]},t.source))})]})},e.mesh))})}let V={mouse:"#60a5fa",touch:"#34d399",stylus:"#a78bfa",pen:"#a78bfa","xr-controller":"#fbbf24",hand:"#f472b6",gaze:"#22d3ee",transient:"#fb7185",keyboard:"#f59e0b",gamepad:"#c084fc",other:"#94a3b8"};function W(e){return V[e]??"#64748b"}function X({sources:e,actions:t,topActions:n=8}){let l=function(e){let t=new Map;for(let s of e)t.set(s.source,(t.get(s.source)??0)+s.count);let s=[...t.values()].reduce((e,t)=>e+t,0);return[...t.entries()].map(([e,t])=>({source:e,count:t,share:s>0?t/s:0})).sort((e,t)=>t.count-e.count)}(e),r=t.slice(0,n);return 0===l.length&&0===r.length?(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No input interactions in range."}):(0,s.jsxs)("div",{className:"space-y-4",children:[(0,s.jsxs)("div",{children:[(0,s.jsx)("h4",{className:"mb-2 text-xs font-semibold uppercase tracking-wide text-fg-muted",children:"Modality share"}),0===l.length?(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No source-bearing interactions in range."}):(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{className:"flex h-3 w-full overflow-hidden rounded bg-ink/60",children:l.map(e=>(0,s.jsx)("div",{className:"h-full",style:{width:`${100*e.share}%`,backgroundColor:W(e.source)},title:`${e.source}: ${b(e.count)}`},e.source))}),(0,s.jsx)("ul",{className:"mt-2 flex flex-wrap gap-x-3 gap-y-1",children:l.map(e=>(0,s.jsxs)("li",{className:"flex items-center gap-1.5 text-xs text-fg-muted",children:[(0,s.jsx)("span",{className:"inline-block h-2 w-2 rounded-sm",style:{backgroundColor:W(e.source)}}),e.source,(0,s.jsxs)("span",{className:"tabular-nums text-fg",children:[Math.round(100*e.share),"%"]})]},e.source))})]})]}),(0,s.jsxs)("div",{children:[(0,s.jsx)("h4",{className:"mb-2 text-xs font-semibold uppercase tracking-wide text-fg-muted",children:"Most-used shortcuts"}),0===r.length?(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No input_action events in range."}):(0,s.jsx)("ul",{className:"space-y-1.5",children:r.map(e=>(0,s.jsxs)("li",{className:"flex items-center gap-2 text-sm",children:[(0,s.jsx)("span",{className:"inline-block h-2 w-2 shrink-0 rounded-sm",style:{backgroundColor:W(e.source)}}),(0,s.jsx)("span",{className:"min-w-0 flex-1 truncate font-mono text-xs text-fg",children:e.action}),(0,s.jsx)("span",{className:"shrink-0 text-xs text-fg-muted",children:e.source}),(0,s.jsx)("span",{className:"w-12 shrink-0 text-right tabular-nums text-fg-muted",children:b(e.count)})]},`${e.action}/${e.source}`))})]})]})}function J({coverage:e,proxyMeshes:t,cellSize:n,topN:l=12}){if(0===t.length)return(0,s.jsxs)("div",{className:"space-y-2 text-sm text-fg-muted",children:[(0,s.jsx)("p",{children:"No scene proxy is registered, so there is no reference geometry to call “dead”."}),(0,s.jsx)("p",{children:"Register proxy geometry (ADR 0014) via the scene representation API to enumerate the regions visitors could approach."})]});if(0===e.length)return(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No camera-position samples in range — every region reads as dead. Widen the range or check that first-person camera samples are being captured."});let r=function(e,t,s,n=1){let l=s*n,r=t.slice(0,600).map(t=>{let n=0;for(let r of e)(function(e,t,s,n,l,r){let a=(e+.5)*n,i=(t+.5)*n,o=(s+.5)*n,[c,d,u,m,x,p]=l;return a>=c-r&&a<=m+r&&i>=d-r&&i<=x+r&&o>=u-r&&o<=p+r})(r.vx,r.vy,r.vz,s,t.aabb,l)&&(n+=r.count);return{mesh:t.name,path:t.path,nearbySamples:n,dead:0===n}});return r.sort((e,t)=>e.nearbySamples-t.nearbySamples),{rows:r,deadCount:r.filter(e=>e.dead).length,total:r.length}}(e,t,n),a=r.rows.reduce((e,t)=>Math.max(e,t.nearbySamples),0)||1,i=r.rows.slice(0,l);return(0,s.jsxs)("div",{className:"space-y-3",children:[(0,s.jsxs)("p",{className:"text-xs text-fg-muted",children:[(0,s.jsx)("span",{className:"tabular-nums text-fg",children:b(r.deadCount)})," of"," ",(0,s.jsx)("span",{className:"tabular-nums text-fg",children:b(r.total)})," proxy meshes are dead (no nearby camera samples)."]}),(0,s.jsx)("ul",{className:"space-y-1.5",children:i.map(e=>(0,s.jsxs)("li",{className:"text-sm",children:[(0,s.jsxs)("div",{className:"flex items-center justify-between gap-3",children:[(0,s.jsx)("span",{className:"truncate font-mono text-xs text-fg",title:e.path??e.mesh,children:e.mesh}),e.dead?(0,s.jsx)("span",{className:"shrink-0 rounded bg-rose-500/20 px-1.5 text-xs text-rose-300",children:"dead"}):(0,s.jsx)("span",{className:"shrink-0 tabular-nums text-xs text-fg-muted",children:b(e.nearbySamples)})]}),(0,s.jsx)("div",{className:"mt-1 h-1.5 w-full overflow-hidden rounded bg-ink/60",children:(0,s.jsx)("div",{className:"h-full rounded bg-sky-500/70",style:{width:`${e.nearbySamples/a*100}%`}})})]},e.path??e.mesh))})]})}function q({label:e,value:t}){return(0,s.jsxs)("div",{className:"rounded-lg bg-ink/60 p-3",children:[(0,s.jsx)("div",{className:"text-xs uppercase tracking-wide text-fg-muted",children:e}),(0,s.jsx)("div",{className:"mt-1 text-2xl font-semibold tabular-nums text-fg-hi",children:t})]})}function Y({bins:e}){if(0===e.length)return(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No FPS samples in range."});let t=[...e].sort((e,t)=>e.bucket-t.bucket),n=t.reduce((e,t)=>Math.max(e,t.sessions),0)||1,l=t.length>1?t[1].bucket-t[0].bucket:10;return(0,s.jsx)("div",{className:"space-y-1.5",children:t.map(e=>(0,s.jsxs)("div",{className:"flex items-center gap-2 text-xs",children:[(0,s.jsxs)("span",{className:"w-16 shrink-0 text-right tabular-nums text-fg-muted",children:[e.bucket,"–",e.bucket+l]}),(0,s.jsx)("div",{className:"h-4 flex-1 overflow-hidden rounded bg-ink/60",children:(0,s.jsx)("div",{className:"h-full rounded bg-emerald-500/70",style:{width:`${e.sessions/n*100}%`}})}),(0,s.jsx)("span",{className:"w-10 shrink-0 tabular-nums text-fg-muted",children:e.sessions})]},e.bucket))})}function Z({distribution:e,histogram:t}){return e&&0!==e.samples?(0,s.jsxs)("div",{className:"space-y-4",children:[(0,s.jsxs)("div",{className:"grid grid-cols-2 gap-3 sm:grid-cols-4",children:[(0,s.jsx)(q,{label:"p05 FPS (worst)",value:b(e.p05_fps,1)}),(0,s.jsx)(q,{label:"p50 FPS (typical)",value:b(e.p50_fps,1)}),(0,s.jsx)(q,{label:"p95 FPS (best)",value:b(e.p95_fps,1)}),(0,s.jsx)(q,{label:"Sessions",value:b(e.sessions)})]}),(0,s.jsx)(Y,{bins:t})]}):(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No performance samples in range."})}function Q(e){return`${Math.round(100*e)}%`}function ee({data:e}){if(!e||0===e.samples)return(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No frame-perf samples in range."});let t=e.p50_fps>=50&&e.p50_render_scale>0&&e.p50_render_scale<.9,n=[{label:"Median FPS",value:b(Math.round(e.p50_fps))},{label:"Avg FPS",value:b(Math.round(e.avg_fps))},{label:"Median render scale",value:Q(e.p50_render_scale)},{label:"Avg render scale",value:Q(e.avg_render_scale)},{label:"Downscaled frames",value:Q(e.downscaled_share)},{label:"Samples",value:b(e.samples)}];return(0,s.jsxs)("div",{className:"space-y-3",children:[(0,s.jsx)("dl",{className:"grid grid-cols-2 gap-x-4 gap-y-3 sm:grid-cols-3",children:n.map(e=>(0,s.jsxs)("div",{children:[(0,s.jsx)("dt",{className:"text-xs text-fg-muted",children:e.label}),(0,s.jsx)("dd",{className:"tabular-nums text-lg text-fg",children:e.value})]},e.label))}),t?(0,s.jsxs)("p",{className:"rounded-md border border-amber/40 bg-amber/10 px-3 py-2 text-xs text-amber",children:["Good FPS is being bought with resolution — the median frame renders at"," ",Q(e.p50_render_scale)," scale. The headline FPS overstates the device experience."]}):null]})}let et={orbit:"Orbit",pan:"Pan",dolly:"Dolly",zoom:"Zoom",roll:"Roll",fly:"Fly",navigate:"Navigate"};function es({stats:e}){let t=[...e].sort((e,t)=>t.gestures-e.gestures),n=t.reduce((e,t)=>e+t.gestures,0),l=t.reduce((e,t)=>Math.max(e,t.gestures),0);return 0===t.length||0===n?(0,s.jsxs)("p",{className:"text-sm text-fg-muted",children:["No camera-navigation gestures in range. Enable ",(0,s.jsx)("code",{children:"cameraGesture"})," capture in the SDK (on by default for Babylon) to populate this."]}):(0,s.jsx)("ul",{className:"space-y-3",children:t.map(e=>{var t,r;let a=n>0?e.gestures/n*100:0;return(0,s.jsxs)("li",{className:"text-sm",children:[(0,s.jsxs)("div",{className:"flex items-center justify-between gap-3",children:[(0,s.jsx)("span",{className:"font-medium text-fg",children:et[t=e.kind]??t.charAt(0).toUpperCase()+t.slice(1)}),(0,s.jsxs)("span",{className:"tabular-nums text-fg-muted",children:[b(e.gestures),(0,s.jsxs)("span",{className:"ml-1 text-xs text-fg-muted",children:["· ",a.toFixed(0),"%"]}),(0,s.jsxs)("span",{className:"ml-2 text-xs text-fg-muted",children:["avg ",!Number.isFinite(r=e.avg_ms)||r<=0?"0 ms":r<1e3?`${Math.round(r)} ms`:`${(r/1e3).toFixed(r<1e4?2:1)} s`]})]})]}),(0,s.jsx)("div",{className:"mt-1 h-1.5 w-full overflow-hidden rounded bg-ink/60",children:(0,s.jsx)("div",{className:"h-full rounded bg-amber",style:{width:`${l>0?e.gestures/l*100:0}%`}})})]},e.kind)})})}let en="#161210",el={fontSize:13,color:"#a8917c"},er={padding:"6px 10px",fontSize:13,borderTop:"1px solid #34291f"};function ea({sessions:e,onSelect:t,selectedId:n}){return 0===e.length?(0,s.jsx)("p",{style:el,children:"No sessions in range."}):(0,s.jsx)("div",{style:{maxHeight:320,overflow:"auto"},children:(0,s.jsxs)("table",{style:{width:"100%",borderCollapse:"collapse",textAlign:"left"},children:[(0,s.jsx)("thead",{children:(0,s.jsxs)("tr",{style:{fontSize:11,textTransform:"uppercase",color:"#a8917c"},children:[(0,s.jsx)("th",{style:{padding:"6px 10px"},children:"Session"}),(0,s.jsx)("th",{style:{padding:"6px 10px"},children:"Visitor"}),(0,s.jsx)("th",{style:{padding:"6px 10px",textAlign:"right"},children:"Events"}),(0,s.jsx)("th",{style:{padding:"6px 10px"},children:"Started"})]})}),(0,s.jsx)("tbody",{children:e.map(e=>{var l;let r,a=e.session_id===n;return(0,s.jsxs)("tr",{onClick:t?()=>t(e.session_id):void 0,style:{cursor:t?"pointer":"default",background:a?"rgba(237,166,62,0.15)":void 0},children:[(0,s.jsx)("td",{style:{...er,fontFamily:"ui-monospace, monospace",color:"#d8c8b8"},children:e.session_id.slice(0,12)}),(0,s.jsx)("td",{style:{...er,fontFamily:"ui-monospace, monospace",color:"#a8917c"},children:e.visitor_id.slice(0,8)}),(0,s.jsx)("td",{style:{...er,textAlign:"right",fontVariantNumeric:"tabular-nums"},children:b(e.events)}),(0,s.jsx)("td",{style:{...er,fontSize:12,color:"#a8917c"},children:Number.isNaN((r=new Date((l=e.started_at).includes("T")?l:l.replace(" ","T")+"Z")).getTime())?l:r.toLocaleString()})]},e.session_id)})})]})})}function ei({bins:e,gridSize:t,size:n=320,className:r,style:a}){let i=(0,l.useRef)(null);return(0,l.useEffect)(()=>{let s=i.current;if(!s)return;let l=s.getContext("2d");l&&function(e,t,s,n){if(e.clearRect(0,0,n,n),e.fillStyle=en,e.fillRect(0,0,n,n),0===t.length)return;let l=t.reduce((e,t)=>Math.max(e,t.count),0),r=n/s;for(let s of t)e.fillStyle=f(l>0?s.count/l:0,.85),e.fillRect(s.gx*r,s.gy*r,Math.ceil(r),Math.ceil(r))}(l,e,t,n)},[e,t,n]),(0,s.jsx)("canvas",{ref:i,width:n,height:n,className:r,style:a,"aria-label":"Pointer heatmap"})}function eo({bins:e,gridSize:t,size:n=340,className:r,style:a}){let i=(0,l.useRef)(null);return(0,l.useEffect)(()=>{let s=i.current;if(!s)return;let l=s.getContext("2d");if(!l)return;let r=Math.min(window.devicePixelRatio||1,2);s.width=n*r,s.height=n*r,l.setTransform(r,0,0,r,0,0),function(e,t,s,n){let l=n/2,r=n/2,a=n/2-18;if(e.clearRect(0,0,n,n),e.fillStyle=en,e.fillRect(0,0,n,n),e.strokeStyle="#34291f",e.lineWidth=1,e.beginPath(),e.arc(l,r,a,0,2*Math.PI),e.stroke(),e.beginPath(),e.arc(l,r,a/2,0,2*Math.PI),e.stroke(),t.length>0){let n=t.reduce((e,t)=>Math.max(e,t.count),0),i=2*Math.PI/s;for(let o of t){let t=n>0?o.count/n:0,c=1-(o.elevation_bin+1)/s,d=1-o.elevation_bin/s,u=Math.max(0,c)*a,m=Math.max(0,d)*a,x=o.azimuth_bin*i,p=x+i;e.beginPath(),e.arc(l,r,m,x,p),e.arc(l,r,u,p,x,!0),e.closePath(),e.fillStyle=f(t,.85),e.fill()}}let i=(t,s,n)=>{e.lineWidth=3,e.strokeStyle="rgba(22,18,16,0.9)",e.strokeText(t,s,n),e.fillStyle="#d8c8b8",e.fillText(t,s,n)};for(let t of(e.font="600 10px ui-sans-serif, system-ui, sans-serif",e.textAlign="left",e.textBaseline="middle",e.strokeStyle="rgba(203,213,225,0.35)",e.lineWidth=1,e.beginPath(),e.moveTo(l,r),e.lineTo(l,r-a),e.stroke(),[0,a/2,a]))e.beginPath(),e.moveTo(l-3,r-t),e.lineTo(l+3,r-t),e.stroke();i("up",l+6,r),i("horizon",l+6,r-a/2),i("down",l+6,r-a+2)}(l,e,t,n)},[e,t,n]),(0,s.jsx)("canvas",{ref:i,className:r,style:{width:n,height:n,...a},"aria-label":"Camera view-direction heatmap: top-down polar plot where the center is looking up, the middle ring is the horizon, and the rim is looking down; color shows how often each direction was viewed."})}let ec={background:"rgba(32,25,19,0.6)",borderRadius:8,padding:12},ed={fontSize:11,textTransform:"uppercase",letterSpacing:"0.04em",color:"#a8917c"},eu={marginTop:4,fontSize:24,fontWeight:600,color:"#f4eadf",fontVariantNumeric:"tabular-nums"};function em({label:e,value:t}){return(0,s.jsxs)("div",{style:ec,children:[(0,s.jsx)("div",{style:ed,children:e}),(0,s.jsx)("div",{style:eu,children:t})]})}function ex({perf:e}){return e&&0!==e.samples?(0,s.jsxs)("div",{style:{display:"grid",gridTemplateColumns:"repeat(2, minmax(0, 1fr))",gap:12},children:[(0,s.jsx)(em,{label:"Samples",value:b(e.samples)}),(0,s.jsx)(em,{label:"Avg FPS",value:b(e.avg_fps,1)}),(0,s.jsx)(em,{label:"p50 FPS",value:b(e.p50_fps,1)}),(0,s.jsx)(em,{label:"Min FPS",value:b(e.min_fps,1)})]}):(0,s.jsx)("p",{style:el,children:"No performance samples in range."})}function ep({bins:e,gridSize:t}){return(0,s.jsx)("div",{className:"flex justify-center",children:(0,s.jsx)(ei,{bins:e,gridSize:t,className:"rounded-lg border border-edge"})})}function eh({meshes:e}){let t=e.reduce((e,t)=>Math.max(e,t.count),0);return 0===e.length?(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No mesh interactions in range."}):(0,s.jsx)("ul",{className:"space-y-1.5",children:e.map(e=>(0,s.jsxs)("li",{className:"text-sm",children:[(0,s.jsxs)("div",{className:"flex items-center justify-between gap-3",children:[(0,s.jsx)("span",{className:"truncate font-mono text-xs text-fg",children:e.mesh}),(0,s.jsx)("span",{className:"tabular-nums text-fg-muted",children:b(e.count)})]}),(0,s.jsx)("div",{className:"mt-1 h-1.5 w-full overflow-hidden rounded bg-ink/60",children:(0,s.jsx)("div",{className:"h-full rounded bg-amber",style:{width:`${t>0?e.count/t*100:0}%`}})})]},e.mesh))})}var eg=e.i(37215);let ef=(0,l.lazy)(()=>e.A(78573).then(e=>({default:e.CameraDome3DView}))),eb=(0,l.lazy)(()=>e.A(47410).then(e=>({default:e.WorldHeatmap3DView}))),ev=(0,l.lazy)(()=>e.A(70162).then(e=>({default:e.FlowSankey3DView}))),ej=(0,l.lazy)(()=>e.A(21269).then(e=>({default:e.GazeClickDivergence3DView})));function ey({children:e}){return(0,s.jsx)(l.Suspense,{fallback:(0,s.jsx)("div",{className:"grid min-h-[12rem] place-items-center text-sm text-fg-muted",children:"Loading 3D view…"}),children:e})}function ew(e){return"session"===e.surface&&e.sessionId?{...e.params,session:e.sessionId}:e.params}async function eN(e){let t=e.params.scene;if(t){let s=await e.api.sceneRepresentation(t).catch(()=>null);return s?.proxy?.meshes??[]}return(0,v.mergeSceneProxies)(e.api,e.params)}let ek=[{id:"top-meshes",title:"Top meshes",subtitle:"Most-interacted meshes",span:1,surfaces:["overview","session"],settings:{limit:{type:"number",label:"Top N",help:"How many meshes to rank in the list.",default:25,min:5,max:100,step:5}},load:e=>e.api.topMeshes({...ew(e),source:void 0,scene:void 0,limit:e.settings.limit}),render:({data:e})=>(0,s.jsx)(eh,{meshes:e??[]})},{id:"mesh-leaderboard",title:"Part-popularity leaderboard",subtitle:"Ranked meshes, with trend and input split",help:"The most-interacted meshes ranked by total active interactions (clicks / hovers / picks / drags — passive gaze is excluded), each with a trend sparkline (rising/falling over the range) and an input-source split (mouse / touch / XR / …). Expand a row to see which sources drove it. Unlike the plain Top-meshes list, gaze-only hits don't inflate the ranking.",span:1,surfaces:["overview","session"],load:async e=>{let[t,s]=await Promise.all([e.api.topMeshesBySource({...ew(e),source:void 0,limit:400}),e.api.topMeshesTrend({...ew(e),source:void 0,interval:function(e){let{since:t,until:s}=e.params;return null==t||null==s||s<=t?3600:x(s-t,24)}(e),limit:2e3})]);return{sources:t,trend:s}},render:({data:e})=>(0,s.jsx)(K,{sources:e.sources??[],trend:e.trend??[]})},{id:"pointer-heatmap",title:"Pointer heatmap",subtitle:"Normalized screen positions",span:1,surfaces:["overview","session"],clientOnly:!0,settings:{bins:{type:"number",label:"Grid resolution",help:"Bins per axis for the 2D pointer grid. More bins sharpen detail; fewer smooth the heat.",default:50,min:10,max:120,step:10}},load:e=>e.api.pointerHeatmap({...ew(e),bins:e.settings.bins}),render:({data:e,ctx:t})=>(0,s.jsx)(ep,{bins:e??[],gridSize:t.settings.bins})},{id:"camera-dome-3d",title:eg.CAMERA_DOME_TITLE,subtitle:eg.CAMERA_DOME_SUBTITLE,span:2,surfaces:["overview","session"],clientOnly:!0,settings:{bins:{type:"number",label:"Direction resolution",help:"Angular bins for the view-direction dome. More bins resolve finer look-directions; fewer aggregate them.",default:36,min:12,max:72,step:6}},load:e=>e.api.cameraHeatmap({...ew(e),source:void 0,bins:e.settings.bins}),render:({data:e,ctx:t})=>(0,s.jsx)(ey,{children:(0,s.jsx)(ef,{bins:e??[],gridSize:t.settings.bins})})},{id:"floor-plan",title:"Floor-plan heatmap",subtitle:"Where visitors stand (top-down, first-person)",help:"Camera positions binned on the ground plane — the first-person counterpart of the pointer heatmap. Filter to the first-person camera mode to isolate walkable sessions.",span:1,surfaces:["overview","session"],clientOnly:!0,settings:{cellSize:{type:"number",label:"Cell size",help:"Ground-plane bin size in world units. Larger cells smooth the dwell heat; smaller cells sharpen spatial resolution.",default:1,min:.25,max:5,step:.25,unit:"m"}},enabled:e=>"viewer"!==e.filters.cameraMode,load:e=>e.api.cameraPositionHeatmap({...ew(e),cellSize:e.settings.cellSize}),render:({data:e,ctx:t})=>(0,s.jsx)($,{bins:e??[],cellSize:t.settings.cellSize})},{id:"desire-lines",title:"Desire lines",subtitle:"The routes visitors actually walk",help:"Every session's camera path, binned onto the ground plane and overlaid as a faint poly-line. Where many visitors walk the same way the lines pile up into bright 'desire lines' — the routes people take vs. the ones the scene intended. Filter to the first-person camera mode to isolate walkable sessions.",span:1,surfaces:["overview"],clientOnly:!0,enabled:e=>"viewer"!==e.filters.cameraMode,load:e=>e.api.aggregatePaths({...ew(e),cellSize:1}),render:({data:e})=>(0,s.jsx)(D,{points:e??[]})},{id:"mesh-interaction-kinds",title:"Interaction kinds",subtitle:"How visitors act on each mesh",help:"Per-mesh breakdown of interaction kinds (hover, pick, click, drag, …) from mesh_interaction events. The dwell ranking says which objects draw attention; this says how people act on them — a hovered-but-never-picked mesh reads very differently from a dragged one.",span:1,surfaces:["overview","session"],load:e=>e.api.meshKinds({...ew(e),limit:200}),render:({data:e})=>(0,s.jsx)(O,{rows:e??[]})},{id:"input-modality-split",title:"Input-modality split",subtitle:"Keyboard / gamepad / touch / XR — and top shortcuts",help:"How visitors drive the experience: the share of interactions per input source (mouse / touch / keyboard / gamepad / XR), from the input-source breakdown (ADR 0011), paired with the most-used app-level shortcuts/actions from input_action events (ADR 0023).",span:1,surfaces:["overview","session"],load:async e=>{let[t,s]=await Promise.all([e.api.interactionsBySource({...ew(e),source:void 0,limit:100}),e.api.topInputActions({...ew(e),source:void 0,limit:50})]);return{sources:t,actions:s}},render:({data:e})=>(0,s.jsx)(X,{sources:e.sources??[],actions:e.actions??[]})},{id:"render-scale-truth",title:"Render-scale truth",subtitle:"Is that FPS real, or downscaled?",help:"Adaptive renderers keep frame rate up by quietly dropping resolution. This pairs the FPS headline with the render scale that bought it, and flags the 'good FPS at a low render scale' case where the headline overstates the real device experience.",span:1,surfaces:["overview","session"],load:e=>e.api.renderScale(ew(e)),render:({data:e})=>(0,s.jsx)(ee,{data:e})},{id:"perf-distribution",title:"Performance distribution",subtitle:"p05 / p50 / p95 FPS bands, not just the average",help:"The shape of rendering performance, not a single average: p05 (worst), p50 (typical) and p95 (best) FPS computed per-session then aggregated (ADR 0028 §1), plus a histogram of per-session median FPS. One session contributes one data point, so a few chatty sessions can't skew the curve.",span:1,surfaces:["overview","session"],load:async e=>{let[t,s]=await Promise.all([e.api.perfDistribution(ew(e)),e.api.fpsHistogram(ew(e))]);return{distribution:t,histogram:s}},render:({data:e})=>(0,s.jsx)(Z,{distribution:e.distribution,histogram:e.histogram??[]})},{id:"world-heatmap-3d",title:eg.WORLD_HEATMAP_TITLE,subtitle:eg.WORLD_HEATMAP_SUBTITLE,span:2,surfaces:["overview","session"],clientOnly:!0,settings:{cellSize:{type:"number",label:"Voxel size",help:"World-space voxel size for binning pointer hits. Larger voxels smooth the heat; smaller ones sharpen spatial detail.",default:.5,min:.1,max:2,step:.1,unit:"m"}},load:async e=>{let[t,s,n]=await Promise.all([e.api.worldHeatmap({...ew(e),cellSize:e.settings.cellSize}),eN(e),e.api.worldHeatmapStats({...ew(e),cellSize:e.settings.cellSize})]);return{voxels:t,proxyMeshes:s,totals:{cells:n.cells,hits:n.hits}}},render:({data:e,ctx:t})=>(0,s.jsx)(ey,{children:(0,s.jsx)(eb,{voxels:e.voxels,cellSize:t.settings.cellSize,proxyMeshes:e.proxyMeshes,totals:e.totals})})},{id:"navigation-mix",title:"Navigation-style mix",subtitle:"Orbit / pan / dolly / zoom / roll / fly share + avg gesture duration",span:1,surfaces:["overview","session"],load:e=>e.api.cameraGestures({...ew(e),source:void 0}),render:({data:e})=>(0,s.jsx)(es,{stats:e??[]})},{id:"dead-zone-report",title:"Dead-zone report",subtitle:"Scene parts visitors never approach",help:"The negative space: registered proxy meshes (ADR 0014) with near-zero camera proximity, computed by subtracting the occupied camera-position voxels (scene coverage) from the scene's proxy geometry. Ranked coldest first. Requires a registered scene proxy to know which regions could be visited.",span:1,surfaces:["overview","session"],load:async e=>{let[t,s]=await Promise.all([e.api.coverage({...ew(e),cellSize:1}),eN(e)]);return{coverage:t,proxyMeshes:s}},render:({data:e})=>(0,s.jsx)(J,{coverage:e.coverage??[],proxyMeshes:e.proxyMeshes??[],cellSize:1})},{id:"flow-sankey-3d",title:eg.FLOW_SANKEY_TITLE,subtitle:eg.FLOW_SANKEY_SUBTITLE,help:eg.FLOW_SANKEY_HELP,span:2,surfaces:["overview","session"],clientOnly:!0,settings:{maxLinks:{type:"number",label:"Max links",help:"Maximum aggregate flow links drawn before the panel caps for legibility.",default:80,min:10,max:200,step:10}},load:async e=>{let t={...ew(e),cameraMode:void 0},[s,n]=await Promise.all([e.api.flowHeatmap({...t,bins:36,limit:400,groupByOrigin:!0}),eN(e)]);return{links:s,proxyMeshes:n,flowQuery:t}},render:({data:e,ctx:t})=>(0,s.jsx)(ey,{children:(0,s.jsx)(ev,{links:e.links,gridSize:36,proxyMeshes:e.proxyMeshes,maxLinks:t.settings.maxLinks,baseUrl:t.baseUrl,apiKey:t.apiKey,flowQuery:e.flowQuery,hasFirstPerson:t.capabilities.hasFirstPerson})})},{id:"gaze-click-divergence-3d",title:eg.GAZE_CLICK_TITLE,subtitle:eg.GAZE_CLICK_SUBTITLE,span:2,surfaces:["overview","session"],clientOnly:!0,settings:{cellSize:{type:"number",label:"Voxel size",help:"Shared world-space voxel size for both the gaze and click grids, so the divergence field stays aligned.",default:.5,min:.1,max:2,step:.1,unit:"m"}},load:async e=>{let[t,s,n]=await Promise.all([e.api.gazeHeatmap({...ew(e),source:void 0,cellSize:e.settings.cellSize}),e.api.worldHeatmap({...ew(e),cellSize:e.settings.cellSize}),eN(e)]);return{gaze:t,click:s,proxyMeshes:n}},render:({data:e,ctx:t})=>(0,s.jsx)(ey,{children:(0,s.jsx)(ej,{gazeVoxels:e.gaze,clickVoxels:e.click,cellSize:t.settings.cellSize,proxyMeshes:e.proxyMeshes})})}];function eS(e){return e?e.split(",").map(e=>e.trim()).filter(e=>e.length>0):[]}let eM={panels:[],errors:[],loading:!1};function eP({errors:e}){let[t,n]=(0,l.useState)(!1);return 0===e.length||t?null:(0,s.jsxs)("section",{className:"rounded-xl border border-dashed border-amber/60 bg-panel/60 px-4 py-3 text-xs text-fg-muted",children:[(0,s.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,s.jsxs)("span",{className:"font-medium uppercase tracking-wide text-fg",children:[e.length," panel",1===e.length?"":"s"," failed to load"]}),(0,s.jsx)("button",{type:"button",onClick:()=>n(!0),className:"text-fg-muted underline-offset-2 transition hover:text-amber hover:underline",children:"Dismiss"})]}),(0,s.jsx)("ul",{className:"mt-2 space-y-1",children:e.map((e,t)=>(0,s.jsxs)("li",{className:"font-mono",children:[(0,s.jsx)("span",{className:"text-fg",children:e.source}),(0,s.jsxs)("span",{className:"text-fg-muted",children:[" ","— [",e.code,"] ",e.message]})]},`${e.source}-${t}`))})]})}function eC({bins:e,gridSize:t}){return(0,s.jsx)(_.Panel,{title:"View-direction heatmap",subtitle:"Top-down sphere — center = looking up, rim = looking down",help:(0,s.jsxs)(s.Fragment,{children:["A flattened top-down view of where the camera pointed."," ",(0,s.jsx)("strong",{children:"Distance from the center"})," is the up/down tilt: the ",(0,s.jsx)("strong",{children:"center"})," ","is looking straight up, the ",(0,s.jsx)("strong",{children:"middle ring"})," is the horizon (level), and the"," ",(0,s.jsx)("strong",{children:"outer rim"})," is looking straight down. The"," ",(0,s.jsx)("strong",{children:"angle around the disc"})," is the facing (azimuth) direction. Color shows how often each direction was viewed, normalized to the most-viewed direction in range."]}),children:(0,s.jsxs)("div",{className:"flex flex-col items-center gap-3",children:[(0,s.jsx)(eo,{bins:e,gridSize:t,className:"rounded-lg border border-edge"}),e.length>0?(0,s.jsxs)("div",{className:"flex items-center gap-2 text-[10px] text-fg-muted",children:[(0,s.jsx)("span",{className:"font-medium text-fg",children:"View density"}),(0,s.jsx)("span",{children:"rarely"}),(0,s.jsx)("span",{className:"h-2 w-28 rounded-sm",style:{background:g.HEAT_GRADIENT}}),(0,s.jsx)("span",{children:"most-viewed"})]}):null]})})}function e_(e){return null==e?"":new Date(e-6e4*new Date(e).getTimezoneOffset()).toISOString().slice(0,16)}function ez(e){if(!e)return;let t=new Date(e).getTime();return Number.isNaN(t)?void 0:t}function eR({filters:e,scenes:t,onChange:n,busy:l}){let r=t=>n({...e,...t});return(0,s.jsxs)("section",{className:"mb-6 flex flex-wrap items-end gap-x-4 gap-y-3 rounded-xl border border-edge bg-panel p-4",children:[(0,s.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,s.jsx)("span",{className:"text-xs text-fg-muted",children:"Time window"}),(0,s.jsxs)("div",{className:"flex flex-wrap gap-1",role:"group","aria-label":"Time window",children:[o.map(t=>{let n=e.window===t.id;return(0,s.jsx)("button",{type:"button",onClick:()=>r({window:t.id}),className:`rounded-md border px-2.5 py-1.5 text-xs transition ${n?"border-amber bg-amber/10 text-saffron":"border-edge text-fg hover:border-amber/60 hover:text-fg-hi"}`,children:t.label},t.id)}),(0,s.jsx)("button",{type:"button",onClick:()=>r({window:"custom",since:e.since??Date.now()-864e5,until:e.until??Date.now()}),className:`rounded-md border px-2.5 py-1.5 text-xs transition ${"custom"===e.window?"border-amber bg-amber/10 text-saffron":"border-edge text-fg hover:border-amber/60 hover:text-fg-hi"}`,children:"Custom"})]})]}),"custom"===e.window?(0,s.jsxs)("div",{className:"flex items-end gap-2",children:[(0,s.jsxs)("label",{className:"flex flex-col gap-1 text-xs text-fg-muted",children:["From",(0,s.jsx)("input",{type:"datetime-local",value:e_(e.since),onChange:e=>r({since:ez(e.target.value)}),className:"rounded-md border border-edge bg-ink px-2 py-1.5 text-xs text-fg outline-none focus:border-saffron"})]}),(0,s.jsxs)("label",{className:"flex flex-col gap-1 text-xs text-fg-muted",children:["To",(0,s.jsx)("input",{type:"datetime-local",value:e_(e.until),onChange:e=>r({until:ez(e.target.value)}),className:"rounded-md border border-edge bg-ink px-2 py-1.5 text-xs text-fg outline-none focus:border-saffron"})]})]}):null,(0,s.jsxs)("label",{className:"flex flex-col gap-1 text-xs text-fg-muted",children:["Scene",(0,s.jsxs)("select",{value:e.scene??"",onChange:e=>r({scene:e.target.value||void 0}),className:"min-w-40 rounded-md border border-edge bg-ink px-2 py-1.5 text-xs text-fg outline-none focus:border-saffron",children:[(0,s.jsx)("option",{value:"",children:"All scenes"}),t.map(e=>(0,s.jsxs)("option",{value:e.scene_id,children:[e.scene_id," (",e.events.toLocaleString(),")"]},e.scene_id))]})]}),(0,s.jsxs)("label",{className:"flex flex-col gap-1 text-xs text-fg-muted",children:["Input source",(0,s.jsxs)("select",{value:e.source??"",onChange:e=>r({source:e.target.value||void 0}),className:"min-w-36 rounded-md border border-edge bg-ink px-2 py-1.5 text-xs text-fg outline-none focus:border-saffron",children:[(0,s.jsx)("option",{value:"",children:"All sources"}),h.map(e=>(0,s.jsx)("option",{value:e,children:p(e)},e))]})]}),(0,s.jsxs)("label",{className:"flex flex-col gap-1 text-xs text-fg-muted",children:["Camera mode",(0,s.jsxs)("select",{value:e.cameraMode??"",onChange:e=>r({cameraMode:e.target.value||void 0}),className:"min-w-36 rounded-md border border-edge bg-ink px-2 py-1.5 text-xs text-fg outline-none focus:border-saffron",children:[(0,s.jsx)("option",{value:"",children:"All cameras"}),(0,s.jsx)("option",{value:"viewer",children:"Viewer (orbit)"}),(0,s.jsx)("option",{value:"first-person",children:"First-person (walk)"})]})]}),(0,s.jsx)("span",{className:`ml-auto text-xs ${l?"text-saffron":"text-fg-muted"}`,"aria-live":"polite",children:l?"Refreshing…":"Up to date"})]})}function eT({rows:e}){let t=function(e){let t=new Map;for(let s of e){let e=t.get(s.source);e||(e={source:s.source,total:0,sessions:0,byType:[]},t.set(s.source,e)),e.total+=s.count,e.sessions=Math.max(e.sessions,s.sessions),e.byType.push({event_type:s.event_type,count:s.count})}for(let e of t.values())e.byType.sort((e,t)=>t.count-e.count);return[...t.values()].sort((e,t)=>t.total-e.total)}(e),n=t.reduce((e,t)=>Math.max(e,t.total),0);return(0,s.jsx)(_.Panel,{title:"Input sources",subtitle:"Interactions by input source",children:0===t.length?(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No source-bearing interactions in range."}):(0,s.jsx)("ul",{className:"space-y-3",children:t.map(e=>(0,s.jsxs)("li",{className:"text-sm",children:[(0,s.jsxs)("div",{className:"flex items-center justify-between gap-3",children:[(0,s.jsx)("span",{className:"font-medium text-fg",children:p(e.source)}),(0,s.jsxs)("span",{className:"tabular-nums text-fg-muted",children:[b(e.total),(0,s.jsxs)("span",{className:"ml-1 text-xs text-fg-muted",children:["· ",b(e.sessions)," ",1===e.sessions?"session":"sessions"]})]})]}),(0,s.jsx)("div",{className:"mt-1 h-1.5 w-full overflow-hidden rounded bg-ink/60",children:(0,s.jsx)("div",{className:"h-full rounded bg-amber",style:{width:`${n>0?e.total/n*100:0}%`}})}),(0,s.jsx)("div",{className:"mt-1.5 flex flex-wrap gap-1.5",children:e.byType.map(e=>{let t;return(0,s.jsxs)("span",{className:"rounded bg-ink/60 px-1.5 py-0.5 font-mono text-[11px] text-fg-muted",children:[(t=e.event_type.replace(/_/g," ")).charAt(0).toUpperCase()+t.slice(1)," ",b(e.count)]},e.event_type)})})]},e.source))})})}function eA({perf:e}){return(0,s.jsx)(_.Panel,{title:"Rendering performance",subtitle:"frame_perf samples",children:(0,s.jsx)(ex,{perf:e})})}function eE({label:e,value:t,unit:n}){return(0,s.jsxs)("div",{className:"rounded-lg bg-ink/60 p-3",children:[(0,s.jsx)("div",{className:"text-xs uppercase tracking-wide text-fg-muted",children:e}),(0,s.jsxs)("div",{className:"mt-1 text-2xl font-semibold tabular-nums text-fg-hi",children:[t,n?(0,s.jsx)("span",{className:"ml-1 text-sm font-normal text-fg-muted",children:n}):null]})]})}function eI(e){return b(e/1048576,1)}function e$({bins:e}){if(0===e.length)return(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No FPS samples in range."});let t=[...e].sort((e,t)=>e.bucket-t.bucket),n=t.reduce((e,t)=>Math.max(e,t.sessions),0)||1,l=t.length>1?t[1].bucket-t[0].bucket:10;return(0,s.jsx)("div",{className:"space-y-1.5",children:t.map(e=>(0,s.jsxs)("div",{className:"flex items-center gap-2 text-xs",children:[(0,s.jsxs)("span",{className:"w-16 shrink-0 text-right tabular-nums text-fg-muted",children:[e.bucket,"–",e.bucket+l]}),(0,s.jsx)("div",{className:"h-4 flex-1 overflow-hidden rounded bg-ink/60",children:(0,s.jsx)("div",{className:"h-full rounded bg-emerald-500/70",style:{width:`${e.sessions/n*100}%`}})}),(0,s.jsx)("span",{className:"w-10 shrink-0 tabular-nums text-fg-muted",children:e.sessions})]},e.bucket))})}function eD({data:e}){let{distribution:t,histogram:n,frameTime:l,jank:r,byDevice:a,byScene:i,resources:o,stability:c}=e,d=(t?.samples??0)>0;return(0,s.jsxs)("section",{className:"space-y-4",children:[(0,s.jsx)("h2",{className:"text-sm font-semibold uppercase tracking-wide text-fg-muted",children:"Performance"}),(0,s.jsx)(_.Panel,{title:"FPS distribution",subtitle:"per-session p05 / p50 / p95, summarized across sessions",children:d?(0,s.jsxs)("div",{className:"space-y-4",children:[(0,s.jsxs)("div",{className:"grid grid-cols-2 gap-3 sm:grid-cols-4",children:[(0,s.jsx)(eE,{label:"p05 FPS (worst)",value:b(t.p05_fps,1)}),(0,s.jsx)(eE,{label:"p50 FPS (typical)",value:b(t.p50_fps,1)}),(0,s.jsx)(eE,{label:"p95 FPS (best)",value:b(t.p95_fps,1)}),(0,s.jsx)(eE,{label:"Sessions",value:b(t.sessions)})]}),(0,s.jsx)(e$,{bins:n})]}):(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No performance samples in range."})}),(0,s.jsxs)("div",{className:"grid grid-cols-1 gap-4 lg:grid-cols-2",children:[(0,s.jsx)(_.Panel,{title:"Frame time",subtitle:"per-session median & worst-window p95",children:l&&0!==l.sessions?(0,s.jsxs)("div",{className:"grid grid-cols-2 gap-3",children:[(0,s.jsx)(eE,{label:"p50 frame time",value:b(l.p50_ms,1),unit:"ms"}),(0,s.jsx)(eE,{label:"p95 frame time",value:b(l.p95_ms,1),unit:"ms"})]}):(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No frame-time samples in range."})}),(0,s.jsx)(_.Panel,{title:"Jank",subtitle:"long frames per sample window",children:r&&0!==r.sessions?(0,s.jsxs)("div",{className:"grid grid-cols-2 gap-3",children:[(0,s.jsx)(eE,{label:"Median session",value:b(r.median_rate,2)}),(0,s.jsx)(eE,{label:"Worst decile",value:b(r.worst_decile_rate,2)})]}):(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No jank data in range."})})]}),(0,s.jsx)(_.Panel,{title:"FPS by device",subtitle:"per-session median FPS, by session_start.device + UA-derived browser/OS",children:0===a.length?(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No device data in range."}):(0,s.jsx)("div",{className:"overflow-x-auto",children:(0,s.jsxs)("table",{className:"w-full text-left text-sm",children:[(0,s.jsx)("thead",{className:"text-xs uppercase tracking-wide text-fg-muted",children:(0,s.jsxs)("tr",{children:[(0,s.jsx)("th",{className:"py-1 pr-4 font-medium",children:"Backend"}),(0,s.jsx)("th",{className:"py-1 pr-4 font-medium",children:"Browser"}),(0,s.jsx)("th",{className:"py-1 pr-4 font-medium",children:"OS"}),(0,s.jsx)("th",{className:"py-1 pr-4 font-medium",children:"Mobile"}),(0,s.jsx)("th",{className:"py-1 pr-4 font-medium",children:"GPU"}),(0,s.jsx)("th",{className:"py-1 pr-4 text-right font-medium",children:"Sessions"}),(0,s.jsx)("th",{className:"py-1 text-right font-medium",children:"p50 FPS"})]})}),(0,s.jsx)("tbody",{className:"text-fg",children:a.map((e,t)=>(0,s.jsxs)("tr",{className:"border-t border-ink/60",children:[(0,s.jsx)("td",{className:"py-1 pr-4",children:e.engine||"—"}),(0,s.jsx)("td",{className:"py-1 pr-4",children:e.browser||"—"}),(0,s.jsx)("td",{className:"py-1 pr-4",children:e.os||"—"}),(0,s.jsx)("td",{className:"py-1 pr-4",children:"true"===e.is_mobile?"yes":"no"}),(0,s.jsx)("td",{className:"py-1 pr-4 max-w-[16rem] truncate",title:e.renderer,children:e.renderer||"—"}),(0,s.jsx)("td",{className:"py-1 pr-4 text-right tabular-nums",children:b(e.sessions)}),(0,s.jsx)("td",{className:"py-1 text-right tabular-nums",children:b(e.p50_fps,1)})]},`${e.engine}|${e.browser}|${e.os}|${e.is_mobile}|${e.renderer}|${t}`))})]})})}),(0,s.jsxs)("div",{className:"grid grid-cols-1 gap-4 lg:grid-cols-2",children:[(0,s.jsx)(_.Panel,{title:"FPS by scene",subtitle:"per-session median FPS per scene",children:0===i.length?(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No scene data in range."}):(0,s.jsxs)("table",{className:"w-full text-left text-sm",children:[(0,s.jsx)("thead",{className:"text-xs uppercase tracking-wide text-fg-muted",children:(0,s.jsxs)("tr",{children:[(0,s.jsx)("th",{className:"py-1 pr-4 font-medium",children:"Scene"}),(0,s.jsx)("th",{className:"py-1 pr-4 text-right font-medium",children:"Sessions"}),(0,s.jsx)("th",{className:"py-1 text-right font-medium",children:"p50 FPS"})]})}),(0,s.jsx)("tbody",{className:"text-fg",children:i.map(e=>(0,s.jsxs)("tr",{className:"border-t border-ink/60",children:[(0,s.jsx)("td",{className:"py-1 pr-4",children:e.scene_id||"—"}),(0,s.jsx)("td",{className:"py-1 pr-4 text-right tabular-nums",children:b(e.sessions)}),(0,s.jsx)("td",{className:"py-1 text-right tabular-nums",children:b(e.p50_fps,1)})]},e.scene_id))})]})}),(0,s.jsx)(_.Panel,{title:"Stability",subtitle:"hard failures frame_perf can't show",children:c?(0,s.jsxs)("div",{className:"grid grid-cols-3 gap-3",children:[(0,s.jsx)(eE,{label:"Context losses",value:b(c.context_losses)}),(0,s.jsx)(eE,{label:"Compile stalls",value:b(c.compile_stalls)}),(0,s.jsx)(eE,{label:"Incidents",value:b(c.incidents)})]}):(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No stability data in range."})})]}),(0,s.jsx)(_.Panel,{title:"Resource footprint",subtitle:"per-session p50 / p95 of what the scene asked of the device",children:o&&0!==o.sessions?(0,s.jsxs)("div",{className:"grid grid-cols-2 gap-3 sm:grid-cols-3",children:[(0,s.jsx)(eE,{label:"p50 JS heap",value:eI(o.p50_js_heap_bytes),unit:"MB"}),(0,s.jsx)(eE,{label:"p50 texture",value:eI(o.p50_texture_bytes),unit:"MB"}),(0,s.jsx)(eE,{label:"p50 triangles",value:b(o.p50_triangles)}),(0,s.jsx)(eE,{label:"p95 JS heap",value:eI(o.p95_js_heap_bytes),unit:"MB"}),(0,s.jsx)(eE,{label:"p95 texture",value:eI(o.p95_texture_bytes),unit:"MB"}),(0,s.jsx)(eE,{label:"p95 triangles",value:b(o.p95_triangles)})]}):(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No resource samples in range."})})]})}function eF({label:e,value:t,tone:n="neutral",hint:l}){return(0,s.jsxs)("div",{className:"rounded-lg border border-edge bg-ink/40 px-3 py-2.5",children:[(0,s.jsx)("p",{className:"text-xs uppercase tracking-wide text-fg-muted",children:e}),(0,s.jsx)("p",{className:`mt-0.5 text-lg font-semibold tabular-nums ${"bad"===n?"text-red-300":"warn"===n?"text-amber-300":"good"===n?"text-emerald-300":"text-fg-hi"}`,children:t}),l?(0,s.jsx)("p",{className:"text-[11px] text-fg-muted",children:l}):null]})}function eL({counts:e,perf:t}){let n=new Map(e.map(e=>[e.event_type,e.count])),l=e=>n.get(e)??0,r=l("session_start"),a=l("runtime_error"),i=l("context_lost"),o=l("focus_change"),c=l("visibility_change"),d=l("viewport_resize"),u=e.reduce((e,t)=>e+t.count,0),m=r>0?a/r:0;return(0,s.jsx)(_.Panel,{title:"Scene health",subtitle:"Errors, GPU context loss & attention gaps in the selected window",children:u>0?(0,s.jsxs)("div",{className:"grid grid-cols-2 gap-2 sm:grid-cols-3",children:[(0,s.jsx)(eF,{label:"Errors",value:b(a),tone:a>0?"bad":"good",hint:r>0?`${m.toFixed(2)} / session`:void 0}),(0,s.jsx)(eF,{label:"Context loss",value:b(i),tone:i>0?"warn":"good",hint:"GPU device lost"}),(0,s.jsx)(eF,{label:"Avg FPS",value:t&&t.samples>0?b(t.avg_fps,1):"—",tone:t&&t.samples>0?t.avg_fps>=50?"good":"warn":"neutral",hint:t&&t.samples>0?`min ${b(t.min_fps,0)}`:void 0}),(0,s.jsx)(eF,{label:"Sessions",value:b(r)}),(0,s.jsx)(eF,{label:"Attention",value:b(o+c),hint:"focus + visibility changes"}),(0,s.jsx)(eF,{label:"Resizes",value:b(d),hint:"viewport changes"})]}):(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No events in range."})})}let eO=["fatal","error","warning","info"];function eU(e){let t=eO.indexOf(e);return -1===t?eO.length:t}function eB({label:e,value:t,tone:n="neutral"}){return(0,s.jsxs)("div",{className:"rounded-lg border border-edge bg-ink/40 px-3 py-2.5",children:[(0,s.jsx)("p",{className:"truncate text-xs uppercase tracking-wide text-fg-muted",title:e,children:e}),(0,s.jsx)("p",{className:`mt-0.5 text-lg font-semibold tabular-nums ${"bad"===n?"text-red-300":"warn"===n?"text-amber-300":"text-fg-hi"}`,children:t})]})}function eH({title:e,buckets:t,tones:n}){return(0,s.jsxs)("div",{children:[(0,s.jsx)("p",{className:"mb-1.5 text-xs font-medium uppercase tracking-wide text-fg-muted",children:e}),(0,s.jsx)("div",{className:"grid grid-cols-2 gap-2 sm:grid-cols-3",children:t.map(e=>(0,s.jsx)(eB,{label:e.label,value:b(e.count),tone:n?.(e)},e.key))})]})}function eG({rows:e}){let{bySeverity:t,byCategory:n,byBackend:l,total:r}=function(e){let t=new Map,s=new Map,n=new Map,l=0;for(let r of e){let e=Number(r.incidents)||0;if(e<=0)continue;l+=e,t.set(r.severity,(t.get(r.severity)??0)+e),s.set(r.category,(s.get(r.category)??0)+e);let a=""===r.backend?"unknown":r.backend;n.set(a,(n.get(a)??0)+e)}let r=e=>[...e.entries()].map(([e,t])=>({key:e,label:e,count:t})),a=r(t).sort((e,t)=>eU(e.key)-eU(t.key)||e.key.localeCompare(t.key)),i=(e,t)=>t.count-e.count||e.key.localeCompare(t.key);return{bySeverity:a,byCategory:r(s).sort(i),byBackend:r(n).sort(i),total:l}}(e);return(0,s.jsx)(_.Panel,{title:"Engine diagnostics",subtitle:"GPU-health incidents by severity, category & backend in the selected window",children:0===r?(0,s.jsxs)("div",{className:"space-y-1.5",children:[(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No engine diagnostics in range."}),(0,s.jsxs)("p",{className:"text-xs text-fg-muted",children:["Engine diagnostics (",(0,s.jsx)("code",{className:"text-fg-hi",children:"graphics_diagnostic"}),") are"," ",(0,s.jsx)("span",{className:"text-fg-hi",children:"opt-in and off by default"}),". Enable"," ",(0,s.jsx)("code",{className:"text-fg-hi",children:"captureGraphicsDiagnostics"})," in the SDK to surface GPU errors, device losses, and shader-compile failures here."]})]}):(0,s.jsxs)("div",{className:"space-y-4",children:[(0,s.jsx)(eH,{title:"By severity",buckets:t,tones:e=>{var t;return"fatal"===(t=e.key)||"error"===t?"bad":"warning"===t?"warn":"neutral"}}),(0,s.jsx)(eH,{title:"By category",buckets:n}),(0,s.jsx)(eH,{title:"By backend",buckets:l})]})})}function eK({label:e,value:t}){return(0,s.jsxs)("div",{className:"rounded-lg border border-edge bg-ink/40 px-3 py-2.5",children:[(0,s.jsx)("p",{className:"truncate text-xs uppercase tracking-wide text-fg-muted",title:e,children:e}),(0,s.jsx)("p",{className:"mt-0.5 text-lg font-semibold tabular-nums text-fg-hi",children:t})]})}function eV({title:e,buckets:t}){return(0,s.jsxs)("div",{children:[(0,s.jsx)("p",{className:"mb-1.5 text-xs font-medium uppercase tracking-wide text-fg-muted",children:e}),(0,s.jsx)("div",{className:"grid grid-cols-2 gap-2 sm:grid-cols-3",children:t.map(e=>(0,s.jsx)(eK,{label:e.label,value:b(e.count)},e.key))})]})}function eW({rows:e}){let{byApi:t,byBackend:n,byShadingLanguage:l,total:r}=function(e){let t=new Map,s=new Map,n=new Map,l=0;for(let r of e){let e=Number(r.sessions)||0;if(e<=0)continue;l+=e;let a=(t,s)=>{let n=""===s?"unknown":s;t.set(n,(t.get(n)??0)+e)};a(t,r.api),a(s,r.backend),a(n,r.shadingLanguage)}let r=(e,t)=>t.count-e.count||e.key.localeCompare(t.key),a=e=>[...e.entries()].map(([e,t])=>({key:e,label:e,count:t})).sort(r);return{byApi:a(t),byBackend:a(s),byShadingLanguage:a(n),total:l}}(e);return(0,s.jsx)(_.Panel,{title:"Rendering technology",subtitle:"Sessions by graphics API, backend & shading language in the selected window",children:0===r?(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No sessions in range."}):(0,s.jsxs)("div",{className:"space-y-4",children:[(0,s.jsx)(eV,{title:"By API",buckets:t}),(0,s.jsx)(eV,{title:"By backend",buckets:n}),(0,s.jsx)(eV,{title:"By shading language",buckets:l})]})})}function eX({label:e,value:t,hint:n}){return(0,s.jsxs)("div",{className:"rounded-lg border border-edge bg-ink/40 px-3 py-2.5",children:[(0,s.jsx)("p",{className:"text-xs uppercase tracking-wide text-fg-muted",children:e}),(0,s.jsx)("p",{className:"mt-0.5 text-lg font-semibold tabular-nums text-fg-hi",children:t}),n?(0,s.jsx)("p",{className:"text-[11px] text-fg-muted",children:n}):null]})}function eJ({buckets:e,bucketSize:t}){if(0===e.length)return(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No camera samples in range."});let n=[...e].sort((e,t)=>e.bucket-t.bucket),l=n.reduce((e,t)=>Math.max(e,t.count),0)||1;return(0,s.jsx)("div",{className:"flex flex-col gap-1",children:n.map(e=>{let n=e.bucket*t;return(0,s.jsxs)("div",{className:"flex items-center gap-2",children:[(0,s.jsxs)("span",{className:"w-24 shrink-0 text-right font-mono text-[11px] text-fg-muted",children:[b(n,1),"–",b(n+t,1)]}),(0,s.jsx)("div",{className:"h-3.5 flex-1 overflow-hidden rounded-sm bg-ink/60",children:(0,s.jsx)("div",{className:"h-full rounded-sm bg-amber",style:{width:`${e.count/l*100}%`}})}),(0,s.jsx)("span",{className:"w-12 shrink-0 text-right font-mono text-[11px] text-fg-muted",children:b(e.count)})]},e.bucket)})})}function eq({coverage:e,cellSize:t,distance:n,bucketSize:l,navigation:r}){let a=e.length,i=e.reduce((e,t)=>e+t.count,0),o=r.reduce((e,t)=>e+t.total_distance,0),c=r.reduce((e,t)=>e+t.segments,0),d=r.reduce((e,t)=>e+t.active_segments,0),u=r.length,m=a>0||r.length>0;return(0,s.jsx)(_.Panel,{title:"Scene traversal",subtitle:"Coverage, camera distance & navigation effort — derived from camera_sample",collapsible:!0,defaultCollapsed:!0,children:m?(0,s.jsxs)("div",{className:"flex flex-col gap-5",children:[(0,s.jsxs)("div",{className:"grid grid-cols-2 gap-2 sm:grid-cols-4",children:[(0,s.jsx)(eX,{label:"Visited cells",value:b(a),hint:`${b(t,2)} u voxels`}),(0,s.jsx)(eX,{label:"Camera samples",value:b(i)}),(0,s.jsx)(eX,{label:"Avg travel",value:b(u>0?o/u:0,1),hint:u>0?`over ${b(u)} sessions`:void 0}),(0,s.jsx)(eX,{label:"Active movement",value:`${b(100*(c>0?d/c:0),0)}%`,hint:"of camera segments"})]}),(0,s.jsxs)("div",{children:[(0,s.jsx)("p",{className:"mb-1.5 text-xs uppercase tracking-wide text-fg-muted",children:"Camera distance distribution"}),(0,s.jsx)(eJ,{buckets:n,bucketSize:l})]})]}):(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"No camera samples in range."})})}let eY={babylon:"Babylon.js","babylon-lite":"Babylon (lite)",three:"three.js",playcanvas:"PlayCanvas",r3f:"react-three-fiber",aframe:"A-Frame"};function eZ({project:e,playgroundUrl:t,onView:n,onOpenOverlay:r}){var a;let i=e.scene,o=i?.engines.length?i.engines:[],[c,d]=(0,l.useState)(i?.defaultEngine??o[0]??""),u=t.length>0&&c.length>0;return(0,s.jsxs)("div",{className:"flex flex-col gap-3 rounded-xl border border-edge bg-panel p-4",children:[(0,s.jsxs)("div",{className:"flex items-start justify-between gap-2",children:[(0,s.jsxs)("div",{children:[(0,s.jsx)("h3",{className:"text-sm font-semibold text-fg-hi",children:i?.label??e.name}),(0,s.jsx)("p",{className:"text-xs text-fg-muted",children:e.name})]}),i?(0,s.jsx)("span",{className:"shrink-0 rounded-full border border-edge bg-ink/50 px-2 py-0.5 text-[11px] text-fg-muted",children:"first-person"===i.cameraMode?"first-person":"viewer"}):null]}),i?.description?(0,s.jsx)("p",{className:"text-xs leading-relaxed text-fg-muted",children:i.description}):(0,s.jsx)("p",{className:"text-xs leading-relaxed text-fg-muted",children:"A project without scene metadata — open its analytics directly."}),o.length>1?(0,s.jsxs)("label",{className:"flex flex-col gap-1 text-[11px] text-fg-muted",children:["Engine",(0,s.jsx)("select",{className:"rounded-md border border-edge bg-ink px-2 py-1.5 text-xs text-fg outline-none focus:border-saffron",value:c,onChange:e=>d(e.target.value),children:o.map(e=>(0,s.jsx)("option",{value:e,children:eY[e]??e},e))})]}):1===o.length?(0,s.jsxs)("p",{className:"text-[11px] text-fg-muted",children:["Engine: ",eY[a=o[0]]??a]}):null,(0,s.jsxs)("div",{className:"mt-auto flex flex-wrap gap-2 pt-1",children:[(0,s.jsx)("button",{type:"button",onClick:()=>n(e),className:"rounded-md bg-amber px-3 py-1.5 text-xs font-medium text-ink transition hover:bg-ember",children:"View analytics"}),i?(0,s.jsx)("button",{type:"button",disabled:!u,onClick:()=>r(e,c),className:"rounded-md border border-edge px-3 py-1.5 text-xs text-fg transition hover:border-amber hover:text-fg-hi disabled:opacity-40",children:"Open live scene"}):null]})]})}function eQ({projects:e,playgroundUrl:t,onView:n}){let[r,a]=(0,l.useState)(null),i=(0,l.useMemo)(()=>{let t=[],s=[],n=[];for(let l of e)l.scene?"first-person"===l.scene.cameraMode?s.push(l):t.push(l):n.push(l);return{viewer:t,firstPerson:s,other:n}},[e]),o=(e,s)=>{let n=e.scene;n&&t&&a({url:`${t.replace(/\/$/,"")}/?scene=${encodeURIComponent(n.id)}&engine=${encodeURIComponent(s)}`,title:`${n.label} \xb7 ${eY[s]??s}`})},c=(e,l)=>l.length>0?(0,s.jsxs)("section",{className:"flex flex-col gap-3",children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-fg-muted",children:e}),(0,s.jsx)("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2 lg:grid-cols-3",children:l.map(e=>(0,s.jsx)(eZ,{project:e,playgroundUrl:t,onView:n,onOpenOverlay:o},e.id))})]}):null;return(0,s.jsxs)(_.Panel,{title:"Scenes",subtitle:"Pick a scene to explore its analytics, or open it live to test capture.",children:[(0,s.jsxs)("div",{className:"flex flex-col gap-6",children:[c("Viewer",i.viewer),c("First-person",i.firstPerson),c("Other projects",i.other)]}),r?(0,s.jsx)("div",{className:"fixed inset-0 z-50 flex flex-col bg-black/70 p-4 sm:p-8",role:"dialog","aria-modal":"true","aria-label":"Live scene overlay",children:(0,s.jsxs)("div",{className:"mx-auto flex h-full w-full max-w-6xl flex-col overflow-hidden rounded-xl border border-edge bg-panel",children:[(0,s.jsxs)("div",{className:"flex items-center justify-between gap-3 border-b border-edge px-4 py-2.5",children:[(0,s.jsx)("p",{className:"text-sm text-fg",children:r.title}),(0,s.jsxs)("div",{className:"flex items-center gap-2",children:[(0,s.jsx)("a",{href:r.url,target:"_blank",rel:"noreferrer",className:"rounded-md border border-edge px-3 py-1.5 text-xs text-fg transition hover:border-amber hover:text-fg-hi",children:"Open in new tab ↗"}),(0,s.jsx)("button",{type:"button",onClick:()=>a(null),className:"rounded-md border border-edge px-3 py-1.5 text-xs text-fg transition hover:border-amber hover:text-fg-hi",children:"Close ✕"})]})]}),(0,s.jsx)("iframe",{title:r.title,src:r.url,className:"h-full w-full flex-1 bg-ink"})]})}):null]})}function e0({sessions:e,onSelect:t,selectedId:n}){return(0,s.jsx)(_.Panel,{title:"Sessions",subtitle:t?`${e.length} most recent \xb7 select to drill in`:`${e.length} most recent`,children:(0,s.jsx)(ea,{sessions:e,onSelect:t,selectedId:n})})}function e1({baseUrl:e,apiKey:t,sessionId:n,scene:r}){let i=(0,l.useRef)(null),[o,c]=(0,l.useState)([]),[d,u]=(0,l.useState)("loading");return(0,l.useEffect)(()=>{let s=!1;return u("loading"),new a.CollectorApi(e,t).sessionTrajectory(n,{scene:r,limit:5e3}).then(e=>{s||(c(e),u("ready"))}).catch(()=>{s||(c([]),u("error"))}),()=>{s=!0}},[e,t,n,r]),(0,l.useEffect)(()=>{let e=i.current;if(!e)return;let t=e.getContext("2d");if(!t||(t.clearRect(0,0,360,360),t.fillStyle="#0b0e14",t.fillRect(0,0,360,360),0===o.length))return;let s=1/0,n=-1/0,l=1/0,r=-1/0;for(let e of o)e.x<s&&(s=e.x),e.x>n&&(n=e.x),e.z<l&&(l=e.z),e.z>r&&(r=e.z);let a=328/Math.max(n-s,r-l,.001),c=e=>[16+(e.x-s)*a,16+(r-e.z)*a];t.lineWidth=2,t.strokeStyle="#38bdf8",t.beginPath(),o.forEach((e,s)=>{let[n,l]=c(e);0===s?t.moveTo(n,l):t.lineTo(n,l)}),t.stroke();let d=o[0],u=o[o.length-1];if(d){let[e,s]=c(d);t.fillStyle="#22c55e",t.beginPath(),t.arc(e,s,5,0,2*Math.PI),t.fill()}if(u){let[e,s]=c(u);t.fillStyle="#ef4444",t.beginPath(),t.arc(e,s,5,0,2*Math.PI),t.fill()}},[o]),(0,s.jsxs)(_.Panel,{title:"Walked path",subtitle:"Camera trajectory (top-down)",help:"The ordered route this session's camera took across the X/Z ground plane — green is the start, red is the end. Meaningful for first-person (walkable) sessions.",children:[(0,s.jsx)("div",{className:"flex justify-center",children:(0,s.jsx)("canvas",{ref:i,width:360,height:360,className:"rounded-lg border border-edge","aria-label":"Session camera trajectory"})}),"loading"===d?(0,s.jsx)("p",{className:"mt-2 text-center text-xs text-fg-muted",children:"Loading trajectory…"}):"error"===d?(0,s.jsx)("p",{className:"mt-2 text-center text-xs text-red-400",children:"Failed to load trajectory."}):0===o.length?(0,s.jsx)("p",{className:"mt-2 text-center text-xs text-fg-muted",children:"No camera movement recorded for this session."}):null]})}function e2(e){return e>=36e5?`${Math.round(e/36e5)}h`:e>=6e4?`${Math.round(e/6e4)}m`:e>=1e3?`${Math.round(e/1e3)}s`:`${e}ms`}function e5({buckets:e,intervalMs:t,onBrush:n,onClear:r,brushed:a}){let i=(0,l.useRef)(null),o=(0,l.useRef)(null),[c,d]=(0,l.useState)(640),u=(0,l.useRef)(null),[m,x]=(0,l.useState)(null);(0,l.useEffect)(()=>{let e=i.current;if(!e)return;let t=()=>d(Math.max(320,e.clientWidth));t();let s=new ResizeObserver(t);return s.observe(e),()=>s.disconnect()},[]);let p={x:40,y:14,w:Math.max(1,c-40-36),h:114},h=e.length>0?{start:e[0].bucket,end:e[e.length-1].bucket+t}:null,g=(0,l.useCallback)(e=>{if(!h)return 0;let t=(e-p.x)/p.w;return Math.round(h.start+Math.max(0,Math.min(1,t))*(h.end-h.start))},[h,p.x,p.w]);(0,l.useEffect)(()=>{let s=o.current;if(!s)return;let n=s.getContext("2d");if(!n)return;if(n.clearRect(0,0,c,150),n.fillStyle="#0b0e14",n.fillRect(0,0,c,150),0===e.length||!h){n.fillStyle="#64748b",n.font="12px system-ui, sans-serif",n.textAlign="center",n.fillText("No events in range",c/2,75);return}let l=e.reduce((e,t)=>Math.max(e,t.events),0)||1,r=h.end-h.start,a=Math.max(1,p.w/e.length*.8);for(let t of e){let e=p.x+(t.bucket-h.start)/r*p.w,s=t.events/l*p.h;n.fillStyle="rgba(56, 189, 248, 0.55)",n.fillRect(e,p.y+p.h-s,a,s)}if(n.font="10px system-ui, sans-serif",n.textBaseline="middle",n.fillStyle="rgba(56, 189, 248, 0.95)",n.textAlign="right",n.fillText(String(l),p.x-5,p.y+4),n.fillText("0",p.x-5,p.y+p.h),n.textBaseline="alphabetic",n.fillStyle="rgba(56, 189, 248, 0.7)",n.textAlign="left",n.fillText(`events / ${e2(t)}`,p.x,144),m){let e=Math.min(m.x0,m.x1),t=Math.max(m.x0,m.x1);n.fillStyle="rgba(56, 189, 248, 0.18)",n.fillRect(e,p.y,t-e,p.h),n.strokeStyle="rgba(56, 189, 248, 0.8)",n.lineWidth=1,n.strokeRect(e,p.y,t-e,p.h)}},[e,c,h,m,t,p.x,p.y,p.w,p.h]);let f=()=>{let e=u.current;if(u.current=null,x(null),!e||4>Math.abs(e.x1-e.x0))return;let t=g(Math.min(e.x0,e.x1)),s=g(Math.max(e.x0,e.x1));s>t&&n(t,s)};return(0,s.jsx)(_.Panel,{title:"Event volume over time",subtitle:`Bars: events per ${e2(t)} \xb7 drag to zoom the time window`,children:(0,s.jsxs)("div",{ref:i,className:"relative",children:[(0,s.jsx)("canvas",{ref:o,width:c,height:150,className:"w-full cursor-crosshair rounded-lg border border-edge",onMouseDown:e=>{let t=e.currentTarget.getBoundingClientRect(),s=e.clientX-t.left;u.current={x0:s,x1:s},x({x0:s,x1:s})},onMouseMove:e=>{if(!u.current)return;let t=e.currentTarget.getBoundingClientRect(),s={...u.current,x1:e.clientX-t.left};u.current=s,x(s)},onMouseUp:f,onMouseLeave:f,"aria-label":"Event volume time series"}),a&&r?(0,s.jsx)("button",{type:"button",onClick:r,className:"absolute right-2 top-2 rounded-md border border-edge bg-ink/80 px-2 py-1 text-xs text-fg transition hover:border-amber hover:text-fg-hi",children:"Clear zoom"}):null]})})}var e3=e.i(19761);function e4({label:e,value:t}){return(0,s.jsxs)("div",{className:"flex items-baseline justify-between gap-3 py-0.5",children:[(0,s.jsx)("span",{className:"shrink-0 text-xs text-fg-muted",children:e}),(0,s.jsx)("span",{className:"min-w-0 truncate text-right font-mono text-xs text-fg",title:t,children:t})]})}function e6({title:e,rows:t}){return 0===t.length?null:(0,s.jsxs)("div",{className:"rounded-lg border border-edge bg-ink/40 p-3",children:[(0,s.jsx)("p",{className:"mb-1.5 text-[10px] font-semibold uppercase tracking-wide text-fg-muted",children:e}),t.map(([e,t])=>(0,s.jsx)(e4,{label:e,value:t},e))]})}function e8(e){let t=[];for(let[s,n]of e){let e=null==n||""===n?null:Array.isArray(n)?n.join(" × "):"boolean"==typeof n?n?"yes":"no":"object"==typeof n?JSON.stringify(n):String(n);null!=e&&t.push([s,e])}return t}function e9({baseUrl:e,apiKey:t,sessionId:n,hiddenTypes:r,onToggleType:a,onSetAllHidden:i}){let o,c,d,[u,m]=(0,l.useState)([]),[x,p]=(0,l.useState)("loading"),[h,g]=(0,l.useState)(null),[f,b]=(0,l.useState)(new Set);(0,l.useEffect)(()=>{let s=!1;return p("loading"),g(null),m([]),b(new Set),(async()=>{try{let l=await (0,e3.fetchSessionEvents)({endpoint:e,apiKey:t,sessionId:n});if(s)return;m(l),p(0===l.length?"empty":"ready")}catch(e){if(s)return;p("error"),g(e instanceof Error?e.message:"Failed to load session data.")}})(),()=>{s=!0}},[e,t,n]);let{meta:v,byType:j,allTypes:y,sorted:w}=(0,l.useMemo)(()=>{let e=[...u].sort((e,t)=>e.ts-t.ts),t=new Map;for(let s of e)t.set(s.type,(t.get(s.type)??0)+1);let s=[...t.keys()].sort(),n=e[0];return{meta:{start:n,end:e[e.length-1],startEvent:e.find(e=>"session_start"===e.type)},byType:t,allTypes:s,sorted:e}},[u]);if("ready"!==x)return(0,s.jsx)(_.Panel,{title:"Session data",subtitle:"Metadata and captured event breakdown",children:(0,s.jsx)("p",{className:"py-6 text-center text-sm text-fg-muted",children:"loading"===x?"Loading session data…":"empty"===x?"No events captured for this session.":h??"Session data unavailable."})});let N=v.start,k=v.end,S=v.startEvent,M=N&&k?k.ts-N.ts:0,P=e=>e?new Date(e).toLocaleString():"—",C=N?.pageMeta,z=e8([["Project",N?.projectId],["Session",N?.sessionId],["Visitor",N?.visitorId],["SDK",N?.sdkVersion],["Scene ID",N?.sceneId],["URL",N?.url],["Started",P(N?.ts)],["Ended",P(k?.ts)],["Duration",(c=Math.floor((o=Math.round(M/1e3))/60),d=o%60,c>0?`${c}m ${d}s`:`${d}s`)],["Events",String(w.length)]]),R=C?e8([["Title",C.title],["Language",C.language],["Referrer",C.referrer],["Viewport",C.viewport],["Device pixel ratio",C.devicePixelRatio]]):[],T=S?.type==="session_start"?S.device:void 0,A=S?.type==="session_start"?S.graphics:void 0,E=S?.type==="session_start"?S.scene:void 0,I=S?.type==="session_start"?S.connector:void 0,$=S?.type==="session_start"?S.user:void 0,D=e8([["Engine",T?.engine],["Graphics API",A?.api],["Backend",A?.backend],["API version",A?.apiVersion],["Shading language",A?.shadingLanguage],["GPU vendor",T?.vendor],["GPU renderer",T?.renderer],["Max texture size",T?.maxTextureSize],["CPU cores",T?.hardwareConcurrency],["Device memory (GB)",T?.deviceMemoryGb],["Mobile",T?.isMobile]]),F=e8([["Connector",I?[I.name,I.version].filter(Boolean).join(" "):null],["Coordinate system",I?.coordinateSystem],["Description",E?.description],["Camera type",E?.cameraType],["Camera name",E?.cameraName],["Mesh count",E?.meshCount],["User id",$?.id],["User traits",$?.traits]]),L=y.every(e=>r.has(e));return(0,s.jsxs)(_.Panel,{title:"Session data",subtitle:"Metadata that was sent and a per-feature breakdown — toggle a type to show/hide it in the replay, expand to inspect raw payloads",help:(0,s.jsxs)(s.Fragment,{children:["Project-level metadata beyond the ",(0,s.jsx)("strong",{children:"Project ID"}),"isn't stored in the OSS collector (Phase 1) — everything here is derived from the session's own events. The"," ",(0,s.jsx)("strong",{children:"Device / graphics"})," and ",(0,s.jsx)("strong",{children:"Scene / connector"})," blocks come from the one-time ",(0,s.jsx)("code",{children:"session_start"})," event."]}),children:[(0,s.jsxs)("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[(0,s.jsx)(e6,{title:"Identity",rows:z}),(0,s.jsx)(e6,{title:"Page context",rows:R}),(0,s.jsx)(e6,{title:"Device / graphics",rows:D}),(0,s.jsx)(e6,{title:"Scene / connector",rows:F})]}),(0,s.jsxs)("div",{className:"mt-4",children:[(0,s.jsxs)("div",{className:"mb-2 flex items-center justify-between",children:[(0,s.jsxs)("p",{className:"text-[10px] font-semibold uppercase tracking-wide text-fg-muted",children:["Captured features (",y.length," event types)"]}),(0,s.jsx)("button",{type:"button",onClick:()=>i(!L,y),className:"rounded-md border border-edge px-2 py-1 text-xs text-fg transition hover:border-amber hover:text-fg-hi",children:L?"Show all":"Hide all"})]}),(0,s.jsx)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-2 lg:grid-cols-3",children:y.map(e=>{let t=!r.has(e),n=f.has(e),l=w.filter(t=>t.type===e).slice(0,3);return(0,s.jsxs)("div",{className:`self-start rounded-lg border border-edge bg-ink/40 ${n?"sm:col-span-2 lg:col-span-3":""}`,children:[(0,s.jsxs)("div",{className:"flex items-center gap-2 px-2.5 py-1.5",children:[(0,s.jsxs)("label",{className:"flex min-w-0 flex-1 cursor-pointer items-center gap-2",children:[(0,s.jsx)("input",{type:"checkbox",checked:t,onChange:()=>a(e),className:"accent-amber"}),(0,s.jsx)("span",{className:"truncate font-mono text-xs text-fg",children:e})]}),(0,s.jsx)("span",{className:"tabular-nums text-xs text-fg-muted",children:j.get(e)}),(0,s.jsx)("button",{type:"button",onClick:()=>b(t=>{let s=new Set(t);return s.has(e)?s.delete(e):s.add(e),s}),"aria-expanded":n?"true":"false",className:"rounded border border-edge px-1.5 py-0.5 text-[10px] text-fg-muted transition hover:border-amber hover:text-fg-hi",children:n?"Hide raw":"Raw"})]}),n?(0,s.jsxs)("pre",{className:"max-h-64 overflow-auto border-t border-edge bg-black/30 px-3 py-2 text-[10px] leading-relaxed text-fg",children:[l.map(e=>JSON.stringify(e,null,2)).join("\n\n"),(j.get(e)??0)>l.length?`
2
+
3
+ … ${(j.get(e)??0)-l.length} more`:""]}):null]},e)})})]})]})}function e7(e){return e.length>10?`${e.slice(0,8)}…`:e}function te(e,t){let s=Math.max(0,Math.round((t-e)/1e3));if(s<60)return`${s}s ago`;let n=Math.floor(s/60);return n<60?`${n}m ago`:`${Math.floor(n/60)}h ago`}let tt={active:"bg-emerald-400",recent:"bg-amber-400",idle:"bg-fg-muted"},ts={idle:"offline",connecting:"connecting…",open:"live",reconnecting:"reconnecting…"};function tn({status:e,sessions:t}){let n="open"===e;return(0,s.jsxs)("span",{className:"inline-flex items-center gap-2 rounded-full border border-edge bg-ink px-3 py-1 text-xs",children:[(0,s.jsxs)("span",{className:"relative flex h-2 w-2",children:[n?(0,s.jsx)("span",{className:"absolute inline-flex h-full w-full animate-ping rounded-full bg-emerald-400 opacity-75"}):null,(0,s.jsx)("span",{className:`relative inline-flex h-2 w-2 rounded-full ${n?"bg-emerald-400":"idle"===e?"bg-fg-muted":"bg-amber-400"}`})]}),(0,s.jsx)("span",{className:"font-medium text-fg",children:n?`${b(t)} live now`:ts[e]})]})}function tl({snapshot:e,status:t,feed:n,now:l,onSelectSession:r}){let a=e?.sessions??[],i=e?.activeSessions??0,o=e?.activeVisitors??0;return(0,s.jsxs)(_.Panel,{title:"Live now",subtitle:"Active sessions and a real-time event feed, updating in place.",help:(0,s.jsx)(s.Fragment,{children:"Sessions seen within the liveness window, streamed over SSE from the collector. The roster is intentionally non-identifying — no geo, user-agent, or visitor id. Click a session to follow it live."}),children:[(0,s.jsxs)("div",{className:"mb-3 flex flex-wrap items-center gap-4",children:[(0,s.jsx)(tn,{status:t,sessions:i}),(0,s.jsxs)("span",{className:"text-xs text-fg-muted",children:[(0,s.jsx)("span",{className:"font-semibold text-fg",children:b(o)})," visitor",1===o?"":"s"]})]}),(0,s.jsxs)("div",{className:"grid grid-cols-1 gap-4 lg:grid-cols-2",children:[(0,s.jsxs)("div",{children:[(0,s.jsxs)("p",{className:"mb-2 text-xs uppercase tracking-wide text-fg-muted",children:["Sessions (",a.length,")"]}),0===a.length?(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"open"===t?"No active sessions right now.":"Waiting for live data…"}):(0,s.jsx)("ul",{className:"flex max-h-64 flex-col gap-1 overflow-y-auto pr-1",children:a.map(e=>(0,s.jsx)("li",{children:r?(0,s.jsxs)("button",{type:"button",onClick:()=>r(e.sessionId),className:"flex w-full items-center gap-2 rounded-md border border-transparent px-2 py-1.5 text-left transition hover:border-edge hover:bg-ink",children:[(0,s.jsx)("span",{className:`h-2 w-2 flex-none rounded-full ${tt[e.activity]}`,"aria-hidden":"true"}),(0,s.jsx)("span",{className:"font-mono text-xs text-fg",children:e7(e.sessionId)}),(0,s.jsx)("span",{className:"truncate text-xs text-fg-muted",children:e.sceneId}),(0,s.jsx)("span",{className:"ml-auto flex-none text-xs text-fg-muted",children:te(e.lastSeen,l)})]}):(0,s.jsxs)("div",{className:"flex w-full items-center gap-2 px-2 py-1.5",children:[(0,s.jsx)("span",{className:`h-2 w-2 flex-none rounded-full ${tt[e.activity]}`,"aria-hidden":"true"}),(0,s.jsx)("span",{className:"font-mono text-xs text-fg",children:e7(e.sessionId)}),(0,s.jsx)("span",{className:"truncate text-xs text-fg-muted",children:e.sceneId}),(0,s.jsx)("span",{className:"ml-auto flex-none text-xs text-fg-muted",children:te(e.lastSeen,l)})]})},e.sessionId))})]}),(0,s.jsxs)("div",{children:[(0,s.jsx)("p",{className:"mb-2 text-xs uppercase tracking-wide text-fg-muted",children:"Event feed"}),0===n.length?(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"open"===t?"Listening for events…":"Waiting for live data…"}):(0,s.jsx)("ul",{className:"flex max-h-64 flex-col gap-1 overflow-y-auto pr-1 font-mono text-xs",children:n.map((e,t)=>(0,s.jsxs)("li",{className:"flex items-center gap-2 rounded-md px-2 py-1",children:[(0,s.jsx)("span",{className:"flex-none rounded bg-amber/15 px-1.5 py-0.5 text-[11px] text-saffron",children:e.type}),(0,s.jsx)("span",{className:"text-fg-muted",children:e7(e.sessionId)}),(0,s.jsx)("span",{className:"ml-auto flex-none text-fg-muted",children:te(e.ts,l)})]},`${e.sessionId}-${e.ts}-${t}`))})]})]})]})}let tr=(0,n.default)(()=>e.A(69091).then(e=>e.SessionReplay),{loadableGenerated:{modules:[12449]},ssr:!1}),ta=(0,n.default)(()=>e.A(15867).then(e=>e.WorldHeatmap3DView),{loadableGenerated:{modules:[94452]},ssr:!1}),ti=(0,n.default)(()=>e.A(15867).then(e=>e.ClickRays3DView),{loadableGenerated:{modules:[94452]},ssr:!1}),to={sessions:[],camera:[],perf:null,gaze:[],clickRays:[],hasFirstPerson:!1,proxyMeshes:[],timeseries:[],counts:[],diagnostics:[],renderingTech:[],coverage:[],distance:[],navigation:[],sources:[],floorPlan:[],performance:{distribution:null,histogram:[],frameTime:null,jank:null,byDevice:[],byScene:[],resources:null,stability:null},intervalMs:36e5};e.s(["default",0,function(){let[e,n]=(0,l.useState)(r.DEFAULT_COLLECTOR_URL),[o,c]=(0,l.useState)(r.DEFAULT_API_KEY),[m,p]=(0,l.useState)([]),[h,g]=(0,l.useState)(""),[f,b]=(0,l.useState)(i),[y,k]=(0,l.useState)([]),[S,M]=(0,l.useState)(to),[P,C]=(0,l.useState)("idle"),[z,T]=(0,l.useState)(null),[A,E]=(0,l.useState)(null),[I,$]=(0,l.useState)("idle"),[D,F]=(0,l.useState)(new Set),[L,O]=(0,l.useState)([]),[U,B]=(0,l.useState)(()=>Date.now()),[H,G]=(0,l.useState)(0),[K,V]=(0,l.useState)(void 0),W=(0,l.useRef)(void 0),X=(0,l.useRef)(new Set),J=(0,l.useRef)(f);J.current=f;let q=(0,l.useRef)(i.window),Y=(0,l.useRef)(h);Y.current=h;let Z=(0,l.useRef)(A);Z.current=A;let Q=(0,l.useRef)(null),ee=(0,l.useRef)(null),et=(0,l.useRef)(!1),es=(0,l.useCallback)((e,t)=>{let s=`/projects/${encodeURIComponent(e)}`;return t?`${s}/session/${encodeURIComponent(t)}`:s},[]),en=(0,l.useCallback)(e=>{window.location.pathname!==e&&window.history.pushState({},"",e)},[]);(0,l.useEffect)(()=>{let e=window.location.pathname.match(/^\/projects\/([^/]+)(?:\/session\/([^/]+))?/);e?.[1]&&(Q.current=decodeURIComponent(e[1]),e[2]&&(ee.current=decodeURIComponent(e[2])))},[]),(0,l.useEffect)(()=>{r.COLLECTOR_URL_IS_PINNED||n(window.location.origin)},[]),(0,l.useEffect)(()=>{let e=!1;return fetch("/api/projects").then(e=>e.ok?e.json():[]).then(t=>{if(e||!Array.isArray(t)||0===t.length)return;p(t);let[s]=t,n=Q.current,l=(n?t.find(e=>e.id===n):void 0)??t.find(e=>e.apiKey===r.DEFAULT_API_KEY)??s;l&&(g(l.id),c(l.apiKey),(n&&l.id===n||1===t.length&&!l.scene)&&(et.current=!0))}).catch(()=>{}),()=>{e=!0}},[]);let el=(0,l.useCallback)(async t=>{let s=t??o;if(!s){C("error"),T("An API key is required.");return}C("loading"),T(null),E(null),$("idle");let n=J.current,l=u(n),r=d(n),i=new a.CollectorApi(e,s);try{let e=await i.sessions({...l,source:void 0,limit:100}),t=r.until??Date.now(),s=r.since;if(null==s){let n=e.reduce((e,t)=>{var s;let n=(s=t.started_at,new Date(s.includes("T")?s:s.replace(" ","T")+"Z").getTime());return Number.isFinite(n)?Math.min(e,n):e},Date.now());s=Number.isFinite(n)?n:t-864e5}let n=x(Math.max(6e4,t-s)),a=1e3*n,[o,c,d,u,m,p,h,g,f,b,v,j,y,w,N]=await Promise.all([i.cameraHeatmap({...l,source:void 0,bins:36}),i.perf({...l,source:void 0}),i.gazeHeatmap({...l,source:void 0,cellSize:.5}),i.clickRays({...l,cellSize:.5}),i.scenes({since:r.since,until:r.until,limit:200}),i.timeseries({since:r.since,until:r.until,scene:l.scene,interval:n}),i.eventCounts({since:r.since,until:r.until,scene:l.scene}),i.graphicsDiagnosticCounts({...l,source:void 0}),i.renderingTechnology({...l,source:void 0}),i.coverage({...l,source:void 0,cellSize:1}),i.cameraDistance({...l,source:void 0,bucketSize:1}),i.navigation({...l,source:void 0}),i.interactionsBySource(l),i.cameraPositionHeatmap({...l,source:void 0,cameraMode:"first-person",cellSize:1}),(async()=>{let[e,t,s,n,r,a,o,c]=await Promise.all([i.perfDistribution({...l,source:void 0}),i.fpsHistogram({...l,source:void 0}),i.frameTimePercentiles({...l,source:void 0}),i.jankRate({...l,source:void 0}),i.perfByDevice({...l,source:void 0}),i.perfByScene({...l,source:void 0,scene:void 0}),i.resourcePercentiles({...l,source:void 0}),i.stabilityCounts({...l,source:void 0})]);return{distribution:e,histogram:t,frameTime:s,jank:n,byDevice:r,byScene:a,resources:o,stability:c}})()]);k(m),M(t=>({sessions:e,camera:o,perf:c,gaze:d,clickRays:u,hasFirstPerson:w.length>0,proxyMeshes:t.proxyMeshes,timeseries:p,counts:h,diagnostics:g,renderingTech:f,coverage:b,distance:v,navigation:j,sources:y,floorPlan:w,performance:N,intervalMs:a})),C("ready")}catch(e){M(to),C("error"),T(e instanceof a.ApiError?`${e.status}: ${e.message}`:e instanceof Error?e.message:"Request failed.")}},[o,e]),er=(0,l.useCallback)(e=>{g(e.id),c(e.apiKey),V(void 0),W.current=void 0,en(es(e.id)),el(e.apiKey)},[el,es,en]);(0,l.useEffect)(()=>{if("idle"===P)return;let e=setTimeout(()=>void el(),300);return()=>clearTimeout(e)},[f]);let ea="idle"!==P&&!!o,ei=(0,l.useRef)(0),eo=(0,l.useRef)(!1);eo.current=null!=A;let ec=(0,l.useCallback)(e=>{O(t=>[e,...t].slice(0,30)),X.current.forEach(t=>t(e)),!eo.current&&e.sceneId&&e.sceneId!==W.current&&(W.current=e.sceneId,V(e.sceneId),G(e=>e+1));let t=Date.now();eo.current||t-ei.current<5e3||(ei.current=t,el(),G(e=>e+1))},[el]),{snapshot:ed,status:eu}=(0,j.useLivePresence)(e,o,ea);(0,j.useLiveStream)(e,o,ea,ec),(0,l.useEffect)(()=>{if(!ea)return;let e=setInterval(()=>B(Date.now()),1e3);return()=>clearInterval(e)},[ea]),(0,l.useEffect)(()=>{if(!ea)return;let t=new a.CollectorApi(e,o),s=!1,n=async()=>{let e=d(J.current),n=await t.scenes({since:e.since,until:e.until,limit:200}).catch(()=>null);!s&&n&&k(n)},l=setInterval(()=>void n(),5e3);return()=>{s=!0,clearInterval(l)}},[ea,e,o]);let em=f.scene&&f.scene.length>0?f.scene:void 0;(0,l.useEffect)(()=>{if("idle"===P)return;let t=!1;return(async()=>{let s=new a.CollectorApi(e,o),n=em?(await s.sceneRepresentation(em).catch(()=>null))?.proxy?.meshes??[]:await (0,v.mergeSceneProxies)(s,u(J.current));t||M(e=>({...e,proxyMeshes:n}))})(),()=>{t=!0}},[em,e,o,P,H]);let ex=(0,l.useCallback)(async t=>{let s=u(J.current),n=new a.CollectorApi(e,o),[l,r,i]=await Promise.all([n.cameraHeatmap({...s,source:void 0,bins:36,session:t}),n.perf({...s,source:void 0,session:t}),n.sessionMeta(t).catch(()=>null)]);return{id:t,meta:i,camera:l,perf:r}},[e,o]),ep=(0,l.useCallback)(async e=>{let t=Y.current;t&&en(es(t,e)),window.scrollTo({top:0,behavior:"smooth"}),E({id:e,meta:null,camera:[],perf:null}),$("loading"),F(new Set);try{E(await ex(e)),$("ready")}catch(e){$("error"),T(e instanceof a.ApiError?`${e.status}: ${e.message}`:e instanceof Error?e.message:"Request failed.")}},[ex,es,en]),eh=(0,l.useCallback)(()=>{let e=Y.current;e&&en(es(e)),E(null),$("idle"),F(new Set)},[es,en]),eg=(0,l.useCallback)(e=>{let t=m.find(t=>t.id===e);g(e),t&&c(t.apiKey),M(to),k([]),C("idle"),T(null),E(null),$("idle"),F(new Set)},[m]),ef=(0,l.useCallback)(e=>{F(t=>{let s=new Set(t);return s.has(e)?s.delete(e):s.add(e),s})},[]),eb=(0,l.useCallback)((e,t)=>{F(e?new Set(t):new Set)},[]),ev=(0,l.useCallback)((e,t)=>{b(s=>("custom"!==s.window&&(q.current=s.window),{...s,window:"custom",since:e,until:t}))},[]),ej=(0,l.useCallback)(()=>{b(e=>({...e,window:q.current}))},[]);(0,l.useEffect)(()=>{et.current&&o&&(et.current=!1,el())},[m,o,el]),(0,l.useEffect)(()=>{if("ready"===P&&ee.current){let e=ee.current;ee.current=null,ep(e)}},[P,ep]),(0,l.useEffect)(()=>{let e=()=>{let e=window.location.pathname.match(/^\/projects\/[^/]+(?:\/session\/([^/]+))?/),t=e?.[1]?decodeURIComponent(e[1]):null;t?Z.current?.id!==t&&ep(t):Z.current&&eh()};return window.addEventListener("popstate",e),()=>window.removeEventListener("popstate",e)},[ep,eh]);let ey="loading"===P,ew=(0,l.useMemo)(()=>new a.CollectorApi(e,o),[e,o]),eN=(0,l.useMemo)(()=>u(f),[f,H]),e_=(0,l.useCallback)(e=>{let t=X.current;return t.add(e),()=>{t.delete(e)}},[]),ez=(0,l.useMemo)(()=>({selectSession:e=>void ep(e),setTimeRange:(e,t)=>ev(e,t),setFilters:e=>b(t=>({...t,...e}))}),[ep,ev]),eE={api:ew,baseUrl:e,apiKey:o,params:eN,filters:f,capabilities:{hasFirstPerson:S.hasFirstPerson},actions:ez,live:{presence:ed,enabled:ea,subscribe:e_,sceneId:ea?K:void 0},settings:{}},eI={...eE,surface:"overview"},e$=A?{...eE,surface:"session",sessionId:A.id}:null,eF=function(){let[e,s]=(0,l.useState)(eM);return(0,l.useEffect)(()=>{let e,n,l=(e=eS(t.default.env.NEXT_PUBLIC_PANELS_MANIFEST_URL),n=eS(t.default.env.NEXT_PUBLIC_PANELS_ALLOWED_ORIGINS),{enabled:e.length>0,manifestUrls:e,allowOrigins:n});if(!l.enabled)return;let r=!1,a=new AbortController;return s({panels:[],errors:[],loading:!0}),(async()=>{let e=[],t=[],n=new Set;for(let s of l.manifestUrls){let r=await w(s,{signal:a.signal});if("code"in r){t.push(r);continue}let i=await N(r,{allowOrigins:l.allowOrigins.length>0?l.allowOrigins:void 0});for(let s of(t.push(...i.errors),i.panels)){if(n.has(s.id)){t.push({source:s.id,code:"invalid-panel",message:`Duplicate panel id "${s.id}" from another manifest — ignored`});continue}n.add(s.id),e.push(s)}}r||s({panels:e,errors:t,loading:!1})})(),()=>{r=!0,a.abort()}},[]),e}(),eO=(0,l.useMemo)(()=>(function(e,t){let s=new Map;for(let t of e)s.set(t.id,t);let n=[...e],l=[];for(let e of t){if(s.has(e.id)){l.push({source:e.id,code:"invalid-panel",message:`Duplicate panel id "${e.id}" — kept the existing panel`});continue}s.set(e.id,e),n.push(e)}return{panels:n,errors:l}})(ek,eF.panels),[eF.panels]),eU=eO.panels,eB=(0,l.useMemo)(()=>[...eF.errors,...eO.errors],[eF.errors,eO.errors]),eH=!!(A&&ed?.sessions.some(e=>e.sessionId===A.id)),eK=(0,l.useRef)(eH);return(0,l.useEffect)(()=>{let e=eK.current;if(eK.current=eH,!e||eH)return;let t=Z.current;if(!t||"ready"!==I)return;let s=t.id,n=!1;return(async()=>{try{let e=await ex(s);n||Z.current?.id!==s||E(e)}catch{}})(),()=>{n=!0}},[eH,I,ex]),(0,l.useEffect)(()=>{if(!eH||"ready"!==I)return;let e=Z.current?.id;if(!e)return;let t=!1,s=setInterval(()=>{(async()=>{try{let s=await ex(e);t||Z.current?.id!==e||E(s)}catch{}})()},1e3);return()=>{t=!0,clearInterval(s)}},[eH,I,ex]),(0,s.jsxs)("main",{className:"mx-auto max-w-6xl px-6 py-8",children:[(0,s.jsxs)("header",{className:"mb-6 flex items-center gap-3",children:[(0,s.jsx)("img",{src:"/logo.svg",alt:"Uptimizr",width:36,height:36,className:"h-9 w-9 shrink-0"}),(0,s.jsxs)("div",{children:[(0,s.jsx)("h1",{className:"font-display text-2xl font-bold text-fg-hi",children:"Uptimizr"}),(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"Analytics for 3D scenes — open-source collector."})]})]}),(0,s.jsxs)("form",{className:"mb-6 flex flex-wrap items-end gap-3 rounded-xl border border-edge bg-panel p-4",onSubmit:e=>{e.preventDefault(),h&&en(es(h)),el()},children:[m.length>0?(0,s.jsxs)("label",{className:"flex flex-col gap-1 text-xs text-fg-muted",children:["Project",(0,s.jsx)("select",{className:"min-w-56 rounded-md border border-edge bg-ink px-3 py-2 text-sm text-fg outline-none focus:border-saffron",value:h,onChange:e=>eg(e.target.value),children:m.map(e=>(0,s.jsx)("option",{value:e.id,children:e.name},e.id))})]}):null,(0,s.jsxs)("label",{className:"flex flex-1 flex-col gap-1 text-xs text-fg-muted",children:["Collector URL",(0,s.jsx)("input",{className:"min-w-56 rounded-md border border-edge bg-ink px-3 py-2 text-sm text-fg outline-none focus:border-saffron",value:e,onChange:e=>n(e.target.value),placeholder:"http://localhost:4318"})]}),(0,s.jsxs)("label",{className:"flex flex-1 flex-col gap-1 text-xs text-fg-muted",children:["Project API key",(0,s.jsx)("input",{className:"min-w-56 rounded-md border border-edge bg-ink px-3 py-2 text-sm text-fg outline-none focus:border-saffron",value:o,onChange:e=>c(e.target.value),type:"password",placeholder:"utk_…"})]}),(0,s.jsx)("button",{type:"submit",disabled:"loading"===P,className:"rounded-md bg-amber px-4 py-2 text-sm font-medium text-ink transition hover:bg-ember disabled:opacity-50",children:"loading"===P?"Loading…":"Load"})]}),"idle"!==P?(0,s.jsx)(eR,{filters:f,scenes:y,onChange:b,busy:ey}):null,z?(0,s.jsx)("div",{className:"mb-6 rounded-lg border border-red-900/60 bg-red-950/40 px-4 py-3 text-sm text-red-300",children:z}):null,"idle"===P?m.length>0?(0,s.jsx)(eQ,{projects:m,playgroundUrl:r.DEFAULT_PLAYGROUND_URL,onView:er}):(0,s.jsx)("p",{className:"text-sm text-fg-muted",children:"Enter your collector URL and a project API key, then load to view analytics."}):A?(0,s.jsxs)("div",{className:"grid grid-cols-1 gap-5 lg:grid-cols-2",children:[eB.length>0?(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(eP,{errors:eB})}):null,(0,s.jsxs)("div",{className:"lg:col-span-2 flex flex-wrap items-center justify-between gap-3 rounded-xl border border-edge bg-panel p-4",children:[(0,s.jsxs)("div",{children:[(0,s.jsx)("p",{className:"text-xs uppercase tracking-wide text-fg-muted",children:"Session"}),(0,s.jsx)("p",{className:"font-mono text-sm text-fg",children:A.id}),(0,s.jsx)("p",{className:"mt-1 text-xs text-fg-muted",children:"loading"===I?"Loading session…":[A.meta?.scene?.sceneId?`scene: ${A.meta.scene.sceneId}`:null,A.meta?.device?.gpu?`gpu: ${A.meta.device.gpu}`:null,A.meta?.startedAt?`started: ${A.meta.startedAt}`:null].filter(Boolean).join(" · ")||"No session metadata."})]}),(0,s.jsx)("button",{type:"button",onClick:eh,className:"rounded-md border border-edge px-3 py-2 text-sm text-fg transition hover:border-amber hover:text-fg-hi",children:"← All sessions"})]}),(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(tr,{baseUrl:e,apiKey:o,sessionId:A.id,hiddenTypes:D,isLive:eH})}),(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(e9,{baseUrl:e,apiKey:o,sessionId:A.id,hiddenTypes:D,onToggleType:ef,onSetAllHidden:eb})}),(0,s.jsx)(eA,{perf:A.perf}),e$?(0,s.jsx)(R,{panels:eU,ctx:e$,surface:"session",revision:H}):null,(0,s.jsx)(eC,{bins:A.camera,gridSize:36}),A.meta?.scene?.cameraType==="free"?(0,s.jsx)(e1,{baseUrl:e,apiKey:o,sessionId:A.id,scene:A.meta?.scene?.sceneId??f.scene}):null,(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(e0,{sessions:S.sessions,selectedId:A.id,onSelect:ep})})]}):(0,s.jsxs)("div",{className:"grid grid-cols-1 gap-5 lg:grid-cols-2",children:[eB.length>0?(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(eP,{errors:eB})}):null,(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(tl,{snapshot:ed,status:eu,feed:L,now:U,onSelectSession:ep})}),(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(e5,{buckets:S.timeseries,intervalMs:S.intervalMs,onBrush:ev,brushed:"custom"===f.window,onClear:ej})}),(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(eL,{counts:S.counts,perf:S.perf})}),(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(eG,{rows:S.diagnostics})}),(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(eW,{rows:S.renderingTech})}),(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(eq,{coverage:S.coverage,cellSize:1,distance:S.distance,bucketSize:1,navigation:S.navigation})}),(0,s.jsx)(eA,{perf:S.perf}),(0,s.jsx)(R,{panels:eU,ctx:eI,surface:"overview",revision:H}),(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(eD,{data:S.performance})}),(0,s.jsx)(eT,{rows:S.sources}),(0,s.jsx)(eC,{bins:S.camera,gridSize:36}),(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(_.Panel,{title:"Gaze heatmap (3D)",subtitle:"Camera-pose gaze hit-points voxel-binned in world space — what viewers actually look at",children:(0,s.jsx)(ta,{voxels:S.gaze,cellSize:.5,proxyMeshes:S.proxyMeshes,legendTitle:"Gaze density",legendLow:"few looks",legendHigh:"most looks",legendNote:"Each marker is a voxel where the camera-forward (gaze) ray hit your scene. Enable gaze capture in the SDK to populate this.",emptyLabel:"No gaze hit-points in range. Enable gaze capture in the SDK."})})}),(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(_.Panel,{title:"Click rays (3D)",subtitle:"Each click joined to the view it was made from — gate by viewpoint or focus a mesh; double-click to recenter",children:(0,s.jsx)(ti,{rays:S.clickRays,cellSize:.5,proxyMeshes:S.proxyMeshes})})}),(0,s.jsx)("div",{className:"lg:col-span-2",children:(0,s.jsx)(e0,{sessions:S.sessions,onSelect:ep})})]})]})}],14936)}]);